From python-checkins at python.org Tue Jan 1 00:48:47 2008 From: python-checkins at python.org (neal.norwitz) Date: Tue, 1 Jan 2008 00:48:47 +0100 (CET) Subject: [Python-checkins] r59635 - python/trunk/Objects/descrobject.c Message-ID: <20071231234847.CD00B1E400D@bag.python.org> Author: neal.norwitz Date: Tue Jan 1 00:48:47 2008 New Revision: 59635 Modified: python/trunk/Objects/descrobject.c Log: Fix refleak Modified: python/trunk/Objects/descrobject.c ============================================================================== --- python/trunk/Objects/descrobject.c (original) +++ python/trunk/Objects/descrobject.c Tue Jan 1 00:48:47 2008 @@ -1237,6 +1237,7 @@ } new = PyObject_CallFunction(type, "OOOO", get, set, del, doc); + Py_DECREF(type); if (new == NULL) return NULL; pnew = (propertyobject *)new; From buildbot at python.org Tue Jan 1 01:15:50 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 01 Jan 2008 00:15:50 +0000 Subject: [Python-checkins] buildbot failure in x86 gentoo trunk Message-ID: <20080101001550.A29BB1E4021@bag.python.org> The Buildbot has detected a new failure of x86 gentoo trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20gentoo%20trunk/builds/2773 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-x86 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: neal.norwitz BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_sqlite ====================================================================== FAIL: CheckSqlTimestamp (sqlite3.test.types.DateTimeTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/sqlite3/test/types.py", line 340, in CheckSqlTimestamp self.failUnlessEqual(ts.year, now.year) AssertionError: 2008 != 2007 make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Tue Jan 1 01:24:15 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 01 Jan 2008 00:24:15 +0000 Subject: [Python-checkins] buildbot failure in amd64 XP trunk Message-ID: <20080101002415.420EF1E400D@bag.python.org> The Buildbot has detected a new failure of amd64 XP trunk. Full details are available at: http://www.python.org/dev/buildbot/all/amd64%20XP%20trunk/builds/460 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: heller-windows-amd64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: neal.norwitz BUILD FAILED: failed failed slave lost sincerely, -The Buildbot From buildbot at python.org Tue Jan 1 01:34:41 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 01 Jan 2008 00:34:41 +0000 Subject: [Python-checkins] buildbot failure in PPC64 Debian trunk Message-ID: <20080101003441.64FC21E400D@bag.python.org> The Buildbot has detected a new failure of PPC64 Debian trunk. Full details are available at: http://www.python.org/dev/buildbot/all/PPC64%20Debian%20trunk/builds/1 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: neal.norwitz BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_xmlrpc ====================================================================== ERROR: test_fail_no_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/test/test_xmlrpc.py", line 560, in test_fail_no_info p.pow(6,8) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/xmlrpclib.py", line 1157, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/xmlrpclib.py", line 1447, in __request verbose=self.__verbose File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/xmlrpclib.py", line 1195, in request errcode, errmsg, headers = h.getreply() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 1006, in getreply response = self._conn.getresponse() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 932, in getresponse response.begin() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 415, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 271, in readheaders line = self.fp.readline() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/socket.py", line 351, in readline data = recv(1) error: [Errno 104] Connection reset by peer ====================================================================== ERROR: test_fail_with_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/test/test_xmlrpc.py", line 580, in test_fail_with_info p.pow(6,8) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/xmlrpclib.py", line 1157, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/xmlrpclib.py", line 1447, in __request verbose=self.__verbose File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/xmlrpclib.py", line 1195, in request errcode, errmsg, headers = h.getreply() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 1006, in getreply response = self._conn.getresponse() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 932, in getresponse response.begin() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 415, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 271, in readheaders line = self.fp.readline() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/socket.py", line 351, in readline data = recv(1) error: [Errno 104] Connection reset by peer make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Tue Jan 1 01:43:12 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 01 Jan 2008 00:43:12 +0000 Subject: [Python-checkins] buildbot failure in g4 osx.4 trunk Message-ID: <20080101004312.6778A1E400D@bag.python.org> The Buildbot has detected a new failure of g4 osx.4 trunk. Full details are available at: http://www.python.org/dev/buildbot/all/g4%20osx.4%20trunk/builds/2516 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: psf-g4 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: neal.norwitz BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30995, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') 1 test failed: test_sqlite ====================================================================== FAIL: CheckSqlTimestamp (sqlite3.test.types.DateTimeTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/sqlite3/test/types.py", line 340, in CheckSqlTimestamp self.failUnlessEqual(ts.year, now.year) AssertionError: 2008 != 2007 make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Tue Jan 1 01:45:22 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 01 Jan 2008 00:45:22 +0000 Subject: [Python-checkins] buildbot failure in x86 FreeBSD trunk Message-ID: <20080101004522.D75BA1E400D@bag.python.org> The Buildbot has detected a new failure of x86 FreeBSD trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20FreeBSD%20trunk/builds/307 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-freebsd Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: neal.norwitz BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_sqlite ====================================================================== FAIL: CheckSqlTimestamp (sqlite3.test.types.DateTimeTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/sqlite3/test/types.py", line 340, in CheckSqlTimestamp self.failUnlessEqual(ts.year, now.year) AssertionError: 2008 != 2007 sincerely, -The Buildbot From buildbot at python.org Tue Jan 1 02:15:30 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 01 Jan 2008 01:15:30 +0000 Subject: [Python-checkins] buildbot failure in hppa Ubuntu trunk Message-ID: <20080101011530.D488B1E400D@bag.python.org> The Buildbot has detected a new failure of hppa Ubuntu trunk. Full details are available at: http://www.python.org/dev/buildbot/all/hppa%20Ubuntu%20trunk/builds/430 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-ubuntu-hppa Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: neal.norwitz BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_bsddb3 ====================================================================== ERROR: test00_associateDBError (bsddb.test.test_associate.AssociateErrorTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 104, in setUp self.env.open(homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateBTreeTxnTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateBTreeTxnTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test13_associate_in_transaction (bsddb.test.test_associate.AssociateBTreeTxnTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ShelveAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ShelveAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ShelveAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ThreadedAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ThreadedAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ThreadedAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ThreadedAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ThreadedAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ThreadedAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_EnvRemoveAndRename (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_EnvRemoveAndRename (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Transactions (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_TxnTruncate (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test08_TxnLateUse (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Transactions (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_TxnTruncate (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test08_TxnLateUse (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test09_MultiDB (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test09_MultiDB (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_both (bsddb.test.test_dbobj.dbobjTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbobj.py", line 45, in test01_both self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbobj.py", line 39, in open return apply(self._cobj.open, args, kwargs) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_dbobj_dict_interface (bsddb.test.test_dbobj.dbobjTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbobj.py", line 58, in test02_dbobj_dict_interface self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbobj.py", line 39, in open return apply(self._cobj.open, args, kwargs) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01 (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02 (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03 (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_MultiCondSelect (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_CondObjs (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_CreateOrExtend (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_Delete (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_Modify (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_close_dbenv_before_db (bsddb.test.test_env_close.DBEnvClosedEarlyCrash) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_env_close.py", line 53, in test01_close_dbenv_before_db 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_close_dbenv_delete_db_success (bsddb.test.test_env_close.DBEnvClosedEarlyCrash) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_env_close.py", line 78, in test02_close_dbenv_delete_db_success 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_join (bsddb.test.test_join.JoinTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_join.py", line 57, in setUp self.env.open(homeDir, db.DB_CREATE | db.DB_INIT_MPOOL | db.DB_INIT_LOCK ) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_simple (bsddb.test.test_lock.LockingTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_lock.py", line 38, in setUp db.DB_INIT_LOCK | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_threaded (bsddb.test.test_lock.LockingTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_lock.py", line 38, in setUp db.DB_INIT_LOCK | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_set_timeout (bsddb.test.test_lock.LockingTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_lock.py", line 38, in setUp db.DB_INIT_LOCK | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_db_home (bsddb.test.test_misc.MiscTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_misc.py", line 45, in test02_db_home env.open(self.homeDir, db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_1WriterMultiReaders (bsddb.test.test_thread.BTreeConcurrentDataStore) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_1WriterMultiReaders (bsddb.test.test_thread.HashConcurrentDataStore) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_SimpleLocks (bsddb.test.test_thread.BTreeSimpleThreaded) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_SimpleLocks (bsddb.test.test_thread.HashSimpleThreaded) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.BTreeThreadedTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.HashThreadedTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.BTreeThreadedNoWaitTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.HashThreadedNoWaitTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_cachesize (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_flags (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_get (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_get_dbp (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_get_key (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_range (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_remove (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_stat (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_pget (bsddb.test.test_cursor_pget_bug.pget_bugTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_cursor_pget_bug.py", line 25, in setUp self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Tue Jan 1 05:15:30 2008 From: python-checkins at python.org (guido.van.rossum) Date: Tue, 1 Jan 2008 05:15:30 +0100 (CET) Subject: [Python-checkins] r59637 - python/trunk/Lib/sqlite3/test/types.py Message-ID: <20080101041530.53F941E400D@bag.python.org> Author: guido.van.rossum Date: Tue Jan 1 05:15:29 2008 New Revision: 59637 Modified: python/trunk/Lib/sqlite3/test/types.py Log: Fix an odd error which would only occur close to new year's eve, due to use of datetime.datetime.now() instead of utcnow() for comparison. (I think the test can still fail if it's executed pretty much *at* new year's eve, but that's not worth fixing.) Modified: python/trunk/Lib/sqlite3/test/types.py ============================================================================== --- python/trunk/Lib/sqlite3/test/types.py (original) +++ python/trunk/Lib/sqlite3/test/types.py Tue Jan 1 05:15:29 2008 @@ -331,8 +331,7 @@ if sqlite.sqlite_version_info < (3, 1): return - # SQLite's current_timestamp uses UTC time, while datetime.datetime.now() uses local time. - now = datetime.datetime.now() + now = datetime.datetime.utcnow() self.cur.execute("insert into test(ts) values (current_timestamp)") self.cur.execute("select ts from test") ts = self.cur.fetchone()[0] From buildbot at python.org Tue Jan 1 07:11:00 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 01 Jan 2008 06:11:00 +0000 Subject: [Python-checkins] buildbot failure in ia64 Ubuntu trunk Message-ID: <20080101061100.B93A81E400D@bag.python.org> The Buildbot has detected a new failure of ia64 Ubuntu trunk. Full details are available at: http://www.python.org/dev/buildbot/all/ia64%20Ubuntu%20trunk/builds/1192 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ia64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: guido.van.rossum BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_socket_ssl ====================================================================== ERROR: test_978833 (test.test_socket_ssl.BasicTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ia64/build/Lib/test/test_socket_ssl.py", line 123, in test_978833 raise test_support.TestFailed("Failed to close socket") File "/home/pybot/buildarea/trunk.klose-debian-ia64/build/Lib/contextlib.py", line 33, in __exit__ self.gen.throw(type, value, traceback) File "/home/pybot/buildarea/trunk.klose-debian-ia64/build/Lib/contextlib.py", line 117, in nested yield vars File "/home/pybot/buildarea/trunk.klose-debian-ia64/build/Lib/test/test_socket_ssl.py", line 113, in test_978833 s.connect(("svn.python.org", 443)) File "", line 1, in connect error: [Errno 110] Connection timed out make: *** [buildbottest] Error 1 sincerely, -The Buildbot From nnorwitz at gmail.com Tue Jan 1 10:00:06 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Tue, 1 Jan 2008 04:00:06 -0500 Subject: [Python-checkins] Python Regression Test Failures doc (1) Message-ID: <20080101090006.GA7122@python.psfb.org> svn update tools/sphinx svn: PROPFIND request failed on '/projects/doctools/trunk/sphinx' svn: PROPFIND of '/projects/doctools/trunk/sphinx': could not connect to server (http://svn.python.org) make: *** [update] Error 1 From buildbot at python.org Tue Jan 1 14:17:43 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 01 Jan 2008 13:17:43 +0000 Subject: [Python-checkins] buildbot failure in 3.0.msi Message-ID: <20080101131743.ED4471E4003@bag.python.org> The Buildbot has detected a new failure of 3.0.msi. Full details are available at: http://www.python.org/dev/buildbot/all/3.0.msi/builds/117 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-windows Build Reason: The Nightly scheduler named '3.0.msi' triggered this build Build Source Stamp: HEAD Blamelist: BUILD FAILED: failed compile sincerely, -The Buildbot From python-checkins at python.org Tue Jan 1 14:40:26 2008 From: python-checkins at python.org (christian.heimes) Date: Tue, 1 Jan 2008 14:40:26 +0100 (CET) Subject: [Python-checkins] r59638 - python/trunk/Tools/msi/msi.py Message-ID: <20080101134026.B90551E4011@bag.python.org> Author: christian.heimes Date: Tue Jan 1 14:40:26 2008 New Revision: 59638 Modified: python/trunk/Tools/msi/msi.py Log: MSI uses back slashes as path separators Modified: python/trunk/Tools/msi/msi.py ============================================================================== --- python/trunk/Tools/msi/msi.py (original) +++ python/trunk/Tools/msi/msi.py Tue Jan 1 14:40:26 2008 @@ -27,7 +27,7 @@ # Where is sqlite3.dll located, relative to srcdir? sqlite_dir = "../sqlite-source-3.3.4" # path to PCbuild directory -PCBUILD="PC/VS7.1" +PCBUILD="PC\\VS7.1" #PCBUILD="PCbuild9" # msvcrt version MSVCR = "71" From buildbot at python.org Tue Jan 1 14:48:17 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 01 Jan 2008 13:48:17 +0000 Subject: [Python-checkins] buildbot failure in amd64 XP trunk Message-ID: <20080101134817.420E31E4003@bag.python.org> The Buildbot has detected a new failure of amd64 XP trunk. Full details are available at: http://www.python.org/dev/buildbot/all/amd64%20XP%20trunk/builds/462 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: heller-windows-amd64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: christian.heimes BUILD FAILED: failed compile sincerely, -The Buildbot From python-checkins at python.org Tue Jan 1 14:52:58 2008 From: python-checkins at python.org (christian.heimes) Date: Tue, 1 Jan 2008 14:52:58 +0100 (CET) Subject: [Python-checkins] r59639 - python/trunk/Tools/msi/msi.py Message-ID: <20080101135258.079051E4003@bag.python.org> Author: christian.heimes Date: Tue Jan 1 14:52:57 2008 New Revision: 59639 Modified: python/trunk/Tools/msi/msi.py Log: Added new wininst files to msi.py and adjusted some paths Modified: python/trunk/Tools/msi/msi.py ============================================================================== --- python/trunk/Tools/msi/msi.py (original) +++ python/trunk/Tools/msi/msi.py Tue Jan 1 14:52:57 2008 @@ -28,7 +28,7 @@ sqlite_dir = "../sqlite-source-3.3.4" # path to PCbuild directory PCBUILD="PC\\VS7.1" -#PCBUILD="PCbuild9" +#PCBUILD="PCbuild" # msvcrt version MSVCR = "71" #MSVCR = "90" @@ -334,7 +334,7 @@ if not os.path.exists(srcdir+r"\PC\python_icon.exe"): raise "Run icons.mak in PC directory" add_data(db, "Binary", - [("PythonWin", msilib.Binary(r"%s\%s\installer.bmp" % (srcdir, PCBUILD))), # 152x328 pixels + [("PythonWin", msilib.Binary(r"%s\PCbuild\installer.bmp" % srcdir)), # 152x328 pixels ("py.ico",msilib.Binary(srcdir+r"\PC\py.ico")), ]) add_data(db, "Icon", @@ -989,8 +989,10 @@ lib.glob("*.gif") lib.add_file("idle.icns") if dir=="command" and parent.physical=="distutils": - lib.add_file("wininst-6.exe") + lib.add_file("wininst-6.0.exe") lib.add_file("wininst-7.1.exe") + lib.add_file("wininst-8.0.exe") + lib.add_file("wininst-9.0.exe") if dir=="setuptools": lib.add_file("cli.exe") lib.add_file("gui.exe") @@ -1008,8 +1010,8 @@ # Add DLLs default_feature.set_current() lib = PyDirectory(db, cab, root, srcdir + "/" + PCBUILD, "DLLs", "DLLS|DLLs") - lib.add_file("py.ico", src="../PC/py.ico") - lib.add_file("pyc.ico", src="../PC/pyc.ico") + lib.add_file("py.ico", src=srcdir+"/PC/py.ico") + lib.add_file("pyc.ico", src=srcdir"/PC/pyc.ico") dlls = [] tclfiles = [] for f in extensions: From python-checkins at python.org Tue Jan 1 14:58:17 2008 From: python-checkins at python.org (christian.heimes) Date: Tue, 1 Jan 2008 14:58:17 +0100 (CET) Subject: [Python-checkins] r59640 - in python/trunk: PC/VS7.1/make_buildinfo.c Tools/msi/msi.py Message-ID: <20080101135817.30A8E1E400E@bag.python.org> Author: christian.heimes Date: Tue Jan 1 14:58:16 2008 New Revision: 59640 Modified: python/trunk/PC/VS7.1/make_buildinfo.c python/trunk/Tools/msi/msi.py Log: The root of the project is two levels up from PC/VS7.1 Modified: python/trunk/PC/VS7.1/make_buildinfo.c ============================================================================== --- python/trunk/PC/VS7.1/make_buildinfo.c (original) +++ python/trunk/PC/VS7.1/make_buildinfo.c Tue Jan 1 14:58:16 2008 @@ -44,7 +44,7 @@ if (_stat(command+1, &st) < 0) /* subwcrev.exe not part of the release */ return 0; - strcat(command, "\" .. ..\\..\\Modules\\getbuildinfo.c getbuildinfo2.c"); + strcat(command, "\" ..\\.. ..\\..\\Modules\\getbuildinfo.c getbuildinfo2.c"); puts(command); fflush(stdout); if (system(command) < 0) return 0; Modified: python/trunk/Tools/msi/msi.py ============================================================================== --- python/trunk/Tools/msi/msi.py (original) +++ python/trunk/Tools/msi/msi.py Tue Jan 1 14:58:16 2008 @@ -1011,7 +1011,7 @@ default_feature.set_current() lib = PyDirectory(db, cab, root, srcdir + "/" + PCBUILD, "DLLs", "DLLS|DLLs") lib.add_file("py.ico", src=srcdir+"/PC/py.ico") - lib.add_file("pyc.ico", src=srcdir"/PC/pyc.ico") + lib.add_file("pyc.ico", src=srcdir+"/PC/pyc.ico") dlls = [] tclfiles = [] for f in extensions: From buildbot at python.org Tue Jan 1 15:11:09 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 01 Jan 2008 14:11:09 +0000 Subject: [Python-checkins] buildbot failure in x86 XP-3 trunk Message-ID: <20080101141109.2D0161E400E@bag.python.org> The Buildbot has detected a new failure of x86 XP-3 trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20XP-3%20trunk/builds/549 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: heller-windows Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_distutils ====================================================================== FAIL: test_get_config_h_filename (distutils.tests.test_sysconfig.SysconfigTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\trunk.heller-windows\build\lib\distutils\tests\test_sysconfig.py", line 14, in test_get_config_h_filename self.assert_(os.path.isfile(config_h), config_h) AssertionError: C:\buildbot\work\trunk.heller-windows\build\include\pyconfig.h sincerely, -The Buildbot From buildbot at python.org Tue Jan 1 15:30:05 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 01 Jan 2008 14:30:05 +0000 Subject: [Python-checkins] buildbot failure in sparc solaris10 gcc trunk Message-ID: <20080101143006.134971E400E@bag.python.org> The Buildbot has detected a new failure of sparc solaris10 gcc trunk. Full details are available at: http://www.python.org/dev/buildbot/all/sparc%20solaris10%20gcc%20trunk/builds/2516 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-sun Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/SocketServer.py", line 523, in __init__ self.handle() File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/socket.py", line 366, in readline data = self._sock.recv(self._rbufsize) error: [Errno 11] Resource temporarily unavailable 1 test failed: test_xmlrpc sincerely, -The Buildbot From python-checkins at python.org Tue Jan 1 15:37:32 2008 From: python-checkins at python.org (christian.heimes) Date: Tue, 1 Jan 2008 15:37:32 +0100 (CET) Subject: [Python-checkins] r59641 - python/trunk/Lib/distutils/sysconfig.py Message-ID: <20080101143732.5DE741E400E@bag.python.org> Author: christian.heimes Date: Tue Jan 1 15:37:32 2008 New Revision: 59641 Modified: python/trunk/Lib/distutils/sysconfig.py Log: Added support for new Windows build dirs in PC/ to distutils.sysconfig Modified: python/trunk/Lib/distutils/sysconfig.py ============================================================================== --- python/trunk/Lib/distutils/sysconfig.py (original) +++ python/trunk/Lib/distutils/sysconfig.py Tue Jan 1 15:37:32 2008 @@ -27,6 +27,10 @@ project_base = os.path.dirname(os.path.abspath(sys.executable)) if os.name == "nt" and "pcbuild" in project_base[-8:].lower(): project_base = os.path.abspath(os.path.join(project_base, os.path.pardir)) +# PC/VS7.1 +if os.name == "nt" and "\\pc\\v" in project_base[-10:].lower(): + project_base = os.path.abspath(os.path.join(project_base, os.path.pardir, + os.path.pardir)) # python_build: (Boolean) if true, we're either building Python or # building an extension with an un-installed Python, so we use From python-checkins at python.org Tue Jan 1 16:39:12 2008 From: python-checkins at python.org (martin.v.loewis) Date: Tue, 1 Jan 2008 16:39:12 +0100 (CET) Subject: [Python-checkins] r59643 - tracker/instances/python-dev/html/issue.item.html Message-ID: <20080101153912.64A7E1E4002@bag.python.org> Author: martin.v.loewis Date: Tue Jan 1 16:39:12 2008 New Revision: 59643 Modified: tracker/instances/python-dev/html/issue.item.html Log: Add file description field. Modified: tracker/instances/python-dev/html/issue.item.html ============================================================================== --- tracker/instances/python-dev/html/issue.item.html (original) +++ tracker/instances/python-dev/html/issue.item.html Tue Jan 1 16:39:12 2008 @@ -165,7 +165,14 @@ File: - + + + + + + + File Description: + From python-checkins at python.org Tue Jan 1 16:47:42 2008 From: python-checkins at python.org (martin.v.loewis) Date: Tue, 1 Jan 2008 16:47:42 +0100 (CET) Subject: [Python-checkins] r59644 - tracker/instances/python-dev/html/issue.search.html Message-ID: <20080101154742.AB9551E4002@bag.python.org> Author: martin.v.loewis Date: Tue Jan 1 16:47:42 2008 New Revision: 59644 Modified: tracker/instances/python-dev/html/issue.search.html Log: Add nosy list entry field. Fixes #145. Modified: tracker/instances/python-dev/html/issue.search.html ============================================================================== --- tracker/instances/python-dev/html/issue.search.html (original) +++ tracker/instances/python-dev/html/issue.search.html Tue Jan 1 16:47:42 2008 @@ -100,6 +100,14 @@   + + Nosy list member: + + + +   + + From python-checkins at python.org Tue Jan 1 17:04:37 2008 From: python-checkins at python.org (martin.v.loewis) Date: Tue, 1 Jan 2008 17:04:37 +0100 (CET) Subject: [Python-checkins] r59645 - tracker/instances/python-dev/extensions/local_replace.py Message-ID: <20080101160437.8671C1E4002@bag.python.org> Author: martin.v.loewis Date: Tue Jan 1 17:04:37 2008 New Revision: 59645 Modified: tracker/instances/python-dev/extensions/local_replace.py Log: Also hyperlink rev. Requested in #154. Modified: tracker/instances/python-dev/extensions/local_replace.py ============================================================================== --- tracker/instances/python-dev/extensions/local_replace.py (original) +++ tracker/instances/python-dev/extensions/local_replace.py Tue Jan 1 17:04:37 2008 @@ -4,6 +4,8 @@ "#\g\g" ), (re.compile('(?P\s+)revision(?P\s*)(?P\d+)'), "\grevision\g\g"), + (re.compile('(?P\s+)rev(?P\s*)(?P\d+)'), + "\grev\g\g"), (re.compile('(?P\s+)(?Pr|r\s+)(?P\d+)'), "\g\g\g"), ] From buildbot at python.org Tue Jan 1 18:09:26 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 01 Jan 2008 17:09:26 +0000 Subject: [Python-checkins] buildbot failure in ppc Debian unstable 3.0 Message-ID: <20080101170926.24C051E4002@bag.python.org> The Buildbot has detected a new failure of ppc Debian unstable 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/ppc%20Debian%20unstable%203.0/builds/422 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: guido.van.rossum BUILD FAILED: failed test Excerpt from the test logfile: 2 tests failed: test_xmlrpc test_xmlrpc_net Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 522, in __init__ self.handle() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/BaseHTTPServer.py", line 330, in handle self.handle_one_request() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/BaseHTTPServer.py", line 324, in handle_one_request method() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SimpleXMLRPCServer.py", line 430, in do_POST self.report_404() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SimpleXMLRPCServer.py", line 489, in report_404 self.connection.shutdown(1) socket.error: [Errno 107] Transport endpoint is not connected ====================================================================== ERROR: test_fail_no_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/test/test_xmlrpc.py", line 497, in test_fail_no_info p.pow(6,8) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1091, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1349, in __request verbose=self.__verbose File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1121, in request resp = http_conn.getresponse() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/httplib.py", line 961, in getresponse response.begin() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/httplib.py", line 425, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/httplib.py", line 267, in readheaders line = str(self.fp.readline(), "iso-8859-1") File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/io.py", line 413, in readline b = self.read(nreadahead()) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/io.py", line 475, in read n = self.readinto(b) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/socket.py", line 217, in readinto return self._sock.recv_into(b) socket.error: [Errno 104] Connection reset by peer ====================================================================== ERROR: test_fail_with_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/test/test_xmlrpc.py", line 515, in test_fail_with_info p.pow(6,8) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1091, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1349, in __request verbose=self.__verbose File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1121, in request resp = http_conn.getresponse() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/httplib.py", line 961, in getresponse response.begin() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/httplib.py", line 425, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/httplib.py", line 267, in readheaders line = str(self.fp.readline(), "iso-8859-1") File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/io.py", line 413, in readline b = self.read(nreadahead()) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/io.py", line 475, in read n = self.readinto(b) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/socket.py", line 217, in readinto return self._sock.recv_into(b) socket.error: [Errno 104] Connection reset by peer make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Tue Jan 1 22:05:17 2008 From: python-checkins at python.org (martin.v.loewis) Date: Tue, 1 Jan 2008 22:05:17 +0100 (CET) Subject: [Python-checkins] r59653 - python/trunk/Modules/_tkinter.c Message-ID: <20080101210517.C2C781E401F@bag.python.org> Author: martin.v.loewis Date: Tue Jan 1 22:05:17 2008 New Revision: 59653 Modified: python/trunk/Modules/_tkinter.c Log: Return results from Python callbacks to Tcl as Tcl objects. Fixes Tk issue #1851526 Modified: python/trunk/Modules/_tkinter.c ============================================================================== --- python/trunk/Modules/_tkinter.c (original) +++ python/trunk/Modules/_tkinter.c Tue Jan 1 22:05:17 2008 @@ -1992,9 +1992,9 @@ PythonCmd(ClientData clientData, Tcl_Interp *interp, int argc, char *argv[]) { PythonCmd_ClientData *data = (PythonCmd_ClientData *)clientData; - PyObject *self, *func, *arg, *res, *tmp; + PyObject *self, *func, *arg, *res; int i, rv; - char *s; + Tcl_Obj *obj_res; ENTER_PYTHON @@ -2021,24 +2021,17 @@ if (res == NULL) return PythonCmd_Error(interp); - if (!(tmp = PyList_New(0))) { + obj_res = AsObj(res); + if (obj_res == NULL) { Py_DECREF(res); return PythonCmd_Error(interp); } - - s = AsString(res, tmp); - if (s == NULL) { - Py_DECREF(res); - Py_DECREF(tmp); - return PythonCmd_Error(interp); - } else { - Tcl_SetResult(Tkapp_Interp(self), s, TCL_VOLATILE); + Tcl_SetObjResult(Tkapp_Interp(self), obj_res); rv = TCL_OK; } Py_DECREF(res); - Py_DECREF(tmp); LEAVE_PYTHON From python-checkins at python.org Tue Jan 1 22:08:18 2008 From: python-checkins at python.org (martin.v.loewis) Date: Tue, 1 Jan 2008 22:08:18 +0100 (CET) Subject: [Python-checkins] r59654 - python/trunk/Lib/lib-tk/Tkinter.py Message-ID: <20080101210818.A18FD1E400E@bag.python.org> Author: martin.v.loewis Date: Tue Jan 1 22:08:18 2008 New Revision: 59654 Modified: python/trunk/Lib/lib-tk/Tkinter.py Log: Always convert Text.index result to string. This improves compatibility with Tcl 8.5, which would otherwise return textindex objects. Modified: python/trunk/Lib/lib-tk/Tkinter.py ============================================================================== --- python/trunk/Lib/lib-tk/Tkinter.py (original) +++ python/trunk/Lib/lib-tk/Tkinter.py Tue Jan 1 22:08:18 2008 @@ -2981,7 +2981,7 @@ return self.tk.call(self._w, "image", "names") def index(self, index): """Return the index in the form line.char for INDEX.""" - return self.tk.call(self._w, 'index', index) + return str(self.tk.call(self._w, 'index', index)) def insert(self, index, chars, *args): """Insert CHARS before the characters at INDEX. An additional tag can be given in ARGS. Additional CHARS and tags can follow in ARGS.""" From python-checkins at python.org Tue Jan 1 22:09:07 2008 From: python-checkins at python.org (martin.v.loewis) Date: Tue, 1 Jan 2008 22:09:07 +0100 (CET) Subject: [Python-checkins] r59655 - python/trunk/Misc/NEWS Message-ID: <20080101210907.BC7F21E4002@bag.python.org> Author: martin.v.loewis Date: Tue Jan 1 22:09:07 2008 New Revision: 59655 Modified: python/trunk/Misc/NEWS Log: News item for r59653. Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Tue Jan 1 22:09:07 2008 @@ -342,6 +342,9 @@ Library ------- +- Tk issue #1851526: Return results from Python callbacks to Tcl as + Tcl objects. + - Issue #1642: Fix segfault in ctypes when trying to delete attributes. - Issue #1727780: Support loading pickles of random.Random objects created From buildbot at python.org Tue Jan 1 22:17:08 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 01 Jan 2008 21:17:08 +0000 Subject: [Python-checkins] buildbot failure in alpha Tru64 5.1 trunk Message-ID: <20080101211708.98C531E4002@bag.python.org> The Buildbot has detected a new failure of alpha Tru64 5.1 trunk. Full details are available at: http://www.python.org/dev/buildbot/all/alpha%20Tru64%205.1%20trunk/builds/2182 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-tru64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: martin.v.loewis BUILD FAILED: failed test Excerpt from the test logfile: sincerely, -The Buildbot From buildbot at python.org Tue Jan 1 23:00:31 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 01 Jan 2008 22:00:31 +0000 Subject: [Python-checkins] buildbot failure in x86 gentoo trunk Message-ID: <20080101220031.BCF991E4020@bag.python.org> The Buildbot has detected a new failure of x86 gentoo trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20gentoo%20trunk/builds/2778 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-x86 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: martin.v.loewis BUILD FAILED: failed test Excerpt from the test logfile: sincerely, -The Buildbot From python-checkins at python.org Wed Jan 2 00:00:00 2008 From: python-checkins at python.org (martin.v.loewis) Date: Wed, 2 Jan 2008 00:00:00 +0100 (CET) Subject: [Python-checkins] r59656 - python/trunk/PCbuild/pyproject.vsprops Message-ID: <20080101230000.D2EDC1E4002@bag.python.org> Author: martin.v.loewis Date: Wed Jan 2 00:00:00 2008 New Revision: 59656 Modified: python/trunk/PCbuild/pyproject.vsprops Log: Don't link with Tix; Tix is loaded dynamically by Tcl. Modified: python/trunk/PCbuild/pyproject.vsprops ============================================================================== --- python/trunk/PCbuild/pyproject.vsprops (original) +++ python/trunk/PCbuild/pyproject.vsprops Wed Jan 2 00:00:00 2008 @@ -70,10 +70,10 @@ /> From python-checkins at python.org Wed Jan 2 00:00:49 2008 From: python-checkins at python.org (martin.v.loewis) Date: Wed, 2 Jan 2008 00:00:49 +0100 (CET) Subject: [Python-checkins] r59657 - python/trunk/Tools/buildbot/build.bat python/trunk/Tools/buildbot/buildmsi.bat python/trunk/Tools/buildbot/clean-amd64.bat python/trunk/Tools/buildbot/clean.bat python/trunk/Tools/buildbot/external.bat python/trunk/Tools/buildbot/kill_python.c Message-ID: <20080101230049.C9D0B1E4014@bag.python.org> Author: martin.v.loewis Date: Wed Jan 2 00:00:48 2008 New Revision: 59657 Modified: python/trunk/Tools/buildbot/build.bat python/trunk/Tools/buildbot/buildmsi.bat python/trunk/Tools/buildbot/clean-amd64.bat python/trunk/Tools/buildbot/clean.bat python/trunk/Tools/buildbot/external.bat python/trunk/Tools/buildbot/kill_python.c Log: Use Visual Studio 2009 on the build slaves. Modified: python/trunk/Tools/buildbot/build.bat ============================================================================== --- python/trunk/Tools/buildbot/build.bat (original) +++ python/trunk/Tools/buildbot/build.bat Wed Jan 2 00:00:48 2008 @@ -1,5 +1,6 @@ @rem Used by the buildbot "compile" step. cmd /c Tools\buildbot\external.bat -call "%VS71COMNTOOLS%vsvars32.bat" +call "%VS90COMNTOOLS%vsvars32.bat" cmd /q/c Tools\buildbot\kill_python.bat -devenv.com /useenv /build Debug PC\VS7.1\pcbuild.sln +vcbuild /useenv PCbuild\pcbuild.sln "Debug|Win32" + Modified: python/trunk/Tools/buildbot/buildmsi.bat ============================================================================== --- python/trunk/Tools/buildbot/buildmsi.bat (original) +++ python/trunk/Tools/buildbot/buildmsi.bat Wed Jan 2 00:00:48 2008 @@ -2,14 +2,14 @@ cmd /c Tools\buildbot\external.bat @rem build release versions of things -call "%VS71COMNTOOLS%vsvars32.bat" +call "%VS90COMNTOOLS%vsvars32.bat" if not exist ..\db-4.4.20\build_win32\release\libdb44s.lib ( devenv ..\db-4.4.20\build_win32\Berkeley_DB.sln /build Release /project db_static ) @rem build Python cmd /q/c Tools\buildbot\kill_python.bat -devenv.com /useenv /build Release PC\VS7.1\pcbuild.sln +devenv.com /useenv /build Release PCbuild\pcbuild.sln @rem build the documentation bash.exe -c 'cd Doc;make PYTHON=python2.5 update htmlhelp' Modified: python/trunk/Tools/buildbot/clean-amd64.bat ============================================================================== --- python/trunk/Tools/buildbot/clean-amd64.bat (original) +++ python/trunk/Tools/buildbot/clean-amd64.bat Wed Jan 2 00:00:48 2008 @@ -2,5 +2,5 @@ call "%VS71COMNTOOLS%vsvars32.bat" cd PC\VS7.1 @echo Deleting .pyc/.pyo files ... -python.exe rmpyc.py +del /s Lib\*.pyc Lib\*.pyo devenv.com /clean ReleaseAMD64 pcbuild.sln Modified: python/trunk/Tools/buildbot/clean.bat ============================================================================== --- python/trunk/Tools/buildbot/clean.bat (original) +++ python/trunk/Tools/buildbot/clean.bat Wed Jan 2 00:00:48 2008 @@ -1,7 +1,7 @@ @rem Used by the buildbot "clean" step. -call "%VS71COMNTOOLS%vsvars32.bat" -cd PC\VS7.1 +call "%VS90COMNTOOLS%vsvars32.bat" +cd PCbuild @echo Deleting .pyc/.pyo files ... -python_d.exe rmpyc.py -devenv.com /clean Release pcbuild.sln -devenv.com /clean Debug pcbuild.sln +del /s Lib\*.pyc Lib\*.pyo +vcbuild /clean pcbuild.sln "Release|Win32" +vcbuild /clean pcbuild.sln "Debug|Win32" Modified: python/trunk/Tools/buildbot/external.bat ============================================================================== --- python/trunk/Tools/buildbot/external.bat (original) +++ python/trunk/Tools/buildbot/external.bat Wed Jan 2 00:00:48 2008 @@ -2,7 +2,7 @@ @rem Assume we start inside the Python source directory cd .. -call "%VS71COMNTOOLS%vsvars32.bat" +call "%VS90COMNTOOLS%vsvars32.bat" @rem bzip if not exist bzip2-1.0.3 svn export http://svn.python.org/projects/external/bzip2-1.0.3 @@ -10,24 +10,29 @@ @rem Sleepycat db if not exist db-4.4.20 svn export http://svn.python.org/projects/external/db-4.4.20 if not exist db-4.4.20\build_win32\debug\libdb44sd.lib ( - devenv db-4.4.20\build_win32\Berkeley_DB.sln /build Debug /project db_static + vcbuild db-4.4.20\build_win32\Berkeley_DB.sln /build Debug /project db_static ) @rem OpenSSL -if not exist openssl-0.9.8a svn export http://svn.python.org/projects/external/openssl-0.9.8a +if not exist openssl-0.9.8g ( + if exist openssl-0.9.8a rd /s/q openssl-0.9.8a + svn export http://svn.python.org/projects/external/openssl-0.9.8g +) @rem tcltk -if not exist tcl8.4.12 ( +if not exist tcl8.4.16 ( if exist tcltk rd /s/q tcltk - svn export http://svn.python.org/projects/external/tcl8.4.12 - svn export http://svn.python.org/projects/external/tk8.4.12 - cd tcl8.4.12\win - nmake -f makefile.vc - nmake -f makefile.vc INSTALLDIR=..\..\tcltk install + if exist tcl8.4.12 rd /s/q tcl8.4.12 + if exist tk8.4.12 rd /s/q tk8.4.12 + svn export http://svn.python.org/projects/external/tcl8.4.16 + svn export http://svn.python.org/projects/external/tk8.4.16 + cd tcl8.4.16\win + nmake -f makefile.vc COMPILERFLAGS=-DWINVER=0x0500 + nmake -f makefile.vc COMPILERFLAGS=-DWINVER=0x0500 INSTALLDIR=..\..\tcltk install cd ..\.. - cd tk8.4.12\win - nmake -f makefile.vc TCLDIR=..\..\tcl8.4.12 - nmake -f makefile.vc TCLDIR=..\..\tcl8.4.12 INSTALLDIR=..\..\tcltk install + cd tk8.4.16\win + nmake -f makefile.vc COMPILERFLAGS=-DWINVER=0x0500 TCLDIR=..\..\tcl8.4.16 + nmake -f makefile.vc COMPILERFLAGS=-DWINVER=0x0500 TCLDIR=..\..\tcl8.4.16 INSTALLDIR=..\..\tcltk install cd ..\.. ) Modified: python/trunk/Tools/buildbot/kill_python.c ============================================================================== --- python/trunk/Tools/buildbot/kill_python.c (original) +++ python/trunk/Tools/buildbot/kill_python.c Wed Jan 2 00:00:48 2008 @@ -1,4 +1,4 @@ -/* This program looks for processes which have build\PC\VS7.1\python.exe +/* This program looks for processes which have build\PCbuild\python.exe in their path and terminates them. */ #include #include @@ -46,14 +46,14 @@ /* Check if we are running a buildbot version of Python. On Windows, this will always be a debug build from the - PC\VS7.1 directory. build\\PC\\VS7.1\\python_d.exe + PCbuild directory. build\\PCbuild\\python_d.exe On Cygwin, the pathname is similar to other Unixes. Use \\build\\python.exe to ensure we don't match - PC\\VS7.1\\python.exe which could be a normal instance + PCbuild\\python.exe which could be a normal instance of Python running on vanilla Windows. */ - if ((strstr(path, "build\\pc\\vs7.1\\python_d.exe") != NULL) || + if ((strstr(path, "pcbuild\\python_d.exe") != NULL) || (strstr(path, "\\build\\python.exe") != NULL)) { printf("Terminating %s (pid %d)\n", path, pids[i]); if (!TerminateProcess(hProcess, 1)) { From buildbot at python.org Wed Jan 2 00:10:24 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 01 Jan 2008 23:10:24 +0000 Subject: [Python-checkins] buildbot failure in x86 XP-3 trunk Message-ID: <20080101231025.3A9CA1E4004@bag.python.org> The Buildbot has detected a new failure of x86 XP-3 trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20XP-3%20trunk/builds/553 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: heller-windows Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: martin.v.loewis BUILD FAILED: failed compile sincerely, -The Buildbot From buildbot at python.org Wed Jan 2 00:32:13 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 01 Jan 2008 23:32:13 +0000 Subject: [Python-checkins] buildbot failure in x86 XP-4 trunk Message-ID: <20080101233213.4CC281E4002@bag.python.org> The Buildbot has detected a new failure of x86 XP-4 trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20XP-4%20trunk/builds/353 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-windows Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: martin.v.loewis BUILD FAILED: failed test Excerpt from the test logfile: sincerely, -The Buildbot From python-checkins at python.org Wed Jan 2 00:36:24 2008 From: python-checkins at python.org (martin.v.loewis) Date: Wed, 2 Jan 2008 00:36:24 +0100 (CET) Subject: [Python-checkins] r59658 - python/trunk/Tools/buildbot/test.bat Message-ID: <20080101233624.DC1B81E4018@bag.python.org> Author: martin.v.loewis Date: Wed Jan 2 00:36:24 2008 New Revision: 59658 Modified: python/trunk/Tools/buildbot/test.bat Log: Test in PCbuild directory. Modified: python/trunk/Tools/buildbot/test.bat ============================================================================== --- python/trunk/Tools/buildbot/test.bat (original) +++ python/trunk/Tools/buildbot/test.bat Wed Jan 2 00:36:24 2008 @@ -1,3 +1,3 @@ @rem Used by the buildbot "test" step. -cd PC\VS7.1 +cd PCbuild call rt.bat -d -q -uall -rw From buildbot at python.org Wed Jan 2 02:01:31 2008 From: buildbot at python.org (buildbot at python.org) Date: Wed, 02 Jan 2008 01:01:31 +0000 Subject: [Python-checkins] buildbot failure in hppa Ubuntu trunk Message-ID: <20080102010131.A3AD41E4002@bag.python.org> The Buildbot has detected a new failure of hppa Ubuntu trunk. Full details are available at: http://www.python.org/dev/buildbot/all/hppa%20Ubuntu%20trunk/builds/436 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-ubuntu-hppa Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: martin.v.loewis BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_bsddb3 ====================================================================== ERROR: test00_associateDBError (bsddb.test.test_associate.AssociateErrorTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 104, in setUp self.env.open(homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateBTreeTxnTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateBTreeTxnTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test13_associate_in_transaction (bsddb.test.test_associate.AssociateBTreeTxnTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ShelveAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ShelveAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ShelveAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ThreadedAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ThreadedAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ThreadedAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ThreadedAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ThreadedAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ThreadedAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_EnvRemoveAndRename (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_EnvRemoveAndRename (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Transactions (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_TxnTruncate (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test08_TxnLateUse (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Transactions (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_TxnTruncate (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test08_TxnLateUse (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test09_MultiDB (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test09_MultiDB (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_both (bsddb.test.test_dbobj.dbobjTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbobj.py", line 45, in test01_both self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbobj.py", line 39, in open return apply(self._cobj.open, args, kwargs) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_dbobj_dict_interface (bsddb.test.test_dbobj.dbobjTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbobj.py", line 58, in test02_dbobj_dict_interface self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbobj.py", line 39, in open return apply(self._cobj.open, args, kwargs) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01 (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02 (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03 (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_MultiCondSelect (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_CondObjs (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_CreateOrExtend (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_Delete (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_Modify (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_close_dbenv_before_db (bsddb.test.test_env_close.DBEnvClosedEarlyCrash) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_env_close.py", line 53, in test01_close_dbenv_before_db 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_close_dbenv_delete_db_success (bsddb.test.test_env_close.DBEnvClosedEarlyCrash) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_env_close.py", line 78, in test02_close_dbenv_delete_db_success 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_join (bsddb.test.test_join.JoinTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_join.py", line 57, in setUp self.env.open(homeDir, db.DB_CREATE | db.DB_INIT_MPOOL | db.DB_INIT_LOCK ) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_simple (bsddb.test.test_lock.LockingTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_lock.py", line 38, in setUp db.DB_INIT_LOCK | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_threaded (bsddb.test.test_lock.LockingTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_lock.py", line 38, in setUp db.DB_INIT_LOCK | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_set_timeout (bsddb.test.test_lock.LockingTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_lock.py", line 38, in setUp db.DB_INIT_LOCK | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_db_home (bsddb.test.test_misc.MiscTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_misc.py", line 45, in test02_db_home env.open(self.homeDir, db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_1WriterMultiReaders (bsddb.test.test_thread.BTreeConcurrentDataStore) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_1WriterMultiReaders (bsddb.test.test_thread.HashConcurrentDataStore) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_SimpleLocks (bsddb.test.test_thread.BTreeSimpleThreaded) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_SimpleLocks (bsddb.test.test_thread.HashSimpleThreaded) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.BTreeThreadedTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.HashThreadedTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.BTreeThreadedNoWaitTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.HashThreadedNoWaitTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_cachesize (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_flags (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_get (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_get_dbp (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_get_key (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_range (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_remove (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_stat (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_pget (bsddb.test.test_cursor_pget_bug.pget_bugTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_cursor_pget_bug.py", line 25, in setUp self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Wed Jan 2 04:53:47 2008 From: buildbot at python.org (buildbot at python.org) Date: Wed, 02 Jan 2008 03:53:47 +0000 Subject: [Python-checkins] buildbot failure in g4 osx.4 3.0 Message-ID: <20080102035347.B15021E4002@bag.python.org> The Buildbot has detected a new failure of g4 osx.4 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/g4%20osx.4%203.0/builds/398 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: psf-g4 Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: guido.van.rossum BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_asynchat make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Wed Jan 2 05:11:29 2008 From: python-checkins at python.org (kurt.kaiser) Date: Wed, 2 Jan 2008 05:11:29 +0100 (CET) Subject: [Python-checkins] r59661 - in python/trunk/Lib: test/test_urllib.py urllib.py Message-ID: <20080102041129.663C01E4002@bag.python.org> Author: kurt.kaiser Date: Wed Jan 2 05:11:28 2008 New Revision: 59661 Modified: python/trunk/Lib/test/test_urllib.py python/trunk/Lib/urllib.py Log: Issue1177 r58207 and r58247 patch logic is reversed. I noticed this when I tried to use urllib to retrieve a file which required auth. Fix that and add a test for 401 error to verify. Modified: python/trunk/Lib/test/test_urllib.py ============================================================================== --- python/trunk/Lib/test/test_urllib.py (original) +++ python/trunk/Lib/test/test_urllib.py Wed Jan 2 05:11:28 2008 @@ -126,6 +126,19 @@ finally: self.unfakehttp() + def test_read_bogus(self): + "urlopen() should raise IOError for many error codes." + self.fakehttp('''HTTP/1.1 401 Authentication Required +Date: Wed, 02 Jan 2008 03:03:54 GMT +Server: Apache/1.3.33 (Debian GNU/Linux) mod_ssl/2.8.22 OpenSSL/0.9.7e +Connection: close +Content-Type: text/html; charset=iso-8859-1 +''') + try: + self.assertRaises(IOError, urllib.urlopen, "http://python.org/") + finally: + self.unfakehttp() + def test_empty_socket(self): """urlopen() raises IOError if the underlying socket does not send any data. (#1680230) """ Modified: python/trunk/Lib/urllib.py ============================================================================== --- python/trunk/Lib/urllib.py (original) +++ python/trunk/Lib/urllib.py Wed Jan 2 05:11:28 2008 @@ -342,7 +342,7 @@ 'got a bad status line', None) # According to RFC 2616, "2xx" code indicates that the client's # request was successfully received, understood, and accepted. - if not (200 <= errcode < 300): + if (200 <= errcode < 300): return addinfourl(fp, headers, "http:" + url) else: if data is None: @@ -437,7 +437,7 @@ 'got a bad status line', None) # According to RFC 2616, "2xx" code indicates that the client's # request was successfully received, understood, and accepted. - if not (200 <= errcode < 300): + if (200 <= errcode < 300): return addinfourl(fp, headers, "https:" + url) else: if data is None: From python-checkins at python.org Wed Jan 2 06:23:39 2008 From: python-checkins at python.org (kurt.kaiser) Date: Wed, 2 Jan 2008 06:23:39 +0100 (CET) Subject: [Python-checkins] r59662 - python/trunk/Lib/test/test_urllib.py Message-ID: <20080102052339.469941E4002@bag.python.org> Author: kurt.kaiser Date: Wed Jan 2 06:23:38 2008 New Revision: 59662 Modified: python/trunk/Lib/test/test_urllib.py Log: Change docstrings to comments so test output will display normally. Modified: python/trunk/Lib/test/test_urllib.py ============================================================================== --- python/trunk/Lib/test/test_urllib.py (original) +++ python/trunk/Lib/test/test_urllib.py Wed Jan 2 06:23:38 2008 @@ -127,7 +127,7 @@ self.unfakehttp() def test_read_bogus(self): - "urlopen() should raise IOError for many error codes." + # urlopen() should raise IOError for many error codes. self.fakehttp('''HTTP/1.1 401 Authentication Required Date: Wed, 02 Jan 2008 03:03:54 GMT Server: Apache/1.3.33 (Debian GNU/Linux) mod_ssl/2.8.22 OpenSSL/0.9.7e @@ -140,8 +140,8 @@ self.unfakehttp() def test_empty_socket(self): - """urlopen() raises IOError if the underlying socket does not send any - data. (#1680230) """ + # urlopen() raises IOError if the underlying socket does not send any + # data. (#1680230) self.fakehttp('') try: self.assertRaises(IOError, urllib.urlopen, 'http://something') From buildbot at python.org Wed Jan 2 06:28:43 2008 From: buildbot at python.org (buildbot at python.org) Date: Wed, 02 Jan 2008 05:28:43 +0000 Subject: [Python-checkins] buildbot failure in x86 gentoo trunk Message-ID: <20080102052843.7E2691E4002@bag.python.org> The Buildbot has detected a new failure of x86 gentoo trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20gentoo%20trunk/builds/2782 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-x86 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: kurt.kaiser BUILD FAILED: failed svn sincerely, -The Buildbot From buildbot at python.org Wed Jan 2 06:28:50 2008 From: buildbot at python.org (buildbot at python.org) Date: Wed, 02 Jan 2008 05:28:50 +0000 Subject: [Python-checkins] buildbot failure in sparc solaris10 gcc trunk Message-ID: <20080102052850.7AE0B1E4002@bag.python.org> The Buildbot has detected a new failure of sparc solaris10 gcc trunk. Full details are available at: http://www.python.org/dev/buildbot/all/sparc%20solaris10%20gcc%20trunk/builds/2523 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-sun Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: kurt.kaiser BUILD FAILED: failed svn sincerely, -The Buildbot From buildbot at python.org Wed Jan 2 06:34:33 2008 From: buildbot at python.org (buildbot at python.org) Date: Wed, 02 Jan 2008 05:34:33 +0000 Subject: [Python-checkins] buildbot failure in x86 FreeBSD trunk Message-ID: <20080102053433.4118F1E4002@bag.python.org> The Buildbot has detected a new failure of x86 FreeBSD trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20FreeBSD%20trunk/builds/315 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-freebsd Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: kurt.kaiser BUILD FAILED: failed svn sincerely, -The Buildbot From buildbot at python.org Wed Jan 2 06:43:22 2008 From: buildbot at python.org (buildbot at python.org) Date: Wed, 02 Jan 2008 05:43:22 +0000 Subject: [Python-checkins] buildbot failure in g4 osx.4 trunk Message-ID: <20080102054322.819421E4002@bag.python.org> The Buildbot has detected a new failure of g4 osx.4 trunk. Full details are available at: http://www.python.org/dev/buildbot/all/g4%20osx.4%20trunk/builds/2524 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: psf-g4 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: kurt.kaiser BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_ssl ====================================================================== ERROR: testSSLconnect (test.test_ssl.BasicTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/test/test_ssl.py", line 43, in testSSLconnect s.connect(("svn.python.org", 443)) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/ssl.py", line 201, in connect socket.connect(self, addr) File "", line 1, in connect error: [Errno 61] Connection refused ====================================================================== ERROR: testConnect (test.test_ssl.NetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/test/test_ssl.py", line 107, in testConnect s.connect(("svn.python.org", 443)) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/ssl.py", line 201, in connect socket.connect(self, addr) File "", line 1, in connect error: [Errno 61] Connection refused ====================================================================== ERROR: testFetchServerCert (test.test_ssl.NetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/test/test_ssl.py", line 136, in testFetchServerCert pem = ssl.get_server_certificate(("svn.python.org", 443)) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/ssl.py", line 526, in get_server_certificate s.connect(addr) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/ssl.py", line 201, in connect socket.connect(self, addr) File "", line 1, in connect error: [Errno 61] Connection refused make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Wed Jan 2 07:15:11 2008 From: buildbot at python.org (buildbot at python.org) Date: Wed, 02 Jan 2008 06:15:11 +0000 Subject: [Python-checkins] buildbot failure in ia64 Ubuntu trunk Message-ID: <20080102061511.625051E4002@bag.python.org> The Buildbot has detected a new failure of ia64 Ubuntu trunk. Full details are available at: http://www.python.org/dev/buildbot/all/ia64%20Ubuntu%20trunk/builds/1198 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ia64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: kurt.kaiser BUILD FAILED: failed test Excerpt from the test logfile: 2 tests failed: test_socket_ssl test_ssl ====================================================================== ERROR: test_978833 (test.test_socket_ssl.BasicTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ia64/build/Lib/test/test_socket_ssl.py", line 123, in test_978833 raise test_support.TestFailed("Failed to close socket") File "/home/pybot/buildarea/trunk.klose-debian-ia64/build/Lib/contextlib.py", line 33, in __exit__ self.gen.throw(type, value, traceback) File "/home/pybot/buildarea/trunk.klose-debian-ia64/build/Lib/contextlib.py", line 117, in nested yield vars File "/home/pybot/buildarea/trunk.klose-debian-ia64/build/Lib/test/test_socket_ssl.py", line 113, in test_978833 s.connect(("svn.python.org", 443)) File "", line 1, in connect error: [Errno 110] Connection timed out ====================================================================== ERROR: testSSLconnect (test.test_ssl.BasicTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ia64/build/Lib/test/test_ssl.py", line 43, in testSSLconnect s.connect(("svn.python.org", 443)) File "/home/pybot/buildarea/trunk.klose-debian-ia64/build/Lib/ssl.py", line 201, in connect socket.connect(self, addr) File "", line 1, in connect error: [Errno 110] Connection timed out ====================================================================== ERROR: testConnect (test.test_ssl.NetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ia64/build/Lib/test/test_ssl.py", line 107, in testConnect s.connect(("svn.python.org", 443)) File "/home/pybot/buildarea/trunk.klose-debian-ia64/build/Lib/ssl.py", line 201, in connect socket.connect(self, addr) File "", line 1, in connect error: [Errno 110] Connection timed out ====================================================================== ERROR: testFetchServerCert (test.test_ssl.NetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ia64/build/Lib/test/test_ssl.py", line 136, in testFetchServerCert pem = ssl.get_server_certificate(("svn.python.org", 443)) File "/home/pybot/buildarea/trunk.klose-debian-ia64/build/Lib/ssl.py", line 526, in get_server_certificate s.connect(addr) File "/home/pybot/buildarea/trunk.klose-debian-ia64/build/Lib/ssl.py", line 201, in connect socket.connect(self, addr) File "", line 1, in connect error: [Errno 110] Connection timed out make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Wed Jan 2 13:11:43 2008 From: buildbot at python.org (buildbot at python.org) Date: Wed, 02 Jan 2008 12:11:43 +0000 Subject: [Python-checkins] buildbot failure in 2.6.msi Message-ID: <20080102121143.2DF821E4016@bag.python.org> The Buildbot has detected a new failure of 2.6.msi. Full details are available at: http://www.python.org/dev/buildbot/all/2.6.msi/builds/123 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-windows Build Reason: The Nightly scheduler named '2.6.msi' triggered this build Build Source Stamp: HEAD Blamelist: BUILD FAILED: failed compile sincerely, -The Buildbot From buildbot at python.org Wed Jan 2 13:36:43 2008 From: buildbot at python.org (buildbot at python.org) Date: Wed, 02 Jan 2008 12:36:43 +0000 Subject: [Python-checkins] buildbot failure in x86 XP-3 trunk Message-ID: <20080102123643.E16611E4004@bag.python.org> The Buildbot has detected a new failure of x86 XP-3 trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20XP-3%20trunk/builds/558 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: heller-windows Build Reason: The web-page 'force build' button was pressed by 'theller': Build Source Stamp: [branch trunk] HEAD Blamelist: BUILD FAILED: failed compile sincerely, -The Buildbot From buildbot at python.org Wed Jan 2 14:06:54 2008 From: buildbot at python.org (buildbot at python.org) Date: Wed, 02 Jan 2008 13:06:54 +0000 Subject: [Python-checkins] buildbot failure in amd64 XP 3.0 Message-ID: <20080102130654.326161E4010@bag.python.org> The Buildbot has detected a new failure of amd64 XP 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/amd64%20XP%203.0/builds/436 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: heller-windows-amd64 Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes BUILD FAILED: failed compile sincerely, -The Buildbot From python-checkins at python.org Wed Jan 2 18:43:42 2008 From: python-checkins at python.org (christian.heimes) Date: Wed, 2 Jan 2008 18:43:42 +0100 (CET) Subject: [Python-checkins] r59665 - in python/trunk: Misc/NEWS PC/VS8.0 PC/VS8.0/_bsddb.vcproj PC/VS8.0/_ctypes.vcproj PC/VS8.0/_ctypes_test.vcproj PC/VS8.0/_elementtree.vcproj PC/VS8.0/_msi.vcproj PC/VS8.0/_socket.vcproj PC/VS8.0/_sqlite3.vcproj PC/VS8.0/_ssl.vcproj PC/VS8.0/_testcapi.vcproj PC/VS8.0/_tkinter.vcproj PC/VS8.0/bdist_wininst.vcproj PC/VS8.0/build.bat PC/VS8.0/build_env.bat PC/VS8.0/build_pgo.bat PC/VS8.0/build_ssl.bat PC/VS8.0/build_ssl.py PC/VS8.0/build_tkinter.py PC/VS8.0/bz2.vcproj PC/VS8.0/debug.vsprops PC/VS8.0/env.bat PC/VS8.0/field3.py PC/VS8.0/idle.bat PC/VS8.0/make_buildinfo.c PC/VS8.0/make_buildinfo.vcproj PC/VS8.0/make_versioninfo.vcproj PC/VS8.0/pcbuild.sln PC/VS8.0/pginstrument.vsprops PC/VS8.0/pgupdate.vsprops PC/VS8.0/pyd.vsprops PC/VS8.0/pyd_d.vsprops PC/VS8.0/pyexpat.vcproj PC/VS8.0/pyproject.vsprops PC/VS8.0/python.vcproj PC/VS8.0/pythoncore.vcproj PC/VS8.0/pythonw.vcproj PC/VS8.0/release.vsprops PC/VS8.0/rmpyc.py PC/VS8.0/rt.bat PC/VS8.0/select.vcproj PC/VS8.0/unicodedata.vcproj PC/VS8.0/w9xpopen.vcproj PC/VS8.0/winsound.vcproj PC/VS8.0/x64.vsprops PCbuild/readme.txt PCbuild/vs9to8.py PCbuild8 Message-ID: <20080102174342.C49301E4004@bag.python.org> Author: christian.heimes Date: Wed Jan 2 18:43:40 2008 New Revision: 59665 Added: python/trunk/PC/VS8.0/ (props changed) python/trunk/PC/VS8.0/_bsddb.vcproj python/trunk/PC/VS8.0/_ctypes.vcproj python/trunk/PC/VS8.0/_ctypes_test.vcproj python/trunk/PC/VS8.0/_elementtree.vcproj python/trunk/PC/VS8.0/_msi.vcproj python/trunk/PC/VS8.0/_socket.vcproj python/trunk/PC/VS8.0/_sqlite3.vcproj python/trunk/PC/VS8.0/_ssl.vcproj python/trunk/PC/VS8.0/_testcapi.vcproj python/trunk/PC/VS8.0/_tkinter.vcproj python/trunk/PC/VS8.0/bdist_wininst.vcproj python/trunk/PC/VS8.0/build.bat python/trunk/PC/VS8.0/build_env.bat python/trunk/PC/VS8.0/build_pgo.bat python/trunk/PC/VS8.0/build_ssl.bat python/trunk/PC/VS8.0/build_ssl.py (contents, props changed) python/trunk/PC/VS8.0/build_tkinter.py (contents, props changed) python/trunk/PC/VS8.0/bz2.vcproj python/trunk/PC/VS8.0/debug.vsprops python/trunk/PC/VS8.0/env.bat python/trunk/PC/VS8.0/field3.py (contents, props changed) python/trunk/PC/VS8.0/idle.bat python/trunk/PC/VS8.0/make_buildinfo.c (contents, props changed) python/trunk/PC/VS8.0/make_buildinfo.vcproj python/trunk/PC/VS8.0/make_versioninfo.vcproj python/trunk/PC/VS8.0/pcbuild.sln python/trunk/PC/VS8.0/pginstrument.vsprops python/trunk/PC/VS8.0/pgupdate.vsprops python/trunk/PC/VS8.0/pyd.vsprops python/trunk/PC/VS8.0/pyd_d.vsprops python/trunk/PC/VS8.0/pyexpat.vcproj python/trunk/PC/VS8.0/pyproject.vsprops python/trunk/PC/VS8.0/python.vcproj python/trunk/PC/VS8.0/pythoncore.vcproj python/trunk/PC/VS8.0/pythonw.vcproj python/trunk/PC/VS8.0/release.vsprops python/trunk/PC/VS8.0/rmpyc.py (contents, props changed) python/trunk/PC/VS8.0/rt.bat python/trunk/PC/VS8.0/select.vcproj python/trunk/PC/VS8.0/unicodedata.vcproj python/trunk/PC/VS8.0/w9xpopen.vcproj python/trunk/PC/VS8.0/winsound.vcproj python/trunk/PC/VS8.0/x64.vsprops python/trunk/PCbuild/vs9to8.py (contents, props changed) Removed: python/trunk/PCbuild8/ Modified: python/trunk/Misc/NEWS python/trunk/PCbuild/readme.txt Log: Removed PCbuild8/ directory and added a new build directory for VS 2005 based on the VS 2008 build directory to PC/VS8.0. The script PCbuild/vs8to9.py was added to sync changes from PCbuild to PC/VS8.0. Kristjan, the initial creator of the PCbuild8 directory is fine with the replacement. I've moved the new version of the VS 2005 build directory next to the other legacy build directories. The new sync script is based on the work of wreck and syncs changes in the project, property and solution files. Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Wed Jan 2 18:43:40 2008 @@ -12,6 +12,10 @@ Core and builtins ----------------- +- Removed PCbuild8/ directory and added a new build directory for VS 2005 + based on the VS 2008 build directory to PC/VS8.0. The script + PCbuild/vs8to9.py was added to sync changes from PCbuild to PC/VS8.0. + - Moved PCbuild/ directory for VS 2003 to PC/VS7.1 and renamed PCBuild9/ directory to PCBuild/. Added: python/trunk/PC/VS8.0/_bsddb.vcproj ============================================================================== --- (empty file) +++ python/trunk/PC/VS8.0/_bsddb.vcproj Wed Jan 2 18:43:40 2008 @@ -0,0 +1,553 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Added: python/trunk/PC/VS8.0/_ctypes.vcproj ============================================================================== --- (empty file) +++ python/trunk/PC/VS8.0/_ctypes.vcproj Wed Jan 2 18:43:40 2008 @@ -0,0 +1,704 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Added: python/trunk/PC/VS8.0/_ctypes_test.vcproj ============================================================================== --- (empty file) +++ python/trunk/PC/VS8.0/_ctypes_test.vcproj Wed Jan 2 18:43:40 2008 @@ -0,0 +1,521 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Added: python/trunk/PC/VS8.0/_elementtree.vcproj ============================================================================== --- (empty file) +++ python/trunk/PC/VS8.0/_elementtree.vcproj Wed Jan 2 18:43:40 2008 @@ -0,0 +1,621 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Added: python/trunk/PC/VS8.0/_msi.vcproj ============================================================================== --- (empty file) +++ python/trunk/PC/VS8.0/_msi.vcproj Wed Jan 2 18:43:40 2008 @@ -0,0 +1,529 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Added: python/trunk/PC/VS8.0/_socket.vcproj ============================================================================== --- (empty file) +++ python/trunk/PC/VS8.0/_socket.vcproj Wed Jan 2 18:43:40 2008 @@ -0,0 +1,537 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Added: python/trunk/PC/VS8.0/_sqlite3.vcproj ============================================================================== --- (empty file) +++ python/trunk/PC/VS8.0/_sqlite3.vcproj Wed Jan 2 18:43:40 2008 @@ -0,0 +1,637 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Added: python/trunk/PC/VS8.0/_ssl.vcproj ============================================================================== --- (empty file) +++ python/trunk/PC/VS8.0/_ssl.vcproj Wed Jan 2 18:43:40 2008 @@ -0,0 +1,549 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Added: python/trunk/PC/VS8.0/_testcapi.vcproj ============================================================================== --- (empty file) +++ python/trunk/PC/VS8.0/_testcapi.vcproj Wed Jan 2 18:43:40 2008 @@ -0,0 +1,521 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Added: python/trunk/PC/VS8.0/_tkinter.vcproj ============================================================================== --- (empty file) +++ python/trunk/PC/VS8.0/_tkinter.vcproj Wed Jan 2 18:43:40 2008 @@ -0,0 +1,541 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Added: python/trunk/PC/VS8.0/bdist_wininst.vcproj ============================================================================== --- (empty file) +++ python/trunk/PC/VS8.0/bdist_wininst.vcproj Wed Jan 2 18:43:40 2008 @@ -0,0 +1,177 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Added: python/trunk/PC/VS8.0/build.bat ============================================================================== --- (empty file) +++ python/trunk/PC/VS8.0/build.bat Wed Jan 2 18:43:40 2008 @@ -0,0 +1,17 @@ + at echo off +rem A batch program to build or rebuild a particular configuration. +rem just for convenience. + +setlocal +set platf=Win32 +set conf=Release +set build=/build + +:CheckOpts +if "%1"=="-c" (set conf=%2) & shift & shift & goto CheckOpts +if "%1"=="-p" (set platf=%2) & shift & shift & goto CheckOpts +if "%1"=="-r" (set build=/rebuild) & shift & goto CheckOpts + +set cmd=devenv pcbuild.sln %build% "%conf%|%platf%" +echo %cmd% +%cmd% Added: python/trunk/PC/VS8.0/build_env.bat ============================================================================== --- (empty file) +++ python/trunk/PC/VS8.0/build_env.bat Wed Jan 2 18:43:40 2008 @@ -0,0 +1 @@ +@%comspec% /k env.bat %* Added: python/trunk/PC/VS8.0/build_pgo.bat ============================================================================== --- (empty file) +++ python/trunk/PC/VS8.0/build_pgo.bat Wed Jan 2 18:43:40 2008 @@ -0,0 +1,41 @@ + at echo off +rem A batch program to build PGO (Profile guided optimization) by first +rem building instrumented binaries, then running the testsuite, and +rem finally building the optimized code. +rem Note, after the first instrumented run, one can just keep on +rem building the PGUpdate configuration while developing. + +setlocal +set platf=Win32 + +rem use the performance testsuite. This is quick and simple +set job1=..\..\tools\pybench\pybench.py -n 1 -C 1 --with-gc +set path1=..\..\tools\pybench + +rem or the whole testsuite for more thorough testing +set job2=..\..\lib\test\regrtest.py +set path2=..\..\lib + +set job=%job1% +set clrpath=%path1% + +:CheckOpts +if "%1"=="-p" (set platf=%2) & shift & shift & goto CheckOpts +if "%1"=="-2" (set job=%job2%) & (set clrpath=%path2%) & shift & goto CheckOpts + +set PGI=%platf%-pgi +set PGO=%platf%-pgo + + at echo on +rem build the instrumented version +call build -p %platf% -c PGInstrument + +rem remove .pyc files, .pgc files and execute the job +%PGI%\python.exe rmpyc.py %clrpath% +del %PGI%\*.pgc +%PGI%\python.exe %job% + +rem finally build the optimized version +if exist %PGO% del /s /q %PGO% +call build -p %platf% -c PGUpdate + Added: python/trunk/PC/VS8.0/build_ssl.bat ============================================================================== --- (empty file) +++ python/trunk/PC/VS8.0/build_ssl.bat Wed Jan 2 18:43:40 2008 @@ -0,0 +1,12 @@ + at echo off +if not defined HOST_PYTHON ( + if %1 EQU Debug ( + set HOST_PYTHON=python_d.exe + if not exist python30_d.dll exit 1 + ) ELSE ( + set HOST_PYTHON=python.exe + if not exist python30.dll exit 1 + ) +) +%HOST_PYTHON% build_ssl.py %1 %2 %3 + Added: python/trunk/PC/VS8.0/build_ssl.py ============================================================================== --- (empty file) +++ python/trunk/PC/VS8.0/build_ssl.py Wed Jan 2 18:43:40 2008 @@ -0,0 +1,250 @@ +# Script for building the _ssl and _hashlib modules for Windows. +# Uses Perl to setup the OpenSSL environment correctly +# and build OpenSSL, then invokes a simple nmake session +# for the actual _ssl.pyd and _hashlib.pyd DLLs. + +# THEORETICALLY, you can: +# * Unpack the latest SSL release one level above your main Python source +# directory. It is likely you will already find the zlib library and +# any other external packages there. +# * Install ActivePerl and ensure it is somewhere on your path. +# * Run this script from the PCBuild directory. +# +# it should configure and build SSL, then build the _ssl and _hashlib +# Python extensions without intervention. + +# Modified by Christian Heimes +# Now this script supports pre-generated makefiles and assembly files. +# Developers don't need an installation of Perl anymore to build Python. A svn +# checkout from our svn repository is enough. +# +# In Order to create the files in the case of an update you still need Perl. +# Run build_ssl in this order: +# python.exe build_ssl.py Release x64 +# python.exe build_ssl.py Release Win32 + +import os, sys, re, shutil + +# Find all "foo.exe" files on the PATH. +def find_all_on_path(filename, extras = None): + entries = os.environ["PATH"].split(os.pathsep) + ret = [] + for p in entries: + fname = os.path.abspath(os.path.join(p, filename)) + if os.path.isfile(fname) and fname not in ret: + ret.append(fname) + if extras: + for p in extras: + fname = os.path.abspath(os.path.join(p, filename)) + if os.path.isfile(fname) and fname not in ret: + ret.append(fname) + return ret + +# Find a suitable Perl installation for OpenSSL. +# cygwin perl does *not* work. ActivePerl does. +# Being a Perl dummy, the simplest way I can check is if the "Win32" package +# is available. +def find_working_perl(perls): + for perl in perls: + fh = os.popen(perl + ' -e "use Win32;"') + fh.read() + rc = fh.close() + if rc: + continue + return perl + print("Can not find a suitable PERL:") + if perls: + print(" the following perl interpreters were found:") + for p in perls: + print(" ", p) + print(" None of these versions appear suitable for building OpenSSL") + else: + print(" NO perl interpreters were found on this machine at all!") + print(" Please install ActivePerl and ensure it appears on your path") + return None + +# Locate the best SSL directory given a few roots to look into. +def find_best_ssl_dir(sources): + candidates = [] + for s in sources: + try: + # note: do not abspath s; the build will fail if any + # higher up directory name has spaces in it. + fnames = os.listdir(s) + except os.error: + fnames = [] + for fname in fnames: + fqn = os.path.join(s, fname) + if os.path.isdir(fqn) and fname.startswith("openssl-"): + candidates.append(fqn) + # Now we have all the candidates, locate the best. + best_parts = [] + best_name = None + for c in candidates: + parts = re.split("[.-]", os.path.basename(c))[1:] + # eg - openssl-0.9.7-beta1 - ignore all "beta" or any other qualifiers + if len(parts) >= 4: + continue + if parts > best_parts: + best_parts = parts + best_name = c + if best_name is not None: + print("Found an SSL directory at '%s'" % (best_name,)) + else: + print("Could not find an SSL directory in '%s'" % (sources,)) + sys.stdout.flush() + return best_name + +def create_makefile64(makefile, m32): + """Create and fix makefile for 64bit + + Replace 32 with 64bit directories + """ + if not os.path.isfile(m32): + return + with open(m32) as fin: + with open(makefile, 'w') as fout: + for line in fin: + line = line.replace("=tmp32", "=tmp64") + line = line.replace("=out32", "=out64") + line = line.replace("=inc32", "=inc64") + # force 64 bit machine + line = line.replace("MKLIB=lib", "MKLIB=lib /MACHINE:X64") + line = line.replace("LFLAGS=", "LFLAGS=/MACHINE:X64 ") + # don't link against the lib on 64bit systems + line = line.replace("bufferoverflowu.lib", "") + fout.write(line) + os.unlink(m32) + +def fix_makefile(makefile): + """Fix some stuff in all makefiles + """ + if not os.path.isfile(makefile): + return + with open(makefile) as fin: + lines = fin.readlines() + with open(makefile, 'w') as fout: + for line in lines: + if line.startswith("PERL="): + continue + if line.startswith("CP="): + line = "CP=copy\n" + if line.startswith("MKDIR="): + line = "MKDIR=mkdir\n" + if line.startswith("CFLAG="): + line = line.strip() + for algo in ("RC5", "MDC2", "IDEA"): + noalgo = " -DOPENSSL_NO_%s" % algo + if noalgo not in line: + line = line + noalgo + line = line + '\n' + fout.write(line) + +def run_configure(configure, do_script): + print("perl Configure "+configure) + os.system("perl Configure "+configure) + print(do_script) + os.system(do_script) + +def main(): + build_all = "-a" in sys.argv + if sys.argv[1] == "Release": + debug = False + elif sys.argv[1] == "Debug": + debug = True + else: + raise ValueError(str(sys.argv)) + + if sys.argv[2] == "Win32": + arch = "x86" + configure = "VC-WIN32" + do_script = "ms\\do_nasm" + makefile="ms\\nt.mak" + m32 = makefile + elif sys.argv[2] == "x64": + arch="amd64" + configure = "VC-WIN64A" + do_script = "ms\\do_win64a" + makefile = "ms\\nt64.mak" + m32 = makefile.replace('64', '') + #os.environ["VSEXTCOMP_USECL"] = "MS_OPTERON" + else: + raise ValueError(str(sys.argv)) + + make_flags = "" + if build_all: + make_flags = "-a" + # perl should be on the path, but we also look in "\perl" and "c:\\perl" + # as "well known" locations + perls = find_all_on_path("perl.exe", ["\\perl\\bin", "C:\\perl\\bin"]) + perl = find_working_perl(perls) + if perl is None: + print("No Perl installation was found. Existing Makefiles are used.") + + print("Found a working perl at '%s'" % (perl,)) + sys.stdout.flush() + # Look for SSL 2 levels up from pcbuild - ie, same place zlib etc all live. + ssl_dir = find_best_ssl_dir(("..\\..\\..",)) + if ssl_dir is None: + sys.exit(1) + + old_cd = os.getcwd() + try: + os.chdir(ssl_dir) + # rebuild makefile when we do the role over from 32 to 64 build + if arch == "amd64" and os.path.isfile(m32) and not os.path.isfile(makefile): + os.unlink(m32) + + # If the ssl makefiles do not exist, we invoke Perl to generate them. + # Due to a bug in this script, the makefile sometimes ended up empty + # Force a regeneration if it is. + if not os.path.isfile(makefile) or os.path.getsize(makefile)==0: + if perl is None: + print("Perl is required to build the makefiles!") + sys.exit(1) + + print("Creating the makefiles...") + sys.stdout.flush() + # Put our working Perl at the front of our path + os.environ["PATH"] = os.path.dirname(perl) + \ + os.pathsep + \ + os.environ["PATH"] + run_configure(configure, do_script) + if debug: + print("OpenSSL debug builds aren't supported.") + #if arch=="x86" and debug: + # # the do_masm script in openssl doesn't generate a debug + # # build makefile so we generate it here: + # os.system("perl util\mk1mf.pl debug "+configure+" >"+makefile) + + if arch == "amd64": + create_makefile64(makefile, m32) + fix_makefile(makefile) + shutil.copy(r"crypto\buildinf.h", r"crypto\buildinf_%s.h" % arch) + shutil.copy(r"crypto\opensslconf.h", r"crypto\opensslconf_%s.h" % arch) + + # Now run make. + if arch == "amd64": + rc = os.system(r"ml64 -c -Foms\uptable.obj ms\uptable.asm") + if rc: + print("ml64 assembler has failed.") + sys.exit(rc) + + shutil.copy(r"crypto\buildinf_%s.h" % arch, r"crypto\buildinf.h") + shutil.copy(r"crypto\opensslconf_%s.h" % arch, r"crypto\opensslconf.h") + + #makeCommand = "nmake /nologo PERL=\"%s\" -f \"%s\"" %(perl, makefile) + makeCommand = "nmake /nologo -f \"%s\"" % makefile + print("Executing ssl makefiles:", makeCommand) + sys.stdout.flush() + rc = os.system(makeCommand) + if rc: + print("Executing "+makefile+" failed") + print(rc) + sys.exit(rc) + finally: + os.chdir(old_cd) + sys.exit(rc) + +if __name__=='__main__': + main() Added: python/trunk/PC/VS8.0/build_tkinter.py ============================================================================== --- (empty file) +++ python/trunk/PC/VS8.0/build_tkinter.py Wed Jan 2 18:43:40 2008 @@ -0,0 +1,86 @@ +"""Script to compile the dependencies of _tkinter + +Copyright (c) 2007 by Christian Heimes + +Licensed to PSF under a Contributor Agreement. +""" + +import os +import sys +import shutil + +here = os.path.abspath(os.path.dirname(__file__)) +par = os.path.pardir + +if 1: + TCL = "tcl8.4.16" + TK = "tk8.4.16" + TIX = "tix-8.4.0" +else: + TCL = "tcl8.5b3" + TK = "tcl8.5b3" + TIX = "Tix8.4.2" + +ROOT = os.path.abspath(os.path.join(here, par, par, par)) +# Windows 2000 compatibility: WINVER 0x0500 +# http://msdn2.microsoft.com/en-us/library/aa383745.aspx +NMAKE = "nmake /nologo /f %s COMPILERFLAGS=-DWINVER=0x0500 %s %s" + +def nmake(makefile, command="", **kw): + defines = ' '.join(k+'='+v for k, v in kw.items()) + cmd = NMAKE % (makefile, defines, command) + print("\n\n"+cmd+"\n") + if os.system(cmd) != 0: + raise RuntimeError(cmd) + +def build(platform, clean): + if platform == "Win32": + dest = os.path.join(ROOT, "tcltk") + machine = "X86" + elif platform == "x64": + dest = os.path.join(ROOT, "tcltk64") + machine = "X64" + else: + raise ValueError(platform) + + # TCL + tcldir = os.path.join(ROOT, TCL) + if 1: + os.chdir(os.path.join(tcldir, "win")) + if clean: + nmake("makefile.vc", "clean") + nmake("makefile.vc") + nmake("makefile.vc", "install", INSTALLDIR=dest) + + # TK + if 1: + os.chdir(os.path.join(ROOT, TK, "win")) + if clean: + nmake("makefile.vc", "clean", TCLDIR=tcldir) + nmake("makefile.vc", TCLDIR=tcldir) + nmake("makefile.vc", "install", TCLDIR=tcldir, INSTALLDIR=dest) + + # TIX + if 1: + # python9.mak is available at http://svn.python.org + os.chdir(os.path.join(ROOT, TIX, "win")) + if clean: + nmake("python9.mak", "clean") + nmake("python9.mak", MACHINE=machine) + nmake("python9.mak", "install") + +def main(): + if len(sys.argv) < 2 or sys.argv[1] not in ("Win32", "x64"): + print("%s Win32|x64" % sys.argv[0]) + sys.exit(1) + + if "-c" in sys.argv: + clean = True + else: + clean = False + + build(sys.argv[1], clean) + + +if __name__ == '__main__': + main() Added: python/trunk/PC/VS8.0/bz2.vcproj ============================================================================== --- (empty file) +++ python/trunk/PC/VS8.0/bz2.vcproj Wed Jan 2 18:43:40 2008 @@ -0,0 +1,545 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Added: python/trunk/PC/VS8.0/debug.vsprops ============================================================================== --- (empty file) +++ python/trunk/PC/VS8.0/debug.vsprops Wed Jan 2 18:43:40 2008 @@ -0,0 +1,11 @@ + + + + \ No newline at end of file Added: python/trunk/PC/VS8.0/env.bat ============================================================================== --- (empty file) +++ python/trunk/PC/VS8.0/env.bat Wed Jan 2 18:43:40 2008 @@ -0,0 +1,5 @@ + at echo off +set VS8=%ProgramFiles%\Microsoft Visual Studio 8 +echo Build environments: x86, ia64, amd64, x86_amd64, x86_ia64 +echo. +call "%VS8%\VC\vcvarsall.bat" %1 Added: python/trunk/PC/VS8.0/field3.py ============================================================================== --- (empty file) +++ python/trunk/PC/VS8.0/field3.py Wed Jan 2 18:43:40 2008 @@ -0,0 +1,35 @@ +# An absurd workaround for the lack of arithmetic in MS's resource compiler. +# After building Python, run this, then paste the output into the appropriate +# part of PC\python_nt.rc. +# Example output: +# +# * For 2.3a0, +# * PY_MICRO_VERSION = 0 +# * PY_RELEASE_LEVEL = 'alpha' = 0xA +# * PY_RELEASE_SERIAL = 1 +# * +# * and 0*1000 + 10*10 + 1 = 101. +# */ +# #define FIELD3 101 + +import sys + +major, minor, micro, level, serial = sys.version_info +levelnum = {'alpha': 0xA, + 'beta': 0xB, + 'candidate': 0xC, + 'final': 0xF, + }[level] +string = sys.version.split()[0] # like '2.3a0' + +print(" * For %s," % string) +print(" * PY_MICRO_VERSION = %d" % micro) +print(" * PY_RELEASE_LEVEL = %r = %s" % (level, hex(levelnum))) +print(" * PY_RELEASE_SERIAL = %d" % serial) +print(" *") + +field3 = micro * 1000 + levelnum * 10 + serial + +print(" * and %d*1000 + %d*10 + %d = %d" % (micro, levelnum, serial, field3)) +print(" */") +print("#define FIELD3", field3) Added: python/trunk/PC/VS8.0/idle.bat ============================================================================== --- (empty file) +++ python/trunk/PC/VS8.0/idle.bat Wed Jan 2 18:43:40 2008 @@ -0,0 +1,15 @@ + at echo off +rem start idle +rem Usage: idle [-d] +rem -d Run Debug build (python_d.exe). Else release build. + +setlocal +set exe=python +PATH %PATH%;..\..\..\tcltk\bin + +if "%1"=="-d" (set exe=python_d) & shift + +set cmd=%exe% ../../Lib/idlelib/idle.py %1 %2 %3 %4 %5 %6 %7 %8 %9 + +echo on +%cmd% Added: python/trunk/PC/VS8.0/make_buildinfo.c ============================================================================== --- (empty file) +++ python/trunk/PC/VS8.0/make_buildinfo.c Wed Jan 2 18:43:40 2008 @@ -0,0 +1,94 @@ +#include +#include +#include +#include + +#define CMD_SIZE 500 + +/* This file creates the getbuildinfo.o object, by first + invoking subwcrev.exe (if found), and then invoking cl.exe. + As a side effect, it might generate PCBuild\getbuildinfo2.c + also. If this isn't a subversion checkout, or subwcrev isn't + found, it compiles ..\\..\\Modules\\getbuildinfo.c instead. + + Currently, subwcrev.exe is found from the registry entries + of TortoiseSVN. + + No attempt is made to place getbuildinfo.o into the proper + binary directory. This isn't necessary, as this tool is + invoked as a pre-link step for pythoncore, so that overwrites + any previous getbuildinfo.o. + +*/ + +int make_buildinfo2() +{ + struct _stat st; + HKEY hTortoise; + char command[CMD_SIZE+1]; + DWORD type, size; + if (_stat(".svn", &st) < 0) + return 0; + /* Allow suppression of subwcrev.exe invocation if a no_subwcrev file is present. */ + if (_stat("no_subwcrev", &st) == 0) + return 0; + if (RegOpenKey(HKEY_LOCAL_MACHINE, "Software\\TortoiseSVN", &hTortoise) != ERROR_SUCCESS && + RegOpenKey(HKEY_CURRENT_USER, "Software\\TortoiseSVN", &hTortoise) != ERROR_SUCCESS) + /* Tortoise not installed */ + return 0; + command[0] = '"'; /* quote the path to the executable */ + size = sizeof(command) - 1; + if (RegQueryValueEx(hTortoise, "Directory", 0, &type, command+1, &size) != ERROR_SUCCESS || + type != REG_SZ) + /* Registry corrupted */ + return 0; + strcat_s(command, CMD_SIZE, "bin\\subwcrev.exe"); + if (_stat(command+1, &st) < 0) + /* subwcrev.exe not part of the release */ + return 0; + strcat_s(command, CMD_SIZE, "\" ..\\.. ..\\..\\Modules\\getbuildinfo.c getbuildinfo2.c"); + puts(command); fflush(stdout); + if (system(command) < 0) + return 0; + return 1; +} + +int main(int argc, char*argv[]) +{ + char command[500] = "cl.exe -c -D_WIN32 -DUSE_DL_EXPORT -D_WINDOWS -DWIN32 -D_WINDLL "; + int do_unlink, result; + if (argc != 2) { + fprintf(stderr, "make_buildinfo $(ConfigurationName)\n"); + return EXIT_FAILURE; + } + if (strcmp(argv[1], "Release") == 0) { + strcat_s(command, CMD_SIZE, "-MD "); + } + else if (strcmp(argv[1], "Debug") == 0) { + strcat_s(command, CMD_SIZE, "-D_DEBUG -MDd "); + } + else if (strcmp(argv[1], "ReleaseItanium") == 0) { + strcat_s(command, CMD_SIZE, "-MD /USECL:MS_ITANIUM "); + } + else if (strcmp(argv[1], "ReleaseAMD64") == 0) { + strcat_s(command, CMD_SIZE, "-MD "); + strcat_s(command, CMD_SIZE, "-MD /USECL:MS_OPTERON "); + } + else { + fprintf(stderr, "unsupported configuration %s\n", argv[1]); + return EXIT_FAILURE; + } + + if ((do_unlink = make_buildinfo2())) + strcat_s(command, CMD_SIZE, "getbuildinfo2.c -DSUBWCREV "); + else + strcat_s(command, CMD_SIZE, "..\\..\\Modules\\getbuildinfo.c"); + strcat_s(command, CMD_SIZE, " -Fogetbuildinfo.o -I..\\..\\Include -I..\\..\\PC"); + puts(command); fflush(stdout); + result = system(command); + if (do_unlink) + _unlink("getbuildinfo2.c"); + if (result < 0) + return EXIT_FAILURE; + return 0; +} \ No newline at end of file Added: python/trunk/PC/VS8.0/make_buildinfo.vcproj ============================================================================== --- (empty file) +++ python/trunk/PC/VS8.0/make_buildinfo.vcproj Wed Jan 2 18:43:40 2008 @@ -0,0 +1,162 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Added: python/trunk/PC/VS8.0/make_versioninfo.vcproj ============================================================================== --- (empty file) +++ python/trunk/PC/VS8.0/make_versioninfo.vcproj Wed Jan 2 18:43:40 2008 @@ -0,0 +1,326 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Added: python/trunk/PC/VS8.0/pcbuild.sln ============================================================================== --- (empty file) +++ python/trunk/PC/VS8.0/pcbuild.sln Wed Jan 2 18:43:40 2008 @@ -0,0 +1,471 @@ +Microsoft Visual Studio Solution File, Format Version 9.00 +# Visual Studio 2005 +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "python", "python.vcproj", "{B11D750F-CD1F-4A96-85CE-E69A5C5259F9}" + ProjectSection(ProjectDependencies) = postProject + {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26} = {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26} + {E9E0A1F6-0009-4E8C-B8F8-1B8F5D49A058} = {E9E0A1F6-0009-4E8C-B8F8-1B8F5D49A058} + EndProjectSection +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "make_versioninfo", "make_versioninfo.vcproj", "{F0E0541E-F17D-430B-97C4-93ADF0DD284E}" +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "pythoncore", "pythoncore.vcproj", "{CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26}" + ProjectSection(ProjectDependencies) = postProject + {F0E0541E-F17D-430B-97C4-93ADF0DD284E} = {F0E0541E-F17D-430B-97C4-93ADF0DD284E} + {C73F0EC1-358B-4177-940F-0846AC8B04CD} = {C73F0EC1-358B-4177-940F-0846AC8B04CD} + EndProjectSection +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "pythonw", "pythonw.vcproj", "{F4229CC3-873C-49AE-9729-DD308ED4CD4A}" + ProjectSection(ProjectDependencies) = postProject + {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26} = {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26} + EndProjectSection +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "w9xpopen", "w9xpopen.vcproj", "{E9E0A1F6-0009-4E8C-B8F8-1B8F5D49A058}" +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "make_buildinfo", "make_buildinfo.vcproj", "{C73F0EC1-358B-4177-940F-0846AC8B04CD}" +EndProject +Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{553EC33E-9816-4996-A660-5D6186A0B0B3}" + ProjectSection(SolutionItems) = preProject + ..\..\Modules\getbuildinfo.c = ..\..\Modules\getbuildinfo.c + readme.txt = readme.txt + EndProjectSection +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "winsound", "winsound.vcproj", "{28B5D777-DDF2-4B6B-B34F-31D938813856}" + ProjectSection(ProjectDependencies) = postProject + {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26} = {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26} + EndProjectSection +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "_bsddb", "_bsddb.vcproj", "{B4D38F3F-68FB-42EC-A45D-E00657BB3627}" + ProjectSection(ProjectDependencies) = postProject + {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26} = {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26} + EndProjectSection +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "_ctypes", "_ctypes.vcproj", "{0E9791DB-593A-465F-98BC-681011311618}" + ProjectSection(ProjectDependencies) = postProject + {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26} = {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26} + EndProjectSection +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "_ctypes_test", "_ctypes_test.vcproj", "{9EC7190A-249F-4180-A900-548FDCF3055F}" + ProjectSection(ProjectDependencies) = postProject + {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26} = {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26} + EndProjectSection +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "_elementtree", "_elementtree.vcproj", "{17E1E049-C309-4D79-843F-AE483C264AEA}" + ProjectSection(ProjectDependencies) = postProject + {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26} = {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26} + EndProjectSection +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "_msi", "_msi.vcproj", "{31FFC478-7B4A-43E8-9954-8D03E2187E9C}" + ProjectSection(ProjectDependencies) = postProject + {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26} = {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26} + EndProjectSection +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "_socket", "_socket.vcproj", "{86937F53-C189-40EF-8CE8-8759D8E7D480}" + ProjectSection(ProjectDependencies) = postProject + {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26} = {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26} + EndProjectSection +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "_sqlite3", "_sqlite3.vcproj", "{13CECB97-4119-4316-9D42-8534019A5A44}" + ProjectSection(ProjectDependencies) = postProject + {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26} = {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26} + EndProjectSection +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "_ssl", "_ssl.vcproj", "{C6E20F84-3247-4AD6-B051-B073268F73BA}" + ProjectSection(ProjectDependencies) = postProject + {B11D750F-CD1F-4A96-85CE-E69A5C5259F9} = {B11D750F-CD1F-4A96-85CE-E69A5C5259F9} + {86937F53-C189-40EF-8CE8-8759D8E7D480} = {86937F53-C189-40EF-8CE8-8759D8E7D480} + {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26} = {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26} + EndProjectSection +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "_testcapi", "_testcapi.vcproj", "{6901D91C-6E48-4BB7-9FEC-700C8131DF1D}" + ProjectSection(ProjectDependencies) = postProject + {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26} = {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26} + EndProjectSection +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "_tkinter", "_tkinter.vcproj", "{4946ECAC-2E69-4BF8-A90A-F5136F5094DF}" + ProjectSection(ProjectDependencies) = postProject + {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26} = {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26} + EndProjectSection +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "bz2", "bz2.vcproj", "{73FCD2BD-F133-46B7-8EC1-144CD82A59D5}" + ProjectSection(ProjectDependencies) = postProject + {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26} = {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26} + EndProjectSection +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "select", "select.vcproj", "{18CAE28C-B454-46C1-87A0-493D91D97F03}" + ProjectSection(ProjectDependencies) = postProject + {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26} = {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26} + EndProjectSection +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "unicodedata", "unicodedata.vcproj", "{ECC7CEAC-A5E5-458E-BB9E-2413CC847881}" + ProjectSection(ProjectDependencies) = postProject + {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26} = {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26} + EndProjectSection +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "pyexpat", "pyexpat.vcproj", "{D06B6426-4762-44CC-8BAD-D79052507F2F}" + ProjectSection(ProjectDependencies) = postProject + {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26} = {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26} + EndProjectSection +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "bdist_wininst", "bdist_wininst.vcproj", "{EB1C19C1-1F18-421E-9735-CAEE69DC6A3C}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|Win32 = Debug|Win32 + Debug|x64 = Debug|x64 + PGInstrument|Win32 = PGInstrument|Win32 + PGInstrument|x64 = PGInstrument|x64 + PGUpdate|Win32 = PGUpdate|Win32 + PGUpdate|x64 = PGUpdate|x64 + Release|Win32 = Release|Win32 + Release|x64 = Release|x64 + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {B11D750F-CD1F-4A96-85CE-E69A5C5259F9}.Debug|Win32.ActiveCfg = Debug|Win32 + {B11D750F-CD1F-4A96-85CE-E69A5C5259F9}.Debug|Win32.Build.0 = Debug|Win32 + {B11D750F-CD1F-4A96-85CE-E69A5C5259F9}.Debug|x64.ActiveCfg = Debug|x64 + {B11D750F-CD1F-4A96-85CE-E69A5C5259F9}.Debug|x64.Build.0 = Debug|x64 + {B11D750F-CD1F-4A96-85CE-E69A5C5259F9}.PGInstrument|Win32.ActiveCfg = PGInstrument|Win32 + {B11D750F-CD1F-4A96-85CE-E69A5C5259F9}.PGInstrument|Win32.Build.0 = PGInstrument|Win32 + {B11D750F-CD1F-4A96-85CE-E69A5C5259F9}.PGInstrument|x64.ActiveCfg = PGInstrument|x64 + {B11D750F-CD1F-4A96-85CE-E69A5C5259F9}.PGInstrument|x64.Build.0 = PGInstrument|x64 + {B11D750F-CD1F-4A96-85CE-E69A5C5259F9}.PGUpdate|Win32.ActiveCfg = PGUpdate|Win32 + {B11D750F-CD1F-4A96-85CE-E69A5C5259F9}.PGUpdate|Win32.Build.0 = PGUpdate|Win32 + {B11D750F-CD1F-4A96-85CE-E69A5C5259F9}.PGUpdate|x64.ActiveCfg = PGUpdate|x64 + {B11D750F-CD1F-4A96-85CE-E69A5C5259F9}.PGUpdate|x64.Build.0 = PGUpdate|x64 + {B11D750F-CD1F-4A96-85CE-E69A5C5259F9}.Release|Win32.ActiveCfg = Release|Win32 + {B11D750F-CD1F-4A96-85CE-E69A5C5259F9}.Release|Win32.Build.0 = Release|Win32 + {B11D750F-CD1F-4A96-85CE-E69A5C5259F9}.Release|x64.ActiveCfg = Release|x64 + {B11D750F-CD1F-4A96-85CE-E69A5C5259F9}.Release|x64.Build.0 = Release|x64 + {F0E0541E-F17D-430B-97C4-93ADF0DD284E}.Debug|Win32.ActiveCfg = Debug|Win32 + {F0E0541E-F17D-430B-97C4-93ADF0DD284E}.Debug|Win32.Build.0 = Debug|Win32 + {F0E0541E-F17D-430B-97C4-93ADF0DD284E}.Debug|x64.ActiveCfg = Debug|Win32 + {F0E0541E-F17D-430B-97C4-93ADF0DD284E}.Debug|x64.Build.0 = Debug|Win32 + {F0E0541E-F17D-430B-97C4-93ADF0DD284E}.PGInstrument|Win32.ActiveCfg = Release|Win32 + {F0E0541E-F17D-430B-97C4-93ADF0DD284E}.PGInstrument|Win32.Build.0 = Release|Win32 + {F0E0541E-F17D-430B-97C4-93ADF0DD284E}.PGInstrument|x64.ActiveCfg = Release|Win32 + {F0E0541E-F17D-430B-97C4-93ADF0DD284E}.PGInstrument|x64.Build.0 = Release|Win32 + {F0E0541E-F17D-430B-97C4-93ADF0DD284E}.PGUpdate|Win32.ActiveCfg = Release|Win32 + {F0E0541E-F17D-430B-97C4-93ADF0DD284E}.PGUpdate|Win32.Build.0 = Release|Win32 + {F0E0541E-F17D-430B-97C4-93ADF0DD284E}.PGUpdate|x64.ActiveCfg = Release|Win32 + {F0E0541E-F17D-430B-97C4-93ADF0DD284E}.PGUpdate|x64.Build.0 = Release|Win32 + {F0E0541E-F17D-430B-97C4-93ADF0DD284E}.Release|Win32.ActiveCfg = Release|Win32 + {F0E0541E-F17D-430B-97C4-93ADF0DD284E}.Release|Win32.Build.0 = Release|Win32 + {F0E0541E-F17D-430B-97C4-93ADF0DD284E}.Release|x64.ActiveCfg = Release|Win32 + {F0E0541E-F17D-430B-97C4-93ADF0DD284E}.Release|x64.Build.0 = Release|Win32 + {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26}.Debug|Win32.ActiveCfg = Debug|Win32 + {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26}.Debug|Win32.Build.0 = Debug|Win32 + {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26}.Debug|x64.ActiveCfg = Debug|x64 + {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26}.Debug|x64.Build.0 = Debug|x64 + {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26}.PGInstrument|Win32.ActiveCfg = PGInstrument|Win32 + {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26}.PGInstrument|Win32.Build.0 = PGInstrument|Win32 + {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26}.PGInstrument|x64.ActiveCfg = PGInstrument|x64 + {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26}.PGInstrument|x64.Build.0 = PGInstrument|x64 + {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26}.PGUpdate|Win32.ActiveCfg = PGUpdate|Win32 + {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26}.PGUpdate|Win32.Build.0 = PGUpdate|Win32 + {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26}.PGUpdate|x64.ActiveCfg = PGUpdate|x64 + {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26}.PGUpdate|x64.Build.0 = PGUpdate|x64 + {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26}.Release|Win32.ActiveCfg = Release|Win32 + {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26}.Release|Win32.Build.0 = Release|Win32 + {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26}.Release|x64.ActiveCfg = Release|x64 + {CF7AC3D1-E2DF-41D2-BEA6-1E2556CDEA26}.Release|x64.Build.0 = Release|x64 + {F4229CC3-873C-49AE-9729-DD308ED4CD4A}.Debug|Win32.ActiveCfg = Debug|Win32 + {F4229CC3-873C-49AE-9729-DD308ED4CD4A}.Debug|Win32.Build.0 = Debug|Win32 + {F4229CC3-873C-49AE-9729-DD308ED4CD4A}.Debug|x64.ActiveCfg = Debug|x64 + {F4229CC3-873C-49AE-9729-DD308ED4CD4A}.Debug|x64.Build.0 = Debug|x64 + {F4229CC3-873C-49AE-9729-DD308ED4CD4A}.PGInstrument|Win32.ActiveCfg = PGInstrument|Win32 + {F4229CC3-873C-49AE-9729-DD308ED4CD4A}.PGInstrument|Win32.Build.0 = PGInstrument|Win32 + {F4229CC3-873C-49AE-9729-DD308ED4CD4A}.PGInstrument|x64.ActiveCfg = PGInstrument|x64 + {F4229CC3-873C-49AE-9729-DD308ED4CD4A}.PGInstrument|x64.Build.0 = PGInstrument|x64 + {F4229CC3-873C-49AE-9729-DD308ED4CD4A}.PGUpdate|Win32.ActiveCfg = PGUpdate|Win32 + {F4229CC3-873C-49AE-9729-DD308ED4CD4A}.PGUpdate|Win32.Build.0 = PGUpdate|Win32 + {F4229CC3-873C-49AE-9729-DD308ED4CD4A}.PGUpdate|x64.ActiveCfg = PGUpdate|x64 + {F4229CC3-873C-49AE-9729-DD308ED4CD4A}.PGUpdate|x64.Build.0 = PGUpdate|x64 + {F4229CC3-873C-49AE-9729-DD308ED4CD4A}.Release|Win32.ActiveCfg = Release|Win32 + {F4229CC3-873C-49AE-9729-DD308ED4CD4A}.Release|Win32.Build.0 = Release|Win32 + {F4229CC3-873C-49AE-9729-DD308ED4CD4A}.Release|x64.ActiveCfg = Release|x64 + {F4229CC3-873C-49AE-9729-DD308ED4CD4A}.Release|x64.Build.0 = Release|x64 + {E9E0A1F6-0009-4E8C-B8F8-1B8F5D49A058}.Debug|Win32.ActiveCfg = Debug|Win32 + {E9E0A1F6-0009-4E8C-B8F8-1B8F5D49A058}.Debug|Win32.Build.0 = Debug|Win32 + {E9E0A1F6-0009-4E8C-B8F8-1B8F5D49A058}.Debug|x64.ActiveCfg = Debug|x64 + {E9E0A1F6-0009-4E8C-B8F8-1B8F5D49A058}.Debug|x64.Build.0 = Debug|x64 + {E9E0A1F6-0009-4E8C-B8F8-1B8F5D49A058}.PGInstrument|Win32.ActiveCfg = PGInstrument|Win32 + {E9E0A1F6-0009-4E8C-B8F8-1B8F5D49A058}.PGInstrument|Win32.Build.0 = PGInstrument|Win32 + {E9E0A1F6-0009-4E8C-B8F8-1B8F5D49A058}.PGInstrument|x64.ActiveCfg = PGInstrument|x64 + {E9E0A1F6-0009-4E8C-B8F8-1B8F5D49A058}.PGInstrument|x64.Build.0 = PGInstrument|x64 + {E9E0A1F6-0009-4E8C-B8F8-1B8F5D49A058}.PGUpdate|Win32.ActiveCfg = PGUpdate|Win32 + {E9E0A1F6-0009-4E8C-B8F8-1B8F5D49A058}.PGUpdate|Win32.Build.0 = PGUpdate|Win32 + {E9E0A1F6-0009-4E8C-B8F8-1B8F5D49A058}.PGUpdate|x64.ActiveCfg = PGUpdate|x64 + {E9E0A1F6-0009-4E8C-B8F8-1B8F5D49A058}.PGUpdate|x64.Build.0 = PGUpdate|x64 + {E9E0A1F6-0009-4E8C-B8F8-1B8F5D49A058}.Release|Win32.ActiveCfg = Release|Win32 + {E9E0A1F6-0009-4E8C-B8F8-1B8F5D49A058}.Release|Win32.Build.0 = Release|Win32 + {E9E0A1F6-0009-4E8C-B8F8-1B8F5D49A058}.Release|x64.ActiveCfg = Release|x64 + {E9E0A1F6-0009-4E8C-B8F8-1B8F5D49A058}.Release|x64.Build.0 = Release|x64 + {C73F0EC1-358B-4177-940F-0846AC8B04CD}.Debug|Win32.ActiveCfg = Release|Win32 + {C73F0EC1-358B-4177-940F-0846AC8B04CD}.Debug|Win32.Build.0 = Release|Win32 + {C73F0EC1-358B-4177-940F-0846AC8B04CD}.Debug|x64.ActiveCfg = Release|Win32 + {C73F0EC1-358B-4177-940F-0846AC8B04CD}.Debug|x64.Build.0 = Release|Win32 + {C73F0EC1-358B-4177-940F-0846AC8B04CD}.PGInstrument|Win32.ActiveCfg = Release|Win32 + {C73F0EC1-358B-4177-940F-0846AC8B04CD}.PGInstrument|Win32.Build.0 = Release|Win32 + {C73F0EC1-358B-4177-940F-0846AC8B04CD}.PGInstrument|x64.ActiveCfg = Release|Win32 + {C73F0EC1-358B-4177-940F-0846AC8B04CD}.PGInstrument|x64.Build.0 = Release|Win32 + {C73F0EC1-358B-4177-940F-0846AC8B04CD}.PGUpdate|Win32.ActiveCfg = Release|Win32 + {C73F0EC1-358B-4177-940F-0846AC8B04CD}.PGUpdate|Win32.Build.0 = Release|Win32 + {C73F0EC1-358B-4177-940F-0846AC8B04CD}.PGUpdate|x64.ActiveCfg = Release|Win32 + {C73F0EC1-358B-4177-940F-0846AC8B04CD}.PGUpdate|x64.Build.0 = Release|Win32 + {C73F0EC1-358B-4177-940F-0846AC8B04CD}.Release|Win32.ActiveCfg = Release|Win32 + {C73F0EC1-358B-4177-940F-0846AC8B04CD}.Release|Win32.Build.0 = Release|Win32 + {C73F0EC1-358B-4177-940F-0846AC8B04CD}.Release|x64.ActiveCfg = Release|Win32 + {C73F0EC1-358B-4177-940F-0846AC8B04CD}.Release|x64.Build.0 = Release|Win32 + {28B5D777-DDF2-4B6B-B34F-31D938813856}.Debug|Win32.ActiveCfg = Debug|Win32 + {28B5D777-DDF2-4B6B-B34F-31D938813856}.Debug|Win32.Build.0 = Debug|Win32 + {28B5D777-DDF2-4B6B-B34F-31D938813856}.Debug|x64.ActiveCfg = Debug|x64 + {28B5D777-DDF2-4B6B-B34F-31D938813856}.Debug|x64.Build.0 = Debug|x64 + {28B5D777-DDF2-4B6B-B34F-31D938813856}.PGInstrument|Win32.ActiveCfg = PGInstrument|Win32 + {28B5D777-DDF2-4B6B-B34F-31D938813856}.PGInstrument|Win32.Build.0 = PGInstrument|Win32 + {28B5D777-DDF2-4B6B-B34F-31D938813856}.PGInstrument|x64.ActiveCfg = PGInstrument|x64 + {28B5D777-DDF2-4B6B-B34F-31D938813856}.PGInstrument|x64.Build.0 = PGInstrument|x64 + {28B5D777-DDF2-4B6B-B34F-31D938813856}.PGUpdate|Win32.ActiveCfg = PGUpdate|Win32 + {28B5D777-DDF2-4B6B-B34F-31D938813856}.PGUpdate|Win32.Build.0 = PGUpdate|Win32 + {28B5D777-DDF2-4B6B-B34F-31D938813856}.PGUpdate|x64.ActiveCfg = PGUpdate|x64 + {28B5D777-DDF2-4B6B-B34F-31D938813856}.PGUpdate|x64.Build.0 = PGUpdate|x64 + {28B5D777-DDF2-4B6B-B34F-31D938813856}.Release|Win32.ActiveCfg = Release|Win32 + {28B5D777-DDF2-4B6B-B34F-31D938813856}.Release|Win32.Build.0 = Release|Win32 + {28B5D777-DDF2-4B6B-B34F-31D938813856}.Release|x64.ActiveCfg = Release|x64 + {28B5D777-DDF2-4B6B-B34F-31D938813856}.Release|x64.Build.0 = Release|x64 + {B4D38F3F-68FB-42EC-A45D-E00657BB3627}.Debug|Win32.ActiveCfg = Debug|Win32 + {B4D38F3F-68FB-42EC-A45D-E00657BB3627}.Debug|Win32.Build.0 = Debug|Win32 + {B4D38F3F-68FB-42EC-A45D-E00657BB3627}.Debug|x64.ActiveCfg = Debug|x64 + {B4D38F3F-68FB-42EC-A45D-E00657BB3627}.Debug|x64.Build.0 = Debug|x64 + {B4D38F3F-68FB-42EC-A45D-E00657BB3627}.PGInstrument|Win32.ActiveCfg = PGInstrument|Win32 + {B4D38F3F-68FB-42EC-A45D-E00657BB3627}.PGInstrument|Win32.Build.0 = PGInstrument|Win32 + {B4D38F3F-68FB-42EC-A45D-E00657BB3627}.PGInstrument|x64.ActiveCfg = PGInstrument|x64 + {B4D38F3F-68FB-42EC-A45D-E00657BB3627}.PGInstrument|x64.Build.0 = PGInstrument|x64 + {B4D38F3F-68FB-42EC-A45D-E00657BB3627}.PGUpdate|Win32.ActiveCfg = PGUpdate|Win32 + {B4D38F3F-68FB-42EC-A45D-E00657BB3627}.PGUpdate|Win32.Build.0 = PGUpdate|Win32 + {B4D38F3F-68FB-42EC-A45D-E00657BB3627}.PGUpdate|x64.ActiveCfg = PGUpdate|x64 + {B4D38F3F-68FB-42EC-A45D-E00657BB3627}.PGUpdate|x64.Build.0 = PGUpdate|x64 + {B4D38F3F-68FB-42EC-A45D-E00657BB3627}.Release|Win32.ActiveCfg = Release|Win32 + {B4D38F3F-68FB-42EC-A45D-E00657BB3627}.Release|Win32.Build.0 = Release|Win32 + {B4D38F3F-68FB-42EC-A45D-E00657BB3627}.Release|x64.ActiveCfg = Release|x64 + {B4D38F3F-68FB-42EC-A45D-E00657BB3627}.Release|x64.Build.0 = Release|x64 + {0E9791DB-593A-465F-98BC-681011311618}.Debug|Win32.ActiveCfg = Debug|Win32 + {0E9791DB-593A-465F-98BC-681011311618}.Debug|Win32.Build.0 = Debug|Win32 + {0E9791DB-593A-465F-98BC-681011311618}.Debug|x64.ActiveCfg = Debug|x64 + {0E9791DB-593A-465F-98BC-681011311618}.Debug|x64.Build.0 = Debug|x64 + {0E9791DB-593A-465F-98BC-681011311618}.PGInstrument|Win32.ActiveCfg = PGInstrument|Win32 + {0E9791DB-593A-465F-98BC-681011311618}.PGInstrument|Win32.Build.0 = PGInstrument|Win32 + {0E9791DB-593A-465F-98BC-681011311618}.PGInstrument|x64.ActiveCfg = PGInstrument|x64 + {0E9791DB-593A-465F-98BC-681011311618}.PGInstrument|x64.Build.0 = PGInstrument|x64 + {0E9791DB-593A-465F-98BC-681011311618}.PGUpdate|Win32.ActiveCfg = PGUpdate|Win32 + {0E9791DB-593A-465F-98BC-681011311618}.PGUpdate|Win32.Build.0 = PGUpdate|Win32 + {0E9791DB-593A-465F-98BC-681011311618}.PGUpdate|x64.ActiveCfg = PGUpdate|x64 + {0E9791DB-593A-465F-98BC-681011311618}.PGUpdate|x64.Build.0 = PGUpdate|x64 + {0E9791DB-593A-465F-98BC-681011311618}.Release|Win32.ActiveCfg = Release|Win32 + {0E9791DB-593A-465F-98BC-681011311618}.Release|Win32.Build.0 = Release|Win32 + {0E9791DB-593A-465F-98BC-681011311618}.Release|x64.ActiveCfg = Release|x64 + {0E9791DB-593A-465F-98BC-681011311618}.Release|x64.Build.0 = Release|x64 + {9EC7190A-249F-4180-A900-548FDCF3055F}.Debug|Win32.ActiveCfg = Debug|Win32 + {9EC7190A-249F-4180-A900-548FDCF3055F}.Debug|Win32.Build.0 = Debug|Win32 + {9EC7190A-249F-4180-A900-548FDCF3055F}.Debug|x64.ActiveCfg = Debug|x64 + {9EC7190A-249F-4180-A900-548FDCF3055F}.Debug|x64.Build.0 = Debug|x64 + {9EC7190A-249F-4180-A900-548FDCF3055F}.PGInstrument|Win32.ActiveCfg = PGInstrument|Win32 + {9EC7190A-249F-4180-A900-548FDCF3055F}.PGInstrument|Win32.Build.0 = PGInstrument|Win32 + {9EC7190A-249F-4180-A900-548FDCF3055F}.PGInstrument|x64.ActiveCfg = PGInstrument|x64 + {9EC7190A-249F-4180-A900-548FDCF3055F}.PGInstrument|x64.Build.0 = PGInstrument|x64 + {9EC7190A-249F-4180-A900-548FDCF3055F}.PGUpdate|Win32.ActiveCfg = PGUpdate|Win32 + {9EC7190A-249F-4180-A900-548FDCF3055F}.PGUpdate|Win32.Build.0 = PGUpdate|Win32 + {9EC7190A-249F-4180-A900-548FDCF3055F}.PGUpdate|x64.ActiveCfg = PGUpdate|x64 + {9EC7190A-249F-4180-A900-548FDCF3055F}.PGUpdate|x64.Build.0 = PGUpdate|x64 + {9EC7190A-249F-4180-A900-548FDCF3055F}.Release|Win32.ActiveCfg = Release|Win32 + {9EC7190A-249F-4180-A900-548FDCF3055F}.Release|Win32.Build.0 = Release|Win32 + {9EC7190A-249F-4180-A900-548FDCF3055F}.Release|x64.ActiveCfg = Release|x64 + {9EC7190A-249F-4180-A900-548FDCF3055F}.Release|x64.Build.0 = Release|x64 + {17E1E049-C309-4D79-843F-AE483C264AEA}.Debug|Win32.ActiveCfg = Debug|Win32 + {17E1E049-C309-4D79-843F-AE483C264AEA}.Debug|Win32.Build.0 = Debug|Win32 + {17E1E049-C309-4D79-843F-AE483C264AEA}.Debug|x64.ActiveCfg = Debug|x64 + {17E1E049-C309-4D79-843F-AE483C264AEA}.Debug|x64.Build.0 = Debug|x64 + {17E1E049-C309-4D79-843F-AE483C264AEA}.PGInstrument|Win32.ActiveCfg = PGInstrument|Win32 + {17E1E049-C309-4D79-843F-AE483C264AEA}.PGInstrument|Win32.Build.0 = PGInstrument|Win32 + {17E1E049-C309-4D79-843F-AE483C264AEA}.PGInstrument|x64.ActiveCfg = PGInstrument|x64 + {17E1E049-C309-4D79-843F-AE483C264AEA}.PGInstrument|x64.Build.0 = PGInstrument|x64 + {17E1E049-C309-4D79-843F-AE483C264AEA}.PGUpdate|Win32.ActiveCfg = PGUpdate|Win32 + {17E1E049-C309-4D79-843F-AE483C264AEA}.PGUpdate|Win32.Build.0 = PGUpdate|Win32 + {17E1E049-C309-4D79-843F-AE483C264AEA}.PGUpdate|x64.ActiveCfg = PGUpdate|x64 + {17E1E049-C309-4D79-843F-AE483C264AEA}.PGUpdate|x64.Build.0 = PGUpdate|x64 + {17E1E049-C309-4D79-843F-AE483C264AEA}.Release|Win32.ActiveCfg = Release|Win32 + {17E1E049-C309-4D79-843F-AE483C264AEA}.Release|Win32.Build.0 = Release|Win32 + {17E1E049-C309-4D79-843F-AE483C264AEA}.Release|x64.ActiveCfg = Release|x64 + {17E1E049-C309-4D79-843F-AE483C264AEA}.Release|x64.Build.0 = Release|x64 + {31FFC478-7B4A-43E8-9954-8D03E2187E9C}.Debug|Win32.ActiveCfg = Debug|Win32 + {31FFC478-7B4A-43E8-9954-8D03E2187E9C}.Debug|Win32.Build.0 = Debug|Win32 + {31FFC478-7B4A-43E8-9954-8D03E2187E9C}.Debug|x64.ActiveCfg = Debug|x64 + {31FFC478-7B4A-43E8-9954-8D03E2187E9C}.Debug|x64.Build.0 = Debug|x64 + {31FFC478-7B4A-43E8-9954-8D03E2187E9C}.PGInstrument|Win32.ActiveCfg = PGInstrument|Win32 + {31FFC478-7B4A-43E8-9954-8D03E2187E9C}.PGInstrument|Win32.Build.0 = PGInstrument|Win32 + {31FFC478-7B4A-43E8-9954-8D03E2187E9C}.PGInstrument|x64.ActiveCfg = PGInstrument|x64 + {31FFC478-7B4A-43E8-9954-8D03E2187E9C}.PGInstrument|x64.Build.0 = PGInstrument|x64 + {31FFC478-7B4A-43E8-9954-8D03E2187E9C}.PGUpdate|Win32.ActiveCfg = PGUpdate|Win32 + {31FFC478-7B4A-43E8-9954-8D03E2187E9C}.PGUpdate|Win32.Build.0 = PGUpdate|Win32 + {31FFC478-7B4A-43E8-9954-8D03E2187E9C}.PGUpdate|x64.ActiveCfg = PGUpdate|x64 + {31FFC478-7B4A-43E8-9954-8D03E2187E9C}.PGUpdate|x64.Build.0 = PGUpdate|x64 + {31FFC478-7B4A-43E8-9954-8D03E2187E9C}.Release|Win32.ActiveCfg = Release|Win32 + {31FFC478-7B4A-43E8-9954-8D03E2187E9C}.Release|Win32.Build.0 = Release|Win32 + {31FFC478-7B4A-43E8-9954-8D03E2187E9C}.Release|x64.ActiveCfg = Release|x64 + {31FFC478-7B4A-43E8-9954-8D03E2187E9C}.Release|x64.Build.0 = Release|x64 + {86937F53-C189-40EF-8CE8-8759D8E7D480}.Debug|Win32.ActiveCfg = Debug|Win32 + {86937F53-C189-40EF-8CE8-8759D8E7D480}.Debug|Win32.Build.0 = Debug|Win32 + {86937F53-C189-40EF-8CE8-8759D8E7D480}.Debug|x64.ActiveCfg = Debug|x64 + {86937F53-C189-40EF-8CE8-8759D8E7D480}.Debug|x64.Build.0 = Debug|x64 + {86937F53-C189-40EF-8CE8-8759D8E7D480}.PGInstrument|Win32.ActiveCfg = PGInstrument|Win32 + {86937F53-C189-40EF-8CE8-8759D8E7D480}.PGInstrument|Win32.Build.0 = PGInstrument|Win32 + {86937F53-C189-40EF-8CE8-8759D8E7D480}.PGInstrument|x64.ActiveCfg = PGInstrument|x64 + {86937F53-C189-40EF-8CE8-8759D8E7D480}.PGInstrument|x64.Build.0 = PGInstrument|x64 + {86937F53-C189-40EF-8CE8-8759D8E7D480}.PGUpdate|Win32.ActiveCfg = PGUpdate|Win32 + {86937F53-C189-40EF-8CE8-8759D8E7D480}.PGUpdate|Win32.Build.0 = PGUpdate|Win32 + {86937F53-C189-40EF-8CE8-8759D8E7D480}.PGUpdate|x64.ActiveCfg = PGUpdate|x64 + {86937F53-C189-40EF-8CE8-8759D8E7D480}.PGUpdate|x64.Build.0 = PGUpdate|x64 + {86937F53-C189-40EF-8CE8-8759D8E7D480}.Release|Win32.ActiveCfg = Release|Win32 + {86937F53-C189-40EF-8CE8-8759D8E7D480}.Release|Win32.Build.0 = Release|Win32 + {86937F53-C189-40EF-8CE8-8759D8E7D480}.Release|x64.ActiveCfg = Release|x64 + {86937F53-C189-40EF-8CE8-8759D8E7D480}.Release|x64.Build.0 = Release|x64 + {13CECB97-4119-4316-9D42-8534019A5A44}.Debug|Win32.ActiveCfg = Debug|Win32 + {13CECB97-4119-4316-9D42-8534019A5A44}.Debug|Win32.Build.0 = Debug|Win32 + {13CECB97-4119-4316-9D42-8534019A5A44}.Debug|x64.ActiveCfg = Debug|x64 + {13CECB97-4119-4316-9D42-8534019A5A44}.Debug|x64.Build.0 = Debug|x64 + {13CECB97-4119-4316-9D42-8534019A5A44}.PGInstrument|Win32.ActiveCfg = PGInstrument|Win32 + {13CECB97-4119-4316-9D42-8534019A5A44}.PGInstrument|Win32.Build.0 = PGInstrument|Win32 + {13CECB97-4119-4316-9D42-8534019A5A44}.PGInstrument|x64.ActiveCfg = PGInstrument|x64 + {13CECB97-4119-4316-9D42-8534019A5A44}.PGInstrument|x64.Build.0 = PGInstrument|x64 + {13CECB97-4119-4316-9D42-8534019A5A44}.PGUpdate|Win32.ActiveCfg = PGUpdate|Win32 + {13CECB97-4119-4316-9D42-8534019A5A44}.PGUpdate|Win32.Build.0 = PGUpdate|Win32 + {13CECB97-4119-4316-9D42-8534019A5A44}.PGUpdate|x64.ActiveCfg = PGUpdate|x64 + {13CECB97-4119-4316-9D42-8534019A5A44}.PGUpdate|x64.Build.0 = PGUpdate|x64 + {13CECB97-4119-4316-9D42-8534019A5A44}.Release|Win32.ActiveCfg = Release|Win32 + {13CECB97-4119-4316-9D42-8534019A5A44}.Release|Win32.Build.0 = Release|Win32 + {13CECB97-4119-4316-9D42-8534019A5A44}.Release|x64.ActiveCfg = Release|x64 + {13CECB97-4119-4316-9D42-8534019A5A44}.Release|x64.Build.0 = Release|x64 + {C6E20F84-3247-4AD6-B051-B073268F73BA}.Debug|Win32.ActiveCfg = Debug|Win32 + {C6E20F84-3247-4AD6-B051-B073268F73BA}.Debug|Win32.Build.0 = Debug|Win32 + {C6E20F84-3247-4AD6-B051-B073268F73BA}.Debug|x64.ActiveCfg = Debug|x64 + {C6E20F84-3247-4AD6-B051-B073268F73BA}.Debug|x64.Build.0 = Debug|x64 + {C6E20F84-3247-4AD6-B051-B073268F73BA}.PGInstrument|Win32.ActiveCfg = PGInstrument|Win32 + {C6E20F84-3247-4AD6-B051-B073268F73BA}.PGInstrument|Win32.Build.0 = PGInstrument|Win32 + {C6E20F84-3247-4AD6-B051-B073268F73BA}.PGInstrument|x64.ActiveCfg = PGInstrument|x64 + {C6E20F84-3247-4AD6-B051-B073268F73BA}.PGInstrument|x64.Build.0 = PGInstrument|x64 + {C6E20F84-3247-4AD6-B051-B073268F73BA}.PGUpdate|Win32.ActiveCfg = PGUpdate|Win32 + {C6E20F84-3247-4AD6-B051-B073268F73BA}.PGUpdate|Win32.Build.0 = PGUpdate|Win32 + {C6E20F84-3247-4AD6-B051-B073268F73BA}.PGUpdate|x64.ActiveCfg = PGUpdate|x64 + {C6E20F84-3247-4AD6-B051-B073268F73BA}.PGUpdate|x64.Build.0 = PGUpdate|x64 + {C6E20F84-3247-4AD6-B051-B073268F73BA}.Release|Win32.ActiveCfg = Release|Win32 + {C6E20F84-3247-4AD6-B051-B073268F73BA}.Release|Win32.Build.0 = Release|Win32 + {C6E20F84-3247-4AD6-B051-B073268F73BA}.Release|x64.ActiveCfg = Release|x64 + {C6E20F84-3247-4AD6-B051-B073268F73BA}.Release|x64.Build.0 = Release|x64 + {6901D91C-6E48-4BB7-9FEC-700C8131DF1D}.Debug|Win32.ActiveCfg = Debug|Win32 + {6901D91C-6E48-4BB7-9FEC-700C8131DF1D}.Debug|Win32.Build.0 = Debug|Win32 + {6901D91C-6E48-4BB7-9FEC-700C8131DF1D}.Debug|x64.ActiveCfg = Debug|x64 + {6901D91C-6E48-4BB7-9FEC-700C8131DF1D}.Debug|x64.Build.0 = Debug|x64 + {6901D91C-6E48-4BB7-9FEC-700C8131DF1D}.PGInstrument|Win32.ActiveCfg = PGInstrument|Win32 + {6901D91C-6E48-4BB7-9FEC-700C8131DF1D}.PGInstrument|Win32.Build.0 = PGInstrument|Win32 + {6901D91C-6E48-4BB7-9FEC-700C8131DF1D}.PGInstrument|x64.ActiveCfg = PGInstrument|x64 + {6901D91C-6E48-4BB7-9FEC-700C8131DF1D}.PGInstrument|x64.Build.0 = PGInstrument|x64 + {6901D91C-6E48-4BB7-9FEC-700C8131DF1D}.PGUpdate|Win32.ActiveCfg = PGUpdate|Win32 + {6901D91C-6E48-4BB7-9FEC-700C8131DF1D}.PGUpdate|Win32.Build.0 = PGUpdate|Win32 + {6901D91C-6E48-4BB7-9FEC-700C8131DF1D}.PGUpdate|x64.ActiveCfg = PGUpdate|x64 + {6901D91C-6E48-4BB7-9FEC-700C8131DF1D}.PGUpdate|x64.Build.0 = PGUpdate|x64 + {6901D91C-6E48-4BB7-9FEC-700C8131DF1D}.Release|Win32.ActiveCfg = Release|Win32 + {6901D91C-6E48-4BB7-9FEC-700C8131DF1D}.Release|Win32.Build.0 = Release|Win32 + {6901D91C-6E48-4BB7-9FEC-700C8131DF1D}.Release|x64.ActiveCfg = Release|x64 + {6901D91C-6E48-4BB7-9FEC-700C8131DF1D}.Release|x64.Build.0 = Release|x64 + {4946ECAC-2E69-4BF8-A90A-F5136F5094DF}.Debug|Win32.ActiveCfg = Debug|Win32 + {4946ECAC-2E69-4BF8-A90A-F5136F5094DF}.Debug|Win32.Build.0 = Debug|Win32 + {4946ECAC-2E69-4BF8-A90A-F5136F5094DF}.Debug|x64.ActiveCfg = Debug|x64 + {4946ECAC-2E69-4BF8-A90A-F5136F5094DF}.Debug|x64.Build.0 = Debug|x64 + {4946ECAC-2E69-4BF8-A90A-F5136F5094DF}.PGInstrument|Win32.ActiveCfg = PGInstrument|Win32 + {4946ECAC-2E69-4BF8-A90A-F5136F5094DF}.PGInstrument|Win32.Build.0 = PGInstrument|Win32 + {4946ECAC-2E69-4BF8-A90A-F5136F5094DF}.PGInstrument|x64.ActiveCfg = PGInstrument|x64 + {4946ECAC-2E69-4BF8-A90A-F5136F5094DF}.PGInstrument|x64.Build.0 = PGInstrument|x64 + {4946ECAC-2E69-4BF8-A90A-F5136F5094DF}.PGUpdate|Win32.ActiveCfg = PGUpdate|Win32 + {4946ECAC-2E69-4BF8-A90A-F5136F5094DF}.PGUpdate|Win32.Build.0 = PGUpdate|Win32 + {4946ECAC-2E69-4BF8-A90A-F5136F5094DF}.PGUpdate|x64.ActiveCfg = PGUpdate|x64 + {4946ECAC-2E69-4BF8-A90A-F5136F5094DF}.PGUpdate|x64.Build.0 = PGUpdate|x64 + {4946ECAC-2E69-4BF8-A90A-F5136F5094DF}.Release|Win32.ActiveCfg = Release|Win32 + {4946ECAC-2E69-4BF8-A90A-F5136F5094DF}.Release|Win32.Build.0 = Release|Win32 + {4946ECAC-2E69-4BF8-A90A-F5136F5094DF}.Release|x64.ActiveCfg = Release|x64 + {4946ECAC-2E69-4BF8-A90A-F5136F5094DF}.Release|x64.Build.0 = Release|x64 + {73FCD2BD-F133-46B7-8EC1-144CD82A59D5}.Debug|Win32.ActiveCfg = Debug|Win32 + {73FCD2BD-F133-46B7-8EC1-144CD82A59D5}.Debug|Win32.Build.0 = Debug|Win32 + {73FCD2BD-F133-46B7-8EC1-144CD82A59D5}.Debug|x64.ActiveCfg = Debug|x64 + {73FCD2BD-F133-46B7-8EC1-144CD82A59D5}.Debug|x64.Build.0 = Debug|x64 + {73FCD2BD-F133-46B7-8EC1-144CD82A59D5}.PGInstrument|Win32.ActiveCfg = PGInstrument|Win32 + {73FCD2BD-F133-46B7-8EC1-144CD82A59D5}.PGInstrument|Win32.Build.0 = PGInstrument|Win32 + {73FCD2BD-F133-46B7-8EC1-144CD82A59D5}.PGInstrument|x64.ActiveCfg = PGInstrument|x64 + {73FCD2BD-F133-46B7-8EC1-144CD82A59D5}.PGInstrument|x64.Build.0 = PGInstrument|x64 + {73FCD2BD-F133-46B7-8EC1-144CD82A59D5}.PGUpdate|Win32.ActiveCfg = PGUpdate|Win32 + {73FCD2BD-F133-46B7-8EC1-144CD82A59D5}.PGUpdate|Win32.Build.0 = PGUpdate|Win32 + {73FCD2BD-F133-46B7-8EC1-144CD82A59D5}.PGUpdate|x64.ActiveCfg = PGUpdate|x64 + {73FCD2BD-F133-46B7-8EC1-144CD82A59D5}.PGUpdate|x64.Build.0 = PGUpdate|x64 + {73FCD2BD-F133-46B7-8EC1-144CD82A59D5}.Release|Win32.ActiveCfg = Release|Win32 + {73FCD2BD-F133-46B7-8EC1-144CD82A59D5}.Release|Win32.Build.0 = Release|Win32 + {73FCD2BD-F133-46B7-8EC1-144CD82A59D5}.Release|x64.ActiveCfg = Release|x64 + {73FCD2BD-F133-46B7-8EC1-144CD82A59D5}.Release|x64.Build.0 = Release|x64 + {18CAE28C-B454-46C1-87A0-493D91D97F03}.Debug|Win32.ActiveCfg = Debug|Win32 + {18CAE28C-B454-46C1-87A0-493D91D97F03}.Debug|Win32.Build.0 = Debug|Win32 + {18CAE28C-B454-46C1-87A0-493D91D97F03}.Debug|x64.ActiveCfg = Debug|x64 + {18CAE28C-B454-46C1-87A0-493D91D97F03}.Debug|x64.Build.0 = Debug|x64 + {18CAE28C-B454-46C1-87A0-493D91D97F03}.PGInstrument|Win32.ActiveCfg = PGInstrument|Win32 + {18CAE28C-B454-46C1-87A0-493D91D97F03}.PGInstrument|Win32.Build.0 = PGInstrument|Win32 + {18CAE28C-B454-46C1-87A0-493D91D97F03}.PGInstrument|x64.ActiveCfg = PGInstrument|x64 + {18CAE28C-B454-46C1-87A0-493D91D97F03}.PGInstrument|x64.Build.0 = PGInstrument|x64 + {18CAE28C-B454-46C1-87A0-493D91D97F03}.PGUpdate|Win32.ActiveCfg = PGUpdate|Win32 + {18CAE28C-B454-46C1-87A0-493D91D97F03}.PGUpdate|Win32.Build.0 = PGUpdate|Win32 + {18CAE28C-B454-46C1-87A0-493D91D97F03}.PGUpdate|x64.ActiveCfg = PGUpdate|x64 + {18CAE28C-B454-46C1-87A0-493D91D97F03}.PGUpdate|x64.Build.0 = PGUpdate|x64 + {18CAE28C-B454-46C1-87A0-493D91D97F03}.Release|Win32.ActiveCfg = Release|Win32 + {18CAE28C-B454-46C1-87A0-493D91D97F03}.Release|Win32.Build.0 = Release|Win32 + {18CAE28C-B454-46C1-87A0-493D91D97F03}.Release|x64.ActiveCfg = Release|x64 + {18CAE28C-B454-46C1-87A0-493D91D97F03}.Release|x64.Build.0 = Release|x64 + {ECC7CEAC-A5E5-458E-BB9E-2413CC847881}.Debug|Win32.ActiveCfg = Debug|Win32 + {ECC7CEAC-A5E5-458E-BB9E-2413CC847881}.Debug|Win32.Build.0 = Debug|Win32 + {ECC7CEAC-A5E5-458E-BB9E-2413CC847881}.Debug|x64.ActiveCfg = Debug|x64 + {ECC7CEAC-A5E5-458E-BB9E-2413CC847881}.Debug|x64.Build.0 = Debug|x64 + {ECC7CEAC-A5E5-458E-BB9E-2413CC847881}.PGInstrument|Win32.ActiveCfg = PGInstrument|Win32 + {ECC7CEAC-A5E5-458E-BB9E-2413CC847881}.PGInstrument|Win32.Build.0 = PGInstrument|Win32 + {ECC7CEAC-A5E5-458E-BB9E-2413CC847881}.PGInstrument|x64.ActiveCfg = PGInstrument|x64 + {ECC7CEAC-A5E5-458E-BB9E-2413CC847881}.PGInstrument|x64.Build.0 = PGInstrument|x64 + {ECC7CEAC-A5E5-458E-BB9E-2413CC847881}.PGUpdate|Win32.ActiveCfg = PGUpdate|Win32 + {ECC7CEAC-A5E5-458E-BB9E-2413CC847881}.PGUpdate|Win32.Build.0 = PGUpdate|Win32 + {ECC7CEAC-A5E5-458E-BB9E-2413CC847881}.PGUpdate|x64.ActiveCfg = PGUpdate|x64 + {ECC7CEAC-A5E5-458E-BB9E-2413CC847881}.PGUpdate|x64.Build.0 = PGUpdate|x64 + {ECC7CEAC-A5E5-458E-BB9E-2413CC847881}.Release|Win32.ActiveCfg = Release|Win32 + {ECC7CEAC-A5E5-458E-BB9E-2413CC847881}.Release|Win32.Build.0 = Release|Win32 + {ECC7CEAC-A5E5-458E-BB9E-2413CC847881}.Release|x64.ActiveCfg = Release|x64 + {ECC7CEAC-A5E5-458E-BB9E-2413CC847881}.Release|x64.Build.0 = Release|x64 + {D06B6426-4762-44CC-8BAD-D79052507F2F}.Debug|Win32.ActiveCfg = Debug|Win32 + {D06B6426-4762-44CC-8BAD-D79052507F2F}.Debug|Win32.Build.0 = Debug|Win32 + {D06B6426-4762-44CC-8BAD-D79052507F2F}.Debug|x64.ActiveCfg = Debug|x64 + {D06B6426-4762-44CC-8BAD-D79052507F2F}.Debug|x64.Build.0 = Debug|x64 + {D06B6426-4762-44CC-8BAD-D79052507F2F}.PGInstrument|Win32.ActiveCfg = PGInstrument|Win32 + {D06B6426-4762-44CC-8BAD-D79052507F2F}.PGInstrument|Win32.Build.0 = PGInstrument|Win32 + {D06B6426-4762-44CC-8BAD-D79052507F2F}.PGInstrument|x64.ActiveCfg = PGInstrument|x64 + {D06B6426-4762-44CC-8BAD-D79052507F2F}.PGInstrument|x64.Build.0 = PGInstrument|x64 + {D06B6426-4762-44CC-8BAD-D79052507F2F}.PGUpdate|Win32.ActiveCfg = PGUpdate|Win32 + {D06B6426-4762-44CC-8BAD-D79052507F2F}.PGUpdate|Win32.Build.0 = PGUpdate|Win32 + {D06B6426-4762-44CC-8BAD-D79052507F2F}.PGUpdate|x64.ActiveCfg = PGUpdate|x64 + {D06B6426-4762-44CC-8BAD-D79052507F2F}.PGUpdate|x64.Build.0 = PGUpdate|x64 + {D06B6426-4762-44CC-8BAD-D79052507F2F}.Release|Win32.ActiveCfg = Release|Win32 + {D06B6426-4762-44CC-8BAD-D79052507F2F}.Release|Win32.Build.0 = Release|Win32 + {D06B6426-4762-44CC-8BAD-D79052507F2F}.Release|x64.ActiveCfg = Release|x64 + {D06B6426-4762-44CC-8BAD-D79052507F2F}.Release|x64.Build.0 = Release|x64 + {EB1C19C1-1F18-421E-9735-CAEE69DC6A3C}.Debug|Win32.ActiveCfg = Release|Win32 + {EB1C19C1-1F18-421E-9735-CAEE69DC6A3C}.Debug|x64.ActiveCfg = Release|Win32 + {EB1C19C1-1F18-421E-9735-CAEE69DC6A3C}.PGInstrument|Win32.ActiveCfg = Release|Win32 + {EB1C19C1-1F18-421E-9735-CAEE69DC6A3C}.PGInstrument|x64.ActiveCfg = Release|Win32 + {EB1C19C1-1F18-421E-9735-CAEE69DC6A3C}.PGUpdate|Win32.ActiveCfg = Release|Win32 + {EB1C19C1-1F18-421E-9735-CAEE69DC6A3C}.PGUpdate|x64.ActiveCfg = Release|Win32 + {EB1C19C1-1F18-421E-9735-CAEE69DC6A3C}.Release|Win32.ActiveCfg = Release|Win32 + {EB1C19C1-1F18-421E-9735-CAEE69DC6A3C}.Release|x64.ActiveCfg = Release|Win32 + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection +EndGlobal Added: python/trunk/PC/VS8.0/pginstrument.vsprops ============================================================================== --- (empty file) +++ python/trunk/PC/VS8.0/pginstrument.vsprops Wed Jan 2 18:43:40 2008 @@ -0,0 +1,34 @@ + + + + + + Added: python/trunk/PC/VS8.0/pgupdate.vsprops ============================================================================== --- (empty file) +++ python/trunk/PC/VS8.0/pgupdate.vsprops Wed Jan 2 18:43:40 2008 @@ -0,0 +1,14 @@ + + + + Added: python/trunk/PC/VS8.0/pyd.vsprops ============================================================================== --- (empty file) +++ python/trunk/PC/VS8.0/pyd.vsprops Wed Jan 2 18:43:40 2008 @@ -0,0 +1,22 @@ + + + + + + Added: python/trunk/PC/VS8.0/pyd_d.vsprops ============================================================================== --- (empty file) +++ python/trunk/PC/VS8.0/pyd_d.vsprops Wed Jan 2 18:43:40 2008 @@ -0,0 +1,30 @@ + + + + + + + Added: python/trunk/PC/VS8.0/pyexpat.vcproj ============================================================================== --- (empty file) +++ python/trunk/PC/VS8.0/pyexpat.vcproj Wed Jan 2 18:43:40 2008 @@ -0,0 +1,553 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Added: python/trunk/PC/VS8.0/pyproject.vsprops ============================================================================== --- (empty file) +++ python/trunk/PC/VS8.0/pyproject.vsprops Wed Jan 2 18:43:40 2008 @@ -0,0 +1,79 @@ + + + + + + + + + + + + + + + + Added: python/trunk/PC/VS8.0/python.vcproj ============================================================================== --- (empty file) +++ python/trunk/PC/VS8.0/python.vcproj Wed Jan 2 18:43:40 2008 @@ -0,0 +1,645 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Added: python/trunk/PC/VS8.0/pythoncore.vcproj ============================================================================== --- (empty file) +++ python/trunk/PC/VS8.0/pythoncore.vcproj Wed Jan 2 18:43:40 2008 @@ -0,0 +1,1773 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Added: python/trunk/PC/VS8.0/pythonw.vcproj ============================================================================== --- (empty file) +++ python/trunk/PC/VS8.0/pythonw.vcproj Wed Jan 2 18:43:40 2008 @@ -0,0 +1,618 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Added: python/trunk/PC/VS8.0/release.vsprops ============================================================================== --- (empty file) +++ python/trunk/PC/VS8.0/release.vsprops Wed Jan 2 18:43:40 2008 @@ -0,0 +1,11 @@ + + + + Added: python/trunk/PC/VS8.0/rmpyc.py ============================================================================== --- (empty file) +++ python/trunk/PC/VS8.0/rmpyc.py Wed Jan 2 18:43:40 2008 @@ -0,0 +1,25 @@ +# Remove all the .pyc and .pyo files under ../Lib. + + +def deltree(root): + import os + from os.path import join + + npyc = npyo = 0 + for root, dirs, files in os.walk(root): + for name in files: + delete = False + if name.endswith('.pyc'): + delete = True + npyc += 1 + elif name.endswith('.pyo'): + delete = True + npyo += 1 + + if delete: + os.remove(join(root, name)) + + return npyc, npyo + +npyc, npyo = deltree("../../Lib") +print(npyc, ".pyc deleted,", npyo, ".pyo deleted") Added: python/trunk/PC/VS8.0/rt.bat ============================================================================== --- (empty file) +++ python/trunk/PC/VS8.0/rt.bat Wed Jan 2 18:43:40 2008 @@ -0,0 +1,52 @@ + at echo off +rem Run Tests. Run the regression test suite. +rem Usage: rt [-d] [-O] [-q] regrtest_args +rem -d Run Debug build (python_d.exe). Else release build. +rem -O Run python.exe or python_d.exe (see -d) with -O. +rem -q "quick" -- normally the tests are run twice, the first time +rem after deleting all the .py[co] files reachable from Lib/. +rem -q runs the tests just once, and without deleting .py[co] files. +rem All leading instances of these switches are shifted off, and +rem whatever remains is passed to regrtest.py. For example, +rem rt -O -d -x test_thread +rem runs +rem python_d -O ../lib/test/regrtest.py -x test_thread +rem twice, and +rem rt -q -g test_binascii +rem runs +rem python_d ../lib/test/regrtest.py -g test_binascii +rem to generate the expected-output file for binascii quickly. +rem +rem Confusing: if you want to pass a comma-separated list, like +rem -u network,largefile +rem then you have to quote it on the rt line, like +rem rt -u "network,largefile" + +setlocal + +set exe=python +set qmode= +set dashO= +PATH %PATH%;..\..\..\tcltk\bin + +:CheckOpts +if "%1"=="-O" (set dashO=-O) & shift & goto CheckOpts +if "%1"=="-q" (set qmode=yes) & shift & goto CheckOpts +if "%1"=="-d" (set exe=python_d) & shift & goto CheckOpts + +set cmd=%exe% %dashO% -E -tt ../../lib/test/regrtest.py %1 %2 %3 %4 %5 %6 %7 %8 %9 +if defined qmode goto Qmode + +echo Deleting .pyc/.pyo files ... +%exe% rmpyc.py + +echo on +%cmd% + at echo off + +echo About to run again without deleting .pyc/.pyo first: +pause + +:Qmode +echo on +%cmd% Added: python/trunk/PC/VS8.0/select.vcproj ============================================================================== --- (empty file) +++ python/trunk/PC/VS8.0/select.vcproj Wed Jan 2 18:43:40 2008 @@ -0,0 +1,537 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Added: python/trunk/PC/VS8.0/unicodedata.vcproj ============================================================================== --- (empty file) +++ python/trunk/PC/VS8.0/unicodedata.vcproj Wed Jan 2 18:43:40 2008 @@ -0,0 +1,533 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Added: python/trunk/PC/VS8.0/w9xpopen.vcproj ============================================================================== --- (empty file) +++ python/trunk/PC/VS8.0/w9xpopen.vcproj Wed Jan 2 18:43:40 2008 @@ -0,0 +1,576 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Added: python/trunk/PC/VS8.0/winsound.vcproj ============================================================================== --- (empty file) +++ python/trunk/PC/VS8.0/winsound.vcproj Wed Jan 2 18:43:40 2008 @@ -0,0 +1,523 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Added: python/trunk/PC/VS8.0/x64.vsprops ============================================================================== --- (empty file) +++ python/trunk/PC/VS8.0/x64.vsprops Wed Jan 2 18:43:40 2008 @@ -0,0 +1,18 @@ + + + + + Modified: python/trunk/PCbuild/readme.txt ============================================================================== --- python/trunk/PCbuild/readme.txt (original) +++ python/trunk/PCbuild/readme.txt Wed Jan 2 18:43:40 2008 @@ -1,5 +1,6 @@ Building Python using VC++ 9.0 ------------------------------ + This directory is used to build Python for Win32 platforms, e.g. Windows 2000, XP and Vista. It requires Microsoft Visual C++ 9.0 (a.k.a. Visual Studio .NET 2008). @@ -36,6 +37,36 @@ land in the amd64 subfolder. The PGI and PGO builds for profile guided optimization end up in their own folders, too. +Legacy support +-------------- + +You can find build directories for older versions of Visual Studio and +Visual C++ in the PC directory. The legacy build directories are no longer +actively maintained and may not work out of the box. + +PC/VC6/ + Visual C++ 6.0 +PC/VS7.1/ + Visual Studio 2003 (7.1) +PCbuild8/ + Visual Studio 2005 (8.0) + + +C RUNTIME +--------- + +Visual Studio 2008 uses version 9 of the C runtime (MSVCRT9). The executables +are linked to a CRT "side by side" assembly which must be present on the target +machine. This is avalible under the VC/Redist folder of your visual studio +distribution. On XP and later operating systems that support +side-by-side assemblies it is not enough to have the msvcrt80.dll present, +it has to be there as a whole assembly, that is, a folder with the .dll +and a .manifest. Also, a check is made for the correct version. +Therefore, one should distribute this assembly with the dlls, and keep +it in the same directory. For compatibility with older systems, one should +also set the PATH to this directory so that the dll can be found. +For more info, see the Readme in the VC/Redist folder. + SUBPROJECTS ----------- These subprojects should build out of the box. Subprojects other than the Added: python/trunk/PCbuild/vs9to8.py ============================================================================== --- (empty file) +++ python/trunk/PCbuild/vs9to8.py Wed Jan 2 18:43:40 2008 @@ -0,0 +1,29 @@ +from __future__ import with_statement +import os + +def vs9to8(src, dest): + for name in os.listdir(src): + path, ext = os.path.splitext(name) + if ext.lower() not in ('.sln', '.vcproj', '.vsprops'): + continue + + filename = os.path.normpath(os.path.join(src, name)) + destname = os.path.normpath(os.path.join(dest, name)) + print("%s -> %s" % (filename, destname)) + + with open(filename, 'r') as fin: + lines = fin.read() + lines = lines.replace('Version="9,00"', 'Version="8.00"') + lines = lines.replace('Version="9.00"', 'Version="8.00"') + lines = lines.replace('Format Version 10.00', 'Format Version 9.00') + lines = lines.replace('Visual Studio 2008', 'Visual Studio 2005') + + lines = lines.replace('wininst-9.0', 'wininst-8.0') + lines = lines.replace('..\\', '..\\..\\') + lines = lines.replace('..\\..\\..\\..\\', '..\\..\\..\\') + + with open(destname, 'w') as fout: + fout.write(lines) + +if __name__ == "__main__": + vs9to8(src=".", dest="..\PC\VS8.0") From python-checkins at python.org Wed Jan 2 19:28:33 2008 From: python-checkins at python.org (christian.heimes) Date: Wed, 2 Jan 2008 19:28:33 +0100 (CET) Subject: [Python-checkins] r59666 - python/trunk/PCbuild/vs9to8.py Message-ID: <20080102182833.357EE1E4004@bag.python.org> Author: christian.heimes Date: Wed Jan 2 19:28:32 2008 New Revision: 59666 Modified: python/trunk/PCbuild/vs9to8.py Log: Made vs9to8 Unix compatible Modified: python/trunk/PCbuild/vs9to8.py ============================================================================== --- python/trunk/PCbuild/vs9to8.py (original) +++ python/trunk/PCbuild/vs9to8.py Wed Jan 2 19:28:32 2008 @@ -11,7 +11,7 @@ destname = os.path.normpath(os.path.join(dest, name)) print("%s -> %s" % (filename, destname)) - with open(filename, 'r') as fin: + with open(filename, 'rU') as fin: lines = fin.read() lines = lines.replace('Version="9,00"', 'Version="8.00"') lines = lines.replace('Version="9.00"', 'Version="8.00"') @@ -22,8 +22,9 @@ lines = lines.replace('..\\', '..\\..\\') lines = lines.replace('..\\..\\..\\..\\', '..\\..\\..\\') - with open(destname, 'w') as fout: + with open(destname, 'wb') as fout: + lines = lines.replace("\n", "\r\n") fout.write(lines) if __name__ == "__main__": - vs9to8(src=".", dest="..\PC\VS8.0") + vs9to8(src=".", dest="../PC/VS8.0") From buildbot at python.org Wed Jan 2 19:35:14 2008 From: buildbot at python.org (buildbot at python.org) Date: Wed, 02 Jan 2008 18:35:14 +0000 Subject: [Python-checkins] buildbot failure in amd64 XP trunk Message-ID: <20080102183514.78DFE1E4004@bag.python.org> The Buildbot has detected a new failure of amd64 XP trunk. Full details are available at: http://www.python.org/dev/buildbot/all/amd64%20XP%20trunk/builds/472 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: heller-windows-amd64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: christian.heimes BUILD FAILED: failed compile sincerely, -The Buildbot From python-checkins at python.org Wed Jan 2 19:59:36 2008 From: python-checkins at python.org (guido.van.rossum) Date: Wed, 2 Jan 2008 19:59:36 +0100 (CET) Subject: [Python-checkins] r59668 - python/branches/release25-maint/Lib/distutils/command/build_scripts.py Message-ID: <20080102185936.E31861E4005@bag.python.org> Author: guido.van.rossum Date: Wed Jan 2 19:59:36 2008 New Revision: 59668 Modified: python/branches/release25-maint/Lib/distutils/command/build_scripts.py Log: Patch #1696. Don't attempt to call None.close() in dry-run mode. Modified: python/branches/release25-maint/Lib/distutils/command/build_scripts.py ============================================================================== --- python/branches/release25-maint/Lib/distutils/command/build_scripts.py (original) +++ python/branches/release25-maint/Lib/distutils/command/build_scripts.py Wed Jan 2 19:59:36 2008 @@ -111,7 +111,8 @@ if f: f.close() else: - f.close() + if f: + f.close() self.copy_file(script, outfile) if os.name == 'posix': From python-checkins at python.org Wed Jan 2 20:00:48 2008 From: python-checkins at python.org (guido.van.rossum) Date: Wed, 2 Jan 2008 20:00:48 +0100 (CET) Subject: [Python-checkins] r59669 - python/trunk/Lib/distutils/command/build_scripts.py Message-ID: <20080102190048.A193C1E4005@bag.python.org> Author: guido.van.rossum Date: Wed Jan 2 20:00:46 2008 New Revision: 59669 Modified: python/trunk/Lib/distutils/command/build_scripts.py Log: Patch #1696. Don't attempt to close None in dry-run mode. Modified: python/trunk/Lib/distutils/command/build_scripts.py ============================================================================== --- python/trunk/Lib/distutils/command/build_scripts.py (original) +++ python/trunk/Lib/distutils/command/build_scripts.py Wed Jan 2 20:00:46 2008 @@ -112,7 +112,8 @@ if f: f.close() else: - f.close() + if f: + f.close() self.copy_file(script, outfile) if os.name == 'posix': From kend356 at evigna.com Wed Jan 2 20:04:55 2008 From: kend356 at evigna.com (Bright Ik) Date: Wed, 2 Jan 2008 20:04:55 +0100 Subject: [Python-checkins] fiery agency Message-ID: <477BE057.7000708@kingsmen-int.com> An HTML attachment was scrubbed... URL: http://mail.python.org/pipermail/python-checkins/attachments/20080102/18a775fa/attachment-0001.htm -------------- next part -------------- A non-text attachment was scrubbed... Name: empty.gif Type: image/gif Size: 14898 bytes Desc: not available Url : http://mail.python.org/pipermail/python-checkins/attachments/20080102/18a775fa/attachment-0001.gif From buildbot at python.org Wed Jan 2 20:34:09 2008 From: buildbot at python.org (buildbot at python.org) Date: Wed, 02 Jan 2008 19:34:09 +0000 Subject: [Python-checkins] buildbot failure in g4 osx.4 3.0 Message-ID: <20080102193410.371061E4005@bag.python.org> The Buildbot has detected a new failure of g4 osx.4 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/g4%20osx.4%203.0/builds/401 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: psf-g4 Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_asynchat make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Wed Jan 2 21:00:57 2008 From: buildbot at python.org (buildbot at python.org) Date: Wed, 02 Jan 2008 20:00:57 +0000 Subject: [Python-checkins] buildbot failure in x86 XP-4 3.0 Message-ID: <20080102200058.8257E1E4011@bag.python.org> The Buildbot has detected a new failure of x86 XP-4 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20XP-4%203.0/builds/379 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-windows Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: 6 tests failed: test_anydbm test_bsddb test_bsddb3 test_mailbox test_shelve test_whichdb ====================================================================== ERROR: test_anydbm_access (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 90, in test_anydbm_access self.init_db() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 103, in init_db f = anydbm.open(_fname, 'n') File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_anydbm_creation (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 63, in test_anydbm_creation f = anydbm.open(_fname, 'c') File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_anydbm_keys (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 84, in test_anydbm_keys self.init_db() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 103, in init_db f = anydbm.open(_fname, 'n') File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_anydbm_modification (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 71, in test_anydbm_modification self.init_db() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 103, in init_db f = anydbm.open(_fname, 'n') File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_anydbm_read (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 78, in test_anydbm_read self.init_db() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 103, in init_db f = anydbm.open(_fname, 'n') File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') Traceback (most recent call last): File "../lib/test/regrtest.py", line 596, in runtest_inner indirect_test() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb3.py", line 64, in test_main run_unittest(suite()) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb3.py", line 28, in suite import bsddb.test.test_1413192 File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\test\test_1413192.py", line 38, in context = Context() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\test\test_1413192.py", line 26, in __init__ db.DB_CREATE | db.DB_INIT_TXN | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_flush (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 703, in tearDown self._delete_recursively(self._path) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 47, in _delete_recursively os.remove(target) WindowsError: [Error 32] The process cannot access the file because it is being used by another process: '@test' ====================================================================== ERROR: test_popitem (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 336, in test_popitem self.assertEqual(int(msg.get_payload()), keys.index(key)) ValueError: invalid literal for int() with base 10: 'From: foo 0 F' ====================================================================== ERROR: test_flush (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 703, in tearDown self._delete_recursively(self._path) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 47, in _delete_recursively os.remove(target) WindowsError: [Error 32] The process cannot access the file because it is being used by another process: '@test' ====================================================================== ERROR: test_popitem (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 336, in test_popitem self.assertEqual(int(msg.get_payload()), keys.index(key)) ValueError: invalid literal for int() with base 10: 'From: foo 0 \x01' ====================================================================== ERROR: test_flush (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 926, in tearDown self._delete_recursively(self._path) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 47, in _delete_recursively os.remove(target) WindowsError: [Error 32] The process cannot access the file because it is being used by another process: '@test' ====================================================================== ERROR: test_popitem (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 336, in test_popitem self.assertEqual(int(msg.get_payload()), keys.index(key)) ValueError: invalid literal for int() with base 10: 'From: foo *** EOOH *** From: foo 0 1,, From: foo *** EOOH *** From: foo 1 1,, From: foo *** EOOH *** From: foo 2 1,, From: foo *** EOOH *** From: foo 3 ' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestMaildir) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_add (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 77, in test_add self.assertEqual(self._box.get_string(keys[0]), self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\nF' != 'From: foo\n\n0' ====================================================================== FAIL: test_add_and_close (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 743, in test_add_and_close self.assertEqual(contents, open(self._path, 'r').read()) AssertionError: 'From MAILER-DAEMON Wed Jan 02 20:00:37 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Wed Jan 02 20:00:37 2008\n\nFrom: foo\n\n0\n\nFrom MAILER-DAEMON Wed Jan 02 20:00:37 2008\n\nFrom: foo\n\n1\n\nFrom MAILER-DAEMON Wed Jan 02 20:00:37 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Wed Jan 02 20:00:37 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'From MAILER-DAEMON Wed Jan 02 20:00:37 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Wed Jan 02 20:00:37 2008\n\nFrom: foo\n\n0\n\nFrom MAILER-DAEMON Wed Jan 02 20:00:37 2008\n\nFrom: foo\n\n1\n\nFrom MAILER-DAEMON Wed Jan 02 20:00:37 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Wed Jan 02 20:00:37 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Wed Jan 02 20:00:37 2008\n\nFrom: foo\n\n0\n\nFrom MAILER-DAEMON Wed Jan 02 20:00:37 2008\n\nFrom: foo\n\n1\n\nFrom MAILER-DAEMON Wed Jan 02 20:00:37 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Wed Jan 02 20:00:37 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Wed Jan 02 20:00:37 2008\n\nFrom: foo\n\n1\n\nFrom MAILER-DAEMON Wed Jan 02 20:00:37 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Wed Jan 02 20:00:37 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Wed Jan 02 20:00:37 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Wed Jan 02 20:00:37 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Wed Jan 02 20:00:37 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' ====================================================================== FAIL: test_add_from_string (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 710, in test_add_from_string self.assertEqual(self._box[key].get_from(), 'foo at bar blah') AssertionError: 'foo at bar blah\n' != 'foo at bar blah' ====================================================================== FAIL: test_close (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 389, in test_close self._test_flush_or_close(self._box.close) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 6 != 3 ====================================================================== FAIL: test_delitem (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 87, in test_delitem self._test_remove_or_delitem(self._box.__delitem__) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n1' != 'From: foo\n\n1' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_flush (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 377, in test_flush self._test_flush_or_close(self._box.flush) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 6 != 3 ====================================================================== FAIL: test_get (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 129, in test_get self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_file (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 174, in test_get_file self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\nF' != 'From: foo\n\n0' ====================================================================== FAIL: test_get_message (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 156, in test_get_message self.assertEqual(msg0['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_string (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 164, in test_get_string self.assertEqual(self._box.get_string(key0), self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\nF' != 'From: foo\n\n0' ====================================================================== FAIL: test_getitem (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 144, in test_getitem self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_items (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 207, in test_items self._check_iteration(self._box.items, do_keys=True, do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iter (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 194, in test_iter do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iteritems (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 203, in test_iteritems do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_itervalues (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 189, in test_itervalues do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_open_close_open (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 727, in test_open_close_open self.assertEqual(len(self._box), 3) AssertionError: 6 != 3 ====================================================================== FAIL: test_pop (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 313, in test_pop self.assertEqual(self._box.pop(key0).get_payload(), '0') AssertionError: 'From: foo\n\n0\n\nF' != '0' ====================================================================== FAIL: test_remove (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 83, in test_remove self._test_remove_or_delitem(self._box.remove) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n1' != 'From: foo\n\n1' ====================================================================== FAIL: test_set_item (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 272, in test_set_item self._template % 'original 0') AssertionError: '\nFrom: foo\n\noriginal 0' != 'From: foo\n\noriginal 0' ====================================================================== FAIL: test_update (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 350, in test_update self._template % 'changed 0') AssertionError: '\nFrom: foo\n\nchanged 0\n\nF' != 'From: foo\n\nchanged 0' ====================================================================== FAIL: test_values (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 198, in test_values self._check_iteration(self._box.values, do_keys=False, do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_add (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 77, in test_add self.assertEqual(self._box.get_string(keys[0]), self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\n\x01' != 'From: foo\n\n0' ====================================================================== FAIL: test_add_and_close (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 743, in test_add_and_close self.assertEqual(contents, open(self._path, 'r').read()) AssertionError: '\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Wed Jan 02 20:00:40 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Wed Jan 02 20:00:40 2008\n\nFrom: foo\n\n0\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Wed Jan 02 20:00:40 2008\n\nFrom: foo\n\n1\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Wed Jan 02 20:00:40 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Wed Jan 02 20:00:40 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n' != '\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Wed Jan 02 20:00:40 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Wed Jan 02 20:00:40 2008\n\nFrom: foo\n\n0\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Wed Jan 02 20:00:40 2008\n\nFrom: foo\n\n1\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Wed Jan 02 20:00:40 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Wed Jan 02 20:00:40 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Wed Jan 02 20:00:40 2008\n\nFrom: foo\n\n0\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Wed Jan 02 20:00:40 2008\n\nFrom: foo\n\n1\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Wed Jan 02 20:00:40 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Wed Jan 02 20:00:40 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Wed Jan 02 20:00:40 2008\n\nFrom: foo\n\n1\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Wed Jan 02 20:00:40 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Wed Jan 02 20:00:40 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Wed Jan 02 20:00:40 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Wed Jan 02 20:00:40 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Wed Jan 02 20:00:40 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n' ====================================================================== FAIL: test_add_from_string (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 710, in test_add_from_string self.assertEqual(self._box[key].get_from(), 'foo at bar blah') AssertionError: 'foo at bar blah\n' != 'foo at bar blah' ====================================================================== FAIL: test_close (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 389, in test_close self._test_flush_or_close(self._box.close) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_delitem (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 87, in test_delitem self._test_remove_or_delitem(self._box.__delitem__) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n1\n\n\x01' != 'From: foo\n\n1' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_flush (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 377, in test_flush self._test_flush_or_close(self._box.flush) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_get (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 129, in test_get self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_file (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 174, in test_get_file self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\n\x01' != 'From: foo\n\n0' ====================================================================== FAIL: test_get_message (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 156, in test_get_message self.assertEqual(msg0['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_string (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 164, in test_get_string self.assertEqual(self._box.get_string(key0), self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\n\x01' != 'From: foo\n\n0' ====================================================================== FAIL: test_getitem (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 144, in test_getitem self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_items (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 207, in test_items self._check_iteration(self._box.items, do_keys=True, do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iter (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 194, in test_iter do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iteritems (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 203, in test_iteritems do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_itervalues (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 189, in test_itervalues do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_open_close_open (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 727, in test_open_close_open self.assertEqual(len(self._box), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_pop (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 313, in test_pop self.assertEqual(self._box.pop(key0).get_payload(), '0') AssertionError: 'From: foo\n\n0\n\n\x01' != '0' ====================================================================== FAIL: test_remove (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 83, in test_remove self._test_remove_or_delitem(self._box.remove) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n1\n\n\x01' != 'From: foo\n\n1' ====================================================================== FAIL: test_set_item (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 272, in test_set_item self._template % 'original 0') AssertionError: '\nFrom: foo\n\noriginal 0\n\n\x01' != 'From: foo\n\noriginal 0' ====================================================================== FAIL: test_update (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 350, in test_update self._template % 'changed 0') AssertionError: '\nFrom: foo\n\nchanged 0\n\n\x01' != 'From: foo\n\nchanged 0' ====================================================================== FAIL: test_values (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 198, in test_values self._check_iteration(self._box.values, do_keys=False, do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestMH) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_add (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 77, in test_add self.assertEqual(self._box.get_string(keys[0]), self._template % 0) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n0\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f' != 'From: foo\n\n0' ====================================================================== FAIL: test_close (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 389, in test_close self._test_flush_or_close(self._box.close) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_delitem (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 87, in test_delitem self._test_remove_or_delitem(self._box.__delitem__) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n1\n\n\x1f' != 'From: foo\n\n1' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_flush (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 377, in test_flush self._test_flush_or_close(self._box.flush) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_get (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 129, in test_get self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_file (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 174, in test_get_file self._template % 0) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n0\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f' != 'From: foo\n\n0' ====================================================================== FAIL: test_get_message (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 156, in test_get_message self.assertEqual(msg0['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_string (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 164, in test_get_string self.assertEqual(self._box.get_string(key0), self._template % 0) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n0\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f' != 'From: foo\n\n0' ====================================================================== FAIL: test_getitem (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 144, in test_getitem self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_items (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 207, in test_items self._check_iteration(self._box.items, do_keys=True, do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iter (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 194, in test_iter do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iteritems (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 203, in test_iteritems do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_itervalues (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 189, in test_itervalues do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_pop (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 313, in test_pop self.assertEqual(self._box.pop(key0).get_payload(), '0') AssertionError: 'From: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n0\n\n\x1f\x0c\n\n1,,\n\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n1\n\n\x1f' != '0' ====================================================================== FAIL: test_remove (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 83, in test_remove self._test_remove_or_delitem(self._box.remove) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n1\n\n\x1f' != 'From: foo\n\n1' ====================================================================== FAIL: test_set_item (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 272, in test_set_item self._template % 'original 0') AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\noriginal 0\n\n\x1f' != 'From: foo\n\noriginal 0' ====================================================================== FAIL: test_update (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 350, in test_update self._template % 'changed 0') AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\nchanged 0\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f' != 'From: foo\n\nchanged 0' ====================================================================== FAIL: test_values (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 198, in test_values self._check_iteration(self._box.values, do_keys=False, do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== ERROR: test_bool (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 136, in test_bool self.assert_(not self._empty_mapping()) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_constructor (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 133, in test_constructor self.assertEqual(self._empty_mapping(), self._empty_mapping()) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 270, in test_get d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_items (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 156, in test_items d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keys (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 142, in test_keys d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 162, in test_len d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 293, in test_pop d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 288, in test_popitem d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_read (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 44, in test_read p = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 284, in test_setdefault d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 174, in test_update d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_values (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 150, in test_values d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_write (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 92, in test_write p = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_bool (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 136, in test_bool self.assert_(not self._empty_mapping()) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_constructor (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 133, in test_constructor self.assertEqual(self._empty_mapping(), self._empty_mapping()) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 270, in test_get d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_items (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 156, in test_items d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keys (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 142, in test_keys d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 162, in test_len d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 293, in test_pop d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 288, in test_popitem d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_read (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 44, in test_read p = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 284, in test_setdefault d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 174, in test_update d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_values (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 150, in test_values d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_write (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 92, in test_write p = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_bool (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 136, in test_bool self.assert_(not self._empty_mapping()) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_constructor (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 133, in test_constructor self.assertEqual(self._empty_mapping(), self._empty_mapping()) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 270, in test_get d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_items (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 156, in test_items d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keys (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 142, in test_keys d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 162, in test_len d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 293, in test_pop d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 288, in test_popitem d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_read (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 44, in test_read p = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 284, in test_setdefault d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 174, in test_update d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_values (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 150, in test_values d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_write (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 92, in test_write p = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_ascii_file_shelf (test.test_shelve.TestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 46, in test_ascii_file_shelf s = shelve.open(self.fn, protocol=0) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_binary_file_shelf (test.test_shelve.TestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 54, in test_binary_file_shelf s = shelve.open(self.fn, protocol=1) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_proto2_file_shelf (test.test_shelve.TestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 62, in test_proto2_file_shelf s = shelve.open(self.fn, protocol=2) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_whichdb (test.test_whichdb.WhichDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_whichdb.py", line 32, in test_whichdb f = module.open(_fname, 'c') File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') sincerely, -The Buildbot From buildbot at python.org Wed Jan 2 21:07:14 2008 From: buildbot at python.org (buildbot at python.org) Date: Wed, 02 Jan 2008 20:07:14 +0000 Subject: [Python-checkins] buildbot failure in PPC64 Debian trunk Message-ID: <20080102200714.D23411E4005@bag.python.org> The Buildbot has detected a new failure of PPC64 Debian trunk. Full details are available at: http://www.python.org/dev/buildbot/all/PPC64%20Debian%20trunk/builds/12 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/SocketServer.py", line 523, in __init__ self.handle() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/BaseHTTPServer.py", line 310, in handle_one_request method() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/SimpleXMLRPCServer.py", line 449, in do_POST self.report_404() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/SimpleXMLRPCServer.py", line 507, in report_404 self.connection.shutdown(1) File "", line 1, in shutdown error: [Errno 107] Transport endpoint is not connected 1 test failed: test_xmlrpc make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Wed Jan 2 21:43:51 2008 From: buildbot at python.org (buildbot at python.org) Date: Wed, 02 Jan 2008 20:43:51 +0000 Subject: [Python-checkins] buildbot failure in alpha Tru64 5.1 2.5 Message-ID: <20080102204351.A666F1E4014@bag.python.org> The Buildbot has detected a new failure of alpha Tru64 5.1 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/alpha%20Tru64%205.1%202.5/builds/382 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-tru64 Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: guido.van.rossum BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_socket ====================================================================== FAIL: testInterruptedTimeout (test.test_socket.TCPTimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/net/taipan/scratch1/nnorwitz/python/2.5.norwitz-tru64/build/Lib/test/test_socket.py", line 879, in testInterruptedTimeout self.fail("got Alarm in wrong place") AssertionError: got Alarm in wrong place sincerely, -The Buildbot From buildbot at python.org Wed Jan 2 22:33:41 2008 From: buildbot at python.org (buildbot at python.org) Date: Wed, 02 Jan 2008 21:33:41 +0000 Subject: [Python-checkins] buildbot failure in ppc Debian unstable trunk Message-ID: <20080102213341.838A71E4005@bag.python.org> The Buildbot has detected a new failure of ppc Debian unstable trunk. Full details are available at: http://www.python.org/dev/buildbot/all/ppc%20Debian%20unstable%20trunk/builds/507 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: guido.van.rossum BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_xmlrpc make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Thu Jan 3 01:04:23 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 03 Jan 2008 00:04:23 +0000 Subject: [Python-checkins] buildbot failure in sparc solaris10 gcc 3.0 Message-ID: <20080103000423.A21A21E4005@bag.python.org> The Buildbot has detected a new failure of sparc solaris10 gcc 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/sparc%20solaris10%20gcc%203.0/builds/452 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-sun Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: guido.van.rossum BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_ctypes sincerely, -The Buildbot From python-checkins at python.org Thu Jan 3 03:21:53 2008 From: python-checkins at python.org (jeffrey.yasskin) Date: Thu, 3 Jan 2008 03:21:53 +0100 (CET) Subject: [Python-checkins] r59671 - in python/trunk: Doc/library/functions.rst Doc/library/math.rst Doc/library/numbers.rst Doc/library/numeric.rst Doc/library/stdtypes.rst Doc/reference/datamodel.rst Doc/reference/expressions.rst Lib/numbers.py Lib/test/test_abstract_numbers.py Lib/test/test_builtin.py Lib/test/test_long.py Lib/test/test_math.py Lib/test/test_unittest.py Lib/unittest.py Misc/NEWS Modules/mathmodule.c Objects/complexobject.c Objects/floatobject.c Objects/intobject.c Objects/longobject.c Python/bltinmodule.c Message-ID: <20080103022153.9E9611E4005@bag.python.org> Author: jeffrey.yasskin Date: Thu Jan 3 03:21:52 2008 New Revision: 59671 Added: python/trunk/Doc/library/numbers.rst python/trunk/Lib/numbers.py python/trunk/Lib/test/test_abstract_numbers.py Modified: python/trunk/Doc/library/functions.rst python/trunk/Doc/library/math.rst python/trunk/Doc/library/numeric.rst python/trunk/Doc/library/stdtypes.rst python/trunk/Doc/reference/datamodel.rst python/trunk/Doc/reference/expressions.rst python/trunk/Lib/test/test_builtin.py python/trunk/Lib/test/test_long.py python/trunk/Lib/test/test_math.py python/trunk/Lib/test/test_unittest.py python/trunk/Lib/unittest.py python/trunk/Misc/NEWS python/trunk/Modules/mathmodule.c python/trunk/Objects/complexobject.c python/trunk/Objects/floatobject.c python/trunk/Objects/intobject.c python/trunk/Objects/longobject.c python/trunk/Python/bltinmodule.c Log: Backport PEP 3141 from the py3k branch to the trunk. This includes r50877 (just the complex_pow part), r56649, r56652, r56715, r57296, r57302, r57359, r57361, r57372, r57738, r57739, r58017, r58039, r58040, and r59390, and new documentation. The only significant difference is that round(x) returns a float to preserve backward-compatibility. See http://bugs.python.org/issue1689. Modified: python/trunk/Doc/library/functions.rst ============================================================================== --- python/trunk/Doc/library/functions.rst (original) +++ python/trunk/Doc/library/functions.rst Thu Jan 3 03:21:52 2008 @@ -986,10 +986,13 @@ .. function:: round(x[, n]) Return the floating point value *x* rounded to *n* digits after the decimal - point. If *n* is omitted, it defaults to zero. The result is a floating point - number. Values are rounded to the closest multiple of 10 to the power minus - *n*; if two multiples are equally close, rounding is done away from 0 (so. for - example, ``round(0.5)`` is ``1.0`` and ``round(-0.5)`` is ``-1.0``). + point. If *n* is omitted, it defaults to zero. Values are rounded to the + closest multiple of 10 to the power minus *n*; if two multiples are equally + close, rounding is done toward the even choice (so, for example, both + ``round(0.5)`` and ``round(-0.5)`` are ``0``, and ``round(1.5)`` is + ``2``). Delegates to ``x.__round__(n)``. + + .. versionchanged:: 2.6 .. function:: set([iterable]) @@ -1132,6 +1135,14 @@ .. versionadded:: 2.2 +.. function:: trunc(x) + + Return the :class:`Real` value *x* truncated to an :class:`Integral` (usually + a long integer). Delegates to ``x.__trunc__()``. + + .. versionadded:: 2.6 + + .. function:: tuple([iterable]) Return a tuple whose items are the same and in the same order as *iterable*'s Modified: python/trunk/Doc/library/math.rst ============================================================================== --- python/trunk/Doc/library/math.rst (original) +++ python/trunk/Doc/library/math.rst Thu Jan 3 03:21:52 2008 @@ -26,8 +26,9 @@ .. function:: ceil(x) - Return the ceiling of *x* as a float, the smallest integer value greater than or - equal to *x*. + Return the ceiling of *x* as a float, the smallest integer value greater than + or equal to *x*. If *x* is not a float, delegates to ``x.__ceil__()``, which + should return an :class:`Integral` value. .. function:: fabs(x) @@ -37,8 +38,9 @@ .. function:: floor(x) - Return the floor of *x* as a float, the largest integer value less than or equal - to *x*. + Return the floor of *x* as a float, the largest integer value less than or + equal to *x*. If *x* is not a float, delegates to ``x.__floor__()``, which + should return an :class:`Integral` value. .. function:: fmod(x, y) Added: python/trunk/Doc/library/numbers.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/library/numbers.rst Thu Jan 3 03:21:52 2008 @@ -0,0 +1,99 @@ + +:mod:`numbers` --- Numeric abstract base classes +================================================ + +.. module:: numbers + :synopsis: Numeric abstract base classes (Complex, Real, Integral, etc.). + +The :mod:`numbers` module (:pep:`3141`) defines a hierarchy of numeric abstract +base classes which progressively define more operations. These concepts also +provide a way to distinguish exact from inexact types. None of the types defined +in this module can be instantiated. + + +.. class:: Number + + The root of the numeric hierarchy. If you just want to check if an argument + *x* is a number, without caring what kind, use ``isinstance(x, Number)``. + + +Exact and inexact operations +---------------------------- + +.. class:: Exact + + Subclasses of this type have exact operations. + + As long as the result of a homogenous operation is of the same type, you can + assume that it was computed exactly, and there are no round-off errors. Laws + like commutativity and associativity hold. + + +.. class:: Inexact + + Subclasses of this type have inexact operations. + + Given X, an instance of :class:`Inexact`, it is possible that ``(X + -X) + 3 + == 3``, but ``X + (-X + 3) == 0``. The exact form this error takes will vary + by type, but it's generally unsafe to compare this type for equality. + + +The numeric tower +----------------- + +.. class:: Complex + + Subclasses of this type describe complex numbers and include the operations + that work on the builtin :class:`complex` type. These are: conversions to + :class:`complex` and :class:`bool`, :attr:`.real`, :attr:`.imag`, ``+``, + ``-``, ``*``, ``/``, :func:`abs`, :meth:`conjugate`, ``==``, and ``!=``. All + except ``-`` and ``!=`` are abstract. + +.. attribute:: Complex.real + + Abstract. Retrieves the :class:`Real` component of this number. + +.. attribute:: Complex.imag + + Abstract. Retrieves the :class:`Real` component of this number. + +.. method:: Complex.conjugate() + + Abstract. Returns the complex conjugate. For example, ``(1+3j).conjugate() == + (1-3j)``. + +.. class:: Real + + To :class:`Complex`, :class:`Real` adds the operations that work on real + numbers. + + In short, those are: a conversion to :class:`float`, :func:`trunc`, + :func:`round`, :func:`math.floor`, :func:`math.ceil`, :func:`divmod`, ``//``, + ``%``, ``<``, ``<=``, ``>``, and ``>=``. + + Real also provides defaults for :func:`complex`, :attr:`Complex.real`, + :attr:`Complex.imag`, and :meth:`Complex.conjugate`. + + +.. class:: Rational + + Subtypes both :class:`Real` and :class:`Exact`, and adds + :attr:`Rational.numerator` and :attr:`Rational.denominator` properties, which + should be in lowest terms. With these, it provides a default for + :func:`float`. + +.. attribute:: Rational.numerator + + Abstract. + +.. attribute:: Rational.denominator + + Abstract. + + +.. class:: Integral + + Subtypes :class:`Rational` and adds a conversion to :class:`long`, the + 3-argument form of :func:`pow`, and the bit-string operations: ``<<``, + ``>>``, ``&``, ``^``, ``|``, ``~``. Provides defaults for :func:`float`, + :attr:`Rational.numerator`, and :attr:`Rational.denominator`. Modified: python/trunk/Doc/library/numeric.rst ============================================================================== --- python/trunk/Doc/library/numeric.rst (original) +++ python/trunk/Doc/library/numeric.rst Thu Jan 3 03:21:52 2008 @@ -6,16 +6,18 @@ ******************************** The modules described in this chapter provide numeric and math-related functions -and data types. The :mod:`math` and :mod:`cmath` contain various mathematical -functions for floating-point and complex numbers. For users more interested in -decimal accuracy than in speed, the :mod:`decimal` module supports exact -representations of decimal numbers. +and data types. The :mod:`numbers` module defines an abstract hierarchy of +numeric types. The :mod:`math` and :mod:`cmath` modules contain various +mathematical functions for floating-point and complex numbers. For users more +interested in decimal accuracy than in speed, the :mod:`decimal` module supports +exact representations of decimal numbers. The following modules are documented in this chapter: .. toctree:: + numbers.rst math.rst cmath.rst decimal.rst Modified: python/trunk/Doc/library/stdtypes.rst ============================================================================== --- python/trunk/Doc/library/stdtypes.rst (original) +++ python/trunk/Doc/library/stdtypes.rst Thu Jan 3 03:21:52 2008 @@ -270,9 +270,8 @@ :func:`long`, :func:`float`, and :func:`complex` can be used to produce numbers of a specific type. -All numeric types (except complex) support the following operations, sorted by -ascending priority (operations in the same box have the same priority; all -numeric operations have a higher priority than comparison operations): +All builtin numeric types support the following operations. See +:ref:`power` and later sections for the operators' priorities. +--------------------+---------------------------------+--------+ | Operation | Result | Notes | @@ -285,7 +284,7 @@ +--------------------+---------------------------------+--------+ | ``x / y`` | quotient of *x* and *y* | \(1) | +--------------------+---------------------------------+--------+ -| ``x // y`` | (floored) quotient of *x* and | \(5) | +| ``x // y`` | (floored) quotient of *x* and | (4)(5) | | | *y* | | +--------------------+---------------------------------+--------+ | ``x % y`` | remainder of ``x / y`` | \(4) | @@ -294,7 +293,7 @@ +--------------------+---------------------------------+--------+ | ``+x`` | *x* unchanged | | +--------------------+---------------------------------+--------+ -| ``abs(x)`` | absolute value or magnitude of | | +| ``abs(x)`` | absolute value or magnitude of | \(3) | | | *x* | | +--------------------+---------------------------------+--------+ | ``int(x)`` | *x* converted to integer | \(2) | @@ -308,11 +307,11 @@ | | *im* defaults to zero. | | +--------------------+---------------------------------+--------+ | ``c.conjugate()`` | conjugate of the complex number | | -| | *c* | | +| | *c*. (Identity on real numbers) | | +--------------------+---------------------------------+--------+ | ``divmod(x, y)`` | the pair ``(x // y, x % y)`` | (3)(4) | +--------------------+---------------------------------+--------+ -| ``pow(x, y)`` | *x* to the power *y* | | +| ``pow(x, y)`` | *x* to the power *y* | \(3) | +--------------------+---------------------------------+--------+ | ``x ** y`` | *x* to the power *y* | | +--------------------+---------------------------------+--------+ @@ -341,9 +340,12 @@ pair: numeric; conversions pair: C; language - Conversion from floating point to (long or plain) integer may round or truncate - as in C; see functions :func:`floor` and :func:`ceil` in the :mod:`math` module - for well-defined conversions. + Conversion from floating point to (long or plain) integer may round or + truncate as in C. + + .. deprecated:: 2.6 + Instead, convert floats to long explicitly with :func:`trunc`, + :func:`math.floor`, or :func:`math.ceil`. (3) See :ref:`built-in-funcs` for a full description. @@ -364,6 +366,22 @@ .. versionadded:: 2.6 +All :class:`numbers.Real` types (:class:`int`, :class:`long`, and +:class:`float`) also include the following operations: + ++--------------------+--------------------------------+--------+ +| Operation | Result | Notes | ++====================+================================+========+ +| ``trunc(x)`` | *x* truncated to Integral | | ++--------------------+--------------------------------+--------+ +| ``round(x[, n])`` | *x* rounded to n digits, | | +| | rounding half to even. If n is | | +| | omitted, it defaults to 0. | | ++--------------------+--------------------------------+--------+ +| ``math.floor(x)`` | the greatest Integral <= *x* | | ++--------------------+--------------------------------+--------+ +| ``math.ceil(x)`` | the least Integral >= *x* | | ++--------------------+--------------------------------+--------+ .. XXXJH exceptions: overflow (when? what operations?) zerodivision Modified: python/trunk/Doc/reference/datamodel.rst ============================================================================== --- python/trunk/Doc/reference/datamodel.rst (original) +++ python/trunk/Doc/reference/datamodel.rst Thu Jan 3 03:21:52 2008 @@ -150,7 +150,7 @@ indicate the presence of the ``...`` syntax in a slice. Its truth value is true. -Numbers +:class:`numbers.Number` .. index:: object: numeric These are created by numeric literals and returned as results by arithmetic @@ -162,7 +162,7 @@ Python distinguishes between integers, floating point numbers, and complex numbers: - Integers + :class:`numbers.Integral` .. index:: object: integer These represent elements from the mathematical set of integers (positive and @@ -214,7 +214,7 @@ without causing overflow, will yield the same result in the long integer domain or when using mixed operands. - Floating point numbers + :class:`numbers.Real` (:class:`float`) .. index:: object: floating point pair: floating point; number @@ -229,7 +229,7 @@ overhead of using objects in Python, so there is no reason to complicate the language with two kinds of floating point numbers. - Complex numbers + :class:`numbers.Complex` .. index:: object: complex pair: complex; number Modified: python/trunk/Doc/reference/expressions.rst ============================================================================== --- python/trunk/Doc/reference/expressions.rst (original) +++ python/trunk/Doc/reference/expressions.rst Thu Jan 3 03:21:52 2008 @@ -801,7 +801,8 @@ raised). Raising ``0.0`` to a negative power results in a :exc:`ZeroDivisionError`. -Raising a negative number to a fractional power results in a :exc:`ValueError`. +Raising a negative number to a fractional power results in a :class:`complex` +number. (Since Python 2.6. In earlier versions it raised a :exc:`ValueError`.) .. _unary: Added: python/trunk/Lib/numbers.py ============================================================================== --- (empty file) +++ python/trunk/Lib/numbers.py Thu Jan 3 03:21:52 2008 @@ -0,0 +1,393 @@ +# Copyright 2007 Google, Inc. All Rights Reserved. +# Licensed to PSF under a Contributor Agreement. + +"""Abstract Base Classes (ABCs) for numbers, according to PEP 3141. + +TODO: Fill out more detailed documentation on the operators.""" + +from abc import ABCMeta, abstractmethod, abstractproperty + +__all__ = ["Number", "Exact", "Inexact", + "Complex", "Real", "Rational", "Integral", + ] + + +class Number(object): + """All numbers inherit from this class. + + If you just want to check if an argument x is a number, without + caring what kind, use isinstance(x, Number). + """ + __metaclass__ = ABCMeta + + +class Exact(Number): + """Operations on instances of this type are exact. + + As long as the result of a homogenous operation is of the same + type, you can assume that it was computed exactly, and there are + no round-off errors. Laws like commutativity and associativity + hold. + """ + +Exact.register(int) +Exact.register(long) + + +class Inexact(Number): + """Operations on instances of this type are inexact. + + Given X, an instance of Inexact, it is possible that (X + -X) + 3 + == 3, but X + (-X + 3) == 0. The exact form this error takes will + vary by type, but it's generally unsafe to compare this type for + equality. + """ + +Inexact.register(complex) +Inexact.register(float) +# Inexact.register(decimal.Decimal) + + +class Complex(Number): + """Complex defines the operations that work on the builtin complex type. + + In short, those are: a conversion to complex, .real, .imag, +, -, + *, /, abs(), .conjugate, ==, and !=. + + If it is given heterogenous arguments, and doesn't have special + knowledge about them, it should fall back to the builtin complex + type as described below. + """ + + @abstractmethod + def __complex__(self): + """Return a builtin complex instance. Called for complex(self).""" + + def __bool__(self): + """True if self != 0. Called for bool(self).""" + return self != 0 + + @abstractproperty + def real(self): + """Retrieve the real component of this number. + + This should subclass Real. + """ + raise NotImplementedError + + @abstractproperty + def imag(self): + """Retrieve the real component of this number. + + This should subclass Real. + """ + raise NotImplementedError + + @abstractmethod + def __add__(self, other): + """self + other""" + raise NotImplementedError + + @abstractmethod + def __radd__(self, other): + """other + self""" + raise NotImplementedError + + @abstractmethod + def __neg__(self): + """-self""" + raise NotImplementedError + + def __pos__(self): + """+self""" + raise NotImplementedError + + def __sub__(self, other): + """self - other""" + return self + -other + + def __rsub__(self, other): + """other - self""" + return -self + other + + @abstractmethod + def __mul__(self, other): + """self * other""" + raise NotImplementedError + + @abstractmethod + def __rmul__(self, other): + """other * self""" + raise NotImplementedError + + @abstractmethod + def __div__(self, other): + """self / other; should promote to float or complex when necessary.""" + raise NotImplementedError + + @abstractmethod + def __rdiv__(self, other): + """other / self""" + raise NotImplementedError + + @abstractmethod + def __pow__(self, exponent): + """self**exponent; should promote to float or complex when necessary.""" + raise NotImplementedError + + @abstractmethod + def __rpow__(self, base): + """base ** self""" + raise NotImplementedError + + @abstractmethod + def __abs__(self): + """Returns the Real distance from 0. Called for abs(self).""" + raise NotImplementedError + + @abstractmethod + def conjugate(self): + """(x+y*i).conjugate() returns (x-y*i).""" + raise NotImplementedError + + @abstractmethod + def __eq__(self, other): + """self == other""" + raise NotImplementedError + + # __ne__ is inherited from object and negates whatever __eq__ does. + +Complex.register(complex) + + +class Real(Complex): + """To Complex, Real adds the operations that work on real numbers. + + In short, those are: a conversion to float, trunc(), divmod, + %, <, <=, >, and >=. + + Real also provides defaults for the derived operations. + """ + + @abstractmethod + def __float__(self): + """Any Real can be converted to a native float object. + + Called for float(self).""" + raise NotImplementedError + + @abstractmethod + def __trunc__(self): + """trunc(self): Truncates self to an Integral. + + Returns an Integral i such that: + * i>0 iff self>0; + * abs(i) <= abs(self); + * for any Integral j satisfying the first two conditions, + abs(i) >= abs(j) [i.e. i has "maximal" abs among those]. + i.e. "truncate towards 0". + """ + raise NotImplementedError + + @abstractmethod + def __floor__(self): + """Finds the greatest Integral <= self.""" + raise NotImplementedError + + @abstractmethod + def __ceil__(self): + """Finds the least Integral >= self.""" + raise NotImplementedError + + @abstractmethod + def __round__(self, ndigits=None): + """Rounds self to ndigits decimal places, defaulting to 0. + + If ndigits is omitted or None, returns an Integral, otherwise + returns a Real. Rounds half toward even. + """ + raise NotImplementedError + + def __divmod__(self, other): + """divmod(self, other): The pair (self // other, self % other). + + Sometimes this can be computed faster than the pair of + operations. + """ + return (self // other, self % other) + + def __rdivmod__(self, other): + """divmod(other, self): The pair (self // other, self % other). + + Sometimes this can be computed faster than the pair of + operations. + """ + return (other // self, other % self) + + @abstractmethod + def __floordiv__(self, other): + """self // other: The floor() of self/other.""" + raise NotImplementedError + + @abstractmethod + def __rfloordiv__(self, other): + """other // self: The floor() of other/self.""" + raise NotImplementedError + + @abstractmethod + def __mod__(self, other): + """self % other""" + raise NotImplementedError + + @abstractmethod + def __rmod__(self, other): + """other % self""" + raise NotImplementedError + + @abstractmethod + def __lt__(self, other): + """self < other + + < on Reals defines a total ordering, except perhaps for NaN.""" + raise NotImplementedError + + @abstractmethod + def __le__(self, other): + """self <= other""" + raise NotImplementedError + + # Concrete implementations of Complex abstract methods. + def __complex__(self): + """complex(self) == complex(float(self), 0)""" + return complex(float(self)) + + @property + def real(self): + """Real numbers are their real component.""" + return +self + + @property + def imag(self): + """Real numbers have no imaginary component.""" + return 0 + + def conjugate(self): + """Conjugate is a no-op for Reals.""" + return +self + +Real.register(float) +# Real.register(decimal.Decimal) + + +class Rational(Real, Exact): + """.numerator and .denominator should be in lowest terms.""" + + @abstractproperty + def numerator(self): + raise NotImplementedError + + @abstractproperty + def denominator(self): + raise NotImplementedError + + # Concrete implementation of Real's conversion to float. + def __float__(self): + """float(self) = self.numerator / self.denominator""" + return self.numerator / self.denominator + + +class Integral(Rational): + """Integral adds a conversion to long and the bit-string operations.""" + + @abstractmethod + def __long__(self): + """long(self)""" + raise NotImplementedError + + def __index__(self): + """index(self)""" + return long(self) + + @abstractmethod + def __pow__(self, exponent, modulus=None): + """self ** exponent % modulus, but maybe faster. + + Accept the modulus argument if you want to support the + 3-argument version of pow(). Raise a TypeError if exponent < 0 + or any argument isn't Integral. Otherwise, just implement the + 2-argument version described in Complex. + """ + raise NotImplementedError + + @abstractmethod + def __lshift__(self, other): + """self << other""" + raise NotImplementedError + + @abstractmethod + def __rlshift__(self, other): + """other << self""" + raise NotImplementedError + + @abstractmethod + def __rshift__(self, other): + """self >> other""" + raise NotImplementedError + + @abstractmethod + def __rrshift__(self, other): + """other >> self""" + raise NotImplementedError + + @abstractmethod + def __and__(self, other): + """self & other""" + raise NotImplementedError + + @abstractmethod + def __rand__(self, other): + """other & self""" + raise NotImplementedError + + @abstractmethod + def __xor__(self, other): + """self ^ other""" + raise NotImplementedError + + @abstractmethod + def __rxor__(self, other): + """other ^ self""" + raise NotImplementedError + + @abstractmethod + def __or__(self, other): + """self | other""" + raise NotImplementedError + + @abstractmethod + def __ror__(self, other): + """other | self""" + raise NotImplementedError + + @abstractmethod + def __invert__(self): + """~self""" + raise NotImplementedError + + # Concrete implementations of Rational and Real abstract methods. + def __float__(self): + """float(self) == float(long(self))""" + return float(long(self)) + + @property + def numerator(self): + """Integers are their own numerators.""" + return +self + + @property + def denominator(self): + """Integers have a denominator of 1.""" + return 1 + +Integral.register(int) +Integral.register(long) Added: python/trunk/Lib/test/test_abstract_numbers.py ============================================================================== --- (empty file) +++ python/trunk/Lib/test/test_abstract_numbers.py Thu Jan 3 03:21:52 2008 @@ -0,0 +1,62 @@ +"""Unit tests for numbers.py.""" + +import unittest +from test import test_support +from numbers import Number +from numbers import Exact, Inexact +from numbers import Complex, Real, Rational, Integral +import operator + +class TestNumbers(unittest.TestCase): + def test_int(self): + self.failUnless(issubclass(int, Integral)) + self.failUnless(issubclass(int, Complex)) + self.failUnless(issubclass(int, Exact)) + self.failIf(issubclass(int, Inexact)) + + self.assertEqual(7, int(7).real) + self.assertEqual(0, int(7).imag) + self.assertEqual(7, int(7).conjugate()) + self.assertEqual(7, int(7).numerator) + self.assertEqual(1, int(7).denominator) + + def test_long(self): + self.failUnless(issubclass(long, Integral)) + self.failUnless(issubclass(long, Complex)) + self.failUnless(issubclass(long, Exact)) + self.failIf(issubclass(long, Inexact)) + + self.assertEqual(7, long(7).real) + self.assertEqual(0, long(7).imag) + self.assertEqual(7, long(7).conjugate()) + self.assertEqual(7, long(7).numerator) + self.assertEqual(1, long(7).denominator) + + def test_float(self): + self.failIf(issubclass(float, Rational)) + self.failUnless(issubclass(float, Real)) + self.failIf(issubclass(float, Exact)) + self.failUnless(issubclass(float, Inexact)) + + self.assertEqual(7.3, float(7.3).real) + self.assertEqual(0, float(7.3).imag) + self.assertEqual(7.3, float(7.3).conjugate()) + + def test_complex(self): + self.failIf(issubclass(complex, Real)) + self.failUnless(issubclass(complex, Complex)) + self.failIf(issubclass(complex, Exact)) + self.failUnless(issubclass(complex, Inexact)) + + c1, c2 = complex(3, 2), complex(4,1) + # XXX: This is not ideal, but see the comment in builtin_trunc(). + self.assertRaises(AttributeError, trunc, c1) + self.assertRaises(TypeError, float, c1) + self.assertRaises(TypeError, int, c1) + +def test_main(): + test_support.run_unittest(TestNumbers) + + +if __name__ == "__main__": + unittest.main() Modified: python/trunk/Lib/test/test_builtin.py ============================================================================== --- python/trunk/Lib/test/test_builtin.py (original) +++ python/trunk/Lib/test/test_builtin.py Thu Jan 3 03:21:52 2008 @@ -1450,11 +1450,13 @@ else: self.assertAlmostEqual(pow(x, y, z), 24.0) + self.assertAlmostEqual(pow(-1, 0.5), 1j) + self.assertAlmostEqual(pow(-1, 1./3), 0.5 + 0.8660254037844386j) + self.assertRaises(TypeError, pow, -1, -2, 3) self.assertRaises(ValueError, pow, 1, 2, 0) self.assertRaises(TypeError, pow, -1L, -2L, 3L) self.assertRaises(ValueError, pow, 1L, 2L, 0L) - self.assertRaises(ValueError, pow, -342.43, 0.234) self.assertRaises(TypeError, pow) @@ -1622,6 +1624,7 @@ def test_round(self): self.assertEqual(round(0.0), 0.0) + self.assertEqual(type(round(0.0)), float) # Will be int in 3.0. self.assertEqual(round(1.0), 1.0) self.assertEqual(round(10.0), 10.0) self.assertEqual(round(1000000000.0), 1000000000.0) @@ -1650,12 +1653,50 @@ self.assertEqual(round(-999999999.9), -1000000000.0) self.assertEqual(round(-8.0, -1), -10.0) + self.assertEqual(type(round(-8.0, -1)), float) + + self.assertEqual(type(round(-8.0, 0)), float) + self.assertEqual(type(round(-8.0, 1)), float) + + # Check even / odd rounding behaviour + self.assertEqual(round(5.5), 6) + self.assertEqual(round(6.5), 6) + self.assertEqual(round(-5.5), -6) + self.assertEqual(round(-6.5), -6) + + # Check behavior on ints + self.assertEqual(round(0), 0) + self.assertEqual(round(8), 8) + self.assertEqual(round(-8), -8) + self.assertEqual(type(round(0)), float) # Will be int in 3.0. + self.assertEqual(type(round(-8, -1)), float) + self.assertEqual(type(round(-8, 0)), float) + self.assertEqual(type(round(-8, 1)), float) # test new kwargs self.assertEqual(round(number=-8.0, ndigits=-1), -10.0) self.assertRaises(TypeError, round) + # test generic rounding delegation for reals + class TestRound(object): + def __round__(self): + return 23 + + class TestNoRound(object): + pass + + self.assertEqual(round(TestRound()), 23) + + self.assertRaises(TypeError, round, 1, 2, 3) + # XXX: This is not ideal, but see the comment in builtin_round(). + self.assertRaises(AttributeError, round, TestNoRound()) + + t = TestNoRound() + t.__round__ = lambda *args: args + self.assertEquals((), round(t)) + self.assertEquals((0,), round(t, 0)) + def test_setattr(self): setattr(sys, 'spam', 1) self.assertEqual(sys.spam, 1) @@ -1697,6 +1738,38 @@ raise ValueError self.assertRaises(ValueError, sum, BadSeq()) + def test_trunc(self): + + self.assertEqual(trunc(1), 1) + self.assertEqual(trunc(-1), -1) + self.assertEqual(type(trunc(1)), int) + self.assertEqual(type(trunc(1.5)), int) + self.assertEqual(trunc(1.5), 1) + self.assertEqual(trunc(-1.5), -1) + self.assertEqual(trunc(1.999999), 1) + self.assertEqual(trunc(-1.999999), -1) + self.assertEqual(trunc(-0.999999), -0) + self.assertEqual(trunc(-100.999), -100) + + class TestTrunc(object): + def __trunc__(self): + return 23 + + class TestNoTrunc(object): + pass + + self.assertEqual(trunc(TestTrunc()), 23) + + self.assertRaises(TypeError, trunc) + self.assertRaises(TypeError, trunc, 1, 2) + # XXX: This is not ideal, but see the comment in builtin_trunc(). + self.assertRaises(AttributeError, trunc, TestNoTrunc()) + + t = TestNoTrunc() + t.__trunc__ = lambda *args: args + self.assertEquals((), trunc(t)) + self.assertRaises(TypeError, trunc, t, 0) + def test_tuple(self): self.assertEqual(tuple(()), ()) t0_3 = (0, 1, 2, 3) Modified: python/trunk/Lib/test/test_long.py ============================================================================== --- python/trunk/Lib/test/test_long.py (original) +++ python/trunk/Lib/test/test_long.py Thu Jan 3 03:21:52 2008 @@ -385,7 +385,9 @@ "1. ** huge", "huge ** 1.", "1. ** mhuge", "mhuge ** 1.", "math.sin(huge)", "math.sin(mhuge)", "math.sqrt(huge)", "math.sqrt(mhuge)", # should do better - "math.floor(huge)", "math.floor(mhuge)"]: + # math.floor() of an int returns an int now + ##"math.floor(huge)", "math.floor(mhuge)", + ]: self.assertRaises(OverflowError, eval, test, namespace) Modified: python/trunk/Lib/test/test_math.py ============================================================================== --- python/trunk/Lib/test/test_math.py (original) +++ python/trunk/Lib/test/test_math.py Thu Jan 3 03:21:52 2008 @@ -58,6 +58,19 @@ self.ftest('ceil(-1.0)', math.ceil(-1.0), -1) self.ftest('ceil(-1.5)', math.ceil(-1.5), -1) + class TestCeil(object): + def __ceil__(self): + return 42 + class TestNoCeil(object): + pass + self.ftest('ceil(TestCeil())', math.ceil(TestCeil()), 42) + self.assertRaises(TypeError, math.ceil, TestNoCeil()) + + t = TestNoCeil() + t.__ceil__ = lambda *args: args + self.assertRaises(TypeError, math.ceil, t) + self.assertRaises(TypeError, math.ceil, t, 0) + def testCos(self): self.assertRaises(TypeError, math.cos) self.ftest('cos(-pi/2)', math.cos(-math.pi/2), 0) @@ -101,6 +114,19 @@ self.ftest('floor(1.23e167)', math.floor(1.23e167), 1.23e167) self.ftest('floor(-1.23e167)', math.floor(-1.23e167), -1.23e167) + class TestFloor(object): + def __floor__(self): + return 42 + class TestNoFloor(object): + pass + self.ftest('floor(TestFloor())', math.floor(TestFloor()), 42) + self.assertRaises(TypeError, math.floor, TestNoFloor()) + + t = TestNoFloor() + t.__floor__ = lambda *args: args + self.assertRaises(TypeError, math.floor, t) + self.assertRaises(TypeError, math.floor, t, 0) + def testFmod(self): self.assertRaises(TypeError, math.fmod) self.ftest('fmod(10,1)', math.fmod(10,1), 0) Modified: python/trunk/Lib/test/test_unittest.py ============================================================================== --- python/trunk/Lib/test/test_unittest.py (original) +++ python/trunk/Lib/test/test_unittest.py Thu Jan 3 03:21:52 2008 @@ -2264,13 +2264,34 @@ expected = ['startTest', 'test', 'stopTest'] self.assertEqual(events, expected) +class Test_Assertions(TestCase): + def test_AlmostEqual(self): + self.failUnlessAlmostEqual(1.00000001, 1.0) + self.failIfAlmostEqual(1.0000001, 1.0) + self.assertRaises(AssertionError, + self.failUnlessAlmostEqual, 1.0000001, 1.0) + self.assertRaises(AssertionError, + self.failIfAlmostEqual, 1.00000001, 1.0) + + self.failUnlessAlmostEqual(1.1, 1.0, places=0) + self.assertRaises(AssertionError, + self.failUnlessAlmostEqual, 1.1, 1.0, places=1) + + self.failUnlessAlmostEqual(0, .1+.1j, places=0) + self.failIfAlmostEqual(0, .1+.1j, places=1) + self.assertRaises(AssertionError, + self.failUnlessAlmostEqual, 0, .1+.1j, places=1) + self.assertRaises(AssertionError, + self.failIfAlmostEqual, 0, .1+.1j, places=0) + ###################################################################### ## Main ###################################################################### def test_main(): test_support.run_unittest(Test_TestCase, Test_TestLoader, - Test_TestSuite, Test_TestResult, Test_FunctionTestCase) + Test_TestSuite, Test_TestResult, Test_FunctionTestCase, + Test_Assertions) if __name__ == "__main__": test_main() Modified: python/trunk/Lib/unittest.py ============================================================================== --- python/trunk/Lib/unittest.py (original) +++ python/trunk/Lib/unittest.py Thu Jan 3 03:21:52 2008 @@ -358,7 +358,7 @@ Note that decimal places (from zero) are usually not the same as significant digits (measured from the most signficant digit). """ - if round(second-first, places) != 0: + if round(abs(second-first), places) != 0: raise self.failureException, \ (msg or '%r != %r within %r places' % (first, second, places)) @@ -370,7 +370,7 @@ Note that decimal places (from zero) are usually not the same as significant digits (measured from the most signficant digit). """ - if round(second-first, places) == 0: + if round(abs(second-first), places) == 0: raise self.failureException, \ (msg or '%r == %r within %r places' % (first, second, places)) Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Thu Jan 3 03:21:52 2008 @@ -346,6 +346,8 @@ Library ------- +- Issue #1689: PEP 3141, numeric abstract base classes. + - Tk issue #1851526: Return results from Python callbacks to Tcl as Tcl objects. Modified: python/trunk/Modules/mathmodule.c ============================================================================== --- python/trunk/Modules/mathmodule.c (original) +++ python/trunk/Modules/mathmodule.c Thu Jan 3 03:21:52 2008 @@ -107,9 +107,28 @@ FUNC2(atan2, atan2, "atan2(y, x)\n\nReturn the arc tangent (measured in radians) of y/x.\n" "Unlike atan(y/x), the signs of both x and y are considered.") -FUNC1(ceil, ceil, - "ceil(x)\n\nReturn the ceiling of x as a float.\n" - "This is the smallest integral value >= x.") + +static PyObject * math_ceil(PyObject *self, PyObject *number) { + static PyObject *ceil_str = NULL; + PyObject *method; + + if (ceil_str == NULL) { + ceil_str = PyString_FromString("__ceil__"); + if (ceil_str == NULL) + return NULL; + } + + method = _PyType_Lookup(Py_Type(number), ceil_str); + if (method == NULL) + return math_1(number, ceil); + else + return PyObject_CallFunction(method, "O", number); +} + +PyDoc_STRVAR(math_ceil_doc, + "ceil(x)\n\nReturn the ceiling of x as a float.\n" + "This is the smallest integral value >= x."); + FUNC1(cos, cos, "cos(x)\n\nReturn the cosine of x (measured in radians).") FUNC1(cosh, cosh, @@ -118,9 +137,28 @@ "exp(x)\n\nReturn e raised to the power of x.") FUNC1(fabs, fabs, "fabs(x)\n\nReturn the absolute value of the float x.") -FUNC1(floor, floor, - "floor(x)\n\nReturn the floor of x as a float.\n" - "This is the largest integral value <= x.") + +static PyObject * math_floor(PyObject *self, PyObject *number) { + static PyObject *floor_str = NULL; + PyObject *method; + + if (floor_str == NULL) { + floor_str = PyString_FromString("__floor__"); + if (floor_str == NULL) + return NULL; + } + + method = _PyType_Lookup(Py_Type(number), floor_str); + if (method == NULL) + return math_1(number, floor); + else + return PyObject_CallFunction(method, "O", number); +} + +PyDoc_STRVAR(math_floor_doc, + "floor(x)\n\nReturn the floor of x as a float.\n" + "This is the largest integral value <= x."); + FUNC2(fmod, fmod, "fmod(x,y)\n\nReturn fmod(x, y), according to platform C." " x % y may differ.") Modified: python/trunk/Objects/complexobject.c ============================================================================== --- python/trunk/Objects/complexobject.c (original) +++ python/trunk/Objects/complexobject.c Thu Jan 3 03:21:52 2008 @@ -385,6 +385,41 @@ return combined; } +/* This macro may return! */ +#define TO_COMPLEX(obj, c) \ + if (PyComplex_Check(obj)) \ + c = ((PyComplexObject *)(obj))->cval; \ + else if (to_complex(&(obj), &(c)) < 0) \ + return (obj) + +static int +to_complex(PyObject **pobj, Py_complex *pc) +{ + PyObject *obj = *pobj; + + pc->real = pc->imag = 0.0; + if (PyInt_Check(obj)) { + pc->real = PyInt_AS_LONG(obj); + return 0; + } + if (PyLong_Check(obj)) { + pc->real = PyLong_AsDouble(obj); + if (pc->real == -1.0 && PyErr_Occurred()) { + *pobj = NULL; + return -1; + } + return 0; + } + if (PyFloat_Check(obj)) { + pc->real = PyFloat_AsDouble(obj); + return 0; + } + Py_INCREF(Py_NotImplemented); + *pobj = Py_NotImplemented; + return -1; +} + + static PyObject * complex_add(PyComplexObject *v, PyComplexObject *w) { @@ -502,24 +537,27 @@ } static PyObject * -complex_pow(PyComplexObject *v, PyObject *w, PyComplexObject *z) +complex_pow(PyObject *v, PyObject *w, PyObject *z) { Py_complex p; Py_complex exponent; long int_exponent; + Py_complex a, b; + TO_COMPLEX(v, a); + TO_COMPLEX(w, b); - if ((PyObject *)z!=Py_None) { + if (z!=Py_None) { PyErr_SetString(PyExc_ValueError, "complex modulo"); return NULL; } PyFPE_START_PROTECT("complex_pow", return 0) errno = 0; - exponent = ((PyComplexObject*)w)->cval; + exponent = b; int_exponent = (long)exponent.real; if (exponent.imag == 0. && exponent.real == int_exponent) - p = c_powi(v->cval,int_exponent); + p = c_powi(a,int_exponent); else - p = c_pow(v->cval,exponent); + p = c_pow(a,exponent); PyFPE_END_PROTECT(p) Py_ADJUST_ERANGE2(p.real, p.imag); @@ -541,6 +579,10 @@ { PyObject *t, *r; + if (PyErr_Warn(PyExc_DeprecationWarning, + "complex divmod(), // and % are deprecated") < 0) + return NULL; + t = complex_divmod(v, w); if (t != NULL) { r = PyTuple_GET_ITEM(t, 0); @@ -695,6 +737,11 @@ return PyComplex_FromCComplex(c); } +PyDoc_STRVAR(complex_conjugate_doc, +"complex.conjugate() -> complex\n" +"\n" +"Returns the complex conjugate of its argument. (3-4j).conjugate() == 3+4j."); + static PyObject * complex_getnewargs(PyComplexObject *v) { @@ -702,7 +749,8 @@ } static PyMethodDef complex_methods[] = { - {"conjugate", (PyCFunction)complex_conjugate, METH_NOARGS}, + {"conjugate", (PyCFunction)complex_conjugate, METH_NOARGS, + complex_conjugate_doc}, {"__getnewargs__", (PyCFunction)complex_getnewargs, METH_NOARGS}, {NULL, NULL} /* sentinel */ }; Modified: python/trunk/Objects/floatobject.c ============================================================================== --- python/trunk/Objects/floatobject.c (original) +++ python/trunk/Objects/floatobject.c Thu Jan 3 03:21:52 2008 @@ -986,9 +986,10 @@ * bugs so we have to figure it out ourselves. */ if (iw != floor(iw)) { - PyErr_SetString(PyExc_ValueError, "negative number " - "cannot be raised to a fractional power"); - return NULL; + /* Negative numbers raised to fractional powers + * become complex. + */ + return PyComplex_Type.tp_as_number->nb_power(v, w, z); } /* iw is an exact integer, albeit perhaps a very large one. * -1 raised to an exact integer should never be exceptional. @@ -1035,17 +1036,6 @@ } static PyObject * -float_pos(PyFloatObject *v) -{ - if (PyFloat_CheckExact(v)) { - Py_INCREF(v); - return (PyObject *)v; - } - else - return PyFloat_FromDouble(v->ob_fval); -} - -static PyObject * float_abs(PyFloatObject *v) { return PyFloat_FromDouble(fabs(v->ob_fval)); @@ -1083,14 +1073,7 @@ } static PyObject * -float_long(PyObject *v) -{ - double x = PyFloat_AsDouble(v); - return PyLong_FromDouble(x); -} - -static PyObject * -float_int(PyObject *v) +float_trunc(PyObject *v) { double x = PyFloat_AsDouble(v); double wholepart; /* integral portion of x, rounded toward 0 */ @@ -1116,6 +1099,54 @@ } static PyObject * +float_round(PyObject *v, PyObject *args) +{ +#define UNDEF_NDIGITS (-0x7fffffff) /* Unlikely ndigits value */ + double x; + double f; + double flr, cil; + double rounded; + int i; + int ndigits = UNDEF_NDIGITS; + + if (!PyArg_ParseTuple(args, "|i", &ndigits)) + return NULL; + + x = PyFloat_AsDouble(v); + + if (ndigits != UNDEF_NDIGITS) { + f = 1.0; + i = abs(ndigits); + while (--i >= 0) + f = f*10.0; + if (ndigits < 0) + x /= f; + else + x *= f; + } + + flr = floor(x); + cil = ceil(x); + + if (x-flr > 0.5) + rounded = cil; + else if (x-flr == 0.5) + rounded = fmod(flr, 2) == 0 ? flr : cil; + else + rounded = flr; + + if (ndigits != UNDEF_NDIGITS) { + if (ndigits < 0) + rounded *= f; + else + rounded /= f; + } + + return PyFloat_FromDouble(rounded); +#undef UNDEF_NDIGITS +} + +static PyObject * float_float(PyObject *v) { if (PyFloat_CheckExact(v)) @@ -1302,7 +1333,20 @@ "Overrides the automatic determination of C-level floating point type.\n" "This affects how floats are converted to and from binary strings."); +static PyObject * +float_getzero(PyObject *v, void *closure) +{ + return PyFloat_FromDouble(0.0); +} + static PyMethodDef float_methods[] = { + {"conjugate", (PyCFunction)float_float, METH_NOARGS, + "Returns self, the complex conjugate of any float."}, + {"__trunc__", (PyCFunction)float_trunc, METH_NOARGS, + "Returns the Integral closest to x between 0 and x."}, + {"__round__", (PyCFunction)float_round, METH_VARARGS, + "Returns the Integral closest to x, rounding half toward even.\n" + "When an argument is passed, works like built-in round(x, ndigits)."}, {"__getnewargs__", (PyCFunction)float_getnewargs, METH_NOARGS}, {"__getformat__", (PyCFunction)float_getformat, METH_O|METH_CLASS, float_getformat_doc}, @@ -1311,6 +1355,18 @@ {NULL, NULL} /* sentinel */ }; +static PyGetSetDef float_getset[] = { + {"real", + (getter)float_float, (setter)NULL, + "the real part of a complex number", + NULL}, + {"imag", + (getter)float_getzero, (setter)NULL, + "the imaginary part of a complex number", + NULL}, + {NULL} /* Sentinel */ +}; + PyDoc_STRVAR(float_doc, "float(x) -> floating point number\n\ \n\ @@ -1326,7 +1382,7 @@ float_divmod, /*nb_divmod*/ float_pow, /*nb_power*/ (unaryfunc)float_neg, /*nb_negative*/ - (unaryfunc)float_pos, /*nb_positive*/ + (unaryfunc)float_float, /*nb_positive*/ (unaryfunc)float_abs, /*nb_absolute*/ (inquiry)float_nonzero, /*nb_nonzero*/ 0, /*nb_invert*/ @@ -1336,8 +1392,8 @@ 0, /*nb_xor*/ 0, /*nb_or*/ float_coerce, /*nb_coerce*/ - float_int, /*nb_int*/ - float_long, /*nb_long*/ + float_trunc, /*nb_int*/ + float_trunc, /*nb_long*/ float_float, /*nb_float*/ 0, /* nb_oct */ 0, /* nb_hex */ @@ -1389,7 +1445,7 @@ 0, /* tp_iternext */ float_methods, /* tp_methods */ 0, /* tp_members */ - 0, /* tp_getset */ + float_getset, /* tp_getset */ 0, /* tp_base */ 0, /* tp_dict */ 0, /* tp_descr_get */ Modified: python/trunk/Objects/intobject.c ============================================================================== --- python/trunk/Objects/intobject.c (original) +++ python/trunk/Objects/intobject.c Thu Jan 3 03:21:52 2008 @@ -4,6 +4,8 @@ #include "Python.h" #include +static PyObject *int_int(PyIntObject *v); + long PyInt_GetMax(void) { @@ -783,21 +785,10 @@ } static PyObject * -int_pos(PyIntObject *v) -{ - if (PyInt_CheckExact(v)) { - Py_INCREF(v); - return (PyObject *)v; - } - else - return PyInt_FromLong(v->ob_ival); -} - -static PyObject * int_abs(PyIntObject *v) { if (v->ob_ival >= 0) - return int_pos(v); + return int_int(v); else return int_neg(v); } @@ -827,7 +818,7 @@ return NULL; } if (a == 0 || b == 0) - return int_pos(v); + return int_int(v); if (b >= LONG_BIT) { vv = PyLong_FromLong(PyInt_AS_LONG(v)); if (vv == NULL) @@ -871,7 +862,7 @@ return NULL; } if (a == 0 || b == 0) - return int_pos(v); + return int_int(v); if (b >= LONG_BIT) { if (a < 0) a = -1; @@ -1060,11 +1051,72 @@ return Py_BuildValue("(l)", v->ob_ival); } +static PyObject * +int_getN(PyIntObject *v, void *context) { + return PyInt_FromLong((intptr_t)context); +} + +static PyObject * +int_round(PyObject *self, PyObject *args) +{ +#define UNDEF_NDIGITS (-0x7fffffff) /* Unlikely ndigits value */ + int ndigits = UNDEF_NDIGITS; + double x; + PyObject *res; + + if (!PyArg_ParseTuple(args, "|i", &ndigits)) + return NULL; + + if (ndigits == UNDEF_NDIGITS) + return int_float((PyIntObject *)self); + + /* If called with two args, defer to float.__round__(). */ + x = (double) PyInt_AS_LONG(self); + self = PyFloat_FromDouble(x); + if (self == NULL) + return NULL; + res = PyObject_CallMethod(self, "__round__", "i", ndigits); + Py_DECREF(self); + return res; +#undef UNDEF_NDIGITS +} + static PyMethodDef int_methods[] = { + {"conjugate", (PyCFunction)int_int, METH_NOARGS, + "Returns self, the complex conjugate of any int."}, + {"__trunc__", (PyCFunction)int_int, METH_NOARGS, + "Truncating an Integral returns itself."}, + {"__floor__", (PyCFunction)int_int, METH_NOARGS, + "Flooring an Integral returns itself."}, + {"__ceil__", (PyCFunction)int_int, METH_NOARGS, + "Ceiling of an Integral returns itself."}, + {"__round__", (PyCFunction)int_round, METH_VARARGS, + "Rounding an Integral returns itself.\n" + "Rounding with an ndigits arguments defers to float.__round__."}, {"__getnewargs__", (PyCFunction)int_getnewargs, METH_NOARGS}, {NULL, NULL} /* sentinel */ }; +static PyGetSetDef int_getset[] = { + {"real", + (getter)int_int, (setter)NULL, + "the real part of a complex number", + NULL}, + {"imag", + (getter)int_getN, (setter)NULL, + "the imaginary part of a complex number", + (void*)0}, + {"numerator", + (getter)int_int, (setter)NULL, + "the numerator of a rational number in lowest terms", + NULL}, + {"denominator", + (getter)int_getN, (setter)NULL, + "the denominator of a rational number in lowest terms", + (void*)1}, + {NULL} /* Sentinel */ +}; + PyDoc_STRVAR(int_doc, "int(x[, base]) -> integer\n\ \n\ @@ -1085,7 +1137,7 @@ (binaryfunc)int_divmod, /*nb_divmod*/ (ternaryfunc)int_pow, /*nb_power*/ (unaryfunc)int_neg, /*nb_negative*/ - (unaryfunc)int_pos, /*nb_positive*/ + (unaryfunc)int_int, /*nb_positive*/ (unaryfunc)int_abs, /*nb_absolute*/ (inquiry)int_nonzero, /*nb_nonzero*/ (unaryfunc)int_invert, /*nb_invert*/ @@ -1149,7 +1201,7 @@ 0, /* tp_iternext */ int_methods, /* tp_methods */ 0, /* tp_members */ - 0, /* tp_getset */ + int_getset, /* tp_getset */ 0, /* tp_base */ 0, /* tp_dict */ 0, /* tp_descr_get */ Modified: python/trunk/Objects/longobject.c ============================================================================== --- python/trunk/Objects/longobject.c (original) +++ python/trunk/Objects/longobject.c Thu Jan 3 03:21:52 2008 @@ -1716,7 +1716,7 @@ /* forward */ static PyLongObject *x_divrem (PyLongObject *, PyLongObject *, PyLongObject **); -static PyObject *long_pos(PyLongObject *); +static PyObject *long_long(PyObject *v); static int long_divrem(PyLongObject *, PyLongObject *, PyLongObject **, PyLongObject **); @@ -2906,17 +2906,6 @@ } static PyObject * -long_pos(PyLongObject *v) -{ - if (PyLong_CheckExact(v)) { - Py_INCREF(v); - return (PyObject *)v; - } - else - return _PyLong_Copy(v); -} - -static PyObject * long_neg(PyLongObject *v) { PyLongObject *z; @@ -2937,7 +2926,7 @@ if (v->ob_size < 0) return long_neg(v); else - return long_pos(v); + return long_long((PyObject *)v); } static int @@ -3373,11 +3362,74 @@ return Py_BuildValue("(N)", _PyLong_Copy(v)); } +static PyObject * +long_getN(PyLongObject *v, void *context) { + return PyLong_FromLong((intptr_t)context); +} + +static PyObject * +long_round(PyObject *self, PyObject *args) +{ +#define UNDEF_NDIGITS (-0x7fffffff) /* Unlikely ndigits value */ + int ndigits = UNDEF_NDIGITS; + double x; + PyObject *res; + + if (!PyArg_ParseTuple(args, "|i", &ndigits)) + return NULL; + + if (ndigits == UNDEF_NDIGITS) + return long_float(self); + + /* If called with two args, defer to float.__round__(). */ + x = PyLong_AsDouble(self); + if (x == -1.0 && PyErr_Occurred()) + return NULL; + self = PyFloat_FromDouble(x); + if (self == NULL) + return NULL; + res = PyObject_CallMethod(self, "__round__", "i", ndigits); + Py_DECREF(self); + return res; +#undef UNDEF_NDIGITS +} + static PyMethodDef long_methods[] = { + {"conjugate", (PyCFunction)long_long, METH_NOARGS, + "Returns self, the complex conjugate of any long."}, + {"__trunc__", (PyCFunction)long_long, METH_NOARGS, + "Truncating an Integral returns itself."}, + {"__floor__", (PyCFunction)long_long, METH_NOARGS, + "Flooring an Integral returns itself."}, + {"__ceil__", (PyCFunction)long_long, METH_NOARGS, + "Ceiling of an Integral returns itself."}, + {"__round__", (PyCFunction)long_round, METH_VARARGS, + "Rounding an Integral returns itself.\n" + "Rounding with an ndigits arguments defers to float.__round__."}, {"__getnewargs__", (PyCFunction)long_getnewargs, METH_NOARGS}, {NULL, NULL} /* sentinel */ }; +static PyGetSetDef long_getset[] = { + {"real", + (getter)long_long, (setter)NULL, + "the real part of a complex number", + NULL}, + {"imag", + (getter)long_getN, (setter)NULL, + "the imaginary part of a complex number", + (void*)0}, + {"numerator", + (getter)long_long, (setter)NULL, + "the numerator of a rational number in lowest terms", + NULL}, + {"denominator", + (getter)long_getN, (setter)NULL, + "the denominator of a rational number in lowest terms", + (void*)1}, + {NULL} /* Sentinel */ +}; + PyDoc_STRVAR(long_doc, "long(x[, base]) -> integer\n\ \n\ @@ -3396,7 +3448,7 @@ long_divmod, /*nb_divmod*/ long_pow, /*nb_power*/ (unaryfunc) long_neg, /*nb_negative*/ - (unaryfunc) long_pos, /*tp_positive*/ + (unaryfunc) long_long, /*tp_positive*/ (unaryfunc) long_abs, /*tp_absolute*/ (inquiry) long_nonzero, /*tp_nonzero*/ (unaryfunc) long_invert, /*nb_invert*/ @@ -3461,7 +3513,7 @@ 0, /* tp_iternext */ long_methods, /* tp_methods */ 0, /* tp_members */ - 0, /* tp_getset */ + long_getset, /* tp_getset */ 0, /* tp_base */ 0, /* tp_dict */ 0, /* tp_descr_get */ Modified: python/trunk/Python/bltinmodule.c ============================================================================== --- python/trunk/Python/bltinmodule.c (original) +++ python/trunk/Python/bltinmodule.c Thu Jan 3 03:21:52 2008 @@ -1926,39 +1926,31 @@ static PyObject * builtin_round(PyObject *self, PyObject *args, PyObject *kwds) { - double number; - double f; - int ndigits = 0; - int i; +#define UNDEF_NDIGITS (-0x7fffffff) /* Unlikely ndigits value */ + int ndigits = UNDEF_NDIGITS; static char *kwlist[] = {"number", "ndigits", 0}; + PyObject *number; - if (!PyArg_ParseTupleAndKeywords(args, kwds, "d|i:round", + if (!PyArg_ParseTupleAndKeywords(args, kwds, "O|i:round", kwlist, &number, &ndigits)) return NULL; - f = 1.0; - i = abs(ndigits); - while (--i >= 0) - f = f*10.0; - if (ndigits < 0) - number /= f; - else - number *= f; - if (number >= 0.0) - number = floor(number + 0.5); - else - number = ceil(number - 0.5); - if (ndigits < 0) - number *= f; - else - number /= f; - return PyFloat_FromDouble(number); + + // The py3k branch gets better errors for this by using + // _PyType_Lookup(), but since float's mro isn't set in py2.6, + // we just use PyObject_CallMethod here. + if (ndigits == UNDEF_NDIGITS) + return PyObject_CallMethod(number, "__round__", ""); + else + return PyObject_CallMethod(number, "__round__", "i", ndigits); +#undef UNDEF_NDIGITS } PyDoc_STRVAR(round_doc, "round(number[, ndigits]) -> floating point number\n\ \n\ Round a number to a given precision in decimal digits (default 0 digits).\n\ -This always returns a floating point number. Precision may be negative."); +This returns an int when called with one argument, otherwise a float.\n\ +Precision may be negative."); static PyObject * builtin_sorted(PyObject *self, PyObject *args, PyObject *kwds) @@ -2039,6 +2031,20 @@ Without arguments, equivalent to locals().\n\ With an argument, equivalent to object.__dict__."); +static PyObject * +builtin_trunc(PyObject *self, PyObject *number) +{ + // XXX: The py3k branch gets better errors for this by using + // _PyType_Lookup(), but since float's mro isn't set in py2.6, + // we just use PyObject_CallMethod here. + return PyObject_CallMethod(number, "__trunc__", ""); +} + +PyDoc_STRVAR(trunc_doc, +"trunc(Real) -> Integral\n\ +\n\ +returns the integral closest to x between 0 and x."); + static PyObject* builtin_sum(PyObject *self, PyObject *args) @@ -2387,6 +2393,7 @@ {"unichr", builtin_unichr, METH_VARARGS, unichr_doc}, #endif {"vars", builtin_vars, METH_VARARGS, vars_doc}, + {"trunc", builtin_trunc, METH_O, trunc_doc}, {"zip", builtin_zip, METH_VARARGS, zip_doc}, {NULL, NULL}, }; From buildbot at python.org Thu Jan 3 03:34:30 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 03 Jan 2008 02:34:30 +0000 Subject: [Python-checkins] buildbot failure in alpha Tru64 5.1 trunk Message-ID: <20080103023430.EE7371E4005@bag.python.org> The Buildbot has detected a new failure of alpha Tru64 5.1 trunk. Full details are available at: http://www.python.org/dev/buildbot/all/alpha%20Tru64%205.1%20trunk/builds/2190 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-tru64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: jeffrey.yasskin BUILD FAILED: failed test Excerpt from the test logfile: sincerely, -The Buildbot From nnorwitz at gmail.com Thu Jan 3 10:00:06 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Thu, 3 Jan 2008 04:00:06 -0500 Subject: [Python-checkins] Python Regression Test Failures doc (1) Message-ID: <20080103090006.GA4707@python.psfb.org> svn update tools/sphinx svn: PROPFIND request failed on '/projects/doctools/trunk/sphinx' svn: PROPFIND of '/projects/doctools/trunk/sphinx': could not connect to server (http://svn.python.org) make: *** [update] Error 1 From buildbot at python.org Thu Jan 3 14:07:13 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 03 Jan 2008 13:07:13 +0000 Subject: [Python-checkins] buildbot failure in 3.0.msi Message-ID: <20080103130713.48A6B1E401E@bag.python.org> The Buildbot has detected a new failure of 3.0.msi. Full details are available at: http://www.python.org/dev/buildbot/all/3.0.msi/builds/120 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-windows Build Reason: The Nightly scheduler named '3.0.msi' triggered this build Build Source Stamp: HEAD Blamelist: BUILD FAILED: failed compile sincerely, -The Buildbot From buildbot at python.org Thu Jan 3 15:06:53 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 03 Jan 2008 14:06:53 +0000 Subject: [Python-checkins] buildbot failure in x86 mvlgcc 3.0 Message-ID: <20080103140653.ACF751E4012@bag.python.org> The Buildbot has detected a new failure of x86 mvlgcc 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20mvlgcc%203.0/builds/474 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-linux Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes,guido.van.rossum BUILD FAILED: failed test Excerpt from the test logfile: 3 tests failed: test_cProfile test_doctest test_profile make: *** [buildbottest] Fehler 1 sincerely, -The Buildbot From python-checkins at python.org Thu Jan 3 16:41:31 2008 From: python-checkins at python.org (christian.heimes) Date: Thu, 3 Jan 2008 16:41:31 +0100 (CET) Subject: [Python-checkins] r59672 - in python/trunk: Misc/NEWS PC/VS8.0/pythoncore.vcproj PCbuild/pythoncore.vcproj Message-ID: <20080103154131.26CEB1E4011@bag.python.org> Author: christian.heimes Date: Thu Jan 3 16:41:30 2008 New Revision: 59672 Modified: python/trunk/Misc/NEWS python/trunk/PC/VS8.0/pythoncore.vcproj python/trunk/PCbuild/pythoncore.vcproj Log: Issue #1726: Remove Python/atof.c from PCBuild/pythoncore.vcproj Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Thu Jan 3 16:41:30 2008 @@ -12,6 +12,8 @@ Core and builtins ----------------- +- Issue #1726: Remove Python/atof.c from PCBuild/pythoncore.vcproj + - Removed PCbuild8/ directory and added a new build directory for VS 2005 based on the VS 2008 build directory to PC/VS8.0. The script PCbuild/vs8to9.py was added to sync changes from PCbuild to PC/VS8.0. Modified: python/trunk/PC/VS8.0/pythoncore.vcproj ============================================================================== --- python/trunk/PC/VS8.0/pythoncore.vcproj (original) +++ python/trunk/PC/VS8.0/pythoncore.vcproj Thu Jan 3 16:41:30 2008 @@ -1374,10 +1374,6 @@ RelativePath="..\..\Objects\dictobject.c" > - @@ -1607,10 +1603,6 @@ > - - Modified: python/trunk/PCbuild/pythoncore.vcproj ============================================================================== --- python/trunk/PCbuild/pythoncore.vcproj (original) +++ python/trunk/PCbuild/pythoncore.vcproj Thu Jan 3 16:41:30 2008 @@ -1374,10 +1374,6 @@ RelativePath="..\Objects\dictobject.c" > - @@ -1607,10 +1603,6 @@ > - - From buildbot at python.org Thu Jan 3 17:27:11 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 03 Jan 2008 16:27:11 +0000 Subject: [Python-checkins] buildbot failure in ppc Debian unstable trunk Message-ID: <20080103162711.E4F951E4006@bag.python.org> The Buildbot has detected a new failure of ppc Debian unstable trunk. Full details are available at: http://www.python.org/dev/buildbot/all/ppc%20Debian%20unstable%20trunk/builds/509 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30995, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/SocketServer.py", line 523, in __init__ self.handle() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/BaseHTTPServer.py", line 310, in handle_one_request method() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/SimpleXMLRPCServer.py", line 449, in do_POST self.report_404() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/SimpleXMLRPCServer.py", line 507, in report_404 self.connection.shutdown(1) File "", line 1, in shutdown error: [Errno 107] Transport endpoint is not connected 1 test failed: test_xmlrpc ====================================================================== ERROR: test_fail_no_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_xmlrpc.py", line 560, in test_fail_no_info p.pow(6,8) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1157, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1447, in __request verbose=self.__verbose File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1195, in request errcode, errmsg, headers = h.getreply() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 1006, in getreply response = self._conn.getresponse() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 932, in getresponse response.begin() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 415, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 271, in readheaders line = self.fp.readline() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/socket.py", line 351, in readline data = recv(1) error: [Errno 104] Connection reset by peer make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Thu Jan 3 19:57:40 2008 From: python-checkins at python.org (guido.van.rossum) Date: Thu, 3 Jan 2008 19:57:40 +0100 (CET) Subject: [Python-checkins] r59673 - python/branches/release25-maint/Misc/NEWS Message-ID: <20080103185740.E503D1E4006@bag.python.org> Author: guido.van.rossum Date: Thu Jan 3 19:57:40 2008 New Revision: 59673 Modified: python/branches/release25-maint/Misc/NEWS Log: Add some news items I missed. Careful inspection of the svn log output reveals that a lot more are missing. If you checked anything into the 2.5.2 branch without updating Misc/NEWS, please correct your mistake! Modified: python/branches/release25-maint/Misc/NEWS ============================================================================== --- python/branches/release25-maint/Misc/NEWS (original) +++ python/branches/release25-maint/Misc/NEWS Thu Jan 3 19:57:40 2008 @@ -12,7 +12,9 @@ Core and builtins ----------------- -- Issue #1638: %zd configure test fails on Linux +- Bug #1517: Possible segfault in lookup(). + +- Issue #1638: %zd configure test fails on Linux. - Issue #1553: An erroneous __length_hint__ can make list() raise a SystemError. @@ -51,6 +53,9 @@ Library ------- +- Change ctypes version number to 1.0.3 (when Python 2.5.2 is released, + ctypes 1.0.3 will be also be released). + - Issue #1695: Fixed typo in the docstrings for time.localtime() and gmtime(). - Issue #1642: Fix segfault in ctypes when trying to delete attributes. @@ -359,7 +364,9 @@ Extension Modules ----------------- -- Bug #1563759: struct.unpack doens't support buffer protocol objects +- Patch #1643738: Problem with signals in a single-threaded application. + +- Bug #1563759: struct.unpack doens't support buffer protocol objects. - Bug #1686475: Support stat'ing open files on Windows again. From python-checkins at python.org Thu Jan 3 20:08:16 2008 From: python-checkins at python.org (guido.van.rossum) Date: Thu, 3 Jan 2008 20:08:16 +0100 (CET) Subject: [Python-checkins] r59674 - in python/branches/release25-maint: Lib/sre_compile.py Lib/test/test_re.py Misc/NEWS Message-ID: <20080103190816.106701E4145@bag.python.org> Author: guido.van.rossum Date: Thu Jan 3 20:08:15 2008 New Revision: 59674 Modified: python/branches/release25-maint/Lib/sre_compile.py python/branches/release25-maint/Lib/test/test_re.py python/branches/release25-maint/Misc/NEWS Log: Issue #1700, reported by Nguyen Quan Son, fix by Fredruk Lundh: Regular Expression inline flags not handled correctly for some unicode characters. Modified: python/branches/release25-maint/Lib/sre_compile.py ============================================================================== --- python/branches/release25-maint/Lib/sre_compile.py (original) +++ python/branches/release25-maint/Lib/sre_compile.py Thu Jan 3 20:08:15 2008 @@ -525,7 +525,7 @@ indexgroup[i] = k return _sre.compile( - pattern, flags, code, + pattern, flags | p.pattern.flags, code, p.pattern.groups-1, groupindex, indexgroup ) Modified: python/branches/release25-maint/Lib/test/test_re.py ============================================================================== --- python/branches/release25-maint/Lib/test/test_re.py (original) +++ python/branches/release25-maint/Lib/test/test_re.py Thu Jan 3 20:08:15 2008 @@ -637,6 +637,36 @@ self.assertEqual(re.compile("bla").match(a), None) self.assertEqual(re.compile("").match(a).groups(), ()) + def test_inline_flags(self): + # Bug #1700 + upper_char = unichr(0x1ea0) # Latin Capital Letter A with Dot Bellow + lower_char = unichr(0x1ea1) # Latin Small Letter A with Dot Bellow + + p = re.compile(upper_char, re.I | re.U) + q = p.match(lower_char) + self.assertNotEqual(q, None) + + p = re.compile(lower_char, re.I | re.U) + q = p.match(upper_char) + self.assertNotEqual(q, None) + + p = re.compile('(?i)' + upper_char, re.U) + q = p.match(lower_char) + self.assertNotEqual(q, None) + + p = re.compile('(?i)' + lower_char, re.U) + q = p.match(upper_char) + self.assertNotEqual(q, None) + + p = re.compile('(?iu)' + upper_char) + q = p.match(lower_char) + self.assertNotEqual(q, None) + + p = re.compile('(?iu)' + lower_char) + q = p.match(upper_char) + self.assertNotEqual(q, None) + + def run_re_tests(): from test.re_tests import benchmarks, tests, SUCCEED, FAIL, SYNTAX_ERROR if verbose: Modified: python/branches/release25-maint/Misc/NEWS ============================================================================== --- python/branches/release25-maint/Misc/NEWS (original) +++ python/branches/release25-maint/Misc/NEWS Thu Jan 3 20:08:15 2008 @@ -53,6 +53,9 @@ Library ------- +- Issue #1700: Regular expression inline flags incorrectly handle certain + unicode characters. + - Change ctypes version number to 1.0.3 (when Python 2.5.2 is released, ctypes 1.0.3 will be also be released). From python-checkins at python.org Thu Jan 3 20:12:44 2008 From: python-checkins at python.org (guido.van.rossum) Date: Thu, 3 Jan 2008 20:12:44 +0100 (CET) Subject: [Python-checkins] r59675 - in python/trunk: Lib/sre_compile.py Lib/test/test_re.py Misc/NEWS Message-ID: <20080103191244.6EFCA1E4006@bag.python.org> Author: guido.van.rossum Date: Thu Jan 3 20:12:44 2008 New Revision: 59675 Modified: python/trunk/Lib/sre_compile.py python/trunk/Lib/test/test_re.py python/trunk/Misc/NEWS Log: Issue #1700, reported by Nguyen Quan Son, fix by Fredruk Lundh: Regular Expression inline flags not handled correctly for some unicode characters. (Forward port from 2.5.2.) Modified: python/trunk/Lib/sre_compile.py ============================================================================== --- python/trunk/Lib/sre_compile.py (original) +++ python/trunk/Lib/sre_compile.py Thu Jan 3 20:12:44 2008 @@ -525,7 +525,7 @@ indexgroup[i] = k return _sre.compile( - pattern, flags, code, + pattern, flags | p.pattern.flags, code, p.pattern.groups-1, groupindex, indexgroup ) Modified: python/trunk/Lib/test/test_re.py ============================================================================== --- python/trunk/Lib/test/test_re.py (original) +++ python/trunk/Lib/test/test_re.py Thu Jan 3 20:12:44 2008 @@ -642,6 +642,36 @@ self.assertEqual(re.compile("bla").match(a), None) self.assertEqual(re.compile("").match(a).groups(), ()) + def test_inline_flags(self): + # Bug #1700 + upper_char = unichr(0x1ea0) # Latin Capital Letter A with Dot Bellow + lower_char = unichr(0x1ea1) # Latin Small Letter A with Dot Bellow + + p = re.compile(upper_char, re.I | re.U) + q = p.match(lower_char) + self.assertNotEqual(q, None) + + p = re.compile(lower_char, re.I | re.U) + q = p.match(upper_char) + self.assertNotEqual(q, None) + + p = re.compile('(?i)' + upper_char, re.U) + q = p.match(lower_char) + self.assertNotEqual(q, None) + + p = re.compile('(?i)' + lower_char, re.U) + q = p.match(upper_char) + self.assertNotEqual(q, None) + + p = re.compile('(?iu)' + upper_char) + q = p.match(lower_char) + self.assertNotEqual(q, None) + + p = re.compile('(?iu)' + lower_char) + q = p.match(upper_char) + self.assertNotEqual(q, None) + + def run_re_tests(): from test.re_tests import benchmarks, tests, SUCCEED, FAIL, SYNTAX_ERROR if verbose: Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Thu Jan 3 20:12:44 2008 @@ -348,6 +348,9 @@ Library ------- +- Issue #1700: Regular expression inline flags incorrectly handle certain + unicode characters. + - Issue #1689: PEP 3141, numeric abstract base classes. - Tk issue #1851526: Return results from Python callbacks to Tcl as From buildbot at python.org Thu Jan 3 21:21:38 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 03 Jan 2008 20:21:38 +0000 Subject: [Python-checkins] buildbot failure in x86 FreeBSD 2.5 Message-ID: <20080103202138.393521E4018@bag.python.org> The Buildbot has detected a new failure of x86 FreeBSD 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20FreeBSD%202.5/builds/76 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-freebsd Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: guido.van.rossum BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_timeout sincerely, -The Buildbot From python-checkins at python.org Thu Jan 3 21:23:15 2008 From: python-checkins at python.org (christian.heimes) Date: Thu, 3 Jan 2008 21:23:15 +0100 (CET) Subject: [Python-checkins] r59676 - in python/trunk: Doc/library/math.rst Lib/test/test_math.py Misc/NEWS Modules/mathmodule.c Message-ID: <20080103202315.996FD1E400E@bag.python.org> Author: christian.heimes Date: Thu Jan 3 21:23:15 2008 New Revision: 59676 Modified: python/trunk/Doc/library/math.rst python/trunk/Lib/test/test_math.py python/trunk/Misc/NEWS python/trunk/Modules/mathmodule.c Log: Added math.isinf() and math.isnan() Modified: python/trunk/Doc/library/math.rst ============================================================================== --- python/trunk/Doc/library/math.rst (original) +++ python/trunk/Doc/library/math.rst Thu Jan 3 21:23:15 2008 @@ -66,6 +66,23 @@ apart" the internal representation of a float in a portable way. +.. function:: isinf(x) + + Checks if the float *x* is positive or negative infinite. + + ..versionadded:: 2.6 + + +.. function:: isnan(x) + + Checks if the float *x* is a NaN (not a number). NaNs are part of the + IEEE 754 standards. Operation like but not limited to ``inf * 0``, + ``inf / inf`` or any operation involving a NaN, e.g. ``nan * 1``, return + a NaN. + + ..versionadded:: 2.6 + + .. function:: ldexp(x, i) Return ``x * (2**i)``. This is essentially the inverse of function Modified: python/trunk/Lib/test/test_math.py ============================================================================== --- python/trunk/Lib/test/test_math.py (original) +++ python/trunk/Lib/test/test_math.py Thu Jan 3 21:23:15 2008 @@ -229,6 +229,22 @@ self.ftest('tanh(0)', math.tanh(0), 0) self.ftest('tanh(1)+tanh(-1)', math.tanh(1)+math.tanh(-1), 0) + def testIsnan(self): + self.assert_(math.isnan(float("nan"))) + self.assert_(math.isnan(float("inf")* 0.)) + self.failIf(math.isnan(float("inf"))) + self.failIf(math.isnan(0.)) + self.failIf(math.isnan(1.)) + + def testIsinf(self): + self.assert_(math.isinf(float("inf"))) + self.assert_(math.isinf(float("-inf"))) + self.assert_(math.isinf(1E400)) + self.assert_(math.isinf(-1E400)) + self.failIf(math.isinf(float("nan"))) + self.failIf(math.isinf(0.)) + self.failIf(math.isinf(1.)) + # RED_FLAG 16-Oct-2000 Tim # While 2.0 is more consistent about exceptions than previous releases, it # still fails this part of the test on some platforms. For now, we only Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Thu Jan 3 21:23:15 2008 @@ -12,6 +12,8 @@ Core and builtins ----------------- +- Issue #1640: Added math.isinf() and math.isnan() functions. + - Issue #1726: Remove Python/atof.c from PCBuild/pythoncore.vcproj - Removed PCbuild8/ directory and added a new build directory for VS 2005 Modified: python/trunk/Modules/mathmodule.c ============================================================================== --- python/trunk/Modules/mathmodule.c (original) +++ python/trunk/Modules/mathmodule.c Thu Jan 3 21:23:15 2008 @@ -315,9 +315,8 @@ PyDoc_STRVAR(math_log10_doc, "log10(x) -> the base 10 logarithm of x."); -/* XXX(nnorwitz): Should we use the platform M_PI or something more accurate - like: 3.14159265358979323846264338327950288 */ -static const double degToRad = 3.141592653589793238462643383 / 180.0; +static const double degToRad = Py_MATH_PI / 180.0; +static const double radToDeg = 180.0 / Py_MATH_PI; static PyObject * math_degrees(PyObject *self, PyObject *arg) @@ -325,7 +324,7 @@ double x = PyFloat_AsDouble(arg); if (x == -1.0 && PyErr_Occurred()) return NULL; - return PyFloat_FromDouble(x / degToRad); + return PyFloat_FromDouble(x * radToDeg); } PyDoc_STRVAR(math_degrees_doc, @@ -343,6 +342,33 @@ PyDoc_STRVAR(math_radians_doc, "radians(x) -> converts angle x from degrees to radians"); +static PyObject * +math_isnan(PyObject *self, PyObject *arg) +{ + double x = PyFloat_AsDouble(arg); + if (x == -1.0 && PyErr_Occurred()) + return NULL; + return PyBool_FromLong((long)Py_IS_NAN(x)); +} + +PyDoc_STRVAR(math_isnan_doc, +"isnan(x) -> bool\n\ +Checks if float x is not a number (NaN)"); + +static PyObject * +math_isinf(PyObject *self, PyObject *arg) +{ + double x = PyFloat_AsDouble(arg); + if (x == -1.0 && PyErr_Occurred()) + return NULL; + return PyBool_FromLong((long)Py_IS_INFINITY(x)); +} + +PyDoc_STRVAR(math_isinf_doc, +"isinf(x) -> bool\n\ +Checks if float x is infinite (positive or negative)"); + + static PyMethodDef math_methods[] = { {"acos", math_acos, METH_O, math_acos_doc}, {"asin", math_asin, METH_O, math_asin_doc}, @@ -358,6 +384,8 @@ {"fmod", math_fmod, METH_VARARGS, math_fmod_doc}, {"frexp", math_frexp, METH_O, math_frexp_doc}, {"hypot", math_hypot, METH_VARARGS, math_hypot_doc}, + {"isinf", math_isinf, METH_O, math_isinf_doc}, + {"isnan", math_isnan, METH_O, math_isnan_doc}, {"ldexp", math_ldexp, METH_VARARGS, math_ldexp_doc}, {"log", math_log, METH_VARARGS, math_log_doc}, {"log10", math_log10, METH_O, math_log10_doc}, @@ -389,13 +417,13 @@ if (d == NULL) goto finally; - if (!(v = PyFloat_FromDouble(atan(1.0) * 4.0))) + if (!(v = PyFloat_FromDouble(Py_MATH_PI))) goto finally; if (PyDict_SetItemString(d, "pi", v) < 0) goto finally; Py_DECREF(v); - if (!(v = PyFloat_FromDouble(exp(1.0)))) + if (!(v = PyFloat_FromDouble(Py_MATH_E))) goto finally; if (PyDict_SetItemString(d, "e", v) < 0) goto finally; From buildbot at python.org Thu Jan 3 21:35:42 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 03 Jan 2008 20:35:42 +0000 Subject: [Python-checkins] buildbot failure in sparc solaris10 gcc trunk Message-ID: <20080103203542.739C41E4007@bag.python.org> The Buildbot has detected a new failure of sparc solaris10 gcc trunk. Full details are available at: http://www.python.org/dev/buildbot/all/sparc%20solaris10%20gcc%20trunk/builds/2529 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-sun Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: guido.van.rossum BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/SocketServer.py", line 523, in __init__ self.handle() File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/socket.py", line 366, in readline data = self._sock.recv(self._rbufsize) error: [Errno 11] Resource temporarily unavailable 1 test failed: test_xmlrpc sincerely, -The Buildbot From buildbot at python.org Thu Jan 3 21:38:49 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 03 Jan 2008 20:38:49 +0000 Subject: [Python-checkins] buildbot failure in ppc Debian unstable trunk Message-ID: <20080103203850.214CF1E4006@bag.python.org> The Buildbot has detected a new failure of ppc Debian unstable trunk. Full details are available at: http://www.python.org/dev/buildbot/all/ppc%20Debian%20unstable%20trunk/builds/511 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "./Lib/test/regrtest.py", line 127, in import random File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/random.py", line 43, in from math import log as _log, exp as _exp, pi as _pi, e as _e, ceil as _ceil ImportError: No module named math make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Thu Jan 3 21:44:18 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 03 Jan 2008 20:44:18 +0000 Subject: [Python-checkins] buildbot failure in PPC64 Debian trunk Message-ID: <20080103204418.32F221E4016@bag.python.org> The Buildbot has detected a new failure of PPC64 Debian trunk. Full details are available at: http://www.python.org/dev/buildbot/all/PPC64%20Debian%20trunk/builds/16 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: guido.van.rossum BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/bsddb/test/test_thread.py", line 378, in writerThread self.doWrite(d, name, x, min(stop, x+step)) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/bsddb/test/test_thread.py", line 358, in doWrite d.put(key, self.makeData(key), txn) DBRunRecoveryError: (-30974, 'DB_RUNRECOVERY: Fatal error, run database recovery') Traceback (most recent call last): File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/bsddb/test/test_thread.py", line 426, in readerThread rec = c.next() DBRunRecoveryError: (-30974, 'DB_RUNRECOVERY: Fatal error, run database recovery -- PANIC: fatal region error detected; run recovery') Traceback (most recent call last): File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/bsddb/test/test_thread.py", line 378, in writerThread self.doWrite(d, name, x, min(stop, x+step)) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/bsddb/test/test_thread.py", line 366, in doWrite txn.abort() DBRunRecoveryError: (-30974, 'DB_RUNRECOVERY: Fatal error, run database recovery -- PANIC: DB_NOTFOUND: No matching key/data pair found') Traceback (most recent call last): File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/bsddb/test/test_thread.py", line 426, in readerThread rec = c.next() DBRunRecoveryError: (-30974, 'DB_RUNRECOVERY: Fatal error, run database recovery -- PANIC: fatal region error detected; run recovery') Traceback (most recent call last): File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/bsddb/test/test_thread.py", line 426, in readerThread rec = c.next() DBRunRecoveryError: (-30974, 'DB_RUNRECOVERY: Fatal error, run database recovery -- PANIC: fatal region error detected; run recovery') Traceback (most recent call last): File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/bsddb/test/test_thread.py", line 426, in readerThread rec = c.next() DBRunRecoveryError: (-30974, 'DB_RUNRECOVERY: Fatal error, run database recovery -- PANIC: fatal region error detected; run recovery') Traceback (most recent call last): File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/bsddb/test/test_thread.py", line 426, in readerThread rec = c.next() DBRunRecoveryError: (-30974, 'DB_RUNRECOVERY: Fatal error, run database recovery -- PANIC: fatal region error detected; run recovery') Traceback (most recent call last): File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/bsddb/test/test_thread.py", line 378, in writerThread self.doWrite(d, name, x, min(stop, x+step)) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/bsddb/test/test_thread.py", line 358, in doWrite d.put(key, self.makeData(key), txn) DBRunRecoveryError: (-30974, 'DB_RUNRECOVERY: Fatal error, run database recovery') 2 tests failed: test_bsddb3 test_xmlrpc make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Thu Jan 3 21:51:35 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 03 Jan 2008 20:51:35 +0000 Subject: [Python-checkins] buildbot failure in g4 osx.4 trunk Message-ID: <20080103205135.8D7C41E4007@bag.python.org> The Buildbot has detected a new failure of g4 osx.4 trunk. Full details are available at: http://www.python.org/dev/buildbot/all/g4%20osx.4%20trunk/builds/2532 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: psf-g4 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "./Lib/test/regrtest.py", line 127, in import random File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/random.py", line 43, in from math import log as _log, exp as _exp, pi as _pi, e as _e, ceil as _ceil ImportError: No module named math make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Thu Jan 3 22:14:48 2008 From: python-checkins at python.org (christian.heimes) Date: Thu, 3 Jan 2008 22:14:48 +0100 (CET) Subject: [Python-checkins] r59677 - python/trunk/Include/pyport.h Message-ID: <20080103211448.A16071E4006@bag.python.org> Author: christian.heimes Date: Thu Jan 3 22:14:48 2008 New Revision: 59677 Modified: python/trunk/Include/pyport.h Log: Some build bots don't compile mathmodule. There is an issue with the long definition of pi and euler Modified: python/trunk/Include/pyport.h ============================================================================== --- python/trunk/Include/pyport.h (original) +++ python/trunk/Include/pyport.h Thu Jan 3 22:14:48 2008 @@ -352,12 +352,19 @@ /* High precision defintion of pi and e (Euler) * The values are taken from libc6's math.h. */ +#ifndef Py_MATH_PIl +#define Py_MATH_PIl 3.1415926535897932384626433832795029L +#endif #ifndef Py_MATH_PI -#define Py_MATH_PI 3.1415926535897932384626433832795029L +#define Py_MATH_PI 3.14159265358979323846 +#endif + +#ifndef Py_MATH_El +#define Py_MATH_El 2.7182818284590452353602874713526625L #endif #ifndef Py_MATH_E -#define Py_MATH_E 2.7182818284590452353602874713526625L +#define Py_MATH_E 2.7182818284590452354 #endif /* Py_IS_NAN(X) From python-checkins at python.org Thu Jan 3 23:16:33 2008 From: python-checkins at python.org (christian.heimes) Date: Thu, 3 Jan 2008 23:16:33 +0100 (CET) Subject: [Python-checkins] r59678 - in python/trunk: Doc/c-api/utilities.rst Include/import.h Include/py_curses.h Mac/Modules/MacOS.c Misc/NEWS Modules/_ctypes/callbacks.c Modules/_cursesmodule.c Modules/cjkcodecs/cjkcodecs.h Modules/datetimemodule.c Modules/gcmodule.c Modules/parsermodule.c Modules/posixmodule.c Modules/socketmodule.h Modules/timemodule.c Modules/zipimport.c Objects/unicodeobject.c Python/errors.c Python/import.c Python/mactoolboxglue.c Message-ID: <20080103221633.9AF9E1E4006@bag.python.org> Author: christian.heimes Date: Thu Jan 3 23:16:32 2008 New Revision: 59678 Modified: python/trunk/Doc/c-api/utilities.rst python/trunk/Include/import.h python/trunk/Include/py_curses.h python/trunk/Mac/Modules/MacOS.c python/trunk/Misc/NEWS python/trunk/Modules/_ctypes/callbacks.c python/trunk/Modules/_cursesmodule.c python/trunk/Modules/cjkcodecs/cjkcodecs.h python/trunk/Modules/datetimemodule.c python/trunk/Modules/gcmodule.c python/trunk/Modules/parsermodule.c python/trunk/Modules/posixmodule.c python/trunk/Modules/socketmodule.h python/trunk/Modules/timemodule.c python/trunk/Modules/zipimport.c python/trunk/Objects/unicodeobject.c python/trunk/Python/errors.c python/trunk/Python/import.c python/trunk/Python/mactoolboxglue.c Log: Modified PyImport_Import and PyImport_ImportModule to always use absolute imports by calling __import__ with an explicit level of 0 Added a new API function PyImport_ImportModuleNoBlock. It solves the problem with dead locks when mixing threads and imports Modified: python/trunk/Doc/c-api/utilities.rst ============================================================================== --- python/trunk/Doc/c-api/utilities.rst (original) +++ python/trunk/Doc/c-api/utilities.rst Thu Jan 3 23:16:32 2008 @@ -183,7 +183,8 @@ single: __all__ (package variable) This is a simplified interface to :cfunc:`PyImport_ImportModuleEx` below, - leaving the *globals* and *locals* arguments set to *NULL*. When the *name* + leaving the *globals* and *locals* arguments set to *NULL* and *level* set + to 0. When the *name* argument contains a dot (when it specifies a submodule of a package), the *fromlist* argument is set to the list ``['*']`` so that the return value is the named module rather than the top-level package containing it as would otherwise @@ -198,9 +199,28 @@ .. versionchanged:: 2.4 failing imports remove incomplete module objects. + .. versionchanged:: 2.6 + always use absolute imports + .. index:: single: modules (in module sys) +.. cfunction:: PyObject* PyImport_ImportModuleNoBlock(const char *name) + + .. index:: + single: `cfunc:PyImport_ImportModule` + + This version of `cfunc:PyImport_ImportModule` does not block. It's intended + to be used in C function which import other modules to execute a function. + The import may block if another thread holds the import lock. The function + `cfunc:PyImport_ImportModuleNoBlock` doesn't block. It first tries to fetch + the module from sys.modules and falls back to `cfunc:PyImport_ImportModule` + unless the the lock is hold. In the latter case the function raises an + ImportError. + + .. versionadded:: 2.6 + + .. cfunction:: PyObject* PyImport_ImportModuleEx(char *name, PyObject *globals, PyObject *locals, PyObject *fromlist) .. index:: builtin: __import__ @@ -218,6 +238,24 @@ .. versionchanged:: 2.4 failing imports remove incomplete module objects. + .. versionchanged:: 2.6 + The function is an alias for `cfunc:PyImport_ImportModuleLevel` with + -1 as level, meaning relative import. + + +.. cfunction:: PyObject* PyImport_ImportModuleLevel(char *name, PyObject *globals, PyObject *locals, PyObject *fromlist, int level) + + Import a module. This is best described by referring to the built-in Python + function :func:`__import__`, as the standard :func:`__import__` function calls + this function directly. + + The return value is a new reference to the imported module or top-level package, + or *NULL* with an exception set on failure. Like for :func:`__import__`, + the return value when a submodule of a package was requested is normally the + top-level package, unless a non-empty *fromlist* was given. + + ..versionadded:: 2.5 + .. cfunction:: PyObject* PyImport_Import(PyObject *name) @@ -230,6 +268,9 @@ current globals. This means that the import is done using whatever import hooks are installed in the current environment, e.g. by :mod:`rexec` or :mod:`ihooks`. + .. versionchanged:: 2.6 + always use absolute imports + .. cfunction:: PyObject* PyImport_ReloadModule(PyObject *m) Modified: python/trunk/Include/import.h ============================================================================== --- python/trunk/Include/import.h (original) +++ python/trunk/Include/import.h Thu Jan 3 23:16:32 2008 @@ -14,13 +14,10 @@ PyAPI_FUNC(PyObject *) PyImport_GetModuleDict(void); PyAPI_FUNC(PyObject *) PyImport_AddModule(const char *name); PyAPI_FUNC(PyObject *) PyImport_ImportModule(const char *name); +PyAPI_FUNC(PyObject *) PyImport_ImportModuleNoBlock(const char *); PyAPI_FUNC(PyObject *) PyImport_ImportModuleLevel(char *name, PyObject *globals, PyObject *locals, PyObject *fromlist, int level); -/* For DLL compatibility */ -#undef PyImport_ImportModuleEx -PyAPI_FUNC(PyObject *) PyImport_ImportModuleEx( - char *name, PyObject *globals, PyObject *locals, PyObject *fromlist); #define PyImport_ImportModuleEx(n, g, l, f) \ PyImport_ImportModuleLevel(n, g, l, f, -1) Modified: python/trunk/Include/py_curses.h ============================================================================== --- python/trunk/Include/py_curses.h (original) +++ python/trunk/Include/py_curses.h Thu Jan 3 23:16:32 2008 @@ -90,7 +90,7 @@ #define import_curses() \ { \ - PyObject *module = PyImport_ImportModule("_curses"); \ + PyObject *module = PyImport_ImportModuleNoBlock("_curses"); \ if (module != NULL) { \ PyObject *module_dict = PyModule_GetDict(module); \ PyObject *c_api_object = PyDict_GetItemString(module_dict, "_C_API"); \ Modified: python/trunk/Mac/Modules/MacOS.c ============================================================================== --- python/trunk/Mac/Modules/MacOS.c (original) +++ python/trunk/Mac/Modules/MacOS.c Thu Jan 3 23:16:32 2008 @@ -357,7 +357,7 @@ PyObject *m, *rv; errors_loaded = 1; - m = PyImport_ImportModule("macresource"); + m = PyImport_ImportModuleNoBlock("macresource"); if (!m) { if (Py_VerboseFlag) PyErr_Print(); Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Thu Jan 3 23:16:32 2008 @@ -14,25 +14,10 @@ - Issue #1640: Added math.isinf() and math.isnan() functions. -- Issue #1726: Remove Python/atof.c from PCBuild/pythoncore.vcproj - -- Removed PCbuild8/ directory and added a new build directory for VS 2005 - based on the VS 2008 build directory to PC/VS8.0. The script - PCbuild/vs8to9.py was added to sync changes from PCbuild to PC/VS8.0. - -- Moved PCbuild/ directory for VS 2003 to PC/VS7.1 and renamed PCBuild9/ - directory to PCBuild/. - -- Issue #1629: Renamed Py_Size, Py_Type and Py_Refcnt to Py_SIZE, Py_TYPE - and Py_REFCNT. - - Issue #1635: Platform independent creation and representation of NaN and INF. float("nan"), float("inf") and float("-inf") now work on every platform with IEEE 754 semantics. -- Added case insensitive comparsion methods ``PyOS_stricmp(char*, char*)`` - and ``PyOS_strnicmp(char*, char*, Py_ssize_t)``. - - Compiler now generates simpler and faster code for dictionary literals. The oparg for BUILD_MAP now indicates an estimated dictionary size. There is a new opcode, STORE_MAP, for adding entries to the dictionary. @@ -1165,6 +1150,15 @@ Build ----- +- Issue #1726: Remove Python/atof.c from PCBuild/pythoncore.vcproj + +- Removed PCbuild8/ directory and added a new build directory for VS 2005 + based on the VS 2008 build directory to PC/VS8.0. The script + PCbuild/vs8to9.py was added to sync changes from PCbuild to PC/VS8.0. + +- Moved PCbuild/ directory for VS 2003 to PC/VS7.1 and renamed PCBuild9/ + directory to PCBuild/. + - Bug #1699: Define _BSD_SOURCE only on OpenBSD. - Bug #1608: use -fwrapv when GCC supports it. This is important, @@ -1225,6 +1219,18 @@ C API ----- +- Added a new API function ``PyImport_ImportModuleNoBlock``. + +- ``PyImport_Import`` and ``PyImport_ImportModule`` now always do absolute + imports. In earlier versions they might have used relative imports under + some conditions. + +- Issue #1629: Renamed Py_Size, Py_Type and Py_Refcnt to Py_SIZE, Py_TYPE + and Py_REFCNT. + +- Added case insensitive comparsion methods ``PyOS_stricmp(char*, char*)`` + and ``PyOS_strnicmp(char*, char*, Py_ssize_t)``. + - Bug #1542693: remove semi-colon at end of PyImport_ImportModuleEx macro so it can be used as an expression. Modified: python/trunk/Modules/_ctypes/callbacks.c ============================================================================== --- python/trunk/Modules/_ctypes/callbacks.c (original) +++ python/trunk/Modules/_ctypes/callbacks.c Thu Jan 3 23:16:32 2008 @@ -370,7 +370,7 @@ if (context == NULL) context = PyString_FromString("_ctypes.DllGetClassObject"); - mod = PyImport_ImportModule("ctypes"); + mod = PyImport_ImportModuleNoBlock("ctypes"); if (!mod) { PyErr_WriteUnraisable(context ? context : Py_None); /* There has been a warning before about this already */ @@ -449,7 +449,7 @@ if (context == NULL) context = PyString_FromString("_ctypes.DllCanUnloadNow"); - mod = PyImport_ImportModule("ctypes"); + mod = PyImport_ImportModuleNoBlock("ctypes"); if (!mod) { /* OutputDebugString("Could not import ctypes"); */ /* We assume that this error can only occur when shutting Modified: python/trunk/Modules/_cursesmodule.c ============================================================================== --- python/trunk/Modules/_cursesmodule.c (original) +++ python/trunk/Modules/_cursesmodule.c Thu Jan 3 23:16:32 2008 @@ -2255,7 +2255,7 @@ update_lines_cols(void) { PyObject *o; - PyObject *m = PyImport_ImportModule("curses"); + PyObject *m = PyImport_ImportModuleNoBlock("curses"); if (!m) return 0; Modified: python/trunk/Modules/cjkcodecs/cjkcodecs.h ============================================================================== --- python/trunk/Modules/cjkcodecs/cjkcodecs.h (original) +++ python/trunk/Modules/cjkcodecs/cjkcodecs.h Thu Jan 3 23:16:32 2008 @@ -245,7 +245,7 @@ static PyObject *cofunc = NULL; if (cofunc == NULL) { - PyObject *mod = PyImport_ImportModule("_multibytecodec"); + PyObject *mod = PyImport_ImportModuleNoBlock("_multibytecodec"); if (mod == NULL) return NULL; cofunc = PyObject_GetAttrString(mod, "__create_codec"); Modified: python/trunk/Modules/datetimemodule.c ============================================================================== --- python/trunk/Modules/datetimemodule.c (original) +++ python/trunk/Modules/datetimemodule.c Thu Jan 3 23:16:32 2008 @@ -1305,7 +1305,7 @@ if (_PyString_Resize(&newfmt, usednew) < 0) goto Done; { - PyObject *time = PyImport_ImportModule("time"); + PyObject *time = PyImport_ImportModuleNoBlock("time"); if (time == NULL) goto Done; result = PyObject_CallMethod(time, "strftime", "OO", @@ -1353,7 +1353,7 @@ time_time(void) { PyObject *result = NULL; - PyObject *time = PyImport_ImportModule("time"); + PyObject *time = PyImport_ImportModuleNoBlock("time"); if (time != NULL) { result = PyObject_CallMethod(time, "time", "()"); @@ -1371,7 +1371,7 @@ PyObject *time; PyObject *result = NULL; - time = PyImport_ImportModule("time"); + time = PyImport_ImportModuleNoBlock("time"); if (time != NULL) { result = PyObject_CallMethod(time, "struct_time", "((iiiiiiiii))", @@ -3827,7 +3827,7 @@ if (!PyArg_ParseTuple(args, "ss:strptime", &string, &format)) return NULL; - if ((module = PyImport_ImportModule("time")) == NULL) + if ((module = PyImport_ImportModuleNoBlock("time")) == NULL) return NULL; obj = PyObject_CallMethod(module, "strptime", "ss", string, format); Py_DECREF(module); Modified: python/trunk/Modules/gcmodule.c ============================================================================== --- python/trunk/Modules/gcmodule.c (original) +++ python/trunk/Modules/gcmodule.c Thu Jan 3 23:16:32 2008 @@ -1236,7 +1236,7 @@ * the import and triggers an assertion. */ if (tmod == NULL) { - tmod = PyImport_ImportModule("time"); + tmod = PyImport_ImportModuleNoBlock("time"); if (tmod == NULL) PyErr_Clear(); } Modified: python/trunk/Modules/parsermodule.c ============================================================================== --- python/trunk/Modules/parsermodule.c (original) +++ python/trunk/Modules/parsermodule.c Thu Jan 3 23:16:32 2008 @@ -3269,7 +3269,7 @@ * If this fails, the import of this module will fail because an * exception will be raised here; should we clear the exception? */ - copyreg = PyImport_ImportModule("copy_reg"); + copyreg = PyImport_ImportModuleNoBlock("copy_reg"); if (copyreg != NULL) { PyObject *func, *pickler; Modified: python/trunk/Modules/posixmodule.c ============================================================================== --- python/trunk/Modules/posixmodule.c (original) +++ python/trunk/Modules/posixmodule.c Thu Jan 3 23:16:32 2008 @@ -5651,7 +5651,7 @@ return posix_error(); if (struct_rusage == NULL) { - PyObject *m = PyImport_ImportModule("resource"); + PyObject *m = PyImport_ImportModuleNoBlock("resource"); if (m == NULL) return NULL; struct_rusage = PyObject_GetAttrString(m, "struct_rusage"); Modified: python/trunk/Modules/socketmodule.h ============================================================================== --- python/trunk/Modules/socketmodule.h (original) +++ python/trunk/Modules/socketmodule.h Thu Jan 3 23:16:32 2008 @@ -222,7 +222,7 @@ void *api; DPRINTF("Importing the %s C API...\n", apimodule); - mod = PyImport_ImportModule(apimodule); + mod = PyImport_ImportModuleNoBlock(apimodule); if (mod == NULL) goto onError; DPRINTF(" %s package found\n", apimodule); Modified: python/trunk/Modules/timemodule.c ============================================================================== --- python/trunk/Modules/timemodule.c (original) +++ python/trunk/Modules/timemodule.c Thu Jan 3 23:16:32 2008 @@ -515,7 +515,7 @@ static PyObject * time_strptime(PyObject *self, PyObject *args) { - PyObject *strptime_module = PyImport_ImportModule("_strptime"); + PyObject *strptime_module = PyImport_ImportModuleNoBlock("_strptime"); PyObject *strptime_result; if (!strptime_module) @@ -627,7 +627,7 @@ { PyObject* m; - m = PyImport_ImportModule("time"); + m = PyImport_ImportModuleNoBlock("time"); if (m == NULL) { return NULL; } Modified: python/trunk/Modules/zipimport.c ============================================================================== --- python/trunk/Modules/zipimport.c (original) +++ python/trunk/Modules/zipimport.c Thu Jan 3 23:16:32 2008 @@ -776,7 +776,7 @@ let's avoid a stack overflow. */ return NULL; importing_zlib = 1; - zlib = PyImport_ImportModule("zlib"); /* import zlib */ + zlib = PyImport_ImportModuleNoBlock("zlib"); importing_zlib = 0; if (zlib != NULL) { decompress = PyObject_GetAttrString(zlib, Modified: python/trunk/Objects/unicodeobject.c ============================================================================== --- python/trunk/Objects/unicodeobject.c (original) +++ python/trunk/Objects/unicodeobject.c Thu Jan 3 23:16:32 2008 @@ -2216,7 +2216,7 @@ if (ucnhash_CAPI == NULL) { /* load the unicode data module */ PyObject *m, *api; - m = PyImport_ImportModule("unicodedata"); + m = PyImport_ImportModuleNoBlock("unicodedata"); if (m == NULL) goto ucnhashError; api = PyObject_GetAttrString(m, "ucnhash_CAPI"); Modified: python/trunk/Python/errors.c ============================================================================== --- python/trunk/Python/errors.c (original) +++ python/trunk/Python/errors.c Thu Jan 3 23:16:32 2008 @@ -690,7 +690,7 @@ { PyObject *mod, *dict, *func = NULL; - mod = PyImport_ImportModule("warnings"); + mod = PyImport_ImportModuleNoBlock("warnings"); if (mod != NULL) { dict = PyModule_GetDict(mod); func = PyDict_GetItemString(dict, "warn_explicit"); Modified: python/trunk/Python/import.c ============================================================================== --- python/trunk/Python/import.c (original) +++ python/trunk/Python/import.c Thu Jan 3 23:16:32 2008 @@ -1985,6 +1985,53 @@ return result; } +/* Import a module without blocking + * + * At first it tries to fetch the module from sys.modules. If the module was + * never loaded before it loads it with PyImport_ImportModule() unless another + * thread holds the import lock. In the latter case the function raises an + * ImportError instead of blocking. + * + * Returns the module object with incremented ref count. + */ +PyObject * +PyImport_ImportModuleNoBlock(const char *name) +{ + PyObject *result; + PyObject *modules; + long me; + + /* Try to get the module from sys.modules[name] */ + modules = PyImport_GetModuleDict(); + if (modules == NULL) + return NULL; + + result = PyDict_GetItemString(modules, name); + if (result != NULL) { + Py_INCREF(result); + return result; + } + else { + PyErr_Clear(); + } + + /* check the import lock + * me might be -1 but I ignore the error here, the lock function + * takes care of the problem */ + me = PyThread_get_thread_ident(); + if (import_lock_thread == -1 || import_lock_thread == me) { + /* no thread or me is holding the lock */ + return PyImport_ImportModule(name); + } + else { + PyErr_Format(PyExc_ImportError, + "Failed to import %.200s because the import lock" + "is held by another thread.", + name); + return NULL; + } +} + /* Forward declarations for helper routines */ static PyObject *get_parent(PyObject *globals, char *buf, Py_ssize_t *p_buflen, int level); @@ -2054,26 +2101,6 @@ return tail; } -/* For DLL compatibility */ -#undef PyImport_ImportModuleEx -PyObject * -PyImport_ImportModuleEx(char *name, PyObject *globals, PyObject *locals, - PyObject *fromlist) -{ - PyObject *result; - lock_import(); - result = import_module_level(name, globals, locals, fromlist, -1); - if (unlock_import() < 0) { - Py_XDECREF(result); - PyErr_SetString(PyExc_RuntimeError, - "not holding the import lock"); - return NULL; - } - return result; -} -#define PyImport_ImportModuleEx(n, g, l, f) \ - PyImport_ImportModuleLevel(n, g, l, f, -1); - PyObject * PyImport_ImportModuleLevel(char *name, PyObject *globals, PyObject *locals, PyObject *fromlist, int level) @@ -2646,9 +2673,10 @@ if (import == NULL) goto err; - /* Call the __import__ function with the proper argument list */ - r = PyObject_CallFunctionObjArgs(import, module_name, globals, - globals, silly_list, NULL); + /* Call the __import__ function with the proper argument list + * Always use absolute import here. */ + r = PyObject_CallFunction(import, "OOOOi", module_name, globals, + globals, silly_list, 0, NULL); err: Py_XDECREF(globals); Modified: python/trunk/Python/mactoolboxglue.c ============================================================================== --- python/trunk/Python/mactoolboxglue.c (original) +++ python/trunk/Python/mactoolboxglue.c Thu Jan 3 23:16:32 2008 @@ -36,7 +36,7 @@ PyObject *m; PyObject *rv; - m = PyImport_ImportModule("MacOS"); + m = PyImport_ImportModuleNoBlock("MacOS"); if (!m) { if (Py_VerboseFlag) PyErr_Print(); From buildbot at python.org Thu Jan 3 23:25:28 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 03 Jan 2008 22:25:28 +0000 Subject: [Python-checkins] buildbot failure in alpha Tru64 5.1 trunk Message-ID: <20080103222529.5E8C31E4006@bag.python.org> The Buildbot has detected a new failure of alpha Tru64 5.1 trunk. Full details are available at: http://www.python.org/dev/buildbot/all/alpha%20Tru64%205.1%20trunk/builds/2193 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-tru64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: sincerely, -The Buildbot From buildbot at python.org Thu Jan 3 23:27:27 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 03 Jan 2008 22:27:27 +0000 Subject: [Python-checkins] buildbot failure in x86 FreeBSD trunk Message-ID: <20080103222728.166581E4006@bag.python.org> The Buildbot has detected a new failure of x86 FreeBSD trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20FreeBSD%20trunk/builds/323 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-freebsd Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 523, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 366, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 523, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 366, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/bsddb/test/test_thread.py", line 245, in writerThread self.assertEqual(data, self.makeData(key)) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/unittest.py", line 343, in failUnlessEqual (msg or '%r != %r' % (first, second)) AssertionError: None != '2123-2123-2123-2123-2123' Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/bsddb/test/test_thread.py", line 260, in writerThread self.assertEqual(data, self.makeData(key)) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/unittest.py", line 343, in failUnlessEqual (msg or '%r != %r' % (first, second)) AssertionError: None != '0002-0002-0002-0002-0002' Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/bsddb/test/test_thread.py", line 260, in writerThread self.assertEqual(data, self.makeData(key)) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/unittest.py", line 343, in failUnlessEqual (msg or '%r != %r' % (first, second)) AssertionError: None != '1000-1000-1000-1000-1000' 1 test failed: test_xmlrpc sincerely, -The Buildbot From python-checkins at python.org Thu Jan 3 23:32:27 2008 From: python-checkins at python.org (christian.heimes) Date: Thu, 3 Jan 2008 23:32:27 +0100 (CET) Subject: [Python-checkins] r59679 - in python/trunk: Doc/library/math.rst Lib/test/test_math.py Misc/NEWS Modules/mathmodule.c Message-ID: <20080103223227.020CB1E4006@bag.python.org> Author: christian.heimes Date: Thu Jan 3 23:32:26 2008 New Revision: 59679 Modified: python/trunk/Doc/library/math.rst python/trunk/Lib/test/test_math.py python/trunk/Misc/NEWS python/trunk/Modules/mathmodule.c Log: Added copysign(x, y) function to the math module Modified: python/trunk/Doc/library/math.rst ============================================================================== --- python/trunk/Doc/library/math.rst (original) +++ python/trunk/Doc/library/math.rst Thu Jan 3 23:32:26 2008 @@ -31,6 +31,14 @@ should return an :class:`Integral` value. +.. function:: copysign(x, y) + + Return *x* with the sign of *y*. ``copysign`` copies the sign bit of an IEEE + 754 float, ``copysign(1, -0.0)`` returns *-1.0*. + + ..versionadded:: 2.6 + + .. function:: fabs(x) Return the absolute value of *x*. Modified: python/trunk/Lib/test/test_math.py ============================================================================== --- python/trunk/Lib/test/test_math.py (original) +++ python/trunk/Lib/test/test_math.py Thu Jan 3 23:32:26 2008 @@ -229,6 +229,13 @@ self.ftest('tanh(0)', math.tanh(0), 0) self.ftest('tanh(1)+tanh(-1)', math.tanh(1)+math.tanh(-1), 0) + def testCopysign(self): + self.assertEqual(math.copysign(1, 42), 1.0) + self.assertEqual(math.copysign(0., 42), 0.0) + self.assertEqual(math.copysign(1., -42), -1.0) + self.assertEqual(math.copysign(3, 0.), 3.0) + self.assertEqual(math.copysign(4., -0.), -4.0) + def testIsnan(self): self.assert_(math.isnan(float("nan"))) self.assert_(math.isnan(float("inf")* 0.)) Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Thu Jan 3 23:32:26 2008 @@ -12,7 +12,8 @@ Core and builtins ----------------- -- Issue #1640: Added math.isinf() and math.isnan() functions. +- Issue #1640: Added math.isinf(x), math.isnan(x) and math.copysign(x, y) + functions. - Issue #1635: Platform independent creation and representation of NaN and INF. float("nan"), float("inf") and float("-inf") now work on every Modified: python/trunk/Modules/mathmodule.c ============================================================================== --- python/trunk/Modules/mathmodule.c (original) +++ python/trunk/Modules/mathmodule.c Thu Jan 3 23:32:26 2008 @@ -133,6 +133,14 @@ "cos(x)\n\nReturn the cosine of x (measured in radians).") FUNC1(cosh, cosh, "cosh(x)\n\nReturn the hyperbolic cosine of x.") +#if defined(MS_WINDOWS) || defined(HAVE_COPYSIGN) +#ifdef MS_WINDOWS +FUNC2(copysign, _copysign, +#else +FUNC2(copysign, copysign, +#endif + "copysign(x,y)\n\nReturn x with the sign of y."); +#endif FUNC1(exp, exp, "exp(x)\n\nReturn e raised to the power of x.") FUNC1(fabs, fabs, @@ -375,6 +383,9 @@ {"atan", math_atan, METH_O, math_atan_doc}, {"atan2", math_atan2, METH_VARARGS, math_atan2_doc}, {"ceil", math_ceil, METH_O, math_ceil_doc}, +#if defined(MS_WINDOWS) || defined(HAVE_COPYSIGN) + {"copysign", math_copysign, METH_VARARGS, math_copysign_doc}, +#endif {"cos", math_cos, METH_O, math_cos_doc}, {"cosh", math_cosh, METH_O, math_cosh_doc}, {"degrees", math_degrees, METH_O, math_degrees_doc}, From buildbot at python.org Thu Jan 3 23:47:36 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 03 Jan 2008 22:47:36 +0000 Subject: [Python-checkins] buildbot failure in x86 XP-3 trunk Message-ID: <20080103224736.A56711E4006@bag.python.org> The Buildbot has detected a new failure of x86 XP-3 trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20XP-3%20trunk/builds/570 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: heller-windows Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: christian.heimes BUILD FAILED: failed compile sincerely, -The Buildbot From buildbot at python.org Fri Jan 4 00:18:09 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 03 Jan 2008 23:18:09 +0000 Subject: [Python-checkins] buildbot failure in x86 XP-4 3.0 Message-ID: <20080103231809.CA6FE1E4006@bag.python.org> The Buildbot has detected a new failure of x86 XP-4 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20XP-4%203.0/builds/381 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-windows Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes BUILD FAILED: failed compile sincerely, -The Buildbot From python-checkins at python.org Fri Jan 4 00:44:38 2008 From: python-checkins at python.org (phillip.eby) Date: Fri, 4 Jan 2008 00:44:38 +0100 (CET) Subject: [Python-checkins] r59683 - in sandbox/trunk/setuptools: launcher.c setuptools/gui.exe setuptools/tests/win_script_wrapper.txt Message-ID: <20080103234438.D5C4B1E4006@bag.python.org> Author: phillip.eby Date: Fri Jan 4 00:44:38 2008 New Revision: 59683 Modified: sandbox/trunk/setuptools/launcher.c sandbox/trunk/setuptools/setuptools/gui.exe sandbox/trunk/setuptools/setuptools/tests/win_script_wrapper.txt Log: Fix gui.exe launcher issue reported by Alexander Michael and Robin Dunn. Modified: sandbox/trunk/setuptools/launcher.c ============================================================================== --- sandbox/trunk/setuptools/launcher.c (original) +++ sandbox/trunk/setuptools/launcher.c Fri Jan 4 00:44:38 2008 @@ -231,8 +231,8 @@ if (is_gui) { /* Use exec, we don't need to wait for the GUI to finish */ - execv(python, (const char * const *)(newargs)); - return fail("Could not exec %s", python); /* shouldn't get here! */ + execv(ptr, (const char * const *)(newargs)); + return fail("Could not exec %s", ptr); /* shouldn't get here! */ } /* We *do* need to wait for a CLI to finish, so use spawn */ Modified: sandbox/trunk/setuptools/setuptools/gui.exe ============================================================================== Binary files. No diff available. Modified: sandbox/trunk/setuptools/setuptools/tests/win_script_wrapper.txt ============================================================================== --- sandbox/trunk/setuptools/setuptools/tests/win_script_wrapper.txt (original) +++ sandbox/trunk/setuptools/setuptools/tests/win_script_wrapper.txt Fri Jan 4 00:44:38 2008 @@ -5,8 +5,7 @@ executed like regular windows programs. There are 2 wrappers, once for command-line programs, cli.exe, and one for graphica programs, gui.exe. These programs are almost identical, function pretty much -the same way, and are generated from the same source file. In this -document, we'll demonstrate use of the command-line program only. The +the same way, and are generated from the same source file. The wrapper programs are used by copying them to the directory containing the script they are to wrap and with the same name as the script they are to wrap. In the rest of this document, we'll give an example that @@ -68,13 +67,14 @@ - One or more backslashes preceding double quotes quotes need to be escaped by preceding each of them them with back slashes. + Specifying Python Command-line Options -------------------------------------- You can specify a single argument on the '#!' line. This can be used to specify Python options like -O, to run in optimized mode or -i to start the interactive interpreter. You can combine multiple -options as usual. For example, to run in optimized mode and +options as usual. For example, to run in optimized mode and enter the interpreter after running the script, you could use -Oi: >>> open(os.path.join(sample_directory, 'foo-script.py'), 'w').write( @@ -97,8 +97,41 @@ '' --- +Testing the GUI Version +----------------------- + +Now let's test the GUI version with the simple scipt, bar-script.py: + + >>> import os, sys, tempfile + >>> from setuptools.command.easy_install import nt_quote_arg + >>> sample_directory = tempfile.mkdtemp() + >>> open(os.path.join(sample_directory, 'bar-script.pyw'), 'w').write( + ... """#!%(python_exe)s + ... import sys + ... open(sys.argv[1], 'wb').write(repr(sys.argv[2])) + ... """ % dict(python_exe=nt_quote_arg(sys.executable))) + +We'll also copy gui.exe to the sample-directory with the name bar.exe: + + >>> import pkg_resources + >>> open(os.path.join(sample_directory, 'bar.exe'), 'wb').write( + ... pkg_resources.resource_string('setuptools', 'gui.exe') + ... ) + +Finally, we'll run the script and check the result: + + >>> import os + >>> input, output = os.popen4('"'+nt_quote_arg(os.path.join(sample_directory, 'bar.exe')) + ... + r' "%s" "Test Argument"' % os.path.join(sample_directory, 'test_output.txt')) + >>> input.close() + >>> print output.read() + + >>> print open(os.path.join(sample_directory, 'test_output.txt'), 'rb').read() + 'Test Argument' + We're done with the sample_directory: >>> import shutil >>> shutil.rmtree(sample_directory) + From buildbot at python.org Fri Jan 4 00:45:51 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 03 Jan 2008 23:45:51 +0000 Subject: [Python-checkins] buildbot failure in x86 FreeBSD trunk Message-ID: <20080103234552.13BD11E4006@bag.python.org> The Buildbot has detected a new failure of x86 FreeBSD trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20FreeBSD%20trunk/builds/325 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-freebsd Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 523, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 366, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable 2 tests failed: test_timeout test_urllib2net sincerely, -The Buildbot From python-checkins at python.org Fri Jan 4 00:48:02 2008 From: python-checkins at python.org (phillip.eby) Date: Fri, 4 Jan 2008 00:48:02 +0100 (CET) Subject: [Python-checkins] r59684 - in sandbox/branches/setuptools-0.6: EasyInstall.txt launcher.c setuptools/gui.exe setuptools/tests/win_script_wrapper.txt Message-ID: <20080103234802.C682C1E4006@bag.python.org> Author: phillip.eby Date: Fri Jan 4 00:48:02 2008 New Revision: 59684 Modified: sandbox/branches/setuptools-0.6/EasyInstall.txt sandbox/branches/setuptools-0.6/launcher.c sandbox/branches/setuptools-0.6/setuptools/gui.exe sandbox/branches/setuptools-0.6/setuptools/tests/win_script_wrapper.txt Log: Backport gui.exe launcher fix. Modified: sandbox/branches/setuptools-0.6/EasyInstall.txt ============================================================================== --- sandbox/branches/setuptools-0.6/EasyInstall.txt (original) +++ sandbox/branches/setuptools-0.6/EasyInstall.txt Fri Jan 4 00:48:02 2008 @@ -1237,6 +1237,8 @@ * Prevent ``--help-commands`` and other junk from showing under Python 2.5 when running ``easy_install --help``. + * Fixed GUI scripts sometimes not executing on Windows + 0.6c7 * ``ftp:`` download URLs now work correctly. Modified: sandbox/branches/setuptools-0.6/launcher.c ============================================================================== --- sandbox/branches/setuptools-0.6/launcher.c (original) +++ sandbox/branches/setuptools-0.6/launcher.c Fri Jan 4 00:48:02 2008 @@ -231,8 +231,8 @@ if (is_gui) { /* Use exec, we don't need to wait for the GUI to finish */ - execv(python, (const char * const *)(newargs)); - return fail("Could not exec %s", python); /* shouldn't get here! */ + execv(ptr, (const char * const *)(newargs)); + return fail("Could not exec %s", ptr); /* shouldn't get here! */ } /* We *do* need to wait for a CLI to finish, so use spawn */ Modified: sandbox/branches/setuptools-0.6/setuptools/gui.exe ============================================================================== Binary files. No diff available. Modified: sandbox/branches/setuptools-0.6/setuptools/tests/win_script_wrapper.txt ============================================================================== --- sandbox/branches/setuptools-0.6/setuptools/tests/win_script_wrapper.txt (original) +++ sandbox/branches/setuptools-0.6/setuptools/tests/win_script_wrapper.txt Fri Jan 4 00:48:02 2008 @@ -5,8 +5,7 @@ executed like regular windows programs. There are 2 wrappers, once for command-line programs, cli.exe, and one for graphica programs, gui.exe. These programs are almost identical, function pretty much -the same way, and are generated from the same source file. In this -document, we'll demonstrate use of the command-line program only. The +the same way, and are generated from the same source file. The wrapper programs are used by copying them to the directory containing the script they are to wrap and with the same name as the script they are to wrap. In the rest of this document, we'll give an example that @@ -68,13 +67,14 @@ - One or more backslashes preceding double quotes quotes need to be escaped by preceding each of them them with back slashes. + Specifying Python Command-line Options -------------------------------------- You can specify a single argument on the '#!' line. This can be used to specify Python options like -O, to run in optimized mode or -i to start the interactive interpreter. You can combine multiple -options as usual. For example, to run in optimized mode and +options as usual. For example, to run in optimized mode and enter the interpreter after running the script, you could use -Oi: >>> open(os.path.join(sample_directory, 'foo-script.py'), 'w').write( @@ -97,8 +97,41 @@ '' --- +Testing the GUI Version +----------------------- + +Now let's test the GUI version with the simple scipt, bar-script.py: + + >>> import os, sys, tempfile + >>> from setuptools.command.easy_install import nt_quote_arg + >>> sample_directory = tempfile.mkdtemp() + >>> open(os.path.join(sample_directory, 'bar-script.pyw'), 'w').write( + ... """#!%(python_exe)s + ... import sys + ... open(sys.argv[1], 'wb').write(repr(sys.argv[2])) + ... """ % dict(python_exe=nt_quote_arg(sys.executable))) + +We'll also copy gui.exe to the sample-directory with the name bar.exe: + + >>> import pkg_resources + >>> open(os.path.join(sample_directory, 'bar.exe'), 'wb').write( + ... pkg_resources.resource_string('setuptools', 'gui.exe') + ... ) + +Finally, we'll run the script and check the result: + + >>> import os + >>> input, output = os.popen4('"'+nt_quote_arg(os.path.join(sample_directory, 'bar.exe')) + ... + r' "%s" "Test Argument"' % os.path.join(sample_directory, 'test_output.txt')) + >>> input.close() + >>> print output.read() + + >>> print open(os.path.join(sample_directory, 'test_output.txt'), 'rb').read() + 'Test Argument' + We're done with the sample_directory: >>> import shutil >>> shutil.rmtree(sample_directory) + From python-checkins at python.org Fri Jan 4 00:52:05 2008 From: python-checkins at python.org (guido.van.rossum) Date: Fri, 4 Jan 2008 00:52:05 +0100 (CET) Subject: [Python-checkins] r59685 - in python/branches/release25-maint: Misc/NEWS Modules/_tkinter.c Message-ID: <20080103235205.131E41E4007@bag.python.org> Author: guido.van.rossum Date: Fri Jan 4 00:52:04 2008 New Revision: 59685 Modified: python/branches/release25-maint/Misc/NEWS python/branches/release25-maint/Modules/_tkinter.c Log: Fix bug #1301 -- a bad assert in _tkinter. Modified: python/branches/release25-maint/Misc/NEWS ============================================================================== --- python/branches/release25-maint/Misc/NEWS (original) +++ python/branches/release25-maint/Misc/NEWS Fri Jan 4 00:52:04 2008 @@ -157,6 +157,8 @@ Extension Modules ----------------- +- Bug #1301: Bad assert in _tkinter fixed. + - Bug #1649098: Avoid declaration of zero-sized array declaration in structure. Modified: python/branches/release25-maint/Modules/_tkinter.c ============================================================================== --- python/branches/release25-maint/Modules/_tkinter.c (original) +++ python/branches/release25-maint/Modules/_tkinter.c Fri Jan 4 00:52:04 2008 @@ -936,10 +936,12 @@ /* This #ifdef assumes that Tcl uses UCS-2. See TCL_UTF_MAX test above. */ #if defined(Py_UNICODE_WIDE) && TCL_UTF_MAX == 3 - Tcl_UniChar *outbuf; + Tcl_UniChar *outbuf = NULL; Py_ssize_t i; - assert(size < size * sizeof(Tcl_UniChar)); - outbuf = (Tcl_UniChar*)ckalloc(size * sizeof(Tcl_UniChar)); + size_t allocsize = ((size_t)size) * sizeof(Tcl_UniChar); + if (allocsize >= size) + outbuf = (Tcl_UniChar*)ckalloc(allocsize); + /* Else overflow occurred, and we take the next exit */ if (!outbuf) { PyErr_NoMemory(); return NULL; From python-checkins at python.org Fri Jan 4 00:54:04 2008 From: python-checkins at python.org (guido.van.rossum) Date: Fri, 4 Jan 2008 00:54:04 +0100 (CET) Subject: [Python-checkins] r59686 - in python/trunk: Misc/NEWS Modules/_tkinter.c Message-ID: <20080103235404.7B4361E4006@bag.python.org> Author: guido.van.rossum Date: Fri Jan 4 00:54:04 2008 New Revision: 59686 Modified: python/trunk/Misc/NEWS python/trunk/Modules/_tkinter.c Log: Bug #1301: fixed a bad assert in _tkinter. Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Fri Jan 4 00:54:04 2008 @@ -907,6 +907,8 @@ Extension Modules ----------------- +- Bug #1301: Bad assert in _tkinter fixed. + - Added bdist_wininst executable for VS 2008. - Bug #1604: collections.deque.__init__(iterable) now clears any prior contents Modified: python/trunk/Modules/_tkinter.c ============================================================================== --- python/trunk/Modules/_tkinter.c (original) +++ python/trunk/Modules/_tkinter.c Fri Jan 4 00:54:04 2008 @@ -936,10 +936,12 @@ /* This #ifdef assumes that Tcl uses UCS-2. See TCL_UTF_MAX test above. */ #if defined(Py_UNICODE_WIDE) && TCL_UTF_MAX == 3 - Tcl_UniChar *outbuf; + Tcl_UniChar *outbuf = NULL; Py_ssize_t i; - assert(size < size * sizeof(Tcl_UniChar)); - outbuf = (Tcl_UniChar*)ckalloc(size * sizeof(Tcl_UniChar)); + size_t allocsize = ((size_t)size) * sizeof(Tcl_UniChar); + if (allocsize >= size) + outbuf = (Tcl_UniChar*)ckalloc(allocsize); + /* Else overflow occurred, and we take the next exit */ if (!outbuf) { PyErr_NoMemory(); return NULL; From python-checkins at python.org Fri Jan 4 01:01:16 2008 From: python-checkins at python.org (raymond.hettinger) Date: Fri, 4 Jan 2008 01:01:16 +0100 (CET) Subject: [Python-checkins] r59687 - in python/trunk: Lib/struct.py Modules/_struct.c Message-ID: <20080104000116.9AF6E1E4006@bag.python.org> Author: raymond.hettinger Date: Fri Jan 4 01:01:15 2008 New Revision: 59687 Modified: python/trunk/Lib/struct.py python/trunk/Modules/_struct.c Log: Finish-up the struct module optimizations started at the Iceland NFS sprint. Modified: python/trunk/Lib/struct.py ============================================================================== --- python/trunk/Lib/struct.py (original) +++ python/trunk/Lib/struct.py Fri Jan 4 01:01:15 2008 @@ -1,99 +1 @@ -""" -Functions to convert between Python values and C structs. -Python strings are used to hold the data representing the C struct -and also as format strings to describe the layout of data in the C struct. - -The optional first format char indicates byte order, size and alignment: - @: native order, size & alignment (default) - =: native order, std. size & alignment - <: little-endian, std. size & alignment - >: big-endian, std. size & alignment - !: same as > - -The remaining chars indicate types of args and must match exactly; -these can be preceded by a decimal repeat count: - x: pad byte (no data); c:char; b:signed byte; B:unsigned byte; - h:short; H:unsigned short; i:int; I:unsigned int; - l:long; L:unsigned long; f:float; d:double. -Special cases (preceding decimal count indicates length): - s:string (array of char); p: pascal string (with count byte). -Special case (only available in native format): - P:an integer type that is wide enough to hold a pointer. -Special case (not in native mode unless 'long long' in platform C): - q:long long; Q:unsigned long long -Whitespace between formats is ignored. - -The variable struct.error is an exception raised on errors. -""" -__version__ = '0.1' - -from _struct import Struct, error - -_MAXCACHE = 100 -_cache = {} - -def _compile(fmt): - # Internal: compile struct pattern - if len(_cache) >= _MAXCACHE: - _cache.clear() - s = Struct(fmt) - _cache[fmt] = s - return s - -def calcsize(fmt): - """ - Return size of C struct described by format string fmt. - See struct.__doc__ for more on format strings. - """ - try: - o = _cache[fmt] - except KeyError: - o = _compile(fmt) - return o.size - -def pack(fmt, *args): - """ - Return string containing values v1, v2, ... packed according to fmt. - See struct.__doc__ for more on format strings. - """ - try: - o = _cache[fmt] - except KeyError: - o = _compile(fmt) - return o.pack(*args) - -def pack_into(fmt, buf, offset, *args): - """ - Pack the values v1, v2, ... according to fmt, write - the packed bytes into the writable buffer buf starting at offset. - See struct.__doc__ for more on format strings. - """ - try: - o = _cache[fmt] - except KeyError: - o = _compile(fmt) - return o.pack_into(buf, offset, *args) - -def unpack(fmt, s): - """ - Unpack the string, containing packed C structure data, according - to fmt. Requires len(string)==calcsize(fmt). - See struct.__doc__ for more on format strings. - """ - try: - o = _cache[fmt] - except KeyError: - o = _compile(fmt) - return o.unpack(s) - -def unpack_from(fmt, buf, offset=0): - """ - Unpack the buffer, containing packed C structure data, according to - fmt starting at offset. Requires len(buffer[offset:]) >= calcsize(fmt). - See struct.__doc__ for more on format strings. - """ - try: - o = _cache[fmt] - except KeyError: - o = _compile(fmt) - return o.unpack_from(buf, offset) +from _struct import * Modified: python/trunk/Modules/_struct.c ============================================================================== --- python/trunk/Modules/_struct.c (original) +++ python/trunk/Modules/_struct.c Fri Jan 4 01:01:15 2008 @@ -1847,12 +1847,214 @@ PyObject_Del, /* tp_free */ }; + +/* ---- Standalone functions ---- */ + +#define MAXCACHE 100 + +static PyObject * +cache_struct(PyObject *fmt) +{ + static PyObject *cache = NULL; + PyObject * s_object; + + if (cache == NULL) { + cache = PyDict_New(); + if (cache == NULL) + return NULL; + } + + s_object = PyDict_GetItem(cache, fmt); + if (s_object != NULL) { + Py_INCREF(s_object); + return s_object; + } + + s_object = PyObject_CallFunctionObjArgs((PyObject *)(&PyStructType), fmt, NULL); + if (s_object != NULL) { + if (PyDict_Size(cache) >= MAXCACHE) + PyDict_Clear(cache); + /* Attempt to cache the result */ + if (PyDict_SetItem(cache, fmt, s_object) == -1) + PyErr_Clear(); + } + return s_object; +} + +PyDoc_STRVAR(calcsize_doc, +"Return size of C struct described by format string fmt."); + +static PyObject * +calcsize(PyObject *self, PyObject *fmt) +{ + Py_ssize_t n; + PyObject *s_object = cache_struct(fmt); + if (s_object == NULL) + return NULL; + n = ((PyStructObject *)s_object)->s_size; + Py_DECREF(s_object); + return PyInt_FromSsize_t(n); +} + +PyDoc_STRVAR(pack_doc, +"Return string containing values v1, v2, ... packed according to fmt."); + +static PyObject * +pack(PyObject *self, PyObject *args) +{ + PyObject *s_object, *fmt, *newargs, *result; + Py_ssize_t n = PyTuple_GET_SIZE(args); + + if (n == 0) { + PyErr_SetString(PyExc_TypeError, "missing format argument"); + return NULL; + } + fmt = PyTuple_GET_ITEM(args, 0); + newargs = PyTuple_GetSlice(args, 1, n); + if (newargs == NULL) + return NULL; + + s_object = cache_struct(fmt); + if (s_object == NULL) { + Py_DECREF(newargs); + return NULL; + } + result = s_pack(s_object, newargs); + Py_DECREF(newargs); + Py_DECREF(s_object); + return result; +} + +PyDoc_STRVAR(pack_into_doc, +"Pack the values v1, v2, ... according to fmt.\n\ +Write the packed bytes into the writable buffer buf starting at offset."); + +static PyObject * +pack_into(PyObject *self, PyObject *args) +{ + PyObject *s_object, *fmt, *newargs, *result; + Py_ssize_t n = PyTuple_GET_SIZE(args); + + if (n == 0) { + PyErr_SetString(PyExc_TypeError, "missing format argument"); + return NULL; + } + fmt = PyTuple_GET_ITEM(args, 0); + newargs = PyTuple_GetSlice(args, 1, n); + if (newargs == NULL) + return NULL; + + s_object = cache_struct(fmt); + if (s_object == NULL) { + Py_DECREF(newargs); + return NULL; + } + result = s_pack_into(s_object, newargs); + Py_DECREF(newargs); + Py_DECREF(s_object); + return result; +} + +PyDoc_STRVAR(unpack_doc, +"Unpack the string containing packed C structure data, according to fmt.\n\ +Requires len(string) == calcsize(fmt)."); + +static PyObject * +unpack(PyObject *self, PyObject *args) +{ + PyObject *s_object, *fmt, *inputstr, *result; + + if (!PyArg_UnpackTuple(args, "unpack", 2, 2, &fmt, &inputstr)) + return NULL; + + s_object = cache_struct(fmt); + if (s_object == NULL) + return NULL; + result = s_unpack(s_object, inputstr); + Py_DECREF(s_object); + return result; +} + +PyDoc_STRVAR(unpack_from_doc, +"Unpack the buffer, containing packed C structure data, according to\n\ +fmt, starting at offset. Requires len(buffer[offset:]) >= calcsize(fmt)."); + +static PyObject * +unpack_from(PyObject *self, PyObject *args, PyObject *kwds) +{ + PyObject *s_object, *fmt, *newargs, *result; + Py_ssize_t n = PyTuple_GET_SIZE(args); + + if (n == 0) { + PyErr_SetString(PyExc_TypeError, "missing format argument"); + return NULL; + } + fmt = PyTuple_GET_ITEM(args, 0); + newargs = PyTuple_GetSlice(args, 1, n); + if (newargs == NULL) + return NULL; + + s_object = cache_struct(fmt); + if (s_object == NULL) { + Py_DECREF(newargs); + return NULL; + } + result = s_unpack_from(s_object, newargs, kwds); + Py_DECREF(newargs); + Py_DECREF(s_object); + return result; +} + +static struct PyMethodDef module_functions[] = { + {"calcsize", calcsize, METH_O, calcsize_doc}, + {"pack", pack, METH_VARARGS, pack_doc}, + {"pack_into", pack_into, METH_VARARGS, pack_into_doc}, + {"unpack", unpack, METH_VARARGS, unpack_doc}, + {"unpack_from", (PyCFunction)unpack_from, + METH_VARARGS|METH_KEYWORDS, unpack_from_doc}, + {NULL, NULL} /* sentinel */ +}; + + /* Module initialization */ +PyDoc_STRVAR(module_doc, +"Functions to convert between Python values and C structs.\n\ +Python strings are used to hold the data representing the C struct\n\ +and also as format strings to describe the layout of data in the C struct.\n\ +\n\ +The optional first format char indicates byte order, size and alignment:\n\ + @: native order, size & alignment (default)\n\ + =: native order, std. size & alignment\n\ + <: little-endian, std. size & alignment\n\ + >: big-endian, std. size & alignment\n\ + !: same as >\n\ +\n\ +The remaining chars indicate types of args and must match exactly;\n\ +these can be preceded by a decimal repeat count:\n\ + x: pad byte (no data); c:char; b:signed byte; B:unsigned byte;\n\ + h:short; H:unsigned short; i:int; I:unsigned int;\n\ + l:long; L:unsigned long; f:float; d:double.\n\ +Special cases (preceding decimal count indicates length):\n\ + s:string (array of char); p: pascal string (with count byte).\n\ +Special case (only available in native format):\n\ + P:an integer type that is wide enough to hold a pointer.\n\ +Special case (not in native mode unless 'long long' in platform C):\n\ + q:long long; Q:unsigned long long\n\ +Whitespace between formats is ignored.\n\ +\n\ +The variable struct.error is an exception raised on errors.\n"); + PyMODINIT_FUNC init_struct(void) { - PyObject *m = Py_InitModule("_struct", NULL); + PyObject *ver, *m; + + ver = PyString_FromString("0.2"); + if (ver == NULL) + return; + + m = Py_InitModule3("_struct", module_functions, module_doc); if (m == NULL) return; @@ -1933,6 +2135,8 @@ Py_INCREF((PyObject*)&PyStructType); PyModule_AddObject(m, "Struct", (PyObject*)&PyStructType); + PyModule_AddObject(m, "__version__", ver); + PyModule_AddIntConstant(m, "_PY_STRUCT_RANGE_CHECKING", 1); #ifdef PY_STRUCT_OVERFLOW_MASKING PyModule_AddIntConstant(m, "_PY_STRUCT_OVERFLOW_MASKING", 1); From buildbot at python.org Fri Jan 4 01:04:32 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 04 Jan 2008 00:04:32 +0000 Subject: [Python-checkins] buildbot failure in g4 osx.4 3.0 Message-ID: <20080104000433.3EE0E1E4010@bag.python.org> The Buildbot has detected a new failure of g4 osx.4 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/g4%20osx.4%203.0/builds/403 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: psf-g4 Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_re ====================================================================== ERROR: test_inline_flags (test.test_re.ReTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/test/test_re.py", line 637, in test_inline_flags upper_char = unichr(0x1ea0) # Latin Capital Letter A with Dot Bellow NameError: global name 'unichr' is not defined make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Fri Jan 4 01:04:52 2008 From: python-checkins at python.org (christian.heimes) Date: Fri, 4 Jan 2008 01:04:52 +0100 (CET) Subject: [Python-checkins] r59688 - in python/trunk: Lib/plat-mac/plistlib.py Misc/NEWS Message-ID: <20080104000452.6D3151E4070@bag.python.org> Author: christian.heimes Date: Fri Jan 4 01:04:52 2008 New Revision: 59688 Modified: python/trunk/Lib/plat-mac/plistlib.py python/trunk/Misc/NEWS Log: Fixed #1687: plistlib.py restricts to Python int when writing Modified: python/trunk/Lib/plat-mac/plistlib.py ============================================================================== --- python/trunk/Lib/plat-mac/plistlib.py (original) +++ python/trunk/Lib/plat-mac/plistlib.py Fri Jan 4 01:04:52 2008 @@ -240,8 +240,8 @@ self.simpleElement("true") else: self.simpleElement("false") - elif isinstance(value, int): - self.simpleElement("integer", str(value)) + elif isinstance(value, (int, long)): + self.simpleElement("integer", "%d" % value) elif isinstance(value, float): self.simpleElement("real", repr(value)) elif isinstance(value, dict): Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Fri Jan 4 01:04:52 2008 @@ -336,6 +336,8 @@ Library ------- +- Bug #1687: Fxed plistlib.py restricts to Python int when writing + - Issue #1700: Regular expression inline flags incorrectly handle certain unicode characters. From python-checkins at python.org Fri Jan 4 01:37:35 2008 From: python-checkins at python.org (christian.heimes) Date: Fri, 4 Jan 2008 01:37:35 +0100 (CET) Subject: [Python-checkins] r59689 - in python/trunk: Lib/test/test_long.py Misc/NEWS Objects/longobject.c Message-ID: <20080104003735.47A761E400E@bag.python.org> Author: christian.heimes Date: Fri Jan 4 01:37:34 2008 New Revision: 59689 Modified: python/trunk/Lib/test/test_long.py python/trunk/Misc/NEWS python/trunk/Objects/longobject.c Log: Bug #1481296: Fixed long(float('nan'))!=0L. Modified: python/trunk/Lib/test/test_long.py ============================================================================== --- python/trunk/Lib/test/test_long.py (original) +++ python/trunk/Lib/test/test_long.py Fri Jan 4 01:37:34 2008 @@ -498,6 +498,10 @@ eq(x > y, Rcmp > 0, Frm("%r > %r %d", x, y, Rcmp)) eq(x >= y, Rcmp >= 0, Frm("%r >= %r %d", x, y, Rcmp)) + def test_nan_inf(self): + self.assertRaises(OverflowError, long, float('inf')) + self.assertEqual(long(float('nan')), 0L) + def test_main(): test_support.run_unittest(LongTest) Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Fri Jan 4 01:37:34 2008 @@ -12,6 +12,8 @@ Core and builtins ----------------- +- Bug #1481296: Fixed long(float('nan'))!=0L. + - Issue #1640: Added math.isinf(x), math.isnan(x) and math.copysign(x, y) functions. Modified: python/trunk/Objects/longobject.c ============================================================================== --- python/trunk/Objects/longobject.c (original) +++ python/trunk/Objects/longobject.c Fri Jan 4 01:37:34 2008 @@ -170,6 +170,9 @@ "cannot convert float infinity to long"); return NULL; } + if (Py_IS_NAN(dval)) { + return PyLong_FromLong(0L); + } if (dval < 0.0) { neg = 1; dval = -dval; From buildbot at python.org Fri Jan 4 01:55:22 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 04 Jan 2008 00:55:22 +0000 Subject: [Python-checkins] buildbot failure in ia64 Ubuntu 3.0 Message-ID: <20080104005522.9BE831E4006@bag.python.org> The Buildbot has detected a new failure of ia64 Ubuntu 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/ia64%20Ubuntu%203.0/builds/427 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ia64 Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_re ====================================================================== ERROR: test_inline_flags (test.test_re.ReTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ia64/build/Lib/test/test_re.py", line 637, in test_inline_flags upper_char = unichr(0x1ea0) # Latin Capital Letter A with Dot Bellow NameError: global name 'unichr' is not defined make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Fri Jan 4 02:03:35 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 04 Jan 2008 01:03:35 +0000 Subject: [Python-checkins] buildbot failure in alpha Tru64 5.1 2.5 Message-ID: <20080104010336.44A3E1E4006@bag.python.org> The Buildbot has detected a new failure of alpha Tru64 5.1 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/alpha%20Tru64%205.1%202.5/builds/384 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-tru64 Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: guido.van.rossum BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_socket ====================================================================== FAIL: testInterruptedTimeout (test.test_socket.TCPTimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/net/taipan/scratch1/nnorwitz/python/2.5.norwitz-tru64/build/Lib/test/test_socket.py", line 879, in testInterruptedTimeout self.fail("got Alarm in wrong place") AssertionError: got Alarm in wrong place sincerely, -The Buildbot From python-checkins at python.org Fri Jan 4 02:15:51 2008 From: python-checkins at python.org (andrew.kuchling) Date: Fri, 4 Jan 2008 02:15:51 +0100 (CET) Subject: [Python-checkins] r59691 - python/trunk/Doc/library/msvcrt.rst Message-ID: <20080104011551.495B41E4006@bag.python.org> Author: andrew.kuchling Date: Fri Jan 4 02:15:50 2008 New Revision: 59691 Modified: python/trunk/Doc/library/msvcrt.rst Log: Markup fixes; grammar tweaks Modified: python/trunk/Doc/library/msvcrt.rst ============================================================================== --- python/trunk/Doc/library/msvcrt.rst (original) +++ python/trunk/Doc/library/msvcrt.rst Fri Jan 4 02:15:50 2008 @@ -101,9 +101,9 @@ .. function:: getwch() - Wide char variant of `func:getch`, returns unicode. + Wide char variant of :func:`getch`, returning a Unicode value. - ..versionadded:: 2.6 + .. versionadded:: 2.6 .. function:: getche() @@ -114,9 +114,9 @@ .. function:: getwche() - Wide char variant of `func:getche`, returns unicode. + Wide char variant of :func:`getche`, returning a Unicode value. - ..versionadded:: 2.6 + .. versionadded:: 2.6 .. function:: putch(char) @@ -126,9 +126,9 @@ .. function:: putwch(unicode_char) - Wide char variant of `func:putch`, accepts unicode. + Wide char variant of :func:`putch`, accepting a Unicode value. - ..versionadded:: 2.6 + .. versionadded:: 2.6 .. function:: ungetch(char) @@ -139,9 +139,9 @@ .. function:: ungetwch(unicode_char) - Wide char variant of `func:ungetch`, accepts unicode. + Wide char variant of :func:`ungetch`, accepting a Unicode value. - ..versionadded:: 2.6 + .. versionadded:: 2.6 .. _msvcrt-other: From python-checkins at python.org Fri Jan 4 02:16:12 2008 From: python-checkins at python.org (andrew.kuchling) Date: Fri, 4 Jan 2008 02:16:12 +0100 (CET) Subject: [Python-checkins] r59692 - python/trunk/Doc/whatsnew/2.6.rst Message-ID: <20080104011612.79EC71E4006@bag.python.org> Author: andrew.kuchling Date: Fri Jan 4 02:16:12 2008 New Revision: 59692 Modified: python/trunk/Doc/whatsnew/2.6.rst Log: Add items Modified: python/trunk/Doc/whatsnew/2.6.rst ============================================================================== --- python/trunk/Doc/whatsnew/2.6.rst (original) +++ python/trunk/Doc/whatsnew/2.6.rst Fri Jan 4 02:16:12 2008 @@ -552,6 +552,14 @@ .. Patch 1507 +* More floating-point features were also added. The :func:`float` function + will now turn the strings ``+nan`` and ``-nan`` into the corresponding + IEEE 754 Not a Number values, and ``+inf`` and ``-inf`` into + positive or negative infinity. This works on any platform with + IEEE 754 semantics. (Contributed by XXX.) + + .. Patch 1635. + * Changes to the :class:`Exception` interface as dictated by :pep:`352` continue to be made. For 2.6, the :attr:`message` attribute is being deprecated in favor of the @@ -1058,11 +1066,31 @@ .. Issue 1534 +* Python's C API now includes two functions for case-insensitive string + comparisions, ``PyOS_stricmp(char*, char*)`` + and ``PyOS_strnicmp(char*, char*, Py_ssize_t)``. + (Contributed by XXX.) + + .. Issue 1635 + +* Some macros were renamed. :cmacro:`Py_Size()` became :cmacro:`Py_SIZE()`, + :cmacro:`Py_Type()` became :cmacro:`Py_TYPE()`, and + :cmacro:`Py_Refcnt()` became :cmacro:`Py_REFCNT()`. Macros for backward + compatibility are still available. + + .. Issue 1629: XXX why was this done? + .. ====================================================================== -Port-Specific Changes ---------------------- +Port-Specific Changes: Windows +----------------------------------- + +* The :mod:`msvcrt` module now supports + both the normal and wide char variants of the console I/O + API. The :func:`getwch` function reads a keypress and returns a Unicode + value, as does the :func:`getwche` function. The :func:`putwch` function + takes a Unicode character and writes it to the console. Platform-specific changes go here. @@ -1089,9 +1117,15 @@ Porting to Python 2.6 ===================== -This section lists previously described changes that may require changes to your +This section lists previously described changes, and a few +esoteric bugfixes, that may require changes to your code: +* The :method:`__init__` method of :class:`collections.deque` + now clears any existing contents of the deque + before adding elements from the iterable. This change makes the + behavior match that of ``list.__init__()``. + * The :mod:`socket` module exception :exc:`socket.error` now inherits from :exc:`IOError`. Previously it wasn't a subclass of :exc:`StandardError` but now it is, through :exc:`IOError`. From amk at amk.ca Fri Jan 4 02:20:48 2008 From: amk at amk.ca (A.M. Kuchling) Date: Thu, 3 Jan 2008 20:20:48 -0500 Subject: [Python-checkins] r59683 - in sandbox/trunk/setuptools: launcher.c setuptools/gui.exe setuptools/tests/win_script_wrapper.txt In-Reply-To: <20080103234438.D5C4B1E4006@bag.python.org> References: <20080103234438.D5C4B1E4006@bag.python.org> Message-ID: <20080104012031.GA11319@amk.local> On Fri, Jan 04, 2008 at 12:44:38AM +0100, phillip.eby wrote: > Date: Fri Jan 4 00:44:38 2008 > New Revision: 59683 > +Now let's test the GUI version with the simple scipt, bar-script.py: ^^^^^ typo: 'script' --amk From python-checkins at python.org Fri Jan 4 02:48:50 2008 From: python-checkins at python.org (christian.heimes) Date: Fri, 4 Jan 2008 02:48:50 +0100 (CET) Subject: [Python-checkins] r59694 - python/trunk/Modules/mathmodule.c Message-ID: <20080104014850.AE9961E4006@bag.python.org> Author: christian.heimes Date: Fri Jan 4 02:48:50 2008 New Revision: 59694 Modified: python/trunk/Modules/mathmodule.c Log: Fixed math.copysign() on Windows Modified: python/trunk/Modules/mathmodule.c ============================================================================== --- python/trunk/Modules/mathmodule.c (original) +++ python/trunk/Modules/mathmodule.c Fri Jan 4 02:48:50 2008 @@ -133,14 +133,16 @@ "cos(x)\n\nReturn the cosine of x (measured in radians).") FUNC1(cosh, cosh, "cosh(x)\n\nReturn the hyperbolic cosine of x.") -#if defined(MS_WINDOWS) || defined(HAVE_COPYSIGN) + #ifdef MS_WINDOWS -FUNC2(copysign, _copysign, -#else -FUNC2(copysign, copysign, +# define copysign _copysign +# define HAVE_COPYSIGN 1 #endif - "copysign(x,y)\n\nReturn x with the sign of y."); +#ifdef HAVE_COPYSIGN +FUNC2(copysign, copysign, + "copysign(x,y)\n\nReturn x with the sign of y."); #endif + FUNC1(exp, exp, "exp(x)\n\nReturn e raised to the power of x.") FUNC1(fabs, fabs, @@ -383,7 +385,7 @@ {"atan", math_atan, METH_O, math_atan_doc}, {"atan2", math_atan2, METH_VARARGS, math_atan2_doc}, {"ceil", math_ceil, METH_O, math_ceil_doc}, -#if defined(MS_WINDOWS) || defined(HAVE_COPYSIGN) +#ifdef HAVE_COPYSIGN {"copysign", math_copysign, METH_VARARGS, math_copysign_doc}, #endif {"cos", math_cos, METH_O, math_cos_doc}, From python-checkins at python.org Fri Jan 4 03:03:25 2008 From: python-checkins at python.org (christian.heimes) Date: Fri, 4 Jan 2008 03:03:25 +0100 (CET) Subject: [Python-checkins] r59695 - python/trunk/Doc/whatsnew/2.6.rst Message-ID: <20080104020325.DEE1C1E4006@bag.python.org> Author: christian.heimes Date: Fri Jan 4 03:03:25 2008 New Revision: 59695 Modified: python/trunk/Doc/whatsnew/2.6.rst Log: Filled in some XXX comments Modified: python/trunk/Doc/whatsnew/2.6.rst ============================================================================== --- python/trunk/Doc/whatsnew/2.6.rst (original) +++ python/trunk/Doc/whatsnew/2.6.rst Fri Jan 4 03:03:25 2008 @@ -556,7 +556,7 @@ will now turn the strings ``+nan`` and ``-nan`` into the corresponding IEEE 754 Not a Number values, and ``+inf`` and ``-inf`` into positive or negative infinity. This works on any platform with - IEEE 754 semantics. (Contributed by XXX.) + IEEE 754 semantics. (Contributed by Christian Heimes.) .. Patch 1635. @@ -1063,20 +1063,21 @@ ``"mant_dig"`` (number of digits in the mantissa), ``"epsilon"`` (smallest difference between 1.0 and the next largest value representable), and several others. + (Contributed by Christian Heimes.) .. Issue 1534 * Python's C API now includes two functions for case-insensitive string comparisions, ``PyOS_stricmp(char*, char*)`` and ``PyOS_strnicmp(char*, char*, Py_ssize_t)``. - (Contributed by XXX.) + (Contributed by Christian Heimes.) .. Issue 1635 * Some macros were renamed. :cmacro:`Py_Size()` became :cmacro:`Py_SIZE()`, :cmacro:`Py_Type()` became :cmacro:`Py_TYPE()`, and :cmacro:`Py_Refcnt()` became :cmacro:`Py_REFCNT()`. Macros for backward - compatibility are still available. + compatibility are still available for Python 2.6. .. Issue 1629: XXX why was this done? From python-checkins at python.org Fri Jan 4 03:04:16 2008 From: python-checkins at python.org (amaury.forgeotdarc) Date: Fri, 4 Jan 2008 03:04:16 +0100 (CET) Subject: [Python-checkins] r59696 - in python/trunk: Misc/NEWS Python/dynload_win.c Message-ID: <20080104020416.075AF1E4011@bag.python.org> Author: amaury.forgeotdarc Date: Fri Jan 4 03:04:15 2008 New Revision: 59696 Modified: python/trunk/Misc/NEWS python/trunk/Python/dynload_win.c Log: Partial port of r59682 from py3k. On Windows, when import fails to load a dll module, the message says "error code 193" instead of a more informative text. It turns out that FormatMessage needs additional parameters for some error codes. For example: 193 means "%1 is not a valid Win32 application". Since it is impossible to know which parameter to pass, we use FORMAT_MESSAGE_IGNORE_INSERTS to get the raw message, which is still better than the number. Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Fri Jan 4 03:04:15 2008 @@ -12,6 +12,10 @@ Core and builtins ----------------- +- Improve some exception messages when Windows fails to load an extension + module. Now we get for example '%1 is not a valid Win32 application' instead + of 'error code 193'. + - Bug #1481296: Fixed long(float('nan'))!=0L. - Issue #1640: Added math.isinf(x), math.isnan(x) and math.copysign(x, y) Modified: python/trunk/Python/dynload_win.c ============================================================================== --- python/trunk/Python/dynload_win.c (original) +++ python/trunk/Python/dynload_win.c Fri Jan 4 03:04:15 2008 @@ -194,7 +194,8 @@ errorCode = GetLastError(); theLength = FormatMessage( - FORMAT_MESSAGE_FROM_SYSTEM, /* flags */ + FORMAT_MESSAGE_FROM_SYSTEM | + FORMAT_MESSAGE_IGNORE_INSERTS, /* flags */ NULL, /* message source */ errorCode, /* the message (error) ID */ 0, /* default language environment */ From python-checkins at python.org Fri Jan 4 03:21:40 2008 From: python-checkins at python.org (andrew.kuchling) Date: Fri, 4 Jan 2008 03:21:40 +0100 (CET) Subject: [Python-checkins] r59697 - peps/trunk/pep-3119.txt Message-ID: <20080104022140.73FD61E4006@bag.python.org> Author: andrew.kuchling Date: Fri Jan 4 03:21:40 2008 New Revision: 59697 Modified: peps/trunk/pep-3119.txt Log: Typo fix Modified: peps/trunk/pep-3119.txt ============================================================================== --- peps/trunk/pep-3119.txt (original) +++ peps/trunk/pep-3119.txt Fri Jan 4 03:21:40 2008 @@ -242,7 +242,7 @@ The ``ABCMeta`` class overrides ``__instancecheck__`` and ``__subclasscheck__`` and defines a ``register`` method. The -``register`` method takes one argument, which much be a class; after +``register`` method takes one argument, which must be a class; after the call ``B.register(C)``, the call ``issubclass(C, B)`` will return True, by virtue of ``B.__subclasscheck__(C)`` returning True. Also, ``isinstance(x, B)`` is equivalent to ``issubclass(x.__class__, From python-checkins at python.org Fri Jan 4 03:26:01 2008 From: python-checkins at python.org (andrew.kuchling) Date: Fri, 4 Jan 2008 03:26:01 +0100 (CET) Subject: [Python-checkins] r59698 - python/trunk/Misc/NEWS Message-ID: <20080104022601.382331E4006@bag.python.org> Author: andrew.kuchling Date: Fri Jan 4 03:26:00 2008 New Revision: 59698 Modified: python/trunk/Misc/NEWS Log: Typo fix Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Fri Jan 4 03:26:00 2008 @@ -1239,7 +1239,7 @@ - Issue #1629: Renamed Py_Size, Py_Type and Py_Refcnt to Py_SIZE, Py_TYPE and Py_REFCNT. -- Added case insensitive comparsion methods ``PyOS_stricmp(char*, char*)`` +- Added case insensitive comparison methods ``PyOS_stricmp(char*, char*)`` and ``PyOS_strnicmp(char*, char*, Py_ssize_t)``. - Bug #1542693: remove semi-colon at end of PyImport_ImportModuleEx macro From python-checkins at python.org Fri Jan 4 03:31:41 2008 From: python-checkins at python.org (andrew.kuchling) Date: Fri, 4 Jan 2008 03:31:41 +0100 (CET) Subject: [Python-checkins] r59699 - python/trunk/Doc/whatsnew/2.6.rst Message-ID: <20080104023141.7C9EC1E4006@bag.python.org> Author: andrew.kuchling Date: Fri Jan 4 03:31:40 2008 New Revision: 59699 Modified: python/trunk/Doc/whatsnew/2.6.rst Log: Add math items; other edits Modified: python/trunk/Doc/whatsnew/2.6.rst ============================================================================== --- python/trunk/Doc/whatsnew/2.6.rst (original) +++ python/trunk/Doc/whatsnew/2.6.rst Fri Jan 4 03:31:40 2008 @@ -483,6 +483,32 @@ XXX +How to identify a file object? + +ABCs are a collection of classes describing various interfaces. +Classes can derive from an ABC to indicate they support that ABC's +interface. Concrete classes should obey the semantics specified by +an ABC, but Python can't check this; it's up to the implementor. + +A metaclass lets you declare that an existing class or type +derives from a particular ABC. You can even + +class AppendableSequence: + __metaclass__ = ABCMeta + +AppendableSequence.register(list) +assert issubclass(list, AppendableSequence) +assert isinstance([], AppendableSequence) + + at abstractmethod decorator -- you can't instantiate classes w/ +an abstract method. + + at abstractproperty decorator + at abstractproperty +def readonly(self): + return self._x + + .. seealso:: :pep:`3119` - Introducing Abstract Base Classes @@ -554,12 +580,22 @@ * More floating-point features were also added. The :func:`float` function will now turn the strings ``+nan`` and ``-nan`` into the corresponding - IEEE 754 Not a Number values, and ``+inf`` and ``-inf`` into + IEEE 754 Not A Number values, and ``+inf`` and ``-inf`` into positive or negative infinity. This works on any platform with IEEE 754 semantics. (Contributed by Christian Heimes.) .. Patch 1635. + Other functions in the :mod:`math` module, :func:`isinf` and + :func:`isnan`, return true if their floating-point argument is + infinite or Not A Number. + .. Patch 1640 + The ``math.copysign(x, y)`` function + copies the sign bit of an IEEE 754 number, returning the absolute + value of *x* combined with the sign bit of *y*. For example, + ``math.copysign(1, -0.0)`` returns -1.0. (Contributed by Christian + Heimes.) + * Changes to the :class:`Exception` interface as dictated by :pep:`352` continue to be made. For 2.6, the :attr:`message` attribute is being deprecated in favor of the @@ -612,6 +648,10 @@ Optimizations ------------- +* All of the functions in the :mod:`struct` module have been rewritten in + C, thanks to work at the Need For Speed sprint. + (Contributed by Raymond Hettinger.) + * Internally, a bit is now set in type objects to indicate some of the standard built-in types. This speeds up checking if an object is a subclass of one of these types. (Contributed by Neal Norwitz.) @@ -1074,12 +1114,13 @@ .. Issue 1635 -* Some macros were renamed. :cmacro:`Py_Size()` became :cmacro:`Py_SIZE()`, +* Some macros were renamed to make it clearer that they are macros, + not functions. :cmacro:`Py_Size()` became :cmacro:`Py_SIZE()`, :cmacro:`Py_Type()` became :cmacro:`Py_TYPE()`, and :cmacro:`Py_Refcnt()` became :cmacro:`Py_REFCNT()`. Macros for backward compatibility are still available for Python 2.6. - .. Issue 1629: XXX why was this done? + .. Issue 1629 .. ====================================================================== From python-checkins at python.org Fri Jan 4 03:46:19 2008 From: python-checkins at python.org (christian.heimes) Date: Fri, 4 Jan 2008 03:46:19 +0100 (CET) Subject: [Python-checkins] r59700 - python/trunk/Lib/test/regrtest.py Message-ID: <20080104024619.A89AA1E4006@bag.python.org> Author: christian.heimes Date: Fri Jan 4 03:46:19 2008 New Revision: 59700 Modified: python/trunk/Lib/test/regrtest.py Log: Fixed refleak tests for _struct changes Modified: python/trunk/Lib/test/regrtest.py ============================================================================== --- python/trunk/Lib/test/regrtest.py (original) +++ python/trunk/Lib/test/regrtest.py Fri Jan 4 03:46:19 2008 @@ -728,7 +728,6 @@ dircache.reset() linecache.clearcache() mimetypes._default_mime_types() - struct._cache.clear() filecmp._cache.clear() doctest.master = None From python-checkins at python.org Fri Jan 4 03:54:43 2008 From: python-checkins at python.org (christian.heimes) Date: Fri, 4 Jan 2008 03:54:43 +0100 (CET) Subject: [Python-checkins] r59701 - in python/trunk: Lib/struct.py Lib/test/regrtest.py Modules/_struct.c Message-ID: <20080104025443.3CF651E4006@bag.python.org> Author: christian.heimes Date: Fri Jan 4 03:54:42 2008 New Revision: 59701 Modified: python/trunk/Lib/struct.py python/trunk/Lib/test/regrtest.py python/trunk/Modules/_struct.c Log: Added _struct._clearcache() for regression tests Modified: python/trunk/Lib/struct.py ============================================================================== --- python/trunk/Lib/struct.py (original) +++ python/trunk/Lib/struct.py Fri Jan 4 03:54:42 2008 @@ -1 +1,2 @@ from _struct import * +from _struct import _clearcache Modified: python/trunk/Lib/test/regrtest.py ============================================================================== --- python/trunk/Lib/test/regrtest.py (original) +++ python/trunk/Lib/test/regrtest.py Fri Jan 4 03:54:42 2008 @@ -729,6 +729,7 @@ linecache.clearcache() mimetypes._default_mime_types() filecmp._cache.clear() + struct._clearcache() doctest.master = None # Collect cyclic trash. Modified: python/trunk/Modules/_struct.c ============================================================================== --- python/trunk/Modules/_struct.c (original) +++ python/trunk/Modules/_struct.c Fri Jan 4 03:54:42 2008 @@ -1851,11 +1851,11 @@ /* ---- Standalone functions ---- */ #define MAXCACHE 100 +static PyObject *cache = NULL; static PyObject * cache_struct(PyObject *fmt) { - static PyObject *cache = NULL; PyObject * s_object; if (cache == NULL) { @@ -1881,6 +1881,17 @@ return s_object; } +PyDoc_STRVAR(clearcache_doc, +"Clear the internal cache."); + +static PyObject * +clearcache(PyObject *self) +{ + if (cache != NULL) + PyDict_Clear(cache); + Py_RETURN_NONE; +} + PyDoc_STRVAR(calcsize_doc, "Return size of C struct described by format string fmt."); @@ -2006,6 +2017,7 @@ } static struct PyMethodDef module_functions[] = { + {"_clearcache", (PyCFunction)clearcache, METH_NOARGS, clearcache_doc}, {"calcsize", calcsize, METH_O, calcsize_doc}, {"pack", pack, METH_VARARGS, pack_doc}, {"pack_into", pack_into, METH_VARARGS, pack_into_doc}, From python-checkins at python.org Fri Jan 4 04:15:05 2008 From: python-checkins at python.org (christian.heimes) Date: Fri, 4 Jan 2008 04:15:05 +0100 (CET) Subject: [Python-checkins] r59704 - python/trunk/Python/dynload_win.c Message-ID: <20080104031505.5454C1E4006@bag.python.org> Author: christian.heimes Date: Fri Jan 4 04:15:05 2008 New Revision: 59704 Modified: python/trunk/Python/dynload_win.c Log: Moved include "Python.h" in front of other imports to silence a warning. Modified: python/trunk/Python/dynload_win.c ============================================================================== --- python/trunk/Python/dynload_win.c (original) +++ python/trunk/Python/dynload_win.c Fri Jan 4 04:15:05 2008 @@ -1,12 +1,13 @@ /* Support for dynamic loading of extension modules */ +#include "Python.h" + #ifdef HAVE_DIRECT_H #include #endif #include -#include "Python.h" #include "importdl.h" #include From buildbot at python.org Fri Jan 4 04:20:15 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 04 Jan 2008 03:20:15 +0000 Subject: [Python-checkins] buildbot failure in amd64 XP 3.0 Message-ID: <20080104032015.D06181E4006@bag.python.org> The Buildbot has detected a new failure of amd64 XP 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/amd64%20XP%203.0/builds/442 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: heller-windows-amd64 Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: amaury.forgeotdarc,christian.heimes BUILD FAILED: failed failed slave lost sincerely, -The Buildbot From python-checkins at python.org Fri Jan 4 04:22:54 2008 From: python-checkins at python.org (raymond.hettinger) Date: Fri, 4 Jan 2008 04:22:54 +0100 (CET) Subject: [Python-checkins] r59706 - in python/trunk: Doc/library/collections.rst Lib/collections.py Lib/test/test_collections.py Message-ID: <20080104032254.3B3F01E4006@bag.python.org> Author: raymond.hettinger Date: Fri Jan 4 04:22:53 2008 New Revision: 59706 Modified: python/trunk/Doc/library/collections.rst python/trunk/Lib/collections.py python/trunk/Lib/test/test_collections.py Log: Minor fix-ups to named tuples: * Make the _replace() method respect subclassing. * Using property() to make _fields read-only wasn't a good idea. It caused len(Point._fields) to fail. * Add note to _cast() about length checking and alternative with the star-operator. Modified: python/trunk/Doc/library/collections.rst ============================================================================== --- python/trunk/Doc/library/collections.rst (original) +++ python/trunk/Doc/library/collections.rst Fri Jan 4 04:22:53 2008 @@ -388,6 +388,8 @@ __slots__ = () + _fields = ('x', 'y') + def __new__(cls, x, y): return tuple.__new__(cls, (x, y)) @@ -402,11 +404,7 @@ def _replace(self, **kwds): 'Return a new Point object replacing specified fields with new values' - return Point._cast(map(kwds.get, ('x', 'y'), self)) - - @property - def _fields(self): - return ('x', 'y') + return self.__class__._cast(map(kwds.get, ('x', 'y'), self)) x = property(itemgetter(0)) y = property(itemgetter(1)) @@ -439,17 +437,22 @@ print emp.name, emp.title In addition to the methods inherited from tuples, named tuples support -three additonal methods and a read-only attribute. +three additonal methods and one attribute. .. method:: namedtuple._cast(iterable) - Class method returning a new instance taking the positional arguments from the *iterable*. - Useful for casting existing sequences and iterables to named tuples: + Class method returning a new instance taking the positional arguments from the + *iterable*. Useful for casting existing sequences and iterables to named tuples. + + This fast constructor does not check the length of the inputs. To achieve the + same effect with length checking, use the star-operator instead. :: >>> t = [11, 22] - >>> Point._cast(t) + >>> Point._cast(t) # fast conversion + Point(x=11, y=22) + >>> Point(*t) # slow conversion with length checking Point(x=11, y=22) .. method:: somenamedtuple._asdict() @@ -476,7 +479,7 @@ .. attribute:: somenamedtuple._fields - Return a tuple of strings listing the field names. This is useful for introspection + Tuple of strings listing the field names. This is useful for introspection and for creating new named tuple types from existing named tuples. :: Modified: python/trunk/Lib/collections.py ============================================================================== --- python/trunk/Lib/collections.py (original) +++ python/trunk/Lib/collections.py Fri Jan 4 04:22:53 2008 @@ -60,6 +60,7 @@ template = '''class %(typename)s(tuple): '%(typename)s(%(argtxt)s)' \n __slots__ = () \n + _fields = %(field_names)r \n def __new__(cls, %(argtxt)s): return tuple.__new__(cls, (%(argtxt)s)) \n _cast = classmethod(tuple.__new__) \n @@ -70,10 +71,7 @@ return {%(dicttxt)s} \n def _replace(self, **kwds): 'Return a new %(typename)s object replacing specified fields with new values' - return %(typename)s._cast(map(kwds.get, %(field_names)r, self)) \n - @property - def _fields(self): - return %(field_names)r \n\n''' % locals() + return self.__class__._cast(map(kwds.get, %(field_names)r, self)) \n\n''' % locals() for i, name in enumerate(field_names): template += ' %s = property(itemgetter(%d))\n' % (name, i) if verbose: Modified: python/trunk/Lib/test/test_collections.py ============================================================================== --- python/trunk/Lib/test/test_collections.py (original) +++ python/trunk/Lib/test/test_collections.py Fri Jan 4 04:22:53 2008 @@ -17,6 +17,7 @@ self.assertEqual(Point.__slots__, ()) self.assertEqual(Point.__module__, __name__) self.assertEqual(Point.__getitem__, tuple.__getitem__) + self.assertEqual(Point._fields, ('x', 'y')) self.assertRaises(ValueError, namedtuple, 'abc%', 'efg ghi') # type has non-alpha char self.assertRaises(ValueError, namedtuple, 'class', 'efg ghi') # type has keyword @@ -51,14 +52,6 @@ self.assertEqual(p._replace(x=1), (1, 22)) # test _replace method self.assertEqual(p._asdict(), dict(x=11, y=22)) # test _asdict method - # Verify that _fields is read-only - try: - p._fields = ('F1' ,'F2') - except AttributeError: - pass - else: - self.fail('The _fields attribute needs to be read-only') - # verify that field string can have commas Point = namedtuple('Point', 'x, y') p = Point(x=11, y=22) From buildbot at python.org Fri Jan 4 06:10:56 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 04 Jan 2008 05:10:56 +0000 Subject: [Python-checkins] buildbot failure in PPC64 Debian trunk Message-ID: <20080104051057.13FCC1E4006@bag.python.org> The Buildbot has detected a new failure of PPC64 Debian trunk. Full details are available at: http://www.python.org/dev/buildbot/all/PPC64%20Debian%20trunk/builds/22 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: amaury.forgeotdarc,andrew.kuchling,christian.heimes,raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_xmlrpc ====================================================================== ERROR: test_fail_no_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/test/test_xmlrpc.py", line 560, in test_fail_no_info p.pow(6,8) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/xmlrpclib.py", line 1157, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/xmlrpclib.py", line 1447, in __request verbose=self.__verbose File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/xmlrpclib.py", line 1195, in request errcode, errmsg, headers = h.getreply() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 1006, in getreply response = self._conn.getresponse() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 932, in getresponse response.begin() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 415, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 271, in readheaders line = self.fp.readline() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/socket.py", line 351, in readline data = recv(1) error: [Errno 104] Connection reset by peer ====================================================================== ERROR: test_fail_with_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/test/test_xmlrpc.py", line 580, in test_fail_with_info p.pow(6,8) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/xmlrpclib.py", line 1157, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/xmlrpclib.py", line 1447, in __request verbose=self.__verbose File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/xmlrpclib.py", line 1195, in request errcode, errmsg, headers = h.getreply() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 1006, in getreply response = self._conn.getresponse() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 932, in getresponse response.begin() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 415, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 271, in readheaders line = self.fp.readline() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/socket.py", line 351, in readline data = recv(1) error: [Errno 104] Connection reset by peer make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Fri Jan 4 06:29:45 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 04 Jan 2008 05:29:45 +0000 Subject: [Python-checkins] buildbot failure in sparc solaris10 gcc trunk Message-ID: <20080104052945.3DBF81E4006@bag.python.org> The Buildbot has detected a new failure of sparc solaris10 gcc trunk. Full details are available at: http://www.python.org/dev/buildbot/all/sparc%20solaris10%20gcc%20trunk/builds/2537 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-sun Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed svn sincerely, -The Buildbot From sales at westcoastjuniper.com Fri Jan 4 01:25:49 2008 From: sales at westcoastjuniper.com (West Coast Juniper Distributing) Date: Fri, 4 Jan 2008 00:25:49 GMT Subject: [Python-checkins] Eco-Friendly Sale Message-ID: An HTML attachment was scrubbed... URL: http://mail.python.org/pipermail/python-checkins/attachments/20080104/5961fc4c/attachment.htm From buildbot at python.org Fri Jan 4 06:43:27 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 04 Jan 2008 05:43:27 +0000 Subject: [Python-checkins] buildbot failure in ppc Debian unstable trunk Message-ID: <20080104054328.4834C1E4006@bag.python.org> The Buildbot has detected a new failure of ppc Debian unstable trunk. Full details are available at: http://www.python.org/dev/buildbot/all/ppc%20Debian%20unstable%20trunk/builds/516 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: amaury.forgeotdarc,andrew.kuchling,christian.heimes,raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_socket_ssl ====================================================================== ERROR: test_978833 (test.test_socket_ssl.BasicTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_socket_ssl.py", line 123, in test_978833 raise test_support.TestFailed("Failed to close socket") File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/contextlib.py", line 33, in __exit__ self.gen.throw(type, value, traceback) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/contextlib.py", line 117, in nested yield vars File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_socket_ssl.py", line 113, in test_978833 s.connect(("svn.python.org", 443)) File "", line 1, in connect error: [Errno 111] Connection refused make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Fri Jan 4 06:57:42 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 04 Jan 2008 05:57:42 +0000 Subject: [Python-checkins] buildbot failure in g4 osx.4 3.0 Message-ID: <20080104055743.0ADD51E4006@bag.python.org> The Buildbot has detected a new failure of g4 osx.4 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/g4%20osx.4%203.0/builds/406 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: psf-g4 Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: amaury.forgeotdarc,christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/threading.py", line 485, in _bootstrap_inner self.run() File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/threading.py", line 445, in run self._target(*self._args, **self._kwargs) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/bsddb/test/test_thread.py", line 80, in writerThread self._writerThread(*args, **kwargs) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/bsddb/test/test_thread.py", line 254, in _writerThread self.assertEqual(data, self.makeData(key)) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/unittest.py", line 325, in failUnlessEqual raise self.failureException(msg or '%r != %r' % (first, second)) AssertionError: None != b'1087-1087-1087-1087-1087' Traceback (most recent call last): File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/threading.py", line 485, in _bootstrap_inner self.run() File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/threading.py", line 445, in run self._target(*self._args, **self._kwargs) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/bsddb/test/test_thread.py", line 80, in writerThread self._writerThread(*args, **kwargs) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/bsddb/test/test_thread.py", line 269, in _writerThread self.assertEqual(data, self.makeData(key)) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/unittest.py", line 325, in failUnlessEqual raise self.failureException(msg or '%r != %r' % (first, second)) AssertionError: None != b'0004-0004-0004-0004-0004' Traceback (most recent call last): File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/threading.py", line 485, in _bootstrap_inner self.run() File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/threading.py", line 445, in run self._target(*self._args, **self._kwargs) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/bsddb/test/test_thread.py", line 80, in writerThread self._writerThread(*args, **kwargs) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/bsddb/test/test_thread.py", line 269, in _writerThread self.assertEqual(data, self.makeData(key)) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/unittest.py", line 325, in failUnlessEqual raise self.failureException(msg or '%r != %r' % (first, second)) AssertionError: None != b'2002-2002-2002-2002-2002' 1 test failed: test_plistlib ====================================================================== ERROR: test_appleformatting (test.test_plistlib.TestPlistlib) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/test/test_plistlib.py", line 141, in test_appleformatting data = plistlib.writePlistToBytes(pl) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/plat-mac/plistlib.py", line 109, in writePlistToBytes writePlist(rootObject, f) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/plat-mac/plistlib.py", line 93, in writePlist writer.writeValue(rootObject) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/plat-mac/plistlib.py", line 245, in writeValue elif isinstance(value, (int, long)): NameError: global name 'long' is not defined ====================================================================== ERROR: test_bytes (test.test_plistlib.TestPlistlib) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/test/test_plistlib.py", line 133, in test_bytes data = plistlib.writePlistToBytes(pl) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/plat-mac/plistlib.py", line 109, in writePlistToBytes writePlist(rootObject, f) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/plat-mac/plistlib.py", line 93, in writePlist writer.writeValue(rootObject) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/plat-mac/plistlib.py", line 245, in writeValue elif isinstance(value, (int, long)): NameError: global name 'long' is not defined ====================================================================== ERROR: test_bytesio (test.test_plistlib.TestPlistlib) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/test/test_plistlib.py", line 155, in test_bytesio plistlib.writePlist(pl, b) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/plat-mac/plistlib.py", line 93, in writePlist writer.writeValue(rootObject) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/plat-mac/plistlib.py", line 245, in writeValue elif isinstance(value, (int, long)): NameError: global name 'long' is not defined ====================================================================== ERROR: test_io (test.test_plistlib.TestPlistlib) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/test/test_plistlib.py", line 127, in test_io plistlib.writePlist(pl, test_support.TESTFN) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/plat-mac/plistlib.py", line 93, in writePlist writer.writeValue(rootObject) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/plat-mac/plistlib.py", line 245, in writeValue elif isinstance(value, (int, long)): NameError: global name 'long' is not defined ====================================================================== ERROR: test_nondictroot (test.test_plistlib.TestPlistlib) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/test/test_plistlib.py", line 175, in test_nondictroot result2 = plistlib.readPlistFromBytes(plistlib.writePlistToBytes(test2)) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/plat-mac/plistlib.py", line 109, in writePlistToBytes writePlist(rootObject, f) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/plat-mac/plistlib.py", line 93, in writePlist writer.writeValue(rootObject) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/plat-mac/plistlib.py", line 245, in writeValue elif isinstance(value, (int, long)): NameError: global name 'long' is not defined make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Fri Jan 4 06:58:02 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 04 Jan 2008 05:58:02 +0000 Subject: [Python-checkins] buildbot failure in g4 osx.4 trunk Message-ID: <20080104055802.C81C71E4006@bag.python.org> The Buildbot has detected a new failure of g4 osx.4 trunk. Full details are available at: http://www.python.org/dev/buildbot/all/g4%20osx.4%20trunk/builds/2538 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: psf-g4 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed svn sincerely, -The Buildbot From buildbot at python.org Fri Jan 4 07:49:39 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 04 Jan 2008 06:49:39 +0000 Subject: [Python-checkins] buildbot failure in ia64 Ubuntu trunk Message-ID: <20080104064939.BD9DE1E4006@bag.python.org> The Buildbot has detected a new failure of ia64 Ubuntu trunk. Full details are available at: http://www.python.org/dev/buildbot/all/ia64%20Ubuntu%20trunk/builds/1211 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ia64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: andrew.kuchling,christian.heimes,raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: 2 tests failed: test_socket_ssl test_ssl ====================================================================== ERROR: test_978833 (test.test_socket_ssl.BasicTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ia64/build/Lib/test/test_socket_ssl.py", line 123, in test_978833 raise test_support.TestFailed("Failed to close socket") File "/home/pybot/buildarea/trunk.klose-debian-ia64/build/Lib/contextlib.py", line 33, in __exit__ self.gen.throw(type, value, traceback) File "/home/pybot/buildarea/trunk.klose-debian-ia64/build/Lib/contextlib.py", line 117, in nested yield vars File "/home/pybot/buildarea/trunk.klose-debian-ia64/build/Lib/test/test_socket_ssl.py", line 113, in test_978833 s.connect(("svn.python.org", 443)) File "", line 1, in connect error: [Errno 110] Connection timed out ====================================================================== ERROR: testSSLconnect (test.test_ssl.BasicTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ia64/build/Lib/test/test_ssl.py", line 43, in testSSLconnect s.connect(("svn.python.org", 443)) File "/home/pybot/buildarea/trunk.klose-debian-ia64/build/Lib/ssl.py", line 201, in connect socket.connect(self, addr) File "", line 1, in connect error: [Errno 110] Connection timed out ====================================================================== ERROR: testConnect (test.test_ssl.NetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ia64/build/Lib/test/test_ssl.py", line 107, in testConnect s.connect(("svn.python.org", 443)) File "/home/pybot/buildarea/trunk.klose-debian-ia64/build/Lib/ssl.py", line 201, in connect socket.connect(self, addr) File "", line 1, in connect error: [Errno 110] Connection timed out ====================================================================== ERROR: testFetchServerCert (test.test_ssl.NetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ia64/build/Lib/test/test_ssl.py", line 136, in testFetchServerCert pem = ssl.get_server_certificate(("svn.python.org", 443)) File "/home/pybot/buildarea/trunk.klose-debian-ia64/build/Lib/ssl.py", line 526, in get_server_certificate s.connect(addr) File "/home/pybot/buildarea/trunk.klose-debian-ia64/build/Lib/ssl.py", line 201, in connect socket.connect(self, addr) File "", line 1, in connect error: [Errno 110] Connection timed out make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Fri Jan 4 09:01:24 2008 From: python-checkins at python.org (jeffrey.yasskin) Date: Fri, 4 Jan 2008 09:01:24 +0100 (CET) Subject: [Python-checkins] r59707 - in python/trunk: Lib/test/test_math.py Objects/intobject.c Objects/longobject.c Message-ID: <20080104080124.5B8221E4006@bag.python.org> Author: jeffrey.yasskin Date: Fri Jan 4 09:01:23 2008 New Revision: 59707 Modified: python/trunk/Lib/test/test_math.py python/trunk/Objects/intobject.c python/trunk/Objects/longobject.c Log: Make math.{floor,ceil}({int,long}) return float again for backwards compatibility after r59671 made them return integral types. Modified: python/trunk/Lib/test/test_math.py ============================================================================== --- python/trunk/Lib/test/test_math.py (original) +++ python/trunk/Lib/test/test_math.py Fri Jan 4 09:01:23 2008 @@ -51,6 +51,10 @@ def testCeil(self): self.assertRaises(TypeError, math.ceil) + # These types will be int in py3k. + self.assertEquals(float, type(math.ceil(1))) + self.assertEquals(float, type(math.ceil(1L))) + self.assertEquals(float, type(math.ceil(1.0))) self.ftest('ceil(0.5)', math.ceil(0.5), 1) self.ftest('ceil(1.0)', math.ceil(1.0), 1) self.ftest('ceil(1.5)', math.ceil(1.5), 2) @@ -103,6 +107,10 @@ def testFloor(self): self.assertRaises(TypeError, math.floor) + # These types will be int in py3k. + self.assertEquals(float, type(math.floor(1))) + self.assertEquals(float, type(math.floor(1L))) + self.assertEquals(float, type(math.floor(1.0))) self.ftest('floor(0.5)', math.floor(0.5), 0) self.ftest('floor(1.0)', math.floor(1.0), 1) self.ftest('floor(1.5)', math.floor(1.5), 1) Modified: python/trunk/Objects/intobject.c ============================================================================== --- python/trunk/Objects/intobject.c (original) +++ python/trunk/Objects/intobject.c Fri Jan 4 09:01:23 2008 @@ -1086,9 +1086,9 @@ "Returns self, the complex conjugate of any int."}, {"__trunc__", (PyCFunction)int_int, METH_NOARGS, "Truncating an Integral returns itself."}, - {"__floor__", (PyCFunction)int_int, METH_NOARGS, + {"__floor__", (PyCFunction)int_float, METH_NOARGS, "Flooring an Integral returns itself."}, - {"__ceil__", (PyCFunction)int_int, METH_NOARGS, + {"__ceil__", (PyCFunction)int_float, METH_NOARGS, "Ceiling of an Integral returns itself."}, {"__round__", (PyCFunction)int_round, METH_VARARGS, "Rounding an Integral returns itself.\n" Modified: python/trunk/Objects/longobject.c ============================================================================== --- python/trunk/Objects/longobject.c (original) +++ python/trunk/Objects/longobject.c Fri Jan 4 09:01:23 2008 @@ -3402,9 +3402,9 @@ "Returns self, the complex conjugate of any long."}, {"__trunc__", (PyCFunction)long_long, METH_NOARGS, "Truncating an Integral returns itself."}, - {"__floor__", (PyCFunction)long_long, METH_NOARGS, + {"__floor__", (PyCFunction)long_float, METH_NOARGS, "Flooring an Integral returns itself."}, - {"__ceil__", (PyCFunction)long_long, METH_NOARGS, + {"__ceil__", (PyCFunction)long_float, METH_NOARGS, "Ceiling of an Integral returns itself."}, {"__round__", (PyCFunction)long_round, METH_VARARGS, "Rounding an Integral returns itself.\n" From buildbot at python.org Fri Jan 4 09:06:28 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 04 Jan 2008 08:06:28 +0000 Subject: [Python-checkins] buildbot failure in x86 mvlgcc trunk Message-ID: <20080104080628.A1E911E4010@bag.python.org> The Buildbot has detected a new failure of x86 mvlgcc trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20mvlgcc%20trunk/builds/1118 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-linux Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: jeffrey.yasskin BUILD FAILED: failed svn sincerely, -The Buildbot From buildbot at python.org Fri Jan 4 09:06:30 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 04 Jan 2008 08:06:30 +0000 Subject: [Python-checkins] buildbot failure in x86 gentoo trunk Message-ID: <20080104080631.0843E1E4016@bag.python.org> The Buildbot has detected a new failure of x86 gentoo trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20gentoo%20trunk/builds/2802 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-x86 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: jeffrey.yasskin BUILD FAILED: failed svn sincerely, -The Buildbot From nnorwitz at gmail.com Fri Jan 4 10:00:06 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Fri, 4 Jan 2008 04:00:06 -0500 Subject: [Python-checkins] Python Regression Test Failures doc (1) Message-ID: <20080104090006.GA757@python.psfb.org> svn update tools/sphinx svn: PROPFIND request failed on '/projects/doctools/trunk/sphinx' svn: PROPFIND of '/projects/doctools/trunk/sphinx': could not connect to server (http://svn.python.org) make: *** [update] Error 1 From python-checkins at python.org Fri Jan 4 14:21:08 2008 From: python-checkins at python.org (christian.heimes) Date: Fri, 4 Jan 2008 14:21:08 +0100 (CET) Subject: [Python-checkins] r59709 - in python/trunk: Lib/posixpath.py Misc/NEWS Message-ID: <20080104132108.46EDA1E400E@bag.python.org> Author: christian.heimes Date: Fri Jan 4 14:21:07 2008 New Revision: 59709 Modified: python/trunk/Lib/posixpath.py python/trunk/Misc/NEWS Log: Bug #1713: posixpath.ismount() claims symlink to a mountpoint is a mountpoint. Modified: python/trunk/Lib/posixpath.py ============================================================================== --- python/trunk/Lib/posixpath.py (original) +++ python/trunk/Lib/posixpath.py Fri Jan 4 14:21:07 2008 @@ -178,8 +178,8 @@ def ismount(path): """Test whether a path is a mount point""" try: - s1 = os.stat(path) - s2 = os.stat(join(path, '..')) + s1 = os.lstat(path) + s2 = os.lstat(join(path, '..')) except os.error: return False # It doesn't exist -- so not a mount point :-) dev1 = s1.st_dev Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Fri Jan 4 14:21:07 2008 @@ -342,6 +342,8 @@ Library ------- +- Bug #1713: posixpath.ismount() claims symlink to a mountpoint is a mountpoint. + - Bug #1687: Fxed plistlib.py restricts to Python int when writing - Issue #1700: Regular expression inline flags incorrectly handle certain From python-checkins at python.org Fri Jan 4 14:22:37 2008 From: python-checkins at python.org (christian.heimes) Date: Fri, 4 Jan 2008 14:22:37 +0100 (CET) Subject: [Python-checkins] r59710 - in python/branches/release25-maint: Lib/posixpath.py Misc/NEWS Message-ID: <20080104132237.7BC031E4020@bag.python.org> Author: christian.heimes Date: Fri Jan 4 14:22:36 2008 New Revision: 59710 Modified: python/branches/release25-maint/Lib/posixpath.py python/branches/release25-maint/Misc/NEWS Log: Bug #1713: posixpath.ismount() claims symlink to a mountpoint is a mountpoint. Modified: python/branches/release25-maint/Lib/posixpath.py ============================================================================== --- python/branches/release25-maint/Lib/posixpath.py (original) +++ python/branches/release25-maint/Lib/posixpath.py Fri Jan 4 14:22:36 2008 @@ -245,8 +245,8 @@ def ismount(path): """Test whether a path is a mount point""" try: - s1 = os.stat(path) - s2 = os.stat(join(path, '..')) + s1 = os.lstat(path) + s2 = os.lstat(join(path, '..')) except os.error: return False # It doesn't exist -- so not a mount point :-) dev1 = s1.st_dev Modified: python/branches/release25-maint/Misc/NEWS ============================================================================== --- python/branches/release25-maint/Misc/NEWS (original) +++ python/branches/release25-maint/Misc/NEWS Fri Jan 4 14:22:36 2008 @@ -53,6 +53,8 @@ Library ------- +- Bug #1713: posixpath.ismount() claims symlink to a mountpoint is a mountpoint. + - Issue #1700: Regular expression inline flags incorrectly handle certain unicode characters. From python-checkins at python.org Fri Jan 4 15:00:33 2008 From: python-checkins at python.org (lars.gustaebel) Date: Fri, 4 Jan 2008 15:00:33 +0100 (CET) Subject: [Python-checkins] r59712 - in python/trunk: Lib/tarfile.py Lib/test/test_tarfile.py Misc/NEWS Message-ID: <20080104140033.E00721E4021@bag.python.org> Author: lars.gustaebel Date: Fri Jan 4 15:00:33 2008 New Revision: 59712 Modified: python/trunk/Lib/tarfile.py python/trunk/Lib/test/test_tarfile.py python/trunk/Misc/NEWS Log: Issue #1735: TarFile.extractall() now correctly sets directory permissions and times. (will backport to 2.5) Modified: python/trunk/Lib/tarfile.py ============================================================================== --- python/trunk/Lib/tarfile.py (original) +++ python/trunk/Lib/tarfile.py Fri Jan 4 15:00:33 2008 @@ -2037,11 +2037,11 @@ # Set correct owner, mtime and filemode on directories. for tarinfo in directories: - path = os.path.join(path, tarinfo.name) + dirpath = os.path.join(path, tarinfo.name) try: - self.chown(tarinfo, path) - self.utime(tarinfo, path) - self.chmod(tarinfo, path) + self.chown(tarinfo, dirpath) + self.utime(tarinfo, dirpath) + self.chmod(tarinfo, dirpath) except ExtractError, e: if self.errorlevel > 1: raise Modified: python/trunk/Lib/test/test_tarfile.py ============================================================================== --- python/trunk/Lib/test/test_tarfile.py (original) +++ python/trunk/Lib/test/test_tarfile.py Fri Jan 4 15:00:33 2008 @@ -244,6 +244,23 @@ data = open(os.path.join(TEMPDIR, "ustar/symtype"), "rb").read() self.assertEqual(md5sum(data), md5_regtype) + def test_extractall(self): + # Test if extractall() correctly restores directory permissions + # and times (see issue1735). + if sys.platform == "win32": + # Win32 has no support for utime() on directories or + # fine grained permissions. + return + + tar = tarfile.open(tarname, encoding="iso8859-1") + directories = [t for t in tar if t.isdir()] + tar.extractall(TEMPDIR, directories) + for tarinfo in directories: + path = os.path.join(TEMPDIR, tarinfo.name) + self.assertEqual(tarinfo.mode & 0777, os.stat(path).st_mode & 0777) + self.assertEqual(tarinfo.mtime, os.path.getmtime(path)) + tar.close() + class StreamReadTest(ReadTest): Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Fri Jan 4 15:00:33 2008 @@ -342,6 +342,9 @@ Library ------- +- Issue #1735: TarFile.extractall() now correctly sets directory permissions + and times. + - Bug #1713: posixpath.ismount() claims symlink to a mountpoint is a mountpoint. - Bug #1687: Fxed plistlib.py restricts to Python int when writing From python-checkins at python.org Fri Jan 4 15:44:24 2008 From: python-checkins at python.org (lars.gustaebel) Date: Fri, 4 Jan 2008 15:44:24 +0100 (CET) Subject: [Python-checkins] r59713 - in python/branches/release25-maint: Lib/tarfile.py Lib/test/test_tarfile.py Misc/NEWS Message-ID: <20080104144424.5FBA61E4010@bag.python.org> Author: lars.gustaebel Date: Fri Jan 4 15:44:23 2008 New Revision: 59713 Modified: python/branches/release25-maint/Lib/tarfile.py python/branches/release25-maint/Lib/test/test_tarfile.py python/branches/release25-maint/Misc/NEWS Log: Issue #1735: TarFile.extractall() now correctly sets directory permissions and times. (backport from r59712) Modified: python/branches/release25-maint/Lib/tarfile.py ============================================================================== --- python/branches/release25-maint/Lib/tarfile.py (original) +++ python/branches/release25-maint/Lib/tarfile.py Fri Jan 4 15:44:23 2008 @@ -1525,11 +1525,11 @@ # Set correct owner, mtime and filemode on directories. for tarinfo in directories: - path = os.path.join(path, tarinfo.name) + dirpath = os.path.join(path, tarinfo.name) try: - self.chown(tarinfo, path) - self.utime(tarinfo, path) - self.chmod(tarinfo, path) + self.chown(tarinfo, dirpath) + self.utime(tarinfo, dirpath) + self.chmod(tarinfo, dirpath) except ExtractError, e: if self.errorlevel > 1: raise Modified: python/branches/release25-maint/Lib/test/test_tarfile.py ============================================================================== --- python/branches/release25-maint/Lib/test/test_tarfile.py (original) +++ python/branches/release25-maint/Lib/test/test_tarfile.py Fri Jan 4 15:44:23 2008 @@ -197,6 +197,34 @@ self.assert_(tarinfo.name.endswith("/")) self.assert_(not tarinfo.name[:-1].endswith("/")) + def test_extractall(self): + # Test if extractall() correctly restores directory permissions + # and times (see issue1735). + if sys.platform == "win32": + # Win32 has no support for utime() on directories or + # fine grained permissions. + return + + fobj = StringIO.StringIO() + tar = tarfile.open(fileobj=fobj, mode="w:") + for name in ("foo", "foo/bar"): + tarinfo = tarfile.TarInfo(name) + tarinfo.type = tarfile.DIRTYPE + tarinfo.mtime = 07606136617 + tarinfo.mode = 0755 + tar.addfile(tarinfo) + tar.close() + fobj.seek(0) + + TEMPDIR = os.path.join(dirname(), "extract-test") + tar = tarfile.open(fileobj=fobj) + tar.extractall(TEMPDIR) + for tarinfo in tar.getmembers(): + path = os.path.join(TEMPDIR, tarinfo.name) + self.assertEqual(tarinfo.mode, os.stat(path).st_mode & 0777) + self.assertEqual(tarinfo.mtime, os.path.getmtime(path)) + tar.close() + class ReadStreamTest(ReadTest): sep = "|" Modified: python/branches/release25-maint/Misc/NEWS ============================================================================== --- python/branches/release25-maint/Misc/NEWS (original) +++ python/branches/release25-maint/Misc/NEWS Fri Jan 4 15:44:23 2008 @@ -53,6 +53,9 @@ Library ------- +- Issue #1735: TarFile.extractall() now correctly sets directory permissions + and times. + - Bug #1713: posixpath.ismount() claims symlink to a mountpoint is a mountpoint. - Issue #1700: Regular expression inline flags incorrectly handle certain From python-checkins at python.org Fri Jan 4 15:47:18 2008 From: python-checkins at python.org (andrew.kuchling) Date: Fri, 4 Jan 2008 15:47:18 +0100 (CET) Subject: [Python-checkins] r59714 - python/trunk/README Message-ID: <20080104144718.0D4AF1E4016@bag.python.org> Author: andrew.kuchling Date: Fri Jan 4 15:47:17 2008 New Revision: 59714 Modified: python/trunk/README Log: Update links to bug/patch tracker Modified: python/trunk/README ============================================================================== --- python/trunk/README (original) +++ python/trunk/README Fri Jan 4 15:47:17 2008 @@ -124,20 +124,20 @@ ----------- To report or search for bugs, please use the Python Bug -Tracker at http://sourceforge.net/bugs/?group_id=5470. +Tracker at http://bugs.python.org. Patches and contributions ------------------------- To submit a patch or other contribution, please use the Python Patch -Manager at http://sourceforge.net/patch/?group_id=5470. Guidelines -for patch submission may be found at http://www.python.org/patches/. +Manager at http://bugs.python.org. Guidelines +for patch submission may be found at http://www.python.org/dev/patches/. If you have a proposal to change Python, it's best to submit a Python Enhancement Proposal (PEP) first. All current PEPs, as well as guidelines for submitting a new PEP, are listed at -http://www.python.org/peps/. +http://www.python.org/dev/peps/. Questions From python-checkins at python.org Fri Jan 4 15:47:43 2008 From: python-checkins at python.org (andrew.kuchling) Date: Fri, 4 Jan 2008 15:47:43 +0100 (CET) Subject: [Python-checkins] r59715 - python/branches/release25-maint/README Message-ID: <20080104144743.534C31E4028@bag.python.org> Author: andrew.kuchling Date: Fri Jan 4 15:47:42 2008 New Revision: 59715 Modified: python/branches/release25-maint/README Log: Update links to bug/patch tracker Modified: python/branches/release25-maint/README ============================================================================== --- python/branches/release25-maint/README (original) +++ python/branches/release25-maint/README Fri Jan 4 15:47:42 2008 @@ -124,20 +124,20 @@ ----------- To report or search for bugs, please use the Python Bug -Tracker at http://sourceforge.net/bugs/?group_id=5470. +Tracker at http://bugs.python.org. Patches and contributions ------------------------- To submit a patch or other contribution, please use the Python Patch -Manager at http://sourceforge.net/patch/?group_id=5470. Guidelines -for patch submission may be found at http://www.python.org/patches/. +Manager at http://bugs.python.org. Guidelines +for patch submission may be found at http://www.python.org/dev/patches/. If you have a proposal to change Python, it's best to submit a Python Enhancement Proposal (PEP) first. All current PEPs, as well as guidelines for submitting a new PEP, are listed at -http://www.python.org/peps/. +http://www.python.org/dev/peps/. Questions From buildbot at python.org Fri Jan 4 16:11:12 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 04 Jan 2008 15:11:12 +0000 Subject: [Python-checkins] buildbot failure in x86 XP-4 3.0 Message-ID: <20080104151113.0ABD41E4022@bag.python.org> The Buildbot has detected a new failure of x86 XP-4 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20XP-4%203.0/builds/387 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-windows Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: 6 tests failed: test_anydbm test_bsddb test_bsddb3 test_mailbox test_shelve test_whichdb ====================================================================== ERROR: test_anydbm_access (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 90, in test_anydbm_access self.init_db() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 103, in init_db f = anydbm.open(_fname, 'n') File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_anydbm_creation (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 63, in test_anydbm_creation f = anydbm.open(_fname, 'c') File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_anydbm_keys (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 84, in test_anydbm_keys self.init_db() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 103, in init_db f = anydbm.open(_fname, 'n') File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_anydbm_modification (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 71, in test_anydbm_modification self.init_db() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 103, in init_db f = anydbm.open(_fname, 'n') File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_anydbm_read (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 78, in test_anydbm_read self.init_db() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 103, in init_db f = anydbm.open(_fname, 'n') File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') Traceback (most recent call last): File "../lib/test/regrtest.py", line 596, in runtest_inner indirect_test() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb3.py", line 64, in test_main run_unittest(suite()) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb3.py", line 28, in suite import bsddb.test.test_1413192 File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\test\test_1413192.py", line 38, in context = Context() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\test\test_1413192.py", line 26, in __init__ db.DB_CREATE | db.DB_INIT_TXN | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_flush (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 703, in tearDown self._delete_recursively(self._path) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 47, in _delete_recursively os.remove(target) WindowsError: [Error 32] The process cannot access the file because it is being used by another process: '@test' ====================================================================== ERROR: test_popitem (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 336, in test_popitem self.assertEqual(int(msg.get_payload()), keys.index(key)) ValueError: invalid literal for int() with base 10: 'From: foo 0 F' ====================================================================== ERROR: test_flush (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 703, in tearDown self._delete_recursively(self._path) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 47, in _delete_recursively os.remove(target) WindowsError: [Error 32] The process cannot access the file because it is being used by another process: '@test' ====================================================================== ERROR: test_popitem (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 336, in test_popitem self.assertEqual(int(msg.get_payload()), keys.index(key)) ValueError: invalid literal for int() with base 10: 'From: foo 0 \x01' ====================================================================== ERROR: test_flush (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 926, in tearDown self._delete_recursively(self._path) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 47, in _delete_recursively os.remove(target) WindowsError: [Error 32] The process cannot access the file because it is being used by another process: '@test' ====================================================================== ERROR: test_popitem (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 336, in test_popitem self.assertEqual(int(msg.get_payload()), keys.index(key)) ValueError: invalid literal for int() with base 10: 'From: foo *** EOOH *** From: foo 0 1,, From: foo *** EOOH *** From: foo 1 1,, From: foo *** EOOH *** From: foo 2 1,, From: foo *** EOOH *** From: foo 3 ' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestMaildir) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_add (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 77, in test_add self.assertEqual(self._box.get_string(keys[0]), self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\nF' != 'From: foo\n\n0' ====================================================================== FAIL: test_add_and_close (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 743, in test_add_and_close self.assertEqual(contents, open(self._path, 'r').read()) AssertionError: 'From MAILER-DAEMON Fri Jan 04 15:12:10 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Fri Jan 04 15:12:10 2008\n\nFrom: foo\n\n0\n\nFrom MAILER-DAEMON Fri Jan 04 15:12:10 2008\n\nFrom: foo\n\n1\n\nFrom MAILER-DAEMON Fri Jan 04 15:12:10 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Fri Jan 04 15:12:10 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'From MAILER-DAEMON Fri Jan 04 15:12:10 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Fri Jan 04 15:12:10 2008\n\nFrom: foo\n\n0\n\nFrom MAILER-DAEMON Fri Jan 04 15:12:10 2008\n\nFrom: foo\n\n1\n\nFrom MAILER-DAEMON Fri Jan 04 15:12:10 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Fri Jan 04 15:12:10 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Fri Jan 04 15:12:10 2008\n\nFrom: foo\n\n0\n\nFrom MAILER-DAEMON Fri Jan 04 15:12:10 2008\n\nFrom: foo\n\n1\n\nFrom MAILER-DAEMON Fri Jan 04 15:12:10 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Fri Jan 04 15:12:10 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Fri Jan 04 15:12:10 2008\n\nFrom: foo\n\n1\n\nFrom MAILER-DAEMON Fri Jan 04 15:12:10 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Fri Jan 04 15:12:10 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Fri Jan 04 15:12:10 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Fri Jan 04 15:12:10 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Fri Jan 04 15:12:10 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' ====================================================================== FAIL: test_add_from_string (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 710, in test_add_from_string self.assertEqual(self._box[key].get_from(), 'foo at bar blah') AssertionError: 'foo at bar blah\n' != 'foo at bar blah' ====================================================================== FAIL: test_close (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 389, in test_close self._test_flush_or_close(self._box.close) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 6 != 3 ====================================================================== FAIL: test_delitem (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 87, in test_delitem self._test_remove_or_delitem(self._box.__delitem__) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n1' != 'From: foo\n\n1' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_flush (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 377, in test_flush self._test_flush_or_close(self._box.flush) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 6 != 3 ====================================================================== FAIL: test_get (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 129, in test_get self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_file (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 174, in test_get_file self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\nF' != 'From: foo\n\n0' ====================================================================== FAIL: test_get_message (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 156, in test_get_message self.assertEqual(msg0['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_string (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 164, in test_get_string self.assertEqual(self._box.get_string(key0), self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\nF' != 'From: foo\n\n0' ====================================================================== FAIL: test_getitem (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 144, in test_getitem self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_items (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 207, in test_items self._check_iteration(self._box.items, do_keys=True, do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iter (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 194, in test_iter do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iteritems (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 203, in test_iteritems do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_itervalues (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 189, in test_itervalues do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_open_close_open (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 727, in test_open_close_open self.assertEqual(len(self._box), 3) AssertionError: 6 != 3 ====================================================================== FAIL: test_pop (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 313, in test_pop self.assertEqual(self._box.pop(key0).get_payload(), '0') AssertionError: 'From: foo\n\n0\n\nF' != '0' ====================================================================== FAIL: test_remove (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 83, in test_remove self._test_remove_or_delitem(self._box.remove) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n1' != 'From: foo\n\n1' ====================================================================== FAIL: test_set_item (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 272, in test_set_item self._template % 'original 0') AssertionError: '\nFrom: foo\n\noriginal 0' != 'From: foo\n\noriginal 0' ====================================================================== FAIL: test_update (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 350, in test_update self._template % 'changed 0') AssertionError: '\nFrom: foo\n\nchanged 0\n\nF' != 'From: foo\n\nchanged 0' ====================================================================== FAIL: test_values (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 198, in test_values self._check_iteration(self._box.values, do_keys=False, do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_add (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 77, in test_add self.assertEqual(self._box.get_string(keys[0]), self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\n\x01' != 'From: foo\n\n0' ====================================================================== FAIL: test_add_and_close (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 743, in test_add_and_close self.assertEqual(contents, open(self._path, 'r').read()) AssertionError: '\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Fri Jan 04 15:12:15 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Fri Jan 04 15:12:15 2008\n\nFrom: foo\n\n0\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Fri Jan 04 15:12:15 2008\n\nFrom: foo\n\n1\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Fri Jan 04 15:12:15 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Fri Jan 04 15:12:15 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n' != '\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Fri Jan 04 15:12:15 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Fri Jan 04 15:12:15 2008\n\nFrom: foo\n\n0\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Fri Jan 04 15:12:15 2008\n\nFrom: foo\n\n1\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Fri Jan 04 15:12:15 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Fri Jan 04 15:12:15 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Fri Jan 04 15:12:15 2008\n\nFrom: foo\n\n0\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Fri Jan 04 15:12:15 2008\n\nFrom: foo\n\n1\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Fri Jan 04 15:12:15 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Fri Jan 04 15:12:15 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Fri Jan 04 15:12:15 2008\n\nFrom: foo\n\n1\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Fri Jan 04 15:12:15 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Fri Jan 04 15:12:15 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Fri Jan 04 15:12:15 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Fri Jan 04 15:12:15 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Fri Jan 04 15:12:15 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n' ====================================================================== FAIL: test_add_from_string (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 710, in test_add_from_string self.assertEqual(self._box[key].get_from(), 'foo at bar blah') AssertionError: 'foo at bar blah\n' != 'foo at bar blah' ====================================================================== FAIL: test_close (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 389, in test_close self._test_flush_or_close(self._box.close) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_delitem (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 87, in test_delitem self._test_remove_or_delitem(self._box.__delitem__) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n1\n\n\x01' != 'From: foo\n\n1' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_flush (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 377, in test_flush self._test_flush_or_close(self._box.flush) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_get (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 129, in test_get self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_file (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 174, in test_get_file self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\n\x01' != 'From: foo\n\n0' ====================================================================== FAIL: test_get_message (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 156, in test_get_message self.assertEqual(msg0['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_string (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 164, in test_get_string self.assertEqual(self._box.get_string(key0), self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\n\x01' != 'From: foo\n\n0' ====================================================================== FAIL: test_getitem (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 144, in test_getitem self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_items (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 207, in test_items self._check_iteration(self._box.items, do_keys=True, do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iter (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 194, in test_iter do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iteritems (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 203, in test_iteritems do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_itervalues (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 189, in test_itervalues do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_open_close_open (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 727, in test_open_close_open self.assertEqual(len(self._box), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_pop (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 313, in test_pop self.assertEqual(self._box.pop(key0).get_payload(), '0') AssertionError: 'From: foo\n\n0\n\n\x01' != '0' ====================================================================== FAIL: test_remove (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 83, in test_remove self._test_remove_or_delitem(self._box.remove) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n1\n\n\x01' != 'From: foo\n\n1' ====================================================================== FAIL: test_set_item (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 272, in test_set_item self._template % 'original 0') AssertionError: '\nFrom: foo\n\noriginal 0\n\n\x01' != 'From: foo\n\noriginal 0' ====================================================================== FAIL: test_update (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 350, in test_update self._template % 'changed 0') AssertionError: '\nFrom: foo\n\nchanged 0\n\n\x01' != 'From: foo\n\nchanged 0' ====================================================================== FAIL: test_values (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 198, in test_values self._check_iteration(self._box.values, do_keys=False, do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestMH) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_add (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 77, in test_add self.assertEqual(self._box.get_string(keys[0]), self._template % 0) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n0\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f' != 'From: foo\n\n0' ====================================================================== FAIL: test_close (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 389, in test_close self._test_flush_or_close(self._box.close) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_delitem (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 87, in test_delitem self._test_remove_or_delitem(self._box.__delitem__) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n1\n\n\x1f' != 'From: foo\n\n1' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_flush (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 377, in test_flush self._test_flush_or_close(self._box.flush) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_get (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 129, in test_get self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_file (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 174, in test_get_file self._template % 0) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n0\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f' != 'From: foo\n\n0' ====================================================================== FAIL: test_get_message (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 156, in test_get_message self.assertEqual(msg0['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_string (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 164, in test_get_string self.assertEqual(self._box.get_string(key0), self._template % 0) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n0\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f' != 'From: foo\n\n0' ====================================================================== FAIL: test_getitem (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 144, in test_getitem self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_items (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 207, in test_items self._check_iteration(self._box.items, do_keys=True, do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iter (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 194, in test_iter do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iteritems (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 203, in test_iteritems do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_itervalues (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 189, in test_itervalues do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_pop (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 313, in test_pop self.assertEqual(self._box.pop(key0).get_payload(), '0') AssertionError: 'From: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n0\n\n\x1f\x0c\n\n1,,\n\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n1\n\n\x1f' != '0' ====================================================================== FAIL: test_remove (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 83, in test_remove self._test_remove_or_delitem(self._box.remove) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n1\n\n\x1f' != 'From: foo\n\n1' ====================================================================== FAIL: test_set_item (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 272, in test_set_item self._template % 'original 0') AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\noriginal 0\n\n\x1f' != 'From: foo\n\noriginal 0' ====================================================================== FAIL: test_update (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 350, in test_update self._template % 'changed 0') AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\nchanged 0\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f' != 'From: foo\n\nchanged 0' ====================================================================== FAIL: test_values (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 198, in test_values self._check_iteration(self._box.values, do_keys=False, do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== ERROR: test_bool (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 136, in test_bool self.assert_(not self._empty_mapping()) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_constructor (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 133, in test_constructor self.assertEqual(self._empty_mapping(), self._empty_mapping()) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 270, in test_get d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_items (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 156, in test_items d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keys (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 142, in test_keys d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 162, in test_len d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 293, in test_pop d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 288, in test_popitem d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_read (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 44, in test_read p = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 284, in test_setdefault d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 174, in test_update d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_values (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 150, in test_values d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_write (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 92, in test_write p = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_bool (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 136, in test_bool self.assert_(not self._empty_mapping()) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_constructor (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 133, in test_constructor self.assertEqual(self._empty_mapping(), self._empty_mapping()) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 270, in test_get d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_items (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 156, in test_items d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keys (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 142, in test_keys d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 162, in test_len d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 293, in test_pop d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 288, in test_popitem d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_read (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 44, in test_read p = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 284, in test_setdefault d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 174, in test_update d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_values (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 150, in test_values d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_write (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 92, in test_write p = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_bool (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 136, in test_bool self.assert_(not self._empty_mapping()) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_constructor (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 133, in test_constructor self.assertEqual(self._empty_mapping(), self._empty_mapping()) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 270, in test_get d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_items (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 156, in test_items d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keys (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 142, in test_keys d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 162, in test_len d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 293, in test_pop d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 288, in test_popitem d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_read (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 44, in test_read p = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 284, in test_setdefault d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 174, in test_update d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_values (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 150, in test_values d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_write (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 92, in test_write p = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_ascii_file_shelf (test.test_shelve.TestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 46, in test_ascii_file_shelf s = shelve.open(self.fn, protocol=0) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_binary_file_shelf (test.test_shelve.TestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 54, in test_binary_file_shelf s = shelve.open(self.fn, protocol=1) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_proto2_file_shelf (test.test_shelve.TestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 62, in test_proto2_file_shelf s = shelve.open(self.fn, protocol=2) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_whichdb (test.test_whichdb.WhichDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_whichdb.py", line 32, in test_whichdb f = module.open(_fname, 'c') File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') sincerely, -The Buildbot From python-checkins at python.org Fri Jan 4 16:23:31 2008 From: python-checkins at python.org (christian.heimes) Date: Fri, 4 Jan 2008 16:23:31 +0100 (CET) Subject: [Python-checkins] r59716 - in python/trunk: Doc/library/socket.rst Lib/socket.py Misc/NEWS Modules/socketmodule.c Modules/socketmodule.h Message-ID: <20080104152331.572A51E401B@bag.python.org> Author: christian.heimes Date: Fri Jan 4 16:23:30 2008 New Revision: 59716 Modified: python/trunk/Doc/library/socket.rst python/trunk/Lib/socket.py python/trunk/Misc/NEWS python/trunk/Modules/socketmodule.c python/trunk/Modules/socketmodule.h Log: Added interface to Windows' WSAIoctl and a simple example for a network sniffer. Modified: python/trunk/Doc/library/socket.rst ============================================================================== --- python/trunk/Doc/library/socket.rst (original) +++ python/trunk/Doc/library/socket.rst Fri Jan 4 16:23:30 2008 @@ -1,863 +1,906 @@ - -:mod:`socket` --- Low-level networking interface -================================================ - -.. module:: socket - :synopsis: Low-level networking interface. - - -This module provides access to the BSD *socket* interface. It is available on -all modern Unix systems, Windows, Mac OS X, BeOS, OS/2, and probably additional -platforms. - -.. note:: - - Some behavior may be platform dependent, since calls are made to the operating - system socket APIs. - -For an introduction to socket programming (in C), see the following papers: An -Introductory 4.3BSD Interprocess Communication Tutorial, by Stuart Sechrest and -An Advanced 4.3BSD Interprocess Communication Tutorial, by Samuel J. Leffler et -al, both in the UNIX Programmer's Manual, Supplementary Documents 1 (sections -PS1:7 and PS1:8). The platform-specific reference material for the various -socket-related system calls are also a valuable source of information on the -details of socket semantics. For Unix, refer to the manual pages; for Windows, -see the WinSock (or Winsock 2) specification. For IPv6-ready APIs, readers may -want to refer to :rfc:`2553` titled Basic Socket Interface Extensions for IPv6. - -.. index:: object: socket - -The Python interface is a straightforward transliteration of the Unix system -call and library interface for sockets to Python's object-oriented style: the -:func:`socket` function returns a :dfn:`socket object` whose methods implement -the various socket system calls. Parameter types are somewhat higher-level than -in the C interface: as with :meth:`read` and :meth:`write` operations on Python -files, buffer allocation on receive operations is automatic, and buffer length -is implicit on send operations. - -Socket addresses are represented as follows: A single string is used for the -:const:`AF_UNIX` address family. A pair ``(host, port)`` is used for the -:const:`AF_INET` address family, where *host* is a string representing either a -hostname in Internet domain notation like ``'daring.cwi.nl'`` or an IPv4 address -like ``'100.50.200.5'``, and *port* is an integral port number. For -:const:`AF_INET6` address family, a four-tuple ``(host, port, flowinfo, -scopeid)`` is used, where *flowinfo* and *scopeid* represents ``sin6_flowinfo`` -and ``sin6_scope_id`` member in :const:`struct sockaddr_in6` in C. For -:mod:`socket` module methods, *flowinfo* and *scopeid* can be omitted just for -backward compatibility. Note, however, omission of *scopeid* can cause problems -in manipulating scoped IPv6 addresses. Other address families are currently not -supported. The address format required by a particular socket object is -automatically selected based on the address family specified when the socket -object was created. - -For IPv4 addresses, two special forms are accepted instead of a host address: -the empty string represents :const:`INADDR_ANY`, and the string -``''`` represents :const:`INADDR_BROADCAST`. The behavior is not -available for IPv6 for backward compatibility, therefore, you may want to avoid -these if you intend to support IPv6 with your Python programs. - -If you use a hostname in the *host* portion of IPv4/v6 socket address, the -program may show a nondeterministic behavior, as Python uses the first address -returned from the DNS resolution. The socket address will be resolved -differently into an actual IPv4/v6 address, depending on the results from DNS -resolution and/or the host configuration. For deterministic behavior use a -numeric address in *host* portion. - -.. versionadded:: 2.5 - AF_NETLINK sockets are represented as pairs ``pid, groups``. - -All errors raise exceptions. The normal exceptions for invalid argument types -and out-of-memory conditions can be raised; errors related to socket or address -semantics raise the error :exc:`socket.error`. - -Non-blocking mode is supported through :meth:`setblocking`. A generalization of -this based on timeouts is supported through :meth:`settimeout`. - -The module :mod:`socket` exports the following constants and functions: - - -.. exception:: error - - .. index:: module: errno - - This exception is raised for socket-related errors. The accompanying value is - either a string telling what went wrong or a pair ``(errno, string)`` - representing an error returned by a system call, similar to the value - accompanying :exc:`os.error`. See the module :mod:`errno`, which contains names - for the error codes defined by the underlying operating system. - - .. versionchanged:: 2.6 - :exc:`socket.error` is now a child class of :exc:`IOError`. - - -.. exception:: herror - - This exception is raised for address-related errors, i.e. for functions that use - *h_errno* in the C API, including :func:`gethostbyname_ex` and - :func:`gethostbyaddr`. - - The accompanying value is a pair ``(h_errno, string)`` representing an error - returned by a library call. *string* represents the description of *h_errno*, as - returned by the :cfunc:`hstrerror` C function. - - -.. exception:: gaierror - - This exception is raised for address-related errors, for :func:`getaddrinfo` and - :func:`getnameinfo`. The accompanying value is a pair ``(error, string)`` - representing an error returned by a library call. *string* represents the - description of *error*, as returned by the :cfunc:`gai_strerror` C function. The - *error* value will match one of the :const:`EAI_\*` constants defined in this - module. - - -.. exception:: timeout - - This exception is raised when a timeout occurs on a socket which has had - timeouts enabled via a prior call to :meth:`settimeout`. The accompanying value - is a string whose value is currently always "timed out". - - .. versionadded:: 2.3 - - -.. data:: AF_UNIX - AF_INET - AF_INET6 - - These constants represent the address (and protocol) families, used for the - first argument to :func:`socket`. If the :const:`AF_UNIX` constant is not - defined then this protocol is unsupported. - - -.. data:: SOCK_STREAM - SOCK_DGRAM - SOCK_RAW - SOCK_RDM - SOCK_SEQPACKET - - These constants represent the socket types, used for the second argument to - :func:`socket`. (Only :const:`SOCK_STREAM` and :const:`SOCK_DGRAM` appear to be - generally useful.) - - -.. data:: SO_* - SOMAXCONN - MSG_* - SOL_* - IPPROTO_* - IPPORT_* - INADDR_* - IP_* - IPV6_* - EAI_* - AI_* - NI_* - TCP_* - - Many constants of these forms, documented in the Unix documentation on sockets - and/or the IP protocol, are also defined in the socket module. They are - generally used in arguments to the :meth:`setsockopt` and :meth:`getsockopt` - methods of socket objects. In most cases, only those symbols that are defined - in the Unix header files are defined; for a few symbols, default values are - provided. - - -.. data:: has_ipv6 - - This constant contains a boolean value which indicates if IPv6 is supported on - this platform. - - .. versionadded:: 2.3 - - -.. function:: create_connection(address[, timeout]) - - Connects to the *address* received (as usual, a ``(host, port)`` pair), with an - optional timeout for the connection. Especially useful for higher-level - protocols, it is not normally used directly from application-level code. - Passing the optional *timeout* parameter will set the timeout on the socket - instance (if it is not given or ``None``, the global default timeout setting is - used). - - .. versionadded:: 2.6 - - -.. function:: getaddrinfo(host, port[, family[, socktype[, proto[, flags]]]]) - - Resolves the *host*/*port* argument, into a sequence of 5-tuples that contain - all the necessary argument for the sockets manipulation. *host* is a domain - name, a string representation of IPv4/v6 address or ``None``. *port* is a string - service name (like ``'http'``), a numeric port number or ``None``. - - The rest of the arguments are optional and must be numeric if specified. For - *host* and *port*, by passing either an empty string or ``None``, you can pass - ``NULL`` to the C API. The :func:`getaddrinfo` function returns a list of - 5-tuples with the following structure: - - ``(family, socktype, proto, canonname, sockaddr)`` - - *family*, *socktype*, *proto* are all integer and are meant to be passed to the - :func:`socket` function. *canonname* is a string representing the canonical name - of the *host*. It can be a numeric IPv4/v6 address when :const:`AI_CANONNAME` is - specified for a numeric *host*. *sockaddr* is a tuple describing a socket - address, as described above. See the source for :mod:`socket` and other - library modules for a typical usage of the function. - - .. versionadded:: 2.2 - - -.. function:: getfqdn([name]) - - Return a fully qualified domain name for *name*. If *name* is omitted or empty, - it is interpreted as the local host. To find the fully qualified name, the - hostname returned by :func:`gethostbyaddr` is checked, then aliases for the - host, if available. The first name which includes a period is selected. In - case no fully qualified domain name is available, the hostname as returned by - :func:`gethostname` is returned. - - .. versionadded:: 2.0 - - -.. function:: gethostbyname(hostname) - - Translate a host name to IPv4 address format. The IPv4 address is returned as a - string, such as ``'100.50.200.5'``. If the host name is an IPv4 address itself - it is returned unchanged. See :func:`gethostbyname_ex` for a more complete - interface. :func:`gethostbyname` does not support IPv6 name resolution, and - :func:`getaddrinfo` should be used instead for IPv4/v6 dual stack support. - - -.. function:: gethostbyname_ex(hostname) - - Translate a host name to IPv4 address format, extended interface. Return a - triple ``(hostname, aliaslist, ipaddrlist)`` where *hostname* is the primary - host name responding to the given *ip_address*, *aliaslist* is a (possibly - empty) list of alternative host names for the same address, and *ipaddrlist* is - a list of IPv4 addresses for the same interface on the same host (often but not - always a single address). :func:`gethostbyname_ex` does not support IPv6 name - resolution, and :func:`getaddrinfo` should be used instead for IPv4/v6 dual - stack support. - - -.. function:: gethostname() - - Return a string containing the hostname of the machine where the Python - interpreter is currently executing. If you want to know the current machine's IP - address, you may want to use ``gethostbyname(gethostname())``. This operation - assumes that there is a valid address-to-host mapping for the host, and the - assumption does not always hold. Note: :func:`gethostname` doesn't always return - the fully qualified domain name; use ``getfqdn()`` (see above). - - -.. function:: gethostbyaddr(ip_address) - - Return a triple ``(hostname, aliaslist, ipaddrlist)`` where *hostname* is the - primary host name responding to the given *ip_address*, *aliaslist* is a - (possibly empty) list of alternative host names for the same address, and - *ipaddrlist* is a list of IPv4/v6 addresses for the same interface on the same - host (most likely containing only a single address). To find the fully qualified - domain name, use the function :func:`getfqdn`. :func:`gethostbyaddr` supports - both IPv4 and IPv6. - - -.. function:: getnameinfo(sockaddr, flags) - - Translate a socket address *sockaddr* into a 2-tuple ``(host, port)``. Depending - on the settings of *flags*, the result can contain a fully-qualified domain name - or numeric address representation in *host*. Similarly, *port* can contain a - string port name or a numeric port number. - - .. versionadded:: 2.2 - - -.. function:: getprotobyname(protocolname) - - Translate an Internet protocol name (for example, ``'icmp'``) to a constant - suitable for passing as the (optional) third argument to the :func:`socket` - function. This is usually only needed for sockets opened in "raw" mode - (:const:`SOCK_RAW`); for the normal socket modes, the correct protocol is chosen - automatically if the protocol is omitted or zero. - - -.. function:: getservbyname(servicename[, protocolname]) - - Translate an Internet service name and protocol name to a port number for that - service. The optional protocol name, if given, should be ``'tcp'`` or - ``'udp'``, otherwise any protocol will match. - - -.. function:: getservbyport(port[, protocolname]) - - Translate an Internet port number and protocol name to a service name for that - service. The optional protocol name, if given, should be ``'tcp'`` or - ``'udp'``, otherwise any protocol will match. - - -.. function:: socket([family[, type[, proto]]]) - - Create a new socket using the given address family, socket type and protocol - number. The address family should be :const:`AF_INET` (the default), - :const:`AF_INET6` or :const:`AF_UNIX`. The socket type should be - :const:`SOCK_STREAM` (the default), :const:`SOCK_DGRAM` or perhaps one of the - other ``SOCK_`` constants. The protocol number is usually zero and may be - omitted in that case. - - -.. function:: socketpair([family[, type[, proto]]]) - - Build a pair of connected socket objects using the given address family, socket - type, and protocol number. Address family, socket type, and protocol number are - as for the :func:`socket` function above. The default family is :const:`AF_UNIX` - if defined on the platform; otherwise, the default is :const:`AF_INET`. - Availability: Unix. - - .. versionadded:: 2.4 - - -.. function:: fromfd(fd, family, type[, proto]) - - Duplicate the file descriptor *fd* (an integer as returned by a file object's - :meth:`fileno` method) and build a socket object from the result. Address - family, socket type and protocol number are as for the :func:`socket` function - above. The file descriptor should refer to a socket, but this is not checked --- - subsequent operations on the object may fail if the file descriptor is invalid. - This function is rarely needed, but can be used to get or set socket options on - a socket passed to a program as standard input or output (such as a server - started by the Unix inet daemon). The socket is assumed to be in blocking mode. - Availability: Unix. - - -.. function:: ntohl(x) - - Convert 32-bit positive integers from network to host byte order. On machines - where the host byte order is the same as network byte order, this is a no-op; - otherwise, it performs a 4-byte swap operation. - - -.. function:: ntohs(x) - - Convert 16-bit positive integers from network to host byte order. On machines - where the host byte order is the same as network byte order, this is a no-op; - otherwise, it performs a 2-byte swap operation. - - -.. function:: htonl(x) - - Convert 32-bit positive integers from host to network byte order. On machines - where the host byte order is the same as network byte order, this is a no-op; - otherwise, it performs a 4-byte swap operation. - - -.. function:: htons(x) - - Convert 16-bit positive integers from host to network byte order. On machines - where the host byte order is the same as network byte order, this is a no-op; - otherwise, it performs a 2-byte swap operation. - - -.. function:: inet_aton(ip_string) - - Convert an IPv4 address from dotted-quad string format (for example, - '123.45.67.89') to 32-bit packed binary format, as a string four characters in - length. This is useful when conversing with a program that uses the standard C - library and needs objects of type :ctype:`struct in_addr`, which is the C type - for the 32-bit packed binary this function returns. - - If the IPv4 address string passed to this function is invalid, - :exc:`socket.error` will be raised. Note that exactly what is valid depends on - the underlying C implementation of :cfunc:`inet_aton`. - - :func:`inet_aton` does not support IPv6, and :func:`getnameinfo` should be used - instead for IPv4/v6 dual stack support. - - -.. function:: inet_ntoa(packed_ip) - - Convert a 32-bit packed IPv4 address (a string four characters in length) to its - standard dotted-quad string representation (for example, '123.45.67.89'). This - is useful when conversing with a program that uses the standard C library and - needs objects of type :ctype:`struct in_addr`, which is the C type for the - 32-bit packed binary data this function takes as an argument. - - If the string passed to this function is not exactly 4 bytes in length, - :exc:`socket.error` will be raised. :func:`inet_ntoa` does not support IPv6, and - :func:`getnameinfo` should be used instead for IPv4/v6 dual stack support. - - -.. function:: inet_pton(address_family, ip_string) - - Convert an IP address from its family-specific string format to a packed, binary - format. :func:`inet_pton` is useful when a library or network protocol calls for - an object of type :ctype:`struct in_addr` (similar to :func:`inet_aton`) or - :ctype:`struct in6_addr`. - - Supported values for *address_family* are currently :const:`AF_INET` and - :const:`AF_INET6`. If the IP address string *ip_string* is invalid, - :exc:`socket.error` will be raised. Note that exactly what is valid depends on - both the value of *address_family* and the underlying implementation of - :cfunc:`inet_pton`. - - Availability: Unix (maybe not all platforms). - - .. versionadded:: 2.3 - - -.. function:: inet_ntop(address_family, packed_ip) - - Convert a packed IP address (a string of some number of characters) to its - standard, family-specific string representation (for example, ``'7.10.0.5'`` or - ``'5aef:2b::8'``) :func:`inet_ntop` is useful when a library or network protocol - returns an object of type :ctype:`struct in_addr` (similar to :func:`inet_ntoa`) - or :ctype:`struct in6_addr`. - - Supported values for *address_family* are currently :const:`AF_INET` and - :const:`AF_INET6`. If the string *packed_ip* is not the correct length for the - specified address family, :exc:`ValueError` will be raised. A - :exc:`socket.error` is raised for errors from the call to :func:`inet_ntop`. - - Availability: Unix (maybe not all platforms). - - .. versionadded:: 2.3 - - -.. function:: getdefaulttimeout() - - Return the default timeout in floating seconds for new socket objects. A value - of ``None`` indicates that new socket objects have no timeout. When the socket - module is first imported, the default is ``None``. - - .. versionadded:: 2.3 - - -.. function:: setdefaulttimeout(timeout) - - Set the default timeout in floating seconds for new socket objects. A value of - ``None`` indicates that new socket objects have no timeout. When the socket - module is first imported, the default is ``None``. - - .. versionadded:: 2.3 - - -.. data:: SocketType - - This is a Python type object that represents the socket object type. It is the - same as ``type(socket(...))``. - - -.. seealso:: - - Module :mod:`SocketServer` - Classes that simplify writing network servers. - - -.. _socket-objects: - -Socket Objects --------------- - -Socket objects have the following methods. Except for :meth:`makefile` these -correspond to Unix system calls applicable to sockets. - - -.. method:: socket.accept() - - Accept a connection. The socket must be bound to an address and listening for - connections. The return value is a pair ``(conn, address)`` where *conn* is a - *new* socket object usable to send and receive data on the connection, and - *address* is the address bound to the socket on the other end of the connection. - - -.. method:: socket.bind(address) - - Bind the socket to *address*. The socket must not already be bound. (The format - of *address* depends on the address family --- see above.) - - .. note:: - - This method has historically accepted a pair of parameters for :const:`AF_INET` - addresses instead of only a tuple. This was never intentional and is no longer - available in Python 2.0 and later. - - -.. method:: socket.close() - - Close the socket. All future operations on the socket object will fail. The - remote end will receive no more data (after queued data is flushed). Sockets are - automatically closed when they are garbage-collected. - - -.. method:: socket.connect(address) - - Connect to a remote socket at *address*. (The format of *address* depends on the - address family --- see above.) - - .. note:: - - This method has historically accepted a pair of parameters for :const:`AF_INET` - addresses instead of only a tuple. This was never intentional and is no longer - available in Python 2.0 and later. - - -.. method:: socket.connect_ex(address) - - Like ``connect(address)``, but return an error indicator instead of raising an - exception for errors returned by the C-level :cfunc:`connect` call (other - problems, such as "host not found," can still raise exceptions). The error - indicator is ``0`` if the operation succeeded, otherwise the value of the - :cdata:`errno` variable. This is useful to support, for example, asynchronous - connects. - - .. note:: - - This method has historically accepted a pair of parameters for :const:`AF_INET` - addresses instead of only a tuple. This was never intentional and is no longer - available in Python 2.0 and later. - - -.. method:: socket.fileno() - - Return the socket's file descriptor (a small integer). This is useful with - :func:`select.select`. - - Under Windows the small integer returned by this method cannot be used where a - file descriptor can be used (such as :func:`os.fdopen`). Unix does not have - this limitation. - - -.. method:: socket.getpeername() - - Return the remote address to which the socket is connected. This is useful to - find out the port number of a remote IPv4/v6 socket, for instance. (The format - of the address returned depends on the address family --- see above.) On some - systems this function is not supported. - - -.. method:: socket.getsockname() - - Return the socket's own address. This is useful to find out the port number of - an IPv4/v6 socket, for instance. (The format of the address returned depends on - the address family --- see above.) - - -.. method:: socket.getsockopt(level, optname[, buflen]) - - Return the value of the given socket option (see the Unix man page - :manpage:`getsockopt(2)`). The needed symbolic constants (:const:`SO_\*` etc.) - are defined in this module. If *buflen* is absent, an integer option is assumed - and its integer value is returned by the function. If *buflen* is present, it - specifies the maximum length of the buffer used to receive the option in, and - this buffer is returned as a string. It is up to the caller to decode the - contents of the buffer (see the optional built-in module :mod:`struct` for a way - to decode C structures encoded as strings). - - -.. method:: socket.listen(backlog) - - Listen for connections made to the socket. The *backlog* argument specifies the - maximum number of queued connections and should be at least 1; the maximum value - is system-dependent (usually 5). - - -.. method:: socket.makefile([mode[, bufsize]]) - - .. index:: single: I/O control; buffering - - Return a :dfn:`file object` associated with the socket. (File objects are - described in :ref:`bltin-file-objects`.) The file object - references a :cfunc:`dup`\ ped version of the socket file descriptor, so the - file object and socket object may be closed or garbage-collected independently. - The socket must be in blocking mode (it can not have a timeout). The optional - *mode* and *bufsize* arguments are interpreted the same way as by the built-in - :func:`file` function. - - -.. method:: socket.recv(bufsize[, flags]) - - Receive data from the socket. The return value is a string representing the - data received. The maximum amount of data to be received at once is specified - by *bufsize*. See the Unix manual page :manpage:`recv(2)` for the meaning of - the optional argument *flags*; it defaults to zero. - - .. note:: - - For best match with hardware and network realities, the value of *bufsize* - should be a relatively small power of 2, for example, 4096. - - -.. method:: socket.recvfrom(bufsize[, flags]) - - Receive data from the socket. The return value is a pair ``(string, address)`` - where *string* is a string representing the data received and *address* is the - address of the socket sending the data. See the Unix manual page - :manpage:`recv(2)` for the meaning of the optional argument *flags*; it defaults - to zero. (The format of *address* depends on the address family --- see above.) - - -.. method:: socket.recvfrom_into(buffer[, nbytes[, flags]]) - - Receive data from the socket, writing it into *buffer* instead of creating a - new string. The return value is a pair ``(nbytes, address)`` where *nbytes* is - the number of bytes received and *address* is the address of the socket sending - the data. See the Unix manual page :manpage:`recv(2)` for the meaning of the - optional argument *flags*; it defaults to zero. (The format of *address* - depends on the address family --- see above.) - - .. versionadded:: 2.5 - - -.. method:: socket.recv_into(buffer[, nbytes[, flags]]) - - Receive up to *nbytes* bytes from the socket, storing the data into a buffer - rather than creating a new string. If *nbytes* is not specified (or 0), - receive up to the size available in the given buffer. See the Unix manual page - :manpage:`recv(2)` for the meaning of the optional argument *flags*; it defaults - to zero. - - .. versionadded:: 2.5 - - -.. method:: socket.send(string[, flags]) - - Send data to the socket. The socket must be connected to a remote socket. The - optional *flags* argument has the same meaning as for :meth:`recv` above. - Returns the number of bytes sent. Applications are responsible for checking that - all data has been sent; if only some of the data was transmitted, the - application needs to attempt delivery of the remaining data. - - -.. method:: socket.sendall(string[, flags]) - - Send data to the socket. The socket must be connected to a remote socket. The - optional *flags* argument has the same meaning as for :meth:`recv` above. - Unlike :meth:`send`, this method continues to send data from *string* until - either all data has been sent or an error occurs. ``None`` is returned on - success. On error, an exception is raised, and there is no way to determine how - much data, if any, was successfully sent. - - -.. method:: socket.sendto(string[, flags], address) - - Send data to the socket. The socket should not be connected to a remote socket, - since the destination socket is specified by *address*. The optional *flags* - argument has the same meaning as for :meth:`recv` above. Return the number of - bytes sent. (The format of *address* depends on the address family --- see - above.) - - -.. method:: socket.setblocking(flag) - - Set blocking or non-blocking mode of the socket: if *flag* is 0, the socket is - set to non-blocking, else to blocking mode. Initially all sockets are in - blocking mode. In non-blocking mode, if a :meth:`recv` call doesn't find any - data, or if a :meth:`send` call can't immediately dispose of the data, a - :exc:`error` exception is raised; in blocking mode, the calls block until they - can proceed. ``s.setblocking(0)`` is equivalent to ``s.settimeout(0)``; - ``s.setblocking(1)`` is equivalent to ``s.settimeout(None)``. - - -.. method:: socket.settimeout(value) - - Set a timeout on blocking socket operations. The *value* argument can be a - nonnegative float expressing seconds, or ``None``. If a float is given, - subsequent socket operations will raise an :exc:`timeout` exception if the - timeout period *value* has elapsed before the operation has completed. Setting - a timeout of ``None`` disables timeouts on socket operations. - ``s.settimeout(0.0)`` is equivalent to ``s.setblocking(0)``; - ``s.settimeout(None)`` is equivalent to ``s.setblocking(1)``. - - .. versionadded:: 2.3 - - -.. method:: socket.gettimeout() - - Return the timeout in floating seconds associated with socket operations, or - ``None`` if no timeout is set. This reflects the last call to - :meth:`setblocking` or :meth:`settimeout`. - - .. versionadded:: 2.3 - -Some notes on socket blocking and timeouts: A socket object can be in one of -three modes: blocking, non-blocking, or timeout. Sockets are always created in -blocking mode. In blocking mode, operations block until complete. In -non-blocking mode, operations fail (with an error that is unfortunately -system-dependent) if they cannot be completed immediately. In timeout mode, -operations fail if they cannot be completed within the timeout specified for the -socket. The :meth:`setblocking` method is simply a shorthand for certain -:meth:`settimeout` calls. - -Timeout mode internally sets the socket in non-blocking mode. The blocking and -timeout modes are shared between file descriptors and socket objects that refer -to the same network endpoint. A consequence of this is that file objects -returned by the :meth:`makefile` method must only be used when the socket is in -blocking mode; in timeout or non-blocking mode file operations that cannot be -completed immediately will fail. - -Note that the :meth:`connect` operation is subject to the timeout setting, and -in general it is recommended to call :meth:`settimeout` before calling -:meth:`connect`. - - -.. method:: socket.setsockopt(level, optname, value) - - .. index:: module: struct - - Set the value of the given socket option (see the Unix manual page - :manpage:`setsockopt(2)`). The needed symbolic constants are defined in the - :mod:`socket` module (:const:`SO_\*` etc.). The value can be an integer or a - string representing a buffer. In the latter case it is up to the caller to - ensure that the string contains the proper bits (see the optional built-in - module :mod:`struct` for a way to encode C structures as strings). - - -.. method:: socket.shutdown(how) - - Shut down one or both halves of the connection. If *how* is :const:`SHUT_RD`, - further receives are disallowed. If *how* is :const:`SHUT_WR`, further sends - are disallowed. If *how* is :const:`SHUT_RDWR`, further sends and receives are - disallowed. - -Note that there are no methods :meth:`read` or :meth:`write`; use :meth:`recv` -and :meth:`send` without *flags* argument instead. - -Socket objects also have these (read-only) attributes that correspond to the -values given to the :class:`socket` constructor. - - -.. attribute:: socket.family - - The socket family. - - .. versionadded:: 2.5 - - -.. attribute:: socket.type - - The socket type. - - .. versionadded:: 2.5 - - -.. attribute:: socket.proto - - The socket protocol. - - .. versionadded:: 2.5 - - -.. _socket-example: - -Example -------- - -Here are four minimal example programs using the TCP/IP protocol: a server that -echoes all data that it receives back (servicing only one client), and a client -using it. Note that a server must perform the sequence :func:`socket`, -:meth:`bind`, :meth:`listen`, :meth:`accept` (possibly repeating the -:meth:`accept` to service more than one client), while a client only needs the -sequence :func:`socket`, :meth:`connect`. Also note that the server does not -:meth:`send`/:meth:`recv` on the socket it is listening on but on the new -socket returned by :meth:`accept`. - -The first two examples support IPv4 only. :: - - # Echo server program - import socket - - HOST = '' # Symbolic name meaning the local host - PORT = 50007 # Arbitrary non-privileged port - s = socket.socket(socket.AF_INET, socket.SOCK_STREAM) - s.bind((HOST, PORT)) - s.listen(1) - conn, addr = s.accept() - print 'Connected by', addr - while 1: - data = conn.recv(1024) - if not data: break - conn.send(data) - conn.close() - -:: - - # Echo client program - import socket - - HOST = 'daring.cwi.nl' # The remote host - PORT = 50007 # The same port as used by the server - s = socket.socket(socket.AF_INET, socket.SOCK_STREAM) - s.connect((HOST, PORT)) - s.send('Hello, world') - data = s.recv(1024) - s.close() - print 'Received', repr(data) - -The next two examples are identical to the above two, but support both IPv4 and -IPv6. The server side will listen to the first address family available (it -should listen to both instead). On most of IPv6-ready systems, IPv6 will take -precedence and the server may not accept IPv4 traffic. The client side will try -to connect to the all addresses returned as a result of the name resolution, and -sends traffic to the first one connected successfully. :: - - # Echo server program - import socket - import sys - - HOST = '' # Symbolic name meaning the local host - PORT = 50007 # Arbitrary non-privileged port - s = None - for res in socket.getaddrinfo(HOST, PORT, socket.AF_UNSPEC, socket.SOCK_STREAM, 0, socket.AI_PASSIVE): - af, socktype, proto, canonname, sa = res - try: - s = socket.socket(af, socktype, proto) - except socket.error, msg: - s = None - continue - try: - s.bind(sa) - s.listen(1) - except socket.error, msg: - s.close() - s = None - continue - break - if s is None: - print 'could not open socket' - sys.exit(1) - conn, addr = s.accept() - print 'Connected by', addr - while 1: - data = conn.recv(1024) - if not data: break - conn.send(data) - conn.close() - -:: - - # Echo client program - import socket - import sys - - HOST = 'daring.cwi.nl' # The remote host - PORT = 50007 # The same port as used by the server - s = None - for res in socket.getaddrinfo(HOST, PORT, socket.AF_UNSPEC, socket.SOCK_STREAM): - af, socktype, proto, canonname, sa = res - try: - s = socket.socket(af, socktype, proto) - except socket.error, msg: - s = None - continue - try: - s.connect(sa) - except socket.error, msg: - s.close() - s = None - continue - break - if s is None: - print 'could not open socket' - sys.exit(1) - s.send('Hello, world') - data = s.recv(1024) - s.close() - print 'Received', repr(data) - + +:mod:`socket` --- Low-level networking interface +================================================ + +.. module:: socket + :synopsis: Low-level networking interface. + + +This module provides access to the BSD *socket* interface. It is available on +all modern Unix systems, Windows, Mac OS X, BeOS, OS/2, and probably additional +platforms. + +.. note:: + + Some behavior may be platform dependent, since calls are made to the operating + system socket APIs. + +For an introduction to socket programming (in C), see the following papers: An +Introductory 4.3BSD Interprocess Communication Tutorial, by Stuart Sechrest and +An Advanced 4.3BSD Interprocess Communication Tutorial, by Samuel J. Leffler et +al, both in the UNIX Programmer's Manual, Supplementary Documents 1 (sections +PS1:7 and PS1:8). The platform-specific reference material for the various +socket-related system calls are also a valuable source of information on the +details of socket semantics. For Unix, refer to the manual pages; for Windows, +see the WinSock (or Winsock 2) specification. For IPv6-ready APIs, readers may +want to refer to :rfc:`2553` titled Basic Socket Interface Extensions for IPv6. + +.. index:: object: socket + +The Python interface is a straightforward transliteration of the Unix system +call and library interface for sockets to Python's object-oriented style: the +:func:`socket` function returns a :dfn:`socket object` whose methods implement +the various socket system calls. Parameter types are somewhat higher-level than +in the C interface: as with :meth:`read` and :meth:`write` operations on Python +files, buffer allocation on receive operations is automatic, and buffer length +is implicit on send operations. + +Socket addresses are represented as follows: A single string is used for the +:const:`AF_UNIX` address family. A pair ``(host, port)`` is used for the +:const:`AF_INET` address family, where *host* is a string representing either a +hostname in Internet domain notation like ``'daring.cwi.nl'`` or an IPv4 address +like ``'100.50.200.5'``, and *port* is an integral port number. For +:const:`AF_INET6` address family, a four-tuple ``(host, port, flowinfo, +scopeid)`` is used, where *flowinfo* and *scopeid* represents ``sin6_flowinfo`` +and ``sin6_scope_id`` member in :const:`struct sockaddr_in6` in C. For +:mod:`socket` module methods, *flowinfo* and *scopeid* can be omitted just for +backward compatibility. Note, however, omission of *scopeid* can cause problems +in manipulating scoped IPv6 addresses. Other address families are currently not +supported. The address format required by a particular socket object is +automatically selected based on the address family specified when the socket +object was created. + +For IPv4 addresses, two special forms are accepted instead of a host address: +the empty string represents :const:`INADDR_ANY`, and the string +``''`` represents :const:`INADDR_BROADCAST`. The behavior is not +available for IPv6 for backward compatibility, therefore, you may want to avoid +these if you intend to support IPv6 with your Python programs. + +If you use a hostname in the *host* portion of IPv4/v6 socket address, the +program may show a nondeterministic behavior, as Python uses the first address +returned from the DNS resolution. The socket address will be resolved +differently into an actual IPv4/v6 address, depending on the results from DNS +resolution and/or the host configuration. For deterministic behavior use a +numeric address in *host* portion. + +.. versionadded:: 2.5 + AF_NETLINK sockets are represented as pairs ``pid, groups``. + +All errors raise exceptions. The normal exceptions for invalid argument types +and out-of-memory conditions can be raised; errors related to socket or address +semantics raise the error :exc:`socket.error`. + +Non-blocking mode is supported through :meth:`setblocking`. A generalization of +this based on timeouts is supported through :meth:`settimeout`. + +The module :mod:`socket` exports the following constants and functions: + + +.. exception:: error + + .. index:: module: errno + + This exception is raised for socket-related errors. The accompanying value is + either a string telling what went wrong or a pair ``(errno, string)`` + representing an error returned by a system call, similar to the value + accompanying :exc:`os.error`. See the module :mod:`errno`, which contains names + for the error codes defined by the underlying operating system. + + .. versionchanged:: 2.6 + :exc:`socket.error` is now a child class of :exc:`IOError`. + + +.. exception:: herror + + This exception is raised for address-related errors, i.e. for functions that use + *h_errno* in the C API, including :func:`gethostbyname_ex` and + :func:`gethostbyaddr`. + + The accompanying value is a pair ``(h_errno, string)`` representing an error + returned by a library call. *string* represents the description of *h_errno*, as + returned by the :cfunc:`hstrerror` C function. + + +.. exception:: gaierror + + This exception is raised for address-related errors, for :func:`getaddrinfo` and + :func:`getnameinfo`. The accompanying value is a pair ``(error, string)`` + representing an error returned by a library call. *string* represents the + description of *error*, as returned by the :cfunc:`gai_strerror` C function. The + *error* value will match one of the :const:`EAI_\*` constants defined in this + module. + + +.. exception:: timeout + + This exception is raised when a timeout occurs on a socket which has had + timeouts enabled via a prior call to :meth:`settimeout`. The accompanying value + is a string whose value is currently always "timed out". + + .. versionadded:: 2.3 + + +.. data:: AF_UNIX + AF_INET + AF_INET6 + + These constants represent the address (and protocol) families, used for the + first argument to :func:`socket`. If the :const:`AF_UNIX` constant is not + defined then this protocol is unsupported. + + +.. data:: SOCK_STREAM + SOCK_DGRAM + SOCK_RAW + SOCK_RDM + SOCK_SEQPACKET + + These constants represent the socket types, used for the second argument to + :func:`socket`. (Only :const:`SOCK_STREAM` and :const:`SOCK_DGRAM` appear to be + generally useful.) + + +.. data:: SO_* + SOMAXCONN + MSG_* + SOL_* + IPPROTO_* + IPPORT_* + INADDR_* + IP_* + IPV6_* + EAI_* + AI_* + NI_* + TCP_* + + Many constants of these forms, documented in the Unix documentation on sockets + and/or the IP protocol, are also defined in the socket module. They are + generally used in arguments to the :meth:`setsockopt` and :meth:`getsockopt` + methods of socket objects. In most cases, only those symbols that are defined + in the Unix header files are defined; for a few symbols, default values are + provided. + +.. data:: SIO_* + RCVALL_* + + Constants for Windows' WSAIoctl(). The constants are used as arguments to the + :meth:`ioctl` method of socket objects. + + .. versionadded:: 2.6 + + +.. data:: has_ipv6 + + This constant contains a boolean value which indicates if IPv6 is supported on + this platform. + + .. versionadded:: 2.3 + + +.. function:: create_connection(address[, timeout]) + + Connects to the *address* received (as usual, a ``(host, port)`` pair), with an + optional timeout for the connection. Especially useful for higher-level + protocols, it is not normally used directly from application-level code. + Passing the optional *timeout* parameter will set the timeout on the socket + instance (if it is not given or ``None``, the global default timeout setting is + used). + + .. versionadded:: 2.6 + + +.. function:: getaddrinfo(host, port[, family[, socktype[, proto[, flags]]]]) + + Resolves the *host*/*port* argument, into a sequence of 5-tuples that contain + all the necessary argument for the sockets manipulation. *host* is a domain + name, a string representation of IPv4/v6 address or ``None``. *port* is a string + service name (like ``'http'``), a numeric port number or ``None``. + + The rest of the arguments are optional and must be numeric if specified. For + *host* and *port*, by passing either an empty string or ``None``, you can pass + ``NULL`` to the C API. The :func:`getaddrinfo` function returns a list of + 5-tuples with the following structure: + + ``(family, socktype, proto, canonname, sockaddr)`` + + *family*, *socktype*, *proto* are all integer and are meant to be passed to the + :func:`socket` function. *canonname* is a string representing the canonical name + of the *host*. It can be a numeric IPv4/v6 address when :const:`AI_CANONNAME` is + specified for a numeric *host*. *sockaddr* is a tuple describing a socket + address, as described above. See the source for :mod:`socket` and other + library modules for a typical usage of the function. + + .. versionadded:: 2.2 + + +.. function:: getfqdn([name]) + + Return a fully qualified domain name for *name*. If *name* is omitted or empty, + it is interpreted as the local host. To find the fully qualified name, the + hostname returned by :func:`gethostbyaddr` is checked, then aliases for the + host, if available. The first name which includes a period is selected. In + case no fully qualified domain name is available, the hostname as returned by + :func:`gethostname` is returned. + + .. versionadded:: 2.0 + + +.. function:: gethostbyname(hostname) + + Translate a host name to IPv4 address format. The IPv4 address is returned as a + string, such as ``'100.50.200.5'``. If the host name is an IPv4 address itself + it is returned unchanged. See :func:`gethostbyname_ex` for a more complete + interface. :func:`gethostbyname` does not support IPv6 name resolution, and + :func:`getaddrinfo` should be used instead for IPv4/v6 dual stack support. + + +.. function:: gethostbyname_ex(hostname) + + Translate a host name to IPv4 address format, extended interface. Return a + triple ``(hostname, aliaslist, ipaddrlist)`` where *hostname* is the primary + host name responding to the given *ip_address*, *aliaslist* is a (possibly + empty) list of alternative host names for the same address, and *ipaddrlist* is + a list of IPv4 addresses for the same interface on the same host (often but not + always a single address). :func:`gethostbyname_ex` does not support IPv6 name + resolution, and :func:`getaddrinfo` should be used instead for IPv4/v6 dual + stack support. + + +.. function:: gethostname() + + Return a string containing the hostname of the machine where the Python + interpreter is currently executing. If you want to know the current machine's IP + address, you may want to use ``gethostbyname(gethostname())``. This operation + assumes that there is a valid address-to-host mapping for the host, and the + assumption does not always hold. Note: :func:`gethostname` doesn't always return + the fully qualified domain name; use ``getfqdn()`` (see above). + + +.. function:: gethostbyaddr(ip_address) + + Return a triple ``(hostname, aliaslist, ipaddrlist)`` where *hostname* is the + primary host name responding to the given *ip_address*, *aliaslist* is a + (possibly empty) list of alternative host names for the same address, and + *ipaddrlist* is a list of IPv4/v6 addresses for the same interface on the same + host (most likely containing only a single address). To find the fully qualified + domain name, use the function :func:`getfqdn`. :func:`gethostbyaddr` supports + both IPv4 and IPv6. + + +.. function:: getnameinfo(sockaddr, flags) + + Translate a socket address *sockaddr* into a 2-tuple ``(host, port)``. Depending + on the settings of *flags*, the result can contain a fully-qualified domain name + or numeric address representation in *host*. Similarly, *port* can contain a + string port name or a numeric port number. + + .. versionadded:: 2.2 + + +.. function:: getprotobyname(protocolname) + + Translate an Internet protocol name (for example, ``'icmp'``) to a constant + suitable for passing as the (optional) third argument to the :func:`socket` + function. This is usually only needed for sockets opened in "raw" mode + (:const:`SOCK_RAW`); for the normal socket modes, the correct protocol is chosen + automatically if the protocol is omitted or zero. + + +.. function:: getservbyname(servicename[, protocolname]) + + Translate an Internet service name and protocol name to a port number for that + service. The optional protocol name, if given, should be ``'tcp'`` or + ``'udp'``, otherwise any protocol will match. + + +.. function:: getservbyport(port[, protocolname]) + + Translate an Internet port number and protocol name to a service name for that + service. The optional protocol name, if given, should be ``'tcp'`` or + ``'udp'``, otherwise any protocol will match. + + +.. function:: socket([family[, type[, proto]]]) + + Create a new socket using the given address family, socket type and protocol + number. The address family should be :const:`AF_INET` (the default), + :const:`AF_INET6` or :const:`AF_UNIX`. The socket type should be + :const:`SOCK_STREAM` (the default), :const:`SOCK_DGRAM` or perhaps one of the + other ``SOCK_`` constants. The protocol number is usually zero and may be + omitted in that case. + + +.. function:: socketpair([family[, type[, proto]]]) + + Build a pair of connected socket objects using the given address family, socket + type, and protocol number. Address family, socket type, and protocol number are + as for the :func:`socket` function above. The default family is :const:`AF_UNIX` + if defined on the platform; otherwise, the default is :const:`AF_INET`. + Availability: Unix. + + .. versionadded:: 2.4 + + +.. function:: fromfd(fd, family, type[, proto]) + + Duplicate the file descriptor *fd* (an integer as returned by a file object's + :meth:`fileno` method) and build a socket object from the result. Address + family, socket type and protocol number are as for the :func:`socket` function + above. The file descriptor should refer to a socket, but this is not checked --- + subsequent operations on the object may fail if the file descriptor is invalid. + This function is rarely needed, but can be used to get or set socket options on + a socket passed to a program as standard input or output (such as a server + started by the Unix inet daemon). The socket is assumed to be in blocking mode. + Availability: Unix. + + +.. function:: ntohl(x) + + Convert 32-bit positive integers from network to host byte order. On machines + where the host byte order is the same as network byte order, this is a no-op; + otherwise, it performs a 4-byte swap operation. + + +.. function:: ntohs(x) + + Convert 16-bit positive integers from network to host byte order. On machines + where the host byte order is the same as network byte order, this is a no-op; + otherwise, it performs a 2-byte swap operation. + + +.. function:: htonl(x) + + Convert 32-bit positive integers from host to network byte order. On machines + where the host byte order is the same as network byte order, this is a no-op; + otherwise, it performs a 4-byte swap operation. + + +.. function:: htons(x) + + Convert 16-bit positive integers from host to network byte order. On machines + where the host byte order is the same as network byte order, this is a no-op; + otherwise, it performs a 2-byte swap operation. + + +.. function:: inet_aton(ip_string) + + Convert an IPv4 address from dotted-quad string format (for example, + '123.45.67.89') to 32-bit packed binary format, as a string four characters in + length. This is useful when conversing with a program that uses the standard C + library and needs objects of type :ctype:`struct in_addr`, which is the C type + for the 32-bit packed binary this function returns. + + If the IPv4 address string passed to this function is invalid, + :exc:`socket.error` will be raised. Note that exactly what is valid depends on + the underlying C implementation of :cfunc:`inet_aton`. + + :func:`inet_aton` does not support IPv6, and :func:`getnameinfo` should be used + instead for IPv4/v6 dual stack support. + + +.. function:: inet_ntoa(packed_ip) + + Convert a 32-bit packed IPv4 address (a string four characters in length) to its + standard dotted-quad string representation (for example, '123.45.67.89'). This + is useful when conversing with a program that uses the standard C library and + needs objects of type :ctype:`struct in_addr`, which is the C type for the + 32-bit packed binary data this function takes as an argument. + + If the string passed to this function is not exactly 4 bytes in length, + :exc:`socket.error` will be raised. :func:`inet_ntoa` does not support IPv6, and + :func:`getnameinfo` should be used instead for IPv4/v6 dual stack support. + + +.. function:: inet_pton(address_family, ip_string) + + Convert an IP address from its family-specific string format to a packed, binary + format. :func:`inet_pton` is useful when a library or network protocol calls for + an object of type :ctype:`struct in_addr` (similar to :func:`inet_aton`) or + :ctype:`struct in6_addr`. + + Supported values for *address_family* are currently :const:`AF_INET` and + :const:`AF_INET6`. If the IP address string *ip_string* is invalid, + :exc:`socket.error` will be raised. Note that exactly what is valid depends on + both the value of *address_family* and the underlying implementation of + :cfunc:`inet_pton`. + + Availability: Unix (maybe not all platforms). + + .. versionadded:: 2.3 + + +.. function:: inet_ntop(address_family, packed_ip) + + Convert a packed IP address (a string of some number of characters) to its + standard, family-specific string representation (for example, ``'7.10.0.5'`` or + ``'5aef:2b::8'``) :func:`inet_ntop` is useful when a library or network protocol + returns an object of type :ctype:`struct in_addr` (similar to :func:`inet_ntoa`) + or :ctype:`struct in6_addr`. + + Supported values for *address_family* are currently :const:`AF_INET` and + :const:`AF_INET6`. If the string *packed_ip* is not the correct length for the + specified address family, :exc:`ValueError` will be raised. A + :exc:`socket.error` is raised for errors from the call to :func:`inet_ntop`. + + Availability: Unix (maybe not all platforms). + + .. versionadded:: 2.3 + + +.. function:: getdefaulttimeout() + + Return the default timeout in floating seconds for new socket objects. A value + of ``None`` indicates that new socket objects have no timeout. When the socket + module is first imported, the default is ``None``. + + .. versionadded:: 2.3 + + +.. function:: setdefaulttimeout(timeout) + + Set the default timeout in floating seconds for new socket objects. A value of + ``None`` indicates that new socket objects have no timeout. When the socket + module is first imported, the default is ``None``. + + .. versionadded:: 2.3 + + +.. data:: SocketType + + This is a Python type object that represents the socket object type. It is the + same as ``type(socket(...))``. + + +.. seealso:: + + Module :mod:`SocketServer` + Classes that simplify writing network servers. + + +.. _socket-objects: + +Socket Objects +-------------- + +Socket objects have the following methods. Except for :meth:`makefile` these +correspond to Unix system calls applicable to sockets. + + +.. method:: socket.accept() + + Accept a connection. The socket must be bound to an address and listening for + connections. The return value is a pair ``(conn, address)`` where *conn* is a + *new* socket object usable to send and receive data on the connection, and + *address* is the address bound to the socket on the other end of the connection. + + +.. method:: socket.bind(address) + + Bind the socket to *address*. The socket must not already be bound. (The format + of *address* depends on the address family --- see above.) + + .. note:: + + This method has historically accepted a pair of parameters for :const:`AF_INET` + addresses instead of only a tuple. This was never intentional and is no longer + available in Python 2.0 and later. + + +.. method:: socket.close() + + Close the socket. All future operations on the socket object will fail. The + remote end will receive no more data (after queued data is flushed). Sockets are + automatically closed when they are garbage-collected. + + +.. method:: socket.connect(address) + + Connect to a remote socket at *address*. (The format of *address* depends on the + address family --- see above.) + + .. note:: + + This method has historically accepted a pair of parameters for :const:`AF_INET` + addresses instead of only a tuple. This was never intentional and is no longer + available in Python 2.0 and later. + + +.. method:: socket.connect_ex(address) + + Like ``connect(address)``, but return an error indicator instead of raising an + exception for errors returned by the C-level :cfunc:`connect` call (other + problems, such as "host not found," can still raise exceptions). The error + indicator is ``0`` if the operation succeeded, otherwise the value of the + :cdata:`errno` variable. This is useful to support, for example, asynchronous + connects. + + .. note:: + + This method has historically accepted a pair of parameters for :const:`AF_INET` + addresses instead of only a tuple. This was never intentional and is no longer + available in Python 2.0 and later. + + +.. method:: socket.fileno() + + Return the socket's file descriptor (a small integer). This is useful with + :func:`select.select`. + + Under Windows the small integer returned by this method cannot be used where a + file descriptor can be used (such as :func:`os.fdopen`). Unix does not have + this limitation. + + +.. method:: socket.getpeername() + + Return the remote address to which the socket is connected. This is useful to + find out the port number of a remote IPv4/v6 socket, for instance. (The format + of the address returned depends on the address family --- see above.) On some + systems this function is not supported. + + +.. method:: socket.getsockname() + + Return the socket's own address. This is useful to find out the port number of + an IPv4/v6 socket, for instance. (The format of the address returned depends on + the address family --- see above.) + + +.. method:: socket.getsockopt(level, optname[, buflen]) + + Return the value of the given socket option (see the Unix man page + :manpage:`getsockopt(2)`). The needed symbolic constants (:const:`SO_\*` etc.) + are defined in this module. If *buflen* is absent, an integer option is assumed + and its integer value is returned by the function. If *buflen* is present, it + specifies the maximum length of the buffer used to receive the option in, and + this buffer is returned as a string. It is up to the caller to decode the + contents of the buffer (see the optional built-in module :mod:`struct` for a way + to decode C structures encoded as strings). + + +.. method:: socket.ioctl(control, option) + + :platform: Windows + + The `meth:ioctl` method is a limited interface to the WSAIoctl system + interface. Please refer to the MSDN documentation for more information. + + .. versionadded:: 2.6 + + +.. method:: socket.listen(backlog) + + Listen for connections made to the socket. The *backlog* argument specifies the + maximum number of queued connections and should be at least 1; the maximum value + is system-dependent (usually 5). + + +.. method:: socket.makefile([mode[, bufsize]]) + + .. index:: single: I/O control; buffering + + Return a :dfn:`file object` associated with the socket. (File objects are + described in :ref:`bltin-file-objects`.) The file object + references a :cfunc:`dup`\ ped version of the socket file descriptor, so the + file object and socket object may be closed or garbage-collected independently. + The socket must be in blocking mode (it can not have a timeout). The optional + *mode* and *bufsize* arguments are interpreted the same way as by the built-in + :func:`file` function. + + +.. method:: socket.recv(bufsize[, flags]) + + Receive data from the socket. The return value is a string representing the + data received. The maximum amount of data to be received at once is specified + by *bufsize*. See the Unix manual page :manpage:`recv(2)` for the meaning of + the optional argument *flags*; it defaults to zero. + + .. note:: + + For best match with hardware and network realities, the value of *bufsize* + should be a relatively small power of 2, for example, 4096. + + +.. method:: socket.recvfrom(bufsize[, flags]) + + Receive data from the socket. The return value is a pair ``(string, address)`` + where *string* is a string representing the data received and *address* is the + address of the socket sending the data. See the Unix manual page + :manpage:`recv(2)` for the meaning of the optional argument *flags*; it defaults + to zero. (The format of *address* depends on the address family --- see above.) + + +.. method:: socket.recvfrom_into(buffer[, nbytes[, flags]]) + + Receive data from the socket, writing it into *buffer* instead of creating a + new string. The return value is a pair ``(nbytes, address)`` where *nbytes* is + the number of bytes received and *address* is the address of the socket sending + the data. See the Unix manual page :manpage:`recv(2)` for the meaning of the + optional argument *flags*; it defaults to zero. (The format of *address* + depends on the address family --- see above.) + + .. versionadded:: 2.5 + + +.. method:: socket.recv_into(buffer[, nbytes[, flags]]) + + Receive up to *nbytes* bytes from the socket, storing the data into a buffer + rather than creating a new string. If *nbytes* is not specified (or 0), + receive up to the size available in the given buffer. See the Unix manual page + :manpage:`recv(2)` for the meaning of the optional argument *flags*; it defaults + to zero. + + .. versionadded:: 2.5 + + +.. method:: socket.send(string[, flags]) + + Send data to the socket. The socket must be connected to a remote socket. The + optional *flags* argument has the same meaning as for :meth:`recv` above. + Returns the number of bytes sent. Applications are responsible for checking that + all data has been sent; if only some of the data was transmitted, the + application needs to attempt delivery of the remaining data. + + +.. method:: socket.sendall(string[, flags]) + + Send data to the socket. The socket must be connected to a remote socket. The + optional *flags* argument has the same meaning as for :meth:`recv` above. + Unlike :meth:`send`, this method continues to send data from *string* until + either all data has been sent or an error occurs. ``None`` is returned on + success. On error, an exception is raised, and there is no way to determine how + much data, if any, was successfully sent. + + +.. method:: socket.sendto(string[, flags], address) + + Send data to the socket. The socket should not be connected to a remote socket, + since the destination socket is specified by *address*. The optional *flags* + argument has the same meaning as for :meth:`recv` above. Return the number of + bytes sent. (The format of *address* depends on the address family --- see + above.) + + +.. method:: socket.setblocking(flag) + + Set blocking or non-blocking mode of the socket: if *flag* is 0, the socket is + set to non-blocking, else to blocking mode. Initially all sockets are in + blocking mode. In non-blocking mode, if a :meth:`recv` call doesn't find any + data, or if a :meth:`send` call can't immediately dispose of the data, a + :exc:`error` exception is raised; in blocking mode, the calls block until they + can proceed. ``s.setblocking(0)`` is equivalent to ``s.settimeout(0)``; + ``s.setblocking(1)`` is equivalent to ``s.settimeout(None)``. + + +.. method:: socket.settimeout(value) + + Set a timeout on blocking socket operations. The *value* argument can be a + nonnegative float expressing seconds, or ``None``. If a float is given, + subsequent socket operations will raise an :exc:`timeout` exception if the + timeout period *value* has elapsed before the operation has completed. Setting + a timeout of ``None`` disables timeouts on socket operations. + ``s.settimeout(0.0)`` is equivalent to ``s.setblocking(0)``; + ``s.settimeout(None)`` is equivalent to ``s.setblocking(1)``. + + .. versionadded:: 2.3 + + +.. method:: socket.gettimeout() + + Return the timeout in floating seconds associated with socket operations, or + ``None`` if no timeout is set. This reflects the last call to + :meth:`setblocking` or :meth:`settimeout`. + + .. versionadded:: 2.3 + +Some notes on socket blocking and timeouts: A socket object can be in one of +three modes: blocking, non-blocking, or timeout. Sockets are always created in +blocking mode. In blocking mode, operations block until complete. In +non-blocking mode, operations fail (with an error that is unfortunately +system-dependent) if they cannot be completed immediately. In timeout mode, +operations fail if they cannot be completed within the timeout specified for the +socket. The :meth:`setblocking` method is simply a shorthand for certain +:meth:`settimeout` calls. + +Timeout mode internally sets the socket in non-blocking mode. The blocking and +timeout modes are shared between file descriptors and socket objects that refer +to the same network endpoint. A consequence of this is that file objects +returned by the :meth:`makefile` method must only be used when the socket is in +blocking mode; in timeout or non-blocking mode file operations that cannot be +completed immediately will fail. + +Note that the :meth:`connect` operation is subject to the timeout setting, and +in general it is recommended to call :meth:`settimeout` before calling +:meth:`connect`. + + +.. method:: socket.setsockopt(level, optname, value) + + .. index:: module: struct + + Set the value of the given socket option (see the Unix manual page + :manpage:`setsockopt(2)`). The needed symbolic constants are defined in the + :mod:`socket` module (:const:`SO_\*` etc.). The value can be an integer or a + string representing a buffer. In the latter case it is up to the caller to + ensure that the string contains the proper bits (see the optional built-in + module :mod:`struct` for a way to encode C structures as strings). + + +.. method:: socket.shutdown(how) + + Shut down one or both halves of the connection. If *how* is :const:`SHUT_RD`, + further receives are disallowed. If *how* is :const:`SHUT_WR`, further sends + are disallowed. If *how* is :const:`SHUT_RDWR`, further sends and receives are + disallowed. + +Note that there are no methods :meth:`read` or :meth:`write`; use :meth:`recv` +and :meth:`send` without *flags* argument instead. + +Socket objects also have these (read-only) attributes that correspond to the +values given to the :class:`socket` constructor. + + +.. attribute:: socket.family + + The socket family. + + .. versionadded:: 2.5 + + +.. attribute:: socket.type + + The socket type. + + .. versionadded:: 2.5 + + +.. attribute:: socket.proto + + The socket protocol. + + .. versionadded:: 2.5 + + +.. _socket-example: + +Example +------- + +Here are four minimal example programs using the TCP/IP protocol: a server that +echoes all data that it receives back (servicing only one client), and a client +using it. Note that a server must perform the sequence :func:`socket`, +:meth:`bind`, :meth:`listen`, :meth:`accept` (possibly repeating the +:meth:`accept` to service more than one client), while a client only needs the +sequence :func:`socket`, :meth:`connect`. Also note that the server does not +:meth:`send`/:meth:`recv` on the socket it is listening on but on the new +socket returned by :meth:`accept`. + +The first two examples support IPv4 only. :: + + # Echo server program + import socket + + HOST = '' # Symbolic name meaning the local host + PORT = 50007 # Arbitrary non-privileged port + s = socket.socket(socket.AF_INET, socket.SOCK_STREAM) + s.bind((HOST, PORT)) + s.listen(1) + conn, addr = s.accept() + print 'Connected by', addr + while 1: + data = conn.recv(1024) + if not data: break + conn.send(data) + conn.close() + +:: + + # Echo client program + import socket + + HOST = 'daring.cwi.nl' # The remote host + PORT = 50007 # The same port as used by the server + s = socket.socket(socket.AF_INET, socket.SOCK_STREAM) + s.connect((HOST, PORT)) + s.send('Hello, world') + data = s.recv(1024) + s.close() + print 'Received', repr(data) + +The next two examples are identical to the above two, but support both IPv4 and +IPv6. The server side will listen to the first address family available (it +should listen to both instead). On most of IPv6-ready systems, IPv6 will take +precedence and the server may not accept IPv4 traffic. The client side will try +to connect to the all addresses returned as a result of the name resolution, and +sends traffic to the first one connected successfully. :: + + # Echo server program + import socket + import sys + + HOST = '' # Symbolic name meaning the local host + PORT = 50007 # Arbitrary non-privileged port + s = None + for res in socket.getaddrinfo(HOST, PORT, socket.AF_UNSPEC, socket.SOCK_STREAM, 0, socket.AI_PASSIVE): + af, socktype, proto, canonname, sa = res + try: + s = socket.socket(af, socktype, proto) + except socket.error, msg: + s = None + continue + try: + s.bind(sa) + s.listen(1) + except socket.error, msg: + s.close() + s = None + continue + break + if s is None: + print 'could not open socket' + sys.exit(1) + conn, addr = s.accept() + print 'Connected by', addr + while 1: + data = conn.recv(1024) + if not data: break + conn.send(data) + conn.close() + +:: + + # Echo client program + import socket + import sys + + HOST = 'daring.cwi.nl' # The remote host + PORT = 50007 # The same port as used by the server + s = None + for res in socket.getaddrinfo(HOST, PORT, socket.AF_UNSPEC, socket.SOCK_STREAM): + af, socktype, proto, canonname, sa = res + try: + s = socket.socket(af, socktype, proto) + except socket.error, msg: + s = None + continue + try: + s.connect(sa) + except socket.error, msg: + s.close() + s = None + continue + break + if s is None: + print 'could not open socket' + sys.exit(1) + s.send('Hello, world') + data = s.recv(1024) + s.close() + print 'Received', repr(data) + + +The last example shows how to write a very simple network sniffer with raw +sockets on Windows. The example requires administrator priviliges to modify +the interface:: + + import socket + + # the public network interface + HOST = socket.gethostbyname(socket.gethostname()) + + # create a raw socket and bind it to the public interface + s = socket.socket(socket.AF_INET, socket.SOCK_RAW, socket.IPPROTO_IP) + s.bind((HOST, 0)) + + # Include IP headers + s.setsockopt(socket.IPPROTO_IP, socket.IP_HDRINCL, 1) + + # receive all packages + s.ioctl(socket.SIO_RCVALL, socket.RCVALL_ON) + + # receive a package + print s.recvfrom(65565) + + # disabled promiscous mode + s.ioctl(socket.SIO_RCVALL, socket.RCVALL_OFF) Modified: python/trunk/Lib/socket.py ============================================================================== --- python/trunk/Lib/socket.py (original) +++ python/trunk/Lib/socket.py Fri Jan 4 16:23:30 2008 @@ -141,7 +141,7 @@ 'bind', 'connect', 'connect_ex', 'fileno', 'listen', 'getpeername', 'getsockname', 'getsockopt', 'setsockopt', 'sendall', 'setblocking', - 'settimeout', 'gettimeout', 'shutdown') + 'settimeout', 'gettimeout', 'shutdown', 'ioctl') if sys.platform == "riscos": _socketmethods = _socketmethods + ('sleeptaskw',) Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Fri Jan 4 16:23:30 2008 @@ -920,6 +920,9 @@ Extension Modules ----------------- +- Added interface for Windows' WSAIoctl to socket object and added an example + for a simple network sniffer. + - Bug #1301: Bad assert in _tkinter fixed. - Added bdist_wininst executable for VS 2008. Modified: python/trunk/Modules/socketmodule.c ============================================================================== --- python/trunk/Modules/socketmodule.c (original) +++ python/trunk/Modules/socketmodule.c Fri Jan 4 16:23:30 2008 @@ -2687,6 +2687,31 @@ Shut down the reading side of the socket (flag == SHUT_RD), the writing side\n\ of the socket (flag == SHUT_WR), or both ends (flag == SHUT_RDWR)."); +#ifdef MS_WINDOWS +static PyObject* +sock_ioctl(PySocketSockObject *s, PyObject *arg) +{ + unsigned long cmd = SIO_RCVALL; + unsigned int option = RCVALL_ON; + DWORD recv; + + if (!PyArg_ParseTuple(arg, "kI:ioctl", &cmd, &option)) + return NULL; + + if (WSAIoctl(s->sock_fd, cmd, &option, sizeof(option), + NULL, 0, &recv, NULL, NULL) == SOCKET_ERROR) { + return set_error(); + } + return PyLong_FromUnsignedLong(recv); +} +PyDoc_STRVAR(sock_ioctl_doc, +"ioctl(cmd, option) -> long\n\ +\n\ +Control the socket with WSAIoctl syscall. Currently only socket.SIO_RCVALL\n\ +is supported as control. Options must be one of the socket.RCVALL_*\n\ +constants."); + +#endif /* List of methods for socket objects */ @@ -2715,6 +2740,10 @@ METH_NOARGS, getsockname_doc}, {"getsockopt", (PyCFunction)sock_getsockopt, METH_VARARGS, getsockopt_doc}, +#ifdef MS_WINDOWS + {"ioctl", (PyCFunction)sock_ioctl, METH_VARARGS, + sock_ioctl_doc}, +#endif {"listen", (PyCFunction)sock_listen, METH_O, listen_doc}, #ifndef NO_DUP @@ -4194,7 +4223,7 @@ PyMODINIT_FUNC init_socket(void) { - PyObject *m, *has_ipv6; + PyObject *m, *has_ipv6, *tmp; if (!os_init()) return; @@ -5033,6 +5062,18 @@ PyModule_AddIntConstant(m, "SHUT_RDWR", 2); #endif +#ifdef SIO_RCVALL + tmp = PyLong_FromUnsignedLong(SIO_RCVALL); + if (tmp == NULL) + return; + PyModule_AddObject(m, "SIO_RCVALL", tmp); + PyModule_AddIntConstant(m, "RCVALL_OFF", RCVALL_OFF); + PyModule_AddIntConstant(m, "RCVALL_ON", RCVALL_ON); + PyModule_AddIntConstant(m, "RCVALL_SOCKETLEVELONLY", RCVALL_SOCKETLEVELONLY); + PyModule_AddIntConstant(m, "RCVALL_IPLEVEL", RCVALL_IPLEVEL); + PyModule_AddIntConstant(m, "RCVALL_MAX", RCVALL_MAX); +#endif /* _MSTCPIP_ */ + /* Initialize gethostbyname lock */ #if defined(USE_GETHOSTBYNAME_LOCK) || defined(USE_GETADDRINFO_LOCK) netdb_lock = PyThread_allocate_lock(); Modified: python/trunk/Modules/socketmodule.h ============================================================================== --- python/trunk/Modules/socketmodule.h (original) +++ python/trunk/Modules/socketmodule.h Fri Jan 4 16:23:30 2008 @@ -16,6 +16,7 @@ #if _MSC_VER >= 1300 # include # include +# include /* for SIO_RCVALL */ # define HAVE_ADDRINFO # define HAVE_SOCKADDR_STORAGE # define HAVE_GETADDRINFO From python-checkins at python.org Fri Jan 4 16:29:01 2008 From: python-checkins at python.org (christian.heimes) Date: Fri, 4 Jan 2008 16:29:01 +0100 (CET) Subject: [Python-checkins] r59717 - python/trunk/PC/VC6/_msi.dsp python/trunk/PC/VC6/build_ssl.py python/trunk/PC/VC6/pcbuild.dsw python/trunk/PC/VC6/python.dsp python/trunk/PC/VC6/pythoncore.dsp python/trunk/PC/VC6/readme.txt Message-ID: <20080104152901.6595B1E4010@bag.python.org> Author: christian.heimes Date: Fri Jan 4 16:29:00 2008 New Revision: 59717 Added: python/trunk/PC/VC6/_msi.dsp (contents, props changed) Modified: python/trunk/PC/VC6/build_ssl.py python/trunk/PC/VC6/pcbuild.dsw python/trunk/PC/VC6/python.dsp python/trunk/PC/VC6/pythoncore.dsp python/trunk/PC/VC6/readme.txt Log: And here is the rest of Hirokazu Yamamoto's patch for VS6.0 support. Thanks Hiro! Added: python/trunk/PC/VC6/_msi.dsp ============================================================================== --- (empty file) +++ python/trunk/PC/VC6/_msi.dsp Fri Jan 4 16:29:00 2008 @@ -0,0 +1,99 @@ +# Microsoft Developer Studio Project File - Name="_msi" - Package Owner=<4> +# Microsoft Developer Studio Generated Build File, Format Version 6.00 +# ** DO NOT EDIT ** + +# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102 + +CFG=_msi - Win32 Debug +!MESSAGE This is not a valid makefile. To build this project using NMAKE, +!MESSAGE use the Export Makefile command and run +!MESSAGE +!MESSAGE NMAKE /f "_msi.mak". +!MESSAGE +!MESSAGE You can specify a configuration when running NMAKE +!MESSAGE by defining the macro CFG on the command line. For example: +!MESSAGE +!MESSAGE NMAKE /f "_msi.mak" CFG="_msi - Win32 Debug" +!MESSAGE +!MESSAGE Possible choices for configuration are: +!MESSAGE +!MESSAGE "_msi - Win32 Release" (based on "Win32 (x86) Dynamic-Link Library") +!MESSAGE "_msi - Win32 Debug" (based on "Win32 (x86) Dynamic-Link Library") +!MESSAGE + +# Begin Project +# PROP AllowPerConfigDependencies 0 +# PROP Scc_ProjName "_msi" +# PROP Scc_LocalPath ".." +CPP=cl.exe +MTL=midl.exe +RSC=rc.exe + +!IF "$(CFG)" == "_msi - Win32 Release" + +# PROP BASE Use_MFC 0 +# PROP BASE Use_Debug_Libraries 0 +# PROP BASE Output_Dir "Release" +# PROP BASE Intermediate_Dir "Release" +# PROP BASE Target_Dir "" +# PROP Use_MFC 0 +# PROP Use_Debug_Libraries 0 +# PROP Output_Dir "." +# PROP Intermediate_Dir "x86-temp-release\_msi" +# PROP Ignore_Export_Lib 0 +# PROP Target_Dir "" +F90=df.exe +# ADD BASE CPP /nologo /MT /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /YX /FD /c +# ADD CPP /nologo /MD /W3 /GX /Zi /O2 /I "..\..\Include" /I ".." /D "NDEBUG" /D "WIN32" /D "_WINDOWS" /YX /FD /c +# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /o "NUL" /win32 +# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /o "NUL" /win32 +# ADD BASE RSC /l 0x409 /d "NDEBUG" +# ADD RSC /l 0x409 /d "NDEBUG" +BSC32=bscmake.exe +# ADD BASE BSC32 /nologo +# ADD BSC32 /nologo +LINK32=link.exe +# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib fci.lib msi.lib rpcrt4.lib /nologo /subsystem:windows /dll /machine:I386 +# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib fci.lib msi.lib rpcrt4.lib /nologo /base:"0x1d1a0000" /subsystem:windows /dll /debug /machine:I386 /out:"./_msi.pyd" +# SUBTRACT LINK32 /pdb:none + +!ELSEIF "$(CFG)" == "_msi - Win32 Debug" + +# PROP BASE Use_MFC 0 +# PROP BASE Use_Debug_Libraries 1 +# PROP BASE Output_Dir "Debug" +# PROP BASE Intermediate_Dir "Debug" +# PROP BASE Target_Dir "" +# PROP Use_MFC 0 +# PROP Use_Debug_Libraries 1 +# PROP Output_Dir "." +# PROP Intermediate_Dir "x86-temp-debug\_msi" +# PROP Ignore_Export_Lib 0 +# PROP Target_Dir "" +F90=df.exe +# ADD BASE CPP /nologo /MTd /W3 /Gm /GX /Zi /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /YX /FD /c +# ADD CPP /nologo /MDd /W3 /Gm /GX /Zi /Od /I "..\..\Include" /I ".." /D "_DEBUG" /D "WIN32" /D "_WINDOWS" /YX /FD /c +# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /o "NUL" /win32 +# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /o "NUL" /win32 +# ADD BASE RSC /l 0x409 /d "_DEBUG" +# ADD RSC /l 0x409 /d "_DEBUG" +BSC32=bscmake.exe +# ADD BASE BSC32 /nologo +# ADD BSC32 /nologo +LINK32=link.exe +# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib fci.lib msi.lib rpcrt4.lib /nologo /subsystem:windows /dll /debug /machine:I386 /pdbtype:sept +# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib fci.lib msi.lib rpcrt4.lib /nologo /base:"0x1d1a0000" /subsystem:windows /dll /debug /machine:I386 /out:"./_msi_d.pyd" /pdbtype:sept +# SUBTRACT LINK32 /pdb:none + +!ENDIF + +# Begin Target + +# Name "_msi - Win32 Release" +# Name "_msi - Win32 Debug" +# Begin Source File + +SOURCE=..\..\PC\_msi.c +# End Source File +# End Target +# End Project Modified: python/trunk/PC/VC6/build_ssl.py ============================================================================== --- python/trunk/PC/VC6/build_ssl.py (original) +++ python/trunk/PC/VC6/build_ssl.py Fri Jan 4 16:29:00 2008 @@ -8,7 +8,7 @@ # directory. It is likely you will already find the zlib library and # any other external packages there. # * Install ActivePerl and ensure it is somewhere on your path. -# * Run this script from the PCBuild directory. +# * Run this script from the PC/VC6 directory. # # it should configure and build SSL, then build the ssl Python extension # without intervention. Modified: python/trunk/PC/VC6/pcbuild.dsw ============================================================================== --- python/trunk/PC/VC6/pcbuild.dsw (original) +++ python/trunk/PC/VC6/pcbuild.dsw Fri Jan 4 16:29:00 2008 @@ -57,6 +57,21 @@ ############################################################################### +Project: "_msi"=".\_msi.dsp" - Package Owner=<4> + +Package=<5> +{{{ +}}} + +Package=<4> +{{{ + Begin Project Dependency + Project_Dep_Name pythoncore + End Project Dependency +}}} + +############################################################################### + Project: "_socket"=".\_socket.dsp" - Package Owner=<4> Package=<5> @@ -288,3 +303,4 @@ ############################################################################### + Modified: python/trunk/PC/VC6/python.dsp ============================================================================== --- python/trunk/PC/VC6/python.dsp (original) +++ python/trunk/PC/VC6/python.dsp Fri Jan 4 16:29:00 2008 @@ -77,6 +77,11 @@ # ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept # ADD LINK32 odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib /nologo /base:"0x1d000000" /subsystem:console /debug /machine:I386 /out:"./python_d.exe" /pdbtype:sept # SUBTRACT LINK32 /pdb:none +# Begin Special Build Tool +SOURCE="$(InputPath)" +PostBuild_Desc=Changing stack size... +PostBuild_Cmds=editbin /STACK:0x200000 python_d.exe +# End Special Build Tool !ENDIF Modified: python/trunk/PC/VC6/pythoncore.dsp ============================================================================== --- python/trunk/PC/VC6/pythoncore.dsp (original) +++ python/trunk/PC/VC6/pythoncore.dsp Fri Jan 4 16:29:00 2008 @@ -54,7 +54,7 @@ # ADD BSC32 /nologo LINK32=link.exe # ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /dll /machine:I386 -# ADD LINK32 largeint.lib kernel32.lib user32.lib advapi32.lib shell32.lib /nologo /base:"0x1e000000" /subsystem:windows /dll /debug /machine:I386 /nodefaultlib:"libc" /out:"./python26.dll" +# ADD LINK32 largeint.lib kernel32.lib user32.lib advapi32.lib shell32.lib /nologo /base:"0x1e000000" /subsystem:windows /dll /debug /machine:I386 /nodefaultlib:"libc" /out:"./python30.dll" # SUBTRACT LINK32 /pdb:none !ELSEIF "$(CFG)" == "pythoncore - Win32 Debug" @@ -82,7 +82,7 @@ # ADD BSC32 /nologo LINK32=link.exe # ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /dll /debug /machine:I386 /pdbtype:sept -# ADD LINK32 largeint.lib kernel32.lib user32.lib advapi32.lib shell32.lib /nologo /base:"0x1e000000" /subsystem:windows /dll /debug /machine:I386 /nodefaultlib:"libc" /out:"./python26_d.dll" /pdbtype:sept +# ADD LINK32 largeint.lib kernel32.lib user32.lib advapi32.lib shell32.lib /nologo /base:"0x1e000000" /subsystem:windows /dll /debug /machine:I386 /nodefaultlib:"libc" /out:"./python30_d.dll" /pdbtype:sept # SUBTRACT LINK32 /pdb:none !ENDIF @@ -129,15 +129,15 @@ # End Source File # Begin Source File -SOURCE=..\..\Modules\_functoolsmodule.c +SOURCE=..\..\Modules\_fileio.c # End Source File # Begin Source File -SOURCE=..\..\Modules\_heapqmodule.c +SOURCE=..\..\Modules\_functoolsmodule.c # End Source File # Begin Source File -SOURCE=..\..\Modules\_hotshot.c +SOURCE=..\..\Modules\_heapqmodule.c # End Source File # Begin Source File @@ -201,6 +201,10 @@ # End Source File # Begin Source File +SOURCE=..\..\Modules\atexitmodule.c +# End Source File +# Begin Source File + SOURCE=..\..\Modules\audioop.c # End Source File # Begin Source File @@ -221,7 +225,11 @@ # End Source File # Begin Source File -SOURCE=..\..\Objects\bufferobject.c +SOURCE=..\..\Objects\bytes_methods.c +# End Source File +# Begin Source File + +SOURCE=..\..\Objects\bytesobject.c # End Source File # Begin Source File @@ -253,7 +261,7 @@ # End Source File # Begin Source File -SOURCE=..\..\Modules\collectionsmodule.c +SOURCE=..\..\Modules\_collectionsmodule.c # End Source File # Begin Source File @@ -273,10 +281,6 @@ # End Source File # Begin Source File -SOURCE=..\..\Modules\cPickle.c -# End Source File -# Begin Source File - SOURCE=..\..\Modules\zlib\crc32.c # End Source File # Begin Source File @@ -293,6 +297,14 @@ # End Source File # Begin Source File +SOURCE=..\..\Modules\zlib\gzio.c +# End Source File +# Begin Source File + +SOURCE=..\..\Modules\zlib\infback.c +# End Source File +# Begin Source File + SOURCE=..\..\Objects\descrobject.c # End Source File # Begin Source File @@ -329,6 +341,10 @@ # End Source File # Begin Source File +SOURCE=..\..\Parser\firstsets.c +# End Source File +# Begin Source File + SOURCE=..\..\Objects\floatobject.c # End Source File # Begin Source File @@ -337,6 +353,10 @@ # End Source File # Begin Source File +SOURCE=..\..\Python\formatter_unicode.c +# End Source File +# Begin Source File + SOURCE=..\..\Python\frozen.c # End Source File # Begin Source File @@ -398,11 +418,11 @@ # End Source File # Begin Source File -SOURCE=..\..\Parser\grammar1.c +SOURCE=..\..\Parser\grammar.c # End Source File # Begin Source File -SOURCE=..\..\Modules\imageop.c +SOURCE=..\..\Parser\grammar1.c # End Source File # Begin Source File @@ -431,10 +451,6 @@ # End Source File # Begin Source File -SOURCE=..\..\Objects\intobject.c -# End Source File -# Begin Source File - SOURCE=..\..\Objects\iterobject.c # End Source File # Begin Source File @@ -467,15 +483,15 @@ # End Source File # Begin Source File -SOURCE=..\..\Modules\md5.c +SOURCE=..\..\Modules\md5module.c # End Source File # Begin Source File -SOURCE=..\..\Modules\md5module.c +SOURCE=..\..\Parser\metagrammar.c # End Source File # Begin Source File -SOURCE=..\..\Parser\metagrammar.c +SOURCE=..\..\Objects\memoryobject.c # End Source File # Begin Source File @@ -563,6 +579,10 @@ # End Source File # Begin Source File +SOURCE=..\..\Python\pystrcmp.c +# End Source File +# Begin Source File + SOURCE=..\..\Python\pystrtod.c # End Source File # Begin Source File @@ -583,10 +603,6 @@ # End Source File # Begin Source File -SOURCE=..\..\Modules\rgbimgmodule.c -# End Source File -# Begin Source File - SOURCE=..\..\Modules\rotatingtree.c # End Source File # Begin Source File @@ -603,7 +619,7 @@ # End Source File # Begin Source File -SOURCE=..\..\Modules\shamodule.c +SOURCE=..\..\Modules\sha1module.c # End Source File # Begin Source File @@ -619,10 +635,6 @@ # End Source File # Begin Source File -SOURCE=..\..\Modules\stropmodule.c -# End Source File -# Begin Source File - SOURCE=..\..\Python\structmember.c # End Source File # Begin Source File @@ -667,6 +679,10 @@ # End Source File # Begin Source File +SOURCE=..\..\Modules\zlib\uncompr.c +# End Source File +# Begin Source File + SOURCE=..\..\Objects\tupleobject.c # End Source File # Begin Source File Modified: python/trunk/PC/VC6/readme.txt ============================================================================== --- python/trunk/PC/VC6/readme.txt (original) +++ python/trunk/PC/VC6/readme.txt Fri Jan 4 16:29:00 2008 @@ -199,12 +199,10 @@ http://www.activestate.com/Products/ActivePerl/ as this is used by the OpenSSL build process. Complain to them . - The MSVC project simply invokes PCBuild/build_ssl.py to perform + The MSVC project simply invokes PC/VC6/build_ssl.py to perform the build. This Python script locates and builds your OpenSSL installation, then invokes a simple makefile to build the final .pyd. - Win9x users: see "Win9x note" below. - build_ssl.py attempts to catch the most common errors (such as not being able to find OpenSSL sources, or not being able to find a Perl that works with OpenSSL) and give a reasonable error message. @@ -216,30 +214,6 @@ build_ssl.py/MSVC isn't clever enough to clean OpenSSL - you must do this by hand. - Win9x note: If, near the start of the build process, you see - something like - - C:\Code\openssl-0.9.6g>set OPTS=no-asm - Out of environment space - - then you're in trouble, and will probably also see these errors near - the end of the process: - - NMAKE : fatal error U1073: don't know how to make - 'crypto\md5\asm\m5_win32.asm' - Stop. - NMAKE : fatal error U1073: don't know how to make - 'C:\Code\openssl-0.9.6g/out32/libeay32.lib' - Stop. - - You need more environment space. Win9x only has room for 256 bytes - by default, and especially after installing ActivePerl (which fiddles - the PATH envar), you're likely to run out. KB Q230205 - - http://support.microsoft.com/default.aspx?scid=KB;en-us;q230205 - - explains how to edit CONFIG.SYS to cure this. - YOUR OWN EXTENSION DLLs ----------------------- From python-checkins at python.org Fri Jan 4 16:29:19 2008 From: python-checkins at python.org (andrew.kuchling) Date: Fri, 4 Jan 2008 16:29:19 +0100 (CET) Subject: [Python-checkins] r59718 - sandbox/trunk/parrot Message-ID: <20080104152919.CE1311E4010@bag.python.org> Author: andrew.kuchling Date: Fri Jan 4 16:29:19 2008 New Revision: 59718 Removed: sandbox/trunk/parrot/ Log: Remove ancient parrot code; Parrot includes a different Python implementation today From buildbot at python.org Fri Jan 4 16:34:02 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 04 Jan 2008 15:34:02 +0000 Subject: [Python-checkins] buildbot failure in x86 gentoo trunk Message-ID: <20080104153402.9A1AD1E4010@bag.python.org> The Buildbot has detected a new failure of x86 gentoo trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20gentoo%20trunk/builds/2806 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-x86 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "./Lib/test/regrtest.py", line 167, in from test import test_support File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/test/test_support.py", line 8, in import socket File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/socket.py", line 166, in class _socketobject(object): File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/socket.py", line 211, in _socketobject exec _s % (_m, _m, _m, _m) File "", line 3, in AttributeError: type object '_socket.socket' has no attribute 'ioctl' make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Fri Jan 4 16:34:07 2008 From: python-checkins at python.org (christian.heimes) Date: Fri, 4 Jan 2008 16:34:07 +0100 (CET) Subject: [Python-checkins] r59719 - python/trunk/PC/VC6/_msi.dsp python/trunk/PC/VC6/build_ssl.py python/trunk/PC/VC6/pcbuild.dsw python/trunk/PC/VC6/python.dsp python/trunk/PC/VC6/pythoncore.dsp python/trunk/PC/VC6/readme.txt Message-ID: <20080104153407.2A2251E4011@bag.python.org> Author: christian.heimes Date: Fri Jan 4 16:34:06 2008 New Revision: 59719 Removed: python/trunk/PC/VC6/_msi.dsp Modified: python/trunk/PC/VC6/build_ssl.py python/trunk/PC/VC6/pcbuild.dsw python/trunk/PC/VC6/python.dsp python/trunk/PC/VC6/pythoncore.dsp python/trunk/PC/VC6/readme.txt Log: Reverted last transaction. It's the wrong branch. Deleted: /python/trunk/PC/VC6/_msi.dsp ============================================================================== --- /python/trunk/PC/VC6/_msi.dsp Fri Jan 4 16:34:06 2008 +++ (empty file) @@ -1,99 +0,0 @@ -# Microsoft Developer Studio Project File - Name="_msi" - Package Owner=<4> -# Microsoft Developer Studio Generated Build File, Format Version 6.00 -# ** DO NOT EDIT ** - -# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102 - -CFG=_msi - Win32 Debug -!MESSAGE This is not a valid makefile. To build this project using NMAKE, -!MESSAGE use the Export Makefile command and run -!MESSAGE -!MESSAGE NMAKE /f "_msi.mak". -!MESSAGE -!MESSAGE You can specify a configuration when running NMAKE -!MESSAGE by defining the macro CFG on the command line. For example: -!MESSAGE -!MESSAGE NMAKE /f "_msi.mak" CFG="_msi - Win32 Debug" -!MESSAGE -!MESSAGE Possible choices for configuration are: -!MESSAGE -!MESSAGE "_msi - Win32 Release" (based on "Win32 (x86) Dynamic-Link Library") -!MESSAGE "_msi - Win32 Debug" (based on "Win32 (x86) Dynamic-Link Library") -!MESSAGE - -# Begin Project -# PROP AllowPerConfigDependencies 0 -# PROP Scc_ProjName "_msi" -# PROP Scc_LocalPath ".." -CPP=cl.exe -MTL=midl.exe -RSC=rc.exe - -!IF "$(CFG)" == "_msi - Win32 Release" - -# PROP BASE Use_MFC 0 -# PROP BASE Use_Debug_Libraries 0 -# PROP BASE Output_Dir "Release" -# PROP BASE Intermediate_Dir "Release" -# PROP BASE Target_Dir "" -# PROP Use_MFC 0 -# PROP Use_Debug_Libraries 0 -# PROP Output_Dir "." -# PROP Intermediate_Dir "x86-temp-release\_msi" -# PROP Ignore_Export_Lib 0 -# PROP Target_Dir "" -F90=df.exe -# ADD BASE CPP /nologo /MT /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /YX /FD /c -# ADD CPP /nologo /MD /W3 /GX /Zi /O2 /I "..\..\Include" /I ".." /D "NDEBUG" /D "WIN32" /D "_WINDOWS" /YX /FD /c -# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /o "NUL" /win32 -# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /o "NUL" /win32 -# ADD BASE RSC /l 0x409 /d "NDEBUG" -# ADD RSC /l 0x409 /d "NDEBUG" -BSC32=bscmake.exe -# ADD BASE BSC32 /nologo -# ADD BSC32 /nologo -LINK32=link.exe -# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib fci.lib msi.lib rpcrt4.lib /nologo /subsystem:windows /dll /machine:I386 -# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib fci.lib msi.lib rpcrt4.lib /nologo /base:"0x1d1a0000" /subsystem:windows /dll /debug /machine:I386 /out:"./_msi.pyd" -# SUBTRACT LINK32 /pdb:none - -!ELSEIF "$(CFG)" == "_msi - Win32 Debug" - -# PROP BASE Use_MFC 0 -# PROP BASE Use_Debug_Libraries 1 -# PROP BASE Output_Dir "Debug" -# PROP BASE Intermediate_Dir "Debug" -# PROP BASE Target_Dir "" -# PROP Use_MFC 0 -# PROP Use_Debug_Libraries 1 -# PROP Output_Dir "." -# PROP Intermediate_Dir "x86-temp-debug\_msi" -# PROP Ignore_Export_Lib 0 -# PROP Target_Dir "" -F90=df.exe -# ADD BASE CPP /nologo /MTd /W3 /Gm /GX /Zi /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /YX /FD /c -# ADD CPP /nologo /MDd /W3 /Gm /GX /Zi /Od /I "..\..\Include" /I ".." /D "_DEBUG" /D "WIN32" /D "_WINDOWS" /YX /FD /c -# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /o "NUL" /win32 -# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /o "NUL" /win32 -# ADD BASE RSC /l 0x409 /d "_DEBUG" -# ADD RSC /l 0x409 /d "_DEBUG" -BSC32=bscmake.exe -# ADD BASE BSC32 /nologo -# ADD BSC32 /nologo -LINK32=link.exe -# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib fci.lib msi.lib rpcrt4.lib /nologo /subsystem:windows /dll /debug /machine:I386 /pdbtype:sept -# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib fci.lib msi.lib rpcrt4.lib /nologo /base:"0x1d1a0000" /subsystem:windows /dll /debug /machine:I386 /out:"./_msi_d.pyd" /pdbtype:sept -# SUBTRACT LINK32 /pdb:none - -!ENDIF - -# Begin Target - -# Name "_msi - Win32 Release" -# Name "_msi - Win32 Debug" -# Begin Source File - -SOURCE=..\..\PC\_msi.c -# End Source File -# End Target -# End Project Modified: python/trunk/PC/VC6/build_ssl.py ============================================================================== --- python/trunk/PC/VC6/build_ssl.py (original) +++ python/trunk/PC/VC6/build_ssl.py Fri Jan 4 16:34:06 2008 @@ -8,7 +8,7 @@ # directory. It is likely you will already find the zlib library and # any other external packages there. # * Install ActivePerl and ensure it is somewhere on your path. -# * Run this script from the PC/VC6 directory. +# * Run this script from the PCBuild directory. # # it should configure and build SSL, then build the ssl Python extension # without intervention. Modified: python/trunk/PC/VC6/pcbuild.dsw ============================================================================== --- python/trunk/PC/VC6/pcbuild.dsw (original) +++ python/trunk/PC/VC6/pcbuild.dsw Fri Jan 4 16:34:06 2008 @@ -57,21 +57,6 @@ ############################################################################### -Project: "_msi"=".\_msi.dsp" - Package Owner=<4> - -Package=<5> -{{{ -}}} - -Package=<4> -{{{ - Begin Project Dependency - Project_Dep_Name pythoncore - End Project Dependency -}}} - -############################################################################### - Project: "_socket"=".\_socket.dsp" - Package Owner=<4> Package=<5> @@ -303,4 +288,3 @@ ############################################################################### - Modified: python/trunk/PC/VC6/python.dsp ============================================================================== --- python/trunk/PC/VC6/python.dsp (original) +++ python/trunk/PC/VC6/python.dsp Fri Jan 4 16:34:06 2008 @@ -77,11 +77,6 @@ # ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept # ADD LINK32 odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib /nologo /base:"0x1d000000" /subsystem:console /debug /machine:I386 /out:"./python_d.exe" /pdbtype:sept # SUBTRACT LINK32 /pdb:none -# Begin Special Build Tool -SOURCE="$(InputPath)" -PostBuild_Desc=Changing stack size... -PostBuild_Cmds=editbin /STACK:0x200000 python_d.exe -# End Special Build Tool !ENDIF Modified: python/trunk/PC/VC6/pythoncore.dsp ============================================================================== --- python/trunk/PC/VC6/pythoncore.dsp (original) +++ python/trunk/PC/VC6/pythoncore.dsp Fri Jan 4 16:34:06 2008 @@ -54,7 +54,7 @@ # ADD BSC32 /nologo LINK32=link.exe # ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /dll /machine:I386 -# ADD LINK32 largeint.lib kernel32.lib user32.lib advapi32.lib shell32.lib /nologo /base:"0x1e000000" /subsystem:windows /dll /debug /machine:I386 /nodefaultlib:"libc" /out:"./python30.dll" +# ADD LINK32 largeint.lib kernel32.lib user32.lib advapi32.lib shell32.lib /nologo /base:"0x1e000000" /subsystem:windows /dll /debug /machine:I386 /nodefaultlib:"libc" /out:"./python26.dll" # SUBTRACT LINK32 /pdb:none !ELSEIF "$(CFG)" == "pythoncore - Win32 Debug" @@ -82,7 +82,7 @@ # ADD BSC32 /nologo LINK32=link.exe # ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /dll /debug /machine:I386 /pdbtype:sept -# ADD LINK32 largeint.lib kernel32.lib user32.lib advapi32.lib shell32.lib /nologo /base:"0x1e000000" /subsystem:windows /dll /debug /machine:I386 /nodefaultlib:"libc" /out:"./python30_d.dll" /pdbtype:sept +# ADD LINK32 largeint.lib kernel32.lib user32.lib advapi32.lib shell32.lib /nologo /base:"0x1e000000" /subsystem:windows /dll /debug /machine:I386 /nodefaultlib:"libc" /out:"./python26_d.dll" /pdbtype:sept # SUBTRACT LINK32 /pdb:none !ENDIF @@ -129,15 +129,15 @@ # End Source File # Begin Source File -SOURCE=..\..\Modules\_fileio.c +SOURCE=..\..\Modules\_functoolsmodule.c # End Source File # Begin Source File -SOURCE=..\..\Modules\_functoolsmodule.c +SOURCE=..\..\Modules\_heapqmodule.c # End Source File # Begin Source File -SOURCE=..\..\Modules\_heapqmodule.c +SOURCE=..\..\Modules\_hotshot.c # End Source File # Begin Source File @@ -201,10 +201,6 @@ # End Source File # Begin Source File -SOURCE=..\..\Modules\atexitmodule.c -# End Source File -# Begin Source File - SOURCE=..\..\Modules\audioop.c # End Source File # Begin Source File @@ -225,11 +221,7 @@ # End Source File # Begin Source File -SOURCE=..\..\Objects\bytes_methods.c -# End Source File -# Begin Source File - -SOURCE=..\..\Objects\bytesobject.c +SOURCE=..\..\Objects\bufferobject.c # End Source File # Begin Source File @@ -261,7 +253,7 @@ # End Source File # Begin Source File -SOURCE=..\..\Modules\_collectionsmodule.c +SOURCE=..\..\Modules\collectionsmodule.c # End Source File # Begin Source File @@ -281,6 +273,10 @@ # End Source File # Begin Source File +SOURCE=..\..\Modules\cPickle.c +# End Source File +# Begin Source File + SOURCE=..\..\Modules\zlib\crc32.c # End Source File # Begin Source File @@ -297,14 +293,6 @@ # End Source File # Begin Source File -SOURCE=..\..\Modules\zlib\gzio.c -# End Source File -# Begin Source File - -SOURCE=..\..\Modules\zlib\infback.c -# End Source File -# Begin Source File - SOURCE=..\..\Objects\descrobject.c # End Source File # Begin Source File @@ -341,10 +329,6 @@ # End Source File # Begin Source File -SOURCE=..\..\Parser\firstsets.c -# End Source File -# Begin Source File - SOURCE=..\..\Objects\floatobject.c # End Source File # Begin Source File @@ -353,10 +337,6 @@ # End Source File # Begin Source File -SOURCE=..\..\Python\formatter_unicode.c -# End Source File -# Begin Source File - SOURCE=..\..\Python\frozen.c # End Source File # Begin Source File @@ -418,11 +398,11 @@ # End Source File # Begin Source File -SOURCE=..\..\Parser\grammar.c +SOURCE=..\..\Parser\grammar1.c # End Source File # Begin Source File -SOURCE=..\..\Parser\grammar1.c +SOURCE=..\..\Modules\imageop.c # End Source File # Begin Source File @@ -451,6 +431,10 @@ # End Source File # Begin Source File +SOURCE=..\..\Objects\intobject.c +# End Source File +# Begin Source File + SOURCE=..\..\Objects\iterobject.c # End Source File # Begin Source File @@ -483,15 +467,15 @@ # End Source File # Begin Source File -SOURCE=..\..\Modules\md5module.c +SOURCE=..\..\Modules\md5.c # End Source File # Begin Source File -SOURCE=..\..\Parser\metagrammar.c +SOURCE=..\..\Modules\md5module.c # End Source File # Begin Source File -SOURCE=..\..\Objects\memoryobject.c +SOURCE=..\..\Parser\metagrammar.c # End Source File # Begin Source File @@ -579,10 +563,6 @@ # End Source File # Begin Source File -SOURCE=..\..\Python\pystrcmp.c -# End Source File -# Begin Source File - SOURCE=..\..\Python\pystrtod.c # End Source File # Begin Source File @@ -603,6 +583,10 @@ # End Source File # Begin Source File +SOURCE=..\..\Modules\rgbimgmodule.c +# End Source File +# Begin Source File + SOURCE=..\..\Modules\rotatingtree.c # End Source File # Begin Source File @@ -619,7 +603,7 @@ # End Source File # Begin Source File -SOURCE=..\..\Modules\sha1module.c +SOURCE=..\..\Modules\shamodule.c # End Source File # Begin Source File @@ -635,6 +619,10 @@ # End Source File # Begin Source File +SOURCE=..\..\Modules\stropmodule.c +# End Source File +# Begin Source File + SOURCE=..\..\Python\structmember.c # End Source File # Begin Source File @@ -679,10 +667,6 @@ # End Source File # Begin Source File -SOURCE=..\..\Modules\zlib\uncompr.c -# End Source File -# Begin Source File - SOURCE=..\..\Objects\tupleobject.c # End Source File # Begin Source File Modified: python/trunk/PC/VC6/readme.txt ============================================================================== --- python/trunk/PC/VC6/readme.txt (original) +++ python/trunk/PC/VC6/readme.txt Fri Jan 4 16:34:06 2008 @@ -199,10 +199,12 @@ http://www.activestate.com/Products/ActivePerl/ as this is used by the OpenSSL build process. Complain to them . - The MSVC project simply invokes PC/VC6/build_ssl.py to perform + The MSVC project simply invokes PCBuild/build_ssl.py to perform the build. This Python script locates and builds your OpenSSL installation, then invokes a simple makefile to build the final .pyd. + Win9x users: see "Win9x note" below. + build_ssl.py attempts to catch the most common errors (such as not being able to find OpenSSL sources, or not being able to find a Perl that works with OpenSSL) and give a reasonable error message. @@ -214,6 +216,30 @@ build_ssl.py/MSVC isn't clever enough to clean OpenSSL - you must do this by hand. + Win9x note: If, near the start of the build process, you see + something like + + C:\Code\openssl-0.9.6g>set OPTS=no-asm + Out of environment space + + then you're in trouble, and will probably also see these errors near + the end of the process: + + NMAKE : fatal error U1073: don't know how to make + 'crypto\md5\asm\m5_win32.asm' + Stop. + NMAKE : fatal error U1073: don't know how to make + 'C:\Code\openssl-0.9.6g/out32/libeay32.lib' + Stop. + + You need more environment space. Win9x only has room for 256 bytes + by default, and especially after installing ActivePerl (which fiddles + the PATH envar), you're likely to run out. KB Q230205 + + http://support.microsoft.com/default.aspx?scid=KB;en-us;q230205 + + explains how to edit CONFIG.SYS to cure this. + YOUR OWN EXTENSION DLLs ----------------------- From buildbot at python.org Fri Jan 4 16:34:35 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 04 Jan 2008 15:34:35 +0000 Subject: [Python-checkins] buildbot failure in ppc Debian unstable 3.0 Message-ID: <20080104153436.547CD1E4011@bag.python.org> The Buildbot has detected a new failure of ppc Debian unstable 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/ppc%20Debian%20unstable%203.0/builds/432 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_xmlrpc Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 522, in __init__ self.handle() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/BaseHTTPServer.py", line 330, in handle self.handle_one_request() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/BaseHTTPServer.py", line 324, in handle_one_request method() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SimpleXMLRPCServer.py", line 430, in do_POST self.report_404() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SimpleXMLRPCServer.py", line 489, in report_404 self.connection.shutdown(1) socket.error: [Errno 107] Transport endpoint is not connected ====================================================================== ERROR: test_fail_no_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/test/test_xmlrpc.py", line 497, in test_fail_no_info p.pow(6,8) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1091, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1349, in __request verbose=self.__verbose File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1121, in request resp = http_conn.getresponse() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/httplib.py", line 961, in getresponse response.begin() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/httplib.py", line 425, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/httplib.py", line 267, in readheaders line = str(self.fp.readline(), "iso-8859-1") File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/io.py", line 413, in readline b = self.read(nreadahead()) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/io.py", line 475, in read n = self.readinto(b) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/socket.py", line 217, in readinto return self._sock.recv_into(b) socket.error: [Errno 104] Connection reset by peer ====================================================================== ERROR: test_fail_with_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/test/test_xmlrpc.py", line 515, in test_fail_with_info p.pow(6,8) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1091, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1349, in __request verbose=self.__verbose File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1121, in request resp = http_conn.getresponse() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/httplib.py", line 961, in getresponse response.begin() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/httplib.py", line 425, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/httplib.py", line 267, in readheaders line = str(self.fp.readline(), "iso-8859-1") File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/io.py", line 413, in readline b = self.read(nreadahead()) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/io.py", line 475, in read n = self.readinto(b) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/socket.py", line 217, in readinto return self._sock.recv_into(b) socket.error: [Errno 104] Connection reset by peer make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Fri Jan 4 16:35:55 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 04 Jan 2008 15:35:55 +0000 Subject: [Python-checkins] buildbot failure in x86 mvlgcc trunk Message-ID: <20080104153555.3A7C61E4024@bag.python.org> The Buildbot has detected a new failure of x86 mvlgcc trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20mvlgcc%20trunk/builds/1122 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-linux Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "./Lib/test/regrtest.py", line 167, in from test import test_support File "/home2/buildbot/slave/trunk.loewis-linux/build/Lib/test/test_support.py", line 8, in import socket File "/home2/buildbot/slave/trunk.loewis-linux/build/Lib/socket.py", line 166, in class _socketobject(object): File "/home2/buildbot/slave/trunk.loewis-linux/build/Lib/socket.py", line 211, in _socketobject exec _s % (_m, _m, _m, _m) File "", line 3, in AttributeError: type object '_socket.socket' has no attribute 'ioctl' make: *** [buildbottest] Fehler 1 sincerely, -The Buildbot From python-checkins at python.org Fri Jan 4 16:48:06 2008 From: python-checkins at python.org (christian.heimes) Date: Fri, 4 Jan 2008 16:48:06 +0100 (CET) Subject: [Python-checkins] r59721 - in python/trunk/Lib: socket.py test/test_socket.py Message-ID: <20080104154806.9F1F01E4021@bag.python.org> Author: christian.heimes Date: Fri Jan 4 16:48:06 2008 New Revision: 59721 Modified: python/trunk/Lib/socket.py python/trunk/Lib/test/test_socket.py Log: socket.ioctl is only available on Windows Modified: python/trunk/Lib/socket.py ============================================================================== --- python/trunk/Lib/socket.py (original) +++ python/trunk/Lib/socket.py Fri Jan 4 16:48:06 2008 @@ -141,7 +141,10 @@ 'bind', 'connect', 'connect_ex', 'fileno', 'listen', 'getpeername', 'getsockname', 'getsockopt', 'setsockopt', 'sendall', 'setblocking', - 'settimeout', 'gettimeout', 'shutdown', 'ioctl') + 'settimeout', 'gettimeout', 'shutdown') + +if os.name == "nt": + _socketmethods = _socketmethods + ('ioctl',) if sys.platform == "riscos": _socketmethods = _socketmethods + ('sleeptaskw',) Modified: python/trunk/Lib/test/test_socket.py ============================================================================== --- python/trunk/Lib/test/test_socket.py (original) +++ python/trunk/Lib/test/test_socket.py Fri Jan 4 16:48:06 2008 @@ -9,6 +9,7 @@ import thread, threading import Queue import sys +import os import array from weakref import proxy import signal @@ -500,6 +501,15 @@ self.assertEqual(sock.proto, 0) sock.close() + def test_sock_ioctl(self): + if os.name != "nt": + return + self.assert_(hasattr(socket.socket, 'ioctl')) + self.assert_(hasattr(socket, 'SIO_RCVALL')) + self.assert_(hasattr(socket, 'RCVALL_ON')) + self.assert_(hasattr(socket, 'RCVALL_OFF')) + + class BasicTCPTest(SocketConnectedTest): def __init__(self, methodName='runTest'): From buildbot at python.org Fri Jan 4 17:15:56 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 04 Jan 2008 16:15:56 +0000 Subject: [Python-checkins] buildbot failure in alpha Tru64 5.1 2.5 Message-ID: <20080104161556.EDE1B1E4011@bag.python.org> The Buildbot has detected a new failure of alpha Tru64 5.1 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/alpha%20Tru64%205.1%202.5/builds/386 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-tru64 Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: andrew.kuchling,lars.gustaebel BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_socket ====================================================================== FAIL: testInterruptedTimeout (test.test_socket.TCPTimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/net/taipan/scratch1/nnorwitz/python/2.5.norwitz-tru64/build/Lib/test/test_socket.py", line 879, in testInterruptedTimeout self.fail("got Alarm in wrong place") AssertionError: got Alarm in wrong place sincerely, -The Buildbot From buildbot at python.org Fri Jan 4 17:20:27 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 04 Jan 2008 16:20:27 +0000 Subject: [Python-checkins] buildbot failure in hppa Ubuntu 2.5 Message-ID: <20080104162027.797081E4011@bag.python.org> The Buildbot has detected a new failure of hppa Ubuntu 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/hppa%20Ubuntu%202.5/builds/108 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-ubuntu-hppa Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: 2 tests failed: test_bsddb3 test_resource ====================================================================== ERROR: test00_associateDBError (bsddb.test.test_associate.AssociateErrorTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 104, in setUp self.env.open(homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateBTreeTxnTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateBTreeTxnTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test13_associate_in_transaction (bsddb.test.test_associate.AssociateBTreeTxnTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ShelveAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ShelveAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ShelveAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ThreadedAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ThreadedAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ThreadedAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ThreadedAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ThreadedAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ThreadedAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_EnvRemoveAndRename (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_EnvRemoveAndRename (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Transactions (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_TxnTruncate (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test08_TxnLateUse (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Transactions (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_TxnTruncate (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test08_TxnLateUse (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test09_MultiDB (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test09_MultiDB (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_both (bsddb.test.test_dbobj.dbobjTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbobj.py", line 44, in test01_both self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/dbobj.py", line 39, in open return apply(self._cobj.open, args, kwargs) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_dbobj_dict_interface (bsddb.test.test_dbobj.dbobjTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbobj.py", line 57, in test02_dbobj_dict_interface self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/dbobj.py", line 39, in open return apply(self._cobj.open, args, kwargs) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01 (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 52, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02 (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 52, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03 (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 52, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_MultiCondSelect (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 52, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_CondObjs (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 52, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_CreateOrExtend (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 52, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_Delete (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 52, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_Modify (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 52, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_close_dbenv_before_db (bsddb.test.test_env_close.DBEnvClosedEarlyCrash) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_env_close.py", line 53, in test01_close_dbenv_before_db 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_close_dbenv_delete_db_success (bsddb.test.test_env_close.DBEnvClosedEarlyCrash) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_env_close.py", line 78, in test02_close_dbenv_delete_db_success 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_join (bsddb.test.test_join.JoinTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_join.py", line 57, in setUp self.env.open(homeDir, db.DB_CREATE | db.DB_INIT_MPOOL | db.DB_INIT_LOCK ) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_simple (bsddb.test.test_lock.LockingTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_lock.py", line 39, in setUp db.DB_INIT_LOCK | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_threaded (bsddb.test.test_lock.LockingTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_lock.py", line 39, in setUp db.DB_INIT_LOCK | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_set_timeout (bsddb.test.test_lock.LockingTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_lock.py", line 39, in setUp db.DB_INIT_LOCK | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_db_home (bsddb.test.test_misc.MiscTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_misc.py", line 44, in test02_db_home env.open(self.homeDir, db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_1WriterMultiReaders (bsddb.test.test_thread.BTreeConcurrentDataStore) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_1WriterMultiReaders (bsddb.test.test_thread.HashConcurrentDataStore) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_SimpleLocks (bsddb.test.test_thread.BTreeSimpleThreaded) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_SimpleLocks (bsddb.test.test_thread.HashSimpleThreaded) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.BTreeThreadedTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.HashThreadedTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.BTreeThreadedNoWaitTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.HashThreadedNoWaitTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_cachesize (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_flags (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_get (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_get_dbp (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_get_key (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_range (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_remove (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_stat (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_pget (bsddb.test.test_cursor_pget_bug.pget_bugTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/bsddb/test/test_cursor_pget_bug.py", line 25, in setUp self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') Traceback (most recent call last): File "./Lib/test/regrtest.py", line 549, in runtest_inner the_package = __import__(abstest, globals(), locals(), []) File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/test/test_resource.py", line 42, in f.close() IOError: [Errno 27] File too large make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Fri Jan 4 19:24:42 2008 From: python-checkins at python.org (andrew.kuchling) Date: Fri, 4 Jan 2008 19:24:42 +0100 (CET) Subject: [Python-checkins] r59722 - python/trunk/Doc/whatsnew/2.6.rst Message-ID: <20080104182442.19E7A1E4012@bag.python.org> Author: andrew.kuchling Date: Fri Jan 4 19:24:41 2008 New Revision: 59722 Modified: python/trunk/Doc/whatsnew/2.6.rst Log: Fix markup Modified: python/trunk/Doc/whatsnew/2.6.rst ============================================================================== --- python/trunk/Doc/whatsnew/2.6.rst (original) +++ python/trunk/Doc/whatsnew/2.6.rst Fri Jan 4 19:24:41 2008 @@ -503,10 +503,12 @@ @abstractmethod decorator -- you can't instantiate classes w/ an abstract method. - at abstractproperty decorator - at abstractproperty -def readonly(self): - return self._x +:: + + @abstractproperty decorator + @abstractproperty + def readonly(self): + return self._x .. seealso:: @@ -1163,7 +1165,7 @@ esoteric bugfixes, that may require changes to your code: -* The :method:`__init__` method of :class:`collections.deque` +* The :meth:`__init__` method of :class:`collections.deque` now clears any existing contents of the deque before adding elements from the iterable. This change makes the behavior match that of ``list.__init__()``. From python-checkins at python.org Fri Jan 4 19:25:05 2008 From: python-checkins at python.org (andrew.kuchling) Date: Fri, 4 Jan 2008 19:25:05 +0100 (CET) Subject: [Python-checkins] r59723 - python/trunk/Doc/library/math.rst Message-ID: <20080104182505.7D2D91E4016@bag.python.org> Author: andrew.kuchling Date: Fri Jan 4 19:25:05 2008 New Revision: 59723 Modified: python/trunk/Doc/library/math.rst Log: Fix markup Modified: python/trunk/Doc/library/math.rst ============================================================================== --- python/trunk/Doc/library/math.rst (original) +++ python/trunk/Doc/library/math.rst Fri Jan 4 19:25:05 2008 @@ -36,7 +36,7 @@ Return *x* with the sign of *y*. ``copysign`` copies the sign bit of an IEEE 754 float, ``copysign(1, -0.0)`` returns *-1.0*. - ..versionadded:: 2.6 + .. versionadded:: 2.6 .. function:: fabs(x) @@ -78,7 +78,7 @@ Checks if the float *x* is positive or negative infinite. - ..versionadded:: 2.6 + .. versionadded:: 2.6 .. function:: isnan(x) @@ -88,7 +88,7 @@ ``inf / inf`` or any operation involving a NaN, e.g. ``nan * 1``, return a NaN. - ..versionadded:: 2.6 + .. versionadded:: 2.6 .. function:: ldexp(x, i) From python-checkins at python.org Fri Jan 4 20:06:03 2008 From: python-checkins at python.org (guido.van.rossum) Date: Fri, 4 Jan 2008 20:06:03 +0100 (CET) Subject: [Python-checkins] r59724 - python/branches/release25-maint/Lib/threading.py Message-ID: <20080104190603.4786A1E4008@bag.python.org> Author: guido.van.rossum Date: Fri Jan 4 20:06:02 2008 New Revision: 59724 Modified: python/branches/release25-maint/Lib/threading.py Log: Backport r57216 (see issue #1731). Add a hack (originally devised in a slightly different form by Thomas Wouters) to prevent spurious tracebacks when a daemon thread's cleanup happens to wake up when the world around it has already been destroyed. This also backports other small changes to this file, essentially making it identical to the trunk version. Modified: python/branches/release25-maint/Lib/threading.py ============================================================================== --- python/branches/release25-maint/Lib/threading.py (original) +++ python/branches/release25-maint/Lib/threading.py Fri Jan 4 20:06:02 2008 @@ -85,9 +85,10 @@ self.__count = 0 def __repr__(self): + owner = self.__owner return "<%s(%s, %d)>" % ( self.__class__.__name__, - self.__owner and self.__owner.getName(), + owner and owner.getName(), self.__count) def acquire(self, blocking=1): @@ -111,8 +112,8 @@ __enter__ = acquire def release(self): - me = currentThread() - assert self.__owner is me, "release() of un-acquire()d lock" + if self.__owner is not currentThread(): + raise RuntimeError("cannot release un-aquired lock") self.__count = count = self.__count - 1 if not count: self.__owner = None @@ -204,7 +205,8 @@ return True def wait(self, timeout=None): - assert self._is_owned(), "wait() of un-acquire()d lock" + if not self._is_owned(): + raise RuntimeError("cannot wait on un-aquired lock") waiter = _allocate_lock() waiter.acquire() self.__waiters.append(waiter) @@ -245,7 +247,8 @@ self._acquire_restore(saved_state) def notify(self, n=1): - assert self._is_owned(), "notify() of un-acquire()d lock" + if not self._is_owned(): + raise RuntimeError("cannot notify on un-aquired lock") __waiters = self.__waiters waiters = __waiters[:n] if not waiters: @@ -273,7 +276,8 @@ # After Tim Peters' semaphore class, but not quite the same (no maximum) def __init__(self, value=1, verbose=None): - assert value >= 0, "Semaphore initial value must be >= 0" + if value < 0: + raise ValueError("semaphore initial value must be >= 0") _Verbose.__init__(self, verbose) self.__cond = Condition(Lock()) self.__value = value @@ -424,8 +428,10 @@ return "<%s(%s, %s)>" % (self.__class__.__name__, self.__name, status) def start(self): - assert self.__initialized, "Thread.__init__() not called" - assert not self.__started, "thread already started" + if not self.__initialized: + raise RuntimeError("thread.__init__() not called") + if self.__started: + raise RuntimeError("thread already started") if __debug__: self._note("%s.start(): starting thread", self) _active_limbo_lock.acquire() @@ -440,6 +446,26 @@ self.__target(*self.__args, **self.__kwargs) def __bootstrap(self): + # Wrapper around the real bootstrap code that ignores + # exceptions during interpreter cleanup. Those typically + # happen when a daemon thread wakes up at an unfortunate + # moment, finds the world around it destroyed, and raises some + # random exception *** while trying to report the exception in + # __bootstrap_inner() below ***. Those random exceptions + # don't help anybody, and they confuse users, so we suppress + # them. We suppress them only when it appears that the world + # indeed has already been destroyed, so that exceptions in + # __bootstrap_inner() during normal business hours are properly + # reported. Also, we only suppress them for daemonic threads; + # if a non-daemonic encounters this, something else is wrong. + try: + self.__bootstrap_inner() + except: + if self.__daemonic and _sys is None: + return + raise + + def __bootstrap_inner(self): try: self.__started = True _active_limbo_lock.acquire() @@ -545,9 +571,13 @@ _active_limbo_lock.release() def join(self, timeout=None): - assert self.__initialized, "Thread.__init__() not called" - assert self.__started, "cannot join thread before it is started" - assert self is not currentThread(), "cannot join current thread" + if not self.__initialized: + raise RuntimeError("Thread.__init__() not called") + if not self.__started: + raise RuntimeError("cannot join thread before it is started") + if self is currentThread(): + raise RuntimeError("cannot join current thread") + if __debug__: if not self.__stopped: self._note("%s.join(): waiting until thread stops", self) @@ -590,8 +620,10 @@ return self.__daemonic def setDaemon(self, daemonic): - assert self.__initialized, "Thread.__init__() not called" - assert not self.__started, "cannot set daemon status of active thread" + if not self.__initialized: + raise RuntimeError("Thread.__init__() not called") + if self.__started: + raise RuntimeError("cannot set daemon status of active thread"); self.__daemonic = daemonic # The timer class was contributed by Itamar Shtull-Trauring From buildbot at python.org Fri Jan 4 20:23:10 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 04 Jan 2008 19:23:10 +0000 Subject: [Python-checkins] buildbot failure in x86 XP-4 2.5 Message-ID: <20080104192310.3978A1E4008@bag.python.org> The Buildbot has detected a new failure of x86 XP-4 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20XP-4%202.5/builds/81 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-windows Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: guido.van.rossum BUILD FAILED: failed failed slave lost sincerely, -The Buildbot From buildbot at python.org Fri Jan 4 22:15:45 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 04 Jan 2008 21:15:45 +0000 Subject: [Python-checkins] buildbot failure in ia64 Ubuntu trunk Message-ID: <20080104211545.7278D1E4008@bag.python.org> The Buildbot has detected a new failure of ia64 Ubuntu trunk. Full details are available at: http://www.python.org/dev/buildbot/all/ia64%20Ubuntu%20trunk/builds/1214 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ia64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: andrew.kuchling,lars.gustaebel BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_timeout ====================================================================== FAIL: testConnectTimeout (test.test_timeout.TimeoutTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ia64/build/Lib/test/test_timeout.py", line 122, in testConnectTimeout self.addr_remote) AssertionError: error not raised make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Fri Jan 4 23:01:03 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 04 Jan 2008 22:01:03 +0000 Subject: [Python-checkins] buildbot failure in hppa Ubuntu trunk Message-ID: <20080104220103.623E01E401F@bag.python.org> The Buildbot has detected a new failure of hppa Ubuntu trunk. Full details are available at: http://www.python.org/dev/buildbot/all/hppa%20Ubuntu%20trunk/builds/451 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-ubuntu-hppa Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: lars.gustaebel BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_bsddb3 ====================================================================== ERROR: test00_associateDBError (bsddb.test.test_associate.AssociateErrorTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 104, in setUp self.env.open(homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateBTreeTxnTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateBTreeTxnTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test13_associate_in_transaction (bsddb.test.test_associate.AssociateBTreeTxnTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ShelveAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ShelveAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ShelveAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ThreadedAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ThreadedAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ThreadedAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ThreadedAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ThreadedAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ThreadedAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_EnvRemoveAndRename (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_EnvRemoveAndRename (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Transactions (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_TxnTruncate (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test08_TxnLateUse (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Transactions (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_TxnTruncate (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test08_TxnLateUse (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test09_MultiDB (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test09_MultiDB (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_both (bsddb.test.test_dbobj.dbobjTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbobj.py", line 45, in test01_both self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbobj.py", line 39, in open return apply(self._cobj.open, args, kwargs) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_dbobj_dict_interface (bsddb.test.test_dbobj.dbobjTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbobj.py", line 58, in test02_dbobj_dict_interface self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbobj.py", line 39, in open return apply(self._cobj.open, args, kwargs) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01 (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02 (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03 (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_MultiCondSelect (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_CondObjs (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_CreateOrExtend (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_Delete (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_Modify (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_close_dbenv_before_db (bsddb.test.test_env_close.DBEnvClosedEarlyCrash) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_env_close.py", line 53, in test01_close_dbenv_before_db 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_close_dbenv_delete_db_success (bsddb.test.test_env_close.DBEnvClosedEarlyCrash) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_env_close.py", line 78, in test02_close_dbenv_delete_db_success 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_join (bsddb.test.test_join.JoinTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_join.py", line 57, in setUp self.env.open(homeDir, db.DB_CREATE | db.DB_INIT_MPOOL | db.DB_INIT_LOCK ) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_simple (bsddb.test.test_lock.LockingTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_lock.py", line 38, in setUp db.DB_INIT_LOCK | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_threaded (bsddb.test.test_lock.LockingTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_lock.py", line 38, in setUp db.DB_INIT_LOCK | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_set_timeout (bsddb.test.test_lock.LockingTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_lock.py", line 38, in setUp db.DB_INIT_LOCK | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_db_home (bsddb.test.test_misc.MiscTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_misc.py", line 45, in test02_db_home env.open(self.homeDir, db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_1WriterMultiReaders (bsddb.test.test_thread.BTreeConcurrentDataStore) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_1WriterMultiReaders (bsddb.test.test_thread.HashConcurrentDataStore) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_SimpleLocks (bsddb.test.test_thread.BTreeSimpleThreaded) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_SimpleLocks (bsddb.test.test_thread.HashSimpleThreaded) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.BTreeThreadedTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.HashThreadedTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.BTreeThreadedNoWaitTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.HashThreadedNoWaitTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_cachesize (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_flags (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_get (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_get_dbp (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_get_key (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_range (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_remove (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_stat (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_pget (bsddb.test.test_cursor_pget_bug.pget_bugTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_cursor_pget_bug.py", line 25, in setUp self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') make: *** [buildbottest] Error 1 sincerely, -The Buildbot From nnorwitz at gmail.com Fri Jan 4 23:46:47 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Fri, 4 Jan 2008 17:46:47 -0500 Subject: [Python-checkins] Python Regression Test Failures all (1) Message-ID: <20080104224647.GA18064@python.psfb.org> test_grammar test_opcodes test_dict test_builtin test_exceptions test_types test_unittest test_doctest test_doctest2 test_MimeWriter test_StringIO test___all__ test___future__ test__locale test_abc test_abstract_numbers test_aepack test_aepack skipped -- No module named aepack test_al test_al skipped -- No module named al test_anydbm test_applesingle test_applesingle skipped -- No module named macostools test_array test_ast test_asynchat test_asyncore test_atexit test_audioop test_augassign test_base64 test_bastion test_bigaddrspace test_bigmem test_binascii test_binhex test_binop test_bisect test_bool test_bsddb test_bsddb185 test_bsddb185 skipped -- No module named bsddb185 test_bsddb3 test test_bsddb3 failed -- errors occurred; run in verbose mode for details test_buffer test_bufio test_bz2 test_cProfile test_calendar test_call test_capi test_cd test_cd skipped -- No module named cd test_cfgparser test_cgi test_charmapcodec test_cl test_cl skipped -- No module named cl test_class test_cmath test_cmd test_cmd_line test_cmd_line_script test_code test_codeccallbacks test_codecencodings_cn test_codecencodings_hk test_codecencodings_jp test_codecencodings_kr test_codecencodings_tw test_codecmaps_cn test_codecmaps_hk test_codecmaps_jp test_codecmaps_kr test_codecmaps_tw test_codecs test_codeop test_coding test_coercion test_collections test_colorsys test_commands test_compare test_compile test_compiler testCompileLibrary still working, be patient... test_complex test_complex_args test_contains test_contextlib test_cookie test_cookielib test_copy test_copy_reg test_cpickle test_crypt test_csv test_ctypes test_datetime test_dbm test_decimal test_decorators test_defaultdict test_deque test_descr test_descrtut test_difflib test_dircache test_dis test_distutils test_dl test_docxmlrpc test_dumbdbm test_dummy_thread test_dummy_threading test_email test_email_codecs test_email_renamed test_enumerate test_eof test_errno test_exception_variations test_extcall test_fcntl test_file test_filecmp test_fileinput test_float test_fnmatch test_fork1 test_format test_fpformat test_frozen test_ftplib test_funcattrs test_functools test_future test_gc test_gdbm test_generators test_genericpath test_genexps test_getargs test_getargs2 test_getopt test_gettext test_gl test_gl skipped -- No module named gl test_glob test_global test_grp test_gzip test_hash test_hashlib test_heapq test_hexoct test_hmac test_hotshot test_htmllib test_htmlparser test_httplib test_imageop test_imageop skipped -- No module named imgfile test_imaplib test_imgfile test_imgfile skipped -- No module named imgfile test_imp test_import test_importhooks test_index test_inspect test_ioctl test_ioctl skipped -- Unable to open /dev/tty test_isinstance test_iter test_iterlen test_itertools test_largefile test_list test_locale test_logging test_long test_long_future test_longexp test_macostools test_macostools skipped -- No module named macostools test_macpath test_mailbox test_marshal test_math test_md5 test_mhlib test_mimetools test_mimetypes test_minidom test_mmap test_module test_modulefinder test_multibytecodec test_multibytecodec_support test_multifile test_mutants test_netrc test_new test_nis test_normalization test_ntpath test_old_mailbox test_openpty test_operator test_optparse test_os test_parser test_peepholer test_pep247 test_pep263 test_pep277 test_pep277 skipped -- test works only on NT+ test_pep292 test_pep352 test_pickle test_pickletools test_pipes test_pkg test_pkgimport test_platform test_plistlib test_plistlib skipped -- No module named plistlib test_poll test_popen [7443 refs] [7443 refs] [7443 refs] test_popen2 test_poplib test_posix test_posixpath test_pow test_pprint test_profile test_profilehooks test_property test_pty test_pwd test_pyclbr test_pyexpat test_queue test_quopri [7822 refs] [7822 refs] test_random test_re test_repr test_resource test_rfc822 test_richcmp test_robotparser test_runpy test_sax test_scope test_scriptpackages test_scriptpackages skipped -- No module named aetools test_select test_set test_sets test_sgmllib test_sha test_shelve test_shlex test_shutil test_signal test_site test_slice test_smtplib test_socket test_socket_ssl /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:94: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ssl_sock = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:60: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:130: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:144: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) test_socketserver test_softspace test_sort test_sqlite test_ssl test_startfile test_startfile skipped -- cannot import name startfile test_str test_strftime test_string test_stringprep test_strop test_strptime test_struct test_structmembers test_structseq test_subprocess [7438 refs] [7439 refs] [7438 refs] [7438 refs] [7438 refs] [7438 refs] [7438 refs] [7438 refs] [7438 refs] [7438 refs] [7439 refs] [9058 refs] [7656 refs] [7439 refs] [7438 refs] [7438 refs] [7438 refs] [7438 refs] [7438 refs] . [7438 refs] [7438 refs] this bit of output is from a test of stdout in a different process ... [7438 refs] [7438 refs] [7656 refs] test_sunaudiodev test_sunaudiodev skipped -- No module named sunaudiodev test_sundry test_symtable test_syntax test_sys [7438 refs] [7438 refs] test_tarfile test_tcl test_tcl skipped -- No module named _tkinter test_telnetlib test_tempfile [7445 refs] test_textwrap test_thread test_threaded_import test_threadedtempfile test_threading [10580 refs] test_threading_local test_threadsignals test_time test_timeout test_tokenize test_trace test_traceback test_transformer test_tuple test_typechecks test_ucn test_unary test_unicode test_unicode_file test_unicode_file skipped -- No Unicode filesystem semantics on this platform. test_unicodedata test_univnewlines test_unpack test_urllib test_urllib2 test_urllib2_localnet test_urllib2net test_urllibnet test_urlparse test_userdict test_userlist test_userstring test_uu test_uuid WARNING: uuid.getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._ifconfig_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._unixdll_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. test_wait3 test_wait4 test_warnings test_wave test_weakref test_whichdb test_winreg test_winreg skipped -- No module named _winreg test_winsound test_winsound skipped -- No module named winsound test_with test_wsgiref test_xdrlib test_xml_etree test_xml_etree_c test_xmllib test_xmlrpc test_xpickle test_xrange test_zipfile test_zipfile64 test_zipfile64 skipped -- test requires loads of disk-space bytes and a long time to run test_zipimport test_zlib 312 tests OK. 1 test failed: test_bsddb3 21 tests skipped: test_aepack test_al test_applesingle test_bsddb185 test_cd test_cl test_gl test_imageop test_imgfile test_ioctl test_macostools test_pep277 test_plistlib test_scriptpackages test_startfile test_sunaudiodev test_tcl test_unicode_file test_winreg test_winsound test_zipfile64 1 skip unexpected on linux2: test_ioctl [534945 refs] From buildbot at python.org Sat Jan 5 01:52:31 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 05 Jan 2008 00:52:31 +0000 Subject: [Python-checkins] buildbot failure in sparc Ubuntu 2.5 Message-ID: <20080105005231.C367B1E4008@bag.python.org> The Buildbot has detected a new failure of sparc Ubuntu 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/sparc%20Ubuntu%202.5/builds/0 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-ubuntu-sparc Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: andrew.kuchling,christian.heimes,guido.van.rossum,lars.gustaebel BUILD FAILED: failed test Excerpt from the test logfile: make: *** [buildbottest] Bus error sincerely, -The Buildbot From buildbot at python.org Sat Jan 5 01:54:20 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 05 Jan 2008 00:54:20 +0000 Subject: [Python-checkins] buildbot failure in ia64 Ubuntu 3.0 Message-ID: <20080105005421.193D41E4008@bag.python.org> The Buildbot has detected a new failure of ia64 Ubuntu 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/ia64%20Ubuntu%203.0/builds/432 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ia64 Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ia64/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/home/pybot/buildarea/3.0.klose-debian-ia64/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/home/pybot/buildarea/3.0.klose-debian-ia64/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/home/pybot/buildarea/3.0.klose-debian-ia64/build/Lib/SocketServer.py", line 522, in __init__ self.handle() File "/home/pybot/buildarea/3.0.klose-debian-ia64/build/Lib/BaseHTTPServer.py", line 330, in handle self.handle_one_request() File "/home/pybot/buildarea/3.0.klose-debian-ia64/build/Lib/BaseHTTPServer.py", line 324, in handle_one_request method() File "/home/pybot/buildarea/3.0.klose-debian-ia64/build/Lib/SimpleXMLRPCServer.py", line 430, in do_POST self.report_404() File "/home/pybot/buildarea/3.0.klose-debian-ia64/build/Lib/SimpleXMLRPCServer.py", line 489, in report_404 self.connection.shutdown(1) socket.error: [Errno 107] Transport endpoint is not connected 2 tests failed: test_timeout test_xmlrpc ====================================================================== FAIL: testConnectTimeout (test.test_timeout.TimeoutTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ia64/build/Lib/test/test_timeout.py", line 122, in testConnectTimeout self.addr_remote) AssertionError: error not raised by connect make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Sat Jan 5 01:59:59 2008 From: python-checkins at python.org (guido.van.rossum) Date: Sat, 5 Jan 2008 01:59:59 +0100 (CET) Subject: [Python-checkins] r59725 - in python/trunk: Lib/test/test_builtin.py Lib/test/test_float.py Python/pystrtod.c Message-ID: <20080105005959.DC09F1E4008@bag.python.org> Author: guido.van.rossum Date: Sat Jan 5 01:59:59 2008 New Revision: 59725 Modified: python/trunk/Lib/test/test_builtin.py python/trunk/Lib/test/test_float.py python/trunk/Python/pystrtod.c Log: Patch #1725 by Mark Dickinson, fixes incorrect conversion of -1e1000 and adds errors for -0x. Modified: python/trunk/Lib/test/test_builtin.py ============================================================================== --- python/trunk/Lib/test/test_builtin.py (original) +++ python/trunk/Lib/test/test_builtin.py Sat Jan 5 01:59:59 2008 @@ -619,6 +619,11 @@ self.assertEqual(float(" 3.14 "), 3.14) self.assertRaises(ValueError, float, " 0x3.1 ") self.assertRaises(ValueError, float, " -0x3.p-1 ") + self.assertRaises(ValueError, float, " +0x3.p-1 ") + self.assertRaises(ValueError, float, "++3.14") + self.assertRaises(ValueError, float, "+-3.14") + self.assertRaises(ValueError, float, "-+3.14") + self.assertRaises(ValueError, float, "--3.14") if have_unicode: self.assertEqual(float(unicode(" 3.14 ")), 3.14) self.assertEqual(float(unicode(" \u0663.\u0661\u0664 ",'raw-unicode-escape')), 3.14) @@ -648,6 +653,7 @@ self.assertRaises(ValueError, float, " -3,14 ") self.assertRaises(ValueError, float, " 0x3.1 ") self.assertRaises(ValueError, float, " -0x3.p-1 ") + self.assertRaises(ValueError, float, " +0x3.p-1 ") self.assertEqual(float(" 25.e-1 "), 2.5) self.assertEqual(fcmp(float(" .25e-1 "), .025), 0) Modified: python/trunk/Lib/test/test_float.py ============================================================================== --- python/trunk/Lib/test/test_float.py (original) +++ python/trunk/Lib/test/test_float.py Sat Jan 5 01:59:59 2008 @@ -121,6 +121,13 @@ self.assertEquals(pos_pos(), neg_pos()) self.assertEquals(pos_neg(), neg_neg()) + if float.__getformat__("double").startswith("IEEE"): + def test_underflow_sign(self): + import math + # check that -1e-1000 gives -0.0, not 0.0 + self.assertEquals(math.atan2(-1e-1000, -1), math.atan2(-0.0, -1)) + self.assertEquals(math.atan2(float('-1e-1000'), -1), + math.atan2(-0.0, -1)) class ReprTestCase(unittest.TestCase): def test_repr(self): Modified: python/trunk/Python/pystrtod.c ============================================================================== --- python/trunk/Python/pystrtod.c (original) +++ python/trunk/Python/pystrtod.c Sat Jan 5 01:59:59 2008 @@ -48,6 +48,8 @@ size_t decimal_point_len; const char *p, *decimal_point_pos; const char *end = NULL; /* Silence gcc */ + const char *digits_pos = NULL; + int negate = 0; assert(nptr != NULL); @@ -60,18 +62,41 @@ assert(decimal_point_len != 0); decimal_point_pos = NULL; + + /* We process any leading whitespace and the optional sign manually, + then pass the remainder to the system strtod. This ensures that + the result of an underflow has the correct sign. (bug #1725) */ + + p = nptr; + /* Skip leading space */ + while (ISSPACE(*p)) + p++; + + /* Process leading sign, if present */ + if (*p == '-') { + negate = 1; + p++; + } else if (*p == '+') { + p++; + } + + /* What's left should begin with a digit, a decimal point, or one of + the letters i, I, n, N. It should not begin with 0x or 0X */ + if ((!ISDIGIT(*p) && + *p != '.' && *p != 'i' && *p != 'I' && *p != 'n' && *p != 'N') + || + (*p == '0' && (p[1] == 'x' || p[1] == 'X'))) + { + if (endptr) + *endptr = (char*)nptr; + errno = EINVAL; + return val; + } + digits_pos = p; + if (decimal_point[0] != '.' || decimal_point[1] != 0) { - p = nptr; - /* Skip leading space */ - while (ISSPACE(*p)) - p++; - - /* Skip leading optional sign */ - if (*p == '+' || *p == '-') - p++; - while (ISDIGIT(*p)) p++; @@ -93,7 +118,8 @@ else if (strncmp(p, decimal_point, decimal_point_len) == 0) { /* Python bug #1417699 */ - *endptr = (char*)nptr; + if (endptr) + *endptr = (char*)nptr; errno = EINVAL; return val; } @@ -109,7 +135,8 @@ char *copy, *c; /* We need to convert the '.' to the locale specific decimal point */ - copy = (char *)PyMem_MALLOC(end - nptr + 1 + decimal_point_len); + copy = (char *)PyMem_MALLOC(end - digits_pos + + 1 + decimal_point_len); if (copy == NULL) { if (endptr) *endptr = (char *)nptr; @@ -118,8 +145,8 @@ } c = copy; - memcpy(c, nptr, decimal_point_pos - nptr); - c += decimal_point_pos - nptr; + memcpy(c, digits_pos, decimal_point_pos - digits_pos); + c += decimal_point_pos - digits_pos; memcpy(c, decimal_point, decimal_point_len); c += decimal_point_len; memcpy(c, decimal_point_pos + 1, end - (decimal_point_pos + 1)); @@ -131,24 +158,27 @@ if (fail_pos) { if (fail_pos > decimal_point_pos) - fail_pos = (char *)nptr + (fail_pos - copy) - (decimal_point_len - 1); + fail_pos = (char *)digits_pos + + (fail_pos - copy) - + (decimal_point_len - 1); else - fail_pos = (char *)nptr + (fail_pos - copy); + fail_pos = (char *)digits_pos + + (fail_pos - copy); } PyMem_FREE(copy); } else { - unsigned i = 0; - if (nptr[i] == '-') - i++; - if (nptr[i] == '0' && (nptr[i+1] == 'x' || nptr[i+1] == 'X')) - fail_pos = (char*)nptr; - else - val = strtod(nptr, &fail_pos); + val = strtod(digits_pos, &fail_pos); } + if (fail_pos == digits_pos) + fail_pos = (char *)nptr; + + if (negate && fail_pos != nptr) + val = -val; + if (endptr) *endptr = fail_pos; From buildbot at python.org Sat Jan 5 02:07:44 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 05 Jan 2008 01:07:44 +0000 Subject: [Python-checkins] buildbot failure in sparc Ubuntu trunk Message-ID: <20080105010744.85A2C1E4008@bag.python.org> The Buildbot has detected a new failure of sparc Ubuntu trunk. Full details are available at: http://www.python.org/dev/buildbot/all/sparc%20Ubuntu%20trunk/builds/0 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-ubuntu-sparc Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: amaury.forgeotdarc,andrew.kuchling,christian.heimes,guido.van.rossum,jeffrey.yasskin,kurt.kaiser,lars.gustaebel,martin.v.loewis,neal.norwitz,raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: make: *** [buildbottest] Bus error sincerely, -The Buildbot From buildbot at python.org Sat Jan 5 02:17:37 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 05 Jan 2008 01:17:37 +0000 Subject: [Python-checkins] buildbot failure in sparc Ubuntu 3.0 Message-ID: <20080105011737.B36831E4008@bag.python.org> The Buildbot has detected a new failure of sparc Ubuntu 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/sparc%20Ubuntu%203.0/builds/0 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-ubuntu-sparc Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: amaury.forgeotdarc,christian.heimes,guido.van.rossum BUILD FAILED: failed test Excerpt from the test logfile: make: *** [buildbottest] Bus error sincerely, -The Buildbot From python-checkins at python.org Sat Jan 5 02:21:57 2008 From: python-checkins at python.org (guido.van.rossum) Date: Sat, 5 Jan 2008 02:21:57 +0100 (CET) Subject: [Python-checkins] r59726 - in python/trunk: Lib/test/test_urlparse.py Lib/urlparse.py Misc/NEWS Message-ID: <20080105012157.CFE061E4008@bag.python.org> Author: guido.van.rossum Date: Sat Jan 5 02:21:57 2008 New Revision: 59726 Modified: python/trunk/Lib/test/test_urlparse.py python/trunk/Lib/urlparse.py python/trunk/Misc/NEWS Log: Patch #1698 by Senthil: allow '@' in username when parsed by urlparse.py. Modified: python/trunk/Lib/test/test_urlparse.py ============================================================================== --- python/trunk/Lib/test/test_urlparse.py (original) +++ python/trunk/Lib/test/test_urlparse.py Sat Jan 5 02:21:57 2008 @@ -254,6 +254,24 @@ self.assertEqual(p.port, 80) self.assertEqual(p.geturl(), url) + # Addressing issue1698, which suggests Username can contain + # "@" character. Though not RFC complaint, many ftp sites allow + # and requests email ids as usernames. + + url = "http://User at example.com:Pass at www.python.org:080/doc/?query=yes#frag" + p = urlparse.urlsplit(url) + self.assertEqual(p.scheme, "http") + self.assertEqual(p.netloc, "User at example.com:Pass at www.python.org:080") + self.assertEqual(p.path, "/doc/") + self.assertEqual(p.query, "query=yes") + self.assertEqual(p.fragment, "frag") + self.assertEqual(p.username, "User at example.com") + self.assertEqual(p.password, "Pass") + self.assertEqual(p.hostname, "www.python.org") + self.assertEqual(p.port, 80) + self.assertEqual(p.geturl(), url) + + def test_attributes_bad_port(self): """Check handling of non-integer ports.""" p = urlparse.urlsplit("http://www.example.net:foo") Modified: python/trunk/Lib/urlparse.py ============================================================================== --- python/trunk/Lib/urlparse.py (original) +++ python/trunk/Lib/urlparse.py Sat Jan 5 02:21:57 2008 @@ -82,7 +82,7 @@ def username(self): netloc = self.netloc if "@" in netloc: - userinfo = netloc.split("@", 1)[0] + userinfo = netloc.rsplit("@", 1)[0] if ":" in userinfo: userinfo = userinfo.split(":", 1)[0] return userinfo @@ -92,7 +92,7 @@ def password(self): netloc = self.netloc if "@" in netloc: - userinfo = netloc.split("@", 1)[0] + userinfo = netloc.rsplit("@", 1)[0] if ":" in userinfo: return userinfo.split(":", 1)[1] return None @@ -101,7 +101,7 @@ def hostname(self): netloc = self.netloc if "@" in netloc: - netloc = netloc.split("@", 1)[1] + netloc = netloc.rsplit("@", 1)[1] if ":" in netloc: netloc = netloc.split(":", 1)[0] return netloc.lower() or None @@ -110,7 +110,7 @@ def port(self): netloc = self.netloc if "@" in netloc: - netloc = netloc.split("@", 1)[1] + netloc = netloc.rsplit("@", 1)[1] if ":" in netloc: port = netloc.split(":", 1)[1] return int(port, 10) Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Sat Jan 5 02:21:57 2008 @@ -342,6 +342,8 @@ Library ------- +- Patch #1698: allow '@' in username parsed by urlparse.py. + - Issue #1735: TarFile.extractall() now correctly sets directory permissions and times. From python-checkins at python.org Sat Jan 5 02:35:44 2008 From: python-checkins at python.org (raymond.hettinger) Date: Sat, 5 Jan 2008 02:35:44 +0100 (CET) Subject: [Python-checkins] r59727 - in python/trunk: Doc/library/collections.rst Lib/collections.py Lib/test/test_collections.py Message-ID: <20080105013544.25C771E401E@bag.python.org> Author: raymond.hettinger Date: Sat Jan 5 02:35:43 2008 New Revision: 59727 Modified: python/trunk/Doc/library/collections.rst python/trunk/Lib/collections.py python/trunk/Lib/test/test_collections.py Log: Improve namedtuple's _cast() method with a docstring, new name, and error-checking. Modified: python/trunk/Doc/library/collections.rst ============================================================================== --- python/trunk/Doc/library/collections.rst (original) +++ python/trunk/Doc/library/collections.rst Sat Jan 5 02:35:43 2008 @@ -393,7 +393,13 @@ def __new__(cls, x, y): return tuple.__new__(cls, (x, y)) - _cast = classmethod(tuple.__new__) + @classmethod + def _make(cls, iterable): + 'Make a new Point object from a sequence or iterable' + result = tuple.__new__(cls, iterable) + if len(result) != 2: + raise TypeError('Expected 2 arguments, got %d' % len(result)) + return result def __repr__(self): return 'Point(x=%r, y=%r)' % self @@ -404,7 +410,7 @@ def _replace(self, **kwds): 'Return a new Point object replacing specified fields with new values' - return self.__class__._cast(map(kwds.get, ('x', 'y'), self)) + return self.__class__._make(map(kwds.get, ('x', 'y'), self)) x = property(itemgetter(0)) y = property(itemgetter(1)) @@ -426,34 +432,28 @@ EmployeeRecord = namedtuple('EmployeeRecord', 'name, age, title, department, paygrade') import csv - for emp in map(EmployeeRecord._cast, csv.reader(open("employees.csv", "rb"))): + for emp in map(EmployeeRecord._make, csv.reader(open("employees.csv", "rb"))): print emp.name, emp.title import sqlite3 conn = sqlite3.connect('/companydata') cursor = conn.cursor() cursor.execute('SELECT name, age, title, department, paygrade FROM employees') - for emp in map(EmployeeRecord._cast, cursor.fetchall()): + for emp in map(EmployeeRecord._make, cursor.fetchall()): print emp.name, emp.title In addition to the methods inherited from tuples, named tuples support -three additonal methods and one attribute. +three additional methods and one attribute. -.. method:: namedtuple._cast(iterable) +.. method:: namedtuple._make(iterable) - Class method returning a new instance taking the positional arguments from the - *iterable*. Useful for casting existing sequences and iterables to named tuples. - - This fast constructor does not check the length of the inputs. To achieve the - same effect with length checking, use the star-operator instead. + Class method that makes a new instance from an existing sequence or iterable. :: - >>> t = [11, 22] - >>> Point._cast(t) # fast conversion - Point(x=11, y=22) - >>> Point(*t) # slow conversion with length checking - Point(x=11, y=22) + >>> t = [11, 22] + >>> Point._make(t) + Point(x=11, y=22) .. method:: somenamedtuple._asdict() Modified: python/trunk/Lib/collections.py ============================================================================== --- python/trunk/Lib/collections.py (original) +++ python/trunk/Lib/collections.py Sat Jan 5 02:35:43 2008 @@ -54,6 +54,7 @@ seen_names.add(name) # Create and fill-in the class template + numfields = len(field_names) argtxt = repr(field_names).replace("'", "")[1:-1] # tuple repr without parens or quotes reprtxt = ', '.join('%s=%%r' % name for name in field_names) dicttxt = ', '.join('%r: t[%d]' % (name, pos) for pos, name in enumerate(field_names)) @@ -63,7 +64,13 @@ _fields = %(field_names)r \n def __new__(cls, %(argtxt)s): return tuple.__new__(cls, (%(argtxt)s)) \n - _cast = classmethod(tuple.__new__) \n + @classmethod + def _make(cls, iterable): + 'Make a new %(typename)s object from a sequence or iterable' + result = tuple.__new__(cls, iterable) + if len(result) != %(numfields)d: + raise TypeError('Expected %(numfields)d arguments, got %%d' %% len(result)) + return result \n def __repr__(self): return '%(typename)s(%(reprtxt)s)' %% self \n def _asdict(t): @@ -71,7 +78,7 @@ return {%(dicttxt)s} \n def _replace(self, **kwds): 'Return a new %(typename)s object replacing specified fields with new values' - return self.__class__._cast(map(kwds.get, %(field_names)r, self)) \n\n''' % locals() + return self.__class__._make(map(kwds.get, %(field_names)r, self)) \n\n''' % locals() for i, name in enumerate(field_names): template += ' %s = property(itemgetter(%d))\n' % (name, i) if verbose: Modified: python/trunk/Lib/test/test_collections.py ============================================================================== --- python/trunk/Lib/test/test_collections.py (original) +++ python/trunk/Lib/test/test_collections.py Sat Jan 5 02:35:43 2008 @@ -32,6 +32,9 @@ namedtuple('Point0', 'x1 y2') # Verify that numbers are allowed in names namedtuple('_', 'a b c') # Test leading underscores in a typename + self.assertRaises(TypeError, Point._make, [11]) # catch too few args + self.assertRaises(TypeError, Point._make, [11, 22, 33]) # catch too many args + def test_instance(self): Point = namedtuple('Point', 'x y') p = Point(11, 22) @@ -47,7 +50,7 @@ self.assertEqual(repr(p), 'Point(x=11, y=22)') self.assert_('__dict__' not in dir(p)) # verify instance has no dict self.assert_('__weakref__' not in dir(p)) - self.assertEqual(p, Point._cast([11, 22])) # test _cast classmethod + self.assertEqual(p, Point._make([11, 22])) # test _make classmethod self.assertEqual(p._fields, ('x', 'y')) # test _fields attribute self.assertEqual(p._replace(x=1), (1, 22)) # test _replace method self.assertEqual(p._asdict(), dict(x=11, y=22)) # test _asdict method @@ -84,14 +87,14 @@ def test_odd_sizes(self): Zero = namedtuple('Zero', '') self.assertEqual(Zero(), ()) - self.assertEqual(Zero._cast([]), ()) + self.assertEqual(Zero._make([]), ()) self.assertEqual(repr(Zero()), 'Zero()') self.assertEqual(Zero()._asdict(), {}) self.assertEqual(Zero()._fields, ()) Dot = namedtuple('Dot', 'd') self.assertEqual(Dot(1), (1,)) - self.assertEqual(Dot._cast([1]), (1,)) + self.assertEqual(Dot._make([1]), (1,)) self.assertEqual(Dot(1).d, 1) self.assertEqual(repr(Dot(1)), 'Dot(d=1)') self.assertEqual(Dot(1)._asdict(), {'d':1}) @@ -104,7 +107,7 @@ Big = namedtuple('Big', names) b = Big(*range(n)) self.assertEqual(b, tuple(range(n))) - self.assertEqual(Big._cast(range(n)), tuple(range(n))) + self.assertEqual(Big._make(range(n)), tuple(range(n))) for pos, name in enumerate(names): self.assertEqual(getattr(b, name), pos) repr(b) # make sure repr() doesn't blow-up From buildbot at python.org Sat Jan 5 02:53:46 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 05 Jan 2008 01:53:46 +0000 Subject: [Python-checkins] buildbot failure in alpha Debian 2.5 Message-ID: <20080105015346.AF5731E4008@bag.python.org> The Buildbot has detected a new failure of alpha Debian 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/alpha%20Debian%202.5/builds/0 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-alpha Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: andrew.kuchling,christian.heimes,guido.van.rossum,lars.gustaebel BUILD FAILED: failed test Excerpt from the test logfile: sincerely, -The Buildbot From buildbot at python.org Sat Jan 5 03:06:51 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 05 Jan 2008 02:06:51 +0000 Subject: [Python-checkins] buildbot failure in x86 FreeBSD trunk Message-ID: <20080105020652.0DE971E4008@bag.python.org> The Buildbot has detected a new failure of x86 FreeBSD trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20FreeBSD%20trunk/builds/334 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-freebsd Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: andrew.kuchling,guido.van.rossum BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 523, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30995, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30995, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30995, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30995, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') 1 test failed: test_threading sincerely, -The Buildbot From python-checkins at python.org Sat Jan 5 03:17:24 2008 From: python-checkins at python.org (raymond.hettinger) Date: Sat, 5 Jan 2008 03:17:24 +0100 (CET) Subject: [Python-checkins] r59728 - in python/trunk: Doc/library/collections.rst Lib/collections.py Lib/test/test_collections.py Message-ID: <20080105021724.B111E1E4008@bag.python.org> Author: raymond.hettinger Date: Sat Jan 5 03:17:24 2008 New Revision: 59728 Modified: python/trunk/Doc/library/collections.rst python/trunk/Lib/collections.py python/trunk/Lib/test/test_collections.py Log: Add error-checking to namedtuple's _replace() method. Modified: python/trunk/Doc/library/collections.rst ============================================================================== --- python/trunk/Doc/library/collections.rst (original) +++ python/trunk/Doc/library/collections.rst Sat Jan 5 03:17:24 2008 @@ -410,7 +410,10 @@ def _replace(self, **kwds): 'Return a new Point object replacing specified fields with new values' - return self.__class__._make(map(kwds.get, ('x', 'y'), self)) + result = self.__class__._make(map(kwds.pop, ('x', 'y'), self)) + if kwds: + raise ValueError('Got unexpected field names: %r' % kwds.keys()) + return result x = property(itemgetter(0)) y = property(itemgetter(1)) Modified: python/trunk/Lib/collections.py ============================================================================== --- python/trunk/Lib/collections.py (original) +++ python/trunk/Lib/collections.py Sat Jan 5 03:17:24 2008 @@ -78,7 +78,10 @@ return {%(dicttxt)s} \n def _replace(self, **kwds): 'Return a new %(typename)s object replacing specified fields with new values' - return self.__class__._make(map(kwds.get, %(field_names)r, self)) \n\n''' % locals() + result = self.__class__._make(map(kwds.pop, %(field_names)r, self)) + if kwds: + raise ValueError('Got unexpected field names: %%r' %% kwds.keys()) + return result \n\n''' % locals() for i, name in enumerate(field_names): template += ' %s = property(itemgetter(%d))\n' % (name, i) if verbose: Modified: python/trunk/Lib/test/test_collections.py ============================================================================== --- python/trunk/Lib/test/test_collections.py (original) +++ python/trunk/Lib/test/test_collections.py Sat Jan 5 03:17:24 2008 @@ -55,6 +55,13 @@ self.assertEqual(p._replace(x=1), (1, 22)) # test _replace method self.assertEqual(p._asdict(), dict(x=11, y=22)) # test _asdict method + try: + p._replace(x=1, error=2) + except ValueError: + pass + else: + self._fail('Did not detect an incorrect fieldname') + # verify that field string can have commas Point = namedtuple('Point', 'x, y') p = Point(x=11, y=22) From buildbot at python.org Sat Jan 5 03:42:54 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 05 Jan 2008 02:42:54 +0000 Subject: [Python-checkins] buildbot failure in alpha Debian 3.0 Message-ID: <20080105024254.E44E51E4008@bag.python.org> The Buildbot has detected a new failure of alpha Debian 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/alpha%20Debian%203.0/builds/0 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-alpha Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: amaury.forgeotdarc,christian.heimes,guido.van.rossum BUILD FAILED: failed test Excerpt from the test logfile: sincerely, -The Buildbot From buildbot at python.org Sat Jan 5 04:50:15 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 05 Jan 2008 03:50:15 +0000 Subject: [Python-checkins] buildbot failure in PPC64 Debian trunk Message-ID: <20080105035015.A21591E4008@bag.python.org> The Buildbot has detected a new failure of PPC64 Debian trunk. Full details are available at: http://www.python.org/dev/buildbot/all/PPC64%20Debian%20trunk/builds/30 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_xmlrpc make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Sat Jan 5 05:03:48 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 05 Jan 2008 04:03:48 +0000 Subject: [Python-checkins] buildbot failure in alpha Debian trunk Message-ID: <20080105040349.06CED1E4008@bag.python.org> The Buildbot has detected a new failure of alpha Debian trunk. Full details are available at: http://www.python.org/dev/buildbot/all/alpha%20Debian%20trunk/builds/0 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-alpha Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: amaury.forgeotdarc,andrew.kuchling,christian.heimes,guido.van.rossum,jeffrey.yasskin,kurt.kaiser,lars.gustaebel,martin.v.loewis,neal.norwitz,raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: sincerely, -The Buildbot From python-checkins at python.org Sat Jan 5 05:38:39 2008 From: python-checkins at python.org (fred.drake) Date: Sat, 5 Jan 2008 05:38:39 +0100 (CET) Subject: [Python-checkins] r59730 - python/trunk/Lib/test/test_urlparse.py Message-ID: <20080105043839.5A3981E4008@bag.python.org> Author: fred.drake Date: Sat Jan 5 05:38:38 2008 New Revision: 59730 Modified: python/trunk/Lib/test/test_urlparse.py Log: clean up a comment Modified: python/trunk/Lib/test/test_urlparse.py ============================================================================== --- python/trunk/Lib/test/test_urlparse.py (original) +++ python/trunk/Lib/test/test_urlparse.py Sat Jan 5 05:38:38 2008 @@ -255,8 +255,8 @@ self.assertEqual(p.geturl(), url) # Addressing issue1698, which suggests Username can contain - # "@" character. Though not RFC complaint, many ftp sites allow - # and requests email ids as usernames. + # "@" characters. Though not RFC complaint, many ftp sites allow + # and request email addresses as usernames. url = "http://User at example.com:Pass at www.python.org:080/doc/?query=yes#frag" p = urlparse.urlsplit(url) From buildbot at python.org Sat Jan 5 05:43:49 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 05 Jan 2008 04:43:49 +0000 Subject: [Python-checkins] buildbot failure in amd64 XP 3.0 Message-ID: <20080105044349.D36811E4008@bag.python.org> The Buildbot has detected a new failure of amd64 XP 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/amd64%20XP%203.0/builds/447 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: heller-windows-amd64 Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: kurt.kaiser BUILD FAILED: failed failed slave lost sincerely, -The Buildbot From buildbot at python.org Sat Jan 5 05:44:40 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 05 Jan 2008 04:44:40 +0000 Subject: [Python-checkins] buildbot failure in hppa Ubuntu trunk Message-ID: <20080105044440.3DCBE1E4008@bag.python.org> The Buildbot has detected a new failure of hppa Ubuntu trunk. Full details are available at: http://www.python.org/dev/buildbot/all/hppa%20Ubuntu%20trunk/builds/454 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-ubuntu-hppa Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_bsddb3 ====================================================================== ERROR: test00_associateDBError (bsddb.test.test_associate.AssociateErrorTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 104, in setUp self.env.open(homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateBTreeTxnTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateBTreeTxnTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test13_associate_in_transaction (bsddb.test.test_associate.AssociateBTreeTxnTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ShelveAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ShelveAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ShelveAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ThreadedAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ThreadedAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ThreadedAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ThreadedAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ThreadedAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ThreadedAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_EnvRemoveAndRename (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_EnvRemoveAndRename (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Transactions (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_TxnTruncate (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test08_TxnLateUse (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Transactions (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_TxnTruncate (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test08_TxnLateUse (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test09_MultiDB (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test09_MultiDB (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_both (bsddb.test.test_dbobj.dbobjTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbobj.py", line 45, in test01_both self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbobj.py", line 39, in open return apply(self._cobj.open, args, kwargs) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_dbobj_dict_interface (bsddb.test.test_dbobj.dbobjTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbobj.py", line 58, in test02_dbobj_dict_interface self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbobj.py", line 39, in open return apply(self._cobj.open, args, kwargs) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01 (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02 (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03 (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_MultiCondSelect (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_CondObjs (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_CreateOrExtend (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_Delete (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_Modify (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_close_dbenv_before_db (bsddb.test.test_env_close.DBEnvClosedEarlyCrash) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_env_close.py", line 53, in test01_close_dbenv_before_db 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_close_dbenv_delete_db_success (bsddb.test.test_env_close.DBEnvClosedEarlyCrash) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_env_close.py", line 78, in test02_close_dbenv_delete_db_success 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_join (bsddb.test.test_join.JoinTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_join.py", line 57, in setUp self.env.open(homeDir, db.DB_CREATE | db.DB_INIT_MPOOL | db.DB_INIT_LOCK ) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_simple (bsddb.test.test_lock.LockingTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_lock.py", line 38, in setUp db.DB_INIT_LOCK | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_threaded (bsddb.test.test_lock.LockingTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_lock.py", line 38, in setUp db.DB_INIT_LOCK | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_set_timeout (bsddb.test.test_lock.LockingTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_lock.py", line 38, in setUp db.DB_INIT_LOCK | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_db_home (bsddb.test.test_misc.MiscTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_misc.py", line 45, in test02_db_home env.open(self.homeDir, db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_1WriterMultiReaders (bsddb.test.test_thread.BTreeConcurrentDataStore) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_1WriterMultiReaders (bsddb.test.test_thread.HashConcurrentDataStore) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_SimpleLocks (bsddb.test.test_thread.BTreeSimpleThreaded) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_SimpleLocks (bsddb.test.test_thread.HashSimpleThreaded) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.BTreeThreadedTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.HashThreadedTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.BTreeThreadedNoWaitTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.HashThreadedNoWaitTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_cachesize (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_flags (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_get (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_get_dbp (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_get_key (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_range (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_remove (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_stat (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_pget (bsddb.test.test_cursor_pget_bug.pget_bugTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_cursor_pget_bug.py", line 25, in setUp self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Sat Jan 5 06:31:09 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 05 Jan 2008 05:31:09 +0000 Subject: [Python-checkins] buildbot failure in g4 osx.4 trunk Message-ID: <20080105053109.8967B1E4009@bag.python.org> The Buildbot has detected a new failure of g4 osx.4 trunk. Full details are available at: http://www.python.org/dev/buildbot/all/g4%20osx.4%20trunk/builds/2546 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: psf-g4 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: fred.drake BUILD FAILED: failed svn sincerely, -The Buildbot From python-checkins at python.org Sat Jan 5 09:47:14 2008 From: python-checkins at python.org (jeffrey.yasskin) Date: Sat, 5 Jan 2008 09:47:14 +0100 (CET) Subject: [Python-checkins] r59731 - in python/trunk: Doc/library/functions.rst Doc/library/math.rst Doc/library/stdtypes.rst Doc/reference/expressions.rst Lib/numbers.py Lib/test/test_builtin.py Lib/test/test_long.py Lib/test/test_math.py Modules/mathmodule.c Objects/floatobject.c Objects/intobject.c Objects/longobject.c Python/bltinmodule.c Message-ID: <20080105084714.51AC21E4008@bag.python.org> Author: jeffrey.yasskin Date: Sat Jan 5 09:47:13 2008 New Revision: 59731 Modified: python/trunk/Doc/library/functions.rst python/trunk/Doc/library/math.rst python/trunk/Doc/library/stdtypes.rst python/trunk/Doc/reference/expressions.rst python/trunk/Lib/numbers.py python/trunk/Lib/test/test_builtin.py python/trunk/Lib/test/test_long.py python/trunk/Lib/test/test_math.py python/trunk/Modules/mathmodule.c python/trunk/Objects/floatobject.c python/trunk/Objects/intobject.c python/trunk/Objects/longobject.c python/trunk/Python/bltinmodule.c Log: Continue rolling back pep-3141 changes that changed behavior from 2.5. This round included: * Revert round to its 2.6 behavior (half away from 0). * Because round, floor, and ceil always return float again, it's no longer necessary to have them delegate to __xxx___, so I've ripped that out of their implementations and the Real ABC. This also helps in implementing types that work in both 2.6 and 3.0: you return int from the __xxx__ methods, and let it get enabled by the version upgrade. * Make pow(-1, .5) raise a ValueError again. Modified: python/trunk/Doc/library/functions.rst ============================================================================== --- python/trunk/Doc/library/functions.rst (original) +++ python/trunk/Doc/library/functions.rst Sat Jan 5 09:47:13 2008 @@ -986,13 +986,10 @@ .. function:: round(x[, n]) Return the floating point value *x* rounded to *n* digits after the decimal - point. If *n* is omitted, it defaults to zero. Values are rounded to the - closest multiple of 10 to the power minus *n*; if two multiples are equally - close, rounding is done toward the even choice (so, for example, both - ``round(0.5)`` and ``round(-0.5)`` are ``0``, and ``round(1.5)`` is - ``2``). Delegates to ``x.__round__(n)``. - - .. versionchanged:: 2.6 + point. If *n* is omitted, it defaults to zero. The result is a floating point + number. Values are rounded to the closest multiple of 10 to the power minus + *n*; if two multiples are equally close, rounding is done away from 0 (so. for + example, ``round(0.5)`` is ``1.0`` and ``round(-0.5)`` is ``-1.0``). .. function:: set([iterable]) Modified: python/trunk/Doc/library/math.rst ============================================================================== --- python/trunk/Doc/library/math.rst (original) +++ python/trunk/Doc/library/math.rst Sat Jan 5 09:47:13 2008 @@ -26,9 +26,8 @@ .. function:: ceil(x) - Return the ceiling of *x* as a float, the smallest integer value greater than - or equal to *x*. If *x* is not a float, delegates to ``x.__ceil__()``, which - should return an :class:`Integral` value. + Return the ceiling of *x* as a float, the smallest integer value greater than or + equal to *x*. .. function:: copysign(x, y) @@ -46,9 +45,8 @@ .. function:: floor(x) - Return the floor of *x* as a float, the largest integer value less than or - equal to *x*. If *x* is not a float, delegates to ``x.__floor__()``, which - should return an :class:`Integral` value. + Return the floor of *x* as a float, the largest integer value less than or equal + to *x*. .. function:: fmod(x, y) Modified: python/trunk/Doc/library/stdtypes.rst ============================================================================== --- python/trunk/Doc/library/stdtypes.rst (original) +++ python/trunk/Doc/library/stdtypes.rst Sat Jan 5 09:47:13 2008 @@ -341,11 +341,11 @@ pair: C; language Conversion from floating point to (long or plain) integer may round or - truncate as in C. + truncate as in C; see functions :func:`math.floor` and :func:`math.ceil` for + well-defined conversions. .. deprecated:: 2.6 - Instead, convert floats to long explicitly with :func:`trunc`, - :func:`math.floor`, or :func:`math.ceil`. + Instead, convert floats to long explicitly with :func:`trunc`. (3) See :ref:`built-in-funcs` for a full description. @@ -369,19 +369,19 @@ All :class:`numbers.Real` types (:class:`int`, :class:`long`, and :class:`float`) also include the following operations: -+--------------------+--------------------------------+--------+ -| Operation | Result | Notes | -+====================+================================+========+ -| ``trunc(x)`` | *x* truncated to Integral | | -+--------------------+--------------------------------+--------+ -| ``round(x[, n])`` | *x* rounded to n digits, | | -| | rounding half to even. If n is | | -| | omitted, it defaults to 0. | | -+--------------------+--------------------------------+--------+ -| ``math.floor(x)`` | the greatest Integral <= *x* | | -+--------------------+--------------------------------+--------+ -| ``math.ceil(x)`` | the least Integral >= *x* | | -+--------------------+--------------------------------+--------+ ++--------------------+------------------------------------+--------+ +| Operation | Result | Notes | ++====================+====================================+========+ +| ``trunc(x)`` | *x* truncated to Integral | | ++--------------------+------------------------------------+--------+ +| ``round(x[, n])`` | *x* rounded to n digits, | | +| | rounding half to even. If n is | | +| | omitted, it defaults to 0. | | ++--------------------+------------------------------------+--------+ +| ``math.floor(x)`` | the greatest integral float <= *x* | | ++--------------------+------------------------------------+--------+ +| ``math.ceil(x)`` | the least integral float >= *x* | | ++--------------------+------------------------------------+--------+ .. XXXJH exceptions: overflow (when? what operations?) zerodivision Modified: python/trunk/Doc/reference/expressions.rst ============================================================================== --- python/trunk/Doc/reference/expressions.rst (original) +++ python/trunk/Doc/reference/expressions.rst Sat Jan 5 09:47:13 2008 @@ -801,8 +801,7 @@ raised). Raising ``0.0`` to a negative power results in a :exc:`ZeroDivisionError`. -Raising a negative number to a fractional power results in a :class:`complex` -number. (Since Python 2.6. In earlier versions it raised a :exc:`ValueError`.) +Raising a negative number to a fractional power results in a :exc:`ValueError`. .. _unary: Modified: python/trunk/Lib/numbers.py ============================================================================== --- python/trunk/Lib/numbers.py (original) +++ python/trunk/Lib/numbers.py Sat Jan 5 09:47:13 2008 @@ -189,25 +189,6 @@ """ raise NotImplementedError - @abstractmethod - def __floor__(self): - """Finds the greatest Integral <= self.""" - raise NotImplementedError - - @abstractmethod - def __ceil__(self): - """Finds the least Integral >= self.""" - raise NotImplementedError - - @abstractmethod - def __round__(self, ndigits=None): - """Rounds self to ndigits decimal places, defaulting to 0. - - If ndigits is omitted or None, returns an Integral, otherwise - returns a Real. Rounds half toward even. - """ - raise NotImplementedError - def __divmod__(self, other): """divmod(self, other): The pair (self // other, self % other). Modified: python/trunk/Lib/test/test_builtin.py ============================================================================== --- python/trunk/Lib/test/test_builtin.py (original) +++ python/trunk/Lib/test/test_builtin.py Sat Jan 5 09:47:13 2008 @@ -1456,13 +1456,12 @@ else: self.assertAlmostEqual(pow(x, y, z), 24.0) - self.assertAlmostEqual(pow(-1, 0.5), 1j) - self.assertAlmostEqual(pow(-1, 1./3), 0.5 + 0.8660254037844386j) - self.assertRaises(TypeError, pow, -1, -2, 3) self.assertRaises(ValueError, pow, 1, 2, 0) self.assertRaises(TypeError, pow, -1L, -2L, 3L) self.assertRaises(ValueError, pow, 1L, 2L, 0L) + # Will return complex in 3.0: + self.assertRaises(ValueError, pow, -342.43, 0.234) self.assertRaises(TypeError, pow) @@ -1664,11 +1663,11 @@ self.assertEqual(type(round(-8.0, 0)), float) self.assertEqual(type(round(-8.0, 1)), float) - # Check even / odd rounding behaviour + # Check half rounding behaviour. self.assertEqual(round(5.5), 6) - self.assertEqual(round(6.5), 6) + self.assertEqual(round(6.5), 7) self.assertEqual(round(-5.5), -6) - self.assertEqual(round(-6.5), -6) + self.assertEqual(round(-6.5), -7) # Check behavior on ints self.assertEqual(round(0), 0) @@ -1686,8 +1685,8 @@ # test generic rounding delegation for reals class TestRound(object): - def __round__(self): - return 23 + def __float__(self): + return 23.0 class TestNoRound(object): pass @@ -1695,13 +1694,12 @@ self.assertEqual(round(TestRound()), 23) self.assertRaises(TypeError, round, 1, 2, 3) - # XXX: This is not ideal, but see the comment in builtin_round(). - self.assertRaises(AttributeError, round, TestNoRound()) + self.assertRaises(TypeError, round, TestNoRound()) t = TestNoRound() - t.__round__ = lambda *args: args - self.assertEquals((), round(t)) - self.assertEquals((0,), round(t, 0)) + t.__float__ = lambda *args: args + self.assertRaises(TypeError, round, t) + self.assertRaises(TypeError, round, t, 0) def test_setattr(self): setattr(sys, 'spam', 1) Modified: python/trunk/Lib/test/test_long.py ============================================================================== --- python/trunk/Lib/test/test_long.py (original) +++ python/trunk/Lib/test/test_long.py Sat Jan 5 09:47:13 2008 @@ -385,9 +385,7 @@ "1. ** huge", "huge ** 1.", "1. ** mhuge", "mhuge ** 1.", "math.sin(huge)", "math.sin(mhuge)", "math.sqrt(huge)", "math.sqrt(mhuge)", # should do better - # math.floor() of an int returns an int now - ##"math.floor(huge)", "math.floor(mhuge)", - ]: + "math.floor(huge)", "math.floor(mhuge)"]: self.assertRaises(OverflowError, eval, test, namespace) Modified: python/trunk/Lib/test/test_math.py ============================================================================== --- python/trunk/Lib/test/test_math.py (original) +++ python/trunk/Lib/test/test_math.py Sat Jan 5 09:47:13 2008 @@ -63,8 +63,8 @@ self.ftest('ceil(-1.5)', math.ceil(-1.5), -1) class TestCeil(object): - def __ceil__(self): - return 42 + def __float__(self): + return 41.3 class TestNoCeil(object): pass self.ftest('ceil(TestCeil())', math.ceil(TestCeil()), 42) @@ -123,8 +123,8 @@ self.ftest('floor(-1.23e167)', math.floor(-1.23e167), -1.23e167) class TestFloor(object): - def __floor__(self): - return 42 + def __float__(self): + return 42.3 class TestNoFloor(object): pass self.ftest('floor(TestFloor())', math.floor(TestFloor()), 42) Modified: python/trunk/Modules/mathmodule.c ============================================================================== --- python/trunk/Modules/mathmodule.c (original) +++ python/trunk/Modules/mathmodule.c Sat Jan 5 09:47:13 2008 @@ -107,28 +107,9 @@ FUNC2(atan2, atan2, "atan2(y, x)\n\nReturn the arc tangent (measured in radians) of y/x.\n" "Unlike atan(y/x), the signs of both x and y are considered.") - -static PyObject * math_ceil(PyObject *self, PyObject *number) { - static PyObject *ceil_str = NULL; - PyObject *method; - - if (ceil_str == NULL) { - ceil_str = PyString_FromString("__ceil__"); - if (ceil_str == NULL) - return NULL; - } - - method = _PyType_Lookup(Py_Type(number), ceil_str); - if (method == NULL) - return math_1(number, ceil); - else - return PyObject_CallFunction(method, "O", number); -} - -PyDoc_STRVAR(math_ceil_doc, - "ceil(x)\n\nReturn the ceiling of x as a float.\n" - "This is the smallest integral value >= x."); - +FUNC1(ceil, ceil, + "ceil(x)\n\nReturn the ceiling of x as a float.\n" + "This is the smallest integral value >= x.") FUNC1(cos, cos, "cos(x)\n\nReturn the cosine of x (measured in radians).") FUNC1(cosh, cosh, @@ -147,28 +128,9 @@ "exp(x)\n\nReturn e raised to the power of x.") FUNC1(fabs, fabs, "fabs(x)\n\nReturn the absolute value of the float x.") - -static PyObject * math_floor(PyObject *self, PyObject *number) { - static PyObject *floor_str = NULL; - PyObject *method; - - if (floor_str == NULL) { - floor_str = PyString_FromString("__floor__"); - if (floor_str == NULL) - return NULL; - } - - method = _PyType_Lookup(Py_Type(number), floor_str); - if (method == NULL) - return math_1(number, floor); - else - return PyObject_CallFunction(method, "O", number); -} - -PyDoc_STRVAR(math_floor_doc, - "floor(x)\n\nReturn the floor of x as a float.\n" - "This is the largest integral value <= x."); - +FUNC1(floor, floor, + "floor(x)\n\nReturn the floor of x as a float.\n" + "This is the largest integral value <= x.") FUNC2(fmod, fmod, "fmod(x,y)\n\nReturn fmod(x, y), according to platform C." " x % y may differ.") Modified: python/trunk/Objects/floatobject.c ============================================================================== --- python/trunk/Objects/floatobject.c (original) +++ python/trunk/Objects/floatobject.c Sat Jan 5 09:47:13 2008 @@ -986,10 +986,9 @@ * bugs so we have to figure it out ourselves. */ if (iw != floor(iw)) { - /* Negative numbers raised to fractional powers - * become complex. - */ - return PyComplex_Type.tp_as_number->nb_power(v, w, z); + PyErr_SetString(PyExc_ValueError, "negative number " + "cannot be raised to a fractional power"); + return NULL; } /* iw is an exact integer, albeit perhaps a very large one. * -1 raised to an exact integer should never be exceptional. @@ -1099,54 +1098,6 @@ } static PyObject * -float_round(PyObject *v, PyObject *args) -{ -#define UNDEF_NDIGITS (-0x7fffffff) /* Unlikely ndigits value */ - double x; - double f; - double flr, cil; - double rounded; - int i; - int ndigits = UNDEF_NDIGITS; - - if (!PyArg_ParseTuple(args, "|i", &ndigits)) - return NULL; - - x = PyFloat_AsDouble(v); - - if (ndigits != UNDEF_NDIGITS) { - f = 1.0; - i = abs(ndigits); - while (--i >= 0) - f = f*10.0; - if (ndigits < 0) - x /= f; - else - x *= f; - } - - flr = floor(x); - cil = ceil(x); - - if (x-flr > 0.5) - rounded = cil; - else if (x-flr == 0.5) - rounded = fmod(flr, 2) == 0 ? flr : cil; - else - rounded = flr; - - if (ndigits != UNDEF_NDIGITS) { - if (ndigits < 0) - rounded *= f; - else - rounded /= f; - } - - return PyFloat_FromDouble(rounded); -#undef UNDEF_NDIGITS -} - -static PyObject * float_float(PyObject *v) { if (PyFloat_CheckExact(v)) @@ -1344,9 +1295,6 @@ "Returns self, the complex conjugate of any float."}, {"__trunc__", (PyCFunction)float_trunc, METH_NOARGS, "Returns the Integral closest to x between 0 and x."}, - {"__round__", (PyCFunction)float_round, METH_VARARGS, - "Returns the Integral closest to x, rounding half toward even.\n" - "When an argument is passed, works like built-in round(x, ndigits)."}, {"__getnewargs__", (PyCFunction)float_getnewargs, METH_NOARGS}, {"__getformat__", (PyCFunction)float_getformat, METH_O|METH_CLASS, float_getformat_doc}, Modified: python/trunk/Objects/intobject.c ============================================================================== --- python/trunk/Objects/intobject.c (original) +++ python/trunk/Objects/intobject.c Sat Jan 5 09:47:13 2008 @@ -1056,43 +1056,11 @@ return PyInt_FromLong((intptr_t)context); } -static PyObject * -int_round(PyObject *self, PyObject *args) -{ -#define UNDEF_NDIGITS (-0x7fffffff) /* Unlikely ndigits value */ - int ndigits = UNDEF_NDIGITS; - double x; - PyObject *res; - - if (!PyArg_ParseTuple(args, "|i", &ndigits)) - return NULL; - - if (ndigits == UNDEF_NDIGITS) - return int_float((PyIntObject *)self); - - /* If called with two args, defer to float.__round__(). */ - x = (double) PyInt_AS_LONG(self); - self = PyFloat_FromDouble(x); - if (self == NULL) - return NULL; - res = PyObject_CallMethod(self, "__round__", "i", ndigits); - Py_DECREF(self); - return res; -#undef UNDEF_NDIGITS -} - static PyMethodDef int_methods[] = { {"conjugate", (PyCFunction)int_int, METH_NOARGS, "Returns self, the complex conjugate of any int."}, {"__trunc__", (PyCFunction)int_int, METH_NOARGS, "Truncating an Integral returns itself."}, - {"__floor__", (PyCFunction)int_float, METH_NOARGS, - "Flooring an Integral returns itself."}, - {"__ceil__", (PyCFunction)int_float, METH_NOARGS, - "Ceiling of an Integral returns itself."}, - {"__round__", (PyCFunction)int_round, METH_VARARGS, - "Rounding an Integral returns itself.\n" - "Rounding with an ndigits arguments defers to float.__round__."}, {"__getnewargs__", (PyCFunction)int_getnewargs, METH_NOARGS}, {NULL, NULL} /* sentinel */ }; Modified: python/trunk/Objects/longobject.c ============================================================================== --- python/trunk/Objects/longobject.c (original) +++ python/trunk/Objects/longobject.c Sat Jan 5 09:47:13 2008 @@ -3370,45 +3370,11 @@ return PyLong_FromLong((intptr_t)context); } -static PyObject * -long_round(PyObject *self, PyObject *args) -{ -#define UNDEF_NDIGITS (-0x7fffffff) /* Unlikely ndigits value */ - int ndigits = UNDEF_NDIGITS; - double x; - PyObject *res; - - if (!PyArg_ParseTuple(args, "|i", &ndigits)) - return NULL; - - if (ndigits == UNDEF_NDIGITS) - return long_float(self); - - /* If called with two args, defer to float.__round__(). */ - x = PyLong_AsDouble(self); - if (x == -1.0 && PyErr_Occurred()) - return NULL; - self = PyFloat_FromDouble(x); - if (self == NULL) - return NULL; - res = PyObject_CallMethod(self, "__round__", "i", ndigits); - Py_DECREF(self); - return res; -#undef UNDEF_NDIGITS -} - static PyMethodDef long_methods[] = { {"conjugate", (PyCFunction)long_long, METH_NOARGS, "Returns self, the complex conjugate of any long."}, {"__trunc__", (PyCFunction)long_long, METH_NOARGS, "Truncating an Integral returns itself."}, - {"__floor__", (PyCFunction)long_float, METH_NOARGS, - "Flooring an Integral returns itself."}, - {"__ceil__", (PyCFunction)long_float, METH_NOARGS, - "Ceiling of an Integral returns itself."}, - {"__round__", (PyCFunction)long_round, METH_VARARGS, - "Rounding an Integral returns itself.\n" - "Rounding with an ndigits arguments defers to float.__round__."}, {"__getnewargs__", (PyCFunction)long_getnewargs, METH_NOARGS}, {NULL, NULL} /* sentinel */ }; Modified: python/trunk/Python/bltinmodule.c ============================================================================== --- python/trunk/Python/bltinmodule.c (original) +++ python/trunk/Python/bltinmodule.c Sat Jan 5 09:47:13 2008 @@ -1926,31 +1926,39 @@ static PyObject * builtin_round(PyObject *self, PyObject *args, PyObject *kwds) { -#define UNDEF_NDIGITS (-0x7fffffff) /* Unlikely ndigits value */ - int ndigits = UNDEF_NDIGITS; + double number; + double f; + int ndigits = 0; + int i; static char *kwlist[] = {"number", "ndigits", 0}; - PyObject *number; - if (!PyArg_ParseTupleAndKeywords(args, kwds, "O|i:round", - kwlist, &number, &ndigits)) - return NULL; - - // The py3k branch gets better errors for this by using - // _PyType_Lookup(), but since float's mro isn't set in py2.6, - // we just use PyObject_CallMethod here. - if (ndigits == UNDEF_NDIGITS) - return PyObject_CallMethod(number, "__round__", ""); - else - return PyObject_CallMethod(number, "__round__", "i", ndigits); -#undef UNDEF_NDIGITS + if (!PyArg_ParseTupleAndKeywords(args, kwds, "d|i:round", + kwlist, &number, &ndigits)) + return NULL; + f = 1.0; + i = abs(ndigits); + while (--i >= 0) + f = f*10.0; + if (ndigits < 0) + number /= f; + else + number *= f; + if (number >= 0.0) + number = floor(number + 0.5); + else + number = ceil(number - 0.5); + if (ndigits < 0) + number *= f; + else + number /= f; + return PyFloat_FromDouble(number); } PyDoc_STRVAR(round_doc, "round(number[, ndigits]) -> floating point number\n\ \n\ Round a number to a given precision in decimal digits (default 0 digits).\n\ -This returns an int when called with one argument, otherwise a float.\n\ -Precision may be negative."); +This always returns a floating point number. Precision may be negative."); static PyObject * builtin_sorted(PyObject *self, PyObject *args, PyObject *kwds) From buildbot at python.org Sat Jan 5 10:31:24 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 05 Jan 2008 09:31:24 +0000 Subject: [Python-checkins] buildbot failure in ppc Debian unstable trunk Message-ID: <20080105093124.872E41E4008@bag.python.org> The Buildbot has detected a new failure of ppc Debian unstable trunk. Full details are available at: http://www.python.org/dev/buildbot/all/ppc%20Debian%20unstable%20trunk/builds/525 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: jeffrey.yasskin BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_xmlrpc ====================================================================== ERROR: test_fail_with_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_xmlrpc.py", line 580, in test_fail_with_info p.pow(6,8) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1157, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1447, in __request verbose=self.__verbose File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1195, in request errcode, errmsg, headers = h.getreply() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 1006, in getreply response = self._conn.getresponse() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 932, in getresponse response.begin() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 415, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 271, in readheaders line = self.fp.readline() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/socket.py", line 354, in readline data = recv(1) error: [Errno 104] Connection reset by peer make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Sat Jan 5 10:35:33 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 05 Jan 2008 09:35:33 +0000 Subject: [Python-checkins] buildbot failure in PPC64 Debian trunk Message-ID: <20080105093533.82D481E4014@bag.python.org> The Buildbot has detected a new failure of PPC64 Debian trunk. Full details are available at: http://www.python.org/dev/buildbot/all/PPC64%20Debian%20trunk/builds/32 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: jeffrey.yasskin BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_xmlrpc Traceback (most recent call last): File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/SocketServer.py", line 523, in __init__ self.handle() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/BaseHTTPServer.py", line 310, in handle_one_request method() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/SimpleXMLRPCServer.py", line 449, in do_POST self.report_404() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/SimpleXMLRPCServer.py", line 507, in report_404 self.connection.shutdown(1) File "", line 1, in shutdown error: [Errno 107] Transport endpoint is not connected ====================================================================== ERROR: test_fail_no_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/test/test_xmlrpc.py", line 560, in test_fail_no_info p.pow(6,8) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/xmlrpclib.py", line 1157, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/xmlrpclib.py", line 1447, in __request verbose=self.__verbose File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/xmlrpclib.py", line 1195, in request errcode, errmsg, headers = h.getreply() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 1006, in getreply response = self._conn.getresponse() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 932, in getresponse response.begin() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 415, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 271, in readheaders line = self.fp.readline() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/socket.py", line 354, in readline data = recv(1) error: [Errno 104] Connection reset by peer ====================================================================== ERROR: test_fail_with_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/test/test_xmlrpc.py", line 580, in test_fail_with_info p.pow(6,8) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/xmlrpclib.py", line 1157, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/xmlrpclib.py", line 1447, in __request verbose=self.__verbose File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/xmlrpclib.py", line 1195, in request errcode, errmsg, headers = h.getreply() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 1006, in getreply response = self._conn.getresponse() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 932, in getresponse response.begin() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 415, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 271, in readheaders line = self.fp.readline() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/socket.py", line 354, in readline data = recv(1) error: [Errno 104] Connection reset by peer make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Sat Jan 5 11:51:35 2008 From: python-checkins at python.org (martin.v.loewis) Date: Sat, 5 Jan 2008 11:51:35 +0100 (CET) Subject: [Python-checkins] r59732 - tracker/instances/python-dev/detectors/cia.py Message-ID: <20080105105135.67F961E4009@bag.python.org> Author: martin.v.loewis Date: Sat Jan 5 11:51:35 2008 New Revision: 59732 Added: tracker/instances/python-dev/detectors/cia.py (contents, props changed) Log: Add CIA detector. Added: tracker/instances/python-dev/detectors/cia.py ============================================================================== --- (empty file) +++ tracker/instances/python-dev/detectors/cia.py Sat Jan 5 11:51:35 2008 @@ -0,0 +1,59 @@ +# Reactor for sending changes to CIA.vc + +parameters = { + 'name':'Roundup Reactor for CIA', + 'revision': "$Revision$"[11:-2], + 'project': 'python', + 'module': 'Roundup', + 'urlprefix': 'http://bugs.python.org/issue', +} + +max_content = 150 + +TEMPLATE = """ + + + Roundup Reactor for CIA + %(revision)s + + + %(project)s + %(module)s + + + + %(author)s + %(log)s + %(urlprefix)s%(nodeid)s + + + +""" + + +def sendcia(db, cl, nodeid, newvalues): + messages = set(newvalues.get('messages',())) + messages -= set(cl.get(nodeid, 'messages')) + if not messages: + return + messages = list(messages) + + log = '[#%d] ' % nodeid + for msg in messages: + log += db.msg.get(msg, 'content') + if len(log) > max_content: + log = log[:-4] + ' ...' + + params = parameters.copy() + params['nodeid'] = nodeid + params['author'] = db.user.get(db.getuid(), 'username') + params['log'] = log + + payload = TEMPLATE % params + + open("/tmp/xxx", "w").write(payload) + +def init(db): + db.issue.audit('create', sendcia) + db.issue.audit('set', sendcia) + From python-checkins at python.org Sat Jan 5 12:06:53 2008 From: python-checkins at python.org (martin.v.loewis) Date: Sat, 5 Jan 2008 12:06:53 +0100 (CET) Subject: [Python-checkins] r59733 - tracker/instances/python-dev/detectors/cia.py Message-ID: <20080105110653.2C3341E401C@bag.python.org> Author: martin.v.loewis Date: Sat Jan 5 12:06:52 2008 New Revision: 59733 Modified: tracker/instances/python-dev/detectors/cia.py Log: Actually send data to CIA.vc. Modified: tracker/instances/python-dev/detectors/cia.py ============================================================================== --- tracker/instances/python-dev/detectors/cia.py (original) +++ tracker/instances/python-dev/detectors/cia.py Sat Jan 5 12:06:52 2008 @@ -1,4 +1,7 @@ # Reactor for sending changes to CIA.vc +import xmlrpclib + +server = "http://CIA.vc" parameters = { 'name':'Roundup Reactor for CIA', @@ -38,7 +41,7 @@ return messages = list(messages) - log = '[#%d] ' % nodeid + log = '[#%s] ' % nodeid for msg in messages: log += db.msg.get(msg, 'content') if len(log) > max_content: @@ -51,7 +54,14 @@ payload = TEMPLATE % params - open("/tmp/xxx", "w").write(payload) + try: + rpc = xmlrpclib.ServerProxy(server) + rpc.hub.deliver(payload) + except: + # Ignore any errors in sending the CIA; + # if the server is down, that's just bad luck + # XXX might want to do some logging here + pass def init(db): db.issue.audit('create', sendcia) From python-checkins at python.org Sat Jan 5 12:19:55 2008 From: python-checkins at python.org (martin.v.loewis) Date: Sat, 5 Jan 2008 12:19:55 +0100 (CET) Subject: [Python-checkins] r59734 - tracker/instances/python-dev/detectors/cia.py Message-ID: <20080105111955.5DFE31E4009@bag.python.org> Author: martin.v.loewis Date: Sat Jan 5 12:19:55 2008 New Revision: 59734 Modified: tracker/instances/python-dev/detectors/cia.py Log: Make it a reactor, and support an empty oldvalues. Modified: tracker/instances/python-dev/detectors/cia.py ============================================================================== --- tracker/instances/python-dev/detectors/cia.py (original) +++ tracker/instances/python-dev/detectors/cia.py Sat Jan 5 12:19:55 2008 @@ -34,9 +34,10 @@ """ -def sendcia(db, cl, nodeid, newvalues): - messages = set(newvalues.get('messages',())) - messages -= set(cl.get(nodeid, 'messages')) +def sendcia(db, cl, nodeid, oldvalues): + messages = set(cl.get(nodeid, 'messages')) + if oldvalues: + messages -= set(oldvalues.get('messages',())) if not messages: return messages = list(messages) @@ -64,6 +65,6 @@ pass def init(db): - db.issue.audit('create', sendcia) - db.issue.audit('set', sendcia) + db.issue.react('create', sendcia) + db.issue.react('set', sendcia) From python-checkins at python.org Sat Jan 5 12:25:29 2008 From: python-checkins at python.org (martin.v.loewis) Date: Sat, 5 Jan 2008 12:25:29 +0100 (CET) Subject: [Python-checkins] r59735 - tracker/instances/python-dev/detectors/cia.py Message-ID: <20080105112529.0DDB61E4018@bag.python.org> Author: martin.v.loewis Date: Sat Jan 5 12:25:28 2008 New Revision: 59735 Modified: tracker/instances/python-dev/detectors/cia.py Log: Fix max_content handling. Modified: tracker/instances/python-dev/detectors/cia.py ============================================================================== --- tracker/instances/python-dev/detectors/cia.py (original) +++ tracker/instances/python-dev/detectors/cia.py Sat Jan 5 12:25:28 2008 @@ -46,7 +46,7 @@ for msg in messages: log += db.msg.get(msg, 'content') if len(log) > max_content: - log = log[:-4] + ' ...' + log = log[:max_content-4] + ' ...' params = parameters.copy() params['nodeid'] = nodeid From python-checkins at python.org Sat Jan 5 16:13:49 2008 From: python-checkins at python.org (andrew.kuchling) Date: Sat, 5 Jan 2008 16:13:49 +0100 (CET) Subject: [Python-checkins] r59736 - python/trunk/Lib/test/test_urlparse.py Message-ID: <20080105151349.EDCFB1E4009@bag.python.org> Author: andrew.kuchling Date: Sat Jan 5 16:13:49 2008 New Revision: 59736 Modified: python/trunk/Lib/test/test_urlparse.py Log: Fix comment typo Modified: python/trunk/Lib/test/test_urlparse.py ============================================================================== --- python/trunk/Lib/test/test_urlparse.py (original) +++ python/trunk/Lib/test/test_urlparse.py Sat Jan 5 16:13:49 2008 @@ -255,7 +255,7 @@ self.assertEqual(p.geturl(), url) # Addressing issue1698, which suggests Username can contain - # "@" characters. Though not RFC complaint, many ftp sites allow + # "@" characters. Though not RFC compliant, many ftp sites allow # and request email addresses as usernames. url = "http://User at example.com:Pass at www.python.org:080/doc/?query=yes#frag" From python-checkins at python.org Sat Jan 5 18:15:44 2008 From: python-checkins at python.org (thomas.heller) Date: Sat, 5 Jan 2008 18:15:44 +0100 (CET) Subject: [Python-checkins] r59738 - python/trunk/Doc/ACKS.txt Message-ID: <20080105171544.E30041E4014@bag.python.org> Author: thomas.heller Date: Sat Jan 5 18:15:44 2008 New Revision: 59738 Modified: python/trunk/Doc/ACKS.txt Log: Add myself. Modified: python/trunk/Doc/ACKS.txt ============================================================================== --- python/trunk/Doc/ACKS.txt (original) +++ python/trunk/Doc/ACKS.txt Sat Jan 5 18:15:44 2008 @@ -73,6 +73,7 @@ * Travis B. Hartwell * Tim Hatch * Janko Hauser + * Thomas Heller * Bernhard Herzog * Magnus L. Hetland * Konrad Hinsen From buildbot at python.org Sat Jan 5 18:25:12 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 05 Jan 2008 17:25:12 +0000 Subject: [Python-checkins] buildbot failure in ppc Debian unstable 3.0 Message-ID: <20080105172512.B86341E4011@bag.python.org> The Buildbot has detected a new failure of ppc Debian unstable 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/ppc%20Debian%20unstable%203.0/builds/435 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: guido.van.rossum BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 522, in __init__ self.handle() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/BaseHTTPServer.py", line 330, in handle self.handle_one_request() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/BaseHTTPServer.py", line 324, in handle_one_request method() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SimpleXMLRPCServer.py", line 430, in do_POST self.report_404() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SimpleXMLRPCServer.py", line 489, in report_404 self.connection.shutdown(1) socket.error: [Errno 107] Transport endpoint is not connected 1 test failed: test_xmlrpc Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 522, in __init__ self.handle() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/BaseHTTPServer.py", line 330, in handle self.handle_one_request() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/BaseHTTPServer.py", line 324, in handle_one_request method() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SimpleXMLRPCServer.py", line 430, in do_POST self.report_404() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SimpleXMLRPCServer.py", line 489, in report_404 self.connection.shutdown(1) socket.error: [Errno 107] Transport endpoint is not connected ====================================================================== ERROR: test_fail_no_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/test/test_xmlrpc.py", line 497, in test_fail_no_info p.pow(6,8) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1091, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1349, in __request verbose=self.__verbose File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1121, in request resp = http_conn.getresponse() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/httplib.py", line 961, in getresponse response.begin() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/httplib.py", line 425, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/httplib.py", line 267, in readheaders line = str(self.fp.readline(), "iso-8859-1") File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/io.py", line 413, in readline b = self.read(nreadahead()) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/io.py", line 475, in read n = self.readinto(b) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/socket.py", line 217, in readinto return self._sock.recv_into(b) socket.error: [Errno 104] Connection reset by peer make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Sat Jan 5 18:49:17 2008 From: python-checkins at python.org (georg.brandl) Date: Sat, 5 Jan 2008 18:49:17 +0100 (CET) Subject: [Python-checkins] r59739 - python/trunk/Python/bltinmodule.c Message-ID: <20080105174917.E60C91E4009@bag.python.org> Author: georg.brandl Date: Sat Jan 5 18:49:17 2008 New Revision: 59739 Modified: python/trunk/Python/bltinmodule.c Log: Fix C++-style comment. Modified: python/trunk/Python/bltinmodule.c ============================================================================== --- python/trunk/Python/bltinmodule.c (original) +++ python/trunk/Python/bltinmodule.c Sat Jan 5 18:49:17 2008 @@ -2042,9 +2042,9 @@ static PyObject * builtin_trunc(PyObject *self, PyObject *number) { - // XXX: The py3k branch gets better errors for this by using - // _PyType_Lookup(), but since float's mro isn't set in py2.6, - // we just use PyObject_CallMethod here. + /* XXX: The py3k branch gets better errors for this by using + _PyType_Lookup(), but since float's mro isn't set in py2.6, + we just use PyObject_CallMethod here. */ return PyObject_CallMethod(number, "__trunc__", ""); } From buildbot at python.org Sat Jan 5 20:14:53 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 05 Jan 2008 19:14:53 +0000 Subject: [Python-checkins] buildbot failure in hppa Ubuntu trunk Message-ID: <20080105191453.908C51E402F@bag.python.org> The Buildbot has detected a new failure of hppa Ubuntu trunk. Full details are available at: http://www.python.org/dev/buildbot/all/hppa%20Ubuntu%20trunk/builds/458 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-ubuntu-hppa Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: georg.brandl,thomas.heller BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_bsddb3 ====================================================================== ERROR: test00_associateDBError (bsddb.test.test_associate.AssociateErrorTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 104, in setUp self.env.open(homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateBTreeTxnTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateBTreeTxnTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test13_associate_in_transaction (bsddb.test.test_associate.AssociateBTreeTxnTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ShelveAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ShelveAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ShelveAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ThreadedAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ThreadedAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ThreadedAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ThreadedAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ThreadedAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ThreadedAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_EnvRemoveAndRename (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_EnvRemoveAndRename (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Transactions (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_TxnTruncate (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test08_TxnLateUse (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Transactions (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_TxnTruncate (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test08_TxnLateUse (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test09_MultiDB (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test09_MultiDB (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_both (bsddb.test.test_dbobj.dbobjTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbobj.py", line 45, in test01_both self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbobj.py", line 39, in open return apply(self._cobj.open, args, kwargs) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_dbobj_dict_interface (bsddb.test.test_dbobj.dbobjTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbobj.py", line 58, in test02_dbobj_dict_interface self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbobj.py", line 39, in open return apply(self._cobj.open, args, kwargs) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01 (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02 (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03 (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_MultiCondSelect (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_CondObjs (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_CreateOrExtend (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_Delete (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_Modify (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_close_dbenv_before_db (bsddb.test.test_env_close.DBEnvClosedEarlyCrash) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_env_close.py", line 53, in test01_close_dbenv_before_db 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_close_dbenv_delete_db_success (bsddb.test.test_env_close.DBEnvClosedEarlyCrash) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_env_close.py", line 78, in test02_close_dbenv_delete_db_success 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_join (bsddb.test.test_join.JoinTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_join.py", line 57, in setUp self.env.open(homeDir, db.DB_CREATE | db.DB_INIT_MPOOL | db.DB_INIT_LOCK ) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_simple (bsddb.test.test_lock.LockingTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_lock.py", line 38, in setUp db.DB_INIT_LOCK | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_threaded (bsddb.test.test_lock.LockingTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_lock.py", line 38, in setUp db.DB_INIT_LOCK | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_set_timeout (bsddb.test.test_lock.LockingTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_lock.py", line 38, in setUp db.DB_INIT_LOCK | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_db_home (bsddb.test.test_misc.MiscTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_misc.py", line 45, in test02_db_home env.open(self.homeDir, db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_1WriterMultiReaders (bsddb.test.test_thread.BTreeConcurrentDataStore) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_1WriterMultiReaders (bsddb.test.test_thread.HashConcurrentDataStore) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_SimpleLocks (bsddb.test.test_thread.BTreeSimpleThreaded) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_SimpleLocks (bsddb.test.test_thread.HashSimpleThreaded) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.BTreeThreadedTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.HashThreadedTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.BTreeThreadedNoWaitTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.HashThreadedNoWaitTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_cachesize (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_flags (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_get (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_get_dbp (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_get_key (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_range (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_remove (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_stat (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_pget (bsddb.test.test_cursor_pget_bug.pget_bugTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_cursor_pget_bug.py", line 25, in setUp self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Sat Jan 5 20:19:44 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 05 Jan 2008 19:19:44 +0000 Subject: [Python-checkins] buildbot failure in hppa Ubuntu 3.0 Message-ID: <20080105191944.6CD0F1E400C@bag.python.org> The Buildbot has detected a new failure of hppa Ubuntu 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/hppa%20Ubuntu%203.0/builds/416 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-ubuntu-hppa Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: kurt.kaiser BUILD FAILED: failed test Excerpt from the test logfile: make: *** [buildbottest] Unknown signal 37 sincerely, -The Buildbot From python-checkins at python.org Sat Jan 5 20:28:16 2008 From: python-checkins at python.org (georg.brandl) Date: Sat, 5 Jan 2008 20:28:16 +0100 (CET) Subject: [Python-checkins] r59742 - python/trunk/Doc/library/contextlib.rst python/trunk/Doc/library/decimal.rst python/trunk/Doc/library/math.rst python/trunk/Doc/library/numbers.rst python/trunk/Doc/library/thread.rst python/trunk/Doc/library/threading.rst Message-ID: <20080105192816.8BFA51E400C@bag.python.org> Author: georg.brandl Date: Sat Jan 5 20:28:16 2008 New Revision: 59742 Modified: python/trunk/Doc/library/contextlib.rst python/trunk/Doc/library/decimal.rst python/trunk/Doc/library/math.rst python/trunk/Doc/library/numbers.rst python/trunk/Doc/library/thread.rst python/trunk/Doc/library/threading.rst Log: Remove with_statement future imports from 2.6 docs. Modified: python/trunk/Doc/library/contextlib.rst ============================================================================== --- python/trunk/Doc/library/contextlib.rst (original) +++ python/trunk/Doc/library/contextlib.rst Sat Jan 5 20:28:16 2008 @@ -23,7 +23,6 @@ A simple example (this is not recommended as a real way of generating HTML!):: - from __future__ import with_statement from contextlib import contextmanager @contextmanager @@ -100,7 +99,6 @@ And lets you write code like this:: - from __future__ import with_statement from contextlib import closing import urllib Modified: python/trunk/Doc/library/decimal.rst ============================================================================== --- python/trunk/Doc/library/decimal.rst (original) +++ python/trunk/Doc/library/decimal.rst Sat Jan 5 20:28:16 2008 @@ -840,7 +840,6 @@ For example, the following code sets the current decimal precision to 42 places, performs a calculation, and then automatically restores the previous context:: - from __future__ import with_statement from decimal import localcontext with localcontext() as ctx: Modified: python/trunk/Doc/library/math.rst ============================================================================== --- python/trunk/Doc/library/math.rst (original) +++ python/trunk/Doc/library/math.rst Sat Jan 5 20:28:16 2008 @@ -48,6 +48,9 @@ Return the floor of *x* as a float, the largest integer value less than or equal to *x*. + .. versionchanged:: 2.6 + Added :meth:`__floor__` delegation. + .. function:: fmod(x, y) Modified: python/trunk/Doc/library/numbers.rst ============================================================================== --- python/trunk/Doc/library/numbers.rst (original) +++ python/trunk/Doc/library/numbers.rst Sat Jan 5 20:28:16 2008 @@ -1,10 +1,12 @@ - :mod:`numbers` --- Numeric abstract base classes ================================================ .. module:: numbers :synopsis: Numeric abstract base classes (Complex, Real, Integral, etc.). +.. versionadded:: 2.6 + + The :mod:`numbers` module (:pep:`3141`) defines a hierarchy of numeric abstract base classes which progressively define more operations. These concepts also provide a way to distinguish exact from inexact types. None of the types defined Modified: python/trunk/Doc/library/thread.rst ============================================================================== --- python/trunk/Doc/library/thread.rst (original) +++ python/trunk/Doc/library/thread.rst Sat Jan 5 20:28:16 2008 @@ -135,7 +135,6 @@ In addition to these methods, lock objects can also be used via the :keyword:`with` statement, e.g.:: - from __future__ import with_statement import thread a_lock = thread.allocate_lock() Modified: python/trunk/Doc/library/threading.rst ============================================================================== --- python/trunk/Doc/library/threading.rst (original) +++ python/trunk/Doc/library/threading.rst Sat Jan 5 20:28:16 2008 @@ -723,7 +723,6 @@ :class:`Semaphore`, and :class:`BoundedSemaphore` objects may be used as :keyword:`with` statement context managers. For example:: - from __future__ import with_statement import threading some_rlock = threading.RLock() From python-checkins at python.org Sat Jan 5 20:29:45 2008 From: python-checkins at python.org (georg.brandl) Date: Sat, 5 Jan 2008 20:29:45 +0100 (CET) Subject: [Python-checkins] r59743 - python/trunk/Doc/reference/compound_stmts.rst python/trunk/Doc/reference/datamodel.rst python/trunk/Doc/reference/simple_stmts.rst Message-ID: <20080105192945.91BAC1E400C@bag.python.org> Author: georg.brandl Date: Sat Jan 5 20:29:45 2008 New Revision: 59743 Modified: python/trunk/Doc/reference/compound_stmts.rst python/trunk/Doc/reference/datamodel.rst python/trunk/Doc/reference/simple_stmts.rst Log: Simplify index entries; fix #1712. Modified: python/trunk/Doc/reference/compound_stmts.rst ============================================================================== --- python/trunk/Doc/reference/compound_stmts.rst (original) +++ python/trunk/Doc/reference/compound_stmts.rst Sat Jan 5 20:29:45 2008 @@ -76,7 +76,10 @@ The :keyword:`if` statement =========================== -.. index:: statement: if +.. index:: + statement: if + keyword: elif + keyword: else The :keyword:`if` statement is used for conditional execution: @@ -85,10 +88,6 @@ : ( "elif" `expression` ":" `suite` )* : ["else" ":" `suite`] -.. index:: - keyword: elif - keyword: else - It selects exactly one of the suites by evaluating the expressions one by one until one is found to be true (see section :ref:`booleans` for the definition of true and false); then that suite is executed (and no other part of the @@ -104,6 +103,7 @@ .. index:: statement: while pair: loop; statement + keyword: else The :keyword:`while` statement is used for repeated execution as long as an expression is true: @@ -112,8 +112,6 @@ while_stmt: "while" `expression` ":" `suite` : ["else" ":" `suite`] -.. index:: keyword: else - This repeatedly tests the expression and, if it is true, executes the first suite; if the expression is false (which may be the first time it is tested) the suite of the :keyword:`else` clause, if present, is executed and the loop @@ -137,8 +135,10 @@ .. index:: statement: for pair: loop; statement - -.. index:: object: sequence + keyword: in + keyword: else + pair: target; list + object: sequence The :keyword:`for` statement is used to iterate over the elements of a sequence (such as a string, tuple or list) or other iterable object: @@ -147,11 +147,6 @@ for_stmt: "for" `target_list` "in" `expression_list` ":" `suite` : ["else" ":" `suite`] -.. index:: - keyword: in - keyword: else - pair: target; list - The expression list is evaluated once; it should yield an iterable object. An iterator is created for the result of the ``expression_list``. The suite is then executed once for each item provided by the iterator, in the order of @@ -214,7 +209,10 @@ The :keyword:`try` statement ============================ -.. index:: statement: try +.. index:: + statement: try + keyword: except + keyword: finally The :keyword:`try` statement specifies exception handlers and/or cleanup code for a group of statements: @@ -233,8 +231,6 @@ :keyword:`finally` did not work. :keyword:`try`...\ :keyword:`except` had to be nested in :keyword:`try`...\ :keyword:`finally`. -.. index:: keyword: except - The :keyword:`except` clause(s) specify one or more exception handlers. When no exception occurs in the :keyword:`try` clause, no exception handler is executed. When an exception occurs in the :keyword:`try` suite, a search for an exception @@ -376,12 +372,8 @@ .. note:: In Python 2.5, the :keyword:`with` statement is only allowed when the - ``with_statement`` feature has been enabled. It will always be enabled in - Python 2.6. This ``__future__`` import statement can be used to enable the - feature:: - - from __future__ import with_statement - + ``with_statement`` feature has been enabled. It is always enabled in + Python 2.6. .. seealso:: @@ -397,10 +389,10 @@ ==================== .. index:: - pair: function; definition statement: def - -.. index:: + pair: function; definition + pair: function; name + pair: name; binding object: user-defined function object: function @@ -421,10 +413,6 @@ parameter: `identifier` | "(" `sublist` ")" funcname: `identifier` -.. index:: - pair: function; name - pair: name; binding - A function definition is an executable statement. Its execution binds the function name in the current local namespace to a function object (a wrapper around the executable code for the function). This function object contains a @@ -505,10 +493,13 @@ ================= .. index:: - pair: class; definition + object: class statement: class - -.. index:: object: class + pair: class; definition + pair: class; name + pair: name; binding + pair: execution; frame + single: inheritance A class definition defines a class object (see section :ref:`types`): @@ -517,12 +508,6 @@ inheritance: "(" [`expression_list`] ")" classname: `identifier` -.. index:: - single: inheritance - pair: class; name - pair: name; binding - pair: execution; frame - A class definition is an executable statement. It first evaluates the inheritance list, if present. Each item in the inheritance list should evaluate to a class object or class type which allows subclassing. The class's suite is @@ -535,13 +520,13 @@ to this class object in the original local namespace. **Programmer's note:** Variables defined in the class definition are class -variables; they are shared by all instances. To define instance variables, they -must be given a value in the :meth:`__init__` method or in another method. Both -class and instance variables are accessible through the notation -"``self.name``", and an instance variable hides a class variable with the same -name when accessed in this way. Class variables with immutable values can be -used as defaults for instance variables. For :term:`new-style class`\es, -descriptors can be used to create instance variables with different +variables; they are shared by all instances. To create instance variables, they +can be set in a method with ``self.name = value``. Both class and instance +variables are accessible through the notation "``self.name``", and an instance +variable hides a class variable with the same name when accessed in this way. +Class variables can be used as defaults for instance variables, but using +mutable values there can lead to unexpected results. For :term:`new-style +class`\es, descriptors can be used to create instance variables with different implementation details. .. rubric:: Footnotes @@ -552,4 +537,3 @@ .. [#] Currently, control "flows off the end" except in the case of an exception or the execution of a :keyword:`return`, :keyword:`continue`, or :keyword:`break` statement. - Modified: python/trunk/Doc/reference/datamodel.rst ============================================================================== --- python/trunk/Doc/reference/datamodel.rst (original) +++ python/trunk/Doc/reference/datamodel.rst Sat Jan 5 20:29:45 2008 @@ -1097,16 +1097,15 @@ in case of multiple inheritance. This manual is not up-to-date with respect to new-style classes. For now, -please see http://www.python.org/doc/newstyle.html for more information. +please see http://www.python.org/doc/newstyle/ for more information. .. index:: - single: class - single: class - single: class + single: class; new-style + single: class; classic + single: class; old-style The plan is to eventually drop old-style classes, leaving only the semantics of new-style classes. This change will probably only be feasible in Python 3.0. -new-style classic old-style .. _specialnames: @@ -2242,7 +2241,7 @@ extensive revision, it must now be taken as authoritative only regarding "classic classes", that are still the default, for compatibility purposes, in Python 2.2 and 2.3. For more information, see - http://www.python.org/doc/newstyle.html. + http://www.python.org/doc/newstyle/. .. [#] This, and other statements, are only roughly true for instances of new-style classes. Modified: python/trunk/Doc/reference/simple_stmts.rst ============================================================================== --- python/trunk/Doc/reference/simple_stmts.rst (original) +++ python/trunk/Doc/reference/simple_stmts.rst Sat Jan 5 20:29:45 2008 @@ -34,7 +34,9 @@ Expression statements ===================== -.. index:: pair: expression; statement +.. index:: + pair: expression; statement + pair: expression; list Expression statements are used (mostly interactively) to compute and write a value, or (usually) to call a procedure (a function that returns no meaningful @@ -45,8 +47,6 @@ .. productionlist:: expression_stmt: `expression_list` -.. index:: pair: expression; list - An expression statement evaluates the expression list (which may be a single expression). @@ -311,13 +311,13 @@ The :keyword:`pass` statement ============================= -.. index:: statement: pass +.. index:: + statement: pass + pair: null; operation .. productionlist:: pass_stmt: "pass" -.. index:: pair: null; operation - :keyword:`pass` is a null operation --- when it is executed, nothing happens. It is useful as a placeholder when a statement is required syntactically, but no code needs to be executed, for example:: @@ -332,15 +332,14 @@ The :keyword:`del` statement ============================ -.. index:: statement: del - -.. productionlist:: - del_stmt: "del" `target_list` - .. index:: + statement: del pair: deletion; target triple: deletion; target; list +.. productionlist:: + del_stmt: "del" `target_list` + Deletion is recursively defined very similar to the way assignment is defined. Rather that spelling it out in full details, here are some hints. @@ -399,8 +398,6 @@ .. index:: single: output pair: writing; values - -.. index:: pair: trailing; comma pair: newline; suppression @@ -434,15 +431,14 @@ The :keyword:`return` statement =============================== -.. index:: statement: return - -.. productionlist:: - return_stmt: "return" [`expression_list`] - .. index:: + statement: return pair: function; definition pair: class; definition +.. productionlist:: + return_stmt: "return" [`expression_list`] + :keyword:`return` may only occur syntactically nested in a function definition, not within a nested class definition. @@ -468,17 +464,16 @@ The :keyword:`yield` statement ============================== -.. index:: statement: yield - -.. productionlist:: - yield_stmt: `yield_expression` - .. index:: + statement: yield single: generator; function single: generator; iterator single: function; generator exception: StopIteration +.. productionlist:: + yield_stmt: `yield_expression` + The :keyword:`yield` statement is only used when defining a generator function, and is only used in the body of the generator function. Using a :keyword:`yield` statement in a function definition is sufficient to cause that definition to @@ -528,15 +523,14 @@ The :keyword:`raise` statement ============================== -.. index:: statement: raise - -.. productionlist:: - raise_stmt: "raise" [`expression` ["," `expression` ["," `expression`]]] - .. index:: + statement: raise single: exception pair: raising; exception +.. productionlist:: + raise_stmt: "raise" [`expression` ["," `expression` ["," `expression`]]] + If no expressions are present, :keyword:`raise` re-raises the last exception that was active in the current scope. If no exception is active in the current scope, a :exc:`TypeError` exception is raised indicating that this is an error @@ -578,16 +572,15 @@ The :keyword:`break` statement ============================== -.. index:: statement: break - -.. productionlist:: - break_stmt: "break" - .. index:: + statement: break statement: for statement: while pair: loop; statement +.. productionlist:: + break_stmt: "break" + :keyword:`break` may only occur syntactically nested in a :keyword:`for` or :keyword:`while` loop, but not nested in a function or class definition within that loop. @@ -614,17 +607,16 @@ The :keyword:`continue` statement ================================= -.. index:: statement: continue - -.. productionlist:: - continue_stmt: "continue" - .. index:: + statement: continue statement: for statement: while pair: loop; statement keyword: finally +.. productionlist:: + continue_stmt: "continue" + :keyword:`continue` may only occur syntactically nested in a :keyword:`for` or :keyword:`while` loop, but not nested in a function or class definition or :keyword:`finally` statement within that loop. [#]_ It continues with the next @@ -739,8 +731,6 @@ .. index:: keyword: from statement: from - -.. index:: triple: hierarchical; module; names single: packages single: __init__.py @@ -840,13 +830,13 @@ The :keyword:`global` statement =============================== -.. index:: statement: global +.. index:: + statement: global + triple: global; name; binding .. productionlist:: global_stmt: "global" `identifier` ("," `identifier`)* -.. index:: triple: global; name; binding - The :keyword:`global` statement is a declaration which holds for the entire current code block. It means that the listed identifiers are to be interpreted as globals. It would be impossible to assign to a global variable without @@ -908,7 +898,7 @@ variables, respectively. If provided, *locals* can be any mapping object. .. versionchanged:: 2.4 - formerly *locals* was required to be a dictionary. + Formerly, *locals* was required to be a dictionary. .. index:: single: __builtins__ From python-checkins at python.org Sat Jan 5 20:44:23 2008 From: python-checkins at python.org (georg.brandl) Date: Sat, 5 Jan 2008 20:44:23 +0100 (CET) Subject: [Python-checkins] r59744 - in python/trunk: Doc/c-api/newtypes.rst Doc/library/fcntl.rst Doc/library/functions.rst Doc/library/msvcrt.rst Doc/library/os.rst Doc/library/stdtypes.rst Doc/library/winsound.rst Doc/reference/expressions.rst Lib/test/test_doctest.py Modules/fcntlmodule.c Message-ID: <20080105194423.3DDDA1E400C@bag.python.org> Author: georg.brandl Date: Sat Jan 5 20:44:22 2008 New Revision: 59744 Modified: python/trunk/Doc/c-api/newtypes.rst python/trunk/Doc/library/fcntl.rst python/trunk/Doc/library/functions.rst python/trunk/Doc/library/msvcrt.rst python/trunk/Doc/library/os.rst python/trunk/Doc/library/stdtypes.rst python/trunk/Doc/library/winsound.rst python/trunk/Doc/reference/expressions.rst python/trunk/Lib/test/test_doctest.py python/trunk/Modules/fcntlmodule.c Log: Doc patch #1730 from Robin Stocker; minor corrections mostly to os.rst. Modified: python/trunk/Doc/c-api/newtypes.rst ============================================================================== --- python/trunk/Doc/c-api/newtypes.rst (original) +++ python/trunk/Doc/c-api/newtypes.rst Sat Jan 5 20:44:22 2008 @@ -746,7 +746,7 @@ indicated by the :const:`Py_TPFLAGS_HAVE_RICHCOMPARE` flag bit) and have *NULL* values. - The following bit masks are currently defined; these can be or-ed together using + The following bit masks are currently defined; these can be ORed together using the ``|`` operator to form the value of the :attr:`tp_flags` field. The macro :cfunc:`PyType_HasFeature` takes a type and a flags value, *tp* and *f*, and checks whether ``tp->tp_flags & f`` is non-zero. Modified: python/trunk/Doc/library/fcntl.rst ============================================================================== --- python/trunk/Doc/library/fcntl.rst (original) +++ python/trunk/Doc/library/fcntl.rst Sat Jan 5 20:44:22 2008 @@ -109,7 +109,7 @@ * :const:`LOCK_EX` -- acquire an exclusive lock When *operation* is :const:`LOCK_SH` or :const:`LOCK_EX`, it can also be - bit-wise OR'd with :const:`LOCK_NB` to avoid blocking on lock acquisition. + bitwise ORed with :const:`LOCK_NB` to avoid blocking on lock acquisition. If :const:`LOCK_NB` is used and the lock cannot be acquired, an :exc:`IOError` will be raised and the exception will have an *errno* attribute set to :const:`EACCES` or :const:`EAGAIN` (depending on the Modified: python/trunk/Doc/library/functions.rst ============================================================================== --- python/trunk/Doc/library/functions.rst (original) +++ python/trunk/Doc/library/functions.rst Sat Jan 5 20:44:22 2008 @@ -216,7 +216,7 @@ the *flags* argument is it -- the future statements in effect around the call to compile are ignored. - Future statements are specified by bits which can be bitwise or-ed together to + Future statements are specified by bits which can be bitwise ORed together to specify multiple statements. The bitfield required to specify a given feature can be found as the :attr:`compiler_flag` attribute on the :class:`_Feature` instance in the :mod:`__future__` module. Modified: python/trunk/Doc/library/msvcrt.rst ============================================================================== --- python/trunk/Doc/library/msvcrt.rst (original) +++ python/trunk/Doc/library/msvcrt.rst Sat Jan 5 20:44:22 2008 @@ -67,7 +67,7 @@ .. function:: open_osfhandle(handle, flags) Create a C runtime file descriptor from the file handle *handle*. The *flags* - parameter should be a bit-wise OR of :const:`os.O_APPEND`, :const:`os.O_RDONLY`, + parameter should be a bitwise OR of :const:`os.O_APPEND`, :const:`os.O_RDONLY`, and :const:`os.O_TEXT`. The returned file descriptor may be used as a parameter to :func:`os.fdopen` to create a file object. Modified: python/trunk/Doc/library/os.rst ============================================================================== --- python/trunk/Doc/library/os.rst (original) +++ python/trunk/Doc/library/os.rst Sat Jan 5 20:44:22 2008 @@ -7,7 +7,7 @@ This module provides a more portable way of using operating system dependent -functionality than importing a operating system dependent built-in module like +functionality than importing an operating system dependent built-in module like :mod:`posix` or :mod:`nt`. If you just want to read or write a file see :func:`open`, if you want to manipulate paths, see the :mod:`os.path` module, and if you want to read all the lines in all the files on the @@ -17,7 +17,7 @@ This module searches for an operating system dependent built-in module like :mod:`mac` or :mod:`posix` and exports the same functions and data as found -there. The design of all Python's built-in operating system dependent modules +there. The design of all built-in operating system dependent modules of Python is such that as long as the same functionality is available, it uses the same interface; for example, the function ``os.stat(path)`` returns stat information about *path* in the same format (which happens to have originated with the POSIX @@ -137,7 +137,7 @@ .. function:: getegid() Return the effective group id of the current process. This corresponds to the - 'set id' bit on the file being executed in the current process. Availability: + "set id" bit on the file being executed in the current process. Availability: Unix. @@ -145,7 +145,7 @@ .. index:: single: user; effective id - Return the current process' effective user id. Availability: Unix. + Return the current process's effective user id. Availability: Unix. .. function:: getgid() @@ -167,7 +167,7 @@ process. For most purposes, it is more useful to use the environment variable :envvar:`LOGNAME` to find out who the user is, or ``pwd.getpwuid(os.getuid())[0]`` to get the login name of the currently - effective user ID. Availability: Unix. + effective user id. Availability: Unix. .. function:: getpgid(pid) @@ -203,7 +203,7 @@ .. index:: single: user; id - Return the current process' user id. Availability: Unix. + Return the current process's user id. Availability: Unix. .. function:: getenv(varname[, value]) @@ -252,7 +252,7 @@ Set the list of supplemental group ids associated with the current process to *groups*. *groups* must be a sequence, and each element must be an integer - identifying a group. This operation is typical available only to the superuser. + identifying a group. This operation is typically available only to the superuser. Availability: Unix. .. versionadded:: 2.2 @@ -260,14 +260,14 @@ .. function:: setpgrp() - Calls the system call :cfunc:`setpgrp` or :cfunc:`setpgrp(0, 0)` depending on + Call the system call :cfunc:`setpgrp` or :cfunc:`setpgrp(0, 0)` depending on which version is implemented (if any). See the Unix manual for the semantics. Availability: Unix. .. function:: setpgid(pid, pgrp) - Calls the system call :cfunc:`setpgid` to set the process group id of the + Call the system call :cfunc:`setpgid` to set the process group id of the process with id *pid* to the process group with id *pgrp*. See the Unix manual for the semantics. Availability: Unix. @@ -284,7 +284,7 @@ .. function:: getsid(pid) - Calls the system call :cfunc:`getsid`. See the Unix manual for the semantics. + Call the system call :cfunc:`getsid`. See the Unix manual for the semantics. Availability: Unix. .. versionadded:: 2.4 @@ -292,7 +292,7 @@ .. function:: setsid() - Calls the system call :cfunc:`setsid`. See the Unix manual for the semantics. + Call the system call :cfunc:`setsid`. See the Unix manual for the semantics. Availability: Unix. @@ -300,7 +300,7 @@ .. index:: single: user; id, setting - Set the current process' user id. Availability: Unix. + Set the current process's user id. Availability: Unix. .. placed in this section since it relates to errno.... a little weak @@ -312,7 +312,7 @@ .. function:: umask(mask) - Set the current numeric umask and returns the previous umask. Availability: + Set the current numeric umask and return the previous umask. Availability: Unix, Windows. @@ -428,7 +428,7 @@ .. function:: popen2(cmd[, mode[, bufsize]]) - Executes *cmd* as a sub-process. Returns the file objects ``(child_stdin, + Execute *cmd* as a sub-process and return the file objects ``(child_stdin, child_stdout)``. .. deprecated:: 2.6 @@ -442,7 +442,7 @@ .. function:: popen3(cmd[, mode[, bufsize]]) - Executes *cmd* as a sub-process. Returns the file objects ``(child_stdin, + Execute *cmd* as a sub-process and return the file objects ``(child_stdin, child_stdout, child_stderr)``. .. deprecated:: 2.6 @@ -456,7 +456,7 @@ .. function:: popen4(cmd[, mode[, bufsize]]) - Executes *cmd* as a sub-process. Returns the file objects ``(child_stdin, + Execute *cmd* as a sub-process and return the file objects ``(child_stdin, child_stdout_and_stderr)``. .. deprecated:: 2.6 @@ -592,9 +592,10 @@ .. function:: lseek(fd, pos, how) - Set the current position of file descriptor *fd* to position *pos*, modified by - *how*: ``0`` to set the position relative to the beginning of the file; ``1`` to - set it relative to the current position; ``2`` to set it relative to the end of + Set the current position of file descriptor *fd* to position *pos*, modified + by *how*: :const:`SEEK_SET` or ``0`` to set the position relative to the + beginning of the file; :const:`SEEK_CUR` or ``1`` to set it relative to the + current position; :const:`os.SEEK_END` or ``2`` to set it relative to the end of the file. Availability: Macintosh, Unix, Windows. @@ -623,7 +624,7 @@ Open a new pseudo-terminal pair. Return a pair of file descriptors ``(master, slave)`` for the pty and the tty, respectively. For a (slightly) more portable - approach, use the :mod:`pty` module. Availability: Macintosh, Some flavors of + approach, use the :mod:`pty` module. Availability: Macintosh, some flavors of Unix. @@ -644,7 +645,7 @@ This function is intended for low-level I/O and must be applied to a file descriptor as returned by :func:`open` or :func:`pipe`. To read a "file object" returned by the built-in function :func:`open` or by :func:`popen` or - :func:`fdopen`, or ``sys.stdin``, use its :meth:`read` or :meth:`readline` + :func:`fdopen`, or :data:`sys.stdin`, use its :meth:`read` or :meth:`readline` methods. @@ -677,7 +678,7 @@ This function is intended for low-level I/O and must be applied to a file descriptor as returned by :func:`open` or :func:`pipe`. To write a "file object" returned by the built-in function :func:`open` or by :func:`popen` or - :func:`fdopen`, or ``sys.stdout`` or ``sys.stderr``, use its :meth:`write` + :func:`fdopen`, or :data:`sys.stdout` or :data:`sys.stderr`, use its :meth:`write` method. The following data items are available for use in constructing the *flags* @@ -695,7 +696,7 @@ O_TRUNC Options for the *flag* argument to the :func:`open` function. These can be - bit-wise OR'd together. Availability: Macintosh, Unix, Windows. + combined using the bitwise OR operator ``|``. Availability: Macintosh, Unix, Windows. .. data:: O_DSYNC @@ -720,7 +721,7 @@ O_TEXT Options for the *flag* argument to the :func:`open` function. These can be - bit-wise OR'd together. Availability: Windows. + combined using the bitwise OR operator ``|``. Availability: Windows. .. data:: O_DIRECT @@ -860,7 +861,7 @@ .. function:: chmod(path, mode) Change the mode of *path* to the numeric *mode*. *mode* may take one of the - following values (as defined in the :mod:`stat` module) or bitwise or-ed + following values (as defined in the :mod:`stat` module) or bitwise ORed combinations of them: @@ -919,7 +920,7 @@ .. function:: lchown(path, uid, gid) - Change the owner and group id of *path* to the numeric *uid* and gid. This + Change the owner and group id of *path* to the numeric *uid* and *gid*. This function will not follow symbolic links. Availability: Macintosh, Unix. .. versionadded:: 2.3 @@ -978,7 +979,7 @@ .. function:: major(device) - Extracts the device major number from a raw device number (usually the + Extract the device major number from a raw device number (usually the :attr:`st_dev` or :attr:`st_rdev` field from :ctype:`stat`). .. versionadded:: 2.3 @@ -986,7 +987,7 @@ .. function:: minor(device) - Extracts the device minor number from a raw device number (usually the + Extract the device minor number from a raw device number (usually the :attr:`st_dev` or :attr:`st_rdev` field from :ctype:`stat`). .. versionadded:: 2.3 @@ -994,7 +995,7 @@ .. function:: makedev(major, minor) - Composes a raw device number from the major and minor device numbers. + Compose a raw device number from the major and minor device numbers. .. versionadded:: 2.3 @@ -1024,7 +1025,7 @@ .. note:: :func:`makedirs` will become confused if the path elements to create include - *os.pardir*. + :data:`os.pardir`. .. versionadded:: 1.5.2 @@ -1085,7 +1086,7 @@ .. index:: single: directory; deleting - Removes directories recursively. Works like :func:`rmdir` except that, if the + Remove directories recursively. Works like :func:`rmdir` except that, if the leaf directory is successfully removed, :func:`removedirs` tries to successively remove every parent directory mentioned in *path* until an error is raised (which is ignored, because it generally means that a parent directory @@ -1101,7 +1102,7 @@ Rename the file or directory *src* to *dst*. If *dst* is a directory, :exc:`OSError` will be raised. On Unix, if *dst* exists and is a file, it will - be removed silently if the user has permission. The operation may fail on some + be replaced silently if the user has permission. The operation may fail on some Unix flavors if *src* and *dst* are on different filesystems. If successful, the renaming will be an atomic operation (this is a POSIX requirement). On Windows, if *dst* already exists, :exc:`OSError` will be raised even if it is a @@ -1135,7 +1136,7 @@ object whose attributes correspond to the members of the :ctype:`stat` structure, namely: :attr:`st_mode` (protection bits), :attr:`st_ino` (inode number), :attr:`st_dev` (device), :attr:`st_nlink` (number of hard links), - :attr:`st_uid` (user ID of owner), :attr:`st_gid` (group ID of owner), + :attr:`st_uid` (user id of owner), :attr:`st_gid` (group id of owner), :attr:`st_size` (size of file, in bytes), :attr:`st_atime` (time of most recent access), :attr:`st_mtime` (time of most recent content modification), :attr:`st_ctime` (platform dependent; time of most recent metadata change on @@ -1150,7 +1151,7 @@ >>> .. versionchanged:: 2.3 - If :func:`stat_float_times` returns true, the time values are floats, measuring + If :func:`stat_float_times` returns ``True``, the time values are floats, measuring seconds. Fractions of a second may be reported if the system supports that. On Mac OS, the times are always floats. See :func:`stat_float_times` for further discussion. @@ -1196,7 +1197,7 @@ Added access to values as attributes of the returned object. .. versionchanged:: 2.5 - Added st_gen, st_birthtime. + Added :attr:`st_gen` and :attr:`st_birthtime`. .. function:: stat_float_times([newvalue]) @@ -1261,7 +1262,7 @@ to the filename. Applications are responsible for properly creating and managing files created using paths returned by :func:`tempnam`; no automatic cleanup is provided. On Unix, the environment variable :envvar:`TMPDIR` - overrides *dir*, while on Windows the :envvar:`TMP` is used. The specific + overrides *dir*, while on Windows :envvar:`TMP` is used. The specific behavior of this function depends on the C library implementation; some aspects are underspecified in system documentation. @@ -1330,8 +1331,8 @@ single: directory; walking single: directory; traversal - :func:`walk` generates the file names in a directory tree, by walking the tree - either top down or bottom up. For each directory in the tree rooted at directory + Generate the file names in a directory tree by walking the tree + either top-down or bottom-up. For each directory in the tree rooted at directory *top* (including *top* itself), it yields a 3-tuple ``(dirpath, dirnames, filenames)``. @@ -1342,29 +1343,29 @@ (which begins with *top*) to a file or directory in *dirpath*, do ``os.path.join(dirpath, name)``. - If optional argument *topdown* is true or not specified, the triple for a + If optional argument *topdown* is ``True`` or not specified, the triple for a directory is generated before the triples for any of its subdirectories - (directories are generated top down). If *topdown* is false, the triple for a + (directories are generated top-down). If *topdown* is ``False``, the triple for a directory is generated after the triples for all of its subdirectories - (directories are generated bottom up). + (directories are generated bottom-up). - When *topdown* is true, the caller can modify the *dirnames* list in-place + When *topdown* is ``True``, the caller can modify the *dirnames* list in-place (perhaps using :keyword:`del` or slice assignment), and :func:`walk` will only recurse into the subdirectories whose names remain in *dirnames*; this can be used to prune the search, impose a specific order of visiting, or even to inform :func:`walk` about directories the caller creates or renames before it resumes - :func:`walk` again. Modifying *dirnames* when *topdown* is false is + :func:`walk` again. Modifying *dirnames* when *topdown* is ``False`` is ineffective, because in bottom-up mode the directories in *dirnames* are generated before *dirpath* itself is generated. - By default errors from the ``os.listdir()`` call are ignored. If optional + By default errors from the :func:`listdir` call are ignored. If optional argument *onerror* is specified, it should be a function; it will be called with one argument, an :exc:`OSError` instance. It can report the error to continue with the walk, or raise the exception to abort the walk. Note that the filename is available as the ``filename`` attribute of the exception object. By default, :func:`walk` will not walk down into symbolic links that resolve to - directories. Set *followlinks* to True to visit directories pointed to by + directories. Set *followlinks* to ``True`` to visit directories pointed to by symlinks, on systems that support them. .. versionadded:: 2.6 @@ -1372,7 +1373,7 @@ .. note:: - Be aware that setting *followlinks* to true can lead to infinite recursion if a + Be aware that setting *followlinks* to ``True`` can lead to infinite recursion if a link points to a parent directory of itself. :func:`walk` does not keep track of the directories it visited already. @@ -1395,10 +1396,10 @@ if 'CVS' in dirs: dirs.remove('CVS') # don't visit CVS directories - In the next example, walking the tree bottom up is essential: :func:`rmdir` + In the next example, walking the tree bottom-up is essential: :func:`rmdir` doesn't allow deleting a directory before the directory is empty:: - # Delete everything reachable from the directory named in 'top', + # Delete everything reachable from the directory named in "top", # assuming there are no symbolic links. # CAUTION: This is dangerous! For example, if top == '/', it # could delete all your disk files. @@ -1448,19 +1449,19 @@ These functions all execute a new program, replacing the current process; they do not return. On Unix, the new executable is loaded into the current process, - and will have the same process ID as the caller. Errors will be reported as + and will have the same process id as the caller. Errors will be reported as :exc:`OSError` exceptions. - The ``'l'`` and ``'v'`` variants of the :func:`exec\*` functions differ in how - command-line arguments are passed. The ``'l'`` variants are perhaps the easiest + The "l" and "v" variants of the :func:`exec\*` functions differ in how + command-line arguments are passed. The "l" variants are perhaps the easiest to work with if the number of parameters is fixed when the code is written; the individual parameters simply become additional parameters to the :func:`execl\*` - functions. The ``'v'`` variants are good when the number of parameters is + functions. The "v" variants are good when the number of parameters is variable, with the arguments being passed in a list or tuple as the *args* parameter. In either case, the arguments to the child process should start with the name of the command being run, but this is not enforced. - The variants which include a ``'p'`` near the end (:func:`execlp`, + The variants which include a "p" near the end (:func:`execlp`, :func:`execlpe`, :func:`execvp`, and :func:`execvpe`) will use the :envvar:`PATH` environment variable to locate the program *file*. When the environment is being replaced (using one of the :func:`exec\*e` variants, @@ -1471,7 +1472,7 @@ path. For :func:`execle`, :func:`execlpe`, :func:`execve`, and :func:`execvpe` (note - that these all end in ``'e'``), the *env* parameter must be a mapping which is + that these all end in "e"), the *env* parameter must be a mapping which is used to define the environment variables for the new process; the :func:`execl`, :func:`execlp`, :func:`execv`, and :func:`execvp` all cause the new process to inherit the environment of the current process. Availability: Macintosh, Unix, @@ -1488,7 +1489,7 @@ The standard way to exit is ``sys.exit(n)``. :func:`_exit` should normally only be used in the child process after a :func:`fork`. -The following exit codes are a defined, and can be used with :func:`_exit`, +The following exit codes are defined and can be used with :func:`_exit`, although they are not required. These are typically used for system programs written in Python, such as a mail server's external command delivery program. @@ -1638,7 +1639,7 @@ .. function:: fork() - Fork a child process. Return ``0`` in the child, the child's process id in the + Fork a child process. Return ``0`` in the child and the child's process id in the parent. Availability: Macintosh, Unix. @@ -1648,7 +1649,7 @@ terminal. Return a pair of ``(pid, fd)``, where *pid* is ``0`` in the child, the new child's process id in the parent, and *fd* is the file descriptor of the master end of the pseudo-terminal. For a more portable approach, use the - :mod:`pty` module. Availability: Macintosh, Some flavors of Unix. + :mod:`pty` module. Availability: Macintosh, some flavors of Unix. .. function:: kill(pid, sig) @@ -1712,22 +1713,22 @@ spawning new processes and retrieving their results; using that module is preferable to using these functions.) - If *mode* is :const:`P_NOWAIT`, this function returns the process ID of the new + If *mode* is :const:`P_NOWAIT`, this function returns the process id of the new process; if *mode* is :const:`P_WAIT`, returns the process's exit code if it exits normally, or ``-signal``, where *signal* is the signal that killed the - process. On Windows, the process ID will actually be the process handle, so can + process. On Windows, the process id will actually be the process handle, so can be used with the :func:`waitpid` function. - The ``'l'`` and ``'v'`` variants of the :func:`spawn\*` functions differ in how - command-line arguments are passed. The ``'l'`` variants are perhaps the easiest + The "l" and "v" variants of the :func:`spawn\*` functions differ in how + command-line arguments are passed. The "l" variants are perhaps the easiest to work with if the number of parameters is fixed when the code is written; the individual parameters simply become additional parameters to the - :func:`spawnl\*` functions. The ``'v'`` variants are good when the number of + :func:`spawnl\*` functions. The "v" variants are good when the number of parameters is variable, with the arguments being passed in a list or tuple as the *args* parameter. In either case, the arguments to the child process must start with the name of the command being run. - The variants which include a second ``'p'`` near the end (:func:`spawnlp`, + The variants which include a second "p" near the end (:func:`spawnlp`, :func:`spawnlpe`, :func:`spawnvp`, and :func:`spawnvpe`) will use the :envvar:`PATH` environment variable to locate the program *file*. When the environment is being replaced (using one of the :func:`spawn\*e` variants, @@ -1738,7 +1739,7 @@ appropriate absolute or relative path. For :func:`spawnle`, :func:`spawnlpe`, :func:`spawnve`, and :func:`spawnvpe` - (note that these all end in ``'e'``), the *env* parameter must be a mapping + (note that these all end in "e"), the *env* parameter must be a mapping which is used to define the environment variables for the new process; the :func:`spawnl`, :func:`spawnlp`, :func:`spawnv`, and :func:`spawnvp` all cause the new process to inherit the environment of the current process. @@ -1763,7 +1764,7 @@ Possible values for the *mode* parameter to the :func:`spawn\*` family of functions. If either of these values is given, the :func:`spawn\*` functions - will return as soon as the new process has been created, with the process ID as + will return as soon as the new process has been created, with the process id as the return value. Availability: Macintosh, Unix, Windows. .. versionadded:: 1.6 @@ -1825,8 +1826,8 @@ Execute the command (a string) in a subshell. This is implemented by calling the Standard C function :cfunc:`system`, and has the same limitations. Changes - to ``posix.environ``, ``sys.stdin``, etc. are not reflected in the environment - of the executed command. + to :data:`os.environ`, :data:`sys.stdin`, etc. are not reflected in the + environment of the executed command. On Unix, the return value is the exit status of the process encoded in the format specified for :func:`wait`. Note that POSIX does not specify the meaning @@ -1945,36 +1946,36 @@ .. function:: WCOREDUMP(status) - Returns ``True`` if a core dump was generated for the process, otherwise it - returns ``False``. Availability: Macintosh, Unix. + Return ``True`` if a core dump was generated for the process, otherwise + return ``False``. Availability: Macintosh, Unix. .. versionadded:: 2.3 .. function:: WIFCONTINUED(status) - Returns ``True`` if the process has been continued from a job control stop, - otherwise it returns ``False``. Availability: Unix. + Return ``True`` if the process has been continued from a job control stop, + otherwise return ``False``. Availability: Unix. .. versionadded:: 2.3 .. function:: WIFSTOPPED(status) - Returns ``True`` if the process has been stopped, otherwise it returns + Return ``True`` if the process has been stopped, otherwise return ``False``. Availability: Unix. .. function:: WIFSIGNALED(status) - Returns ``True`` if the process exited due to a signal, otherwise it returns + Return ``True`` if the process exited due to a signal, otherwise return ``False``. Availability: Macintosh, Unix. .. function:: WIFEXITED(status) - Returns ``True`` if the process exited using the :manpage:`exit(2)` system call, - otherwise it returns ``False``. Availability: Macintosh, Unix. + Return ``True`` if the process exited using the :manpage:`exit(2)` system call, + otherwise return ``False``. Availability: Macintosh, Unix. .. function:: WEXITSTATUS(status) @@ -2053,7 +2054,7 @@ defined for those names by the host operating system. This can be used to determine the set of names known to the system. Availability: Macintosh, Unix. -The follow data values are used to support path manipulation operations. These +The following data values are used to support path manipulation operations. These are defined for all platforms. Higher-level operations on pathnames are defined in the :mod:`os.path` module. Modified: python/trunk/Doc/library/stdtypes.rst ============================================================================== --- python/trunk/Doc/library/stdtypes.rst (original) +++ python/trunk/Doc/library/stdtypes.rst Sat Jan 5 20:44:22 2008 @@ -398,7 +398,7 @@ (for long integers, this assumes a sufficiently large number of bits that no overflow occurs during the operation). -The priorities of the binary bit-wise operations are all lower than the numeric +The priorities of the binary bitwise operations are all lower than the numeric operations and higher than the comparisons; the unary operation ``~`` has the same priority as the other unary numeric operations (``+`` and ``-``). @@ -2029,7 +2029,12 @@ argument is optional and defaults to ``os.SEEK_SET`` or ``0`` (absolute file positioning); other values are ``os.SEEK_CUR`` or ``1`` (seek relative to the current position) and ``os.SEEK_END`` or ``2`` (seek relative to the file's - end). There is no return value. Note that if the file is opened for appending + end). There is no return value. + + For example, ``f.seek(2, os.SEEK_CUR)`` advances the position by two and + ``f.seek(-3, os.SEEK_END)`` sets the position to the third to last. + + Note that if the file is opened for appending (mode ``'a'`` or ``'a+'``), any :meth:`seek` operations will be undone at the next write. If the file is only opened for writing in append mode (mode ``'a'``), this method is essentially a no-op, but it remains useful for files Modified: python/trunk/Doc/library/winsound.rst ============================================================================== --- python/trunk/Doc/library/winsound.rst (original) +++ python/trunk/Doc/library/winsound.rst Sat Jan 5 20:44:22 2008 @@ -36,7 +36,7 @@ Call the underlying :cfunc:`PlaySound` function from the Platform API. The *sound* parameter may be a filename, audio data as a string, or ``None``. Its - interpretation depends on the value of *flags*, which can be a bit-wise ORed + interpretation depends on the value of *flags*, which can be a bitwise ORed combination of the constants described below. If the system indicates an error, :exc:`RuntimeError` is raised. Modified: python/trunk/Doc/reference/expressions.rst ============================================================================== --- python/trunk/Doc/reference/expressions.rst (original) +++ python/trunk/Doc/reference/expressions.rst Sat Jan 5 20:44:22 2008 @@ -811,9 +811,9 @@ .. index:: triple: unary; arithmetic; operation - triple: unary; bit-wise; operation + triple: unary; bitwise; operation -All unary arithmetic (and bit-wise) operations have the same priority: +All unary arithmetic (and bitwise) operations have the same priority: .. productionlist:: u_expr: `power` | "-" `u_expr` | "+" `u_expr` | "~" `u_expr` @@ -830,8 +830,8 @@ .. index:: single: inversion -The unary ``~`` (invert) operator yields the bit-wise inversion of its plain or -long integer argument. The bit-wise inversion of ``x`` is defined as +The unary ``~`` (invert) operator yields the bitwise inversion of its plain or +long integer argument. The bitwise inversion of ``x`` is defined as ``-(x+1)``. It only applies to integral numbers. .. index:: exception: TypeError @@ -944,10 +944,10 @@ .. _bitwise: -Binary bit-wise operations -========================== +Binary bitwise operations +========================= -.. index:: triple: binary; bit-wise; operation +.. index:: triple: binary; bitwise; operation Each of the three bitwise operations has a different priority level: @@ -956,20 +956,20 @@ xor_expr: `and_expr` | `xor_expr` "^" `and_expr` or_expr: `xor_expr` | `or_expr` "|" `xor_expr` -.. index:: pair: bit-wise; and +.. index:: pair: bitwise; and The ``&`` operator yields the bitwise AND of its arguments, which must be plain or long integers. The arguments are converted to a common type. .. index:: - pair: bit-wise; xor + pair: bitwise; xor pair: exclusive; or The ``^`` operator yields the bitwise XOR (exclusive OR) of its arguments, which must be plain or long integers. The arguments are converted to a common type. .. index:: - pair: bit-wise; or + pair: bitwise; or pair: inclusive; or The ``|`` operator yields the bitwise (inclusive) OR of its arguments, which Modified: python/trunk/Lib/test/test_doctest.py ============================================================================== --- python/trunk/Lib/test/test_doctest.py (original) +++ python/trunk/Lib/test/test_doctest.py Sat Jan 5 20:44:22 2008 @@ -909,7 +909,7 @@ Several option flags can be used to customize the behavior of the test runner. These are defined as module constants in doctest, and passed -to the DocTestRunner constructor (multiple constants should be or-ed +to the DocTestRunner constructor (multiple constants should be ORed together). The DONT_ACCEPT_TRUE_FOR_1 flag disables matches between True/False Modified: python/trunk/Modules/fcntlmodule.c ============================================================================== --- python/trunk/Modules/fcntlmodule.c (original) +++ python/trunk/Modules/fcntlmodule.c Sat Jan 5 20:44:22 2008 @@ -378,7 +378,7 @@ LOCK_SH - acquire a shared lock\n\ LOCK_EX - acquire an exclusive lock\n\ \n\ -When operation is LOCK_SH or LOCK_EX, it can also be bit-wise OR'd with\n\ +When operation is LOCK_SH or LOCK_EX, it can also be bitwise ORed with\n\ LOCK_NB to avoid blocking on lock acquisition. If LOCK_NB is used and the\n\ lock cannot be acquired, an IOError will be raised and the exception will\n\ have an errno attribute set to EACCES or EAGAIN (depending on the operating\n\ From python-checkins at python.org Sat Jan 5 21:00:02 2008 From: python-checkins at python.org (georg.brandl) Date: Sat, 5 Jan 2008 21:00:02 +0100 (CET) Subject: [Python-checkins] r59745 - peps/trunk/pep-3100.txt Message-ID: <20080105200002.6F8411E400C@bag.python.org> Author: georg.brandl Date: Sat Jan 5 21:00:01 2008 New Revision: 59745 Modified: peps/trunk/pep-3100.txt Log: trunc() is done. Modified: peps/trunk/pep-3100.txt ============================================================================== --- peps/trunk/pep-3100.txt (original) +++ peps/trunk/pep-3100.txt Sat Jan 5 21:00:01 2008 @@ -173,7 +173,7 @@ If you need the old input(), use eval(input()). [done] * Introduce ``trunc()``, which would call the ``__trunc__()`` method on its argument; suggested use is for objects like float where calling ``__int__()`` - has data loss, but an integral representation is still desired? [8]_ + has data loss, but an integral representation is still desired? [8]_ [done] * Exception hierarchy changes [#pep352]_ [done] * Add a ``bin()`` function for a binary representation of integers [done] From buildbot at python.org Sat Jan 5 21:28:10 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 05 Jan 2008 20:28:10 +0000 Subject: [Python-checkins] buildbot failure in ppc Debian unstable trunk Message-ID: <20080105202810.36DF11E400C@bag.python.org> The Buildbot has detected a new failure of ppc Debian unstable trunk. Full details are available at: http://www.python.org/dev/buildbot/all/ppc%20Debian%20unstable%20trunk/builds/528 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: georg.brandl BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_xmlrpc ====================================================================== ERROR: test_fail_no_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_xmlrpc.py", line 560, in test_fail_no_info p.pow(6,8) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1157, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1447, in __request verbose=self.__verbose File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1195, in request errcode, errmsg, headers = h.getreply() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 1006, in getreply response = self._conn.getresponse() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 932, in getresponse response.begin() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 415, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 271, in readheaders line = self.fp.readline() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/socket.py", line 354, in readline data = recv(1) error: [Errno 104] Connection reset by peer ====================================================================== ERROR: test_fail_with_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_xmlrpc.py", line 580, in test_fail_with_info p.pow(6,8) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1157, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1447, in __request verbose=self.__verbose File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1195, in request errcode, errmsg, headers = h.getreply() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 1006, in getreply response = self._conn.getresponse() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 932, in getresponse response.begin() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 415, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 271, in readheaders line = self.fp.readline() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/socket.py", line 354, in readline data = recv(1) error: [Errno 104] Connection reset by peer make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Sat Jan 5 21:29:14 2008 From: python-checkins at python.org (georg.brandl) Date: Sat, 5 Jan 2008 21:29:14 +0100 (CET) Subject: [Python-checkins] r59749 - python/trunk/Doc/library/socket.rst Message-ID: <20080105202914.7D5DF1E4011@bag.python.org> Author: georg.brandl Date: Sat Jan 5 21:29:13 2008 New Revision: 59749 Modified: python/trunk/Doc/library/socket.rst Log: Revert socket.rst to unix-eol. Modified: python/trunk/Doc/library/socket.rst ============================================================================== --- python/trunk/Doc/library/socket.rst (original) +++ python/trunk/Doc/library/socket.rst Sat Jan 5 21:29:13 2008 @@ -1,906 +1,906 @@ - -:mod:`socket` --- Low-level networking interface -================================================ - -.. module:: socket - :synopsis: Low-level networking interface. - - -This module provides access to the BSD *socket* interface. It is available on -all modern Unix systems, Windows, Mac OS X, BeOS, OS/2, and probably additional -platforms. - -.. note:: - - Some behavior may be platform dependent, since calls are made to the operating - system socket APIs. - -For an introduction to socket programming (in C), see the following papers: An -Introductory 4.3BSD Interprocess Communication Tutorial, by Stuart Sechrest and -An Advanced 4.3BSD Interprocess Communication Tutorial, by Samuel J. Leffler et -al, both in the UNIX Programmer's Manual, Supplementary Documents 1 (sections -PS1:7 and PS1:8). The platform-specific reference material for the various -socket-related system calls are also a valuable source of information on the -details of socket semantics. For Unix, refer to the manual pages; for Windows, -see the WinSock (or Winsock 2) specification. For IPv6-ready APIs, readers may -want to refer to :rfc:`2553` titled Basic Socket Interface Extensions for IPv6. - -.. index:: object: socket - -The Python interface is a straightforward transliteration of the Unix system -call and library interface for sockets to Python's object-oriented style: the -:func:`socket` function returns a :dfn:`socket object` whose methods implement -the various socket system calls. Parameter types are somewhat higher-level than -in the C interface: as with :meth:`read` and :meth:`write` operations on Python -files, buffer allocation on receive operations is automatic, and buffer length -is implicit on send operations. - -Socket addresses are represented as follows: A single string is used for the -:const:`AF_UNIX` address family. A pair ``(host, port)`` is used for the -:const:`AF_INET` address family, where *host* is a string representing either a -hostname in Internet domain notation like ``'daring.cwi.nl'`` or an IPv4 address -like ``'100.50.200.5'``, and *port* is an integral port number. For -:const:`AF_INET6` address family, a four-tuple ``(host, port, flowinfo, -scopeid)`` is used, where *flowinfo* and *scopeid* represents ``sin6_flowinfo`` -and ``sin6_scope_id`` member in :const:`struct sockaddr_in6` in C. For -:mod:`socket` module methods, *flowinfo* and *scopeid* can be omitted just for -backward compatibility. Note, however, omission of *scopeid* can cause problems -in manipulating scoped IPv6 addresses. Other address families are currently not -supported. The address format required by a particular socket object is -automatically selected based on the address family specified when the socket -object was created. - -For IPv4 addresses, two special forms are accepted instead of a host address: -the empty string represents :const:`INADDR_ANY`, and the string -``''`` represents :const:`INADDR_BROADCAST`. The behavior is not -available for IPv6 for backward compatibility, therefore, you may want to avoid -these if you intend to support IPv6 with your Python programs. - -If you use a hostname in the *host* portion of IPv4/v6 socket address, the -program may show a nondeterministic behavior, as Python uses the first address -returned from the DNS resolution. The socket address will be resolved -differently into an actual IPv4/v6 address, depending on the results from DNS -resolution and/or the host configuration. For deterministic behavior use a -numeric address in *host* portion. - -.. versionadded:: 2.5 - AF_NETLINK sockets are represented as pairs ``pid, groups``. - -All errors raise exceptions. The normal exceptions for invalid argument types -and out-of-memory conditions can be raised; errors related to socket or address -semantics raise the error :exc:`socket.error`. - -Non-blocking mode is supported through :meth:`setblocking`. A generalization of -this based on timeouts is supported through :meth:`settimeout`. - -The module :mod:`socket` exports the following constants and functions: - - -.. exception:: error - - .. index:: module: errno - - This exception is raised for socket-related errors. The accompanying value is - either a string telling what went wrong or a pair ``(errno, string)`` - representing an error returned by a system call, similar to the value - accompanying :exc:`os.error`. See the module :mod:`errno`, which contains names - for the error codes defined by the underlying operating system. - - .. versionchanged:: 2.6 - :exc:`socket.error` is now a child class of :exc:`IOError`. - - -.. exception:: herror - - This exception is raised for address-related errors, i.e. for functions that use - *h_errno* in the C API, including :func:`gethostbyname_ex` and - :func:`gethostbyaddr`. - - The accompanying value is a pair ``(h_errno, string)`` representing an error - returned by a library call. *string* represents the description of *h_errno*, as - returned by the :cfunc:`hstrerror` C function. - - -.. exception:: gaierror - - This exception is raised for address-related errors, for :func:`getaddrinfo` and - :func:`getnameinfo`. The accompanying value is a pair ``(error, string)`` - representing an error returned by a library call. *string* represents the - description of *error*, as returned by the :cfunc:`gai_strerror` C function. The - *error* value will match one of the :const:`EAI_\*` constants defined in this - module. - - -.. exception:: timeout - - This exception is raised when a timeout occurs on a socket which has had - timeouts enabled via a prior call to :meth:`settimeout`. The accompanying value - is a string whose value is currently always "timed out". - - .. versionadded:: 2.3 - - -.. data:: AF_UNIX - AF_INET - AF_INET6 - - These constants represent the address (and protocol) families, used for the - first argument to :func:`socket`. If the :const:`AF_UNIX` constant is not - defined then this protocol is unsupported. - - -.. data:: SOCK_STREAM - SOCK_DGRAM - SOCK_RAW - SOCK_RDM - SOCK_SEQPACKET - - These constants represent the socket types, used for the second argument to - :func:`socket`. (Only :const:`SOCK_STREAM` and :const:`SOCK_DGRAM` appear to be - generally useful.) - - -.. data:: SO_* - SOMAXCONN - MSG_* - SOL_* - IPPROTO_* - IPPORT_* - INADDR_* - IP_* - IPV6_* - EAI_* - AI_* - NI_* - TCP_* - - Many constants of these forms, documented in the Unix documentation on sockets - and/or the IP protocol, are also defined in the socket module. They are - generally used in arguments to the :meth:`setsockopt` and :meth:`getsockopt` - methods of socket objects. In most cases, only those symbols that are defined - in the Unix header files are defined; for a few symbols, default values are - provided. - -.. data:: SIO_* - RCVALL_* - - Constants for Windows' WSAIoctl(). The constants are used as arguments to the - :meth:`ioctl` method of socket objects. - - .. versionadded:: 2.6 - - -.. data:: has_ipv6 - - This constant contains a boolean value which indicates if IPv6 is supported on - this platform. - - .. versionadded:: 2.3 - - -.. function:: create_connection(address[, timeout]) - - Connects to the *address* received (as usual, a ``(host, port)`` pair), with an - optional timeout for the connection. Especially useful for higher-level - protocols, it is not normally used directly from application-level code. - Passing the optional *timeout* parameter will set the timeout on the socket - instance (if it is not given or ``None``, the global default timeout setting is - used). - - .. versionadded:: 2.6 - - -.. function:: getaddrinfo(host, port[, family[, socktype[, proto[, flags]]]]) - - Resolves the *host*/*port* argument, into a sequence of 5-tuples that contain - all the necessary argument for the sockets manipulation. *host* is a domain - name, a string representation of IPv4/v6 address or ``None``. *port* is a string - service name (like ``'http'``), a numeric port number or ``None``. - - The rest of the arguments are optional and must be numeric if specified. For - *host* and *port*, by passing either an empty string or ``None``, you can pass - ``NULL`` to the C API. The :func:`getaddrinfo` function returns a list of - 5-tuples with the following structure: - - ``(family, socktype, proto, canonname, sockaddr)`` - - *family*, *socktype*, *proto* are all integer and are meant to be passed to the - :func:`socket` function. *canonname* is a string representing the canonical name - of the *host*. It can be a numeric IPv4/v6 address when :const:`AI_CANONNAME` is - specified for a numeric *host*. *sockaddr* is a tuple describing a socket - address, as described above. See the source for :mod:`socket` and other - library modules for a typical usage of the function. - - .. versionadded:: 2.2 - - -.. function:: getfqdn([name]) - - Return a fully qualified domain name for *name*. If *name* is omitted or empty, - it is interpreted as the local host. To find the fully qualified name, the - hostname returned by :func:`gethostbyaddr` is checked, then aliases for the - host, if available. The first name which includes a period is selected. In - case no fully qualified domain name is available, the hostname as returned by - :func:`gethostname` is returned. - - .. versionadded:: 2.0 - - -.. function:: gethostbyname(hostname) - - Translate a host name to IPv4 address format. The IPv4 address is returned as a - string, such as ``'100.50.200.5'``. If the host name is an IPv4 address itself - it is returned unchanged. See :func:`gethostbyname_ex` for a more complete - interface. :func:`gethostbyname` does not support IPv6 name resolution, and - :func:`getaddrinfo` should be used instead for IPv4/v6 dual stack support. - - -.. function:: gethostbyname_ex(hostname) - - Translate a host name to IPv4 address format, extended interface. Return a - triple ``(hostname, aliaslist, ipaddrlist)`` where *hostname* is the primary - host name responding to the given *ip_address*, *aliaslist* is a (possibly - empty) list of alternative host names for the same address, and *ipaddrlist* is - a list of IPv4 addresses for the same interface on the same host (often but not - always a single address). :func:`gethostbyname_ex` does not support IPv6 name - resolution, and :func:`getaddrinfo` should be used instead for IPv4/v6 dual - stack support. - - -.. function:: gethostname() - - Return a string containing the hostname of the machine where the Python - interpreter is currently executing. If you want to know the current machine's IP - address, you may want to use ``gethostbyname(gethostname())``. This operation - assumes that there is a valid address-to-host mapping for the host, and the - assumption does not always hold. Note: :func:`gethostname` doesn't always return - the fully qualified domain name; use ``getfqdn()`` (see above). - - -.. function:: gethostbyaddr(ip_address) - - Return a triple ``(hostname, aliaslist, ipaddrlist)`` where *hostname* is the - primary host name responding to the given *ip_address*, *aliaslist* is a - (possibly empty) list of alternative host names for the same address, and - *ipaddrlist* is a list of IPv4/v6 addresses for the same interface on the same - host (most likely containing only a single address). To find the fully qualified - domain name, use the function :func:`getfqdn`. :func:`gethostbyaddr` supports - both IPv4 and IPv6. - - -.. function:: getnameinfo(sockaddr, flags) - - Translate a socket address *sockaddr* into a 2-tuple ``(host, port)``. Depending - on the settings of *flags*, the result can contain a fully-qualified domain name - or numeric address representation in *host*. Similarly, *port* can contain a - string port name or a numeric port number. - - .. versionadded:: 2.2 - - -.. function:: getprotobyname(protocolname) - - Translate an Internet protocol name (for example, ``'icmp'``) to a constant - suitable for passing as the (optional) third argument to the :func:`socket` - function. This is usually only needed for sockets opened in "raw" mode - (:const:`SOCK_RAW`); for the normal socket modes, the correct protocol is chosen - automatically if the protocol is omitted or zero. - - -.. function:: getservbyname(servicename[, protocolname]) - - Translate an Internet service name and protocol name to a port number for that - service. The optional protocol name, if given, should be ``'tcp'`` or - ``'udp'``, otherwise any protocol will match. - - -.. function:: getservbyport(port[, protocolname]) - - Translate an Internet port number and protocol name to a service name for that - service. The optional protocol name, if given, should be ``'tcp'`` or - ``'udp'``, otherwise any protocol will match. - - -.. function:: socket([family[, type[, proto]]]) - - Create a new socket using the given address family, socket type and protocol - number. The address family should be :const:`AF_INET` (the default), - :const:`AF_INET6` or :const:`AF_UNIX`. The socket type should be - :const:`SOCK_STREAM` (the default), :const:`SOCK_DGRAM` or perhaps one of the - other ``SOCK_`` constants. The protocol number is usually zero and may be - omitted in that case. - - -.. function:: socketpair([family[, type[, proto]]]) - - Build a pair of connected socket objects using the given address family, socket - type, and protocol number. Address family, socket type, and protocol number are - as for the :func:`socket` function above. The default family is :const:`AF_UNIX` - if defined on the platform; otherwise, the default is :const:`AF_INET`. - Availability: Unix. - - .. versionadded:: 2.4 - - -.. function:: fromfd(fd, family, type[, proto]) - - Duplicate the file descriptor *fd* (an integer as returned by a file object's - :meth:`fileno` method) and build a socket object from the result. Address - family, socket type and protocol number are as for the :func:`socket` function - above. The file descriptor should refer to a socket, but this is not checked --- - subsequent operations on the object may fail if the file descriptor is invalid. - This function is rarely needed, but can be used to get or set socket options on - a socket passed to a program as standard input or output (such as a server - started by the Unix inet daemon). The socket is assumed to be in blocking mode. - Availability: Unix. - - -.. function:: ntohl(x) - - Convert 32-bit positive integers from network to host byte order. On machines - where the host byte order is the same as network byte order, this is a no-op; - otherwise, it performs a 4-byte swap operation. - - -.. function:: ntohs(x) - - Convert 16-bit positive integers from network to host byte order. On machines - where the host byte order is the same as network byte order, this is a no-op; - otherwise, it performs a 2-byte swap operation. - - -.. function:: htonl(x) - - Convert 32-bit positive integers from host to network byte order. On machines - where the host byte order is the same as network byte order, this is a no-op; - otherwise, it performs a 4-byte swap operation. - - -.. function:: htons(x) - - Convert 16-bit positive integers from host to network byte order. On machines - where the host byte order is the same as network byte order, this is a no-op; - otherwise, it performs a 2-byte swap operation. - - -.. function:: inet_aton(ip_string) - - Convert an IPv4 address from dotted-quad string format (for example, - '123.45.67.89') to 32-bit packed binary format, as a string four characters in - length. This is useful when conversing with a program that uses the standard C - library and needs objects of type :ctype:`struct in_addr`, which is the C type - for the 32-bit packed binary this function returns. - - If the IPv4 address string passed to this function is invalid, - :exc:`socket.error` will be raised. Note that exactly what is valid depends on - the underlying C implementation of :cfunc:`inet_aton`. - - :func:`inet_aton` does not support IPv6, and :func:`getnameinfo` should be used - instead for IPv4/v6 dual stack support. - - -.. function:: inet_ntoa(packed_ip) - - Convert a 32-bit packed IPv4 address (a string four characters in length) to its - standard dotted-quad string representation (for example, '123.45.67.89'). This - is useful when conversing with a program that uses the standard C library and - needs objects of type :ctype:`struct in_addr`, which is the C type for the - 32-bit packed binary data this function takes as an argument. - - If the string passed to this function is not exactly 4 bytes in length, - :exc:`socket.error` will be raised. :func:`inet_ntoa` does not support IPv6, and - :func:`getnameinfo` should be used instead for IPv4/v6 dual stack support. - - -.. function:: inet_pton(address_family, ip_string) - - Convert an IP address from its family-specific string format to a packed, binary - format. :func:`inet_pton` is useful when a library or network protocol calls for - an object of type :ctype:`struct in_addr` (similar to :func:`inet_aton`) or - :ctype:`struct in6_addr`. - - Supported values for *address_family* are currently :const:`AF_INET` and - :const:`AF_INET6`. If the IP address string *ip_string* is invalid, - :exc:`socket.error` will be raised. Note that exactly what is valid depends on - both the value of *address_family* and the underlying implementation of - :cfunc:`inet_pton`. - - Availability: Unix (maybe not all platforms). - - .. versionadded:: 2.3 - - -.. function:: inet_ntop(address_family, packed_ip) - - Convert a packed IP address (a string of some number of characters) to its - standard, family-specific string representation (for example, ``'7.10.0.5'`` or - ``'5aef:2b::8'``) :func:`inet_ntop` is useful when a library or network protocol - returns an object of type :ctype:`struct in_addr` (similar to :func:`inet_ntoa`) - or :ctype:`struct in6_addr`. - - Supported values for *address_family* are currently :const:`AF_INET` and - :const:`AF_INET6`. If the string *packed_ip* is not the correct length for the - specified address family, :exc:`ValueError` will be raised. A - :exc:`socket.error` is raised for errors from the call to :func:`inet_ntop`. - - Availability: Unix (maybe not all platforms). - - .. versionadded:: 2.3 - - -.. function:: getdefaulttimeout() - - Return the default timeout in floating seconds for new socket objects. A value - of ``None`` indicates that new socket objects have no timeout. When the socket - module is first imported, the default is ``None``. - - .. versionadded:: 2.3 - - -.. function:: setdefaulttimeout(timeout) - - Set the default timeout in floating seconds for new socket objects. A value of - ``None`` indicates that new socket objects have no timeout. When the socket - module is first imported, the default is ``None``. - - .. versionadded:: 2.3 - - -.. data:: SocketType - - This is a Python type object that represents the socket object type. It is the - same as ``type(socket(...))``. - - -.. seealso:: - - Module :mod:`SocketServer` - Classes that simplify writing network servers. - - -.. _socket-objects: - -Socket Objects --------------- - -Socket objects have the following methods. Except for :meth:`makefile` these -correspond to Unix system calls applicable to sockets. - - -.. method:: socket.accept() - - Accept a connection. The socket must be bound to an address and listening for - connections. The return value is a pair ``(conn, address)`` where *conn* is a - *new* socket object usable to send and receive data on the connection, and - *address* is the address bound to the socket on the other end of the connection. - - -.. method:: socket.bind(address) - - Bind the socket to *address*. The socket must not already be bound. (The format - of *address* depends on the address family --- see above.) - - .. note:: - - This method has historically accepted a pair of parameters for :const:`AF_INET` - addresses instead of only a tuple. This was never intentional and is no longer - available in Python 2.0 and later. - - -.. method:: socket.close() - - Close the socket. All future operations on the socket object will fail. The - remote end will receive no more data (after queued data is flushed). Sockets are - automatically closed when they are garbage-collected. - - -.. method:: socket.connect(address) - - Connect to a remote socket at *address*. (The format of *address* depends on the - address family --- see above.) - - .. note:: - - This method has historically accepted a pair of parameters for :const:`AF_INET` - addresses instead of only a tuple. This was never intentional and is no longer - available in Python 2.0 and later. - - -.. method:: socket.connect_ex(address) - - Like ``connect(address)``, but return an error indicator instead of raising an - exception for errors returned by the C-level :cfunc:`connect` call (other - problems, such as "host not found," can still raise exceptions). The error - indicator is ``0`` if the operation succeeded, otherwise the value of the - :cdata:`errno` variable. This is useful to support, for example, asynchronous - connects. - - .. note:: - - This method has historically accepted a pair of parameters for :const:`AF_INET` - addresses instead of only a tuple. This was never intentional and is no longer - available in Python 2.0 and later. - - -.. method:: socket.fileno() - - Return the socket's file descriptor (a small integer). This is useful with - :func:`select.select`. - - Under Windows the small integer returned by this method cannot be used where a - file descriptor can be used (such as :func:`os.fdopen`). Unix does not have - this limitation. - - -.. method:: socket.getpeername() - - Return the remote address to which the socket is connected. This is useful to - find out the port number of a remote IPv4/v6 socket, for instance. (The format - of the address returned depends on the address family --- see above.) On some - systems this function is not supported. - - -.. method:: socket.getsockname() - - Return the socket's own address. This is useful to find out the port number of - an IPv4/v6 socket, for instance. (The format of the address returned depends on - the address family --- see above.) - - -.. method:: socket.getsockopt(level, optname[, buflen]) - - Return the value of the given socket option (see the Unix man page - :manpage:`getsockopt(2)`). The needed symbolic constants (:const:`SO_\*` etc.) - are defined in this module. If *buflen* is absent, an integer option is assumed - and its integer value is returned by the function. If *buflen* is present, it - specifies the maximum length of the buffer used to receive the option in, and - this buffer is returned as a string. It is up to the caller to decode the - contents of the buffer (see the optional built-in module :mod:`struct` for a way - to decode C structures encoded as strings). - - -.. method:: socket.ioctl(control, option) - - :platform: Windows - - The `meth:ioctl` method is a limited interface to the WSAIoctl system - interface. Please refer to the MSDN documentation for more information. - - .. versionadded:: 2.6 - - -.. method:: socket.listen(backlog) - - Listen for connections made to the socket. The *backlog* argument specifies the - maximum number of queued connections and should be at least 1; the maximum value - is system-dependent (usually 5). - - -.. method:: socket.makefile([mode[, bufsize]]) - - .. index:: single: I/O control; buffering - - Return a :dfn:`file object` associated with the socket. (File objects are - described in :ref:`bltin-file-objects`.) The file object - references a :cfunc:`dup`\ ped version of the socket file descriptor, so the - file object and socket object may be closed or garbage-collected independently. - The socket must be in blocking mode (it can not have a timeout). The optional - *mode* and *bufsize* arguments are interpreted the same way as by the built-in - :func:`file` function. - - -.. method:: socket.recv(bufsize[, flags]) - - Receive data from the socket. The return value is a string representing the - data received. The maximum amount of data to be received at once is specified - by *bufsize*. See the Unix manual page :manpage:`recv(2)` for the meaning of - the optional argument *flags*; it defaults to zero. - - .. note:: - - For best match with hardware and network realities, the value of *bufsize* - should be a relatively small power of 2, for example, 4096. - - -.. method:: socket.recvfrom(bufsize[, flags]) - - Receive data from the socket. The return value is a pair ``(string, address)`` - where *string* is a string representing the data received and *address* is the - address of the socket sending the data. See the Unix manual page - :manpage:`recv(2)` for the meaning of the optional argument *flags*; it defaults - to zero. (The format of *address* depends on the address family --- see above.) - - -.. method:: socket.recvfrom_into(buffer[, nbytes[, flags]]) - - Receive data from the socket, writing it into *buffer* instead of creating a - new string. The return value is a pair ``(nbytes, address)`` where *nbytes* is - the number of bytes received and *address* is the address of the socket sending - the data. See the Unix manual page :manpage:`recv(2)` for the meaning of the - optional argument *flags*; it defaults to zero. (The format of *address* - depends on the address family --- see above.) - - .. versionadded:: 2.5 - - -.. method:: socket.recv_into(buffer[, nbytes[, flags]]) - - Receive up to *nbytes* bytes from the socket, storing the data into a buffer - rather than creating a new string. If *nbytes* is not specified (or 0), - receive up to the size available in the given buffer. See the Unix manual page - :manpage:`recv(2)` for the meaning of the optional argument *flags*; it defaults - to zero. - - .. versionadded:: 2.5 - - -.. method:: socket.send(string[, flags]) - - Send data to the socket. The socket must be connected to a remote socket. The - optional *flags* argument has the same meaning as for :meth:`recv` above. - Returns the number of bytes sent. Applications are responsible for checking that - all data has been sent; if only some of the data was transmitted, the - application needs to attempt delivery of the remaining data. - - -.. method:: socket.sendall(string[, flags]) - - Send data to the socket. The socket must be connected to a remote socket. The - optional *flags* argument has the same meaning as for :meth:`recv` above. - Unlike :meth:`send`, this method continues to send data from *string* until - either all data has been sent or an error occurs. ``None`` is returned on - success. On error, an exception is raised, and there is no way to determine how - much data, if any, was successfully sent. - - -.. method:: socket.sendto(string[, flags], address) - - Send data to the socket. The socket should not be connected to a remote socket, - since the destination socket is specified by *address*. The optional *flags* - argument has the same meaning as for :meth:`recv` above. Return the number of - bytes sent. (The format of *address* depends on the address family --- see - above.) - - -.. method:: socket.setblocking(flag) - - Set blocking or non-blocking mode of the socket: if *flag* is 0, the socket is - set to non-blocking, else to blocking mode. Initially all sockets are in - blocking mode. In non-blocking mode, if a :meth:`recv` call doesn't find any - data, or if a :meth:`send` call can't immediately dispose of the data, a - :exc:`error` exception is raised; in blocking mode, the calls block until they - can proceed. ``s.setblocking(0)`` is equivalent to ``s.settimeout(0)``; - ``s.setblocking(1)`` is equivalent to ``s.settimeout(None)``. - - -.. method:: socket.settimeout(value) - - Set a timeout on blocking socket operations. The *value* argument can be a - nonnegative float expressing seconds, or ``None``. If a float is given, - subsequent socket operations will raise an :exc:`timeout` exception if the - timeout period *value* has elapsed before the operation has completed. Setting - a timeout of ``None`` disables timeouts on socket operations. - ``s.settimeout(0.0)`` is equivalent to ``s.setblocking(0)``; - ``s.settimeout(None)`` is equivalent to ``s.setblocking(1)``. - - .. versionadded:: 2.3 - - -.. method:: socket.gettimeout() - - Return the timeout in floating seconds associated with socket operations, or - ``None`` if no timeout is set. This reflects the last call to - :meth:`setblocking` or :meth:`settimeout`. - - .. versionadded:: 2.3 - -Some notes on socket blocking and timeouts: A socket object can be in one of -three modes: blocking, non-blocking, or timeout. Sockets are always created in -blocking mode. In blocking mode, operations block until complete. In -non-blocking mode, operations fail (with an error that is unfortunately -system-dependent) if they cannot be completed immediately. In timeout mode, -operations fail if they cannot be completed within the timeout specified for the -socket. The :meth:`setblocking` method is simply a shorthand for certain -:meth:`settimeout` calls. - -Timeout mode internally sets the socket in non-blocking mode. The blocking and -timeout modes are shared between file descriptors and socket objects that refer -to the same network endpoint. A consequence of this is that file objects -returned by the :meth:`makefile` method must only be used when the socket is in -blocking mode; in timeout or non-blocking mode file operations that cannot be -completed immediately will fail. - -Note that the :meth:`connect` operation is subject to the timeout setting, and -in general it is recommended to call :meth:`settimeout` before calling -:meth:`connect`. - - -.. method:: socket.setsockopt(level, optname, value) - - .. index:: module: struct - - Set the value of the given socket option (see the Unix manual page - :manpage:`setsockopt(2)`). The needed symbolic constants are defined in the - :mod:`socket` module (:const:`SO_\*` etc.). The value can be an integer or a - string representing a buffer. In the latter case it is up to the caller to - ensure that the string contains the proper bits (see the optional built-in - module :mod:`struct` for a way to encode C structures as strings). - - -.. method:: socket.shutdown(how) - - Shut down one or both halves of the connection. If *how* is :const:`SHUT_RD`, - further receives are disallowed. If *how* is :const:`SHUT_WR`, further sends - are disallowed. If *how* is :const:`SHUT_RDWR`, further sends and receives are - disallowed. - -Note that there are no methods :meth:`read` or :meth:`write`; use :meth:`recv` -and :meth:`send` without *flags* argument instead. - -Socket objects also have these (read-only) attributes that correspond to the -values given to the :class:`socket` constructor. - - -.. attribute:: socket.family - - The socket family. - - .. versionadded:: 2.5 - - -.. attribute:: socket.type - - The socket type. - - .. versionadded:: 2.5 - - -.. attribute:: socket.proto - - The socket protocol. - - .. versionadded:: 2.5 - - -.. _socket-example: - -Example -------- - -Here are four minimal example programs using the TCP/IP protocol: a server that -echoes all data that it receives back (servicing only one client), and a client -using it. Note that a server must perform the sequence :func:`socket`, -:meth:`bind`, :meth:`listen`, :meth:`accept` (possibly repeating the -:meth:`accept` to service more than one client), while a client only needs the -sequence :func:`socket`, :meth:`connect`. Also note that the server does not -:meth:`send`/:meth:`recv` on the socket it is listening on but on the new -socket returned by :meth:`accept`. - -The first two examples support IPv4 only. :: - - # Echo server program - import socket - - HOST = '' # Symbolic name meaning the local host - PORT = 50007 # Arbitrary non-privileged port - s = socket.socket(socket.AF_INET, socket.SOCK_STREAM) - s.bind((HOST, PORT)) - s.listen(1) - conn, addr = s.accept() - print 'Connected by', addr - while 1: - data = conn.recv(1024) - if not data: break - conn.send(data) - conn.close() - -:: - - # Echo client program - import socket - - HOST = 'daring.cwi.nl' # The remote host - PORT = 50007 # The same port as used by the server - s = socket.socket(socket.AF_INET, socket.SOCK_STREAM) - s.connect((HOST, PORT)) - s.send('Hello, world') - data = s.recv(1024) - s.close() - print 'Received', repr(data) - -The next two examples are identical to the above two, but support both IPv4 and -IPv6. The server side will listen to the first address family available (it -should listen to both instead). On most of IPv6-ready systems, IPv6 will take -precedence and the server may not accept IPv4 traffic. The client side will try -to connect to the all addresses returned as a result of the name resolution, and -sends traffic to the first one connected successfully. :: - - # Echo server program - import socket - import sys - - HOST = '' # Symbolic name meaning the local host - PORT = 50007 # Arbitrary non-privileged port - s = None - for res in socket.getaddrinfo(HOST, PORT, socket.AF_UNSPEC, socket.SOCK_STREAM, 0, socket.AI_PASSIVE): - af, socktype, proto, canonname, sa = res - try: - s = socket.socket(af, socktype, proto) - except socket.error, msg: - s = None - continue - try: - s.bind(sa) - s.listen(1) - except socket.error, msg: - s.close() - s = None - continue - break - if s is None: - print 'could not open socket' - sys.exit(1) - conn, addr = s.accept() - print 'Connected by', addr - while 1: - data = conn.recv(1024) - if not data: break - conn.send(data) - conn.close() - -:: - - # Echo client program - import socket - import sys - - HOST = 'daring.cwi.nl' # The remote host - PORT = 50007 # The same port as used by the server - s = None - for res in socket.getaddrinfo(HOST, PORT, socket.AF_UNSPEC, socket.SOCK_STREAM): - af, socktype, proto, canonname, sa = res - try: - s = socket.socket(af, socktype, proto) - except socket.error, msg: - s = None - continue - try: - s.connect(sa) - except socket.error, msg: - s.close() - s = None - continue - break - if s is None: - print 'could not open socket' - sys.exit(1) - s.send('Hello, world') - data = s.recv(1024) - s.close() - print 'Received', repr(data) - - -The last example shows how to write a very simple network sniffer with raw -sockets on Windows. The example requires administrator priviliges to modify -the interface:: - - import socket - - # the public network interface - HOST = socket.gethostbyname(socket.gethostname()) - - # create a raw socket and bind it to the public interface - s = socket.socket(socket.AF_INET, socket.SOCK_RAW, socket.IPPROTO_IP) - s.bind((HOST, 0)) - - # Include IP headers - s.setsockopt(socket.IPPROTO_IP, socket.IP_HDRINCL, 1) - - # receive all packages - s.ioctl(socket.SIO_RCVALL, socket.RCVALL_ON) - - # receive a package - print s.recvfrom(65565) - - # disabled promiscous mode - s.ioctl(socket.SIO_RCVALL, socket.RCVALL_OFF) + +:mod:`socket` --- Low-level networking interface +================================================ + +.. module:: socket + :synopsis: Low-level networking interface. + + +This module provides access to the BSD *socket* interface. It is available on +all modern Unix systems, Windows, Mac OS X, BeOS, OS/2, and probably additional +platforms. + +.. note:: + + Some behavior may be platform dependent, since calls are made to the operating + system socket APIs. + +For an introduction to socket programming (in C), see the following papers: An +Introductory 4.3BSD Interprocess Communication Tutorial, by Stuart Sechrest and +An Advanced 4.3BSD Interprocess Communication Tutorial, by Samuel J. Leffler et +al, both in the UNIX Programmer's Manual, Supplementary Documents 1 (sections +PS1:7 and PS1:8). The platform-specific reference material for the various +socket-related system calls are also a valuable source of information on the +details of socket semantics. For Unix, refer to the manual pages; for Windows, +see the WinSock (or Winsock 2) specification. For IPv6-ready APIs, readers may +want to refer to :rfc:`2553` titled Basic Socket Interface Extensions for IPv6. + +.. index:: object: socket + +The Python interface is a straightforward transliteration of the Unix system +call and library interface for sockets to Python's object-oriented style: the +:func:`socket` function returns a :dfn:`socket object` whose methods implement +the various socket system calls. Parameter types are somewhat higher-level than +in the C interface: as with :meth:`read` and :meth:`write` operations on Python +files, buffer allocation on receive operations is automatic, and buffer length +is implicit on send operations. + +Socket addresses are represented as follows: A single string is used for the +:const:`AF_UNIX` address family. A pair ``(host, port)`` is used for the +:const:`AF_INET` address family, where *host* is a string representing either a +hostname in Internet domain notation like ``'daring.cwi.nl'`` or an IPv4 address +like ``'100.50.200.5'``, and *port* is an integral port number. For +:const:`AF_INET6` address family, a four-tuple ``(host, port, flowinfo, +scopeid)`` is used, where *flowinfo* and *scopeid* represents ``sin6_flowinfo`` +and ``sin6_scope_id`` member in :const:`struct sockaddr_in6` in C. For +:mod:`socket` module methods, *flowinfo* and *scopeid* can be omitted just for +backward compatibility. Note, however, omission of *scopeid* can cause problems +in manipulating scoped IPv6 addresses. Other address families are currently not +supported. The address format required by a particular socket object is +automatically selected based on the address family specified when the socket +object was created. + +For IPv4 addresses, two special forms are accepted instead of a host address: +the empty string represents :const:`INADDR_ANY`, and the string +``''`` represents :const:`INADDR_BROADCAST`. The behavior is not +available for IPv6 for backward compatibility, therefore, you may want to avoid +these if you intend to support IPv6 with your Python programs. + +If you use a hostname in the *host* portion of IPv4/v6 socket address, the +program may show a nondeterministic behavior, as Python uses the first address +returned from the DNS resolution. The socket address will be resolved +differently into an actual IPv4/v6 address, depending on the results from DNS +resolution and/or the host configuration. For deterministic behavior use a +numeric address in *host* portion. + +.. versionadded:: 2.5 + AF_NETLINK sockets are represented as pairs ``pid, groups``. + +All errors raise exceptions. The normal exceptions for invalid argument types +and out-of-memory conditions can be raised; errors related to socket or address +semantics raise the error :exc:`socket.error`. + +Non-blocking mode is supported through :meth:`setblocking`. A generalization of +this based on timeouts is supported through :meth:`settimeout`. + +The module :mod:`socket` exports the following constants and functions: + + +.. exception:: error + + .. index:: module: errno + + This exception is raised for socket-related errors. The accompanying value is + either a string telling what went wrong or a pair ``(errno, string)`` + representing an error returned by a system call, similar to the value + accompanying :exc:`os.error`. See the module :mod:`errno`, which contains names + for the error codes defined by the underlying operating system. + + .. versionchanged:: 2.6 + :exc:`socket.error` is now a child class of :exc:`IOError`. + + +.. exception:: herror + + This exception is raised for address-related errors, i.e. for functions that use + *h_errno* in the C API, including :func:`gethostbyname_ex` and + :func:`gethostbyaddr`. + + The accompanying value is a pair ``(h_errno, string)`` representing an error + returned by a library call. *string* represents the description of *h_errno*, as + returned by the :cfunc:`hstrerror` C function. + + +.. exception:: gaierror + + This exception is raised for address-related errors, for :func:`getaddrinfo` and + :func:`getnameinfo`. The accompanying value is a pair ``(error, string)`` + representing an error returned by a library call. *string* represents the + description of *error*, as returned by the :cfunc:`gai_strerror` C function. The + *error* value will match one of the :const:`EAI_\*` constants defined in this + module. + + +.. exception:: timeout + + This exception is raised when a timeout occurs on a socket which has had + timeouts enabled via a prior call to :meth:`settimeout`. The accompanying value + is a string whose value is currently always "timed out". + + .. versionadded:: 2.3 + + +.. data:: AF_UNIX + AF_INET + AF_INET6 + + These constants represent the address (and protocol) families, used for the + first argument to :func:`socket`. If the :const:`AF_UNIX` constant is not + defined then this protocol is unsupported. + + +.. data:: SOCK_STREAM + SOCK_DGRAM + SOCK_RAW + SOCK_RDM + SOCK_SEQPACKET + + These constants represent the socket types, used for the second argument to + :func:`socket`. (Only :const:`SOCK_STREAM` and :const:`SOCK_DGRAM` appear to be + generally useful.) + + +.. data:: SO_* + SOMAXCONN + MSG_* + SOL_* + IPPROTO_* + IPPORT_* + INADDR_* + IP_* + IPV6_* + EAI_* + AI_* + NI_* + TCP_* + + Many constants of these forms, documented in the Unix documentation on sockets + and/or the IP protocol, are also defined in the socket module. They are + generally used in arguments to the :meth:`setsockopt` and :meth:`getsockopt` + methods of socket objects. In most cases, only those symbols that are defined + in the Unix header files are defined; for a few symbols, default values are + provided. + +.. data:: SIO_* + RCVALL_* + + Constants for Windows' WSAIoctl(). The constants are used as arguments to the + :meth:`ioctl` method of socket objects. + + .. versionadded:: 2.6 + + +.. data:: has_ipv6 + + This constant contains a boolean value which indicates if IPv6 is supported on + this platform. + + .. versionadded:: 2.3 + + +.. function:: create_connection(address[, timeout]) + + Connects to the *address* received (as usual, a ``(host, port)`` pair), with an + optional timeout for the connection. Especially useful for higher-level + protocols, it is not normally used directly from application-level code. + Passing the optional *timeout* parameter will set the timeout on the socket + instance (if it is not given or ``None``, the global default timeout setting is + used). + + .. versionadded:: 2.6 + + +.. function:: getaddrinfo(host, port[, family[, socktype[, proto[, flags]]]]) + + Resolves the *host*/*port* argument, into a sequence of 5-tuples that contain + all the necessary argument for the sockets manipulation. *host* is a domain + name, a string representation of IPv4/v6 address or ``None``. *port* is a string + service name (like ``'http'``), a numeric port number or ``None``. + + The rest of the arguments are optional and must be numeric if specified. For + *host* and *port*, by passing either an empty string or ``None``, you can pass + ``NULL`` to the C API. The :func:`getaddrinfo` function returns a list of + 5-tuples with the following structure: + + ``(family, socktype, proto, canonname, sockaddr)`` + + *family*, *socktype*, *proto* are all integer and are meant to be passed to the + :func:`socket` function. *canonname* is a string representing the canonical name + of the *host*. It can be a numeric IPv4/v6 address when :const:`AI_CANONNAME` is + specified for a numeric *host*. *sockaddr* is a tuple describing a socket + address, as described above. See the source for :mod:`socket` and other + library modules for a typical usage of the function. + + .. versionadded:: 2.2 + + +.. function:: getfqdn([name]) + + Return a fully qualified domain name for *name*. If *name* is omitted or empty, + it is interpreted as the local host. To find the fully qualified name, the + hostname returned by :func:`gethostbyaddr` is checked, then aliases for the + host, if available. The first name which includes a period is selected. In + case no fully qualified domain name is available, the hostname as returned by + :func:`gethostname` is returned. + + .. versionadded:: 2.0 + + +.. function:: gethostbyname(hostname) + + Translate a host name to IPv4 address format. The IPv4 address is returned as a + string, such as ``'100.50.200.5'``. If the host name is an IPv4 address itself + it is returned unchanged. See :func:`gethostbyname_ex` for a more complete + interface. :func:`gethostbyname` does not support IPv6 name resolution, and + :func:`getaddrinfo` should be used instead for IPv4/v6 dual stack support. + + +.. function:: gethostbyname_ex(hostname) + + Translate a host name to IPv4 address format, extended interface. Return a + triple ``(hostname, aliaslist, ipaddrlist)`` where *hostname* is the primary + host name responding to the given *ip_address*, *aliaslist* is a (possibly + empty) list of alternative host names for the same address, and *ipaddrlist* is + a list of IPv4 addresses for the same interface on the same host (often but not + always a single address). :func:`gethostbyname_ex` does not support IPv6 name + resolution, and :func:`getaddrinfo` should be used instead for IPv4/v6 dual + stack support. + + +.. function:: gethostname() + + Return a string containing the hostname of the machine where the Python + interpreter is currently executing. If you want to know the current machine's IP + address, you may want to use ``gethostbyname(gethostname())``. This operation + assumes that there is a valid address-to-host mapping for the host, and the + assumption does not always hold. Note: :func:`gethostname` doesn't always return + the fully qualified domain name; use ``getfqdn()`` (see above). + + +.. function:: gethostbyaddr(ip_address) + + Return a triple ``(hostname, aliaslist, ipaddrlist)`` where *hostname* is the + primary host name responding to the given *ip_address*, *aliaslist* is a + (possibly empty) list of alternative host names for the same address, and + *ipaddrlist* is a list of IPv4/v6 addresses for the same interface on the same + host (most likely containing only a single address). To find the fully qualified + domain name, use the function :func:`getfqdn`. :func:`gethostbyaddr` supports + both IPv4 and IPv6. + + +.. function:: getnameinfo(sockaddr, flags) + + Translate a socket address *sockaddr* into a 2-tuple ``(host, port)``. Depending + on the settings of *flags*, the result can contain a fully-qualified domain name + or numeric address representation in *host*. Similarly, *port* can contain a + string port name or a numeric port number. + + .. versionadded:: 2.2 + + +.. function:: getprotobyname(protocolname) + + Translate an Internet protocol name (for example, ``'icmp'``) to a constant + suitable for passing as the (optional) third argument to the :func:`socket` + function. This is usually only needed for sockets opened in "raw" mode + (:const:`SOCK_RAW`); for the normal socket modes, the correct protocol is chosen + automatically if the protocol is omitted or zero. + + +.. function:: getservbyname(servicename[, protocolname]) + + Translate an Internet service name and protocol name to a port number for that + service. The optional protocol name, if given, should be ``'tcp'`` or + ``'udp'``, otherwise any protocol will match. + + +.. function:: getservbyport(port[, protocolname]) + + Translate an Internet port number and protocol name to a service name for that + service. The optional protocol name, if given, should be ``'tcp'`` or + ``'udp'``, otherwise any protocol will match. + + +.. function:: socket([family[, type[, proto]]]) + + Create a new socket using the given address family, socket type and protocol + number. The address family should be :const:`AF_INET` (the default), + :const:`AF_INET6` or :const:`AF_UNIX`. The socket type should be + :const:`SOCK_STREAM` (the default), :const:`SOCK_DGRAM` or perhaps one of the + other ``SOCK_`` constants. The protocol number is usually zero and may be + omitted in that case. + + +.. function:: socketpair([family[, type[, proto]]]) + + Build a pair of connected socket objects using the given address family, socket + type, and protocol number. Address family, socket type, and protocol number are + as for the :func:`socket` function above. The default family is :const:`AF_UNIX` + if defined on the platform; otherwise, the default is :const:`AF_INET`. + Availability: Unix. + + .. versionadded:: 2.4 + + +.. function:: fromfd(fd, family, type[, proto]) + + Duplicate the file descriptor *fd* (an integer as returned by a file object's + :meth:`fileno` method) and build a socket object from the result. Address + family, socket type and protocol number are as for the :func:`socket` function + above. The file descriptor should refer to a socket, but this is not checked --- + subsequent operations on the object may fail if the file descriptor is invalid. + This function is rarely needed, but can be used to get or set socket options on + a socket passed to a program as standard input or output (such as a server + started by the Unix inet daemon). The socket is assumed to be in blocking mode. + Availability: Unix. + + +.. function:: ntohl(x) + + Convert 32-bit positive integers from network to host byte order. On machines + where the host byte order is the same as network byte order, this is a no-op; + otherwise, it performs a 4-byte swap operation. + + +.. function:: ntohs(x) + + Convert 16-bit positive integers from network to host byte order. On machines + where the host byte order is the same as network byte order, this is a no-op; + otherwise, it performs a 2-byte swap operation. + + +.. function:: htonl(x) + + Convert 32-bit positive integers from host to network byte order. On machines + where the host byte order is the same as network byte order, this is a no-op; + otherwise, it performs a 4-byte swap operation. + + +.. function:: htons(x) + + Convert 16-bit positive integers from host to network byte order. On machines + where the host byte order is the same as network byte order, this is a no-op; + otherwise, it performs a 2-byte swap operation. + + +.. function:: inet_aton(ip_string) + + Convert an IPv4 address from dotted-quad string format (for example, + '123.45.67.89') to 32-bit packed binary format, as a string four characters in + length. This is useful when conversing with a program that uses the standard C + library and needs objects of type :ctype:`struct in_addr`, which is the C type + for the 32-bit packed binary this function returns. + + If the IPv4 address string passed to this function is invalid, + :exc:`socket.error` will be raised. Note that exactly what is valid depends on + the underlying C implementation of :cfunc:`inet_aton`. + + :func:`inet_aton` does not support IPv6, and :func:`getnameinfo` should be used + instead for IPv4/v6 dual stack support. + + +.. function:: inet_ntoa(packed_ip) + + Convert a 32-bit packed IPv4 address (a string four characters in length) to its + standard dotted-quad string representation (for example, '123.45.67.89'). This + is useful when conversing with a program that uses the standard C library and + needs objects of type :ctype:`struct in_addr`, which is the C type for the + 32-bit packed binary data this function takes as an argument. + + If the string passed to this function is not exactly 4 bytes in length, + :exc:`socket.error` will be raised. :func:`inet_ntoa` does not support IPv6, and + :func:`getnameinfo` should be used instead for IPv4/v6 dual stack support. + + +.. function:: inet_pton(address_family, ip_string) + + Convert an IP address from its family-specific string format to a packed, binary + format. :func:`inet_pton` is useful when a library or network protocol calls for + an object of type :ctype:`struct in_addr` (similar to :func:`inet_aton`) or + :ctype:`struct in6_addr`. + + Supported values for *address_family* are currently :const:`AF_INET` and + :const:`AF_INET6`. If the IP address string *ip_string* is invalid, + :exc:`socket.error` will be raised. Note that exactly what is valid depends on + both the value of *address_family* and the underlying implementation of + :cfunc:`inet_pton`. + + Availability: Unix (maybe not all platforms). + + .. versionadded:: 2.3 + + +.. function:: inet_ntop(address_family, packed_ip) + + Convert a packed IP address (a string of some number of characters) to its + standard, family-specific string representation (for example, ``'7.10.0.5'`` or + ``'5aef:2b::8'``) :func:`inet_ntop` is useful when a library or network protocol + returns an object of type :ctype:`struct in_addr` (similar to :func:`inet_ntoa`) + or :ctype:`struct in6_addr`. + + Supported values for *address_family* are currently :const:`AF_INET` and + :const:`AF_INET6`. If the string *packed_ip* is not the correct length for the + specified address family, :exc:`ValueError` will be raised. A + :exc:`socket.error` is raised for errors from the call to :func:`inet_ntop`. + + Availability: Unix (maybe not all platforms). + + .. versionadded:: 2.3 + + +.. function:: getdefaulttimeout() + + Return the default timeout in floating seconds for new socket objects. A value + of ``None`` indicates that new socket objects have no timeout. When the socket + module is first imported, the default is ``None``. + + .. versionadded:: 2.3 + + +.. function:: setdefaulttimeout(timeout) + + Set the default timeout in floating seconds for new socket objects. A value of + ``None`` indicates that new socket objects have no timeout. When the socket + module is first imported, the default is ``None``. + + .. versionadded:: 2.3 + + +.. data:: SocketType + + This is a Python type object that represents the socket object type. It is the + same as ``type(socket(...))``. + + +.. seealso:: + + Module :mod:`SocketServer` + Classes that simplify writing network servers. + + +.. _socket-objects: + +Socket Objects +-------------- + +Socket objects have the following methods. Except for :meth:`makefile` these +correspond to Unix system calls applicable to sockets. + + +.. method:: socket.accept() + + Accept a connection. The socket must be bound to an address and listening for + connections. The return value is a pair ``(conn, address)`` where *conn* is a + *new* socket object usable to send and receive data on the connection, and + *address* is the address bound to the socket on the other end of the connection. + + +.. method:: socket.bind(address) + + Bind the socket to *address*. The socket must not already be bound. (The format + of *address* depends on the address family --- see above.) + + .. note:: + + This method has historically accepted a pair of parameters for :const:`AF_INET` + addresses instead of only a tuple. This was never intentional and is no longer + available in Python 2.0 and later. + + +.. method:: socket.close() + + Close the socket. All future operations on the socket object will fail. The + remote end will receive no more data (after queued data is flushed). Sockets are + automatically closed when they are garbage-collected. + + +.. method:: socket.connect(address) + + Connect to a remote socket at *address*. (The format of *address* depends on the + address family --- see above.) + + .. note:: + + This method has historically accepted a pair of parameters for :const:`AF_INET` + addresses instead of only a tuple. This was never intentional and is no longer + available in Python 2.0 and later. + + +.. method:: socket.connect_ex(address) + + Like ``connect(address)``, but return an error indicator instead of raising an + exception for errors returned by the C-level :cfunc:`connect` call (other + problems, such as "host not found," can still raise exceptions). The error + indicator is ``0`` if the operation succeeded, otherwise the value of the + :cdata:`errno` variable. This is useful to support, for example, asynchronous + connects. + + .. note:: + + This method has historically accepted a pair of parameters for :const:`AF_INET` + addresses instead of only a tuple. This was never intentional and is no longer + available in Python 2.0 and later. + + +.. method:: socket.fileno() + + Return the socket's file descriptor (a small integer). This is useful with + :func:`select.select`. + + Under Windows the small integer returned by this method cannot be used where a + file descriptor can be used (such as :func:`os.fdopen`). Unix does not have + this limitation. + + +.. method:: socket.getpeername() + + Return the remote address to which the socket is connected. This is useful to + find out the port number of a remote IPv4/v6 socket, for instance. (The format + of the address returned depends on the address family --- see above.) On some + systems this function is not supported. + + +.. method:: socket.getsockname() + + Return the socket's own address. This is useful to find out the port number of + an IPv4/v6 socket, for instance. (The format of the address returned depends on + the address family --- see above.) + + +.. method:: socket.getsockopt(level, optname[, buflen]) + + Return the value of the given socket option (see the Unix man page + :manpage:`getsockopt(2)`). The needed symbolic constants (:const:`SO_\*` etc.) + are defined in this module. If *buflen* is absent, an integer option is assumed + and its integer value is returned by the function. If *buflen* is present, it + specifies the maximum length of the buffer used to receive the option in, and + this buffer is returned as a string. It is up to the caller to decode the + contents of the buffer (see the optional built-in module :mod:`struct` for a way + to decode C structures encoded as strings). + + +.. method:: socket.ioctl(control, option) + + :platform: Windows + + The `meth:ioctl` method is a limited interface to the WSAIoctl system + interface. Please refer to the MSDN documentation for more information. + + .. versionadded:: 2.6 + + +.. method:: socket.listen(backlog) + + Listen for connections made to the socket. The *backlog* argument specifies the + maximum number of queued connections and should be at least 1; the maximum value + is system-dependent (usually 5). + + +.. method:: socket.makefile([mode[, bufsize]]) + + .. index:: single: I/O control; buffering + + Return a :dfn:`file object` associated with the socket. (File objects are + described in :ref:`bltin-file-objects`.) The file object + references a :cfunc:`dup`\ ped version of the socket file descriptor, so the + file object and socket object may be closed or garbage-collected independently. + The socket must be in blocking mode (it can not have a timeout). The optional + *mode* and *bufsize* arguments are interpreted the same way as by the built-in + :func:`file` function. + + +.. method:: socket.recv(bufsize[, flags]) + + Receive data from the socket. The return value is a string representing the + data received. The maximum amount of data to be received at once is specified + by *bufsize*. See the Unix manual page :manpage:`recv(2)` for the meaning of + the optional argument *flags*; it defaults to zero. + + .. note:: + + For best match with hardware and network realities, the value of *bufsize* + should be a relatively small power of 2, for example, 4096. + + +.. method:: socket.recvfrom(bufsize[, flags]) + + Receive data from the socket. The return value is a pair ``(string, address)`` + where *string* is a string representing the data received and *address* is the + address of the socket sending the data. See the Unix manual page + :manpage:`recv(2)` for the meaning of the optional argument *flags*; it defaults + to zero. (The format of *address* depends on the address family --- see above.) + + +.. method:: socket.recvfrom_into(buffer[, nbytes[, flags]]) + + Receive data from the socket, writing it into *buffer* instead of creating a + new string. The return value is a pair ``(nbytes, address)`` where *nbytes* is + the number of bytes received and *address* is the address of the socket sending + the data. See the Unix manual page :manpage:`recv(2)` for the meaning of the + optional argument *flags*; it defaults to zero. (The format of *address* + depends on the address family --- see above.) + + .. versionadded:: 2.5 + + +.. method:: socket.recv_into(buffer[, nbytes[, flags]]) + + Receive up to *nbytes* bytes from the socket, storing the data into a buffer + rather than creating a new string. If *nbytes* is not specified (or 0), + receive up to the size available in the given buffer. See the Unix manual page + :manpage:`recv(2)` for the meaning of the optional argument *flags*; it defaults + to zero. + + .. versionadded:: 2.5 + + +.. method:: socket.send(string[, flags]) + + Send data to the socket. The socket must be connected to a remote socket. The + optional *flags* argument has the same meaning as for :meth:`recv` above. + Returns the number of bytes sent. Applications are responsible for checking that + all data has been sent; if only some of the data was transmitted, the + application needs to attempt delivery of the remaining data. + + +.. method:: socket.sendall(string[, flags]) + + Send data to the socket. The socket must be connected to a remote socket. The + optional *flags* argument has the same meaning as for :meth:`recv` above. + Unlike :meth:`send`, this method continues to send data from *string* until + either all data has been sent or an error occurs. ``None`` is returned on + success. On error, an exception is raised, and there is no way to determine how + much data, if any, was successfully sent. + + +.. method:: socket.sendto(string[, flags], address) + + Send data to the socket. The socket should not be connected to a remote socket, + since the destination socket is specified by *address*. The optional *flags* + argument has the same meaning as for :meth:`recv` above. Return the number of + bytes sent. (The format of *address* depends on the address family --- see + above.) + + +.. method:: socket.setblocking(flag) + + Set blocking or non-blocking mode of the socket: if *flag* is 0, the socket is + set to non-blocking, else to blocking mode. Initially all sockets are in + blocking mode. In non-blocking mode, if a :meth:`recv` call doesn't find any + data, or if a :meth:`send` call can't immediately dispose of the data, a + :exc:`error` exception is raised; in blocking mode, the calls block until they + can proceed. ``s.setblocking(0)`` is equivalent to ``s.settimeout(0)``; + ``s.setblocking(1)`` is equivalent to ``s.settimeout(None)``. + + +.. method:: socket.settimeout(value) + + Set a timeout on blocking socket operations. The *value* argument can be a + nonnegative float expressing seconds, or ``None``. If a float is given, + subsequent socket operations will raise an :exc:`timeout` exception if the + timeout period *value* has elapsed before the operation has completed. Setting + a timeout of ``None`` disables timeouts on socket operations. + ``s.settimeout(0.0)`` is equivalent to ``s.setblocking(0)``; + ``s.settimeout(None)`` is equivalent to ``s.setblocking(1)``. + + .. versionadded:: 2.3 + + +.. method:: socket.gettimeout() + + Return the timeout in floating seconds associated with socket operations, or + ``None`` if no timeout is set. This reflects the last call to + :meth:`setblocking` or :meth:`settimeout`. + + .. versionadded:: 2.3 + +Some notes on socket blocking and timeouts: A socket object can be in one of +three modes: blocking, non-blocking, or timeout. Sockets are always created in +blocking mode. In blocking mode, operations block until complete. In +non-blocking mode, operations fail (with an error that is unfortunately +system-dependent) if they cannot be completed immediately. In timeout mode, +operations fail if they cannot be completed within the timeout specified for the +socket. The :meth:`setblocking` method is simply a shorthand for certain +:meth:`settimeout` calls. + +Timeout mode internally sets the socket in non-blocking mode. The blocking and +timeout modes are shared between file descriptors and socket objects that refer +to the same network endpoint. A consequence of this is that file objects +returned by the :meth:`makefile` method must only be used when the socket is in +blocking mode; in timeout or non-blocking mode file operations that cannot be +completed immediately will fail. + +Note that the :meth:`connect` operation is subject to the timeout setting, and +in general it is recommended to call :meth:`settimeout` before calling +:meth:`connect`. + + +.. method:: socket.setsockopt(level, optname, value) + + .. index:: module: struct + + Set the value of the given socket option (see the Unix manual page + :manpage:`setsockopt(2)`). The needed symbolic constants are defined in the + :mod:`socket` module (:const:`SO_\*` etc.). The value can be an integer or a + string representing a buffer. In the latter case it is up to the caller to + ensure that the string contains the proper bits (see the optional built-in + module :mod:`struct` for a way to encode C structures as strings). + + +.. method:: socket.shutdown(how) + + Shut down one or both halves of the connection. If *how* is :const:`SHUT_RD`, + further receives are disallowed. If *how* is :const:`SHUT_WR`, further sends + are disallowed. If *how* is :const:`SHUT_RDWR`, further sends and receives are + disallowed. + +Note that there are no methods :meth:`read` or :meth:`write`; use :meth:`recv` +and :meth:`send` without *flags* argument instead. + +Socket objects also have these (read-only) attributes that correspond to the +values given to the :class:`socket` constructor. + + +.. attribute:: socket.family + + The socket family. + + .. versionadded:: 2.5 + + +.. attribute:: socket.type + + The socket type. + + .. versionadded:: 2.5 + + +.. attribute:: socket.proto + + The socket protocol. + + .. versionadded:: 2.5 + + +.. _socket-example: + +Example +------- + +Here are four minimal example programs using the TCP/IP protocol: a server that +echoes all data that it receives back (servicing only one client), and a client +using it. Note that a server must perform the sequence :func:`socket`, +:meth:`bind`, :meth:`listen`, :meth:`accept` (possibly repeating the +:meth:`accept` to service more than one client), while a client only needs the +sequence :func:`socket`, :meth:`connect`. Also note that the server does not +:meth:`send`/:meth:`recv` on the socket it is listening on but on the new +socket returned by :meth:`accept`. + +The first two examples support IPv4 only. :: + + # Echo server program + import socket + + HOST = '' # Symbolic name meaning the local host + PORT = 50007 # Arbitrary non-privileged port + s = socket.socket(socket.AF_INET, socket.SOCK_STREAM) + s.bind((HOST, PORT)) + s.listen(1) + conn, addr = s.accept() + print 'Connected by', addr + while 1: + data = conn.recv(1024) + if not data: break + conn.send(data) + conn.close() + +:: + + # Echo client program + import socket + + HOST = 'daring.cwi.nl' # The remote host + PORT = 50007 # The same port as used by the server + s = socket.socket(socket.AF_INET, socket.SOCK_STREAM) + s.connect((HOST, PORT)) + s.send('Hello, world') + data = s.recv(1024) + s.close() + print 'Received', repr(data) + +The next two examples are identical to the above two, but support both IPv4 and +IPv6. The server side will listen to the first address family available (it +should listen to both instead). On most of IPv6-ready systems, IPv6 will take +precedence and the server may not accept IPv4 traffic. The client side will try +to connect to the all addresses returned as a result of the name resolution, and +sends traffic to the first one connected successfully. :: + + # Echo server program + import socket + import sys + + HOST = '' # Symbolic name meaning the local host + PORT = 50007 # Arbitrary non-privileged port + s = None + for res in socket.getaddrinfo(HOST, PORT, socket.AF_UNSPEC, socket.SOCK_STREAM, 0, socket.AI_PASSIVE): + af, socktype, proto, canonname, sa = res + try: + s = socket.socket(af, socktype, proto) + except socket.error, msg: + s = None + continue + try: + s.bind(sa) + s.listen(1) + except socket.error, msg: + s.close() + s = None + continue + break + if s is None: + print 'could not open socket' + sys.exit(1) + conn, addr = s.accept() + print 'Connected by', addr + while 1: + data = conn.recv(1024) + if not data: break + conn.send(data) + conn.close() + +:: + + # Echo client program + import socket + import sys + + HOST = 'daring.cwi.nl' # The remote host + PORT = 50007 # The same port as used by the server + s = None + for res in socket.getaddrinfo(HOST, PORT, socket.AF_UNSPEC, socket.SOCK_STREAM): + af, socktype, proto, canonname, sa = res + try: + s = socket.socket(af, socktype, proto) + except socket.error, msg: + s = None + continue + try: + s.connect(sa) + except socket.error, msg: + s.close() + s = None + continue + break + if s is None: + print 'could not open socket' + sys.exit(1) + s.send('Hello, world') + data = s.recv(1024) + s.close() + print 'Received', repr(data) + + +The last example shows how to write a very simple network sniffer with raw +sockets on Windows. The example requires administrator priviliges to modify +the interface:: + + import socket + + # the public network interface + HOST = socket.gethostbyname(socket.gethostname()) + + # create a raw socket and bind it to the public interface + s = socket.socket(socket.AF_INET, socket.SOCK_RAW, socket.IPPROTO_IP) + s.bind((HOST, 0)) + + # Include IP headers + s.setsockopt(socket.IPPROTO_IP, socket.IP_HDRINCL, 1) + + # receive all packages + s.ioctl(socket.SIO_RCVALL, socket.RCVALL_ON) + + # receive a package + print s.recvfrom(65565) + + # disabled promiscous mode + s.ioctl(socket.SIO_RCVALL, socket.RCVALL_OFF) From python-checkins at python.org Sat Jan 5 21:33:47 2008 From: python-checkins at python.org (georg.brandl) Date: Sat, 5 Jan 2008 21:33:47 +0100 (CET) Subject: [Python-checkins] r59750 - in python/trunk/Doc: ACKS.txt Makefile README.txt TODO.txt about.rst bugs.rst c-api/abstract.rst c-api/concrete.rst c-api/exceptions.rst c-api/index.rst c-api/init.rst c-api/intro.rst c-api/memory.rst c-api/newtypes.rst c-api/refcounting.rst c-api/utilities.rst c-api/veryhigh.rst conf.py contents.rst copyright.rst distutils/apiref.rst distutils/builtdist.rst distutils/commandref.rst distutils/configfile.rst distutils/examples.rst distutils/extending.rst distutils/index.rst distutils/introduction.rst distutils/packageindex.rst distutils/setupscript.rst distutils/sourcedist.rst distutils/uploading.rst documenting/fromlatex.rst documenting/index.rst documenting/intro.rst documenting/markup.rst documenting/rest.rst documenting/sphinx.rst documenting/style.rst extending/building.rst extending/embedding.rst extending/extending.rst extending/index.rst extending/newtypes.rst extending/windows.rst glossary.rst howto/advocacy.rst howto/curses.rst howto/doanddont.rst howto/functional.rst howto/index.rst howto/regex.rst howto/sockets.rst howto/unicode.rst howto/urllib2.rst includes/email-dir.py includes/email-mime.py includes/email-simple.py includes/email-unpack.py includes/minidom-example.py includes/setup.py includes/sqlite3/adapter_datetime.py includes/sqlite3/adapter_point_1.py includes/sqlite3/adapter_point_2.py includes/sqlite3/collation_reverse.py includes/sqlite3/complete_statement.py includes/sqlite3/connect_db_1.py includes/sqlite3/connect_db_2.py includes/sqlite3/converter_point.py includes/sqlite3/countcursors.py includes/sqlite3/createdb.py includes/sqlite3/execsql_fetchonerow.py includes/sqlite3/execsql_printall_1.py includes/sqlite3/execute_1.py includes/sqlite3/execute_2.py includes/sqlite3/execute_3.py includes/sqlite3/executemany_1.py includes/sqlite3/executemany_2.py includes/sqlite3/executescript.py includes/sqlite3/insert_more_people.py includes/sqlite3/md5func.py includes/sqlite3/mysumaggr.py includes/sqlite3/parse_colnames.py includes/sqlite3/pysqlite_datetime.py includes/sqlite3/row_factory.py includes/sqlite3/rowclass.py includes/sqlite3/shared_cache.py includes/sqlite3/shortcut_methods.py includes/sqlite3/simple_tableprinter.py includes/sqlite3/text_factory.py includes/test.py includes/tzinfo-examples.py install/index.rst library/__builtin__.rst library/__future__.rst library/__main__.rst library/_ast.rst library/_winreg.rst library/aepack.rst library/aetools.rst library/aetypes.rst library/aifc.rst library/al.rst library/allos.rst library/anydbm.rst library/archiving.rst library/array.rst library/asynchat.rst library/asyncore.rst library/atexit.rst library/audioop.rst library/autogil.rst library/base64.rst library/basehttpserver.rst library/bastion.rst library/bdb.rst library/binascii.rst library/binhex.rst library/bisect.rst library/bsddb.rst library/bz2.rst library/calendar.rst library/carbon.rst library/cd.rst library/cgi.rst library/cgihttpserver.rst library/cgitb.rst library/chunk.rst library/cmath.rst library/cmd.rst library/code.rst library/codecs.rst library/codeop.rst library/collections.rst library/colorpicker.rst library/colorsys.rst library/commands.rst library/compileall.rst library/compiler.rst library/configparser.rst library/constants.rst library/contextlib.rst library/cookie.rst library/cookielib.rst library/copy.rst library/copy_reg.rst library/crypt.rst library/crypto.rst library/csv.rst library/ctypes.rst library/curses.ascii.rst library/curses.panel.rst library/curses.rst library/custominterp.rst library/datatypes.rst library/datetime.rst library/dbhash.rst library/dbm.rst library/debug.rst library/decimal.rst library/development.rst library/difflib.rst library/dircache.rst library/dis.rst library/distutils.rst library/dl.rst library/doctest.rst library/docxmlrpcserver.rst library/dumbdbm.rst library/dummy_thread.rst library/dummy_threading.rst library/easydialogs.rst library/email-examples.rst library/email.charset.rst library/email.encoders.rst library/email.errors.rst library/email.generator.rst library/email.header.rst library/email.iterators.rst library/email.message.rst library/email.mime.rst library/email.parser.rst library/email.rst library/email.util.rst library/errno.rst library/exceptions.rst library/fcntl.rst library/filecmp.rst library/fileformats.rst library/fileinput.rst library/filesys.rst library/fl.rst library/fm.rst library/fnmatch.rst library/formatter.rst library/fpectl.rst library/fpformat.rst library/framework.rst library/frameworks.rst library/ftplib.rst library/functions.rst library/functools.rst library/gc.rst library/gdbm.rst library/gensuitemodule.rst library/getopt.rst library/getpass.rst library/gettext.rst library/gl.rst library/glob.rst library/grp.rst library/gzip.rst library/hashlib.rst library/heapq.rst library/hmac.rst library/hotshot.rst library/htmllib.rst library/htmlparser.rst library/httplib.rst library/i18n.rst library/ic.rst library/idle.rst library/imageop.rst library/imaplib.rst library/imgfile.rst library/imghdr.rst library/imp.rst library/imputil.rst library/index.rst library/inspect.rst library/internet.rst library/intro.rst library/ipc.rst library/itertools.rst library/jpeg.rst library/keyword.rst library/language.rst library/linecache.rst library/locale.rst library/logging.rst library/mac.rst library/macos.rst library/macosa.rst library/macostools.rst library/macpath.rst library/mailbox.rst library/mailcap.rst library/markup.rst library/marshal.rst library/math.rst library/md5.rst library/mhlib.rst library/mimetools.rst library/mimetypes.rst library/mimewriter.rst library/mimify.rst library/miniaeframe.rst library/misc.rst library/mm.rst library/mmap.rst library/modulefinder.rst library/modules.rst library/msilib.rst library/msvcrt.rst library/multifile.rst library/mutex.rst library/netdata.rst library/netrc.rst library/new.rst library/nis.rst library/nntplib.rst library/numbers.rst library/numeric.rst library/objects.rst library/operator.rst library/optparse.rst library/os.path.rst library/os.rst library/ossaudiodev.rst library/othergui.rst library/parser.rst library/pdb.rst library/persistence.rst library/pickle.rst library/pickletools.rst library/pipes.rst library/pkgutil.rst library/platform.rst library/popen2.rst library/poplib.rst library/posix.rst library/posixfile.rst library/pprint.rst library/profile.rst library/pty.rst library/pwd.rst library/py_compile.rst library/pyclbr.rst library/pydoc.rst library/pyexpat.rst library/python.rst library/queue.rst library/quopri.rst library/random.rst library/re.rst library/readline.rst library/repr.rst library/resource.rst library/restricted.rst library/rexec.rst library/rfc822.rst library/rlcompleter.rst library/robotparser.rst library/runpy.rst library/sched.rst library/scrolledtext.rst library/select.rst library/sets.rst library/sgi.rst library/sgmllib.rst library/sha.rst library/shelve.rst library/shlex.rst library/shutil.rst library/signal.rst library/simplehttpserver.rst library/simplexmlrpcserver.rst library/site.rst library/smtpd.rst library/smtplib.rst library/sndhdr.rst library/socket.rst library/socketserver.rst library/someos.rst library/spwd.rst library/sqlite3.rst library/stat.rst library/statvfs.rst library/stdtypes.rst library/string.rst library/stringio.rst library/stringprep.rst library/strings.rst library/struct.rst library/subprocess.rst library/sun.rst library/sunau.rst library/sunaudio.rst library/symbol.rst library/sys.rst library/syslog.rst library/tabnanny.rst library/tarfile.rst library/telnetlib.rst library/tempfile.rst library/termios.rst library/test.rst library/textwrap.rst library/thread.rst library/threading.rst library/time.rst library/timeit.rst library/tix.rst library/tk.rst library/tkinter.rst library/token.rst library/tokenize.rst library/trace.rst library/traceback.rst library/tty.rst library/turtle.rst library/types.rst library/undoc.rst library/unicodedata.rst library/unittest.rst library/unix.rst library/urllib.rst library/urllib2.rst library/urlparse.rst library/user.rst library/userdict.rst library/uu.rst library/uuid.rst library/warnings.rst library/wave.rst library/weakref.rst library/webbrowser.rst library/whichdb.rst library/windows.rst library/winsound.rst library/wsgiref.rst library/xdrlib.rst library/xml.dom.minidom.rst library/xml.dom.pulldom.rst library/xml.dom.rst library/xml.etree.elementtree.rst library/xml.etree.rst library/xml.sax.handler.rst library/xml.sax.reader.rst library/xml.sax.rst library/xml.sax.utils.rst library/xmllib.rst library/xmlrpclib.rst library/zipfile.rst library/zipimport.rst library/zlib.rst license.rst reference/compound_stmts.rst reference/datamodel.rst reference/executionmodel.rst reference/expressions.rst reference/index.rst reference/introduction.rst reference/lexical_analysis.rst reference/simple_stmts.rst reference/toplevel_components.rst tools/roman.py tools/sphinx-build.py tools/sphinx-web.py tutorial/appetite.rst tutorial/classes.rst tutorial/controlflow.rst tutorial/datastructures.rst tutorial/errors.rst tutorial/floatingpoint.rst tutorial/index.rst tutorial/inputoutput.rst tutorial/interactive.rst tutorial/interpreter.rst tutorial/introduction.rst tutorial/modules.rst tutorial/stdlib.rst tutorial/stdlib2.rst tutorial/whatnow.rst using/cmdline.rst using/index.rst using/mac.rst using/unix.rst using/windows.rst whatsnew/2.0.rst whatsnew/2.1.rst whatsnew/2.2.rst whatsnew/2.3.rst whatsnew/2.4.rst whatsnew/2.5.rst whatsnew/2.6.rst Message-ID: <20080105203347.BA54A1E400C@bag.python.org> Author: georg.brandl Date: Sat Jan 5 21:33:46 2008 New Revision: 59750 Modified: python/trunk/Doc/ACKS.txt (props changed) python/trunk/Doc/Makefile (props changed) python/trunk/Doc/README.txt (props changed) python/trunk/Doc/TODO.txt (props changed) python/trunk/Doc/about.rst (props changed) python/trunk/Doc/bugs.rst (props changed) python/trunk/Doc/c-api/abstract.rst (props changed) python/trunk/Doc/c-api/concrete.rst (props changed) python/trunk/Doc/c-api/exceptions.rst (props changed) python/trunk/Doc/c-api/index.rst (props changed) python/trunk/Doc/c-api/init.rst (props changed) python/trunk/Doc/c-api/intro.rst (props changed) python/trunk/Doc/c-api/memory.rst (props changed) python/trunk/Doc/c-api/newtypes.rst (props changed) python/trunk/Doc/c-api/refcounting.rst (props changed) python/trunk/Doc/c-api/utilities.rst (props changed) python/trunk/Doc/c-api/veryhigh.rst (props changed) python/trunk/Doc/conf.py (props changed) python/trunk/Doc/contents.rst (props changed) python/trunk/Doc/copyright.rst (props changed) python/trunk/Doc/distutils/apiref.rst (props changed) python/trunk/Doc/distutils/builtdist.rst (props changed) python/trunk/Doc/distutils/commandref.rst (props changed) python/trunk/Doc/distutils/configfile.rst (props changed) python/trunk/Doc/distutils/examples.rst (props changed) python/trunk/Doc/distutils/extending.rst (props changed) python/trunk/Doc/distutils/index.rst (props changed) python/trunk/Doc/distutils/introduction.rst (props changed) python/trunk/Doc/distutils/packageindex.rst (props changed) python/trunk/Doc/distutils/setupscript.rst (props changed) python/trunk/Doc/distutils/sourcedist.rst (props changed) python/trunk/Doc/distutils/uploading.rst (props changed) python/trunk/Doc/documenting/fromlatex.rst (props changed) python/trunk/Doc/documenting/index.rst (props changed) python/trunk/Doc/documenting/intro.rst (props changed) python/trunk/Doc/documenting/markup.rst (props changed) python/trunk/Doc/documenting/rest.rst (props changed) python/trunk/Doc/documenting/sphinx.rst (props changed) python/trunk/Doc/documenting/style.rst (props changed) python/trunk/Doc/extending/building.rst (props changed) python/trunk/Doc/extending/embedding.rst (props changed) python/trunk/Doc/extending/extending.rst (props changed) python/trunk/Doc/extending/index.rst (props changed) python/trunk/Doc/extending/newtypes.rst (props changed) python/trunk/Doc/extending/windows.rst (props changed) python/trunk/Doc/glossary.rst (props changed) python/trunk/Doc/howto/advocacy.rst (props changed) python/trunk/Doc/howto/curses.rst (props changed) python/trunk/Doc/howto/doanddont.rst (props changed) python/trunk/Doc/howto/functional.rst (props changed) python/trunk/Doc/howto/index.rst (props changed) python/trunk/Doc/howto/regex.rst (props changed) python/trunk/Doc/howto/sockets.rst (props changed) python/trunk/Doc/howto/unicode.rst (props changed) python/trunk/Doc/howto/urllib2.rst (props changed) python/trunk/Doc/includes/email-dir.py (props changed) python/trunk/Doc/includes/email-mime.py (props changed) python/trunk/Doc/includes/email-simple.py (props changed) python/trunk/Doc/includes/email-unpack.py (props changed) python/trunk/Doc/includes/minidom-example.py (props changed) python/trunk/Doc/includes/setup.py (props changed) python/trunk/Doc/includes/sqlite3/adapter_datetime.py (props changed) python/trunk/Doc/includes/sqlite3/adapter_point_1.py (props changed) python/trunk/Doc/includes/sqlite3/adapter_point_2.py (props changed) python/trunk/Doc/includes/sqlite3/collation_reverse.py (props changed) python/trunk/Doc/includes/sqlite3/complete_statement.py (props changed) python/trunk/Doc/includes/sqlite3/connect_db_1.py (props changed) python/trunk/Doc/includes/sqlite3/connect_db_2.py (props changed) python/trunk/Doc/includes/sqlite3/converter_point.py (props changed) python/trunk/Doc/includes/sqlite3/countcursors.py (props changed) python/trunk/Doc/includes/sqlite3/createdb.py (props changed) python/trunk/Doc/includes/sqlite3/execsql_fetchonerow.py (props changed) python/trunk/Doc/includes/sqlite3/execsql_printall_1.py (props changed) python/trunk/Doc/includes/sqlite3/execute_1.py (props changed) python/trunk/Doc/includes/sqlite3/execute_2.py (props changed) python/trunk/Doc/includes/sqlite3/execute_3.py (props changed) python/trunk/Doc/includes/sqlite3/executemany_1.py (props changed) python/trunk/Doc/includes/sqlite3/executemany_2.py (props changed) python/trunk/Doc/includes/sqlite3/executescript.py (props changed) python/trunk/Doc/includes/sqlite3/insert_more_people.py (props changed) python/trunk/Doc/includes/sqlite3/md5func.py (props changed) python/trunk/Doc/includes/sqlite3/mysumaggr.py (props changed) python/trunk/Doc/includes/sqlite3/parse_colnames.py (props changed) python/trunk/Doc/includes/sqlite3/pysqlite_datetime.py (props changed) python/trunk/Doc/includes/sqlite3/row_factory.py (props changed) python/trunk/Doc/includes/sqlite3/rowclass.py (props changed) python/trunk/Doc/includes/sqlite3/shared_cache.py (props changed) python/trunk/Doc/includes/sqlite3/shortcut_methods.py (props changed) python/trunk/Doc/includes/sqlite3/simple_tableprinter.py (props changed) python/trunk/Doc/includes/sqlite3/text_factory.py (props changed) python/trunk/Doc/includes/test.py (props changed) python/trunk/Doc/includes/tzinfo-examples.py (props changed) python/trunk/Doc/install/index.rst (props changed) python/trunk/Doc/library/__builtin__.rst (props changed) python/trunk/Doc/library/__future__.rst (props changed) python/trunk/Doc/library/__main__.rst (props changed) python/trunk/Doc/library/_ast.rst (props changed) python/trunk/Doc/library/_winreg.rst (props changed) python/trunk/Doc/library/aepack.rst (props changed) python/trunk/Doc/library/aetools.rst (props changed) python/trunk/Doc/library/aetypes.rst (props changed) python/trunk/Doc/library/aifc.rst (props changed) python/trunk/Doc/library/al.rst (props changed) python/trunk/Doc/library/allos.rst (props changed) python/trunk/Doc/library/anydbm.rst (props changed) python/trunk/Doc/library/archiving.rst (props changed) python/trunk/Doc/library/array.rst (props changed) python/trunk/Doc/library/asynchat.rst (props changed) python/trunk/Doc/library/asyncore.rst (props changed) python/trunk/Doc/library/atexit.rst (props changed) python/trunk/Doc/library/audioop.rst (props changed) python/trunk/Doc/library/autogil.rst (props changed) python/trunk/Doc/library/base64.rst (props changed) python/trunk/Doc/library/basehttpserver.rst (props changed) python/trunk/Doc/library/bastion.rst (props changed) python/trunk/Doc/library/bdb.rst (props changed) python/trunk/Doc/library/binascii.rst (props changed) python/trunk/Doc/library/binhex.rst (props changed) python/trunk/Doc/library/bisect.rst (props changed) python/trunk/Doc/library/bsddb.rst (props changed) python/trunk/Doc/library/bz2.rst (props changed) python/trunk/Doc/library/calendar.rst (props changed) python/trunk/Doc/library/carbon.rst (props changed) python/trunk/Doc/library/cd.rst (props changed) python/trunk/Doc/library/cgi.rst (props changed) python/trunk/Doc/library/cgihttpserver.rst (props changed) python/trunk/Doc/library/cgitb.rst (props changed) python/trunk/Doc/library/chunk.rst (props changed) python/trunk/Doc/library/cmath.rst (props changed) python/trunk/Doc/library/cmd.rst (props changed) python/trunk/Doc/library/code.rst (props changed) python/trunk/Doc/library/codecs.rst (props changed) python/trunk/Doc/library/codeop.rst (props changed) python/trunk/Doc/library/collections.rst (props changed) python/trunk/Doc/library/colorpicker.rst (props changed) python/trunk/Doc/library/colorsys.rst (props changed) python/trunk/Doc/library/commands.rst (props changed) python/trunk/Doc/library/compileall.rst (props changed) python/trunk/Doc/library/compiler.rst (props changed) python/trunk/Doc/library/configparser.rst (props changed) python/trunk/Doc/library/constants.rst (props changed) python/trunk/Doc/library/contextlib.rst (props changed) python/trunk/Doc/library/cookie.rst (props changed) python/trunk/Doc/library/cookielib.rst (props changed) python/trunk/Doc/library/copy.rst (props changed) python/trunk/Doc/library/copy_reg.rst (props changed) python/trunk/Doc/library/crypt.rst (props changed) python/trunk/Doc/library/crypto.rst (props changed) python/trunk/Doc/library/csv.rst (props changed) python/trunk/Doc/library/ctypes.rst (props changed) python/trunk/Doc/library/curses.ascii.rst (props changed) python/trunk/Doc/library/curses.panel.rst (props changed) python/trunk/Doc/library/curses.rst (props changed) python/trunk/Doc/library/custominterp.rst (props changed) python/trunk/Doc/library/datatypes.rst (props changed) python/trunk/Doc/library/datetime.rst (props changed) python/trunk/Doc/library/dbhash.rst (props changed) python/trunk/Doc/library/dbm.rst (props changed) python/trunk/Doc/library/debug.rst (props changed) python/trunk/Doc/library/decimal.rst (props changed) python/trunk/Doc/library/development.rst (props changed) python/trunk/Doc/library/difflib.rst (props changed) python/trunk/Doc/library/dircache.rst (props changed) python/trunk/Doc/library/dis.rst (props changed) python/trunk/Doc/library/distutils.rst (props changed) python/trunk/Doc/library/dl.rst (props changed) python/trunk/Doc/library/doctest.rst (props changed) python/trunk/Doc/library/docxmlrpcserver.rst (props changed) python/trunk/Doc/library/dumbdbm.rst (props changed) python/trunk/Doc/library/dummy_thread.rst (props changed) python/trunk/Doc/library/dummy_threading.rst (props changed) python/trunk/Doc/library/easydialogs.rst (props changed) python/trunk/Doc/library/email-examples.rst (props changed) python/trunk/Doc/library/email.charset.rst (props changed) python/trunk/Doc/library/email.encoders.rst (props changed) python/trunk/Doc/library/email.errors.rst (props changed) python/trunk/Doc/library/email.generator.rst (props changed) python/trunk/Doc/library/email.header.rst (props changed) python/trunk/Doc/library/email.iterators.rst (props changed) python/trunk/Doc/library/email.message.rst (props changed) python/trunk/Doc/library/email.mime.rst (props changed) python/trunk/Doc/library/email.parser.rst (props changed) python/trunk/Doc/library/email.rst (props changed) python/trunk/Doc/library/email.util.rst (props changed) python/trunk/Doc/library/errno.rst (props changed) python/trunk/Doc/library/exceptions.rst (props changed) python/trunk/Doc/library/fcntl.rst (props changed) python/trunk/Doc/library/filecmp.rst (props changed) python/trunk/Doc/library/fileformats.rst (props changed) python/trunk/Doc/library/fileinput.rst (props changed) python/trunk/Doc/library/filesys.rst (props changed) python/trunk/Doc/library/fl.rst (props changed) python/trunk/Doc/library/fm.rst (props changed) python/trunk/Doc/library/fnmatch.rst (props changed) python/trunk/Doc/library/formatter.rst (props changed) python/trunk/Doc/library/fpectl.rst (props changed) python/trunk/Doc/library/fpformat.rst (props changed) python/trunk/Doc/library/framework.rst (props changed) python/trunk/Doc/library/frameworks.rst (props changed) python/trunk/Doc/library/ftplib.rst (props changed) python/trunk/Doc/library/functions.rst (props changed) python/trunk/Doc/library/functools.rst (props changed) python/trunk/Doc/library/gc.rst (props changed) python/trunk/Doc/library/gdbm.rst (props changed) python/trunk/Doc/library/gensuitemodule.rst (props changed) python/trunk/Doc/library/getopt.rst (props changed) python/trunk/Doc/library/getpass.rst (props changed) python/trunk/Doc/library/gettext.rst (props changed) python/trunk/Doc/library/gl.rst (props changed) python/trunk/Doc/library/glob.rst (props changed) python/trunk/Doc/library/grp.rst (props changed) python/trunk/Doc/library/gzip.rst (props changed) python/trunk/Doc/library/hashlib.rst (props changed) python/trunk/Doc/library/heapq.rst (props changed) python/trunk/Doc/library/hmac.rst (props changed) python/trunk/Doc/library/hotshot.rst (props changed) python/trunk/Doc/library/htmllib.rst (props changed) python/trunk/Doc/library/htmlparser.rst (props changed) python/trunk/Doc/library/httplib.rst (props changed) python/trunk/Doc/library/i18n.rst (props changed) python/trunk/Doc/library/ic.rst (props changed) python/trunk/Doc/library/idle.rst (props changed) python/trunk/Doc/library/imageop.rst (props changed) python/trunk/Doc/library/imaplib.rst (props changed) python/trunk/Doc/library/imgfile.rst (props changed) python/trunk/Doc/library/imghdr.rst (props changed) python/trunk/Doc/library/imp.rst (props changed) python/trunk/Doc/library/imputil.rst (props changed) python/trunk/Doc/library/index.rst (props changed) python/trunk/Doc/library/inspect.rst (props changed) python/trunk/Doc/library/internet.rst (props changed) python/trunk/Doc/library/intro.rst (props changed) python/trunk/Doc/library/ipc.rst (props changed) python/trunk/Doc/library/itertools.rst (props changed) python/trunk/Doc/library/jpeg.rst (props changed) python/trunk/Doc/library/keyword.rst (props changed) python/trunk/Doc/library/language.rst (props changed) python/trunk/Doc/library/linecache.rst (props changed) python/trunk/Doc/library/locale.rst (props changed) python/trunk/Doc/library/logging.rst (props changed) python/trunk/Doc/library/mac.rst (props changed) python/trunk/Doc/library/macos.rst (props changed) python/trunk/Doc/library/macosa.rst (props changed) python/trunk/Doc/library/macostools.rst (props changed) python/trunk/Doc/library/macpath.rst (props changed) python/trunk/Doc/library/mailbox.rst (props changed) python/trunk/Doc/library/mailcap.rst (props changed) python/trunk/Doc/library/markup.rst (props changed) python/trunk/Doc/library/marshal.rst (props changed) python/trunk/Doc/library/math.rst (props changed) python/trunk/Doc/library/md5.rst (props changed) python/trunk/Doc/library/mhlib.rst (props changed) python/trunk/Doc/library/mimetools.rst (props changed) python/trunk/Doc/library/mimetypes.rst (props changed) python/trunk/Doc/library/mimewriter.rst (props changed) python/trunk/Doc/library/mimify.rst (props changed) python/trunk/Doc/library/miniaeframe.rst (props changed) python/trunk/Doc/library/misc.rst (props changed) python/trunk/Doc/library/mm.rst (props changed) python/trunk/Doc/library/mmap.rst (props changed) python/trunk/Doc/library/modulefinder.rst (props changed) python/trunk/Doc/library/modules.rst (props changed) python/trunk/Doc/library/msilib.rst (props changed) python/trunk/Doc/library/msvcrt.rst (props changed) python/trunk/Doc/library/multifile.rst (props changed) python/trunk/Doc/library/mutex.rst (props changed) python/trunk/Doc/library/netdata.rst (props changed) python/trunk/Doc/library/netrc.rst (props changed) python/trunk/Doc/library/new.rst (props changed) python/trunk/Doc/library/nis.rst (props changed) python/trunk/Doc/library/nntplib.rst (props changed) python/trunk/Doc/library/numbers.rst (props changed) python/trunk/Doc/library/numeric.rst (props changed) python/trunk/Doc/library/objects.rst (props changed) python/trunk/Doc/library/operator.rst (props changed) python/trunk/Doc/library/optparse.rst (props changed) python/trunk/Doc/library/os.path.rst (props changed) python/trunk/Doc/library/os.rst (props changed) python/trunk/Doc/library/ossaudiodev.rst (props changed) python/trunk/Doc/library/othergui.rst (props changed) python/trunk/Doc/library/parser.rst (props changed) python/trunk/Doc/library/pdb.rst (props changed) python/trunk/Doc/library/persistence.rst (props changed) python/trunk/Doc/library/pickle.rst (props changed) python/trunk/Doc/library/pickletools.rst (props changed) python/trunk/Doc/library/pipes.rst (props changed) python/trunk/Doc/library/pkgutil.rst (props changed) python/trunk/Doc/library/platform.rst (props changed) python/trunk/Doc/library/popen2.rst (props changed) python/trunk/Doc/library/poplib.rst (props changed) python/trunk/Doc/library/posix.rst (props changed) python/trunk/Doc/library/posixfile.rst (props changed) python/trunk/Doc/library/pprint.rst (props changed) python/trunk/Doc/library/profile.rst (props changed) python/trunk/Doc/library/pty.rst (props changed) python/trunk/Doc/library/pwd.rst (props changed) python/trunk/Doc/library/py_compile.rst (props changed) python/trunk/Doc/library/pyclbr.rst (props changed) python/trunk/Doc/library/pydoc.rst (props changed) python/trunk/Doc/library/pyexpat.rst (props changed) python/trunk/Doc/library/python.rst (props changed) python/trunk/Doc/library/queue.rst (props changed) python/trunk/Doc/library/quopri.rst (props changed) python/trunk/Doc/library/random.rst (props changed) python/trunk/Doc/library/re.rst (props changed) python/trunk/Doc/library/readline.rst (props changed) python/trunk/Doc/library/repr.rst (props changed) python/trunk/Doc/library/resource.rst (props changed) python/trunk/Doc/library/restricted.rst (props changed) python/trunk/Doc/library/rexec.rst (props changed) python/trunk/Doc/library/rfc822.rst (props changed) python/trunk/Doc/library/rlcompleter.rst (props changed) python/trunk/Doc/library/robotparser.rst (props changed) python/trunk/Doc/library/runpy.rst (props changed) python/trunk/Doc/library/sched.rst (props changed) python/trunk/Doc/library/scrolledtext.rst (props changed) python/trunk/Doc/library/select.rst (props changed) python/trunk/Doc/library/sets.rst (props changed) python/trunk/Doc/library/sgi.rst (props changed) python/trunk/Doc/library/sgmllib.rst (props changed) python/trunk/Doc/library/sha.rst (props changed) python/trunk/Doc/library/shelve.rst (props changed) python/trunk/Doc/library/shlex.rst (props changed) python/trunk/Doc/library/shutil.rst (props changed) python/trunk/Doc/library/signal.rst (props changed) python/trunk/Doc/library/simplehttpserver.rst (props changed) python/trunk/Doc/library/simplexmlrpcserver.rst (props changed) python/trunk/Doc/library/site.rst (props changed) python/trunk/Doc/library/smtpd.rst (props changed) python/trunk/Doc/library/smtplib.rst (props changed) python/trunk/Doc/library/sndhdr.rst (props changed) python/trunk/Doc/library/socket.rst (props changed) python/trunk/Doc/library/socketserver.rst (props changed) python/trunk/Doc/library/someos.rst (props changed) python/trunk/Doc/library/spwd.rst (props changed) python/trunk/Doc/library/sqlite3.rst (props changed) python/trunk/Doc/library/stat.rst (props changed) python/trunk/Doc/library/statvfs.rst (props changed) python/trunk/Doc/library/stdtypes.rst (props changed) python/trunk/Doc/library/string.rst (props changed) python/trunk/Doc/library/stringio.rst (props changed) python/trunk/Doc/library/stringprep.rst (props changed) python/trunk/Doc/library/strings.rst (props changed) python/trunk/Doc/library/struct.rst (props changed) python/trunk/Doc/library/subprocess.rst (props changed) python/trunk/Doc/library/sun.rst (props changed) python/trunk/Doc/library/sunau.rst (props changed) python/trunk/Doc/library/sunaudio.rst (props changed) python/trunk/Doc/library/symbol.rst (props changed) python/trunk/Doc/library/sys.rst (props changed) python/trunk/Doc/library/syslog.rst (props changed) python/trunk/Doc/library/tabnanny.rst (props changed) python/trunk/Doc/library/tarfile.rst (props changed) python/trunk/Doc/library/telnetlib.rst (props changed) python/trunk/Doc/library/tempfile.rst (props changed) python/trunk/Doc/library/termios.rst (props changed) python/trunk/Doc/library/test.rst (props changed) python/trunk/Doc/library/textwrap.rst (props changed) python/trunk/Doc/library/thread.rst (props changed) python/trunk/Doc/library/threading.rst (props changed) python/trunk/Doc/library/time.rst (props changed) python/trunk/Doc/library/timeit.rst (props changed) python/trunk/Doc/library/tix.rst (props changed) python/trunk/Doc/library/tk.rst (props changed) python/trunk/Doc/library/tkinter.rst (props changed) python/trunk/Doc/library/token.rst (props changed) python/trunk/Doc/library/tokenize.rst (props changed) python/trunk/Doc/library/trace.rst (props changed) python/trunk/Doc/library/traceback.rst (props changed) python/trunk/Doc/library/tty.rst (props changed) python/trunk/Doc/library/turtle.rst (props changed) python/trunk/Doc/library/types.rst (props changed) python/trunk/Doc/library/undoc.rst (props changed) python/trunk/Doc/library/unicodedata.rst (props changed) python/trunk/Doc/library/unittest.rst (props changed) python/trunk/Doc/library/unix.rst (props changed) python/trunk/Doc/library/urllib.rst (props changed) python/trunk/Doc/library/urllib2.rst (props changed) python/trunk/Doc/library/urlparse.rst (props changed) python/trunk/Doc/library/user.rst (props changed) python/trunk/Doc/library/userdict.rst (props changed) python/trunk/Doc/library/uu.rst (props changed) python/trunk/Doc/library/uuid.rst (props changed) python/trunk/Doc/library/warnings.rst (props changed) python/trunk/Doc/library/wave.rst (props changed) python/trunk/Doc/library/weakref.rst (props changed) python/trunk/Doc/library/webbrowser.rst (props changed) python/trunk/Doc/library/whichdb.rst (props changed) python/trunk/Doc/library/windows.rst (props changed) python/trunk/Doc/library/winsound.rst (props changed) python/trunk/Doc/library/wsgiref.rst (props changed) python/trunk/Doc/library/xdrlib.rst (props changed) python/trunk/Doc/library/xml.dom.minidom.rst (props changed) python/trunk/Doc/library/xml.dom.pulldom.rst (props changed) python/trunk/Doc/library/xml.dom.rst (props changed) python/trunk/Doc/library/xml.etree.elementtree.rst (props changed) python/trunk/Doc/library/xml.etree.rst (props changed) python/trunk/Doc/library/xml.sax.handler.rst (props changed) python/trunk/Doc/library/xml.sax.reader.rst (props changed) python/trunk/Doc/library/xml.sax.rst (props changed) python/trunk/Doc/library/xml.sax.utils.rst (props changed) python/trunk/Doc/library/xmllib.rst (props changed) python/trunk/Doc/library/xmlrpclib.rst (props changed) python/trunk/Doc/library/zipfile.rst (props changed) python/trunk/Doc/library/zipimport.rst (props changed) python/trunk/Doc/library/zlib.rst (props changed) python/trunk/Doc/license.rst (props changed) python/trunk/Doc/reference/compound_stmts.rst (props changed) python/trunk/Doc/reference/datamodel.rst (props changed) python/trunk/Doc/reference/executionmodel.rst (props changed) python/trunk/Doc/reference/expressions.rst (props changed) python/trunk/Doc/reference/index.rst (props changed) python/trunk/Doc/reference/introduction.rst (props changed) python/trunk/Doc/reference/lexical_analysis.rst (props changed) python/trunk/Doc/reference/simple_stmts.rst (props changed) python/trunk/Doc/reference/toplevel_components.rst (props changed) python/trunk/Doc/tools/roman.py (props changed) python/trunk/Doc/tools/sphinx-build.py (props changed) python/trunk/Doc/tools/sphinx-web.py (props changed) python/trunk/Doc/tutorial/appetite.rst (props changed) python/trunk/Doc/tutorial/classes.rst (props changed) python/trunk/Doc/tutorial/controlflow.rst (props changed) python/trunk/Doc/tutorial/datastructures.rst (props changed) python/trunk/Doc/tutorial/errors.rst (props changed) python/trunk/Doc/tutorial/floatingpoint.rst (props changed) python/trunk/Doc/tutorial/index.rst (props changed) python/trunk/Doc/tutorial/inputoutput.rst (props changed) python/trunk/Doc/tutorial/interactive.rst (props changed) python/trunk/Doc/tutorial/interpreter.rst (props changed) python/trunk/Doc/tutorial/introduction.rst (props changed) python/trunk/Doc/tutorial/modules.rst (props changed) python/trunk/Doc/tutorial/stdlib.rst (props changed) python/trunk/Doc/tutorial/stdlib2.rst (props changed) python/trunk/Doc/tutorial/whatnow.rst (props changed) python/trunk/Doc/using/cmdline.rst (props changed) python/trunk/Doc/using/index.rst (props changed) python/trunk/Doc/using/mac.rst (props changed) python/trunk/Doc/using/unix.rst (props changed) python/trunk/Doc/using/windows.rst (props changed) python/trunk/Doc/whatsnew/2.0.rst (props changed) python/trunk/Doc/whatsnew/2.1.rst (props changed) python/trunk/Doc/whatsnew/2.2.rst (props changed) python/trunk/Doc/whatsnew/2.3.rst (props changed) python/trunk/Doc/whatsnew/2.4.rst (props changed) python/trunk/Doc/whatsnew/2.5.rst (props changed) python/trunk/Doc/whatsnew/2.6.rst (props changed) Log: Set native svn:eol-style property for text files. From python-checkins at python.org Sat Jan 5 21:46:29 2008 From: python-checkins at python.org (georg.brandl) Date: Sat, 5 Jan 2008 21:46:29 +0100 (CET) Subject: [Python-checkins] r59752 - python/trunk/Doc/library/msilib.rst Message-ID: <20080105204629.772471E4024@bag.python.org> Author: georg.brandl Date: Sat Jan 5 21:46:29 2008 New Revision: 59752 Modified: python/trunk/Doc/library/msilib.rst Log: #1719: capitalization error in "UuidCreate". Modified: python/trunk/Doc/library/msilib.rst ============================================================================== --- python/trunk/Doc/library/msilib.rst (original) +++ python/trunk/Doc/library/msilib.rst Sat Jan 5 21:46:29 2008 @@ -42,7 +42,7 @@ exposed. -.. function:: UUIDCreate() +.. function:: UuidCreate() Return the string representation of a new unique identifier. This wraps the Windows API functions :cfunc:`UuidCreate` and :cfunc:`UuidToString`. From python-checkins at python.org Sat Jan 5 22:02:25 2008 From: python-checkins at python.org (georg.brandl) Date: Sat, 5 Jan 2008 22:02:25 +0100 (CET) Subject: [Python-checkins] r59753 - python/trunk/Doc/c-api/utilities.rst Message-ID: <20080105210225.A88861E400B@bag.python.org> Author: georg.brandl Date: Sat Jan 5 22:02:25 2008 New Revision: 59753 Modified: python/trunk/Doc/c-api/utilities.rst Log: Repair markup. Modified: python/trunk/Doc/c-api/utilities.rst ============================================================================== --- python/trunk/Doc/c-api/utilities.rst (original) +++ python/trunk/Doc/c-api/utilities.rst Sat Jan 5 22:02:25 2008 @@ -181,6 +181,7 @@ .. index:: single: package variable; __all__ single: __all__ (package variable) + single: modules (in module sys) This is a simplified interface to :cfunc:`PyImport_ImportModuleEx` below, leaving the *globals* and *locals* arguments set to *NULL* and *level* set @@ -202,19 +203,14 @@ .. versionchanged:: 2.6 always use absolute imports - .. index:: single: modules (in module sys) - .. cfunction:: PyObject* PyImport_ImportModuleNoBlock(const char *name) - .. index:: - single: `cfunc:PyImport_ImportModule` - - This version of `cfunc:PyImport_ImportModule` does not block. It's intended + This version of :cfunc:`PyImport_ImportModule` does not block. It's intended to be used in C function which import other modules to execute a function. The import may block if another thread holds the import lock. The function - `cfunc:PyImport_ImportModuleNoBlock` doesn't block. It first tries to fetch - the module from sys.modules and falls back to `cfunc:PyImport_ImportModule` + :cfunc:`PyImport_ImportModuleNoBlock` doesn't block. It first tries to fetch + the module from sys.modules and falls back to :cfunc:`PyImport_ImportModule` unless the the lock is hold. In the latter case the function raises an ImportError. @@ -239,7 +235,7 @@ failing imports remove incomplete module objects. .. versionchanged:: 2.6 - The function is an alias for `cfunc:PyImport_ImportModuleLevel` with + The function is an alias for :cfunc:`PyImport_ImportModuleLevel` with -1 as level, meaning relative import. @@ -254,7 +250,7 @@ the return value when a submodule of a package was requested is normally the top-level package, unless a non-empty *fromlist* was given. - ..versionadded:: 2.5 + .. versionadded:: 2.5 .. cfunction:: PyObject* PyImport_Import(PyObject *name) From python-checkins at python.org Sat Jan 5 22:10:50 2008 From: python-checkins at python.org (georg.brandl) Date: Sat, 5 Jan 2008 22:10:50 +0100 (CET) Subject: [Python-checkins] r59754 - python/trunk/Doc/c-api/utilities.rst Message-ID: <20080105211050.83E921E400B@bag.python.org> Author: georg.brandl Date: Sat Jan 5 22:10:50 2008 New Revision: 59754 Modified: python/trunk/Doc/c-api/utilities.rst Log: Use markup. Modified: python/trunk/Doc/c-api/utilities.rst ============================================================================== --- python/trunk/Doc/c-api/utilities.rst (original) +++ python/trunk/Doc/c-api/utilities.rst Sat Jan 5 22:10:50 2008 @@ -302,9 +302,9 @@ :func:`compile`, load the module. Return a new reference to the module object, or *NULL* with an exception set if an error occurred. Before Python 2.4, the module could still be created in error cases. Starting with Python 2.4, *name* - is removed from ``sys.modules`` in error cases, and even if *name* was already - in ``sys.modules`` on entry to :cfunc:`PyImport_ExecCodeModule`. Leaving - incompletely initialized modules in ``sys.modules`` is dangerous, as imports of + is removed from :attr:`sys.modules` in error cases, and even if *name* was already + in :attr:`sys.modules` on entry to :cfunc:`PyImport_ExecCodeModule`. Leaving + incompletely initialized modules in :attr:`sys.modules` is dangerous, as imports of such modules have no way to know that the module object is an unknown (and probably damaged with respect to the module author's intents) state. @@ -315,7 +315,7 @@ structures not already created will still not be created. .. versionchanged:: 2.4 - *name* is removed from ``sys.modules`` in error cases. + *name* is removed from :attr:`sys.modules` in error cases. .. cfunction:: long PyImport_GetMagicNumber() From buildbot at python.org Sat Jan 5 22:15:23 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 05 Jan 2008 21:15:23 +0000 Subject: [Python-checkins] buildbot failure in sparc solaris10 gcc 3.0 Message-ID: <20080105211523.33F791E400B@bag.python.org> The Buildbot has detected a new failure of sparc solaris10 gcc 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/sparc%20solaris10%20gcc%203.0/builds/463 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-sun Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: georg.brandl,jeffrey.yasskin BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_platform ====================================================================== ERROR: test_architecture (test.test_platform.PlatformTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/opt/users/buildbot/slave/3.0.loewis-sun/build/Lib/test/test_platform.py", line 7, in test_architecture res = platform.architecture() File "/opt/users/buildbot/slave/3.0.loewis-sun/build/Lib/platform.py", line 955, in architecture output = _syscmd_file(executable, '') File "/opt/users/buildbot/slave/3.0.loewis-sun/build/Lib/platform.py", line 897, in _syscmd_file target = _follow_symlinks(target) File "/opt/users/buildbot/slave/3.0.loewis-sun/build/Lib/platform.py", line 863, in _follow_symlinks filepath = _abspath(filepath) NameError: global name '_abspath' is not defined ====================================================================== ERROR: test_platform (test.test_platform.PlatformTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/opt/users/buildbot/slave/3.0.loewis-sun/build/Lib/test/test_platform.py", line 18, in test_platform res = platform.platform(aliased, terse) File "/opt/users/buildbot/slave/3.0.loewis-sun/build/Lib/platform.py", line 1475, in platform bits,linkage = architecture(sys.executable) File "/opt/users/buildbot/slave/3.0.loewis-sun/build/Lib/platform.py", line 955, in architecture output = _syscmd_file(executable, '') File "/opt/users/buildbot/slave/3.0.loewis-sun/build/Lib/platform.py", line 897, in _syscmd_file target = _follow_symlinks(target) File "/opt/users/buildbot/slave/3.0.loewis-sun/build/Lib/platform.py", line 863, in _follow_symlinks filepath = _abspath(filepath) NameError: global name '_abspath' is not defined sincerely, -The Buildbot From python-checkins at python.org Sat Jan 5 22:35:53 2008 From: python-checkins at python.org (christian.heimes) Date: Sat, 5 Jan 2008 22:35:53 +0100 (CET) Subject: [Python-checkins] r59757 - python/trunk/PCbuild/build_tkinter.py Message-ID: <20080105213553.102071E401D@bag.python.org> Author: christian.heimes Date: Sat Jan 5 22:35:52 2008 New Revision: 59757 Modified: python/trunk/PCbuild/build_tkinter.py Log: Final adjustments for #1601 Modified: python/trunk/PCbuild/build_tkinter.py ============================================================================== --- python/trunk/PCbuild/build_tkinter.py (original) +++ python/trunk/PCbuild/build_tkinter.py Sat Jan 5 22:35:52 2008 @@ -24,7 +24,9 @@ ROOT = os.path.abspath(os.path.join(here, par, par)) # Windows 2000 compatibility: WINVER 0x0500 # http://msdn2.microsoft.com/en-us/library/aa383745.aspx -NMAKE = "nmake /nologo /f %s COMPILERFLAGS=-DWINVER=0x0500 %s %s" +NMAKE = ('nmake /nologo /f %s ' + 'COMPILERFLAGS=\"-DWINVER=0x0500 -D_WIN32_WINNT=0x0500 -DNTDDI_VERSION=NTDDI_WIN2KSP4\"' + '%s %s') def nmake(makefile, command="", **kw): defines = ' '.join(k+'='+v for k, v in kw.items()) From buildbot at python.org Sat Jan 5 22:44:08 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 05 Jan 2008 21:44:08 +0000 Subject: [Python-checkins] buildbot failure in g4 osx.4 3.0 Message-ID: <20080105214408.9C40F1E4021@bag.python.org> The Buildbot has detected a new failure of g4 osx.4 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/g4%20osx.4%203.0/builds/413 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: psf-g4 Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: georg.brandl,jeffrey.yasskin BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_platform ====================================================================== ERROR: test_architecture (test.test_platform.PlatformTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/test/test_platform.py", line 7, in test_architecture res = platform.architecture() File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/platform.py", line 955, in architecture output = _syscmd_file(executable, '') File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/platform.py", line 897, in _syscmd_file target = _follow_symlinks(target) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/platform.py", line 863, in _follow_symlinks filepath = _abspath(filepath) NameError: global name '_abspath' is not defined ====================================================================== ERROR: test_platform (test.test_platform.PlatformTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/test/test_platform.py", line 18, in test_platform res = platform.platform(aliased, terse) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/platform.py", line 1475, in platform bits,linkage = architecture(sys.executable) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/platform.py", line 955, in architecture output = _syscmd_file(executable, '') File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/platform.py", line 897, in _syscmd_file target = _follow_symlinks(target) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/platform.py", line 863, in _follow_symlinks filepath = _abspath(filepath) NameError: global name '_abspath' is not defined make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Sat Jan 5 22:52:52 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 05 Jan 2008 21:52:52 +0000 Subject: [Python-checkins] buildbot failure in ia64 Ubuntu 3.0 Message-ID: <20080105215253.24D561E400B@bag.python.org> The Buildbot has detected a new failure of ia64 Ubuntu 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/ia64%20Ubuntu%203.0/builds/436 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ia64 Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: georg.brandl,jeffrey.yasskin BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_platform ====================================================================== ERROR: test_architecture (test.test_platform.PlatformTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ia64/build/Lib/test/test_platform.py", line 7, in test_architecture res = platform.architecture() File "/home/pybot/buildarea/3.0.klose-debian-ia64/build/Lib/platform.py", line 955, in architecture output = _syscmd_file(executable, '') File "/home/pybot/buildarea/3.0.klose-debian-ia64/build/Lib/platform.py", line 897, in _syscmd_file target = _follow_symlinks(target) File "/home/pybot/buildarea/3.0.klose-debian-ia64/build/Lib/platform.py", line 863, in _follow_symlinks filepath = _abspath(filepath) NameError: global name '_abspath' is not defined make: *** [buildbottest] Error 1 sincerely, -The Buildbot From nnorwitz at gmail.com Sat Jan 5 23:33:50 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Sat, 5 Jan 2008 17:33:50 -0500 Subject: [Python-checkins] Python Regression Test Failures refleak (1) Message-ID: <20080105223350.GA20039@python.psfb.org> test_softspace leaked [0, 98, 0] references, sum=98 test_sys leaked [0, 140, -140] references, sum=0 test_urllib2_localnet leaked [4, 3, 3] references, sum=10 From buildbot at python.org Sat Jan 5 23:14:35 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 05 Jan 2008 22:14:35 +0000 Subject: [Python-checkins] buildbot failure in x86 XP-3 3.0 Message-ID: <20080105221436.540F61E400B@bag.python.org> The Buildbot has detected a new failure of x86 XP-3 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20XP-3%203.0/builds/455 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: heller-windows Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: georg.brandl BUILD FAILED: failed test Excerpt from the test logfile: 6 tests failed: test_anydbm test_bsddb test_bsddb3 test_mailbox test_shelve test_whichdb ====================================================================== ERROR: test_anydbm_access (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_anydbm.py", line 90, in test_anydbm_access self.init_db() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_anydbm.py", line 103, in init_db f = anydbm.open(_fname, 'n') File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_anydbm_creation (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_anydbm.py", line 63, in test_anydbm_creation f = anydbm.open(_fname, 'c') File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_anydbm_keys (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_anydbm.py", line 84, in test_anydbm_keys self.init_db() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_anydbm.py", line 103, in init_db f = anydbm.open(_fname, 'n') File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_anydbm_modification (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_anydbm.py", line 71, in test_anydbm_modification self.init_db() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_anydbm.py", line 103, in init_db f = anydbm.open(_fname, 'n') File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_anydbm_read (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_anydbm.py", line 78, in test_anydbm_read self.init_db() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_anydbm.py", line 103, in init_db f = anydbm.open(_fname, 'n') File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') Traceback (most recent call last): File "../lib/test/regrtest.py", line 596, in runtest_inner indirect_test() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb3.py", line 64, in test_main run_unittest(suite()) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb3.py", line 28, in suite import bsddb.test.test_1413192 File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\test\test_1413192.py", line 38, in context = Context() File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\test\test_1413192.py", line 26, in __init__ db.DB_CREATE | db.DB_INIT_TXN | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_flush (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 703, in tearDown self._delete_recursively(self._path) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 47, in _delete_recursively os.remove(target) WindowsError: [Error 32] The process cannot access the file because it is being used by another process: '@test' ====================================================================== ERROR: test_popitem (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 336, in test_popitem self.assertEqual(int(msg.get_payload()), keys.index(key)) ValueError: invalid literal for int() with base 10: 'From: foo 0 F' ====================================================================== ERROR: test_flush (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 703, in tearDown self._delete_recursively(self._path) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 47, in _delete_recursively os.remove(target) WindowsError: [Error 32] The process cannot access the file because it is being used by another process: '@test' ====================================================================== ERROR: test_popitem (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 336, in test_popitem self.assertEqual(int(msg.get_payload()), keys.index(key)) ValueError: invalid literal for int() with base 10: 'From: foo 0 \x01' ====================================================================== ERROR: test_flush (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 926, in tearDown self._delete_recursively(self._path) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 47, in _delete_recursively os.remove(target) WindowsError: [Error 32] The process cannot access the file because it is being used by another process: '@test' ====================================================================== ERROR: test_popitem (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 336, in test_popitem self.assertEqual(int(msg.get_payload()), keys.index(key)) ValueError: invalid literal for int() with base 10: 'From: foo *** EOOH *** From: foo 0 1,, From: foo *** EOOH *** From: foo 1 1,, From: foo *** EOOH *** From: foo 2 1,, From: foo *** EOOH *** From: foo 3 ' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestMaildir) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_add (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 77, in test_add self.assertEqual(self._box.get_string(keys[0]), self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\nF' != 'From: foo\n\n0' ====================================================================== FAIL: test_add_and_close (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 743, in test_add_and_close self.assertEqual(contents, open(self._path, 'r').read()) AssertionError: 'From MAILER-DAEMON Sun Jan 06 07:45:02 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Sun Jan 06 07:45:02 2008\n\nFrom: foo\n\n0\n\nFrom MAILER-DAEMON Sun Jan 06 07:45:02 2008\n\nFrom: foo\n\n1\n\nFrom MAILER-DAEMON Sun Jan 06 07:45:02 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Sun Jan 06 07:45:02 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'From MAILER-DAEMON Sun Jan 06 07:45:02 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Sun Jan 06 07:45:02 2008\n\nFrom: foo\n\n0\n\nFrom MAILER-DAEMON Sun Jan 06 07:45:02 2008\n\nFrom: foo\n\n1\n\nFrom MAILER-DAEMON Sun Jan 06 07:45:02 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Sun Jan 06 07:45:02 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Sun Jan 06 07:45:02 2008\n\nFrom: foo\n\n0\n\nFrom MAILER-DAEMON Sun Jan 06 07:45:02 2008\n\nFrom: foo\n\n1\n\nFrom MAILER-DAEMON Sun Jan 06 07:45:02 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Sun Jan 06 07:45:02 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Sun Jan 06 07:45:02 2008\n\nFrom: foo\n\n1\n\nFrom MAILER-DAEMON Sun Jan 06 07:45:02 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Sun Jan 06 07:45:02 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Sun Jan 06 07:45:02 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Sun Jan 06 07:45:02 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Sun Jan 06 07:45:02 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' ====================================================================== FAIL: test_add_from_string (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 710, in test_add_from_string self.assertEqual(self._box[key].get_from(), 'foo at bar blah') AssertionError: 'foo at bar blah\n' != 'foo at bar blah' ====================================================================== FAIL: test_close (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 389, in test_close self._test_flush_or_close(self._box.close) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 6 != 3 ====================================================================== FAIL: test_delitem (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 87, in test_delitem self._test_remove_or_delitem(self._box.__delitem__) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n1' != 'From: foo\n\n1' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_flush (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 377, in test_flush self._test_flush_or_close(self._box.flush) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 6 != 3 ====================================================================== FAIL: test_get (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 129, in test_get self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_file (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 174, in test_get_file self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\nF' != 'From: foo\n\n0' ====================================================================== FAIL: test_get_message (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 156, in test_get_message self.assertEqual(msg0['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_string (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 164, in test_get_string self.assertEqual(self._box.get_string(key0), self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\nF' != 'From: foo\n\n0' ====================================================================== FAIL: test_getitem (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 144, in test_getitem self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_items (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 207, in test_items self._check_iteration(self._box.items, do_keys=True, do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iter (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 194, in test_iter do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iteritems (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 203, in test_iteritems do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_itervalues (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 189, in test_itervalues do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_open_close_open (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 727, in test_open_close_open self.assertEqual(len(self._box), 3) AssertionError: 6 != 3 ====================================================================== FAIL: test_pop (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 313, in test_pop self.assertEqual(self._box.pop(key0).get_payload(), '0') AssertionError: 'From: foo\n\n0\n\nF' != '0' ====================================================================== FAIL: test_remove (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 83, in test_remove self._test_remove_or_delitem(self._box.remove) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n1' != 'From: foo\n\n1' ====================================================================== FAIL: test_set_item (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 272, in test_set_item self._template % 'original 0') AssertionError: '\nFrom: foo\n\noriginal 0' != 'From: foo\n\noriginal 0' ====================================================================== FAIL: test_update (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 350, in test_update self._template % 'changed 0') AssertionError: '\nFrom: foo\n\nchanged 0\n\nF' != 'From: foo\n\nchanged 0' ====================================================================== FAIL: test_values (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 198, in test_values self._check_iteration(self._box.values, do_keys=False, do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_add (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 77, in test_add self.assertEqual(self._box.get_string(keys[0]), self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\n\x01' != 'From: foo\n\n0' ====================================================================== FAIL: test_add_and_close (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 743, in test_add_and_close self.assertEqual(contents, open(self._path, 'r').read()) AssertionError: '\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 06 07:45:05 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 06 07:45:05 2008\n\nFrom: foo\n\n0\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 06 07:45:05 2008\n\nFrom: foo\n\n1\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 06 07:45:05 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 06 07:45:05 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n' != '\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 06 07:45:05 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 06 07:45:05 2008\n\nFrom: foo\n\n0\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 06 07:45:05 2008\n\nFrom: foo\n\n1\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 06 07:45:05 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 06 07:45:05 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 06 07:45:05 2008\n\nFrom: foo\n\n0\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 06 07:45:05 2008\n\nFrom: foo\n\n1\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 06 07:45:05 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 06 07:45:05 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 06 07:45:05 2008\n\nFrom: foo\n\n1\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 06 07:45:05 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 06 07:45:05 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 06 07:45:05 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 06 07:45:05 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 06 07:45:05 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n' ====================================================================== FAIL: test_add_from_string (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 710, in test_add_from_string self.assertEqual(self._box[key].get_from(), 'foo at bar blah') AssertionError: 'foo at bar blah\n' != 'foo at bar blah' ====================================================================== FAIL: test_close (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 389, in test_close self._test_flush_or_close(self._box.close) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_delitem (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 87, in test_delitem self._test_remove_or_delitem(self._box.__delitem__) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n1\n\n\x01' != 'From: foo\n\n1' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_flush (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 377, in test_flush self._test_flush_or_close(self._box.flush) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_get (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 129, in test_get self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_file (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 174, in test_get_file self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\n\x01' != 'From: foo\n\n0' ====================================================================== FAIL: test_get_message (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 156, in test_get_message self.assertEqual(msg0['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_string (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 164, in test_get_string self.assertEqual(self._box.get_string(key0), self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\n\x01' != 'From: foo\n\n0' ====================================================================== FAIL: test_getitem (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 144, in test_getitem self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_items (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 207, in test_items self._check_iteration(self._box.items, do_keys=True, do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iter (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 194, in test_iter do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iteritems (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 203, in test_iteritems do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_itervalues (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 189, in test_itervalues do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_open_close_open (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 727, in test_open_close_open self.assertEqual(len(self._box), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_pop (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 313, in test_pop self.assertEqual(self._box.pop(key0).get_payload(), '0') AssertionError: 'From: foo\n\n0\n\n\x01' != '0' ====================================================================== FAIL: test_remove (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 83, in test_remove self._test_remove_or_delitem(self._box.remove) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n1\n\n\x01' != 'From: foo\n\n1' ====================================================================== FAIL: test_set_item (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 272, in test_set_item self._template % 'original 0') AssertionError: '\nFrom: foo\n\noriginal 0\n\n\x01' != 'From: foo\n\noriginal 0' ====================================================================== FAIL: test_update (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 350, in test_update self._template % 'changed 0') AssertionError: '\nFrom: foo\n\nchanged 0\n\n\x01' != 'From: foo\n\nchanged 0' ====================================================================== FAIL: test_values (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 198, in test_values self._check_iteration(self._box.values, do_keys=False, do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestMH) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_add (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 77, in test_add self.assertEqual(self._box.get_string(keys[0]), self._template % 0) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n0\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f' != 'From: foo\n\n0' ====================================================================== FAIL: test_close (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 389, in test_close self._test_flush_or_close(self._box.close) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_delitem (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 87, in test_delitem self._test_remove_or_delitem(self._box.__delitem__) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n1\n\n\x1f' != 'From: foo\n\n1' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_flush (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 377, in test_flush self._test_flush_or_close(self._box.flush) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_get (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 129, in test_get self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_file (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 174, in test_get_file self._template % 0) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n0\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f' != 'From: foo\n\n0' ====================================================================== FAIL: test_get_message (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 156, in test_get_message self.assertEqual(msg0['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_string (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 164, in test_get_string self.assertEqual(self._box.get_string(key0), self._template % 0) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n0\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f' != 'From: foo\n\n0' ====================================================================== FAIL: test_getitem (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 144, in test_getitem self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_items (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 207, in test_items self._check_iteration(self._box.items, do_keys=True, do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iter (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 194, in test_iter do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iteritems (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 203, in test_iteritems do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_itervalues (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 189, in test_itervalues do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_pop (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 313, in test_pop self.assertEqual(self._box.pop(key0).get_payload(), '0') AssertionError: 'From: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n0\n\n\x1f\x0c\n\n1,,\n\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n1\n\n\x1f' != '0' ====================================================================== FAIL: test_remove (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 83, in test_remove self._test_remove_or_delitem(self._box.remove) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n1\n\n\x1f' != 'From: foo\n\n1' ====================================================================== FAIL: test_set_item (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 272, in test_set_item self._template % 'original 0') AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\noriginal 0\n\n\x1f' != 'From: foo\n\noriginal 0' ====================================================================== FAIL: test_update (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 350, in test_update self._template % 'changed 0') AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\nchanged 0\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f' != 'From: foo\n\nchanged 0' ====================================================================== FAIL: test_values (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 198, in test_values self._check_iteration(self._box.values, do_keys=False, do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== ERROR: test_bool (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 136, in test_bool self.assert_(not self._empty_mapping()) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_constructor (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 133, in test_constructor self.assertEqual(self._empty_mapping(), self._empty_mapping()) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 270, in test_get d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_items (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 156, in test_items d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keys (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 142, in test_keys d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 162, in test_len d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 293, in test_pop d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 288, in test_popitem d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_read (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 44, in test_read p = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 284, in test_setdefault d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 174, in test_update d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_values (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 150, in test_values d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_write (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 92, in test_write p = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_bool (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 136, in test_bool self.assert_(not self._empty_mapping()) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_constructor (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 133, in test_constructor self.assertEqual(self._empty_mapping(), self._empty_mapping()) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 270, in test_get d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_items (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 156, in test_items d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keys (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 142, in test_keys d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 162, in test_len d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 293, in test_pop d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 288, in test_popitem d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_read (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 44, in test_read p = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 284, in test_setdefault d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 174, in test_update d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_values (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 150, in test_values d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_write (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 92, in test_write p = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_bool (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 136, in test_bool self.assert_(not self._empty_mapping()) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_constructor (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 133, in test_constructor self.assertEqual(self._empty_mapping(), self._empty_mapping()) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 270, in test_get d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_items (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 156, in test_items d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keys (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 142, in test_keys d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 162, in test_len d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 293, in test_pop d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 288, in test_popitem d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_read (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 44, in test_read p = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 284, in test_setdefault d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 174, in test_update d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_values (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 150, in test_values d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_write (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 92, in test_write p = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_ascii_file_shelf (test.test_shelve.TestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 46, in test_ascii_file_shelf s = shelve.open(self.fn, protocol=0) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_binary_file_shelf (test.test_shelve.TestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 54, in test_binary_file_shelf s = shelve.open(self.fn, protocol=1) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_proto2_file_shelf (test.test_shelve.TestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 62, in test_proto2_file_shelf s = shelve.open(self.fn, protocol=2) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_whichdb (test.test_whichdb.WhichDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_whichdb.py", line 32, in test_whichdb f = module.open(_fname, 'c') File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') sincerely, -The Buildbot From python-checkins at python.org Sat Jan 5 23:19:07 2008 From: python-checkins at python.org (guido.van.rossum) Date: Sat, 5 Jan 2008 23:19:07 +0100 (CET) Subject: [Python-checkins] r59758 - in python/trunk: Lib/test/test_urlparse.py Lib/urlparse.py Misc/NEWS Message-ID: <20080105221907.5C9921E400B@bag.python.org> Author: guido.van.rossum Date: Sat Jan 5 23:19:06 2008 New Revision: 59758 Modified: python/trunk/Lib/test/test_urlparse.py python/trunk/Lib/urlparse.py python/trunk/Misc/NEWS Log: Patch #1637: fix urlparse for URLs like 'http://x.com?arg=/foo'. Fix by John Nagle. Modified: python/trunk/Lib/test/test_urlparse.py ============================================================================== --- python/trunk/Lib/test/test_urlparse.py (original) +++ python/trunk/Lib/test/test_urlparse.py Sat Jan 5 23:19:06 2008 @@ -316,6 +316,11 @@ self.assertEqual(type(p.hostname), type(uri)) self.assertEqual(type(p.path), type(uri)) + def test_noslash(self): + # Issue 1637: http://foo.com?query is legal + self.assertEqual(urlparse.urlparse("http://example.com?blahblah=/foo"), + ('http', 'example.com', '', '', 'blahblah=/foo', '')) + def test_main(): test_support.run_unittest(UrlParseTestCase) Modified: python/trunk/Lib/urlparse.py ============================================================================== --- python/trunk/Lib/urlparse.py (original) +++ python/trunk/Lib/urlparse.py Sat Jan 5 23:19:06 2008 @@ -169,13 +169,12 @@ return url[:i], url[i+1:] def _splitnetloc(url, start=0): - for c in '/?#': # the order is important! - delim = url.find(c, start) - if delim >= 0: - break - else: - delim = len(url) - return url[start:delim], url[delim:] + delim = len(url) # position of end of domain part of url, default is end + for c in '/?#': # look for delimiters; the order is NOT important + wdelim = url.find(c, start) # find first of this delim + if wdelim >= 0: # if found + delim = min(delim, wdelim) # use earliest delim position + return url[start:delim], url[delim:] # return (domain, rest) def urlsplit(url, scheme='', allow_fragments=True): """Parse a URL into 5 components: Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Sat Jan 5 23:19:06 2008 @@ -342,6 +342,8 @@ Library ------- +- Patch #1637: fix urlparse for URLs like 'http://x.com?arg=/foo'. + - Patch #1698: allow '@' in username parsed by urlparse.py. - Issue #1735: TarFile.extractall() now correctly sets directory permissions From python-checkins at python.org Sat Jan 5 23:20:01 2008 From: python-checkins at python.org (guido.van.rossum) Date: Sat, 5 Jan 2008 23:20:01 +0100 (CET) Subject: [Python-checkins] r59759 - python/trunk/Misc/ACKS Message-ID: <20080105222001.CF9A61E400B@bag.python.org> Author: guido.van.rossum Date: Sat Jan 5 23:20:01 2008 New Revision: 59759 Modified: python/trunk/Misc/ACKS Log: Add John Nagle (of issue #1637). Modified: python/trunk/Misc/ACKS ============================================================================== --- python/trunk/Misc/ACKS (original) +++ python/trunk/Misc/ACKS Sat Jan 5 23:20:01 2008 @@ -460,6 +460,7 @@ Sape Mullender Sjoerd Mullender Michael Muller +John Nagle Takahiro Nakayama Travers Naran Fredrik Nehr From nnorwitz at gmail.com Sat Jan 5 23:54:55 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Sat, 5 Jan 2008 17:54:55 -0500 Subject: [Python-checkins] Python Regression Test Failures all (1) Message-ID: <20080105225454.GA32078@python.psfb.org> test_grammar test_opcodes test_dict test_builtin test_exceptions test_types test_unittest test_doctest test_doctest2 test_MimeWriter test_StringIO test___all__ test___future__ test__locale test_abc test_abstract_numbers test_aepack test_aepack skipped -- No module named aepack test_al test_al skipped -- No module named al test_anydbm test_applesingle test_applesingle skipped -- No module named macostools test_array test_ast test_asynchat WARNING: failed to listen on port 54322, trying another test_asyncore test_atexit test_audioop test_augassign test_base64 test_bastion test_bigaddrspace test_bigmem test_binascii test_binhex test_binop test_bisect test_bool test_bsddb test_bsddb185 test_bsddb185 skipped -- No module named bsddb185 test_bsddb3 test_buffer test_bufio test_bz2 test_cProfile test_calendar test_call test_capi test_cd test_cd skipped -- No module named cd test_cfgparser test_cgi test_charmapcodec test_cl test_cl skipped -- No module named cl test_class test_cmath test_cmd test_cmd_line test_cmd_line_script test_code test_codeccallbacks test_codecencodings_cn test_codecencodings_hk test_codecencodings_jp test_codecencodings_kr test_codecencodings_tw test_codecmaps_cn test_codecmaps_hk test_codecmaps_jp test_codecmaps_kr test_codecmaps_tw test_codecs test_codeop test_coding test_coercion test_collections test_colorsys test_commands test_compare test_compile test_compiler testCompileLibrary still working, be patient... test_complex test_complex_args test_contains test_contextlib test_cookie test_cookielib test_copy test_copy_reg test_cpickle test_crypt test_csv test_ctypes test_datetime test_dbm test_decimal test_decorators test_defaultdict test_deque test_descr test_descrtut test_difflib test_dircache test_dis test_distutils test_dl test_docxmlrpc test_dumbdbm test_dummy_thread test_dummy_threading test_email test_email_codecs test_email_renamed test_enumerate test_eof test_errno test_exception_variations test_extcall test_fcntl test_file test_filecmp test_fileinput test_float test_fnmatch test_fork1 test_format test_fpformat test_frozen test_ftplib test_funcattrs test_functools test_future test_gc test_gdbm test_generators test_genericpath test_genexps test_getargs test_getargs2 test_getopt test_gettext test_gl test_gl skipped -- No module named gl test_glob test_global test_grp test_gzip test_hash test_hashlib test_heapq test_hexoct test_hmac test_hotshot test_htmllib test_htmlparser test_httplib test_imageop test_imageop skipped -- No module named imgfile test_imaplib test_imgfile test_imgfile skipped -- No module named imgfile test_imp test_import test_importhooks test_index test_inspect test_ioctl test_ioctl skipped -- Unable to open /dev/tty test_isinstance test_iter test_iterlen test_itertools test_largefile test_list test_locale test_logging test_long test_long_future test_longexp test_macostools test_macostools skipped -- No module named macostools test_macpath test_mailbox test_marshal test_math test_md5 test_mhlib test_mimetools test_mimetypes test_minidom test_mmap test_module test_modulefinder test_multibytecodec test_multibytecodec_support test_multifile test_mutants test_netrc test_new test_nis test_normalization test_ntpath test_old_mailbox test_openpty test_operator test_optparse test_os test_parser test_peepholer test_pep247 test_pep263 test_pep277 test_pep277 skipped -- test works only on NT+ test_pep292 test_pep352 test_pickle test_pickletools test_pipes test_pkg test_pkgimport test_platform test_plistlib test_plistlib skipped -- No module named plistlib test_poll test_popen [7425 refs] [7425 refs] [7425 refs] test_popen2 test_poplib test_posix test_posixpath test_pow test_pprint test_profile test_profilehooks test_property test_pty test_pwd test_pyclbr test_pyexpat test_queue test_quopri [7804 refs] [7804 refs] test_random test_re test_repr test_resource test_rfc822 test_richcmp test_robotparser test_runpy test_sax test_scope test_scriptpackages test_scriptpackages skipped -- No module named aetools test_select test_set test_sets test_sgmllib test_sha test_shelve test_shlex test_shutil test_signal test_site test_slice test_smtplib test_socket test_socket_ssl /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:94: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ssl_sock = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:60: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:130: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:144: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) test test_socket_ssl failed -- Traceback (most recent call last): File "/tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py", line 133, in testBasic self.assertEqual(i, "Foo\n") AssertionError: 'ERRO' != 'Foo\n' test_socketserver test_softspace test_sort test_sqlite test_ssl test_startfile test_startfile skipped -- cannot import name startfile test_str test_strftime test_string test_stringprep test_strop test_strptime test_struct test_structmembers test_structseq test_subprocess [7420 refs] [7421 refs] [7420 refs] [7420 refs] [7420 refs] [7420 refs] [7420 refs] [7420 refs] [7420 refs] [7420 refs] [7421 refs] [9040 refs] [7638 refs] [7421 refs] [7420 refs] [7420 refs] [7420 refs] [7420 refs] [7420 refs] . [7420 refs] [7420 refs] this bit of output is from a test of stdout in a different process ... [7420 refs] [7420 refs] [7638 refs] test_sunaudiodev test_sunaudiodev skipped -- No module named sunaudiodev test_sundry test_symtable test_syntax test_sys [7420 refs] [7420 refs] test_tarfile test_tcl test_tcl skipped -- No module named _tkinter test_telnetlib test_tempfile [7427 refs] test_textwrap test_thread test_threaded_import test_threadedtempfile test_threading [10562 refs] test_threading_local test_threadsignals test_time test_timeout test_tokenize test_trace test_traceback test_transformer test_tuple test_typechecks test_ucn test_unary test_unicode test_unicode_file test_unicode_file skipped -- No Unicode filesystem semantics on this platform. test_unicodedata test_univnewlines test_unpack test_urllib test_urllib2 test_urllib2_localnet test_urllib2net test_urllibnet test_urlparse test_userdict test_userlist test_userstring test_uu test_uuid WARNING: uuid.getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._ifconfig_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._unixdll_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. test_wait3 test_wait4 test_warnings test_wave test_weakref test_whichdb test_winreg test_winreg skipped -- No module named _winreg test_winsound test_winsound skipped -- No module named winsound test_with test_wsgiref test_xdrlib test_xml_etree test_xml_etree_c test_xmllib test_xmlrpc test_xpickle test_xrange test_zipfile test_zipfile64 test_zipfile64 skipped -- test requires loads of disk-space bytes and a long time to run test_zipimport test_zlib 312 tests OK. 1 test failed: test_socket_ssl 21 tests skipped: test_aepack test_al test_applesingle test_bsddb185 test_cd test_cl test_gl test_imageop test_imgfile test_ioctl test_macostools test_pep277 test_plistlib test_scriptpackages test_startfile test_sunaudiodev test_tcl test_unicode_file test_winreg test_winsound test_zipfile64 1 skip unexpected on linux2: test_ioctl [534889 refs] From python-checkins at python.org Sun Jan 6 00:34:38 2008 From: python-checkins at python.org (guido.van.rossum) Date: Sun, 6 Jan 2008 00:34:38 +0100 (CET) Subject: [Python-checkins] r59760 - python/branches/release25-maint/Lib/test/test_urlparse.py Message-ID: <20080105233438.6FD181E4014@bag.python.org> Author: guido.van.rossum Date: Sun Jan 6 00:34:38 2008 New Revision: 59760 Modified: python/branches/release25-maint/Lib/test/test_urlparse.py Log: Backport r59758. Patch #1637: fix urlparse for URLs like 'http://x.com?arg=/foo'. Fix by John Nagle. Modified: python/branches/release25-maint/Lib/test/test_urlparse.py ============================================================================== --- python/branches/release25-maint/Lib/test/test_urlparse.py (original) +++ python/branches/release25-maint/Lib/test/test_urlparse.py Sun Jan 6 00:34:38 2008 @@ -298,6 +298,11 @@ self.assertEqual(type(p.hostname), type(uri)) self.assertEqual(type(p.path), type(uri)) + def test_noslash(self): + # Issue 1637: http://foo.com?query is legal + self.assertEqual(urlparse.urlparse("http://example.com?blahblah=/foo"), + ('http', 'example.com', '', '', 'blahblah=/foo', '')) + def test_main(): test_support.run_unittest(UrlParseTestCase) From buildbot at python.org Sun Jan 6 00:58:15 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 05 Jan 2008 23:58:15 +0000 Subject: [Python-checkins] buildbot failure in x86 gentoo 2.5 Message-ID: <20080105235815.DE4B01E400B@bag.python.org> The Buildbot has detected a new failure of x86 gentoo 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20gentoo%202.5/builds/493 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-x86 Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: guido.van.rossum BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_urlparse ====================================================================== FAIL: test_noslash (test.test_urlparse.UrlParseTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildslave/python-trunk/2.5.norwitz-x86/build/Lib/test/test_urlparse.py", line 304, in test_noslash ('http', 'example.com', '', '', 'blahblah=/foo', '')) AssertionError: ('http', 'example.com?blahblah=', '/foo', '', '', '') != ('http', 'example.com', '', '', 'blahblah=/foo', '') make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Sun Jan 6 00:58:16 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 05 Jan 2008 23:58:16 +0000 Subject: [Python-checkins] buildbot failure in x86 mvlgcc 2.5 Message-ID: <20080105235816.43C341E400B@bag.python.org> The Buildbot has detected a new failure of x86 mvlgcc 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20mvlgcc%202.5/builds/369 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-linux Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: guido.van.rossum BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_urlparse ====================================================================== FAIL: test_noslash (test.test_urlparse.UrlParseTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home2/buildbot/slave/2.5.loewis-linux/build/Lib/test/test_urlparse.py", line 304, in test_noslash ('http', 'example.com', '', '', 'blahblah=/foo', '')) AssertionError: ('http', 'example.com?blahblah=', '/foo', '', '', '') != ('http', 'example.com', '', '', 'blahblah=/foo', '') make: *** [buildbottest] Fehler 1 sincerely, -The Buildbot From buildbot at python.org Sun Jan 6 01:00:36 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 06 Jan 2008 00:00:36 +0000 Subject: [Python-checkins] buildbot failure in x86 XP-3 2.5 Message-ID: <20080106000036.A28C71E400B@bag.python.org> The Buildbot has detected a new failure of x86 XP-3 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20XP-3%202.5/builds/133 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: heller-windows Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: guido.van.rossum BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_urlparse ====================================================================== FAIL: test_noslash (test.test_urlparse.UrlParseTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\2.5.heller-windows\build\lib\test\test_urlparse.py", line 304, in test_noslash ('http', 'example.com', '', '', 'blahblah=/foo', '')) AssertionError: ('http', 'example.com?blahblah=', '/foo', '', '', '') != ('http', 'example.com', '', '', 'blahblah=/foo', '') sincerely, -The Buildbot From buildbot at python.org Sun Jan 6 01:17:40 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 06 Jan 2008 00:17:40 +0000 Subject: [Python-checkins] buildbot failure in sparc solaris10 gcc 2.5 Message-ID: <20080106001740.B02161E4011@bag.python.org> The Buildbot has detected a new failure of sparc solaris10 gcc 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/sparc%20solaris10%20gcc%202.5/builds/477 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-sun Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: guido.van.rossum BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_urlparse ====================================================================== FAIL: test_noslash (test.test_urlparse.UrlParseTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/opt/users/buildbot/slave/2.5.loewis-sun/build/Lib/test/test_urlparse.py", line 304, in test_noslash ('http', 'example.com', '', '', 'blahblah=/foo', '')) AssertionError: ('http', 'example.com?blahblah=', '/foo', '', '', '') != ('http', 'example.com', '', '', 'blahblah=/foo', '') sincerely, -The Buildbot From buildbot at python.org Sun Jan 6 01:19:39 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 06 Jan 2008 00:19:39 +0000 Subject: [Python-checkins] buildbot failure in hppa Ubuntu trunk Message-ID: <20080106001939.5A2551E400B@bag.python.org> The Buildbot has detected a new failure of hppa Ubuntu trunk. Full details are available at: http://www.python.org/dev/buildbot/all/hppa%20Ubuntu%20trunk/builds/461 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-ubuntu-hppa Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: guido.van.rossum BUILD FAILED: failed test Excerpt from the test logfile: 2 tests failed: test_bsddb3 test_urllib2net ====================================================================== ERROR: test00_associateDBError (bsddb.test.test_associate.AssociateErrorTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 104, in setUp self.env.open(homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateBTreeTxnTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateBTreeTxnTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test13_associate_in_transaction (bsddb.test.test_associate.AssociateBTreeTxnTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ShelveAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ShelveAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ShelveAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ThreadedAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ThreadedAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ThreadedAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ThreadedAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ThreadedAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ThreadedAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_EnvRemoveAndRename (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_EnvRemoveAndRename (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Transactions (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_TxnTruncate (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test08_TxnLateUse (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Transactions (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_TxnTruncate (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test08_TxnLateUse (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test09_MultiDB (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test09_MultiDB (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_both (bsddb.test.test_dbobj.dbobjTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbobj.py", line 45, in test01_both self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbobj.py", line 39, in open return apply(self._cobj.open, args, kwargs) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_dbobj_dict_interface (bsddb.test.test_dbobj.dbobjTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbobj.py", line 58, in test02_dbobj_dict_interface self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbobj.py", line 39, in open return apply(self._cobj.open, args, kwargs) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01 (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02 (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03 (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_MultiCondSelect (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_CondObjs (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_CreateOrExtend (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_Delete (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_Modify (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_close_dbenv_before_db (bsddb.test.test_env_close.DBEnvClosedEarlyCrash) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_env_close.py", line 53, in test01_close_dbenv_before_db 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_close_dbenv_delete_db_success (bsddb.test.test_env_close.DBEnvClosedEarlyCrash) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_env_close.py", line 78, in test02_close_dbenv_delete_db_success 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_join (bsddb.test.test_join.JoinTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_join.py", line 57, in setUp self.env.open(homeDir, db.DB_CREATE | db.DB_INIT_MPOOL | db.DB_INIT_LOCK ) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_simple (bsddb.test.test_lock.LockingTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_lock.py", line 38, in setUp db.DB_INIT_LOCK | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_threaded (bsddb.test.test_lock.LockingTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_lock.py", line 38, in setUp db.DB_INIT_LOCK | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_set_timeout (bsddb.test.test_lock.LockingTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_lock.py", line 38, in setUp db.DB_INIT_LOCK | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_db_home (bsddb.test.test_misc.MiscTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_misc.py", line 45, in test02_db_home env.open(self.homeDir, db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_1WriterMultiReaders (bsddb.test.test_thread.BTreeConcurrentDataStore) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_1WriterMultiReaders (bsddb.test.test_thread.HashConcurrentDataStore) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_SimpleLocks (bsddb.test.test_thread.BTreeSimpleThreaded) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_SimpleLocks (bsddb.test.test_thread.HashSimpleThreaded) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.BTreeThreadedTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.HashThreadedTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.BTreeThreadedNoWaitTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.HashThreadedNoWaitTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_cachesize (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_flags (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_get (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_get_dbp (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_get_key (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_range (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_remove (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_stat (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_pget (bsddb.test.test_cursor_pget_bug.pget_bugTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_cursor_pget_bug.py", line 25, in setUp self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Sun Jan 6 01:24:07 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 06 Jan 2008 00:24:07 +0000 Subject: [Python-checkins] buildbot failure in x86 FreeBSD 2.5 Message-ID: <20080106002407.932951E400B@bag.python.org> The Buildbot has detected a new failure of x86 FreeBSD 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20FreeBSD%202.5/builds/81 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-freebsd Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: guido.van.rossum BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_urlparse ====================================================================== FAIL: test_noslash (test.test_urlparse.UrlParseTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/usr/home/db3l/buildarea/2.5.bolen-freebsd/build/Lib/test/test_urlparse.py", line 304, in test_noslash ('http', 'example.com', '', '', 'blahblah=/foo', '')) AssertionError: ('http', 'example.com?blahblah=', '/foo', '', '', '') != ('http', 'example.com', '', '', 'blahblah=/foo', '') sincerely, -The Buildbot From buildbot at python.org Sun Jan 6 01:38:40 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 06 Jan 2008 00:38:40 +0000 Subject: [Python-checkins] buildbot failure in alpha Tru64 5.1 2.5 Message-ID: <20080106003840.EAF1E1E400B@bag.python.org> The Buildbot has detected a new failure of alpha Tru64 5.1 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/alpha%20Tru64%205.1%202.5/builds/388 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-tru64 Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: guido.van.rossum BUILD FAILED: failed test Excerpt from the test logfile: 2 tests failed: test_socket test_urlparse ====================================================================== FAIL: testInterruptedTimeout (test.test_socket.TCPTimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/net/taipan/scratch1/nnorwitz/python/2.5.norwitz-tru64/build/Lib/test/test_socket.py", line 879, in testInterruptedTimeout self.fail("got Alarm in wrong place") AssertionError: got Alarm in wrong place ====================================================================== FAIL: test_noslash (test.test_urlparse.UrlParseTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/net/taipan/scratch1/nnorwitz/python/2.5.norwitz-tru64/build/Lib/test/test_urlparse.py", line 304, in test_noslash ('http', 'example.com', '', '', 'blahblah=/foo', '')) AssertionError: ('http', 'example.com?blahblah=', '/foo', '', '', '') != ('http', 'example.com', '', '', 'blahblah=/foo', '') sincerely, -The Buildbot From buildbot at python.org Sun Jan 6 02:03:46 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 06 Jan 2008 01:03:46 +0000 Subject: [Python-checkins] buildbot failure in g4 osx.4 2.5 Message-ID: <20080106010346.9148A1E4014@bag.python.org> The Buildbot has detected a new failure of g4 osx.4 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/g4%20osx.4%202.5/builds/477 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: psf-g4 Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: guido.van.rossum BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_urlparse ====================================================================== FAIL: test_noslash (test.test_urlparse.UrlParseTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/test/test_urlparse.py", line 304, in test_noslash ('http', 'example.com', '', '', 'blahblah=/foo', '')) AssertionError: ('http', 'example.com?blahblah=', '/foo', '', '', '') != ('http', 'example.com', '', '', 'blahblah=/foo', '') make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Sun Jan 6 03:40:07 2008 From: python-checkins at python.org (guido.van.rossum) Date: Sun, 6 Jan 2008 03:40:07 +0100 (CET) Subject: [Python-checkins] r59764 - in python/branches/release25-maint: Lib/urlparse.py Misc/NEWS Message-ID: <20080106024007.B10991E400B@bag.python.org> Author: guido.van.rossum Date: Sun Jan 6 03:40:07 2008 New Revision: 59764 Modified: python/branches/release25-maint/Lib/urlparse.py python/branches/release25-maint/Misc/NEWS Log: Forgot to backport the rest of #1637. Modified: python/branches/release25-maint/Lib/urlparse.py ============================================================================== --- python/branches/release25-maint/Lib/urlparse.py (original) +++ python/branches/release25-maint/Lib/urlparse.py Sun Jan 6 03:40:07 2008 @@ -169,13 +169,12 @@ return url[:i], url[i+1:] def _splitnetloc(url, start=0): - for c in '/?#': # the order is important! - delim = url.find(c, start) - if delim >= 0: - break - else: - delim = len(url) - return url[start:delim], url[delim:] + delim = len(url) # position of end of domain part of url, default is end + for c in '/?#': # look for delimiters; the order is NOT important + wdelim = url.find(c, start) # find first of this delim + if wdelim >= 0: # if found + delim = min(delim, wdelim) # use earliest delim position + return url[start:delim], url[delim:] # return (domain, rest) def urlsplit(url, scheme='', allow_fragments=True): """Parse a URL into 5 components: Modified: python/branches/release25-maint/Misc/NEWS ============================================================================== --- python/branches/release25-maint/Misc/NEWS (original) +++ python/branches/release25-maint/Misc/NEWS Sun Jan 6 03:40:07 2008 @@ -53,6 +53,8 @@ Library ------- +- Patch #1637: fix urlparse for URLs like 'http://x.com?arg=/foo'. + - Issue #1735: TarFile.extractall() now correctly sets directory permissions and times. From python-checkins at python.org Sun Jan 6 10:02:25 2008 From: python-checkins at python.org (raymond.hettinger) Date: Sun, 6 Jan 2008 10:02:25 +0100 (CET) Subject: [Python-checkins] r59765 - in python/trunk: Doc/library/collections.rst Lib/collections.py Message-ID: <20080106090225.645221E400B@bag.python.org> Author: raymond.hettinger Date: Sun Jan 6 10:02:24 2008 New Revision: 59765 Modified: python/trunk/Doc/library/collections.rst python/trunk/Lib/collections.py Log: Small code simplification. Forgot that classmethods can be called from intances. Modified: python/trunk/Doc/library/collections.rst ============================================================================== --- python/trunk/Doc/library/collections.rst (original) +++ python/trunk/Doc/library/collections.rst Sun Jan 6 10:02:24 2008 @@ -410,7 +410,7 @@ def _replace(self, **kwds): 'Return a new Point object replacing specified fields with new values' - result = self.__class__._make(map(kwds.pop, ('x', 'y'), self)) + result = self._make(map(kwds.pop, ('x', 'y'), self)) if kwds: raise ValueError('Got unexpected field names: %r' % kwds.keys()) return result Modified: python/trunk/Lib/collections.py ============================================================================== --- python/trunk/Lib/collections.py (original) +++ python/trunk/Lib/collections.py Sun Jan 6 10:02:24 2008 @@ -78,7 +78,7 @@ return {%(dicttxt)s} \n def _replace(self, **kwds): 'Return a new %(typename)s object replacing specified fields with new values' - result = self.__class__._make(map(kwds.pop, %(field_names)r, self)) + result = self._make(map(kwds.pop, %(field_names)r, self)) if kwds: raise ValueError('Got unexpected field names: %%r' %% kwds.keys()) return result \n\n''' % locals() From buildbot at python.org Sun Jan 6 10:50:47 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 06 Jan 2008 09:50:47 +0000 Subject: [Python-checkins] buildbot failure in x86 FreeBSD trunk Message-ID: <20080106095047.A4DDB1E4016@bag.python.org> The Buildbot has detected a new failure of x86 FreeBSD trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20FreeBSD%20trunk/builds/344 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-freebsd Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 523, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 523, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable 1 test failed: test_xmlrpc sincerely, -The Buildbot From buildbot at python.org Sun Jan 6 11:03:59 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 06 Jan 2008 10:03:59 +0000 Subject: [Python-checkins] buildbot failure in x86 gentoo trunk Message-ID: <20080106100359.7FCEB1E400B@bag.python.org> The Buildbot has detected a new failure of x86 gentoo trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20gentoo%20trunk/builds/2821 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-x86 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: sincerely, -The Buildbot From python-checkins at python.org Sun Jan 6 11:09:49 2008 From: python-checkins at python.org (martin.v.loewis) Date: Sun, 6 Jan 2008 11:09:49 +0100 (CET) Subject: [Python-checkins] r59766 - python/trunk/Tools/buildbot/buildmsi.bat Message-ID: <20080106100949.060351E400B@bag.python.org> Author: martin.v.loewis Date: Sun Jan 6 11:09:48 2008 New Revision: 59766 Modified: python/trunk/Tools/buildbot/buildmsi.bat Log: Use vcbuild for VS 2009. Modified: python/trunk/Tools/buildbot/buildmsi.bat ============================================================================== --- python/trunk/Tools/buildbot/buildmsi.bat (original) +++ python/trunk/Tools/buildbot/buildmsi.bat Sun Jan 6 11:09:48 2008 @@ -4,12 +4,12 @@ @rem build release versions of things call "%VS90COMNTOOLS%vsvars32.bat" if not exist ..\db-4.4.20\build_win32\release\libdb44s.lib ( - devenv ..\db-4.4.20\build_win32\Berkeley_DB.sln /build Release /project db_static + vcbuild db-4.4.20\build_win32\Berkeley_DB.sln /build Release /project db_static ) @rem build Python cmd /q/c Tools\buildbot\kill_python.bat -devenv.com /useenv /build Release PCbuild\pcbuild.sln +vcbuild /useenv PCbuild\pcbuild.sln "Release|Win32" @rem build the documentation bash.exe -c 'cd Doc;make PYTHON=python2.5 update htmlhelp' From python-checkins at python.org Sun Jan 6 12:03:43 2008 From: python-checkins at python.org (martin.v.loewis) Date: Sun, 6 Jan 2008 12:03:43 +0100 (CET) Subject: [Python-checkins] r59767 - python/trunk/Tools/msi/msi.py Message-ID: <20080106110343.681C91E400F@bag.python.org> Author: martin.v.loewis Date: Sun Jan 6 12:03:43 2008 New Revision: 59767 Modified: python/trunk/Tools/msi/msi.py Log: Package using VS 2008. Modified: python/trunk/Tools/msi/msi.py ============================================================================== --- python/trunk/Tools/msi/msi.py (original) +++ python/trunk/Tools/msi/msi.py Sun Jan 6 12:03:43 2008 @@ -27,11 +27,10 @@ # Where is sqlite3.dll located, relative to srcdir? sqlite_dir = "../sqlite-source-3.3.4" # path to PCbuild directory -PCBUILD="PC\\VS7.1" -#PCBUILD="PCbuild" +PCBUILD="PCbuild" # msvcrt version -MSVCR = "71" -#MSVCR = "90" +#MSVCR = "71" +MSVCR = "90" try: from config import * From python-checkins at python.org Sun Jan 6 12:13:16 2008 From: python-checkins at python.org (martin.v.loewis) Date: Sun, 6 Jan 2008 12:13:16 +0100 (CET) Subject: [Python-checkins] r59768 - python/trunk/Tools/msi/msi.py Message-ID: <20080106111316.E71D21E400F@bag.python.org> Author: martin.v.loewis Date: Sun Jan 6 12:13:16 2008 New Revision: 59768 Modified: python/trunk/Tools/msi/msi.py Log: Don't try to package msvcr90 for the moment. Modified: python/trunk/Tools/msi/msi.py ============================================================================== --- python/trunk/Tools/msi/msi.py (original) +++ python/trunk/Tools/msi/msi.py Sun Jan 6 12:13:16 2008 @@ -902,12 +902,15 @@ language=installer.FileVersion(pydllsrc, 1)) # XXX determine dependencies if MSVCR == "90": - version, lang = extract_msvcr90() - dlldir.start_component("msvcr90", flags=8, keyfile="msvcr90.dll", - uuid=msvcr90_uuid) - dlldir.add_file("msvcr90.dll", src=os.path.abspath("msvcr90.dll"), - version=version, language=lang) - tmpfiles.append("msvcr90.dll") + # XXX don't package the CRT for the moment; + # this should probably use the merge module in the long run. + pass + #version, lang = extract_msvcr90() + #dlldir.start_component("msvcr90", flags=8, keyfile="msvcr90.dll", + # uuid=msvcr90_uuid) + #dlldir.add_file("msvcr90.dll", src=os.path.abspath("msvcr90.dll"), + # version=version, language=lang) + #tmpfiles.append("msvcr90.dll") else: version, lang = extract_msvcr71() dlldir.start_component("msvcr71", flags=8, keyfile="msvcr71.dll", From buildbot at python.org Sun Jan 6 12:47:10 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 06 Jan 2008 11:47:10 +0000 Subject: [Python-checkins] buildbot failure in ppc Debian unstable trunk Message-ID: <20080106114711.1665C1E400F@bag.python.org> The Buildbot has detected a new failure of ppc Debian unstable trunk. Full details are available at: http://www.python.org/dev/buildbot/all/ppc%20Debian%20unstable%20trunk/builds/533 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: martin.v.loewis BUILD FAILED: failed test Excerpt from the test logfile: 2 tests failed: test_socket_ssl test_xmlrpc ====================================================================== ERROR: test_fail_no_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_xmlrpc.py", line 560, in test_fail_no_info p.pow(6,8) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1157, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1447, in __request verbose=self.__verbose File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1195, in request errcode, errmsg, headers = h.getreply() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 1006, in getreply response = self._conn.getresponse() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 932, in getresponse response.begin() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 415, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 271, in readheaders line = self.fp.readline() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/socket.py", line 354, in readline data = recv(1) error: [Errno 104] Connection reset by peer ====================================================================== ERROR: test_fail_with_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_xmlrpc.py", line 580, in test_fail_with_info p.pow(6,8) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1157, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1447, in __request verbose=self.__verbose File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1195, in request errcode, errmsg, headers = h.getreply() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 1006, in getreply response = self._conn.getresponse() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 932, in getresponse response.begin() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 415, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 271, in readheaders line = self.fp.readline() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/socket.py", line 354, in readline data = recv(1) error: [Errno 104] Connection reset by peer make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Sun Jan 6 12:50:19 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 06 Jan 2008 11:50:19 +0000 Subject: [Python-checkins] buildbot failure in PPC64 Debian trunk Message-ID: <20080106115019.B18441E400F@bag.python.org> The Buildbot has detected a new failure of PPC64 Debian trunk. Full details are available at: http://www.python.org/dev/buildbot/all/PPC64%20Debian%20trunk/builds/40 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: martin.v.loewis BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/SocketServer.py", line 523, in __init__ self.handle() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/BaseHTTPServer.py", line 310, in handle_one_request method() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/SimpleXMLRPCServer.py", line 449, in do_POST self.report_404() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/SimpleXMLRPCServer.py", line 507, in report_404 self.connection.shutdown(1) File "", line 1, in shutdown error: [Errno 107] Transport endpoint is not connected 1 test failed: test_xmlrpc Traceback (most recent call last): File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/SocketServer.py", line 523, in __init__ self.handle() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/BaseHTTPServer.py", line 310, in handle_one_request method() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/SimpleXMLRPCServer.py", line 449, in do_POST self.report_404() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/SimpleXMLRPCServer.py", line 507, in report_404 self.connection.shutdown(1) File "", line 1, in shutdown error: [Errno 107] Transport endpoint is not connected ====================================================================== ERROR: test_fail_no_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/test/test_xmlrpc.py", line 560, in test_fail_no_info p.pow(6,8) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/xmlrpclib.py", line 1157, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/xmlrpclib.py", line 1447, in __request verbose=self.__verbose File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/xmlrpclib.py", line 1195, in request errcode, errmsg, headers = h.getreply() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 1006, in getreply response = self._conn.getresponse() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 932, in getresponse response.begin() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 415, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 271, in readheaders line = self.fp.readline() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/socket.py", line 354, in readline data = recv(1) error: [Errno 104] Connection reset by peer ====================================================================== ERROR: test_fail_with_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/test/test_xmlrpc.py", line 580, in test_fail_with_info p.pow(6,8) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/xmlrpclib.py", line 1157, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/xmlrpclib.py", line 1447, in __request verbose=self.__verbose File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/xmlrpclib.py", line 1195, in request errcode, errmsg, headers = h.getreply() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 1006, in getreply response = self._conn.getresponse() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 932, in getresponse response.begin() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 415, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 271, in readheaders line = self.fp.readline() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/socket.py", line 354, in readline data = recv(1) error: [Errno 104] Connection reset by peer make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Sun Jan 6 13:56:12 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 06 Jan 2008 12:56:12 +0000 Subject: [Python-checkins] buildbot failure in hppa Ubuntu trunk Message-ID: <20080106125613.1ADC41E4024@bag.python.org> The Buildbot has detected a new failure of hppa Ubuntu trunk. Full details are available at: http://www.python.org/dev/buildbot/all/hppa%20Ubuntu%20trunk/builds/465 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-ubuntu-hppa Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: martin.v.loewis BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_bsddb3 ====================================================================== ERROR: test00_associateDBError (bsddb.test.test_associate.AssociateErrorTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 104, in setUp self.env.open(homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateBTreeTxnTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateBTreeTxnTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test13_associate_in_transaction (bsddb.test.test_associate.AssociateBTreeTxnTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ShelveAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ShelveAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ShelveAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ThreadedAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ThreadedAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ThreadedAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ThreadedAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ThreadedAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ThreadedAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_EnvRemoveAndRename (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_EnvRemoveAndRename (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Transactions (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_TxnTruncate (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test08_TxnLateUse (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Transactions (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_TxnTruncate (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test08_TxnLateUse (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test09_MultiDB (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test09_MultiDB (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_both (bsddb.test.test_dbobj.dbobjTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbobj.py", line 45, in test01_both self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbobj.py", line 39, in open return apply(self._cobj.open, args, kwargs) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_dbobj_dict_interface (bsddb.test.test_dbobj.dbobjTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbobj.py", line 58, in test02_dbobj_dict_interface self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbobj.py", line 39, in open return apply(self._cobj.open, args, kwargs) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01 (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02 (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03 (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_MultiCondSelect (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_CondObjs (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_CreateOrExtend (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_Delete (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_Modify (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_close_dbenv_before_db (bsddb.test.test_env_close.DBEnvClosedEarlyCrash) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_env_close.py", line 53, in test01_close_dbenv_before_db 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_close_dbenv_delete_db_success (bsddb.test.test_env_close.DBEnvClosedEarlyCrash) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_env_close.py", line 78, in test02_close_dbenv_delete_db_success 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_join (bsddb.test.test_join.JoinTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_join.py", line 57, in setUp self.env.open(homeDir, db.DB_CREATE | db.DB_INIT_MPOOL | db.DB_INIT_LOCK ) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_simple (bsddb.test.test_lock.LockingTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_lock.py", line 38, in setUp db.DB_INIT_LOCK | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_threaded (bsddb.test.test_lock.LockingTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_lock.py", line 38, in setUp db.DB_INIT_LOCK | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_set_timeout (bsddb.test.test_lock.LockingTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_lock.py", line 38, in setUp db.DB_INIT_LOCK | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_db_home (bsddb.test.test_misc.MiscTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_misc.py", line 45, in test02_db_home env.open(self.homeDir, db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_1WriterMultiReaders (bsddb.test.test_thread.BTreeConcurrentDataStore) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_1WriterMultiReaders (bsddb.test.test_thread.HashConcurrentDataStore) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_SimpleLocks (bsddb.test.test_thread.BTreeSimpleThreaded) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_SimpleLocks (bsddb.test.test_thread.HashSimpleThreaded) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.BTreeThreadedTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.HashThreadedTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.BTreeThreadedNoWaitTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.HashThreadedNoWaitTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_cachesize (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_flags (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_get (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_get_dbp (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_get_key (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_range (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_remove (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_stat (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_pget (bsddb.test.test_cursor_pget_bug.pget_bugTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_cursor_pget_bug.py", line 25, in setUp self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Sun Jan 6 15:17:36 2008 From: python-checkins at python.org (georg.brandl) Date: Sun, 6 Jan 2008 15:17:36 +0100 (CET) Subject: [Python-checkins] r59769 - python/trunk/Lib/ntpath.py Message-ID: <20080106141736.855211E4003@bag.python.org> Author: georg.brandl Date: Sun Jan 6 15:17:36 2008 New Revision: 59769 Modified: python/trunk/Lib/ntpath.py Log: #1696393: don't check for '.' and '..' in ntpath.walk since they aren't returned from os.listdir anymore. Reported by Michael Haggerty. Modified: python/trunk/Lib/ntpath.py ============================================================================== --- python/trunk/Lib/ntpath.py (original) +++ python/trunk/Lib/ntpath.py Sun Jan 6 15:17:36 2008 @@ -254,12 +254,10 @@ except os.error: return func(arg, top, names) - exceptions = ('.', '..') for name in names: - if name not in exceptions: - name = join(top, name) - if isdir(name): - walk(name, func, arg) + name = join(top, name) + if isdir(name): + walk(name, func, arg) # Expand paths beginning with '~' or '~user'. From python-checkins at python.org Sun Jan 6 15:27:16 2008 From: python-checkins at python.org (georg.brandl) Date: Sun, 6 Jan 2008 15:27:16 +0100 (CET) Subject: [Python-checkins] r59770 - in python/trunk: Lib/ntpath.py Lib/posixpath.py Lib/test/test_ntpath.py Lib/test/test_posixpath.py Misc/NEWS Message-ID: <20080106142716.51C401E400F@bag.python.org> Author: georg.brandl Date: Sun Jan 6 15:27:15 2008 New Revision: 59770 Modified: python/trunk/Lib/ntpath.py python/trunk/Lib/posixpath.py python/trunk/Lib/test/test_ntpath.py python/trunk/Lib/test/test_posixpath.py python/trunk/Misc/NEWS Log: #1742: don't raise exception on os.path.relpath("a", "a"), but return os.curdir. Reported by Jesse Towner. Modified: python/trunk/Lib/ntpath.py ============================================================================== --- python/trunk/Lib/ntpath.py (original) +++ python/trunk/Lib/ntpath.py Sun Jan 6 15:27:15 2008 @@ -490,4 +490,6 @@ i += 1 rel_list = [pardir] * (len(start_list)-i) + path_list[i:] + if not rel_list: + return curdir return join(*rel_list) Modified: python/trunk/Lib/posixpath.py ============================================================================== --- python/trunk/Lib/posixpath.py (original) +++ python/trunk/Lib/posixpath.py Sun Jan 6 15:27:15 2008 @@ -398,4 +398,6 @@ i = len(commonprefix([start_list, path_list])) rel_list = [pardir] * (len(start_list)-i) + path_list[i:] + if not rel_list: + return curdir return join(*rel_list) Modified: python/trunk/Lib/test/test_ntpath.py ============================================================================== --- python/trunk/Lib/test/test_ntpath.py (original) +++ python/trunk/Lib/test/test_ntpath.py Sun Jan 6 15:27:15 2008 @@ -166,6 +166,7 @@ tester('ntpath.relpath("a/b", "../c")', '..\\'+currentdir+'\\a\\b') tester('ntpath.relpath("a", "b/c")', '..\\..\\a') tester('ntpath.relpath("//conky/mountpoint/a", "//conky/mountpoint/b/c")', '..\\..\\a') +tester('ntpath.relpath("a", "a")', '.') if errors: raise TestFailed(str(errors) + " errors.") Modified: python/trunk/Lib/test/test_posixpath.py ============================================================================== --- python/trunk/Lib/test/test_posixpath.py (original) +++ python/trunk/Lib/test/test_posixpath.py Sun Jan 6 15:27:15 2008 @@ -501,6 +501,7 @@ self.assertEqual(posixpath.relpath("a", "../b"), "../"+curdir+"/a") self.assertEqual(posixpath.relpath("a/b", "../c"), "../"+curdir+"/a/b") self.assertEqual(posixpath.relpath("a", "b/c"), "../../a") + self.assertEqual(posixpath.relpath("a", "a"), ".") finally: os.getcwd = real_getcwd Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Sun Jan 6 15:27:15 2008 @@ -342,6 +342,9 @@ Library ------- +- Bug #1742: return os.curdir from os.path.relpath() if both arguments are + equal instead of raising an exception. + - Patch #1637: fix urlparse for URLs like 'http://x.com?arg=/foo'. - Patch #1698: allow '@' in username parsed by urlparse.py. From python-checkins at python.org Sun Jan 6 15:33:52 2008 From: python-checkins at python.org (georg.brandl) Date: Sun, 6 Jan 2008 15:33:52 +0100 (CET) Subject: [Python-checkins] r59771 - python/trunk/Lib/popen2.py Message-ID: <20080106143352.D1DF81E400F@bag.python.org> Author: georg.brandl Date: Sun Jan 6 15:33:52 2008 New Revision: 59771 Modified: python/trunk/Lib/popen2.py Log: #1591: Clarify docstring of Popen3. Modified: python/trunk/Lib/popen2.py ============================================================================== --- python/trunk/Lib/popen2.py (original) +++ python/trunk/Lib/popen2.py Sun Jan 6 15:33:52 2008 @@ -32,8 +32,8 @@ pass class Popen3: - """Class representing a child process. Normally instances are created - by the factory functions popen2() and popen3().""" + """Class representing a child process. Normally, instances are created + internally by the functions popen2() and popen3().""" sts = -1 # Child not completed yet From python-checkins at python.org Sun Jan 6 16:30:34 2008 From: python-checkins at python.org (georg.brandl) Date: Sun, 6 Jan 2008 16:30:34 +0100 (CET) Subject: [Python-checkins] r59772 - python/trunk/Doc/library/stdtypes.rst Message-ID: <20080106153034.E0BE11E4012@bag.python.org> Author: georg.brandl Date: Sun Jan 6 16:30:34 2008 New Revision: 59772 Modified: python/trunk/Doc/library/stdtypes.rst Log: #1680: fix context manager example function name. Modified: python/trunk/Doc/library/stdtypes.rst ============================================================================== --- python/trunk/Doc/library/stdtypes.rst (original) +++ python/trunk/Doc/library/stdtypes.rst Sun Jan 6 16:30:34 2008 @@ -2190,7 +2190,7 @@ the context expression in a :keyword:`with` statement. An example of a context manager that returns a related object is the one - returned by ``decimal.Context.get_manager()``. These managers set the active + returned by :func:`decimal.localcontext`. These managers set the active decimal context to a copy of the original decimal context and then return the copy. This allows changes to be made to the current decimal context in the body of the :keyword:`with` statement without affecting code outside the From python-checkins at python.org Sun Jan 6 16:34:58 2008 From: python-checkins at python.org (georg.brandl) Date: Sun, 6 Jan 2008 16:34:58 +0100 (CET) Subject: [Python-checkins] r59773 - python/trunk/Doc/library/functions.rst python/trunk/Doc/library/stdtypes.rst Message-ID: <20080106153458.3401A1E43A5@bag.python.org> Author: georg.brandl Date: Sun Jan 6 16:34:57 2008 New Revision: 59773 Modified: python/trunk/Doc/library/functions.rst python/trunk/Doc/library/stdtypes.rst Log: #1755097: document default values for [].sort() and sorted(). Modified: python/trunk/Doc/library/functions.rst ============================================================================== --- python/trunk/Doc/library/functions.rst (original) +++ python/trunk/Doc/library/functions.rst Sun Jan 6 16:34:57 2008 @@ -1038,10 +1038,11 @@ *cmp* specifies a custom comparison function of two arguments (iterable elements) which should return a negative, zero or positive number depending on whether the first argument is considered smaller than, equal to, or larger than - the second argument: ``cmp=lambda x,y: cmp(x.lower(), y.lower())`` + the second argument: ``cmp=lambda x,y: cmp(x.lower(), y.lower())``. The default + value is ``None``. *key* specifies a function of one argument that is used to extract a comparison - key from each list element: ``key=str.lower`` + key from each list element: ``key=str.lower``. The default value is ``None``. *reverse* is a boolean value. If set to ``True``, then the list elements are sorted as if each comparison were reversed. Modified: python/trunk/Doc/library/stdtypes.rst ============================================================================== --- python/trunk/Doc/library/stdtypes.rst (original) +++ python/trunk/Doc/library/stdtypes.rst Sun Jan 6 16:34:57 2008 @@ -1408,10 +1408,11 @@ *cmp* specifies a custom comparison function of two arguments (list items) which should return a negative, zero or positive number depending on whether the first argument is considered smaller than, equal to, or larger than the second - argument: ``cmp=lambda x,y: cmp(x.lower(), y.lower())`` + argument: ``cmp=lambda x,y: cmp(x.lower(), y.lower())``. The default value + is ``None``. *key* specifies a function of one argument that is used to extract a comparison - key from each list element: ``key=str.lower`` + key from each list element: ``key=str.lower``. The default value is ``None``. *reverse* is a boolean value. If set to ``True``, then the list elements are sorted as if each comparison were reversed. From python-checkins at python.org Sun Jan 6 16:41:50 2008 From: python-checkins at python.org (georg.brandl) Date: Sun, 6 Jan 2008 16:41:50 +0100 (CET) Subject: [Python-checkins] r59774 - python/trunk/Doc/library/stdtypes.rst Message-ID: <20080106154150.513951E4012@bag.python.org> Author: georg.brandl Date: Sun Jan 6 16:41:50 2008 New Revision: 59774 Modified: python/trunk/Doc/library/stdtypes.rst Log: #1501: document that 0**0 == 1. Modified: python/trunk/Doc/library/stdtypes.rst ============================================================================== --- python/trunk/Doc/library/stdtypes.rst (original) +++ python/trunk/Doc/library/stdtypes.rst Sun Jan 6 16:41:50 2008 @@ -311,9 +311,9 @@ +--------------------+---------------------------------+--------+ | ``divmod(x, y)`` | the pair ``(x // y, x % y)`` | (3)(4) | +--------------------+---------------------------------+--------+ -| ``pow(x, y)`` | *x* to the power *y* | \(3) | +| ``pow(x, y)`` | *x* to the power *y* | (3)(7) | +--------------------+---------------------------------+--------+ -| ``x ** y`` | *x* to the power *y* | | +| ``x ** y`` | *x* to the power *y* | \(7) | +--------------------+---------------------------------+--------+ .. index:: @@ -366,6 +366,10 @@ .. versionadded:: 2.6 +(7) + Python defines ``pow(0, 0)`` and ``0 ** 0`` to be ``1``, as is common for + programming languages. + All :class:`numbers.Real` types (:class:`int`, :class:`long`, and :class:`float`) also include the following operations: From python-checkins at python.org Sun Jan 6 16:48:20 2008 From: python-checkins at python.org (georg.brandl) Date: Sun, 6 Jan 2008 16:48:20 +0100 (CET) Subject: [Python-checkins] r59775 - python/trunk/Doc/library/functions.rst python/trunk/Doc/library/inspect.rst Message-ID: <20080106154820.7CA721E4012@bag.python.org> Author: georg.brandl Date: Sun Jan 6 16:48:20 2008 New Revision: 59775 Modified: python/trunk/Doc/library/functions.rst python/trunk/Doc/library/inspect.rst Log: #759525: document that dir() doesn't return metaclass attrs when given a class as arg. Modified: python/trunk/Doc/library/functions.rst ============================================================================== --- python/trunk/Doc/library/functions.rst (original) +++ python/trunk/Doc/library/functions.rst Sun Jan 6 16:48:20 2008 @@ -302,7 +302,8 @@ Because :func:`dir` is supplied primarily as a convenience for use at an interactive prompt, it tries to supply an interesting set of names more than it tries to supply a rigorously or consistently defined set of names, and its - detailed behavior may change across releases. + detailed behavior may change across releases. For example, metaclass attributes + are not in the result list when the argument is a class. .. function:: divmod(a, b) Modified: python/trunk/Doc/library/inspect.rst ============================================================================== --- python/trunk/Doc/library/inspect.rst (original) +++ python/trunk/Doc/library/inspect.rst Sun Jan 6 16:48:20 2008 @@ -195,6 +195,11 @@ name. If the optional *predicate* argument is supplied, only members for which the predicate returns a true value are included. + .. note:: + + :func:`getmembers` does not return metaclass attributes when the argument + is a class (this behavior is inherited from the :func:`dir` function). + .. function:: getmoduleinfo(path) From python-checkins at python.org Sun Jan 6 16:55:26 2008 From: python-checkins at python.org (georg.brandl) Date: Sun, 6 Jan 2008 16:55:26 +0100 (CET) Subject: [Python-checkins] r59776 - python/trunk/Doc/library/tempfile.rst Message-ID: <20080106155526.E56871E4012@bag.python.org> Author: georg.brandl Date: Sun Jan 6 16:55:26 2008 New Revision: 59776 Modified: python/trunk/Doc/library/tempfile.rst Log: #1615275: clarify return object types of different tempfile factories. Modified: python/trunk/Doc/library/tempfile.rst ============================================================================== --- python/trunk/Doc/library/tempfile.rst (original) +++ python/trunk/Doc/library/tempfile.rst Sun Jan 6 16:55:26 2008 @@ -34,7 +34,7 @@ .. function:: TemporaryFile([mode='w+b'[, bufsize=-1[, suffix[, prefix[, dir]]]]]) - Return a file (or file-like) object that can be used as a temporary storage + Return a file-like object that can be used as a temporary storage area. The file is created using :func:`mkstemp`. It will be destroyed as soon as it is closed (including an implicit close when the object is garbage collected). Under Unix, the directory entry for the file is removed immediately @@ -49,6 +49,10 @@ The *dir*, *prefix* and *suffix* parameters are passed to :func:`mkstemp`. + The returned object is a true file object on POSIX platforms. On other + platforms, it is a file-like object whose :attr:`file` attribute is the + underlying true file object. + .. function:: NamedTemporaryFile([mode='w+b'[, bufsize=-1[, suffix[, prefix[, dir[, delete]]]]]]) @@ -60,6 +64,9 @@ across platforms (it can be so used on Unix; it cannot on Windows NT or later). If *delete* is true (the default), the file is deleted as soon as it is closed. + The returned object is always a file-like object whose :attr:`file` attribute + is the underlying true file object. + .. versionadded:: 2.3 .. versionadded:: 2.6 @@ -76,6 +83,10 @@ The resulting file has one additional method, :func:`rollover`, which causes the file to roll over to an on-disk file regardless of its size. + The returned object is a file-like object whose :attr:`_file` attribute + is either a :class:`StringIO` object or a true file object, depending on + whether :func:`rollover` has been called. + .. versionadded:: 2.6 From python-checkins at python.org Sun Jan 6 17:01:27 2008 From: python-checkins at python.org (georg.brandl) Date: Sun, 6 Jan 2008 17:01:27 +0100 (CET) Subject: [Python-checkins] r59777 - python/trunk/Doc/library/subprocess.rst Message-ID: <20080106160127.0BFEB1E4012@bag.python.org> Author: georg.brandl Date: Sun Jan 6 17:01:26 2008 New Revision: 59777 Modified: python/trunk/Doc/library/subprocess.rst Log: #1727024: document that Popen.returncode is set by Popen.poll/wait. Modified: python/trunk/Doc/library/subprocess.rst ============================================================================== --- python/trunk/Doc/library/subprocess.rst (original) +++ python/trunk/Doc/library/subprocess.rst Sun Jan 6 17:01:26 2008 @@ -178,12 +178,14 @@ .. method:: Popen.poll() - Check if child process has terminated. Returns returncode attribute. + Check if child process has terminated. Set and return :attr:`returncode` + attribute. .. method:: Popen.wait() - Wait for child process to terminate. Returns returncode attribute. + Wait for child process to terminate. Set and return :attr:`returncode` + attribute. .. method:: Popen.communicate(input=None) @@ -193,20 +195,20 @@ *input* argument should be a string to be sent to the child process, or ``None``, if no data should be sent to the child. - communicate() returns a tuple (stdout, stderr). + :meth:`communicate` returns a tuple ``(stdout, stderr)``. Note that if you want to send data to the process's stdin, you need to create the Popen object with ``stdin=PIPE``. Similarly, to get anything other than ``None`` in the result tuple, you need to give ``stdout=PIPE`` and/or ``stderr=PIPE`` too. -.. note:: + .. note:: - The data read is buffered in memory, so do not use this method if the data size - is large or unlimited. + The data read is buffered in memory, so do not use this method if the data + size is large or unlimited. -The following attributes are also available: +The following attributes are also available: .. attribute:: Popen.stdin @@ -233,9 +235,12 @@ .. attribute:: Popen.returncode - The child return code. A ``None`` value indicates that the process hasn't - terminated yet. A negative value -N indicates that the child was terminated by - signal N (Unix only). + The child return code, set by :meth:`poll` and :meth:`wait` (and indirectly + by :meth:`communicate`). A ``None`` value indicates that the process + hasn't terminated yet. + + A negative value ``-N`` indicates that the child was terminated by signal + ``N`` (Unix only). Replacing Older Functions with the subprocess Module From python-checkins at python.org Sun Jan 6 17:04:57 2008 From: python-checkins at python.org (georg.brandl) Date: Sun, 6 Jan 2008 17:04:57 +0100 (CET) Subject: [Python-checkins] r59778 - python/trunk/Doc/library/csv.rst Message-ID: <20080106160457.3F74A1E4012@bag.python.org> Author: georg.brandl Date: Sun Jan 6 17:04:56 2008 New Revision: 59778 Modified: python/trunk/Doc/library/csv.rst Log: #1686390: add example for csv.Sniffer use. Modified: python/trunk/Doc/library/csv.rst ============================================================================== --- python/trunk/Doc/library/csv.rst (original) +++ python/trunk/Doc/library/csv.rst Sun Jan 6 17:04:56 2008 @@ -220,7 +220,6 @@ The :class:`Sniffer` class provides two methods: - .. method:: Sniffer.sniff(sample[, delimiters=None]) Analyze the given *sample* and return a :class:`Dialect` subclass reflecting the @@ -233,9 +232,17 @@ Analyze the sample text (presumed to be in CSV format) and return :const:`True` if the first row appears to be a series of column headers. -The :mod:`csv` module defines the following constants: +An example for :class:`Sniffer` use:: + + csvfile = open("example.csv") + dialect = csv.Sniffer().sniff(csvfile.read(1024)) + csvfile.seek(0) + reader = csv.reader(csvfile, dialect) + # ... process CSV file contents here ... +The :mod:`csv` module defines the following constants: + .. data:: QUOTE_ALL Instructs :class:`writer` objects to quote all fields. From python-checkins at python.org Sun Jan 6 17:12:39 2008 From: python-checkins at python.org (georg.brandl) Date: Sun, 6 Jan 2008 17:12:39 +0100 (CET) Subject: [Python-checkins] r59779 - python/trunk/Doc/library/shutil.rst Message-ID: <20080106161239.AF0161E4012@bag.python.org> Author: georg.brandl Date: Sun Jan 6 17:12:39 2008 New Revision: 59779 Modified: python/trunk/Doc/library/shutil.rst Log: #1559684: document that shutil.copy* doesn't copy all metadata on Posix and Windows too. Modified: python/trunk/Doc/library/shutil.rst ============================================================================== --- python/trunk/Doc/library/shutil.rst (original) +++ python/trunk/Doc/library/shutil.rst Sun Jan 6 17:12:39 2008 @@ -17,16 +17,21 @@ :mod:`os` module. .. warning:: + + Even the higher-level file copying functions (:func:`copy`, :func:`copy2`) + can't copy all file metadata. - On MacOS, the resource fork and other metadata are not used. For file copies, - this means that resources will be lost and file type and creator codes will - not be correct. + On POSIX platforms, this means that file owner and group are lost as well + as ACLs. On MacOS, the resource fork and other metadata are not used. + This means that resources will be lost and file type and creator codes will + not be correct. On Windows, file owners, ACLs and alternate data streams + are not copied. .. function:: copyfile(src, dst) - Copy the contents of the file named *src* to a file named *dst*. The - destination location must be writable; otherwise, an :exc:`IOError` exception + Copy the contents (no metadata) of the file named *src* to a file named *dst*. + The destination location must be writable; otherwise, an :exc:`IOError` exception will be raised. If *dst* already exists, it will be replaced. Special files such as character or block devices and pipes cannot be copied with this function. *src* and *dst* are path names given as strings. @@ -81,7 +86,7 @@ files are copied to the new tree. If exception(s) occur, an :exc:`Error` is raised with a list of reasons. - The source code for this should be considered an example rather than a tool. + The source code for this should be considered an example rather than a tool. .. versionchanged:: 2.3 :exc:`Error` is raised if any exceptions occur during copying, rather than @@ -114,7 +119,7 @@ Recursively move a file or directory to another location. - If the destination is on our current filesystem, then simply use rename. + If the destination is on the current filesystem, then simply use rename. Otherwise, copy src to the dst and then remove src. .. versionadded:: 2.3 @@ -122,7 +127,7 @@ .. exception:: Error - This exception collects exceptions that raised during a mult-file operation. For + This exception collects exceptions that raised during a multi-file operation. For :func:`copytree`, the exception argument is a list of 3-tuples (*srcname*, *dstname*, *exception*). From python-checkins at python.org Sun Jan 6 17:17:57 2008 From: python-checkins at python.org (georg.brandl) Date: Sun, 6 Jan 2008 17:17:57 +0100 (CET) Subject: [Python-checkins] r59780 - in python/trunk/Doc: ACKS.txt library/functions.rst reference/datamodel.rst Message-ID: <20080106161757.1A05C1E4012@bag.python.org> Author: georg.brandl Date: Sun Jan 6 17:17:56 2008 New Revision: 59780 Modified: python/trunk/Doc/ACKS.txt python/trunk/Doc/library/functions.rst python/trunk/Doc/reference/datamodel.rst Log: #1582: document __reversed__, patch by Mark Russell. Modified: python/trunk/Doc/ACKS.txt ============================================================================== --- python/trunk/Doc/ACKS.txt (original) +++ python/trunk/Doc/ACKS.txt Sun Jan 6 17:17:56 2008 @@ -158,6 +158,7 @@ * Jim Roskind * Guido van Rossum * Donald Wallace Rouse II + * Mark Russell * Nick Russo * Chris Ryland * Constantina S. Modified: python/trunk/Doc/library/functions.rst ============================================================================== --- python/trunk/Doc/library/functions.rst (original) +++ python/trunk/Doc/library/functions.rst Sun Jan 6 17:17:56 2008 @@ -977,12 +977,16 @@ .. function:: reversed(seq) - Return a reverse :term:`iterator`. *seq* must be an object which supports - the sequence protocol (the :meth:`__len__` method and the :meth:`__getitem__` - method with integer arguments starting at ``0``). + Return a reverse :term:`iterator`. *seq* must be an object which has + a :meth:`__reversed__` method or supports the sequence protocol (the + :meth:`__len__` method and the :meth:`__getitem__` method with integer + arguments starting at ``0``). .. versionadded:: 2.4 + .. versionchanged:: 2.6 + Added the possibility to write a custom :meth:`__reversed__` method. + .. function:: round(x[, n]) Modified: python/trunk/Doc/reference/datamodel.rst ============================================================================== --- python/trunk/Doc/reference/datamodel.rst (original) +++ python/trunk/Doc/reference/datamodel.rst Sun Jan 6 17:17:56 2008 @@ -1796,6 +1796,22 @@ Iterator objects also need to implement this method; they are required to return themselves. For more information on iterator objects, see :ref:`typeiter`. + +.. method:: object.__reversed__(self) + + Called (if present) by the :func:`reversed` builtin to implement + reverse iteration. It should return a new iterator object that iterates + over all the objects in the container in reverse order. + + If the :meth:`__reversed__` method is not provided, the + :func:`reversed` builtin will fall back to using the sequence protocol + (:meth:`__len__` and :meth:`__getitem__`). Objects should normally + only provide :meth:`__reversed__` if they do not support the sequence + protocol and an efficient implementation of reverse iteration is possible. + + .. versionadded:: 2.6 + + The membership test operators (:keyword:`in` and :keyword:`not in`) are normally implemented as an iteration through a sequence. However, container objects can supply the following special method with a more efficient implementation, which From lists at cheimes.de Sun Jan 6 17:18:10 2008 From: lists at cheimes.de (Christian Heimes) Date: Sun, 06 Jan 2008 17:18:10 +0100 Subject: [Python-checkins] r59731 - in python/trunk: Doc/library/functions.rst Doc/library/math.rst Doc/library/stdtypes.rst Doc/reference/expressions.rst Lib/numbers.py Lib/test/test_builtin.py Lib/test/test_long.py Lib/test/test_math.py Modules/mathmodule.c Objects/floatobject.c Objects/intobject.c Objects/longobject.c Python/bltinmodule.c In-Reply-To: <20080105084714.51AC21E4008@bag.python.org> References: <20080105084714.51AC21E4008@bag.python.org> Message-ID: <4780FF42.2000905@cheimes.de> jeffrey.yasskin wrote: > Author: jeffrey.yasskin > Date: Sat Jan 5 09:47:13 2008 > New Revision: 59731 > > Modified: > python/trunk/Doc/library/functions.rst > python/trunk/Doc/library/math.rst > python/trunk/Doc/library/stdtypes.rst > python/trunk/Doc/reference/expressions.rst > python/trunk/Lib/numbers.py > python/trunk/Lib/test/test_builtin.py > python/trunk/Lib/test/test_long.py > python/trunk/Lib/test/test_math.py > python/trunk/Modules/mathmodule.c > python/trunk/Objects/floatobject.c > python/trunk/Objects/intobject.c > python/trunk/Objects/longobject.c > python/trunk/Python/bltinmodule.c > Log: > Continue rolling back pep-3141 changes that changed behavior from 2.5. This > round included: > * Revert round to its 2.6 behavior (half away from 0). > * Because round, floor, and ceil always return float again, it's no > longer necessary to have them delegate to __xxx___, so I've ripped > that out of their implementations and the Real ABC. This also helps > in implementing types that work in both 2.6 and 3.0: you return int > from the __xxx__ methods, and let it get enabled by the version > upgrade. > * Make pow(-1, .5) raise a ValueError again. I'm merging changes from the trunk to the 3.0 branch. Should I merge any of the changes of this revision to 3.0? I assume I should omit the changes but I'm not 100% sure. Christian From python-checkins at python.org Sun Jan 6 17:22:56 2008 From: python-checkins at python.org (georg.brandl) Date: Sun, 6 Jan 2008 17:22:56 +0100 (CET) Subject: [Python-checkins] r59781 - python/trunk/Doc/library/functions.rst Message-ID: <20080106162256.A00511E4012@bag.python.org> Author: georg.brandl Date: Sun Jan 6 17:22:56 2008 New Revision: 59781 Modified: python/trunk/Doc/library/functions.rst Log: #1499: Document compile() exceptions. Modified: python/trunk/Doc/library/functions.rst ============================================================================== --- python/trunk/Doc/library/functions.rst (original) +++ python/trunk/Doc/library/functions.rst Sun Jan 6 17:22:56 2008 @@ -221,6 +221,9 @@ can be found as the :attr:`compiler_flag` attribute on the :class:`_Feature` instance in the :mod:`__future__` module. + This function raises :exc:`SyntaxError` if the compiled source is invalid, + and :exc:`TypeError` if the source contains null bytes. + .. function:: complex([real[, imag]]) From buildbot at python.org Sun Jan 6 17:37:26 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 06 Jan 2008 16:37:26 +0000 Subject: [Python-checkins] buildbot failure in PPC64 Debian trunk Message-ID: <20080106163726.88CC71E4012@bag.python.org> The Buildbot has detected a new failure of PPC64 Debian trunk. Full details are available at: http://www.python.org/dev/buildbot/all/PPC64%20Debian%20trunk/builds/43 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: georg.brandl BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/SocketServer.py", line 523, in __init__ self.handle() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/BaseHTTPServer.py", line 310, in handle_one_request method() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/SimpleXMLRPCServer.py", line 449, in do_POST self.report_404() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/SimpleXMLRPCServer.py", line 507, in report_404 self.connection.shutdown(1) File "", line 1, in shutdown error: [Errno 107] Transport endpoint is not connected 1 test failed: test_xmlrpc ====================================================================== ERROR: test_fail_no_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/test/test_xmlrpc.py", line 560, in test_fail_no_info p.pow(6,8) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/xmlrpclib.py", line 1157, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/xmlrpclib.py", line 1447, in __request verbose=self.__verbose File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/xmlrpclib.py", line 1195, in request errcode, errmsg, headers = h.getreply() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 1006, in getreply response = self._conn.getresponse() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 932, in getresponse response.begin() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 415, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 271, in readheaders line = self.fp.readline() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/socket.py", line 354, in readline data = recv(1) error: [Errno 104] Connection reset by peer ====================================================================== ERROR: test_fail_with_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/test/test_xmlrpc.py", line 580, in test_fail_with_info p.pow(6,8) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/xmlrpclib.py", line 1157, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/xmlrpclib.py", line 1447, in __request verbose=self.__verbose File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/xmlrpclib.py", line 1195, in request errcode, errmsg, headers = h.getreply() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 1006, in getreply response = self._conn.getresponse() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 932, in getresponse response.begin() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 415, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 271, in readheaders line = self.fp.readline() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/socket.py", line 354, in readline data = recv(1) error: [Errno 104] Connection reset by peer make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Sun Jan 6 17:49:51 2008 From: python-checkins at python.org (georg.brandl) Date: Sun, 6 Jan 2008 17:49:51 +0100 (CET) Subject: [Python-checkins] r59782 - in python/trunk: Doc/library/zipimport.rst Lib/test/test_zipimport.py Message-ID: <20080106164951.228B41E4012@bag.python.org> Author: georg.brandl Date: Sun Jan 6 17:49:50 2008 New Revision: 59782 Modified: python/trunk/Doc/library/zipimport.rst python/trunk/Lib/test/test_zipimport.py Log: #1325: Add docs and tests for zipimporter.archive and zipimporter.prefix. Modified: python/trunk/Doc/library/zipimport.rst ============================================================================== --- python/trunk/Doc/library/zipimport.rst (original) +++ python/trunk/Doc/library/zipimport.rst Sun Jan 6 17:49:50 2008 @@ -33,21 +33,6 @@ loaded from a ZIP archive; it is unlikely that :func:`reload` would be needed, since this would imply that the ZIP has been altered during runtime. -The available attributes of this module are: - - -.. exception:: ZipImportError - - Exception raised by zipimporter objects. It's a subclass of :exc:`ImportError`, - so it can be caught as :exc:`ImportError`, too. - - -.. class:: zipimporter - - The class for importing ZIP files. See section :ref:`zipimporter-objects` - for constructor details. - - .. seealso:: `PKZIP Application Note `_ @@ -63,18 +48,33 @@ The PEP to add the import hooks that help this module work. +This module defines an exception: + +.. exception:: ZipImportError + + Exception raised by zipimporter objects. It's a subclass of :exc:`ImportError`, + so it can be caught as :exc:`ImportError`, too. + + .. _zipimporter-objects: zipimporter Objects ------------------- +:class:`zipimporter` is the class for importing ZIP files. .. class:: zipimporter(archivepath) - Create a new zipimporter instance. *archivepath* must be a path to a zipfile. + Create a new zipimporter instance. *archivepath* must be a path to a ZIP file. :exc:`ZipImportError` is raised if *archivepath* doesn't point to a valid ZIP archive. + *archivepath* can also contain a path within the ZIP file -- the importer + object will then look under that path instead of the ZIP file root. For + example, an *archivepath* of :file:`foo/bar.zip/lib` will look for modules + in the :file:`lib` directory inside the ZIP file :file:`foo/bar.zip` + (provided that it exists). + .. method:: zipimporter.find_module(fullname[, path]) @@ -116,11 +116,22 @@ :exc:`ZipImportError` if it wasn't found. -Examples --------- +.. attribute:: zipimporter.archive + + The file name of the importer's associated ZIP file. + + +.. attribute:: zipimporter.prefix + + The path within the ZIP file where modules are searched; see + :class:`zipimporter` for details. + .. _zipimport-examples: +Examples +-------- + Here is an example that imports a module from a ZIP archive - note that the :mod:`zipimport` module is not explicitly used. :: Modified: python/trunk/Lib/test/test_zipimport.py ============================================================================== --- python/trunk/Lib/test/test_zipimport.py (original) +++ python/trunk/Lib/test/test_zipimport.py Sun Jan 6 17:49:50 2008 @@ -223,6 +223,11 @@ mod = __import__(module_path_to_dotted_name(mod_name)) self.assertEquals(zi.get_source(TESTPACK), None) self.assertEquals(zi.get_source(mod_name), None) + + # test prefix and archivepath members + zi2 = zipimport.zipimporter(TEMP_ZIP + os.sep + TESTPACK) + self.assertEquals(zi2.archive, TEMP_ZIP) + self.assertEquals(zi2.prefix, TESTPACK + os.sep) finally: z.close() os.remove(TEMP_ZIP) From python-checkins at python.org Sun Jan 6 18:21:01 2008 From: python-checkins at python.org (georg.brandl) Date: Sun, 6 Jan 2008 18:21:01 +0100 (CET) Subject: [Python-checkins] r59785 - python/trunk/Doc/library/getopt.rst Message-ID: <20080106172101.08F1A1E4012@bag.python.org> Author: georg.brandl Date: Sun Jan 6 18:21:00 2008 New Revision: 59785 Modified: python/trunk/Doc/library/getopt.rst Log: Fix introductory sentence. Modified: python/trunk/Doc/library/getopt.rst ============================================================================== --- python/trunk/Doc/library/getopt.rst (original) +++ python/trunk/Doc/library/getopt.rst Sun Jan 6 18:21:00 2008 @@ -11,7 +11,7 @@ It supports the same conventions as the Unix :cfunc:`getopt` function (including the special meanings of arguments of the form '``-``' and '``--``'). Long options similar to those supported by GNU software may be used as well via an -optional third argument. This module provides a single function and an +optional third argument. This module provides two functions and an exception: From python-checkins at python.org Sun Jan 6 18:22:26 2008 From: python-checkins at python.org (georg.brandl) Date: Sun, 6 Jan 2008 18:22:26 +0100 (CET) Subject: [Python-checkins] r59786 - doctools/trunk/sphinx/templates/layout.html Message-ID: <20080106172226.6E6801E4012@bag.python.org> Author: georg.brandl Date: Sun Jan 6 18:22:26 2008 New Revision: 59786 Modified: doctools/trunk/sphinx/templates/layout.html Log: Add access keys to navigation; thanks to Marek. Modified: doctools/trunk/sphinx/templates/layout.html ============================================================================== --- doctools/trunk/sphinx/templates/layout.html (original) +++ doctools/trunk/sphinx/templates/layout.html Sun Jan 6 18:22:26 2008 @@ -48,21 +48,21 @@ From python-checkins at python.org Sun Jan 6 18:33:23 2008 From: python-checkins at python.org (georg.brandl) Date: Sun, 6 Jan 2008 18:33:23 +0100 (CET) Subject: [Python-checkins] r59788 - doctools/trunk/sphinx/templates/download.html Message-ID: <20080106173323.7124E1E4012@bag.python.org> Author: georg.brandl Date: Sun Jan 6 18:33:23 2008 New Revision: 59788 Modified: doctools/trunk/sphinx/templates/download.html Log: Remove mention of WinZip. Modified: doctools/trunk/sphinx/templates/download.html ============================================================================== --- doctools/trunk/sphinx/templates/download.html (original) +++ doctools/trunk/sphinx/templates/download.html Sun Jan 6 18:33:23 2008 @@ -24,11 +24,8 @@

Windows users can use the ZIP archives since those are customary on that platform. These are created on Unix using the InfoZIP zip program. They may be -unpacked using the free WiZ tool (from the InfoZIP developers) or the -proprietary WinZip 7.0 tool. Many other -tools for handling ZIP archives are available; any of them should work. WinZip -can also handle the gzipped tar archives if needed, but be careful that the -filenames may be mangled if you download these using a Web browser.

+unpacked using the free WiZ tool (from the InfoZIP developers) or any other +tool for handling ZIP archives; any of them should work.

Note that the .tar.bz2 files are smaller than the other archives; Windows users may want to install the bzip2 tools on their systems as well. Windows @@ -53,4 +50,4 @@

If you have comments or suggestions for the Python documentation, please send email to docs at python.org.

-{% endblock %} \ No newline at end of file +{% endblock %} From buildbot at python.org Sun Jan 6 18:41:16 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 06 Jan 2008 17:41:16 +0000 Subject: [Python-checkins] buildbot failure in sparc solaris10 gcc trunk Message-ID: <20080106174116.EC8971E4019@bag.python.org> The Buildbot has detected a new failure of sparc solaris10 gcc trunk. Full details are available at: http://www.python.org/dev/buildbot/all/sparc%20solaris10%20gcc%20trunk/builds/2558 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-sun Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: georg.brandl BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_urllib2net sincerely, -The Buildbot From buildbot at python.org Sun Jan 6 19:15:09 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 06 Jan 2008 18:15:09 +0000 Subject: [Python-checkins] buildbot failure in hppa Ubuntu trunk Message-ID: <20080106181510.2E3941E4013@bag.python.org> The Buildbot has detected a new failure of hppa Ubuntu trunk. Full details are available at: http://www.python.org/dev/buildbot/all/hppa%20Ubuntu%20trunk/builds/468 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-ubuntu-hppa Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: georg.brandl BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_bsddb3 ====================================================================== ERROR: test00_associateDBError (bsddb.test.test_associate.AssociateErrorTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 104, in setUp self.env.open(homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateBTreeTxnTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateBTreeTxnTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test13_associate_in_transaction (bsddb.test.test_associate.AssociateBTreeTxnTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ShelveAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ShelveAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ShelveAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ThreadedAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ThreadedAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ThreadedAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ThreadedAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ThreadedAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ThreadedAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_EnvRemoveAndRename (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_EnvRemoveAndRename (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Transactions (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_TxnTruncate (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test08_TxnLateUse (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Transactions (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_TxnTruncate (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test08_TxnLateUse (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test09_MultiDB (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test09_MultiDB (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_both (bsddb.test.test_dbobj.dbobjTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbobj.py", line 45, in test01_both self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbobj.py", line 39, in open return apply(self._cobj.open, args, kwargs) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_dbobj_dict_interface (bsddb.test.test_dbobj.dbobjTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbobj.py", line 58, in test02_dbobj_dict_interface self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbobj.py", line 39, in open return apply(self._cobj.open, args, kwargs) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01 (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02 (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03 (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_MultiCondSelect (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_CondObjs (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_CreateOrExtend (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_Delete (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_Modify (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_close_dbenv_before_db (bsddb.test.test_env_close.DBEnvClosedEarlyCrash) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_env_close.py", line 53, in test01_close_dbenv_before_db 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_close_dbenv_delete_db_success (bsddb.test.test_env_close.DBEnvClosedEarlyCrash) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_env_close.py", line 78, in test02_close_dbenv_delete_db_success 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_join (bsddb.test.test_join.JoinTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_join.py", line 57, in setUp self.env.open(homeDir, db.DB_CREATE | db.DB_INIT_MPOOL | db.DB_INIT_LOCK ) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_simple (bsddb.test.test_lock.LockingTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_lock.py", line 38, in setUp db.DB_INIT_LOCK | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_threaded (bsddb.test.test_lock.LockingTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_lock.py", line 38, in setUp db.DB_INIT_LOCK | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_set_timeout (bsddb.test.test_lock.LockingTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_lock.py", line 38, in setUp db.DB_INIT_LOCK | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_db_home (bsddb.test.test_misc.MiscTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_misc.py", line 45, in test02_db_home env.open(self.homeDir, db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_1WriterMultiReaders (bsddb.test.test_thread.BTreeConcurrentDataStore) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_1WriterMultiReaders (bsddb.test.test_thread.HashConcurrentDataStore) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_SimpleLocks (bsddb.test.test_thread.BTreeSimpleThreaded) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_SimpleLocks (bsddb.test.test_thread.HashSimpleThreaded) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.BTreeThreadedTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.HashThreadedTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.BTreeThreadedNoWaitTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.HashThreadedNoWaitTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_cachesize (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_flags (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_get (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_get_dbp (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_get_key (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_range (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_remove (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_stat (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_pget (bsddb.test.test_cursor_pget_bug.pget_bugTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_cursor_pget_bug.py", line 25, in setUp self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Sun Jan 6 19:17:25 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 06 Jan 2008 18:17:25 +0000 Subject: [Python-checkins] buildbot failure in x86 XP-4 3.0 Message-ID: <20080106181726.099E11E4013@bag.python.org> The Buildbot has detected a new failure of x86 XP-4 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20XP-4%203.0/builds/397 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-windows Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\threading.py", line 485, in _bootstrap_inner self.run() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\threading.py", line 445, in run self._target(*self._args, **self._kwargs) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_smtplib.py", line 139, in debugging_server poll_fun(0.01, asyncore.socket_map) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 132, in poll read(obj) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 72, in read obj.handle_error() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 68, in read obj.handle_read_event() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 390, in handle_read_event self.handle_read() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_ssl.py", line 497, in handle_read data = self.recv(1024) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 352, in recv if why[0] in [ECONNRESET, ENOTCONN, ESHUTDOWN]: TypeError: 'error' object is unindexable 7 tests failed: test_anydbm test_bsddb test_bsddb3 test_mailbox test_shelve test_smtplib test_whichdb ====================================================================== ERROR: test_anydbm_access (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 90, in test_anydbm_access self.init_db() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 103, in init_db f = anydbm.open(_fname, 'n') File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_anydbm_creation (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 63, in test_anydbm_creation f = anydbm.open(_fname, 'c') File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_anydbm_keys (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 84, in test_anydbm_keys self.init_db() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 103, in init_db f = anydbm.open(_fname, 'n') File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_anydbm_modification (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 71, in test_anydbm_modification self.init_db() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 103, in init_db f = anydbm.open(_fname, 'n') File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_anydbm_read (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 78, in test_anydbm_read self.init_db() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 103, in init_db f = anydbm.open(_fname, 'n') File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') Traceback (most recent call last): File "../lib/test/regrtest.py", line 596, in runtest_inner indirect_test() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb3.py", line 64, in test_main run_unittest(suite()) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb3.py", line 28, in suite import bsddb.test.test_1413192 File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\test\test_1413192.py", line 38, in context = Context() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\test\test_1413192.py", line 26, in __init__ db.DB_CREATE | db.DB_INIT_TXN | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_flush (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 703, in tearDown self._delete_recursively(self._path) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 47, in _delete_recursively os.remove(target) WindowsError: [Error 32] The process cannot access the file because it is being used by another process: '@test' ====================================================================== ERROR: test_popitem (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 336, in test_popitem self.assertEqual(int(msg.get_payload()), keys.index(key)) ValueError: invalid literal for int() with base 10: 'From: foo 0 F' ====================================================================== ERROR: test_flush (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 703, in tearDown self._delete_recursively(self._path) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 47, in _delete_recursively os.remove(target) WindowsError: [Error 32] The process cannot access the file because it is being used by another process: '@test' ====================================================================== ERROR: test_popitem (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 336, in test_popitem self.assertEqual(int(msg.get_payload()), keys.index(key)) ValueError: invalid literal for int() with base 10: 'From: foo 0 \x01' ====================================================================== ERROR: test_flush (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 926, in tearDown self._delete_recursively(self._path) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 47, in _delete_recursively os.remove(target) WindowsError: [Error 32] The process cannot access the file because it is being used by another process: '@test' ====================================================================== ERROR: test_popitem (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 336, in test_popitem self.assertEqual(int(msg.get_payload()), keys.index(key)) ValueError: invalid literal for int() with base 10: 'From: foo *** EOOH *** From: foo 0 1,, From: foo *** EOOH *** From: foo 1 1,, From: foo *** EOOH *** From: foo 2 1,, From: foo *** EOOH *** From: foo 3 ' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestMaildir) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_add (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 77, in test_add self.assertEqual(self._box.get_string(keys[0]), self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\nF' != 'From: foo\n\n0' ====================================================================== FAIL: test_add_and_close (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 743, in test_add_and_close self.assertEqual(contents, open(self._path, 'r').read()) AssertionError: 'From MAILER-DAEMON Sun Jan 06 18:17:57 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Sun Jan 06 18:17:57 2008\n\nFrom: foo\n\n0\n\nFrom MAILER-DAEMON Sun Jan 06 18:17:57 2008\n\nFrom: foo\n\n1\n\nFrom MAILER-DAEMON Sun Jan 06 18:17:57 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Sun Jan 06 18:17:57 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'From MAILER-DAEMON Sun Jan 06 18:17:57 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Sun Jan 06 18:17:57 2008\n\nFrom: foo\n\n0\n\nFrom MAILER-DAEMON Sun Jan 06 18:17:57 2008\n\nFrom: foo\n\n1\n\nFrom MAILER-DAEMON Sun Jan 06 18:17:57 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Sun Jan 06 18:17:57 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Sun Jan 06 18:17:57 2008\n\nFrom: foo\n\n0\n\nFrom MAILER-DAEMON Sun Jan 06 18:17:57 2008\n\nFrom: foo\n\n1\n\nFrom MAILER-DAEMON Sun Jan 06 18:17:57 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Sun Jan 06 18:17:57 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Sun Jan 06 18:17:57 2008\n\nFrom: foo\n\n1\n\nFrom MAILER-DAEMON Sun Jan 06 18:17:57 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Sun Jan 06 18:17:57 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Sun Jan 06 18:17:57 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Sun Jan 06 18:17:57 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Sun Jan 06 18:17:57 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' ====================================================================== FAIL: test_add_from_string (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 710, in test_add_from_string self.assertEqual(self._box[key].get_from(), 'foo at bar blah') AssertionError: 'foo at bar blah\n' != 'foo at bar blah' ====================================================================== FAIL: test_close (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 389, in test_close self._test_flush_or_close(self._box.close) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 6 != 3 ====================================================================== FAIL: test_delitem (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 87, in test_delitem self._test_remove_or_delitem(self._box.__delitem__) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n1' != 'From: foo\n\n1' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_flush (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 377, in test_flush self._test_flush_or_close(self._box.flush) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 6 != 3 ====================================================================== FAIL: test_get (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 129, in test_get self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_file (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 174, in test_get_file self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\nF' != 'From: foo\n\n0' ====================================================================== FAIL: test_get_message (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 156, in test_get_message self.assertEqual(msg0['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_string (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 164, in test_get_string self.assertEqual(self._box.get_string(key0), self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\nF' != 'From: foo\n\n0' ====================================================================== FAIL: test_getitem (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 144, in test_getitem self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_items (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 207, in test_items self._check_iteration(self._box.items, do_keys=True, do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iter (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 194, in test_iter do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iteritems (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 203, in test_iteritems do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_itervalues (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 189, in test_itervalues do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_open_close_open (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 727, in test_open_close_open self.assertEqual(len(self._box), 3) AssertionError: 6 != 3 ====================================================================== FAIL: test_pop (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 313, in test_pop self.assertEqual(self._box.pop(key0).get_payload(), '0') AssertionError: 'From: foo\n\n0\n\nF' != '0' ====================================================================== FAIL: test_remove (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 83, in test_remove self._test_remove_or_delitem(self._box.remove) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n1' != 'From: foo\n\n1' ====================================================================== FAIL: test_set_item (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 272, in test_set_item self._template % 'original 0') AssertionError: '\nFrom: foo\n\noriginal 0' != 'From: foo\n\noriginal 0' ====================================================================== FAIL: test_update (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 350, in test_update self._template % 'changed 0') AssertionError: '\nFrom: foo\n\nchanged 0\n\nF' != 'From: foo\n\nchanged 0' ====================================================================== FAIL: test_values (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 198, in test_values self._check_iteration(self._box.values, do_keys=False, do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_add (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 77, in test_add self.assertEqual(self._box.get_string(keys[0]), self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\n\x01' != 'From: foo\n\n0' ====================================================================== FAIL: test_add_and_close (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 743, in test_add_and_close self.assertEqual(contents, open(self._path, 'r').read()) AssertionError: '\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 06 18:18:02 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 06 18:18:02 2008\n\nFrom: foo\n\n0\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 06 18:18:02 2008\n\nFrom: foo\n\n1\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 06 18:18:02 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 06 18:18:02 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n' != '\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 06 18:18:02 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 06 18:18:02 2008\n\nFrom: foo\n\n0\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 06 18:18:02 2008\n\nFrom: foo\n\n1\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 06 18:18:02 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 06 18:18:02 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 06 18:18:02 2008\n\nFrom: foo\n\n0\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 06 18:18:02 2008\n\nFrom: foo\n\n1\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 06 18:18:02 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 06 18:18:02 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 06 18:18:02 2008\n\nFrom: foo\n\n1\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 06 18:18:02 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 06 18:18:02 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 06 18:18:02 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 06 18:18:02 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 06 18:18:02 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n' ====================================================================== FAIL: test_add_from_string (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 710, in test_add_from_string self.assertEqual(self._box[key].get_from(), 'foo at bar blah') AssertionError: 'foo at bar blah\n' != 'foo at bar blah' ====================================================================== FAIL: test_close (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 389, in test_close self._test_flush_or_close(self._box.close) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_delitem (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 87, in test_delitem self._test_remove_or_delitem(self._box.__delitem__) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n1\n\n\x01' != 'From: foo\n\n1' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_flush (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 377, in test_flush self._test_flush_or_close(self._box.flush) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_get (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 129, in test_get self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_file (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 174, in test_get_file self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\n\x01' != 'From: foo\n\n0' ====================================================================== FAIL: test_get_message (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 156, in test_get_message self.assertEqual(msg0['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_string (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 164, in test_get_string self.assertEqual(self._box.get_string(key0), self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\n\x01' != 'From: foo\n\n0' ====================================================================== FAIL: test_getitem (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 144, in test_getitem self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_items (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 207, in test_items self._check_iteration(self._box.items, do_keys=True, do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iter (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 194, in test_iter do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iteritems (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 203, in test_iteritems do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_itervalues (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 189, in test_itervalues do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_open_close_open (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 727, in test_open_close_open self.assertEqual(len(self._box), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_pop (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 313, in test_pop self.assertEqual(self._box.pop(key0).get_payload(), '0') AssertionError: 'From: foo\n\n0\n\n\x01' != '0' ====================================================================== FAIL: test_remove (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 83, in test_remove self._test_remove_or_delitem(self._box.remove) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n1\n\n\x01' != 'From: foo\n\n1' ====================================================================== FAIL: test_set_item (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 272, in test_set_item self._template % 'original 0') AssertionError: '\nFrom: foo\n\noriginal 0\n\n\x01' != 'From: foo\n\noriginal 0' ====================================================================== FAIL: test_update (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 350, in test_update self._template % 'changed 0') AssertionError: '\nFrom: foo\n\nchanged 0\n\n\x01' != 'From: foo\n\nchanged 0' ====================================================================== FAIL: test_values (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 198, in test_values self._check_iteration(self._box.values, do_keys=False, do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestMH) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_add (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 77, in test_add self.assertEqual(self._box.get_string(keys[0]), self._template % 0) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n0\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f' != 'From: foo\n\n0' ====================================================================== FAIL: test_close (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 389, in test_close self._test_flush_or_close(self._box.close) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_delitem (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 87, in test_delitem self._test_remove_or_delitem(self._box.__delitem__) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n1\n\n\x1f' != 'From: foo\n\n1' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_flush (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 377, in test_flush self._test_flush_or_close(self._box.flush) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_get (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 129, in test_get self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_file (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 174, in test_get_file self._template % 0) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n0\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f' != 'From: foo\n\n0' ====================================================================== FAIL: test_get_message (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 156, in test_get_message self.assertEqual(msg0['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_string (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 164, in test_get_string self.assertEqual(self._box.get_string(key0), self._template % 0) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n0\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f' != 'From: foo\n\n0' ====================================================================== FAIL: test_getitem (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 144, in test_getitem self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_items (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 207, in test_items self._check_iteration(self._box.items, do_keys=True, do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iter (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 194, in test_iter do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iteritems (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 203, in test_iteritems do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_itervalues (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 189, in test_itervalues do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_pop (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 313, in test_pop self.assertEqual(self._box.pop(key0).get_payload(), '0') AssertionError: 'From: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n0\n\n\x1f\x0c\n\n1,,\n\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n1\n\n\x1f' != '0' ====================================================================== FAIL: test_remove (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 83, in test_remove self._test_remove_or_delitem(self._box.remove) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n1\n\n\x1f' != 'From: foo\n\n1' ====================================================================== FAIL: test_set_item (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 272, in test_set_item self._template % 'original 0') AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\noriginal 0\n\n\x1f' != 'From: foo\n\noriginal 0' ====================================================================== FAIL: test_update (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 350, in test_update self._template % 'changed 0') AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\nchanged 0\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f' != 'From: foo\n\nchanged 0' ====================================================================== FAIL: test_values (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 198, in test_values self._check_iteration(self._box.values, do_keys=False, do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== ERROR: test_bool (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 136, in test_bool self.assert_(not self._empty_mapping()) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_constructor (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 133, in test_constructor self.assertEqual(self._empty_mapping(), self._empty_mapping()) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 270, in test_get d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_items (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 156, in test_items d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keys (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 142, in test_keys d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 162, in test_len d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 293, in test_pop d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 288, in test_popitem d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_read (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 44, in test_read p = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 284, in test_setdefault d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 174, in test_update d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_values (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 150, in test_values d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_write (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 92, in test_write p = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_bool (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 136, in test_bool self.assert_(not self._empty_mapping()) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_constructor (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 133, in test_constructor self.assertEqual(self._empty_mapping(), self._empty_mapping()) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 270, in test_get d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_items (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 156, in test_items d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keys (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 142, in test_keys d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 162, in test_len d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 293, in test_pop d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 288, in test_popitem d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_read (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 44, in test_read p = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 284, in test_setdefault d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 174, in test_update d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_values (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 150, in test_values d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_write (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 92, in test_write p = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_bool (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 136, in test_bool self.assert_(not self._empty_mapping()) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_constructor (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 133, in test_constructor self.assertEqual(self._empty_mapping(), self._empty_mapping()) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 270, in test_get d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_items (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 156, in test_items d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keys (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 142, in test_keys d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 162, in test_len d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 293, in test_pop d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 288, in test_popitem d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_read (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 44, in test_read p = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 284, in test_setdefault d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 174, in test_update d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_values (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 150, in test_values d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_write (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 92, in test_write p = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_ascii_file_shelf (test.test_shelve.TestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 46, in test_ascii_file_shelf s = shelve.open(self.fn, protocol=0) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_binary_file_shelf (test.test_shelve.TestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 54, in test_binary_file_shelf s = shelve.open(self.fn, protocol=1) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_proto2_file_shelf (test.test_shelve.TestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 62, in test_proto2_file_shelf s = shelve.open(self.fn, protocol=2) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_whichdb (test.test_whichdb.WhichDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_whichdb.py", line 32, in test_whichdb f = module.open(_fname, 'c') File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') sincerely, -The Buildbot From buildbot at python.org Sun Jan 6 19:40:48 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 06 Jan 2008 18:40:48 +0000 Subject: [Python-checkins] buildbot failure in ppc Debian unstable 3.0 Message-ID: <20080106184048.4CEAF1E4013@bag.python.org> The Buildbot has detected a new failure of ppc Debian unstable 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/ppc%20Debian%20unstable%203.0/builds/442 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/threading.py", line 485, in _bootstrap_inner self.run() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/threading.py", line 445, in run self._target(*self._args, **self._kwargs) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/bsddb/test/test_thread.py", line 80, in writerThread self._writerThread(*args, **kwargs) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/bsddb/test/test_thread.py", line 254, in _writerThread self.assertEqual(data, self.makeData(key)) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/unittest.py", line 325, in failUnlessEqual raise self.failureException(msg or '%r != %r' % (first, second)) AssertionError: None != b'0095-0095-0095-0095-0095' Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/threading.py", line 485, in _bootstrap_inner self.run() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/threading.py", line 445, in run self._target(*self._args, **self._kwargs) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/bsddb/test/test_thread.py", line 80, in writerThread self._writerThread(*args, **kwargs) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/bsddb/test/test_thread.py", line 269, in _writerThread self.assertEqual(data, self.makeData(key)) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/unittest.py", line 325, in failUnlessEqual raise self.failureException(msg or '%r != %r' % (first, second)) AssertionError: None != b'2000-2000-2000-2000-2000' Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/threading.py", line 485, in _bootstrap_inner self.run() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/threading.py", line 445, in run self._target(*self._args, **self._kwargs) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/bsddb/test/test_thread.py", line 80, in writerThread self._writerThread(*args, **kwargs) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/bsddb/test/test_thread.py", line 269, in _writerThread self.assertEqual(data, self.makeData(key)) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/unittest.py", line 325, in failUnlessEqual raise self.failureException(msg or '%r != %r' % (first, second)) AssertionError: None != b'1000-1000-1000-1000-1000' 1 test failed: test_xmlrpc Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 522, in __init__ self.handle() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/BaseHTTPServer.py", line 330, in handle self.handle_one_request() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/BaseHTTPServer.py", line 324, in handle_one_request method() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SimpleXMLRPCServer.py", line 430, in do_POST self.report_404() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SimpleXMLRPCServer.py", line 489, in report_404 self.connection.shutdown(1) socket.error: [Errno 107] Transport endpoint is not connected ====================================================================== ERROR: test_fail_no_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/test/test_xmlrpc.py", line 497, in test_fail_no_info p.pow(6,8) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1091, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1349, in __request verbose=self.__verbose File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1121, in request resp = http_conn.getresponse() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/httplib.py", line 961, in getresponse response.begin() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/httplib.py", line 425, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/httplib.py", line 267, in readheaders line = str(self.fp.readline(), "iso-8859-1") File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/io.py", line 413, in readline b = self.read(nreadahead()) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/io.py", line 475, in read n = self.readinto(b) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/socket.py", line 217, in readinto return self._sock.recv_into(b) socket.error: [Errno 104] Connection reset by peer ====================================================================== ERROR: test_fail_with_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/test/test_xmlrpc.py", line 515, in test_fail_with_info p.pow(6,8) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1091, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1349, in __request verbose=self.__verbose File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1121, in request resp = http_conn.getresponse() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/httplib.py", line 961, in getresponse response.begin() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/httplib.py", line 425, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/httplib.py", line 267, in readheaders line = str(self.fp.readline(), "iso-8859-1") File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/io.py", line 413, in readline b = self.read(nreadahead()) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/io.py", line 475, in read n = self.readinto(b) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/socket.py", line 217, in readinto return self._sock.recv_into(b) socket.error: [Errno 104] Connection reset by peer make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Sun Jan 6 20:52:45 2008 From: python-checkins at python.org (martin.v.loewis) Date: Sun, 6 Jan 2008 20:52:45 +0100 (CET) Subject: [Python-checkins] r59791 - tracker/instances/python-dev/extensions/local_replace.py Message-ID: <20080106195245.1F5F31E4014@bag.python.org> Author: martin.v.loewis Date: Sun Jan 6 20:52:44 2008 New Revision: 59791 Modified: tracker/instances/python-dev/extensions/local_replace.py Log: Add link to source files. Fixes the rest of #154. Modified: tracker/instances/python-dev/extensions/local_replace.py ============================================================================== --- tracker/instances/python-dev/extensions/local_replace.py (original) +++ tracker/instances/python-dev/extensions/local_replace.py Sun Jan 6 20:52:44 2008 @@ -8,6 +8,8 @@ "\grev\g\g"), (re.compile('(?P\s+)(?Pr|r\s+)(?P\d+)'), "\g\g\g"), + (re.compile('(?P\s+)(?P(Demo|Doc|Grammar|Include|Lib|Mac|Misc|Modules|Parser|PC|PCbuild|Python|RISCOS|Tools)/[-.a-zA-Z0-9]+[a-zA-Z0-9])'), + "\g\g"), ] def localReplace(message): From python-checkins at python.org Sun Jan 6 22:13:12 2008 From: python-checkins at python.org (facundo.batista) Date: Sun, 6 Jan 2008 22:13:12 +0100 (CET) Subject: [Python-checkins] r59792 - python/trunk/Misc/developers.txt Message-ID: <20080106211312.972891E4014@bag.python.org> Author: facundo.batista Date: Sun Jan 6 22:13:12 2008 New Revision: 59792 Modified: python/trunk/Misc/developers.txt Log: Added Mark Dickinson. Modified: python/trunk/Misc/developers.txt ============================================================================== --- python/trunk/Misc/developers.txt (original) +++ python/trunk/Misc/developers.txt Sun Jan 6 22:13:12 2008 @@ -17,6 +17,9 @@ Permissions History ------------------- +- Mark Dickinson was given SVN access on 6 January 2008 by Facundo + Batista for his work on mathemathics and number related issues. + - Amaury Forgeot d'Arc was given SVN access on 9 November 2007 by MvL, for general contributions to Python. From buildbot at python.org Sun Jan 6 22:39:25 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 06 Jan 2008 21:39:25 +0000 Subject: [Python-checkins] buildbot failure in hppa Ubuntu 3.0 Message-ID: <20080106213925.35A431E4014@bag.python.org> The Buildbot has detected a new failure of hppa Ubuntu 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/hppa%20Ubuntu%203.0/builds/424 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-ubuntu-hppa Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: georg.brandl BUILD FAILED: failed test Excerpt from the test logfile: make: *** [buildbottest] Unknown signal 37 sincerely, -The Buildbot From python-checkins at python.org Sun Jan 6 23:05:40 2008 From: python-checkins at python.org (georg.brandl) Date: Sun, 6 Jan 2008 23:05:40 +0100 (CET) Subject: [Python-checkins] r59796 - python/trunk/Doc/tutorial/controlflow.rst python/trunk/Doc/tutorial/introduction.rst Message-ID: <20080106220540.87F441E4022@bag.python.org> Author: georg.brandl Date: Sun Jan 6 23:05:40 2008 New Revision: 59796 Modified: python/trunk/Doc/tutorial/controlflow.rst python/trunk/Doc/tutorial/introduction.rst Log: Add tutorial section about coding style. Modified: python/trunk/Doc/tutorial/controlflow.rst ============================================================================== --- python/trunk/Doc/tutorial/controlflow.rst (original) +++ python/trunk/Doc/tutorial/controlflow.rst Sun Jan 6 23:05:40 2008 @@ -551,10 +551,57 @@ No, really, it doesn't do anything. +.. _tut-codingstyle: + +Intermezzo: Coding Style +======================== + +.. sectionauthor:: Georg Brandl +.. index:: pair: coding; style + +Now that you are about to write longer, more complex pieces of Python, it is a +good time to talk about *coding style*. Most languages can be written (or more +concise, *formatted*) in different styles; some are more readable than others. +Making it easy for others to read your code is always a good idea, and adopting +a nice coding style helps tremendously for that. + +For Python, :pep:`8` has emerged as the style guide that most projects adher to; +it promotes a very readable and eye-pleasing coding style. Every Python +developer should read it at some point; here are the most important points +extracted for you: + +* Use 4-space indentation, and no tabs. + + 4 spaces are a good compromise between small indentation (allows greater + nesting depth) and large indentation (easier to read). Tabs introduce + confusion, and are best left out. + +* Wrap lines so that they don't exceed 79 characters. + + This helps users with small displays and makes it possible to have several + code files side-by-side on larger displays. + +* Use blank lines to separate functions and classes, and larger blocks of + code inside functions. + +* When possible, put comments on a line of their own. + +* Use docstrings. + +* Use spaces around operators and after commas, but not directly inside + bracketing constructs: ``a = f(1, 2) + g(3, 4)``. + +* Name your classes and functions consistently; the convention is to use + ``CamelCase`` for classes and ``lower_case_with_underscores`` for functions + and methods. Always use ``self`` as the name for the first method argument. + +* Don't use fancy encodings if your code is meant to be used in international + environments. Plain ASCII works best in any case. + .. rubric:: Footnotes -.. [#] Actually, *call by object reference* would be a better description, since if a - mutable object is passed, the caller will see any changes the callee makes to it - (items inserted into a list). +.. [#] Actually, *call by object reference* would be a better description, + since if a mutable object is passed, the caller will see any changes the + callee makes to it (items inserted into a list). Modified: python/trunk/Doc/tutorial/introduction.rst ============================================================================== --- python/trunk/Doc/tutorial/introduction.rst (original) +++ python/trunk/Doc/tutorial/introduction.rst Sun Jan 6 23:05:40 2008 @@ -578,8 +578,8 @@ ... # the sum of two elements defines the next ... a, b = 0, 1 >>> while b < 10: - ... print b - ... a, b = b, a+b + ... print b + ... a, b = b, a+b ... 1 1 From python-checkins at python.org Sun Jan 6 23:11:54 2008 From: python-checkins at python.org (raymond.hettinger) Date: Sun, 6 Jan 2008 23:11:54 +0100 (CET) Subject: [Python-checkins] r59797 - python/trunk/Lib/collections.py Message-ID: <20080106221154.8D2231E4014@bag.python.org> Author: raymond.hettinger Date: Sun Jan 6 23:11:54 2008 New Revision: 59797 Modified: python/trunk/Lib/collections.py Log: Speed-up named tuple's _make() constructor. Modified: python/trunk/Lib/collections.py ============================================================================== --- python/trunk/Lib/collections.py (original) +++ python/trunk/Lib/collections.py Sun Jan 6 23:11:54 2008 @@ -65,9 +65,9 @@ def __new__(cls, %(argtxt)s): return tuple.__new__(cls, (%(argtxt)s)) \n @classmethod - def _make(cls, iterable): + def _make(cls, iterable, new=tuple.__new__, len=len): 'Make a new %(typename)s object from a sequence or iterable' - result = tuple.__new__(cls, iterable) + result = new(cls, iterable) if len(result) != %(numfields)d: raise TypeError('Expected %(numfields)d arguments, got %%d' %% len(result)) return result \n From nnorwitz at gmail.com Sun Jan 6 23:34:08 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Sun, 6 Jan 2008 17:34:08 -0500 Subject: [Python-checkins] Python Regression Test Failures refleak (1) Message-ID: <20080106223408.GA18280@python.psfb.org> test_cmd_line leaked [0, -23, 0] references, sum=-23 test_popen2 leaked [0, 26, 0] references, sum=26 test_poplib leaked [-95, 0, 0] references, sum=-95 test_sys leaked [-140, 140, -140] references, sum=-140 test_telnetlib leaked [95, -95, 0] references, sum=0 test_urllib2_localnet leaked [3, 3, 3] references, sum=9 From python-checkins at python.org Sun Jan 6 23:22:23 2008 From: python-checkins at python.org (martin.v.loewis) Date: Sun, 6 Jan 2008 23:22:23 +0100 (CET) Subject: [Python-checkins] r59798 - tracker/instances/python-dev/scripts/remove_py3k Message-ID: <20080106222223.1004F1E4014@bag.python.org> Author: martin.v.loewis Date: Sun Jan 6 23:22:22 2008 New Revision: 59798 Added: tracker/instances/python-dev/scripts/remove_py3k (contents, props changed) Log: Create script to change all py3k keyword occurrences to the Python 3.0 version. Added: tracker/instances/python-dev/scripts/remove_py3k ============================================================================== --- (empty file) +++ tracker/instances/python-dev/scripts/remove_py3k Sun Jan 6 23:22:22 2008 @@ -0,0 +1,24 @@ +# This sample script changes all issues with the +# py3k keyword to using the "Python 3.0" version instead. +import sys +sys.path.insert(1,'/home/roundup/roundup/lib/python2.4/site-packages') +import roundup.instance + +tracker = roundup.instance.open('.') +db = tracker.open('admin') + +py3k = db.keyword.lookup('py3k') +py30 = db.version.lookup('Python 3.1') + +using_py3k = db.issue.find(keywords={py3k:1}) + +for issue in using_py3k: + keywords = db.issue.get(issue, 'keywords') + keywords.remove(py3k) + versions = db.issue.get(issue, 'versions') + versions.append(py30) + + # Use set_inner, so that auditors and reactors don't fire + db.issue.set_inner(issue, keywords=keywords, versions=versions) + +db.commit() From python-checkins at python.org Sun Jan 6 23:28:02 2008 From: python-checkins at python.org (martin.v.loewis) Date: Sun, 6 Jan 2008 23:28:02 +0100 (CET) Subject: [Python-checkins] r59799 - tracker/instances/python-dev/scripts/remove_py3k Message-ID: <20080106222802.26EE51E4014@bag.python.org> Author: martin.v.loewis Date: Sun Jan 6 23:28:01 2008 New Revision: 59799 Modified: tracker/instances/python-dev/scripts/remove_py3k Log: Fix version number. Modified: tracker/instances/python-dev/scripts/remove_py3k ============================================================================== --- tracker/instances/python-dev/scripts/remove_py3k (original) +++ tracker/instances/python-dev/scripts/remove_py3k Sun Jan 6 23:28:01 2008 @@ -8,7 +8,7 @@ db = tracker.open('admin') py3k = db.keyword.lookup('py3k') -py30 = db.version.lookup('Python 3.1') +py30 = db.version.lookup('Python 3.0') using_py3k = db.issue.find(keywords={py3k:1}) From python-checkins at python.org Mon Jan 7 00:03:09 2008 From: python-checkins at python.org (martin.v.loewis) Date: Mon, 7 Jan 2008 00:03:09 +0100 (CET) Subject: [Python-checkins] r59800 - tracker/instances/python-dev/detectors/cia.py Message-ID: <20080106230309.20C031E401D@bag.python.org> Author: martin.v.loewis Date: Mon Jan 7 00:03:08 2008 New Revision: 59800 Modified: tracker/instances/python-dev/detectors/cia.py Log: Change client as proposed by Georg. Modified: tracker/instances/python-dev/detectors/cia.py ============================================================================== --- tracker/instances/python-dev/detectors/cia.py (original) +++ tracker/instances/python-dev/detectors/cia.py Mon Jan 7 00:03:08 2008 @@ -7,7 +7,7 @@ 'name':'Roundup Reactor for CIA', 'revision': "$Revision$"[11:-2], 'project': 'python', - 'module': 'Roundup', + 'branch': 'Roundup', 'urlprefix': 'http://bugs.python.org/issue', } @@ -21,11 +21,13 @@ %(project)s - %(module)s + %(nodeid)s + %(branch)s %(author)s + %(files)s %(log)s %(urlprefix)s%(nodeid)s @@ -42,13 +44,15 @@ return messages = list(messages) - log = '[#%s] ' % nodeid + log = '' for msg in messages: log += db.msg.get(msg, 'content') if len(log) > max_content: log = log[:max_content-4] + ' ...' + log = log.replace('\n', ' ') params = parameters.copy() + params['files'] = db.msg.get(msg, 'title') params['nodeid'] = nodeid params['author'] = db.user.get(db.getuid(), 'username') params['log'] = log From python-checkins at python.org Mon Jan 7 00:05:57 2008 From: python-checkins at python.org (martin.v.loewis) Date: Mon, 7 Jan 2008 00:05:57 +0100 (CET) Subject: [Python-checkins] r59801 - tracker/instances/python-dev/detectors/cia.py Message-ID: <20080106230557.1ED801E4014@bag.python.org> Author: martin.v.loewis Date: Mon Jan 7 00:05:56 2008 New Revision: 59801 Modified: tracker/instances/python-dev/detectors/cia.py Log: Use title from issue. Modified: tracker/instances/python-dev/detectors/cia.py ============================================================================== --- tracker/instances/python-dev/detectors/cia.py (original) +++ tracker/instances/python-dev/detectors/cia.py Mon Jan 7 00:05:56 2008 @@ -52,7 +52,7 @@ log = log.replace('\n', ' ') params = parameters.copy() - params['files'] = db.msg.get(msg, 'title') + params['files'] = db.issue.get(nodeid, 'title') params['nodeid'] = nodeid params['author'] = db.user.get(db.getuid(), 'username') params['log'] = log From python-checkins at python.org Mon Jan 7 00:17:44 2008 From: python-checkins at python.org (martin.v.loewis) Date: Mon, 7 Jan 2008 00:17:44 +0100 (CET) Subject: [Python-checkins] r59802 - tracker/instances/python-dev/detectors/cia.py Message-ID: <20080106231744.4BC501E4014@bag.python.org> Author: martin.v.loewis Date: Mon Jan 7 00:17:44 2008 New Revision: 59802 Modified: tracker/instances/python-dev/detectors/cia.py Log: Fix formatting; include status. Modified: tracker/instances/python-dev/detectors/cia.py ============================================================================== --- tracker/instances/python-dev/detectors/cia.py (original) +++ tracker/instances/python-dev/detectors/cia.py Mon Jan 7 00:17:44 2008 @@ -21,13 +21,13 @@ %(project)s - %(nodeid)s + #%(nodeid)s %(branch)s %(author)s - %(files)s + %(file)s %(log)s %(urlprefix)s%(nodeid)s @@ -44,7 +44,16 @@ return messages = list(messages) - log = '' + oldstatus = oldvalues.get('status') + newstatus = db.issue.get(nodeid, 'status') + if oldstatus != newstatus: + if oldvalues: + status = db.status.get(newstatus, 'name') + else: + status = 'new' + log = '[' + status + '] ' + else: + log = '' for msg in messages: log += db.msg.get(msg, 'content') if len(log) > max_content: @@ -52,14 +61,14 @@ log = log.replace('\n', ' ') params = parameters.copy() - params['files'] = db.issue.get(nodeid, 'title') + params['file'] = db.issue.get(nodeid, 'title') params['nodeid'] = nodeid params['author'] = db.user.get(db.getuid(), 'username') params['log'] = log payload = TEMPLATE % params - try: + try: rpc = xmlrpclib.ServerProxy(server) rpc.hub.deliver(payload) except: @@ -71,4 +80,3 @@ def init(db): db.issue.react('create', sendcia) db.issue.react('set', sendcia) - From python-checkins at python.org Mon Jan 7 00:22:27 2008 From: python-checkins at python.org (georg.brandl) Date: Mon, 7 Jan 2008 00:22:27 +0100 (CET) Subject: [Python-checkins] r59803 - python/trunk/Doc/library/functions.rst Message-ID: <20080106232227.9E3D31E4014@bag.python.org> Author: georg.brandl Date: Mon Jan 7 00:22:27 2008 New Revision: 59803 Modified: python/trunk/Doc/library/functions.rst Log: Remove latex trace. Modified: python/trunk/Doc/library/functions.rst ============================================================================== --- python/trunk/Doc/library/functions.rst (original) +++ python/trunk/Doc/library/functions.rst Mon Jan 7 00:22:27 2008 @@ -1287,7 +1287,7 @@ Formerly, :func:`zip` required at least one argument and ``zip()`` raised a :exc:`TypeError` instead of returning an empty list. -.. % --------------------------------------------------------------------------- +.. --------------------------------------------------------------------------- .. _non-essential-built-in-funcs: From python-checkins at python.org Mon Jan 7 00:36:57 2008 From: python-checkins at python.org (martin.v.loewis) Date: Mon, 7 Jan 2008 00:36:57 +0100 (CET) Subject: [Python-checkins] r59804 - tracker/instances/python-dev/detectors/cia.py Message-ID: <20080106233657.927C81E4026@bag.python.org> Author: martin.v.loewis Date: Mon Jan 7 00:36:57 2008 New Revision: 59804 Modified: tracker/instances/python-dev/detectors/cia.py Log: Fix submission of new issues. Modified: tracker/instances/python-dev/detectors/cia.py ============================================================================== --- tracker/instances/python-dev/detectors/cia.py (original) +++ tracker/instances/python-dev/detectors/cia.py Mon Jan 7 00:36:57 2008 @@ -44,7 +44,10 @@ return messages = list(messages) - oldstatus = oldvalues.get('status') + if oldvalues: + oldstatus = oldvalues['status'] + else: + oldstatus = None newstatus = db.issue.get(nodeid, 'status') if oldstatus != newstatus: if oldvalues: From python-checkins at python.org Mon Jan 7 01:25:38 2008 From: python-checkins at python.org (jeffrey.yasskin) Date: Mon, 7 Jan 2008 01:25:38 +0100 (CET) Subject: [Python-checkins] r59805 - peps/trunk/pep-3141.txt Message-ID: <20080107002538.22BEF1E4016@bag.python.org> Author: jeffrey.yasskin Date: Mon Jan 7 01:25:37 2008 New Revision: 59805 Modified: peps/trunk/pep-3141.txt Log: Update PEP 3141 according to the conclusion of http://mail.python.org/pipermail/python-dev/2008-January/075921.html. Different types may have different rounding behavior, but float will definitely round-to-even. Modified: peps/trunk/pep-3141.txt ============================================================================== --- peps/trunk/pep-3141.txt (original) +++ peps/trunk/pep-3141.txt Mon Jan 7 01:25:37 2008 @@ -205,8 +205,12 @@ def __round__(self, ndigits:Integral=None): """Rounds self to ndigits decimal places, defaulting to 0. - If ndigits is omitted or None, returns an Integral, otherwise - returns a Real. Rounds half toward even. + If ndigits is omitted or None, returns an Integral, + otherwise returns a Real, preferably of the same type as + self. Types may choose which direction to round half. For + example, float rounds half toward even, and Decimal rounds + it according to the current context. + """ raise NotImplementedError @@ -428,9 +432,13 @@ least Integral ``>= x``. 4. ``__round__(self)``, called from ``round(x)``, which returns the - Integral closest to ``x``, rounding half toward even. There is also - a 2-argument version, ``__round__(self, other)``, called from - ``round(x, y)``, which should return a Real. + Integral closest to ``x``, rounding half as the type chooses. + ``float`` will change in 3.0 to round half toward even. There is + also a 2-argument version, ``__round__(self, ndigits)``, called + from ``round(x, ndigits)``, which should return a Real. + +In 2.6, ``math.floor``, ``math.ceil``, and ``round`` will continue to +return floats. Because the ``int()`` conversion implemented by ``float`` (and by ``decimal.Decimal``) is equivalent to but less explicit than From python-checkins at python.org Mon Jan 7 05:24:49 2008 From: python-checkins at python.org (raymond.hettinger) Date: Mon, 7 Jan 2008 05:24:49 +0100 (CET) Subject: [Python-checkins] r59807 - in python/trunk: Doc/library/collections.rst Lib/collections.py Message-ID: <20080107042449.9EF6E1E4024@bag.python.org> Author: raymond.hettinger Date: Mon Jan 7 05:24:49 2008 New Revision: 59807 Modified: python/trunk/Doc/library/collections.rst python/trunk/Lib/collections.py Log: Add subclassing example to docs for named tuples. Modified: python/trunk/Doc/library/collections.rst ============================================================================== --- python/trunk/Doc/library/collections.rst (original) +++ python/trunk/Doc/library/collections.rst Mon Jan 7 05:24:49 2008 @@ -510,15 +510,22 @@ Point(x=11, y=22) Since a named tuple is a regular Python class, it is easy to add or change -functionality. For example, the display format can be changed by overriding -the :meth:`__repr__` method: +functionality with a subclass. Here is how to add a calculated field and +a custom fixed-width print format: :: - >>> Point = namedtuple('Point', 'x y') - >>> Point.__repr__ = lambda self: 'Point(%.3f, %.3f)' % self - >>> Point(x=11, y=22) - Point(11.000, 22.000) + >>> class Point(namedtuple('Point', 'x y')): + @property + def hypot(self): + return (self.x ** 2 + self.y ** 2) ** 0.5 + def __repr__(self): + return 'Point(x=%.3f, y=%.3f, hypot=%.3f)' % (self.x, self.y, self.hypot) + + >>> print Point(3, 4) + Point(x=3.000, y=4.000, hypot=5.000) + >>> Point(2, 5) + Point(x=2.000, y=5.000, hypot=5.385) Default values can be implemented by starting with a prototype instance and customizing it with :meth:`_replace`: Modified: python/trunk/Lib/collections.py ============================================================================== --- python/trunk/Lib/collections.py (original) +++ python/trunk/Lib/collections.py Mon Jan 7 05:24:49 2008 @@ -116,8 +116,15 @@ assert p == loads(dumps(p)) # test and demonstrate ability to override methods - Point.__repr__ = lambda self: 'Point(%.3f, %.3f)' % self - print p + class Point(namedtuple('Point', 'x y')): + @property + def hypot(self): + return (self.x ** 2 + self.y ** 2) ** 0.5 + def __repr__(self): + return 'Point(x=%.3f, y=%.3f, hypot=%.3f)' % (self.x, self.y, self.hypot) + + print Point(3, 4) + print Point(2, 5) import doctest TestResults = namedtuple('TestResults', 'failed attempted') From buildbot at python.org Mon Jan 7 06:20:47 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 07 Jan 2008 05:20:47 +0000 Subject: [Python-checkins] buildbot failure in g4 osx.4 trunk Message-ID: <20080107052047.AAC781E4015@bag.python.org> The Buildbot has detected a new failure of g4 osx.4 trunk. Full details are available at: http://www.python.org/dev/buildbot/all/g4%20osx.4%20trunk/builds/2561 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: psf-g4 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: georg.brandl,raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: 2 tests failed: test_urllib2 test_urllib2net ====================================================================== ERROR: test_trivial (test.test_urllib2.TrivialTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/test/test_urllib2.py", line 19, in test_trivial self.assertRaises(ValueError, urllib2.urlopen, 'bogus url') File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/unittest.py", line 329, in failUnlessRaises callableObj(*args, **kwargs) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 123, in urlopen _opener = build_opener() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 461, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 670, in __init__ proxies = getproxies() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib.py", line 1321, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_file (test.test_urllib2.HandlerTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/test/test_urllib2.py", line 619, in test_file r = h.file_open(Request(url)) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 1204, in file_open return self.open_local_file(req) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 1223, in open_local_file localfile = url2pathname(file) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib.py", line 55, in url2pathname return unquote(pathname) TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_http (test.test_urllib2.HandlerTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/test/test_urllib2.py", line 725, in test_http r.read; r.readline # wrapped MockFile methods AttributeError: addinfourl instance has no attribute 'read' ====================================================================== ERROR: test_build_opener (test.test_urllib2.MiscTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/test/test_urllib2.py", line 1031, in test_build_opener o = build_opener(FooHandler, BarHandler) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 461, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 670, in __init__ proxies = getproxies() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib.py", line 1321, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: testURLread (test.test_urllib2net.URLTimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/test/test_urllib2net.py", line 24, in testURLread f = urllib2.urlopen("http://www.python.org/") File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 123, in urlopen _opener = build_opener() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 461, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 670, in __init__ proxies = getproxies() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib.py", line 1321, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_bad_address (test.test_urllib2net.urlopenNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/test/test_urllib2net.py", line 147, in test_bad_address urllib2.urlopen, "http://www.python.invalid./") File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/unittest.py", line 329, in failUnlessRaises callableObj(*args, **kwargs) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 123, in urlopen _opener = build_opener() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 461, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 670, in __init__ proxies = getproxies() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib.py", line 1321, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_basic (test.test_urllib2net.urlopenNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/test/test_urllib2net.py", line 105, in test_basic open_url = urllib2.urlopen("http://www.python.org/") File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 123, in urlopen _opener = build_opener() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 461, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 670, in __init__ proxies = getproxies() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib.py", line 1321, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_geturl (test.test_urllib2net.urlopenNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/test/test_urllib2net.py", line 129, in test_geturl open_url = urllib2.urlopen(URL) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 123, in urlopen _opener = build_opener() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 461, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 670, in __init__ proxies = getproxies() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib.py", line 1321, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_info (test.test_urllib2net.urlopenNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/test/test_urllib2net.py", line 116, in test_info open_url = urllib2.urlopen("http://www.python.org/") File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 123, in urlopen _opener = build_opener() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 461, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 670, in __init__ proxies = getproxies() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib.py", line 1321, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_file (test.test_urllib2net.OtherNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/test/test_urllib2net.py", line 187, in test_file self._test_urls(urls, self._extra_handlers()) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/test/test_urllib2net.py", line 235, in _test_urls urllib2.install_opener(urllib2.build_opener(*handlers)) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 461, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 670, in __init__ proxies = getproxies() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib.py", line 1321, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_ftp (test.test_urllib2net.OtherNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/test/test_urllib2net.py", line 175, in test_ftp self._test_urls(urls, self._extra_handlers()) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/test/test_urllib2net.py", line 235, in _test_urls urllib2.install_opener(urllib2.build_opener(*handlers)) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 461, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 670, in __init__ proxies = getproxies() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib.py", line 1321, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_http (test.test_urllib2net.OtherNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/test/test_urllib2net.py", line 199, in test_http self._test_urls(urls, self._extra_handlers()) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/test/test_urllib2net.py", line 235, in _test_urls urllib2.install_opener(urllib2.build_opener(*handlers)) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 461, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 670, in __init__ proxies = getproxies() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib.py", line 1321, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_range (test.test_urllib2net.OtherNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/test/test_urllib2net.py", line 160, in test_range result = urllib2.urlopen(req) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 123, in urlopen _opener = build_opener() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 461, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 670, in __init__ proxies = getproxies() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib.py", line 1321, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_close (test.test_urllib2net.CloseSocketTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/test/test_urllib2net.py", line 76, in test_close response = urllib2.urlopen("http://www.python.org/") File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 123, in urlopen _opener = build_opener() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 461, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 670, in __init__ proxies = getproxies() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib.py", line 1321, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_ftp_NoneNodefault (test.test_urllib2net.TimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/test/test_urllib2net.py", line 304, in test_ftp_NoneNodefault u = urllib2.urlopen("ftp://ftp.mirror.nl/pub/mirror/gnu/", timeout=None) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 123, in urlopen _opener = build_opener() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 461, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 670, in __init__ proxies = getproxies() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib.py", line 1321, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_ftp_NoneWithdefault (test.test_urllib2net.TimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/test/test_urllib2net.py", line 298, in test_ftp_NoneWithdefault u = urllib2.urlopen("ftp://ftp.mirror.nl/pub/mirror/gnu/", timeout=None) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 123, in urlopen _opener = build_opener() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 461, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 670, in __init__ proxies = getproxies() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib.py", line 1321, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_ftp_Value (test.test_urllib2net.TimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/test/test_urllib2net.py", line 308, in test_ftp_Value u = urllib2.urlopen("ftp://ftp.mirror.nl/pub/mirror/gnu/", timeout=60) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 123, in urlopen _opener = build_opener() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 461, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 670, in __init__ proxies = getproxies() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib.py", line 1321, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_ftp_basic (test.test_urllib2net.TimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/test/test_urllib2net.py", line 291, in test_ftp_basic u = urllib2.urlopen("ftp://ftp.mirror.nl/pub/mirror/gnu/") File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 123, in urlopen _opener = build_opener() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 461, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 670, in __init__ proxies = getproxies() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib.py", line 1321, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_http_NoneNodefault (test.test_urllib2net.TimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/test/test_urllib2net.py", line 287, in test_http_NoneNodefault u = urllib2.urlopen("http://www.python.org", timeout=None) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 123, in urlopen _opener = build_opener() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 461, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 670, in __init__ proxies = getproxies() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib.py", line 1321, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_http_NoneWithdefault (test.test_urllib2net.TimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/test/test_urllib2net.py", line 277, in test_http_NoneWithdefault u = urllib2.urlopen("http://www.python.org", timeout=None) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 123, in urlopen _opener = build_opener() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 461, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 670, in __init__ proxies = getproxies() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib.py", line 1321, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_http_Value (test.test_urllib2net.TimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/test/test_urllib2net.py", line 283, in test_http_Value u = urllib2.urlopen("http://www.python.org", timeout=120) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 123, in urlopen _opener = build_opener() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 461, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 670, in __init__ proxies = getproxies() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib.py", line 1321, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_http_basic (test.test_urllib2net.TimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/test/test_urllib2net.py", line 270, in test_http_basic u = urllib2.urlopen("http://www.python.org") File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 123, in urlopen _opener = build_opener() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 461, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 670, in __init__ proxies = getproxies() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib.py", line 1321, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Mon Jan 7 06:31:59 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 07 Jan 2008 05:31:59 +0000 Subject: [Python-checkins] buildbot failure in ia64 Ubuntu trunk Message-ID: <20080107053159.A1A2D1E4015@bag.python.org> The Buildbot has detected a new failure of ia64 Ubuntu trunk. Full details are available at: http://www.python.org/dev/buildbot/all/ia64%20Ubuntu%20trunk/builds/1233 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ia64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: georg.brandl,raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ia64/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/home/pybot/buildarea/trunk.klose-debian-ia64/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/home/pybot/buildarea/trunk.klose-debian-ia64/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/home/pybot/buildarea/trunk.klose-debian-ia64/build/Lib/SocketServer.py", line 523, in __init__ self.handle() File "/home/pybot/buildarea/trunk.klose-debian-ia64/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/home/pybot/buildarea/trunk.klose-debian-ia64/build/Lib/BaseHTTPServer.py", line 310, in handle_one_request method() File "/home/pybot/buildarea/trunk.klose-debian-ia64/build/Lib/SimpleXMLRPCServer.py", line 449, in do_POST self.report_404() File "/home/pybot/buildarea/trunk.klose-debian-ia64/build/Lib/SimpleXMLRPCServer.py", line 507, in report_404 self.connection.shutdown(1) File "", line 1, in shutdown error: [Errno 107] Transport endpoint is not connected 1 test failed: test_socket_ssl make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Mon Jan 7 06:33:41 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 07 Jan 2008 05:33:41 +0000 Subject: [Python-checkins] buildbot failure in PPC64 Debian trunk Message-ID: <20080107053341.E728E1E4015@bag.python.org> The Buildbot has detected a new failure of PPC64 Debian trunk. Full details are available at: http://www.python.org/dev/buildbot/all/PPC64%20Debian%20trunk/builds/46 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: georg.brandl,raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/test/test_ssl.py", line 585, in listener s.bind(('127.0.0.1', TESTPORT)) File "", line 1, in bind error: [Errno 98] Address already in use sincerely, -The Buildbot From python-checkins at python.org Mon Jan 7 06:50:35 2008 From: python-checkins at python.org (raymond.hettinger) Date: Mon, 7 Jan 2008 06:50:35 +0100 (CET) Subject: [Python-checkins] r59808 - in python/trunk: Doc/library/collections.rst Lib/collections.py Message-ID: <20080107055035.A8A3E1E4015@bag.python.org> Author: raymond.hettinger Date: Mon Jan 7 06:50:35 2008 New Revision: 59808 Modified: python/trunk/Doc/library/collections.rst python/trunk/Lib/collections.py Log: Cleanup subclassing example to more clearly show fixed-width print format. Modified: python/trunk/Doc/library/collections.rst ============================================================================== --- python/trunk/Doc/library/collections.rst (original) +++ python/trunk/Doc/library/collections.rst Mon Jan 7 06:50:35 2008 @@ -511,7 +511,7 @@ Since a named tuple is a regular Python class, it is easy to add or change functionality with a subclass. Here is how to add a calculated field and -a custom fixed-width print format: +a fixed-width print format: :: @@ -522,10 +522,10 @@ def __repr__(self): return 'Point(x=%.3f, y=%.3f, hypot=%.3f)' % (self.x, self.y, self.hypot) - >>> print Point(3, 4) - Point(x=3.000, y=4.000, hypot=5.000) - >>> Point(2, 5) - Point(x=2.000, y=5.000, hypot=5.385) + >>> print Point(3, 4),'\n', Point(2, 5), '\n', Point(9./7, 6) + Point(x=3.000, y=4.000, hypot=5.000) + Point(x=2.000, y=5.000, hypot=5.385) + Point(x=1.286, y=6.000, hypot=6.136) Default values can be implemented by starting with a prototype instance and customizing it with :meth:`_replace`: Modified: python/trunk/Lib/collections.py ============================================================================== --- python/trunk/Lib/collections.py (original) +++ python/trunk/Lib/collections.py Mon Jan 7 06:50:35 2008 @@ -123,8 +123,7 @@ def __repr__(self): return 'Point(x=%.3f, y=%.3f, hypot=%.3f)' % (self.x, self.y, self.hypot) - print Point(3, 4) - print Point(2, 5) + print Point(3, 4),'\n', Point(2, 5), '\n', Point(9./7, 6) import doctest TestResults = namedtuple('TestResults', 'failed attempted') From python-checkins at python.org Mon Jan 7 07:09:40 2008 From: python-checkins at python.org (jeffrey.yasskin) Date: Mon, 7 Jan 2008 07:09:40 +0100 (CET) Subject: [Python-checkins] r59809 - in python/trunk/Lib: abc.py test/test_abc.py Message-ID: <20080107060940.C3A901E4015@bag.python.org> Author: jeffrey.yasskin Date: Mon Jan 7 07:09:40 2008 New Revision: 59809 Modified: python/trunk/Lib/abc.py python/trunk/Lib/test/test_abc.py Log: Fix issue 1747: allow classic classes to be checked for being subclasses of ABCs. Modified: python/trunk/Lib/abc.py ============================================================================== --- python/trunk/Lib/abc.py (original) +++ python/trunk/Lib/abc.py Mon Jan 7 07:09:40 2008 @@ -188,7 +188,7 @@ cls._abc_negative_cache.add(subclass) return ok # Check if it's a direct subclass - if cls in subclass.__mro__: + if cls in getattr(subclass, '__mro__', ()): cls._abc_cache.add(subclass) return True # Check if it's a subclass of a registered class (recursive) Modified: python/trunk/Lib/test/test_abc.py ============================================================================== --- python/trunk/Lib/test/test_abc.py (original) +++ python/trunk/Lib/test/test_abc.py Mon Jan 7 07:09:40 2008 @@ -8,7 +8,6 @@ from test import test_support import abc -__metaclass__ = type class TestABC(unittest.TestCase): @@ -59,10 +58,18 @@ self.assertEqual(F.__abstractmethods__, set(["bar"])) self.assertRaises(TypeError, F) # because bar is abstract now + def test_subclass_oldstyle_class(self): + class A: + __metaclass__ = abc.ABCMeta + class OldstyleClass: + pass + self.assertFalse(issubclass(OldstyleClass, A)) + self.assertFalse(issubclass(A, OldstyleClass)) + def test_registration_basics(self): class A: __metaclass__ = abc.ABCMeta - class B: + class B(object): pass b = B() self.assertEqual(issubclass(B, A), False) @@ -95,7 +102,7 @@ class A1(A): pass self.assertRaises(RuntimeError, A1.register, A) # cycles not allowed - class B: + class B(object): pass A1.register(B) # ok A1.register(B) # should pass silently @@ -136,7 +143,7 @@ def test_all_new_methods_are_called(self): class A: __metaclass__ = abc.ABCMeta - class B: + class B(object): counter = 0 def __new__(cls): B.counter += 1 From buildbot at python.org Mon Jan 7 07:34:17 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 07 Jan 2008 06:34:17 +0000 Subject: [Python-checkins] buildbot failure in ppc Debian unstable trunk Message-ID: <20080107063417.B4B721E4015@bag.python.org> The Buildbot has detected a new failure of ppc Debian unstable trunk. Full details are available at: http://www.python.org/dev/buildbot/all/ppc%20Debian%20unstable%20trunk/builds/540 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/SocketServer.py", line 523, in __init__ self.handle() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/BaseHTTPServer.py", line 310, in handle_one_request method() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/SimpleXMLRPCServer.py", line 449, in do_POST self.report_404() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/SimpleXMLRPCServer.py", line 507, in report_404 self.connection.shutdown(1) File "", line 1, in shutdown error: [Errno 107] Transport endpoint is not connected 1 test failed: test_xmlrpc make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Mon Jan 7 07:48:40 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 07 Jan 2008 06:48:40 +0000 Subject: [Python-checkins] buildbot failure in x86 FreeBSD trunk Message-ID: <20080107064840.DC2A31E4015@bag.python.org> The Buildbot has detected a new failure of x86 FreeBSD trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20FreeBSD%20trunk/builds/352 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-freebsd Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 523, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 523, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable 1 test failed: test_xmlrpc sincerely, -The Buildbot From python-checkins at python.org Mon Jan 7 10:03:49 2008 From: python-checkins at python.org (raymond.hettinger) Date: Mon, 7 Jan 2008 10:03:49 +0100 (CET) Subject: [Python-checkins] r59810 - in python/trunk: Doc/library/collections.rst Lib/collections.py Message-ID: <20080107090349.9008A1E4016@bag.python.org> Author: raymond.hettinger Date: Mon Jan 7 10:03:49 2008 New Revision: 59810 Modified: python/trunk/Doc/library/collections.rst python/trunk/Lib/collections.py Log: Add another named tuple subclassing example. Modified: python/trunk/Doc/library/collections.rst ============================================================================== --- python/trunk/Doc/library/collections.rst (original) +++ python/trunk/Doc/library/collections.rst Mon Jan 7 10:03:49 2008 @@ -527,6 +527,14 @@ Point(x=2.000, y=5.000, hypot=5.385) Point(x=1.286, y=6.000, hypot=6.136) +Another use for subclassing is to replace performance critcal methods with +faster versions that bypass error-checking and localize variable access: + + >>> class Point(namedtuple('Point', 'x y')): + _make = classmethod(tuple.__new__) + def _replace(self, _map=map, **kwds): + return self._make(_map(kwds.pop, ('x', 'y'), self)) + Default values can be implemented by starting with a prototype instance and customizing it with :meth:`_replace`: Modified: python/trunk/Lib/collections.py ============================================================================== --- python/trunk/Lib/collections.py (original) +++ python/trunk/Lib/collections.py Mon Jan 7 10:03:49 2008 @@ -125,6 +125,14 @@ print Point(3, 4),'\n', Point(2, 5), '\n', Point(9./7, 6) + class Point(namedtuple('Point', 'x y')): + 'Point class with optimized _make() and _replace() without error-checking' + _make = classmethod(tuple.__new__) + def _replace(self, _map=map, **kwds): + return self._make(_map(kwds.pop, ('x', 'y'), self)) + + print Point(11, 22)._replace(x=100) + import doctest TestResults = namedtuple('TestResults', 'failed attempted') print TestResults(*doctest.testmod()) From python-checkins at python.org Mon Jan 7 10:07:39 2008 From: python-checkins at python.org (georg.brandl) Date: Mon, 7 Jan 2008 10:07:39 +0100 (CET) Subject: [Python-checkins] r59811 - python/trunk/Doc/library/stdtypes.rst Message-ID: <20080107090739.3774E1E4015@bag.python.org> Author: georg.brandl Date: Mon Jan 7 10:07:38 2008 New Revision: 59811 Modified: python/trunk/Doc/library/stdtypes.rst Log: Change virtual class name of __iter__ to "object" in order to make it linkable. Modified: python/trunk/Doc/library/stdtypes.rst ============================================================================== --- python/trunk/Doc/library/stdtypes.rst (original) +++ python/trunk/Doc/library/stdtypes.rst Mon Jan 7 10:07:38 2008 @@ -470,7 +470,7 @@ support: -.. method:: container.__iter__() +.. method:: object.__iter__() Return an iterator object. The object is required to support the iterator protocol described below. If a container supports different types of From python-checkins at python.org Mon Jan 7 10:16:08 2008 From: python-checkins at python.org (georg.brandl) Date: Mon, 7 Jan 2008 10:16:08 +0100 (CET) Subject: [Python-checkins] r59813 - python/trunk/Doc/library/stdtypes.rst Message-ID: <20080107091608.C65CB1E401A@bag.python.org> Author: georg.brandl Date: Mon Jan 7 10:16:08 2008 New Revision: 59813 Modified: python/trunk/Doc/library/stdtypes.rst Log: Consistency nit. Modified: python/trunk/Doc/library/stdtypes.rst ============================================================================== --- python/trunk/Doc/library/stdtypes.rst (original) +++ python/trunk/Doc/library/stdtypes.rst Mon Jan 7 10:16:08 2008 @@ -421,9 +421,9 @@ | ``x & y`` | bitwise :dfn:`and` of *x* and | | | | *y* | | +------------+--------------------------------+----------+ -| ``x << n`` | *x* shifted left by *n* bits | (1), (2) | +| ``x << n`` | *x* shifted left by *n* bits | (1)(2) | +------------+--------------------------------+----------+ -| ``x >> n`` | *x* shifted right by *n* bits | (1), (3) | +| ``x >> n`` | *x* shifted right by *n* bits | (1)(3) | +------------+--------------------------------+----------+ | ``~x`` | the bits of *x* inverted | | +------------+--------------------------------+----------+ @@ -585,9 +585,9 @@ +------------------+--------------------------------+----------+ | ``s[i]`` | *i*'th item of *s*, origin 0 | \(3) | +------------------+--------------------------------+----------+ -| ``s[i:j]`` | slice of *s* from *i* to *j* | (3), (4) | +| ``s[i:j]`` | slice of *s* from *i* to *j* | (3)(4) | +------------------+--------------------------------+----------+ -| ``s[i:j:k]`` | slice of *s* from *i* to *j* | (3), (5) | +| ``s[i:j:k]`` | slice of *s* from *i* to *j* | (3)(5) | | | with step *k* | | +------------------+--------------------------------+----------+ | ``len(s)`` | length of *s* | | @@ -1343,7 +1343,7 @@ | ``s.reverse()`` | reverses the items of *s* in | \(7) | | | place | | +------------------------------+--------------------------------+---------------------+ -| ``s.sort([cmp[, key[, | sort the items of *s* in place | (7), (8), (9), (10) | +| ``s.sort([cmp[, key[, | sort the items of *s* in place | (7)(8)(9)(10) | | reverse]]])`` | | | +------------------------------+--------------------------------+---------------------+ From python-checkins at python.org Mon Jan 7 10:18:18 2008 From: python-checkins at python.org (georg.brandl) Date: Mon, 7 Jan 2008 10:18:18 +0100 (CET) Subject: [Python-checkins] r59815 - python/trunk/Doc/library/collections.rst Message-ID: <20080107091818.0B8521E4015@bag.python.org> Author: georg.brandl Date: Mon Jan 7 10:18:17 2008 New Revision: 59815 Modified: python/trunk/Doc/library/collections.rst Log: Clean up markup. Modified: python/trunk/Doc/library/collections.rst ============================================================================== --- python/trunk/Doc/library/collections.rst (original) +++ python/trunk/Doc/library/collections.rst Mon Jan 7 10:18:17 2008 @@ -458,7 +458,7 @@ >>> Point._make(t) Point(x=11, y=22) -.. method:: somenamedtuple._asdict() +.. method:: namedtuple._asdict() Return a new dict which maps field names to their corresponding values: @@ -467,7 +467,7 @@ >>> p._asdict() {'x': 11, 'y': 22} -.. method:: somenamedtuple._replace(kwargs) +.. method:: namedtuple._replace(kwargs) Return a new instance of the named tuple replacing specified fields with new values: @@ -480,7 +480,7 @@ >>> for partnum, record in inventory.items(): ... inventory[partnum] = record._replace(price=newprices[partnum], updated=time.now()) -.. attribute:: somenamedtuple._fields +.. attribute:: namedtuple._fields Tuple of strings listing the field names. This is useful for introspection and for creating new named tuple types from existing named tuples. @@ -511,9 +511,7 @@ Since a named tuple is a regular Python class, it is easy to add or change functionality with a subclass. Here is how to add a calculated field and -a fixed-width print format: - -:: +a fixed-width print format:: >>> class Point(namedtuple('Point', 'x y')): @property @@ -528,7 +526,7 @@ Point(x=1.286, y=6.000, hypot=6.136) Another use for subclassing is to replace performance critcal methods with -faster versions that bypass error-checking and localize variable access: +faster versions that bypass error-checking and localize variable access:: >>> class Point(namedtuple('Point', 'x y')): _make = classmethod(tuple.__new__) From buildbot at python.org Mon Jan 7 10:22:24 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 07 Jan 2008 09:22:24 +0000 Subject: [Python-checkins] buildbot failure in amd64 XP trunk Message-ID: <20080107092224.78AF11E4015@bag.python.org> The Buildbot has detected a new failure of amd64 XP trunk. Full details are available at: http://www.python.org/dev/buildbot/all/amd64%20XP%20trunk/builds/521 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: heller-windows-amd64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: georg.brandl,raymond.hettinger BUILD FAILED: failed compile sincerely, -The Buildbot From python at rcn.com Mon Jan 7 10:40:53 2008 From: python at rcn.com (Raymond Hettinger) Date: Mon, 7 Jan 2008 01:40:53 -0800 Subject: [Python-checkins] r59815 - python/trunk/Doc/library/collections.rst References: <20080107091818.0B8521E4015@bag.python.org> Message-ID: <012901c85111$65bb3280$6800a8c0@RaymondLaptop1> Please revert the part with "somenamedtuple". That was not a typo, it is distinct from namedtuple() which is a factory function which returns a new class. The moniker, somenamedtuple refers to a instance of that created class. ----- Original Message ----- From: "georg.brandl" To: Sent: Monday, January 07, 2008 1:18 AM Subject: [Python-checkins] r59815 - python/trunk/Doc/library/collections.rst > Author: georg.brandl > Date: Mon Jan 7 10:18:17 2008 > New Revision: 59815 > > Modified: > python/trunk/Doc/library/collections.rst > Log: > Clean up markup. > > > Modified: python/trunk/Doc/library/collections.rst > ============================================================================== > --- python/trunk/Doc/library/collections.rst (original) > +++ python/trunk/Doc/library/collections.rst Mon Jan 7 10:18:17 2008 > @@ -458,7 +458,7 @@ > >>> Point._make(t) > Point(x=11, y=22) > > -.. method:: somenamedtuple._asdict() > +.. method:: namedtuple._asdict() > > Return a new dict which maps field names to their corresponding values: > > @@ -467,7 +467,7 @@ > >>> p._asdict() > {'x': 11, 'y': 22} > > -.. method:: somenamedtuple._replace(kwargs) > +.. method:: namedtuple._replace(kwargs) > > Return a new instance of the named tuple replacing specified fields with new values: > > @@ -480,7 +480,7 @@ > >>> for partnum, record in inventory.items(): > ... inventory[partnum] = record._replace(price=newprices[partnum], updated=time.now()) > > -.. attribute:: somenamedtuple._fields > +.. attribute:: namedtuple._fields > > Tuple of strings listing the field names. This is useful for introspection > and for creating new named tuple types from existing named tuples. > @@ -511,9 +511,7 @@ > > Since a named tuple is a regular Python class, it is easy to add or change > functionality with a subclass. Here is how to add a calculated field and > -a fixed-width print format: > - > -:: > +a fixed-width print format:: > > >>> class Point(namedtuple('Point', 'x y')): > @property > @@ -528,7 +526,7 @@ > Point(x=1.286, y=6.000, hypot=6.136) > > Another use for subclassing is to replace performance critcal methods with > -faster versions that bypass error-checking and localize variable access: > +faster versions that bypass error-checking and localize variable access:: > > >>> class Point(namedtuple('Point', 'x y')): > _make = classmethod(tuple.__new__) > _______________________________________________ > Python-checkins mailing list > Python-checkins at python.org > http://mail.python.org/mailman/listinfo/python-checkins From buildbot at python.org Mon Jan 7 11:08:44 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 07 Jan 2008 10:08:44 +0000 Subject: [Python-checkins] buildbot failure in ia64 Ubuntu trunk Message-ID: <20080107100844.51F051E4015@bag.python.org> The Buildbot has detected a new failure of ia64 Ubuntu trunk. Full details are available at: http://www.python.org/dev/buildbot/all/ia64%20Ubuntu%20trunk/builds/1236 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ia64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: georg.brandl,raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_socket_ssl make: *** [buildbottest] Error 1 sincerely, -The Buildbot From nnorwitz at gmail.com Mon Jan 7 11:38:17 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Mon, 7 Jan 2008 05:38:17 -0500 Subject: [Python-checkins] Python Regression Test Failures refleak (2) Message-ID: <20080107103817.GA20694@python.psfb.org> test_cmd_line leaked [23, 0, 0] references, sum=23 test_ftplib leaked [-95, 0, 0] references, sum=-95 test_popen2 leaked [52, -26, 0] references, sum=26 test_poplib leaked [-95, 0, 94] references, sum=-1 test_urllib2_localnet leaked [3, 3, 3] references, sum=9 From buildbot at python.org Mon Jan 7 11:30:02 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 07 Jan 2008 10:30:02 +0000 Subject: [Python-checkins] buildbot failure in hppa Ubuntu trunk Message-ID: <20080107103002.C9D911E4015@bag.python.org> The Buildbot has detected a new failure of hppa Ubuntu trunk. Full details are available at: http://www.python.org/dev/buildbot/all/hppa%20Ubuntu%20trunk/builds/473 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-ubuntu-hppa Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: georg.brandl,raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_bsddb3 ====================================================================== ERROR: test00_associateDBError (bsddb.test.test_associate.AssociateErrorTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 104, in setUp self.env.open(homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateBTreeTxnTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateBTreeTxnTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test13_associate_in_transaction (bsddb.test.test_associate.AssociateBTreeTxnTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ShelveAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ShelveAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ShelveAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ThreadedAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ThreadedAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ThreadedAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ThreadedAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ThreadedAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ThreadedAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_EnvRemoveAndRename (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_EnvRemoveAndRename (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Transactions (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_TxnTruncate (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test08_TxnLateUse (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Transactions (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_TxnTruncate (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test08_TxnLateUse (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test09_MultiDB (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test09_MultiDB (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_both (bsddb.test.test_dbobj.dbobjTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbobj.py", line 45, in test01_both self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbobj.py", line 39, in open return apply(self._cobj.open, args, kwargs) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_dbobj_dict_interface (bsddb.test.test_dbobj.dbobjTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbobj.py", line 58, in test02_dbobj_dict_interface self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbobj.py", line 39, in open return apply(self._cobj.open, args, kwargs) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01 (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02 (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03 (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_MultiCondSelect (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_CondObjs (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_CreateOrExtend (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_Delete (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_Modify (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_close_dbenv_before_db (bsddb.test.test_env_close.DBEnvClosedEarlyCrash) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_env_close.py", line 53, in test01_close_dbenv_before_db 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_close_dbenv_delete_db_success (bsddb.test.test_env_close.DBEnvClosedEarlyCrash) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_env_close.py", line 78, in test02_close_dbenv_delete_db_success 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_join (bsddb.test.test_join.JoinTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_join.py", line 57, in setUp self.env.open(homeDir, db.DB_CREATE | db.DB_INIT_MPOOL | db.DB_INIT_LOCK ) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_simple (bsddb.test.test_lock.LockingTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_lock.py", line 38, in setUp db.DB_INIT_LOCK | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_threaded (bsddb.test.test_lock.LockingTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_lock.py", line 38, in setUp db.DB_INIT_LOCK | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_set_timeout (bsddb.test.test_lock.LockingTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_lock.py", line 38, in setUp db.DB_INIT_LOCK | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_db_home (bsddb.test.test_misc.MiscTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_misc.py", line 45, in test02_db_home env.open(self.homeDir, db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_1WriterMultiReaders (bsddb.test.test_thread.BTreeConcurrentDataStore) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_1WriterMultiReaders (bsddb.test.test_thread.HashConcurrentDataStore) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_SimpleLocks (bsddb.test.test_thread.BTreeSimpleThreaded) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_SimpleLocks (bsddb.test.test_thread.HashSimpleThreaded) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.BTreeThreadedTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.HashThreadedTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.BTreeThreadedNoWaitTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.HashThreadedNoWaitTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_cachesize (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_flags (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_get (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_get_dbp (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_get_key (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_range (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_remove (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_stat (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_pget (bsddb.test.test_cursor_pget_bug.pget_bugTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_cursor_pget_bug.py", line 25, in setUp self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Mon Jan 7 16:30:36 2008 From: python-checkins at python.org (vinay.sajip) Date: Mon, 7 Jan 2008 16:30:36 +0100 (CET) Subject: [Python-checkins] r59818 - python/trunk/Doc/library/logging.rst Message-ID: <20080107153036.8B8C51E4002@bag.python.org> Author: vinay.sajip Date: Mon Jan 7 16:30:36 2008 New Revision: 59818 Modified: python/trunk/Doc/library/logging.rst Log: Updated docs for basicConfig to indicate it's a no-op if handlers have been defined for the root logger. Modified: python/trunk/Doc/library/logging.rst ============================================================================== --- python/trunk/Doc/library/logging.rst (original) +++ python/trunk/Doc/library/logging.rst Mon Jan 7 16:30:36 2008 @@ -693,7 +693,8 @@ Does basic configuration for the logging system by creating a :class:`StreamHandler` with a default :class:`Formatter` and adding it to the - root logger. The functions :func:`debug`, :func:`info`, :func:`warning`, + root logger. The function does nothing if any handlers have been defined for + the root logger. The functions :func:`debug`, :func:`info`, :func:`warning`, :func:`error` and :func:`critical` will call :func:`basicConfig` automatically if no handlers are defined for the root logger. @@ -2414,24 +2415,24 @@ The output looks like this:: - 2005-03-23 23:47:11,663 - spam_application - INFO - + 2005-03-23 23:47:11,663 - spam_application - INFO - creating an instance of auxiliary_module.Auxiliary - 2005-03-23 23:47:11,665 - spam_application.auxiliary.Auxiliary - INFO - + 2005-03-23 23:47:11,665 - spam_application.auxiliary.Auxiliary - INFO - creating an instance of Auxiliary - 2005-03-23 23:47:11,665 - spam_application - INFO - + 2005-03-23 23:47:11,665 - spam_application - INFO - created an instance of auxiliary_module.Auxiliary - 2005-03-23 23:47:11,668 - spam_application - INFO - + 2005-03-23 23:47:11,668 - spam_application - INFO - calling auxiliary_module.Auxiliary.do_something - 2005-03-23 23:47:11,668 - spam_application.auxiliary.Auxiliary - INFO - + 2005-03-23 23:47:11,668 - spam_application.auxiliary.Auxiliary - INFO - doing something - 2005-03-23 23:47:11,669 - spam_application.auxiliary.Auxiliary - INFO - + 2005-03-23 23:47:11,669 - spam_application.auxiliary.Auxiliary - INFO - done doing something - 2005-03-23 23:47:11,670 - spam_application - INFO - + 2005-03-23 23:47:11,670 - spam_application - INFO - finished auxiliary_module.Auxiliary.do_something - 2005-03-23 23:47:11,671 - spam_application - INFO - + 2005-03-23 23:47:11,671 - spam_application - INFO - calling auxiliary_module.some_function() - 2005-03-23 23:47:11,672 - spam_application.auxiliary - INFO - + 2005-03-23 23:47:11,672 - spam_application.auxiliary - INFO - received a call to "some_function" - 2005-03-23 23:47:11,673 - spam_application - INFO - + 2005-03-23 23:47:11,673 - spam_application - INFO - done with auxiliary_module.some_function() From python-checkins at python.org Mon Jan 7 17:12:45 2008 From: python-checkins at python.org (christian.heimes) Date: Mon, 7 Jan 2008 17:12:45 +0100 (CET) Subject: [Python-checkins] r59819 - in python/trunk: Doc/library/socket.rst Lib/test/test_socket.py Misc/NEWS Modules/socketmodule.c Modules/socketmodule.h configure configure.in pyconfig.h.in Message-ID: <20080107161245.0CCFF1E4002@bag.python.org> Author: christian.heimes Date: Mon Jan 7 17:12:44 2008 New Revision: 59819 Modified: python/trunk/Doc/library/socket.rst python/trunk/Lib/test/test_socket.py python/trunk/Misc/NEWS python/trunk/Modules/socketmodule.c python/trunk/Modules/socketmodule.h python/trunk/configure python/trunk/configure.in python/trunk/pyconfig.h.in Log: Issue #1646: Make socket support TIPC. The socket module now has support for TIPC under Linux, see http://tipc.sf.net/ for more information. Thanks to Alberto Bertogli for the patch Modified: python/trunk/Doc/library/socket.rst ============================================================================== --- python/trunk/Doc/library/socket.rst (original) +++ python/trunk/Doc/library/socket.rst Mon Jan 7 17:12:44 2008 @@ -66,6 +66,27 @@ .. versionadded:: 2.5 AF_NETLINK sockets are represented as pairs ``pid, groups``. +.. versionadded:: 2.6 + Linux-only support for TIPC is also available using the :const:`AF_TIPC` + address family. TIPC is an open, non-IP based networked protocol designed + for use in clustered computer environments. Addresses are represented by a + tuple, and the fields depend on the address type. The general tuple form is + ``(addr_type, v1, v2, v3 [, scope])``, where: + + - *addr_type* is one of TIPC_ADDR_NAMESEQ, TIPC_ADDR_NAME, or + TIPC_ADDR_ID. + - *scope* is one of TIPC_ZONE_SCOPE, TIPC_CLUSTER_SCOPE, and + TIPC_NODE_SCOPE. + - If *addr_type* is TIPC_ADDR_NAME, then *v1* is the server type, *v2* is + the port identifier, and *v3* should be 0. + + If *addr_type* is TIPC_ADDR_NAMESEQ, then *v1* is the server type, *v2* + is the lower port number, and *v3* is the upper port number. + + If *addr_type* is TIPC_ADDR_ID, then *v1* is the node, *v2* is the + reference, and *v3* should be set to 0. + + All errors raise exceptions. The normal exceptions for invalid argument types and out-of-memory conditions can be raised; errors related to socket or address semantics raise the error :exc:`socket.error`. @@ -169,6 +190,12 @@ .. versionadded:: 2.6 +.. data:: TIPC_* + + TIPC related constants, matching the ones exported by the C socket API. See + the TIPC documentation for more information. + + .. versionadded:: 2.6 .. data:: has_ipv6 Modified: python/trunk/Lib/test/test_socket.py ============================================================================== --- python/trunk/Lib/test/test_socket.py (original) +++ python/trunk/Lib/test/test_socket.py Mon Jan 7 17:12:44 2008 @@ -1084,6 +1084,85 @@ buf = buffer(MSG) self.serv_conn.send(buf) + +TIPC_STYPE = 2000 +TIPC_LOWER = 200 +TIPC_UPPER = 210 + +def isTipcAvailable(): + """Check if the TIPC module is loaded + + The TIPC module is not loaded automatically on Ubuntu and probably + other Linux distros. + """ + if not hasattr(socket, "AF_TIPC"): + return False + if not os.path.isfile("/proc/modules"): + return False + with open("/proc/modules") as f: + for line in f: + if line.startswith("tipc "): + return True + if test_support.debug: + print "TIPC module is not loaded, please 'sudo modprobe tipc'" + return False + +class TIPCTest (unittest.TestCase): + def testRDM(self): + srv = socket.socket(socket.AF_TIPC, socket.SOCK_RDM) + cli = socket.socket(socket.AF_TIPC, socket.SOCK_RDM) + + srv.setsockopt(socket.SOL_SOCKET, socket.SO_REUSEADDR, 1) + srvaddr = (socket.TIPC_ADDR_NAMESEQ, TIPC_STYPE, + TIPC_LOWER, TIPC_UPPER) + srv.bind(srvaddr) + + sendaddr = (socket.TIPC_ADDR_NAME, TIPC_STYPE, + TIPC_LOWER + (TIPC_UPPER - TIPC_LOWER) / 2, 0) + cli.sendto(MSG, sendaddr) + + msg, recvaddr = srv.recvfrom(1024) + + self.assertEqual(cli.getsockname(), recvaddr) + self.assertEqual(msg, MSG) + + +class TIPCThreadableTest (unittest.TestCase, ThreadableTest): + def __init__(self, methodName = 'runTest'): + unittest.TestCase.__init__(self, methodName = methodName) + ThreadableTest.__init__(self) + + def setUp(self): + self.srv = socket.socket(socket.AF_TIPC, socket.SOCK_STREAM) + self.srv.setsockopt(socket.SOL_SOCKET, socket.SO_REUSEADDR, 1) + srvaddr = (socket.TIPC_ADDR_NAMESEQ, TIPC_STYPE, + TIPC_LOWER, TIPC_UPPER) + self.srv.bind(srvaddr) + self.srv.listen(5) + self.serverExplicitReady() + self.conn, self.connaddr = self.srv.accept() + + def clientSetUp(self): + # The is a hittable race between serverExplicitReady() and the + # accept() call; sleep a little while to avoid it, otherwise + # we could get an exception + time.sleep(0.1) + self.cli = socket.socket(socket.AF_TIPC, socket.SOCK_STREAM) + addr = (socket.TIPC_ADDR_NAME, TIPC_STYPE, + TIPC_LOWER + (TIPC_UPPER - TIPC_LOWER) / 2, 0) + self.cli.connect(addr) + self.cliaddr = self.cli.getsockname() + + def testStream(self): + msg = self.conn.recv(1024) + self.assertEqual(msg, MSG) + self.assertEqual(self.cliaddr, self.connaddr) + + def _testStream(self): + self.cli.send(MSG) + self.cli.close() + + def test_main(): tests = [GeneralModuleTests, BasicTCPTest, TCPCloserTest, TCPTimeoutTest, TestExceptions, BufferIOTest, BasicTCPTest2] @@ -1105,6 +1184,9 @@ tests.append(BasicSocketPairTest) if sys.platform == 'linux2': tests.append(TestLinuxAbstractNamespace) + if isTipcAvailable(): + tests.append(TIPCTest) + tests.append(TIPCThreadableTest) thread_info = test_support.threading_setup() test_support.run_unittest(*tests) Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Mon Jan 7 17:12:44 2008 @@ -342,6 +342,8 @@ Library ------- +- Issue #1646: Make socket support the TIPC protocol. + - Bug #1742: return os.curdir from os.path.relpath() if both arguments are equal instead of raising an exception. @@ -927,6 +929,9 @@ Extension Modules ----------------- +- Issue #1646: Make socket support TIPC. The socket module now has support + for TIPC under Linux, see http://tipc.sf.net/ for more information. + - Added interface for Windows' WSAIoctl to socket object and added an example for a simple network sniffer. Modified: python/trunk/Modules/socketmodule.c ============================================================================== --- python/trunk/Modules/socketmodule.c (original) +++ python/trunk/Modules/socketmodule.c Mon Jan 7 17:12:44 2008 @@ -7,7 +7,8 @@ Limitations: - Only AF_INET, AF_INET6 and AF_UNIX address families are supported in a - portable manner, though AF_PACKET and AF_NETLINK are supported under Linux. + portable manner, though AF_PACKET, AF_NETLINK and AF_TIPC are supported + under Linux. - No read/write operations (use sendall/recv or makefile instead). - Additional restrictions apply on some non-Unix platforms (compensated for by socket.py). @@ -52,6 +53,25 @@ the Ethernet protocol number to be received. For example: ("eth0",0x1234). Optional 3rd,4th,5th elements in the tuple specify packet-type and ha-type/addr. +- an AF_TIPC socket address is expressed as + (addr_type, v1, v2, v3 [, scope]); where addr_type can be one of: + TIPC_ADDR_NAMESEQ, TIPC_ADDR_NAME, and TIPC_ADDR_ID; + and scope can be one of: + TIPC_ZONE_SCOPE, TIPC_CLUSTER_SCOPE, and TIPC_NODE_SCOPE. + The meaning of v1, v2 and v3 depends on the value of addr_type: + if addr_type is TIPC_ADDR_NAME: + v1 is the server type + v2 is the port identifier + v3 is ignored + if addr_type is TIPC_ADDR_NAMESEQ: + v1 is the server type + v2 is the lower port number + v3 is the upper port number + if addr_type is TIPC_ADDR_ID: + v1 is the node + v2 is the ref + v3 is ignored + Local naming conventions: @@ -1094,6 +1114,39 @@ } #endif +#ifdef HAVE_LINUX_TIPC_H + case AF_TIPC: + { + struct sockaddr_tipc *a = (struct sockaddr_tipc *) addr; + if (a->addrtype == TIPC_ADDR_NAMESEQ) { + return Py_BuildValue("IIIII", + a->addrtype, + a->addr.nameseq.type, + a->addr.nameseq.lower, + a->addr.nameseq.upper, + a->scope); + } else if (a->addrtype == TIPC_ADDR_NAME) { + return Py_BuildValue("IIIII", + a->addrtype, + a->addr.name.name.type, + a->addr.name.name.instance, + a->addr.name.name.instance, + a->scope); + } else if (a->addrtype == TIPC_ADDR_ID) { + return Py_BuildValue("IIIII", + a->addrtype, + a->addr.id.node, + a->addr.id.ref, + 0, + a->scope); + } else { + PyErr_SetString(PyExc_TypeError, + "Invalid address type"); + return NULL; + } + } +#endif + /* More cases here... */ default: @@ -1379,6 +1432,56 @@ } #endif +#ifdef HAVE_LINUX_TIPC_H + case AF_TIPC: + { + unsigned int atype, v1, v2, v3; + unsigned int scope = TIPC_CLUSTER_SCOPE; + struct sockaddr_tipc *addr; + + if (!PyTuple_Check(args)) { + PyErr_Format( + PyExc_TypeError, + "getsockaddrarg: " + "AF_TIPC address must be tuple, not %.500s", + Py_TYPE(args)->tp_name); + return 0; + } + + if (!PyArg_ParseTuple(args, + "IIII|I;Invalid TIPC address format", + &atype, &v1, &v2, &v3, &scope)) + return 0; + + addr = (struct sockaddr_tipc *) addr_ret; + memset(addr, 0, sizeof(struct sockaddr_tipc)); + + addr->family = AF_TIPC; + addr->scope = scope; + addr->addrtype = atype; + + if (atype == TIPC_ADDR_NAMESEQ) { + addr->addr.nameseq.type = v1; + addr->addr.nameseq.lower = v2; + addr->addr.nameseq.upper = v3; + } else if (atype == TIPC_ADDR_NAME) { + addr->addr.name.name.type = v1; + addr->addr.name.name.instance = v2; + } else if (atype == TIPC_ADDR_ID) { + addr->addr.id.node = v1; + addr->addr.id.ref = v2; + } else { + /* Shouldn't happen */ + PyErr_SetString(PyExc_TypeError, "Invalid address type"); + return 0; + } + + *len_ret = sizeof(*addr); + + return 1; + } +#endif + /* More cases here... */ default: @@ -1464,6 +1567,14 @@ } #endif +#ifdef HAVE_LINUX_TIPC_H + case AF_TIPC: + { + *len_ret = sizeof (struct sockaddr_tipc); + return 1; + } +#endif + /* More cases here... */ default: @@ -4448,6 +4559,47 @@ PyModule_AddIntConstant(m, "PACKET_FASTROUTE", PACKET_FASTROUTE); #endif +#ifdef HAVE_LINUX_TIPC_H + PyModule_AddIntConstant(m, "AF_TIPC", AF_TIPC); + + /* for addresses */ + PyModule_AddIntConstant(m, "TIPC_ADDR_NAMESEQ", TIPC_ADDR_NAMESEQ); + PyModule_AddIntConstant(m, "TIPC_ADDR_NAME", TIPC_ADDR_NAME); + PyModule_AddIntConstant(m, "TIPC_ADDR_ID", TIPC_ADDR_ID); + + PyModule_AddIntConstant(m, "TIPC_ZONE_SCOPE", TIPC_ZONE_SCOPE); + PyModule_AddIntConstant(m, "TIPC_CLUSTER_SCOPE", TIPC_CLUSTER_SCOPE); + PyModule_AddIntConstant(m, "TIPC_NODE_SCOPE", TIPC_NODE_SCOPE); + + /* for setsockopt() */ + PyModule_AddIntConstant(m, "SOL_TIPC", SOL_TIPC); + PyModule_AddIntConstant(m, "TIPC_IMPORTANCE", TIPC_IMPORTANCE); + PyModule_AddIntConstant(m, "TIPC_SRC_DROPPABLE", TIPC_SRC_DROPPABLE); + PyModule_AddIntConstant(m, "TIPC_DEST_DROPPABLE", + TIPC_DEST_DROPPABLE); + PyModule_AddIntConstant(m, "TIPC_CONN_TIMEOUT", TIPC_CONN_TIMEOUT); + + PyModule_AddIntConstant(m, "TIPC_LOW_IMPORTANCE", + TIPC_LOW_IMPORTANCE); + PyModule_AddIntConstant(m, "TIPC_MEDIUM_IMPORTANCE", + TIPC_MEDIUM_IMPORTANCE); + PyModule_AddIntConstant(m, "TIPC_HIGH_IMPORTANCE", + TIPC_HIGH_IMPORTANCE); + PyModule_AddIntConstant(m, "TIPC_CRITICAL_IMPORTANCE", + TIPC_CRITICAL_IMPORTANCE); + + /* for subscriptions */ + PyModule_AddIntConstant(m, "TIPC_SUB_PORTS", TIPC_SUB_PORTS); + PyModule_AddIntConstant(m, "TIPC_SUB_SERVICE", TIPC_SUB_SERVICE); + PyModule_AddIntConstant(m, "TIPC_SUB_CANCEL", TIPC_SUB_CANCEL); + PyModule_AddIntConstant(m, "TIPC_WAIT_FOREVER", TIPC_WAIT_FOREVER); + PyModule_AddIntConstant(m, "TIPC_PUBLISHED", TIPC_PUBLISHED); + PyModule_AddIntConstant(m, "TIPC_WITHDRAWN", TIPC_WITHDRAWN); + PyModule_AddIntConstant(m, "TIPC_SUBSCR_TIMEOUT", TIPC_SUBSCR_TIMEOUT); + PyModule_AddIntConstant(m, "TIPC_CFG_SRV", TIPC_CFG_SRV); + PyModule_AddIntConstant(m, "TIPC_TOP_SRV", TIPC_TOP_SRV); +#endif + /* Socket types */ PyModule_AddIntConstant(m, "SOCK_STREAM", SOCK_STREAM); PyModule_AddIntConstant(m, "SOCK_DGRAM", SOCK_DGRAM); Modified: python/trunk/Modules/socketmodule.h ============================================================================== --- python/trunk/Modules/socketmodule.h (original) +++ python/trunk/Modules/socketmodule.h Mon Jan 7 17:12:44 2008 @@ -60,6 +60,10 @@ # include #endif +#ifdef HAVE_LINUX_TIPC_H +# include +#endif + #ifndef Py__SOCKET_H #define Py__SOCKET_H #ifdef __cplusplus Modified: python/trunk/configure ============================================================================== --- python/trunk/configure (original) +++ python/trunk/configure Mon Jan 7 17:12:44 2008 @@ -1,5 +1,5 @@ #! /bin/sh -# From configure.in Revision: 59558 . +# From configure.in Revision: 59611 . # Guess values for system-dependent variables and create Makefiles. # Generated by GNU Autoconf 2.61 for python 2.6. # @@ -5417,6 +5417,7 @@ + for ac_header in asm/types.h conio.h curses.h direct.h dlfcn.h errno.h \ fcntl.h grp.h \ io.h langinfo.h libintl.h ncurses.h poll.h process.h pthread.h \ @@ -5428,7 +5429,7 @@ sys/time.h \ sys/times.h sys/types.h sys/un.h sys/utsname.h sys/wait.h pty.h libutil.h \ sys/resource.h netpacket/packet.h sysexits.h bluetooth.h \ -bluetooth/bluetooth.h +bluetooth/bluetooth.h linux/tipc.h do as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then Modified: python/trunk/configure.in ============================================================================== --- python/trunk/configure.in (original) +++ python/trunk/configure.in Mon Jan 7 17:12:44 2008 @@ -1107,7 +1107,7 @@ sys/time.h \ sys/times.h sys/types.h sys/un.h sys/utsname.h sys/wait.h pty.h libutil.h \ sys/resource.h netpacket/packet.h sysexits.h bluetooth.h \ -bluetooth/bluetooth.h) +bluetooth/bluetooth.h linux/tipc.h) AC_HEADER_DIRENT AC_HEADER_MAJOR Modified: python/trunk/pyconfig.h.in ============================================================================== --- python/trunk/pyconfig.h.in (original) +++ python/trunk/pyconfig.h.in Mon Jan 7 17:12:44 2008 @@ -354,6 +354,9 @@ /* Define to 1 if you have the header file. */ #undef HAVE_LINUX_NETLINK_H +/* Define to 1 if you have the header file. */ +#undef HAVE_LINUX_TIPC_H + /* Define this if you have the type long long. */ #undef HAVE_LONG_LONG @@ -1040,4 +1043,3 @@ #endif /*Py_PYCONFIG_H*/ - From buildbot at python.org Mon Jan 7 17:19:41 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 07 Jan 2008 16:19:41 +0000 Subject: [Python-checkins] buildbot failure in x86 mvlgcc trunk Message-ID: <20080107161941.3384E1E4002@bag.python.org> The Buildbot has detected a new failure of x86 mvlgcc trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20mvlgcc%20trunk/builds/1149 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-linux Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: christian.heimes,georg.brandl,vinay.sajip BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "./Lib/test/regrtest.py", line 167, in from test import test_support File "/home2/buildbot/slave/trunk.loewis-linux/build/Lib/test/test_support.py", line 8, in import socket File "/home2/buildbot/slave/trunk.loewis-linux/build/Lib/socket.py", line 46, in import _socket ImportError: No module named _socket make: *** [buildbottest] Fehler 1 sincerely, -The Buildbot From g.brandl at gmx.net Mon Jan 7 17:33:21 2008 From: g.brandl at gmx.net (Georg Brandl) Date: Mon, 07 Jan 2008 17:33:21 +0100 Subject: [Python-checkins] r59815 - python/trunk/Doc/library/collections.rst In-Reply-To: <012901c85111$65bb3280$6800a8c0@RaymondLaptop1> References: <20080107091818.0B8521E4015@bag.python.org> <012901c85111$65bb3280$6800a8c0@RaymondLaptop1> Message-ID: Raymond Hettinger schrieb: > Please revert the part with "somenamedtuple". That was not a typo, it is distinct from namedtuple() which is a factory function > which returns a new class. The moniker, somenamedtuple refers to a instance of that created class. Ok, sorry. I guess _make needs to be "somenamedtuple._make" too, then? Georg From buildbot at python.org Mon Jan 7 17:40:01 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 07 Jan 2008 16:40:01 +0000 Subject: [Python-checkins] buildbot failure in x86 gentoo trunk Message-ID: <20080107164001.B0ED21E4002@bag.python.org> The Buildbot has detected a new failure of x86 gentoo trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20gentoo%20trunk/builds/2833 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-x86 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: christian.heimes,georg.brandl,vinay.sajip BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_socket ====================================================================== ERROR: testStream (test.test_socket.TIPCThreadableTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/test/test_socket.py", line 112, in _setUp self.__setUp() File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/test/test_socket.py", line 1136, in setUp self.srv = socket.socket(socket.AF_TIPC, socket.SOCK_STREAM) AttributeError: 'module' object has no attribute 'AF_TIPC' make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Mon Jan 7 17:41:57 2008 From: python-checkins at python.org (georg.brandl) Date: Mon, 7 Jan 2008 17:41:57 +0100 (CET) Subject: [Python-checkins] r59820 - python/trunk/Python/future.c Message-ID: <20080107164157.8C4C51E4002@bag.python.org> Author: georg.brandl Date: Mon Jan 7 17:41:57 2008 New Revision: 59820 Modified: python/trunk/Python/future.c Log: #1755: typo. Modified: python/trunk/Python/future.c ============================================================================== --- python/trunk/Python/future.c (original) +++ python/trunk/Python/future.c Mon Jan 7 17:41:57 2008 @@ -65,7 +65,7 @@ /* A subsequent pass will detect future imports that don't appear at the beginning of the file. There's one case, - however, that is easier to handl here: A series of imports + however, that is easier to handle here: A series of imports joined by semi-colons, where the first import is a future statement but some subsequent import has the future form but is preceded by a regular import. From python-checkins at python.org Mon Jan 7 17:42:09 2008 From: python-checkins at python.org (mark.summerfield) Date: Mon, 7 Jan 2008 17:42:09 +0100 (CET) Subject: [Python-checkins] r59821 - python/trunk/Doc/library/stdtypes.rst Message-ID: <20080107164209.1DED71E4002@bag.python.org> Author: mark.summerfield Date: Mon Jan 7 17:42:08 2008 New Revision: 59821 Modified: python/trunk/Doc/library/stdtypes.rst Log: Added a hyperlink from sequence types to mutable sequence types. Modified: python/trunk/Doc/library/stdtypes.rst ============================================================================== --- python/trunk/Doc/library/stdtypes.rst (original) +++ python/trunk/Doc/library/stdtypes.rst Mon Jan 7 17:42:08 2008 @@ -562,7 +562,7 @@ Most sequence types support the following operations. The ``in`` and ``not in`` operations have the same priorities as the comparison operations. The ``+`` and ``*`` operations have the same priority as the corresponding numeric operations. -[#]_ +[#]_ Additional methods are provided for :ref:`typesseq-mutable`. This table lists the sequence operations sorted in ascending priority (operations in the same box have the same priority). In the table, *s* and *t* From python-checkins at python.org Mon Jan 7 17:43:48 2008 From: python-checkins at python.org (georg.brandl) Date: Mon, 7 Jan 2008 17:43:48 +0100 (CET) Subject: [Python-checkins] r59822 - python/trunk/Doc/library/collections.rst Message-ID: <20080107164348.304461E4002@bag.python.org> Author: georg.brandl Date: Mon Jan 7 17:43:47 2008 New Revision: 59822 Modified: python/trunk/Doc/library/collections.rst Log: Restore "somenamedtuple" as the "class" for named tuple attrs. Modified: python/trunk/Doc/library/collections.rst ============================================================================== --- python/trunk/Doc/library/collections.rst (original) +++ python/trunk/Doc/library/collections.rst Mon Jan 7 17:43:47 2008 @@ -349,7 +349,7 @@ .. _named-tuple-factory: :func:`namedtuple` Factory Function for Tuples with Named Fields ------------------------------------------------------------------ +---------------------------------------------------------------- Named tuples assign meaning to each position in a tuple and allow for more readable, self-documenting code. They can be used wherever regular tuples are used, and @@ -448,7 +448,7 @@ In addition to the methods inherited from tuples, named tuples support three additional methods and one attribute. -.. method:: namedtuple._make(iterable) +.. method:: somenamedtuple._make(iterable) Class method that makes a new instance from an existing sequence or iterable. @@ -458,7 +458,7 @@ >>> Point._make(t) Point(x=11, y=22) -.. method:: namedtuple._asdict() +.. method:: somenamedtuple._asdict() Return a new dict which maps field names to their corresponding values: @@ -467,7 +467,7 @@ >>> p._asdict() {'x': 11, 'y': 22} -.. method:: namedtuple._replace(kwargs) +.. method:: somenamedtuple._replace(kwargs) Return a new instance of the named tuple replacing specified fields with new values: @@ -480,7 +480,7 @@ >>> for partnum, record in inventory.items(): ... inventory[partnum] = record._replace(price=newprices[partnum], updated=time.now()) -.. attribute:: namedtuple._fields +.. attribute:: somenamedtuple._fields Tuple of strings listing the field names. This is useful for introspection and for creating new named tuple types from existing named tuples. @@ -496,9 +496,7 @@ Pixel(x=11, y=22, red=128, green=255, blue=0)' To retrieve a field whose name is stored in a string, use the :func:`getattr` -function: - -:: +function:: >>> getattr(p, 'x') 11 @@ -534,9 +532,7 @@ return self._make(_map(kwds.pop, ('x', 'y'), self)) Default values can be implemented by starting with a prototype instance -and customizing it with :meth:`_replace`: - -:: +and customizing it with :meth:`_replace`:: >>> Account = namedtuple('Account', 'owner balance transaction_count') >>> model_account = Account('', 0.0, 0) From python at rcn.com Mon Jan 7 17:42:35 2008 From: python at rcn.com (Raymond Hettinger) Date: Mon, 7 Jan 2008 08:42:35 -0800 Subject: [Python-checkins] r59815 -python/trunk/Doc/library/collections.rst References: <20080107091818.0B8521E4015@bag.python.org><012901c85111$65bb3280$6800a8c0@RaymondLaptop1> Message-ID: <016401c8514c$4f0c2720$6800a8c0@RaymondLaptop1> > Ok, sorry. I guess _make needs to be "somenamedtuple._make" too, then? Yes, please. Raymond From python-checkins at python.org Mon Jan 7 17:49:03 2008 From: python-checkins at python.org (facundo.batista) Date: Mon, 7 Jan 2008 17:49:03 +0100 (CET) Subject: [Python-checkins] r59823 - python/branches/release25-maint/Lib/os.py Message-ID: <20080107164903.4479C1E4002@bag.python.org> Author: facundo.batista Date: Mon Jan 7 17:49:02 2008 New Revision: 59823 Modified: python/branches/release25-maint/Lib/os.py Log: Backport of issue 1755179 fix. Modified: python/branches/release25-maint/Lib/os.py ============================================================================== --- python/branches/release25-maint/Lib/os.py (original) +++ python/branches/release25-maint/Lib/os.py Mon Jan 7 17:49:02 2008 @@ -23,7 +23,7 @@ #' -import sys +import sys, errno _names = sys.builtin_module_names @@ -156,7 +156,6 @@ recursive. """ - from errno import EEXIST head, tail = path.split(name) if not tail: head, tail = path.split(head) @@ -165,7 +164,7 @@ makedirs(head, mode) except OSError, e: # be happy if someone already created the path - if e.errno != EEXIST: + if e.errno != errno.EEXIST: raise if tail == curdir: # xxx/newdir/. exists if xxx/newdir exists return @@ -365,8 +364,6 @@ __all__.extend(["execl","execle","execlp","execlpe","execvp","execvpe"]) def _execvpe(file, args, env=None): - from errno import ENOENT, ENOTDIR - if env is not None: func = execve argrest = (args, env) @@ -392,7 +389,7 @@ func(fullname, *argrest) except error, e: tb = sys.exc_info()[2] - if (e.errno != ENOENT and e.errno != ENOTDIR + if (e.errno != errno.ENOENT and e.errno != errno.ENOTDIR and saved_exc is None): saved_exc = e saved_tb = tb From buildbot at python.org Mon Jan 7 17:55:52 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 07 Jan 2008 16:55:52 +0000 Subject: [Python-checkins] buildbot failure in ppc Debian unstable trunk Message-ID: <20080107165553.2886F1E4002@bag.python.org> The Buildbot has detected a new failure of ppc Debian unstable trunk. Full details are available at: http://www.python.org/dev/buildbot/all/ppc%20Debian%20unstable%20trunk/builds/543 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: christian.heimes,georg.brandl,vinay.sajip BUILD FAILED: failed test Excerpt from the test logfile: 2 tests failed: test_socket test_xmlrpc Traceback (most recent call last): File "./Lib/test/regrtest.py", line 556, in runtest_inner indirect_test() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_socket.py", line 1187, in test_main if isTipcAvailable(): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_socket.py", line 1106, in isTipcAvailable if test_support.debug: AttributeError: 'module' object has no attribute 'debug' ====================================================================== ERROR: test_fail_with_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_xmlrpc.py", line 580, in test_fail_with_info p.pow(6,8) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1157, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1447, in __request verbose=self.__verbose File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1195, in request errcode, errmsg, headers = h.getreply() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 1006, in getreply response = self._conn.getresponse() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 932, in getresponse response.begin() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 415, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 271, in readheaders line = self.fp.readline() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/socket.py", line 354, in readline data = recv(1) error: [Errno 104] Connection reset by peer make: *** [buildbottest] Error 1 sincerely, -The Buildbot From g.brandl at gmx.net Mon Jan 7 18:01:05 2008 From: g.brandl at gmx.net (Georg Brandl) Date: Mon, 07 Jan 2008 18:01:05 +0100 Subject: [Python-checkins] r59819 - in python/trunk: Doc/library/socket.rst Lib/test/test_socket.py Misc/NEWS Modules/socketmodule.c Modules/socketmodule.h configure configure.in pyconfig.h.in In-Reply-To: <20080107161245.0CCFF1E4002@bag.python.org> References: <20080107161245.0CCFF1E4002@bag.python.org> Message-ID: christian.heimes schrieb: > Author: christian.heimes > Date: Mon Jan 7 17:12:44 2008 > New Revision: 59819 > > Modified: > python/trunk/Doc/library/socket.rst > python/trunk/Lib/test/test_socket.py > python/trunk/Misc/NEWS > python/trunk/Modules/socketmodule.c > python/trunk/Modules/socketmodule.h > python/trunk/configure > python/trunk/configure.in > python/trunk/pyconfig.h.in > Log: > Issue #1646: Make socket support TIPC. The socket module now has support > for TIPC under Linux, see http://tipc.sf.net/ for more information. > Thanks to Alberto Bertogli for the patch > Modified: python/trunk/Lib/test/test_socket.py > ============================================================================== > --- python/trunk/Lib/test/test_socket.py (original) > +++ python/trunk/Lib/test/test_socket.py Mon Jan 7 17:12:44 2008 > @@ -1084,6 +1084,85 @@ > buf = buffer(MSG) > self.serv_conn.send(buf) > > + > +TIPC_STYPE = 2000 > +TIPC_LOWER = 200 > +TIPC_UPPER = 210 > + > +def isTipcAvailable(): > + """Check if the TIPC module is loaded > + > + The TIPC module is not loaded automatically on Ubuntu and probably > + other Linux distros. > + """ > + if not hasattr(socket, "AF_TIPC"): > + return False > + if not os.path.isfile("/proc/modules"): > + return False > + with open("/proc/modules") as f: > + for line in f: > + if line.startswith("tipc "): > + return True > + if test_support.debug: I assume this should be test_support.verbose? Georg From buildbot at python.org Mon Jan 7 18:03:13 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 07 Jan 2008 17:03:13 +0000 Subject: [Python-checkins] buildbot failure in sparc solaris10 gcc trunk Message-ID: <20080107170314.0B5601E4019@bag.python.org> The Buildbot has detected a new failure of sparc solaris10 gcc trunk. Full details are available at: http://www.python.org/dev/buildbot/all/sparc%20solaris10%20gcc%20trunk/builds/2564 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-sun Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: christian.heimes,georg.brandl,vinay.sajip BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_socket ====================================================================== ERROR: testStream (test.test_socket.TIPCThreadableTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/test/test_socket.py", line 112, in _setUp self.__setUp() File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/test/test_socket.py", line 1136, in setUp self.srv = socket.socket(socket.AF_TIPC, socket.SOCK_STREAM) AttributeError: 'module' object has no attribute 'AF_TIPC' sincerely, -The Buildbot From buildbot at python.org Mon Jan 7 18:08:19 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 07 Jan 2008 17:08:19 +0000 Subject: [Python-checkins] buildbot failure in g4 osx.4 trunk Message-ID: <20080107170819.B5EDB1E4002@bag.python.org> The Buildbot has detected a new failure of g4 osx.4 trunk. Full details are available at: http://www.python.org/dev/buildbot/all/g4%20osx.4%20trunk/builds/2565 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: psf-g4 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: christian.heimes,georg.brandl,vinay.sajip BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_socket ====================================================================== ERROR: testStream (test.test_socket.TIPCThreadableTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/test/test_socket.py", line 112, in _setUp self.__setUp() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/test/test_socket.py", line 1136, in setUp self.srv = socket.socket(socket.AF_TIPC, socket.SOCK_STREAM) AttributeError: 'module' object has no attribute 'AF_TIPC' make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Mon Jan 7 18:09:36 2008 From: python-checkins at python.org (georg.brandl) Date: Mon, 7 Jan 2008 18:09:36 +0100 (CET) Subject: [Python-checkins] r59824 - in python/trunk: Doc/library/sys.rst Doc/using/cmdline.rst Include/pydebug.h Misc/NEWS Modules/main.c Python/import.c Python/pythonrun.c Python/sysmodule.c Message-ID: <20080107170936.B551C1E4002@bag.python.org> Author: georg.brandl Date: Mon Jan 7 18:09:35 2008 New Revision: 59824 Modified: python/trunk/Doc/library/sys.rst python/trunk/Doc/using/cmdline.rst python/trunk/Include/pydebug.h python/trunk/Misc/NEWS python/trunk/Modules/main.c python/trunk/Python/import.c python/trunk/Python/pythonrun.c python/trunk/Python/sysmodule.c Log: Patch #602345 by Neal Norwitz and me: add -B option and PYTHONDONTWRITEBYTECODE envvar to skip writing bytecode. Modified: python/trunk/Doc/library/sys.rst ============================================================================== --- python/trunk/Doc/library/sys.rst (original) +++ python/trunk/Doc/library/sys.rst Mon Jan 7 18:09:35 2008 @@ -507,6 +507,17 @@ when Python is started with the -3 option. +.. data:: dont_write_bytecode + + If this is true, Python won't try to write ``.pyc`` or ``.pyo`` files on the + import of source modules. This value is initially set to ``True`` or ``False`` + depending on the ``-B`` command line option and the ``PYTHONDONTWRITEBYTECODE`` + environment variable, but you can set it yourself to control bytecode file + generation. + + .. versionadded:: 2.6 + + .. function:: setcheckinterval(interval) Set the interpreter's "check interval". This integer value determines how often Modified: python/trunk/Doc/using/cmdline.rst ============================================================================== --- python/trunk/Doc/using/cmdline.rst (original) +++ python/trunk/Doc/using/cmdline.rst Mon Jan 7 18:09:35 2008 @@ -145,6 +145,14 @@ Miscellaneous options ~~~~~~~~~~~~~~~~~~~~~ +.. cmdoption:: -B + + If given, Python won't try to write ``.pyc`` or ``.pyo`` files on the + import of source modules. See also :envvar:`PYTHONDONTWRITEBYTECODE`. + + .. versionadded:: 2.6 + + .. cmdoption:: -d Turn on parser debugging output (for wizards only, depending on compilation @@ -411,3 +419,10 @@ If this is set, Python ignores case in :keyword:`import` statements. This only works on Windows. + +.. envvar:: PYTHONDONTWRITEBYTECODE + + If given, Python won't try to write ``.pyc`` or ``.pyo`` files on the + import of source modules. + + .. versionadded:: 2.6 Modified: python/trunk/Include/pydebug.h ============================================================================== --- python/trunk/Include/pydebug.h (original) +++ python/trunk/Include/pydebug.h Mon Jan 7 18:09:35 2008 @@ -17,6 +17,7 @@ PyAPI_DATA(int) Py_UnicodeFlag; PyAPI_DATA(int) Py_IgnoreEnvironmentFlag; PyAPI_DATA(int) Py_DivisionWarningFlag; +PyAPI_DATA(int) Py_DontWriteBytecodeFlag; /* _XXX Py_QnewFlag should go away in 3.0. It's true iff -Qnew is passed, on the command line, and is used in 2.2 by ceval.c to make all "/" divisions true divisions (which they will be in 3.0). */ Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Mon Jan 7 18:09:35 2008 @@ -12,6 +12,10 @@ Core and builtins ----------------- +- Patch #602345: Add -B command line option, PYTHONDONTWRITEBYTECODE envvar + and sys.dont_write_bytecode attribute. All these can be set to forbid Python + to attempt to write compiled bytecode files. + - Improve some exception messages when Windows fails to load an extension module. Now we get for example '%1 is not a valid Win32 application' instead of 'error code 193'. Modified: python/trunk/Modules/main.c ============================================================================== --- python/trunk/Modules/main.c (original) +++ python/trunk/Modules/main.c Mon Jan 7 18:09:35 2008 @@ -40,7 +40,7 @@ static int orig_argc; /* command line options */ -#define BASE_OPTS "3c:dEhim:OQ:StuUvVW:xX?" +#define BASE_OPTS "3Bc:dEhim:OQ:StuUvVW:xX?" #ifndef RISCOS #define PROGRAM_OPTS BASE_OPTS @@ -59,39 +59,42 @@ /* Long usage message, split into parts < 512 bytes */ static char *usage_1 = "\ Options and arguments (and corresponding environment variables):\n\ +-B : don't write .py[co] files on import; also PYTHONDONTWRITEBYTECODE=x\n\ -c cmd : program passed in as string (terminates option list)\n\ -d : debug output from parser; also PYTHONDEBUG=x\n\ -E : ignore environment variables (such as PYTHONPATH)\n\ -h : print this help message and exit (also --help)\n\ -i : inspect interactively after running script; forces a prompt even\n\ - if stdin does not appear to be a terminal; also PYTHONINSPECT=x\n\ "; static char *usage_2 = "\ + if stdin does not appear to be a terminal; also PYTHONINSPECT=x\n\ -m mod : run library module as a script (terminates option list)\n\ -O : optimize generated bytecode slightly; also PYTHONOPTIMIZE=x\n\ -OO : remove doc-strings in addition to the -O optimizations\n\ -Q arg : division options: -Qold (default), -Qwarn, -Qwarnall, -Qnew\n\ -S : don't imply 'import site' on initialization\n\ -t : issue warnings about inconsistent tab usage (-tt: issue errors)\n\ --u : unbuffered binary stdout and stderr; also PYTHONUNBUFFERED=x\n\ "; static char *usage_3 = "\ +-u : unbuffered binary stdout and stderr; also PYTHONUNBUFFERED=x\n\ see man page for details on internal buffering relating to '-u'\n\ -v : verbose (trace import statements); also PYTHONVERBOSE=x\n\ can be supplied multiple times to increase verbosity\n\ -V : print the Python version number and exit (also --version)\n\ -W arg : warning control; arg is action:message:category:module:lineno\n\ -x : skip first line of source, allowing use of non-Unix forms of #!cmd\n\ +"; +static char *usage_4 = "\ -3 : warn about Python 3.x incompatibilities\n\ file : program read from script file\n\ - : program read from stdin (default; interactive mode if a tty)\n\ -"; -static char *usage_4 = "\ arg ...: arguments passed to program in sys.argv[1:]\n\n\ Other environment variables:\n\ PYTHONSTARTUP: file executed on interactive startup (no default)\n\ PYTHONPATH : '%c'-separated list of directories prefixed to the\n\ default module search path. The result is sys.path.\n\ +"; +static char *usage_5 = "\ PYTHONHOME : alternate directory (or %c).\n\ The default module search path uses %s.\n\ PYTHONCASEOK : ignore case in 'import' statements (Windows).\n\ @@ -110,7 +113,8 @@ fprintf(f, usage_1); fprintf(f, usage_2); fprintf(f, usage_3); - fprintf(f, usage_4, DELIM, DELIM, PYTHONHOMEHELP); + fprintf(f, usage_4, DELIM); + fprintf(f, usage_5, DELIM, PYTHONHOMEHELP); } #if defined(__VMS) if (exitcode == 0) { @@ -337,6 +341,10 @@ Py_OptimizeFlag++; break; + case 'B': + Py_DontWriteBytecodeFlag++; + break; + case 'S': Py_NoSiteFlag++; break; Modified: python/trunk/Python/import.c ============================================================================== --- python/trunk/Python/import.c (original) +++ python/trunk/Python/import.c Mon Jan 7 18:09:35 2008 @@ -950,8 +950,11 @@ if (Py_VerboseFlag) PySys_WriteStderr("import %s # from %s\n", name, pathname); - if (cpathname) - write_compiled_module(co, cpathname, mtime); + if (cpathname) { + PyObject *ro = PySys_GetObject("dont_write_bytecode"); + if (ro == NULL || !PyObject_IsTrue(ro)) + write_compiled_module(co, cpathname, mtime); + } } m = PyImport_ExecCodeModuleEx(name, (PyObject *)co, pathname); Py_DECREF(co); Modified: python/trunk/Python/pythonrun.c ============================================================================== --- python/trunk/Python/pythonrun.c (original) +++ python/trunk/Python/pythonrun.c Mon Jan 7 18:09:35 2008 @@ -72,6 +72,7 @@ int Py_InteractiveFlag; /* Needed by Py_FdIsInteractive() below */ int Py_InspectFlag; /* Needed to determine whether to exit at SystemError */ int Py_NoSiteFlag; /* Suppress 'import site' */ +int Py_DontWriteBytecodeFlag; /* Suppress writing bytecode files (*.py[co]) */ int Py_UseClassExceptionsFlag = 1; /* Needed by bltinmodule.c: deprecated */ int Py_FrozenFlag; /* Needed by getpath.c */ int Py_UnicodeFlag = 0; /* Needed by compile.c */ @@ -172,6 +173,8 @@ Py_VerboseFlag = add_flag(Py_VerboseFlag, p); if ((p = Py_GETENV("PYTHONOPTIMIZE")) && *p != '\0') Py_OptimizeFlag = add_flag(Py_OptimizeFlag, p); + if ((p = Py_GETENV("PYTHONDONTWRITEBYTECODE")) && *p != '\0') + Py_DontWriteBytecodeFlag = add_flag(Py_DontWriteBytecodeFlag, p); interp = PyInterpreterState_New(); if (interp == NULL) Modified: python/trunk/Python/sysmodule.c ============================================================================== --- python/trunk/Python/sysmodule.c (original) +++ python/trunk/Python/sysmodule.c Mon Jan 7 18:09:35 2008 @@ -1128,6 +1128,9 @@ v = Py_BuildValue("(ssz)", "CPython", branch, svn_revision); PyDict_SetItemString(sysdict, "subversion", v); Py_XDECREF(v); + PyDict_SetItemString(sysdict, "dont_write_bytecode", + v = PyBool_FromLong(Py_DontWriteBytecodeFlag)); + Py_XDECREF(v); /* * These release level checks are mutually exclusive and cover * the field, so don't get too fancy with the pre-processor! From buildbot at python.org Mon Jan 7 18:23:34 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 07 Jan 2008 17:23:34 +0000 Subject: [Python-checkins] buildbot failure in x86 FreeBSD trunk Message-ID: <20080107172334.507841E4002@bag.python.org> The Buildbot has detected a new failure of x86 FreeBSD trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20FreeBSD%20trunk/builds/355 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-freebsd Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: christian.heimes,georg.brandl,vinay.sajip BUILD FAILED: failed test Excerpt from the test logfile: sincerely, -The Buildbot From python-checkins at python.org Mon Jan 7 18:25:54 2008 From: python-checkins at python.org (georg.brandl) Date: Mon, 7 Jan 2008 18:25:54 +0100 (CET) Subject: [Python-checkins] r59827 - in python/trunk: Doc/using/cmdline.rst Misc/NEWS Modules/main.c Python/import.c Python/thread.c Message-ID: <20080107172554.68EF51E4002@bag.python.org> Author: georg.brandl Date: Mon Jan 7 18:25:53 2008 New Revision: 59827 Modified: python/trunk/Doc/using/cmdline.rst python/trunk/Misc/NEWS python/trunk/Modules/main.c python/trunk/Python/import.c python/trunk/Python/thread.c Log: patch #1668: clarify envvar docs; rename THREADDEBUG to PYTHONTHREADDEBUG. Modified: python/trunk/Doc/using/cmdline.rst ============================================================================== --- python/trunk/Doc/using/cmdline.rst (original) +++ python/trunk/Doc/using/cmdline.rst Mon Jan 7 18:25:53 2008 @@ -335,6 +335,8 @@ Environment variables --------------------- +These environment variables influence Python's behavior. + .. envvar:: PYTHONHOME Change the location of the standard Python libraries. By default, the @@ -350,7 +352,7 @@ .. envvar:: PYTHONPATH - Augments the default search path for module files. The format is the same as + Augment the default search path for module files. The format is the same as the shell's :envvar:`PATH`: one or more directory pathnames separated by colons. Non-existent directories are silently ignored. @@ -400,6 +402,9 @@ If this is set to a non-empty string it is equivalent to specifying the :option:`-i` option. + This variable can also be modified by Python code using :data:`os.environ` + to force inspect mode on program termination. + .. envvar:: PYTHONUNBUFFERED @@ -422,7 +427,40 @@ .. envvar:: PYTHONDONTWRITEBYTECODE - If given, Python won't try to write ``.pyc`` or ``.pyo`` files on the + If this is set, Python won't try to write ``.pyc`` or ``.pyo`` files on the import of source modules. .. versionadded:: 2.6 + + +.. envvar:: PYTHONEXECUTABLE + + If this environment variable is set, ``sys.argv[0]`` will be set to its + value instead of the value got through the C runtime. Only works on + MacOS X. + + +Debug-mode variables +^^^^^^^^^^^^^^^^^^^^ + +Setting these variables only has an effect in a debug build of Python, that is, +if Python was configured with the :opt:`--with-pydebug` build option. + +.. envvar:: PYTHONTHREADDEBUG + + If set, Python will print debug threading debug info. + + .. versionchanged:: 2.6 + Previously, this variable was called ``THREADDEBUG``. + +.. envvar:: PYTHONDUMPREFS + + If set, Python will dump objects and reference counts still alive after + shutting down the interpreter. + + +.. envvar:: PYTHONMALLOCSTATS + + If set, Python will print memory allocation statistics every time a new + object arena is created, and on shutdown. + Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Mon Jan 7 18:25:53 2008 @@ -12,6 +12,8 @@ Core and builtins ----------------- +- Patch #1668: renamed THREADDEBUG envvar to PYTHONTHREADDEBUG. + - Patch #602345: Add -B command line option, PYTHONDONTWRITEBYTECODE envvar and sys.dont_write_bytecode attribute. All these can be set to forbid Python to attempt to write compiled bytecode files. Modified: python/trunk/Modules/main.c ============================================================================== --- python/trunk/Modules/main.c (original) +++ python/trunk/Modules/main.c Mon Jan 7 18:25:53 2008 @@ -62,7 +62,7 @@ -B : don't write .py[co] files on import; also PYTHONDONTWRITEBYTECODE=x\n\ -c cmd : program passed in as string (terminates option list)\n\ -d : debug output from parser; also PYTHONDEBUG=x\n\ --E : ignore environment variables (such as PYTHONPATH)\n\ +-E : ignore PYTHON* environment variables (such as PYTHONPATH)\n\ -h : print this help message and exit (also --help)\n\ -i : inspect interactively after running script; forces a prompt even\n\ "; Modified: python/trunk/Python/import.c ============================================================================== --- python/trunk/Python/import.c (original) +++ python/trunk/Python/import.c Mon Jan 7 18:25:53 2008 @@ -1630,7 +1630,7 @@ FILEFINDBUF3 ffbuf; APIRET rc; - if (getenv("PYTHONCASEOK") != NULL) + if (Py_GETENV("PYTHONCASEOK") != NULL) return 1; rc = DosFindFirst(buf, Modified: python/trunk/Python/thread.c ============================================================================== --- python/trunk/Python/thread.c (original) +++ python/trunk/Python/thread.c Mon Jan 7 18:25:53 2008 @@ -79,7 +79,7 @@ PyThread_init_thread(void) { #ifdef Py_DEBUG - char *p = getenv("THREADDEBUG"); + char *p = Py_GETENV("PYTHONTHREADDEBUG"); if (p) { if (*p) From buildbot at python.org Mon Jan 7 18:50:50 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 07 Jan 2008 17:50:50 +0000 Subject: [Python-checkins] buildbot failure in alpha Tru64 5.1 2.5 Message-ID: <20080107175050.3E8E31E4002@bag.python.org> The Buildbot has detected a new failure of alpha Tru64 5.1 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/alpha%20Tru64%205.1%202.5/builds/390 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-tru64 Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: facundo.batista BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_signal sincerely, -The Buildbot From python-checkins at python.org Mon Jan 7 19:16:37 2008 From: python-checkins at python.org (georg.brandl) Date: Mon, 7 Jan 2008 19:16:37 +0100 (CET) Subject: [Python-checkins] r59830 - in python/trunk: Objects/typeobject.c Parser/tokenizer.c Parser/tokenizer.h Python/ast.c Message-ID: <20080107181637.2AB641E4002@bag.python.org> Author: georg.brandl Date: Mon Jan 7 19:16:36 2008 New Revision: 59830 Modified: python/trunk/Objects/typeobject.c python/trunk/Parser/tokenizer.c python/trunk/Parser/tokenizer.h python/trunk/Python/ast.c Log: Make Python compile with --disable-unicode. Modified: python/trunk/Objects/typeobject.c ============================================================================== --- python/trunk/Objects/typeobject.c (original) +++ python/trunk/Objects/typeobject.c Mon Jan 7 19:16:36 2008 @@ -3220,8 +3220,10 @@ type->tp_flags |= Py_TPFLAGS_LONG_SUBCLASS; else if (PyType_IsSubtype(base, &PyString_Type)) type->tp_flags |= Py_TPFLAGS_STRING_SUBCLASS; +#ifdef Py_USING_UNICODE else if (PyType_IsSubtype(base, &PyUnicode_Type)) type->tp_flags |= Py_TPFLAGS_UNICODE_SUBCLASS; +#endif else if (PyType_IsSubtype(base, &PyTuple_Type)) type->tp_flags |= Py_TPFLAGS_TUPLE_SUBCLASS; else if (PyType_IsSubtype(base, &PyList_Type)) Modified: python/trunk/Parser/tokenizer.c ============================================================================== --- python/trunk/Parser/tokenizer.c (original) +++ python/trunk/Parser/tokenizer.c Mon Jan 7 19:16:36 2008 @@ -1533,6 +1533,7 @@ return result; } +#ifdef Py_USING_UNICODE /* This function is only called from parsetok. However, it cannot live there, as it must be empty for PGEN, and we can check for PGEN only in this file. */ @@ -1593,6 +1594,7 @@ } #endif +#endif /* defined(Py_USING_UNICODE) */ #ifdef Py_DEBUG Modified: python/trunk/Parser/tokenizer.h ============================================================================== --- python/trunk/Parser/tokenizer.h (original) +++ python/trunk/Parser/tokenizer.h Mon Jan 7 19:16:36 2008 @@ -58,8 +58,10 @@ extern struct tok_state *PyTokenizer_FromFile(FILE *, char *, char *); extern void PyTokenizer_Free(struct tok_state *); extern int PyTokenizer_Get(struct tok_state *, char **, char **); +#ifdef Py_USING_UNICODE extern char * PyTokenizer_RestoreEncoding(struct tok_state* tok, int len, int *offset); +#endif #ifdef __cplusplus } Modified: python/trunk/Python/ast.c ============================================================================== --- python/trunk/Python/ast.c (original) +++ python/trunk/Python/ast.c Mon Jan 7 19:16:36 2008 @@ -1246,6 +1246,7 @@ case STRING: { PyObject *str = parsestrplus(c, n); if (!str) { +#ifdef Py_USING_UNICODE if (PyErr_ExceptionMatches(PyExc_UnicodeError)){ PyObject *type, *value, *tback, *errstr; PyErr_Fetch(&type, &value, &tback); @@ -1263,6 +1264,7 @@ Py_DECREF(value); Py_XDECREF(tback); } +#endif return NULL; } PyArena_AddPyObject(c->c_arena, str); From python-checkins at python.org Mon Jan 7 19:23:27 2008 From: python-checkins at python.org (georg.brandl) Date: Mon, 7 Jan 2008 19:23:27 +0100 (CET) Subject: [Python-checkins] r59831 - python/trunk/Doc/library/urllib.rst Message-ID: <20080107182327.F16801E4002@bag.python.org> Author: georg.brandl Date: Mon Jan 7 19:23:27 2008 New Revision: 59831 Modified: python/trunk/Doc/library/urllib.rst Log: Restructure urllib doc structure. Modified: python/trunk/Doc/library/urllib.rst ============================================================================== --- python/trunk/Doc/library/urllib.rst (original) +++ python/trunk/Doc/library/urllib.rst Mon Jan 7 19:23:27 2008 @@ -1,4 +1,3 @@ - :mod:`urllib` --- Open arbitrary resources by URL ================================================= @@ -17,8 +16,8 @@ instead of filenames. Some restrictions apply --- it can only open URLs for reading, and no seek operations are available. -It defines the following public functions: - +High-level interface +-------------------- .. function:: urlopen(url[, data[, proxies]]) @@ -178,6 +177,9 @@ :func:`urlretrieve`. +Utility functions +----------------- + .. function:: quote(string[, safe]) Replace special characters in *string* using the ``%xx`` escape. Letters, @@ -239,6 +241,9 @@ to decode *path*. +URL Opener objects +------------------ + .. class:: URLopener([proxies[, **x509]]) Base class for opening and reading URLs. Unless you need to support opening @@ -264,6 +269,48 @@ :class:`URLopener` objects will raise an :exc:`IOError` exception if the server returns an error code. + .. method:: open(fullurl[, data]) + + Open *fullurl* using the appropriate protocol. This method sets up cache and + proxy information, then calls the appropriate open method with its input + arguments. If the scheme is not recognized, :meth:`open_unknown` is called. + The *data* argument has the same meaning as the *data* argument of + :func:`urlopen`. + + + .. method:: open_unknown(fullurl[, data]) + + Overridable interface to open unknown URL types. + + + .. method:: retrieve(url[, filename[, reporthook[, data]]]) + + Retrieves the contents of *url* and places it in *filename*. The return value + is a tuple consisting of a local filename and either a + :class:`mimetools.Message` object containing the response headers (for remote + URLs) or ``None`` (for local URLs). The caller must then open and read the + contents of *filename*. If *filename* is not given and the URL refers to a + local file, the input filename is returned. If the URL is non-local and + *filename* is not given, the filename is the output of :func:`tempfile.mktemp` + with a suffix that matches the suffix of the last path component of the input + URL. If *reporthook* is given, it must be a function accepting three numeric + parameters. It will be called after each chunk of data is read from the + network. *reporthook* is ignored for local URLs. + + If the *url* uses the :file:`http:` scheme identifier, the optional *data* + argument may be given to specify a ``POST`` request (normally the request type + is ``GET``). The *data* argument must in standard + :mimetype:`application/x-www-form-urlencoded` format; see the :func:`urlencode` + function below. + + + .. attribute:: version + + Variable that specifies the user agent of the opener object. To get + :mod:`urllib` to tell servers that it is a particular user agent, set this in a + subclass as a class variable or in the constructor before calling the base + constructor. + .. class:: FancyURLopener(...) @@ -293,6 +340,18 @@ users for the required information on the controlling terminal. A subclass may override this method to support more appropriate behavior if needed. + The :class:`FancyURLopener` class offers one additional method that should be + overloaded to provide the appropriate behavior: + + .. method:: prompt_user_passwd(host, realm) + + Return information needed to authenticate the user at the given host in the + specified security realm. The return value should be a tuple, ``(user, + password)``, which can be used for basic authentication. + + The implementation prompts for this information on the terminal; an application + should override this method to use an appropriate interaction model in the local + environment. .. exception:: ContentTooShortError(msg[, content]) @@ -303,7 +362,9 @@ .. versionadded:: 2.5 -Restrictions: + +:mod:`urllib` Restrictions +-------------------------- .. index:: pair: HTTP; protocol @@ -364,75 +425,6 @@ module :mod:`urlparse`. -.. _urlopener-objs: - -URLopener Objects ------------------ - -.. sectionauthor:: Skip Montanaro - - -:class:`URLopener` and :class:`FancyURLopener` objects have the following -attributes. - - -.. method:: URLopener.open(fullurl[, data]) - - Open *fullurl* using the appropriate protocol. This method sets up cache and - proxy information, then calls the appropriate open method with its input - arguments. If the scheme is not recognized, :meth:`open_unknown` is called. - The *data* argument has the same meaning as the *data* argument of - :func:`urlopen`. - - -.. method:: URLopener.open_unknown(fullurl[, data]) - - Overridable interface to open unknown URL types. - - -.. method:: URLopener.retrieve(url[, filename[, reporthook[, data]]]) - - Retrieves the contents of *url* and places it in *filename*. The return value - is a tuple consisting of a local filename and either a - :class:`mimetools.Message` object containing the response headers (for remote - URLs) or ``None`` (for local URLs). The caller must then open and read the - contents of *filename*. If *filename* is not given and the URL refers to a - local file, the input filename is returned. If the URL is non-local and - *filename* is not given, the filename is the output of :func:`tempfile.mktemp` - with a suffix that matches the suffix of the last path component of the input - URL. If *reporthook* is given, it must be a function accepting three numeric - parameters. It will be called after each chunk of data is read from the - network. *reporthook* is ignored for local URLs. - - If the *url* uses the :file:`http:` scheme identifier, the optional *data* - argument may be given to specify a ``POST`` request (normally the request type - is ``GET``). The *data* argument must in standard - :mimetype:`application/x-www-form-urlencoded` format; see the :func:`urlencode` - function below. - - -.. attribute:: URLopener.version - - Variable that specifies the user agent of the opener object. To get - :mod:`urllib` to tell servers that it is a particular user agent, set this in a - subclass as a class variable or in the constructor before calling the base - constructor. - -The :class:`FancyURLopener` class offers one additional method that should be -overloaded to provide the appropriate behavior: - - -.. method:: FancyURLopener.prompt_user_passwd(host, realm) - - Return information needed to authenticate the user at the given host in the - specified security realm. The return value should be a tuple, ``(user, - password)``, which can be used for basic authentication. - - The implementation prompts for this information on the terminal; an application - should override this method to use an appropriate interaction model in the local - environment. - - .. _urllib-examples: Examples From buildbot at python.org Mon Jan 7 19:38:18 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 07 Jan 2008 18:38:18 +0000 Subject: [Python-checkins] buildbot failure in ppc Debian unstable 3.0 Message-ID: <20080107183818.A88971E4016@bag.python.org> The Buildbot has detected a new failure of ppc Debian unstable 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/ppc%20Debian%20unstable%203.0/builds/447 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes,georg.brandl BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 522, in __init__ self.handle() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/BaseHTTPServer.py", line 330, in handle self.handle_one_request() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/BaseHTTPServer.py", line 324, in handle_one_request method() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SimpleXMLRPCServer.py", line 430, in do_POST self.report_404() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SimpleXMLRPCServer.py", line 489, in report_404 self.connection.shutdown(1) socket.error: [Errno 107] Transport endpoint is not connected 1 test failed: test_xmlrpc Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 522, in __init__ self.handle() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/BaseHTTPServer.py", line 330, in handle self.handle_one_request() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/BaseHTTPServer.py", line 324, in handle_one_request method() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SimpleXMLRPCServer.py", line 430, in do_POST self.report_404() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SimpleXMLRPCServer.py", line 489, in report_404 self.connection.shutdown(1) socket.error: [Errno 107] Transport endpoint is not connected ====================================================================== ERROR: test_fail_with_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/test/test_xmlrpc.py", line 515, in test_fail_with_info p.pow(6,8) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1091, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1349, in __request verbose=self.__verbose File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1121, in request resp = http_conn.getresponse() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/httplib.py", line 961, in getresponse response.begin() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/httplib.py", line 425, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/httplib.py", line 267, in readheaders line = str(self.fp.readline(), "iso-8859-1") File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/io.py", line 413, in readline b = self.read(nreadahead()) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/io.py", line 475, in read n = self.readinto(b) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/socket.py", line 217, in readinto return self._sock.recv_into(b) socket.error: [Errno 104] Connection reset by peer make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Mon Jan 7 19:41:34 2008 From: python-checkins at python.org (georg.brandl) Date: Mon, 7 Jan 2008 19:41:34 +0100 (CET) Subject: [Python-checkins] r59833 - python/trunk/Parser/tokenizer.c python/trunk/Parser/tokenizer.h Message-ID: <20080107184134.E98561E401A@bag.python.org> Author: georg.brandl Date: Mon Jan 7 19:41:34 2008 New Revision: 59833 Modified: python/trunk/Parser/tokenizer.c python/trunk/Parser/tokenizer.h Log: Fix #define ordering. Modified: python/trunk/Parser/tokenizer.c ============================================================================== --- python/trunk/Parser/tokenizer.c (original) +++ python/trunk/Parser/tokenizer.c Mon Jan 7 19:41:34 2008 @@ -1533,7 +1533,6 @@ return result; } -#ifdef Py_USING_UNICODE /* This function is only called from parsetok. However, it cannot live there, as it must be empty for PGEN, and we can check for PGEN only in this file. */ @@ -1545,6 +1544,7 @@ return NULL; } #else +#ifdef Py_USING_UNICODE static PyObject * dec_utf8(const char *enc, const char *text, size_t len) { PyObject *ret = NULL; @@ -1592,10 +1592,9 @@ return text; } +#endif /* defined(Py_USING_UNICODE) */ #endif -#endif /* defined(Py_USING_UNICODE) */ - #ifdef Py_DEBUG Modified: python/trunk/Parser/tokenizer.h ============================================================================== --- python/trunk/Parser/tokenizer.h (original) +++ python/trunk/Parser/tokenizer.h Mon Jan 7 19:41:34 2008 @@ -58,7 +58,7 @@ extern struct tok_state *PyTokenizer_FromFile(FILE *, char *, char *); extern void PyTokenizer_Free(struct tok_state *); extern int PyTokenizer_Get(struct tok_state *, char **, char **); -#ifdef Py_USING_UNICODE +#if defined(PGEN) || defined(Py_USING_UNICODE) extern char * PyTokenizer_RestoreEncoding(struct tok_state* tok, int len, int *offset); #endif From python-checkins at python.org Mon Jan 7 19:47:44 2008 From: python-checkins at python.org (georg.brandl) Date: Mon, 7 Jan 2008 19:47:44 +0100 (CET) Subject: [Python-checkins] r59834 - in python/trunk: Doc/library/zipfile.rst Lib/test/test_zipfile.py Lib/zipfile.py Misc/NEWS Message-ID: <20080107184744.B3BF11E401F@bag.python.org> Author: georg.brandl Date: Mon Jan 7 19:47:44 2008 New Revision: 59834 Modified: python/trunk/Doc/library/zipfile.rst python/trunk/Lib/test/test_zipfile.py python/trunk/Lib/zipfile.py python/trunk/Misc/NEWS Log: #467924, patch by Alan McIntyre: Add ZipFile.extract and ZipFile.extractall. Modified: python/trunk/Doc/library/zipfile.rst ============================================================================== --- python/trunk/Doc/library/zipfile.rst (original) +++ python/trunk/Doc/library/zipfile.rst Mon Jan 7 19:47:44 2008 @@ -180,6 +180,27 @@ .. versionadded:: 2.6 +.. method:: ZipFile.extract(member[, path[, pwd]]) + + Extract a member from the archive to the current working directory, using its + full name. Its file information is extracted as accurately as possible. + *path* specifies a different directory to extract to. *member* can be a + filename or a :class:`ZipInfo` object. *pwd* is the password used for + encrypted files. + + .. versionadded:: 2.6 + + +.. method:: ZipFile.extractall([path[, members[, pwd]]]) + + Extract all members from the archive to the current working directory. *path* + specifies a different directory to extract to. *members* is optional and must + be a subset of the list returned by :meth:`namelist`. *pwd* is the password + used for encrypted files. + + .. versionadded:: 2.6 + + .. method:: ZipFile.printdir() Print a table of contents for the archive to ``sys.stdout``. @@ -249,6 +270,13 @@ created with mode ``'r'`` will raise a :exc:`RuntimeError`. Calling :meth:`writestr` on a closed ZipFile will raise a :exc:`RuntimeError`. + .. note:: + + When passing a :class:`ZipInfo` instance as the *zinfo_or_acrname* parameter, + the compression method used will be that specified in the *compress_type* + member of the given :class:`ZipInfo` instance. By default, the + :class:`ZipInfo` constructor sets this member to :const:`ZIP_STORED`. + The following data attribute is also available: Modified: python/trunk/Lib/test/test_zipfile.py ============================================================================== --- python/trunk/Lib/test/test_zipfile.py (original) +++ python/trunk/Lib/test/test_zipfile.py Mon Jan 7 19:47:44 2008 @@ -16,6 +16,11 @@ TESTFN2 = TESTFN + "2" FIXEDTEST_SIZE = 1000 +SMALL_TEST_DATA = [('_ziptest1', '1q2w3e4r5t'), + ('ziptest2dir/_ziptest2', 'qawsedrftg'), + ('/ziptest2dir/ziptest3dir/_ziptest3', 'azsxdcfvgb'), + ('ziptest2dir/ziptest3dir/ziptest4dir/_ziptest3', '6y7u8i9o0p')] + class TestsWithSourceFile(unittest.TestCase): def setUp(self): self.line_gen = ["Zipfile test line %d. random float: %f" % (i, random()) @@ -296,6 +301,57 @@ self.assertRaises(RuntimeError, zipf.write, TESTFN) zipf.close() + def testExtract(self): + zipfp = zipfile.ZipFile(TESTFN2, "w", zipfile.ZIP_STORED) + for fpath, fdata in SMALL_TEST_DATA: + zipfp.writestr(fpath, fdata) + zipfp.close() + + zipfp = zipfile.ZipFile(TESTFN2, "r") + for fpath, fdata in SMALL_TEST_DATA: + writtenfile = zipfp.extract(fpath) + + # make sure it was written to the right place + if os.path.isabs(fpath): + correctfile = os.path.join(os.getcwd(), fpath[1:]) + else: + correctfile = os.path.join(os.getcwd(), fpath) + + self.assertEqual(writtenfile, correctfile) + + # make sure correct data is in correct file + self.assertEqual(fdata, file(writtenfile, "rb").read()) + + os.remove(writtenfile) + + zipfp.close() + + # remove the test file subdirectories + shutil.rmtree(os.path.join(os.getcwd(), 'ziptest2dir')) + + def testExtractAll(self): + zipfp = zipfile.ZipFile(TESTFN2, "w", zipfile.ZIP_STORED) + for fpath, fdata in SMALL_TEST_DATA: + zipfp.writestr(fpath, fdata) + zipfp.close() + + zipfp = zipfile.ZipFile(TESTFN2, "r") + zipfp.extractall() + for fpath, fdata in SMALL_TEST_DATA: + if os.path.isabs(fpath): + outfile = os.path.join(os.getcwd(), fpath[1:]) + else: + outfile = os.path.join(os.getcwd(), fpath) + + self.assertEqual(fdata, file(outfile, "rb").read()) + + os.remove(outfile) + + zipfp.close() + + # remove the test file subdirectories + shutil.rmtree(os.path.join(os.getcwd(), 'ziptest2dir')) + def tearDown(self): os.remove(TESTFN) os.remove(TESTFN2) Modified: python/trunk/Lib/zipfile.py ============================================================================== --- python/trunk/Lib/zipfile.py (original) +++ python/trunk/Lib/zipfile.py Mon Jan 7 19:47:44 2008 @@ -1,7 +1,7 @@ """ Read and write ZIP files. """ -import struct, os, time, sys +import struct, os, time, sys, shutil import binascii, cStringIO try: @@ -807,6 +807,62 @@ zef.set_univ_newlines(True) return zef + def extract(self, member, path=None, pwd=None): + """Extract a member from the archive to the current working directory, + using its full name. Its file information is extracted as accurately + as possible. `member' may be a filename or a ZipInfo object. You can + specify a different directory using `path'. + """ + if not isinstance(member, ZipInfo): + member = self.getinfo(member) + + if path is None: + path = os.getcwd() + + return self._extract_member(member, path, pwd) + + def extractall(self, path=None, members=None, pwd=None): + """Extract all members from the archive to the current working + directory. `path' specifies a different directory to extract to. + `members' is optional and must be a subset of the list returned + by namelist(). + """ + if members is None: + members = self.namelist() + + for zipinfo in members: + self.extract(zipinfo, path, pwd) + + def _extract_member(self, member, targetpath, pwd): + """Extract the ZipInfo object 'member' to a physical + file on the path targetpath. + """ + # build the destination pathname, replacing + # forward slashes to platform specific separators. + if targetpath[-1:] == "/": + targetpath = targetpath[:-1] + + # don't include leading "/" from file name if present + if os.path.isabs(member.filename): + targetpath = os.path.join(targetpath, member.filename[1:]) + else: + targetpath = os.path.join(targetpath, member.filename) + + targetpath = os.path.normpath(targetpath) + + # Create all upper directories if necessary. + upperdirs = os.path.dirname(targetpath) + if upperdirs and not os.path.exists(upperdirs): + os.makedirs(upperdirs) + + source = self.open(member.filename, pwd=pwd) + target = file(targetpath, "wb") + shutil.copyfileobj(source, target) + source.close() + target.close() + + return targetpath + def _writecheck(self, zinfo): """Check for errors before writing a file to the archive.""" if zinfo.filename in self.NameToInfo: Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Mon Jan 7 19:47:44 2008 @@ -348,6 +348,9 @@ Library ------- +- Patch #467924: add ZipFile.extract() and ZipFile.extractall() in the + zipfile module. + - Issue #1646: Make socket support the TIPC protocol. - Bug #1742: return os.curdir from os.path.relpath() if both arguments are From buildbot at python.org Mon Jan 7 19:48:59 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 07 Jan 2008 18:48:59 +0000 Subject: [Python-checkins] buildbot failure in amd64 XP trunk Message-ID: <20080107184859.BB4B81E4027@bag.python.org> The Buildbot has detected a new failure of amd64 XP trunk. Full details are available at: http://www.python.org/dev/buildbot/all/amd64%20XP%20trunk/builds/526 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: heller-windows-amd64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: georg.brandl BUILD FAILED: failed compile sincerely, -The Buildbot From python-checkins at python.org Mon Jan 7 19:52:19 2008 From: python-checkins at python.org (raymond.hettinger) Date: Mon, 7 Jan 2008 19:52:19 +0100 (CET) Subject: [Python-checkins] r59835 - python/trunk/Doc/using/cmdline.rst Message-ID: <20080107185219.9FEF41E4002@bag.python.org> Author: raymond.hettinger Date: Mon Jan 7 19:52:19 2008 New Revision: 59835 Modified: python/trunk/Doc/using/cmdline.rst Log: Fix inconsistent title levels -- it made the whole doc build crash horribly. Modified: python/trunk/Doc/using/cmdline.rst ============================================================================== --- python/trunk/Doc/using/cmdline.rst (original) +++ python/trunk/Doc/using/cmdline.rst Mon Jan 7 19:52:19 2008 @@ -441,7 +441,7 @@ Debug-mode variables -^^^^^^^^^^^^^^^^^^^^ +-------------------- Setting these variables only has an effect in a debug build of Python, that is, if Python was configured with the :opt:`--with-pydebug` build option. From python-checkins at python.org Mon Jan 7 19:57:03 2008 From: python-checkins at python.org (georg.brandl) Date: Mon, 7 Jan 2008 19:57:03 +0100 (CET) Subject: [Python-checkins] r59836 - in python/trunk/Doc: library/stdtypes.rst using/cmdline.rst Message-ID: <20080107185703.C5ABD1E4002@bag.python.org> Author: georg.brandl Date: Mon Jan 7 19:57:03 2008 New Revision: 59836 Modified: python/trunk/Doc/library/stdtypes.rst python/trunk/Doc/using/cmdline.rst Log: Fix two further doc build warnings. Modified: python/trunk/Doc/library/stdtypes.rst ============================================================================== --- python/trunk/Doc/library/stdtypes.rst (original) +++ python/trunk/Doc/library/stdtypes.rst Mon Jan 7 19:57:03 2008 @@ -469,8 +469,9 @@ One method needs to be defined for container objects to provide iteration support: +.. XXX duplicated in reference/datamodel! -.. method:: object.__iter__() +.. method:: container.__iter__() Return an iterator object. The object is required to support the iterator protocol described below. If a container supports different types of Modified: python/trunk/Doc/using/cmdline.rst ============================================================================== --- python/trunk/Doc/using/cmdline.rst (original) +++ python/trunk/Doc/using/cmdline.rst Mon Jan 7 19:57:03 2008 @@ -441,10 +441,10 @@ Debug-mode variables --------------------- +~~~~~~~~~~~~~~~~~~~~ Setting these variables only has an effect in a debug build of Python, that is, -if Python was configured with the :opt:`--with-pydebug` build option. +if Python was configured with the :option:`--with-pydebug` build option. .. envvar:: PYTHONTHREADDEBUG From python-checkins at python.org Mon Jan 7 20:17:10 2008 From: python-checkins at python.org (georg.brandl) Date: Mon, 7 Jan 2008 20:17:10 +0100 (CET) Subject: [Python-checkins] r59837 - python/trunk/Doc/reference/datamodel.rst Message-ID: <20080107191710.4EF861E401A@bag.python.org> Author: georg.brandl Date: Mon Jan 7 20:17:10 2008 New Revision: 59837 Modified: python/trunk/Doc/reference/datamodel.rst Log: Clarify metaclass docs and add example. Modified: python/trunk/Doc/reference/datamodel.rst ============================================================================== --- python/trunk/Doc/reference/datamodel.rst (original) +++ python/trunk/Doc/reference/datamodel.rst Mon Jan 7 20:17:10 2008 @@ -1177,7 +1177,8 @@ :meth:`__init__` method will not be invoked. :meth:`__new__` is intended mainly to allow subclasses of immutable types (like - int, str, or tuple) to customize instance creation. + int, str, or tuple) to customize instance creation. It is also commonly + overridden in custom metaclasses in order to customize class creation. .. method:: object.__init__(self[, ...]) @@ -1651,7 +1652,7 @@ bound to the result of ``type(name, bases, dict)``. When the class definition is read, if *__metaclass__* is defined then the -callable assigned to it will be called instead of :func:`type`. The allows +callable assigned to it will be called instead of :func:`type`. This allows classes or functions to be written which monitor or alter the class creation process: @@ -1660,6 +1661,20 @@ * Returning an instance of another class -- essentially performing the role of a factory function. +These steps will have to be performed in the metaclass's :meth:`__new__` method +-- :meth:`type.__new__` can then be called from this method to create a class +with different properties. This example adds a new element to the class +dictionary before creating the class:: + + class metacls(type): + def __new__(mcs, name, bases, dict): + dict['foo'] = 'metacls was here' + return type.__new__(mcs, name, bases, dict) + +You can of course also override other class methods (or add new methods); for +example defining a custom :meth:`__call__` method in the metaclass allows custom +behavior when the class is called, e.g. not always creating a new instance. + .. data:: __metaclass__ From python-checkins at python.org Mon Jan 7 20:40:10 2008 From: python-checkins at python.org (vinay.sajip) Date: Mon, 7 Jan 2008 20:40:10 +0100 (CET) Subject: [Python-checkins] r59838 - python/trunk/Doc/library/logging.rst Message-ID: <20080107194010.9DB721E4002@bag.python.org> Author: vinay.sajip Date: Mon Jan 7 20:40:10 2008 New Revision: 59838 Modified: python/trunk/Doc/library/logging.rst Log: Added section about adding contextual information to log output. Modified: python/trunk/Doc/library/logging.rst ============================================================================== --- python/trunk/Doc/library/logging.rst (original) +++ python/trunk/Doc/library/logging.rst Mon Jan 7 20:40:10 2008 @@ -1137,6 +1137,52 @@ combination of handlers you choose. +.. _context-info: + +Adding contextual information to your logging output +---------------------------------------------------- + +Sometimes you want logging output to contain contextual information in +addition to the parameters passed to the logging call. For example, in a +networked application, it may be desirable to log client-specific information +in the log (e.g. remote client's username, or IP address). Although you could +use the *extra* parameter to achieve this, it's not always convenient to pass +the information in this way. While it might be tempting to create +:class:`Logger` instances on a per-connection basis, this is not a good idea +because these instances are not garbage collected. While this is not a problem +in practice, when the number of :class:`Logger` instances is dependent on the +level of granularity you want to use in logging an application, it could +be hard to manage if the number of :class:`Logger` instances becomes +effectively unbounded. + +There are a number of other ways you can pass contextual information to be +output along with logging event information. + +* Use an adapter class which has access to the contextual information and + which defines methods :meth:`debug`, :meth:`info` etc. with the same + signatures as used by :class:`Logger`. You instantiate the adapter with a + name, which will be used to create an underlying :class:`Logger` with that + name. In each adpater method, the passed-in message is modified to include + whatever contextual information you want. + +* Use something other than a string to pass the message. Although normally + the first argument to a logger method such as :meth:`debug`, :meth:`info` + etc. is usually a string, it can in fact be any object. This object is the + argument to a :func:`str()` call which is made, in + :meth:`LogRecord.getMessage`, to obtain the actual message string. You can + use this behavior to pass an instance which may be initialized with a + logging message, which redefines :meth:__str__ to return a modified version + of that message with the contextual information added. + +* Use a specialized :class:`Formatter` subclass to add additional information + to the formatted output. The subclass could, for instance, merge some thread + local contextual information (or contextual information obtained in some + other way) with the output generated by the base :class:`Formatter`. + +In each of these three approaches, thread locals can sometimes be a useful way +of passing contextual information without undue coupling between different +parts of your code. + .. _network-logging: Sending and receiving logging events across a network From buildbot at python.org Mon Jan 7 20:44:27 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 07 Jan 2008 19:44:27 +0000 Subject: [Python-checkins] buildbot failure in hppa Ubuntu 3.0 Message-ID: <20080107194427.56C771E4002@bag.python.org> The Buildbot has detected a new failure of hppa Ubuntu 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/hppa%20Ubuntu%203.0/builds/427 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-ubuntu-hppa Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes,georg.brandl BUILD FAILED: failed test Excerpt from the test logfile: make: *** [buildbottest] Unknown signal 37 sincerely, -The Buildbot From python-checkins at python.org Mon Jan 7 20:58:41 2008 From: python-checkins at python.org (christian.heimes) Date: Mon, 7 Jan 2008 20:58:41 +0100 (CET) Subject: [Python-checkins] r59839 - python/trunk/Lib/test/test_socket.py Message-ID: <20080107195841.4D83B1E4002@bag.python.org> Author: christian.heimes Date: Mon Jan 7 20:58:41 2008 New Revision: 59839 Modified: python/trunk/Lib/test/test_socket.py Log: Fixed indention problem that caused the second TIPC test to run on systems without TIPC Modified: python/trunk/Lib/test/test_socket.py ============================================================================== --- python/trunk/Lib/test/test_socket.py (original) +++ python/trunk/Lib/test/test_socket.py Mon Jan 7 20:58:41 2008 @@ -1186,7 +1186,7 @@ tests.append(TestLinuxAbstractNamespace) if isTipcAvailable(): tests.append(TIPCTest) - tests.append(TIPCThreadableTest) + tests.append(TIPCThreadableTest) thread_info = test_support.threading_setup() test_support.run_unittest(*tests) From python-checkins at python.org Mon Jan 7 21:07:38 2008 From: python-checkins at python.org (raymond.hettinger) Date: Mon, 7 Jan 2008 21:07:38 +0100 (CET) Subject: [Python-checkins] r59840 - in python/trunk: Doc/library/collections.rst Lib/collections.py Message-ID: <20080107200738.842011E401B@bag.python.org> Author: raymond.hettinger Date: Mon Jan 7 21:07:38 2008 New Revision: 59840 Modified: python/trunk/Doc/library/collections.rst python/trunk/Lib/collections.py Log: Cleanup named tuple subclassing example. Modified: python/trunk/Doc/library/collections.rst ============================================================================== --- python/trunk/Doc/library/collections.rst (original) +++ python/trunk/Doc/library/collections.rst Mon Jan 7 21:07:38 2008 @@ -365,7 +365,7 @@ The *fieldnames* are a single string with each fieldname separated by whitespace and/or commas (for example 'x y' or 'x, y'). Alternatively, the *fieldnames* - can be specified as a list of strings (such as ['x', 'y']). + can be specified with a sequence of strings (such as ['x', 'y']). Any valid Python identifier may be used for a fieldname except for names starting with an underscore. Valid identifiers consist of letters, digits, @@ -478,7 +478,7 @@ Point(x=33, y=22) >>> for partnum, record in inventory.items(): - ... inventory[partnum] = record._replace(price=newprices[partnum], updated=time.now()) + inventory[partnum] = record._replace(price=newprices[partnum], timestamp=time.now()) .. attribute:: somenamedtuple._fields @@ -515,13 +515,15 @@ @property def hypot(self): return (self.x ** 2 + self.y ** 2) ** 0.5 - def __repr__(self): - return 'Point(x=%.3f, y=%.3f, hypot=%.3f)' % (self.x, self.y, self.hypot) + def __str__(self): + return 'Point: x=%6.3f y=%6.3f hypot=%6.3f' % (self.x, self.y, self.hypot) - >>> print Point(3, 4),'\n', Point(2, 5), '\n', Point(9./7, 6) - Point(x=3.000, y=4.000, hypot=5.000) - Point(x=2.000, y=5.000, hypot=5.385) - Point(x=1.286, y=6.000, hypot=6.136) + >>> for p in Point(3,4), Point(14,5), Point(9./7,6): + print p + + Point: x= 3.000 y= 4.000 hypot= 5.000 + Point: x=14.000 y= 5.000 hypot=14.866 + Point: x= 1.286 y= 6.000 hypot= 6.136 Another use for subclassing is to replace performance critcal methods with faster versions that bypass error-checking and localize variable access:: @@ -531,8 +533,8 @@ def _replace(self, _map=map, **kwds): return self._make(_map(kwds.pop, ('x', 'y'), self)) -Default values can be implemented by starting with a prototype instance -and customizing it with :meth:`_replace`:: +Default values can be implemented by using :meth:`_replace`:: to +customize a prototype instance:: >>> Account = namedtuple('Account', 'owner balance transaction_count') >>> model_account = Account('', 0.0, 0) Modified: python/trunk/Lib/collections.py ============================================================================== --- python/trunk/Lib/collections.py (original) +++ python/trunk/Lib/collections.py Mon Jan 7 21:07:38 2008 @@ -120,10 +120,11 @@ @property def hypot(self): return (self.x ** 2 + self.y ** 2) ** 0.5 - def __repr__(self): - return 'Point(x=%.3f, y=%.3f, hypot=%.3f)' % (self.x, self.y, self.hypot) + def __str__(self): + return 'Point: x=%6.3f y=%6.3f hypot=%6.3f' % (self.x, self.y, self.hypot) - print Point(3, 4),'\n', Point(2, 5), '\n', Point(9./7, 6) + for p in Point(3,4), Point(14,5), Point(9./7,6): + print p class Point(namedtuple('Point', 'x y')): 'Point class with optimized _make() and _replace() without error-checking' From python-checkins at python.org Mon Jan 7 21:17:36 2008 From: python-checkins at python.org (raymond.hettinger) Date: Mon, 7 Jan 2008 21:17:36 +0100 (CET) Subject: [Python-checkins] r59842 - python/trunk/Doc/library/collections.rst Message-ID: <20080107201736.1D4F01E4002@bag.python.org> Author: raymond.hettinger Date: Mon Jan 7 21:17:35 2008 New Revision: 59842 Modified: python/trunk/Doc/library/collections.rst Log: Minor markup fix Modified: python/trunk/Doc/library/collections.rst ============================================================================== --- python/trunk/Doc/library/collections.rst (original) +++ python/trunk/Doc/library/collections.rst Mon Jan 7 21:17:35 2008 @@ -533,7 +533,7 @@ def _replace(self, _map=map, **kwds): return self._make(_map(kwds.pop, ('x', 'y'), self)) -Default values can be implemented by using :meth:`_replace`:: to +Default values can be implemented by using :meth:`_replace` to customize a prototype instance:: >>> Account = namedtuple('Account', 'owner balance transaction_count') From python-checkins at python.org Mon Jan 7 21:29:23 2008 From: python-checkins at python.org (brett.cannon) Date: Mon, 7 Jan 2008 21:29:23 +0100 (CET) Subject: [Python-checkins] r59843 - sandbox/trunk/import_in_py/TODO Message-ID: <20080107202923.30F2E1E4002@bag.python.org> Author: brett.cannon Date: Mon Jan 7 21:29:22 2008 New Revision: 59843 Modified: sandbox/trunk/import_in_py/TODO Log: Update the todo list. Modified: sandbox/trunk/import_in_py/TODO ============================================================================== --- sandbox/trunk/import_in_py/TODO (original) +++ sandbox/trunk/import_in_py/TODO Mon Jan 7 21:29:22 2008 @@ -1,2 +1,2 @@ -* Get zipimport passing 2.6's unit tests. * Put importlib into 2.6 stdlib. +* For Py3K, always have __file__ point to the .py file if it exists. From buildbot at python.org Mon Jan 7 21:33:07 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 07 Jan 2008 20:33:07 +0000 Subject: [Python-checkins] buildbot failure in sparc solaris10 gcc 3.0 Message-ID: <20080107203308.1C7191E4025@bag.python.org> The Buildbot has detected a new failure of sparc solaris10 gcc 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/sparc%20solaris10%20gcc%203.0/builds/474 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-sun Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: alexandre.vassalotti,christian.heimes,georg.brandl BUILD FAILED: failed test Excerpt from the test logfile: 3 tests failed: test_cProfile test_profile test_socket ====================================================================== ERROR: testStream (test.test_socket.TIPCThreadableTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/opt/users/buildbot/slave/3.0.loewis-sun/build/Lib/test/test_socket.py", line 112, in _setUp self.__setUp() File "/opt/users/buildbot/slave/3.0.loewis-sun/build/Lib/test/test_socket.py", line 1166, in setUp self.srv = socket.socket(socket.AF_TIPC, socket.SOCK_STREAM) AttributeError: 'module' object has no attribute 'AF_TIPC' sincerely, -The Buildbot From python-checkins at python.org Mon Jan 7 21:56:05 2008 From: python-checkins at python.org (raymond.hettinger) Date: Mon, 7 Jan 2008 21:56:05 +0100 (CET) Subject: [Python-checkins] r59844 - in python/trunk: Doc/library/collections.rst Lib/collections.py Message-ID: <20080107205605.A2A3E1E401D@bag.python.org> Author: raymond.hettinger Date: Mon Jan 7 21:56:05 2008 New Revision: 59844 Modified: python/trunk/Doc/library/collections.rst python/trunk/Lib/collections.py Log: Use get() instead of pop() for the optimized version of _replace(). Modified: python/trunk/Doc/library/collections.rst ============================================================================== --- python/trunk/Doc/library/collections.rst (original) +++ python/trunk/Doc/library/collections.rst Mon Jan 7 21:56:05 2008 @@ -531,7 +531,7 @@ >>> class Point(namedtuple('Point', 'x y')): _make = classmethod(tuple.__new__) def _replace(self, _map=map, **kwds): - return self._make(_map(kwds.pop, ('x', 'y'), self)) + return self._make(_map(kwds.get, ('x', 'y'), self)) Default values can be implemented by using :meth:`_replace` to customize a prototype instance:: Modified: python/trunk/Lib/collections.py ============================================================================== --- python/trunk/Lib/collections.py (original) +++ python/trunk/Lib/collections.py Mon Jan 7 21:56:05 2008 @@ -130,7 +130,7 @@ 'Point class with optimized _make() and _replace() without error-checking' _make = classmethod(tuple.__new__) def _replace(self, _map=map, **kwds): - return self._make(_map(kwds.pop, ('x', 'y'), self)) + return self._make(_map(kwds.get, ('x', 'y'), self)) print Point(11, 22)._replace(x=100) From buildbot at python.org Mon Jan 7 22:25:54 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 07 Jan 2008 21:25:54 +0000 Subject: [Python-checkins] buildbot failure in g4 osx.4 3.0 Message-ID: <20080107212555.0ED9F1E4002@bag.python.org> The Buildbot has detected a new failure of g4 osx.4 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/g4%20osx.4%203.0/builds/423 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: psf-g4 Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: alexandre.vassalotti,christian.heimes,georg.brandl BUILD FAILED: failed test Excerpt from the test logfile: 3 tests failed: test_cProfile test_profile test_socket ====================================================================== ERROR: testStream (test.test_socket.TIPCThreadableTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/test/test_socket.py", line 112, in _setUp self.__setUp() File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/test/test_socket.py", line 1166, in setUp self.srv = socket.socket(socket.AF_TIPC, socket.SOCK_STREAM) AttributeError: 'module' object has no attribute 'AF_TIPC' make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Mon Jan 7 22:33:51 2008 From: python-checkins at python.org (raymond.hettinger) Date: Mon, 7 Jan 2008 22:33:51 +0100 (CET) Subject: [Python-checkins] r59847 - python/trunk/Doc/library/collections.rst Message-ID: <20080107213351.7936C1E4002@bag.python.org> Author: raymond.hettinger Date: Mon Jan 7 22:33:51 2008 New Revision: 59847 Modified: python/trunk/Doc/library/collections.rst Log: Documentation nits. Modified: python/trunk/Doc/library/collections.rst ============================================================================== --- python/trunk/Doc/library/collections.rst (original) +++ python/trunk/Doc/library/collections.rst Mon Jan 7 22:33:51 2008 @@ -364,8 +364,8 @@ method which lists the tuple contents in a ``name=value`` format. The *fieldnames* are a single string with each fieldname separated by whitespace - and/or commas (for example 'x y' or 'x, y'). Alternatively, the *fieldnames* - can be specified with a sequence of strings (such as ['x', 'y']). + and/or commas (for example 'x y' or 'x, y'). Alternatively, *fieldnames* + can be a sequence of strings (such as ['x', 'y']). Any valid Python identifier may be used for a fieldname except for names starting with an underscore. Valid identifiers consist of letters, digits, @@ -482,7 +482,7 @@ .. attribute:: somenamedtuple._fields - Tuple of strings listing the field names. This is useful for introspection + Tuple of strings listing the field names. Useful for introspection and for creating new named tuple types from existing named tuples. :: @@ -501,7 +501,7 @@ >>> getattr(p, 'x') 11 -When casting a dictionary to a named tuple, use the double-star-operator [#]_:: +To cast a dictionary to a named tuple, use the double-star-operator [#]_:: >>> d = {'x': 11, 'y': 22} >>> Point(**d) @@ -526,7 +526,7 @@ Point: x= 1.286 y= 6.000 hypot= 6.136 Another use for subclassing is to replace performance critcal methods with -faster versions that bypass error-checking and localize variable access:: +faster versions that bypass error-checking and that localize variable access:: >>> class Point(namedtuple('Point', 'x y')): _make = classmethod(tuple.__new__) From buildbot at python.org Mon Jan 7 22:41:41 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 07 Jan 2008 21:41:41 +0000 Subject: [Python-checkins] buildbot failure in hppa Ubuntu 3.0 Message-ID: <20080107214142.14EAC1E4002@bag.python.org> The Buildbot has detected a new failure of hppa Ubuntu 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/hppa%20Ubuntu%203.0/builds/429 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-ubuntu-hppa Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: make: *** [buildbottest] Unknown signal 37 sincerely, -The Buildbot From buildbot at python.org Mon Jan 7 22:52:48 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 07 Jan 2008 21:52:48 +0000 Subject: [Python-checkins] buildbot failure in ia64 Ubuntu 3.0 Message-ID: <20080107215248.9D0EC1E4002@bag.python.org> The Buildbot has detected a new failure of ia64 Ubuntu 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/ia64%20Ubuntu%203.0/builds/446 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ia64 Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: alexandre.vassalotti,christian.heimes,georg.brandl BUILD FAILED: failed test Excerpt from the test logfile: 3 tests failed: test_cProfile test_profile test_socket Traceback (most recent call last): File "./Lib/test/regrtest.py", line 596, in runtest_inner indirect_test() File "/home/pybot/buildarea/3.0.klose-debian-ia64/build/Lib/test/test_socket.py", line 1216, in test_main if isTipcAvailable(): File "/home/pybot/buildarea/3.0.klose-debian-ia64/build/Lib/test/test_socket.py", line 1136, in isTipcAvailable if test_support.debug: AttributeError: 'module' object has no attribute 'debug' make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Mon Jan 7 23:46:23 2008 From: python-checkins at python.org (martin.v.loewis) Date: Mon, 7 Jan 2008 23:46:23 +0100 (CET) Subject: [Python-checkins] r59848 - python/branches/release25-maint/Doc/html/stdabout.dat Message-ID: <20080107224623.1DDB61E4004@bag.python.org> Author: martin.v.loewis Date: Mon Jan 7 23:46:22 2008 New Revision: 59848 Modified: python/branches/release25-maint/Doc/html/stdabout.dat Log: Fix bug tracker link. Modified: python/branches/release25-maint/Doc/html/stdabout.dat ============================================================================== --- python/branches/release25-maint/Doc/html/stdabout.dat (original) +++ python/branches/release25-maint/Doc/html/stdabout.dat Mon Jan 7 23:46:22 2008 @@ -28,12 +28,10 @@

Comments and Questions

General comments and questions regarding this document should - be sent by email to docs at python.org. If you find specific errors in - this document, either in the content or the presentation, please - report the bug at the Python Bug - Tracker at SourceForge. + be sent by email to docs at python.org. + If you find specific errors in this document, either in the content or + the presentation, please report the bug at the + Python Bug Tracker. If you are able to provide suggested text, either to replace existing incorrect or unclear material, or additional text to supplement what's already available, we'd appreciate the From python-checkins at python.org Tue Jan 8 03:02:05 2008 From: python-checkins at python.org (raymond.hettinger) Date: Tue, 8 Jan 2008 03:02:05 +0100 (CET) Subject: [Python-checkins] r59849 - python/trunk/Lib/collections.py Message-ID: <20080108020205.CBAEA1E401A@bag.python.org> Author: raymond.hettinger Date: Tue Jan 8 03:02:05 2008 New Revision: 59849 Modified: python/trunk/Lib/collections.py Log: Expand comment. Modified: python/trunk/Lib/collections.py ============================================================================== --- python/trunk/Lib/collections.py (original) +++ python/trunk/Lib/collections.py Tue Jan 8 03:02:05 2008 @@ -34,7 +34,8 @@ """ - # Parse and validate the field names + # Parse and validate the field names. Validation serves two purposes, + # generating informative error messages and preventing template injection attacks. if isinstance(field_names, basestring): field_names = field_names.replace(',', ' ').split() # names separated by whitespace and/or commas field_names = tuple(field_names) From python-checkins at python.org Tue Jan 8 03:24:15 2008 From: python-checkins at python.org (raymond.hettinger) Date: Tue, 8 Jan 2008 03:24:15 +0100 (CET) Subject: [Python-checkins] r59850 - python/trunk/Doc/library/collections.rst Message-ID: <20080108022415.8626D1E4004@bag.python.org> Author: raymond.hettinger Date: Tue Jan 8 03:24:15 2008 New Revision: 59850 Modified: python/trunk/Doc/library/collections.rst Log: Docs on named tuple's naming conventions and limits of subclassing Modified: python/trunk/Doc/library/collections.rst ============================================================================== --- python/trunk/Doc/library/collections.rst (original) +++ python/trunk/Doc/library/collections.rst Tue Jan 8 03:24:15 2008 @@ -446,7 +446,8 @@ print emp.name, emp.title In addition to the methods inherited from tuples, named tuples support -three additional methods and one attribute. +three additional methods and one attribute. To prevent conflicts with +field names, the method and attribute names start with an underscore. .. method:: somenamedtuple._make(iterable) @@ -533,6 +534,11 @@ def _replace(self, _map=map, **kwds): return self._make(_map(kwds.get, ('x', 'y'), self)) +Subclassing is not useful for adding new, stored fields. Instead, simply +create a new named tuple type from the :attr:`_fields` attribute:: + + >>> Pixel = namedtuple('Pixel', Point._fields + Color._fields) + Default values can be implemented by using :meth:`_replace` to customize a prototype instance:: From buildbot at python.org Tue Jan 8 03:49:53 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 08 Jan 2008 02:49:53 +0000 Subject: [Python-checkins] buildbot failure in x86 FreeBSD trunk Message-ID: <20080108024953.638661E4004@bag.python.org> The Buildbot has detected a new failure of x86 FreeBSD trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20FreeBSD%20trunk/builds/359 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-freebsd Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 523, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 523, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable 1 test failed: test_xmlrpc sincerely, -The Buildbot From python-checkins at python.org Tue Jan 8 04:40:05 2008 From: python-checkins at python.org (christian.heimes) Date: Tue, 8 Jan 2008 04:40:05 +0100 (CET) Subject: [Python-checkins] r59851 - python/trunk/Lib/test/test_socket.py Message-ID: <20080108034005.1FBC61E4004@bag.python.org> Author: christian.heimes Date: Tue Jan 8 04:40:04 2008 New Revision: 59851 Modified: python/trunk/Lib/test/test_socket.py Log: It's verbose, not debug Modified: python/trunk/Lib/test/test_socket.py ============================================================================== --- python/trunk/Lib/test/test_socket.py (original) +++ python/trunk/Lib/test/test_socket.py Tue Jan 8 04:40:04 2008 @@ -1103,7 +1103,7 @@ for line in f: if line.startswith("tipc "): return True - if test_support.debug: + if test_support.verbose: print "TIPC module is not loaded, please 'sudo modprobe tipc'" return False From buildbot at python.org Tue Jan 8 06:05:25 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 08 Jan 2008 05:05:25 +0000 Subject: [Python-checkins] buildbot failure in hppa Ubuntu trunk Message-ID: <20080108050525.508001E4004@bag.python.org> The Buildbot has detected a new failure of hppa Ubuntu trunk. Full details are available at: http://www.python.org/dev/buildbot/all/hppa%20Ubuntu%20trunk/builds/479 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-ubuntu-hppa Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: christian.heimes,raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_bsddb3 ====================================================================== ERROR: test00_associateDBError (bsddb.test.test_associate.AssociateErrorTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 104, in setUp self.env.open(homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateBTreeTxnTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateBTreeTxnTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test13_associate_in_transaction (bsddb.test.test_associate.AssociateBTreeTxnTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ShelveAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ShelveAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ShelveAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ThreadedAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ThreadedAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ThreadedAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ThreadedAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ThreadedAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ThreadedAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_EnvRemoveAndRename (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_EnvRemoveAndRename (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Transactions (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_TxnTruncate (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test08_TxnLateUse (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Transactions (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_TxnTruncate (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test08_TxnLateUse (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test09_MultiDB (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test09_MultiDB (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_both (bsddb.test.test_dbobj.dbobjTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbobj.py", line 45, in test01_both self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbobj.py", line 39, in open return apply(self._cobj.open, args, kwargs) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_dbobj_dict_interface (bsddb.test.test_dbobj.dbobjTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbobj.py", line 58, in test02_dbobj_dict_interface self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbobj.py", line 39, in open return apply(self._cobj.open, args, kwargs) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01 (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02 (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03 (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_MultiCondSelect (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_CondObjs (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_CreateOrExtend (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_Delete (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_Modify (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_close_dbenv_before_db (bsddb.test.test_env_close.DBEnvClosedEarlyCrash) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_env_close.py", line 53, in test01_close_dbenv_before_db 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_close_dbenv_delete_db_success (bsddb.test.test_env_close.DBEnvClosedEarlyCrash) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_env_close.py", line 78, in test02_close_dbenv_delete_db_success 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_join (bsddb.test.test_join.JoinTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_join.py", line 57, in setUp self.env.open(homeDir, db.DB_CREATE | db.DB_INIT_MPOOL | db.DB_INIT_LOCK ) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_simple (bsddb.test.test_lock.LockingTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_lock.py", line 38, in setUp db.DB_INIT_LOCK | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_threaded (bsddb.test.test_lock.LockingTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_lock.py", line 38, in setUp db.DB_INIT_LOCK | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_set_timeout (bsddb.test.test_lock.LockingTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_lock.py", line 38, in setUp db.DB_INIT_LOCK | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_db_home (bsddb.test.test_misc.MiscTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_misc.py", line 45, in test02_db_home env.open(self.homeDir, db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_1WriterMultiReaders (bsddb.test.test_thread.BTreeConcurrentDataStore) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_1WriterMultiReaders (bsddb.test.test_thread.HashConcurrentDataStore) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_SimpleLocks (bsddb.test.test_thread.BTreeSimpleThreaded) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_SimpleLocks (bsddb.test.test_thread.HashSimpleThreaded) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.BTreeThreadedTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.HashThreadedTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.BTreeThreadedNoWaitTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.HashThreadedNoWaitTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_cachesize (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_flags (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_get (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_get_dbp (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_get_key (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_range (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_remove (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_stat (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_pget (bsddb.test.test_cursor_pget_bug.pget_bugTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_cursor_pget_bug.py", line 25, in setUp self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Tue Jan 8 13:25:21 2008 From: python-checkins at python.org (facundo.batista) Date: Tue, 8 Jan 2008 13:25:21 +0100 (CET) Subject: [Python-checkins] r59852 - in python/trunk: Lib/decimal.py Lib/test/test_decimal.py Misc/NEWS Message-ID: <20080108122521.1D27A1E4019@bag.python.org> Author: facundo.batista Date: Tue Jan 8 13:25:20 2008 New Revision: 59852 Modified: python/trunk/Lib/decimal.py python/trunk/Lib/test/test_decimal.py python/trunk/Misc/NEWS Log: Issue #1757: The hash of a Decimal instance is no longer affected by the current context. Thanks Mark Dickinson. Modified: python/trunk/Lib/decimal.py ============================================================================== --- python/trunk/Lib/decimal.py (original) +++ python/trunk/Lib/decimal.py Tue Jan 8 13:25:20 2008 @@ -788,8 +788,10 @@ def __hash__(self): """x.__hash__() <==> hash(x)""" # Decimal integers must hash the same as the ints - # Non-integer decimals are normalized and hashed as strings - # Normalization assures that hash(100E-1) == hash(10) + # + # The hash of a nonspecial noninteger Decimal must depend only + # on the value of that Decimal, and not on its representation. + # For example: hash(Decimal("100E-1")) == hash(Decimal("10")). if self._is_special: if self._isnan(): raise TypeError('Cannot hash a NaN value.') @@ -805,7 +807,13 @@ # 2**64-1. So we can replace hash((-1)**s*c*10**e) with # hash((-1)**s*c*pow(10, e, 2**64-1). return hash((-1)**op.sign*op.int*pow(10, op.exp, 2**64-1)) - return hash(str(self.normalize())) + # The value of a nonzero nonspecial Decimal instance is + # faithfully represented by the triple consisting of its sign, + # its adjusted exponent, and its coefficient with trailing + # zeros removed. + return hash((self._sign, + self._exp+len(self._int), + self._int.rstrip('0'))) def as_tuple(self): """Represents the number as a triple tuple. Modified: python/trunk/Lib/test/test_decimal.py ============================================================================== --- python/trunk/Lib/test/test_decimal.py (original) +++ python/trunk/Lib/test/test_decimal.py Tue Jan 8 13:25:20 2008 @@ -980,6 +980,23 @@ self.assert_(hash(Decimal('Inf'))) self.assert_(hash(Decimal('-Inf'))) + # check that the value of the hash doesn't depend on the + # current context (issue #1757) + c = getcontext() + old_precision = c.prec + x = Decimal("123456789.1") + + c.prec = 6 + h1 = hash(x) + c.prec = 10 + h2 = hash(x) + c.prec = 16 + h3 = hash(x) + + self.assertEqual(h1, h2) + self.assertEqual(h1, h3) + c.prec = old_precision + def test_min_and_max_methods(self): d1 = Decimal('15.32') Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Tue Jan 8 13:25:20 2008 @@ -348,6 +348,9 @@ Library ------- +- Issue #1757: The hash of a Decimal instance is no longer affected by + the current context. + - Patch #467924: add ZipFile.extract() and ZipFile.extractall() in the zipfile module. From python-checkins at python.org Tue Jan 8 15:30:55 2008 From: python-checkins at python.org (andrew.kuchling) Date: Tue, 8 Jan 2008 15:30:55 +0100 (CET) Subject: [Python-checkins] r59853 - in python/trunk: Doc/library/pyexpat.rst Doc/whatsnew/2.6.rst Lib/test/test_pyexpat.py Misc/ACKS Misc/NEWS Modules/pyexpat.c Message-ID: <20080108143055.CAEC81E4016@bag.python.org> Author: andrew.kuchling Date: Tue Jan 8 15:30:55 2008 New Revision: 59853 Modified: python/trunk/Doc/library/pyexpat.rst python/trunk/Doc/whatsnew/2.6.rst python/trunk/Lib/test/test_pyexpat.py python/trunk/Misc/ACKS python/trunk/Misc/NEWS python/trunk/Modules/pyexpat.c Log: Patch 1137: allow assigning to .buffer_size attribute of PyExpat.parser objects Modified: python/trunk/Doc/library/pyexpat.rst ============================================================================== --- python/trunk/Doc/library/pyexpat.rst (original) +++ python/trunk/Doc/library/pyexpat.rst Tue Jan 8 15:30:55 2008 @@ -182,11 +182,15 @@ .. attribute:: xmlparser.buffer_size - The size of the buffer used when :attr:`buffer_text` is true. This value cannot - be changed at this time. + The size of the buffer used when :attr:`buffer_text` is true. + A new buffer size can be set by assigning a new integer value + to this attribute. + When the size is changed, the buffer will be flushed. .. versionadded:: 2.3 + .. versionchanged:: 2.6 + The buffer size can now be changed. .. attribute:: xmlparser.buffer_text Modified: python/trunk/Doc/whatsnew/2.6.rst ============================================================================== --- python/trunk/Doc/whatsnew/2.6.rst (original) +++ python/trunk/Doc/whatsnew/2.6.rst Tue Jan 8 15:30:55 2008 @@ -875,6 +875,13 @@ changed and :const:`UF_APPEND` to indicate that data can only be appended to the file. (Contributed by M. Levinson.) +* The :mod:`pyexpat` module's :class:`Parser` objects now allow setting + their :attr:`buffer_size` attribute to change the size of the buffer + used to hold character data. + (Contributed by Achim Gaedke.) + + .. Patch 1137 + * The :mod:`random` module's :class:`Random` objects can now be pickled on a 32-bit system and unpickled on a 64-bit system, and vice versa. Unfortunately, this change also means Modified: python/trunk/Lib/test/test_pyexpat.py ============================================================================== --- python/trunk/Lib/test/test_pyexpat.py (original) +++ python/trunk/Lib/test/test_pyexpat.py Tue Jan 8 15:30:55 2008 @@ -1,7 +1,7 @@ # XXX TypeErrors on calling handlers, or on bad return values from a # handler, are obscure and unhelpful. -import StringIO +import StringIO, sys import unittest import pyexpat @@ -434,6 +434,131 @@ self.assertRaises(Exception, parser.Parse, xml) +class ChardataBufferTest(unittest.TestCase): + """ + test setting of chardata buffer size + """ + + def test_1025_bytes(self): + self.assertEquals(self.small_buffer_test(1025), 2) + + def test_1000_bytes(self): + self.assertEquals(self.small_buffer_test(1000), 1) + + def test_wrong_size(self): + parser = expat.ParserCreate() + parser.buffer_text = 1 + def f(size): + parser.buffer_size = size + + self.assertRaises(TypeError, f, sys.maxint+1) + self.assertRaises(ValueError, f, -1) + self.assertRaises(ValueError, f, 0) + + def test_unchanged_size(self): + xml1 = ("%s" % ('a' * 512)) + xml2 = 'a'*512 + '' + parser = expat.ParserCreate() + parser.CharacterDataHandler = self.counting_handler + parser.buffer_size = 512 + parser.buffer_text = 1 + + # Feed 512 bytes of character data: the handler should be called + # once. + self.n = 0 + parser.Parse(xml1) + self.assertEquals(self.n, 1) + + # Reassign to buffer_size, but assign the same size. + parser.buffer_size = parser.buffer_size + self.assertEquals(self.n, 1) + + # Try parsing rest of the document + parser.Parse(xml2) + self.assertEquals(self.n, 2) + + + def test_disabling_buffer(self): + xml1 = "%s" % ('a' * 512) + xml2 = ('b' * 1024) + xml3 = "%s" % ('c' * 1024) + parser = expat.ParserCreate() + parser.CharacterDataHandler = self.counting_handler + parser.buffer_text = 1 + parser.buffer_size = 1024 + self.assertEquals(parser.buffer_size, 1024) + + # Parse one chunk of XML + self.n = 0 + parser.Parse(xml1, 0) + self.assertEquals(parser.buffer_size, 1024) + self.assertEquals(self.n, 1) + + # Turn off buffering and parse the next chunk. + parser.buffer_text = 0 + self.assertFalse(parser.buffer_text) + self.assertEquals(parser.buffer_size, 1024) + for i in range(10): + parser.Parse(xml2, 0) + self.assertEquals(self.n, 11) + + parser.buffer_text = 1 + self.assertTrue(parser.buffer_text) + self.assertEquals(parser.buffer_size, 1024) + parser.Parse(xml3, 1) + self.assertEquals(self.n, 12) + + + + def make_document(self, bytes): + return ("" + bytes * 'a' + '') + + def counting_handler(self, text): + self.n += 1 + + def small_buffer_test(self, buffer_len): + xml = "%s" % ('a' * buffer_len) + parser = expat.ParserCreate() + parser.CharacterDataHandler = self.counting_handler + parser.buffer_size = 1024 + parser.buffer_text = 1 + + self.n = 0 + parser.Parse(xml) + return self.n + + def test_change_size_1(self): + xml1 = "%s" % ('a' * 1024) + xml2 = "aaa%s" % ('a' * 1025) + parser = expat.ParserCreate() + parser.CharacterDataHandler = self.counting_handler + parser.buffer_text = 1 + parser.buffer_size = 1024 + self.assertEquals(parser.buffer_size, 1024) + + self.n = 0 + parser.Parse(xml1, 0) + parser.buffer_size *= 2 + self.assertEquals(parser.buffer_size, 2048) + parser.Parse(xml2, 1) + self.assertEquals(self.n, 2) + + def test_change_size_2(self): + xml1 = "a%s" % ('a' * 1023) + xml2 = "aaa%s" % ('a' * 1025) + parser = expat.ParserCreate() + parser.CharacterDataHandler = self.counting_handler + parser.buffer_text = 1 + parser.buffer_size = 2048 + self.assertEquals(parser.buffer_size, 2048) + + self.n=0 + parser.Parse(xml1, 0) + parser.buffer_size /= 2 + self.assertEquals(parser.buffer_size, 1024) + parser.Parse(xml2, 1) + self.assertEquals(self.n, 4) + def test_main(): run_unittest(SetAttributeTest, @@ -443,7 +568,8 @@ BufferTextTest, HandlerExceptionTest, PositionTest, - sf1296433Test) + sf1296433Test, + ChardataBufferTest) if __name__ == "__main__": test_main() Modified: python/trunk/Misc/ACKS ============================================================================== --- python/trunk/Misc/ACKS (original) +++ python/trunk/Misc/ACKS Tue Jan 8 15:30:55 2008 @@ -225,6 +225,7 @@ Peter Funk Geoff Furnish Ulisses Furquim +Achim Gaedke Lele Gaifax Santiago Gala Yitzchak Gale Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Tue Jan 8 15:30:55 2008 @@ -348,6 +348,9 @@ Library ------- +- pyexpat, patch #1137: allow setting buffer_size attribute + on Parser objects to set the character data buffer size. + - Issue #1757: The hash of a Decimal instance is no longer affected by the current context. Modified: python/trunk/Modules/pyexpat.c ============================================================================== --- python/trunk/Modules/pyexpat.c (original) +++ python/trunk/Modules/pyexpat.c Tue Jan 8 15:30:55 2008 @@ -1649,6 +1649,50 @@ self->specified_attributes = 0; return 0; } + + if (strcmp(name, "buffer_size") == 0) { + long new_buffer_size; + if (!PyInt_Check(v)) { + PyErr_SetString(PyExc_TypeError, "buffer_size must be an integer"); + return -1; + } + + new_buffer_size=PyInt_AS_LONG(v); + /* trivial case -- no change */ + if (new_buffer_size == self->buffer_size) { + return 0; + } + + if (new_buffer_size <= 0) { + PyErr_SetString(PyExc_ValueError, "buffer_size must be greater than zero"); + return -1; + } + + /* check maximum */ + if (new_buffer_size > INT_MAX) { + char errmsg[100]; + sprintf(errmsg, "buffer_size must not be greater than %i", INT_MAX); + PyErr_SetString(PyExc_ValueError, errmsg); + return -1; + } + + if (self->buffer != NULL) { + /* there is already a buffer */ + if (self->buffer_used != 0) { + flush_character_buffer(self); + } + /* free existing buffer */ + free(self->buffer); + } + self->buffer = malloc(new_buffer_size); + if (self->buffer == NULL) { + PyErr_NoMemory(); + return -1; + } + self->buffer_size = new_buffer_size; + return 0; + } + if (strcmp(name, "CharacterDataHandler") == 0) { /* If we're changing the character data handler, flush all * cached data with the old handler. Not sure there's a From python-checkins at python.org Tue Jan 8 15:56:03 2008 From: python-checkins at python.org (andrew.kuchling) Date: Tue, 8 Jan 2008 15:56:03 +0100 (CET) Subject: [Python-checkins] r59854 - in python/trunk: Misc/NEWS Modules/_cursesmodule.c Message-ID: <20080108145603.3D0B01E402D@bag.python.org> Author: andrew.kuchling Date: Tue Jan 8 15:56:02 2008 New Revision: 59854 Modified: python/trunk/Misc/NEWS python/trunk/Modules/_cursesmodule.c Log: Patch 1114: fix compilation of curses module on 64-bit AIX, and any other LP64 platforms where attr_t isn't a C long Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Tue Jan 8 15:56:02 2008 @@ -1060,6 +1060,10 @@ - Bug #1548092: fix curses.tparm seg fault on invalid input. +- Patch #1114: fix curses module compilation on 64-bit AIX, & possibly + other 64-bit LP64 platforms where attr_t is not the same size as a long. + (Contributed by Luke Mewburn.) + - Bug #1550714: fix SystemError from itertools.tee on negative value for n. - Fixed a few bugs on cjkcodecs: Modified: python/trunk/Modules/_cursesmodule.c ============================================================================== --- python/trunk/Modules/_cursesmodule.c (original) +++ python/trunk/Modules/_cursesmodule.c Tue Jan 8 15:56:02 2008 @@ -315,9 +315,6 @@ Window_NoArg2TupleReturnFunction(getmaxyx, int, "ii") Window_NoArg2TupleReturnFunction(getparyx, int, "ii") -Window_OneArgNoReturnFunction(wattron, attr_t, "l;attr") -Window_OneArgNoReturnFunction(wattroff, attr_t, "l;attr") -Window_OneArgNoReturnFunction(wattrset, attr_t, "l;attr") Window_OneArgNoReturnFunction(clearok, int, "i;True(1) or False(0)") Window_OneArgNoReturnFunction(idlok, int, "i;True(1) or False(0)") #if defined(__NetBSD__) @@ -372,6 +369,7 @@ PyObject *temp; chtype ch = 0; attr_t attr = A_NORMAL; + long lattr; switch (PyTuple_Size(args)) { case 1: @@ -379,8 +377,9 @@ return NULL; break; case 2: - if (!PyArg_ParseTuple(args, "Ol;ch or int,attr", &temp, &attr)) + if (!PyArg_ParseTuple(args, "Ol;ch or int,attr", &temp, &lattr)) return NULL; + attr = lattr; break; case 3: if (!PyArg_ParseTuple(args,"iiO;y,x,ch or int", &y, &x, &temp)) @@ -389,8 +388,9 @@ break; case 4: if (!PyArg_ParseTuple(args,"iiOl;y,x,ch or int, attr", - &y, &x, &temp, &attr)) + &y, &x, &temp, &lattr)) return NULL; + attr = lattr; use_xy = TRUE; break; default: @@ -418,6 +418,7 @@ int x, y; char *str; attr_t attr = A_NORMAL , attr_old = A_NORMAL; + long lattr; int use_xy = FALSE, use_attr = FALSE; switch (PyTuple_Size(args)) { @@ -426,8 +427,9 @@ return NULL; break; case 2: - if (!PyArg_ParseTuple(args,"sl;str,attr", &str, &attr)) + if (!PyArg_ParseTuple(args,"sl;str,attr", &str, &lattr)) return NULL; + attr = lattr; use_attr = TRUE; break; case 3: @@ -436,8 +438,9 @@ use_xy = TRUE; break; case 4: - if (!PyArg_ParseTuple(args,"iisl;int,int,str,attr", &y, &x, &str, &attr)) + if (!PyArg_ParseTuple(args,"iisl;int,int,str,attr", &y, &x, &str, &lattr)) return NULL; + attr = lattr; use_xy = use_attr = TRUE; break; default: @@ -464,6 +467,7 @@ int rtn, x, y, n; char *str; attr_t attr = A_NORMAL , attr_old = A_NORMAL; + long lattr; int use_xy = FALSE, use_attr = FALSE; switch (PyTuple_Size(args)) { @@ -472,8 +476,9 @@ return NULL; break; case 3: - if (!PyArg_ParseTuple(args,"sil;str,n,attr", &str, &n, &attr)) + if (!PyArg_ParseTuple(args,"sil;str,n,attr", &str, &n, &lattr)) return NULL; + attr = lattr; use_attr = TRUE; break; case 4: @@ -482,8 +487,9 @@ use_xy = TRUE; break; case 5: - if (!PyArg_ParseTuple(args,"iisil;y,x,str,n,attr", &y, &x, &str, &n, &attr)) + if (!PyArg_ParseTuple(args,"iisil;y,x,str,n,attr", &y, &x, &str, &n, &lattr)) return NULL; + attr = lattr; use_xy = use_attr = TRUE; break; default: @@ -510,6 +516,7 @@ PyObject *temp; chtype bkgd; attr_t attr = A_NORMAL; + long lattr; switch (PyTuple_Size(args)) { case 1: @@ -517,8 +524,9 @@ return NULL; break; case 2: - if (!PyArg_ParseTuple(args,"Ol;ch or int,attr", &temp, &attr)) + if (!PyArg_ParseTuple(args,"Ol;ch or int,attr", &temp, &lattr)) return NULL; + attr = lattr; break; default: PyErr_SetString(PyExc_TypeError, "bkgd requires 1 or 2 arguments"); @@ -534,11 +542,39 @@ } static PyObject * +PyCursesWindow_AttrOff(PyCursesWindowObject *self, PyObject *args) +{ + long lattr; + if (!PyArg_ParseTuple(args,"l;attr", &lattr)) + return NULL; + return PyCursesCheckERR(wattroff(self->win, (attr_t)lattr), "attroff"); +} + +static PyObject * +PyCursesWindow_AttrOn(PyCursesWindowObject *self, PyObject *args) +{ + long lattr; + if (!PyArg_ParseTuple(args,"l;attr", &lattr)) + return NULL; + return PyCursesCheckERR(wattron(self->win, (attr_t)lattr), "attron"); +} + +static PyObject * +PyCursesWindow_AttrSet(PyCursesWindowObject *self, PyObject *args) +{ + long lattr; + if (!PyArg_ParseTuple(args,"l;attr", &lattr)) + return NULL; + return PyCursesCheckERR(wattrset(self->win, (attr_t)lattr), "attrset"); +} + +static PyObject * PyCursesWindow_BkgdSet(PyCursesWindowObject *self, PyObject *args) { PyObject *temp; chtype bkgd; attr_t attr = A_NORMAL; + long lattr; switch (PyTuple_Size(args)) { case 1: @@ -546,8 +582,9 @@ return NULL; break; case 2: - if (!PyArg_ParseTuple(args,"Ol;ch or int,attr", &temp, &attr)) + if (!PyArg_ParseTuple(args,"Ol;ch or int,attr", &temp, &lattr)) return NULL; + attr = lattr; break; default: PyErr_SetString(PyExc_TypeError, "bkgdset requires 1 or 2 arguments"); @@ -735,6 +772,7 @@ PyObject *temp; chtype ch; attr_t attr = A_NORMAL; + long lattr; switch (PyTuple_Size(args)) { case 1: @@ -742,8 +780,9 @@ return NULL; break; case 2: - if (!PyArg_ParseTuple(args,"Ol;ch or int,attr", &temp, &attr)) + if (!PyArg_ParseTuple(args,"Ol;ch or int,attr", &temp, &lattr)) return NULL; + attr = lattr; break; default: PyErr_SetString(PyExc_TypeError, "echochar requires 1 or 2 arguments"); @@ -909,6 +948,7 @@ chtype ch; int n, x, y, code = OK; attr_t attr = A_NORMAL; + long lattr; switch (PyTuple_Size(args)) { case 2: @@ -916,8 +956,9 @@ return NULL; break; case 3: - if (!PyArg_ParseTuple(args, "Oil;ch or int,n,attr", &temp, &n, &attr)) + if (!PyArg_ParseTuple(args, "Oil;ch or int,n,attr", &temp, &n, &lattr)) return NULL; + attr = lattr; break; case 4: if (!PyArg_ParseTuple(args, "iiOi;y,x,ch or int,n", &y, &x, &temp, &n)) @@ -926,8 +967,9 @@ break; case 5: if (!PyArg_ParseTuple(args, "iiOil; y,x,ch or int,n,attr", - &y, &x, &temp, &n, &attr)) + &y, &x, &temp, &n, &lattr)) return NULL; + attr = lattr; code = wmove(self->win, y, x); break; default: @@ -953,6 +995,7 @@ PyObject *temp; chtype ch = 0; attr_t attr = A_NORMAL; + long lattr; switch (PyTuple_Size(args)) { case 1: @@ -960,8 +1003,9 @@ return NULL; break; case 2: - if (!PyArg_ParseTuple(args, "Ol;ch or int,attr", &temp, &attr)) + if (!PyArg_ParseTuple(args, "Ol;ch or int,attr", &temp, &lattr)) return NULL; + attr = lattr; break; case 3: if (!PyArg_ParseTuple(args,"iiO;y,x,ch or int", &y, &x, &temp)) @@ -969,8 +1013,9 @@ use_xy = TRUE; break; case 4: - if (!PyArg_ParseTuple(args,"iiOl;y,x,ch or int, attr", &y, &x, &temp, &attr)) + if (!PyArg_ParseTuple(args,"iiOl;y,x,ch or int, attr", &y, &x, &temp, &lattr)) return NULL; + attr = lattr; use_xy = TRUE; break; default: @@ -1055,6 +1100,7 @@ int x, y; char *str; attr_t attr = A_NORMAL , attr_old = A_NORMAL; + long lattr; int use_xy = FALSE, use_attr = FALSE; switch (PyTuple_Size(args)) { @@ -1063,8 +1109,9 @@ return NULL; break; case 2: - if (!PyArg_ParseTuple(args,"sl;str,attr", &str, &attr)) + if (!PyArg_ParseTuple(args,"sl;str,attr", &str, &lattr)) return NULL; + attr = lattr; use_attr = TRUE; break; case 3: @@ -1073,8 +1120,9 @@ use_xy = TRUE; break; case 4: - if (!PyArg_ParseTuple(args,"iisl;y,x,str,attr", &y, &x, &str, &attr)) + if (!PyArg_ParseTuple(args,"iisl;y,x,str,attr", &y, &x, &str, &lattr)) return NULL; + attr = lattr; use_xy = use_attr = TRUE; break; default: @@ -1101,6 +1149,7 @@ int rtn, x, y, n; char *str; attr_t attr = A_NORMAL , attr_old = A_NORMAL; + long lattr; int use_xy = FALSE, use_attr = FALSE; switch (PyTuple_Size(args)) { @@ -1109,8 +1158,9 @@ return NULL; break; case 3: - if (!PyArg_ParseTuple(args,"sil;str,n,attr", &str, &n, &attr)) + if (!PyArg_ParseTuple(args,"sil;str,n,attr", &str, &n, &lattr)) return NULL; + attr = lattr; use_attr = TRUE; break; case 4: @@ -1119,8 +1169,9 @@ use_xy = TRUE; break; case 5: - if (!PyArg_ParseTuple(args,"iisil;y,x,str,n,attr", &y, &x, &str, &n, &attr)) + if (!PyArg_ParseTuple(args,"iisil;y,x,str,n,attr", &y, &x, &str, &n, &lattr)) return NULL; + attr = lattr; use_xy = use_attr = TRUE; break; default: @@ -1436,6 +1487,7 @@ chtype ch; int n, x, y, code = OK; attr_t attr = A_NORMAL; + long lattr; switch (PyTuple_Size(args)) { case 2: @@ -1443,8 +1495,9 @@ return NULL; break; case 3: - if (!PyArg_ParseTuple(args, "Oil;ch or int,n,attr", &temp, &n, &attr)) + if (!PyArg_ParseTuple(args, "Oil;ch or int,n,attr", &temp, &n, &lattr)) return NULL; + attr = lattr; break; case 4: if (!PyArg_ParseTuple(args, "iiOi;y,x,ch or int,n", &y, &x, &temp, &n)) @@ -1453,8 +1506,9 @@ break; case 5: if (!PyArg_ParseTuple(args, "iiOil; y,x,ch or int,n,attr", - &y, &x, &temp, &n, &attr)) + &y, &x, &temp, &n, &lattr)) return NULL; + attr = lattr; code = wmove(self->win, y, x); break; default: @@ -1477,9 +1531,9 @@ {"addch", (PyCFunction)PyCursesWindow_AddCh, METH_VARARGS}, {"addnstr", (PyCFunction)PyCursesWindow_AddNStr, METH_VARARGS}, {"addstr", (PyCFunction)PyCursesWindow_AddStr, METH_VARARGS}, - {"attroff", (PyCFunction)PyCursesWindow_wattroff, METH_VARARGS}, - {"attron", (PyCFunction)PyCursesWindow_wattron, METH_VARARGS}, - {"attrset", (PyCFunction)PyCursesWindow_wattrset, METH_VARARGS}, + {"attroff", (PyCFunction)PyCursesWindow_AttrOff, METH_VARARGS}, + {"attron", (PyCFunction)PyCursesWindow_AttrOn, METH_VARARGS}, + {"attrset", (PyCFunction)PyCursesWindow_AttrSet, METH_VARARGS}, {"bkgd", (PyCFunction)PyCursesWindow_Bkgd, METH_VARARGS}, {"chgat", (PyCFunction)PyCursesWindow_ChgAt, METH_VARARGS}, {"bkgdset", (PyCFunction)PyCursesWindow_BkgdSet, METH_VARARGS}, From python-checkins at python.org Tue Jan 8 15:58:53 2008 From: python-checkins at python.org (andrew.kuchling) Date: Tue, 8 Jan 2008 15:58:53 +0100 (CET) Subject: [Python-checkins] r59855 - in python/branches/release25-maint: Misc/NEWS Modules/_cursesmodule.c Message-ID: <20080108145853.5D18C1E4005@bag.python.org> Author: andrew.kuchling Date: Tue Jan 8 15:58:52 2008 New Revision: 59855 Modified: python/branches/release25-maint/Misc/NEWS python/branches/release25-maint/Modules/_cursesmodule.c Log: Patch 1114: fix compilation of curses module on 64-bit AIX, and any other LP64 platforms where attr_t isn't a C long Modified: python/branches/release25-maint/Misc/NEWS ============================================================================== --- python/branches/release25-maint/Misc/NEWS (original) +++ python/branches/release25-maint/Misc/NEWS Tue Jan 8 15:58:52 2008 @@ -166,6 +166,10 @@ - Bug #1301: Bad assert in _tkinter fixed. +- Patch #1114: fix curses module compilation on 64-bit AIX, & possibly + other 64-bit LP64 platforms where attr_t is not the same size as a long. + (Contributed by Luke Mewburn.) + - Bug #1649098: Avoid declaration of zero-sized array declaration in structure. Modified: python/branches/release25-maint/Modules/_cursesmodule.c ============================================================================== --- python/branches/release25-maint/Modules/_cursesmodule.c (original) +++ python/branches/release25-maint/Modules/_cursesmodule.c Tue Jan 8 15:58:52 2008 @@ -312,9 +312,6 @@ Window_NoArg2TupleReturnFunction(getmaxyx, int, "ii") Window_NoArg2TupleReturnFunction(getparyx, int, "ii") -Window_OneArgNoReturnFunction(wattron, attr_t, "l;attr") -Window_OneArgNoReturnFunction(wattroff, attr_t, "l;attr") -Window_OneArgNoReturnFunction(wattrset, attr_t, "l;attr") Window_OneArgNoReturnFunction(clearok, int, "i;True(1) or False(0)") Window_OneArgNoReturnFunction(idlok, int, "i;True(1) or False(0)") #if defined(__NetBSD__) @@ -369,6 +366,7 @@ PyObject *temp; chtype ch = 0; attr_t attr = A_NORMAL; + long lattr; switch (PyTuple_Size(args)) { case 1: @@ -376,8 +374,9 @@ return NULL; break; case 2: - if (!PyArg_ParseTuple(args, "Ol;ch or int,attr", &temp, &attr)) + if (!PyArg_ParseTuple(args, "Ol;ch or int,attr", &temp, &lattr)) return NULL; + attr = lattr; break; case 3: if (!PyArg_ParseTuple(args,"iiO;y,x,ch or int", &y, &x, &temp)) @@ -386,8 +385,9 @@ break; case 4: if (!PyArg_ParseTuple(args,"iiOl;y,x,ch or int, attr", - &y, &x, &temp, &attr)) + &y, &x, &temp, &lattr)) return NULL; + attr = lattr; use_xy = TRUE; break; default: @@ -415,6 +415,7 @@ int x, y; char *str; attr_t attr = A_NORMAL , attr_old = A_NORMAL; + long lattr; int use_xy = FALSE, use_attr = FALSE; switch (PyTuple_Size(args)) { @@ -423,8 +424,9 @@ return NULL; break; case 2: - if (!PyArg_ParseTuple(args,"sl;str,attr", &str, &attr)) + if (!PyArg_ParseTuple(args,"sl;str,attr", &str, &lattr)) return NULL; + attr = lattr; use_attr = TRUE; break; case 3: @@ -433,8 +435,9 @@ use_xy = TRUE; break; case 4: - if (!PyArg_ParseTuple(args,"iisl;int,int,str,attr", &y, &x, &str, &attr)) + if (!PyArg_ParseTuple(args,"iisl;int,int,str,attr", &y, &x, &str, &lattr)) return NULL; + attr = lattr; use_xy = use_attr = TRUE; break; default: @@ -461,6 +464,7 @@ int rtn, x, y, n; char *str; attr_t attr = A_NORMAL , attr_old = A_NORMAL; + long lattr; int use_xy = FALSE, use_attr = FALSE; switch (PyTuple_Size(args)) { @@ -469,8 +473,9 @@ return NULL; break; case 3: - if (!PyArg_ParseTuple(args,"sil;str,n,attr", &str, &n, &attr)) + if (!PyArg_ParseTuple(args,"sil;str,n,attr", &str, &n, &lattr)) return NULL; + attr = lattr; use_attr = TRUE; break; case 4: @@ -479,8 +484,9 @@ use_xy = TRUE; break; case 5: - if (!PyArg_ParseTuple(args,"iisil;y,x,str,n,attr", &y, &x, &str, &n, &attr)) + if (!PyArg_ParseTuple(args,"iisil;y,x,str,n,attr", &y, &x, &str, &n, &lattr)) return NULL; + attr = lattr; use_xy = use_attr = TRUE; break; default: @@ -507,6 +513,7 @@ PyObject *temp; chtype bkgd; attr_t attr = A_NORMAL; + long lattr; switch (PyTuple_Size(args)) { case 1: @@ -514,8 +521,9 @@ return NULL; break; case 2: - if (!PyArg_ParseTuple(args,"Ol;ch or int,attr", &temp, &attr)) + if (!PyArg_ParseTuple(args,"Ol;ch or int,attr", &temp, &lattr)) return NULL; + attr = lattr; break; default: PyErr_SetString(PyExc_TypeError, "bkgd requires 1 or 2 arguments"); @@ -531,11 +539,39 @@ } static PyObject * +PyCursesWindow_AttrOff(PyCursesWindowObject *self, PyObject *args) +{ + long lattr; + if (!PyArg_ParseTuple(args,"l;attr", &lattr)) + return NULL; + return PyCursesCheckERR(wattroff(self->win, (attr_t)lattr), "attroff"); +} + +static PyObject * +PyCursesWindow_AttrOn(PyCursesWindowObject *self, PyObject *args) +{ + long lattr; + if (!PyArg_ParseTuple(args,"l;attr", &lattr)) + return NULL; + return PyCursesCheckERR(wattron(self->win, (attr_t)lattr), "attron"); +} + +static PyObject * +PyCursesWindow_AttrSet(PyCursesWindowObject *self, PyObject *args) +{ + long lattr; + if (!PyArg_ParseTuple(args,"l;attr", &lattr)) + return NULL; + return PyCursesCheckERR(wattrset(self->win, (attr_t)lattr), "attrset"); +} + +static PyObject * PyCursesWindow_BkgdSet(PyCursesWindowObject *self, PyObject *args) { PyObject *temp; chtype bkgd; attr_t attr = A_NORMAL; + long lattr; switch (PyTuple_Size(args)) { case 1: @@ -543,8 +579,9 @@ return NULL; break; case 2: - if (!PyArg_ParseTuple(args,"Ol;ch or int,attr", &temp, &attr)) + if (!PyArg_ParseTuple(args,"Ol;ch or int,attr", &temp, &lattr)) return NULL; + attr = lattr; break; default: PyErr_SetString(PyExc_TypeError, "bkgdset requires 1 or 2 arguments"); @@ -682,6 +719,7 @@ PyObject *temp; chtype ch; attr_t attr = A_NORMAL; + long lattr; switch (PyTuple_Size(args)) { case 1: @@ -689,8 +727,9 @@ return NULL; break; case 2: - if (!PyArg_ParseTuple(args,"Ol;ch or int,attr", &temp, &attr)) + if (!PyArg_ParseTuple(args,"Ol;ch or int,attr", &temp, &lattr)) return NULL; + attr = lattr; break; default: PyErr_SetString(PyExc_TypeError, "echochar requires 1 or 2 arguments"); @@ -856,6 +895,7 @@ chtype ch; int n, x, y, code = OK; attr_t attr = A_NORMAL; + long lattr; switch (PyTuple_Size(args)) { case 2: @@ -863,8 +903,9 @@ return NULL; break; case 3: - if (!PyArg_ParseTuple(args, "Oil;ch or int,n,attr", &temp, &n, &attr)) + if (!PyArg_ParseTuple(args, "Oil;ch or int,n,attr", &temp, &n, &lattr)) return NULL; + attr = lattr; break; case 4: if (!PyArg_ParseTuple(args, "iiOi;y,x,ch or int,n", &y, &x, &temp, &n)) @@ -873,8 +914,9 @@ break; case 5: if (!PyArg_ParseTuple(args, "iiOil; y,x,ch or int,n,attr", - &y, &x, &temp, &n, &attr)) + &y, &x, &temp, &n, &lattr)) return NULL; + attr = lattr; code = wmove(self->win, y, x); break; default: @@ -900,6 +942,7 @@ PyObject *temp; chtype ch = 0; attr_t attr = A_NORMAL; + long lattr; switch (PyTuple_Size(args)) { case 1: @@ -907,8 +950,9 @@ return NULL; break; case 2: - if (!PyArg_ParseTuple(args, "Ol;ch or int,attr", &temp, &attr)) + if (!PyArg_ParseTuple(args, "Ol;ch or int,attr", &temp, &lattr)) return NULL; + attr = lattr; break; case 3: if (!PyArg_ParseTuple(args,"iiO;y,x,ch or int", &y, &x, &temp)) @@ -916,8 +960,9 @@ use_xy = TRUE; break; case 4: - if (!PyArg_ParseTuple(args,"iiOl;y,x,ch or int, attr", &y, &x, &temp, &attr)) + if (!PyArg_ParseTuple(args,"iiOl;y,x,ch or int, attr", &y, &x, &temp, &lattr)) return NULL; + attr = lattr; use_xy = TRUE; break; default: @@ -1002,6 +1047,7 @@ int x, y; char *str; attr_t attr = A_NORMAL , attr_old = A_NORMAL; + long lattr; int use_xy = FALSE, use_attr = FALSE; switch (PyTuple_Size(args)) { @@ -1010,8 +1056,9 @@ return NULL; break; case 2: - if (!PyArg_ParseTuple(args,"sl;str,attr", &str, &attr)) + if (!PyArg_ParseTuple(args,"sl;str,attr", &str, &lattr)) return NULL; + attr = lattr; use_attr = TRUE; break; case 3: @@ -1020,8 +1067,9 @@ use_xy = TRUE; break; case 4: - if (!PyArg_ParseTuple(args,"iisl;y,x,str,attr", &y, &x, &str, &attr)) + if (!PyArg_ParseTuple(args,"iisl;y,x,str,attr", &y, &x, &str, &lattr)) return NULL; + attr = lattr; use_xy = use_attr = TRUE; break; default: @@ -1048,6 +1096,7 @@ int rtn, x, y, n; char *str; attr_t attr = A_NORMAL , attr_old = A_NORMAL; + long lattr; int use_xy = FALSE, use_attr = FALSE; switch (PyTuple_Size(args)) { @@ -1056,8 +1105,9 @@ return NULL; break; case 3: - if (!PyArg_ParseTuple(args,"sil;str,n,attr", &str, &n, &attr)) + if (!PyArg_ParseTuple(args,"sil;str,n,attr", &str, &n, &lattr)) return NULL; + attr = lattr; use_attr = TRUE; break; case 4: @@ -1066,8 +1116,9 @@ use_xy = TRUE; break; case 5: - if (!PyArg_ParseTuple(args,"iisil;y,x,str,n,attr", &y, &x, &str, &n, &attr)) + if (!PyArg_ParseTuple(args,"iisil;y,x,str,n,attr", &y, &x, &str, &n, &lattr)) return NULL; + attr = lattr; use_xy = use_attr = TRUE; break; default: @@ -1383,6 +1434,7 @@ chtype ch; int n, x, y, code = OK; attr_t attr = A_NORMAL; + long lattr; switch (PyTuple_Size(args)) { case 2: @@ -1390,8 +1442,9 @@ return NULL; break; case 3: - if (!PyArg_ParseTuple(args, "Oil;ch or int,n,attr", &temp, &n, &attr)) + if (!PyArg_ParseTuple(args, "Oil;ch or int,n,attr", &temp, &n, &lattr)) return NULL; + attr = lattr; break; case 4: if (!PyArg_ParseTuple(args, "iiOi;y,x,ch or int,n", &y, &x, &temp, &n)) @@ -1400,8 +1453,9 @@ break; case 5: if (!PyArg_ParseTuple(args, "iiOil; y,x,ch or int,n,attr", - &y, &x, &temp, &n, &attr)) + &y, &x, &temp, &n, &lattr)) return NULL; + attr = lattr; code = wmove(self->win, y, x); break; default: @@ -1424,9 +1478,9 @@ {"addch", (PyCFunction)PyCursesWindow_AddCh, METH_VARARGS}, {"addnstr", (PyCFunction)PyCursesWindow_AddNStr, METH_VARARGS}, {"addstr", (PyCFunction)PyCursesWindow_AddStr, METH_VARARGS}, - {"attroff", (PyCFunction)PyCursesWindow_wattroff, METH_VARARGS}, - {"attron", (PyCFunction)PyCursesWindow_wattron, METH_VARARGS}, - {"attrset", (PyCFunction)PyCursesWindow_wattrset, METH_VARARGS}, + {"attroff", (PyCFunction)PyCursesWindow_AttrOff, METH_VARARGS}, + {"attron", (PyCFunction)PyCursesWindow_AttrOn, METH_VARARGS}, + {"attrset", (PyCFunction)PyCursesWindow_AttrSet, METH_VARARGS}, {"bkgd", (PyCFunction)PyCursesWindow_Bkgd, METH_VARARGS}, {"bkgdset", (PyCFunction)PyCursesWindow_BkgdSet, METH_VARARGS}, {"border", (PyCFunction)PyCursesWindow_Border, METH_VARARGS}, From python-checkins at python.org Tue Jan 8 16:15:09 2008 From: python-checkins at python.org (thomas.heller) Date: Tue, 8 Jan 2008 16:15:09 +0100 (CET) Subject: [Python-checkins] r59856 - python/trunk/Modules/_ctypes/callbacks.c python/trunk/Modules/_ctypes/callproc.c Message-ID: <20080108151509.C87891E4005@bag.python.org> Author: thomas.heller Date: Tue Jan 8 16:15:09 2008 New Revision: 59856 Modified: python/trunk/Modules/_ctypes/callbacks.c python/trunk/Modules/_ctypes/callproc.c Log: Use relative instead of absolute filenames in the C-level tracebacks. This prevents traceback prints pointing to files in this way: File "\loewis\25\python\Modules\_ctypes\callbacks.c", line 206, in 'calling callback function' Modified: python/trunk/Modules/_ctypes/callbacks.c ============================================================================== --- python/trunk/Modules/_ctypes/callbacks.c (original) +++ python/trunk/Modules/_ctypes/callbacks.c Tue Jan 8 16:15:09 2008 @@ -201,7 +201,7 @@ } #define CHECK(what, x) \ -if (x == NULL) _AddTraceback(what, __FILE__, __LINE__ - 1), PyErr_Print() +if (x == NULL) _AddTraceback(what, "_ctypes/callbacks.c", __LINE__ - 1), PyErr_Print() result = PyObject_CallObject(callable, arglist); CHECK("'calling callback function'", result); Modified: python/trunk/Modules/_ctypes/callproc.c ============================================================================== --- python/trunk/Modules/_ctypes/callproc.c (original) +++ python/trunk/Modules/_ctypes/callproc.c Tue Jan 8 16:15:09 2008 @@ -766,7 +766,7 @@ v = PyObject_CallFunctionObjArgs(checker, retval, NULL); if (v == NULL) - _AddTraceback("GetResult", __FILE__, __LINE__-2); + _AddTraceback("GetResult", "_ctypes/callproc.c", __LINE__-2); Py_DECREF(retval); return v; } From python-checkins at python.org Tue Jan 8 16:46:11 2008 From: python-checkins at python.org (christian.heimes) Date: Tue, 8 Jan 2008 16:46:11 +0100 (CET) Subject: [Python-checkins] r59857 - in python/trunk: Doc/library/_winreg.rst Lib/test/test_winreg.py Misc/NEWS PC/_winreg.c Message-ID: <20080108154611.6621D1E4016@bag.python.org> Author: christian.heimes Date: Tue Jan 8 16:46:10 2008 New Revision: 59857 Modified: python/trunk/Doc/library/_winreg.rst python/trunk/Lib/test/test_winreg.py python/trunk/Misc/NEWS python/trunk/PC/_winreg.c Log: Added __enter__ and __exit__ functions to HKEY object Added ExpandEnvironmentStrings to the _winreg module. Modified: python/trunk/Doc/library/_winreg.rst ============================================================================== --- python/trunk/Doc/library/_winreg.rst (original) +++ python/trunk/Doc/library/_winreg.rst Tue Jan 8 16:46:10 2008 @@ -133,6 +133,16 @@ +-------+--------------------------------------------+ +.. function:: ExpandEnvironmentStrings(unicode) + + Expands environment strings %NAME% in unicode string like const:`REG_EXPAND_SZ`:: + + >>> ExpandEnvironmentStrings(u"%windir%") + u"C:\\Windows" + + .. versionadded: 2.6 + + .. function:: FlushKey(key) Writes all the attributes of a key to the registry. @@ -418,3 +428,11 @@ handle is not closed. You would call this function when you need the underlying Win32 handle to exist beyond the lifetime of the handle object. +.. method:: PyHKEY.__enter__() +.. method:: PyHKEY.__exit__(*exc_info) + + The HKEY object implements __enter__ and __exit__ and thus supports the + context protocol for the with statement. + + .. versionadded: 2.6 + Modified: python/trunk/Lib/test/test_winreg.py ============================================================================== --- python/trunk/Lib/test/test_winreg.py (original) +++ python/trunk/Lib/test/test_winreg.py Tue Jan 8 16:46:10 2008 @@ -80,26 +80,26 @@ key = OpenKey(root_key, test_key_name) # Read the sub-keys - sub_key = OpenKey(key, "sub_key") - # Check I can enumerate over the values. - index = 0 - while 1: - try: - data = EnumValue(sub_key, index) - except EnvironmentError: - break - self.assertEquals(data in test_data, True, - "Didn't read back the correct test data") - index = index + 1 - self.assertEquals(index, len(test_data), - "Didn't read the correct number of items") - # Check I can directly access each item - for value_name, value_data, value_type in test_data: - read_val, read_typ = QueryValueEx(sub_key, value_name) - self.assertEquals(read_val, value_data, - "Could not directly read the value") - self.assertEquals(read_typ, value_type, - "Could not directly read the value") + with OpenKey(key, "sub_key") as sub_key: + # Check I can enumerate over the values. + index = 0 + while 1: + try: + data = EnumValue(sub_key, index) + except EnvironmentError: + break + self.assertEquals(data in test_data, True, + "Didn't read back the correct test data") + index = index + 1 + self.assertEquals(index, len(test_data), + "Didn't read the correct number of items") + # Check I can directly access each item + for value_name, value_data, value_type in test_data: + read_val, read_typ = QueryValueEx(sub_key, value_name) + self.assertEquals(read_val, value_data, + "Could not directly read the value") + self.assertEquals(read_typ, value_type, + "Could not directly read the value") sub_key.Close() # Enumerate our main key. read_val = EnumKey(key, 0) @@ -161,6 +161,11 @@ remote_key = ConnectRegistry(self.remote_name, HKEY_CURRENT_USER) self.TestAll(remote_key) + def testExpandEnvironmentStrings(self): + r = ExpandEnvironmentStrings(u"%windir%\\test") + self.assertEqual(type(r), unicode) + self.assertEqual(r, os.environ["windir"] + "\\test") + def test_main(): test_support.run_unittest(WinregTests) Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Tue Jan 8 16:46:10 2008 @@ -944,6 +944,10 @@ Extension Modules ----------------- +- _winreg's HKEY object have gained __enter__ and __exit__ functions to support he + context manager protocol. The _winreg module also got a new function + ``ExpandEnvironmentStrings`` to expand REG_EXPAND_SZ keys. + - Issue #1646: Make socket support TIPC. The socket module now has support for TIPC under Linux, see http://tipc.sf.net/ for more information. Modified: python/trunk/PC/_winreg.c ============================================================================== --- python/trunk/PC/_winreg.c (original) +++ python/trunk/PC/_winreg.c Tue Jan 8 16:46:10 2008 @@ -47,6 +47,7 @@ "DeleteValue() - Removes a named value from the specified registry key.\n" "EnumKey() - Enumerates subkeys of the specified open registry key.\n" "EnumValue() - Enumerates values of the specified open registry key.\n" +"ExpandEnvironmentStrings() - Expand the env strings in a REG_EXPAND_SZ string.\n" "FlushKey() - Writes all the attributes of the specified key to the registry.\n" "LoadKey() - Creates a subkey under HKEY_USER or HKEY_LOCAL_MACHINE and stores\n" " registration information from a specified file into that subkey.\n" @@ -146,6 +147,9 @@ " on the underlying registry type.\n" "data_type is an integer that identifies the type of the value data."); +PyDoc_STRVAR(ExpandEnvironmentStrings_doc, +"string = ExpandEnvironmentStrings(string) - Expand environment vars.\n"); + PyDoc_STRVAR(FlushKey_doc, "FlushKey(key) - Writes all the attributes of a key to the registry.\n" "\n" @@ -518,9 +522,27 @@ return PyLong_FromVoidPtr(ret); } +static PyObject * +PyHKEY_Enter(PyObject *self) +{ + Py_XINCREF(self); + return self; +} + +static PyObject * +PyHKEY_Exit(PyObject *self, PyObject *args) +{ + if (!PyHKEY_Close(self)) + return NULL; + Py_RETURN_NONE; +} + + static struct PyMethodDef PyHKEY_methods[] = { {"Close", PyHKEY_CloseMethod, METH_VARARGS, PyHKEY_Close_doc}, {"Detach", PyHKEY_DetachMethod, METH_VARARGS, PyHKEY_Detach_doc}, + {"__enter__", (PyCFunction)PyHKEY_Enter, METH_NOARGS, NULL}, + {"__exit__", PyHKEY_Exit, METH_VARARGS, NULL}, {NULL} }; @@ -1118,6 +1140,39 @@ } static PyObject * +PyExpandEnvironmentStrings(PyObject *self, PyObject *args) +{ + Py_UNICODE *retValue = NULL; + Py_UNICODE *src; + DWORD retValueSize; + DWORD rc; + PyObject *o; + + if (!PyArg_ParseTuple(args, "u:ExpandEnvironmentStrings", &src)) + return NULL; + + retValueSize = ExpandEnvironmentStringsW(src, retValue, 0); + if (retValueSize == 0) { + return PyErr_SetFromWindowsErrWithFunction(retValueSize, + "ExpandEnvironmentStrings"); + } + retValue = (Py_UNICODE *)PyMem_Malloc(retValueSize * sizeof(Py_UNICODE)); + if (retValue == NULL) { + return PyErr_NoMemory(); + } + + rc = ExpandEnvironmentStringsW(src, retValue, retValueSize); + if (rc == 0) { + PyMem_Free(retValue); + return PyErr_SetFromWindowsErrWithFunction(retValueSize, + "ExpandEnvironmentStrings"); + } + o = PyUnicode_FromUnicode(retValue, wcslen(retValue)); + PyMem_Free(retValue); + return o; +} + +static PyObject * PyFlushKey(PyObject *self, PyObject *args) { HKEY hKey; @@ -1412,6 +1467,8 @@ {"DeleteValue", PyDeleteValue, METH_VARARGS, DeleteValue_doc}, {"EnumKey", PyEnumKey, METH_VARARGS, EnumKey_doc}, {"EnumValue", PyEnumValue, METH_VARARGS, EnumValue_doc}, + {"ExpandEnvironmentStrings", PyExpandEnvironmentStrings, METH_VARARGS, + ExpandEnvironmentStrings_doc }, {"FlushKey", PyFlushKey, METH_VARARGS, FlushKey_doc}, {"LoadKey", PyLoadKey, METH_VARARGS, LoadKey_doc}, {"OpenKey", PyOpenKey, METH_VARARGS, OpenKey_doc}, From python-checkins at python.org Tue Jan 8 17:18:26 2008 From: python-checkins at python.org (georg.brandl) Date: Tue, 8 Jan 2008 17:18:26 +0100 (CET) Subject: [Python-checkins] r59858 - python/trunk/Doc/library/_winreg.rst Message-ID: <20080108161826.681AB1E401F@bag.python.org> Author: georg.brandl Date: Tue Jan 8 17:18:26 2008 New Revision: 59858 Modified: python/trunk/Doc/library/_winreg.rst Log: Fix markup errors from r59857 and clarify key.__enter__/__exit__ docs Modified: python/trunk/Doc/library/_winreg.rst ============================================================================== --- python/trunk/Doc/library/_winreg.rst (original) +++ python/trunk/Doc/library/_winreg.rst Tue Jan 8 17:18:26 2008 @@ -136,11 +136,11 @@ .. function:: ExpandEnvironmentStrings(unicode) Expands environment strings %NAME% in unicode string like const:`REG_EXPAND_SZ`:: - - >>> ExpandEnvironmentStrings(u"%windir%") - u"C:\\Windows" - - .. versionadded: 2.6 + + >>> ExpandEnvironmentStrings(u"%windir%") + u"C:\\Windows" + + .. versionadded:: 2.6 .. function:: FlushKey(key) @@ -429,10 +429,15 @@ underlying Win32 handle to exist beyond the lifetime of the handle object. .. method:: PyHKEY.__enter__() -.. method:: PyHKEY.__exit__(*exc_info) - - The HKEY object implements __enter__ and __exit__ and thus supports the - context protocol for the with statement. - - .. versionadded: 2.6 + PyHKEY.__exit__(\*exc_info) + + The HKEY object implements :meth:`__enter__` and :meth:`__exit__` and thus + supports the context protocol for the :keyword:`with` statement:: + + with OpenKey(HKEY_LOCAL_MACHINE, "foo") as key: + # ... work with key ... + + will automatically close *key* when control leaves the :keyword:`with` block. + + .. versionadded:: 2.6 From python-checkins at python.org Tue Jan 8 17:20:46 2008 From: python-checkins at python.org (facundo.batista) Date: Tue, 8 Jan 2008 17:20:46 +0100 (CET) Subject: [Python-checkins] r59859 - in python/branches/release25-maint/Lib: decimal.py test/decimaltestdata/abs.decTest test/decimaltestdata/add.decTest test/decimaltestdata/and.decTest test/decimaltestdata/base.decTest test/decimaltestdata/clamp.decTest test/decimaltestdata/class.decTest test/decimaltestdata/compare.decTest test/decimaltestdata/comparetotal.decTest test/decimaltestdata/comparetotmag.decTest test/decimaltestdata/copy.decTest test/decimaltestdata/copyabs.decTest test/decimaltestdata/copynegate.decTest test/decimaltestdata/copysign.decTest test/decimaltestdata/ddAbs.decTest test/decimaltestdata/ddAdd.decTest test/decimaltestdata/ddAnd.decTest test/decimaltestdata/ddBase.decTest test/decimaltestdata/ddCanonical.decTest test/decimaltestdata/ddClass.decTest test/decimaltestdata/ddCompare.decTest test/decimaltestdata/ddCompareSig.decTest test/decimaltestdata/ddCompareTotal.decTest test/decimaltestdata/ddCompareTotalMag.decTest test/decimaltestdata/ddCopy.decTest test/decimaltestdata/ddCopyAbs.decTest test/decimaltestdata/ddCopyNegate.decTest test/decimaltestdata/ddCopySign.decTest test/decimaltestdata/ddDivide.decTest test/decimaltestdata/ddDivideInt.decTest test/decimaltestdata/ddEncode.decTest test/decimaltestdata/ddFMA.decTest test/decimaltestdata/ddInvert.decTest test/decimaltestdata/ddLogB.decTest test/decimaltestdata/ddMax.decTest test/decimaltestdata/ddMaxMag.decTest test/decimaltestdata/ddMin.decTest test/decimaltestdata/ddMinMag.decTest test/decimaltestdata/ddMinus.decTest test/decimaltestdata/ddMultiply.decTest test/decimaltestdata/ddNextMinus.decTest test/decimaltestdata/ddNextPlus.decTest test/decimaltestdata/ddNextToward.decTest test/decimaltestdata/ddOr.decTest test/decimaltestdata/ddPlus.decTest test/decimaltestdata/ddQuantize.decTest test/decimaltestdata/ddReduce.decTest test/decimaltestdata/ddRemainder.decTest test/decimaltestdata/ddRemainderNear.decTest test/decimaltestdata/ddRotate.decTest test/decimaltestdata/ddSameQuantum.decTest test/decimaltestdata/ddScaleB.decTest test/decimaltestdata/ddShift.decTest test/decimaltestdata/ddSubtract.decTest test/decimaltestdata/ddToIntegral.decTest test/decimaltestdata/ddXor.decTest test/decimaltestdata/decDouble.decTest test/decimaltestdata/decQuad.decTest test/decimaltestdata/decSingle.decTest test/decimaltestdata/decimal128.decTest test/decimaltestdata/decimal32.decTest test/decimaltestdata/decimal64.decTest test/decimaltestdata/divide.decTest test/decimaltestdata/divideint.decTest test/decimaltestdata/dqAbs.decTest test/decimaltestdata/dqAdd.decTest test/decimaltestdata/dqAnd.decTest test/decimaltestdata/dqBase.decTest test/decimaltestdata/dqCanonical.decTest test/decimaltestdata/dqClass.decTest test/decimaltestdata/dqCompare.decTest test/decimaltestdata/dqCompareSig.decTest test/decimaltestdata/dqCompareTotal.decTest test/decimaltestdata/dqCompareTotalMag.decTest test/decimaltestdata/dqCopy.decTest test/decimaltestdata/dqCopyAbs.decTest test/decimaltestdata/dqCopyNegate.decTest test/decimaltestdata/dqCopySign.decTest test/decimaltestdata/dqDivide.decTest test/decimaltestdata/dqDivideInt.decTest test/decimaltestdata/dqEncode.decTest test/decimaltestdata/dqFMA.decTest test/decimaltestdata/dqInvert.decTest test/decimaltestdata/dqLogB.decTest test/decimaltestdata/dqMax.decTest test/decimaltestdata/dqMaxMag.decTest test/decimaltestdata/dqMin.decTest test/decimaltestdata/dqMinMag.decTest test/decimaltestdata/dqMinus.decTest test/decimaltestdata/dqMultiply.decTest test/decimaltestdata/dqNextMinus.decTest test/decimaltestdata/dqNextPlus.decTest test/decimaltestdata/dqNextToward.decTest test/decimaltestdata/dqOr.decTest test/decimaltestdata/dqPlus.decTest test/decimaltestdata/dqQuantize.decTest test/decimaltestdata/dqReduce.decTest test/decimaltestdata/dqRemainder.decTest test/decimaltestdata/dqRemainderNear.decTest test/decimaltestdata/dqRotate.decTest test/decimaltestdata/dqSameQuantum.decTest test/decimaltestdata/dqScaleB.decTest test/decimaltestdata/dqShift.decTest test/decimaltestdata/dqSubtract.decTest test/decimaltestdata/dqToIntegral.decTest test/decimaltestdata/dqXor.decTest test/decimaltestdata/dsBase.decTest test/decimaltestdata/dsEncode.decTest test/decimaltestdata/exp.decTest test/decimaltestdata/extra.decTest test/decimaltestdata/fma.decTest test/decimaltestdata/inexact.decTest test/decimaltestdata/invert.decTest test/decimaltestdata/ln.decTest test/decimaltestdata/log10.decTest test/decimaltestdata/logb.decTest test/decimaltestdata/max.decTest test/decimaltestdata/maxmag.decTest test/decimaltestdata/min.decTest test/decimaltestdata/minmag.decTest test/decimaltestdata/minus.decTest test/decimaltestdata/multiply.decTest test/decimaltestdata/nextminus.decTest test/decimaltestdata/nextplus.decTest test/decimaltestdata/nexttoward.decTest test/decimaltestdata/normalize.decTest test/decimaltestdata/or.decTest test/decimaltestdata/plus.decTest test/decimaltestdata/power.decTest test/decimaltestdata/powersqrt.decTest test/decimaltestdata/quantize.decTest test/decimaltestdata/randomBound32.decTest test/decimaltestdata/randoms.decTest test/decimaltestdata/reduce.decTest test/decimaltestdata/remainder.decTest test/decimaltestdata/remainderNear.decTest test/decimaltestdata/rescale.decTest test/decimaltestdata/rotate.decTest test/decimaltestdata/rounding.decTest test/decimaltestdata/samequantum.decTest test/decimaltestdata/scaleb.decTest test/decimaltestdata/shift.decTest test/decimaltestdata/squareroot.decTest test/decimaltestdata/subtract.decTest test/decimaltestdata/testall.decTest test/decimaltestdata/tointegral.decTest test/decimaltestdata/tointegralx.decTest test/decimaltestdata/xor.decTest test/test_decimal.py Message-ID: <20080108162046.D1ED91E4005@bag.python.org> Author: facundo.batista Date: Tue Jan 8 17:20:31 2008 New Revision: 59859 Added: python/branches/release25-maint/Lib/test/decimaltestdata/and.decTest python/branches/release25-maint/Lib/test/decimaltestdata/class.decTest python/branches/release25-maint/Lib/test/decimaltestdata/comparetotal.decTest python/branches/release25-maint/Lib/test/decimaltestdata/comparetotmag.decTest python/branches/release25-maint/Lib/test/decimaltestdata/copy.decTest python/branches/release25-maint/Lib/test/decimaltestdata/copyabs.decTest python/branches/release25-maint/Lib/test/decimaltestdata/copynegate.decTest python/branches/release25-maint/Lib/test/decimaltestdata/copysign.decTest python/branches/release25-maint/Lib/test/decimaltestdata/ddAbs.decTest python/branches/release25-maint/Lib/test/decimaltestdata/ddAdd.decTest python/branches/release25-maint/Lib/test/decimaltestdata/ddAnd.decTest python/branches/release25-maint/Lib/test/decimaltestdata/ddBase.decTest python/branches/release25-maint/Lib/test/decimaltestdata/ddCanonical.decTest python/branches/release25-maint/Lib/test/decimaltestdata/ddClass.decTest python/branches/release25-maint/Lib/test/decimaltestdata/ddCompare.decTest python/branches/release25-maint/Lib/test/decimaltestdata/ddCompareSig.decTest python/branches/release25-maint/Lib/test/decimaltestdata/ddCompareTotal.decTest python/branches/release25-maint/Lib/test/decimaltestdata/ddCompareTotalMag.decTest python/branches/release25-maint/Lib/test/decimaltestdata/ddCopy.decTest python/branches/release25-maint/Lib/test/decimaltestdata/ddCopyAbs.decTest python/branches/release25-maint/Lib/test/decimaltestdata/ddCopyNegate.decTest python/branches/release25-maint/Lib/test/decimaltestdata/ddCopySign.decTest python/branches/release25-maint/Lib/test/decimaltestdata/ddDivide.decTest python/branches/release25-maint/Lib/test/decimaltestdata/ddDivideInt.decTest python/branches/release25-maint/Lib/test/decimaltestdata/ddEncode.decTest python/branches/release25-maint/Lib/test/decimaltestdata/ddFMA.decTest python/branches/release25-maint/Lib/test/decimaltestdata/ddInvert.decTest python/branches/release25-maint/Lib/test/decimaltestdata/ddLogB.decTest python/branches/release25-maint/Lib/test/decimaltestdata/ddMax.decTest python/branches/release25-maint/Lib/test/decimaltestdata/ddMaxMag.decTest python/branches/release25-maint/Lib/test/decimaltestdata/ddMin.decTest python/branches/release25-maint/Lib/test/decimaltestdata/ddMinMag.decTest python/branches/release25-maint/Lib/test/decimaltestdata/ddMinus.decTest python/branches/release25-maint/Lib/test/decimaltestdata/ddMultiply.decTest python/branches/release25-maint/Lib/test/decimaltestdata/ddNextMinus.decTest python/branches/release25-maint/Lib/test/decimaltestdata/ddNextPlus.decTest python/branches/release25-maint/Lib/test/decimaltestdata/ddNextToward.decTest python/branches/release25-maint/Lib/test/decimaltestdata/ddOr.decTest python/branches/release25-maint/Lib/test/decimaltestdata/ddPlus.decTest python/branches/release25-maint/Lib/test/decimaltestdata/ddQuantize.decTest python/branches/release25-maint/Lib/test/decimaltestdata/ddReduce.decTest python/branches/release25-maint/Lib/test/decimaltestdata/ddRemainder.decTest python/branches/release25-maint/Lib/test/decimaltestdata/ddRemainderNear.decTest python/branches/release25-maint/Lib/test/decimaltestdata/ddRotate.decTest python/branches/release25-maint/Lib/test/decimaltestdata/ddSameQuantum.decTest python/branches/release25-maint/Lib/test/decimaltestdata/ddScaleB.decTest python/branches/release25-maint/Lib/test/decimaltestdata/ddShift.decTest python/branches/release25-maint/Lib/test/decimaltestdata/ddSubtract.decTest python/branches/release25-maint/Lib/test/decimaltestdata/ddToIntegral.decTest python/branches/release25-maint/Lib/test/decimaltestdata/ddXor.decTest python/branches/release25-maint/Lib/test/decimaltestdata/decDouble.decTest python/branches/release25-maint/Lib/test/decimaltestdata/decQuad.decTest python/branches/release25-maint/Lib/test/decimaltestdata/decSingle.decTest python/branches/release25-maint/Lib/test/decimaltestdata/dqAbs.decTest python/branches/release25-maint/Lib/test/decimaltestdata/dqAdd.decTest python/branches/release25-maint/Lib/test/decimaltestdata/dqAnd.decTest python/branches/release25-maint/Lib/test/decimaltestdata/dqBase.decTest python/branches/release25-maint/Lib/test/decimaltestdata/dqCanonical.decTest python/branches/release25-maint/Lib/test/decimaltestdata/dqClass.decTest python/branches/release25-maint/Lib/test/decimaltestdata/dqCompare.decTest python/branches/release25-maint/Lib/test/decimaltestdata/dqCompareSig.decTest python/branches/release25-maint/Lib/test/decimaltestdata/dqCompareTotal.decTest python/branches/release25-maint/Lib/test/decimaltestdata/dqCompareTotalMag.decTest python/branches/release25-maint/Lib/test/decimaltestdata/dqCopy.decTest python/branches/release25-maint/Lib/test/decimaltestdata/dqCopyAbs.decTest python/branches/release25-maint/Lib/test/decimaltestdata/dqCopyNegate.decTest python/branches/release25-maint/Lib/test/decimaltestdata/dqCopySign.decTest python/branches/release25-maint/Lib/test/decimaltestdata/dqDivide.decTest python/branches/release25-maint/Lib/test/decimaltestdata/dqDivideInt.decTest python/branches/release25-maint/Lib/test/decimaltestdata/dqEncode.decTest python/branches/release25-maint/Lib/test/decimaltestdata/dqFMA.decTest python/branches/release25-maint/Lib/test/decimaltestdata/dqInvert.decTest python/branches/release25-maint/Lib/test/decimaltestdata/dqLogB.decTest python/branches/release25-maint/Lib/test/decimaltestdata/dqMax.decTest python/branches/release25-maint/Lib/test/decimaltestdata/dqMaxMag.decTest python/branches/release25-maint/Lib/test/decimaltestdata/dqMin.decTest python/branches/release25-maint/Lib/test/decimaltestdata/dqMinMag.decTest python/branches/release25-maint/Lib/test/decimaltestdata/dqMinus.decTest python/branches/release25-maint/Lib/test/decimaltestdata/dqMultiply.decTest python/branches/release25-maint/Lib/test/decimaltestdata/dqNextMinus.decTest python/branches/release25-maint/Lib/test/decimaltestdata/dqNextPlus.decTest python/branches/release25-maint/Lib/test/decimaltestdata/dqNextToward.decTest python/branches/release25-maint/Lib/test/decimaltestdata/dqOr.decTest python/branches/release25-maint/Lib/test/decimaltestdata/dqPlus.decTest python/branches/release25-maint/Lib/test/decimaltestdata/dqQuantize.decTest python/branches/release25-maint/Lib/test/decimaltestdata/dqReduce.decTest python/branches/release25-maint/Lib/test/decimaltestdata/dqRemainder.decTest python/branches/release25-maint/Lib/test/decimaltestdata/dqRemainderNear.decTest python/branches/release25-maint/Lib/test/decimaltestdata/dqRotate.decTest python/branches/release25-maint/Lib/test/decimaltestdata/dqSameQuantum.decTest python/branches/release25-maint/Lib/test/decimaltestdata/dqScaleB.decTest python/branches/release25-maint/Lib/test/decimaltestdata/dqShift.decTest python/branches/release25-maint/Lib/test/decimaltestdata/dqSubtract.decTest python/branches/release25-maint/Lib/test/decimaltestdata/dqToIntegral.decTest python/branches/release25-maint/Lib/test/decimaltestdata/dqXor.decTest python/branches/release25-maint/Lib/test/decimaltestdata/dsBase.decTest python/branches/release25-maint/Lib/test/decimaltestdata/dsEncode.decTest python/branches/release25-maint/Lib/test/decimaltestdata/exp.decTest python/branches/release25-maint/Lib/test/decimaltestdata/extra.decTest python/branches/release25-maint/Lib/test/decimaltestdata/fma.decTest python/branches/release25-maint/Lib/test/decimaltestdata/invert.decTest python/branches/release25-maint/Lib/test/decimaltestdata/ln.decTest python/branches/release25-maint/Lib/test/decimaltestdata/log10.decTest python/branches/release25-maint/Lib/test/decimaltestdata/logb.decTest python/branches/release25-maint/Lib/test/decimaltestdata/maxmag.decTest python/branches/release25-maint/Lib/test/decimaltestdata/minmag.decTest python/branches/release25-maint/Lib/test/decimaltestdata/nextminus.decTest python/branches/release25-maint/Lib/test/decimaltestdata/nextplus.decTest python/branches/release25-maint/Lib/test/decimaltestdata/nexttoward.decTest python/branches/release25-maint/Lib/test/decimaltestdata/or.decTest python/branches/release25-maint/Lib/test/decimaltestdata/powersqrt.decTest python/branches/release25-maint/Lib/test/decimaltestdata/reduce.decTest python/branches/release25-maint/Lib/test/decimaltestdata/rotate.decTest python/branches/release25-maint/Lib/test/decimaltestdata/scaleb.decTest python/branches/release25-maint/Lib/test/decimaltestdata/shift.decTest python/branches/release25-maint/Lib/test/decimaltestdata/tointegralx.decTest python/branches/release25-maint/Lib/test/decimaltestdata/xor.decTest Removed: python/branches/release25-maint/Lib/test/decimaltestdata/decimal128.decTest python/branches/release25-maint/Lib/test/decimaltestdata/decimal32.decTest python/branches/release25-maint/Lib/test/decimaltestdata/decimal64.decTest python/branches/release25-maint/Lib/test/decimaltestdata/normalize.decTest Modified: python/branches/release25-maint/Lib/decimal.py python/branches/release25-maint/Lib/test/decimaltestdata/abs.decTest python/branches/release25-maint/Lib/test/decimaltestdata/add.decTest python/branches/release25-maint/Lib/test/decimaltestdata/base.decTest python/branches/release25-maint/Lib/test/decimaltestdata/clamp.decTest python/branches/release25-maint/Lib/test/decimaltestdata/compare.decTest python/branches/release25-maint/Lib/test/decimaltestdata/divide.decTest python/branches/release25-maint/Lib/test/decimaltestdata/divideint.decTest python/branches/release25-maint/Lib/test/decimaltestdata/inexact.decTest python/branches/release25-maint/Lib/test/decimaltestdata/max.decTest python/branches/release25-maint/Lib/test/decimaltestdata/min.decTest python/branches/release25-maint/Lib/test/decimaltestdata/minus.decTest python/branches/release25-maint/Lib/test/decimaltestdata/multiply.decTest python/branches/release25-maint/Lib/test/decimaltestdata/plus.decTest python/branches/release25-maint/Lib/test/decimaltestdata/power.decTest python/branches/release25-maint/Lib/test/decimaltestdata/quantize.decTest python/branches/release25-maint/Lib/test/decimaltestdata/randomBound32.decTest python/branches/release25-maint/Lib/test/decimaltestdata/randoms.decTest python/branches/release25-maint/Lib/test/decimaltestdata/remainder.decTest python/branches/release25-maint/Lib/test/decimaltestdata/remainderNear.decTest python/branches/release25-maint/Lib/test/decimaltestdata/rescale.decTest python/branches/release25-maint/Lib/test/decimaltestdata/rounding.decTest python/branches/release25-maint/Lib/test/decimaltestdata/samequantum.decTest python/branches/release25-maint/Lib/test/decimaltestdata/squareroot.decTest python/branches/release25-maint/Lib/test/decimaltestdata/subtract.decTest python/branches/release25-maint/Lib/test/decimaltestdata/testall.decTest python/branches/release25-maint/Lib/test/decimaltestdata/tointegral.decTest python/branches/release25-maint/Lib/test/test_decimal.py Log: Decimal module and test cases were updated to their state of the art. It now complies latest specification and tests. The only difference of this version with the one in the trunk is that a small subset that hash tests were removed, because they rely on modifications to core hash() function (see issue 1182 for further details). Modified: python/branches/release25-maint/Lib/decimal.py ============================================================================== --- python/branches/release25-maint/Lib/decimal.py (original) +++ python/branches/release25-maint/Lib/decimal.py Tue Jan 8 17:20:31 2008 @@ -29,8 +29,8 @@ Decimal floating point has finite precision with arbitrarily large bounds. -The purpose of the module is to support arithmetic using familiar -"schoolhouse" rules and to avoid the some of tricky representation +The purpose of this module is to support arithmetic using familiar +"schoolhouse" rules and to avoid some of the tricky representation issues associated with binary floating point. The package is especially useful for financial applications or for contexts where users have expectations that are at odds with binary floating point (for instance, @@ -128,7 +128,7 @@ # Constants for use in setting up contexts 'ROUND_DOWN', 'ROUND_HALF_UP', 'ROUND_HALF_EVEN', 'ROUND_CEILING', - 'ROUND_FLOOR', 'ROUND_UP', 'ROUND_HALF_DOWN', + 'ROUND_FLOOR', 'ROUND_UP', 'ROUND_HALF_DOWN', 'ROUND_05UP', # Functions for manipulating contexts 'setcontext', 'getcontext', 'localcontext' @@ -136,7 +136,7 @@ import copy as _copy -#Rounding +# Rounding ROUND_DOWN = 'ROUND_DOWN' ROUND_HALF_UP = 'ROUND_HALF_UP' ROUND_HALF_EVEN = 'ROUND_HALF_EVEN' @@ -144,12 +144,9 @@ ROUND_FLOOR = 'ROUND_FLOOR' ROUND_UP = 'ROUND_UP' ROUND_HALF_DOWN = 'ROUND_HALF_DOWN' +ROUND_05UP = 'ROUND_05UP' -#Rounding decision (not part of the public API) -NEVER_ROUND = 'NEVER_ROUND' # Round in division (non-divmod), sqrt ONLY -ALWAYS_ROUND = 'ALWAYS_ROUND' # Every operation rounds at end. - -#Errors +# Errors class DecimalException(ArithmeticError): """Base exception class. @@ -179,14 +176,13 @@ This occurs and signals clamped if the exponent of a result has been altered in order to fit the constraints of a specific concrete - representation. This may occur when the exponent of a zero result would - be outside the bounds of a representation, or when a large normal - number would have an encoded exponent that cannot be represented. In + representation. This may occur when the exponent of a zero result would + be outside the bounds of a representation, or when a large normal + number would have an encoded exponent that cannot be represented. In this latter case, the exponent is reduced to fit and the corresponding number of zero digits are appended to the coefficient ("fold-down"). """ - class InvalidOperation(DecimalException): """An invalid operation was performed. @@ -194,8 +190,8 @@ Something creates a signaling NaN -INF + INF - 0 * (+-)INF - (+-)INF / (+-)INF + 0 * (+-)INF + (+-)INF / (+-)INF x % 0 (+-)INF % x x._rescale( non-integer ) @@ -204,11 +200,16 @@ x ** (non-integer) x ** (+-)INF An operand is invalid + + The result of the operation after these is a quiet positive NaN, + except when the cause is a signaling NaN, in which case the result is + also a quiet NaN, but with the original sign, and an optional + diagnostic information. """ def handle(self, context, *args): if args: - if args[0] == 1: #sNaN, must drop 's' but keep diagnostics - return Decimal( (args[1]._sign, args[1]._int, 'n') ) + ans = _dec_from_triple(args[0]._sign, args[0]._int, 'n', True) + return ans._fix_nan(context) return NaN class ConversionSyntax(InvalidOperation): @@ -216,11 +217,10 @@ This occurs and signals invalid-operation if an string is being converted to a number and it does not conform to the numeric string - syntax. The result is [0,qNaN]. + syntax. The result is [0,qNaN]. """ - def handle(self, context, *args): - return (0, (0,), 'n') #Passed to something which uses a tuple. + return NaN class DivisionByZero(DecimalException, ZeroDivisionError): """Division by 0. @@ -235,9 +235,7 @@ -0, for power. """ - def handle(self, context, sign, double = None, *args): - if double is not None: - return (Infsign[sign],)*2 + def handle(self, context, sign, *args): return Infsign[sign] class DivisionImpossible(InvalidOperation): @@ -245,23 +243,21 @@ This occurs and signals invalid-operation if the integer result of a divide-integer or remainder operation had too many digits (would be - longer than precision). The result is [0,qNaN]. + longer than precision). The result is [0,qNaN]. """ def handle(self, context, *args): - return (NaN, NaN) + return NaN class DivisionUndefined(InvalidOperation, ZeroDivisionError): """Undefined result of division. This occurs and signals invalid-operation if division by zero was attempted (during a divide-integer, divide, or remainder operation), and - the dividend is also zero. The result is [0,qNaN]. + the dividend is also zero. The result is [0,qNaN]. """ - def handle(self, context, tup=None, *args): - if tup is not None: - return (NaN, NaN) #for 0 %0, 0 // 0 + def handle(self, context, *args): return NaN class Inexact(DecimalException): @@ -269,23 +265,22 @@ This occurs and signals inexact whenever the result of an operation is not exact (that is, it needed to be rounded and any discarded digits - were non-zero), or if an overflow or underflow condition occurs. The + were non-zero), or if an overflow or underflow condition occurs. The result in all cases is unchanged. The inexact signal may be tested (or trapped) to determine if a given operation (or sequence of operations) was inexact. """ - pass class InvalidContext(InvalidOperation): """Invalid context. Unknown rounding, for example. This occurs and signals invalid-operation if an invalid context was - detected during an operation. This can occur if contexts are not checked + detected during an operation. This can occur if contexts are not checked on creation and either the precision exceeds the capability of the underlying concrete representation or an unknown or unsupported rounding - was specified. These aspects of the context need only be checked when - the values are required to be used. The result is [0,qNaN]. + was specified. These aspects of the context need only be checked when + the values are required to be used. The result is [0,qNaN]. """ def handle(self, context, *args): @@ -296,25 +291,23 @@ This occurs and signals rounded whenever the result of an operation is rounded (that is, some zero or non-zero digits were discarded from the - coefficient), or if an overflow or underflow condition occurs. The + coefficient), or if an overflow or underflow condition occurs. The result in all cases is unchanged. The rounded signal may be tested (or trapped) to determine if a given operation (or sequence of operations) caused a loss of precision. """ - pass class Subnormal(DecimalException): """Exponent < Emin before rounding. This occurs and signals subnormal whenever the result of a conversion or operation is subnormal (that is, its adjusted exponent is less than - Emin, before any rounding). The result in all cases is unchanged. + Emin, before any rounding). The result in all cases is unchanged. The subnormal signal may be tested (or trapped) to determine if a given or operation (or sequence of operations) yielded a subnormal result. """ - pass class Overflow(Inexact, Rounded): """Numerical overflow. @@ -328,30 +321,30 @@ For round-half-up and round-half-even (and for round-half-down and round-up, if implemented), the result of the operation is [sign,inf], - where sign is the sign of the intermediate result. For round-down, the + where sign is the sign of the intermediate result. For round-down, the result is the largest finite number that can be represented in the - current precision, with the sign of the intermediate result. For + current precision, with the sign of the intermediate result. For round-ceiling, the result is the same as for round-down if the sign of - the intermediate result is 1, or is [0,inf] otherwise. For round-floor, + the intermediate result is 1, or is [0,inf] otherwise. For round-floor, the result is the same as for round-down if the sign of the intermediate - result is 0, or is [1,inf] otherwise. In all cases, Inexact and Rounded + result is 0, or is [1,inf] otherwise. In all cases, Inexact and Rounded will also be raised. - """ + """ def handle(self, context, sign, *args): if context.rounding in (ROUND_HALF_UP, ROUND_HALF_EVEN, - ROUND_HALF_DOWN, ROUND_UP): + ROUND_HALF_DOWN, ROUND_UP): return Infsign[sign] if sign == 0: if context.rounding == ROUND_CEILING: return Infsign[sign] - return Decimal((sign, (9,)*context.prec, - context.Emax-context.prec+1)) + return _dec_from_triple(sign, '9'*context.prec, + context.Emax-context.prec+1) if sign == 1: if context.rounding == ROUND_FLOOR: return Infsign[sign] - return Decimal( (sign, (9,)*context.prec, - context.Emax-context.prec+1)) + return _dec_from_triple(sign, '9'*context.prec, + context.Emax-context.prec+1) class Underflow(Inexact, Rounded, Subnormal): @@ -360,10 +353,10 @@ This occurs and signals underflow if a result is inexact and the adjusted exponent of the result would be smaller (more negative) than the smallest value that can be handled by the implementation (the value - Emin). That is, the result is both inexact and subnormal. + Emin). That is, the result is both inexact and subnormal. The result after an underflow will be a subnormal number rounded, if - necessary, so that its exponent is not less than Etiny. This may result + necessary, so that its exponent is not less than Etiny. This may result in 0 with the sign of the intermediate result and an exponent of Etiny. In all cases, Inexact, Rounded, and Subnormal will also be raised. @@ -379,7 +372,7 @@ DivisionUndefined:InvalidOperation, InvalidContext:InvalidOperation} -##### Context Functions ####################################### +##### Context Functions ################################################## # The getcontext() and setcontext() function manage access to a thread-local # current context. Py2.4 offers direct support for thread locals. If that @@ -392,7 +385,7 @@ except ImportError: # Python was compiled without threads; create a mock object instead import sys - class MockThreading: + class MockThreading(object): def local(self, sys=sys): return sys.modules[__name__] threading = MockThreading() @@ -403,8 +396,8 @@ except AttributeError: - #To fix reloading, force it to create a new context - #Old contexts have different exceptions in their dicts, making problems. + # To fix reloading, force it to create a new context + # Old contexts have different exceptions in their dicts, making problems. if hasattr(threading.currentThread(), '__decimal_context__'): del threading.currentThread().__decimal_context__ @@ -469,14 +462,14 @@ ctx.prec += 2 # Rest of sin calculation algorithm # uses a precision 2 greater than normal - return +s # Convert result to normal precision + return +s # Convert result to normal precision def sin(x): with localcontext(ExtendedContext): # Rest of sin calculation algorithm # uses the Extended Context from the # General Decimal Arithmetic Specification - return +s # Convert result to normal context + return +s # Convert result to normal context """ # The string below can't be included in the docstring until Python 2.6 @@ -502,7 +495,7 @@ return _ContextManager(ctx) -##### Decimal class ########################################### +##### Decimal class ####################################################### class Decimal(object): """Floating point class for decimal arithmetic.""" @@ -518,7 +511,7 @@ >>> Decimal('3.14') # string input Decimal("3.14") - >>> Decimal((0, (3, 1, 4), -2)) # tuple input (sign, digit_tuple, exponent) + >>> Decimal((0, (3, 1, 4), -2)) # tuple (sign, digit_tuple, exponent) Decimal("3.14") >>> Decimal(314) # int or long Decimal("314") @@ -526,22 +519,56 @@ Decimal("314") """ + # Note that the coefficient, self._int, is actually stored as + # a string rather than as a tuple of digits. This speeds up + # the "digits to integer" and "integer to digits" conversions + # that are used in almost every arithmetic operation on + # Decimals. This is an internal detail: the as_tuple function + # and the Decimal constructor still deal with tuples of + # digits. + self = object.__new__(cls) - self._is_special = False - # From an internal working value - if isinstance(value, _WorkRep): - self._sign = value.sign - self._int = tuple(map(int, str(value.int))) - self._exp = int(value.exp) - return self + # From a string + # REs insist on real strings, so we can too. + if isinstance(value, basestring): + m = _parser(value) + if m is None: + if context is None: + context = getcontext() + return context._raise_error(ConversionSyntax, + "Invalid literal for Decimal: %r" % value) - # From another decimal - if isinstance(value, Decimal): - self._exp = value._exp - self._sign = value._sign - self._int = value._int - self._is_special = value._is_special + if m.group('sign') == "-": + self._sign = 1 + else: + self._sign = 0 + intpart = m.group('int') + if intpart is not None: + # finite number + fracpart = m.group('frac') + exp = int(m.group('exp') or '0') + if fracpart is not None: + self._int = (intpart+fracpart).lstrip('0') or '0' + self._exp = exp - len(fracpart) + else: + self._int = intpart.lstrip('0') or '0' + self._exp = exp + self._is_special = False + else: + diag = m.group('diag') + if diag is not None: + # NaN + self._int = diag.lstrip('0') + if m.group('signal'): + self._exp = 'N' + else: + self._exp = 'n' + else: + # infinity + self._int = '0' + self._exp = 'F' + self._is_special = True return self # From an integer @@ -551,69 +578,75 @@ else: self._sign = 1 self._exp = 0 - self._int = tuple(map(int, str(abs(value)))) + self._int = str(abs(value)) + self._is_special = False + return self + + # From another decimal + if isinstance(value, Decimal): + self._exp = value._exp + self._sign = value._sign + self._int = value._int + self._is_special = value._is_special + return self + + # From an internal working value + if isinstance(value, _WorkRep): + self._sign = value.sign + self._int = str(value.int) + self._exp = int(value.exp) + self._is_special = False return self # tuple/list conversion (possibly from as_tuple()) if isinstance(value, (list,tuple)): if len(value) != 3: - raise ValueError, 'Invalid arguments' - if value[0] not in (0,1): - raise ValueError, 'Invalid sign' - for digit in value[1]: - if not isinstance(digit, (int,long)) or digit < 0: - raise ValueError, "The second value in the tuple must be composed of non negative integer elements." - + raise ValueError('Invalid tuple size in creation of Decimal ' + 'from list or tuple. The list or tuple ' + 'should have exactly three elements.') + # process sign. The isinstance test rejects floats + if not (isinstance(value[0], (int, long)) and value[0] in (0,1)): + raise ValueError("Invalid sign. The first value in the tuple " + "should be an integer; either 0 for a " + "positive number or 1 for a negative number.") self._sign = value[0] - self._int = tuple(value[1]) - if value[2] in ('F','n','N'): + if value[2] == 'F': + # infinity: value[1] is ignored + self._int = '0' self._exp = value[2] self._is_special = True else: - self._exp = int(value[2]) + # process and validate the digits in value[1] + digits = [] + for digit in value[1]: + if isinstance(digit, (int, long)) and 0 <= digit <= 9: + # skip leading zeros + if digits or digit != 0: + digits.append(digit) + else: + raise ValueError("The second value in the tuple must " + "be composed of integers in the range " + "0 through 9.") + if value[2] in ('n', 'N'): + # NaN: digits form the diagnostic + self._int = ''.join(map(str, digits)) + self._exp = value[2] + self._is_special = True + elif isinstance(value[2], (int, long)): + # finite number: digits give the coefficient + self._int = ''.join(map(str, digits or [0])) + self._exp = value[2] + self._is_special = False + else: + raise ValueError("The third value in the tuple must " + "be an integer, or one of the " + "strings 'F', 'n', 'N'.") return self if isinstance(value, float): raise TypeError("Cannot convert float to Decimal. " + "First convert the float to a string") - # Other argument types may require the context during interpretation - if context is None: - context = getcontext() - - # From a string - # REs insist on real strings, so we can too. - if isinstance(value, basestring): - if _isinfinity(value): - self._exp = 'F' - self._int = (0,) - self._is_special = True - if _isinfinity(value) == 1: - self._sign = 0 - else: - self._sign = 1 - return self - if _isnan(value): - sig, sign, diag = _isnan(value) - self._is_special = True - if len(diag) > context.prec: #Diagnostic info too long - self._sign, self._int, self._exp = \ - context._raise_error(ConversionSyntax) - return self - if sig == 1: - self._exp = 'n' #qNaN - else: #sig == 2 - self._exp = 'N' #sNaN - self._sign = sign - self._int = tuple(map(int, diag)) #Diagnostic info - return self - try: - self._sign, self._int, self._exp = _string2exact(value) - except ValueError: - self._is_special = True - self._sign, self._int, self._exp = context._raise_error(ConversionSyntax) - return self - raise TypeError("Cannot convert %r to Decimal" % value) def _isnan(self): @@ -644,7 +677,7 @@ return 1 return 0 - def _check_nans(self, other = None, context=None): + def _check_nans(self, other=None, context=None): """Returns whether the number is not actually one. if self, other are sNaN, signal @@ -666,43 +699,47 @@ if self_is_nan == 2: return context._raise_error(InvalidOperation, 'sNaN', - 1, self) + self) if other_is_nan == 2: return context._raise_error(InvalidOperation, 'sNaN', - 1, other) + other) if self_is_nan: - return self + return self._fix_nan(context) - return other + return other._fix_nan(context) return 0 def __nonzero__(self): - """Is the number non-zero? + """Return True if self is nonzero; otherwise return False. - 0 if self == 0 - 1 if self != 0 + NaNs and infinities are considered nonzero. """ - if self._is_special: - return 1 - return sum(self._int) != 0 + return self._is_special or self._int != '0' - def __cmp__(self, other, context=None): + def __cmp__(self, other): other = _convert_other(other) if other is NotImplemented: - return other + # Never return NotImplemented + return 1 if self._is_special or other._is_special: - ans = self._check_nans(other, context) - if ans: - return 1 # Comparison involving NaN's always reports self > other + # check for nans, without raising on a signaling nan + if self._isnan() or other._isnan(): + return 1 # Comparison involving NaN's always reports self > other # INF = INF return cmp(self._isinfinity(), other._isinfinity()) - if not self and not other: - return 0 #If both 0, sign comparison isn't certain. + # check for zeros; note that cmp(0, -0) should return 0 + if not self: + if not other: + return 0 + else: + return -((-1)**other._sign) + if not other: + return (-1)**self._sign - #If different signs, neg one is less + # If different signs, neg one is less if other._sign < self._sign: return -1 if self._sign < other._sign: @@ -710,35 +747,15 @@ self_adjusted = self.adjusted() other_adjusted = other.adjusted() - if self_adjusted == other_adjusted and \ - self._int + (0,)*(self._exp - other._exp) == \ - other._int + (0,)*(other._exp - self._exp): - return 0 #equal, except in precision. ([0]*(-x) = []) - elif self_adjusted > other_adjusted and self._int[0] != 0: + if self_adjusted == other_adjusted: + self_padded = self._int + '0'*(self._exp - other._exp) + other_padded = other._int + '0'*(other._exp - self._exp) + return cmp(self_padded, other_padded) * (-1)**self._sign + elif self_adjusted > other_adjusted: return (-1)**self._sign - elif self_adjusted < other_adjusted and other._int[0] != 0: + else: # self_adjusted < other_adjusted return -((-1)**self._sign) - # Need to round, so make sure we have a valid context - if context is None: - context = getcontext() - - context = context._shallow_copy() - rounding = context._set_rounding(ROUND_UP) #round away from 0 - - flags = context._ignore_all_flags() - res = self.__sub__(other, context=context) - - context._regard_flags(*flags) - - context.rounding = rounding - - if not res: - return 0 - elif res._sign: - return -1 - return 1 - def __eq__(self, other): if not isinstance(other, (Decimal, int, long)): return NotImplemented @@ -758,126 +775,109 @@ NaN => one is NaN Like __cmp__, but returns Decimal instances. """ - other = _convert_other(other) - if other is NotImplemented: - return other + other = _convert_other(other, raiseit=True) - #compare(NaN, NaN) = NaN + # Compare(NaN, NaN) = NaN if (self._is_special or other and other._is_special): ans = self._check_nans(other, context) if ans: return ans - return Decimal(self.__cmp__(other, context)) + return Decimal(self.__cmp__(other)) def __hash__(self): """x.__hash__() <==> hash(x)""" # Decimal integers must hash the same as the ints - # Non-integer decimals are normalized and hashed as strings - # Normalization assures that hash(100E-1) == hash(10) + # + # The hash of a nonspecial noninteger Decimal must depend only + # on the value of that Decimal, and not on its representation. + # For example: hash(Decimal("100E-1")) == hash(Decimal("10")). if self._is_special: if self._isnan(): raise TypeError('Cannot hash a NaN value.') return hash(str(self)) - i = int(self) - if self == Decimal(i): - return hash(i) - assert self.__nonzero__() # '-0' handled by integer case - return hash(str(self.normalize())) + if not self: + return 0 + if self._isinteger(): + op = _WorkRep(self.to_integral_value()) + # to make computation feasible for Decimals with large + # exponent, we use the fact that hash(n) == hash(m) for + # any two nonzero integers n and m such that (i) n and m + # have the same sign, and (ii) n is congruent to m modulo + # 2**64-1. So we can replace hash((-1)**s*c*10**e) with + # hash((-1)**s*c*pow(10, e, 2**64-1). + return hash((-1)**op.sign*op.int*pow(10, op.exp, 2**64-1)) + # The value of a nonzero nonspecial Decimal instance is + # faithfully represented by the triple consisting of its sign, + # its adjusted exponent, and its coefficient with trailing + # zeros removed. + return hash((self._sign, + self._exp+len(self._int), + self._int.rstrip('0'))) def as_tuple(self): """Represents the number as a triple tuple. To show the internals exactly as they are. """ - return (self._sign, self._int, self._exp) + return (self._sign, tuple(map(int, self._int)), self._exp) def __repr__(self): """Represents the number as an instance of Decimal.""" # Invariant: eval(repr(d)) == d return 'Decimal("%s")' % str(self) - def __str__(self, eng = 0, context=None): + def __str__(self, eng=False, context=None): """Return string representation of the number in scientific notation. Captures all of the information in the underlying representation. """ + sign = ['', '-'][self._sign] if self._is_special: - if self._isnan(): - minus = '-'*self._sign - if self._int == (0,): - info = '' - else: - info = ''.join(map(str, self._int)) - if self._isnan() == 2: - return minus + 'sNaN' + info - return minus + 'NaN' + info - if self._isinfinity(): - minus = '-'*self._sign - return minus + 'Infinity' - - if context is None: - context = getcontext() + if self._exp == 'F': + return sign + 'Infinity' + elif self._exp == 'n': + return sign + 'NaN' + self._int + else: # self._exp == 'N' + return sign + 'sNaN' + self._int + + # number of digits of self._int to left of decimal point + leftdigits = self._exp + len(self._int) + + # dotplace is number of digits of self._int to the left of the + # decimal point in the mantissa of the output string (that is, + # after adjusting the exponent) + if self._exp <= 0 and leftdigits > -6: + # no exponent required + dotplace = leftdigits + elif not eng: + # usual scientific notation: 1 digit on left of the point + dotplace = 1 + elif self._int == '0': + # engineering notation, zero + dotplace = (leftdigits + 1) % 3 - 1 + else: + # engineering notation, nonzero + dotplace = (leftdigits - 1) % 3 + 1 - tmp = map(str, self._int) - numdigits = len(self._int) - leftdigits = self._exp + numdigits - if eng and not self: #self = 0eX wants 0[.0[0]]eY, not [[0]0]0eY - if self._exp < 0 and self._exp >= -6: #short, no need for e/E - s = '-'*self._sign + '0.' + '0'*(abs(self._exp)) - return s - #exp is closest mult. of 3 >= self._exp - exp = ((self._exp - 1)// 3 + 1) * 3 - if exp != self._exp: - s = '0.'+'0'*(exp - self._exp) - else: - s = '0' - if exp != 0: - if context.capitals: - s += 'E' - else: - s += 'e' - if exp > 0: - s += '+' #0.0e+3, not 0.0e3 - s += str(exp) - s = '-'*self._sign + s - return s - if eng: - dotplace = (leftdigits-1)%3+1 - adjexp = leftdigits -1 - (leftdigits-1)%3 + if dotplace <= 0: + intpart = '0' + fracpart = '.' + '0'*(-dotplace) + self._int + elif dotplace >= len(self._int): + intpart = self._int+'0'*(dotplace-len(self._int)) + fracpart = '' else: - adjexp = leftdigits-1 - dotplace = 1 - if self._exp == 0: - pass - elif self._exp < 0 and adjexp >= 0: - tmp.insert(leftdigits, '.') - elif self._exp < 0 and adjexp >= -6: - tmp[0:0] = ['0'] * int(-leftdigits) - tmp.insert(0, '0.') - else: - if numdigits > dotplace: - tmp.insert(dotplace, '.') - elif numdigits < dotplace: - tmp.extend(['0']*(dotplace-numdigits)) - if adjexp: - if not context.capitals: - tmp.append('e') - else: - tmp.append('E') - if adjexp > 0: - tmp.append('+') - tmp.append(str(adjexp)) - if eng: - while tmp[0:1] == ['0']: - tmp[0:1] = [] - if len(tmp) == 0 or tmp[0] == '.' or tmp[0].lower() == 'e': - tmp[0:0] = ['0'] - if self._sign: - tmp.insert(0, '-') + intpart = self._int[:dotplace] + fracpart = '.' + self._int[dotplace:] + if leftdigits == dotplace: + exp = '' + else: + if context is None: + context = getcontext() + exp = ['e', 'E'][context.capitals] + "%+d" % (leftdigits-dotplace) - return ''.join(tmp) + return sign + intpart + fracpart + exp def to_eng_string(self, context=None): """Convert to engineering-type string. @@ -887,7 +887,7 @@ Same rules for when in exponential and when as a value as in __str__. """ - return self.__str__(eng=1, context=context) + return self.__str__(eng=True, context=context) def __neg__(self, context=None): """Returns a copy with the sign switched. @@ -901,17 +901,13 @@ if not self: # -Decimal('0') is Decimal('0'), not Decimal('-0') - sign = 0 - elif self._sign: - sign = 0 + ans = self.copy_abs() else: - sign = 1 + ans = self.copy_negate() if context is None: context = getcontext() - if context._rounding_decision == ALWAYS_ROUND: - return Decimal((sign, self._int, self._exp))._fix(context) - return Decimal( (sign, self._int, self._exp)) + return ans._fix(context) def __pos__(self, context=None): """Returns a copy, unless it is a sNaN. @@ -923,37 +919,31 @@ if ans: return ans - sign = self._sign if not self: # + (-0) = 0 - sign = 0 + ans = self.copy_abs() + else: + ans = Decimal(self) if context is None: context = getcontext() + return ans._fix(context) - if context._rounding_decision == ALWAYS_ROUND: - ans = self._fix(context) - else: - ans = Decimal(self) - ans._sign = sign - return ans - - def __abs__(self, round=1, context=None): + def __abs__(self, round=True, context=None): """Returns the absolute value of self. - If the second argument is 0, do not round. + If the keyword argument 'round' is false, do not round. The + expression self.__abs__(round=False) is equivalent to + self.copy_abs(). """ + if not round: + return self.copy_abs() + if self._is_special: ans = self._check_nans(context=context) if ans: return ans - if not round: - if context is None: - context = getcontext() - context = context._shallow_copy() - context._set_rounding_decision(NEVER_ROUND) - if self._sign: ans = self.__neg__(context=context) else: @@ -979,66 +969,63 @@ return ans if self._isinfinity(): - #If both INF, same sign => same as both, opposite => error. + # If both INF, same sign => same as both, opposite => error. if self._sign != other._sign and other._isinfinity(): return context._raise_error(InvalidOperation, '-INF + INF') return Decimal(self) if other._isinfinity(): - return Decimal(other) #Can't both be infinity here - - shouldround = context._rounding_decision == ALWAYS_ROUND + return Decimal(other) # Can't both be infinity here exp = min(self._exp, other._exp) negativezero = 0 if context.rounding == ROUND_FLOOR and self._sign != other._sign: - #If the answer is 0, the sign should be negative, in this case. + # If the answer is 0, the sign should be negative, in this case. negativezero = 1 if not self and not other: sign = min(self._sign, other._sign) if negativezero: sign = 1 - return Decimal( (sign, (0,), exp)) + ans = _dec_from_triple(sign, '0', exp) + ans = ans._fix(context) + return ans if not self: exp = max(exp, other._exp - context.prec-1) - ans = other._rescale(exp, watchexp=0, context=context) - if shouldround: - ans = ans._fix(context) + ans = other._rescale(exp, context.rounding) + ans = ans._fix(context) return ans if not other: exp = max(exp, self._exp - context.prec-1) - ans = self._rescale(exp, watchexp=0, context=context) - if shouldround: - ans = ans._fix(context) + ans = self._rescale(exp, context.rounding) + ans = ans._fix(context) return ans op1 = _WorkRep(self) op2 = _WorkRep(other) - op1, op2 = _normalize(op1, op2, shouldround, context.prec) + op1, op2 = _normalize(op1, op2, context.prec) result = _WorkRep() if op1.sign != op2.sign: # Equal and opposite if op1.int == op2.int: - if exp < context.Etiny(): - exp = context.Etiny() - context._raise_error(Clamped) - return Decimal((negativezero, (0,), exp)) + ans = _dec_from_triple(negativezero, '0', exp) + ans = ans._fix(context) + return ans if op1.int < op2.int: op1, op2 = op2, op1 - #OK, now abs(op1) > abs(op2) + # OK, now abs(op1) > abs(op2) if op1.sign == 1: result.sign = 1 op1.sign, op2.sign = op2.sign, op1.sign else: result.sign = 0 - #So we know the sign, and op1 > 0. + # So we know the sign, and op1 > 0. elif op1.sign == 1: result.sign = 1 op1.sign, op2.sign = (0, 0) else: result.sign = 0 - #Now, op1 > abs(op2) > 0 + # Now, op1 > abs(op2) > 0 if op2.sign == 0: result.int = op1.int + op2.int @@ -1047,14 +1034,13 @@ result.exp = op1.exp ans = Decimal(result) - if shouldround: - ans = ans._fix(context) + ans = ans._fix(context) return ans __radd__ = __add__ def __sub__(self, other, context=None): - """Return self + (-other)""" + """Return self - other""" other = _convert_other(other) if other is NotImplemented: return other @@ -1064,57 +1050,16 @@ if ans: return ans - # -Decimal(0) = Decimal(0), which we don't want since - # (-0 - 0 = -0 + (-0) = -0, but -0 + 0 = 0.) - # so we change the sign directly to a copy - tmp = Decimal(other) - tmp._sign = 1-tmp._sign - - return self.__add__(tmp, context=context) + # self - other is computed as self + other.copy_negate() + return self.__add__(other.copy_negate(), context=context) def __rsub__(self, other, context=None): - """Return other + (-self)""" + """Return other - self""" other = _convert_other(other) if other is NotImplemented: return other - tmp = Decimal(self) - tmp._sign = 1 - tmp._sign - return other.__add__(tmp, context=context) - - def _increment(self, round=1, context=None): - """Special case of add, adding 1eExponent - - Since it is common, (rounding, for example) this adds - (sign)*one E self._exp to the number more efficiently than add. - - For example: - Decimal('5.624e10')._increment() == Decimal('5.625e10') - """ - if self._is_special: - ans = self._check_nans(context=context) - if ans: - return ans - - return Decimal(self) # Must be infinite, and incrementing makes no difference - - L = list(self._int) - L[-1] += 1 - spot = len(L)-1 - while L[spot] == 10: - L[spot] = 0 - if spot == 0: - L[0:0] = [1] - break - L[spot-1] += 1 - spot -= 1 - ans = Decimal((self._sign, L, self._exp)) - - if context is None: - context = getcontext() - if round and context._rounding_decision == ALWAYS_ROUND: - ans = ans._fix(context) - return ans + return other.__sub__(self, context=context) def __mul__(self, other, context=None): """Return self * other. @@ -1146,60 +1091,38 @@ return Infsign[resultsign] resultexp = self._exp + other._exp - shouldround = context._rounding_decision == ALWAYS_ROUND # Special case for multiplying by zero if not self or not other: - ans = Decimal((resultsign, (0,), resultexp)) - if shouldround: - #Fixing in case the exponent is out of bounds - ans = ans._fix(context) + ans = _dec_from_triple(resultsign, '0', resultexp) + # Fixing in case the exponent is out of bounds + ans = ans._fix(context) return ans # Special case for multiplying by power of 10 - if self._int == (1,): - ans = Decimal((resultsign, other._int, resultexp)) - if shouldround: - ans = ans._fix(context) + if self._int == '1': + ans = _dec_from_triple(resultsign, other._int, resultexp) + ans = ans._fix(context) return ans - if other._int == (1,): - ans = Decimal((resultsign, self._int, resultexp)) - if shouldround: - ans = ans._fix(context) + if other._int == '1': + ans = _dec_from_triple(resultsign, self._int, resultexp) + ans = ans._fix(context) return ans op1 = _WorkRep(self) op2 = _WorkRep(other) - ans = Decimal( (resultsign, map(int, str(op1.int * op2.int)), resultexp)) - if shouldround: - ans = ans._fix(context) + ans = _dec_from_triple(resultsign, str(op1.int * op2.int), resultexp) + ans = ans._fix(context) return ans __rmul__ = __mul__ def __div__(self, other, context=None): """Return self / other.""" - return self._divide(other, context=context) - __truediv__ = __div__ - - def _divide(self, other, divmod = 0, context=None): - """Return a / b, to context.prec precision. - - divmod: - 0 => true division - 1 => (a //b, a%b) - 2 => a //b - 3 => a%b - - Actually, if divmod is 2 or 3 a tuple is returned, but errors for - computing the other value are not raised. - """ other = _convert_other(other) if other is NotImplemented: - if divmod in (0, 1): - return NotImplemented - return (NotImplemented, NotImplemented) + return NotImplemented if context is None: context = getcontext() @@ -1209,145 +1132,85 @@ if self._is_special or other._is_special: ans = self._check_nans(other, context) if ans: - if divmod: - return (ans, ans) return ans if self._isinfinity() and other._isinfinity(): - if divmod: - return (context._raise_error(InvalidOperation, - '(+-)INF // (+-)INF'), - context._raise_error(InvalidOperation, - '(+-)INF % (+-)INF')) return context._raise_error(InvalidOperation, '(+-)INF/(+-)INF') if self._isinfinity(): - if divmod == 1: - return (Infsign[sign], - context._raise_error(InvalidOperation, 'INF % x')) - elif divmod == 2: - return (Infsign[sign], NaN) - elif divmod == 3: - return (Infsign[sign], - context._raise_error(InvalidOperation, 'INF % x')) return Infsign[sign] if other._isinfinity(): - if divmod: - return (Decimal((sign, (0,), 0)), Decimal(self)) context._raise_error(Clamped, 'Division by infinity') - return Decimal((sign, (0,), context.Etiny())) + return _dec_from_triple(sign, '0', context.Etiny()) # Special cases for zeroes - if not self and not other: - if divmod: - return context._raise_error(DivisionUndefined, '0 / 0', 1) - return context._raise_error(DivisionUndefined, '0 / 0') - - if not self: - if divmod: - otherside = Decimal(self) - otherside._exp = min(self._exp, other._exp) - return (Decimal((sign, (0,), 0)), otherside) - exp = self._exp - other._exp - if exp < context.Etiny(): - exp = context.Etiny() - context._raise_error(Clamped, '0e-x / y') - if exp > context.Emax: - exp = context.Emax - context._raise_error(Clamped, '0e+x / y') - return Decimal( (sign, (0,), exp) ) - if not other: - if divmod: - return context._raise_error(DivisionByZero, 'divmod(x,0)', - sign, 1) + if not self: + return context._raise_error(DivisionUndefined, '0 / 0') return context._raise_error(DivisionByZero, 'x / 0', sign) - #OK, so neither = 0, INF or NaN - - shouldround = context._rounding_decision == ALWAYS_ROUND - - #If we're dividing into ints, and self < other, stop. - #self.__abs__(0) does not round. - if divmod and (self.__abs__(0, context) < other.__abs__(0, context)): - - if divmod == 1 or divmod == 3: - exp = min(self._exp, other._exp) - ans2 = self._rescale(exp, context=context, watchexp=0) - if shouldround: - ans2 = ans2._fix(context) - return (Decimal( (sign, (0,), 0) ), - ans2) - - elif divmod == 2: - #Don't round the mod part, if we don't need it. - return (Decimal( (sign, (0,), 0) ), Decimal(self)) - - op1 = _WorkRep(self) - op2 = _WorkRep(other) - op1, op2, adjust = _adjust_coefficients(op1, op2) - res = _WorkRep( (sign, 0, (op1.exp - op2.exp)) ) - if divmod and res.exp > context.prec + 1: - return context._raise_error(DivisionImpossible) - - prec_limit = 10 ** context.prec - while 1: - while op2.int <= op1.int: - res.int += 1 - op1.int -= op2.int - if res.exp == 0 and divmod: - if res.int >= prec_limit and shouldround: - return context._raise_error(DivisionImpossible) - otherside = Decimal(op1) - frozen = context._ignore_all_flags() - - exp = min(self._exp, other._exp) - otherside = otherside._rescale(exp, context=context, watchexp=0) - context._regard_flags(*frozen) - if shouldround: - otherside = otherside._fix(context) - return (Decimal(res), otherside) - - if op1.int == 0 and adjust >= 0 and not divmod: - break - if res.int >= prec_limit and shouldround: - if divmod: - return context._raise_error(DivisionImpossible) - shouldround=1 - # Really, the answer is a bit higher, so adding a one to - # the end will make sure the rounding is right. - if op1.int != 0: - res.int *= 10 - res.int += 1 - res.exp -= 1 - - break - res.int *= 10 - res.exp -= 1 - adjust += 1 - op1.int *= 10 - op1.exp -= 1 - - if res.exp == 0 and divmod and op2.int > op1.int: - #Solves an error in precision. Same as a previous block. + if not self: + exp = self._exp - other._exp + coeff = 0 + else: + # OK, so neither = 0, INF or NaN + shift = len(other._int) - len(self._int) + context.prec + 1 + exp = self._exp - other._exp - shift + op1 = _WorkRep(self) + op2 = _WorkRep(other) + if shift >= 0: + coeff, remainder = divmod(op1.int * 10**shift, op2.int) + else: + coeff, remainder = divmod(op1.int, op2.int * 10**-shift) + if remainder: + # result is not exact; adjust to ensure correct rounding + if coeff % 5 == 0: + coeff += 1 + else: + # result is exact; get as close to ideal exponent as possible + ideal_exp = self._exp - other._exp + while exp < ideal_exp and coeff % 10 == 0: + coeff //= 10 + exp += 1 - if res.int >= prec_limit and shouldround: - return context._raise_error(DivisionImpossible) - otherside = Decimal(op1) - frozen = context._ignore_all_flags() + ans = _dec_from_triple(sign, str(coeff), exp) + return ans._fix(context) - exp = min(self._exp, other._exp) - otherside = otherside._rescale(exp, context=context) + __truediv__ = __div__ - context._regard_flags(*frozen) + def _divide(self, other, context): + """Return (self // other, self % other), to context.prec precision. - return (Decimal(res), otherside) + Assumes that neither self nor other is a NaN, that self is not + infinite and that other is nonzero. + """ + sign = self._sign ^ other._sign + if other._isinfinity(): + ideal_exp = self._exp + else: + ideal_exp = min(self._exp, other._exp) - ans = Decimal(res) - if shouldround: - ans = ans._fix(context) - return ans + expdiff = self.adjusted() - other.adjusted() + if not self or other._isinfinity() or expdiff <= -2: + return (_dec_from_triple(sign, '0', 0), + self._rescale(ideal_exp, context.rounding)) + if expdiff <= context.prec: + op1 = _WorkRep(self) + op2 = _WorkRep(other) + if op1.exp >= op2.exp: + op1.int *= 10**(op1.exp - op2.exp) + else: + op2.int *= 10**(op2.exp - op1.exp) + q, r = divmod(op1.int, op2.int) + if q < 10**context.prec: + return (_dec_from_triple(sign, str(q), 0), + _dec_from_triple(self._sign, str(r), ideal_exp)) + + # Here the quotient is too large to be representable + ans = context._raise_error(DivisionImpossible, + 'quotient too large in //, % or divmod') + return ans, ans def __rdiv__(self, other, context=None): """Swaps self/other and returns __div__.""" @@ -1359,9 +1222,39 @@ def __divmod__(self, other, context=None): """ - (self // other, self % other) + Return (self // other, self % other) """ - return self._divide(other, 1, context) + other = _convert_other(other) + if other is NotImplemented: + return other + + if context is None: + context = getcontext() + + ans = self._check_nans(other, context) + if ans: + return (ans, ans) + + sign = self._sign ^ other._sign + if self._isinfinity(): + if other._isinfinity(): + ans = context._raise_error(InvalidOperation, 'divmod(INF, INF)') + return ans, ans + else: + return (Infsign[sign], + context._raise_error(InvalidOperation, 'INF % x')) + + if not other: + if not self: + ans = context._raise_error(DivisionUndefined, 'divmod(0, 0)') + return ans, ans + else: + return (context._raise_error(DivisionByZero, 'x // 0', sign), + context._raise_error(InvalidOperation, 'x % 0')) + + quotient, remainder = self._divide(other, context) + remainder = remainder._fix(context) + return quotient, remainder def __rdivmod__(self, other, context=None): """Swaps self/other and returns __divmod__.""" @@ -1378,15 +1271,24 @@ if other is NotImplemented: return other - if self._is_special or other._is_special: - ans = self._check_nans(other, context) - if ans: - return ans + if context is None: + context = getcontext() + + ans = self._check_nans(other, context) + if ans: + return ans - if self and not other: - return context._raise_error(InvalidOperation, 'x % 0') + if self._isinfinity(): + return context._raise_error(InvalidOperation, 'INF % x') + elif not other: + if self: + return context._raise_error(InvalidOperation, 'x % 0') + else: + return context._raise_error(DivisionUndefined, '0 % 0') - return self._divide(other, 3, context)[1] + remainder = self._divide(other, context)[1] + remainder = remainder._fix(context) + return remainder def __rmod__(self, other, context=None): """Swaps self/other and returns __mod__.""" @@ -1399,84 +1301,104 @@ """ Remainder nearest to 0- abs(remainder-near) <= other/2 """ - other = _convert_other(other) - if other is NotImplemented: - return other - - if self._is_special or other._is_special: - ans = self._check_nans(other, context) - if ans: - return ans - if self and not other: - return context._raise_error(InvalidOperation, 'x % 0') - if context is None: context = getcontext() - # If DivisionImpossible causes an error, do not leave Rounded/Inexact - # ignored in the calling function. - context = context._shallow_copy() - flags = context._ignore_flags(Rounded, Inexact) - #keep DivisionImpossible flags - (side, r) = self.__divmod__(other, context=context) - - if r._isnan(): - context._regard_flags(*flags) - return r - context = context._shallow_copy() - rounding = context._set_rounding_decision(NEVER_ROUND) + other = _convert_other(other, raiseit=True) - if other._sign: - comparison = other.__div__(Decimal(-2), context=context) - else: - comparison = other.__div__(Decimal(2), context=context) + ans = self._check_nans(other, context) + if ans: + return ans + + # self == +/-infinity -> InvalidOperation + if self._isinfinity(): + return context._raise_error(InvalidOperation, + 'remainder_near(infinity, x)') - context._set_rounding_decision(rounding) - context._regard_flags(*flags) - - s1, s2 = r._sign, comparison._sign - r._sign, comparison._sign = 0, 0 - - if r < comparison: - r._sign, comparison._sign = s1, s2 - #Get flags now - self.__divmod__(other, context=context) - return r._fix(context) - r._sign, comparison._sign = s1, s2 - - rounding = context._set_rounding_decision(NEVER_ROUND) - - (side, r) = self.__divmod__(other, context=context) - context._set_rounding_decision(rounding) - if r._isnan(): - return r - - decrease = not side._iseven() - rounding = context._set_rounding_decision(NEVER_ROUND) - side = side.__abs__(context=context) - context._set_rounding_decision(rounding) - - s1, s2 = r._sign, comparison._sign - r._sign, comparison._sign = 0, 0 - if r > comparison or decrease and r == comparison: - r._sign, comparison._sign = s1, s2 - context.prec += 1 - if len(side.__add__(Decimal(1), context=context)._int) >= context.prec: - context.prec -= 1 - return context._raise_error(DivisionImpossible)[1] - context.prec -= 1 - if self._sign == other._sign: - r = r.__sub__(other, context=context) + # other == 0 -> either InvalidOperation or DivisionUndefined + if not other: + if self: + return context._raise_error(InvalidOperation, + 'remainder_near(x, 0)') else: - r = r.__add__(other, context=context) + return context._raise_error(DivisionUndefined, + 'remainder_near(0, 0)') + + # other = +/-infinity -> remainder = self + if other._isinfinity(): + ans = Decimal(self) + return ans._fix(context) + + # self = 0 -> remainder = self, with ideal exponent + ideal_exponent = min(self._exp, other._exp) + if not self: + ans = _dec_from_triple(self._sign, '0', ideal_exponent) + return ans._fix(context) + + # catch most cases of large or small quotient + expdiff = self.adjusted() - other.adjusted() + if expdiff >= context.prec + 1: + # expdiff >= prec+1 => abs(self/other) > 10**prec + return context._raise_error(DivisionImpossible) + if expdiff <= -2: + # expdiff <= -2 => abs(self/other) < 0.1 + ans = self._rescale(ideal_exponent, context.rounding) + return ans._fix(context) + + # adjust both arguments to have the same exponent, then divide + op1 = _WorkRep(self) + op2 = _WorkRep(other) + if op1.exp >= op2.exp: + op1.int *= 10**(op1.exp - op2.exp) else: - r._sign, comparison._sign = s1, s2 + op2.int *= 10**(op2.exp - op1.exp) + q, r = divmod(op1.int, op2.int) + # remainder is r*10**ideal_exponent; other is +/-op2.int * + # 10**ideal_exponent. Apply correction to ensure that + # abs(remainder) <= abs(other)/2 + if 2*r + (q&1) > op2.int: + r -= op2.int + q += 1 + + if q >= 10**context.prec: + return context._raise_error(DivisionImpossible) + + # result has same sign as self unless r is negative + sign = self._sign + if r < 0: + sign = 1-sign + r = -r - return r._fix(context) + ans = _dec_from_triple(sign, str(r), ideal_exponent) + return ans._fix(context) def __floordiv__(self, other, context=None): """self // other""" - return self._divide(other, 2, context)[0] + other = _convert_other(other) + if other is NotImplemented: + return other + + if context is None: + context = getcontext() + + ans = self._check_nans(other, context) + if ans: + return ans + + if self._isinfinity(): + if other._isinfinity(): + return context._raise_error(InvalidOperation, 'INF // INF') + else: + return Infsign[self._sign ^ other._sign] + + if not other: + if self: + return context._raise_error(DivisionByZero, 'x // 0', + self._sign ^ other._sign) + else: + return context._raise_error(DivisionUndefined, '0 // 0') + + return self._divide(other, context)[0] def __rfloordiv__(self, other, context=None): """Swaps self/other and returns __floordiv__.""" @@ -1496,15 +1418,12 @@ context = getcontext() return context._raise_error(InvalidContext) elif self._isinfinity(): - raise OverflowError, "Cannot convert infinity to long" + raise OverflowError("Cannot convert infinity to long") + s = (-1)**self._sign if self._exp >= 0: - s = ''.join(map(str, self._int)) + '0'*self._exp + return s*int(self._int)*10**self._exp else: - s = ''.join(map(str, self._int))[:self._exp] - if s == '': - s = '0' - sign = '-'*self._sign - return int(sign + s) + return s*int(self._int[:self._exp] or '0') def __long__(self): """Converts to a long. @@ -1513,6 +1432,18 @@ """ return long(self.__int__()) + def _fix_nan(self, context): + """Decapitate the payload of a NaN to fit the context""" + payload = self._int + + # maximum length of payload is precision if _clamp=0, + # precision-1 if _clamp=1. + max_payload_len = context.prec - context._clamp + if len(payload) > max_payload_len: + payload = payload[len(payload)-max_payload_len:].lstrip('0') + return _dec_from_triple(self._sign, payload, self._exp, True) + return Decimal(self) + def _fix(self, context): """Round if it is necessary to keep self within prec precision. @@ -1522,301 +1453,673 @@ self - Decimal instance context - context used. """ - if self._is_special: - return self - if context is None: - context = getcontext() - prec = context.prec - ans = self._fixexponents(context) - if len(ans._int) > prec: - ans = ans._round(prec, context=context) - ans = ans._fixexponents(context) - return ans - def _fixexponents(self, context): - """Fix the exponents and return a copy with the exponent in bounds. - Only call if known to not be a special value. - """ - folddown = context._clamp - Emin = context.Emin - ans = self - ans_adjusted = ans.adjusted() - if ans_adjusted < Emin: - Etiny = context.Etiny() - if ans._exp < Etiny: - if not ans: - ans = Decimal(self) - ans._exp = Etiny - context._raise_error(Clamped) - return ans - ans = ans._rescale(Etiny, context=context) - #It isn't zero, and exp < Emin => subnormal - context._raise_error(Subnormal) - if context.flags[Inexact]: - context._raise_error(Underflow) + if self._is_special: + if self._isnan(): + # decapitate payload if necessary + return self._fix_nan(context) else: - if ans: - #Only raise subnormal if non-zero. - context._raise_error(Subnormal) - else: - Etop = context.Etop() - if folddown and ans._exp > Etop: + # self is +/-Infinity; return unaltered + return Decimal(self) + + # if self is zero then exponent should be between Etiny and + # Emax if _clamp==0, and between Etiny and Etop if _clamp==1. + Etiny = context.Etiny() + Etop = context.Etop() + if not self: + exp_max = [context.Emax, Etop][context._clamp] + new_exp = min(max(self._exp, Etiny), exp_max) + if new_exp != self._exp: context._raise_error(Clamped) - ans = ans._rescale(Etop, context=context) + return _dec_from_triple(self._sign, '0', new_exp) else: - Emax = context.Emax - if ans_adjusted > Emax: - if not ans: - ans = Decimal(self) - ans._exp = Emax - context._raise_error(Clamped) - return ans - context._raise_error(Inexact) - context._raise_error(Rounded) - return context._raise_error(Overflow, 'above Emax', ans._sign) - return ans - - def _round(self, prec=None, rounding=None, context=None): - """Returns a rounded version of self. - - You can specify the precision or rounding method. Otherwise, the - context determines it. - """ - - if self._is_special: - ans = self._check_nans(context=context) - if ans: - return ans - - if self._isinfinity(): return Decimal(self) - if context is None: - context = getcontext() - - if rounding is None: - rounding = context.rounding - if prec is None: - prec = context.prec - - if not self: - if prec <= 0: - dig = (0,) - exp = len(self._int) - prec + self._exp - else: - dig = (0,) * prec - exp = len(self._int) + self._exp - prec - ans = Decimal((self._sign, dig, exp)) + # exp_min is the smallest allowable exponent of the result, + # equal to max(self.adjusted()-context.prec+1, Etiny) + exp_min = len(self._int) + self._exp - context.prec + if exp_min > Etop: + # overflow: exp_min > Etop iff self.adjusted() > Emax + context._raise_error(Inexact) context._raise_error(Rounded) - return ans + return context._raise_error(Overflow, 'above Emax', self._sign) + self_is_subnormal = exp_min < Etiny + if self_is_subnormal: + context._raise_error(Subnormal) + exp_min = Etiny - if prec == 0: - temp = Decimal(self) - temp._int = (0,)+temp._int - prec = 1 - elif prec < 0: - exp = self._exp + len(self._int) - prec - 1 - temp = Decimal( (self._sign, (0, 1), exp)) - prec = 1 - else: - temp = Decimal(self) - - numdigits = len(temp._int) - if prec == numdigits: - return temp - - # See if we need to extend precision - expdiff = prec - numdigits - if expdiff > 0: - tmp = list(temp._int) - tmp.extend([0] * expdiff) - ans = Decimal( (temp._sign, tmp, temp._exp - expdiff)) - return ans - - #OK, but maybe all the lost digits are 0. - lostdigits = self._int[expdiff:] - if lostdigits == (0,) * len(lostdigits): - ans = Decimal( (temp._sign, temp._int[:prec], temp._exp - expdiff)) - #Rounded, but not Inexact + # round if self has too many digits + if self._exp < exp_min: context._raise_error(Rounded) + digits = len(self._int) + self._exp - exp_min + if digits < 0: + self = _dec_from_triple(self._sign, '1', exp_min-1) + digits = 0 + this_function = getattr(self, self._pick_rounding_function[context.rounding]) + changed = this_function(digits) + coeff = self._int[:digits] or '0' + if changed == 1: + coeff = str(int(coeff)+1) + ans = _dec_from_triple(self._sign, coeff, exp_min) + + if changed: + context._raise_error(Inexact) + if self_is_subnormal: + context._raise_error(Underflow) + if not ans: + # raise Clamped on underflow to 0 + context._raise_error(Clamped) + elif len(ans._int) == context.prec+1: + # we get here only if rescaling rounds the + # cofficient up to exactly 10**context.prec + if ans._exp < Etop: + ans = _dec_from_triple(ans._sign, + ans._int[:-1], ans._exp+1) + else: + # Inexact and Rounded have already been raised + ans = context._raise_error(Overflow, 'above Emax', + self._sign) return ans - # Okay, let's round and lose data - - this_function = getattr(temp, self._pick_rounding_function[rounding]) - #Now we've got the rounding function - - if prec != context.prec: - context = context._shallow_copy() - context.prec = prec - ans = this_function(prec, expdiff, context) - context._raise_error(Rounded) - context._raise_error(Inexact, 'Changed in rounding') + # fold down if _clamp == 1 and self has too few digits + if context._clamp == 1 and self._exp > Etop: + context._raise_error(Clamped) + self_padded = self._int + '0'*(self._exp - Etop) + return _dec_from_triple(self._sign, self_padded, Etop) - return ans + # here self was representable to begin with; return unchanged + return Decimal(self) _pick_rounding_function = {} - def _round_down(self, prec, expdiff, context): - """Also known as round-towards-0, truncate.""" - return Decimal( (self._sign, self._int[:prec], self._exp - expdiff) ) - - def _round_half_up(self, prec, expdiff, context, tmp = None): - """Rounds 5 up (away from 0)""" + # for each of the rounding functions below: + # self is a finite, nonzero Decimal + # prec is an integer satisfying 0 <= prec < len(self._int) + # + # each function returns either -1, 0, or 1, as follows: + # 1 indicates that self should be rounded up (away from zero) + # 0 indicates that self should be truncated, and that all the + # digits to be truncated are zeros (so the value is unchanged) + # -1 indicates that there are nonzero digits to be truncated - if tmp is None: - tmp = Decimal( (self._sign,self._int[:prec], self._exp - expdiff)) - if self._int[prec] >= 5: - tmp = tmp._increment(round=0, context=context) - if len(tmp._int) > prec: - return Decimal( (tmp._sign, tmp._int[:-1], tmp._exp + 1)) - return tmp + def _round_down(self, prec): + """Also known as round-towards-0, truncate.""" + if _all_zeros(self._int, prec): + return 0 + else: + return -1 - def _round_half_even(self, prec, expdiff, context): - """Round 5 to even, rest to nearest.""" + def _round_up(self, prec): + """Rounds away from 0.""" + return -self._round_down(prec) - tmp = Decimal( (self._sign, self._int[:prec], self._exp - expdiff)) - half = (self._int[prec] == 5) - if half: - for digit in self._int[prec+1:]: - if digit != 0: - half = 0 - break - if half: - if self._int[prec-1] & 1 == 0: - return tmp - return self._round_half_up(prec, expdiff, context, tmp) + def _round_half_up(self, prec): + """Rounds 5 up (away from 0)""" + if self._int[prec] in '56789': + return 1 + elif _all_zeros(self._int, prec): + return 0 + else: + return -1 - def _round_half_down(self, prec, expdiff, context): + def _round_half_down(self, prec): """Round 5 down""" + if _exact_half(self._int, prec): + return -1 + else: + return self._round_half_up(prec) - tmp = Decimal( (self._sign, self._int[:prec], self._exp - expdiff)) - half = (self._int[prec] == 5) - if half: - for digit in self._int[prec+1:]: - if digit != 0: - half = 0 - break - if half: - return tmp - return self._round_half_up(prec, expdiff, context, tmp) - - def _round_up(self, prec, expdiff, context): - """Rounds away from 0.""" - tmp = Decimal( (self._sign, self._int[:prec], self._exp - expdiff) ) - for digit in self._int[prec:]: - if digit != 0: - tmp = tmp._increment(round=1, context=context) - if len(tmp._int) > prec: - return Decimal( (tmp._sign, tmp._int[:-1], tmp._exp + 1)) - else: - return tmp - return tmp + def _round_half_even(self, prec): + """Round 5 to even, rest to nearest.""" + if _exact_half(self._int, prec) and \ + (prec == 0 or self._int[prec-1] in '02468'): + return -1 + else: + return self._round_half_up(prec) - def _round_ceiling(self, prec, expdiff, context): + def _round_ceiling(self, prec): """Rounds up (not away from 0 if negative.)""" if self._sign: - return self._round_down(prec, expdiff, context) + return self._round_down(prec) else: - return self._round_up(prec, expdiff, context) + return -self._round_down(prec) - def _round_floor(self, prec, expdiff, context): + def _round_floor(self, prec): """Rounds down (not towards 0 if negative)""" if not self._sign: - return self._round_down(prec, expdiff, context) + return self._round_down(prec) + else: + return -self._round_down(prec) + + def _round_05up(self, prec): + """Round down unless digit prec-1 is 0 or 5.""" + if prec and self._int[prec-1] not in '05': + return self._round_down(prec) else: - return self._round_up(prec, expdiff, context) + return -self._round_down(prec) - def __pow__(self, n, modulo = None, context=None): - """Return self ** n (mod modulo) + def fma(self, other, third, context=None): + """Fused multiply-add. - If modulo is None (default), don't take it mod modulo. + Returns self*other+third with no rounding of the intermediate + product self*other. + + self and other are multiplied together, with no rounding of + the result. The third operand is then added to the result, + and a single final rounding is performed. """ - n = _convert_other(n) - if n is NotImplemented: - return n + + other = _convert_other(other, raiseit=True) + + # compute product; raise InvalidOperation if either operand is + # a signaling NaN or if the product is zero times infinity. + if self._is_special or other._is_special: + if context is None: + context = getcontext() + if self._exp == 'N': + return context._raise_error(InvalidOperation, 'sNaN', self) + if other._exp == 'N': + return context._raise_error(InvalidOperation, 'sNaN', other) + if self._exp == 'n': + product = self + elif other._exp == 'n': + product = other + elif self._exp == 'F': + if not other: + return context._raise_error(InvalidOperation, + 'INF * 0 in fma') + product = Infsign[self._sign ^ other._sign] + elif other._exp == 'F': + if not self: + return context._raise_error(InvalidOperation, + '0 * INF in fma') + product = Infsign[self._sign ^ other._sign] + else: + product = _dec_from_triple(self._sign ^ other._sign, + str(int(self._int) * int(other._int)), + self._exp + other._exp) + + third = _convert_other(third, raiseit=True) + return product.__add__(third, context) + + def _power_modulo(self, other, modulo, context=None): + """Three argument version of __pow__""" + + # if can't convert other and modulo to Decimal, raise + # TypeError; there's no point returning NotImplemented (no + # equivalent of __rpow__ for three argument pow) + other = _convert_other(other, raiseit=True) + modulo = _convert_other(modulo, raiseit=True) if context is None: context = getcontext() - if self._is_special or n._is_special or n.adjusted() > 8: - #Because the spot << doesn't work with really big exponents - if n._isinfinity() or n.adjusted() > 8: - return context._raise_error(InvalidOperation, 'x ** INF') + # deal with NaNs: if there are any sNaNs then first one wins, + # (i.e. behaviour for NaNs is identical to that of fma) + self_is_nan = self._isnan() + other_is_nan = other._isnan() + modulo_is_nan = modulo._isnan() + if self_is_nan or other_is_nan or modulo_is_nan: + if self_is_nan == 2: + return context._raise_error(InvalidOperation, 'sNaN', + self) + if other_is_nan == 2: + return context._raise_error(InvalidOperation, 'sNaN', + other) + if modulo_is_nan == 2: + return context._raise_error(InvalidOperation, 'sNaN', + modulo) + if self_is_nan: + return self._fix_nan(context) + if other_is_nan: + return other._fix_nan(context) + return modulo._fix_nan(context) + + # check inputs: we apply same restrictions as Python's pow() + if not (self._isinteger() and + other._isinteger() and + modulo._isinteger()): + return context._raise_error(InvalidOperation, + 'pow() 3rd argument not allowed ' + 'unless all arguments are integers') + if other < 0: + return context._raise_error(InvalidOperation, + 'pow() 2nd argument cannot be ' + 'negative when 3rd argument specified') + if not modulo: + return context._raise_error(InvalidOperation, + 'pow() 3rd argument cannot be 0') + + # additional restriction for decimal: the modulus must be less + # than 10**prec in absolute value + if modulo.adjusted() >= context.prec: + return context._raise_error(InvalidOperation, + 'insufficient precision: pow() 3rd ' + 'argument must not have more than ' + 'precision digits') + + # define 0**0 == NaN, for consistency with two-argument pow + # (even though it hurts!) + if not other and not self: + return context._raise_error(InvalidOperation, + 'at least one of pow() 1st argument ' + 'and 2nd argument must be nonzero ;' + '0**0 is not defined') - ans = self._check_nans(n, context) - if ans: - return ans + # compute sign of result + if other._iseven(): + sign = 0 + else: + sign = self._sign - if not n._isinteger(): - return context._raise_error(InvalidOperation, 'x ** (non-integer)') + # convert modulo to a Python integer, and self and other to + # Decimal integers (i.e. force their exponents to be >= 0) + modulo = abs(int(modulo)) + base = _WorkRep(self.to_integral_value()) + exponent = _WorkRep(other.to_integral_value()) + + # compute result using integer pow() + base = (base.int % modulo * pow(10, base.exp, modulo)) % modulo + for i in xrange(exponent.exp): + base = pow(base, 10, modulo) + base = pow(base, exponent.int, modulo) + + return _dec_from_triple(sign, str(base), 0) + + def _power_exact(self, other, p): + """Attempt to compute self**other exactly. + + Given Decimals self and other and an integer p, attempt to + compute an exact result for the power self**other, with p + digits of precision. Return None if self**other is not + exactly representable in p digits. + + Assumes that elimination of special cases has already been + performed: self and other must both be nonspecial; self must + be positive and not numerically equal to 1; other must be + nonzero. For efficiency, other._exp should not be too large, + so that 10**abs(other._exp) is a feasible calculation.""" + + # In the comments below, we write x for the value of self and + # y for the value of other. Write x = xc*10**xe and y = + # yc*10**ye. + + # The main purpose of this method is to identify the *failure* + # of x**y to be exactly representable with as little effort as + # possible. So we look for cheap and easy tests that + # eliminate the possibility of x**y being exact. Only if all + # these tests are passed do we go on to actually compute x**y. + + # Here's the main idea. First normalize both x and y. We + # express y as a rational m/n, with m and n relatively prime + # and n>0. Then for x**y to be exactly representable (at + # *any* precision), xc must be the nth power of a positive + # integer and xe must be divisible by n. If m is negative + # then additionally xc must be a power of either 2 or 5, hence + # a power of 2**n or 5**n. + # + # There's a limit to how small |y| can be: if y=m/n as above + # then: + # + # (1) if xc != 1 then for the result to be representable we + # need xc**(1/n) >= 2, and hence also xc**|y| >= 2. So + # if |y| <= 1/nbits(xc) then xc < 2**nbits(xc) <= + # 2**(1/|y|), hence xc**|y| < 2 and the result is not + # representable. + # + # (2) if xe != 0, |xe|*(1/n) >= 1, so |xe|*|y| >= 1. Hence if + # |y| < 1/|xe| then the result is not representable. + # + # Note that since x is not equal to 1, at least one of (1) and + # (2) must apply. Now |y| < 1/nbits(xc) iff |yc|*nbits(xc) < + # 10**-ye iff len(str(|yc|*nbits(xc)) <= -ye. + # + # There's also a limit to how large y can be, at least if it's + # positive: the normalized result will have coefficient xc**y, + # so if it's representable then xc**y < 10**p, and y < + # p/log10(xc). Hence if y*log10(xc) >= p then the result is + # not exactly representable. + + # if len(str(abs(yc*xe)) <= -ye then abs(yc*xe) < 10**-ye, + # so |y| < 1/xe and the result is not representable. + # Similarly, len(str(abs(yc)*xc_bits)) <= -ye implies |y| + # < 1/nbits(xc). + + x = _WorkRep(self) + xc, xe = x.int, x.exp + while xc % 10 == 0: + xc //= 10 + xe += 1 + + y = _WorkRep(other) + yc, ye = y.int, y.exp + while yc % 10 == 0: + yc //= 10 + ye += 1 + + # case where xc == 1: result is 10**(xe*y), with xe*y + # required to be an integer + if xc == 1: + if ye >= 0: + exponent = xe*yc*10**ye + else: + exponent, remainder = divmod(xe*yc, 10**-ye) + if remainder: + return None + if y.sign == 1: + exponent = -exponent + # if other is a nonnegative integer, use ideal exponent + if other._isinteger() and other._sign == 0: + ideal_exponent = self._exp*int(other) + zeros = min(exponent-ideal_exponent, p-1) + else: + zeros = 0 + return _dec_from_triple(0, '1' + '0'*zeros, exponent-zeros) - if not self and not n: - return context._raise_error(InvalidOperation, '0 ** 0') + # case where y is negative: xc must be either a power + # of 2 or a power of 5. + if y.sign == 1: + last_digit = xc % 10 + if last_digit in (2,4,6,8): + # quick test for power of 2 + if xc & -xc != xc: + return None + # now xc is a power of 2; e is its exponent + e = _nbits(xc)-1 + # find e*y and xe*y; both must be integers + if ye >= 0: + y_as_int = yc*10**ye + e = e*y_as_int + xe = xe*y_as_int + else: + ten_pow = 10**-ye + e, remainder = divmod(e*yc, ten_pow) + if remainder: + return None + xe, remainder = divmod(xe*yc, ten_pow) + if remainder: + return None + + if e*65 >= p*93: # 93/65 > log(10)/log(5) + return None + xc = 5**e + + elif last_digit == 5: + # e >= log_5(xc) if xc is a power of 5; we have + # equality all the way up to xc=5**2658 + e = _nbits(xc)*28//65 + xc, remainder = divmod(5**e, xc) + if remainder: + return None + while xc % 5 == 0: + xc //= 5 + e -= 1 + if ye >= 0: + y_as_integer = yc*10**ye + e = e*y_as_integer + xe = xe*y_as_integer + else: + ten_pow = 10**-ye + e, remainder = divmod(e*yc, ten_pow) + if remainder: + return None + xe, remainder = divmod(xe*yc, ten_pow) + if remainder: + return None + if e*3 >= p*10: # 10/3 > log(10)/log(2) + return None + xc = 2**e + else: + return None + + if xc >= 10**p: + return None + xe = -e-xe + return _dec_from_triple(0, str(xc), xe) + + # now y is positive; find m and n such that y = m/n + if ye >= 0: + m, n = yc*10**ye, 1 + else: + if xe != 0 and len(str(abs(yc*xe))) <= -ye: + return None + xc_bits = _nbits(xc) + if xc != 1 and len(str(abs(yc)*xc_bits)) <= -ye: + return None + m, n = yc, 10**(-ye) + while m % 2 == n % 2 == 0: + m //= 2 + n //= 2 + while m % 5 == n % 5 == 0: + m //= 5 + n //= 5 + + # compute nth root of xc*10**xe + if n > 1: + # if 1 < xc < 2**n then xc isn't an nth power + if xc != 1 and xc_bits <= n: + return None + + xe, rem = divmod(xe, n) + if rem != 0: + return None + + # compute nth root of xc using Newton's method + a = 1L << -(-_nbits(xc)//n) # initial estimate + while True: + q, r = divmod(xc, a**(n-1)) + if a <= q: + break + else: + a = (a*(n-1) + q)//n + if not (a == q and r == 0): + return None + xc = a + + # now xc*10**xe is the nth root of the original xc*10**xe + # compute mth power of xc*10**xe + + # if m > p*100//_log10_lb(xc) then m > p/log10(xc), hence xc**m > + # 10**p and the result is not representable. + if xc > 1 and m > p*100//_log10_lb(xc): + return None + xc = xc**m + xe *= m + if xc > 10**p: + return None + + # by this point the result *is* exactly representable + # adjust the exponent to get as close as possible to the ideal + # exponent, if necessary + str_xc = str(xc) + if other._isinteger() and other._sign == 0: + ideal_exponent = self._exp*int(other) + zeros = min(xe-ideal_exponent, p-len(str_xc)) + else: + zeros = 0 + return _dec_from_triple(0, str_xc+'0'*zeros, xe-zeros) + + def __pow__(self, other, modulo=None, context=None): + """Return self ** other [ % modulo]. - if not n: - return Decimal(1) + With two arguments, compute self**other. - if self == Decimal(1): - return Decimal(1) + With three arguments, compute (self**other) % modulo. For the + three argument form, the following restrictions on the + arguments hold: - sign = self._sign and not n._iseven() - n = int(n) + - all three arguments must be integral + - other must be nonnegative + - either self or other (or both) must be nonzero + - modulo must be nonzero and must have at most p digits, + where p is the context precision. + + If any of these restrictions is violated the InvalidOperation + flag is raised. + + The result of pow(self, other, modulo) is identical to the + result that would be obtained by computing (self**other) % + modulo with unbounded precision, but is computed more + efficiently. It is always exact. + """ + if modulo is not None: + return self._power_modulo(other, modulo, context) + + other = _convert_other(other) + if other is NotImplemented: + return other + + if context is None: + context = getcontext() + + # either argument is a NaN => result is NaN + ans = self._check_nans(other, context) + if ans: + return ans + + # 0**0 = NaN (!), x**0 = 1 for nonzero x (including +/-Infinity) + if not other: + if not self: + return context._raise_error(InvalidOperation, '0 ** 0') + else: + return Dec_p1 + + # result has sign 1 iff self._sign is 1 and other is an odd integer + result_sign = 0 + if self._sign == 1: + if other._isinteger(): + if not other._iseven(): + result_sign = 1 + else: + # -ve**noninteger = NaN + # (-0)**noninteger = 0**noninteger + if self: + return context._raise_error(InvalidOperation, + 'x ** y with x negative and y not an integer') + # negate self, without doing any unwanted rounding + self = self.copy_negate() + + # 0**(+ve or Inf)= 0; 0**(-ve or -Inf) = Infinity + if not self: + if other._sign == 0: + return _dec_from_triple(result_sign, '0', 0) + else: + return Infsign[result_sign] + + # Inf**(+ve or Inf) = Inf; Inf**(-ve or -Inf) = 0 if self._isinfinity(): - if modulo: - return context._raise_error(InvalidOperation, 'INF % x') - if n > 0: - return Infsign[sign] - return Decimal( (sign, (0,), 0) ) + if other._sign == 0: + return Infsign[result_sign] + else: + return _dec_from_triple(result_sign, '0', 0) - #with ludicrously large exponent, just raise an overflow and return inf. - if not modulo and n > 0 and (self._exp + len(self._int) - 1) * n > context.Emax \ - and self: + # 1**other = 1, but the choice of exponent and the flags + # depend on the exponent of self, and on whether other is a + # positive integer, a negative integer, or neither + if self == Dec_p1: + if other._isinteger(): + # exp = max(self._exp*max(int(other), 0), + # 1-context.prec) but evaluating int(other) directly + # is dangerous until we know other is small (other + # could be 1e999999999) + if other._sign == 1: + multiplier = 0 + elif other > context.prec: + multiplier = context.prec + else: + multiplier = int(other) - tmp = Decimal('inf') - tmp._sign = sign - context._raise_error(Rounded) - context._raise_error(Inexact) - context._raise_error(Overflow, 'Big power', sign) - return tmp + exp = self._exp * multiplier + if exp < 1-context.prec: + exp = 1-context.prec + context._raise_error(Rounded) + else: + context._raise_error(Inexact) + context._raise_error(Rounded) + exp = 1-context.prec + + return _dec_from_triple(result_sign, '1'+'0'*-exp, exp) + + # compute adjusted exponent of self + self_adj = self.adjusted() + + # self ** infinity is infinity if self > 1, 0 if self < 1 + # self ** -infinity is infinity if self < 1, 0 if self > 1 + if other._isinfinity(): + if (other._sign == 0) == (self_adj < 0): + return _dec_from_triple(result_sign, '0', 0) + else: + return Infsign[result_sign] + + # from here on, the result always goes through the call + # to _fix at the end of this function. + ans = None + + # crude test to catch cases of extreme overflow/underflow. If + # log10(self)*other >= 10**bound and bound >= len(str(Emax)) + # then 10**bound >= 10**len(str(Emax)) >= Emax+1 and hence + # self**other >= 10**(Emax+1), so overflow occurs. The test + # for underflow is similar. + bound = self._log10_exp_bound() + other.adjusted() + if (self_adj >= 0) == (other._sign == 0): + # self > 1 and other +ve, or self < 1 and other -ve + # possibility of overflow + if bound >= len(str(context.Emax)): + ans = _dec_from_triple(result_sign, '1', context.Emax+1) + else: + # self > 1 and other -ve, or self < 1 and other +ve + # possibility of underflow to 0 + Etiny = context.Etiny() + if bound >= len(str(-Etiny)): + ans = _dec_from_triple(result_sign, '1', Etiny-1) - elength = len(str(abs(n))) - firstprec = context.prec + # try for an exact result with precision +1 + if ans is None: + ans = self._power_exact(other, context.prec + 1) + if ans is not None and result_sign == 1: + ans = _dec_from_triple(1, ans._int, ans._exp) + + # usual case: inexact result, x**y computed directly as exp(y*log(x)) + if ans is None: + p = context.prec + x = _WorkRep(self) + xc, xe = x.int, x.exp + y = _WorkRep(other) + yc, ye = y.int, y.exp + if y.sign == 1: + yc = -yc + + # compute correctly rounded result: start with precision +3, + # then increase precision until result is unambiguously roundable + extra = 3 + while True: + coeff, exp = _dpower(xc, xe, yc, ye, p+extra) + if coeff % (5*10**(len(str(coeff))-p-1)): + break + extra += 3 - if not modulo and firstprec + elength + 1 > DefaultContext.Emax: - return context._raise_error(Overflow, 'Too much precision.', sign) + ans = _dec_from_triple(result_sign, str(coeff), exp) - mul = Decimal(self) - val = Decimal(1) - context = context._shallow_copy() - context.prec = firstprec + elength + 1 - if n < 0: - #n is a long now, not Decimal instance - n = -n - mul = Decimal(1).__div__(mul, context=context) - - spot = 1 - while spot <= n: - spot <<= 1 - - spot >>= 1 - #Spot is the highest power of 2 less than n - while spot: - val = val.__mul__(val, context=context) - if val._isinfinity(): - val = Infsign[sign] - break - if spot & n: - val = val.__mul__(mul, context=context) - if modulo is not None: - val = val.__mod__(modulo, context=context) - spot >>= 1 - context.prec = firstprec - - if context._rounding_decision == ALWAYS_ROUND: - return val._fix(context) - return val + # the specification says that for non-integer other we need to + # raise Inexact, even when the result is actually exact. In + # the same way, we need to raise Underflow here if the result + # is subnormal. (The call to _fix will take care of raising + # Rounded and Subnormal, as usual.) + if not other._isinteger(): + context._raise_error(Inexact) + # pad with zeros up to length context.prec+1 if necessary + if len(ans._int) <= context.prec: + expdiff = context.prec+1 - len(ans._int) + ans = _dec_from_triple(ans._sign, ans._int+'0'*expdiff, + ans._exp-expdiff) + if ans.adjusted() < context.Emin: + context._raise_error(Underflow) + + # unlike exp, ln and log10, the power function respects the + # rounding mode; no need to use ROUND_HALF_EVEN here + ans = ans._fix(context) + return ans def __rpow__(self, other, context=None): """Swaps self/other and returns __pow__.""" @@ -1828,6 +2131,9 @@ def normalize(self, context=None): """Normalize- strip trailing 0s, change anything equal to 0 to 0e0""" + if context is None: + context = getcontext() + if self._is_special: ans = self._check_nans(context=context) if ans: @@ -1838,20 +2144,27 @@ return dup if not dup: - return Decimal( (dup._sign, (0,), 0) ) + return _dec_from_triple(dup._sign, '0', 0) + exp_max = [context.Emax, context.Etop()][context._clamp] end = len(dup._int) exp = dup._exp - while dup._int[end-1] == 0: + while dup._int[end-1] == '0' and exp < exp_max: exp += 1 end -= 1 - return Decimal( (dup._sign, dup._int[:end], exp) ) - + return _dec_from_triple(dup._sign, dup._int[:end], exp) - def quantize(self, exp, rounding=None, context=None, watchexp=1): + def quantize(self, exp, rounding=None, context=None, watchexp=True): """Quantize self so its exponent is the same as that of exp. Similar to self._rescale(exp._exp) but with error checking. """ + exp = _convert_other(exp, raiseit=True) + + if context is None: + context = getcontext() + if rounding is None: + rounding = context.rounding + if self._is_special or exp._is_special: ans = self._check_nans(exp, context) if ans: @@ -1859,337 +2172,1157 @@ if exp._isinfinity() or self._isinfinity(): if exp._isinfinity() and self._isinfinity(): - return self #if both are inf, it is OK - if context is None: - context = getcontext() + return Decimal(self) # if both are inf, it is OK return context._raise_error(InvalidOperation, 'quantize with one INF') - return self._rescale(exp._exp, rounding, context, watchexp) + + # if we're not watching exponents, do a simple rescale + if not watchexp: + ans = self._rescale(exp._exp, rounding) + # raise Inexact and Rounded where appropriate + if ans._exp > self._exp: + context._raise_error(Rounded) + if ans != self: + context._raise_error(Inexact) + return ans + + # exp._exp should be between Etiny and Emax + if not (context.Etiny() <= exp._exp <= context.Emax): + return context._raise_error(InvalidOperation, + 'target exponent out of bounds in quantize') + + if not self: + ans = _dec_from_triple(self._sign, '0', exp._exp) + return ans._fix(context) + + self_adjusted = self.adjusted() + if self_adjusted > context.Emax: + return context._raise_error(InvalidOperation, + 'exponent of quantize result too large for current context') + if self_adjusted - exp._exp + 1 > context.prec: + return context._raise_error(InvalidOperation, + 'quantize result has too many digits for current context') + + ans = self._rescale(exp._exp, rounding) + if ans.adjusted() > context.Emax: + return context._raise_error(InvalidOperation, + 'exponent of quantize result too large for current context') + if len(ans._int) > context.prec: + return context._raise_error(InvalidOperation, + 'quantize result has too many digits for current context') + + # raise appropriate flags + if ans._exp > self._exp: + context._raise_error(Rounded) + if ans != self: + context._raise_error(Inexact) + if ans and ans.adjusted() < context.Emin: + context._raise_error(Subnormal) + + # call to fix takes care of any necessary folddown + ans = ans._fix(context) + return ans def same_quantum(self, other): - """Test whether self and other have the same exponent. + """Return True if self and other have the same exponent; otherwise + return False. - same as self._exp == other._exp, except NaN == sNaN + If either operand is a special value, the following rules are used: + * return True if both operands are infinities + * return True if both operands are NaNs + * otherwise, return False. """ + other = _convert_other(other, raiseit=True) if self._is_special or other._is_special: - if self._isnan() or other._isnan(): - return self._isnan() and other._isnan() and True - if self._isinfinity() or other._isinfinity(): - return self._isinfinity() and other._isinfinity() and True + return (self.is_nan() and other.is_nan() or + self.is_infinite() and other.is_infinite()) return self._exp == other._exp - def _rescale(self, exp, rounding=None, context=None, watchexp=1): - """Rescales so that the exponent is exp. + def _rescale(self, exp, rounding): + """Rescale self so that the exponent is exp, either by padding with zeros + or by truncating digits, using the given rounding mode. + + Specials are returned without change. This operation is + quiet: it raises no flags, and uses no information from the + context. exp = exp to scale to (an integer) - rounding = rounding version - watchexp: if set (default) an error is returned if exp is greater - than Emax or less than Etiny. + rounding = rounding mode + """ + if self._is_special: + return Decimal(self) + if not self: + return _dec_from_triple(self._sign, '0', exp) + + if self._exp >= exp: + # pad answer with zeros if necessary + return _dec_from_triple(self._sign, + self._int + '0'*(self._exp - exp), exp) + + # too many digits; round and lose data. If self.adjusted() < + # exp-1, replace self by 10**(exp-1) before rounding + digits = len(self._int) + self._exp - exp + if digits < 0: + self = _dec_from_triple(self._sign, '1', exp-1) + digits = 0 + this_function = getattr(self, self._pick_rounding_function[rounding]) + changed = this_function(digits) + coeff = self._int[:digits] or '0' + if changed == 1: + coeff = str(int(coeff)+1) + return _dec_from_triple(self._sign, coeff, exp) + + def to_integral_exact(self, rounding=None, context=None): + """Rounds to a nearby integer. + + If no rounding mode is specified, take the rounding mode from + the context. This method raises the Rounded and Inexact flags + when appropriate. + + See also: to_integral_value, which does exactly the same as + this method except that it doesn't raise Inexact or Rounded. """ + if self._is_special: + ans = self._check_nans(context=context) + if ans: + return ans + return Decimal(self) + if self._exp >= 0: + return Decimal(self) + if not self: + return _dec_from_triple(self._sign, '0', 0) if context is None: context = getcontext() + if rounding is None: + rounding = context.rounding + context._raise_error(Rounded) + ans = self._rescale(0, rounding) + if ans != self: + context._raise_error(Inexact) + return ans + def to_integral_value(self, rounding=None, context=None): + """Rounds to the nearest integer, without raising inexact, rounded.""" + if context is None: + context = getcontext() + if rounding is None: + rounding = context.rounding if self._is_special: - if self._isinfinity(): - return context._raise_error(InvalidOperation, 'rescale with an INF') + ans = self._check_nans(context=context) + if ans: + return ans + return Decimal(self) + if self._exp >= 0: + return Decimal(self) + else: + return self._rescale(0, rounding) + + # the method name changed, but we provide also the old one, for compatibility + to_integral = to_integral_value + def sqrt(self, context=None): + """Return the square root of self.""" + if self._is_special: ans = self._check_nans(context=context) if ans: return ans - if watchexp and (context.Emax < exp or context.Etiny() > exp): - return context._raise_error(InvalidOperation, 'rescale(a, INF)') + if self._isinfinity() and self._sign == 0: + return Decimal(self) if not self: - ans = Decimal(self) - ans._int = (0,) - ans._exp = exp + # exponent = self._exp // 2. sqrt(-0) = -0 + ans = _dec_from_triple(self._sign, '0', self._exp // 2) + return ans._fix(context) + + if context is None: + context = getcontext() + + if self._sign == 1: + return context._raise_error(InvalidOperation, 'sqrt(-x), x > 0') + + # At this point self represents a positive number. Let p be + # the desired precision and express self in the form c*100**e + # with c a positive real number and e an integer, c and e + # being chosen so that 100**(p-1) <= c < 100**p. Then the + # (exact) square root of self is sqrt(c)*10**e, and 10**(p-1) + # <= sqrt(c) < 10**p, so the closest representable Decimal at + # precision p is n*10**e where n = round_half_even(sqrt(c)), + # the closest integer to sqrt(c) with the even integer chosen + # in the case of a tie. + # + # To ensure correct rounding in all cases, we use the + # following trick: we compute the square root to an extra + # place (precision p+1 instead of precision p), rounding down. + # Then, if the result is inexact and its last digit is 0 or 5, + # we increase the last digit to 1 or 6 respectively; if it's + # exact we leave the last digit alone. Now the final round to + # p places (or fewer in the case of underflow) will round + # correctly and raise the appropriate flags. + + # use an extra digit of precision + prec = context.prec+1 + + # write argument in the form c*100**e where e = self._exp//2 + # is the 'ideal' exponent, to be used if the square root is + # exactly representable. l is the number of 'digits' of c in + # base 100, so that 100**(l-1) <= c < 100**l. + op = _WorkRep(self) + e = op.exp >> 1 + if op.exp & 1: + c = op.int * 10 + l = (len(self._int) >> 1) + 1 + else: + c = op.int + l = len(self._int)+1 >> 1 + + # rescale so that c has exactly prec base 100 'digits' + shift = prec-l + if shift >= 0: + c *= 100**shift + exact = True + else: + c, remainder = divmod(c, 100**-shift) + exact = not remainder + e -= shift + + # find n = floor(sqrt(c)) using Newton's method + n = 10**prec + while True: + q = c//n + if n <= q: + break + else: + n = n + q >> 1 + exact = exact and n*n == c + + if exact: + # result is exact; rescale to use ideal exponent e + if shift >= 0: + # assert n % 10**shift == 0 + n //= 10**shift + else: + n *= 10**-shift + e += shift + else: + # result is not exact; fix last digit as described above + if n % 5 == 0: + n += 1 + + ans = _dec_from_triple(0, str(n), e) + + # round, and fit to current context + context = context._shallow_copy() + rounding = context._set_rounding(ROUND_HALF_EVEN) + ans = ans._fix(context) + context.rounding = rounding + + return ans + + def max(self, other, context=None): + """Returns the larger value. + + Like max(self, other) except if one is not a number, returns + NaN (and signals if one is sNaN). Also rounds. + """ + other = _convert_other(other, raiseit=True) + + if context is None: + context = getcontext() + + if self._is_special or other._is_special: + # If one operand is a quiet NaN and the other is number, then the + # number is always returned + sn = self._isnan() + on = other._isnan() + if sn or on: + if on == 1 and sn != 2: + return self._fix_nan(context) + if sn == 1 and on != 2: + return other._fix_nan(context) + return self._check_nans(other, context) + + c = self.__cmp__(other) + if c == 0: + # If both operands are finite and equal in numerical value + # then an ordering is applied: + # + # If the signs differ then max returns the operand with the + # positive sign and min returns the operand with the negative sign + # + # If the signs are the same then the exponent is used to select + # the result. This is exactly the ordering used in compare_total. + c = self.compare_total(other) + + if c == -1: + ans = other + else: + ans = self + + return ans._fix(context) + + def min(self, other, context=None): + """Returns the smaller value. + + Like min(self, other) except if one is not a number, returns + NaN (and signals if one is sNaN). Also rounds. + """ + other = _convert_other(other, raiseit=True) + + if context is None: + context = getcontext() + + if self._is_special or other._is_special: + # If one operand is a quiet NaN and the other is number, then the + # number is always returned + sn = self._isnan() + on = other._isnan() + if sn or on: + if on == 1 and sn != 2: + return self._fix_nan(context) + if sn == 1 and on != 2: + return other._fix_nan(context) + return self._check_nans(other, context) + + c = self.__cmp__(other) + if c == 0: + c = self.compare_total(other) + + if c == -1: + ans = self + else: + ans = other + + return ans._fix(context) + + def _isinteger(self): + """Returns whether self is an integer""" + if self._is_special: + return False + if self._exp >= 0: + return True + rest = self._int[self._exp:] + return rest == '0'*len(rest) + + def _iseven(self): + """Returns True if self is even. Assumes self is an integer.""" + if not self or self._exp > 0: + return True + return self._int[-1+self._exp] in '02468' + + def adjusted(self): + """Return the adjusted exponent of self""" + try: + return self._exp + len(self._int) - 1 + # If NaN or Infinity, self._exp is string + except TypeError: + return 0 + + def canonical(self, context=None): + """Returns the same Decimal object. + + As we do not have different encodings for the same number, the + received object already is in its canonical form. + """ + return self + + def compare_signal(self, other, context=None): + """Compares self to the other operand numerically. + + It's pretty much like compare(), but all NaNs signal, with signaling + NaNs taking precedence over quiet NaNs. + """ + if context is None: + context = getcontext() + + self_is_nan = self._isnan() + other_is_nan = other._isnan() + if self_is_nan == 2: + return context._raise_error(InvalidOperation, 'sNaN', + self) + if other_is_nan == 2: + return context._raise_error(InvalidOperation, 'sNaN', + other) + if self_is_nan: + return context._raise_error(InvalidOperation, 'NaN in compare_signal', + self) + if other_is_nan: + return context._raise_error(InvalidOperation, 'NaN in compare_signal', + other) + return self.compare(other, context=context) + + def compare_total(self, other): + """Compares self to other using the abstract representations. + + This is not like the standard compare, which use their numerical + value. Note that a total ordering is defined for all possible abstract + representations. + """ + # if one is negative and the other is positive, it's easy + if self._sign and not other._sign: + return Dec_n1 + if not self._sign and other._sign: + return Dec_p1 + sign = self._sign + + # let's handle both NaN types + self_nan = self._isnan() + other_nan = other._isnan() + if self_nan or other_nan: + if self_nan == other_nan: + if self._int < other._int: + if sign: + return Dec_p1 + else: + return Dec_n1 + if self._int > other._int: + if sign: + return Dec_n1 + else: + return Dec_p1 + return Dec_0 + + if sign: + if self_nan == 1: + return Dec_n1 + if other_nan == 1: + return Dec_p1 + if self_nan == 2: + return Dec_n1 + if other_nan == 2: + return Dec_p1 + else: + if self_nan == 1: + return Dec_p1 + if other_nan == 1: + return Dec_n1 + if self_nan == 2: + return Dec_p1 + if other_nan == 2: + return Dec_n1 + + if self < other: + return Dec_n1 + if self > other: + return Dec_p1 + + if self._exp < other._exp: + if sign: + return Dec_p1 + else: + return Dec_n1 + if self._exp > other._exp: + if sign: + return Dec_n1 + else: + return Dec_p1 + return Dec_0 + + + def compare_total_mag(self, other): + """Compares self to other using abstract repr., ignoring sign. + + Like compare_total, but with operand's sign ignored and assumed to be 0. + """ + s = self.copy_abs() + o = other.copy_abs() + return s.compare_total(o) + + def copy_abs(self): + """Returns a copy with the sign set to 0. """ + return _dec_from_triple(0, self._int, self._exp, self._is_special) + + def copy_negate(self): + """Returns a copy with the sign inverted.""" + if self._sign: + return _dec_from_triple(0, self._int, self._exp, self._is_special) + else: + return _dec_from_triple(1, self._int, self._exp, self._is_special) + + def copy_sign(self, other): + """Returns self with the sign of other.""" + return _dec_from_triple(other._sign, self._int, + self._exp, self._is_special) + + def exp(self, context=None): + """Returns e ** self.""" + + if context is None: + context = getcontext() + + # exp(NaN) = NaN + ans = self._check_nans(context=context) + if ans: + return ans + + # exp(-Infinity) = 0 + if self._isinfinity() == -1: + return Dec_0 + + # exp(0) = 1 + if not self: + return Dec_p1 + + # exp(Infinity) = Infinity + if self._isinfinity() == 1: + return Decimal(self) + + # the result is now guaranteed to be inexact (the true + # mathematical result is transcendental). There's no need to + # raise Rounded and Inexact here---they'll always be raised as + # a result of the call to _fix. + p = context.prec + adj = self.adjusted() + + # we only need to do any computation for quite a small range + # of adjusted exponents---for example, -29 <= adj <= 10 for + # the default context. For smaller exponent the result is + # indistinguishable from 1 at the given precision, while for + # larger exponent the result either overflows or underflows. + if self._sign == 0 and adj > len(str((context.Emax+1)*3)): + # overflow + ans = _dec_from_triple(0, '1', context.Emax+1) + elif self._sign == 1 and adj > len(str((-context.Etiny()+1)*3)): + # underflow to 0 + ans = _dec_from_triple(0, '1', context.Etiny()-1) + elif self._sign == 0 and adj < -p: + # p+1 digits; final round will raise correct flags + ans = _dec_from_triple(0, '1' + '0'*(p-1) + '1', -p) + elif self._sign == 1 and adj < -p-1: + # p+1 digits; final round will raise correct flags + ans = _dec_from_triple(0, '9'*(p+1), -p-1) + # general case + else: + op = _WorkRep(self) + c, e = op.int, op.exp + if op.sign == 1: + c = -c + + # compute correctly rounded result: increase precision by + # 3 digits at a time until we get an unambiguously + # roundable result + extra = 3 + while True: + coeff, exp = _dexp(c, e, p+extra) + if coeff % (5*10**(len(str(coeff))-p-1)): + break + extra += 3 + + ans = _dec_from_triple(0, str(coeff), exp) + + # at this stage, ans should round correctly with *any* + # rounding mode, not just with ROUND_HALF_EVEN + context = context._shallow_copy() + rounding = context._set_rounding(ROUND_HALF_EVEN) + ans = ans._fix(context) + context.rounding = rounding + + return ans + + def is_canonical(self): + """Return True if self is canonical; otherwise return False. + + Currently, the encoding of a Decimal instance is always + canonical, so this method returns True for any Decimal. + """ + return True + + def is_finite(self): + """Return True if self is finite; otherwise return False. + + A Decimal instance is considered finite if it is neither + infinite nor a NaN. + """ + return not self._is_special + + def is_infinite(self): + """Return True if self is infinite; otherwise return False.""" + return self._exp == 'F' + + def is_nan(self): + """Return True if self is a qNaN or sNaN; otherwise return False.""" + return self._exp in ('n', 'N') + + def is_normal(self, context=None): + """Return True if self is a normal number; otherwise return False.""" + if self._is_special or not self: + return False + if context is None: + context = getcontext() + return context.Emin <= self.adjusted() <= context.Emax + + def is_qnan(self): + """Return True if self is a quiet NaN; otherwise return False.""" + return self._exp == 'n' + + def is_signed(self): + """Return True if self is negative; otherwise return False.""" + return self._sign == 1 + + def is_snan(self): + """Return True if self is a signaling NaN; otherwise return False.""" + return self._exp == 'N' + + def is_subnormal(self, context=None): + """Return True if self is subnormal; otherwise return False.""" + if self._is_special or not self: + return False + if context is None: + context = getcontext() + return self.adjusted() < context.Emin + + def is_zero(self): + """Return True if self is a zero; otherwise return False.""" + return not self._is_special and self._int == '0' + + def _ln_exp_bound(self): + """Compute a lower bound for the adjusted exponent of self.ln(). + In other words, compute r such that self.ln() >= 10**r. Assumes + that self is finite and positive and that self != 1. + """ + + # for 0.1 <= x <= 10 we use the inequalities 1-1/x <= ln(x) <= x-1 + adj = self._exp + len(self._int) - 1 + if adj >= 1: + # argument >= 10; we use 23/10 = 2.3 as a lower bound for ln(10) + return len(str(adj*23//10)) - 1 + if adj <= -2: + # argument <= 0.1 + return len(str((-1-adj)*23//10)) - 1 + op = _WorkRep(self) + c, e = op.int, op.exp + if adj == 0: + # 1 < self < 10 + num = str(c-10**-e) + den = str(c) + return len(num) - len(den) - (num < den) + # adj == -1, 0.1 <= self < 1 + return e + len(str(10**-e - c)) - 1 + + + def ln(self, context=None): + """Returns the natural (base e) logarithm of self.""" + + if context is None: + context = getcontext() + + # ln(NaN) = NaN + ans = self._check_nans(context=context) + if ans: return ans - diff = self._exp - exp - digits = len(self._int) + diff + # ln(0.0) == -Infinity + if not self: + return negInf + + # ln(Infinity) = Infinity + if self._isinfinity() == 1: + return Inf + + # ln(1.0) == 0.0 + if self == Dec_p1: + return Dec_0 + + # ln(negative) raises InvalidOperation + if self._sign == 1: + return context._raise_error(InvalidOperation, + 'ln of a negative value') - if watchexp and digits > context.prec: - return context._raise_error(InvalidOperation, 'Rescale > prec') + # result is irrational, so necessarily inexact + op = _WorkRep(self) + c, e = op.int, op.exp + p = context.prec + + # correctly rounded result: repeatedly increase precision by 3 + # until we get an unambiguously roundable result + places = p - self._ln_exp_bound() + 2 # at least p+3 places + while True: + coeff = _dlog(c, e, places) + # assert len(str(abs(coeff)))-p >= 1 + if coeff % (5*10**(len(str(abs(coeff)))-p-1)): + break + places += 3 + ans = _dec_from_triple(int(coeff<0), str(abs(coeff)), -places) - tmp = Decimal(self) - tmp._int = (0,) + tmp._int - digits += 1 + context = context._shallow_copy() + rounding = context._set_rounding(ROUND_HALF_EVEN) + ans = ans._fix(context) + context.rounding = rounding + return ans - if digits < 0: - tmp._exp = -digits + tmp._exp - tmp._int = (0,1) - digits = 1 - tmp = tmp._round(digits, rounding, context=context) - - if tmp._int[0] == 0 and len(tmp._int) > 1: - tmp._int = tmp._int[1:] - tmp._exp = exp + def _log10_exp_bound(self): + """Compute a lower bound for the adjusted exponent of self.log10(). + In other words, find r such that self.log10() >= 10**r. + Assumes that self is finite and positive and that self != 1. + """ + + # For x >= 10 or x < 0.1 we only need a bound on the integer + # part of log10(self), and this comes directly from the + # exponent of x. For 0.1 <= x <= 10 we use the inequalities + # 1-1/x <= log(x) <= x-1. If x > 1 we have |log10(x)| > + # (1-1/x)/2.31 > 0. If x < 1 then |log10(x)| > (1-x)/2.31 > 0 + + adj = self._exp + len(self._int) - 1 + if adj >= 1: + # self >= 10 + return len(str(adj))-1 + if adj <= -2: + # self < 0.1 + return len(str(-1-adj))-1 + op = _WorkRep(self) + c, e = op.int, op.exp + if adj == 0: + # 1 < self < 10 + num = str(c-10**-e) + den = str(231*c) + return len(num) - len(den) - (num < den) + 2 + # adj == -1, 0.1 <= self < 1 + num = str(10**-e-c) + return len(num) + e - (num < "231") - 1 - tmp_adjusted = tmp.adjusted() - if tmp and tmp_adjusted < context.Emin: - context._raise_error(Subnormal) - elif tmp and tmp_adjusted > context.Emax: - return context._raise_error(InvalidOperation, 'rescale(a, INF)') - return tmp + def log10(self, context=None): + """Returns the base 10 logarithm of self.""" - def to_integral(self, rounding=None, context=None): - """Rounds to the nearest integer, without raising inexact, rounded.""" - if self._is_special: - ans = self._check_nans(context=context) - if ans: - return ans - if self._exp >= 0: - return self if context is None: context = getcontext() - flags = context._ignore_flags(Rounded, Inexact) - ans = self._rescale(0, rounding, context=context) - context._regard_flags(flags) - return ans - def sqrt(self, context=None): - """Return the square root of self. - - Uses a converging algorithm (Xn+1 = 0.5*(Xn + self / Xn)) - Should quadratically approach the right answer. - """ - if self._is_special: - ans = self._check_nans(context=context) - if ans: - return ans - - if self._isinfinity() and self._sign == 0: - return Decimal(self) + # log10(NaN) = NaN + ans = self._check_nans(context=context) + if ans: + return ans + # log10(0.0) == -Infinity if not self: - #exponent = self._exp / 2, using round_down. - #if self._exp < 0: - # exp = (self._exp+1) // 2 - #else: - exp = (self._exp) // 2 - if self._sign == 1: - #sqrt(-0) = -0 - return Decimal( (1, (0,), exp)) - else: - return Decimal( (0, (0,), exp)) + return negInf - if context is None: - context = getcontext() + # log10(Infinity) = Infinity + if self._isinfinity() == 1: + return Inf + # log10(negative or -Infinity) raises InvalidOperation if self._sign == 1: - return context._raise_error(InvalidOperation, 'sqrt(-x), x > 0') - - tmp = Decimal(self) + return context._raise_error(InvalidOperation, + 'log10 of a negative value') - expadd = tmp._exp // 2 - if tmp._exp & 1: - tmp._int += (0,) - tmp._exp = 0 + # log10(10**n) = n + if self._int[0] == '1' and self._int[1:] == '0'*(len(self._int) - 1): + # answer may need rounding + ans = Decimal(self._exp + len(self._int) - 1) else: - tmp._exp = 0 + # result is irrational, so necessarily inexact + op = _WorkRep(self) + c, e = op.int, op.exp + p = context.prec + + # correctly rounded result: repeatedly increase precision + # until result is unambiguously roundable + places = p-self._log10_exp_bound()+2 + while True: + coeff = _dlog10(c, e, places) + # assert len(str(abs(coeff)))-p >= 1 + if coeff % (5*10**(len(str(abs(coeff)))-p-1)): + break + places += 3 + ans = _dec_from_triple(int(coeff<0), str(abs(coeff)), -places) context = context._shallow_copy() - flags = context._ignore_all_flags() - firstprec = context.prec - context.prec = 3 - if tmp.adjusted() & 1 == 0: - ans = Decimal( (0, (8,1,9), tmp.adjusted() - 2) ) - ans = ans.__add__(tmp.__mul__(Decimal((0, (2,5,9), -2)), - context=context), context=context) - ans._exp -= 1 + tmp.adjusted() // 2 - else: - ans = Decimal( (0, (2,5,9), tmp._exp + len(tmp._int)- 3) ) - ans = ans.__add__(tmp.__mul__(Decimal((0, (8,1,9), -3)), - context=context), context=context) - ans._exp -= 1 + tmp.adjusted() // 2 + rounding = context._set_rounding(ROUND_HALF_EVEN) + ans = ans._fix(context) + context.rounding = rounding + return ans - #ans is now a linear approximation. + def logb(self, context=None): + """ Returns the exponent of the magnitude of self's MSD. - Emax, Emin = context.Emax, context.Emin - context.Emax, context.Emin = DefaultContext.Emax, DefaultContext.Emin + The result is the integer which is the exponent of the magnitude + of the most significant digit of self (as though it were truncated + to a single digit while maintaining the value of that digit and + without limiting the resulting exponent). + """ + # logb(NaN) = NaN + ans = self._check_nans(context=context) + if ans: + return ans - half = Decimal('0.5') + if context is None: + context = getcontext() - maxp = firstprec + 2 - rounding = context._set_rounding(ROUND_HALF_EVEN) - while 1: - context.prec = min(2*context.prec - 2, maxp) - ans = half.__mul__(ans.__add__(tmp.__div__(ans, context=context), - context=context), context=context) - if context.prec == maxp: - break + # logb(+/-Inf) = +Inf + if self._isinfinity(): + return Inf - #round to the answer's precision-- the only error can be 1 ulp. - context.prec = firstprec - prevexp = ans.adjusted() - ans = ans._round(context=context) + # logb(0) = -Inf, DivisionByZero + if not self: + return context._raise_error(DivisionByZero, 'logb(0)', 1) - #Now, check if the other last digits are better. - context.prec = firstprec + 1 - # In case we rounded up another digit and we should actually go lower. - if prevexp != ans.adjusted(): - ans._int += (0,) - ans._exp -= 1 + # otherwise, simply return the adjusted exponent of self, as a + # Decimal. Note that no attempt is made to fit the result + # into the current context. + return Decimal(self.adjusted()) + + def _islogical(self): + """Return True if self is a logical operand. + + For being logical, it must be a finite numbers with a sign of 0, + an exponent of 0, and a coefficient whose digits must all be + either 0 or 1. + """ + if self._sign != 0 or self._exp != 0: + return False + for dig in self._int: + if dig not in '01': + return False + return True + + def _fill_logical(self, context, opa, opb): + dif = context.prec - len(opa) + if dif > 0: + opa = '0'*dif + opa + elif dif < 0: + opa = opa[-context.prec:] + dif = context.prec - len(opb) + if dif > 0: + opb = '0'*dif + opb + elif dif < 0: + opb = opb[-context.prec:] + return opa, opb + def logical_and(self, other, context=None): + """Applies an 'and' operation between self and other's digits.""" + if context is None: + context = getcontext() + if not self._islogical() or not other._islogical(): + return context._raise_error(InvalidOperation) - lower = ans.__sub__(Decimal((0, (5,), ans._exp-1)), context=context) - context._set_rounding(ROUND_UP) - if lower.__mul__(lower, context=context) > (tmp): - ans = ans.__sub__(Decimal((0, (1,), ans._exp)), context=context) + # fill to context.prec + (opa, opb) = self._fill_logical(context, self._int, other._int) - else: - upper = ans.__add__(Decimal((0, (5,), ans._exp-1)),context=context) - context._set_rounding(ROUND_DOWN) - if upper.__mul__(upper, context=context) < tmp: - ans = ans.__add__(Decimal((0, (1,), ans._exp)),context=context) + # make the operation, and clean starting zeroes + result = "".join([str(int(a)&int(b)) for a,b in zip(opa,opb)]) + return _dec_from_triple(0, result.lstrip('0') or '0', 0) - ans._exp += expadd + def logical_invert(self, context=None): + """Invert all its digits.""" + if context is None: + context = getcontext() + return self.logical_xor(_dec_from_triple(0,'1'*context.prec,0), + context) - context.prec = firstprec - context.rounding = rounding - ans = ans._fix(context) + def logical_or(self, other, context=None): + """Applies an 'or' operation between self and other's digits.""" + if context is None: + context = getcontext() + if not self._islogical() or not other._islogical(): + return context._raise_error(InvalidOperation) - rounding = context._set_rounding_decision(NEVER_ROUND) - if not ans.__mul__(ans, context=context) == self: - # Only rounded/inexact if here. - context._regard_flags(flags) - context._raise_error(Rounded) - context._raise_error(Inexact) - else: - #Exact answer, so let's set the exponent right. - #if self._exp < 0: - # exp = (self._exp +1)// 2 - #else: - exp = self._exp // 2 - context.prec += ans._exp - exp - ans = ans._rescale(exp, context=context) - context.prec = firstprec - context._regard_flags(flags) - context.Emax, context.Emin = Emax, Emin + # fill to context.prec + (opa, opb) = self._fill_logical(context, self._int, other._int) - return ans._fix(context) + # make the operation, and clean starting zeroes + result = "".join(str(int(a)|int(b)) for a,b in zip(opa,opb)) + return _dec_from_triple(0, result.lstrip('0') or '0', 0) - def max(self, other, context=None): - """Returns the larger value. + def logical_xor(self, other, context=None): + """Applies an 'xor' operation between self and other's digits.""" + if context is None: + context = getcontext() + if not self._islogical() or not other._islogical(): + return context._raise_error(InvalidOperation) - like max(self, other) except if one is not a number, returns - NaN (and signals if one is sNaN). Also rounds. - """ - other = _convert_other(other) - if other is NotImplemented: - return other + # fill to context.prec + (opa, opb) = self._fill_logical(context, self._int, other._int) + + # make the operation, and clean starting zeroes + result = "".join(str(int(a)^int(b)) for a,b in zip(opa,opb)) + return _dec_from_triple(0, result.lstrip('0') or '0', 0) + + def max_mag(self, other, context=None): + """Compares the values numerically with their sign ignored.""" + other = _convert_other(other, raiseit=True) + + if context is None: + context = getcontext() if self._is_special or other._is_special: - # if one operand is a quiet NaN and the other is number, then the + # If one operand is a quiet NaN and the other is number, then the # number is always returned sn = self._isnan() on = other._isnan() if sn or on: if on == 1 and sn != 2: - return self + return self._fix_nan(context) if sn == 1 and on != 2: - return other + return other._fix_nan(context) return self._check_nans(other, context) - ans = self - c = self.__cmp__(other) + c = self.copy_abs().__cmp__(other.copy_abs()) if c == 0: - # if both operands are finite and equal in numerical value - # then an ordering is applied: - # - # if the signs differ then max returns the operand with the - # positive sign and min returns the operand with the negative sign - # - # if the signs are the same then the exponent is used to select - # the result. - if self._sign != other._sign: - if self._sign: - ans = other - elif self._exp < other._exp and not self._sign: - ans = other - elif self._exp > other._exp and self._sign: - ans = other - elif c == -1: + c = self.compare_total(other) + + if c == -1: ans = other + else: + ans = self - if context is None: - context = getcontext() - if context._rounding_decision == ALWAYS_ROUND: - return ans._fix(context) - return ans + return ans._fix(context) - def min(self, other, context=None): - """Returns the smaller value. + def min_mag(self, other, context=None): + """Compares the values numerically with their sign ignored.""" + other = _convert_other(other, raiseit=True) - like min(self, other) except if one is not a number, returns - NaN (and signals if one is sNaN). Also rounds. - """ - other = _convert_other(other) - if other is NotImplemented: - return other + if context is None: + context = getcontext() if self._is_special or other._is_special: - # if one operand is a quiet NaN and the other is number, then the + # If one operand is a quiet NaN and the other is number, then the # number is always returned sn = self._isnan() on = other._isnan() if sn or on: if on == 1 and sn != 2: - return self + return self._fix_nan(context) if sn == 1 and on != 2: - return other + return other._fix_nan(context) return self._check_nans(other, context) - ans = self - c = self.__cmp__(other) + c = self.copy_abs().__cmp__(other.copy_abs()) if c == 0: - # if both operands are finite and equal in numerical value - # then an ordering is applied: - # - # if the signs differ then max returns the operand with the - # positive sign and min returns the operand with the negative sign - # - # if the signs are the same then the exponent is used to select - # the result. - if self._sign != other._sign: - if other._sign: - ans = other - elif self._exp > other._exp and not self._sign: - ans = other - elif self._exp < other._exp and self._sign: - ans = other - elif c == 1: + c = self.compare_total(other) + + if c == -1: + ans = self + else: ans = other + return ans._fix(context) + + def next_minus(self, context=None): + """Returns the largest representable number smaller than itself.""" if context is None: context = getcontext() - if context._rounding_decision == ALWAYS_ROUND: - return ans._fix(context) + + ans = self._check_nans(context=context) + if ans: + return ans + + if self._isinfinity() == -1: + return negInf + if self._isinfinity() == 1: + return _dec_from_triple(0, '9'*context.prec, context.Etop()) + + context = context.copy() + context._set_rounding(ROUND_FLOOR) + context._ignore_all_flags() + new_self = self._fix(context) + if new_self != self: + return new_self + return self.__sub__(_dec_from_triple(0, '1', context.Etiny()-1), + context) + + def next_plus(self, context=None): + """Returns the smallest representable number larger than itself.""" + if context is None: + context = getcontext() + + ans = self._check_nans(context=context) + if ans: + return ans + + if self._isinfinity() == 1: + return Inf + if self._isinfinity() == -1: + return _dec_from_triple(1, '9'*context.prec, context.Etop()) + + context = context.copy() + context._set_rounding(ROUND_CEILING) + context._ignore_all_flags() + new_self = self._fix(context) + if new_self != self: + return new_self + return self.__add__(_dec_from_triple(0, '1', context.Etiny()-1), + context) + + def next_toward(self, other, context=None): + """Returns the number closest to self, in the direction towards other. + + The result is the closest representable number to self + (excluding self) that is in the direction towards other, + unless both have the same value. If the two operands are + numerically equal, then the result is a copy of self with the + sign set to be the same as the sign of other. + """ + other = _convert_other(other, raiseit=True) + + if context is None: + context = getcontext() + + ans = self._check_nans(other, context) + if ans: + return ans + + comparison = self.__cmp__(other) + if comparison == 0: + return self.copy_sign(other) + + if comparison == -1: + ans = self.next_plus(context) + else: # comparison == 1 + ans = self.next_minus(context) + + # decide which flags to raise using value of ans + if ans._isinfinity(): + context._raise_error(Overflow, + 'Infinite result from next_toward', + ans._sign) + context._raise_error(Rounded) + context._raise_error(Inexact) + elif ans.adjusted() < context.Emin: + context._raise_error(Underflow) + context._raise_error(Subnormal) + context._raise_error(Rounded) + context._raise_error(Inexact) + # if precision == 1 then we don't raise Clamped for a + # result 0E-Etiny. + if not ans: + context._raise_error(Clamped) + return ans - def _isinteger(self): - """Returns whether self is an integer""" - if self._exp >= 0: - return True - rest = self._int[self._exp:] - return rest == (0,)*len(rest) + def number_class(self, context=None): + """Returns an indication of the class of self. - def _iseven(self): - """Returns 1 if self is even. Assumes self is an integer.""" - if self._exp > 0: - return 1 - return self._int[-1+self._exp] & 1 == 0 + The class is one of the following strings: + sNaN + NaN + -Infinity + -Normal + -Subnormal + -Zero + +Zero + +Subnormal + +Normal + +Infinity + """ + if self.is_snan(): + return "sNaN" + if self.is_qnan(): + return "NaN" + inf = self._isinfinity() + if inf == 1: + return "+Infinity" + if inf == -1: + return "-Infinity" + if self.is_zero(): + if self._sign: + return "-Zero" + else: + return "+Zero" + if context is None: + context = getcontext() + if self.is_subnormal(context=context): + if self._sign: + return "-Subnormal" + else: + return "+Subnormal" + # just a normal, regular, boring number, :) + if self._sign: + return "-Normal" + else: + return "+Normal" - def adjusted(self): - """Return the adjusted exponent of self""" - try: - return self._exp + len(self._int) - 1 - #If NaN or Infinity, self._exp is string - except TypeError: - return 0 + def radix(self): + """Just returns 10, as this is Decimal, :)""" + return Decimal(10) + + def rotate(self, other, context=None): + """Returns a rotated copy of self, value-of-other times.""" + if context is None: + context = getcontext() + + ans = self._check_nans(other, context) + if ans: + return ans + + if other._exp != 0: + return context._raise_error(InvalidOperation) + if not (-context.prec <= int(other) <= context.prec): + return context._raise_error(InvalidOperation) + + if self._isinfinity(): + return Decimal(self) + + # get values, pad if necessary + torot = int(other) + rotdig = self._int + topad = context.prec - len(rotdig) + if topad: + rotdig = '0'*topad + rotdig + + # let's rotate! + rotated = rotdig[torot:] + rotdig[:torot] + return _dec_from_triple(self._sign, + rotated.lstrip('0') or '0', self._exp) + + def scaleb (self, other, context=None): + """Returns self operand after adding the second value to its exp.""" + if context is None: + context = getcontext() + + ans = self._check_nans(other, context) + if ans: + return ans + + if other._exp != 0: + return context._raise_error(InvalidOperation) + liminf = -2 * (context.Emax + context.prec) + limsup = 2 * (context.Emax + context.prec) + if not (liminf <= int(other) <= limsup): + return context._raise_error(InvalidOperation) + + if self._isinfinity(): + return Decimal(self) + + d = _dec_from_triple(self._sign, self._int, self._exp + int(other)) + d = d._fix(context) + return d + + def shift(self, other, context=None): + """Returns a shifted copy of self, value-of-other times.""" + if context is None: + context = getcontext() + + ans = self._check_nans(other, context) + if ans: + return ans + + if other._exp != 0: + return context._raise_error(InvalidOperation) + if not (-context.prec <= int(other) <= context.prec): + return context._raise_error(InvalidOperation) + + if self._isinfinity(): + return Decimal(self) + + # get values, pad if necessary + torot = int(other) + if not torot: + return Decimal(self) + rotdig = self._int + topad = context.prec - len(rotdig) + if topad: + rotdig = '0'*topad + rotdig + + # let's shift! + if torot < 0: + rotated = rotdig[:torot] + else: + rotated = rotdig + '0'*torot + rotated = rotated[-context.prec:] + + return _dec_from_triple(self._sign, + rotated.lstrip('0') or '0', self._exp) - # support for pickling, copy, and deepcopy + # Support for pickling, copy, and deepcopy def __reduce__(self): return (self.__class__, (str(self),)) @@ -2203,13 +3336,30 @@ return self # My components are also immutable return self.__class__(str(self)) -##### Context class ########################################### +def _dec_from_triple(sign, coefficient, exponent, special=False): + """Create a decimal instance directly, without any validation, + normalization (e.g. removal of leading zeros) or argument + conversion. + + This function is for *internal use only*. + """ + + self = object.__new__(Decimal) + self._sign = sign + self._int = coefficient + self._exp = exponent + self._is_special = special + + return self + +##### Context class ####################################################### # get rounding method function: -rounding_functions = [name for name in Decimal.__dict__.keys() if name.startswith('_round_')] +rounding_functions = [name for name in Decimal.__dict__.keys() + if name.startswith('_round_')] for name in rounding_functions: - #name is like _round_half_even, goes to the global ROUND_HALF_EVEN value. + # name is like _round_half_even, goes to the global ROUND_HALF_EVEN value. globalname = name[1:].upper() val = globals()[globalname] Decimal._pick_rounding_function[val] = name @@ -2236,8 +3386,7 @@ Contains: prec - precision (for use in rounding, division, square roots..) - rounding - rounding type. (how you round) - _rounding_decision - ALWAYS_ROUND, NEVER_ROUND -- do you round? + rounding - rounding type (how you round) traps - If traps[exception] = 1, then the exception is raised when it is caused. Otherwise, a value is substituted in. @@ -2253,7 +3402,6 @@ def __init__(self, prec=None, rounding=None, traps=None, flags=None, - _rounding_decision=None, Emin=None, Emax=None, capitals=None, _clamp=0, _ignored_flags=None): @@ -2277,9 +3425,13 @@ def __repr__(self): """Show the current context.""" s = [] - s.append('Context(prec=%(prec)d, rounding=%(rounding)s, Emin=%(Emin)d, Emax=%(Emax)d, capitals=%(capitals)d' % vars(self)) - s.append('flags=[' + ', '.join([f.__name__ for f, v in self.flags.items() if v]) + ']') - s.append('traps=[' + ', '.join([t.__name__ for t, v in self.traps.items() if v]) + ']') + s.append('Context(prec=%(prec)d, rounding=%(rounding)s, ' + 'Emin=%(Emin)d, Emax=%(Emax)d, capitals=%(capitals)d' + % vars(self)) + names = [f.__name__ for f, v in self.flags.items() if v] + s.append('flags=[' + ', '.join(names) + ']') + names = [t.__name__ for t, v in self.traps.items() if v] + s.append('traps=[' + ', '.join(names) + ']') return ', '.join(s) + ')' def clear_flags(self): @@ -2289,16 +3441,16 @@ def _shallow_copy(self): """Returns a shallow copy from self.""" - nc = Context(self.prec, self.rounding, self.traps, self.flags, - self._rounding_decision, self.Emin, self.Emax, - self.capitals, self._clamp, self._ignored_flags) + nc = Context(self.prec, self.rounding, self.traps, + self.flags, self.Emin, self.Emax, + self.capitals, self._clamp, self._ignored_flags) return nc def copy(self): """Returns a deep copy from self.""" - nc = Context(self.prec, self.rounding, self.traps.copy(), self.flags.copy(), - self._rounding_decision, self.Emin, self.Emax, - self.capitals, self._clamp, self._ignored_flags) + nc = Context(self.prec, self.rounding, self.traps.copy(), + self.flags.copy(), self.Emin, self.Emax, + self.capitals, self._clamp, self._ignored_flags) return nc __copy__ = copy @@ -2312,16 +3464,16 @@ """ error = _condition_map.get(condition, condition) if error in self._ignored_flags: - #Don't touch the flag + # Don't touch the flag return error().handle(self, *args) self.flags[error] += 1 if not self.traps[error]: - #The errors define how to handle themselves. + # The errors define how to handle themselves. return condition().handle(self, *args) # Errors should only be risked on copies of the context - #self._ignored_flags = [] + # self._ignored_flags = [] raise error, explanation def _ignore_all_flags(self): @@ -2345,7 +3497,7 @@ def __hash__(self): """A Context cannot be hashed.""" # We inherit object.__hash__, so we must deny this explicitly - raise TypeError, "Cannot hash a Context." + raise TypeError("Cannot hash a Context.") def Etiny(self): """Returns Etiny (= Emin - prec + 1)""" @@ -2355,27 +3507,6 @@ """Returns maximum exponent (= Emax - prec + 1)""" return int(self.Emax - self.prec + 1) - def _set_rounding_decision(self, type): - """Sets the rounding decision. - - Sets the rounding decision, and returns the current (previous) - rounding decision. Often used like: - - context = context._shallow_copy() - # That so you don't change the calling context - # if an error occurs in the middle (say DivisionImpossible is raised). - - rounding = context._set_rounding_decision(NEVER_ROUND) - instance = instance / Decimal(2) - context._set_rounding_decision(rounding) - - This will make it not round for that operation. - """ - - rounding = self._rounding_decision - self._rounding_decision = type - return rounding - def _set_rounding(self, type): """Sets the rounding type. @@ -2398,14 +3529,17 @@ def create_decimal(self, num='0'): """Creates a new Decimal instance but using self as context.""" d = Decimal(num, context=self) + if d._isnan() and len(d._int) > self.prec - self._clamp: + return self._raise_error(ConversionSyntax, + "diagnostic info too long in NaN") return d._fix(self) - #Methods + # Methods def abs(self, a): """Returns the absolute value of the operand. If the operand is negative, the result is the same as using the minus - operation on the operand. Otherwise, the result is the same as using + operation on the operand. Otherwise, the result is the same as using the plus operation on the operand. >>> ExtendedContext.abs(Decimal('2.1')) @@ -2432,34 +3566,149 @@ def _apply(self, a): return str(a._fix(self)) + def canonical(self, a): + """Returns the same Decimal object. + + As we do not have different encodings for the same number, the + received object already is in its canonical form. + + >>> ExtendedContext.canonical(Decimal('2.50')) + Decimal("2.50") + """ + return a.canonical(context=self) + def compare(self, a, b): """Compares values numerically. - If the signs of the operands differ, a value representing each operand - ('-1' if the operand is less than zero, '0' if the operand is zero or - negative zero, or '1' if the operand is greater than zero) is used in - place of that operand for the comparison instead of the actual - operand. + If the signs of the operands differ, a value representing each operand + ('-1' if the operand is less than zero, '0' if the operand is zero or + negative zero, or '1' if the operand is greater than zero) is used in + place of that operand for the comparison instead of the actual + operand. + + The comparison is then effected by subtracting the second operand from + the first and then returning a value according to the result of the + subtraction: '-1' if the result is less than zero, '0' if the result is + zero or negative zero, or '1' if the result is greater than zero. + + >>> ExtendedContext.compare(Decimal('2.1'), Decimal('3')) + Decimal("-1") + >>> ExtendedContext.compare(Decimal('2.1'), Decimal('2.1')) + Decimal("0") + >>> ExtendedContext.compare(Decimal('2.1'), Decimal('2.10')) + Decimal("0") + >>> ExtendedContext.compare(Decimal('3'), Decimal('2.1')) + Decimal("1") + >>> ExtendedContext.compare(Decimal('2.1'), Decimal('-3')) + Decimal("1") + >>> ExtendedContext.compare(Decimal('-3'), Decimal('2.1')) + Decimal("-1") + """ + return a.compare(b, context=self) + + def compare_signal(self, a, b): + """Compares the values of the two operands numerically. + + It's pretty much like compare(), but all NaNs signal, with signaling + NaNs taking precedence over quiet NaNs. + + >>> c = ExtendedContext + >>> c.compare_signal(Decimal('2.1'), Decimal('3')) + Decimal("-1") + >>> c.compare_signal(Decimal('2.1'), Decimal('2.1')) + Decimal("0") + >>> c.flags[InvalidOperation] = 0 + >>> print c.flags[InvalidOperation] + 0 + >>> c.compare_signal(Decimal('NaN'), Decimal('2.1')) + Decimal("NaN") + >>> print c.flags[InvalidOperation] + 1 + >>> c.flags[InvalidOperation] = 0 + >>> print c.flags[InvalidOperation] + 0 + >>> c.compare_signal(Decimal('sNaN'), Decimal('2.1')) + Decimal("NaN") + >>> print c.flags[InvalidOperation] + 1 + """ + return a.compare_signal(b, context=self) + + def compare_total(self, a, b): + """Compares two operands using their abstract representation. + + This is not like the standard compare, which use their numerical + value. Note that a total ordering is defined for all possible abstract + representations. + + >>> ExtendedContext.compare_total(Decimal('12.73'), Decimal('127.9')) + Decimal("-1") + >>> ExtendedContext.compare_total(Decimal('-127'), Decimal('12')) + Decimal("-1") + >>> ExtendedContext.compare_total(Decimal('12.30'), Decimal('12.3')) + Decimal("-1") + >>> ExtendedContext.compare_total(Decimal('12.30'), Decimal('12.30')) + Decimal("0") + >>> ExtendedContext.compare_total(Decimal('12.3'), Decimal('12.300')) + Decimal("1") + >>> ExtendedContext.compare_total(Decimal('12.3'), Decimal('NaN')) + Decimal("-1") + """ + return a.compare_total(b) + + def compare_total_mag(self, a, b): + """Compares two operands using their abstract representation ignoring sign. + + Like compare_total, but with operand's sign ignored and assumed to be 0. + """ + return a.compare_total_mag(b) + + def copy_abs(self, a): + """Returns a copy of the operand with the sign set to 0. + + >>> ExtendedContext.copy_abs(Decimal('2.1')) + Decimal("2.1") + >>> ExtendedContext.copy_abs(Decimal('-100')) + Decimal("100") + """ + return a.copy_abs() + + def copy_decimal(self, a): + """Returns a copy of the decimal objet. + + >>> ExtendedContext.copy_decimal(Decimal('2.1')) + Decimal("2.1") + >>> ExtendedContext.copy_decimal(Decimal('-1.00')) + Decimal("-1.00") + """ + return Decimal(a) + + def copy_negate(self, a): + """Returns a copy of the operand with the sign inverted. + + >>> ExtendedContext.copy_negate(Decimal('101.5')) + Decimal("-101.5") + >>> ExtendedContext.copy_negate(Decimal('-101.5')) + Decimal("101.5") + """ + return a.copy_negate() + + def copy_sign(self, a, b): + """Copies the second operand's sign to the first one. - The comparison is then effected by subtracting the second operand from - the first and then returning a value according to the result of the - subtraction: '-1' if the result is less than zero, '0' if the result is - zero or negative zero, or '1' if the result is greater than zero. + In detail, it returns a copy of the first operand with the sign + equal to the sign of the second operand. - >>> ExtendedContext.compare(Decimal('2.1'), Decimal('3')) - Decimal("-1") - >>> ExtendedContext.compare(Decimal('2.1'), Decimal('2.1')) - Decimal("0") - >>> ExtendedContext.compare(Decimal('2.1'), Decimal('2.10')) - Decimal("0") - >>> ExtendedContext.compare(Decimal('3'), Decimal('2.1')) - Decimal("1") - >>> ExtendedContext.compare(Decimal('2.1'), Decimal('-3')) - Decimal("1") - >>> ExtendedContext.compare(Decimal('-3'), Decimal('2.1')) - Decimal("-1") + >>> ExtendedContext.copy_sign(Decimal( '1.50'), Decimal('7.33')) + Decimal("1.50") + >>> ExtendedContext.copy_sign(Decimal('-1.50'), Decimal('7.33')) + Decimal("1.50") + >>> ExtendedContext.copy_sign(Decimal( '1.50'), Decimal('-7.33')) + Decimal("-1.50") + >>> ExtendedContext.copy_sign(Decimal('-1.50'), Decimal('-7.33')) + Decimal("-1.50") """ - return a.compare(b, context=self) + return a.copy_sign(b) def divide(self, a, b): """Decimal division in a specified context. @@ -2502,13 +3751,330 @@ def divmod(self, a, b): return a.__divmod__(b, context=self) + def exp(self, a): + """Returns e ** a. + + >>> c = ExtendedContext.copy() + >>> c.Emin = -999 + >>> c.Emax = 999 + >>> c.exp(Decimal('-Infinity')) + Decimal("0") + >>> c.exp(Decimal('-1')) + Decimal("0.367879441") + >>> c.exp(Decimal('0')) + Decimal("1") + >>> c.exp(Decimal('1')) + Decimal("2.71828183") + >>> c.exp(Decimal('0.693147181')) + Decimal("2.00000000") + >>> c.exp(Decimal('+Infinity')) + Decimal("Infinity") + """ + return a.exp(context=self) + + def fma(self, a, b, c): + """Returns a multiplied by b, plus c. + + The first two operands are multiplied together, using multiply, + the third operand is then added to the result of that + multiplication, using add, all with only one final rounding. + + >>> ExtendedContext.fma(Decimal('3'), Decimal('5'), Decimal('7')) + Decimal("22") + >>> ExtendedContext.fma(Decimal('3'), Decimal('-5'), Decimal('7')) + Decimal("-8") + >>> ExtendedContext.fma(Decimal('888565290'), Decimal('1557.96930'), Decimal('-86087.7578')) + Decimal("1.38435736E+12") + """ + return a.fma(b, c, context=self) + + def is_canonical(self, a): + """Return True if the operand is canonical; otherwise return False. + + Currently, the encoding of a Decimal instance is always + canonical, so this method returns True for any Decimal. + + >>> ExtendedContext.is_canonical(Decimal('2.50')) + True + """ + return a.is_canonical() + + def is_finite(self, a): + """Return True if the operand is finite; otherwise return False. + + A Decimal instance is considered finite if it is neither + infinite nor a NaN. + + >>> ExtendedContext.is_finite(Decimal('2.50')) + True + >>> ExtendedContext.is_finite(Decimal('-0.3')) + True + >>> ExtendedContext.is_finite(Decimal('0')) + True + >>> ExtendedContext.is_finite(Decimal('Inf')) + False + >>> ExtendedContext.is_finite(Decimal('NaN')) + False + """ + return a.is_finite() + + def is_infinite(self, a): + """Return True if the operand is infinite; otherwise return False. + + >>> ExtendedContext.is_infinite(Decimal('2.50')) + False + >>> ExtendedContext.is_infinite(Decimal('-Inf')) + True + >>> ExtendedContext.is_infinite(Decimal('NaN')) + False + """ + return a.is_infinite() + + def is_nan(self, a): + """Return True if the operand is a qNaN or sNaN; + otherwise return False. + + >>> ExtendedContext.is_nan(Decimal('2.50')) + False + >>> ExtendedContext.is_nan(Decimal('NaN')) + True + >>> ExtendedContext.is_nan(Decimal('-sNaN')) + True + """ + return a.is_nan() + + def is_normal(self, a): + """Return True if the operand is a normal number; + otherwise return False. + + >>> c = ExtendedContext.copy() + >>> c.Emin = -999 + >>> c.Emax = 999 + >>> c.is_normal(Decimal('2.50')) + True + >>> c.is_normal(Decimal('0.1E-999')) + False + >>> c.is_normal(Decimal('0.00')) + False + >>> c.is_normal(Decimal('-Inf')) + False + >>> c.is_normal(Decimal('NaN')) + False + """ + return a.is_normal(context=self) + + def is_qnan(self, a): + """Return True if the operand is a quiet NaN; otherwise return False. + + >>> ExtendedContext.is_qnan(Decimal('2.50')) + False + >>> ExtendedContext.is_qnan(Decimal('NaN')) + True + >>> ExtendedContext.is_qnan(Decimal('sNaN')) + False + """ + return a.is_qnan() + + def is_signed(self, a): + """Return True if the operand is negative; otherwise return False. + + >>> ExtendedContext.is_signed(Decimal('2.50')) + False + >>> ExtendedContext.is_signed(Decimal('-12')) + True + >>> ExtendedContext.is_signed(Decimal('-0')) + True + """ + return a.is_signed() + + def is_snan(self, a): + """Return True if the operand is a signaling NaN; + otherwise return False. + + >>> ExtendedContext.is_snan(Decimal('2.50')) + False + >>> ExtendedContext.is_snan(Decimal('NaN')) + False + >>> ExtendedContext.is_snan(Decimal('sNaN')) + True + """ + return a.is_snan() + + def is_subnormal(self, a): + """Return True if the operand is subnormal; otherwise return False. + + >>> c = ExtendedContext.copy() + >>> c.Emin = -999 + >>> c.Emax = 999 + >>> c.is_subnormal(Decimal('2.50')) + False + >>> c.is_subnormal(Decimal('0.1E-999')) + True + >>> c.is_subnormal(Decimal('0.00')) + False + >>> c.is_subnormal(Decimal('-Inf')) + False + >>> c.is_subnormal(Decimal('NaN')) + False + """ + return a.is_subnormal(context=self) + + def is_zero(self, a): + """Return True if the operand is a zero; otherwise return False. + + >>> ExtendedContext.is_zero(Decimal('0')) + True + >>> ExtendedContext.is_zero(Decimal('2.50')) + False + >>> ExtendedContext.is_zero(Decimal('-0E+2')) + True + """ + return a.is_zero() + + def ln(self, a): + """Returns the natural (base e) logarithm of the operand. + + >>> c = ExtendedContext.copy() + >>> c.Emin = -999 + >>> c.Emax = 999 + >>> c.ln(Decimal('0')) + Decimal("-Infinity") + >>> c.ln(Decimal('1.000')) + Decimal("0") + >>> c.ln(Decimal('2.71828183')) + Decimal("1.00000000") + >>> c.ln(Decimal('10')) + Decimal("2.30258509") + >>> c.ln(Decimal('+Infinity')) + Decimal("Infinity") + """ + return a.ln(context=self) + + def log10(self, a): + """Returns the base 10 logarithm of the operand. + + >>> c = ExtendedContext.copy() + >>> c.Emin = -999 + >>> c.Emax = 999 + >>> c.log10(Decimal('0')) + Decimal("-Infinity") + >>> c.log10(Decimal('0.001')) + Decimal("-3") + >>> c.log10(Decimal('1.000')) + Decimal("0") + >>> c.log10(Decimal('2')) + Decimal("0.301029996") + >>> c.log10(Decimal('10')) + Decimal("1") + >>> c.log10(Decimal('70')) + Decimal("1.84509804") + >>> c.log10(Decimal('+Infinity')) + Decimal("Infinity") + """ + return a.log10(context=self) + + def logb(self, a): + """ Returns the exponent of the magnitude of the operand's MSD. + + The result is the integer which is the exponent of the magnitude + of the most significant digit of the operand (as though the + operand were truncated to a single digit while maintaining the + value of that digit and without limiting the resulting exponent). + + >>> ExtendedContext.logb(Decimal('250')) + Decimal("2") + >>> ExtendedContext.logb(Decimal('2.50')) + Decimal("0") + >>> ExtendedContext.logb(Decimal('0.03')) + Decimal("-2") + >>> ExtendedContext.logb(Decimal('0')) + Decimal("-Infinity") + """ + return a.logb(context=self) + + def logical_and(self, a, b): + """Applies the logical operation 'and' between each operand's digits. + + The operands must be both logical numbers. + + >>> ExtendedContext.logical_and(Decimal('0'), Decimal('0')) + Decimal("0") + >>> ExtendedContext.logical_and(Decimal('0'), Decimal('1')) + Decimal("0") + >>> ExtendedContext.logical_and(Decimal('1'), Decimal('0')) + Decimal("0") + >>> ExtendedContext.logical_and(Decimal('1'), Decimal('1')) + Decimal("1") + >>> ExtendedContext.logical_and(Decimal('1100'), Decimal('1010')) + Decimal("1000") + >>> ExtendedContext.logical_and(Decimal('1111'), Decimal('10')) + Decimal("10") + """ + return a.logical_and(b, context=self) + + def logical_invert(self, a): + """Invert all the digits in the operand. + + The operand must be a logical number. + + >>> ExtendedContext.logical_invert(Decimal('0')) + Decimal("111111111") + >>> ExtendedContext.logical_invert(Decimal('1')) + Decimal("111111110") + >>> ExtendedContext.logical_invert(Decimal('111111111')) + Decimal("0") + >>> ExtendedContext.logical_invert(Decimal('101010101')) + Decimal("10101010") + """ + return a.logical_invert(context=self) + + def logical_or(self, a, b): + """Applies the logical operation 'or' between each operand's digits. + + The operands must be both logical numbers. + + >>> ExtendedContext.logical_or(Decimal('0'), Decimal('0')) + Decimal("0") + >>> ExtendedContext.logical_or(Decimal('0'), Decimal('1')) + Decimal("1") + >>> ExtendedContext.logical_or(Decimal('1'), Decimal('0')) + Decimal("1") + >>> ExtendedContext.logical_or(Decimal('1'), Decimal('1')) + Decimal("1") + >>> ExtendedContext.logical_or(Decimal('1100'), Decimal('1010')) + Decimal("1110") + >>> ExtendedContext.logical_or(Decimal('1110'), Decimal('10')) + Decimal("1110") + """ + return a.logical_or(b, context=self) + + def logical_xor(self, a, b): + """Applies the logical operation 'xor' between each operand's digits. + + The operands must be both logical numbers. + + >>> ExtendedContext.logical_xor(Decimal('0'), Decimal('0')) + Decimal("0") + >>> ExtendedContext.logical_xor(Decimal('0'), Decimal('1')) + Decimal("1") + >>> ExtendedContext.logical_xor(Decimal('1'), Decimal('0')) + Decimal("1") + >>> ExtendedContext.logical_xor(Decimal('1'), Decimal('1')) + Decimal("0") + >>> ExtendedContext.logical_xor(Decimal('1100'), Decimal('1010')) + Decimal("110") + >>> ExtendedContext.logical_xor(Decimal('1111'), Decimal('10')) + Decimal("1101") + """ + return a.logical_xor(b, context=self) + def max(self, a,b): """max compares two values numerically and returns the maximum. If either operand is a NaN then the general rules apply. Otherwise, the operands are compared as as though by the compare - operation. If they are numerically equal then the left-hand operand - is chosen as the result. Otherwise the maximum (closer to positive + operation. If they are numerically equal then the left-hand operand + is chosen as the result. Otherwise the maximum (closer to positive infinity) of the two operands is chosen as the result. >>> ExtendedContext.max(Decimal('3'), Decimal('2')) @@ -2522,13 +4088,17 @@ """ return a.max(b, context=self) + def max_mag(self, a, b): + """Compares the values numerically with their sign ignored.""" + return a.max_mag(b, context=self) + def min(self, a,b): """min compares two values numerically and returns the minimum. If either operand is a NaN then the general rules apply. Otherwise, the operands are compared as as though by the compare - operation. If they are numerically equal then the left-hand operand - is chosen as the result. Otherwise the minimum (closer to negative + operation. If they are numerically equal then the left-hand operand + is chosen as the result. Otherwise the minimum (closer to negative infinity) of the two operands is chosen as the result. >>> ExtendedContext.min(Decimal('3'), Decimal('2')) @@ -2542,6 +4112,10 @@ """ return a.min(b, context=self) + def min_mag(self, a, b): + """Compares the values numerically with their sign ignored.""" + return a.min_mag(b, context=self) + def minus(self, a): """Minus corresponds to unary prefix minus in Python. @@ -2577,6 +4151,68 @@ """ return a.__mul__(b, context=self) + def next_minus(self, a): + """Returns the largest representable number smaller than a. + + >>> c = ExtendedContext.copy() + >>> c.Emin = -999 + >>> c.Emax = 999 + >>> ExtendedContext.next_minus(Decimal('1')) + Decimal("0.999999999") + >>> c.next_minus(Decimal('1E-1007')) + Decimal("0E-1007") + >>> ExtendedContext.next_minus(Decimal('-1.00000003')) + Decimal("-1.00000004") + >>> c.next_minus(Decimal('Infinity')) + Decimal("9.99999999E+999") + """ + return a.next_minus(context=self) + + def next_plus(self, a): + """Returns the smallest representable number larger than a. + + >>> c = ExtendedContext.copy() + >>> c.Emin = -999 + >>> c.Emax = 999 + >>> ExtendedContext.next_plus(Decimal('1')) + Decimal("1.00000001") + >>> c.next_plus(Decimal('-1E-1007')) + Decimal("-0E-1007") + >>> ExtendedContext.next_plus(Decimal('-1.00000003')) + Decimal("-1.00000002") + >>> c.next_plus(Decimal('-Infinity')) + Decimal("-9.99999999E+999") + """ + return a.next_plus(context=self) + + def next_toward(self, a, b): + """Returns the number closest to a, in direction towards b. + + The result is the closest representable number from the first + operand (but not the first operand) that is in the direction + towards the second operand, unless the operands have the same + value. + + >>> c = ExtendedContext.copy() + >>> c.Emin = -999 + >>> c.Emax = 999 + >>> c.next_toward(Decimal('1'), Decimal('2')) + Decimal("1.00000001") + >>> c.next_toward(Decimal('-1E-1007'), Decimal('1')) + Decimal("-0E-1007") + >>> c.next_toward(Decimal('-1.00000003'), Decimal('0')) + Decimal("-1.00000002") + >>> c.next_toward(Decimal('1'), Decimal('0')) + Decimal("0.999999999") + >>> c.next_toward(Decimal('1E-1007'), Decimal('-100')) + Decimal("0E-1007") + >>> c.next_toward(Decimal('-1.00000003'), Decimal('-10')) + Decimal("-1.00000004") + >>> c.next_toward(Decimal('0.00'), Decimal('-0.0000')) + Decimal("-0.00") + """ + return a.next_toward(b, context=self) + def normalize(self, a): """normalize reduces an operand to its simplest form. @@ -2598,6 +4234,53 @@ """ return a.normalize(context=self) + def number_class(self, a): + """Returns an indication of the class of the operand. + + The class is one of the following strings: + -sNaN + -NaN + -Infinity + -Normal + -Subnormal + -Zero + +Zero + +Subnormal + +Normal + +Infinity + + >>> c = Context(ExtendedContext) + >>> c.Emin = -999 + >>> c.Emax = 999 + >>> c.number_class(Decimal('Infinity')) + '+Infinity' + >>> c.number_class(Decimal('1E-10')) + '+Normal' + >>> c.number_class(Decimal('2.50')) + '+Normal' + >>> c.number_class(Decimal('0.1E-999')) + '+Subnormal' + >>> c.number_class(Decimal('0')) + '+Zero' + >>> c.number_class(Decimal('-0')) + '-Zero' + >>> c.number_class(Decimal('-0.1E-999')) + '-Subnormal' + >>> c.number_class(Decimal('-1E-10')) + '-Normal' + >>> c.number_class(Decimal('-2.50')) + '-Normal' + >>> c.number_class(Decimal('-Infinity')) + '-Infinity' + >>> c.number_class(Decimal('NaN')) + 'NaN' + >>> c.number_class(Decimal('-NaN')) + 'NaN' + >>> c.number_class(Decimal('sNaN')) + 'sNaN' + """ + return a.number_class(context=self) + def plus(self, a): """Plus corresponds to unary prefix plus in Python. @@ -2615,65 +4298,85 @@ def power(self, a, b, modulo=None): """Raises a to the power of b, to modulo if given. - The right-hand operand must be a whole number whose integer part (after - any exponent has been applied) has no more than 9 digits and whose - fractional part (if any) is all zeros before any rounding. The operand - may be positive, negative, or zero; if negative, the absolute value of - the power is used, and the left-hand operand is inverted (divided into - 1) before use. - - If the increased precision needed for the intermediate calculations - exceeds the capabilities of the implementation then an Invalid operation - condition is raised. - - If, when raising to a negative power, an underflow occurs during the - division into 1, the operation is not halted at that point but - continues. - - >>> ExtendedContext.power(Decimal('2'), Decimal('3')) + With two arguments, compute a**b. If a is negative then b + must be integral. The result will be inexact unless b is + integral and the result is finite and can be expressed exactly + in 'precision' digits. + + With three arguments, compute (a**b) % modulo. For the + three argument form, the following restrictions on the + arguments hold: + + - all three arguments must be integral + - b must be nonnegative + - at least one of a or b must be nonzero + - modulo must be nonzero and have at most 'precision' digits + + The result of pow(a, b, modulo) is identical to the result + that would be obtained by computing (a**b) % modulo with + unbounded precision, but is computed more efficiently. It is + always exact. + + >>> c = ExtendedContext.copy() + >>> c.Emin = -999 + >>> c.Emax = 999 + >>> c.power(Decimal('2'), Decimal('3')) Decimal("8") - >>> ExtendedContext.power(Decimal('2'), Decimal('-3')) + >>> c.power(Decimal('-2'), Decimal('3')) + Decimal("-8") + >>> c.power(Decimal('2'), Decimal('-3')) Decimal("0.125") - >>> ExtendedContext.power(Decimal('1.7'), Decimal('8')) + >>> c.power(Decimal('1.7'), Decimal('8')) Decimal("69.7575744") - >>> ExtendedContext.power(Decimal('Infinity'), Decimal('-2')) + >>> c.power(Decimal('10'), Decimal('0.301029996')) + Decimal("2.00000000") + >>> c.power(Decimal('Infinity'), Decimal('-1')) Decimal("0") - >>> ExtendedContext.power(Decimal('Infinity'), Decimal('-1')) - Decimal("0") - >>> ExtendedContext.power(Decimal('Infinity'), Decimal('0')) + >>> c.power(Decimal('Infinity'), Decimal('0')) Decimal("1") - >>> ExtendedContext.power(Decimal('Infinity'), Decimal('1')) - Decimal("Infinity") - >>> ExtendedContext.power(Decimal('Infinity'), Decimal('2')) + >>> c.power(Decimal('Infinity'), Decimal('1')) Decimal("Infinity") - >>> ExtendedContext.power(Decimal('-Infinity'), Decimal('-2')) - Decimal("0") - >>> ExtendedContext.power(Decimal('-Infinity'), Decimal('-1')) + >>> c.power(Decimal('-Infinity'), Decimal('-1')) Decimal("-0") - >>> ExtendedContext.power(Decimal('-Infinity'), Decimal('0')) + >>> c.power(Decimal('-Infinity'), Decimal('0')) Decimal("1") - >>> ExtendedContext.power(Decimal('-Infinity'), Decimal('1')) + >>> c.power(Decimal('-Infinity'), Decimal('1')) Decimal("-Infinity") - >>> ExtendedContext.power(Decimal('-Infinity'), Decimal('2')) + >>> c.power(Decimal('-Infinity'), Decimal('2')) Decimal("Infinity") - >>> ExtendedContext.power(Decimal('0'), Decimal('0')) + >>> c.power(Decimal('0'), Decimal('0')) Decimal("NaN") + + >>> c.power(Decimal('3'), Decimal('7'), Decimal('16')) + Decimal("11") + >>> c.power(Decimal('-3'), Decimal('7'), Decimal('16')) + Decimal("-11") + >>> c.power(Decimal('-3'), Decimal('8'), Decimal('16')) + Decimal("1") + >>> c.power(Decimal('3'), Decimal('7'), Decimal('-16')) + Decimal("11") + >>> c.power(Decimal('23E12345'), Decimal('67E189'), Decimal('123456789')) + Decimal("11729830") + >>> c.power(Decimal('-0'), Decimal('17'), Decimal('1729')) + Decimal("-0") + >>> c.power(Decimal('-23'), Decimal('0'), Decimal('65537')) + Decimal("1") """ return a.__pow__(b, modulo, context=self) def quantize(self, a, b): - """Returns a value equal to 'a' (rounded) and having the exponent of 'b'. + """Returns a value equal to 'a' (rounded), having the exponent of 'b'. The coefficient of the result is derived from that of the left-hand - operand. It may be rounded using the current rounding setting (if the + operand. It may be rounded using the current rounding setting (if the exponent is being increased), multiplied by a positive power of ten (if the exponent is being decreased), or is unchanged (if the exponent is already equal to that of the right-hand operand). Unlike other operations, if the length of the coefficient after the quantize operation would be greater than precision then an Invalid - operation condition is raised. This guarantees that, unless there is an - error condition, the exponent of the result of a quantize is always + operation condition is raised. This guarantees that, unless there is + an error condition, the exponent of the result of a quantize is always equal to that of the right-hand operand. Also unlike other operations, quantize will never raise Underflow, even @@ -2712,13 +4415,21 @@ """ return a.quantize(b, context=self) + def radix(self): + """Just returns 10, as this is Decimal, :) + + >>> ExtendedContext.radix() + Decimal("10") + """ + return Decimal(10) + def remainder(self, a, b): """Returns the remainder from integer division. The result is the residue of the dividend after the operation of - calculating integer division as described for divide-integer, rounded to - precision digits if necessary. The sign of the result, if non-zero, is - the same as that of the original dividend. + calculating integer division as described for divide-integer, rounded + to precision digits if necessary. The sign of the result, if + non-zero, is the same as that of the original dividend. This operation will fail under the same conditions as integer division (that is, if integer division on the same two operands would fail, the @@ -2742,7 +4453,7 @@ def remainder_near(self, a, b): """Returns to be "a - b * n", where n is the integer nearest the exact value of "x / b" (if two integers are equally near then the even one - is chosen). If the result is equal to 0 then its sign will be the + is chosen). If the result is equal to 0 then its sign will be the sign of a. This operation will fail under the same conditions as integer division @@ -2766,6 +4477,28 @@ """ return a.remainder_near(b, context=self) + def rotate(self, a, b): + """Returns a rotated copy of a, b times. + + The coefficient of the result is a rotated copy of the digits in + the coefficient of the first operand. The number of places of + rotation is taken from the absolute value of the second operand, + with the rotation being to the left if the second operand is + positive or to the right otherwise. + + >>> ExtendedContext.rotate(Decimal('34'), Decimal('8')) + Decimal("400000003") + >>> ExtendedContext.rotate(Decimal('12'), Decimal('9')) + Decimal("12") + >>> ExtendedContext.rotate(Decimal('123456789'), Decimal('-2')) + Decimal("891234567") + >>> ExtendedContext.rotate(Decimal('123456789'), Decimal('0')) + Decimal("123456789") + >>> ExtendedContext.rotate(Decimal('123456789'), Decimal('+2')) + Decimal("345678912") + """ + return a.rotate(b, context=self) + def same_quantum(self, a, b): """Returns True if the two operands have the same exponent. @@ -2783,8 +4516,43 @@ """ return a.same_quantum(b) + def scaleb (self, a, b): + """Returns the first operand after adding the second value its exp. + + >>> ExtendedContext.scaleb(Decimal('7.50'), Decimal('-2')) + Decimal("0.0750") + >>> ExtendedContext.scaleb(Decimal('7.50'), Decimal('0')) + Decimal("7.50") + >>> ExtendedContext.scaleb(Decimal('7.50'), Decimal('3')) + Decimal("7.50E+3") + """ + return a.scaleb (b, context=self) + + def shift(self, a, b): + """Returns a shifted copy of a, b times. + + The coefficient of the result is a shifted copy of the digits + in the coefficient of the first operand. The number of places + to shift is taken from the absolute value of the second operand, + with the shift being to the left if the second operand is + positive or to the right otherwise. Digits shifted into the + coefficient are zeros. + + >>> ExtendedContext.shift(Decimal('34'), Decimal('8')) + Decimal("400000000") + >>> ExtendedContext.shift(Decimal('12'), Decimal('9')) + Decimal("0") + >>> ExtendedContext.shift(Decimal('123456789'), Decimal('-2')) + Decimal("1234567") + >>> ExtendedContext.shift(Decimal('123456789'), Decimal('0')) + Decimal("123456789") + >>> ExtendedContext.shift(Decimal('123456789'), Decimal('+2')) + Decimal("345678900") + """ + return a.shift(b, context=self) + def sqrt(self, a): - """Returns the square root of a non-negative number to context precision. + """Square root of a non-negative number to context precision. If the result must be inexact, it is rounded using the round-half-even algorithm. @@ -2838,33 +4606,65 @@ """ return a.__str__(context=self) - def to_integral(self, a): + def to_integral_exact(self, a): + """Rounds to an integer. + + When the operand has a negative exponent, the result is the same + as using the quantize() operation using the given operand as the + left-hand-operand, 1E+0 as the right-hand-operand, and the precision + of the operand as the precision setting; Inexact and Rounded flags + are allowed in this operation. The rounding mode is taken from the + context. + + >>> ExtendedContext.to_integral_exact(Decimal('2.1')) + Decimal("2") + >>> ExtendedContext.to_integral_exact(Decimal('100')) + Decimal("100") + >>> ExtendedContext.to_integral_exact(Decimal('100.0')) + Decimal("100") + >>> ExtendedContext.to_integral_exact(Decimal('101.5')) + Decimal("102") + >>> ExtendedContext.to_integral_exact(Decimal('-101.5')) + Decimal("-102") + >>> ExtendedContext.to_integral_exact(Decimal('10E+5')) + Decimal("1.0E+6") + >>> ExtendedContext.to_integral_exact(Decimal('7.89E+77')) + Decimal("7.89E+77") + >>> ExtendedContext.to_integral_exact(Decimal('-Inf')) + Decimal("-Infinity") + """ + return a.to_integral_exact(context=self) + + def to_integral_value(self, a): """Rounds to an integer. When the operand has a negative exponent, the result is the same as using the quantize() operation using the given operand as the left-hand-operand, 1E+0 as the right-hand-operand, and the precision of the operand as the precision setting, except that no flags will - be set. The rounding mode is taken from the context. + be set. The rounding mode is taken from the context. - >>> ExtendedContext.to_integral(Decimal('2.1')) + >>> ExtendedContext.to_integral_value(Decimal('2.1')) Decimal("2") - >>> ExtendedContext.to_integral(Decimal('100')) + >>> ExtendedContext.to_integral_value(Decimal('100')) Decimal("100") - >>> ExtendedContext.to_integral(Decimal('100.0')) + >>> ExtendedContext.to_integral_value(Decimal('100.0')) Decimal("100") - >>> ExtendedContext.to_integral(Decimal('101.5')) + >>> ExtendedContext.to_integral_value(Decimal('101.5')) Decimal("102") - >>> ExtendedContext.to_integral(Decimal('-101.5')) + >>> ExtendedContext.to_integral_value(Decimal('-101.5')) Decimal("-102") - >>> ExtendedContext.to_integral(Decimal('10E+5')) + >>> ExtendedContext.to_integral_value(Decimal('10E+5')) Decimal("1.0E+6") - >>> ExtendedContext.to_integral(Decimal('7.89E+77')) + >>> ExtendedContext.to_integral_value(Decimal('7.89E+77')) Decimal("7.89E+77") - >>> ExtendedContext.to_integral(Decimal('-Inf')) + >>> ExtendedContext.to_integral_value(Decimal('-Inf')) Decimal("-Infinity") """ - return a.to_integral(context=self) + return a.to_integral_value(context=self) + + # the method name changed, but we provide also the old one, for compatibility + to_integral = to_integral_value class _WorkRep(object): __slots__ = ('sign','int','exp') @@ -2879,10 +4679,7 @@ self.exp = None elif isinstance(value, Decimal): self.sign = value._sign - cum = 0 - for digit in value._int: - cum = cum * 10 + digit - self.int = cum + self.int = int(value._int) self.exp = value._exp else: # assert isinstance(value, tuple) @@ -2897,70 +4694,375 @@ -def _normalize(op1, op2, shouldround = 0, prec = 0): +def _normalize(op1, op2, prec = 0): """Normalizes op1, op2 to have the same exp and length of coefficient. Done during addition. """ - # Yes, the exponent is a long, but the difference between exponents - # must be an int-- otherwise you'd get a big memory problem. - numdigits = int(op1.exp - op2.exp) - if numdigits < 0: - numdigits = -numdigits + if op1.exp < op2.exp: tmp = op2 other = op1 else: tmp = op1 other = op2 + # Let exp = min(tmp.exp - 1, tmp.adjusted() - precision - 1). + # Then adding 10**exp to tmp has the same effect (after rounding) + # as adding any positive quantity smaller than 10**exp; similarly + # for subtraction. So if other is smaller than 10**exp we replace + # it with 10**exp. This avoids tmp.exp - other.exp getting too large. + tmp_len = len(str(tmp.int)) + other_len = len(str(other.int)) + exp = tmp.exp + min(-1, tmp_len - prec - 2) + if other_len + other.exp - 1 < exp: + other.int = 1 + other.exp = exp - if shouldround and numdigits > prec + 1: - # Big difference in exponents - check the adjusted exponents - tmp_len = len(str(tmp.int)) - other_len = len(str(other.int)) - if numdigits > (other_len + prec + 1 - tmp_len): - # If the difference in adjusted exps is > prec+1, we know - # other is insignificant, so might as well put a 1 after the precision. - # (since this is only for addition.) Also stops use of massive longs. - - extend = prec + 2 - tmp_len - if extend <= 0: - extend = 1 - tmp.int *= 10 ** extend - tmp.exp -= extend - other.int = 1 - other.exp = tmp.exp - return op1, op2 - - tmp.int *= 10 ** numdigits - tmp.exp -= numdigits + tmp.int *= 10 ** (tmp.exp - other.exp) + tmp.exp = other.exp return op1, op2 -def _adjust_coefficients(op1, op2): - """Adjust op1, op2 so that op2.int * 10 > op1.int >= op2.int. +##### Integer arithmetic functions used by ln, log10, exp and __pow__ ##### + +# This function from Tim Peters was taken from here: +# http://mail.python.org/pipermail/python-list/1999-July/007758.html +# The correction being in the function definition is for speed, and +# the whole function is not resolved with math.log because of avoiding +# the use of floats. +def _nbits(n, correction = { + '0': 4, '1': 3, '2': 2, '3': 2, + '4': 1, '5': 1, '6': 1, '7': 1, + '8': 0, '9': 0, 'a': 0, 'b': 0, + 'c': 0, 'd': 0, 'e': 0, 'f': 0}): + """Number of bits in binary representation of the positive integer n, + or 0 if n == 0. + """ + if n < 0: + raise ValueError("The argument to _nbits should be nonnegative.") + hex_n = "%x" % n + return 4*len(hex_n) - correction[hex_n[0]] + +def _sqrt_nearest(n, a): + """Closest integer to the square root of the positive integer n. a is + an initial approximation to the square root. Any positive integer + will do for a, but the closer a is to the square root of n the + faster convergence will be. + + """ + if n <= 0 or a <= 0: + raise ValueError("Both arguments to _sqrt_nearest should be positive.") + + b=0 + while a != b: + b, a = a, a--n//a>>1 + return a + +def _rshift_nearest(x, shift): + """Given an integer x and a nonnegative integer shift, return closest + integer to x / 2**shift; use round-to-even in case of a tie. + + """ + b, q = 1L << shift, x >> shift + return q + (2*(x & (b-1)) + (q&1) > b) + +def _div_nearest(a, b): + """Closest integer to a/b, a and b positive integers; rounds to even + in the case of a tie. + + """ + q, r = divmod(a, b) + return q + (2*r + (q&1) > b) + +def _ilog(x, M, L = 8): + """Integer approximation to M*log(x/M), with absolute error boundable + in terms only of x/M. + + Given positive integers x and M, return an integer approximation to + M * log(x/M). For L = 8 and 0.1 <= x/M <= 10 the difference + between the approximation and the exact result is at most 22. For + L = 8 and 1.0 <= x/M <= 10.0 the difference is at most 15. In + both cases these are upper bounds on the error; it will usually be + much smaller.""" + + # The basic algorithm is the following: let log1p be the function + # log1p(x) = log(1+x). Then log(x/M) = log1p((x-M)/M). We use + # the reduction + # + # log1p(y) = 2*log1p(y/(1+sqrt(1+y))) + # + # repeatedly until the argument to log1p is small (< 2**-L in + # absolute value). For small y we can use the Taylor series + # expansion + # + # log1p(y) ~ y - y**2/2 + y**3/3 - ... - (-y)**T/T + # + # truncating at T such that y**T is small enough. The whole + # computation is carried out in a form of fixed-point arithmetic, + # with a real number z being represented by an integer + # approximation to z*M. To avoid loss of precision, the y below + # is actually an integer approximation to 2**R*y*M, where R is the + # number of reductions performed so far. + + y = x-M + # argument reduction; R = number of reductions performed + R = 0 + while (R <= L and long(abs(y)) << L-R >= M or + R > L and abs(y) >> R-L >= M): + y = _div_nearest(long(M*y) << 1, + M + _sqrt_nearest(M*(M+_rshift_nearest(y, R)), M)) + R += 1 + + # Taylor series with T terms + T = -int(-10*len(str(M))//(3*L)) + yshift = _rshift_nearest(y, R) + w = _div_nearest(M, T) + for k in xrange(T-1, 0, -1): + w = _div_nearest(M, k) - _div_nearest(yshift*w, M) + + return _div_nearest(w*y, M) + +def _dlog10(c, e, p): + """Given integers c, e and p with c > 0, p >= 0, compute an integer + approximation to 10**p * log10(c*10**e), with an absolute error of + at most 1. Assumes that c*10**e is not exactly 1.""" + + # increase precision by 2; compensate for this by dividing + # final result by 100 + p += 2 + + # write c*10**e as d*10**f with either: + # f >= 0 and 1 <= d <= 10, or + # f <= 0 and 0.1 <= d <= 1. + # Thus for c*10**e close to 1, f = 0 + l = len(str(c)) + f = e+l - (e+l >= 1) + + if p > 0: + M = 10**p + k = e+p-f + if k >= 0: + c *= 10**k + else: + c = _div_nearest(c, 10**-k) + + log_d = _ilog(c, M) # error < 5 + 22 = 27 + log_10 = _log10_digits(p) # error < 1 + log_d = _div_nearest(log_d*M, log_10) + log_tenpower = f*M # exact + else: + log_d = 0 # error < 2.31 + log_tenpower = div_nearest(f, 10**-p) # error < 0.5 + + return _div_nearest(log_tenpower+log_d, 100) + +def _dlog(c, e, p): + """Given integers c, e and p with c > 0, compute an integer + approximation to 10**p * log(c*10**e), with an absolute error of + at most 1. Assumes that c*10**e is not exactly 1.""" + + # Increase precision by 2. The precision increase is compensated + # for at the end with a division by 100. + p += 2 + + # rewrite c*10**e as d*10**f with either f >= 0 and 1 <= d <= 10, + # or f <= 0 and 0.1 <= d <= 1. Then we can compute 10**p * log(c*10**e) + # as 10**p * log(d) + 10**p*f * log(10). + l = len(str(c)) + f = e+l - (e+l >= 1) + + # compute approximation to 10**p*log(d), with error < 27 + if p > 0: + k = e+p-f + if k >= 0: + c *= 10**k + else: + c = _div_nearest(c, 10**-k) # error of <= 0.5 in c + + # _ilog magnifies existing error in c by a factor of at most 10 + log_d = _ilog(c, 10**p) # error < 5 + 22 = 27 + else: + # p <= 0: just approximate the whole thing by 0; error < 2.31 + log_d = 0 + + # compute approximation to f*10**p*log(10), with error < 11. + if f: + extra = len(str(abs(f)))-1 + if p + extra >= 0: + # error in f * _log10_digits(p+extra) < |f| * 1 = |f| + # after division, error < |f|/10**extra + 0.5 < 10 + 0.5 < 11 + f_log_ten = _div_nearest(f*_log10_digits(p+extra), 10**extra) + else: + f_log_ten = 0 + else: + f_log_ten = 0 + + # error in sum < 11+27 = 38; error after division < 0.38 + 0.5 < 1 + return _div_nearest(f_log_ten + log_d, 100) + +class _Log10Memoize(object): + """Class to compute, store, and allow retrieval of, digits of the + constant log(10) = 2.302585.... This constant is needed by + Decimal.ln, Decimal.log10, Decimal.exp and Decimal.__pow__.""" + def __init__(self): + self.digits = "23025850929940456840179914546843642076011014886" + + def getdigits(self, p): + """Given an integer p >= 0, return floor(10**p)*log(10). + + For example, self.getdigits(3) returns 2302. + """ + # digits are stored as a string, for quick conversion to + # integer in the case that we've already computed enough + # digits; the stored digits should always be correct + # (truncated, not rounded to nearest). + if p < 0: + raise ValueError("p should be nonnegative") + + if p >= len(self.digits): + # compute p+3, p+6, p+9, ... digits; continue until at + # least one of the extra digits is nonzero + extra = 3 + while True: + # compute p+extra digits, correct to within 1ulp + M = 10**(p+extra+2) + digits = str(_div_nearest(_ilog(10*M, M), 100)) + if digits[-extra:] != '0'*extra: + break + extra += 3 + # keep all reliable digits so far; remove trailing zeros + # and next nonzero digit + self.digits = digits.rstrip('0')[:-1] + return int(self.digits[:p+1]) + +_log10_digits = _Log10Memoize().getdigits + +def _iexp(x, M, L=8): + """Given integers x and M, M > 0, such that x/M is small in absolute + value, compute an integer approximation to M*exp(x/M). For 0 <= + x/M <= 2.4, the absolute error in the result is bounded by 60 (and + is usually much smaller).""" + + # Algorithm: to compute exp(z) for a real number z, first divide z + # by a suitable power R of 2 so that |z/2**R| < 2**-L. Then + # compute expm1(z/2**R) = exp(z/2**R) - 1 using the usual Taylor + # series + # + # expm1(x) = x + x**2/2! + x**3/3! + ... + # + # Now use the identity + # + # expm1(2x) = expm1(x)*(expm1(x)+2) + # + # R times to compute the sequence expm1(z/2**R), + # expm1(z/2**(R-1)), ... , exp(z/2), exp(z). + + # Find R such that x/2**R/M <= 2**-L + R = _nbits((long(x)< M + T = -int(-10*len(str(M))//(3*L)) + y = _div_nearest(x, T) + Mshift = long(M)<= 0: + cshift = c*10**shift + else: + cshift = c//10**-shift + quot, rem = divmod(cshift, _log10_digits(q)) + + # reduce remainder back to original precision + rem = _div_nearest(rem, 10**extra) + + # error in result of _iexp < 120; error after division < 0.62 + return _div_nearest(_iexp(rem, 10**p), 1000), quot - p + 3 + +def _dpower(xc, xe, yc, ye, p): + """Given integers xc, xe, yc and ye representing Decimals x = xc*10**xe and + y = yc*10**ye, compute x**y. Returns a pair of integers (c, e) such that: + + 10**(p-1) <= c <= 10**p, and + (c-1)*10**e < x**y < (c+1)*10**e - Returns the adjusted op1, op2 as well as the change in op1.exp-op2.exp. + in other words, c*10**e is an approximation to x**y with p digits + of precision, and with an error in c of at most 1. (This is + almost, but not quite, the same as the error being < 1ulp: when c + == 10**(p-1) we can only guarantee error < 10ulp.) - Used on _WorkRep instances during division. + We assume that: x is positive and not equal to 1, and y is nonzero. """ - adjust = 0 - #If op1 is smaller, make it larger - while op2.int > op1.int: - op1.int *= 10 - op1.exp -= 1 - adjust += 1 - #If op2 is too small, make it larger - while op1.int >= (10 * op2.int): - op2.int *= 10 - op2.exp -= 1 - adjust -= 1 + # Find b such that 10**(b-1) <= |y| <= 10**b + b = len(str(abs(yc))) + ye - return op1, op2, adjust + # log(x) = lxc*10**(-p-b-1), to p+b+1 places after the decimal point + lxc = _dlog(xc, xe, p+b+1) -##### Helper Functions ######################################## + # compute product y*log(x) = yc*lxc*10**(-p-b-1+ye) = pc*10**(-p-1) + shift = ye-b + if shift >= 0: + pc = lxc*yc*10**shift + else: + pc = _div_nearest(lxc*yc, 10**-shift) + + if pc == 0: + # we prefer a result that isn't exactly 1; this makes it + # easier to compute a correctly rounded result in __pow__ + if ((len(str(xc)) + xe >= 1) == (yc > 0)): # if x**y > 1: + coeff, exp = 10**(p-1)+1, 1-p + else: + coeff, exp = 10**p-1, -p + else: + coeff, exp = _dexp(pc, -(p+1), p+1) + coeff = _div_nearest(coeff, 10) + exp += 1 + + return coeff, exp + +def _log10_lb(c, correction = { + '1': 100, '2': 70, '3': 53, '4': 40, '5': 31, + '6': 23, '7': 16, '8': 10, '9': 5}): + """Compute a lower bound for 100*log10(c) for a positive integer c.""" + if c <= 0: + raise ValueError("The argument to _log10_lb should be nonnegative.") + str_c = str(c) + return 100*len(str_c) - correction[str_c[0]] -def _convert_other(other): +##### Helper Functions #################################################### + +def _convert_other(other, raiseit=False): """Convert other to Decimal. Verifies that it's ok to use in an implicit construction. @@ -2969,56 +5071,11 @@ return other if isinstance(other, (int, long)): return Decimal(other) + if raiseit: + raise TypeError("Unable to convert %s to Decimal" % other) return NotImplemented -_infinity_map = { - 'inf' : 1, - 'infinity' : 1, - '+inf' : 1, - '+infinity' : 1, - '-inf' : -1, - '-infinity' : -1 -} - -def _isinfinity(num): - """Determines whether a string or float is infinity. - - +1 for negative infinity; 0 for finite ; +1 for positive infinity - """ - num = str(num).lower() - return _infinity_map.get(num, 0) - -def _isnan(num): - """Determines whether a string or float is NaN - - (1, sign, diagnostic info as string) => NaN - (2, sign, diagnostic info as string) => sNaN - 0 => not a NaN - """ - num = str(num).lower() - if not num: - return 0 - - #get the sign, get rid of trailing [+-] - sign = 0 - if num[0] == '+': - num = num[1:] - elif num[0] == '-': #elif avoids '+-nan' - num = num[1:] - sign = 1 - - if num.startswith('nan'): - if len(num) > 3 and not num[3:].isdigit(): #diagnostic info - return 0 - return (1, sign, num[3:].lstrip('0')) - if num.startswith('snan'): - if len(num) > 4 and not num[4:].isdigit(): - return 0 - return (2, sign, num[4:].lstrip('0')) - return 0 - - -##### Setup Specific Contexts ################################ +##### Setup Specific Contexts ############################################ # The default context prototype used by Context() # Is mutable, so that new contexts can have different default values @@ -3027,7 +5084,6 @@ prec=28, rounding=ROUND_HALF_EVEN, traps=[DivisionByZero, Overflow, InvalidOperation], flags=[], - _rounding_decision=ALWAYS_ROUND, Emax=999999999, Emin=-999999999, capitals=1 @@ -3051,85 +5107,62 @@ ) -##### Useful Constants (internal use only) #################### - -#Reusable defaults -Inf = Decimal('Inf') -negInf = Decimal('-Inf') - -#Infsign[sign] is infinity w/ that sign -Infsign = (Inf, negInf) - -NaN = Decimal('NaN') - - -##### crud for parsing strings ################################# +##### crud for parsing strings ############################################# import re -# There's an optional sign at the start, and an optional exponent -# at the end. The exponent has an optional sign and at least one -# digit. In between, must have either at least one digit followed -# by an optional fraction, or a decimal point followed by at least -# one digit. Yuck. +# Regular expression used for parsing numeric strings. Additional +# comments: +# +# 1. Uncomment the two '\s*' lines to allow leading and/or trailing +# whitespace. But note that the specification disallows whitespace in +# a numeric string. +# +# 2. For finite numbers (not infinities and NaNs) the body of the +# number between the optional sign and the optional exponent must have +# at least one decimal digit, possibly after the decimal point. The +# lookahead expression '(?=\d|\.\d)' checks this. +# +# As the flag UNICODE is not enabled here, we're explicitly avoiding any +# other meaning for \d than the numbers [0-9]. -_parser = re.compile(r""" +import re +_parser = re.compile(r""" # A numeric string consists of: # \s* - (?P[-+])? + (?P[-+])? # an optional sign, followed by either... ( - (?P\d+) (\. (?P\d*))? + (?=\d|\.\d) # ...a number (with at least one digit) + (?P\d*) # consisting of a (possibly empty) integer part + (\.(?P\d*))? # followed by an optional fractional part + (E(?P[-+]?\d+))? # followed by an optional exponent, or... + | + Inf(inity)? # ...an infinity, or... | - \. (?P\d+) + (?Ps)? # ...an (optionally signaling) + NaN # NaN + (?P\d*) # with (possibly empty) diagnostic information. ) - ([eE](?P[-+]? \d+))? # \s* $ -""", re.VERBOSE).match #Uncomment the \s* to allow leading or trailing spaces. +""", re.VERBOSE | re.IGNORECASE).match +_all_zeros = re.compile('0*$').match +_exact_half = re.compile('50*$').match del re -# return sign, n, p s.t. float string value == -1**sign * n * 10**p exactly -def _string2exact(s): - m = _parser(s) - if m is None: - raise ValueError("invalid literal for Decimal: %r" % s) +##### Useful Constants (internal use only) ################################ - if m.group('sign') == "-": - sign = 1 - else: - sign = 0 - - exp = m.group('exp') - if exp is None: - exp = 0 - else: - exp = int(exp) +# Reusable defaults +Inf = Decimal('Inf') +negInf = Decimal('-Inf') +NaN = Decimal('NaN') +Dec_0 = Decimal(0) +Dec_p1 = Decimal(1) +Dec_n1 = Decimal(-1) - intpart = m.group('int') - if intpart is None: - intpart = "" - fracpart = m.group('onlyfrac') - else: - fracpart = m.group('frac') - if fracpart is None: - fracpart = "" - - exp -= len(fracpart) - - mantissa = intpart + fracpart - tmp = map(int, mantissa) - backup = tmp - while tmp and tmp[0] == 0: - del tmp[0] - - # It's a zero - if not tmp: - if backup: - return (sign, tuple(backup), exp) - return (sign, (0,), exp) - mantissa = tuple(tmp) +# Infsign[sign] is infinity w/ that sign +Infsign = (Inf, negInf) - return (sign, mantissa, exp) if __name__ == '__main__': Modified: python/branches/release25-maint/Lib/test/decimaltestdata/abs.decTest ============================================================================== --- python/branches/release25-maint/Lib/test/decimaltestdata/abs.decTest (original) +++ python/branches/release25-maint/Lib/test/decimaltestdata/abs.decTest Tue Jan 8 17:20:31 2008 @@ -1,6 +1,6 @@ ------------------------------------------------------------------------ -- abs.decTest -- decimal absolute value -- --- Copyright (c) IBM Corporation, 1981, 2004. All rights reserved. -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- ------------------------------------------------------------------------ -- Please see the document "General Decimal Arithmetic Testcases" -- -- at http://www2.hursley.ibm.com/decimal for the description of -- @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc at uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.39 +version: 2.57 -- This set of tests primarily tests the existence of the operator. -- Additon, subtraction, rounding, and more overflows are tested @@ -106,9 +106,9 @@ absx215 abs 0.999E-999 -> 1.00E-999 Inexact Rounded Subnormal Underflow absx216 abs 0.099E-999 -> 1.0E-1000 Inexact Rounded Subnormal Underflow absx217 abs 0.009E-999 -> 1E-1001 Inexact Rounded Subnormal Underflow -absx218 abs 0.001E-999 -> 0E-1001 Inexact Rounded Subnormal Underflow -absx219 abs 0.0009E-999 -> 0E-1001 Inexact Rounded Subnormal Underflow -absx220 abs 0.0001E-999 -> 0E-1001 Inexact Rounded Subnormal Underflow +absx218 abs 0.001E-999 -> 0E-1001 Inexact Rounded Subnormal Underflow Clamped +absx219 abs 0.0009E-999 -> 0E-1001 Inexact Rounded Subnormal Underflow Clamped +absx220 abs 0.0001E-999 -> 0E-1001 Inexact Rounded Subnormal Underflow Clamped absx230 abs -1.00E-999 -> 1.00E-999 absx231 abs -0.1E-999 -> 1E-1000 Subnormal @@ -119,9 +119,9 @@ absx235 abs -0.999E-999 -> 1.00E-999 Inexact Rounded Subnormal Underflow absx236 abs -0.099E-999 -> 1.0E-1000 Inexact Rounded Subnormal Underflow absx237 abs -0.009E-999 -> 1E-1001 Inexact Rounded Subnormal Underflow -absx238 abs -0.001E-999 -> 0E-1001 Inexact Rounded Subnormal Underflow -absx239 abs -0.0009E-999 -> 0E-1001 Inexact Rounded Subnormal Underflow -absx240 abs -0.0001E-999 -> 0E-1001 Inexact Rounded Subnormal Underflow +absx238 abs -0.001E-999 -> 0E-1001 Inexact Rounded Subnormal Underflow Clamped +absx239 abs -0.0009E-999 -> 0E-1001 Inexact Rounded Subnormal Underflow Clamped +absx240 abs -0.0001E-999 -> 0E-1001 Inexact Rounded Subnormal Underflow Clamped -- long operand tests maxexponent: 999 Modified: python/branches/release25-maint/Lib/test/decimaltestdata/add.decTest ============================================================================== --- python/branches/release25-maint/Lib/test/decimaltestdata/add.decTest (original) +++ python/branches/release25-maint/Lib/test/decimaltestdata/add.decTest Tue Jan 8 17:20:31 2008 @@ -1,6 +1,6 @@ ------------------------------------------------------------------------- +------/cancell---------------------------------------------------------- -- add.decTest -- decimal addition -- --- Copyright (c) IBM Corporation, 1981, 2004. All rights reserved. -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- ------------------------------------------------------------------------ -- Please see the document "General Decimal Arithmetic Testcases" -- -- at http://www2.hursley.ibm.com/decimal for the description of -- @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc at uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.39 +version: 2.57 precision: 9 rounding: half_up @@ -86,6 +86,7 @@ addx049 add '10000e+9' '7000' -> '10000000007000' addx050 add '10000e+9' '70000' -> '10000000070000' addx051 add '10000e+9' '700000' -> '10000000700000' +addx052 add '10000e+9' '7000000' -> '10000007000000' -- examples from decarith addx053 add '12' '7.00' -> '19.00' @@ -216,7 +217,7 @@ addx167 add '1.11' '7E+12' -> '7000000000001.11' addx168 add '-1' '7E+12' -> '6999999999999' --- 123456789012345 123456789012345 1 23456789012345 +-- 123456789012345 123456789012345 1 23456789012345 addx170 add '0.444444444444444' '0.555555555555563' -> '1.00000000000001' Inexact Rounded addx171 add '0.444444444444444' '0.555555555555562' -> '1.00000000000001' Inexact Rounded addx172 add '0.444444444444444' '0.555555555555561' -> '1.00000000000001' Inexact Rounded @@ -396,6 +397,7 @@ addx361 add 0E+50 10000E+1 -> 1.0000E+5 addx362 add 10000E+1 0E-50 -> 100000.0 Rounded addx363 add 10000E+1 10000E-50 -> 100000.0 Rounded Inexact +addx364 add 9.999999E+92 -9.999999E+92 -> 0E+86 -- a curiosity from JSR 13 testing rounding: half_down @@ -568,7 +570,7 @@ rounding: down addx561 add 1e-398 9.000000000000000E+384 -> 9.000000000000000E+384 Inexact Rounded addx562 add 0 9.000000000000000E+384 -> 9.000000000000000E+384 Rounded --- and using decimal64 bounds... +-- and using decimal64 bounds (see also ddadd.decTest) precision: 16 maxExponent: +384 minExponent: -383 @@ -576,6 +578,7 @@ addx563 add 1e-388 9.000000000000000E+374 -> 9.000000000000000E+374 Inexact Rounded addx564 add 0 9.000000000000000E+374 -> 9.000000000000000E+374 Rounded + -- some more residue effects with extreme rounding precision: 9 rounding: half_up @@ -955,26 +958,26 @@ addx912 add 0.10E-999 0 -> 1.0E-1000 Subnormal addx913 add 0.100E-999 0 -> 1.0E-1000 Subnormal Rounded addx914 add 0.01E-999 0 -> 1E-1001 Subnormal --- next is rounded to Emin +-- next is rounded to Nmin addx915 add 0.999E-999 0 -> 1.00E-999 Inexact Rounded Subnormal Underflow addx916 add 0.099E-999 0 -> 1.0E-1000 Inexact Rounded Subnormal Underflow addx917 add 0.009E-999 0 -> 1E-1001 Inexact Rounded Subnormal Underflow -addx918 add 0.001E-999 0 -> 0E-1001 Inexact Rounded Subnormal Underflow -addx919 add 0.0009E-999 0 -> 0E-1001 Inexact Rounded Subnormal Underflow -addx920 add 0.0001E-999 0 -> 0E-1001 Inexact Rounded Subnormal Underflow +addx918 add 0.001E-999 0 -> 0E-1001 Inexact Rounded Subnormal Underflow Clamped +addx919 add 0.0009E-999 0 -> 0E-1001 Inexact Rounded Subnormal Underflow Clamped +addx920 add 0.0001E-999 0 -> 0E-1001 Inexact Rounded Subnormal Underflow Clamped addx930 add -1.00E-999 0 -> -1.00E-999 addx931 add -0.1E-999 0 -> -1E-1000 Subnormal addx932 add -0.10E-999 0 -> -1.0E-1000 Subnormal addx933 add -0.100E-999 0 -> -1.0E-1000 Subnormal Rounded addx934 add -0.01E-999 0 -> -1E-1001 Subnormal --- next is rounded to Emin +-- next is rounded to Nmin addx935 add -0.999E-999 0 -> -1.00E-999 Inexact Rounded Subnormal Underflow addx936 add -0.099E-999 0 -> -1.0E-1000 Inexact Rounded Subnormal Underflow addx937 add -0.009E-999 0 -> -1E-1001 Inexact Rounded Subnormal Underflow -addx938 add -0.001E-999 0 -> -0E-1001 Inexact Rounded Subnormal Underflow -addx939 add -0.0009E-999 0 -> -0E-1001 Inexact Rounded Subnormal Underflow -addx940 add -0.0001E-999 0 -> -0E-1001 Inexact Rounded Subnormal Underflow +addx938 add -0.001E-999 0 -> -0E-1001 Inexact Rounded Subnormal Underflow Clamped +addx939 add -0.0009E-999 0 -> -0E-1001 Inexact Rounded Subnormal Underflow Clamped +addx940 add -0.0001E-999 0 -> -0E-1001 Inexact Rounded Subnormal Underflow Clamped -- some non-zero subnormal adds addx950 add 1.00E-999 0.1E-999 -> 1.10E-999 @@ -995,12 +998,43 @@ addx964 add 0.100E-999 -0.1E-999 -> 0E-1001 Clamped addx965 add 0.01E-999 -0.1E-999 -> -9E-1001 Subnormal addx966 add 0.999E-999 -0.1E-999 -> 9.0E-1000 Inexact Rounded Subnormal Underflow -addx967 add 0.099E-999 -0.1E-999 -> -0E-1001 Inexact Rounded Subnormal Underflow +addx967 add 0.099E-999 -0.1E-999 -> -0E-1001 Inexact Rounded Subnormal Underflow Clamped addx968 add 0.009E-999 -0.1E-999 -> -9E-1001 Inexact Rounded Subnormal Underflow addx969 add 0.001E-999 -0.1E-999 -> -1.0E-1000 Inexact Rounded Subnormal Underflow addx970 add 0.0009E-999 -0.1E-999 -> -1.0E-1000 Inexact Rounded Subnormal Underflow addx971 add 0.0001E-999 -0.1E-999 -> -1.0E-1000 Inexact Rounded Subnormal Underflow +-- some 'real' numbers +maxExponent: 384 +minExponent: -383 +precision: 8 +addx566 add 99999061735E-394 0E-394 -> 9.999906E-384 Inexact Rounded Underflow Subnormal +precision: 7 +addx567 add 99999061735E-394 0E-394 -> 9.99991E-384 Inexact Rounded Underflow Subnormal +precision: 6 +addx568 add 99999061735E-394 0E-394 -> 9.9999E-384 Inexact Rounded Underflow Subnormal + +-- now the case where we can get underflow but the result is normal +-- [note this can't happen if the operands are also bounded, as we +-- cannot represent 1E-399, for example] +precision: 16 +rounding: half_up +maxExponent: 384 +minExponent: -383 + +addx571 add 1E-383 0 -> 1E-383 +addx572 add 1E-384 0 -> 1E-384 Subnormal +addx573 add 1E-383 1E-384 -> 1.1E-383 +addx574 subtract 1E-383 1E-384 -> 9E-384 Subnormal + +-- Here we explore the boundary of rounding a subnormal to Nmin +addx575 subtract 1E-383 1E-398 -> 9.99999999999999E-384 Subnormal +addx576 subtract 1E-383 1E-398 -> 9.99999999999999E-384 Subnormal +addx577 subtract 1E-383 1E-399 -> 1.000000000000000E-383 Underflow Inexact Subnormal Rounded +addx578 subtract 1E-383 1E-400 -> 1.000000000000000E-383 Underflow Inexact Subnormal Rounded +addx579 subtract 1E-383 1E-401 -> 1.000000000000000E-383 Underflow Inexact Subnormal Rounded +addx580 subtract 1E-383 1E-402 -> 1.000000000000000E-383 Underflow Inexact Subnormal Rounded + -- check overflow edge case precision: 7 rounding: half_up @@ -1088,6 +1122,15 @@ addx1117 add -1e-4 +1e-383 -> -0.00009999999999999999 Rounded Inexact addx1118 add -1e-5 +1e-383 -> -0.000009999999999999999 Rounded Inexact addx1119 add -1e-6 +1e-383 -> -9.999999999999999E-7 Rounded Inexact +addx1120 add +1e-383 -1e+2 -> -99.99999999999999 Rounded Inexact +addx1121 add +1e-383 -1e+1 -> -9.999999999999999 Rounded Inexact +addx1123 add +1e-383 -1 -> -0.9999999999999999 Rounded Inexact +addx1124 add +1e-383 -1e-1 -> -0.09999999999999999 Rounded Inexact +addx1125 add +1e-383 -1e-2 -> -0.009999999999999999 Rounded Inexact +addx1126 add +1e-383 -1e-3 -> -0.0009999999999999999 Rounded Inexact +addx1127 add +1e-383 -1e-4 -> -0.00009999999999999999 Rounded Inexact +addx1128 add +1e-383 -1e-5 -> -0.000009999999999999999 Rounded Inexact +addx1129 add +1e-383 -1e-6 -> -9.999999999999999E-7 Rounded Inexact rounding: down precision: 7 @@ -1106,21 +1149,1567 @@ addx1139 add 1000E-101 -1e-200 -> 9.99E-99 Subnormal Inexact Rounded Underflow addx1140 add 100E-101 -1e-200 -> 9.9E-100 Subnormal Inexact Rounded Underflow addx1141 add 10E-101 -1e-200 -> 9E-101 Subnormal Inexact Rounded Underflow -addx1142 add 1E-101 -1e-200 -> 0E-101 Subnormal Inexact Rounded Underflow -addx1143 add 0E-101 -1e-200 -> -0E-101 Subnormal Inexact Rounded Underflow -addx1144 add 1E-102 -1e-200 -> 0E-101 Subnormal Inexact Rounded Underflow +addx1142 add 1E-101 -1e-200 -> 0E-101 Subnormal Inexact Rounded Underflow Clamped +addx1143 add 0E-101 -1e-200 -> -0E-101 Subnormal Inexact Rounded Underflow Clamped +addx1144 add 1E-102 -1e-200 -> 0E-101 Subnormal Inexact Rounded Underflow Clamped addx1151 add 10000E-102 -1e-200 -> 9.99E-99 Subnormal Inexact Rounded Underflow addx1152 add 1000E-102 -1e-200 -> 9.9E-100 Subnormal Inexact Rounded Underflow addx1153 add 100E-102 -1e-200 -> 9E-101 Subnormal Inexact Rounded Underflow -addx1154 add 10E-102 -1e-200 -> 0E-101 Subnormal Inexact Rounded Underflow -addx1155 add 1E-102 -1e-200 -> 0E-101 Subnormal Inexact Rounded Underflow -addx1156 add 0E-102 -1e-200 -> -0E-101 Subnormal Inexact Rounded Underflow -addx1157 add 1E-103 -1e-200 -> 0E-101 Subnormal Inexact Rounded Underflow +addx1154 add 10E-102 -1e-200 -> 0E-101 Subnormal Inexact Rounded Underflow Clamped +addx1155 add 1E-102 -1e-200 -> 0E-101 Subnormal Inexact Rounded Underflow Clamped +addx1156 add 0E-102 -1e-200 -> -0E-101 Subnormal Inexact Rounded Underflow Clamped +addx1157 add 1E-103 -1e-200 -> 0E-101 Subnormal Inexact Rounded Underflow Clamped + +addx1160 add 100E-105 -1e-101 -> -0E-101 Subnormal Inexact Rounded Underflow Clamped +addx1161 add 100E-105 -1e-201 -> 0E-101 Subnormal Inexact Rounded Underflow Clamped + +-- tests based on Gunnar Degnbol's edge case +precision: 15 +rounding: half_up +maxExponent: 384 +minexponent: -383 + +addx1200 add 1E15 -0.5 -> 1.00000000000000E+15 Inexact Rounded +addx1201 add 1E15 -0.50 -> 1.00000000000000E+15 Inexact Rounded +addx1210 add 1E15 -0.51 -> 999999999999999 Inexact Rounded +addx1211 add 1E15 -0.501 -> 999999999999999 Inexact Rounded +addx1212 add 1E15 -0.5001 -> 999999999999999 Inexact Rounded +addx1213 add 1E15 -0.50001 -> 999999999999999 Inexact Rounded +addx1214 add 1E15 -0.500001 -> 999999999999999 Inexact Rounded +addx1215 add 1E15 -0.5000001 -> 999999999999999 Inexact Rounded +addx1216 add 1E15 -0.50000001 -> 999999999999999 Inexact Rounded +addx1217 add 1E15 -0.500000001 -> 999999999999999 Inexact Rounded +addx1218 add 1E15 -0.5000000001 -> 999999999999999 Inexact Rounded +addx1219 add 1E15 -0.50000000001 -> 999999999999999 Inexact Rounded +addx1220 add 1E15 -0.500000000001 -> 999999999999999 Inexact Rounded +addx1221 add 1E15 -0.5000000000001 -> 999999999999999 Inexact Rounded +addx1222 add 1E15 -0.50000000000001 -> 999999999999999 Inexact Rounded +addx1223 add 1E15 -0.500000000000001 -> 999999999999999 Inexact Rounded +addx1224 add 1E15 -0.5000000000000001 -> 999999999999999 Inexact Rounded +addx1225 add 1E15 -0.5000000000000000 -> 1.00000000000000E+15 Inexact Rounded +addx1230 add 1E15 -5000000.000000001 -> 999999995000000 Inexact Rounded + +precision: 16 + +addx1300 add 1E16 -0.5 -> 1.000000000000000E+16 Inexact Rounded +addx1310 add 1E16 -0.51 -> 9999999999999999 Inexact Rounded +addx1311 add 1E16 -0.501 -> 9999999999999999 Inexact Rounded +addx1312 add 1E16 -0.5001 -> 9999999999999999 Inexact Rounded +addx1313 add 1E16 -0.50001 -> 9999999999999999 Inexact Rounded +addx1314 add 1E16 -0.500001 -> 9999999999999999 Inexact Rounded +addx1315 add 1E16 -0.5000001 -> 9999999999999999 Inexact Rounded +addx1316 add 1E16 -0.50000001 -> 9999999999999999 Inexact Rounded +addx1317 add 1E16 -0.500000001 -> 9999999999999999 Inexact Rounded +addx1318 add 1E16 -0.5000000001 -> 9999999999999999 Inexact Rounded +addx1319 add 1E16 -0.50000000001 -> 9999999999999999 Inexact Rounded +addx1320 add 1E16 -0.500000000001 -> 9999999999999999 Inexact Rounded +addx1321 add 1E16 -0.5000000000001 -> 9999999999999999 Inexact Rounded +addx1322 add 1E16 -0.50000000000001 -> 9999999999999999 Inexact Rounded +addx1323 add 1E16 -0.500000000000001 -> 9999999999999999 Inexact Rounded +addx1324 add 1E16 -0.5000000000000001 -> 9999999999999999 Inexact Rounded +addx1325 add 1E16 -0.5000000000000000 -> 1.000000000000000E+16 Inexact Rounded +addx1326 add 1E16 -0.500000000000000 -> 1.000000000000000E+16 Inexact Rounded +addx1327 add 1E16 -0.50000000000000 -> 1.000000000000000E+16 Inexact Rounded +addx1328 add 1E16 -0.5000000000000 -> 1.000000000000000E+16 Inexact Rounded +addx1329 add 1E16 -0.500000000000 -> 1.000000000000000E+16 Inexact Rounded +addx1330 add 1E16 -0.50000000000 -> 1.000000000000000E+16 Inexact Rounded +addx1331 add 1E16 -0.5000000000 -> 1.000000000000000E+16 Inexact Rounded +addx1332 add 1E16 -0.500000000 -> 1.000000000000000E+16 Inexact Rounded +addx1333 add 1E16 -0.50000000 -> 1.000000000000000E+16 Inexact Rounded +addx1334 add 1E16 -0.5000000 -> 1.000000000000000E+16 Inexact Rounded +addx1335 add 1E16 -0.500000 -> 1.000000000000000E+16 Inexact Rounded +addx1336 add 1E16 -0.50000 -> 1.000000000000000E+16 Inexact Rounded +addx1337 add 1E16 -0.5000 -> 1.000000000000000E+16 Inexact Rounded +addx1338 add 1E16 -0.500 -> 1.000000000000000E+16 Inexact Rounded +addx1339 add 1E16 -0.50 -> 1.000000000000000E+16 Inexact Rounded + +addx1340 add 1E16 -5000000.000010001 -> 9999999995000000 Inexact Rounded +addx1341 add 1E16 -5000000.000000001 -> 9999999995000000 Inexact Rounded + +addx1349 add 9999999999999999 0.4 -> 9999999999999999 Inexact Rounded +addx1350 add 9999999999999999 0.49 -> 9999999999999999 Inexact Rounded +addx1351 add 9999999999999999 0.499 -> 9999999999999999 Inexact Rounded +addx1352 add 9999999999999999 0.4999 -> 9999999999999999 Inexact Rounded +addx1353 add 9999999999999999 0.49999 -> 9999999999999999 Inexact Rounded +addx1354 add 9999999999999999 0.499999 -> 9999999999999999 Inexact Rounded +addx1355 add 9999999999999999 0.4999999 -> 9999999999999999 Inexact Rounded +addx1356 add 9999999999999999 0.49999999 -> 9999999999999999 Inexact Rounded +addx1357 add 9999999999999999 0.499999999 -> 9999999999999999 Inexact Rounded +addx1358 add 9999999999999999 0.4999999999 -> 9999999999999999 Inexact Rounded +addx1359 add 9999999999999999 0.49999999999 -> 9999999999999999 Inexact Rounded +addx1360 add 9999999999999999 0.499999999999 -> 9999999999999999 Inexact Rounded +addx1361 add 9999999999999999 0.4999999999999 -> 9999999999999999 Inexact Rounded +addx1362 add 9999999999999999 0.49999999999999 -> 9999999999999999 Inexact Rounded +addx1363 add 9999999999999999 0.499999999999999 -> 9999999999999999 Inexact Rounded +addx1364 add 9999999999999999 0.4999999999999999 -> 9999999999999999 Inexact Rounded +addx1365 add 9999999999999999 0.5000000000000000 -> 1.000000000000000E+16 Inexact Rounded +addx1367 add 9999999999999999 0.500000000000000 -> 1.000000000000000E+16 Inexact Rounded +addx1368 add 9999999999999999 0.50000000000000 -> 1.000000000000000E+16 Inexact Rounded +addx1369 add 9999999999999999 0.5000000000000 -> 1.000000000000000E+16 Inexact Rounded +addx1370 add 9999999999999999 0.500000000000 -> 1.000000000000000E+16 Inexact Rounded +addx1371 add 9999999999999999 0.50000000000 -> 1.000000000000000E+16 Inexact Rounded +addx1372 add 9999999999999999 0.5000000000 -> 1.000000000000000E+16 Inexact Rounded +addx1373 add 9999999999999999 0.500000000 -> 1.000000000000000E+16 Inexact Rounded +addx1374 add 9999999999999999 0.50000000 -> 1.000000000000000E+16 Inexact Rounded +addx1375 add 9999999999999999 0.5000000 -> 1.000000000000000E+16 Inexact Rounded +addx1376 add 9999999999999999 0.500000 -> 1.000000000000000E+16 Inexact Rounded +addx1377 add 9999999999999999 0.50000 -> 1.000000000000000E+16 Inexact Rounded +addx1378 add 9999999999999999 0.5000 -> 1.000000000000000E+16 Inexact Rounded +addx1379 add 9999999999999999 0.500 -> 1.000000000000000E+16 Inexact Rounded +addx1380 add 9999999999999999 0.50 -> 1.000000000000000E+16 Inexact Rounded +addx1381 add 9999999999999999 0.5 -> 1.000000000000000E+16 Inexact Rounded +addx1382 add 9999999999999999 0.5000000000000001 -> 1.000000000000000E+16 Inexact Rounded +addx1383 add 9999999999999999 0.500000000000001 -> 1.000000000000000E+16 Inexact Rounded +addx1384 add 9999999999999999 0.50000000000001 -> 1.000000000000000E+16 Inexact Rounded +addx1385 add 9999999999999999 0.5000000000001 -> 1.000000000000000E+16 Inexact Rounded +addx1386 add 9999999999999999 0.500000000001 -> 1.000000000000000E+16 Inexact Rounded +addx1387 add 9999999999999999 0.50000000001 -> 1.000000000000000E+16 Inexact Rounded +addx1388 add 9999999999999999 0.5000000001 -> 1.000000000000000E+16 Inexact Rounded +addx1389 add 9999999999999999 0.500000001 -> 1.000000000000000E+16 Inexact Rounded +addx1390 add 9999999999999999 0.50000001 -> 1.000000000000000E+16 Inexact Rounded +addx1391 add 9999999999999999 0.5000001 -> 1.000000000000000E+16 Inexact Rounded +addx1392 add 9999999999999999 0.500001 -> 1.000000000000000E+16 Inexact Rounded +addx1393 add 9999999999999999 0.50001 -> 1.000000000000000E+16 Inexact Rounded +addx1394 add 9999999999999999 0.5001 -> 1.000000000000000E+16 Inexact Rounded +addx1395 add 9999999999999999 0.501 -> 1.000000000000000E+16 Inexact Rounded +addx1396 add 9999999999999999 0.51 -> 1.000000000000000E+16 Inexact Rounded + +-- More GD edge cases, where difference between the unadjusted +-- exponents is larger than the maximum precision and one side is 0 +precision: 15 +rounding: half_up +maxExponent: 384 +minexponent: -383 + +addx1400 add 0 1.23456789012345 -> 1.23456789012345 +addx1401 add 0 1.23456789012345E-1 -> 0.123456789012345 +addx1402 add 0 1.23456789012345E-2 -> 0.0123456789012345 +addx1403 add 0 1.23456789012345E-3 -> 0.00123456789012345 +addx1404 add 0 1.23456789012345E-4 -> 0.000123456789012345 +addx1405 add 0 1.23456789012345E-5 -> 0.0000123456789012345 +addx1406 add 0 1.23456789012345E-6 -> 0.00000123456789012345 +addx1407 add 0 1.23456789012345E-7 -> 1.23456789012345E-7 +addx1408 add 0 1.23456789012345E-8 -> 1.23456789012345E-8 +addx1409 add 0 1.23456789012345E-9 -> 1.23456789012345E-9 +addx1410 add 0 1.23456789012345E-10 -> 1.23456789012345E-10 +addx1411 add 0 1.23456789012345E-11 -> 1.23456789012345E-11 +addx1412 add 0 1.23456789012345E-12 -> 1.23456789012345E-12 +addx1413 add 0 1.23456789012345E-13 -> 1.23456789012345E-13 +addx1414 add 0 1.23456789012345E-14 -> 1.23456789012345E-14 +addx1415 add 0 1.23456789012345E-15 -> 1.23456789012345E-15 +addx1416 add 0 1.23456789012345E-16 -> 1.23456789012345E-16 +addx1417 add 0 1.23456789012345E-17 -> 1.23456789012345E-17 +addx1418 add 0 1.23456789012345E-18 -> 1.23456789012345E-18 +addx1419 add 0 1.23456789012345E-19 -> 1.23456789012345E-19 + +-- same, precision 16.. +precision: 16 +addx1420 add 0 1.123456789012345 -> 1.123456789012345 +addx1421 add 0 1.123456789012345E-1 -> 0.1123456789012345 +addx1422 add 0 1.123456789012345E-2 -> 0.01123456789012345 +addx1423 add 0 1.123456789012345E-3 -> 0.001123456789012345 +addx1424 add 0 1.123456789012345E-4 -> 0.0001123456789012345 +addx1425 add 0 1.123456789012345E-5 -> 0.00001123456789012345 +addx1426 add 0 1.123456789012345E-6 -> 0.000001123456789012345 +addx1427 add 0 1.123456789012345E-7 -> 1.123456789012345E-7 +addx1428 add 0 1.123456789012345E-8 -> 1.123456789012345E-8 +addx1429 add 0 1.123456789012345E-9 -> 1.123456789012345E-9 +addx1430 add 0 1.123456789012345E-10 -> 1.123456789012345E-10 +addx1431 add 0 1.123456789012345E-11 -> 1.123456789012345E-11 +addx1432 add 0 1.123456789012345E-12 -> 1.123456789012345E-12 +addx1433 add 0 1.123456789012345E-13 -> 1.123456789012345E-13 +addx1434 add 0 1.123456789012345E-14 -> 1.123456789012345E-14 +addx1435 add 0 1.123456789012345E-15 -> 1.123456789012345E-15 +addx1436 add 0 1.123456789012345E-16 -> 1.123456789012345E-16 +addx1437 add 0 1.123456789012345E-17 -> 1.123456789012345E-17 +addx1438 add 0 1.123456789012345E-18 -> 1.123456789012345E-18 +addx1439 add 0 1.123456789012345E-19 -> 1.123456789012345E-19 + +-- same, reversed 0 +addx1440 add 1.123456789012345 0 -> 1.123456789012345 +addx1441 add 1.123456789012345E-1 0 -> 0.1123456789012345 +addx1442 add 1.123456789012345E-2 0 -> 0.01123456789012345 +addx1443 add 1.123456789012345E-3 0 -> 0.001123456789012345 +addx1444 add 1.123456789012345E-4 0 -> 0.0001123456789012345 +addx1445 add 1.123456789012345E-5 0 -> 0.00001123456789012345 +addx1446 add 1.123456789012345E-6 0 -> 0.000001123456789012345 +addx1447 add 1.123456789012345E-7 0 -> 1.123456789012345E-7 +addx1448 add 1.123456789012345E-8 0 -> 1.123456789012345E-8 +addx1449 add 1.123456789012345E-9 0 -> 1.123456789012345E-9 +addx1450 add 1.123456789012345E-10 0 -> 1.123456789012345E-10 +addx1451 add 1.123456789012345E-11 0 -> 1.123456789012345E-11 +addx1452 add 1.123456789012345E-12 0 -> 1.123456789012345E-12 +addx1453 add 1.123456789012345E-13 0 -> 1.123456789012345E-13 +addx1454 add 1.123456789012345E-14 0 -> 1.123456789012345E-14 +addx1455 add 1.123456789012345E-15 0 -> 1.123456789012345E-15 +addx1456 add 1.123456789012345E-16 0 -> 1.123456789012345E-16 +addx1457 add 1.123456789012345E-17 0 -> 1.123456789012345E-17 +addx1458 add 1.123456789012345E-18 0 -> 1.123456789012345E-18 +addx1459 add 1.123456789012345E-19 0 -> 1.123456789012345E-19 + +-- same, Es on the 0 +addx1460 add 1.123456789012345 0E-0 -> 1.123456789012345 +addx1461 add 1.123456789012345 0E-1 -> 1.123456789012345 +addx1462 add 1.123456789012345 0E-2 -> 1.123456789012345 +addx1463 add 1.123456789012345 0E-3 -> 1.123456789012345 +addx1464 add 1.123456789012345 0E-4 -> 1.123456789012345 +addx1465 add 1.123456789012345 0E-5 -> 1.123456789012345 +addx1466 add 1.123456789012345 0E-6 -> 1.123456789012345 +addx1467 add 1.123456789012345 0E-7 -> 1.123456789012345 +addx1468 add 1.123456789012345 0E-8 -> 1.123456789012345 +addx1469 add 1.123456789012345 0E-9 -> 1.123456789012345 +addx1470 add 1.123456789012345 0E-10 -> 1.123456789012345 +addx1471 add 1.123456789012345 0E-11 -> 1.123456789012345 +addx1472 add 1.123456789012345 0E-12 -> 1.123456789012345 +addx1473 add 1.123456789012345 0E-13 -> 1.123456789012345 +addx1474 add 1.123456789012345 0E-14 -> 1.123456789012345 +addx1475 add 1.123456789012345 0E-15 -> 1.123456789012345 +-- next four flag Rounded because the 0 extends the result +addx1476 add 1.123456789012345 0E-16 -> 1.123456789012345 Rounded +addx1477 add 1.123456789012345 0E-17 -> 1.123456789012345 Rounded +addx1478 add 1.123456789012345 0E-18 -> 1.123456789012345 Rounded +addx1479 add 1.123456789012345 0E-19 -> 1.123456789012345 Rounded + +-- sum of two opposite-sign operands is exactly 0 and floor => -0 +precision: 16 +maxExponent: 384 +minexponent: -383 + +rounding: half_up +-- exact zeros from zeros +addx1500 add 0 0E-19 -> 0E-19 +addx1501 add -0 0E-19 -> 0E-19 +addx1502 add 0 -0E-19 -> 0E-19 +addx1503 add -0 -0E-19 -> -0E-19 +addx1504 add 0E-400 0E-19 -> 0E-398 Clamped +addx1505 add -0E-400 0E-19 -> 0E-398 Clamped +addx1506 add 0E-400 -0E-19 -> 0E-398 Clamped +addx1507 add -0E-400 -0E-19 -> -0E-398 Clamped +-- inexact zeros +addx1511 add 1E-401 1E-400 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +addx1512 add -1E-401 1E-400 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +addx1513 add 1E-401 -1E-400 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped +addx1514 add -1E-401 -1E-400 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped +-- some exact zeros from non-zeros +addx1515 add 1E-401 1E-401 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +addx1516 add -1E-401 1E-401 -> 0E-398 Clamped +addx1517 add 1E-401 -1E-401 -> 0E-398 Clamped +addx1518 add -1E-401 -1E-401 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped + +rounding: half_down +-- exact zeros from zeros +addx1520 add 0 0E-19 -> 0E-19 +addx1521 add -0 0E-19 -> 0E-19 +addx1522 add 0 -0E-19 -> 0E-19 +addx1523 add -0 -0E-19 -> -0E-19 +addx1524 add 0E-400 0E-19 -> 0E-398 Clamped +addx1525 add -0E-400 0E-19 -> 0E-398 Clamped +addx1526 add 0E-400 -0E-19 -> 0E-398 Clamped +addx1527 add -0E-400 -0E-19 -> -0E-398 Clamped +-- inexact zeros +addx1531 add 1E-401 1E-400 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +addx1532 add -1E-401 1E-400 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +addx1533 add 1E-401 -1E-400 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped +addx1534 add -1E-401 -1E-400 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped +-- some exact zeros from non-zeros +addx1535 add 1E-401 1E-401 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +addx1536 add -1E-401 1E-401 -> 0E-398 Clamped +addx1537 add 1E-401 -1E-401 -> 0E-398 Clamped +addx1538 add -1E-401 -1E-401 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped + +rounding: half_even +-- exact zeros from zeros +addx1540 add 0 0E-19 -> 0E-19 +addx1541 add -0 0E-19 -> 0E-19 +addx1542 add 0 -0E-19 -> 0E-19 +addx1543 add -0 -0E-19 -> -0E-19 +addx1544 add 0E-400 0E-19 -> 0E-398 Clamped +addx1545 add -0E-400 0E-19 -> 0E-398 Clamped +addx1546 add 0E-400 -0E-19 -> 0E-398 Clamped +addx1547 add -0E-400 -0E-19 -> -0E-398 Clamped +-- inexact zeros +addx1551 add 1E-401 1E-400 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +addx1552 add -1E-401 1E-400 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +addx1553 add 1E-401 -1E-400 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped +addx1554 add -1E-401 -1E-400 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped +-- some exact zeros from non-zeros +addx1555 add 1E-401 1E-401 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +addx1556 add -1E-401 1E-401 -> 0E-398 Clamped +addx1557 add 1E-401 -1E-401 -> 0E-398 Clamped +addx1558 add -1E-401 -1E-401 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped + +rounding: up +-- exact zeros from zeros +addx1560 add 0 0E-19 -> 0E-19 +addx1561 add -0 0E-19 -> 0E-19 +addx1562 add 0 -0E-19 -> 0E-19 +addx1563 add -0 -0E-19 -> -0E-19 +addx1564 add 0E-400 0E-19 -> 0E-398 Clamped +addx1565 add -0E-400 0E-19 -> 0E-398 Clamped +addx1566 add 0E-400 -0E-19 -> 0E-398 Clamped +addx1567 add -0E-400 -0E-19 -> -0E-398 Clamped +-- inexact zeros +addx1571 add 1E-401 1E-400 -> 1E-398 Subnormal Inexact Rounded Underflow +addx1572 add -1E-401 1E-400 -> 1E-398 Subnormal Inexact Rounded Underflow +addx1573 add 1E-401 -1E-400 -> -1E-398 Subnormal Inexact Rounded Underflow +addx1574 add -1E-401 -1E-400 -> -1E-398 Subnormal Inexact Rounded Underflow +-- some exact zeros from non-zeros +addx1575 add 1E-401 1E-401 -> 1E-398 Subnormal Inexact Rounded Underflow +addx1576 add -1E-401 1E-401 -> 0E-398 Clamped +addx1577 add 1E-401 -1E-401 -> 0E-398 Clamped +addx1578 add -1E-401 -1E-401 -> -1E-398 Subnormal Inexact Rounded Underflow + +rounding: down +-- exact zeros from zeros +addx1580 add 0 0E-19 -> 0E-19 +addx1581 add -0 0E-19 -> 0E-19 +addx1582 add 0 -0E-19 -> 0E-19 +addx1583 add -0 -0E-19 -> -0E-19 +addx1584 add 0E-400 0E-19 -> 0E-398 Clamped +addx1585 add -0E-400 0E-19 -> 0E-398 Clamped +addx1586 add 0E-400 -0E-19 -> 0E-398 Clamped +addx1587 add -0E-400 -0E-19 -> -0E-398 Clamped +-- inexact zeros +addx1591 add 1E-401 1E-400 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +addx1592 add -1E-401 1E-400 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +addx1593 add 1E-401 -1E-400 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped +addx1594 add -1E-401 -1E-400 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped +-- some exact zeros from non-zeros +addx1595 add 1E-401 1E-401 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +addx1596 add -1E-401 1E-401 -> 0E-398 Clamped +addx1597 add 1E-401 -1E-401 -> 0E-398 Clamped +addx1598 add -1E-401 -1E-401 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped + +rounding: ceiling +-- exact zeros from zeros +addx1600 add 0 0E-19 -> 0E-19 +addx1601 add -0 0E-19 -> 0E-19 +addx1602 add 0 -0E-19 -> 0E-19 +addx1603 add -0 -0E-19 -> -0E-19 +addx1604 add 0E-400 0E-19 -> 0E-398 Clamped +addx1605 add -0E-400 0E-19 -> 0E-398 Clamped +addx1606 add 0E-400 -0E-19 -> 0E-398 Clamped +addx1607 add -0E-400 -0E-19 -> -0E-398 Clamped +-- inexact zeros +addx1611 add 1E-401 1E-400 -> 1E-398 Subnormal Inexact Rounded Underflow +addx1612 add -1E-401 1E-400 -> 1E-398 Subnormal Inexact Rounded Underflow +addx1613 add 1E-401 -1E-400 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped +addx1614 add -1E-401 -1E-400 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped +-- some exact zeros from non-zeros +addx1615 add 1E-401 1E-401 -> 1E-398 Subnormal Inexact Rounded Underflow +addx1616 add -1E-401 1E-401 -> 0E-398 Clamped +addx1617 add 1E-401 -1E-401 -> 0E-398 Clamped +addx1618 add -1E-401 -1E-401 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped + +-- and the extra-special ugly case; unusual minuses marked by -- * +rounding: floor +-- exact zeros from zeros +addx1620 add 0 0E-19 -> 0E-19 +addx1621 add -0 0E-19 -> -0E-19 -- * +addx1622 add 0 -0E-19 -> -0E-19 -- * +addx1623 add -0 -0E-19 -> -0E-19 +addx1624 add 0E-400 0E-19 -> 0E-398 Clamped +addx1625 add -0E-400 0E-19 -> -0E-398 Clamped -- * +addx1626 add 0E-400 -0E-19 -> -0E-398 Clamped -- * +addx1627 add -0E-400 -0E-19 -> -0E-398 Clamped +-- inexact zeros +addx1631 add 1E-401 1E-400 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +addx1632 add -1E-401 1E-400 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +addx1633 add 1E-401 -1E-400 -> -1E-398 Subnormal Inexact Rounded Underflow +addx1634 add -1E-401 -1E-400 -> -1E-398 Subnormal Inexact Rounded Underflow +-- some exact zeros from non-zeros +addx1635 add 1E-401 1E-401 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +addx1636 add -1E-401 1E-401 -> -0E-398 Clamped -- * +addx1637 add 1E-401 -1E-401 -> -0E-398 Clamped -- * +addx1638 add -1E-401 -1E-401 -> -1E-398 Subnormal Inexact Rounded Underflow + +-- BigDecimal problem testcases 2006.01.23 +precision: 16 +maxExponent: 384 +minexponent: -383 + +rounding: down +precision: 7 +addx1651 add 10001E+2 -2E+1 -> 1.00008E+6 +precision: 6 +addx1652 add 10001E+2 -2E+1 -> 1.00008E+6 +precision: 5 +addx1653 add 10001E+2 -2E+1 -> 1.0000E+6 Inexact Rounded +precision: 4 +addx1654 add 10001E+2 -2E+1 -> 1.000E+6 Inexact Rounded +precision: 3 +addx1655 add 10001E+2 -2E+1 -> 1.00E+6 Inexact Rounded +precision: 2 +addx1656 add 10001E+2 -2E+1 -> 1.0E+6 Inexact Rounded +precision: 1 +addx1657 add 10001E+2 -2E+1 -> 1E+6 Inexact Rounded + +rounding: half_even +precision: 7 +addx1661 add 10001E+2 -2E+1 -> 1.00008E+6 +precision: 6 +addx1662 add 10001E+2 -2E+1 -> 1.00008E+6 +precision: 5 +addx1663 add 10001E+2 -2E+1 -> 1.0001E+6 Inexact Rounded +precision: 4 +addx1664 add 10001E+2 -2E+1 -> 1.000E+6 Inexact Rounded +precision: 3 +addx1665 add 10001E+2 -2E+1 -> 1.00E+6 Inexact Rounded +precision: 2 +addx1666 add 10001E+2 -2E+1 -> 1.0E+6 Inexact Rounded +precision: 1 +addx1667 add 10001E+2 -2E+1 -> 1E+6 Inexact Rounded + +rounding: up +precision: 7 +addx1671 add 10001E+2 -2E+1 -> 1.00008E+6 +precision: 6 +addx1672 add 10001E+2 -2E+1 -> 1.00008E+6 +precision: 5 +addx1673 add 10001E+2 -2E+1 -> 1.0001E+6 Inexact Rounded +precision: 4 +addx1674 add 10001E+2 -2E+1 -> 1.001E+6 Inexact Rounded +precision: 3 +addx1675 add 10001E+2 -2E+1 -> 1.01E+6 Inexact Rounded +precision: 2 +addx1676 add 10001E+2 -2E+1 -> 1.1E+6 Inexact Rounded +precision: 1 +addx1677 add 10001E+2 -2E+1 -> 2E+6 Inexact Rounded + +precision: 34 +rounding: half_up +maxExponent: 6144 +minExponent: -6143 +-- Examples from SQL proposal (Krishna Kulkarni) +addx1701 add 130E-2 120E-2 -> 2.50 +addx1702 add 130E-2 12E-1 -> 2.50 +addx1703 add 130E-2 1E0 -> 2.30 +addx1704 add 1E2 1E4 -> 1.01E+4 +addx1705 subtract 130E-2 120E-2 -> 0.10 +addx1706 subtract 130E-2 12E-1 -> 0.10 +addx1707 subtract 130E-2 1E0 -> 0.30 +addx1708 subtract 1E2 1E4 -> -9.9E+3 + +------------------------------------------------------------------------ +-- Same as above, using decimal64 default parameters -- +------------------------------------------------------------------------ +precision: 16 +rounding: half_even +maxExponent: 384 +minexponent: -383 + +-- [first group are 'quick confidence check'] +addx6001 add 1 1 -> 2 +addx6002 add 2 3 -> 5 +addx6003 add '5.75' '3.3' -> 9.05 +addx6004 add '5' '-3' -> 2 +addx6005 add '-5' '-3' -> -8 +addx6006 add '-7' '2.5' -> -4.5 +addx6007 add '0.7' '0.3' -> 1.0 +addx6008 add '1.25' '1.25' -> 2.50 +addx6009 add '1.23456789' '1.00000000' -> '2.23456789' +addx6010 add '1.23456789' '1.00000011' -> '2.23456800' + +addx6011 add '0.44444444444444444' '0.55555555555555555' -> '1.000000000000000' Inexact Rounded +addx6012 add '0.44444444444444440' '0.55555555555555555' -> '1.000000000000000' Inexact Rounded +addx6013 add '0.44444444444444444' '0.55555555555555550' -> '0.9999999999999999' Inexact Rounded +addx6014 add '0.444444444444444449' '0' -> '0.4444444444444444' Inexact Rounded +addx6015 add '0.4444444444444444499' '0' -> '0.4444444444444444' Inexact Rounded +addx6016 add '0.44444444444444444999' '0' -> '0.4444444444444444' Inexact Rounded +addx6017 add '0.44444444444444445000' '0' -> '0.4444444444444444' Inexact Rounded +addx6018 add '0.44444444444444445001' '0' -> '0.4444444444444445' Inexact Rounded +addx6019 add '0.4444444444444444501' '0' -> '0.4444444444444445' Inexact Rounded +addx6020 add '0.444444444444444451' '0' -> '0.4444444444444445' Inexact Rounded + +addx6021 add 0 1 -> 1 +addx6022 add 1 1 -> 2 +addx6023 add 2 1 -> 3 +addx6024 add 3 1 -> 4 +addx6025 add 4 1 -> 5 +addx6026 add 5 1 -> 6 +addx6027 add 6 1 -> 7 +addx6028 add 7 1 -> 8 +addx6029 add 8 1 -> 9 +addx6030 add 9 1 -> 10 + +-- some carrying effects +addx6031 add '0.9998' '0.0000' -> '0.9998' +addx6032 add '0.9998' '0.0001' -> '0.9999' +addx6033 add '0.9998' '0.0002' -> '1.0000' +addx6034 add '0.9998' '0.0003' -> '1.0001' + +addx6035 add '70' '10000e+16' -> '1.000000000000000E+20' Inexact Rounded +addx6036 add '700' '10000e+16' -> '1.000000000000000E+20' Inexact Rounded +addx6037 add '7000' '10000e+16' -> '1.000000000000000E+20' Inexact Rounded +addx6038 add '70000' '10000e+16' -> '1.000000000000001E+20' Inexact Rounded +addx6039 add '700000' '10000e+16' -> '1.000000000000007E+20' Rounded + +-- symmetry: +addx6040 add '10000e+16' '70' -> '1.000000000000000E+20' Inexact Rounded +addx6041 add '10000e+16' '700' -> '1.000000000000000E+20' Inexact Rounded +addx6042 add '10000e+16' '7000' -> '1.000000000000000E+20' Inexact Rounded +addx6044 add '10000e+16' '70000' -> '1.000000000000001E+20' Inexact Rounded +addx6045 add '10000e+16' '700000' -> '1.000000000000007E+20' Rounded + +addx6046 add '10000e+9' '7' -> '10000000000007' +addx6047 add '10000e+9' '70' -> '10000000000070' +addx6048 add '10000e+9' '700' -> '10000000000700' +addx6049 add '10000e+9' '7000' -> '10000000007000' +addx6050 add '10000e+9' '70000' -> '10000000070000' +addx6051 add '10000e+9' '700000' -> '10000000700000' + +-- examples from decarith +addx6053 add '12' '7.00' -> '19.00' +addx6054 add '1.3' '-1.07' -> '0.23' +addx6055 add '1.3' '-1.30' -> '0.00' +addx6056 add '1.3' '-2.07' -> '-0.77' +addx6057 add '1E+2' '1E+4' -> '1.01E+4' + +-- from above +addx6060 add 1 '0.1' -> '1.1' +addx6061 add 1 '0.01' -> '1.01' +addx6062 add 1 '0.001' -> '1.001' +addx6063 add 1 '0.0001' -> '1.0001' +addx6064 add 1 '0.00001' -> '1.00001' +addx6065 add 1 '0.000001' -> '1.000001' +addx6066 add 1 '0.0000001' -> '1.0000001' +addx6067 add 1 '0.00000001' -> '1.00000001' + +-- cancellation to integer +addx6068 add 99999999999999123456789 -99999999999999E+9 -> 123456789 +-- similar from FMA fun +addx6069 add "-1234567890123455.234567890123454" "1234567890123456" -> 0.765432109876546 + +-- some funny zeros [in case of bad signum] +addx6070 add 1 0 -> 1 +addx6071 add 1 0. -> 1 +addx6072 add 1 .0 -> 1.0 +addx6073 add 1 0.0 -> 1.0 +addx6074 add 1 0.00 -> 1.00 +addx6075 add 0 1 -> 1 +addx6076 add 0. 1 -> 1 +addx6077 add .0 1 -> 1.0 +addx6078 add 0.0 1 -> 1.0 +addx6079 add 0.00 1 -> 1.00 + +-- some carries +addx6080 add 9999999999999998 1 -> 9999999999999999 +addx6081 add 9999999999999999 1 -> 1.000000000000000E+16 Rounded +addx6082 add 999999999999999 1 -> 1000000000000000 +addx6083 add 9999999999999 1 -> 10000000000000 +addx6084 add 99999999999 1 -> 100000000000 +addx6085 add 999999999 1 -> 1000000000 +addx6086 add 9999999 1 -> 10000000 +addx6087 add 99999 1 -> 100000 +addx6088 add 999 1 -> 1000 +addx6089 add 9 1 -> 10 + + +-- more LHS swaps +addx6090 add '-56267E-10' 0 -> '-0.0000056267' +addx6091 add '-56267E-6' 0 -> '-0.056267' +addx6092 add '-56267E-5' 0 -> '-0.56267' +addx6093 add '-56267E-4' 0 -> '-5.6267' +addx6094 add '-56267E-3' 0 -> '-56.267' +addx6095 add '-56267E-2' 0 -> '-562.67' +addx6096 add '-56267E-1' 0 -> '-5626.7' +addx6097 add '-56267E-0' 0 -> '-56267' +addx6098 add '-5E-10' 0 -> '-5E-10' +addx6099 add '-5E-7' 0 -> '-5E-7' +addx6100 add '-5E-6' 0 -> '-0.000005' +addx6101 add '-5E-5' 0 -> '-0.00005' +addx6102 add '-5E-4' 0 -> '-0.0005' +addx6103 add '-5E-1' 0 -> '-0.5' +addx6104 add '-5E0' 0 -> '-5' +addx6105 add '-5E1' 0 -> '-50' +addx6106 add '-5E5' 0 -> '-500000' +addx6107 add '-5E15' 0 -> '-5000000000000000' +addx6108 add '-5E16' 0 -> '-5.000000000000000E+16' Rounded +addx6109 add '-5E17' 0 -> '-5.000000000000000E+17' Rounded +addx6110 add '-5E18' 0 -> '-5.000000000000000E+18' Rounded +addx6111 add '-5E100' 0 -> '-5.000000000000000E+100' Rounded + +-- more RHS swaps +addx6113 add 0 '-56267E-10' -> '-0.0000056267' +addx6114 add 0 '-56267E-6' -> '-0.056267' +addx6116 add 0 '-56267E-5' -> '-0.56267' +addx6117 add 0 '-56267E-4' -> '-5.6267' +addx6119 add 0 '-56267E-3' -> '-56.267' +addx6120 add 0 '-56267E-2' -> '-562.67' +addx6121 add 0 '-56267E-1' -> '-5626.7' +addx6122 add 0 '-56267E-0' -> '-56267' +addx6123 add 0 '-5E-10' -> '-5E-10' +addx6124 add 0 '-5E-7' -> '-5E-7' +addx6125 add 0 '-5E-6' -> '-0.000005' +addx6126 add 0 '-5E-5' -> '-0.00005' +addx6127 add 0 '-5E-4' -> '-0.0005' +addx6128 add 0 '-5E-1' -> '-0.5' +addx6129 add 0 '-5E0' -> '-5' +addx6130 add 0 '-5E1' -> '-50' +addx6131 add 0 '-5E5' -> '-500000' +addx6132 add 0 '-5E15' -> '-5000000000000000' +addx6133 add 0 '-5E16' -> '-5.000000000000000E+16' Rounded +addx6134 add 0 '-5E17' -> '-5.000000000000000E+17' Rounded +addx6135 add 0 '-5E18' -> '-5.000000000000000E+18' Rounded +addx6136 add 0 '-5E100' -> '-5.000000000000000E+100' Rounded + +-- related +addx6137 add 1 '0E-19' -> '1.000000000000000' Rounded +addx6138 add -1 '0E-19' -> '-1.000000000000000' Rounded +addx6139 add '0E-19' 1 -> '1.000000000000000' Rounded +addx6140 add '0E-19' -1 -> '-1.000000000000000' Rounded +addx6141 add 1E+11 0.0000 -> '100000000000.0000' +addx6142 add 1E+11 0.00000 -> '100000000000.0000' Rounded +addx6143 add 0.000 1E+12 -> '1000000000000.000' +addx6144 add 0.0000 1E+12 -> '1000000000000.000' Rounded + +-- [some of the next group are really constructor tests] +addx6146 add '00.0' 0 -> '0.0' +addx6147 add '0.00' 0 -> '0.00' +addx6148 add 0 '0.00' -> '0.00' +addx6149 add 0 '00.0' -> '0.0' +addx6150 add '00.0' '0.00' -> '0.00' +addx6151 add '0.00' '00.0' -> '0.00' +addx6152 add '3' '.3' -> '3.3' +addx6153 add '3.' '.3' -> '3.3' +addx6154 add '3.0' '.3' -> '3.3' +addx6155 add '3.00' '.3' -> '3.30' +addx6156 add '3' '3' -> '6' +addx6157 add '3' '+3' -> '6' +addx6158 add '3' '-3' -> '0' +addx6159 add '0.3' '-0.3' -> '0.0' +addx6160 add '0.03' '-0.03' -> '0.00' + +-- try borderline precision, with carries, etc. +addx6161 add '1E+13' '-1' -> '9999999999999' +addx6162 add '1E+13' '1.11' -> '10000000000001.11' +addx6163 add '1.11' '1E+13' -> '10000000000001.11' +addx6164 add '-1' '1E+13' -> '9999999999999' +addx6165 add '7E+13' '-1' -> '69999999999999' +addx6166 add '7E+13' '1.11' -> '70000000000001.11' +addx6167 add '1.11' '7E+13' -> '70000000000001.11' +addx6168 add '-1' '7E+13' -> '69999999999999' + +-- 1234567890123456 1234567890123456 1 234567890123456 +addx6170 add '0.4444444444444444' '0.5555555555555563' -> '1.000000000000001' Inexact Rounded +addx6171 add '0.4444444444444444' '0.5555555555555562' -> '1.000000000000001' Inexact Rounded +addx6172 add '0.4444444444444444' '0.5555555555555561' -> '1.000000000000000' Inexact Rounded +addx6173 add '0.4444444444444444' '0.5555555555555560' -> '1.000000000000000' Inexact Rounded +addx6174 add '0.4444444444444444' '0.5555555555555559' -> '1.000000000000000' Inexact Rounded +addx6175 add '0.4444444444444444' '0.5555555555555558' -> '1.000000000000000' Inexact Rounded +addx6176 add '0.4444444444444444' '0.5555555555555557' -> '1.000000000000000' Inexact Rounded +addx6177 add '0.4444444444444444' '0.5555555555555556' -> '1.000000000000000' Rounded +addx6178 add '0.4444444444444444' '0.5555555555555555' -> '0.9999999999999999' +addx6179 add '0.4444444444444444' '0.5555555555555554' -> '0.9999999999999998' +addx6180 add '0.4444444444444444' '0.5555555555555553' -> '0.9999999999999997' +addx6181 add '0.4444444444444444' '0.5555555555555552' -> '0.9999999999999996' +addx6182 add '0.4444444444444444' '0.5555555555555551' -> '0.9999999999999995' +addx6183 add '0.4444444444444444' '0.5555555555555550' -> '0.9999999999999994' + +-- and some more, including residue effects and different roundings +rounding: half_up +addx6200 add '6543210123456789' 0 -> '6543210123456789' +addx6201 add '6543210123456789' 0.000000001 -> '6543210123456789' Inexact Rounded +addx6202 add '6543210123456789' 0.000001 -> '6543210123456789' Inexact Rounded +addx6203 add '6543210123456789' 0.1 -> '6543210123456789' Inexact Rounded +addx6204 add '6543210123456789' 0.4 -> '6543210123456789' Inexact Rounded +addx6205 add '6543210123456789' 0.49 -> '6543210123456789' Inexact Rounded +addx6206 add '6543210123456789' 0.499999 -> '6543210123456789' Inexact Rounded +addx6207 add '6543210123456789' 0.499999999 -> '6543210123456789' Inexact Rounded +addx6208 add '6543210123456789' 0.5 -> '6543210123456790' Inexact Rounded +addx6209 add '6543210123456789' 0.500000001 -> '6543210123456790' Inexact Rounded +addx6210 add '6543210123456789' 0.500001 -> '6543210123456790' Inexact Rounded +addx6211 add '6543210123456789' 0.51 -> '6543210123456790' Inexact Rounded +addx6212 add '6543210123456789' 0.6 -> '6543210123456790' Inexact Rounded +addx6213 add '6543210123456789' 0.9 -> '6543210123456790' Inexact Rounded +addx6214 add '6543210123456789' 0.99999 -> '6543210123456790' Inexact Rounded +addx6215 add '6543210123456789' 0.999999999 -> '6543210123456790' Inexact Rounded +addx6216 add '6543210123456789' 1 -> '6543210123456790' +addx6217 add '6543210123456789' 1.000000001 -> '6543210123456790' Inexact Rounded +addx6218 add '6543210123456789' 1.00001 -> '6543210123456790' Inexact Rounded +addx6219 add '6543210123456789' 1.1 -> '6543210123456790' Inexact Rounded + +rounding: half_even +addx6220 add '6543210123456789' 0 -> '6543210123456789' +addx6221 add '6543210123456789' 0.000000001 -> '6543210123456789' Inexact Rounded +addx6222 add '6543210123456789' 0.000001 -> '6543210123456789' Inexact Rounded +addx6223 add '6543210123456789' 0.1 -> '6543210123456789' Inexact Rounded +addx6224 add '6543210123456789' 0.4 -> '6543210123456789' Inexact Rounded +addx6225 add '6543210123456789' 0.49 -> '6543210123456789' Inexact Rounded +addx6226 add '6543210123456789' 0.499999 -> '6543210123456789' Inexact Rounded +addx6227 add '6543210123456789' 0.499999999 -> '6543210123456789' Inexact Rounded +addx6228 add '6543210123456789' 0.5 -> '6543210123456790' Inexact Rounded +addx6229 add '6543210123456789' 0.500000001 -> '6543210123456790' Inexact Rounded +addx6230 add '6543210123456789' 0.500001 -> '6543210123456790' Inexact Rounded +addx6231 add '6543210123456789' 0.51 -> '6543210123456790' Inexact Rounded +addx6232 add '6543210123456789' 0.6 -> '6543210123456790' Inexact Rounded +addx6233 add '6543210123456789' 0.9 -> '6543210123456790' Inexact Rounded +addx6234 add '6543210123456789' 0.99999 -> '6543210123456790' Inexact Rounded +addx6235 add '6543210123456789' 0.999999999 -> '6543210123456790' Inexact Rounded +addx6236 add '6543210123456789' 1 -> '6543210123456790' +addx6237 add '6543210123456789' 1.00000001 -> '6543210123456790' Inexact Rounded +addx6238 add '6543210123456789' 1.00001 -> '6543210123456790' Inexact Rounded +addx6239 add '6543210123456789' 1.1 -> '6543210123456790' Inexact Rounded +-- critical few with even bottom digit... +addx6240 add '6543210123456788' 0.499999999 -> '6543210123456788' Inexact Rounded +addx6241 add '6543210123456788' 0.5 -> '6543210123456788' Inexact Rounded +addx6242 add '6543210123456788' 0.500000001 -> '6543210123456789' Inexact Rounded + +rounding: down +addx6250 add '6543210123456789' 0 -> '6543210123456789' +addx6251 add '6543210123456789' 0.000000001 -> '6543210123456789' Inexact Rounded +addx6252 add '6543210123456789' 0.000001 -> '6543210123456789' Inexact Rounded +addx6253 add '6543210123456789' 0.1 -> '6543210123456789' Inexact Rounded +addx6254 add '6543210123456789' 0.4 -> '6543210123456789' Inexact Rounded +addx6255 add '6543210123456789' 0.49 -> '6543210123456789' Inexact Rounded +addx6256 add '6543210123456789' 0.499999 -> '6543210123456789' Inexact Rounded +addx6257 add '6543210123456789' 0.499999999 -> '6543210123456789' Inexact Rounded +addx6258 add '6543210123456789' 0.5 -> '6543210123456789' Inexact Rounded +addx6259 add '6543210123456789' 0.500000001 -> '6543210123456789' Inexact Rounded +addx6260 add '6543210123456789' 0.500001 -> '6543210123456789' Inexact Rounded +addx6261 add '6543210123456789' 0.51 -> '6543210123456789' Inexact Rounded +addx6262 add '6543210123456789' 0.6 -> '6543210123456789' Inexact Rounded +addx6263 add '6543210123456789' 0.9 -> '6543210123456789' Inexact Rounded +addx6264 add '6543210123456789' 0.99999 -> '6543210123456789' Inexact Rounded +addx6265 add '6543210123456789' 0.999999999 -> '6543210123456789' Inexact Rounded +addx6266 add '6543210123456789' 1 -> '6543210123456790' +addx6267 add '6543210123456789' 1.00000001 -> '6543210123456790' Inexact Rounded +addx6268 add '6543210123456789' 1.00001 -> '6543210123456790' Inexact Rounded +addx6269 add '6543210123456789' 1.1 -> '6543210123456790' Inexact Rounded + +-- 1 in last place tests +rounding: half_even +addx6301 add -1 1 -> 0 +addx6302 add 0 1 -> 1 +addx6303 add 1 1 -> 2 +addx6304 add 12 1 -> 13 +addx6305 add 98 1 -> 99 +addx6306 add 99 1 -> 100 +addx6307 add 100 1 -> 101 +addx6308 add 101 1 -> 102 +addx6309 add -1 -1 -> -2 +addx6310 add 0 -1 -> -1 +addx6311 add 1 -1 -> 0 +addx6312 add 12 -1 -> 11 +addx6313 add 98 -1 -> 97 +addx6314 add 99 -1 -> 98 +addx6315 add 100 -1 -> 99 +addx6316 add 101 -1 -> 100 + +addx6321 add -0.01 0.01 -> 0.00 +addx6322 add 0.00 0.01 -> 0.01 +addx6323 add 0.01 0.01 -> 0.02 +addx6324 add 0.12 0.01 -> 0.13 +addx6325 add 0.98 0.01 -> 0.99 +addx6326 add 0.99 0.01 -> 1.00 +addx6327 add 1.00 0.01 -> 1.01 +addx6328 add 1.01 0.01 -> 1.02 +addx6329 add -0.01 -0.01 -> -0.02 +addx6330 add 0.00 -0.01 -> -0.01 +addx6331 add 0.01 -0.01 -> 0.00 +addx6332 add 0.12 -0.01 -> 0.11 +addx6333 add 0.98 -0.01 -> 0.97 +addx6334 add 0.99 -0.01 -> 0.98 +addx6335 add 1.00 -0.01 -> 0.99 +addx6336 add 1.01 -0.01 -> 1.00 + +-- some more cases where adding 0 affects the coefficient +addx6340 add 1E+3 0 -> 1000 +addx6341 add 1E+15 0 -> 1000000000000000 +addx6342 add 1E+16 0 -> 1.000000000000000E+16 Rounded +addx6343 add 1E+17 0 -> 1.000000000000000E+17 Rounded +-- which simply follow from these cases ... +addx6344 add 1E+3 1 -> 1001 +addx6345 add 1E+15 1 -> 1000000000000001 +addx6346 add 1E+16 1 -> 1.000000000000000E+16 Inexact Rounded +addx6347 add 1E+17 1 -> 1.000000000000000E+17 Inexact Rounded +addx6348 add 1E+3 7 -> 1007 +addx6349 add 1E+15 7 -> 1000000000000007 +addx6350 add 1E+16 7 -> 1.000000000000001E+16 Inexact Rounded +addx6351 add 1E+17 7 -> 1.000000000000000E+17 Inexact Rounded + +-- tryzeros cases +addx6361 add 0E+50 10000E+1 -> 1.0000E+5 +addx6362 add 10000E+1 0E-50 -> 100000.0000000000 Rounded +addx6363 add 10000E+1 10000E-50 -> 100000.0000000000 Rounded Inexact +addx6364 add 12.34 0e-398 -> 12.34000000000000 Rounded + +-- ulp replacement tests +addx6400 add 1 77e-14 -> 1.00000000000077 +addx6401 add 1 77e-15 -> 1.000000000000077 +addx6402 add 1 77e-16 -> 1.000000000000008 Inexact Rounded +addx6403 add 1 77e-17 -> 1.000000000000001 Inexact Rounded +addx6404 add 1 77e-18 -> 1.000000000000000 Inexact Rounded +addx6405 add 1 77e-19 -> 1.000000000000000 Inexact Rounded +addx6406 add 1 77e-99 -> 1.000000000000000 Inexact Rounded + +addx6410 add 10 77e-14 -> 10.00000000000077 +addx6411 add 10 77e-15 -> 10.00000000000008 Inexact Rounded +addx6412 add 10 77e-16 -> 10.00000000000001 Inexact Rounded +addx6413 add 10 77e-17 -> 10.00000000000000 Inexact Rounded +addx6414 add 10 77e-18 -> 10.00000000000000 Inexact Rounded +addx6415 add 10 77e-19 -> 10.00000000000000 Inexact Rounded +addx6416 add 10 77e-99 -> 10.00000000000000 Inexact Rounded + +addx6420 add 77e-14 1 -> 1.00000000000077 +addx6421 add 77e-15 1 -> 1.000000000000077 +addx6422 add 77e-16 1 -> 1.000000000000008 Inexact Rounded +addx6423 add 77e-17 1 -> 1.000000000000001 Inexact Rounded +addx6424 add 77e-18 1 -> 1.000000000000000 Inexact Rounded +addx6425 add 77e-19 1 -> 1.000000000000000 Inexact Rounded +addx6426 add 77e-99 1 -> 1.000000000000000 Inexact Rounded + +addx6430 add 77e-14 10 -> 10.00000000000077 +addx6431 add 77e-15 10 -> 10.00000000000008 Inexact Rounded +addx6432 add 77e-16 10 -> 10.00000000000001 Inexact Rounded +addx6433 add 77e-17 10 -> 10.00000000000000 Inexact Rounded +addx6434 add 77e-18 10 -> 10.00000000000000 Inexact Rounded +addx6435 add 77e-19 10 -> 10.00000000000000 Inexact Rounded +addx6436 add 77e-99 10 -> 10.00000000000000 Inexact Rounded + +-- negative ulps +addx6440 add 1 -77e-14 -> 0.99999999999923 +addx6441 add 1 -77e-15 -> 0.999999999999923 +addx6442 add 1 -77e-16 -> 0.9999999999999923 +addx6443 add 1 -77e-17 -> 0.9999999999999992 Inexact Rounded +addx6444 add 1 -77e-18 -> 0.9999999999999999 Inexact Rounded +addx6445 add 1 -77e-19 -> 1.000000000000000 Inexact Rounded +addx6446 add 1 -77e-99 -> 1.000000000000000 Inexact Rounded + +addx6450 add 10 -77e-14 -> 9.99999999999923 +addx6451 add 10 -77e-15 -> 9.999999999999923 +addx6452 add 10 -77e-16 -> 9.999999999999992 Inexact Rounded +addx6453 add 10 -77e-17 -> 9.999999999999999 Inexact Rounded +addx6454 add 10 -77e-18 -> 10.00000000000000 Inexact Rounded +addx6455 add 10 -77e-19 -> 10.00000000000000 Inexact Rounded +addx6456 add 10 -77e-99 -> 10.00000000000000 Inexact Rounded + +addx6460 add -77e-14 1 -> 0.99999999999923 +addx6461 add -77e-15 1 -> 0.999999999999923 +addx6462 add -77e-16 1 -> 0.9999999999999923 +addx6463 add -77e-17 1 -> 0.9999999999999992 Inexact Rounded +addx6464 add -77e-18 1 -> 0.9999999999999999 Inexact Rounded +addx6465 add -77e-19 1 -> 1.000000000000000 Inexact Rounded +addx6466 add -77e-99 1 -> 1.000000000000000 Inexact Rounded + +addx6470 add -77e-14 10 -> 9.99999999999923 +addx6471 add -77e-15 10 -> 9.999999999999923 +addx6472 add -77e-16 10 -> 9.999999999999992 Inexact Rounded +addx6473 add -77e-17 10 -> 9.999999999999999 Inexact Rounded +addx6474 add -77e-18 10 -> 10.00000000000000 Inexact Rounded +addx6475 add -77e-19 10 -> 10.00000000000000 Inexact Rounded +addx6476 add -77e-99 10 -> 10.00000000000000 Inexact Rounded + +-- negative ulps +addx6480 add -1 77e-14 -> -0.99999999999923 +addx6481 add -1 77e-15 -> -0.999999999999923 +addx6482 add -1 77e-16 -> -0.9999999999999923 +addx6483 add -1 77e-17 -> -0.9999999999999992 Inexact Rounded +addx6484 add -1 77e-18 -> -0.9999999999999999 Inexact Rounded +addx6485 add -1 77e-19 -> -1.000000000000000 Inexact Rounded +addx6486 add -1 77e-99 -> -1.000000000000000 Inexact Rounded + +addx6490 add -10 77e-14 -> -9.99999999999923 +addx6491 add -10 77e-15 -> -9.999999999999923 +addx6492 add -10 77e-16 -> -9.999999999999992 Inexact Rounded +addx6493 add -10 77e-17 -> -9.999999999999999 Inexact Rounded +addx6494 add -10 77e-18 -> -10.00000000000000 Inexact Rounded +addx6495 add -10 77e-19 -> -10.00000000000000 Inexact Rounded +addx6496 add -10 77e-99 -> -10.00000000000000 Inexact Rounded + +addx6500 add 77e-14 -1 -> -0.99999999999923 +addx6501 add 77e-15 -1 -> -0.999999999999923 +addx6502 add 77e-16 -1 -> -0.9999999999999923 +addx6503 add 77e-17 -1 -> -0.9999999999999992 Inexact Rounded +addx6504 add 77e-18 -1 -> -0.9999999999999999 Inexact Rounded +addx6505 add 77e-19 -1 -> -1.000000000000000 Inexact Rounded +addx6506 add 77e-99 -1 -> -1.000000000000000 Inexact Rounded + +addx6510 add 77e-14 -10 -> -9.99999999999923 +addx6511 add 77e-15 -10 -> -9.999999999999923 +addx6512 add 77e-16 -10 -> -9.999999999999992 Inexact Rounded +addx6513 add 77e-17 -10 -> -9.999999999999999 Inexact Rounded +addx6514 add 77e-18 -10 -> -10.00000000000000 Inexact Rounded +addx6515 add 77e-19 -10 -> -10.00000000000000 Inexact Rounded +addx6516 add 77e-99 -10 -> -10.00000000000000 Inexact Rounded -addx1160 add 100E-105 -1e-101 -> -0E-101 Subnormal Inexact Rounded Underflow -addx1161 add 100E-105 -1e-201 -> 0E-101 Subnormal Inexact Rounded Underflow +-- long operands +addx6521 add 101234562345678000 0 -> 1.012345623456780E+17 Rounded +addx6522 add 0 101234562345678000 -> 1.012345623456780E+17 Rounded +addx6523 add 10123456234567800 0 -> 1.012345623456780E+16 Rounded +addx6524 add 0 10123456234567800 -> 1.012345623456780E+16 Rounded +addx6525 add 10123456234567890 0 -> 1.012345623456789E+16 Rounded +addx6526 add 0 10123456234567890 -> 1.012345623456789E+16 Rounded +addx6527 add 10123456234567891 0 -> 1.012345623456789E+16 Inexact Rounded +addx6528 add 0 10123456234567891 -> 1.012345623456789E+16 Inexact Rounded +addx6529 add 101234562345678901 0 -> 1.012345623456789E+17 Inexact Rounded +addx6530 add 0 101234562345678901 -> 1.012345623456789E+17 Inexact Rounded +addx6531 add 10123456234567896 0 -> 1.012345623456790E+16 Inexact Rounded +addx6532 add 0 10123456234567896 -> 1.012345623456790E+16 Inexact Rounded + +-- verify a query +rounding: down +addx6561 add 1e-398 9.000000000000000E+384 -> 9.000000000000000E+384 Inexact Rounded +addx6562 add 0 9.000000000000000E+384 -> 9.000000000000000E+384 Rounded +-- and using decimal64 bounds... +rounding: down +addx6563 add 1e-388 9.000000000000000E+374 -> 9.000000000000000E+374 Inexact Rounded +addx6564 add 0 9.000000000000000E+374 -> 9.000000000000000E+374 Rounded + +-- more zeros, etc. +rounding: half_even + +addx6701 add 5.00 1.00E-3 -> 5.00100 +addx6702 add 00.00 0.000 -> 0.000 +addx6703 add 00.00 0E-3 -> 0.000 +addx6704 add 0E-3 00.00 -> 0.000 + +addx6710 add 0E+3 00.00 -> 0.00 +addx6711 add 0E+3 00.0 -> 0.0 +addx6712 add 0E+3 00. -> 0 +addx6713 add 0E+3 00.E+1 -> 0E+1 +addx6714 add 0E+3 00.E+2 -> 0E+2 +addx6715 add 0E+3 00.E+3 -> 0E+3 +addx6716 add 0E+3 00.E+4 -> 0E+3 +addx6717 add 0E+3 00.E+5 -> 0E+3 +addx6718 add 0E+3 -00.0 -> 0.0 +addx6719 add 0E+3 -00. -> 0 +addx6731 add 0E+3 -00.E+1 -> 0E+1 + +addx6720 add 00.00 0E+3 -> 0.00 +addx6721 add 00.0 0E+3 -> 0.0 +addx6722 add 00. 0E+3 -> 0 +addx6723 add 00.E+1 0E+3 -> 0E+1 +addx6724 add 00.E+2 0E+3 -> 0E+2 +addx6725 add 00.E+3 0E+3 -> 0E+3 +addx6726 add 00.E+4 0E+3 -> 0E+3 +addx6727 add 00.E+5 0E+3 -> 0E+3 +addx6728 add -00.00 0E+3 -> 0.00 +addx6729 add -00.0 0E+3 -> 0.0 +addx6730 add -00. 0E+3 -> 0 + +addx6732 add 0 0 -> 0 +addx6733 add 0 -0 -> 0 +addx6734 add -0 0 -> 0 +addx6735 add -0 -0 -> -0 -- IEEE 854 special case + +addx6736 add 1 -1 -> 0 +addx6737 add -1 -1 -> -2 +addx6738 add 1 1 -> 2 +addx6739 add -1 1 -> 0 + +addx6741 add 0 -1 -> -1 +addx6742 add -0 -1 -> -1 +addx6743 add 0 1 -> 1 +addx6744 add -0 1 -> 1 +addx6745 add -1 0 -> -1 +addx6746 add -1 -0 -> -1 +addx6747 add 1 0 -> 1 +addx6748 add 1 -0 -> 1 + +addx6751 add 0.0 -1 -> -1.0 +addx6752 add -0.0 -1 -> -1.0 +addx6753 add 0.0 1 -> 1.0 +addx6754 add -0.0 1 -> 1.0 +addx6755 add -1.0 0 -> -1.0 +addx6756 add -1.0 -0 -> -1.0 +addx6757 add 1.0 0 -> 1.0 +addx6758 add 1.0 -0 -> 1.0 + +addx6761 add 0 -1.0 -> -1.0 +addx6762 add -0 -1.0 -> -1.0 +addx6763 add 0 1.0 -> 1.0 +addx6764 add -0 1.0 -> 1.0 +addx6765 add -1 0.0 -> -1.0 +addx6766 add -1 -0.0 -> -1.0 +addx6767 add 1 0.0 -> 1.0 +addx6768 add 1 -0.0 -> 1.0 + +addx6771 add 0.0 -1.0 -> -1.0 +addx6772 add -0.0 -1.0 -> -1.0 +addx6773 add 0.0 1.0 -> 1.0 +addx6774 add -0.0 1.0 -> 1.0 +addx6775 add -1.0 0.0 -> -1.0 +addx6776 add -1.0 -0.0 -> -1.0 +addx6777 add 1.0 0.0 -> 1.0 +addx6778 add 1.0 -0.0 -> 1.0 + +-- Specials +addx6780 add -Inf -Inf -> -Infinity +addx6781 add -Inf -1000 -> -Infinity +addx6782 add -Inf -1 -> -Infinity +addx6783 add -Inf -0 -> -Infinity +addx6784 add -Inf 0 -> -Infinity +addx6785 add -Inf 1 -> -Infinity +addx6786 add -Inf 1000 -> -Infinity +addx6787 add -1000 -Inf -> -Infinity +addx6788 add -Inf -Inf -> -Infinity +addx6789 add -1 -Inf -> -Infinity +addx6790 add -0 -Inf -> -Infinity +addx6791 add 0 -Inf -> -Infinity +addx6792 add 1 -Inf -> -Infinity +addx6793 add 1000 -Inf -> -Infinity +addx6794 add Inf -Inf -> NaN Invalid_operation + +addx6800 add Inf -Inf -> NaN Invalid_operation +addx6801 add Inf -1000 -> Infinity +addx6802 add Inf -1 -> Infinity +addx6803 add Inf -0 -> Infinity +addx6804 add Inf 0 -> Infinity +addx6805 add Inf 1 -> Infinity +addx6806 add Inf 1000 -> Infinity +addx6807 add Inf Inf -> Infinity +addx6808 add -1000 Inf -> Infinity +addx6809 add -Inf Inf -> NaN Invalid_operation +addx6810 add -1 Inf -> Infinity +addx6811 add -0 Inf -> Infinity +addx6812 add 0 Inf -> Infinity +addx6813 add 1 Inf -> Infinity +addx6814 add 1000 Inf -> Infinity +addx6815 add Inf Inf -> Infinity + +addx6821 add NaN -Inf -> NaN +addx6822 add NaN -1000 -> NaN +addx6823 add NaN -1 -> NaN +addx6824 add NaN -0 -> NaN +addx6825 add NaN 0 -> NaN +addx6826 add NaN 1 -> NaN +addx6827 add NaN 1000 -> NaN +addx6828 add NaN Inf -> NaN +addx6829 add NaN NaN -> NaN +addx6830 add -Inf NaN -> NaN +addx6831 add -1000 NaN -> NaN +addx6832 add -1 NaN -> NaN +addx6833 add -0 NaN -> NaN +addx6834 add 0 NaN -> NaN +addx6835 add 1 NaN -> NaN +addx6836 add 1000 NaN -> NaN +addx6837 add Inf NaN -> NaN + +addx6841 add sNaN -Inf -> NaN Invalid_operation +addx6842 add sNaN -1000 -> NaN Invalid_operation +addx6843 add sNaN -1 -> NaN Invalid_operation +addx6844 add sNaN -0 -> NaN Invalid_operation +addx6845 add sNaN 0 -> NaN Invalid_operation +addx6846 add sNaN 1 -> NaN Invalid_operation +addx6847 add sNaN 1000 -> NaN Invalid_operation +addx6848 add sNaN NaN -> NaN Invalid_operation +addx6849 add sNaN sNaN -> NaN Invalid_operation +addx6850 add NaN sNaN -> NaN Invalid_operation +addx6851 add -Inf sNaN -> NaN Invalid_operation +addx6852 add -1000 sNaN -> NaN Invalid_operation +addx6853 add -1 sNaN -> NaN Invalid_operation +addx6854 add -0 sNaN -> NaN Invalid_operation +addx6855 add 0 sNaN -> NaN Invalid_operation +addx6856 add 1 sNaN -> NaN Invalid_operation +addx6857 add 1000 sNaN -> NaN Invalid_operation +addx6858 add Inf sNaN -> NaN Invalid_operation +addx6859 add NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +addx6861 add NaN1 -Inf -> NaN1 +addx6862 add +NaN2 -1000 -> NaN2 +addx6863 add NaN3 1000 -> NaN3 +addx6864 add NaN4 Inf -> NaN4 +addx6865 add NaN5 +NaN6 -> NaN5 +addx6866 add -Inf NaN7 -> NaN7 +addx6867 add -1000 NaN8 -> NaN8 +addx6868 add 1000 NaN9 -> NaN9 +addx6869 add Inf +NaN10 -> NaN10 +addx6871 add sNaN11 -Inf -> NaN11 Invalid_operation +addx6872 add sNaN12 -1000 -> NaN12 Invalid_operation +addx6873 add sNaN13 1000 -> NaN13 Invalid_operation +addx6874 add sNaN14 NaN17 -> NaN14 Invalid_operation +addx6875 add sNaN15 sNaN18 -> NaN15 Invalid_operation +addx6876 add NaN16 sNaN19 -> NaN19 Invalid_operation +addx6877 add -Inf +sNaN20 -> NaN20 Invalid_operation +addx6878 add -1000 sNaN21 -> NaN21 Invalid_operation +addx6879 add 1000 sNaN22 -> NaN22 Invalid_operation +addx6880 add Inf sNaN23 -> NaN23 Invalid_operation +addx6881 add +NaN25 +sNaN24 -> NaN24 Invalid_operation +addx6882 add -NaN26 NaN28 -> -NaN26 +addx6883 add -sNaN27 sNaN29 -> -NaN27 Invalid_operation +addx6884 add 1000 -NaN30 -> -NaN30 +addx6885 add 1000 -sNaN31 -> -NaN31 Invalid_operation + +-- now the case where we can get underflow but the result is normal +-- [note this can't happen if the operands are also bounded, as we +-- cannot represent 1E-399, for example] + +addx6571 add 1E-383 0 -> 1E-383 +addx6572 add 1E-384 0 -> 1E-384 Subnormal +addx6573 add 1E-383 1E-384 -> 1.1E-383 +addx6574 subtract 1E-383 1E-384 -> 9E-384 Subnormal + +-- Here we explore the boundary of rounding a subnormal to Nmin +addx6575 subtract 1E-383 1E-398 -> 9.99999999999999E-384 Subnormal +addx6576 subtract 1E-383 1E-398 -> 9.99999999999999E-384 Subnormal +addx6577 subtract 1E-383 1E-399 -> 1.000000000000000E-383 Underflow Inexact Subnormal Rounded +addx6578 subtract 1E-383 1E-400 -> 1.000000000000000E-383 Underflow Inexact Subnormal Rounded +addx6579 subtract 1E-383 1E-401 -> 1.000000000000000E-383 Underflow Inexact Subnormal Rounded +addx6580 subtract 1E-383 1E-402 -> 1.000000000000000E-383 Underflow Inexact Subnormal Rounded + +-- check overflow edge case +-- 1234567890123456 +addx6972 apply 9.999999999999999E+384 -> 9.999999999999999E+384 +addx6973 add 9.999999999999999E+384 1 -> 9.999999999999999E+384 Inexact Rounded +addx6974 add 9999999999999999E+369 1 -> 9.999999999999999E+384 Inexact Rounded +addx6975 add 9999999999999999E+369 1E+369 -> Infinity Overflow Inexact Rounded +addx6976 add 9999999999999999E+369 9E+368 -> Infinity Overflow Inexact Rounded +addx6977 add 9999999999999999E+369 8E+368 -> Infinity Overflow Inexact Rounded +addx6978 add 9999999999999999E+369 7E+368 -> Infinity Overflow Inexact Rounded +addx6979 add 9999999999999999E+369 6E+368 -> Infinity Overflow Inexact Rounded +addx6980 add 9999999999999999E+369 5E+368 -> Infinity Overflow Inexact Rounded +addx6981 add 9999999999999999E+369 4E+368 -> 9.999999999999999E+384 Inexact Rounded +addx6982 add 9999999999999999E+369 3E+368 -> 9.999999999999999E+384 Inexact Rounded +addx6983 add 9999999999999999E+369 2E+368 -> 9.999999999999999E+384 Inexact Rounded +addx6984 add 9999999999999999E+369 1E+368 -> 9.999999999999999E+384 Inexact Rounded + +addx6985 apply -9.999999999999999E+384 -> -9.999999999999999E+384 +addx6986 add -9.999999999999999E+384 -1 -> -9.999999999999999E+384 Inexact Rounded +addx6987 add -9999999999999999E+369 -1 -> -9.999999999999999E+384 Inexact Rounded +addx6988 add -9999999999999999E+369 -1E+369 -> -Infinity Overflow Inexact Rounded +addx6989 add -9999999999999999E+369 -9E+368 -> -Infinity Overflow Inexact Rounded +addx6990 add -9999999999999999E+369 -8E+368 -> -Infinity Overflow Inexact Rounded +addx6991 add -9999999999999999E+369 -7E+368 -> -Infinity Overflow Inexact Rounded +addx6992 add -9999999999999999E+369 -6E+368 -> -Infinity Overflow Inexact Rounded +addx6993 add -9999999999999999E+369 -5E+368 -> -Infinity Overflow Inexact Rounded +addx6994 add -9999999999999999E+369 -4E+368 -> -9.999999999999999E+384 Inexact Rounded +addx6995 add -9999999999999999E+369 -3E+368 -> -9.999999999999999E+384 Inexact Rounded +addx6996 add -9999999999999999E+369 -2E+368 -> -9.999999999999999E+384 Inexact Rounded +addx6997 add -9999999999999999E+369 -1E+368 -> -9.999999999999999E+384 Inexact Rounded + +-- And for round down full and subnormal results +rounding: down +addx61100 add 1e+2 -1e-383 -> 99.99999999999999 Rounded Inexact +addx61101 add 1e+1 -1e-383 -> 9.999999999999999 Rounded Inexact +addx61103 add +1 -1e-383 -> 0.9999999999999999 Rounded Inexact +addx61104 add 1e-1 -1e-383 -> 0.09999999999999999 Rounded Inexact +addx61105 add 1e-2 -1e-383 -> 0.009999999999999999 Rounded Inexact +addx61106 add 1e-3 -1e-383 -> 0.0009999999999999999 Rounded Inexact +addx61107 add 1e-4 -1e-383 -> 0.00009999999999999999 Rounded Inexact +addx61108 add 1e-5 -1e-383 -> 0.000009999999999999999 Rounded Inexact +addx61109 add 1e-6 -1e-383 -> 9.999999999999999E-7 Rounded Inexact + +rounding: ceiling +addx61110 add -1e+2 +1e-383 -> -99.99999999999999 Rounded Inexact +addx61111 add -1e+1 +1e-383 -> -9.999999999999999 Rounded Inexact +addx61113 add -1 +1e-383 -> -0.9999999999999999 Rounded Inexact +addx61114 add -1e-1 +1e-383 -> -0.09999999999999999 Rounded Inexact +addx61115 add -1e-2 +1e-383 -> -0.009999999999999999 Rounded Inexact +addx61116 add -1e-3 +1e-383 -> -0.0009999999999999999 Rounded Inexact +addx61117 add -1e-4 +1e-383 -> -0.00009999999999999999 Rounded Inexact +addx61118 add -1e-5 +1e-383 -> -0.000009999999999999999 Rounded Inexact +addx61119 add -1e-6 +1e-383 -> -9.999999999999999E-7 Rounded Inexact + +-- tests based on Gunnar Degnbol's edge case +rounding: half_even + +addx61300 add 1E16 -0.5 -> 1.000000000000000E+16 Inexact Rounded +addx61310 add 1E16 -0.51 -> 9999999999999999 Inexact Rounded +addx61311 add 1E16 -0.501 -> 9999999999999999 Inexact Rounded +addx61312 add 1E16 -0.5001 -> 9999999999999999 Inexact Rounded +addx61313 add 1E16 -0.50001 -> 9999999999999999 Inexact Rounded +addx61314 add 1E16 -0.500001 -> 9999999999999999 Inexact Rounded +addx61315 add 1E16 -0.5000001 -> 9999999999999999 Inexact Rounded +addx61316 add 1E16 -0.50000001 -> 9999999999999999 Inexact Rounded +addx61317 add 1E16 -0.500000001 -> 9999999999999999 Inexact Rounded +addx61318 add 1E16 -0.5000000001 -> 9999999999999999 Inexact Rounded +addx61319 add 1E16 -0.50000000001 -> 9999999999999999 Inexact Rounded +addx61320 add 1E16 -0.500000000001 -> 9999999999999999 Inexact Rounded +addx61321 add 1E16 -0.5000000000001 -> 9999999999999999 Inexact Rounded +addx61322 add 1E16 -0.50000000000001 -> 9999999999999999 Inexact Rounded +addx61323 add 1E16 -0.500000000000001 -> 9999999999999999 Inexact Rounded +addx61324 add 1E16 -0.5000000000000001 -> 9999999999999999 Inexact Rounded +addx61325 add 1E16 -0.5000000000000000 -> 1.000000000000000E+16 Inexact Rounded +addx61326 add 1E16 -0.500000000000000 -> 1.000000000000000E+16 Inexact Rounded +addx61327 add 1E16 -0.50000000000000 -> 1.000000000000000E+16 Inexact Rounded +addx61328 add 1E16 -0.5000000000000 -> 1.000000000000000E+16 Inexact Rounded +addx61329 add 1E16 -0.500000000000 -> 1.000000000000000E+16 Inexact Rounded +addx61330 add 1E16 -0.50000000000 -> 1.000000000000000E+16 Inexact Rounded +addx61331 add 1E16 -0.5000000000 -> 1.000000000000000E+16 Inexact Rounded +addx61332 add 1E16 -0.500000000 -> 1.000000000000000E+16 Inexact Rounded +addx61333 add 1E16 -0.50000000 -> 1.000000000000000E+16 Inexact Rounded +addx61334 add 1E16 -0.5000000 -> 1.000000000000000E+16 Inexact Rounded +addx61335 add 1E16 -0.500000 -> 1.000000000000000E+16 Inexact Rounded +addx61336 add 1E16 -0.50000 -> 1.000000000000000E+16 Inexact Rounded +addx61337 add 1E16 -0.5000 -> 1.000000000000000E+16 Inexact Rounded +addx61338 add 1E16 -0.500 -> 1.000000000000000E+16 Inexact Rounded +addx61339 add 1E16 -0.50 -> 1.000000000000000E+16 Inexact Rounded + +addx61340 add 1E16 -5000000.000010001 -> 9999999995000000 Inexact Rounded +addx61341 add 1E16 -5000000.000000001 -> 9999999995000000 Inexact Rounded + +addx61349 add 9999999999999999 0.4 -> 9999999999999999 Inexact Rounded +addx61350 add 9999999999999999 0.49 -> 9999999999999999 Inexact Rounded +addx61351 add 9999999999999999 0.499 -> 9999999999999999 Inexact Rounded +addx61352 add 9999999999999999 0.4999 -> 9999999999999999 Inexact Rounded +addx61353 add 9999999999999999 0.49999 -> 9999999999999999 Inexact Rounded +addx61354 add 9999999999999999 0.499999 -> 9999999999999999 Inexact Rounded +addx61355 add 9999999999999999 0.4999999 -> 9999999999999999 Inexact Rounded +addx61356 add 9999999999999999 0.49999999 -> 9999999999999999 Inexact Rounded +addx61357 add 9999999999999999 0.499999999 -> 9999999999999999 Inexact Rounded +addx61358 add 9999999999999999 0.4999999999 -> 9999999999999999 Inexact Rounded +addx61359 add 9999999999999999 0.49999999999 -> 9999999999999999 Inexact Rounded +addx61360 add 9999999999999999 0.499999999999 -> 9999999999999999 Inexact Rounded +addx61361 add 9999999999999999 0.4999999999999 -> 9999999999999999 Inexact Rounded +addx61362 add 9999999999999999 0.49999999999999 -> 9999999999999999 Inexact Rounded +addx61363 add 9999999999999999 0.499999999999999 -> 9999999999999999 Inexact Rounded +addx61364 add 9999999999999999 0.4999999999999999 -> 9999999999999999 Inexact Rounded +addx61365 add 9999999999999999 0.5000000000000000 -> 1.000000000000000E+16 Inexact Rounded +addx61367 add 9999999999999999 0.500000000000000 -> 1.000000000000000E+16 Inexact Rounded +addx61368 add 9999999999999999 0.50000000000000 -> 1.000000000000000E+16 Inexact Rounded +addx61369 add 9999999999999999 0.5000000000000 -> 1.000000000000000E+16 Inexact Rounded +addx61370 add 9999999999999999 0.500000000000 -> 1.000000000000000E+16 Inexact Rounded +addx61371 add 9999999999999999 0.50000000000 -> 1.000000000000000E+16 Inexact Rounded +addx61372 add 9999999999999999 0.5000000000 -> 1.000000000000000E+16 Inexact Rounded +addx61373 add 9999999999999999 0.500000000 -> 1.000000000000000E+16 Inexact Rounded +addx61374 add 9999999999999999 0.50000000 -> 1.000000000000000E+16 Inexact Rounded +addx61375 add 9999999999999999 0.5000000 -> 1.000000000000000E+16 Inexact Rounded +addx61376 add 9999999999999999 0.500000 -> 1.000000000000000E+16 Inexact Rounded +addx61377 add 9999999999999999 0.50000 -> 1.000000000000000E+16 Inexact Rounded +addx61378 add 9999999999999999 0.5000 -> 1.000000000000000E+16 Inexact Rounded +addx61379 add 9999999999999999 0.500 -> 1.000000000000000E+16 Inexact Rounded +addx61380 add 9999999999999999 0.50 -> 1.000000000000000E+16 Inexact Rounded +addx61381 add 9999999999999999 0.5 -> 1.000000000000000E+16 Inexact Rounded +addx61382 add 9999999999999999 0.5000000000000001 -> 1.000000000000000E+16 Inexact Rounded +addx61383 add 9999999999999999 0.500000000000001 -> 1.000000000000000E+16 Inexact Rounded +addx61384 add 9999999999999999 0.50000000000001 -> 1.000000000000000E+16 Inexact Rounded +addx61385 add 9999999999999999 0.5000000000001 -> 1.000000000000000E+16 Inexact Rounded +addx61386 add 9999999999999999 0.500000000001 -> 1.000000000000000E+16 Inexact Rounded +addx61387 add 9999999999999999 0.50000000001 -> 1.000000000000000E+16 Inexact Rounded +addx61388 add 9999999999999999 0.5000000001 -> 1.000000000000000E+16 Inexact Rounded +addx61389 add 9999999999999999 0.500000001 -> 1.000000000000000E+16 Inexact Rounded +addx61390 add 9999999999999999 0.50000001 -> 1.000000000000000E+16 Inexact Rounded +addx61391 add 9999999999999999 0.5000001 -> 1.000000000000000E+16 Inexact Rounded +addx61392 add 9999999999999999 0.500001 -> 1.000000000000000E+16 Inexact Rounded +addx61393 add 9999999999999999 0.50001 -> 1.000000000000000E+16 Inexact Rounded +addx61394 add 9999999999999999 0.5001 -> 1.000000000000000E+16 Inexact Rounded +addx61395 add 9999999999999999 0.501 -> 1.000000000000000E+16 Inexact Rounded +addx61396 add 9999999999999999 0.51 -> 1.000000000000000E+16 Inexact Rounded + +-- More GD edge cases, where difference between the unadjusted +-- exponents is larger than the maximum precision and one side is 0 +addx61420 add 0 1.123456789012345 -> 1.123456789012345 +addx61421 add 0 1.123456789012345E-1 -> 0.1123456789012345 +addx61422 add 0 1.123456789012345E-2 -> 0.01123456789012345 +addx61423 add 0 1.123456789012345E-3 -> 0.001123456789012345 +addx61424 add 0 1.123456789012345E-4 -> 0.0001123456789012345 +addx61425 add 0 1.123456789012345E-5 -> 0.00001123456789012345 +addx61426 add 0 1.123456789012345E-6 -> 0.000001123456789012345 +addx61427 add 0 1.123456789012345E-7 -> 1.123456789012345E-7 +addx61428 add 0 1.123456789012345E-8 -> 1.123456789012345E-8 +addx61429 add 0 1.123456789012345E-9 -> 1.123456789012345E-9 +addx61430 add 0 1.123456789012345E-10 -> 1.123456789012345E-10 +addx61431 add 0 1.123456789012345E-11 -> 1.123456789012345E-11 +addx61432 add 0 1.123456789012345E-12 -> 1.123456789012345E-12 +addx61433 add 0 1.123456789012345E-13 -> 1.123456789012345E-13 +addx61434 add 0 1.123456789012345E-14 -> 1.123456789012345E-14 +addx61435 add 0 1.123456789012345E-15 -> 1.123456789012345E-15 +addx61436 add 0 1.123456789012345E-16 -> 1.123456789012345E-16 +addx61437 add 0 1.123456789012345E-17 -> 1.123456789012345E-17 +addx61438 add 0 1.123456789012345E-18 -> 1.123456789012345E-18 +addx61439 add 0 1.123456789012345E-19 -> 1.123456789012345E-19 + +-- same, reversed 0 +addx61440 add 1.123456789012345 0 -> 1.123456789012345 +addx61441 add 1.123456789012345E-1 0 -> 0.1123456789012345 +addx61442 add 1.123456789012345E-2 0 -> 0.01123456789012345 +addx61443 add 1.123456789012345E-3 0 -> 0.001123456789012345 +addx61444 add 1.123456789012345E-4 0 -> 0.0001123456789012345 +addx61445 add 1.123456789012345E-5 0 -> 0.00001123456789012345 +addx61446 add 1.123456789012345E-6 0 -> 0.000001123456789012345 +addx61447 add 1.123456789012345E-7 0 -> 1.123456789012345E-7 +addx61448 add 1.123456789012345E-8 0 -> 1.123456789012345E-8 +addx61449 add 1.123456789012345E-9 0 -> 1.123456789012345E-9 +addx61450 add 1.123456789012345E-10 0 -> 1.123456789012345E-10 +addx61451 add 1.123456789012345E-11 0 -> 1.123456789012345E-11 +addx61452 add 1.123456789012345E-12 0 -> 1.123456789012345E-12 +addx61453 add 1.123456789012345E-13 0 -> 1.123456789012345E-13 +addx61454 add 1.123456789012345E-14 0 -> 1.123456789012345E-14 +addx61455 add 1.123456789012345E-15 0 -> 1.123456789012345E-15 +addx61456 add 1.123456789012345E-16 0 -> 1.123456789012345E-16 +addx61457 add 1.123456789012345E-17 0 -> 1.123456789012345E-17 +addx61458 add 1.123456789012345E-18 0 -> 1.123456789012345E-18 +addx61459 add 1.123456789012345E-19 0 -> 1.123456789012345E-19 + +-- same, Es on the 0 +addx61460 add 1.123456789012345 0E-0 -> 1.123456789012345 +addx61461 add 1.123456789012345 0E-1 -> 1.123456789012345 +addx61462 add 1.123456789012345 0E-2 -> 1.123456789012345 +addx61463 add 1.123456789012345 0E-3 -> 1.123456789012345 +addx61464 add 1.123456789012345 0E-4 -> 1.123456789012345 +addx61465 add 1.123456789012345 0E-5 -> 1.123456789012345 +addx61466 add 1.123456789012345 0E-6 -> 1.123456789012345 +addx61467 add 1.123456789012345 0E-7 -> 1.123456789012345 +addx61468 add 1.123456789012345 0E-8 -> 1.123456789012345 +addx61469 add 1.123456789012345 0E-9 -> 1.123456789012345 +addx61470 add 1.123456789012345 0E-10 -> 1.123456789012345 +addx61471 add 1.123456789012345 0E-11 -> 1.123456789012345 +addx61472 add 1.123456789012345 0E-12 -> 1.123456789012345 +addx61473 add 1.123456789012345 0E-13 -> 1.123456789012345 +addx61474 add 1.123456789012345 0E-14 -> 1.123456789012345 +addx61475 add 1.123456789012345 0E-15 -> 1.123456789012345 +-- next four flag Rounded because the 0 extends the result +addx61476 add 1.123456789012345 0E-16 -> 1.123456789012345 Rounded +addx61477 add 1.123456789012345 0E-17 -> 1.123456789012345 Rounded +addx61478 add 1.123456789012345 0E-18 -> 1.123456789012345 Rounded +addx61479 add 1.123456789012345 0E-19 -> 1.123456789012345 Rounded + +-- sum of two opposite-sign operands is exactly 0 and floor => -0 +rounding: half_up +-- exact zeros from zeros +addx61500 add 0 0E-19 -> 0E-19 +addx61501 add -0 0E-19 -> 0E-19 +addx61502 add 0 -0E-19 -> 0E-19 +addx61503 add -0 -0E-19 -> -0E-19 +addx61504 add 0E-400 0E-19 -> 0E-398 Clamped +addx61505 add -0E-400 0E-19 -> 0E-398 Clamped +addx61506 add 0E-400 -0E-19 -> 0E-398 Clamped +addx61507 add -0E-400 -0E-19 -> -0E-398 Clamped +-- inexact zeros +addx61511 add 1E-401 1E-400 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +addx61512 add -1E-401 1E-400 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +addx61513 add 1E-401 -1E-400 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped +addx61514 add -1E-401 -1E-400 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped +-- some exact zeros from non-zeros +addx61515 add 1E-401 1E-401 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +addx61516 add -1E-401 1E-401 -> 0E-398 Clamped +addx61517 add 1E-401 -1E-401 -> 0E-398 Clamped +addx61518 add -1E-401 -1E-401 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped + +rounding: half_down +-- exact zeros from zeros +addx61520 add 0 0E-19 -> 0E-19 +addx61521 add -0 0E-19 -> 0E-19 +addx61522 add 0 -0E-19 -> 0E-19 +addx61523 add -0 -0E-19 -> -0E-19 +addx61524 add 0E-400 0E-19 -> 0E-398 Clamped +addx61525 add -0E-400 0E-19 -> 0E-398 Clamped +addx61526 add 0E-400 -0E-19 -> 0E-398 Clamped +addx61527 add -0E-400 -0E-19 -> -0E-398 Clamped +-- inexact zeros +addx61531 add 1E-401 1E-400 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +addx61532 add -1E-401 1E-400 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +addx61533 add 1E-401 -1E-400 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped +addx61534 add -1E-401 -1E-400 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped +-- some exact zeros from non-zeros +addx61535 add 1E-401 1E-401 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +addx61536 add -1E-401 1E-401 -> 0E-398 Clamped +addx61537 add 1E-401 -1E-401 -> 0E-398 Clamped +addx61538 add -1E-401 -1E-401 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped + +rounding: half_even +-- exact zeros from zeros +addx61540 add 0 0E-19 -> 0E-19 +addx61541 add -0 0E-19 -> 0E-19 +addx61542 add 0 -0E-19 -> 0E-19 +addx61543 add -0 -0E-19 -> -0E-19 +addx61544 add 0E-400 0E-19 -> 0E-398 Clamped +addx61545 add -0E-400 0E-19 -> 0E-398 Clamped +addx61546 add 0E-400 -0E-19 -> 0E-398 Clamped +addx61547 add -0E-400 -0E-19 -> -0E-398 Clamped +-- inexact zeros +addx61551 add 1E-401 1E-400 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +addx61552 add -1E-401 1E-400 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +addx61553 add 1E-401 -1E-400 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped +addx61554 add -1E-401 -1E-400 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped +-- some exact zeros from non-zeros +addx61555 add 1E-401 1E-401 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +addx61556 add -1E-401 1E-401 -> 0E-398 Clamped +addx61557 add 1E-401 -1E-401 -> 0E-398 Clamped +addx61558 add -1E-401 -1E-401 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped + +rounding: up +-- exact zeros from zeros +addx61560 add 0 0E-19 -> 0E-19 +addx61561 add -0 0E-19 -> 0E-19 +addx61562 add 0 -0E-19 -> 0E-19 +addx61563 add -0 -0E-19 -> -0E-19 +addx61564 add 0E-400 0E-19 -> 0E-398 Clamped +addx61565 add -0E-400 0E-19 -> 0E-398 Clamped +addx61566 add 0E-400 -0E-19 -> 0E-398 Clamped +addx61567 add -0E-400 -0E-19 -> -0E-398 Clamped +-- inexact zeros +addx61571 add 1E-401 1E-400 -> 1E-398 Subnormal Inexact Rounded Underflow +addx61572 add -1E-401 1E-400 -> 1E-398 Subnormal Inexact Rounded Underflow +addx61573 add 1E-401 -1E-400 -> -1E-398 Subnormal Inexact Rounded Underflow +addx61574 add -1E-401 -1E-400 -> -1E-398 Subnormal Inexact Rounded Underflow +-- some exact zeros from non-zeros +addx61575 add 1E-401 1E-401 -> 1E-398 Subnormal Inexact Rounded Underflow +addx61576 add -1E-401 1E-401 -> 0E-398 Clamped +addx61577 add 1E-401 -1E-401 -> 0E-398 Clamped +addx61578 add -1E-401 -1E-401 -> -1E-398 Subnormal Inexact Rounded Underflow + +rounding: down +-- exact zeros from zeros +addx61580 add 0 0E-19 -> 0E-19 +addx61581 add -0 0E-19 -> 0E-19 +addx61582 add 0 -0E-19 -> 0E-19 +addx61583 add -0 -0E-19 -> -0E-19 +addx61584 add 0E-400 0E-19 -> 0E-398 Clamped +addx61585 add -0E-400 0E-19 -> 0E-398 Clamped +addx61586 add 0E-400 -0E-19 -> 0E-398 Clamped +addx61587 add -0E-400 -0E-19 -> -0E-398 Clamped +-- inexact zeros +addx61591 add 1E-401 1E-400 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +addx61592 add -1E-401 1E-400 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +addx61593 add 1E-401 -1E-400 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped +addx61594 add -1E-401 -1E-400 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped +-- some exact zeros from non-zeros +addx61595 add 1E-401 1E-401 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +addx61596 add -1E-401 1E-401 -> 0E-398 Clamped +addx61597 add 1E-401 -1E-401 -> 0E-398 Clamped +addx61598 add -1E-401 -1E-401 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped + +rounding: ceiling +-- exact zeros from zeros +addx61600 add 0 0E-19 -> 0E-19 +addx61601 add -0 0E-19 -> 0E-19 +addx61602 add 0 -0E-19 -> 0E-19 +addx61603 add -0 -0E-19 -> -0E-19 +addx61604 add 0E-400 0E-19 -> 0E-398 Clamped +addx61605 add -0E-400 0E-19 -> 0E-398 Clamped +addx61606 add 0E-400 -0E-19 -> 0E-398 Clamped +addx61607 add -0E-400 -0E-19 -> -0E-398 Clamped +-- inexact zeros +addx61611 add 1E-401 1E-400 -> 1E-398 Subnormal Inexact Rounded Underflow +addx61612 add -1E-401 1E-400 -> 1E-398 Subnormal Inexact Rounded Underflow +addx61613 add 1E-401 -1E-400 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped +addx61614 add -1E-401 -1E-400 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped +-- some exact zeros from non-zeros +addx61615 add 1E-401 1E-401 -> 1E-398 Subnormal Inexact Rounded Underflow +addx61616 add -1E-401 1E-401 -> 0E-398 Clamped +addx61617 add 1E-401 -1E-401 -> 0E-398 Clamped +addx61618 add -1E-401 -1E-401 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped + +-- and the extra-special ugly case; unusual minuses marked by -- * +rounding: floor +-- exact zeros from zeros +addx61620 add 0 0E-19 -> 0E-19 +addx61621 add -0 0E-19 -> -0E-19 -- * +addx61622 add 0 -0E-19 -> -0E-19 -- * +addx61623 add -0 -0E-19 -> -0E-19 +addx61624 add 0E-400 0E-19 -> 0E-398 Clamped +addx61625 add -0E-400 0E-19 -> -0E-398 Clamped -- * +addx61626 add 0E-400 -0E-19 -> -0E-398 Clamped -- * +addx61627 add -0E-400 -0E-19 -> -0E-398 Clamped +-- inexact zeros +addx61631 add 1E-401 1E-400 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +addx61632 add -1E-401 1E-400 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +addx61633 add 1E-401 -1E-400 -> -1E-398 Subnormal Inexact Rounded Underflow +addx61634 add -1E-401 -1E-400 -> -1E-398 Subnormal Inexact Rounded Underflow +-- some exact zeros from non-zeros +addx61635 add 1E-401 1E-401 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +addx61636 add -1E-401 1E-401 -> -0E-398 Clamped -- * +addx61637 add 1E-401 -1E-401 -> -0E-398 Clamped -- * +addx61638 add -1E-401 -1E-401 -> -1E-398 Subnormal Inexact Rounded Underflow + +-- Examples from SQL proposal (Krishna Kulkarni) +addx61701 add 130E-2 120E-2 -> 2.50 +addx61702 add 130E-2 12E-1 -> 2.50 +addx61703 add 130E-2 1E0 -> 2.30 +addx61704 add 1E2 1E4 -> 1.01E+4 +addx61705 subtract 130E-2 120E-2 -> 0.10 +addx61706 subtract 130E-2 12E-1 -> 0.10 +addx61707 subtract 130E-2 1E0 -> 0.30 +addx61708 subtract 1E2 1E4 -> -9.9E+3 + +-- Gappy coefficients; check residue handling even with full coefficient gap +rounding: half_even + +addx62001 add 1234567890123456 1 -> 1234567890123457 +addx62002 add 1234567890123456 0.6 -> 1234567890123457 Inexact Rounded +addx62003 add 1234567890123456 0.06 -> 1234567890123456 Inexact Rounded +addx62004 add 1234567890123456 6E-3 -> 1234567890123456 Inexact Rounded +addx62005 add 1234567890123456 6E-4 -> 1234567890123456 Inexact Rounded +addx62006 add 1234567890123456 6E-5 -> 1234567890123456 Inexact Rounded +addx62007 add 1234567890123456 6E-6 -> 1234567890123456 Inexact Rounded +addx62008 add 1234567890123456 6E-7 -> 1234567890123456 Inexact Rounded +addx62009 add 1234567890123456 6E-8 -> 1234567890123456 Inexact Rounded +addx62010 add 1234567890123456 6E-9 -> 1234567890123456 Inexact Rounded +addx62011 add 1234567890123456 6E-10 -> 1234567890123456 Inexact Rounded +addx62012 add 1234567890123456 6E-11 -> 1234567890123456 Inexact Rounded +addx62013 add 1234567890123456 6E-12 -> 1234567890123456 Inexact Rounded +addx62014 add 1234567890123456 6E-13 -> 1234567890123456 Inexact Rounded +addx62015 add 1234567890123456 6E-14 -> 1234567890123456 Inexact Rounded +addx62016 add 1234567890123456 6E-15 -> 1234567890123456 Inexact Rounded +addx62017 add 1234567890123456 6E-16 -> 1234567890123456 Inexact Rounded +addx62018 add 1234567890123456 6E-17 -> 1234567890123456 Inexact Rounded +addx62019 add 1234567890123456 6E-18 -> 1234567890123456 Inexact Rounded +addx62020 add 1234567890123456 6E-19 -> 1234567890123456 Inexact Rounded +addx62021 add 1234567890123456 6E-20 -> 1234567890123456 Inexact Rounded + +-- widening second argument at gap +addx62030 add 12345678 1 -> 12345679 +addx62031 add 12345678 0.1 -> 12345678.1 +addx62032 add 12345678 0.12 -> 12345678.12 +addx62033 add 12345678 0.123 -> 12345678.123 +addx62034 add 12345678 0.1234 -> 12345678.1234 +addx62035 add 12345678 0.12345 -> 12345678.12345 +addx62036 add 12345678 0.123456 -> 12345678.123456 +addx62037 add 12345678 0.1234567 -> 12345678.1234567 +addx62038 add 12345678 0.12345678 -> 12345678.12345678 +addx62039 add 12345678 0.123456789 -> 12345678.12345679 Inexact Rounded +addx62040 add 12345678 0.123456785 -> 12345678.12345678 Inexact Rounded +addx62041 add 12345678 0.1234567850 -> 12345678.12345678 Inexact Rounded +addx62042 add 12345678 0.1234567851 -> 12345678.12345679 Inexact Rounded +addx62043 add 12345678 0.12345678501 -> 12345678.12345679 Inexact Rounded +addx62044 add 12345678 0.123456785001 -> 12345678.12345679 Inexact Rounded +addx62045 add 12345678 0.1234567850001 -> 12345678.12345679 Inexact Rounded +addx62046 add 12345678 0.12345678500001 -> 12345678.12345679 Inexact Rounded +addx62047 add 12345678 0.123456785000001 -> 12345678.12345679 Inexact Rounded +addx62048 add 12345678 0.1234567850000001 -> 12345678.12345679 Inexact Rounded +addx62049 add 12345678 0.1234567850000000 -> 12345678.12345678 Inexact Rounded +-- 90123456 +rounding: half_even +addx62050 add 12345678 0.0234567750000000 -> 12345678.02345678 Inexact Rounded +addx62051 add 12345678 0.0034567750000000 -> 12345678.00345678 Inexact Rounded +addx62052 add 12345678 0.0004567750000000 -> 12345678.00045678 Inexact Rounded +addx62053 add 12345678 0.0000567750000000 -> 12345678.00005678 Inexact Rounded +addx62054 add 12345678 0.0000067750000000 -> 12345678.00000678 Inexact Rounded +addx62055 add 12345678 0.0000007750000000 -> 12345678.00000078 Inexact Rounded +addx62056 add 12345678 0.0000000750000000 -> 12345678.00000008 Inexact Rounded +addx62057 add 12345678 0.0000000050000000 -> 12345678.00000000 Inexact Rounded +addx62060 add 12345678 0.0234567750000001 -> 12345678.02345678 Inexact Rounded +addx62061 add 12345678 0.0034567750000001 -> 12345678.00345678 Inexact Rounded +addx62062 add 12345678 0.0004567750000001 -> 12345678.00045678 Inexact Rounded +addx62063 add 12345678 0.0000567750000001 -> 12345678.00005678 Inexact Rounded +addx62064 add 12345678 0.0000067750000001 -> 12345678.00000678 Inexact Rounded +addx62065 add 12345678 0.0000007750000001 -> 12345678.00000078 Inexact Rounded +addx62066 add 12345678 0.0000000750000001 -> 12345678.00000008 Inexact Rounded +addx62067 add 12345678 0.0000000050000001 -> 12345678.00000001 Inexact Rounded +-- far-out residues (full coefficient gap is 16+15 digits) +rounding: up +addx62070 add 12345678 1E-8 -> 12345678.00000001 +addx62071 add 12345678 1E-9 -> 12345678.00000001 Inexact Rounded +addx62072 add 12345678 1E-10 -> 12345678.00000001 Inexact Rounded +addx62073 add 12345678 1E-11 -> 12345678.00000001 Inexact Rounded +addx62074 add 12345678 1E-12 -> 12345678.00000001 Inexact Rounded +addx62075 add 12345678 1E-13 -> 12345678.00000001 Inexact Rounded +addx62076 add 12345678 1E-14 -> 12345678.00000001 Inexact Rounded +addx62077 add 12345678 1E-15 -> 12345678.00000001 Inexact Rounded +addx62078 add 12345678 1E-16 -> 12345678.00000001 Inexact Rounded +addx62079 add 12345678 1E-17 -> 12345678.00000001 Inexact Rounded +addx62080 add 12345678 1E-18 -> 12345678.00000001 Inexact Rounded +addx62081 add 12345678 1E-19 -> 12345678.00000001 Inexact Rounded +addx62082 add 12345678 1E-20 -> 12345678.00000001 Inexact Rounded +addx62083 add 12345678 1E-25 -> 12345678.00000001 Inexact Rounded +addx62084 add 12345678 1E-30 -> 12345678.00000001 Inexact Rounded +addx62085 add 12345678 1E-31 -> 12345678.00000001 Inexact Rounded +addx62086 add 12345678 1E-32 -> 12345678.00000001 Inexact Rounded +addx62087 add 12345678 1E-33 -> 12345678.00000001 Inexact Rounded +addx62088 add 12345678 1E-34 -> 12345678.00000001 Inexact Rounded +addx62089 add 12345678 1E-35 -> 12345678.00000001 Inexact Rounded + +-- payload decapitate +precision: 5 +addx62100 add 11 sNaN123456789 -> NaN56789 Invalid_operation +addx62101 add -11 -sNaN123456789 -> -NaN56789 Invalid_operation +addx62102 add 11 NaN123456789 -> NaN56789 +addx62103 add -11 -NaN123456789 -> -NaN56789 -- Null tests addx9990 add 10 # -> NaN Invalid_operation Added: python/branches/release25-maint/Lib/test/decimaltestdata/and.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/and.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,338 @@ +------------------------------------------------------------------------ +-- and.decTest -- digitwise logical AND -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +extended: 1 +precision: 9 +rounding: half_up +maxExponent: 999 +minExponent: -999 + +-- Sanity check (truth table) +andx001 and 0 0 -> 0 +andx002 and 0 1 -> 0 +andx003 and 1 0 -> 0 +andx004 and 1 1 -> 1 +andx005 and 1100 1010 -> 1000 +andx006 and 1111 10 -> 10 +andx007 and 1111 1010 -> 1010 + +-- and at msd and msd-1 +andx010 and 000000000 000000000 -> 0 +andx011 and 000000000 100000000 -> 0 +andx012 and 100000000 000000000 -> 0 +andx013 and 100000000 100000000 -> 100000000 +andx014 and 000000000 000000000 -> 0 +andx015 and 000000000 010000000 -> 0 +andx016 and 010000000 000000000 -> 0 +andx017 and 010000000 010000000 -> 10000000 + +-- Various lengths +-- 123456789 123456789 123456789 +andx021 and 111111111 111111111 -> 111111111 +andx022 and 111111111111 111111111 -> 111111111 +andx023 and 111111111111 11111111 -> 11111111 +andx024 and 111111111 11111111 -> 11111111 +andx025 and 111111111 1111111 -> 1111111 +andx026 and 111111111111 111111 -> 111111 +andx027 and 111111111111 11111 -> 11111 +andx028 and 111111111111 1111 -> 1111 +andx029 and 111111111111 111 -> 111 +andx031 and 111111111111 11 -> 11 +andx032 and 111111111111 1 -> 1 +andx033 and 111111111111 1111111111 -> 111111111 +andx034 and 11111111111 11111111111 -> 111111111 +andx035 and 1111111111 111111111111 -> 111111111 +andx036 and 111111111 1111111111111 -> 111111111 + +andx040 and 111111111 111111111111 -> 111111111 +andx041 and 11111111 111111111111 -> 11111111 +andx042 and 11111111 111111111 -> 11111111 +andx043 and 1111111 111111111 -> 1111111 +andx044 and 111111 111111111 -> 111111 +andx045 and 11111 111111111 -> 11111 +andx046 and 1111 111111111 -> 1111 +andx047 and 111 111111111 -> 111 +andx048 and 11 111111111 -> 11 +andx049 and 1 111111111 -> 1 + +andx050 and 1111111111 1 -> 1 +andx051 and 111111111 1 -> 1 +andx052 and 11111111 1 -> 1 +andx053 and 1111111 1 -> 1 +andx054 and 111111 1 -> 1 +andx055 and 11111 1 -> 1 +andx056 and 1111 1 -> 1 +andx057 and 111 1 -> 1 +andx058 and 11 1 -> 1 +andx059 and 1 1 -> 1 + +andx060 and 1111111111 0 -> 0 +andx061 and 111111111 0 -> 0 +andx062 and 11111111 0 -> 0 +andx063 and 1111111 0 -> 0 +andx064 and 111111 0 -> 0 +andx065 and 11111 0 -> 0 +andx066 and 1111 0 -> 0 +andx067 and 111 0 -> 0 +andx068 and 11 0 -> 0 +andx069 and 1 0 -> 0 + +andx070 and 1 1111111111 -> 1 +andx071 and 1 111111111 -> 1 +andx072 and 1 11111111 -> 1 +andx073 and 1 1111111 -> 1 +andx074 and 1 111111 -> 1 +andx075 and 1 11111 -> 1 +andx076 and 1 1111 -> 1 +andx077 and 1 111 -> 1 +andx078 and 1 11 -> 1 +andx079 and 1 1 -> 1 + +andx080 and 0 1111111111 -> 0 +andx081 and 0 111111111 -> 0 +andx082 and 0 11111111 -> 0 +andx083 and 0 1111111 -> 0 +andx084 and 0 111111 -> 0 +andx085 and 0 11111 -> 0 +andx086 and 0 1111 -> 0 +andx087 and 0 111 -> 0 +andx088 and 0 11 -> 0 +andx089 and 0 1 -> 0 + +andx090 and 011111111 111111111 -> 11111111 +andx091 and 101111111 111111111 -> 101111111 +andx092 and 110111111 111111111 -> 110111111 +andx093 and 111011111 111111111 -> 111011111 +andx094 and 111101111 111111111 -> 111101111 +andx095 and 111110111 111111111 -> 111110111 +andx096 and 111111011 111111111 -> 111111011 +andx097 and 111111101 111111111 -> 111111101 +andx098 and 111111110 111111111 -> 111111110 + +andx100 and 111111111 011111111 -> 11111111 +andx101 and 111111111 101111111 -> 101111111 +andx102 and 111111111 110111111 -> 110111111 +andx103 and 111111111 111011111 -> 111011111 +andx104 and 111111111 111101111 -> 111101111 +andx105 and 111111111 111110111 -> 111110111 +andx106 and 111111111 111111011 -> 111111011 +andx107 and 111111111 111111101 -> 111111101 +andx108 and 111111111 111111110 -> 111111110 + +-- non-0/1 should not be accepted, nor should signs +andx220 and 111111112 111111111 -> NaN Invalid_operation +andx221 and 333333333 333333333 -> NaN Invalid_operation +andx222 and 555555555 555555555 -> NaN Invalid_operation +andx223 and 777777777 777777777 -> NaN Invalid_operation +andx224 and 999999999 999999999 -> NaN Invalid_operation +andx225 and 222222222 999999999 -> NaN Invalid_operation +andx226 and 444444444 999999999 -> NaN Invalid_operation +andx227 and 666666666 999999999 -> NaN Invalid_operation +andx228 and 888888888 999999999 -> NaN Invalid_operation +andx229 and 999999999 222222222 -> NaN Invalid_operation +andx230 and 999999999 444444444 -> NaN Invalid_operation +andx231 and 999999999 666666666 -> NaN Invalid_operation +andx232 and 999999999 888888888 -> NaN Invalid_operation +-- a few randoms +andx240 and 567468689 -934981942 -> NaN Invalid_operation +andx241 and 567367689 934981942 -> NaN Invalid_operation +andx242 and -631917772 -706014634 -> NaN Invalid_operation +andx243 and -756253257 138579234 -> NaN Invalid_operation +andx244 and 835590149 567435400 -> NaN Invalid_operation +-- test MSD +andx250 and 200000000 100000000 -> NaN Invalid_operation +andx251 and 700000000 100000000 -> NaN Invalid_operation +andx252 and 800000000 100000000 -> NaN Invalid_operation +andx253 and 900000000 100000000 -> NaN Invalid_operation +andx254 and 200000000 000000000 -> NaN Invalid_operation +andx255 and 700000000 000000000 -> NaN Invalid_operation +andx256 and 800000000 000000000 -> NaN Invalid_operation +andx257 and 900000000 000000000 -> NaN Invalid_operation +andx258 and 100000000 200000000 -> NaN Invalid_operation +andx259 and 100000000 700000000 -> NaN Invalid_operation +andx260 and 100000000 800000000 -> NaN Invalid_operation +andx261 and 100000000 900000000 -> NaN Invalid_operation +andx262 and 000000000 200000000 -> NaN Invalid_operation +andx263 and 000000000 700000000 -> NaN Invalid_operation +andx264 and 000000000 800000000 -> NaN Invalid_operation +andx265 and 000000000 900000000 -> NaN Invalid_operation +-- test MSD-1 +andx270 and 020000000 100000000 -> NaN Invalid_operation +andx271 and 070100000 100000000 -> NaN Invalid_operation +andx272 and 080010000 100000001 -> NaN Invalid_operation +andx273 and 090001000 100000010 -> NaN Invalid_operation +andx274 and 100000100 020010100 -> NaN Invalid_operation +andx275 and 100000000 070001000 -> NaN Invalid_operation +andx276 and 100000010 080010100 -> NaN Invalid_operation +andx277 and 100000000 090000010 -> NaN Invalid_operation +-- test LSD +andx280 and 001000002 100000000 -> NaN Invalid_operation +andx281 and 000000007 100000000 -> NaN Invalid_operation +andx282 and 000000008 100000000 -> NaN Invalid_operation +andx283 and 000000009 100000000 -> NaN Invalid_operation +andx284 and 100000000 000100002 -> NaN Invalid_operation +andx285 and 100100000 001000007 -> NaN Invalid_operation +andx286 and 100010000 010000008 -> NaN Invalid_operation +andx287 and 100001000 100000009 -> NaN Invalid_operation +-- test Middie +andx288 and 001020000 100000000 -> NaN Invalid_operation +andx289 and 000070001 100000000 -> NaN Invalid_operation +andx290 and 000080000 100010000 -> NaN Invalid_operation +andx291 and 000090000 100001000 -> NaN Invalid_operation +andx292 and 100000010 000020100 -> NaN Invalid_operation +andx293 and 100100000 000070010 -> NaN Invalid_operation +andx294 and 100010100 000080001 -> NaN Invalid_operation +andx295 and 100001000 000090000 -> NaN Invalid_operation +-- signs +andx296 and -100001000 -000000000 -> NaN Invalid_operation +andx297 and -100001000 000010000 -> NaN Invalid_operation +andx298 and 100001000 -000000000 -> NaN Invalid_operation +andx299 and 100001000 000011000 -> 1000 + +-- Nmax, Nmin, Ntiny +andx331 and 2 9.99999999E+999 -> NaN Invalid_operation +andx332 and 3 1E-999 -> NaN Invalid_operation +andx333 and 4 1.00000000E-999 -> NaN Invalid_operation +andx334 and 5 1E-1007 -> NaN Invalid_operation +andx335 and 6 -1E-1007 -> NaN Invalid_operation +andx336 and 7 -1.00000000E-999 -> NaN Invalid_operation +andx337 and 8 -1E-999 -> NaN Invalid_operation +andx338 and 9 -9.99999999E+999 -> NaN Invalid_operation +andx341 and 9.99999999E+999 -18 -> NaN Invalid_operation +andx342 and 1E-999 01 -> NaN Invalid_operation +andx343 and 1.00000000E-999 -18 -> NaN Invalid_operation +andx344 and 1E-1007 18 -> NaN Invalid_operation +andx345 and -1E-1007 -10 -> NaN Invalid_operation +andx346 and -1.00000000E-999 18 -> NaN Invalid_operation +andx347 and -1E-999 10 -> NaN Invalid_operation +andx348 and -9.99999999E+999 -18 -> NaN Invalid_operation + +-- A few other non-integers +andx361 and 1.0 1 -> NaN Invalid_operation +andx362 and 1E+1 1 -> NaN Invalid_operation +andx363 and 0.0 1 -> NaN Invalid_operation +andx364 and 0E+1 1 -> NaN Invalid_operation +andx365 and 9.9 1 -> NaN Invalid_operation +andx366 and 9E+1 1 -> NaN Invalid_operation +andx371 and 0 1.0 -> NaN Invalid_operation +andx372 and 0 1E+1 -> NaN Invalid_operation +andx373 and 0 0.0 -> NaN Invalid_operation +andx374 and 0 0E+1 -> NaN Invalid_operation +andx375 and 0 9.9 -> NaN Invalid_operation +andx376 and 0 9E+1 -> NaN Invalid_operation + +-- All Specials are in error +andx780 and -Inf -Inf -> NaN Invalid_operation +andx781 and -Inf -1000 -> NaN Invalid_operation +andx782 and -Inf -1 -> NaN Invalid_operation +andx783 and -Inf -0 -> NaN Invalid_operation +andx784 and -Inf 0 -> NaN Invalid_operation +andx785 and -Inf 1 -> NaN Invalid_operation +andx786 and -Inf 1000 -> NaN Invalid_operation +andx787 and -1000 -Inf -> NaN Invalid_operation +andx788 and -Inf -Inf -> NaN Invalid_operation +andx789 and -1 -Inf -> NaN Invalid_operation +andx790 and -0 -Inf -> NaN Invalid_operation +andx791 and 0 -Inf -> NaN Invalid_operation +andx792 and 1 -Inf -> NaN Invalid_operation +andx793 and 1000 -Inf -> NaN Invalid_operation +andx794 and Inf -Inf -> NaN Invalid_operation + +andx800 and Inf -Inf -> NaN Invalid_operation +andx801 and Inf -1000 -> NaN Invalid_operation +andx802 and Inf -1 -> NaN Invalid_operation +andx803 and Inf -0 -> NaN Invalid_operation +andx804 and Inf 0 -> NaN Invalid_operation +andx805 and Inf 1 -> NaN Invalid_operation +andx806 and Inf 1000 -> NaN Invalid_operation +andx807 and Inf Inf -> NaN Invalid_operation +andx808 and -1000 Inf -> NaN Invalid_operation +andx809 and -Inf Inf -> NaN Invalid_operation +andx810 and -1 Inf -> NaN Invalid_operation +andx811 and -0 Inf -> NaN Invalid_operation +andx812 and 0 Inf -> NaN Invalid_operation +andx813 and 1 Inf -> NaN Invalid_operation +andx814 and 1000 Inf -> NaN Invalid_operation +andx815 and Inf Inf -> NaN Invalid_operation + +andx821 and NaN -Inf -> NaN Invalid_operation +andx822 and NaN -1000 -> NaN Invalid_operation +andx823 and NaN -1 -> NaN Invalid_operation +andx824 and NaN -0 -> NaN Invalid_operation +andx825 and NaN 0 -> NaN Invalid_operation +andx826 and NaN 1 -> NaN Invalid_operation +andx827 and NaN 1000 -> NaN Invalid_operation +andx828 and NaN Inf -> NaN Invalid_operation +andx829 and NaN NaN -> NaN Invalid_operation +andx830 and -Inf NaN -> NaN Invalid_operation +andx831 and -1000 NaN -> NaN Invalid_operation +andx832 and -1 NaN -> NaN Invalid_operation +andx833 and -0 NaN -> NaN Invalid_operation +andx834 and 0 NaN -> NaN Invalid_operation +andx835 and 1 NaN -> NaN Invalid_operation +andx836 and 1000 NaN -> NaN Invalid_operation +andx837 and Inf NaN -> NaN Invalid_operation + +andx841 and sNaN -Inf -> NaN Invalid_operation +andx842 and sNaN -1000 -> NaN Invalid_operation +andx843 and sNaN -1 -> NaN Invalid_operation +andx844 and sNaN -0 -> NaN Invalid_operation +andx845 and sNaN 0 -> NaN Invalid_operation +andx846 and sNaN 1 -> NaN Invalid_operation +andx847 and sNaN 1000 -> NaN Invalid_operation +andx848 and sNaN NaN -> NaN Invalid_operation +andx849 and sNaN sNaN -> NaN Invalid_operation +andx850 and NaN sNaN -> NaN Invalid_operation +andx851 and -Inf sNaN -> NaN Invalid_operation +andx852 and -1000 sNaN -> NaN Invalid_operation +andx853 and -1 sNaN -> NaN Invalid_operation +andx854 and -0 sNaN -> NaN Invalid_operation +andx855 and 0 sNaN -> NaN Invalid_operation +andx856 and 1 sNaN -> NaN Invalid_operation +andx857 and 1000 sNaN -> NaN Invalid_operation +andx858 and Inf sNaN -> NaN Invalid_operation +andx859 and NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +andx861 and NaN1 -Inf -> NaN Invalid_operation +andx862 and +NaN2 -1000 -> NaN Invalid_operation +andx863 and NaN3 1000 -> NaN Invalid_operation +andx864 and NaN4 Inf -> NaN Invalid_operation +andx865 and NaN5 +NaN6 -> NaN Invalid_operation +andx866 and -Inf NaN7 -> NaN Invalid_operation +andx867 and -1000 NaN8 -> NaN Invalid_operation +andx868 and 1000 NaN9 -> NaN Invalid_operation +andx869 and Inf +NaN10 -> NaN Invalid_operation +andx871 and sNaN11 -Inf -> NaN Invalid_operation +andx872 and sNaN12 -1000 -> NaN Invalid_operation +andx873 and sNaN13 1000 -> NaN Invalid_operation +andx874 and sNaN14 NaN17 -> NaN Invalid_operation +andx875 and sNaN15 sNaN18 -> NaN Invalid_operation +andx876 and NaN16 sNaN19 -> NaN Invalid_operation +andx877 and -Inf +sNaN20 -> NaN Invalid_operation +andx878 and -1000 sNaN21 -> NaN Invalid_operation +andx879 and 1000 sNaN22 -> NaN Invalid_operation +andx880 and Inf sNaN23 -> NaN Invalid_operation +andx881 and +NaN25 +sNaN24 -> NaN Invalid_operation +andx882 and -NaN26 NaN28 -> NaN Invalid_operation +andx883 and -sNaN27 sNaN29 -> NaN Invalid_operation +andx884 and 1000 -NaN30 -> NaN Invalid_operation +andx885 and 1000 -sNaN31 -> NaN Invalid_operation Modified: python/branches/release25-maint/Lib/test/decimaltestdata/base.decTest ============================================================================== --- python/branches/release25-maint/Lib/test/decimaltestdata/base.decTest (original) +++ python/branches/release25-maint/Lib/test/decimaltestdata/base.decTest Tue Jan 8 17:20:31 2008 @@ -1,6 +1,6 @@ ------------------------------------------------------------------------ -- base.decTest -- base decimal <--> string conversions -- --- Copyright (c) IBM Corporation, 1981, 2003. All rights reserved. -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- ------------------------------------------------------------------------ -- Please see the document "General Decimal Arithmetic Testcases" -- -- at http://www2.hursley.ibm.com/decimal for the description of -- @@ -17,7 +17,8 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc at uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.39 +version: 2.57 +extended: 1 -- This file tests base conversions from string to a decimal number -- and back to a string (in either Scientific or Engineering form) @@ -26,11 +27,10 @@ -- to conform to emax and precision settings (that is, numbers will -- conform to rules and exponent will be in permitted range). -precision: 15 +precision: 16 rounding: half_up -maxExponent: 999999999 -minExponent: -999999999 -extended: 1 +maxExponent: 384 +minExponent: -383 basx001 toSci 0 -> 0 basx002 toSci 1 -> 1 @@ -73,41 +73,62 @@ -- String [many more examples are implicitly tested elsewhere] -- strings without E cannot generate E in result -basx100 toSci "12" -> '12' -basx101 toSci "-76" -> '-76' -basx102 toSci "12.76" -> '12.76' -basx103 toSci "+12.76" -> '12.76' -basx104 toSci "012.76" -> '12.76' -basx105 toSci "+0.003" -> '0.003' -basx106 toSci "17." -> '17' -basx107 toSci ".5" -> '0.5' -basx108 toSci "044" -> '44' -basx109 toSci "0044" -> '44' -basx110 toSci "0.0005" -> '0.0005' -basx111 toSci "00.00005" -> '0.00005' -basx112 toSci "0.000005" -> '0.000005' -basx113 toSci "0.0000050" -> '0.0000050' -basx114 toSci "0.0000005" -> '5E-7' -basx115 toSci "0.00000005" -> '5E-8' -basx116 toSci "12345678.543210" -> '12345678.543210' -basx117 toSci "2345678.543210" -> '2345678.543210' -basx118 toSci "345678.543210" -> '345678.543210' -basx119 toSci "0345678.54321" -> '345678.54321' -basx120 toSci "345678.5432" -> '345678.5432' -basx121 toSci "+345678.5432" -> '345678.5432' -basx122 toSci "+0345678.5432" -> '345678.5432' -basx123 toSci "+00345678.5432" -> '345678.5432' -basx124 toSci "-345678.5432" -> '-345678.5432' -basx125 toSci "-0345678.5432" -> '-345678.5432' -basx126 toSci "-00345678.5432" -> '-345678.5432' +basx040 toSci "12" -> '12' +basx041 toSci "-76" -> '-76' +basx042 toSci "12.76" -> '12.76' +basx043 toSci "+12.76" -> '12.76' +basx044 toSci "012.76" -> '12.76' +basx045 toSci "+0.003" -> '0.003' +basx046 toSci "17." -> '17' +basx047 toSci ".5" -> '0.5' +basx048 toSci "044" -> '44' +basx049 toSci "0044" -> '44' +basx050 toSci "0.0005" -> '0.0005' +basx051 toSci "00.00005" -> '0.00005' +basx052 toSci "0.000005" -> '0.000005' +basx053 toSci "0.0000050" -> '0.0000050' +basx054 toSci "0.0000005" -> '5E-7' +basx055 toSci "0.00000005" -> '5E-8' +basx056 toSci "12345678.543210" -> '12345678.543210' +basx057 toSci "2345678.543210" -> '2345678.543210' +basx058 toSci "345678.543210" -> '345678.543210' +basx059 toSci "0345678.54321" -> '345678.54321' +basx060 toSci "345678.5432" -> '345678.5432' +basx061 toSci "+345678.5432" -> '345678.5432' +basx062 toSci "+0345678.5432" -> '345678.5432' +basx063 toSci "+00345678.5432" -> '345678.5432' +basx064 toSci "-345678.5432" -> '-345678.5432' +basx065 toSci "-0345678.5432" -> '-345678.5432' +basx066 toSci "-00345678.5432" -> '-345678.5432' -- examples -basx127 toSci "5E-6" -> '0.000005' -basx128 toSci "50E-7" -> '0.0000050' -basx129 toSci "5E-7" -> '5E-7' - +basx067 toSci "5E-6" -> '0.000005' +basx068 toSci "50E-7" -> '0.0000050' +basx069 toSci "5E-7" -> '5E-7' -- [No exotics as no Unicode] +-- rounded with dots in all (including edge) places +basx071 toSci .1234567890123456123 -> 0.1234567890123456 Inexact Rounded +basx072 toSci 1.234567890123456123 -> 1.234567890123456 Inexact Rounded +basx073 toSci 12.34567890123456123 -> 12.34567890123456 Inexact Rounded +basx074 toSci 123.4567890123456123 -> 123.4567890123456 Inexact Rounded +basx075 toSci 1234.567890123456123 -> 1234.567890123456 Inexact Rounded +basx076 toSci 12345.67890123456123 -> 12345.67890123456 Inexact Rounded +basx077 toSci 123456.7890123456123 -> 123456.7890123456 Inexact Rounded +basx078 toSci 1234567.890123456123 -> 1234567.890123456 Inexact Rounded +basx079 toSci 12345678.90123456123 -> 12345678.90123456 Inexact Rounded +basx080 toSci 123456789.0123456123 -> 123456789.0123456 Inexact Rounded +basx081 toSci 1234567890.123456123 -> 1234567890.123456 Inexact Rounded +basx082 toSci 12345678901.23456123 -> 12345678901.23456 Inexact Rounded +basx083 toSci 123456789012.3456123 -> 123456789012.3456 Inexact Rounded +basx084 toSci 1234567890123.456123 -> 1234567890123.456 Inexact Rounded +basx085 toSci 12345678901234.56123 -> 12345678901234.56 Inexact Rounded +basx086 toSci 123456789012345.6123 -> 123456789012345.6 Inexact Rounded +basx087 toSci 1234567890123456.123 -> 1234567890123456 Inexact Rounded +basx088 toSci 12345678901234561.23 -> 1.234567890123456E+16 Inexact Rounded +basx089 toSci 123456789012345612.3 -> 1.234567890123456E+17 Inexact Rounded +basx090 toSci 1234567890123456123. -> 1.234567890123456E+18 Inexact Rounded + -- Numbers with E basx130 toSci "0.000E-1" -> '0.0000' basx131 toSci "0.000E-2" -> '0.00000' @@ -225,21 +246,6 @@ basx262 toSci "0.1265E+8" -> '1.265E+7' basx263 toSci "0.1265E+20" -> '1.265E+19' -basx270 toSci "0.09e999" -> '9E+997' -basx271 toSci "0.9e999" -> '9E+998' -basx272 toSci "9e999" -> '9E+999' -basx273 toSci "9.9e999" -> '9.9E+999' -basx274 toSci "9.99e999" -> '9.99E+999' -basx275 toSci "9.99e-999" -> '9.99E-999' -basx276 toSci "9.9e-999" -> '9.9E-999' -basx277 toSci "9e-999" -> '9E-999' -basx279 toSci "99e-999" -> '9.9E-998' -basx280 toSci "999e-999" -> '9.99E-997' -basx281 toSci '0.9e-998' -> '9E-999' -basx282 toSci '0.09e-997' -> '9E-999' -basx283 toSci '0.1e1000' -> '1E+999' -basx284 toSci '10e-1000' -> '1.0E-999' - -- some more negative zeros [systematic tests below] basx290 toSci "-0.000E-1" -> '-0.0000' basx291 toSci "-0.000E-2" -> '-0.00000' @@ -418,6 +424,22 @@ basx474 toSci 1000000009000 -> 1.00000001E+12 Rounded Inexact basx475 toEng 1000000009000 -> 1.00000001E+12 Rounded Inexact +-- all-nines rounding +precision: 9 +rounding: half_up +basx270 toSci 999999999 -> 999999999 +basx271 toSci 9999999990 -> 9.99999999E+9 Rounded +basx272 toSci 9999999991 -> 9.99999999E+9 Rounded Inexact +basx273 toSci 9999999992 -> 9.99999999E+9 Rounded Inexact +basx274 toSci 9999999993 -> 9.99999999E+9 Rounded Inexact +basx275 toSci 9999999994 -> 9.99999999E+9 Rounded Inexact +basx276 toSci 9999999995 -> 1.00000000E+10 Rounded Inexact +basx277 toSci 9999999996 -> 1.00000000E+10 Rounded Inexact +basx278 toSci 9999999997 -> 1.00000000E+10 Rounded Inexact +basx279 toSci 9999999998 -> 1.00000000E+10 Rounded Inexact +basx280 toSci 9999999999 -> 1.00000000E+10 Rounded Inexact +basx281 toSci 9999999999999999 -> 1.00000000E+16 Rounded Inexact + -- check rounding modes heeded precision: 5 rounding: ceiling @@ -425,11 +447,11 @@ bsrx402 toSci 1.234549 -> 1.2346 Rounded Inexact bsrx403 toSci 1.234550 -> 1.2346 Rounded Inexact bsrx404 toSci 1.234551 -> 1.2346 Rounded Inexact -rounding: down +rounding: up bsrx405 toSci 1.23450 -> 1.2345 Rounded -bsrx406 toSci 1.234549 -> 1.2345 Rounded Inexact -bsrx407 toSci 1.234550 -> 1.2345 Rounded Inexact -bsrx408 toSci 1.234551 -> 1.2345 Rounded Inexact +bsrx406 toSci 1.234549 -> 1.2346 Rounded Inexact +bsrx407 toSci 1.234550 -> 1.2346 Rounded Inexact +bsrx408 toSci 1.234551 -> 1.2346 Rounded Inexact rounding: floor bsrx410 toSci 1.23450 -> 1.2345 Rounded bsrx411 toSci 1.234549 -> 1.2345 Rounded Inexact @@ -464,11 +486,11 @@ bsrx502 toSci -1.234549 -> -1.2345 Rounded Inexact bsrx503 toSci -1.234550 -> -1.2345 Rounded Inexact bsrx504 toSci -1.234551 -> -1.2345 Rounded Inexact -rounding: down +rounding: up bsrx505 toSci -1.23450 -> -1.2345 Rounded -bsrx506 toSci -1.234549 -> -1.2345 Rounded Inexact -bsrx507 toSci -1.234550 -> -1.2345 Rounded Inexact -bsrx508 toSci -1.234551 -> -1.2345 Rounded Inexact +bsrx506 toSci -1.234549 -> -1.2346 Rounded Inexact +bsrx507 toSci -1.234550 -> -1.2346 Rounded Inexact +bsrx508 toSci -1.234551 -> -1.2346 Rounded Inexact rounding: floor bsrx510 toSci -1.23450 -> -1.2345 Rounded bsrx511 toSci -1.234549 -> -1.2346 Rounded Inexact @@ -498,6 +520,24 @@ bsrx534 toSci -1.234650 -> -1.2347 Rounded Inexact bsrx535 toSci -1.234551 -> -1.2346 Rounded Inexact +-- a few larger exponents +maxExponent: 999999999 +minExponent: -999999999 +basx480 toSci "0.09e999" -> '9E+997' +basx481 toSci "0.9e999" -> '9E+998' +basx482 toSci "9e999" -> '9E+999' +basx483 toSci "9.9e999" -> '9.9E+999' +basx484 toSci "9.99e999" -> '9.99E+999' +basx485 toSci "9.99e-999" -> '9.99E-999' +basx486 toSci "9.9e-999" -> '9.9E-999' +basx487 toSci "9e-999" -> '9E-999' +basx489 toSci "99e-999" -> '9.9E-998' +basx490 toSci "999e-999" -> '9.99E-997' +basx491 toSci '0.9e-998' -> '9E-999' +basx492 toSci '0.09e-997' -> '9E-999' +basx493 toSci '0.1e1000' -> '1E+999' +basx494 toSci '10e-1000' -> '1.0E-999' + rounding: half_up precision: 9 @@ -580,32 +620,23 @@ basx574 toSci "xNaN" -> NaN Conversion_syntax basx575 toSci "0sNaN" -> NaN Conversion_syntax --- subnormals and overflows -basx576 toSci '99e999999999' -> Infinity Overflow Inexact Rounded -basx577 toSci '999e999999999' -> Infinity Overflow Inexact Rounded -basx578 toSci '0.9e-999999999' -> 9E-1000000000 Subnormal -basx579 toSci '0.09e-999999999' -> 9E-1000000001 Subnormal -basx580 toSci '0.1e1000000000' -> 1E+999999999 -basx581 toSci '10e-1000000000' -> 1.0E-999999999 -basx582 toSci '0.9e9999999999' -> Infinity Overflow Inexact Rounded -basx583 toSci '99e-9999999999' -> 0E-1000000007 Underflow Subnormal Inexact Rounded -basx584 toSci '111e9999999999' -> Infinity Overflow Inexact Rounded -basx585 toSci '1111e-9999999999' -> 0E-1000000007 Underflow Subnormal Inexact Rounded -basx586 toSci '1111e-99999999999' -> 0E-1000000007 Underflow Subnormal Inexact Rounded -basx587 toSci '7e1000000000' -> Infinity Overflow Inexact Rounded --- negatives the same -basx588 toSci '-99e999999999' -> -Infinity Overflow Inexact Rounded -basx589 toSci '-999e999999999' -> -Infinity Overflow Inexact Rounded -basx590 toSci '-0.9e-999999999' -> -9E-1000000000 Subnormal -basx591 toSci '-0.09e-999999999' -> -9E-1000000001 Subnormal -basx592 toSci '-0.1e1000000000' -> -1E+999999999 -basx593 toSci '-10e-1000000000' -> -1.0E-999999999 -basx594 toSci '-0.9e9999999999' -> -Infinity Overflow Inexact Rounded -basx595 toSci '-99e-9999999999' -> -0E-1000000007 Underflow Subnormal Inexact Rounded -basx596 toSci '-111e9999999999' -> -Infinity Overflow Inexact Rounded -basx597 toSci '-1111e-9999999999' -> -0E-1000000007 Underflow Subnormal Inexact Rounded -basx598 toSci '-1111e-99999999999' -> -0E-1000000007 Underflow Subnormal Inexact Rounded -basx599 toSci '-7e1000000000' -> -Infinity Overflow Inexact Rounded +-- some baddies with dots and Es and dots and specials +basx576 toSci 'e+1' -> NaN Conversion_syntax +basx577 toSci '.e+1' -> NaN Conversion_syntax +basx578 toSci '+.e+1' -> NaN Conversion_syntax +basx579 toSci '-.e+' -> NaN Conversion_syntax +basx580 toSci '-.e' -> NaN Conversion_syntax +basx581 toSci 'E+1' -> NaN Conversion_syntax +basx582 toSci '.E+1' -> NaN Conversion_syntax +basx583 toSci '+.E+1' -> NaN Conversion_syntax +basx584 toSci '-.E+' -> NaN Conversion_syntax +basx585 toSci '-.E' -> NaN Conversion_syntax + +basx586 toSci '.NaN' -> NaN Conversion_syntax +basx587 toSci '-.NaN' -> NaN Conversion_syntax +basx588 toSci '+.sNaN' -> NaN Conversion_syntax +basx589 toSci '+.Inf' -> NaN Conversion_syntax +basx590 toSci '.Infinity' -> NaN Conversion_syntax -- Zeros basx601 toSci 0.000000000 -> 0E-9 @@ -686,6 +717,17 @@ basx678 toSci 0.00E-8 -> 0E-10 basx679 toSci 0.00E-9 -> 0E-11 +basx680 toSci 000000. -> 0 +basx681 toSci 00000. -> 0 +basx682 toSci 0000. -> 0 +basx683 toSci 000. -> 0 +basx684 toSci 00. -> 0 +basx685 toSci 0. -> 0 +basx686 toSci +00000. -> 0 +basx687 toSci -00000. -> -0 +basx688 toSci +0. -> 0 +basx689 toSci -0. -> -0 + -- Specials precision: 4 basx700 toSci "NaN" -> NaN @@ -868,6 +910,62 @@ basx878 toEng 0.00E-8 -> 0.0E-9 basx879 toEng 0.00E-9 -> 0.00E-9 + +rounding: half_up +precision: 9 +-- subnormals and overflows +basx906 toSci '99e999999999' -> Infinity Overflow Inexact Rounded +basx907 toSci '999e999999999' -> Infinity Overflow Inexact Rounded +basx908 toSci '0.9e-999999999' -> 9E-1000000000 Subnormal +basx909 toSci '0.09e-999999999' -> 9E-1000000001 Subnormal +basx910 toSci '0.1e1000000000' -> 1E+999999999 +basx911 toSci '10e-1000000000' -> 1.0E-999999999 +basx912 toSci '0.9e9999999999' -> Infinity Overflow Inexact Rounded +basx913 toSci '99e-9999999999' -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped +basx914 toSci '111e9999999999' -> Infinity Overflow Inexact Rounded +basx915 toSci '1111e-9999999999' -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped +basx916 toSci '1111e-99999999999' -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped +basx917 toSci '7e1000000000' -> Infinity Overflow Inexact Rounded +-- negatives the same +basx918 toSci '-99e999999999' -> -Infinity Overflow Inexact Rounded +basx919 toSci '-999e999999999' -> -Infinity Overflow Inexact Rounded +basx920 toSci '-0.9e-999999999' -> -9E-1000000000 Subnormal +basx921 toSci '-0.09e-999999999' -> -9E-1000000001 Subnormal +basx922 toSci '-0.1e1000000000' -> -1E+999999999 +basx923 toSci '-10e-1000000000' -> -1.0E-999999999 +basx924 toSci '-0.9e9999999999' -> -Infinity Overflow Inexact Rounded +basx925 toSci '-99e-9999999999' -> -0E-1000000007 Underflow Subnormal Inexact Rounded Clamped +basx926 toSci '-111e9999999999' -> -Infinity Overflow Inexact Rounded +basx927 toSci '-1111e-9999999999' -> -0E-1000000007 Underflow Subnormal Inexact Rounded Clamped +basx928 toSci '-1111e-99999999999' -> -0E-1000000007 Underflow Subnormal Inexact Rounded Clamped +basx929 toSci '-7e1000000000' -> -Infinity Overflow Inexact Rounded + +rounding: ceiling +basx930 toSci '7e1000000000' -> Infinity Overflow Inexact Rounded +basx931 toSci '-7e1000000000' -> -9.99999999E+999999999 Overflow Inexact Rounded +rounding: up +basx932 toSci '7e1000000000' -> Infinity Overflow Inexact Rounded +basx933 toSci '-7e1000000000' -> -Infinity Overflow Inexact Rounded +rounding: down +basx934 toSci '7e1000000000' -> 9.99999999E+999999999 Overflow Inexact Rounded +basx935 toSci '-7e1000000000' -> -9.99999999E+999999999 Overflow Inexact Rounded +rounding: floor +basx936 toSci '7e1000000000' -> 9.99999999E+999999999 Overflow Inexact Rounded +basx937 toSci '-7e1000000000' -> -Infinity Overflow Inexact Rounded + +rounding: half_up +basx938 toSci '7e1000000000' -> Infinity Overflow Inexact Rounded +basx939 toSci '-7e1000000000' -> -Infinity Overflow Inexact Rounded +rounding: half_even +basx940 toSci '7e1000000000' -> Infinity Overflow Inexact Rounded +basx941 toSci '-7e1000000000' -> -Infinity Overflow Inexact Rounded +rounding: half_down +basx942 toSci '7e1000000000' -> Infinity Overflow Inexact Rounded +basx943 toSci '-7e1000000000' -> -Infinity Overflow Inexact Rounded + +rounding: half_even + + -- Giga exponent initial tests maxExponent: 999999999 minExponent: -999999999 @@ -987,8 +1085,8 @@ emax226 toSci 1E-8 -> 1E-8 Subnormal emax227 toSci 1E-9 -> 1E-9 Subnormal emax228 toSci 1E-10 -> 1E-10 Subnormal -emax229 toSci 1E-11 -> 0E-10 Underflow Subnormal Inexact Rounded -emax230 toSci 1E-12 -> 0E-10 Underflow Subnormal Inexact Rounded +emax229 toSci 1E-11 -> 0E-10 Underflow Subnormal Inexact Rounded Clamped +emax230 toSci 1E-12 -> 0E-10 Underflow Subnormal Inexact Rounded Clamped maxexponent: 7 minexponent: -7 @@ -1003,7 +1101,7 @@ maxexponent: 9 minexponent: -9 -emax240 toSci 1E-21 -> 0E-17 Subnormal Underflow Inexact Rounded +emax240 toSci 1E-21 -> 0E-17 Subnormal Underflow Inexact Rounded Clamped emax241 toSci 1E-10 -> 1E-10 Subnormal emax242 toSci 1E-9 -> 1E-9 emax243 toSci 1E-8 -> 1E-8 @@ -1015,7 +1113,7 @@ maxexponent: 10 -- boundary minexponent: -10 -emax250 toSci 1E-21 -> 0E-18 Underflow Subnormal Inexact Rounded +emax250 toSci 1E-21 -> 0E-18 Underflow Subnormal Inexact Rounded Clamped emax251 toSci 1E-11 -> 1E-11 Subnormal emax252 toSci 1E-10 -> 1E-10 emax253 toSci 1E-9 -> 1E-9 @@ -1025,7 +1123,7 @@ emax257 toSci 1E+10 -> 1E+10 emax258 toSci 1E+11 -> Infinity Overflow Inexact Rounded -emax260 toSci 1.00E-21 -> 0E-18 Underflow Subnormal Inexact Rounded +emax260 toSci 1.00E-21 -> 0E-18 Underflow Subnormal Inexact Rounded Clamped emax261 toSci 1.00E-11 -> 1.00E-11 Subnormal emax262 toSci 1.00E-10 -> 1.00E-10 emax263 toSci 1.00E-9 -> 1.00E-9 @@ -1034,7 +1132,7 @@ emax266 toSci 1.00E+9 -> 1.00E+9 emax267 toSci 1.00E+10 -> 1.00E+10 emax268 toSci 1.00E+11 -> Infinity Overflow Inexact Rounded -emax270 toSci 9.99E-21 -> 0E-18 Underflow Subnormal Inexact Rounded +emax270 toSci 9.99E-21 -> 0E-18 Underflow Subnormal Inexact Rounded Clamped emax271 toSci 9.99E-11 -> 9.99E-11 Subnormal emax272 toSci 9.99E-10 -> 9.99E-10 emax273 toSci 9.99E-9 -> 9.99E-9 @@ -1046,7 +1144,7 @@ maxexponent: 99 minexponent: -99 -emax280 toSci 1E-120 -> 0E-107 Underflow Subnormal Inexact Rounded +emax280 toSci 1E-120 -> 0E-107 Underflow Subnormal Inexact Rounded Clamped emax281 toSci 1E-100 -> 1E-100 Subnormal emax282 toSci 1E-99 -> 1E-99 emax283 toSci 1E-98 -> 1E-98 @@ -1093,7 +1191,7 @@ maxexponent: 999999999 minexponent: -999999999 -emax347 toSci 1E-1000000008 -> 0E-1000000007 Underflow Subnormal Inexact Rounded +emax347 toSci 1E-1000000008 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped emax348 toSci 1E-1000000007 -> 1E-1000000007 Subnormal emax349 toSci 1E-1000000000 -> 1E-1000000000 Subnormal emax350 toSci 1E-999999999 -> 1E-999999999 @@ -1103,7 +1201,7 @@ emax354 toSci 1.000E-999999999 -> 1.000E-999999999 emax355 toSci 1.000E+999999999 -> 1.000E+999999999 emax356 toSci 1.000E+1000000000 -> Infinity Overflow Inexact Rounded -emax357 toSci 1.001E-1000000008 -> 0E-1000000007 Underflow Subnormal Inexact Rounded +emax357 toSci 1.001E-1000000008 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped emax358 toSci 1.001E-1000000007 -> 1E-1000000007 Subnormal Inexact Rounded Underflow emax359 toSci 1.001E-1000000000 -> 1.001E-1000000000 Subnormal emax360 toSci 1.001E-999999999 -> 1.001E-999999999 @@ -1113,7 +1211,7 @@ emax364 toSci 9.000E-999999999 -> 9.000E-999999999 emax365 toSci 9.000E+999999999 -> 9.000E+999999999 emax366 toSci 9.000E+1000000000 -> Infinity Overflow Inexact Rounded -emax367 toSci 9.999E-1000000009 -> 0E-1000000007 Underflow Subnormal Inexact Rounded +emax367 toSci 9.999E-1000000009 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped emax368 toSci 9.999E-1000000008 -> 1E-1000000007 Underflow Subnormal Inexact Rounded emax369 toSci 9.999E-1000000007 -> 1.0E-1000000006 Underflow Subnormal Inexact Rounded emax370 toSci 9.999E-1000000000 -> 9.999E-1000000000 Subnormal @@ -1129,11 +1227,11 @@ emax379 toSci -1.000E-999999999 -> -1.000E-999999999 emax380 toSci -1.000E+999999999 -> -1.000E+999999999 emax381 toSci -1.000E+1000000000 -> -Infinity Overflow Inexact Rounded -emax382 toSci -1.001E-1000000008 -> -0E-1000000007 Underflow Subnormal Inexact Rounded +emax382 toSci -1.001E-1000000008 -> -0E-1000000007 Underflow Subnormal Inexact Rounded Clamped emax383 toSci -1.001E-999999999 -> -1.001E-999999999 emax384 toSci -1.001E+999999999 -> -1.001E+999999999 emax385 toSci -1.001E+1000000000 -> -Infinity Overflow Inexact Rounded -emax386 toSci -9.000E-1000000123 -> -0E-1000000007 Underflow Subnormal Inexact Rounded +emax386 toSci -9.000E-1000000123 -> -0E-1000000007 Underflow Subnormal Inexact Rounded Clamped emax387 toSci -9.000E-999999999 -> -9.000E-999999999 emax388 toSci -9.000E+999999999 -> -9.000E+999999999 emax389 toSci -9.000E+1000000000 -> -Infinity Overflow Inexact Rounded @@ -1168,11 +1266,11 @@ emax417 toSci 0.000250E-999 -> 2E-1003 Underflow Subnormal Inexact Rounded emax418 toSci 0.000251E-999 -> 3E-1003 Underflow Subnormal Inexact Rounded emax419 toSci 0.00009E-999 -> 1E-1003 Underflow Subnormal Inexact Rounded -emax420 toSci 0.00005E-999 -> 0E-1003 Underflow Subnormal Inexact Rounded -emax421 toSci 0.00003E-999 -> 0E-1003 Underflow Subnormal Inexact Rounded -emax422 toSci 0.000009E-999 -> 0E-1003 Underflow Subnormal Inexact Rounded -emax423 toSci 0.000005E-999 -> 0E-1003 Underflow Subnormal Inexact Rounded -emax424 toSci 0.000003E-999 -> 0E-1003 Underflow Subnormal Inexact Rounded +emax420 toSci 0.00005E-999 -> 0E-1003 Underflow Subnormal Inexact Rounded Clamped +emax421 toSci 0.00003E-999 -> 0E-1003 Underflow Subnormal Inexact Rounded Clamped +emax422 toSci 0.000009E-999 -> 0E-1003 Underflow Subnormal Inexact Rounded Clamped +emax423 toSci 0.000005E-999 -> 0E-1003 Underflow Subnormal Inexact Rounded Clamped +emax424 toSci 0.000003E-999 -> 0E-1003 Underflow Subnormal Inexact Rounded Clamped emax425 toSci 0.001049E-999 -> 1.0E-1002 Underflow Subnormal Inexact Rounded emax426 toSci 0.001050E-999 -> 1.0E-1002 Underflow Subnormal Inexact Rounded @@ -1223,9 +1321,9 @@ emax473 toSci 0.0099999E-999 -> 1.00E-1001 Underflow Subnormal Inexact Rounded emax474 toSci 0.00099999E-999 -> 1.0E-1002 Underflow Subnormal Inexact Rounded emax475 toSci 0.000099999E-999 -> 1E-1003 Underflow Subnormal Inexact Rounded -emax476 toSci 0.0000099999E-999 -> 0E-1003 Underflow Subnormal Inexact Rounded -emax477 toSci 0.00000099999E-999 -> 0E-1003 Underflow Subnormal Inexact Rounded -emax478 toSci 0.000000099999E-999 -> 0E-1003 Underflow Subnormal Inexact Rounded +emax476 toSci 0.0000099999E-999 -> 0E-1003 Underflow Subnormal Inexact Rounded Clamped +emax477 toSci 0.00000099999E-999 -> 0E-1003 Underflow Subnormal Inexact Rounded Clamped +emax478 toSci 0.000000099999E-999 -> 0E-1003 Underflow Subnormal Inexact Rounded Clamped -- Exponents with insignificant leading zeros precision: 16 @@ -1248,9 +1346,9 @@ basx1021 tosci 1e+2147483649 -> Infinity Overflow Inexact Rounded basx1022 tosci 1e+2147483648 -> Infinity Overflow Inexact Rounded basx1023 tosci 1e+2147483647 -> Infinity Overflow Inexact Rounded -basx1024 tosci 1e-2147483647 -> 0E-1000000014 Underflow Subnormal Inexact Rounded -basx1025 tosci 1e-2147483648 -> 0E-1000000014 Underflow Subnormal Inexact Rounded -basx1026 tosci 1e-2147483649 -> 0E-1000000014 Underflow Subnormal Inexact Rounded +basx1024 tosci 1e-2147483647 -> 0E-1000000014 Underflow Subnormal Inexact Rounded Clamped +basx1025 tosci 1e-2147483648 -> 0E-1000000014 Underflow Subnormal Inexact Rounded Clamped +basx1026 tosci 1e-2147483649 -> 0E-1000000014 Underflow Subnormal Inexact Rounded Clamped -- same unbalanced precision: 7 maxExponent: 96 @@ -1258,9 +1356,9 @@ basx1031 tosci 1e+2147483649 -> Infinity Overflow Inexact Rounded basx1032 tosci 1e+2147483648 -> Infinity Overflow Inexact Rounded basx1033 tosci 1e+2147483647 -> Infinity Overflow Inexact Rounded -basx1034 tosci 1e-2147483647 -> 0E-101 Underflow Subnormal Inexact Rounded -basx1035 tosci 1e-2147483648 -> 0E-101 Underflow Subnormal Inexact Rounded -basx1036 tosci 1e-2147483649 -> 0E-101 Underflow Subnormal Inexact Rounded +basx1034 tosci 1e-2147483647 -> 0E-101 Underflow Subnormal Inexact Rounded Clamped +basx1035 tosci 1e-2147483648 -> 0E-101 Underflow Subnormal Inexact Rounded Clamped +basx1036 tosci 1e-2147483649 -> 0E-101 Underflow Subnormal Inexact Rounded Clamped -- check for double-rounded subnormals precision: 5 @@ -1270,3 +1368,44 @@ basx1042 toSci 1.52445E-80 -> 1.524E-80 Inexact Rounded Subnormal Underflow basx1043 toSci 1.52446E-80 -> 1.524E-80 Inexact Rounded Subnormal Underflow +-- clamped zeros [see also clamp.decTest] +precision: 34 +maxExponent: 6144 +minExponent: -6143 + +basx1061 apply 0e+10000 -> 0E+6144 Clamped +basx1062 apply 0e-10000 -> 0E-6176 Clamped +basx1063 apply -0e+10000 -> -0E+6144 Clamped +basx1064 apply -0e-10000 -> -0E-6176 Clamped + +precision: 16 +maxExponent: 384 +minExponent: -383 + +basx1065 apply 0e+10000 -> 0E+384 Clamped +basx1066 apply 0e-10000 -> 0E-398 Clamped +basx1067 apply -0e+10000 -> -0E+384 Clamped +basx1068 apply -0e-10000 -> -0E-398 Clamped + +-- same with IEEE clamping +clamp: 1 + +precision: 34 +maxExponent: 6144 +minExponent: -6143 + +basx1071 apply 0e+10000 -> 0E+6111 Clamped +basx1072 apply 0e-10000 -> 0E-6176 Clamped +basx1073 apply -0e+10000 -> -0E+6111 Clamped +basx1074 apply -0e-10000 -> -0E-6176 Clamped + +precision: 16 +maxExponent: 384 +minExponent: -383 + +basx1075 apply 0e+10000 -> 0E+369 Clamped +basx1076 apply 0e-10000 -> 0E-398 Clamped +basx1077 apply -0e+10000 -> -0E+369 Clamped +basx1078 apply -0e-10000 -> -0E-398 Clamped + + Modified: python/branches/release25-maint/Lib/test/decimaltestdata/clamp.decTest ============================================================================== --- python/branches/release25-maint/Lib/test/decimaltestdata/clamp.decTest (original) +++ python/branches/release25-maint/Lib/test/decimaltestdata/clamp.decTest Tue Jan 8 17:20:31 2008 @@ -1,6 +1,6 @@ ------------------------------------------------------------------------ -- clamp.decTest -- clamped exponent tests (format-independent) -- --- Copyright (c) IBM Corporation, 2000, 2003. All rights reserved. -- +-- Copyright (c) IBM Corporation, 2000, 2007. All rights reserved. -- ------------------------------------------------------------------------ -- Please see the document "General Decimal Arithmetic Testcases" -- -- at http://www2.hursley.ibm.com/decimal for the description of -- @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc at uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.39 +version: 2.57 -- This set of tests uses the same limits as the 8-byte concrete -- representation, but applies clamping without using format-specific @@ -73,10 +73,10 @@ clam093 apply 1.00000000001e-398 -> #0000000000000001 Subnormal Underflow Inexact Rounded clam094 apply 1.00000000000001e-398 -> #0000000000000001 Subnormal Underflow Inexact Rounded clam095 apply 1.000000000000001e-398 -> #0000000000000001 Subnormal Underflow Inexact Rounded -clam096 apply 0.1e-398 -> #0000000000000000 Subnormal Underflow Inexact Rounded -clam097 apply 0.00000000001e-398 -> #0000000000000000 Subnormal Underflow Inexact Rounded -clam098 apply 0.00000000000001e-398 -> #0000000000000000 Subnormal Underflow Inexact Rounded -clam099 apply 0.000000000000001e-398 -> #0000000000000000 Subnormal Underflow Inexact Rounded +clam096 apply 0.1e-398 -> #0000000000000000 Subnormal Underflow Inexact Rounded Clamped +clam097 apply 0.00000000001e-398 -> #0000000000000000 Subnormal Underflow Inexact Rounded Clamped +clam098 apply 0.00000000000001e-398 -> #0000000000000000 Subnormal Underflow Inexact Rounded Clamped +clam099 apply 0.000000000000001e-398 -> #0000000000000000 Subnormal Underflow Inexact Rounded Clamped -- Same again, negatives -- Nmax and similar @@ -112,10 +112,10 @@ clam193 apply -1.00000000001e-398 -> #8000000000000001 Subnormal Underflow Inexact Rounded clam194 apply -1.00000000000001e-398 -> #8000000000000001 Subnormal Underflow Inexact Rounded clam195 apply -1.000000000000001e-398 -> #8000000000000001 Subnormal Underflow Inexact Rounded -clam196 apply -0.1e-398 -> #8000000000000000 Subnormal Underflow Inexact Rounded -clam197 apply -0.00000000001e-398 -> #8000000000000000 Subnormal Underflow Inexact Rounded -clam198 apply -0.00000000000001e-398 -> #8000000000000000 Subnormal Underflow Inexact Rounded -clam199 apply -0.000000000000001e-398 -> #8000000000000000 Subnormal Underflow Inexact Rounded +clam196 apply -0.1e-398 -> #8000000000000000 Subnormal Underflow Inexact Rounded Clamped +clam197 apply -0.00000000001e-398 -> #8000000000000000 Subnormal Underflow Inexact Rounded Clamped +clam198 apply -0.00000000000001e-398 -> #8000000000000000 Subnormal Underflow Inexact Rounded Clamped +clam199 apply -0.000000000000001e-398 -> #8000000000000000 Subnormal Underflow Inexact Rounded Clamped -- zeros clam401 apply 0E-500 -> 0E-398 Clamped @@ -184,6 +184,20 @@ clam671 apply 9E+369 -> 9E+369 clam673 apply 9E+368 -> 9E+368 +-- subnormals clamped to 0-Etiny +precision: 16 +maxExponent: 384 +minExponent: -383 +clam681 apply 7E-398 -> 7E-398 Subnormal +clam682 apply 0E-398 -> 0E-398 +clam683 apply 7E-399 -> 1E-398 Subnormal Underflow Inexact Rounded +clam684 apply 4E-399 -> 0E-398 Clamped Subnormal Underflow Inexact Rounded +clam685 apply 7E-400 -> 0E-398 Clamped Subnormal Underflow Inexact Rounded +clam686 apply 7E-401 -> 0E-398 Clamped Subnormal Underflow Inexact Rounded +clam687 apply 0E-399 -> 0E-398 Clamped +clam688 apply 0E-400 -> 0E-398 Clamped +clam689 apply 0E-401 -> 0E-398 Clamped + -- example from documentation precision: 7 rounding: half_even Added: python/branches/release25-maint/Lib/test/decimaltestdata/class.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/class.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,131 @@ +------------------------------------------------------------------------ +-- class.decTest -- Class operations -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- [New 2006.11.27] + +precision: 9 +maxExponent: 999 +minExponent: -999 +extended: 1 +clamp: 1 +rounding: half_even + +clasx001 class 0 -> +Zero +clasx002 class 0.00 -> +Zero +clasx003 class 0E+5 -> +Zero +clasx004 class 1E-1007 -> +Subnormal +clasx005 class 0.1E-999 -> +Subnormal +clasx006 class 0.99999999E-999 -> +Subnormal +clasx007 class 1.00000000E-999 -> +Normal +clasx008 class 1E-999 -> +Normal +clasx009 class 1E-100 -> +Normal +clasx010 class 1E-10 -> +Normal +clasx012 class 1E-1 -> +Normal +clasx013 class 1 -> +Normal +clasx014 class 2.50 -> +Normal +clasx015 class 100.100 -> +Normal +clasx016 class 1E+30 -> +Normal +clasx017 class 1E+999 -> +Normal +clasx018 class 9.99999999E+999 -> +Normal +clasx019 class Inf -> +Infinity + +clasx021 class -0 -> -Zero +clasx022 class -0.00 -> -Zero +clasx023 class -0E+5 -> -Zero +clasx024 class -1E-1007 -> -Subnormal +clasx025 class -0.1E-999 -> -Subnormal +clasx026 class -0.99999999E-999 -> -Subnormal +clasx027 class -1.00000000E-999 -> -Normal +clasx028 class -1E-999 -> -Normal +clasx029 class -1E-100 -> -Normal +clasx030 class -1E-10 -> -Normal +clasx032 class -1E-1 -> -Normal +clasx033 class -1 -> -Normal +clasx034 class -2.50 -> -Normal +clasx035 class -100.100 -> -Normal +clasx036 class -1E+30 -> -Normal +clasx037 class -1E+999 -> -Normal +clasx038 class -9.99999999E+999 -> -Normal +clasx039 class -Inf -> -Infinity + +clasx041 class NaN -> NaN +clasx042 class -NaN -> NaN +clasx043 class +NaN12345 -> NaN +clasx044 class sNaN -> sNaN +clasx045 class -sNaN -> sNaN +clasx046 class +sNaN12345 -> sNaN + + +-- decimal64 bounds + +precision: 16 +maxExponent: 384 +minExponent: -383 +clamp: 1 +rounding: half_even + +clasx201 class 0 -> +Zero +clasx202 class 0.00 -> +Zero +clasx203 class 0E+5 -> +Zero +clasx204 class 1E-396 -> +Subnormal +clasx205 class 0.1E-383 -> +Subnormal +clasx206 class 0.999999999999999E-383 -> +Subnormal +clasx207 class 1.000000000000000E-383 -> +Normal +clasx208 class 1E-383 -> +Normal +clasx209 class 1E-100 -> +Normal +clasx210 class 1E-10 -> +Normal +clasx212 class 1E-1 -> +Normal +clasx213 class 1 -> +Normal +clasx214 class 2.50 -> +Normal +clasx215 class 100.100 -> +Normal +clasx216 class 1E+30 -> +Normal +clasx217 class 1E+384 -> +Normal +clasx218 class 9.999999999999999E+384 -> +Normal +clasx219 class Inf -> +Infinity + +clasx221 class -0 -> -Zero +clasx222 class -0.00 -> -Zero +clasx223 class -0E+5 -> -Zero +clasx224 class -1E-396 -> -Subnormal +clasx225 class -0.1E-383 -> -Subnormal +clasx226 class -0.999999999999999E-383 -> -Subnormal +clasx227 class -1.000000000000000E-383 -> -Normal +clasx228 class -1E-383 -> -Normal +clasx229 class -1E-100 -> -Normal +clasx230 class -1E-10 -> -Normal +clasx232 class -1E-1 -> -Normal +clasx233 class -1 -> -Normal +clasx234 class -2.50 -> -Normal +clasx235 class -100.100 -> -Normal +clasx236 class -1E+30 -> -Normal +clasx237 class -1E+384 -> -Normal +clasx238 class -9.999999999999999E+384 -> -Normal +clasx239 class -Inf -> -Infinity + +clasx241 class NaN -> NaN +clasx242 class -NaN -> NaN +clasx243 class +NaN12345 -> NaN +clasx244 class sNaN -> sNaN +clasx245 class -sNaN -> sNaN +clasx246 class +sNaN12345 -> sNaN + + + Modified: python/branches/release25-maint/Lib/test/decimaltestdata/compare.decTest ============================================================================== --- python/branches/release25-maint/Lib/test/decimaltestdata/compare.decTest (original) +++ python/branches/release25-maint/Lib/test/decimaltestdata/compare.decTest Tue Jan 8 17:20:31 2008 @@ -1,6 +1,6 @@ ------------------------------------------------------------------------ --- compare.decTest -- decimal comparison -- --- Copyright (c) IBM Corporation, 1981, 2003. All rights reserved. -- +-- compare.decTest -- decimal comparison that allows quiet NaNs -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- ------------------------------------------------------------------------ -- Please see the document "General Decimal Arithmetic Testcases" -- -- at http://www2.hursley.ibm.com/decimal for the description of -- @@ -17,11 +17,11 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc at uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.39 +version: 2.57 -- Note that we cannot assume add/subtract tests cover paths adequately, -- here, because the code might be quite different (comparison cannot --- overflow or underflow, so actual subtractions are not necesary). +-- overflow or underflow, so actual subtractions are not necessary). extended: 1 @@ -112,10 +112,10 @@ -- now some cases which might overflow if subtract were used maxexponent: 999999999 minexponent: -999999999 -comx090 compare 9.99999999E+999999999 9.99999999E+999999999 -> 0 -comx091 compare -9.99999999E+999999999 9.99999999E+999999999 -> -1 -comx092 compare 9.99999999E+999999999 -9.99999999E+999999999 -> 1 -comx093 compare -9.99999999E+999999999 -9.99999999E+999999999 -> 0 +comx095 compare 9.99999999E+999999999 9.99999999E+999999999 -> 0 +comx096 compare -9.99999999E+999999999 9.99999999E+999999999 -> -1 +comx097 compare 9.99999999E+999999999 -9.99999999E+999999999 -> 1 +comx098 compare -9.99999999E+999999999 -9.99999999E+999999999 -> 0 -- some differing length/exponent cases comx100 compare 7.0 7.0 -> 0 @@ -265,6 +265,21 @@ comx449 compare -8 -.9E+1 -> 1 comx450 compare -8 -90E-1 -> 1 +-- misalignment traps for little-endian +comx451 compare 1.0 0.1 -> 1 +comx452 compare 0.1 1.0 -> -1 +comx453 compare 10.0 0.1 -> 1 +comx454 compare 0.1 10.0 -> -1 +comx455 compare 100 1.0 -> 1 +comx456 compare 1.0 100 -> -1 +comx457 compare 1000 10.0 -> 1 +comx458 compare 10.0 1000 -> -1 +comx459 compare 10000 100.0 -> 1 +comx460 compare 100.0 10000 -> -1 +comx461 compare 100000 1000.0 -> 1 +comx462 compare 1000.0 100000 -> -1 +comx463 compare 1000000 10000.0 -> 1 +comx464 compare 10000.0 1000000 -> -1 -- testcases that subtract to lots of zeros at boundaries [pgr] precision: 40 @@ -362,7 +377,7 @@ comx569 compare 1E+13 1 -> 1 comx570 compare 1E+14 1 -> 1 comx571 compare 1E+15 1 -> 1 --- similar with an useful coefficient, one side only +-- similar with a useful coefficient, one side only comx580 compare 0.000000987654321 1E-15 -> 1 comx581 compare 0.000000987654321 1E-14 -> 1 comx582 compare 0.000000987654321 1E-13 -> 1 @@ -712,6 +727,32 @@ comx907 compare -1e-777777777 1e-411111111 -> -1 comx908 compare -1e-777777777 -1e-411111111 -> 1 +-- spread zeros +comx910 compare 0E-383 0 -> 0 +comx911 compare 0E-383 -0 -> 0 +comx912 compare -0E-383 0 -> 0 +comx913 compare -0E-383 -0 -> 0 +comx914 compare 0E-383 0E+384 -> 0 +comx915 compare 0E-383 -0E+384 -> 0 +comx916 compare -0E-383 0E+384 -> 0 +comx917 compare -0E-383 -0E+384 -> 0 +comx918 compare 0 0E+384 -> 0 +comx919 compare 0 -0E+384 -> 0 +comx920 compare -0 0E+384 -> 0 +comx921 compare -0 -0E+384 -> 0 +comx930 compare 0E+384 0 -> 0 +comx931 compare 0E+384 -0 -> 0 +comx932 compare -0E+384 0 -> 0 +comx933 compare -0E+384 -0 -> 0 +comx934 compare 0E+384 0E-383 -> 0 +comx935 compare 0E+384 -0E-383 -> 0 +comx936 compare -0E+384 0E-383 -> 0 +comx937 compare -0E+384 -0E-383 -> 0 +comx938 compare 0 0E-383 -> 0 +comx939 compare 0 -0E-383 -> 0 +comx940 compare -0 0E-383 -> 0 +comx941 compare -0 -0E-383 -> 0 + -- Null tests comx990 compare 10 # -> NaN Invalid_operation comx991 compare # 10 -> NaN Invalid_operation Added: python/branches/release25-maint/Lib/test/decimaltestdata/comparetotal.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/comparetotal.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,798 @@ +------------------------------------------------------------------------ +-- comparetotal.decTest -- decimal comparison using total ordering -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- Note that we cannot assume add/subtract tests cover paths adequately, +-- here, because the code might be quite different (comparison cannot +-- overflow or underflow, so actual subtractions are not necessary). +-- Similarly, comparetotal will have some radically different paths +-- than compare. + +extended: 1 +precision: 16 +rounding: half_up +maxExponent: 384 +minExponent: -383 + +-- sanity checks +cotx001 comparetotal -2 -2 -> 0 +cotx002 comparetotal -2 -1 -> -1 +cotx003 comparetotal -2 0 -> -1 +cotx004 comparetotal -2 1 -> -1 +cotx005 comparetotal -2 2 -> -1 +cotx006 comparetotal -1 -2 -> 1 +cotx007 comparetotal -1 -1 -> 0 +cotx008 comparetotal -1 0 -> -1 +cotx009 comparetotal -1 1 -> -1 +cotx010 comparetotal -1 2 -> -1 +cotx011 comparetotal 0 -2 -> 1 +cotx012 comparetotal 0 -1 -> 1 +cotx013 comparetotal 0 0 -> 0 +cotx014 comparetotal 0 1 -> -1 +cotx015 comparetotal 0 2 -> -1 +cotx016 comparetotal 1 -2 -> 1 +cotx017 comparetotal 1 -1 -> 1 +cotx018 comparetotal 1 0 -> 1 +cotx019 comparetotal 1 1 -> 0 +cotx020 comparetotal 1 2 -> -1 +cotx021 comparetotal 2 -2 -> 1 +cotx022 comparetotal 2 -1 -> 1 +cotx023 comparetotal 2 0 -> 1 +cotx025 comparetotal 2 1 -> 1 +cotx026 comparetotal 2 2 -> 0 + +cotx031 comparetotal -20 -20 -> 0 +cotx032 comparetotal -20 -10 -> -1 +cotx033 comparetotal -20 00 -> -1 +cotx034 comparetotal -20 10 -> -1 +cotx035 comparetotal -20 20 -> -1 +cotx036 comparetotal -10 -20 -> 1 +cotx037 comparetotal -10 -10 -> 0 +cotx038 comparetotal -10 00 -> -1 +cotx039 comparetotal -10 10 -> -1 +cotx040 comparetotal -10 20 -> -1 +cotx041 comparetotal 00 -20 -> 1 +cotx042 comparetotal 00 -10 -> 1 +cotx043 comparetotal 00 00 -> 0 +cotx044 comparetotal 00 10 -> -1 +cotx045 comparetotal 00 20 -> -1 +cotx046 comparetotal 10 -20 -> 1 +cotx047 comparetotal 10 -10 -> 1 +cotx048 comparetotal 10 00 -> 1 +cotx049 comparetotal 10 10 -> 0 +cotx050 comparetotal 10 20 -> -1 +cotx051 comparetotal 20 -20 -> 1 +cotx052 comparetotal 20 -10 -> 1 +cotx053 comparetotal 20 00 -> 1 +cotx055 comparetotal 20 10 -> 1 +cotx056 comparetotal 20 20 -> 0 + +cotx061 comparetotal -2.0 -2.0 -> 0 +cotx062 comparetotal -2.0 -1.0 -> -1 +cotx063 comparetotal -2.0 0.0 -> -1 +cotx064 comparetotal -2.0 1.0 -> -1 +cotx065 comparetotal -2.0 2.0 -> -1 +cotx066 comparetotal -1.0 -2.0 -> 1 +cotx067 comparetotal -1.0 -1.0 -> 0 +cotx068 comparetotal -1.0 0.0 -> -1 +cotx069 comparetotal -1.0 1.0 -> -1 +cotx070 comparetotal -1.0 2.0 -> -1 +cotx071 comparetotal 0.0 -2.0 -> 1 +cotx072 comparetotal 0.0 -1.0 -> 1 +cotx073 comparetotal 0.0 0.0 -> 0 +cotx074 comparetotal 0.0 1.0 -> -1 +cotx075 comparetotal 0.0 2.0 -> -1 +cotx076 comparetotal 1.0 -2.0 -> 1 +cotx077 comparetotal 1.0 -1.0 -> 1 +cotx078 comparetotal 1.0 0.0 -> 1 +cotx079 comparetotal 1.0 1.0 -> 0 +cotx080 comparetotal 1.0 2.0 -> -1 +cotx081 comparetotal 2.0 -2.0 -> 1 +cotx082 comparetotal 2.0 -1.0 -> 1 +cotx083 comparetotal 2.0 0.0 -> 1 +cotx085 comparetotal 2.0 1.0 -> 1 +cotx086 comparetotal 2.0 2.0 -> 0 + +-- now some cases which might overflow if subtract were used +maxexponent: 999999999 +minexponent: -999999999 +cotx090 comparetotal 9.99999999E+999999999 9.99999999E+999999999 -> 0 +cotx091 comparetotal -9.99999999E+999999999 9.99999999E+999999999 -> -1 +cotx092 comparetotal 9.99999999E+999999999 -9.99999999E+999999999 -> 1 +cotx093 comparetotal -9.99999999E+999999999 -9.99999999E+999999999 -> 0 + +-- Examples +cotx094 comparetotal 12.73 127.9 -> -1 +cotx095 comparetotal -127 12 -> -1 +cotx096 comparetotal 12.30 12.3 -> -1 +cotx097 comparetotal 12.30 12.30 -> 0 +cotx098 comparetotal 12.3 12.300 -> 1 +cotx099 comparetotal 12.3 NaN -> -1 + +-- some differing length/exponent cases +-- in this first group, compare would compare all equal +cotx100 comparetotal 7.0 7.0 -> 0 +cotx101 comparetotal 7.0 7 -> -1 +cotx102 comparetotal 7 7.0 -> 1 +cotx103 comparetotal 7E+0 7.0 -> 1 +cotx104 comparetotal 70E-1 7.0 -> 0 +cotx105 comparetotal 0.7E+1 7 -> 0 +cotx106 comparetotal 70E-1 7 -> -1 +cotx107 comparetotal 7.0 7E+0 -> -1 +cotx108 comparetotal 7.0 70E-1 -> 0 +cotx109 comparetotal 7 0.7E+1 -> 0 +cotx110 comparetotal 7 70E-1 -> 1 + +cotx120 comparetotal 8.0 7.0 -> 1 +cotx121 comparetotal 8.0 7 -> 1 +cotx122 comparetotal 8 7.0 -> 1 +cotx123 comparetotal 8E+0 7.0 -> 1 +cotx124 comparetotal 80E-1 7.0 -> 1 +cotx125 comparetotal 0.8E+1 7 -> 1 +cotx126 comparetotal 80E-1 7 -> 1 +cotx127 comparetotal 8.0 7E+0 -> 1 +cotx128 comparetotal 8.0 70E-1 -> 1 +cotx129 comparetotal 8 0.7E+1 -> 1 +cotx130 comparetotal 8 70E-1 -> 1 + +cotx140 comparetotal 8.0 9.0 -> -1 +cotx141 comparetotal 8.0 9 -> -1 +cotx142 comparetotal 8 9.0 -> -1 +cotx143 comparetotal 8E+0 9.0 -> -1 +cotx144 comparetotal 80E-1 9.0 -> -1 +cotx145 comparetotal 0.8E+1 9 -> -1 +cotx146 comparetotal 80E-1 9 -> -1 +cotx147 comparetotal 8.0 9E+0 -> -1 +cotx148 comparetotal 8.0 90E-1 -> -1 +cotx149 comparetotal 8 0.9E+1 -> -1 +cotx150 comparetotal 8 90E-1 -> -1 + +-- and again, with sign changes -+ .. +cotx200 comparetotal -7.0 7.0 -> -1 +cotx201 comparetotal -7.0 7 -> -1 +cotx202 comparetotal -7 7.0 -> -1 +cotx203 comparetotal -7E+0 7.0 -> -1 +cotx204 comparetotal -70E-1 7.0 -> -1 +cotx205 comparetotal -0.7E+1 7 -> -1 +cotx206 comparetotal -70E-1 7 -> -1 +cotx207 comparetotal -7.0 7E+0 -> -1 +cotx208 comparetotal -7.0 70E-1 -> -1 +cotx209 comparetotal -7 0.7E+1 -> -1 +cotx210 comparetotal -7 70E-1 -> -1 + +cotx220 comparetotal -8.0 7.0 -> -1 +cotx221 comparetotal -8.0 7 -> -1 +cotx222 comparetotal -8 7.0 -> -1 +cotx223 comparetotal -8E+0 7.0 -> -1 +cotx224 comparetotal -80E-1 7.0 -> -1 +cotx225 comparetotal -0.8E+1 7 -> -1 +cotx226 comparetotal -80E-1 7 -> -1 +cotx227 comparetotal -8.0 7E+0 -> -1 +cotx228 comparetotal -8.0 70E-1 -> -1 +cotx229 comparetotal -8 0.7E+1 -> -1 +cotx230 comparetotal -8 70E-1 -> -1 + +cotx240 comparetotal -8.0 9.0 -> -1 +cotx241 comparetotal -8.0 9 -> -1 +cotx242 comparetotal -8 9.0 -> -1 +cotx243 comparetotal -8E+0 9.0 -> -1 +cotx244 comparetotal -80E-1 9.0 -> -1 +cotx245 comparetotal -0.8E+1 9 -> -1 +cotx246 comparetotal -80E-1 9 -> -1 +cotx247 comparetotal -8.0 9E+0 -> -1 +cotx248 comparetotal -8.0 90E-1 -> -1 +cotx249 comparetotal -8 0.9E+1 -> -1 +cotx250 comparetotal -8 90E-1 -> -1 + +-- and again, with sign changes +- .. +cotx300 comparetotal 7.0 -7.0 -> 1 +cotx301 comparetotal 7.0 -7 -> 1 +cotx302 comparetotal 7 -7.0 -> 1 +cotx303 comparetotal 7E+0 -7.0 -> 1 +cotx304 comparetotal 70E-1 -7.0 -> 1 +cotx305 comparetotal .7E+1 -7 -> 1 +cotx306 comparetotal 70E-1 -7 -> 1 +cotx307 comparetotal 7.0 -7E+0 -> 1 +cotx308 comparetotal 7.0 -70E-1 -> 1 +cotx309 comparetotal 7 -.7E+1 -> 1 +cotx310 comparetotal 7 -70E-1 -> 1 + +cotx320 comparetotal 8.0 -7.0 -> 1 +cotx321 comparetotal 8.0 -7 -> 1 +cotx322 comparetotal 8 -7.0 -> 1 +cotx323 comparetotal 8E+0 -7.0 -> 1 +cotx324 comparetotal 80E-1 -7.0 -> 1 +cotx325 comparetotal .8E+1 -7 -> 1 +cotx326 comparetotal 80E-1 -7 -> 1 +cotx327 comparetotal 8.0 -7E+0 -> 1 +cotx328 comparetotal 8.0 -70E-1 -> 1 +cotx329 comparetotal 8 -.7E+1 -> 1 +cotx330 comparetotal 8 -70E-1 -> 1 + +cotx340 comparetotal 8.0 -9.0 -> 1 +cotx341 comparetotal 8.0 -9 -> 1 +cotx342 comparetotal 8 -9.0 -> 1 +cotx343 comparetotal 8E+0 -9.0 -> 1 +cotx344 comparetotal 80E-1 -9.0 -> 1 +cotx345 comparetotal .8E+1 -9 -> 1 +cotx346 comparetotal 80E-1 -9 -> 1 +cotx347 comparetotal 8.0 -9E+0 -> 1 +cotx348 comparetotal 8.0 -90E-1 -> 1 +cotx349 comparetotal 8 -.9E+1 -> 1 +cotx350 comparetotal 8 -90E-1 -> 1 + +-- and again, with sign changes -- .. +cotx400 comparetotal -7.0 -7.0 -> 0 +cotx401 comparetotal -7.0 -7 -> 1 +cotx402 comparetotal -7 -7.0 -> -1 +cotx403 comparetotal -7E+0 -7.0 -> -1 +cotx404 comparetotal -70E-1 -7.0 -> 0 +cotx405 comparetotal -.7E+1 -7 -> 0 +cotx406 comparetotal -70E-1 -7 -> 1 +cotx407 comparetotal -7.0 -7E+0 -> 1 +cotx408 comparetotal -7.0 -70E-1 -> 0 +cotx409 comparetotal -7 -.7E+1 -> 0 +cotx410 comparetotal -7 -70E-1 -> -1 + +cotx420 comparetotal -8.0 -7.0 -> -1 +cotx421 comparetotal -8.0 -7 -> -1 +cotx422 comparetotal -8 -7.0 -> -1 +cotx423 comparetotal -8E+0 -7.0 -> -1 +cotx424 comparetotal -80E-1 -7.0 -> -1 +cotx425 comparetotal -.8E+1 -7 -> -1 +cotx426 comparetotal -80E-1 -7 -> -1 +cotx427 comparetotal -8.0 -7E+0 -> -1 +cotx428 comparetotal -8.0 -70E-1 -> -1 +cotx429 comparetotal -8 -.7E+1 -> -1 +cotx430 comparetotal -8 -70E-1 -> -1 + +cotx440 comparetotal -8.0 -9.0 -> 1 +cotx441 comparetotal -8.0 -9 -> 1 +cotx442 comparetotal -8 -9.0 -> 1 +cotx443 comparetotal -8E+0 -9.0 -> 1 +cotx444 comparetotal -80E-1 -9.0 -> 1 +cotx445 comparetotal -.8E+1 -9 -> 1 +cotx446 comparetotal -80E-1 -9 -> 1 +cotx447 comparetotal -8.0 -9E+0 -> 1 +cotx448 comparetotal -8.0 -90E-1 -> 1 +cotx449 comparetotal -8 -.9E+1 -> 1 +cotx450 comparetotal -8 -90E-1 -> 1 + + +-- testcases that subtract to lots of zeros at boundaries [pgr] +precision: 40 +cotx470 comparetotal 123.4560000000000000E789 123.456E789 -> -1 +cotx471 comparetotal 123.456000000000000E-89 123.456E-89 -> -1 +cotx472 comparetotal 123.45600000000000E789 123.456E789 -> -1 +cotx473 comparetotal 123.4560000000000E-89 123.456E-89 -> -1 +cotx474 comparetotal 123.456000000000E789 123.456E789 -> -1 +cotx475 comparetotal 123.45600000000E-89 123.456E-89 -> -1 +cotx476 comparetotal 123.4560000000E789 123.456E789 -> -1 +cotx477 comparetotal 123.456000000E-89 123.456E-89 -> -1 +cotx478 comparetotal 123.45600000E789 123.456E789 -> -1 +cotx479 comparetotal 123.4560000E-89 123.456E-89 -> -1 +cotx480 comparetotal 123.456000E789 123.456E789 -> -1 +cotx481 comparetotal 123.45600E-89 123.456E-89 -> -1 +cotx482 comparetotal 123.4560E789 123.456E789 -> -1 +cotx483 comparetotal 123.456E-89 123.456E-89 -> 0 +cotx484 comparetotal 123.456E-89 123.4560000000000000E-89 -> 1 +cotx485 comparetotal 123.456E789 123.456000000000000E789 -> 1 +cotx486 comparetotal 123.456E-89 123.45600000000000E-89 -> 1 +cotx487 comparetotal 123.456E789 123.4560000000000E789 -> 1 +cotx488 comparetotal 123.456E-89 123.456000000000E-89 -> 1 +cotx489 comparetotal 123.456E789 123.45600000000E789 -> 1 +cotx490 comparetotal 123.456E-89 123.4560000000E-89 -> 1 +cotx491 comparetotal 123.456E789 123.456000000E789 -> 1 +cotx492 comparetotal 123.456E-89 123.45600000E-89 -> 1 +cotx493 comparetotal 123.456E789 123.4560000E789 -> 1 +cotx494 comparetotal 123.456E-89 123.456000E-89 -> 1 +cotx495 comparetotal 123.456E789 123.45600E789 -> 1 +cotx496 comparetotal 123.456E-89 123.4560E-89 -> 1 +cotx497 comparetotal 123.456E789 123.456E789 -> 0 + +-- wide-ranging, around precision; signs equal +precision: 9 +cotx500 comparetotal 1 1E-15 -> 1 +cotx501 comparetotal 1 1E-14 -> 1 +cotx502 comparetotal 1 1E-13 -> 1 +cotx503 comparetotal 1 1E-12 -> 1 +cotx504 comparetotal 1 1E-11 -> 1 +cotx505 comparetotal 1 1E-10 -> 1 +cotx506 comparetotal 1 1E-9 -> 1 +cotx507 comparetotal 1 1E-8 -> 1 +cotx508 comparetotal 1 1E-7 -> 1 +cotx509 comparetotal 1 1E-6 -> 1 +cotx510 comparetotal 1 1E-5 -> 1 +cotx511 comparetotal 1 1E-4 -> 1 +cotx512 comparetotal 1 1E-3 -> 1 +cotx513 comparetotal 1 1E-2 -> 1 +cotx514 comparetotal 1 1E-1 -> 1 +cotx515 comparetotal 1 1E-0 -> 0 +cotx516 comparetotal 1 1E+1 -> -1 +cotx517 comparetotal 1 1E+2 -> -1 +cotx518 comparetotal 1 1E+3 -> -1 +cotx519 comparetotal 1 1E+4 -> -1 +cotx521 comparetotal 1 1E+5 -> -1 +cotx522 comparetotal 1 1E+6 -> -1 +cotx523 comparetotal 1 1E+7 -> -1 +cotx524 comparetotal 1 1E+8 -> -1 +cotx525 comparetotal 1 1E+9 -> -1 +cotx526 comparetotal 1 1E+10 -> -1 +cotx527 comparetotal 1 1E+11 -> -1 +cotx528 comparetotal 1 1E+12 -> -1 +cotx529 comparetotal 1 1E+13 -> -1 +cotx530 comparetotal 1 1E+14 -> -1 +cotx531 comparetotal 1 1E+15 -> -1 +-- LR swap +cotx540 comparetotal 1E-15 1 -> -1 +cotx541 comparetotal 1E-14 1 -> -1 +cotx542 comparetotal 1E-13 1 -> -1 +cotx543 comparetotal 1E-12 1 -> -1 +cotx544 comparetotal 1E-11 1 -> -1 +cotx545 comparetotal 1E-10 1 -> -1 +cotx546 comparetotal 1E-9 1 -> -1 +cotx547 comparetotal 1E-8 1 -> -1 +cotx548 comparetotal 1E-7 1 -> -1 +cotx549 comparetotal 1E-6 1 -> -1 +cotx550 comparetotal 1E-5 1 -> -1 +cotx551 comparetotal 1E-4 1 -> -1 +cotx552 comparetotal 1E-3 1 -> -1 +cotx553 comparetotal 1E-2 1 -> -1 +cotx554 comparetotal 1E-1 1 -> -1 +cotx555 comparetotal 1E-0 1 -> 0 +cotx556 comparetotal 1E+1 1 -> 1 +cotx557 comparetotal 1E+2 1 -> 1 +cotx558 comparetotal 1E+3 1 -> 1 +cotx559 comparetotal 1E+4 1 -> 1 +cotx561 comparetotal 1E+5 1 -> 1 +cotx562 comparetotal 1E+6 1 -> 1 +cotx563 comparetotal 1E+7 1 -> 1 +cotx564 comparetotal 1E+8 1 -> 1 +cotx565 comparetotal 1E+9 1 -> 1 +cotx566 comparetotal 1E+10 1 -> 1 +cotx567 comparetotal 1E+11 1 -> 1 +cotx568 comparetotal 1E+12 1 -> 1 +cotx569 comparetotal 1E+13 1 -> 1 +cotx570 comparetotal 1E+14 1 -> 1 +cotx571 comparetotal 1E+15 1 -> 1 +-- similar with an useful coefficient, one side only +cotx580 comparetotal 0.000000987654321 1E-15 -> 1 +cotx581 comparetotal 0.000000987654321 1E-14 -> 1 +cotx582 comparetotal 0.000000987654321 1E-13 -> 1 +cotx583 comparetotal 0.000000987654321 1E-12 -> 1 +cotx584 comparetotal 0.000000987654321 1E-11 -> 1 +cotx585 comparetotal 0.000000987654321 1E-10 -> 1 +cotx586 comparetotal 0.000000987654321 1E-9 -> 1 +cotx587 comparetotal 0.000000987654321 1E-8 -> 1 +cotx588 comparetotal 0.000000987654321 1E-7 -> 1 +cotx589 comparetotal 0.000000987654321 1E-6 -> -1 +cotx590 comparetotal 0.000000987654321 1E-5 -> -1 +cotx591 comparetotal 0.000000987654321 1E-4 -> -1 +cotx592 comparetotal 0.000000987654321 1E-3 -> -1 +cotx593 comparetotal 0.000000987654321 1E-2 -> -1 +cotx594 comparetotal 0.000000987654321 1E-1 -> -1 +cotx595 comparetotal 0.000000987654321 1E-0 -> -1 +cotx596 comparetotal 0.000000987654321 1E+1 -> -1 +cotx597 comparetotal 0.000000987654321 1E+2 -> -1 +cotx598 comparetotal 0.000000987654321 1E+3 -> -1 +cotx599 comparetotal 0.000000987654321 1E+4 -> -1 + +-- check some unit-y traps +precision: 20 +cotx600 comparetotal 12 12.2345 -> -1 +cotx601 comparetotal 12.0 12.2345 -> -1 +cotx602 comparetotal 12.00 12.2345 -> -1 +cotx603 comparetotal 12.000 12.2345 -> -1 +cotx604 comparetotal 12.0000 12.2345 -> -1 +cotx605 comparetotal 12.00000 12.2345 -> -1 +cotx606 comparetotal 12.000000 12.2345 -> -1 +cotx607 comparetotal 12.0000000 12.2345 -> -1 +cotx608 comparetotal 12.00000000 12.2345 -> -1 +cotx609 comparetotal 12.000000000 12.2345 -> -1 +cotx610 comparetotal 12.1234 12 -> 1 +cotx611 comparetotal 12.1234 12.0 -> 1 +cotx612 comparetotal 12.1234 12.00 -> 1 +cotx613 comparetotal 12.1234 12.000 -> 1 +cotx614 comparetotal 12.1234 12.0000 -> 1 +cotx615 comparetotal 12.1234 12.00000 -> 1 +cotx616 comparetotal 12.1234 12.000000 -> 1 +cotx617 comparetotal 12.1234 12.0000000 -> 1 +cotx618 comparetotal 12.1234 12.00000000 -> 1 +cotx619 comparetotal 12.1234 12.000000000 -> 1 +cotx620 comparetotal -12 -12.2345 -> 1 +cotx621 comparetotal -12.0 -12.2345 -> 1 +cotx622 comparetotal -12.00 -12.2345 -> 1 +cotx623 comparetotal -12.000 -12.2345 -> 1 +cotx624 comparetotal -12.0000 -12.2345 -> 1 +cotx625 comparetotal -12.00000 -12.2345 -> 1 +cotx626 comparetotal -12.000000 -12.2345 -> 1 +cotx627 comparetotal -12.0000000 -12.2345 -> 1 +cotx628 comparetotal -12.00000000 -12.2345 -> 1 +cotx629 comparetotal -12.000000000 -12.2345 -> 1 +cotx630 comparetotal -12.1234 -12 -> -1 +cotx631 comparetotal -12.1234 -12.0 -> -1 +cotx632 comparetotal -12.1234 -12.00 -> -1 +cotx633 comparetotal -12.1234 -12.000 -> -1 +cotx634 comparetotal -12.1234 -12.0000 -> -1 +cotx635 comparetotal -12.1234 -12.00000 -> -1 +cotx636 comparetotal -12.1234 -12.000000 -> -1 +cotx637 comparetotal -12.1234 -12.0000000 -> -1 +cotx638 comparetotal -12.1234 -12.00000000 -> -1 +cotx639 comparetotal -12.1234 -12.000000000 -> -1 +precision: 9 + +-- extended zeros +cotx640 comparetotal 0 0 -> 0 +cotx641 comparetotal 0 -0 -> 1 +cotx642 comparetotal 0 -0.0 -> 1 +cotx643 comparetotal 0 0.0 -> 1 +cotx644 comparetotal -0 0 -> -1 +cotx645 comparetotal -0 -0 -> 0 +cotx646 comparetotal -0 -0.0 -> -1 +cotx647 comparetotal -0 0.0 -> -1 +cotx648 comparetotal 0.0 0 -> -1 +cotx649 comparetotal 0.0 -0 -> 1 +cotx650 comparetotal 0.0 -0.0 -> 1 +cotx651 comparetotal 0.0 0.0 -> 0 +cotx652 comparetotal -0.0 0 -> -1 +cotx653 comparetotal -0.0 -0 -> 1 +cotx654 comparetotal -0.0 -0.0 -> 0 +cotx655 comparetotal -0.0 0.0 -> -1 + +cotx656 comparetotal -0E1 0.0 -> -1 +cotx657 comparetotal -0E2 0.0 -> -1 +cotx658 comparetotal 0E1 0.0 -> 1 +cotx659 comparetotal 0E2 0.0 -> 1 +cotx660 comparetotal -0E1 0 -> -1 +cotx661 comparetotal -0E2 0 -> -1 +cotx662 comparetotal 0E1 0 -> 1 +cotx663 comparetotal 0E2 0 -> 1 +cotx664 comparetotal -0E1 -0E1 -> 0 +cotx665 comparetotal -0E2 -0E1 -> -1 +cotx666 comparetotal 0E1 -0E1 -> 1 +cotx667 comparetotal 0E2 -0E1 -> 1 +cotx668 comparetotal -0E1 -0E2 -> 1 +cotx669 comparetotal -0E2 -0E2 -> 0 +cotx670 comparetotal 0E1 -0E2 -> 1 +cotx671 comparetotal 0E2 -0E2 -> 1 +cotx672 comparetotal -0E1 0E1 -> -1 +cotx673 comparetotal -0E2 0E1 -> -1 +cotx674 comparetotal 0E1 0E1 -> 0 +cotx675 comparetotal 0E2 0E1 -> 1 +cotx676 comparetotal -0E1 0E2 -> -1 +cotx677 comparetotal -0E2 0E2 -> -1 +cotx678 comparetotal 0E1 0E2 -> -1 +cotx679 comparetotal 0E2 0E2 -> 0 + +-- trailing zeros; unit-y +precision: 20 +cotx680 comparetotal 12 12 -> 0 +cotx681 comparetotal 12 12.0 -> 1 +cotx682 comparetotal 12 12.00 -> 1 +cotx683 comparetotal 12 12.000 -> 1 +cotx684 comparetotal 12 12.0000 -> 1 +cotx685 comparetotal 12 12.00000 -> 1 +cotx686 comparetotal 12 12.000000 -> 1 +cotx687 comparetotal 12 12.0000000 -> 1 +cotx688 comparetotal 12 12.00000000 -> 1 +cotx689 comparetotal 12 12.000000000 -> 1 +cotx690 comparetotal 12 12 -> 0 +cotx691 comparetotal 12.0 12 -> -1 +cotx692 comparetotal 12.00 12 -> -1 +cotx693 comparetotal 12.000 12 -> -1 +cotx694 comparetotal 12.0000 12 -> -1 +cotx695 comparetotal 12.00000 12 -> -1 +cotx696 comparetotal 12.000000 12 -> -1 +cotx697 comparetotal 12.0000000 12 -> -1 +cotx698 comparetotal 12.00000000 12 -> -1 +cotx699 comparetotal 12.000000000 12 -> -1 + +-- long operand checks +maxexponent: 999 +minexponent: -999 +precision: 9 +cotx701 comparetotal 12345678000 1 -> 1 +cotx702 comparetotal 1 12345678000 -> -1 +cotx703 comparetotal 1234567800 1 -> 1 +cotx704 comparetotal 1 1234567800 -> -1 +cotx705 comparetotal 1234567890 1 -> 1 +cotx706 comparetotal 1 1234567890 -> -1 +cotx707 comparetotal 1234567891 1 -> 1 +cotx708 comparetotal 1 1234567891 -> -1 +cotx709 comparetotal 12345678901 1 -> 1 +cotx710 comparetotal 1 12345678901 -> -1 +cotx711 comparetotal 1234567896 1 -> 1 +cotx712 comparetotal 1 1234567896 -> -1 +cotx713 comparetotal -1234567891 1 -> -1 +cotx714 comparetotal 1 -1234567891 -> 1 +cotx715 comparetotal -12345678901 1 -> -1 +cotx716 comparetotal 1 -12345678901 -> 1 +cotx717 comparetotal -1234567896 1 -> -1 +cotx718 comparetotal 1 -1234567896 -> 1 + +precision: 15 +-- same with plenty of precision +cotx721 comparetotal 12345678000 1 -> 1 +cotx722 comparetotal 1 12345678000 -> -1 +cotx723 comparetotal 1234567800 1 -> 1 +cotx724 comparetotal 1 1234567800 -> -1 +cotx725 comparetotal 1234567890 1 -> 1 +cotx726 comparetotal 1 1234567890 -> -1 +cotx727 comparetotal 1234567891 1 -> 1 +cotx728 comparetotal 1 1234567891 -> -1 +cotx729 comparetotal 12345678901 1 -> 1 +cotx730 comparetotal 1 12345678901 -> -1 +cotx731 comparetotal 1234567896 1 -> 1 +cotx732 comparetotal 1 1234567896 -> -1 + +-- residue cases +precision: 5 +cotx740 comparetotal 1 0.9999999 -> 1 +cotx741 comparetotal 1 0.999999 -> 1 +cotx742 comparetotal 1 0.99999 -> 1 +cotx743 comparetotal 1 1.0000 -> 1 +cotx744 comparetotal 1 1.00001 -> -1 +cotx745 comparetotal 1 1.000001 -> -1 +cotx746 comparetotal 1 1.0000001 -> -1 +cotx750 comparetotal 0.9999999 1 -> -1 +cotx751 comparetotal 0.999999 1 -> -1 +cotx752 comparetotal 0.99999 1 -> -1 +cotx753 comparetotal 1.0000 1 -> -1 +cotx754 comparetotal 1.00001 1 -> 1 +cotx755 comparetotal 1.000001 1 -> 1 +cotx756 comparetotal 1.0000001 1 -> 1 + +-- a selection of longies +cotx760 comparetotal -36852134.84194296250843579428931 -5830629.8347085025808756560357940 -> -1 +cotx761 comparetotal -36852134.84194296250843579428931 -36852134.84194296250843579428931 -> 0 +cotx762 comparetotal -36852134.94194296250843579428931 -36852134.84194296250843579428931 -> -1 +cotx763 comparetotal -36852134.84194296250843579428931 -36852134.94194296250843579428931 -> 1 +-- precisions above or below the difference should have no effect +precision: 11 +cotx764 comparetotal -36852134.84194296250843579428931 -36852134.94194296250843579428931 -> 1 +precision: 10 +cotx765 comparetotal -36852134.84194296250843579428931 -36852134.94194296250843579428931 -> 1 +precision: 9 +cotx766 comparetotal -36852134.84194296250843579428931 -36852134.94194296250843579428931 -> 1 +precision: 8 +cotx767 comparetotal -36852134.84194296250843579428931 -36852134.94194296250843579428931 -> 1 +precision: 7 +cotx768 comparetotal -36852134.84194296250843579428931 -36852134.94194296250843579428931 -> 1 +precision: 6 +cotx769 comparetotal -36852134.84194296250843579428931 -36852134.94194296250843579428931 -> 1 +precision: 5 +cotx770 comparetotal -36852134.84194296250843579428931 -36852134.94194296250843579428931 -> 1 +precision: 4 +cotx771 comparetotal -36852134.84194296250843579428931 -36852134.94194296250843579428931 -> 1 +precision: 3 +cotx772 comparetotal -36852134.84194296250843579428931 -36852134.94194296250843579428931 -> 1 +precision: 2 +cotx773 comparetotal -36852134.84194296250843579428931 -36852134.94194296250843579428931 -> 1 +precision: 1 +cotx774 comparetotal -36852134.84194296250843579428931 -36852134.94194296250843579428931 -> 1 + +-- Specials +precision: 9 +cotx780 comparetotal Inf -Inf -> 1 +cotx781 comparetotal Inf -1000 -> 1 +cotx782 comparetotal Inf -1 -> 1 +cotx783 comparetotal Inf -0 -> 1 +cotx784 comparetotal Inf 0 -> 1 +cotx785 comparetotal Inf 1 -> 1 +cotx786 comparetotal Inf 1000 -> 1 +cotx787 comparetotal Inf Inf -> 0 +cotx788 comparetotal -1000 Inf -> -1 +cotx789 comparetotal -Inf Inf -> -1 +cotx790 comparetotal -1 Inf -> -1 +cotx791 comparetotal -0 Inf -> -1 +cotx792 comparetotal 0 Inf -> -1 +cotx793 comparetotal 1 Inf -> -1 +cotx794 comparetotal 1000 Inf -> -1 +cotx795 comparetotal Inf Inf -> 0 + +cotx800 comparetotal -Inf -Inf -> 0 +cotx801 comparetotal -Inf -1000 -> -1 +cotx802 comparetotal -Inf -1 -> -1 +cotx803 comparetotal -Inf -0 -> -1 +cotx804 comparetotal -Inf 0 -> -1 +cotx805 comparetotal -Inf 1 -> -1 +cotx806 comparetotal -Inf 1000 -> -1 +cotx807 comparetotal -Inf Inf -> -1 +cotx808 comparetotal -Inf -Inf -> 0 +cotx809 comparetotal -1000 -Inf -> 1 +cotx810 comparetotal -1 -Inf -> 1 +cotx811 comparetotal -0 -Inf -> 1 +cotx812 comparetotal 0 -Inf -> 1 +cotx813 comparetotal 1 -Inf -> 1 +cotx814 comparetotal 1000 -Inf -> 1 +cotx815 comparetotal Inf -Inf -> 1 + +cotx821 comparetotal NaN -Inf -> 1 +cotx822 comparetotal NaN -1000 -> 1 +cotx823 comparetotal NaN -1 -> 1 +cotx824 comparetotal NaN -0 -> 1 +cotx825 comparetotal NaN 0 -> 1 +cotx826 comparetotal NaN 1 -> 1 +cotx827 comparetotal NaN 1000 -> 1 +cotx828 comparetotal NaN Inf -> 1 +cotx829 comparetotal NaN NaN -> 0 +cotx830 comparetotal -Inf NaN -> -1 +cotx831 comparetotal -1000 NaN -> -1 +cotx832 comparetotal -1 NaN -> -1 +cotx833 comparetotal -0 NaN -> -1 +cotx834 comparetotal 0 NaN -> -1 +cotx835 comparetotal 1 NaN -> -1 +cotx836 comparetotal 1000 NaN -> -1 +cotx837 comparetotal Inf NaN -> -1 +cotx838 comparetotal -NaN -NaN -> 0 +cotx839 comparetotal +NaN -NaN -> 1 +cotx840 comparetotal -NaN +NaN -> -1 + +cotx841 comparetotal sNaN -sNaN -> 1 +cotx842 comparetotal sNaN -NaN -> 1 +cotx843 comparetotal sNaN -Inf -> 1 +cotx844 comparetotal sNaN -1000 -> 1 +cotx845 comparetotal sNaN -1 -> 1 +cotx846 comparetotal sNaN -0 -> 1 +cotx847 comparetotal sNaN 0 -> 1 +cotx848 comparetotal sNaN 1 -> 1 +cotx849 comparetotal sNaN 1000 -> 1 +cotx850 comparetotal sNaN NaN -> -1 +cotx851 comparetotal sNaN sNaN -> 0 + +cotx852 comparetotal -sNaN sNaN -> -1 +cotx853 comparetotal -NaN sNaN -> -1 +cotx854 comparetotal -Inf sNaN -> -1 +cotx855 comparetotal -1000 sNaN -> -1 +cotx856 comparetotal -1 sNaN -> -1 +cotx857 comparetotal -0 sNaN -> -1 +cotx858 comparetotal 0 sNaN -> -1 +cotx859 comparetotal 1 sNaN -> -1 +cotx860 comparetotal 1000 sNaN -> -1 +cotx861 comparetotal Inf sNaN -> -1 +cotx862 comparetotal NaN sNaN -> 1 +cotx863 comparetotal sNaN sNaN -> 0 + +cotx871 comparetotal -sNaN -sNaN -> 0 +cotx872 comparetotal -sNaN -NaN -> 1 +cotx873 comparetotal -sNaN -Inf -> -1 +cotx874 comparetotal -sNaN -1000 -> -1 +cotx875 comparetotal -sNaN -1 -> -1 +cotx876 comparetotal -sNaN -0 -> -1 +cotx877 comparetotal -sNaN 0 -> -1 +cotx878 comparetotal -sNaN 1 -> -1 +cotx879 comparetotal -sNaN 1000 -> -1 +cotx880 comparetotal -sNaN NaN -> -1 +cotx881 comparetotal -sNaN sNaN -> -1 + +cotx882 comparetotal -sNaN -sNaN -> 0 +cotx883 comparetotal -NaN -sNaN -> -1 +cotx884 comparetotal -Inf -sNaN -> 1 +cotx885 comparetotal -1000 -sNaN -> 1 +cotx886 comparetotal -1 -sNaN -> 1 +cotx887 comparetotal -0 -sNaN -> 1 +cotx888 comparetotal 0 -sNaN -> 1 +cotx889 comparetotal 1 -sNaN -> 1 +cotx890 comparetotal 1000 -sNaN -> 1 +cotx891 comparetotal Inf -sNaN -> 1 +cotx892 comparetotal NaN -sNaN -> 1 +cotx893 comparetotal sNaN -sNaN -> 1 + +-- NaNs with payload +cotx960 comparetotal NaN9 -Inf -> 1 +cotx961 comparetotal NaN8 999 -> 1 +cotx962 comparetotal NaN77 Inf -> 1 +cotx963 comparetotal -NaN67 NaN5 -> -1 +cotx964 comparetotal -Inf -NaN4 -> 1 +cotx965 comparetotal -999 -NaN33 -> 1 +cotx966 comparetotal Inf NaN2 -> -1 + +cotx970 comparetotal -NaN41 -NaN42 -> 1 +cotx971 comparetotal +NaN41 -NaN42 -> 1 +cotx972 comparetotal -NaN41 +NaN42 -> -1 +cotx973 comparetotal +NaN41 +NaN42 -> -1 +cotx974 comparetotal -NaN42 -NaN01 -> -1 +cotx975 comparetotal +NaN42 -NaN01 -> 1 +cotx976 comparetotal -NaN42 +NaN01 -> -1 +cotx977 comparetotal +NaN42 +NaN01 -> 1 + +cotx980 comparetotal -sNaN771 -sNaN772 -> 1 +cotx981 comparetotal +sNaN771 -sNaN772 -> 1 +cotx982 comparetotal -sNaN771 +sNaN772 -> -1 +cotx983 comparetotal +sNaN771 +sNaN772 -> -1 +cotx984 comparetotal -sNaN772 -sNaN771 -> -1 +cotx985 comparetotal +sNaN772 -sNaN771 -> 1 +cotx986 comparetotal -sNaN772 +sNaN771 -> -1 +cotx987 comparetotal +sNaN772 +sNaN771 -> 1 + +cotx991 comparetotal -sNaN99 -Inf -> -1 +cotx992 comparetotal sNaN98 -11 -> 1 +cotx993 comparetotal sNaN97 NaN -> -1 +cotx994 comparetotal sNaN16 sNaN94 -> -1 +cotx995 comparetotal NaN85 sNaN83 -> 1 +cotx996 comparetotal -Inf sNaN92 -> -1 +cotx997 comparetotal 088 sNaN81 -> -1 +cotx998 comparetotal Inf sNaN90 -> -1 +cotx999 comparetotal NaN -sNaN89 -> 1 + +-- overflow and underflow tests .. subnormal results now allowed +maxExponent: 999999999 +minexponent: -999999999 +cotx1080 comparetotal +1.23456789012345E-0 9E+999999999 -> -1 +cotx1081 comparetotal 9E+999999999 +1.23456789012345E-0 -> 1 +cotx1082 comparetotal +0.100 9E-999999999 -> 1 +cotx1083 comparetotal 9E-999999999 +0.100 -> -1 +cotx1085 comparetotal -1.23456789012345E-0 9E+999999999 -> -1 +cotx1086 comparetotal 9E+999999999 -1.23456789012345E-0 -> 1 +cotx1087 comparetotal -0.100 9E-999999999 -> -1 +cotx1088 comparetotal 9E-999999999 -0.100 -> 1 + +cotx1089 comparetotal 1e-599999999 1e-400000001 -> -1 +cotx1090 comparetotal 1e-599999999 1e-400000000 -> -1 +cotx1091 comparetotal 1e-600000000 1e-400000000 -> -1 +cotx1092 comparetotal 9e-999999998 0.01 -> -1 +cotx1093 comparetotal 9e-999999998 0.1 -> -1 +cotx1094 comparetotal 0.01 9e-999999998 -> 1 +cotx1095 comparetotal 1e599999999 1e400000001 -> 1 +cotx1096 comparetotal 1e599999999 1e400000000 -> 1 +cotx1097 comparetotal 1e600000000 1e400000000 -> 1 +cotx1098 comparetotal 9e999999998 100 -> 1 +cotx1099 comparetotal 9e999999998 10 -> 1 +cotx1100 comparetotal 100 9e999999998 -> -1 +-- signs +cotx1101 comparetotal 1e+777777777 1e+411111111 -> 1 +cotx1102 comparetotal 1e+777777777 -1e+411111111 -> 1 +cotx1103 comparetotal -1e+777777777 1e+411111111 -> -1 +cotx1104 comparetotal -1e+777777777 -1e+411111111 -> -1 +cotx1105 comparetotal 1e-777777777 1e-411111111 -> -1 +cotx1106 comparetotal 1e-777777777 -1e-411111111 -> 1 +cotx1107 comparetotal -1e-777777777 1e-411111111 -> -1 +cotx1108 comparetotal -1e-777777777 -1e-411111111 -> 1 + +-- spread zeros +cotx1110 comparetotal 0E-383 0 -> -1 +cotx1111 comparetotal 0E-383 -0 -> 1 +cotx1112 comparetotal -0E-383 0 -> -1 +cotx1113 comparetotal -0E-383 -0 -> 1 +cotx1114 comparetotal 0E-383 0E+384 -> -1 +cotx1115 comparetotal 0E-383 -0E+384 -> 1 +cotx1116 comparetotal -0E-383 0E+384 -> -1 +cotx1117 comparetotal -0E-383 -0E+384 -> 1 +cotx1118 comparetotal 0 0E+384 -> -1 +cotx1119 comparetotal 0 -0E+384 -> 1 +cotx1120 comparetotal -0 0E+384 -> -1 +cotx1121 comparetotal -0 -0E+384 -> 1 + +cotx1130 comparetotal 0E+384 0 -> 1 +cotx1131 comparetotal 0E+384 -0 -> 1 +cotx1132 comparetotal -0E+384 0 -> -1 +cotx1133 comparetotal -0E+384 -0 -> -1 +cotx1134 comparetotal 0E+384 0E-383 -> 1 +cotx1135 comparetotal 0E+384 -0E-383 -> 1 +cotx1136 comparetotal -0E+384 0E-383 -> -1 +cotx1137 comparetotal -0E+384 -0E-383 -> -1 +cotx1138 comparetotal 0 0E-383 -> 1 +cotx1139 comparetotal 0 -0E-383 -> 1 +cotx1140 comparetotal -0 0E-383 -> -1 +cotx1141 comparetotal -0 -0E-383 -> -1 + +-- Null tests +cotx9990 comparetotal 10 # -> NaN Invalid_operation +cotx9991 comparetotal # 10 -> NaN Invalid_operation Added: python/branches/release25-maint/Lib/test/decimaltestdata/comparetotmag.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/comparetotmag.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,790 @@ +------------------------------------------------------------------------ +-- comparetotmag.decTest -- decimal comparison, abs. total ordering -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- Note that it cannot be assumed that add/subtract tests cover paths +-- for this operation adequately, here, because the code might be +-- quite different (comparison cannot overflow or underflow, so +-- actual subtractions are not necessary). Similarly, comparetotal +-- will have some radically different paths than compare. + +extended: 1 +precision: 16 +rounding: half_up +maxExponent: 384 +minExponent: -383 + +-- sanity checks +ctmx001 comparetotmag -2 -2 -> 0 +ctmx002 comparetotmag -2 -1 -> 1 +ctmx003 comparetotmag -2 0 -> 1 +ctmx004 comparetotmag -2 1 -> 1 +ctmx005 comparetotmag -2 2 -> 0 +ctmx006 comparetotmag -1 -2 -> -1 +ctmx007 comparetotmag -1 -1 -> 0 +ctmx008 comparetotmag -1 0 -> 1 +ctmx009 comparetotmag -1 1 -> 0 +ctmx010 comparetotmag -1 2 -> -1 +ctmx011 comparetotmag 0 -2 -> -1 +ctmx012 comparetotmag 0 -1 -> -1 +ctmx013 comparetotmag 0 0 -> 0 +ctmx014 comparetotmag 0 1 -> -1 +ctmx015 comparetotmag 0 2 -> -1 +ctmx016 comparetotmag 1 -2 -> -1 +ctmx017 comparetotmag 1 -1 -> 0 +ctmx018 comparetotmag 1 0 -> 1 +ctmx019 comparetotmag 1 1 -> 0 +ctmx020 comparetotmag 1 2 -> -1 +ctmx021 comparetotmag 2 -2 -> 0 +ctmx022 comparetotmag 2 -1 -> 1 +ctmx023 comparetotmag 2 0 -> 1 +ctmx025 comparetotmag 2 1 -> 1 +ctmx026 comparetotmag 2 2 -> 0 + +ctmx031 comparetotmag -20 -20 -> 0 +ctmx032 comparetotmag -20 -10 -> 1 +ctmx033 comparetotmag -20 00 -> 1 +ctmx034 comparetotmag -20 10 -> 1 +ctmx035 comparetotmag -20 20 -> 0 +ctmx036 comparetotmag -10 -20 -> -1 +ctmx037 comparetotmag -10 -10 -> 0 +ctmx038 comparetotmag -10 00 -> 1 +ctmx039 comparetotmag -10 10 -> 0 +ctmx040 comparetotmag -10 20 -> -1 +ctmx041 comparetotmag 00 -20 -> -1 +ctmx042 comparetotmag 00 -10 -> -1 +ctmx043 comparetotmag 00 00 -> 0 +ctmx044 comparetotmag 00 10 -> -1 +ctmx045 comparetotmag 00 20 -> -1 +ctmx046 comparetotmag 10 -20 -> -1 +ctmx047 comparetotmag 10 -10 -> 0 +ctmx048 comparetotmag 10 00 -> 1 +ctmx049 comparetotmag 10 10 -> 0 +ctmx050 comparetotmag 10 20 -> -1 +ctmx051 comparetotmag 20 -20 -> 0 +ctmx052 comparetotmag 20 -10 -> 1 +ctmx053 comparetotmag 20 00 -> 1 +ctmx055 comparetotmag 20 10 -> 1 +ctmx056 comparetotmag 20 20 -> 0 + +ctmx061 comparetotmag -2.0 -2.0 -> 0 +ctmx062 comparetotmag -2.0 -1.0 -> 1 +ctmx063 comparetotmag -2.0 0.0 -> 1 +ctmx064 comparetotmag -2.0 1.0 -> 1 +ctmx065 comparetotmag -2.0 2.0 -> 0 +ctmx066 comparetotmag -1.0 -2.0 -> -1 +ctmx067 comparetotmag -1.0 -1.0 -> 0 +ctmx068 comparetotmag -1.0 0.0 -> 1 +ctmx069 comparetotmag -1.0 1.0 -> 0 +ctmx070 comparetotmag -1.0 2.0 -> -1 +ctmx071 comparetotmag 0.0 -2.0 -> -1 +ctmx072 comparetotmag 0.0 -1.0 -> -1 +ctmx073 comparetotmag 0.0 0.0 -> 0 +ctmx074 comparetotmag 0.0 1.0 -> -1 +ctmx075 comparetotmag 0.0 2.0 -> -1 +ctmx076 comparetotmag 1.0 -2.0 -> -1 +ctmx077 comparetotmag 1.0 -1.0 -> 0 +ctmx078 comparetotmag 1.0 0.0 -> 1 +ctmx079 comparetotmag 1.0 1.0 -> 0 +ctmx080 comparetotmag 1.0 2.0 -> -1 +ctmx081 comparetotmag 2.0 -2.0 -> 0 +ctmx082 comparetotmag 2.0 -1.0 -> 1 +ctmx083 comparetotmag 2.0 0.0 -> 1 +ctmx085 comparetotmag 2.0 1.0 -> 1 +ctmx086 comparetotmag 2.0 2.0 -> 0 + +-- now some cases which might overflow if subtract were used +maxexponent: 999999999 +minexponent: -999999999 +ctmx090 comparetotmag 9.99999999E+999999999 9.99999999E+999999999 -> 0 +ctmx091 comparetotmag -9.99999999E+999999999 9.99999999E+999999999 -> 0 +ctmx092 comparetotmag 9.99999999E+999999999 -9.99999999E+999999999 -> 0 +ctmx093 comparetotmag -9.99999999E+999999999 -9.99999999E+999999999 -> 0 + +-- some differing length/exponent cases +-- in this first group, compare would compare all equal +ctmx100 comparetotmag 7.0 7.0 -> 0 +ctmx101 comparetotmag 7.0 7 -> -1 +ctmx102 comparetotmag 7 7.0 -> 1 +ctmx103 comparetotmag 7E+0 7.0 -> 1 +ctmx104 comparetotmag 70E-1 7.0 -> 0 +ctmx105 comparetotmag 0.7E+1 7 -> 0 +ctmx106 comparetotmag 70E-1 7 -> -1 +ctmx107 comparetotmag 7.0 7E+0 -> -1 +ctmx108 comparetotmag 7.0 70E-1 -> 0 +ctmx109 comparetotmag 7 0.7E+1 -> 0 +ctmx110 comparetotmag 7 70E-1 -> 1 + +ctmx120 comparetotmag 8.0 7.0 -> 1 +ctmx121 comparetotmag 8.0 7 -> 1 +ctmx122 comparetotmag 8 7.0 -> 1 +ctmx123 comparetotmag 8E+0 7.0 -> 1 +ctmx124 comparetotmag 80E-1 7.0 -> 1 +ctmx125 comparetotmag 0.8E+1 7 -> 1 +ctmx126 comparetotmag 80E-1 7 -> 1 +ctmx127 comparetotmag 8.0 7E+0 -> 1 +ctmx128 comparetotmag 8.0 70E-1 -> 1 +ctmx129 comparetotmag 8 0.7E+1 -> 1 +ctmx130 comparetotmag 8 70E-1 -> 1 + +ctmx140 comparetotmag 8.0 9.0 -> -1 +ctmx141 comparetotmag 8.0 9 -> -1 +ctmx142 comparetotmag 8 9.0 -> -1 +ctmx143 comparetotmag 8E+0 9.0 -> -1 +ctmx144 comparetotmag 80E-1 9.0 -> -1 +ctmx145 comparetotmag 0.8E+1 9 -> -1 +ctmx146 comparetotmag 80E-1 9 -> -1 +ctmx147 comparetotmag 8.0 9E+0 -> -1 +ctmx148 comparetotmag 8.0 90E-1 -> -1 +ctmx149 comparetotmag 8 0.9E+1 -> -1 +ctmx150 comparetotmag 8 90E-1 -> -1 + +-- and again, with sign changes -+ .. +ctmx200 comparetotmag -7.0 7.0 -> 0 +ctmx201 comparetotmag -7.0 7 -> -1 +ctmx202 comparetotmag -7 7.0 -> 1 +ctmx203 comparetotmag -7E+0 7.0 -> 1 +ctmx204 comparetotmag -70E-1 7.0 -> 0 +ctmx205 comparetotmag -0.7E+1 7 -> 0 +ctmx206 comparetotmag -70E-1 7 -> -1 +ctmx207 comparetotmag -7.0 7E+0 -> -1 +ctmx208 comparetotmag -7.0 70E-1 -> 0 +ctmx209 comparetotmag -7 0.7E+1 -> 0 +ctmx210 comparetotmag -7 70E-1 -> 1 + +ctmx220 comparetotmag -8.0 7.0 -> 1 +ctmx221 comparetotmag -8.0 7 -> 1 +ctmx222 comparetotmag -8 7.0 -> 1 +ctmx223 comparetotmag -8E+0 7.0 -> 1 +ctmx224 comparetotmag -80E-1 7.0 -> 1 +ctmx225 comparetotmag -0.8E+1 7 -> 1 +ctmx226 comparetotmag -80E-1 7 -> 1 +ctmx227 comparetotmag -8.0 7E+0 -> 1 +ctmx228 comparetotmag -8.0 70E-1 -> 1 +ctmx229 comparetotmag -8 0.7E+1 -> 1 +ctmx230 comparetotmag -8 70E-1 -> 1 + +ctmx240 comparetotmag -8.0 9.0 -> -1 +ctmx241 comparetotmag -8.0 9 -> -1 +ctmx242 comparetotmag -8 9.0 -> -1 +ctmx243 comparetotmag -8E+0 9.0 -> -1 +ctmx244 comparetotmag -80E-1 9.0 -> -1 +ctmx245 comparetotmag -0.8E+1 9 -> -1 +ctmx246 comparetotmag -80E-1 9 -> -1 +ctmx247 comparetotmag -8.0 9E+0 -> -1 +ctmx248 comparetotmag -8.0 90E-1 -> -1 +ctmx249 comparetotmag -8 0.9E+1 -> -1 +ctmx250 comparetotmag -8 90E-1 -> -1 + +-- and again, with sign changes +- .. +ctmx300 comparetotmag 7.0 -7.0 -> 0 +ctmx301 comparetotmag 7.0 -7 -> -1 +ctmx302 comparetotmag 7 -7.0 -> 1 +ctmx303 comparetotmag 7E+0 -7.0 -> 1 +ctmx304 comparetotmag 70E-1 -7.0 -> 0 +ctmx305 comparetotmag .7E+1 -7 -> 0 +ctmx306 comparetotmag 70E-1 -7 -> -1 +ctmx307 comparetotmag 7.0 -7E+0 -> -1 +ctmx308 comparetotmag 7.0 -70E-1 -> 0 +ctmx309 comparetotmag 7 -.7E+1 -> 0 +ctmx310 comparetotmag 7 -70E-1 -> 1 + +ctmx320 comparetotmag 8.0 -7.0 -> 1 +ctmx321 comparetotmag 8.0 -7 -> 1 +ctmx322 comparetotmag 8 -7.0 -> 1 +ctmx323 comparetotmag 8E+0 -7.0 -> 1 +ctmx324 comparetotmag 80E-1 -7.0 -> 1 +ctmx325 comparetotmag .8E+1 -7 -> 1 +ctmx326 comparetotmag 80E-1 -7 -> 1 +ctmx327 comparetotmag 8.0 -7E+0 -> 1 +ctmx328 comparetotmag 8.0 -70E-1 -> 1 +ctmx329 comparetotmag 8 -.7E+1 -> 1 +ctmx330 comparetotmag 8 -70E-1 -> 1 + +ctmx340 comparetotmag 8.0 -9.0 -> -1 +ctmx341 comparetotmag 8.0 -9 -> -1 +ctmx342 comparetotmag 8 -9.0 -> -1 +ctmx343 comparetotmag 8E+0 -9.0 -> -1 +ctmx344 comparetotmag 80E-1 -9.0 -> -1 +ctmx345 comparetotmag .8E+1 -9 -> -1 +ctmx346 comparetotmag 80E-1 -9 -> -1 +ctmx347 comparetotmag 8.0 -9E+0 -> -1 +ctmx348 comparetotmag 8.0 -90E-1 -> -1 +ctmx349 comparetotmag 8 -.9E+1 -> -1 +ctmx350 comparetotmag 8 -90E-1 -> -1 + +-- and again, with sign changes -- .. +ctmx400 comparetotmag -7.0 -7.0 -> 0 +ctmx401 comparetotmag -7.0 -7 -> -1 +ctmx402 comparetotmag -7 -7.0 -> 1 +ctmx403 comparetotmag -7E+0 -7.0 -> 1 +ctmx404 comparetotmag -70E-1 -7.0 -> 0 +ctmx405 comparetotmag -.7E+1 -7 -> 0 +ctmx406 comparetotmag -70E-1 -7 -> -1 +ctmx407 comparetotmag -7.0 -7E+0 -> -1 +ctmx408 comparetotmag -7.0 -70E-1 -> 0 +ctmx409 comparetotmag -7 -.7E+1 -> 0 +ctmx410 comparetotmag -7 -70E-1 -> 1 + +ctmx420 comparetotmag -8.0 -7.0 -> 1 +ctmx421 comparetotmag -8.0 -7 -> 1 +ctmx422 comparetotmag -8 -7.0 -> 1 +ctmx423 comparetotmag -8E+0 -7.0 -> 1 +ctmx424 comparetotmag -80E-1 -7.0 -> 1 +ctmx425 comparetotmag -.8E+1 -7 -> 1 +ctmx426 comparetotmag -80E-1 -7 -> 1 +ctmx427 comparetotmag -8.0 -7E+0 -> 1 +ctmx428 comparetotmag -8.0 -70E-1 -> 1 +ctmx429 comparetotmag -8 -.7E+1 -> 1 +ctmx430 comparetotmag -8 -70E-1 -> 1 + +ctmx440 comparetotmag -8.0 -9.0 -> -1 +ctmx441 comparetotmag -8.0 -9 -> -1 +ctmx442 comparetotmag -8 -9.0 -> -1 +ctmx443 comparetotmag -8E+0 -9.0 -> -1 +ctmx444 comparetotmag -80E-1 -9.0 -> -1 +ctmx445 comparetotmag -.8E+1 -9 -> -1 +ctmx446 comparetotmag -80E-1 -9 -> -1 +ctmx447 comparetotmag -8.0 -9E+0 -> -1 +ctmx448 comparetotmag -8.0 -90E-1 -> -1 +ctmx449 comparetotmag -8 -.9E+1 -> -1 +ctmx450 comparetotmag -8 -90E-1 -> -1 + + +-- testcases that subtract to lots of zeros at boundaries [pgr] +precision: 40 +ctmx470 comparetotmag 123.4560000000000000E789 123.456E789 -> -1 +ctmx471 comparetotmag 123.456000000000000E-89 123.456E-89 -> -1 +ctmx472 comparetotmag 123.45600000000000E789 123.456E789 -> -1 +ctmx473 comparetotmag 123.4560000000000E-89 123.456E-89 -> -1 +ctmx474 comparetotmag 123.456000000000E789 123.456E789 -> -1 +ctmx475 comparetotmag 123.45600000000E-89 123.456E-89 -> -1 +ctmx476 comparetotmag 123.4560000000E789 123.456E789 -> -1 +ctmx477 comparetotmag 123.456000000E-89 123.456E-89 -> -1 +ctmx478 comparetotmag 123.45600000E789 123.456E789 -> -1 +ctmx479 comparetotmag 123.4560000E-89 123.456E-89 -> -1 +ctmx480 comparetotmag 123.456000E789 123.456E789 -> -1 +ctmx481 comparetotmag 123.45600E-89 123.456E-89 -> -1 +ctmx482 comparetotmag 123.4560E789 123.456E789 -> -1 +ctmx483 comparetotmag 123.456E-89 123.456E-89 -> 0 +ctmx484 comparetotmag 123.456E-89 123.4560000000000000E-89 -> 1 +ctmx485 comparetotmag 123.456E789 123.456000000000000E789 -> 1 +ctmx486 comparetotmag 123.456E-89 123.45600000000000E-89 -> 1 +ctmx487 comparetotmag 123.456E789 123.4560000000000E789 -> 1 +ctmx488 comparetotmag 123.456E-89 123.456000000000E-89 -> 1 +ctmx489 comparetotmag 123.456E789 123.45600000000E789 -> 1 +ctmx490 comparetotmag 123.456E-89 123.4560000000E-89 -> 1 +ctmx491 comparetotmag 123.456E789 123.456000000E789 -> 1 +ctmx492 comparetotmag 123.456E-89 123.45600000E-89 -> 1 +ctmx493 comparetotmag 123.456E789 123.4560000E789 -> 1 +ctmx494 comparetotmag 123.456E-89 123.456000E-89 -> 1 +ctmx495 comparetotmag 123.456E789 123.45600E789 -> 1 +ctmx496 comparetotmag 123.456E-89 123.4560E-89 -> 1 +ctmx497 comparetotmag 123.456E789 123.456E789 -> 0 + +-- wide-ranging, around precision; signs equal +precision: 9 +ctmx500 comparetotmag 1 1E-15 -> 1 +ctmx501 comparetotmag 1 1E-14 -> 1 +ctmx502 comparetotmag 1 1E-13 -> 1 +ctmx503 comparetotmag 1 1E-12 -> 1 +ctmx504 comparetotmag 1 1E-11 -> 1 +ctmx505 comparetotmag 1 1E-10 -> 1 +ctmx506 comparetotmag 1 1E-9 -> 1 +ctmx507 comparetotmag 1 1E-8 -> 1 +ctmx508 comparetotmag 1 1E-7 -> 1 +ctmx509 comparetotmag 1 1E-6 -> 1 +ctmx510 comparetotmag 1 1E-5 -> 1 +ctmx511 comparetotmag 1 1E-4 -> 1 +ctmx512 comparetotmag 1 1E-3 -> 1 +ctmx513 comparetotmag 1 1E-2 -> 1 +ctmx514 comparetotmag 1 1E-1 -> 1 +ctmx515 comparetotmag 1 1E-0 -> 0 +ctmx516 comparetotmag 1 1E+1 -> -1 +ctmx517 comparetotmag 1 1E+2 -> -1 +ctmx518 comparetotmag 1 1E+3 -> -1 +ctmx519 comparetotmag 1 1E+4 -> -1 +ctmx521 comparetotmag 1 1E+5 -> -1 +ctmx522 comparetotmag 1 1E+6 -> -1 +ctmx523 comparetotmag 1 1E+7 -> -1 +ctmx524 comparetotmag 1 1E+8 -> -1 +ctmx525 comparetotmag 1 1E+9 -> -1 +ctmx526 comparetotmag 1 1E+10 -> -1 +ctmx527 comparetotmag 1 1E+11 -> -1 +ctmx528 comparetotmag 1 1E+12 -> -1 +ctmx529 comparetotmag 1 1E+13 -> -1 +ctmx530 comparetotmag 1 1E+14 -> -1 +ctmx531 comparetotmag 1 1E+15 -> -1 +-- LR swap +ctmx540 comparetotmag 1E-15 1 -> -1 +ctmx541 comparetotmag 1E-14 1 -> -1 +ctmx542 comparetotmag 1E-13 1 -> -1 +ctmx543 comparetotmag 1E-12 1 -> -1 +ctmx544 comparetotmag 1E-11 1 -> -1 +ctmx545 comparetotmag 1E-10 1 -> -1 +ctmx546 comparetotmag 1E-9 1 -> -1 +ctmx547 comparetotmag 1E-8 1 -> -1 +ctmx548 comparetotmag 1E-7 1 -> -1 +ctmx549 comparetotmag 1E-6 1 -> -1 +ctmx550 comparetotmag 1E-5 1 -> -1 +ctmx551 comparetotmag 1E-4 1 -> -1 +ctmx552 comparetotmag 1E-3 1 -> -1 +ctmx553 comparetotmag 1E-2 1 -> -1 +ctmx554 comparetotmag 1E-1 1 -> -1 +ctmx555 comparetotmag 1E-0 1 -> 0 +ctmx556 comparetotmag 1E+1 1 -> 1 +ctmx557 comparetotmag 1E+2 1 -> 1 +ctmx558 comparetotmag 1E+3 1 -> 1 +ctmx559 comparetotmag 1E+4 1 -> 1 +ctmx561 comparetotmag 1E+5 1 -> 1 +ctmx562 comparetotmag 1E+6 1 -> 1 +ctmx563 comparetotmag 1E+7 1 -> 1 +ctmx564 comparetotmag 1E+8 1 -> 1 +ctmx565 comparetotmag 1E+9 1 -> 1 +ctmx566 comparetotmag 1E+10 1 -> 1 +ctmx567 comparetotmag 1E+11 1 -> 1 +ctmx568 comparetotmag 1E+12 1 -> 1 +ctmx569 comparetotmag 1E+13 1 -> 1 +ctmx570 comparetotmag 1E+14 1 -> 1 +ctmx571 comparetotmag 1E+15 1 -> 1 +-- similar with an useful coefficient, one side only +ctmx580 comparetotmag 0.000000987654321 1E-15 -> 1 +ctmx581 comparetotmag 0.000000987654321 1E-14 -> 1 +ctmx582 comparetotmag 0.000000987654321 1E-13 -> 1 +ctmx583 comparetotmag 0.000000987654321 1E-12 -> 1 +ctmx584 comparetotmag 0.000000987654321 1E-11 -> 1 +ctmx585 comparetotmag 0.000000987654321 1E-10 -> 1 +ctmx586 comparetotmag 0.000000987654321 1E-9 -> 1 +ctmx587 comparetotmag 0.000000987654321 1E-8 -> 1 +ctmx588 comparetotmag 0.000000987654321 1E-7 -> 1 +ctmx589 comparetotmag 0.000000987654321 1E-6 -> -1 +ctmx590 comparetotmag 0.000000987654321 1E-5 -> -1 +ctmx591 comparetotmag 0.000000987654321 1E-4 -> -1 +ctmx592 comparetotmag 0.000000987654321 1E-3 -> -1 +ctmx593 comparetotmag 0.000000987654321 1E-2 -> -1 +ctmx594 comparetotmag 0.000000987654321 1E-1 -> -1 +ctmx595 comparetotmag 0.000000987654321 1E-0 -> -1 +ctmx596 comparetotmag 0.000000987654321 1E+1 -> -1 +ctmx597 comparetotmag 0.000000987654321 1E+2 -> -1 +ctmx598 comparetotmag 0.000000987654321 1E+3 -> -1 +ctmx599 comparetotmag 0.000000987654321 1E+4 -> -1 + +-- check some unit-y traps +precision: 20 +ctmx600 comparetotmag 12 12.2345 -> -1 +ctmx601 comparetotmag 12.0 12.2345 -> -1 +ctmx602 comparetotmag 12.00 12.2345 -> -1 +ctmx603 comparetotmag 12.000 12.2345 -> -1 +ctmx604 comparetotmag 12.0000 12.2345 -> -1 +ctmx605 comparetotmag 12.00000 12.2345 -> -1 +ctmx606 comparetotmag 12.000000 12.2345 -> -1 +ctmx607 comparetotmag 12.0000000 12.2345 -> -1 +ctmx608 comparetotmag 12.00000000 12.2345 -> -1 +ctmx609 comparetotmag 12.000000000 12.2345 -> -1 +ctmx610 comparetotmag 12.1234 12 -> 1 +ctmx611 comparetotmag 12.1234 12.0 -> 1 +ctmx612 comparetotmag 12.1234 12.00 -> 1 +ctmx613 comparetotmag 12.1234 12.000 -> 1 +ctmx614 comparetotmag 12.1234 12.0000 -> 1 +ctmx615 comparetotmag 12.1234 12.00000 -> 1 +ctmx616 comparetotmag 12.1234 12.000000 -> 1 +ctmx617 comparetotmag 12.1234 12.0000000 -> 1 +ctmx618 comparetotmag 12.1234 12.00000000 -> 1 +ctmx619 comparetotmag 12.1234 12.000000000 -> 1 +ctmx620 comparetotmag -12 -12.2345 -> -1 +ctmx621 comparetotmag -12.0 -12.2345 -> -1 +ctmx622 comparetotmag -12.00 -12.2345 -> -1 +ctmx623 comparetotmag -12.000 -12.2345 -> -1 +ctmx624 comparetotmag -12.0000 -12.2345 -> -1 +ctmx625 comparetotmag -12.00000 -12.2345 -> -1 +ctmx626 comparetotmag -12.000000 -12.2345 -> -1 +ctmx627 comparetotmag -12.0000000 -12.2345 -> -1 +ctmx628 comparetotmag -12.00000000 -12.2345 -> -1 +ctmx629 comparetotmag -12.000000000 -12.2345 -> -1 +ctmx630 comparetotmag -12.1234 -12 -> 1 +ctmx631 comparetotmag -12.1234 -12.0 -> 1 +ctmx632 comparetotmag -12.1234 -12.00 -> 1 +ctmx633 comparetotmag -12.1234 -12.000 -> 1 +ctmx634 comparetotmag -12.1234 -12.0000 -> 1 +ctmx635 comparetotmag -12.1234 -12.00000 -> 1 +ctmx636 comparetotmag -12.1234 -12.000000 -> 1 +ctmx637 comparetotmag -12.1234 -12.0000000 -> 1 +ctmx638 comparetotmag -12.1234 -12.00000000 -> 1 +ctmx639 comparetotmag -12.1234 -12.000000000 -> 1 +precision: 9 + +-- extended zeros +ctmx640 comparetotmag 0 0 -> 0 +ctmx641 comparetotmag 0 -0 -> 0 +ctmx642 comparetotmag 0 -0.0 -> 1 +ctmx643 comparetotmag 0 0.0 -> 1 +ctmx644 comparetotmag -0 0 -> 0 +ctmx645 comparetotmag -0 -0 -> 0 +ctmx646 comparetotmag -0 -0.0 -> 1 +ctmx647 comparetotmag -0 0.0 -> 1 +ctmx648 comparetotmag 0.0 0 -> -1 +ctmx649 comparetotmag 0.0 -0 -> -1 +ctmx650 comparetotmag 0.0 -0.0 -> 0 +ctmx651 comparetotmag 0.0 0.0 -> 0 +ctmx652 comparetotmag -0.0 0 -> -1 +ctmx653 comparetotmag -0.0 -0 -> -1 +ctmx654 comparetotmag -0.0 -0.0 -> 0 +ctmx655 comparetotmag -0.0 0.0 -> 0 + +ctmx656 comparetotmag -0E1 0.0 -> 1 +ctmx657 comparetotmag -0E2 0.0 -> 1 +ctmx658 comparetotmag 0E1 0.0 -> 1 +ctmx659 comparetotmag 0E2 0.0 -> 1 +ctmx660 comparetotmag -0E1 0 -> 1 +ctmx661 comparetotmag -0E2 0 -> 1 +ctmx662 comparetotmag 0E1 0 -> 1 +ctmx663 comparetotmag 0E2 0 -> 1 +ctmx664 comparetotmag -0E1 -0E1 -> 0 +ctmx665 comparetotmag -0E2 -0E1 -> 1 +ctmx666 comparetotmag 0E1 -0E1 -> 0 +ctmx667 comparetotmag 0E2 -0E1 -> 1 +ctmx668 comparetotmag -0E1 -0E2 -> -1 +ctmx669 comparetotmag -0E2 -0E2 -> 0 +ctmx670 comparetotmag 0E1 -0E2 -> -1 +ctmx671 comparetotmag 0E2 -0E2 -> 0 +ctmx672 comparetotmag -0E1 0E1 -> 0 +ctmx673 comparetotmag -0E2 0E1 -> 1 +ctmx674 comparetotmag 0E1 0E1 -> 0 +ctmx675 comparetotmag 0E2 0E1 -> 1 +ctmx676 comparetotmag -0E1 0E2 -> -1 +ctmx677 comparetotmag -0E2 0E2 -> 0 +ctmx678 comparetotmag 0E1 0E2 -> -1 +ctmx679 comparetotmag 0E2 0E2 -> 0 + +-- trailing zeros; unit-y +precision: 20 +ctmx680 comparetotmag 12 12 -> 0 +ctmx681 comparetotmag 12 12.0 -> 1 +ctmx682 comparetotmag 12 12.00 -> 1 +ctmx683 comparetotmag 12 12.000 -> 1 +ctmx684 comparetotmag 12 12.0000 -> 1 +ctmx685 comparetotmag 12 12.00000 -> 1 +ctmx686 comparetotmag 12 12.000000 -> 1 +ctmx687 comparetotmag 12 12.0000000 -> 1 +ctmx688 comparetotmag 12 12.00000000 -> 1 +ctmx689 comparetotmag 12 12.000000000 -> 1 +ctmx690 comparetotmag 12 12 -> 0 +ctmx691 comparetotmag 12.0 12 -> -1 +ctmx692 comparetotmag 12.00 12 -> -1 +ctmx693 comparetotmag 12.000 12 -> -1 +ctmx694 comparetotmag 12.0000 12 -> -1 +ctmx695 comparetotmag 12.00000 12 -> -1 +ctmx696 comparetotmag 12.000000 12 -> -1 +ctmx697 comparetotmag 12.0000000 12 -> -1 +ctmx698 comparetotmag 12.00000000 12 -> -1 +ctmx699 comparetotmag 12.000000000 12 -> -1 + +-- long operand checks +maxexponent: 999 +minexponent: -999 +precision: 9 +ctmx701 comparetotmag 12345678000 1 -> 1 +ctmx702 comparetotmag 1 12345678000 -> -1 +ctmx703 comparetotmag 1234567800 1 -> 1 +ctmx704 comparetotmag 1 1234567800 -> -1 +ctmx705 comparetotmag 1234567890 1 -> 1 +ctmx706 comparetotmag 1 1234567890 -> -1 +ctmx707 comparetotmag 1234567891 1 -> 1 +ctmx708 comparetotmag 1 1234567891 -> -1 +ctmx709 comparetotmag 12345678901 1 -> 1 +ctmx710 comparetotmag 1 12345678901 -> -1 +ctmx711 comparetotmag 1234567896 1 -> 1 +ctmx712 comparetotmag 1 1234567896 -> -1 +ctmx713 comparetotmag -1234567891 1 -> 1 +ctmx714 comparetotmag 1 -1234567891 -> -1 +ctmx715 comparetotmag -12345678901 1 -> 1 +ctmx716 comparetotmag 1 -12345678901 -> -1 +ctmx717 comparetotmag -1234567896 1 -> 1 +ctmx718 comparetotmag 1 -1234567896 -> -1 + +precision: 15 +-- same with plenty of precision +ctmx721 comparetotmag 12345678000 1 -> 1 +ctmx722 comparetotmag 1 12345678000 -> -1 +ctmx723 comparetotmag 1234567800 1 -> 1 +ctmx724 comparetotmag 1 1234567800 -> -1 +ctmx725 comparetotmag 1234567890 1 -> 1 +ctmx726 comparetotmag 1 1234567890 -> -1 +ctmx727 comparetotmag 1234567891 1 -> 1 +ctmx728 comparetotmag 1 1234567891 -> -1 +ctmx729 comparetotmag 12345678901 1 -> 1 +ctmx730 comparetotmag 1 12345678901 -> -1 +ctmx731 comparetotmag 1234567896 1 -> 1 +ctmx732 comparetotmag 1 1234567896 -> -1 + +-- residue cases +precision: 5 +ctmx740 comparetotmag 1 0.9999999 -> 1 +ctmx741 comparetotmag 1 0.999999 -> 1 +ctmx742 comparetotmag 1 0.99999 -> 1 +ctmx743 comparetotmag 1 1.0000 -> 1 +ctmx744 comparetotmag 1 1.00001 -> -1 +ctmx745 comparetotmag 1 1.000001 -> -1 +ctmx746 comparetotmag 1 1.0000001 -> -1 +ctmx750 comparetotmag 0.9999999 1 -> -1 +ctmx751 comparetotmag 0.999999 1 -> -1 +ctmx752 comparetotmag 0.99999 1 -> -1 +ctmx753 comparetotmag 1.0000 1 -> -1 +ctmx754 comparetotmag 1.00001 1 -> 1 +ctmx755 comparetotmag 1.000001 1 -> 1 +ctmx756 comparetotmag 1.0000001 1 -> 1 + +-- a selection of longies +ctmx760 comparetotmag -36852134.84194296250843579428931 -5830629.8347085025808756560357940 -> 1 +ctmx761 comparetotmag -36852134.84194296250843579428931 -36852134.84194296250843579428931 -> 0 +ctmx762 comparetotmag -36852134.94194296250843579428931 -36852134.84194296250843579428931 -> 1 +ctmx763 comparetotmag -36852134.84194296250843579428931 -36852134.94194296250843579428931 -> -1 +-- precisions above or below the difference should have no effect +precision: 11 +ctmx764 comparetotmag -36852134.84194296250843579428931 -36852134.94194296250843579428931 -> -1 +precision: 10 +ctmx765 comparetotmag -36852134.84194296250843579428931 -36852134.94194296250843579428931 -> -1 +precision: 9 +ctmx766 comparetotmag -36852134.84194296250843579428931 -36852134.94194296250843579428931 -> -1 +precision: 8 +ctmx767 comparetotmag -36852134.84194296250843579428931 -36852134.94194296250843579428931 -> -1 +precision: 7 +ctmx768 comparetotmag -36852134.84194296250843579428931 -36852134.94194296250843579428931 -> -1 +precision: 6 +ctmx769 comparetotmag -36852134.84194296250843579428931 -36852134.94194296250843579428931 -> -1 +precision: 5 +ctmx770 comparetotmag -36852134.84194296250843579428931 -36852134.94194296250843579428931 -> -1 +precision: 4 +ctmx771 comparetotmag -36852134.84194296250843579428931 -36852134.94194296250843579428931 -> -1 +precision: 3 +ctmx772 comparetotmag -36852134.84194296250843579428931 -36852134.94194296250843579428931 -> -1 +precision: 2 +ctmx773 comparetotmag -36852134.84194296250843579428931 -36852134.94194296250843579428931 -> -1 +precision: 1 +ctmx774 comparetotmag -36852134.84194296250843579428931 -36852134.94194296250843579428931 -> -1 + +-- Specials +precision: 9 +ctmx780 comparetotmag Inf -Inf -> 0 +ctmx781 comparetotmag Inf -1000 -> 1 +ctmx782 comparetotmag Inf -1 -> 1 +ctmx783 comparetotmag Inf -0 -> 1 +ctmx784 comparetotmag Inf 0 -> 1 +ctmx785 comparetotmag Inf 1 -> 1 +ctmx786 comparetotmag Inf 1000 -> 1 +ctmx787 comparetotmag Inf Inf -> 0 +ctmx788 comparetotmag -1000 Inf -> -1 +ctmx789 comparetotmag -Inf Inf -> 0 +ctmx790 comparetotmag -1 Inf -> -1 +ctmx791 comparetotmag -0 Inf -> -1 +ctmx792 comparetotmag 0 Inf -> -1 +ctmx793 comparetotmag 1 Inf -> -1 +ctmx794 comparetotmag 1000 Inf -> -1 +ctmx795 comparetotmag Inf Inf -> 0 + +ctmx800 comparetotmag -Inf -Inf -> 0 +ctmx801 comparetotmag -Inf -1000 -> 1 +ctmx802 comparetotmag -Inf -1 -> 1 +ctmx803 comparetotmag -Inf -0 -> 1 +ctmx804 comparetotmag -Inf 0 -> 1 +ctmx805 comparetotmag -Inf 1 -> 1 +ctmx806 comparetotmag -Inf 1000 -> 1 +ctmx807 comparetotmag -Inf Inf -> 0 +ctmx808 comparetotmag -Inf -Inf -> 0 +ctmx809 comparetotmag -1000 -Inf -> -1 +ctmx810 comparetotmag -1 -Inf -> -1 +ctmx811 comparetotmag -0 -Inf -> -1 +ctmx812 comparetotmag 0 -Inf -> -1 +ctmx813 comparetotmag 1 -Inf -> -1 +ctmx814 comparetotmag 1000 -Inf -> -1 +ctmx815 comparetotmag Inf -Inf -> 0 + +ctmx821 comparetotmag NaN -Inf -> 1 +ctmx822 comparetotmag NaN -1000 -> 1 +ctmx823 comparetotmag NaN -1 -> 1 +ctmx824 comparetotmag NaN -0 -> 1 +ctmx825 comparetotmag NaN 0 -> 1 +ctmx826 comparetotmag NaN 1 -> 1 +ctmx827 comparetotmag NaN 1000 -> 1 +ctmx828 comparetotmag NaN Inf -> 1 +ctmx829 comparetotmag NaN NaN -> 0 +ctmx830 comparetotmag -Inf NaN -> -1 +ctmx831 comparetotmag -1000 NaN -> -1 +ctmx832 comparetotmag -1 NaN -> -1 +ctmx833 comparetotmag -0 NaN -> -1 +ctmx834 comparetotmag 0 NaN -> -1 +ctmx835 comparetotmag 1 NaN -> -1 +ctmx836 comparetotmag 1000 NaN -> -1 +ctmx837 comparetotmag Inf NaN -> -1 +ctmx838 comparetotmag -NaN -NaN -> 0 +ctmx839 comparetotmag +NaN -NaN -> 0 +ctmx840 comparetotmag -NaN +NaN -> 0 + +ctmx841 comparetotmag sNaN -sNaN -> 0 +ctmx842 comparetotmag sNaN -NaN -> -1 +ctmx843 comparetotmag sNaN -Inf -> 1 +ctmx844 comparetotmag sNaN -1000 -> 1 +ctmx845 comparetotmag sNaN -1 -> 1 +ctmx846 comparetotmag sNaN -0 -> 1 +ctmx847 comparetotmag sNaN 0 -> 1 +ctmx848 comparetotmag sNaN 1 -> 1 +ctmx849 comparetotmag sNaN 1000 -> 1 +ctmx850 comparetotmag sNaN NaN -> -1 +ctmx851 comparetotmag sNaN sNaN -> 0 + +ctmx852 comparetotmag -sNaN sNaN -> 0 +ctmx853 comparetotmag -NaN sNaN -> 1 +ctmx854 comparetotmag -Inf sNaN -> -1 +ctmx855 comparetotmag -1000 sNaN -> -1 +ctmx856 comparetotmag -1 sNaN -> -1 +ctmx857 comparetotmag -0 sNaN -> -1 +ctmx858 comparetotmag 0 sNaN -> -1 +ctmx859 comparetotmag 1 sNaN -> -1 +ctmx860 comparetotmag 1000 sNaN -> -1 +ctmx861 comparetotmag Inf sNaN -> -1 +ctmx862 comparetotmag NaN sNaN -> 1 +ctmx863 comparetotmag sNaN sNaN -> 0 + +ctmx871 comparetotmag -sNaN -sNaN -> 0 +ctmx872 comparetotmag -sNaN -NaN -> -1 +ctmx873 comparetotmag -sNaN -Inf -> 1 +ctmx874 comparetotmag -sNaN -1000 -> 1 +ctmx875 comparetotmag -sNaN -1 -> 1 +ctmx876 comparetotmag -sNaN -0 -> 1 +ctmx877 comparetotmag -sNaN 0 -> 1 +ctmx878 comparetotmag -sNaN 1 -> 1 +ctmx879 comparetotmag -sNaN 1000 -> 1 +ctmx880 comparetotmag -sNaN NaN -> -1 +ctmx881 comparetotmag -sNaN sNaN -> 0 + +ctmx882 comparetotmag -sNaN -sNaN -> 0 +ctmx883 comparetotmag -NaN -sNaN -> 1 +ctmx884 comparetotmag -Inf -sNaN -> -1 +ctmx885 comparetotmag -1000 -sNaN -> -1 +ctmx886 comparetotmag -1 -sNaN -> -1 +ctmx887 comparetotmag -0 -sNaN -> -1 +ctmx888 comparetotmag 0 -sNaN -> -1 +ctmx889 comparetotmag 1 -sNaN -> -1 +ctmx890 comparetotmag 1000 -sNaN -> -1 +ctmx891 comparetotmag Inf -sNaN -> -1 +ctmx892 comparetotmag NaN -sNaN -> 1 +ctmx893 comparetotmag sNaN -sNaN -> 0 + +-- NaNs with payload +ctmx960 comparetotmag NaN9 -Inf -> 1 +ctmx961 comparetotmag NaN8 999 -> 1 +ctmx962 comparetotmag NaN77 Inf -> 1 +ctmx963 comparetotmag -NaN67 NaN5 -> 1 +ctmx964 comparetotmag -Inf -NaN4 -> -1 +ctmx965 comparetotmag -999 -NaN33 -> -1 +ctmx966 comparetotmag Inf NaN2 -> -1 + +ctmx970 comparetotmag -NaN41 -NaN42 -> -1 +ctmx971 comparetotmag +NaN41 -NaN42 -> -1 +ctmx972 comparetotmag -NaN41 +NaN42 -> -1 +ctmx973 comparetotmag +NaN41 +NaN42 -> -1 +ctmx974 comparetotmag -NaN42 -NaN01 -> 1 +ctmx975 comparetotmag +NaN42 -NaN01 -> 1 +ctmx976 comparetotmag -NaN42 +NaN01 -> 1 +ctmx977 comparetotmag +NaN42 +NaN01 -> 1 + +ctmx980 comparetotmag -sNaN771 -sNaN772 -> -1 +ctmx981 comparetotmag +sNaN771 -sNaN772 -> -1 +ctmx982 comparetotmag -sNaN771 +sNaN772 -> -1 +ctmx983 comparetotmag +sNaN771 +sNaN772 -> -1 +ctmx984 comparetotmag -sNaN772 -sNaN771 -> 1 +ctmx985 comparetotmag +sNaN772 -sNaN771 -> 1 +ctmx986 comparetotmag -sNaN772 +sNaN771 -> 1 +ctmx987 comparetotmag +sNaN772 +sNaN771 -> 1 + +ctmx991 comparetotmag -sNaN99 -Inf -> 1 +ctmx992 comparetotmag sNaN98 -11 -> 1 +ctmx993 comparetotmag sNaN97 NaN -> -1 +ctmx994 comparetotmag sNaN16 sNaN94 -> -1 +ctmx995 comparetotmag NaN85 sNaN83 -> 1 +ctmx996 comparetotmag -Inf sNaN92 -> -1 +ctmx997 comparetotmag 088 sNaN81 -> -1 +ctmx998 comparetotmag Inf sNaN90 -> -1 +ctmx999 comparetotmag NaN -sNaN89 -> 1 + +-- overflow and underflow tests .. subnormal results now allowed +maxExponent: 999999999 +minexponent: -999999999 +ctmx1080 comparetotmag +1.23456789012345E-0 9E+999999999 -> -1 +ctmx1081 comparetotmag 9E+999999999 +1.23456789012345E-0 -> 1 +ctmx1082 comparetotmag +0.100 9E-999999999 -> 1 +ctmx1083 comparetotmag 9E-999999999 +0.100 -> -1 +ctmx1085 comparetotmag -1.23456789012345E-0 9E+999999999 -> -1 +ctmx1086 comparetotmag 9E+999999999 -1.23456789012345E-0 -> 1 +ctmx1087 comparetotmag -0.100 9E-999999999 -> 1 +ctmx1088 comparetotmag 9E-999999999 -0.100 -> -1 + +ctmx1089 comparetotmag 1e-599999999 1e-400000001 -> -1 +ctmx1090 comparetotmag 1e-599999999 1e-400000000 -> -1 +ctmx1091 comparetotmag 1e-600000000 1e-400000000 -> -1 +ctmx1092 comparetotmag 9e-999999998 0.01 -> -1 +ctmx1093 comparetotmag 9e-999999998 0.1 -> -1 +ctmx1094 comparetotmag 0.01 9e-999999998 -> 1 +ctmx1095 comparetotmag 1e599999999 1e400000001 -> 1 +ctmx1096 comparetotmag 1e599999999 1e400000000 -> 1 +ctmx1097 comparetotmag 1e600000000 1e400000000 -> 1 +ctmx1098 comparetotmag 9e999999998 100 -> 1 +ctmx1099 comparetotmag 9e999999998 10 -> 1 +ctmx1100 comparetotmag 100 9e999999998 -> -1 +-- signs +ctmx1101 comparetotmag 1e+777777777 1e+411111111 -> 1 +ctmx1102 comparetotmag 1e+777777777 -1e+411111111 -> 1 +ctmx1103 comparetotmag -1e+777777777 1e+411111111 -> 1 +ctmx1104 comparetotmag -1e+777777777 -1e+411111111 -> 1 +ctmx1105 comparetotmag 1e-777777777 1e-411111111 -> -1 +ctmx1106 comparetotmag 1e-777777777 -1e-411111111 -> -1 +ctmx1107 comparetotmag -1e-777777777 1e-411111111 -> -1 +ctmx1108 comparetotmag -1e-777777777 -1e-411111111 -> -1 + +-- spread zeros +ctmx1110 comparetotmag 0E-383 0 -> -1 +ctmx1111 comparetotmag 0E-383 -0 -> -1 +ctmx1112 comparetotmag -0E-383 0 -> -1 +ctmx1113 comparetotmag -0E-383 -0 -> -1 +ctmx1114 comparetotmag 0E-383 0E+384 -> -1 +ctmx1115 comparetotmag 0E-383 -0E+384 -> -1 +ctmx1116 comparetotmag -0E-383 0E+384 -> -1 +ctmx1117 comparetotmag -0E-383 -0E+384 -> -1 +ctmx1118 comparetotmag 0 0E+384 -> -1 +ctmx1119 comparetotmag 0 -0E+384 -> -1 +ctmx1120 comparetotmag -0 0E+384 -> -1 +ctmx1121 comparetotmag -0 -0E+384 -> -1 + +ctmx1130 comparetotmag 0E+384 0 -> 1 +ctmx1131 comparetotmag 0E+384 -0 -> 1 +ctmx1132 comparetotmag -0E+384 0 -> 1 +ctmx1133 comparetotmag -0E+384 -0 -> 1 +ctmx1134 comparetotmag 0E+384 0E-383 -> 1 +ctmx1135 comparetotmag 0E+384 -0E-383 -> 1 +ctmx1136 comparetotmag -0E+384 0E-383 -> 1 +ctmx1137 comparetotmag -0E+384 -0E-383 -> 1 +ctmx1138 comparetotmag 0 0E-383 -> 1 +ctmx1139 comparetotmag 0 -0E-383 -> 1 +ctmx1140 comparetotmag -0 0E-383 -> 1 +ctmx1141 comparetotmag -0 -0E-383 -> 1 + +-- Null tests +ctmx9990 comparetotmag 10 # -> NaN Invalid_operation +ctmx9991 comparetotmag # 10 -> NaN Invalid_operation Added: python/branches/release25-maint/Lib/test/decimaltestdata/copy.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/copy.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,86 @@ +------------------------------------------------------------------------ +-- copy.decTest -- quiet copy -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +extended: 1 +precision: 9 +rounding: half_up +maxExponent: 999 +minExponent: -999 + +-- Sanity check +cpyx001 copy +7.50 -> 7.50 + +-- Infinities +cpyx011 copy Infinity -> Infinity +cpyx012 copy -Infinity -> -Infinity + +-- NaNs, 0 payload +cpyx021 copy NaN -> NaN +cpyx022 copy -NaN -> -NaN +cpyx023 copy sNaN -> sNaN +cpyx024 copy -sNaN -> -sNaN + +-- NaNs, non-0 payload +cpyx031 copy NaN10 -> NaN10 +cpyx032 copy -NaN10 -> -NaN10 +cpyx033 copy sNaN10 -> sNaN10 +cpyx034 copy -sNaN10 -> -sNaN10 +cpyx035 copy NaN7 -> NaN7 +cpyx036 copy -NaN7 -> -NaN7 +cpyx037 copy sNaN101 -> sNaN101 +cpyx038 copy -sNaN101 -> -sNaN101 + +-- finites +cpyx101 copy 7 -> 7 +cpyx102 copy -7 -> -7 +cpyx103 copy 75 -> 75 +cpyx104 copy -75 -> -75 +cpyx105 copy 7.50 -> 7.50 +cpyx106 copy -7.50 -> -7.50 +cpyx107 copy 7.500 -> 7.500 +cpyx108 copy -7.500 -> -7.500 + +-- zeros +cpyx111 copy 0 -> 0 +cpyx112 copy -0 -> -0 +cpyx113 copy 0E+4 -> 0E+4 +cpyx114 copy -0E+4 -> -0E+4 +cpyx115 copy 0.0000 -> 0.0000 +cpyx116 copy -0.0000 -> -0.0000 +cpyx117 copy 0E-141 -> 0E-141 +cpyx118 copy -0E-141 -> -0E-141 + +-- full coefficients, alternating bits +cpyx121 copy 268268268 -> 268268268 +cpyx122 copy -268268268 -> -268268268 +cpyx123 copy 134134134 -> 134134134 +cpyx124 copy -134134134 -> -134134134 + +-- Nmax, Nmin, Ntiny +cpyx131 copy 9.99999999E+999 -> 9.99999999E+999 +cpyx132 copy 1E-999 -> 1E-999 +cpyx133 copy 1.00000000E-999 -> 1.00000000E-999 +cpyx134 copy 1E-1007 -> 1E-1007 + +cpyx135 copy -1E-1007 -> -1E-1007 +cpyx136 copy -1.00000000E-999 -> -1.00000000E-999 +cpyx137 copy -1E-999 -> -1E-999 +cpyx138 copy -9.99999999E+999 -> -9.99999999E+999 Added: python/branches/release25-maint/Lib/test/decimaltestdata/copyabs.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/copyabs.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,86 @@ +------------------------------------------------------------------------ +-- copyAbs.decTest -- quiet copy and set sign to zero -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +extended: 1 +precision: 9 +rounding: half_up +maxExponent: 999 +minExponent: -999 + +-- Sanity check +cpax001 copyabs +7.50 -> 7.50 + +-- Infinities +cpax011 copyabs Infinity -> Infinity +cpax012 copyabs -Infinity -> Infinity + +-- NaNs, 0 payload +cpax021 copyabs NaN -> NaN +cpax022 copyabs -NaN -> NaN +cpax023 copyabs sNaN -> sNaN +cpax024 copyabs -sNaN -> sNaN + +-- NaNs, non-0 payload +cpax031 copyabs NaN10 -> NaN10 +cpax032 copyabs -NaN15 -> NaN15 +cpax033 copyabs sNaN15 -> sNaN15 +cpax034 copyabs -sNaN10 -> sNaN10 +cpax035 copyabs NaN7 -> NaN7 +cpax036 copyabs -NaN7 -> NaN7 +cpax037 copyabs sNaN101 -> sNaN101 +cpax038 copyabs -sNaN101 -> sNaN101 + +-- finites +cpax101 copyabs 7 -> 7 +cpax102 copyabs -7 -> 7 +cpax103 copyabs 75 -> 75 +cpax104 copyabs -75 -> 75 +cpax105 copyabs 7.10 -> 7.10 +cpax106 copyabs -7.10 -> 7.10 +cpax107 copyabs 7.500 -> 7.500 +cpax108 copyabs -7.500 -> 7.500 + +-- zeros +cpax111 copyabs 0 -> 0 +cpax112 copyabs -0 -> 0 +cpax113 copyabs 0E+6 -> 0E+6 +cpax114 copyabs -0E+6 -> 0E+6 +cpax115 copyabs 0.0000 -> 0.0000 +cpax116 copyabs -0.0000 -> 0.0000 +cpax117 copyabs 0E-141 -> 0E-141 +cpax118 copyabs -0E-141 -> 0E-141 + +-- full coefficients, alternating bits +cpax121 copyabs 268268268 -> 268268268 +cpax122 copyabs -268268268 -> 268268268 +cpax123 copyabs 134134134 -> 134134134 +cpax124 copyabs -134134134 -> 134134134 + +-- Nmax, Nmin, Ntiny +cpax131 copyabs 9.99999999E+999 -> 9.99999999E+999 +cpax132 copyabs 1E-999 -> 1E-999 +cpax133 copyabs 1.00000000E-999 -> 1.00000000E-999 +cpax134 copyabs 1E-1007 -> 1E-1007 + +cpax135 copyabs -1E-1007 -> 1E-1007 +cpax136 copyabs -1.00000000E-999 -> 1.00000000E-999 +cpax137 copyabs -1E-999 -> 1E-999 +cpax199 copyabs -9.99999999E+999 -> 9.99999999E+999 Added: python/branches/release25-maint/Lib/test/decimaltestdata/copynegate.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/copynegate.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,86 @@ +------------------------------------------------------------------------ +-- copyNegate.decTest -- quiet copy and negate -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +extended: 1 +precision: 9 +rounding: half_up +maxExponent: 999 +minExponent: -999 + +-- Sanity check +cpnx001 copynegate +7.50 -> -7.50 + +-- Infinities +cpnx011 copynegate Infinity -> -Infinity +cpnx012 copynegate -Infinity -> Infinity + +-- NaNs, 0 payload +cpnx021 copynegate NaN -> -NaN +cpnx022 copynegate -NaN -> NaN +cpnx023 copynegate sNaN -> -sNaN +cpnx024 copynegate -sNaN -> sNaN + +-- NaNs, non-0 payload +cpnx031 copynegate NaN13 -> -NaN13 +cpnx032 copynegate -NaN13 -> NaN13 +cpnx033 copynegate sNaN13 -> -sNaN13 +cpnx034 copynegate -sNaN13 -> sNaN13 +cpnx035 copynegate NaN70 -> -NaN70 +cpnx036 copynegate -NaN70 -> NaN70 +cpnx037 copynegate sNaN101 -> -sNaN101 +cpnx038 copynegate -sNaN101 -> sNaN101 + +-- finites +cpnx101 copynegate 7 -> -7 +cpnx102 copynegate -7 -> 7 +cpnx103 copynegate 75 -> -75 +cpnx104 copynegate -75 -> 75 +cpnx105 copynegate 7.50 -> -7.50 +cpnx106 copynegate -7.50 -> 7.50 +cpnx107 copynegate 7.500 -> -7.500 +cpnx108 copynegate -7.500 -> 7.500 + +-- zeros +cpnx111 copynegate 0 -> -0 +cpnx112 copynegate -0 -> 0 +cpnx113 copynegate 0E+4 -> -0E+4 +cpnx114 copynegate -0E+4 -> 0E+4 +cpnx115 copynegate 0.0000 -> -0.0000 +cpnx116 copynegate -0.0000 -> 0.0000 +cpnx117 copynegate 0E-141 -> -0E-141 +cpnx118 copynegate -0E-141 -> 0E-141 + +-- full coefficients, alternating bits +cpnx121 copynegate 268268268 -> -268268268 +cpnx122 copynegate -268268268 -> 268268268 +cpnx123 copynegate 134134134 -> -134134134 +cpnx124 copynegate -134134134 -> 134134134 + +-- Nmax, Nmin, Ntiny +cpnx131 copynegate 9.99999999E+999 -> -9.99999999E+999 +cpnx132 copynegate 1E-999 -> -1E-999 +cpnx133 copynegate 1.00000000E-999 -> -1.00000000E-999 +cpnx134 copynegate 1E-1007 -> -1E-1007 + +cpnx135 copynegate -1E-1007 -> 1E-1007 +cpnx136 copynegate -1.00000000E-999 -> 1.00000000E-999 +cpnx137 copynegate -1E-999 -> 1E-999 +cpnx138 copynegate -9.99999999E+999 -> 9.99999999E+999 Added: python/branches/release25-maint/Lib/test/decimaltestdata/copysign.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/copysign.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,177 @@ +------------------------------------------------------------------------ +-- copysign.decTest -- quiet copy with sign from rhs -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +extended: 1 +precision: 9 +rounding: half_up +maxExponent: 999 +minExponent: -999 + +-- Sanity check, and examples from decArith +cpsx001 copysign +7.50 11 -> 7.50 +cpsx002 copysign '1.50' '7.33' -> 1.50 +cpsx003 copysign '-1.50' '7.33' -> 1.50 +cpsx004 copysign '1.50' '-7.33' -> -1.50 +cpsx005 copysign '-1.50' '-7.33' -> -1.50 + +-- Infinities +cpsx011 copysign Infinity 11 -> Infinity +cpsx012 copysign -Infinity 11 -> Infinity + +-- NaNs, 0 payload +cpsx021 copysign NaN 11 -> NaN +cpsx022 copysign -NaN 11 -> NaN +cpsx023 copysign sNaN 11 -> sNaN +cpsx024 copysign -sNaN 11 -> sNaN + +-- NaNs, non-0 payload +cpsx031 copysign NaN10 11 -> NaN10 +cpsx032 copysign -NaN10 11 -> NaN10 +cpsx033 copysign sNaN10 11 -> sNaN10 +cpsx034 copysign -sNaN10 11 -> sNaN10 +cpsx035 copysign NaN7 11 -> NaN7 +cpsx036 copysign -NaN7 11 -> NaN7 +cpsx037 copysign sNaN101 11 -> sNaN101 +cpsx038 copysign -sNaN101 11 -> sNaN101 + +-- finites +cpsx101 copysign 7 11 -> 7 +cpsx102 copysign -7 11 -> 7 +cpsx103 copysign 75 11 -> 75 +cpsx104 copysign -75 11 -> 75 +cpsx105 copysign 7.50 11 -> 7.50 +cpsx106 copysign -7.50 11 -> 7.50 +cpsx107 copysign 7.500 11 -> 7.500 +cpsx108 copysign -7.500 11 -> 7.500 + +-- zeros +cpsx111 copysign 0 11 -> 0 +cpsx112 copysign -0 11 -> 0 +cpsx113 copysign 0E+4 11 -> 0E+4 +cpsx114 copysign -0E+4 11 -> 0E+4 +cpsx115 copysign 0.0000 11 -> 0.0000 +cpsx116 copysign -0.0000 11 -> 0.0000 +cpsx117 copysign 0E-141 11 -> 0E-141 +cpsx118 copysign -0E-141 11 -> 0E-141 + +-- full coefficients, alternating bits +cpsx121 copysign 268268268 11 -> 268268268 +cpsx122 copysign -268268268 11 -> 268268268 +cpsx123 copysign 134134134 11 -> 134134134 +cpsx124 copysign -134134134 11 -> 134134134 + +-- Nmax, Nmin, Ntiny +cpsx131 copysign 9.99999999E+999 11 -> 9.99999999E+999 +cpsx132 copysign 1E-999 11 -> 1E-999 +cpsx133 copysign 1.00000000E-999 11 -> 1.00000000E-999 +cpsx134 copysign 1E-1007 11 -> 1E-1007 + +cpsx135 copysign -1E-1007 11 -> 1E-1007 +cpsx136 copysign -1.00000000E-999 11 -> 1.00000000E-999 +cpsx137 copysign -1E-999 11 -> 1E-999 +cpsx138 copysign -9.99999999E+999 11 -> 9.99999999E+999 + +-- repeat with negative RHS + +-- Infinities +cpsx211 copysign Infinity -34 -> -Infinity +cpsx212 copysign -Infinity -34 -> -Infinity + +-- NaNs, 0 payload +cpsx221 copysign NaN -34 -> -NaN +cpsx222 copysign -NaN -34 -> -NaN +cpsx223 copysign sNaN -34 -> -sNaN +cpsx224 copysign -sNaN -34 -> -sNaN + +-- NaNs, non-0 payload +cpsx231 copysign NaN10 -34 -> -NaN10 +cpsx232 copysign -NaN10 -34 -> -NaN10 +cpsx233 copysign sNaN10 -34 -> -sNaN10 +cpsx234 copysign -sNaN10 -34 -> -sNaN10 +cpsx235 copysign NaN7 -34 -> -NaN7 +cpsx236 copysign -NaN7 -34 -> -NaN7 +cpsx237 copysign sNaN101 -34 -> -sNaN101 +cpsx238 copysign -sNaN101 -34 -> -sNaN101 + +-- finites +cpsx301 copysign 7 -34 -> -7 +cpsx302 copysign -7 -34 -> -7 +cpsx303 copysign 75 -34 -> -75 +cpsx304 copysign -75 -34 -> -75 +cpsx305 copysign 7.50 -34 -> -7.50 +cpsx306 copysign -7.50 -34 -> -7.50 +cpsx307 copysign 7.500 -34 -> -7.500 +cpsx308 copysign -7.500 -34 -> -7.500 + +-- zeros +cpsx311 copysign 0 -34 -> -0 +cpsx312 copysign -0 -34 -> -0 +cpsx313 copysign 0E+4 -34 -> -0E+4 +cpsx314 copysign -0E+4 -34 -> -0E+4 +cpsx315 copysign 0.0000 -34 -> -0.0000 +cpsx316 copysign -0.0000 -34 -> -0.0000 +cpsx317 copysign 0E-141 -34 -> -0E-141 +cpsx318 copysign -0E-141 -34 -> -0E-141 + +-- full coefficients, alternating bits +cpsx321 copysign 268268268 -18 -> -268268268 +cpsx322 copysign -268268268 -18 -> -268268268 +cpsx323 copysign 134134134 -18 -> -134134134 +cpsx324 copysign -134134134 -18 -> -134134134 + +-- Nmax, Nmin, Ntiny +cpsx331 copysign 9.99999999E+999 -18 -> -9.99999999E+999 +cpsx332 copysign 1E-999 -18 -> -1E-999 +cpsx333 copysign 1.00000000E-999 -18 -> -1.00000000E-999 +cpsx334 copysign 1E-1007 -18 -> -1E-1007 + +cpsx335 copysign -1E-1007 -18 -> -1E-1007 +cpsx336 copysign -1.00000000E-999 -18 -> -1.00000000E-999 +cpsx337 copysign -1E-999 -18 -> -1E-999 +cpsx338 copysign -9.99999999E+999 -18 -> -9.99999999E+999 + +-- Other kinds of RHS +cpsx401 copysign 701 -34 -> -701 +cpsx402 copysign -720 -34 -> -720 +cpsx403 copysign 701 -0 -> -701 +cpsx404 copysign -720 -0 -> -720 +cpsx405 copysign 701 +0 -> 701 +cpsx406 copysign -720 +0 -> 720 +cpsx407 copysign 701 +34 -> 701 +cpsx408 copysign -720 +34 -> 720 + +cpsx413 copysign 701 -Inf -> -701 +cpsx414 copysign -720 -Inf -> -720 +cpsx415 copysign 701 +Inf -> 701 +cpsx416 copysign -720 +Inf -> 720 + +cpsx420 copysign 701 -NaN -> -701 +cpsx421 copysign -720 -NaN -> -720 +cpsx422 copysign 701 +NaN -> 701 +cpsx423 copysign -720 +NaN -> 720 +cpsx425 copysign -720 +NaN8 -> 720 + +cpsx426 copysign 701 -sNaN -> -701 +cpsx427 copysign -720 -sNaN -> -720 +cpsx428 copysign 701 +sNaN -> 701 +cpsx429 copysign -720 +sNaN -> 720 +cpsx430 copysign -720 +sNaN3 -> 720 + Added: python/branches/release25-maint/Lib/test/decimaltestdata/ddAbs.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/ddAbs.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,126 @@ +------------------------------------------------------------------------ +-- ddAbs.decTest -- decDouble absolute value, heeding sNaN -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +precision: 16 +maxExponent: 384 +minExponent: -383 +extended: 1 +clamp: 1 +rounding: half_even + +ddabs001 abs '1' -> '1' +ddabs002 abs '-1' -> '1' +ddabs003 abs '1.00' -> '1.00' +ddabs004 abs '-1.00' -> '1.00' +ddabs005 abs '0' -> '0' +ddabs006 abs '0.00' -> '0.00' +ddabs007 abs '00.0' -> '0.0' +ddabs008 abs '00.00' -> '0.00' +ddabs009 abs '00' -> '0' + +ddabs010 abs '-2' -> '2' +ddabs011 abs '2' -> '2' +ddabs012 abs '-2.00' -> '2.00' +ddabs013 abs '2.00' -> '2.00' +ddabs014 abs '-0' -> '0' +ddabs015 abs '-0.00' -> '0.00' +ddabs016 abs '-00.0' -> '0.0' +ddabs017 abs '-00.00' -> '0.00' +ddabs018 abs '-00' -> '0' + +ddabs020 abs '-2000000' -> '2000000' +ddabs021 abs '2000000' -> '2000000' + +ddabs030 abs '+0.1' -> '0.1' +ddabs031 abs '-0.1' -> '0.1' +ddabs032 abs '+0.01' -> '0.01' +ddabs033 abs '-0.01' -> '0.01' +ddabs034 abs '+0.001' -> '0.001' +ddabs035 abs '-0.001' -> '0.001' +ddabs036 abs '+0.000001' -> '0.000001' +ddabs037 abs '-0.000001' -> '0.000001' +ddabs038 abs '+0.000000000001' -> '1E-12' +ddabs039 abs '-0.000000000001' -> '1E-12' + +-- examples from decArith +ddabs040 abs '2.1' -> '2.1' +ddabs041 abs '-100' -> '100' +ddabs042 abs '101.5' -> '101.5' +ddabs043 abs '-101.5' -> '101.5' + +-- more fixed, potential LHS swaps/overlays if done by subtract 0 +ddabs060 abs '-56267E-10' -> '0.0000056267' +ddabs061 abs '-56267E-5' -> '0.56267' +ddabs062 abs '-56267E-2' -> '562.67' +ddabs063 abs '-56267E-1' -> '5626.7' +ddabs065 abs '-56267E-0' -> '56267' + +-- subnormals and underflow + +-- long operand tests +ddabs321 abs 1234567890123456 -> 1234567890123456 +ddabs322 abs 12345678000 -> 12345678000 +ddabs323 abs 1234567800 -> 1234567800 +ddabs324 abs 1234567890 -> 1234567890 +ddabs325 abs 1234567891 -> 1234567891 +ddabs326 abs 12345678901 -> 12345678901 +ddabs327 abs 1234567896 -> 1234567896 + +-- zeros +ddabs111 abs 0 -> 0 +ddabs112 abs -0 -> 0 +ddabs113 abs 0E+6 -> 0E+6 +ddabs114 abs -0E+6 -> 0E+6 +ddabs115 abs 0.0000 -> 0.0000 +ddabs116 abs -0.0000 -> 0.0000 +ddabs117 abs 0E-141 -> 0E-141 +ddabs118 abs -0E-141 -> 0E-141 + +-- full coefficients, alternating bits +ddabs121 abs 2682682682682682 -> 2682682682682682 +ddabs122 abs -2682682682682682 -> 2682682682682682 +ddabs123 abs 1341341341341341 -> 1341341341341341 +ddabs124 abs -1341341341341341 -> 1341341341341341 + +-- Nmax, Nmin, Ntiny +ddabs131 abs 9.999999999999999E+384 -> 9.999999999999999E+384 +ddabs132 abs 1E-383 -> 1E-383 +ddabs133 abs 1.000000000000000E-383 -> 1.000000000000000E-383 +ddabs134 abs 1E-398 -> 1E-398 Subnormal + +ddabs135 abs -1E-398 -> 1E-398 Subnormal +ddabs136 abs -1.000000000000000E-383 -> 1.000000000000000E-383 +ddabs137 abs -1E-383 -> 1E-383 +ddabs138 abs -9.999999999999999E+384 -> 9.999999999999999E+384 + +-- specials +ddabs520 abs 'Inf' -> 'Infinity' +ddabs521 abs '-Inf' -> 'Infinity' +ddabs522 abs NaN -> NaN +ddabs523 abs sNaN -> NaN Invalid_operation +ddabs524 abs NaN22 -> NaN22 +ddabs525 abs sNaN33 -> NaN33 Invalid_operation +ddabs526 abs -NaN22 -> -NaN22 +ddabs527 abs -sNaN33 -> -NaN33 Invalid_operation + +-- Null tests +ddabs900 abs # -> NaN Invalid_operation + Added: python/branches/release25-maint/Lib/test/decimaltestdata/ddAdd.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/ddAdd.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,1300 @@ +------------------------------------------------------------------------ +-- ddAdd.decTest -- decDouble addition -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- This set of tests are for decDoubles only; all arguments are +-- representable in a decDouble +precision: 16 +maxExponent: 384 +minExponent: -383 +extended: 1 +clamp: 1 +rounding: half_even + +-- [first group are 'quick confidence check'] +ddadd001 add 1 1 -> 2 +ddadd002 add 2 3 -> 5 +ddadd003 add '5.75' '3.3' -> 9.05 +ddadd004 add '5' '-3' -> 2 +ddadd005 add '-5' '-3' -> -8 +ddadd006 add '-7' '2.5' -> -4.5 +ddadd007 add '0.7' '0.3' -> 1.0 +ddadd008 add '1.25' '1.25' -> 2.50 +ddadd009 add '1.23456789' '1.00000000' -> '2.23456789' +ddadd010 add '1.23456789' '1.00000011' -> '2.23456800' + +-- 1234567890123456 1234567890123456 +ddadd011 add '0.4444444444444446' '0.5555555555555555' -> '1.000000000000000' Inexact Rounded +ddadd012 add '0.4444444444444445' '0.5555555555555555' -> '1.000000000000000' Rounded +ddadd013 add '0.4444444444444444' '0.5555555555555555' -> '0.9999999999999999' +ddadd014 add '4444444444444444' '0.49' -> '4444444444444444' Inexact Rounded +ddadd015 add '4444444444444444' '0.499' -> '4444444444444444' Inexact Rounded +ddadd016 add '4444444444444444' '0.4999' -> '4444444444444444' Inexact Rounded +ddadd017 add '4444444444444444' '0.5000' -> '4444444444444444' Inexact Rounded +ddadd018 add '4444444444444444' '0.5001' -> '4444444444444445' Inexact Rounded +ddadd019 add '4444444444444444' '0.501' -> '4444444444444445' Inexact Rounded +ddadd020 add '4444444444444444' '0.51' -> '4444444444444445' Inexact Rounded + +ddadd021 add 0 1 -> 1 +ddadd022 add 1 1 -> 2 +ddadd023 add 2 1 -> 3 +ddadd024 add 3 1 -> 4 +ddadd025 add 4 1 -> 5 +ddadd026 add 5 1 -> 6 +ddadd027 add 6 1 -> 7 +ddadd028 add 7 1 -> 8 +ddadd029 add 8 1 -> 9 +ddadd030 add 9 1 -> 10 + +-- some carrying effects +ddadd031 add '0.9998' '0.0000' -> '0.9998' +ddadd032 add '0.9998' '0.0001' -> '0.9999' +ddadd033 add '0.9998' '0.0002' -> '1.0000' +ddadd034 add '0.9998' '0.0003' -> '1.0001' + +ddadd035 add '70' '10000e+16' -> '1.000000000000000E+20' Inexact Rounded +ddadd036 add '700' '10000e+16' -> '1.000000000000000E+20' Inexact Rounded +ddadd037 add '7000' '10000e+16' -> '1.000000000000000E+20' Inexact Rounded +ddadd038 add '70000' '10000e+16' -> '1.000000000000001E+20' Inexact Rounded +ddadd039 add '700000' '10000e+16' -> '1.000000000000007E+20' Rounded + +-- symmetry: +ddadd040 add '10000e+16' '70' -> '1.000000000000000E+20' Inexact Rounded +ddadd041 add '10000e+16' '700' -> '1.000000000000000E+20' Inexact Rounded +ddadd042 add '10000e+16' '7000' -> '1.000000000000000E+20' Inexact Rounded +ddadd044 add '10000e+16' '70000' -> '1.000000000000001E+20' Inexact Rounded +ddadd045 add '10000e+16' '700000' -> '1.000000000000007E+20' Rounded + +-- same, without rounding +ddadd046 add '10000e+9' '7' -> '10000000000007' +ddadd047 add '10000e+9' '70' -> '10000000000070' +ddadd048 add '10000e+9' '700' -> '10000000000700' +ddadd049 add '10000e+9' '7000' -> '10000000007000' +ddadd050 add '10000e+9' '70000' -> '10000000070000' +ddadd051 add '10000e+9' '700000' -> '10000000700000' +ddadd052 add '10000e+9' '7000000' -> '10000007000000' + +-- examples from decarith +ddadd053 add '12' '7.00' -> '19.00' +ddadd054 add '1.3' '-1.07' -> '0.23' +ddadd055 add '1.3' '-1.30' -> '0.00' +ddadd056 add '1.3' '-2.07' -> '-0.77' +ddadd057 add '1E+2' '1E+4' -> '1.01E+4' + +-- leading zero preservation +ddadd061 add 1 '0.0001' -> '1.0001' +ddadd062 add 1 '0.00001' -> '1.00001' +ddadd063 add 1 '0.000001' -> '1.000001' +ddadd064 add 1 '0.0000001' -> '1.0000001' +ddadd065 add 1 '0.00000001' -> '1.00000001' + +-- some funny zeros [in case of bad signum] +ddadd070 add 1 0 -> 1 +ddadd071 add 1 0. -> 1 +ddadd072 add 1 .0 -> 1.0 +ddadd073 add 1 0.0 -> 1.0 +ddadd074 add 1 0.00 -> 1.00 +ddadd075 add 0 1 -> 1 +ddadd076 add 0. 1 -> 1 +ddadd077 add .0 1 -> 1.0 +ddadd078 add 0.0 1 -> 1.0 +ddadd079 add 0.00 1 -> 1.00 + +-- some carries +ddadd080 add 999999998 1 -> 999999999 +ddadd081 add 999999999 1 -> 1000000000 +ddadd082 add 99999999 1 -> 100000000 +ddadd083 add 9999999 1 -> 10000000 +ddadd084 add 999999 1 -> 1000000 +ddadd085 add 99999 1 -> 100000 +ddadd086 add 9999 1 -> 10000 +ddadd087 add 999 1 -> 1000 +ddadd088 add 99 1 -> 100 +ddadd089 add 9 1 -> 10 + + +-- more LHS swaps +ddadd090 add '-56267E-10' 0 -> '-0.0000056267' +ddadd091 add '-56267E-6' 0 -> '-0.056267' +ddadd092 add '-56267E-5' 0 -> '-0.56267' +ddadd093 add '-56267E-4' 0 -> '-5.6267' +ddadd094 add '-56267E-3' 0 -> '-56.267' +ddadd095 add '-56267E-2' 0 -> '-562.67' +ddadd096 add '-56267E-1' 0 -> '-5626.7' +ddadd097 add '-56267E-0' 0 -> '-56267' +ddadd098 add '-5E-10' 0 -> '-5E-10' +ddadd099 add '-5E-7' 0 -> '-5E-7' +ddadd100 add '-5E-6' 0 -> '-0.000005' +ddadd101 add '-5E-5' 0 -> '-0.00005' +ddadd102 add '-5E-4' 0 -> '-0.0005' +ddadd103 add '-5E-1' 0 -> '-0.5' +ddadd104 add '-5E0' 0 -> '-5' +ddadd105 add '-5E1' 0 -> '-50' +ddadd106 add '-5E5' 0 -> '-500000' +ddadd107 add '-5E15' 0 -> '-5000000000000000' +ddadd108 add '-5E16' 0 -> '-5.000000000000000E+16' Rounded +ddadd109 add '-5E17' 0 -> '-5.000000000000000E+17' Rounded +ddadd110 add '-5E18' 0 -> '-5.000000000000000E+18' Rounded +ddadd111 add '-5E100' 0 -> '-5.000000000000000E+100' Rounded + +-- more RHS swaps +ddadd113 add 0 '-56267E-10' -> '-0.0000056267' +ddadd114 add 0 '-56267E-6' -> '-0.056267' +ddadd116 add 0 '-56267E-5' -> '-0.56267' +ddadd117 add 0 '-56267E-4' -> '-5.6267' +ddadd119 add 0 '-56267E-3' -> '-56.267' +ddadd120 add 0 '-56267E-2' -> '-562.67' +ddadd121 add 0 '-56267E-1' -> '-5626.7' +ddadd122 add 0 '-56267E-0' -> '-56267' +ddadd123 add 0 '-5E-10' -> '-5E-10' +ddadd124 add 0 '-5E-7' -> '-5E-7' +ddadd125 add 0 '-5E-6' -> '-0.000005' +ddadd126 add 0 '-5E-5' -> '-0.00005' +ddadd127 add 0 '-5E-4' -> '-0.0005' +ddadd128 add 0 '-5E-1' -> '-0.5' +ddadd129 add 0 '-5E0' -> '-5' +ddadd130 add 0 '-5E1' -> '-50' +ddadd131 add 0 '-5E5' -> '-500000' +ddadd132 add 0 '-5E15' -> '-5000000000000000' +ddadd133 add 0 '-5E16' -> '-5.000000000000000E+16' Rounded +ddadd134 add 0 '-5E17' -> '-5.000000000000000E+17' Rounded +ddadd135 add 0 '-5E18' -> '-5.000000000000000E+18' Rounded +ddadd136 add 0 '-5E100' -> '-5.000000000000000E+100' Rounded + +-- related +ddadd137 add 1 '0E-19' -> '1.000000000000000' Rounded +ddadd138 add -1 '0E-19' -> '-1.000000000000000' Rounded +ddadd139 add '0E-19' 1 -> '1.000000000000000' Rounded +ddadd140 add '0E-19' -1 -> '-1.000000000000000' Rounded +ddadd141 add 1E+11 0.0000 -> '100000000000.0000' +ddadd142 add 1E+11 0.00000 -> '100000000000.0000' Rounded +ddadd143 add 0.000 1E+12 -> '1000000000000.000' +ddadd144 add 0.0000 1E+12 -> '1000000000000.000' Rounded + +-- [some of the next group are really constructor tests] +ddadd146 add '00.0' 0 -> '0.0' +ddadd147 add '0.00' 0 -> '0.00' +ddadd148 add 0 '0.00' -> '0.00' +ddadd149 add 0 '00.0' -> '0.0' +ddadd150 add '00.0' '0.00' -> '0.00' +ddadd151 add '0.00' '00.0' -> '0.00' +ddadd152 add '3' '.3' -> '3.3' +ddadd153 add '3.' '.3' -> '3.3' +ddadd154 add '3.0' '.3' -> '3.3' +ddadd155 add '3.00' '.3' -> '3.30' +ddadd156 add '3' '3' -> '6' +ddadd157 add '3' '+3' -> '6' +ddadd158 add '3' '-3' -> '0' +ddadd159 add '0.3' '-0.3' -> '0.0' +ddadd160 add '0.03' '-0.03' -> '0.00' + +-- try borderline precision, with carries, etc. +ddadd161 add '1E+12' '-1' -> '999999999999' +ddadd162 add '1E+12' '1.11' -> '1000000000001.11' +ddadd163 add '1.11' '1E+12' -> '1000000000001.11' +ddadd164 add '-1' '1E+12' -> '999999999999' +ddadd165 add '7E+12' '-1' -> '6999999999999' +ddadd166 add '7E+12' '1.11' -> '7000000000001.11' +ddadd167 add '1.11' '7E+12' -> '7000000000001.11' +ddadd168 add '-1' '7E+12' -> '6999999999999' + +rounding: half_up +-- 1.234567890123456 1234567890123456 1 234567890123456 +ddadd170 add '4.444444444444444' '0.5555555555555567' -> '5.000000000000001' Inexact Rounded +ddadd171 add '4.444444444444444' '0.5555555555555566' -> '5.000000000000001' Inexact Rounded +ddadd172 add '4.444444444444444' '0.5555555555555565' -> '5.000000000000001' Inexact Rounded +ddadd173 add '4.444444444444444' '0.5555555555555564' -> '5.000000000000000' Inexact Rounded +ddadd174 add '4.444444444444444' '0.5555555555555553' -> '4.999999999999999' Inexact Rounded +ddadd175 add '4.444444444444444' '0.5555555555555552' -> '4.999999999999999' Inexact Rounded +ddadd176 add '4.444444444444444' '0.5555555555555551' -> '4.999999999999999' Inexact Rounded +ddadd177 add '4.444444444444444' '0.5555555555555550' -> '4.999999999999999' Rounded +ddadd178 add '4.444444444444444' '0.5555555555555545' -> '4.999999999999999' Inexact Rounded +ddadd179 add '4.444444444444444' '0.5555555555555544' -> '4.999999999999998' Inexact Rounded +ddadd180 add '4.444444444444444' '0.5555555555555543' -> '4.999999999999998' Inexact Rounded +ddadd181 add '4.444444444444444' '0.5555555555555542' -> '4.999999999999998' Inexact Rounded +ddadd182 add '4.444444444444444' '0.5555555555555541' -> '4.999999999999998' Inexact Rounded +ddadd183 add '4.444444444444444' '0.5555555555555540' -> '4.999999999999998' Rounded + +-- and some more, including residue effects and different roundings +rounding: half_up +ddadd200 add '1234560123456789' 0 -> '1234560123456789' +ddadd201 add '1234560123456789' 0.000000001 -> '1234560123456789' Inexact Rounded +ddadd202 add '1234560123456789' 0.000001 -> '1234560123456789' Inexact Rounded +ddadd203 add '1234560123456789' 0.1 -> '1234560123456789' Inexact Rounded +ddadd204 add '1234560123456789' 0.4 -> '1234560123456789' Inexact Rounded +ddadd205 add '1234560123456789' 0.49 -> '1234560123456789' Inexact Rounded +ddadd206 add '1234560123456789' 0.499999 -> '1234560123456789' Inexact Rounded +ddadd207 add '1234560123456789' 0.499999999 -> '1234560123456789' Inexact Rounded +ddadd208 add '1234560123456789' 0.5 -> '1234560123456790' Inexact Rounded +ddadd209 add '1234560123456789' 0.500000001 -> '1234560123456790' Inexact Rounded +ddadd210 add '1234560123456789' 0.500001 -> '1234560123456790' Inexact Rounded +ddadd211 add '1234560123456789' 0.51 -> '1234560123456790' Inexact Rounded +ddadd212 add '1234560123456789' 0.6 -> '1234560123456790' Inexact Rounded +ddadd213 add '1234560123456789' 0.9 -> '1234560123456790' Inexact Rounded +ddadd214 add '1234560123456789' 0.99999 -> '1234560123456790' Inexact Rounded +ddadd215 add '1234560123456789' 0.999999999 -> '1234560123456790' Inexact Rounded +ddadd216 add '1234560123456789' 1 -> '1234560123456790' +ddadd217 add '1234560123456789' 1.000000001 -> '1234560123456790' Inexact Rounded +ddadd218 add '1234560123456789' 1.00001 -> '1234560123456790' Inexact Rounded +ddadd219 add '1234560123456789' 1.1 -> '1234560123456790' Inexact Rounded + +rounding: half_even +ddadd220 add '1234560123456789' 0 -> '1234560123456789' +ddadd221 add '1234560123456789' 0.000000001 -> '1234560123456789' Inexact Rounded +ddadd222 add '1234560123456789' 0.000001 -> '1234560123456789' Inexact Rounded +ddadd223 add '1234560123456789' 0.1 -> '1234560123456789' Inexact Rounded +ddadd224 add '1234560123456789' 0.4 -> '1234560123456789' Inexact Rounded +ddadd225 add '1234560123456789' 0.49 -> '1234560123456789' Inexact Rounded +ddadd226 add '1234560123456789' 0.499999 -> '1234560123456789' Inexact Rounded +ddadd227 add '1234560123456789' 0.499999999 -> '1234560123456789' Inexact Rounded +ddadd228 add '1234560123456789' 0.5 -> '1234560123456790' Inexact Rounded +ddadd229 add '1234560123456789' 0.500000001 -> '1234560123456790' Inexact Rounded +ddadd230 add '1234560123456789' 0.500001 -> '1234560123456790' Inexact Rounded +ddadd231 add '1234560123456789' 0.51 -> '1234560123456790' Inexact Rounded +ddadd232 add '1234560123456789' 0.6 -> '1234560123456790' Inexact Rounded +ddadd233 add '1234560123456789' 0.9 -> '1234560123456790' Inexact Rounded +ddadd234 add '1234560123456789' 0.99999 -> '1234560123456790' Inexact Rounded +ddadd235 add '1234560123456789' 0.999999999 -> '1234560123456790' Inexact Rounded +ddadd236 add '1234560123456789' 1 -> '1234560123456790' +ddadd237 add '1234560123456789' 1.00000001 -> '1234560123456790' Inexact Rounded +ddadd238 add '1234560123456789' 1.00001 -> '1234560123456790' Inexact Rounded +ddadd239 add '1234560123456789' 1.1 -> '1234560123456790' Inexact Rounded +-- critical few with even bottom digit... +ddadd240 add '1234560123456788' 0.499999999 -> '1234560123456788' Inexact Rounded +ddadd241 add '1234560123456788' 0.5 -> '1234560123456788' Inexact Rounded +ddadd242 add '1234560123456788' 0.500000001 -> '1234560123456789' Inexact Rounded + +rounding: down +ddadd250 add '1234560123456789' 0 -> '1234560123456789' +ddadd251 add '1234560123456789' 0.000000001 -> '1234560123456789' Inexact Rounded +ddadd252 add '1234560123456789' 0.000001 -> '1234560123456789' Inexact Rounded +ddadd253 add '1234560123456789' 0.1 -> '1234560123456789' Inexact Rounded +ddadd254 add '1234560123456789' 0.4 -> '1234560123456789' Inexact Rounded +ddadd255 add '1234560123456789' 0.49 -> '1234560123456789' Inexact Rounded +ddadd256 add '1234560123456789' 0.499999 -> '1234560123456789' Inexact Rounded +ddadd257 add '1234560123456789' 0.499999999 -> '1234560123456789' Inexact Rounded +ddadd258 add '1234560123456789' 0.5 -> '1234560123456789' Inexact Rounded +ddadd259 add '1234560123456789' 0.500000001 -> '1234560123456789' Inexact Rounded +ddadd260 add '1234560123456789' 0.500001 -> '1234560123456789' Inexact Rounded +ddadd261 add '1234560123456789' 0.51 -> '1234560123456789' Inexact Rounded +ddadd262 add '1234560123456789' 0.6 -> '1234560123456789' Inexact Rounded +ddadd263 add '1234560123456789' 0.9 -> '1234560123456789' Inexact Rounded +ddadd264 add '1234560123456789' 0.99999 -> '1234560123456789' Inexact Rounded +ddadd265 add '1234560123456789' 0.999999999 -> '1234560123456789' Inexact Rounded +ddadd266 add '1234560123456789' 1 -> '1234560123456790' +ddadd267 add '1234560123456789' 1.00000001 -> '1234560123456790' Inexact Rounded +ddadd268 add '1234560123456789' 1.00001 -> '1234560123456790' Inexact Rounded +ddadd269 add '1234560123456789' 1.1 -> '1234560123456790' Inexact Rounded + +-- 1 in last place tests +rounding: half_up +ddadd301 add -1 1 -> 0 +ddadd302 add 0 1 -> 1 +ddadd303 add 1 1 -> 2 +ddadd304 add 12 1 -> 13 +ddadd305 add 98 1 -> 99 +ddadd306 add 99 1 -> 100 +ddadd307 add 100 1 -> 101 +ddadd308 add 101 1 -> 102 +ddadd309 add -1 -1 -> -2 +ddadd310 add 0 -1 -> -1 +ddadd311 add 1 -1 -> 0 +ddadd312 add 12 -1 -> 11 +ddadd313 add 98 -1 -> 97 +ddadd314 add 99 -1 -> 98 +ddadd315 add 100 -1 -> 99 +ddadd316 add 101 -1 -> 100 + +ddadd321 add -0.01 0.01 -> 0.00 +ddadd322 add 0.00 0.01 -> 0.01 +ddadd323 add 0.01 0.01 -> 0.02 +ddadd324 add 0.12 0.01 -> 0.13 +ddadd325 add 0.98 0.01 -> 0.99 +ddadd326 add 0.99 0.01 -> 1.00 +ddadd327 add 1.00 0.01 -> 1.01 +ddadd328 add 1.01 0.01 -> 1.02 +ddadd329 add -0.01 -0.01 -> -0.02 +ddadd330 add 0.00 -0.01 -> -0.01 +ddadd331 add 0.01 -0.01 -> 0.00 +ddadd332 add 0.12 -0.01 -> 0.11 +ddadd333 add 0.98 -0.01 -> 0.97 +ddadd334 add 0.99 -0.01 -> 0.98 +ddadd335 add 1.00 -0.01 -> 0.99 +ddadd336 add 1.01 -0.01 -> 1.00 + +-- some more cases where adding 0 affects the coefficient +ddadd340 add 1E+3 0 -> 1000 +ddadd341 add 1E+15 0 -> 1000000000000000 +ddadd342 add 1E+16 0 -> 1.000000000000000E+16 Rounded +ddadd343 add 1E+20 0 -> 1.000000000000000E+20 Rounded +-- which simply follow from these cases ... +ddadd344 add 1E+3 1 -> 1001 +ddadd345 add 1E+15 1 -> 1000000000000001 +ddadd346 add 1E+16 1 -> 1.000000000000000E+16 Inexact Rounded +ddadd347 add 1E+20 1 -> 1.000000000000000E+20 Inexact Rounded +ddadd348 add 1E+3 7 -> 1007 +ddadd349 add 1E+15 7 -> 1000000000000007 +ddadd350 add 1E+16 7 -> 1.000000000000001E+16 Inexact Rounded +ddadd351 add 1E+20 7 -> 1.000000000000000E+20 Inexact Rounded + +-- tryzeros cases +rounding: half_up +ddadd360 add 0E+50 10000E+1 -> 1.0000E+5 +ddadd361 add 0E-50 10000E+1 -> 100000.0000000000 Rounded +ddadd362 add 10000E+1 0E-50 -> 100000.0000000000 Rounded +ddadd363 add 10000E+1 10000E-50 -> 100000.0000000000 Rounded Inexact +ddadd364 add 9.999999999999999E+384 -9.999999999999999E+384 -> 0E+369 + +-- a curiosity from JSR 13 testing +rounding: half_down +ddadd370 add 999999999999999 815 -> 1000000000000814 +ddadd371 add 9999999999999999 815 -> 1.000000000000081E+16 Rounded Inexact +rounding: half_up +ddadd372 add 999999999999999 815 -> 1000000000000814 +ddadd373 add 9999999999999999 815 -> 1.000000000000081E+16 Rounded Inexact +rounding: half_even +ddadd374 add 999999999999999 815 -> 1000000000000814 +ddadd375 add 9999999999999999 815 -> 1.000000000000081E+16 Rounded Inexact + +-- operands folded +ddadd380 add 1E+384 1E+384 -> 2.000000000000000E+384 Clamped +ddadd381 add 1E+380 1E+380 -> 2.00000000000E+380 Clamped +ddadd382 add 1E+376 1E+376 -> 2.0000000E+376 Clamped +ddadd383 add 1E+372 1E+372 -> 2.000E+372 Clamped +ddadd384 add 1E+370 1E+370 -> 2.0E+370 Clamped +ddadd385 add 1E+369 1E+369 -> 2E+369 +ddadd386 add 1E+368 1E+368 -> 2E+368 + +-- ulp replacement tests +ddadd400 add 1 77e-14 -> 1.00000000000077 +ddadd401 add 1 77e-15 -> 1.000000000000077 +ddadd402 add 1 77e-16 -> 1.000000000000008 Inexact Rounded +ddadd403 add 1 77e-17 -> 1.000000000000001 Inexact Rounded +ddadd404 add 1 77e-18 -> 1.000000000000000 Inexact Rounded +ddadd405 add 1 77e-19 -> 1.000000000000000 Inexact Rounded +ddadd406 add 1 77e-299 -> 1.000000000000000 Inexact Rounded + +ddadd410 add 10 77e-14 -> 10.00000000000077 +ddadd411 add 10 77e-15 -> 10.00000000000008 Inexact Rounded +ddadd412 add 10 77e-16 -> 10.00000000000001 Inexact Rounded +ddadd413 add 10 77e-17 -> 10.00000000000000 Inexact Rounded +ddadd414 add 10 77e-18 -> 10.00000000000000 Inexact Rounded +ddadd415 add 10 77e-19 -> 10.00000000000000 Inexact Rounded +ddadd416 add 10 77e-299 -> 10.00000000000000 Inexact Rounded + +ddadd420 add 77e-14 1 -> 1.00000000000077 +ddadd421 add 77e-15 1 -> 1.000000000000077 +ddadd422 add 77e-16 1 -> 1.000000000000008 Inexact Rounded +ddadd423 add 77e-17 1 -> 1.000000000000001 Inexact Rounded +ddadd424 add 77e-18 1 -> 1.000000000000000 Inexact Rounded +ddadd425 add 77e-19 1 -> 1.000000000000000 Inexact Rounded +ddadd426 add 77e-299 1 -> 1.000000000000000 Inexact Rounded + +ddadd430 add 77e-14 10 -> 10.00000000000077 +ddadd431 add 77e-15 10 -> 10.00000000000008 Inexact Rounded +ddadd432 add 77e-16 10 -> 10.00000000000001 Inexact Rounded +ddadd433 add 77e-17 10 -> 10.00000000000000 Inexact Rounded +ddadd434 add 77e-18 10 -> 10.00000000000000 Inexact Rounded +ddadd435 add 77e-19 10 -> 10.00000000000000 Inexact Rounded +ddadd436 add 77e-299 10 -> 10.00000000000000 Inexact Rounded + +-- negative ulps +ddadd6440 add 1 -77e-14 -> 0.99999999999923 +ddadd6441 add 1 -77e-15 -> 0.999999999999923 +ddadd6442 add 1 -77e-16 -> 0.9999999999999923 +ddadd6443 add 1 -77e-17 -> 0.9999999999999992 Inexact Rounded +ddadd6444 add 1 -77e-18 -> 0.9999999999999999 Inexact Rounded +ddadd6445 add 1 -77e-19 -> 1.000000000000000 Inexact Rounded +ddadd6446 add 1 -77e-99 -> 1.000000000000000 Inexact Rounded + +ddadd6450 add 10 -77e-14 -> 9.99999999999923 +ddadd6451 add 10 -77e-15 -> 9.999999999999923 +ddadd6452 add 10 -77e-16 -> 9.999999999999992 Inexact Rounded +ddadd6453 add 10 -77e-17 -> 9.999999999999999 Inexact Rounded +ddadd6454 add 10 -77e-18 -> 10.00000000000000 Inexact Rounded +ddadd6455 add 10 -77e-19 -> 10.00000000000000 Inexact Rounded +ddadd6456 add 10 -77e-99 -> 10.00000000000000 Inexact Rounded + +ddadd6460 add -77e-14 1 -> 0.99999999999923 +ddadd6461 add -77e-15 1 -> 0.999999999999923 +ddadd6462 add -77e-16 1 -> 0.9999999999999923 +ddadd6463 add -77e-17 1 -> 0.9999999999999992 Inexact Rounded +ddadd6464 add -77e-18 1 -> 0.9999999999999999 Inexact Rounded +ddadd6465 add -77e-19 1 -> 1.000000000000000 Inexact Rounded +ddadd6466 add -77e-99 1 -> 1.000000000000000 Inexact Rounded + +ddadd6470 add -77e-14 10 -> 9.99999999999923 +ddadd6471 add -77e-15 10 -> 9.999999999999923 +ddadd6472 add -77e-16 10 -> 9.999999999999992 Inexact Rounded +ddadd6473 add -77e-17 10 -> 9.999999999999999 Inexact Rounded +ddadd6474 add -77e-18 10 -> 10.00000000000000 Inexact Rounded +ddadd6475 add -77e-19 10 -> 10.00000000000000 Inexact Rounded +ddadd6476 add -77e-99 10 -> 10.00000000000000 Inexact Rounded + +-- negative ulps +ddadd6480 add -1 77e-14 -> -0.99999999999923 +ddadd6481 add -1 77e-15 -> -0.999999999999923 +ddadd6482 add -1 77e-16 -> -0.9999999999999923 +ddadd6483 add -1 77e-17 -> -0.9999999999999992 Inexact Rounded +ddadd6484 add -1 77e-18 -> -0.9999999999999999 Inexact Rounded +ddadd6485 add -1 77e-19 -> -1.000000000000000 Inexact Rounded +ddadd6486 add -1 77e-99 -> -1.000000000000000 Inexact Rounded + +ddadd6490 add -10 77e-14 -> -9.99999999999923 +ddadd6491 add -10 77e-15 -> -9.999999999999923 +ddadd6492 add -10 77e-16 -> -9.999999999999992 Inexact Rounded +ddadd6493 add -10 77e-17 -> -9.999999999999999 Inexact Rounded +ddadd6494 add -10 77e-18 -> -10.00000000000000 Inexact Rounded +ddadd6495 add -10 77e-19 -> -10.00000000000000 Inexact Rounded +ddadd6496 add -10 77e-99 -> -10.00000000000000 Inexact Rounded + +ddadd6500 add 77e-14 -1 -> -0.99999999999923 +ddadd6501 add 77e-15 -1 -> -0.999999999999923 +ddadd6502 add 77e-16 -1 -> -0.9999999999999923 +ddadd6503 add 77e-17 -1 -> -0.9999999999999992 Inexact Rounded +ddadd6504 add 77e-18 -1 -> -0.9999999999999999 Inexact Rounded +ddadd6505 add 77e-19 -1 -> -1.000000000000000 Inexact Rounded +ddadd6506 add 77e-99 -1 -> -1.000000000000000 Inexact Rounded + +ddadd6510 add 77e-14 -10 -> -9.99999999999923 +ddadd6511 add 77e-15 -10 -> -9.999999999999923 +ddadd6512 add 77e-16 -10 -> -9.999999999999992 Inexact Rounded +ddadd6513 add 77e-17 -10 -> -9.999999999999999 Inexact Rounded +ddadd6514 add 77e-18 -10 -> -10.00000000000000 Inexact Rounded +ddadd6515 add 77e-19 -10 -> -10.00000000000000 Inexact Rounded +ddadd6516 add 77e-99 -10 -> -10.00000000000000 Inexact Rounded + +-- and some more residue effects and different roundings +rounding: half_up +ddadd6540 add '6543210123456789' 0 -> '6543210123456789' +ddadd6541 add '6543210123456789' 0.000000001 -> '6543210123456789' Inexact Rounded +ddadd6542 add '6543210123456789' 0.000001 -> '6543210123456789' Inexact Rounded +ddadd6543 add '6543210123456789' 0.1 -> '6543210123456789' Inexact Rounded +ddadd6544 add '6543210123456789' 0.4 -> '6543210123456789' Inexact Rounded +ddadd6545 add '6543210123456789' 0.49 -> '6543210123456789' Inexact Rounded +ddadd6546 add '6543210123456789' 0.499999 -> '6543210123456789' Inexact Rounded +ddadd6547 add '6543210123456789' 0.499999999 -> '6543210123456789' Inexact Rounded +ddadd6548 add '6543210123456789' 0.5 -> '6543210123456790' Inexact Rounded +ddadd6549 add '6543210123456789' 0.500000001 -> '6543210123456790' Inexact Rounded +ddadd6550 add '6543210123456789' 0.500001 -> '6543210123456790' Inexact Rounded +ddadd6551 add '6543210123456789' 0.51 -> '6543210123456790' Inexact Rounded +ddadd6552 add '6543210123456789' 0.6 -> '6543210123456790' Inexact Rounded +ddadd6553 add '6543210123456789' 0.9 -> '6543210123456790' Inexact Rounded +ddadd6554 add '6543210123456789' 0.99999 -> '6543210123456790' Inexact Rounded +ddadd6555 add '6543210123456789' 0.999999999 -> '6543210123456790' Inexact Rounded +ddadd6556 add '6543210123456789' 1 -> '6543210123456790' +ddadd6557 add '6543210123456789' 1.000000001 -> '6543210123456790' Inexact Rounded +ddadd6558 add '6543210123456789' 1.00001 -> '6543210123456790' Inexact Rounded +ddadd6559 add '6543210123456789' 1.1 -> '6543210123456790' Inexact Rounded + +rounding: half_even +ddadd6560 add '6543210123456789' 0 -> '6543210123456789' +ddadd6561 add '6543210123456789' 0.000000001 -> '6543210123456789' Inexact Rounded +ddadd6562 add '6543210123456789' 0.000001 -> '6543210123456789' Inexact Rounded +ddadd6563 add '6543210123456789' 0.1 -> '6543210123456789' Inexact Rounded +ddadd6564 add '6543210123456789' 0.4 -> '6543210123456789' Inexact Rounded +ddadd6565 add '6543210123456789' 0.49 -> '6543210123456789' Inexact Rounded +ddadd6566 add '6543210123456789' 0.499999 -> '6543210123456789' Inexact Rounded +ddadd6567 add '6543210123456789' 0.499999999 -> '6543210123456789' Inexact Rounded +ddadd6568 add '6543210123456789' 0.5 -> '6543210123456790' Inexact Rounded +ddadd6569 add '6543210123456789' 0.500000001 -> '6543210123456790' Inexact Rounded +ddadd6570 add '6543210123456789' 0.500001 -> '6543210123456790' Inexact Rounded +ddadd6571 add '6543210123456789' 0.51 -> '6543210123456790' Inexact Rounded +ddadd6572 add '6543210123456789' 0.6 -> '6543210123456790' Inexact Rounded +ddadd6573 add '6543210123456789' 0.9 -> '6543210123456790' Inexact Rounded +ddadd6574 add '6543210123456789' 0.99999 -> '6543210123456790' Inexact Rounded +ddadd6575 add '6543210123456789' 0.999999999 -> '6543210123456790' Inexact Rounded +ddadd6576 add '6543210123456789' 1 -> '6543210123456790' +ddadd6577 add '6543210123456789' 1.00000001 -> '6543210123456790' Inexact Rounded +ddadd6578 add '6543210123456789' 1.00001 -> '6543210123456790' Inexact Rounded +ddadd6579 add '6543210123456789' 1.1 -> '6543210123456790' Inexact Rounded + +-- critical few with even bottom digit... +ddadd7540 add '6543210123456788' 0.499999999 -> '6543210123456788' Inexact Rounded +ddadd7541 add '6543210123456788' 0.5 -> '6543210123456788' Inexact Rounded +ddadd7542 add '6543210123456788' 0.500000001 -> '6543210123456789' Inexact Rounded + +rounding: down +ddadd7550 add '6543210123456789' 0 -> '6543210123456789' +ddadd7551 add '6543210123456789' 0.000000001 -> '6543210123456789' Inexact Rounded +ddadd7552 add '6543210123456789' 0.000001 -> '6543210123456789' Inexact Rounded +ddadd7553 add '6543210123456789' 0.1 -> '6543210123456789' Inexact Rounded +ddadd7554 add '6543210123456789' 0.4 -> '6543210123456789' Inexact Rounded +ddadd7555 add '6543210123456789' 0.49 -> '6543210123456789' Inexact Rounded +ddadd7556 add '6543210123456789' 0.499999 -> '6543210123456789' Inexact Rounded +ddadd7557 add '6543210123456789' 0.499999999 -> '6543210123456789' Inexact Rounded +ddadd7558 add '6543210123456789' 0.5 -> '6543210123456789' Inexact Rounded +ddadd7559 add '6543210123456789' 0.500000001 -> '6543210123456789' Inexact Rounded +ddadd7560 add '6543210123456789' 0.500001 -> '6543210123456789' Inexact Rounded +ddadd7561 add '6543210123456789' 0.51 -> '6543210123456789' Inexact Rounded +ddadd7562 add '6543210123456789' 0.6 -> '6543210123456789' Inexact Rounded +ddadd7563 add '6543210123456789' 0.9 -> '6543210123456789' Inexact Rounded +ddadd7564 add '6543210123456789' 0.99999 -> '6543210123456789' Inexact Rounded +ddadd7565 add '6543210123456789' 0.999999999 -> '6543210123456789' Inexact Rounded +ddadd7566 add '6543210123456789' 1 -> '6543210123456790' +ddadd7567 add '6543210123456789' 1.00000001 -> '6543210123456790' Inexact Rounded +ddadd7568 add '6543210123456789' 1.00001 -> '6543210123456790' Inexact Rounded +ddadd7569 add '6543210123456789' 1.1 -> '6543210123456790' Inexact Rounded + +-- verify a query +rounding: down +ddadd7661 add 1e-398 9.000000000000000E+384 -> 9.000000000000000E+384 Inexact Rounded +ddadd7662 add 0 9.000000000000000E+384 -> 9.000000000000000E+384 Rounded +ddadd7663 add 1e-388 9.000000000000000E+374 -> 9.000000000000000E+374 Inexact Rounded +ddadd7664 add 0 9.000000000000000E+374 -> 9.000000000000000E+374 Rounded + +-- more zeros, etc. +rounding: half_even + +ddadd7701 add 5.00 1.00E-3 -> 5.00100 +ddadd7702 add 00.00 0.000 -> 0.000 +ddadd7703 add 00.00 0E-3 -> 0.000 +ddadd7704 add 0E-3 00.00 -> 0.000 + +ddadd7710 add 0E+3 00.00 -> 0.00 +ddadd7711 add 0E+3 00.0 -> 0.0 +ddadd7712 add 0E+3 00. -> 0 +ddadd7713 add 0E+3 00.E+1 -> 0E+1 +ddadd7714 add 0E+3 00.E+2 -> 0E+2 +ddadd7715 add 0E+3 00.E+3 -> 0E+3 +ddadd7716 add 0E+3 00.E+4 -> 0E+3 +ddadd7717 add 0E+3 00.E+5 -> 0E+3 +ddadd7718 add 0E+3 -00.0 -> 0.0 +ddadd7719 add 0E+3 -00. -> 0 +ddadd7731 add 0E+3 -00.E+1 -> 0E+1 + +ddadd7720 add 00.00 0E+3 -> 0.00 +ddadd7721 add 00.0 0E+3 -> 0.0 +ddadd7722 add 00. 0E+3 -> 0 +ddadd7723 add 00.E+1 0E+3 -> 0E+1 +ddadd7724 add 00.E+2 0E+3 -> 0E+2 +ddadd7725 add 00.E+3 0E+3 -> 0E+3 +ddadd7726 add 00.E+4 0E+3 -> 0E+3 +ddadd7727 add 00.E+5 0E+3 -> 0E+3 +ddadd7728 add -00.00 0E+3 -> 0.00 +ddadd7729 add -00.0 0E+3 -> 0.0 +ddadd7730 add -00. 0E+3 -> 0 + +ddadd7732 add 0 0 -> 0 +ddadd7733 add 0 -0 -> 0 +ddadd7734 add -0 0 -> 0 +ddadd7735 add -0 -0 -> -0 -- IEEE 854 special case + +ddadd7736 add 1 -1 -> 0 +ddadd7737 add -1 -1 -> -2 +ddadd7738 add 1 1 -> 2 +ddadd7739 add -1 1 -> 0 + +ddadd7741 add 0 -1 -> -1 +ddadd7742 add -0 -1 -> -1 +ddadd7743 add 0 1 -> 1 +ddadd7744 add -0 1 -> 1 +ddadd7745 add -1 0 -> -1 +ddadd7746 add -1 -0 -> -1 +ddadd7747 add 1 0 -> 1 +ddadd7748 add 1 -0 -> 1 + +ddadd7751 add 0.0 -1 -> -1.0 +ddadd7752 add -0.0 -1 -> -1.0 +ddadd7753 add 0.0 1 -> 1.0 +ddadd7754 add -0.0 1 -> 1.0 +ddadd7755 add -1.0 0 -> -1.0 +ddadd7756 add -1.0 -0 -> -1.0 +ddadd7757 add 1.0 0 -> 1.0 +ddadd7758 add 1.0 -0 -> 1.0 + +ddadd7761 add 0 -1.0 -> -1.0 +ddadd7762 add -0 -1.0 -> -1.0 +ddadd7763 add 0 1.0 -> 1.0 +ddadd7764 add -0 1.0 -> 1.0 +ddadd7765 add -1 0.0 -> -1.0 +ddadd7766 add -1 -0.0 -> -1.0 +ddadd7767 add 1 0.0 -> 1.0 +ddadd7768 add 1 -0.0 -> 1.0 + +ddadd7771 add 0.0 -1.0 -> -1.0 +ddadd7772 add -0.0 -1.0 -> -1.0 +ddadd7773 add 0.0 1.0 -> 1.0 +ddadd7774 add -0.0 1.0 -> 1.0 +ddadd7775 add -1.0 0.0 -> -1.0 +ddadd7776 add -1.0 -0.0 -> -1.0 +ddadd7777 add 1.0 0.0 -> 1.0 +ddadd7778 add 1.0 -0.0 -> 1.0 + +-- Specials +ddadd7780 add -Inf -Inf -> -Infinity +ddadd7781 add -Inf -1000 -> -Infinity +ddadd7782 add -Inf -1 -> -Infinity +ddadd7783 add -Inf -0 -> -Infinity +ddadd7784 add -Inf 0 -> -Infinity +ddadd7785 add -Inf 1 -> -Infinity +ddadd7786 add -Inf 1000 -> -Infinity +ddadd7787 add -1000 -Inf -> -Infinity +ddadd7788 add -Inf -Inf -> -Infinity +ddadd7789 add -1 -Inf -> -Infinity +ddadd7790 add -0 -Inf -> -Infinity +ddadd7791 add 0 -Inf -> -Infinity +ddadd7792 add 1 -Inf -> -Infinity +ddadd7793 add 1000 -Inf -> -Infinity +ddadd7794 add Inf -Inf -> NaN Invalid_operation + +ddadd7800 add Inf -Inf -> NaN Invalid_operation +ddadd7801 add Inf -1000 -> Infinity +ddadd7802 add Inf -1 -> Infinity +ddadd7803 add Inf -0 -> Infinity +ddadd7804 add Inf 0 -> Infinity +ddadd7805 add Inf 1 -> Infinity +ddadd7806 add Inf 1000 -> Infinity +ddadd7807 add Inf Inf -> Infinity +ddadd7808 add -1000 Inf -> Infinity +ddadd7809 add -Inf Inf -> NaN Invalid_operation +ddadd7810 add -1 Inf -> Infinity +ddadd7811 add -0 Inf -> Infinity +ddadd7812 add 0 Inf -> Infinity +ddadd7813 add 1 Inf -> Infinity +ddadd7814 add 1000 Inf -> Infinity +ddadd7815 add Inf Inf -> Infinity + +ddadd7821 add NaN -Inf -> NaN +ddadd7822 add NaN -1000 -> NaN +ddadd7823 add NaN -1 -> NaN +ddadd7824 add NaN -0 -> NaN +ddadd7825 add NaN 0 -> NaN +ddadd7826 add NaN 1 -> NaN +ddadd7827 add NaN 1000 -> NaN +ddadd7828 add NaN Inf -> NaN +ddadd7829 add NaN NaN -> NaN +ddadd7830 add -Inf NaN -> NaN +ddadd7831 add -1000 NaN -> NaN +ddadd7832 add -1 NaN -> NaN +ddadd7833 add -0 NaN -> NaN +ddadd7834 add 0 NaN -> NaN +ddadd7835 add 1 NaN -> NaN +ddadd7836 add 1000 NaN -> NaN +ddadd7837 add Inf NaN -> NaN + +ddadd7841 add sNaN -Inf -> NaN Invalid_operation +ddadd7842 add sNaN -1000 -> NaN Invalid_operation +ddadd7843 add sNaN -1 -> NaN Invalid_operation +ddadd7844 add sNaN -0 -> NaN Invalid_operation +ddadd7845 add sNaN 0 -> NaN Invalid_operation +ddadd7846 add sNaN 1 -> NaN Invalid_operation +ddadd7847 add sNaN 1000 -> NaN Invalid_operation +ddadd7848 add sNaN NaN -> NaN Invalid_operation +ddadd7849 add sNaN sNaN -> NaN Invalid_operation +ddadd7850 add NaN sNaN -> NaN Invalid_operation +ddadd7851 add -Inf sNaN -> NaN Invalid_operation +ddadd7852 add -1000 sNaN -> NaN Invalid_operation +ddadd7853 add -1 sNaN -> NaN Invalid_operation +ddadd7854 add -0 sNaN -> NaN Invalid_operation +ddadd7855 add 0 sNaN -> NaN Invalid_operation +ddadd7856 add 1 sNaN -> NaN Invalid_operation +ddadd7857 add 1000 sNaN -> NaN Invalid_operation +ddadd7858 add Inf sNaN -> NaN Invalid_operation +ddadd7859 add NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +ddadd7861 add NaN1 -Inf -> NaN1 +ddadd7862 add +NaN2 -1000 -> NaN2 +ddadd7863 add NaN3 1000 -> NaN3 +ddadd7864 add NaN4 Inf -> NaN4 +ddadd7865 add NaN5 +NaN6 -> NaN5 +ddadd7866 add -Inf NaN7 -> NaN7 +ddadd7867 add -1000 NaN8 -> NaN8 +ddadd7868 add 1000 NaN9 -> NaN9 +ddadd7869 add Inf +NaN10 -> NaN10 +ddadd7871 add sNaN11 -Inf -> NaN11 Invalid_operation +ddadd7872 add sNaN12 -1000 -> NaN12 Invalid_operation +ddadd7873 add sNaN13 1000 -> NaN13 Invalid_operation +ddadd7874 add sNaN14 NaN17 -> NaN14 Invalid_operation +ddadd7875 add sNaN15 sNaN18 -> NaN15 Invalid_operation +ddadd7876 add NaN16 sNaN19 -> NaN19 Invalid_operation +ddadd7877 add -Inf +sNaN20 -> NaN20 Invalid_operation +ddadd7878 add -1000 sNaN21 -> NaN21 Invalid_operation +ddadd7879 add 1000 sNaN22 -> NaN22 Invalid_operation +ddadd7880 add Inf sNaN23 -> NaN23 Invalid_operation +ddadd7881 add +NaN25 +sNaN24 -> NaN24 Invalid_operation +ddadd7882 add -NaN26 NaN28 -> -NaN26 +ddadd7883 add -sNaN27 sNaN29 -> -NaN27 Invalid_operation +ddadd7884 add 1000 -NaN30 -> -NaN30 +ddadd7885 add 1000 -sNaN31 -> -NaN31 Invalid_operation + +-- Here we explore near the boundary of rounding a subnormal to Nmin +ddadd7575 add 1E-383 -1E-398 -> 9.99999999999999E-384 Subnormal +ddadd7576 add -1E-383 +1E-398 -> -9.99999999999999E-384 Subnormal + +-- check overflow edge case +-- 1234567890123456 +ddadd7972 apply 9.999999999999999E+384 -> 9.999999999999999E+384 +ddadd7973 add 9.999999999999999E+384 1 -> 9.999999999999999E+384 Inexact Rounded +ddadd7974 add 9999999999999999E+369 1 -> 9.999999999999999E+384 Inexact Rounded +ddadd7975 add 9999999999999999E+369 1E+369 -> Infinity Overflow Inexact Rounded +ddadd7976 add 9999999999999999E+369 9E+368 -> Infinity Overflow Inexact Rounded +ddadd7977 add 9999999999999999E+369 8E+368 -> Infinity Overflow Inexact Rounded +ddadd7978 add 9999999999999999E+369 7E+368 -> Infinity Overflow Inexact Rounded +ddadd7979 add 9999999999999999E+369 6E+368 -> Infinity Overflow Inexact Rounded +ddadd7980 add 9999999999999999E+369 5E+368 -> Infinity Overflow Inexact Rounded +ddadd7981 add 9999999999999999E+369 4E+368 -> 9.999999999999999E+384 Inexact Rounded +ddadd7982 add 9999999999999999E+369 3E+368 -> 9.999999999999999E+384 Inexact Rounded +ddadd7983 add 9999999999999999E+369 2E+368 -> 9.999999999999999E+384 Inexact Rounded +ddadd7984 add 9999999999999999E+369 1E+368 -> 9.999999999999999E+384 Inexact Rounded + +ddadd7985 apply -9.999999999999999E+384 -> -9.999999999999999E+384 +ddadd7986 add -9.999999999999999E+384 -1 -> -9.999999999999999E+384 Inexact Rounded +ddadd7987 add -9999999999999999E+369 -1 -> -9.999999999999999E+384 Inexact Rounded +ddadd7988 add -9999999999999999E+369 -1E+369 -> -Infinity Overflow Inexact Rounded +ddadd7989 add -9999999999999999E+369 -9E+368 -> -Infinity Overflow Inexact Rounded +ddadd7990 add -9999999999999999E+369 -8E+368 -> -Infinity Overflow Inexact Rounded +ddadd7991 add -9999999999999999E+369 -7E+368 -> -Infinity Overflow Inexact Rounded +ddadd7992 add -9999999999999999E+369 -6E+368 -> -Infinity Overflow Inexact Rounded +ddadd7993 add -9999999999999999E+369 -5E+368 -> -Infinity Overflow Inexact Rounded +ddadd7994 add -9999999999999999E+369 -4E+368 -> -9.999999999999999E+384 Inexact Rounded +ddadd7995 add -9999999999999999E+369 -3E+368 -> -9.999999999999999E+384 Inexact Rounded +ddadd7996 add -9999999999999999E+369 -2E+368 -> -9.999999999999999E+384 Inexact Rounded +ddadd7997 add -9999999999999999E+369 -1E+368 -> -9.999999999999999E+384 Inexact Rounded + +-- And for round down full and subnormal results +rounding: down +ddadd71100 add 1e+2 -1e-383 -> 99.99999999999999 Rounded Inexact +ddadd71101 add 1e+1 -1e-383 -> 9.999999999999999 Rounded Inexact +ddadd71103 add +1 -1e-383 -> 0.9999999999999999 Rounded Inexact +ddadd71104 add 1e-1 -1e-383 -> 0.09999999999999999 Rounded Inexact +ddadd71105 add 1e-2 -1e-383 -> 0.009999999999999999 Rounded Inexact +ddadd71106 add 1e-3 -1e-383 -> 0.0009999999999999999 Rounded Inexact +ddadd71107 add 1e-4 -1e-383 -> 0.00009999999999999999 Rounded Inexact +ddadd71108 add 1e-5 -1e-383 -> 0.000009999999999999999 Rounded Inexact +ddadd71109 add 1e-6 -1e-383 -> 9.999999999999999E-7 Rounded Inexact + +rounding: ceiling +ddadd71110 add -1e+2 +1e-383 -> -99.99999999999999 Rounded Inexact +ddadd71111 add -1e+1 +1e-383 -> -9.999999999999999 Rounded Inexact +ddadd71113 add -1 +1e-383 -> -0.9999999999999999 Rounded Inexact +ddadd71114 add -1e-1 +1e-383 -> -0.09999999999999999 Rounded Inexact +ddadd71115 add -1e-2 +1e-383 -> -0.009999999999999999 Rounded Inexact +ddadd71116 add -1e-3 +1e-383 -> -0.0009999999999999999 Rounded Inexact +ddadd71117 add -1e-4 +1e-383 -> -0.00009999999999999999 Rounded Inexact +ddadd71118 add -1e-5 +1e-383 -> -0.000009999999999999999 Rounded Inexact +ddadd71119 add -1e-6 +1e-383 -> -9.999999999999999E-7 Rounded Inexact + +-- tests based on Gunnar Degnbol's edge case +rounding: half_even + +ddadd71300 add 1E16 -0.5 -> 1.000000000000000E+16 Inexact Rounded +ddadd71310 add 1E16 -0.51 -> 9999999999999999 Inexact Rounded +ddadd71311 add 1E16 -0.501 -> 9999999999999999 Inexact Rounded +ddadd71312 add 1E16 -0.5001 -> 9999999999999999 Inexact Rounded +ddadd71313 add 1E16 -0.50001 -> 9999999999999999 Inexact Rounded +ddadd71314 add 1E16 -0.500001 -> 9999999999999999 Inexact Rounded +ddadd71315 add 1E16 -0.5000001 -> 9999999999999999 Inexact Rounded +ddadd71316 add 1E16 -0.50000001 -> 9999999999999999 Inexact Rounded +ddadd71317 add 1E16 -0.500000001 -> 9999999999999999 Inexact Rounded +ddadd71318 add 1E16 -0.5000000001 -> 9999999999999999 Inexact Rounded +ddadd71319 add 1E16 -0.50000000001 -> 9999999999999999 Inexact Rounded +ddadd71320 add 1E16 -0.500000000001 -> 9999999999999999 Inexact Rounded +ddadd71321 add 1E16 -0.5000000000001 -> 9999999999999999 Inexact Rounded +ddadd71322 add 1E16 -0.50000000000001 -> 9999999999999999 Inexact Rounded +ddadd71323 add 1E16 -0.500000000000001 -> 9999999999999999 Inexact Rounded +ddadd71324 add 1E16 -0.5000000000000001 -> 9999999999999999 Inexact Rounded +ddadd71325 add 1E16 -0.5000000000000000 -> 1.000000000000000E+16 Inexact Rounded +ddadd71326 add 1E16 -0.500000000000000 -> 1.000000000000000E+16 Inexact Rounded +ddadd71327 add 1E16 -0.50000000000000 -> 1.000000000000000E+16 Inexact Rounded +ddadd71328 add 1E16 -0.5000000000000 -> 1.000000000000000E+16 Inexact Rounded +ddadd71329 add 1E16 -0.500000000000 -> 1.000000000000000E+16 Inexact Rounded +ddadd71330 add 1E16 -0.50000000000 -> 1.000000000000000E+16 Inexact Rounded +ddadd71331 add 1E16 -0.5000000000 -> 1.000000000000000E+16 Inexact Rounded +ddadd71332 add 1E16 -0.500000000 -> 1.000000000000000E+16 Inexact Rounded +ddadd71333 add 1E16 -0.50000000 -> 1.000000000000000E+16 Inexact Rounded +ddadd71334 add 1E16 -0.5000000 -> 1.000000000000000E+16 Inexact Rounded +ddadd71335 add 1E16 -0.500000 -> 1.000000000000000E+16 Inexact Rounded +ddadd71336 add 1E16 -0.50000 -> 1.000000000000000E+16 Inexact Rounded +ddadd71337 add 1E16 -0.5000 -> 1.000000000000000E+16 Inexact Rounded +ddadd71338 add 1E16 -0.500 -> 1.000000000000000E+16 Inexact Rounded +ddadd71339 add 1E16 -0.50 -> 1.000000000000000E+16 Inexact Rounded + +ddadd71340 add 1E16 -5000000.000010001 -> 9999999995000000 Inexact Rounded +ddadd71341 add 1E16 -5000000.000000001 -> 9999999995000000 Inexact Rounded + +ddadd71349 add 9999999999999999 0.4 -> 9999999999999999 Inexact Rounded +ddadd71350 add 9999999999999999 0.49 -> 9999999999999999 Inexact Rounded +ddadd71351 add 9999999999999999 0.499 -> 9999999999999999 Inexact Rounded +ddadd71352 add 9999999999999999 0.4999 -> 9999999999999999 Inexact Rounded +ddadd71353 add 9999999999999999 0.49999 -> 9999999999999999 Inexact Rounded +ddadd71354 add 9999999999999999 0.499999 -> 9999999999999999 Inexact Rounded +ddadd71355 add 9999999999999999 0.4999999 -> 9999999999999999 Inexact Rounded +ddadd71356 add 9999999999999999 0.49999999 -> 9999999999999999 Inexact Rounded +ddadd71357 add 9999999999999999 0.499999999 -> 9999999999999999 Inexact Rounded +ddadd71358 add 9999999999999999 0.4999999999 -> 9999999999999999 Inexact Rounded +ddadd71359 add 9999999999999999 0.49999999999 -> 9999999999999999 Inexact Rounded +ddadd71360 add 9999999999999999 0.499999999999 -> 9999999999999999 Inexact Rounded +ddadd71361 add 9999999999999999 0.4999999999999 -> 9999999999999999 Inexact Rounded +ddadd71362 add 9999999999999999 0.49999999999999 -> 9999999999999999 Inexact Rounded +ddadd71363 add 9999999999999999 0.499999999999999 -> 9999999999999999 Inexact Rounded +ddadd71364 add 9999999999999999 0.4999999999999999 -> 9999999999999999 Inexact Rounded +ddadd71365 add 9999999999999999 0.5000000000000000 -> 1.000000000000000E+16 Inexact Rounded +ddadd71367 add 9999999999999999 0.500000000000000 -> 1.000000000000000E+16 Inexact Rounded +ddadd71368 add 9999999999999999 0.50000000000000 -> 1.000000000000000E+16 Inexact Rounded +ddadd71369 add 9999999999999999 0.5000000000000 -> 1.000000000000000E+16 Inexact Rounded +ddadd71370 add 9999999999999999 0.500000000000 -> 1.000000000000000E+16 Inexact Rounded +ddadd71371 add 9999999999999999 0.50000000000 -> 1.000000000000000E+16 Inexact Rounded +ddadd71372 add 9999999999999999 0.5000000000 -> 1.000000000000000E+16 Inexact Rounded +ddadd71373 add 9999999999999999 0.500000000 -> 1.000000000000000E+16 Inexact Rounded +ddadd71374 add 9999999999999999 0.50000000 -> 1.000000000000000E+16 Inexact Rounded +ddadd71375 add 9999999999999999 0.5000000 -> 1.000000000000000E+16 Inexact Rounded +ddadd71376 add 9999999999999999 0.500000 -> 1.000000000000000E+16 Inexact Rounded +ddadd71377 add 9999999999999999 0.50000 -> 1.000000000000000E+16 Inexact Rounded +ddadd71378 add 9999999999999999 0.5000 -> 1.000000000000000E+16 Inexact Rounded +ddadd71379 add 9999999999999999 0.500 -> 1.000000000000000E+16 Inexact Rounded +ddadd71380 add 9999999999999999 0.50 -> 1.000000000000000E+16 Inexact Rounded +ddadd71381 add 9999999999999999 0.5 -> 1.000000000000000E+16 Inexact Rounded +ddadd71382 add 9999999999999999 0.5000000000000001 -> 1.000000000000000E+16 Inexact Rounded +ddadd71383 add 9999999999999999 0.500000000000001 -> 1.000000000000000E+16 Inexact Rounded +ddadd71384 add 9999999999999999 0.50000000000001 -> 1.000000000000000E+16 Inexact Rounded +ddadd71385 add 9999999999999999 0.5000000000001 -> 1.000000000000000E+16 Inexact Rounded +ddadd71386 add 9999999999999999 0.500000000001 -> 1.000000000000000E+16 Inexact Rounded +ddadd71387 add 9999999999999999 0.50000000001 -> 1.000000000000000E+16 Inexact Rounded +ddadd71388 add 9999999999999999 0.5000000001 -> 1.000000000000000E+16 Inexact Rounded +ddadd71389 add 9999999999999999 0.500000001 -> 1.000000000000000E+16 Inexact Rounded +ddadd71390 add 9999999999999999 0.50000001 -> 1.000000000000000E+16 Inexact Rounded +ddadd71391 add 9999999999999999 0.5000001 -> 1.000000000000000E+16 Inexact Rounded +ddadd71392 add 9999999999999999 0.500001 -> 1.000000000000000E+16 Inexact Rounded +ddadd71393 add 9999999999999999 0.50001 -> 1.000000000000000E+16 Inexact Rounded +ddadd71394 add 9999999999999999 0.5001 -> 1.000000000000000E+16 Inexact Rounded +ddadd71395 add 9999999999999999 0.501 -> 1.000000000000000E+16 Inexact Rounded +ddadd71396 add 9999999999999999 0.51 -> 1.000000000000000E+16 Inexact Rounded + +-- More GD edge cases, where difference between the unadjusted +-- exponents is larger than the maximum precision and one side is 0 +ddadd71420 add 0 1.123456789012345 -> 1.123456789012345 +ddadd71421 add 0 1.123456789012345E-1 -> 0.1123456789012345 +ddadd71422 add 0 1.123456789012345E-2 -> 0.01123456789012345 +ddadd71423 add 0 1.123456789012345E-3 -> 0.001123456789012345 +ddadd71424 add 0 1.123456789012345E-4 -> 0.0001123456789012345 +ddadd71425 add 0 1.123456789012345E-5 -> 0.00001123456789012345 +ddadd71426 add 0 1.123456789012345E-6 -> 0.000001123456789012345 +ddadd71427 add 0 1.123456789012345E-7 -> 1.123456789012345E-7 +ddadd71428 add 0 1.123456789012345E-8 -> 1.123456789012345E-8 +ddadd71429 add 0 1.123456789012345E-9 -> 1.123456789012345E-9 +ddadd71430 add 0 1.123456789012345E-10 -> 1.123456789012345E-10 +ddadd71431 add 0 1.123456789012345E-11 -> 1.123456789012345E-11 +ddadd71432 add 0 1.123456789012345E-12 -> 1.123456789012345E-12 +ddadd71433 add 0 1.123456789012345E-13 -> 1.123456789012345E-13 +ddadd71434 add 0 1.123456789012345E-14 -> 1.123456789012345E-14 +ddadd71435 add 0 1.123456789012345E-15 -> 1.123456789012345E-15 +ddadd71436 add 0 1.123456789012345E-16 -> 1.123456789012345E-16 +ddadd71437 add 0 1.123456789012345E-17 -> 1.123456789012345E-17 +ddadd71438 add 0 1.123456789012345E-18 -> 1.123456789012345E-18 +ddadd71439 add 0 1.123456789012345E-19 -> 1.123456789012345E-19 + +-- same, reversed 0 +ddadd71440 add 1.123456789012345 0 -> 1.123456789012345 +ddadd71441 add 1.123456789012345E-1 0 -> 0.1123456789012345 +ddadd71442 add 1.123456789012345E-2 0 -> 0.01123456789012345 +ddadd71443 add 1.123456789012345E-3 0 -> 0.001123456789012345 +ddadd71444 add 1.123456789012345E-4 0 -> 0.0001123456789012345 +ddadd71445 add 1.123456789012345E-5 0 -> 0.00001123456789012345 +ddadd71446 add 1.123456789012345E-6 0 -> 0.000001123456789012345 +ddadd71447 add 1.123456789012345E-7 0 -> 1.123456789012345E-7 +ddadd71448 add 1.123456789012345E-8 0 -> 1.123456789012345E-8 +ddadd71449 add 1.123456789012345E-9 0 -> 1.123456789012345E-9 +ddadd71450 add 1.123456789012345E-10 0 -> 1.123456789012345E-10 +ddadd71451 add 1.123456789012345E-11 0 -> 1.123456789012345E-11 +ddadd71452 add 1.123456789012345E-12 0 -> 1.123456789012345E-12 +ddadd71453 add 1.123456789012345E-13 0 -> 1.123456789012345E-13 +ddadd71454 add 1.123456789012345E-14 0 -> 1.123456789012345E-14 +ddadd71455 add 1.123456789012345E-15 0 -> 1.123456789012345E-15 +ddadd71456 add 1.123456789012345E-16 0 -> 1.123456789012345E-16 +ddadd71457 add 1.123456789012345E-17 0 -> 1.123456789012345E-17 +ddadd71458 add 1.123456789012345E-18 0 -> 1.123456789012345E-18 +ddadd71459 add 1.123456789012345E-19 0 -> 1.123456789012345E-19 + +-- same, Es on the 0 +ddadd71460 add 1.123456789012345 0E-0 -> 1.123456789012345 +ddadd71461 add 1.123456789012345 0E-1 -> 1.123456789012345 +ddadd71462 add 1.123456789012345 0E-2 -> 1.123456789012345 +ddadd71463 add 1.123456789012345 0E-3 -> 1.123456789012345 +ddadd71464 add 1.123456789012345 0E-4 -> 1.123456789012345 +ddadd71465 add 1.123456789012345 0E-5 -> 1.123456789012345 +ddadd71466 add 1.123456789012345 0E-6 -> 1.123456789012345 +ddadd71467 add 1.123456789012345 0E-7 -> 1.123456789012345 +ddadd71468 add 1.123456789012345 0E-8 -> 1.123456789012345 +ddadd71469 add 1.123456789012345 0E-9 -> 1.123456789012345 +ddadd71470 add 1.123456789012345 0E-10 -> 1.123456789012345 +ddadd71471 add 1.123456789012345 0E-11 -> 1.123456789012345 +ddadd71472 add 1.123456789012345 0E-12 -> 1.123456789012345 +ddadd71473 add 1.123456789012345 0E-13 -> 1.123456789012345 +ddadd71474 add 1.123456789012345 0E-14 -> 1.123456789012345 +ddadd71475 add 1.123456789012345 0E-15 -> 1.123456789012345 +-- next four flag Rounded because the 0 extends the result +ddadd71476 add 1.123456789012345 0E-16 -> 1.123456789012345 Rounded +ddadd71477 add 1.123456789012345 0E-17 -> 1.123456789012345 Rounded +ddadd71478 add 1.123456789012345 0E-18 -> 1.123456789012345 Rounded +ddadd71479 add 1.123456789012345 0E-19 -> 1.123456789012345 Rounded + +-- sum of two opposite-sign operands is exactly 0 and floor => -0 +rounding: half_up +-- exact zeros from zeros +ddadd71500 add 0 0E-19 -> 0E-19 +ddadd71501 add -0 0E-19 -> 0E-19 +ddadd71502 add 0 -0E-19 -> 0E-19 +ddadd71503 add -0 -0E-19 -> -0E-19 +-- exact zeros from non-zeros +ddadd71511 add -11 11 -> 0 +ddadd71512 add 11 -11 -> 0 + +rounding: half_down +-- exact zeros from zeros +ddadd71520 add 0 0E-19 -> 0E-19 +ddadd71521 add -0 0E-19 -> 0E-19 +ddadd71522 add 0 -0E-19 -> 0E-19 +ddadd71523 add -0 -0E-19 -> -0E-19 +-- exact zeros from non-zeros +ddadd71531 add -11 11 -> 0 +ddadd71532 add 11 -11 -> 0 + +rounding: half_even +-- exact zeros from zeros +ddadd71540 add 0 0E-19 -> 0E-19 +ddadd71541 add -0 0E-19 -> 0E-19 +ddadd71542 add 0 -0E-19 -> 0E-19 +ddadd71543 add -0 -0E-19 -> -0E-19 +-- exact zeros from non-zeros +ddadd71551 add -11 11 -> 0 +ddadd71552 add 11 -11 -> 0 + +rounding: up +-- exact zeros from zeros +ddadd71560 add 0 0E-19 -> 0E-19 +ddadd71561 add -0 0E-19 -> 0E-19 +ddadd71562 add 0 -0E-19 -> 0E-19 +ddadd71563 add -0 -0E-19 -> -0E-19 +-- exact zeros from non-zeros +ddadd71571 add -11 11 -> 0 +ddadd71572 add 11 -11 -> 0 + +rounding: down +-- exact zeros from zeros +ddadd71580 add 0 0E-19 -> 0E-19 +ddadd71581 add -0 0E-19 -> 0E-19 +ddadd71582 add 0 -0E-19 -> 0E-19 +ddadd71583 add -0 -0E-19 -> -0E-19 +-- exact zeros from non-zeros +ddadd71591 add -11 11 -> 0 +ddadd71592 add 11 -11 -> 0 + +rounding: ceiling +-- exact zeros from zeros +ddadd71600 add 0 0E-19 -> 0E-19 +ddadd71601 add -0 0E-19 -> 0E-19 +ddadd71602 add 0 -0E-19 -> 0E-19 +ddadd71603 add -0 -0E-19 -> -0E-19 +-- exact zeros from non-zeros +ddadd71611 add -11 11 -> 0 +ddadd71612 add 11 -11 -> 0 + +-- and the extra-special ugly case; unusual minuses marked by -- * +rounding: floor +-- exact zeros from zeros +ddadd71620 add 0 0E-19 -> 0E-19 +ddadd71621 add -0 0E-19 -> -0E-19 -- * +ddadd71622 add 0 -0E-19 -> -0E-19 -- * +ddadd71623 add -0 -0E-19 -> -0E-19 +-- exact zeros from non-zeros +ddadd71631 add -11 11 -> -0 -- * +ddadd71632 add 11 -11 -> -0 -- * + +-- Examples from SQL proposal (Krishna Kulkarni) +ddadd71701 add 130E-2 120E-2 -> 2.50 +ddadd71702 add 130E-2 12E-1 -> 2.50 +ddadd71703 add 130E-2 1E0 -> 2.30 +ddadd71704 add 1E2 1E4 -> 1.01E+4 +ddadd71705 add 130E-2 -120E-2 -> 0.10 +ddadd71706 add 130E-2 -12E-1 -> 0.10 +ddadd71707 add 130E-2 -1E0 -> 0.30 +ddadd71708 add 1E2 -1E4 -> -9.9E+3 + +-- query from Vincent Kulandaisamy +rounding: ceiling +ddadd71801 add 7.8822773805862E+277 -5.1757503820663E-21 -> 7.882277380586200E+277 Inexact Rounded +ddadd71802 add 7.882277380586200E+277 12.341 -> 7.882277380586201E+277 Inexact Rounded +ddadd71803 add 7.882277380586201E+277 2.7270545046613E-31 -> 7.882277380586202E+277 Inexact Rounded + +ddadd71811 add 12.341 -5.1757503820663E-21 -> 12.34100000000000 Inexact Rounded +ddadd71812 add 12.34100000000000 2.7270545046613E-31 -> 12.34100000000001 Inexact Rounded +ddadd71813 add 12.34100000000001 7.8822773805862E+277 -> 7.882277380586201E+277 Inexact Rounded + +-- Gappy coefficients; check residue handling even with full coefficient gap +rounding: half_even + +ddadd75001 add 1234567890123456 1 -> 1234567890123457 +ddadd75002 add 1234567890123456 0.6 -> 1234567890123457 Inexact Rounded +ddadd75003 add 1234567890123456 0.06 -> 1234567890123456 Inexact Rounded +ddadd75004 add 1234567890123456 6E-3 -> 1234567890123456 Inexact Rounded +ddadd75005 add 1234567890123456 6E-4 -> 1234567890123456 Inexact Rounded +ddadd75006 add 1234567890123456 6E-5 -> 1234567890123456 Inexact Rounded +ddadd75007 add 1234567890123456 6E-6 -> 1234567890123456 Inexact Rounded +ddadd75008 add 1234567890123456 6E-7 -> 1234567890123456 Inexact Rounded +ddadd75009 add 1234567890123456 6E-8 -> 1234567890123456 Inexact Rounded +ddadd75010 add 1234567890123456 6E-9 -> 1234567890123456 Inexact Rounded +ddadd75011 add 1234567890123456 6E-10 -> 1234567890123456 Inexact Rounded +ddadd75012 add 1234567890123456 6E-11 -> 1234567890123456 Inexact Rounded +ddadd75013 add 1234567890123456 6E-12 -> 1234567890123456 Inexact Rounded +ddadd75014 add 1234567890123456 6E-13 -> 1234567890123456 Inexact Rounded +ddadd75015 add 1234567890123456 6E-14 -> 1234567890123456 Inexact Rounded +ddadd75016 add 1234567890123456 6E-15 -> 1234567890123456 Inexact Rounded +ddadd75017 add 1234567890123456 6E-16 -> 1234567890123456 Inexact Rounded +ddadd75018 add 1234567890123456 6E-17 -> 1234567890123456 Inexact Rounded +ddadd75019 add 1234567890123456 6E-18 -> 1234567890123456 Inexact Rounded +ddadd75020 add 1234567890123456 6E-19 -> 1234567890123456 Inexact Rounded +ddadd75021 add 1234567890123456 6E-20 -> 1234567890123456 Inexact Rounded + +-- widening second argument at gap +ddadd75030 add 12345678 1 -> 12345679 +ddadd75031 add 12345678 0.1 -> 12345678.1 +ddadd75032 add 12345678 0.12 -> 12345678.12 +ddadd75033 add 12345678 0.123 -> 12345678.123 +ddadd75034 add 12345678 0.1234 -> 12345678.1234 +ddadd75035 add 12345678 0.12345 -> 12345678.12345 +ddadd75036 add 12345678 0.123456 -> 12345678.123456 +ddadd75037 add 12345678 0.1234567 -> 12345678.1234567 +ddadd75038 add 12345678 0.12345678 -> 12345678.12345678 +ddadd75039 add 12345678 0.123456789 -> 12345678.12345679 Inexact Rounded +ddadd75040 add 12345678 0.123456785 -> 12345678.12345678 Inexact Rounded +ddadd75041 add 12345678 0.1234567850 -> 12345678.12345678 Inexact Rounded +ddadd75042 add 12345678 0.1234567851 -> 12345678.12345679 Inexact Rounded +ddadd75043 add 12345678 0.12345678501 -> 12345678.12345679 Inexact Rounded +ddadd75044 add 12345678 0.123456785001 -> 12345678.12345679 Inexact Rounded +ddadd75045 add 12345678 0.1234567850001 -> 12345678.12345679 Inexact Rounded +ddadd75046 add 12345678 0.12345678500001 -> 12345678.12345679 Inexact Rounded +ddadd75047 add 12345678 0.123456785000001 -> 12345678.12345679 Inexact Rounded +ddadd75048 add 12345678 0.1234567850000001 -> 12345678.12345679 Inexact Rounded +ddadd75049 add 12345678 0.1234567850000000 -> 12345678.12345678 Inexact Rounded +-- 90123456 +rounding: half_even +ddadd75050 add 12345678 0.0234567750000000 -> 12345678.02345678 Inexact Rounded +ddadd75051 add 12345678 0.0034567750000000 -> 12345678.00345678 Inexact Rounded +ddadd75052 add 12345678 0.0004567750000000 -> 12345678.00045678 Inexact Rounded +ddadd75053 add 12345678 0.0000567750000000 -> 12345678.00005678 Inexact Rounded +ddadd75054 add 12345678 0.0000067750000000 -> 12345678.00000678 Inexact Rounded +ddadd75055 add 12345678 0.0000007750000000 -> 12345678.00000078 Inexact Rounded +ddadd75056 add 12345678 0.0000000750000000 -> 12345678.00000008 Inexact Rounded +ddadd75057 add 12345678 0.0000000050000000 -> 12345678.00000000 Inexact Rounded +ddadd75060 add 12345678 0.0234567750000001 -> 12345678.02345678 Inexact Rounded +ddadd75061 add 12345678 0.0034567750000001 -> 12345678.00345678 Inexact Rounded +ddadd75062 add 12345678 0.0004567750000001 -> 12345678.00045678 Inexact Rounded +ddadd75063 add 12345678 0.0000567750000001 -> 12345678.00005678 Inexact Rounded +ddadd75064 add 12345678 0.0000067750000001 -> 12345678.00000678 Inexact Rounded +ddadd75065 add 12345678 0.0000007750000001 -> 12345678.00000078 Inexact Rounded +ddadd75066 add 12345678 0.0000000750000001 -> 12345678.00000008 Inexact Rounded +ddadd75067 add 12345678 0.0000000050000001 -> 12345678.00000001 Inexact Rounded +-- far-out residues (full coefficient gap is 16+15 digits) +rounding: up +ddadd75070 add 12345678 1E-8 -> 12345678.00000001 +ddadd75071 add 12345678 1E-9 -> 12345678.00000001 Inexact Rounded +ddadd75072 add 12345678 1E-10 -> 12345678.00000001 Inexact Rounded +ddadd75073 add 12345678 1E-11 -> 12345678.00000001 Inexact Rounded +ddadd75074 add 12345678 1E-12 -> 12345678.00000001 Inexact Rounded +ddadd75075 add 12345678 1E-13 -> 12345678.00000001 Inexact Rounded +ddadd75076 add 12345678 1E-14 -> 12345678.00000001 Inexact Rounded +ddadd75077 add 12345678 1E-15 -> 12345678.00000001 Inexact Rounded +ddadd75078 add 12345678 1E-16 -> 12345678.00000001 Inexact Rounded +ddadd75079 add 12345678 1E-17 -> 12345678.00000001 Inexact Rounded +ddadd75080 add 12345678 1E-18 -> 12345678.00000001 Inexact Rounded +ddadd75081 add 12345678 1E-19 -> 12345678.00000001 Inexact Rounded +ddadd75082 add 12345678 1E-20 -> 12345678.00000001 Inexact Rounded +ddadd75083 add 12345678 1E-25 -> 12345678.00000001 Inexact Rounded +ddadd75084 add 12345678 1E-30 -> 12345678.00000001 Inexact Rounded +ddadd75085 add 12345678 1E-31 -> 12345678.00000001 Inexact Rounded +ddadd75086 add 12345678 1E-32 -> 12345678.00000001 Inexact Rounded +ddadd75087 add 12345678 1E-33 -> 12345678.00000001 Inexact Rounded +ddadd75088 add 12345678 1E-34 -> 12345678.00000001 Inexact Rounded +ddadd75089 add 12345678 1E-35 -> 12345678.00000001 Inexact Rounded + +-- Punit's +ddadd75100 add 1.000 -200.000 -> -199.000 + +-- Rounding swathe +rounding: half_even +ddadd81100 add .2300 12345678901234.00 -> 12345678901234.23 Rounded +ddadd81101 add .2301 12345678901234.00 -> 12345678901234.23 Inexact Rounded +ddadd81102 add .2310 12345678901234.00 -> 12345678901234.23 Inexact Rounded +ddadd81103 add .2350 12345678901234.00 -> 12345678901234.24 Inexact Rounded +ddadd81104 add .2351 12345678901234.00 -> 12345678901234.24 Inexact Rounded +ddadd81105 add .2450 12345678901234.00 -> 12345678901234.24 Inexact Rounded +ddadd81106 add .2451 12345678901234.00 -> 12345678901234.25 Inexact Rounded +ddadd81107 add .2360 12345678901234.00 -> 12345678901234.24 Inexact Rounded +ddadd81108 add .2370 12345678901234.00 -> 12345678901234.24 Inexact Rounded +ddadd81109 add .2399 12345678901234.00 -> 12345678901234.24 Inexact Rounded +ddadd81120 add 9999999999999999E+369 9E+369 -> Infinity Overflow Inexact Rounded +ddadd81121 add -9999999999999999E+369 -9E+369 -> -Infinity Overflow Inexact Rounded + +rounding: half_up +ddadd81200 add .2300 12345678901234.00 -> 12345678901234.23 Rounded +ddadd81201 add .2301 12345678901234.00 -> 12345678901234.23 Inexact Rounded +ddadd81202 add .2310 12345678901234.00 -> 12345678901234.23 Inexact Rounded +ddadd81203 add .2350 12345678901234.00 -> 12345678901234.24 Inexact Rounded +ddadd81204 add .2351 12345678901234.00 -> 12345678901234.24 Inexact Rounded +ddadd81205 add .2450 12345678901234.00 -> 12345678901234.25 Inexact Rounded +ddadd81206 add .2451 12345678901234.00 -> 12345678901234.25 Inexact Rounded +ddadd81207 add .2360 12345678901234.00 -> 12345678901234.24 Inexact Rounded +ddadd81208 add .2370 12345678901234.00 -> 12345678901234.24 Inexact Rounded +ddadd81209 add .2399 12345678901234.00 -> 12345678901234.24 Inexact Rounded +ddadd81220 add 9999999999999999E+369 9E+369 -> Infinity Overflow Inexact Rounded +ddadd81221 add -9999999999999999E+369 -9E+369 -> -Infinity Overflow Inexact Rounded + +rounding: half_down +ddadd81300 add .2300 12345678901234.00 -> 12345678901234.23 Rounded +ddadd81301 add .2301 12345678901234.00 -> 12345678901234.23 Inexact Rounded +ddadd81302 add .2310 12345678901234.00 -> 12345678901234.23 Inexact Rounded +ddadd81303 add .2350 12345678901234.00 -> 12345678901234.23 Inexact Rounded +ddadd81304 add .2351 12345678901234.00 -> 12345678901234.24 Inexact Rounded +ddadd81305 add .2450 12345678901234.00 -> 12345678901234.24 Inexact Rounded +ddadd81306 add .2451 12345678901234.00 -> 12345678901234.25 Inexact Rounded +ddadd81307 add .2360 12345678901234.00 -> 12345678901234.24 Inexact Rounded +ddadd81308 add .2370 12345678901234.00 -> 12345678901234.24 Inexact Rounded +ddadd81309 add .2399 12345678901234.00 -> 12345678901234.24 Inexact Rounded +ddadd81320 add 9999999999999999E+369 9E+369 -> Infinity Overflow Inexact Rounded +ddadd81321 add -9999999999999999E+369 -9E+369 -> -Infinity Overflow Inexact Rounded + +rounding: up +ddadd81400 add .2300 12345678901234.00 -> 12345678901234.23 Rounded +ddadd81401 add .2301 12345678901234.00 -> 12345678901234.24 Inexact Rounded +ddadd81402 add .2310 12345678901234.00 -> 12345678901234.24 Inexact Rounded +ddadd81403 add .2350 12345678901234.00 -> 12345678901234.24 Inexact Rounded +ddadd81404 add .2351 12345678901234.00 -> 12345678901234.24 Inexact Rounded +ddadd81405 add .2450 12345678901234.00 -> 12345678901234.25 Inexact Rounded +ddadd81406 add .2451 12345678901234.00 -> 12345678901234.25 Inexact Rounded +ddadd81407 add .2360 12345678901234.00 -> 12345678901234.24 Inexact Rounded +ddadd81408 add .2370 12345678901234.00 -> 12345678901234.24 Inexact Rounded +ddadd81409 add .2399 12345678901234.00 -> 12345678901234.24 Inexact Rounded +ddadd81411 add -.2399 -12345678901234.00 -> -12345678901234.24 Inexact Rounded +ddadd81420 add 9999999999999999E+369 9E+369 -> Infinity Overflow Inexact Rounded +ddadd81421 add -9999999999999999E+369 -9E+369 -> -Infinity Overflow Inexact Rounded + +rounding: down +ddadd81500 add .2300 12345678901234.00 -> 12345678901234.23 Rounded +ddadd81501 add .2301 12345678901234.00 -> 12345678901234.23 Inexact Rounded +ddadd81502 add .2310 12345678901234.00 -> 12345678901234.23 Inexact Rounded +ddadd81503 add .2350 12345678901234.00 -> 12345678901234.23 Inexact Rounded +ddadd81504 add .2351 12345678901234.00 -> 12345678901234.23 Inexact Rounded +ddadd81505 add .2450 12345678901234.00 -> 12345678901234.24 Inexact Rounded +ddadd81506 add .2451 12345678901234.00 -> 12345678901234.24 Inexact Rounded +ddadd81507 add .2360 12345678901234.00 -> 12345678901234.23 Inexact Rounded +ddadd81508 add .2370 12345678901234.00 -> 12345678901234.23 Inexact Rounded +ddadd81509 add .2399 12345678901234.00 -> 12345678901234.23 Inexact Rounded +ddadd81511 add -.2399 -12345678901234.00 -> -12345678901234.23 Inexact Rounded +ddadd81520 add 9999999999999999E+369 9E+369 -> 9.999999999999999E+384 Overflow Inexact Rounded +ddadd81521 add -9999999999999999E+369 -9E+369 -> -9.999999999999999E+384 Overflow Inexact Rounded + +rounding: ceiling +ddadd81600 add .2300 12345678901234.00 -> 12345678901234.23 Rounded +ddadd81601 add .2301 12345678901234.00 -> 12345678901234.24 Inexact Rounded +ddadd81602 add .2310 12345678901234.00 -> 12345678901234.24 Inexact Rounded +ddadd81603 add .2350 12345678901234.00 -> 12345678901234.24 Inexact Rounded +ddadd81604 add .2351 12345678901234.00 -> 12345678901234.24 Inexact Rounded +ddadd81605 add .2450 12345678901234.00 -> 12345678901234.25 Inexact Rounded +ddadd81606 add .2451 12345678901234.00 -> 12345678901234.25 Inexact Rounded +ddadd81607 add .2360 12345678901234.00 -> 12345678901234.24 Inexact Rounded +ddadd81608 add .2370 12345678901234.00 -> 12345678901234.24 Inexact Rounded +ddadd81609 add .2399 12345678901234.00 -> 12345678901234.24 Inexact Rounded +ddadd81611 add -.2399 -12345678901234.00 -> -12345678901234.23 Inexact Rounded +ddadd81620 add 9999999999999999E+369 9E+369 -> Infinity Overflow Inexact Rounded +ddadd81621 add -9999999999999999E+369 -9E+369 -> -9.999999999999999E+384 Overflow Inexact Rounded + +rounding: floor +ddadd81700 add .2300 12345678901234.00 -> 12345678901234.23 Rounded +ddadd81701 add .2301 12345678901234.00 -> 12345678901234.23 Inexact Rounded +ddadd81702 add .2310 12345678901234.00 -> 12345678901234.23 Inexact Rounded +ddadd81703 add .2350 12345678901234.00 -> 12345678901234.23 Inexact Rounded +ddadd81704 add .2351 12345678901234.00 -> 12345678901234.23 Inexact Rounded +ddadd81705 add .2450 12345678901234.00 -> 12345678901234.24 Inexact Rounded +ddadd81706 add .2451 12345678901234.00 -> 12345678901234.24 Inexact Rounded +ddadd81707 add .2360 12345678901234.00 -> 12345678901234.23 Inexact Rounded +ddadd81708 add .2370 12345678901234.00 -> 12345678901234.23 Inexact Rounded +ddadd81709 add .2399 12345678901234.00 -> 12345678901234.23 Inexact Rounded +ddadd81711 add -.2399 -12345678901234.00 -> -12345678901234.24 Inexact Rounded +ddadd81720 add 9999999999999999E+369 9E+369 -> 9.999999999999999E+384 Overflow Inexact Rounded +ddadd81721 add -9999999999999999E+369 -9E+369 -> -Infinity Overflow Inexact Rounded + +rounding: 05up +ddadd81800 add .2000 12345678901234.00 -> 12345678901234.20 Rounded +ddadd81801 add .2001 12345678901234.00 -> 12345678901234.21 Inexact Rounded +ddadd81802 add .2010 12345678901234.00 -> 12345678901234.21 Inexact Rounded +ddadd81803 add .2050 12345678901234.00 -> 12345678901234.21 Inexact Rounded +ddadd81804 add .2051 12345678901234.00 -> 12345678901234.21 Inexact Rounded +ddadd81807 add .2060 12345678901234.00 -> 12345678901234.21 Inexact Rounded +ddadd81808 add .2070 12345678901234.00 -> 12345678901234.21 Inexact Rounded +ddadd81809 add .2099 12345678901234.00 -> 12345678901234.21 Inexact Rounded +ddadd81811 add -.2099 -12345678901234.00 -> -12345678901234.21 Inexact Rounded +ddadd81820 add 9999999999999999E+369 9E+369 -> 9.999999999999999E+384 Overflow Inexact Rounded +ddadd81821 add -9999999999999999E+369 -9E+369 -> -9.999999999999999E+384 Overflow Inexact Rounded + +ddadd81900 add .2100 12345678901234.00 -> 12345678901234.21 Rounded +ddadd81901 add .2101 12345678901234.00 -> 12345678901234.21 Inexact Rounded +ddadd81902 add .2110 12345678901234.00 -> 12345678901234.21 Inexact Rounded +ddadd81903 add .2150 12345678901234.00 -> 12345678901234.21 Inexact Rounded +ddadd81904 add .2151 12345678901234.00 -> 12345678901234.21 Inexact Rounded +ddadd81907 add .2160 12345678901234.00 -> 12345678901234.21 Inexact Rounded +ddadd81908 add .2170 12345678901234.00 -> 12345678901234.21 Inexact Rounded +ddadd81909 add .2199 12345678901234.00 -> 12345678901234.21 Inexact Rounded +ddadd81911 add -.2199 -12345678901234.00 -> -12345678901234.21 Inexact Rounded + +ddadd82000 add .2400 12345678901234.00 -> 12345678901234.24 Rounded +ddadd82001 add .2401 12345678901234.00 -> 12345678901234.24 Inexact Rounded +ddadd82002 add .2410 12345678901234.00 -> 12345678901234.24 Inexact Rounded +ddadd82003 add .2450 12345678901234.00 -> 12345678901234.24 Inexact Rounded +ddadd82004 add .2451 12345678901234.00 -> 12345678901234.24 Inexact Rounded +ddadd82007 add .2460 12345678901234.00 -> 12345678901234.24 Inexact Rounded +ddadd82008 add .2470 12345678901234.00 -> 12345678901234.24 Inexact Rounded +ddadd82009 add .2499 12345678901234.00 -> 12345678901234.24 Inexact Rounded +ddadd82011 add -.2499 -12345678901234.00 -> -12345678901234.24 Inexact Rounded + +ddadd82100 add .2500 12345678901234.00 -> 12345678901234.25 Rounded +ddadd82101 add .2501 12345678901234.00 -> 12345678901234.26 Inexact Rounded +ddadd82102 add .2510 12345678901234.00 -> 12345678901234.26 Inexact Rounded +ddadd82103 add .2550 12345678901234.00 -> 12345678901234.26 Inexact Rounded +ddadd82104 add .2551 12345678901234.00 -> 12345678901234.26 Inexact Rounded +ddadd82107 add .2560 12345678901234.00 -> 12345678901234.26 Inexact Rounded +ddadd82108 add .2570 12345678901234.00 -> 12345678901234.26 Inexact Rounded +ddadd82109 add .2599 12345678901234.00 -> 12345678901234.26 Inexact Rounded +ddadd82111 add -.2599 -12345678901234.00 -> -12345678901234.26 Inexact Rounded + +ddadd82200 add .2600 12345678901234.00 -> 12345678901234.26 Rounded +ddadd82201 add .2601 12345678901234.00 -> 12345678901234.26 Inexact Rounded +ddadd82202 add .2610 12345678901234.00 -> 12345678901234.26 Inexact Rounded +ddadd82203 add .2650 12345678901234.00 -> 12345678901234.26 Inexact Rounded +ddadd82204 add .2651 12345678901234.00 -> 12345678901234.26 Inexact Rounded +ddadd82207 add .2660 12345678901234.00 -> 12345678901234.26 Inexact Rounded +ddadd82208 add .2670 12345678901234.00 -> 12345678901234.26 Inexact Rounded +ddadd82209 add .2699 12345678901234.00 -> 12345678901234.26 Inexact Rounded +ddadd82211 add -.2699 -12345678901234.00 -> -12345678901234.26 Inexact Rounded + +ddadd82300 add .2900 12345678901234.00 -> 12345678901234.29 Rounded +ddadd82301 add .2901 12345678901234.00 -> 12345678901234.29 Inexact Rounded +ddadd82302 add .2910 12345678901234.00 -> 12345678901234.29 Inexact Rounded +ddadd82303 add .2950 12345678901234.00 -> 12345678901234.29 Inexact Rounded +ddadd82304 add .2951 12345678901234.00 -> 12345678901234.29 Inexact Rounded +ddadd82307 add .2960 12345678901234.00 -> 12345678901234.29 Inexact Rounded +ddadd82308 add .2970 12345678901234.00 -> 12345678901234.29 Inexact Rounded +ddadd82309 add .2999 12345678901234.00 -> 12345678901234.29 Inexact Rounded +ddadd82311 add -.2999 -12345678901234.00 -> -12345678901234.29 Inexact Rounded + +-- Null tests +ddadd9990 add 10 # -> NaN Invalid_operation +ddadd9991 add # 10 -> NaN Invalid_operation Added: python/branches/release25-maint/Lib/test/decimaltestdata/ddAnd.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/ddAnd.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,347 @@ +------------------------------------------------------------------------ +-- ddAnd.decTest -- digitwise logical AND for decDoubles -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +precision: 16 +maxExponent: 384 +minExponent: -383 +extended: 1 +clamp: 1 +rounding: half_even + +-- Sanity check (truth table) +ddand001 and 0 0 -> 0 +ddand002 and 0 1 -> 0 +ddand003 and 1 0 -> 0 +ddand004 and 1 1 -> 1 +ddand005 and 1100 1010 -> 1000 +-- and at msd and msd-1 +-- 1234567890123456 1234567890123456 1234567890123456 +ddand006 and 0000000000000000 0000000000000000 -> 0 +ddand007 and 0000000000000000 1000000000000000 -> 0 +ddand008 and 1000000000000000 0000000000000000 -> 0 +ddand009 and 1000000000000000 1000000000000000 -> 1000000000000000 +ddand010 and 0000000000000000 0000000000000000 -> 0 +ddand011 and 0000000000000000 0100000000000000 -> 0 +ddand012 and 0100000000000000 0000000000000000 -> 0 +ddand013 and 0100000000000000 0100000000000000 -> 100000000000000 + +-- Various lengths +-- 1234567890123456 1234567890123456 1234567890123456 +ddand021 and 1111111111111111 1111111111111111 -> 1111111111111111 +ddand024 and 1111111111111111 111111111111111 -> 111111111111111 +ddand025 and 1111111111111111 11111111111111 -> 11111111111111 +ddand026 and 1111111111111111 1111111111111 -> 1111111111111 +ddand027 and 1111111111111111 111111111111 -> 111111111111 +ddand028 and 1111111111111111 11111111111 -> 11111111111 +ddand029 and 1111111111111111 1111111111 -> 1111111111 +ddand030 and 1111111111111111 111111111 -> 111111111 +ddand031 and 1111111111111111 11111111 -> 11111111 +ddand032 and 1111111111111111 1111111 -> 1111111 +ddand033 and 1111111111111111 111111 -> 111111 +ddand034 and 1111111111111111 11111 -> 11111 +ddand035 and 1111111111111111 1111 -> 1111 +ddand036 and 1111111111111111 111 -> 111 +ddand037 and 1111111111111111 11 -> 11 +ddand038 and 1111111111111111 1 -> 1 +ddand039 and 1111111111111111 0 -> 0 + +ddand040 and 1111111111111111 1111111111111111 -> 1111111111111111 +ddand041 and 111111111111111 1111111111111111 -> 111111111111111 +ddand042 and 111111111111111 1111111111111111 -> 111111111111111 +ddand043 and 11111111111111 1111111111111111 -> 11111111111111 +ddand044 and 1111111111111 1111111111111111 -> 1111111111111 +ddand045 and 111111111111 1111111111111111 -> 111111111111 +ddand046 and 11111111111 1111111111111111 -> 11111111111 +ddand047 and 1111111111 1111111111111111 -> 1111111111 +ddand048 and 111111111 1111111111111111 -> 111111111 +ddand049 and 11111111 1111111111111111 -> 11111111 +ddand050 and 1111111 1111111111111111 -> 1111111 +ddand051 and 111111 1111111111111111 -> 111111 +ddand052 and 11111 1111111111111111 -> 11111 +ddand053 and 1111 1111111111111111 -> 1111 +ddand054 and 111 1111111111111111 -> 111 +ddand055 and 11 1111111111111111 -> 11 +ddand056 and 1 1111111111111111 -> 1 +ddand057 and 0 1111111111111111 -> 0 + +ddand150 and 1111111111 1 -> 1 +ddand151 and 111111111 1 -> 1 +ddand152 and 11111111 1 -> 1 +ddand153 and 1111111 1 -> 1 +ddand154 and 111111 1 -> 1 +ddand155 and 11111 1 -> 1 +ddand156 and 1111 1 -> 1 +ddand157 and 111 1 -> 1 +ddand158 and 11 1 -> 1 +ddand159 and 1 1 -> 1 + +ddand160 and 1111111111 0 -> 0 +ddand161 and 111111111 0 -> 0 +ddand162 and 11111111 0 -> 0 +ddand163 and 1111111 0 -> 0 +ddand164 and 111111 0 -> 0 +ddand165 and 11111 0 -> 0 +ddand166 and 1111 0 -> 0 +ddand167 and 111 0 -> 0 +ddand168 and 11 0 -> 0 +ddand169 and 1 0 -> 0 + +ddand170 and 1 1111111111 -> 1 +ddand171 and 1 111111111 -> 1 +ddand172 and 1 11111111 -> 1 +ddand173 and 1 1111111 -> 1 +ddand174 and 1 111111 -> 1 +ddand175 and 1 11111 -> 1 +ddand176 and 1 1111 -> 1 +ddand177 and 1 111 -> 1 +ddand178 and 1 11 -> 1 +ddand179 and 1 1 -> 1 + +ddand180 and 0 1111111111 -> 0 +ddand181 and 0 111111111 -> 0 +ddand182 and 0 11111111 -> 0 +ddand183 and 0 1111111 -> 0 +ddand184 and 0 111111 -> 0 +ddand185 and 0 11111 -> 0 +ddand186 and 0 1111 -> 0 +ddand187 and 0 111 -> 0 +ddand188 and 0 11 -> 0 +ddand189 and 0 1 -> 0 + +ddand090 and 011111111 111111111 -> 11111111 +ddand091 and 101111111 111111111 -> 101111111 +ddand092 and 110111111 111111111 -> 110111111 +ddand093 and 111011111 111111111 -> 111011111 +ddand094 and 111101111 111111111 -> 111101111 +ddand095 and 111110111 111111111 -> 111110111 +ddand096 and 111111011 111111111 -> 111111011 +ddand097 and 111111101 111111111 -> 111111101 +ddand098 and 111111110 111111111 -> 111111110 + +ddand100 and 111111111 011111111 -> 11111111 +ddand101 and 111111111 101111111 -> 101111111 +ddand102 and 111111111 110111111 -> 110111111 +ddand103 and 111111111 111011111 -> 111011111 +ddand104 and 111111111 111101111 -> 111101111 +ddand105 and 111111111 111110111 -> 111110111 +ddand106 and 111111111 111111011 -> 111111011 +ddand107 and 111111111 111111101 -> 111111101 +ddand108 and 111111111 111111110 -> 111111110 + +-- non-0/1 should not be accepted, nor should signs +ddand220 and 111111112 111111111 -> NaN Invalid_operation +ddand221 and 333333333 333333333 -> NaN Invalid_operation +ddand222 and 555555555 555555555 -> NaN Invalid_operation +ddand223 and 777777777 777777777 -> NaN Invalid_operation +ddand224 and 999999999 999999999 -> NaN Invalid_operation +ddand225 and 222222222 999999999 -> NaN Invalid_operation +ddand226 and 444444444 999999999 -> NaN Invalid_operation +ddand227 and 666666666 999999999 -> NaN Invalid_operation +ddand228 and 888888888 999999999 -> NaN Invalid_operation +ddand229 and 999999999 222222222 -> NaN Invalid_operation +ddand230 and 999999999 444444444 -> NaN Invalid_operation +ddand231 and 999999999 666666666 -> NaN Invalid_operation +ddand232 and 999999999 888888888 -> NaN Invalid_operation +-- a few randoms +ddand240 and 567468689 -934981942 -> NaN Invalid_operation +ddand241 and 567367689 934981942 -> NaN Invalid_operation +ddand242 and -631917772 -706014634 -> NaN Invalid_operation +ddand243 and -756253257 138579234 -> NaN Invalid_operation +ddand244 and 835590149 567435400 -> NaN Invalid_operation +-- test MSD +ddand250 and 2000000000000000 1000000000000000 -> NaN Invalid_operation +ddand251 and 7000000000000000 1000000000000000 -> NaN Invalid_operation +ddand252 and 8000000000000000 1000000000000000 -> NaN Invalid_operation +ddand253 and 9000000000000000 1000000000000000 -> NaN Invalid_operation +ddand254 and 2000000000000000 0000000000000000 -> NaN Invalid_operation +ddand255 and 7000000000000000 0000000000000000 -> NaN Invalid_operation +ddand256 and 8000000000000000 0000000000000000 -> NaN Invalid_operation +ddand257 and 9000000000000000 0000000000000000 -> NaN Invalid_operation +ddand258 and 1000000000000000 2000000000000000 -> NaN Invalid_operation +ddand259 and 1000000000000000 7000000000000000 -> NaN Invalid_operation +ddand260 and 1000000000000000 8000000000000000 -> NaN Invalid_operation +ddand261 and 1000000000000000 9000000000000000 -> NaN Invalid_operation +ddand262 and 0000000000000000 2000000000000000 -> NaN Invalid_operation +ddand263 and 0000000000000000 7000000000000000 -> NaN Invalid_operation +ddand264 and 0000000000000000 8000000000000000 -> NaN Invalid_operation +ddand265 and 0000000000000000 9000000000000000 -> NaN Invalid_operation +-- test MSD-1 +ddand270 and 0200001000000000 1000100000000010 -> NaN Invalid_operation +ddand271 and 0700000100000000 1000010000000100 -> NaN Invalid_operation +ddand272 and 0800000010000000 1000001000001000 -> NaN Invalid_operation +ddand273 and 0900000001000000 1000000100010000 -> NaN Invalid_operation +ddand274 and 1000000000100000 0200000010100000 -> NaN Invalid_operation +ddand275 and 1000000000010000 0700000001000000 -> NaN Invalid_operation +ddand276 and 1000000000001000 0800000010100000 -> NaN Invalid_operation +ddand277 and 1000000000000100 0900000000010000 -> NaN Invalid_operation +-- test LSD +ddand280 and 0010000000000002 1000000100000001 -> NaN Invalid_operation +ddand281 and 0001000000000007 1000001000000011 -> NaN Invalid_operation +ddand282 and 0000100000000008 1000010000000001 -> NaN Invalid_operation +ddand283 and 0000010000000009 1000100000000001 -> NaN Invalid_operation +ddand284 and 1000001000000000 0001000000000002 -> NaN Invalid_operation +ddand285 and 1000000100000000 0010000000000007 -> NaN Invalid_operation +ddand286 and 1000000010000000 0100000000000008 -> NaN Invalid_operation +ddand287 and 1000000001000000 1000000000000009 -> NaN Invalid_operation +-- test Middie +ddand288 and 0010000020000000 1000001000000000 -> NaN Invalid_operation +ddand289 and 0001000070000001 1000000100000000 -> NaN Invalid_operation +ddand290 and 0000100080000010 1000000010000000 -> NaN Invalid_operation +ddand291 and 0000010090000100 1000000001000000 -> NaN Invalid_operation +ddand292 and 1000001000001000 0000000020100000 -> NaN Invalid_operation +ddand293 and 1000000100010000 0000000070010000 -> NaN Invalid_operation +ddand294 and 1000000010100000 0000000080001000 -> NaN Invalid_operation +ddand295 and 1000000001000000 0000000090000100 -> NaN Invalid_operation +-- signs +ddand296 and -1000000001000000 -0000010000000100 -> NaN Invalid_operation +ddand297 and -1000000001000000 0000000010000100 -> NaN Invalid_operation +ddand298 and 1000000001000000 -0000001000000100 -> NaN Invalid_operation +ddand299 and 1000000001000000 0000000011000100 -> 1000000 + +-- Nmax, Nmin, Ntiny-like +ddand331 and 2 9.99999999E+199 -> NaN Invalid_operation +ddand332 and 3 1E-199 -> NaN Invalid_operation +ddand333 and 4 1.00000000E-199 -> NaN Invalid_operation +ddand334 and 5 1E-100 -> NaN Invalid_operation +ddand335 and 6 -1E-100 -> NaN Invalid_operation +ddand336 and 7 -1.00000000E-199 -> NaN Invalid_operation +ddand337 and 8 -1E-199 -> NaN Invalid_operation +ddand338 and 9 -9.99999999E+199 -> NaN Invalid_operation +ddand341 and 9.99999999E+199 -18 -> NaN Invalid_operation +ddand342 and 1E-199 01 -> NaN Invalid_operation +ddand343 and 1.00000000E-199 -18 -> NaN Invalid_operation +ddand344 and 1E-100 18 -> NaN Invalid_operation +ddand345 and -1E-100 -10 -> NaN Invalid_operation +ddand346 and -1.00000000E-199 18 -> NaN Invalid_operation +ddand347 and -1E-199 10 -> NaN Invalid_operation +ddand348 and -9.99999999E+199 -18 -> NaN Invalid_operation + +-- A few other non-integers +ddand361 and 1.0 1 -> NaN Invalid_operation +ddand362 and 1E+1 1 -> NaN Invalid_operation +ddand363 and 0.0 1 -> NaN Invalid_operation +ddand364 and 0E+1 1 -> NaN Invalid_operation +ddand365 and 9.9 1 -> NaN Invalid_operation +ddand366 and 9E+1 1 -> NaN Invalid_operation +ddand371 and 0 1.0 -> NaN Invalid_operation +ddand372 and 0 1E+1 -> NaN Invalid_operation +ddand373 and 0 0.0 -> NaN Invalid_operation +ddand374 and 0 0E+1 -> NaN Invalid_operation +ddand375 and 0 9.9 -> NaN Invalid_operation +ddand376 and 0 9E+1 -> NaN Invalid_operation + +-- All Specials are in error +ddand780 and -Inf -Inf -> NaN Invalid_operation +ddand781 and -Inf -1000 -> NaN Invalid_operation +ddand782 and -Inf -1 -> NaN Invalid_operation +ddand783 and -Inf -0 -> NaN Invalid_operation +ddand784 and -Inf 0 -> NaN Invalid_operation +ddand785 and -Inf 1 -> NaN Invalid_operation +ddand786 and -Inf 1000 -> NaN Invalid_operation +ddand787 and -1000 -Inf -> NaN Invalid_operation +ddand788 and -Inf -Inf -> NaN Invalid_operation +ddand789 and -1 -Inf -> NaN Invalid_operation +ddand790 and -0 -Inf -> NaN Invalid_operation +ddand791 and 0 -Inf -> NaN Invalid_operation +ddand792 and 1 -Inf -> NaN Invalid_operation +ddand793 and 1000 -Inf -> NaN Invalid_operation +ddand794 and Inf -Inf -> NaN Invalid_operation + +ddand800 and Inf -Inf -> NaN Invalid_operation +ddand801 and Inf -1000 -> NaN Invalid_operation +ddand802 and Inf -1 -> NaN Invalid_operation +ddand803 and Inf -0 -> NaN Invalid_operation +ddand804 and Inf 0 -> NaN Invalid_operation +ddand805 and Inf 1 -> NaN Invalid_operation +ddand806 and Inf 1000 -> NaN Invalid_operation +ddand807 and Inf Inf -> NaN Invalid_operation +ddand808 and -1000 Inf -> NaN Invalid_operation +ddand809 and -Inf Inf -> NaN Invalid_operation +ddand810 and -1 Inf -> NaN Invalid_operation +ddand811 and -0 Inf -> NaN Invalid_operation +ddand812 and 0 Inf -> NaN Invalid_operation +ddand813 and 1 Inf -> NaN Invalid_operation +ddand814 and 1000 Inf -> NaN Invalid_operation +ddand815 and Inf Inf -> NaN Invalid_operation + +ddand821 and NaN -Inf -> NaN Invalid_operation +ddand822 and NaN -1000 -> NaN Invalid_operation +ddand823 and NaN -1 -> NaN Invalid_operation +ddand824 and NaN -0 -> NaN Invalid_operation +ddand825 and NaN 0 -> NaN Invalid_operation +ddand826 and NaN 1 -> NaN Invalid_operation +ddand827 and NaN 1000 -> NaN Invalid_operation +ddand828 and NaN Inf -> NaN Invalid_operation +ddand829 and NaN NaN -> NaN Invalid_operation +ddand830 and -Inf NaN -> NaN Invalid_operation +ddand831 and -1000 NaN -> NaN Invalid_operation +ddand832 and -1 NaN -> NaN Invalid_operation +ddand833 and -0 NaN -> NaN Invalid_operation +ddand834 and 0 NaN -> NaN Invalid_operation +ddand835 and 1 NaN -> NaN Invalid_operation +ddand836 and 1000 NaN -> NaN Invalid_operation +ddand837 and Inf NaN -> NaN Invalid_operation + +ddand841 and sNaN -Inf -> NaN Invalid_operation +ddand842 and sNaN -1000 -> NaN Invalid_operation +ddand843 and sNaN -1 -> NaN Invalid_operation +ddand844 and sNaN -0 -> NaN Invalid_operation +ddand845 and sNaN 0 -> NaN Invalid_operation +ddand846 and sNaN 1 -> NaN Invalid_operation +ddand847 and sNaN 1000 -> NaN Invalid_operation +ddand848 and sNaN NaN -> NaN Invalid_operation +ddand849 and sNaN sNaN -> NaN Invalid_operation +ddand850 and NaN sNaN -> NaN Invalid_operation +ddand851 and -Inf sNaN -> NaN Invalid_operation +ddand852 and -1000 sNaN -> NaN Invalid_operation +ddand853 and -1 sNaN -> NaN Invalid_operation +ddand854 and -0 sNaN -> NaN Invalid_operation +ddand855 and 0 sNaN -> NaN Invalid_operation +ddand856 and 1 sNaN -> NaN Invalid_operation +ddand857 and 1000 sNaN -> NaN Invalid_operation +ddand858 and Inf sNaN -> NaN Invalid_operation +ddand859 and NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +ddand861 and NaN1 -Inf -> NaN Invalid_operation +ddand862 and +NaN2 -1000 -> NaN Invalid_operation +ddand863 and NaN3 1000 -> NaN Invalid_operation +ddand864 and NaN4 Inf -> NaN Invalid_operation +ddand865 and NaN5 +NaN6 -> NaN Invalid_operation +ddand866 and -Inf NaN7 -> NaN Invalid_operation +ddand867 and -1000 NaN8 -> NaN Invalid_operation +ddand868 and 1000 NaN9 -> NaN Invalid_operation +ddand869 and Inf +NaN10 -> NaN Invalid_operation +ddand871 and sNaN11 -Inf -> NaN Invalid_operation +ddand872 and sNaN12 -1000 -> NaN Invalid_operation +ddand873 and sNaN13 1000 -> NaN Invalid_operation +ddand874 and sNaN14 NaN17 -> NaN Invalid_operation +ddand875 and sNaN15 sNaN18 -> NaN Invalid_operation +ddand876 and NaN16 sNaN19 -> NaN Invalid_operation +ddand877 and -Inf +sNaN20 -> NaN Invalid_operation +ddand878 and -1000 sNaN21 -> NaN Invalid_operation +ddand879 and 1000 sNaN22 -> NaN Invalid_operation +ddand880 and Inf sNaN23 -> NaN Invalid_operation +ddand881 and +NaN25 +sNaN24 -> NaN Invalid_operation +ddand882 and -NaN26 NaN28 -> NaN Invalid_operation +ddand883 and -sNaN27 sNaN29 -> NaN Invalid_operation +ddand884 and 1000 -NaN30 -> NaN Invalid_operation +ddand885 and 1000 -sNaN31 -> NaN Invalid_operation Added: python/branches/release25-maint/Lib/test/decimaltestdata/ddBase.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/ddBase.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,1096 @@ +------------------------------------------------------------------------ +-- ddBase.decTest -- base decDouble <--> string conversions -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- This file tests base conversions from string to a decimal number +-- and back to a string (in Scientific form) + +-- Note that unlike other operations the operand is subject to rounding +-- to conform to emax and precision settings (that is, numbers will +-- conform to rules and exponent will be in permitted range). The +-- 'left hand side', therefore, may have numbers that cannot be +-- represented in a decDouble. Some testcases go to the limit of the +-- next-wider format, and hence these testcases may also be used to +-- test narrowing and widening operations. + +precision: 16 +maxExponent: 384 +minExponent: -383 +extended: 1 +clamp: 1 +rounding: half_even + +ddbas001 toSci 0 -> 0 +ddbas002 toSci 1 -> 1 +ddbas003 toSci 1.0 -> 1.0 +ddbas004 toSci 1.00 -> 1.00 +ddbas005 toSci 10 -> 10 +ddbas006 toSci 1000 -> 1000 +ddbas007 toSci 10.0 -> 10.0 +ddbas008 toSci 10.1 -> 10.1 +ddbas009 toSci 10.4 -> 10.4 +ddbas010 toSci 10.5 -> 10.5 +ddbas011 toSci 10.6 -> 10.6 +ddbas012 toSci 10.9 -> 10.9 +ddbas013 toSci 11.0 -> 11.0 +ddbas014 toSci 1.234 -> 1.234 +ddbas015 toSci 0.123 -> 0.123 +ddbas016 toSci 0.012 -> 0.012 +ddbas017 toSci -0 -> -0 +ddbas018 toSci -0.0 -> -0.0 +ddbas019 toSci -00.00 -> -0.00 + +ddbas021 toSci -1 -> -1 +ddbas022 toSci -1.0 -> -1.0 +ddbas023 toSci -0.1 -> -0.1 +ddbas024 toSci -9.1 -> -9.1 +ddbas025 toSci -9.11 -> -9.11 +ddbas026 toSci -9.119 -> -9.119 +ddbas027 toSci -9.999 -> -9.999 + +ddbas030 toSci '123456789.123456' -> '123456789.123456' +ddbas031 toSci '123456789.000000' -> '123456789.000000' +ddbas032 toSci '123456789123456' -> '123456789123456' +ddbas033 toSci '0.0000123456789' -> '0.0000123456789' +ddbas034 toSci '0.00000123456789' -> '0.00000123456789' +ddbas035 toSci '0.000000123456789' -> '1.23456789E-7' +ddbas036 toSci '0.0000000123456789' -> '1.23456789E-8' + +ddbas037 toSci '0.123456789012344' -> '0.123456789012344' +ddbas038 toSci '0.123456789012345' -> '0.123456789012345' + +-- test finite bounds (Negs of, then 0, Ntiny, Nmin, other, Nmax) +ddbsn001 toSci -9.999999999999999E+384 -> -9.999999999999999E+384 +ddbsn002 toSci -1E-383 -> -1E-383 +ddbsn003 toSci -1E-398 -> -1E-398 Subnormal +ddbsn004 toSci -0 -> -0 +ddbsn005 toSci +0 -> 0 +ddbsn006 toSci +1E-398 -> 1E-398 Subnormal +ddbsn007 toSci +1E-383 -> 1E-383 +ddbsn008 toSci +9.999999999999999E+384 -> 9.999999999999999E+384 + +-- String [many more examples are implicitly tested elsewhere] +-- strings without E cannot generate E in result +ddbas040 toSci "12" -> '12' +ddbas041 toSci "-76" -> '-76' +ddbas042 toSci "12.76" -> '12.76' +ddbas043 toSci "+12.76" -> '12.76' +ddbas044 toSci "012.76" -> '12.76' +ddbas045 toSci "+0.003" -> '0.003' +ddbas046 toSci "17." -> '17' +ddbas047 toSci ".5" -> '0.5' +ddbas048 toSci "044" -> '44' +ddbas049 toSci "0044" -> '44' +ddbas050 toSci "0.0005" -> '0.0005' +ddbas051 toSci "00.00005" -> '0.00005' +ddbas052 toSci "0.000005" -> '0.000005' +ddbas053 toSci "0.0000050" -> '0.0000050' +ddbas054 toSci "0.0000005" -> '5E-7' +ddbas055 toSci "0.00000005" -> '5E-8' +ddbas056 toSci "12345678.543210" -> '12345678.543210' +ddbas057 toSci "2345678.543210" -> '2345678.543210' +ddbas058 toSci "345678.543210" -> '345678.543210' +ddbas059 toSci "0345678.54321" -> '345678.54321' +ddbas060 toSci "345678.5432" -> '345678.5432' +ddbas061 toSci "+345678.5432" -> '345678.5432' +ddbas062 toSci "+0345678.5432" -> '345678.5432' +ddbas063 toSci "+00345678.5432" -> '345678.5432' +ddbas064 toSci "-345678.5432" -> '-345678.5432' +ddbas065 toSci "-0345678.5432" -> '-345678.5432' +ddbas066 toSci "-00345678.5432" -> '-345678.5432' +-- examples +ddbas067 toSci "5E-6" -> '0.000005' +ddbas068 toSci "50E-7" -> '0.0000050' +ddbas069 toSci "5E-7" -> '5E-7' + +-- [No exotics as no Unicode] + +-- rounded with dots in all (including edge) places +ddbas071 toSci .1234567890123456123 -> 0.1234567890123456 Inexact Rounded +ddbas072 toSci 1.234567890123456123 -> 1.234567890123456 Inexact Rounded +ddbas073 toSci 12.34567890123456123 -> 12.34567890123456 Inexact Rounded +ddbas074 toSci 123.4567890123456123 -> 123.4567890123456 Inexact Rounded +ddbas075 toSci 1234.567890123456123 -> 1234.567890123456 Inexact Rounded +ddbas076 toSci 12345.67890123456123 -> 12345.67890123456 Inexact Rounded +ddbas077 toSci 123456.7890123456123 -> 123456.7890123456 Inexact Rounded +ddbas078 toSci 1234567.890123456123 -> 1234567.890123456 Inexact Rounded +ddbas079 toSci 12345678.90123456123 -> 12345678.90123456 Inexact Rounded +ddbas080 toSci 123456789.0123456123 -> 123456789.0123456 Inexact Rounded +ddbas081 toSci 1234567890.123456123 -> 1234567890.123456 Inexact Rounded +ddbas082 toSci 12345678901.23456123 -> 12345678901.23456 Inexact Rounded +ddbas083 toSci 123456789012.3456123 -> 123456789012.3456 Inexact Rounded +ddbas084 toSci 1234567890123.456123 -> 1234567890123.456 Inexact Rounded +ddbas085 toSci 12345678901234.56123 -> 12345678901234.56 Inexact Rounded +ddbas086 toSci 123456789012345.6123 -> 123456789012345.6 Inexact Rounded +ddbas087 toSci 1234567890123456.123 -> 1234567890123456 Inexact Rounded +ddbas088 toSci 12345678901234561.23 -> 1.234567890123456E+16 Inexact Rounded +ddbas089 toSci 123456789012345612.3 -> 1.234567890123456E+17 Inexact Rounded +ddbas090 toSci 1234567890123456123. -> 1.234567890123456E+18 Inexact Rounded + + +-- Numbers with E +ddbas130 toSci "0.000E-1" -> '0.0000' +ddbas131 toSci "0.000E-2" -> '0.00000' +ddbas132 toSci "0.000E-3" -> '0.000000' +ddbas133 toSci "0.000E-4" -> '0E-7' +ddbas134 toSci "0.00E-2" -> '0.0000' +ddbas135 toSci "0.00E-3" -> '0.00000' +ddbas136 toSci "0.00E-4" -> '0.000000' +ddbas137 toSci "0.00E-5" -> '0E-7' +ddbas138 toSci "+0E+9" -> '0E+9' +ddbas139 toSci "-0E+9" -> '-0E+9' +ddbas140 toSci "1E+9" -> '1E+9' +ddbas141 toSci "1e+09" -> '1E+9' +ddbas142 toSci "1E+90" -> '1E+90' +ddbas143 toSci "+1E+009" -> '1E+9' +ddbas144 toSci "0E+9" -> '0E+9' +ddbas145 toSci "1E+9" -> '1E+9' +ddbas146 toSci "1E+09" -> '1E+9' +ddbas147 toSci "1e+90" -> '1E+90' +ddbas148 toSci "1E+009" -> '1E+9' +ddbas149 toSci "000E+9" -> '0E+9' +ddbas150 toSci "1E9" -> '1E+9' +ddbas151 toSci "1e09" -> '1E+9' +ddbas152 toSci "1E90" -> '1E+90' +ddbas153 toSci "1E009" -> '1E+9' +ddbas154 toSci "0E9" -> '0E+9' +ddbas155 toSci "0.000e+0" -> '0.000' +ddbas156 toSci "0.000E-1" -> '0.0000' +ddbas157 toSci "4E+9" -> '4E+9' +ddbas158 toSci "44E+9" -> '4.4E+10' +ddbas159 toSci "0.73e-7" -> '7.3E-8' +ddbas160 toSci "00E+9" -> '0E+9' +ddbas161 toSci "00E-9" -> '0E-9' +ddbas162 toSci "10E+9" -> '1.0E+10' +ddbas163 toSci "10E+09" -> '1.0E+10' +ddbas164 toSci "10e+90" -> '1.0E+91' +ddbas165 toSci "10E+009" -> '1.0E+10' +ddbas166 toSci "100e+9" -> '1.00E+11' +ddbas167 toSci "100e+09" -> '1.00E+11' +ddbas168 toSci "100E+90" -> '1.00E+92' +ddbas169 toSci "100e+009" -> '1.00E+11' + +ddbas170 toSci "1.265" -> '1.265' +ddbas171 toSci "1.265E-20" -> '1.265E-20' +ddbas172 toSci "1.265E-8" -> '1.265E-8' +ddbas173 toSci "1.265E-4" -> '0.0001265' +ddbas174 toSci "1.265E-3" -> '0.001265' +ddbas175 toSci "1.265E-2" -> '0.01265' +ddbas176 toSci "1.265E-1" -> '0.1265' +ddbas177 toSci "1.265E-0" -> '1.265' +ddbas178 toSci "1.265E+1" -> '12.65' +ddbas179 toSci "1.265E+2" -> '126.5' +ddbas180 toSci "1.265E+3" -> '1265' +ddbas181 toSci "1.265E+4" -> '1.265E+4' +ddbas182 toSci "1.265E+8" -> '1.265E+8' +ddbas183 toSci "1.265E+20" -> '1.265E+20' + +ddbas190 toSci "12.65" -> '12.65' +ddbas191 toSci "12.65E-20" -> '1.265E-19' +ddbas192 toSci "12.65E-8" -> '1.265E-7' +ddbas193 toSci "12.65E-4" -> '0.001265' +ddbas194 toSci "12.65E-3" -> '0.01265' +ddbas195 toSci "12.65E-2" -> '0.1265' +ddbas196 toSci "12.65E-1" -> '1.265' +ddbas197 toSci "12.65E-0" -> '12.65' +ddbas198 toSci "12.65E+1" -> '126.5' +ddbas199 toSci "12.65E+2" -> '1265' +ddbas200 toSci "12.65E+3" -> '1.265E+4' +ddbas201 toSci "12.65E+4" -> '1.265E+5' +ddbas202 toSci "12.65E+8" -> '1.265E+9' +ddbas203 toSci "12.65E+20" -> '1.265E+21' + +ddbas210 toSci "126.5" -> '126.5' +ddbas211 toSci "126.5E-20" -> '1.265E-18' +ddbas212 toSci "126.5E-8" -> '0.000001265' +ddbas213 toSci "126.5E-4" -> '0.01265' +ddbas214 toSci "126.5E-3" -> '0.1265' +ddbas215 toSci "126.5E-2" -> '1.265' +ddbas216 toSci "126.5E-1" -> '12.65' +ddbas217 toSci "126.5E-0" -> '126.5' +ddbas218 toSci "126.5E+1" -> '1265' +ddbas219 toSci "126.5E+2" -> '1.265E+4' +ddbas220 toSci "126.5E+3" -> '1.265E+5' +ddbas221 toSci "126.5E+4" -> '1.265E+6' +ddbas222 toSci "126.5E+8" -> '1.265E+10' +ddbas223 toSci "126.5E+20" -> '1.265E+22' + +ddbas230 toSci "1265" -> '1265' +ddbas231 toSci "1265E-20" -> '1.265E-17' +ddbas232 toSci "1265E-8" -> '0.00001265' +ddbas233 toSci "1265E-4" -> '0.1265' +ddbas234 toSci "1265E-3" -> '1.265' +ddbas235 toSci "1265E-2" -> '12.65' +ddbas236 toSci "1265E-1" -> '126.5' +ddbas237 toSci "1265E-0" -> '1265' +ddbas238 toSci "1265E+1" -> '1.265E+4' +ddbas239 toSci "1265E+2" -> '1.265E+5' +ddbas240 toSci "1265E+3" -> '1.265E+6' +ddbas241 toSci "1265E+4" -> '1.265E+7' +ddbas242 toSci "1265E+8" -> '1.265E+11' +ddbas243 toSci "1265E+20" -> '1.265E+23' +ddbas244 toSci "1265E-9" -> '0.000001265' +ddbas245 toSci "1265E-10" -> '1.265E-7' +ddbas246 toSci "1265E-11" -> '1.265E-8' +ddbas247 toSci "1265E-12" -> '1.265E-9' + +ddbas250 toSci "0.1265" -> '0.1265' +ddbas251 toSci "0.1265E-20" -> '1.265E-21' +ddbas252 toSci "0.1265E-8" -> '1.265E-9' +ddbas253 toSci "0.1265E-4" -> '0.00001265' +ddbas254 toSci "0.1265E-3" -> '0.0001265' +ddbas255 toSci "0.1265E-2" -> '0.001265' +ddbas256 toSci "0.1265E-1" -> '0.01265' +ddbas257 toSci "0.1265E-0" -> '0.1265' +ddbas258 toSci "0.1265E+1" -> '1.265' +ddbas259 toSci "0.1265E+2" -> '12.65' +ddbas260 toSci "0.1265E+3" -> '126.5' +ddbas261 toSci "0.1265E+4" -> '1265' +ddbas262 toSci "0.1265E+8" -> '1.265E+7' +ddbas263 toSci "0.1265E+20" -> '1.265E+19' + +-- some more negative zeros [systematic tests below] +ddbas290 toSci "-0.000E-1" -> '-0.0000' +ddbas291 toSci "-0.000E-2" -> '-0.00000' +ddbas292 toSci "-0.000E-3" -> '-0.000000' +ddbas293 toSci "-0.000E-4" -> '-0E-7' +ddbas294 toSci "-0.00E-2" -> '-0.0000' +ddbas295 toSci "-0.00E-3" -> '-0.00000' +ddbas296 toSci "-0.0E-2" -> '-0.000' +ddbas297 toSci "-0.0E-3" -> '-0.0000' +ddbas298 toSci "-0E-2" -> '-0.00' +ddbas299 toSci "-0E-3" -> '-0.000' + +-- Engineering notation tests +ddbas301 toSci 10e12 -> 1.0E+13 +ddbas302 toEng 10e12 -> 10E+12 +ddbas303 toSci 10e11 -> 1.0E+12 +ddbas304 toEng 10e11 -> 1.0E+12 +ddbas305 toSci 10e10 -> 1.0E+11 +ddbas306 toEng 10e10 -> 100E+9 +ddbas307 toSci 10e9 -> 1.0E+10 +ddbas308 toEng 10e9 -> 10E+9 +ddbas309 toSci 10e8 -> 1.0E+9 +ddbas310 toEng 10e8 -> 1.0E+9 +ddbas311 toSci 10e7 -> 1.0E+8 +ddbas312 toEng 10e7 -> 100E+6 +ddbas313 toSci 10e6 -> 1.0E+7 +ddbas314 toEng 10e6 -> 10E+6 +ddbas315 toSci 10e5 -> 1.0E+6 +ddbas316 toEng 10e5 -> 1.0E+6 +ddbas317 toSci 10e4 -> 1.0E+5 +ddbas318 toEng 10e4 -> 100E+3 +ddbas319 toSci 10e3 -> 1.0E+4 +ddbas320 toEng 10e3 -> 10E+3 +ddbas321 toSci 10e2 -> 1.0E+3 +ddbas322 toEng 10e2 -> 1.0E+3 +ddbas323 toSci 10e1 -> 1.0E+2 +ddbas324 toEng 10e1 -> 100 +ddbas325 toSci 10e0 -> 10 +ddbas326 toEng 10e0 -> 10 +ddbas327 toSci 10e-1 -> 1.0 +ddbas328 toEng 10e-1 -> 1.0 +ddbas329 toSci 10e-2 -> 0.10 +ddbas330 toEng 10e-2 -> 0.10 +ddbas331 toSci 10e-3 -> 0.010 +ddbas332 toEng 10e-3 -> 0.010 +ddbas333 toSci 10e-4 -> 0.0010 +ddbas334 toEng 10e-4 -> 0.0010 +ddbas335 toSci 10e-5 -> 0.00010 +ddbas336 toEng 10e-5 -> 0.00010 +ddbas337 toSci 10e-6 -> 0.000010 +ddbas338 toEng 10e-6 -> 0.000010 +ddbas339 toSci 10e-7 -> 0.0000010 +ddbas340 toEng 10e-7 -> 0.0000010 +ddbas341 toSci 10e-8 -> 1.0E-7 +ddbas342 toEng 10e-8 -> 100E-9 +ddbas343 toSci 10e-9 -> 1.0E-8 +ddbas344 toEng 10e-9 -> 10E-9 +ddbas345 toSci 10e-10 -> 1.0E-9 +ddbas346 toEng 10e-10 -> 1.0E-9 +ddbas347 toSci 10e-11 -> 1.0E-10 +ddbas348 toEng 10e-11 -> 100E-12 +ddbas349 toSci 10e-12 -> 1.0E-11 +ddbas350 toEng 10e-12 -> 10E-12 +ddbas351 toSci 10e-13 -> 1.0E-12 +ddbas352 toEng 10e-13 -> 1.0E-12 + +ddbas361 toSci 7E12 -> 7E+12 +ddbas362 toEng 7E12 -> 7E+12 +ddbas363 toSci 7E11 -> 7E+11 +ddbas364 toEng 7E11 -> 700E+9 +ddbas365 toSci 7E10 -> 7E+10 +ddbas366 toEng 7E10 -> 70E+9 +ddbas367 toSci 7E9 -> 7E+9 +ddbas368 toEng 7E9 -> 7E+9 +ddbas369 toSci 7E8 -> 7E+8 +ddbas370 toEng 7E8 -> 700E+6 +ddbas371 toSci 7E7 -> 7E+7 +ddbas372 toEng 7E7 -> 70E+6 +ddbas373 toSci 7E6 -> 7E+6 +ddbas374 toEng 7E6 -> 7E+6 +ddbas375 toSci 7E5 -> 7E+5 +ddbas376 toEng 7E5 -> 700E+3 +ddbas377 toSci 7E4 -> 7E+4 +ddbas378 toEng 7E4 -> 70E+3 +ddbas379 toSci 7E3 -> 7E+3 +ddbas380 toEng 7E3 -> 7E+3 +ddbas381 toSci 7E2 -> 7E+2 +ddbas382 toEng 7E2 -> 700 +ddbas383 toSci 7E1 -> 7E+1 +ddbas384 toEng 7E1 -> 70 +ddbas385 toSci 7E0 -> 7 +ddbas386 toEng 7E0 -> 7 +ddbas387 toSci 7E-1 -> 0.7 +ddbas388 toEng 7E-1 -> 0.7 +ddbas389 toSci 7E-2 -> 0.07 +ddbas390 toEng 7E-2 -> 0.07 +ddbas391 toSci 7E-3 -> 0.007 +ddbas392 toEng 7E-3 -> 0.007 +ddbas393 toSci 7E-4 -> 0.0007 +ddbas394 toEng 7E-4 -> 0.0007 +ddbas395 toSci 7E-5 -> 0.00007 +ddbas396 toEng 7E-5 -> 0.00007 +ddbas397 toSci 7E-6 -> 0.000007 +ddbas398 toEng 7E-6 -> 0.000007 +ddbas399 toSci 7E-7 -> 7E-7 +ddbas400 toEng 7E-7 -> 700E-9 +ddbas401 toSci 7E-8 -> 7E-8 +ddbas402 toEng 7E-8 -> 70E-9 +ddbas403 toSci 7E-9 -> 7E-9 +ddbas404 toEng 7E-9 -> 7E-9 +ddbas405 toSci 7E-10 -> 7E-10 +ddbas406 toEng 7E-10 -> 700E-12 +ddbas407 toSci 7E-11 -> 7E-11 +ddbas408 toEng 7E-11 -> 70E-12 +ddbas409 toSci 7E-12 -> 7E-12 +ddbas410 toEng 7E-12 -> 7E-12 +ddbas411 toSci 7E-13 -> 7E-13 +ddbas412 toEng 7E-13 -> 700E-15 + +-- Exacts remain exact up to precision .. +rounding: half_up +ddbas420 toSci 100 -> 100 +ddbas421 toEng 100 -> 100 +ddbas422 toSci 1000 -> 1000 +ddbas423 toEng 1000 -> 1000 +ddbas424 toSci 999.9 -> 999.9 +ddbas425 toEng 999.9 -> 999.9 +ddbas426 toSci 1000.0 -> 1000.0 +ddbas427 toEng 1000.0 -> 1000.0 +ddbas428 toSci 1000.1 -> 1000.1 +ddbas429 toEng 1000.1 -> 1000.1 +ddbas430 toSci 10000 -> 10000 +ddbas431 toEng 10000 -> 10000 +ddbas432 toSci 100000 -> 100000 +ddbas433 toEng 100000 -> 100000 +ddbas434 toSci 1000000 -> 1000000 +ddbas435 toEng 1000000 -> 1000000 +ddbas436 toSci 10000000 -> 10000000 +ddbas437 toEng 10000000 -> 10000000 +ddbas438 toSci 100000000 -> 100000000 +ddbas439 toEng 1000000000000000 -> 1000000000000000 +ddbas440 toSci 10000000000000000 -> 1.000000000000000E+16 Rounded +ddbas441 toEng 10000000000000000 -> 10.00000000000000E+15 Rounded +ddbas442 toSci 10000000000000001 -> 1.000000000000000E+16 Rounded Inexact +ddbas443 toEng 10000000000000001 -> 10.00000000000000E+15 Rounded Inexact +ddbas444 toSci 10000000000000003 -> 1.000000000000000E+16 Rounded Inexact +ddbas445 toEng 10000000000000003 -> 10.00000000000000E+15 Rounded Inexact +ddbas446 toSci 10000000000000005 -> 1.000000000000001E+16 Rounded Inexact +ddbas447 toEng 10000000000000005 -> 10.00000000000001E+15 Rounded Inexact +ddbas448 toSci 100000000000000050 -> 1.000000000000001E+17 Rounded Inexact +ddbas449 toEng 100000000000000050 -> 100.0000000000001E+15 Rounded Inexact +ddbas450 toSci 10000000000000009 -> 1.000000000000001E+16 Rounded Inexact +ddbas451 toEng 10000000000000009 -> 10.00000000000001E+15 Rounded Inexact +ddbas452 toSci 100000000000000000 -> 1.000000000000000E+17 Rounded +ddbas453 toEng 100000000000000000 -> 100.0000000000000E+15 Rounded +ddbas454 toSci 100000000000000003 -> 1.000000000000000E+17 Rounded Inexact +ddbas455 toEng 100000000000000003 -> 100.0000000000000E+15 Rounded Inexact +ddbas456 toSci 100000000000000005 -> 1.000000000000000E+17 Rounded Inexact +ddbas457 toEng 100000000000000005 -> 100.0000000000000E+15 Rounded Inexact +ddbas458 toSci 100000000000000009 -> 1.000000000000000E+17 Rounded Inexact +ddbas459 toEng 100000000000000009 -> 100.0000000000000E+15 Rounded Inexact +ddbas460 toSci 1000000000000000000 -> 1.000000000000000E+18 Rounded +ddbas461 toEng 1000000000000000000 -> 1.000000000000000E+18 Rounded +ddbas462 toSci 1000000000000000300 -> 1.000000000000000E+18 Rounded Inexact +ddbas463 toEng 1000000000000000300 -> 1.000000000000000E+18 Rounded Inexact +ddbas464 toSci 1000000000000000500 -> 1.000000000000001E+18 Rounded Inexact +ddbas465 toEng 1000000000000000500 -> 1.000000000000001E+18 Rounded Inexact +ddbas466 toSci 1000000000000000900 -> 1.000000000000001E+18 Rounded Inexact +ddbas467 toEng 1000000000000000900 -> 1.000000000000001E+18 Rounded Inexact +ddbas468 toSci 10000000000000000000 -> 1.000000000000000E+19 Rounded +ddbas469 toEng 10000000000000000000 -> 10.00000000000000E+18 Rounded +ddbas470 toSci 10000000000000003000 -> 1.000000000000000E+19 Rounded Inexact +ddbas471 toEng 10000000000000003000 -> 10.00000000000000E+18 Rounded Inexact +ddbas472 toSci 10000000000000005000 -> 1.000000000000001E+19 Rounded Inexact +ddbas473 toEng 10000000000000005000 -> 10.00000000000001E+18 Rounded Inexact +ddbas474 toSci 10000000000000009000 -> 1.000000000000001E+19 Rounded Inexact +ddbas475 toEng 10000000000000009000 -> 10.00000000000001E+18 Rounded Inexact + +-- check rounding modes heeded +rounding: ceiling +ddbsr401 toSci 1.1111111111123450 -> 1.111111111112345 Rounded +ddbsr402 toSci 1.11111111111234549 -> 1.111111111112346 Rounded Inexact +ddbsr403 toSci 1.11111111111234550 -> 1.111111111112346 Rounded Inexact +ddbsr404 toSci 1.11111111111234551 -> 1.111111111112346 Rounded Inexact +rounding: up +ddbsr405 toSci 1.1111111111123450 -> 1.111111111112345 Rounded +ddbsr406 toSci 1.11111111111234549 -> 1.111111111112346 Rounded Inexact +ddbsr407 toSci 1.11111111111234550 -> 1.111111111112346 Rounded Inexact +ddbsr408 toSci 1.11111111111234551 -> 1.111111111112346 Rounded Inexact +rounding: floor +ddbsr410 toSci 1.1111111111123450 -> 1.111111111112345 Rounded +ddbsr411 toSci 1.11111111111234549 -> 1.111111111112345 Rounded Inexact +ddbsr412 toSci 1.11111111111234550 -> 1.111111111112345 Rounded Inexact +ddbsr413 toSci 1.11111111111234551 -> 1.111111111112345 Rounded Inexact +rounding: half_down +ddbsr415 toSci 1.1111111111123450 -> 1.111111111112345 Rounded +ddbsr416 toSci 1.11111111111234549 -> 1.111111111112345 Rounded Inexact +ddbsr417 toSci 1.11111111111234550 -> 1.111111111112345 Rounded Inexact +ddbsr418 toSci 1.11111111111234650 -> 1.111111111112346 Rounded Inexact +ddbsr419 toSci 1.11111111111234551 -> 1.111111111112346 Rounded Inexact +rounding: half_even +ddbsr421 toSci 1.1111111111123450 -> 1.111111111112345 Rounded +ddbsr422 toSci 1.11111111111234549 -> 1.111111111112345 Rounded Inexact +ddbsr423 toSci 1.11111111111234550 -> 1.111111111112346 Rounded Inexact +ddbsr424 toSci 1.11111111111234650 -> 1.111111111112346 Rounded Inexact +ddbsr425 toSci 1.11111111111234551 -> 1.111111111112346 Rounded Inexact +rounding: down +ddbsr426 toSci 1.1111111111123450 -> 1.111111111112345 Rounded +ddbsr427 toSci 1.11111111111234549 -> 1.111111111112345 Rounded Inexact +ddbsr428 toSci 1.11111111111234550 -> 1.111111111112345 Rounded Inexact +ddbsr429 toSci 1.11111111111234551 -> 1.111111111112345 Rounded Inexact +rounding: half_up +ddbsr431 toSci 1.1111111111123450 -> 1.111111111112345 Rounded +ddbsr432 toSci 1.11111111111234549 -> 1.111111111112345 Rounded Inexact +ddbsr433 toSci 1.11111111111234550 -> 1.111111111112346 Rounded Inexact +ddbsr434 toSci 1.11111111111234650 -> 1.111111111112347 Rounded Inexact +ddbsr435 toSci 1.11111111111234551 -> 1.111111111112346 Rounded Inexact +-- negatives +rounding: ceiling +ddbsr501 toSci -1.1111111111123450 -> -1.111111111112345 Rounded +ddbsr502 toSci -1.11111111111234549 -> -1.111111111112345 Rounded Inexact +ddbsr503 toSci -1.11111111111234550 -> -1.111111111112345 Rounded Inexact +ddbsr504 toSci -1.11111111111234551 -> -1.111111111112345 Rounded Inexact +rounding: up +ddbsr505 toSci -1.1111111111123450 -> -1.111111111112345 Rounded +ddbsr506 toSci -1.11111111111234549 -> -1.111111111112346 Rounded Inexact +ddbsr507 toSci -1.11111111111234550 -> -1.111111111112346 Rounded Inexact +ddbsr508 toSci -1.11111111111234551 -> -1.111111111112346 Rounded Inexact +rounding: floor +ddbsr510 toSci -1.1111111111123450 -> -1.111111111112345 Rounded +ddbsr511 toSci -1.11111111111234549 -> -1.111111111112346 Rounded Inexact +ddbsr512 toSci -1.11111111111234550 -> -1.111111111112346 Rounded Inexact +ddbsr513 toSci -1.11111111111234551 -> -1.111111111112346 Rounded Inexact +rounding: half_down +ddbsr515 toSci -1.1111111111123450 -> -1.111111111112345 Rounded +ddbsr516 toSci -1.11111111111234549 -> -1.111111111112345 Rounded Inexact +ddbsr517 toSci -1.11111111111234550 -> -1.111111111112345 Rounded Inexact +ddbsr518 toSci -1.11111111111234650 -> -1.111111111112346 Rounded Inexact +ddbsr519 toSci -1.11111111111234551 -> -1.111111111112346 Rounded Inexact +rounding: half_even +ddbsr521 toSci -1.1111111111123450 -> -1.111111111112345 Rounded +ddbsr522 toSci -1.11111111111234549 -> -1.111111111112345 Rounded Inexact +ddbsr523 toSci -1.11111111111234550 -> -1.111111111112346 Rounded Inexact +ddbsr524 toSci -1.11111111111234650 -> -1.111111111112346 Rounded Inexact +ddbsr525 toSci -1.11111111111234551 -> -1.111111111112346 Rounded Inexact +rounding: down +ddbsr526 toSci -1.1111111111123450 -> -1.111111111112345 Rounded +ddbsr527 toSci -1.11111111111234549 -> -1.111111111112345 Rounded Inexact +ddbsr528 toSci -1.11111111111234550 -> -1.111111111112345 Rounded Inexact +ddbsr529 toSci -1.11111111111234551 -> -1.111111111112345 Rounded Inexact +rounding: half_up +ddbsr531 toSci -1.1111111111123450 -> -1.111111111112345 Rounded +ddbsr532 toSci -1.11111111111234549 -> -1.111111111112345 Rounded Inexact +ddbsr533 toSci -1.11111111111234550 -> -1.111111111112346 Rounded Inexact +ddbsr534 toSci -1.11111111111234650 -> -1.111111111112347 Rounded Inexact +ddbsr535 toSci -1.11111111111234551 -> -1.111111111112346 Rounded Inexact + +rounding: half_even + +-- The 'baddies' tests from DiagBigDecimal, plus some new ones +ddbas500 toSci '1..2' -> NaN Conversion_syntax +ddbas501 toSci '.' -> NaN Conversion_syntax +ddbas502 toSci '..' -> NaN Conversion_syntax +ddbas503 toSci '++1' -> NaN Conversion_syntax +ddbas504 toSci '--1' -> NaN Conversion_syntax +ddbas505 toSci '-+1' -> NaN Conversion_syntax +ddbas506 toSci '+-1' -> NaN Conversion_syntax +ddbas507 toSci '12e' -> NaN Conversion_syntax +ddbas508 toSci '12e++' -> NaN Conversion_syntax +ddbas509 toSci '12f4' -> NaN Conversion_syntax +ddbas510 toSci ' +1' -> NaN Conversion_syntax +ddbas511 toSci '+ 1' -> NaN Conversion_syntax +ddbas512 toSci '12 ' -> NaN Conversion_syntax +ddbas513 toSci ' + 1' -> NaN Conversion_syntax +ddbas514 toSci ' - 1 ' -> NaN Conversion_syntax +ddbas515 toSci 'x' -> NaN Conversion_syntax +ddbas516 toSci '-1-' -> NaN Conversion_syntax +ddbas517 toSci '12-' -> NaN Conversion_syntax +ddbas518 toSci '3+' -> NaN Conversion_syntax +ddbas519 toSci '' -> NaN Conversion_syntax +ddbas520 toSci '1e-' -> NaN Conversion_syntax +ddbas521 toSci '7e99999a' -> NaN Conversion_syntax +ddbas522 toSci '7e123567890x' -> NaN Conversion_syntax +ddbas523 toSci '7e12356789012x' -> NaN Conversion_syntax +ddbas524 toSci '' -> NaN Conversion_syntax +ddbas525 toSci 'e100' -> NaN Conversion_syntax +ddbas526 toSci '\u0e5a' -> NaN Conversion_syntax +ddbas527 toSci '\u0b65' -> NaN Conversion_syntax +ddbas528 toSci '123,65' -> NaN Conversion_syntax +ddbas529 toSci '1.34.5' -> NaN Conversion_syntax +ddbas530 toSci '.123.5' -> NaN Conversion_syntax +ddbas531 toSci '01.35.' -> NaN Conversion_syntax +ddbas532 toSci '01.35-' -> NaN Conversion_syntax +ddbas533 toSci '0000..' -> NaN Conversion_syntax +ddbas534 toSci '.0000.' -> NaN Conversion_syntax +ddbas535 toSci '00..00' -> NaN Conversion_syntax +ddbas536 toSci '111e*123' -> NaN Conversion_syntax +ddbas537 toSci '111e123-' -> NaN Conversion_syntax +ddbas538 toSci '111e+12+' -> NaN Conversion_syntax +ddbas539 toSci '111e1-3-' -> NaN Conversion_syntax +ddbas540 toSci '111e1*23' -> NaN Conversion_syntax +ddbas541 toSci '111e1e+3' -> NaN Conversion_syntax +ddbas542 toSci '1e1.0' -> NaN Conversion_syntax +ddbas543 toSci '1e123e' -> NaN Conversion_syntax +ddbas544 toSci 'ten' -> NaN Conversion_syntax +ddbas545 toSci 'ONE' -> NaN Conversion_syntax +ddbas546 toSci '1e.1' -> NaN Conversion_syntax +ddbas547 toSci '1e1.' -> NaN Conversion_syntax +ddbas548 toSci '1ee' -> NaN Conversion_syntax +ddbas549 toSci 'e+1' -> NaN Conversion_syntax +ddbas550 toSci '1.23.4' -> NaN Conversion_syntax +ddbas551 toSci '1.2.1' -> NaN Conversion_syntax +ddbas552 toSci '1E+1.2' -> NaN Conversion_syntax +ddbas553 toSci '1E+1.2.3' -> NaN Conversion_syntax +ddbas554 toSci '1E++1' -> NaN Conversion_syntax +ddbas555 toSci '1E--1' -> NaN Conversion_syntax +ddbas556 toSci '1E+-1' -> NaN Conversion_syntax +ddbas557 toSci '1E-+1' -> NaN Conversion_syntax +ddbas558 toSci '1E''1' -> NaN Conversion_syntax +ddbas559 toSci "1E""1" -> NaN Conversion_syntax +ddbas560 toSci "1E""""" -> NaN Conversion_syntax +-- Near-specials +ddbas561 toSci "qNaN" -> NaN Conversion_syntax +ddbas562 toSci "NaNq" -> NaN Conversion_syntax +ddbas563 toSci "NaNs" -> NaN Conversion_syntax +ddbas564 toSci "Infi" -> NaN Conversion_syntax +ddbas565 toSci "Infin" -> NaN Conversion_syntax +ddbas566 toSci "Infini" -> NaN Conversion_syntax +ddbas567 toSci "Infinit" -> NaN Conversion_syntax +ddbas568 toSci "-Infinit" -> NaN Conversion_syntax +ddbas569 toSci "0Inf" -> NaN Conversion_syntax +ddbas570 toSci "9Inf" -> NaN Conversion_syntax +ddbas571 toSci "-0Inf" -> NaN Conversion_syntax +ddbas572 toSci "-9Inf" -> NaN Conversion_syntax +ddbas573 toSci "-sNa" -> NaN Conversion_syntax +ddbas574 toSci "xNaN" -> NaN Conversion_syntax +ddbas575 toSci "0sNaN" -> NaN Conversion_syntax + +-- some baddies with dots and Es and dots and specials +ddbas576 toSci 'e+1' -> NaN Conversion_syntax +ddbas577 toSci '.e+1' -> NaN Conversion_syntax +ddbas578 toSci '+.e+1' -> NaN Conversion_syntax +ddbas579 toSci '-.e+' -> NaN Conversion_syntax +ddbas580 toSci '-.e' -> NaN Conversion_syntax +ddbas581 toSci 'E+1' -> NaN Conversion_syntax +ddbas582 toSci '.E+1' -> NaN Conversion_syntax +ddbas583 toSci '+.E+1' -> NaN Conversion_syntax +ddbas584 toSci '-.E+' -> NaN Conversion_syntax +ddbas585 toSci '-.E' -> NaN Conversion_syntax + +ddbas586 toSci '.NaN' -> NaN Conversion_syntax +ddbas587 toSci '-.NaN' -> NaN Conversion_syntax +ddbas588 toSci '+.sNaN' -> NaN Conversion_syntax +ddbas589 toSci '+.Inf' -> NaN Conversion_syntax +ddbas590 toSci '.Infinity' -> NaN Conversion_syntax + +-- Zeros +ddbas601 toSci 0.000000000 -> 0E-9 +ddbas602 toSci 0.00000000 -> 0E-8 +ddbas603 toSci 0.0000000 -> 0E-7 +ddbas604 toSci 0.000000 -> 0.000000 +ddbas605 toSci 0.00000 -> 0.00000 +ddbas606 toSci 0.0000 -> 0.0000 +ddbas607 toSci 0.000 -> 0.000 +ddbas608 toSci 0.00 -> 0.00 +ddbas609 toSci 0.0 -> 0.0 +ddbas610 toSci .0 -> 0.0 +ddbas611 toSci 0. -> 0 +ddbas612 toSci -.0 -> -0.0 +ddbas613 toSci -0. -> -0 +ddbas614 toSci -0.0 -> -0.0 +ddbas615 toSci -0.00 -> -0.00 +ddbas616 toSci -0.000 -> -0.000 +ddbas617 toSci -0.0000 -> -0.0000 +ddbas618 toSci -0.00000 -> -0.00000 +ddbas619 toSci -0.000000 -> -0.000000 +ddbas620 toSci -0.0000000 -> -0E-7 +ddbas621 toSci -0.00000000 -> -0E-8 +ddbas622 toSci -0.000000000 -> -0E-9 + +ddbas630 toSci 0.00E+0 -> 0.00 +ddbas631 toSci 0.00E+1 -> 0.0 +ddbas632 toSci 0.00E+2 -> 0 +ddbas633 toSci 0.00E+3 -> 0E+1 +ddbas634 toSci 0.00E+4 -> 0E+2 +ddbas635 toSci 0.00E+5 -> 0E+3 +ddbas636 toSci 0.00E+6 -> 0E+4 +ddbas637 toSci 0.00E+7 -> 0E+5 +ddbas638 toSci 0.00E+8 -> 0E+6 +ddbas639 toSci 0.00E+9 -> 0E+7 + +ddbas640 toSci 0.0E+0 -> 0.0 +ddbas641 toSci 0.0E+1 -> 0 +ddbas642 toSci 0.0E+2 -> 0E+1 +ddbas643 toSci 0.0E+3 -> 0E+2 +ddbas644 toSci 0.0E+4 -> 0E+3 +ddbas645 toSci 0.0E+5 -> 0E+4 +ddbas646 toSci 0.0E+6 -> 0E+5 +ddbas647 toSci 0.0E+7 -> 0E+6 +ddbas648 toSci 0.0E+8 -> 0E+7 +ddbas649 toSci 0.0E+9 -> 0E+8 + +ddbas650 toSci 0E+0 -> 0 +ddbas651 toSci 0E+1 -> 0E+1 +ddbas652 toSci 0E+2 -> 0E+2 +ddbas653 toSci 0E+3 -> 0E+3 +ddbas654 toSci 0E+4 -> 0E+4 +ddbas655 toSci 0E+5 -> 0E+5 +ddbas656 toSci 0E+6 -> 0E+6 +ddbas657 toSci 0E+7 -> 0E+7 +ddbas658 toSci 0E+8 -> 0E+8 +ddbas659 toSci 0E+9 -> 0E+9 + +ddbas660 toSci 0.0E-0 -> 0.0 +ddbas661 toSci 0.0E-1 -> 0.00 +ddbas662 toSci 0.0E-2 -> 0.000 +ddbas663 toSci 0.0E-3 -> 0.0000 +ddbas664 toSci 0.0E-4 -> 0.00000 +ddbas665 toSci 0.0E-5 -> 0.000000 +ddbas666 toSci 0.0E-6 -> 0E-7 +ddbas667 toSci 0.0E-7 -> 0E-8 +ddbas668 toSci 0.0E-8 -> 0E-9 +ddbas669 toSci 0.0E-9 -> 0E-10 + +ddbas670 toSci 0.00E-0 -> 0.00 +ddbas671 toSci 0.00E-1 -> 0.000 +ddbas672 toSci 0.00E-2 -> 0.0000 +ddbas673 toSci 0.00E-3 -> 0.00000 +ddbas674 toSci 0.00E-4 -> 0.000000 +ddbas675 toSci 0.00E-5 -> 0E-7 +ddbas676 toSci 0.00E-6 -> 0E-8 +ddbas677 toSci 0.00E-7 -> 0E-9 +ddbas678 toSci 0.00E-8 -> 0E-10 +ddbas679 toSci 0.00E-9 -> 0E-11 + +ddbas680 toSci 000000. -> 0 +ddbas681 toSci 00000. -> 0 +ddbas682 toSci 0000. -> 0 +ddbas683 toSci 000. -> 0 +ddbas684 toSci 00. -> 0 +ddbas685 toSci 0. -> 0 +ddbas686 toSci +00000. -> 0 +ddbas687 toSci -00000. -> -0 +ddbas688 toSci +0. -> 0 +ddbas689 toSci -0. -> -0 + +-- Specials +ddbas700 toSci "NaN" -> NaN +ddbas701 toSci "nan" -> NaN +ddbas702 toSci "nAn" -> NaN +ddbas703 toSci "NAN" -> NaN +ddbas704 toSci "+NaN" -> NaN +ddbas705 toSci "+nan" -> NaN +ddbas706 toSci "+nAn" -> NaN +ddbas707 toSci "+NAN" -> NaN +ddbas708 toSci "-NaN" -> -NaN +ddbas709 toSci "-nan" -> -NaN +ddbas710 toSci "-nAn" -> -NaN +ddbas711 toSci "-NAN" -> -NaN +ddbas712 toSci 'NaN0' -> NaN +ddbas713 toSci 'NaN1' -> NaN1 +ddbas714 toSci 'NaN12' -> NaN12 +ddbas715 toSci 'NaN123' -> NaN123 +ddbas716 toSci 'NaN1234' -> NaN1234 +ddbas717 toSci 'NaN01' -> NaN1 +ddbas718 toSci 'NaN012' -> NaN12 +ddbas719 toSci 'NaN0123' -> NaN123 +ddbas720 toSci 'NaN01234' -> NaN1234 +ddbas721 toSci 'NaN001' -> NaN1 +ddbas722 toSci 'NaN0012' -> NaN12 +ddbas723 toSci 'NaN00123' -> NaN123 +ddbas724 toSci 'NaN001234' -> NaN1234 +ddbas725 toSci 'NaN1234567890123456' -> NaN Conversion_syntax +ddbas726 toSci 'NaN123e+1' -> NaN Conversion_syntax +ddbas727 toSci 'NaN12.45' -> NaN Conversion_syntax +ddbas728 toSci 'NaN-12' -> NaN Conversion_syntax +ddbas729 toSci 'NaN+12' -> NaN Conversion_syntax + +ddbas730 toSci "sNaN" -> sNaN +ddbas731 toSci "snan" -> sNaN +ddbas732 toSci "SnAn" -> sNaN +ddbas733 toSci "SNAN" -> sNaN +ddbas734 toSci "+sNaN" -> sNaN +ddbas735 toSci "+snan" -> sNaN +ddbas736 toSci "+SnAn" -> sNaN +ddbas737 toSci "+SNAN" -> sNaN +ddbas738 toSci "-sNaN" -> -sNaN +ddbas739 toSci "-snan" -> -sNaN +ddbas740 toSci "-SnAn" -> -sNaN +ddbas741 toSci "-SNAN" -> -sNaN +ddbas742 toSci 'sNaN0000' -> sNaN +ddbas743 toSci 'sNaN7' -> sNaN7 +ddbas744 toSci 'sNaN007234' -> sNaN7234 +ddbas745 toSci 'sNaN7234561234567890' -> NaN Conversion_syntax +ddbas746 toSci 'sNaN72.45' -> NaN Conversion_syntax +ddbas747 toSci 'sNaN-72' -> NaN Conversion_syntax + +ddbas748 toSci "Inf" -> Infinity +ddbas749 toSci "inf" -> Infinity +ddbas750 toSci "iNf" -> Infinity +ddbas751 toSci "INF" -> Infinity +ddbas752 toSci "+Inf" -> Infinity +ddbas753 toSci "+inf" -> Infinity +ddbas754 toSci "+iNf" -> Infinity +ddbas755 toSci "+INF" -> Infinity +ddbas756 toSci "-Inf" -> -Infinity +ddbas757 toSci "-inf" -> -Infinity +ddbas758 toSci "-iNf" -> -Infinity +ddbas759 toSci "-INF" -> -Infinity + +ddbas760 toSci "Infinity" -> Infinity +ddbas761 toSci "infinity" -> Infinity +ddbas762 toSci "iNfInItY" -> Infinity +ddbas763 toSci "INFINITY" -> Infinity +ddbas764 toSci "+Infinity" -> Infinity +ddbas765 toSci "+infinity" -> Infinity +ddbas766 toSci "+iNfInItY" -> Infinity +ddbas767 toSci "+INFINITY" -> Infinity +ddbas768 toSci "-Infinity" -> -Infinity +ddbas769 toSci "-infinity" -> -Infinity +ddbas770 toSci "-iNfInItY" -> -Infinity +ddbas771 toSci "-INFINITY" -> -Infinity + +-- Specials and zeros for toEng +ddbast772 toEng "NaN" -> NaN +ddbast773 toEng "-Infinity" -> -Infinity +ddbast774 toEng "-sNaN" -> -sNaN +ddbast775 toEng "-NaN" -> -NaN +ddbast776 toEng "+Infinity" -> Infinity +ddbast778 toEng "+sNaN" -> sNaN +ddbast779 toEng "+NaN" -> NaN +ddbast780 toEng "INFINITY" -> Infinity +ddbast781 toEng "SNAN" -> sNaN +ddbast782 toEng "NAN" -> NaN +ddbast783 toEng "infinity" -> Infinity +ddbast784 toEng "snan" -> sNaN +ddbast785 toEng "nan" -> NaN +ddbast786 toEng "InFINITY" -> Infinity +ddbast787 toEng "SnAN" -> sNaN +ddbast788 toEng "nAN" -> NaN +ddbast789 toEng "iNfinity" -> Infinity +ddbast790 toEng "sNan" -> sNaN +ddbast791 toEng "Nan" -> NaN +ddbast792 toEng "Infinity" -> Infinity +ddbast793 toEng "sNaN" -> sNaN + +-- Zero toEng, etc. +ddbast800 toEng 0e+1 -> "0.00E+3" -- doc example + +ddbast801 toEng 0.000000000 -> 0E-9 +ddbast802 toEng 0.00000000 -> 0.00E-6 +ddbast803 toEng 0.0000000 -> 0.0E-6 +ddbast804 toEng 0.000000 -> 0.000000 +ddbast805 toEng 0.00000 -> 0.00000 +ddbast806 toEng 0.0000 -> 0.0000 +ddbast807 toEng 0.000 -> 0.000 +ddbast808 toEng 0.00 -> 0.00 +ddbast809 toEng 0.0 -> 0.0 +ddbast810 toEng .0 -> 0.0 +ddbast811 toEng 0. -> 0 +ddbast812 toEng -.0 -> -0.0 +ddbast813 toEng -0. -> -0 +ddbast814 toEng -0.0 -> -0.0 +ddbast815 toEng -0.00 -> -0.00 +ddbast816 toEng -0.000 -> -0.000 +ddbast817 toEng -0.0000 -> -0.0000 +ddbast818 toEng -0.00000 -> -0.00000 +ddbast819 toEng -0.000000 -> -0.000000 +ddbast820 toEng -0.0000000 -> -0.0E-6 +ddbast821 toEng -0.00000000 -> -0.00E-6 +ddbast822 toEng -0.000000000 -> -0E-9 + +ddbast830 toEng 0.00E+0 -> 0.00 +ddbast831 toEng 0.00E+1 -> 0.0 +ddbast832 toEng 0.00E+2 -> 0 +ddbast833 toEng 0.00E+3 -> 0.00E+3 +ddbast834 toEng 0.00E+4 -> 0.0E+3 +ddbast835 toEng 0.00E+5 -> 0E+3 +ddbast836 toEng 0.00E+6 -> 0.00E+6 +ddbast837 toEng 0.00E+7 -> 0.0E+6 +ddbast838 toEng 0.00E+8 -> 0E+6 +ddbast839 toEng 0.00E+9 -> 0.00E+9 + +ddbast840 toEng 0.0E+0 -> 0.0 +ddbast841 toEng 0.0E+1 -> 0 +ddbast842 toEng 0.0E+2 -> 0.00E+3 +ddbast843 toEng 0.0E+3 -> 0.0E+3 +ddbast844 toEng 0.0E+4 -> 0E+3 +ddbast845 toEng 0.0E+5 -> 0.00E+6 +ddbast846 toEng 0.0E+6 -> 0.0E+6 +ddbast847 toEng 0.0E+7 -> 0E+6 +ddbast848 toEng 0.0E+8 -> 0.00E+9 +ddbast849 toEng 0.0E+9 -> 0.0E+9 + +ddbast850 toEng 0E+0 -> 0 +ddbast851 toEng 0E+1 -> 0.00E+3 +ddbast852 toEng 0E+2 -> 0.0E+3 +ddbast853 toEng 0E+3 -> 0E+3 +ddbast854 toEng 0E+4 -> 0.00E+6 +ddbast855 toEng 0E+5 -> 0.0E+6 +ddbast856 toEng 0E+6 -> 0E+6 +ddbast857 toEng 0E+7 -> 0.00E+9 +ddbast858 toEng 0E+8 -> 0.0E+9 +ddbast859 toEng 0E+9 -> 0E+9 + +ddbast860 toEng 0.0E-0 -> 0.0 +ddbast861 toEng 0.0E-1 -> 0.00 +ddbast862 toEng 0.0E-2 -> 0.000 +ddbast863 toEng 0.0E-3 -> 0.0000 +ddbast864 toEng 0.0E-4 -> 0.00000 +ddbast865 toEng 0.0E-5 -> 0.000000 +ddbast866 toEng 0.0E-6 -> 0.0E-6 +ddbast867 toEng 0.0E-7 -> 0.00E-6 +ddbast868 toEng 0.0E-8 -> 0E-9 +ddbast869 toEng 0.0E-9 -> 0.0E-9 + +ddbast870 toEng 0.00E-0 -> 0.00 +ddbast871 toEng 0.00E-1 -> 0.000 +ddbast872 toEng 0.00E-2 -> 0.0000 +ddbast873 toEng 0.00E-3 -> 0.00000 +ddbast874 toEng 0.00E-4 -> 0.000000 +ddbast875 toEng 0.00E-5 -> 0.0E-6 +ddbast876 toEng 0.00E-6 -> 0.00E-6 +ddbast877 toEng 0.00E-7 -> 0E-9 +ddbast878 toEng 0.00E-8 -> 0.0E-9 +ddbast879 toEng 0.00E-9 -> 0.00E-9 + +-- long input strings +ddbas801 tosci '01234567890123456' -> 1234567890123456 +ddbas802 tosci '001234567890123456' -> 1234567890123456 +ddbas803 tosci '0001234567890123456' -> 1234567890123456 +ddbas804 tosci '00001234567890123456' -> 1234567890123456 +ddbas805 tosci '000001234567890123456' -> 1234567890123456 +ddbas806 tosci '0000001234567890123456' -> 1234567890123456 +ddbas807 tosci '00000001234567890123456' -> 1234567890123456 +ddbas808 tosci '000000001234567890123456' -> 1234567890123456 +ddbas809 tosci '0000000001234567890123456' -> 1234567890123456 +ddbas810 tosci '00000000001234567890123456' -> 1234567890123456 + +ddbas811 tosci '0.1234567890123456' -> 0.1234567890123456 +ddbas812 tosci '0.01234567890123456' -> 0.01234567890123456 +ddbas813 tosci '0.001234567890123456' -> 0.001234567890123456 +ddbas814 tosci '0.0001234567890123456' -> 0.0001234567890123456 +ddbas815 tosci '0.00001234567890123456' -> 0.00001234567890123456 +ddbas816 tosci '0.000001234567890123456' -> 0.000001234567890123456 +ddbas817 tosci '0.0000001234567890123456' -> 1.234567890123456E-7 +ddbas818 tosci '0.00000001234567890123456' -> 1.234567890123456E-8 +ddbas819 tosci '0.000000001234567890123456' -> 1.234567890123456E-9 +ddbas820 tosci '0.0000000001234567890123456' -> 1.234567890123456E-10 + +ddbas821 tosci '12345678901234567890' -> 1.234567890123457E+19 Inexact Rounded +ddbas822 tosci '123456789012345678901' -> 1.234567890123457E+20 Inexact Rounded +ddbas823 tosci '1234567890123456789012' -> 1.234567890123457E+21 Inexact Rounded +ddbas824 tosci '12345678901234567890123' -> 1.234567890123457E+22 Inexact Rounded +ddbas825 tosci '123456789012345678901234' -> 1.234567890123457E+23 Inexact Rounded +ddbas826 tosci '1234567890123456789012345' -> 1.234567890123457E+24 Inexact Rounded +ddbas827 tosci '12345678901234567890123456' -> 1.234567890123457E+25 Inexact Rounded +ddbas828 tosci '123456789012345678901234567' -> 1.234567890123457E+26 Inexact Rounded +ddbas829 tosci '1234567890123456789012345678' -> 1.234567890123457E+27 Inexact Rounded + +-- subnormals and overflows +ddbas906 toSci '99e999999999' -> Infinity Overflow Inexact Rounded +ddbas907 toSci '999e999999999' -> Infinity Overflow Inexact Rounded +ddbas908 toSci '0.9e-999999999' -> 0E-398 Underflow Subnormal Inexact Rounded Clamped +ddbas909 toSci '0.09e-999999999' -> 0E-398 Underflow Subnormal Inexact Rounded Clamped +ddbas910 toSci '0.1e1000000000' -> Infinity Overflow Inexact Rounded +ddbas911 toSci '10e-1000000000' -> 0E-398 Underflow Subnormal Inexact Rounded Clamped +ddbas912 toSci '0.9e9999999999' -> Infinity Overflow Inexact Rounded +ddbas913 toSci '99e-9999999999' -> 0E-398 Underflow Subnormal Inexact Rounded Clamped +ddbas914 toSci '111e9999999999' -> Infinity Overflow Inexact Rounded +ddbas915 toSci '1111e-9999999999' -> 0E-398 Underflow Subnormal Inexact Rounded Clamped +ddbas916 toSci '1111e-99999999999' -> 0E-398 Underflow Subnormal Inexact Rounded Clamped +ddbas917 toSci '7e1000000000' -> Infinity Overflow Inexact Rounded +-- negatives the same +ddbas918 toSci '-99e999999999' -> -Infinity Overflow Inexact Rounded +ddbas919 toSci '-999e999999999' -> -Infinity Overflow Inexact Rounded +ddbas920 toSci '-0.9e-999999999' -> -0E-398 Underflow Subnormal Inexact Rounded Clamped +ddbas921 toSci '-0.09e-999999999' -> -0E-398 Underflow Subnormal Inexact Rounded Clamped +ddbas922 toSci '-0.1e1000000000' -> -Infinity Overflow Inexact Rounded +ddbas923 toSci '-10e-1000000000' -> -0E-398 Underflow Subnormal Inexact Rounded Clamped +ddbas924 toSci '-0.9e9999999999' -> -Infinity Overflow Inexact Rounded +ddbas925 toSci '-99e-9999999999' -> -0E-398 Underflow Subnormal Inexact Rounded Clamped +ddbas926 toSci '-111e9999999999' -> -Infinity Overflow Inexact Rounded +ddbas927 toSci '-1111e-9999999999' -> -0E-398 Underflow Subnormal Inexact Rounded Clamped +ddbas928 toSci '-1111e-99999999999' -> -0E-398 Underflow Subnormal Inexact Rounded Clamped +ddbas929 toSci '-7e1000000000' -> -Infinity Overflow Inexact Rounded + +-- overflow results at different rounding modes +rounding: ceiling +ddbas930 toSci '7e10000' -> Infinity Overflow Inexact Rounded +ddbas931 toSci '-7e10000' -> -9.999999999999999E+384 Overflow Inexact Rounded +rounding: up +ddbas932 toSci '7e10000' -> Infinity Overflow Inexact Rounded +ddbas933 toSci '-7e10000' -> -Infinity Overflow Inexact Rounded +rounding: down +ddbas934 toSci '7e10000' -> 9.999999999999999E+384 Overflow Inexact Rounded +ddbas935 toSci '-7e10000' -> -9.999999999999999E+384 Overflow Inexact Rounded +rounding: floor +ddbas936 toSci '7e10000' -> 9.999999999999999E+384 Overflow Inexact Rounded +ddbas937 toSci '-7e10000' -> -Infinity Overflow Inexact Rounded + +rounding: half_up +ddbas938 toSci '7e10000' -> Infinity Overflow Inexact Rounded +ddbas939 toSci '-7e10000' -> -Infinity Overflow Inexact Rounded +rounding: half_even +ddbas940 toSci '7e10000' -> Infinity Overflow Inexact Rounded +ddbas941 toSci '-7e10000' -> -Infinity Overflow Inexact Rounded +rounding: half_down +ddbas942 toSci '7e10000' -> Infinity Overflow Inexact Rounded +ddbas943 toSci '-7e10000' -> -Infinity Overflow Inexact Rounded + +rounding: half_even + +-- Now check 854/754r some subnormals and underflow to 0 +ddbem400 toSci 1.0000E-383 -> 1.0000E-383 +ddbem401 toSci 0.1E-394 -> 1E-395 Subnormal +ddbem402 toSci 0.1000E-394 -> 1.000E-395 Subnormal +ddbem403 toSci 0.0100E-394 -> 1.00E-396 Subnormal +ddbem404 toSci 0.0010E-394 -> 1.0E-397 Subnormal +ddbem405 toSci 0.0001E-394 -> 1E-398 Subnormal +ddbem406 toSci 0.00010E-394 -> 1E-398 Subnormal Rounded +ddbem407 toSci 0.00013E-394 -> 1E-398 Underflow Subnormal Inexact Rounded +ddbem408 toSci 0.00015E-394 -> 2E-398 Underflow Subnormal Inexact Rounded +ddbem409 toSci 0.00017E-394 -> 2E-398 Underflow Subnormal Inexact Rounded +ddbem410 toSci 0.00023E-394 -> 2E-398 Underflow Subnormal Inexact Rounded +ddbem411 toSci 0.00025E-394 -> 2E-398 Underflow Subnormal Inexact Rounded +ddbem412 toSci 0.00027E-394 -> 3E-398 Underflow Subnormal Inexact Rounded +ddbem413 toSci 0.000149E-394 -> 1E-398 Underflow Subnormal Inexact Rounded +ddbem414 toSci 0.000150E-394 -> 2E-398 Underflow Subnormal Inexact Rounded +ddbem415 toSci 0.000151E-394 -> 2E-398 Underflow Subnormal Inexact Rounded +ddbem416 toSci 0.000249E-394 -> 2E-398 Underflow Subnormal Inexact Rounded +ddbem417 toSci 0.000250E-394 -> 2E-398 Underflow Subnormal Inexact Rounded +ddbem418 toSci 0.000251E-394 -> 3E-398 Underflow Subnormal Inexact Rounded +ddbem419 toSci 0.00009E-394 -> 1E-398 Underflow Subnormal Inexact Rounded +ddbem420 toSci 0.00005E-394 -> 0E-398 Underflow Subnormal Inexact Rounded Clamped +ddbem421 toSci 0.00003E-394 -> 0E-398 Underflow Subnormal Inexact Rounded Clamped +ddbem422 toSci 0.000009E-394 -> 0E-398 Underflow Subnormal Inexact Rounded Clamped +ddbem423 toSci 0.000005E-394 -> 0E-398 Underflow Subnormal Inexact Rounded Clamped +ddbem424 toSci 0.000003E-394 -> 0E-398 Underflow Subnormal Inexact Rounded Clamped + +ddbem425 toSci 0.001049E-394 -> 1.0E-397 Underflow Subnormal Inexact Rounded +ddbem426 toSci 0.001050E-394 -> 1.0E-397 Underflow Subnormal Inexact Rounded +ddbem427 toSci 0.001051E-394 -> 1.1E-397 Underflow Subnormal Inexact Rounded +ddbem428 toSci 0.001149E-394 -> 1.1E-397 Underflow Subnormal Inexact Rounded +ddbem429 toSci 0.001150E-394 -> 1.2E-397 Underflow Subnormal Inexact Rounded +ddbem430 toSci 0.001151E-394 -> 1.2E-397 Underflow Subnormal Inexact Rounded + +ddbem432 toSci 0.010049E-394 -> 1.00E-396 Underflow Subnormal Inexact Rounded +ddbem433 toSci 0.010050E-394 -> 1.00E-396 Underflow Subnormal Inexact Rounded +ddbem434 toSci 0.010051E-394 -> 1.01E-396 Underflow Subnormal Inexact Rounded +ddbem435 toSci 0.010149E-394 -> 1.01E-396 Underflow Subnormal Inexact Rounded +ddbem436 toSci 0.010150E-394 -> 1.02E-396 Underflow Subnormal Inexact Rounded +ddbem437 toSci 0.010151E-394 -> 1.02E-396 Underflow Subnormal Inexact Rounded + +ddbem440 toSci 0.10103E-394 -> 1.010E-395 Underflow Subnormal Inexact Rounded +ddbem441 toSci 0.10105E-394 -> 1.010E-395 Underflow Subnormal Inexact Rounded +ddbem442 toSci 0.10107E-394 -> 1.011E-395 Underflow Subnormal Inexact Rounded +ddbem443 toSci 0.10113E-394 -> 1.011E-395 Underflow Subnormal Inexact Rounded +ddbem444 toSci 0.10115E-394 -> 1.012E-395 Underflow Subnormal Inexact Rounded +ddbem445 toSci 0.10117E-394 -> 1.012E-395 Underflow Subnormal Inexact Rounded + +ddbem450 toSci 1.10730E-395 -> 1.107E-395 Underflow Subnormal Inexact Rounded +ddbem451 toSci 1.10750E-395 -> 1.108E-395 Underflow Subnormal Inexact Rounded +ddbem452 toSci 1.10770E-395 -> 1.108E-395 Underflow Subnormal Inexact Rounded +ddbem453 toSci 1.10830E-395 -> 1.108E-395 Underflow Subnormal Inexact Rounded +ddbem454 toSci 1.10850E-395 -> 1.108E-395 Underflow Subnormal Inexact Rounded +ddbem455 toSci 1.10870E-395 -> 1.109E-395 Underflow Subnormal Inexact Rounded + +-- make sure sign OK +ddbem456 toSci -0.10103E-394 -> -1.010E-395 Underflow Subnormal Inexact Rounded +ddbem457 toSci -0.10105E-394 -> -1.010E-395 Underflow Subnormal Inexact Rounded +ddbem458 toSci -0.10107E-394 -> -1.011E-395 Underflow Subnormal Inexact Rounded +ddbem459 toSci -0.10113E-394 -> -1.011E-395 Underflow Subnormal Inexact Rounded +ddbem460 toSci -0.10115E-394 -> -1.012E-395 Underflow Subnormal Inexact Rounded +ddbem461 toSci -0.10117E-394 -> -1.012E-395 Underflow Subnormal Inexact Rounded + +-- '999s' cases +ddbem464 toSci 999999E-395 -> 9.99999E-390 Subnormal +ddbem465 toSci 99999.0E-394 -> 9.99990E-390 Subnormal +ddbem466 toSci 99999.E-394 -> 9.9999E-390 Subnormal +ddbem467 toSci 9999.9E-394 -> 9.9999E-391 Subnormal +ddbem468 toSci 999.99E-394 -> 9.9999E-392 Subnormal +ddbem469 toSci 99.999E-394 -> 9.9999E-393 Subnormal +ddbem470 toSci 9.9999E-394 -> 9.9999E-394 Subnormal +ddbem471 toSci 0.99999E-394 -> 1.0000E-394 Underflow Subnormal Inexact Rounded +ddbem472 toSci 0.099999E-394 -> 1.000E-395 Underflow Subnormal Inexact Rounded +ddbem473 toSci 0.0099999E-394 -> 1.00E-396 Underflow Subnormal Inexact Rounded +ddbem474 toSci 0.00099999E-394 -> 1.0E-397 Underflow Subnormal Inexact Rounded +ddbem475 toSci 0.000099999E-394 -> 1E-398 Underflow Subnormal Inexact Rounded +ddbem476 toSci 0.0000099999E-394 -> 0E-398 Underflow Subnormal Inexact Rounded Clamped +ddbem477 toSci 0.00000099999E-394 -> 0E-398 Underflow Subnormal Inexact Rounded Clamped +ddbem478 toSci 0.000000099999E-394 -> 0E-398 Underflow Subnormal Inexact Rounded Clamped + +-- Exponents with insignificant leading zeros +ddbas1001 toSci 1e999999999 -> Infinity Overflow Inexact Rounded +ddbas1002 toSci 1e0999999999 -> Infinity Overflow Inexact Rounded +ddbas1003 toSci 1e00999999999 -> Infinity Overflow Inexact Rounded +ddbas1004 toSci 1e000999999999 -> Infinity Overflow Inexact Rounded +ddbas1005 toSci 1e000000000000999999999 -> Infinity Overflow Inexact Rounded +ddbas1006 toSci 1e000000000001000000007 -> Infinity Overflow Inexact Rounded +ddbas1007 toSci 1e-999999999 -> 0E-398 Underflow Subnormal Inexact Rounded Clamped +ddbas1008 toSci 1e-0999999999 -> 0E-398 Underflow Subnormal Inexact Rounded Clamped +ddbas1009 toSci 1e-00999999999 -> 0E-398 Underflow Subnormal Inexact Rounded Clamped +ddbas1010 toSci 1e-000999999999 -> 0E-398 Underflow Subnormal Inexact Rounded Clamped +ddbas1011 toSci 1e-000000000000999999999 -> 0E-398 Underflow Subnormal Inexact Rounded Clamped +ddbas1012 toSci 1e-000000000001000000007 -> 0E-398 Underflow Subnormal Inexact Rounded Clamped + +-- check for double-rounded subnormals +ddbas1041 toSci 1.1111111111152444E-384 -> 1.11111111111524E-384 Inexact Rounded Subnormal Underflow +ddbas1042 toSci 1.1111111111152445E-384 -> 1.11111111111524E-384 Inexact Rounded Subnormal Underflow +ddbas1043 toSci 1.1111111111152446E-384 -> 1.11111111111524E-384 Inexact Rounded Subnormal Underflow + +-- clamped zeros [see also clamp.decTest] +ddbas1075 toSci 0e+10000 -> 0E+369 Clamped +ddbas1076 toSci 0e-10000 -> 0E-398 Clamped +ddbas1077 toSci -0e+10000 -> -0E+369 Clamped +ddbas1078 toSci -0e-10000 -> -0E-398 Clamped + +-- extreme values from next-wider +ddbas1101 toSci -9.99999999999999999999999999999999E+6144 -> -Infinity Overflow Inexact Rounded +ddbas1102 toSci -1E-6143 -> -0E-398 Inexact Rounded Subnormal Underflow Clamped +ddbas1103 toSci -1E-6176 -> -0E-398 Inexact Rounded Subnormal Underflow Clamped +ddbas1104 toSci -0 -> -0 +ddbas1105 toSci +0 -> 0 +ddbas1106 toSci +1E-6176 -> 0E-398 Inexact Rounded Subnormal Underflow Clamped +ddbas1107 toSci +1E-6173 -> 0E-398 Inexact Rounded Subnormal Underflow Clamped +ddbas1108 toSci +9.99999999999999999999999999999999E+6144 -> Infinity Overflow Inexact Rounded + Added: python/branches/release25-maint/Lib/test/decimaltestdata/ddCanonical.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/ddCanonical.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,357 @@ +------------------------------------------------------------------------ +-- ddCanonical.decTest -- test decDouble canonical results -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- This file tests that copy operations leave uncanonical operands +-- unchanged, and vice versa +-- All operands and results are decDoubles. +precision: 16 +maxExponent: 384 +minExponent: -383 +extended: 1 +clamp: 1 +rounding: half_even + +-- Uncanonical declets are: abc, where: +-- a=1,2,3 +-- b=6,7,e,f +-- c=e,f + +-- assert some standard (canonical) values; this tests that FromString +-- produces canonical results (many more in decimalNN) +ddcan001 apply 9.999999999999999E+384 -> #77fcff3fcff3fcff +ddcan002 apply 0 -> #2238000000000000 +ddcan003 apply 1 -> #2238000000000001 +ddcan004 apply -1 -> #a238000000000001 +ddcan005 apply Infinity -> #7800000000000000 +ddcan006 apply -Infinity -> #f800000000000000 +ddcan007 apply -NaN -> #fc00000000000000 +ddcan008 apply -sNaN -> #fe00000000000000 +ddcan009 apply NaN999999999999999 -> #7c00ff3fcff3fcff +ddcan010 apply sNaN999999999999999 -> #7e00ff3fcff3fcff +decan011 apply 9999999999999999 -> #6e38ff3fcff3fcff +ddcan012 apply 7.50 -> #22300000000003d0 +ddcan013 apply 9.99 -> #22300000000000ff + +-- Base tests for canonical encodings (individual operator +-- propagation is tested later) + +-- Finites: declets in coefficient +ddcan021 canonical #77fcff3fcff3fcff -> #77fcff3fcff3fcff +ddcan022 canonical #77fcff3fcff3fcff -> #77fcff3fcff3fcff +ddcan023 canonical #77ffff3fcff3fcff -> #77fcff3fcff3fcff +ddcan024 canonical #77ffff3fcff3fcff -> #77fcff3fcff3fcff +ddcan025 canonical #77fcffffcff3fcff -> #77fcff3fcff3fcff +ddcan026 canonical #77fcffffcff3fcff -> #77fcff3fcff3fcff +ddcan027 canonical #77fcff3ffff3fcff -> #77fcff3fcff3fcff +ddcan028 canonical #77fcff3ffff3fcff -> #77fcff3fcff3fcff +ddcan030 canonical #77fcff3fcffffcff -> #77fcff3fcff3fcff +ddcan031 canonical #77fcff3fcffffcff -> #77fcff3fcff3fcff +ddcan032 canonical #77fcff3fcff3ffff -> #77fcff3fcff3fcff +ddcan033 canonical #77fcff3fcff3ffff -> #77fcff3fcff3fcff +ddcan035 canonical #77fcff3fdff3fcff -> #77fcff3fcff3fcff +ddcan036 canonical #77fcff3feff3fcff -> #77fcff3fcff3fcff + +-- NaN: declets in payload +ddcan100 canonical NaN999999999999999 -> #7c00ff3fcff3fcff +ddcan101 canonical #7c00ff3fcff3fcff -> #7c00ff3fcff3fcff +ddcan102 canonical #7c03ff3fcff3fcff -> #7c00ff3fcff3fcff +ddcan103 canonical #7c00ffffcff3fcff -> #7c00ff3fcff3fcff +ddcan104 canonical #7c00ff3ffff3fcff -> #7c00ff3fcff3fcff +ddcan105 canonical #7c00ff3fcffffcff -> #7c00ff3fcff3fcff +ddcan106 canonical #7c00ff3fcff3ffff -> #7c00ff3fcff3fcff +ddcan107 canonical #7c00ff3fcff3ffff -> #7c00ff3fcff3fcff +-- NaN: exponent continuation bits [excluding sNaN selector] +ddcan110 canonical #7c00ff3fcff3fcff -> #7c00ff3fcff3fcff +ddcan112 canonical #7d00ff3fcff3fcff -> #7c00ff3fcff3fcff +ddcan113 canonical #7c80ff3fcff3fcff -> #7c00ff3fcff3fcff +ddcan114 canonical #7c40ff3fcff3fcff -> #7c00ff3fcff3fcff +ddcan115 canonical #7c20ff3fcff3fcff -> #7c00ff3fcff3fcff +ddcan116 canonical #7c10ff3fcff3fcff -> #7c00ff3fcff3fcff +ddcan117 canonical #7c08ff3fcff3fcff -> #7c00ff3fcff3fcff +ddcan118 canonical #7c04ff3fcff3fcff -> #7c00ff3fcff3fcff + +-- sNaN: declets in payload +ddcan120 canonical sNaN999999999999999 -> #7e00ff3fcff3fcff +ddcan121 canonical #7e00ff3fcff3fcff -> #7e00ff3fcff3fcff +ddcan122 canonical #7e03ff3fcff3fcff -> #7e00ff3fcff3fcff +ddcan123 canonical #7e00ffffcff3fcff -> #7e00ff3fcff3fcff +ddcan124 canonical #7e00ff3ffff3fcff -> #7e00ff3fcff3fcff +ddcan125 canonical #7e00ff3fcffffcff -> #7e00ff3fcff3fcff +ddcan126 canonical #7e00ff3fcff3ffff -> #7e00ff3fcff3fcff +ddcan127 canonical #7e00ff3fcff3ffff -> #7e00ff3fcff3fcff +-- sNaN: exponent continuation bits [excluding sNaN selector] +ddcan130 canonical #7e00ff3fcff3fcff -> #7e00ff3fcff3fcff +ddcan132 canonical #7f00ff3fcff3fcff -> #7e00ff3fcff3fcff +ddcan133 canonical #7e80ff3fcff3fcff -> #7e00ff3fcff3fcff +ddcan134 canonical #7e40ff3fcff3fcff -> #7e00ff3fcff3fcff +ddcan135 canonical #7e20ff3fcff3fcff -> #7e00ff3fcff3fcff +ddcan136 canonical #7e10ff3fcff3fcff -> #7e00ff3fcff3fcff +ddcan137 canonical #7e08ff3fcff3fcff -> #7e00ff3fcff3fcff +ddcan138 canonical #7e04ff3fcff3fcff -> #7e00ff3fcff3fcff + +-- Inf: exponent continuation bits +ddcan140 canonical #7800000000000000 -> #7800000000000000 +ddcan141 canonical #7900000000000000 -> #7800000000000000 +ddcan142 canonical #7a00000000000000 -> #7800000000000000 +ddcan143 canonical #7880000000000000 -> #7800000000000000 +ddcan144 canonical #7840000000000000 -> #7800000000000000 +ddcan145 canonical #7820000000000000 -> #7800000000000000 +ddcan146 canonical #7810000000000000 -> #7800000000000000 +ddcan147 canonical #7808000000000000 -> #7800000000000000 +ddcan148 canonical #7804000000000000 -> #7800000000000000 + +-- Inf: coefficient continuation bits (first, last, and a few others) +ddcan150 canonical #7800000000000000 -> #7800000000000000 +ddcan151 canonical #7802000000000000 -> #7800000000000000 +ddcan152 canonical #7800000000000001 -> #7800000000000000 +ddcan153 canonical #7801000000000000 -> #7800000000000000 +ddcan154 canonical #7800200000000000 -> #7800000000000000 +ddcan155 canonical #7800080000000000 -> #7800000000000000 +ddcan156 canonical #7800002000000000 -> #7800000000000000 +ddcan157 canonical #7800000400000000 -> #7800000000000000 +ddcan158 canonical #7800000040000000 -> #7800000000000000 +ddcan159 canonical #7800000008000000 -> #7800000000000000 +ddcan160 canonical #7800000000400000 -> #7800000000000000 +ddcan161 canonical #7800000000020000 -> #7800000000000000 +ddcan162 canonical #7800000000008000 -> #7800000000000000 +ddcan163 canonical #7800000000000200 -> #7800000000000000 +ddcan164 canonical #7800000000000040 -> #7800000000000000 +ddcan165 canonical #7800000000000008 -> #7800000000000000 + + +-- Now the operators -- trying to check paths that might fail to +-- canonicalize propagated operands + +----- Add: +-- Finites: neutral 0 +ddcan202 add 0E+384 #77ffff3fcff3fcff -> #77fcff3fcff3fcff +ddcan203 add #77fcffffcff3fcff 0E+384 -> #77fcff3fcff3fcff +-- tiny zero +ddcan204 add 0E-398 #77ffff3fcff3fcff -> #77fcff3fcff3fcff Rounded +ddcan205 add #77fcffffcff3fcff 0E-398 -> #77fcff3fcff3fcff Rounded +-- tiny non zero +ddcan206 add -1E-398 #77ffff3fcff3fcff -> #77fcff3fcff3fcff Inexact Rounded +ddcan207 add #77ffff3fcff3fcff -1E-398 -> #77fcff3fcff3fcff Inexact Rounded +-- NaN: declets in payload +ddcan211 add 0 #7c03ff3fcff3fcff -> #7c00ff3fcff3fcff +ddcan212 add #7c03ff3fcff3fcff 0 -> #7c00ff3fcff3fcff +-- NaN: exponent continuation bits [excluding sNaN selector] +ddcan213 add 0 #7c40ff3fcff3fcff -> #7c00ff3fcff3fcff +ddcan214 add #7c40ff3fcff3fcff 0 -> #7c00ff3fcff3fcff +-- sNaN: declets in payload +ddcan215 add 0 #7e00ffffcff3fcff -> #7c00ff3fcff3fcff Invalid_operation +ddcan216 add #7e00ffffcff3fcff 0 -> #7c00ff3fcff3fcff Invalid_operation +-- sNaN: exponent continuation bits [excluding sNaN selector] +ddcan217 add 0 #7e80ff3fcff3fcff -> #7c00ff3fcff3fcff Invalid_operation +ddcan218 add #7e80ff3fcff3fcff 0 -> #7c00ff3fcff3fcff Invalid_operation +-- Inf: exponent continuation bits +ddcan220 add 0 #7880000000000000 -> #7800000000000000 +ddcan221 add #7880000000000000 0 -> #7800000000000000 +-- Inf: coefficient continuation bits +ddcan222 add 0 #7802000000000000 -> #7800000000000000 +ddcan223 add #7802000000000000 0 -> #7800000000000000 +ddcan224 add 0 #7800000000000001 -> #7800000000000000 +ddcan225 add #7800000000000001 0 -> #7800000000000000 +ddcan226 add 0 #7800002000000000 -> #7800000000000000 +ddcan227 add #7800002000000000 0 -> #7800000000000000 + +----- Class: [does not return encoded] + +----- Compare: +ddcan231 compare -Inf 1 -> #a238000000000001 +ddcan232 compare -Inf -Inf -> #2238000000000000 +ddcan233 compare 1 -Inf -> #2238000000000001 +ddcan234 compare #7c00ff3ffff3fcff -1000 -> #7c00ff3fcff3fcff +ddcan235 compare #7e00ff3ffff3fcff -1000 -> #7c00ff3fcff3fcff Invalid_operation + +----- CompareSig: +ddcan241 comparesig -Inf 1 -> #a238000000000001 +ddcan242 comparesig -Inf -Inf -> #2238000000000000 +ddcan243 comparesig 1 -Inf -> #2238000000000001 +ddcan244 comparesig #7c00ff3ffff3fcff -1000 -> #7c00ff3fcff3fcff Invalid_operation +ddcan245 comparesig #7e00ff3ffff3fcff -1000 -> #7c00ff3fcff3fcff Invalid_operation + +----- Copy: [does not usually canonicalize] +-- finites +ddcan250 copy #77ffff3fcff3fcff -> #77ffff3fcff3fcff +ddcan251 copy #77fcff3fdff3fcff -> #77fcff3fdff3fcff +-- NaNs +ddcan252 copy #7c03ff3fcff3fcff -> #7c03ff3fcff3fcff +ddcan253 copy #7c00ff3fcff3ffff -> #7c00ff3fcff3ffff +ddcan254 copy #7d00ff3fcff3fcff -> #7d00ff3fcff3fcff +ddcan255 copy #7c04ff3fcff3fcff -> #7c04ff3fcff3fcff +-- sNaN +ddcan256 copy #7e00ff3fcffffcff -> #7e00ff3fcffffcff +ddcan257 copy #7e40ff3fcff3fcff -> #7e40ff3fcff3fcff +-- Inf +ddcan258 copy #7a00000000000000 -> #7a00000000000000 +ddcan259 copy #7800200000000000 -> #7800200000000000 + +----- CopyAbs: [does not usually canonicalize] +-- finites +ddcan260 copyabs #f7ffff3fcff3fcff -> #77ffff3fcff3fcff +ddcan261 copyabs #f7fcff3fdff3fcff -> #77fcff3fdff3fcff +-- NaNs +ddcan262 copyabs #fc03ff3fcff3fcff -> #7c03ff3fcff3fcff +ddcan263 copyabs #fc00ff3fcff3ffff -> #7c00ff3fcff3ffff +ddcan264 copyabs #fd00ff3fcff3fcff -> #7d00ff3fcff3fcff +ddcan265 copyabs #fc04ff3fcff3fcff -> #7c04ff3fcff3fcff +-- sNaN +ddcan266 copyabs #fe00ff3fcffffcff -> #7e00ff3fcffffcff +ddcan267 copyabs #fe40ff3fcff3fcff -> #7e40ff3fcff3fcff +-- Inf +ddcan268 copyabs #fa00000000000000 -> #7a00000000000000 +ddcan269 copyabs #f800200000000000 -> #7800200000000000 + +----- CopyNegate: [does not usually canonicalize] +-- finites +ddcan270 copynegate #77ffff3fcff3fcff -> #f7ffff3fcff3fcff +ddcan271 copynegate #77fcff3fdff3fcff -> #f7fcff3fdff3fcff +-- NaNs +ddcan272 copynegate #7c03ff3fcff3fcff -> #fc03ff3fcff3fcff +ddcan273 copynegate #7c00ff3fcff3ffff -> #fc00ff3fcff3ffff +ddcan274 copynegate #7d00ff3fcff3fcff -> #fd00ff3fcff3fcff +ddcan275 copynegate #7c04ff3fcff3fcff -> #fc04ff3fcff3fcff +-- sNaN +ddcan276 copynegate #7e00ff3fcffffcff -> #fe00ff3fcffffcff +ddcan277 copynegate #7e40ff3fcff3fcff -> #fe40ff3fcff3fcff +-- Inf +ddcan278 copynegate #7a00000000000000 -> #fa00000000000000 +ddcan279 copynegate #7800200000000000 -> #f800200000000000 + +----- CopySign: [does not usually canonicalize] +-- finites +ddcan280 copysign #77ffff3fcff3fcff -1 -> #f7ffff3fcff3fcff +ddcan281 copysign #77fcff3fdff3fcff 1 -> #77fcff3fdff3fcff +-- NaNs +ddcan282 copysign #7c03ff3fcff3fcff -1 -> #fc03ff3fcff3fcff +ddcan283 copysign #7c00ff3fcff3ffff 1 -> #7c00ff3fcff3ffff +ddcan284 copysign #7d00ff3fcff3fcff -1 -> #fd00ff3fcff3fcff +ddcan285 copysign #7c04ff3fcff3fcff 1 -> #7c04ff3fcff3fcff +-- sNaN +ddcan286 copysign #7e00ff3fcffffcff -1 -> #fe00ff3fcffffcff +ddcan287 copysign #7e40ff3fcff3fcff 1 -> #7e40ff3fcff3fcff +-- Inf +ddcan288 copysign #7a00000000000000 -1 -> #fa00000000000000 +ddcan289 copysign #7800200000000000 1 -> #7800200000000000 + +----- Multiply: +-- Finites: neutral 0 +ddcan302 multiply 1 #77ffff3fcff3fcff -> #77fcff3fcff3fcff +ddcan303 multiply #77fcffffcff3fcff 1 -> #77fcff3fcff3fcff +-- negative +ddcan306 multiply -1 #77ffff3fcff3fcff -> #f7fcff3fcff3fcff +ddcan307 multiply #77fcffffcff3fcff -1 -> #f7fcff3fcff3fcff +-- NaN: declets in payload +ddcan311 multiply 1 #7c03ff3fcff3fcff -> #7c00ff3fcff3fcff +ddcan312 multiply #7c03ff3fcff3fcff 1 -> #7c00ff3fcff3fcff +-- NaN: exponent continuation bits [excluding sNaN selector] +ddcan313 multiply 1 #7c40ff3fcff3fcff -> #7c00ff3fcff3fcff +ddcan314 multiply #7c40ff3fcff3fcff 1 -> #7c00ff3fcff3fcff +-- sNaN: declets in payload +ddcan315 multiply 1 #7e00ffffcff3fcff -> #7c00ff3fcff3fcff Invalid_operation +ddcan316 multiply #7e00ffffcff3fcff 1 -> #7c00ff3fcff3fcff Invalid_operation +-- sNaN: exponent continuation bits [excluding sNaN selector] +ddcan317 multiply 1 #7e80ff3fcff3fcff -> #7c00ff3fcff3fcff Invalid_operation +ddcan318 multiply #7e80ff3fcff3fcff 1 -> #7c00ff3fcff3fcff Invalid_operation +-- Inf: exponent continuation bits +ddcan320 multiply 1 #7880000000000000 -> #7800000000000000 +ddcan321 multiply #7880000000000000 1 -> #7800000000000000 +-- Inf: coefficient continuation bits +ddcan322 multiply 1 #7802000000000000 -> #7800000000000000 +ddcan323 multiply #7802000000000000 1 -> #7800000000000000 +ddcan324 multiply 1 #7800000000000001 -> #7800000000000000 +ddcan325 multiply #7800000000000001 1 -> #7800000000000000 +ddcan326 multiply 1 #7800002000000000 -> #7800000000000000 +ddcan327 multiply #7800002000000000 1 -> #7800000000000000 + +----- Quantize: +ddcan401 quantize #6e38ff3ffff3fcff 1 -> #6e38ff3fcff3fcff +ddcan402 quantize #6e38ff3fcff3fdff 0 -> #6e38ff3fcff3fcff +ddcan403 quantize #7880000000000000 Inf -> #7800000000000000 +ddcan404 quantize #7802000000000000 -Inf -> #7800000000000000 +ddcan410 quantize #7c03ff3fcff3fcff 1 -> #7c00ff3fcff3fcff +ddcan411 quantize #7c03ff3fcff3fcff 1 -> #7c00ff3fcff3fcff +ddcan412 quantize #7c40ff3fcff3fcff 1 -> #7c00ff3fcff3fcff +ddcan413 quantize #7c40ff3fcff3fcff 1 -> #7c00ff3fcff3fcff +ddcan414 quantize #7e00ffffcff3fcff 1 -> #7c00ff3fcff3fcff Invalid_operation +ddcan415 quantize #7e00ffffcff3fcff 1 -> #7c00ff3fcff3fcff Invalid_operation +ddcan416 quantize #7e80ff3fcff3fcff 1 -> #7c00ff3fcff3fcff Invalid_operation +ddcan417 quantize #7e80ff3fcff3fcff 1 -> #7c00ff3fcff3fcff Invalid_operation + +----- Subtract: +-- Finites: neutral 0 +ddcan502 subtract 0E+384 #77ffff3fcff3fcff -> #f7fcff3fcff3fcff +ddcan503 subtract #77fcffffcff3fcff 0E+384 -> #77fcff3fcff3fcff +-- tiny zero +ddcan504 subtract 0E-398 #77ffff3fcff3fcff -> #f7fcff3fcff3fcff Rounded +ddcan505 subtract #77fcffffcff3fcff 0E-398 -> #77fcff3fcff3fcff Rounded +-- tiny non zero +ddcan506 subtract -1E-398 #77ffff3fcff3fcff -> #f7fcff3fcff3fcff Inexact Rounded +ddcan507 subtract #77ffff3fcff3fcff -1E-398 -> #77fcff3fcff3fcff Inexact Rounded +-- NaN: declets in payload +ddcan511 subtract 0 #7c03ff3fcff3fcff -> #7c00ff3fcff3fcff +ddcan512 subtract #7c03ff3fcff3fcff 0 -> #7c00ff3fcff3fcff +-- NaN: exponent continuation bits [excluding sNaN selector] +ddcan513 subtract 0 #7c40ff3fcff3fcff -> #7c00ff3fcff3fcff +ddcan514 subtract #7c40ff3fcff3fcff 0 -> #7c00ff3fcff3fcff +-- sNaN: declets in payload +ddcan515 subtract 0 #7e00ffffcff3fcff -> #7c00ff3fcff3fcff Invalid_operation +ddcan516 subtract #7e00ffffcff3fcff 0 -> #7c00ff3fcff3fcff Invalid_operation +-- sNaN: exponent continuation bits [excluding sNaN selector] +ddcan517 subtract 0 #7e80ff3fcff3fcff -> #7c00ff3fcff3fcff Invalid_operation +ddcan518 subtract #7e80ff3fcff3fcff 0 -> #7c00ff3fcff3fcff Invalid_operation +-- Inf: exponent continuation bits +ddcan520 subtract 0 #7880000000000000 -> #f800000000000000 +ddcan521 subtract #7880000000000000 0 -> #7800000000000000 +-- Inf: coefficient continuation bits +ddcan522 subtract 0 #7802000000000000 -> #f800000000000000 +ddcan523 subtract #7802000000000000 0 -> #7800000000000000 +ddcan524 subtract 0 #7800000000000001 -> #f800000000000000 +ddcan525 subtract #7800000000000001 0 -> #7800000000000000 +ddcan526 subtract 0 #7800002000000000 -> #f800000000000000 +ddcan527 subtract #7800002000000000 0 -> #7800000000000000 + +----- ToIntegral: +ddcan601 tointegralx #6e38ff3ffff3fcff -> #6e38ff3fcff3fcff +ddcan602 tointegralx #6e38ff3fcff3fdff -> #6e38ff3fcff3fcff +ddcan603 tointegralx #7880000000000000 -> #7800000000000000 +ddcan604 tointegralx #7802000000000000 -> #7800000000000000 +ddcan610 tointegralx #7c03ff3fcff3fcff -> #7c00ff3fcff3fcff +ddcan611 tointegralx #7c03ff3fcff3fcff -> #7c00ff3fcff3fcff +ddcan612 tointegralx #7c40ff3fcff3fcff -> #7c00ff3fcff3fcff +ddcan613 tointegralx #7c40ff3fcff3fcff -> #7c00ff3fcff3fcff +ddcan614 tointegralx #7e00ffffcff3fcff -> #7c00ff3fcff3fcff Invalid_operation +ddcan615 tointegralx #7e00ffffcff3fcff -> #7c00ff3fcff3fcff Invalid_operation +ddcan616 tointegralx #7e80ff3fcff3fcff -> #7c00ff3fcff3fcff Invalid_operation +ddcan617 tointegralx #7e80ff3fcff3fcff -> #7c00ff3fcff3fcff Invalid_operation +-- uncanonical 3999, 39.99, 3.99, 0.399, and negatives +ddcan618 tointegralx #2238000000000fff -> #2238000000000cff +ddcan619 tointegralx #2230000000000fff -> #2238000000000040 Inexact Rounded +ddcan620 tointegralx #222c000000000fff -> #2238000000000004 Inexact Rounded +ddcan621 tointegralx #2228000000000fff -> #2238000000000000 Inexact Rounded +ddcan622 tointegralx #a238000000000fff -> #a238000000000cff +ddcan623 tointegralx #a230000000000fff -> #a238000000000040 Inexact Rounded +ddcan624 tointegralx #a22c000000000fff -> #a238000000000004 Inexact Rounded +ddcan625 tointegralx #a228000000000fff -> #a238000000000000 Inexact Rounded + + + Added: python/branches/release25-maint/Lib/test/decimaltestdata/ddClass.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/ddClass.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,76 @@ +------------------------------------------------------------------------ +-- ddClass.decTest -- decDouble Class operations -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- [New 2006.11.27] +precision: 16 +maxExponent: 384 +minExponent: -383 +extended: 1 +clamp: 1 +rounding: half_even + +ddcla001 class 0 -> +Zero +ddcla002 class 0.00 -> +Zero +ddcla003 class 0E+5 -> +Zero +ddcla004 class 1E-396 -> +Subnormal +ddcla005 class 0.1E-383 -> +Subnormal +ddcla006 class 0.999999999999999E-383 -> +Subnormal +ddcla007 class 1.000000000000000E-383 -> +Normal +ddcla008 class 1E-383 -> +Normal +ddcla009 class 1E-100 -> +Normal +ddcla010 class 1E-10 -> +Normal +ddcla012 class 1E-1 -> +Normal +ddcla013 class 1 -> +Normal +ddcla014 class 2.50 -> +Normal +ddcla015 class 100.100 -> +Normal +ddcla016 class 1E+30 -> +Normal +ddcla017 class 1E+384 -> +Normal +ddcla018 class 9.999999999999999E+384 -> +Normal +ddcla019 class Inf -> +Infinity + +ddcla021 class -0 -> -Zero +ddcla022 class -0.00 -> -Zero +ddcla023 class -0E+5 -> -Zero +ddcla024 class -1E-396 -> -Subnormal +ddcla025 class -0.1E-383 -> -Subnormal +ddcla026 class -0.999999999999999E-383 -> -Subnormal +ddcla027 class -1.000000000000000E-383 -> -Normal +ddcla028 class -1E-383 -> -Normal +ddcla029 class -1E-100 -> -Normal +ddcla030 class -1E-10 -> -Normal +ddcla032 class -1E-1 -> -Normal +ddcla033 class -1 -> -Normal +ddcla034 class -2.50 -> -Normal +ddcla035 class -100.100 -> -Normal +ddcla036 class -1E+30 -> -Normal +ddcla037 class -1E+384 -> -Normal +ddcla038 class -9.999999999999999E+384 -> -Normal +ddcla039 class -Inf -> -Infinity + +ddcla041 class NaN -> NaN +ddcla042 class -NaN -> NaN +ddcla043 class +NaN12345 -> NaN +ddcla044 class sNaN -> sNaN +ddcla045 class -sNaN -> sNaN +ddcla046 class +sNaN12345 -> sNaN + + + Added: python/branches/release25-maint/Lib/test/decimaltestdata/ddCompare.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/ddCompare.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,744 @@ +------------------------------------------------------------------------ +-- ddCompare.decTest -- decDouble comparison that allows quiet NaNs -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- Note that we cannot assume add/subtract tests cover paths adequately, +-- here, because the code might be quite different (comparison cannot +-- overflow or underflow, so actual subtractions are not necessary). + +-- All operands and results are decDoubles. +precision: 16 +maxExponent: 384 +minExponent: -383 +extended: 1 +clamp: 1 +rounding: half_even + +-- sanity checks +ddcom001 compare -2 -2 -> 0 +ddcom002 compare -2 -1 -> -1 +ddcom003 compare -2 0 -> -1 +ddcom004 compare -2 1 -> -1 +ddcom005 compare -2 2 -> -1 +ddcom006 compare -1 -2 -> 1 +ddcom007 compare -1 -1 -> 0 +ddcom008 compare -1 0 -> -1 +ddcom009 compare -1 1 -> -1 +ddcom010 compare -1 2 -> -1 +ddcom011 compare 0 -2 -> 1 +ddcom012 compare 0 -1 -> 1 +ddcom013 compare 0 0 -> 0 +ddcom014 compare 0 1 -> -1 +ddcom015 compare 0 2 -> -1 +ddcom016 compare 1 -2 -> 1 +ddcom017 compare 1 -1 -> 1 +ddcom018 compare 1 0 -> 1 +ddcom019 compare 1 1 -> 0 +ddcom020 compare 1 2 -> -1 +ddcom021 compare 2 -2 -> 1 +ddcom022 compare 2 -1 -> 1 +ddcom023 compare 2 0 -> 1 +ddcom025 compare 2 1 -> 1 +ddcom026 compare 2 2 -> 0 + +ddcom031 compare -20 -20 -> 0 +ddcom032 compare -20 -10 -> -1 +ddcom033 compare -20 00 -> -1 +ddcom034 compare -20 10 -> -1 +ddcom035 compare -20 20 -> -1 +ddcom036 compare -10 -20 -> 1 +ddcom037 compare -10 -10 -> 0 +ddcom038 compare -10 00 -> -1 +ddcom039 compare -10 10 -> -1 +ddcom040 compare -10 20 -> -1 +ddcom041 compare 00 -20 -> 1 +ddcom042 compare 00 -10 -> 1 +ddcom043 compare 00 00 -> 0 +ddcom044 compare 00 10 -> -1 +ddcom045 compare 00 20 -> -1 +ddcom046 compare 10 -20 -> 1 +ddcom047 compare 10 -10 -> 1 +ddcom048 compare 10 00 -> 1 +ddcom049 compare 10 10 -> 0 +ddcom050 compare 10 20 -> -1 +ddcom051 compare 20 -20 -> 1 +ddcom052 compare 20 -10 -> 1 +ddcom053 compare 20 00 -> 1 +ddcom055 compare 20 10 -> 1 +ddcom056 compare 20 20 -> 0 + +ddcom061 compare -2.0 -2.0 -> 0 +ddcom062 compare -2.0 -1.0 -> -1 +ddcom063 compare -2.0 0.0 -> -1 +ddcom064 compare -2.0 1.0 -> -1 +ddcom065 compare -2.0 2.0 -> -1 +ddcom066 compare -1.0 -2.0 -> 1 +ddcom067 compare -1.0 -1.0 -> 0 +ddcom068 compare -1.0 0.0 -> -1 +ddcom069 compare -1.0 1.0 -> -1 +ddcom070 compare -1.0 2.0 -> -1 +ddcom071 compare 0.0 -2.0 -> 1 +ddcom072 compare 0.0 -1.0 -> 1 +ddcom073 compare 0.0 0.0 -> 0 +ddcom074 compare 0.0 1.0 -> -1 +ddcom075 compare 0.0 2.0 -> -1 +ddcom076 compare 1.0 -2.0 -> 1 +ddcom077 compare 1.0 -1.0 -> 1 +ddcom078 compare 1.0 0.0 -> 1 +ddcom079 compare 1.0 1.0 -> 0 +ddcom080 compare 1.0 2.0 -> -1 +ddcom081 compare 2.0 -2.0 -> 1 +ddcom082 compare 2.0 -1.0 -> 1 +ddcom083 compare 2.0 0.0 -> 1 +ddcom085 compare 2.0 1.0 -> 1 +ddcom086 compare 2.0 2.0 -> 0 +ddcom087 compare 1.0 0.1 -> 1 +ddcom088 compare 0.1 1.0 -> -1 + +-- now some cases which might overflow if subtract were used +ddcom095 compare 9.999999999999999E+384 9.999999999999999E+384 -> 0 +ddcom096 compare -9.999999999999999E+384 9.999999999999999E+384 -> -1 +ddcom097 compare 9.999999999999999E+384 -9.999999999999999E+384 -> 1 +ddcom098 compare -9.999999999999999E+384 -9.999999999999999E+384 -> 0 + +-- some differing length/exponent cases +ddcom100 compare 7.0 7.0 -> 0 +ddcom101 compare 7.0 7 -> 0 +ddcom102 compare 7 7.0 -> 0 +ddcom103 compare 7E+0 7.0 -> 0 +ddcom104 compare 70E-1 7.0 -> 0 +ddcom105 compare 0.7E+1 7 -> 0 +ddcom106 compare 70E-1 7 -> 0 +ddcom107 compare 7.0 7E+0 -> 0 +ddcom108 compare 7.0 70E-1 -> 0 +ddcom109 compare 7 0.7E+1 -> 0 +ddcom110 compare 7 70E-1 -> 0 + +ddcom120 compare 8.0 7.0 -> 1 +ddcom121 compare 8.0 7 -> 1 +ddcom122 compare 8 7.0 -> 1 +ddcom123 compare 8E+0 7.0 -> 1 +ddcom124 compare 80E-1 7.0 -> 1 +ddcom125 compare 0.8E+1 7 -> 1 +ddcom126 compare 80E-1 7 -> 1 +ddcom127 compare 8.0 7E+0 -> 1 +ddcom128 compare 8.0 70E-1 -> 1 +ddcom129 compare 8 0.7E+1 -> 1 +ddcom130 compare 8 70E-1 -> 1 + +ddcom140 compare 8.0 9.0 -> -1 +ddcom141 compare 8.0 9 -> -1 +ddcom142 compare 8 9.0 -> -1 +ddcom143 compare 8E+0 9.0 -> -1 +ddcom144 compare 80E-1 9.0 -> -1 +ddcom145 compare 0.8E+1 9 -> -1 +ddcom146 compare 80E-1 9 -> -1 +ddcom147 compare 8.0 9E+0 -> -1 +ddcom148 compare 8.0 90E-1 -> -1 +ddcom149 compare 8 0.9E+1 -> -1 +ddcom150 compare 8 90E-1 -> -1 + +-- and again, with sign changes -+ .. +ddcom200 compare -7.0 7.0 -> -1 +ddcom201 compare -7.0 7 -> -1 +ddcom202 compare -7 7.0 -> -1 +ddcom203 compare -7E+0 7.0 -> -1 +ddcom204 compare -70E-1 7.0 -> -1 +ddcom205 compare -0.7E+1 7 -> -1 +ddcom206 compare -70E-1 7 -> -1 +ddcom207 compare -7.0 7E+0 -> -1 +ddcom208 compare -7.0 70E-1 -> -1 +ddcom209 compare -7 0.7E+1 -> -1 +ddcom210 compare -7 70E-1 -> -1 + +ddcom220 compare -8.0 7.0 -> -1 +ddcom221 compare -8.0 7 -> -1 +ddcom222 compare -8 7.0 -> -1 +ddcom223 compare -8E+0 7.0 -> -1 +ddcom224 compare -80E-1 7.0 -> -1 +ddcom225 compare -0.8E+1 7 -> -1 +ddcom226 compare -80E-1 7 -> -1 +ddcom227 compare -8.0 7E+0 -> -1 +ddcom228 compare -8.0 70E-1 -> -1 +ddcom229 compare -8 0.7E+1 -> -1 +ddcom230 compare -8 70E-1 -> -1 + +ddcom240 compare -8.0 9.0 -> -1 +ddcom241 compare -8.0 9 -> -1 +ddcom242 compare -8 9.0 -> -1 +ddcom243 compare -8E+0 9.0 -> -1 +ddcom244 compare -80E-1 9.0 -> -1 +ddcom245 compare -0.8E+1 9 -> -1 +ddcom246 compare -80E-1 9 -> -1 +ddcom247 compare -8.0 9E+0 -> -1 +ddcom248 compare -8.0 90E-1 -> -1 +ddcom249 compare -8 0.9E+1 -> -1 +ddcom250 compare -8 90E-1 -> -1 + +-- and again, with sign changes +- .. +ddcom300 compare 7.0 -7.0 -> 1 +ddcom301 compare 7.0 -7 -> 1 +ddcom302 compare 7 -7.0 -> 1 +ddcom303 compare 7E+0 -7.0 -> 1 +ddcom304 compare 70E-1 -7.0 -> 1 +ddcom305 compare .7E+1 -7 -> 1 +ddcom306 compare 70E-1 -7 -> 1 +ddcom307 compare 7.0 -7E+0 -> 1 +ddcom308 compare 7.0 -70E-1 -> 1 +ddcom309 compare 7 -.7E+1 -> 1 +ddcom310 compare 7 -70E-1 -> 1 + +ddcom320 compare 8.0 -7.0 -> 1 +ddcom321 compare 8.0 -7 -> 1 +ddcom322 compare 8 -7.0 -> 1 +ddcom323 compare 8E+0 -7.0 -> 1 +ddcom324 compare 80E-1 -7.0 -> 1 +ddcom325 compare .8E+1 -7 -> 1 +ddcom326 compare 80E-1 -7 -> 1 +ddcom327 compare 8.0 -7E+0 -> 1 +ddcom328 compare 8.0 -70E-1 -> 1 +ddcom329 compare 8 -.7E+1 -> 1 +ddcom330 compare 8 -70E-1 -> 1 + +ddcom340 compare 8.0 -9.0 -> 1 +ddcom341 compare 8.0 -9 -> 1 +ddcom342 compare 8 -9.0 -> 1 +ddcom343 compare 8E+0 -9.0 -> 1 +ddcom344 compare 80E-1 -9.0 -> 1 +ddcom345 compare .8E+1 -9 -> 1 +ddcom346 compare 80E-1 -9 -> 1 +ddcom347 compare 8.0 -9E+0 -> 1 +ddcom348 compare 8.0 -90E-1 -> 1 +ddcom349 compare 8 -.9E+1 -> 1 +ddcom350 compare 8 -90E-1 -> 1 + +-- and again, with sign changes -- .. +ddcom400 compare -7.0 -7.0 -> 0 +ddcom401 compare -7.0 -7 -> 0 +ddcom402 compare -7 -7.0 -> 0 +ddcom403 compare -7E+0 -7.0 -> 0 +ddcom404 compare -70E-1 -7.0 -> 0 +ddcom405 compare -.7E+1 -7 -> 0 +ddcom406 compare -70E-1 -7 -> 0 +ddcom407 compare -7.0 -7E+0 -> 0 +ddcom408 compare -7.0 -70E-1 -> 0 +ddcom409 compare -7 -.7E+1 -> 0 +ddcom410 compare -7 -70E-1 -> 0 + +ddcom420 compare -8.0 -7.0 -> -1 +ddcom421 compare -8.0 -7 -> -1 +ddcom422 compare -8 -7.0 -> -1 +ddcom423 compare -8E+0 -7.0 -> -1 +ddcom424 compare -80E-1 -7.0 -> -1 +ddcom425 compare -.8E+1 -7 -> -1 +ddcom426 compare -80E-1 -7 -> -1 +ddcom427 compare -8.0 -7E+0 -> -1 +ddcom428 compare -8.0 -70E-1 -> -1 +ddcom429 compare -8 -.7E+1 -> -1 +ddcom430 compare -8 -70E-1 -> -1 + +ddcom440 compare -8.0 -9.0 -> 1 +ddcom441 compare -8.0 -9 -> 1 +ddcom442 compare -8 -9.0 -> 1 +ddcom443 compare -8E+0 -9.0 -> 1 +ddcom444 compare -80E-1 -9.0 -> 1 +ddcom445 compare -.8E+1 -9 -> 1 +ddcom446 compare -80E-1 -9 -> 1 +ddcom447 compare -8.0 -9E+0 -> 1 +ddcom448 compare -8.0 -90E-1 -> 1 +ddcom449 compare -8 -.9E+1 -> 1 +ddcom450 compare -8 -90E-1 -> 1 + +-- misalignment traps for little-endian +ddcom451 compare 1.0 0.1 -> 1 +ddcom452 compare 0.1 1.0 -> -1 +ddcom453 compare 10.0 0.1 -> 1 +ddcom454 compare 0.1 10.0 -> -1 +ddcom455 compare 100 1.0 -> 1 +ddcom456 compare 1.0 100 -> -1 +ddcom457 compare 1000 10.0 -> 1 +ddcom458 compare 10.0 1000 -> -1 +ddcom459 compare 10000 100.0 -> 1 +ddcom460 compare 100.0 10000 -> -1 +ddcom461 compare 100000 1000.0 -> 1 +ddcom462 compare 1000.0 100000 -> -1 +ddcom463 compare 1000000 10000.0 -> 1 +ddcom464 compare 10000.0 1000000 -> -1 + +-- testcases that subtract to lots of zeros at boundaries [pgr] +ddcom473 compare 123.4560000000000E-89 123.456E-89 -> 0 +ddcom474 compare 123.456000000000E+89 123.456E+89 -> 0 +ddcom475 compare 123.45600000000E-89 123.456E-89 -> 0 +ddcom476 compare 123.4560000000E+89 123.456E+89 -> 0 +ddcom477 compare 123.456000000E-89 123.456E-89 -> 0 +ddcom478 compare 123.45600000E+89 123.456E+89 -> 0 +ddcom479 compare 123.4560000E-89 123.456E-89 -> 0 +ddcom480 compare 123.456000E+89 123.456E+89 -> 0 +ddcom481 compare 123.45600E-89 123.456E-89 -> 0 +ddcom482 compare 123.4560E+89 123.456E+89 -> 0 +ddcom483 compare 123.456E-89 123.456E-89 -> 0 +ddcom487 compare 123.456E+89 123.4560000000000E+89 -> 0 +ddcom488 compare 123.456E-89 123.456000000000E-89 -> 0 +ddcom489 compare 123.456E+89 123.45600000000E+89 -> 0 +ddcom490 compare 123.456E-89 123.4560000000E-89 -> 0 +ddcom491 compare 123.456E+89 123.456000000E+89 -> 0 +ddcom492 compare 123.456E-89 123.45600000E-89 -> 0 +ddcom493 compare 123.456E+89 123.4560000E+89 -> 0 +ddcom494 compare 123.456E-89 123.456000E-89 -> 0 +ddcom495 compare 123.456E+89 123.45600E+89 -> 0 +ddcom496 compare 123.456E-89 123.4560E-89 -> 0 +ddcom497 compare 123.456E+89 123.456E+89 -> 0 + +-- wide-ranging, around precision; signs equal +ddcom500 compare 1 1E-15 -> 1 +ddcom501 compare 1 1E-14 -> 1 +ddcom502 compare 1 1E-13 -> 1 +ddcom503 compare 1 1E-12 -> 1 +ddcom504 compare 1 1E-11 -> 1 +ddcom505 compare 1 1E-10 -> 1 +ddcom506 compare 1 1E-9 -> 1 +ddcom507 compare 1 1E-8 -> 1 +ddcom508 compare 1 1E-7 -> 1 +ddcom509 compare 1 1E-6 -> 1 +ddcom510 compare 1 1E-5 -> 1 +ddcom511 compare 1 1E-4 -> 1 +ddcom512 compare 1 1E-3 -> 1 +ddcom513 compare 1 1E-2 -> 1 +ddcom514 compare 1 1E-1 -> 1 +ddcom515 compare 1 1E-0 -> 0 +ddcom516 compare 1 1E+1 -> -1 +ddcom517 compare 1 1E+2 -> -1 +ddcom518 compare 1 1E+3 -> -1 +ddcom519 compare 1 1E+4 -> -1 +ddcom521 compare 1 1E+5 -> -1 +ddcom522 compare 1 1E+6 -> -1 +ddcom523 compare 1 1E+7 -> -1 +ddcom524 compare 1 1E+8 -> -1 +ddcom525 compare 1 1E+9 -> -1 +ddcom526 compare 1 1E+10 -> -1 +ddcom527 compare 1 1E+11 -> -1 +ddcom528 compare 1 1E+12 -> -1 +ddcom529 compare 1 1E+13 -> -1 +ddcom530 compare 1 1E+14 -> -1 +ddcom531 compare 1 1E+15 -> -1 +-- LR swap +ddcom540 compare 1E-15 1 -> -1 +ddcom541 compare 1E-14 1 -> -1 +ddcom542 compare 1E-13 1 -> -1 +ddcom543 compare 1E-12 1 -> -1 +ddcom544 compare 1E-11 1 -> -1 +ddcom545 compare 1E-10 1 -> -1 +ddcom546 compare 1E-9 1 -> -1 +ddcom547 compare 1E-8 1 -> -1 +ddcom548 compare 1E-7 1 -> -1 +ddcom549 compare 1E-6 1 -> -1 +ddcom550 compare 1E-5 1 -> -1 +ddcom551 compare 1E-4 1 -> -1 +ddcom552 compare 1E-3 1 -> -1 +ddcom553 compare 1E-2 1 -> -1 +ddcom554 compare 1E-1 1 -> -1 +ddcom555 compare 1E-0 1 -> 0 +ddcom556 compare 1E+1 1 -> 1 +ddcom557 compare 1E+2 1 -> 1 +ddcom558 compare 1E+3 1 -> 1 +ddcom559 compare 1E+4 1 -> 1 +ddcom561 compare 1E+5 1 -> 1 +ddcom562 compare 1E+6 1 -> 1 +ddcom563 compare 1E+7 1 -> 1 +ddcom564 compare 1E+8 1 -> 1 +ddcom565 compare 1E+9 1 -> 1 +ddcom566 compare 1E+10 1 -> 1 +ddcom567 compare 1E+11 1 -> 1 +ddcom568 compare 1E+12 1 -> 1 +ddcom569 compare 1E+13 1 -> 1 +ddcom570 compare 1E+14 1 -> 1 +ddcom571 compare 1E+15 1 -> 1 +-- similar with a useful coefficient, one side only +ddcom580 compare 0.000000987654321 1E-15 -> 1 +ddcom581 compare 0.000000987654321 1E-14 -> 1 +ddcom582 compare 0.000000987654321 1E-13 -> 1 +ddcom583 compare 0.000000987654321 1E-12 -> 1 +ddcom584 compare 0.000000987654321 1E-11 -> 1 +ddcom585 compare 0.000000987654321 1E-10 -> 1 +ddcom586 compare 0.000000987654321 1E-9 -> 1 +ddcom587 compare 0.000000987654321 1E-8 -> 1 +ddcom588 compare 0.000000987654321 1E-7 -> 1 +ddcom589 compare 0.000000987654321 1E-6 -> -1 +ddcom590 compare 0.000000987654321 1E-5 -> -1 +ddcom591 compare 0.000000987654321 1E-4 -> -1 +ddcom592 compare 0.000000987654321 1E-3 -> -1 +ddcom593 compare 0.000000987654321 1E-2 -> -1 +ddcom594 compare 0.000000987654321 1E-1 -> -1 +ddcom595 compare 0.000000987654321 1E-0 -> -1 +ddcom596 compare 0.000000987654321 1E+1 -> -1 +ddcom597 compare 0.000000987654321 1E+2 -> -1 +ddcom598 compare 0.000000987654321 1E+3 -> -1 +ddcom599 compare 0.000000987654321 1E+4 -> -1 + +-- check some unit-y traps +ddcom600 compare 12 12.2345 -> -1 +ddcom601 compare 12.0 12.2345 -> -1 +ddcom602 compare 12.00 12.2345 -> -1 +ddcom603 compare 12.000 12.2345 -> -1 +ddcom604 compare 12.0000 12.2345 -> -1 +ddcom605 compare 12.00000 12.2345 -> -1 +ddcom606 compare 12.000000 12.2345 -> -1 +ddcom607 compare 12.0000000 12.2345 -> -1 +ddcom608 compare 12.00000000 12.2345 -> -1 +ddcom609 compare 12.000000000 12.2345 -> -1 +ddcom610 compare 12.1234 12 -> 1 +ddcom611 compare 12.1234 12.0 -> 1 +ddcom612 compare 12.1234 12.00 -> 1 +ddcom613 compare 12.1234 12.000 -> 1 +ddcom614 compare 12.1234 12.0000 -> 1 +ddcom615 compare 12.1234 12.00000 -> 1 +ddcom616 compare 12.1234 12.000000 -> 1 +ddcom617 compare 12.1234 12.0000000 -> 1 +ddcom618 compare 12.1234 12.00000000 -> 1 +ddcom619 compare 12.1234 12.000000000 -> 1 +ddcom620 compare -12 -12.2345 -> 1 +ddcom621 compare -12.0 -12.2345 -> 1 +ddcom622 compare -12.00 -12.2345 -> 1 +ddcom623 compare -12.000 -12.2345 -> 1 +ddcom624 compare -12.0000 -12.2345 -> 1 +ddcom625 compare -12.00000 -12.2345 -> 1 +ddcom626 compare -12.000000 -12.2345 -> 1 +ddcom627 compare -12.0000000 -12.2345 -> 1 +ddcom628 compare -12.00000000 -12.2345 -> 1 +ddcom629 compare -12.000000000 -12.2345 -> 1 +ddcom630 compare -12.1234 -12 -> -1 +ddcom631 compare -12.1234 -12.0 -> -1 +ddcom632 compare -12.1234 -12.00 -> -1 +ddcom633 compare -12.1234 -12.000 -> -1 +ddcom634 compare -12.1234 -12.0000 -> -1 +ddcom635 compare -12.1234 -12.00000 -> -1 +ddcom636 compare -12.1234 -12.000000 -> -1 +ddcom637 compare -12.1234 -12.0000000 -> -1 +ddcom638 compare -12.1234 -12.00000000 -> -1 +ddcom639 compare -12.1234 -12.000000000 -> -1 + +-- extended zeros +ddcom640 compare 0 0 -> 0 +ddcom641 compare 0 -0 -> 0 +ddcom642 compare 0 -0.0 -> 0 +ddcom643 compare 0 0.0 -> 0 +ddcom644 compare -0 0 -> 0 +ddcom645 compare -0 -0 -> 0 +ddcom646 compare -0 -0.0 -> 0 +ddcom647 compare -0 0.0 -> 0 +ddcom648 compare 0.0 0 -> 0 +ddcom649 compare 0.0 -0 -> 0 +ddcom650 compare 0.0 -0.0 -> 0 +ddcom651 compare 0.0 0.0 -> 0 +ddcom652 compare -0.0 0 -> 0 +ddcom653 compare -0.0 -0 -> 0 +ddcom654 compare -0.0 -0.0 -> 0 +ddcom655 compare -0.0 0.0 -> 0 + +ddcom656 compare -0E1 0.0 -> 0 +ddcom657 compare -0E2 0.0 -> 0 +ddcom658 compare 0E1 0.0 -> 0 +ddcom659 compare 0E2 0.0 -> 0 +ddcom660 compare -0E1 0 -> 0 +ddcom661 compare -0E2 0 -> 0 +ddcom662 compare 0E1 0 -> 0 +ddcom663 compare 0E2 0 -> 0 +ddcom664 compare -0E1 -0E1 -> 0 +ddcom665 compare -0E2 -0E1 -> 0 +ddcom666 compare 0E1 -0E1 -> 0 +ddcom667 compare 0E2 -0E1 -> 0 +ddcom668 compare -0E1 -0E2 -> 0 +ddcom669 compare -0E2 -0E2 -> 0 +ddcom670 compare 0E1 -0E2 -> 0 +ddcom671 compare 0E2 -0E2 -> 0 +ddcom672 compare -0E1 0E1 -> 0 +ddcom673 compare -0E2 0E1 -> 0 +ddcom674 compare 0E1 0E1 -> 0 +ddcom675 compare 0E2 0E1 -> 0 +ddcom676 compare -0E1 0E2 -> 0 +ddcom677 compare -0E2 0E2 -> 0 +ddcom678 compare 0E1 0E2 -> 0 +ddcom679 compare 0E2 0E2 -> 0 + +-- trailing zeros; unit-y +ddcom680 compare 12 12 -> 0 +ddcom681 compare 12 12.0 -> 0 +ddcom682 compare 12 12.00 -> 0 +ddcom683 compare 12 12.000 -> 0 +ddcom684 compare 12 12.0000 -> 0 +ddcom685 compare 12 12.00000 -> 0 +ddcom686 compare 12 12.000000 -> 0 +ddcom687 compare 12 12.0000000 -> 0 +ddcom688 compare 12 12.00000000 -> 0 +ddcom689 compare 12 12.000000000 -> 0 +ddcom690 compare 12 12 -> 0 +ddcom691 compare 12.0 12 -> 0 +ddcom692 compare 12.00 12 -> 0 +ddcom693 compare 12.000 12 -> 0 +ddcom694 compare 12.0000 12 -> 0 +ddcom695 compare 12.00000 12 -> 0 +ddcom696 compare 12.000000 12 -> 0 +ddcom697 compare 12.0000000 12 -> 0 +ddcom698 compare 12.00000000 12 -> 0 +ddcom699 compare 12.000000000 12 -> 0 + +-- first, second, & last digit +ddcom700 compare 1234567890123456 1234567890123455 -> 1 +ddcom701 compare 1234567890123456 1234567890123456 -> 0 +ddcom702 compare 1234567890123456 1234567890123457 -> -1 +ddcom703 compare 1234567890123456 0234567890123456 -> 1 +ddcom704 compare 1234567890123456 1234567890123456 -> 0 +ddcom705 compare 1234567890123456 2234567890123456 -> -1 +ddcom706 compare 1134567890123456 1034567890123456 -> 1 +ddcom707 compare 1134567890123456 1134567890123456 -> 0 +ddcom708 compare 1134567890123456 1234567890123456 -> -1 + +-- miscellaneous +ddcom721 compare 12345678000 1 -> 1 +ddcom722 compare 1 12345678000 -> -1 +ddcom723 compare 1234567800 1 -> 1 +ddcom724 compare 1 1234567800 -> -1 +ddcom725 compare 1234567890 1 -> 1 +ddcom726 compare 1 1234567890 -> -1 +ddcom727 compare 1234567891 1 -> 1 +ddcom728 compare 1 1234567891 -> -1 +ddcom729 compare 12345678901 1 -> 1 +ddcom730 compare 1 12345678901 -> -1 +ddcom731 compare 1234567896 1 -> 1 +ddcom732 compare 1 1234567896 -> -1 + +-- residue cases at lower precision +ddcom740 compare 1 0.9999999 -> 1 +ddcom741 compare 1 0.999999 -> 1 +ddcom742 compare 1 0.99999 -> 1 +ddcom743 compare 1 1.0000 -> 0 +ddcom744 compare 1 1.00001 -> -1 +ddcom745 compare 1 1.000001 -> -1 +ddcom746 compare 1 1.0000001 -> -1 +ddcom750 compare 0.9999999 1 -> -1 +ddcom751 compare 0.999999 1 -> -1 +ddcom752 compare 0.99999 1 -> -1 +ddcom753 compare 1.0000 1 -> 0 +ddcom754 compare 1.00001 1 -> 1 +ddcom755 compare 1.000001 1 -> 1 +ddcom756 compare 1.0000001 1 -> 1 + +-- Specials +ddcom780 compare Inf -Inf -> 1 +ddcom781 compare Inf -1000 -> 1 +ddcom782 compare Inf -1 -> 1 +ddcom783 compare Inf -0 -> 1 +ddcom784 compare Inf 0 -> 1 +ddcom785 compare Inf 1 -> 1 +ddcom786 compare Inf 1000 -> 1 +ddcom787 compare Inf Inf -> 0 +ddcom788 compare -1000 Inf -> -1 +ddcom789 compare -Inf Inf -> -1 +ddcom790 compare -1 Inf -> -1 +ddcom791 compare -0 Inf -> -1 +ddcom792 compare 0 Inf -> -1 +ddcom793 compare 1 Inf -> -1 +ddcom794 compare 1000 Inf -> -1 +ddcom795 compare Inf Inf -> 0 + +ddcom800 compare -Inf -Inf -> 0 +ddcom801 compare -Inf -1000 -> -1 +ddcom802 compare -Inf -1 -> -1 +ddcom803 compare -Inf -0 -> -1 +ddcom804 compare -Inf 0 -> -1 +ddcom805 compare -Inf 1 -> -1 +ddcom806 compare -Inf 1000 -> -1 +ddcom807 compare -Inf Inf -> -1 +ddcom808 compare -Inf -Inf -> 0 +ddcom809 compare -1000 -Inf -> 1 +ddcom810 compare -1 -Inf -> 1 +ddcom811 compare -0 -Inf -> 1 +ddcom812 compare 0 -Inf -> 1 +ddcom813 compare 1 -Inf -> 1 +ddcom814 compare 1000 -Inf -> 1 +ddcom815 compare Inf -Inf -> 1 + +ddcom821 compare NaN -Inf -> NaN +ddcom822 compare NaN -1000 -> NaN +ddcom823 compare NaN -1 -> NaN +ddcom824 compare NaN -0 -> NaN +ddcom825 compare NaN 0 -> NaN +ddcom826 compare NaN 1 -> NaN +ddcom827 compare NaN 1000 -> NaN +ddcom828 compare NaN Inf -> NaN +ddcom829 compare NaN NaN -> NaN +ddcom830 compare -Inf NaN -> NaN +ddcom831 compare -1000 NaN -> NaN +ddcom832 compare -1 NaN -> NaN +ddcom833 compare -0 NaN -> NaN +ddcom834 compare 0 NaN -> NaN +ddcom835 compare 1 NaN -> NaN +ddcom836 compare 1000 NaN -> NaN +ddcom837 compare Inf NaN -> NaN +ddcom838 compare -NaN -NaN -> -NaN +ddcom839 compare +NaN -NaN -> NaN +ddcom840 compare -NaN +NaN -> -NaN + +ddcom841 compare sNaN -Inf -> NaN Invalid_operation +ddcom842 compare sNaN -1000 -> NaN Invalid_operation +ddcom843 compare sNaN -1 -> NaN Invalid_operation +ddcom844 compare sNaN -0 -> NaN Invalid_operation +ddcom845 compare sNaN 0 -> NaN Invalid_operation +ddcom846 compare sNaN 1 -> NaN Invalid_operation +ddcom847 compare sNaN 1000 -> NaN Invalid_operation +ddcom848 compare sNaN NaN -> NaN Invalid_operation +ddcom849 compare sNaN sNaN -> NaN Invalid_operation +ddcom850 compare NaN sNaN -> NaN Invalid_operation +ddcom851 compare -Inf sNaN -> NaN Invalid_operation +ddcom852 compare -1000 sNaN -> NaN Invalid_operation +ddcom853 compare -1 sNaN -> NaN Invalid_operation +ddcom854 compare -0 sNaN -> NaN Invalid_operation +ddcom855 compare 0 sNaN -> NaN Invalid_operation +ddcom856 compare 1 sNaN -> NaN Invalid_operation +ddcom857 compare 1000 sNaN -> NaN Invalid_operation +ddcom858 compare Inf sNaN -> NaN Invalid_operation +ddcom859 compare NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +ddcom860 compare NaN9 -Inf -> NaN9 +ddcom861 compare NaN8 999 -> NaN8 +ddcom862 compare NaN77 Inf -> NaN77 +ddcom863 compare -NaN67 NaN5 -> -NaN67 +ddcom864 compare -Inf -NaN4 -> -NaN4 +ddcom865 compare -999 -NaN33 -> -NaN33 +ddcom866 compare Inf NaN2 -> NaN2 +ddcom867 compare -NaN41 -NaN42 -> -NaN41 +ddcom868 compare +NaN41 -NaN42 -> NaN41 +ddcom869 compare -NaN41 +NaN42 -> -NaN41 +ddcom870 compare +NaN41 +NaN42 -> NaN41 + +ddcom871 compare -sNaN99 -Inf -> -NaN99 Invalid_operation +ddcom872 compare sNaN98 -11 -> NaN98 Invalid_operation +ddcom873 compare sNaN97 NaN -> NaN97 Invalid_operation +ddcom874 compare sNaN16 sNaN94 -> NaN16 Invalid_operation +ddcom875 compare NaN85 sNaN83 -> NaN83 Invalid_operation +ddcom876 compare -Inf sNaN92 -> NaN92 Invalid_operation +ddcom877 compare 088 sNaN81 -> NaN81 Invalid_operation +ddcom878 compare Inf sNaN90 -> NaN90 Invalid_operation +ddcom879 compare NaN -sNaN89 -> -NaN89 Invalid_operation + +-- wide range +ddcom880 compare +1.23456789012345E-0 9E+384 -> -1 +ddcom881 compare 9E+384 +1.23456789012345E-0 -> 1 +ddcom882 compare +0.100 9E-383 -> 1 +ddcom883 compare 9E-383 +0.100 -> -1 +ddcom885 compare -1.23456789012345E-0 9E+384 -> -1 +ddcom886 compare 9E+384 -1.23456789012345E-0 -> 1 +ddcom887 compare -0.100 9E-383 -> -1 +ddcom888 compare 9E-383 -0.100 -> 1 + +-- spread zeros +ddcom900 compare 0E-383 0 -> 0 +ddcom901 compare 0E-383 -0 -> 0 +ddcom902 compare -0E-383 0 -> 0 +ddcom903 compare -0E-383 -0 -> 0 +ddcom904 compare 0E-383 0E+384 -> 0 +ddcom905 compare 0E-383 -0E+384 -> 0 +ddcom906 compare -0E-383 0E+384 -> 0 +ddcom907 compare -0E-383 -0E+384 -> 0 +ddcom908 compare 0 0E+384 -> 0 +ddcom909 compare 0 -0E+384 -> 0 +ddcom910 compare -0 0E+384 -> 0 +ddcom911 compare -0 -0E+384 -> 0 +ddcom930 compare 0E+384 0 -> 0 +ddcom931 compare 0E+384 -0 -> 0 +ddcom932 compare -0E+384 0 -> 0 +ddcom933 compare -0E+384 -0 -> 0 +ddcom934 compare 0E+384 0E-383 -> 0 +ddcom935 compare 0E+384 -0E-383 -> 0 +ddcom936 compare -0E+384 0E-383 -> 0 +ddcom937 compare -0E+384 -0E-383 -> 0 +ddcom938 compare 0 0E-383 -> 0 +ddcom939 compare 0 -0E-383 -> 0 +ddcom940 compare -0 0E-383 -> 0 +ddcom941 compare -0 -0E-383 -> 0 + +-- signs +ddcom961 compare 1e+77 1e+11 -> 1 +ddcom962 compare 1e+77 -1e+11 -> 1 +ddcom963 compare -1e+77 1e+11 -> -1 +ddcom964 compare -1e+77 -1e+11 -> -1 +ddcom965 compare 1e-77 1e-11 -> -1 +ddcom966 compare 1e-77 -1e-11 -> 1 +ddcom967 compare -1e-77 1e-11 -> -1 +ddcom968 compare -1e-77 -1e-11 -> 1 + +-- full alignment range, both ways +ddcomp1001 compare 1 1.000000000000000 -> 0 +ddcomp1002 compare 1 1.00000000000000 -> 0 +ddcomp1003 compare 1 1.0000000000000 -> 0 +ddcomp1004 compare 1 1.000000000000 -> 0 +ddcomp1005 compare 1 1.00000000000 -> 0 +ddcomp1006 compare 1 1.0000000000 -> 0 +ddcomp1007 compare 1 1.000000000 -> 0 +ddcomp1008 compare 1 1.00000000 -> 0 +ddcomp1009 compare 1 1.0000000 -> 0 +ddcomp1010 compare 1 1.000000 -> 0 +ddcomp1011 compare 1 1.00000 -> 0 +ddcomp1012 compare 1 1.0000 -> 0 +ddcomp1013 compare 1 1.000 -> 0 +ddcomp1014 compare 1 1.00 -> 0 +ddcomp1015 compare 1 1.0 -> 0 +ddcomp1021 compare 1.000000000000000 1 -> 0 +ddcomp1022 compare 1.00000000000000 1 -> 0 +ddcomp1023 compare 1.0000000000000 1 -> 0 +ddcomp1024 compare 1.000000000000 1 -> 0 +ddcomp1025 compare 1.00000000000 1 -> 0 +ddcomp1026 compare 1.0000000000 1 -> 0 +ddcomp1027 compare 1.000000000 1 -> 0 +ddcomp1028 compare 1.00000000 1 -> 0 +ddcomp1029 compare 1.0000000 1 -> 0 +ddcomp1030 compare 1.000000 1 -> 0 +ddcomp1031 compare 1.00000 1 -> 0 +ddcomp1032 compare 1.0000 1 -> 0 +ddcomp1033 compare 1.000 1 -> 0 +ddcomp1034 compare 1.00 1 -> 0 +ddcomp1035 compare 1.0 1 -> 0 + +-- check MSD always detected non-zero +ddcomp1040 compare 0 0.000000000000000 -> 0 +ddcomp1041 compare 0 1.000000000000000 -> -1 +ddcomp1042 compare 0 2.000000000000000 -> -1 +ddcomp1043 compare 0 3.000000000000000 -> -1 +ddcomp1044 compare 0 4.000000000000000 -> -1 +ddcomp1045 compare 0 5.000000000000000 -> -1 +ddcomp1046 compare 0 6.000000000000000 -> -1 +ddcomp1047 compare 0 7.000000000000000 -> -1 +ddcomp1048 compare 0 8.000000000000000 -> -1 +ddcomp1049 compare 0 9.000000000000000 -> -1 +ddcomp1050 compare 0.000000000000000 0 -> 0 +ddcomp1051 compare 1.000000000000000 0 -> 1 +ddcomp1052 compare 2.000000000000000 0 -> 1 +ddcomp1053 compare 3.000000000000000 0 -> 1 +ddcomp1054 compare 4.000000000000000 0 -> 1 +ddcomp1055 compare 5.000000000000000 0 -> 1 +ddcomp1056 compare 6.000000000000000 0 -> 1 +ddcomp1057 compare 7.000000000000000 0 -> 1 +ddcomp1058 compare 8.000000000000000 0 -> 1 +ddcomp1059 compare 9.000000000000000 0 -> 1 + +-- Null tests +ddcom9990 compare 10 # -> NaN Invalid_operation +ddcom9991 compare # 10 -> NaN Invalid_operation Added: python/branches/release25-maint/Lib/test/decimaltestdata/ddCompareSig.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/ddCompareSig.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,647 @@ +------------------------------------------------------------------------ +-- ddCompareSig.decTest -- decDouble comparison; all NaNs signal -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- Note that we cannot assume add/subtract tests cover paths adequately, +-- here, because the code might be quite different (comparison cannot +-- overflow or underflow, so actual subtractions are not necessary). + +-- All operands and results are decDoubles. +precision: 16 +maxExponent: 384 +minExponent: -383 +extended: 1 +clamp: 1 +rounding: half_even + +-- sanity checks +ddcms001 comparesig -2 -2 -> 0 +ddcms002 comparesig -2 -1 -> -1 +ddcms003 comparesig -2 0 -> -1 +ddcms004 comparesig -2 1 -> -1 +ddcms005 comparesig -2 2 -> -1 +ddcms006 comparesig -1 -2 -> 1 +ddcms007 comparesig -1 -1 -> 0 +ddcms008 comparesig -1 0 -> -1 +ddcms009 comparesig -1 1 -> -1 +ddcms010 comparesig -1 2 -> -1 +ddcms011 comparesig 0 -2 -> 1 +ddcms012 comparesig 0 -1 -> 1 +ddcms013 comparesig 0 0 -> 0 +ddcms014 comparesig 0 1 -> -1 +ddcms015 comparesig 0 2 -> -1 +ddcms016 comparesig 1 -2 -> 1 +ddcms017 comparesig 1 -1 -> 1 +ddcms018 comparesig 1 0 -> 1 +ddcms019 comparesig 1 1 -> 0 +ddcms020 comparesig 1 2 -> -1 +ddcms021 comparesig 2 -2 -> 1 +ddcms022 comparesig 2 -1 -> 1 +ddcms023 comparesig 2 0 -> 1 +ddcms025 comparesig 2 1 -> 1 +ddcms026 comparesig 2 2 -> 0 + +ddcms031 comparesig -20 -20 -> 0 +ddcms032 comparesig -20 -10 -> -1 +ddcms033 comparesig -20 00 -> -1 +ddcms034 comparesig -20 10 -> -1 +ddcms035 comparesig -20 20 -> -1 +ddcms036 comparesig -10 -20 -> 1 +ddcms037 comparesig -10 -10 -> 0 +ddcms038 comparesig -10 00 -> -1 +ddcms039 comparesig -10 10 -> -1 +ddcms040 comparesig -10 20 -> -1 +ddcms041 comparesig 00 -20 -> 1 +ddcms042 comparesig 00 -10 -> 1 +ddcms043 comparesig 00 00 -> 0 +ddcms044 comparesig 00 10 -> -1 +ddcms045 comparesig 00 20 -> -1 +ddcms046 comparesig 10 -20 -> 1 +ddcms047 comparesig 10 -10 -> 1 +ddcms048 comparesig 10 00 -> 1 +ddcms049 comparesig 10 10 -> 0 +ddcms050 comparesig 10 20 -> -1 +ddcms051 comparesig 20 -20 -> 1 +ddcms052 comparesig 20 -10 -> 1 +ddcms053 comparesig 20 00 -> 1 +ddcms055 comparesig 20 10 -> 1 +ddcms056 comparesig 20 20 -> 0 + +ddcms061 comparesig -2.0 -2.0 -> 0 +ddcms062 comparesig -2.0 -1.0 -> -1 +ddcms063 comparesig -2.0 0.0 -> -1 +ddcms064 comparesig -2.0 1.0 -> -1 +ddcms065 comparesig -2.0 2.0 -> -1 +ddcms066 comparesig -1.0 -2.0 -> 1 +ddcms067 comparesig -1.0 -1.0 -> 0 +ddcms068 comparesig -1.0 0.0 -> -1 +ddcms069 comparesig -1.0 1.0 -> -1 +ddcms070 comparesig -1.0 2.0 -> -1 +ddcms071 comparesig 0.0 -2.0 -> 1 +ddcms072 comparesig 0.0 -1.0 -> 1 +ddcms073 comparesig 0.0 0.0 -> 0 +ddcms074 comparesig 0.0 1.0 -> -1 +ddcms075 comparesig 0.0 2.0 -> -1 +ddcms076 comparesig 1.0 -2.0 -> 1 +ddcms077 comparesig 1.0 -1.0 -> 1 +ddcms078 comparesig 1.0 0.0 -> 1 +ddcms079 comparesig 1.0 1.0 -> 0 +ddcms080 comparesig 1.0 2.0 -> -1 +ddcms081 comparesig 2.0 -2.0 -> 1 +ddcms082 comparesig 2.0 -1.0 -> 1 +ddcms083 comparesig 2.0 0.0 -> 1 +ddcms085 comparesig 2.0 1.0 -> 1 +ddcms086 comparesig 2.0 2.0 -> 0 + +-- now some cases which might overflow if subtract were used +ddcms090 comparesig 9.999999999999999E+384 9.999999999999999E+384 -> 0 +ddcms091 comparesig -9.999999999999999E+384 9.999999999999999E+384 -> -1 +ddcms092 comparesig 9.999999999999999E+384 -9.999999999999999E+384 -> 1 +ddcms093 comparesig -9.999999999999999E+384 -9.999999999999999E+384 -> 0 + +-- some differing length/exponent cases +ddcms100 comparesig 7.0 7.0 -> 0 +ddcms101 comparesig 7.0 7 -> 0 +ddcms102 comparesig 7 7.0 -> 0 +ddcms103 comparesig 7E+0 7.0 -> 0 +ddcms104 comparesig 70E-1 7.0 -> 0 +ddcms105 comparesig 0.7E+1 7 -> 0 +ddcms106 comparesig 70E-1 7 -> 0 +ddcms107 comparesig 7.0 7E+0 -> 0 +ddcms108 comparesig 7.0 70E-1 -> 0 +ddcms109 comparesig 7 0.7E+1 -> 0 +ddcms110 comparesig 7 70E-1 -> 0 + +ddcms120 comparesig 8.0 7.0 -> 1 +ddcms121 comparesig 8.0 7 -> 1 +ddcms122 comparesig 8 7.0 -> 1 +ddcms123 comparesig 8E+0 7.0 -> 1 +ddcms124 comparesig 80E-1 7.0 -> 1 +ddcms125 comparesig 0.8E+1 7 -> 1 +ddcms126 comparesig 80E-1 7 -> 1 +ddcms127 comparesig 8.0 7E+0 -> 1 +ddcms128 comparesig 8.0 70E-1 -> 1 +ddcms129 comparesig 8 0.7E+1 -> 1 +ddcms130 comparesig 8 70E-1 -> 1 + +ddcms140 comparesig 8.0 9.0 -> -1 +ddcms141 comparesig 8.0 9 -> -1 +ddcms142 comparesig 8 9.0 -> -1 +ddcms143 comparesig 8E+0 9.0 -> -1 +ddcms144 comparesig 80E-1 9.0 -> -1 +ddcms145 comparesig 0.8E+1 9 -> -1 +ddcms146 comparesig 80E-1 9 -> -1 +ddcms147 comparesig 8.0 9E+0 -> -1 +ddcms148 comparesig 8.0 90E-1 -> -1 +ddcms149 comparesig 8 0.9E+1 -> -1 +ddcms150 comparesig 8 90E-1 -> -1 + +-- and again, with sign changes -+ .. +ddcms200 comparesig -7.0 7.0 -> -1 +ddcms201 comparesig -7.0 7 -> -1 +ddcms202 comparesig -7 7.0 -> -1 +ddcms203 comparesig -7E+0 7.0 -> -1 +ddcms204 comparesig -70E-1 7.0 -> -1 +ddcms205 comparesig -0.7E+1 7 -> -1 +ddcms206 comparesig -70E-1 7 -> -1 +ddcms207 comparesig -7.0 7E+0 -> -1 +ddcms208 comparesig -7.0 70E-1 -> -1 +ddcms209 comparesig -7 0.7E+1 -> -1 +ddcms210 comparesig -7 70E-1 -> -1 + +ddcms220 comparesig -8.0 7.0 -> -1 +ddcms221 comparesig -8.0 7 -> -1 +ddcms222 comparesig -8 7.0 -> -1 +ddcms223 comparesig -8E+0 7.0 -> -1 +ddcms224 comparesig -80E-1 7.0 -> -1 +ddcms225 comparesig -0.8E+1 7 -> -1 +ddcms226 comparesig -80E-1 7 -> -1 +ddcms227 comparesig -8.0 7E+0 -> -1 +ddcms228 comparesig -8.0 70E-1 -> -1 +ddcms229 comparesig -8 0.7E+1 -> -1 +ddcms230 comparesig -8 70E-1 -> -1 + +ddcms240 comparesig -8.0 9.0 -> -1 +ddcms241 comparesig -8.0 9 -> -1 +ddcms242 comparesig -8 9.0 -> -1 +ddcms243 comparesig -8E+0 9.0 -> -1 +ddcms244 comparesig -80E-1 9.0 -> -1 +ddcms245 comparesig -0.8E+1 9 -> -1 +ddcms246 comparesig -80E-1 9 -> -1 +ddcms247 comparesig -8.0 9E+0 -> -1 +ddcms248 comparesig -8.0 90E-1 -> -1 +ddcms249 comparesig -8 0.9E+1 -> -1 +ddcms250 comparesig -8 90E-1 -> -1 + +-- and again, with sign changes +- .. +ddcms300 comparesig 7.0 -7.0 -> 1 +ddcms301 comparesig 7.0 -7 -> 1 +ddcms302 comparesig 7 -7.0 -> 1 +ddcms303 comparesig 7E+0 -7.0 -> 1 +ddcms304 comparesig 70E-1 -7.0 -> 1 +ddcms305 comparesig .7E+1 -7 -> 1 +ddcms306 comparesig 70E-1 -7 -> 1 +ddcms307 comparesig 7.0 -7E+0 -> 1 +ddcms308 comparesig 7.0 -70E-1 -> 1 +ddcms309 comparesig 7 -.7E+1 -> 1 +ddcms310 comparesig 7 -70E-1 -> 1 + +ddcms320 comparesig 8.0 -7.0 -> 1 +ddcms321 comparesig 8.0 -7 -> 1 +ddcms322 comparesig 8 -7.0 -> 1 +ddcms323 comparesig 8E+0 -7.0 -> 1 +ddcms324 comparesig 80E-1 -7.0 -> 1 +ddcms325 comparesig .8E+1 -7 -> 1 +ddcms326 comparesig 80E-1 -7 -> 1 +ddcms327 comparesig 8.0 -7E+0 -> 1 +ddcms328 comparesig 8.0 -70E-1 -> 1 +ddcms329 comparesig 8 -.7E+1 -> 1 +ddcms330 comparesig 8 -70E-1 -> 1 + +ddcms340 comparesig 8.0 -9.0 -> 1 +ddcms341 comparesig 8.0 -9 -> 1 +ddcms342 comparesig 8 -9.0 -> 1 +ddcms343 comparesig 8E+0 -9.0 -> 1 +ddcms344 comparesig 80E-1 -9.0 -> 1 +ddcms345 comparesig .8E+1 -9 -> 1 +ddcms346 comparesig 80E-1 -9 -> 1 +ddcms347 comparesig 8.0 -9E+0 -> 1 +ddcms348 comparesig 8.0 -90E-1 -> 1 +ddcms349 comparesig 8 -.9E+1 -> 1 +ddcms350 comparesig 8 -90E-1 -> 1 + +-- and again, with sign changes -- .. +ddcms400 comparesig -7.0 -7.0 -> 0 +ddcms401 comparesig -7.0 -7 -> 0 +ddcms402 comparesig -7 -7.0 -> 0 +ddcms403 comparesig -7E+0 -7.0 -> 0 +ddcms404 comparesig -70E-1 -7.0 -> 0 +ddcms405 comparesig -.7E+1 -7 -> 0 +ddcms406 comparesig -70E-1 -7 -> 0 +ddcms407 comparesig -7.0 -7E+0 -> 0 +ddcms408 comparesig -7.0 -70E-1 -> 0 +ddcms409 comparesig -7 -.7E+1 -> 0 +ddcms410 comparesig -7 -70E-1 -> 0 + +ddcms420 comparesig -8.0 -7.0 -> -1 +ddcms421 comparesig -8.0 -7 -> -1 +ddcms422 comparesig -8 -7.0 -> -1 +ddcms423 comparesig -8E+0 -7.0 -> -1 +ddcms424 comparesig -80E-1 -7.0 -> -1 +ddcms425 comparesig -.8E+1 -7 -> -1 +ddcms426 comparesig -80E-1 -7 -> -1 +ddcms427 comparesig -8.0 -7E+0 -> -1 +ddcms428 comparesig -8.0 -70E-1 -> -1 +ddcms429 comparesig -8 -.7E+1 -> -1 +ddcms430 comparesig -8 -70E-1 -> -1 + +ddcms440 comparesig -8.0 -9.0 -> 1 +ddcms441 comparesig -8.0 -9 -> 1 +ddcms442 comparesig -8 -9.0 -> 1 +ddcms443 comparesig -8E+0 -9.0 -> 1 +ddcms444 comparesig -80E-1 -9.0 -> 1 +ddcms445 comparesig -.8E+1 -9 -> 1 +ddcms446 comparesig -80E-1 -9 -> 1 +ddcms447 comparesig -8.0 -9E+0 -> 1 +ddcms448 comparesig -8.0 -90E-1 -> 1 +ddcms449 comparesig -8 -.9E+1 -> 1 +ddcms450 comparesig -8 -90E-1 -> 1 + + +-- testcases that subtract to lots of zeros at boundaries [pgr] +ddcms473 comparesig 123.4560000000000E-89 123.456E-89 -> 0 +ddcms474 comparesig 123.456000000000E+89 123.456E+89 -> 0 +ddcms475 comparesig 123.45600000000E-89 123.456E-89 -> 0 +ddcms476 comparesig 123.4560000000E+89 123.456E+89 -> 0 +ddcms477 comparesig 123.456000000E-89 123.456E-89 -> 0 +ddcms478 comparesig 123.45600000E+89 123.456E+89 -> 0 +ddcms479 comparesig 123.4560000E-89 123.456E-89 -> 0 +ddcms480 comparesig 123.456000E+89 123.456E+89 -> 0 +ddcms481 comparesig 123.45600E-89 123.456E-89 -> 0 +ddcms482 comparesig 123.4560E+89 123.456E+89 -> 0 +ddcms483 comparesig 123.456E-89 123.456E-89 -> 0 +ddcms487 comparesig 123.456E+89 123.4560000000000E+89 -> 0 +ddcms488 comparesig 123.456E-89 123.456000000000E-89 -> 0 +ddcms489 comparesig 123.456E+89 123.45600000000E+89 -> 0 +ddcms490 comparesig 123.456E-89 123.4560000000E-89 -> 0 +ddcms491 comparesig 123.456E+89 123.456000000E+89 -> 0 +ddcms492 comparesig 123.456E-89 123.45600000E-89 -> 0 +ddcms493 comparesig 123.456E+89 123.4560000E+89 -> 0 +ddcms494 comparesig 123.456E-89 123.456000E-89 -> 0 +ddcms495 comparesig 123.456E+89 123.45600E+89 -> 0 +ddcms496 comparesig 123.456E-89 123.4560E-89 -> 0 +ddcms497 comparesig 123.456E+89 123.456E+89 -> 0 + +-- wide-ranging, around precision; signs equal +ddcms500 comparesig 1 1E-15 -> 1 +ddcms501 comparesig 1 1E-14 -> 1 +ddcms502 comparesig 1 1E-13 -> 1 +ddcms503 comparesig 1 1E-12 -> 1 +ddcms504 comparesig 1 1E-11 -> 1 +ddcms505 comparesig 1 1E-10 -> 1 +ddcms506 comparesig 1 1E-9 -> 1 +ddcms507 comparesig 1 1E-8 -> 1 +ddcms508 comparesig 1 1E-7 -> 1 +ddcms509 comparesig 1 1E-6 -> 1 +ddcms510 comparesig 1 1E-5 -> 1 +ddcms511 comparesig 1 1E-4 -> 1 +ddcms512 comparesig 1 1E-3 -> 1 +ddcms513 comparesig 1 1E-2 -> 1 +ddcms514 comparesig 1 1E-1 -> 1 +ddcms515 comparesig 1 1E-0 -> 0 +ddcms516 comparesig 1 1E+1 -> -1 +ddcms517 comparesig 1 1E+2 -> -1 +ddcms518 comparesig 1 1E+3 -> -1 +ddcms519 comparesig 1 1E+4 -> -1 +ddcms521 comparesig 1 1E+5 -> -1 +ddcms522 comparesig 1 1E+6 -> -1 +ddcms523 comparesig 1 1E+7 -> -1 +ddcms524 comparesig 1 1E+8 -> -1 +ddcms525 comparesig 1 1E+9 -> -1 +ddcms526 comparesig 1 1E+10 -> -1 +ddcms527 comparesig 1 1E+11 -> -1 +ddcms528 comparesig 1 1E+12 -> -1 +ddcms529 comparesig 1 1E+13 -> -1 +ddcms530 comparesig 1 1E+14 -> -1 +ddcms531 comparesig 1 1E+15 -> -1 +-- LR swap +ddcms540 comparesig 1E-15 1 -> -1 +ddcms541 comparesig 1E-14 1 -> -1 +ddcms542 comparesig 1E-13 1 -> -1 +ddcms543 comparesig 1E-12 1 -> -1 +ddcms544 comparesig 1E-11 1 -> -1 +ddcms545 comparesig 1E-10 1 -> -1 +ddcms546 comparesig 1E-9 1 -> -1 +ddcms547 comparesig 1E-8 1 -> -1 +ddcms548 comparesig 1E-7 1 -> -1 +ddcms549 comparesig 1E-6 1 -> -1 +ddcms550 comparesig 1E-5 1 -> -1 +ddcms551 comparesig 1E-4 1 -> -1 +ddcms552 comparesig 1E-3 1 -> -1 +ddcms553 comparesig 1E-2 1 -> -1 +ddcms554 comparesig 1E-1 1 -> -1 +ddcms555 comparesig 1E-0 1 -> 0 +ddcms556 comparesig 1E+1 1 -> 1 +ddcms557 comparesig 1E+2 1 -> 1 +ddcms558 comparesig 1E+3 1 -> 1 +ddcms559 comparesig 1E+4 1 -> 1 +ddcms561 comparesig 1E+5 1 -> 1 +ddcms562 comparesig 1E+6 1 -> 1 +ddcms563 comparesig 1E+7 1 -> 1 +ddcms564 comparesig 1E+8 1 -> 1 +ddcms565 comparesig 1E+9 1 -> 1 +ddcms566 comparesig 1E+10 1 -> 1 +ddcms567 comparesig 1E+11 1 -> 1 +ddcms568 comparesig 1E+12 1 -> 1 +ddcms569 comparesig 1E+13 1 -> 1 +ddcms570 comparesig 1E+14 1 -> 1 +ddcms571 comparesig 1E+15 1 -> 1 +-- similar with a useful coefficient, one side only +ddcms580 comparesig 0.000000987654321 1E-15 -> 1 +ddcms581 comparesig 0.000000987654321 1E-14 -> 1 +ddcms582 comparesig 0.000000987654321 1E-13 -> 1 +ddcms583 comparesig 0.000000987654321 1E-12 -> 1 +ddcms584 comparesig 0.000000987654321 1E-11 -> 1 +ddcms585 comparesig 0.000000987654321 1E-10 -> 1 +ddcms586 comparesig 0.000000987654321 1E-9 -> 1 +ddcms587 comparesig 0.000000987654321 1E-8 -> 1 +ddcms588 comparesig 0.000000987654321 1E-7 -> 1 +ddcms589 comparesig 0.000000987654321 1E-6 -> -1 +ddcms590 comparesig 0.000000987654321 1E-5 -> -1 +ddcms591 comparesig 0.000000987654321 1E-4 -> -1 +ddcms592 comparesig 0.000000987654321 1E-3 -> -1 +ddcms593 comparesig 0.000000987654321 1E-2 -> -1 +ddcms594 comparesig 0.000000987654321 1E-1 -> -1 +ddcms595 comparesig 0.000000987654321 1E-0 -> -1 +ddcms596 comparesig 0.000000987654321 1E+1 -> -1 +ddcms597 comparesig 0.000000987654321 1E+2 -> -1 +ddcms598 comparesig 0.000000987654321 1E+3 -> -1 +ddcms599 comparesig 0.000000987654321 1E+4 -> -1 + +-- check some unit-y traps +ddcms600 comparesig 12 12.2345 -> -1 +ddcms601 comparesig 12.0 12.2345 -> -1 +ddcms602 comparesig 12.00 12.2345 -> -1 +ddcms603 comparesig 12.000 12.2345 -> -1 +ddcms604 comparesig 12.0000 12.2345 -> -1 +ddcms605 comparesig 12.00000 12.2345 -> -1 +ddcms606 comparesig 12.000000 12.2345 -> -1 +ddcms607 comparesig 12.0000000 12.2345 -> -1 +ddcms608 comparesig 12.00000000 12.2345 -> -1 +ddcms609 comparesig 12.000000000 12.2345 -> -1 +ddcms610 comparesig 12.1234 12 -> 1 +ddcms611 comparesig 12.1234 12.0 -> 1 +ddcms612 comparesig 12.1234 12.00 -> 1 +ddcms613 comparesig 12.1234 12.000 -> 1 +ddcms614 comparesig 12.1234 12.0000 -> 1 +ddcms615 comparesig 12.1234 12.00000 -> 1 +ddcms616 comparesig 12.1234 12.000000 -> 1 +ddcms617 comparesig 12.1234 12.0000000 -> 1 +ddcms618 comparesig 12.1234 12.00000000 -> 1 +ddcms619 comparesig 12.1234 12.000000000 -> 1 +ddcms620 comparesig -12 -12.2345 -> 1 +ddcms621 comparesig -12.0 -12.2345 -> 1 +ddcms622 comparesig -12.00 -12.2345 -> 1 +ddcms623 comparesig -12.000 -12.2345 -> 1 +ddcms624 comparesig -12.0000 -12.2345 -> 1 +ddcms625 comparesig -12.00000 -12.2345 -> 1 +ddcms626 comparesig -12.000000 -12.2345 -> 1 +ddcms627 comparesig -12.0000000 -12.2345 -> 1 +ddcms628 comparesig -12.00000000 -12.2345 -> 1 +ddcms629 comparesig -12.000000000 -12.2345 -> 1 +ddcms630 comparesig -12.1234 -12 -> -1 +ddcms631 comparesig -12.1234 -12.0 -> -1 +ddcms632 comparesig -12.1234 -12.00 -> -1 +ddcms633 comparesig -12.1234 -12.000 -> -1 +ddcms634 comparesig -12.1234 -12.0000 -> -1 +ddcms635 comparesig -12.1234 -12.00000 -> -1 +ddcms636 comparesig -12.1234 -12.000000 -> -1 +ddcms637 comparesig -12.1234 -12.0000000 -> -1 +ddcms638 comparesig -12.1234 -12.00000000 -> -1 +ddcms639 comparesig -12.1234 -12.000000000 -> -1 + +-- extended zeros +ddcms640 comparesig 0 0 -> 0 +ddcms641 comparesig 0 -0 -> 0 +ddcms642 comparesig 0 -0.0 -> 0 +ddcms643 comparesig 0 0.0 -> 0 +ddcms644 comparesig -0 0 -> 0 +ddcms645 comparesig -0 -0 -> 0 +ddcms646 comparesig -0 -0.0 -> 0 +ddcms647 comparesig -0 0.0 -> 0 +ddcms648 comparesig 0.0 0 -> 0 +ddcms649 comparesig 0.0 -0 -> 0 +ddcms650 comparesig 0.0 -0.0 -> 0 +ddcms651 comparesig 0.0 0.0 -> 0 +ddcms652 comparesig -0.0 0 -> 0 +ddcms653 comparesig -0.0 -0 -> 0 +ddcms654 comparesig -0.0 -0.0 -> 0 +ddcms655 comparesig -0.0 0.0 -> 0 + +ddcms656 comparesig -0E1 0.0 -> 0 +ddcms657 comparesig -0E2 0.0 -> 0 +ddcms658 comparesig 0E1 0.0 -> 0 +ddcms659 comparesig 0E2 0.0 -> 0 +ddcms660 comparesig -0E1 0 -> 0 +ddcms661 comparesig -0E2 0 -> 0 +ddcms662 comparesig 0E1 0 -> 0 +ddcms663 comparesig 0E2 0 -> 0 +ddcms664 comparesig -0E1 -0E1 -> 0 +ddcms665 comparesig -0E2 -0E1 -> 0 +ddcms666 comparesig 0E1 -0E1 -> 0 +ddcms667 comparesig 0E2 -0E1 -> 0 +ddcms668 comparesig -0E1 -0E2 -> 0 +ddcms669 comparesig -0E2 -0E2 -> 0 +ddcms670 comparesig 0E1 -0E2 -> 0 +ddcms671 comparesig 0E2 -0E2 -> 0 +ddcms672 comparesig -0E1 0E1 -> 0 +ddcms673 comparesig -0E2 0E1 -> 0 +ddcms674 comparesig 0E1 0E1 -> 0 +ddcms675 comparesig 0E2 0E1 -> 0 +ddcms676 comparesig -0E1 0E2 -> 0 +ddcms677 comparesig -0E2 0E2 -> 0 +ddcms678 comparesig 0E1 0E2 -> 0 +ddcms679 comparesig 0E2 0E2 -> 0 + +-- trailing zeros; unit-y +ddcms680 comparesig 12 12 -> 0 +ddcms681 comparesig 12 12.0 -> 0 +ddcms682 comparesig 12 12.00 -> 0 +ddcms683 comparesig 12 12.000 -> 0 +ddcms684 comparesig 12 12.0000 -> 0 +ddcms685 comparesig 12 12.00000 -> 0 +ddcms686 comparesig 12 12.000000 -> 0 +ddcms687 comparesig 12 12.0000000 -> 0 +ddcms688 comparesig 12 12.00000000 -> 0 +ddcms689 comparesig 12 12.000000000 -> 0 +ddcms690 comparesig 12 12 -> 0 +ddcms691 comparesig 12.0 12 -> 0 +ddcms692 comparesig 12.00 12 -> 0 +ddcms693 comparesig 12.000 12 -> 0 +ddcms694 comparesig 12.0000 12 -> 0 +ddcms695 comparesig 12.00000 12 -> 0 +ddcms696 comparesig 12.000000 12 -> 0 +ddcms697 comparesig 12.0000000 12 -> 0 +ddcms698 comparesig 12.00000000 12 -> 0 +ddcms699 comparesig 12.000000000 12 -> 0 + +-- first, second, & last digit +ddcms700 comparesig 1234567890123456 1234567890123455 -> 1 +ddcms701 comparesig 1234567890123456 1234567890123456 -> 0 +ddcms702 comparesig 1234567890123456 1234567890123457 -> -1 +ddcms703 comparesig 1234567890123456 0234567890123456 -> 1 +ddcms704 comparesig 1234567890123456 1234567890123456 -> 0 +ddcms705 comparesig 1234567890123456 2234567890123456 -> -1 +ddcms706 comparesig 1134567890123456 1034567890123456 -> 1 +ddcms707 comparesig 1134567890123456 1134567890123456 -> 0 +ddcms708 comparesig 1134567890123456 1234567890123456 -> -1 + +-- miscellaneous +ddcms721 comparesig 12345678000 1 -> 1 +ddcms722 comparesig 1 12345678000 -> -1 +ddcms723 comparesig 1234567800 1 -> 1 +ddcms724 comparesig 1 1234567800 -> -1 +ddcms725 comparesig 1234567890 1 -> 1 +ddcms726 comparesig 1 1234567890 -> -1 +ddcms727 comparesig 1234567891 1 -> 1 +ddcms728 comparesig 1 1234567891 -> -1 +ddcms729 comparesig 12345678901 1 -> 1 +ddcms730 comparesig 1 12345678901 -> -1 +ddcms731 comparesig 1234567896 1 -> 1 +ddcms732 comparesig 1 1234567896 -> -1 + +-- residue cases at lower precision +ddcms740 comparesig 1 0.9999999 -> 1 +ddcms741 comparesig 1 0.999999 -> 1 +ddcms742 comparesig 1 0.99999 -> 1 +ddcms743 comparesig 1 1.0000 -> 0 +ddcms744 comparesig 1 1.00001 -> -1 +ddcms745 comparesig 1 1.000001 -> -1 +ddcms746 comparesig 1 1.0000001 -> -1 +ddcms750 comparesig 0.9999999 1 -> -1 +ddcms751 comparesig 0.999999 1 -> -1 +ddcms752 comparesig 0.99999 1 -> -1 +ddcms753 comparesig 1.0000 1 -> 0 +ddcms754 comparesig 1.00001 1 -> 1 +ddcms755 comparesig 1.000001 1 -> 1 +ddcms756 comparesig 1.0000001 1 -> 1 + +-- Specials +ddcms780 comparesig Inf -Inf -> 1 +ddcms781 comparesig Inf -1000 -> 1 +ddcms782 comparesig Inf -1 -> 1 +ddcms783 comparesig Inf -0 -> 1 +ddcms784 comparesig Inf 0 -> 1 +ddcms785 comparesig Inf 1 -> 1 +ddcms786 comparesig Inf 1000 -> 1 +ddcms787 comparesig Inf Inf -> 0 +ddcms788 comparesig -1000 Inf -> -1 +ddcms789 comparesig -Inf Inf -> -1 +ddcms790 comparesig -1 Inf -> -1 +ddcms791 comparesig -0 Inf -> -1 +ddcms792 comparesig 0 Inf -> -1 +ddcms793 comparesig 1 Inf -> -1 +ddcms794 comparesig 1000 Inf -> -1 +ddcms795 comparesig Inf Inf -> 0 + +ddcms800 comparesig -Inf -Inf -> 0 +ddcms801 comparesig -Inf -1000 -> -1 +ddcms802 comparesig -Inf -1 -> -1 +ddcms803 comparesig -Inf -0 -> -1 +ddcms804 comparesig -Inf 0 -> -1 +ddcms805 comparesig -Inf 1 -> -1 +ddcms806 comparesig -Inf 1000 -> -1 +ddcms807 comparesig -Inf Inf -> -1 +ddcms808 comparesig -Inf -Inf -> 0 +ddcms809 comparesig -1000 -Inf -> 1 +ddcms810 comparesig -1 -Inf -> 1 +ddcms811 comparesig -0 -Inf -> 1 +ddcms812 comparesig 0 -Inf -> 1 +ddcms813 comparesig 1 -Inf -> 1 +ddcms814 comparesig 1000 -Inf -> 1 +ddcms815 comparesig Inf -Inf -> 1 + +ddcms821 comparesig NaN -Inf -> NaN Invalid_operation +ddcms822 comparesig NaN -1000 -> NaN Invalid_operation +ddcms823 comparesig NaN -1 -> NaN Invalid_operation +ddcms824 comparesig NaN -0 -> NaN Invalid_operation +ddcms825 comparesig NaN 0 -> NaN Invalid_operation +ddcms826 comparesig NaN 1 -> NaN Invalid_operation +ddcms827 comparesig NaN 1000 -> NaN Invalid_operation +ddcms828 comparesig NaN Inf -> NaN Invalid_operation +ddcms829 comparesig NaN NaN -> NaN Invalid_operation +ddcms830 comparesig -Inf NaN -> NaN Invalid_operation +ddcms831 comparesig -1000 NaN -> NaN Invalid_operation +ddcms832 comparesig -1 NaN -> NaN Invalid_operation +ddcms833 comparesig -0 NaN -> NaN Invalid_operation +ddcms834 comparesig 0 NaN -> NaN Invalid_operation +ddcms835 comparesig 1 NaN -> NaN Invalid_operation +ddcms836 comparesig 1000 NaN -> NaN Invalid_operation +ddcms837 comparesig Inf NaN -> NaN Invalid_operation +ddcms838 comparesig -NaN -NaN -> -NaN Invalid_operation +ddcms839 comparesig +NaN -NaN -> NaN Invalid_operation +ddcms840 comparesig -NaN +NaN -> -NaN Invalid_operation + +ddcms841 comparesig sNaN -Inf -> NaN Invalid_operation +ddcms842 comparesig sNaN -1000 -> NaN Invalid_operation +ddcms843 comparesig sNaN -1 -> NaN Invalid_operation +ddcms844 comparesig sNaN -0 -> NaN Invalid_operation +ddcms845 comparesig sNaN 0 -> NaN Invalid_operation +ddcms846 comparesig sNaN 1 -> NaN Invalid_operation +ddcms847 comparesig sNaN 1000 -> NaN Invalid_operation +ddcms848 comparesig sNaN NaN -> NaN Invalid_operation +ddcms849 comparesig sNaN sNaN -> NaN Invalid_operation +ddcms850 comparesig NaN sNaN -> NaN Invalid_operation +ddcms851 comparesig -Inf sNaN -> NaN Invalid_operation +ddcms852 comparesig -1000 sNaN -> NaN Invalid_operation +ddcms853 comparesig -1 sNaN -> NaN Invalid_operation +ddcms854 comparesig -0 sNaN -> NaN Invalid_operation +ddcms855 comparesig 0 sNaN -> NaN Invalid_operation +ddcms856 comparesig 1 sNaN -> NaN Invalid_operation +ddcms857 comparesig 1000 sNaN -> NaN Invalid_operation +ddcms858 comparesig Inf sNaN -> NaN Invalid_operation +ddcms859 comparesig NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +ddcms860 comparesig NaN9 -Inf -> NaN9 Invalid_operation +ddcms861 comparesig NaN8 999 -> NaN8 Invalid_operation +ddcms862 comparesig NaN77 Inf -> NaN77 Invalid_operation +ddcms863 comparesig -NaN67 NaN5 -> -NaN67 Invalid_operation +ddcms864 comparesig -Inf -NaN4 -> -NaN4 Invalid_operation +ddcms865 comparesig -999 -NaN33 -> -NaN33 Invalid_operation +ddcms866 comparesig Inf NaN2 -> NaN2 Invalid_operation +ddcms867 comparesig -NaN41 -NaN42 -> -NaN41 Invalid_operation +ddcms868 comparesig +NaN41 -NaN42 -> NaN41 Invalid_operation +ddcms869 comparesig -NaN41 +NaN42 -> -NaN41 Invalid_operation +ddcms870 comparesig +NaN41 +NaN42 -> NaN41 Invalid_operation + +ddcms871 comparesig -sNaN99 -Inf -> -NaN99 Invalid_operation +ddcms872 comparesig sNaN98 -11 -> NaN98 Invalid_operation +ddcms873 comparesig sNaN97 NaN -> NaN97 Invalid_operation +ddcms874 comparesig sNaN16 sNaN94 -> NaN16 Invalid_operation +ddcms875 comparesig NaN85 sNaN83 -> NaN83 Invalid_operation +ddcms876 comparesig -Inf sNaN92 -> NaN92 Invalid_operation +ddcms877 comparesig 088 sNaN81 -> NaN81 Invalid_operation +ddcms878 comparesig Inf sNaN90 -> NaN90 Invalid_operation +ddcms879 comparesig NaN -sNaN89 -> -NaN89 Invalid_operation + +-- wide range +ddcms880 comparesig +1.23456789012345E-0 9E+384 -> -1 +ddcms881 comparesig 9E+384 +1.23456789012345E-0 -> 1 +ddcms882 comparesig +0.100 9E-383 -> 1 +ddcms883 comparesig 9E-383 +0.100 -> -1 +ddcms885 comparesig -1.23456789012345E-0 9E+384 -> -1 +ddcms886 comparesig 9E+384 -1.23456789012345E-0 -> 1 +ddcms887 comparesig -0.100 9E-383 -> -1 +ddcms888 comparesig 9E-383 -0.100 -> 1 + +-- signs +ddcms901 comparesig 1e+77 1e+11 -> 1 +ddcms902 comparesig 1e+77 -1e+11 -> 1 +ddcms903 comparesig -1e+77 1e+11 -> -1 +ddcms904 comparesig -1e+77 -1e+11 -> -1 +ddcms905 comparesig 1e-77 1e-11 -> -1 +ddcms906 comparesig 1e-77 -1e-11 -> 1 +ddcms907 comparesig -1e-77 1e-11 -> -1 +ddcms908 comparesig -1e-77 -1e-11 -> 1 + +-- Null tests +ddcms990 comparesig 10 # -> NaN Invalid_operation +ddcms991 comparesig # 10 -> NaN Invalid_operation Added: python/branches/release25-maint/Lib/test/decimaltestdata/ddCompareTotal.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/ddCompareTotal.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,706 @@ +------------------------------------------------------------------------ +-- ddCompareTotal.decTest -- decDouble comparison using total ordering-- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- Note that we cannot assume add/subtract tests cover paths adequately, +-- here, because the code might be quite different (comparison cannot +-- overflow or underflow, so actual subtractions are not necessary). +-- Similarly, comparetotal will have some radically different paths +-- than compare. + +-- All operands and results are decDoubles. +precision: 16 +maxExponent: 384 +minExponent: -383 +extended: 1 +clamp: 1 +rounding: half_even + +-- sanity checks +ddcot001 comparetotal -2 -2 -> 0 +ddcot002 comparetotal -2 -1 -> -1 +ddcot003 comparetotal -2 0 -> -1 +ddcot004 comparetotal -2 1 -> -1 +ddcot005 comparetotal -2 2 -> -1 +ddcot006 comparetotal -1 -2 -> 1 +ddcot007 comparetotal -1 -1 -> 0 +ddcot008 comparetotal -1 0 -> -1 +ddcot009 comparetotal -1 1 -> -1 +ddcot010 comparetotal -1 2 -> -1 +ddcot011 comparetotal 0 -2 -> 1 +ddcot012 comparetotal 0 -1 -> 1 +ddcot013 comparetotal 0 0 -> 0 +ddcot014 comparetotal 0 1 -> -1 +ddcot015 comparetotal 0 2 -> -1 +ddcot016 comparetotal 1 -2 -> 1 +ddcot017 comparetotal 1 -1 -> 1 +ddcot018 comparetotal 1 0 -> 1 +ddcot019 comparetotal 1 1 -> 0 +ddcot020 comparetotal 1 2 -> -1 +ddcot021 comparetotal 2 -2 -> 1 +ddcot022 comparetotal 2 -1 -> 1 +ddcot023 comparetotal 2 0 -> 1 +ddcot025 comparetotal 2 1 -> 1 +ddcot026 comparetotal 2 2 -> 0 + +ddcot031 comparetotal -20 -20 -> 0 +ddcot032 comparetotal -20 -10 -> -1 +ddcot033 comparetotal -20 00 -> -1 +ddcot034 comparetotal -20 10 -> -1 +ddcot035 comparetotal -20 20 -> -1 +ddcot036 comparetotal -10 -20 -> 1 +ddcot037 comparetotal -10 -10 -> 0 +ddcot038 comparetotal -10 00 -> -1 +ddcot039 comparetotal -10 10 -> -1 +ddcot040 comparetotal -10 20 -> -1 +ddcot041 comparetotal 00 -20 -> 1 +ddcot042 comparetotal 00 -10 -> 1 +ddcot043 comparetotal 00 00 -> 0 +ddcot044 comparetotal 00 10 -> -1 +ddcot045 comparetotal 00 20 -> -1 +ddcot046 comparetotal 10 -20 -> 1 +ddcot047 comparetotal 10 -10 -> 1 +ddcot048 comparetotal 10 00 -> 1 +ddcot049 comparetotal 10 10 -> 0 +ddcot050 comparetotal 10 20 -> -1 +ddcot051 comparetotal 20 -20 -> 1 +ddcot052 comparetotal 20 -10 -> 1 +ddcot053 comparetotal 20 00 -> 1 +ddcot055 comparetotal 20 10 -> 1 +ddcot056 comparetotal 20 20 -> 0 + +ddcot061 comparetotal -2.0 -2.0 -> 0 +ddcot062 comparetotal -2.0 -1.0 -> -1 +ddcot063 comparetotal -2.0 0.0 -> -1 +ddcot064 comparetotal -2.0 1.0 -> -1 +ddcot065 comparetotal -2.0 2.0 -> -1 +ddcot066 comparetotal -1.0 -2.0 -> 1 +ddcot067 comparetotal -1.0 -1.0 -> 0 +ddcot068 comparetotal -1.0 0.0 -> -1 +ddcot069 comparetotal -1.0 1.0 -> -1 +ddcot070 comparetotal -1.0 2.0 -> -1 +ddcot071 comparetotal 0.0 -2.0 -> 1 +ddcot072 comparetotal 0.0 -1.0 -> 1 +ddcot073 comparetotal 0.0 0.0 -> 0 +ddcot074 comparetotal 0.0 1.0 -> -1 +ddcot075 comparetotal 0.0 2.0 -> -1 +ddcot076 comparetotal 1.0 -2.0 -> 1 +ddcot077 comparetotal 1.0 -1.0 -> 1 +ddcot078 comparetotal 1.0 0.0 -> 1 +ddcot079 comparetotal 1.0 1.0 -> 0 +ddcot080 comparetotal 1.0 2.0 -> -1 +ddcot081 comparetotal 2.0 -2.0 -> 1 +ddcot082 comparetotal 2.0 -1.0 -> 1 +ddcot083 comparetotal 2.0 0.0 -> 1 +ddcot085 comparetotal 2.0 1.0 -> 1 +ddcot086 comparetotal 2.0 2.0 -> 0 + +-- now some cases which might overflow if subtract were used +ddcot090 comparetotal 9.99999999E+384 9.99999999E+384 -> 0 +ddcot091 comparetotal -9.99999999E+384 9.99999999E+384 -> -1 +ddcot092 comparetotal 9.99999999E+384 -9.99999999E+384 -> 1 +ddcot093 comparetotal -9.99999999E+384 -9.99999999E+384 -> 0 + +-- some differing length/exponent cases +-- in this first group, compare would compare all equal +ddcot100 comparetotal 7.0 7.0 -> 0 +ddcot101 comparetotal 7.0 7 -> -1 +ddcot102 comparetotal 7 7.0 -> 1 +ddcot103 comparetotal 7E+0 7.0 -> 1 +ddcot104 comparetotal 70E-1 7.0 -> 0 +ddcot105 comparetotal 0.7E+1 7 -> 0 +ddcot106 comparetotal 70E-1 7 -> -1 +ddcot107 comparetotal 7.0 7E+0 -> -1 +ddcot108 comparetotal 7.0 70E-1 -> 0 +ddcot109 comparetotal 7 0.7E+1 -> 0 +ddcot110 comparetotal 7 70E-1 -> 1 + +ddcot120 comparetotal 8.0 7.0 -> 1 +ddcot121 comparetotal 8.0 7 -> 1 +ddcot122 comparetotal 8 7.0 -> 1 +ddcot123 comparetotal 8E+0 7.0 -> 1 +ddcot124 comparetotal 80E-1 7.0 -> 1 +ddcot125 comparetotal 0.8E+1 7 -> 1 +ddcot126 comparetotal 80E-1 7 -> 1 +ddcot127 comparetotal 8.0 7E+0 -> 1 +ddcot128 comparetotal 8.0 70E-1 -> 1 +ddcot129 comparetotal 8 0.7E+1 -> 1 +ddcot130 comparetotal 8 70E-1 -> 1 + +ddcot140 comparetotal 8.0 9.0 -> -1 +ddcot141 comparetotal 8.0 9 -> -1 +ddcot142 comparetotal 8 9.0 -> -1 +ddcot143 comparetotal 8E+0 9.0 -> -1 +ddcot144 comparetotal 80E-1 9.0 -> -1 +ddcot145 comparetotal 0.8E+1 9 -> -1 +ddcot146 comparetotal 80E-1 9 -> -1 +ddcot147 comparetotal 8.0 9E+0 -> -1 +ddcot148 comparetotal 8.0 90E-1 -> -1 +ddcot149 comparetotal 8 0.9E+1 -> -1 +ddcot150 comparetotal 8 90E-1 -> -1 + +-- and again, with sign changes -+ .. +ddcot200 comparetotal -7.0 7.0 -> -1 +ddcot201 comparetotal -7.0 7 -> -1 +ddcot202 comparetotal -7 7.0 -> -1 +ddcot203 comparetotal -7E+0 7.0 -> -1 +ddcot204 comparetotal -70E-1 7.0 -> -1 +ddcot205 comparetotal -0.7E+1 7 -> -1 +ddcot206 comparetotal -70E-1 7 -> -1 +ddcot207 comparetotal -7.0 7E+0 -> -1 +ddcot208 comparetotal -7.0 70E-1 -> -1 +ddcot209 comparetotal -7 0.7E+1 -> -1 +ddcot210 comparetotal -7 70E-1 -> -1 + +ddcot220 comparetotal -8.0 7.0 -> -1 +ddcot221 comparetotal -8.0 7 -> -1 +ddcot222 comparetotal -8 7.0 -> -1 +ddcot223 comparetotal -8E+0 7.0 -> -1 +ddcot224 comparetotal -80E-1 7.0 -> -1 +ddcot225 comparetotal -0.8E+1 7 -> -1 +ddcot226 comparetotal -80E-1 7 -> -1 +ddcot227 comparetotal -8.0 7E+0 -> -1 +ddcot228 comparetotal -8.0 70E-1 -> -1 +ddcot229 comparetotal -8 0.7E+1 -> -1 +ddcot230 comparetotal -8 70E-1 -> -1 + +ddcot240 comparetotal -8.0 9.0 -> -1 +ddcot241 comparetotal -8.0 9 -> -1 +ddcot242 comparetotal -8 9.0 -> -1 +ddcot243 comparetotal -8E+0 9.0 -> -1 +ddcot244 comparetotal -80E-1 9.0 -> -1 +ddcot245 comparetotal -0.8E+1 9 -> -1 +ddcot246 comparetotal -80E-1 9 -> -1 +ddcot247 comparetotal -8.0 9E+0 -> -1 +ddcot248 comparetotal -8.0 90E-1 -> -1 +ddcot249 comparetotal -8 0.9E+1 -> -1 +ddcot250 comparetotal -8 90E-1 -> -1 + +-- and again, with sign changes +- .. +ddcot300 comparetotal 7.0 -7.0 -> 1 +ddcot301 comparetotal 7.0 -7 -> 1 +ddcot302 comparetotal 7 -7.0 -> 1 +ddcot303 comparetotal 7E+0 -7.0 -> 1 +ddcot304 comparetotal 70E-1 -7.0 -> 1 +ddcot305 comparetotal .7E+1 -7 -> 1 +ddcot306 comparetotal 70E-1 -7 -> 1 +ddcot307 comparetotal 7.0 -7E+0 -> 1 +ddcot308 comparetotal 7.0 -70E-1 -> 1 +ddcot309 comparetotal 7 -.7E+1 -> 1 +ddcot310 comparetotal 7 -70E-1 -> 1 + +ddcot320 comparetotal 8.0 -7.0 -> 1 +ddcot321 comparetotal 8.0 -7 -> 1 +ddcot322 comparetotal 8 -7.0 -> 1 +ddcot323 comparetotal 8E+0 -7.0 -> 1 +ddcot324 comparetotal 80E-1 -7.0 -> 1 +ddcot325 comparetotal .8E+1 -7 -> 1 +ddcot326 comparetotal 80E-1 -7 -> 1 +ddcot327 comparetotal 8.0 -7E+0 -> 1 +ddcot328 comparetotal 8.0 -70E-1 -> 1 +ddcot329 comparetotal 8 -.7E+1 -> 1 +ddcot330 comparetotal 8 -70E-1 -> 1 + +ddcot340 comparetotal 8.0 -9.0 -> 1 +ddcot341 comparetotal 8.0 -9 -> 1 +ddcot342 comparetotal 8 -9.0 -> 1 +ddcot343 comparetotal 8E+0 -9.0 -> 1 +ddcot344 comparetotal 80E-1 -9.0 -> 1 +ddcot345 comparetotal .8E+1 -9 -> 1 +ddcot346 comparetotal 80E-1 -9 -> 1 +ddcot347 comparetotal 8.0 -9E+0 -> 1 +ddcot348 comparetotal 8.0 -90E-1 -> 1 +ddcot349 comparetotal 8 -.9E+1 -> 1 +ddcot350 comparetotal 8 -90E-1 -> 1 + +-- and again, with sign changes -- .. +ddcot400 comparetotal -7.0 -7.0 -> 0 +ddcot401 comparetotal -7.0 -7 -> 1 +ddcot402 comparetotal -7 -7.0 -> -1 +ddcot403 comparetotal -7E+0 -7.0 -> -1 +ddcot404 comparetotal -70E-1 -7.0 -> 0 +ddcot405 comparetotal -.7E+1 -7 -> 0 +ddcot406 comparetotal -70E-1 -7 -> 1 +ddcot407 comparetotal -7.0 -7E+0 -> 1 +ddcot408 comparetotal -7.0 -70E-1 -> 0 +ddcot409 comparetotal -7 -.7E+1 -> 0 +ddcot410 comparetotal -7 -70E-1 -> -1 + +ddcot420 comparetotal -8.0 -7.0 -> -1 +ddcot421 comparetotal -8.0 -7 -> -1 +ddcot422 comparetotal -8 -7.0 -> -1 +ddcot423 comparetotal -8E+0 -7.0 -> -1 +ddcot424 comparetotal -80E-1 -7.0 -> -1 +ddcot425 comparetotal -.8E+1 -7 -> -1 +ddcot426 comparetotal -80E-1 -7 -> -1 +ddcot427 comparetotal -8.0 -7E+0 -> -1 +ddcot428 comparetotal -8.0 -70E-1 -> -1 +ddcot429 comparetotal -8 -.7E+1 -> -1 +ddcot430 comparetotal -8 -70E-1 -> -1 + +ddcot440 comparetotal -8.0 -9.0 -> 1 +ddcot441 comparetotal -8.0 -9 -> 1 +ddcot442 comparetotal -8 -9.0 -> 1 +ddcot443 comparetotal -8E+0 -9.0 -> 1 +ddcot444 comparetotal -80E-1 -9.0 -> 1 +ddcot445 comparetotal -.8E+1 -9 -> 1 +ddcot446 comparetotal -80E-1 -9 -> 1 +ddcot447 comparetotal -8.0 -9E+0 -> 1 +ddcot448 comparetotal -8.0 -90E-1 -> 1 +ddcot449 comparetotal -8 -.9E+1 -> 1 +ddcot450 comparetotal -8 -90E-1 -> 1 + + +-- testcases that subtract to lots of zeros at boundaries [pgr] +ddcot473 comparetotal 123.4560000000000E-89 123.456E-89 -> -1 +ddcot474 comparetotal 123.456000000000E+89 123.456E+89 -> -1 +ddcot475 comparetotal 123.45600000000E-89 123.456E-89 -> -1 +ddcot476 comparetotal 123.4560000000E+89 123.456E+89 -> -1 +ddcot477 comparetotal 123.456000000E-89 123.456E-89 -> -1 +ddcot478 comparetotal 123.45600000E+89 123.456E+89 -> -1 +ddcot479 comparetotal 123.4560000E-89 123.456E-89 -> -1 +ddcot480 comparetotal 123.456000E+89 123.456E+89 -> -1 +ddcot481 comparetotal 123.45600E-89 123.456E-89 -> -1 +ddcot482 comparetotal 123.4560E+89 123.456E+89 -> -1 +ddcot483 comparetotal 123.456E-89 123.456E-89 -> 0 +ddcot487 comparetotal 123.456E+89 123.4560000000000E+89 -> 1 +ddcot488 comparetotal 123.456E-89 123.456000000000E-89 -> 1 +ddcot489 comparetotal 123.456E+89 123.45600000000E+89 -> 1 +ddcot490 comparetotal 123.456E-89 123.4560000000E-89 -> 1 +ddcot491 comparetotal 123.456E+89 123.456000000E+89 -> 1 +ddcot492 comparetotal 123.456E-89 123.45600000E-89 -> 1 +ddcot493 comparetotal 123.456E+89 123.4560000E+89 -> 1 +ddcot494 comparetotal 123.456E-89 123.456000E-89 -> 1 +ddcot495 comparetotal 123.456E+89 123.45600E+89 -> 1 +ddcot496 comparetotal 123.456E-89 123.4560E-89 -> 1 +ddcot497 comparetotal 123.456E+89 123.456E+89 -> 0 + +-- wide-ranging, around precision; signs equal +ddcot498 comparetotal 1 1E-17 -> 1 +ddcot499 comparetotal 1 1E-16 -> 1 +ddcot500 comparetotal 1 1E-15 -> 1 +ddcot501 comparetotal 1 1E-14 -> 1 +ddcot502 comparetotal 1 1E-13 -> 1 +ddcot503 comparetotal 1 1E-12 -> 1 +ddcot504 comparetotal 1 1E-11 -> 1 +ddcot505 comparetotal 1 1E-10 -> 1 +ddcot506 comparetotal 1 1E-9 -> 1 +ddcot507 comparetotal 1 1E-8 -> 1 +ddcot508 comparetotal 1 1E-7 -> 1 +ddcot509 comparetotal 1 1E-6 -> 1 +ddcot510 comparetotal 1 1E-5 -> 1 +ddcot511 comparetotal 1 1E-4 -> 1 +ddcot512 comparetotal 1 1E-3 -> 1 +ddcot513 comparetotal 1 1E-2 -> 1 +ddcot514 comparetotal 1 1E-1 -> 1 +ddcot515 comparetotal 1 1E-0 -> 0 +ddcot516 comparetotal 1 1E+1 -> -1 +ddcot517 comparetotal 1 1E+2 -> -1 +ddcot518 comparetotal 1 1E+3 -> -1 +ddcot519 comparetotal 1 1E+4 -> -1 +ddcot521 comparetotal 1 1E+5 -> -1 +ddcot522 comparetotal 1 1E+6 -> -1 +ddcot523 comparetotal 1 1E+7 -> -1 +ddcot524 comparetotal 1 1E+8 -> -1 +ddcot525 comparetotal 1 1E+9 -> -1 +ddcot526 comparetotal 1 1E+10 -> -1 +ddcot527 comparetotal 1 1E+11 -> -1 +ddcot528 comparetotal 1 1E+12 -> -1 +ddcot529 comparetotal 1 1E+13 -> -1 +ddcot530 comparetotal 1 1E+14 -> -1 +ddcot531 comparetotal 1 1E+15 -> -1 +ddcot532 comparetotal 1 1E+16 -> -1 +ddcot533 comparetotal 1 1E+17 -> -1 +-- LR swap +ddcot538 comparetotal 1E-17 1 -> -1 +ddcot539 comparetotal 1E-16 1 -> -1 +ddcot540 comparetotal 1E-15 1 -> -1 +ddcot541 comparetotal 1E-14 1 -> -1 +ddcot542 comparetotal 1E-13 1 -> -1 +ddcot543 comparetotal 1E-12 1 -> -1 +ddcot544 comparetotal 1E-11 1 -> -1 +ddcot545 comparetotal 1E-10 1 -> -1 +ddcot546 comparetotal 1E-9 1 -> -1 +ddcot547 comparetotal 1E-8 1 -> -1 +ddcot548 comparetotal 1E-7 1 -> -1 +ddcot549 comparetotal 1E-6 1 -> -1 +ddcot550 comparetotal 1E-5 1 -> -1 +ddcot551 comparetotal 1E-4 1 -> -1 +ddcot552 comparetotal 1E-3 1 -> -1 +ddcot553 comparetotal 1E-2 1 -> -1 +ddcot554 comparetotal 1E-1 1 -> -1 +ddcot555 comparetotal 1E-0 1 -> 0 +ddcot556 comparetotal 1E+1 1 -> 1 +ddcot557 comparetotal 1E+2 1 -> 1 +ddcot558 comparetotal 1E+3 1 -> 1 +ddcot559 comparetotal 1E+4 1 -> 1 +ddcot561 comparetotal 1E+5 1 -> 1 +ddcot562 comparetotal 1E+6 1 -> 1 +ddcot563 comparetotal 1E+7 1 -> 1 +ddcot564 comparetotal 1E+8 1 -> 1 +ddcot565 comparetotal 1E+9 1 -> 1 +ddcot566 comparetotal 1E+10 1 -> 1 +ddcot567 comparetotal 1E+11 1 -> 1 +ddcot568 comparetotal 1E+12 1 -> 1 +ddcot569 comparetotal 1E+13 1 -> 1 +ddcot570 comparetotal 1E+14 1 -> 1 +ddcot571 comparetotal 1E+15 1 -> 1 +ddcot572 comparetotal 1E+16 1 -> 1 +ddcot573 comparetotal 1E+17 1 -> 1 +-- similar with a useful coefficient, one side only +ddcot578 comparetotal 0.000000987654321 1E-17 -> 1 +ddcot579 comparetotal 0.000000987654321 1E-16 -> 1 +ddcot580 comparetotal 0.000000987654321 1E-15 -> 1 +ddcot581 comparetotal 0.000000987654321 1E-14 -> 1 +ddcot582 comparetotal 0.000000987654321 1E-13 -> 1 +ddcot583 comparetotal 0.000000987654321 1E-12 -> 1 +ddcot584 comparetotal 0.000000987654321 1E-11 -> 1 +ddcot585 comparetotal 0.000000987654321 1E-10 -> 1 +ddcot586 comparetotal 0.000000987654321 1E-9 -> 1 +ddcot587 comparetotal 0.000000987654321 1E-8 -> 1 +ddcot588 comparetotal 0.000000987654321 1E-7 -> 1 +ddcot589 comparetotal 0.000000987654321 1E-6 -> -1 +ddcot590 comparetotal 0.000000987654321 1E-5 -> -1 +ddcot591 comparetotal 0.000000987654321 1E-4 -> -1 +ddcot592 comparetotal 0.000000987654321 1E-3 -> -1 +ddcot593 comparetotal 0.000000987654321 1E-2 -> -1 +ddcot594 comparetotal 0.000000987654321 1E-1 -> -1 +ddcot595 comparetotal 0.000000987654321 1E-0 -> -1 +ddcot596 comparetotal 0.000000987654321 1E+1 -> -1 +ddcot597 comparetotal 0.000000987654321 1E+2 -> -1 +ddcot598 comparetotal 0.000000987654321 1E+3 -> -1 +ddcot599 comparetotal 0.000000987654321 1E+4 -> -1 + +-- check some unit-y traps +ddcot600 comparetotal 12 12.2345 -> -1 +ddcot601 comparetotal 12.0 12.2345 -> -1 +ddcot602 comparetotal 12.00 12.2345 -> -1 +ddcot603 comparetotal 12.000 12.2345 -> -1 +ddcot604 comparetotal 12.0000 12.2345 -> -1 +ddcot605 comparetotal 12.00000 12.2345 -> -1 +ddcot606 comparetotal 12.000000 12.2345 -> -1 +ddcot607 comparetotal 12.0000000 12.2345 -> -1 +ddcot608 comparetotal 12.00000000 12.2345 -> -1 +ddcot609 comparetotal 12.000000000 12.2345 -> -1 +ddcot610 comparetotal 12.1234 12 -> 1 +ddcot611 comparetotal 12.1234 12.0 -> 1 +ddcot612 comparetotal 12.1234 12.00 -> 1 +ddcot613 comparetotal 12.1234 12.000 -> 1 +ddcot614 comparetotal 12.1234 12.0000 -> 1 +ddcot615 comparetotal 12.1234 12.00000 -> 1 +ddcot616 comparetotal 12.1234 12.000000 -> 1 +ddcot617 comparetotal 12.1234 12.0000000 -> 1 +ddcot618 comparetotal 12.1234 12.00000000 -> 1 +ddcot619 comparetotal 12.1234 12.000000000 -> 1 +ddcot620 comparetotal -12 -12.2345 -> 1 +ddcot621 comparetotal -12.0 -12.2345 -> 1 +ddcot622 comparetotal -12.00 -12.2345 -> 1 +ddcot623 comparetotal -12.000 -12.2345 -> 1 +ddcot624 comparetotal -12.0000 -12.2345 -> 1 +ddcot625 comparetotal -12.00000 -12.2345 -> 1 +ddcot626 comparetotal -12.000000 -12.2345 -> 1 +ddcot627 comparetotal -12.0000000 -12.2345 -> 1 +ddcot628 comparetotal -12.00000000 -12.2345 -> 1 +ddcot629 comparetotal -12.000000000 -12.2345 -> 1 +ddcot630 comparetotal -12.1234 -12 -> -1 +ddcot631 comparetotal -12.1234 -12.0 -> -1 +ddcot632 comparetotal -12.1234 -12.00 -> -1 +ddcot633 comparetotal -12.1234 -12.000 -> -1 +ddcot634 comparetotal -12.1234 -12.0000 -> -1 +ddcot635 comparetotal -12.1234 -12.00000 -> -1 +ddcot636 comparetotal -12.1234 -12.000000 -> -1 +ddcot637 comparetotal -12.1234 -12.0000000 -> -1 +ddcot638 comparetotal -12.1234 -12.00000000 -> -1 +ddcot639 comparetotal -12.1234 -12.000000000 -> -1 + +-- extended zeros +ddcot640 comparetotal 0 0 -> 0 +ddcot641 comparetotal 0 -0 -> 1 +ddcot642 comparetotal 0 -0.0 -> 1 +ddcot643 comparetotal 0 0.0 -> 1 +ddcot644 comparetotal -0 0 -> -1 +ddcot645 comparetotal -0 -0 -> 0 +ddcot646 comparetotal -0 -0.0 -> -1 +ddcot647 comparetotal -0 0.0 -> -1 +ddcot648 comparetotal 0.0 0 -> -1 +ddcot649 comparetotal 0.0 -0 -> 1 +ddcot650 comparetotal 0.0 -0.0 -> 1 +ddcot651 comparetotal 0.0 0.0 -> 0 +ddcot652 comparetotal -0.0 0 -> -1 +ddcot653 comparetotal -0.0 -0 -> 1 +ddcot654 comparetotal -0.0 -0.0 -> 0 +ddcot655 comparetotal -0.0 0.0 -> -1 + +ddcot656 comparetotal -0E1 0.0 -> -1 +ddcot657 comparetotal -0E2 0.0 -> -1 +ddcot658 comparetotal 0E1 0.0 -> 1 +ddcot659 comparetotal 0E2 0.0 -> 1 +ddcot660 comparetotal -0E1 0 -> -1 +ddcot661 comparetotal -0E2 0 -> -1 +ddcot662 comparetotal 0E1 0 -> 1 +ddcot663 comparetotal 0E2 0 -> 1 +ddcot664 comparetotal -0E1 -0E1 -> 0 +ddcot665 comparetotal -0E2 -0E1 -> -1 +ddcot666 comparetotal 0E1 -0E1 -> 1 +ddcot667 comparetotal 0E2 -0E1 -> 1 +ddcot668 comparetotal -0E1 -0E2 -> 1 +ddcot669 comparetotal -0E2 -0E2 -> 0 +ddcot670 comparetotal 0E1 -0E2 -> 1 +ddcot671 comparetotal 0E2 -0E2 -> 1 +ddcot672 comparetotal -0E1 0E1 -> -1 +ddcot673 comparetotal -0E2 0E1 -> -1 +ddcot674 comparetotal 0E1 0E1 -> 0 +ddcot675 comparetotal 0E2 0E1 -> 1 +ddcot676 comparetotal -0E1 0E2 -> -1 +ddcot677 comparetotal -0E2 0E2 -> -1 +ddcot678 comparetotal 0E1 0E2 -> -1 +ddcot679 comparetotal 0E2 0E2 -> 0 + +-- trailing zeros; unit-y +ddcot680 comparetotal 12 12 -> 0 +ddcot681 comparetotal 12 12.0 -> 1 +ddcot682 comparetotal 12 12.00 -> 1 +ddcot683 comparetotal 12 12.000 -> 1 +ddcot684 comparetotal 12 12.0000 -> 1 +ddcot685 comparetotal 12 12.00000 -> 1 +ddcot686 comparetotal 12 12.000000 -> 1 +ddcot687 comparetotal 12 12.0000000 -> 1 +ddcot688 comparetotal 12 12.00000000 -> 1 +ddcot689 comparetotal 12 12.000000000 -> 1 +ddcot690 comparetotal 12 12 -> 0 +ddcot691 comparetotal 12.0 12 -> -1 +ddcot692 comparetotal 12.00 12 -> -1 +ddcot693 comparetotal 12.000 12 -> -1 +ddcot694 comparetotal 12.0000 12 -> -1 +ddcot695 comparetotal 12.00000 12 -> -1 +ddcot696 comparetotal 12.000000 12 -> -1 +ddcot697 comparetotal 12.0000000 12 -> -1 +ddcot698 comparetotal 12.00000000 12 -> -1 +ddcot699 comparetotal 12.000000000 12 -> -1 + +-- old long operand checks +ddcot701 comparetotal 12345678000 1 -> 1 +ddcot702 comparetotal 1 12345678000 -> -1 +ddcot703 comparetotal 1234567800 1 -> 1 +ddcot704 comparetotal 1 1234567800 -> -1 +ddcot705 comparetotal 1234567890 1 -> 1 +ddcot706 comparetotal 1 1234567890 -> -1 +ddcot707 comparetotal 1234567891 1 -> 1 +ddcot708 comparetotal 1 1234567891 -> -1 +ddcot709 comparetotal 12345678901 1 -> 1 +ddcot710 comparetotal 1 12345678901 -> -1 +ddcot711 comparetotal 1234567896 1 -> 1 +ddcot712 comparetotal 1 1234567896 -> -1 +ddcot713 comparetotal -1234567891 1 -> -1 +ddcot714 comparetotal 1 -1234567891 -> 1 +ddcot715 comparetotal -12345678901 1 -> -1 +ddcot716 comparetotal 1 -12345678901 -> 1 +ddcot717 comparetotal -1234567896 1 -> -1 +ddcot718 comparetotal 1 -1234567896 -> 1 + +-- old residue cases +ddcot740 comparetotal 1 0.9999999 -> 1 +ddcot741 comparetotal 1 0.999999 -> 1 +ddcot742 comparetotal 1 0.99999 -> 1 +ddcot743 comparetotal 1 1.0000 -> 1 +ddcot744 comparetotal 1 1.00001 -> -1 +ddcot745 comparetotal 1 1.000001 -> -1 +ddcot746 comparetotal 1 1.0000001 -> -1 +ddcot750 comparetotal 0.9999999 1 -> -1 +ddcot751 comparetotal 0.999999 1 -> -1 +ddcot752 comparetotal 0.99999 1 -> -1 +ddcot753 comparetotal 1.0000 1 -> -1 +ddcot754 comparetotal 1.00001 1 -> 1 +ddcot755 comparetotal 1.000001 1 -> 1 +ddcot756 comparetotal 1.0000001 1 -> 1 + +-- Specials +ddcot780 comparetotal Inf -Inf -> 1 +ddcot781 comparetotal Inf -1000 -> 1 +ddcot782 comparetotal Inf -1 -> 1 +ddcot783 comparetotal Inf -0 -> 1 +ddcot784 comparetotal Inf 0 -> 1 +ddcot785 comparetotal Inf 1 -> 1 +ddcot786 comparetotal Inf 1000 -> 1 +ddcot787 comparetotal Inf Inf -> 0 +ddcot788 comparetotal -1000 Inf -> -1 +ddcot789 comparetotal -Inf Inf -> -1 +ddcot790 comparetotal -1 Inf -> -1 +ddcot791 comparetotal -0 Inf -> -1 +ddcot792 comparetotal 0 Inf -> -1 +ddcot793 comparetotal 1 Inf -> -1 +ddcot794 comparetotal 1000 Inf -> -1 +ddcot795 comparetotal Inf Inf -> 0 + +ddcot800 comparetotal -Inf -Inf -> 0 +ddcot801 comparetotal -Inf -1000 -> -1 +ddcot802 comparetotal -Inf -1 -> -1 +ddcot803 comparetotal -Inf -0 -> -1 +ddcot804 comparetotal -Inf 0 -> -1 +ddcot805 comparetotal -Inf 1 -> -1 +ddcot806 comparetotal -Inf 1000 -> -1 +ddcot807 comparetotal -Inf Inf -> -1 +ddcot808 comparetotal -Inf -Inf -> 0 +ddcot809 comparetotal -1000 -Inf -> 1 +ddcot810 comparetotal -1 -Inf -> 1 +ddcot811 comparetotal -0 -Inf -> 1 +ddcot812 comparetotal 0 -Inf -> 1 +ddcot813 comparetotal 1 -Inf -> 1 +ddcot814 comparetotal 1000 -Inf -> 1 +ddcot815 comparetotal Inf -Inf -> 1 + +ddcot821 comparetotal NaN -Inf -> 1 +ddcot822 comparetotal NaN -1000 -> 1 +ddcot823 comparetotal NaN -1 -> 1 +ddcot824 comparetotal NaN -0 -> 1 +ddcot825 comparetotal NaN 0 -> 1 +ddcot826 comparetotal NaN 1 -> 1 +ddcot827 comparetotal NaN 1000 -> 1 +ddcot828 comparetotal NaN Inf -> 1 +ddcot829 comparetotal NaN NaN -> 0 +ddcot830 comparetotal -Inf NaN -> -1 +ddcot831 comparetotal -1000 NaN -> -1 +ddcot832 comparetotal -1 NaN -> -1 +ddcot833 comparetotal -0 NaN -> -1 +ddcot834 comparetotal 0 NaN -> -1 +ddcot835 comparetotal 1 NaN -> -1 +ddcot836 comparetotal 1000 NaN -> -1 +ddcot837 comparetotal Inf NaN -> -1 +ddcot838 comparetotal -NaN -NaN -> 0 +ddcot839 comparetotal +NaN -NaN -> 1 +ddcot840 comparetotal -NaN +NaN -> -1 + +ddcot841 comparetotal sNaN -sNaN -> 1 +ddcot842 comparetotal sNaN -NaN -> 1 +ddcot843 comparetotal sNaN -Inf -> 1 +ddcot844 comparetotal sNaN -1000 -> 1 +ddcot845 comparetotal sNaN -1 -> 1 +ddcot846 comparetotal sNaN -0 -> 1 +ddcot847 comparetotal sNaN 0 -> 1 +ddcot848 comparetotal sNaN 1 -> 1 +ddcot849 comparetotal sNaN 1000 -> 1 +ddcot850 comparetotal sNaN NaN -> -1 +ddcot851 comparetotal sNaN sNaN -> 0 + +ddcot852 comparetotal -sNaN sNaN -> -1 +ddcot853 comparetotal -NaN sNaN -> -1 +ddcot854 comparetotal -Inf sNaN -> -1 +ddcot855 comparetotal -1000 sNaN -> -1 +ddcot856 comparetotal -1 sNaN -> -1 +ddcot857 comparetotal -0 sNaN -> -1 +ddcot858 comparetotal 0 sNaN -> -1 +ddcot859 comparetotal 1 sNaN -> -1 +ddcot860 comparetotal 1000 sNaN -> -1 +ddcot861 comparetotal Inf sNaN -> -1 +ddcot862 comparetotal NaN sNaN -> 1 +ddcot863 comparetotal sNaN sNaN -> 0 + +ddcot871 comparetotal -sNaN -sNaN -> 0 +ddcot872 comparetotal -sNaN -NaN -> 1 +ddcot873 comparetotal -sNaN -Inf -> -1 +ddcot874 comparetotal -sNaN -1000 -> -1 +ddcot875 comparetotal -sNaN -1 -> -1 +ddcot876 comparetotal -sNaN -0 -> -1 +ddcot877 comparetotal -sNaN 0 -> -1 +ddcot878 comparetotal -sNaN 1 -> -1 +ddcot879 comparetotal -sNaN 1000 -> -1 +ddcot880 comparetotal -sNaN NaN -> -1 +ddcot881 comparetotal -sNaN sNaN -> -1 + +ddcot882 comparetotal -sNaN -sNaN -> 0 +ddcot883 comparetotal -NaN -sNaN -> -1 +ddcot884 comparetotal -Inf -sNaN -> 1 +ddcot885 comparetotal -1000 -sNaN -> 1 +ddcot886 comparetotal -1 -sNaN -> 1 +ddcot887 comparetotal -0 -sNaN -> 1 +ddcot888 comparetotal 0 -sNaN -> 1 +ddcot889 comparetotal 1 -sNaN -> 1 +ddcot890 comparetotal 1000 -sNaN -> 1 +ddcot891 comparetotal Inf -sNaN -> 1 +ddcot892 comparetotal NaN -sNaN -> 1 +ddcot893 comparetotal sNaN -sNaN -> 1 + +-- NaNs with payload +ddcot960 comparetotal NaN9 -Inf -> 1 +ddcot961 comparetotal NaN8 999 -> 1 +ddcot962 comparetotal NaN77 Inf -> 1 +ddcot963 comparetotal -NaN67 NaN5 -> -1 +ddcot964 comparetotal -Inf -NaN4 -> 1 +ddcot965 comparetotal -999 -NaN33 -> 1 +ddcot966 comparetotal Inf NaN2 -> -1 + +ddcot970 comparetotal -NaN41 -NaN42 -> 1 +ddcot971 comparetotal +NaN41 -NaN42 -> 1 +ddcot972 comparetotal -NaN41 +NaN42 -> -1 +ddcot973 comparetotal +NaN41 +NaN42 -> -1 +ddcot974 comparetotal -NaN42 -NaN01 -> -1 +ddcot975 comparetotal +NaN42 -NaN01 -> 1 +ddcot976 comparetotal -NaN42 +NaN01 -> -1 +ddcot977 comparetotal +NaN42 +NaN01 -> 1 + +ddcot980 comparetotal -sNaN771 -sNaN772 -> 1 +ddcot981 comparetotal +sNaN771 -sNaN772 -> 1 +ddcot982 comparetotal -sNaN771 +sNaN772 -> -1 +ddcot983 comparetotal +sNaN771 +sNaN772 -> -1 +ddcot984 comparetotal -sNaN772 -sNaN771 -> -1 +ddcot985 comparetotal +sNaN772 -sNaN771 -> 1 +ddcot986 comparetotal -sNaN772 +sNaN771 -> -1 +ddcot987 comparetotal +sNaN772 +sNaN771 -> 1 + +ddcot991 comparetotal -sNaN99 -Inf -> -1 +ddcot992 comparetotal sNaN98 -11 -> 1 +ddcot993 comparetotal sNaN97 NaN -> -1 +ddcot994 comparetotal sNaN16 sNaN94 -> -1 +ddcot995 comparetotal NaN85 sNaN83 -> 1 +ddcot996 comparetotal -Inf sNaN92 -> -1 +ddcot997 comparetotal 088 sNaN81 -> -1 +ddcot998 comparetotal Inf sNaN90 -> -1 +ddcot999 comparetotal NaN -sNaN89 -> 1 + +-- spread zeros +ddcot1110 comparetotal 0E-383 0 -> -1 +ddcot1111 comparetotal 0E-383 -0 -> 1 +ddcot1112 comparetotal -0E-383 0 -> -1 +ddcot1113 comparetotal -0E-383 -0 -> 1 +ddcot1114 comparetotal 0E-383 0E+384 -> -1 +ddcot1115 comparetotal 0E-383 -0E+384 -> 1 +ddcot1116 comparetotal -0E-383 0E+384 -> -1 +ddcot1117 comparetotal -0E-383 -0E+384 -> 1 +ddcot1118 comparetotal 0 0E+384 -> -1 +ddcot1119 comparetotal 0 -0E+384 -> 1 +ddcot1120 comparetotal -0 0E+384 -> -1 +ddcot1121 comparetotal -0 -0E+384 -> 1 + +ddcot1130 comparetotal 0E+384 0 -> 1 +ddcot1131 comparetotal 0E+384 -0 -> 1 +ddcot1132 comparetotal -0E+384 0 -> -1 +ddcot1133 comparetotal -0E+384 -0 -> -1 +ddcot1134 comparetotal 0E+384 0E-383 -> 1 +ddcot1135 comparetotal 0E+384 -0E-383 -> 1 +ddcot1136 comparetotal -0E+384 0E-383 -> -1 +ddcot1137 comparetotal -0E+384 -0E-383 -> -1 +ddcot1138 comparetotal 0 0E-383 -> 1 +ddcot1139 comparetotal 0 -0E-383 -> 1 +ddcot1140 comparetotal -0 0E-383 -> -1 +ddcot1141 comparetotal -0 -0E-383 -> -1 + +-- Null tests +ddcot9990 comparetotal 10 # -> NaN Invalid_operation +ddcot9991 comparetotal # 10 -> NaN Invalid_operation Added: python/branches/release25-maint/Lib/test/decimaltestdata/ddCompareTotalMag.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/ddCompareTotalMag.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,706 @@ +------------------------------------------------------------------------ +-- ddCompareTotalMag.decTest -- decDouble comparison; abs. total order-- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- Note that we cannot assume add/subtract tests cover paths adequately, +-- here, because the code might be quite different (comparison cannot +-- overflow or underflow, so actual subtractions are not necessary). +-- Similarly, comparetotal will have some radically different paths +-- than compare. + +-- All operands and results are decDoubles. +precision: 16 +maxExponent: 384 +minExponent: -383 +extended: 1 +clamp: 1 +rounding: half_even + +-- sanity checks +ddctm001 comparetotmag -2 -2 -> 0 +ddctm002 comparetotmag -2 -1 -> 1 +ddctm003 comparetotmag -2 0 -> 1 +ddctm004 comparetotmag -2 1 -> 1 +ddctm005 comparetotmag -2 2 -> 0 +ddctm006 comparetotmag -1 -2 -> -1 +ddctm007 comparetotmag -1 -1 -> 0 +ddctm008 comparetotmag -1 0 -> 1 +ddctm009 comparetotmag -1 1 -> 0 +ddctm010 comparetotmag -1 2 -> -1 +ddctm011 comparetotmag 0 -2 -> -1 +ddctm012 comparetotmag 0 -1 -> -1 +ddctm013 comparetotmag 0 0 -> 0 +ddctm014 comparetotmag 0 1 -> -1 +ddctm015 comparetotmag 0 2 -> -1 +ddctm016 comparetotmag 1 -2 -> -1 +ddctm017 comparetotmag 1 -1 -> 0 +ddctm018 comparetotmag 1 0 -> 1 +ddctm019 comparetotmag 1 1 -> 0 +ddctm020 comparetotmag 1 2 -> -1 +ddctm021 comparetotmag 2 -2 -> 0 +ddctm022 comparetotmag 2 -1 -> 1 +ddctm023 comparetotmag 2 0 -> 1 +ddctm025 comparetotmag 2 1 -> 1 +ddctm026 comparetotmag 2 2 -> 0 + +ddctm031 comparetotmag -20 -20 -> 0 +ddctm032 comparetotmag -20 -10 -> 1 +ddctm033 comparetotmag -20 00 -> 1 +ddctm034 comparetotmag -20 10 -> 1 +ddctm035 comparetotmag -20 20 -> 0 +ddctm036 comparetotmag -10 -20 -> -1 +ddctm037 comparetotmag -10 -10 -> 0 +ddctm038 comparetotmag -10 00 -> 1 +ddctm039 comparetotmag -10 10 -> 0 +ddctm040 comparetotmag -10 20 -> -1 +ddctm041 comparetotmag 00 -20 -> -1 +ddctm042 comparetotmag 00 -10 -> -1 +ddctm043 comparetotmag 00 00 -> 0 +ddctm044 comparetotmag 00 10 -> -1 +ddctm045 comparetotmag 00 20 -> -1 +ddctm046 comparetotmag 10 -20 -> -1 +ddctm047 comparetotmag 10 -10 -> 0 +ddctm048 comparetotmag 10 00 -> 1 +ddctm049 comparetotmag 10 10 -> 0 +ddctm050 comparetotmag 10 20 -> -1 +ddctm051 comparetotmag 20 -20 -> 0 +ddctm052 comparetotmag 20 -10 -> 1 +ddctm053 comparetotmag 20 00 -> 1 +ddctm055 comparetotmag 20 10 -> 1 +ddctm056 comparetotmag 20 20 -> 0 + +ddctm061 comparetotmag -2.0 -2.0 -> 0 +ddctm062 comparetotmag -2.0 -1.0 -> 1 +ddctm063 comparetotmag -2.0 0.0 -> 1 +ddctm064 comparetotmag -2.0 1.0 -> 1 +ddctm065 comparetotmag -2.0 2.0 -> 0 +ddctm066 comparetotmag -1.0 -2.0 -> -1 +ddctm067 comparetotmag -1.0 -1.0 -> 0 +ddctm068 comparetotmag -1.0 0.0 -> 1 +ddctm069 comparetotmag -1.0 1.0 -> 0 +ddctm070 comparetotmag -1.0 2.0 -> -1 +ddctm071 comparetotmag 0.0 -2.0 -> -1 +ddctm072 comparetotmag 0.0 -1.0 -> -1 +ddctm073 comparetotmag 0.0 0.0 -> 0 +ddctm074 comparetotmag 0.0 1.0 -> -1 +ddctm075 comparetotmag 0.0 2.0 -> -1 +ddctm076 comparetotmag 1.0 -2.0 -> -1 +ddctm077 comparetotmag 1.0 -1.0 -> 0 +ddctm078 comparetotmag 1.0 0.0 -> 1 +ddctm079 comparetotmag 1.0 1.0 -> 0 +ddctm080 comparetotmag 1.0 2.0 -> -1 +ddctm081 comparetotmag 2.0 -2.0 -> 0 +ddctm082 comparetotmag 2.0 -1.0 -> 1 +ddctm083 comparetotmag 2.0 0.0 -> 1 +ddctm085 comparetotmag 2.0 1.0 -> 1 +ddctm086 comparetotmag 2.0 2.0 -> 0 + +-- now some cases which might overflow if subtract were used +ddctm090 comparetotmag 9.99999999E+384 9.99999999E+384 -> 0 +ddctm091 comparetotmag -9.99999999E+384 9.99999999E+384 -> 0 +ddctm092 comparetotmag 9.99999999E+384 -9.99999999E+384 -> 0 +ddctm093 comparetotmag -9.99999999E+384 -9.99999999E+384 -> 0 + +-- some differing length/exponent cases +-- in this first group, compare would compare all equal +ddctm100 comparetotmag 7.0 7.0 -> 0 +ddctm101 comparetotmag 7.0 7 -> -1 +ddctm102 comparetotmag 7 7.0 -> 1 +ddctm103 comparetotmag 7E+0 7.0 -> 1 +ddctm104 comparetotmag 70E-1 7.0 -> 0 +ddctm105 comparetotmag 0.7E+1 7 -> 0 +ddctm106 comparetotmag 70E-1 7 -> -1 +ddctm107 comparetotmag 7.0 7E+0 -> -1 +ddctm108 comparetotmag 7.0 70E-1 -> 0 +ddctm109 comparetotmag 7 0.7E+1 -> 0 +ddctm110 comparetotmag 7 70E-1 -> 1 + +ddctm120 comparetotmag 8.0 7.0 -> 1 +ddctm121 comparetotmag 8.0 7 -> 1 +ddctm122 comparetotmag 8 7.0 -> 1 +ddctm123 comparetotmag 8E+0 7.0 -> 1 +ddctm124 comparetotmag 80E-1 7.0 -> 1 +ddctm125 comparetotmag 0.8E+1 7 -> 1 +ddctm126 comparetotmag 80E-1 7 -> 1 +ddctm127 comparetotmag 8.0 7E+0 -> 1 +ddctm128 comparetotmag 8.0 70E-1 -> 1 +ddctm129 comparetotmag 8 0.7E+1 -> 1 +ddctm130 comparetotmag 8 70E-1 -> 1 + +ddctm140 comparetotmag 8.0 9.0 -> -1 +ddctm141 comparetotmag 8.0 9 -> -1 +ddctm142 comparetotmag 8 9.0 -> -1 +ddctm143 comparetotmag 8E+0 9.0 -> -1 +ddctm144 comparetotmag 80E-1 9.0 -> -1 +ddctm145 comparetotmag 0.8E+1 9 -> -1 +ddctm146 comparetotmag 80E-1 9 -> -1 +ddctm147 comparetotmag 8.0 9E+0 -> -1 +ddctm148 comparetotmag 8.0 90E-1 -> -1 +ddctm149 comparetotmag 8 0.9E+1 -> -1 +ddctm150 comparetotmag 8 90E-1 -> -1 + +-- and again, with sign changes -+ .. +ddctm200 comparetotmag -7.0 7.0 -> 0 +ddctm201 comparetotmag -7.0 7 -> -1 +ddctm202 comparetotmag -7 7.0 -> 1 +ddctm203 comparetotmag -7E+0 7.0 -> 1 +ddctm204 comparetotmag -70E-1 7.0 -> 0 +ddctm205 comparetotmag -0.7E+1 7 -> 0 +ddctm206 comparetotmag -70E-1 7 -> -1 +ddctm207 comparetotmag -7.0 7E+0 -> -1 +ddctm208 comparetotmag -7.0 70E-1 -> 0 +ddctm209 comparetotmag -7 0.7E+1 -> 0 +ddctm210 comparetotmag -7 70E-1 -> 1 + +ddctm220 comparetotmag -8.0 7.0 -> 1 +ddctm221 comparetotmag -8.0 7 -> 1 +ddctm222 comparetotmag -8 7.0 -> 1 +ddctm223 comparetotmag -8E+0 7.0 -> 1 +ddctm224 comparetotmag -80E-1 7.0 -> 1 +ddctm225 comparetotmag -0.8E+1 7 -> 1 +ddctm226 comparetotmag -80E-1 7 -> 1 +ddctm227 comparetotmag -8.0 7E+0 -> 1 +ddctm228 comparetotmag -8.0 70E-1 -> 1 +ddctm229 comparetotmag -8 0.7E+1 -> 1 +ddctm230 comparetotmag -8 70E-1 -> 1 + +ddctm240 comparetotmag -8.0 9.0 -> -1 +ddctm241 comparetotmag -8.0 9 -> -1 +ddctm242 comparetotmag -8 9.0 -> -1 +ddctm243 comparetotmag -8E+0 9.0 -> -1 +ddctm244 comparetotmag -80E-1 9.0 -> -1 +ddctm245 comparetotmag -0.8E+1 9 -> -1 +ddctm246 comparetotmag -80E-1 9 -> -1 +ddctm247 comparetotmag -8.0 9E+0 -> -1 +ddctm248 comparetotmag -8.0 90E-1 -> -1 +ddctm249 comparetotmag -8 0.9E+1 -> -1 +ddctm250 comparetotmag -8 90E-1 -> -1 + +-- and again, with sign changes +- .. +ddctm300 comparetotmag 7.0 -7.0 -> 0 +ddctm301 comparetotmag 7.0 -7 -> -1 +ddctm302 comparetotmag 7 -7.0 -> 1 +ddctm303 comparetotmag 7E+0 -7.0 -> 1 +ddctm304 comparetotmag 70E-1 -7.0 -> 0 +ddctm305 comparetotmag .7E+1 -7 -> 0 +ddctm306 comparetotmag 70E-1 -7 -> -1 +ddctm307 comparetotmag 7.0 -7E+0 -> -1 +ddctm308 comparetotmag 7.0 -70E-1 -> 0 +ddctm309 comparetotmag 7 -.7E+1 -> 0 +ddctm310 comparetotmag 7 -70E-1 -> 1 + +ddctm320 comparetotmag 8.0 -7.0 -> 1 +ddctm321 comparetotmag 8.0 -7 -> 1 +ddctm322 comparetotmag 8 -7.0 -> 1 +ddctm323 comparetotmag 8E+0 -7.0 -> 1 +ddctm324 comparetotmag 80E-1 -7.0 -> 1 +ddctm325 comparetotmag .8E+1 -7 -> 1 +ddctm326 comparetotmag 80E-1 -7 -> 1 +ddctm327 comparetotmag 8.0 -7E+0 -> 1 +ddctm328 comparetotmag 8.0 -70E-1 -> 1 +ddctm329 comparetotmag 8 -.7E+1 -> 1 +ddctm330 comparetotmag 8 -70E-1 -> 1 + +ddctm340 comparetotmag 8.0 -9.0 -> -1 +ddctm341 comparetotmag 8.0 -9 -> -1 +ddctm342 comparetotmag 8 -9.0 -> -1 +ddctm343 comparetotmag 8E+0 -9.0 -> -1 +ddctm344 comparetotmag 80E-1 -9.0 -> -1 +ddctm345 comparetotmag .8E+1 -9 -> -1 +ddctm346 comparetotmag 80E-1 -9 -> -1 +ddctm347 comparetotmag 8.0 -9E+0 -> -1 +ddctm348 comparetotmag 8.0 -90E-1 -> -1 +ddctm349 comparetotmag 8 -.9E+1 -> -1 +ddctm350 comparetotmag 8 -90E-1 -> -1 + +-- and again, with sign changes -- .. +ddctm400 comparetotmag -7.0 -7.0 -> 0 +ddctm401 comparetotmag -7.0 -7 -> -1 +ddctm402 comparetotmag -7 -7.0 -> 1 +ddctm403 comparetotmag -7E+0 -7.0 -> 1 +ddctm404 comparetotmag -70E-1 -7.0 -> 0 +ddctm405 comparetotmag -.7E+1 -7 -> 0 +ddctm406 comparetotmag -70E-1 -7 -> -1 +ddctm407 comparetotmag -7.0 -7E+0 -> -1 +ddctm408 comparetotmag -7.0 -70E-1 -> 0 +ddctm409 comparetotmag -7 -.7E+1 -> 0 +ddctm410 comparetotmag -7 -70E-1 -> 1 + +ddctm420 comparetotmag -8.0 -7.0 -> 1 +ddctm421 comparetotmag -8.0 -7 -> 1 +ddctm422 comparetotmag -8 -7.0 -> 1 +ddctm423 comparetotmag -8E+0 -7.0 -> 1 +ddctm424 comparetotmag -80E-1 -7.0 -> 1 +ddctm425 comparetotmag -.8E+1 -7 -> 1 +ddctm426 comparetotmag -80E-1 -7 -> 1 +ddctm427 comparetotmag -8.0 -7E+0 -> 1 +ddctm428 comparetotmag -8.0 -70E-1 -> 1 +ddctm429 comparetotmag -8 -.7E+1 -> 1 +ddctm430 comparetotmag -8 -70E-1 -> 1 + +ddctm440 comparetotmag -8.0 -9.0 -> -1 +ddctm441 comparetotmag -8.0 -9 -> -1 +ddctm442 comparetotmag -8 -9.0 -> -1 +ddctm443 comparetotmag -8E+0 -9.0 -> -1 +ddctm444 comparetotmag -80E-1 -9.0 -> -1 +ddctm445 comparetotmag -.8E+1 -9 -> -1 +ddctm446 comparetotmag -80E-1 -9 -> -1 +ddctm447 comparetotmag -8.0 -9E+0 -> -1 +ddctm448 comparetotmag -8.0 -90E-1 -> -1 +ddctm449 comparetotmag -8 -.9E+1 -> -1 +ddctm450 comparetotmag -8 -90E-1 -> -1 + + +-- testcases that subtract to lots of zeros at boundaries [pgr] +ddctm473 comparetotmag 123.4560000000000E-89 123.456E-89 -> -1 +ddctm474 comparetotmag 123.456000000000E+89 123.456E+89 -> -1 +ddctm475 comparetotmag 123.45600000000E-89 123.456E-89 -> -1 +ddctm476 comparetotmag 123.4560000000E+89 123.456E+89 -> -1 +ddctm477 comparetotmag 123.456000000E-89 123.456E-89 -> -1 +ddctm478 comparetotmag 123.45600000E+89 123.456E+89 -> -1 +ddctm479 comparetotmag 123.4560000E-89 123.456E-89 -> -1 +ddctm480 comparetotmag 123.456000E+89 123.456E+89 -> -1 +ddctm481 comparetotmag 123.45600E-89 123.456E-89 -> -1 +ddctm482 comparetotmag 123.4560E+89 123.456E+89 -> -1 +ddctm483 comparetotmag 123.456E-89 123.456E-89 -> 0 +ddctm487 comparetotmag 123.456E+89 123.4560000000000E+89 -> 1 +ddctm488 comparetotmag 123.456E-89 123.456000000000E-89 -> 1 +ddctm489 comparetotmag 123.456E+89 123.45600000000E+89 -> 1 +ddctm490 comparetotmag 123.456E-89 123.4560000000E-89 -> 1 +ddctm491 comparetotmag 123.456E+89 123.456000000E+89 -> 1 +ddctm492 comparetotmag 123.456E-89 123.45600000E-89 -> 1 +ddctm493 comparetotmag 123.456E+89 123.4560000E+89 -> 1 +ddctm494 comparetotmag 123.456E-89 123.456000E-89 -> 1 +ddctm495 comparetotmag 123.456E+89 123.45600E+89 -> 1 +ddctm496 comparetotmag 123.456E-89 123.4560E-89 -> 1 +ddctm497 comparetotmag 123.456E+89 123.456E+89 -> 0 + +-- wide-ranging, around precision; signs equal +ddctm498 comparetotmag 1 1E-17 -> 1 +ddctm499 comparetotmag 1 1E-16 -> 1 +ddctm500 comparetotmag 1 1E-15 -> 1 +ddctm501 comparetotmag 1 1E-14 -> 1 +ddctm502 comparetotmag 1 1E-13 -> 1 +ddctm503 comparetotmag 1 1E-12 -> 1 +ddctm504 comparetotmag 1 1E-11 -> 1 +ddctm505 comparetotmag 1 1E-10 -> 1 +ddctm506 comparetotmag 1 1E-9 -> 1 +ddctm507 comparetotmag 1 1E-8 -> 1 +ddctm508 comparetotmag 1 1E-7 -> 1 +ddctm509 comparetotmag 1 1E-6 -> 1 +ddctm510 comparetotmag 1 1E-5 -> 1 +ddctm511 comparetotmag 1 1E-4 -> 1 +ddctm512 comparetotmag 1 1E-3 -> 1 +ddctm513 comparetotmag 1 1E-2 -> 1 +ddctm514 comparetotmag 1 1E-1 -> 1 +ddctm515 comparetotmag 1 1E-0 -> 0 +ddctm516 comparetotmag 1 1E+1 -> -1 +ddctm517 comparetotmag 1 1E+2 -> -1 +ddctm518 comparetotmag 1 1E+3 -> -1 +ddctm519 comparetotmag 1 1E+4 -> -1 +ddctm521 comparetotmag 1 1E+5 -> -1 +ddctm522 comparetotmag 1 1E+6 -> -1 +ddctm523 comparetotmag 1 1E+7 -> -1 +ddctm524 comparetotmag 1 1E+8 -> -1 +ddctm525 comparetotmag 1 1E+9 -> -1 +ddctm526 comparetotmag 1 1E+10 -> -1 +ddctm527 comparetotmag 1 1E+11 -> -1 +ddctm528 comparetotmag 1 1E+12 -> -1 +ddctm529 comparetotmag 1 1E+13 -> -1 +ddctm530 comparetotmag 1 1E+14 -> -1 +ddctm531 comparetotmag 1 1E+15 -> -1 +ddctm532 comparetotmag 1 1E+16 -> -1 +ddctm533 comparetotmag 1 1E+17 -> -1 +-- LR swap +ddctm538 comparetotmag 1E-17 1 -> -1 +ddctm539 comparetotmag 1E-16 1 -> -1 +ddctm540 comparetotmag 1E-15 1 -> -1 +ddctm541 comparetotmag 1E-14 1 -> -1 +ddctm542 comparetotmag 1E-13 1 -> -1 +ddctm543 comparetotmag 1E-12 1 -> -1 +ddctm544 comparetotmag 1E-11 1 -> -1 +ddctm545 comparetotmag 1E-10 1 -> -1 +ddctm546 comparetotmag 1E-9 1 -> -1 +ddctm547 comparetotmag 1E-8 1 -> -1 +ddctm548 comparetotmag 1E-7 1 -> -1 +ddctm549 comparetotmag 1E-6 1 -> -1 +ddctm550 comparetotmag 1E-5 1 -> -1 +ddctm551 comparetotmag 1E-4 1 -> -1 +ddctm552 comparetotmag 1E-3 1 -> -1 +ddctm553 comparetotmag 1E-2 1 -> -1 +ddctm554 comparetotmag 1E-1 1 -> -1 +ddctm555 comparetotmag 1E-0 1 -> 0 +ddctm556 comparetotmag 1E+1 1 -> 1 +ddctm557 comparetotmag 1E+2 1 -> 1 +ddctm558 comparetotmag 1E+3 1 -> 1 +ddctm559 comparetotmag 1E+4 1 -> 1 +ddctm561 comparetotmag 1E+5 1 -> 1 +ddctm562 comparetotmag 1E+6 1 -> 1 +ddctm563 comparetotmag 1E+7 1 -> 1 +ddctm564 comparetotmag 1E+8 1 -> 1 +ddctm565 comparetotmag 1E+9 1 -> 1 +ddctm566 comparetotmag 1E+10 1 -> 1 +ddctm567 comparetotmag 1E+11 1 -> 1 +ddctm568 comparetotmag 1E+12 1 -> 1 +ddctm569 comparetotmag 1E+13 1 -> 1 +ddctm570 comparetotmag 1E+14 1 -> 1 +ddctm571 comparetotmag 1E+15 1 -> 1 +ddctm572 comparetotmag 1E+16 1 -> 1 +ddctm573 comparetotmag 1E+17 1 -> 1 +-- similar with a useful coefficient, one side only +ddctm578 comparetotmag 0.000000987654321 1E-17 -> 1 +ddctm579 comparetotmag 0.000000987654321 1E-16 -> 1 +ddctm580 comparetotmag 0.000000987654321 1E-15 -> 1 +ddctm581 comparetotmag 0.000000987654321 1E-14 -> 1 +ddctm582 comparetotmag 0.000000987654321 1E-13 -> 1 +ddctm583 comparetotmag 0.000000987654321 1E-12 -> 1 +ddctm584 comparetotmag 0.000000987654321 1E-11 -> 1 +ddctm585 comparetotmag 0.000000987654321 1E-10 -> 1 +ddctm586 comparetotmag 0.000000987654321 1E-9 -> 1 +ddctm587 comparetotmag 0.000000987654321 1E-8 -> 1 +ddctm588 comparetotmag 0.000000987654321 1E-7 -> 1 +ddctm589 comparetotmag 0.000000987654321 1E-6 -> -1 +ddctm590 comparetotmag 0.000000987654321 1E-5 -> -1 +ddctm591 comparetotmag 0.000000987654321 1E-4 -> -1 +ddctm592 comparetotmag 0.000000987654321 1E-3 -> -1 +ddctm593 comparetotmag 0.000000987654321 1E-2 -> -1 +ddctm594 comparetotmag 0.000000987654321 1E-1 -> -1 +ddctm595 comparetotmag 0.000000987654321 1E-0 -> -1 +ddctm596 comparetotmag 0.000000987654321 1E+1 -> -1 +ddctm597 comparetotmag 0.000000987654321 1E+2 -> -1 +ddctm598 comparetotmag 0.000000987654321 1E+3 -> -1 +ddctm599 comparetotmag 0.000000987654321 1E+4 -> -1 + +-- check some unit-y traps +ddctm600 comparetotmag 12 12.2345 -> -1 +ddctm601 comparetotmag 12.0 12.2345 -> -1 +ddctm602 comparetotmag 12.00 12.2345 -> -1 +ddctm603 comparetotmag 12.000 12.2345 -> -1 +ddctm604 comparetotmag 12.0000 12.2345 -> -1 +ddctm605 comparetotmag 12.00000 12.2345 -> -1 +ddctm606 comparetotmag 12.000000 12.2345 -> -1 +ddctm607 comparetotmag 12.0000000 12.2345 -> -1 +ddctm608 comparetotmag 12.00000000 12.2345 -> -1 +ddctm609 comparetotmag 12.000000000 12.2345 -> -1 +ddctm610 comparetotmag 12.1234 12 -> 1 +ddctm611 comparetotmag 12.1234 12.0 -> 1 +ddctm612 comparetotmag 12.1234 12.00 -> 1 +ddctm613 comparetotmag 12.1234 12.000 -> 1 +ddctm614 comparetotmag 12.1234 12.0000 -> 1 +ddctm615 comparetotmag 12.1234 12.00000 -> 1 +ddctm616 comparetotmag 12.1234 12.000000 -> 1 +ddctm617 comparetotmag 12.1234 12.0000000 -> 1 +ddctm618 comparetotmag 12.1234 12.00000000 -> 1 +ddctm619 comparetotmag 12.1234 12.000000000 -> 1 +ddctm620 comparetotmag -12 -12.2345 -> -1 +ddctm621 comparetotmag -12.0 -12.2345 -> -1 +ddctm622 comparetotmag -12.00 -12.2345 -> -1 +ddctm623 comparetotmag -12.000 -12.2345 -> -1 +ddctm624 comparetotmag -12.0000 -12.2345 -> -1 +ddctm625 comparetotmag -12.00000 -12.2345 -> -1 +ddctm626 comparetotmag -12.000000 -12.2345 -> -1 +ddctm627 comparetotmag -12.0000000 -12.2345 -> -1 +ddctm628 comparetotmag -12.00000000 -12.2345 -> -1 +ddctm629 comparetotmag -12.000000000 -12.2345 -> -1 +ddctm630 comparetotmag -12.1234 -12 -> 1 +ddctm631 comparetotmag -12.1234 -12.0 -> 1 +ddctm632 comparetotmag -12.1234 -12.00 -> 1 +ddctm633 comparetotmag -12.1234 -12.000 -> 1 +ddctm634 comparetotmag -12.1234 -12.0000 -> 1 +ddctm635 comparetotmag -12.1234 -12.00000 -> 1 +ddctm636 comparetotmag -12.1234 -12.000000 -> 1 +ddctm637 comparetotmag -12.1234 -12.0000000 -> 1 +ddctm638 comparetotmag -12.1234 -12.00000000 -> 1 +ddctm639 comparetotmag -12.1234 -12.000000000 -> 1 + +-- extended zeros +ddctm640 comparetotmag 0 0 -> 0 +ddctm641 comparetotmag 0 -0 -> 0 +ddctm642 comparetotmag 0 -0.0 -> 1 +ddctm643 comparetotmag 0 0.0 -> 1 +ddctm644 comparetotmag -0 0 -> 0 +ddctm645 comparetotmag -0 -0 -> 0 +ddctm646 comparetotmag -0 -0.0 -> 1 +ddctm647 comparetotmag -0 0.0 -> 1 +ddctm648 comparetotmag 0.0 0 -> -1 +ddctm649 comparetotmag 0.0 -0 -> -1 +ddctm650 comparetotmag 0.0 -0.0 -> 0 +ddctm651 comparetotmag 0.0 0.0 -> 0 +ddctm652 comparetotmag -0.0 0 -> -1 +ddctm653 comparetotmag -0.0 -0 -> -1 +ddctm654 comparetotmag -0.0 -0.0 -> 0 +ddctm655 comparetotmag -0.0 0.0 -> 0 + +ddctm656 comparetotmag -0E1 0.0 -> 1 +ddctm657 comparetotmag -0E2 0.0 -> 1 +ddctm658 comparetotmag 0E1 0.0 -> 1 +ddctm659 comparetotmag 0E2 0.0 -> 1 +ddctm660 comparetotmag -0E1 0 -> 1 +ddctm661 comparetotmag -0E2 0 -> 1 +ddctm662 comparetotmag 0E1 0 -> 1 +ddctm663 comparetotmag 0E2 0 -> 1 +ddctm664 comparetotmag -0E1 -0E1 -> 0 +ddctm665 comparetotmag -0E2 -0E1 -> 1 +ddctm666 comparetotmag 0E1 -0E1 -> 0 +ddctm667 comparetotmag 0E2 -0E1 -> 1 +ddctm668 comparetotmag -0E1 -0E2 -> -1 +ddctm669 comparetotmag -0E2 -0E2 -> 0 +ddctm670 comparetotmag 0E1 -0E2 -> -1 +ddctm671 comparetotmag 0E2 -0E2 -> 0 +ddctm672 comparetotmag -0E1 0E1 -> 0 +ddctm673 comparetotmag -0E2 0E1 -> 1 +ddctm674 comparetotmag 0E1 0E1 -> 0 +ddctm675 comparetotmag 0E2 0E1 -> 1 +ddctm676 comparetotmag -0E1 0E2 -> -1 +ddctm677 comparetotmag -0E2 0E2 -> 0 +ddctm678 comparetotmag 0E1 0E2 -> -1 +ddctm679 comparetotmag 0E2 0E2 -> 0 + +-- trailing zeros; unit-y +ddctm680 comparetotmag 12 12 -> 0 +ddctm681 comparetotmag 12 12.0 -> 1 +ddctm682 comparetotmag 12 12.00 -> 1 +ddctm683 comparetotmag 12 12.000 -> 1 +ddctm684 comparetotmag 12 12.0000 -> 1 +ddctm685 comparetotmag 12 12.00000 -> 1 +ddctm686 comparetotmag 12 12.000000 -> 1 +ddctm687 comparetotmag 12 12.0000000 -> 1 +ddctm688 comparetotmag 12 12.00000000 -> 1 +ddctm689 comparetotmag 12 12.000000000 -> 1 +ddctm690 comparetotmag 12 12 -> 0 +ddctm691 comparetotmag 12.0 12 -> -1 +ddctm692 comparetotmag 12.00 12 -> -1 +ddctm693 comparetotmag 12.000 12 -> -1 +ddctm694 comparetotmag 12.0000 12 -> -1 +ddctm695 comparetotmag 12.00000 12 -> -1 +ddctm696 comparetotmag 12.000000 12 -> -1 +ddctm697 comparetotmag 12.0000000 12 -> -1 +ddctm698 comparetotmag 12.00000000 12 -> -1 +ddctm699 comparetotmag 12.000000000 12 -> -1 + +-- old long operand checks +ddctm701 comparetotmag 12345678000 1 -> 1 +ddctm702 comparetotmag 1 12345678000 -> -1 +ddctm703 comparetotmag 1234567800 1 -> 1 +ddctm704 comparetotmag 1 1234567800 -> -1 +ddctm705 comparetotmag 1234567890 1 -> 1 +ddctm706 comparetotmag 1 1234567890 -> -1 +ddctm707 comparetotmag 1234567891 1 -> 1 +ddctm708 comparetotmag 1 1234567891 -> -1 +ddctm709 comparetotmag 12345678901 1 -> 1 +ddctm710 comparetotmag 1 12345678901 -> -1 +ddctm711 comparetotmag 1234567896 1 -> 1 +ddctm712 comparetotmag 1 1234567896 -> -1 +ddctm713 comparetotmag -1234567891 1 -> 1 +ddctm714 comparetotmag 1 -1234567891 -> -1 +ddctm715 comparetotmag -12345678901 1 -> 1 +ddctm716 comparetotmag 1 -12345678901 -> -1 +ddctm717 comparetotmag -1234567896 1 -> 1 +ddctm718 comparetotmag 1 -1234567896 -> -1 + +-- old residue cases +ddctm740 comparetotmag 1 0.9999999 -> 1 +ddctm741 comparetotmag 1 0.999999 -> 1 +ddctm742 comparetotmag 1 0.99999 -> 1 +ddctm743 comparetotmag 1 1.0000 -> 1 +ddctm744 comparetotmag 1 1.00001 -> -1 +ddctm745 comparetotmag 1 1.000001 -> -1 +ddctm746 comparetotmag 1 1.0000001 -> -1 +ddctm750 comparetotmag 0.9999999 1 -> -1 +ddctm751 comparetotmag 0.999999 1 -> -1 +ddctm752 comparetotmag 0.99999 1 -> -1 +ddctm753 comparetotmag 1.0000 1 -> -1 +ddctm754 comparetotmag 1.00001 1 -> 1 +ddctm755 comparetotmag 1.000001 1 -> 1 +ddctm756 comparetotmag 1.0000001 1 -> 1 + +-- Specials +ddctm780 comparetotmag Inf -Inf -> 0 +ddctm781 comparetotmag Inf -1000 -> 1 +ddctm782 comparetotmag Inf -1 -> 1 +ddctm783 comparetotmag Inf -0 -> 1 +ddctm784 comparetotmag Inf 0 -> 1 +ddctm785 comparetotmag Inf 1 -> 1 +ddctm786 comparetotmag Inf 1000 -> 1 +ddctm787 comparetotmag Inf Inf -> 0 +ddctm788 comparetotmag -1000 Inf -> -1 +ddctm789 comparetotmag -Inf Inf -> 0 +ddctm790 comparetotmag -1 Inf -> -1 +ddctm791 comparetotmag -0 Inf -> -1 +ddctm792 comparetotmag 0 Inf -> -1 +ddctm793 comparetotmag 1 Inf -> -1 +ddctm794 comparetotmag 1000 Inf -> -1 +ddctm795 comparetotmag Inf Inf -> 0 + +ddctm800 comparetotmag -Inf -Inf -> 0 +ddctm801 comparetotmag -Inf -1000 -> 1 +ddctm802 comparetotmag -Inf -1 -> 1 +ddctm803 comparetotmag -Inf -0 -> 1 +ddctm804 comparetotmag -Inf 0 -> 1 +ddctm805 comparetotmag -Inf 1 -> 1 +ddctm806 comparetotmag -Inf 1000 -> 1 +ddctm807 comparetotmag -Inf Inf -> 0 +ddctm808 comparetotmag -Inf -Inf -> 0 +ddctm809 comparetotmag -1000 -Inf -> -1 +ddctm810 comparetotmag -1 -Inf -> -1 +ddctm811 comparetotmag -0 -Inf -> -1 +ddctm812 comparetotmag 0 -Inf -> -1 +ddctm813 comparetotmag 1 -Inf -> -1 +ddctm814 comparetotmag 1000 -Inf -> -1 +ddctm815 comparetotmag Inf -Inf -> 0 + +ddctm821 comparetotmag NaN -Inf -> 1 +ddctm822 comparetotmag NaN -1000 -> 1 +ddctm823 comparetotmag NaN -1 -> 1 +ddctm824 comparetotmag NaN -0 -> 1 +ddctm825 comparetotmag NaN 0 -> 1 +ddctm826 comparetotmag NaN 1 -> 1 +ddctm827 comparetotmag NaN 1000 -> 1 +ddctm828 comparetotmag NaN Inf -> 1 +ddctm829 comparetotmag NaN NaN -> 0 +ddctm830 comparetotmag -Inf NaN -> -1 +ddctm831 comparetotmag -1000 NaN -> -1 +ddctm832 comparetotmag -1 NaN -> -1 +ddctm833 comparetotmag -0 NaN -> -1 +ddctm834 comparetotmag 0 NaN -> -1 +ddctm835 comparetotmag 1 NaN -> -1 +ddctm836 comparetotmag 1000 NaN -> -1 +ddctm837 comparetotmag Inf NaN -> -1 +ddctm838 comparetotmag -NaN -NaN -> 0 +ddctm839 comparetotmag +NaN -NaN -> 0 +ddctm840 comparetotmag -NaN +NaN -> 0 + +ddctm841 comparetotmag sNaN -sNaN -> 0 +ddctm842 comparetotmag sNaN -NaN -> -1 +ddctm843 comparetotmag sNaN -Inf -> 1 +ddctm844 comparetotmag sNaN -1000 -> 1 +ddctm845 comparetotmag sNaN -1 -> 1 +ddctm846 comparetotmag sNaN -0 -> 1 +ddctm847 comparetotmag sNaN 0 -> 1 +ddctm848 comparetotmag sNaN 1 -> 1 +ddctm849 comparetotmag sNaN 1000 -> 1 +ddctm850 comparetotmag sNaN NaN -> -1 +ddctm851 comparetotmag sNaN sNaN -> 0 + +ddctm852 comparetotmag -sNaN sNaN -> 0 +ddctm853 comparetotmag -NaN sNaN -> 1 +ddctm854 comparetotmag -Inf sNaN -> -1 +ddctm855 comparetotmag -1000 sNaN -> -1 +ddctm856 comparetotmag -1 sNaN -> -1 +ddctm857 comparetotmag -0 sNaN -> -1 +ddctm858 comparetotmag 0 sNaN -> -1 +ddctm859 comparetotmag 1 sNaN -> -1 +ddctm860 comparetotmag 1000 sNaN -> -1 +ddctm861 comparetotmag Inf sNaN -> -1 +ddctm862 comparetotmag NaN sNaN -> 1 +ddctm863 comparetotmag sNaN sNaN -> 0 + +ddctm871 comparetotmag -sNaN -sNaN -> 0 +ddctm872 comparetotmag -sNaN -NaN -> -1 +ddctm873 comparetotmag -sNaN -Inf -> 1 +ddctm874 comparetotmag -sNaN -1000 -> 1 +ddctm875 comparetotmag -sNaN -1 -> 1 +ddctm876 comparetotmag -sNaN -0 -> 1 +ddctm877 comparetotmag -sNaN 0 -> 1 +ddctm878 comparetotmag -sNaN 1 -> 1 +ddctm879 comparetotmag -sNaN 1000 -> 1 +ddctm880 comparetotmag -sNaN NaN -> -1 +ddctm881 comparetotmag -sNaN sNaN -> 0 + +ddctm882 comparetotmag -sNaN -sNaN -> 0 +ddctm883 comparetotmag -NaN -sNaN -> 1 +ddctm884 comparetotmag -Inf -sNaN -> -1 +ddctm885 comparetotmag -1000 -sNaN -> -1 +ddctm886 comparetotmag -1 -sNaN -> -1 +ddctm887 comparetotmag -0 -sNaN -> -1 +ddctm888 comparetotmag 0 -sNaN -> -1 +ddctm889 comparetotmag 1 -sNaN -> -1 +ddctm890 comparetotmag 1000 -sNaN -> -1 +ddctm891 comparetotmag Inf -sNaN -> -1 +ddctm892 comparetotmag NaN -sNaN -> 1 +ddctm893 comparetotmag sNaN -sNaN -> 0 + +-- NaNs with payload +ddctm960 comparetotmag NaN9 -Inf -> 1 +ddctm961 comparetotmag NaN8 999 -> 1 +ddctm962 comparetotmag NaN77 Inf -> 1 +ddctm963 comparetotmag -NaN67 NaN5 -> 1 +ddctm964 comparetotmag -Inf -NaN4 -> -1 +ddctm965 comparetotmag -999 -NaN33 -> -1 +ddctm966 comparetotmag Inf NaN2 -> -1 + +ddctm970 comparetotmag -NaN41 -NaN42 -> -1 +ddctm971 comparetotmag +NaN41 -NaN42 -> -1 +ddctm972 comparetotmag -NaN41 +NaN42 -> -1 +ddctm973 comparetotmag +NaN41 +NaN42 -> -1 +ddctm974 comparetotmag -NaN42 -NaN01 -> 1 +ddctm975 comparetotmag +NaN42 -NaN01 -> 1 +ddctm976 comparetotmag -NaN42 +NaN01 -> 1 +ddctm977 comparetotmag +NaN42 +NaN01 -> 1 + +ddctm980 comparetotmag -sNaN771 -sNaN772 -> -1 +ddctm981 comparetotmag +sNaN771 -sNaN772 -> -1 +ddctm982 comparetotmag -sNaN771 +sNaN772 -> -1 +ddctm983 comparetotmag +sNaN771 +sNaN772 -> -1 +ddctm984 comparetotmag -sNaN772 -sNaN771 -> 1 +ddctm985 comparetotmag +sNaN772 -sNaN771 -> 1 +ddctm986 comparetotmag -sNaN772 +sNaN771 -> 1 +ddctm987 comparetotmag +sNaN772 +sNaN771 -> 1 + +ddctm991 comparetotmag -sNaN99 -Inf -> 1 +ddctm992 comparetotmag sNaN98 -11 -> 1 +ddctm993 comparetotmag sNaN97 NaN -> -1 +ddctm994 comparetotmag sNaN16 sNaN94 -> -1 +ddctm995 comparetotmag NaN85 sNaN83 -> 1 +ddctm996 comparetotmag -Inf sNaN92 -> -1 +ddctm997 comparetotmag 088 sNaN81 -> -1 +ddctm998 comparetotmag Inf sNaN90 -> -1 +ddctm999 comparetotmag NaN -sNaN89 -> 1 + +-- spread zeros +ddctm1110 comparetotmag 0E-383 0 -> -1 +ddctm1111 comparetotmag 0E-383 -0 -> -1 +ddctm1112 comparetotmag -0E-383 0 -> -1 +ddctm1113 comparetotmag -0E-383 -0 -> -1 +ddctm1114 comparetotmag 0E-383 0E+384 -> -1 +ddctm1115 comparetotmag 0E-383 -0E+384 -> -1 +ddctm1116 comparetotmag -0E-383 0E+384 -> -1 +ddctm1117 comparetotmag -0E-383 -0E+384 -> -1 +ddctm1118 comparetotmag 0 0E+384 -> -1 +ddctm1119 comparetotmag 0 -0E+384 -> -1 +ddctm1120 comparetotmag -0 0E+384 -> -1 +ddctm1121 comparetotmag -0 -0E+384 -> -1 + +ddctm1130 comparetotmag 0E+384 0 -> 1 +ddctm1131 comparetotmag 0E+384 -0 -> 1 +ddctm1132 comparetotmag -0E+384 0 -> 1 +ddctm1133 comparetotmag -0E+384 -0 -> 1 +ddctm1134 comparetotmag 0E+384 0E-383 -> 1 +ddctm1135 comparetotmag 0E+384 -0E-383 -> 1 +ddctm1136 comparetotmag -0E+384 0E-383 -> 1 +ddctm1137 comparetotmag -0E+384 -0E-383 -> 1 +ddctm1138 comparetotmag 0 0E-383 -> 1 +ddctm1139 comparetotmag 0 -0E-383 -> 1 +ddctm1140 comparetotmag -0 0E-383 -> 1 +ddctm1141 comparetotmag -0 -0E-383 -> 1 + +-- Null tests +ddctm9990 comparetotmag 10 # -> NaN Invalid_operation +ddctm9991 comparetotmag # 10 -> NaN Invalid_operation Added: python/branches/release25-maint/Lib/test/decimaltestdata/ddCopy.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/ddCopy.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,88 @@ +------------------------------------------------------------------------ +-- ddCopy.decTest -- quiet decDouble copy -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- All operands and results are decDoubles. +precision: 16 +maxExponent: 384 +minExponent: -383 +extended: 1 +clamp: 1 +rounding: half_even + +-- Sanity check +ddcpy001 copy +7.50 -> 7.50 + +-- Infinities +ddcpy011 copy Infinity -> Infinity +ddcpy012 copy -Infinity -> -Infinity + +-- NaNs, 0 payload +ddcpy021 copy NaN -> NaN +ddcpy022 copy -NaN -> -NaN +ddcpy023 copy sNaN -> sNaN +ddcpy024 copy -sNaN -> -sNaN + +-- NaNs, non-0 payload +ddcpy031 copy NaN10 -> NaN10 +ddcpy032 copy -NaN10 -> -NaN10 +ddcpy033 copy sNaN10 -> sNaN10 +ddcpy034 copy -sNaN10 -> -sNaN10 +ddcpy035 copy NaN7 -> NaN7 +ddcpy036 copy -NaN7 -> -NaN7 +ddcpy037 copy sNaN101 -> sNaN101 +ddcpy038 copy -sNaN101 -> -sNaN101 + +-- finites +ddcpy101 copy 7 -> 7 +ddcpy102 copy -7 -> -7 +ddcpy103 copy 75 -> 75 +ddcpy104 copy -75 -> -75 +ddcpy105 copy 7.50 -> 7.50 +ddcpy106 copy -7.50 -> -7.50 +ddcpy107 copy 7.500 -> 7.500 +ddcpy108 copy -7.500 -> -7.500 + +-- zeros +ddcpy111 copy 0 -> 0 +ddcpy112 copy -0 -> -0 +ddcpy113 copy 0E+4 -> 0E+4 +ddcpy114 copy -0E+4 -> -0E+4 +ddcpy115 copy 0.0000 -> 0.0000 +ddcpy116 copy -0.0000 -> -0.0000 +ddcpy117 copy 0E-141 -> 0E-141 +ddcpy118 copy -0E-141 -> -0E-141 + +-- full coefficients, alternating bits +ddcpy121 copy 2682682682682682 -> 2682682682682682 +ddcpy122 copy -2682682682682682 -> -2682682682682682 +ddcpy123 copy 1341341341341341 -> 1341341341341341 +ddcpy124 copy -1341341341341341 -> -1341341341341341 + +-- Nmax, Nmin, Ntiny +ddcpy131 copy 9.999999999999999E+384 -> 9.999999999999999E+384 +ddcpy132 copy 1E-383 -> 1E-383 +ddcpy133 copy 1.000000000000000E-383 -> 1.000000000000000E-383 +ddcpy134 copy 1E-398 -> 1E-398 + +ddcpy135 copy -1E-398 -> -1E-398 +ddcpy136 copy -1.000000000000000E-383 -> -1.000000000000000E-383 +ddcpy137 copy -1E-383 -> -1E-383 +ddcpy138 copy -9.999999999999999E+384 -> -9.999999999999999E+384 Added: python/branches/release25-maint/Lib/test/decimaltestdata/ddCopyAbs.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/ddCopyAbs.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,88 @@ +------------------------------------------------------------------------ +-- ddCopyAbs.decTest -- quiet decDouble copy and set sign to zero -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- All operands and results are decDoubles. +precision: 16 +maxExponent: 384 +minExponent: -383 +extended: 1 +clamp: 1 +rounding: half_even + +-- Sanity check +ddcpa001 copyabs +7.50 -> 7.50 + +-- Infinities +ddcpa011 copyabs Infinity -> Infinity +ddcpa012 copyabs -Infinity -> Infinity + +-- NaNs, 0 payload +ddcpa021 copyabs NaN -> NaN +ddcpa022 copyabs -NaN -> NaN +ddcpa023 copyabs sNaN -> sNaN +ddcpa024 copyabs -sNaN -> sNaN + +-- NaNs, non-0 payload +ddcpa031 copyabs NaN10 -> NaN10 +ddcpa032 copyabs -NaN15 -> NaN15 +ddcpa033 copyabs sNaN15 -> sNaN15 +ddcpa034 copyabs -sNaN10 -> sNaN10 +ddcpa035 copyabs NaN7 -> NaN7 +ddcpa036 copyabs -NaN7 -> NaN7 +ddcpa037 copyabs sNaN101 -> sNaN101 +ddcpa038 copyabs -sNaN101 -> sNaN101 + +-- finites +ddcpa101 copyabs 7 -> 7 +ddcpa102 copyabs -7 -> 7 +ddcpa103 copyabs 75 -> 75 +ddcpa104 copyabs -75 -> 75 +ddcpa105 copyabs 7.10 -> 7.10 +ddcpa106 copyabs -7.10 -> 7.10 +ddcpa107 copyabs 7.500 -> 7.500 +ddcpa108 copyabs -7.500 -> 7.500 + +-- zeros +ddcpa111 copyabs 0 -> 0 +ddcpa112 copyabs -0 -> 0 +ddcpa113 copyabs 0E+6 -> 0E+6 +ddcpa114 copyabs -0E+6 -> 0E+6 +ddcpa115 copyabs 0.0000 -> 0.0000 +ddcpa116 copyabs -0.0000 -> 0.0000 +ddcpa117 copyabs 0E-141 -> 0E-141 +ddcpa118 copyabs -0E-141 -> 0E-141 + +-- full coefficients, alternating bits +ddcpa121 copyabs 2682682682682682 -> 2682682682682682 +ddcpa122 copyabs -2682682682682682 -> 2682682682682682 +ddcpa123 copyabs 1341341341341341 -> 1341341341341341 +ddcpa124 copyabs -1341341341341341 -> 1341341341341341 + +-- Nmax, Nmin, Ntiny +ddcpa131 copyabs 9.999999999999999E+384 -> 9.999999999999999E+384 +ddcpa132 copyabs 1E-383 -> 1E-383 +ddcpa133 copyabs 1.000000000000000E-383 -> 1.000000000000000E-383 +ddcpa134 copyabs 1E-398 -> 1E-398 + +ddcpa135 copyabs -1E-398 -> 1E-398 +ddcpa136 copyabs -1.000000000000000E-383 -> 1.000000000000000E-383 +ddcpa137 copyabs -1E-383 -> 1E-383 +ddcpa138 copyabs -9.999999999999999E+384 -> 9.999999999999999E+384 Added: python/branches/release25-maint/Lib/test/decimaltestdata/ddCopyNegate.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/ddCopyNegate.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,88 @@ +------------------------------------------------------------------------ +-- ddCopyNegate.decTest -- quiet decDouble copy and negate -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- All operands and results are decDoubles. +precision: 16 +maxExponent: 384 +minExponent: -383 +extended: 1 +clamp: 1 +rounding: half_even + +-- Sanity check +ddcpn001 copynegate +7.50 -> -7.50 + +-- Infinities +ddcpn011 copynegate Infinity -> -Infinity +ddcpn012 copynegate -Infinity -> Infinity + +-- NaNs, 0 payload +ddcpn021 copynegate NaN -> -NaN +ddcpn022 copynegate -NaN -> NaN +ddcpn023 copynegate sNaN -> -sNaN +ddcpn024 copynegate -sNaN -> sNaN + +-- NaNs, non-0 payload +ddcpn031 copynegate NaN13 -> -NaN13 +ddcpn032 copynegate -NaN13 -> NaN13 +ddcpn033 copynegate sNaN13 -> -sNaN13 +ddcpn034 copynegate -sNaN13 -> sNaN13 +ddcpn035 copynegate NaN70 -> -NaN70 +ddcpn036 copynegate -NaN70 -> NaN70 +ddcpn037 copynegate sNaN101 -> -sNaN101 +ddcpn038 copynegate -sNaN101 -> sNaN101 + +-- finites +ddcpn101 copynegate 7 -> -7 +ddcpn102 copynegate -7 -> 7 +ddcpn103 copynegate 75 -> -75 +ddcpn104 copynegate -75 -> 75 +ddcpn105 copynegate 7.50 -> -7.50 +ddcpn106 copynegate -7.50 -> 7.50 +ddcpn107 copynegate 7.500 -> -7.500 +ddcpn108 copynegate -7.500 -> 7.500 + +-- zeros +ddcpn111 copynegate 0 -> -0 +ddcpn112 copynegate -0 -> 0 +ddcpn113 copynegate 0E+4 -> -0E+4 +ddcpn114 copynegate -0E+4 -> 0E+4 +ddcpn115 copynegate 0.0000 -> -0.0000 +ddcpn116 copynegate -0.0000 -> 0.0000 +ddcpn117 copynegate 0E-141 -> -0E-141 +ddcpn118 copynegate -0E-141 -> 0E-141 + +-- full coefficients, alternating bits +ddcpn121 copynegate 2682682682682682 -> -2682682682682682 +ddcpn122 copynegate -2682682682682682 -> 2682682682682682 +ddcpn123 copynegate 1341341341341341 -> -1341341341341341 +ddcpn124 copynegate -1341341341341341 -> 1341341341341341 + +-- Nmax, Nmin, Ntiny +ddcpn131 copynegate 9.999999999999999E+384 -> -9.999999999999999E+384 +ddcpn132 copynegate 1E-383 -> -1E-383 +ddcpn133 copynegate 1.000000000000000E-383 -> -1.000000000000000E-383 +ddcpn134 copynegate 1E-398 -> -1E-398 + +ddcpn135 copynegate -1E-398 -> 1E-398 +ddcpn136 copynegate -1.000000000000000E-383 -> 1.000000000000000E-383 +ddcpn137 copynegate -1E-383 -> 1E-383 +ddcpn138 copynegate -9.999999999999999E+384 -> 9.999999999999999E+384 Added: python/branches/release25-maint/Lib/test/decimaltestdata/ddCopySign.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/ddCopySign.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,175 @@ +------------------------------------------------------------------------ +-- ddCopySign.decTest -- quiet decDouble copy with sign from rhs -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- All operands and results are decDoubles. +precision: 16 +maxExponent: 384 +minExponent: -383 +extended: 1 +clamp: 1 +rounding: half_even + +-- Sanity check +ddcps001 copysign +7.50 11 -> 7.50 + +-- Infinities +ddcps011 copysign Infinity 11 -> Infinity +ddcps012 copysign -Infinity 11 -> Infinity + +-- NaNs, 0 payload +ddcps021 copysign NaN 11 -> NaN +ddcps022 copysign -NaN 11 -> NaN +ddcps023 copysign sNaN 11 -> sNaN +ddcps024 copysign -sNaN 11 -> sNaN + +-- NaNs, non-0 payload +ddcps031 copysign NaN10 11 -> NaN10 +ddcps032 copysign -NaN10 11 -> NaN10 +ddcps033 copysign sNaN10 11 -> sNaN10 +ddcps034 copysign -sNaN10 11 -> sNaN10 +ddcps035 copysign NaN7 11 -> NaN7 +ddcps036 copysign -NaN7 11 -> NaN7 +ddcps037 copysign sNaN101 11 -> sNaN101 +ddcps038 copysign -sNaN101 11 -> sNaN101 + +-- finites +ddcps101 copysign 7 11 -> 7 +ddcps102 copysign -7 11 -> 7 +ddcps103 copysign 75 11 -> 75 +ddcps104 copysign -75 11 -> 75 +ddcps105 copysign 7.50 11 -> 7.50 +ddcps106 copysign -7.50 11 -> 7.50 +ddcps107 copysign 7.500 11 -> 7.500 +ddcps108 copysign -7.500 11 -> 7.500 + +-- zeros +ddcps111 copysign 0 11 -> 0 +ddcps112 copysign -0 11 -> 0 +ddcps113 copysign 0E+4 11 -> 0E+4 +ddcps114 copysign -0E+4 11 -> 0E+4 +ddcps115 copysign 0.0000 11 -> 0.0000 +ddcps116 copysign -0.0000 11 -> 0.0000 +ddcps117 copysign 0E-141 11 -> 0E-141 +ddcps118 copysign -0E-141 11 -> 0E-141 + +-- full coefficients, alternating bits +ddcps121 copysign 2682682682682682 11 -> 2682682682682682 +ddcps122 copysign -2682682682682682 11 -> 2682682682682682 +ddcps123 copysign 1341341341341341 11 -> 1341341341341341 +ddcps124 copysign -1341341341341341 11 -> 1341341341341341 + +-- Nmax, Nmin, Ntiny +ddcps131 copysign 9.999999999999999E+384 11 -> 9.999999999999999E+384 +ddcps132 copysign 1E-383 11 -> 1E-383 +ddcps133 copysign 1.000000000000000E-383 11 -> 1.000000000000000E-383 +ddcps134 copysign 1E-398 11 -> 1E-398 + +ddcps135 copysign -1E-398 11 -> 1E-398 +ddcps136 copysign -1.000000000000000E-383 11 -> 1.000000000000000E-383 +ddcps137 copysign -1E-383 11 -> 1E-383 +ddcps138 copysign -9.999999999999999E+384 11 -> 9.999999999999999E+384 + +-- repeat with negative RHS + +-- Infinities +ddcps211 copysign Infinity -34 -> -Infinity +ddcps212 copysign -Infinity -34 -> -Infinity + +-- NaNs, 0 payload +ddcps221 copysign NaN -34 -> -NaN +ddcps222 copysign -NaN -34 -> -NaN +ddcps223 copysign sNaN -34 -> -sNaN +ddcps224 copysign -sNaN -34 -> -sNaN + +-- NaNs, non-0 payload +ddcps231 copysign NaN10 -34 -> -NaN10 +ddcps232 copysign -NaN10 -34 -> -NaN10 +ddcps233 copysign sNaN10 -34 -> -sNaN10 +ddcps234 copysign -sNaN10 -34 -> -sNaN10 +ddcps235 copysign NaN7 -34 -> -NaN7 +ddcps236 copysign -NaN7 -34 -> -NaN7 +ddcps237 copysign sNaN101 -34 -> -sNaN101 +ddcps238 copysign -sNaN101 -34 -> -sNaN101 + +-- finites +ddcps301 copysign 7 -34 -> -7 +ddcps302 copysign -7 -34 -> -7 +ddcps303 copysign 75 -34 -> -75 +ddcps304 copysign -75 -34 -> -75 +ddcps305 copysign 7.50 -34 -> -7.50 +ddcps306 copysign -7.50 -34 -> -7.50 +ddcps307 copysign 7.500 -34 -> -7.500 +ddcps308 copysign -7.500 -34 -> -7.500 + +-- zeros +ddcps311 copysign 0 -34 -> -0 +ddcps312 copysign -0 -34 -> -0 +ddcps313 copysign 0E+4 -34 -> -0E+4 +ddcps314 copysign -0E+4 -34 -> -0E+4 +ddcps315 copysign 0.0000 -34 -> -0.0000 +ddcps316 copysign -0.0000 -34 -> -0.0000 +ddcps317 copysign 0E-141 -34 -> -0E-141 +ddcps318 copysign -0E-141 -34 -> -0E-141 + +-- full coefficients, alternating bits +ddcps321 copysign 2682682682682682 -34 -> -2682682682682682 +ddcps322 copysign -2682682682682682 -34 -> -2682682682682682 +ddcps323 copysign 1341341341341341 -34 -> -1341341341341341 +ddcps324 copysign -1341341341341341 -34 -> -1341341341341341 + +-- Nmax, Nmin, Ntiny +ddcps331 copysign 9.999999999999999E+384 -34 -> -9.999999999999999E+384 +ddcps332 copysign 1E-383 -34 -> -1E-383 +ddcps333 copysign 1.000000000000000E-383 -34 -> -1.000000000000000E-383 +ddcps334 copysign 1E-398 -34 -> -1E-398 + +ddcps335 copysign -1E-398 -34 -> -1E-398 +ddcps336 copysign -1.000000000000000E-383 -34 -> -1.000000000000000E-383 +ddcps337 copysign -1E-383 -34 -> -1E-383 +ddcps338 copysign -9.999999999999999E+384 -34 -> -9.999999999999999E+384 + +-- Other kinds of RHS +ddcps401 copysign 701 -34 -> -701 +ddcps402 copysign -720 -34 -> -720 +ddcps403 copysign 701 -0 -> -701 +ddcps404 copysign -720 -0 -> -720 +ddcps405 copysign 701 +0 -> 701 +ddcps406 copysign -720 +0 -> 720 +ddcps407 copysign 701 +34 -> 701 +ddcps408 copysign -720 +34 -> 720 + +ddcps413 copysign 701 -Inf -> -701 +ddcps414 copysign -720 -Inf -> -720 +ddcps415 copysign 701 +Inf -> 701 +ddcps416 copysign -720 +Inf -> 720 + +ddcps420 copysign 701 -NaN -> -701 +ddcps421 copysign -720 -NaN -> -720 +ddcps422 copysign 701 +NaN -> 701 +ddcps423 copysign -720 +NaN -> 720 +ddcps425 copysign -720 +NaN8 -> 720 + +ddcps426 copysign 701 -sNaN -> -701 +ddcps427 copysign -720 -sNaN -> -720 +ddcps428 copysign 701 +sNaN -> 701 +ddcps429 copysign -720 +sNaN -> 720 +ddcps430 copysign -720 +sNaN3 -> 720 + Added: python/branches/release25-maint/Lib/test/decimaltestdata/ddDivide.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/ddDivide.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,854 @@ +------------------------------------------------------------------------ +-- ddDivide.decTest -- decDouble division -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +precision: 16 +maxExponent: 384 +minExponent: -383 +extended: 1 +clamp: 1 +rounding: half_even + +-- sanity checks +dddiv001 divide 1 1 -> 1 +dddiv002 divide 2 1 -> 2 +dddiv003 divide 1 2 -> 0.5 +dddiv004 divide 2 2 -> 1 +dddiv005 divide 0 1 -> 0 +dddiv006 divide 0 2 -> 0 +dddiv007 divide 1 3 -> 0.3333333333333333 Inexact Rounded +dddiv008 divide 2 3 -> 0.6666666666666667 Inexact Rounded +dddiv009 divide 3 3 -> 1 + +dddiv010 divide 2.4 1 -> 2.4 +dddiv011 divide 2.4 -1 -> -2.4 +dddiv012 divide -2.4 1 -> -2.4 +dddiv013 divide -2.4 -1 -> 2.4 +dddiv014 divide 2.40 1 -> 2.40 +dddiv015 divide 2.400 1 -> 2.400 +dddiv016 divide 2.4 2 -> 1.2 +dddiv017 divide 2.400 2 -> 1.200 +dddiv018 divide 2. 2 -> 1 +dddiv019 divide 20 20 -> 1 + +dddiv020 divide 187 187 -> 1 +dddiv021 divide 5 2 -> 2.5 +dddiv022 divide 50 20 -> 2.5 +dddiv023 divide 500 200 -> 2.5 +dddiv024 divide 50.0 20.0 -> 2.5 +dddiv025 divide 5.00 2.00 -> 2.5 +dddiv026 divide 5 2.0 -> 2.5 +dddiv027 divide 5 2.000 -> 2.5 +dddiv028 divide 5 0.20 -> 25 +dddiv029 divide 5 0.200 -> 25 +dddiv030 divide 10 1 -> 10 +dddiv031 divide 100 1 -> 100 +dddiv032 divide 1000 1 -> 1000 +dddiv033 divide 1000 100 -> 10 + +dddiv035 divide 1 2 -> 0.5 +dddiv036 divide 1 4 -> 0.25 +dddiv037 divide 1 8 -> 0.125 +dddiv038 divide 1 16 -> 0.0625 +dddiv039 divide 1 32 -> 0.03125 +dddiv040 divide 1 64 -> 0.015625 +dddiv041 divide 1 -2 -> -0.5 +dddiv042 divide 1 -4 -> -0.25 +dddiv043 divide 1 -8 -> -0.125 +dddiv044 divide 1 -16 -> -0.0625 +dddiv045 divide 1 -32 -> -0.03125 +dddiv046 divide 1 -64 -> -0.015625 +dddiv047 divide -1 2 -> -0.5 +dddiv048 divide -1 4 -> -0.25 +dddiv049 divide -1 8 -> -0.125 +dddiv050 divide -1 16 -> -0.0625 +dddiv051 divide -1 32 -> -0.03125 +dddiv052 divide -1 64 -> -0.015625 +dddiv053 divide -1 -2 -> 0.5 +dddiv054 divide -1 -4 -> 0.25 +dddiv055 divide -1 -8 -> 0.125 +dddiv056 divide -1 -16 -> 0.0625 +dddiv057 divide -1 -32 -> 0.03125 +dddiv058 divide -1 -64 -> 0.015625 + +-- bcdTime +dddiv060 divide 1 7 -> 0.1428571428571429 Inexact Rounded +dddiv061 divide 1.2345678 1.9876543 -> 0.6211179680490717 Inexact Rounded + +-- 1234567890123456 +dddiv071 divide 9999999999999999 1 -> 9999999999999999 +dddiv072 divide 999999999999999 1 -> 999999999999999 +dddiv073 divide 99999999999999 1 -> 99999999999999 +dddiv074 divide 9999999999999 1 -> 9999999999999 +dddiv075 divide 999999999999 1 -> 999999999999 +dddiv076 divide 99999999999 1 -> 99999999999 +dddiv077 divide 9999999999 1 -> 9999999999 +dddiv078 divide 999999999 1 -> 999999999 +dddiv079 divide 99999999 1 -> 99999999 +dddiv080 divide 9999999 1 -> 9999999 +dddiv081 divide 999999 1 -> 999999 +dddiv082 divide 99999 1 -> 99999 +dddiv083 divide 9999 1 -> 9999 +dddiv084 divide 999 1 -> 999 +dddiv085 divide 99 1 -> 99 +dddiv086 divide 9 1 -> 9 + +dddiv090 divide 0. 1 -> 0 +dddiv091 divide .0 1 -> 0.0 +dddiv092 divide 0.00 1 -> 0.00 +dddiv093 divide 0.00E+9 1 -> 0E+7 +dddiv094 divide 0.0000E-50 1 -> 0E-54 + +dddiv095 divide 1 1E-8 -> 1E+8 +dddiv096 divide 1 1E-9 -> 1E+9 +dddiv097 divide 1 1E-10 -> 1E+10 +dddiv098 divide 1 1E-11 -> 1E+11 +dddiv099 divide 1 1E-12 -> 1E+12 + +dddiv100 divide 1 1 -> 1 +dddiv101 divide 1 2 -> 0.5 +dddiv102 divide 1 3 -> 0.3333333333333333 Inexact Rounded +dddiv103 divide 1 4 -> 0.25 +dddiv104 divide 1 5 -> 0.2 +dddiv105 divide 1 6 -> 0.1666666666666667 Inexact Rounded +dddiv106 divide 1 7 -> 0.1428571428571429 Inexact Rounded +dddiv107 divide 1 8 -> 0.125 +dddiv108 divide 1 9 -> 0.1111111111111111 Inexact Rounded +dddiv109 divide 1 10 -> 0.1 +dddiv110 divide 1 1 -> 1 +dddiv111 divide 2 1 -> 2 +dddiv112 divide 3 1 -> 3 +dddiv113 divide 4 1 -> 4 +dddiv114 divide 5 1 -> 5 +dddiv115 divide 6 1 -> 6 +dddiv116 divide 7 1 -> 7 +dddiv117 divide 8 1 -> 8 +dddiv118 divide 9 1 -> 9 +dddiv119 divide 10 1 -> 10 + +dddiv120 divide 3E+1 0.001 -> 3E+4 +dddiv121 divide 2.200 2 -> 1.100 + +dddiv130 divide 12345 4.999 -> 2469.493898779756 Inexact Rounded +dddiv131 divide 12345 4.99 -> 2473.947895791583 Inexact Rounded +dddiv132 divide 12345 4.9 -> 2519.387755102041 Inexact Rounded +dddiv133 divide 12345 5 -> 2469 +dddiv134 divide 12345 5.1 -> 2420.588235294118 Inexact Rounded +dddiv135 divide 12345 5.01 -> 2464.071856287425 Inexact Rounded +dddiv136 divide 12345 5.001 -> 2468.506298740252 Inexact Rounded + +-- test possibly imprecise results +dddiv220 divide 391 597 -> 0.6549413735343384 Inexact Rounded +dddiv221 divide 391 -597 -> -0.6549413735343384 Inexact Rounded +dddiv222 divide -391 597 -> -0.6549413735343384 Inexact Rounded +dddiv223 divide -391 -597 -> 0.6549413735343384 Inexact Rounded + +-- test some cases that are close to exponent overflow +dddiv270 divide 1 1e384 -> 1E-384 Subnormal +dddiv271 divide 1 0.9e384 -> 1.11111111111111E-384 Rounded Inexact Subnormal Underflow +dddiv272 divide 1 0.99e384 -> 1.01010101010101E-384 Rounded Inexact Subnormal Underflow +dddiv273 divide 1 0.9999999999999999e384 -> 1.00000000000000E-384 Rounded Inexact Subnormal Underflow +dddiv274 divide 9e384 1 -> 9.000000000000000E+384 Clamped +dddiv275 divide 9.9e384 1 -> 9.900000000000000E+384 Clamped +dddiv276 divide 9.99e384 1 -> 9.990000000000000E+384 Clamped +dddiv277 divide 9.999999999999999e384 1 -> 9.999999999999999E+384 + +-- Divide into 0 tests +dddiv301 divide 0 7 -> 0 +dddiv302 divide 0 7E-5 -> 0E+5 +dddiv303 divide 0 7E-1 -> 0E+1 +dddiv304 divide 0 7E+1 -> 0.0 +dddiv305 divide 0 7E+5 -> 0.00000 +dddiv306 divide 0 7E+6 -> 0.000000 +dddiv307 divide 0 7E+7 -> 0E-7 +dddiv308 divide 0 70E-5 -> 0E+5 +dddiv309 divide 0 70E-1 -> 0E+1 +dddiv310 divide 0 70E+0 -> 0 +dddiv311 divide 0 70E+1 -> 0.0 +dddiv312 divide 0 70E+5 -> 0.00000 +dddiv313 divide 0 70E+6 -> 0.000000 +dddiv314 divide 0 70E+7 -> 0E-7 +dddiv315 divide 0 700E-5 -> 0E+5 +dddiv316 divide 0 700E-1 -> 0E+1 +dddiv317 divide 0 700E+0 -> 0 +dddiv318 divide 0 700E+1 -> 0.0 +dddiv319 divide 0 700E+5 -> 0.00000 +dddiv320 divide 0 700E+6 -> 0.000000 +dddiv321 divide 0 700E+7 -> 0E-7 +dddiv322 divide 0 700E+77 -> 0E-77 + +dddiv331 divide 0E-3 7E-5 -> 0E+2 +dddiv332 divide 0E-3 7E-1 -> 0.00 +dddiv333 divide 0E-3 7E+1 -> 0.0000 +dddiv334 divide 0E-3 7E+5 -> 0E-8 +dddiv335 divide 0E-1 7E-5 -> 0E+4 +dddiv336 divide 0E-1 7E-1 -> 0 +dddiv337 divide 0E-1 7E+1 -> 0.00 +dddiv338 divide 0E-1 7E+5 -> 0.000000 +dddiv339 divide 0E+1 7E-5 -> 0E+6 +dddiv340 divide 0E+1 7E-1 -> 0E+2 +dddiv341 divide 0E+1 7E+1 -> 0 +dddiv342 divide 0E+1 7E+5 -> 0.0000 +dddiv343 divide 0E+3 7E-5 -> 0E+8 +dddiv344 divide 0E+3 7E-1 -> 0E+4 +dddiv345 divide 0E+3 7E+1 -> 0E+2 +dddiv346 divide 0E+3 7E+5 -> 0.00 + +-- These were 'input rounding' +dddiv441 divide 12345678000 1 -> 12345678000 +dddiv442 divide 1 12345678000 -> 8.100000664200054E-11 Inexact Rounded +dddiv443 divide 1234567800 1 -> 1234567800 +dddiv444 divide 1 1234567800 -> 8.100000664200054E-10 Inexact Rounded +dddiv445 divide 1234567890 1 -> 1234567890 +dddiv446 divide 1 1234567890 -> 8.100000073710001E-10 Inexact Rounded +dddiv447 divide 1234567891 1 -> 1234567891 +dddiv448 divide 1 1234567891 -> 8.100000067149001E-10 Inexact Rounded +dddiv449 divide 12345678901 1 -> 12345678901 +dddiv450 divide 1 12345678901 -> 8.100000073053901E-11 Inexact Rounded +dddiv451 divide 1234567896 1 -> 1234567896 +dddiv452 divide 1 1234567896 -> 8.100000034344000E-10 Inexact Rounded + +-- high-lows +dddiv453 divide 1e+1 1 -> 1E+1 +dddiv454 divide 1e+1 1.0 -> 1E+1 +dddiv455 divide 1e+1 1.00 -> 1E+1 +dddiv456 divide 1e+2 2 -> 5E+1 +dddiv457 divide 1e+2 2.0 -> 5E+1 +dddiv458 divide 1e+2 2.00 -> 5E+1 + +-- some from IEEE discussions +dddiv460 divide 3e0 2e0 -> 1.5 +dddiv461 divide 30e-1 2e0 -> 1.5 +dddiv462 divide 300e-2 2e0 -> 1.50 +dddiv464 divide 3000e-3 2e0 -> 1.500 +dddiv465 divide 3e0 20e-1 -> 1.5 +dddiv466 divide 30e-1 20e-1 -> 1.5 +dddiv467 divide 300e-2 20e-1 -> 1.5 +dddiv468 divide 3000e-3 20e-1 -> 1.50 +dddiv469 divide 3e0 200e-2 -> 1.5 +dddiv470 divide 30e-1 200e-2 -> 1.5 +dddiv471 divide 300e-2 200e-2 -> 1.5 +dddiv472 divide 3000e-3 200e-2 -> 1.5 +dddiv473 divide 3e0 2000e-3 -> 1.5 +dddiv474 divide 30e-1 2000e-3 -> 1.5 +dddiv475 divide 300e-2 2000e-3 -> 1.5 +dddiv476 divide 3000e-3 2000e-3 -> 1.5 + +-- some reciprocals +dddiv480 divide 1 1.0E+33 -> 1E-33 +dddiv481 divide 1 10E+33 -> 1E-34 +dddiv482 divide 1 1.0E-33 -> 1E+33 +dddiv483 divide 1 10E-33 -> 1E+32 + +-- RMS discussion table +dddiv484 divide 0e5 1e3 -> 0E+2 +dddiv485 divide 0e5 2e3 -> 0E+2 +dddiv486 divide 0e5 10e2 -> 0E+3 +dddiv487 divide 0e5 20e2 -> 0E+3 +dddiv488 divide 0e5 100e1 -> 0E+4 +dddiv489 divide 0e5 200e1 -> 0E+4 + +dddiv491 divide 1e5 1e3 -> 1E+2 +dddiv492 divide 1e5 2e3 -> 5E+1 +dddiv493 divide 1e5 10e2 -> 1E+2 +dddiv494 divide 1e5 20e2 -> 5E+1 +dddiv495 divide 1e5 100e1 -> 1E+2 +dddiv496 divide 1e5 200e1 -> 5E+1 + +-- tryzeros cases +rounding: half_up +dddiv497 divide 0E+380 1000E-13 -> 0E+369 Clamped +dddiv498 divide 0E-390 1000E+13 -> 0E-398 Clamped + +rounding: half_up + +-- focus on trailing zeros issues +dddiv500 divide 1 9.9 -> 0.1010101010101010 Inexact Rounded +dddiv501 divide 1 9.09 -> 0.1100110011001100 Inexact Rounded +dddiv502 divide 1 9.009 -> 0.1110001110001110 Inexact Rounded + +dddiv511 divide 1 2 -> 0.5 +dddiv512 divide 1.0 2 -> 0.5 +dddiv513 divide 1.00 2 -> 0.50 +dddiv514 divide 1.000 2 -> 0.500 +dddiv515 divide 1.0000 2 -> 0.5000 +dddiv516 divide 1.00000 2 -> 0.50000 +dddiv517 divide 1.000000 2 -> 0.500000 +dddiv518 divide 1.0000000 2 -> 0.5000000 +dddiv519 divide 1.00 2.00 -> 0.5 + +dddiv521 divide 2 1 -> 2 +dddiv522 divide 2 1.0 -> 2 +dddiv523 divide 2 1.00 -> 2 +dddiv524 divide 2 1.000 -> 2 +dddiv525 divide 2 1.0000 -> 2 +dddiv526 divide 2 1.00000 -> 2 +dddiv527 divide 2 1.000000 -> 2 +dddiv528 divide 2 1.0000000 -> 2 +dddiv529 divide 2.00 1.00 -> 2 + +dddiv530 divide 2.40 2 -> 1.20 +dddiv531 divide 2.40 4 -> 0.60 +dddiv532 divide 2.40 10 -> 0.24 +dddiv533 divide 2.40 2.0 -> 1.2 +dddiv534 divide 2.40 4.0 -> 0.6 +dddiv535 divide 2.40 10.0 -> 0.24 +dddiv536 divide 2.40 2.00 -> 1.2 +dddiv537 divide 2.40 4.00 -> 0.6 +dddiv538 divide 2.40 10.00 -> 0.24 +dddiv539 divide 0.9 0.1 -> 9 +dddiv540 divide 0.9 0.01 -> 9E+1 +dddiv541 divide 0.9 0.001 -> 9E+2 +dddiv542 divide 5 2 -> 2.5 +dddiv543 divide 5 2.0 -> 2.5 +dddiv544 divide 5 2.00 -> 2.5 +dddiv545 divide 5 20 -> 0.25 +dddiv546 divide 5 20.0 -> 0.25 +dddiv547 divide 2.400 2 -> 1.200 +dddiv548 divide 2.400 2.0 -> 1.20 +dddiv549 divide 2.400 2.400 -> 1 + +dddiv550 divide 240 1 -> 240 +dddiv551 divide 240 10 -> 24 +dddiv552 divide 240 100 -> 2.4 +dddiv553 divide 240 1000 -> 0.24 +dddiv554 divide 2400 1 -> 2400 +dddiv555 divide 2400 10 -> 240 +dddiv556 divide 2400 100 -> 24 +dddiv557 divide 2400 1000 -> 2.4 + +-- +ve exponent +dddiv600 divide 2.4E+9 2 -> 1.2E+9 +dddiv601 divide 2.40E+9 2 -> 1.20E+9 +dddiv602 divide 2.400E+9 2 -> 1.200E+9 +dddiv603 divide 2.4000E+9 2 -> 1.2000E+9 +dddiv604 divide 24E+8 2 -> 1.2E+9 +dddiv605 divide 240E+7 2 -> 1.20E+9 +dddiv606 divide 2400E+6 2 -> 1.200E+9 +dddiv607 divide 24000E+5 2 -> 1.2000E+9 + +-- more zeros, etc. +dddiv731 divide 5.00 1E-3 -> 5.00E+3 +dddiv732 divide 00.00 0.000 -> NaN Division_undefined +dddiv733 divide 00.00 0E-3 -> NaN Division_undefined +dddiv734 divide 0 -0 -> NaN Division_undefined +dddiv735 divide -0 0 -> NaN Division_undefined +dddiv736 divide -0 -0 -> NaN Division_undefined + +dddiv741 divide 0 -1 -> -0 +dddiv742 divide -0 -1 -> 0 +dddiv743 divide 0 1 -> 0 +dddiv744 divide -0 1 -> -0 +dddiv745 divide -1 0 -> -Infinity Division_by_zero +dddiv746 divide -1 -0 -> Infinity Division_by_zero +dddiv747 divide 1 0 -> Infinity Division_by_zero +dddiv748 divide 1 -0 -> -Infinity Division_by_zero + +dddiv751 divide 0.0 -1 -> -0.0 +dddiv752 divide -0.0 -1 -> 0.0 +dddiv753 divide 0.0 1 -> 0.0 +dddiv754 divide -0.0 1 -> -0.0 +dddiv755 divide -1.0 0 -> -Infinity Division_by_zero +dddiv756 divide -1.0 -0 -> Infinity Division_by_zero +dddiv757 divide 1.0 0 -> Infinity Division_by_zero +dddiv758 divide 1.0 -0 -> -Infinity Division_by_zero + +dddiv761 divide 0 -1.0 -> -0E+1 +dddiv762 divide -0 -1.0 -> 0E+1 +dddiv763 divide 0 1.0 -> 0E+1 +dddiv764 divide -0 1.0 -> -0E+1 +dddiv765 divide -1 0.0 -> -Infinity Division_by_zero +dddiv766 divide -1 -0.0 -> Infinity Division_by_zero +dddiv767 divide 1 0.0 -> Infinity Division_by_zero +dddiv768 divide 1 -0.0 -> -Infinity Division_by_zero + +dddiv771 divide 0.0 -1.0 -> -0 +dddiv772 divide -0.0 -1.0 -> 0 +dddiv773 divide 0.0 1.0 -> 0 +dddiv774 divide -0.0 1.0 -> -0 +dddiv775 divide -1.0 0.0 -> -Infinity Division_by_zero +dddiv776 divide -1.0 -0.0 -> Infinity Division_by_zero +dddiv777 divide 1.0 0.0 -> Infinity Division_by_zero +dddiv778 divide 1.0 -0.0 -> -Infinity Division_by_zero + +-- Specials +dddiv780 divide Inf -Inf -> NaN Invalid_operation +dddiv781 divide Inf -1000 -> -Infinity +dddiv782 divide Inf -1 -> -Infinity +dddiv783 divide Inf -0 -> -Infinity +dddiv784 divide Inf 0 -> Infinity +dddiv785 divide Inf 1 -> Infinity +dddiv786 divide Inf 1000 -> Infinity +dddiv787 divide Inf Inf -> NaN Invalid_operation +dddiv788 divide -1000 Inf -> -0E-398 Clamped +dddiv789 divide -Inf Inf -> NaN Invalid_operation +dddiv790 divide -1 Inf -> -0E-398 Clamped +dddiv791 divide -0 Inf -> -0E-398 Clamped +dddiv792 divide 0 Inf -> 0E-398 Clamped +dddiv793 divide 1 Inf -> 0E-398 Clamped +dddiv794 divide 1000 Inf -> 0E-398 Clamped +dddiv795 divide Inf Inf -> NaN Invalid_operation + +dddiv800 divide -Inf -Inf -> NaN Invalid_operation +dddiv801 divide -Inf -1000 -> Infinity +dddiv802 divide -Inf -1 -> Infinity +dddiv803 divide -Inf -0 -> Infinity +dddiv804 divide -Inf 0 -> -Infinity +dddiv805 divide -Inf 1 -> -Infinity +dddiv806 divide -Inf 1000 -> -Infinity +dddiv807 divide -Inf Inf -> NaN Invalid_operation +dddiv808 divide -1000 Inf -> -0E-398 Clamped +dddiv809 divide -Inf -Inf -> NaN Invalid_operation +dddiv810 divide -1 -Inf -> 0E-398 Clamped +dddiv811 divide -0 -Inf -> 0E-398 Clamped +dddiv812 divide 0 -Inf -> -0E-398 Clamped +dddiv813 divide 1 -Inf -> -0E-398 Clamped +dddiv814 divide 1000 -Inf -> -0E-398 Clamped +dddiv815 divide Inf -Inf -> NaN Invalid_operation + +dddiv821 divide NaN -Inf -> NaN +dddiv822 divide NaN -1000 -> NaN +dddiv823 divide NaN -1 -> NaN +dddiv824 divide NaN -0 -> NaN +dddiv825 divide NaN 0 -> NaN +dddiv826 divide NaN 1 -> NaN +dddiv827 divide NaN 1000 -> NaN +dddiv828 divide NaN Inf -> NaN +dddiv829 divide NaN NaN -> NaN +dddiv830 divide -Inf NaN -> NaN +dddiv831 divide -1000 NaN -> NaN +dddiv832 divide -1 NaN -> NaN +dddiv833 divide -0 NaN -> NaN +dddiv834 divide 0 NaN -> NaN +dddiv835 divide 1 NaN -> NaN +dddiv836 divide 1000 NaN -> NaN +dddiv837 divide Inf NaN -> NaN + +dddiv841 divide sNaN -Inf -> NaN Invalid_operation +dddiv842 divide sNaN -1000 -> NaN Invalid_operation +dddiv843 divide sNaN -1 -> NaN Invalid_operation +dddiv844 divide sNaN -0 -> NaN Invalid_operation +dddiv845 divide sNaN 0 -> NaN Invalid_operation +dddiv846 divide sNaN 1 -> NaN Invalid_operation +dddiv847 divide sNaN 1000 -> NaN Invalid_operation +dddiv848 divide sNaN NaN -> NaN Invalid_operation +dddiv849 divide sNaN sNaN -> NaN Invalid_operation +dddiv850 divide NaN sNaN -> NaN Invalid_operation +dddiv851 divide -Inf sNaN -> NaN Invalid_operation +dddiv852 divide -1000 sNaN -> NaN Invalid_operation +dddiv853 divide -1 sNaN -> NaN Invalid_operation +dddiv854 divide -0 sNaN -> NaN Invalid_operation +dddiv855 divide 0 sNaN -> NaN Invalid_operation +dddiv856 divide 1 sNaN -> NaN Invalid_operation +dddiv857 divide 1000 sNaN -> NaN Invalid_operation +dddiv858 divide Inf sNaN -> NaN Invalid_operation +dddiv859 divide NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +dddiv861 divide NaN9 -Inf -> NaN9 +dddiv862 divide NaN8 1000 -> NaN8 +dddiv863 divide NaN7 Inf -> NaN7 +dddiv864 divide NaN6 NaN5 -> NaN6 +dddiv865 divide -Inf NaN4 -> NaN4 +dddiv866 divide -1000 NaN3 -> NaN3 +dddiv867 divide Inf NaN2 -> NaN2 + +dddiv871 divide sNaN99 -Inf -> NaN99 Invalid_operation +dddiv872 divide sNaN98 -1 -> NaN98 Invalid_operation +dddiv873 divide sNaN97 NaN -> NaN97 Invalid_operation +dddiv874 divide sNaN96 sNaN94 -> NaN96 Invalid_operation +dddiv875 divide NaN95 sNaN93 -> NaN93 Invalid_operation +dddiv876 divide -Inf sNaN92 -> NaN92 Invalid_operation +dddiv877 divide 0 sNaN91 -> NaN91 Invalid_operation +dddiv878 divide Inf sNaN90 -> NaN90 Invalid_operation +dddiv879 divide NaN sNaN89 -> NaN89 Invalid_operation + +dddiv881 divide -NaN9 -Inf -> -NaN9 +dddiv882 divide -NaN8 1000 -> -NaN8 +dddiv883 divide -NaN7 Inf -> -NaN7 +dddiv884 divide -NaN6 -NaN5 -> -NaN6 +dddiv885 divide -Inf -NaN4 -> -NaN4 +dddiv886 divide -1000 -NaN3 -> -NaN3 +dddiv887 divide Inf -NaN2 -> -NaN2 + +dddiv891 divide -sNaN99 -Inf -> -NaN99 Invalid_operation +dddiv892 divide -sNaN98 -1 -> -NaN98 Invalid_operation +dddiv893 divide -sNaN97 NaN -> -NaN97 Invalid_operation +dddiv894 divide -sNaN96 -sNaN94 -> -NaN96 Invalid_operation +dddiv895 divide -NaN95 -sNaN93 -> -NaN93 Invalid_operation +dddiv896 divide -Inf -sNaN92 -> -NaN92 Invalid_operation +dddiv897 divide 0 -sNaN91 -> -NaN91 Invalid_operation +dddiv898 divide Inf -sNaN90 -> -NaN90 Invalid_operation +dddiv899 divide -NaN -sNaN89 -> -NaN89 Invalid_operation + +-- Various flavours of divide by 0 +dddiv901 divide 0 0 -> NaN Division_undefined +dddiv902 divide 0.0E5 0 -> NaN Division_undefined +dddiv903 divide 0.000 0 -> NaN Division_undefined +dddiv904 divide 0.0001 0 -> Infinity Division_by_zero +dddiv905 divide 0.01 0 -> Infinity Division_by_zero +dddiv906 divide 0.1 0 -> Infinity Division_by_zero +dddiv907 divide 1 0 -> Infinity Division_by_zero +dddiv908 divide 1 0.0 -> Infinity Division_by_zero +dddiv909 divide 10 0.0 -> Infinity Division_by_zero +dddiv910 divide 1E+100 0.0 -> Infinity Division_by_zero +dddiv911 divide 1E+100 0 -> Infinity Division_by_zero + +dddiv921 divide -0.0001 0 -> -Infinity Division_by_zero +dddiv922 divide -0.01 0 -> -Infinity Division_by_zero +dddiv923 divide -0.1 0 -> -Infinity Division_by_zero +dddiv924 divide -1 0 -> -Infinity Division_by_zero +dddiv925 divide -1 0.0 -> -Infinity Division_by_zero +dddiv926 divide -10 0.0 -> -Infinity Division_by_zero +dddiv927 divide -1E+100 0.0 -> -Infinity Division_by_zero +dddiv928 divide -1E+100 0 -> -Infinity Division_by_zero + +dddiv931 divide 0.0001 -0 -> -Infinity Division_by_zero +dddiv932 divide 0.01 -0 -> -Infinity Division_by_zero +dddiv933 divide 0.1 -0 -> -Infinity Division_by_zero +dddiv934 divide 1 -0 -> -Infinity Division_by_zero +dddiv935 divide 1 -0.0 -> -Infinity Division_by_zero +dddiv936 divide 10 -0.0 -> -Infinity Division_by_zero +dddiv937 divide 1E+100 -0.0 -> -Infinity Division_by_zero +dddiv938 divide 1E+100 -0 -> -Infinity Division_by_zero + +dddiv941 divide -0.0001 -0 -> Infinity Division_by_zero +dddiv942 divide -0.01 -0 -> Infinity Division_by_zero +dddiv943 divide -0.1 -0 -> Infinity Division_by_zero +dddiv944 divide -1 -0 -> Infinity Division_by_zero +dddiv945 divide -1 -0.0 -> Infinity Division_by_zero +dddiv946 divide -10 -0.0 -> Infinity Division_by_zero +dddiv947 divide -1E+100 -0.0 -> Infinity Division_by_zero +dddiv948 divide -1E+100 -0 -> Infinity Division_by_zero + +-- Examples from SQL proposal (Krishna Kulkarni) +dddiv1021 divide 1E0 1E0 -> 1 +dddiv1022 divide 1E0 2E0 -> 0.5 +dddiv1023 divide 1E0 3E0 -> 0.3333333333333333 Inexact Rounded +dddiv1024 divide 100E-2 1000E-3 -> 1 +dddiv1025 divide 24E-1 2E0 -> 1.2 +dddiv1026 divide 2400E-3 2E0 -> 1.200 +dddiv1027 divide 5E0 2E0 -> 2.5 +dddiv1028 divide 5E0 20E-1 -> 2.5 +dddiv1029 divide 5E0 2000E-3 -> 2.5 +dddiv1030 divide 5E0 2E-1 -> 25 +dddiv1031 divide 5E0 20E-2 -> 25 +dddiv1032 divide 480E-2 3E0 -> 1.60 +dddiv1033 divide 47E-1 2E0 -> 2.35 + +-- ECMAScript bad examples +rounding: half_down +dddiv1040 divide 5 9 -> 0.5555555555555556 Inexact Rounded +rounding: half_even +dddiv1041 divide 6 11 -> 0.5454545454545455 Inexact Rounded + +-- overflow and underflow tests .. note subnormal results +-- signs +dddiv1051 divide 1e+277 1e-311 -> Infinity Overflow Inexact Rounded +dddiv1052 divide 1e+277 -1e-311 -> -Infinity Overflow Inexact Rounded +dddiv1053 divide -1e+277 1e-311 -> -Infinity Overflow Inexact Rounded +dddiv1054 divide -1e+277 -1e-311 -> Infinity Overflow Inexact Rounded +dddiv1055 divide 1e-277 1e+311 -> 0E-398 Underflow Subnormal Inexact Rounded Clamped +dddiv1056 divide 1e-277 -1e+311 -> -0E-398 Underflow Subnormal Inexact Rounded Clamped +dddiv1057 divide -1e-277 1e+311 -> -0E-398 Underflow Subnormal Inexact Rounded Clamped +dddiv1058 divide -1e-277 -1e+311 -> 0E-398 Underflow Subnormal Inexact Rounded Clamped + +-- 'subnormal' boundary (all hard underflow or overflow in base arithemtic) +dddiv1060 divide 1e-291 1e+101 -> 1E-392 Subnormal +dddiv1061 divide 1e-291 1e+102 -> 1E-393 Subnormal +dddiv1062 divide 1e-291 1e+103 -> 1E-394 Subnormal +dddiv1063 divide 1e-291 1e+104 -> 1E-395 Subnormal +dddiv1064 divide 1e-291 1e+105 -> 1E-396 Subnormal +dddiv1065 divide 1e-291 1e+106 -> 1E-397 Subnormal +dddiv1066 divide 1e-291 1e+107 -> 1E-398 Subnormal +dddiv1067 divide 1e-291 1e+108 -> 0E-398 Underflow Subnormal Inexact Rounded Clamped +dddiv1068 divide 1e-291 1e+109 -> 0E-398 Underflow Subnormal Inexact Rounded Clamped +dddiv1069 divide 1e-291 1e+110 -> 0E-398 Underflow Subnormal Inexact Rounded Clamped +-- [no equivalent of 'subnormal' for overflow] +dddiv1070 divide 1e+60 1e-321 -> 1.000000000000E+381 Clamped +dddiv1071 divide 1e+60 1e-322 -> 1.0000000000000E+382 Clamped +dddiv1072 divide 1e+60 1e-323 -> 1.00000000000000E+383 Clamped +dddiv1073 divide 1e+60 1e-324 -> 1.000000000000000E+384 Clamped +dddiv1074 divide 1e+60 1e-325 -> Infinity Overflow Inexact Rounded +dddiv1075 divide 1e+60 1e-326 -> Infinity Overflow Inexact Rounded +dddiv1076 divide 1e+60 1e-327 -> Infinity Overflow Inexact Rounded +dddiv1077 divide 1e+60 1e-328 -> Infinity Overflow Inexact Rounded +dddiv1078 divide 1e+60 1e-329 -> Infinity Overflow Inexact Rounded +dddiv1079 divide 1e+60 1e-330 -> Infinity Overflow Inexact Rounded + +dddiv1101 divide 1.0000E-394 1 -> 1.0000E-394 Subnormal +dddiv1102 divide 1.000E-394 1e+1 -> 1.000E-395 Subnormal +dddiv1103 divide 1.00E-394 1e+2 -> 1.00E-396 Subnormal +dddiv1104 divide 1.0E-394 1e+3 -> 1.0E-397 Subnormal +dddiv1105 divide 1.0E-394 1e+4 -> 1E-398 Subnormal Rounded +dddiv1106 divide 1.3E-394 1e+4 -> 1E-398 Underflow Subnormal Inexact Rounded +dddiv1107 divide 1.5E-394 1e+4 -> 2E-398 Underflow Subnormal Inexact Rounded +dddiv1108 divide 1.7E-394 1e+4 -> 2E-398 Underflow Subnormal Inexact Rounded +dddiv1109 divide 2.3E-394 1e+4 -> 2E-398 Underflow Subnormal Inexact Rounded +dddiv1110 divide 2.5E-394 1e+4 -> 2E-398 Underflow Subnormal Inexact Rounded +dddiv1111 divide 2.7E-394 1e+4 -> 3E-398 Underflow Subnormal Inexact Rounded +dddiv1112 divide 1.49E-394 1e+4 -> 1E-398 Underflow Subnormal Inexact Rounded +dddiv1113 divide 1.50E-394 1e+4 -> 2E-398 Underflow Subnormal Inexact Rounded +dddiv1114 divide 1.51E-394 1e+4 -> 2E-398 Underflow Subnormal Inexact Rounded +dddiv1115 divide 2.49E-394 1e+4 -> 2E-398 Underflow Subnormal Inexact Rounded +dddiv1116 divide 2.50E-394 1e+4 -> 2E-398 Underflow Subnormal Inexact Rounded +dddiv1117 divide 2.51E-394 1e+4 -> 3E-398 Underflow Subnormal Inexact Rounded + +dddiv1118 divide 1E-394 1e+4 -> 1E-398 Subnormal +dddiv1119 divide 3E-394 1e+5 -> 0E-398 Underflow Subnormal Inexact Rounded Clamped +dddiv1120 divide 5E-394 1e+5 -> 0E-398 Underflow Subnormal Inexact Rounded Clamped +dddiv1121 divide 7E-394 1e+5 -> 1E-398 Underflow Subnormal Inexact Rounded +dddiv1122 divide 9E-394 1e+5 -> 1E-398 Underflow Subnormal Inexact Rounded +dddiv1123 divide 9.9E-394 1e+5 -> 1E-398 Underflow Subnormal Inexact Rounded + +dddiv1124 divide 1E-394 -1e+4 -> -1E-398 Subnormal +dddiv1125 divide 3E-394 -1e+5 -> -0E-398 Underflow Subnormal Inexact Rounded Clamped +dddiv1126 divide -5E-394 1e+5 -> -0E-398 Underflow Subnormal Inexact Rounded Clamped +dddiv1127 divide 7E-394 -1e+5 -> -1E-398 Underflow Subnormal Inexact Rounded +dddiv1128 divide -9E-394 1e+5 -> -1E-398 Underflow Subnormal Inexact Rounded +dddiv1129 divide 9.9E-394 -1e+5 -> -1E-398 Underflow Subnormal Inexact Rounded +dddiv1130 divide 3.0E-394 -1e+5 -> -0E-398 Underflow Subnormal Inexact Rounded Clamped + +dddiv1131 divide 1.0E-199 1e+200 -> 0E-398 Underflow Subnormal Inexact Rounded Clamped +dddiv1132 divide 1.0E-199 1e+199 -> 1E-398 Subnormal Rounded +dddiv1133 divide 1.0E-199 1e+198 -> 1.0E-397 Subnormal +dddiv1134 divide 2.0E-199 2e+198 -> 1.0E-397 Subnormal +dddiv1135 divide 4.0E-199 4e+198 -> 1.0E-397 Subnormal +dddiv1136 divide 10.0E-199 10e+198 -> 1.0E-397 Subnormal +dddiv1137 divide 30.0E-199 30e+198 -> 1.0E-397 Subnormal + +-- randoms +dddiv2010 divide -3.303226714900711E-35 8.796578842713183E+73 -> -3.755126594058783E-109 Inexact Rounded +dddiv2011 divide 933153327821073.6 68782181090246.25 -> 13.56678885475763 Inexact Rounded +dddiv2012 divide 5.04752436057906E-72 -8.179481771238642E+64 -> -6.170958627632835E-137 Inexact Rounded +dddiv2013 divide -3707613309582318 3394911196503.048 -> -1092.109070010836 Inexact Rounded +dddiv2014 divide 99689.0555190461 -4.735208553891464 -> -21052.72753765411 Inexact Rounded +dddiv2015 divide -1447915775613329 269750797.8184875 -> -5367605.164925653 Inexact Rounded +dddiv2016 divide -9.394881304225258E-19 -830585.0252671636 -> 1.131116143251358E-24 Inexact Rounded +dddiv2017 divide -1.056283432738934 88.58754555124013 -> -0.01192361100159352 Inexact Rounded +dddiv2018 divide 5763220933343.081 689089567025052.1 -> 0.008363529516524456 Inexact Rounded +dddiv2019 divide 873819.122103216 9.740612494523300E-49 -> 8.970884763093948E+53 Inexact Rounded +dddiv2020 divide 8022914.838533576 6178.566801742713 -> 1298.507420243583 Inexact Rounded +dddiv2021 divide 203982.7605650363 -2158.283639053435 -> -94.51156320422168 Inexact Rounded +dddiv2022 divide 803.6310547013030 7101143795399.238 -> 1.131692411611166E-10 Inexact Rounded +dddiv2023 divide 9.251697842123399E-82 -1.342350220606119E-7 -> -6.892163982321936E-75 Inexact Rounded +dddiv2024 divide -1.980600645637992E-53 -5.474262753214457E+77 -> 3.618022617703168E-131 Inexact Rounded +dddiv2025 divide -210.0322996351690 -8.580951835872843E+80 -> 2.447657365434971E-79 Inexact Rounded +dddiv2026 divide -1.821980314020370E+85 -3.018915267138165 -> 6.035215144503042E+84 Inexact Rounded +dddiv2027 divide -772264503601.1047 5.158258271408988E-86 -> -1.497141986630614E+97 Inexact Rounded +dddiv2028 divide -767.0532415847106 2.700027228028939E-59 -> -2.840909282772941E+61 Inexact Rounded +dddiv2029 divide 496724.8548250093 7.32700588163100E+66 -> 6.779370220929013E-62 Inexact Rounded +dddiv2030 divide -304232651447703.9 -108.9730808657440 -> 2791814721862.565 Inexact Rounded +dddiv2031 divide -7.233817192699405E+42 -5711302004.149411 -> 1.266579352211430E+33 Inexact Rounded +dddiv2032 divide -9.999221444912745E+96 4010569406446197 -> -2.493217404202250E+81 Inexact Rounded +dddiv2033 divide -1837272.061937622 8.356322838066762 -> -219866.0939196882 Inexact Rounded +dddiv2034 divide 2168.517555606529 209.1910258615061 -> 10.36620737756784 Inexact Rounded +dddiv2035 divide -1.884389790576371E+88 2.95181953870583E+20 -> -6.383824505079828E+67 Inexact Rounded +dddiv2036 divide 732263.6037438196 961222.3634446889 -> 0.7618045850698269 Inexact Rounded +dddiv2037 divide -813461419.0348336 5.376293753809143E+84 -> -1.513052404285927E-76 Inexact Rounded +dddiv2038 divide -45562133508108.50 -9.776843494690107E+51 -> 4.660208945029519E-39 Inexact Rounded +dddiv2039 divide -6.489393172441016E+80 -9101965.097852113 -> 7.129661674897421E+73 Inexact Rounded +dddiv2040 divide 3.694576237117349E+93 6683512.012622003 -> 5.527896456443912E+86 Inexact Rounded +dddiv2041 divide -2.252877726403272E+19 -7451913256.181367 -> 3023220546.125531 Inexact Rounded +dddiv2042 divide 518303.1989111842 50.01587020474133 -> 10362.77479107123 Inexact Rounded +dddiv2043 divide 2.902087881880103E+24 33.32400992305702 -> 8.708699488989578E+22 Inexact Rounded +dddiv2044 divide 549619.4559510557 1660824845196338 -> 3.309316196351104E-10 Inexact Rounded +dddiv2045 divide -6775670774684043 8292152023.077262 -> -817118.4941891062 Inexact Rounded +dddiv2046 divide -77.50923921524079 -5.636882655425815E+74 -> 1.375037302588405E-73 Inexact Rounded +dddiv2047 divide -2.984889459605149E-10 -88106156784122.99 -> 3.387833005721384E-24 Inexact Rounded +dddiv2048 divide 0.949517293997085 44767115.96450998 -> 2.121015110175589E-8 Inexact Rounded +dddiv2049 divide -2760937211.084521 -1087015876975408 -> 0.000002539923537057024 Inexact Rounded +dddiv2050 divide 28438351.85030536 -4.209397904088624E-47 -> -6.755919135770688E+53 Inexact Rounded +dddiv2051 divide -85562731.6820956 -7.166045442530185E+45 -> 1.194002080621542E-38 Inexact Rounded +dddiv2052 divide 2533802852165.25 7154.119606235955 -> 354173957.3317501 Inexact Rounded +dddiv2053 divide -8858831346851.474 97.59734208801716 -> -90769186509.83577 Inexact Rounded +dddiv2054 divide 176783629801387.5 840073263.3109817 -> 210438.3480848206 Inexact Rounded +dddiv2055 divide -493506471796175.6 79733894790822.03 -> -6.189418854940746 Inexact Rounded +dddiv2056 divide 790.1682542103445 829.9449370367435 -> 0.9520731062371214 Inexact Rounded +dddiv2057 divide -8920459838.583164 -4767.889187899214 -> 1870945.294035581 Inexact Rounded +dddiv2058 divide 53536687164422.1 53137.5007032689 -> 1007512330.385698 Inexact Rounded +dddiv2059 divide 4.051532311146561E-74 -2.343089768972261E+94 -> -1.729140882606332E-168 Inexact Rounded +dddiv2060 divide -14847758778636.88 3.062543516383807E-43 -> -4.848178874587497E+55 Inexact Rounded + +-- Division probably has pre-rounding, so need to test rounding +-- explicitly rather than assume included through other tests; +-- tests include simple rounding and also the tricky cases of sticky +-- bits following two zeros +-- +-- 1/99999 gives 0.0000100001000010000100001000010000100001 +-- 1234567890123456 +-- +-- 1/999999 gives 0.000001000001000001000001000001000001000001 +-- 1234567890123456 + +rounding: ceiling +dddiv3001 divide 1 3 -> 0.3333333333333334 Inexact Rounded +dddiv3002 divide 2 3 -> 0.6666666666666667 Inexact Rounded +dddiv3003 divide 1 99999 -> 0.00001000010000100002 Inexact Rounded +dddiv3004 divide 1 999999 -> 0.000001000001000001001 Inexact Rounded + +rounding: floor +dddiv3011 divide 1 3 -> 0.3333333333333333 Inexact Rounded +dddiv3012 divide 2 3 -> 0.6666666666666666 Inexact Rounded +dddiv3013 divide 1 99999 -> 0.00001000010000100001 Inexact Rounded +dddiv3014 divide 1 999999 -> 0.000001000001000001000 Inexact Rounded + +rounding: up +dddiv3021 divide 1 3 -> 0.3333333333333334 Inexact Rounded +dddiv3022 divide 2 3 -> 0.6666666666666667 Inexact Rounded +dddiv3023 divide 1 99999 -> 0.00001000010000100002 Inexact Rounded +dddiv3024 divide 1 999999 -> 0.000001000001000001001 Inexact Rounded + +rounding: down +dddiv3031 divide 1 3 -> 0.3333333333333333 Inexact Rounded +dddiv3032 divide 2 3 -> 0.6666666666666666 Inexact Rounded +dddiv3033 divide 1 99999 -> 0.00001000010000100001 Inexact Rounded +dddiv3034 divide 1 999999 -> 0.000001000001000001000 Inexact Rounded + +rounding: half_up +dddiv3041 divide 1 3 -> 0.3333333333333333 Inexact Rounded +dddiv3042 divide 2 3 -> 0.6666666666666667 Inexact Rounded +dddiv3043 divide 1 99999 -> 0.00001000010000100001 Inexact Rounded +dddiv3044 divide 1 999999 -> 0.000001000001000001000 Inexact Rounded + +rounding: half_down +dddiv3051 divide 1 3 -> 0.3333333333333333 Inexact Rounded +dddiv3052 divide 2 3 -> 0.6666666666666667 Inexact Rounded +dddiv3053 divide 1 99999 -> 0.00001000010000100001 Inexact Rounded +dddiv3054 divide 1 999999 -> 0.000001000001000001000 Inexact Rounded + +rounding: half_even +dddiv3061 divide 1 3 -> 0.3333333333333333 Inexact Rounded +dddiv3062 divide 2 3 -> 0.6666666666666667 Inexact Rounded +dddiv3063 divide 1 99999 -> 0.00001000010000100001 Inexact Rounded +dddiv3064 divide 1 999999 -> 0.000001000001000001000 Inexact Rounded + +rounding: 05up +dddiv3071 divide 1 3 -> 0.3333333333333333 Inexact Rounded +dddiv3072 divide 2 3 -> 0.6666666666666666 Inexact Rounded +dddiv3073 divide 1 99999 -> 0.00001000010000100001 Inexact Rounded +dddiv3074 divide 1 999999 -> 0.000001000001000001001 Inexact Rounded + +-- random divide tests with result near 1 +rounding: half_even +dddiv4001 divide 3195385192916917 3195385192946695 -> 0.9999999999906809 Inexact Rounded +dddiv4002 divide 1393723067526993 1393723067519475 -> 1.000000000005394 Inexact Rounded +dddiv4003 divide 759985543702302 759985543674015 -> 1.000000000037220 Inexact Rounded +dddiv4004 divide 9579158456027302 9579158456036864 -> 0.9999999999990018 Inexact Rounded +dddiv4005 divide 7079398299143569 7079398299156904 -> 0.9999999999981164 Inexact Rounded +dddiv4006 divide 6636169255366598 6636169255336386 -> 1.000000000004553 Inexact Rounded +dddiv4007 divide 6964813971340090 6964813971321554 -> 1.000000000002661 Inexact Rounded +dddiv4008 divide 4182275225480784 4182275225454009 -> 1.000000000006402 Inexact Rounded +dddiv4009 divide 9228325124938029 9228325124918730 -> 1.000000000002091 Inexact Rounded +dddiv4010 divide 3428346338630192 3428346338609843 -> 1.000000000005936 Inexact Rounded +dddiv4011 divide 2143511550722893 2143511550751754 -> 0.9999999999865356 Inexact Rounded +dddiv4012 divide 1672732924396785 1672732924401811 -> 0.9999999999969953 Inexact Rounded +dddiv4013 divide 4190714611948216 4190714611948664 -> 0.9999999999998931 Inexact Rounded +dddiv4014 divide 3942254800848877 3942254800814556 -> 1.000000000008706 Inexact Rounded +dddiv4015 divide 2854459826952334 2854459826960762 -> 0.9999999999970474 Inexact Rounded +dddiv4016 divide 2853258953664731 2853258953684471 -> 0.9999999999930816 Inexact Rounded +dddiv4017 divide 9453512638125978 9453512638146425 -> 0.9999999999978371 Inexact Rounded +dddiv4018 divide 339476633940369 339476633912887 -> 1.000000000080954 Inexact Rounded +dddiv4019 divide 4542181492688467 4542181492697735 -> 0.9999999999979596 Inexact Rounded +dddiv4020 divide 7312600192399197 7312600192395424 -> 1.000000000000516 Inexact Rounded +dddiv4021 divide 1811674985570111 1811674985603935 -> 0.9999999999813300 Inexact Rounded +dddiv4022 divide 1706462639003481 1706462639017740 -> 0.9999999999916441 Inexact Rounded +dddiv4023 divide 6697052654940368 6697052654934110 -> 1.000000000000934 Inexact Rounded +dddiv4024 divide 5015283664277539 5015283664310719 -> 0.9999999999933842 Inexact Rounded +dddiv4025 divide 2359501561537464 2359501561502464 -> 1.000000000014834 Inexact Rounded +dddiv4026 divide 2669850227909157 2669850227901548 -> 1.000000000002850 Inexact Rounded +dddiv4027 divide 9329725546974648 9329725547002445 -> 0.9999999999970206 Inexact Rounded +dddiv4028 divide 3228562867071248 3228562867106206 -> 0.9999999999891723 Inexact Rounded +dddiv4029 divide 4862226644921175 4862226644909380 -> 1.000000000002426 Inexact Rounded +dddiv4030 divide 1022267997054529 1022267997071329 -> 0.9999999999835660 Inexact Rounded +dddiv4031 divide 1048777482023719 1048777482000948 -> 1.000000000021712 Inexact Rounded +dddiv4032 divide 9980113777337098 9980113777330539 -> 1.000000000000657 Inexact Rounded +dddiv4033 divide 7506839167963908 7506839167942901 -> 1.000000000002798 Inexact Rounded +dddiv4034 divide 231119751977860 231119751962453 -> 1.000000000066662 Inexact Rounded +dddiv4035 divide 4034903664762962 4034903664795526 -> 0.9999999999919294 Inexact Rounded +dddiv4036 divide 5700122152274696 5700122152251386 -> 1.000000000004089 Inexact Rounded +dddiv4037 divide 6869599590293110 6869599590293495 -> 0.9999999999999440 Inexact Rounded +dddiv4038 divide 5576281960092797 5576281960105579 -> 0.9999999999977078 Inexact Rounded +dddiv4039 divide 2304844888381318 2304844888353073 -> 1.000000000012255 Inexact Rounded +dddiv4040 divide 3265933651656452 3265933651682779 -> 0.9999999999919389 Inexact Rounded +dddiv4041 divide 5235714985079914 5235714985066131 -> 1.000000000002632 Inexact Rounded +dddiv4042 divide 5578481572827551 5578481572822945 -> 1.000000000000826 Inexact Rounded +dddiv4043 divide 4909616081396134 4909616081373076 -> 1.000000000004696 Inexact Rounded +dddiv4044 divide 636447224349537 636447224338757 -> 1.000000000016938 Inexact Rounded +dddiv4045 divide 1539373428396640 1539373428364727 -> 1.000000000020731 Inexact Rounded +dddiv4046 divide 2028786707377893 2028786707378866 -> 0.9999999999995204 Inexact Rounded +dddiv4047 divide 137643260486222 137643260487419 -> 0.9999999999913036 Inexact Rounded +dddiv4048 divide 247451519746765 247451519752267 -> 0.9999999999777653 Inexact Rounded +dddiv4049 divide 7877858475022054 7877858474999794 -> 1.000000000002826 Inexact Rounded +dddiv4050 divide 7333242694766258 7333242694744628 -> 1.000000000002950 Inexact Rounded +dddiv4051 divide 124051503698592 124051503699397 -> 0.9999999999935108 Inexact Rounded +dddiv4052 divide 8944737432385188 8944737432406860 -> 0.9999999999975771 Inexact Rounded +dddiv4053 divide 9883948923406874 9883948923424843 -> 0.9999999999981820 Inexact Rounded +dddiv4054 divide 6829178741654284 6829178741671973 -> 0.9999999999974098 Inexact Rounded +dddiv4055 divide 7342752479768122 7342752479793385 -> 0.9999999999965595 Inexact Rounded +dddiv4056 divide 8066426579008783 8066426578977563 -> 1.000000000003870 Inexact Rounded +dddiv4057 divide 8992775071383295 8992775071352712 -> 1.000000000003401 Inexact Rounded +dddiv4058 divide 5485011755545641 5485011755543611 -> 1.000000000000370 Inexact Rounded +dddiv4059 divide 5779983054353918 5779983054365300 -> 0.9999999999980308 Inexact Rounded +dddiv4060 divide 9502265102713774 9502265102735208 -> 0.9999999999977443 Inexact Rounded +dddiv4061 divide 2109558399130981 2109558399116281 -> 1.000000000006968 Inexact Rounded +dddiv4062 divide 5296182636350471 5296182636351521 -> 0.9999999999998017 Inexact Rounded +dddiv4063 divide 1440019225591883 1440019225601844 -> 0.9999999999930827 Inexact Rounded +dddiv4064 divide 8182110791881341 8182110791847174 -> 1.000000000004176 Inexact Rounded +dddiv4065 divide 489098235512060 489098235534516 -> 0.9999999999540869 Inexact Rounded +dddiv4066 divide 6475687084782038 6475687084756089 -> 1.000000000004007 Inexact Rounded +dddiv4067 divide 8094348555736948 8094348555759236 -> 0.9999999999972465 Inexact Rounded +dddiv4068 divide 1982766816291543 1982766816309463 -> 0.9999999999909621 Inexact Rounded +dddiv4069 divide 9277314300113251 9277314300084467 -> 1.000000000003103 Inexact Rounded +dddiv4070 divide 4335532959318934 4335532959293167 -> 1.000000000005943 Inexact Rounded +dddiv4071 divide 7767113032981348 7767113032968132 -> 1.000000000001702 Inexact Rounded +dddiv4072 divide 1578548053342868 1578548053370448 -> 0.9999999999825282 Inexact Rounded +dddiv4073 divide 3790420686666898 3790420686636315 -> 1.000000000008068 Inexact Rounded +dddiv4074 divide 871682421955147 871682421976441 -> 0.9999999999755714 Inexact Rounded +dddiv4075 divide 744141054479940 744141054512329 -> 0.9999999999564746 Inexact Rounded +dddiv4076 divide 8956824183670735 8956824183641741 -> 1.000000000003237 Inexact Rounded +dddiv4077 divide 8337291694485682 8337291694451193 -> 1.000000000004137 Inexact Rounded +dddiv4078 divide 4107775944683669 4107775944657097 -> 1.000000000006469 Inexact Rounded +dddiv4079 divide 8691900057964648 8691900057997555 -> 0.9999999999962141 Inexact Rounded +dddiv4080 divide 2229528520536462 2229528520502337 -> 1.000000000015306 Inexact Rounded +dddiv4081 divide 398442083774322 398442083746273 -> 1.000000000070397 Inexact Rounded +dddiv4082 divide 5319819776808759 5319819776838313 -> 0.9999999999944445 Inexact Rounded +dddiv4083 divide 7710491299066855 7710491299041858 -> 1.000000000003242 Inexact Rounded +dddiv4084 divide 9083231296087266 9083231296058160 -> 1.000000000003204 Inexact Rounded +dddiv4085 divide 3566873574904559 3566873574890328 -> 1.000000000003990 Inexact Rounded +dddiv4086 divide 596343290550525 596343290555614 -> 0.9999999999914663 Inexact Rounded +dddiv4087 divide 278227925093192 278227925068104 -> 1.000000000090171 Inexact Rounded +dddiv4088 divide 3292902958490649 3292902958519881 -> 0.9999999999911227 Inexact Rounded +dddiv4089 divide 5521871364245881 5521871364229536 -> 1.000000000002960 Inexact Rounded +dddiv4090 divide 2406505602883617 2406505602857997 -> 1.000000000010646 Inexact Rounded +dddiv4091 divide 7741146984869208 7741146984867255 -> 1.000000000000252 Inexact Rounded +dddiv4092 divide 4576041832414909 4576041832405102 -> 1.000000000002143 Inexact Rounded +dddiv4093 divide 9183756982878057 9183756982901934 -> 0.9999999999974001 Inexact Rounded +dddiv4094 divide 6215736513855159 6215736513870342 -> 0.9999999999975573 Inexact Rounded +dddiv4095 divide 248554968534533 248554968551417 -> 0.9999999999320714 Inexact Rounded +dddiv4096 divide 376314165668645 376314165659755 -> 1.000000000023624 Inexact Rounded +dddiv4097 divide 5513569249809718 5513569249808906 -> 1.000000000000147 Inexact Rounded +dddiv4098 divide 3367992242167904 3367992242156228 -> 1.000000000003467 Inexact Rounded +dddiv4099 divide 6134869538966967 6134869538985986 -> 0.9999999999968999 Inexact Rounded + +-- Null tests +dddiv9998 divide 10 # -> NaN Invalid_operation +dddiv9999 divide # 10 -> NaN Invalid_operation + Added: python/branches/release25-maint/Lib/test/decimaltestdata/ddDivideInt.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/ddDivideInt.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,449 @@ +------------------------------------------------------------------------ +-- ddDivideInt.decTest -- decDouble integer division -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +precision: 16 +maxExponent: 384 +minExponent: -383 +extended: 1 +clamp: 1 +rounding: half_even + +dddvi001 divideint 1 1 -> 1 +dddvi002 divideint 2 1 -> 2 +dddvi003 divideint 1 2 -> 0 +dddvi004 divideint 2 2 -> 1 +dddvi005 divideint 0 1 -> 0 +dddvi006 divideint 0 2 -> 0 +dddvi007 divideint 1 3 -> 0 +dddvi008 divideint 2 3 -> 0 +dddvi009 divideint 3 3 -> 1 + +dddvi010 divideint 2.4 1 -> 2 +dddvi011 divideint 2.4 -1 -> -2 +dddvi012 divideint -2.4 1 -> -2 +dddvi013 divideint -2.4 -1 -> 2 +dddvi014 divideint 2.40 1 -> 2 +dddvi015 divideint 2.400 1 -> 2 +dddvi016 divideint 2.4 2 -> 1 +dddvi017 divideint 2.400 2 -> 1 +dddvi018 divideint 2. 2 -> 1 +dddvi019 divideint 20 20 -> 1 + +dddvi020 divideint 187 187 -> 1 +dddvi021 divideint 5 2 -> 2 +dddvi022 divideint 5 2.0 -> 2 +dddvi023 divideint 5 2.000 -> 2 +dddvi024 divideint 5 0.200 -> 25 +dddvi025 divideint 5 0.200 -> 25 + +dddvi030 divideint 1 2 -> 0 +dddvi031 divideint 1 4 -> 0 +dddvi032 divideint 1 8 -> 0 +dddvi033 divideint 1 16 -> 0 +dddvi034 divideint 1 32 -> 0 +dddvi035 divideint 1 64 -> 0 +dddvi040 divideint 1 -2 -> -0 +dddvi041 divideint 1 -4 -> -0 +dddvi042 divideint 1 -8 -> -0 +dddvi043 divideint 1 -16 -> -0 +dddvi044 divideint 1 -32 -> -0 +dddvi045 divideint 1 -64 -> -0 +dddvi050 divideint -1 2 -> -0 +dddvi051 divideint -1 4 -> -0 +dddvi052 divideint -1 8 -> -0 +dddvi053 divideint -1 16 -> -0 +dddvi054 divideint -1 32 -> -0 +dddvi055 divideint -1 64 -> -0 +dddvi060 divideint -1 -2 -> 0 +dddvi061 divideint -1 -4 -> 0 +dddvi062 divideint -1 -8 -> 0 +dddvi063 divideint -1 -16 -> 0 +dddvi064 divideint -1 -32 -> 0 +dddvi065 divideint -1 -64 -> 0 + +-- similar with powers of ten +dddvi160 divideint 1 1 -> 1 +dddvi161 divideint 1 10 -> 0 +dddvi162 divideint 1 100 -> 0 +dddvi163 divideint 1 1000 -> 0 +dddvi164 divideint 1 10000 -> 0 +dddvi165 divideint 1 100000 -> 0 +dddvi166 divideint 1 1000000 -> 0 +dddvi167 divideint 1 10000000 -> 0 +dddvi168 divideint 1 100000000 -> 0 +dddvi170 divideint 1 -1 -> -1 +dddvi171 divideint 1 -10 -> -0 +dddvi172 divideint 1 -100 -> -0 +dddvi173 divideint 1 -1000 -> -0 +dddvi174 divideint 1 -10000 -> -0 +dddvi175 divideint 1 -100000 -> -0 +dddvi176 divideint 1 -1000000 -> -0 +dddvi177 divideint 1 -10000000 -> -0 +dddvi178 divideint 1 -100000000 -> -0 +dddvi180 divideint -1 1 -> -1 +dddvi181 divideint -1 10 -> -0 +dddvi182 divideint -1 100 -> -0 +dddvi183 divideint -1 1000 -> -0 +dddvi184 divideint -1 10000 -> -0 +dddvi185 divideint -1 100000 -> -0 +dddvi186 divideint -1 1000000 -> -0 +dddvi187 divideint -1 10000000 -> -0 +dddvi188 divideint -1 100000000 -> -0 +dddvi190 divideint -1 -1 -> 1 +dddvi191 divideint -1 -10 -> 0 +dddvi192 divideint -1 -100 -> 0 +dddvi193 divideint -1 -1000 -> 0 +dddvi194 divideint -1 -10000 -> 0 +dddvi195 divideint -1 -100000 -> 0 +dddvi196 divideint -1 -1000000 -> 0 +dddvi197 divideint -1 -10000000 -> 0 +dddvi198 divideint -1 -100000000 -> 0 + +-- some long operand (at p=9) cases +dddvi070 divideint 999999999 1 -> 999999999 +dddvi071 divideint 999999999.4 1 -> 999999999 +dddvi072 divideint 999999999.5 1 -> 999999999 +dddvi073 divideint 999999999.9 1 -> 999999999 +dddvi074 divideint 999999999.999 1 -> 999999999 + +dddvi090 divideint 0. 1 -> 0 +dddvi091 divideint .0 1 -> 0 +dddvi092 divideint 0.00 1 -> 0 +dddvi093 divideint 0.00E+9 1 -> 0 +dddvi094 divideint 0.0000E-50 1 -> 0 + +dddvi100 divideint 1 1 -> 1 +dddvi101 divideint 1 2 -> 0 +dddvi102 divideint 1 3 -> 0 +dddvi103 divideint 1 4 -> 0 +dddvi104 divideint 1 5 -> 0 +dddvi105 divideint 1 6 -> 0 +dddvi106 divideint 1 7 -> 0 +dddvi107 divideint 1 8 -> 0 +dddvi108 divideint 1 9 -> 0 +dddvi109 divideint 1 10 -> 0 +dddvi110 divideint 1 1 -> 1 +dddvi111 divideint 2 1 -> 2 +dddvi112 divideint 3 1 -> 3 +dddvi113 divideint 4 1 -> 4 +dddvi114 divideint 5 1 -> 5 +dddvi115 divideint 6 1 -> 6 +dddvi116 divideint 7 1 -> 7 +dddvi117 divideint 8 1 -> 8 +dddvi118 divideint 9 1 -> 9 +dddvi119 divideint 10 1 -> 10 + +-- from DiagBigDecimal +dddvi131 divideint 101.3 1 -> 101 +dddvi132 divideint 101.0 1 -> 101 +dddvi133 divideint 101.3 3 -> 33 +dddvi134 divideint 101.0 3 -> 33 +dddvi135 divideint 2.4 1 -> 2 +dddvi136 divideint 2.400 1 -> 2 +dddvi137 divideint 18 18 -> 1 +dddvi138 divideint 1120 1000 -> 1 +dddvi139 divideint 2.4 2 -> 1 +dddvi140 divideint 2.400 2 -> 1 +dddvi141 divideint 0.5 2.000 -> 0 +dddvi142 divideint 8.005 7 -> 1 +dddvi143 divideint 5 2 -> 2 +dddvi144 divideint 0 2 -> 0 +dddvi145 divideint 0.00 2 -> 0 + +-- Others +dddvi150 divideint 12345 4.999 -> 2469 +dddvi151 divideint 12345 4.99 -> 2473 +dddvi152 divideint 12345 4.9 -> 2519 +dddvi153 divideint 12345 5 -> 2469 +dddvi154 divideint 12345 5.1 -> 2420 +dddvi155 divideint 12345 5.01 -> 2464 +dddvi156 divideint 12345 5.001 -> 2468 +dddvi157 divideint 101 7.6 -> 13 + +-- Various flavours of divideint by 0 +dddvi201 divideint 0 0 -> NaN Division_undefined +dddvi202 divideint 0.0E5 0 -> NaN Division_undefined +dddvi203 divideint 0.000 0 -> NaN Division_undefined +dddvi204 divideint 0.0001 0 -> Infinity Division_by_zero +dddvi205 divideint 0.01 0 -> Infinity Division_by_zero +dddvi206 divideint 0.1 0 -> Infinity Division_by_zero +dddvi207 divideint 1 0 -> Infinity Division_by_zero +dddvi208 divideint 1 0.0 -> Infinity Division_by_zero +dddvi209 divideint 10 0.0 -> Infinity Division_by_zero +dddvi210 divideint 1E+100 0.0 -> Infinity Division_by_zero +dddvi211 divideint 1E+380 0 -> Infinity Division_by_zero +dddvi214 divideint -0.0001 0 -> -Infinity Division_by_zero +dddvi215 divideint -0.01 0 -> -Infinity Division_by_zero +dddvi216 divideint -0.1 0 -> -Infinity Division_by_zero +dddvi217 divideint -1 0 -> -Infinity Division_by_zero +dddvi218 divideint -1 0.0 -> -Infinity Division_by_zero +dddvi219 divideint -10 0.0 -> -Infinity Division_by_zero +dddvi220 divideint -1E+100 0.0 -> -Infinity Division_by_zero +dddvi221 divideint -1E+380 0 -> -Infinity Division_by_zero + +-- test some cases that are close to exponent overflow +dddvi270 divideint 1 1e384 -> 0 +dddvi271 divideint 1 0.9e384 -> 0 +dddvi272 divideint 1 0.99e384 -> 0 +dddvi273 divideint 1 0.9999999999999999e384 -> 0 +dddvi274 divideint 9e384 1 -> NaN Division_impossible +dddvi275 divideint 9.9e384 1 -> NaN Division_impossible +dddvi276 divideint 9.99e384 1 -> NaN Division_impossible +dddvi277 divideint 9.999999999999999e384 1 -> NaN Division_impossible + +dddvi280 divideint 0.1 9e-383 -> NaN Division_impossible +dddvi281 divideint 0.1 99e-383 -> NaN Division_impossible +dddvi282 divideint 0.1 999e-383 -> NaN Division_impossible +dddvi283 divideint 0.1 9e-382 -> NaN Division_impossible +dddvi284 divideint 0.1 99e-382 -> NaN Division_impossible + +-- GD edge cases: lhs smaller than rhs but more digits +dddvi301 divideint 0.9 2 -> 0 +dddvi302 divideint 0.9 2.0 -> 0 +dddvi303 divideint 0.9 2.1 -> 0 +dddvi304 divideint 0.9 2.00 -> 0 +dddvi305 divideint 0.9 2.01 -> 0 +dddvi306 divideint 0.12 1 -> 0 +dddvi307 divideint 0.12 1.0 -> 0 +dddvi308 divideint 0.12 1.00 -> 0 +dddvi309 divideint 0.12 1.0 -> 0 +dddvi310 divideint 0.12 1.00 -> 0 +dddvi311 divideint 0.12 2 -> 0 +dddvi312 divideint 0.12 2.0 -> 0 +dddvi313 divideint 0.12 2.1 -> 0 +dddvi314 divideint 0.12 2.00 -> 0 +dddvi315 divideint 0.12 2.01 -> 0 + +-- edge cases of impossible +dddvi330 divideint 1234567890123456 10 -> 123456789012345 +dddvi331 divideint 1234567890123456 1 -> 1234567890123456 +dddvi332 divideint 1234567890123456 0.1 -> NaN Division_impossible +dddvi333 divideint 1234567890123456 0.01 -> NaN Division_impossible + +-- overflow and underflow tests [from divide] +dddvi1051 divideint 1e+277 1e-311 -> NaN Division_impossible +dddvi1052 divideint 1e+277 -1e-311 -> NaN Division_impossible +dddvi1053 divideint -1e+277 1e-311 -> NaN Division_impossible +dddvi1054 divideint -1e+277 -1e-311 -> NaN Division_impossible +dddvi1055 divideint 1e-277 1e+311 -> 0 +dddvi1056 divideint 1e-277 -1e+311 -> -0 +dddvi1057 divideint -1e-277 1e+311 -> -0 +dddvi1058 divideint -1e-277 -1e+311 -> 0 + +-- 'subnormal' boundary (all hard underflow or overflow in base arithemtic) +dddvi1060 divideint 1e-291 1e+101 -> 0 +dddvi1061 divideint 1e-291 1e+102 -> 0 +dddvi1062 divideint 1e-291 1e+103 -> 0 +dddvi1063 divideint 1e-291 1e+104 -> 0 +dddvi1064 divideint 1e-291 1e+105 -> 0 +dddvi1065 divideint 1e-291 1e+106 -> 0 +dddvi1066 divideint 1e-291 1e+107 -> 0 +dddvi1067 divideint 1e-291 1e+108 -> 0 +dddvi1068 divideint 1e-291 1e+109 -> 0 +dddvi1069 divideint 1e-291 1e+110 -> 0 + +dddvi1101 divideint 1.0000E-394 1 -> 0 +dddvi1102 divideint 1.000E-394 1e+1 -> 0 +dddvi1103 divideint 1.00E-394 1e+2 -> 0 + +dddvi1118 divideint 1E-394 1e+4 -> 0 +dddvi1119 divideint 3E-394 -1e+5 -> -0 +dddvi1120 divideint 5E-394 1e+5 -> 0 + +dddvi1124 divideint 1E-394 -1e+4 -> -0 +dddvi1130 divideint 3.0E-394 -1e+5 -> -0 + +dddvi1131 divideint 1.0E-199 1e+200 -> 0 +dddvi1132 divideint 1.0E-199 1e+199 -> 0 +dddvi1133 divideint 1.0E-199 1e+198 -> 0 +dddvi1134 divideint 2.0E-199 2e+198 -> 0 +dddvi1135 divideint 4.0E-199 4e+198 -> 0 + +-- long operand checks +dddvi401 divideint 12345678000 100 -> 123456780 +dddvi402 divideint 1 12345678000 -> 0 +dddvi403 divideint 1234567800 10 -> 123456780 +dddvi404 divideint 1 1234567800 -> 0 +dddvi405 divideint 1234567890 10 -> 123456789 +dddvi406 divideint 1 1234567890 -> 0 +dddvi407 divideint 1234567891 10 -> 123456789 +dddvi408 divideint 1 1234567891 -> 0 +dddvi409 divideint 12345678901 100 -> 123456789 +dddvi410 divideint 1 12345678901 -> 0 +dddvi411 divideint 1234567896 10 -> 123456789 +dddvi412 divideint 1 1234567896 -> 0 +dddvi413 divideint 12345678948 100 -> 123456789 +dddvi414 divideint 12345678949 100 -> 123456789 +dddvi415 divideint 12345678950 100 -> 123456789 +dddvi416 divideint 12345678951 100 -> 123456789 +dddvi417 divideint 12345678999 100 -> 123456789 +dddvi441 divideint 12345678000 1 -> 12345678000 +dddvi442 divideint 1 12345678000 -> 0 +dddvi443 divideint 1234567800 1 -> 1234567800 +dddvi444 divideint 1 1234567800 -> 0 +dddvi445 divideint 1234567890 1 -> 1234567890 +dddvi446 divideint 1 1234567890 -> 0 +dddvi447 divideint 1234567891 1 -> 1234567891 +dddvi448 divideint 1 1234567891 -> 0 +dddvi449 divideint 12345678901 1 -> 12345678901 +dddvi450 divideint 1 12345678901 -> 0 +dddvi451 divideint 1234567896 1 -> 1234567896 +dddvi452 divideint 1 1234567896 -> 0 + +-- more zeros, etc. +dddvi531 divideint 5.00 1E-3 -> 5000 +dddvi532 divideint 00.00 0.000 -> NaN Division_undefined +dddvi533 divideint 00.00 0E-3 -> NaN Division_undefined +dddvi534 divideint 0 -0 -> NaN Division_undefined +dddvi535 divideint -0 0 -> NaN Division_undefined +dddvi536 divideint -0 -0 -> NaN Division_undefined + +dddvi541 divideint 0 -1 -> -0 +dddvi542 divideint -0 -1 -> 0 +dddvi543 divideint 0 1 -> 0 +dddvi544 divideint -0 1 -> -0 +dddvi545 divideint -1 0 -> -Infinity Division_by_zero +dddvi546 divideint -1 -0 -> Infinity Division_by_zero +dddvi547 divideint 1 0 -> Infinity Division_by_zero +dddvi548 divideint 1 -0 -> -Infinity Division_by_zero + +dddvi551 divideint 0.0 -1 -> -0 +dddvi552 divideint -0.0 -1 -> 0 +dddvi553 divideint 0.0 1 -> 0 +dddvi554 divideint -0.0 1 -> -0 +dddvi555 divideint -1.0 0 -> -Infinity Division_by_zero +dddvi556 divideint -1.0 -0 -> Infinity Division_by_zero +dddvi557 divideint 1.0 0 -> Infinity Division_by_zero +dddvi558 divideint 1.0 -0 -> -Infinity Division_by_zero + +dddvi561 divideint 0 -1.0 -> -0 +dddvi562 divideint -0 -1.0 -> 0 +dddvi563 divideint 0 1.0 -> 0 +dddvi564 divideint -0 1.0 -> -0 +dddvi565 divideint -1 0.0 -> -Infinity Division_by_zero +dddvi566 divideint -1 -0.0 -> Infinity Division_by_zero +dddvi567 divideint 1 0.0 -> Infinity Division_by_zero +dddvi568 divideint 1 -0.0 -> -Infinity Division_by_zero + +dddvi571 divideint 0.0 -1.0 -> -0 +dddvi572 divideint -0.0 -1.0 -> 0 +dddvi573 divideint 0.0 1.0 -> 0 +dddvi574 divideint -0.0 1.0 -> -0 +dddvi575 divideint -1.0 0.0 -> -Infinity Division_by_zero +dddvi576 divideint -1.0 -0.0 -> Infinity Division_by_zero +dddvi577 divideint 1.0 0.0 -> Infinity Division_by_zero +dddvi578 divideint 1.0 -0.0 -> -Infinity Division_by_zero + +-- Specials +dddvi580 divideint Inf -Inf -> NaN Invalid_operation +dddvi581 divideint Inf -1000 -> -Infinity +dddvi582 divideint Inf -1 -> -Infinity +dddvi583 divideint Inf -0 -> -Infinity +dddvi584 divideint Inf 0 -> Infinity +dddvi585 divideint Inf 1 -> Infinity +dddvi586 divideint Inf 1000 -> Infinity +dddvi587 divideint Inf Inf -> NaN Invalid_operation +dddvi588 divideint -1000 Inf -> -0 +dddvi589 divideint -Inf Inf -> NaN Invalid_operation +dddvi590 divideint -1 Inf -> -0 +dddvi591 divideint -0 Inf -> -0 +dddvi592 divideint 0 Inf -> 0 +dddvi593 divideint 1 Inf -> 0 +dddvi594 divideint 1000 Inf -> 0 +dddvi595 divideint Inf Inf -> NaN Invalid_operation + +dddvi600 divideint -Inf -Inf -> NaN Invalid_operation +dddvi601 divideint -Inf -1000 -> Infinity +dddvi602 divideint -Inf -1 -> Infinity +dddvi603 divideint -Inf -0 -> Infinity +dddvi604 divideint -Inf 0 -> -Infinity +dddvi605 divideint -Inf 1 -> -Infinity +dddvi606 divideint -Inf 1000 -> -Infinity +dddvi607 divideint -Inf Inf -> NaN Invalid_operation +dddvi608 divideint -1000 Inf -> -0 +dddvi609 divideint -Inf -Inf -> NaN Invalid_operation +dddvi610 divideint -1 -Inf -> 0 +dddvi611 divideint -0 -Inf -> 0 +dddvi612 divideint 0 -Inf -> -0 +dddvi613 divideint 1 -Inf -> -0 +dddvi614 divideint 1000 -Inf -> -0 +dddvi615 divideint Inf -Inf -> NaN Invalid_operation + +dddvi621 divideint NaN -Inf -> NaN +dddvi622 divideint NaN -1000 -> NaN +dddvi623 divideint NaN -1 -> NaN +dddvi624 divideint NaN -0 -> NaN +dddvi625 divideint NaN 0 -> NaN +dddvi626 divideint NaN 1 -> NaN +dddvi627 divideint NaN 1000 -> NaN +dddvi628 divideint NaN Inf -> NaN +dddvi629 divideint NaN NaN -> NaN +dddvi630 divideint -Inf NaN -> NaN +dddvi631 divideint -1000 NaN -> NaN +dddvi632 divideint -1 NaN -> NaN +dddvi633 divideint -0 NaN -> NaN +dddvi634 divideint 0 NaN -> NaN +dddvi635 divideint 1 NaN -> NaN +dddvi636 divideint 1000 NaN -> NaN +dddvi637 divideint Inf NaN -> NaN + +dddvi641 divideint sNaN -Inf -> NaN Invalid_operation +dddvi642 divideint sNaN -1000 -> NaN Invalid_operation +dddvi643 divideint sNaN -1 -> NaN Invalid_operation +dddvi644 divideint sNaN -0 -> NaN Invalid_operation +dddvi645 divideint sNaN 0 -> NaN Invalid_operation +dddvi646 divideint sNaN 1 -> NaN Invalid_operation +dddvi647 divideint sNaN 1000 -> NaN Invalid_operation +dddvi648 divideint sNaN NaN -> NaN Invalid_operation +dddvi649 divideint sNaN sNaN -> NaN Invalid_operation +dddvi650 divideint NaN sNaN -> NaN Invalid_operation +dddvi651 divideint -Inf sNaN -> NaN Invalid_operation +dddvi652 divideint -1000 sNaN -> NaN Invalid_operation +dddvi653 divideint -1 sNaN -> NaN Invalid_operation +dddvi654 divideint -0 sNaN -> NaN Invalid_operation +dddvi655 divideint 0 sNaN -> NaN Invalid_operation +dddvi656 divideint 1 sNaN -> NaN Invalid_operation +dddvi657 divideint 1000 sNaN -> NaN Invalid_operation +dddvi658 divideint Inf sNaN -> NaN Invalid_operation +dddvi659 divideint NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +dddvi661 divideint NaN9 -Inf -> NaN9 +dddvi662 divideint NaN8 1000 -> NaN8 +dddvi663 divideint NaN7 Inf -> NaN7 +dddvi664 divideint -NaN6 NaN5 -> -NaN6 +dddvi665 divideint -Inf NaN4 -> NaN4 +dddvi666 divideint -1000 NaN3 -> NaN3 +dddvi667 divideint Inf -NaN2 -> -NaN2 + +dddvi671 divideint -sNaN99 -Inf -> -NaN99 Invalid_operation +dddvi672 divideint sNaN98 -1 -> NaN98 Invalid_operation +dddvi673 divideint sNaN97 NaN -> NaN97 Invalid_operation +dddvi674 divideint sNaN96 sNaN94 -> NaN96 Invalid_operation +dddvi675 divideint NaN95 sNaN93 -> NaN93 Invalid_operation +dddvi676 divideint -Inf sNaN92 -> NaN92 Invalid_operation +dddvi677 divideint 0 sNaN91 -> NaN91 Invalid_operation +dddvi678 divideint Inf -sNaN90 -> -NaN90 Invalid_operation +dddvi679 divideint NaN sNaN89 -> NaN89 Invalid_operation + +-- Null tests +dddvi900 divideint 10 # -> NaN Invalid_operation +dddvi901 divideint # 10 -> NaN Invalid_operation Added: python/branches/release25-maint/Lib/test/decimaltestdata/ddEncode.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/ddEncode.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,490 @@ +------------------------------------------------------------------------ +-- ddEncode.decTest -- decimal eight-byte format testcases -- +-- Copyright (c) IBM Corporation, 2000, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +-- [Previously called decimal64.decTest] +version: 2.57 + +-- This set of tests is for the eight-byte concrete representation. +-- Its characteristics are: +-- +-- 1 bit sign +-- 5 bits combination field +-- 8 bits exponent continuation +-- 50 bits coefficient continuation +-- +-- Total exponent length 10 bits +-- Total coefficient length 54 bits (16 digits) +-- +-- Elimit = 767 (maximum encoded exponent) +-- Emax = 384 (largest exponent value) +-- Emin = -383 (smallest exponent value) +-- bias = 398 (subtracted from encoded exponent) = -Etiny + +-- The testcases here have only exactly representable data on the +-- 'left-hand-side'; rounding from strings is tested in 'base' +-- testcase groups. + +extended: 1 +clamp: 1 +precision: 16 +rounding: half_up +maxExponent: 384 +minExponent: -383 + +-- General testcases +-- (mostly derived from the Strawman 4 document and examples) +dece001 apply #A2300000000003D0 -> -7.50 +dece002 apply -7.50 -> #A2300000000003D0 +-- derivative canonical plain strings +dece003 apply #A23c0000000003D0 -> -7.50E+3 +dece004 apply -7.50E+3 -> #A23c0000000003D0 +dece005 apply #A2380000000003D0 -> -750 +dece006 apply -750 -> #A2380000000003D0 +dece007 apply #A2340000000003D0 -> -75.0 +dece008 apply -75.0 -> #A2340000000003D0 +dece009 apply #A22c0000000003D0 -> -0.750 +dece010 apply -0.750 -> #A22c0000000003D0 +dece011 apply #A2280000000003D0 -> -0.0750 +dece012 apply -0.0750 -> #A2280000000003D0 +dece013 apply #A2200000000003D0 -> -0.000750 +dece014 apply -0.000750 -> #A2200000000003D0 +dece015 apply #A2180000000003D0 -> -0.00000750 +dece016 apply -0.00000750 -> #A2180000000003D0 +dece017 apply #A2140000000003D0 -> -7.50E-7 +dece018 apply -7.50E-7 -> #A2140000000003D0 + +-- Normality +dece020 apply 1234567890123456 -> #263934b9c1e28e56 +dece021 apply -1234567890123456 -> #a63934b9c1e28e56 +dece022 apply 1234.567890123456 -> #260934b9c1e28e56 +dece023 apply #260934b9c1e28e56 -> 1234.567890123456 +dece024 apply 1111111111111111 -> #2638912449124491 +dece025 apply 9999999999999999 -> #6e38ff3fcff3fcff + +-- Nmax and similar +dece031 apply 9999999999999999E+369 -> #77fcff3fcff3fcff +dece032 apply 9.999999999999999E+384 -> #77fcff3fcff3fcff +dece033 apply #77fcff3fcff3fcff -> 9.999999999999999E+384 +dece034 apply 1.234567890123456E+384 -> #47fd34b9c1e28e56 +dece035 apply #47fd34b9c1e28e56 -> 1.234567890123456E+384 +-- fold-downs (more below) +dece036 apply 1.23E+384 -> #47fd300000000000 Clamped +dece037 apply #47fd300000000000 -> 1.230000000000000E+384 +decd038 apply 1E+384 -> #47fc000000000000 Clamped +decd039 apply #47fc000000000000 -> 1.000000000000000E+384 + +decd051 apply 12345 -> #22380000000049c5 +decd052 apply #22380000000049c5 -> 12345 +decd053 apply 1234 -> #2238000000000534 +decd054 apply #2238000000000534 -> 1234 +decd055 apply 123 -> #22380000000000a3 +decd056 apply #22380000000000a3 -> 123 +decd057 apply 12 -> #2238000000000012 +decd058 apply #2238000000000012 -> 12 +decd059 apply 1 -> #2238000000000001 +decd060 apply #2238000000000001 -> 1 +decd061 apply 1.23 -> #22300000000000a3 +decd062 apply #22300000000000a3 -> 1.23 +decd063 apply 123.45 -> #22300000000049c5 +decd064 apply #22300000000049c5 -> 123.45 + +-- Nmin and below +decd071 apply 1E-383 -> #003c000000000001 +decd072 apply #003c000000000001 -> 1E-383 +decd073 apply 1.000000000000000E-383 -> #0400000000000000 +decd074 apply #0400000000000000 -> 1.000000000000000E-383 +decd075 apply 1.000000000000001E-383 -> #0400000000000001 +decd076 apply #0400000000000001 -> 1.000000000000001E-383 + +decd077 apply 0.100000000000000E-383 -> #0000800000000000 Subnormal +decd078 apply #0000800000000000 -> 1.00000000000000E-384 Subnormal +decd079 apply 0.000000000000010E-383 -> #0000000000000010 Subnormal +decd080 apply #0000000000000010 -> 1.0E-397 Subnormal +decd081 apply 0.00000000000001E-383 -> #0004000000000001 Subnormal +decd082 apply #0004000000000001 -> 1E-397 Subnormal +decd083 apply 0.000000000000001E-383 -> #0000000000000001 Subnormal +decd084 apply #0000000000000001 -> 1E-398 Subnormal +-- next is smallest all-nines +decd085 apply 9999999999999999E-398 -> #6400ff3fcff3fcff +decd086 apply #6400ff3fcff3fcff -> 9.999999999999999E-383 +-- and a problematic divide result +decd088 apply 1.111111111111111E-383 -> #0400912449124491 +decd089 apply #0400912449124491 -> 1.111111111111111E-383 + +-- forties +decd090 apply 40 -> #2238000000000040 +decd091 apply 39.99 -> #2230000000000cff + +-- underflows cannot be tested as all LHS exact + +-- Same again, negatives +-- Nmax and similar +decd122 apply -9.999999999999999E+384 -> #f7fcff3fcff3fcff +decd123 apply #f7fcff3fcff3fcff -> -9.999999999999999E+384 +decd124 apply -1.234567890123456E+384 -> #c7fd34b9c1e28e56 +decd125 apply #c7fd34b9c1e28e56 -> -1.234567890123456E+384 +-- fold-downs (more below) +decd130 apply -1.23E+384 -> #c7fd300000000000 Clamped +decd131 apply #c7fd300000000000 -> -1.230000000000000E+384 +decd132 apply -1E+384 -> #c7fc000000000000 Clamped +decd133 apply #c7fc000000000000 -> -1.000000000000000E+384 + +-- overflows +decd151 apply -12345 -> #a2380000000049c5 +decd152 apply #a2380000000049c5 -> -12345 +decd153 apply -1234 -> #a238000000000534 +decd154 apply #a238000000000534 -> -1234 +decd155 apply -123 -> #a2380000000000a3 +decd156 apply #a2380000000000a3 -> -123 +decd157 apply -12 -> #a238000000000012 +decd158 apply #a238000000000012 -> -12 +decd159 apply -1 -> #a238000000000001 +decd160 apply #a238000000000001 -> -1 +decd161 apply -1.23 -> #a2300000000000a3 +decd162 apply #a2300000000000a3 -> -1.23 +decd163 apply -123.45 -> #a2300000000049c5 +decd164 apply #a2300000000049c5 -> -123.45 + +-- Nmin and below +decd171 apply -1E-383 -> #803c000000000001 +decd172 apply #803c000000000001 -> -1E-383 +decd173 apply -1.000000000000000E-383 -> #8400000000000000 +decd174 apply #8400000000000000 -> -1.000000000000000E-383 +decd175 apply -1.000000000000001E-383 -> #8400000000000001 +decd176 apply #8400000000000001 -> -1.000000000000001E-383 + +decd177 apply -0.100000000000000E-383 -> #8000800000000000 Subnormal +decd178 apply #8000800000000000 -> -1.00000000000000E-384 Subnormal +decd179 apply -0.000000000000010E-383 -> #8000000000000010 Subnormal +decd180 apply #8000000000000010 -> -1.0E-397 Subnormal +decd181 apply -0.00000000000001E-383 -> #8004000000000001 Subnormal +decd182 apply #8004000000000001 -> -1E-397 Subnormal +decd183 apply -0.000000000000001E-383 -> #8000000000000001 Subnormal +decd184 apply #8000000000000001 -> -1E-398 Subnormal +-- next is smallest all-nines +decd185 apply -9999999999999999E-398 -> #e400ff3fcff3fcff +decd186 apply #e400ff3fcff3fcff -> -9.999999999999999E-383 +-- and a tricky subnormal +decd187 apply 1.11111111111524E-384 -> #00009124491246a4 Subnormal +decd188 apply #00009124491246a4 -> 1.11111111111524E-384 Subnormal + +-- near-underflows +decd189 apply -1e-398 -> #8000000000000001 Subnormal +decd190 apply -1.0e-398 -> #8000000000000001 Subnormal Rounded + +-- zeros +decd401 apply 0E-500 -> #0000000000000000 Clamped +decd402 apply 0E-400 -> #0000000000000000 Clamped +decd403 apply 0E-398 -> #0000000000000000 +decd404 apply #0000000000000000 -> 0E-398 +decd405 apply 0.000000000000000E-383 -> #0000000000000000 +decd406 apply #0000000000000000 -> 0E-398 +decd407 apply 0E-2 -> #2230000000000000 +decd408 apply #2230000000000000 -> 0.00 +decd409 apply 0 -> #2238000000000000 +decd410 apply #2238000000000000 -> 0 +decd411 apply 0E+3 -> #2244000000000000 +decd412 apply #2244000000000000 -> 0E+3 +decd413 apply 0E+369 -> #43fc000000000000 +decd414 apply #43fc000000000000 -> 0E+369 +-- clamped zeros... +decd415 apply 0E+370 -> #43fc000000000000 Clamped +decd416 apply #43fc000000000000 -> 0E+369 +decd417 apply 0E+384 -> #43fc000000000000 Clamped +decd418 apply #43fc000000000000 -> 0E+369 +decd419 apply 0E+400 -> #43fc000000000000 Clamped +decd420 apply #43fc000000000000 -> 0E+369 +decd421 apply 0E+500 -> #43fc000000000000 Clamped +decd422 apply #43fc000000000000 -> 0E+369 + +-- negative zeros +decd431 apply -0E-400 -> #8000000000000000 Clamped +decd432 apply -0E-400 -> #8000000000000000 Clamped +decd433 apply -0E-398 -> #8000000000000000 +decd434 apply #8000000000000000 -> -0E-398 +decd435 apply -0.000000000000000E-383 -> #8000000000000000 +decd436 apply #8000000000000000 -> -0E-398 +decd437 apply -0E-2 -> #a230000000000000 +decd438 apply #a230000000000000 -> -0.00 +decd439 apply -0 -> #a238000000000000 +decd440 apply #a238000000000000 -> -0 +decd441 apply -0E+3 -> #a244000000000000 +decd442 apply #a244000000000000 -> -0E+3 +decd443 apply -0E+369 -> #c3fc000000000000 +decd444 apply #c3fc000000000000 -> -0E+369 +-- clamped zeros... +decd445 apply -0E+370 -> #c3fc000000000000 Clamped +decd446 apply #c3fc000000000000 -> -0E+369 +decd447 apply -0E+384 -> #c3fc000000000000 Clamped +decd448 apply #c3fc000000000000 -> -0E+369 +decd449 apply -0E+400 -> #c3fc000000000000 Clamped +decd450 apply #c3fc000000000000 -> -0E+369 +decd451 apply -0E+500 -> #c3fc000000000000 Clamped +decd452 apply #c3fc000000000000 -> -0E+369 + +-- exponents +decd460 apply #225c000000000007 -> 7E+9 +decd461 apply 7E+9 -> #225c000000000007 +decd462 apply #23c4000000000007 -> 7E+99 +decd463 apply 7E+99 -> #23c4000000000007 + +-- Specials +decd500 apply Infinity -> #7800000000000000 +decd501 apply #7878787878787878 -> #7800000000000000 +decd502 apply #7800000000000000 -> Infinity +decd503 apply #7979797979797979 -> #7800000000000000 +decd504 apply #7900000000000000 -> Infinity +decd505 apply #7a7a7a7a7a7a7a7a -> #7800000000000000 +decd506 apply #7a00000000000000 -> Infinity +decd507 apply #7b7b7b7b7b7b7b7b -> #7800000000000000 +decd508 apply #7b00000000000000 -> Infinity + +decd509 apply NaN -> #7c00000000000000 +decd510 apply #7c7c7c7c7c7c7c7c -> #7c007c7c7c7c7c7c +decd511 apply #7c00000000000000 -> NaN +decd512 apply #7d7d7d7d7d7d7d7d -> #7c017d7d7d7d7d7d +decd513 apply #7d00000000000000 -> NaN +decd514 apply #7e7e7e7e7e7e7e7e -> #7e007e7e7e7e7c7e +decd515 apply #7e00000000000000 -> sNaN +decd516 apply #7f7f7f7f7f7f7f7f -> #7e007f7f7f7f7c7f +decd517 apply #7f00000000000000 -> sNaN +decd518 apply #7fffffffffffffff -> sNaN999999999999999 +decd519 apply #7fffffffffffffff -> #7e00ff3fcff3fcff + +decd520 apply -Infinity -> #f800000000000000 +decd521 apply #f878787878787878 -> #f800000000000000 +decd522 apply #f800000000000000 -> -Infinity +decd523 apply #f979797979797979 -> #f800000000000000 +decd524 apply #f900000000000000 -> -Infinity +decd525 apply #fa7a7a7a7a7a7a7a -> #f800000000000000 +decd526 apply #fa00000000000000 -> -Infinity +decd527 apply #fb7b7b7b7b7b7b7b -> #f800000000000000 +decd528 apply #fb00000000000000 -> -Infinity + +decd529 apply -NaN -> #fc00000000000000 +decd530 apply #fc7c7c7c7c7c7c7c -> #fc007c7c7c7c7c7c +decd531 apply #fc00000000000000 -> -NaN +decd532 apply #fd7d7d7d7d7d7d7d -> #fc017d7d7d7d7d7d +decd533 apply #fd00000000000000 -> -NaN +decd534 apply #fe7e7e7e7e7e7e7e -> #fe007e7e7e7e7c7e +decd535 apply #fe00000000000000 -> -sNaN +decd536 apply #ff7f7f7f7f7f7f7f -> #fe007f7f7f7f7c7f +decd537 apply #ff00000000000000 -> -sNaN +decd538 apply #ffffffffffffffff -> -sNaN999999999999999 +decd539 apply #ffffffffffffffff -> #fe00ff3fcff3fcff + +-- diagnostic NaNs +decd540 apply NaN -> #7c00000000000000 +decd541 apply NaN0 -> #7c00000000000000 +decd542 apply NaN1 -> #7c00000000000001 +decd543 apply NaN12 -> #7c00000000000012 +decd544 apply NaN79 -> #7c00000000000079 +decd545 apply NaN12345 -> #7c000000000049c5 +decd546 apply NaN123456 -> #7c00000000028e56 +decd547 apply NaN799799 -> #7c000000000f7fdf +decd548 apply NaN799799799799799 -> #7c03dff7fdff7fdf +decd549 apply NaN999999999999999 -> #7c00ff3fcff3fcff +-- too many digits + +-- fold-down full sequence +decd601 apply 1E+384 -> #47fc000000000000 Clamped +decd602 apply #47fc000000000000 -> 1.000000000000000E+384 +decd603 apply 1E+383 -> #43fc800000000000 Clamped +decd604 apply #43fc800000000000 -> 1.00000000000000E+383 +decd605 apply 1E+382 -> #43fc100000000000 Clamped +decd606 apply #43fc100000000000 -> 1.0000000000000E+382 +decd607 apply 1E+381 -> #43fc010000000000 Clamped +decd608 apply #43fc010000000000 -> 1.000000000000E+381 +decd609 apply 1E+380 -> #43fc002000000000 Clamped +decd610 apply #43fc002000000000 -> 1.00000000000E+380 +decd611 apply 1E+379 -> #43fc000400000000 Clamped +decd612 apply #43fc000400000000 -> 1.0000000000E+379 +decd613 apply 1E+378 -> #43fc000040000000 Clamped +decd614 apply #43fc000040000000 -> 1.000000000E+378 +decd615 apply 1E+377 -> #43fc000008000000 Clamped +decd616 apply #43fc000008000000 -> 1.00000000E+377 +decd617 apply 1E+376 -> #43fc000001000000 Clamped +decd618 apply #43fc000001000000 -> 1.0000000E+376 +decd619 apply 1E+375 -> #43fc000000100000 Clamped +decd620 apply #43fc000000100000 -> 1.000000E+375 +decd621 apply 1E+374 -> #43fc000000020000 Clamped +decd622 apply #43fc000000020000 -> 1.00000E+374 +decd623 apply 1E+373 -> #43fc000000004000 Clamped +decd624 apply #43fc000000004000 -> 1.0000E+373 +decd625 apply 1E+372 -> #43fc000000000400 Clamped +decd626 apply #43fc000000000400 -> 1.000E+372 +decd627 apply 1E+371 -> #43fc000000000080 Clamped +decd628 apply #43fc000000000080 -> 1.00E+371 +decd629 apply 1E+370 -> #43fc000000000010 Clamped +decd630 apply #43fc000000000010 -> 1.0E+370 +decd631 apply 1E+369 -> #43fc000000000001 +decd632 apply #43fc000000000001 -> 1E+369 +decd633 apply 1E+368 -> #43f8000000000001 +decd634 apply #43f8000000000001 -> 1E+368 +-- same with 9s +decd641 apply 9E+384 -> #77fc000000000000 Clamped +decd642 apply #77fc000000000000 -> 9.000000000000000E+384 +decd643 apply 9E+383 -> #43fc8c0000000000 Clamped +decd644 apply #43fc8c0000000000 -> 9.00000000000000E+383 +decd645 apply 9E+382 -> #43fc1a0000000000 Clamped +decd646 apply #43fc1a0000000000 -> 9.0000000000000E+382 +decd647 apply 9E+381 -> #43fc090000000000 Clamped +decd648 apply #43fc090000000000 -> 9.000000000000E+381 +decd649 apply 9E+380 -> #43fc002300000000 Clamped +decd650 apply #43fc002300000000 -> 9.00000000000E+380 +decd651 apply 9E+379 -> #43fc000680000000 Clamped +decd652 apply #43fc000680000000 -> 9.0000000000E+379 +decd653 apply 9E+378 -> #43fc000240000000 Clamped +decd654 apply #43fc000240000000 -> 9.000000000E+378 +decd655 apply 9E+377 -> #43fc000008c00000 Clamped +decd656 apply #43fc000008c00000 -> 9.00000000E+377 +decd657 apply 9E+376 -> #43fc000001a00000 Clamped +decd658 apply #43fc000001a00000 -> 9.0000000E+376 +decd659 apply 9E+375 -> #43fc000000900000 Clamped +decd660 apply #43fc000000900000 -> 9.000000E+375 +decd661 apply 9E+374 -> #43fc000000023000 Clamped +decd662 apply #43fc000000023000 -> 9.00000E+374 +decd663 apply 9E+373 -> #43fc000000006800 Clamped +decd664 apply #43fc000000006800 -> 9.0000E+373 +decd665 apply 9E+372 -> #43fc000000002400 Clamped +decd666 apply #43fc000000002400 -> 9.000E+372 +decd667 apply 9E+371 -> #43fc00000000008c Clamped +decd668 apply #43fc00000000008c -> 9.00E+371 +decd669 apply 9E+370 -> #43fc00000000001a Clamped +decd670 apply #43fc00000000001a -> 9.0E+370 +decd671 apply 9E+369 -> #43fc000000000009 +decd672 apply #43fc000000000009 -> 9E+369 +decd673 apply 9E+368 -> #43f8000000000009 +decd674 apply #43f8000000000009 -> 9E+368 + + +-- Selected DPD codes +decd700 apply #2238000000000000 -> 0 +decd701 apply #2238000000000009 -> 9 +decd702 apply #2238000000000010 -> 10 +decd703 apply #2238000000000019 -> 19 +decd704 apply #2238000000000020 -> 20 +decd705 apply #2238000000000029 -> 29 +decd706 apply #2238000000000030 -> 30 +decd707 apply #2238000000000039 -> 39 +decd708 apply #2238000000000040 -> 40 +decd709 apply #2238000000000049 -> 49 +decd710 apply #2238000000000050 -> 50 +decd711 apply #2238000000000059 -> 59 +decd712 apply #2238000000000060 -> 60 +decd713 apply #2238000000000069 -> 69 +decd714 apply #2238000000000070 -> 70 +decd715 apply #2238000000000071 -> 71 +decd716 apply #2238000000000072 -> 72 +decd717 apply #2238000000000073 -> 73 +decd718 apply #2238000000000074 -> 74 +decd719 apply #2238000000000075 -> 75 +decd720 apply #2238000000000076 -> 76 +decd721 apply #2238000000000077 -> 77 +decd722 apply #2238000000000078 -> 78 +decd723 apply #2238000000000079 -> 79 + +decd725 apply #223800000000029e -> 994 +decd726 apply #223800000000029f -> 995 +decd727 apply #22380000000002a0 -> 520 +decd728 apply #22380000000002a1 -> 521 +-- from telco test data +decd730 apply #2238000000000188 -> 308 +decd731 apply #22380000000001a3 -> 323 +decd732 apply #223800000000002a -> 82 +decd733 apply #22380000000001a9 -> 329 +decd734 apply #2238000000000081 -> 101 +decd735 apply #22380000000002a2 -> 522 + +-- DPD: one of each of the huffman groups +decd740 apply #22380000000003f7 -> 777 +decd741 apply #22380000000003f8 -> 778 +decd742 apply #22380000000003eb -> 787 +decd743 apply #223800000000037d -> 877 +decd744 apply #223800000000039f -> 997 +decd745 apply #22380000000003bf -> 979 +decd746 apply #22380000000003df -> 799 +decd747 apply #223800000000006e -> 888 + +-- DPD all-highs cases (includes the 24 redundant codes) +decd750 apply #223800000000006e -> 888 +decd751 apply #223800000000016e -> 888 +decd752 apply #223800000000026e -> 888 +decd753 apply #223800000000036e -> 888 +decd754 apply #223800000000006f -> 889 +decd755 apply #223800000000016f -> 889 +decd756 apply #223800000000026f -> 889 +decd757 apply #223800000000036f -> 889 + +decd760 apply #223800000000007e -> 898 +decd761 apply #223800000000017e -> 898 +decd762 apply #223800000000027e -> 898 +decd763 apply #223800000000037e -> 898 +decd764 apply #223800000000007f -> 899 +decd765 apply #223800000000017f -> 899 +decd766 apply #223800000000027f -> 899 +decd767 apply #223800000000037f -> 899 + +decd770 apply #22380000000000ee -> 988 +decd771 apply #22380000000001ee -> 988 +decd772 apply #22380000000002ee -> 988 +decd773 apply #22380000000003ee -> 988 +decd774 apply #22380000000000ef -> 989 +decd775 apply #22380000000001ef -> 989 +decd776 apply #22380000000002ef -> 989 +decd777 apply #22380000000003ef -> 989 + +decd780 apply #22380000000000fe -> 998 +decd781 apply #22380000000001fe -> 998 +decd782 apply #22380000000002fe -> 998 +decd783 apply #22380000000003fe -> 998 +decd784 apply #22380000000000ff -> 999 +decd785 apply #22380000000001ff -> 999 +decd786 apply #22380000000002ff -> 999 +decd787 apply #22380000000003ff -> 999 + +-- values around [u]int32 edges (zeros done earlier) +decd800 apply -2147483646 -> #a23800008c78af46 +decd801 apply -2147483647 -> #a23800008c78af47 +decd802 apply -2147483648 -> #a23800008c78af48 +decd803 apply -2147483649 -> #a23800008c78af49 +decd804 apply 2147483646 -> #223800008c78af46 +decd805 apply 2147483647 -> #223800008c78af47 +decd806 apply 2147483648 -> #223800008c78af48 +decd807 apply 2147483649 -> #223800008c78af49 +decd808 apply 4294967294 -> #2238000115afb55a +decd809 apply 4294967295 -> #2238000115afb55b +decd810 apply 4294967296 -> #2238000115afb57a +decd811 apply 4294967297 -> #2238000115afb57b + +decd820 apply #a23800008c78af46 -> -2147483646 +decd821 apply #a23800008c78af47 -> -2147483647 +decd822 apply #a23800008c78af48 -> -2147483648 +decd823 apply #a23800008c78af49 -> -2147483649 +decd824 apply #223800008c78af46 -> 2147483646 +decd825 apply #223800008c78af47 -> 2147483647 +decd826 apply #223800008c78af48 -> 2147483648 +decd827 apply #223800008c78af49 -> 2147483649 +decd828 apply #2238000115afb55a -> 4294967294 +decd829 apply #2238000115afb55b -> 4294967295 +decd830 apply #2238000115afb57a -> 4294967296 +decd831 apply #2238000115afb57b -> 4294967297 + +-- for narrowing +decd840 apply #2870000000000000 -> 2.000000000000000E-99 Added: python/branches/release25-maint/Lib/test/decimaltestdata/ddFMA.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/ddFMA.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,1698 @@ +------------------------------------------------------------------------ +-- ddFMA.decTest -- decDouble Fused Multiply Add -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +precision: 16 +maxExponent: 384 +minExponent: -383 +extended: 1 +clamp: 1 +rounding: half_even + +-- These tests comprese three parts: +-- 1. Sanity checks and other three-operand tests (especially those +-- where the fused operation makes a difference) +-- 2. Multiply tests (third operand is neutral zero [0E+emax]) +-- 3. Addition tests (first operand is 1) +-- The multiply and addition tests are extensive because FMA may have +-- its own dedicated multiplication or addition routine(s), and they +-- also inherently check the left-to-right properties. + +-- Sanity checks +ddfma0001 fma 1 1 1 -> 2 +ddfma0002 fma 1 1 2 -> 3 +ddfma0003 fma 2 2 3 -> 7 +ddfma0004 fma 9 9 9 -> 90 +ddfma0005 fma -1 1 1 -> 0 +ddfma0006 fma -1 1 2 -> 1 +ddfma0007 fma -2 2 3 -> -1 +ddfma0008 fma -9 9 9 -> -72 +ddfma0011 fma 1 -1 1 -> 0 +ddfma0012 fma 1 -1 2 -> 1 +ddfma0013 fma 2 -2 3 -> -1 +ddfma0014 fma 9 -9 9 -> -72 +ddfma0015 fma 1 1 -1 -> 0 +ddfma0016 fma 1 1 -2 -> -1 +ddfma0017 fma 2 2 -3 -> 1 +ddfma0018 fma 9 9 -9 -> 72 + +-- non-integer exacts +ddfma0100 fma 25.2 63.6 -438 -> 1164.72 +ddfma0101 fma 0.301 0.380 334 -> 334.114380 +ddfma0102 fma 49.2 -4.8 23.3 -> -212.86 +ddfma0103 fma 4.22 0.079 -94.6 -> -94.26662 +ddfma0104 fma 903 0.797 0.887 -> 720.578 +ddfma0105 fma 6.13 -161 65.9 -> -921.03 +ddfma0106 fma 28.2 727 5.45 -> 20506.85 +ddfma0107 fma 4 605 688 -> 3108 +ddfma0108 fma 93.3 0.19 0.226 -> 17.953 +ddfma0109 fma 0.169 -341 5.61 -> -52.019 +ddfma0110 fma -72.2 30 -51.2 -> -2217.2 +ddfma0111 fma -0.409 13 20.4 -> 15.083 +ddfma0112 fma 317 77.0 19.0 -> 24428.0 +ddfma0113 fma 47 6.58 1.62 -> 310.88 +ddfma0114 fma 1.36 0.984 0.493 -> 1.83124 +ddfma0115 fma 72.7 274 1.56 -> 19921.36 +ddfma0116 fma 335 847 83 -> 283828 +ddfma0117 fma 666 0.247 25.4 -> 189.902 +ddfma0118 fma -3.87 3.06 78.0 -> 66.1578 +ddfma0119 fma 0.742 192 35.6 -> 178.064 +ddfma0120 fma -91.6 5.29 0.153 -> -484.411 + +-- cases where result is different from separate multiply + add; each +-- is preceded by the result of unfused multiply and add +-- [this is about 20% of all similar cases in general] +-- -> 7.123356429257969E+16 +ddfma0201 fma 27583489.6645 2582471078.04 2593183.42371 -> 7.123356429257970E+16 Inexact Rounded +-- -> 22813275328.80506 +ddfma0208 fma 24280.355566 939577.397653 2032.013252 -> 22813275328.80507 Inexact Rounded +-- -> -2.030397734278062E+16 +ddfma0209 fma 7848976432 -2586831.2281 137903.517909 -> -2.030397734278061E+16 Inexact Rounded +-- -> 2040774094814.077 +ddfma0217 fma 56890.388731 35872030.4255 339337.123410 -> 2040774094814.078 Inexact Rounded +-- -> 2.714469575205049E+18 +ddfma0220 fma 7533543.57445 360317763928 5073392.31638 -> 2.714469575205050E+18 Inexact Rounded +-- -> 1.011676297716716E+19 +ddfma0223 fma 739945255.563 13672312784.1 -994381.53572 -> 1.011676297716715E+19 Inexact Rounded +-- -> -2.914135721455315E+23 +ddfma0224 fma -413510957218 704729988550 9234162614.0 -> -2.914135721455314E+23 Inexact Rounded +-- -> 2.620119863365786E+17 +ddfma0226 fma 437484.00601 598906432790 894450638.442 -> 2.620119863365787E+17 Inexact Rounded +-- -> 1.272647995808178E+19 +ddfma0253 fma 73287556929 173651305.784 -358312568.389 -> 1.272647995808177E+19 Inexact Rounded +-- -> -1.753769320861851E+18 +ddfma0257 fma 203258304486 -8628278.8066 153127.446727 -> -1.753769320861850E+18 Inexact Rounded +-- -> -1.550737835263346E+17 +ddfma0260 fma 42560533.1774 -3643605282.86 178277.96377 -> -1.550737835263347E+17 Inexact Rounded +-- -> 2.897624620576005E+22 +ddfma0269 fma 142656587375 203118879670 604576103991 -> 2.897624620576004E+22 Inexact Rounded + +-- Cases where multiply would overflow or underflow if separate +fma0300 fma 9e+384 10 0 -> Infinity Overflow Inexact Rounded +fma0301 fma 1e+384 10 0 -> Infinity Overflow Inexact Rounded +fma0302 fma 1e+384 10 -1e+384 -> 9.000000000000000E+384 Clamped +fma0303 fma 1e+384 10 -9e+384 -> 1.000000000000000E+384 Clamped +-- subnormal etc. +fma0305 fma 1e-398 0.1 0 -> 0E-398 Underflow Subnormal Inexact Rounded Clamped +fma0306 fma 1e-398 0.1 1 -> 1.000000000000000 Inexact Rounded +fma0307 fma 1e-398 0.1 1e-398 -> 1E-398 Underflow Subnormal Inexact Rounded + +-- Infinite combinations +ddfma0800 fma Inf Inf Inf -> Infinity +ddfma0801 fma Inf Inf -Inf -> NaN Invalid_operation +ddfma0802 fma Inf -Inf Inf -> NaN Invalid_operation +ddfma0803 fma Inf -Inf -Inf -> -Infinity +ddfma0804 fma -Inf Inf Inf -> NaN Invalid_operation +ddfma0805 fma -Inf Inf -Inf -> -Infinity +ddfma0806 fma -Inf -Inf Inf -> Infinity +ddfma0807 fma -Inf -Inf -Inf -> NaN Invalid_operation + +-- Triple NaN propagation +ddfma0900 fma NaN2 NaN3 NaN5 -> NaN2 +ddfma0901 fma 0 NaN3 NaN5 -> NaN3 +ddfma0902 fma 0 0 NaN5 -> NaN5 +-- first sNaN wins (consider qNaN from earlier sNaN being +-- overridden by an sNaN in third operand) +ddfma0903 fma sNaN1 sNaN2 sNaN3 -> NaN1 Invalid_operation +ddfma0904 fma 0 sNaN2 sNaN3 -> NaN2 Invalid_operation +ddfma0905 fma 0 0 sNaN3 -> NaN3 Invalid_operation +ddfma0906 fma sNaN1 sNaN2 sNaN3 -> NaN1 Invalid_operation +ddfma0907 fma NaN7 sNaN2 sNaN3 -> NaN2 Invalid_operation +ddfma0908 fma NaN7 NaN5 sNaN3 -> NaN3 Invalid_operation + +-- MULTIPLICATION TESTS ------------------------------------------------ + +-- sanity checks +ddfma2000 fma 2 2 0e+384 -> 4 +ddfma2001 fma 2 3 0e+384 -> 6 +ddfma2002 fma 5 1 0e+384 -> 5 +ddfma2003 fma 5 2 0e+384 -> 10 +ddfma2004 fma 1.20 2 0e+384 -> 2.40 +ddfma2005 fma 1.20 0 0e+384 -> 0.00 +ddfma2006 fma 1.20 -2 0e+384 -> -2.40 +ddfma2007 fma -1.20 2 0e+384 -> -2.40 +ddfma2008 fma -1.20 0 0e+384 -> 0.00 +ddfma2009 fma -1.20 -2 0e+384 -> 2.40 +ddfma2010 fma 5.09 7.1 0e+384 -> 36.139 +ddfma2011 fma 2.5 4 0e+384 -> 10.0 +ddfma2012 fma 2.50 4 0e+384 -> 10.00 +ddfma2013 fma 1.23456789 1.00000000 0e+384 -> 1.234567890000000 Rounded +ddfma2015 fma 2.50 4 0e+384 -> 10.00 +ddfma2016 fma 9.999999999 9.999999999 0e+384 -> 99.99999998000000 Inexact Rounded +ddfma2017 fma 9.999999999 -9.999999999 0e+384 -> -99.99999998000000 Inexact Rounded +ddfma2018 fma -9.999999999 9.999999999 0e+384 -> -99.99999998000000 Inexact Rounded +ddfma2019 fma -9.999999999 -9.999999999 0e+384 -> 99.99999998000000 Inexact Rounded + +-- zeros, etc. +ddfma2021 fma 0 0 0e+384 -> 0 +ddfma2022 fma 0 -0 0e+384 -> 0 +ddfma2023 fma -0 0 0e+384 -> 0 +ddfma2024 fma -0 -0 0e+384 -> 0 +ddfma2025 fma -0.0 -0.0 0e+384 -> 0.00 +ddfma2026 fma -0.0 -0.0 0e+384 -> 0.00 +ddfma2027 fma -0.0 -0.0 0e+384 -> 0.00 +ddfma2028 fma -0.0 -0.0 0e+384 -> 0.00 +ddfma2030 fma 5.00 1E-3 0e+384 -> 0.00500 +ddfma2031 fma 00.00 0.000 0e+384 -> 0.00000 +ddfma2032 fma 00.00 0E-3 0e+384 -> 0.00000 -- rhs is 0 +ddfma2033 fma 0E-3 00.00 0e+384 -> 0.00000 -- lhs is 0 +ddfma2034 fma -5.00 1E-3 0e+384 -> -0.00500 +ddfma2035 fma -00.00 0.000 0e+384 -> 0.00000 +ddfma2036 fma -00.00 0E-3 0e+384 -> 0.00000 -- rhs is 0 +ddfma2037 fma -0E-3 00.00 0e+384 -> 0.00000 -- lhs is 0 +ddfma2038 fma 5.00 -1E-3 0e+384 -> -0.00500 +ddfma2039 fma 00.00 -0.000 0e+384 -> 0.00000 +ddfma2040 fma 00.00 -0E-3 0e+384 -> 0.00000 -- rhs is 0 +ddfma2041 fma 0E-3 -00.00 0e+384 -> 0.00000 -- lhs is 0 +ddfma2042 fma -5.00 -1E-3 0e+384 -> 0.00500 +ddfma2043 fma -00.00 -0.000 0e+384 -> 0.00000 +ddfma2044 fma -00.00 -0E-3 0e+384 -> 0.00000 -- rhs is 0 +ddfma2045 fma -0E-3 -00.00 -0e+384 -> 0.00000 -- lhs is 0 +ddfma2046 fma -0E-3 00.00 -0e+384 -> -0.00000 +ddfma2047 fma 0E-3 -00.00 -0e+384 -> -0.00000 +ddfma2048 fma 0E-3 00.00 -0e+384 -> 0.00000 + +-- examples from decarith +ddfma2050 fma 1.20 3 0e+384 -> 3.60 +ddfma2051 fma 7 3 0e+384 -> 21 +ddfma2052 fma 0.9 0.8 0e+384 -> 0.72 +ddfma2053 fma 0.9 -0 0e+384 -> 0.0 +ddfma2054 fma 654321 654321 0e+384 -> 428135971041 + +ddfma2060 fma 123.45 1e7 0e+384 -> 1.2345E+9 +ddfma2061 fma 123.45 1e8 0e+384 -> 1.2345E+10 +ddfma2062 fma 123.45 1e+9 0e+384 -> 1.2345E+11 +ddfma2063 fma 123.45 1e10 0e+384 -> 1.2345E+12 +ddfma2064 fma 123.45 1e11 0e+384 -> 1.2345E+13 +ddfma2065 fma 123.45 1e12 0e+384 -> 1.2345E+14 +ddfma2066 fma 123.45 1e13 0e+384 -> 1.2345E+15 + + +-- test some intermediate lengths +-- 1234567890123456 +ddfma2080 fma 0.1 1230123456456789 0e+384 -> 123012345645678.9 +ddfma2084 fma 0.1 1230123456456789 0e+384 -> 123012345645678.9 +ddfma2090 fma 1230123456456789 0.1 0e+384 -> 123012345645678.9 +ddfma2094 fma 1230123456456789 0.1 0e+384 -> 123012345645678.9 + +-- test some more edge cases and carries +ddfma2101 fma 9 9 0e+384 -> 81 +ddfma2102 fma 9 90 0e+384 -> 810 +ddfma2103 fma 9 900 0e+384 -> 8100 +ddfma2104 fma 9 9000 0e+384 -> 81000 +ddfma2105 fma 9 90000 0e+384 -> 810000 +ddfma2106 fma 9 900000 0e+384 -> 8100000 +ddfma2107 fma 9 9000000 0e+384 -> 81000000 +ddfma2108 fma 9 90000000 0e+384 -> 810000000 +ddfma2109 fma 9 900000000 0e+384 -> 8100000000 +ddfma2110 fma 9 9000000000 0e+384 -> 81000000000 +ddfma2111 fma 9 90000000000 0e+384 -> 810000000000 +ddfma2112 fma 9 900000000000 0e+384 -> 8100000000000 +ddfma2113 fma 9 9000000000000 0e+384 -> 81000000000000 +ddfma2114 fma 9 90000000000000 0e+384 -> 810000000000000 +ddfma2115 fma 9 900000000000000 0e+384 -> 8100000000000000 +--ddfma2116 fma 9 9000000000000000 0e+384 -> 81000000000000000 +--ddfma2117 fma 9 90000000000000000 0e+384 -> 810000000000000000 +--ddfma2118 fma 9 900000000000000000 0e+384 -> 8100000000000000000 +--ddfma2119 fma 9 9000000000000000000 0e+384 -> 81000000000000000000 +--ddfma2120 fma 9 90000000000000000000 0e+384 -> 810000000000000000000 +--ddfma2121 fma 9 900000000000000000000 0e+384 -> 8100000000000000000000 +--ddfma2122 fma 9 9000000000000000000000 0e+384 -> 81000000000000000000000 +--ddfma2123 fma 9 90000000000000000000000 0e+384 -> 810000000000000000000000 +-- test some more edge cases without carries +ddfma2131 fma 3 3 0e+384 -> 9 +ddfma2132 fma 3 30 0e+384 -> 90 +ddfma2133 fma 3 300 0e+384 -> 900 +ddfma2134 fma 3 3000 0e+384 -> 9000 +ddfma2135 fma 3 30000 0e+384 -> 90000 +ddfma2136 fma 3 300000 0e+384 -> 900000 +ddfma2137 fma 3 3000000 0e+384 -> 9000000 +ddfma2138 fma 3 30000000 0e+384 -> 90000000 +ddfma2139 fma 3 300000000 0e+384 -> 900000000 +ddfma2140 fma 3 3000000000 0e+384 -> 9000000000 +ddfma2141 fma 3 30000000000 0e+384 -> 90000000000 +ddfma2142 fma 3 300000000000 0e+384 -> 900000000000 +ddfma2143 fma 3 3000000000000 0e+384 -> 9000000000000 +ddfma2144 fma 3 30000000000000 0e+384 -> 90000000000000 +ddfma2145 fma 3 300000000000000 0e+384 -> 900000000000000 + +-- test some edge cases with exact rounding +ddfma2301 fma 9 9 0e+384 -> 81 +ddfma2302 fma 9 90 0e+384 -> 810 +ddfma2303 fma 9 900 0e+384 -> 8100 +ddfma2304 fma 9 9000 0e+384 -> 81000 +ddfma2305 fma 9 90000 0e+384 -> 810000 +ddfma2306 fma 9 900000 0e+384 -> 8100000 +ddfma2307 fma 9 9000000 0e+384 -> 81000000 +ddfma2308 fma 9 90000000 0e+384 -> 810000000 +ddfma2309 fma 9 900000000 0e+384 -> 8100000000 +ddfma2310 fma 9 9000000000 0e+384 -> 81000000000 +ddfma2311 fma 9 90000000000 0e+384 -> 810000000000 +ddfma2312 fma 9 900000000000 0e+384 -> 8100000000000 +ddfma2313 fma 9 9000000000000 0e+384 -> 81000000000000 +ddfma2314 fma 9 90000000000000 0e+384 -> 810000000000000 +ddfma2315 fma 9 900000000000000 0e+384 -> 8100000000000000 +ddfma2316 fma 9 9000000000000000 0e+384 -> 8.100000000000000E+16 Rounded +ddfma2317 fma 90 9000000000000000 0e+384 -> 8.100000000000000E+17 Rounded +ddfma2318 fma 900 9000000000000000 0e+384 -> 8.100000000000000E+18 Rounded +ddfma2319 fma 9000 9000000000000000 0e+384 -> 8.100000000000000E+19 Rounded +ddfma2320 fma 90000 9000000000000000 0e+384 -> 8.100000000000000E+20 Rounded +ddfma2321 fma 900000 9000000000000000 0e+384 -> 8.100000000000000E+21 Rounded +ddfma2322 fma 9000000 9000000000000000 0e+384 -> 8.100000000000000E+22 Rounded +ddfma2323 fma 90000000 9000000000000000 0e+384 -> 8.100000000000000E+23 Rounded + +-- tryzeros cases +ddfma2504 fma 0E-260 1000E-260 0e+384 -> 0E-398 Clamped +ddfma2505 fma 100E+260 0E+260 0e+384 -> 0E+369 Clamped + +-- mixed with zeros +ddfma2541 fma 0 -1 0e+384 -> 0 +ddfma2542 fma -0 -1 0e+384 -> 0 +ddfma2543 fma 0 1 0e+384 -> 0 +ddfma2544 fma -0 1 0e+384 -> 0 +ddfma2545 fma -1 0 0e+384 -> 0 +ddfma2546 fma -1 -0 0e+384 -> 0 +ddfma2547 fma 1 0 0e+384 -> 0 +ddfma2548 fma 1 -0 0e+384 -> 0 + +ddfma2551 fma 0.0 -1 0e+384 -> 0.0 +ddfma2552 fma -0.0 -1 0e+384 -> 0.0 +ddfma2553 fma 0.0 1 0e+384 -> 0.0 +ddfma2554 fma -0.0 1 0e+384 -> 0.0 +ddfma2555 fma -1.0 0 0e+384 -> 0.0 +ddfma2556 fma -1.0 -0 0e+384 -> 0.0 +ddfma2557 fma 1.0 0 0e+384 -> 0.0 +ddfma2558 fma 1.0 -0 0e+384 -> 0.0 + +ddfma2561 fma 0 -1.0 0e+384 -> 0.0 +ddfma2562 fma -0 -1.0 0e+384 -> 0.0 +ddfma2563 fma 0 1.0 0e+384 -> 0.0 +ddfma2564 fma -0 1.0 0e+384 -> 0.0 +ddfma2565 fma -1 0.0 0e+384 -> 0.0 +ddfma2566 fma -1 -0.0 0e+384 -> 0.0 +ddfma2567 fma 1 0.0 0e+384 -> 0.0 +ddfma2568 fma 1 -0.0 0e+384 -> 0.0 + +ddfma2571 fma 0.0 -1.0 0e+384 -> 0.00 +ddfma2572 fma -0.0 -1.0 0e+384 -> 0.00 +ddfma2573 fma 0.0 1.0 0e+384 -> 0.00 +ddfma2574 fma -0.0 1.0 0e+384 -> 0.00 +ddfma2575 fma -1.0 0.0 0e+384 -> 0.00 +ddfma2576 fma -1.0 -0.0 0e+384 -> 0.00 +ddfma2577 fma 1.0 0.0 0e+384 -> 0.00 +ddfma2578 fma 1.0 -0.0 0e+384 -> 0.00 + +-- Specials +ddfma2580 fma Inf -Inf 0e+384 -> -Infinity +ddfma2581 fma Inf -1000 0e+384 -> -Infinity +ddfma2582 fma Inf -1 0e+384 -> -Infinity +ddfma2583 fma Inf -0 0e+384 -> NaN Invalid_operation +ddfma2584 fma Inf 0 0e+384 -> NaN Invalid_operation +ddfma2585 fma Inf 1 0e+384 -> Infinity +ddfma2586 fma Inf 1000 0e+384 -> Infinity +ddfma2587 fma Inf Inf 0e+384 -> Infinity +ddfma2588 fma -1000 Inf 0e+384 -> -Infinity +ddfma2589 fma -Inf Inf 0e+384 -> -Infinity +ddfma2590 fma -1 Inf 0e+384 -> -Infinity +ddfma2591 fma -0 Inf 0e+384 -> NaN Invalid_operation +ddfma2592 fma 0 Inf 0e+384 -> NaN Invalid_operation +ddfma2593 fma 1 Inf 0e+384 -> Infinity +ddfma2594 fma 1000 Inf 0e+384 -> Infinity +ddfma2595 fma Inf Inf 0e+384 -> Infinity + +ddfma2600 fma -Inf -Inf 0e+384 -> Infinity +ddfma2601 fma -Inf -1000 0e+384 -> Infinity +ddfma2602 fma -Inf -1 0e+384 -> Infinity +ddfma2603 fma -Inf -0 0e+384 -> NaN Invalid_operation +ddfma2604 fma -Inf 0 0e+384 -> NaN Invalid_operation +ddfma2605 fma -Inf 1 0e+384 -> -Infinity +ddfma2606 fma -Inf 1000 0e+384 -> -Infinity +ddfma2607 fma -Inf Inf 0e+384 -> -Infinity +ddfma2608 fma -1000 Inf 0e+384 -> -Infinity +ddfma2609 fma -Inf -Inf 0e+384 -> Infinity +ddfma2610 fma -1 -Inf 0e+384 -> Infinity +ddfma2611 fma -0 -Inf 0e+384 -> NaN Invalid_operation +ddfma2612 fma 0 -Inf 0e+384 -> NaN Invalid_operation +ddfma2613 fma 1 -Inf 0e+384 -> -Infinity +ddfma2614 fma 1000 -Inf 0e+384 -> -Infinity +ddfma2615 fma Inf -Inf 0e+384 -> -Infinity + +ddfma2621 fma NaN -Inf 0e+384 -> NaN +ddfma2622 fma NaN -1000 0e+384 -> NaN +ddfma2623 fma NaN -1 0e+384 -> NaN +ddfma2624 fma NaN -0 0e+384 -> NaN +ddfma2625 fma NaN 0 0e+384 -> NaN +ddfma2626 fma NaN 1 0e+384 -> NaN +ddfma2627 fma NaN 1000 0e+384 -> NaN +ddfma2628 fma NaN Inf 0e+384 -> NaN +ddfma2629 fma NaN NaN 0e+384 -> NaN +ddfma2630 fma -Inf NaN 0e+384 -> NaN +ddfma2631 fma -1000 NaN 0e+384 -> NaN +ddfma2632 fma -1 NaN 0e+384 -> NaN +ddfma2633 fma -0 NaN 0e+384 -> NaN +ddfma2634 fma 0 NaN 0e+384 -> NaN +ddfma2635 fma 1 NaN 0e+384 -> NaN +ddfma2636 fma 1000 NaN 0e+384 -> NaN +ddfma2637 fma Inf NaN 0e+384 -> NaN + +ddfma2641 fma sNaN -Inf 0e+384 -> NaN Invalid_operation +ddfma2642 fma sNaN -1000 0e+384 -> NaN Invalid_operation +ddfma2643 fma sNaN -1 0e+384 -> NaN Invalid_operation +ddfma2644 fma sNaN -0 0e+384 -> NaN Invalid_operation +ddfma2645 fma sNaN 0 0e+384 -> NaN Invalid_operation +ddfma2646 fma sNaN 1 0e+384 -> NaN Invalid_operation +ddfma2647 fma sNaN 1000 0e+384 -> NaN Invalid_operation +ddfma2648 fma sNaN NaN 0e+384 -> NaN Invalid_operation +ddfma2649 fma sNaN sNaN 0e+384 -> NaN Invalid_operation +ddfma2650 fma NaN sNaN 0e+384 -> NaN Invalid_operation +ddfma2651 fma -Inf sNaN 0e+384 -> NaN Invalid_operation +ddfma2652 fma -1000 sNaN 0e+384 -> NaN Invalid_operation +ddfma2653 fma -1 sNaN 0e+384 -> NaN Invalid_operation +ddfma2654 fma -0 sNaN 0e+384 -> NaN Invalid_operation +ddfma2655 fma 0 sNaN 0e+384 -> NaN Invalid_operation +ddfma2656 fma 1 sNaN 0e+384 -> NaN Invalid_operation +ddfma2657 fma 1000 sNaN 0e+384 -> NaN Invalid_operation +ddfma2658 fma Inf sNaN 0e+384 -> NaN Invalid_operation +ddfma2659 fma NaN sNaN 0e+384 -> NaN Invalid_operation + +-- propagating NaNs +ddfma2661 fma NaN9 -Inf 0e+384 -> NaN9 +ddfma2662 fma NaN8 999 0e+384 -> NaN8 +ddfma2663 fma NaN71 Inf 0e+384 -> NaN71 +ddfma2664 fma NaN6 NaN5 0e+384 -> NaN6 +ddfma2665 fma -Inf NaN4 0e+384 -> NaN4 +ddfma2666 fma -999 NaN33 0e+384 -> NaN33 +ddfma2667 fma Inf NaN2 0e+384 -> NaN2 + +ddfma2671 fma sNaN99 -Inf 0e+384 -> NaN99 Invalid_operation +ddfma2672 fma sNaN98 -11 0e+384 -> NaN98 Invalid_operation +ddfma2673 fma sNaN97 NaN 0e+384 -> NaN97 Invalid_operation +ddfma2674 fma sNaN16 sNaN94 0e+384 -> NaN16 Invalid_operation +ddfma2675 fma NaN95 sNaN93 0e+384 -> NaN93 Invalid_operation +ddfma2676 fma -Inf sNaN92 0e+384 -> NaN92 Invalid_operation +ddfma2677 fma 088 sNaN91 0e+384 -> NaN91 Invalid_operation +ddfma2678 fma Inf sNaN90 0e+384 -> NaN90 Invalid_operation +ddfma2679 fma NaN sNaN89 0e+384 -> NaN89 Invalid_operation + +ddfma2681 fma -NaN9 -Inf 0e+384 -> -NaN9 +ddfma2682 fma -NaN8 999 0e+384 -> -NaN8 +ddfma2683 fma -NaN71 Inf 0e+384 -> -NaN71 +ddfma2684 fma -NaN6 -NaN5 0e+384 -> -NaN6 +ddfma2685 fma -Inf -NaN4 0e+384 -> -NaN4 +ddfma2686 fma -999 -NaN33 0e+384 -> -NaN33 +ddfma2687 fma Inf -NaN2 0e+384 -> -NaN2 + +ddfma2691 fma -sNaN99 -Inf 0e+384 -> -NaN99 Invalid_operation +ddfma2692 fma -sNaN98 -11 0e+384 -> -NaN98 Invalid_operation +ddfma2693 fma -sNaN97 NaN 0e+384 -> -NaN97 Invalid_operation +ddfma2694 fma -sNaN16 -sNaN94 0e+384 -> -NaN16 Invalid_operation +ddfma2695 fma -NaN95 -sNaN93 0e+384 -> -NaN93 Invalid_operation +ddfma2696 fma -Inf -sNaN92 0e+384 -> -NaN92 Invalid_operation +ddfma2697 fma 088 -sNaN91 0e+384 -> -NaN91 Invalid_operation +ddfma2698 fma Inf -sNaN90 0e+384 -> -NaN90 Invalid_operation +ddfma2699 fma -NaN -sNaN89 0e+384 -> -NaN89 Invalid_operation + +ddfma2701 fma -NaN -Inf 0e+384 -> -NaN +ddfma2702 fma -NaN 999 0e+384 -> -NaN +ddfma2703 fma -NaN Inf 0e+384 -> -NaN +ddfma2704 fma -NaN -NaN 0e+384 -> -NaN +ddfma2705 fma -Inf -NaN0 0e+384 -> -NaN +ddfma2706 fma -999 -NaN 0e+384 -> -NaN +ddfma2707 fma Inf -NaN 0e+384 -> -NaN + +ddfma2711 fma -sNaN -Inf 0e+384 -> -NaN Invalid_operation +ddfma2712 fma -sNaN -11 0e+384 -> -NaN Invalid_operation +ddfma2713 fma -sNaN00 NaN 0e+384 -> -NaN Invalid_operation +ddfma2714 fma -sNaN -sNaN 0e+384 -> -NaN Invalid_operation +ddfma2715 fma -NaN -sNaN 0e+384 -> -NaN Invalid_operation +ddfma2716 fma -Inf -sNaN 0e+384 -> -NaN Invalid_operation +ddfma2717 fma 088 -sNaN 0e+384 -> -NaN Invalid_operation +ddfma2718 fma Inf -sNaN 0e+384 -> -NaN Invalid_operation +ddfma2719 fma -NaN -sNaN 0e+384 -> -NaN Invalid_operation + +-- overflow and underflow tests .. note subnormal results +-- signs +ddfma2751 fma 1e+277 1e+311 0e+384 -> Infinity Overflow Inexact Rounded +ddfma2752 fma 1e+277 -1e+311 0e+384 -> -Infinity Overflow Inexact Rounded +ddfma2753 fma -1e+277 1e+311 0e+384 -> -Infinity Overflow Inexact Rounded +ddfma2754 fma -1e+277 -1e+311 0e+384 -> Infinity Overflow Inexact Rounded +ddfma2755 fma 1e-277 1e-311 0e+384 -> 0E-398 Underflow Subnormal Inexact Rounded Clamped +ddfma2756 fma 1e-277 -1e-311 0e+384 -> -0E-398 Underflow Subnormal Inexact Rounded Clamped +ddfma2757 fma -1e-277 1e-311 0e+384 -> -0E-398 Underflow Subnormal Inexact Rounded Clamped +ddfma2758 fma -1e-277 -1e-311 0e+384 -> 0E-398 Underflow Subnormal Inexact Rounded Clamped + +-- 'subnormal' boundary (all hard underflow or overflow in base arithemtic) +ddfma2760 fma 1e-291 1e-101 0e+384 -> 1E-392 Subnormal +ddfma2761 fma 1e-291 1e-102 0e+384 -> 1E-393 Subnormal +ddfma2762 fma 1e-291 1e-103 0e+384 -> 1E-394 Subnormal +ddfma2763 fma 1e-291 1e-104 0e+384 -> 1E-395 Subnormal +ddfma2764 fma 1e-291 1e-105 0e+384 -> 1E-396 Subnormal +ddfma2765 fma 1e-291 1e-106 0e+384 -> 1E-397 Subnormal +ddfma2766 fma 1e-291 1e-107 0e+384 -> 1E-398 Subnormal +ddfma2767 fma 1e-291 1e-108 0e+384 -> 0E-398 Underflow Subnormal Inexact Rounded Clamped +ddfma2768 fma 1e-291 1e-109 0e+384 -> 0E-398 Underflow Subnormal Inexact Rounded Clamped +ddfma2769 fma 1e-291 1e-110 0e+384 -> 0E-398 Underflow Subnormal Inexact Rounded Clamped +-- [no equivalent of 'subnormal' for overflow] +ddfma2770 fma 1e+60 1e+321 0e+384 -> 1.000000000000E+381 Clamped +ddfma2771 fma 1e+60 1e+322 0e+384 -> 1.0000000000000E+382 Clamped +ddfma2772 fma 1e+60 1e+323 0e+384 -> 1.00000000000000E+383 Clamped +ddfma2773 fma 1e+60 1e+324 0e+384 -> 1.000000000000000E+384 Clamped +ddfma2774 fma 1e+60 1e+325 0e+384 -> Infinity Overflow Inexact Rounded +ddfma2775 fma 1e+60 1e+326 0e+384 -> Infinity Overflow Inexact Rounded +ddfma2776 fma 1e+60 1e+327 0e+384 -> Infinity Overflow Inexact Rounded +ddfma2777 fma 1e+60 1e+328 0e+384 -> Infinity Overflow Inexact Rounded +ddfma2778 fma 1e+60 1e+329 0e+384 -> Infinity Overflow Inexact Rounded +ddfma2779 fma 1e+60 1e+330 0e+384 -> Infinity Overflow Inexact Rounded + +ddfma2801 fma 1.0000E-394 1 0e+384 -> 1.0000E-394 Subnormal +ddfma2802 fma 1.000E-394 1e-1 0e+384 -> 1.000E-395 Subnormal +ddfma2803 fma 1.00E-394 1e-2 0e+384 -> 1.00E-396 Subnormal +ddfma2804 fma 1.0E-394 1e-3 0e+384 -> 1.0E-397 Subnormal +ddfma2805 fma 1.0E-394 1e-4 0e+384 -> 1E-398 Subnormal Rounded +ddfma2806 fma 1.3E-394 1e-4 0e+384 -> 1E-398 Underflow Subnormal Inexact Rounded +ddfma2807 fma 1.5E-394 1e-4 0e+384 -> 2E-398 Underflow Subnormal Inexact Rounded +ddfma2808 fma 1.7E-394 1e-4 0e+384 -> 2E-398 Underflow Subnormal Inexact Rounded +ddfma2809 fma 2.3E-394 1e-4 0e+384 -> 2E-398 Underflow Subnormal Inexact Rounded +ddfma2810 fma 2.5E-394 1e-4 0e+384 -> 2E-398 Underflow Subnormal Inexact Rounded +ddfma2811 fma 2.7E-394 1e-4 0e+384 -> 3E-398 Underflow Subnormal Inexact Rounded +ddfma2812 fma 1.49E-394 1e-4 0e+384 -> 1E-398 Underflow Subnormal Inexact Rounded +ddfma2813 fma 1.50E-394 1e-4 0e+384 -> 2E-398 Underflow Subnormal Inexact Rounded +ddfma2814 fma 1.51E-394 1e-4 0e+384 -> 2E-398 Underflow Subnormal Inexact Rounded +ddfma2815 fma 2.49E-394 1e-4 0e+384 -> 2E-398 Underflow Subnormal Inexact Rounded +ddfma2816 fma 2.50E-394 1e-4 0e+384 -> 2E-398 Underflow Subnormal Inexact Rounded +ddfma2817 fma 2.51E-394 1e-4 0e+384 -> 3E-398 Underflow Subnormal Inexact Rounded + +ddfma2818 fma 1E-394 1e-4 0e+384 -> 1E-398 Subnormal +ddfma2819 fma 3E-394 1e-5 0e+384 -> 0E-398 Underflow Subnormal Inexact Rounded Clamped +ddfma2820 fma 5E-394 1e-5 0e+384 -> 0E-398 Underflow Subnormal Inexact Rounded Clamped +ddfma2821 fma 7E-394 1e-5 0e+384 -> 1E-398 Underflow Subnormal Inexact Rounded +ddfma2822 fma 9E-394 1e-5 0e+384 -> 1E-398 Underflow Subnormal Inexact Rounded +ddfma2823 fma 9.9E-394 1e-5 0e+384 -> 1E-398 Underflow Subnormal Inexact Rounded + +ddfma2824 fma 1E-394 -1e-4 0e+384 -> -1E-398 Subnormal +ddfma2825 fma 3E-394 -1e-5 0e+384 -> -0E-398 Underflow Subnormal Inexact Rounded Clamped +ddfma2826 fma -5E-394 1e-5 0e+384 -> -0E-398 Underflow Subnormal Inexact Rounded Clamped +ddfma2827 fma 7E-394 -1e-5 0e+384 -> -1E-398 Underflow Subnormal Inexact Rounded +ddfma2828 fma -9E-394 1e-5 0e+384 -> -1E-398 Underflow Subnormal Inexact Rounded +ddfma2829 fma 9.9E-394 -1e-5 0e+384 -> -1E-398 Underflow Subnormal Inexact Rounded +ddfma2830 fma 3.0E-394 -1e-5 0e+384 -> -0E-398 Underflow Subnormal Inexact Rounded Clamped + +ddfma2831 fma 1.0E-199 1e-200 0e+384 -> 0E-398 Underflow Subnormal Inexact Rounded Clamped +ddfma2832 fma 1.0E-199 1e-199 0e+384 -> 1E-398 Subnormal Rounded +ddfma2833 fma 1.0E-199 1e-198 0e+384 -> 1.0E-397 Subnormal +ddfma2834 fma 2.0E-199 2e-198 0e+384 -> 4.0E-397 Subnormal +ddfma2835 fma 4.0E-199 4e-198 0e+384 -> 1.60E-396 Subnormal +ddfma2836 fma 10.0E-199 10e-198 0e+384 -> 1.000E-395 Subnormal +ddfma2837 fma 30.0E-199 30e-198 0e+384 -> 9.000E-395 Subnormal +ddfma2838 fma 40.0E-199 40e-188 0e+384 -> 1.6000E-384 Subnormal +ddfma2839 fma 40.0E-199 40e-187 0e+384 -> 1.6000E-383 +ddfma2840 fma 40.0E-199 40e-186 0e+384 -> 1.6000E-382 + +-- Long operand overflow may be a different path +ddfma2870 fma 100 9.999E+383 0e+384 -> Infinity Inexact Overflow Rounded +ddfma2871 fma 100 -9.999E+383 0e+384 -> -Infinity Inexact Overflow Rounded +ddfma2872 fma 9.999E+383 100 0e+384 -> Infinity Inexact Overflow Rounded +ddfma2873 fma -9.999E+383 100 0e+384 -> -Infinity Inexact Overflow Rounded + +-- check for double-rounded subnormals +ddfma2881 fma 1.2347E-355 1.2347E-40 0e+384 -> 1.524E-395 Inexact Rounded Subnormal Underflow +ddfma2882 fma 1.234E-355 1.234E-40 0e+384 -> 1.523E-395 Inexact Rounded Subnormal Underflow +ddfma2883 fma 1.23E-355 1.23E-40 0e+384 -> 1.513E-395 Inexact Rounded Subnormal Underflow +ddfma2884 fma 1.2E-355 1.2E-40 0e+384 -> 1.44E-395 Subnormal +ddfma2885 fma 1.2E-355 1.2E-41 0e+384 -> 1.44E-396 Subnormal +ddfma2886 fma 1.2E-355 1.2E-42 0e+384 -> 1.4E-397 Subnormal Inexact Rounded Underflow +ddfma2887 fma 1.2E-355 1.3E-42 0e+384 -> 1.6E-397 Subnormal Inexact Rounded Underflow +ddfma2888 fma 1.3E-355 1.3E-42 0e+384 -> 1.7E-397 Subnormal Inexact Rounded Underflow +ddfma2889 fma 1.3E-355 1.3E-43 0e+384 -> 2E-398 Subnormal Inexact Rounded Underflow +ddfma2890 fma 1.3E-356 1.3E-43 0e+384 -> 0E-398 Clamped Subnormal Inexact Rounded Underflow + +ddfma2891 fma 1.2345E-39 1.234E-355 0e+384 -> 1.5234E-394 Inexact Rounded Subnormal Underflow +ddfma2892 fma 1.23456E-39 1.234E-355 0e+384 -> 1.5234E-394 Inexact Rounded Subnormal Underflow +ddfma2893 fma 1.2345E-40 1.234E-355 0e+384 -> 1.523E-395 Inexact Rounded Subnormal Underflow +ddfma2894 fma 1.23456E-40 1.234E-355 0e+384 -> 1.523E-395 Inexact Rounded Subnormal Underflow +ddfma2895 fma 1.2345E-41 1.234E-355 0e+384 -> 1.52E-396 Inexact Rounded Subnormal Underflow +ddfma2896 fma 1.23456E-41 1.234E-355 0e+384 -> 1.52E-396 Inexact Rounded Subnormal Underflow + +-- Now explore the case where we get a normal result with Underflow +ddfma2900 fma 0.3000000000E-191 0.3000000000E-191 0e+384 -> 9.00000000000000E-384 Subnormal Rounded +ddfma2901 fma 0.3000000001E-191 0.3000000001E-191 0e+384 -> 9.00000000600000E-384 Underflow Inexact Subnormal Rounded +ddfma2902 fma 9.999999999999999E-383 0.0999999999999 0e+384 -> 9.99999999999000E-384 Underflow Inexact Subnormal Rounded +ddfma2903 fma 9.999999999999999E-383 0.09999999999999 0e+384 -> 9.99999999999900E-384 Underflow Inexact Subnormal Rounded +ddfma2904 fma 9.999999999999999E-383 0.099999999999999 0e+384 -> 9.99999999999990E-384 Underflow Inexact Subnormal Rounded +ddfma2905 fma 9.999999999999999E-383 0.0999999999999999 0e+384 -> 9.99999999999999E-384 Underflow Inexact Subnormal Rounded +-- prove operands are exact +ddfma2906 fma 9.999999999999999E-383 1 0e+384 -> 9.999999999999999E-383 +ddfma2907 fma 1 0.09999999999999999 0e+384 -> 0.09999999999999999 +-- the next rounds to Nmin +ddfma2908 fma 9.999999999999999E-383 0.09999999999999999 0e+384 -> 1.000000000000000E-383 Underflow Inexact Subnormal Rounded + +-- hugest +ddfma2909 fma 9999999999999999 9999999999999999 0e+384 -> 9.999999999999998E+31 Inexact Rounded + +-- Null tests +ddfma2990 fma 10 # 0e+384 -> NaN Invalid_operation +ddfma2991 fma # 10 0e+384 -> NaN Invalid_operation + + +-- ADDITION TESTS ------------------------------------------------------ + +-- [first group are 'quick confidence check'] +ddfma3001 fma 1 1 1 -> 2 +ddfma3002 fma 1 2 3 -> 5 +ddfma3003 fma 1 '5.75' '3.3' -> 9.05 +ddfma3004 fma 1 '5' '-3' -> 2 +ddfma3005 fma 1 '-5' '-3' -> -8 +ddfma3006 fma 1 '-7' '2.5' -> -4.5 +ddfma3007 fma 1 '0.7' '0.3' -> 1.0 +ddfma3008 fma 1 '1.25' '1.25' -> 2.50 +ddfma3009 fma 1 '1.23456789' '1.00000000' -> '2.23456789' +ddfma3010 fma 1 '1.23456789' '1.00000011' -> '2.23456800' + +-- 1234567890123456 1234567890123456 +ddfma3011 fma 1 '0.4444444444444446' '0.5555555555555555' -> '1.000000000000000' Inexact Rounded +ddfma3012 fma 1 '0.4444444444444445' '0.5555555555555555' -> '1.000000000000000' Rounded +ddfma3013 fma 1 '0.4444444444444444' '0.5555555555555555' -> '0.9999999999999999' +ddfma3014 fma 1 '4444444444444444' '0.49' -> '4444444444444444' Inexact Rounded +ddfma3015 fma 1 '4444444444444444' '0.499' -> '4444444444444444' Inexact Rounded +ddfma3016 fma 1 '4444444444444444' '0.4999' -> '4444444444444444' Inexact Rounded +ddfma3017 fma 1 '4444444444444444' '0.5000' -> '4444444444444444' Inexact Rounded +ddfma3018 fma 1 '4444444444444444' '0.5001' -> '4444444444444445' Inexact Rounded +ddfma3019 fma 1 '4444444444444444' '0.501' -> '4444444444444445' Inexact Rounded +ddfma3020 fma 1 '4444444444444444' '0.51' -> '4444444444444445' Inexact Rounded + +ddfma3021 fma 1 0 1 -> 1 +ddfma3022 fma 1 1 1 -> 2 +ddfma3023 fma 1 2 1 -> 3 +ddfma3024 fma 1 3 1 -> 4 +ddfma3025 fma 1 4 1 -> 5 +ddfma3026 fma 1 5 1 -> 6 +ddfma3027 fma 1 6 1 -> 7 +ddfma3028 fma 1 7 1 -> 8 +ddfma3029 fma 1 8 1 -> 9 +ddfma3030 fma 1 9 1 -> 10 + +-- some carrying effects +ddfma3031 fma 1 '0.9998' '0.0000' -> '0.9998' +ddfma3032 fma 1 '0.9998' '0.0001' -> '0.9999' +ddfma3033 fma 1 '0.9998' '0.0002' -> '1.0000' +ddfma3034 fma 1 '0.9998' '0.0003' -> '1.0001' + +ddfma3035 fma 1 '70' '10000e+16' -> '1.000000000000000E+20' Inexact Rounded +ddfma3036 fma 1 '700' '10000e+16' -> '1.000000000000000E+20' Inexact Rounded +ddfma3037 fma 1 '7000' '10000e+16' -> '1.000000000000000E+20' Inexact Rounded +ddfma3038 fma 1 '70000' '10000e+16' -> '1.000000000000001E+20' Inexact Rounded +ddfma3039 fma 1 '700000' '10000e+16' -> '1.000000000000007E+20' Rounded + +-- symmetry: +ddfma3040 fma 1 '10000e+16' '70' -> '1.000000000000000E+20' Inexact Rounded +ddfma3041 fma 1 '10000e+16' '700' -> '1.000000000000000E+20' Inexact Rounded +ddfma3042 fma 1 '10000e+16' '7000' -> '1.000000000000000E+20' Inexact Rounded +ddfma3044 fma 1 '10000e+16' '70000' -> '1.000000000000001E+20' Inexact Rounded +ddfma3045 fma 1 '10000e+16' '700000' -> '1.000000000000007E+20' Rounded + +-- same, without rounding +ddfma3046 fma 1 '10000e+9' '7' -> '10000000000007' +ddfma3047 fma 1 '10000e+9' '70' -> '10000000000070' +ddfma3048 fma 1 '10000e+9' '700' -> '10000000000700' +ddfma3049 fma 1 '10000e+9' '7000' -> '10000000007000' +ddfma3050 fma 1 '10000e+9' '70000' -> '10000000070000' +ddfma3051 fma 1 '10000e+9' '700000' -> '10000000700000' +ddfma3052 fma 1 '10000e+9' '7000000' -> '10000007000000' + +-- examples from decarith +ddfma3053 fma 1 '12' '7.00' -> '19.00' +ddfma3054 fma 1 '1.3' '-1.07' -> '0.23' +ddfma3055 fma 1 '1.3' '-1.30' -> '0.00' +ddfma3056 fma 1 '1.3' '-2.07' -> '-0.77' +ddfma3057 fma 1 '1E+2' '1E+4' -> '1.01E+4' + +-- leading zero preservation +ddfma3061 fma 1 1 '0.0001' -> '1.0001' +ddfma3062 fma 1 1 '0.00001' -> '1.00001' +ddfma3063 fma 1 1 '0.000001' -> '1.000001' +ddfma3064 fma 1 1 '0.0000001' -> '1.0000001' +ddfma3065 fma 1 1 '0.00000001' -> '1.00000001' + +-- some funny zeros [in case of bad signum] +ddfma3070 fma 1 1 0 -> 1 +ddfma3071 fma 1 1 0. -> 1 +ddfma3072 fma 1 1 .0 -> 1.0 +ddfma3073 fma 1 1 0.0 -> 1.0 +ddfma3074 fma 1 1 0.00 -> 1.00 +ddfma3075 fma 1 0 1 -> 1 +ddfma3076 fma 1 0. 1 -> 1 +ddfma3077 fma 1 .0 1 -> 1.0 +ddfma3078 fma 1 0.0 1 -> 1.0 +ddfma3079 fma 1 0.00 1 -> 1.00 + +-- some carries +ddfma3080 fma 1 999999998 1 -> 999999999 +ddfma3081 fma 1 999999999 1 -> 1000000000 +ddfma3082 fma 1 99999999 1 -> 100000000 +ddfma3083 fma 1 9999999 1 -> 10000000 +ddfma3084 fma 1 999999 1 -> 1000000 +ddfma3085 fma 1 99999 1 -> 100000 +ddfma3086 fma 1 9999 1 -> 10000 +ddfma3087 fma 1 999 1 -> 1000 +ddfma3088 fma 1 99 1 -> 100 +ddfma3089 fma 1 9 1 -> 10 + + +-- more LHS swaps +ddfma3090 fma 1 '-56267E-10' 0 -> '-0.0000056267' +ddfma3091 fma 1 '-56267E-6' 0 -> '-0.056267' +ddfma3092 fma 1 '-56267E-5' 0 -> '-0.56267' +ddfma3093 fma 1 '-56267E-4' 0 -> '-5.6267' +ddfma3094 fma 1 '-56267E-3' 0 -> '-56.267' +ddfma3095 fma 1 '-56267E-2' 0 -> '-562.67' +ddfma3096 fma 1 '-56267E-1' 0 -> '-5626.7' +ddfma3097 fma 1 '-56267E-0' 0 -> '-56267' +ddfma3098 fma 1 '-5E-10' 0 -> '-5E-10' +ddfma3099 fma 1 '-5E-7' 0 -> '-5E-7' +ddfma3100 fma 1 '-5E-6' 0 -> '-0.000005' +ddfma3101 fma 1 '-5E-5' 0 -> '-0.00005' +ddfma3102 fma 1 '-5E-4' 0 -> '-0.0005' +ddfma3103 fma 1 '-5E-1' 0 -> '-0.5' +ddfma3104 fma 1 '-5E0' 0 -> '-5' +ddfma3105 fma 1 '-5E1' 0 -> '-50' +ddfma3106 fma 1 '-5E5' 0 -> '-500000' +ddfma3107 fma 1 '-5E15' 0 -> '-5000000000000000' +ddfma3108 fma 1 '-5E16' 0 -> '-5.000000000000000E+16' Rounded +ddfma3109 fma 1 '-5E17' 0 -> '-5.000000000000000E+17' Rounded +ddfma3110 fma 1 '-5E18' 0 -> '-5.000000000000000E+18' Rounded +ddfma3111 fma 1 '-5E100' 0 -> '-5.000000000000000E+100' Rounded + +-- more RHS swaps +ddfma3113 fma 1 0 '-56267E-10' -> '-0.0000056267' +ddfma3114 fma 1 0 '-56267E-6' -> '-0.056267' +ddfma3116 fma 1 0 '-56267E-5' -> '-0.56267' +ddfma3117 fma 1 0 '-56267E-4' -> '-5.6267' +ddfma3119 fma 1 0 '-56267E-3' -> '-56.267' +ddfma3120 fma 1 0 '-56267E-2' -> '-562.67' +ddfma3121 fma 1 0 '-56267E-1' -> '-5626.7' +ddfma3122 fma 1 0 '-56267E-0' -> '-56267' +ddfma3123 fma 1 0 '-5E-10' -> '-5E-10' +ddfma3124 fma 1 0 '-5E-7' -> '-5E-7' +ddfma3125 fma 1 0 '-5E-6' -> '-0.000005' +ddfma3126 fma 1 0 '-5E-5' -> '-0.00005' +ddfma3127 fma 1 0 '-5E-4' -> '-0.0005' +ddfma3128 fma 1 0 '-5E-1' -> '-0.5' +ddfma3129 fma 1 0 '-5E0' -> '-5' +ddfma3130 fma 1 0 '-5E1' -> '-50' +ddfma3131 fma 1 0 '-5E5' -> '-500000' +ddfma3132 fma 1 0 '-5E15' -> '-5000000000000000' +ddfma3133 fma 1 0 '-5E16' -> '-5.000000000000000E+16' Rounded +ddfma3134 fma 1 0 '-5E17' -> '-5.000000000000000E+17' Rounded +ddfma3135 fma 1 0 '-5E18' -> '-5.000000000000000E+18' Rounded +ddfma3136 fma 1 0 '-5E100' -> '-5.000000000000000E+100' Rounded + +-- related +ddfma3137 fma 1 1 '0E-19' -> '1.000000000000000' Rounded +ddfma3138 fma 1 -1 '0E-19' -> '-1.000000000000000' Rounded +ddfma3139 fma 1 '0E-19' 1 -> '1.000000000000000' Rounded +ddfma3140 fma 1 '0E-19' -1 -> '-1.000000000000000' Rounded +ddfma3141 fma 1 1E+11 0.0000 -> '100000000000.0000' +ddfma3142 fma 1 1E+11 0.00000 -> '100000000000.0000' Rounded +ddfma3143 fma 1 0.000 1E+12 -> '1000000000000.000' +ddfma3144 fma 1 0.0000 1E+12 -> '1000000000000.000' Rounded + +-- [some of the next group are really constructor tests] +ddfma3146 fma 1 '00.0' 0 -> '0.0' +ddfma3147 fma 1 '0.00' 0 -> '0.00' +ddfma3148 fma 1 0 '0.00' -> '0.00' +ddfma3149 fma 1 0 '00.0' -> '0.0' +ddfma3150 fma 1 '00.0' '0.00' -> '0.00' +ddfma3151 fma 1 '0.00' '00.0' -> '0.00' +ddfma3152 fma 1 '3' '.3' -> '3.3' +ddfma3153 fma 1 '3.' '.3' -> '3.3' +ddfma3154 fma 1 '3.0' '.3' -> '3.3' +ddfma3155 fma 1 '3.00' '.3' -> '3.30' +ddfma3156 fma 1 '3' '3' -> '6' +ddfma3157 fma 1 '3' '+3' -> '6' +ddfma3158 fma 1 '3' '-3' -> '0' +ddfma3159 fma 1 '0.3' '-0.3' -> '0.0' +ddfma3160 fma 1 '0.03' '-0.03' -> '0.00' + +-- try borderline precision, with carries, etc. +ddfma3161 fma 1 '1E+12' '-1' -> '999999999999' +ddfma3162 fma 1 '1E+12' '1.11' -> '1000000000001.11' +ddfma3163 fma 1 '1.11' '1E+12' -> '1000000000001.11' +ddfma3164 fma 1 '-1' '1E+12' -> '999999999999' +ddfma3165 fma 1 '7E+12' '-1' -> '6999999999999' +ddfma3166 fma 1 '7E+12' '1.11' -> '7000000000001.11' +ddfma3167 fma 1 '1.11' '7E+12' -> '7000000000001.11' +ddfma3168 fma 1 '-1' '7E+12' -> '6999999999999' + +rounding: half_up +-- 1.234567890123456 1234567890123456 1 234567890123456 +ddfma3170 fma 1 '4.444444444444444' '0.5555555555555567' -> '5.000000000000001' Inexact Rounded +ddfma3171 fma 1 '4.444444444444444' '0.5555555555555566' -> '5.000000000000001' Inexact Rounded +ddfma3172 fma 1 '4.444444444444444' '0.5555555555555565' -> '5.000000000000001' Inexact Rounded +ddfma3173 fma 1 '4.444444444444444' '0.5555555555555564' -> '5.000000000000000' Inexact Rounded +ddfma3174 fma 1 '4.444444444444444' '0.5555555555555553' -> '4.999999999999999' Inexact Rounded +ddfma3175 fma 1 '4.444444444444444' '0.5555555555555552' -> '4.999999999999999' Inexact Rounded +ddfma3176 fma 1 '4.444444444444444' '0.5555555555555551' -> '4.999999999999999' Inexact Rounded +ddfma3177 fma 1 '4.444444444444444' '0.5555555555555550' -> '4.999999999999999' Rounded +ddfma3178 fma 1 '4.444444444444444' '0.5555555555555545' -> '4.999999999999999' Inexact Rounded +ddfma3179 fma 1 '4.444444444444444' '0.5555555555555544' -> '4.999999999999998' Inexact Rounded +ddfma3180 fma 1 '4.444444444444444' '0.5555555555555543' -> '4.999999999999998' Inexact Rounded +ddfma3181 fma 1 '4.444444444444444' '0.5555555555555542' -> '4.999999999999998' Inexact Rounded +ddfma3182 fma 1 '4.444444444444444' '0.5555555555555541' -> '4.999999999999998' Inexact Rounded +ddfma3183 fma 1 '4.444444444444444' '0.5555555555555540' -> '4.999999999999998' Rounded + +-- and some more, including residue effects and different roundings +rounding: half_up +ddfma3200 fma 1 '1234560123456789' 0 -> '1234560123456789' +ddfma3201 fma 1 '1234560123456789' 0.000000001 -> '1234560123456789' Inexact Rounded +ddfma3202 fma 1 '1234560123456789' 0.000001 -> '1234560123456789' Inexact Rounded +ddfma3203 fma 1 '1234560123456789' 0.1 -> '1234560123456789' Inexact Rounded +ddfma3204 fma 1 '1234560123456789' 0.4 -> '1234560123456789' Inexact Rounded +ddfma3205 fma 1 '1234560123456789' 0.49 -> '1234560123456789' Inexact Rounded +ddfma3206 fma 1 '1234560123456789' 0.499999 -> '1234560123456789' Inexact Rounded +ddfma3207 fma 1 '1234560123456789' 0.499999999 -> '1234560123456789' Inexact Rounded +ddfma3208 fma 1 '1234560123456789' 0.5 -> '1234560123456790' Inexact Rounded +ddfma3209 fma 1 '1234560123456789' 0.500000001 -> '1234560123456790' Inexact Rounded +ddfma3210 fma 1 '1234560123456789' 0.500001 -> '1234560123456790' Inexact Rounded +ddfma3211 fma 1 '1234560123456789' 0.51 -> '1234560123456790' Inexact Rounded +ddfma3212 fma 1 '1234560123456789' 0.6 -> '1234560123456790' Inexact Rounded +ddfma3213 fma 1 '1234560123456789' 0.9 -> '1234560123456790' Inexact Rounded +ddfma3214 fma 1 '1234560123456789' 0.99999 -> '1234560123456790' Inexact Rounded +ddfma3215 fma 1 '1234560123456789' 0.999999999 -> '1234560123456790' Inexact Rounded +ddfma3216 fma 1 '1234560123456789' 1 -> '1234560123456790' +ddfma3217 fma 1 '1234560123456789' 1.000000001 -> '1234560123456790' Inexact Rounded +ddfma3218 fma 1 '1234560123456789' 1.00001 -> '1234560123456790' Inexact Rounded +ddfma3219 fma 1 '1234560123456789' 1.1 -> '1234560123456790' Inexact Rounded + +rounding: half_even +ddfma3220 fma 1 '1234560123456789' 0 -> '1234560123456789' +ddfma3221 fma 1 '1234560123456789' 0.000000001 -> '1234560123456789' Inexact Rounded +ddfma3222 fma 1 '1234560123456789' 0.000001 -> '1234560123456789' Inexact Rounded +ddfma3223 fma 1 '1234560123456789' 0.1 -> '1234560123456789' Inexact Rounded +ddfma3224 fma 1 '1234560123456789' 0.4 -> '1234560123456789' Inexact Rounded +ddfma3225 fma 1 '1234560123456789' 0.49 -> '1234560123456789' Inexact Rounded +ddfma3226 fma 1 '1234560123456789' 0.499999 -> '1234560123456789' Inexact Rounded +ddfma3227 fma 1 '1234560123456789' 0.499999999 -> '1234560123456789' Inexact Rounded +ddfma3228 fma 1 '1234560123456789' 0.5 -> '1234560123456790' Inexact Rounded +ddfma3229 fma 1 '1234560123456789' 0.500000001 -> '1234560123456790' Inexact Rounded +ddfma3230 fma 1 '1234560123456789' 0.500001 -> '1234560123456790' Inexact Rounded +ddfma3231 fma 1 '1234560123456789' 0.51 -> '1234560123456790' Inexact Rounded +ddfma3232 fma 1 '1234560123456789' 0.6 -> '1234560123456790' Inexact Rounded +ddfma3233 fma 1 '1234560123456789' 0.9 -> '1234560123456790' Inexact Rounded +ddfma3234 fma 1 '1234560123456789' 0.99999 -> '1234560123456790' Inexact Rounded +ddfma3235 fma 1 '1234560123456789' 0.999999999 -> '1234560123456790' Inexact Rounded +ddfma3236 fma 1 '1234560123456789' 1 -> '1234560123456790' +ddfma3237 fma 1 '1234560123456789' 1.00000001 -> '1234560123456790' Inexact Rounded +ddfma3238 fma 1 '1234560123456789' 1.00001 -> '1234560123456790' Inexact Rounded +ddfma3239 fma 1 '1234560123456789' 1.1 -> '1234560123456790' Inexact Rounded +-- critical few with even bottom digit... +ddfma3240 fma 1 '1234560123456788' 0.499999999 -> '1234560123456788' Inexact Rounded +ddfma3241 fma 1 '1234560123456788' 0.5 -> '1234560123456788' Inexact Rounded +ddfma3242 fma 1 '1234560123456788' 0.500000001 -> '1234560123456789' Inexact Rounded + +rounding: down +ddfma3250 fma 1 '1234560123456789' 0 -> '1234560123456789' +ddfma3251 fma 1 '1234560123456789' 0.000000001 -> '1234560123456789' Inexact Rounded +ddfma3252 fma 1 '1234560123456789' 0.000001 -> '1234560123456789' Inexact Rounded +ddfma3253 fma 1 '1234560123456789' 0.1 -> '1234560123456789' Inexact Rounded +ddfma3254 fma 1 '1234560123456789' 0.4 -> '1234560123456789' Inexact Rounded +ddfma3255 fma 1 '1234560123456789' 0.49 -> '1234560123456789' Inexact Rounded +ddfma3256 fma 1 '1234560123456789' 0.499999 -> '1234560123456789' Inexact Rounded +ddfma3257 fma 1 '1234560123456789' 0.499999999 -> '1234560123456789' Inexact Rounded +ddfma3258 fma 1 '1234560123456789' 0.5 -> '1234560123456789' Inexact Rounded +ddfma3259 fma 1 '1234560123456789' 0.500000001 -> '1234560123456789' Inexact Rounded +ddfma3260 fma 1 '1234560123456789' 0.500001 -> '1234560123456789' Inexact Rounded +ddfma3261 fma 1 '1234560123456789' 0.51 -> '1234560123456789' Inexact Rounded +ddfma3262 fma 1 '1234560123456789' 0.6 -> '1234560123456789' Inexact Rounded +ddfma3263 fma 1 '1234560123456789' 0.9 -> '1234560123456789' Inexact Rounded +ddfma3264 fma 1 '1234560123456789' 0.99999 -> '1234560123456789' Inexact Rounded +ddfma3265 fma 1 '1234560123456789' 0.999999999 -> '1234560123456789' Inexact Rounded +ddfma3266 fma 1 '1234560123456789' 1 -> '1234560123456790' +ddfma3267 fma 1 '1234560123456789' 1.00000001 -> '1234560123456790' Inexact Rounded +ddfma3268 fma 1 '1234560123456789' 1.00001 -> '1234560123456790' Inexact Rounded +ddfma3269 fma 1 '1234560123456789' 1.1 -> '1234560123456790' Inexact Rounded + +-- 1 in last place tests +rounding: half_up +ddfma3301 fma 1 -1 1 -> 0 +ddfma3302 fma 1 0 1 -> 1 +ddfma3303 fma 1 1 1 -> 2 +ddfma3304 fma 1 12 1 -> 13 +ddfma3305 fma 1 98 1 -> 99 +ddfma3306 fma 1 99 1 -> 100 +ddfma3307 fma 1 100 1 -> 101 +ddfma3308 fma 1 101 1 -> 102 +ddfma3309 fma 1 -1 -1 -> -2 +ddfma3310 fma 1 0 -1 -> -1 +ddfma3311 fma 1 1 -1 -> 0 +ddfma3312 fma 1 12 -1 -> 11 +ddfma3313 fma 1 98 -1 -> 97 +ddfma3314 fma 1 99 -1 -> 98 +ddfma3315 fma 1 100 -1 -> 99 +ddfma3316 fma 1 101 -1 -> 100 + +ddfma3321 fma 1 -0.01 0.01 -> 0.00 +ddfma3322 fma 1 0.00 0.01 -> 0.01 +ddfma3323 fma 1 0.01 0.01 -> 0.02 +ddfma3324 fma 1 0.12 0.01 -> 0.13 +ddfma3325 fma 1 0.98 0.01 -> 0.99 +ddfma3326 fma 1 0.99 0.01 -> 1.00 +ddfma3327 fma 1 1.00 0.01 -> 1.01 +ddfma3328 fma 1 1.01 0.01 -> 1.02 +ddfma3329 fma 1 -0.01 -0.01 -> -0.02 +ddfma3330 fma 1 0.00 -0.01 -> -0.01 +ddfma3331 fma 1 0.01 -0.01 -> 0.00 +ddfma3332 fma 1 0.12 -0.01 -> 0.11 +ddfma3333 fma 1 0.98 -0.01 -> 0.97 +ddfma3334 fma 1 0.99 -0.01 -> 0.98 +ddfma3335 fma 1 1.00 -0.01 -> 0.99 +ddfma3336 fma 1 1.01 -0.01 -> 1.00 + +-- some more cases where adding 0 affects the coefficient +ddfma3340 fma 1 1E+3 0 -> 1000 +ddfma3341 fma 1 1E+15 0 -> 1000000000000000 +ddfma3342 fma 1 1E+16 0 -> 1.000000000000000E+16 Rounded +ddfma3343 fma 1 1E+20 0 -> 1.000000000000000E+20 Rounded +-- which simply follow from these cases ... +ddfma3344 fma 1 1E+3 1 -> 1001 +ddfma3345 fma 1 1E+15 1 -> 1000000000000001 +ddfma3346 fma 1 1E+16 1 -> 1.000000000000000E+16 Inexact Rounded +ddfma3347 fma 1 1E+20 1 -> 1.000000000000000E+20 Inexact Rounded +ddfma3348 fma 1 1E+3 7 -> 1007 +ddfma3349 fma 1 1E+15 7 -> 1000000000000007 +ddfma3350 fma 1 1E+16 7 -> 1.000000000000001E+16 Inexact Rounded +ddfma3351 fma 1 1E+20 7 -> 1.000000000000000E+20 Inexact Rounded + +-- tryzeros cases +rounding: half_up +ddfma3360 fma 1 0E+50 10000E+1 -> 1.0000E+5 +ddfma3361 fma 1 0E-50 10000E+1 -> 100000.0000000000 Rounded +ddfma3362 fma 1 10000E+1 0E-50 -> 100000.0000000000 Rounded +ddfma3363 fma 1 10000E+1 10000E-50 -> 100000.0000000000 Rounded Inexact +ddfma3364 fma 1 9.999999999999999E+384 -9.999999999999999E+384 -> 0E+369 + +-- a curiosity from JSR 13 testing +rounding: half_down +ddfma3370 fma 1 999999999999999 815 -> 1000000000000814 +ddfma3371 fma 1 9999999999999999 815 -> 1.000000000000081E+16 Rounded Inexact +rounding: half_up +ddfma3372 fma 1 999999999999999 815 -> 1000000000000814 +ddfma3373 fma 1 9999999999999999 815 -> 1.000000000000081E+16 Rounded Inexact +rounding: half_even +ddfma3374 fma 1 999999999999999 815 -> 1000000000000814 +ddfma3375 fma 1 9999999999999999 815 -> 1.000000000000081E+16 Rounded Inexact + +-- ulp replacement tests +ddfma3400 fma 1 1 77e-14 -> 1.00000000000077 +ddfma3401 fma 1 1 77e-15 -> 1.000000000000077 +ddfma3402 fma 1 1 77e-16 -> 1.000000000000008 Inexact Rounded +ddfma3403 fma 1 1 77e-17 -> 1.000000000000001 Inexact Rounded +ddfma3404 fma 1 1 77e-18 -> 1.000000000000000 Inexact Rounded +ddfma3405 fma 1 1 77e-19 -> 1.000000000000000 Inexact Rounded +ddfma3406 fma 1 1 77e-299 -> 1.000000000000000 Inexact Rounded + +ddfma3410 fma 1 10 77e-14 -> 10.00000000000077 +ddfma3411 fma 1 10 77e-15 -> 10.00000000000008 Inexact Rounded +ddfma3412 fma 1 10 77e-16 -> 10.00000000000001 Inexact Rounded +ddfma3413 fma 1 10 77e-17 -> 10.00000000000000 Inexact Rounded +ddfma3414 fma 1 10 77e-18 -> 10.00000000000000 Inexact Rounded +ddfma3415 fma 1 10 77e-19 -> 10.00000000000000 Inexact Rounded +ddfma3416 fma 1 10 77e-299 -> 10.00000000000000 Inexact Rounded + +ddfma3420 fma 1 77e-14 1 -> 1.00000000000077 +ddfma3421 fma 1 77e-15 1 -> 1.000000000000077 +ddfma3422 fma 1 77e-16 1 -> 1.000000000000008 Inexact Rounded +ddfma3423 fma 1 77e-17 1 -> 1.000000000000001 Inexact Rounded +ddfma3424 fma 1 77e-18 1 -> 1.000000000000000 Inexact Rounded +ddfma3425 fma 1 77e-19 1 -> 1.000000000000000 Inexact Rounded +ddfma3426 fma 1 77e-299 1 -> 1.000000000000000 Inexact Rounded + +ddfma3430 fma 1 77e-14 10 -> 10.00000000000077 +ddfma3431 fma 1 77e-15 10 -> 10.00000000000008 Inexact Rounded +ddfma3432 fma 1 77e-16 10 -> 10.00000000000001 Inexact Rounded +ddfma3433 fma 1 77e-17 10 -> 10.00000000000000 Inexact Rounded +ddfma3434 fma 1 77e-18 10 -> 10.00000000000000 Inexact Rounded +ddfma3435 fma 1 77e-19 10 -> 10.00000000000000 Inexact Rounded +ddfma3436 fma 1 77e-299 10 -> 10.00000000000000 Inexact Rounded + +-- negative ulps +ddfma36440 fma 1 1 -77e-14 -> 0.99999999999923 +ddfma36441 fma 1 1 -77e-15 -> 0.999999999999923 +ddfma36442 fma 1 1 -77e-16 -> 0.9999999999999923 +ddfma36443 fma 1 1 -77e-17 -> 0.9999999999999992 Inexact Rounded +ddfma36444 fma 1 1 -77e-18 -> 0.9999999999999999 Inexact Rounded +ddfma36445 fma 1 1 -77e-19 -> 1.000000000000000 Inexact Rounded +ddfma36446 fma 1 1 -77e-99 -> 1.000000000000000 Inexact Rounded + +ddfma36450 fma 1 10 -77e-14 -> 9.99999999999923 +ddfma36451 fma 1 10 -77e-15 -> 9.999999999999923 +ddfma36452 fma 1 10 -77e-16 -> 9.999999999999992 Inexact Rounded +ddfma36453 fma 1 10 -77e-17 -> 9.999999999999999 Inexact Rounded +ddfma36454 fma 1 10 -77e-18 -> 10.00000000000000 Inexact Rounded +ddfma36455 fma 1 10 -77e-19 -> 10.00000000000000 Inexact Rounded +ddfma36456 fma 1 10 -77e-99 -> 10.00000000000000 Inexact Rounded + +ddfma36460 fma 1 -77e-14 1 -> 0.99999999999923 +ddfma36461 fma 1 -77e-15 1 -> 0.999999999999923 +ddfma36462 fma 1 -77e-16 1 -> 0.9999999999999923 +ddfma36463 fma 1 -77e-17 1 -> 0.9999999999999992 Inexact Rounded +ddfma36464 fma 1 -77e-18 1 -> 0.9999999999999999 Inexact Rounded +ddfma36465 fma 1 -77e-19 1 -> 1.000000000000000 Inexact Rounded +ddfma36466 fma 1 -77e-99 1 -> 1.000000000000000 Inexact Rounded + +ddfma36470 fma 1 -77e-14 10 -> 9.99999999999923 +ddfma36471 fma 1 -77e-15 10 -> 9.999999999999923 +ddfma36472 fma 1 -77e-16 10 -> 9.999999999999992 Inexact Rounded +ddfma36473 fma 1 -77e-17 10 -> 9.999999999999999 Inexact Rounded +ddfma36474 fma 1 -77e-18 10 -> 10.00000000000000 Inexact Rounded +ddfma36475 fma 1 -77e-19 10 -> 10.00000000000000 Inexact Rounded +ddfma36476 fma 1 -77e-99 10 -> 10.00000000000000 Inexact Rounded + +-- negative ulps +ddfma36480 fma 1 -1 77e-14 -> -0.99999999999923 +ddfma36481 fma 1 -1 77e-15 -> -0.999999999999923 +ddfma36482 fma 1 -1 77e-16 -> -0.9999999999999923 +ddfma36483 fma 1 -1 77e-17 -> -0.9999999999999992 Inexact Rounded +ddfma36484 fma 1 -1 77e-18 -> -0.9999999999999999 Inexact Rounded +ddfma36485 fma 1 -1 77e-19 -> -1.000000000000000 Inexact Rounded +ddfma36486 fma 1 -1 77e-99 -> -1.000000000000000 Inexact Rounded + +ddfma36490 fma 1 -10 77e-14 -> -9.99999999999923 +ddfma36491 fma 1 -10 77e-15 -> -9.999999999999923 +ddfma36492 fma 1 -10 77e-16 -> -9.999999999999992 Inexact Rounded +ddfma36493 fma 1 -10 77e-17 -> -9.999999999999999 Inexact Rounded +ddfma36494 fma 1 -10 77e-18 -> -10.00000000000000 Inexact Rounded +ddfma36495 fma 1 -10 77e-19 -> -10.00000000000000 Inexact Rounded +ddfma36496 fma 1 -10 77e-99 -> -10.00000000000000 Inexact Rounded + +ddfma36500 fma 1 77e-14 -1 -> -0.99999999999923 +ddfma36501 fma 1 77e-15 -1 -> -0.999999999999923 +ddfma36502 fma 1 77e-16 -1 -> -0.9999999999999923 +ddfma36503 fma 1 77e-17 -1 -> -0.9999999999999992 Inexact Rounded +ddfma36504 fma 1 77e-18 -1 -> -0.9999999999999999 Inexact Rounded +ddfma36505 fma 1 77e-19 -1 -> -1.000000000000000 Inexact Rounded +ddfma36506 fma 1 77e-99 -1 -> -1.000000000000000 Inexact Rounded + +ddfma36510 fma 1 77e-14 -10 -> -9.99999999999923 +ddfma36511 fma 1 77e-15 -10 -> -9.999999999999923 +ddfma36512 fma 1 77e-16 -10 -> -9.999999999999992 Inexact Rounded +ddfma36513 fma 1 77e-17 -10 -> -9.999999999999999 Inexact Rounded +ddfma36514 fma 1 77e-18 -10 -> -10.00000000000000 Inexact Rounded +ddfma36515 fma 1 77e-19 -10 -> -10.00000000000000 Inexact Rounded +ddfma36516 fma 1 77e-99 -10 -> -10.00000000000000 Inexact Rounded + +-- and a couple more with longer RHS +ddfma36520 fma 1 1 -7777e-16 -> 0.9999999999992223 +ddfma36521 fma 1 1 -7777e-17 -> 0.9999999999999222 Inexact Rounded +ddfma36522 fma 1 1 -7777e-18 -> 0.9999999999999922 Inexact Rounded +ddfma36523 fma 1 1 -7777e-19 -> 0.9999999999999992 Inexact Rounded +ddfma36524 fma 1 1 -7777e-20 -> 0.9999999999999999 Inexact Rounded +ddfma36525 fma 1 1 -7777e-21 -> 1.000000000000000 Inexact Rounded +ddfma36526 fma 1 1 -7777e-22 -> 1.000000000000000 Inexact Rounded + + +-- and some more residue effects and different roundings +rounding: half_up +ddfma36540 fma 1 '6543210123456789' 0 -> '6543210123456789' +ddfma36541 fma 1 '6543210123456789' 0.000000001 -> '6543210123456789' Inexact Rounded +ddfma36542 fma 1 '6543210123456789' 0.000001 -> '6543210123456789' Inexact Rounded +ddfma36543 fma 1 '6543210123456789' 0.1 -> '6543210123456789' Inexact Rounded +ddfma36544 fma 1 '6543210123456789' 0.4 -> '6543210123456789' Inexact Rounded +ddfma36545 fma 1 '6543210123456789' 0.49 -> '6543210123456789' Inexact Rounded +ddfma36546 fma 1 '6543210123456789' 0.499999 -> '6543210123456789' Inexact Rounded +ddfma36547 fma 1 '6543210123456789' 0.499999999 -> '6543210123456789' Inexact Rounded +ddfma36548 fma 1 '6543210123456789' 0.5 -> '6543210123456790' Inexact Rounded +ddfma36549 fma 1 '6543210123456789' 0.500000001 -> '6543210123456790' Inexact Rounded +ddfma36550 fma 1 '6543210123456789' 0.500001 -> '6543210123456790' Inexact Rounded +ddfma36551 fma 1 '6543210123456789' 0.51 -> '6543210123456790' Inexact Rounded +ddfma36552 fma 1 '6543210123456789' 0.6 -> '6543210123456790' Inexact Rounded +ddfma36553 fma 1 '6543210123456789' 0.9 -> '6543210123456790' Inexact Rounded +ddfma36554 fma 1 '6543210123456789' 0.99999 -> '6543210123456790' Inexact Rounded +ddfma36555 fma 1 '6543210123456789' 0.999999999 -> '6543210123456790' Inexact Rounded +ddfma36556 fma 1 '6543210123456789' 1 -> '6543210123456790' +ddfma36557 fma 1 '6543210123456789' 1.000000001 -> '6543210123456790' Inexact Rounded +ddfma36558 fma 1 '6543210123456789' 1.00001 -> '6543210123456790' Inexact Rounded +ddfma36559 fma 1 '6543210123456789' 1.1 -> '6543210123456790' Inexact Rounded + +rounding: half_even +ddfma36560 fma 1 '6543210123456789' 0 -> '6543210123456789' +ddfma36561 fma 1 '6543210123456789' 0.000000001 -> '6543210123456789' Inexact Rounded +ddfma36562 fma 1 '6543210123456789' 0.000001 -> '6543210123456789' Inexact Rounded +ddfma36563 fma 1 '6543210123456789' 0.1 -> '6543210123456789' Inexact Rounded +ddfma36564 fma 1 '6543210123456789' 0.4 -> '6543210123456789' Inexact Rounded +ddfma36565 fma 1 '6543210123456789' 0.49 -> '6543210123456789' Inexact Rounded +ddfma36566 fma 1 '6543210123456789' 0.499999 -> '6543210123456789' Inexact Rounded +ddfma36567 fma 1 '6543210123456789' 0.499999999 -> '6543210123456789' Inexact Rounded +ddfma36568 fma 1 '6543210123456789' 0.5 -> '6543210123456790' Inexact Rounded +ddfma36569 fma 1 '6543210123456789' 0.500000001 -> '6543210123456790' Inexact Rounded +ddfma36570 fma 1 '6543210123456789' 0.500001 -> '6543210123456790' Inexact Rounded +ddfma36571 fma 1 '6543210123456789' 0.51 -> '6543210123456790' Inexact Rounded +ddfma36572 fma 1 '6543210123456789' 0.6 -> '6543210123456790' Inexact Rounded +ddfma36573 fma 1 '6543210123456789' 0.9 -> '6543210123456790' Inexact Rounded +ddfma36574 fma 1 '6543210123456789' 0.99999 -> '6543210123456790' Inexact Rounded +ddfma36575 fma 1 '6543210123456789' 0.999999999 -> '6543210123456790' Inexact Rounded +ddfma36576 fma 1 '6543210123456789' 1 -> '6543210123456790' +ddfma36577 fma 1 '6543210123456789' 1.00000001 -> '6543210123456790' Inexact Rounded +ddfma36578 fma 1 '6543210123456789' 1.00001 -> '6543210123456790' Inexact Rounded +ddfma36579 fma 1 '6543210123456789' 1.1 -> '6543210123456790' Inexact Rounded + +-- critical few with even bottom digit... +ddfma37540 fma 1 '6543210123456788' 0.499999999 -> '6543210123456788' Inexact Rounded +ddfma37541 fma 1 '6543210123456788' 0.5 -> '6543210123456788' Inexact Rounded +ddfma37542 fma 1 '6543210123456788' 0.500000001 -> '6543210123456789' Inexact Rounded + +rounding: down +ddfma37550 fma 1 '6543210123456789' 0 -> '6543210123456789' +ddfma37551 fma 1 '6543210123456789' 0.000000001 -> '6543210123456789' Inexact Rounded +ddfma37552 fma 1 '6543210123456789' 0.000001 -> '6543210123456789' Inexact Rounded +ddfma37553 fma 1 '6543210123456789' 0.1 -> '6543210123456789' Inexact Rounded +ddfma37554 fma 1 '6543210123456789' 0.4 -> '6543210123456789' Inexact Rounded +ddfma37555 fma 1 '6543210123456789' 0.49 -> '6543210123456789' Inexact Rounded +ddfma37556 fma 1 '6543210123456789' 0.499999 -> '6543210123456789' Inexact Rounded +ddfma37557 fma 1 '6543210123456789' 0.499999999 -> '6543210123456789' Inexact Rounded +ddfma37558 fma 1 '6543210123456789' 0.5 -> '6543210123456789' Inexact Rounded +ddfma37559 fma 1 '6543210123456789' 0.500000001 -> '6543210123456789' Inexact Rounded +ddfma37560 fma 1 '6543210123456789' 0.500001 -> '6543210123456789' Inexact Rounded +ddfma37561 fma 1 '6543210123456789' 0.51 -> '6543210123456789' Inexact Rounded +ddfma37562 fma 1 '6543210123456789' 0.6 -> '6543210123456789' Inexact Rounded +ddfma37563 fma 1 '6543210123456789' 0.9 -> '6543210123456789' Inexact Rounded +ddfma37564 fma 1 '6543210123456789' 0.99999 -> '6543210123456789' Inexact Rounded +ddfma37565 fma 1 '6543210123456789' 0.999999999 -> '6543210123456789' Inexact Rounded +ddfma37566 fma 1 '6543210123456789' 1 -> '6543210123456790' +ddfma37567 fma 1 '6543210123456789' 1.00000001 -> '6543210123456790' Inexact Rounded +ddfma37568 fma 1 '6543210123456789' 1.00001 -> '6543210123456790' Inexact Rounded +ddfma37569 fma 1 '6543210123456789' 1.1 -> '6543210123456790' Inexact Rounded + + +-- verify a query +rounding: down +ddfma37661 fma 1 1e-398 9.000000000000000E+384 -> 9.000000000000000E+384 Inexact Rounded +ddfma37662 fma 1 0 9.000000000000000E+384 -> 9.000000000000000E+384 Rounded +ddfma37663 fma 1 1e-388 9.000000000000000E+374 -> 9.000000000000000E+374 Inexact Rounded +ddfma37664 fma 1 0 9.000000000000000E+374 -> 9.000000000000000E+374 Rounded + +-- more zeros, etc. +rounding: half_even + +ddfma37701 fma 1 5.00 1.00E-3 -> 5.00100 +ddfma37702 fma 1 00.00 0.000 -> 0.000 +ddfma37703 fma 1 00.00 0E-3 -> 0.000 +ddfma37704 fma 1 0E-3 00.00 -> 0.000 + +ddfma37710 fma 1 0E+3 00.00 -> 0.00 +ddfma37711 fma 1 0E+3 00.0 -> 0.0 +ddfma37712 fma 1 0E+3 00. -> 0 +ddfma37713 fma 1 0E+3 00.E+1 -> 0E+1 +ddfma37714 fma 1 0E+3 00.E+2 -> 0E+2 +ddfma37715 fma 1 0E+3 00.E+3 -> 0E+3 +ddfma37716 fma 1 0E+3 00.E+4 -> 0E+3 +ddfma37717 fma 1 0E+3 00.E+5 -> 0E+3 +ddfma37718 fma 1 0E+3 -00.0 -> 0.0 +ddfma37719 fma 1 0E+3 -00. -> 0 +ddfma37731 fma 1 0E+3 -00.E+1 -> 0E+1 + +ddfma37720 fma 1 00.00 0E+3 -> 0.00 +ddfma37721 fma 1 00.0 0E+3 -> 0.0 +ddfma37722 fma 1 00. 0E+3 -> 0 +ddfma37723 fma 1 00.E+1 0E+3 -> 0E+1 +ddfma37724 fma 1 00.E+2 0E+3 -> 0E+2 +ddfma37725 fma 1 00.E+3 0E+3 -> 0E+3 +ddfma37726 fma 1 00.E+4 0E+3 -> 0E+3 +ddfma37727 fma 1 00.E+5 0E+3 -> 0E+3 +ddfma37728 fma 1 -00.00 0E+3 -> 0.00 +ddfma37729 fma 1 -00.0 0E+3 -> 0.0 +ddfma37730 fma 1 -00. 0E+3 -> 0 + +ddfma37732 fma 1 0 0 -> 0 +ddfma37733 fma 1 0 -0 -> 0 +ddfma37734 fma 1 -0 0 -> 0 +ddfma37735 fma 1 -0 -0 -> -0 -- IEEE 854 special case + +ddfma37736 fma 1 1 -1 -> 0 +ddfma37737 fma 1 -1 -1 -> -2 +ddfma37738 fma 1 1 1 -> 2 +ddfma37739 fma 1 -1 1 -> 0 + +ddfma37741 fma 1 0 -1 -> -1 +ddfma37742 fma 1 -0 -1 -> -1 +ddfma37743 fma 1 0 1 -> 1 +ddfma37744 fma 1 -0 1 -> 1 +ddfma37745 fma 1 -1 0 -> -1 +ddfma37746 fma 1 -1 -0 -> -1 +ddfma37747 fma 1 1 0 -> 1 +ddfma37748 fma 1 1 -0 -> 1 + +ddfma37751 fma 1 0.0 -1 -> -1.0 +ddfma37752 fma 1 -0.0 -1 -> -1.0 +ddfma37753 fma 1 0.0 1 -> 1.0 +ddfma37754 fma 1 -0.0 1 -> 1.0 +ddfma37755 fma 1 -1.0 0 -> -1.0 +ddfma37756 fma 1 -1.0 -0 -> -1.0 +ddfma37757 fma 1 1.0 0 -> 1.0 +ddfma37758 fma 1 1.0 -0 -> 1.0 + +ddfma37761 fma 1 0 -1.0 -> -1.0 +ddfma37762 fma 1 -0 -1.0 -> -1.0 +ddfma37763 fma 1 0 1.0 -> 1.0 +ddfma37764 fma 1 -0 1.0 -> 1.0 +ddfma37765 fma 1 -1 0.0 -> -1.0 +ddfma37766 fma 1 -1 -0.0 -> -1.0 +ddfma37767 fma 1 1 0.0 -> 1.0 +ddfma37768 fma 1 1 -0.0 -> 1.0 + +ddfma37771 fma 1 0.0 -1.0 -> -1.0 +ddfma37772 fma 1 -0.0 -1.0 -> -1.0 +ddfma37773 fma 1 0.0 1.0 -> 1.0 +ddfma37774 fma 1 -0.0 1.0 -> 1.0 +ddfma37775 fma 1 -1.0 0.0 -> -1.0 +ddfma37776 fma 1 -1.0 -0.0 -> -1.0 +ddfma37777 fma 1 1.0 0.0 -> 1.0 +ddfma37778 fma 1 1.0 -0.0 -> 1.0 + +-- Specials +ddfma37780 fma 1 -Inf -Inf -> -Infinity +ddfma37781 fma 1 -Inf -1000 -> -Infinity +ddfma37782 fma 1 -Inf -1 -> -Infinity +ddfma37783 fma 1 -Inf -0 -> -Infinity +ddfma37784 fma 1 -Inf 0 -> -Infinity +ddfma37785 fma 1 -Inf 1 -> -Infinity +ddfma37786 fma 1 -Inf 1000 -> -Infinity +ddfma37787 fma 1 -1000 -Inf -> -Infinity +ddfma37788 fma 1 -Inf -Inf -> -Infinity +ddfma37789 fma 1 -1 -Inf -> -Infinity +ddfma37790 fma 1 -0 -Inf -> -Infinity +ddfma37791 fma 1 0 -Inf -> -Infinity +ddfma37792 fma 1 1 -Inf -> -Infinity +ddfma37793 fma 1 1000 -Inf -> -Infinity +ddfma37794 fma 1 Inf -Inf -> NaN Invalid_operation + +ddfma37800 fma 1 Inf -Inf -> NaN Invalid_operation +ddfma37801 fma 1 Inf -1000 -> Infinity +ddfma37802 fma 1 Inf -1 -> Infinity +ddfma37803 fma 1 Inf -0 -> Infinity +ddfma37804 fma 1 Inf 0 -> Infinity +ddfma37805 fma 1 Inf 1 -> Infinity +ddfma37806 fma 1 Inf 1000 -> Infinity +ddfma37807 fma 1 Inf Inf -> Infinity +ddfma37808 fma 1 -1000 Inf -> Infinity +ddfma37809 fma 1 -Inf Inf -> NaN Invalid_operation +ddfma37810 fma 1 -1 Inf -> Infinity +ddfma37811 fma 1 -0 Inf -> Infinity +ddfma37812 fma 1 0 Inf -> Infinity +ddfma37813 fma 1 1 Inf -> Infinity +ddfma37814 fma 1 1000 Inf -> Infinity +ddfma37815 fma 1 Inf Inf -> Infinity + +ddfma37821 fma 1 NaN -Inf -> NaN +ddfma37822 fma 1 NaN -1000 -> NaN +ddfma37823 fma 1 NaN -1 -> NaN +ddfma37824 fma 1 NaN -0 -> NaN +ddfma37825 fma 1 NaN 0 -> NaN +ddfma37826 fma 1 NaN 1 -> NaN +ddfma37827 fma 1 NaN 1000 -> NaN +ddfma37828 fma 1 NaN Inf -> NaN +ddfma37829 fma 1 NaN NaN -> NaN +ddfma37830 fma 1 -Inf NaN -> NaN +ddfma37831 fma 1 -1000 NaN -> NaN +ddfma37832 fma 1 -1 NaN -> NaN +ddfma37833 fma 1 -0 NaN -> NaN +ddfma37834 fma 1 0 NaN -> NaN +ddfma37835 fma 1 1 NaN -> NaN +ddfma37836 fma 1 1000 NaN -> NaN +ddfma37837 fma 1 Inf NaN -> NaN + +ddfma37841 fma 1 sNaN -Inf -> NaN Invalid_operation +ddfma37842 fma 1 sNaN -1000 -> NaN Invalid_operation +ddfma37843 fma 1 sNaN -1 -> NaN Invalid_operation +ddfma37844 fma 1 sNaN -0 -> NaN Invalid_operation +ddfma37845 fma 1 sNaN 0 -> NaN Invalid_operation +ddfma37846 fma 1 sNaN 1 -> NaN Invalid_operation +ddfma37847 fma 1 sNaN 1000 -> NaN Invalid_operation +ddfma37848 fma 1 sNaN NaN -> NaN Invalid_operation +ddfma37849 fma 1 sNaN sNaN -> NaN Invalid_operation +ddfma37850 fma 1 NaN sNaN -> NaN Invalid_operation +ddfma37851 fma 1 -Inf sNaN -> NaN Invalid_operation +ddfma37852 fma 1 -1000 sNaN -> NaN Invalid_operation +ddfma37853 fma 1 -1 sNaN -> NaN Invalid_operation +ddfma37854 fma 1 -0 sNaN -> NaN Invalid_operation +ddfma37855 fma 1 0 sNaN -> NaN Invalid_operation +ddfma37856 fma 1 1 sNaN -> NaN Invalid_operation +ddfma37857 fma 1 1000 sNaN -> NaN Invalid_operation +ddfma37858 fma 1 Inf sNaN -> NaN Invalid_operation +ddfma37859 fma 1 NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +ddfma37861 fma 1 NaN1 -Inf -> NaN1 +ddfma37862 fma 1 +NaN2 -1000 -> NaN2 +ddfma37863 fma 1 NaN3 1000 -> NaN3 +ddfma37864 fma 1 NaN4 Inf -> NaN4 +ddfma37865 fma 1 NaN5 +NaN6 -> NaN5 +ddfma37866 fma 1 -Inf NaN7 -> NaN7 +ddfma37867 fma 1 -1000 NaN8 -> NaN8 +ddfma37868 fma 1 1000 NaN9 -> NaN9 +ddfma37869 fma 1 Inf +NaN10 -> NaN10 +ddfma37871 fma 1 sNaN11 -Inf -> NaN11 Invalid_operation +ddfma37872 fma 1 sNaN12 -1000 -> NaN12 Invalid_operation +ddfma37873 fma 1 sNaN13 1000 -> NaN13 Invalid_operation +ddfma37874 fma 1 sNaN14 NaN17 -> NaN14 Invalid_operation +ddfma37875 fma 1 sNaN15 sNaN18 -> NaN15 Invalid_operation +ddfma37876 fma 1 NaN16 sNaN19 -> NaN19 Invalid_operation +ddfma37877 fma 1 -Inf +sNaN20 -> NaN20 Invalid_operation +ddfma37878 fma 1 -1000 sNaN21 -> NaN21 Invalid_operation +ddfma37879 fma 1 1000 sNaN22 -> NaN22 Invalid_operation +ddfma37880 fma 1 Inf sNaN23 -> NaN23 Invalid_operation +ddfma37881 fma 1 +NaN25 +sNaN24 -> NaN24 Invalid_operation +ddfma37882 fma 1 -NaN26 NaN28 -> -NaN26 +ddfma37883 fma 1 -sNaN27 sNaN29 -> -NaN27 Invalid_operation +ddfma37884 fma 1 1000 -NaN30 -> -NaN30 +ddfma37885 fma 1 1000 -sNaN31 -> -NaN31 Invalid_operation + +-- Here we explore near the boundary of rounding a subnormal to Nmin +ddfma37575 fma 1 1E-383 -1E-398 -> 9.99999999999999E-384 Subnormal +ddfma37576 fma 1 -1E-383 +1E-398 -> -9.99999999999999E-384 Subnormal + +-- check overflow edge case +-- 1234567890123456 +ddfma37972 apply 9.999999999999999E+384 -> 9.999999999999999E+384 +ddfma37973 fma 1 9.999999999999999E+384 1 -> 9.999999999999999E+384 Inexact Rounded +ddfma37974 fma 1 9999999999999999E+369 1 -> 9.999999999999999E+384 Inexact Rounded +ddfma37975 fma 1 9999999999999999E+369 1E+369 -> Infinity Overflow Inexact Rounded +ddfma37976 fma 1 9999999999999999E+369 9E+368 -> Infinity Overflow Inexact Rounded +ddfma37977 fma 1 9999999999999999E+369 8E+368 -> Infinity Overflow Inexact Rounded +ddfma37978 fma 1 9999999999999999E+369 7E+368 -> Infinity Overflow Inexact Rounded +ddfma37979 fma 1 9999999999999999E+369 6E+368 -> Infinity Overflow Inexact Rounded +ddfma37980 fma 1 9999999999999999E+369 5E+368 -> Infinity Overflow Inexact Rounded +ddfma37981 fma 1 9999999999999999E+369 4E+368 -> 9.999999999999999E+384 Inexact Rounded +ddfma37982 fma 1 9999999999999999E+369 3E+368 -> 9.999999999999999E+384 Inexact Rounded +ddfma37983 fma 1 9999999999999999E+369 2E+368 -> 9.999999999999999E+384 Inexact Rounded +ddfma37984 fma 1 9999999999999999E+369 1E+368 -> 9.999999999999999E+384 Inexact Rounded + +ddfma37985 apply -9.999999999999999E+384 -> -9.999999999999999E+384 +ddfma37986 fma 1 -9.999999999999999E+384 -1 -> -9.999999999999999E+384 Inexact Rounded +ddfma37987 fma 1 -9999999999999999E+369 -1 -> -9.999999999999999E+384 Inexact Rounded +ddfma37988 fma 1 -9999999999999999E+369 -1E+369 -> -Infinity Overflow Inexact Rounded +ddfma37989 fma 1 -9999999999999999E+369 -9E+368 -> -Infinity Overflow Inexact Rounded +ddfma37990 fma 1 -9999999999999999E+369 -8E+368 -> -Infinity Overflow Inexact Rounded +ddfma37991 fma 1 -9999999999999999E+369 -7E+368 -> -Infinity Overflow Inexact Rounded +ddfma37992 fma 1 -9999999999999999E+369 -6E+368 -> -Infinity Overflow Inexact Rounded +ddfma37993 fma 1 -9999999999999999E+369 -5E+368 -> -Infinity Overflow Inexact Rounded +ddfma37994 fma 1 -9999999999999999E+369 -4E+368 -> -9.999999999999999E+384 Inexact Rounded +ddfma37995 fma 1 -9999999999999999E+369 -3E+368 -> -9.999999999999999E+384 Inexact Rounded +ddfma37996 fma 1 -9999999999999999E+369 -2E+368 -> -9.999999999999999E+384 Inexact Rounded +ddfma37997 fma 1 -9999999999999999E+369 -1E+368 -> -9.999999999999999E+384 Inexact Rounded + +-- And for round down full and subnormal results +rounding: down +ddfma371100 fma 1 1e+2 -1e-383 -> 99.99999999999999 Rounded Inexact +ddfma371101 fma 1 1e+1 -1e-383 -> 9.999999999999999 Rounded Inexact +ddfma371103 fma 1 +1 -1e-383 -> 0.9999999999999999 Rounded Inexact +ddfma371104 fma 1 1e-1 -1e-383 -> 0.09999999999999999 Rounded Inexact +ddfma371105 fma 1 1e-2 -1e-383 -> 0.009999999999999999 Rounded Inexact +ddfma371106 fma 1 1e-3 -1e-383 -> 0.0009999999999999999 Rounded Inexact +ddfma371107 fma 1 1e-4 -1e-383 -> 0.00009999999999999999 Rounded Inexact +ddfma371108 fma 1 1e-5 -1e-383 -> 0.000009999999999999999 Rounded Inexact +ddfma371109 fma 1 1e-6 -1e-383 -> 9.999999999999999E-7 Rounded Inexact + +rounding: ceiling +ddfma371110 fma 1 -1e+2 +1e-383 -> -99.99999999999999 Rounded Inexact +ddfma371111 fma 1 -1e+1 +1e-383 -> -9.999999999999999 Rounded Inexact +ddfma371113 fma 1 -1 +1e-383 -> -0.9999999999999999 Rounded Inexact +ddfma371114 fma 1 -1e-1 +1e-383 -> -0.09999999999999999 Rounded Inexact +ddfma371115 fma 1 -1e-2 +1e-383 -> -0.009999999999999999 Rounded Inexact +ddfma371116 fma 1 -1e-3 +1e-383 -> -0.0009999999999999999 Rounded Inexact +ddfma371117 fma 1 -1e-4 +1e-383 -> -0.00009999999999999999 Rounded Inexact +ddfma371118 fma 1 -1e-5 +1e-383 -> -0.000009999999999999999 Rounded Inexact +ddfma371119 fma 1 -1e-6 +1e-383 -> -9.999999999999999E-7 Rounded Inexact + +-- tests based on Gunnar Degnbol's edge case +rounding: half_even + +ddfma371300 fma 1 1E16 -0.5 -> 1.000000000000000E+16 Inexact Rounded +ddfma371310 fma 1 1E16 -0.51 -> 9999999999999999 Inexact Rounded +ddfma371311 fma 1 1E16 -0.501 -> 9999999999999999 Inexact Rounded +ddfma371312 fma 1 1E16 -0.5001 -> 9999999999999999 Inexact Rounded +ddfma371313 fma 1 1E16 -0.50001 -> 9999999999999999 Inexact Rounded +ddfma371314 fma 1 1E16 -0.500001 -> 9999999999999999 Inexact Rounded +ddfma371315 fma 1 1E16 -0.5000001 -> 9999999999999999 Inexact Rounded +ddfma371316 fma 1 1E16 -0.50000001 -> 9999999999999999 Inexact Rounded +ddfma371317 fma 1 1E16 -0.500000001 -> 9999999999999999 Inexact Rounded +ddfma371318 fma 1 1E16 -0.5000000001 -> 9999999999999999 Inexact Rounded +ddfma371319 fma 1 1E16 -0.50000000001 -> 9999999999999999 Inexact Rounded +ddfma371320 fma 1 1E16 -0.500000000001 -> 9999999999999999 Inexact Rounded +ddfma371321 fma 1 1E16 -0.5000000000001 -> 9999999999999999 Inexact Rounded +ddfma371322 fma 1 1E16 -0.50000000000001 -> 9999999999999999 Inexact Rounded +ddfma371323 fma 1 1E16 -0.500000000000001 -> 9999999999999999 Inexact Rounded +ddfma371324 fma 1 1E16 -0.5000000000000001 -> 9999999999999999 Inexact Rounded +ddfma371325 fma 1 1E16 -0.5000000000000000 -> 1.000000000000000E+16 Inexact Rounded +ddfma371326 fma 1 1E16 -0.500000000000000 -> 1.000000000000000E+16 Inexact Rounded +ddfma371327 fma 1 1E16 -0.50000000000000 -> 1.000000000000000E+16 Inexact Rounded +ddfma371328 fma 1 1E16 -0.5000000000000 -> 1.000000000000000E+16 Inexact Rounded +ddfma371329 fma 1 1E16 -0.500000000000 -> 1.000000000000000E+16 Inexact Rounded +ddfma371330 fma 1 1E16 -0.50000000000 -> 1.000000000000000E+16 Inexact Rounded +ddfma371331 fma 1 1E16 -0.5000000000 -> 1.000000000000000E+16 Inexact Rounded +ddfma371332 fma 1 1E16 -0.500000000 -> 1.000000000000000E+16 Inexact Rounded +ddfma371333 fma 1 1E16 -0.50000000 -> 1.000000000000000E+16 Inexact Rounded +ddfma371334 fma 1 1E16 -0.5000000 -> 1.000000000000000E+16 Inexact Rounded +ddfma371335 fma 1 1E16 -0.500000 -> 1.000000000000000E+16 Inexact Rounded +ddfma371336 fma 1 1E16 -0.50000 -> 1.000000000000000E+16 Inexact Rounded +ddfma371337 fma 1 1E16 -0.5000 -> 1.000000000000000E+16 Inexact Rounded +ddfma371338 fma 1 1E16 -0.500 -> 1.000000000000000E+16 Inexact Rounded +ddfma371339 fma 1 1E16 -0.50 -> 1.000000000000000E+16 Inexact Rounded + +ddfma371340 fma 1 1E16 -5000000.000010001 -> 9999999995000000 Inexact Rounded +ddfma371341 fma 1 1E16 -5000000.000000001 -> 9999999995000000 Inexact Rounded + +ddfma371349 fma 1 9999999999999999 0.4 -> 9999999999999999 Inexact Rounded +ddfma371350 fma 1 9999999999999999 0.49 -> 9999999999999999 Inexact Rounded +ddfma371351 fma 1 9999999999999999 0.499 -> 9999999999999999 Inexact Rounded +ddfma371352 fma 1 9999999999999999 0.4999 -> 9999999999999999 Inexact Rounded +ddfma371353 fma 1 9999999999999999 0.49999 -> 9999999999999999 Inexact Rounded +ddfma371354 fma 1 9999999999999999 0.499999 -> 9999999999999999 Inexact Rounded +ddfma371355 fma 1 9999999999999999 0.4999999 -> 9999999999999999 Inexact Rounded +ddfma371356 fma 1 9999999999999999 0.49999999 -> 9999999999999999 Inexact Rounded +ddfma371357 fma 1 9999999999999999 0.499999999 -> 9999999999999999 Inexact Rounded +ddfma371358 fma 1 9999999999999999 0.4999999999 -> 9999999999999999 Inexact Rounded +ddfma371359 fma 1 9999999999999999 0.49999999999 -> 9999999999999999 Inexact Rounded +ddfma371360 fma 1 9999999999999999 0.499999999999 -> 9999999999999999 Inexact Rounded +ddfma371361 fma 1 9999999999999999 0.4999999999999 -> 9999999999999999 Inexact Rounded +ddfma371362 fma 1 9999999999999999 0.49999999999999 -> 9999999999999999 Inexact Rounded +ddfma371363 fma 1 9999999999999999 0.499999999999999 -> 9999999999999999 Inexact Rounded +ddfma371364 fma 1 9999999999999999 0.4999999999999999 -> 9999999999999999 Inexact Rounded +ddfma371365 fma 1 9999999999999999 0.5000000000000000 -> 1.000000000000000E+16 Inexact Rounded +ddfma371367 fma 1 9999999999999999 0.500000000000000 -> 1.000000000000000E+16 Inexact Rounded +ddfma371368 fma 1 9999999999999999 0.50000000000000 -> 1.000000000000000E+16 Inexact Rounded +ddfma371369 fma 1 9999999999999999 0.5000000000000 -> 1.000000000000000E+16 Inexact Rounded +ddfma371370 fma 1 9999999999999999 0.500000000000 -> 1.000000000000000E+16 Inexact Rounded +ddfma371371 fma 1 9999999999999999 0.50000000000 -> 1.000000000000000E+16 Inexact Rounded +ddfma371372 fma 1 9999999999999999 0.5000000000 -> 1.000000000000000E+16 Inexact Rounded +ddfma371373 fma 1 9999999999999999 0.500000000 -> 1.000000000000000E+16 Inexact Rounded +ddfma371374 fma 1 9999999999999999 0.50000000 -> 1.000000000000000E+16 Inexact Rounded +ddfma371375 fma 1 9999999999999999 0.5000000 -> 1.000000000000000E+16 Inexact Rounded +ddfma371376 fma 1 9999999999999999 0.500000 -> 1.000000000000000E+16 Inexact Rounded +ddfma371377 fma 1 9999999999999999 0.50000 -> 1.000000000000000E+16 Inexact Rounded +ddfma371378 fma 1 9999999999999999 0.5000 -> 1.000000000000000E+16 Inexact Rounded +ddfma371379 fma 1 9999999999999999 0.500 -> 1.000000000000000E+16 Inexact Rounded +ddfma371380 fma 1 9999999999999999 0.50 -> 1.000000000000000E+16 Inexact Rounded +ddfma371381 fma 1 9999999999999999 0.5 -> 1.000000000000000E+16 Inexact Rounded +ddfma371382 fma 1 9999999999999999 0.5000000000000001 -> 1.000000000000000E+16 Inexact Rounded +ddfma371383 fma 1 9999999999999999 0.500000000000001 -> 1.000000000000000E+16 Inexact Rounded +ddfma371384 fma 1 9999999999999999 0.50000000000001 -> 1.000000000000000E+16 Inexact Rounded +ddfma371385 fma 1 9999999999999999 0.5000000000001 -> 1.000000000000000E+16 Inexact Rounded +ddfma371386 fma 1 9999999999999999 0.500000000001 -> 1.000000000000000E+16 Inexact Rounded +ddfma371387 fma 1 9999999999999999 0.50000000001 -> 1.000000000000000E+16 Inexact Rounded +ddfma371388 fma 1 9999999999999999 0.5000000001 -> 1.000000000000000E+16 Inexact Rounded +ddfma371389 fma 1 9999999999999999 0.500000001 -> 1.000000000000000E+16 Inexact Rounded +ddfma371390 fma 1 9999999999999999 0.50000001 -> 1.000000000000000E+16 Inexact Rounded +ddfma371391 fma 1 9999999999999999 0.5000001 -> 1.000000000000000E+16 Inexact Rounded +ddfma371392 fma 1 9999999999999999 0.500001 -> 1.000000000000000E+16 Inexact Rounded +ddfma371393 fma 1 9999999999999999 0.50001 -> 1.000000000000000E+16 Inexact Rounded +ddfma371394 fma 1 9999999999999999 0.5001 -> 1.000000000000000E+16 Inexact Rounded +ddfma371395 fma 1 9999999999999999 0.501 -> 1.000000000000000E+16 Inexact Rounded +ddfma371396 fma 1 9999999999999999 0.51 -> 1.000000000000000E+16 Inexact Rounded + +-- More GD edge cases, where difference between the unadjusted +-- exponents is larger than the maximum precision and one side is 0 +ddfma371420 fma 1 0 1.123456789012345 -> 1.123456789012345 +ddfma371421 fma 1 0 1.123456789012345E-1 -> 0.1123456789012345 +ddfma371422 fma 1 0 1.123456789012345E-2 -> 0.01123456789012345 +ddfma371423 fma 1 0 1.123456789012345E-3 -> 0.001123456789012345 +ddfma371424 fma 1 0 1.123456789012345E-4 -> 0.0001123456789012345 +ddfma371425 fma 1 0 1.123456789012345E-5 -> 0.00001123456789012345 +ddfma371426 fma 1 0 1.123456789012345E-6 -> 0.000001123456789012345 +ddfma371427 fma 1 0 1.123456789012345E-7 -> 1.123456789012345E-7 +ddfma371428 fma 1 0 1.123456789012345E-8 -> 1.123456789012345E-8 +ddfma371429 fma 1 0 1.123456789012345E-9 -> 1.123456789012345E-9 +ddfma371430 fma 1 0 1.123456789012345E-10 -> 1.123456789012345E-10 +ddfma371431 fma 1 0 1.123456789012345E-11 -> 1.123456789012345E-11 +ddfma371432 fma 1 0 1.123456789012345E-12 -> 1.123456789012345E-12 +ddfma371433 fma 1 0 1.123456789012345E-13 -> 1.123456789012345E-13 +ddfma371434 fma 1 0 1.123456789012345E-14 -> 1.123456789012345E-14 +ddfma371435 fma 1 0 1.123456789012345E-15 -> 1.123456789012345E-15 +ddfma371436 fma 1 0 1.123456789012345E-16 -> 1.123456789012345E-16 +ddfma371437 fma 1 0 1.123456789012345E-17 -> 1.123456789012345E-17 +ddfma371438 fma 1 0 1.123456789012345E-18 -> 1.123456789012345E-18 +ddfma371439 fma 1 0 1.123456789012345E-19 -> 1.123456789012345E-19 + +-- same, reversed 0 +ddfma371440 fma 1 1.123456789012345 0 -> 1.123456789012345 +ddfma371441 fma 1 1.123456789012345E-1 0 -> 0.1123456789012345 +ddfma371442 fma 1 1.123456789012345E-2 0 -> 0.01123456789012345 +ddfma371443 fma 1 1.123456789012345E-3 0 -> 0.001123456789012345 +ddfma371444 fma 1 1.123456789012345E-4 0 -> 0.0001123456789012345 +ddfma371445 fma 1 1.123456789012345E-5 0 -> 0.00001123456789012345 +ddfma371446 fma 1 1.123456789012345E-6 0 -> 0.000001123456789012345 +ddfma371447 fma 1 1.123456789012345E-7 0 -> 1.123456789012345E-7 +ddfma371448 fma 1 1.123456789012345E-8 0 -> 1.123456789012345E-8 +ddfma371449 fma 1 1.123456789012345E-9 0 -> 1.123456789012345E-9 +ddfma371450 fma 1 1.123456789012345E-10 0 -> 1.123456789012345E-10 +ddfma371451 fma 1 1.123456789012345E-11 0 -> 1.123456789012345E-11 +ddfma371452 fma 1 1.123456789012345E-12 0 -> 1.123456789012345E-12 +ddfma371453 fma 1 1.123456789012345E-13 0 -> 1.123456789012345E-13 +ddfma371454 fma 1 1.123456789012345E-14 0 -> 1.123456789012345E-14 +ddfma371455 fma 1 1.123456789012345E-15 0 -> 1.123456789012345E-15 +ddfma371456 fma 1 1.123456789012345E-16 0 -> 1.123456789012345E-16 +ddfma371457 fma 1 1.123456789012345E-17 0 -> 1.123456789012345E-17 +ddfma371458 fma 1 1.123456789012345E-18 0 -> 1.123456789012345E-18 +ddfma371459 fma 1 1.123456789012345E-19 0 -> 1.123456789012345E-19 + +-- same, Es on the 0 +ddfma371460 fma 1 1.123456789012345 0E-0 -> 1.123456789012345 +ddfma371461 fma 1 1.123456789012345 0E-1 -> 1.123456789012345 +ddfma371462 fma 1 1.123456789012345 0E-2 -> 1.123456789012345 +ddfma371463 fma 1 1.123456789012345 0E-3 -> 1.123456789012345 +ddfma371464 fma 1 1.123456789012345 0E-4 -> 1.123456789012345 +ddfma371465 fma 1 1.123456789012345 0E-5 -> 1.123456789012345 +ddfma371466 fma 1 1.123456789012345 0E-6 -> 1.123456789012345 +ddfma371467 fma 1 1.123456789012345 0E-7 -> 1.123456789012345 +ddfma371468 fma 1 1.123456789012345 0E-8 -> 1.123456789012345 +ddfma371469 fma 1 1.123456789012345 0E-9 -> 1.123456789012345 +ddfma371470 fma 1 1.123456789012345 0E-10 -> 1.123456789012345 +ddfma371471 fma 1 1.123456789012345 0E-11 -> 1.123456789012345 +ddfma371472 fma 1 1.123456789012345 0E-12 -> 1.123456789012345 +ddfma371473 fma 1 1.123456789012345 0E-13 -> 1.123456789012345 +ddfma371474 fma 1 1.123456789012345 0E-14 -> 1.123456789012345 +ddfma371475 fma 1 1.123456789012345 0E-15 -> 1.123456789012345 +-- next four flag Rounded because the 0 extends the result +ddfma371476 fma 1 1.123456789012345 0E-16 -> 1.123456789012345 Rounded +ddfma371477 fma 1 1.123456789012345 0E-17 -> 1.123456789012345 Rounded +ddfma371478 fma 1 1.123456789012345 0E-18 -> 1.123456789012345 Rounded +ddfma371479 fma 1 1.123456789012345 0E-19 -> 1.123456789012345 Rounded + +-- sum of two opposite-sign operands is exactly 0 and floor => -0 +rounding: half_up +-- exact zeros from zeros +ddfma371500 fma 1 0 0E-19 -> 0E-19 +ddfma371501 fma 1 -0 0E-19 -> 0E-19 +ddfma371502 fma 1 0 -0E-19 -> 0E-19 +ddfma371503 fma 1 -0 -0E-19 -> -0E-19 +-- exact zeros from non-zeros +ddfma371511 fma 1 -11 11 -> 0 +ddfma371512 fma 1 11 -11 -> 0 + +rounding: half_down +-- exact zeros from zeros +ddfma371520 fma 1 0 0E-19 -> 0E-19 +ddfma371521 fma 1 -0 0E-19 -> 0E-19 +ddfma371522 fma 1 0 -0E-19 -> 0E-19 +ddfma371523 fma 1 -0 -0E-19 -> -0E-19 +-- exact zeros from non-zeros +ddfma371531 fma 1 -11 11 -> 0 +ddfma371532 fma 1 11 -11 -> 0 + +rounding: half_even +-- exact zeros from zeros +ddfma371540 fma 1 0 0E-19 -> 0E-19 +ddfma371541 fma 1 -0 0E-19 -> 0E-19 +ddfma371542 fma 1 0 -0E-19 -> 0E-19 +ddfma371543 fma 1 -0 -0E-19 -> -0E-19 +-- exact zeros from non-zeros +ddfma371551 fma 1 -11 11 -> 0 +ddfma371552 fma 1 11 -11 -> 0 + +rounding: up +-- exact zeros from zeros +ddfma371560 fma 1 0 0E-19 -> 0E-19 +ddfma371561 fma 1 -0 0E-19 -> 0E-19 +ddfma371562 fma 1 0 -0E-19 -> 0E-19 +ddfma371563 fma 1 -0 -0E-19 -> -0E-19 +-- exact zeros from non-zeros +ddfma371571 fma 1 -11 11 -> 0 +ddfma371572 fma 1 11 -11 -> 0 + +rounding: down +-- exact zeros from zeros +ddfma371580 fma 1 0 0E-19 -> 0E-19 +ddfma371581 fma 1 -0 0E-19 -> 0E-19 +ddfma371582 fma 1 0 -0E-19 -> 0E-19 +ddfma371583 fma 1 -0 -0E-19 -> -0E-19 +-- exact zeros from non-zeros +ddfma371591 fma 1 -11 11 -> 0 +ddfma371592 fma 1 11 -11 -> 0 + +rounding: ceiling +-- exact zeros from zeros +ddfma371600 fma 1 0 0E-19 -> 0E-19 +ddfma371601 fma 1 -0 0E-19 -> 0E-19 +ddfma371602 fma 1 0 -0E-19 -> 0E-19 +ddfma371603 fma 1 -0 -0E-19 -> -0E-19 +-- exact zeros from non-zeros +ddfma371611 fma 1 -11 11 -> 0 +ddfma371612 fma 1 11 -11 -> 0 + +-- and the extra-special ugly case; unusual minuses marked by -- * +rounding: floor +-- exact zeros from zeros +ddfma371620 fma 1 0 0E-19 -> 0E-19 +ddfma371621 fma 1 -0 0E-19 -> -0E-19 -- * +ddfma371622 fma 1 0 -0E-19 -> -0E-19 -- * +ddfma371623 fma 1 -0 -0E-19 -> -0E-19 +-- exact zeros from non-zeros +ddfma371631 fma 1 -11 11 -> -0 -- * +ddfma371632 fma 1 11 -11 -> -0 -- * + +-- Examples from SQL proposal (Krishna Kulkarni) +ddfma371701 fma 1 130E-2 120E-2 -> 2.50 +ddfma371702 fma 1 130E-2 12E-1 -> 2.50 +ddfma371703 fma 1 130E-2 1E0 -> 2.30 +ddfma371704 fma 1 1E2 1E4 -> 1.01E+4 +ddfma371705 fma 1 130E-2 -120E-2 -> 0.10 +ddfma371706 fma 1 130E-2 -12E-1 -> 0.10 +ddfma371707 fma 1 130E-2 -1E0 -> 0.30 +ddfma371708 fma 1 1E2 -1E4 -> -9.9E+3 + +-- Gappy coefficients; check residue handling even with full coefficient gap +rounding: half_even + +ddfma375001 fma 1 1234567890123456 1 -> 1234567890123457 +ddfma375002 fma 1 1234567890123456 0.6 -> 1234567890123457 Inexact Rounded +ddfma375003 fma 1 1234567890123456 0.06 -> 1234567890123456 Inexact Rounded +ddfma375004 fma 1 1234567890123456 6E-3 -> 1234567890123456 Inexact Rounded +ddfma375005 fma 1 1234567890123456 6E-4 -> 1234567890123456 Inexact Rounded +ddfma375006 fma 1 1234567890123456 6E-5 -> 1234567890123456 Inexact Rounded +ddfma375007 fma 1 1234567890123456 6E-6 -> 1234567890123456 Inexact Rounded +ddfma375008 fma 1 1234567890123456 6E-7 -> 1234567890123456 Inexact Rounded +ddfma375009 fma 1 1234567890123456 6E-8 -> 1234567890123456 Inexact Rounded +ddfma375010 fma 1 1234567890123456 6E-9 -> 1234567890123456 Inexact Rounded +ddfma375011 fma 1 1234567890123456 6E-10 -> 1234567890123456 Inexact Rounded +ddfma375012 fma 1 1234567890123456 6E-11 -> 1234567890123456 Inexact Rounded +ddfma375013 fma 1 1234567890123456 6E-12 -> 1234567890123456 Inexact Rounded +ddfma375014 fma 1 1234567890123456 6E-13 -> 1234567890123456 Inexact Rounded +ddfma375015 fma 1 1234567890123456 6E-14 -> 1234567890123456 Inexact Rounded +ddfma375016 fma 1 1234567890123456 6E-15 -> 1234567890123456 Inexact Rounded +ddfma375017 fma 1 1234567890123456 6E-16 -> 1234567890123456 Inexact Rounded +ddfma375018 fma 1 1234567890123456 6E-17 -> 1234567890123456 Inexact Rounded +ddfma375019 fma 1 1234567890123456 6E-18 -> 1234567890123456 Inexact Rounded +ddfma375020 fma 1 1234567890123456 6E-19 -> 1234567890123456 Inexact Rounded +ddfma375021 fma 1 1234567890123456 6E-20 -> 1234567890123456 Inexact Rounded + +-- widening second argument at gap +ddfma375030 fma 1 12345678 1 -> 12345679 +ddfma375031 fma 1 12345678 0.1 -> 12345678.1 +ddfma375032 fma 1 12345678 0.12 -> 12345678.12 +ddfma375033 fma 1 12345678 0.123 -> 12345678.123 +ddfma375034 fma 1 12345678 0.1234 -> 12345678.1234 +ddfma375035 fma 1 12345678 0.12345 -> 12345678.12345 +ddfma375036 fma 1 12345678 0.123456 -> 12345678.123456 +ddfma375037 fma 1 12345678 0.1234567 -> 12345678.1234567 +ddfma375038 fma 1 12345678 0.12345678 -> 12345678.12345678 +ddfma375039 fma 1 12345678 0.123456789 -> 12345678.12345679 Inexact Rounded +ddfma375040 fma 1 12345678 0.123456785 -> 12345678.12345678 Inexact Rounded +ddfma375041 fma 1 12345678 0.1234567850 -> 12345678.12345678 Inexact Rounded +ddfma375042 fma 1 12345678 0.1234567851 -> 12345678.12345679 Inexact Rounded +ddfma375043 fma 1 12345678 0.12345678501 -> 12345678.12345679 Inexact Rounded +ddfma375044 fma 1 12345678 0.123456785001 -> 12345678.12345679 Inexact Rounded +ddfma375045 fma 1 12345678 0.1234567850001 -> 12345678.12345679 Inexact Rounded +ddfma375046 fma 1 12345678 0.12345678500001 -> 12345678.12345679 Inexact Rounded +ddfma375047 fma 1 12345678 0.123456785000001 -> 12345678.12345679 Inexact Rounded +ddfma375048 fma 1 12345678 0.1234567850000001 -> 12345678.12345679 Inexact Rounded +ddfma375049 fma 1 12345678 0.1234567850000000 -> 12345678.12345678 Inexact Rounded +-- 90123456 +rounding: half_even +ddfma375050 fma 1 12345678 0.0234567750000000 -> 12345678.02345678 Inexact Rounded +ddfma375051 fma 1 12345678 0.0034567750000000 -> 12345678.00345678 Inexact Rounded +ddfma375052 fma 1 12345678 0.0004567750000000 -> 12345678.00045678 Inexact Rounded +ddfma375053 fma 1 12345678 0.0000567750000000 -> 12345678.00005678 Inexact Rounded +ddfma375054 fma 1 12345678 0.0000067750000000 -> 12345678.00000678 Inexact Rounded +ddfma375055 fma 1 12345678 0.0000007750000000 -> 12345678.00000078 Inexact Rounded +ddfma375056 fma 1 12345678 0.0000000750000000 -> 12345678.00000008 Inexact Rounded +ddfma375057 fma 1 12345678 0.0000000050000000 -> 12345678.00000000 Inexact Rounded +ddfma375060 fma 1 12345678 0.0234567750000001 -> 12345678.02345678 Inexact Rounded +ddfma375061 fma 1 12345678 0.0034567750000001 -> 12345678.00345678 Inexact Rounded +ddfma375062 fma 1 12345678 0.0004567750000001 -> 12345678.00045678 Inexact Rounded +ddfma375063 fma 1 12345678 0.0000567750000001 -> 12345678.00005678 Inexact Rounded +ddfma375064 fma 1 12345678 0.0000067750000001 -> 12345678.00000678 Inexact Rounded +ddfma375065 fma 1 12345678 0.0000007750000001 -> 12345678.00000078 Inexact Rounded +ddfma375066 fma 1 12345678 0.0000000750000001 -> 12345678.00000008 Inexact Rounded +ddfma375067 fma 1 12345678 0.0000000050000001 -> 12345678.00000001 Inexact Rounded +-- far-out residues (full coefficient gap is 16+15 digits) +rounding: up +ddfma375070 fma 1 12345678 1E-8 -> 12345678.00000001 +ddfma375071 fma 1 12345678 1E-9 -> 12345678.00000001 Inexact Rounded +ddfma375072 fma 1 12345678 1E-10 -> 12345678.00000001 Inexact Rounded +ddfma375073 fma 1 12345678 1E-11 -> 12345678.00000001 Inexact Rounded +ddfma375074 fma 1 12345678 1E-12 -> 12345678.00000001 Inexact Rounded +ddfma375075 fma 1 12345678 1E-13 -> 12345678.00000001 Inexact Rounded +ddfma375076 fma 1 12345678 1E-14 -> 12345678.00000001 Inexact Rounded +ddfma375077 fma 1 12345678 1E-15 -> 12345678.00000001 Inexact Rounded +ddfma375078 fma 1 12345678 1E-16 -> 12345678.00000001 Inexact Rounded +ddfma375079 fma 1 12345678 1E-17 -> 12345678.00000001 Inexact Rounded +ddfma375080 fma 1 12345678 1E-18 -> 12345678.00000001 Inexact Rounded +ddfma375081 fma 1 12345678 1E-19 -> 12345678.00000001 Inexact Rounded +ddfma375082 fma 1 12345678 1E-20 -> 12345678.00000001 Inexact Rounded +ddfma375083 fma 1 12345678 1E-25 -> 12345678.00000001 Inexact Rounded +ddfma375084 fma 1 12345678 1E-30 -> 12345678.00000001 Inexact Rounded +ddfma375085 fma 1 12345678 1E-31 -> 12345678.00000001 Inexact Rounded +ddfma375086 fma 1 12345678 1E-32 -> 12345678.00000001 Inexact Rounded +ddfma375087 fma 1 12345678 1E-33 -> 12345678.00000001 Inexact Rounded +ddfma375088 fma 1 12345678 1E-34 -> 12345678.00000001 Inexact Rounded +ddfma375089 fma 1 12345678 1E-35 -> 12345678.00000001 Inexact Rounded + +-- desctructive subtraction (from remainder tests) + +-- +++ some of these will be off-by-one remainder vs remainderNear + +ddfma4000 fma -1234567890123454 1.000000000000001 1234567890123456 -> 0.765432109876546 +ddfma4001 fma -1234567890123443 1.00000000000001 1234567890123456 -> 0.65432109876557 +ddfma4002 fma -1234567890123332 1.0000000000001 1234567890123456 -> 0.5432109876668 +ddfma4003 fma -308641972530863 4.000000000000001 1234567890123455 -> 2.691358027469137 +ddfma4004 fma -308641972530863 4.000000000000001 1234567890123456 -> 3.691358027469137 +ddfma4005 fma -246913578024696 4.9999999999999 1234567890123456 -> 0.6913578024696 +ddfma4006 fma -246913578024691 4.99999999999999 1234567890123456 -> 3.46913578024691 +ddfma4007 fma -246913578024691 4.999999999999999 1234567890123456 -> 1.246913578024691 +ddfma4008 fma -246913578024691 5.000000000000001 1234567890123456 -> 0.753086421975309 +ddfma4009 fma -246913578024690 5.00000000000001 1234567890123456 -> 3.53086421975310 +ddfma4010 fma -246913578024686 5.0000000000001 1234567890123456 -> 1.3086421975314 +ddfma4011 fma -1234567890123455 1.000000000000001 1234567890123456 -> -0.234567890123455 +ddfma4012 fma -1234567890123444 1.00000000000001 1234567890123456 -> -0.34567890123444 +ddfma4013 fma -1234567890123333 1.0000000000001 1234567890123456 -> -0.4567890123333 +ddfma4014 fma -308641972530864 4.000000000000001 1234567890123455 -> -1.308641972530864 +ddfma4015 fma -308641972530864 4.000000000000001 1234567890123456 -> -0.308641972530864 +ddfma4016 fma -246913578024696 4.9999999999999 1234567890123456 -> 0.6913578024696 +ddfma4017 fma -246913578024692 4.99999999999999 1234567890123456 -> -1.53086421975308 +ddfma4018 fma -246913578024691 4.999999999999999 1234567890123456 -> 1.246913578024691 +ddfma4019 fma -246913578024691 5.000000000000001 1234567890123456 -> 0.753086421975309 +ddfma4020 fma -246913578024691 5.00000000000001 1234567890123456 -> -1.46913578024691 +ddfma4021 fma -246913578024686 5.0000000000001 1234567890123456 -> 1.3086421975314 + + +-- Null tests +ddfma39990 fma 1 10 # -> NaN Invalid_operation +ddfma39991 fma 1 # 10 -> NaN Invalid_operation + + Added: python/branches/release25-maint/Lib/test/decimaltestdata/ddInvert.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/ddInvert.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,202 @@ +------------------------------------------------------------------------ +-- ddInvert.decTest -- digitwise logical INVERT for decDoubles -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +precision: 16 +maxExponent: 384 +minExponent: -383 +extended: 1 +clamp: 1 +rounding: half_even + +-- Sanity check (truth table) +ddinv001 invert 0 -> 1111111111111111 +ddinv002 invert 1 -> 1111111111111110 +ddinv003 invert 10 -> 1111111111111101 +ddinv004 invert 111111111 -> 1111111000000000 +ddinv005 invert 000000000 -> 1111111111111111 +-- and at msd and msd-1 +ddinv007 invert 0000000000000000 -> 1111111111111111 +ddinv008 invert 1000000000000000 -> 111111111111111 +ddinv009 invert 0000000000000000 -> 1111111111111111 +ddinv010 invert 0100000000000000 -> 1011111111111111 +ddinv011 invert 0111111111111111 -> 1000000000000000 +ddinv012 invert 1111111111111111 -> 0 +ddinv013 invert 0011111111111111 -> 1100000000000000 +ddinv014 invert 0111111111111111 -> 1000000000000000 + +-- Various lengths +-- 123456789 1234567890123456 +ddinv021 invert 111111111 -> 1111111000000000 +ddinv022 invert 111111111111 -> 1111000000000000 +ddinv023 invert 11111111 -> 1111111100000000 +ddinv025 invert 1111111 -> 1111111110000000 +ddinv026 invert 111111 -> 1111111111000000 +ddinv027 invert 11111 -> 1111111111100000 +ddinv028 invert 1111 -> 1111111111110000 +ddinv029 invert 111 -> 1111111111111000 +ddinv031 invert 11 -> 1111111111111100 +ddinv032 invert 1 -> 1111111111111110 +ddinv033 invert 111111111111 -> 1111000000000000 +ddinv034 invert 11111111111 -> 1111100000000000 +ddinv035 invert 1111111111 -> 1111110000000000 +ddinv036 invert 111111111 -> 1111111000000000 + +ddinv040 invert 011111111 -> 1111111100000000 +ddinv041 invert 101111111 -> 1111111010000000 +ddinv042 invert 110111111 -> 1111111001000000 +ddinv043 invert 111011111 -> 1111111000100000 +ddinv044 invert 111101111 -> 1111111000010000 +ddinv045 invert 111110111 -> 1111111000001000 +ddinv046 invert 111111011 -> 1111111000000100 +ddinv047 invert 111111101 -> 1111111000000010 +ddinv048 invert 111111110 -> 1111111000000001 +ddinv049 invert 011111011 -> 1111111100000100 +ddinv050 invert 101111101 -> 1111111010000010 +ddinv051 invert 110111110 -> 1111111001000001 +ddinv052 invert 111011101 -> 1111111000100010 +ddinv053 invert 111101011 -> 1111111000010100 +ddinv054 invert 111110111 -> 1111111000001000 +ddinv055 invert 111101011 -> 1111111000010100 +ddinv056 invert 111011101 -> 1111111000100010 +ddinv057 invert 110111110 -> 1111111001000001 +ddinv058 invert 101111101 -> 1111111010000010 +ddinv059 invert 011111011 -> 1111111100000100 + +ddinv080 invert 1000000011111111 -> 111111100000000 +ddinv081 invert 0100000101111111 -> 1011111010000000 +ddinv082 invert 0010000110111111 -> 1101111001000000 +ddinv083 invert 0001000111011111 -> 1110111000100000 +ddinv084 invert 0000100111101111 -> 1111011000010000 +ddinv085 invert 0000010111110111 -> 1111101000001000 +ddinv086 invert 0000001111111011 -> 1111110000000100 +ddinv087 invert 0000010111111101 -> 1111101000000010 +ddinv088 invert 0000100111111110 -> 1111011000000001 +ddinv089 invert 0001000011111011 -> 1110111100000100 +ddinv090 invert 0010000101111101 -> 1101111010000010 +ddinv091 invert 0100000110111110 -> 1011111001000001 +ddinv092 invert 1000000111011101 -> 111111000100010 +ddinv093 invert 0100000111101011 -> 1011111000010100 +ddinv094 invert 0010000111110111 -> 1101111000001000 +ddinv095 invert 0001000111101011 -> 1110111000010100 +ddinv096 invert 0000100111011101 -> 1111011000100010 +ddinv097 invert 0000010110111110 -> 1111101001000001 +ddinv098 invert 0000001101111101 -> 1111110010000010 +ddinv099 invert 0000010011111011 -> 1111101100000100 + +-- non-0/1 should not be accepted, nor should signs +ddinv220 invert 111111112 -> NaN Invalid_operation +ddinv221 invert 333333333 -> NaN Invalid_operation +ddinv222 invert 555555555 -> NaN Invalid_operation +ddinv223 invert 777777777 -> NaN Invalid_operation +ddinv224 invert 999999999 -> NaN Invalid_operation +ddinv225 invert 222222222 -> NaN Invalid_operation +ddinv226 invert 444444444 -> NaN Invalid_operation +ddinv227 invert 666666666 -> NaN Invalid_operation +ddinv228 invert 888888888 -> NaN Invalid_operation +ddinv229 invert 999999999 -> NaN Invalid_operation +ddinv230 invert 999999999 -> NaN Invalid_operation +ddinv231 invert 999999999 -> NaN Invalid_operation +ddinv232 invert 999999999 -> NaN Invalid_operation +-- a few randoms +ddinv240 invert 567468689 -> NaN Invalid_operation +ddinv241 invert 567367689 -> NaN Invalid_operation +ddinv242 invert -631917772 -> NaN Invalid_operation +ddinv243 invert -756253257 -> NaN Invalid_operation +ddinv244 invert 835590149 -> NaN Invalid_operation +-- test MSD +ddinv250 invert 2000000000000000 -> NaN Invalid_operation +ddinv251 invert 3000000000000000 -> NaN Invalid_operation +ddinv252 invert 4000000000000000 -> NaN Invalid_operation +ddinv253 invert 5000000000000000 -> NaN Invalid_operation +ddinv254 invert 6000000000000000 -> NaN Invalid_operation +ddinv255 invert 7000000000000000 -> NaN Invalid_operation +ddinv256 invert 8000000000000000 -> NaN Invalid_operation +ddinv257 invert 9000000000000000 -> NaN Invalid_operation +-- test MSD-1 +ddinv270 invert 0200001000000000 -> NaN Invalid_operation +ddinv271 invert 0300000100000000 -> NaN Invalid_operation +ddinv272 invert 0400000010000000 -> NaN Invalid_operation +ddinv273 invert 0500000001000000 -> NaN Invalid_operation +ddinv274 invert 1600000000100000 -> NaN Invalid_operation +ddinv275 invert 1700000000010000 -> NaN Invalid_operation +ddinv276 invert 1800000000001000 -> NaN Invalid_operation +ddinv277 invert 1900000000000100 -> NaN Invalid_operation +-- test LSD +ddinv280 invert 0010000000000002 -> NaN Invalid_operation +ddinv281 invert 0001000000000003 -> NaN Invalid_operation +ddinv282 invert 0000100000000004 -> NaN Invalid_operation +ddinv283 invert 0000010000000005 -> NaN Invalid_operation +ddinv284 invert 1000001000000006 -> NaN Invalid_operation +ddinv285 invert 1000000100000007 -> NaN Invalid_operation +ddinv286 invert 1000000010000008 -> NaN Invalid_operation +ddinv287 invert 1000000001000009 -> NaN Invalid_operation +-- test Middie +ddinv288 invert 0010000020000000 -> NaN Invalid_operation +ddinv289 invert 0001000030000001 -> NaN Invalid_operation +ddinv290 invert 0000100040000010 -> NaN Invalid_operation +ddinv291 invert 0000010050000100 -> NaN Invalid_operation +ddinv292 invert 1000001060001000 -> NaN Invalid_operation +ddinv293 invert 1000000170010000 -> NaN Invalid_operation +ddinv294 invert 1000000080100000 -> NaN Invalid_operation +ddinv295 invert 1000000091000000 -> NaN Invalid_operation +-- sign +ddinv296 invert -1000000001000000 -> NaN Invalid_operation +ddinv299 invert 1000000001000000 -> 111111110111111 + + +-- Nmax, Nmin, Ntiny-like +ddinv341 invert 9.99999999E+299 -> NaN Invalid_operation +ddinv342 invert 1E-299 -> NaN Invalid_operation +ddinv343 invert 1.00000000E-299 -> NaN Invalid_operation +ddinv344 invert 1E-207 -> NaN Invalid_operation +ddinv345 invert -1E-207 -> NaN Invalid_operation +ddinv346 invert -1.00000000E-299 -> NaN Invalid_operation +ddinv347 invert -1E-299 -> NaN Invalid_operation +ddinv348 invert -9.99999999E+299 -> NaN Invalid_operation + +-- A few other non-integers +ddinv361 invert 1.0 -> NaN Invalid_operation +ddinv362 invert 1E+1 -> NaN Invalid_operation +ddinv363 invert 0.0 -> NaN Invalid_operation +ddinv364 invert 0E+1 -> NaN Invalid_operation +ddinv365 invert 9.9 -> NaN Invalid_operation +ddinv366 invert 9E+1 -> NaN Invalid_operation + +-- All Specials are in error +ddinv788 invert -Inf -> NaN Invalid_operation +ddinv794 invert Inf -> NaN Invalid_operation +ddinv821 invert NaN -> NaN Invalid_operation +ddinv841 invert sNaN -> NaN Invalid_operation +-- propagating NaNs +ddinv861 invert NaN1 -> NaN Invalid_operation +ddinv862 invert +NaN2 -> NaN Invalid_operation +ddinv863 invert NaN3 -> NaN Invalid_operation +ddinv864 invert NaN4 -> NaN Invalid_operation +ddinv865 invert NaN5 -> NaN Invalid_operation +ddinv871 invert sNaN11 -> NaN Invalid_operation +ddinv872 invert sNaN12 -> NaN Invalid_operation +ddinv873 invert sNaN13 -> NaN Invalid_operation +ddinv874 invert sNaN14 -> NaN Invalid_operation +ddinv875 invert sNaN15 -> NaN Invalid_operation +ddinv876 invert NaN16 -> NaN Invalid_operation +ddinv881 invert +NaN25 -> NaN Invalid_operation +ddinv882 invert -NaN26 -> NaN Invalid_operation +ddinv883 invert -sNaN27 -> NaN Invalid_operation Added: python/branches/release25-maint/Lib/test/decimaltestdata/ddLogB.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/ddLogB.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,159 @@ +------------------------------------------------------------------------ +-- ddLogB.decTest -- integral 754r adjusted exponent, for decDoubles -- +-- Copyright (c) IBM Corporation, 2005, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +precision: 16 +maxExponent: 384 +minExponent: -383 +extended: 1 +clamp: 1 +rounding: half_even + +-- basics +ddlogb000 logb 0 -> -Infinity Division_by_zero +ddlogb001 logb 1E-398 -> -398 +ddlogb002 logb 1E-383 -> -383 +ddlogb003 logb 0.001 -> -3 +ddlogb004 logb 0.03 -> -2 +ddlogb005 logb 1 -> 0 +ddlogb006 logb 2 -> 0 +ddlogb007 logb 2.5 -> 0 +ddlogb008 logb 2.500 -> 0 +ddlogb009 logb 10 -> 1 +ddlogb010 logb 70 -> 1 +ddlogb011 logb 100 -> 2 +ddlogb012 logb 333 -> 2 +ddlogb013 logb 9E+384 -> 384 +ddlogb014 logb +Infinity -> Infinity + +-- negatives appear to be treated as positives +ddlogb021 logb -0 -> -Infinity Division_by_zero +ddlogb022 logb -1E-398 -> -398 +ddlogb023 logb -9E-383 -> -383 +ddlogb024 logb -0.001 -> -3 +ddlogb025 logb -1 -> 0 +ddlogb026 logb -2 -> 0 +ddlogb027 logb -10 -> 1 +ddlogb028 logb -70 -> 1 +ddlogb029 logb -100 -> 2 +ddlogb030 logb -9E+384 -> 384 +ddlogb031 logb -Infinity -> Infinity + +-- zeros +ddlogb111 logb 0 -> -Infinity Division_by_zero +ddlogb112 logb -0 -> -Infinity Division_by_zero +ddlogb113 logb 0E+4 -> -Infinity Division_by_zero +ddlogb114 logb -0E+4 -> -Infinity Division_by_zero +ddlogb115 logb 0.0000 -> -Infinity Division_by_zero +ddlogb116 logb -0.0000 -> -Infinity Division_by_zero +ddlogb117 logb 0E-141 -> -Infinity Division_by_zero +ddlogb118 logb -0E-141 -> -Infinity Division_by_zero + +-- full coefficients, alternating bits +ddlogb121 logb 268268268 -> 8 +ddlogb122 logb -268268268 -> 8 +ddlogb123 logb 134134134 -> 8 +ddlogb124 logb -134134134 -> 8 + +-- Nmax, Nmin, Ntiny +ddlogb131 logb 9.999999999999999E+384 -> 384 +ddlogb132 logb 1E-383 -> -383 +ddlogb133 logb 1.000000000000000E-383 -> -383 +ddlogb134 logb 1E-398 -> -398 + +ddlogb135 logb -1E-398 -> -398 +ddlogb136 logb -1.000000000000000E-383 -> -383 +ddlogb137 logb -1E-383 -> -383 +ddlogb138 logb -9.999999999999999E+384 -> 384 + +-- ones +ddlogb0061 logb 1 -> 0 +ddlogb0062 logb 1.0 -> 0 +ddlogb0063 logb 1.000000000000000 -> 0 + +-- notable cases -- exact powers of 10 +ddlogb1100 logb 1 -> 0 +ddlogb1101 logb 10 -> 1 +ddlogb1102 logb 100 -> 2 +ddlogb1103 logb 1000 -> 3 +ddlogb1104 logb 10000 -> 4 +ddlogb1105 logb 100000 -> 5 +ddlogb1106 logb 1000000 -> 6 +ddlogb1107 logb 10000000 -> 7 +ddlogb1108 logb 100000000 -> 8 +ddlogb1109 logb 1000000000 -> 9 +ddlogb1110 logb 10000000000 -> 10 +ddlogb1111 logb 100000000000 -> 11 +ddlogb1112 logb 1000000000000 -> 12 +ddlogb1113 logb 0.00000000001 -> -11 +ddlogb1114 logb 0.0000000001 -> -10 +ddlogb1115 logb 0.000000001 -> -9 +ddlogb1116 logb 0.00000001 -> -8 +ddlogb1117 logb 0.0000001 -> -7 +ddlogb1118 logb 0.000001 -> -6 +ddlogb1119 logb 0.00001 -> -5 +ddlogb1120 logb 0.0001 -> -4 +ddlogb1121 logb 0.001 -> -3 +ddlogb1122 logb 0.01 -> -2 +ddlogb1123 logb 0.1 -> -1 +ddlogb1124 logb 1E-99 -> -99 +ddlogb1125 logb 1E-100 -> -100 +ddlogb1127 logb 1E-299 -> -299 +ddlogb1126 logb 1E-383 -> -383 + +-- suggestions from Ilan Nehama +ddlogb1400 logb 10E-3 -> -2 +ddlogb1401 logb 10E-2 -> -1 +ddlogb1402 logb 100E-2 -> 0 +ddlogb1403 logb 1000E-2 -> 1 +ddlogb1404 logb 10000E-2 -> 2 +ddlogb1405 logb 10E-1 -> 0 +ddlogb1406 logb 100E-1 -> 1 +ddlogb1407 logb 1000E-1 -> 2 +ddlogb1408 logb 10000E-1 -> 3 +ddlogb1409 logb 10E0 -> 1 +ddlogb1410 logb 100E0 -> 2 +ddlogb1411 logb 1000E0 -> 3 +ddlogb1412 logb 10000E0 -> 4 +ddlogb1413 logb 10E1 -> 2 +ddlogb1414 logb 100E1 -> 3 +ddlogb1415 logb 1000E1 -> 4 +ddlogb1416 logb 10000E1 -> 5 +ddlogb1417 logb 10E2 -> 3 +ddlogb1418 logb 100E2 -> 4 +ddlogb1419 logb 1000E2 -> 5 +ddlogb1420 logb 10000E2 -> 6 + +-- special values +ddlogb820 logb Infinity -> Infinity +ddlogb821 logb 0 -> -Infinity Division_by_zero +ddlogb822 logb NaN -> NaN +ddlogb823 logb sNaN -> NaN Invalid_operation +-- propagating NaNs +ddlogb824 logb sNaN123 -> NaN123 Invalid_operation +ddlogb825 logb -sNaN321 -> -NaN321 Invalid_operation +ddlogb826 logb NaN456 -> NaN456 +ddlogb827 logb -NaN654 -> -NaN654 +ddlogb828 logb NaN1 -> NaN1 + +-- Null test +ddlogb900 logb # -> NaN Invalid_operation + + Added: python/branches/release25-maint/Lib/test/decimaltestdata/ddMax.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/ddMax.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,322 @@ +------------------------------------------------------------------------ +-- ddMax.decTest -- decDouble maxnum -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- we assume that base comparison is tested in compare.decTest, so +-- these mainly cover special cases and rounding +precision: 16 +maxExponent: 384 +minExponent: -383 +extended: 1 +clamp: 1 +rounding: half_even + +-- sanity checks +ddmax001 max -2 -2 -> -2 +ddmax002 max -2 -1 -> -1 +ddmax003 max -2 0 -> 0 +ddmax004 max -2 1 -> 1 +ddmax005 max -2 2 -> 2 +ddmax006 max -1 -2 -> -1 +ddmax007 max -1 -1 -> -1 +ddmax008 max -1 0 -> 0 +ddmax009 max -1 1 -> 1 +ddmax010 max -1 2 -> 2 +ddmax011 max 0 -2 -> 0 +ddmax012 max 0 -1 -> 0 +ddmax013 max 0 0 -> 0 +ddmax014 max 0 1 -> 1 +ddmax015 max 0 2 -> 2 +ddmax016 max 1 -2 -> 1 +ddmax017 max 1 -1 -> 1 +ddmax018 max 1 0 -> 1 +ddmax019 max 1 1 -> 1 +ddmax020 max 1 2 -> 2 +ddmax021 max 2 -2 -> 2 +ddmax022 max 2 -1 -> 2 +ddmax023 max 2 0 -> 2 +ddmax025 max 2 1 -> 2 +ddmax026 max 2 2 -> 2 + +-- extended zeros +ddmax030 max 0 0 -> 0 +ddmax031 max 0 -0 -> 0 +ddmax032 max 0 -0.0 -> 0 +ddmax033 max 0 0.0 -> 0 +ddmax034 max -0 0 -> 0 -- note: -0 = 0, but 0 chosen +ddmax035 max -0 -0 -> -0 +ddmax036 max -0 -0.0 -> -0.0 +ddmax037 max -0 0.0 -> 0.0 +ddmax038 max 0.0 0 -> 0 +ddmax039 max 0.0 -0 -> 0.0 +ddmax040 max 0.0 -0.0 -> 0.0 +ddmax041 max 0.0 0.0 -> 0.0 +ddmax042 max -0.0 0 -> 0 +ddmax043 max -0.0 -0 -> -0.0 +ddmax044 max -0.0 -0.0 -> -0.0 +ddmax045 max -0.0 0.0 -> 0.0 + +ddmax050 max -0E1 0E1 -> 0E+1 +ddmax051 max -0E2 0E2 -> 0E+2 +ddmax052 max -0E2 0E1 -> 0E+1 +ddmax053 max -0E1 0E2 -> 0E+2 +ddmax054 max 0E1 -0E1 -> 0E+1 +ddmax055 max 0E2 -0E2 -> 0E+2 +ddmax056 max 0E2 -0E1 -> 0E+2 +ddmax057 max 0E1 -0E2 -> 0E+1 + +ddmax058 max 0E1 0E1 -> 0E+1 +ddmax059 max 0E2 0E2 -> 0E+2 +ddmax060 max 0E2 0E1 -> 0E+2 +ddmax061 max 0E1 0E2 -> 0E+2 +ddmax062 max -0E1 -0E1 -> -0E+1 +ddmax063 max -0E2 -0E2 -> -0E+2 +ddmax064 max -0E2 -0E1 -> -0E+1 +ddmax065 max -0E1 -0E2 -> -0E+1 + +-- Specials +ddmax090 max Inf -Inf -> Infinity +ddmax091 max Inf -1000 -> Infinity +ddmax092 max Inf -1 -> Infinity +ddmax093 max Inf -0 -> Infinity +ddmax094 max Inf 0 -> Infinity +ddmax095 max Inf 1 -> Infinity +ddmax096 max Inf 1000 -> Infinity +ddmax097 max Inf Inf -> Infinity +ddmax098 max -1000 Inf -> Infinity +ddmax099 max -Inf Inf -> Infinity +ddmax100 max -1 Inf -> Infinity +ddmax101 max -0 Inf -> Infinity +ddmax102 max 0 Inf -> Infinity +ddmax103 max 1 Inf -> Infinity +ddmax104 max 1000 Inf -> Infinity +ddmax105 max Inf Inf -> Infinity + +ddmax120 max -Inf -Inf -> -Infinity +ddmax121 max -Inf -1000 -> -1000 +ddmax122 max -Inf -1 -> -1 +ddmax123 max -Inf -0 -> -0 +ddmax124 max -Inf 0 -> 0 +ddmax125 max -Inf 1 -> 1 +ddmax126 max -Inf 1000 -> 1000 +ddmax127 max -Inf Inf -> Infinity +ddmax128 max -Inf -Inf -> -Infinity +ddmax129 max -1000 -Inf -> -1000 +ddmax130 max -1 -Inf -> -1 +ddmax131 max -0 -Inf -> -0 +ddmax132 max 0 -Inf -> 0 +ddmax133 max 1 -Inf -> 1 +ddmax134 max 1000 -Inf -> 1000 +ddmax135 max Inf -Inf -> Infinity + +-- 2004.08.02 754r chooses number over NaN in mixed cases +ddmax141 max NaN -Inf -> -Infinity +ddmax142 max NaN -1000 -> -1000 +ddmax143 max NaN -1 -> -1 +ddmax144 max NaN -0 -> -0 +ddmax145 max NaN 0 -> 0 +ddmax146 max NaN 1 -> 1 +ddmax147 max NaN 1000 -> 1000 +ddmax148 max NaN Inf -> Infinity +ddmax149 max NaN NaN -> NaN +ddmax150 max -Inf NaN -> -Infinity +ddmax151 max -1000 NaN -> -1000 +ddmax152 max -1 NaN -> -1 +ddmax153 max -0 NaN -> -0 +ddmax154 max 0 NaN -> 0 +ddmax155 max 1 NaN -> 1 +ddmax156 max 1000 NaN -> 1000 +ddmax157 max Inf NaN -> Infinity + +ddmax161 max sNaN -Inf -> NaN Invalid_operation +ddmax162 max sNaN -1000 -> NaN Invalid_operation +ddmax163 max sNaN -1 -> NaN Invalid_operation +ddmax164 max sNaN -0 -> NaN Invalid_operation +ddmax165 max sNaN 0 -> NaN Invalid_operation +ddmax166 max sNaN 1 -> NaN Invalid_operation +ddmax167 max sNaN 1000 -> NaN Invalid_operation +ddmax168 max sNaN NaN -> NaN Invalid_operation +ddmax169 max sNaN sNaN -> NaN Invalid_operation +ddmax170 max NaN sNaN -> NaN Invalid_operation +ddmax171 max -Inf sNaN -> NaN Invalid_operation +ddmax172 max -1000 sNaN -> NaN Invalid_operation +ddmax173 max -1 sNaN -> NaN Invalid_operation +ddmax174 max -0 sNaN -> NaN Invalid_operation +ddmax175 max 0 sNaN -> NaN Invalid_operation +ddmax176 max 1 sNaN -> NaN Invalid_operation +ddmax177 max 1000 sNaN -> NaN Invalid_operation +ddmax178 max Inf sNaN -> NaN Invalid_operation +ddmax179 max NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +ddmax181 max NaN9 -Inf -> -Infinity +ddmax182 max NaN8 9 -> 9 +ddmax183 max -NaN7 Inf -> Infinity + +ddmax184 max -NaN1 NaN11 -> -NaN1 +ddmax185 max NaN2 NaN12 -> NaN2 +ddmax186 max -NaN13 -NaN7 -> -NaN13 +ddmax187 max NaN14 -NaN5 -> NaN14 + +ddmax188 max -Inf NaN4 -> -Infinity +ddmax189 max -9 -NaN3 -> -9 +ddmax190 max Inf NaN2 -> Infinity + +ddmax191 max sNaN99 -Inf -> NaN99 Invalid_operation +ddmax192 max sNaN98 -1 -> NaN98 Invalid_operation +ddmax193 max -sNaN97 NaN -> -NaN97 Invalid_operation +ddmax194 max sNaN96 sNaN94 -> NaN96 Invalid_operation +ddmax195 max NaN95 sNaN93 -> NaN93 Invalid_operation +ddmax196 max -Inf sNaN92 -> NaN92 Invalid_operation +ddmax197 max 0 sNaN91 -> NaN91 Invalid_operation +ddmax198 max Inf -sNaN90 -> -NaN90 Invalid_operation +ddmax199 max NaN sNaN89 -> NaN89 Invalid_operation + +-- old rounding checks +ddmax221 max 12345678000 1 -> 12345678000 +ddmax222 max 1 12345678000 -> 12345678000 +ddmax223 max 1234567800 1 -> 1234567800 +ddmax224 max 1 1234567800 -> 1234567800 +ddmax225 max 1234567890 1 -> 1234567890 +ddmax226 max 1 1234567890 -> 1234567890 +ddmax227 max 1234567891 1 -> 1234567891 +ddmax228 max 1 1234567891 -> 1234567891 +ddmax229 max 12345678901 1 -> 12345678901 +ddmax230 max 1 12345678901 -> 12345678901 +ddmax231 max 1234567896 1 -> 1234567896 +ddmax232 max 1 1234567896 -> 1234567896 +ddmax233 max -1234567891 1 -> 1 +ddmax234 max 1 -1234567891 -> 1 +ddmax235 max -12345678901 1 -> 1 +ddmax236 max 1 -12345678901 -> 1 +ddmax237 max -1234567896 1 -> 1 +ddmax238 max 1 -1234567896 -> 1 + +-- from examples +ddmax280 max '3' '2' -> '3' +ddmax281 max '-10' '3' -> '3' +ddmax282 max '1.0' '1' -> '1' +ddmax283 max '1' '1.0' -> '1' +ddmax284 max '7' 'NaN' -> '7' + +-- expanded list from min/max 754r purple prose +-- [explicit tests for exponent ordering] +ddmax401 max Inf 1.1 -> Infinity +ddmax402 max 1.1 1 -> 1.1 +ddmax403 max 1 1.0 -> 1 +ddmax404 max 1.0 0.1 -> 1.0 +ddmax405 max 0.1 0.10 -> 0.1 +ddmax406 max 0.10 0.100 -> 0.10 +ddmax407 max 0.10 0 -> 0.10 +ddmax408 max 0 0.0 -> 0 +ddmax409 max 0.0 -0 -> 0.0 +ddmax410 max 0.0 -0.0 -> 0.0 +ddmax411 max 0.00 -0.0 -> 0.00 +ddmax412 max 0.0 -0.00 -> 0.0 +ddmax413 max 0 -0.0 -> 0 +ddmax414 max 0 -0 -> 0 +ddmax415 max -0.0 -0 -> -0.0 +ddmax416 max -0 -0.100 -> -0 +ddmax417 max -0.100 -0.10 -> -0.100 +ddmax418 max -0.10 -0.1 -> -0.10 +ddmax419 max -0.1 -1.0 -> -0.1 +ddmax420 max -1.0 -1 -> -1.0 +ddmax421 max -1 -1.1 -> -1 +ddmax423 max -1.1 -Inf -> -1.1 +-- same with operands reversed +ddmax431 max 1.1 Inf -> Infinity +ddmax432 max 1 1.1 -> 1.1 +ddmax433 max 1.0 1 -> 1 +ddmax434 max 0.1 1.0 -> 1.0 +ddmax435 max 0.10 0.1 -> 0.1 +ddmax436 max 0.100 0.10 -> 0.10 +ddmax437 max 0 0.10 -> 0.10 +ddmax438 max 0.0 0 -> 0 +ddmax439 max -0 0.0 -> 0.0 +ddmax440 max -0.0 0.0 -> 0.0 +ddmax441 max -0.0 0.00 -> 0.00 +ddmax442 max -0.00 0.0 -> 0.0 +ddmax443 max -0.0 0 -> 0 +ddmax444 max -0 0 -> 0 +ddmax445 max -0 -0.0 -> -0.0 +ddmax446 max -0.100 -0 -> -0 +ddmax447 max -0.10 -0.100 -> -0.100 +ddmax448 max -0.1 -0.10 -> -0.10 +ddmax449 max -1.0 -0.1 -> -0.1 +ddmax450 max -1 -1.0 -> -1.0 +ddmax451 max -1.1 -1 -> -1 +ddmax453 max -Inf -1.1 -> -1.1 +-- largies +ddmax460 max 1000 1E+3 -> 1E+3 +ddmax461 max 1E+3 1000 -> 1E+3 +ddmax462 max 1000 -1E+3 -> 1000 +ddmax463 max 1E+3 -1000 -> 1E+3 +ddmax464 max -1000 1E+3 -> 1E+3 +ddmax465 max -1E+3 1000 -> 1000 +ddmax466 max -1000 -1E+3 -> -1000 +ddmax467 max -1E+3 -1000 -> -1000 + +-- misalignment traps for little-endian +ddmax471 max 1.0 0.1 -> 1.0 +ddmax472 max 0.1 1.0 -> 1.0 +ddmax473 max 10.0 0.1 -> 10.0 +ddmax474 max 0.1 10.0 -> 10.0 +ddmax475 max 100 1.0 -> 100 +ddmax476 max 1.0 100 -> 100 +ddmax477 max 1000 10.0 -> 1000 +ddmax478 max 10.0 1000 -> 1000 +ddmax479 max 10000 100.0 -> 10000 +ddmax480 max 100.0 10000 -> 10000 +ddmax481 max 100000 1000.0 -> 100000 +ddmax482 max 1000.0 100000 -> 100000 +ddmax483 max 1000000 10000.0 -> 1000000 +ddmax484 max 10000.0 1000000 -> 1000000 + +-- subnormals +ddmax510 max 1.00E-383 0 -> 1.00E-383 +ddmax511 max 0.1E-383 0 -> 1E-384 Subnormal +ddmax512 max 0.10E-383 0 -> 1.0E-384 Subnormal +ddmax513 max 0.100E-383 0 -> 1.00E-384 Subnormal +ddmax514 max 0.01E-383 0 -> 1E-385 Subnormal +ddmax515 max 0.999E-383 0 -> 9.99E-384 Subnormal +ddmax516 max 0.099E-383 0 -> 9.9E-385 Subnormal +ddmax517 max 0.009E-383 0 -> 9E-386 Subnormal +ddmax518 max 0.001E-383 0 -> 1E-386 Subnormal +ddmax519 max 0.0009E-383 0 -> 9E-387 Subnormal +ddmax520 max 0.0001E-383 0 -> 1E-387 Subnormal + +ddmax530 max -1.00E-383 0 -> 0 +ddmax531 max -0.1E-383 0 -> 0 +ddmax532 max -0.10E-383 0 -> 0 +ddmax533 max -0.100E-383 0 -> 0 +ddmax534 max -0.01E-383 0 -> 0 +ddmax535 max -0.999E-383 0 -> 0 +ddmax536 max -0.099E-383 0 -> 0 +ddmax537 max -0.009E-383 0 -> 0 +ddmax538 max -0.001E-383 0 -> 0 +ddmax539 max -0.0009E-383 0 -> 0 +ddmax540 max -0.0001E-383 0 -> 0 + +-- Null tests +ddmax900 max 10 # -> NaN Invalid_operation +ddmax901 max # 10 -> NaN Invalid_operation + + + Added: python/branches/release25-maint/Lib/test/decimaltestdata/ddMaxMag.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/ddMaxMag.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,304 @@ +------------------------------------------------------------------------ +-- ddMaxMag.decTest -- decDouble maxnummag -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- we assume that base comparison is tested in compare.decTest, so +-- these mainly cover special cases and rounding +precision: 16 +maxExponent: 384 +minExponent: -383 +extended: 1 +clamp: 1 +rounding: half_even + +-- sanity checks +ddmxg001 maxmag -2 -2 -> -2 +ddmxg002 maxmag -2 -1 -> -2 +ddmxg003 maxmag -2 0 -> -2 +ddmxg004 maxmag -2 1 -> -2 +ddmxg005 maxmag -2 2 -> 2 +ddmxg006 maxmag -1 -2 -> -2 +ddmxg007 maxmag -1 -1 -> -1 +ddmxg008 maxmag -1 0 -> -1 +ddmxg009 maxmag -1 1 -> 1 +ddmxg010 maxmag -1 2 -> 2 +ddmxg011 maxmag 0 -2 -> -2 +ddmxg012 maxmag 0 -1 -> -1 +ddmxg013 maxmag 0 0 -> 0 +ddmxg014 maxmag 0 1 -> 1 +ddmxg015 maxmag 0 2 -> 2 +ddmxg016 maxmag 1 -2 -> -2 +ddmxg017 maxmag 1 -1 -> 1 +ddmxg018 maxmag 1 0 -> 1 +ddmxg019 maxmag 1 1 -> 1 +ddmxg020 maxmag 1 2 -> 2 +ddmxg021 maxmag 2 -2 -> 2 +ddmxg022 maxmag 2 -1 -> 2 +ddmxg023 maxmag 2 0 -> 2 +ddmxg025 maxmag 2 1 -> 2 +ddmxg026 maxmag 2 2 -> 2 + +-- extended zeros +ddmxg030 maxmag 0 0 -> 0 +ddmxg031 maxmag 0 -0 -> 0 +ddmxg032 maxmag 0 -0.0 -> 0 +ddmxg033 maxmag 0 0.0 -> 0 +ddmxg034 maxmag -0 0 -> 0 -- note: -0 = 0, but 0 chosen +ddmxg035 maxmag -0 -0 -> -0 +ddmxg036 maxmag -0 -0.0 -> -0.0 +ddmxg037 maxmag -0 0.0 -> 0.0 +ddmxg038 maxmag 0.0 0 -> 0 +ddmxg039 maxmag 0.0 -0 -> 0.0 +ddmxg040 maxmag 0.0 -0.0 -> 0.0 +ddmxg041 maxmag 0.0 0.0 -> 0.0 +ddmxg042 maxmag -0.0 0 -> 0 +ddmxg043 maxmag -0.0 -0 -> -0.0 +ddmxg044 maxmag -0.0 -0.0 -> -0.0 +ddmxg045 maxmag -0.0 0.0 -> 0.0 + +ddmxg050 maxmag -0E1 0E1 -> 0E+1 +ddmxg051 maxmag -0E2 0E2 -> 0E+2 +ddmxg052 maxmag -0E2 0E1 -> 0E+1 +ddmxg053 maxmag -0E1 0E2 -> 0E+2 +ddmxg054 maxmag 0E1 -0E1 -> 0E+1 +ddmxg055 maxmag 0E2 -0E2 -> 0E+2 +ddmxg056 maxmag 0E2 -0E1 -> 0E+2 +ddmxg057 maxmag 0E1 -0E2 -> 0E+1 + +ddmxg058 maxmag 0E1 0E1 -> 0E+1 +ddmxg059 maxmag 0E2 0E2 -> 0E+2 +ddmxg060 maxmag 0E2 0E1 -> 0E+2 +ddmxg061 maxmag 0E1 0E2 -> 0E+2 +ddmxg062 maxmag -0E1 -0E1 -> -0E+1 +ddmxg063 maxmag -0E2 -0E2 -> -0E+2 +ddmxg064 maxmag -0E2 -0E1 -> -0E+1 +ddmxg065 maxmag -0E1 -0E2 -> -0E+1 + +-- Specials +ddmxg090 maxmag Inf -Inf -> Infinity +ddmxg091 maxmag Inf -1000 -> Infinity +ddmxg092 maxmag Inf -1 -> Infinity +ddmxg093 maxmag Inf -0 -> Infinity +ddmxg094 maxmag Inf 0 -> Infinity +ddmxg095 maxmag Inf 1 -> Infinity +ddmxg096 maxmag Inf 1000 -> Infinity +ddmxg097 maxmag Inf Inf -> Infinity +ddmxg098 maxmag -1000 Inf -> Infinity +ddmxg099 maxmag -Inf Inf -> Infinity +ddmxg100 maxmag -1 Inf -> Infinity +ddmxg101 maxmag -0 Inf -> Infinity +ddmxg102 maxmag 0 Inf -> Infinity +ddmxg103 maxmag 1 Inf -> Infinity +ddmxg104 maxmag 1000 Inf -> Infinity +ddmxg105 maxmag Inf Inf -> Infinity + +ddmxg120 maxmag -Inf -Inf -> -Infinity +ddmxg121 maxmag -Inf -1000 -> -Infinity +ddmxg122 maxmag -Inf -1 -> -Infinity +ddmxg123 maxmag -Inf -0 -> -Infinity +ddmxg124 maxmag -Inf 0 -> -Infinity +ddmxg125 maxmag -Inf 1 -> -Infinity +ddmxg126 maxmag -Inf 1000 -> -Infinity +ddmxg127 maxmag -Inf Inf -> Infinity +ddmxg128 maxmag -Inf -Inf -> -Infinity +ddmxg129 maxmag -1000 -Inf -> -Infinity +ddmxg130 maxmag -1 -Inf -> -Infinity +ddmxg131 maxmag -0 -Inf -> -Infinity +ddmxg132 maxmag 0 -Inf -> -Infinity +ddmxg133 maxmag 1 -Inf -> -Infinity +ddmxg134 maxmag 1000 -Inf -> -Infinity +ddmxg135 maxmag Inf -Inf -> Infinity + +-- 2004.08.02 754r chooses number over NaN in mixed cases +ddmxg141 maxmag NaN -Inf -> -Infinity +ddmxg142 maxmag NaN -1000 -> -1000 +ddmxg143 maxmag NaN -1 -> -1 +ddmxg144 maxmag NaN -0 -> -0 +ddmxg145 maxmag NaN 0 -> 0 +ddmxg146 maxmag NaN 1 -> 1 +ddmxg147 maxmag NaN 1000 -> 1000 +ddmxg148 maxmag NaN Inf -> Infinity +ddmxg149 maxmag NaN NaN -> NaN +ddmxg150 maxmag -Inf NaN -> -Infinity +ddmxg151 maxmag -1000 NaN -> -1000 +ddmxg152 maxmag -1 NaN -> -1 +ddmxg153 maxmag -0 NaN -> -0 +ddmxg154 maxmag 0 NaN -> 0 +ddmxg155 maxmag 1 NaN -> 1 +ddmxg156 maxmag 1000 NaN -> 1000 +ddmxg157 maxmag Inf NaN -> Infinity + +ddmxg161 maxmag sNaN -Inf -> NaN Invalid_operation +ddmxg162 maxmag sNaN -1000 -> NaN Invalid_operation +ddmxg163 maxmag sNaN -1 -> NaN Invalid_operation +ddmxg164 maxmag sNaN -0 -> NaN Invalid_operation +ddmxg165 maxmag sNaN 0 -> NaN Invalid_operation +ddmxg166 maxmag sNaN 1 -> NaN Invalid_operation +ddmxg167 maxmag sNaN 1000 -> NaN Invalid_operation +ddmxg168 maxmag sNaN NaN -> NaN Invalid_operation +ddmxg169 maxmag sNaN sNaN -> NaN Invalid_operation +ddmxg170 maxmag NaN sNaN -> NaN Invalid_operation +ddmxg171 maxmag -Inf sNaN -> NaN Invalid_operation +ddmxg172 maxmag -1000 sNaN -> NaN Invalid_operation +ddmxg173 maxmag -1 sNaN -> NaN Invalid_operation +ddmxg174 maxmag -0 sNaN -> NaN Invalid_operation +ddmxg175 maxmag 0 sNaN -> NaN Invalid_operation +ddmxg176 maxmag 1 sNaN -> NaN Invalid_operation +ddmxg177 maxmag 1000 sNaN -> NaN Invalid_operation +ddmxg178 maxmag Inf sNaN -> NaN Invalid_operation +ddmxg179 maxmag NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +ddmxg181 maxmag NaN9 -Inf -> -Infinity +ddmxg182 maxmag NaN8 9 -> 9 +ddmxg183 maxmag -NaN7 Inf -> Infinity + +ddmxg184 maxmag -NaN1 NaN11 -> -NaN1 +ddmxg185 maxmag NaN2 NaN12 -> NaN2 +ddmxg186 maxmag -NaN13 -NaN7 -> -NaN13 +ddmxg187 maxmag NaN14 -NaN5 -> NaN14 + +ddmxg188 maxmag -Inf NaN4 -> -Infinity +ddmxg189 maxmag -9 -NaN3 -> -9 +ddmxg190 maxmag Inf NaN2 -> Infinity + +ddmxg191 maxmag sNaN99 -Inf -> NaN99 Invalid_operation +ddmxg192 maxmag sNaN98 -1 -> NaN98 Invalid_operation +ddmxg193 maxmag -sNaN97 NaN -> -NaN97 Invalid_operation +ddmxg194 maxmag sNaN96 sNaN94 -> NaN96 Invalid_operation +ddmxg195 maxmag NaN95 sNaN93 -> NaN93 Invalid_operation +ddmxg196 maxmag -Inf sNaN92 -> NaN92 Invalid_operation +ddmxg197 maxmag 0 sNaN91 -> NaN91 Invalid_operation +ddmxg198 maxmag Inf -sNaN90 -> -NaN90 Invalid_operation +ddmxg199 maxmag NaN sNaN89 -> NaN89 Invalid_operation + +-- old rounding checks +ddmxg221 maxmag 12345678000 1 -> 12345678000 +ddmxg222 maxmag 1 12345678000 -> 12345678000 +ddmxg223 maxmag 1234567800 1 -> 1234567800 +ddmxg224 maxmag 1 1234567800 -> 1234567800 +ddmxg225 maxmag 1234567890 1 -> 1234567890 +ddmxg226 maxmag 1 1234567890 -> 1234567890 +ddmxg227 maxmag 1234567891 1 -> 1234567891 +ddmxg228 maxmag 1 1234567891 -> 1234567891 +ddmxg229 maxmag 12345678901 1 -> 12345678901 +ddmxg230 maxmag 1 12345678901 -> 12345678901 +ddmxg231 maxmag 1234567896 1 -> 1234567896 +ddmxg232 maxmag 1 1234567896 -> 1234567896 +ddmxg233 maxmag -1234567891 1 -> -1234567891 +ddmxg234 maxmag 1 -1234567891 -> -1234567891 +ddmxg235 maxmag -12345678901 1 -> -12345678901 +ddmxg236 maxmag 1 -12345678901 -> -12345678901 +ddmxg237 maxmag -1234567896 1 -> -1234567896 +ddmxg238 maxmag 1 -1234567896 -> -1234567896 + +-- from examples +ddmxg280 maxmag '3' '2' -> '3' +ddmxg281 maxmag '-10' '3' -> '-10' +ddmxg282 maxmag '1.0' '1' -> '1' +ddmxg283 maxmag '1' '1.0' -> '1' +ddmxg284 maxmag '7' 'NaN' -> '7' + +-- expanded list from min/max 754r purple prose +-- [explicit tests for exponent ordering] +ddmxg401 maxmag Inf 1.1 -> Infinity +ddmxg402 maxmag 1.1 1 -> 1.1 +ddmxg403 maxmag 1 1.0 -> 1 +ddmxg404 maxmag 1.0 0.1 -> 1.0 +ddmxg405 maxmag 0.1 0.10 -> 0.1 +ddmxg406 maxmag 0.10 0.100 -> 0.10 +ddmxg407 maxmag 0.10 0 -> 0.10 +ddmxg408 maxmag 0 0.0 -> 0 +ddmxg409 maxmag 0.0 -0 -> 0.0 +ddmxg410 maxmag 0.0 -0.0 -> 0.0 +ddmxg411 maxmag 0.00 -0.0 -> 0.00 +ddmxg412 maxmag 0.0 -0.00 -> 0.0 +ddmxg413 maxmag 0 -0.0 -> 0 +ddmxg414 maxmag 0 -0 -> 0 +ddmxg415 maxmag -0.0 -0 -> -0.0 +ddmxg416 maxmag -0 -0.100 -> -0.100 +ddmxg417 maxmag -0.100 -0.10 -> -0.100 +ddmxg418 maxmag -0.10 -0.1 -> -0.10 +ddmxg419 maxmag -0.1 -1.0 -> -1.0 +ddmxg420 maxmag -1.0 -1 -> -1.0 +ddmxg421 maxmag -1 -1.1 -> -1.1 +ddmxg423 maxmag -1.1 -Inf -> -Infinity +-- same with operands reversed +ddmxg431 maxmag 1.1 Inf -> Infinity +ddmxg432 maxmag 1 1.1 -> 1.1 +ddmxg433 maxmag 1.0 1 -> 1 +ddmxg434 maxmag 0.1 1.0 -> 1.0 +ddmxg435 maxmag 0.10 0.1 -> 0.1 +ddmxg436 maxmag 0.100 0.10 -> 0.10 +ddmxg437 maxmag 0 0.10 -> 0.10 +ddmxg438 maxmag 0.0 0 -> 0 +ddmxg439 maxmag -0 0.0 -> 0.0 +ddmxg440 maxmag -0.0 0.0 -> 0.0 +ddmxg441 maxmag -0.0 0.00 -> 0.00 +ddmxg442 maxmag -0.00 0.0 -> 0.0 +ddmxg443 maxmag -0.0 0 -> 0 +ddmxg444 maxmag -0 0 -> 0 +ddmxg445 maxmag -0 -0.0 -> -0.0 +ddmxg446 maxmag -0.100 -0 -> -0.100 +ddmxg447 maxmag -0.10 -0.100 -> -0.100 +ddmxg448 maxmag -0.1 -0.10 -> -0.10 +ddmxg449 maxmag -1.0 -0.1 -> -1.0 +ddmxg450 maxmag -1 -1.0 -> -1.0 +ddmxg451 maxmag -1.1 -1 -> -1.1 +ddmxg453 maxmag -Inf -1.1 -> -Infinity +-- largies +ddmxg460 maxmag 1000 1E+3 -> 1E+3 +ddmxg461 maxmag 1E+3 1000 -> 1E+3 +ddmxg462 maxmag 1000 -1E+3 -> 1000 +ddmxg463 maxmag 1E+3 -1000 -> 1E+3 +ddmxg464 maxmag -1000 1E+3 -> 1E+3 +ddmxg465 maxmag -1E+3 1000 -> 1000 +ddmxg466 maxmag -1000 -1E+3 -> -1000 +ddmxg467 maxmag -1E+3 -1000 -> -1000 + +-- subnormals +ddmxg510 maxmag 1.00E-383 0 -> 1.00E-383 +ddmxg511 maxmag 0.1E-383 0 -> 1E-384 Subnormal +ddmxg512 maxmag 0.10E-383 0 -> 1.0E-384 Subnormal +ddmxg513 maxmag 0.100E-383 0 -> 1.00E-384 Subnormal +ddmxg514 maxmag 0.01E-383 0 -> 1E-385 Subnormal +ddmxg515 maxmag 0.999E-383 0 -> 9.99E-384 Subnormal +ddmxg516 maxmag 0.099E-383 0 -> 9.9E-385 Subnormal +ddmxg517 maxmag 0.009E-383 0 -> 9E-386 Subnormal +ddmxg518 maxmag 0.001E-383 0 -> 1E-386 Subnormal +ddmxg519 maxmag 0.0009E-383 0 -> 9E-387 Subnormal +ddmxg520 maxmag 0.0001E-383 0 -> 1E-387 Subnormal + +ddmxg530 maxmag -1.00E-383 0 -> -1.00E-383 +ddmxg531 maxmag -0.1E-383 0 -> -1E-384 Subnormal +ddmxg532 maxmag -0.10E-383 0 -> -1.0E-384 Subnormal +ddmxg533 maxmag -0.100E-383 0 -> -1.00E-384 Subnormal +ddmxg534 maxmag -0.01E-383 0 -> -1E-385 Subnormal +ddmxg535 maxmag -0.999E-383 0 -> -9.99E-384 Subnormal +ddmxg536 maxmag -0.099E-383 0 -> -9.9E-385 Subnormal +ddmxg537 maxmag -0.009E-383 0 -> -9E-386 Subnormal +ddmxg538 maxmag -0.001E-383 0 -> -1E-386 Subnormal +ddmxg539 maxmag -0.0009E-383 0 -> -9E-387 Subnormal +ddmxg540 maxmag -0.0001E-383 0 -> -1E-387 Subnormal + +-- Null tests +ddmxg900 maxmag 10 # -> NaN Invalid_operation +ddmxg901 maxmag # 10 -> NaN Invalid_operation + Added: python/branches/release25-maint/Lib/test/decimaltestdata/ddMin.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/ddMin.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,309 @@ +------------------------------------------------------------------------ +-- ddMin.decTest -- decDouble minnum -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- we assume that base comparison is tested in compare.decTest, so +-- these mainly cover special cases and rounding +precision: 16 +maxExponent: 384 +minExponent: -383 +extended: 1 +clamp: 1 +rounding: half_even + +-- sanity checks +ddmin001 min -2 -2 -> -2 +ddmin002 min -2 -1 -> -2 +ddmin003 min -2 0 -> -2 +ddmin004 min -2 1 -> -2 +ddmin005 min -2 2 -> -2 +ddmin006 min -1 -2 -> -2 +ddmin007 min -1 -1 -> -1 +ddmin008 min -1 0 -> -1 +ddmin009 min -1 1 -> -1 +ddmin010 min -1 2 -> -1 +ddmin011 min 0 -2 -> -2 +ddmin012 min 0 -1 -> -1 +ddmin013 min 0 0 -> 0 +ddmin014 min 0 1 -> 0 +ddmin015 min 0 2 -> 0 +ddmin016 min 1 -2 -> -2 +ddmin017 min 1 -1 -> -1 +ddmin018 min 1 0 -> 0 +ddmin019 min 1 1 -> 1 +ddmin020 min 1 2 -> 1 +ddmin021 min 2 -2 -> -2 +ddmin022 min 2 -1 -> -1 +ddmin023 min 2 0 -> 0 +ddmin025 min 2 1 -> 1 +ddmin026 min 2 2 -> 2 + +-- extended zeros +ddmin030 min 0 0 -> 0 +ddmin031 min 0 -0 -> -0 +ddmin032 min 0 -0.0 -> -0.0 +ddmin033 min 0 0.0 -> 0.0 +ddmin034 min -0 0 -> -0 +ddmin035 min -0 -0 -> -0 +ddmin036 min -0 -0.0 -> -0 +ddmin037 min -0 0.0 -> -0 +ddmin038 min 0.0 0 -> 0.0 +ddmin039 min 0.0 -0 -> -0 +ddmin040 min 0.0 -0.0 -> -0.0 +ddmin041 min 0.0 0.0 -> 0.0 +ddmin042 min -0.0 0 -> -0.0 +ddmin043 min -0.0 -0 -> -0 +ddmin044 min -0.0 -0.0 -> -0.0 +ddmin045 min -0.0 0.0 -> -0.0 + +ddmin046 min 0E1 -0E1 -> -0E+1 +ddmin047 min -0E1 0E2 -> -0E+1 +ddmin048 min 0E2 0E1 -> 0E+1 +ddmin049 min 0E1 0E2 -> 0E+1 +ddmin050 min -0E3 -0E2 -> -0E+3 +ddmin051 min -0E2 -0E3 -> -0E+3 + +-- Specials +ddmin090 min Inf -Inf -> -Infinity +ddmin091 min Inf -1000 -> -1000 +ddmin092 min Inf -1 -> -1 +ddmin093 min Inf -0 -> -0 +ddmin094 min Inf 0 -> 0 +ddmin095 min Inf 1 -> 1 +ddmin096 min Inf 1000 -> 1000 +ddmin097 min Inf Inf -> Infinity +ddmin098 min -1000 Inf -> -1000 +ddmin099 min -Inf Inf -> -Infinity +ddmin100 min -1 Inf -> -1 +ddmin101 min -0 Inf -> -0 +ddmin102 min 0 Inf -> 0 +ddmin103 min 1 Inf -> 1 +ddmin104 min 1000 Inf -> 1000 +ddmin105 min Inf Inf -> Infinity + +ddmin120 min -Inf -Inf -> -Infinity +ddmin121 min -Inf -1000 -> -Infinity +ddmin122 min -Inf -1 -> -Infinity +ddmin123 min -Inf -0 -> -Infinity +ddmin124 min -Inf 0 -> -Infinity +ddmin125 min -Inf 1 -> -Infinity +ddmin126 min -Inf 1000 -> -Infinity +ddmin127 min -Inf Inf -> -Infinity +ddmin128 min -Inf -Inf -> -Infinity +ddmin129 min -1000 -Inf -> -Infinity +ddmin130 min -1 -Inf -> -Infinity +ddmin131 min -0 -Inf -> -Infinity +ddmin132 min 0 -Inf -> -Infinity +ddmin133 min 1 -Inf -> -Infinity +ddmin134 min 1000 -Inf -> -Infinity +ddmin135 min Inf -Inf -> -Infinity + +-- 2004.08.02 754r chooses number over NaN in mixed cases +ddmin141 min NaN -Inf -> -Infinity +ddmin142 min NaN -1000 -> -1000 +ddmin143 min NaN -1 -> -1 +ddmin144 min NaN -0 -> -0 +ddmin145 min NaN 0 -> 0 +ddmin146 min NaN 1 -> 1 +ddmin147 min NaN 1000 -> 1000 +ddmin148 min NaN Inf -> Infinity +ddmin149 min NaN NaN -> NaN +ddmin150 min -Inf NaN -> -Infinity +ddmin151 min -1000 NaN -> -1000 +ddmin152 min -1 -NaN -> -1 +ddmin153 min -0 NaN -> -0 +ddmin154 min 0 -NaN -> 0 +ddmin155 min 1 NaN -> 1 +ddmin156 min 1000 NaN -> 1000 +ddmin157 min Inf NaN -> Infinity + +ddmin161 min sNaN -Inf -> NaN Invalid_operation +ddmin162 min sNaN -1000 -> NaN Invalid_operation +ddmin163 min sNaN -1 -> NaN Invalid_operation +ddmin164 min sNaN -0 -> NaN Invalid_operation +ddmin165 min -sNaN 0 -> -NaN Invalid_operation +ddmin166 min -sNaN 1 -> -NaN Invalid_operation +ddmin167 min sNaN 1000 -> NaN Invalid_operation +ddmin168 min sNaN NaN -> NaN Invalid_operation +ddmin169 min sNaN sNaN -> NaN Invalid_operation +ddmin170 min NaN sNaN -> NaN Invalid_operation +ddmin171 min -Inf sNaN -> NaN Invalid_operation +ddmin172 min -1000 sNaN -> NaN Invalid_operation +ddmin173 min -1 sNaN -> NaN Invalid_operation +ddmin174 min -0 sNaN -> NaN Invalid_operation +ddmin175 min 0 sNaN -> NaN Invalid_operation +ddmin176 min 1 sNaN -> NaN Invalid_operation +ddmin177 min 1000 sNaN -> NaN Invalid_operation +ddmin178 min Inf sNaN -> NaN Invalid_operation +ddmin179 min NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +ddmin181 min NaN9 -Inf -> -Infinity +ddmin182 min -NaN8 9990 -> 9990 +ddmin183 min NaN71 Inf -> Infinity + +ddmin184 min NaN1 NaN54 -> NaN1 +ddmin185 min NaN22 -NaN53 -> NaN22 +ddmin186 min -NaN3 NaN6 -> -NaN3 +ddmin187 min -NaN44 NaN7 -> -NaN44 + +ddmin188 min -Inf NaN41 -> -Infinity +ddmin189 min -9999 -NaN33 -> -9999 +ddmin190 min Inf NaN2 -> Infinity + +ddmin191 min sNaN99 -Inf -> NaN99 Invalid_operation +ddmin192 min sNaN98 -11 -> NaN98 Invalid_operation +ddmin193 min -sNaN97 NaN8 -> -NaN97 Invalid_operation +ddmin194 min sNaN69 sNaN94 -> NaN69 Invalid_operation +ddmin195 min NaN95 sNaN93 -> NaN93 Invalid_operation +ddmin196 min -Inf sNaN92 -> NaN92 Invalid_operation +ddmin197 min 088 sNaN91 -> NaN91 Invalid_operation +ddmin198 min Inf -sNaN90 -> -NaN90 Invalid_operation +ddmin199 min NaN sNaN86 -> NaN86 Invalid_operation + +-- old rounding checks +ddmin221 min -12345678000 1 -> -12345678000 +ddmin222 min 1 -12345678000 -> -12345678000 +ddmin223 min -1234567800 1 -> -1234567800 +ddmin224 min 1 -1234567800 -> -1234567800 +ddmin225 min -1234567890 1 -> -1234567890 +ddmin226 min 1 -1234567890 -> -1234567890 +ddmin227 min -1234567891 1 -> -1234567891 +ddmin228 min 1 -1234567891 -> -1234567891 +ddmin229 min -12345678901 1 -> -12345678901 +ddmin230 min 1 -12345678901 -> -12345678901 +ddmin231 min -1234567896 1 -> -1234567896 +ddmin232 min 1 -1234567896 -> -1234567896 +ddmin233 min 1234567891 1 -> 1 +ddmin234 min 1 1234567891 -> 1 +ddmin235 min 12345678901 1 -> 1 +ddmin236 min 1 12345678901 -> 1 +ddmin237 min 1234567896 1 -> 1 +ddmin238 min 1 1234567896 -> 1 + +-- from examples +ddmin280 min '3' '2' -> '2' +ddmin281 min '-10' '3' -> '-10' +ddmin282 min '1.0' '1' -> '1.0' +ddmin283 min '1' '1.0' -> '1.0' +ddmin284 min '7' 'NaN' -> '7' + +-- expanded list from min/max 754r purple prose +-- [explicit tests for exponent ordering] +ddmin401 min Inf 1.1 -> 1.1 +ddmin402 min 1.1 1 -> 1 +ddmin403 min 1 1.0 -> 1.0 +ddmin404 min 1.0 0.1 -> 0.1 +ddmin405 min 0.1 0.10 -> 0.10 +ddmin406 min 0.10 0.100 -> 0.100 +ddmin407 min 0.10 0 -> 0 +ddmin408 min 0 0.0 -> 0.0 +ddmin409 min 0.0 -0 -> -0 +ddmin410 min 0.0 -0.0 -> -0.0 +ddmin411 min 0.00 -0.0 -> -0.0 +ddmin412 min 0.0 -0.00 -> -0.00 +ddmin413 min 0 -0.0 -> -0.0 +ddmin414 min 0 -0 -> -0 +ddmin415 min -0.0 -0 -> -0 +ddmin416 min -0 -0.100 -> -0.100 +ddmin417 min -0.100 -0.10 -> -0.10 +ddmin418 min -0.10 -0.1 -> -0.1 +ddmin419 min -0.1 -1.0 -> -1.0 +ddmin420 min -1.0 -1 -> -1 +ddmin421 min -1 -1.1 -> -1.1 +ddmin423 min -1.1 -Inf -> -Infinity +-- same with operands reversed +ddmin431 min 1.1 Inf -> 1.1 +ddmin432 min 1 1.1 -> 1 +ddmin433 min 1.0 1 -> 1.0 +ddmin434 min 0.1 1.0 -> 0.1 +ddmin435 min 0.10 0.1 -> 0.10 +ddmin436 min 0.100 0.10 -> 0.100 +ddmin437 min 0 0.10 -> 0 +ddmin438 min 0.0 0 -> 0.0 +ddmin439 min -0 0.0 -> -0 +ddmin440 min -0.0 0.0 -> -0.0 +ddmin441 min -0.0 0.00 -> -0.0 +ddmin442 min -0.00 0.0 -> -0.00 +ddmin443 min -0.0 0 -> -0.0 +ddmin444 min -0 0 -> -0 +ddmin445 min -0 -0.0 -> -0 +ddmin446 min -0.100 -0 -> -0.100 +ddmin447 min -0.10 -0.100 -> -0.10 +ddmin448 min -0.1 -0.10 -> -0.1 +ddmin449 min -1.0 -0.1 -> -1.0 +ddmin450 min -1 -1.0 -> -1 +ddmin451 min -1.1 -1 -> -1.1 +ddmin453 min -Inf -1.1 -> -Infinity +-- largies +ddmin460 min 1000 1E+3 -> 1000 +ddmin461 min 1E+3 1000 -> 1000 +ddmin462 min 1000 -1E+3 -> -1E+3 +ddmin463 min 1E+3 -384 -> -384 +ddmin464 min -384 1E+3 -> -384 +ddmin465 min -1E+3 1000 -> -1E+3 +ddmin466 min -384 -1E+3 -> -1E+3 +ddmin467 min -1E+3 -384 -> -1E+3 + +-- misalignment traps for little-endian +ddmin471 min 1.0 0.1 -> 0.1 +ddmin472 min 0.1 1.0 -> 0.1 +ddmin473 min 10.0 0.1 -> 0.1 +ddmin474 min 0.1 10.0 -> 0.1 +ddmin475 min 100 1.0 -> 1.0 +ddmin476 min 1.0 100 -> 1.0 +ddmin477 min 1000 10.0 -> 10.0 +ddmin478 min 10.0 1000 -> 10.0 +ddmin479 min 10000 100.0 -> 100.0 +ddmin480 min 100.0 10000 -> 100.0 +ddmin481 min 100000 1000.0 -> 1000.0 +ddmin482 min 1000.0 100000 -> 1000.0 +ddmin483 min 1000000 10000.0 -> 10000.0 +ddmin484 min 10000.0 1000000 -> 10000.0 + +-- subnormals +ddmin510 min 1.00E-383 0 -> 0 +ddmin511 min 0.1E-383 0 -> 0 +ddmin512 min 0.10E-383 0 -> 0 +ddmin513 min 0.100E-383 0 -> 0 +ddmin514 min 0.01E-383 0 -> 0 +ddmin515 min 0.999E-383 0 -> 0 +ddmin516 min 0.099E-383 0 -> 0 +ddmin517 min 0.009E-383 0 -> 0 +ddmin518 min 0.001E-383 0 -> 0 +ddmin519 min 0.0009E-383 0 -> 0 +ddmin520 min 0.0001E-383 0 -> 0 + +ddmin530 min -1.00E-383 0 -> -1.00E-383 +ddmin531 min -0.1E-383 0 -> -1E-384 Subnormal +ddmin532 min -0.10E-383 0 -> -1.0E-384 Subnormal +ddmin533 min -0.100E-383 0 -> -1.00E-384 Subnormal +ddmin534 min -0.01E-383 0 -> -1E-385 Subnormal +ddmin535 min -0.999E-383 0 -> -9.99E-384 Subnormal +ddmin536 min -0.099E-383 0 -> -9.9E-385 Subnormal +ddmin537 min -0.009E-383 0 -> -9E-386 Subnormal +ddmin538 min -0.001E-383 0 -> -1E-386 Subnormal +ddmin539 min -0.0009E-383 0 -> -9E-387 Subnormal +ddmin540 min -0.0001E-383 0 -> -1E-387 Subnormal + + +-- Null tests +ddmin900 min 10 # -> NaN Invalid_operation +ddmin901 min # 10 -> NaN Invalid_operation Added: python/branches/release25-maint/Lib/test/decimaltestdata/ddMinMag.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/ddMinMag.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,293 @@ +------------------------------------------------------------------------ +-- ddMinMag.decTest -- decDouble minnummag -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- we assume that base comparison is tested in compare.decTest, so +-- these mainly cover special cases and rounding +precision: 16 +maxExponent: 384 +minExponent: -383 +extended: 1 +clamp: 1 +rounding: half_even + +-- sanity checks +ddmng001 minmag -2 -2 -> -2 +ddmng002 minmag -2 -1 -> -1 +ddmng003 minmag -2 0 -> 0 +ddmng004 minmag -2 1 -> 1 +ddmng005 minmag -2 2 -> -2 +ddmng006 minmag -1 -2 -> -1 +ddmng007 minmag -1 -1 -> -1 +ddmng008 minmag -1 0 -> 0 +ddmng009 minmag -1 1 -> -1 +ddmng010 minmag -1 2 -> -1 +ddmng011 minmag 0 -2 -> 0 +ddmng012 minmag 0 -1 -> 0 +ddmng013 minmag 0 0 -> 0 +ddmng014 minmag 0 1 -> 0 +ddmng015 minmag 0 2 -> 0 +ddmng016 minmag 1 -2 -> 1 +ddmng017 minmag 1 -1 -> -1 +ddmng018 minmag 1 0 -> 0 +ddmng019 minmag 1 1 -> 1 +ddmng020 minmag 1 2 -> 1 +ddmng021 minmag 2 -2 -> -2 +ddmng022 minmag 2 -1 -> -1 +ddmng023 minmag 2 0 -> 0 +ddmng025 minmag 2 1 -> 1 +ddmng026 minmag 2 2 -> 2 + +-- extended zeros +ddmng030 minmag 0 0 -> 0 +ddmng031 minmag 0 -0 -> -0 +ddmng032 minmag 0 -0.0 -> -0.0 +ddmng033 minmag 0 0.0 -> 0.0 +ddmng034 minmag -0 0 -> -0 +ddmng035 minmag -0 -0 -> -0 +ddmng036 minmag -0 -0.0 -> -0 +ddmng037 minmag -0 0.0 -> -0 +ddmng038 minmag 0.0 0 -> 0.0 +ddmng039 minmag 0.0 -0 -> -0 +ddmng040 minmag 0.0 -0.0 -> -0.0 +ddmng041 minmag 0.0 0.0 -> 0.0 +ddmng042 minmag -0.0 0 -> -0.0 +ddmng043 minmag -0.0 -0 -> -0 +ddmng044 minmag -0.0 -0.0 -> -0.0 +ddmng045 minmag -0.0 0.0 -> -0.0 + +ddmng046 minmag 0E1 -0E1 -> -0E+1 +ddmng047 minmag -0E1 0E2 -> -0E+1 +ddmng048 minmag 0E2 0E1 -> 0E+1 +ddmng049 minmag 0E1 0E2 -> 0E+1 +ddmng050 minmag -0E3 -0E2 -> -0E+3 +ddmng051 minmag -0E2 -0E3 -> -0E+3 + +-- Specials +ddmng090 minmag Inf -Inf -> -Infinity +ddmng091 minmag Inf -1000 -> -1000 +ddmng092 minmag Inf -1 -> -1 +ddmng093 minmag Inf -0 -> -0 +ddmng094 minmag Inf 0 -> 0 +ddmng095 minmag Inf 1 -> 1 +ddmng096 minmag Inf 1000 -> 1000 +ddmng097 minmag Inf Inf -> Infinity +ddmng098 minmag -1000 Inf -> -1000 +ddmng099 minmag -Inf Inf -> -Infinity +ddmng100 minmag -1 Inf -> -1 +ddmng101 minmag -0 Inf -> -0 +ddmng102 minmag 0 Inf -> 0 +ddmng103 minmag 1 Inf -> 1 +ddmng104 minmag 1000 Inf -> 1000 +ddmng105 minmag Inf Inf -> Infinity + +ddmng120 minmag -Inf -Inf -> -Infinity +ddmng121 minmag -Inf -1000 -> -1000 +ddmng122 minmag -Inf -1 -> -1 +ddmng123 minmag -Inf -0 -> -0 +ddmng124 minmag -Inf 0 -> 0 +ddmng125 minmag -Inf 1 -> 1 +ddmng126 minmag -Inf 1000 -> 1000 +ddmng127 minmag -Inf Inf -> -Infinity +ddmng128 minmag -Inf -Inf -> -Infinity +ddmng129 minmag -1000 -Inf -> -1000 +ddmng130 minmag -1 -Inf -> -1 +ddmng131 minmag -0 -Inf -> -0 +ddmng132 minmag 0 -Inf -> 0 +ddmng133 minmag 1 -Inf -> 1 +ddmng134 minmag 1000 -Inf -> 1000 +ddmng135 minmag Inf -Inf -> -Infinity + +-- 2004.08.02 754r chooses number over NaN in mixed cases +ddmng141 minmag NaN -Inf -> -Infinity +ddmng142 minmag NaN -1000 -> -1000 +ddmng143 minmag NaN -1 -> -1 +ddmng144 minmag NaN -0 -> -0 +ddmng145 minmag NaN 0 -> 0 +ddmng146 minmag NaN 1 -> 1 +ddmng147 minmag NaN 1000 -> 1000 +ddmng148 minmag NaN Inf -> Infinity +ddmng149 minmag NaN NaN -> NaN +ddmng150 minmag -Inf NaN -> -Infinity +ddmng151 minmag -1000 NaN -> -1000 +ddmng152 minmag -1 -NaN -> -1 +ddmng153 minmag -0 NaN -> -0 +ddmng154 minmag 0 -NaN -> 0 +ddmng155 minmag 1 NaN -> 1 +ddmng156 minmag 1000 NaN -> 1000 +ddmng157 minmag Inf NaN -> Infinity + +ddmng161 minmag sNaN -Inf -> NaN Invalid_operation +ddmng162 minmag sNaN -1000 -> NaN Invalid_operation +ddmng163 minmag sNaN -1 -> NaN Invalid_operation +ddmng164 minmag sNaN -0 -> NaN Invalid_operation +ddmng165 minmag -sNaN 0 -> -NaN Invalid_operation +ddmng166 minmag -sNaN 1 -> -NaN Invalid_operation +ddmng167 minmag sNaN 1000 -> NaN Invalid_operation +ddmng168 minmag sNaN NaN -> NaN Invalid_operation +ddmng169 minmag sNaN sNaN -> NaN Invalid_operation +ddmng170 minmag NaN sNaN -> NaN Invalid_operation +ddmng171 minmag -Inf sNaN -> NaN Invalid_operation +ddmng172 minmag -1000 sNaN -> NaN Invalid_operation +ddmng173 minmag -1 sNaN -> NaN Invalid_operation +ddmng174 minmag -0 sNaN -> NaN Invalid_operation +ddmng175 minmag 0 sNaN -> NaN Invalid_operation +ddmng176 minmag 1 sNaN -> NaN Invalid_operation +ddmng177 minmag 1000 sNaN -> NaN Invalid_operation +ddmng178 minmag Inf sNaN -> NaN Invalid_operation +ddmng179 minmag NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +ddmng181 minmag NaN9 -Inf -> -Infinity +ddmng182 minmag -NaN8 9990 -> 9990 +ddmng183 minmag NaN71 Inf -> Infinity + +ddmng184 minmag NaN1 NaN54 -> NaN1 +ddmng185 minmag NaN22 -NaN53 -> NaN22 +ddmng186 minmag -NaN3 NaN6 -> -NaN3 +ddmng187 minmag -NaN44 NaN7 -> -NaN44 + +ddmng188 minmag -Inf NaN41 -> -Infinity +ddmng189 minmag -9999 -NaN33 -> -9999 +ddmng190 minmag Inf NaN2 -> Infinity + +ddmng191 minmag sNaN99 -Inf -> NaN99 Invalid_operation +ddmng192 minmag sNaN98 -11 -> NaN98 Invalid_operation +ddmng193 minmag -sNaN97 NaN8 -> -NaN97 Invalid_operation +ddmng194 minmag sNaN69 sNaN94 -> NaN69 Invalid_operation +ddmng195 minmag NaN95 sNaN93 -> NaN93 Invalid_operation +ddmng196 minmag -Inf sNaN92 -> NaN92 Invalid_operation +ddmng197 minmag 088 sNaN91 -> NaN91 Invalid_operation +ddmng198 minmag Inf -sNaN90 -> -NaN90 Invalid_operation +ddmng199 minmag NaN sNaN86 -> NaN86 Invalid_operation + +-- old rounding checks +ddmng221 minmag -12345678000 1 -> 1 +ddmng222 minmag 1 -12345678000 -> 1 +ddmng223 minmag -1234567800 1 -> 1 +ddmng224 minmag 1 -1234567800 -> 1 +ddmng225 minmag -1234567890 1 -> 1 +ddmng226 minmag 1 -1234567890 -> 1 +ddmng227 minmag -1234567891 1 -> 1 +ddmng228 minmag 1 -1234567891 -> 1 +ddmng229 minmag -12345678901 1 -> 1 +ddmng230 minmag 1 -12345678901 -> 1 +ddmng231 minmag -1234567896 1 -> 1 +ddmng232 minmag 1 -1234567896 -> 1 +ddmng233 minmag 1234567891 1 -> 1 +ddmng234 minmag 1 1234567891 -> 1 +ddmng235 minmag 12345678901 1 -> 1 +ddmng236 minmag 1 12345678901 -> 1 +ddmng237 minmag 1234567896 1 -> 1 +ddmng238 minmag 1 1234567896 -> 1 + +-- from examples +ddmng280 minmag '3' '2' -> '2' +ddmng281 minmag '-10' '3' -> '3' +ddmng282 minmag '1.0' '1' -> '1.0' +ddmng283 minmag '1' '1.0' -> '1.0' +ddmng284 minmag '7' 'NaN' -> '7' + +-- expanded list from min/max 754r purple prose +-- [explicit tests for exponent ordering] +ddmng401 minmag Inf 1.1 -> 1.1 +ddmng402 minmag 1.1 1 -> 1 +ddmng403 minmag 1 1.0 -> 1.0 +ddmng404 minmag 1.0 0.1 -> 0.1 +ddmng405 minmag 0.1 0.10 -> 0.10 +ddmng406 minmag 0.10 0.100 -> 0.100 +ddmng407 minmag 0.10 0 -> 0 +ddmng408 minmag 0 0.0 -> 0.0 +ddmng409 minmag 0.0 -0 -> -0 +ddmng410 minmag 0.0 -0.0 -> -0.0 +ddmng411 minmag 0.00 -0.0 -> -0.0 +ddmng412 minmag 0.0 -0.00 -> -0.00 +ddmng413 minmag 0 -0.0 -> -0.0 +ddmng414 minmag 0 -0 -> -0 +ddmng415 minmag -0.0 -0 -> -0 +ddmng416 minmag -0 -0.100 -> -0 +ddmng417 minmag -0.100 -0.10 -> -0.10 +ddmng418 minmag -0.10 -0.1 -> -0.1 +ddmng419 minmag -0.1 -1.0 -> -0.1 +ddmng420 minmag -1.0 -1 -> -1 +ddmng421 minmag -1 -1.1 -> -1 +ddmng423 minmag -1.1 -Inf -> -1.1 +-- same with operands reversed +ddmng431 minmag 1.1 Inf -> 1.1 +ddmng432 minmag 1 1.1 -> 1 +ddmng433 minmag 1.0 1 -> 1.0 +ddmng434 minmag 0.1 1.0 -> 0.1 +ddmng435 minmag 0.10 0.1 -> 0.10 +ddmng436 minmag 0.100 0.10 -> 0.100 +ddmng437 minmag 0 0.10 -> 0 +ddmng438 minmag 0.0 0 -> 0.0 +ddmng439 minmag -0 0.0 -> -0 +ddmng440 minmag -0.0 0.0 -> -0.0 +ddmng441 minmag -0.0 0.00 -> -0.0 +ddmng442 minmag -0.00 0.0 -> -0.00 +ddmng443 minmag -0.0 0 -> -0.0 +ddmng444 minmag -0 0 -> -0 +ddmng445 minmag -0 -0.0 -> -0 +ddmng446 minmag -0.100 -0 -> -0 +ddmng447 minmag -0.10 -0.100 -> -0.10 +ddmng448 minmag -0.1 -0.10 -> -0.1 +ddmng449 minmag -1.0 -0.1 -> -0.1 +ddmng450 minmag -1 -1.0 -> -1 +ddmng451 minmag -1.1 -1 -> -1 +ddmng453 minmag -Inf -1.1 -> -1.1 +-- largies +ddmng460 minmag 1000 1E+3 -> 1000 +ddmng461 minmag 1E+3 1000 -> 1000 +ddmng462 minmag 1000 -1E+3 -> -1E+3 +ddmng463 minmag 1E+3 -384 -> -384 +ddmng464 minmag -384 1E+3 -> -384 +ddmng465 minmag -1E+3 1000 -> -1E+3 +ddmng466 minmag -384 -1E+3 -> -384 +ddmng467 minmag -1E+3 -384 -> -384 + +-- subnormals +ddmng510 minmag 1.00E-383 0 -> 0 +ddmng511 minmag 0.1E-383 0 -> 0 +ddmng512 minmag 0.10E-383 0 -> 0 +ddmng513 minmag 0.100E-383 0 -> 0 +ddmng514 minmag 0.01E-383 0 -> 0 +ddmng515 minmag 0.999E-383 0 -> 0 +ddmng516 minmag 0.099E-383 0 -> 0 +ddmng517 minmag 0.009E-383 0 -> 0 +ddmng518 minmag 0.001E-383 0 -> 0 +ddmng519 minmag 0.0009E-383 0 -> 0 +ddmng520 minmag 0.0001E-383 0 -> 0 + +ddmng530 minmag -1.00E-383 0 -> 0 +ddmng531 minmag -0.1E-383 0 -> 0 +ddmng532 minmag -0.10E-383 0 -> 0 +ddmng533 minmag -0.100E-383 0 -> 0 +ddmng534 minmag -0.01E-383 0 -> 0 +ddmng535 minmag -0.999E-383 0 -> 0 +ddmng536 minmag -0.099E-383 0 -> 0 +ddmng537 minmag -0.009E-383 0 -> 0 +ddmng538 minmag -0.001E-383 0 -> 0 +ddmng539 minmag -0.0009E-383 0 -> 0 +ddmng540 minmag -0.0001E-383 0 -> 0 + + +-- Null tests +ddmng900 minmag 10 # -> NaN Invalid_operation +ddmng901 minmag # 10 -> NaN Invalid_operation Added: python/branches/release25-maint/Lib/test/decimaltestdata/ddMinus.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/ddMinus.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,88 @@ +------------------------------------------------------------------------ +-- ddMinus.decTest -- decDouble 0-x -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- All operands and results are decDoubles. +precision: 16 +maxExponent: 384 +minExponent: -383 +extended: 1 +clamp: 1 +rounding: half_even + +-- Sanity check +ddmns001 minus +7.50 -> -7.50 + +-- Infinities +ddmns011 minus Infinity -> -Infinity +ddmns012 minus -Infinity -> Infinity + +-- NaNs, 0 payload +ddmns021 minus NaN -> NaN +ddmns022 minus -NaN -> -NaN +ddmns023 minus sNaN -> NaN Invalid_operation +ddmns024 minus -sNaN -> -NaN Invalid_operation + +-- NaNs, non-0 payload +ddmns031 minus NaN13 -> NaN13 +ddmns032 minus -NaN13 -> -NaN13 +ddmns033 minus sNaN13 -> NaN13 Invalid_operation +ddmns034 minus -sNaN13 -> -NaN13 Invalid_operation +ddmns035 minus NaN70 -> NaN70 +ddmns036 minus -NaN70 -> -NaN70 +ddmns037 minus sNaN101 -> NaN101 Invalid_operation +ddmns038 minus -sNaN101 -> -NaN101 Invalid_operation + +-- finites +ddmns101 minus 7 -> -7 +ddmns102 minus -7 -> 7 +ddmns103 minus 75 -> -75 +ddmns104 minus -75 -> 75 +ddmns105 minus 7.50 -> -7.50 +ddmns106 minus -7.50 -> 7.50 +ddmns107 minus 7.500 -> -7.500 +ddmns108 minus -7.500 -> 7.500 + +-- zeros +ddmns111 minus 0 -> 0 +ddmns112 minus -0 -> 0 +ddmns113 minus 0E+4 -> 0E+4 +ddmns114 minus -0E+4 -> 0E+4 +ddmns115 minus 0.0000 -> 0.0000 +ddmns116 minus -0.0000 -> 0.0000 +ddmns117 minus 0E-141 -> 0E-141 +ddmns118 minus -0E-141 -> 0E-141 + +-- full coefficients, alternating bits +ddmns121 minus 2682682682682682 -> -2682682682682682 +ddmns122 minus -2682682682682682 -> 2682682682682682 +ddmns123 minus 1341341341341341 -> -1341341341341341 +ddmns124 minus -1341341341341341 -> 1341341341341341 + +-- Nmax, Nmin, Ntiny +ddmns131 minus 9.999999999999999E+384 -> -9.999999999999999E+384 +ddmns132 minus 1E-383 -> -1E-383 +ddmns133 minus 1.000000000000000E-383 -> -1.000000000000000E-383 +ddmns134 minus 1E-398 -> -1E-398 Subnormal + +ddmns135 minus -1E-398 -> 1E-398 Subnormal +ddmns136 minus -1.000000000000000E-383 -> 1.000000000000000E-383 +ddmns137 minus -1E-383 -> 1E-383 +ddmns138 minus -9.999999999999999E+384 -> 9.999999999999999E+384 Added: python/branches/release25-maint/Lib/test/decimaltestdata/ddMultiply.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/ddMultiply.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,546 @@ +------------------------------------------------------------------------ +-- ddMultiply.decTest -- decDouble multiplication -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- This set of tests are for decDoubles only; all arguments are +-- representable in a decDouble +precision: 16 +maxExponent: 384 +minExponent: -383 +extended: 1 +clamp: 1 +rounding: half_even + +-- sanity checks +ddmul000 multiply 2 2 -> 4 +ddmul001 multiply 2 3 -> 6 +ddmul002 multiply 5 1 -> 5 +ddmul003 multiply 5 2 -> 10 +ddmul004 multiply 1.20 2 -> 2.40 +ddmul005 multiply 1.20 0 -> 0.00 +ddmul006 multiply 1.20 -2 -> -2.40 +ddmul007 multiply -1.20 2 -> -2.40 +ddmul008 multiply -1.20 0 -> -0.00 +ddmul009 multiply -1.20 -2 -> 2.40 +ddmul010 multiply 5.09 7.1 -> 36.139 +ddmul011 multiply 2.5 4 -> 10.0 +ddmul012 multiply 2.50 4 -> 10.00 +ddmul013 multiply 1.23456789 1.00000000 -> 1.234567890000000 Rounded +ddmul015 multiply 2.50 4 -> 10.00 +ddmul016 multiply 9.999999999 9.999999999 -> 99.99999998000000 Inexact Rounded +ddmul017 multiply 9.999999999 -9.999999999 -> -99.99999998000000 Inexact Rounded +ddmul018 multiply -9.999999999 9.999999999 -> -99.99999998000000 Inexact Rounded +ddmul019 multiply -9.999999999 -9.999999999 -> 99.99999998000000 Inexact Rounded + +-- zeros, etc. +ddmul021 multiply 0 0 -> 0 +ddmul022 multiply 0 -0 -> -0 +ddmul023 multiply -0 0 -> -0 +ddmul024 multiply -0 -0 -> 0 +ddmul025 multiply -0.0 -0.0 -> 0.00 +ddmul026 multiply -0.0 -0.0 -> 0.00 +ddmul027 multiply -0.0 -0.0 -> 0.00 +ddmul028 multiply -0.0 -0.0 -> 0.00 +ddmul030 multiply 5.00 1E-3 -> 0.00500 +ddmul031 multiply 00.00 0.000 -> 0.00000 +ddmul032 multiply 00.00 0E-3 -> 0.00000 -- rhs is 0 +ddmul033 multiply 0E-3 00.00 -> 0.00000 -- lhs is 0 +ddmul034 multiply -5.00 1E-3 -> -0.00500 +ddmul035 multiply -00.00 0.000 -> -0.00000 +ddmul036 multiply -00.00 0E-3 -> -0.00000 -- rhs is 0 +ddmul037 multiply -0E-3 00.00 -> -0.00000 -- lhs is 0 +ddmul038 multiply 5.00 -1E-3 -> -0.00500 +ddmul039 multiply 00.00 -0.000 -> -0.00000 +ddmul040 multiply 00.00 -0E-3 -> -0.00000 -- rhs is 0 +ddmul041 multiply 0E-3 -00.00 -> -0.00000 -- lhs is 0 +ddmul042 multiply -5.00 -1E-3 -> 0.00500 +ddmul043 multiply -00.00 -0.000 -> 0.00000 +ddmul044 multiply -00.00 -0E-3 -> 0.00000 -- rhs is 0 +ddmul045 multiply -0E-3 -00.00 -> 0.00000 -- lhs is 0 + +-- examples from decarith +ddmul050 multiply 1.20 3 -> 3.60 +ddmul051 multiply 7 3 -> 21 +ddmul052 multiply 0.9 0.8 -> 0.72 +ddmul053 multiply 0.9 -0 -> -0.0 +ddmul054 multiply 654321 654321 -> 428135971041 + +ddmul060 multiply 123.45 1e7 -> 1.2345E+9 +ddmul061 multiply 123.45 1e8 -> 1.2345E+10 +ddmul062 multiply 123.45 1e+9 -> 1.2345E+11 +ddmul063 multiply 123.45 1e10 -> 1.2345E+12 +ddmul064 multiply 123.45 1e11 -> 1.2345E+13 +ddmul065 multiply 123.45 1e12 -> 1.2345E+14 +ddmul066 multiply 123.45 1e13 -> 1.2345E+15 + + +-- test some intermediate lengths +-- 1234567890123456 +ddmul080 multiply 0.1 1230123456456789 -> 123012345645678.9 +ddmul084 multiply 0.1 1230123456456789 -> 123012345645678.9 +ddmul090 multiply 1230123456456789 0.1 -> 123012345645678.9 +ddmul094 multiply 1230123456456789 0.1 -> 123012345645678.9 + +-- test some more edge cases and carries +ddmul101 multiply 9 9 -> 81 +ddmul102 multiply 9 90 -> 810 +ddmul103 multiply 9 900 -> 8100 +ddmul104 multiply 9 9000 -> 81000 +ddmul105 multiply 9 90000 -> 810000 +ddmul106 multiply 9 900000 -> 8100000 +ddmul107 multiply 9 9000000 -> 81000000 +ddmul108 multiply 9 90000000 -> 810000000 +ddmul109 multiply 9 900000000 -> 8100000000 +ddmul110 multiply 9 9000000000 -> 81000000000 +ddmul111 multiply 9 90000000000 -> 810000000000 +ddmul112 multiply 9 900000000000 -> 8100000000000 +ddmul113 multiply 9 9000000000000 -> 81000000000000 +ddmul114 multiply 9 90000000000000 -> 810000000000000 +ddmul115 multiply 9 900000000000000 -> 8100000000000000 +--ddmul116 multiply 9 9000000000000000 -> 81000000000000000 +--ddmul117 multiply 9 90000000000000000 -> 810000000000000000 +--ddmul118 multiply 9 900000000000000000 -> 8100000000000000000 +--ddmul119 multiply 9 9000000000000000000 -> 81000000000000000000 +--ddmul120 multiply 9 90000000000000000000 -> 810000000000000000000 +--ddmul121 multiply 9 900000000000000000000 -> 8100000000000000000000 +--ddmul122 multiply 9 9000000000000000000000 -> 81000000000000000000000 +--ddmul123 multiply 9 90000000000000000000000 -> 810000000000000000000000 +-- test some more edge cases without carries +ddmul131 multiply 3 3 -> 9 +ddmul132 multiply 3 30 -> 90 +ddmul133 multiply 3 300 -> 900 +ddmul134 multiply 3 3000 -> 9000 +ddmul135 multiply 3 30000 -> 90000 +ddmul136 multiply 3 300000 -> 900000 +ddmul137 multiply 3 3000000 -> 9000000 +ddmul138 multiply 3 30000000 -> 90000000 +ddmul139 multiply 3 300000000 -> 900000000 +ddmul140 multiply 3 3000000000 -> 9000000000 +ddmul141 multiply 3 30000000000 -> 90000000000 +ddmul142 multiply 3 300000000000 -> 900000000000 +ddmul143 multiply 3 3000000000000 -> 9000000000000 +ddmul144 multiply 3 30000000000000 -> 90000000000000 +ddmul145 multiply 3 300000000000000 -> 900000000000000 + +-- test some edge cases with exact rounding +ddmul301 multiply 9 9 -> 81 +ddmul302 multiply 9 90 -> 810 +ddmul303 multiply 9 900 -> 8100 +ddmul304 multiply 9 9000 -> 81000 +ddmul305 multiply 9 90000 -> 810000 +ddmul306 multiply 9 900000 -> 8100000 +ddmul307 multiply 9 9000000 -> 81000000 +ddmul308 multiply 9 90000000 -> 810000000 +ddmul309 multiply 9 900000000 -> 8100000000 +ddmul310 multiply 9 9000000000 -> 81000000000 +ddmul311 multiply 9 90000000000 -> 810000000000 +ddmul312 multiply 9 900000000000 -> 8100000000000 +ddmul313 multiply 9 9000000000000 -> 81000000000000 +ddmul314 multiply 9 90000000000000 -> 810000000000000 +ddmul315 multiply 9 900000000000000 -> 8100000000000000 +ddmul316 multiply 9 9000000000000000 -> 8.100000000000000E+16 Rounded +ddmul317 multiply 90 9000000000000000 -> 8.100000000000000E+17 Rounded +ddmul318 multiply 900 9000000000000000 -> 8.100000000000000E+18 Rounded +ddmul319 multiply 9000 9000000000000000 -> 8.100000000000000E+19 Rounded +ddmul320 multiply 90000 9000000000000000 -> 8.100000000000000E+20 Rounded +ddmul321 multiply 900000 9000000000000000 -> 8.100000000000000E+21 Rounded +ddmul322 multiply 9000000 9000000000000000 -> 8.100000000000000E+22 Rounded +ddmul323 multiply 90000000 9000000000000000 -> 8.100000000000000E+23 Rounded + +-- tryzeros cases +ddmul504 multiply 0E-260 1000E-260 -> 0E-398 Clamped +ddmul505 multiply 100E+260 0E+260 -> 0E+369 Clamped + +-- mixed with zeros +ddmul541 multiply 0 -1 -> -0 +ddmul542 multiply -0 -1 -> 0 +ddmul543 multiply 0 1 -> 0 +ddmul544 multiply -0 1 -> -0 +ddmul545 multiply -1 0 -> -0 +ddmul546 multiply -1 -0 -> 0 +ddmul547 multiply 1 0 -> 0 +ddmul548 multiply 1 -0 -> -0 + +ddmul551 multiply 0.0 -1 -> -0.0 +ddmul552 multiply -0.0 -1 -> 0.0 +ddmul553 multiply 0.0 1 -> 0.0 +ddmul554 multiply -0.0 1 -> -0.0 +ddmul555 multiply -1.0 0 -> -0.0 +ddmul556 multiply -1.0 -0 -> 0.0 +ddmul557 multiply 1.0 0 -> 0.0 +ddmul558 multiply 1.0 -0 -> -0.0 + +ddmul561 multiply 0 -1.0 -> -0.0 +ddmul562 multiply -0 -1.0 -> 0.0 +ddmul563 multiply 0 1.0 -> 0.0 +ddmul564 multiply -0 1.0 -> -0.0 +ddmul565 multiply -1 0.0 -> -0.0 +ddmul566 multiply -1 -0.0 -> 0.0 +ddmul567 multiply 1 0.0 -> 0.0 +ddmul568 multiply 1 -0.0 -> -0.0 + +ddmul571 multiply 0.0 -1.0 -> -0.00 +ddmul572 multiply -0.0 -1.0 -> 0.00 +ddmul573 multiply 0.0 1.0 -> 0.00 +ddmul574 multiply -0.0 1.0 -> -0.00 +ddmul575 multiply -1.0 0.0 -> -0.00 +ddmul576 multiply -1.0 -0.0 -> 0.00 +ddmul577 multiply 1.0 0.0 -> 0.00 +ddmul578 multiply 1.0 -0.0 -> -0.00 + + +-- Specials +ddmul580 multiply Inf -Inf -> -Infinity +ddmul581 multiply Inf -1000 -> -Infinity +ddmul582 multiply Inf -1 -> -Infinity +ddmul583 multiply Inf -0 -> NaN Invalid_operation +ddmul584 multiply Inf 0 -> NaN Invalid_operation +ddmul585 multiply Inf 1 -> Infinity +ddmul586 multiply Inf 1000 -> Infinity +ddmul587 multiply Inf Inf -> Infinity +ddmul588 multiply -1000 Inf -> -Infinity +ddmul589 multiply -Inf Inf -> -Infinity +ddmul590 multiply -1 Inf -> -Infinity +ddmul591 multiply -0 Inf -> NaN Invalid_operation +ddmul592 multiply 0 Inf -> NaN Invalid_operation +ddmul593 multiply 1 Inf -> Infinity +ddmul594 multiply 1000 Inf -> Infinity +ddmul595 multiply Inf Inf -> Infinity + +ddmul600 multiply -Inf -Inf -> Infinity +ddmul601 multiply -Inf -1000 -> Infinity +ddmul602 multiply -Inf -1 -> Infinity +ddmul603 multiply -Inf -0 -> NaN Invalid_operation +ddmul604 multiply -Inf 0 -> NaN Invalid_operation +ddmul605 multiply -Inf 1 -> -Infinity +ddmul606 multiply -Inf 1000 -> -Infinity +ddmul607 multiply -Inf Inf -> -Infinity +ddmul608 multiply -1000 Inf -> -Infinity +ddmul609 multiply -Inf -Inf -> Infinity +ddmul610 multiply -1 -Inf -> Infinity +ddmul611 multiply -0 -Inf -> NaN Invalid_operation +ddmul612 multiply 0 -Inf -> NaN Invalid_operation +ddmul613 multiply 1 -Inf -> -Infinity +ddmul614 multiply 1000 -Inf -> -Infinity +ddmul615 multiply Inf -Inf -> -Infinity + +ddmul621 multiply NaN -Inf -> NaN +ddmul622 multiply NaN -1000 -> NaN +ddmul623 multiply NaN -1 -> NaN +ddmul624 multiply NaN -0 -> NaN +ddmul625 multiply NaN 0 -> NaN +ddmul626 multiply NaN 1 -> NaN +ddmul627 multiply NaN 1000 -> NaN +ddmul628 multiply NaN Inf -> NaN +ddmul629 multiply NaN NaN -> NaN +ddmul630 multiply -Inf NaN -> NaN +ddmul631 multiply -1000 NaN -> NaN +ddmul632 multiply -1 NaN -> NaN +ddmul633 multiply -0 NaN -> NaN +ddmul634 multiply 0 NaN -> NaN +ddmul635 multiply 1 NaN -> NaN +ddmul636 multiply 1000 NaN -> NaN +ddmul637 multiply Inf NaN -> NaN + +ddmul641 multiply sNaN -Inf -> NaN Invalid_operation +ddmul642 multiply sNaN -1000 -> NaN Invalid_operation +ddmul643 multiply sNaN -1 -> NaN Invalid_operation +ddmul644 multiply sNaN -0 -> NaN Invalid_operation +ddmul645 multiply sNaN 0 -> NaN Invalid_operation +ddmul646 multiply sNaN 1 -> NaN Invalid_operation +ddmul647 multiply sNaN 1000 -> NaN Invalid_operation +ddmul648 multiply sNaN NaN -> NaN Invalid_operation +ddmul649 multiply sNaN sNaN -> NaN Invalid_operation +ddmul650 multiply NaN sNaN -> NaN Invalid_operation +ddmul651 multiply -Inf sNaN -> NaN Invalid_operation +ddmul652 multiply -1000 sNaN -> NaN Invalid_operation +ddmul653 multiply -1 sNaN -> NaN Invalid_operation +ddmul654 multiply -0 sNaN -> NaN Invalid_operation +ddmul655 multiply 0 sNaN -> NaN Invalid_operation +ddmul656 multiply 1 sNaN -> NaN Invalid_operation +ddmul657 multiply 1000 sNaN -> NaN Invalid_operation +ddmul658 multiply Inf sNaN -> NaN Invalid_operation +ddmul659 multiply NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +ddmul661 multiply NaN9 -Inf -> NaN9 +ddmul662 multiply NaN8 999 -> NaN8 +ddmul663 multiply NaN71 Inf -> NaN71 +ddmul664 multiply NaN6 NaN5 -> NaN6 +ddmul665 multiply -Inf NaN4 -> NaN4 +ddmul666 multiply -999 NaN33 -> NaN33 +ddmul667 multiply Inf NaN2 -> NaN2 + +ddmul671 multiply sNaN99 -Inf -> NaN99 Invalid_operation +ddmul672 multiply sNaN98 -11 -> NaN98 Invalid_operation +ddmul673 multiply sNaN97 NaN -> NaN97 Invalid_operation +ddmul674 multiply sNaN16 sNaN94 -> NaN16 Invalid_operation +ddmul675 multiply NaN95 sNaN93 -> NaN93 Invalid_operation +ddmul676 multiply -Inf sNaN92 -> NaN92 Invalid_operation +ddmul677 multiply 088 sNaN91 -> NaN91 Invalid_operation +ddmul678 multiply Inf sNaN90 -> NaN90 Invalid_operation +ddmul679 multiply NaN sNaN89 -> NaN89 Invalid_operation + +ddmul681 multiply -NaN9 -Inf -> -NaN9 +ddmul682 multiply -NaN8 999 -> -NaN8 +ddmul683 multiply -NaN71 Inf -> -NaN71 +ddmul684 multiply -NaN6 -NaN5 -> -NaN6 +ddmul685 multiply -Inf -NaN4 -> -NaN4 +ddmul686 multiply -999 -NaN33 -> -NaN33 +ddmul687 multiply Inf -NaN2 -> -NaN2 + +ddmul691 multiply -sNaN99 -Inf -> -NaN99 Invalid_operation +ddmul692 multiply -sNaN98 -11 -> -NaN98 Invalid_operation +ddmul693 multiply -sNaN97 NaN -> -NaN97 Invalid_operation +ddmul694 multiply -sNaN16 -sNaN94 -> -NaN16 Invalid_operation +ddmul695 multiply -NaN95 -sNaN93 -> -NaN93 Invalid_operation +ddmul696 multiply -Inf -sNaN92 -> -NaN92 Invalid_operation +ddmul697 multiply 088 -sNaN91 -> -NaN91 Invalid_operation +ddmul698 multiply Inf -sNaN90 -> -NaN90 Invalid_operation +ddmul699 multiply -NaN -sNaN89 -> -NaN89 Invalid_operation + +ddmul701 multiply -NaN -Inf -> -NaN +ddmul702 multiply -NaN 999 -> -NaN +ddmul703 multiply -NaN Inf -> -NaN +ddmul704 multiply -NaN -NaN -> -NaN +ddmul705 multiply -Inf -NaN0 -> -NaN +ddmul706 multiply -999 -NaN -> -NaN +ddmul707 multiply Inf -NaN -> -NaN + +ddmul711 multiply -sNaN -Inf -> -NaN Invalid_operation +ddmul712 multiply -sNaN -11 -> -NaN Invalid_operation +ddmul713 multiply -sNaN00 NaN -> -NaN Invalid_operation +ddmul714 multiply -sNaN -sNaN -> -NaN Invalid_operation +ddmul715 multiply -NaN -sNaN -> -NaN Invalid_operation +ddmul716 multiply -Inf -sNaN -> -NaN Invalid_operation +ddmul717 multiply 088 -sNaN -> -NaN Invalid_operation +ddmul718 multiply Inf -sNaN -> -NaN Invalid_operation +ddmul719 multiply -NaN -sNaN -> -NaN Invalid_operation + +-- overflow and underflow tests .. note subnormal results +-- signs +ddmul751 multiply 1e+277 1e+311 -> Infinity Overflow Inexact Rounded +ddmul752 multiply 1e+277 -1e+311 -> -Infinity Overflow Inexact Rounded +ddmul753 multiply -1e+277 1e+311 -> -Infinity Overflow Inexact Rounded +ddmul754 multiply -1e+277 -1e+311 -> Infinity Overflow Inexact Rounded +ddmul755 multiply 1e-277 1e-311 -> 0E-398 Underflow Subnormal Inexact Rounded Clamped +ddmul756 multiply 1e-277 -1e-311 -> -0E-398 Underflow Subnormal Inexact Rounded Clamped +ddmul757 multiply -1e-277 1e-311 -> -0E-398 Underflow Subnormal Inexact Rounded Clamped +ddmul758 multiply -1e-277 -1e-311 -> 0E-398 Underflow Subnormal Inexact Rounded Clamped + +-- 'subnormal' boundary (all hard underflow or overflow in base arithemtic) +ddmul760 multiply 1e-291 1e-101 -> 1E-392 Subnormal +ddmul761 multiply 1e-291 1e-102 -> 1E-393 Subnormal +ddmul762 multiply 1e-291 1e-103 -> 1E-394 Subnormal +ddmul763 multiply 1e-291 1e-104 -> 1E-395 Subnormal +ddmul764 multiply 1e-291 1e-105 -> 1E-396 Subnormal +ddmul765 multiply 1e-291 1e-106 -> 1E-397 Subnormal +ddmul766 multiply 1e-291 1e-107 -> 1E-398 Subnormal +ddmul767 multiply 1e-291 1e-108 -> 0E-398 Underflow Subnormal Inexact Rounded Clamped +ddmul768 multiply 1e-291 1e-109 -> 0E-398 Underflow Subnormal Inexact Rounded Clamped +ddmul769 multiply 1e-291 1e-110 -> 0E-398 Underflow Subnormal Inexact Rounded Clamped +-- [no equivalent of 'subnormal' for overflow] +ddmul770 multiply 1e+60 1e+321 -> 1.000000000000E+381 Clamped +ddmul771 multiply 1e+60 1e+322 -> 1.0000000000000E+382 Clamped +ddmul772 multiply 1e+60 1e+323 -> 1.00000000000000E+383 Clamped +ddmul773 multiply 1e+60 1e+324 -> 1.000000000000000E+384 Clamped +ddmul774 multiply 1e+60 1e+325 -> Infinity Overflow Inexact Rounded +ddmul775 multiply 1e+60 1e+326 -> Infinity Overflow Inexact Rounded +ddmul776 multiply 1e+60 1e+327 -> Infinity Overflow Inexact Rounded +ddmul777 multiply 1e+60 1e+328 -> Infinity Overflow Inexact Rounded +ddmul778 multiply 1e+60 1e+329 -> Infinity Overflow Inexact Rounded +ddmul779 multiply 1e+60 1e+330 -> Infinity Overflow Inexact Rounded + +ddmul801 multiply 1.0000E-394 1 -> 1.0000E-394 Subnormal +ddmul802 multiply 1.000E-394 1e-1 -> 1.000E-395 Subnormal +ddmul803 multiply 1.00E-394 1e-2 -> 1.00E-396 Subnormal +ddmul804 multiply 1.0E-394 1e-3 -> 1.0E-397 Subnormal +ddmul805 multiply 1.0E-394 1e-4 -> 1E-398 Subnormal Rounded +ddmul806 multiply 1.3E-394 1e-4 -> 1E-398 Underflow Subnormal Inexact Rounded +ddmul807 multiply 1.5E-394 1e-4 -> 2E-398 Underflow Subnormal Inexact Rounded +ddmul808 multiply 1.7E-394 1e-4 -> 2E-398 Underflow Subnormal Inexact Rounded +ddmul809 multiply 2.3E-394 1e-4 -> 2E-398 Underflow Subnormal Inexact Rounded +ddmul810 multiply 2.5E-394 1e-4 -> 2E-398 Underflow Subnormal Inexact Rounded +ddmul811 multiply 2.7E-394 1e-4 -> 3E-398 Underflow Subnormal Inexact Rounded +ddmul812 multiply 1.49E-394 1e-4 -> 1E-398 Underflow Subnormal Inexact Rounded +ddmul813 multiply 1.50E-394 1e-4 -> 2E-398 Underflow Subnormal Inexact Rounded +ddmul814 multiply 1.51E-394 1e-4 -> 2E-398 Underflow Subnormal Inexact Rounded +ddmul815 multiply 2.49E-394 1e-4 -> 2E-398 Underflow Subnormal Inexact Rounded +ddmul816 multiply 2.50E-394 1e-4 -> 2E-398 Underflow Subnormal Inexact Rounded +ddmul817 multiply 2.51E-394 1e-4 -> 3E-398 Underflow Subnormal Inexact Rounded + +ddmul818 multiply 1E-394 1e-4 -> 1E-398 Subnormal +ddmul819 multiply 3E-394 1e-5 -> 0E-398 Underflow Subnormal Inexact Rounded Clamped +ddmul820 multiply 5E-394 1e-5 -> 0E-398 Underflow Subnormal Inexact Rounded Clamped +ddmul821 multiply 7E-394 1e-5 -> 1E-398 Underflow Subnormal Inexact Rounded +ddmul822 multiply 9E-394 1e-5 -> 1E-398 Underflow Subnormal Inexact Rounded +ddmul823 multiply 9.9E-394 1e-5 -> 1E-398 Underflow Subnormal Inexact Rounded + +ddmul824 multiply 1E-394 -1e-4 -> -1E-398 Subnormal +ddmul825 multiply 3E-394 -1e-5 -> -0E-398 Underflow Subnormal Inexact Rounded Clamped +ddmul826 multiply -5E-394 1e-5 -> -0E-398 Underflow Subnormal Inexact Rounded Clamped +ddmul827 multiply 7E-394 -1e-5 -> -1E-398 Underflow Subnormal Inexact Rounded +ddmul828 multiply -9E-394 1e-5 -> -1E-398 Underflow Subnormal Inexact Rounded +ddmul829 multiply 9.9E-394 -1e-5 -> -1E-398 Underflow Subnormal Inexact Rounded +ddmul830 multiply 3.0E-394 -1e-5 -> -0E-398 Underflow Subnormal Inexact Rounded Clamped + +ddmul831 multiply 1.0E-199 1e-200 -> 0E-398 Underflow Subnormal Inexact Rounded Clamped +ddmul832 multiply 1.0E-199 1e-199 -> 1E-398 Subnormal Rounded +ddmul833 multiply 1.0E-199 1e-198 -> 1.0E-397 Subnormal +ddmul834 multiply 2.0E-199 2e-198 -> 4.0E-397 Subnormal +ddmul835 multiply 4.0E-199 4e-198 -> 1.60E-396 Subnormal +ddmul836 multiply 10.0E-199 10e-198 -> 1.000E-395 Subnormal +ddmul837 multiply 30.0E-199 30e-198 -> 9.000E-395 Subnormal +ddmul838 multiply 40.0E-199 40e-188 -> 1.6000E-384 Subnormal +ddmul839 multiply 40.0E-199 40e-187 -> 1.6000E-383 +ddmul840 multiply 40.0E-199 40e-186 -> 1.6000E-382 + +-- Long operand overflow may be a different path +ddmul870 multiply 100 9.999E+383 -> Infinity Inexact Overflow Rounded +ddmul871 multiply 100 -9.999E+383 -> -Infinity Inexact Overflow Rounded +ddmul872 multiply 9.999E+383 100 -> Infinity Inexact Overflow Rounded +ddmul873 multiply -9.999E+383 100 -> -Infinity Inexact Overflow Rounded + +-- check for double-rounded subnormals +ddmul881 multiply 1.2347E-355 1.2347E-40 -> 1.524E-395 Inexact Rounded Subnormal Underflow +ddmul882 multiply 1.234E-355 1.234E-40 -> 1.523E-395 Inexact Rounded Subnormal Underflow +ddmul883 multiply 1.23E-355 1.23E-40 -> 1.513E-395 Inexact Rounded Subnormal Underflow +ddmul884 multiply 1.2E-355 1.2E-40 -> 1.44E-395 Subnormal +ddmul885 multiply 1.2E-355 1.2E-41 -> 1.44E-396 Subnormal +ddmul886 multiply 1.2E-355 1.2E-42 -> 1.4E-397 Subnormal Inexact Rounded Underflow +ddmul887 multiply 1.2E-355 1.3E-42 -> 1.6E-397 Subnormal Inexact Rounded Underflow +ddmul888 multiply 1.3E-355 1.3E-42 -> 1.7E-397 Subnormal Inexact Rounded Underflow +ddmul889 multiply 1.3E-355 1.3E-43 -> 2E-398 Subnormal Inexact Rounded Underflow +ddmul890 multiply 1.3E-356 1.3E-43 -> 0E-398 Clamped Subnormal Inexact Rounded Underflow + +ddmul891 multiply 1.2345E-39 1.234E-355 -> 1.5234E-394 Inexact Rounded Subnormal Underflow +ddmul892 multiply 1.23456E-39 1.234E-355 -> 1.5234E-394 Inexact Rounded Subnormal Underflow +ddmul893 multiply 1.2345E-40 1.234E-355 -> 1.523E-395 Inexact Rounded Subnormal Underflow +ddmul894 multiply 1.23456E-40 1.234E-355 -> 1.523E-395 Inexact Rounded Subnormal Underflow +ddmul895 multiply 1.2345E-41 1.234E-355 -> 1.52E-396 Inexact Rounded Subnormal Underflow +ddmul896 multiply 1.23456E-41 1.234E-355 -> 1.52E-396 Inexact Rounded Subnormal Underflow + +-- Now explore the case where we get a normal result with Underflow +-- 1 234567890123456 +ddmul900 multiply 0.3000000000E-191 0.3000000000E-191 -> 9.00000000000000E-384 Subnormal Rounded +ddmul901 multiply 0.3000000001E-191 0.3000000001E-191 -> 9.00000000600000E-384 Underflow Inexact Subnormal Rounded +ddmul902 multiply 9.999999999999999E-383 0.0999999999999 -> 9.99999999999000E-384 Underflow Inexact Subnormal Rounded +ddmul903 multiply 9.999999999999999E-383 0.09999999999999 -> 9.99999999999900E-384 Underflow Inexact Subnormal Rounded +ddmul904 multiply 9.999999999999999E-383 0.099999999999999 -> 9.99999999999990E-384 Underflow Inexact Subnormal Rounded +ddmul905 multiply 9.999999999999999E-383 0.0999999999999999 -> 9.99999999999999E-384 Underflow Inexact Subnormal Rounded +-- prove operands are exact +ddmul906 multiply 9.999999999999999E-383 1 -> 9.999999999999999E-383 +ddmul907 multiply 1 0.09999999999999999 -> 0.09999999999999999 +-- the next rounds to Nmin +ddmul908 multiply 9.999999999999999E-383 0.09999999999999999 -> 1.000000000000000E-383 Underflow Inexact Subnormal Rounded + +-- hugest +ddmul909 multiply 9999999999999999 9999999999999999 -> 9.999999999999998E+31 Inexact Rounded + +-- power-of-ten edge cases +ddmul1001 multiply 1 10 -> 10 +ddmul1002 multiply 1 100 -> 100 +ddmul1003 multiply 1 1000 -> 1000 +ddmul1004 multiply 1 10000 -> 10000 +ddmul1005 multiply 1 100000 -> 100000 +ddmul1006 multiply 1 1000000 -> 1000000 +ddmul1007 multiply 1 10000000 -> 10000000 +ddmul1008 multiply 1 100000000 -> 100000000 +ddmul1009 multiply 1 1000000000 -> 1000000000 +ddmul1010 multiply 1 10000000000 -> 10000000000 +ddmul1011 multiply 1 100000000000 -> 100000000000 +ddmul1012 multiply 1 1000000000000 -> 1000000000000 +ddmul1013 multiply 1 10000000000000 -> 10000000000000 +ddmul1014 multiply 1 100000000000000 -> 100000000000000 +ddmul1015 multiply 1 1000000000000000 -> 1000000000000000 +ddmul1021 multiply 10 1 -> 10 +ddmul1022 multiply 10 10 -> 100 +ddmul1023 multiply 10 100 -> 1000 +ddmul1024 multiply 10 1000 -> 10000 +ddmul1025 multiply 10 10000 -> 100000 +ddmul1026 multiply 10 100000 -> 1000000 +ddmul1027 multiply 10 1000000 -> 10000000 +ddmul1028 multiply 10 10000000 -> 100000000 +ddmul1029 multiply 10 100000000 -> 1000000000 +ddmul1030 multiply 10 1000000000 -> 10000000000 +ddmul1031 multiply 10 10000000000 -> 100000000000 +ddmul1032 multiply 10 100000000000 -> 1000000000000 +ddmul1033 multiply 10 1000000000000 -> 10000000000000 +ddmul1034 multiply 10 10000000000000 -> 100000000000000 +ddmul1035 multiply 10 100000000000000 -> 1000000000000000 +ddmul1041 multiply 100 0.1 -> 10.0 +ddmul1042 multiply 100 1 -> 100 +ddmul1043 multiply 100 10 -> 1000 +ddmul1044 multiply 100 100 -> 10000 +ddmul1045 multiply 100 1000 -> 100000 +ddmul1046 multiply 100 10000 -> 1000000 +ddmul1047 multiply 100 100000 -> 10000000 +ddmul1048 multiply 100 1000000 -> 100000000 +ddmul1049 multiply 100 10000000 -> 1000000000 +ddmul1050 multiply 100 100000000 -> 10000000000 +ddmul1051 multiply 100 1000000000 -> 100000000000 +ddmul1052 multiply 100 10000000000 -> 1000000000000 +ddmul1053 multiply 100 100000000000 -> 10000000000000 +ddmul1054 multiply 100 1000000000000 -> 100000000000000 +ddmul1055 multiply 100 10000000000000 -> 1000000000000000 +ddmul1061 multiply 1000 0.01 -> 10.00 +ddmul1062 multiply 1000 0.1 -> 100.0 +ddmul1063 multiply 1000 1 -> 1000 +ddmul1064 multiply 1000 10 -> 10000 +ddmul1065 multiply 1000 100 -> 100000 +ddmul1066 multiply 1000 1000 -> 1000000 +ddmul1067 multiply 1000 10000 -> 10000000 +ddmul1068 multiply 1000 100000 -> 100000000 +ddmul1069 multiply 1000 1000000 -> 1000000000 +ddmul1070 multiply 1000 10000000 -> 10000000000 +ddmul1071 multiply 1000 100000000 -> 100000000000 +ddmul1072 multiply 1000 1000000000 -> 1000000000000 +ddmul1073 multiply 1000 10000000000 -> 10000000000000 +ddmul1074 multiply 1000 100000000000 -> 100000000000000 +ddmul1075 multiply 1000 1000000000000 -> 1000000000000000 +ddmul1081 multiply 10000 0.001 -> 10.000 +ddmul1082 multiply 10000 0.01 -> 100.00 +ddmul1083 multiply 10000 0.1 -> 1000.0 +ddmul1084 multiply 10000 1 -> 10000 +ddmul1085 multiply 10000 10 -> 100000 +ddmul1086 multiply 10000 100 -> 1000000 +ddmul1087 multiply 10000 1000 -> 10000000 +ddmul1088 multiply 10000 10000 -> 100000000 +ddmul1089 multiply 10000 100000 -> 1000000000 +ddmul1090 multiply 10000 1000000 -> 10000000000 +ddmul1091 multiply 10000 10000000 -> 100000000000 +ddmul1092 multiply 10000 100000000 -> 1000000000000 +ddmul1093 multiply 10000 1000000000 -> 10000000000000 +ddmul1094 multiply 10000 10000000000 -> 100000000000000 +ddmul1095 multiply 10000 100000000000 -> 1000000000000000 + +ddmul1097 multiply 10000 99999999999 -> 999999999990000 +ddmul1098 multiply 10000 99999999999 -> 999999999990000 + + + + +-- Null tests +ddmul9990 multiply 10 # -> NaN Invalid_operation +ddmul9991 multiply # 10 -> NaN Invalid_operation + + + + Added: python/branches/release25-maint/Lib/test/decimaltestdata/ddNextMinus.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/ddNextMinus.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,126 @@ +------------------------------------------------------------------------ +-- ddNextMinus.decTest -- decDouble next that is less [754r nextdown] -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- All operands and results are decDoubles. +precision: 16 +maxExponent: 384 +minExponent: -383 +extended: 1 +clamp: 1 +rounding: half_even + +ddnextm001 nextminus 0.9999999999999995 -> 0.9999999999999994 +ddnextm002 nextminus 0.9999999999999996 -> 0.9999999999999995 +ddnextm003 nextminus 0.9999999999999997 -> 0.9999999999999996 +ddnextm004 nextminus 0.9999999999999998 -> 0.9999999999999997 +ddnextm005 nextminus 0.9999999999999999 -> 0.9999999999999998 +ddnextm006 nextminus 1.000000000000000 -> 0.9999999999999999 +ddnextm007 nextminus 1.0 -> 0.9999999999999999 +ddnextm008 nextminus 1 -> 0.9999999999999999 +ddnextm009 nextminus 1.000000000000001 -> 1.000000000000000 +ddnextm010 nextminus 1.000000000000002 -> 1.000000000000001 +ddnextm011 nextminus 1.000000000000003 -> 1.000000000000002 +ddnextm012 nextminus 1.000000000000004 -> 1.000000000000003 +ddnextm013 nextminus 1.000000000000005 -> 1.000000000000004 +ddnextm014 nextminus 1.000000000000006 -> 1.000000000000005 +ddnextm015 nextminus 1.000000000000007 -> 1.000000000000006 +ddnextm016 nextminus 1.000000000000008 -> 1.000000000000007 +ddnextm017 nextminus 1.000000000000009 -> 1.000000000000008 +ddnextm018 nextminus 1.000000000000010 -> 1.000000000000009 +ddnextm019 nextminus 1.000000000000011 -> 1.000000000000010 +ddnextm020 nextminus 1.000000000000012 -> 1.000000000000011 + +ddnextm021 nextminus -0.9999999999999995 -> -0.9999999999999996 +ddnextm022 nextminus -0.9999999999999996 -> -0.9999999999999997 +ddnextm023 nextminus -0.9999999999999997 -> -0.9999999999999998 +ddnextm024 nextminus -0.9999999999999998 -> -0.9999999999999999 +ddnextm025 nextminus -0.9999999999999999 -> -1.000000000000000 +ddnextm026 nextminus -1.000000000000000 -> -1.000000000000001 +ddnextm027 nextminus -1.0 -> -1.000000000000001 +ddnextm028 nextminus -1 -> -1.000000000000001 +ddnextm029 nextminus -1.000000000000001 -> -1.000000000000002 +ddnextm030 nextminus -1.000000000000002 -> -1.000000000000003 +ddnextm031 nextminus -1.000000000000003 -> -1.000000000000004 +ddnextm032 nextminus -1.000000000000004 -> -1.000000000000005 +ddnextm033 nextminus -1.000000000000005 -> -1.000000000000006 +ddnextm034 nextminus -1.000000000000006 -> -1.000000000000007 +ddnextm035 nextminus -1.000000000000007 -> -1.000000000000008 +ddnextm036 nextminus -1.000000000000008 -> -1.000000000000009 +ddnextm037 nextminus -1.000000000000009 -> -1.000000000000010 +ddnextm038 nextminus -1.000000000000010 -> -1.000000000000011 +ddnextm039 nextminus -1.000000000000011 -> -1.000000000000012 + +-- ultra-tiny inputs +ddnextm062 nextminus 1E-398 -> 0E-398 +ddnextm065 nextminus -1E-398 -> -2E-398 + +-- Zeros +ddnextm100 nextminus -0 -> -1E-398 +ddnextm101 nextminus 0 -> -1E-398 +ddnextm102 nextminus 0.00 -> -1E-398 +ddnextm103 nextminus -0.00 -> -1E-398 +ddnextm104 nextminus 0E-300 -> -1E-398 +ddnextm105 nextminus 0E+300 -> -1E-398 +ddnextm106 nextminus 0E+30000 -> -1E-398 +ddnextm107 nextminus -0E+30000 -> -1E-398 + +-- specials +ddnextm150 nextminus Inf -> 9.999999999999999E+384 +ddnextm151 nextminus -Inf -> -Infinity +ddnextm152 nextminus NaN -> NaN +ddnextm153 nextminus sNaN -> NaN Invalid_operation +ddnextm154 nextminus NaN77 -> NaN77 +ddnextm155 nextminus sNaN88 -> NaN88 Invalid_operation +ddnextm156 nextminus -NaN -> -NaN +ddnextm157 nextminus -sNaN -> -NaN Invalid_operation +ddnextm158 nextminus -NaN77 -> -NaN77 +ddnextm159 nextminus -sNaN88 -> -NaN88 Invalid_operation + +-- Nmax, Nmin, Ntiny, subnormals +ddnextm170 nextminus 9.999999999999999E+384 -> 9.999999999999998E+384 +ddnextm171 nextminus 9.999999999999998E+384 -> 9.999999999999997E+384 +ddnextm172 nextminus 1E-383 -> 9.99999999999999E-384 +ddnextm173 nextminus 1.000000000000000E-383 -> 9.99999999999999E-384 +ddnextm174 nextminus 9E-398 -> 8E-398 +ddnextm175 nextminus 9.9E-397 -> 9.8E-397 +ddnextm176 nextminus 9.99999999999E-387 -> 9.99999999998E-387 +ddnextm177 nextminus 9.99999999999999E-384 -> 9.99999999999998E-384 +ddnextm178 nextminus 9.99999999999998E-384 -> 9.99999999999997E-384 +ddnextm179 nextminus 9.99999999999997E-384 -> 9.99999999999996E-384 +ddnextm180 nextminus 0E-398 -> -1E-398 +ddnextm181 nextminus 1E-398 -> 0E-398 +ddnextm182 nextminus 2E-398 -> 1E-398 + +ddnextm183 nextminus -0E-398 -> -1E-398 +ddnextm184 nextminus -1E-398 -> -2E-398 +ddnextm185 nextminus -2E-398 -> -3E-398 +ddnextm186 nextminus -10E-398 -> -1.1E-397 +ddnextm187 nextminus -100E-398 -> -1.01E-396 +ddnextm188 nextminus -100000E-398 -> -1.00001E-393 +ddnextm189 nextminus -1.00000000000E-383 -> -1.000000000000001E-383 +ddnextm190 nextminus -1.000000000000000E-383 -> -1.000000000000001E-383 +ddnextm191 nextminus -1E-383 -> -1.000000000000001E-383 +ddnextm192 nextminus -9.999999999999998E+384 -> -9.999999999999999E+384 +ddnextm193 nextminus -9.999999999999999E+384 -> -Infinity + +-- Null tests +ddnextm900 nextminus # -> NaN Invalid_operation + Added: python/branches/release25-maint/Lib/test/decimaltestdata/ddNextPlus.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/ddNextPlus.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,124 @@ +------------------------------------------------------------------------ +-- ddNextPlus.decTest -- decDouble next that is greater [754r nextup] -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- All operands and results are decDoubles. +precision: 16 +maxExponent: 384 +minExponent: -383 +extended: 1 +clamp: 1 +rounding: half_even + +ddnextp001 nextplus 0.9999999999999995 -> 0.9999999999999996 +ddnextp002 nextplus 0.9999999999999996 -> 0.9999999999999997 +ddnextp003 nextplus 0.9999999999999997 -> 0.9999999999999998 +ddnextp004 nextplus 0.9999999999999998 -> 0.9999999999999999 +ddnextp005 nextplus 0.9999999999999999 -> 1.000000000000000 +ddnextp006 nextplus 1.000000000000000 -> 1.000000000000001 +ddnextp007 nextplus 1.0 -> 1.000000000000001 +ddnextp008 nextplus 1 -> 1.000000000000001 +ddnextp009 nextplus 1.000000000000001 -> 1.000000000000002 +ddnextp010 nextplus 1.000000000000002 -> 1.000000000000003 +ddnextp011 nextplus 1.000000000000003 -> 1.000000000000004 +ddnextp012 nextplus 1.000000000000004 -> 1.000000000000005 +ddnextp013 nextplus 1.000000000000005 -> 1.000000000000006 +ddnextp014 nextplus 1.000000000000006 -> 1.000000000000007 +ddnextp015 nextplus 1.000000000000007 -> 1.000000000000008 +ddnextp016 nextplus 1.000000000000008 -> 1.000000000000009 +ddnextp017 nextplus 1.000000000000009 -> 1.000000000000010 +ddnextp018 nextplus 1.000000000000010 -> 1.000000000000011 +ddnextp019 nextplus 1.000000000000011 -> 1.000000000000012 + +ddnextp021 nextplus -0.9999999999999995 -> -0.9999999999999994 +ddnextp022 nextplus -0.9999999999999996 -> -0.9999999999999995 +ddnextp023 nextplus -0.9999999999999997 -> -0.9999999999999996 +ddnextp024 nextplus -0.9999999999999998 -> -0.9999999999999997 +ddnextp025 nextplus -0.9999999999999999 -> -0.9999999999999998 +ddnextp026 nextplus -1.000000000000000 -> -0.9999999999999999 +ddnextp027 nextplus -1.0 -> -0.9999999999999999 +ddnextp028 nextplus -1 -> -0.9999999999999999 +ddnextp029 nextplus -1.000000000000001 -> -1.000000000000000 +ddnextp030 nextplus -1.000000000000002 -> -1.000000000000001 +ddnextp031 nextplus -1.000000000000003 -> -1.000000000000002 +ddnextp032 nextplus -1.000000000000004 -> -1.000000000000003 +ddnextp033 nextplus -1.000000000000005 -> -1.000000000000004 +ddnextp034 nextplus -1.000000000000006 -> -1.000000000000005 +ddnextp035 nextplus -1.000000000000007 -> -1.000000000000006 +ddnextp036 nextplus -1.000000000000008 -> -1.000000000000007 +ddnextp037 nextplus -1.000000000000009 -> -1.000000000000008 +ddnextp038 nextplus -1.000000000000010 -> -1.000000000000009 +ddnextp039 nextplus -1.000000000000011 -> -1.000000000000010 +ddnextp040 nextplus -1.000000000000012 -> -1.000000000000011 + +-- Zeros +ddnextp100 nextplus 0 -> 1E-398 +ddnextp101 nextplus 0.00 -> 1E-398 +ddnextp102 nextplus 0E-300 -> 1E-398 +ddnextp103 nextplus 0E+300 -> 1E-398 +ddnextp104 nextplus 0E+30000 -> 1E-398 +ddnextp105 nextplus -0 -> 1E-398 +ddnextp106 nextplus -0.00 -> 1E-398 +ddnextp107 nextplus -0E-300 -> 1E-398 +ddnextp108 nextplus -0E+300 -> 1E-398 +ddnextp109 nextplus -0E+30000 -> 1E-398 + +-- specials +ddnextp150 nextplus Inf -> Infinity +ddnextp151 nextplus -Inf -> -9.999999999999999E+384 +ddnextp152 nextplus NaN -> NaN +ddnextp153 nextplus sNaN -> NaN Invalid_operation +ddnextp154 nextplus NaN77 -> NaN77 +ddnextp155 nextplus sNaN88 -> NaN88 Invalid_operation +ddnextp156 nextplus -NaN -> -NaN +ddnextp157 nextplus -sNaN -> -NaN Invalid_operation +ddnextp158 nextplus -NaN77 -> -NaN77 +ddnextp159 nextplus -sNaN88 -> -NaN88 Invalid_operation + +-- Nmax, Nmin, Ntiny, subnormals +ddnextp170 nextplus -9.999999999999999E+384 -> -9.999999999999998E+384 +ddnextp171 nextplus -9.999999999999998E+384 -> -9.999999999999997E+384 +ddnextp172 nextplus -1E-383 -> -9.99999999999999E-384 +ddnextp173 nextplus -1.000000000000000E-383 -> -9.99999999999999E-384 +ddnextp174 nextplus -9E-398 -> -8E-398 +ddnextp175 nextplus -9.9E-397 -> -9.8E-397 +ddnextp176 nextplus -9.99999999999E-387 -> -9.99999999998E-387 +ddnextp177 nextplus -9.99999999999999E-384 -> -9.99999999999998E-384 +ddnextp178 nextplus -9.99999999999998E-384 -> -9.99999999999997E-384 +ddnextp179 nextplus -9.99999999999997E-384 -> -9.99999999999996E-384 +ddnextp180 nextplus -0E-398 -> 1E-398 +ddnextp181 nextplus -1E-398 -> -0E-398 +ddnextp182 nextplus -2E-398 -> -1E-398 + +ddnextp183 nextplus 0E-398 -> 1E-398 +ddnextp184 nextplus 1E-398 -> 2E-398 +ddnextp185 nextplus 2E-398 -> 3E-398 +ddnextp186 nextplus 10E-398 -> 1.1E-397 +ddnextp187 nextplus 100E-398 -> 1.01E-396 +ddnextp188 nextplus 100000E-398 -> 1.00001E-393 +ddnextp189 nextplus 1.00000000000E-383 -> 1.000000000000001E-383 +ddnextp190 nextplus 1.000000000000000E-383 -> 1.000000000000001E-383 +ddnextp191 nextplus 1E-383 -> 1.000000000000001E-383 +ddnextp192 nextplus 9.999999999999998E+384 -> 9.999999999999999E+384 +ddnextp193 nextplus 9.999999999999999E+384 -> Infinity + +-- Null tests +ddnextp900 nextplus # -> NaN Invalid_operation + Added: python/branches/release25-maint/Lib/test/decimaltestdata/ddNextToward.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/ddNextToward.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,374 @@ +------------------------------------------------------------------------ +-- ddNextToward.decTest -- decDouble next toward rhs [754r nextafter] -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- All operands and results are decDoubles. +precision: 16 +maxExponent: 384 +minExponent: -383 +extended: 1 +clamp: 1 +rounding: half_even + +-- Sanity check with a scattering of numerics +ddnextt001 nexttoward 10 10 -> 10 +ddnextt002 nexttoward -10 -10 -> -10 +ddnextt003 nexttoward 1 10 -> 1.000000000000001 +ddnextt004 nexttoward 1 -10 -> 0.9999999999999999 +ddnextt005 nexttoward -1 10 -> -0.9999999999999999 +ddnextt006 nexttoward -1 -10 -> -1.000000000000001 +ddnextt007 nexttoward 0 10 -> 1E-398 Underflow Subnormal Inexact Rounded +ddnextt008 nexttoward 0 -10 -> -1E-398 Underflow Subnormal Inexact Rounded +ddnextt009 nexttoward 9.999999999999999E+384 +Infinity -> Infinity Overflow Inexact Rounded +ddnextt010 nexttoward -9.999999999999999E+384 -Infinity -> -Infinity Overflow Inexact Rounded +ddnextt011 nexttoward 9.999999999999999 10 -> 10.00000000000000 +ddnextt012 nexttoward 10 9.999999999999999 -> 9.999999999999999 +ddnextt013 nexttoward -9.999999999999999 -10 -> -10.00000000000000 +ddnextt014 nexttoward -10 -9.999999999999999 -> -9.999999999999999 +ddnextt015 nexttoward 9.999999999999998 10 -> 9.999999999999999 +ddnextt016 nexttoward 10 9.999999999999998 -> 9.999999999999999 +ddnextt017 nexttoward -9.999999999999998 -10 -> -9.999999999999999 +ddnextt018 nexttoward -10 -9.999999999999998 -> -9.999999999999999 + +------- lhs=rhs +-- finites +ddnextt101 nexttoward 7 7 -> 7 +ddnextt102 nexttoward -7 -7 -> -7 +ddnextt103 nexttoward 75 75 -> 75 +ddnextt104 nexttoward -75 -75 -> -75 +ddnextt105 nexttoward 7.50 7.5 -> 7.50 +ddnextt106 nexttoward -7.50 -7.50 -> -7.50 +ddnextt107 nexttoward 7.500 7.5000 -> 7.500 +ddnextt108 nexttoward -7.500 -7.5 -> -7.500 + +-- zeros +ddnextt111 nexttoward 0 0 -> 0 +ddnextt112 nexttoward -0 -0 -> -0 +ddnextt113 nexttoward 0E+4 0 -> 0E+4 +ddnextt114 nexttoward -0E+4 -0 -> -0E+4 +ddnextt115 nexttoward 0.00000000000 0.000000000000 -> 0E-11 +ddnextt116 nexttoward -0.00000000000 -0.00 -> -0E-11 +ddnextt117 nexttoward 0E-141 0 -> 0E-141 +ddnextt118 nexttoward -0E-141 -000 -> -0E-141 + +-- full coefficients, alternating bits +ddnextt121 nexttoward 268268268 268268268 -> 268268268 +ddnextt122 nexttoward -268268268 -268268268 -> -268268268 +ddnextt123 nexttoward 134134134 134134134 -> 134134134 +ddnextt124 nexttoward -134134134 -134134134 -> -134134134 + +-- Nmax, Nmin, Ntiny +ddnextt131 nexttoward 9.999999999999999E+384 9.999999999999999E+384 -> 9.999999999999999E+384 +ddnextt132 nexttoward 1E-383 1E-383 -> 1E-383 +ddnextt133 nexttoward 1.000000000000000E-383 1.000000000000000E-383 -> 1.000000000000000E-383 +ddnextt134 nexttoward 1E-398 1E-398 -> 1E-398 + +ddnextt135 nexttoward -1E-398 -1E-398 -> -1E-398 +ddnextt136 nexttoward -1.000000000000000E-383 -1.000000000000000E-383 -> -1.000000000000000E-383 +ddnextt137 nexttoward -1E-383 -1E-383 -> -1E-383 +ddnextt138 nexttoward -9.999999999999999E+384 -9.999999999999999E+384 -> -9.999999999999999E+384 + +------- lhs 0.9999999999999996 +ddnextt202 nexttoward 0.9999999999999996 Infinity -> 0.9999999999999997 +ddnextt203 nexttoward 0.9999999999999997 Infinity -> 0.9999999999999998 +ddnextt204 nexttoward 0.9999999999999998 Infinity -> 0.9999999999999999 +ddnextt205 nexttoward 0.9999999999999999 Infinity -> 1.000000000000000 +ddnextt206 nexttoward 1.000000000000000 Infinity -> 1.000000000000001 +ddnextt207 nexttoward 1.0 Infinity -> 1.000000000000001 +ddnextt208 nexttoward 1 Infinity -> 1.000000000000001 +ddnextt209 nexttoward 1.000000000000001 Infinity -> 1.000000000000002 +ddnextt210 nexttoward 1.000000000000002 Infinity -> 1.000000000000003 +ddnextt211 nexttoward 1.000000000000003 Infinity -> 1.000000000000004 +ddnextt212 nexttoward 1.000000000000004 Infinity -> 1.000000000000005 +ddnextt213 nexttoward 1.000000000000005 Infinity -> 1.000000000000006 +ddnextt214 nexttoward 1.000000000000006 Infinity -> 1.000000000000007 +ddnextt215 nexttoward 1.000000000000007 Infinity -> 1.000000000000008 +ddnextt216 nexttoward 1.000000000000008 Infinity -> 1.000000000000009 +ddnextt217 nexttoward 1.000000000000009 Infinity -> 1.000000000000010 +ddnextt218 nexttoward 1.000000000000010 Infinity -> 1.000000000000011 +ddnextt219 nexttoward 1.000000000000011 Infinity -> 1.000000000000012 + +ddnextt221 nexttoward -0.9999999999999995 Infinity -> -0.9999999999999994 +ddnextt222 nexttoward -0.9999999999999996 Infinity -> -0.9999999999999995 +ddnextt223 nexttoward -0.9999999999999997 Infinity -> -0.9999999999999996 +ddnextt224 nexttoward -0.9999999999999998 Infinity -> -0.9999999999999997 +ddnextt225 nexttoward -0.9999999999999999 Infinity -> -0.9999999999999998 +ddnextt226 nexttoward -1.000000000000000 Infinity -> -0.9999999999999999 +ddnextt227 nexttoward -1.0 Infinity -> -0.9999999999999999 +ddnextt228 nexttoward -1 Infinity -> -0.9999999999999999 +ddnextt229 nexttoward -1.000000000000001 Infinity -> -1.000000000000000 +ddnextt230 nexttoward -1.000000000000002 Infinity -> -1.000000000000001 +ddnextt231 nexttoward -1.000000000000003 Infinity -> -1.000000000000002 +ddnextt232 nexttoward -1.000000000000004 Infinity -> -1.000000000000003 +ddnextt233 nexttoward -1.000000000000005 Infinity -> -1.000000000000004 +ddnextt234 nexttoward -1.000000000000006 Infinity -> -1.000000000000005 +ddnextt235 nexttoward -1.000000000000007 Infinity -> -1.000000000000006 +ddnextt236 nexttoward -1.000000000000008 Infinity -> -1.000000000000007 +ddnextt237 nexttoward -1.000000000000009 Infinity -> -1.000000000000008 +ddnextt238 nexttoward -1.000000000000010 Infinity -> -1.000000000000009 +ddnextt239 nexttoward -1.000000000000011 Infinity -> -1.000000000000010 +ddnextt240 nexttoward -1.000000000000012 Infinity -> -1.000000000000011 + +-- Zeros +ddnextt300 nexttoward 0 Infinity -> 1E-398 Underflow Subnormal Inexact Rounded +ddnextt301 nexttoward 0.00 Infinity -> 1E-398 Underflow Subnormal Inexact Rounded +ddnextt302 nexttoward 0E-300 Infinity -> 1E-398 Underflow Subnormal Inexact Rounded +ddnextt303 nexttoward 0E+300 Infinity -> 1E-398 Underflow Subnormal Inexact Rounded +ddnextt304 nexttoward 0E+30000 Infinity -> 1E-398 Underflow Subnormal Inexact Rounded +ddnextt305 nexttoward -0 Infinity -> 1E-398 Underflow Subnormal Inexact Rounded +ddnextt306 nexttoward -0.00 Infinity -> 1E-398 Underflow Subnormal Inexact Rounded +ddnextt307 nexttoward -0E-300 Infinity -> 1E-398 Underflow Subnormal Inexact Rounded +ddnextt308 nexttoward -0E+300 Infinity -> 1E-398 Underflow Subnormal Inexact Rounded +ddnextt309 nexttoward -0E+30000 Infinity -> 1E-398 Underflow Subnormal Inexact Rounded + +-- specials +ddnextt350 nexttoward Inf Infinity -> Infinity +ddnextt351 nexttoward -Inf Infinity -> -9.999999999999999E+384 +ddnextt352 nexttoward NaN Infinity -> NaN +ddnextt353 nexttoward sNaN Infinity -> NaN Invalid_operation +ddnextt354 nexttoward NaN77 Infinity -> NaN77 +ddnextt355 nexttoward sNaN88 Infinity -> NaN88 Invalid_operation +ddnextt356 nexttoward -NaN Infinity -> -NaN +ddnextt357 nexttoward -sNaN Infinity -> -NaN Invalid_operation +ddnextt358 nexttoward -NaN77 Infinity -> -NaN77 +ddnextt359 nexttoward -sNaN88 Infinity -> -NaN88 Invalid_operation + +-- Nmax, Nmin, Ntiny, subnormals +ddnextt370 nexttoward -9.999999999999999E+384 Infinity -> -9.999999999999998E+384 +ddnextt371 nexttoward -9.999999999999998E+384 Infinity -> -9.999999999999997E+384 +ddnextt372 nexttoward -1E-383 Infinity -> -9.99999999999999E-384 Underflow Subnormal Inexact Rounded +ddnextt373 nexttoward -1.000000000000000E-383 Infinity -> -9.99999999999999E-384 Underflow Subnormal Inexact Rounded +ddnextt374 nexttoward -9E-398 Infinity -> -8E-398 Underflow Subnormal Inexact Rounded +ddnextt375 nexttoward -9.9E-397 Infinity -> -9.8E-397 Underflow Subnormal Inexact Rounded +ddnextt376 nexttoward -9.99999999999E-387 Infinity -> -9.99999999998E-387 Underflow Subnormal Inexact Rounded +ddnextt377 nexttoward -9.99999999999999E-384 Infinity -> -9.99999999999998E-384 Underflow Subnormal Inexact Rounded +ddnextt378 nexttoward -9.99999999999998E-384 Infinity -> -9.99999999999997E-384 Underflow Subnormal Inexact Rounded +ddnextt379 nexttoward -9.99999999999997E-384 Infinity -> -9.99999999999996E-384 Underflow Subnormal Inexact Rounded +ddnextt380 nexttoward -0E-398 Infinity -> 1E-398 Underflow Subnormal Inexact Rounded +ddnextt381 nexttoward -1E-398 Infinity -> -0E-398 Underflow Subnormal Inexact Rounded Clamped +ddnextt382 nexttoward -2E-398 Infinity -> -1E-398 Underflow Subnormal Inexact Rounded + +ddnextt383 nexttoward 0E-398 Infinity -> 1E-398 Underflow Subnormal Inexact Rounded +ddnextt384 nexttoward 1E-398 Infinity -> 2E-398 Underflow Subnormal Inexact Rounded +ddnextt385 nexttoward 2E-398 Infinity -> 3E-398 Underflow Subnormal Inexact Rounded +ddnextt386 nexttoward 10E-398 Infinity -> 1.1E-397 Underflow Subnormal Inexact Rounded +ddnextt387 nexttoward 100E-398 Infinity -> 1.01E-396 Underflow Subnormal Inexact Rounded +ddnextt388 nexttoward 100000E-398 Infinity -> 1.00001E-393 Underflow Subnormal Inexact Rounded +ddnextt389 nexttoward 1.00000000000E-383 Infinity -> 1.000000000000001E-383 +ddnextt390 nexttoward 1.000000000000000E-383 Infinity -> 1.000000000000001E-383 +ddnextt391 nexttoward 1E-383 Infinity -> 1.000000000000001E-383 +ddnextt392 nexttoward 9.999999999999997E+384 Infinity -> 9.999999999999998E+384 +ddnextt393 nexttoward 9.999999999999998E+384 Infinity -> 9.999999999999999E+384 +ddnextt394 nexttoward 9.999999999999999E+384 Infinity -> Infinity Overflow Inexact Rounded + +------- lhs>rhs +ddnextt401 nexttoward 0.9999999999999995 -Infinity -> 0.9999999999999994 +ddnextt402 nexttoward 0.9999999999999996 -Infinity -> 0.9999999999999995 +ddnextt403 nexttoward 0.9999999999999997 -Infinity -> 0.9999999999999996 +ddnextt404 nexttoward 0.9999999999999998 -Infinity -> 0.9999999999999997 +ddnextt405 nexttoward 0.9999999999999999 -Infinity -> 0.9999999999999998 +ddnextt406 nexttoward 1.000000000000000 -Infinity -> 0.9999999999999999 +ddnextt407 nexttoward 1.0 -Infinity -> 0.9999999999999999 +ddnextt408 nexttoward 1 -Infinity -> 0.9999999999999999 +ddnextt409 nexttoward 1.000000000000001 -Infinity -> 1.000000000000000 +ddnextt410 nexttoward 1.000000000000002 -Infinity -> 1.000000000000001 +ddnextt411 nexttoward 1.000000000000003 -Infinity -> 1.000000000000002 +ddnextt412 nexttoward 1.000000000000004 -Infinity -> 1.000000000000003 +ddnextt413 nexttoward 1.000000000000005 -Infinity -> 1.000000000000004 +ddnextt414 nexttoward 1.000000000000006 -Infinity -> 1.000000000000005 +ddnextt415 nexttoward 1.000000000000007 -Infinity -> 1.000000000000006 +ddnextt416 nexttoward 1.000000000000008 -Infinity -> 1.000000000000007 +ddnextt417 nexttoward 1.000000000000009 -Infinity -> 1.000000000000008 +ddnextt418 nexttoward 1.000000000000010 -Infinity -> 1.000000000000009 +ddnextt419 nexttoward 1.000000000000011 -Infinity -> 1.000000000000010 +ddnextt420 nexttoward 1.000000000000012 -Infinity -> 1.000000000000011 + +ddnextt421 nexttoward -0.9999999999999995 -Infinity -> -0.9999999999999996 +ddnextt422 nexttoward -0.9999999999999996 -Infinity -> -0.9999999999999997 +ddnextt423 nexttoward -0.9999999999999997 -Infinity -> -0.9999999999999998 +ddnextt424 nexttoward -0.9999999999999998 -Infinity -> -0.9999999999999999 +ddnextt425 nexttoward -0.9999999999999999 -Infinity -> -1.000000000000000 +ddnextt426 nexttoward -1.000000000000000 -Infinity -> -1.000000000000001 +ddnextt427 nexttoward -1.0 -Infinity -> -1.000000000000001 +ddnextt428 nexttoward -1 -Infinity -> -1.000000000000001 +ddnextt429 nexttoward -1.000000000000001 -Infinity -> -1.000000000000002 +ddnextt430 nexttoward -1.000000000000002 -Infinity -> -1.000000000000003 +ddnextt431 nexttoward -1.000000000000003 -Infinity -> -1.000000000000004 +ddnextt432 nexttoward -1.000000000000004 -Infinity -> -1.000000000000005 +ddnextt433 nexttoward -1.000000000000005 -Infinity -> -1.000000000000006 +ddnextt434 nexttoward -1.000000000000006 -Infinity -> -1.000000000000007 +ddnextt435 nexttoward -1.000000000000007 -Infinity -> -1.000000000000008 +ddnextt436 nexttoward -1.000000000000008 -Infinity -> -1.000000000000009 +ddnextt437 nexttoward -1.000000000000009 -Infinity -> -1.000000000000010 +ddnextt438 nexttoward -1.000000000000010 -Infinity -> -1.000000000000011 +ddnextt439 nexttoward -1.000000000000011 -Infinity -> -1.000000000000012 + +-- Zeros +ddnextt500 nexttoward -0 -Infinity -> -1E-398 Underflow Subnormal Inexact Rounded +ddnextt501 nexttoward 0 -Infinity -> -1E-398 Underflow Subnormal Inexact Rounded +ddnextt502 nexttoward 0.00 -Infinity -> -1E-398 Underflow Subnormal Inexact Rounded +ddnextt503 nexttoward -0.00 -Infinity -> -1E-398 Underflow Subnormal Inexact Rounded +ddnextt504 nexttoward 0E-300 -Infinity -> -1E-398 Underflow Subnormal Inexact Rounded +ddnextt505 nexttoward 0E+300 -Infinity -> -1E-398 Underflow Subnormal Inexact Rounded +ddnextt506 nexttoward 0E+30000 -Infinity -> -1E-398 Underflow Subnormal Inexact Rounded +ddnextt507 nexttoward -0E+30000 -Infinity -> -1E-398 Underflow Subnormal Inexact Rounded + +-- specials +ddnextt550 nexttoward Inf -Infinity -> 9.999999999999999E+384 +ddnextt551 nexttoward -Inf -Infinity -> -Infinity +ddnextt552 nexttoward NaN -Infinity -> NaN +ddnextt553 nexttoward sNaN -Infinity -> NaN Invalid_operation +ddnextt554 nexttoward NaN77 -Infinity -> NaN77 +ddnextt555 nexttoward sNaN88 -Infinity -> NaN88 Invalid_operation +ddnextt556 nexttoward -NaN -Infinity -> -NaN +ddnextt557 nexttoward -sNaN -Infinity -> -NaN Invalid_operation +ddnextt558 nexttoward -NaN77 -Infinity -> -NaN77 +ddnextt559 nexttoward -sNaN88 -Infinity -> -NaN88 Invalid_operation + +-- Nmax, Nmin, Ntiny, subnormals +ddnextt670 nexttoward 9.999999999999999E+384 -Infinity -> 9.999999999999998E+384 +ddnextt671 nexttoward 9.999999999999998E+384 -Infinity -> 9.999999999999997E+384 +ddnextt672 nexttoward 1E-383 -Infinity -> 9.99999999999999E-384 Underflow Subnormal Inexact Rounded +ddnextt673 nexttoward 1.000000000000000E-383 -Infinity -> 9.99999999999999E-384 Underflow Subnormal Inexact Rounded +ddnextt674 nexttoward 9E-398 -Infinity -> 8E-398 Underflow Subnormal Inexact Rounded +ddnextt675 nexttoward 9.9E-397 -Infinity -> 9.8E-397 Underflow Subnormal Inexact Rounded +ddnextt676 nexttoward 9.99999999999E-387 -Infinity -> 9.99999999998E-387 Underflow Subnormal Inexact Rounded +ddnextt677 nexttoward 9.99999999999999E-384 -Infinity -> 9.99999999999998E-384 Underflow Subnormal Inexact Rounded +ddnextt678 nexttoward 9.99999999999998E-384 -Infinity -> 9.99999999999997E-384 Underflow Subnormal Inexact Rounded +ddnextt679 nexttoward 9.99999999999997E-384 -Infinity -> 9.99999999999996E-384 Underflow Subnormal Inexact Rounded +ddnextt680 nexttoward 0E-398 -Infinity -> -1E-398 Underflow Subnormal Inexact Rounded +ddnextt681 nexttoward 1E-398 -Infinity -> 0E-398 Underflow Subnormal Inexact Rounded Clamped +ddnextt682 nexttoward 2E-398 -Infinity -> 1E-398 Underflow Subnormal Inexact Rounded + +ddnextt683 nexttoward -0E-398 -Infinity -> -1E-398 Underflow Subnormal Inexact Rounded +ddnextt684 nexttoward -1E-398 -Infinity -> -2E-398 Underflow Subnormal Inexact Rounded +ddnextt685 nexttoward -2E-398 -Infinity -> -3E-398 Underflow Subnormal Inexact Rounded +ddnextt686 nexttoward -10E-398 -Infinity -> -1.1E-397 Underflow Subnormal Inexact Rounded +ddnextt687 nexttoward -100E-398 -Infinity -> -1.01E-396 Underflow Subnormal Inexact Rounded +ddnextt688 nexttoward -100000E-398 -Infinity -> -1.00001E-393 Underflow Subnormal Inexact Rounded +ddnextt689 nexttoward -1.00000000000E-383 -Infinity -> -1.000000000000001E-383 +ddnextt690 nexttoward -1.000000000000000E-383 -Infinity -> -1.000000000000001E-383 +ddnextt691 nexttoward -1E-383 -Infinity -> -1.000000000000001E-383 +ddnextt692 nexttoward -9.999999999999998E+384 -Infinity -> -9.999999999999999E+384 +ddnextt693 nexttoward -9.999999999999999E+384 -Infinity -> -Infinity Overflow Inexact Rounded + +------- Specials +ddnextt780 nexttoward -Inf -Inf -> -Infinity +ddnextt781 nexttoward -Inf -1000 -> -9.999999999999999E+384 +ddnextt782 nexttoward -Inf -1 -> -9.999999999999999E+384 +ddnextt783 nexttoward -Inf -0 -> -9.999999999999999E+384 +ddnextt784 nexttoward -Inf 0 -> -9.999999999999999E+384 +ddnextt785 nexttoward -Inf 1 -> -9.999999999999999E+384 +ddnextt786 nexttoward -Inf 1000 -> -9.999999999999999E+384 +ddnextt787 nexttoward -1000 -Inf -> -1000.000000000001 +ddnextt788 nexttoward -Inf -Inf -> -Infinity +ddnextt789 nexttoward -1 -Inf -> -1.000000000000001 +ddnextt790 nexttoward -0 -Inf -> -1E-398 Underflow Subnormal Inexact Rounded +ddnextt791 nexttoward 0 -Inf -> -1E-398 Underflow Subnormal Inexact Rounded +ddnextt792 nexttoward 1 -Inf -> 0.9999999999999999 +ddnextt793 nexttoward 1000 -Inf -> 999.9999999999999 +ddnextt794 nexttoward Inf -Inf -> 9.999999999999999E+384 + +ddnextt800 nexttoward Inf -Inf -> 9.999999999999999E+384 +ddnextt801 nexttoward Inf -1000 -> 9.999999999999999E+384 +ddnextt802 nexttoward Inf -1 -> 9.999999999999999E+384 +ddnextt803 nexttoward Inf -0 -> 9.999999999999999E+384 +ddnextt804 nexttoward Inf 0 -> 9.999999999999999E+384 +ddnextt805 nexttoward Inf 1 -> 9.999999999999999E+384 +ddnextt806 nexttoward Inf 1000 -> 9.999999999999999E+384 +ddnextt807 nexttoward Inf Inf -> Infinity +ddnextt808 nexttoward -1000 Inf -> -999.9999999999999 +ddnextt809 nexttoward -Inf Inf -> -9.999999999999999E+384 +ddnextt810 nexttoward -1 Inf -> -0.9999999999999999 +ddnextt811 nexttoward -0 Inf -> 1E-398 Underflow Subnormal Inexact Rounded +ddnextt812 nexttoward 0 Inf -> 1E-398 Underflow Subnormal Inexact Rounded +ddnextt813 nexttoward 1 Inf -> 1.000000000000001 +ddnextt814 nexttoward 1000 Inf -> 1000.000000000001 +ddnextt815 nexttoward Inf Inf -> Infinity + +ddnextt821 nexttoward NaN -Inf -> NaN +ddnextt822 nexttoward NaN -1000 -> NaN +ddnextt823 nexttoward NaN -1 -> NaN +ddnextt824 nexttoward NaN -0 -> NaN +ddnextt825 nexttoward NaN 0 -> NaN +ddnextt826 nexttoward NaN 1 -> NaN +ddnextt827 nexttoward NaN 1000 -> NaN +ddnextt828 nexttoward NaN Inf -> NaN +ddnextt829 nexttoward NaN NaN -> NaN +ddnextt830 nexttoward -Inf NaN -> NaN +ddnextt831 nexttoward -1000 NaN -> NaN +ddnextt832 nexttoward -1 NaN -> NaN +ddnextt833 nexttoward -0 NaN -> NaN +ddnextt834 nexttoward 0 NaN -> NaN +ddnextt835 nexttoward 1 NaN -> NaN +ddnextt836 nexttoward 1000 NaN -> NaN +ddnextt837 nexttoward Inf NaN -> NaN + +ddnextt841 nexttoward sNaN -Inf -> NaN Invalid_operation +ddnextt842 nexttoward sNaN -1000 -> NaN Invalid_operation +ddnextt843 nexttoward sNaN -1 -> NaN Invalid_operation +ddnextt844 nexttoward sNaN -0 -> NaN Invalid_operation +ddnextt845 nexttoward sNaN 0 -> NaN Invalid_operation +ddnextt846 nexttoward sNaN 1 -> NaN Invalid_operation +ddnextt847 nexttoward sNaN 1000 -> NaN Invalid_operation +ddnextt848 nexttoward sNaN NaN -> NaN Invalid_operation +ddnextt849 nexttoward sNaN sNaN -> NaN Invalid_operation +ddnextt850 nexttoward NaN sNaN -> NaN Invalid_operation +ddnextt851 nexttoward -Inf sNaN -> NaN Invalid_operation +ddnextt852 nexttoward -1000 sNaN -> NaN Invalid_operation +ddnextt853 nexttoward -1 sNaN -> NaN Invalid_operation +ddnextt854 nexttoward -0 sNaN -> NaN Invalid_operation +ddnextt855 nexttoward 0 sNaN -> NaN Invalid_operation +ddnextt856 nexttoward 1 sNaN -> NaN Invalid_operation +ddnextt857 nexttoward 1000 sNaN -> NaN Invalid_operation +ddnextt858 nexttoward Inf sNaN -> NaN Invalid_operation +ddnextt859 nexttoward NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +ddnextt861 nexttoward NaN1 -Inf -> NaN1 +ddnextt862 nexttoward +NaN2 -1000 -> NaN2 +ddnextt863 nexttoward NaN3 1000 -> NaN3 +ddnextt864 nexttoward NaN4 Inf -> NaN4 +ddnextt865 nexttoward NaN5 +NaN6 -> NaN5 +ddnextt866 nexttoward -Inf NaN7 -> NaN7 +ddnextt867 nexttoward -1000 NaN8 -> NaN8 +ddnextt868 nexttoward 1000 NaN9 -> NaN9 +ddnextt869 nexttoward Inf +NaN10 -> NaN10 +ddnextt871 nexttoward sNaN11 -Inf -> NaN11 Invalid_operation +ddnextt872 nexttoward sNaN12 -1000 -> NaN12 Invalid_operation +ddnextt873 nexttoward sNaN13 1000 -> NaN13 Invalid_operation +ddnextt874 nexttoward sNaN14 NaN17 -> NaN14 Invalid_operation +ddnextt875 nexttoward sNaN15 sNaN18 -> NaN15 Invalid_operation +ddnextt876 nexttoward NaN16 sNaN19 -> NaN19 Invalid_operation +ddnextt877 nexttoward -Inf +sNaN20 -> NaN20 Invalid_operation +ddnextt878 nexttoward -1000 sNaN21 -> NaN21 Invalid_operation +ddnextt879 nexttoward 1000 sNaN22 -> NaN22 Invalid_operation +ddnextt880 nexttoward Inf sNaN23 -> NaN23 Invalid_operation +ddnextt881 nexttoward +NaN25 +sNaN24 -> NaN24 Invalid_operation +ddnextt882 nexttoward -NaN26 NaN28 -> -NaN26 +ddnextt883 nexttoward -sNaN27 sNaN29 -> -NaN27 Invalid_operation +ddnextt884 nexttoward 1000 -NaN30 -> -NaN30 +ddnextt885 nexttoward 1000 -sNaN31 -> -NaN31 Invalid_operation + +-- Null tests +ddnextt900 nexttoward 1 # -> NaN Invalid_operation +ddnextt901 nexttoward # 1 -> NaN Invalid_operation + Added: python/branches/release25-maint/Lib/test/decimaltestdata/ddOr.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/ddOr.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,292 @@ +------------------------------------------------------------------------ +-- ddOr.decTest -- digitwise logical OR for decDoubles -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +precision: 16 +maxExponent: 384 +minExponent: -383 +extended: 1 +clamp: 1 +rounding: half_even + +-- Sanity check (truth table) +ddor001 or 0 0 -> 0 +ddor002 or 0 1 -> 1 +ddor003 or 1 0 -> 1 +ddor004 or 1 1 -> 1 +ddor005 or 1100 1010 -> 1110 +-- and at msd and msd-1 +ddor006 or 0000000000000000 0000000000000000 -> 0 +ddor007 or 0000000000000000 1000000000000000 -> 1000000000000000 +ddor008 or 1000000000000000 0000000000000000 -> 1000000000000000 +ddor009 or 1000000000000000 1000000000000000 -> 1000000000000000 +ddor010 or 0000000000000000 0000000000000000 -> 0 +ddor011 or 0000000000000000 0100000000000000 -> 100000000000000 +ddor012 or 0100000000000000 0000000000000000 -> 100000000000000 +ddor013 or 0100000000000000 0100000000000000 -> 100000000000000 + +-- Various lengths +-- 1234567890123456 1234567890123456 1234567890123456 +ddor020 or 1111111111111111 1111111111111111 -> 1111111111111111 +ddor021 or 111111111111111 111111111111111 -> 111111111111111 +ddor022 or 11111111111111 11111111111111 -> 11111111111111 +ddor023 or 1111111111111 1111111111111 -> 1111111111111 +ddor024 or 111111111111 111111111111 -> 111111111111 +ddor025 or 11111111111 11111111111 -> 11111111111 +ddor026 or 1111111111 1111111111 -> 1111111111 +ddor027 or 111111111 111111111 -> 111111111 +ddor028 or 11111111 11111111 -> 11111111 +ddor029 or 1111111 1111111 -> 1111111 +ddor030 or 111111 111111 -> 111111 +ddor031 or 11111 11111 -> 11111 +ddor032 or 1111 1111 -> 1111 +ddor033 or 111 111 -> 111 +ddor034 or 11 11 -> 11 +ddor035 or 1 1 -> 1 +ddor036 or 0 0 -> 0 + +ddor042 or 111111110000000 1111111110000000 -> 1111111110000000 +ddor043 or 11111110000000 1000000100000000 -> 1011111110000000 +ddor044 or 1111110000000 1000001000000000 -> 1001111110000000 +ddor045 or 111110000000 1000010000000000 -> 1000111110000000 +ddor046 or 11110000000 1000100000000000 -> 1000111110000000 +ddor047 or 1110000000 1001000000000000 -> 1001001110000000 +ddor048 or 110000000 1010000000000000 -> 1010000110000000 +ddor049 or 10000000 1100000000000000 -> 1100000010000000 + +ddor090 or 011111111 111101111 -> 111111111 +ddor091 or 101111111 111101111 -> 111111111 +ddor092 or 110111111 111101111 -> 111111111 +ddor093 or 111011111 111101111 -> 111111111 +ddor094 or 111101111 111101111 -> 111101111 +ddor095 or 111110111 111101111 -> 111111111 +ddor096 or 111111011 111101111 -> 111111111 +ddor097 or 111111101 111101111 -> 111111111 +ddor098 or 111111110 111101111 -> 111111111 + +ddor100 or 111101111 011111111 -> 111111111 +ddor101 or 111101111 101111111 -> 111111111 +ddor102 or 111101111 110111111 -> 111111111 +ddor103 or 111101111 111011111 -> 111111111 +ddor104 or 111101111 111101111 -> 111101111 +ddor105 or 111101111 111110111 -> 111111111 +ddor106 or 111101111 111111011 -> 111111111 +ddor107 or 111101111 111111101 -> 111111111 +ddor108 or 111101111 111111110 -> 111111111 + +-- non-0/1 should not be accepted, nor should signs +ddor220 or 111111112 111111111 -> NaN Invalid_operation +ddor221 or 333333333 333333333 -> NaN Invalid_operation +ddor222 or 555555555 555555555 -> NaN Invalid_operation +ddor223 or 777777777 777777777 -> NaN Invalid_operation +ddor224 or 999999999 999999999 -> NaN Invalid_operation +ddor225 or 222222222 999999999 -> NaN Invalid_operation +ddor226 or 444444444 999999999 -> NaN Invalid_operation +ddor227 or 666666666 999999999 -> NaN Invalid_operation +ddor228 or 888888888 999999999 -> NaN Invalid_operation +ddor229 or 999999999 222222222 -> NaN Invalid_operation +ddor230 or 999999999 444444444 -> NaN Invalid_operation +ddor231 or 999999999 666666666 -> NaN Invalid_operation +ddor232 or 999999999 888888888 -> NaN Invalid_operation +-- a few randoms +ddor240 or 567468689 -934981942 -> NaN Invalid_operation +ddor241 or 567367689 934981942 -> NaN Invalid_operation +ddor242 or -631917772 -706014634 -> NaN Invalid_operation +ddor243 or -756253257 138579234 -> NaN Invalid_operation +ddor244 or 835590149 567435400 -> NaN Invalid_operation +-- test MSD +ddor250 or 2000000000000000 1000000000000000 -> NaN Invalid_operation +ddor251 or 7000000000000000 1000000000000000 -> NaN Invalid_operation +ddor252 or 8000000000000000 1000000000000000 -> NaN Invalid_operation +ddor253 or 9000000000000000 1000000000000000 -> NaN Invalid_operation +ddor254 or 2000000000000000 0000000000000000 -> NaN Invalid_operation +ddor255 or 7000000000000000 0000000000000000 -> NaN Invalid_operation +ddor256 or 8000000000000000 0000000000000000 -> NaN Invalid_operation +ddor257 or 9000000000000000 0000000000000000 -> NaN Invalid_operation +ddor258 or 1000000000000000 2000000000000000 -> NaN Invalid_operation +ddor259 or 1000000000000000 7000000000000000 -> NaN Invalid_operation +ddor260 or 1000000000000000 8000000000000000 -> NaN Invalid_operation +ddor261 or 1000000000000000 9000000000000000 -> NaN Invalid_operation +ddor262 or 0000000000000000 2000000000000000 -> NaN Invalid_operation +ddor263 or 0000000000000000 7000000000000000 -> NaN Invalid_operation +ddor264 or 0000000000000000 8000000000000000 -> NaN Invalid_operation +ddor265 or 0000000000000000 9000000000000000 -> NaN Invalid_operation +-- test MSD-1 +ddor270 or 0200001000000000 1000100000000010 -> NaN Invalid_operation +ddor271 or 0700000100000000 1000010000000100 -> NaN Invalid_operation +ddor272 or 0800000010000000 1000001000001000 -> NaN Invalid_operation +ddor273 or 0900000001000000 1000000100010000 -> NaN Invalid_operation +ddor274 or 1000000000100000 0200000010100000 -> NaN Invalid_operation +ddor275 or 1000000000010000 0700000001000000 -> NaN Invalid_operation +ddor276 or 1000000000001000 0800000010100000 -> NaN Invalid_operation +ddor277 or 1000000000000100 0900000000010000 -> NaN Invalid_operation +-- test LSD +ddor280 or 0010000000000002 1000000100000001 -> NaN Invalid_operation +ddor281 or 0001000000000007 1000001000000011 -> NaN Invalid_operation +ddor282 or 0000100000000008 1000010000000001 -> NaN Invalid_operation +ddor283 or 0000010000000009 1000100000000001 -> NaN Invalid_operation +ddor284 or 1000001000000000 0001000000000002 -> NaN Invalid_operation +ddor285 or 1000000100000000 0010000000000007 -> NaN Invalid_operation +ddor286 or 1000000010000000 0100000000000008 -> NaN Invalid_operation +ddor287 or 1000000001000000 1000000000000009 -> NaN Invalid_operation +-- test Middie +ddor288 or 0010000020000000 1000001000000000 -> NaN Invalid_operation +ddor289 or 0001000070000001 1000000100000000 -> NaN Invalid_operation +ddor290 or 0000100080000010 1000000010000000 -> NaN Invalid_operation +ddor291 or 0000010090000100 1000000001000000 -> NaN Invalid_operation +ddor292 or 1000001000001000 0000000020100000 -> NaN Invalid_operation +ddor293 or 1000000100010000 0000000070010000 -> NaN Invalid_operation +ddor294 or 1000000010100000 0000000080001000 -> NaN Invalid_operation +ddor295 or 1000000001000000 0000000090000100 -> NaN Invalid_operation +-- signs +ddor296 or -1000000001000000 -0000010000000100 -> NaN Invalid_operation +ddor297 or -1000000001000000 0000000010000100 -> NaN Invalid_operation +ddor298 or 1000000001000000 -0000001000000100 -> NaN Invalid_operation +ddor299 or 1000000001000000 0000000011000100 -> 1000000011000100 + +-- Nmax, Nmin, Ntiny-like +ddor331 or 2 9.99999999E+199 -> NaN Invalid_operation +ddor332 or 3 1E-199 -> NaN Invalid_operation +ddor333 or 4 1.00000000E-199 -> NaN Invalid_operation +ddor334 or 5 1E-100 -> NaN Invalid_operation +ddor335 or 6 -1E-100 -> NaN Invalid_operation +ddor336 or 7 -1.00000000E-199 -> NaN Invalid_operation +ddor337 or 8 -1E-199 -> NaN Invalid_operation +ddor338 or 9 -9.99999999E+199 -> NaN Invalid_operation +ddor341 or 9.99999999E+299 -18 -> NaN Invalid_operation +ddor342 or 1E-299 01 -> NaN Invalid_operation +ddor343 or 1.00000000E-299 -18 -> NaN Invalid_operation +ddor344 or 1E-100 18 -> NaN Invalid_operation +ddor345 or -1E-100 -10 -> NaN Invalid_operation +ddor346 or -1.00000000E-299 18 -> NaN Invalid_operation +ddor347 or -1E-299 10 -> NaN Invalid_operation +ddor348 or -9.99999999E+299 -18 -> NaN Invalid_operation + +-- A few other non-integers +ddor361 or 1.0 1 -> NaN Invalid_operation +ddor362 or 1E+1 1 -> NaN Invalid_operation +ddor363 or 0.0 1 -> NaN Invalid_operation +ddor364 or 0E+1 1 -> NaN Invalid_operation +ddor365 or 9.9 1 -> NaN Invalid_operation +ddor366 or 9E+1 1 -> NaN Invalid_operation +ddor371 or 0 1.0 -> NaN Invalid_operation +ddor372 or 0 1E+1 -> NaN Invalid_operation +ddor373 or 0 0.0 -> NaN Invalid_operation +ddor374 or 0 0E+1 -> NaN Invalid_operation +ddor375 or 0 9.9 -> NaN Invalid_operation +ddor376 or 0 9E+1 -> NaN Invalid_operation + +-- All Specials are in error +ddor780 or -Inf -Inf -> NaN Invalid_operation +ddor781 or -Inf -1000 -> NaN Invalid_operation +ddor782 or -Inf -1 -> NaN Invalid_operation +ddor783 or -Inf -0 -> NaN Invalid_operation +ddor784 or -Inf 0 -> NaN Invalid_operation +ddor785 or -Inf 1 -> NaN Invalid_operation +ddor786 or -Inf 1000 -> NaN Invalid_operation +ddor787 or -1000 -Inf -> NaN Invalid_operation +ddor788 or -Inf -Inf -> NaN Invalid_operation +ddor789 or -1 -Inf -> NaN Invalid_operation +ddor790 or -0 -Inf -> NaN Invalid_operation +ddor791 or 0 -Inf -> NaN Invalid_operation +ddor792 or 1 -Inf -> NaN Invalid_operation +ddor793 or 1000 -Inf -> NaN Invalid_operation +ddor794 or Inf -Inf -> NaN Invalid_operation + +ddor800 or Inf -Inf -> NaN Invalid_operation +ddor801 or Inf -1000 -> NaN Invalid_operation +ddor802 or Inf -1 -> NaN Invalid_operation +ddor803 or Inf -0 -> NaN Invalid_operation +ddor804 or Inf 0 -> NaN Invalid_operation +ddor805 or Inf 1 -> NaN Invalid_operation +ddor806 or Inf 1000 -> NaN Invalid_operation +ddor807 or Inf Inf -> NaN Invalid_operation +ddor808 or -1000 Inf -> NaN Invalid_operation +ddor809 or -Inf Inf -> NaN Invalid_operation +ddor810 or -1 Inf -> NaN Invalid_operation +ddor811 or -0 Inf -> NaN Invalid_operation +ddor812 or 0 Inf -> NaN Invalid_operation +ddor813 or 1 Inf -> NaN Invalid_operation +ddor814 or 1000 Inf -> NaN Invalid_operation +ddor815 or Inf Inf -> NaN Invalid_operation + +ddor821 or NaN -Inf -> NaN Invalid_operation +ddor822 or NaN -1000 -> NaN Invalid_operation +ddor823 or NaN -1 -> NaN Invalid_operation +ddor824 or NaN -0 -> NaN Invalid_operation +ddor825 or NaN 0 -> NaN Invalid_operation +ddor826 or NaN 1 -> NaN Invalid_operation +ddor827 or NaN 1000 -> NaN Invalid_operation +ddor828 or NaN Inf -> NaN Invalid_operation +ddor829 or NaN NaN -> NaN Invalid_operation +ddor830 or -Inf NaN -> NaN Invalid_operation +ddor831 or -1000 NaN -> NaN Invalid_operation +ddor832 or -1 NaN -> NaN Invalid_operation +ddor833 or -0 NaN -> NaN Invalid_operation +ddor834 or 0 NaN -> NaN Invalid_operation +ddor835 or 1 NaN -> NaN Invalid_operation +ddor836 or 1000 NaN -> NaN Invalid_operation +ddor837 or Inf NaN -> NaN Invalid_operation + +ddor841 or sNaN -Inf -> NaN Invalid_operation +ddor842 or sNaN -1000 -> NaN Invalid_operation +ddor843 or sNaN -1 -> NaN Invalid_operation +ddor844 or sNaN -0 -> NaN Invalid_operation +ddor845 or sNaN 0 -> NaN Invalid_operation +ddor846 or sNaN 1 -> NaN Invalid_operation +ddor847 or sNaN 1000 -> NaN Invalid_operation +ddor848 or sNaN NaN -> NaN Invalid_operation +ddor849 or sNaN sNaN -> NaN Invalid_operation +ddor850 or NaN sNaN -> NaN Invalid_operation +ddor851 or -Inf sNaN -> NaN Invalid_operation +ddor852 or -1000 sNaN -> NaN Invalid_operation +ddor853 or -1 sNaN -> NaN Invalid_operation +ddor854 or -0 sNaN -> NaN Invalid_operation +ddor855 or 0 sNaN -> NaN Invalid_operation +ddor856 or 1 sNaN -> NaN Invalid_operation +ddor857 or 1000 sNaN -> NaN Invalid_operation +ddor858 or Inf sNaN -> NaN Invalid_operation +ddor859 or NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +ddor861 or NaN1 -Inf -> NaN Invalid_operation +ddor862 or +NaN2 -1000 -> NaN Invalid_operation +ddor863 or NaN3 1000 -> NaN Invalid_operation +ddor864 or NaN4 Inf -> NaN Invalid_operation +ddor865 or NaN5 +NaN6 -> NaN Invalid_operation +ddor866 or -Inf NaN7 -> NaN Invalid_operation +ddor867 or -1000 NaN8 -> NaN Invalid_operation +ddor868 or 1000 NaN9 -> NaN Invalid_operation +ddor869 or Inf +NaN10 -> NaN Invalid_operation +ddor871 or sNaN11 -Inf -> NaN Invalid_operation +ddor872 or sNaN12 -1000 -> NaN Invalid_operation +ddor873 or sNaN13 1000 -> NaN Invalid_operation +ddor874 or sNaN14 NaN17 -> NaN Invalid_operation +ddor875 or sNaN15 sNaN18 -> NaN Invalid_operation +ddor876 or NaN16 sNaN19 -> NaN Invalid_operation +ddor877 or -Inf +sNaN20 -> NaN Invalid_operation +ddor878 or -1000 sNaN21 -> NaN Invalid_operation +ddor879 or 1000 sNaN22 -> NaN Invalid_operation +ddor880 or Inf sNaN23 -> NaN Invalid_operation +ddor881 or +NaN25 +sNaN24 -> NaN Invalid_operation +ddor882 or -NaN26 NaN28 -> NaN Invalid_operation +ddor883 or -sNaN27 sNaN29 -> NaN Invalid_operation +ddor884 or 1000 -NaN30 -> NaN Invalid_operation +ddor885 or 1000 -sNaN31 -> NaN Invalid_operation Added: python/branches/release25-maint/Lib/test/decimaltestdata/ddPlus.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/ddPlus.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,88 @@ +------------------------------------------------------------------------ +-- ddPlus.decTest -- decDouble 0+x -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- All operands and results are decDoubles. +precision: 16 +maxExponent: 384 +minExponent: -383 +extended: 1 +clamp: 1 +rounding: half_even + +-- Sanity check +ddpls001 plus +7.50 -> 7.50 + +-- Infinities +ddpls011 plus Infinity -> Infinity +ddpls012 plus -Infinity -> -Infinity + +-- NaNs, 0 payload +ddpls021 plus NaN -> NaN +ddpls022 plus -NaN -> -NaN +ddpls023 plus sNaN -> NaN Invalid_operation +ddpls024 plus -sNaN -> -NaN Invalid_operation + +-- NaNs, non-0 payload +ddpls031 plus NaN13 -> NaN13 +ddpls032 plus -NaN13 -> -NaN13 +ddpls033 plus sNaN13 -> NaN13 Invalid_operation +ddpls034 plus -sNaN13 -> -NaN13 Invalid_operation +ddpls035 plus NaN70 -> NaN70 +ddpls036 plus -NaN70 -> -NaN70 +ddpls037 plus sNaN101 -> NaN101 Invalid_operation +ddpls038 plus -sNaN101 -> -NaN101 Invalid_operation + +-- finites +ddpls101 plus 7 -> 7 +ddpls102 plus -7 -> -7 +ddpls103 plus 75 -> 75 +ddpls104 plus -75 -> -75 +ddpls105 plus 7.50 -> 7.50 +ddpls106 plus -7.50 -> -7.50 +ddpls107 plus 7.500 -> 7.500 +ddpls108 plus -7.500 -> -7.500 + +-- zeros +ddpls111 plus 0 -> 0 +ddpls112 plus -0 -> 0 +ddpls113 plus 0E+4 -> 0E+4 +ddpls114 plus -0E+4 -> 0E+4 +ddpls115 plus 0.0000 -> 0.0000 +ddpls116 plus -0.0000 -> 0.0000 +ddpls117 plus 0E-141 -> 0E-141 +ddpls118 plus -0E-141 -> 0E-141 + +-- full coefficients, alternating bits +ddpls121 plus 2682682682682682 -> 2682682682682682 +ddpls122 plus -2682682682682682 -> -2682682682682682 +ddpls123 plus 1341341341341341 -> 1341341341341341 +ddpls124 plus -1341341341341341 -> -1341341341341341 + +-- Nmax, Nmin, Ntiny +ddpls131 plus 9.999999999999999E+384 -> 9.999999999999999E+384 +ddpls132 plus 1E-383 -> 1E-383 +ddpls133 plus 1.000000000000000E-383 -> 1.000000000000000E-383 +ddpls134 plus 1E-398 -> 1E-398 Subnormal + +ddpls135 plus -1E-398 -> -1E-398 Subnormal +ddpls136 plus -1.000000000000000E-383 -> -1.000000000000000E-383 +ddpls137 plus -1E-383 -> -1E-383 +ddpls138 plus -9.999999999999999E+384 -> -9.999999999999999E+384 Added: python/branches/release25-maint/Lib/test/decimaltestdata/ddQuantize.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/ddQuantize.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,825 @@ +------------------------------------------------------------------------ +-- ddQuantize.decTest -- decDouble quantize operation -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- Most of the tests here assume a "regular pattern", where the +-- sign and coefficient are +1. +-- 2004.03.15 Underflow for quantize is suppressed +-- 2005.06.08 More extensive tests for 'does not fit' +precision: 16 +maxExponent: 384 +minExponent: -383 +extended: 1 +clamp: 1 +rounding: half_even + +-- sanity checks +ddqua001 quantize 0 1e0 -> 0 +ddqua002 quantize 1 1e0 -> 1 +ddqua003 quantize 0.1 1e+2 -> 0E+2 Inexact Rounded +ddqua005 quantize 0.1 1e+1 -> 0E+1 Inexact Rounded +ddqua006 quantize 0.1 1e0 -> 0 Inexact Rounded +ddqua007 quantize 0.1 1e-1 -> 0.1 +ddqua008 quantize 0.1 1e-2 -> 0.10 +ddqua009 quantize 0.1 1e-3 -> 0.100 +ddqua010 quantize 0.9 1e+2 -> 0E+2 Inexact Rounded +ddqua011 quantize 0.9 1e+1 -> 0E+1 Inexact Rounded +ddqua012 quantize 0.9 1e+0 -> 1 Inexact Rounded +ddqua013 quantize 0.9 1e-1 -> 0.9 +ddqua014 quantize 0.9 1e-2 -> 0.90 +ddqua015 quantize 0.9 1e-3 -> 0.900 +-- negatives +ddqua021 quantize -0 1e0 -> -0 +ddqua022 quantize -1 1e0 -> -1 +ddqua023 quantize -0.1 1e+2 -> -0E+2 Inexact Rounded +ddqua025 quantize -0.1 1e+1 -> -0E+1 Inexact Rounded +ddqua026 quantize -0.1 1e0 -> -0 Inexact Rounded +ddqua027 quantize -0.1 1e-1 -> -0.1 +ddqua028 quantize -0.1 1e-2 -> -0.10 +ddqua029 quantize -0.1 1e-3 -> -0.100 +ddqua030 quantize -0.9 1e+2 -> -0E+2 Inexact Rounded +ddqua031 quantize -0.9 1e+1 -> -0E+1 Inexact Rounded +ddqua032 quantize -0.9 1e+0 -> -1 Inexact Rounded +ddqua033 quantize -0.9 1e-1 -> -0.9 +ddqua034 quantize -0.9 1e-2 -> -0.90 +ddqua035 quantize -0.9 1e-3 -> -0.900 +ddqua036 quantize -0.5 1e+2 -> -0E+2 Inexact Rounded +ddqua037 quantize -0.5 1e+1 -> -0E+1 Inexact Rounded +ddqua038 quantize -0.5 1e+0 -> -0 Inexact Rounded +ddqua039 quantize -0.5 1e-1 -> -0.5 +ddqua040 quantize -0.5 1e-2 -> -0.50 +ddqua041 quantize -0.5 1e-3 -> -0.500 +ddqua042 quantize -0.9 1e+2 -> -0E+2 Inexact Rounded +ddqua043 quantize -0.9 1e+1 -> -0E+1 Inexact Rounded +ddqua044 quantize -0.9 1e+0 -> -1 Inexact Rounded +ddqua045 quantize -0.9 1e-1 -> -0.9 +ddqua046 quantize -0.9 1e-2 -> -0.90 +ddqua047 quantize -0.9 1e-3 -> -0.900 + +-- examples from Specification +ddqua060 quantize 2.17 0.001 -> 2.170 +ddqua061 quantize 2.17 0.01 -> 2.17 +ddqua062 quantize 2.17 0.1 -> 2.2 Inexact Rounded +ddqua063 quantize 2.17 1e+0 -> 2 Inexact Rounded +ddqua064 quantize 2.17 1e+1 -> 0E+1 Inexact Rounded +ddqua065 quantize -Inf Inf -> -Infinity +ddqua066 quantize 2 Inf -> NaN Invalid_operation +ddqua067 quantize -0.1 1 -> -0 Inexact Rounded +ddqua068 quantize -0 1e+5 -> -0E+5 +ddqua069 quantize +123456789012345.6 1e-2 -> NaN Invalid_operation +ddqua070 quantize -987654335236450.6 1e-2 -> NaN Invalid_operation +ddqua071 quantize 217 1e-1 -> 217.0 +ddqua072 quantize 217 1e+0 -> 217 +ddqua073 quantize 217 1e+1 -> 2.2E+2 Inexact Rounded +ddqua074 quantize 217 1e+2 -> 2E+2 Inexact Rounded + +-- general tests .. +ddqua089 quantize 12 1e+4 -> 0E+4 Inexact Rounded +ddqua090 quantize 12 1e+3 -> 0E+3 Inexact Rounded +ddqua091 quantize 12 1e+2 -> 0E+2 Inexact Rounded +ddqua092 quantize 12 1e+1 -> 1E+1 Inexact Rounded +ddqua093 quantize 1.2345 1e-2 -> 1.23 Inexact Rounded +ddqua094 quantize 1.2355 1e-2 -> 1.24 Inexact Rounded +ddqua095 quantize 1.2345 1e-6 -> 1.234500 +ddqua096 quantize 9.9999 1e-2 -> 10.00 Inexact Rounded +ddqua097 quantize 0.0001 1e-2 -> 0.00 Inexact Rounded +ddqua098 quantize 0.001 1e-2 -> 0.00 Inexact Rounded +ddqua099 quantize 0.009 1e-2 -> 0.01 Inexact Rounded +ddqua100 quantize 92 1e+2 -> 1E+2 Inexact Rounded + +ddqua101 quantize -1 1e0 -> -1 +ddqua102 quantize -1 1e-1 -> -1.0 +ddqua103 quantize -1 1e-2 -> -1.00 +ddqua104 quantize 0 1e0 -> 0 +ddqua105 quantize 0 1e-1 -> 0.0 +ddqua106 quantize 0 1e-2 -> 0.00 +ddqua107 quantize 0.00 1e0 -> 0 +ddqua108 quantize 0 1e+1 -> 0E+1 +ddqua109 quantize 0 1e+2 -> 0E+2 +ddqua110 quantize +1 1e0 -> 1 +ddqua111 quantize +1 1e-1 -> 1.0 +ddqua112 quantize +1 1e-2 -> 1.00 + +ddqua120 quantize 1.04 1e-3 -> 1.040 +ddqua121 quantize 1.04 1e-2 -> 1.04 +ddqua122 quantize 1.04 1e-1 -> 1.0 Inexact Rounded +ddqua123 quantize 1.04 1e0 -> 1 Inexact Rounded +ddqua124 quantize 1.05 1e-3 -> 1.050 +ddqua125 quantize 1.05 1e-2 -> 1.05 +ddqua126 quantize 1.05 1e-1 -> 1.0 Inexact Rounded +ddqua131 quantize 1.05 1e0 -> 1 Inexact Rounded +ddqua132 quantize 1.06 1e-3 -> 1.060 +ddqua133 quantize 1.06 1e-2 -> 1.06 +ddqua134 quantize 1.06 1e-1 -> 1.1 Inexact Rounded +ddqua135 quantize 1.06 1e0 -> 1 Inexact Rounded + +ddqua140 quantize -10 1e-2 -> -10.00 +ddqua141 quantize +1 1e-2 -> 1.00 +ddqua142 quantize +10 1e-2 -> 10.00 +ddqua143 quantize 1E+17 1e-2 -> NaN Invalid_operation +ddqua144 quantize 1E-17 1e-2 -> 0.00 Inexact Rounded +ddqua145 quantize 1E-3 1e-2 -> 0.00 Inexact Rounded +ddqua146 quantize 1E-2 1e-2 -> 0.01 +ddqua147 quantize 1E-1 1e-2 -> 0.10 +ddqua148 quantize 0E-17 1e-2 -> 0.00 + +ddqua150 quantize 1.0600 1e-5 -> 1.06000 +ddqua151 quantize 1.0600 1e-4 -> 1.0600 +ddqua152 quantize 1.0600 1e-3 -> 1.060 Rounded +ddqua153 quantize 1.0600 1e-2 -> 1.06 Rounded +ddqua154 quantize 1.0600 1e-1 -> 1.1 Inexact Rounded +ddqua155 quantize 1.0600 1e0 -> 1 Inexact Rounded + +-- a couple where rounding was different in base tests +rounding: half_up +ddqua157 quantize -0.5 1e+0 -> -1 Inexact Rounded +ddqua158 quantize 1.05 1e-1 -> 1.1 Inexact Rounded +ddqua159 quantize 1.06 1e0 -> 1 Inexact Rounded +rounding: half_even + +-- base tests with non-1 coefficients +ddqua161 quantize 0 -9e0 -> 0 +ddqua162 quantize 1 -7e0 -> 1 +ddqua163 quantize 0.1 -1e+2 -> 0E+2 Inexact Rounded +ddqua165 quantize 0.1 0e+1 -> 0E+1 Inexact Rounded +ddqua166 quantize 0.1 2e0 -> 0 Inexact Rounded +ddqua167 quantize 0.1 3e-1 -> 0.1 +ddqua168 quantize 0.1 44e-2 -> 0.10 +ddqua169 quantize 0.1 555e-3 -> 0.100 +ddqua170 quantize 0.9 6666e+2 -> 0E+2 Inexact Rounded +ddqua171 quantize 0.9 -777e+1 -> 0E+1 Inexact Rounded +ddqua172 quantize 0.9 -88e+0 -> 1 Inexact Rounded +ddqua173 quantize 0.9 -9e-1 -> 0.9 +ddqua174 quantize 0.9 0e-2 -> 0.90 +ddqua175 quantize 0.9 1.1e-3 -> 0.9000 +-- negatives +ddqua181 quantize -0 1.1e0 -> -0.0 +ddqua182 quantize -1 -1e0 -> -1 +ddqua183 quantize -0.1 11e+2 -> -0E+2 Inexact Rounded +ddqua185 quantize -0.1 111e+1 -> -0E+1 Inexact Rounded +ddqua186 quantize -0.1 71e0 -> -0 Inexact Rounded +ddqua187 quantize -0.1 -91e-1 -> -0.1 +ddqua188 quantize -0.1 -.1e-2 -> -0.100 +ddqua189 quantize -0.1 -1e-3 -> -0.100 +ddqua190 quantize -0.9 0e+2 -> -0E+2 Inexact Rounded +ddqua191 quantize -0.9 -0e+1 -> -0E+1 Inexact Rounded +ddqua192 quantize -0.9 -10e+0 -> -1 Inexact Rounded +ddqua193 quantize -0.9 100e-1 -> -0.9 +ddqua194 quantize -0.9 999e-2 -> -0.90 + +-- +ve exponents .. +ddqua201 quantize -1 1e+0 -> -1 +ddqua202 quantize -1 1e+1 -> -0E+1 Inexact Rounded +ddqua203 quantize -1 1e+2 -> -0E+2 Inexact Rounded +ddqua204 quantize 0 1e+0 -> 0 +ddqua205 quantize 0 1e+1 -> 0E+1 +ddqua206 quantize 0 1e+2 -> 0E+2 +ddqua207 quantize +1 1e+0 -> 1 +ddqua208 quantize +1 1e+1 -> 0E+1 Inexact Rounded +ddqua209 quantize +1 1e+2 -> 0E+2 Inexact Rounded + +ddqua220 quantize 1.04 1e+3 -> 0E+3 Inexact Rounded +ddqua221 quantize 1.04 1e+2 -> 0E+2 Inexact Rounded +ddqua222 quantize 1.04 1e+1 -> 0E+1 Inexact Rounded +ddqua223 quantize 1.04 1e+0 -> 1 Inexact Rounded +ddqua224 quantize 1.05 1e+3 -> 0E+3 Inexact Rounded +ddqua225 quantize 1.05 1e+2 -> 0E+2 Inexact Rounded +ddqua226 quantize 1.05 1e+1 -> 0E+1 Inexact Rounded +ddqua227 quantize 1.05 1e+0 -> 1 Inexact Rounded +ddqua228 quantize 1.05 1e+3 -> 0E+3 Inexact Rounded +ddqua229 quantize 1.05 1e+2 -> 0E+2 Inexact Rounded +ddqua230 quantize 1.05 1e+1 -> 0E+1 Inexact Rounded +ddqua231 quantize 1.05 1e+0 -> 1 Inexact Rounded +ddqua232 quantize 1.06 1e+3 -> 0E+3 Inexact Rounded +ddqua233 quantize 1.06 1e+2 -> 0E+2 Inexact Rounded +ddqua234 quantize 1.06 1e+1 -> 0E+1 Inexact Rounded +ddqua235 quantize 1.06 1e+0 -> 1 Inexact Rounded + +ddqua240 quantize -10 1e+1 -> -1E+1 Rounded +ddqua241 quantize +1 1e+1 -> 0E+1 Inexact Rounded +ddqua242 quantize +10 1e+1 -> 1E+1 Rounded +ddqua243 quantize 1E+1 1e+1 -> 1E+1 -- underneath this is E+1 +ddqua244 quantize 1E+2 1e+1 -> 1.0E+2 -- underneath this is E+1 +ddqua245 quantize 1E+3 1e+1 -> 1.00E+3 -- underneath this is E+1 +ddqua246 quantize 1E+4 1e+1 -> 1.000E+4 -- underneath this is E+1 +ddqua247 quantize 1E+5 1e+1 -> 1.0000E+5 -- underneath this is E+1 +ddqua248 quantize 1E+6 1e+1 -> 1.00000E+6 -- underneath this is E+1 +ddqua249 quantize 1E+7 1e+1 -> 1.000000E+7 -- underneath this is E+1 +ddqua250 quantize 1E+8 1e+1 -> 1.0000000E+8 -- underneath this is E+1 +ddqua251 quantize 1E+9 1e+1 -> 1.00000000E+9 -- underneath this is E+1 +-- next one tries to add 9 zeros +ddqua252 quantize 1E+17 1e+1 -> NaN Invalid_operation +ddqua253 quantize 1E-17 1e+1 -> 0E+1 Inexact Rounded +ddqua254 quantize 1E-2 1e+1 -> 0E+1 Inexact Rounded +ddqua255 quantize 0E-17 1e+1 -> 0E+1 +ddqua256 quantize -0E-17 1e+1 -> -0E+1 +ddqua257 quantize -0E-1 1e+1 -> -0E+1 +ddqua258 quantize -0 1e+1 -> -0E+1 +ddqua259 quantize -0E+1 1e+1 -> -0E+1 + +ddqua260 quantize -10 1e+2 -> -0E+2 Inexact Rounded +ddqua261 quantize +1 1e+2 -> 0E+2 Inexact Rounded +ddqua262 quantize +10 1e+2 -> 0E+2 Inexact Rounded +ddqua263 quantize 1E+1 1e+2 -> 0E+2 Inexact Rounded +ddqua264 quantize 1E+2 1e+2 -> 1E+2 +ddqua265 quantize 1E+3 1e+2 -> 1.0E+3 +ddqua266 quantize 1E+4 1e+2 -> 1.00E+4 +ddqua267 quantize 1E+5 1e+2 -> 1.000E+5 +ddqua268 quantize 1E+6 1e+2 -> 1.0000E+6 +ddqua269 quantize 1E+7 1e+2 -> 1.00000E+7 +ddqua270 quantize 1E+8 1e+2 -> 1.000000E+8 +ddqua271 quantize 1E+9 1e+2 -> 1.0000000E+9 +ddqua272 quantize 1E+10 1e+2 -> 1.00000000E+10 +ddqua273 quantize 1E-10 1e+2 -> 0E+2 Inexact Rounded +ddqua274 quantize 1E-2 1e+2 -> 0E+2 Inexact Rounded +ddqua275 quantize 0E-10 1e+2 -> 0E+2 + +ddqua280 quantize -10 1e+3 -> -0E+3 Inexact Rounded +ddqua281 quantize +1 1e+3 -> 0E+3 Inexact Rounded +ddqua282 quantize +10 1e+3 -> 0E+3 Inexact Rounded +ddqua283 quantize 1E+1 1e+3 -> 0E+3 Inexact Rounded +ddqua284 quantize 1E+2 1e+3 -> 0E+3 Inexact Rounded +ddqua285 quantize 1E+3 1e+3 -> 1E+3 +ddqua286 quantize 1E+4 1e+3 -> 1.0E+4 +ddqua287 quantize 1E+5 1e+3 -> 1.00E+5 +ddqua288 quantize 1E+6 1e+3 -> 1.000E+6 +ddqua289 quantize 1E+7 1e+3 -> 1.0000E+7 +ddqua290 quantize 1E+8 1e+3 -> 1.00000E+8 +ddqua291 quantize 1E+9 1e+3 -> 1.000000E+9 +ddqua292 quantize 1E+10 1e+3 -> 1.0000000E+10 +ddqua293 quantize 1E-10 1e+3 -> 0E+3 Inexact Rounded +ddqua294 quantize 1E-2 1e+3 -> 0E+3 Inexact Rounded +ddqua295 quantize 0E-10 1e+3 -> 0E+3 + +-- round up from below [sign wrong in JIT compiler once] +ddqua300 quantize 0.0078 1e-5 -> 0.00780 +ddqua301 quantize 0.0078 1e-4 -> 0.0078 +ddqua302 quantize 0.0078 1e-3 -> 0.008 Inexact Rounded +ddqua303 quantize 0.0078 1e-2 -> 0.01 Inexact Rounded +ddqua304 quantize 0.0078 1e-1 -> 0.0 Inexact Rounded +ddqua305 quantize 0.0078 1e0 -> 0 Inexact Rounded +ddqua306 quantize 0.0078 1e+1 -> 0E+1 Inexact Rounded +ddqua307 quantize 0.0078 1e+2 -> 0E+2 Inexact Rounded + +ddqua310 quantize -0.0078 1e-5 -> -0.00780 +ddqua311 quantize -0.0078 1e-4 -> -0.0078 +ddqua312 quantize -0.0078 1e-3 -> -0.008 Inexact Rounded +ddqua313 quantize -0.0078 1e-2 -> -0.01 Inexact Rounded +ddqua314 quantize -0.0078 1e-1 -> -0.0 Inexact Rounded +ddqua315 quantize -0.0078 1e0 -> -0 Inexact Rounded +ddqua316 quantize -0.0078 1e+1 -> -0E+1 Inexact Rounded +ddqua317 quantize -0.0078 1e+2 -> -0E+2 Inexact Rounded + +ddqua320 quantize 0.078 1e-5 -> 0.07800 +ddqua321 quantize 0.078 1e-4 -> 0.0780 +ddqua322 quantize 0.078 1e-3 -> 0.078 +ddqua323 quantize 0.078 1e-2 -> 0.08 Inexact Rounded +ddqua324 quantize 0.078 1e-1 -> 0.1 Inexact Rounded +ddqua325 quantize 0.078 1e0 -> 0 Inexact Rounded +ddqua326 quantize 0.078 1e+1 -> 0E+1 Inexact Rounded +ddqua327 quantize 0.078 1e+2 -> 0E+2 Inexact Rounded + +ddqua330 quantize -0.078 1e-5 -> -0.07800 +ddqua331 quantize -0.078 1e-4 -> -0.0780 +ddqua332 quantize -0.078 1e-3 -> -0.078 +ddqua333 quantize -0.078 1e-2 -> -0.08 Inexact Rounded +ddqua334 quantize -0.078 1e-1 -> -0.1 Inexact Rounded +ddqua335 quantize -0.078 1e0 -> -0 Inexact Rounded +ddqua336 quantize -0.078 1e+1 -> -0E+1 Inexact Rounded +ddqua337 quantize -0.078 1e+2 -> -0E+2 Inexact Rounded + +ddqua340 quantize 0.78 1e-5 -> 0.78000 +ddqua341 quantize 0.78 1e-4 -> 0.7800 +ddqua342 quantize 0.78 1e-3 -> 0.780 +ddqua343 quantize 0.78 1e-2 -> 0.78 +ddqua344 quantize 0.78 1e-1 -> 0.8 Inexact Rounded +ddqua345 quantize 0.78 1e0 -> 1 Inexact Rounded +ddqua346 quantize 0.78 1e+1 -> 0E+1 Inexact Rounded +ddqua347 quantize 0.78 1e+2 -> 0E+2 Inexact Rounded + +ddqua350 quantize -0.78 1e-5 -> -0.78000 +ddqua351 quantize -0.78 1e-4 -> -0.7800 +ddqua352 quantize -0.78 1e-3 -> -0.780 +ddqua353 quantize -0.78 1e-2 -> -0.78 +ddqua354 quantize -0.78 1e-1 -> -0.8 Inexact Rounded +ddqua355 quantize -0.78 1e0 -> -1 Inexact Rounded +ddqua356 quantize -0.78 1e+1 -> -0E+1 Inexact Rounded +ddqua357 quantize -0.78 1e+2 -> -0E+2 Inexact Rounded + +ddqua360 quantize 7.8 1e-5 -> 7.80000 +ddqua361 quantize 7.8 1e-4 -> 7.8000 +ddqua362 quantize 7.8 1e-3 -> 7.800 +ddqua363 quantize 7.8 1e-2 -> 7.80 +ddqua364 quantize 7.8 1e-1 -> 7.8 +ddqua365 quantize 7.8 1e0 -> 8 Inexact Rounded +ddqua366 quantize 7.8 1e+1 -> 1E+1 Inexact Rounded +ddqua367 quantize 7.8 1e+2 -> 0E+2 Inexact Rounded +ddqua368 quantize 7.8 1e+3 -> 0E+3 Inexact Rounded + +ddqua370 quantize -7.8 1e-5 -> -7.80000 +ddqua371 quantize -7.8 1e-4 -> -7.8000 +ddqua372 quantize -7.8 1e-3 -> -7.800 +ddqua373 quantize -7.8 1e-2 -> -7.80 +ddqua374 quantize -7.8 1e-1 -> -7.8 +ddqua375 quantize -7.8 1e0 -> -8 Inexact Rounded +ddqua376 quantize -7.8 1e+1 -> -1E+1 Inexact Rounded +ddqua377 quantize -7.8 1e+2 -> -0E+2 Inexact Rounded +ddqua378 quantize -7.8 1e+3 -> -0E+3 Inexact Rounded + +-- some individuals +ddqua380 quantize 1234567352364.506 1e-2 -> 1234567352364.51 Inexact Rounded +ddqua381 quantize 12345673523645.06 1e-2 -> 12345673523645.06 +ddqua382 quantize 123456735236450.6 1e-2 -> NaN Invalid_operation +ddqua383 quantize 1234567352364506 1e-2 -> NaN Invalid_operation +ddqua384 quantize -1234567352364.506 1e-2 -> -1234567352364.51 Inexact Rounded +ddqua385 quantize -12345673523645.06 1e-2 -> -12345673523645.06 +ddqua386 quantize -123456735236450.6 1e-2 -> NaN Invalid_operation +ddqua387 quantize -1234567352364506 1e-2 -> NaN Invalid_operation + +rounding: down +ddqua389 quantize 123456735236450.6 1e-2 -> NaN Invalid_operation +-- ? should that one instead have been: +-- ddqua389 quantize 123456735236450.6 1e-2 -> NaN Invalid_operation +rounding: half_up + +-- and a few more from e-mail discussions +ddqua391 quantize 12345678912.34567 1e-3 -> 12345678912.346 Inexact Rounded +ddqua392 quantize 123456789123.4567 1e-3 -> 123456789123.457 Inexact Rounded +ddqua393 quantize 1234567891234.567 1e-3 -> 1234567891234.567 +ddqua394 quantize 12345678912345.67 1e-3 -> NaN Invalid_operation +ddqua395 quantize 123456789123456.7 1e-3 -> NaN Invalid_operation +ddqua396 quantize 1234567891234567. 1e-3 -> NaN Invalid_operation + +-- some 9999 round-up cases +ddqua400 quantize 9.999 1e-5 -> 9.99900 +ddqua401 quantize 9.999 1e-4 -> 9.9990 +ddqua402 quantize 9.999 1e-3 -> 9.999 +ddqua403 quantize 9.999 1e-2 -> 10.00 Inexact Rounded +ddqua404 quantize 9.999 1e-1 -> 10.0 Inexact Rounded +ddqua405 quantize 9.999 1e0 -> 10 Inexact Rounded +ddqua406 quantize 9.999 1e1 -> 1E+1 Inexact Rounded +ddqua407 quantize 9.999 1e2 -> 0E+2 Inexact Rounded + +ddqua410 quantize 0.999 1e-5 -> 0.99900 +ddqua411 quantize 0.999 1e-4 -> 0.9990 +ddqua412 quantize 0.999 1e-3 -> 0.999 +ddqua413 quantize 0.999 1e-2 -> 1.00 Inexact Rounded +ddqua414 quantize 0.999 1e-1 -> 1.0 Inexact Rounded +ddqua415 quantize 0.999 1e0 -> 1 Inexact Rounded +ddqua416 quantize 0.999 1e1 -> 0E+1 Inexact Rounded + +ddqua420 quantize 0.0999 1e-5 -> 0.09990 +ddqua421 quantize 0.0999 1e-4 -> 0.0999 +ddqua422 quantize 0.0999 1e-3 -> 0.100 Inexact Rounded +ddqua423 quantize 0.0999 1e-2 -> 0.10 Inexact Rounded +ddqua424 quantize 0.0999 1e-1 -> 0.1 Inexact Rounded +ddqua425 quantize 0.0999 1e0 -> 0 Inexact Rounded +ddqua426 quantize 0.0999 1e1 -> 0E+1 Inexact Rounded + +ddqua430 quantize 0.00999 1e-5 -> 0.00999 +ddqua431 quantize 0.00999 1e-4 -> 0.0100 Inexact Rounded +ddqua432 quantize 0.00999 1e-3 -> 0.010 Inexact Rounded +ddqua433 quantize 0.00999 1e-2 -> 0.01 Inexact Rounded +ddqua434 quantize 0.00999 1e-1 -> 0.0 Inexact Rounded +ddqua435 quantize 0.00999 1e0 -> 0 Inexact Rounded +ddqua436 quantize 0.00999 1e1 -> 0E+1 Inexact Rounded + +ddqua440 quantize 0.000999 1e-5 -> 0.00100 Inexact Rounded +ddqua441 quantize 0.000999 1e-4 -> 0.0010 Inexact Rounded +ddqua442 quantize 0.000999 1e-3 -> 0.001 Inexact Rounded +ddqua443 quantize 0.000999 1e-2 -> 0.00 Inexact Rounded +ddqua444 quantize 0.000999 1e-1 -> 0.0 Inexact Rounded +ddqua445 quantize 0.000999 1e0 -> 0 Inexact Rounded +ddqua446 quantize 0.000999 1e1 -> 0E+1 Inexact Rounded + +ddqua1001 quantize 0.000 0.001 -> 0.000 +ddqua1002 quantize 0.001 0.001 -> 0.001 +ddqua1003 quantize 0.0012 0.001 -> 0.001 Inexact Rounded +ddqua1004 quantize 0.0018 0.001 -> 0.002 Inexact Rounded +ddqua1005 quantize 0.501 0.001 -> 0.501 +ddqua1006 quantize 0.5012 0.001 -> 0.501 Inexact Rounded +ddqua1007 quantize 0.5018 0.001 -> 0.502 Inexact Rounded +ddqua1008 quantize 0.999 0.001 -> 0.999 + +ddqua481 quantize 12345678000 1e+3 -> 1.2345678E+10 Rounded +ddqua482 quantize 1234567800 1e+1 -> 1.23456780E+9 Rounded +ddqua483 quantize 1234567890 1e+1 -> 1.23456789E+9 Rounded +ddqua484 quantize 1234567891 1e+1 -> 1.23456789E+9 Inexact Rounded +ddqua485 quantize 12345678901 1e+2 -> 1.23456789E+10 Inexact Rounded +ddqua486 quantize 1234567896 1e+1 -> 1.23456790E+9 Inexact Rounded +-- a potential double-round +ddqua487 quantize 1234.987643 1e-4 -> 1234.9876 Inexact Rounded +ddqua488 quantize 1234.987647 1e-4 -> 1234.9876 Inexact Rounded + +ddqua491 quantize 12345678000 1e+3 -> 1.2345678E+10 Rounded +ddqua492 quantize 1234567800 1e+1 -> 1.23456780E+9 Rounded +ddqua493 quantize 1234567890 1e+1 -> 1.23456789E+9 Rounded +ddqua494 quantize 1234567891 1e+1 -> 1.23456789E+9 Inexact Rounded +ddqua495 quantize 12345678901 1e+2 -> 1.23456789E+10 Inexact Rounded +ddqua496 quantize 1234567896 1e+1 -> 1.23456790E+9 Inexact Rounded +ddqua497 quantize 1234.987643 1e-4 -> 1234.9876 Inexact Rounded +ddqua498 quantize 1234.987647 1e-4 -> 1234.9876 Inexact Rounded + +-- Zeros +ddqua500 quantize 0 1e1 -> 0E+1 +ddqua501 quantize 0 1e0 -> 0 +ddqua502 quantize 0 1e-1 -> 0.0 +ddqua503 quantize 0.0 1e-1 -> 0.0 +ddqua504 quantize 0.0 1e0 -> 0 +ddqua505 quantize 0.0 1e+1 -> 0E+1 +ddqua506 quantize 0E+1 1e-1 -> 0.0 +ddqua507 quantize 0E+1 1e0 -> 0 +ddqua508 quantize 0E+1 1e+1 -> 0E+1 +ddqua509 quantize -0 1e1 -> -0E+1 +ddqua510 quantize -0 1e0 -> -0 +ddqua511 quantize -0 1e-1 -> -0.0 +ddqua512 quantize -0.0 1e-1 -> -0.0 +ddqua513 quantize -0.0 1e0 -> -0 +ddqua514 quantize -0.0 1e+1 -> -0E+1 +ddqua515 quantize -0E+1 1e-1 -> -0.0 +ddqua516 quantize -0E+1 1e0 -> -0 +ddqua517 quantize -0E+1 1e+1 -> -0E+1 + +-- Suspicious RHS values +ddqua520 quantize 1.234 1e359 -> 0E+359 Inexact Rounded +ddqua521 quantize 123.456 1e359 -> 0E+359 Inexact Rounded +ddqua522 quantize 1.234 1e359 -> 0E+359 Inexact Rounded +ddqua523 quantize 123.456 1e359 -> 0E+359 Inexact Rounded +-- next four are "won't fit" overfl +ddqua526 quantize 1.234 1e-299 -> NaN Invalid_operation +ddqua527 quantize 123.456 1e-299 -> NaN Invalid_operation +ddqua528 quantize 1.234 1e-299 -> NaN Invalid_operation +ddqua529 quantize 123.456 1e-299 -> NaN Invalid_operation + +ddqua532 quantize 1.234E+299 1e299 -> 1E+299 Inexact Rounded +ddqua533 quantize 1.234E+298 1e299 -> 0E+299 Inexact Rounded +ddqua534 quantize 1.234 1e299 -> 0E+299 Inexact Rounded +ddqua537 quantize 0 1e-299 -> 0E-299 +-- next two are "won't fit" overflows +ddqua538 quantize 1.234 1e-299 -> NaN Invalid_operation +ddqua539 quantize 1.234 1e-300 -> NaN Invalid_operation +-- [more below] + +-- Specials +ddqua580 quantize Inf -Inf -> Infinity +ddqua581 quantize Inf 1e-299 -> NaN Invalid_operation +ddqua582 quantize Inf 1e-1 -> NaN Invalid_operation +ddqua583 quantize Inf 1e0 -> NaN Invalid_operation +ddqua584 quantize Inf 1e1 -> NaN Invalid_operation +ddqua585 quantize Inf 1e299 -> NaN Invalid_operation +ddqua586 quantize Inf Inf -> Infinity +ddqua587 quantize -1000 Inf -> NaN Invalid_operation +ddqua588 quantize -Inf Inf -> -Infinity +ddqua589 quantize -1 Inf -> NaN Invalid_operation +ddqua590 quantize 0 Inf -> NaN Invalid_operation +ddqua591 quantize 1 Inf -> NaN Invalid_operation +ddqua592 quantize 1000 Inf -> NaN Invalid_operation +ddqua593 quantize Inf Inf -> Infinity +ddqua594 quantize Inf 1e-0 -> NaN Invalid_operation +ddqua595 quantize -0 Inf -> NaN Invalid_operation + +ddqua600 quantize -Inf -Inf -> -Infinity +ddqua601 quantize -Inf 1e-299 -> NaN Invalid_operation +ddqua602 quantize -Inf 1e-1 -> NaN Invalid_operation +ddqua603 quantize -Inf 1e0 -> NaN Invalid_operation +ddqua604 quantize -Inf 1e1 -> NaN Invalid_operation +ddqua605 quantize -Inf 1e299 -> NaN Invalid_operation +ddqua606 quantize -Inf Inf -> -Infinity +ddqua607 quantize -1000 Inf -> NaN Invalid_operation +ddqua608 quantize -Inf -Inf -> -Infinity +ddqua609 quantize -1 -Inf -> NaN Invalid_operation +ddqua610 quantize 0 -Inf -> NaN Invalid_operation +ddqua611 quantize 1 -Inf -> NaN Invalid_operation +ddqua612 quantize 1000 -Inf -> NaN Invalid_operation +ddqua613 quantize Inf -Inf -> Infinity +ddqua614 quantize -Inf 1e-0 -> NaN Invalid_operation +ddqua615 quantize -0 -Inf -> NaN Invalid_operation + +ddqua621 quantize NaN -Inf -> NaN +ddqua622 quantize NaN 1e-299 -> NaN +ddqua623 quantize NaN 1e-1 -> NaN +ddqua624 quantize NaN 1e0 -> NaN +ddqua625 quantize NaN 1e1 -> NaN +ddqua626 quantize NaN 1e299 -> NaN +ddqua627 quantize NaN Inf -> NaN +ddqua628 quantize NaN NaN -> NaN +ddqua629 quantize -Inf NaN -> NaN +ddqua630 quantize -1000 NaN -> NaN +ddqua631 quantize -1 NaN -> NaN +ddqua632 quantize 0 NaN -> NaN +ddqua633 quantize 1 NaN -> NaN +ddqua634 quantize 1000 NaN -> NaN +ddqua635 quantize Inf NaN -> NaN +ddqua636 quantize NaN 1e-0 -> NaN +ddqua637 quantize -0 NaN -> NaN + +ddqua641 quantize sNaN -Inf -> NaN Invalid_operation +ddqua642 quantize sNaN 1e-299 -> NaN Invalid_operation +ddqua643 quantize sNaN 1e-1 -> NaN Invalid_operation +ddqua644 quantize sNaN 1e0 -> NaN Invalid_operation +ddqua645 quantize sNaN 1e1 -> NaN Invalid_operation +ddqua646 quantize sNaN 1e299 -> NaN Invalid_operation +ddqua647 quantize sNaN NaN -> NaN Invalid_operation +ddqua648 quantize sNaN sNaN -> NaN Invalid_operation +ddqua649 quantize NaN sNaN -> NaN Invalid_operation +ddqua650 quantize -Inf sNaN -> NaN Invalid_operation +ddqua651 quantize -1000 sNaN -> NaN Invalid_operation +ddqua652 quantize -1 sNaN -> NaN Invalid_operation +ddqua653 quantize 0 sNaN -> NaN Invalid_operation +ddqua654 quantize 1 sNaN -> NaN Invalid_operation +ddqua655 quantize 1000 sNaN -> NaN Invalid_operation +ddqua656 quantize Inf sNaN -> NaN Invalid_operation +ddqua657 quantize NaN sNaN -> NaN Invalid_operation +ddqua658 quantize sNaN 1e-0 -> NaN Invalid_operation +ddqua659 quantize -0 sNaN -> NaN Invalid_operation + +-- propagating NaNs +ddqua661 quantize NaN9 -Inf -> NaN9 +ddqua662 quantize NaN8 919 -> NaN8 +ddqua663 quantize NaN71 Inf -> NaN71 +ddqua664 quantize NaN6 NaN5 -> NaN6 +ddqua665 quantize -Inf NaN4 -> NaN4 +ddqua666 quantize -919 NaN31 -> NaN31 +ddqua667 quantize Inf NaN2 -> NaN2 + +ddqua671 quantize sNaN99 -Inf -> NaN99 Invalid_operation +ddqua672 quantize sNaN98 -11 -> NaN98 Invalid_operation +ddqua673 quantize sNaN97 NaN -> NaN97 Invalid_operation +ddqua674 quantize sNaN16 sNaN94 -> NaN16 Invalid_operation +ddqua675 quantize NaN95 sNaN93 -> NaN93 Invalid_operation +ddqua676 quantize -Inf sNaN92 -> NaN92 Invalid_operation +ddqua677 quantize 088 sNaN91 -> NaN91 Invalid_operation +ddqua678 quantize Inf sNaN90 -> NaN90 Invalid_operation +ddqua679 quantize NaN sNaN88 -> NaN88 Invalid_operation + +ddqua681 quantize -NaN9 -Inf -> -NaN9 +ddqua682 quantize -NaN8 919 -> -NaN8 +ddqua683 quantize -NaN71 Inf -> -NaN71 +ddqua684 quantize -NaN6 -NaN5 -> -NaN6 +ddqua685 quantize -Inf -NaN4 -> -NaN4 +ddqua686 quantize -919 -NaN31 -> -NaN31 +ddqua687 quantize Inf -NaN2 -> -NaN2 + +ddqua691 quantize -sNaN99 -Inf -> -NaN99 Invalid_operation +ddqua692 quantize -sNaN98 -11 -> -NaN98 Invalid_operation +ddqua693 quantize -sNaN97 NaN -> -NaN97 Invalid_operation +ddqua694 quantize -sNaN16 sNaN94 -> -NaN16 Invalid_operation +ddqua695 quantize -NaN95 -sNaN93 -> -NaN93 Invalid_operation +ddqua696 quantize -Inf -sNaN92 -> -NaN92 Invalid_operation +ddqua697 quantize 088 -sNaN91 -> -NaN91 Invalid_operation +ddqua698 quantize Inf -sNaN90 -> -NaN90 Invalid_operation +ddqua699 quantize NaN -sNaN88 -> -NaN88 Invalid_operation + +-- subnormals and underflow +ddqua710 quantize 1.00E-383 1e-383 -> 1E-383 Rounded +ddqua711 quantize 0.1E-383 2e-384 -> 1E-384 Subnormal +ddqua712 quantize 0.10E-383 3e-384 -> 1E-384 Subnormal Rounded +ddqua713 quantize 0.100E-383 4e-384 -> 1E-384 Subnormal Rounded +ddqua714 quantize 0.01E-383 5e-385 -> 1E-385 Subnormal +-- next is rounded to Emin +ddqua715 quantize 0.999E-383 1e-383 -> 1E-383 Inexact Rounded +ddqua716 quantize 0.099E-383 10e-384 -> 1E-384 Inexact Rounded Subnormal + +ddqua717 quantize 0.009E-383 1e-385 -> 1E-385 Inexact Rounded Subnormal +ddqua718 quantize 0.001E-383 1e-385 -> 0E-385 Inexact Rounded +ddqua719 quantize 0.0009E-383 1e-385 -> 0E-385 Inexact Rounded +ddqua720 quantize 0.0001E-383 1e-385 -> 0E-385 Inexact Rounded + +ddqua730 quantize -1.00E-383 1e-383 -> -1E-383 Rounded +ddqua731 quantize -0.1E-383 1e-383 -> -0E-383 Rounded Inexact +ddqua732 quantize -0.10E-383 1e-383 -> -0E-383 Rounded Inexact +ddqua733 quantize -0.100E-383 1e-383 -> -0E-383 Rounded Inexact +ddqua734 quantize -0.01E-383 1e-383 -> -0E-383 Inexact Rounded +-- next is rounded to Emin +ddqua735 quantize -0.999E-383 90e-383 -> -1E-383 Inexact Rounded +ddqua736 quantize -0.099E-383 -1e-383 -> -0E-383 Inexact Rounded +ddqua737 quantize -0.009E-383 -1e-383 -> -0E-383 Inexact Rounded +ddqua738 quantize -0.001E-383 -0e-383 -> -0E-383 Inexact Rounded +ddqua739 quantize -0.0001E-383 0e-383 -> -0E-383 Inexact Rounded + +ddqua740 quantize -1.00E-383 1e-384 -> -1.0E-383 Rounded +ddqua741 quantize -0.1E-383 1e-384 -> -1E-384 Subnormal +ddqua742 quantize -0.10E-383 1e-384 -> -1E-384 Subnormal Rounded +ddqua743 quantize -0.100E-383 1e-384 -> -1E-384 Subnormal Rounded +ddqua744 quantize -0.01E-383 1e-384 -> -0E-384 Inexact Rounded +-- next is rounded to Emin +ddqua745 quantize -0.999E-383 1e-384 -> -1.0E-383 Inexact Rounded +ddqua746 quantize -0.099E-383 1e-384 -> -1E-384 Inexact Rounded Subnormal +ddqua747 quantize -0.009E-383 1e-384 -> -0E-384 Inexact Rounded +ddqua748 quantize -0.001E-383 1e-384 -> -0E-384 Inexact Rounded +ddqua749 quantize -0.0001E-383 1e-384 -> -0E-384 Inexact Rounded + +ddqua750 quantize -1.00E-383 1e-385 -> -1.00E-383 +ddqua751 quantize -0.1E-383 1e-385 -> -1.0E-384 Subnormal +ddqua752 quantize -0.10E-383 1e-385 -> -1.0E-384 Subnormal +ddqua753 quantize -0.100E-383 1e-385 -> -1.0E-384 Subnormal Rounded +ddqua754 quantize -0.01E-383 1e-385 -> -1E-385 Subnormal +-- next is rounded to Emin +ddqua755 quantize -0.999E-383 1e-385 -> -1.00E-383 Inexact Rounded +ddqua756 quantize -0.099E-383 1e-385 -> -1.0E-384 Inexact Rounded Subnormal +ddqua757 quantize -0.009E-383 1e-385 -> -1E-385 Inexact Rounded Subnormal +ddqua758 quantize -0.001E-383 1e-385 -> -0E-385 Inexact Rounded +ddqua759 quantize -0.0001E-383 1e-385 -> -0E-385 Inexact Rounded + +ddqua760 quantize -1.00E-383 1e-386 -> -1.000E-383 +ddqua761 quantize -0.1E-383 1e-386 -> -1.00E-384 Subnormal +ddqua762 quantize -0.10E-383 1e-386 -> -1.00E-384 Subnormal +ddqua763 quantize -0.100E-383 1e-386 -> -1.00E-384 Subnormal +ddqua764 quantize -0.01E-383 1e-386 -> -1.0E-385 Subnormal +ddqua765 quantize -0.999E-383 1e-386 -> -9.99E-384 Subnormal +ddqua766 quantize -0.099E-383 1e-386 -> -9.9E-385 Subnormal +ddqua767 quantize -0.009E-383 1e-386 -> -9E-386 Subnormal +ddqua768 quantize -0.001E-383 1e-386 -> -1E-386 Subnormal +ddqua769 quantize -0.0001E-383 1e-386 -> -0E-386 Inexact Rounded + +-- More from Fung Lee +ddqua1021 quantize 8.666666666666000E+384 1.000000000000000E+384 -> 8.666666666666000E+384 +ddqua1022 quantize -8.666666666666000E+384 1.000000000000000E+384 -> -8.666666666666000E+384 +ddqua1027 quantize 8.666666666666000E+323 1E+31 -> NaN Invalid_operation +ddqua1030 quantize 8.66666666E+3 1E+3 -> 9E+3 Inexact Rounded + +-- Int and uInt32 edge values for testing conversions +ddqua1040 quantize -2147483646 0 -> -2147483646 +ddqua1041 quantize -2147483647 0 -> -2147483647 +ddqua1042 quantize -2147483648 0 -> -2147483648 +ddqua1043 quantize -2147483649 0 -> -2147483649 +ddqua1044 quantize 2147483646 0 -> 2147483646 +ddqua1045 quantize 2147483647 0 -> 2147483647 +ddqua1046 quantize 2147483648 0 -> 2147483648 +ddqua1047 quantize 2147483649 0 -> 2147483649 +ddqua1048 quantize 4294967294 0 -> 4294967294 +ddqua1049 quantize 4294967295 0 -> 4294967295 +ddqua1050 quantize 4294967296 0 -> 4294967296 +ddqua1051 quantize 4294967297 0 -> 4294967297 + +-- Rounding swathe +rounding: half_even +ddqua1100 quantize 1.2300 1.00 -> 1.23 Rounded +ddqua1101 quantize 1.2301 1.00 -> 1.23 Inexact Rounded +ddqua1102 quantize 1.2310 1.00 -> 1.23 Inexact Rounded +ddqua1103 quantize 1.2350 1.00 -> 1.24 Inexact Rounded +ddqua1104 quantize 1.2351 1.00 -> 1.24 Inexact Rounded +ddqua1105 quantize 1.2450 1.00 -> 1.24 Inexact Rounded +ddqua1106 quantize 1.2451 1.00 -> 1.25 Inexact Rounded +ddqua1107 quantize 1.2360 1.00 -> 1.24 Inexact Rounded +ddqua1108 quantize 1.2370 1.00 -> 1.24 Inexact Rounded +ddqua1109 quantize 1.2399 1.00 -> 1.24 Inexact Rounded + +rounding: half_up +ddqua1200 quantize 1.2300 1.00 -> 1.23 Rounded +ddqua1201 quantize 1.2301 1.00 -> 1.23 Inexact Rounded +ddqua1202 quantize 1.2310 1.00 -> 1.23 Inexact Rounded +ddqua1203 quantize 1.2350 1.00 -> 1.24 Inexact Rounded +ddqua1204 quantize 1.2351 1.00 -> 1.24 Inexact Rounded +ddqua1205 quantize 1.2450 1.00 -> 1.25 Inexact Rounded +ddqua1206 quantize 1.2451 1.00 -> 1.25 Inexact Rounded +ddqua1207 quantize 1.2360 1.00 -> 1.24 Inexact Rounded +ddqua1208 quantize 1.2370 1.00 -> 1.24 Inexact Rounded +ddqua1209 quantize 1.2399 1.00 -> 1.24 Inexact Rounded + +rounding: half_down +ddqua1300 quantize 1.2300 1.00 -> 1.23 Rounded +ddqua1301 quantize 1.2301 1.00 -> 1.23 Inexact Rounded +ddqua1302 quantize 1.2310 1.00 -> 1.23 Inexact Rounded +ddqua1303 quantize 1.2350 1.00 -> 1.23 Inexact Rounded +ddqua1304 quantize 1.2351 1.00 -> 1.24 Inexact Rounded +ddqua1305 quantize 1.2450 1.00 -> 1.24 Inexact Rounded +ddqua1306 quantize 1.2451 1.00 -> 1.25 Inexact Rounded +ddqua1307 quantize 1.2360 1.00 -> 1.24 Inexact Rounded +ddqua1308 quantize 1.2370 1.00 -> 1.24 Inexact Rounded +ddqua1309 quantize 1.2399 1.00 -> 1.24 Inexact Rounded + +rounding: up +ddqua1400 quantize 1.2300 1.00 -> 1.23 Rounded +ddqua1401 quantize 1.2301 1.00 -> 1.24 Inexact Rounded +ddqua1402 quantize 1.2310 1.00 -> 1.24 Inexact Rounded +ddqua1403 quantize 1.2350 1.00 -> 1.24 Inexact Rounded +ddqua1404 quantize 1.2351 1.00 -> 1.24 Inexact Rounded +ddqua1405 quantize 1.2450 1.00 -> 1.25 Inexact Rounded +ddqua1406 quantize 1.2451 1.00 -> 1.25 Inexact Rounded +ddqua1407 quantize 1.2360 1.00 -> 1.24 Inexact Rounded +ddqua1408 quantize 1.2370 1.00 -> 1.24 Inexact Rounded +ddqua1409 quantize 1.2399 1.00 -> 1.24 Inexact Rounded +ddqua1411 quantize -1.2399 1.00 -> -1.24 Inexact Rounded + +rounding: down +ddqua1500 quantize 1.2300 1.00 -> 1.23 Rounded +ddqua1501 quantize 1.2301 1.00 -> 1.23 Inexact Rounded +ddqua1502 quantize 1.2310 1.00 -> 1.23 Inexact Rounded +ddqua1503 quantize 1.2350 1.00 -> 1.23 Inexact Rounded +ddqua1504 quantize 1.2351 1.00 -> 1.23 Inexact Rounded +ddqua1505 quantize 1.2450 1.00 -> 1.24 Inexact Rounded +ddqua1506 quantize 1.2451 1.00 -> 1.24 Inexact Rounded +ddqua1507 quantize 1.2360 1.00 -> 1.23 Inexact Rounded +ddqua1508 quantize 1.2370 1.00 -> 1.23 Inexact Rounded +ddqua1509 quantize 1.2399 1.00 -> 1.23 Inexact Rounded +ddqua1511 quantize -1.2399 1.00 -> -1.23 Inexact Rounded + +rounding: ceiling +ddqua1600 quantize 1.2300 1.00 -> 1.23 Rounded +ddqua1601 quantize 1.2301 1.00 -> 1.24 Inexact Rounded +ddqua1602 quantize 1.2310 1.00 -> 1.24 Inexact Rounded +ddqua1603 quantize 1.2350 1.00 -> 1.24 Inexact Rounded +ddqua1604 quantize 1.2351 1.00 -> 1.24 Inexact Rounded +ddqua1605 quantize 1.2450 1.00 -> 1.25 Inexact Rounded +ddqua1606 quantize 1.2451 1.00 -> 1.25 Inexact Rounded +ddqua1607 quantize 1.2360 1.00 -> 1.24 Inexact Rounded +ddqua1608 quantize 1.2370 1.00 -> 1.24 Inexact Rounded +ddqua1609 quantize 1.2399 1.00 -> 1.24 Inexact Rounded +ddqua1611 quantize -1.2399 1.00 -> -1.23 Inexact Rounded + +rounding: floor +ddqua1700 quantize 1.2300 1.00 -> 1.23 Rounded +ddqua1701 quantize 1.2301 1.00 -> 1.23 Inexact Rounded +ddqua1702 quantize 1.2310 1.00 -> 1.23 Inexact Rounded +ddqua1703 quantize 1.2350 1.00 -> 1.23 Inexact Rounded +ddqua1704 quantize 1.2351 1.00 -> 1.23 Inexact Rounded +ddqua1705 quantize 1.2450 1.00 -> 1.24 Inexact Rounded +ddqua1706 quantize 1.2451 1.00 -> 1.24 Inexact Rounded +ddqua1707 quantize 1.2360 1.00 -> 1.23 Inexact Rounded +ddqua1708 quantize 1.2370 1.00 -> 1.23 Inexact Rounded +ddqua1709 quantize 1.2399 1.00 -> 1.23 Inexact Rounded +ddqua1711 quantize -1.2399 1.00 -> -1.24 Inexact Rounded + +rounding: 05up +ddqua1800 quantize 1.2000 1.00 -> 1.20 Rounded +ddqua1801 quantize 1.2001 1.00 -> 1.21 Inexact Rounded +ddqua1802 quantize 1.2010 1.00 -> 1.21 Inexact Rounded +ddqua1803 quantize 1.2050 1.00 -> 1.21 Inexact Rounded +ddqua1804 quantize 1.2051 1.00 -> 1.21 Inexact Rounded +ddqua1807 quantize 1.2060 1.00 -> 1.21 Inexact Rounded +ddqua1808 quantize 1.2070 1.00 -> 1.21 Inexact Rounded +ddqua1809 quantize 1.2099 1.00 -> 1.21 Inexact Rounded +ddqua1811 quantize -1.2099 1.00 -> -1.21 Inexact Rounded + +ddqua1900 quantize 1.2100 1.00 -> 1.21 Rounded +ddqua1901 quantize 1.2101 1.00 -> 1.21 Inexact Rounded +ddqua1902 quantize 1.2110 1.00 -> 1.21 Inexact Rounded +ddqua1903 quantize 1.2150 1.00 -> 1.21 Inexact Rounded +ddqua1904 quantize 1.2151 1.00 -> 1.21 Inexact Rounded +ddqua1907 quantize 1.2160 1.00 -> 1.21 Inexact Rounded +ddqua1908 quantize 1.2170 1.00 -> 1.21 Inexact Rounded +ddqua1909 quantize 1.2199 1.00 -> 1.21 Inexact Rounded +ddqua1911 quantize -1.2199 1.00 -> -1.21 Inexact Rounded + +ddqua2000 quantize 1.2400 1.00 -> 1.24 Rounded +ddqua2001 quantize 1.2401 1.00 -> 1.24 Inexact Rounded +ddqua2002 quantize 1.2410 1.00 -> 1.24 Inexact Rounded +ddqua2003 quantize 1.2450 1.00 -> 1.24 Inexact Rounded +ddqua2004 quantize 1.2451 1.00 -> 1.24 Inexact Rounded +ddqua2007 quantize 1.2460 1.00 -> 1.24 Inexact Rounded +ddqua2008 quantize 1.2470 1.00 -> 1.24 Inexact Rounded +ddqua2009 quantize 1.2499 1.00 -> 1.24 Inexact Rounded +ddqua2011 quantize -1.2499 1.00 -> -1.24 Inexact Rounded + +ddqua2100 quantize 1.2500 1.00 -> 1.25 Rounded +ddqua2101 quantize 1.2501 1.00 -> 1.26 Inexact Rounded +ddqua2102 quantize 1.2510 1.00 -> 1.26 Inexact Rounded +ddqua2103 quantize 1.2550 1.00 -> 1.26 Inexact Rounded +ddqua2104 quantize 1.2551 1.00 -> 1.26 Inexact Rounded +ddqua2107 quantize 1.2560 1.00 -> 1.26 Inexact Rounded +ddqua2108 quantize 1.2570 1.00 -> 1.26 Inexact Rounded +ddqua2109 quantize 1.2599 1.00 -> 1.26 Inexact Rounded +ddqua2111 quantize -1.2599 1.00 -> -1.26 Inexact Rounded + +ddqua2200 quantize 1.2600 1.00 -> 1.26 Rounded +ddqua2201 quantize 1.2601 1.00 -> 1.26 Inexact Rounded +ddqua2202 quantize 1.2610 1.00 -> 1.26 Inexact Rounded +ddqua2203 quantize 1.2650 1.00 -> 1.26 Inexact Rounded +ddqua2204 quantize 1.2651 1.00 -> 1.26 Inexact Rounded +ddqua2207 quantize 1.2660 1.00 -> 1.26 Inexact Rounded +ddqua2208 quantize 1.2670 1.00 -> 1.26 Inexact Rounded +ddqua2209 quantize 1.2699 1.00 -> 1.26 Inexact Rounded +ddqua2211 quantize -1.2699 1.00 -> -1.26 Inexact Rounded + +ddqua2300 quantize 1.2900 1.00 -> 1.29 Rounded +ddqua2301 quantize 1.2901 1.00 -> 1.29 Inexact Rounded +ddqua2302 quantize 1.2910 1.00 -> 1.29 Inexact Rounded +ddqua2303 quantize 1.2950 1.00 -> 1.29 Inexact Rounded +ddqua2304 quantize 1.2951 1.00 -> 1.29 Inexact Rounded +ddqua2307 quantize 1.2960 1.00 -> 1.29 Inexact Rounded +ddqua2308 quantize 1.2970 1.00 -> 1.29 Inexact Rounded +ddqua2309 quantize 1.2999 1.00 -> 1.29 Inexact Rounded +ddqua2311 quantize -1.2999 1.00 -> -1.29 Inexact Rounded + +-- Null tests +rounding: half_even +ddqua998 quantize 10 # -> NaN Invalid_operation +ddqua999 quantize # 1e10 -> NaN Invalid_operation Added: python/branches/release25-maint/Lib/test/decimaltestdata/ddReduce.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/ddReduce.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,182 @@ +------------------------------------------------------------------------ +-- ddReduce.decTest -- remove trailing zeros from a decDouble -- +-- Copyright (c) IBM Corporation, 2003, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +precision: 16 +maxExponent: 384 +minExponent: -383 +extended: 1 +clamp: 1 +rounding: half_even + +ddred001 reduce '1' -> '1' +ddred002 reduce '-1' -> '-1' +ddred003 reduce '1.00' -> '1' +ddred004 reduce '-1.00' -> '-1' +ddred005 reduce '0' -> '0' +ddred006 reduce '0.00' -> '0' +ddred007 reduce '00.0' -> '0' +ddred008 reduce '00.00' -> '0' +ddred009 reduce '00' -> '0' +ddred010 reduce '0E+1' -> '0' +ddred011 reduce '0E+5' -> '0' + +ddred012 reduce '-2' -> '-2' +ddred013 reduce '2' -> '2' +ddred014 reduce '-2.00' -> '-2' +ddred015 reduce '2.00' -> '2' +ddred016 reduce '-0' -> '-0' +ddred017 reduce '-0.00' -> '-0' +ddred018 reduce '-00.0' -> '-0' +ddred019 reduce '-00.00' -> '-0' +ddred020 reduce '-00' -> '-0' +ddred021 reduce '-0E+5' -> '-0' +ddred022 reduce '-0E+1' -> '-0' + +ddred030 reduce '+0.1' -> '0.1' +ddred031 reduce '-0.1' -> '-0.1' +ddred032 reduce '+0.01' -> '0.01' +ddred033 reduce '-0.01' -> '-0.01' +ddred034 reduce '+0.001' -> '0.001' +ddred035 reduce '-0.001' -> '-0.001' +ddred036 reduce '+0.000001' -> '0.000001' +ddred037 reduce '-0.000001' -> '-0.000001' +ddred038 reduce '+0.000000000001' -> '1E-12' +ddred039 reduce '-0.000000000001' -> '-1E-12' + +ddred041 reduce 1.1 -> 1.1 +ddred042 reduce 1.10 -> 1.1 +ddred043 reduce 1.100 -> 1.1 +ddred044 reduce 1.110 -> 1.11 +ddred045 reduce -1.1 -> -1.1 +ddred046 reduce -1.10 -> -1.1 +ddred047 reduce -1.100 -> -1.1 +ddred048 reduce -1.110 -> -1.11 +ddred049 reduce 9.9 -> 9.9 +ddred050 reduce 9.90 -> 9.9 +ddred051 reduce 9.900 -> 9.9 +ddred052 reduce 9.990 -> 9.99 +ddred053 reduce -9.9 -> -9.9 +ddred054 reduce -9.90 -> -9.9 +ddred055 reduce -9.900 -> -9.9 +ddred056 reduce -9.990 -> -9.99 + +-- some trailing fractional zeros with zeros in units +ddred060 reduce 10.0 -> 1E+1 +ddred061 reduce 10.00 -> 1E+1 +ddred062 reduce 100.0 -> 1E+2 +ddred063 reduce 100.00 -> 1E+2 +ddred064 reduce 1.1000E+3 -> 1.1E+3 +ddred065 reduce 1.10000E+3 -> 1.1E+3 +ddred066 reduce -10.0 -> -1E+1 +ddred067 reduce -10.00 -> -1E+1 +ddred068 reduce -100.0 -> -1E+2 +ddred069 reduce -100.00 -> -1E+2 +ddred070 reduce -1.1000E+3 -> -1.1E+3 +ddred071 reduce -1.10000E+3 -> -1.1E+3 + +-- some insignificant trailing zeros with positive exponent +ddred080 reduce 10E+1 -> 1E+2 +ddred081 reduce 100E+1 -> 1E+3 +ddred082 reduce 1.0E+2 -> 1E+2 +ddred083 reduce 1.0E+3 -> 1E+3 +ddred084 reduce 1.1E+3 -> 1.1E+3 +ddred085 reduce 1.00E+3 -> 1E+3 +ddred086 reduce 1.10E+3 -> 1.1E+3 +ddred087 reduce -10E+1 -> -1E+2 +ddred088 reduce -100E+1 -> -1E+3 +ddred089 reduce -1.0E+2 -> -1E+2 +ddred090 reduce -1.0E+3 -> -1E+3 +ddred091 reduce -1.1E+3 -> -1.1E+3 +ddred092 reduce -1.00E+3 -> -1E+3 +ddred093 reduce -1.10E+3 -> -1.1E+3 + +-- some significant trailing zeros, were we to be trimming +ddred100 reduce 11 -> 11 +ddred101 reduce 10 -> 1E+1 +ddred102 reduce 10. -> 1E+1 +ddred103 reduce 1.1E+1 -> 11 +ddred104 reduce 1.0E+1 -> 1E+1 +ddred105 reduce 1.10E+2 -> 1.1E+2 +ddred106 reduce 1.00E+2 -> 1E+2 +ddred107 reduce 1.100E+3 -> 1.1E+3 +ddred108 reduce 1.000E+3 -> 1E+3 +ddred109 reduce 1.000000E+6 -> 1E+6 +ddred110 reduce -11 -> -11 +ddred111 reduce -10 -> -1E+1 +ddred112 reduce -10. -> -1E+1 +ddred113 reduce -1.1E+1 -> -11 +ddred114 reduce -1.0E+1 -> -1E+1 +ddred115 reduce -1.10E+2 -> -1.1E+2 +ddred116 reduce -1.00E+2 -> -1E+2 +ddred117 reduce -1.100E+3 -> -1.1E+3 +ddred118 reduce -1.000E+3 -> -1E+3 +ddred119 reduce -1.00000E+5 -> -1E+5 +ddred120 reduce -1.000000E+6 -> -1E+6 +ddred121 reduce -10.00000E+6 -> -1E+7 +ddred122 reduce -100.0000E+6 -> -1E+8 +ddred123 reduce -1000.000E+6 -> -1E+9 +ddred124 reduce -10000.00E+6 -> -1E+10 +ddred125 reduce -100000.0E+6 -> -1E+11 +ddred126 reduce -1000000.E+6 -> -1E+12 + +-- examples from decArith +ddred140 reduce '2.1' -> '2.1' +ddred141 reduce '-2.0' -> '-2' +ddred142 reduce '1.200' -> '1.2' +ddred143 reduce '-120' -> '-1.2E+2' +ddred144 reduce '120.00' -> '1.2E+2' +ddred145 reduce '0.00' -> '0' + +-- Nmax, Nmin, Ntiny +-- note origami effect on some of these +ddred151 reduce 9.999999999999999E+384 -> 9.999999999999999E+384 +ddred152 reduce 9.999999000000000E+380 -> 9.99999900000E+380 +ddred153 reduce 9.999999999990000E+384 -> 9.999999999990000E+384 +ddred154 reduce 1E-383 -> 1E-383 +ddred155 reduce 1.000000000000000E-383 -> 1E-383 +ddred156 reduce 2.000E-395 -> 2E-395 Subnormal +ddred157 reduce 1E-398 -> 1E-398 Subnormal + +ddred161 reduce -1E-398 -> -1E-398 Subnormal +ddred162 reduce -2.000E-395 -> -2E-395 Subnormal +ddred163 reduce -1.000000000000000E-383 -> -1E-383 +ddred164 reduce -1E-383 -> -1E-383 +ddred165 reduce -9.999999000000000E+380 -> -9.99999900000E+380 +ddred166 reduce -9.999999999990000E+384 -> -9.999999999990000E+384 +ddred167 reduce -9.999999999999990E+384 -> -9.999999999999990E+384 +ddred168 reduce -9.999999999999999E+384 -> -9.999999999999999E+384 +ddred169 reduce -9.999999999999990E+384 -> -9.999999999999990E+384 + + +-- specials (reduce does not affect payload) +ddred820 reduce 'Inf' -> 'Infinity' +ddred821 reduce '-Inf' -> '-Infinity' +ddred822 reduce NaN -> NaN +ddred823 reduce sNaN -> NaN Invalid_operation +ddred824 reduce NaN101 -> NaN101 +ddred825 reduce sNaN010 -> NaN10 Invalid_operation +ddred827 reduce -NaN -> -NaN +ddred828 reduce -sNaN -> -NaN Invalid_operation +ddred829 reduce -NaN101 -> -NaN101 +ddred830 reduce -sNaN010 -> -NaN10 Invalid_operation + +-- Null test +ddred900 reduce # -> NaN Invalid_operation Added: python/branches/release25-maint/Lib/test/decimaltestdata/ddRemainder.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/ddRemainder.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,600 @@ +------------------------------------------------------------------------ +-- ddRemainder.decTest -- decDouble remainder -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +precision: 16 +maxExponent: 384 +minExponent: -383 +extended: 1 +clamp: 1 +rounding: half_even + +-- sanity checks (as base, above) +ddrem001 remainder 1 1 -> 0 +ddrem002 remainder 2 1 -> 0 +ddrem003 remainder 1 2 -> 1 +ddrem004 remainder 2 2 -> 0 +ddrem005 remainder 0 1 -> 0 +ddrem006 remainder 0 2 -> 0 +ddrem007 remainder 1 3 -> 1 +ddrem008 remainder 2 3 -> 2 +ddrem009 remainder 3 3 -> 0 + +ddrem010 remainder 2.4 1 -> 0.4 +ddrem011 remainder 2.4 -1 -> 0.4 +ddrem012 remainder -2.4 1 -> -0.4 +ddrem013 remainder -2.4 -1 -> -0.4 +ddrem014 remainder 2.40 1 -> 0.40 +ddrem015 remainder 2.400 1 -> 0.400 +ddrem016 remainder 2.4 2 -> 0.4 +ddrem017 remainder 2.400 2 -> 0.400 +ddrem018 remainder 2. 2 -> 0 +ddrem019 remainder 20 20 -> 0 + +ddrem020 remainder 187 187 -> 0 +ddrem021 remainder 5 2 -> 1 +ddrem022 remainder 5 2.0 -> 1.0 +ddrem023 remainder 5 2.000 -> 1.000 +ddrem024 remainder 5 0.200 -> 0.000 +ddrem025 remainder 5 0.200 -> 0.000 + +ddrem030 remainder 1 2 -> 1 +ddrem031 remainder 1 4 -> 1 +ddrem032 remainder 1 8 -> 1 + +ddrem033 remainder 1 16 -> 1 +ddrem034 remainder 1 32 -> 1 +ddrem035 remainder 1 64 -> 1 +ddrem040 remainder 1 -2 -> 1 +ddrem041 remainder 1 -4 -> 1 +ddrem042 remainder 1 -8 -> 1 +ddrem043 remainder 1 -16 -> 1 +ddrem044 remainder 1 -32 -> 1 +ddrem045 remainder 1 -64 -> 1 +ddrem050 remainder -1 2 -> -1 +ddrem051 remainder -1 4 -> -1 +ddrem052 remainder -1 8 -> -1 +ddrem053 remainder -1 16 -> -1 +ddrem054 remainder -1 32 -> -1 +ddrem055 remainder -1 64 -> -1 +ddrem060 remainder -1 -2 -> -1 +ddrem061 remainder -1 -4 -> -1 +ddrem062 remainder -1 -8 -> -1 +ddrem063 remainder -1 -16 -> -1 +ddrem064 remainder -1 -32 -> -1 +ddrem065 remainder -1 -64 -> -1 + +ddrem066 remainder 999999999 1 -> 0 +ddrem067 remainder 999999999.4 1 -> 0.4 +ddrem068 remainder 999999999.5 1 -> 0.5 +ddrem069 remainder 999999999.9 1 -> 0.9 +ddrem070 remainder 999999999.999 1 -> 0.999 +ddrem071 remainder 999999.999999 1 -> 0.999999 +ddrem072 remainder 9 1 -> 0 +ddrem073 remainder 9999999999999999 1 -> 0 +ddrem074 remainder 9999999999999999 2 -> 1 +ddrem075 remainder 9999999999999999 3 -> 0 +ddrem076 remainder 9999999999999999 4 -> 3 + +ddrem080 remainder 0. 1 -> 0 +ddrem081 remainder .0 1 -> 0.0 +ddrem082 remainder 0.00 1 -> 0.00 +ddrem083 remainder 0.00E+9 1 -> 0 +ddrem084 remainder 0.00E+3 1 -> 0 +ddrem085 remainder 0.00E+2 1 -> 0 +ddrem086 remainder 0.00E+1 1 -> 0.0 +ddrem087 remainder 0.00E+0 1 -> 0.00 +ddrem088 remainder 0.00E-0 1 -> 0.00 +ddrem089 remainder 0.00E-1 1 -> 0.000 +ddrem090 remainder 0.00E-2 1 -> 0.0000 +ddrem091 remainder 0.00E-3 1 -> 0.00000 +ddrem092 remainder 0.00E-4 1 -> 0.000000 +ddrem093 remainder 0.00E-5 1 -> 0E-7 +ddrem094 remainder 0.00E-6 1 -> 0E-8 +ddrem095 remainder 0.0000E-50 1 -> 0E-54 + +-- Various flavours of remainder by 0 +ddrem101 remainder 0 0 -> NaN Division_undefined +ddrem102 remainder 0 -0 -> NaN Division_undefined +ddrem103 remainder -0 0 -> NaN Division_undefined +ddrem104 remainder -0 -0 -> NaN Division_undefined +ddrem105 remainder 0.0E5 0 -> NaN Division_undefined +ddrem106 remainder 0.000 0 -> NaN Division_undefined +-- [Some think this next group should be Division_by_zero exception, but +-- IEEE 854 is explicit that it is Invalid operation .. for +-- remainder-near, anyway] +ddrem107 remainder 0.0001 0 -> NaN Invalid_operation +ddrem108 remainder 0.01 0 -> NaN Invalid_operation +ddrem109 remainder 0.1 0 -> NaN Invalid_operation +ddrem110 remainder 1 0 -> NaN Invalid_operation +ddrem111 remainder 1 0.0 -> NaN Invalid_operation +ddrem112 remainder 10 0.0 -> NaN Invalid_operation +ddrem113 remainder 1E+100 0.0 -> NaN Invalid_operation +ddrem114 remainder 1E+380 0 -> NaN Invalid_operation +ddrem115 remainder 0.0001 -0 -> NaN Invalid_operation +ddrem116 remainder 0.01 -0 -> NaN Invalid_operation +ddrem119 remainder 0.1 -0 -> NaN Invalid_operation +ddrem120 remainder 1 -0 -> NaN Invalid_operation +ddrem121 remainder 1 -0.0 -> NaN Invalid_operation +ddrem122 remainder 10 -0.0 -> NaN Invalid_operation +ddrem123 remainder 1E+100 -0.0 -> NaN Invalid_operation +ddrem124 remainder 1E+384 -0 -> NaN Invalid_operation +-- and zeros on left +ddrem130 remainder 0 1 -> 0 +ddrem131 remainder 0 -1 -> 0 +ddrem132 remainder 0.0 1 -> 0.0 +ddrem133 remainder 0.0 -1 -> 0.0 +ddrem134 remainder -0 1 -> -0 +ddrem135 remainder -0 -1 -> -0 +ddrem136 remainder -0.0 1 -> -0.0 +ddrem137 remainder -0.0 -1 -> -0.0 + +-- 0.5ers +ddrem143 remainder 0.5 2 -> 0.5 +ddrem144 remainder 0.5 2.1 -> 0.5 +ddrem145 remainder 0.5 2.01 -> 0.50 +ddrem146 remainder 0.5 2.001 -> 0.500 +ddrem147 remainder 0.50 2 -> 0.50 +ddrem148 remainder 0.50 2.01 -> 0.50 +ddrem149 remainder 0.50 2.001 -> 0.500 + +-- steadies +ddrem150 remainder 1 1 -> 0 +ddrem151 remainder 1 2 -> 1 +ddrem152 remainder 1 3 -> 1 +ddrem153 remainder 1 4 -> 1 +ddrem154 remainder 1 5 -> 1 +ddrem155 remainder 1 6 -> 1 +ddrem156 remainder 1 7 -> 1 +ddrem157 remainder 1 8 -> 1 +ddrem158 remainder 1 9 -> 1 +ddrem159 remainder 1 10 -> 1 +ddrem160 remainder 1 1 -> 0 +ddrem161 remainder 2 1 -> 0 +ddrem162 remainder 3 1 -> 0 +ddrem163 remainder 4 1 -> 0 +ddrem164 remainder 5 1 -> 0 +ddrem165 remainder 6 1 -> 0 +ddrem166 remainder 7 1 -> 0 +ddrem167 remainder 8 1 -> 0 +ddrem168 remainder 9 1 -> 0 +ddrem169 remainder 10 1 -> 0 + +-- some differences from remainderNear +ddrem171 remainder 0.4 1.020 -> 0.400 +ddrem172 remainder 0.50 1.020 -> 0.500 +ddrem173 remainder 0.51 1.020 -> 0.510 +ddrem174 remainder 0.52 1.020 -> 0.520 +ddrem175 remainder 0.6 1.020 -> 0.600 + +-- More flavours of remainder by 0 +ddrem201 remainder 0 0 -> NaN Division_undefined +ddrem202 remainder 0.0E5 0 -> NaN Division_undefined +ddrem203 remainder 0.000 0 -> NaN Division_undefined +ddrem204 remainder 0.0001 0 -> NaN Invalid_operation +ddrem205 remainder 0.01 0 -> NaN Invalid_operation +ddrem206 remainder 0.1 0 -> NaN Invalid_operation +ddrem207 remainder 1 0 -> NaN Invalid_operation +ddrem208 remainder 1 0.0 -> NaN Invalid_operation +ddrem209 remainder 10 0.0 -> NaN Invalid_operation +ddrem210 remainder 1E+100 0.0 -> NaN Invalid_operation +ddrem211 remainder 1E+380 0 -> NaN Invalid_operation + +-- some differences from remainderNear +ddrem231 remainder -0.4 1.020 -> -0.400 +ddrem232 remainder -0.50 1.020 -> -0.500 +ddrem233 remainder -0.51 1.020 -> -0.510 +ddrem234 remainder -0.52 1.020 -> -0.520 +ddrem235 remainder -0.6 1.020 -> -0.600 + +-- high Xs +ddrem240 remainder 1E+2 1.00 -> 0.00 + +-- ddrem3xx are from DiagBigDecimal +ddrem301 remainder 1 3 -> 1 +ddrem302 remainder 5 5 -> 0 +ddrem303 remainder 13 10 -> 3 +ddrem304 remainder 13 50 -> 13 +ddrem305 remainder 13 100 -> 13 +ddrem306 remainder 13 1000 -> 13 +ddrem307 remainder .13 1 -> 0.13 +ddrem308 remainder 0.133 1 -> 0.133 +ddrem309 remainder 0.1033 1 -> 0.1033 +ddrem310 remainder 1.033 1 -> 0.033 +ddrem311 remainder 10.33 1 -> 0.33 +ddrem312 remainder 10.33 10 -> 0.33 +ddrem313 remainder 103.3 1 -> 0.3 +ddrem314 remainder 133 10 -> 3 +ddrem315 remainder 1033 10 -> 3 +ddrem316 remainder 1033 50 -> 33 +ddrem317 remainder 101.0 3 -> 2.0 +ddrem318 remainder 102.0 3 -> 0.0 +ddrem319 remainder 103.0 3 -> 1.0 +ddrem320 remainder 2.40 1 -> 0.40 +ddrem321 remainder 2.400 1 -> 0.400 +ddrem322 remainder 2.4 1 -> 0.4 +ddrem323 remainder 2.4 2 -> 0.4 +ddrem324 remainder 2.400 2 -> 0.400 +ddrem325 remainder 1 0.3 -> 0.1 +ddrem326 remainder 1 0.30 -> 0.10 +ddrem327 remainder 1 0.300 -> 0.100 +ddrem328 remainder 1 0.3000 -> 0.1000 +ddrem329 remainder 1.0 0.3 -> 0.1 +ddrem330 remainder 1.00 0.3 -> 0.10 +ddrem331 remainder 1.000 0.3 -> 0.100 +ddrem332 remainder 1.0000 0.3 -> 0.1000 +ddrem333 remainder 0.5 2 -> 0.5 +ddrem334 remainder 0.5 2.1 -> 0.5 +ddrem335 remainder 0.5 2.01 -> 0.50 +ddrem336 remainder 0.5 2.001 -> 0.500 +ddrem337 remainder 0.50 2 -> 0.50 +ddrem338 remainder 0.50 2.01 -> 0.50 +ddrem339 remainder 0.50 2.001 -> 0.500 + +ddrem340 remainder 0.5 0.5000001 -> 0.5000000 +ddrem341 remainder 0.5 0.50000001 -> 0.50000000 +ddrem342 remainder 0.5 0.500000001 -> 0.500000000 +ddrem343 remainder 0.5 0.5000000001 -> 0.5000000000 +ddrem344 remainder 0.5 0.50000000001 -> 0.50000000000 +ddrem345 remainder 0.5 0.4999999 -> 1E-7 +ddrem346 remainder 0.5 0.49999999 -> 1E-8 +ddrem347 remainder 0.5 0.499999999 -> 1E-9 +ddrem348 remainder 0.5 0.4999999999 -> 1E-10 +ddrem349 remainder 0.5 0.49999999999 -> 1E-11 +ddrem350 remainder 0.5 0.499999999999 -> 1E-12 + +ddrem351 remainder 0.03 7 -> 0.03 +ddrem352 remainder 5 2 -> 1 +ddrem353 remainder 4.1 2 -> 0.1 +ddrem354 remainder 4.01 2 -> 0.01 +ddrem355 remainder 4.001 2 -> 0.001 +ddrem356 remainder 4.0001 2 -> 0.0001 +ddrem357 remainder 4.00001 2 -> 0.00001 +ddrem358 remainder 4.000001 2 -> 0.000001 +ddrem359 remainder 4.0000001 2 -> 1E-7 + +ddrem360 remainder 1.2 0.7345 -> 0.4655 +ddrem361 remainder 0.8 12 -> 0.8 +ddrem362 remainder 0.8 0.2 -> 0.0 +ddrem363 remainder 0.8 0.3 -> 0.2 +ddrem364 remainder 0.800 12 -> 0.800 +ddrem365 remainder 0.800 1.7 -> 0.800 +ddrem366 remainder 2.400 2 -> 0.400 + +ddrem371 remainder 2.400 2 -> 0.400 + +ddrem381 remainder 12345 1 -> 0 +ddrem382 remainder 12345 1.0001 -> 0.7657 +ddrem383 remainder 12345 1.001 -> 0.668 +ddrem384 remainder 12345 1.01 -> 0.78 +ddrem385 remainder 12345 1.1 -> 0.8 +ddrem386 remainder 12355 4 -> 3 +ddrem387 remainder 12345 4 -> 1 +ddrem388 remainder 12355 4.0001 -> 2.6912 +ddrem389 remainder 12345 4.0001 -> 0.6914 +ddrem390 remainder 12345 4.9 -> 1.9 +ddrem391 remainder 12345 4.99 -> 4.73 +ddrem392 remainder 12345 4.999 -> 2.469 +ddrem393 remainder 12345 4.9999 -> 0.2469 +ddrem394 remainder 12345 5 -> 0 +ddrem395 remainder 12345 5.0001 -> 4.7532 +ddrem396 remainder 12345 5.001 -> 2.532 +ddrem397 remainder 12345 5.01 -> 0.36 +ddrem398 remainder 12345 5.1 -> 3.0 + +-- the nasty division-by-1 cases +ddrem401 remainder 0.5 1 -> 0.5 +ddrem402 remainder 0.55 1 -> 0.55 +ddrem403 remainder 0.555 1 -> 0.555 +ddrem404 remainder 0.5555 1 -> 0.5555 +ddrem405 remainder 0.55555 1 -> 0.55555 +ddrem406 remainder 0.555555 1 -> 0.555555 +ddrem407 remainder 0.5555555 1 -> 0.5555555 +ddrem408 remainder 0.55555555 1 -> 0.55555555 +ddrem409 remainder 0.555555555 1 -> 0.555555555 + +-- folddowns +ddrem421 remainder 1E+384 1 -> NaN Division_impossible +ddrem422 remainder 1E+384 1E+383 -> 0E+369 Clamped +ddrem423 remainder 1E+384 2E+383 -> 0E+369 Clamped +ddrem424 remainder 1E+384 3E+383 -> 1.00000000000000E+383 Clamped +ddrem425 remainder 1E+384 4E+383 -> 2.00000000000000E+383 Clamped +ddrem426 remainder 1E+384 5E+383 -> 0E+369 Clamped +ddrem427 remainder 1E+384 6E+383 -> 4.00000000000000E+383 Clamped +ddrem428 remainder 1E+384 7E+383 -> 3.00000000000000E+383 Clamped +ddrem429 remainder 1E+384 8E+383 -> 2.00000000000000E+383 Clamped +ddrem430 remainder 1E+384 9E+383 -> 1.00000000000000E+383 Clamped +-- tinies +ddrem431 remainder 1E-397 1E-398 -> 0E-398 +ddrem432 remainder 1E-397 2E-398 -> 0E-398 +ddrem433 remainder 1E-397 3E-398 -> 1E-398 Subnormal +ddrem434 remainder 1E-397 4E-398 -> 2E-398 Subnormal +ddrem435 remainder 1E-397 5E-398 -> 0E-398 +ddrem436 remainder 1E-397 6E-398 -> 4E-398 Subnormal +ddrem437 remainder 1E-397 7E-398 -> 3E-398 Subnormal +ddrem438 remainder 1E-397 8E-398 -> 2E-398 Subnormal +ddrem439 remainder 1E-397 9E-398 -> 1E-398 Subnormal +ddrem440 remainder 1E-397 10E-398 -> 0E-398 +ddrem441 remainder 1E-397 11E-398 -> 1.0E-397 Subnormal +ddrem442 remainder 100E-397 11E-398 -> 1.0E-397 Subnormal +ddrem443 remainder 100E-397 20E-398 -> 0E-398 +ddrem444 remainder 100E-397 21E-398 -> 1.3E-397 Subnormal +ddrem445 remainder 100E-397 30E-398 -> 1.0E-397 Subnormal + +-- zero signs +ddrem650 remainder 1 1 -> 0 +ddrem651 remainder -1 1 -> -0 +ddrem652 remainder 1 -1 -> 0 +ddrem653 remainder -1 -1 -> -0 +ddrem654 remainder 0 1 -> 0 +ddrem655 remainder -0 1 -> -0 +ddrem656 remainder 0 -1 -> 0 +ddrem657 remainder -0 -1 -> -0 +ddrem658 remainder 0.00 1 -> 0.00 +ddrem659 remainder -0.00 1 -> -0.00 + +-- Specials +ddrem680 remainder Inf -Inf -> NaN Invalid_operation +ddrem681 remainder Inf -1000 -> NaN Invalid_operation +ddrem682 remainder Inf -1 -> NaN Invalid_operation +ddrem683 remainder Inf 0 -> NaN Invalid_operation +ddrem684 remainder Inf -0 -> NaN Invalid_operation +ddrem685 remainder Inf 1 -> NaN Invalid_operation +ddrem686 remainder Inf 1000 -> NaN Invalid_operation +ddrem687 remainder Inf Inf -> NaN Invalid_operation +ddrem688 remainder -1000 Inf -> -1000 +ddrem689 remainder -Inf Inf -> NaN Invalid_operation +ddrem691 remainder -1 Inf -> -1 +ddrem692 remainder 0 Inf -> 0 +ddrem693 remainder -0 Inf -> -0 +ddrem694 remainder 1 Inf -> 1 +ddrem695 remainder 1000 Inf -> 1000 +ddrem696 remainder Inf Inf -> NaN Invalid_operation + +ddrem700 remainder -Inf -Inf -> NaN Invalid_operation +ddrem701 remainder -Inf -1000 -> NaN Invalid_operation +ddrem702 remainder -Inf -1 -> NaN Invalid_operation +ddrem703 remainder -Inf -0 -> NaN Invalid_operation +ddrem704 remainder -Inf 0 -> NaN Invalid_operation +ddrem705 remainder -Inf 1 -> NaN Invalid_operation +ddrem706 remainder -Inf 1000 -> NaN Invalid_operation +ddrem707 remainder -Inf Inf -> NaN Invalid_operation +ddrem708 remainder -Inf -Inf -> NaN Invalid_operation +ddrem709 remainder -1000 Inf -> -1000 +ddrem710 remainder -1 -Inf -> -1 +ddrem711 remainder -0 -Inf -> -0 +ddrem712 remainder 0 -Inf -> 0 +ddrem713 remainder 1 -Inf -> 1 +ddrem714 remainder 1000 -Inf -> 1000 +ddrem715 remainder Inf -Inf -> NaN Invalid_operation + +ddrem721 remainder NaN -Inf -> NaN +ddrem722 remainder NaN -1000 -> NaN +ddrem723 remainder NaN -1 -> NaN +ddrem724 remainder NaN -0 -> NaN +ddrem725 remainder -NaN 0 -> -NaN +ddrem726 remainder NaN 1 -> NaN +ddrem727 remainder NaN 1000 -> NaN +ddrem728 remainder NaN Inf -> NaN +ddrem729 remainder NaN -NaN -> NaN +ddrem730 remainder -Inf NaN -> NaN +ddrem731 remainder -1000 NaN -> NaN +ddrem732 remainder -1 NaN -> NaN +ddrem733 remainder -0 -NaN -> -NaN +ddrem734 remainder 0 NaN -> NaN +ddrem735 remainder 1 -NaN -> -NaN +ddrem736 remainder 1000 NaN -> NaN +ddrem737 remainder Inf NaN -> NaN + +ddrem741 remainder sNaN -Inf -> NaN Invalid_operation +ddrem742 remainder sNaN -1000 -> NaN Invalid_operation +ddrem743 remainder -sNaN -1 -> -NaN Invalid_operation +ddrem744 remainder sNaN -0 -> NaN Invalid_operation +ddrem745 remainder sNaN 0 -> NaN Invalid_operation +ddrem746 remainder sNaN 1 -> NaN Invalid_operation +ddrem747 remainder sNaN 1000 -> NaN Invalid_operation +ddrem749 remainder sNaN NaN -> NaN Invalid_operation +ddrem750 remainder sNaN sNaN -> NaN Invalid_operation +ddrem751 remainder NaN sNaN -> NaN Invalid_operation +ddrem752 remainder -Inf sNaN -> NaN Invalid_operation +ddrem753 remainder -1000 sNaN -> NaN Invalid_operation +ddrem754 remainder -1 sNaN -> NaN Invalid_operation +ddrem755 remainder -0 sNaN -> NaN Invalid_operation +ddrem756 remainder 0 sNaN -> NaN Invalid_operation +ddrem757 remainder 1 sNaN -> NaN Invalid_operation +ddrem758 remainder 1000 sNaN -> NaN Invalid_operation +ddrem759 remainder Inf -sNaN -> -NaN Invalid_operation + +-- propaging NaNs +ddrem760 remainder NaN1 NaN7 -> NaN1 +ddrem761 remainder sNaN2 NaN8 -> NaN2 Invalid_operation +ddrem762 remainder NaN3 sNaN9 -> NaN9 Invalid_operation +ddrem763 remainder sNaN4 sNaN10 -> NaN4 Invalid_operation +ddrem764 remainder 15 NaN11 -> NaN11 +ddrem765 remainder NaN6 NaN12 -> NaN6 +ddrem766 remainder Inf NaN13 -> NaN13 +ddrem767 remainder NaN14 -Inf -> NaN14 +ddrem768 remainder 0 NaN15 -> NaN15 +ddrem769 remainder NaN16 -0 -> NaN16 + +-- edge cases of impossible +ddrem770 remainder 1234567890123456 10 -> 6 +ddrem771 remainder 1234567890123456 1 -> 0 +ddrem772 remainder 1234567890123456 0.1 -> NaN Division_impossible +ddrem773 remainder 1234567890123456 0.01 -> NaN Division_impossible + +-- long operand checks +ddrem801 remainder 12345678000 100 -> 0 +ddrem802 remainder 1 12345678000 -> 1 +ddrem803 remainder 1234567800 10 -> 0 +ddrem804 remainder 1 1234567800 -> 1 +ddrem805 remainder 1234567890 10 -> 0 +ddrem806 remainder 1 1234567890 -> 1 +ddrem807 remainder 1234567891 10 -> 1 +ddrem808 remainder 1 1234567891 -> 1 +ddrem809 remainder 12345678901 100 -> 1 +ddrem810 remainder 1 12345678901 -> 1 +ddrem811 remainder 1234567896 10 -> 6 +ddrem812 remainder 1 1234567896 -> 1 + +ddrem821 remainder 12345678000 100 -> 0 +ddrem822 remainder 1 12345678000 -> 1 +ddrem823 remainder 1234567800 10 -> 0 +ddrem824 remainder 1 1234567800 -> 1 +ddrem825 remainder 1234567890 10 -> 0 +ddrem826 remainder 1 1234567890 -> 1 +ddrem827 remainder 1234567891 10 -> 1 +ddrem828 remainder 1 1234567891 -> 1 +ddrem829 remainder 12345678901 100 -> 1 +ddrem830 remainder 1 12345678901 -> 1 +ddrem831 remainder 1234567896 10 -> 6 +ddrem832 remainder 1 1234567896 -> 1 + +-- from divideint +ddrem840 remainder 100000000.0 1 -> 0.0 +ddrem841 remainder 100000000.4 1 -> 0.4 +ddrem842 remainder 100000000.5 1 -> 0.5 +ddrem843 remainder 100000000.9 1 -> 0.9 +ddrem844 remainder 100000000.999 1 -> 0.999 +ddrem850 remainder 100000003 5 -> 3 +ddrem851 remainder 10000003 5 -> 3 +ddrem852 remainder 1000003 5 -> 3 +ddrem853 remainder 100003 5 -> 3 +ddrem854 remainder 10003 5 -> 3 +ddrem855 remainder 1003 5 -> 3 +ddrem856 remainder 103 5 -> 3 +ddrem857 remainder 13 5 -> 3 +ddrem858 remainder 1 5 -> 1 + +-- Vladimir's cases 1234567890123456 +ddrem860 remainder 123.0e1 1000000000000000 -> 1230 +ddrem861 remainder 1230 1000000000000000 -> 1230 +ddrem862 remainder 12.3e2 1000000000000000 -> 1230 +ddrem863 remainder 1.23e3 1000000000000000 -> 1230 +ddrem864 remainder 123e1 1000000000000000 -> 1230 +ddrem870 remainder 123e1 1000000000000000 -> 1230 +ddrem871 remainder 123e1 100000000000000 -> 1230 +ddrem872 remainder 123e1 10000000000000 -> 1230 +ddrem873 remainder 123e1 1000000000000 -> 1230 +ddrem874 remainder 123e1 100000000000 -> 1230 +ddrem875 remainder 123e1 10000000000 -> 1230 +ddrem876 remainder 123e1 1000000000 -> 1230 +ddrem877 remainder 123e1 100000000 -> 1230 +ddrem878 remainder 1230 100000000 -> 1230 +ddrem879 remainder 123e1 10000000 -> 1230 +ddrem880 remainder 123e1 1000000 -> 1230 +ddrem881 remainder 123e1 100000 -> 1230 +ddrem882 remainder 123e1 10000 -> 1230 +ddrem883 remainder 123e1 1000 -> 230 +ddrem884 remainder 123e1 100 -> 30 +ddrem885 remainder 123e1 10 -> 0 +ddrem886 remainder 123e1 1 -> 0 + +ddrem890 remainder 123e1 2000000000000000 -> 1230 +ddrem891 remainder 123e1 200000000000000 -> 1230 +ddrem892 remainder 123e1 20000000000000 -> 1230 +ddrem893 remainder 123e1 2000000000000 -> 1230 +ddrem894 remainder 123e1 200000000000 -> 1230 +ddrem895 remainder 123e1 20000000000 -> 1230 +ddrem896 remainder 123e1 2000000000 -> 1230 +ddrem897 remainder 123e1 200000000 -> 1230 +ddrem899 remainder 123e1 20000000 -> 1230 +ddrem900 remainder 123e1 2000000 -> 1230 +ddrem901 remainder 123e1 200000 -> 1230 +ddrem902 remainder 123e1 20000 -> 1230 +ddrem903 remainder 123e1 2000 -> 1230 +ddrem904 remainder 123e1 200 -> 30 +ddrem905 remainder 123e1 20 -> 10 +ddrem906 remainder 123e1 2 -> 0 + +ddrem910 remainder 123e1 5000000000000000 -> 1230 +ddrem911 remainder 123e1 500000000000000 -> 1230 +ddrem912 remainder 123e1 50000000000000 -> 1230 +ddrem913 remainder 123e1 5000000000000 -> 1230 +ddrem914 remainder 123e1 500000000000 -> 1230 +ddrem915 remainder 123e1 50000000000 -> 1230 +ddrem916 remainder 123e1 5000000000 -> 1230 +ddrem917 remainder 123e1 500000000 -> 1230 +ddrem919 remainder 123e1 50000000 -> 1230 +ddrem920 remainder 123e1 5000000 -> 1230 +ddrem921 remainder 123e1 500000 -> 1230 +ddrem922 remainder 123e1 50000 -> 1230 +ddrem923 remainder 123e1 5000 -> 1230 +ddrem924 remainder 123e1 500 -> 230 +ddrem925 remainder 123e1 50 -> 30 +ddrem926 remainder 123e1 5 -> 0 + +ddrem930 remainder 123e1 9000000000000000 -> 1230 +ddrem931 remainder 123e1 900000000000000 -> 1230 +ddrem932 remainder 123e1 90000000000000 -> 1230 +ddrem933 remainder 123e1 9000000000000 -> 1230 +ddrem934 remainder 123e1 900000000000 -> 1230 +ddrem935 remainder 123e1 90000000000 -> 1230 +ddrem936 remainder 123e1 9000000000 -> 1230 +ddrem937 remainder 123e1 900000000 -> 1230 +ddrem939 remainder 123e1 90000000 -> 1230 +ddrem940 remainder 123e1 9000000 -> 1230 +ddrem941 remainder 123e1 900000 -> 1230 +ddrem942 remainder 123e1 90000 -> 1230 +ddrem943 remainder 123e1 9000 -> 1230 +ddrem944 remainder 123e1 900 -> 330 +ddrem945 remainder 123e1 90 -> 60 +ddrem946 remainder 123e1 9 -> 6 + +ddrem950 remainder 123e1 1000000000000000 -> 1230 +ddrem961 remainder 123e1 2999999999999999 -> 1230 +ddrem962 remainder 123e1 3999999999999999 -> 1230 +ddrem963 remainder 123e1 4999999999999999 -> 1230 +ddrem964 remainder 123e1 5999999999999999 -> 1230 +ddrem965 remainder 123e1 6999999999999999 -> 1230 +ddrem966 remainder 123e1 7999999999999999 -> 1230 +ddrem967 remainder 123e1 8999999999999999 -> 1230 +ddrem968 remainder 123e1 9999999999999999 -> 1230 +ddrem969 remainder 123e1 9876543210987654 -> 1230 + +ddrem980 remainder 123e1 1000E299 -> 1.23E+3 -- 123E+1 internally + +-- overflow and underflow tests [from divide] +ddrem1051 remainder 1e+277 1e-311 -> NaN Division_impossible +ddrem1052 remainder 1e+277 -1e-311 -> NaN Division_impossible +ddrem1053 remainder -1e+277 1e-311 -> NaN Division_impossible +ddrem1054 remainder -1e+277 -1e-311 -> NaN Division_impossible +ddrem1055 remainder 1e-277 1e+311 -> 1E-277 +ddrem1056 remainder 1e-277 -1e+311 -> 1E-277 +ddrem1057 remainder -1e-277 1e+311 -> -1E-277 +ddrem1058 remainder -1e-277 -1e+311 -> -1E-277 + +-- destructive subtract +ddrem1101 remainder 1234567890123456 1.000000000000001 -> 0.765432109876546 +ddrem1102 remainder 1234567890123456 1.00000000000001 -> 0.65432109876557 +ddrem1103 remainder 1234567890123456 1.0000000000001 -> 0.5432109876668 +ddrem1104 remainder 1234567890123455 4.000000000000001 -> 2.691358027469137 +ddrem1105 remainder 1234567890123456 4.000000000000001 -> 3.691358027469137 +ddrem1106 remainder 1234567890123456 4.9999999999999 -> 0.6913578024696 +ddrem1107 remainder 1234567890123456 4.99999999999999 -> 3.46913578024691 +ddrem1108 remainder 1234567890123456 4.999999999999999 -> 1.246913578024691 +ddrem1109 remainder 1234567890123456 5.000000000000001 -> 0.753086421975309 +ddrem1110 remainder 1234567890123456 5.00000000000001 -> 3.53086421975310 +ddrem1111 remainder 1234567890123456 5.0000000000001 -> 1.3086421975314 + +-- Null tests +ddrem1000 remainder 10 # -> NaN Invalid_operation +ddrem1001 remainder # 10 -> NaN Invalid_operation + Added: python/branches/release25-maint/Lib/test/decimaltestdata/ddRemainderNear.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/ddRemainderNear.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,629 @@ +------------------------------------------------------------------------ +-- ddRemainderNear.decTest -- decDouble remainder-near -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +precision: 16 +maxExponent: 384 +minExponent: -383 +extended: 1 +clamp: 1 +rounding: half_even + +-- sanity checks (as base, above) +ddrmn001 remaindernear 1 1 -> 0 +ddrmn002 remaindernear 2 1 -> 0 +ddrmn003 remaindernear 1 2 -> 1 +ddrmn004 remaindernear 2 2 -> 0 +ddrmn005 remaindernear 0 1 -> 0 +ddrmn006 remaindernear 0 2 -> 0 +ddrmn007 remaindernear 1 3 -> 1 +ddrmn008 remaindernear 2 3 -> -1 +ddrmn009 remaindernear 3 3 -> 0 + +ddrmn010 remaindernear 2.4 1 -> 0.4 +ddrmn011 remaindernear 2.4 -1 -> 0.4 +ddrmn012 remaindernear -2.4 1 -> -0.4 +ddrmn013 remaindernear -2.4 -1 -> -0.4 +ddrmn014 remaindernear 2.40 1 -> 0.40 +ddrmn015 remaindernear 2.400 1 -> 0.400 +ddrmn016 remaindernear 2.4 2 -> 0.4 +ddrmn017 remaindernear 2.400 2 -> 0.400 +ddrmn018 remaindernear 2. 2 -> 0 +ddrmn019 remaindernear 20 20 -> 0 + +ddrmn020 remaindernear 187 187 -> 0 +ddrmn021 remaindernear 5 2 -> 1 +ddrmn022 remaindernear 5 2.0 -> 1.0 +ddrmn023 remaindernear 5 2.000 -> 1.000 +ddrmn024 remaindernear 5 0.200 -> 0.000 +ddrmn025 remaindernear 5 0.200 -> 0.000 + +ddrmn030 remaindernear 1 2 -> 1 +ddrmn031 remaindernear 1 4 -> 1 +ddrmn032 remaindernear 1 8 -> 1 + +ddrmn033 remaindernear 1 16 -> 1 +ddrmn034 remaindernear 1 32 -> 1 +ddrmn035 remaindernear 1 64 -> 1 +ddrmn040 remaindernear 1 -2 -> 1 +ddrmn041 remaindernear 1 -4 -> 1 +ddrmn042 remaindernear 1 -8 -> 1 +ddrmn043 remaindernear 1 -16 -> 1 +ddrmn044 remaindernear 1 -32 -> 1 +ddrmn045 remaindernear 1 -64 -> 1 +ddrmn050 remaindernear -1 2 -> -1 +ddrmn051 remaindernear -1 4 -> -1 +ddrmn052 remaindernear -1 8 -> -1 +ddrmn053 remaindernear -1 16 -> -1 +ddrmn054 remaindernear -1 32 -> -1 +ddrmn055 remaindernear -1 64 -> -1 +ddrmn060 remaindernear -1 -2 -> -1 +ddrmn061 remaindernear -1 -4 -> -1 +ddrmn062 remaindernear -1 -8 -> -1 +ddrmn063 remaindernear -1 -16 -> -1 +ddrmn064 remaindernear -1 -32 -> -1 +ddrmn065 remaindernear -1 -64 -> -1 + +ddrmn066 remaindernear 9.9 1 -> -0.1 +ddrmn067 remaindernear 99.7 1 -> -0.3 +ddrmn068 remaindernear 999999999 1 -> 0 +ddrmn069 remaindernear 999999999.4 1 -> 0.4 +ddrmn070 remaindernear 999999999.5 1 -> -0.5 +ddrmn071 remaindernear 999999999.9 1 -> -0.1 +ddrmn072 remaindernear 999999999.999 1 -> -0.001 +ddrmn073 remaindernear 999999.999999 1 -> -0.000001 +ddrmn074 remaindernear 9 1 -> 0 +ddrmn075 remaindernear 9999999999999999 1 -> 0 +ddrmn076 remaindernear 9999999999999999 2 -> -1 +ddrmn077 remaindernear 9999999999999999 3 -> 0 +ddrmn078 remaindernear 9999999999999999 4 -> -1 + +ddrmn080 remaindernear 0. 1 -> 0 +ddrmn081 remaindernear .0 1 -> 0.0 +ddrmn082 remaindernear 0.00 1 -> 0.00 +ddrmn083 remaindernear 0.00E+9 1 -> 0 +ddrmn084 remaindernear 0.00E+3 1 -> 0 +ddrmn085 remaindernear 0.00E+2 1 -> 0 +ddrmn086 remaindernear 0.00E+1 1 -> 0.0 +ddrmn087 remaindernear 0.00E+0 1 -> 0.00 +ddrmn088 remaindernear 0.00E-0 1 -> 0.00 +ddrmn089 remaindernear 0.00E-1 1 -> 0.000 +ddrmn090 remaindernear 0.00E-2 1 -> 0.0000 +ddrmn091 remaindernear 0.00E-3 1 -> 0.00000 +ddrmn092 remaindernear 0.00E-4 1 -> 0.000000 +ddrmn093 remaindernear 0.00E-5 1 -> 0E-7 +ddrmn094 remaindernear 0.00E-6 1 -> 0E-8 +ddrmn095 remaindernear 0.0000E-50 1 -> 0E-54 + +-- Various flavours of remaindernear by 0 +ddrmn101 remaindernear 0 0 -> NaN Division_undefined +ddrmn102 remaindernear 0 -0 -> NaN Division_undefined +ddrmn103 remaindernear -0 0 -> NaN Division_undefined +ddrmn104 remaindernear -0 -0 -> NaN Division_undefined +ddrmn105 remaindernear 0.0E5 0 -> NaN Division_undefined +ddrmn106 remaindernear 0.000 0 -> NaN Division_undefined +-- [Some think this next group should be Division_by_zero exception, but +-- IEEE 854 is explicit that it is Invalid operation .. for +-- remainder-near, anyway] +ddrmn107 remaindernear 0.0001 0 -> NaN Invalid_operation +ddrmn108 remaindernear 0.01 0 -> NaN Invalid_operation +ddrmn109 remaindernear 0.1 0 -> NaN Invalid_operation +ddrmn110 remaindernear 1 0 -> NaN Invalid_operation +ddrmn111 remaindernear 1 0.0 -> NaN Invalid_operation +ddrmn112 remaindernear 10 0.0 -> NaN Invalid_operation +ddrmn113 remaindernear 1E+100 0.0 -> NaN Invalid_operation +ddrmn114 remaindernear 1E+380 0 -> NaN Invalid_operation +ddrmn115 remaindernear 0.0001 -0 -> NaN Invalid_operation +ddrmn116 remaindernear 0.01 -0 -> NaN Invalid_operation +ddrmn119 remaindernear 0.1 -0 -> NaN Invalid_operation +ddrmn120 remaindernear 1 -0 -> NaN Invalid_operation +ddrmn121 remaindernear 1 -0.0 -> NaN Invalid_operation +ddrmn122 remaindernear 10 -0.0 -> NaN Invalid_operation +ddrmn123 remaindernear 1E+100 -0.0 -> NaN Invalid_operation +ddrmn124 remaindernear 1E+384 -0 -> NaN Invalid_operation +-- and zeros on left +ddrmn130 remaindernear 0 1 -> 0 +ddrmn131 remaindernear 0 -1 -> 0 +ddrmn132 remaindernear 0.0 1 -> 0.0 +ddrmn133 remaindernear 0.0 -1 -> 0.0 +ddrmn134 remaindernear -0 1 -> -0 +ddrmn135 remaindernear -0 -1 -> -0 +ddrmn136 remaindernear -0.0 1 -> -0.0 +ddrmn137 remaindernear -0.0 -1 -> -0.0 + +-- 0.5ers +ddrmn143 remaindernear 0.5 2 -> 0.5 +ddrmn144 remaindernear 0.5 2.1 -> 0.5 +ddrmn145 remaindernear 0.5 2.01 -> 0.50 +ddrmn146 remaindernear 0.5 2.001 -> 0.500 +ddrmn147 remaindernear 0.50 2 -> 0.50 +ddrmn148 remaindernear 0.50 2.01 -> 0.50 +ddrmn149 remaindernear 0.50 2.001 -> 0.500 + +-- steadies +ddrmn150 remaindernear 1 1 -> 0 +ddrmn151 remaindernear 1 2 -> 1 +ddrmn152 remaindernear 1 3 -> 1 +ddrmn153 remaindernear 1 4 -> 1 +ddrmn154 remaindernear 1 5 -> 1 +ddrmn155 remaindernear 1 6 -> 1 +ddrmn156 remaindernear 1 7 -> 1 +ddrmn157 remaindernear 1 8 -> 1 +ddrmn158 remaindernear 1 9 -> 1 +ddrmn159 remaindernear 1 10 -> 1 +ddrmn160 remaindernear 1 1 -> 0 +ddrmn161 remaindernear 2 1 -> 0 +ddrmn162 remaindernear 3 1 -> 0 +ddrmn163 remaindernear 4 1 -> 0 +ddrmn164 remaindernear 5 1 -> 0 +ddrmn165 remaindernear 6 1 -> 0 +ddrmn166 remaindernear 7 1 -> 0 +ddrmn167 remaindernear 8 1 -> 0 +ddrmn168 remaindernear 9 1 -> 0 +ddrmn169 remaindernear 10 1 -> 0 + +-- some differences from remainder +ddrmn171 remaindernear 0.4 1.020 -> 0.400 +ddrmn172 remaindernear 0.50 1.020 -> 0.500 +ddrmn173 remaindernear 0.51 1.020 -> 0.510 +ddrmn174 remaindernear 0.52 1.020 -> -0.500 +ddrmn175 remaindernear 0.6 1.020 -> -0.420 + +-- More flavours of remaindernear by 0 +ddrmn201 remaindernear 0 0 -> NaN Division_undefined +ddrmn202 remaindernear 0.0E5 0 -> NaN Division_undefined +ddrmn203 remaindernear 0.000 0 -> NaN Division_undefined +ddrmn204 remaindernear 0.0001 0 -> NaN Invalid_operation +ddrmn205 remaindernear 0.01 0 -> NaN Invalid_operation +ddrmn206 remaindernear 0.1 0 -> NaN Invalid_operation +ddrmn207 remaindernear 1 0 -> NaN Invalid_operation +ddrmn208 remaindernear 1 0.0 -> NaN Invalid_operation +ddrmn209 remaindernear 10 0.0 -> NaN Invalid_operation +ddrmn210 remaindernear 1E+100 0.0 -> NaN Invalid_operation +ddrmn211 remaindernear 1E+380 0 -> NaN Invalid_operation + +-- tests from the extended specification +ddrmn221 remaindernear 2.1 3 -> -0.9 +ddrmn222 remaindernear 10 6 -> -2 +ddrmn223 remaindernear 10 3 -> 1 +ddrmn224 remaindernear -10 3 -> -1 +ddrmn225 remaindernear 10.2 1 -> 0.2 +ddrmn226 remaindernear 10 0.3 -> 0.1 +ddrmn227 remaindernear 3.6 1.3 -> -0.3 + +-- some differences from remainder +ddrmn231 remaindernear -0.4 1.020 -> -0.400 +ddrmn232 remaindernear -0.50 1.020 -> -0.500 +ddrmn233 remaindernear -0.51 1.020 -> -0.510 +ddrmn234 remaindernear -0.52 1.020 -> 0.500 +ddrmn235 remaindernear -0.6 1.020 -> 0.420 + +-- high Xs +ddrmn240 remaindernear 1E+2 1.00 -> 0.00 + +-- ddrmn3xx are from DiagBigDecimal +ddrmn301 remaindernear 1 3 -> 1 +ddrmn302 remaindernear 5 5 -> 0 +ddrmn303 remaindernear 13 10 -> 3 +ddrmn304 remaindernear 13 50 -> 13 +ddrmn305 remaindernear 13 100 -> 13 +ddrmn306 remaindernear 13 1000 -> 13 +ddrmn307 remaindernear .13 1 -> 0.13 +ddrmn308 remaindernear 0.133 1 -> 0.133 +ddrmn309 remaindernear 0.1033 1 -> 0.1033 +ddrmn310 remaindernear 1.033 1 -> 0.033 +ddrmn311 remaindernear 10.33 1 -> 0.33 +ddrmn312 remaindernear 10.33 10 -> 0.33 +ddrmn313 remaindernear 103.3 1 -> 0.3 +ddrmn314 remaindernear 133 10 -> 3 +ddrmn315 remaindernear 1033 10 -> 3 +ddrmn316 remaindernear 1033 50 -> -17 +ddrmn317 remaindernear 101.0 3 -> -1.0 +ddrmn318 remaindernear 102.0 3 -> 0.0 +ddrmn319 remaindernear 103.0 3 -> 1.0 +ddrmn320 remaindernear 2.40 1 -> 0.40 +ddrmn321 remaindernear 2.400 1 -> 0.400 +ddrmn322 remaindernear 2.4 1 -> 0.4 +ddrmn323 remaindernear 2.4 2 -> 0.4 +ddrmn324 remaindernear 2.400 2 -> 0.400 +ddrmn325 remaindernear 1 0.3 -> 0.1 +ddrmn326 remaindernear 1 0.30 -> 0.10 +ddrmn327 remaindernear 1 0.300 -> 0.100 +ddrmn328 remaindernear 1 0.3000 -> 0.1000 +ddrmn329 remaindernear 1.0 0.3 -> 0.1 +ddrmn330 remaindernear 1.00 0.3 -> 0.10 +ddrmn331 remaindernear 1.000 0.3 -> 0.100 +ddrmn332 remaindernear 1.0000 0.3 -> 0.1000 +ddrmn333 remaindernear 0.5 2 -> 0.5 +ddrmn334 remaindernear 0.5 2.1 -> 0.5 +ddrmn335 remaindernear 0.5 2.01 -> 0.50 +ddrmn336 remaindernear 0.5 2.001 -> 0.500 +ddrmn337 remaindernear 0.50 2 -> 0.50 +ddrmn338 remaindernear 0.50 2.01 -> 0.50 +ddrmn339 remaindernear 0.50 2.001 -> 0.500 + +ddrmn340 remaindernear 0.5 0.5000001 -> -1E-7 +ddrmn341 remaindernear 0.5 0.50000001 -> -1E-8 +ddrmn342 remaindernear 0.5 0.500000001 -> -1E-9 +ddrmn343 remaindernear 0.5 0.5000000001 -> -1E-10 +ddrmn344 remaindernear 0.5 0.50000000001 -> -1E-11 +ddrmn345 remaindernear 0.5 0.4999999 -> 1E-7 +ddrmn346 remaindernear 0.5 0.49999999 -> 1E-8 +ddrmn347 remaindernear 0.5 0.499999999 -> 1E-9 +ddrmn348 remaindernear 0.5 0.4999999999 -> 1E-10 +ddrmn349 remaindernear 0.5 0.49999999999 -> 1E-11 +ddrmn350 remaindernear 0.5 0.499999999999 -> 1E-12 + +ddrmn351 remaindernear 0.03 7 -> 0.03 +ddrmn352 remaindernear 5 2 -> 1 +ddrmn353 remaindernear 4.1 2 -> 0.1 +ddrmn354 remaindernear 4.01 2 -> 0.01 +ddrmn355 remaindernear 4.001 2 -> 0.001 +ddrmn356 remaindernear 4.0001 2 -> 0.0001 +ddrmn357 remaindernear 4.00001 2 -> 0.00001 +ddrmn358 remaindernear 4.000001 2 -> 0.000001 +ddrmn359 remaindernear 4.0000001 2 -> 1E-7 + +ddrmn360 remaindernear 1.2 0.7345 -> -0.2690 +ddrmn361 remaindernear 0.8 12 -> 0.8 +ddrmn362 remaindernear 0.8 0.2 -> 0.0 +ddrmn363 remaindernear 0.8 0.3 -> -0.1 +ddrmn364 remaindernear 0.800 12 -> 0.800 +ddrmn365 remaindernear 0.800 1.7 -> 0.800 +ddrmn366 remaindernear 2.400 2 -> 0.400 + +-- round to even +ddrmn371 remaindernear 121 2 -> 1 +ddrmn372 remaindernear 122 2 -> 0 +ddrmn373 remaindernear 123 2 -> -1 +ddrmn374 remaindernear 124 2 -> 0 +ddrmn375 remaindernear 125 2 -> 1 +ddrmn376 remaindernear 126 2 -> 0 +ddrmn377 remaindernear 127 2 -> -1 + +ddrmn381 remaindernear 12345 1 -> 0 +ddrmn382 remaindernear 12345 1.0001 -> -0.2344 +ddrmn383 remaindernear 12345 1.001 -> -0.333 +ddrmn384 remaindernear 12345 1.01 -> -0.23 +ddrmn385 remaindernear 12345 1.1 -> -0.3 +ddrmn386 remaindernear 12355 4 -> -1 +ddrmn387 remaindernear 12345 4 -> 1 +ddrmn388 remaindernear 12355 4.0001 -> -1.3089 +ddrmn389 remaindernear 12345 4.0001 -> 0.6914 +ddrmn390 remaindernear 12345 4.9 -> 1.9 +ddrmn391 remaindernear 12345 4.99 -> -0.26 +ddrmn392 remaindernear 12345 4.999 -> 2.469 +ddrmn393 remaindernear 12345 4.9999 -> 0.2469 +ddrmn394 remaindernear 12345 5 -> 0 +ddrmn395 remaindernear 12345 5.0001 -> -0.2469 +ddrmn396 remaindernear 12345 5.001 -> -2.469 +ddrmn397 remaindernear 12345 5.01 -> 0.36 +ddrmn398 remaindernear 12345 5.1 -> -2.1 + +-- the nasty division-by-1 cases +ddrmn401 remaindernear 0.4 1 -> 0.4 +ddrmn402 remaindernear 0.45 1 -> 0.45 +ddrmn403 remaindernear 0.455 1 -> 0.455 +ddrmn404 remaindernear 0.4555 1 -> 0.4555 +ddrmn405 remaindernear 0.45555 1 -> 0.45555 +ddrmn406 remaindernear 0.455555 1 -> 0.455555 +ddrmn407 remaindernear 0.4555555 1 -> 0.4555555 +ddrmn408 remaindernear 0.45555555 1 -> 0.45555555 +ddrmn409 remaindernear 0.455555555 1 -> 0.455555555 +-- with spill... [412 exercises sticktab loop] +ddrmn411 remaindernear 0.5 1 -> 0.5 +ddrmn412 remaindernear 0.55 1 -> -0.45 +ddrmn413 remaindernear 0.555 1 -> -0.445 +ddrmn414 remaindernear 0.5555 1 -> -0.4445 +ddrmn415 remaindernear 0.55555 1 -> -0.44445 +ddrmn416 remaindernear 0.555555 1 -> -0.444445 +ddrmn417 remaindernear 0.5555555 1 -> -0.4444445 +ddrmn418 remaindernear 0.55555555 1 -> -0.44444445 +ddrmn419 remaindernear 0.555555555 1 -> -0.444444445 + +-- folddowns +ddrmn421 remaindernear 1E+384 1 -> NaN Division_impossible +ddrmn422 remaindernear 1E+384 1E+383 -> 0E+369 Clamped +ddrmn423 remaindernear 1E+384 2E+383 -> 0E+369 Clamped +ddrmn424 remaindernear 1E+384 3E+383 -> 1.00000000000000E+383 Clamped +ddrmn425 remaindernear 1E+384 4E+383 -> 2.00000000000000E+383 Clamped +ddrmn426 remaindernear 1E+384 5E+383 -> 0E+369 Clamped +ddrmn427 remaindernear 1E+384 6E+383 -> -2.00000000000000E+383 Clamped +ddrmn428 remaindernear 1E+384 7E+383 -> 3.00000000000000E+383 Clamped +ddrmn429 remaindernear 1E+384 8E+383 -> 2.00000000000000E+383 Clamped +ddrmn430 remaindernear 1E+384 9E+383 -> 1.00000000000000E+383 Clamped +-- tinies +ddrmn431 remaindernear 1E-397 1E-398 -> 0E-398 +ddrmn432 remaindernear 1E-397 2E-398 -> 0E-398 +ddrmn433 remaindernear 1E-397 3E-398 -> 1E-398 Subnormal +ddrmn434 remaindernear 1E-397 4E-398 -> 2E-398 Subnormal +ddrmn435 remaindernear 1E-397 5E-398 -> 0E-398 +ddrmn436 remaindernear 1E-397 6E-398 -> -2E-398 Subnormal +ddrmn437 remaindernear 1E-397 7E-398 -> 3E-398 Subnormal +ddrmn438 remaindernear 1E-397 8E-398 -> 2E-398 Subnormal +ddrmn439 remaindernear 1E-397 9E-398 -> 1E-398 Subnormal +ddrmn440 remaindernear 1E-397 10E-398 -> 0E-398 +ddrmn441 remaindernear 1E-397 11E-398 -> -1E-398 Subnormal +ddrmn442 remaindernear 100E-397 11E-398 -> -1E-398 Subnormal +ddrmn443 remaindernear 100E-397 20E-398 -> 0E-398 +ddrmn444 remaindernear 100E-397 21E-398 -> -8E-398 Subnormal +ddrmn445 remaindernear 100E-397 30E-398 -> 1.0E-397 Subnormal + +-- zero signs +ddrmn650 remaindernear 1 1 -> 0 +ddrmn651 remaindernear -1 1 -> -0 +ddrmn652 remaindernear 1 -1 -> 0 +ddrmn653 remaindernear -1 -1 -> -0 +ddrmn654 remaindernear 0 1 -> 0 +ddrmn655 remaindernear -0 1 -> -0 +ddrmn656 remaindernear 0 -1 -> 0 +ddrmn657 remaindernear -0 -1 -> -0 +ddrmn658 remaindernear 0.00 1 -> 0.00 +ddrmn659 remaindernear -0.00 1 -> -0.00 + +-- Specials +ddrmn680 remaindernear Inf -Inf -> NaN Invalid_operation +ddrmn681 remaindernear Inf -1000 -> NaN Invalid_operation +ddrmn682 remaindernear Inf -1 -> NaN Invalid_operation +ddrmn683 remaindernear Inf 0 -> NaN Invalid_operation +ddrmn684 remaindernear Inf -0 -> NaN Invalid_operation +ddrmn685 remaindernear Inf 1 -> NaN Invalid_operation +ddrmn686 remaindernear Inf 1000 -> NaN Invalid_operation +ddrmn687 remaindernear Inf Inf -> NaN Invalid_operation +ddrmn688 remaindernear -1000 Inf -> -1000 +ddrmn689 remaindernear -Inf Inf -> NaN Invalid_operation +ddrmn691 remaindernear -1 Inf -> -1 +ddrmn692 remaindernear 0 Inf -> 0 +ddrmn693 remaindernear -0 Inf -> -0 +ddrmn694 remaindernear 1 Inf -> 1 +ddrmn695 remaindernear 1000 Inf -> 1000 +ddrmn696 remaindernear Inf Inf -> NaN Invalid_operation + +ddrmn700 remaindernear -Inf -Inf -> NaN Invalid_operation +ddrmn701 remaindernear -Inf -1000 -> NaN Invalid_operation +ddrmn702 remaindernear -Inf -1 -> NaN Invalid_operation +ddrmn703 remaindernear -Inf -0 -> NaN Invalid_operation +ddrmn704 remaindernear -Inf 0 -> NaN Invalid_operation +ddrmn705 remaindernear -Inf 1 -> NaN Invalid_operation +ddrmn706 remaindernear -Inf 1000 -> NaN Invalid_operation +ddrmn707 remaindernear -Inf Inf -> NaN Invalid_operation +ddrmn708 remaindernear -Inf -Inf -> NaN Invalid_operation +ddrmn709 remaindernear -1000 Inf -> -1000 +ddrmn710 remaindernear -1 -Inf -> -1 +ddrmn711 remaindernear -0 -Inf -> -0 +ddrmn712 remaindernear 0 -Inf -> 0 +ddrmn713 remaindernear 1 -Inf -> 1 +ddrmn714 remaindernear 1000 -Inf -> 1000 +ddrmn715 remaindernear Inf -Inf -> NaN Invalid_operation + +ddrmn721 remaindernear NaN -Inf -> NaN +ddrmn722 remaindernear NaN -1000 -> NaN +ddrmn723 remaindernear NaN -1 -> NaN +ddrmn724 remaindernear NaN -0 -> NaN +ddrmn725 remaindernear -NaN 0 -> -NaN +ddrmn726 remaindernear NaN 1 -> NaN +ddrmn727 remaindernear NaN 1000 -> NaN +ddrmn728 remaindernear NaN Inf -> NaN +ddrmn729 remaindernear NaN -NaN -> NaN +ddrmn730 remaindernear -Inf NaN -> NaN +ddrmn731 remaindernear -1000 NaN -> NaN +ddrmn732 remaindernear -1 NaN -> NaN +ddrmn733 remaindernear -0 -NaN -> -NaN +ddrmn734 remaindernear 0 NaN -> NaN +ddrmn735 remaindernear 1 -NaN -> -NaN +ddrmn736 remaindernear 1000 NaN -> NaN +ddrmn737 remaindernear Inf NaN -> NaN + +ddrmn741 remaindernear sNaN -Inf -> NaN Invalid_operation +ddrmn742 remaindernear sNaN -1000 -> NaN Invalid_operation +ddrmn743 remaindernear -sNaN -1 -> -NaN Invalid_operation +ddrmn744 remaindernear sNaN -0 -> NaN Invalid_operation +ddrmn745 remaindernear sNaN 0 -> NaN Invalid_operation +ddrmn746 remaindernear sNaN 1 -> NaN Invalid_operation +ddrmn747 remaindernear sNaN 1000 -> NaN Invalid_operation +ddrmn749 remaindernear sNaN NaN -> NaN Invalid_operation +ddrmn750 remaindernear sNaN sNaN -> NaN Invalid_operation +ddrmn751 remaindernear NaN sNaN -> NaN Invalid_operation +ddrmn752 remaindernear -Inf sNaN -> NaN Invalid_operation +ddrmn753 remaindernear -1000 sNaN -> NaN Invalid_operation +ddrmn754 remaindernear -1 sNaN -> NaN Invalid_operation +ddrmn755 remaindernear -0 sNaN -> NaN Invalid_operation +ddrmn756 remaindernear 0 sNaN -> NaN Invalid_operation +ddrmn757 remaindernear 1 sNaN -> NaN Invalid_operation +ddrmn758 remaindernear 1000 sNaN -> NaN Invalid_operation +ddrmn759 remaindernear Inf -sNaN -> -NaN Invalid_operation + +-- propaging NaNs +ddrmn760 remaindernear NaN1 NaN7 -> NaN1 +ddrmn761 remaindernear sNaN2 NaN8 -> NaN2 Invalid_operation +ddrmn762 remaindernear NaN3 sNaN9 -> NaN9 Invalid_operation +ddrmn763 remaindernear sNaN4 sNaN10 -> NaN4 Invalid_operation +ddrmn764 remaindernear 15 NaN11 -> NaN11 +ddrmn765 remaindernear NaN6 NaN12 -> NaN6 +ddrmn766 remaindernear Inf NaN13 -> NaN13 +ddrmn767 remaindernear NaN14 -Inf -> NaN14 +ddrmn768 remaindernear 0 NaN15 -> NaN15 +ddrmn769 remaindernear NaN16 -0 -> NaN16 + +-- edge cases of impossible +ddrmn770 remaindernear 1234567890123456 10 -> -4 +ddrmn771 remaindernear 1234567890123456 1 -> 0 +ddrmn772 remaindernear 1234567890123456 0.1 -> NaN Division_impossible +ddrmn773 remaindernear 1234567890123456 0.01 -> NaN Division_impossible + +-- long operand checks +ddrmn801 remaindernear 12345678000 100 -> 0 +ddrmn802 remaindernear 1 12345678000 -> 1 +ddrmn803 remaindernear 1234567800 10 -> 0 +ddrmn804 remaindernear 1 1234567800 -> 1 +ddrmn805 remaindernear 1234567890 10 -> 0 +ddrmn806 remaindernear 1 1234567890 -> 1 +ddrmn807 remaindernear 1234567891 10 -> 1 +ddrmn808 remaindernear 1 1234567891 -> 1 +ddrmn809 remaindernear 12345678901 100 -> 1 +ddrmn810 remaindernear 1 12345678901 -> 1 +ddrmn811 remaindernear 1234567896 10 -> -4 +ddrmn812 remaindernear 1 1234567896 -> 1 + +ddrmn821 remaindernear 12345678000 100 -> 0 +ddrmn822 remaindernear 1 12345678000 -> 1 +ddrmn823 remaindernear 1234567800 10 -> 0 +ddrmn824 remaindernear 1 1234567800 -> 1 +ddrmn825 remaindernear 1234567890 10 -> 0 +ddrmn826 remaindernear 1 1234567890 -> 1 +ddrmn827 remaindernear 1234567891 10 -> 1 +ddrmn828 remaindernear 1 1234567891 -> 1 +ddrmn829 remaindernear 12345678901 100 -> 1 +ddrmn830 remaindernear 1 12345678901 -> 1 +ddrmn831 remaindernear 1234567896 10 -> -4 +ddrmn832 remaindernear 1 1234567896 -> 1 + +-- from divideint +ddrmn840 remaindernear 100000000.0 1 -> 0.0 +ddrmn841 remaindernear 100000000.4 1 -> 0.4 +ddrmn842 remaindernear 100000000.5 1 -> 0.5 +ddrmn843 remaindernear 100000000.9 1 -> -0.1 +ddrmn844 remaindernear 100000000.999 1 -> -0.001 +ddrmn850 remaindernear 100000003 5 -> -2 +ddrmn851 remaindernear 10000003 5 -> -2 +ddrmn852 remaindernear 1000003 5 -> -2 +ddrmn853 remaindernear 100003 5 -> -2 +ddrmn854 remaindernear 10003 5 -> -2 +ddrmn855 remaindernear 1003 5 -> -2 +ddrmn856 remaindernear 103 5 -> -2 +ddrmn857 remaindernear 13 5 -> -2 +ddrmn858 remaindernear 1 5 -> 1 + +-- Vladimir's cases 1234567890123456 +ddrmn860 remaindernear 123.0e1 1000000000000000 -> 1230 +ddrmn861 remaindernear 1230 1000000000000000 -> 1230 +ddrmn862 remaindernear 12.3e2 1000000000000000 -> 1230 +ddrmn863 remaindernear 1.23e3 1000000000000000 -> 1230 +ddrmn864 remaindernear 123e1 1000000000000000 -> 1230 +ddrmn870 remaindernear 123e1 1000000000000000 -> 1230 +ddrmn871 remaindernear 123e1 100000000000000 -> 1230 +ddrmn872 remaindernear 123e1 10000000000000 -> 1230 +ddrmn873 remaindernear 123e1 1000000000000 -> 1230 +ddrmn874 remaindernear 123e1 100000000000 -> 1230 +ddrmn875 remaindernear 123e1 10000000000 -> 1230 +ddrmn876 remaindernear 123e1 1000000000 -> 1230 +ddrmn877 remaindernear 123e1 100000000 -> 1230 +ddrmn878 remaindernear 1230 100000000 -> 1230 +ddrmn879 remaindernear 123e1 10000000 -> 1230 +ddrmn880 remaindernear 123e1 1000000 -> 1230 +ddrmn881 remaindernear 123e1 100000 -> 1230 +ddrmn882 remaindernear 123e1 10000 -> 1230 +ddrmn883 remaindernear 123e1 1000 -> 230 +ddrmn884 remaindernear 123e1 100 -> 30 +ddrmn885 remaindernear 123e1 10 -> 0 +ddrmn886 remaindernear 123e1 1 -> 0 + +ddrmn890 remaindernear 123e1 2000000000000000 -> 1230 +ddrmn891 remaindernear 123e1 200000000000000 -> 1230 +ddrmn892 remaindernear 123e1 20000000000000 -> 1230 +ddrmn893 remaindernear 123e1 2000000000000 -> 1230 +ddrmn894 remaindernear 123e1 200000000000 -> 1230 +ddrmn895 remaindernear 123e1 20000000000 -> 1230 +ddrmn896 remaindernear 123e1 2000000000 -> 1230 +ddrmn897 remaindernear 123e1 200000000 -> 1230 +ddrmn899 remaindernear 123e1 20000000 -> 1230 +ddrmn900 remaindernear 123e1 2000000 -> 1230 +ddrmn901 remaindernear 123e1 200000 -> 1230 +ddrmn902 remaindernear 123e1 20000 -> 1230 +ddrmn903 remaindernear 123e1 2000 -> -770 +ddrmn904 remaindernear 123e1 200 -> 30 +ddrmn905 remaindernear 123e1 20 -> -10 +ddrmn906 remaindernear 123e1 2 -> 0 + +ddrmn910 remaindernear 123e1 5000000000000000 -> 1230 +ddrmn911 remaindernear 123e1 500000000000000 -> 1230 +ddrmn912 remaindernear 123e1 50000000000000 -> 1230 +ddrmn913 remaindernear 123e1 5000000000000 -> 1230 +ddrmn914 remaindernear 123e1 500000000000 -> 1230 +ddrmn915 remaindernear 123e1 50000000000 -> 1230 +ddrmn916 remaindernear 123e1 5000000000 -> 1230 +ddrmn917 remaindernear 123e1 500000000 -> 1230 +ddrmn919 remaindernear 123e1 50000000 -> 1230 +ddrmn920 remaindernear 123e1 5000000 -> 1230 +ddrmn921 remaindernear 123e1 500000 -> 1230 +ddrmn922 remaindernear 123e1 50000 -> 1230 +ddrmn923 remaindernear 123e1 5000 -> 1230 +ddrmn924 remaindernear 123e1 500 -> 230 +ddrmn925 remaindernear 123e1 50 -> -20 +ddrmn926 remaindernear 123e1 5 -> 0 + +ddrmn930 remaindernear 123e1 9000000000000000 -> 1230 +ddrmn931 remaindernear 123e1 900000000000000 -> 1230 +ddrmn932 remaindernear 123e1 90000000000000 -> 1230 +ddrmn933 remaindernear 123e1 9000000000000 -> 1230 +ddrmn934 remaindernear 123e1 900000000000 -> 1230 +ddrmn935 remaindernear 123e1 90000000000 -> 1230 +ddrmn936 remaindernear 123e1 9000000000 -> 1230 +ddrmn937 remaindernear 123e1 900000000 -> 1230 +ddrmn939 remaindernear 123e1 90000000 -> 1230 +ddrmn940 remaindernear 123e1 9000000 -> 1230 +ddrmn941 remaindernear 123e1 900000 -> 1230 +ddrmn942 remaindernear 123e1 90000 -> 1230 +ddrmn943 remaindernear 123e1 9000 -> 1230 +ddrmn944 remaindernear 123e1 900 -> 330 +ddrmn945 remaindernear 123e1 90 -> -30 +ddrmn946 remaindernear 123e1 9 -> -3 + +ddrmn950 remaindernear 123e1 1000000000000000 -> 1230 +ddrmn961 remaindernear 123e1 2999999999999999 -> 1230 +ddrmn962 remaindernear 123e1 3999999999999999 -> 1230 +ddrmn963 remaindernear 123e1 4999999999999999 -> 1230 +ddrmn964 remaindernear 123e1 5999999999999999 -> 1230 +ddrmn965 remaindernear 123e1 6999999999999999 -> 1230 +ddrmn966 remaindernear 123e1 7999999999999999 -> 1230 +ddrmn967 remaindernear 123e1 8999999999999999 -> 1230 +ddrmn968 remaindernear 123e1 9999999999999999 -> 1230 +ddrmn969 remaindernear 123e1 9876543210987654 -> 1230 + +ddrmn980 remaindernear 123e1 1000E299 -> 1.23E+3 -- 123E+1 internally + + +-- overflow and underflow tests [from divide] +ddrmn1051 remaindernear 1e+277 1e-311 -> NaN Division_impossible +ddrmn1052 remaindernear 1e+277 -1e-311 -> NaN Division_impossible +ddrmn1053 remaindernear -1e+277 1e-311 -> NaN Division_impossible +ddrmn1054 remaindernear -1e+277 -1e-311 -> NaN Division_impossible +ddrmn1055 remaindernear 1e-277 1e+311 -> 1E-277 +ddrmn1056 remaindernear 1e-277 -1e+311 -> 1E-277 +ddrmn1057 remaindernear -1e-277 1e+311 -> -1E-277 +ddrmn1058 remaindernear -1e-277 -1e+311 -> -1E-277 + +-- destructive subtract +ddrmn1100 remainderNear 1234567890123456 1.000000000000001 -> -0.234567890123455 +ddrmn1101 remainderNear 1234567890123456 1.00000000000001 -> -0.34567890123444 +ddrmn1102 remainderNear 1234567890123456 1.0000000000001 -> -0.4567890123333 +ddrmn1103 remainderNear 1234567890123455 4.000000000000001 -> -1.308641972530864 +ddrmn1104 remainderNear 1234567890123456 4.000000000000001 -> -0.308641972530864 +ddrmn1115 remainderNear 1234567890123456 4.9999999999999 -> 0.6913578024696 +ddrmn1116 remainderNear 1234567890123456 4.99999999999999 -> -1.53086421975308 +ddrmn1117 remainderNear 1234567890123456 4.999999999999999 -> 1.246913578024691 +ddrmn1118 remainderNear 1234567890123456 5.000000000000001 -> 0.753086421975309 +ddrmn1119 remainderNear 1234567890123456 5.00000000000001 -> -1.46913578024691 +ddrmn1110 remainderNear 1234567890123456 5.0000000000001 -> 1.3086421975314 + +-- Null tests +ddrmn1000 remaindernear 10 # -> NaN Invalid_operation +ddrmn1001 remaindernear # 10 -> NaN Invalid_operation + Added: python/branches/release25-maint/Lib/test/decimaltestdata/ddRotate.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/ddRotate.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,262 @@ +------------------------------------------------------------------------ +-- ddRotate.decTest -- rotate a decDouble coefficient left or right -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +precision: 16 +maxExponent: 384 +minExponent: -383 +extended: 1 +clamp: 1 +rounding: half_even + +-- Sanity check +ddrot001 rotate 0 0 -> 0 +ddrot002 rotate 0 2 -> 0 +ddrot003 rotate 1 2 -> 100 +ddrot004 rotate 1 15 -> 1000000000000000 +ddrot005 rotate 1 16 -> 1 +ddrot006 rotate 1 -1 -> 1000000000000000 +ddrot007 rotate 0 -2 -> 0 +ddrot008 rotate 1234567890123456 -1 -> 6123456789012345 +ddrot009 rotate 1234567890123456 -15 -> 2345678901234561 +ddrot010 rotate 1234567890123456 -16 -> 1234567890123456 +ddrot011 rotate 9934567890123456 -15 -> 9345678901234569 +ddrot012 rotate 9934567890123456 -16 -> 9934567890123456 + +-- rhs must be an integer +ddrot015 rotate 1 1.5 -> NaN Invalid_operation +ddrot016 rotate 1 1.0 -> NaN Invalid_operation +ddrot017 rotate 1 0.1 -> NaN Invalid_operation +ddrot018 rotate 1 0.0 -> NaN Invalid_operation +ddrot019 rotate 1 1E+1 -> NaN Invalid_operation +ddrot020 rotate 1 1E+99 -> NaN Invalid_operation +ddrot021 rotate 1 Inf -> NaN Invalid_operation +ddrot022 rotate 1 -Inf -> NaN Invalid_operation +-- and |rhs| <= precision +ddrot025 rotate 1 -1000 -> NaN Invalid_operation +ddrot026 rotate 1 -17 -> NaN Invalid_operation +ddrot027 rotate 1 17 -> NaN Invalid_operation +ddrot028 rotate 1 1000 -> NaN Invalid_operation + +-- full pattern +ddrot030 rotate 1234567890123456 -16 -> 1234567890123456 +ddrot031 rotate 1234567890123456 -15 -> 2345678901234561 +ddrot032 rotate 1234567890123456 -14 -> 3456789012345612 +ddrot033 rotate 1234567890123456 -13 -> 4567890123456123 +ddrot034 rotate 1234567890123456 -12 -> 5678901234561234 +ddrot035 rotate 1234567890123456 -11 -> 6789012345612345 +ddrot036 rotate 1234567890123456 -10 -> 7890123456123456 +ddrot037 rotate 1234567890123456 -9 -> 8901234561234567 +ddrot038 rotate 1234567890123456 -8 -> 9012345612345678 +ddrot039 rotate 1234567890123456 -7 -> 123456123456789 +ddrot040 rotate 1234567890123456 -6 -> 1234561234567890 +ddrot041 rotate 1234567890123456 -5 -> 2345612345678901 +ddrot042 rotate 1234567890123456 -4 -> 3456123456789012 +ddrot043 rotate 1234567890123456 -3 -> 4561234567890123 +ddrot044 rotate 1234567890123456 -2 -> 5612345678901234 +ddrot045 rotate 1234567890123456 -1 -> 6123456789012345 +ddrot046 rotate 1234567890123456 -0 -> 1234567890123456 + +ddrot047 rotate 1234567890123456 +0 -> 1234567890123456 +ddrot048 rotate 1234567890123456 +1 -> 2345678901234561 +ddrot049 rotate 1234567890123456 +2 -> 3456789012345612 +ddrot050 rotate 1234567890123456 +3 -> 4567890123456123 +ddrot051 rotate 1234567890123456 +4 -> 5678901234561234 +ddrot052 rotate 1234567890123456 +5 -> 6789012345612345 +ddrot053 rotate 1234567890123456 +6 -> 7890123456123456 +ddrot054 rotate 1234567890123456 +7 -> 8901234561234567 +ddrot055 rotate 1234567890123456 +8 -> 9012345612345678 +ddrot056 rotate 1234567890123456 +9 -> 123456123456789 +ddrot057 rotate 1234567890123456 +10 -> 1234561234567890 +ddrot058 rotate 1234567890123456 +11 -> 2345612345678901 +ddrot059 rotate 1234567890123456 +12 -> 3456123456789012 +ddrot060 rotate 1234567890123456 +13 -> 4561234567890123 +ddrot061 rotate 1234567890123456 +14 -> 5612345678901234 +ddrot062 rotate 1234567890123456 +15 -> 6123456789012345 +ddrot063 rotate 1234567890123456 +16 -> 1234567890123456 + +-- zeros +ddrot070 rotate 0E-10 +9 -> 0E-10 +ddrot071 rotate 0E-10 -9 -> 0E-10 +ddrot072 rotate 0.000 +9 -> 0.000 +ddrot073 rotate 0.000 -9 -> 0.000 +ddrot074 rotate 0E+10 +9 -> 0E+10 +ddrot075 rotate 0E+10 -9 -> 0E+10 +ddrot076 rotate -0E-10 +9 -> -0E-10 +ddrot077 rotate -0E-10 -9 -> -0E-10 +ddrot078 rotate -0.000 +9 -> -0.000 +ddrot079 rotate -0.000 -9 -> -0.000 +ddrot080 rotate -0E+10 +9 -> -0E+10 +ddrot081 rotate -0E+10 -9 -> -0E+10 + +-- Nmax, Nmin, Ntiny +ddrot141 rotate 9.999999999999999E+384 -1 -> 9.999999999999999E+384 +ddrot142 rotate 9.999999999999999E+384 -15 -> 9.999999999999999E+384 +ddrot143 rotate 9.999999999999999E+384 1 -> 9.999999999999999E+384 +ddrot144 rotate 9.999999999999999E+384 15 -> 9.999999999999999E+384 +ddrot145 rotate 1E-383 -1 -> 1.000000000000000E-368 +ddrot146 rotate 1E-383 -15 -> 1.0E-382 +ddrot147 rotate 1E-383 1 -> 1.0E-382 +ddrot148 rotate 1E-383 15 -> 1.000000000000000E-368 +ddrot151 rotate 1.000000000000000E-383 -1 -> 1.00000000000000E-384 +ddrot152 rotate 1.000000000000000E-383 -15 -> 1E-398 +ddrot153 rotate 1.000000000000000E-383 1 -> 1E-398 +ddrot154 rotate 1.000000000000000E-383 15 -> 1.00000000000000E-384 +ddrot155 rotate 9.000000000000000E-383 -1 -> 9.00000000000000E-384 +ddrot156 rotate 9.000000000000000E-383 -15 -> 9E-398 +ddrot157 rotate 9.000000000000000E-383 1 -> 9E-398 +ddrot158 rotate 9.000000000000000E-383 15 -> 9.00000000000000E-384 +ddrot160 rotate 1E-398 -1 -> 1.000000000000000E-383 +ddrot161 rotate 1E-398 -15 -> 1.0E-397 +ddrot162 rotate 1E-398 1 -> 1.0E-397 +ddrot163 rotate 1E-398 15 -> 1.000000000000000E-383 +-- negatives +ddrot171 rotate -9.999999999999999E+384 -1 -> -9.999999999999999E+384 +ddrot172 rotate -9.999999999999999E+384 -15 -> -9.999999999999999E+384 +ddrot173 rotate -9.999999999999999E+384 1 -> -9.999999999999999E+384 +ddrot174 rotate -9.999999999999999E+384 15 -> -9.999999999999999E+384 +ddrot175 rotate -1E-383 -1 -> -1.000000000000000E-368 +ddrot176 rotate -1E-383 -15 -> -1.0E-382 +ddrot177 rotate -1E-383 1 -> -1.0E-382 +ddrot178 rotate -1E-383 15 -> -1.000000000000000E-368 +ddrot181 rotate -1.000000000000000E-383 -1 -> -1.00000000000000E-384 +ddrot182 rotate -1.000000000000000E-383 -15 -> -1E-398 +ddrot183 rotate -1.000000000000000E-383 1 -> -1E-398 +ddrot184 rotate -1.000000000000000E-383 15 -> -1.00000000000000E-384 +ddrot185 rotate -9.000000000000000E-383 -1 -> -9.00000000000000E-384 +ddrot186 rotate -9.000000000000000E-383 -15 -> -9E-398 +ddrot187 rotate -9.000000000000000E-383 1 -> -9E-398 +ddrot188 rotate -9.000000000000000E-383 15 -> -9.00000000000000E-384 +ddrot190 rotate -1E-398 -1 -> -1.000000000000000E-383 +ddrot191 rotate -1E-398 -15 -> -1.0E-397 +ddrot192 rotate -1E-398 1 -> -1.0E-397 +ddrot193 rotate -1E-398 15 -> -1.000000000000000E-383 + +-- more negatives (of sanities) +ddrot201 rotate -0 0 -> -0 +ddrot202 rotate -0 2 -> -0 +ddrot203 rotate -1 2 -> -100 +ddrot204 rotate -1 15 -> -1000000000000000 +ddrot205 rotate -1 16 -> -1 +ddrot206 rotate -1 -1 -> -1000000000000000 +ddrot207 rotate -0 -2 -> -0 +ddrot208 rotate -1234567890123456 -1 -> -6123456789012345 +ddrot209 rotate -1234567890123456 -15 -> -2345678901234561 +ddrot210 rotate -1234567890123456 -16 -> -1234567890123456 +ddrot211 rotate -9934567890123456 -15 -> -9345678901234569 +ddrot212 rotate -9934567890123456 -16 -> -9934567890123456 + + +-- Specials; NaNs are handled as usual +ddrot781 rotate -Inf -8 -> -Infinity +ddrot782 rotate -Inf -1 -> -Infinity +ddrot783 rotate -Inf -0 -> -Infinity +ddrot784 rotate -Inf 0 -> -Infinity +ddrot785 rotate -Inf 1 -> -Infinity +ddrot786 rotate -Inf 8 -> -Infinity +ddrot787 rotate -1000 -Inf -> NaN Invalid_operation +ddrot788 rotate -Inf -Inf -> NaN Invalid_operation +ddrot789 rotate -1 -Inf -> NaN Invalid_operation +ddrot790 rotate -0 -Inf -> NaN Invalid_operation +ddrot791 rotate 0 -Inf -> NaN Invalid_operation +ddrot792 rotate 1 -Inf -> NaN Invalid_operation +ddrot793 rotate 1000 -Inf -> NaN Invalid_operation +ddrot794 rotate Inf -Inf -> NaN Invalid_operation + +ddrot800 rotate Inf -Inf -> NaN Invalid_operation +ddrot801 rotate Inf -8 -> Infinity +ddrot802 rotate Inf -1 -> Infinity +ddrot803 rotate Inf -0 -> Infinity +ddrot804 rotate Inf 0 -> Infinity +ddrot805 rotate Inf 1 -> Infinity +ddrot806 rotate Inf 8 -> Infinity +ddrot807 rotate Inf Inf -> NaN Invalid_operation +ddrot808 rotate -1000 Inf -> NaN Invalid_operation +ddrot809 rotate -Inf Inf -> NaN Invalid_operation +ddrot810 rotate -1 Inf -> NaN Invalid_operation +ddrot811 rotate -0 Inf -> NaN Invalid_operation +ddrot812 rotate 0 Inf -> NaN Invalid_operation +ddrot813 rotate 1 Inf -> NaN Invalid_operation +ddrot814 rotate 1000 Inf -> NaN Invalid_operation +ddrot815 rotate Inf Inf -> NaN Invalid_operation + +ddrot821 rotate NaN -Inf -> NaN +ddrot822 rotate NaN -1000 -> NaN +ddrot823 rotate NaN -1 -> NaN +ddrot824 rotate NaN -0 -> NaN +ddrot825 rotate NaN 0 -> NaN +ddrot826 rotate NaN 1 -> NaN +ddrot827 rotate NaN 1000 -> NaN +ddrot828 rotate NaN Inf -> NaN +ddrot829 rotate NaN NaN -> NaN +ddrot830 rotate -Inf NaN -> NaN +ddrot831 rotate -1000 NaN -> NaN +ddrot832 rotate -1 NaN -> NaN +ddrot833 rotate -0 NaN -> NaN +ddrot834 rotate 0 NaN -> NaN +ddrot835 rotate 1 NaN -> NaN +ddrot836 rotate 1000 NaN -> NaN +ddrot837 rotate Inf NaN -> NaN + +ddrot841 rotate sNaN -Inf -> NaN Invalid_operation +ddrot842 rotate sNaN -1000 -> NaN Invalid_operation +ddrot843 rotate sNaN -1 -> NaN Invalid_operation +ddrot844 rotate sNaN -0 -> NaN Invalid_operation +ddrot845 rotate sNaN 0 -> NaN Invalid_operation +ddrot846 rotate sNaN 1 -> NaN Invalid_operation +ddrot847 rotate sNaN 1000 -> NaN Invalid_operation +ddrot848 rotate sNaN NaN -> NaN Invalid_operation +ddrot849 rotate sNaN sNaN -> NaN Invalid_operation +ddrot850 rotate NaN sNaN -> NaN Invalid_operation +ddrot851 rotate -Inf sNaN -> NaN Invalid_operation +ddrot852 rotate -1000 sNaN -> NaN Invalid_operation +ddrot853 rotate -1 sNaN -> NaN Invalid_operation +ddrot854 rotate -0 sNaN -> NaN Invalid_operation +ddrot855 rotate 0 sNaN -> NaN Invalid_operation +ddrot856 rotate 1 sNaN -> NaN Invalid_operation +ddrot857 rotate 1000 sNaN -> NaN Invalid_operation +ddrot858 rotate Inf sNaN -> NaN Invalid_operation +ddrot859 rotate NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +ddrot861 rotate NaN1 -Inf -> NaN1 +ddrot862 rotate +NaN2 -1000 -> NaN2 +ddrot863 rotate NaN3 1000 -> NaN3 +ddrot864 rotate NaN4 Inf -> NaN4 +ddrot865 rotate NaN5 +NaN6 -> NaN5 +ddrot866 rotate -Inf NaN7 -> NaN7 +ddrot867 rotate -1000 NaN8 -> NaN8 +ddrot868 rotate 1000 NaN9 -> NaN9 +ddrot869 rotate Inf +NaN10 -> NaN10 +ddrot871 rotate sNaN11 -Inf -> NaN11 Invalid_operation +ddrot872 rotate sNaN12 -1000 -> NaN12 Invalid_operation +ddrot873 rotate sNaN13 1000 -> NaN13 Invalid_operation +ddrot874 rotate sNaN14 NaN17 -> NaN14 Invalid_operation +ddrot875 rotate sNaN15 sNaN18 -> NaN15 Invalid_operation +ddrot876 rotate NaN16 sNaN19 -> NaN19 Invalid_operation +ddrot877 rotate -Inf +sNaN20 -> NaN20 Invalid_operation +ddrot878 rotate -1000 sNaN21 -> NaN21 Invalid_operation +ddrot879 rotate 1000 sNaN22 -> NaN22 Invalid_operation +ddrot880 rotate Inf sNaN23 -> NaN23 Invalid_operation +ddrot881 rotate +NaN25 +sNaN24 -> NaN24 Invalid_operation +ddrot882 rotate -NaN26 NaN28 -> -NaN26 +ddrot883 rotate -sNaN27 sNaN29 -> -NaN27 Invalid_operation +ddrot884 rotate 1000 -NaN30 -> -NaN30 +ddrot885 rotate 1000 -sNaN31 -> -NaN31 Invalid_operation Added: python/branches/release25-maint/Lib/test/decimaltestdata/ddSameQuantum.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/ddSameQuantum.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,389 @@ +------------------------------------------------------------------------ +-- ddSameQuantum.decTest -- check decDouble quantums match -- +-- Copyright (c) IBM Corporation, 2001, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- All operands and results are decDoubles. +precision: 16 +maxExponent: 384 +minExponent: -383 +extended: 1 +clamp: 1 +rounding: half_even + +ddsamq001 samequantum 0 0 -> 1 +ddsamq002 samequantum 0 1 -> 1 +ddsamq003 samequantum 1 0 -> 1 +ddsamq004 samequantum 1 1 -> 1 + +ddsamq011 samequantum 10 1E+1 -> 0 +ddsamq012 samequantum 10E+1 10E+1 -> 1 +ddsamq013 samequantum 100 10E+1 -> 0 +ddsamq014 samequantum 100 1E+2 -> 0 +ddsamq015 samequantum 0.1 1E-2 -> 0 +ddsamq016 samequantum 0.1 1E-1 -> 1 +ddsamq017 samequantum 0.1 1E-0 -> 0 +ddsamq018 samequantum 999 999 -> 1 +ddsamq019 samequantum 999E-1 99.9 -> 1 +ddsamq020 samequantum 111E-1 22.2 -> 1 +ddsamq021 samequantum 111E-1 1234.2 -> 1 + +-- zeros +ddsamq030 samequantum 0.0 1.1 -> 1 +ddsamq031 samequantum 0.0 1.11 -> 0 +ddsamq032 samequantum 0.0 0 -> 0 +ddsamq033 samequantum 0.0 0.0 -> 1 +ddsamq034 samequantum 0.0 0.00 -> 0 +ddsamq035 samequantum 0E+1 0E+0 -> 0 +ddsamq036 samequantum 0E+1 0E+1 -> 1 +ddsamq037 samequantum 0E+1 0E+2 -> 0 +ddsamq038 samequantum 0E-17 0E-16 -> 0 +ddsamq039 samequantum 0E-17 0E-17 -> 1 +ddsamq040 samequantum 0E-17 0E-18 -> 0 +ddsamq041 samequantum 0E-17 0.0E-15 -> 0 +ddsamq042 samequantum 0E-17 0.0E-16 -> 1 +ddsamq043 samequantum 0E-17 0.0E-17 -> 0 +ddsamq044 samequantum -0E-17 0.0E-16 -> 1 +ddsamq045 samequantum 0E-17 -0.0E-17 -> 0 +ddsamq046 samequantum 0E-17 -0.0E-16 -> 1 +ddsamq047 samequantum -0E-17 0.0E-17 -> 0 +ddsamq048 samequantum -0E-17 -0.0E-16 -> 1 +ddsamq049 samequantum -0E-17 -0.0E-17 -> 0 + +-- Nmax, Nmin, Ntiny +ddsamq051 samequantum 9.999999999999999E+384 9.999999999999999E+384 -> 1 +ddsamq052 samequantum 1E-383 1E-383 -> 1 +ddsamq053 samequantum 1.000000000000000E-383 1.000000000000000E-383 -> 1 +ddsamq054 samequantum 1E-398 1E-398 -> 1 +ddsamq055 samequantum 9.999999999999999E+384 9.999999999999999E+384 -> 1 +ddsamq056 samequantum 1E-383 1E-383 -> 1 +ddsamq057 samequantum 1.000000000000000E-383 1.000000000000000E-383 -> 1 +ddsamq058 samequantum 1E-398 1E-398 -> 1 + +ddsamq061 samequantum -1E-398 -1E-398 -> 1 +ddsamq062 samequantum -1.000000000000000E-383 -1.000000000000000E-383 -> 1 +ddsamq063 samequantum -1E-383 -1E-383 -> 1 +ddsamq064 samequantum -9.999999999999999E+384 -9.999999999999999E+384 -> 1 +ddsamq065 samequantum -1E-398 -1E-398 -> 1 +ddsamq066 samequantum -1.000000000000000E-383 -1.000000000000000E-383 -> 1 +ddsamq067 samequantum -1E-383 -1E-383 -> 1 +ddsamq068 samequantum -9.999999999999999E+384 -9.999999999999999E+384 -> 1 + +ddsamq071 samequantum -4E-398 -1E-398 -> 1 +ddsamq072 samequantum -4.000000000000000E-383 -1.000040000000000E-383 -> 1 +ddsamq073 samequantum -4E-383 -1E-383 -> 1 +ddsamq074 samequantum -4.999999999999999E+384 -9.999999999949999E+384 -> 1 +ddsamq075 samequantum -4E-398 -1E-398 -> 1 +ddsamq076 samequantum -4.000000000000000E-383 -1.004000000000000E-383 -> 1 +ddsamq077 samequantum -4E-383 -1E-383 -> 1 +ddsamq078 samequantum -4.999999999999999E+384 -9.949999999999999E+384 -> 1 + +ddsamq081 samequantum -4E-397 -1E-398 -> 0 +ddsamq082 samequantum -4.000000000000000E-383 -1.000040000000000E-336 -> 0 +ddsamq083 samequantum -4E-346 -1E-383 -> 0 +ddsamq084 samequantum -4.999999999999999E+384 -9.999499999999999E+336 -> 0 +ddsamq085 samequantum -4E-397 -1E-398 -> 0 +ddsamq086 samequantum -4.000000000000000E-383 -1.004000000000000E-336 -> 0 +ddsamq087 samequantum -4E-346 -1E-383 -> 0 +ddsamq088 samequantum -4.999999999999999E+384 -9.949999999999999E+336 -> 0 + +-- specials & combinations +ddsamq0110 samequantum -Inf -Inf -> 1 +ddsamq0111 samequantum -Inf Inf -> 1 +ddsamq0112 samequantum -Inf NaN -> 0 +ddsamq0113 samequantum -Inf -7E+3 -> 0 +ddsamq0114 samequantum -Inf -7 -> 0 +ddsamq0115 samequantum -Inf -7E-3 -> 0 +ddsamq0116 samequantum -Inf -0E-3 -> 0 +ddsamq0117 samequantum -Inf -0 -> 0 +ddsamq0118 samequantum -Inf -0E+3 -> 0 +ddsamq0119 samequantum -Inf 0E-3 -> 0 +ddsamq0120 samequantum -Inf 0 -> 0 +ddsamq0121 samequantum -Inf 0E+3 -> 0 +ddsamq0122 samequantum -Inf 7E-3 -> 0 +ddsamq0123 samequantum -Inf 7 -> 0 +ddsamq0124 samequantum -Inf 7E+3 -> 0 +ddsamq0125 samequantum -Inf sNaN -> 0 + +ddsamq0210 samequantum Inf -Inf -> 1 +ddsamq0211 samequantum Inf Inf -> 1 +ddsamq0212 samequantum Inf NaN -> 0 +ddsamq0213 samequantum Inf -7E+3 -> 0 +ddsamq0214 samequantum Inf -7 -> 0 +ddsamq0215 samequantum Inf -7E-3 -> 0 +ddsamq0216 samequantum Inf -0E-3 -> 0 +ddsamq0217 samequantum Inf -0 -> 0 +ddsamq0218 samequantum Inf -0E+3 -> 0 +ddsamq0219 samequantum Inf 0E-3 -> 0 +ddsamq0220 samequantum Inf 0 -> 0 +ddsamq0221 samequantum Inf 0E+3 -> 0 +ddsamq0222 samequantum Inf 7E-3 -> 0 +ddsamq0223 samequantum Inf 7 -> 0 +ddsamq0224 samequantum Inf 7E+3 -> 0 +ddsamq0225 samequantum Inf sNaN -> 0 + +ddsamq0310 samequantum NaN -Inf -> 0 +ddsamq0311 samequantum NaN Inf -> 0 +ddsamq0312 samequantum NaN NaN -> 1 +ddsamq0313 samequantum NaN -7E+3 -> 0 +ddsamq0314 samequantum NaN -7 -> 0 +ddsamq0315 samequantum NaN -7E-3 -> 0 +ddsamq0316 samequantum NaN -0E-3 -> 0 +ddsamq0317 samequantum NaN -0 -> 0 +ddsamq0318 samequantum NaN -0E+3 -> 0 +ddsamq0319 samequantum NaN 0E-3 -> 0 +ddsamq0320 samequantum NaN 0 -> 0 +ddsamq0321 samequantum NaN 0E+3 -> 0 +ddsamq0322 samequantum NaN 7E-3 -> 0 +ddsamq0323 samequantum NaN 7 -> 0 +ddsamq0324 samequantum NaN 7E+3 -> 0 +ddsamq0325 samequantum NaN sNaN -> 1 + +ddsamq0410 samequantum -7E+3 -Inf -> 0 +ddsamq0411 samequantum -7E+3 Inf -> 0 +ddsamq0412 samequantum -7E+3 NaN -> 0 +ddsamq0413 samequantum -7E+3 -7E+3 -> 1 +ddsamq0414 samequantum -7E+3 -7 -> 0 +ddsamq0415 samequantum -7E+3 -7E-3 -> 0 +ddsamq0416 samequantum -7E+3 -0E-3 -> 0 +ddsamq0417 samequantum -7E+3 -0 -> 0 +ddsamq0418 samequantum -7E+3 -0E+3 -> 1 +ddsamq0419 samequantum -7E+3 0E-3 -> 0 +ddsamq0420 samequantum -7E+3 0 -> 0 +ddsamq0421 samequantum -7E+3 0E+3 -> 1 +ddsamq0422 samequantum -7E+3 7E-3 -> 0 +ddsamq0423 samequantum -7E+3 7 -> 0 +ddsamq0424 samequantum -7E+3 7E+3 -> 1 +ddsamq0425 samequantum -7E+3 sNaN -> 0 + +ddsamq0510 samequantum -7 -Inf -> 0 +ddsamq0511 samequantum -7 Inf -> 0 +ddsamq0512 samequantum -7 NaN -> 0 +ddsamq0513 samequantum -7 -7E+3 -> 0 +ddsamq0514 samequantum -7 -7 -> 1 +ddsamq0515 samequantum -7 -7E-3 -> 0 +ddsamq0516 samequantum -7 -0E-3 -> 0 +ddsamq0517 samequantum -7 -0 -> 1 +ddsamq0518 samequantum -7 -0E+3 -> 0 +ddsamq0519 samequantum -7 0E-3 -> 0 +ddsamq0520 samequantum -7 0 -> 1 +ddsamq0521 samequantum -7 0E+3 -> 0 +ddsamq0522 samequantum -7 7E-3 -> 0 +ddsamq0523 samequantum -7 7 -> 1 +ddsamq0524 samequantum -7 7E+3 -> 0 +ddsamq0525 samequantum -7 sNaN -> 0 + +ddsamq0610 samequantum -7E-3 -Inf -> 0 +ddsamq0611 samequantum -7E-3 Inf -> 0 +ddsamq0612 samequantum -7E-3 NaN -> 0 +ddsamq0613 samequantum -7E-3 -7E+3 -> 0 +ddsamq0614 samequantum -7E-3 -7 -> 0 +ddsamq0615 samequantum -7E-3 -7E-3 -> 1 +ddsamq0616 samequantum -7E-3 -0E-3 -> 1 +ddsamq0617 samequantum -7E-3 -0 -> 0 +ddsamq0618 samequantum -7E-3 -0E+3 -> 0 +ddsamq0619 samequantum -7E-3 0E-3 -> 1 +ddsamq0620 samequantum -7E-3 0 -> 0 +ddsamq0621 samequantum -7E-3 0E+3 -> 0 +ddsamq0622 samequantum -7E-3 7E-3 -> 1 +ddsamq0623 samequantum -7E-3 7 -> 0 +ddsamq0624 samequantum -7E-3 7E+3 -> 0 +ddsamq0625 samequantum -7E-3 sNaN -> 0 + +ddsamq0710 samequantum -0E-3 -Inf -> 0 +ddsamq0711 samequantum -0E-3 Inf -> 0 +ddsamq0712 samequantum -0E-3 NaN -> 0 +ddsamq0713 samequantum -0E-3 -7E+3 -> 0 +ddsamq0714 samequantum -0E-3 -7 -> 0 +ddsamq0715 samequantum -0E-3 -7E-3 -> 1 +ddsamq0716 samequantum -0E-3 -0E-3 -> 1 +ddsamq0717 samequantum -0E-3 -0 -> 0 +ddsamq0718 samequantum -0E-3 -0E+3 -> 0 +ddsamq0719 samequantum -0E-3 0E-3 -> 1 +ddsamq0720 samequantum -0E-3 0 -> 0 +ddsamq0721 samequantum -0E-3 0E+3 -> 0 +ddsamq0722 samequantum -0E-3 7E-3 -> 1 +ddsamq0723 samequantum -0E-3 7 -> 0 +ddsamq0724 samequantum -0E-3 7E+3 -> 0 +ddsamq0725 samequantum -0E-3 sNaN -> 0 + +ddsamq0810 samequantum -0 -Inf -> 0 +ddsamq0811 samequantum -0 Inf -> 0 +ddsamq0812 samequantum -0 NaN -> 0 +ddsamq0813 samequantum -0 -7E+3 -> 0 +ddsamq0814 samequantum -0 -7 -> 1 +ddsamq0815 samequantum -0 -7E-3 -> 0 +ddsamq0816 samequantum -0 -0E-3 -> 0 +ddsamq0817 samequantum -0 -0 -> 1 +ddsamq0818 samequantum -0 -0E+3 -> 0 +ddsamq0819 samequantum -0 0E-3 -> 0 +ddsamq0820 samequantum -0 0 -> 1 +ddsamq0821 samequantum -0 0E+3 -> 0 +ddsamq0822 samequantum -0 7E-3 -> 0 +ddsamq0823 samequantum -0 7 -> 1 +ddsamq0824 samequantum -0 7E+3 -> 0 +ddsamq0825 samequantum -0 sNaN -> 0 + +ddsamq0910 samequantum -0E+3 -Inf -> 0 +ddsamq0911 samequantum -0E+3 Inf -> 0 +ddsamq0912 samequantum -0E+3 NaN -> 0 +ddsamq0913 samequantum -0E+3 -7E+3 -> 1 +ddsamq0914 samequantum -0E+3 -7 -> 0 +ddsamq0915 samequantum -0E+3 -7E-3 -> 0 +ddsamq0916 samequantum -0E+3 -0E-3 -> 0 +ddsamq0917 samequantum -0E+3 -0 -> 0 +ddsamq0918 samequantum -0E+3 -0E+3 -> 1 +ddsamq0919 samequantum -0E+3 0E-3 -> 0 +ddsamq0920 samequantum -0E+3 0 -> 0 +ddsamq0921 samequantum -0E+3 0E+3 -> 1 +ddsamq0922 samequantum -0E+3 7E-3 -> 0 +ddsamq0923 samequantum -0E+3 7 -> 0 +ddsamq0924 samequantum -0E+3 7E+3 -> 1 +ddsamq0925 samequantum -0E+3 sNaN -> 0 + +ddsamq1110 samequantum 0E-3 -Inf -> 0 +ddsamq1111 samequantum 0E-3 Inf -> 0 +ddsamq1112 samequantum 0E-3 NaN -> 0 +ddsamq1113 samequantum 0E-3 -7E+3 -> 0 +ddsamq1114 samequantum 0E-3 -7 -> 0 +ddsamq1115 samequantum 0E-3 -7E-3 -> 1 +ddsamq1116 samequantum 0E-3 -0E-3 -> 1 +ddsamq1117 samequantum 0E-3 -0 -> 0 +ddsamq1118 samequantum 0E-3 -0E+3 -> 0 +ddsamq1119 samequantum 0E-3 0E-3 -> 1 +ddsamq1120 samequantum 0E-3 0 -> 0 +ddsamq1121 samequantum 0E-3 0E+3 -> 0 +ddsamq1122 samequantum 0E-3 7E-3 -> 1 +ddsamq1123 samequantum 0E-3 7 -> 0 +ddsamq1124 samequantum 0E-3 7E+3 -> 0 +ddsamq1125 samequantum 0E-3 sNaN -> 0 + +ddsamq1210 samequantum 0 -Inf -> 0 +ddsamq1211 samequantum 0 Inf -> 0 +ddsamq1212 samequantum 0 NaN -> 0 +ddsamq1213 samequantum 0 -7E+3 -> 0 +ddsamq1214 samequantum 0 -7 -> 1 +ddsamq1215 samequantum 0 -7E-3 -> 0 +ddsamq1216 samequantum 0 -0E-3 -> 0 +ddsamq1217 samequantum 0 -0 -> 1 +ddsamq1218 samequantum 0 -0E+3 -> 0 +ddsamq1219 samequantum 0 0E-3 -> 0 +ddsamq1220 samequantum 0 0 -> 1 +ddsamq1221 samequantum 0 0E+3 -> 0 +ddsamq1222 samequantum 0 7E-3 -> 0 +ddsamq1223 samequantum 0 7 -> 1 +ddsamq1224 samequantum 0 7E+3 -> 0 +ddsamq1225 samequantum 0 sNaN -> 0 + +ddsamq1310 samequantum 0E+3 -Inf -> 0 +ddsamq1311 samequantum 0E+3 Inf -> 0 +ddsamq1312 samequantum 0E+3 NaN -> 0 +ddsamq1313 samequantum 0E+3 -7E+3 -> 1 +ddsamq1314 samequantum 0E+3 -7 -> 0 +ddsamq1315 samequantum 0E+3 -7E-3 -> 0 +ddsamq1316 samequantum 0E+3 -0E-3 -> 0 +ddsamq1317 samequantum 0E+3 -0 -> 0 +ddsamq1318 samequantum 0E+3 -0E+3 -> 1 +ddsamq1319 samequantum 0E+3 0E-3 -> 0 +ddsamq1320 samequantum 0E+3 0 -> 0 +ddsamq1321 samequantum 0E+3 0E+3 -> 1 +ddsamq1322 samequantum 0E+3 7E-3 -> 0 +ddsamq1323 samequantum 0E+3 7 -> 0 +ddsamq1324 samequantum 0E+3 7E+3 -> 1 +ddsamq1325 samequantum 0E+3 sNaN -> 0 + +ddsamq1410 samequantum 7E-3 -Inf -> 0 +ddsamq1411 samequantum 7E-3 Inf -> 0 +ddsamq1412 samequantum 7E-3 NaN -> 0 +ddsamq1413 samequantum 7E-3 -7E+3 -> 0 +ddsamq1414 samequantum 7E-3 -7 -> 0 +ddsamq1415 samequantum 7E-3 -7E-3 -> 1 +ddsamq1416 samequantum 7E-3 -0E-3 -> 1 +ddsamq1417 samequantum 7E-3 -0 -> 0 +ddsamq1418 samequantum 7E-3 -0E+3 -> 0 +ddsamq1419 samequantum 7E-3 0E-3 -> 1 +ddsamq1420 samequantum 7E-3 0 -> 0 +ddsamq1421 samequantum 7E-3 0E+3 -> 0 +ddsamq1422 samequantum 7E-3 7E-3 -> 1 +ddsamq1423 samequantum 7E-3 7 -> 0 +ddsamq1424 samequantum 7E-3 7E+3 -> 0 +ddsamq1425 samequantum 7E-3 sNaN -> 0 + +ddsamq1510 samequantum 7 -Inf -> 0 +ddsamq1511 samequantum 7 Inf -> 0 +ddsamq1512 samequantum 7 NaN -> 0 +ddsamq1513 samequantum 7 -7E+3 -> 0 +ddsamq1514 samequantum 7 -7 -> 1 +ddsamq1515 samequantum 7 -7E-3 -> 0 +ddsamq1516 samequantum 7 -0E-3 -> 0 +ddsamq1517 samequantum 7 -0 -> 1 +ddsamq1518 samequantum 7 -0E+3 -> 0 +ddsamq1519 samequantum 7 0E-3 -> 0 +ddsamq1520 samequantum 7 0 -> 1 +ddsamq1521 samequantum 7 0E+3 -> 0 +ddsamq1522 samequantum 7 7E-3 -> 0 +ddsamq1523 samequantum 7 7 -> 1 +ddsamq1524 samequantum 7 7E+3 -> 0 +ddsamq1525 samequantum 7 sNaN -> 0 + +ddsamq1610 samequantum 7E+3 -Inf -> 0 +ddsamq1611 samequantum 7E+3 Inf -> 0 +ddsamq1612 samequantum 7E+3 NaN -> 0 +ddsamq1613 samequantum 7E+3 -7E+3 -> 1 +ddsamq1614 samequantum 7E+3 -7 -> 0 +ddsamq1615 samequantum 7E+3 -7E-3 -> 0 +ddsamq1616 samequantum 7E+3 -0E-3 -> 0 +ddsamq1617 samequantum 7E+3 -0 -> 0 +ddsamq1618 samequantum 7E+3 -0E+3 -> 1 +ddsamq1619 samequantum 7E+3 0E-3 -> 0 +ddsamq1620 samequantum 7E+3 0 -> 0 +ddsamq1621 samequantum 7E+3 0E+3 -> 1 +ddsamq1622 samequantum 7E+3 7E-3 -> 0 +ddsamq1623 samequantum 7E+3 7 -> 0 +ddsamq1624 samequantum 7E+3 7E+3 -> 1 +ddsamq1625 samequantum 7E+3 sNaN -> 0 + +ddsamq1710 samequantum sNaN -Inf -> 0 +ddsamq1711 samequantum sNaN Inf -> 0 +ddsamq1712 samequantum sNaN NaN -> 1 +ddsamq1713 samequantum sNaN -7E+3 -> 0 +ddsamq1714 samequantum sNaN -7 -> 0 +ddsamq1715 samequantum sNaN -7E-3 -> 0 +ddsamq1716 samequantum sNaN -0E-3 -> 0 +ddsamq1717 samequantum sNaN -0 -> 0 +ddsamq1718 samequantum sNaN -0E+3 -> 0 +ddsamq1719 samequantum sNaN 0E-3 -> 0 +ddsamq1720 samequantum sNaN 0 -> 0 +ddsamq1721 samequantum sNaN 0E+3 -> 0 +ddsamq1722 samequantum sNaN 7E-3 -> 0 +ddsamq1723 samequantum sNaN 7 -> 0 +ddsamq1724 samequantum sNaN 7E+3 -> 0 +ddsamq1725 samequantum sNaN sNaN -> 1 +-- noisy NaNs +ddsamq1730 samequantum sNaN3 sNaN3 -> 1 +ddsamq1731 samequantum sNaN3 sNaN4 -> 1 +ddsamq1732 samequantum NaN3 NaN3 -> 1 +ddsamq1733 samequantum NaN3 NaN4 -> 1 +ddsamq1734 samequantum sNaN3 3 -> 0 +ddsamq1735 samequantum NaN3 3 -> 0 +ddsamq1736 samequantum 4 sNaN4 -> 0 +ddsamq1737 samequantum 3 NaN3 -> 0 +ddsamq1738 samequantum Inf sNaN4 -> 0 +ddsamq1739 samequantum -Inf NaN3 -> 0 + Added: python/branches/release25-maint/Lib/test/decimaltestdata/ddScaleB.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/ddScaleB.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,243 @@ +------------------------------------------------------------------------ +-- ddScalebB.decTest -- scale a decDouble by powers of 10 -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +precision: 16 +maxExponent: 384 +minExponent: -383 +extended: 1 +clamp: 1 +rounding: half_even + +-- Max |rhs| is 2*(384+16) = 800 + +-- Sanity checks +ddscb001 scaleb 7.50 10 -> 7.50E+10 +ddscb002 scaleb 7.50 3 -> 7.50E+3 +ddscb003 scaleb 7.50 2 -> 750 +ddscb004 scaleb 7.50 1 -> 75.0 +ddscb005 scaleb 7.50 0 -> 7.50 +ddscb006 scaleb 7.50 -1 -> 0.750 +ddscb007 scaleb 7.50 -2 -> 0.0750 +ddscb008 scaleb 7.50 -10 -> 7.50E-10 +ddscb009 scaleb -7.50 3 -> -7.50E+3 +ddscb010 scaleb -7.50 2 -> -750 +ddscb011 scaleb -7.50 1 -> -75.0 +ddscb012 scaleb -7.50 0 -> -7.50 +ddscb013 scaleb -7.50 -1 -> -0.750 + +-- Infinities +ddscb014 scaleb Infinity 1 -> Infinity +ddscb015 scaleb -Infinity 2 -> -Infinity +ddscb016 scaleb Infinity -1 -> Infinity +ddscb017 scaleb -Infinity -2 -> -Infinity + +-- Next two are somewhat undefined in 754r; treat as non-integer +ddscb018 scaleb 10 Infinity -> NaN Invalid_operation +ddscb019 scaleb 10 -Infinity -> NaN Invalid_operation + +-- NaNs are undefined in 754r; assume usual processing +-- NaNs, 0 payload +ddscb021 scaleb NaN 1 -> NaN +ddscb022 scaleb -NaN -1 -> -NaN +ddscb023 scaleb sNaN 1 -> NaN Invalid_operation +ddscb024 scaleb -sNaN 1 -> -NaN Invalid_operation +ddscb025 scaleb 4 NaN -> NaN +ddscb026 scaleb -Inf -NaN -> -NaN +ddscb027 scaleb 4 sNaN -> NaN Invalid_operation +ddscb028 scaleb Inf -sNaN -> -NaN Invalid_operation + +-- non-integer RHS +ddscb030 scaleb 1.23 1 -> 12.3 +ddscb031 scaleb 1.23 1.00 -> NaN Invalid_operation +ddscb032 scaleb 1.23 1.1 -> NaN Invalid_operation +ddscb033 scaleb 1.23 1.01 -> NaN Invalid_operation +ddscb034 scaleb 1.23 0.01 -> NaN Invalid_operation +ddscb035 scaleb 1.23 0.11 -> NaN Invalid_operation +ddscb036 scaleb 1.23 0.999999999 -> NaN Invalid_operation +ddscb037 scaleb 1.23 -1 -> 0.123 +ddscb038 scaleb 1.23 -1.00 -> NaN Invalid_operation +ddscb039 scaleb 1.23 -1.1 -> NaN Invalid_operation +ddscb040 scaleb 1.23 -1.01 -> NaN Invalid_operation +ddscb041 scaleb 1.23 -0.01 -> NaN Invalid_operation +ddscb042 scaleb 1.23 -0.11 -> NaN Invalid_operation +ddscb043 scaleb 1.23 -0.999999999 -> NaN Invalid_operation +ddscb044 scaleb 1.23 0.1 -> NaN Invalid_operation +ddscb045 scaleb 1.23 1E+1 -> NaN Invalid_operation +ddscb046 scaleb 1.23 1.1234E+6 -> NaN Invalid_operation +ddscb047 scaleb 1.23 1.123E+4 -> NaN Invalid_operation + +-- out-of range RHS +ddscb120 scaleb 1.23 799 -> Infinity Overflow Inexact Rounded +ddscb121 scaleb 1.23 800 -> Infinity Overflow Inexact Rounded +ddscb122 scaleb 1.23 801 -> NaN Invalid_operation +ddscb123 scaleb 1.23 802 -> NaN Invalid_operation +ddscb124 scaleb 1.23 -799 -> 0E-398 Underflow Subnormal Inexact Rounded Clamped +ddscb125 scaleb 1.23 -800 -> 0E-398 Underflow Subnormal Inexact Rounded Clamped +ddscb126 scaleb 1.23 -801 -> NaN Invalid_operation +ddscb127 scaleb 1.23 -802 -> NaN Invalid_operation + +-- NaNs, non-0 payload +-- propagating NaNs +ddscb861 scaleb NaN01 -Inf -> NaN1 +ddscb862 scaleb -NaN02 -1000 -> -NaN2 +ddscb863 scaleb NaN03 1000 -> NaN3 +ddscb864 scaleb NaN04 Inf -> NaN4 +ddscb865 scaleb NaN05 NaN61 -> NaN5 +ddscb866 scaleb -Inf -NaN71 -> -NaN71 +ddscb867 scaleb -1000 NaN81 -> NaN81 +ddscb868 scaleb 1000 NaN91 -> NaN91 +ddscb869 scaleb Inf NaN101 -> NaN101 +ddscb871 scaleb sNaN011 -Inf -> NaN11 Invalid_operation +ddscb872 scaleb sNaN012 -1000 -> NaN12 Invalid_operation +ddscb873 scaleb -sNaN013 1000 -> -NaN13 Invalid_operation +ddscb874 scaleb sNaN014 NaN171 -> NaN14 Invalid_operation +ddscb875 scaleb sNaN015 sNaN181 -> NaN15 Invalid_operation +ddscb876 scaleb NaN016 sNaN191 -> NaN191 Invalid_operation +ddscb877 scaleb -Inf sNaN201 -> NaN201 Invalid_operation +ddscb878 scaleb -1000 sNaN211 -> NaN211 Invalid_operation +ddscb879 scaleb 1000 -sNaN221 -> -NaN221 Invalid_operation +ddscb880 scaleb Inf sNaN231 -> NaN231 Invalid_operation +ddscb881 scaleb NaN025 sNaN241 -> NaN241 Invalid_operation + +-- finites +ddscb051 scaleb 7 -2 -> 0.07 +ddscb052 scaleb -7 -2 -> -0.07 +ddscb053 scaleb 75 -2 -> 0.75 +ddscb054 scaleb -75 -2 -> -0.75 +ddscb055 scaleb 7.50 -2 -> 0.0750 +ddscb056 scaleb -7.50 -2 -> -0.0750 +ddscb057 scaleb 7.500 -2 -> 0.07500 +ddscb058 scaleb -7.500 -2 -> -0.07500 +ddscb061 scaleb 7 -1 -> 0.7 +ddscb062 scaleb -7 -1 -> -0.7 +ddscb063 scaleb 75 -1 -> 7.5 +ddscb064 scaleb -75 -1 -> -7.5 +ddscb065 scaleb 7.50 -1 -> 0.750 +ddscb066 scaleb -7.50 -1 -> -0.750 +ddscb067 scaleb 7.500 -1 -> 0.7500 +ddscb068 scaleb -7.500 -1 -> -0.7500 +ddscb071 scaleb 7 0 -> 7 +ddscb072 scaleb -7 0 -> -7 +ddscb073 scaleb 75 0 -> 75 +ddscb074 scaleb -75 0 -> -75 +ddscb075 scaleb 7.50 0 -> 7.50 +ddscb076 scaleb -7.50 0 -> -7.50 +ddscb077 scaleb 7.500 0 -> 7.500 +ddscb078 scaleb -7.500 0 -> -7.500 +ddscb081 scaleb 7 1 -> 7E+1 +ddscb082 scaleb -7 1 -> -7E+1 +ddscb083 scaleb 75 1 -> 7.5E+2 +ddscb084 scaleb -75 1 -> -7.5E+2 +ddscb085 scaleb 7.50 1 -> 75.0 +ddscb086 scaleb -7.50 1 -> -75.0 +ddscb087 scaleb 7.500 1 -> 75.00 +ddscb088 scaleb -7.500 1 -> -75.00 +ddscb091 scaleb 7 2 -> 7E+2 +ddscb092 scaleb -7 2 -> -7E+2 +ddscb093 scaleb 75 2 -> 7.5E+3 +ddscb094 scaleb -75 2 -> -7.5E+3 +ddscb095 scaleb 7.50 2 -> 750 +ddscb096 scaleb -7.50 2 -> -750 +ddscb097 scaleb 7.500 2 -> 750.0 +ddscb098 scaleb -7.500 2 -> -750.0 + +-- zeros +ddscb111 scaleb 0 1 -> 0E+1 +ddscb112 scaleb -0 2 -> -0E+2 +ddscb113 scaleb 0E+4 3 -> 0E+7 +ddscb114 scaleb -0E+4 4 -> -0E+8 +ddscb115 scaleb 0.0000 5 -> 0E+1 +ddscb116 scaleb -0.0000 6 -> -0E+2 +ddscb117 scaleb 0E-141 7 -> 0E-134 +ddscb118 scaleb -0E-141 8 -> -0E-133 + +-- Nmax, Nmin, Ntiny +ddscb132 scaleb 9.999999999999999E+384 +384 -> Infinity Overflow Inexact Rounded +ddscb133 scaleb 9.999999999999999E+384 +10 -> Infinity Overflow Inexact Rounded +ddscb134 scaleb 9.999999999999999E+384 +1 -> Infinity Overflow Inexact Rounded +ddscb135 scaleb 9.999999999999999E+384 0 -> 9.999999999999999E+384 +ddscb136 scaleb 9.999999999999999E+384 -1 -> 9.999999999999999E+383 +ddscb137 scaleb 1E-383 +1 -> 1E-382 +ddscb138 scaleb 1E-383 -0 -> 1E-383 +ddscb139 scaleb 1E-383 -1 -> 1E-384 Subnormal +ddscb140 scaleb 1.000000000000000E-383 +1 -> 1.000000000000000E-382 +ddscb141 scaleb 1.000000000000000E-383 0 -> 1.000000000000000E-383 +ddscb142 scaleb 1.000000000000000E-383 -1 -> 1.00000000000000E-384 Subnormal Rounded +ddscb143 scaleb 1E-398 +1 -> 1E-397 Subnormal +ddscb144 scaleb 1E-398 -0 -> 1E-398 Subnormal +ddscb145 scaleb 1E-398 -1 -> 0E-398 Underflow Subnormal Inexact Rounded Clamped + +ddscb150 scaleb -1E-398 +1 -> -1E-397 Subnormal +ddscb151 scaleb -1E-398 -0 -> -1E-398 Subnormal +ddscb152 scaleb -1E-398 -1 -> -0E-398 Underflow Subnormal Inexact Rounded Clamped +ddscb153 scaleb -1.000000000000000E-383 +1 -> -1.000000000000000E-382 +ddscb154 scaleb -1.000000000000000E-383 +0 -> -1.000000000000000E-383 +ddscb155 scaleb -1.000000000000000E-383 -1 -> -1.00000000000000E-384 Subnormal Rounded +ddscb156 scaleb -1E-383 +1 -> -1E-382 +ddscb157 scaleb -1E-383 -0 -> -1E-383 +ddscb158 scaleb -1E-383 -1 -> -1E-384 Subnormal +ddscb159 scaleb -9.999999999999999E+384 +1 -> -Infinity Overflow Inexact Rounded +ddscb160 scaleb -9.999999999999999E+384 +0 -> -9.999999999999999E+384 +ddscb161 scaleb -9.999999999999999E+384 -1 -> -9.999999999999999E+383 +ddscb162 scaleb -9E+384 +1 -> -Infinity Overflow Inexact Rounded +ddscb163 scaleb -1E+384 +1 -> -Infinity Overflow Inexact Rounded + +-- some Origami +-- (these check that overflow is being done correctly) +ddscb171 scaleb 1000E+365 +1 -> 1.000E+369 +ddscb172 scaleb 1000E+366 +1 -> 1.000E+370 +ddscb173 scaleb 1000E+367 +1 -> 1.000E+371 +ddscb174 scaleb 1000E+368 +1 -> 1.000E+372 +ddscb175 scaleb 1000E+369 +1 -> 1.0000E+373 Clamped +ddscb176 scaleb 1000E+370 +1 -> 1.00000E+374 Clamped +ddscb177 scaleb 1000E+371 +1 -> 1.000000E+375 Clamped +ddscb178 scaleb 1000E+372 +1 -> 1.0000000E+376 Clamped +ddscb179 scaleb 1000E+373 +1 -> 1.00000000E+377 Clamped +ddscb180 scaleb 1000E+374 +1 -> 1.000000000E+378 Clamped +ddscb181 scaleb 1000E+375 +1 -> 1.0000000000E+379 Clamped +ddscb182 scaleb 1000E+376 +1 -> 1.00000000000E+380 Clamped +ddscb183 scaleb 1000E+377 +1 -> 1.000000000000E+381 Clamped +ddscb184 scaleb 1000E+378 +1 -> 1.0000000000000E+382 Clamped +ddscb185 scaleb 1000E+379 +1 -> 1.00000000000000E+383 Clamped +ddscb186 scaleb 1000E+380 +1 -> 1.000000000000000E+384 Clamped +ddscb187 scaleb 1000E+381 +1 -> Infinity Overflow Inexact Rounded + +-- and a few more subnormal truncations +-- (these check that underflow is being done correctly) +ddscb201 scaleb 1.000000000000000E-383 0 -> 1.000000000000000E-383 +ddscb202 scaleb 1.000000000000000E-383 -1 -> 1.00000000000000E-384 Subnormal Rounded +ddscb203 scaleb 1.000000000000000E-383 -2 -> 1.0000000000000E-385 Subnormal Rounded +ddscb204 scaleb 1.000000000000000E-383 -3 -> 1.000000000000E-386 Subnormal Rounded +ddscb205 scaleb 1.000000000000000E-383 -4 -> 1.00000000000E-387 Subnormal Rounded +ddscb206 scaleb 1.000000000000000E-383 -5 -> 1.0000000000E-388 Subnormal Rounded +ddscb207 scaleb 1.000000000000000E-383 -6 -> 1.000000000E-389 Subnormal Rounded +ddscb208 scaleb 1.000000000000000E-383 -7 -> 1.00000000E-390 Subnormal Rounded +ddscb209 scaleb 1.000000000000000E-383 -8 -> 1.0000000E-391 Subnormal Rounded +ddscb210 scaleb 1.000000000000000E-383 -9 -> 1.000000E-392 Subnormal Rounded +ddscb211 scaleb 1.000000000000000E-383 -10 -> 1.00000E-393 Subnormal Rounded +ddscb212 scaleb 1.000000000000000E-383 -11 -> 1.0000E-394 Subnormal Rounded +ddscb213 scaleb 1.000000000000000E-383 -12 -> 1.000E-395 Subnormal Rounded +ddscb214 scaleb 1.000000000000000E-383 -13 -> 1.00E-396 Subnormal Rounded +ddscb215 scaleb 1.000000000000000E-383 -14 -> 1.0E-397 Subnormal Rounded +ddscb216 scaleb 1.000000000000000E-383 -15 -> 1E-398 Subnormal Rounded +ddscb217 scaleb 1.000000000000000E-383 -16 -> 0E-398 Underflow Subnormal Inexact Rounded Clamped +ddscb218 scaleb 1.000000000000000E-383 -17 -> 0E-398 Underflow Subnormal Inexact Rounded Clamped + Added: python/branches/release25-maint/Lib/test/decimaltestdata/ddShift.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/ddShift.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,262 @@ +------------------------------------------------------------------------ +-- ddShift.decTest -- shift decDouble coefficient left or right -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +precision: 16 +maxExponent: 384 +minExponent: -383 +extended: 1 +clamp: 1 +rounding: half_even + +-- Sanity check +ddshi001 shift 0 0 -> 0 +ddshi002 shift 0 2 -> 0 +ddshi003 shift 1 2 -> 100 +ddshi004 shift 1 15 -> 1000000000000000 +ddshi005 shift 1 16 -> 0 +ddshi006 shift 1 -1 -> 0 +ddshi007 shift 0 -2 -> 0 +ddshi008 shift 1234567890123456 -1 -> 123456789012345 +ddshi009 shift 1234567890123456 -15 -> 1 +ddshi010 shift 1234567890123456 -16 -> 0 +ddshi011 shift 9934567890123456 -15 -> 9 +ddshi012 shift 9934567890123456 -16 -> 0 + +-- rhs must be an integer +ddshi015 shift 1 1.5 -> NaN Invalid_operation +ddshi016 shift 1 1.0 -> NaN Invalid_operation +ddshi017 shift 1 0.1 -> NaN Invalid_operation +ddshi018 shift 1 0.0 -> NaN Invalid_operation +ddshi019 shift 1 1E+1 -> NaN Invalid_operation +ddshi020 shift 1 1E+99 -> NaN Invalid_operation +ddshi021 shift 1 Inf -> NaN Invalid_operation +ddshi022 shift 1 -Inf -> NaN Invalid_operation +-- and |rhs| <= precision +ddshi025 shift 1 -1000 -> NaN Invalid_operation +ddshi026 shift 1 -17 -> NaN Invalid_operation +ddshi027 shift 1 17 -> NaN Invalid_operation +ddshi028 shift 1 1000 -> NaN Invalid_operation + +-- full shifting pattern +ddshi030 shift 1234567890123456 -16 -> 0 +ddshi031 shift 1234567890123456 -15 -> 1 +ddshi032 shift 1234567890123456 -14 -> 12 +ddshi033 shift 1234567890123456 -13 -> 123 +ddshi034 shift 1234567890123456 -12 -> 1234 +ddshi035 shift 1234567890123456 -11 -> 12345 +ddshi036 shift 1234567890123456 -10 -> 123456 +ddshi037 shift 1234567890123456 -9 -> 1234567 +ddshi038 shift 1234567890123456 -8 -> 12345678 +ddshi039 shift 1234567890123456 -7 -> 123456789 +ddshi040 shift 1234567890123456 -6 -> 1234567890 +ddshi041 shift 1234567890123456 -5 -> 12345678901 +ddshi042 shift 1234567890123456 -4 -> 123456789012 +ddshi043 shift 1234567890123456 -3 -> 1234567890123 +ddshi044 shift 1234567890123456 -2 -> 12345678901234 +ddshi045 shift 1234567890123456 -1 -> 123456789012345 +ddshi046 shift 1234567890123456 -0 -> 1234567890123456 + +ddshi047 shift 1234567890123456 +0 -> 1234567890123456 +ddshi048 shift 1234567890123456 +1 -> 2345678901234560 +ddshi049 shift 1234567890123456 +2 -> 3456789012345600 +ddshi050 shift 1234567890123456 +3 -> 4567890123456000 +ddshi051 shift 1234567890123456 +4 -> 5678901234560000 +ddshi052 shift 1234567890123456 +5 -> 6789012345600000 +ddshi053 shift 1234567890123456 +6 -> 7890123456000000 +ddshi054 shift 1234567890123456 +7 -> 8901234560000000 +ddshi055 shift 1234567890123456 +8 -> 9012345600000000 +ddshi056 shift 1234567890123456 +9 -> 123456000000000 +ddshi057 shift 1234567890123456 +10 -> 1234560000000000 +ddshi058 shift 1234567890123456 +11 -> 2345600000000000 +ddshi059 shift 1234567890123456 +12 -> 3456000000000000 +ddshi060 shift 1234567890123456 +13 -> 4560000000000000 +ddshi061 shift 1234567890123456 +14 -> 5600000000000000 +ddshi062 shift 1234567890123456 +15 -> 6000000000000000 +ddshi063 shift 1234567890123456 +16 -> 0 + +-- zeros +ddshi070 shift 0E-10 +9 -> 0E-10 +ddshi071 shift 0E-10 -9 -> 0E-10 +ddshi072 shift 0.000 +9 -> 0.000 +ddshi073 shift 0.000 -9 -> 0.000 +ddshi074 shift 0E+10 +9 -> 0E+10 +ddshi075 shift 0E+10 -9 -> 0E+10 +ddshi076 shift -0E-10 +9 -> -0E-10 +ddshi077 shift -0E-10 -9 -> -0E-10 +ddshi078 shift -0.000 +9 -> -0.000 +ddshi079 shift -0.000 -9 -> -0.000 +ddshi080 shift -0E+10 +9 -> -0E+10 +ddshi081 shift -0E+10 -9 -> -0E+10 + +-- Nmax, Nmin, Ntiny +ddshi141 shift 9.999999999999999E+384 -1 -> 9.99999999999999E+383 +ddshi142 shift 9.999999999999999E+384 -15 -> 9E+369 +ddshi143 shift 9.999999999999999E+384 1 -> 9.999999999999990E+384 +ddshi144 shift 9.999999999999999E+384 15 -> 9.000000000000000E+384 +ddshi145 shift 1E-383 -1 -> 0E-383 +ddshi146 shift 1E-383 -15 -> 0E-383 +ddshi147 shift 1E-383 1 -> 1.0E-382 +ddshi148 shift 1E-383 15 -> 1.000000000000000E-368 +ddshi151 shift 1.000000000000000E-383 -1 -> 1.00000000000000E-384 +ddshi152 shift 1.000000000000000E-383 -15 -> 1E-398 +ddshi153 shift 1.000000000000000E-383 1 -> 0E-398 +ddshi154 shift 1.000000000000000E-383 15 -> 0E-398 +ddshi155 shift 9.000000000000000E-383 -1 -> 9.00000000000000E-384 +ddshi156 shift 9.000000000000000E-383 -15 -> 9E-398 +ddshi157 shift 9.000000000000000E-383 1 -> 0E-398 +ddshi158 shift 9.000000000000000E-383 15 -> 0E-398 +ddshi160 shift 1E-398 -1 -> 0E-398 +ddshi161 shift 1E-398 -15 -> 0E-398 +ddshi162 shift 1E-398 1 -> 1.0E-397 +ddshi163 shift 1E-398 15 -> 1.000000000000000E-383 +-- negatives +ddshi171 shift -9.999999999999999E+384 -1 -> -9.99999999999999E+383 +ddshi172 shift -9.999999999999999E+384 -15 -> -9E+369 +ddshi173 shift -9.999999999999999E+384 1 -> -9.999999999999990E+384 +ddshi174 shift -9.999999999999999E+384 15 -> -9.000000000000000E+384 +ddshi175 shift -1E-383 -1 -> -0E-383 +ddshi176 shift -1E-383 -15 -> -0E-383 +ddshi177 shift -1E-383 1 -> -1.0E-382 +ddshi178 shift -1E-383 15 -> -1.000000000000000E-368 +ddshi181 shift -1.000000000000000E-383 -1 -> -1.00000000000000E-384 +ddshi182 shift -1.000000000000000E-383 -15 -> -1E-398 +ddshi183 shift -1.000000000000000E-383 1 -> -0E-398 +ddshi184 shift -1.000000000000000E-383 15 -> -0E-398 +ddshi185 shift -9.000000000000000E-383 -1 -> -9.00000000000000E-384 +ddshi186 shift -9.000000000000000E-383 -15 -> -9E-398 +ddshi187 shift -9.000000000000000E-383 1 -> -0E-398 +ddshi188 shift -9.000000000000000E-383 15 -> -0E-398 +ddshi190 shift -1E-398 -1 -> -0E-398 +ddshi191 shift -1E-398 -15 -> -0E-398 +ddshi192 shift -1E-398 1 -> -1.0E-397 +ddshi193 shift -1E-398 15 -> -1.000000000000000E-383 + +-- more negatives (of sanities) +ddshi201 shift -0 0 -> -0 +ddshi202 shift -0 2 -> -0 +ddshi203 shift -1 2 -> -100 +ddshi204 shift -1 15 -> -1000000000000000 +ddshi205 shift -1 16 -> -0 +ddshi206 shift -1 -1 -> -0 +ddshi207 shift -0 -2 -> -0 +ddshi208 shift -1234567890123456 -1 -> -123456789012345 +ddshi209 shift -1234567890123456 -15 -> -1 +ddshi210 shift -1234567890123456 -16 -> -0 +ddshi211 shift -9934567890123456 -15 -> -9 +ddshi212 shift -9934567890123456 -16 -> -0 + + +-- Specials; NaNs are handled as usual +ddshi781 shift -Inf -8 -> -Infinity +ddshi782 shift -Inf -1 -> -Infinity +ddshi783 shift -Inf -0 -> -Infinity +ddshi784 shift -Inf 0 -> -Infinity +ddshi785 shift -Inf 1 -> -Infinity +ddshi786 shift -Inf 8 -> -Infinity +ddshi787 shift -1000 -Inf -> NaN Invalid_operation +ddshi788 shift -Inf -Inf -> NaN Invalid_operation +ddshi789 shift -1 -Inf -> NaN Invalid_operation +ddshi790 shift -0 -Inf -> NaN Invalid_operation +ddshi791 shift 0 -Inf -> NaN Invalid_operation +ddshi792 shift 1 -Inf -> NaN Invalid_operation +ddshi793 shift 1000 -Inf -> NaN Invalid_operation +ddshi794 shift Inf -Inf -> NaN Invalid_operation + +ddshi800 shift Inf -Inf -> NaN Invalid_operation +ddshi801 shift Inf -8 -> Infinity +ddshi802 shift Inf -1 -> Infinity +ddshi803 shift Inf -0 -> Infinity +ddshi804 shift Inf 0 -> Infinity +ddshi805 shift Inf 1 -> Infinity +ddshi806 shift Inf 8 -> Infinity +ddshi807 shift Inf Inf -> NaN Invalid_operation +ddshi808 shift -1000 Inf -> NaN Invalid_operation +ddshi809 shift -Inf Inf -> NaN Invalid_operation +ddshi810 shift -1 Inf -> NaN Invalid_operation +ddshi811 shift -0 Inf -> NaN Invalid_operation +ddshi812 shift 0 Inf -> NaN Invalid_operation +ddshi813 shift 1 Inf -> NaN Invalid_operation +ddshi814 shift 1000 Inf -> NaN Invalid_operation +ddshi815 shift Inf Inf -> NaN Invalid_operation + +ddshi821 shift NaN -Inf -> NaN +ddshi822 shift NaN -1000 -> NaN +ddshi823 shift NaN -1 -> NaN +ddshi824 shift NaN -0 -> NaN +ddshi825 shift NaN 0 -> NaN +ddshi826 shift NaN 1 -> NaN +ddshi827 shift NaN 1000 -> NaN +ddshi828 shift NaN Inf -> NaN +ddshi829 shift NaN NaN -> NaN +ddshi830 shift -Inf NaN -> NaN +ddshi831 shift -1000 NaN -> NaN +ddshi832 shift -1 NaN -> NaN +ddshi833 shift -0 NaN -> NaN +ddshi834 shift 0 NaN -> NaN +ddshi835 shift 1 NaN -> NaN +ddshi836 shift 1000 NaN -> NaN +ddshi837 shift Inf NaN -> NaN + +ddshi841 shift sNaN -Inf -> NaN Invalid_operation +ddshi842 shift sNaN -1000 -> NaN Invalid_operation +ddshi843 shift sNaN -1 -> NaN Invalid_operation +ddshi844 shift sNaN -0 -> NaN Invalid_operation +ddshi845 shift sNaN 0 -> NaN Invalid_operation +ddshi846 shift sNaN 1 -> NaN Invalid_operation +ddshi847 shift sNaN 1000 -> NaN Invalid_operation +ddshi848 shift sNaN NaN -> NaN Invalid_operation +ddshi849 shift sNaN sNaN -> NaN Invalid_operation +ddshi850 shift NaN sNaN -> NaN Invalid_operation +ddshi851 shift -Inf sNaN -> NaN Invalid_operation +ddshi852 shift -1000 sNaN -> NaN Invalid_operation +ddshi853 shift -1 sNaN -> NaN Invalid_operation +ddshi854 shift -0 sNaN -> NaN Invalid_operation +ddshi855 shift 0 sNaN -> NaN Invalid_operation +ddshi856 shift 1 sNaN -> NaN Invalid_operation +ddshi857 shift 1000 sNaN -> NaN Invalid_operation +ddshi858 shift Inf sNaN -> NaN Invalid_operation +ddshi859 shift NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +ddshi861 shift NaN1 -Inf -> NaN1 +ddshi862 shift +NaN2 -1000 -> NaN2 +ddshi863 shift NaN3 1000 -> NaN3 +ddshi864 shift NaN4 Inf -> NaN4 +ddshi865 shift NaN5 +NaN6 -> NaN5 +ddshi866 shift -Inf NaN7 -> NaN7 +ddshi867 shift -1000 NaN8 -> NaN8 +ddshi868 shift 1000 NaN9 -> NaN9 +ddshi869 shift Inf +NaN10 -> NaN10 +ddshi871 shift sNaN11 -Inf -> NaN11 Invalid_operation +ddshi872 shift sNaN12 -1000 -> NaN12 Invalid_operation +ddshi873 shift sNaN13 1000 -> NaN13 Invalid_operation +ddshi874 shift sNaN14 NaN17 -> NaN14 Invalid_operation +ddshi875 shift sNaN15 sNaN18 -> NaN15 Invalid_operation +ddshi876 shift NaN16 sNaN19 -> NaN19 Invalid_operation +ddshi877 shift -Inf +sNaN20 -> NaN20 Invalid_operation +ddshi878 shift -1000 sNaN21 -> NaN21 Invalid_operation +ddshi879 shift 1000 sNaN22 -> NaN22 Invalid_operation +ddshi880 shift Inf sNaN23 -> NaN23 Invalid_operation +ddshi881 shift +NaN25 +sNaN24 -> NaN24 Invalid_operation +ddshi882 shift -NaN26 NaN28 -> -NaN26 +ddshi883 shift -sNaN27 sNaN29 -> -NaN27 Invalid_operation +ddshi884 shift 1000 -NaN30 -> -NaN30 +ddshi885 shift 1000 -sNaN31 -> -NaN31 Invalid_operation Added: python/branches/release25-maint/Lib/test/decimaltestdata/ddSubtract.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/ddSubtract.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,629 @@ +------------------------------------------------------------------------ +-- ddSubtract.decTest -- decDouble subtraction -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- This set of tests are for decDoubles only; all arguments are +-- representable in a decDouble +precision: 16 +maxExponent: 384 +minExponent: -383 +extended: 1 +clamp: 1 +rounding: half_even + +-- [first group are 'quick confidence check'] +ddsub001 subtract 0 0 -> '0' +ddsub002 subtract 1 1 -> '0' +ddsub003 subtract 1 2 -> '-1' +ddsub004 subtract 2 1 -> '1' +ddsub005 subtract 2 2 -> '0' +ddsub006 subtract 3 2 -> '1' +ddsub007 subtract 2 3 -> '-1' + +ddsub011 subtract -0 0 -> '-0' +ddsub012 subtract -1 1 -> '-2' +ddsub013 subtract -1 2 -> '-3' +ddsub014 subtract -2 1 -> '-3' +ddsub015 subtract -2 2 -> '-4' +ddsub016 subtract -3 2 -> '-5' +ddsub017 subtract -2 3 -> '-5' + +ddsub021 subtract 0 -0 -> '0' +ddsub022 subtract 1 -1 -> '2' +ddsub023 subtract 1 -2 -> '3' +ddsub024 subtract 2 -1 -> '3' +ddsub025 subtract 2 -2 -> '4' +ddsub026 subtract 3 -2 -> '5' +ddsub027 subtract 2 -3 -> '5' + +ddsub030 subtract 11 1 -> 10 +ddsub031 subtract 10 1 -> 9 +ddsub032 subtract 9 1 -> 8 +ddsub033 subtract 1 1 -> 0 +ddsub034 subtract 0 1 -> -1 +ddsub035 subtract -1 1 -> -2 +ddsub036 subtract -9 1 -> -10 +ddsub037 subtract -10 1 -> -11 +ddsub038 subtract -11 1 -> -12 + +ddsub040 subtract '5.75' '3.3' -> '2.45' +ddsub041 subtract '5' '-3' -> '8' +ddsub042 subtract '-5' '-3' -> '-2' +ddsub043 subtract '-7' '2.5' -> '-9.5' +ddsub044 subtract '0.7' '0.3' -> '0.4' +ddsub045 subtract '1.3' '0.3' -> '1.0' +ddsub046 subtract '1.25' '1.25' -> '0.00' + +ddsub050 subtract '1.23456789' '1.00000000' -> '0.23456789' +ddsub051 subtract '1.23456789' '1.00000089' -> '0.23456700' + +ddsub060 subtract '70' '10000e+16' -> '-1.000000000000000E+20' Inexact Rounded +ddsub061 subtract '700' '10000e+16' -> '-1.000000000000000E+20' Inexact Rounded +ddsub062 subtract '7000' '10000e+16' -> '-9.999999999999999E+19' Inexact Rounded +ddsub063 subtract '70000' '10000e+16' -> '-9.999999999999993E+19' Rounded +ddsub064 subtract '700000' '10000e+16' -> '-9.999999999999930E+19' Rounded + -- symmetry: +ddsub065 subtract '10000e+16' '70' -> '1.000000000000000E+20' Inexact Rounded +ddsub066 subtract '10000e+16' '700' -> '1.000000000000000E+20' Inexact Rounded +ddsub067 subtract '10000e+16' '7000' -> '9.999999999999999E+19' Inexact Rounded +ddsub068 subtract '10000e+16' '70000' -> '9.999999999999993E+19' Rounded +ddsub069 subtract '10000e+16' '700000' -> '9.999999999999930E+19' Rounded + + -- some of the next group are really constructor tests +ddsub090 subtract '00.0' '0.0' -> '0.0' +ddsub091 subtract '00.0' '0.00' -> '0.00' +ddsub092 subtract '0.00' '00.0' -> '0.00' +ddsub093 subtract '00.0' '0.00' -> '0.00' +ddsub094 subtract '0.00' '00.0' -> '0.00' +ddsub095 subtract '3' '.3' -> '2.7' +ddsub096 subtract '3.' '.3' -> '2.7' +ddsub097 subtract '3.0' '.3' -> '2.7' +ddsub098 subtract '3.00' '.3' -> '2.70' +ddsub099 subtract '3' '3' -> '0' +ddsub100 subtract '3' '+3' -> '0' +ddsub101 subtract '3' '-3' -> '6' +ddsub102 subtract '3' '0.3' -> '2.7' +ddsub103 subtract '3.' '0.3' -> '2.7' +ddsub104 subtract '3.0' '0.3' -> '2.7' +ddsub105 subtract '3.00' '0.3' -> '2.70' +ddsub106 subtract '3' '3.0' -> '0.0' +ddsub107 subtract '3' '+3.0' -> '0.0' +ddsub108 subtract '3' '-3.0' -> '6.0' + +-- the above all from add; massaged and extended. Now some new ones... +-- [particularly important for comparisons] +-- NB: -xE-8 below were non-exponents pre-ANSI X3-274, and -1E-7 or 0E-7 +-- with input rounding. +ddsub120 subtract '10.23456784' '10.23456789' -> '-5E-8' +ddsub121 subtract '10.23456785' '10.23456789' -> '-4E-8' +ddsub122 subtract '10.23456786' '10.23456789' -> '-3E-8' +ddsub123 subtract '10.23456787' '10.23456789' -> '-2E-8' +ddsub124 subtract '10.23456788' '10.23456789' -> '-1E-8' +ddsub125 subtract '10.23456789' '10.23456789' -> '0E-8' +ddsub126 subtract '10.23456790' '10.23456789' -> '1E-8' +ddsub127 subtract '10.23456791' '10.23456789' -> '2E-8' +ddsub128 subtract '10.23456792' '10.23456789' -> '3E-8' +ddsub129 subtract '10.23456793' '10.23456789' -> '4E-8' +ddsub130 subtract '10.23456794' '10.23456789' -> '5E-8' +ddsub131 subtract '10.23456781' '10.23456786' -> '-5E-8' +ddsub132 subtract '10.23456782' '10.23456786' -> '-4E-8' +ddsub133 subtract '10.23456783' '10.23456786' -> '-3E-8' +ddsub134 subtract '10.23456784' '10.23456786' -> '-2E-8' +ddsub135 subtract '10.23456785' '10.23456786' -> '-1E-8' +ddsub136 subtract '10.23456786' '10.23456786' -> '0E-8' +ddsub137 subtract '10.23456787' '10.23456786' -> '1E-8' +ddsub138 subtract '10.23456788' '10.23456786' -> '2E-8' +ddsub139 subtract '10.23456789' '10.23456786' -> '3E-8' +ddsub140 subtract '10.23456790' '10.23456786' -> '4E-8' +ddsub141 subtract '10.23456791' '10.23456786' -> '5E-8' +ddsub142 subtract '1' '0.999999999' -> '1E-9' +ddsub143 subtract '0.999999999' '1' -> '-1E-9' +ddsub144 subtract '-10.23456780' '-10.23456786' -> '6E-8' +ddsub145 subtract '-10.23456790' '-10.23456786' -> '-4E-8' +ddsub146 subtract '-10.23456791' '-10.23456786' -> '-5E-8' + +-- additional scaled arithmetic tests [0.97 problem] +ddsub160 subtract '0' '.1' -> '-0.1' +ddsub161 subtract '00' '.97983' -> '-0.97983' +ddsub162 subtract '0' '.9' -> '-0.9' +ddsub163 subtract '0' '0.102' -> '-0.102' +ddsub164 subtract '0' '.4' -> '-0.4' +ddsub165 subtract '0' '.307' -> '-0.307' +ddsub166 subtract '0' '.43822' -> '-0.43822' +ddsub167 subtract '0' '.911' -> '-0.911' +ddsub168 subtract '.0' '.02' -> '-0.02' +ddsub169 subtract '00' '.392' -> '-0.392' +ddsub170 subtract '0' '.26' -> '-0.26' +ddsub171 subtract '0' '0.51' -> '-0.51' +ddsub172 subtract '0' '.2234' -> '-0.2234' +ddsub173 subtract '0' '.2' -> '-0.2' +ddsub174 subtract '.0' '.0008' -> '-0.0008' +-- 0. on left +ddsub180 subtract '0.0' '-.1' -> '0.1' +ddsub181 subtract '0.00' '-.97983' -> '0.97983' +ddsub182 subtract '0.0' '-.9' -> '0.9' +ddsub183 subtract '0.0' '-0.102' -> '0.102' +ddsub184 subtract '0.0' '-.4' -> '0.4' +ddsub185 subtract '0.0' '-.307' -> '0.307' +ddsub186 subtract '0.0' '-.43822' -> '0.43822' +ddsub187 subtract '0.0' '-.911' -> '0.911' +ddsub188 subtract '0.0' '-.02' -> '0.02' +ddsub189 subtract '0.00' '-.392' -> '0.392' +ddsub190 subtract '0.0' '-.26' -> '0.26' +ddsub191 subtract '0.0' '-0.51' -> '0.51' +ddsub192 subtract '0.0' '-.2234' -> '0.2234' +ddsub193 subtract '0.0' '-.2' -> '0.2' +ddsub194 subtract '0.0' '-.0008' -> '0.0008' +-- negatives of same +ddsub200 subtract '0' '-.1' -> '0.1' +ddsub201 subtract '00' '-.97983' -> '0.97983' +ddsub202 subtract '0' '-.9' -> '0.9' +ddsub203 subtract '0' '-0.102' -> '0.102' +ddsub204 subtract '0' '-.4' -> '0.4' +ddsub205 subtract '0' '-.307' -> '0.307' +ddsub206 subtract '0' '-.43822' -> '0.43822' +ddsub207 subtract '0' '-.911' -> '0.911' +ddsub208 subtract '.0' '-.02' -> '0.02' +ddsub209 subtract '00' '-.392' -> '0.392' +ddsub210 subtract '0' '-.26' -> '0.26' +ddsub211 subtract '0' '-0.51' -> '0.51' +ddsub212 subtract '0' '-.2234' -> '0.2234' +ddsub213 subtract '0' '-.2' -> '0.2' +ddsub214 subtract '.0' '-.0008' -> '0.0008' + +-- more fixed, LHS swaps [really the same as testcases under add] +ddsub220 subtract '-56267E-12' 0 -> '-5.6267E-8' +ddsub221 subtract '-56267E-11' 0 -> '-5.6267E-7' +ddsub222 subtract '-56267E-10' 0 -> '-0.0000056267' +ddsub223 subtract '-56267E-9' 0 -> '-0.000056267' +ddsub224 subtract '-56267E-8' 0 -> '-0.00056267' +ddsub225 subtract '-56267E-7' 0 -> '-0.0056267' +ddsub226 subtract '-56267E-6' 0 -> '-0.056267' +ddsub227 subtract '-56267E-5' 0 -> '-0.56267' +ddsub228 subtract '-56267E-2' 0 -> '-562.67' +ddsub229 subtract '-56267E-1' 0 -> '-5626.7' +ddsub230 subtract '-56267E-0' 0 -> '-56267' +-- symmetry ... +ddsub240 subtract 0 '-56267E-12' -> '5.6267E-8' +ddsub241 subtract 0 '-56267E-11' -> '5.6267E-7' +ddsub242 subtract 0 '-56267E-10' -> '0.0000056267' +ddsub243 subtract 0 '-56267E-9' -> '0.000056267' +ddsub244 subtract 0 '-56267E-8' -> '0.00056267' +ddsub245 subtract 0 '-56267E-7' -> '0.0056267' +ddsub246 subtract 0 '-56267E-6' -> '0.056267' +ddsub247 subtract 0 '-56267E-5' -> '0.56267' +ddsub248 subtract 0 '-56267E-2' -> '562.67' +ddsub249 subtract 0 '-56267E-1' -> '5626.7' +ddsub250 subtract 0 '-56267E-0' -> '56267' + +-- now some more from the 'new' add +ddsub301 subtract '1.23456789' '1.00000000' -> '0.23456789' +ddsub302 subtract '1.23456789' '1.00000011' -> '0.23456778' + +-- some carrying effects +ddsub321 subtract '0.9998' '0.0000' -> '0.9998' +ddsub322 subtract '0.9998' '0.0001' -> '0.9997' +ddsub323 subtract '0.9998' '0.0002' -> '0.9996' +ddsub324 subtract '0.9998' '0.0003' -> '0.9995' +ddsub325 subtract '0.9998' '-0.0000' -> '0.9998' +ddsub326 subtract '0.9998' '-0.0001' -> '0.9999' +ddsub327 subtract '0.9998' '-0.0002' -> '1.0000' +ddsub328 subtract '0.9998' '-0.0003' -> '1.0001' + +-- internal boundaries +ddsub346 subtract '10000e+9' '7' -> '9999999999993' +ddsub347 subtract '10000e+9' '70' -> '9999999999930' +ddsub348 subtract '10000e+9' '700' -> '9999999999300' +ddsub349 subtract '10000e+9' '7000' -> '9999999993000' +ddsub350 subtract '10000e+9' '70000' -> '9999999930000' +ddsub351 subtract '10000e+9' '700000' -> '9999999300000' +ddsub352 subtract '7' '10000e+9' -> '-9999999999993' +ddsub353 subtract '70' '10000e+9' -> '-9999999999930' +ddsub354 subtract '700' '10000e+9' -> '-9999999999300' +ddsub355 subtract '7000' '10000e+9' -> '-9999999993000' +ddsub356 subtract '70000' '10000e+9' -> '-9999999930000' +ddsub357 subtract '700000' '10000e+9' -> '-9999999300000' + +-- zero preservation +ddsub361 subtract 1 '0.0001' -> '0.9999' +ddsub362 subtract 1 '0.00001' -> '0.99999' +ddsub363 subtract 1 '0.000001' -> '0.999999' +ddsub364 subtract 1 '0.0000000000000001' -> '0.9999999999999999' +ddsub365 subtract 1 '0.00000000000000001' -> '1.000000000000000' Inexact Rounded +ddsub366 subtract 1 '0.000000000000000001' -> '1.000000000000000' Inexact Rounded + +-- some funny zeros [in case of bad signum] +ddsub370 subtract 1 0 -> 1 +ddsub371 subtract 1 0. -> 1 +ddsub372 subtract 1 .0 -> 1.0 +ddsub373 subtract 1 0.0 -> 1.0 +ddsub374 subtract 0 1 -> -1 +ddsub375 subtract 0. 1 -> -1 +ddsub376 subtract .0 1 -> -1.0 +ddsub377 subtract 0.0 1 -> -1.0 + +-- leading 0 digit before round +ddsub910 subtract -103519362 -51897955.3 -> -51621406.7 +ddsub911 subtract 159579.444 89827.5229 -> 69751.9211 + +ddsub920 subtract 333.0000000123456 33.00000001234566 -> 299.9999999999999 Inexact Rounded +ddsub921 subtract 333.0000000123456 33.00000001234565 -> 300.0000000000000 Inexact Rounded +ddsub922 subtract 133.0000000123456 33.00000001234565 -> 99.99999999999995 +ddsub923 subtract 133.0000000123456 33.00000001234564 -> 99.99999999999996 +ddsub924 subtract 133.0000000123456 33.00000001234540 -> 100.0000000000002 Rounded +ddsub925 subtract 133.0000000123456 43.00000001234560 -> 90.00000000000000 +ddsub926 subtract 133.0000000123456 43.00000001234561 -> 89.99999999999999 +ddsub927 subtract 133.0000000123456 43.00000001234566 -> 89.99999999999994 +ddsub928 subtract 101.0000000123456 91.00000001234566 -> 9.99999999999994 +ddsub929 subtract 101.0000000123456 99.00000001234566 -> 1.99999999999994 + +-- more LHS swaps [were fixed] +ddsub390 subtract '-56267E-10' 0 -> '-0.0000056267' +ddsub391 subtract '-56267E-6' 0 -> '-0.056267' +ddsub392 subtract '-56267E-5' 0 -> '-0.56267' +ddsub393 subtract '-56267E-4' 0 -> '-5.6267' +ddsub394 subtract '-56267E-3' 0 -> '-56.267' +ddsub395 subtract '-56267E-2' 0 -> '-562.67' +ddsub396 subtract '-56267E-1' 0 -> '-5626.7' +ddsub397 subtract '-56267E-0' 0 -> '-56267' +ddsub398 subtract '-5E-10' 0 -> '-5E-10' +ddsub399 subtract '-5E-7' 0 -> '-5E-7' +ddsub400 subtract '-5E-6' 0 -> '-0.000005' +ddsub401 subtract '-5E-5' 0 -> '-0.00005' +ddsub402 subtract '-5E-4' 0 -> '-0.0005' +ddsub403 subtract '-5E-1' 0 -> '-0.5' +ddsub404 subtract '-5E0' 0 -> '-5' +ddsub405 subtract '-5E1' 0 -> '-50' +ddsub406 subtract '-5E5' 0 -> '-500000' +ddsub407 subtract '-5E15' 0 -> '-5000000000000000' +ddsub408 subtract '-5E16' 0 -> '-5.000000000000000E+16' Rounded +ddsub409 subtract '-5E17' 0 -> '-5.000000000000000E+17' Rounded +ddsub410 subtract '-5E18' 0 -> '-5.000000000000000E+18' Rounded +ddsub411 subtract '-5E100' 0 -> '-5.000000000000000E+100' Rounded + +-- more RHS swaps [were fixed] +ddsub420 subtract 0 '-56267E-10' -> '0.0000056267' +ddsub421 subtract 0 '-56267E-6' -> '0.056267' +ddsub422 subtract 0 '-56267E-5' -> '0.56267' +ddsub423 subtract 0 '-56267E-4' -> '5.6267' +ddsub424 subtract 0 '-56267E-3' -> '56.267' +ddsub425 subtract 0 '-56267E-2' -> '562.67' +ddsub426 subtract 0 '-56267E-1' -> '5626.7' +ddsub427 subtract 0 '-56267E-0' -> '56267' +ddsub428 subtract 0 '-5E-10' -> '5E-10' +ddsub429 subtract 0 '-5E-7' -> '5E-7' +ddsub430 subtract 0 '-5E-6' -> '0.000005' +ddsub431 subtract 0 '-5E-5' -> '0.00005' +ddsub432 subtract 0 '-5E-4' -> '0.0005' +ddsub433 subtract 0 '-5E-1' -> '0.5' +ddsub434 subtract 0 '-5E0' -> '5' +ddsub435 subtract 0 '-5E1' -> '50' +ddsub436 subtract 0 '-5E5' -> '500000' +ddsub437 subtract 0 '-5E15' -> '5000000000000000' +ddsub438 subtract 0 '-5E16' -> '5.000000000000000E+16' Rounded +ddsub439 subtract 0 '-5E17' -> '5.000000000000000E+17' Rounded +ddsub440 subtract 0 '-5E18' -> '5.000000000000000E+18' Rounded +ddsub441 subtract 0 '-5E100' -> '5.000000000000000E+100' Rounded + + +-- try borderline precision, with carries, etc. +ddsub461 subtract '1E+16' '1' -> '9999999999999999' +ddsub462 subtract '1E+12' '-1.111' -> '1000000000001.111' +ddsub463 subtract '1.111' '-1E+12' -> '1000000000001.111' +ddsub464 subtract '-1' '-1E+16' -> '9999999999999999' +ddsub465 subtract '7E+15' '1' -> '6999999999999999' +ddsub466 subtract '7E+12' '-1.111' -> '7000000000001.111' +ddsub467 subtract '1.111' '-7E+12' -> '7000000000001.111' +ddsub468 subtract '-1' '-7E+15' -> '6999999999999999' + +-- 1234567890123456 1234567890123456 1 23456789012345 +ddsub470 subtract '0.4444444444444444' '-0.5555555555555563' -> '1.000000000000001' Inexact Rounded +ddsub471 subtract '0.4444444444444444' '-0.5555555555555562' -> '1.000000000000001' Inexact Rounded +ddsub472 subtract '0.4444444444444444' '-0.5555555555555561' -> '1.000000000000000' Inexact Rounded +ddsub473 subtract '0.4444444444444444' '-0.5555555555555560' -> '1.000000000000000' Inexact Rounded +ddsub474 subtract '0.4444444444444444' '-0.5555555555555559' -> '1.000000000000000' Inexact Rounded +ddsub475 subtract '0.4444444444444444' '-0.5555555555555558' -> '1.000000000000000' Inexact Rounded +ddsub476 subtract '0.4444444444444444' '-0.5555555555555557' -> '1.000000000000000' Inexact Rounded +ddsub477 subtract '0.4444444444444444' '-0.5555555555555556' -> '1.000000000000000' Rounded +ddsub478 subtract '0.4444444444444444' '-0.5555555555555555' -> '0.9999999999999999' +ddsub479 subtract '0.4444444444444444' '-0.5555555555555554' -> '0.9999999999999998' +ddsub480 subtract '0.4444444444444444' '-0.5555555555555553' -> '0.9999999999999997' +ddsub481 subtract '0.4444444444444444' '-0.5555555555555552' -> '0.9999999999999996' +ddsub482 subtract '0.4444444444444444' '-0.5555555555555551' -> '0.9999999999999995' +ddsub483 subtract '0.4444444444444444' '-0.5555555555555550' -> '0.9999999999999994' + +-- and some more, including residue effects and different roundings +rounding: half_up +ddsub500 subtract '1231234567456789' 0 -> '1231234567456789' +ddsub501 subtract '1231234567456789' 0.000000001 -> '1231234567456789' Inexact Rounded +ddsub502 subtract '1231234567456789' 0.000001 -> '1231234567456789' Inexact Rounded +ddsub503 subtract '1231234567456789' 0.1 -> '1231234567456789' Inexact Rounded +ddsub504 subtract '1231234567456789' 0.4 -> '1231234567456789' Inexact Rounded +ddsub505 subtract '1231234567456789' 0.49 -> '1231234567456789' Inexact Rounded +ddsub506 subtract '1231234567456789' 0.499999 -> '1231234567456789' Inexact Rounded +ddsub507 subtract '1231234567456789' 0.499999999 -> '1231234567456789' Inexact Rounded +ddsub508 subtract '1231234567456789' 0.5 -> '1231234567456789' Inexact Rounded +ddsub509 subtract '1231234567456789' 0.500000001 -> '1231234567456788' Inexact Rounded +ddsub510 subtract '1231234567456789' 0.500001 -> '1231234567456788' Inexact Rounded +ddsub511 subtract '1231234567456789' 0.51 -> '1231234567456788' Inexact Rounded +ddsub512 subtract '1231234567456789' 0.6 -> '1231234567456788' Inexact Rounded +ddsub513 subtract '1231234567456789' 0.9 -> '1231234567456788' Inexact Rounded +ddsub514 subtract '1231234567456789' 0.99999 -> '1231234567456788' Inexact Rounded +ddsub515 subtract '1231234567456789' 0.999999999 -> '1231234567456788' Inexact Rounded +ddsub516 subtract '1231234567456789' 1 -> '1231234567456788' +ddsub517 subtract '1231234567456789' 1.000000001 -> '1231234567456788' Inexact Rounded +ddsub518 subtract '1231234567456789' 1.00001 -> '1231234567456788' Inexact Rounded +ddsub519 subtract '1231234567456789' 1.1 -> '1231234567456788' Inexact Rounded + +rounding: half_even +ddsub520 subtract '1231234567456789' 0 -> '1231234567456789' +ddsub521 subtract '1231234567456789' 0.000000001 -> '1231234567456789' Inexact Rounded +ddsub522 subtract '1231234567456789' 0.000001 -> '1231234567456789' Inexact Rounded +ddsub523 subtract '1231234567456789' 0.1 -> '1231234567456789' Inexact Rounded +ddsub524 subtract '1231234567456789' 0.4 -> '1231234567456789' Inexact Rounded +ddsub525 subtract '1231234567456789' 0.49 -> '1231234567456789' Inexact Rounded +ddsub526 subtract '1231234567456789' 0.499999 -> '1231234567456789' Inexact Rounded +ddsub527 subtract '1231234567456789' 0.499999999 -> '1231234567456789' Inexact Rounded +ddsub528 subtract '1231234567456789' 0.5 -> '1231234567456788' Inexact Rounded +ddsub529 subtract '1231234567456789' 0.500000001 -> '1231234567456788' Inexact Rounded +ddsub530 subtract '1231234567456789' 0.500001 -> '1231234567456788' Inexact Rounded +ddsub531 subtract '1231234567456789' 0.51 -> '1231234567456788' Inexact Rounded +ddsub532 subtract '1231234567456789' 0.6 -> '1231234567456788' Inexact Rounded +ddsub533 subtract '1231234567456789' 0.9 -> '1231234567456788' Inexact Rounded +ddsub534 subtract '1231234567456789' 0.99999 -> '1231234567456788' Inexact Rounded +ddsub535 subtract '1231234567456789' 0.999999999 -> '1231234567456788' Inexact Rounded +ddsub536 subtract '1231234567456789' 1 -> '1231234567456788' +ddsub537 subtract '1231234567456789' 1.00000001 -> '1231234567456788' Inexact Rounded +ddsub538 subtract '1231234567456789' 1.00001 -> '1231234567456788' Inexact Rounded +ddsub539 subtract '1231234567456789' 1.1 -> '1231234567456788' Inexact Rounded +-- critical few with even bottom digit... +ddsub540 subtract '1231234567456788' 0.499999999 -> '1231234567456788' Inexact Rounded +ddsub541 subtract '1231234567456788' 0.5 -> '1231234567456788' Inexact Rounded +ddsub542 subtract '1231234567456788' 0.500000001 -> '1231234567456787' Inexact Rounded + +rounding: down +ddsub550 subtract '1231234567456789' 0 -> '1231234567456789' +ddsub551 subtract '1231234567456789' 0.000000001 -> '1231234567456788' Inexact Rounded +ddsub552 subtract '1231234567456789' 0.000001 -> '1231234567456788' Inexact Rounded +ddsub553 subtract '1231234567456789' 0.1 -> '1231234567456788' Inexact Rounded +ddsub554 subtract '1231234567456789' 0.4 -> '1231234567456788' Inexact Rounded +ddsub555 subtract '1231234567456789' 0.49 -> '1231234567456788' Inexact Rounded +ddsub556 subtract '1231234567456789' 0.499999 -> '1231234567456788' Inexact Rounded +ddsub557 subtract '1231234567456789' 0.499999999 -> '1231234567456788' Inexact Rounded +ddsub558 subtract '1231234567456789' 0.5 -> '1231234567456788' Inexact Rounded +ddsub559 subtract '1231234567456789' 0.500000001 -> '1231234567456788' Inexact Rounded +ddsub560 subtract '1231234567456789' 0.500001 -> '1231234567456788' Inexact Rounded +ddsub561 subtract '1231234567456789' 0.51 -> '1231234567456788' Inexact Rounded +ddsub562 subtract '1231234567456789' 0.6 -> '1231234567456788' Inexact Rounded +ddsub563 subtract '1231234567456789' 0.9 -> '1231234567456788' Inexact Rounded +ddsub564 subtract '1231234567456789' 0.99999 -> '1231234567456788' Inexact Rounded +ddsub565 subtract '1231234567456789' 0.999999999 -> '1231234567456788' Inexact Rounded +ddsub566 subtract '1231234567456789' 1 -> '1231234567456788' +ddsub567 subtract '1231234567456789' 1.00000001 -> '1231234567456787' Inexact Rounded +ddsub568 subtract '1231234567456789' 1.00001 -> '1231234567456787' Inexact Rounded +ddsub569 subtract '1231234567456789' 1.1 -> '1231234567456787' Inexact Rounded + +-- symmetry... +rounding: half_up +ddsub600 subtract 0 '1231234567456789' -> '-1231234567456789' +ddsub601 subtract 0.000000001 '1231234567456789' -> '-1231234567456789' Inexact Rounded +ddsub602 subtract 0.000001 '1231234567456789' -> '-1231234567456789' Inexact Rounded +ddsub603 subtract 0.1 '1231234567456789' -> '-1231234567456789' Inexact Rounded +ddsub604 subtract 0.4 '1231234567456789' -> '-1231234567456789' Inexact Rounded +ddsub605 subtract 0.49 '1231234567456789' -> '-1231234567456789' Inexact Rounded +ddsub606 subtract 0.499999 '1231234567456789' -> '-1231234567456789' Inexact Rounded +ddsub607 subtract 0.499999999 '1231234567456789' -> '-1231234567456789' Inexact Rounded +ddsub608 subtract 0.5 '1231234567456789' -> '-1231234567456789' Inexact Rounded +ddsub609 subtract 0.500000001 '1231234567456789' -> '-1231234567456788' Inexact Rounded +ddsub610 subtract 0.500001 '1231234567456789' -> '-1231234567456788' Inexact Rounded +ddsub611 subtract 0.51 '1231234567456789' -> '-1231234567456788' Inexact Rounded +ddsub612 subtract 0.6 '1231234567456789' -> '-1231234567456788' Inexact Rounded +ddsub613 subtract 0.9 '1231234567456789' -> '-1231234567456788' Inexact Rounded +ddsub614 subtract 0.99999 '1231234567456789' -> '-1231234567456788' Inexact Rounded +ddsub615 subtract 0.999999999 '1231234567456789' -> '-1231234567456788' Inexact Rounded +ddsub616 subtract 1 '1231234567456789' -> '-1231234567456788' +ddsub617 subtract 1.000000001 '1231234567456789' -> '-1231234567456788' Inexact Rounded +ddsub618 subtract 1.00001 '1231234567456789' -> '-1231234567456788' Inexact Rounded +ddsub619 subtract 1.1 '1231234567456789' -> '-1231234567456788' Inexact Rounded + +rounding: half_even +ddsub620 subtract 0 '1231234567456789' -> '-1231234567456789' +ddsub621 subtract 0.000000001 '1231234567456789' -> '-1231234567456789' Inexact Rounded +ddsub622 subtract 0.000001 '1231234567456789' -> '-1231234567456789' Inexact Rounded +ddsub623 subtract 0.1 '1231234567456789' -> '-1231234567456789' Inexact Rounded +ddsub624 subtract 0.4 '1231234567456789' -> '-1231234567456789' Inexact Rounded +ddsub625 subtract 0.49 '1231234567456789' -> '-1231234567456789' Inexact Rounded +ddsub626 subtract 0.499999 '1231234567456789' -> '-1231234567456789' Inexact Rounded +ddsub627 subtract 0.499999999 '1231234567456789' -> '-1231234567456789' Inexact Rounded +ddsub628 subtract 0.5 '1231234567456789' -> '-1231234567456788' Inexact Rounded +ddsub629 subtract 0.500000001 '1231234567456789' -> '-1231234567456788' Inexact Rounded +ddsub630 subtract 0.500001 '1231234567456789' -> '-1231234567456788' Inexact Rounded +ddsub631 subtract 0.51 '1231234567456789' -> '-1231234567456788' Inexact Rounded +ddsub632 subtract 0.6 '1231234567456789' -> '-1231234567456788' Inexact Rounded +ddsub633 subtract 0.9 '1231234567456789' -> '-1231234567456788' Inexact Rounded +ddsub634 subtract 0.99999 '1231234567456789' -> '-1231234567456788' Inexact Rounded +ddsub635 subtract 0.999999999 '1231234567456789' -> '-1231234567456788' Inexact Rounded +ddsub636 subtract 1 '1231234567456789' -> '-1231234567456788' +ddsub637 subtract 1.00000001 '1231234567456789' -> '-1231234567456788' Inexact Rounded +ddsub638 subtract 1.00001 '1231234567456789' -> '-1231234567456788' Inexact Rounded +ddsub639 subtract 1.1 '1231234567456789' -> '-1231234567456788' Inexact Rounded +-- critical few with even bottom digit... +ddsub640 subtract 0.499999999 '1231234567456788' -> '-1231234567456788' Inexact Rounded +ddsub641 subtract 0.5 '1231234567456788' -> '-1231234567456788' Inexact Rounded +ddsub642 subtract 0.500000001 '1231234567456788' -> '-1231234567456787' Inexact Rounded + +rounding: down +ddsub650 subtract 0 '1231234567456789' -> '-1231234567456789' +ddsub651 subtract 0.000000001 '1231234567456789' -> '-1231234567456788' Inexact Rounded +ddsub652 subtract 0.000001 '1231234567456789' -> '-1231234567456788' Inexact Rounded +ddsub653 subtract 0.1 '1231234567456789' -> '-1231234567456788' Inexact Rounded +ddsub654 subtract 0.4 '1231234567456789' -> '-1231234567456788' Inexact Rounded +ddsub655 subtract 0.49 '1231234567456789' -> '-1231234567456788' Inexact Rounded +ddsub656 subtract 0.499999 '1231234567456789' -> '-1231234567456788' Inexact Rounded +ddsub657 subtract 0.499999999 '1231234567456789' -> '-1231234567456788' Inexact Rounded +ddsub658 subtract 0.5 '1231234567456789' -> '-1231234567456788' Inexact Rounded +ddsub659 subtract 0.500000001 '1231234567456789' -> '-1231234567456788' Inexact Rounded +ddsub660 subtract 0.500001 '1231234567456789' -> '-1231234567456788' Inexact Rounded +ddsub661 subtract 0.51 '1231234567456789' -> '-1231234567456788' Inexact Rounded +ddsub662 subtract 0.6 '1231234567456789' -> '-1231234567456788' Inexact Rounded +ddsub663 subtract 0.9 '1231234567456789' -> '-1231234567456788' Inexact Rounded +ddsub664 subtract 0.99999 '1231234567456789' -> '-1231234567456788' Inexact Rounded +ddsub665 subtract 0.999999999 '1231234567456789' -> '-1231234567456788' Inexact Rounded +ddsub666 subtract 1 '1231234567456789' -> '-1231234567456788' +ddsub667 subtract 1.00000001 '1231234567456789' -> '-1231234567456787' Inexact Rounded +ddsub668 subtract 1.00001 '1231234567456789' -> '-1231234567456787' Inexact Rounded +ddsub669 subtract 1.1 '1231234567456789' -> '-1231234567456787' Inexact Rounded + + +-- lots of leading zeros in intermediate result, and showing effects of +-- input rounding would have affected the following +rounding: half_up +ddsub670 subtract '1234567456789' '1234567456788.1' -> 0.9 +ddsub671 subtract '1234567456789' '1234567456788.9' -> 0.1 +ddsub672 subtract '1234567456789' '1234567456789.1' -> -0.1 +ddsub673 subtract '1234567456789' '1234567456789.5' -> -0.5 +ddsub674 subtract '1234567456789' '1234567456789.9' -> -0.9 + +rounding: half_even +ddsub680 subtract '1234567456789' '1234567456788.1' -> 0.9 +ddsub681 subtract '1234567456789' '1234567456788.9' -> 0.1 +ddsub682 subtract '1234567456789' '1234567456789.1' -> -0.1 +ddsub683 subtract '1234567456789' '1234567456789.5' -> -0.5 +ddsub684 subtract '1234567456789' '1234567456789.9' -> -0.9 + +ddsub685 subtract '1234567456788' '1234567456787.1' -> 0.9 +ddsub686 subtract '1234567456788' '1234567456787.9' -> 0.1 +ddsub687 subtract '1234567456788' '1234567456788.1' -> -0.1 +ddsub688 subtract '1234567456788' '1234567456788.5' -> -0.5 +ddsub689 subtract '1234567456788' '1234567456788.9' -> -0.9 + +rounding: down +ddsub690 subtract '1234567456789' '1234567456788.1' -> 0.9 +ddsub691 subtract '1234567456789' '1234567456788.9' -> 0.1 +ddsub692 subtract '1234567456789' '1234567456789.1' -> -0.1 +ddsub693 subtract '1234567456789' '1234567456789.5' -> -0.5 +ddsub694 subtract '1234567456789' '1234567456789.9' -> -0.9 + +-- Specials +ddsub780 subtract -Inf Inf -> -Infinity +ddsub781 subtract -Inf 1000 -> -Infinity +ddsub782 subtract -Inf 1 -> -Infinity +ddsub783 subtract -Inf -0 -> -Infinity +ddsub784 subtract -Inf -1 -> -Infinity +ddsub785 subtract -Inf -1000 -> -Infinity +ddsub787 subtract -1000 Inf -> -Infinity +ddsub788 subtract -Inf Inf -> -Infinity +ddsub789 subtract -1 Inf -> -Infinity +ddsub790 subtract 0 Inf -> -Infinity +ddsub791 subtract 1 Inf -> -Infinity +ddsub792 subtract 1000 Inf -> -Infinity + +ddsub800 subtract Inf Inf -> NaN Invalid_operation +ddsub801 subtract Inf 1000 -> Infinity +ddsub802 subtract Inf 1 -> Infinity +ddsub803 subtract Inf 0 -> Infinity +ddsub804 subtract Inf -0 -> Infinity +ddsub805 subtract Inf -1 -> Infinity +ddsub806 subtract Inf -1000 -> Infinity +ddsub807 subtract Inf -Inf -> Infinity +ddsub808 subtract -1000 -Inf -> Infinity +ddsub809 subtract -Inf -Inf -> NaN Invalid_operation +ddsub810 subtract -1 -Inf -> Infinity +ddsub811 subtract -0 -Inf -> Infinity +ddsub812 subtract 0 -Inf -> Infinity +ddsub813 subtract 1 -Inf -> Infinity +ddsub814 subtract 1000 -Inf -> Infinity +ddsub815 subtract Inf -Inf -> Infinity + +ddsub821 subtract NaN Inf -> NaN +ddsub822 subtract -NaN 1000 -> -NaN +ddsub823 subtract NaN 1 -> NaN +ddsub824 subtract NaN 0 -> NaN +ddsub825 subtract NaN -0 -> NaN +ddsub826 subtract NaN -1 -> NaN +ddsub827 subtract NaN -1000 -> NaN +ddsub828 subtract NaN -Inf -> NaN +ddsub829 subtract -NaN NaN -> -NaN +ddsub830 subtract -Inf NaN -> NaN +ddsub831 subtract -1000 NaN -> NaN +ddsub832 subtract -1 NaN -> NaN +ddsub833 subtract -0 NaN -> NaN +ddsub834 subtract 0 NaN -> NaN +ddsub835 subtract 1 NaN -> NaN +ddsub836 subtract 1000 -NaN -> -NaN +ddsub837 subtract Inf NaN -> NaN + +ddsub841 subtract sNaN Inf -> NaN Invalid_operation +ddsub842 subtract -sNaN 1000 -> -NaN Invalid_operation +ddsub843 subtract sNaN 1 -> NaN Invalid_operation +ddsub844 subtract sNaN 0 -> NaN Invalid_operation +ddsub845 subtract sNaN -0 -> NaN Invalid_operation +ddsub846 subtract sNaN -1 -> NaN Invalid_operation +ddsub847 subtract sNaN -1000 -> NaN Invalid_operation +ddsub848 subtract sNaN NaN -> NaN Invalid_operation +ddsub849 subtract sNaN sNaN -> NaN Invalid_operation +ddsub850 subtract NaN sNaN -> NaN Invalid_operation +ddsub851 subtract -Inf -sNaN -> -NaN Invalid_operation +ddsub852 subtract -1000 sNaN -> NaN Invalid_operation +ddsub853 subtract -1 sNaN -> NaN Invalid_operation +ddsub854 subtract -0 sNaN -> NaN Invalid_operation +ddsub855 subtract 0 sNaN -> NaN Invalid_operation +ddsub856 subtract 1 sNaN -> NaN Invalid_operation +ddsub857 subtract 1000 sNaN -> NaN Invalid_operation +ddsub858 subtract Inf sNaN -> NaN Invalid_operation +ddsub859 subtract NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +ddsub861 subtract NaN01 -Inf -> NaN1 +ddsub862 subtract -NaN02 -1000 -> -NaN2 +ddsub863 subtract NaN03 1000 -> NaN3 +ddsub864 subtract NaN04 Inf -> NaN4 +ddsub865 subtract NaN05 NaN61 -> NaN5 +ddsub866 subtract -Inf -NaN71 -> -NaN71 +ddsub867 subtract -1000 NaN81 -> NaN81 +ddsub868 subtract 1000 NaN91 -> NaN91 +ddsub869 subtract Inf NaN101 -> NaN101 +ddsub871 subtract sNaN011 -Inf -> NaN11 Invalid_operation +ddsub872 subtract sNaN012 -1000 -> NaN12 Invalid_operation +ddsub873 subtract -sNaN013 1000 -> -NaN13 Invalid_operation +ddsub874 subtract sNaN014 NaN171 -> NaN14 Invalid_operation +ddsub875 subtract sNaN015 sNaN181 -> NaN15 Invalid_operation +ddsub876 subtract NaN016 sNaN191 -> NaN191 Invalid_operation +ddsub877 subtract -Inf sNaN201 -> NaN201 Invalid_operation +ddsub878 subtract -1000 sNaN211 -> NaN211 Invalid_operation +ddsub879 subtract 1000 -sNaN221 -> -NaN221 Invalid_operation +ddsub880 subtract Inf sNaN231 -> NaN231 Invalid_operation +ddsub881 subtract NaN025 sNaN241 -> NaN241 Invalid_operation + +-- edge case spills +ddsub901 subtract 2.E-3 1.002 -> -1.000 +ddsub902 subtract 2.0E-3 1.002 -> -1.0000 +ddsub903 subtract 2.00E-3 1.0020 -> -1.00000 +ddsub904 subtract 2.000E-3 1.00200 -> -1.000000 +ddsub905 subtract 2.0000E-3 1.002000 -> -1.0000000 +ddsub906 subtract 2.00000E-3 1.0020000 -> -1.00000000 +ddsub907 subtract 2.000000E-3 1.00200000 -> -1.000000000 +ddsub908 subtract 2.0000000E-3 1.002000000 -> -1.0000000000 + +-- subnormals and overflows covered under Add + +-- Null tests +ddsub9990 subtract 10 # -> NaN Invalid_operation +ddsub9991 subtract # 10 -> NaN Invalid_operation Added: python/branches/release25-maint/Lib/test/decimaltestdata/ddToIntegral.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/ddToIntegral.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,257 @@ +------------------------------------------------------------------------ +-- ddToIntegral.decTest -- round Double to integral value -- +-- Copyright (c) IBM Corporation, 2001, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- This set of tests tests the extended specification 'round-to-integral +-- value-exact' operations (from IEEE 854, later modified in 754r). +-- All non-zero results are defined as being those from either copy or +-- quantize, so those are assumed to have been tested extensively +-- elsewhere; the tests here are for integrity, rounding mode, etc. +-- Also, it is assumed the test harness will use these tests for both +-- ToIntegralExact (which does set Inexact) and the fixed-name +-- functions (which do not set Inexact). + +-- Note that decNumber implements an earlier definition of toIntegral +-- which never sets Inexact; the decTest operator for that is called +-- 'tointegral' instead of 'tointegralx'. + +precision: 16 +maxExponent: 384 +minExponent: -383 +extended: 1 +clamp: 1 +rounding: half_even + +ddintx001 tointegralx 0 -> 0 +ddintx002 tointegralx 0.0 -> 0 +ddintx003 tointegralx 0.1 -> 0 Inexact Rounded +ddintx004 tointegralx 0.2 -> 0 Inexact Rounded +ddintx005 tointegralx 0.3 -> 0 Inexact Rounded +ddintx006 tointegralx 0.4 -> 0 Inexact Rounded +ddintx007 tointegralx 0.5 -> 0 Inexact Rounded +ddintx008 tointegralx 0.6 -> 1 Inexact Rounded +ddintx009 tointegralx 0.7 -> 1 Inexact Rounded +ddintx010 tointegralx 0.8 -> 1 Inexact Rounded +ddintx011 tointegralx 0.9 -> 1 Inexact Rounded +ddintx012 tointegralx 1 -> 1 +ddintx013 tointegralx 1.0 -> 1 Rounded +ddintx014 tointegralx 1.1 -> 1 Inexact Rounded +ddintx015 tointegralx 1.2 -> 1 Inexact Rounded +ddintx016 tointegralx 1.3 -> 1 Inexact Rounded +ddintx017 tointegralx 1.4 -> 1 Inexact Rounded +ddintx018 tointegralx 1.5 -> 2 Inexact Rounded +ddintx019 tointegralx 1.6 -> 2 Inexact Rounded +ddintx020 tointegralx 1.7 -> 2 Inexact Rounded +ddintx021 tointegralx 1.8 -> 2 Inexact Rounded +ddintx022 tointegralx 1.9 -> 2 Inexact Rounded +-- negatives +ddintx031 tointegralx -0 -> -0 +ddintx032 tointegralx -0.0 -> -0 +ddintx033 tointegralx -0.1 -> -0 Inexact Rounded +ddintx034 tointegralx -0.2 -> -0 Inexact Rounded +ddintx035 tointegralx -0.3 -> -0 Inexact Rounded +ddintx036 tointegralx -0.4 -> -0 Inexact Rounded +ddintx037 tointegralx -0.5 -> -0 Inexact Rounded +ddintx038 tointegralx -0.6 -> -1 Inexact Rounded +ddintx039 tointegralx -0.7 -> -1 Inexact Rounded +ddintx040 tointegralx -0.8 -> -1 Inexact Rounded +ddintx041 tointegralx -0.9 -> -1 Inexact Rounded +ddintx042 tointegralx -1 -> -1 +ddintx043 tointegralx -1.0 -> -1 Rounded +ddintx044 tointegralx -1.1 -> -1 Inexact Rounded +ddintx045 tointegralx -1.2 -> -1 Inexact Rounded +ddintx046 tointegralx -1.3 -> -1 Inexact Rounded +ddintx047 tointegralx -1.4 -> -1 Inexact Rounded +ddintx048 tointegralx -1.5 -> -2 Inexact Rounded +ddintx049 tointegralx -1.6 -> -2 Inexact Rounded +ddintx050 tointegralx -1.7 -> -2 Inexact Rounded +ddintx051 tointegralx -1.8 -> -2 Inexact Rounded +ddintx052 tointegralx -1.9 -> -2 Inexact Rounded +-- next two would be NaN using quantize(x, 0) +ddintx053 tointegralx 10E+60 -> 1.0E+61 +ddintx054 tointegralx -10E+60 -> -1.0E+61 + +-- numbers around precision +ddintx060 tointegralx '56267E-17' -> '0' Inexact Rounded +ddintx061 tointegralx '56267E-5' -> '1' Inexact Rounded +ddintx062 tointegralx '56267E-2' -> '563' Inexact Rounded +ddintx063 tointegralx '56267E-1' -> '5627' Inexact Rounded +ddintx065 tointegralx '56267E-0' -> '56267' +ddintx066 tointegralx '56267E+0' -> '56267' +ddintx067 tointegralx '56267E+1' -> '5.6267E+5' +ddintx068 tointegralx '56267E+9' -> '5.6267E+13' +ddintx069 tointegralx '56267E+10' -> '5.6267E+14' +ddintx070 tointegralx '56267E+11' -> '5.6267E+15' +ddintx071 tointegralx '56267E+12' -> '5.6267E+16' +ddintx072 tointegralx '56267E+13' -> '5.6267E+17' +ddintx073 tointegralx '1.23E+96' -> '1.23E+96' +ddintx074 tointegralx '1.23E+384' -> #47fd300000000000 Clamped + +ddintx080 tointegralx '-56267E-10' -> '-0' Inexact Rounded +ddintx081 tointegralx '-56267E-5' -> '-1' Inexact Rounded +ddintx082 tointegralx '-56267E-2' -> '-563' Inexact Rounded +ddintx083 tointegralx '-56267E-1' -> '-5627' Inexact Rounded +ddintx085 tointegralx '-56267E-0' -> '-56267' +ddintx086 tointegralx '-56267E+0' -> '-56267' +ddintx087 tointegralx '-56267E+1' -> '-5.6267E+5' +ddintx088 tointegralx '-56267E+9' -> '-5.6267E+13' +ddintx089 tointegralx '-56267E+10' -> '-5.6267E+14' +ddintx090 tointegralx '-56267E+11' -> '-5.6267E+15' +ddintx091 tointegralx '-56267E+12' -> '-5.6267E+16' +ddintx092 tointegralx '-56267E+13' -> '-5.6267E+17' +ddintx093 tointegralx '-1.23E+96' -> '-1.23E+96' +ddintx094 tointegralx '-1.23E+384' -> #c7fd300000000000 Clamped + +-- subnormal inputs +ddintx100 tointegralx 1E-299 -> 0 Inexact Rounded +ddintx101 tointegralx 0.1E-299 -> 0 Inexact Rounded +ddintx102 tointegralx 0.01E-299 -> 0 Inexact Rounded +ddintx103 tointegralx 0E-299 -> 0 + +-- specials and zeros +ddintx120 tointegralx 'Inf' -> Infinity +ddintx121 tointegralx '-Inf' -> -Infinity +ddintx122 tointegralx NaN -> NaN +ddintx123 tointegralx sNaN -> NaN Invalid_operation +ddintx124 tointegralx 0 -> 0 +ddintx125 tointegralx -0 -> -0 +ddintx126 tointegralx 0.000 -> 0 +ddintx127 tointegralx 0.00 -> 0 +ddintx128 tointegralx 0.0 -> 0 +ddintx129 tointegralx 0 -> 0 +ddintx130 tointegralx 0E-3 -> 0 +ddintx131 tointegralx 0E-2 -> 0 +ddintx132 tointegralx 0E-1 -> 0 +ddintx133 tointegralx 0E-0 -> 0 +ddintx134 tointegralx 0E+1 -> 0E+1 +ddintx135 tointegralx 0E+2 -> 0E+2 +ddintx136 tointegralx 0E+3 -> 0E+3 +ddintx137 tointegralx 0E+4 -> 0E+4 +ddintx138 tointegralx 0E+5 -> 0E+5 +ddintx139 tointegralx -0.000 -> -0 +ddintx140 tointegralx -0.00 -> -0 +ddintx141 tointegralx -0.0 -> -0 +ddintx142 tointegralx -0 -> -0 +ddintx143 tointegralx -0E-3 -> -0 +ddintx144 tointegralx -0E-2 -> -0 +ddintx145 tointegralx -0E-1 -> -0 +ddintx146 tointegralx -0E-0 -> -0 +ddintx147 tointegralx -0E+1 -> -0E+1 +ddintx148 tointegralx -0E+2 -> -0E+2 +ddintx149 tointegralx -0E+3 -> -0E+3 +ddintx150 tointegralx -0E+4 -> -0E+4 +ddintx151 tointegralx -0E+5 -> -0E+5 +-- propagating NaNs +ddintx152 tointegralx NaN808 -> NaN808 +ddintx153 tointegralx sNaN080 -> NaN80 Invalid_operation +ddintx154 tointegralx -NaN808 -> -NaN808 +ddintx155 tointegralx -sNaN080 -> -NaN80 Invalid_operation +ddintx156 tointegralx -NaN -> -NaN +ddintx157 tointegralx -sNaN -> -NaN Invalid_operation + +-- examples +rounding: half_up +ddintx200 tointegralx 2.1 -> 2 Inexact Rounded +ddintx201 tointegralx 100 -> 100 +ddintx202 tointegralx 100.0 -> 100 Rounded +ddintx203 tointegralx 101.5 -> 102 Inexact Rounded +ddintx204 tointegralx -101.5 -> -102 Inexact Rounded +ddintx205 tointegralx 10E+5 -> 1.0E+6 +ddintx206 tointegralx 7.89E+77 -> 7.89E+77 +ddintx207 tointegralx -Inf -> -Infinity + + +-- all rounding modes +rounding: half_even +ddintx210 tointegralx 55.5 -> 56 Inexact Rounded +ddintx211 tointegralx 56.5 -> 56 Inexact Rounded +ddintx212 tointegralx 57.5 -> 58 Inexact Rounded +ddintx213 tointegralx -55.5 -> -56 Inexact Rounded +ddintx214 tointegralx -56.5 -> -56 Inexact Rounded +ddintx215 tointegralx -57.5 -> -58 Inexact Rounded + +rounding: half_up + +ddintx220 tointegralx 55.5 -> 56 Inexact Rounded +ddintx221 tointegralx 56.5 -> 57 Inexact Rounded +ddintx222 tointegralx 57.5 -> 58 Inexact Rounded +ddintx223 tointegralx -55.5 -> -56 Inexact Rounded +ddintx224 tointegralx -56.5 -> -57 Inexact Rounded +ddintx225 tointegralx -57.5 -> -58 Inexact Rounded + +rounding: half_down + +ddintx230 tointegralx 55.5 -> 55 Inexact Rounded +ddintx231 tointegralx 56.5 -> 56 Inexact Rounded +ddintx232 tointegralx 57.5 -> 57 Inexact Rounded +ddintx233 tointegralx -55.5 -> -55 Inexact Rounded +ddintx234 tointegralx -56.5 -> -56 Inexact Rounded +ddintx235 tointegralx -57.5 -> -57 Inexact Rounded + +rounding: up + +ddintx240 tointegralx 55.3 -> 56 Inexact Rounded +ddintx241 tointegralx 56.3 -> 57 Inexact Rounded +ddintx242 tointegralx 57.3 -> 58 Inexact Rounded +ddintx243 tointegralx -55.3 -> -56 Inexact Rounded +ddintx244 tointegralx -56.3 -> -57 Inexact Rounded +ddintx245 tointegralx -57.3 -> -58 Inexact Rounded + +rounding: down + +ddintx250 tointegralx 55.7 -> 55 Inexact Rounded +ddintx251 tointegralx 56.7 -> 56 Inexact Rounded +ddintx252 tointegralx 57.7 -> 57 Inexact Rounded +ddintx253 tointegralx -55.7 -> -55 Inexact Rounded +ddintx254 tointegralx -56.7 -> -56 Inexact Rounded +ddintx255 tointegralx -57.7 -> -57 Inexact Rounded + +rounding: ceiling + +ddintx260 tointegralx 55.3 -> 56 Inexact Rounded +ddintx261 tointegralx 56.3 -> 57 Inexact Rounded +ddintx262 tointegralx 57.3 -> 58 Inexact Rounded +ddintx263 tointegralx -55.3 -> -55 Inexact Rounded +ddintx264 tointegralx -56.3 -> -56 Inexact Rounded +ddintx265 tointegralx -57.3 -> -57 Inexact Rounded + +rounding: floor + +ddintx270 tointegralx 55.7 -> 55 Inexact Rounded +ddintx271 tointegralx 56.7 -> 56 Inexact Rounded +ddintx272 tointegralx 57.7 -> 57 Inexact Rounded +ddintx273 tointegralx -55.7 -> -56 Inexact Rounded +ddintx274 tointegralx -56.7 -> -57 Inexact Rounded +ddintx275 tointegralx -57.7 -> -58 Inexact Rounded + +-- Int and uInt32 edge values for testing conversions +ddintx300 tointegralx -2147483646 -> -2147483646 +ddintx301 tointegralx -2147483647 -> -2147483647 +ddintx302 tointegralx -2147483648 -> -2147483648 +ddintx303 tointegralx -2147483649 -> -2147483649 +ddintx304 tointegralx 2147483646 -> 2147483646 +ddintx305 tointegralx 2147483647 -> 2147483647 +ddintx306 tointegralx 2147483648 -> 2147483648 +ddintx307 tointegralx 2147483649 -> 2147483649 +ddintx308 tointegralx 4294967294 -> 4294967294 +ddintx309 tointegralx 4294967295 -> 4294967295 +ddintx310 tointegralx 4294967296 -> 4294967296 +ddintx311 tointegralx 4294967297 -> 4294967297 + Added: python/branches/release25-maint/Lib/test/decimaltestdata/ddXor.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/ddXor.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,337 @@ +------------------------------------------------------------------------ +-- ddXor.decTest -- digitwise logical XOR for decDoubles -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +precision: 16 +maxExponent: 384 +minExponent: -383 +extended: 1 +clamp: 1 +rounding: half_even + +-- Sanity check (truth table) +ddxor001 xor 0 0 -> 0 +ddxor002 xor 0 1 -> 1 +ddxor003 xor 1 0 -> 1 +ddxor004 xor 1 1 -> 0 +ddxor005 xor 1100 1010 -> 110 +-- and at msd and msd-1 +ddxor006 xor 0000000000000000 0000000000000000 -> 0 +ddxor007 xor 0000000000000000 1000000000000000 -> 1000000000000000 +ddxor008 xor 1000000000000000 0000000000000000 -> 1000000000000000 +ddxor009 xor 1000000000000000 1000000000000000 -> 0 +ddxor010 xor 0000000000000000 0000000000000000 -> 0 +ddxor011 xor 0000000000000000 0100000000000000 -> 100000000000000 +ddxor012 xor 0100000000000000 0000000000000000 -> 100000000000000 +ddxor013 xor 0100000000000000 0100000000000000 -> 0 + +-- Various lengths +-- 1234567890123456 1234567890123456 1234567890123456 +ddxor021 xor 1111111110000000 1111111110000000 -> 0 +ddxor022 xor 111111110000000 111111110000000 -> 0 +ddxor023 xor 11111110000000 11111110000000 -> 0 +ddxor024 xor 1111110000000 1111110000000 -> 0 +ddxor025 xor 111110000000 111110000000 -> 0 +ddxor026 xor 11110000000 11110000000 -> 0 +ddxor027 xor 1110000000 1110000000 -> 0 +ddxor028 xor 110000000 110000000 -> 0 +ddxor029 xor 10000000 10000000 -> 0 +ddxor030 xor 1000000 1000000 -> 0 +ddxor031 xor 100000 100000 -> 0 +ddxor032 xor 10000 10000 -> 0 +ddxor033 xor 1000 1000 -> 0 +ddxor034 xor 100 100 -> 0 +ddxor035 xor 10 10 -> 0 +ddxor036 xor 1 1 -> 0 + +ddxor040 xor 111111111 111111111111 -> 111000000000 +ddxor041 xor 11111111 111111111111 -> 111100000000 +ddxor042 xor 11111111 111111111 -> 100000000 +ddxor043 xor 1111111 100000010 -> 101111101 +ddxor044 xor 111111 100000100 -> 100111011 +ddxor045 xor 11111 100001000 -> 100010111 +ddxor046 xor 1111 100010000 -> 100011111 +ddxor047 xor 111 100100000 -> 100100111 +ddxor048 xor 11 101000000 -> 101000011 +ddxor049 xor 1 110000000 -> 110000001 + +ddxor050 xor 1111111111 1 -> 1111111110 +ddxor051 xor 111111111 1 -> 111111110 +ddxor052 xor 11111111 1 -> 11111110 +ddxor053 xor 1111111 1 -> 1111110 +ddxor054 xor 111111 1 -> 111110 +ddxor055 xor 11111 1 -> 11110 +ddxor056 xor 1111 1 -> 1110 +ddxor057 xor 111 1 -> 110 +ddxor058 xor 11 1 -> 10 +ddxor059 xor 1 1 -> 0 + +ddxor060 xor 1111111111 0 -> 1111111111 +ddxor061 xor 111111111 0 -> 111111111 +ddxor062 xor 11111111 0 -> 11111111 +ddxor063 xor 1111111 0 -> 1111111 +ddxor064 xor 111111 0 -> 111111 +ddxor065 xor 11111 0 -> 11111 +ddxor066 xor 1111 0 -> 1111 +ddxor067 xor 111 0 -> 111 +ddxor068 xor 11 0 -> 11 +ddxor069 xor 1 0 -> 1 + +ddxor070 xor 1 1111111111 -> 1111111110 +ddxor071 xor 1 111111111 -> 111111110 +ddxor072 xor 1 11111111 -> 11111110 +ddxor073 xor 1 1111111 -> 1111110 +ddxor074 xor 1 111111 -> 111110 +ddxor075 xor 1 11111 -> 11110 +ddxor076 xor 1 1111 -> 1110 +ddxor077 xor 1 111 -> 110 +ddxor078 xor 1 11 -> 10 +ddxor079 xor 1 1 -> 0 + +ddxor080 xor 0 1111111111 -> 1111111111 +ddxor081 xor 0 111111111 -> 111111111 +ddxor082 xor 0 11111111 -> 11111111 +ddxor083 xor 0 1111111 -> 1111111 +ddxor084 xor 0 111111 -> 111111 +ddxor085 xor 0 11111 -> 11111 +ddxor086 xor 0 1111 -> 1111 +ddxor087 xor 0 111 -> 111 +ddxor088 xor 0 11 -> 11 +ddxor089 xor 0 1 -> 1 + +ddxor090 xor 011111111 111101111 -> 100010000 +ddxor091 xor 101111111 111101111 -> 10010000 +ddxor092 xor 110111111 111101111 -> 1010000 +ddxor093 xor 111011111 111101111 -> 110000 +ddxor094 xor 111101111 111101111 -> 0 +ddxor095 xor 111110111 111101111 -> 11000 +ddxor096 xor 111111011 111101111 -> 10100 +ddxor097 xor 111111101 111101111 -> 10010 +ddxor098 xor 111111110 111101111 -> 10001 + +ddxor100 xor 111101111 011111111 -> 100010000 +ddxor101 xor 111101111 101111111 -> 10010000 +ddxor102 xor 111101111 110111111 -> 1010000 +ddxor103 xor 111101111 111011111 -> 110000 +ddxor104 xor 111101111 111101111 -> 0 +ddxor105 xor 111101111 111110111 -> 11000 +ddxor106 xor 111101111 111111011 -> 10100 +ddxor107 xor 111101111 111111101 -> 10010 +ddxor108 xor 111101111 111111110 -> 10001 + +-- non-0/1 should not be accepted, nor should signs +ddxor220 xor 111111112 111111111 -> NaN Invalid_operation +ddxor221 xor 333333333 333333333 -> NaN Invalid_operation +ddxor222 xor 555555555 555555555 -> NaN Invalid_operation +ddxor223 xor 777777777 777777777 -> NaN Invalid_operation +ddxor224 xor 999999999 999999999 -> NaN Invalid_operation +ddxor225 xor 222222222 999999999 -> NaN Invalid_operation +ddxor226 xor 444444444 999999999 -> NaN Invalid_operation +ddxor227 xor 666666666 999999999 -> NaN Invalid_operation +ddxor228 xor 888888888 999999999 -> NaN Invalid_operation +ddxor229 xor 999999999 222222222 -> NaN Invalid_operation +ddxor230 xor 999999999 444444444 -> NaN Invalid_operation +ddxor231 xor 999999999 666666666 -> NaN Invalid_operation +ddxor232 xor 999999999 888888888 -> NaN Invalid_operation +-- a few randoms +ddxor240 xor 567468689 -934981942 -> NaN Invalid_operation +ddxor241 xor 567367689 934981942 -> NaN Invalid_operation +ddxor242 xor -631917772 -706014634 -> NaN Invalid_operation +ddxor243 xor -756253257 138579234 -> NaN Invalid_operation +ddxor244 xor 835590149 567435400 -> NaN Invalid_operation +-- test MSD +ddxor250 xor 2000000000000000 1000000000000000 -> NaN Invalid_operation +ddxor251 xor 7000000000000000 1000000000000000 -> NaN Invalid_operation +ddxor252 xor 8000000000000000 1000000000000000 -> NaN Invalid_operation +ddxor253 xor 9000000000000000 1000000000000000 -> NaN Invalid_operation +ddxor254 xor 2000000000000000 0000000000000000 -> NaN Invalid_operation +ddxor255 xor 7000000000000000 0000000000000000 -> NaN Invalid_operation +ddxor256 xor 8000000000000000 0000000000000000 -> NaN Invalid_operation +ddxor257 xor 9000000000000000 0000000000000000 -> NaN Invalid_operation +ddxor258 xor 1000000000000000 2000000000000000 -> NaN Invalid_operation +ddxor259 xor 1000000000000000 7000000000000000 -> NaN Invalid_operation +ddxor260 xor 1000000000000000 8000000000000000 -> NaN Invalid_operation +ddxor261 xor 1000000000000000 9000000000000000 -> NaN Invalid_operation +ddxor262 xor 0000000000000000 2000000000000000 -> NaN Invalid_operation +ddxor263 xor 0000000000000000 7000000000000000 -> NaN Invalid_operation +ddxor264 xor 0000000000000000 8000000000000000 -> NaN Invalid_operation +ddxor265 xor 0000000000000000 9000000000000000 -> NaN Invalid_operation +-- test MSD-1 +ddxor270 xor 0200001000000000 1000100000000010 -> NaN Invalid_operation +ddxor271 xor 0700000100000000 1000010000000100 -> NaN Invalid_operation +ddxor272 xor 0800000010000000 1000001000001000 -> NaN Invalid_operation +ddxor273 xor 0900000001000000 1000000100010000 -> NaN Invalid_operation +ddxor274 xor 1000000000100000 0200000010100000 -> NaN Invalid_operation +ddxor275 xor 1000000000010000 0700000001000000 -> NaN Invalid_operation +ddxor276 xor 1000000000001000 0800000010100000 -> NaN Invalid_operation +ddxor277 xor 1000000000000100 0900000000010000 -> NaN Invalid_operation +-- test LSD +ddxor280 xor 0010000000000002 1000000100000001 -> NaN Invalid_operation +ddxor281 xor 0001000000000007 1000001000000011 -> NaN Invalid_operation +ddxor282 xor 0000100000000008 1000010000000001 -> NaN Invalid_operation +ddxor283 xor 0000010000000009 1000100000000001 -> NaN Invalid_operation +ddxor284 xor 1000001000000000 0001000000000002 -> NaN Invalid_operation +ddxor285 xor 1000000100000000 0010000000000007 -> NaN Invalid_operation +ddxor286 xor 1000000010000000 0100000000000008 -> NaN Invalid_operation +ddxor287 xor 1000000001000000 1000000000000009 -> NaN Invalid_operation +-- test Middie +ddxor288 xor 0010000020000000 1000001000000000 -> NaN Invalid_operation +ddxor289 xor 0001000070000001 1000000100000000 -> NaN Invalid_operation +ddxor290 xor 0000100080000010 1000000010000000 -> NaN Invalid_operation +ddxor291 xor 0000010090000100 1000000001000000 -> NaN Invalid_operation +ddxor292 xor 1000001000001000 0000000020100000 -> NaN Invalid_operation +ddxor293 xor 1000000100010000 0000000070010000 -> NaN Invalid_operation +ddxor294 xor 1000000010100000 0000000080001000 -> NaN Invalid_operation +ddxor295 xor 1000000001000000 0000000090000100 -> NaN Invalid_operation +-- signs +ddxor296 xor -1000000001000000 -0000010000000100 -> NaN Invalid_operation +ddxor297 xor -1000000001000000 0000000010000100 -> NaN Invalid_operation +ddxor298 xor 1000000001000000 -0000001000000100 -> NaN Invalid_operation +ddxor299 xor 1000000001000000 0000000011000100 -> 1000000010000100 + +-- Nmax, Nmin, Ntiny-like +ddxor331 xor 2 9.99999999E+299 -> NaN Invalid_operation +ddxor332 xor 3 1E-299 -> NaN Invalid_operation +ddxor333 xor 4 1.00000000E-299 -> NaN Invalid_operation +ddxor334 xor 5 1E-200 -> NaN Invalid_operation +ddxor335 xor 6 -1E-200 -> NaN Invalid_operation +ddxor336 xor 7 -1.00000000E-299 -> NaN Invalid_operation +ddxor337 xor 8 -1E-299 -> NaN Invalid_operation +ddxor338 xor 9 -9.99999999E+299 -> NaN Invalid_operation +ddxor341 xor 9.99999999E+299 -18 -> NaN Invalid_operation +ddxor342 xor 1E-299 01 -> NaN Invalid_operation +ddxor343 xor 1.00000000E-299 -18 -> NaN Invalid_operation +ddxor344 xor 1E-208 18 -> NaN Invalid_operation +ddxor345 xor -1E-207 -10 -> NaN Invalid_operation +ddxor346 xor -1.00000000E-299 18 -> NaN Invalid_operation +ddxor347 xor -1E-299 10 -> NaN Invalid_operation +ddxor348 xor -9.99999999E+299 -18 -> NaN Invalid_operation + +-- A few other non-integers +ddxor361 xor 1.0 1 -> NaN Invalid_operation +ddxor362 xor 1E+1 1 -> NaN Invalid_operation +ddxor363 xor 0.0 1 -> NaN Invalid_operation +ddxor364 xor 0E+1 1 -> NaN Invalid_operation +ddxor365 xor 9.9 1 -> NaN Invalid_operation +ddxor366 xor 9E+1 1 -> NaN Invalid_operation +ddxor371 xor 0 1.0 -> NaN Invalid_operation +ddxor372 xor 0 1E+1 -> NaN Invalid_operation +ddxor373 xor 0 0.0 -> NaN Invalid_operation +ddxor374 xor 0 0E+1 -> NaN Invalid_operation +ddxor375 xor 0 9.9 -> NaN Invalid_operation +ddxor376 xor 0 9E+1 -> NaN Invalid_operation + +-- All Specials are in error +ddxor780 xor -Inf -Inf -> NaN Invalid_operation +ddxor781 xor -Inf -1000 -> NaN Invalid_operation +ddxor782 xor -Inf -1 -> NaN Invalid_operation +ddxor783 xor -Inf -0 -> NaN Invalid_operation +ddxor784 xor -Inf 0 -> NaN Invalid_operation +ddxor785 xor -Inf 1 -> NaN Invalid_operation +ddxor786 xor -Inf 1000 -> NaN Invalid_operation +ddxor787 xor -1000 -Inf -> NaN Invalid_operation +ddxor788 xor -Inf -Inf -> NaN Invalid_operation +ddxor789 xor -1 -Inf -> NaN Invalid_operation +ddxor790 xor -0 -Inf -> NaN Invalid_operation +ddxor791 xor 0 -Inf -> NaN Invalid_operation +ddxor792 xor 1 -Inf -> NaN Invalid_operation +ddxor793 xor 1000 -Inf -> NaN Invalid_operation +ddxor794 xor Inf -Inf -> NaN Invalid_operation + +ddxor800 xor Inf -Inf -> NaN Invalid_operation +ddxor801 xor Inf -1000 -> NaN Invalid_operation +ddxor802 xor Inf -1 -> NaN Invalid_operation +ddxor803 xor Inf -0 -> NaN Invalid_operation +ddxor804 xor Inf 0 -> NaN Invalid_operation +ddxor805 xor Inf 1 -> NaN Invalid_operation +ddxor806 xor Inf 1000 -> NaN Invalid_operation +ddxor807 xor Inf Inf -> NaN Invalid_operation +ddxor808 xor -1000 Inf -> NaN Invalid_operation +ddxor809 xor -Inf Inf -> NaN Invalid_operation +ddxor810 xor -1 Inf -> NaN Invalid_operation +ddxor811 xor -0 Inf -> NaN Invalid_operation +ddxor812 xor 0 Inf -> NaN Invalid_operation +ddxor813 xor 1 Inf -> NaN Invalid_operation +ddxor814 xor 1000 Inf -> NaN Invalid_operation +ddxor815 xor Inf Inf -> NaN Invalid_operation + +ddxor821 xor NaN -Inf -> NaN Invalid_operation +ddxor822 xor NaN -1000 -> NaN Invalid_operation +ddxor823 xor NaN -1 -> NaN Invalid_operation +ddxor824 xor NaN -0 -> NaN Invalid_operation +ddxor825 xor NaN 0 -> NaN Invalid_operation +ddxor826 xor NaN 1 -> NaN Invalid_operation +ddxor827 xor NaN 1000 -> NaN Invalid_operation +ddxor828 xor NaN Inf -> NaN Invalid_operation +ddxor829 xor NaN NaN -> NaN Invalid_operation +ddxor830 xor -Inf NaN -> NaN Invalid_operation +ddxor831 xor -1000 NaN -> NaN Invalid_operation +ddxor832 xor -1 NaN -> NaN Invalid_operation +ddxor833 xor -0 NaN -> NaN Invalid_operation +ddxor834 xor 0 NaN -> NaN Invalid_operation +ddxor835 xor 1 NaN -> NaN Invalid_operation +ddxor836 xor 1000 NaN -> NaN Invalid_operation +ddxor837 xor Inf NaN -> NaN Invalid_operation + +ddxor841 xor sNaN -Inf -> NaN Invalid_operation +ddxor842 xor sNaN -1000 -> NaN Invalid_operation +ddxor843 xor sNaN -1 -> NaN Invalid_operation +ddxor844 xor sNaN -0 -> NaN Invalid_operation +ddxor845 xor sNaN 0 -> NaN Invalid_operation +ddxor846 xor sNaN 1 -> NaN Invalid_operation +ddxor847 xor sNaN 1000 -> NaN Invalid_operation +ddxor848 xor sNaN NaN -> NaN Invalid_operation +ddxor849 xor sNaN sNaN -> NaN Invalid_operation +ddxor850 xor NaN sNaN -> NaN Invalid_operation +ddxor851 xor -Inf sNaN -> NaN Invalid_operation +ddxor852 xor -1000 sNaN -> NaN Invalid_operation +ddxor853 xor -1 sNaN -> NaN Invalid_operation +ddxor854 xor -0 sNaN -> NaN Invalid_operation +ddxor855 xor 0 sNaN -> NaN Invalid_operation +ddxor856 xor 1 sNaN -> NaN Invalid_operation +ddxor857 xor 1000 sNaN -> NaN Invalid_operation +ddxor858 xor Inf sNaN -> NaN Invalid_operation +ddxor859 xor NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +ddxor861 xor NaN1 -Inf -> NaN Invalid_operation +ddxor862 xor +NaN2 -1000 -> NaN Invalid_operation +ddxor863 xor NaN3 1000 -> NaN Invalid_operation +ddxor864 xor NaN4 Inf -> NaN Invalid_operation +ddxor865 xor NaN5 +NaN6 -> NaN Invalid_operation +ddxor866 xor -Inf NaN7 -> NaN Invalid_operation +ddxor867 xor -1000 NaN8 -> NaN Invalid_operation +ddxor868 xor 1000 NaN9 -> NaN Invalid_operation +ddxor869 xor Inf +NaN10 -> NaN Invalid_operation +ddxor871 xor sNaN11 -Inf -> NaN Invalid_operation +ddxor872 xor sNaN12 -1000 -> NaN Invalid_operation +ddxor873 xor sNaN13 1000 -> NaN Invalid_operation +ddxor874 xor sNaN14 NaN17 -> NaN Invalid_operation +ddxor875 xor sNaN15 sNaN18 -> NaN Invalid_operation +ddxor876 xor NaN16 sNaN19 -> NaN Invalid_operation +ddxor877 xor -Inf +sNaN20 -> NaN Invalid_operation +ddxor878 xor -1000 sNaN21 -> NaN Invalid_operation +ddxor879 xor 1000 sNaN22 -> NaN Invalid_operation +ddxor880 xor Inf sNaN23 -> NaN Invalid_operation +ddxor881 xor +NaN25 +sNaN24 -> NaN Invalid_operation +ddxor882 xor -NaN26 NaN28 -> NaN Invalid_operation +ddxor883 xor -sNaN27 sNaN29 -> NaN Invalid_operation +ddxor884 xor 1000 -NaN30 -> NaN Invalid_operation +ddxor885 xor 1000 -sNaN31 -> NaN Invalid_operation Added: python/branches/release25-maint/Lib/test/decimaltestdata/decDouble.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/decDouble.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,65 @@ +------------------------------------------------------------------------ +-- decDouble.decTest -- run all decDouble decimal arithmetic tests -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- decDouble tests +dectest: ddAbs +dectest: ddAdd +dectest: ddAnd +dectest: ddBase +dectest: ddCanonical +dectest: ddClass +dectest: ddCompare +dectest: ddCompareSig +dectest: ddCompareTotal +dectest: ddCompareTotalMag +dectest: ddCopy +dectest: ddCopyAbs +dectest: ddCopyNegate +dectest: ddCopySign +dectest: ddDivide +dectest: ddDivideInt +dectest: ddEncode +dectest: ddFMA +dectest: ddInvert +dectest: ddLogB +dectest: ddMax +dectest: ddMaxMag +dectest: ddMin +dectest: ddMinMag +dectest: ddMinus +dectest: ddMultiply +dectest: ddNextMinus +dectest: ddNextPlus +dectest: ddNextToward +dectest: ddOr +dectest: ddPlus +dectest: ddQuantize +dectest: ddReduce +dectest: ddRemainder +dectest: ddRemainderNear +dectest: ddRotate +dectest: ddSameQuantum +dectest: ddScaleB +dectest: ddShift +dectest: ddSubtract +dectest: ddToIntegral +dectest: ddXor + Added: python/branches/release25-maint/Lib/test/decimaltestdata/decQuad.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/decQuad.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,65 @@ +------------------------------------------------------------------------ +-- decQuad.decTest -- run all decQuad decimal arithmetic tests -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- decQuad tests +dectest: dqAbs +dectest: dqAdd +dectest: dqAnd +dectest: dqBase +dectest: dqCanonical +dectest: dqClass +dectest: dqCompare +dectest: dqCompareSig +dectest: dqCompareTotal +dectest: dqCompareTotalMag +dectest: dqCopy +dectest: dqCopyAbs +dectest: dqCopyNegate +dectest: dqCopySign +dectest: dqDivide +dectest: dqDivideInt +dectest: dqEncode +dectest: dqFMA +dectest: dqInvert +dectest: dqLogB +dectest: dqMax +dectest: dqMaxMag +dectest: dqMin +dectest: dqMinMag +dectest: dqMinus +dectest: dqMultiply +dectest: dqNextMinus +dectest: dqNextPlus +dectest: dqNextToward +dectest: dqOr +dectest: dqPlus +dectest: dqQuantize +dectest: dqReduce +dectest: dqRemainder +dectest: dqRemainderNear +dectest: dqRotate +dectest: dqSameQuantum +dectest: dqScaleB +dectest: dqShift +dectest: dqSubtract +dectest: dqToIntegral +dectest: dqXor + Added: python/branches/release25-maint/Lib/test/decimaltestdata/decSingle.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/decSingle.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,25 @@ +------------------------------------------------------------------------ +-- decSingle.decTest -- run all decSingle decimal arithmetic tests -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- decSingle tests +dectest: dsBase +dectest: dsEncode + Deleted: /python/branches/release25-maint/Lib/test/decimaltestdata/decimal128.decTest ============================================================================== --- /python/branches/release25-maint/Lib/test/decimaltestdata/decimal128.decTest Tue Jan 8 17:20:31 2008 +++ (empty file) @@ -1,441 +0,0 @@ ------------------------------------------------------------------------- --- decimal128.decTest -- decimal sixteen-byte format testcases -- --- Copyright (c) IBM Corporation, 2000, 2003. All rights reserved. -- ------------------------------------------------------------------------- --- Please see the document "General Decimal Arithmetic Testcases" -- --- at http://www2.hursley.ibm.com/decimal for the description of -- --- these testcases. -- --- -- --- These testcases are experimental ('beta' versions), and they -- --- may contain errors. They are offered on an as-is basis. In -- --- particular, achieving the same results as the tests here is not -- --- a guarantee that an implementation complies with any Standard -- --- or specification. The tests are not exhaustive. -- --- -- --- Please send comments, suggestions, and corrections to the author: -- --- Mike Cowlishaw, IBM Fellow -- --- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- --- mfc at uk.ibm.com -- ------------------------------------------------------------------------- -version: 2.39 - --- This set of tests is for the sixteen-byte concrete representation. --- Its characteristics are: --- --- 1 bit sign --- 5 bits combination field --- 12 bits exponent continuation --- 110 bits coefficient continuation --- --- Total exponent length 14 bits --- Total coefficient length 114 bits (34 digits) --- --- Elimit = 12287 (maximum encoded exponent) --- Emax = 6144 (largest exponent value) --- Emin = -6143 (smallest exponent value) --- bias = 6176 (subtracted from encoded exponent) = -Etiny - -extended: 1 -precision: 34 -rounding: half_up -maxExponent: 6144 -minExponent: -6143 - --- General testcases --- (mostly derived from the Strawman 4 document and examples) -decg001 apply #A20780000000000000000000000003D0 -> -7.50 -decg002 apply -7.50 -> #A20780000000000000000000000003D0 - --- Normality -decf010 apply 1234567890123456789012345678901234 -> #2608134b9c1e28e56f3c127177823534 -decf011 apply 1234567890123456789012345678901234.0 -> #2608134b9c1e28e56f3c127177823534 Rounded -decf012 apply 1234567890123456789012345678901234.1 -> #2608134b9c1e28e56f3c127177823534 Rounded Inexact -decf013 apply -1234567890123456789012345678901234 -> #a608134b9c1e28e56f3c127177823534 -decf014 apply -1234567890123456789012345678901234.0 -> #a608134b9c1e28e56f3c127177823534 Rounded -decf015 apply -1234567890123456789012345678901234.1 -> #a608134b9c1e28e56f3c127177823534 Rounded Inexact - - --- Nmax and similar -decf022 apply 9.999999999999999999999999999999999E+6144 -> #77ffcff3fcff3fcff3fcff3fcff3fcff -decf023 apply #77ffcff3fcff3fcff3fcff3fcff3fcff -> 9.999999999999999999999999999999999E+6144 -decf024 apply 1.234567890123456789012345678901234E+6144 -> #47ffd34b9c1e28e56f3c127177823534 -decf025 apply #47ffd34b9c1e28e56f3c127177823534 -> 1.234567890123456789012345678901234E+6144 --- fold-downs (more below) -decf030 apply 1.23E+6144 -> #47ffd300000000000000000000000000 Clamped -decf031 apply #47ffd300000000000000000000000000 -> 1.230000000000000000000000000000000E+6144 -decf032 apply 1E+6144 -> #47ffc000000000000000000000000000 Clamped -decf033 apply #47ffc000000000000000000000000000 -> 1.000000000000000000000000000000000E+6144 - --- overflows -maxExponent: 9999 -- set high so conversion causes the overflow -minExponent: -9999 -decf040 apply 10E+6144 -> #78000000000000000000000000000000 Overflow Rounded Inexact -decf041 apply 1.000000000000000E+6145 -> #78000000000000000000000000000000 Overflow Rounded Inexact -maxExponent: 6144 -minExponent: -6143 - -decf051 apply 12345 -> #220800000000000000000000000049c5 -decf052 apply #220800000000000000000000000049c5 -> 12345 -decf053 apply 1234 -> #22080000000000000000000000000534 -decf054 apply #22080000000000000000000000000534 -> 1234 -decf055 apply 123 -> #220800000000000000000000000000a3 -decf056 apply #220800000000000000000000000000a3 -> 123 -decf057 apply 12 -> #22080000000000000000000000000012 -decf058 apply #22080000000000000000000000000012 -> 12 -decf059 apply 1 -> #22080000000000000000000000000001 -decf060 apply #22080000000000000000000000000001 -> 1 -decf061 apply 1.23 -> #220780000000000000000000000000a3 -decf062 apply #220780000000000000000000000000a3 -> 1.23 -decf063 apply 123.45 -> #220780000000000000000000000049c5 -decf064 apply #220780000000000000000000000049c5 -> 123.45 - --- Nmin and below -decf071 apply 1E-6143 -> #00084000000000000000000000000001 -decf072 apply #00084000000000000000000000000001 -> 1E-6143 -decf073 apply 1.000000000000000000000000000000000E-6143 -> #04000000000000000000000000000000 -decf074 apply #04000000000000000000000000000000 -> 1.000000000000000000000000000000000E-6143 -decf075 apply 1.000000000000000000000000000000001E-6143 -> #04000000000000000000000000000001 -decf076 apply #04000000000000000000000000000001 -> 1.000000000000000000000000000000001E-6143 - -decf077 apply 0.100000000000000000000000000000000E-6143 -> #00000800000000000000000000000000 Subnormal -decf078 apply #00000800000000000000000000000000 -> 1.00000000000000000000000000000000E-6144 Subnormal -decf079 apply 0.000000000000000000000000000000010E-6143 -> #00000000000000000000000000000010 Subnormal -decf080 apply #00000000000000000000000000000010 -> 1.0E-6175 Subnormal -decf081 apply 0.00000000000000000000000000000001E-6143 -> #00004000000000000000000000000001 Subnormal -decf082 apply #00004000000000000000000000000001 -> 1E-6175 Subnormal -decf083 apply 0.000000000000000000000000000000001E-6143 -> #00000000000000000000000000000001 Subnormal -decf084 apply #00000000000000000000000000000001 -> 1E-6176 Subnormal - --- underflows -decf090 apply 1e-6176 -> #00000000000000000000000000000001 Subnormal -decf091 apply 1.9e-6176 -> #00000000000000000000000000000002 Subnormal Underflow Inexact Rounded -decf092 apply 1.1e-6176 -> #00000000000000000000000000000001 Subnormal Underflow Inexact Rounded -decf093 apply 1.00000000001e-6176 -> #00000000000000000000000000000001 Subnormal Underflow Inexact Rounded -decf094 apply 1.00000000000001e-6176 -> #00000000000000000000000000000001 Subnormal Underflow Inexact Rounded -decf095 apply 1.000000000000001e-6176 -> #00000000000000000000000000000001 Subnormal Underflow Inexact Rounded -decf096 apply 0.1e-6176 -> #00000000000000000000000000000000 Subnormal Underflow Inexact Rounded -decf097 apply 0.00000000001e-6176 -> #00000000000000000000000000000000 Subnormal Underflow Inexact Rounded -decf098 apply 0.00000000000001e-6176 -> #00000000000000000000000000000000 Subnormal Underflow Inexact Rounded -decf099 apply 0.000000000000001e-6176 -> #00000000000000000000000000000000 Subnormal Underflow Inexact Rounded -decf100 apply 999999999999999999999999999999999e-6176 -> #00000ff3fcff3fcff3fcff3fcff3fcff Subnormal - --- same again, negatives --- Nmax and similar -decf122 apply -9.999999999999999999999999999999999E+6144 -> #f7ffcff3fcff3fcff3fcff3fcff3fcff -decf123 apply #f7ffcff3fcff3fcff3fcff3fcff3fcff -> -9.999999999999999999999999999999999E+6144 -decf124 apply -1.234567890123456789012345678901234E+6144 -> #c7ffd34b9c1e28e56f3c127177823534 -decf125 apply #c7ffd34b9c1e28e56f3c127177823534 -> -1.234567890123456789012345678901234E+6144 --- fold-downs (more below) -decf130 apply -1.23E+6144 -> #c7ffd300000000000000000000000000 Clamped -decf131 apply #c7ffd300000000000000000000000000 -> -1.230000000000000000000000000000000E+6144 -decf132 apply -1E+6144 -> #c7ffc000000000000000000000000000 Clamped -decf133 apply #c7ffc000000000000000000000000000 -> -1.000000000000000000000000000000000E+6144 - --- overflows -maxExponent: 9999 -- set high so conversion causes the overflow -minExponent: -9999 -decf140 apply -10E+6144 -> #f8000000000000000000000000000000 Overflow Rounded Inexact -decf141 apply -1.000000000000000E+6145 -> #f8000000000000000000000000000000 Overflow Rounded Inexact -maxExponent: 6144 -minExponent: -6143 - -decf151 apply -12345 -> #a20800000000000000000000000049c5 -decf152 apply #a20800000000000000000000000049c5 -> -12345 -decf153 apply -1234 -> #a2080000000000000000000000000534 -decf154 apply #a2080000000000000000000000000534 -> -1234 -decf155 apply -123 -> #a20800000000000000000000000000a3 -decf156 apply #a20800000000000000000000000000a3 -> -123 -decf157 apply -12 -> #a2080000000000000000000000000012 -decf158 apply #a2080000000000000000000000000012 -> -12 -decf159 apply -1 -> #a2080000000000000000000000000001 -decf160 apply #a2080000000000000000000000000001 -> -1 -decf161 apply -1.23 -> #a20780000000000000000000000000a3 -decf162 apply #a20780000000000000000000000000a3 -> -1.23 -decf163 apply -123.45 -> #a20780000000000000000000000049c5 -decf164 apply #a20780000000000000000000000049c5 -> -123.45 - --- Nmin and below -decf171 apply -1E-6143 -> #80084000000000000000000000000001 -decf172 apply #80084000000000000000000000000001 -> -1E-6143 -decf173 apply -1.000000000000000000000000000000000E-6143 -> #84000000000000000000000000000000 -decf174 apply #84000000000000000000000000000000 -> -1.000000000000000000000000000000000E-6143 -decf175 apply -1.000000000000000000000000000000001E-6143 -> #84000000000000000000000000000001 -decf176 apply #84000000000000000000000000000001 -> -1.000000000000000000000000000000001E-6143 - -decf177 apply -0.100000000000000000000000000000000E-6143 -> #80000800000000000000000000000000 Subnormal -decf178 apply #80000800000000000000000000000000 -> -1.00000000000000000000000000000000E-6144 Subnormal -decf179 apply -0.000000000000000000000000000000010E-6143 -> #80000000000000000000000000000010 Subnormal -decf180 apply #80000000000000000000000000000010 -> -1.0E-6175 Subnormal -decf181 apply -0.00000000000000000000000000000001E-6143 -> #80004000000000000000000000000001 Subnormal -decf182 apply #80004000000000000000000000000001 -> -1E-6175 Subnormal -decf183 apply -0.000000000000000000000000000000001E-6143 -> #80000000000000000000000000000001 Subnormal -decf184 apply #80000000000000000000000000000001 -> -1E-6176 Subnormal - --- underflows -decf190 apply -1e-6176 -> #80000000000000000000000000000001 Subnormal -decf191 apply -1.9e-6176 -> #80000000000000000000000000000002 Subnormal Underflow Inexact Rounded -decf192 apply -1.1e-6176 -> #80000000000000000000000000000001 Subnormal Underflow Inexact Rounded -decf193 apply -1.00000000001e-6176 -> #80000000000000000000000000000001 Subnormal Underflow Inexact Rounded -decf194 apply -1.00000000000001e-6176 -> #80000000000000000000000000000001 Subnormal Underflow Inexact Rounded -decf195 apply -1.000000000000001e-6176 -> #80000000000000000000000000000001 Subnormal Underflow Inexact Rounded -decf196 apply -0.1e-6176 -> #80000000000000000000000000000000 Subnormal Underflow Inexact Rounded -decf197 apply -0.00000000001e-6176 -> #80000000000000000000000000000000 Subnormal Underflow Inexact Rounded -decf198 apply -0.00000000000001e-6176 -> #80000000000000000000000000000000 Subnormal Underflow Inexact Rounded -decf199 apply -0.000000000000001e-6176 -> #80000000000000000000000000000000 Subnormal Underflow Inexact Rounded -decf200 apply -999999999999999999999999999999999e-6176 -> #80000ff3fcff3fcff3fcff3fcff3fcff Subnormal - --- zeros -decf400 apply 0E-8000 -> #00000000000000000000000000000000 Clamped -decf401 apply 0E-6177 -> #00000000000000000000000000000000 Clamped -decf402 apply 0E-6176 -> #00000000000000000000000000000000 -decf403 apply #00000000000000000000000000000000 -> 0E-6176 -decf404 apply 0.000000000000000000000000000000000E-6143 -> #00000000000000000000000000000000 -decf405 apply #00000000000000000000000000000000 -> 0E-6176 -decf406 apply 0E-2 -> #22078000000000000000000000000000 -decf407 apply #22078000000000000000000000000000 -> 0.00 -decf408 apply 0 -> #22080000000000000000000000000000 -decf409 apply #22080000000000000000000000000000 -> 0 -decf410 apply 0E+3 -> #2208c000000000000000000000000000 -decf411 apply #2208c000000000000000000000000000 -> 0E+3 -decf412 apply 0E+6111 -> #43ffc000000000000000000000000000 -decf413 apply #43ffc000000000000000000000000000 -> 0E+6111 --- clamped zeros... -decf414 apply 0E+6112 -> #43ffc000000000000000000000000000 Clamped -decf415 apply #43ffc000000000000000000000000000 -> 0E+6111 -decf416 apply 0E+6144 -> #43ffc000000000000000000000000000 Clamped -decf417 apply #43ffc000000000000000000000000000 -> 0E+6111 -decf418 apply 0E+8000 -> #43ffc000000000000000000000000000 Clamped -decf419 apply #43ffc000000000000000000000000000 -> 0E+6111 - --- negative zeros -decf420 apply -0E-8000 -> #80000000000000000000000000000000 Clamped -decf421 apply -0E-6177 -> #80000000000000000000000000000000 Clamped -decf422 apply -0E-6176 -> #80000000000000000000000000000000 -decf423 apply #80000000000000000000000000000000 -> -0E-6176 -decf424 apply -0.000000000000000000000000000000000E-6143 -> #80000000000000000000000000000000 -decf425 apply #80000000000000000000000000000000 -> -0E-6176 -decf426 apply -0E-2 -> #a2078000000000000000000000000000 -decf427 apply #a2078000000000000000000000000000 -> -0.00 -decf428 apply -0 -> #a2080000000000000000000000000000 -decf429 apply #a2080000000000000000000000000000 -> -0 -decf430 apply -0E+3 -> #a208c000000000000000000000000000 -decf431 apply #a208c000000000000000000000000000 -> -0E+3 -decf432 apply -0E+6111 -> #c3ffc000000000000000000000000000 -decf433 apply #c3ffc000000000000000000000000000 -> -0E+6111 --- clamped zeros... -decf434 apply -0E+6112 -> #c3ffc000000000000000000000000000 Clamped -decf435 apply #c3ffc000000000000000000000000000 -> -0E+6111 -decf436 apply -0E+6144 -> #c3ffc000000000000000000000000000 Clamped -decf437 apply #c3ffc000000000000000000000000000 -> -0E+6111 -decf438 apply -0E+8000 -> #c3ffc000000000000000000000000000 Clamped -decf439 apply #c3ffc000000000000000000000000000 -> -0E+6111 - --- Specials -decf500 apply Infinity -> #78000000000000000000000000000000 -decf501 apply #78787878787878787878787878787878 -> #78000000000000000000000000000000 -decf502 apply #78000000000000000000000000000000 -> Infinity -decf503 apply #79797979797979797979797979797979 -> #78000000000000000000000000000000 -decf504 apply #79000000000000000000000000000000 -> Infinity -decf505 apply #7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a -> #78000000000000000000000000000000 -decf506 apply #7a000000000000000000000000000000 -> Infinity -decf507 apply #7b7b7b7b7b7b7b7b7b7b7b7b7b7b7b7b -> #78000000000000000000000000000000 -decf508 apply #7b000000000000000000000000000000 -> Infinity - -decf509 apply NaN -> #7c000000000000000000000000000000 -decf510 apply #7c7c7c7c7c7c7c7c7c7c7c7c7c7c7c7c -> #7c003c7c7c7c7c7c7c7c7c7c7c7c7c7c -decf511 apply #7c000000000000000000000000000000 -> NaN -decf512 apply #7d7d7d7d7d7d7d7d7d7d7d7d7d7d7d7d -> #7c003d7d7d7d7d7d7d7d7d7d7d7d7d7d -decf513 apply #7d000000000000000000000000000000 -> NaN -decf514 apply #7e7e7e7e7e7e7e7e7e7e7e7e7e7e7e7e -> #7e003e7e7c7e7e7e7e7c7e7e7e7e7c7e -decf515 apply #7e000000000000000000000000000000 -> sNaN -decf516 apply #7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f -> #7e003f7f7c7f7f7f7f7c7f7f7f7f7c7f -decf517 apply #7f000000000000000000000000000000 -> sNaN -decf518 apply #7fffffffffffffffffffffffffffffff -> sNaN999999999999999999999999999999999 -decf519 apply #7fffffffffffffffffffffffffffffff -> #7e000ff3fcff3fcff3fcff3fcff3fcff - -decf520 apply -Infinity -> #f8000000000000000000000000000000 -decf521 apply #f8787878787878787878787878787878 -> #f8000000000000000000000000000000 -decf522 apply #f8000000000000000000000000000000 -> -Infinity -decf523 apply #f9797979797979797979797979797979 -> #f8000000000000000000000000000000 -decf524 apply #f9000000000000000000000000000000 -> -Infinity -decf525 apply #fa7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a -> #f8000000000000000000000000000000 -decf526 apply #fa000000000000000000000000000000 -> -Infinity -decf527 apply #fb7b7b7b7b7b7b7b7b7b7b7b7b7b7b7b -> #f8000000000000000000000000000000 -decf528 apply #fb000000000000000000000000000000 -> -Infinity - -decf529 apply -NaN -> #fc000000000000000000000000000000 -decf530 apply #fc7c7c7c7c7c7c7c7c7c7c7c7c7c7c7c -> #fc003c7c7c7c7c7c7c7c7c7c7c7c7c7c -decf531 apply #fc000000000000000000000000000000 -> -NaN -decf532 apply #fd7d7d7d7d7d7d7d7d7d7d7d7d7d7d7d -> #fc003d7d7d7d7d7d7d7d7d7d7d7d7d7d -decf533 apply #fd000000000000000000000000000000 -> -NaN -decf534 apply #fe7e7e7e7e7e7e7e7e7e7e7e7e7e7e7e -> #fe003e7e7c7e7e7e7e7c7e7e7e7e7c7e -decf535 apply #fe000000000000000000000000000000 -> -sNaN -decf536 apply #ff7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f -> #fe003f7f7c7f7f7f7f7c7f7f7f7f7c7f -decf537 apply #ff000000000000000000000000000000 -> -sNaN -decf538 apply #ffffffffffffffffffffffffffffffff -> -sNaN999999999999999999999999999999999 -decf539 apply #ffffffffffffffffffffffffffffffff -> #fe000ff3fcff3fcff3fcff3fcff3fcff - -decf540 apply NaN -> #7c000000000000000000000000000000 -decf541 apply NaN0 -> #7c000000000000000000000000000000 -decf542 apply NaN1 -> #7c000000000000000000000000000001 -decf543 apply NaN12 -> #7c000000000000000000000000000012 -decf544 apply NaN79 -> #7c000000000000000000000000000079 -decf545 apply NaN12345 -> #7c0000000000000000000000000049c5 -decf546 apply NaN123456 -> #7c000000000000000000000000028e56 -decf547 apply NaN799799 -> #7c0000000000000000000000000f7fdf -decf548 apply NaN799799799799799799799799799799799 -> #7c003dff7fdff7fdff7fdff7fdff7fdf -decf549 apply NaN999999999999999999999999999999999 -> #7c000ff3fcff3fcff3fcff3fcff3fcff -decf550 apply NaN1234567890123456789012345678901234 -> #7c000000000000000000000000000000 -- too many digits - --- fold-down full sequence -decf600 apply 1E+6145 -> #78000000000000000000000000000000 Overflow Inexact Rounded -decf601 apply 1E+6144 -> #47ffc000000000000000000000000000 Clamped -decf602 apply #47ffc000000000000000000000000000 -> 1.000000000000000000000000000000000E+6144 -decf603 apply 1E+6143 -> #43ffc800000000000000000000000000 Clamped -decf604 apply #43ffc800000000000000000000000000 -> 1.00000000000000000000000000000000E+6143 -decf605 apply 1E+6142 -> #43ffc100000000000000000000000000 Clamped -decf606 apply #43ffc100000000000000000000000000 -> 1.0000000000000000000000000000000E+6142 -decf607 apply 1E+6141 -> #43ffc010000000000000000000000000 Clamped -decf608 apply #43ffc010000000000000000000000000 -> 1.000000000000000000000000000000E+6141 -decf609 apply 1E+6140 -> #43ffc002000000000000000000000000 Clamped -decf610 apply #43ffc002000000000000000000000000 -> 1.00000000000000000000000000000E+6140 -decf611 apply 1E+6139 -> #43ffc000400000000000000000000000 Clamped -decf612 apply #43ffc000400000000000000000000000 -> 1.0000000000000000000000000000E+6139 -decf613 apply 1E+6138 -> #43ffc000040000000000000000000000 Clamped -decf614 apply #43ffc000040000000000000000000000 -> 1.000000000000000000000000000E+6138 -decf615 apply 1E+6137 -> #43ffc000008000000000000000000000 Clamped -decf616 apply #43ffc000008000000000000000000000 -> 1.00000000000000000000000000E+6137 -decf617 apply 1E+6136 -> #43ffc000001000000000000000000000 Clamped -decf618 apply #43ffc000001000000000000000000000 -> 1.0000000000000000000000000E+6136 -decf619 apply 1E+6135 -> #43ffc000000100000000000000000000 Clamped -decf620 apply #43ffc000000100000000000000000000 -> 1.000000000000000000000000E+6135 -decf621 apply 1E+6134 -> #43ffc000000020000000000000000000 Clamped -decf622 apply #43ffc000000020000000000000000000 -> 1.00000000000000000000000E+6134 -decf623 apply 1E+6133 -> #43ffc000000004000000000000000000 Clamped -decf624 apply #43ffc000000004000000000000000000 -> 1.0000000000000000000000E+6133 -decf625 apply 1E+6132 -> #43ffc000000000400000000000000000 Clamped -decf626 apply #43ffc000000000400000000000000000 -> 1.000000000000000000000E+6132 -decf627 apply 1E+6131 -> #43ffc000000000080000000000000000 Clamped -decf628 apply #43ffc000000000080000000000000000 -> 1.00000000000000000000E+6131 -decf629 apply 1E+6130 -> #43ffc000000000010000000000000000 Clamped -decf630 apply #43ffc000000000010000000000000000 -> 1.0000000000000000000E+6130 -decf631 apply 1E+6129 -> #43ffc000000000001000000000000000 Clamped -decf632 apply #43ffc000000000001000000000000000 -> 1.000000000000000000E+6129 -decf633 apply 1E+6128 -> #43ffc000000000000200000000000000 Clamped -decf634 apply #43ffc000000000000200000000000000 -> 1.00000000000000000E+6128 -decf635 apply 1E+6127 -> #43ffc000000000000040000000000000 Clamped -decf636 apply #43ffc000000000000040000000000000 -> 1.0000000000000000E+6127 -decf637 apply 1E+6126 -> #43ffc000000000000004000000000000 Clamped -decf638 apply #43ffc000000000000004000000000000 -> 1.000000000000000E+6126 -decf639 apply 1E+6125 -> #43ffc000000000000000800000000000 Clamped -decf640 apply #43ffc000000000000000800000000000 -> 1.00000000000000E+6125 -decf641 apply 1E+6124 -> #43ffc000000000000000100000000000 Clamped -decf642 apply #43ffc000000000000000100000000000 -> 1.0000000000000E+6124 -decf643 apply 1E+6123 -> #43ffc000000000000000010000000000 Clamped -decf644 apply #43ffc000000000000000010000000000 -> 1.000000000000E+6123 -decf645 apply 1E+6122 -> #43ffc000000000000000002000000000 Clamped -decf646 apply #43ffc000000000000000002000000000 -> 1.00000000000E+6122 -decf647 apply 1E+6121 -> #43ffc000000000000000000400000000 Clamped -decf648 apply #43ffc000000000000000000400000000 -> 1.0000000000E+6121 -decf649 apply 1E+6120 -> #43ffc000000000000000000040000000 Clamped -decf650 apply #43ffc000000000000000000040000000 -> 1.000000000E+6120 -decf651 apply 1E+6119 -> #43ffc000000000000000000008000000 Clamped -decf652 apply #43ffc000000000000000000008000000 -> 1.00000000E+6119 -decf653 apply 1E+6118 -> #43ffc000000000000000000001000000 Clamped -decf654 apply #43ffc000000000000000000001000000 -> 1.0000000E+6118 -decf655 apply 1E+6117 -> #43ffc000000000000000000000100000 Clamped -decf656 apply #43ffc000000000000000000000100000 -> 1.000000E+6117 -decf657 apply 1E+6116 -> #43ffc000000000000000000000020000 Clamped -decf658 apply #43ffc000000000000000000000020000 -> 1.00000E+6116 -decf659 apply 1E+6115 -> #43ffc000000000000000000000004000 Clamped -decf660 apply #43ffc000000000000000000000004000 -> 1.0000E+6115 -decf661 apply 1E+6114 -> #43ffc000000000000000000000000400 Clamped -decf662 apply #43ffc000000000000000000000000400 -> 1.000E+6114 -decf663 apply 1E+6113 -> #43ffc000000000000000000000000080 Clamped -decf664 apply #43ffc000000000000000000000000080 -> 1.00E+6113 -decf665 apply 1E+6112 -> #43ffc000000000000000000000000010 Clamped -decf666 apply #43ffc000000000000000000000000010 -> 1.0E+6112 -decf667 apply 1E+6111 -> #43ffc000000000000000000000000001 -decf668 apply #43ffc000000000000000000000000001 -> 1E+6111 -decf669 apply 1E+6110 -> #43ff8000000000000000000000000001 -decf670 apply #43ff8000000000000000000000000001 -> 1E+6110 - --- Selected DPD codes -decf700 apply #22080000000000000000000000000000 -> 0 -decf701 apply #22080000000000000000000000000009 -> 9 -decf702 apply #22080000000000000000000000000010 -> 10 -decf703 apply #22080000000000000000000000000019 -> 19 -decf704 apply #22080000000000000000000000000020 -> 20 -decf705 apply #22080000000000000000000000000029 -> 29 -decf706 apply #22080000000000000000000000000030 -> 30 -decf707 apply #22080000000000000000000000000039 -> 39 -decf708 apply #22080000000000000000000000000040 -> 40 -decf709 apply #22080000000000000000000000000049 -> 49 -decf710 apply #22080000000000000000000000000050 -> 50 -decf711 apply #22080000000000000000000000000059 -> 59 -decf712 apply #22080000000000000000000000000060 -> 60 -decf713 apply #22080000000000000000000000000069 -> 69 -decf714 apply #22080000000000000000000000000070 -> 70 -decf715 apply #22080000000000000000000000000071 -> 71 -decf716 apply #22080000000000000000000000000072 -> 72 -decf717 apply #22080000000000000000000000000073 -> 73 -decf718 apply #22080000000000000000000000000074 -> 74 -decf719 apply #22080000000000000000000000000075 -> 75 -decf720 apply #22080000000000000000000000000076 -> 76 -decf721 apply #22080000000000000000000000000077 -> 77 -decf722 apply #22080000000000000000000000000078 -> 78 -decf723 apply #22080000000000000000000000000079 -> 79 - -decf730 apply #2208000000000000000000000000029e -> 994 -decf731 apply #2208000000000000000000000000029f -> 995 -decf732 apply #220800000000000000000000000002a0 -> 520 -decf733 apply #220800000000000000000000000002a1 -> 521 - --- DPD: one of each of the huffman groups -decf740 apply #220800000000000000000000000003f7 -> 777 -decf741 apply #220800000000000000000000000003f8 -> 778 -decf742 apply #220800000000000000000000000003eb -> 787 -decf743 apply #2208000000000000000000000000037d -> 877 -decf744 apply #2208000000000000000000000000039f -> 997 -decf745 apply #220800000000000000000000000003bf -> 979 -decf746 apply #220800000000000000000000000003df -> 799 -decf747 apply #2208000000000000000000000000006e -> 888 - - --- DPD all-highs cases (includes the 24 redundant codes) -decf750 apply #2208000000000000000000000000006e -> 888 -decf751 apply #2208000000000000000000000000016e -> 888 -decf752 apply #2208000000000000000000000000026e -> 888 -decf753 apply #2208000000000000000000000000036e -> 888 -decf754 apply #2208000000000000000000000000006f -> 889 -decf755 apply #2208000000000000000000000000016f -> 889 -decf756 apply #2208000000000000000000000000026f -> 889 -decf757 apply #2208000000000000000000000000036f -> 889 - -decf760 apply #2208000000000000000000000000007e -> 898 -decf761 apply #2208000000000000000000000000017e -> 898 -decf762 apply #2208000000000000000000000000027e -> 898 -decf763 apply #2208000000000000000000000000037e -> 898 -decf764 apply #2208000000000000000000000000007f -> 899 -decf765 apply #2208000000000000000000000000017f -> 899 -decf766 apply #2208000000000000000000000000027f -> 899 -decf767 apply #2208000000000000000000000000037f -> 899 - -decf770 apply #220800000000000000000000000000ee -> 988 -decf771 apply #220800000000000000000000000001ee -> 988 -decf772 apply #220800000000000000000000000002ee -> 988 -decf773 apply #220800000000000000000000000003ee -> 988 -decf774 apply #220800000000000000000000000000ef -> 989 -decf775 apply #220800000000000000000000000001ef -> 989 -decf776 apply #220800000000000000000000000002ef -> 989 -decf777 apply #220800000000000000000000000003ef -> 989 - -decf780 apply #220800000000000000000000000000fe -> 998 -decf781 apply #220800000000000000000000000001fe -> 998 -decf782 apply #220800000000000000000000000002fe -> 998 -decf783 apply #220800000000000000000000000003fe -> 998 -decf784 apply #220800000000000000000000000000ff -> 999 -decf785 apply #220800000000000000000000000001ff -> 999 -decf786 apply #220800000000000000000000000002ff -> 999 -decf787 apply #220800000000000000000000000003ff -> 999 - Deleted: /python/branches/release25-maint/Lib/test/decimaltestdata/decimal32.decTest ============================================================================== --- /python/branches/release25-maint/Lib/test/decimaltestdata/decimal32.decTest Tue Jan 8 17:20:31 2008 +++ (empty file) @@ -1,385 +0,0 @@ ------------------------------------------------------------------------- --- decimal32.decTest -- decimal four-byte format testcases -- --- Copyright (c) IBM Corporation, 2000, 2003. All rights reserved. -- ------------------------------------------------------------------------- --- Please see the document "General Decimal Arithmetic Testcases" -- --- at http://www2.hursley.ibm.com/decimal for the description of -- --- these testcases. -- --- -- --- These testcases are experimental ('beta' versions), and they -- --- may contain errors. They are offered on an as-is basis. In -- --- particular, achieving the same results as the tests here is not -- --- a guarantee that an implementation complies with any Standard -- --- or specification. The tests are not exhaustive. -- --- -- --- Please send comments, suggestions, and corrections to the author: -- --- Mike Cowlishaw, IBM Fellow -- --- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- --- mfc at uk.ibm.com -- ------------------------------------------------------------------------- -version: 2.39 - --- This set of tests is for the four-byte concrete representation. --- Its characteristics are: --- --- 1 bit sign --- 5 bits combination field --- 6 bits exponent continuation --- 20 bits coefficient continuation --- --- Total exponent length 8 bits --- Total coefficient length 24 bits (7 digits) --- --- Elimit = 191 (maximum encoded exponent) --- Emax = 96 (largest exponent value) --- Emin = -95 (smallest exponent value) --- bias = 101 (subtracted from encoded exponent) = -Etiny - -extended: 1 -precision: 7 -rounding: half_up -maxExponent: 96 -minExponent: -95 - --- General testcases --- (mostly derived from the Strawman 4 document and examples) -decd001 apply #A23003D0 -> -7.50 -decd002 apply -7.50 -> #A23003D0 - --- Normality -decd010 apply 1234567 -> #2654d2e7 -decd011 apply 1234567.0 -> #2654d2e7 Rounded -decd012 apply 1234567.1 -> #2654d2e7 Rounded Inexact -decd013 apply -1234567 -> #a654d2e7 -decd014 apply -1234567.0 -> #a654d2e7 Rounded -decd015 apply -1234567.1 -> #a654d2e7 Rounded Inexact - - --- Nmax and similar -decd022 apply 9.999999E+96 -> #77f3fcff -decd023 apply #77f3fcff -> 9.999999E+96 -decd024 apply 1.234567E+96 -> #47f4d2e7 -decd025 apply #47f4d2e7 -> 1.234567E+96 --- fold-downs (more below) -decd030 apply 1.23E+96 -> #47f4c000 Clamped -decd031 apply #47f4c000 -> 1.230000E+96 -decd032 apply 1E+96 -> #47f00000 Clamped -decd033 apply #47f00000 -> 1.000000E+96 - --- overflows -maxExponent: 999 -- set high so conversion causes the overflow -minExponent: -999 -decd040 apply 10E+96 -> #78000000 Overflow Rounded Inexact -decd041 apply 1.000000E+97 -> #78000000 Overflow Rounded Inexact -maxExponent: 96 -minExponent: -95 - -decd051 apply 12345 -> #225049c5 -decd052 apply #225049c5 -> 12345 -decd053 apply 1234 -> #22500534 -decd054 apply #22500534 -> 1234 -decd055 apply 123 -> #225000a3 -decd056 apply #225000a3 -> 123 -decd057 apply 12 -> #22500012 -decd058 apply #22500012 -> 12 -decd059 apply 1 -> #22500001 -decd060 apply #22500001 -> 1 -decd061 apply 1.23 -> #223000a3 -decd062 apply #223000a3 -> 1.23 -decd063 apply 123.45 -> #223049c5 -decd064 apply #223049c5 -> 123.45 - --- Nmin and below -decd071 apply 1E-95 -> #00600001 -decd072 apply #00600001 -> 1E-95 -decd073 apply 1.000000E-95 -> #04000000 -decd074 apply #04000000 -> 1.000000E-95 -decd075 apply 1.000001E-95 -> #04000001 -decd076 apply #04000001 -> 1.000001E-95 - -decd077 apply 0.100000E-95 -> #00020000 Subnormal -decd07x apply 1.00000E-96 -> 1.00000E-96 Subnormal -decd078 apply #00020000 -> 1.00000E-96 Subnormal -decd079 apply 0.000010E-95 -> #00000010 Subnormal -decd080 apply #00000010 -> 1.0E-100 Subnormal -decd081 apply 0.000001E-95 -> #00000001 Subnormal -decd082 apply #00000001 -> 1E-101 Subnormal -decd083 apply 1e-101 -> #00000001 Subnormal -decd084 apply #00000001 -> 1E-101 Subnormal -decd08x apply 1e-101 -> 1E-101 Subnormal - --- underflows -decd090 apply 1e-101 -> #00000001 Subnormal -decd091 apply 1.9e-101 -> #00000002 Subnormal Underflow Inexact Rounded -decd092 apply 1.1e-101 -> #00000001 Subnormal Underflow Inexact Rounded -decd093 apply 1.001e-101 -> #00000001 Subnormal Underflow Inexact Rounded -decd094 apply 1.000001e-101 -> #00000001 Subnormal Underflow Inexact Rounded -decd095 apply 1.0000001e-101 -> #00000001 Subnormal Underflow Inexact Rounded -decd096 apply 0.1e-101 -> #00000000 Subnormal Underflow Inexact Rounded -decd097 apply 0.001e-101 -> #00000000 Subnormal Underflow Inexact Rounded -decd098 apply 0.000001e-101 -> #00000000 Subnormal Underflow Inexact Rounded -decd099 apply 0.0000001e-101 -> #00000000 Subnormal Underflow Inexact Rounded - --- same again, negatives -- - --- Nmax and similar -decd122 apply -9.999999E+96 -> #f7f3fcff -decd123 apply #f7f3fcff -> -9.999999E+96 -decd124 apply -1.234567E+96 -> #c7f4d2e7 -decd125 apply #c7f4d2e7 -> -1.234567E+96 --- fold-downs (more below) -decd130 apply -1.23E+96 -> #c7f4c000 Clamped -decd131 apply #c7f4c000 -> -1.230000E+96 -decd132 apply -1E+96 -> #c7f00000 Clamped -decd133 apply #c7f00000 -> -1.000000E+96 - --- overflows -maxExponent: 999 -- set high so conversion causes the overflow -minExponent: -999 -decd140 apply -10E+96 -> #f8000000 Overflow Rounded Inexact -decd141 apply -1.000000E+97 -> #f8000000 Overflow Rounded Inexact -maxExponent: 96 -minExponent: -95 - -decd151 apply -12345 -> #a25049c5 -decd152 apply #a25049c5 -> -12345 -decd153 apply -1234 -> #a2500534 -decd154 apply #a2500534 -> -1234 -decd155 apply -123 -> #a25000a3 -decd156 apply #a25000a3 -> -123 -decd157 apply -12 -> #a2500012 -decd158 apply #a2500012 -> -12 -decd159 apply -1 -> #a2500001 -decd160 apply #a2500001 -> -1 -decd161 apply -1.23 -> #a23000a3 -decd162 apply #a23000a3 -> -1.23 -decd163 apply -123.45 -> #a23049c5 -decd164 apply #a23049c5 -> -123.45 - --- Nmin and below -decd171 apply -1E-95 -> #80600001 -decd172 apply #80600001 -> -1E-95 -decd173 apply -1.000000E-95 -> #84000000 -decd174 apply #84000000 -> -1.000000E-95 -decd175 apply -1.000001E-95 -> #84000001 -decd176 apply #84000001 -> -1.000001E-95 - -decd177 apply -0.100000E-95 -> #80020000 Subnormal -decd178 apply #80020000 -> -1.00000E-96 Subnormal -decd179 apply -0.000010E-95 -> #80000010 Subnormal -decd180 apply #80000010 -> -1.0E-100 Subnormal -decd181 apply -0.000001E-95 -> #80000001 Subnormal -decd182 apply #80000001 -> -1E-101 Subnormal -decd183 apply -1e-101 -> #80000001 Subnormal -decd184 apply #80000001 -> -1E-101 Subnormal - --- underflows -decd190 apply -1e-101 -> #80000001 Subnormal -decd191 apply -1.9e-101 -> #80000002 Subnormal Underflow Inexact Rounded -decd192 apply -1.1e-101 -> #80000001 Subnormal Underflow Inexact Rounded -decd193 apply -1.001e-101 -> #80000001 Subnormal Underflow Inexact Rounded -decd194 apply -1.000001e-101 -> #80000001 Subnormal Underflow Inexact Rounded -decd195 apply -1.0000001e-101 -> #80000001 Subnormal Underflow Inexact Rounded -decd196 apply -0.1e-101 -> #80000000 Subnormal Underflow Inexact Rounded -decd197 apply -0.001e-101 -> #80000000 Subnormal Underflow Inexact Rounded -decd198 apply -0.000001e-101 -> #80000000 Subnormal Underflow Inexact Rounded -decd199 apply -0.0000001e-101 -> #80000000 Subnormal Underflow Inexact Rounded - --- zeros -decd400 apply 0E-400 -> #00000000 Clamped -decd401 apply 0E-101 -> #00000000 -decd402 apply #00000000 -> 0E-101 -decd403 apply 0.000000E-95 -> #00000000 -decd404 apply #00000000 -> 0E-101 -decd405 apply 0E-2 -> #22300000 -decd406 apply #22300000 -> 0.00 -decd407 apply 0 -> #22500000 -decd408 apply #22500000 -> 0 -decd409 apply 0E+3 -> #22800000 -decd410 apply #22800000 -> 0E+3 -decd411 apply 0E+90 -> #43f00000 -decd412 apply #43f00000 -> 0E+90 --- clamped zeros... -decd413 apply 0E+91 -> #43f00000 Clamped -decd414 apply #43f00000 -> 0E+90 -decd415 apply 0E+96 -> #43f00000 Clamped -decd416 apply #43f00000 -> 0E+90 -decd417 apply 0E+400 -> #43f00000 Clamped -decd418 apply #43f00000 -> 0E+90 - --- negative zeros -decd420 apply -0E-400 -> #80000000 Clamped -decd421 apply -0E-101 -> #80000000 -decd422 apply #80000000 -> -0E-101 -decd423 apply -0.000000E-95 -> #80000000 -decd424 apply #80000000 -> -0E-101 -decd425 apply -0E-2 -> #a2300000 -decd426 apply #a2300000 -> -0.00 -decd427 apply -0 -> #a2500000 -decd428 apply #a2500000 -> -0 -decd429 apply -0E+3 -> #a2800000 -decd430 apply #a2800000 -> -0E+3 -decd431 apply -0E+90 -> #c3f00000 -decd432 apply #c3f00000 -> -0E+90 --- clamped zeros... -decd433 apply -0E+91 -> #c3f00000 Clamped -decd434 apply #c3f00000 -> -0E+90 -decd435 apply -0E+96 -> #c3f00000 Clamped -decd436 apply #c3f00000 -> -0E+90 -decd437 apply -0E+400 -> #c3f00000 Clamped -decd438 apply #c3f00000 -> -0E+90 - --- Specials -decd500 apply Infinity -> #78000000 -decd501 apply #78787878 -> #78000000 -decd502 apply #78000000 -> Infinity -decd503 apply #79797979 -> #78000000 -decd504 apply #79000000 -> Infinity -decd505 apply #7a7a7a7a -> #78000000 -decd506 apply #7a000000 -> Infinity -decd507 apply #7b7b7b7b -> #78000000 -decd508 apply #7b000000 -> Infinity -decd509 apply #7c7c7c7c -> #7c0c7c7c - -decd510 apply NaN -> #7c000000 -decd511 apply #7c000000 -> NaN -decd512 apply #7d7d7d7d -> #7c0d7d7d -decd513 apply #7d000000 -> NaN -decd514 apply #7e7e7e7e -> #7e0e7c7e -decd515 apply #7e000000 -> sNaN -decd516 apply #7f7f7f7f -> #7e0f7c7f -decd517 apply #7f000000 -> sNaN -decd518 apply #7fffffff -> sNaN999999 -decd519 apply #7fffffff -> #7e03fcff - -decd520 apply -Infinity -> #f8000000 -decd521 apply #f8787878 -> #f8000000 -decd522 apply #f8000000 -> -Infinity -decd523 apply #f9797979 -> #f8000000 -decd524 apply #f9000000 -> -Infinity -decd525 apply #fa7a7a7a -> #f8000000 -decd526 apply #fa000000 -> -Infinity -decd527 apply #fb7b7b7b -> #f8000000 -decd528 apply #fb000000 -> -Infinity - -decd529 apply -NaN -> #fc000000 -decd530 apply #fc7c7c7c -> #fc0c7c7c -decd531 apply #fc000000 -> -NaN -decd532 apply #fd7d7d7d -> #fc0d7d7d -decd533 apply #fd000000 -> -NaN -decd534 apply #fe7e7e7e -> #fe0e7c7e -decd535 apply #fe000000 -> -sNaN -decd536 apply #ff7f7f7f -> #fe0f7c7f -decd537 apply #ff000000 -> -sNaN -decd538 apply #ffffffff -> -sNaN999999 -decd539 apply #ffffffff -> #fe03fcff - --- diagnostic NaNs -decd540 apply NaN -> #7c000000 -decd541 apply NaN0 -> #7c000000 -decd542 apply NaN1 -> #7c000001 -decd543 apply NaN12 -> #7c000012 -decd544 apply NaN79 -> #7c000079 -decd545 apply NaN12345 -> #7c0049c5 -decd546 apply NaN123456 -> #7c028e56 -decd547 apply NaN799799 -> #7c0f7fdf -decd548 apply NaN999999 -> #7c03fcff -decd549 apply NaN1234567 -> #7c000000 -- too many digits - - --- fold-down full sequence -decd601 apply 1E+96 -> #47f00000 Clamped -decd602 apply #47f00000 -> 1.000000E+96 -decd603 apply 1E+95 -> #43f20000 Clamped -decd604 apply #43f20000 -> 1.00000E+95 -decd605 apply 1E+94 -> #43f04000 Clamped -decd606 apply #43f04000 -> 1.0000E+94 -decd607 apply 1E+93 -> #43f00400 Clamped -decd608 apply #43f00400 -> 1.000E+93 -decd609 apply 1E+92 -> #43f00080 Clamped -decd610 apply #43f00080 -> 1.00E+92 -decd611 apply 1E+91 -> #43f00010 Clamped -decd612 apply #43f00010 -> 1.0E+91 -decd613 apply 1E+90 -> #43f00001 -decd614 apply #43f00001 -> 1E+90 - - --- Selected DPD codes -decd700 apply #22500000 -> 0 -decd701 apply #22500009 -> 9 -decd702 apply #22500010 -> 10 -decd703 apply #22500019 -> 19 -decd704 apply #22500020 -> 20 -decd705 apply #22500029 -> 29 -decd706 apply #22500030 -> 30 -decd707 apply #22500039 -> 39 -decd708 apply #22500040 -> 40 -decd709 apply #22500049 -> 49 -decd710 apply #22500050 -> 50 -decd711 apply #22500059 -> 59 -decd712 apply #22500060 -> 60 -decd713 apply #22500069 -> 69 -decd714 apply #22500070 -> 70 -decd715 apply #22500071 -> 71 -decd716 apply #22500072 -> 72 -decd717 apply #22500073 -> 73 -decd718 apply #22500074 -> 74 -decd719 apply #22500075 -> 75 -decd720 apply #22500076 -> 76 -decd721 apply #22500077 -> 77 -decd722 apply #22500078 -> 78 -decd723 apply #22500079 -> 79 - -decd730 apply #2250029e -> 994 -decd731 apply #2250029f -> 995 -decd732 apply #225002a0 -> 520 -decd733 apply #225002a1 -> 521 - --- DPD: one of each of the huffman groups -decd740 apply #225003f7 -> 777 -decd741 apply #225003f8 -> 778 -decd742 apply #225003eb -> 787 -decd743 apply #2250037d -> 877 -decd744 apply #2250039f -> 997 -decd745 apply #225003bf -> 979 -decd746 apply #225003df -> 799 -decd747 apply #2250006e -> 888 - - --- DPD all-highs cases (includes the 24 redundant codes) -decd750 apply #2250006e -> 888 -decd751 apply #2250016e -> 888 -decd752 apply #2250026e -> 888 -decd753 apply #2250036e -> 888 -decd754 apply #2250006f -> 889 -decd755 apply #2250016f -> 889 -decd756 apply #2250026f -> 889 -decd757 apply #2250036f -> 889 - -decd760 apply #2250007e -> 898 -decd761 apply #2250017e -> 898 -decd762 apply #2250027e -> 898 -decd763 apply #2250037e -> 898 -decd764 apply #2250007f -> 899 -decd765 apply #2250017f -> 899 -decd766 apply #2250027f -> 899 -decd767 apply #2250037f -> 899 - -decd770 apply #225000ee -> 988 -decd771 apply #225001ee -> 988 -decd772 apply #225002ee -> 988 -decd773 apply #225003ee -> 988 -decd774 apply #225000ef -> 989 -decd775 apply #225001ef -> 989 -decd776 apply #225002ef -> 989 -decd777 apply #225003ef -> 989 - -decd780 apply #225000fe -> 998 -decd781 apply #225001fe -> 998 -decd782 apply #225002fe -> 998 -decd783 apply #225003fe -> 998 -decd784 apply #225000ff -> 999 -decd785 apply #225001ff -> 999 -decd786 apply #225002ff -> 999 -decd787 apply #225003ff -> 999 - Deleted: /python/branches/release25-maint/Lib/test/decimaltestdata/decimal64.decTest ============================================================================== --- /python/branches/release25-maint/Lib/test/decimaltestdata/decimal64.decTest Tue Jan 8 17:20:31 2008 +++ (empty file) @@ -1,444 +0,0 @@ ------------------------------------------------------------------------- --- decimal64.decTest -- decimal eight-byte format testcases -- --- Copyright (c) IBM Corporation, 2000, 2003. All rights reserved. -- ------------------------------------------------------------------------- --- Please see the document "General Decimal Arithmetic Testcases" -- --- at http://www2.hursley.ibm.com/decimal for the description of -- --- these testcases. -- --- -- --- These testcases are experimental ('beta' versions), and they -- --- may contain errors. They are offered on an as-is basis. In -- --- particular, achieving the same results as the tests here is not -- --- a guarantee that an implementation complies with any Standard -- --- or specification. The tests are not exhaustive. -- --- -- --- Please send comments, suggestions, and corrections to the author: -- --- Mike Cowlishaw, IBM Fellow -- --- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- --- mfc at uk.ibm.com -- ------------------------------------------------------------------------- -version: 2.39 - --- This set of tests is for the eight-byte concrete representation. --- Its characteristics are: --- --- 1 bit sign --- 5 bits combination field --- 8 bits exponent continuation --- 50 bits coefficient continuation --- --- Total exponent length 10 bits --- Total coefficient length 54 bits (16 digits) --- --- Elimit = 767 (maximum encoded exponent) --- Emax = 384 (largest exponent value) --- Emin = -383 (smallest exponent value) --- bias = 398 (subtracted from encoded exponent) = -Etiny - -extended: 1 -precision: 16 -rounding: half_up -maxExponent: 384 -minExponent: -383 - --- General testcases --- (mostly derived from the Strawman 4 document and examples) -dece001 apply #A2300000000003D0 -> -7.50 -dece002 apply -7.50 -> #A2300000000003D0 - --- Normality -dece010 apply 1234567890123456 -> #263934b9c1e28e56 -dece011 apply 1234567890123456.0 -> #263934b9c1e28e56 Rounded -dece012 apply 1234567890123456.1 -> #263934b9c1e28e56 Rounded Inexact -dece013 apply -1234567890123456 -> #a63934b9c1e28e56 -dece014 apply -1234567890123456.0 -> #a63934b9c1e28e56 Rounded -dece015 apply -1234567890123456.1 -> #a63934b9c1e28e56 Rounded Inexact - - --- Nmax and similar -dece022 apply 9.999999999999999E+384 -> #77fcff3fcff3fcff -dece023 apply #77fcff3fcff3fcff -> 9.999999999999999E+384 -dece024 apply 1.234567890123456E+384 -> #47fd34b9c1e28e56 -dece025 apply #47fd34b9c1e28e56 -> 1.234567890123456E+384 --- fold-downs (more below) -dece030 apply 1.23E+384 -> #47fd300000000000 Clamped -dece031 apply #47fd300000000000 -> 1.230000000000000E+384 -dece032 apply 1E+384 -> #47fc000000000000 Clamped -dece033 apply #47fc000000000000 -> 1.000000000000000E+384 - --- overflows -maxExponent: 999 -- set high so conversion causes the overflow -minExponent: -999 -dece040 apply 10E+384 -> #7800000000000000 Overflow Rounded Inexact -dece041 apply 1.000000000000000E+385 -> #7800000000000000 Overflow Rounded Inexact -maxExponent: 384 -minExponent: -383 - -dece051 apply 12345 -> #22380000000049c5 -dece052 apply #22380000000049c5 -> 12345 -dece053 apply 1234 -> #2238000000000534 -dece054 apply #2238000000000534 -> 1234 -dece055 apply 123 -> #22380000000000a3 -dece056 apply #22380000000000a3 -> 123 -dece057 apply 12 -> #2238000000000012 -dece058 apply #2238000000000012 -> 12 -dece059 apply 1 -> #2238000000000001 -dece060 apply #2238000000000001 -> 1 -dece061 apply 1.23 -> #22300000000000a3 -dece062 apply #22300000000000a3 -> 1.23 -dece063 apply 123.45 -> #22300000000049c5 -dece064 apply #22300000000049c5 -> 123.45 - --- Nmin and below -dece071 apply 1E-383 -> #003c000000000001 -dece072 apply #003c000000000001 -> 1E-383 -dece073 apply 1.000000000000000E-383 -> #0400000000000000 -dece074 apply #0400000000000000 -> 1.000000000000000E-383 -dece075 apply 1.000000000000001E-383 -> #0400000000000001 -dece076 apply #0400000000000001 -> 1.000000000000001E-383 - -dece077 apply 0.100000000000000E-383 -> #0000800000000000 Subnormal -dece078 apply #0000800000000000 -> 1.00000000000000E-384 Subnormal -dece079 apply 0.000000000000010E-383 -> #0000000000000010 Subnormal -dece080 apply #0000000000000010 -> 1.0E-397 Subnormal -dece081 apply 0.00000000000001E-383 -> #0004000000000001 Subnormal -dece082 apply #0004000000000001 -> 1E-397 Subnormal -dece083 apply 0.000000000000001E-383 -> #0000000000000001 Subnormal -dece084 apply #0000000000000001 -> 1E-398 Subnormal - --- underflows -dece090 apply 1e-398 -> #0000000000000001 Subnormal -dece091 apply 1.9e-398 -> #0000000000000002 Subnormal Underflow Inexact Rounded -dece092 apply 1.1e-398 -> #0000000000000001 Subnormal Underflow Inexact Rounded -dece093 apply 1.00000000001e-398 -> #0000000000000001 Subnormal Underflow Inexact Rounded -dece094 apply 1.00000000000001e-398 -> #0000000000000001 Subnormal Underflow Inexact Rounded -dece095 apply 1.000000000000001e-398 -> #0000000000000001 Subnormal Underflow Inexact Rounded -dece096 apply 0.1e-398 -> #0000000000000000 Subnormal Underflow Inexact Rounded -dece097 apply 0.00000000001e-398 -> #0000000000000000 Subnormal Underflow Inexact Rounded -dece098 apply 0.00000000000001e-398 -> #0000000000000000 Subnormal Underflow Inexact Rounded -dece099 apply 0.000000000000001e-398 -> #0000000000000000 Subnormal Underflow Inexact Rounded - --- Same again, negatives --- Nmax and similar -dece122 apply -9.999999999999999E+384 -> #f7fcff3fcff3fcff -dece123 apply #f7fcff3fcff3fcff -> -9.999999999999999E+384 -dece124 apply -1.234567890123456E+384 -> #c7fd34b9c1e28e56 -dece125 apply #c7fd34b9c1e28e56 -> -1.234567890123456E+384 --- fold-downs (more below) -dece130 apply -1.23E+384 -> #c7fd300000000000 Clamped -dece131 apply #c7fd300000000000 -> -1.230000000000000E+384 -dece132 apply -1E+384 -> #c7fc000000000000 Clamped -dece133 apply #c7fc000000000000 -> -1.000000000000000E+384 - --- overflows -maxExponent: 999 -- set high so conversion causes the overflow -minExponent: -999 -dece140 apply -10E+384 -> #f800000000000000 Overflow Rounded Inexact -dece141 apply -1.000000000000000E+385 -> #f800000000000000 Overflow Rounded Inexact -maxExponent: 384 -minExponent: -383 - -dece151 apply -12345 -> #a2380000000049c5 -dece152 apply #a2380000000049c5 -> -12345 -dece153 apply -1234 -> #a238000000000534 -dece154 apply #a238000000000534 -> -1234 -dece155 apply -123 -> #a2380000000000a3 -dece156 apply #a2380000000000a3 -> -123 -dece157 apply -12 -> #a238000000000012 -dece158 apply #a238000000000012 -> -12 -dece159 apply -1 -> #a238000000000001 -dece160 apply #a238000000000001 -> -1 -dece161 apply -1.23 -> #a2300000000000a3 -dece162 apply #a2300000000000a3 -> -1.23 -dece163 apply -123.45 -> #a2300000000049c5 -dece164 apply #a2300000000049c5 -> -123.45 - --- Nmin and below -dece171 apply -1E-383 -> #803c000000000001 -dece172 apply #803c000000000001 -> -1E-383 -dece173 apply -1.000000000000000E-383 -> #8400000000000000 -dece174 apply #8400000000000000 -> -1.000000000000000E-383 -dece175 apply -1.000000000000001E-383 -> #8400000000000001 -dece176 apply #8400000000000001 -> -1.000000000000001E-383 - -dece177 apply -0.100000000000000E-383 -> #8000800000000000 Subnormal -dece178 apply #8000800000000000 -> -1.00000000000000E-384 Subnormal -dece179 apply -0.000000000000010E-383 -> #8000000000000010 Subnormal -dece180 apply #8000000000000010 -> -1.0E-397 Subnormal -dece181 apply -0.00000000000001E-383 -> #8004000000000001 Subnormal -dece182 apply #8004000000000001 -> -1E-397 Subnormal -dece183 apply -0.000000000000001E-383 -> #8000000000000001 Subnormal -dece184 apply #8000000000000001 -> -1E-398 Subnormal - --- underflows -dece189 apply -1e-398 -> #8000000000000001 Subnormal -dece190 apply -1.0e-398 -> #8000000000000001 Subnormal Rounded -dece191 apply -1.9e-398 -> #8000000000000002 Subnormal Underflow Inexact Rounded -dece192 apply -1.1e-398 -> #8000000000000001 Subnormal Underflow Inexact Rounded -dece193 apply -1.00000000001e-398 -> #8000000000000001 Subnormal Underflow Inexact Rounded -dece194 apply -1.00000000000001e-398 -> #8000000000000001 Subnormal Underflow Inexact Rounded -dece195 apply -1.000000000000001e-398 -> #8000000000000001 Subnormal Underflow Inexact Rounded -dece196 apply -0.1e-398 -> #8000000000000000 Subnormal Underflow Inexact Rounded -dece197 apply -0.00000000001e-398 -> #8000000000000000 Subnormal Underflow Inexact Rounded -dece198 apply -0.00000000000001e-398 -> #8000000000000000 Subnormal Underflow Inexact Rounded -dece199 apply -0.000000000000001e-398 -> #8000000000000000 Subnormal Underflow Inexact Rounded - --- zeros -dece401 apply 0E-500 -> #0000000000000000 Clamped -dece402 apply 0E-400 -> #0000000000000000 Clamped -dece403 apply 0E-398 -> #0000000000000000 -dece404 apply #0000000000000000 -> 0E-398 -dece405 apply 0.000000000000000E-383 -> #0000000000000000 -dece406 apply #0000000000000000 -> 0E-398 -dece407 apply 0E-2 -> #2230000000000000 -dece408 apply #2230000000000000 -> 0.00 -dece409 apply 0 -> #2238000000000000 -dece410 apply #2238000000000000 -> 0 -dece411 apply 0E+3 -> #2244000000000000 -dece412 apply #2244000000000000 -> 0E+3 -dece413 apply 0E+369 -> #43fc000000000000 -dece414 apply #43fc000000000000 -> 0E+369 --- clamped zeros... -dece415 apply 0E+370 -> #43fc000000000000 Clamped -dece416 apply #43fc000000000000 -> 0E+369 -dece417 apply 0E+384 -> #43fc000000000000 Clamped -dece418 apply #43fc000000000000 -> 0E+369 -dece419 apply 0E+400 -> #43fc000000000000 Clamped -dece420 apply #43fc000000000000 -> 0E+369 -dece421 apply 0E+500 -> #43fc000000000000 Clamped -dece422 apply #43fc000000000000 -> 0E+369 - --- negative zeros -dece431 apply -0E-400 -> #8000000000000000 Clamped -dece432 apply -0E-400 -> #8000000000000000 Clamped -dece433 apply -0E-398 -> #8000000000000000 -dece434 apply #8000000000000000 -> -0E-398 -dece435 apply -0.000000000000000E-383 -> #8000000000000000 -dece436 apply #8000000000000000 -> -0E-398 -dece437 apply -0E-2 -> #a230000000000000 -dece438 apply #a230000000000000 -> -0.00 -dece439 apply -0 -> #a238000000000000 -dece440 apply #a238000000000000 -> -0 -dece441 apply -0E+3 -> #a244000000000000 -dece442 apply #a244000000000000 -> -0E+3 -dece443 apply -0E+369 -> #c3fc000000000000 -dece444 apply #c3fc000000000000 -> -0E+369 --- clamped zeros... -dece445 apply -0E+370 -> #c3fc000000000000 Clamped -dece446 apply #c3fc000000000000 -> -0E+369 -dece447 apply -0E+384 -> #c3fc000000000000 Clamped -dece448 apply #c3fc000000000000 -> -0E+369 -dece449 apply -0E+400 -> #c3fc000000000000 Clamped -dece450 apply #c3fc000000000000 -> -0E+369 -dece451 apply -0E+500 -> #c3fc000000000000 Clamped -dece452 apply #c3fc000000000000 -> -0E+369 - --- Specials -dece500 apply Infinity -> #7800000000000000 -dece501 apply #7878787878787878 -> #7800000000000000 -dece502 apply #7800000000000000 -> Infinity -dece503 apply #7979797979797979 -> #7800000000000000 -dece504 apply #7900000000000000 -> Infinity -dece505 apply #7a7a7a7a7a7a7a7a -> #7800000000000000 -dece506 apply #7a00000000000000 -> Infinity -dece507 apply #7b7b7b7b7b7b7b7b -> #7800000000000000 -dece508 apply #7b00000000000000 -> Infinity - -dece509 apply NaN -> #7c00000000000000 -dece510 apply #7c7c7c7c7c7c7c7c -> #7c007c7c7c7c7c7c -dece511 apply #7c00000000000000 -> NaN -dece512 apply #7d7d7d7d7d7d7d7d -> #7c017d7d7d7d7d7d -dece513 apply #7d00000000000000 -> NaN -dece514 apply #7e7e7e7e7e7e7e7e -> #7e007e7e7e7e7c7e -dece515 apply #7e00000000000000 -> sNaN -dece516 apply #7f7f7f7f7f7f7f7f -> #7e007f7f7f7f7c7f -dece517 apply #7f00000000000000 -> sNaN -dece518 apply #7fffffffffffffff -> sNaN999999999999999 -dece519 apply #7fffffffffffffff -> #7e00ff3fcff3fcff - -dece520 apply -Infinity -> #f800000000000000 -dece521 apply #f878787878787878 -> #f800000000000000 -dece522 apply #f800000000000000 -> -Infinity -dece523 apply #f979797979797979 -> #f800000000000000 -dece524 apply #f900000000000000 -> -Infinity -dece525 apply #fa7a7a7a7a7a7a7a -> #f800000000000000 -dece526 apply #fa00000000000000 -> -Infinity -dece527 apply #fb7b7b7b7b7b7b7b -> #f800000000000000 -dece528 apply #fb00000000000000 -> -Infinity - -dece529 apply -NaN -> #fc00000000000000 -dece530 apply #fc7c7c7c7c7c7c7c -> #fc007c7c7c7c7c7c -dece531 apply #fc00000000000000 -> -NaN -dece532 apply #fd7d7d7d7d7d7d7d -> #fc017d7d7d7d7d7d -dece533 apply #fd00000000000000 -> -NaN -dece534 apply #fe7e7e7e7e7e7e7e -> #fe007e7e7e7e7c7e -dece535 apply #fe00000000000000 -> -sNaN -dece536 apply #ff7f7f7f7f7f7f7f -> #fe007f7f7f7f7c7f -dece537 apply #ff00000000000000 -> -sNaN -dece538 apply #ffffffffffffffff -> -sNaN999999999999999 -dece539 apply #ffffffffffffffff -> #fe00ff3fcff3fcff - --- diagnostic NaNs -dece540 apply NaN -> #7c00000000000000 -dece541 apply NaN0 -> #7c00000000000000 -dece542 apply NaN1 -> #7c00000000000001 -dece543 apply NaN12 -> #7c00000000000012 -dece544 apply NaN79 -> #7c00000000000079 -dece545 apply NaN12345 -> #7c000000000049c5 -dece546 apply NaN123456 -> #7c00000000028e56 -dece547 apply NaN799799 -> #7c000000000f7fdf -dece548 apply NaN799799799799799 -> #7c03dff7fdff7fdf -dece549 apply NaN999999999999999 -> #7c00ff3fcff3fcff -dece550 apply NaN1234567890123456 -> #7c00000000000000 -- too many digits - --- fold-down full sequence -dece601 apply 1E+384 -> #47fc000000000000 Clamped -dece602 apply #47fc000000000000 -> 1.000000000000000E+384 -dece603 apply 1E+383 -> #43fc800000000000 Clamped -dece604 apply #43fc800000000000 -> 1.00000000000000E+383 -dece605 apply 1E+382 -> #43fc100000000000 Clamped -dece606 apply #43fc100000000000 -> 1.0000000000000E+382 -dece607 apply 1E+381 -> #43fc010000000000 Clamped -dece608 apply #43fc010000000000 -> 1.000000000000E+381 -dece609 apply 1E+380 -> #43fc002000000000 Clamped -dece610 apply #43fc002000000000 -> 1.00000000000E+380 -dece611 apply 1E+379 -> #43fc000400000000 Clamped -dece612 apply #43fc000400000000 -> 1.0000000000E+379 -dece613 apply 1E+378 -> #43fc000040000000 Clamped -dece614 apply #43fc000040000000 -> 1.000000000E+378 -dece615 apply 1E+377 -> #43fc000008000000 Clamped -dece616 apply #43fc000008000000 -> 1.00000000E+377 -dece617 apply 1E+376 -> #43fc000001000000 Clamped -dece618 apply #43fc000001000000 -> 1.0000000E+376 -dece619 apply 1E+375 -> #43fc000000100000 Clamped -dece620 apply #43fc000000100000 -> 1.000000E+375 -dece621 apply 1E+374 -> #43fc000000020000 Clamped -dece622 apply #43fc000000020000 -> 1.00000E+374 -dece623 apply 1E+373 -> #43fc000000004000 Clamped -dece624 apply #43fc000000004000 -> 1.0000E+373 -dece625 apply 1E+372 -> #43fc000000000400 Clamped -dece626 apply #43fc000000000400 -> 1.000E+372 -dece627 apply 1E+371 -> #43fc000000000080 Clamped -dece628 apply #43fc000000000080 -> 1.00E+371 -dece629 apply 1E+370 -> #43fc000000000010 Clamped -dece630 apply #43fc000000000010 -> 1.0E+370 -dece631 apply 1E+369 -> #43fc000000000001 -dece632 apply #43fc000000000001 -> 1E+369 -dece633 apply 1E+368 -> #43f8000000000001 -dece634 apply #43f8000000000001 -> 1E+368 --- same with 9s -dece641 apply 9E+384 -> #77fc000000000000 Clamped -dece642 apply #77fc000000000000 -> 9.000000000000000E+384 -dece643 apply 9E+383 -> #43fc8c0000000000 Clamped -dece644 apply #43fc8c0000000000 -> 9.00000000000000E+383 -dece645 apply 9E+382 -> #43fc1a0000000000 Clamped -dece646 apply #43fc1a0000000000 -> 9.0000000000000E+382 -dece647 apply 9E+381 -> #43fc090000000000 Clamped -dece648 apply #43fc090000000000 -> 9.000000000000E+381 -dece649 apply 9E+380 -> #43fc002300000000 Clamped -dece650 apply #43fc002300000000 -> 9.00000000000E+380 -dece651 apply 9E+379 -> #43fc000680000000 Clamped -dece652 apply #43fc000680000000 -> 9.0000000000E+379 -dece653 apply 9E+378 -> #43fc000240000000 Clamped -dece654 apply #43fc000240000000 -> 9.000000000E+378 -dece655 apply 9E+377 -> #43fc000008c00000 Clamped -dece656 apply #43fc000008c00000 -> 9.00000000E+377 -dece657 apply 9E+376 -> #43fc000001a00000 Clamped -dece658 apply #43fc000001a00000 -> 9.0000000E+376 -dece659 apply 9E+375 -> #43fc000000900000 Clamped -dece660 apply #43fc000000900000 -> 9.000000E+375 -dece661 apply 9E+374 -> #43fc000000023000 Clamped -dece662 apply #43fc000000023000 -> 9.00000E+374 -dece663 apply 9E+373 -> #43fc000000006800 Clamped -dece664 apply #43fc000000006800 -> 9.0000E+373 -dece665 apply 9E+372 -> #43fc000000002400 Clamped -dece666 apply #43fc000000002400 -> 9.000E+372 -dece667 apply 9E+371 -> #43fc00000000008c Clamped -dece668 apply #43fc00000000008c -> 9.00E+371 -dece669 apply 9E+370 -> #43fc00000000001a Clamped -dece670 apply #43fc00000000001a -> 9.0E+370 -dece671 apply 9E+369 -> #43fc000000000009 -dece672 apply #43fc000000000009 -> 9E+369 -dece673 apply 9E+368 -> #43f8000000000009 -dece674 apply #43f8000000000009 -> 9E+368 - - --- Selected DPD codes -dece700 apply #2238000000000000 -> 0 -dece701 apply #2238000000000009 -> 9 -dece702 apply #2238000000000010 -> 10 -dece703 apply #2238000000000019 -> 19 -dece704 apply #2238000000000020 -> 20 -dece705 apply #2238000000000029 -> 29 -dece706 apply #2238000000000030 -> 30 -dece707 apply #2238000000000039 -> 39 -dece708 apply #2238000000000040 -> 40 -dece709 apply #2238000000000049 -> 49 -dece710 apply #2238000000000050 -> 50 -dece711 apply #2238000000000059 -> 59 -dece712 apply #2238000000000060 -> 60 -dece713 apply #2238000000000069 -> 69 -dece714 apply #2238000000000070 -> 70 -dece715 apply #2238000000000071 -> 71 -dece716 apply #2238000000000072 -> 72 -dece717 apply #2238000000000073 -> 73 -dece718 apply #2238000000000074 -> 74 -dece719 apply #2238000000000075 -> 75 -dece720 apply #2238000000000076 -> 76 -dece721 apply #2238000000000077 -> 77 -dece722 apply #2238000000000078 -> 78 -dece723 apply #2238000000000079 -> 79 - -dece730 apply #223800000000029e -> 994 -dece731 apply #223800000000029f -> 995 -dece732 apply #22380000000002a0 -> 520 -dece733 apply #22380000000002a1 -> 521 - --- DPD: one of each of the huffman groups -dece740 apply #22380000000003f7 -> 777 -dece741 apply #22380000000003f8 -> 778 -dece742 apply #22380000000003eb -> 787 -dece743 apply #223800000000037d -> 877 -dece744 apply #223800000000039f -> 997 -dece745 apply #22380000000003bf -> 979 -dece746 apply #22380000000003df -> 799 -dece747 apply #223800000000006e -> 888 - - --- DPD all-highs cases (includes the 24 redundant codes) -dece750 apply #223800000000006e -> 888 -dece751 apply #223800000000016e -> 888 -dece752 apply #223800000000026e -> 888 -dece753 apply #223800000000036e -> 888 -dece754 apply #223800000000006f -> 889 -dece755 apply #223800000000016f -> 889 -dece756 apply #223800000000026f -> 889 -dece757 apply #223800000000036f -> 889 - -dece760 apply #223800000000007e -> 898 -dece761 apply #223800000000017e -> 898 -dece762 apply #223800000000027e -> 898 -dece763 apply #223800000000037e -> 898 -dece764 apply #223800000000007f -> 899 -dece765 apply #223800000000017f -> 899 -dece766 apply #223800000000027f -> 899 -dece767 apply #223800000000037f -> 899 - -dece770 apply #22380000000000ee -> 988 -dece771 apply #22380000000001ee -> 988 -dece772 apply #22380000000002ee -> 988 -dece773 apply #22380000000003ee -> 988 -dece774 apply #22380000000000ef -> 989 -dece775 apply #22380000000001ef -> 989 -dece776 apply #22380000000002ef -> 989 -dece777 apply #22380000000003ef -> 989 - -dece780 apply #22380000000000fe -> 998 -dece781 apply #22380000000001fe -> 998 -dece782 apply #22380000000002fe -> 998 -dece783 apply #22380000000003fe -> 998 -dece784 apply #22380000000000ff -> 999 -dece785 apply #22380000000001ff -> 999 -dece786 apply #22380000000002ff -> 999 -dece787 apply #22380000000003ff -> 999 - Modified: python/branches/release25-maint/Lib/test/decimaltestdata/divide.decTest ============================================================================== --- python/branches/release25-maint/Lib/test/decimaltestdata/divide.decTest (original) +++ python/branches/release25-maint/Lib/test/decimaltestdata/divide.decTest Tue Jan 8 17:20:31 2008 @@ -1,6 +1,6 @@ ------------------------------------------------------------------------ -- divide.decTest -- decimal division -- --- Copyright (c) IBM Corporation, 1981, 2004. All rights reserved. -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- ------------------------------------------------------------------------ -- Please see the document "General Decimal Arithmetic Testcases" -- -- at http://www2.hursley.ibm.com/decimal for the description of -- @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc at uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.39 +version: 2.57 extended: 1 precision: 9 @@ -47,41 +47,45 @@ divx018 divide 2. 2 -> 1 divx019 divide 20 20 -> 1 -divx020 divide 187 187 -> 1 -divx021 divide 5 2 -> 2.5 -divx022 divide 5 2.0 -> 2.5 -divx023 divide 5 2.000 -> 2.5 -divx024 divide 5 0.20 -> 25 -divx025 divide 5 0.200 -> 25 -divx026 divide 10 1 -> 10 -divx027 divide 100 1 -> 100 -divx028 divide 1000 1 -> 1000 -divx029 divide 1000 100 -> 10 - -divx030 divide 1 2 -> 0.5 -divx031 divide 1 4 -> 0.25 -divx032 divide 1 8 -> 0.125 -divx033 divide 1 16 -> 0.0625 -divx034 divide 1 32 -> 0.03125 -divx035 divide 1 64 -> 0.015625 -divx040 divide 1 -2 -> -0.5 -divx041 divide 1 -4 -> -0.25 -divx042 divide 1 -8 -> -0.125 -divx043 divide 1 -16 -> -0.0625 -divx044 divide 1 -32 -> -0.03125 -divx045 divide 1 -64 -> -0.015625 -divx050 divide -1 2 -> -0.5 -divx051 divide -1 4 -> -0.25 -divx052 divide -1 8 -> -0.125 -divx053 divide -1 16 -> -0.0625 -divx054 divide -1 32 -> -0.03125 -divx055 divide -1 64 -> -0.015625 -divx060 divide -1 -2 -> 0.5 -divx061 divide -1 -4 -> 0.25 -divx062 divide -1 -8 -> 0.125 -divx063 divide -1 -16 -> 0.0625 -divx064 divide -1 -32 -> 0.03125 -divx065 divide -1 -64 -> 0.015625 +divx020 divide 187 187 -> 1 +divx021 divide 5 2 -> 2.5 +divx022 divide 50 20 -> 2.5 +divx023 divide 500 200 -> 2.5 +divx024 divide 50.0 20.0 -> 2.5 +divx025 divide 5.00 2.00 -> 2.5 +divx026 divide 5 2.0 -> 2.5 +divx027 divide 5 2.000 -> 2.5 +divx028 divide 5 0.20 -> 25 +divx029 divide 5 0.200 -> 25 +divx030 divide 10 1 -> 10 +divx031 divide 100 1 -> 100 +divx032 divide 1000 1 -> 1000 +divx033 divide 1000 100 -> 10 + +divx035 divide 1 2 -> 0.5 +divx036 divide 1 4 -> 0.25 +divx037 divide 1 8 -> 0.125 +divx038 divide 1 16 -> 0.0625 +divx039 divide 1 32 -> 0.03125 +divx040 divide 1 64 -> 0.015625 +divx041 divide 1 -2 -> -0.5 +divx042 divide 1 -4 -> -0.25 +divx043 divide 1 -8 -> -0.125 +divx044 divide 1 -16 -> -0.0625 +divx045 divide 1 -32 -> -0.03125 +divx046 divide 1 -64 -> -0.015625 +divx047 divide -1 2 -> -0.5 +divx048 divide -1 4 -> -0.25 +divx049 divide -1 8 -> -0.125 +divx050 divide -1 16 -> -0.0625 +divx051 divide -1 32 -> -0.03125 +divx052 divide -1 64 -> -0.015625 +divx053 divide -1 -2 -> 0.5 +divx054 divide -1 -4 -> 0.25 +divx055 divide -1 -8 -> 0.125 +divx056 divide -1 -16 -> 0.0625 +divx057 divide -1 -32 -> 0.03125 +divx058 divide -1 -64 -> 0.015625 divx070 divide 999999999 1 -> 999999999 divx071 divide 999999999.4 1 -> 999999999 Inexact Rounded @@ -763,9 +767,9 @@ divx964 divide 1e-600000000 1e+400000005 -> 1E-1000000005 Subnormal divx965 divide 1e-600000000 1e+400000006 -> 1E-1000000006 Subnormal divx966 divide 1e-600000000 1e+400000007 -> 1E-1000000007 Subnormal -divx967 divide 1e-600000000 1e+400000008 -> 0E-1000000007 Underflow Subnormal Inexact Rounded -divx968 divide 1e-600000000 1e+400000009 -> 0E-1000000007 Underflow Subnormal Inexact Rounded -divx969 divide 1e-600000000 1e+400000010 -> 0E-1000000007 Underflow Subnormal Inexact Rounded +divx967 divide 1e-600000000 1e+400000008 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped +divx968 divide 1e-600000000 1e+400000009 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped +divx969 divide 1e-600000000 1e+400000010 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped -- [no equivalent of 'subnormal' for overflow] divx970 divide 1e+600000000 1e-400000001 -> Infinity Overflow Inexact Rounded divx971 divide 1e+600000000 1e-400000002 -> Infinity Overflow Inexact Rounded @@ -779,10 +783,10 @@ divx979 divide 1e+600000000 1e-400000010 -> Infinity Overflow Inexact Rounded -- Sign after overflow and underflow -divx980 divide 1e-600000000 1e+400000009 -> 0E-1000000007 Underflow Subnormal Inexact Rounded -divx981 divide 1e-600000000 -1e+400000009 -> -0E-1000000007 Underflow Subnormal Inexact Rounded -divx982 divide -1e-600000000 1e+400000009 -> -0E-1000000007 Underflow Subnormal Inexact Rounded -divx983 divide -1e-600000000 -1e+400000009 -> 0E-1000000007 Underflow Subnormal Inexact Rounded +divx980 divide 1e-600000000 1e+400000009 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped +divx981 divide 1e-600000000 -1e+400000009 -> -0E-1000000007 Underflow Subnormal Inexact Rounded Clamped +divx982 divide -1e-600000000 1e+400000009 -> -0E-1000000007 Underflow Subnormal Inexact Rounded Clamped +divx983 divide -1e-600000000 -1e+400000009 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped divx984 divide 1e+600000000 1e-400000009 -> Infinity Overflow Inexact Rounded divx985 divide 1e+600000000 -1e-400000009 -> -Infinity Overflow Inexact Rounded divx986 divide -1e+600000000 1e-400000009 -> -Infinity Overflow Inexact Rounded @@ -812,6 +816,38 @@ -- 1.465811965811965811965811965811965811966E+7000 divx1010 divide 343E6000 234E-1000 -> Infinity Overflow Inexact Rounded +precision: 34 +rounding: half_up +maxExponent: 6144 +minExponent: -6143 + +-- Examples from SQL proposal (Krishna Kulkarni) +precision: 7 +divx1021 divide 1E0 1E0 -> 1 +divx1022 divide 1E0 2E0 -> 0.5 +divx1023 divide 1E0 3E0 -> 0.3333333 Inexact Rounded +divx1024 divide 100E-2 1000E-3 -> 1 +divx1025 divide 24E-1 2E0 -> 1.2 +divx1026 divide 2400E-3 2E0 -> 1.200 +divx1027 divide 5E0 2E0 -> 2.5 +divx1028 divide 5E0 20E-1 -> 2.5 +divx1029 divide 5E0 2000E-3 -> 2.5 +divx1030 divide 5E0 2E-1 -> 25 +divx1031 divide 5E0 20E-2 -> 25 +divx1032 divide 480E-2 3E0 -> 1.60 +divx1033 divide 47E-1 2E0 -> 2.35 + +-- ECMAScript bad examples +rounding: half_down +precision: 7 +divx1050 divide 5 9 -> 0.5555556 Inexact Rounded +rounding: half_even +divx1051 divide 5 11 -> 0.4545455 Inexact Rounded + +-- payload decapitate +precision: 5 +divx1055 divide sNaN987654321 1 -> NaN54321 Invalid_operation + -- Null tests divx9998 divide 10 # -> NaN Invalid_operation divx9999 divide # 10 -> NaN Invalid_operation Modified: python/branches/release25-maint/Lib/test/decimaltestdata/divideint.decTest ============================================================================== --- python/branches/release25-maint/Lib/test/decimaltestdata/divideint.decTest (original) +++ python/branches/release25-maint/Lib/test/decimaltestdata/divideint.decTest Tue Jan 8 17:20:31 2008 @@ -1,6 +1,6 @@ ------------------------------------------------------------------------ -- divideint.decTest -- decimal integer division -- --- Copyright (c) IBM Corporation, 1981, 2004. All rights reserved. -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- ------------------------------------------------------------------------ -- Please see the document "General Decimal Arithmetic Testcases" -- -- at http://www2.hursley.ibm.com/decimal for the description of -- @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc at uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.39 +version: 2.57 extended: 1 precision: 9 @@ -234,6 +234,22 @@ dvix287 divideint 0.1 9999e-999999997 -> NaN Division_impossible dvix288 divideint 0.1 99999e-999999997 -> NaN Division_impossible +-- GD edge cases: lhs smaller than rhs but more digits +dvix301 divideint 0.9 2 -> 0 +dvix302 divideint 0.9 2.0 -> 0 +dvix303 divideint 0.9 2.1 -> 0 +dvix304 divideint 0.9 2.00 -> 0 +dvix305 divideint 0.9 2.01 -> 0 +dvix306 divideint 0.12 1 -> 0 +dvix307 divideint 0.12 1.0 -> 0 +dvix308 divideint 0.12 1.00 -> 0 +dvix309 divideint 0.12 1.0 -> 0 +dvix310 divideint 0.12 1.00 -> 0 +dvix311 divideint 0.12 2 -> 0 +dvix312 divideint 0.12 2.0 -> 0 +dvix313 divideint 0.12 2.1 -> 0 +dvix314 divideint 0.12 2.00 -> 0 +dvix315 divideint 0.12 2.01 -> 0 -- overflow and underflow tests [from divide] maxexponent: 999999999 Added: python/branches/release25-maint/Lib/test/decimaltestdata/dqAbs.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/dqAbs.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,126 @@ +------------------------------------------------------------------------ +-- dqAbs.decTest -- decQuad absolute value, heeding sNaN -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +extended: 1 +clamp: 1 +precision: 34 +maxExponent: 6144 +minExponent: -6143 +rounding: half_even + +dqabs001 abs '1' -> '1' +dqabs002 abs '-1' -> '1' +dqabs003 abs '1.00' -> '1.00' +dqabs004 abs '-1.00' -> '1.00' +dqabs005 abs '0' -> '0' +dqabs006 abs '0.00' -> '0.00' +dqabs007 abs '00.0' -> '0.0' +dqabs008 abs '00.00' -> '0.00' +dqabs009 abs '00' -> '0' + +dqabs010 abs '-2' -> '2' +dqabs011 abs '2' -> '2' +dqabs012 abs '-2.00' -> '2.00' +dqabs013 abs '2.00' -> '2.00' +dqabs014 abs '-0' -> '0' +dqabs015 abs '-0.00' -> '0.00' +dqabs016 abs '-00.0' -> '0.0' +dqabs017 abs '-00.00' -> '0.00' +dqabs018 abs '-00' -> '0' + +dqabs020 abs '-2000000' -> '2000000' +dqabs021 abs '2000000' -> '2000000' + +dqabs030 abs '+0.1' -> '0.1' +dqabs031 abs '-0.1' -> '0.1' +dqabs032 abs '+0.01' -> '0.01' +dqabs033 abs '-0.01' -> '0.01' +dqabs034 abs '+0.001' -> '0.001' +dqabs035 abs '-0.001' -> '0.001' +dqabs036 abs '+0.000001' -> '0.000001' +dqabs037 abs '-0.000001' -> '0.000001' +dqabs038 abs '+0.000000000001' -> '1E-12' +dqabs039 abs '-0.000000000001' -> '1E-12' + +-- examples from decArith +dqabs040 abs '2.1' -> '2.1' +dqabs041 abs '-100' -> '100' +dqabs042 abs '101.5' -> '101.5' +dqabs043 abs '-101.5' -> '101.5' + +-- more fixed, potential LHS swaps/overlays if done by subtract 0 +dqabs060 abs '-56267E-10' -> '0.0000056267' +dqabs061 abs '-56267E-5' -> '0.56267' +dqabs062 abs '-56267E-2' -> '562.67' +dqabs063 abs '-56267E-1' -> '5626.7' +dqabs065 abs '-56267E-0' -> '56267' + +-- subnormals and underflow + +-- long operand tests +dqabs321 abs 1234567890123456 -> 1234567890123456 +dqabs322 abs 12345678000 -> 12345678000 +dqabs323 abs 1234567800 -> 1234567800 +dqabs324 abs 1234567890 -> 1234567890 +dqabs325 abs 1234567891 -> 1234567891 +dqabs326 abs 12345678901 -> 12345678901 +dqabs327 abs 1234567896 -> 1234567896 + +-- zeros +dqabs111 abs 0 -> 0 +dqabs112 abs -0 -> 0 +dqabs113 abs 0E+6 -> 0E+6 +dqabs114 abs -0E+6 -> 0E+6 +dqabs115 abs 0.0000 -> 0.0000 +dqabs116 abs -0.0000 -> 0.0000 +dqabs117 abs 0E-141 -> 0E-141 +dqabs118 abs -0E-141 -> 0E-141 + +-- full coefficients, alternating bits +dqabs121 abs 2682682682682682682682682682682682 -> 2682682682682682682682682682682682 +dqabs122 abs -2682682682682682682682682682682682 -> 2682682682682682682682682682682682 +dqabs123 abs 1341341341341341341341341341341341 -> 1341341341341341341341341341341341 +dqabs124 abs -1341341341341341341341341341341341 -> 1341341341341341341341341341341341 + +-- Nmax, Nmin, Ntiny +dqabs131 abs 9.999999999999999999999999999999999E+6144 -> 9.999999999999999999999999999999999E+6144 +dqabs132 abs 1E-6143 -> 1E-6143 +dqabs133 abs 1.000000000000000000000000000000000E-6143 -> 1.000000000000000000000000000000000E-6143 +dqabs134 abs 1E-6176 -> 1E-6176 Subnormal + +dqabs135 abs -1E-6176 -> 1E-6176 Subnormal +dqabs136 abs -1.000000000000000000000000000000000E-6143 -> 1.000000000000000000000000000000000E-6143 +dqabs137 abs -1E-6143 -> 1E-6143 +dqabs138 abs -9.999999999999999999999999999999999E+6144 -> 9.999999999999999999999999999999999E+6144 + +-- specials +dqabs520 abs 'Inf' -> 'Infinity' +dqabs521 abs '-Inf' -> 'Infinity' +dqabs522 abs NaN -> NaN +dqabs523 abs sNaN -> NaN Invalid_operation +dqabs524 abs NaN22 -> NaN22 +dqabs525 abs sNaN33 -> NaN33 Invalid_operation +dqabs526 abs -NaN22 -> -NaN22 +dqabs527 abs -sNaN33 -> -NaN33 Invalid_operation + +-- Null tests +dqabs900 abs # -> NaN Invalid_operation + Added: python/branches/release25-maint/Lib/test/decimaltestdata/dqAdd.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/dqAdd.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,1157 @@ +------------------------------------------------------------------------ +-- dqAdd.decTest -- decQuad addition -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- This set of tests are for decQuads only; all arguments are +-- representable in a decQuad +extended: 1 +clamp: 1 +precision: 34 +maxExponent: 6144 +minExponent: -6143 +rounding: half_even + +-- [first group are 'quick confidence check'] +dqadd001 add 1 1 -> 2 +dqadd002 add 2 3 -> 5 +dqadd003 add '5.75' '3.3' -> 9.05 +dqadd004 add '5' '-3' -> 2 +dqadd005 add '-5' '-3' -> -8 +dqadd006 add '-7' '2.5' -> -4.5 +dqadd007 add '0.7' '0.3' -> 1.0 +dqadd008 add '1.25' '1.25' -> 2.50 +dqadd009 add '1.23456789' '1.00000000' -> '2.23456789' +dqadd010 add '1.23456789' '1.00000011' -> '2.23456800' + +-- 1234567890123456 1234567890123456 +dqadd011 add '0.4444444444444444444444444444444446' '0.5555555555555555555555555555555555' -> '1.000000000000000000000000000000000' Inexact Rounded +dqadd012 add '0.4444444444444444444444444444444445' '0.5555555555555555555555555555555555' -> '1.000000000000000000000000000000000' Rounded +dqadd013 add '0.4444444444444444444444444444444444' '0.5555555555555555555555555555555555' -> '0.9999999999999999999999999999999999' +dqadd014 add '4444444444444444444444444444444444' '0.49' -> '4444444444444444444444444444444444' Inexact Rounded +dqadd015 add '4444444444444444444444444444444444' '0.499' -> '4444444444444444444444444444444444' Inexact Rounded +dqadd016 add '4444444444444444444444444444444444' '0.4999' -> '4444444444444444444444444444444444' Inexact Rounded +dqadd017 add '4444444444444444444444444444444444' '0.5000' -> '4444444444444444444444444444444444' Inexact Rounded +dqadd018 add '4444444444444444444444444444444444' '0.5001' -> '4444444444444444444444444444444445' Inexact Rounded +dqadd019 add '4444444444444444444444444444444444' '0.501' -> '4444444444444444444444444444444445' Inexact Rounded +dqadd020 add '4444444444444444444444444444444444' '0.51' -> '4444444444444444444444444444444445' Inexact Rounded + +dqadd021 add 0 1 -> 1 +dqadd022 add 1 1 -> 2 +dqadd023 add 2 1 -> 3 +dqadd024 add 3 1 -> 4 +dqadd025 add 4 1 -> 5 +dqadd026 add 5 1 -> 6 +dqadd027 add 6 1 -> 7 +dqadd028 add 7 1 -> 8 +dqadd029 add 8 1 -> 9 +dqadd030 add 9 1 -> 10 + +-- some carrying effects +dqadd031 add '0.9998' '0.0000' -> '0.9998' +dqadd032 add '0.9998' '0.0001' -> '0.9999' +dqadd033 add '0.9998' '0.0002' -> '1.0000' +dqadd034 add '0.9998' '0.0003' -> '1.0001' + +dqadd035 add '70' '10000e+34' -> '1.000000000000000000000000000000000E+38' Inexact Rounded +dqadd036 add '700' '10000e+34' -> '1.000000000000000000000000000000000E+38' Inexact Rounded +dqadd037 add '7000' '10000e+34' -> '1.000000000000000000000000000000000E+38' Inexact Rounded +dqadd038 add '70000' '10000e+34' -> '1.000000000000000000000000000000001E+38' Inexact Rounded +dqadd039 add '700000' '10000e+34' -> '1.000000000000000000000000000000007E+38' Rounded + +-- symmetry: +dqadd040 add '10000e+34' '70' -> '1.000000000000000000000000000000000E+38' Inexact Rounded +dqadd041 add '10000e+34' '700' -> '1.000000000000000000000000000000000E+38' Inexact Rounded +dqadd042 add '10000e+34' '7000' -> '1.000000000000000000000000000000000E+38' Inexact Rounded +dqadd044 add '10000e+34' '70000' -> '1.000000000000000000000000000000001E+38' Inexact Rounded +dqadd045 add '10000e+34' '700000' -> '1.000000000000000000000000000000007E+38' Rounded + +-- same, without rounding +dqadd046 add '10000e+9' '7' -> '10000000000007' +dqadd047 add '10000e+9' '70' -> '10000000000070' +dqadd048 add '10000e+9' '700' -> '10000000000700' +dqadd049 add '10000e+9' '7000' -> '10000000007000' +dqadd050 add '10000e+9' '70000' -> '10000000070000' +dqadd051 add '10000e+9' '700000' -> '10000000700000' +dqadd052 add '10000e+9' '7000000' -> '10000007000000' + +-- examples from decarith +dqadd053 add '12' '7.00' -> '19.00' +dqadd054 add '1.3' '-1.07' -> '0.23' +dqadd055 add '1.3' '-1.30' -> '0.00' +dqadd056 add '1.3' '-2.07' -> '-0.77' +dqadd057 add '1E+2' '1E+4' -> '1.01E+4' + +-- leading zero preservation +dqadd061 add 1 '0.0001' -> '1.0001' +dqadd062 add 1 '0.00001' -> '1.00001' +dqadd063 add 1 '0.000001' -> '1.000001' +dqadd064 add 1 '0.0000001' -> '1.0000001' +dqadd065 add 1 '0.00000001' -> '1.00000001' + +-- some funny zeros [in case of bad signum] +dqadd070 add 1 0 -> 1 +dqadd071 add 1 0. -> 1 +dqadd072 add 1 .0 -> 1.0 +dqadd073 add 1 0.0 -> 1.0 +dqadd074 add 1 0.00 -> 1.00 +dqadd075 add 0 1 -> 1 +dqadd076 add 0. 1 -> 1 +dqadd077 add .0 1 -> 1.0 +dqadd078 add 0.0 1 -> 1.0 +dqadd079 add 0.00 1 -> 1.00 + +-- some carries +dqadd080 add 999999998 1 -> 999999999 +dqadd081 add 999999999 1 -> 1000000000 +dqadd082 add 99999999 1 -> 100000000 +dqadd083 add 9999999 1 -> 10000000 +dqadd084 add 999999 1 -> 1000000 +dqadd085 add 99999 1 -> 100000 +dqadd086 add 9999 1 -> 10000 +dqadd087 add 999 1 -> 1000 +dqadd088 add 99 1 -> 100 +dqadd089 add 9 1 -> 10 + + +-- more LHS swaps +dqadd090 add '-56267E-10' 0 -> '-0.0000056267' +dqadd091 add '-56267E-6' 0 -> '-0.056267' +dqadd092 add '-56267E-5' 0 -> '-0.56267' +dqadd093 add '-56267E-4' 0 -> '-5.6267' +dqadd094 add '-56267E-3' 0 -> '-56.267' +dqadd095 add '-56267E-2' 0 -> '-562.67' +dqadd096 add '-56267E-1' 0 -> '-5626.7' +dqadd097 add '-56267E-0' 0 -> '-56267' +dqadd098 add '-5E-10' 0 -> '-5E-10' +dqadd099 add '-5E-7' 0 -> '-5E-7' +dqadd100 add '-5E-6' 0 -> '-0.000005' +dqadd101 add '-5E-5' 0 -> '-0.00005' +dqadd102 add '-5E-4' 0 -> '-0.0005' +dqadd103 add '-5E-1' 0 -> '-0.5' +dqadd104 add '-5E0' 0 -> '-5' +dqadd105 add '-5E1' 0 -> '-50' +dqadd106 add '-5E5' 0 -> '-500000' +dqadd107 add '-5E33' 0 -> '-5000000000000000000000000000000000' +dqadd108 add '-5E34' 0 -> '-5.000000000000000000000000000000000E+34' Rounded +dqadd109 add '-5E35' 0 -> '-5.000000000000000000000000000000000E+35' Rounded +dqadd110 add '-5E36' 0 -> '-5.000000000000000000000000000000000E+36' Rounded +dqadd111 add '-5E100' 0 -> '-5.000000000000000000000000000000000E+100' Rounded + +-- more RHS swaps +dqadd113 add 0 '-56267E-10' -> '-0.0000056267' +dqadd114 add 0 '-56267E-6' -> '-0.056267' +dqadd116 add 0 '-56267E-5' -> '-0.56267' +dqadd117 add 0 '-56267E-4' -> '-5.6267' +dqadd119 add 0 '-56267E-3' -> '-56.267' +dqadd120 add 0 '-56267E-2' -> '-562.67' +dqadd121 add 0 '-56267E-1' -> '-5626.7' +dqadd122 add 0 '-56267E-0' -> '-56267' +dqadd123 add 0 '-5E-10' -> '-5E-10' +dqadd124 add 0 '-5E-7' -> '-5E-7' +dqadd125 add 0 '-5E-6' -> '-0.000005' +dqadd126 add 0 '-5E-5' -> '-0.00005' +dqadd127 add 0 '-5E-4' -> '-0.0005' +dqadd128 add 0 '-5E-1' -> '-0.5' +dqadd129 add 0 '-5E0' -> '-5' +dqadd130 add 0 '-5E1' -> '-50' +dqadd131 add 0 '-5E5' -> '-500000' +dqadd132 add 0 '-5E33' -> '-5000000000000000000000000000000000' +dqadd133 add 0 '-5E34' -> '-5.000000000000000000000000000000000E+34' Rounded +dqadd134 add 0 '-5E35' -> '-5.000000000000000000000000000000000E+35' Rounded +dqadd135 add 0 '-5E36' -> '-5.000000000000000000000000000000000E+36' Rounded +dqadd136 add 0 '-5E100' -> '-5.000000000000000000000000000000000E+100' Rounded + +-- related +dqadd137 add 1 '0E-39' -> '1.000000000000000000000000000000000' Rounded +dqadd138 add -1 '0E-39' -> '-1.000000000000000000000000000000000' Rounded +dqadd139 add '0E-39' 1 -> '1.000000000000000000000000000000000' Rounded +dqadd140 add '0E-39' -1 -> '-1.000000000000000000000000000000000' Rounded +dqadd141 add 1E+29 0.0000 -> '100000000000000000000000000000.0000' +dqadd142 add 1E+29 0.00000 -> '100000000000000000000000000000.0000' Rounded +dqadd143 add 0.000 1E+30 -> '1000000000000000000000000000000.000' +dqadd144 add 0.0000 1E+30 -> '1000000000000000000000000000000.000' Rounded + +-- [some of the next group are really constructor tests] +dqadd146 add '00.0' 0 -> '0.0' +dqadd147 add '0.00' 0 -> '0.00' +dqadd148 add 0 '0.00' -> '0.00' +dqadd149 add 0 '00.0' -> '0.0' +dqadd150 add '00.0' '0.00' -> '0.00' +dqadd151 add '0.00' '00.0' -> '0.00' +dqadd152 add '3' '.3' -> '3.3' +dqadd153 add '3.' '.3' -> '3.3' +dqadd154 add '3.0' '.3' -> '3.3' +dqadd155 add '3.00' '.3' -> '3.30' +dqadd156 add '3' '3' -> '6' +dqadd157 add '3' '+3' -> '6' +dqadd158 add '3' '-3' -> '0' +dqadd159 add '0.3' '-0.3' -> '0.0' +dqadd160 add '0.03' '-0.03' -> '0.00' + +-- try borderline precision, with carries, etc. +dqadd161 add '1E+12' '-1' -> '999999999999' +dqadd162 add '1E+12' '1.11' -> '1000000000001.11' +dqadd163 add '1.11' '1E+12' -> '1000000000001.11' +dqadd164 add '-1' '1E+12' -> '999999999999' +dqadd165 add '7E+12' '-1' -> '6999999999999' +dqadd166 add '7E+12' '1.11' -> '7000000000001.11' +dqadd167 add '1.11' '7E+12' -> '7000000000001.11' +dqadd168 add '-1' '7E+12' -> '6999999999999' + +rounding: half_up +dqadd170 add '4.444444444444444444444444444444444' '0.5555555555555555555555555555555567' -> '5.000000000000000000000000000000001' Inexact Rounded +dqadd171 add '4.444444444444444444444444444444444' '0.5555555555555555555555555555555566' -> '5.000000000000000000000000000000001' Inexact Rounded +dqadd172 add '4.444444444444444444444444444444444' '0.5555555555555555555555555555555565' -> '5.000000000000000000000000000000001' Inexact Rounded +dqadd173 add '4.444444444444444444444444444444444' '0.5555555555555555555555555555555564' -> '5.000000000000000000000000000000000' Inexact Rounded +dqadd174 add '4.444444444444444444444444444444444' '0.5555555555555555555555555555555553' -> '4.999999999999999999999999999999999' Inexact Rounded +dqadd175 add '4.444444444444444444444444444444444' '0.5555555555555555555555555555555552' -> '4.999999999999999999999999999999999' Inexact Rounded +dqadd176 add '4.444444444444444444444444444444444' '0.5555555555555555555555555555555551' -> '4.999999999999999999999999999999999' Inexact Rounded +dqadd177 add '4.444444444444444444444444444444444' '0.5555555555555555555555555555555550' -> '4.999999999999999999999999999999999' Rounded +dqadd178 add '4.444444444444444444444444444444444' '0.5555555555555555555555555555555545' -> '4.999999999999999999999999999999999' Inexact Rounded +dqadd179 add '4.444444444444444444444444444444444' '0.5555555555555555555555555555555544' -> '4.999999999999999999999999999999998' Inexact Rounded +dqadd180 add '4.444444444444444444444444444444444' '0.5555555555555555555555555555555543' -> '4.999999999999999999999999999999998' Inexact Rounded +dqadd181 add '4.444444444444444444444444444444444' '0.5555555555555555555555555555555542' -> '4.999999999999999999999999999999998' Inexact Rounded +dqadd182 add '4.444444444444444444444444444444444' '0.5555555555555555555555555555555541' -> '4.999999999999999999999999999999998' Inexact Rounded +dqadd183 add '4.444444444444444444444444444444444' '0.5555555555555555555555555555555540' -> '4.999999999999999999999999999999998' Rounded + +-- and some more, including residue effects and different roundings +rounding: half_up +dqadd200 add '1231234567890123456784560123456789' 0 -> '1231234567890123456784560123456789' +dqadd201 add '1231234567890123456784560123456789' 0.000000001 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd202 add '1231234567890123456784560123456789' 0.000001 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd203 add '1231234567890123456784560123456789' 0.1 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd204 add '1231234567890123456784560123456789' 0.4 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd205 add '1231234567890123456784560123456789' 0.49 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd206 add '1231234567890123456784560123456789' 0.499999 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd207 add '1231234567890123456784560123456789' 0.499999999 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd208 add '1231234567890123456784560123456789' 0.5 -> '1231234567890123456784560123456790' Inexact Rounded +dqadd209 add '1231234567890123456784560123456789' 0.500000001 -> '1231234567890123456784560123456790' Inexact Rounded +dqadd210 add '1231234567890123456784560123456789' 0.500001 -> '1231234567890123456784560123456790' Inexact Rounded +dqadd211 add '1231234567890123456784560123456789' 0.51 -> '1231234567890123456784560123456790' Inexact Rounded +dqadd212 add '1231234567890123456784560123456789' 0.6 -> '1231234567890123456784560123456790' Inexact Rounded +dqadd213 add '1231234567890123456784560123456789' 0.9 -> '1231234567890123456784560123456790' Inexact Rounded +dqadd214 add '1231234567890123456784560123456789' 0.99999 -> '1231234567890123456784560123456790' Inexact Rounded +dqadd215 add '1231234567890123456784560123456789' 0.999999999 -> '1231234567890123456784560123456790' Inexact Rounded +dqadd216 add '1231234567890123456784560123456789' 1 -> '1231234567890123456784560123456790' +dqadd217 add '1231234567890123456784560123456789' 1.000000001 -> '1231234567890123456784560123456790' Inexact Rounded +dqadd218 add '1231234567890123456784560123456789' 1.00001 -> '1231234567890123456784560123456790' Inexact Rounded +dqadd219 add '1231234567890123456784560123456789' 1.1 -> '1231234567890123456784560123456790' Inexact Rounded + +rounding: half_even +dqadd220 add '1231234567890123456784560123456789' 0 -> '1231234567890123456784560123456789' +dqadd221 add '1231234567890123456784560123456789' 0.000000001 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd222 add '1231234567890123456784560123456789' 0.000001 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd223 add '1231234567890123456784560123456789' 0.1 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd224 add '1231234567890123456784560123456789' 0.4 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd225 add '1231234567890123456784560123456789' 0.49 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd226 add '1231234567890123456784560123456789' 0.499999 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd227 add '1231234567890123456784560123456789' 0.499999999 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd228 add '1231234567890123456784560123456789' 0.5 -> '1231234567890123456784560123456790' Inexact Rounded +dqadd229 add '1231234567890123456784560123456789' 0.500000001 -> '1231234567890123456784560123456790' Inexact Rounded +dqadd230 add '1231234567890123456784560123456789' 0.500001 -> '1231234567890123456784560123456790' Inexact Rounded +dqadd231 add '1231234567890123456784560123456789' 0.51 -> '1231234567890123456784560123456790' Inexact Rounded +dqadd232 add '1231234567890123456784560123456789' 0.6 -> '1231234567890123456784560123456790' Inexact Rounded +dqadd233 add '1231234567890123456784560123456789' 0.9 -> '1231234567890123456784560123456790' Inexact Rounded +dqadd234 add '1231234567890123456784560123456789' 0.99999 -> '1231234567890123456784560123456790' Inexact Rounded +dqadd235 add '1231234567890123456784560123456789' 0.999999999 -> '1231234567890123456784560123456790' Inexact Rounded +dqadd236 add '1231234567890123456784560123456789' 1 -> '1231234567890123456784560123456790' +dqadd237 add '1231234567890123456784560123456789' 1.00000001 -> '1231234567890123456784560123456790' Inexact Rounded +dqadd238 add '1231234567890123456784560123456789' 1.00001 -> '1231234567890123456784560123456790' Inexact Rounded +dqadd239 add '1231234567890123456784560123456789' 1.1 -> '1231234567890123456784560123456790' Inexact Rounded +-- critical few with even bottom digit... +dqadd240 add '1231234567890123456784560123456788' 0.499999999 -> '1231234567890123456784560123456788' Inexact Rounded +dqadd241 add '1231234567890123456784560123456788' 0.5 -> '1231234567890123456784560123456788' Inexact Rounded +dqadd242 add '1231234567890123456784560123456788' 0.500000001 -> '1231234567890123456784560123456789' Inexact Rounded + +rounding: down +dqadd250 add '1231234567890123456784560123456789' 0 -> '1231234567890123456784560123456789' +dqadd251 add '1231234567890123456784560123456789' 0.000000001 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd252 add '1231234567890123456784560123456789' 0.000001 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd253 add '1231234567890123456784560123456789' 0.1 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd254 add '1231234567890123456784560123456789' 0.4 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd255 add '1231234567890123456784560123456789' 0.49 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd256 add '1231234567890123456784560123456789' 0.499999 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd257 add '1231234567890123456784560123456789' 0.499999999 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd258 add '1231234567890123456784560123456789' 0.5 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd259 add '1231234567890123456784560123456789' 0.500000001 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd260 add '1231234567890123456784560123456789' 0.500001 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd261 add '1231234567890123456784560123456789' 0.51 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd262 add '1231234567890123456784560123456789' 0.6 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd263 add '1231234567890123456784560123456789' 0.9 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd264 add '1231234567890123456784560123456789' 0.99999 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd265 add '1231234567890123456784560123456789' 0.999999999 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd266 add '1231234567890123456784560123456789' 1 -> '1231234567890123456784560123456790' +dqadd267 add '1231234567890123456784560123456789' 1.00000001 -> '1231234567890123456784560123456790' Inexact Rounded +dqadd268 add '1231234567890123456784560123456789' 1.00001 -> '1231234567890123456784560123456790' Inexact Rounded +dqadd269 add '1231234567890123456784560123456789' 1.1 -> '1231234567890123456784560123456790' Inexact Rounded + +-- 1 in last place tests +rounding: half_up +dqadd301 add -1 1 -> 0 +dqadd302 add 0 1 -> 1 +dqadd303 add 1 1 -> 2 +dqadd304 add 12 1 -> 13 +dqadd305 add 98 1 -> 99 +dqadd306 add 99 1 -> 100 +dqadd307 add 100 1 -> 101 +dqadd308 add 101 1 -> 102 +dqadd309 add -1 -1 -> -2 +dqadd310 add 0 -1 -> -1 +dqadd311 add 1 -1 -> 0 +dqadd312 add 12 -1 -> 11 +dqadd313 add 98 -1 -> 97 +dqadd314 add 99 -1 -> 98 +dqadd315 add 100 -1 -> 99 +dqadd316 add 101 -1 -> 100 + +dqadd321 add -0.01 0.01 -> 0.00 +dqadd322 add 0.00 0.01 -> 0.01 +dqadd323 add 0.01 0.01 -> 0.02 +dqadd324 add 0.12 0.01 -> 0.13 +dqadd325 add 0.98 0.01 -> 0.99 +dqadd326 add 0.99 0.01 -> 1.00 +dqadd327 add 1.00 0.01 -> 1.01 +dqadd328 add 1.01 0.01 -> 1.02 +dqadd329 add -0.01 -0.01 -> -0.02 +dqadd330 add 0.00 -0.01 -> -0.01 +dqadd331 add 0.01 -0.01 -> 0.00 +dqadd332 add 0.12 -0.01 -> 0.11 +dqadd333 add 0.98 -0.01 -> 0.97 +dqadd334 add 0.99 -0.01 -> 0.98 +dqadd335 add 1.00 -0.01 -> 0.99 +dqadd336 add 1.01 -0.01 -> 1.00 + +-- some more cases where adding 0 affects the coefficient +dqadd340 add 1E+3 0 -> 1000 +dqadd341 add 1E+33 0 -> 1000000000000000000000000000000000 +dqadd342 add 1E+34 0 -> 1.000000000000000000000000000000000E+34 Rounded +dqadd343 add 1E+35 0 -> 1.000000000000000000000000000000000E+35 Rounded +-- which simply follow from these cases ... +dqadd344 add 1E+3 1 -> 1001 +dqadd345 add 1E+33 1 -> 1000000000000000000000000000000001 +dqadd346 add 1E+34 1 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd347 add 1E+35 1 -> 1.000000000000000000000000000000000E+35 Inexact Rounded +dqadd348 add 1E+3 7 -> 1007 +dqadd349 add 1E+33 7 -> 1000000000000000000000000000000007 +dqadd350 add 1E+34 7 -> 1.000000000000000000000000000000001E+34 Inexact Rounded +dqadd351 add 1E+35 7 -> 1.000000000000000000000000000000000E+35 Inexact Rounded + +-- tryzeros cases +rounding: half_up +dqadd360 add 0E+50 10000E+1 -> 1.0000E+5 +dqadd361 add 0E-50 10000E+1 -> 100000.0000000000000000000000000000 Rounded +dqadd362 add 10000E+1 0E-50 -> 100000.0000000000000000000000000000 Rounded +dqadd363 add 10000E+1 10000E-50 -> 100000.0000000000000000000000000000 Rounded Inexact +dqadd364 add 9.999999999999999999999999999999999E+6144 -9.999999999999999999999999999999999E+6144 -> 0E+6111 +-- 1 234567890123456789012345678901234 + +-- a curiosity from JSR 13 testing +rounding: half_down +dqadd370 add 999999999999999999999999999999999 815 -> 1000000000000000000000000000000814 +dqadd371 add 9999999999999999999999999999999999 815 -> 1.000000000000000000000000000000081E+34 Rounded Inexact +rounding: half_up +dqadd372 add 999999999999999999999999999999999 815 -> 1000000000000000000000000000000814 +dqadd373 add 9999999999999999999999999999999999 815 -> 1.000000000000000000000000000000081E+34 Rounded Inexact +rounding: half_even +dqadd374 add 999999999999999999999999999999999 815 -> 1000000000000000000000000000000814 +dqadd375 add 9999999999999999999999999999999999 815 -> 1.000000000000000000000000000000081E+34 Rounded Inexact + +-- ulp replacement tests +dqadd400 add 1 77e-32 -> 1.00000000000000000000000000000077 +dqadd401 add 1 77e-33 -> 1.000000000000000000000000000000077 +dqadd402 add 1 77e-34 -> 1.000000000000000000000000000000008 Inexact Rounded +dqadd403 add 1 77e-35 -> 1.000000000000000000000000000000001 Inexact Rounded +dqadd404 add 1 77e-36 -> 1.000000000000000000000000000000000 Inexact Rounded +dqadd405 add 1 77e-37 -> 1.000000000000000000000000000000000 Inexact Rounded +dqadd406 add 1 77e-299 -> 1.000000000000000000000000000000000 Inexact Rounded + +dqadd410 add 10 77e-32 -> 10.00000000000000000000000000000077 +dqadd411 add 10 77e-33 -> 10.00000000000000000000000000000008 Inexact Rounded +dqadd412 add 10 77e-34 -> 10.00000000000000000000000000000001 Inexact Rounded +dqadd413 add 10 77e-35 -> 10.00000000000000000000000000000000 Inexact Rounded +dqadd414 add 10 77e-36 -> 10.00000000000000000000000000000000 Inexact Rounded +dqadd415 add 10 77e-37 -> 10.00000000000000000000000000000000 Inexact Rounded +dqadd416 add 10 77e-299 -> 10.00000000000000000000000000000000 Inexact Rounded + +dqadd420 add 77e-32 1 -> 1.00000000000000000000000000000077 +dqadd421 add 77e-33 1 -> 1.000000000000000000000000000000077 +dqadd422 add 77e-34 1 -> 1.000000000000000000000000000000008 Inexact Rounded +dqadd423 add 77e-35 1 -> 1.000000000000000000000000000000001 Inexact Rounded +dqadd424 add 77e-36 1 -> 1.000000000000000000000000000000000 Inexact Rounded +dqadd425 add 77e-37 1 -> 1.000000000000000000000000000000000 Inexact Rounded +dqadd426 add 77e-299 1 -> 1.000000000000000000000000000000000 Inexact Rounded + +dqadd430 add 77e-32 10 -> 10.00000000000000000000000000000077 +dqadd431 add 77e-33 10 -> 10.00000000000000000000000000000008 Inexact Rounded +dqadd432 add 77e-34 10 -> 10.00000000000000000000000000000001 Inexact Rounded +dqadd433 add 77e-35 10 -> 10.00000000000000000000000000000000 Inexact Rounded +dqadd434 add 77e-36 10 -> 10.00000000000000000000000000000000 Inexact Rounded +dqadd435 add 77e-37 10 -> 10.00000000000000000000000000000000 Inexact Rounded +dqadd436 add 77e-299 10 -> 10.00000000000000000000000000000000 Inexact Rounded + +-- negative ulps +dqadd6440 add 1 -77e-32 -> 0.99999999999999999999999999999923 +dqadd6441 add 1 -77e-33 -> 0.999999999999999999999999999999923 +dqadd6442 add 1 -77e-34 -> 0.9999999999999999999999999999999923 +dqadd6443 add 1 -77e-35 -> 0.9999999999999999999999999999999992 Inexact Rounded +dqadd6444 add 1 -77e-36 -> 0.9999999999999999999999999999999999 Inexact Rounded +dqadd6445 add 1 -77e-37 -> 1.000000000000000000000000000000000 Inexact Rounded +dqadd6446 add 1 -77e-99 -> 1.000000000000000000000000000000000 Inexact Rounded + +dqadd6450 add 10 -77e-32 -> 9.99999999999999999999999999999923 +dqadd6451 add 10 -77e-33 -> 9.999999999999999999999999999999923 +dqadd6452 add 10 -77e-34 -> 9.999999999999999999999999999999992 Inexact Rounded +dqadd6453 add 10 -77e-35 -> 9.999999999999999999999999999999999 Inexact Rounded +dqadd6454 add 10 -77e-36 -> 10.00000000000000000000000000000000 Inexact Rounded +dqadd6455 add 10 -77e-37 -> 10.00000000000000000000000000000000 Inexact Rounded +dqadd6456 add 10 -77e-99 -> 10.00000000000000000000000000000000 Inexact Rounded + +dqadd6460 add -77e-32 1 -> 0.99999999999999999999999999999923 +dqadd6461 add -77e-33 1 -> 0.999999999999999999999999999999923 +dqadd6462 add -77e-34 1 -> 0.9999999999999999999999999999999923 +dqadd6463 add -77e-35 1 -> 0.9999999999999999999999999999999992 Inexact Rounded +dqadd6464 add -77e-36 1 -> 0.9999999999999999999999999999999999 Inexact Rounded +dqadd6465 add -77e-37 1 -> 1.000000000000000000000000000000000 Inexact Rounded +dqadd6466 add -77e-99 1 -> 1.000000000000000000000000000000000 Inexact Rounded + +dqadd6470 add -77e-32 10 -> 9.99999999999999999999999999999923 +dqadd6471 add -77e-33 10 -> 9.999999999999999999999999999999923 +dqadd6472 add -77e-34 10 -> 9.999999999999999999999999999999992 Inexact Rounded +dqadd6473 add -77e-35 10 -> 9.999999999999999999999999999999999 Inexact Rounded +dqadd6474 add -77e-36 10 -> 10.00000000000000000000000000000000 Inexact Rounded +dqadd6475 add -77e-37 10 -> 10.00000000000000000000000000000000 Inexact Rounded +dqadd6476 add -77e-99 10 -> 10.00000000000000000000000000000000 Inexact Rounded + +-- negative ulps +dqadd6480 add -1 77e-32 -> -0.99999999999999999999999999999923 +dqadd6481 add -1 77e-33 -> -0.999999999999999999999999999999923 +dqadd6482 add -1 77e-34 -> -0.9999999999999999999999999999999923 +dqadd6483 add -1 77e-35 -> -0.9999999999999999999999999999999992 Inexact Rounded +dqadd6484 add -1 77e-36 -> -0.9999999999999999999999999999999999 Inexact Rounded +dqadd6485 add -1 77e-37 -> -1.000000000000000000000000000000000 Inexact Rounded +dqadd6486 add -1 77e-99 -> -1.000000000000000000000000000000000 Inexact Rounded + +dqadd6490 add -10 77e-32 -> -9.99999999999999999999999999999923 +dqadd6491 add -10 77e-33 -> -9.999999999999999999999999999999923 +dqadd6492 add -10 77e-34 -> -9.999999999999999999999999999999992 Inexact Rounded +dqadd6493 add -10 77e-35 -> -9.999999999999999999999999999999999 Inexact Rounded +dqadd6494 add -10 77e-36 -> -10.00000000000000000000000000000000 Inexact Rounded +dqadd6495 add -10 77e-37 -> -10.00000000000000000000000000000000 Inexact Rounded +dqadd6496 add -10 77e-99 -> -10.00000000000000000000000000000000 Inexact Rounded + +dqadd6500 add 77e-32 -1 -> -0.99999999999999999999999999999923 +dqadd6501 add 77e-33 -1 -> -0.999999999999999999999999999999923 +dqadd6502 add 77e-34 -1 -> -0.9999999999999999999999999999999923 +dqadd6503 add 77e-35 -1 -> -0.9999999999999999999999999999999992 Inexact Rounded +dqadd6504 add 77e-36 -1 -> -0.9999999999999999999999999999999999 Inexact Rounded +dqadd6505 add 77e-37 -1 -> -1.000000000000000000000000000000000 Inexact Rounded +dqadd6506 add 77e-99 -1 -> -1.000000000000000000000000000000000 Inexact Rounded + +dqadd6510 add 77e-32 -10 -> -9.99999999999999999999999999999923 +dqadd6511 add 77e-33 -10 -> -9.999999999999999999999999999999923 +dqadd6512 add 77e-34 -10 -> -9.999999999999999999999999999999992 Inexact Rounded +dqadd6513 add 77e-35 -10 -> -9.999999999999999999999999999999999 Inexact Rounded +dqadd6514 add 77e-36 -10 -> -10.00000000000000000000000000000000 Inexact Rounded +dqadd6515 add 77e-37 -10 -> -10.00000000000000000000000000000000 Inexact Rounded +dqadd6516 add 77e-99 -10 -> -10.00000000000000000000000000000000 Inexact Rounded + +-- and some more residue effects and different roundings +rounding: half_up +dqadd6540 add '9876543219876543216543210123456789' 0 -> '9876543219876543216543210123456789' +dqadd6541 add '9876543219876543216543210123456789' 0.000000001 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd6542 add '9876543219876543216543210123456789' 0.000001 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd6543 add '9876543219876543216543210123456789' 0.1 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd6544 add '9876543219876543216543210123456789' 0.4 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd6545 add '9876543219876543216543210123456789' 0.49 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd6546 add '9876543219876543216543210123456789' 0.499999 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd6547 add '9876543219876543216543210123456789' 0.499999999 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd6548 add '9876543219876543216543210123456789' 0.5 -> '9876543219876543216543210123456790' Inexact Rounded +dqadd6549 add '9876543219876543216543210123456789' 0.500000001 -> '9876543219876543216543210123456790' Inexact Rounded +dqadd6550 add '9876543219876543216543210123456789' 0.500001 -> '9876543219876543216543210123456790' Inexact Rounded +dqadd6551 add '9876543219876543216543210123456789' 0.51 -> '9876543219876543216543210123456790' Inexact Rounded +dqadd6552 add '9876543219876543216543210123456789' 0.6 -> '9876543219876543216543210123456790' Inexact Rounded +dqadd6553 add '9876543219876543216543210123456789' 0.9 -> '9876543219876543216543210123456790' Inexact Rounded +dqadd6554 add '9876543219876543216543210123456789' 0.99999 -> '9876543219876543216543210123456790' Inexact Rounded +dqadd6555 add '9876543219876543216543210123456789' 0.999999999 -> '9876543219876543216543210123456790' Inexact Rounded +dqadd6556 add '9876543219876543216543210123456789' 1 -> '9876543219876543216543210123456790' +dqadd6557 add '9876543219876543216543210123456789' 1.000000001 -> '9876543219876543216543210123456790' Inexact Rounded +dqadd6558 add '9876543219876543216543210123456789' 1.00001 -> '9876543219876543216543210123456790' Inexact Rounded +dqadd6559 add '9876543219876543216543210123456789' 1.1 -> '9876543219876543216543210123456790' Inexact Rounded + +rounding: half_even +dqadd6560 add '9876543219876543216543210123456789' 0 -> '9876543219876543216543210123456789' +dqadd6561 add '9876543219876543216543210123456789' 0.000000001 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd6562 add '9876543219876543216543210123456789' 0.000001 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd6563 add '9876543219876543216543210123456789' 0.1 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd6564 add '9876543219876543216543210123456789' 0.4 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd6565 add '9876543219876543216543210123456789' 0.49 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd6566 add '9876543219876543216543210123456789' 0.499999 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd6567 add '9876543219876543216543210123456789' 0.499999999 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd6568 add '9876543219876543216543210123456789' 0.5 -> '9876543219876543216543210123456790' Inexact Rounded +dqadd6569 add '9876543219876543216543210123456789' 0.500000001 -> '9876543219876543216543210123456790' Inexact Rounded +dqadd6570 add '9876543219876543216543210123456789' 0.500001 -> '9876543219876543216543210123456790' Inexact Rounded +dqadd6571 add '9876543219876543216543210123456789' 0.51 -> '9876543219876543216543210123456790' Inexact Rounded +dqadd6572 add '9876543219876543216543210123456789' 0.6 -> '9876543219876543216543210123456790' Inexact Rounded +dqadd6573 add '9876543219876543216543210123456789' 0.9 -> '9876543219876543216543210123456790' Inexact Rounded +dqadd6574 add '9876543219876543216543210123456789' 0.99999 -> '9876543219876543216543210123456790' Inexact Rounded +dqadd6575 add '9876543219876543216543210123456789' 0.999999999 -> '9876543219876543216543210123456790' Inexact Rounded +dqadd6576 add '9876543219876543216543210123456789' 1 -> '9876543219876543216543210123456790' +dqadd6577 add '9876543219876543216543210123456789' 1.00000001 -> '9876543219876543216543210123456790' Inexact Rounded +dqadd6578 add '9876543219876543216543210123456789' 1.00001 -> '9876543219876543216543210123456790' Inexact Rounded +dqadd6579 add '9876543219876543216543210123456789' 1.1 -> '9876543219876543216543210123456790' Inexact Rounded + +-- critical few with even bottom digit... +dqadd7540 add '9876543219876543216543210123456788' 0.499999999 -> '9876543219876543216543210123456788' Inexact Rounded +dqadd7541 add '9876543219876543216543210123456788' 0.5 -> '9876543219876543216543210123456788' Inexact Rounded +dqadd7542 add '9876543219876543216543210123456788' 0.500000001 -> '9876543219876543216543210123456789' Inexact Rounded + +rounding: down +dqadd7550 add '9876543219876543216543210123456789' 0 -> '9876543219876543216543210123456789' +dqadd7551 add '9876543219876543216543210123456789' 0.000000001 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd7552 add '9876543219876543216543210123456789' 0.000001 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd7553 add '9876543219876543216543210123456789' 0.1 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd7554 add '9876543219876543216543210123456789' 0.4 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd7555 add '9876543219876543216543210123456789' 0.49 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd7556 add '9876543219876543216543210123456789' 0.499999 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd7557 add '9876543219876543216543210123456789' 0.499999999 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd7558 add '9876543219876543216543210123456789' 0.5 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd7559 add '9876543219876543216543210123456789' 0.500000001 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd7560 add '9876543219876543216543210123456789' 0.500001 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd7561 add '9876543219876543216543210123456789' 0.51 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd7562 add '9876543219876543216543210123456789' 0.6 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd7563 add '9876543219876543216543210123456789' 0.9 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd7564 add '9876543219876543216543210123456789' 0.99999 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd7565 add '9876543219876543216543210123456789' 0.999999999 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd7566 add '9876543219876543216543210123456789' 1 -> '9876543219876543216543210123456790' +dqadd7567 add '9876543219876543216543210123456789' 1.00000001 -> '9876543219876543216543210123456790' Inexact Rounded +dqadd7568 add '9876543219876543216543210123456789' 1.00001 -> '9876543219876543216543210123456790' Inexact Rounded +dqadd7569 add '9876543219876543216543210123456789' 1.1 -> '9876543219876543216543210123456790' Inexact Rounded + +-- more zeros, etc. +rounding: half_even + +dqadd7701 add 5.00 1.00E-3 -> 5.00100 +dqadd7702 add 00.00 0.000 -> 0.000 +dqadd7703 add 00.00 0E-3 -> 0.000 +dqadd7704 add 0E-3 00.00 -> 0.000 + +dqadd7710 add 0E+3 00.00 -> 0.00 +dqadd7711 add 0E+3 00.0 -> 0.0 +dqadd7712 add 0E+3 00. -> 0 +dqadd7713 add 0E+3 00.E+1 -> 0E+1 +dqadd7714 add 0E+3 00.E+2 -> 0E+2 +dqadd7715 add 0E+3 00.E+3 -> 0E+3 +dqadd7716 add 0E+3 00.E+4 -> 0E+3 +dqadd7717 add 0E+3 00.E+5 -> 0E+3 +dqadd7718 add 0E+3 -00.0 -> 0.0 +dqadd7719 add 0E+3 -00. -> 0 +dqadd7731 add 0E+3 -00.E+1 -> 0E+1 + +dqadd7720 add 00.00 0E+3 -> 0.00 +dqadd7721 add 00.0 0E+3 -> 0.0 +dqadd7722 add 00. 0E+3 -> 0 +dqadd7723 add 00.E+1 0E+3 -> 0E+1 +dqadd7724 add 00.E+2 0E+3 -> 0E+2 +dqadd7725 add 00.E+3 0E+3 -> 0E+3 +dqadd7726 add 00.E+4 0E+3 -> 0E+3 +dqadd7727 add 00.E+5 0E+3 -> 0E+3 +dqadd7728 add -00.00 0E+3 -> 0.00 +dqadd7729 add -00.0 0E+3 -> 0.0 +dqadd7730 add -00. 0E+3 -> 0 + +dqadd7732 add 0 0 -> 0 +dqadd7733 add 0 -0 -> 0 +dqadd7734 add -0 0 -> 0 +dqadd7735 add -0 -0 -> -0 -- IEEE 854 special case + +dqadd7736 add 1 -1 -> 0 +dqadd7737 add -1 -1 -> -2 +dqadd7738 add 1 1 -> 2 +dqadd7739 add -1 1 -> 0 + +dqadd7741 add 0 -1 -> -1 +dqadd7742 add -0 -1 -> -1 +dqadd7743 add 0 1 -> 1 +dqadd7744 add -0 1 -> 1 +dqadd7745 add -1 0 -> -1 +dqadd7746 add -1 -0 -> -1 +dqadd7747 add 1 0 -> 1 +dqadd7748 add 1 -0 -> 1 + +dqadd7751 add 0.0 -1 -> -1.0 +dqadd7752 add -0.0 -1 -> -1.0 +dqadd7753 add 0.0 1 -> 1.0 +dqadd7754 add -0.0 1 -> 1.0 +dqadd7755 add -1.0 0 -> -1.0 +dqadd7756 add -1.0 -0 -> -1.0 +dqadd7757 add 1.0 0 -> 1.0 +dqadd7758 add 1.0 -0 -> 1.0 + +dqadd7761 add 0 -1.0 -> -1.0 +dqadd7762 add -0 -1.0 -> -1.0 +dqadd7763 add 0 1.0 -> 1.0 +dqadd7764 add -0 1.0 -> 1.0 +dqadd7765 add -1 0.0 -> -1.0 +dqadd7766 add -1 -0.0 -> -1.0 +dqadd7767 add 1 0.0 -> 1.0 +dqadd7768 add 1 -0.0 -> 1.0 + +dqadd7771 add 0.0 -1.0 -> -1.0 +dqadd7772 add -0.0 -1.0 -> -1.0 +dqadd7773 add 0.0 1.0 -> 1.0 +dqadd7774 add -0.0 1.0 -> 1.0 +dqadd7775 add -1.0 0.0 -> -1.0 +dqadd7776 add -1.0 -0.0 -> -1.0 +dqadd7777 add 1.0 0.0 -> 1.0 +dqadd7778 add 1.0 -0.0 -> 1.0 + +-- Specials +dqadd7780 add -Inf -Inf -> -Infinity +dqadd7781 add -Inf -1000 -> -Infinity +dqadd7782 add -Inf -1 -> -Infinity +dqadd7783 add -Inf -0 -> -Infinity +dqadd7784 add -Inf 0 -> -Infinity +dqadd7785 add -Inf 1 -> -Infinity +dqadd7786 add -Inf 1000 -> -Infinity +dqadd7787 add -1000 -Inf -> -Infinity +dqadd7788 add -Inf -Inf -> -Infinity +dqadd7789 add -1 -Inf -> -Infinity +dqadd7790 add -0 -Inf -> -Infinity +dqadd7791 add 0 -Inf -> -Infinity +dqadd7792 add 1 -Inf -> -Infinity +dqadd7793 add 1000 -Inf -> -Infinity +dqadd7794 add Inf -Inf -> NaN Invalid_operation + +dqadd7800 add Inf -Inf -> NaN Invalid_operation +dqadd7801 add Inf -1000 -> Infinity +dqadd7802 add Inf -1 -> Infinity +dqadd7803 add Inf -0 -> Infinity +dqadd7804 add Inf 0 -> Infinity +dqadd7805 add Inf 1 -> Infinity +dqadd7806 add Inf 1000 -> Infinity +dqadd7807 add Inf Inf -> Infinity +dqadd7808 add -1000 Inf -> Infinity +dqadd7809 add -Inf Inf -> NaN Invalid_operation +dqadd7810 add -1 Inf -> Infinity +dqadd7811 add -0 Inf -> Infinity +dqadd7812 add 0 Inf -> Infinity +dqadd7813 add 1 Inf -> Infinity +dqadd7814 add 1000 Inf -> Infinity +dqadd7815 add Inf Inf -> Infinity + +dqadd7821 add NaN -Inf -> NaN +dqadd7822 add NaN -1000 -> NaN +dqadd7823 add NaN -1 -> NaN +dqadd7824 add NaN -0 -> NaN +dqadd7825 add NaN 0 -> NaN +dqadd7826 add NaN 1 -> NaN +dqadd7827 add NaN 1000 -> NaN +dqadd7828 add NaN Inf -> NaN +dqadd7829 add NaN NaN -> NaN +dqadd7830 add -Inf NaN -> NaN +dqadd7831 add -1000 NaN -> NaN +dqadd7832 add -1 NaN -> NaN +dqadd7833 add -0 NaN -> NaN +dqadd7834 add 0 NaN -> NaN +dqadd7835 add 1 NaN -> NaN +dqadd7836 add 1000 NaN -> NaN +dqadd7837 add Inf NaN -> NaN + +dqadd7841 add sNaN -Inf -> NaN Invalid_operation +dqadd7842 add sNaN -1000 -> NaN Invalid_operation +dqadd7843 add sNaN -1 -> NaN Invalid_operation +dqadd7844 add sNaN -0 -> NaN Invalid_operation +dqadd7845 add sNaN 0 -> NaN Invalid_operation +dqadd7846 add sNaN 1 -> NaN Invalid_operation +dqadd7847 add sNaN 1000 -> NaN Invalid_operation +dqadd7848 add sNaN NaN -> NaN Invalid_operation +dqadd7849 add sNaN sNaN -> NaN Invalid_operation +dqadd7850 add NaN sNaN -> NaN Invalid_operation +dqadd7851 add -Inf sNaN -> NaN Invalid_operation +dqadd7852 add -1000 sNaN -> NaN Invalid_operation +dqadd7853 add -1 sNaN -> NaN Invalid_operation +dqadd7854 add -0 sNaN -> NaN Invalid_operation +dqadd7855 add 0 sNaN -> NaN Invalid_operation +dqadd7856 add 1 sNaN -> NaN Invalid_operation +dqadd7857 add 1000 sNaN -> NaN Invalid_operation +dqadd7858 add Inf sNaN -> NaN Invalid_operation +dqadd7859 add NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +dqadd7861 add NaN1 -Inf -> NaN1 +dqadd7862 add +NaN2 -1000 -> NaN2 +dqadd7863 add NaN3 1000 -> NaN3 +dqadd7864 add NaN4 Inf -> NaN4 +dqadd7865 add NaN5 +NaN6 -> NaN5 +dqadd7866 add -Inf NaN7 -> NaN7 +dqadd7867 add -1000 NaN8 -> NaN8 +dqadd7868 add 1000 NaN9 -> NaN9 +dqadd7869 add Inf +NaN10 -> NaN10 +dqadd7871 add sNaN11 -Inf -> NaN11 Invalid_operation +dqadd7872 add sNaN12 -1000 -> NaN12 Invalid_operation +dqadd7873 add sNaN13 1000 -> NaN13 Invalid_operation +dqadd7874 add sNaN14 NaN17 -> NaN14 Invalid_operation +dqadd7875 add sNaN15 sNaN18 -> NaN15 Invalid_operation +dqadd7876 add NaN16 sNaN19 -> NaN19 Invalid_operation +dqadd7877 add -Inf +sNaN20 -> NaN20 Invalid_operation +dqadd7878 add -1000 sNaN21 -> NaN21 Invalid_operation +dqadd7879 add 1000 sNaN22 -> NaN22 Invalid_operation +dqadd7880 add Inf sNaN23 -> NaN23 Invalid_operation +dqadd7881 add +NaN25 +sNaN24 -> NaN24 Invalid_operation +dqadd7882 add -NaN26 NaN28 -> -NaN26 +dqadd7883 add -sNaN27 sNaN29 -> -NaN27 Invalid_operation +dqadd7884 add 1000 -NaN30 -> -NaN30 +dqadd7885 add 1000 -sNaN31 -> -NaN31 Invalid_operation + +-- Here we explore near the boundary of rounding a subnormal to Nmin +dqadd7575 add 1E-6143 -1E-6176 -> 9.99999999999999999999999999999999E-6144 Subnormal +dqadd7576 add -1E-6143 +1E-6176 -> -9.99999999999999999999999999999999E-6144 Subnormal + +-- check overflow edge case +-- 1234567890123456 +dqadd7972 apply 9.999999999999999999999999999999999E+6144 -> 9.999999999999999999999999999999999E+6144 +dqadd7973 add 9.999999999999999999999999999999999E+6144 1 -> 9.999999999999999999999999999999999E+6144 Inexact Rounded +dqadd7974 add 9999999999999999999999999999999999E+6111 1 -> 9.999999999999999999999999999999999E+6144 Inexact Rounded +dqadd7975 add 9999999999999999999999999999999999E+6111 1E+6111 -> Infinity Overflow Inexact Rounded +dqadd7976 add 9999999999999999999999999999999999E+6111 9E+6110 -> Infinity Overflow Inexact Rounded +dqadd7977 add 9999999999999999999999999999999999E+6111 8E+6110 -> Infinity Overflow Inexact Rounded +dqadd7978 add 9999999999999999999999999999999999E+6111 7E+6110 -> Infinity Overflow Inexact Rounded +dqadd7979 add 9999999999999999999999999999999999E+6111 6E+6110 -> Infinity Overflow Inexact Rounded +dqadd7980 add 9999999999999999999999999999999999E+6111 5E+6110 -> Infinity Overflow Inexact Rounded +dqadd7981 add 9999999999999999999999999999999999E+6111 4E+6110 -> 9.999999999999999999999999999999999E+6144 Inexact Rounded +dqadd7982 add 9999999999999999999999999999999999E+6111 3E+6110 -> 9.999999999999999999999999999999999E+6144 Inexact Rounded +dqadd7983 add 9999999999999999999999999999999999E+6111 2E+6110 -> 9.999999999999999999999999999999999E+6144 Inexact Rounded +dqadd7984 add 9999999999999999999999999999999999E+6111 1E+6110 -> 9.999999999999999999999999999999999E+6144 Inexact Rounded + +dqadd7985 apply -9.999999999999999999999999999999999E+6144 -> -9.999999999999999999999999999999999E+6144 +dqadd7986 add -9.999999999999999999999999999999999E+6144 -1 -> -9.999999999999999999999999999999999E+6144 Inexact Rounded +dqadd7987 add -9999999999999999999999999999999999E+6111 -1 -> -9.999999999999999999999999999999999E+6144 Inexact Rounded +dqadd7988 add -9999999999999999999999999999999999E+6111 -1E+6111 -> -Infinity Overflow Inexact Rounded +dqadd7989 add -9999999999999999999999999999999999E+6111 -9E+6110 -> -Infinity Overflow Inexact Rounded +dqadd7990 add -9999999999999999999999999999999999E+6111 -8E+6110 -> -Infinity Overflow Inexact Rounded +dqadd7991 add -9999999999999999999999999999999999E+6111 -7E+6110 -> -Infinity Overflow Inexact Rounded +dqadd7992 add -9999999999999999999999999999999999E+6111 -6E+6110 -> -Infinity Overflow Inexact Rounded +dqadd7993 add -9999999999999999999999999999999999E+6111 -5E+6110 -> -Infinity Overflow Inexact Rounded +dqadd7994 add -9999999999999999999999999999999999E+6111 -4E+6110 -> -9.999999999999999999999999999999999E+6144 Inexact Rounded +dqadd7995 add -9999999999999999999999999999999999E+6111 -3E+6110 -> -9.999999999999999999999999999999999E+6144 Inexact Rounded +dqadd7996 add -9999999999999999999999999999999999E+6111 -2E+6110 -> -9.999999999999999999999999999999999E+6144 Inexact Rounded +dqadd7997 add -9999999999999999999999999999999999E+6111 -1E+6110 -> -9.999999999999999999999999999999999E+6144 Inexact Rounded + +-- And for round down full and subnormal results +rounding: down +dqadd71100 add 1e+2 -1e-6143 -> 99.99999999999999999999999999999999 Rounded Inexact +dqadd71101 add 1e+1 -1e-6143 -> 9.999999999999999999999999999999999 Rounded Inexact +dqadd71103 add +1 -1e-6143 -> 0.9999999999999999999999999999999999 Rounded Inexact +dqadd71104 add 1e-1 -1e-6143 -> 0.09999999999999999999999999999999999 Rounded Inexact +dqadd71105 add 1e-2 -1e-6143 -> 0.009999999999999999999999999999999999 Rounded Inexact +dqadd71106 add 1e-3 -1e-6143 -> 0.0009999999999999999999999999999999999 Rounded Inexact +dqadd71107 add 1e-4 -1e-6143 -> 0.00009999999999999999999999999999999999 Rounded Inexact +dqadd71108 add 1e-5 -1e-6143 -> 0.000009999999999999999999999999999999999 Rounded Inexact +dqadd71109 add 1e-6 -1e-6143 -> 9.999999999999999999999999999999999E-7 Rounded Inexact + +rounding: ceiling +dqadd71110 add -1e+2 +1e-6143 -> -99.99999999999999999999999999999999 Rounded Inexact +dqadd71111 add -1e+1 +1e-6143 -> -9.999999999999999999999999999999999 Rounded Inexact +dqadd71113 add -1 +1e-6143 -> -0.9999999999999999999999999999999999 Rounded Inexact +dqadd71114 add -1e-1 +1e-6143 -> -0.09999999999999999999999999999999999 Rounded Inexact +dqadd71115 add -1e-2 +1e-6143 -> -0.009999999999999999999999999999999999 Rounded Inexact +dqadd71116 add -1e-3 +1e-6143 -> -0.0009999999999999999999999999999999999 Rounded Inexact +dqadd71117 add -1e-4 +1e-6143 -> -0.00009999999999999999999999999999999999 Rounded Inexact +dqadd71118 add -1e-5 +1e-6143 -> -0.000009999999999999999999999999999999999 Rounded Inexact +dqadd71119 add -1e-6 +1e-6143 -> -9.999999999999999999999999999999999E-7 Rounded Inexact + +-- tests based on Gunnar Degnbol's edge case +rounding: half_even + +dqadd71300 add 1E34 -0.5 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd71310 add 1E34 -0.51 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd71311 add 1E34 -0.501 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd71312 add 1E34 -0.5001 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd71313 add 1E34 -0.50001 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd71314 add 1E34 -0.500001 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd71315 add 1E34 -0.5000001 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd71316 add 1E34 -0.50000001 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd71317 add 1E34 -0.500000001 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd71318 add 1E34 -0.5000000001 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd71319 add 1E34 -0.50000000001 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd71320 add 1E34 -0.500000000001 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd71321 add 1E34 -0.5000000000001 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd71322 add 1E34 -0.50000000000001 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd71323 add 1E34 -0.500000000000001 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd71324 add 1E34 -0.5000000000000001 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd71325 add 1E34 -0.5000000000000000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd71326 add 1E34 -0.500000000000000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd71327 add 1E34 -0.50000000000000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd71328 add 1E34 -0.5000000000000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd71329 add 1E34 -0.500000000000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd71330 add 1E34 -0.50000000000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd71331 add 1E34 -0.5000000000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd71332 add 1E34 -0.500000000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd71333 add 1E34 -0.50000000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd71334 add 1E34 -0.5000000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd71335 add 1E34 -0.500000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd71336 add 1E34 -0.50000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd71337 add 1E34 -0.5000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd71338 add 1E34 -0.500 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd71339 add 1E34 -0.50 -> 1.000000000000000000000000000000000E+34 Inexact Rounded + +dqadd71340 add 1E34 -5000000.000010001 -> 9999999999999999999999999995000000 Inexact Rounded +dqadd71341 add 1E34 -5000000.000000001 -> 9999999999999999999999999995000000 Inexact Rounded + +dqadd71349 add 9999999999999999999999999999999999 0.4 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd71350 add 9999999999999999999999999999999999 0.49 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd71351 add 9999999999999999999999999999999999 0.499 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd71352 add 9999999999999999999999999999999999 0.4999 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd71353 add 9999999999999999999999999999999999 0.49999 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd71354 add 9999999999999999999999999999999999 0.499999 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd71355 add 9999999999999999999999999999999999 0.4999999 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd71356 add 9999999999999999999999999999999999 0.49999999 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd71357 add 9999999999999999999999999999999999 0.499999999 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd71358 add 9999999999999999999999999999999999 0.4999999999 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd71359 add 9999999999999999999999999999999999 0.49999999999 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd71360 add 9999999999999999999999999999999999 0.499999999999 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd71361 add 9999999999999999999999999999999999 0.4999999999999 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd71362 add 9999999999999999999999999999999999 0.49999999999999 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd71363 add 9999999999999999999999999999999999 0.499999999999999 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd71364 add 9999999999999999999999999999999999 0.4999999999999999 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd71365 add 9999999999999999999999999999999999 0.5000000000000000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd71367 add 9999999999999999999999999999999999 0.500000000000000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd71368 add 9999999999999999999999999999999999 0.50000000000000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd71369 add 9999999999999999999999999999999999 0.5000000000000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd71370 add 9999999999999999999999999999999999 0.500000000000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd71371 add 9999999999999999999999999999999999 0.50000000000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd71372 add 9999999999999999999999999999999999 0.5000000000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd71373 add 9999999999999999999999999999999999 0.500000000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd71374 add 9999999999999999999999999999999999 0.50000000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd71375 add 9999999999999999999999999999999999 0.5000000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd71376 add 9999999999999999999999999999999999 0.500000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd71377 add 9999999999999999999999999999999999 0.50000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd71378 add 9999999999999999999999999999999999 0.5000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd71379 add 9999999999999999999999999999999999 0.500 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd71380 add 9999999999999999999999999999999999 0.50 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd71381 add 9999999999999999999999999999999999 0.5 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd71382 add 9999999999999999999999999999999999 0.5000000000000001 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd71383 add 9999999999999999999999999999999999 0.500000000000001 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd71384 add 9999999999999999999999999999999999 0.50000000000001 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd71385 add 9999999999999999999999999999999999 0.5000000000001 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd71386 add 9999999999999999999999999999999999 0.500000000001 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd71387 add 9999999999999999999999999999999999 0.50000000001 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd71388 add 9999999999999999999999999999999999 0.5000000001 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd71389 add 9999999999999999999999999999999999 0.500000001 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd71390 add 9999999999999999999999999999999999 0.50000001 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd71391 add 9999999999999999999999999999999999 0.5000001 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd71392 add 9999999999999999999999999999999999 0.500001 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd71393 add 9999999999999999999999999999999999 0.50001 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd71394 add 9999999999999999999999999999999999 0.5001 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd71395 add 9999999999999999999999999999999999 0.501 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd71396 add 9999999999999999999999999999999999 0.51 -> 1.000000000000000000000000000000000E+34 Inexact Rounded + +-- More GD edge cases, where difference between the unadjusted +-- exponents is larger than the maximum precision and one side is 0 +dqadd71420 add 0 1.123456789987654321123456789012345 -> 1.123456789987654321123456789012345 +dqadd71421 add 0 1.123456789987654321123456789012345E-1 -> 0.1123456789987654321123456789012345 +dqadd71422 add 0 1.123456789987654321123456789012345E-2 -> 0.01123456789987654321123456789012345 +dqadd71423 add 0 1.123456789987654321123456789012345E-3 -> 0.001123456789987654321123456789012345 +dqadd71424 add 0 1.123456789987654321123456789012345E-4 -> 0.0001123456789987654321123456789012345 +dqadd71425 add 0 1.123456789987654321123456789012345E-5 -> 0.00001123456789987654321123456789012345 +dqadd71426 add 0 1.123456789987654321123456789012345E-6 -> 0.000001123456789987654321123456789012345 +dqadd71427 add 0 1.123456789987654321123456789012345E-7 -> 1.123456789987654321123456789012345E-7 +dqadd71428 add 0 1.123456789987654321123456789012345E-8 -> 1.123456789987654321123456789012345E-8 +dqadd71429 add 0 1.123456789987654321123456789012345E-9 -> 1.123456789987654321123456789012345E-9 +dqadd71430 add 0 1.123456789987654321123456789012345E-10 -> 1.123456789987654321123456789012345E-10 +dqadd71431 add 0 1.123456789987654321123456789012345E-11 -> 1.123456789987654321123456789012345E-11 +dqadd71432 add 0 1.123456789987654321123456789012345E-12 -> 1.123456789987654321123456789012345E-12 +dqadd71433 add 0 1.123456789987654321123456789012345E-13 -> 1.123456789987654321123456789012345E-13 +dqadd71434 add 0 1.123456789987654321123456789012345E-14 -> 1.123456789987654321123456789012345E-14 +dqadd71435 add 0 1.123456789987654321123456789012345E-15 -> 1.123456789987654321123456789012345E-15 +dqadd71436 add 0 1.123456789987654321123456789012345E-16 -> 1.123456789987654321123456789012345E-16 +dqadd71437 add 0 1.123456789987654321123456789012345E-17 -> 1.123456789987654321123456789012345E-17 +dqadd71438 add 0 1.123456789987654321123456789012345E-18 -> 1.123456789987654321123456789012345E-18 +dqadd71439 add 0 1.123456789987654321123456789012345E-19 -> 1.123456789987654321123456789012345E-19 +dqadd71440 add 0 1.123456789987654321123456789012345E-20 -> 1.123456789987654321123456789012345E-20 +dqadd71441 add 0 1.123456789987654321123456789012345E-21 -> 1.123456789987654321123456789012345E-21 +dqadd71442 add 0 1.123456789987654321123456789012345E-22 -> 1.123456789987654321123456789012345E-22 +dqadd71443 add 0 1.123456789987654321123456789012345E-23 -> 1.123456789987654321123456789012345E-23 +dqadd71444 add 0 1.123456789987654321123456789012345E-24 -> 1.123456789987654321123456789012345E-24 +dqadd71445 add 0 1.123456789987654321123456789012345E-25 -> 1.123456789987654321123456789012345E-25 +dqadd71446 add 0 1.123456789987654321123456789012345E-26 -> 1.123456789987654321123456789012345E-26 +dqadd71447 add 0 1.123456789987654321123456789012345E-27 -> 1.123456789987654321123456789012345E-27 +dqadd71448 add 0 1.123456789987654321123456789012345E-28 -> 1.123456789987654321123456789012345E-28 +dqadd71449 add 0 1.123456789987654321123456789012345E-29 -> 1.123456789987654321123456789012345E-29 +dqadd71450 add 0 1.123456789987654321123456789012345E-30 -> 1.123456789987654321123456789012345E-30 +dqadd71451 add 0 1.123456789987654321123456789012345E-31 -> 1.123456789987654321123456789012345E-31 +dqadd71452 add 0 1.123456789987654321123456789012345E-32 -> 1.123456789987654321123456789012345E-32 +dqadd71453 add 0 1.123456789987654321123456789012345E-33 -> 1.123456789987654321123456789012345E-33 +dqadd71454 add 0 1.123456789987654321123456789012345E-34 -> 1.123456789987654321123456789012345E-34 +dqadd71455 add 0 1.123456789987654321123456789012345E-35 -> 1.123456789987654321123456789012345E-35 +dqadd71456 add 0 1.123456789987654321123456789012345E-36 -> 1.123456789987654321123456789012345E-36 + +-- same, reversed 0 +dqadd71460 add 1.123456789987654321123456789012345 0 -> 1.123456789987654321123456789012345 +dqadd71461 add 1.123456789987654321123456789012345E-1 0 -> 0.1123456789987654321123456789012345 +dqadd71462 add 1.123456789987654321123456789012345E-2 0 -> 0.01123456789987654321123456789012345 +dqadd71463 add 1.123456789987654321123456789012345E-3 0 -> 0.001123456789987654321123456789012345 +dqadd71464 add 1.123456789987654321123456789012345E-4 0 -> 0.0001123456789987654321123456789012345 +dqadd71465 add 1.123456789987654321123456789012345E-5 0 -> 0.00001123456789987654321123456789012345 +dqadd71466 add 1.123456789987654321123456789012345E-6 0 -> 0.000001123456789987654321123456789012345 +dqadd71467 add 1.123456789987654321123456789012345E-7 0 -> 1.123456789987654321123456789012345E-7 +dqadd71468 add 1.123456789987654321123456789012345E-8 0 -> 1.123456789987654321123456789012345E-8 +dqadd71469 add 1.123456789987654321123456789012345E-9 0 -> 1.123456789987654321123456789012345E-9 +dqadd71470 add 1.123456789987654321123456789012345E-10 0 -> 1.123456789987654321123456789012345E-10 +dqadd71471 add 1.123456789987654321123456789012345E-11 0 -> 1.123456789987654321123456789012345E-11 +dqadd71472 add 1.123456789987654321123456789012345E-12 0 -> 1.123456789987654321123456789012345E-12 +dqadd71473 add 1.123456789987654321123456789012345E-13 0 -> 1.123456789987654321123456789012345E-13 +dqadd71474 add 1.123456789987654321123456789012345E-14 0 -> 1.123456789987654321123456789012345E-14 +dqadd71475 add 1.123456789987654321123456789012345E-15 0 -> 1.123456789987654321123456789012345E-15 +dqadd71476 add 1.123456789987654321123456789012345E-16 0 -> 1.123456789987654321123456789012345E-16 +dqadd71477 add 1.123456789987654321123456789012345E-17 0 -> 1.123456789987654321123456789012345E-17 +dqadd71478 add 1.123456789987654321123456789012345E-18 0 -> 1.123456789987654321123456789012345E-18 +dqadd71479 add 1.123456789987654321123456789012345E-19 0 -> 1.123456789987654321123456789012345E-19 +dqadd71480 add 1.123456789987654321123456789012345E-20 0 -> 1.123456789987654321123456789012345E-20 +dqadd71481 add 1.123456789987654321123456789012345E-21 0 -> 1.123456789987654321123456789012345E-21 +dqadd71482 add 1.123456789987654321123456789012345E-22 0 -> 1.123456789987654321123456789012345E-22 +dqadd71483 add 1.123456789987654321123456789012345E-23 0 -> 1.123456789987654321123456789012345E-23 +dqadd71484 add 1.123456789987654321123456789012345E-24 0 -> 1.123456789987654321123456789012345E-24 +dqadd71485 add 1.123456789987654321123456789012345E-25 0 -> 1.123456789987654321123456789012345E-25 +dqadd71486 add 1.123456789987654321123456789012345E-26 0 -> 1.123456789987654321123456789012345E-26 +dqadd71487 add 1.123456789987654321123456789012345E-27 0 -> 1.123456789987654321123456789012345E-27 +dqadd71488 add 1.123456789987654321123456789012345E-28 0 -> 1.123456789987654321123456789012345E-28 +dqadd71489 add 1.123456789987654321123456789012345E-29 0 -> 1.123456789987654321123456789012345E-29 +dqadd71490 add 1.123456789987654321123456789012345E-30 0 -> 1.123456789987654321123456789012345E-30 +dqadd71491 add 1.123456789987654321123456789012345E-31 0 -> 1.123456789987654321123456789012345E-31 +dqadd71492 add 1.123456789987654321123456789012345E-32 0 -> 1.123456789987654321123456789012345E-32 +dqadd71493 add 1.123456789987654321123456789012345E-33 0 -> 1.123456789987654321123456789012345E-33 +dqadd71494 add 1.123456789987654321123456789012345E-34 0 -> 1.123456789987654321123456789012345E-34 +dqadd71495 add 1.123456789987654321123456789012345E-35 0 -> 1.123456789987654321123456789012345E-35 +dqadd71496 add 1.123456789987654321123456789012345E-36 0 -> 1.123456789987654321123456789012345E-36 + +-- same, Es on the 0 +dqadd71500 add 1.123456789987654321123456789012345 0E-0 -> 1.123456789987654321123456789012345 +dqadd71501 add 1.123456789987654321123456789012345 0E-1 -> 1.123456789987654321123456789012345 +dqadd71502 add 1.123456789987654321123456789012345 0E-2 -> 1.123456789987654321123456789012345 +dqadd71503 add 1.123456789987654321123456789012345 0E-3 -> 1.123456789987654321123456789012345 +dqadd71504 add 1.123456789987654321123456789012345 0E-4 -> 1.123456789987654321123456789012345 +dqadd71505 add 1.123456789987654321123456789012345 0E-5 -> 1.123456789987654321123456789012345 +dqadd71506 add 1.123456789987654321123456789012345 0E-6 -> 1.123456789987654321123456789012345 +dqadd71507 add 1.123456789987654321123456789012345 0E-7 -> 1.123456789987654321123456789012345 +dqadd71508 add 1.123456789987654321123456789012345 0E-8 -> 1.123456789987654321123456789012345 +dqadd71509 add 1.123456789987654321123456789012345 0E-9 -> 1.123456789987654321123456789012345 +dqadd71510 add 1.123456789987654321123456789012345 0E-10 -> 1.123456789987654321123456789012345 +dqadd71511 add 1.123456789987654321123456789012345 0E-11 -> 1.123456789987654321123456789012345 +dqadd71512 add 1.123456789987654321123456789012345 0E-12 -> 1.123456789987654321123456789012345 +dqadd71513 add 1.123456789987654321123456789012345 0E-13 -> 1.123456789987654321123456789012345 +dqadd71514 add 1.123456789987654321123456789012345 0E-14 -> 1.123456789987654321123456789012345 +dqadd71515 add 1.123456789987654321123456789012345 0E-15 -> 1.123456789987654321123456789012345 +dqadd71516 add 1.123456789987654321123456789012345 0E-16 -> 1.123456789987654321123456789012345 +dqadd71517 add 1.123456789987654321123456789012345 0E-17 -> 1.123456789987654321123456789012345 +dqadd71518 add 1.123456789987654321123456789012345 0E-18 -> 1.123456789987654321123456789012345 +dqadd71519 add 1.123456789987654321123456789012345 0E-19 -> 1.123456789987654321123456789012345 +dqadd71520 add 1.123456789987654321123456789012345 0E-20 -> 1.123456789987654321123456789012345 +dqadd71521 add 1.123456789987654321123456789012345 0E-21 -> 1.123456789987654321123456789012345 +dqadd71522 add 1.123456789987654321123456789012345 0E-22 -> 1.123456789987654321123456789012345 +dqadd71523 add 1.123456789987654321123456789012345 0E-23 -> 1.123456789987654321123456789012345 +dqadd71524 add 1.123456789987654321123456789012345 0E-24 -> 1.123456789987654321123456789012345 +dqadd71525 add 1.123456789987654321123456789012345 0E-25 -> 1.123456789987654321123456789012345 +dqadd71526 add 1.123456789987654321123456789012345 0E-26 -> 1.123456789987654321123456789012345 +dqadd71527 add 1.123456789987654321123456789012345 0E-27 -> 1.123456789987654321123456789012345 +dqadd71528 add 1.123456789987654321123456789012345 0E-28 -> 1.123456789987654321123456789012345 +dqadd71529 add 1.123456789987654321123456789012345 0E-29 -> 1.123456789987654321123456789012345 +dqadd71530 add 1.123456789987654321123456789012345 0E-30 -> 1.123456789987654321123456789012345 +dqadd71531 add 1.123456789987654321123456789012345 0E-31 -> 1.123456789987654321123456789012345 +dqadd71532 add 1.123456789987654321123456789012345 0E-32 -> 1.123456789987654321123456789012345 +dqadd71533 add 1.123456789987654321123456789012345 0E-33 -> 1.123456789987654321123456789012345 +-- next four flag Rounded because the 0 extends the result +dqadd71534 add 1.123456789987654321123456789012345 0E-34 -> 1.123456789987654321123456789012345 Rounded +dqadd71535 add 1.123456789987654321123456789012345 0E-35 -> 1.123456789987654321123456789012345 Rounded +dqadd71536 add 1.123456789987654321123456789012345 0E-36 -> 1.123456789987654321123456789012345 Rounded +dqadd71537 add 1.123456789987654321123456789012345 0E-37 -> 1.123456789987654321123456789012345 Rounded + +-- sum of two opposite-sign operands is exactly 0 and floor => -0 +rounding: half_up +-- exact zeros from zeros +dqadd71600 add 0 0E-19 -> 0E-19 +dqadd71601 add -0 0E-19 -> 0E-19 +dqadd71602 add 0 -0E-19 -> 0E-19 +dqadd71603 add -0 -0E-19 -> -0E-19 +-- exact zeros from non-zeros +dqadd71611 add -11 11 -> 0 +dqadd71612 add 11 -11 -> 0 + +rounding: half_down +-- exact zeros from zeros +dqadd71620 add 0 0E-19 -> 0E-19 +dqadd71621 add -0 0E-19 -> 0E-19 +dqadd71622 add 0 -0E-19 -> 0E-19 +dqadd71623 add -0 -0E-19 -> -0E-19 +-- exact zeros from non-zeros +dqadd71631 add -11 11 -> 0 +dqadd71632 add 11 -11 -> 0 + +rounding: half_even +-- exact zeros from zeros +dqadd71640 add 0 0E-19 -> 0E-19 +dqadd71641 add -0 0E-19 -> 0E-19 +dqadd71642 add 0 -0E-19 -> 0E-19 +dqadd71643 add -0 -0E-19 -> -0E-19 +-- exact zeros from non-zeros +dqadd71651 add -11 11 -> 0 +dqadd71652 add 11 -11 -> 0 + +rounding: up +-- exact zeros from zeros +dqadd71660 add 0 0E-19 -> 0E-19 +dqadd71661 add -0 0E-19 -> 0E-19 +dqadd71662 add 0 -0E-19 -> 0E-19 +dqadd71663 add -0 -0E-19 -> -0E-19 +-- exact zeros from non-zeros +dqadd71671 add -11 11 -> 0 +dqadd71672 add 11 -11 -> 0 + +rounding: down +-- exact zeros from zeros +dqadd71680 add 0 0E-19 -> 0E-19 +dqadd71681 add -0 0E-19 -> 0E-19 +dqadd71682 add 0 -0E-19 -> 0E-19 +dqadd71683 add -0 -0E-19 -> -0E-19 +-- exact zeros from non-zeros +dqadd71691 add -11 11 -> 0 +dqadd71692 add 11 -11 -> 0 + +rounding: ceiling +-- exact zeros from zeros +dqadd71700 add 0 0E-19 -> 0E-19 +dqadd71701 add -0 0E-19 -> 0E-19 +dqadd71702 add 0 -0E-19 -> 0E-19 +dqadd71703 add -0 -0E-19 -> -0E-19 +-- exact zeros from non-zeros +dqadd71711 add -11 11 -> 0 +dqadd71712 add 11 -11 -> 0 + +-- and the extra-special ugly case; unusual minuses marked by -- * +rounding: floor +-- exact zeros from zeros +dqadd71720 add 0 0E-19 -> 0E-19 +dqadd71721 add -0 0E-19 -> -0E-19 -- * +dqadd71722 add 0 -0E-19 -> -0E-19 -- * +dqadd71723 add -0 -0E-19 -> -0E-19 +-- exact zeros from non-zeros +dqadd71731 add -11 11 -> -0 -- * +dqadd71732 add 11 -11 -> -0 -- * + +-- Examples from SQL proposal (Krishna Kulkarni) +dqadd71741 add 130E-2 120E-2 -> 2.50 +dqadd71742 add 130E-2 12E-1 -> 2.50 +dqadd71743 add 130E-2 1E0 -> 2.30 +dqadd71744 add 1E2 1E4 -> 1.01E+4 +dqadd71745 add 130E-2 -120E-2 -> 0.10 +dqadd71746 add 130E-2 -12E-1 -> 0.10 +dqadd71747 add 130E-2 -1E0 -> 0.30 +dqadd71748 add 1E2 -1E4 -> -9.9E+3 + +-- Gappy coefficients; check residue handling even with full coefficient gap +rounding: half_even + +dqadd75001 add 1239876543211234567894567890123456 1 -> 1239876543211234567894567890123457 +dqadd75002 add 1239876543211234567894567890123456 0.6 -> 1239876543211234567894567890123457 Inexact Rounded +dqadd75003 add 1239876543211234567894567890123456 0.06 -> 1239876543211234567894567890123456 Inexact Rounded +dqadd75004 add 1239876543211234567894567890123456 6E-3 -> 1239876543211234567894567890123456 Inexact Rounded +dqadd75005 add 1239876543211234567894567890123456 6E-4 -> 1239876543211234567894567890123456 Inexact Rounded +dqadd75006 add 1239876543211234567894567890123456 6E-5 -> 1239876543211234567894567890123456 Inexact Rounded +dqadd75007 add 1239876543211234567894567890123456 6E-6 -> 1239876543211234567894567890123456 Inexact Rounded +dqadd75008 add 1239876543211234567894567890123456 6E-7 -> 1239876543211234567894567890123456 Inexact Rounded +dqadd75009 add 1239876543211234567894567890123456 6E-8 -> 1239876543211234567894567890123456 Inexact Rounded +dqadd75010 add 1239876543211234567894567890123456 6E-9 -> 1239876543211234567894567890123456 Inexact Rounded +dqadd75011 add 1239876543211234567894567890123456 6E-10 -> 1239876543211234567894567890123456 Inexact Rounded +dqadd75012 add 1239876543211234567894567890123456 6E-11 -> 1239876543211234567894567890123456 Inexact Rounded +dqadd75013 add 1239876543211234567894567890123456 6E-12 -> 1239876543211234567894567890123456 Inexact Rounded +dqadd75014 add 1239876543211234567894567890123456 6E-13 -> 1239876543211234567894567890123456 Inexact Rounded +dqadd75015 add 1239876543211234567894567890123456 6E-14 -> 1239876543211234567894567890123456 Inexact Rounded +dqadd75016 add 1239876543211234567894567890123456 6E-15 -> 1239876543211234567894567890123456 Inexact Rounded +dqadd75017 add 1239876543211234567894567890123456 6E-16 -> 1239876543211234567894567890123456 Inexact Rounded +dqadd75018 add 1239876543211234567894567890123456 6E-17 -> 1239876543211234567894567890123456 Inexact Rounded +dqadd75019 add 1239876543211234567894567890123456 6E-18 -> 1239876543211234567894567890123456 Inexact Rounded +dqadd75020 add 1239876543211234567894567890123456 6E-19 -> 1239876543211234567894567890123456 Inexact Rounded +dqadd75021 add 1239876543211234567894567890123456 6E-20 -> 1239876543211234567894567890123456 Inexact Rounded + +-- widening second argument at gap +dqadd75030 add 12398765432112345678945678 1 -> 12398765432112345678945679 +dqadd75031 add 12398765432112345678945678 0.1 -> 12398765432112345678945678.1 +dqadd75032 add 12398765432112345678945678 0.12 -> 12398765432112345678945678.12 +dqadd75033 add 12398765432112345678945678 0.123 -> 12398765432112345678945678.123 +dqadd75034 add 12398765432112345678945678 0.1234 -> 12398765432112345678945678.1234 +dqadd75035 add 12398765432112345678945678 0.12345 -> 12398765432112345678945678.12345 +dqadd75036 add 12398765432112345678945678 0.123456 -> 12398765432112345678945678.123456 +dqadd75037 add 12398765432112345678945678 0.1234567 -> 12398765432112345678945678.1234567 +dqadd75038 add 12398765432112345678945678 0.12345678 -> 12398765432112345678945678.12345678 +dqadd75039 add 12398765432112345678945678 0.123456789 -> 12398765432112345678945678.12345679 Inexact Rounded +dqadd75040 add 12398765432112345678945678 0.123456785 -> 12398765432112345678945678.12345678 Inexact Rounded +dqadd75041 add 12398765432112345678945678 0.1234567850 -> 12398765432112345678945678.12345678 Inexact Rounded +dqadd75042 add 12398765432112345678945678 0.1234567851 -> 12398765432112345678945678.12345679 Inexact Rounded +dqadd75043 add 12398765432112345678945678 0.12345678501 -> 12398765432112345678945678.12345679 Inexact Rounded +dqadd75044 add 12398765432112345678945678 0.123456785001 -> 12398765432112345678945678.12345679 Inexact Rounded +dqadd75045 add 12398765432112345678945678 0.1234567850001 -> 12398765432112345678945678.12345679 Inexact Rounded +dqadd75046 add 12398765432112345678945678 0.12345678500001 -> 12398765432112345678945678.12345679 Inexact Rounded +dqadd75047 add 12398765432112345678945678 0.123456785000001 -> 12398765432112345678945678.12345679 Inexact Rounded +dqadd75048 add 12398765432112345678945678 0.1234567850000001 -> 12398765432112345678945678.12345679 Inexact Rounded +dqadd75049 add 12398765432112345678945678 0.1234567850000000 -> 12398765432112345678945678.12345678 Inexact Rounded +-- 90123456 +rounding: half_even +dqadd75050 add 12398765432112345678945678 0.0234567750000000 -> 12398765432112345678945678.02345678 Inexact Rounded +dqadd75051 add 12398765432112345678945678 0.0034567750000000 -> 12398765432112345678945678.00345678 Inexact Rounded +dqadd75052 add 12398765432112345678945678 0.0004567750000000 -> 12398765432112345678945678.00045678 Inexact Rounded +dqadd75053 add 12398765432112345678945678 0.0000567750000000 -> 12398765432112345678945678.00005678 Inexact Rounded +dqadd75054 add 12398765432112345678945678 0.0000067750000000 -> 12398765432112345678945678.00000678 Inexact Rounded +dqadd75055 add 12398765432112345678945678 0.0000007750000000 -> 12398765432112345678945678.00000078 Inexact Rounded +dqadd75056 add 12398765432112345678945678 0.0000000750000000 -> 12398765432112345678945678.00000008 Inexact Rounded +dqadd75057 add 12398765432112345678945678 0.0000000050000000 -> 12398765432112345678945678.00000000 Inexact Rounded +dqadd75060 add 12398765432112345678945678 0.0234567750000001 -> 12398765432112345678945678.02345678 Inexact Rounded +dqadd75061 add 12398765432112345678945678 0.0034567750000001 -> 12398765432112345678945678.00345678 Inexact Rounded +dqadd75062 add 12398765432112345678945678 0.0004567750000001 -> 12398765432112345678945678.00045678 Inexact Rounded +dqadd75063 add 12398765432112345678945678 0.0000567750000001 -> 12398765432112345678945678.00005678 Inexact Rounded +dqadd75064 add 12398765432112345678945678 0.0000067750000001 -> 12398765432112345678945678.00000678 Inexact Rounded +dqadd75065 add 12398765432112345678945678 0.0000007750000001 -> 12398765432112345678945678.00000078 Inexact Rounded +dqadd75066 add 12398765432112345678945678 0.0000000750000001 -> 12398765432112345678945678.00000008 Inexact Rounded +dqadd75067 add 12398765432112345678945678 0.0000000050000001 -> 12398765432112345678945678.00000001 Inexact Rounded +-- far-out residues (full coefficient gap is 16+15 digits) +rounding: up +dqadd75070 add 12398765432112345678945678 1E-8 -> 12398765432112345678945678.00000001 +dqadd75071 add 12398765432112345678945678 1E-9 -> 12398765432112345678945678.00000001 Inexact Rounded +dqadd75072 add 12398765432112345678945678 1E-10 -> 12398765432112345678945678.00000001 Inexact Rounded +dqadd75073 add 12398765432112345678945678 1E-11 -> 12398765432112345678945678.00000001 Inexact Rounded +dqadd75074 add 12398765432112345678945678 1E-12 -> 12398765432112345678945678.00000001 Inexact Rounded +dqadd75075 add 12398765432112345678945678 1E-13 -> 12398765432112345678945678.00000001 Inexact Rounded +dqadd75076 add 12398765432112345678945678 1E-14 -> 12398765432112345678945678.00000001 Inexact Rounded +dqadd75077 add 12398765432112345678945678 1E-15 -> 12398765432112345678945678.00000001 Inexact Rounded +dqadd75078 add 12398765432112345678945678 1E-16 -> 12398765432112345678945678.00000001 Inexact Rounded +dqadd75079 add 12398765432112345678945678 1E-17 -> 12398765432112345678945678.00000001 Inexact Rounded +dqadd75080 add 12398765432112345678945678 1E-18 -> 12398765432112345678945678.00000001 Inexact Rounded +dqadd75081 add 12398765432112345678945678 1E-19 -> 12398765432112345678945678.00000001 Inexact Rounded +dqadd75082 add 12398765432112345678945678 1E-20 -> 12398765432112345678945678.00000001 Inexact Rounded +dqadd75083 add 12398765432112345678945678 1E-25 -> 12398765432112345678945678.00000001 Inexact Rounded +dqadd75084 add 12398765432112345678945678 1E-30 -> 12398765432112345678945678.00000001 Inexact Rounded +dqadd75085 add 12398765432112345678945678 1E-31 -> 12398765432112345678945678.00000001 Inexact Rounded +dqadd75086 add 12398765432112345678945678 1E-32 -> 12398765432112345678945678.00000001 Inexact Rounded +dqadd75087 add 12398765432112345678945678 1E-33 -> 12398765432112345678945678.00000001 Inexact Rounded +dqadd75088 add 12398765432112345678945678 1E-34 -> 12398765432112345678945678.00000001 Inexact Rounded +dqadd75089 add 12398765432112345678945678 1E-35 -> 12398765432112345678945678.00000001 Inexact Rounded + +-- Null tests +dqadd9990 add 10 # -> NaN Invalid_operation +dqadd9991 add # 10 -> NaN Invalid_operation Added: python/branches/release25-maint/Lib/test/decimaltestdata/dqAnd.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/dqAnd.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,420 @@ +------------------------------------------------------------------------ +-- dqAnd.decTest -- digitwise logical AND for decQuads -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +extended: 1 +clamp: 1 +precision: 34 +maxExponent: 6144 +minExponent: -6143 +rounding: half_even + +-- Sanity check (truth table) +dqand001 and 0 0 -> 0 +dqand002 and 0 1 -> 0 +dqand003 and 1 0 -> 0 +dqand004 and 1 1 -> 1 +dqand005 and 1100 1010 -> 1000 +-- and at msd and msd-1 +-- 1234567890123456789012345678901234 +dqand006 and 0000000000000000000000000000000000 0000000000000000000000000000000000 -> 0 +dqand007 and 0000000000000000000000000000000000 1000000000000000000000000000000000 -> 0 +dqand008 and 1000000000000000000000000000000000 0000000000000000000000000000000000 -> 0 +dqand009 and 1000000000000000000000000000000000 1000000000000000000000000000000000 -> 1000000000000000000000000000000000 +dqand010 and 0000000000000000000000000000000000 0000000000000000000000000000000000 -> 0 +dqand011 and 0000000000000000000000000000000000 0100000000000000000000000000000000 -> 0 +dqand012 and 0100000000000000000000000000000000 0000000000000000000000000000000000 -> 0 +dqand013 and 0100000000000000000000000000000000 0100000000000000000000000000000000 -> 100000000000000000000000000000000 + +-- Various lengths +-- 1234567890123456789012345678901234 + +dqand601 and 0111111111111111111111111111111111 1111111111111111111111111111111111 -> 111111111111111111111111111111111 +dqand602 and 1011111111111111111111111111111111 1111111111111111111111111111111111 -> 1011111111111111111111111111111111 +dqand603 and 1101111111111111111111111111111111 1111111111111111111111111111111111 -> 1101111111111111111111111111111111 +dqand604 and 1110111111111111111111111111111111 1111111111111111111111111111111111 -> 1110111111111111111111111111111111 +dqand605 and 1111011111111111111111111111111111 1111111111111111111111111111111111 -> 1111011111111111111111111111111111 +dqand606 and 1111101111111111111111111111111111 1111111111111111111111111111111111 -> 1111101111111111111111111111111111 +dqand607 and 1111110111111111111111111111111111 1111111111111111111111111111111111 -> 1111110111111111111111111111111111 +dqand608 and 1111111011111111111111111111111111 1111111111111111111111111111111111 -> 1111111011111111111111111111111111 +dqand609 and 1111111101111111111111111111111111 1111111111111111111111111111111111 -> 1111111101111111111111111111111111 +dqand610 and 1111111110111111111111111111111111 1111111111111111111111111111111111 -> 1111111110111111111111111111111111 +dqand611 and 1111111111011111111111111111111111 1111111111111111111111111111111111 -> 1111111111011111111111111111111111 +dqand612 and 1111111111101111111111111111111111 1111111111111111111111111111111111 -> 1111111111101111111111111111111111 +dqand613 and 1111111111110111111111111111111111 1111111111111111111111111111111111 -> 1111111111110111111111111111111111 +dqand614 and 1111111111111011111111111111111111 1111111111111111111111111111111111 -> 1111111111111011111111111111111111 +dqand615 and 1111111111111101111111111111111111 1111111111111111111111111111111111 -> 1111111111111101111111111111111111 +dqand616 and 1111111111111110111111111111111111 1111111111111111111111111111111111 -> 1111111111111110111111111111111111 +dqand617 and 1111111111111111011111111111111111 1111111111111111111111111111111111 -> 1111111111111111011111111111111111 +dqand618 and 1111111111111111101111111111111111 1111111111111111111111111111111111 -> 1111111111111111101111111111111111 +dqand619 and 1111111111111111110111111111111111 1111111111111111111111111111111111 -> 1111111111111111110111111111111111 +dqand620 and 1111111111111111111011111111111111 1111111111111111111111111111111111 -> 1111111111111111111011111111111111 +dqand621 and 1111111111111111111101111111111111 1111111111111111111111111111111111 -> 1111111111111111111101111111111111 +dqand622 and 1111111111111111111110111111111111 1111111111111111111111111111111111 -> 1111111111111111111110111111111111 +dqand623 and 1111111111111111111111011111111111 1111111111111111111111111111111111 -> 1111111111111111111111011111111111 +dqand624 and 1111111111111111111111101111111111 1111111111111111111111111111111111 -> 1111111111111111111111101111111111 +dqand625 and 1111111111111111111111110111111111 1111111111111111111111111111111111 -> 1111111111111111111111110111111111 +dqand626 and 1111111111111111111111111011111111 1111111111111111111111111111111111 -> 1111111111111111111111111011111111 +dqand627 and 1111111111111111111111111101111111 1111111111111111111111111111111111 -> 1111111111111111111111111101111111 +dqand628 and 1111111111111111111111111110111111 1111111111111111111111111111111111 -> 1111111111111111111111111110111111 +dqand629 and 1111111111111111111111111111011111 1111111111111111111111111111111111 -> 1111111111111111111111111111011111 +dqand630 and 1111111111111111111111111111101111 1111111111111111111111111111111111 -> 1111111111111111111111111111101111 +dqand631 and 1111111111111111111111111111110111 1111111111111111111111111111111111 -> 1111111111111111111111111111110111 +dqand632 and 1111111111111111111111111111111011 1111111111111111111111111111111111 -> 1111111111111111111111111111111011 +dqand633 and 1111111111111111111111111111111101 1111111111111111111111111111111111 -> 1111111111111111111111111111111101 +dqand634 and 1111111111111111111111111111111110 1111111111111111111111111111111111 -> 1111111111111111111111111111111110 + +dqand641 and 1111111111111111111111111111111111 0111111111111111111111111111111111 -> 111111111111111111111111111111111 +dqand642 and 1111111111111111111111111111111111 1011111111111111111111111111111111 -> 1011111111111111111111111111111111 +dqand643 and 1111111111111111111111111111111111 1101111111111111111111111111111111 -> 1101111111111111111111111111111111 +dqand644 and 1111111111111111111111111111111111 1110111111111111111111111111111111 -> 1110111111111111111111111111111111 +dqand645 and 1111111111111111111111111111111111 1111011111111111111111111111111111 -> 1111011111111111111111111111111111 +dqand646 and 1111111111111111111111111111111111 1111101111111111111111111111111111 -> 1111101111111111111111111111111111 +dqand647 and 1111111111111111111111111111111111 1111110111111111111111111111111111 -> 1111110111111111111111111111111111 +dqand648 and 1111111111111111111111111111111111 1111111011111111111111111111111111 -> 1111111011111111111111111111111111 +dqand649 and 1111111111111111111111111111111111 1111111101111111111111111111111111 -> 1111111101111111111111111111111111 +dqand650 and 1111111111111111111111111111111111 1111111110111111111111111111111111 -> 1111111110111111111111111111111111 +dqand651 and 1111111111111111111111111111111111 1111111111011111111111111111111111 -> 1111111111011111111111111111111111 +dqand652 and 1111111111111111111111111111111111 1111111111101111111111111111111111 -> 1111111111101111111111111111111111 +dqand653 and 1111111111111111111111111111111111 1111111111110111111111111111111111 -> 1111111111110111111111111111111111 +dqand654 and 1111111111111111111111111111111111 1111111111111011111111111111111111 -> 1111111111111011111111111111111111 +dqand655 and 1111111111111111111111111111111111 1111111111111101111111111111111111 -> 1111111111111101111111111111111111 +dqand656 and 1111111111111111111111111111111111 1111111111111110111111111111111111 -> 1111111111111110111111111111111111 +dqand657 and 1111111111111111111111111111111111 1111111111111111011111111111111111 -> 1111111111111111011111111111111111 +dqand658 and 1111111111111111111111111111111111 1111111111111111101111111111111111 -> 1111111111111111101111111111111111 +dqand659 and 1111111111111111111111111111111111 1111111111111111110111111111111111 -> 1111111111111111110111111111111111 +dqand660 and 1111111111111111111111111111111111 1111111111111111111011111111111111 -> 1111111111111111111011111111111111 +dqand661 and 1111111111111111111111111111111111 1111111111111111111101111111111111 -> 1111111111111111111101111111111111 +dqand662 and 1111111111111111111111111111111111 1111111111111111111110111111111111 -> 1111111111111111111110111111111111 +dqand663 and 1111111111111111111111111111111111 1111111111111111111111011111111111 -> 1111111111111111111111011111111111 +dqand664 and 1111111111111111111111111111111111 1111111111111111111111101111111111 -> 1111111111111111111111101111111111 +dqand665 and 1111111111111111111111111111111111 1111111111111111111111110111111111 -> 1111111111111111111111110111111111 +dqand666 and 1111111111111111111111111111111111 1111111111111111111111111011111111 -> 1111111111111111111111111011111111 +dqand667 and 1111111111111111111111111111111111 1111111111111111111111111101111111 -> 1111111111111111111111111101111111 +dqand668 and 1111111111111111111111111111111111 1111111111111111111111111110111111 -> 1111111111111111111111111110111111 +dqand669 and 1111111111111111111111111111111111 1111111111111111111111111111011111 -> 1111111111111111111111111111011111 +dqand670 and 1111111111111111111111111111111111 1111111111111111111111111111101111 -> 1111111111111111111111111111101111 +dqand671 and 1111111111111111111111111111111111 1111111111111111111111111111110111 -> 1111111111111111111111111111110111 +dqand672 and 1111111111111111111111111111111111 1111111111111111111111111111111011 -> 1111111111111111111111111111111011 +dqand673 and 1111111111111111111111111111111111 1111111111111111111111111111111101 -> 1111111111111111111111111111111101 +dqand674 and 1111111111111111111111111111111111 1111111111111111111111111111111110 -> 1111111111111111111111111111111110 +dqand675 and 0111111111111111111111111111111111 1111111111111111111111111111111110 -> 111111111111111111111111111111110 +dqand676 and 1111111111111111111111111111111111 1111111111111111111111111111111110 -> 1111111111111111111111111111111110 + +dqand021 and 1111111111111111 1111111111111111 -> 1111111111111111 +dqand024 and 1111111111111111 111111111111111 -> 111111111111111 +dqand025 and 1111111111111111 11111111111111 -> 11111111111111 +dqand026 and 1111111111111111 1111111111111 -> 1111111111111 +dqand027 and 1111111111111111 111111111111 -> 111111111111 +dqand028 and 1111111111111111 11111111111 -> 11111111111 +dqand029 and 1111111111111111 1111111111 -> 1111111111 +dqand030 and 1111111111111111 111111111 -> 111111111 +dqand031 and 1111111111111111 11111111 -> 11111111 +dqand032 and 1111111111111111 1111111 -> 1111111 +dqand033 and 1111111111111111 111111 -> 111111 +dqand034 and 1111111111111111 11111 -> 11111 +dqand035 and 1111111111111111 1111 -> 1111 +dqand036 and 1111111111111111 111 -> 111 +dqand037 and 1111111111111111 11 -> 11 +dqand038 and 1111111111111111 1 -> 1 +dqand039 and 1111111111111111 0 -> 0 + +dqand040 and 1111111111111111 1111111111111111 -> 1111111111111111 +dqand041 and 111111111111111 1111111111111111 -> 111111111111111 +dqand042 and 111111111111111 1111111111111111 -> 111111111111111 +dqand043 and 11111111111111 1111111111111111 -> 11111111111111 +dqand044 and 1111111111111 1111111111111111 -> 1111111111111 +dqand045 and 111111111111 1111111111111111 -> 111111111111 +dqand046 and 11111111111 1111111111111111 -> 11111111111 +dqand047 and 1111111111 1111111111111111 -> 1111111111 +dqand048 and 111111111 1111111111111111 -> 111111111 +dqand049 and 11111111 1111111111111111 -> 11111111 +dqand050 and 1111111 1111111111111111 -> 1111111 +dqand051 and 111111 1111111111111111 -> 111111 +dqand052 and 11111 1111111111111111 -> 11111 +dqand053 and 1111 1111111111111111 -> 1111 +dqand054 and 111 1111111111111111 -> 111 +dqand055 and 11 1111111111111111 -> 11 +dqand056 and 1 1111111111111111 -> 1 +dqand057 and 0 1111111111111111 -> 0 + +dqand150 and 1111111111 1 -> 1 +dqand151 and 111111111 1 -> 1 +dqand152 and 11111111 1 -> 1 +dqand153 and 1111111 1 -> 1 +dqand154 and 111111 1 -> 1 +dqand155 and 11111 1 -> 1 +dqand156 and 1111 1 -> 1 +dqand157 and 111 1 -> 1 +dqand158 and 11 1 -> 1 +dqand159 and 1 1 -> 1 + +dqand160 and 1111111111 0 -> 0 +dqand161 and 111111111 0 -> 0 +dqand162 and 11111111 0 -> 0 +dqand163 and 1111111 0 -> 0 +dqand164 and 111111 0 -> 0 +dqand165 and 11111 0 -> 0 +dqand166 and 1111 0 -> 0 +dqand167 and 111 0 -> 0 +dqand168 and 11 0 -> 0 +dqand169 and 1 0 -> 0 + +dqand170 and 1 1111111111 -> 1 +dqand171 and 1 111111111 -> 1 +dqand172 and 1 11111111 -> 1 +dqand173 and 1 1111111 -> 1 +dqand174 and 1 111111 -> 1 +dqand175 and 1 11111 -> 1 +dqand176 and 1 1111 -> 1 +dqand177 and 1 111 -> 1 +dqand178 and 1 11 -> 1 +dqand179 and 1 1 -> 1 + +dqand180 and 0 1111111111 -> 0 +dqand181 and 0 111111111 -> 0 +dqand182 and 0 11111111 -> 0 +dqand183 and 0 1111111 -> 0 +dqand184 and 0 111111 -> 0 +dqand185 and 0 11111 -> 0 +dqand186 and 0 1111 -> 0 +dqand187 and 0 111 -> 0 +dqand188 and 0 11 -> 0 +dqand189 and 0 1 -> 0 + +dqand090 and 011111111 111111111 -> 11111111 +dqand091 and 101111111 111111111 -> 101111111 +dqand092 and 110111111 111111111 -> 110111111 +dqand093 and 111011111 111111111 -> 111011111 +dqand094 and 111101111 111111111 -> 111101111 +dqand095 and 111110111 111111111 -> 111110111 +dqand096 and 111111011 111111111 -> 111111011 +dqand097 and 111111101 111111111 -> 111111101 +dqand098 and 111111110 111111111 -> 111111110 + +dqand100 and 111111111 011111111 -> 11111111 +dqand101 and 111111111 101111111 -> 101111111 +dqand102 and 111111111 110111111 -> 110111111 +dqand103 and 111111111 111011111 -> 111011111 +dqand104 and 111111111 111101111 -> 111101111 +dqand105 and 111111111 111110111 -> 111110111 +dqand106 and 111111111 111111011 -> 111111011 +dqand107 and 111111111 111111101 -> 111111101 +dqand108 and 111111111 111111110 -> 111111110 + +-- non-0/1 should not be accepted, nor should signs +dqand220 and 111111112 111111111 -> NaN Invalid_operation +dqand221 and 333333333 333333333 -> NaN Invalid_operation +dqand222 and 555555555 555555555 -> NaN Invalid_operation +dqand223 and 777777777 777777777 -> NaN Invalid_operation +dqand224 and 999999999 999999999 -> NaN Invalid_operation +dqand225 and 222222222 999999999 -> NaN Invalid_operation +dqand226 and 444444444 999999999 -> NaN Invalid_operation +dqand227 and 666666666 999999999 -> NaN Invalid_operation +dqand228 and 888888888 999999999 -> NaN Invalid_operation +dqand229 and 999999999 222222222 -> NaN Invalid_operation +dqand230 and 999999999 444444444 -> NaN Invalid_operation +dqand231 and 999999999 666666666 -> NaN Invalid_operation +dqand232 and 999999999 888888888 -> NaN Invalid_operation +-- a few randoms +dqand240 and 567468689 -934981942 -> NaN Invalid_operation +dqand241 and 567367689 934981942 -> NaN Invalid_operation +dqand242 and -631917772 -706014634 -> NaN Invalid_operation +dqand243 and -756253257 138579234 -> NaN Invalid_operation +dqand244 and 835590149 567435400 -> NaN Invalid_operation +-- test MSD +dqand250 and 2000000111000111000111000000000000 1000000111000111000111000000000000 -> NaN Invalid_operation +dqand251 and 7000000111000111000111000000000000 1000000111000111000111000000000000 -> NaN Invalid_operation +dqand252 and 8000000111000111000111000000000000 1000000111000111000111000000000000 -> NaN Invalid_operation +dqand253 and 9000000111000111000111000000000000 1000000111000111000111000000000000 -> NaN Invalid_operation +dqand254 and 2000000111000111000111000000000000 0000000111000111000111000000000000 -> NaN Invalid_operation +dqand255 and 7000000111000111000111000000000000 0000000111000111000111000000000000 -> NaN Invalid_operation +dqand256 and 8000000111000111000111000000000000 0000000111000111000111000000000000 -> NaN Invalid_operation +dqand257 and 9000000111000111000111000000000000 0000000111000111000111000000000000 -> NaN Invalid_operation +dqand258 and 1000000111000111000111000000000000 2000000111000111000111000000000000 -> NaN Invalid_operation +dqand259 and 1000000111000111000111000000000000 7000000111000111000111000000000000 -> NaN Invalid_operation +dqand260 and 1000000111000111000111000000000000 8000000111000111000111000000000000 -> NaN Invalid_operation +dqand261 and 1000000111000111000111000000000000 9000000111000111000111000000000000 -> NaN Invalid_operation +dqand262 and 0000000111000111000111000000000000 2000000111000111000111000000000000 -> NaN Invalid_operation +dqand263 and 0000000111000111000111000000000000 7000000111000111000111000000000000 -> NaN Invalid_operation +dqand264 and 0000000111000111000111000000000000 8000000111000111000111000000000000 -> NaN Invalid_operation +dqand265 and 0000000111000111000111000000000000 9000000111000111000111000000000000 -> NaN Invalid_operation +-- test MSD-1 +dqand270 and 0200000111000111000111001000000000 1000000111000111000111100000000010 -> NaN Invalid_operation +dqand271 and 0700000111000111000111000100000000 1000000111000111000111010000000100 -> NaN Invalid_operation +dqand272 and 0800000111000111000111000010000000 1000000111000111000111001000001000 -> NaN Invalid_operation +dqand273 and 0900000111000111000111000001000000 1000000111000111000111000100010000 -> NaN Invalid_operation +dqand274 and 1000000111000111000111000000100000 0200000111000111000111000010100000 -> NaN Invalid_operation +dqand275 and 1000000111000111000111000000010000 0700000111000111000111000001000000 -> NaN Invalid_operation +dqand276 and 1000000111000111000111000000001000 0800000111000111000111000010100000 -> NaN Invalid_operation +dqand277 and 1000000111000111000111000000000100 0900000111000111000111000000010000 -> NaN Invalid_operation +-- test LSD +dqand280 and 0010000111000111000111000000000002 1000000111000111000111000100000001 -> NaN Invalid_operation +dqand281 and 0001000111000111000111000000000007 1000000111000111000111001000000011 -> NaN Invalid_operation +dqand282 and 0000000111000111000111100000000008 1000000111000111000111010000000001 -> NaN Invalid_operation +dqand283 and 0000000111000111000111010000000009 1000000111000111000111100000000001 -> NaN Invalid_operation +dqand284 and 1000000111000111000111001000000000 0001000111000111000111000000000002 -> NaN Invalid_operation +dqand285 and 1000000111000111000111000100000000 0010000111000111000111000000000007 -> NaN Invalid_operation +dqand286 and 1000000111000111000111000010000000 0100000111000111000111000000000008 -> NaN Invalid_operation +dqand287 and 1000000111000111000111000001000000 1000000111000111000111000000000009 -> NaN Invalid_operation +-- test Middie +dqand288 and 0010000111000111000111000020000000 1000000111000111000111001000000000 -> NaN Invalid_operation +dqand289 and 0001000111000111000111000070000001 1000000111000111000111000100000000 -> NaN Invalid_operation +dqand290 and 0000000111000111000111100080000010 1000000111000111000111000010000000 -> NaN Invalid_operation +dqand291 and 0000000111000111000111010090000100 1000000111000111000111000001000000 -> NaN Invalid_operation +dqand292 and 1000000111000111000111001000001000 0000000111000111000111000020100000 -> NaN Invalid_operation +dqand293 and 1000000111000111000111000100010000 0000000111000111000111000070010000 -> NaN Invalid_operation +dqand294 and 1000000111000111000111000010100000 0000000111000111000111000080001000 -> NaN Invalid_operation +dqand295 and 1000000111000111000111000001000000 0000000111000111000111000090000100 -> NaN Invalid_operation +-- signs +dqand296 and -1000000111000111000111000001000000 -0000001110001110001110010000000100 -> NaN Invalid_operation +dqand297 and -1000000111000111000111000001000000 0000001110001110001110000010000100 -> NaN Invalid_operation +dqand298 and 1000000111000111000111000001000000 -0000001110001110001110001000000100 -> NaN Invalid_operation +dqand299 and 1000000111000111000111000001000000 0000001110001110001110000011000100 -> 110000110000110000001000000 + +-- Nmax, Nmin, Ntiny-like +dqand331 and 2 9.99999999E+999 -> NaN Invalid_operation +dqand332 and 3 1E-999 -> NaN Invalid_operation +dqand333 and 4 1.00000000E-999 -> NaN Invalid_operation +dqand334 and 5 1E-900 -> NaN Invalid_operation +dqand335 and 6 -1E-900 -> NaN Invalid_operation +dqand336 and 7 -1.00000000E-999 -> NaN Invalid_operation +dqand337 and 8 -1E-999 -> NaN Invalid_operation +dqand338 and 9 -9.99999999E+999 -> NaN Invalid_operation +dqand341 and 9.99999999E+999 -18 -> NaN Invalid_operation +dqand342 and 1E-999 01 -> NaN Invalid_operation +dqand343 and 1.00000000E-999 -18 -> NaN Invalid_operation +dqand344 and 1E-900 18 -> NaN Invalid_operation +dqand345 and -1E-900 -10 -> NaN Invalid_operation +dqand346 and -1.00000000E-999 18 -> NaN Invalid_operation +dqand347 and -1E-999 10 -> NaN Invalid_operation +dqand348 and -9.99999999E+999 -18 -> NaN Invalid_operation + +-- A few other non-integers +dqand361 and 1.0 1 -> NaN Invalid_operation +dqand362 and 1E+1 1 -> NaN Invalid_operation +dqand363 and 0.0 1 -> NaN Invalid_operation +dqand364 and 0E+1 1 -> NaN Invalid_operation +dqand365 and 9.9 1 -> NaN Invalid_operation +dqand366 and 9E+1 1 -> NaN Invalid_operation +dqand371 and 0 1.0 -> NaN Invalid_operation +dqand372 and 0 1E+1 -> NaN Invalid_operation +dqand373 and 0 0.0 -> NaN Invalid_operation +dqand374 and 0 0E+1 -> NaN Invalid_operation +dqand375 and 0 9.9 -> NaN Invalid_operation +dqand376 and 0 9E+1 -> NaN Invalid_operation + +-- All Specials are in error +dqand780 and -Inf -Inf -> NaN Invalid_operation +dqand781 and -Inf -1000 -> NaN Invalid_operation +dqand782 and -Inf -1 -> NaN Invalid_operation +dqand783 and -Inf -0 -> NaN Invalid_operation +dqand784 and -Inf 0 -> NaN Invalid_operation +dqand785 and -Inf 1 -> NaN Invalid_operation +dqand786 and -Inf 1000 -> NaN Invalid_operation +dqand787 and -1000 -Inf -> NaN Invalid_operation +dqand788 and -Inf -Inf -> NaN Invalid_operation +dqand789 and -1 -Inf -> NaN Invalid_operation +dqand790 and -0 -Inf -> NaN Invalid_operation +dqand791 and 0 -Inf -> NaN Invalid_operation +dqand792 and 1 -Inf -> NaN Invalid_operation +dqand793 and 1000 -Inf -> NaN Invalid_operation +dqand794 and Inf -Inf -> NaN Invalid_operation + +dqand800 and Inf -Inf -> NaN Invalid_operation +dqand801 and Inf -1000 -> NaN Invalid_operation +dqand802 and Inf -1 -> NaN Invalid_operation +dqand803 and Inf -0 -> NaN Invalid_operation +dqand804 and Inf 0 -> NaN Invalid_operation +dqand805 and Inf 1 -> NaN Invalid_operation +dqand806 and Inf 1000 -> NaN Invalid_operation +dqand807 and Inf Inf -> NaN Invalid_operation +dqand808 and -1000 Inf -> NaN Invalid_operation +dqand809 and -Inf Inf -> NaN Invalid_operation +dqand810 and -1 Inf -> NaN Invalid_operation +dqand811 and -0 Inf -> NaN Invalid_operation +dqand812 and 0 Inf -> NaN Invalid_operation +dqand813 and 1 Inf -> NaN Invalid_operation +dqand814 and 1000 Inf -> NaN Invalid_operation +dqand815 and Inf Inf -> NaN Invalid_operation + +dqand821 and NaN -Inf -> NaN Invalid_operation +dqand822 and NaN -1000 -> NaN Invalid_operation +dqand823 and NaN -1 -> NaN Invalid_operation +dqand824 and NaN -0 -> NaN Invalid_operation +dqand825 and NaN 0 -> NaN Invalid_operation +dqand826 and NaN 1 -> NaN Invalid_operation +dqand827 and NaN 1000 -> NaN Invalid_operation +dqand828 and NaN Inf -> NaN Invalid_operation +dqand829 and NaN NaN -> NaN Invalid_operation +dqand830 and -Inf NaN -> NaN Invalid_operation +dqand831 and -1000 NaN -> NaN Invalid_operation +dqand832 and -1 NaN -> NaN Invalid_operation +dqand833 and -0 NaN -> NaN Invalid_operation +dqand834 and 0 NaN -> NaN Invalid_operation +dqand835 and 1 NaN -> NaN Invalid_operation +dqand836 and 1000 NaN -> NaN Invalid_operation +dqand837 and Inf NaN -> NaN Invalid_operation + +dqand841 and sNaN -Inf -> NaN Invalid_operation +dqand842 and sNaN -1000 -> NaN Invalid_operation +dqand843 and sNaN -1 -> NaN Invalid_operation +dqand844 and sNaN -0 -> NaN Invalid_operation +dqand845 and sNaN 0 -> NaN Invalid_operation +dqand846 and sNaN 1 -> NaN Invalid_operation +dqand847 and sNaN 1000 -> NaN Invalid_operation +dqand848 and sNaN NaN -> NaN Invalid_operation +dqand849 and sNaN sNaN -> NaN Invalid_operation +dqand850 and NaN sNaN -> NaN Invalid_operation +dqand851 and -Inf sNaN -> NaN Invalid_operation +dqand852 and -1000 sNaN -> NaN Invalid_operation +dqand853 and -1 sNaN -> NaN Invalid_operation +dqand854 and -0 sNaN -> NaN Invalid_operation +dqand855 and 0 sNaN -> NaN Invalid_operation +dqand856 and 1 sNaN -> NaN Invalid_operation +dqand857 and 1000 sNaN -> NaN Invalid_operation +dqand858 and Inf sNaN -> NaN Invalid_operation +dqand859 and NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +dqand861 and NaN1 -Inf -> NaN Invalid_operation +dqand862 and +NaN2 -1000 -> NaN Invalid_operation +dqand863 and NaN3 1000 -> NaN Invalid_operation +dqand864 and NaN4 Inf -> NaN Invalid_operation +dqand865 and NaN5 +NaN6 -> NaN Invalid_operation +dqand866 and -Inf NaN7 -> NaN Invalid_operation +dqand867 and -1000 NaN8 -> NaN Invalid_operation +dqand868 and 1000 NaN9 -> NaN Invalid_operation +dqand869 and Inf +NaN10 -> NaN Invalid_operation +dqand871 and sNaN11 -Inf -> NaN Invalid_operation +dqand872 and sNaN12 -1000 -> NaN Invalid_operation +dqand873 and sNaN13 1000 -> NaN Invalid_operation +dqand874 and sNaN14 NaN17 -> NaN Invalid_operation +dqand875 and sNaN15 sNaN18 -> NaN Invalid_operation +dqand876 and NaN16 sNaN19 -> NaN Invalid_operation +dqand877 and -Inf +sNaN20 -> NaN Invalid_operation +dqand878 and -1000 sNaN21 -> NaN Invalid_operation +dqand879 and 1000 sNaN22 -> NaN Invalid_operation +dqand880 and Inf sNaN23 -> NaN Invalid_operation +dqand881 and +NaN25 +sNaN24 -> NaN Invalid_operation +dqand882 and -NaN26 NaN28 -> NaN Invalid_operation +dqand883 and -sNaN27 sNaN29 -> NaN Invalid_operation +dqand884 and 1000 -NaN30 -> NaN Invalid_operation +dqand885 and 1000 -sNaN31 -> NaN Invalid_operation Added: python/branches/release25-maint/Lib/test/decimaltestdata/dqBase.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/dqBase.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,1081 @@ +------------------------------------------------------------------------ +-- dqBase.decTest -- base decQuad <--> string conversions -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- This file tests base conversions from string to a decimal number +-- and back to a string (in Scientific form) + +-- Note that unlike other operations the operand is subject to rounding +-- to conform to emax and precision settings (that is, numbers will +-- conform to rules and exponent will be in permitted range). The +-- 'left hand side', therefore, may have numbers that cannot be +-- represented in a decQuad. Some testcases go to the limit of the +-- next-wider format, and hence these testcases may also be used to +-- test narrowing and widening operations. + +extended: 1 +clamp: 1 +precision: 34 +maxExponent: 6144 +minExponent: -6143 +rounding: half_even + +dqbas001 toSci 0 -> 0 +dqbas002 toSci 1 -> 1 +dqbas003 toSci 1.0 -> 1.0 +dqbas004 toSci 1.00 -> 1.00 +dqbas005 toSci 10 -> 10 +dqbas006 toSci 1000 -> 1000 +dqbas007 toSci 10.0 -> 10.0 +dqbas008 toSci 10.1 -> 10.1 +dqbas009 toSci 10.4 -> 10.4 +dqbas010 toSci 10.5 -> 10.5 +dqbas011 toSci 10.6 -> 10.6 +dqbas012 toSci 10.9 -> 10.9 +dqbas013 toSci 11.0 -> 11.0 +dqbas014 toSci 1.234 -> 1.234 +dqbas015 toSci 0.123 -> 0.123 +dqbas016 toSci 0.012 -> 0.012 +dqbas017 toSci -0 -> -0 +dqbas018 toSci -0.0 -> -0.0 +dqbas019 toSci -00.00 -> -0.00 + +dqbas021 toSci -1 -> -1 +dqbas022 toSci -1.0 -> -1.0 +dqbas023 toSci -0.1 -> -0.1 +dqbas024 toSci -9.1 -> -9.1 +dqbas025 toSci -9.11 -> -9.11 +dqbas026 toSci -9.119 -> -9.119 +dqbas027 toSci -9.999 -> -9.999 + +dqbas030 toSci '123456789.123456' -> '123456789.123456' +dqbas031 toSci '123456789.000000' -> '123456789.000000' +dqbas032 toSci '123456789123456' -> '123456789123456' +dqbas033 toSci '0.0000123456789' -> '0.0000123456789' +dqbas034 toSci '0.00000123456789' -> '0.00000123456789' +dqbas035 toSci '0.000000123456789' -> '1.23456789E-7' +dqbas036 toSci '0.0000000123456789' -> '1.23456789E-8' + +dqbas037 toSci '0.123456789012344' -> '0.123456789012344' +dqbas038 toSci '0.123456789012345' -> '0.123456789012345' + +-- test finite bounds (Negs of, then 0, Ntiny, Nmin, other, Nmax) +dqbsn001 toSci -9.999999999999999999999999999999999E+6144 -> -9.999999999999999999999999999999999E+6144 +dqbsn002 toSci -1E-6143 -> -1E-6143 +dqbsn003 toSci -1E-6176 -> -1E-6176 Subnormal +dqbsn004 toSci -0 -> -0 +dqbsn005 toSci +0 -> 0 +dqbsn006 toSci +1E-6176 -> 1E-6176 Subnormal +dqbsn007 toSci +1E-6143 -> 1E-6143 +dqbsn008 toSci +9.999999999999999999999999999999999E+6144 -> 9.999999999999999999999999999999999E+6144 + +-- String [many more examples are implicitly tested elsewhere] +-- strings without E cannot generate E in result +dqbas040 toSci "12" -> '12' +dqbas041 toSci "-76" -> '-76' +dqbas042 toSci "12.76" -> '12.76' +dqbas043 toSci "+12.76" -> '12.76' +dqbas044 toSci "012.76" -> '12.76' +dqbas045 toSci "+0.003" -> '0.003' +dqbas046 toSci "17." -> '17' +dqbas047 toSci ".5" -> '0.5' +dqbas048 toSci "044" -> '44' +dqbas049 toSci "0044" -> '44' +dqbas050 toSci "0.0005" -> '0.0005' +dqbas051 toSci "00.00005" -> '0.00005' +dqbas052 toSci "0.000005" -> '0.000005' +dqbas053 toSci "0.0000050" -> '0.0000050' +dqbas054 toSci "0.0000005" -> '5E-7' +dqbas055 toSci "0.00000005" -> '5E-8' +dqbas056 toSci "12345678.543210" -> '12345678.543210' +dqbas057 toSci "2345678.543210" -> '2345678.543210' +dqbas058 toSci "345678.543210" -> '345678.543210' +dqbas059 toSci "0345678.54321" -> '345678.54321' +dqbas060 toSci "345678.5432" -> '345678.5432' +dqbas061 toSci "+345678.5432" -> '345678.5432' +dqbas062 toSci "+0345678.5432" -> '345678.5432' +dqbas063 toSci "+00345678.5432" -> '345678.5432' +dqbas064 toSci "-345678.5432" -> '-345678.5432' +dqbas065 toSci "-0345678.5432" -> '-345678.5432' +dqbas066 toSci "-00345678.5432" -> '-345678.5432' +-- examples +dqbas067 toSci "5E-6" -> '0.000005' +dqbas068 toSci "50E-7" -> '0.0000050' +dqbas069 toSci "5E-7" -> '5E-7' + +-- [No exotics as no Unicode] + +-- rounded with dots in all (including edge) places +dqbas071 toSci .1234567891234567890123456780123456123 -> 0.1234567891234567890123456780123456 Inexact Rounded +dqbas072 toSci 1.234567891234567890123456780123456123 -> 1.234567891234567890123456780123456 Inexact Rounded +dqbas073 toSci 12.34567891234567890123456780123456123 -> 12.34567891234567890123456780123456 Inexact Rounded +dqbas074 toSci 123.4567891234567890123456780123456123 -> 123.4567891234567890123456780123456 Inexact Rounded +dqbas075 toSci 1234.567891234567890123456780123456123 -> 1234.567891234567890123456780123456 Inexact Rounded +dqbas076 toSci 12345.67891234567890123456780123456123 -> 12345.67891234567890123456780123456 Inexact Rounded +dqbas077 toSci 123456.7891234567890123456780123456123 -> 123456.7891234567890123456780123456 Inexact Rounded +dqbas078 toSci 1234567.891234567890123456780123456123 -> 1234567.891234567890123456780123456 Inexact Rounded +dqbas079 toSci 12345678.91234567890123456780123456123 -> 12345678.91234567890123456780123456 Inexact Rounded +dqbas080 toSci 123456789.1234567890123456780123456123 -> 123456789.1234567890123456780123456 Inexact Rounded +dqbas081 toSci 1234567891.234567890123456780123456123 -> 1234567891.234567890123456780123456 Inexact Rounded +dqbas082 toSci 12345678912.34567890123456780123456123 -> 12345678912.34567890123456780123456 Inexact Rounded +dqbas083 toSci 123456789123.4567890123456780123456123 -> 123456789123.4567890123456780123456 Inexact Rounded +dqbas084 toSci 1234567891234.567890123456780123456123 -> 1234567891234.567890123456780123456 Inexact Rounded +dqbas085 toSci 12345678912345.67890123456780123456123 -> 12345678912345.67890123456780123456 Inexact Rounded +dqbas086 toSci 123456789123456.7890123456780123456123 -> 123456789123456.7890123456780123456 Inexact Rounded +dqbas087 toSci 1234567891234567.890123456780123456123 -> 1234567891234567.890123456780123456 Inexact Rounded +dqbas088 toSci 12345678912345678.90123456780123456123 -> 12345678912345678.90123456780123456 Inexact Rounded +dqbas089 toSci 123456789123456789.0123456780123456123 -> 123456789123456789.0123456780123456 Inexact Rounded +dqbas090 toSci 1234567891234567890.123456780123456123 -> 1234567891234567890.123456780123456 Inexact Rounded +dqbas091 toSci 12345678912345678901.23456780123456123 -> 12345678912345678901.23456780123456 Inexact Rounded +dqbas092 toSci 123456789123456789012.3456780123456123 -> 123456789123456789012.3456780123456 Inexact Rounded +dqbas093 toSci 1234567891234567890123.456780123456123 -> 1234567891234567890123.456780123456 Inexact Rounded +dqbas094 toSci 12345678912345678901234.56780123456123 -> 12345678912345678901234.56780123456 Inexact Rounded +dqbas095 toSci 123456789123456789012345.6780123456123 -> 123456789123456789012345.6780123456 Inexact Rounded +dqbas096 toSci 1234567891234567890123456.780123456123 -> 1234567891234567890123456.780123456 Inexact Rounded +dqbas097 toSci 12345678912345678901234567.80123456123 -> 12345678912345678901234567.80123456 Inexact Rounded +dqbas098 toSci 123456789123456789012345678.0123456123 -> 123456789123456789012345678.0123456 Inexact Rounded +dqbas099 toSci 1234567891234567890123456780.123456123 -> 1234567891234567890123456780.123456 Inexact Rounded +dqbas100 toSci 12345678912345678901234567801.23456123 -> 12345678912345678901234567801.23456 Inexact Rounded +dqbas101 toSci 123456789123456789012345678012.3456123 -> 123456789123456789012345678012.3456 Inexact Rounded +dqbas102 toSci 1234567891234567890123456780123.456123 -> 1234567891234567890123456780123.456 Inexact Rounded +dqbas103 toSci 12345678912345678901234567801234.56123 -> 12345678912345678901234567801234.56 Inexact Rounded +dqbas104 toSci 123456789123456789012345678012345.6123 -> 123456789123456789012345678012345.6 Inexact Rounded +dqbas105 toSci 1234567891234567890123456780123456.123 -> 1234567891234567890123456780123456 Inexact Rounded +dqbas106 toSci 12345678912345678901234567801234561.23 -> 1.234567891234567890123456780123456E+34 Inexact Rounded +dqbas107 toSci 123456789123456789012345678012345612.3 -> 1.234567891234567890123456780123456E+35 Inexact Rounded +dqbas108 toSci 1234567891234567890123456780123456123. -> 1.234567891234567890123456780123456E+36 Inexact Rounded +-- 123456789012345678 + +-- Numbers with E +dqbas130 toSci "0.000E-1" -> '0.0000' +dqbas131 toSci "0.000E-2" -> '0.00000' +dqbas132 toSci "0.000E-3" -> '0.000000' +dqbas133 toSci "0.000E-4" -> '0E-7' +dqbas134 toSci "0.00E-2" -> '0.0000' +dqbas135 toSci "0.00E-3" -> '0.00000' +dqbas136 toSci "0.00E-4" -> '0.000000' +dqbas137 toSci "0.00E-5" -> '0E-7' +dqbas138 toSci "+0E+9" -> '0E+9' +dqbas139 toSci "-0E+9" -> '-0E+9' +dqbas140 toSci "1E+9" -> '1E+9' +dqbas141 toSci "1e+09" -> '1E+9' +dqbas142 toSci "1E+90" -> '1E+90' +dqbas143 toSci "+1E+009" -> '1E+9' +dqbas144 toSci "0E+9" -> '0E+9' +dqbas145 toSci "1E+9" -> '1E+9' +dqbas146 toSci "1E+09" -> '1E+9' +dqbas147 toSci "1e+90" -> '1E+90' +dqbas148 toSci "1E+009" -> '1E+9' +dqbas149 toSci "000E+9" -> '0E+9' +dqbas150 toSci "1E9" -> '1E+9' +dqbas151 toSci "1e09" -> '1E+9' +dqbas152 toSci "1E90" -> '1E+90' +dqbas153 toSci "1E009" -> '1E+9' +dqbas154 toSci "0E9" -> '0E+9' +dqbas155 toSci "0.000e+0" -> '0.000' +dqbas156 toSci "0.000E-1" -> '0.0000' +dqbas157 toSci "4E+9" -> '4E+9' +dqbas158 toSci "44E+9" -> '4.4E+10' +dqbas159 toSci "0.73e-7" -> '7.3E-8' +dqbas160 toSci "00E+9" -> '0E+9' +dqbas161 toSci "00E-9" -> '0E-9' +dqbas162 toSci "10E+9" -> '1.0E+10' +dqbas163 toSci "10E+09" -> '1.0E+10' +dqbas164 toSci "10e+90" -> '1.0E+91' +dqbas165 toSci "10E+009" -> '1.0E+10' +dqbas166 toSci "100e+9" -> '1.00E+11' +dqbas167 toSci "100e+09" -> '1.00E+11' +dqbas168 toSci "100E+90" -> '1.00E+92' +dqbas169 toSci "100e+009" -> '1.00E+11' + +dqbas170 toSci "1.265" -> '1.265' +dqbas171 toSci "1.265E-20" -> '1.265E-20' +dqbas172 toSci "1.265E-8" -> '1.265E-8' +dqbas173 toSci "1.265E-4" -> '0.0001265' +dqbas174 toSci "1.265E-3" -> '0.001265' +dqbas175 toSci "1.265E-2" -> '0.01265' +dqbas176 toSci "1.265E-1" -> '0.1265' +dqbas177 toSci "1.265E-0" -> '1.265' +dqbas178 toSci "1.265E+1" -> '12.65' +dqbas179 toSci "1.265E+2" -> '126.5' +dqbas180 toSci "1.265E+3" -> '1265' +dqbas181 toSci "1.265E+4" -> '1.265E+4' +dqbas182 toSci "1.265E+8" -> '1.265E+8' +dqbas183 toSci "1.265E+20" -> '1.265E+20' + +dqbas190 toSci "12.65" -> '12.65' +dqbas191 toSci "12.65E-20" -> '1.265E-19' +dqbas192 toSci "12.65E-8" -> '1.265E-7' +dqbas193 toSci "12.65E-4" -> '0.001265' +dqbas194 toSci "12.65E-3" -> '0.01265' +dqbas195 toSci "12.65E-2" -> '0.1265' +dqbas196 toSci "12.65E-1" -> '1.265' +dqbas197 toSci "12.65E-0" -> '12.65' +dqbas198 toSci "12.65E+1" -> '126.5' +dqbas199 toSci "12.65E+2" -> '1265' +dqbas200 toSci "12.65E+3" -> '1.265E+4' +dqbas201 toSci "12.65E+4" -> '1.265E+5' +dqbas202 toSci "12.65E+8" -> '1.265E+9' +dqbas203 toSci "12.65E+20" -> '1.265E+21' + +dqbas210 toSci "126.5" -> '126.5' +dqbas211 toSci "126.5E-20" -> '1.265E-18' +dqbas212 toSci "126.5E-8" -> '0.000001265' +dqbas213 toSci "126.5E-4" -> '0.01265' +dqbas214 toSci "126.5E-3" -> '0.1265' +dqbas215 toSci "126.5E-2" -> '1.265' +dqbas216 toSci "126.5E-1" -> '12.65' +dqbas217 toSci "126.5E-0" -> '126.5' +dqbas218 toSci "126.5E+1" -> '1265' +dqbas219 toSci "126.5E+2" -> '1.265E+4' +dqbas220 toSci "126.5E+3" -> '1.265E+5' +dqbas221 toSci "126.5E+4" -> '1.265E+6' +dqbas222 toSci "126.5E+8" -> '1.265E+10' +dqbas223 toSci "126.5E+20" -> '1.265E+22' + +dqbas230 toSci "1265" -> '1265' +dqbas231 toSci "1265E-20" -> '1.265E-17' +dqbas232 toSci "1265E-8" -> '0.00001265' +dqbas233 toSci "1265E-4" -> '0.1265' +dqbas234 toSci "1265E-3" -> '1.265' +dqbas235 toSci "1265E-2" -> '12.65' +dqbas236 toSci "1265E-1" -> '126.5' +dqbas237 toSci "1265E-0" -> '1265' +dqbas238 toSci "1265E+1" -> '1.265E+4' +dqbas239 toSci "1265E+2" -> '1.265E+5' +dqbas240 toSci "1265E+3" -> '1.265E+6' +dqbas241 toSci "1265E+4" -> '1.265E+7' +dqbas242 toSci "1265E+8" -> '1.265E+11' +dqbas243 toSci "1265E+20" -> '1.265E+23' + +dqbas250 toSci "0.1265" -> '0.1265' +dqbas251 toSci "0.1265E-20" -> '1.265E-21' +dqbas252 toSci "0.1265E-8" -> '1.265E-9' +dqbas253 toSci "0.1265E-4" -> '0.00001265' +dqbas254 toSci "0.1265E-3" -> '0.0001265' +dqbas255 toSci "0.1265E-2" -> '0.001265' +dqbas256 toSci "0.1265E-1" -> '0.01265' +dqbas257 toSci "0.1265E-0" -> '0.1265' +dqbas258 toSci "0.1265E+1" -> '1.265' +dqbas259 toSci "0.1265E+2" -> '12.65' +dqbas260 toSci "0.1265E+3" -> '126.5' +dqbas261 toSci "0.1265E+4" -> '1265' +dqbas262 toSci "0.1265E+8" -> '1.265E+7' +dqbas263 toSci "0.1265E+20" -> '1.265E+19' + +-- some more negative zeros [systematic tests below] +dqbas290 toSci "-0.000E-1" -> '-0.0000' +dqbas291 toSci "-0.000E-2" -> '-0.00000' +dqbas292 toSci "-0.000E-3" -> '-0.000000' +dqbas293 toSci "-0.000E-4" -> '-0E-7' +dqbas294 toSci "-0.00E-2" -> '-0.0000' +dqbas295 toSci "-0.00E-3" -> '-0.00000' +dqbas296 toSci "-0.0E-2" -> '-0.000' +dqbas297 toSci "-0.0E-3" -> '-0.0000' +dqbas298 toSci "-0E-2" -> '-0.00' +dqbas299 toSci "-0E-3" -> '-0.000' + +-- Engineering notation tests +dqbas301 toSci 10e12 -> 1.0E+13 +dqbas302 toEng 10e12 -> 10E+12 +dqbas303 toSci 10e11 -> 1.0E+12 +dqbas304 toEng 10e11 -> 1.0E+12 +dqbas305 toSci 10e10 -> 1.0E+11 +dqbas306 toEng 10e10 -> 100E+9 +dqbas307 toSci 10e9 -> 1.0E+10 +dqbas308 toEng 10e9 -> 10E+9 +dqbas309 toSci 10e8 -> 1.0E+9 +dqbas310 toEng 10e8 -> 1.0E+9 +dqbas311 toSci 10e7 -> 1.0E+8 +dqbas312 toEng 10e7 -> 100E+6 +dqbas313 toSci 10e6 -> 1.0E+7 +dqbas314 toEng 10e6 -> 10E+6 +dqbas315 toSci 10e5 -> 1.0E+6 +dqbas316 toEng 10e5 -> 1.0E+6 +dqbas317 toSci 10e4 -> 1.0E+5 +dqbas318 toEng 10e4 -> 100E+3 +dqbas319 toSci 10e3 -> 1.0E+4 +dqbas320 toEng 10e3 -> 10E+3 +dqbas321 toSci 10e2 -> 1.0E+3 +dqbas322 toEng 10e2 -> 1.0E+3 +dqbas323 toSci 10e1 -> 1.0E+2 +dqbas324 toEng 10e1 -> 100 +dqbas325 toSci 10e0 -> 10 +dqbas326 toEng 10e0 -> 10 +dqbas327 toSci 10e-1 -> 1.0 +dqbas328 toEng 10e-1 -> 1.0 +dqbas329 toSci 10e-2 -> 0.10 +dqbas330 toEng 10e-2 -> 0.10 +dqbas331 toSci 10e-3 -> 0.010 +dqbas332 toEng 10e-3 -> 0.010 +dqbas333 toSci 10e-4 -> 0.0010 +dqbas334 toEng 10e-4 -> 0.0010 +dqbas335 toSci 10e-5 -> 0.00010 +dqbas336 toEng 10e-5 -> 0.00010 +dqbas337 toSci 10e-6 -> 0.000010 +dqbas338 toEng 10e-6 -> 0.000010 +dqbas339 toSci 10e-7 -> 0.0000010 +dqbas340 toEng 10e-7 -> 0.0000010 +dqbas341 toSci 10e-8 -> 1.0E-7 +dqbas342 toEng 10e-8 -> 100E-9 +dqbas343 toSci 10e-9 -> 1.0E-8 +dqbas344 toEng 10e-9 -> 10E-9 +dqbas345 toSci 10e-10 -> 1.0E-9 +dqbas346 toEng 10e-10 -> 1.0E-9 +dqbas347 toSci 10e-11 -> 1.0E-10 +dqbas348 toEng 10e-11 -> 100E-12 +dqbas349 toSci 10e-12 -> 1.0E-11 +dqbas350 toEng 10e-12 -> 10E-12 +dqbas351 toSci 10e-13 -> 1.0E-12 +dqbas352 toEng 10e-13 -> 1.0E-12 + +dqbas361 toSci 7E12 -> 7E+12 +dqbas362 toEng 7E12 -> 7E+12 +dqbas363 toSci 7E11 -> 7E+11 +dqbas364 toEng 7E11 -> 700E+9 +dqbas365 toSci 7E10 -> 7E+10 +dqbas366 toEng 7E10 -> 70E+9 +dqbas367 toSci 7E9 -> 7E+9 +dqbas368 toEng 7E9 -> 7E+9 +dqbas369 toSci 7E8 -> 7E+8 +dqbas370 toEng 7E8 -> 700E+6 +dqbas371 toSci 7E7 -> 7E+7 +dqbas372 toEng 7E7 -> 70E+6 +dqbas373 toSci 7E6 -> 7E+6 +dqbas374 toEng 7E6 -> 7E+6 +dqbas375 toSci 7E5 -> 7E+5 +dqbas376 toEng 7E5 -> 700E+3 +dqbas377 toSci 7E4 -> 7E+4 +dqbas378 toEng 7E4 -> 70E+3 +dqbas379 toSci 7E3 -> 7E+3 +dqbas380 toEng 7E3 -> 7E+3 +dqbas381 toSci 7E2 -> 7E+2 +dqbas382 toEng 7E2 -> 700 +dqbas383 toSci 7E1 -> 7E+1 +dqbas384 toEng 7E1 -> 70 +dqbas385 toSci 7E0 -> 7 +dqbas386 toEng 7E0 -> 7 +dqbas387 toSci 7E-1 -> 0.7 +dqbas388 toEng 7E-1 -> 0.7 +dqbas389 toSci 7E-2 -> 0.07 +dqbas390 toEng 7E-2 -> 0.07 +dqbas391 toSci 7E-3 -> 0.007 +dqbas392 toEng 7E-3 -> 0.007 +dqbas393 toSci 7E-4 -> 0.0007 +dqbas394 toEng 7E-4 -> 0.0007 +dqbas395 toSci 7E-5 -> 0.00007 +dqbas396 toEng 7E-5 -> 0.00007 +dqbas397 toSci 7E-6 -> 0.000007 +dqbas398 toEng 7E-6 -> 0.000007 +dqbas399 toSci 7E-7 -> 7E-7 +dqbas400 toEng 7E-7 -> 700E-9 +dqbas401 toSci 7E-8 -> 7E-8 +dqbas402 toEng 7E-8 -> 70E-9 +dqbas403 toSci 7E-9 -> 7E-9 +dqbas404 toEng 7E-9 -> 7E-9 +dqbas405 toSci 7E-10 -> 7E-10 +dqbas406 toEng 7E-10 -> 700E-12 +dqbas407 toSci 7E-11 -> 7E-11 +dqbas408 toEng 7E-11 -> 70E-12 +dqbas409 toSci 7E-12 -> 7E-12 +dqbas410 toEng 7E-12 -> 7E-12 +dqbas411 toSci 7E-13 -> 7E-13 +dqbas412 toEng 7E-13 -> 700E-15 + +-- Exacts remain exact up to precision .. +dqbas420 toSci 100 -> 100 +dqbas422 toSci 1000 -> 1000 +dqbas424 toSci 999.9 -> 999.9 +dqbas426 toSci 1000.0 -> 1000.0 +dqbas428 toSci 1000.1 -> 1000.1 +dqbas430 toSci 10000 -> 10000 +dqbas432 toSci 1000000000000000000000000000000 -> 1000000000000000000000000000000 +dqbas434 toSci 10000000000000000000000000000000 -> 10000000000000000000000000000000 +dqbas436 toSci 100000000000000000000000000000000 -> 100000000000000000000000000000000 +dqbas438 toSci 1000000000000000000000000000000000 -> 1000000000000000000000000000000000 +dqbas440 toSci 10000000000000000000000000000000000 -> 1.000000000000000000000000000000000E+34 Rounded +dqbas442 toSci 10000000000000000000000000000000000 -> 1.000000000000000000000000000000000E+34 Rounded +dqbas444 toSci 10000000000000000000000000000000003 -> 1.000000000000000000000000000000000E+34 Rounded Inexact +dqbas446 toSci 10000000000000000000000000000000005 -> 1.000000000000000000000000000000000E+34 Rounded Inexact +dqbas448 toSci 100000000000000000000000000000000050 -> 1.000000000000000000000000000000000E+35 Rounded Inexact +dqbas450 toSci 10000000000000000000000000000000009 -> 1.000000000000000000000000000000001E+34 Rounded Inexact +dqbas452 toSci 100000000000000000000000000000000000 -> 1.000000000000000000000000000000000E+35 Rounded +dqbas454 toSci 100000000000000000000000000000000003 -> 1.000000000000000000000000000000000E+35 Rounded Inexact +dqbas456 toSci 100000000000000000000000000000000005 -> 1.000000000000000000000000000000000E+35 Rounded Inexact +dqbas458 toSci 100000000000000000000000000000000009 -> 1.000000000000000000000000000000000E+35 Rounded Inexact +dqbas460 toSci 1000000000000000000000000000000000000 -> 1.000000000000000000000000000000000E+36 Rounded +dqbas462 toSci 1000000000000000000000000000000000300 -> 1.000000000000000000000000000000000E+36 Rounded Inexact +dqbas464 toSci 1000000000000000000000000000000000500 -> 1.000000000000000000000000000000000E+36 Rounded Inexact +dqbas466 toSci 1000000000000000000000000000000000900 -> 1.000000000000000000000000000000001E+36 Rounded Inexact +dqbas468 toSci 10000000000000000000000000000000000000 -> 1.000000000000000000000000000000000E+37 Rounded +dqbas470 toSci 10000000000000000000000000000000003000 -> 1.000000000000000000000000000000000E+37 Rounded Inexact +dqbas472 toSci 10000000000000000000000000000000005000 -> 1.000000000000000000000000000000000E+37 Rounded Inexact +dqbas474 toSci 10000000000000000000000000000000009000 -> 1.000000000000000000000000000000001E+37 Rounded Inexact + +-- check rounding modes heeded +rounding: ceiling +dqbsr401 toSci 1.1111111111111111111111111111123450 -> 1.111111111111111111111111111112345 Rounded +dqbsr402 toSci 1.11111111111111111111111111111234549 -> 1.111111111111111111111111111112346 Rounded Inexact +dqbsr403 toSci 1.11111111111111111111111111111234550 -> 1.111111111111111111111111111112346 Rounded Inexact +dqbsr404 toSci 1.11111111111111111111111111111234551 -> 1.111111111111111111111111111112346 Rounded Inexact +rounding: up +dqbsr405 toSci 1.1111111111111111111111111111123450 -> 1.111111111111111111111111111112345 Rounded +dqbsr406 toSci 1.11111111111111111111111111111234549 -> 1.111111111111111111111111111112346 Rounded Inexact +dqbsr407 toSci 1.11111111111111111111111111111234550 -> 1.111111111111111111111111111112346 Rounded Inexact +dqbsr408 toSci 1.11111111111111111111111111111234551 -> 1.111111111111111111111111111112346 Rounded Inexact +rounding: floor +dqbsr410 toSci 1.1111111111111111111111111111123450 -> 1.111111111111111111111111111112345 Rounded +dqbsr411 toSci 1.11111111111111111111111111111234549 -> 1.111111111111111111111111111112345 Rounded Inexact +dqbsr412 toSci 1.11111111111111111111111111111234550 -> 1.111111111111111111111111111112345 Rounded Inexact +dqbsr413 toSci 1.11111111111111111111111111111234551 -> 1.111111111111111111111111111112345 Rounded Inexact +rounding: half_down +dqbsr415 toSci 1.1111111111111111111111111111123450 -> 1.111111111111111111111111111112345 Rounded +dqbsr416 toSci 1.11111111111111111111111111111234549 -> 1.111111111111111111111111111112345 Rounded Inexact +dqbsr417 toSci 1.11111111111111111111111111111234550 -> 1.111111111111111111111111111112345 Rounded Inexact +dqbsr418 toSci 1.11111111111111111111111111111234650 -> 1.111111111111111111111111111112346 Rounded Inexact +dqbsr419 toSci 1.11111111111111111111111111111234551 -> 1.111111111111111111111111111112346 Rounded Inexact +rounding: half_even +dqbsr421 toSci 1.1111111111111111111111111111123450 -> 1.111111111111111111111111111112345 Rounded +dqbsr422 toSci 1.11111111111111111111111111111234549 -> 1.111111111111111111111111111112345 Rounded Inexact +dqbsr423 toSci 1.11111111111111111111111111111234550 -> 1.111111111111111111111111111112346 Rounded Inexact +dqbsr424 toSci 1.11111111111111111111111111111234650 -> 1.111111111111111111111111111112346 Rounded Inexact +dqbsr425 toSci 1.11111111111111111111111111111234551 -> 1.111111111111111111111111111112346 Rounded Inexact +rounding: down +dqbsr426 toSci 1.1111111111111111111111111111123450 -> 1.111111111111111111111111111112345 Rounded +dqbsr427 toSci 1.11111111111111111111111111111234549 -> 1.111111111111111111111111111112345 Rounded Inexact +dqbsr428 toSci 1.11111111111111111111111111111234550 -> 1.111111111111111111111111111112345 Rounded Inexact +dqbsr429 toSci 1.11111111111111111111111111111234551 -> 1.111111111111111111111111111112345 Rounded Inexact +rounding: half_up +dqbsr431 toSci 1.1111111111111111111111111111123450 -> 1.111111111111111111111111111112345 Rounded +dqbsr432 toSci 1.11111111111111111111111111111234549 -> 1.111111111111111111111111111112345 Rounded Inexact +dqbsr433 toSci 1.11111111111111111111111111111234550 -> 1.111111111111111111111111111112346 Rounded Inexact +dqbsr434 toSci 1.11111111111111111111111111111234650 -> 1.111111111111111111111111111112347 Rounded Inexact +dqbsr435 toSci 1.11111111111111111111111111111234551 -> 1.111111111111111111111111111112346 Rounded Inexact +-- negatives +rounding: ceiling +dqbsr501 toSci -1.1111111111111111111111111111123450 -> -1.111111111111111111111111111112345 Rounded +dqbsr502 toSci -1.11111111111111111111111111111234549 -> -1.111111111111111111111111111112345 Rounded Inexact +dqbsr503 toSci -1.11111111111111111111111111111234550 -> -1.111111111111111111111111111112345 Rounded Inexact +dqbsr504 toSci -1.11111111111111111111111111111234551 -> -1.111111111111111111111111111112345 Rounded Inexact +rounding: up +dqbsr505 toSci -1.1111111111111111111111111111123450 -> -1.111111111111111111111111111112345 Rounded +dqbsr506 toSci -1.11111111111111111111111111111234549 -> -1.111111111111111111111111111112346 Rounded Inexact +dqbsr507 toSci -1.11111111111111111111111111111234550 -> -1.111111111111111111111111111112346 Rounded Inexact +dqbsr508 toSci -1.11111111111111111111111111111234551 -> -1.111111111111111111111111111112346 Rounded Inexact +rounding: floor +dqbsr510 toSci -1.1111111111111111111111111111123450 -> -1.111111111111111111111111111112345 Rounded +dqbsr511 toSci -1.11111111111111111111111111111234549 -> -1.111111111111111111111111111112346 Rounded Inexact +dqbsr512 toSci -1.11111111111111111111111111111234550 -> -1.111111111111111111111111111112346 Rounded Inexact +dqbsr513 toSci -1.11111111111111111111111111111234551 -> -1.111111111111111111111111111112346 Rounded Inexact +rounding: half_down +dqbsr515 toSci -1.1111111111111111111111111111123450 -> -1.111111111111111111111111111112345 Rounded +dqbsr516 toSci -1.11111111111111111111111111111234549 -> -1.111111111111111111111111111112345 Rounded Inexact +dqbsr517 toSci -1.11111111111111111111111111111234550 -> -1.111111111111111111111111111112345 Rounded Inexact +dqbsr518 toSci -1.11111111111111111111111111111234650 -> -1.111111111111111111111111111112346 Rounded Inexact +dqbsr519 toSci -1.11111111111111111111111111111234551 -> -1.111111111111111111111111111112346 Rounded Inexact +rounding: half_even +dqbsr521 toSci -1.1111111111111111111111111111123450 -> -1.111111111111111111111111111112345 Rounded +dqbsr522 toSci -1.11111111111111111111111111111234549 -> -1.111111111111111111111111111112345 Rounded Inexact +dqbsr523 toSci -1.11111111111111111111111111111234550 -> -1.111111111111111111111111111112346 Rounded Inexact +dqbsr524 toSci -1.11111111111111111111111111111234650 -> -1.111111111111111111111111111112346 Rounded Inexact +dqbsr525 toSci -1.11111111111111111111111111111234551 -> -1.111111111111111111111111111112346 Rounded Inexact +rounding: down +dqbsr526 toSci -1.1111111111111111111111111111123450 -> -1.111111111111111111111111111112345 Rounded +dqbsr527 toSci -1.11111111111111111111111111111234549 -> -1.111111111111111111111111111112345 Rounded Inexact +dqbsr528 toSci -1.11111111111111111111111111111234550 -> -1.111111111111111111111111111112345 Rounded Inexact +dqbsr529 toSci -1.11111111111111111111111111111234551 -> -1.111111111111111111111111111112345 Rounded Inexact +rounding: half_up +dqbsr531 toSci -1.1111111111111111111111111111123450 -> -1.111111111111111111111111111112345 Rounded +dqbsr532 toSci -1.11111111111111111111111111111234549 -> -1.111111111111111111111111111112345 Rounded Inexact +dqbsr533 toSci -1.11111111111111111111111111111234550 -> -1.111111111111111111111111111112346 Rounded Inexact +dqbsr534 toSci -1.11111111111111111111111111111234650 -> -1.111111111111111111111111111112347 Rounded Inexact +dqbsr535 toSci -1.11111111111111111111111111111234551 -> -1.111111111111111111111111111112346 Rounded Inexact + +rounding: half_even + +-- The 'baddies' tests from DiagBigDecimal, plus some new ones +dqbas500 toSci '1..2' -> NaN Conversion_syntax +dqbas501 toSci '.' -> NaN Conversion_syntax +dqbas502 toSci '..' -> NaN Conversion_syntax +dqbas503 toSci '++1' -> NaN Conversion_syntax +dqbas504 toSci '--1' -> NaN Conversion_syntax +dqbas505 toSci '-+1' -> NaN Conversion_syntax +dqbas506 toSci '+-1' -> NaN Conversion_syntax +dqbas507 toSci '12e' -> NaN Conversion_syntax +dqbas508 toSci '12e++' -> NaN Conversion_syntax +dqbas509 toSci '12f4' -> NaN Conversion_syntax +dqbas510 toSci ' +1' -> NaN Conversion_syntax +dqbas511 toSci '+ 1' -> NaN Conversion_syntax +dqbas512 toSci '12 ' -> NaN Conversion_syntax +dqbas513 toSci ' + 1' -> NaN Conversion_syntax +dqbas514 toSci ' - 1 ' -> NaN Conversion_syntax +dqbas515 toSci 'x' -> NaN Conversion_syntax +dqbas516 toSci '-1-' -> NaN Conversion_syntax +dqbas517 toSci '12-' -> NaN Conversion_syntax +dqbas518 toSci '3+' -> NaN Conversion_syntax +dqbas519 toSci '' -> NaN Conversion_syntax +dqbas520 toSci '1e-' -> NaN Conversion_syntax +dqbas521 toSci '7e99999a' -> NaN Conversion_syntax +dqbas522 toSci '7e123567890x' -> NaN Conversion_syntax +dqbas523 toSci '7e12356789012x' -> NaN Conversion_syntax +dqbas524 toSci '' -> NaN Conversion_syntax +dqbas525 toSci 'e100' -> NaN Conversion_syntax +dqbas526 toSci '\u0e5a' -> NaN Conversion_syntax +dqbas527 toSci '\u0b65' -> NaN Conversion_syntax +dqbas528 toSci '123,65' -> NaN Conversion_syntax +dqbas529 toSci '1.34.5' -> NaN Conversion_syntax +dqbas530 toSci '.123.5' -> NaN Conversion_syntax +dqbas531 toSci '01.35.' -> NaN Conversion_syntax +dqbas532 toSci '01.35-' -> NaN Conversion_syntax +dqbas533 toSci '0000..' -> NaN Conversion_syntax +dqbas534 toSci '.0000.' -> NaN Conversion_syntax +dqbas535 toSci '00..00' -> NaN Conversion_syntax +dqbas536 toSci '111e*123' -> NaN Conversion_syntax +dqbas537 toSci '111e123-' -> NaN Conversion_syntax +dqbas538 toSci '111e+12+' -> NaN Conversion_syntax +dqbas539 toSci '111e1-3-' -> NaN Conversion_syntax +dqbas540 toSci '111e1*23' -> NaN Conversion_syntax +dqbas541 toSci '111e1e+3' -> NaN Conversion_syntax +dqbas542 toSci '1e1.0' -> NaN Conversion_syntax +dqbas543 toSci '1e123e' -> NaN Conversion_syntax +dqbas544 toSci 'ten' -> NaN Conversion_syntax +dqbas545 toSci 'ONE' -> NaN Conversion_syntax +dqbas546 toSci '1e.1' -> NaN Conversion_syntax +dqbas547 toSci '1e1.' -> NaN Conversion_syntax +dqbas548 toSci '1ee' -> NaN Conversion_syntax +dqbas549 toSci 'e+1' -> NaN Conversion_syntax +dqbas550 toSci '1.23.4' -> NaN Conversion_syntax +dqbas551 toSci '1.2.1' -> NaN Conversion_syntax +dqbas552 toSci '1E+1.2' -> NaN Conversion_syntax +dqbas553 toSci '1E+1.2.3' -> NaN Conversion_syntax +dqbas554 toSci '1E++1' -> NaN Conversion_syntax +dqbas555 toSci '1E--1' -> NaN Conversion_syntax +dqbas556 toSci '1E+-1' -> NaN Conversion_syntax +dqbas557 toSci '1E-+1' -> NaN Conversion_syntax +dqbas558 toSci '1E''1' -> NaN Conversion_syntax +dqbas559 toSci "1E""1" -> NaN Conversion_syntax +dqbas560 toSci "1E""""" -> NaN Conversion_syntax +-- Near-specials +dqbas561 toSci "qNaN" -> NaN Conversion_syntax +dqbas562 toSci "NaNq" -> NaN Conversion_syntax +dqbas563 toSci "NaNs" -> NaN Conversion_syntax +dqbas564 toSci "Infi" -> NaN Conversion_syntax +dqbas565 toSci "Infin" -> NaN Conversion_syntax +dqbas566 toSci "Infini" -> NaN Conversion_syntax +dqbas567 toSci "Infinit" -> NaN Conversion_syntax +dqbas568 toSci "-Infinit" -> NaN Conversion_syntax +dqbas569 toSci "0Inf" -> NaN Conversion_syntax +dqbas570 toSci "9Inf" -> NaN Conversion_syntax +dqbas571 toSci "-0Inf" -> NaN Conversion_syntax +dqbas572 toSci "-9Inf" -> NaN Conversion_syntax +dqbas573 toSci "-sNa" -> NaN Conversion_syntax +dqbas574 toSci "xNaN" -> NaN Conversion_syntax +dqbas575 toSci "0sNaN" -> NaN Conversion_syntax + +-- some baddies with dots and Es and dots and specials +dqbas576 toSci 'e+1' -> NaN Conversion_syntax +dqbas577 toSci '.e+1' -> NaN Conversion_syntax +dqbas578 toSci '+.e+1' -> NaN Conversion_syntax +dqbas579 toSci '-.e+' -> NaN Conversion_syntax +dqbas580 toSci '-.e' -> NaN Conversion_syntax +dqbas581 toSci 'E+1' -> NaN Conversion_syntax +dqbas582 toSci '.E+1' -> NaN Conversion_syntax +dqbas583 toSci '+.E+1' -> NaN Conversion_syntax +dqbas584 toSci '-.E+' -> NaN Conversion_syntax +dqbas585 toSci '-.E' -> NaN Conversion_syntax + +dqbas586 toSci '.NaN' -> NaN Conversion_syntax +dqbas587 toSci '-.NaN' -> NaN Conversion_syntax +dqbas588 toSci '+.sNaN' -> NaN Conversion_syntax +dqbas589 toSci '+.Inf' -> NaN Conversion_syntax +dqbas590 toSci '.Infinity' -> NaN Conversion_syntax + +-- Zeros +dqbas601 toSci 0.000000000 -> 0E-9 +dqbas602 toSci 0.00000000 -> 0E-8 +dqbas603 toSci 0.0000000 -> 0E-7 +dqbas604 toSci 0.000000 -> 0.000000 +dqbas605 toSci 0.00000 -> 0.00000 +dqbas606 toSci 0.0000 -> 0.0000 +dqbas607 toSci 0.000 -> 0.000 +dqbas608 toSci 0.00 -> 0.00 +dqbas609 toSci 0.0 -> 0.0 +dqbas610 toSci .0 -> 0.0 +dqbas611 toSci 0. -> 0 +dqbas612 toSci -.0 -> -0.0 +dqbas613 toSci -0. -> -0 +dqbas614 toSci -0.0 -> -0.0 +dqbas615 toSci -0.00 -> -0.00 +dqbas616 toSci -0.000 -> -0.000 +dqbas617 toSci -0.0000 -> -0.0000 +dqbas618 toSci -0.00000 -> -0.00000 +dqbas619 toSci -0.000000 -> -0.000000 +dqbas620 toSci -0.0000000 -> -0E-7 +dqbas621 toSci -0.00000000 -> -0E-8 +dqbas622 toSci -0.000000000 -> -0E-9 + +dqbas630 toSci 0.00E+0 -> 0.00 +dqbas631 toSci 0.00E+1 -> 0.0 +dqbas632 toSci 0.00E+2 -> 0 +dqbas633 toSci 0.00E+3 -> 0E+1 +dqbas634 toSci 0.00E+4 -> 0E+2 +dqbas635 toSci 0.00E+5 -> 0E+3 +dqbas636 toSci 0.00E+6 -> 0E+4 +dqbas637 toSci 0.00E+7 -> 0E+5 +dqbas638 toSci 0.00E+8 -> 0E+6 +dqbas639 toSci 0.00E+9 -> 0E+7 + +dqbas640 toSci 0.0E+0 -> 0.0 +dqbas641 toSci 0.0E+1 -> 0 +dqbas642 toSci 0.0E+2 -> 0E+1 +dqbas643 toSci 0.0E+3 -> 0E+2 +dqbas644 toSci 0.0E+4 -> 0E+3 +dqbas645 toSci 0.0E+5 -> 0E+4 +dqbas646 toSci 0.0E+6 -> 0E+5 +dqbas647 toSci 0.0E+7 -> 0E+6 +dqbas648 toSci 0.0E+8 -> 0E+7 +dqbas649 toSci 0.0E+9 -> 0E+8 + +dqbas650 toSci 0E+0 -> 0 +dqbas651 toSci 0E+1 -> 0E+1 +dqbas652 toSci 0E+2 -> 0E+2 +dqbas653 toSci 0E+3 -> 0E+3 +dqbas654 toSci 0E+4 -> 0E+4 +dqbas655 toSci 0E+5 -> 0E+5 +dqbas656 toSci 0E+6 -> 0E+6 +dqbas657 toSci 0E+7 -> 0E+7 +dqbas658 toSci 0E+8 -> 0E+8 +dqbas659 toSci 0E+9 -> 0E+9 + +dqbas660 toSci 0.0E-0 -> 0.0 +dqbas661 toSci 0.0E-1 -> 0.00 +dqbas662 toSci 0.0E-2 -> 0.000 +dqbas663 toSci 0.0E-3 -> 0.0000 +dqbas664 toSci 0.0E-4 -> 0.00000 +dqbas665 toSci 0.0E-5 -> 0.000000 +dqbas666 toSci 0.0E-6 -> 0E-7 +dqbas667 toSci 0.0E-7 -> 0E-8 +dqbas668 toSci 0.0E-8 -> 0E-9 +dqbas669 toSci 0.0E-9 -> 0E-10 + +dqbas670 toSci 0.00E-0 -> 0.00 +dqbas671 toSci 0.00E-1 -> 0.000 +dqbas672 toSci 0.00E-2 -> 0.0000 +dqbas673 toSci 0.00E-3 -> 0.00000 +dqbas674 toSci 0.00E-4 -> 0.000000 +dqbas675 toSci 0.00E-5 -> 0E-7 +dqbas676 toSci 0.00E-6 -> 0E-8 +dqbas677 toSci 0.00E-7 -> 0E-9 +dqbas678 toSci 0.00E-8 -> 0E-10 +dqbas679 toSci 0.00E-9 -> 0E-11 + +dqbas680 toSci 000000. -> 0 +dqbas681 toSci 00000. -> 0 +dqbas682 toSci 0000. -> 0 +dqbas683 toSci 000. -> 0 +dqbas684 toSci 00. -> 0 +dqbas685 toSci 0. -> 0 +dqbas686 toSci +00000. -> 0 +dqbas687 toSci -00000. -> -0 +dqbas688 toSci +0. -> 0 +dqbas689 toSci -0. -> -0 + +-- Specials +dqbas700 toSci "NaN" -> NaN +dqbas701 toSci "nan" -> NaN +dqbas702 toSci "nAn" -> NaN +dqbas703 toSci "NAN" -> NaN +dqbas704 toSci "+NaN" -> NaN +dqbas705 toSci "+nan" -> NaN +dqbas706 toSci "+nAn" -> NaN +dqbas707 toSci "+NAN" -> NaN +dqbas708 toSci "-NaN" -> -NaN +dqbas709 toSci "-nan" -> -NaN +dqbas710 toSci "-nAn" -> -NaN +dqbas711 toSci "-NAN" -> -NaN +dqbas712 toSci 'NaN0' -> NaN +dqbas713 toSci 'NaN1' -> NaN1 +dqbas714 toSci 'NaN12' -> NaN12 +dqbas715 toSci 'NaN123' -> NaN123 +dqbas716 toSci 'NaN1234' -> NaN1234 +dqbas717 toSci 'NaN01' -> NaN1 +dqbas718 toSci 'NaN012' -> NaN12 +dqbas719 toSci 'NaN0123' -> NaN123 +dqbas720 toSci 'NaN01234' -> NaN1234 +dqbas721 toSci 'NaN001' -> NaN1 +dqbas722 toSci 'NaN0012' -> NaN12 +dqbas723 toSci 'NaN00123' -> NaN123 +dqbas724 toSci 'NaN001234' -> NaN1234 +dqbas725 toSci 'NaN1234567890123456781234567890123456' -> NaN Conversion_syntax +dqbas726 toSci 'NaN123e+1' -> NaN Conversion_syntax +dqbas727 toSci 'NaN12.45' -> NaN Conversion_syntax +dqbas728 toSci 'NaN-12' -> NaN Conversion_syntax +dqbas729 toSci 'NaN+12' -> NaN Conversion_syntax + +dqbas730 toSci "sNaN" -> sNaN +dqbas731 toSci "snan" -> sNaN +dqbas732 toSci "SnAn" -> sNaN +dqbas733 toSci "SNAN" -> sNaN +dqbas734 toSci "+sNaN" -> sNaN +dqbas735 toSci "+snan" -> sNaN +dqbas736 toSci "+SnAn" -> sNaN +dqbas737 toSci "+SNAN" -> sNaN +dqbas738 toSci "-sNaN" -> -sNaN +dqbas739 toSci "-snan" -> -sNaN +dqbas740 toSci "-SnAn" -> -sNaN +dqbas741 toSci "-SNAN" -> -sNaN +dqbas742 toSci 'sNaN0000' -> sNaN +dqbas743 toSci 'sNaN7' -> sNaN7 +dqbas744 toSci 'sNaN007234' -> sNaN7234 +dqbas745 toSci 'sNaN1234567890123456787234561234567890' -> NaN Conversion_syntax +dqbas746 toSci 'sNaN72.45' -> NaN Conversion_syntax +dqbas747 toSci 'sNaN-72' -> NaN Conversion_syntax + +dqbas748 toSci "Inf" -> Infinity +dqbas749 toSci "inf" -> Infinity +dqbas750 toSci "iNf" -> Infinity +dqbas751 toSci "INF" -> Infinity +dqbas752 toSci "+Inf" -> Infinity +dqbas753 toSci "+inf" -> Infinity +dqbas754 toSci "+iNf" -> Infinity +dqbas755 toSci "+INF" -> Infinity +dqbas756 toSci "-Inf" -> -Infinity +dqbas757 toSci "-inf" -> -Infinity +dqbas758 toSci "-iNf" -> -Infinity +dqbas759 toSci "-INF" -> -Infinity + +dqbas760 toSci "Infinity" -> Infinity +dqbas761 toSci "infinity" -> Infinity +dqbas762 toSci "iNfInItY" -> Infinity +dqbas763 toSci "INFINITY" -> Infinity +dqbas764 toSci "+Infinity" -> Infinity +dqbas765 toSci "+infinity" -> Infinity +dqbas766 toSci "+iNfInItY" -> Infinity +dqbas767 toSci "+INFINITY" -> Infinity +dqbas768 toSci "-Infinity" -> -Infinity +dqbas769 toSci "-infinity" -> -Infinity +dqbas770 toSci "-iNfInItY" -> -Infinity +dqbas771 toSci "-INFINITY" -> -Infinity + +-- Specials and zeros for toEng +dqbast772 toEng "NaN" -> NaN +dqbast773 toEng "-Infinity" -> -Infinity +dqbast774 toEng "-sNaN" -> -sNaN +dqbast775 toEng "-NaN" -> -NaN +dqbast776 toEng "+Infinity" -> Infinity +dqbast778 toEng "+sNaN" -> sNaN +dqbast779 toEng "+NaN" -> NaN +dqbast780 toEng "INFINITY" -> Infinity +dqbast781 toEng "SNAN" -> sNaN +dqbast782 toEng "NAN" -> NaN +dqbast783 toEng "infinity" -> Infinity +dqbast784 toEng "snan" -> sNaN +dqbast785 toEng "nan" -> NaN +dqbast786 toEng "InFINITY" -> Infinity +dqbast787 toEng "SnAN" -> sNaN +dqbast788 toEng "nAN" -> NaN +dqbast789 toEng "iNfinity" -> Infinity +dqbast790 toEng "sNan" -> sNaN +dqbast791 toEng "Nan" -> NaN +dqbast792 toEng "Infinity" -> Infinity +dqbast793 toEng "sNaN" -> sNaN + +-- Zero toEng, etc. +dqbast800 toEng 0e+1 -> "0.00E+3" -- doc example + +dqbast801 toEng 0.000000000 -> 0E-9 +dqbast802 toEng 0.00000000 -> 0.00E-6 +dqbast803 toEng 0.0000000 -> 0.0E-6 +dqbast804 toEng 0.000000 -> 0.000000 +dqbast805 toEng 0.00000 -> 0.00000 +dqbast806 toEng 0.0000 -> 0.0000 +dqbast807 toEng 0.000 -> 0.000 +dqbast808 toEng 0.00 -> 0.00 +dqbast809 toEng 0.0 -> 0.0 +dqbast810 toEng .0 -> 0.0 +dqbast811 toEng 0. -> 0 +dqbast812 toEng -.0 -> -0.0 +dqbast813 toEng -0. -> -0 +dqbast814 toEng -0.0 -> -0.0 +dqbast815 toEng -0.00 -> -0.00 +dqbast816 toEng -0.000 -> -0.000 +dqbast817 toEng -0.0000 -> -0.0000 +dqbast818 toEng -0.00000 -> -0.00000 +dqbast819 toEng -0.000000 -> -0.000000 +dqbast820 toEng -0.0000000 -> -0.0E-6 +dqbast821 toEng -0.00000000 -> -0.00E-6 +dqbast822 toEng -0.000000000 -> -0E-9 + +dqbast830 toEng 0.00E+0 -> 0.00 +dqbast831 toEng 0.00E+1 -> 0.0 +dqbast832 toEng 0.00E+2 -> 0 +dqbast833 toEng 0.00E+3 -> 0.00E+3 +dqbast834 toEng 0.00E+4 -> 0.0E+3 +dqbast835 toEng 0.00E+5 -> 0E+3 +dqbast836 toEng 0.00E+6 -> 0.00E+6 +dqbast837 toEng 0.00E+7 -> 0.0E+6 +dqbast838 toEng 0.00E+8 -> 0E+6 +dqbast839 toEng 0.00E+9 -> 0.00E+9 + +dqbast840 toEng 0.0E+0 -> 0.0 +dqbast841 toEng 0.0E+1 -> 0 +dqbast842 toEng 0.0E+2 -> 0.00E+3 +dqbast843 toEng 0.0E+3 -> 0.0E+3 +dqbast844 toEng 0.0E+4 -> 0E+3 +dqbast845 toEng 0.0E+5 -> 0.00E+6 +dqbast846 toEng 0.0E+6 -> 0.0E+6 +dqbast847 toEng 0.0E+7 -> 0E+6 +dqbast848 toEng 0.0E+8 -> 0.00E+9 +dqbast849 toEng 0.0E+9 -> 0.0E+9 + +dqbast850 toEng 0E+0 -> 0 +dqbast851 toEng 0E+1 -> 0.00E+3 +dqbast852 toEng 0E+2 -> 0.0E+3 +dqbast853 toEng 0E+3 -> 0E+3 +dqbast854 toEng 0E+4 -> 0.00E+6 +dqbast855 toEng 0E+5 -> 0.0E+6 +dqbast856 toEng 0E+6 -> 0E+6 +dqbast857 toEng 0E+7 -> 0.00E+9 +dqbast858 toEng 0E+8 -> 0.0E+9 +dqbast859 toEng 0E+9 -> 0E+9 + +dqbast860 toEng 0.0E-0 -> 0.0 +dqbast861 toEng 0.0E-1 -> 0.00 +dqbast862 toEng 0.0E-2 -> 0.000 +dqbast863 toEng 0.0E-3 -> 0.0000 +dqbast864 toEng 0.0E-4 -> 0.00000 +dqbast865 toEng 0.0E-5 -> 0.000000 +dqbast866 toEng 0.0E-6 -> 0.0E-6 +dqbast867 toEng 0.0E-7 -> 0.00E-6 +dqbast868 toEng 0.0E-8 -> 0E-9 +dqbast869 toEng 0.0E-9 -> 0.0E-9 + +dqbast870 toEng 0.00E-0 -> 0.00 +dqbast871 toEng 0.00E-1 -> 0.000 +dqbast872 toEng 0.00E-2 -> 0.0000 +dqbast873 toEng 0.00E-3 -> 0.00000 +dqbast874 toEng 0.00E-4 -> 0.000000 +dqbast875 toEng 0.00E-5 -> 0.0E-6 +dqbast876 toEng 0.00E-6 -> 0.00E-6 +dqbast877 toEng 0.00E-7 -> 0E-9 +dqbast878 toEng 0.00E-8 -> 0.0E-9 +dqbast879 toEng 0.00E-9 -> 0.00E-9 + +-- long input strings +dqbas801 tosci '01234567890123456' -> 1234567890123456 +dqbas802 tosci '001234567890123456' -> 1234567890123456 +dqbas803 tosci '0001234567890123456' -> 1234567890123456 +dqbas804 tosci '00001234567890123456' -> 1234567890123456 +dqbas805 tosci '000001234567890123456' -> 1234567890123456 +dqbas806 tosci '0000001234567890123456' -> 1234567890123456 +dqbas807 tosci '00000001234567890123456' -> 1234567890123456 +dqbas808 tosci '000000001234567890123456' -> 1234567890123456 +dqbas809 tosci '0000000001234567890123456' -> 1234567890123456 +dqbas810 tosci '00000000001234567890123456' -> 1234567890123456 + +dqbas811 tosci '0.1234567890123456' -> 0.1234567890123456 +dqbas812 tosci '0.01234567890123456' -> 0.01234567890123456 +dqbas813 tosci '0.001234567890123456' -> 0.001234567890123456 +dqbas814 tosci '0.0001234567890123456' -> 0.0001234567890123456 +dqbas815 tosci '0.00001234567890123456' -> 0.00001234567890123456 +dqbas816 tosci '0.000001234567890123456' -> 0.000001234567890123456 +dqbas817 tosci '0.0000001234567890123456' -> 1.234567890123456E-7 +dqbas818 tosci '0.00000001234567890123456' -> 1.234567890123456E-8 +dqbas819 tosci '0.000000001234567890123456' -> 1.234567890123456E-9 +dqbas820 tosci '0.0000000001234567890123456' -> 1.234567890123456E-10 + +dqbas821 tosci '12345678912345678901234567801234567890' -> 1.234567891234567890123456780123457E+37 Inexact Rounded +dqbas822 tosci '123456789123456789012345678012345678901' -> 1.234567891234567890123456780123457E+38 Inexact Rounded +dqbas823 tosci '1234567891234567890123456780123456789012' -> 1.234567891234567890123456780123457E+39 Inexact Rounded +dqbas824 tosci '12345678912345678901234567801234567890123' -> 1.234567891234567890123456780123457E+40 Inexact Rounded +dqbas825 tosci '123456789123456789012345678012345678901234' -> 1.234567891234567890123456780123457E+41 Inexact Rounded +dqbas826 tosci '1234567891234567890123456780123456789012345' -> 1.234567891234567890123456780123457E+42 Inexact Rounded +dqbas827 tosci '12345678912345678901234567801234567890123456' -> 1.234567891234567890123456780123457E+43 Inexact Rounded +dqbas828 tosci '123456789123456789012345678012345678901234567' -> 1.234567891234567890123456780123457E+44 Inexact Rounded +dqbas829 tosci '1234567891234567890123456780123456789012345678' -> 1.234567891234567890123456780123457E+45 Inexact Rounded + +-- subnormals and overflows +dqbas906 toSci '99e999999999' -> Infinity Overflow Inexact Rounded +dqbas907 toSci '999e999999999' -> Infinity Overflow Inexact Rounded +dqbas908 toSci '0.9e-999999999' -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqbas909 toSci '0.09e-999999999' -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqbas910 toSci '0.1e1000000000' -> Infinity Overflow Inexact Rounded +dqbas911 toSci '10e-1000000000' -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqbas912 toSci '0.9e9999999999' -> Infinity Overflow Inexact Rounded +dqbas913 toSci '99e-9999999999' -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqbas914 toSci '111e9999999999' -> Infinity Overflow Inexact Rounded +dqbas915 toSci '1111e-9999999999' -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqbas916 toSci '1111e-99999999999' -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqbas917 toSci '7e1000000000' -> Infinity Overflow Inexact Rounded +-- negatives the same +dqbas918 toSci '-99e999999999' -> -Infinity Overflow Inexact Rounded +dqbas919 toSci '-999e999999999' -> -Infinity Overflow Inexact Rounded +dqbas920 toSci '-0.9e-999999999' -> -0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqbas921 toSci '-0.09e-999999999' -> -0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqbas922 toSci '-0.1e1000000000' -> -Infinity Overflow Inexact Rounded +dqbas923 toSci '-10e-1000000000' -> -0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqbas924 toSci '-0.9e9999999999' -> -Infinity Overflow Inexact Rounded +dqbas925 toSci '-99e-9999999999' -> -0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqbas926 toSci '-111e9999999999' -> -Infinity Overflow Inexact Rounded +dqbas927 toSci '-1111e-9999999999' -> -0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqbas928 toSci '-1111e-99999999999' -> -0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqbas929 toSci '-7e1000000000' -> -Infinity Overflow Inexact Rounded + +-- overflow results at different rounding modes +rounding: ceiling +dqbas930 toSci '7e10000' -> Infinity Overflow Inexact Rounded +dqbas931 toSci '-7e10000' -> -9.999999999999999999999999999999999E+6144 Overflow Inexact Rounded +rounding: up +dqbas932 toSci '7e10000' -> Infinity Overflow Inexact Rounded +dqbas933 toSci '-7e10000' -> -Infinity Overflow Inexact Rounded +rounding: down +dqbas934 toSci '7e10000' -> 9.999999999999999999999999999999999E+6144 Overflow Inexact Rounded +dqbas935 toSci '-7e10000' -> -9.999999999999999999999999999999999E+6144 Overflow Inexact Rounded +rounding: floor +dqbas936 toSci '7e10000' -> 9.999999999999999999999999999999999E+6144 Overflow Inexact Rounded +dqbas937 toSci '-7e10000' -> -Infinity Overflow Inexact Rounded + +rounding: half_up +dqbas938 toSci '7e10000' -> Infinity Overflow Inexact Rounded +dqbas939 toSci '-7e10000' -> -Infinity Overflow Inexact Rounded +rounding: half_even +dqbas940 toSci '7e10000' -> Infinity Overflow Inexact Rounded +dqbas941 toSci '-7e10000' -> -Infinity Overflow Inexact Rounded +rounding: half_down +dqbas942 toSci '7e10000' -> Infinity Overflow Inexact Rounded +dqbas943 toSci '-7e10000' -> -Infinity Overflow Inexact Rounded + +rounding: half_even + +-- Now check 854/754r some subnormals and underflow to 0 +dqbem400 toSci 1.0000E-383 -> 1.0000E-383 +dqbem401 toSci 0.1E-6172 -> 1E-6173 Subnormal +dqbem402 toSci 0.1000E-6172 -> 1.000E-6173 Subnormal +dqbem403 toSci 0.0100E-6172 -> 1.00E-6174 Subnormal +dqbem404 toSci 0.0010E-6172 -> 1.0E-6175 Subnormal +dqbem405 toSci 0.0001E-6172 -> 1E-6176 Subnormal +dqbem406 toSci 0.00010E-6172 -> 1E-6176 Subnormal Rounded +dqbem407 toSci 0.00013E-6172 -> 1E-6176 Underflow Subnormal Inexact Rounded +dqbem408 toSci 0.00015E-6172 -> 2E-6176 Underflow Subnormal Inexact Rounded +dqbem409 toSci 0.00017E-6172 -> 2E-6176 Underflow Subnormal Inexact Rounded +dqbem410 toSci 0.00023E-6172 -> 2E-6176 Underflow Subnormal Inexact Rounded +dqbem411 toSci 0.00025E-6172 -> 2E-6176 Underflow Subnormal Inexact Rounded +dqbem412 toSci 0.00027E-6172 -> 3E-6176 Underflow Subnormal Inexact Rounded +dqbem413 toSci 0.000149E-6172 -> 1E-6176 Underflow Subnormal Inexact Rounded +dqbem414 toSci 0.000150E-6172 -> 2E-6176 Underflow Subnormal Inexact Rounded +dqbem415 toSci 0.000151E-6172 -> 2E-6176 Underflow Subnormal Inexact Rounded +dqbem416 toSci 0.000249E-6172 -> 2E-6176 Underflow Subnormal Inexact Rounded +dqbem417 toSci 0.000250E-6172 -> 2E-6176 Underflow Subnormal Inexact Rounded +dqbem418 toSci 0.000251E-6172 -> 3E-6176 Underflow Subnormal Inexact Rounded +dqbem419 toSci 0.00009E-6172 -> 1E-6176 Underflow Subnormal Inexact Rounded +dqbem420 toSci 0.00005E-6172 -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqbem421 toSci 0.00003E-6172 -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqbem422 toSci 0.000009E-6172 -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqbem423 toSci 0.000005E-6172 -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqbem424 toSci 0.000003E-6172 -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped + +dqbem425 toSci 0.001049E-6172 -> 1.0E-6175 Underflow Subnormal Inexact Rounded +dqbem426 toSci 0.001050E-6172 -> 1.0E-6175 Underflow Subnormal Inexact Rounded +dqbem427 toSci 0.001051E-6172 -> 1.1E-6175 Underflow Subnormal Inexact Rounded +dqbem428 toSci 0.001149E-6172 -> 1.1E-6175 Underflow Subnormal Inexact Rounded +dqbem429 toSci 0.001150E-6172 -> 1.2E-6175 Underflow Subnormal Inexact Rounded +dqbem430 toSci 0.001151E-6172 -> 1.2E-6175 Underflow Subnormal Inexact Rounded + +dqbem432 toSci 0.010049E-6172 -> 1.00E-6174 Underflow Subnormal Inexact Rounded +dqbem433 toSci 0.010050E-6172 -> 1.00E-6174 Underflow Subnormal Inexact Rounded +dqbem434 toSci 0.010051E-6172 -> 1.01E-6174 Underflow Subnormal Inexact Rounded +dqbem435 toSci 0.010149E-6172 -> 1.01E-6174 Underflow Subnormal Inexact Rounded +dqbem436 toSci 0.010150E-6172 -> 1.02E-6174 Underflow Subnormal Inexact Rounded +dqbem437 toSci 0.010151E-6172 -> 1.02E-6174 Underflow Subnormal Inexact Rounded + +dqbem440 toSci 0.10103E-6172 -> 1.010E-6173 Underflow Subnormal Inexact Rounded +dqbem441 toSci 0.10105E-6172 -> 1.010E-6173 Underflow Subnormal Inexact Rounded +dqbem442 toSci 0.10107E-6172 -> 1.011E-6173 Underflow Subnormal Inexact Rounded +dqbem443 toSci 0.10113E-6172 -> 1.011E-6173 Underflow Subnormal Inexact Rounded +dqbem444 toSci 0.10115E-6172 -> 1.012E-6173 Underflow Subnormal Inexact Rounded +dqbem445 toSci 0.10117E-6172 -> 1.012E-6173 Underflow Subnormal Inexact Rounded + +dqbem450 toSci 1.10730E-6173 -> 1.107E-6173 Underflow Subnormal Inexact Rounded +dqbem451 toSci 1.10750E-6173 -> 1.108E-6173 Underflow Subnormal Inexact Rounded +dqbem452 toSci 1.10770E-6173 -> 1.108E-6173 Underflow Subnormal Inexact Rounded +dqbem453 toSci 1.10830E-6173 -> 1.108E-6173 Underflow Subnormal Inexact Rounded +dqbem454 toSci 1.10850E-6173 -> 1.108E-6173 Underflow Subnormal Inexact Rounded +dqbem455 toSci 1.10870E-6173 -> 1.109E-6173 Underflow Subnormal Inexact Rounded + +-- make sure sign OK +dqbem456 toSci -0.10103E-6172 -> -1.010E-6173 Underflow Subnormal Inexact Rounded +dqbem457 toSci -0.10105E-6172 -> -1.010E-6173 Underflow Subnormal Inexact Rounded +dqbem458 toSci -0.10107E-6172 -> -1.011E-6173 Underflow Subnormal Inexact Rounded +dqbem459 toSci -0.10113E-6172 -> -1.011E-6173 Underflow Subnormal Inexact Rounded +dqbem460 toSci -0.10115E-6172 -> -1.012E-6173 Underflow Subnormal Inexact Rounded +dqbem461 toSci -0.10117E-6172 -> -1.012E-6173 Underflow Subnormal Inexact Rounded + +-- '999s' cases +dqbem464 toSci 999999E-6173 -> 9.99999E-6168 Subnormal +dqbem465 toSci 99999.0E-6172 -> 9.99990E-6168 Subnormal +dqbem466 toSci 99999.E-6172 -> 9.9999E-6168 Subnormal +dqbem467 toSci 9999.9E-6172 -> 9.9999E-6169 Subnormal +dqbem468 toSci 999.99E-6172 -> 9.9999E-6170 Subnormal +dqbem469 toSci 99.999E-6172 -> 9.9999E-6171 Subnormal +dqbem470 toSci 9.9999E-6172 -> 9.9999E-6172 Subnormal +dqbem471 toSci 0.99999E-6172 -> 1.0000E-6172 Underflow Subnormal Inexact Rounded +dqbem472 toSci 0.099999E-6172 -> 1.000E-6173 Underflow Subnormal Inexact Rounded +dqbem473 toSci 0.0099999E-6172 -> 1.00E-6174 Underflow Subnormal Inexact Rounded +dqbem474 toSci 0.00099999E-6172 -> 1.0E-6175 Underflow Subnormal Inexact Rounded +dqbem475 toSci 0.000099999E-6172 -> 1E-6176 Underflow Subnormal Inexact Rounded +dqbem476 toSci 0.0000099999E-6172 -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqbem477 toSci 0.00000099999E-6172 -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqbem478 toSci 0.000000099999E-6172 -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped + +-- Exponents with insignificant leading zeros +dqbas1001 toSci 1e999999999 -> Infinity Overflow Inexact Rounded +dqbas1002 toSci 1e0999999999 -> Infinity Overflow Inexact Rounded +dqbas1003 toSci 1e00999999999 -> Infinity Overflow Inexact Rounded +dqbas1004 toSci 1e000999999999 -> Infinity Overflow Inexact Rounded +dqbas1005 toSci 1e000000000000999999999 -> Infinity Overflow Inexact Rounded +dqbas1006 toSci 1e000000000001000000007 -> Infinity Overflow Inexact Rounded +dqbas1007 toSci 1e-999999999 -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqbas1008 toSci 1e-0999999999 -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqbas1009 toSci 1e-00999999999 -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqbas1010 toSci 1e-000999999999 -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqbas1011 toSci 1e-000000000000999999999 -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqbas1012 toSci 1e-000000000001000000007 -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped + +-- check for double-rounded subnormals +dqbas1041 toSci 1.1111111111111111111111111111152444E-6144 -> 1.11111111111111111111111111111524E-6144 Inexact Rounded Subnormal Underflow +dqbas1042 toSci 1.1111111111111111111111111111152445E-6144 -> 1.11111111111111111111111111111524E-6144 Inexact Rounded Subnormal Underflow +dqbas1043 toSci 1.1111111111111111111111111111152446E-6144 -> 1.11111111111111111111111111111524E-6144 Inexact Rounded Subnormal Underflow + +-- clamped zeros [see also clamp.decTest] +dqbas1075 toSci 0e+10000 -> 0E+6111 Clamped +dqbas1076 toSci 0e-10000 -> 0E-6176 Clamped +dqbas1077 toSci -0e+10000 -> -0E+6111 Clamped +dqbas1078 toSci -0e-10000 -> -0E-6176 Clamped + +-- extreme values from next-wider +dqbas1101 toSci -9.9999999999999999999999999999999999999999999999999999999999999999999E+1572864 -> -Infinity Overflow Inexact Rounded +dqbas1102 toSci -1E-1572863 -> -0E-6176 Inexact Rounded Subnormal Underflow Clamped +dqbas1103 toSci -1E-1572932 -> -0E-6176 Inexact Rounded Subnormal Underflow Clamped +dqbas1104 toSci -0 -> -0 +dqbas1105 toSci +0 -> 0 +dqbas1106 toSci +1E-1572932 -> 0E-6176 Inexact Rounded Subnormal Underflow Clamped +dqbas1107 toSci +1E-1572863 -> 0E-6176 Inexact Rounded Subnormal Underflow Clamped +dqbas1108 toSci +9.9999999999999999999999999999999999999999999999999999999999999999999E+1572864 -> Infinity Overflow Inexact Rounded + Added: python/branches/release25-maint/Lib/test/decimaltestdata/dqCanonical.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/dqCanonical.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,372 @@ +------------------------------------------------------------------------ +-- dqCanonical.decTest -- test decQuad canonical results -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- This file tests that copy operations leave uncanonical operands +-- unchanged, and vice versa + +-- All operands and results are decQuads. +extended: 1 +clamp: 1 +precision: 34 +maxExponent: 6144 +minExponent: -6143 +rounding: half_even + +-- Uncanonical declets are: abc, where: +-- a=1,2,3 +-- b=6,7,e,f +-- c=e,f + +-- assert some standard (canonical) values; this tests that FromString +-- produces canonical results (many more in decimalNN) +dqcan001 apply 9.999999999999999999999999999999999E+6144 -> #77ffcff3fcff3fcff3fcff3fcff3fcff +dqcan002 apply 0 -> #22080000000000000000000000000000 +dqcan003 apply 1 -> #22080000000000000000000000000001 +dqcan004 apply -1 -> #a2080000000000000000000000000001 +dqcan005 apply Infinity -> #78000000000000000000000000000000 +dqcan006 apply -Infinity -> #f8000000000000000000000000000000 +dqcan007 apply -NaN -> #fc000000000000000000000000000000 +dqcan008 apply -sNaN -> #fe000000000000000000000000000000 +dqcan009 apply NaN999999999999999999999999999999999 -> #7c000ff3fcff3fcff3fcff3fcff3fcff +dqcan010 apply sNaN999999999999999999999999999999999 -> #7e000ff3fcff3fcff3fcff3fcff3fcff +decan011 apply 9999999999999999999999999999999999 -> #6e080ff3fcff3fcff3fcff3fcff3fcff +dqcan012 apply 7.50 -> #220780000000000000000000000003d0 +dqcan013 apply 9.99 -> #220780000000000000000000000000ff + +-- Base tests for canonical encodings (individual operator +-- propagation is tested later) + +-- Finites: declets in coefficient +dqcan021 canonical #77ffcff3fcff3fcff3fcff3fcff3fcff -> #77ffcff3fcff3fcff3fcff3fcff3fcff +dqcan022 canonical #77fffff3fcff3fcff3fcff3fcff3fcff -> #77ffcff3fcff3fcff3fcff3fcff3fcff +dqcan023 canonical #77ffcffffcff3fcff3fcff3fcff3fcff -> #77ffcff3fcff3fcff3fcff3fcff3fcff +dqcan024 canonical #77ffcff3ffff3fcff3fcff3fcff3fcff -> #77ffcff3fcff3fcff3fcff3fcff3fcff +dqcan025 canonical #77ffcff3fcffffcff3fcff3fcff3fcff -> #77ffcff3fcff3fcff3fcff3fcff3fcff +dqcan026 canonical #77ffcff3fcff3ffff3fcff3fcff3fcff -> #77ffcff3fcff3fcff3fcff3fcff3fcff +dqcan027 canonical #77ffcff3fcff3fcffffcff3fcff3fcff -> #77ffcff3fcff3fcff3fcff3fcff3fcff +dqcan028 canonical #77ffcff3fcff3fcff3ffff3fcff3fcff -> #77ffcff3fcff3fcff3fcff3fcff3fcff +dqcan029 canonical #77ffcff3fcff3fcff3fcffffcff3fcff -> #77ffcff3fcff3fcff3fcff3fcff3fcff +dqcan030 canonical #77ffcff3fcff3fcff3fcff3ffff3fcff -> #77ffcff3fcff3fcff3fcff3fcff3fcff +dqcan031 canonical #77ffcff3fcff3fcff3fcff3fcffffcff -> #77ffcff3fcff3fcff3fcff3fcff3fcff +dqcan032 canonical #77ffcff3fcff3fcff3fcff3fcff3ffff -> #77ffcff3fcff3fcff3fcff3fcff3fcff + +-- NaN: declets in payload +dqcan061 canonical #7c000ff3fcff3fcff3fcff3fcff3fcff -> #7c000ff3fcff3fcff3fcff3fcff3fcff +dqcan062 canonical #7c000ffffcff3fcff3fcff3fcff3fcff -> #7c000ff3fcff3fcff3fcff3fcff3fcff +dqcan063 canonical #7c000ff3ffff3fcff3fcff3fcff3fcff -> #7c000ff3fcff3fcff3fcff3fcff3fcff +dqcan064 canonical #7c000ff3fcffffcff3fcff3fcff3fcff -> #7c000ff3fcff3fcff3fcff3fcff3fcff +dqcan065 canonical #7c000ff3fcff3ffff3fcff3fcff3fcff -> #7c000ff3fcff3fcff3fcff3fcff3fcff +dqcan066 canonical #7c000ff3fcff3fcffffcff3fcff3fcff -> #7c000ff3fcff3fcff3fcff3fcff3fcff +dqcan067 canonical #7c000ff3fcff3fcff3ffff3fcff3fcff -> #7c000ff3fcff3fcff3fcff3fcff3fcff +dqcan068 canonical #7c000ff3fcff3fcff3fcffffcff3fcff -> #7c000ff3fcff3fcff3fcff3fcff3fcff +dqcan069 canonical #7c000ff3fcff3fcff3fcff3ffff3fcff -> #7c000ff3fcff3fcff3fcff3fcff3fcff +dqcan070 canonical #7c000ff3fcff3fcff3fcff3fcffffcff -> #7c000ff3fcff3fcff3fcff3fcff3fcff +dqcan071 canonical #7c000ff3fcff3fcff3fcff3fcff3ffff -> #7c000ff3fcff3fcff3fcff3fcff3fcff +-- NaN: exponent continuation bits [excluding sNaN selector] +dqcan081 canonical #7d000ff3fcff3fcff3fcff3fcff3fcff -> #7c000ff3fcff3fcff3fcff3fcff3fcff +dqcan082 canonical #7c800ff3fcff3fcff3fcff3fcff3fcff -> #7c000ff3fcff3fcff3fcff3fcff3fcff +dqcan083 canonical #7c400ff3fcff3fcff3fcff3fcff3fcff -> #7c000ff3fcff3fcff3fcff3fcff3fcff +dqcan084 canonical #7c200ff3fcff3fcff3fcff3fcff3fcff -> #7c000ff3fcff3fcff3fcff3fcff3fcff +dqcan085 canonical #7c100ff3fcff3fcff3fcff3fcff3fcff -> #7c000ff3fcff3fcff3fcff3fcff3fcff +dqcan086 canonical #7c080ff3fcff3fcff3fcff3fcff3fcff -> #7c000ff3fcff3fcff3fcff3fcff3fcff +dqcan087 canonical #7c040ff3fcff3fcff3fcff3fcff3fcff -> #7c000ff3fcff3fcff3fcff3fcff3fcff +dqcan088 canonical #7c020ff3fcff3fcff3fcff3fcff3fcff -> #7c000ff3fcff3fcff3fcff3fcff3fcff +dqcan089 canonical #7c010ff3fcff3fcff3fcff3fcff3fcff -> #7c000ff3fcff3fcff3fcff3fcff3fcff +dqcan090 canonical #7c008ff3fcff3fcff3fcff3fcff3fcff -> #7c000ff3fcff3fcff3fcff3fcff3fcff +dqcan091 canonical #7c004ff3fcff3fcff3fcff3fcff3fcff -> #7c000ff3fcff3fcff3fcff3fcff3fcff + +-- sNaN: declets in payload +dqcan101 canonical #7e000ff3fcff3fcff3fcff3fcff3fcff -> #7e000ff3fcff3fcff3fcff3fcff3fcff +dqcan102 canonical #7e000ffffcff3fcff3fcff3fcff3fcff -> #7e000ff3fcff3fcff3fcff3fcff3fcff +dqcan103 canonical #7e000ff3ffff3fcff3fcff3fcff3fcff -> #7e000ff3fcff3fcff3fcff3fcff3fcff +dqcan104 canonical #7e000ff3fcffffcff3fcff3fcff3fcff -> #7e000ff3fcff3fcff3fcff3fcff3fcff +dqcan105 canonical #7e000ff3fcff3ffff3fcff3fcff3fcff -> #7e000ff3fcff3fcff3fcff3fcff3fcff +dqcan106 canonical #7e000ff3fcff3fcffffcff3fcff3fcff -> #7e000ff3fcff3fcff3fcff3fcff3fcff +dqcan107 canonical #7e000ff3fcff3fcff3ffff3fcff3fcff -> #7e000ff3fcff3fcff3fcff3fcff3fcff +dqcan108 canonical #7e000ff3fcff3fcff3fcffffcff3fcff -> #7e000ff3fcff3fcff3fcff3fcff3fcff +dqcan109 canonical #7e000ff3fcff3fcff3fcff3ffff3fcff -> #7e000ff3fcff3fcff3fcff3fcff3fcff +dqcan100 canonical #7e000ff3fcff3fcff3fcff3fcffffcff -> #7e000ff3fcff3fcff3fcff3fcff3fcff +dqcan111 canonical #7e000ff3fcff3fcff3fcff3fcff3ffff -> #7e000ff3fcff3fcff3fcff3fcff3fcff +-- sNaN: exponent continuation bits [excluding sNaN selector] +dqcan121 canonical #7f000ff3fcff3fcff3fcff3fcff3fcff -> #7e000ff3fcff3fcff3fcff3fcff3fcff +dqcan122 canonical #7e800ff3fcff3fcff3fcff3fcff3fcff -> #7e000ff3fcff3fcff3fcff3fcff3fcff +dqcan123 canonical #7e400ff3fcff3fcff3fcff3fcff3fcff -> #7e000ff3fcff3fcff3fcff3fcff3fcff +dqcan124 canonical #7e200ff3fcff3fcff3fcff3fcff3fcff -> #7e000ff3fcff3fcff3fcff3fcff3fcff +dqcan125 canonical #7e100ff3fcff3fcff3fcff3fcff3fcff -> #7e000ff3fcff3fcff3fcff3fcff3fcff +dqcan126 canonical #7e080ff3fcff3fcff3fcff3fcff3fcff -> #7e000ff3fcff3fcff3fcff3fcff3fcff +dqcan127 canonical #7e040ff3fcff3fcff3fcff3fcff3fcff -> #7e000ff3fcff3fcff3fcff3fcff3fcff +dqcan128 canonical #7e020ff3fcff3fcff3fcff3fcff3fcff -> #7e000ff3fcff3fcff3fcff3fcff3fcff +dqcan129 canonical #7e010ff3fcff3fcff3fcff3fcff3fcff -> #7e000ff3fcff3fcff3fcff3fcff3fcff +dqcan130 canonical #7e008ff3fcff3fcff3fcff3fcff3fcff -> #7e000ff3fcff3fcff3fcff3fcff3fcff +dqcan131 canonical #7e004ff3fcff3fcff3fcff3fcff3fcff -> #7e000ff3fcff3fcff3fcff3fcff3fcff + +-- Inf: exponent continuation bits +dqcan137 canonical #78000000000000000000000000000000 -> #78000000000000000000000000000000 +dqcan138 canonical #79000000000000000000000000000000 -> #78000000000000000000000000000000 +dqcan139 canonical #7a000000000000000000000000000000 -> #78000000000000000000000000000000 +dqcan140 canonical #78800000000000000000000000000000 -> #78000000000000000000000000000000 +dqcan141 canonical #78400000000000000000000000000000 -> #78000000000000000000000000000000 +dqcan142 canonical #78200000000000000000000000000000 -> #78000000000000000000000000000000 +dqcan143 canonical #78100000000000000000000000000000 -> #78000000000000000000000000000000 +dqcan144 canonical #78080000000000000000000000000000 -> #78000000000000000000000000000000 +dqcan145 canonical #78040000000000000000000000000000 -> #78000000000000000000000000000000 +dqcan146 canonical #78020000000000000000000000000000 -> #78000000000000000000000000000000 +dqcan147 canonical #78010000000000000000000000000000 -> #78000000000000000000000000000000 +dqcan148 canonical #78008000000000000000000000000000 -> #78000000000000000000000000000000 +dqcan149 canonical #78004000000000000000000000000000 -> #78000000000000000000000000000000 + +-- Inf: coefficient continuation bits (first, last, and a few others) +dqcan150 canonical #78000000000000000000000000000000 -> #78000000000000000000000000000000 +dqcan151 canonical #78020000000000000000000000000000 -> #78000000000000000000000000000000 +dqcan152 canonical #78000000000000000000000000000001 -> #78000000000000000000000000000000 +dqcan153 canonical #78010000000000000000000000000000 -> #78000000000000000000000000000000 +dqcan154 canonical #78002000000000000000000000000000 -> #78000000000000000000000000000000 +dqcan155 canonical #78000800000000000000000000000000 -> #78000000000000000000000000000000 +dqcan156 canonical #78000020000000000000000000000000 -> #78000000000000000000000000000000 +dqcan157 canonical #78000004000000000000000000000000 -> #78000000000000000000000000000000 +dqcan158 canonical #78000000400000000000000000000000 -> #78000000000000000000000000000000 +dqcan159 canonical #78000000080000000000000000000000 -> #78000000000000000000000000000000 +dqcan160 canonical #78000000004000000000000000000000 -> #78000000000000000000000000000000 +dqcan161 canonical #78000000000200000000000000000000 -> #78000000000000000000000000000000 +dqcan162 canonical #78000000000080000000000000000000 -> #78000000000000000000000000000000 +dqcan163 canonical #78000000000002000000000000000000 -> #78000000000000000000000000000000 +dqcan164 canonical #78000000000000400000000000000000 -> #78000000000000000000000000000000 +dqcan165 canonical #78000000000000080000000000000000 -> #78000000000000000000000000000000 +dqcan166 canonical #78000000000000001000000000000000 -> #78000000000000000000000000000000 +dqcan167 canonical #78000000000000000200000000000000 -> #78000000000000000000000000000000 +dqcan168 canonical #78000000000000000080000000000000 -> #78000000000000000000000000000000 +dqcan169 canonical #78000000000000000004000000000000 -> #78000000000000000000000000000000 +dqcan170 canonical #78000000000000000000400000000000 -> #78000000000000000000000000000000 +dqcan171 canonical #78000000000000000000010000000000 -> #78000000000000000000000000000000 +dqcan172 canonical #78000000000000000000002000000000 -> #78000000000000000000000000000000 +dqcan173 canonical #78000000000000000000000400000000 -> #78000000000000000000000000000000 +dqcan174 canonical #78000000000000000000000080000000 -> #78000000000000000000000000000000 +dqcan175 canonical #78000000000000000000000002000000 -> #78000000000000000000000000000000 +dqcan176 canonical #78000000000000000000000000400000 -> #78000000000000000000000000000000 +dqcan177 canonical #78000000000000000000000000020000 -> #78000000000000000000000000000000 +dqcan178 canonical #78000000000000000000000000001000 -> #78000000000000000000000000000000 +dqcan179 canonical #78000000000000000000000000000400 -> #78000000000000000000000000000000 +dqcan180 canonical #78000000000000000000000000000020 -> #78000000000000000000000000000000 +dqcan181 canonical #78000000000000000000000000000008 -> #78000000000000000000000000000000 + + +-- Now the operators -- trying to check paths that might fail to +-- canonicalize propagated operands + +----- Add: +-- Finites: neutral 0 +dqcan202 add 0E+6144 #77ffcff3fcff3fcffffcff3fcff3fcff -> #77ffcff3fcff3fcff3fcff3fcff3fcff +dqcan203 add #77ffcff3fcff3fcff3fcff3ffff3fcff 0E+6144 -> #77ffcff3fcff3fcff3fcff3fcff3fcff +-- tiny zero +dqcan204 add 0E-6176 #77ffcff3ffff3fcff3fcff3fcff3fcff -> #77ffcff3fcff3fcff3fcff3fcff3fcff Rounded +dqcan205 add #77ffcff3fcff3fcff3fcff3fcff3ffff 0E-6176 -> #77ffcff3fcff3fcff3fcff3fcff3fcff Rounded +-- tiny non zero +dqcan206 add -1E-6176 #77ffcff3fcff3fcff3fcff3fcfffffff -> #77ffcff3fcff3fcff3fcff3fcff3fcff Inexact Rounded +dqcan207 add #77ffcffffffffffffffffffffff3fcff -1E-6176 -> #77ffcff3fcff3fcff3fcff3fcff3fcff Inexact Rounded +-- NaN: declets in payload +dqcan211 add 0 #7c000ff3fcff3fcff3fcfffffff3fcff -> #7c000ff3fcff3fcff3fcff3fcff3fcff +dqcan212 add #7c000ff3fcff3fcfffffff3fcff3fcff 0 -> #7c000ff3fcff3fcff3fcff3fcff3fcff +-- NaN: exponent continuation bits [excluding sNaN selector] +dqcan213 add 0 #7c400ff3fcff3fcff3fcff3fcff3fcff -> #7c000ff3fcff3fcff3fcff3fcff3fcff +dqcan214 add #7c020ff3fcff3fcff3fcff3fcff3fcff 0 -> #7c000ff3fcff3fcff3fcff3fcff3fcff +-- sNaN: declets in payload +dqcan215 add 0 #7e000ff3fcffffcff3fcff3fcff3fcff -> #7c000ff3fcff3fcff3fcff3fcff3fcff Invalid_operation +dqcan216 add #7e003ff3fcff3fcff3fcff3fcff3fcff 0 -> #7c000ff3fcff3fcff3fcff3fcff3fcff Invalid_operation +-- sNaN: exponent continuation bits [excluding sNaN selector] +dqcan217 add 0 #7e500ff3fcff3fcff3fcff3fcff3fcff -> #7c000ff3fcff3fcff3fcff3fcff3fcff Invalid_operation +dqcan218 add #7e0e0ff3fcff3fcff3fcff3fcff3fcff 0 -> #7c000ff3fcff3fcff3fcff3fcff3fcff Invalid_operation +-- Inf: exponent continuation bits +dqcan220 add 0 #78010000000000000000000000000000 -> #78000000000000000000000000000000 +dqcan221 add #78680000000000000000000000000000 0 -> #78000000000000000000000000000000 +-- Inf: coefficient continuation bits +dqcan222 add 0 #78002000000000000000000000000000 -> #78000000000000000000000000000000 +dqcan223 add #78000000000000000000000000000001 0 -> #78000000000000000000000000000000 +dqcan224 add 0 #78000002000000000000000000000000 -> #78000000000000000000000000000000 +dqcan225 add #780000000000f0000000000000000000 0 -> #78000000000000000000000000000000 +dqcan226 add 0 #78000000000000000005000000000000 -> #78000000000000000000000000000000 +dqcan227 add #780000000000000000000000000a0000 0 -> #78000000000000000000000000000000 + +----- Class: [does not return encoded] + +----- Compare: +dqcan231 compare -Inf 1 -> #a2080000000000000000000000000001 +dqcan232 compare -Inf -Inf -> #22080000000000000000000000000000 +dqcan233 compare 1 -Inf -> #22080000000000000000000000000001 +dqcan234 compare #7c010ff3fcff3fcff3fcff3ffffffcff -1000 -> #7c000ff3fcff3fcff3fcff3fcff3fcff +dqcan235 compare #7e004ff3fcff3fcff3ffffffcff3fcff -1000 -> #7c000ff3fcff3fcff3fcff3fcff3fcff Invalid_operation + +----- CompareSig: +dqcan241 comparesig -Inf 1 -> #a2080000000000000000000000000001 +dqcan242 comparesig -Inf -Inf -> #22080000000000000000000000000000 +dqcan243 comparesig 1 -Inf -> #22080000000000000000000000000001 +dqcan244 comparesig #7c400ff3ffff3fcff3fcff3fcff3fcff -1000 -> #7c000ff3fcff3fcff3fcff3fcff3fcff Invalid_operation +dqcan245 comparesig #7e050ff3fcfffffff3fcff3fcff3fcff -1000 -> #7c000ff3fcff3fcff3fcff3fcff3fcff Invalid_operation + +----- Copy: [does not usually canonicalize] +-- finites +dqcan250 copy #6e080ff3fcff3fcfffffff3fcfffffff -> #6e080ff3fcff3fcfffffff3fcfffffff +dqcan251 copy #ee080ff3fcff3ffff3fcff3ffff3fcff -> #ee080ff3fcff3ffff3fcff3ffff3fcff +-- NaNs +dqcan252 copy #7c000ff3fcffffffffffffffcff3fcff -> #7c000ff3fcffffffffffffffcff3fcff +dqcan253 copy #7c080ff3fcff3fcff3fcff3fcff3fcff -> #7c080ff3fcff3fcff3fcff3fcff3fcff +-- sNaN +dqcan254 copy #7e003ff3fcffffffffffffffcff3fcff -> #7e003ff3fcffffffffffffffcff3fcff +dqcan255 copy #7e100ff3fcff3fcff3fcff3fcff3fcff -> #7e100ff3fcff3fcff3fcff3fcff3fcff +-- Inf +dqcan258 copy #78002000000000000000000000000000 -> #78002000000000000000000000000000 +dqcan259 copy #78000000000010000000000000100000 -> #78000000000010000000000000100000 + +----- CopyAbs: [does not usually canonicalize] +-- finites +dqcan260 copyabs #6e080ff3fcff3fcfffffff3fcfffffff -> #6e080ff3fcff3fcfffffff3fcfffffff +dqcan261 copyabs #ee080ff3fcff3ffff3fcff3ffff3fcff -> #6e080ff3fcff3ffff3fcff3ffff3fcff +-- NaNs +dqcan262 copyabs #fc000ff3fcffffffffffffffcff3fcff -> #7c000ff3fcffffffffffffffcff3fcff +dqcan263 copyabs #fc080ff3fcff3fcff3fcff3fcff3fcff -> #7c080ff3fcff3fcff3fcff3fcff3fcff +-- sNaN +dqcan264 copyabs #fe003ff3fcffffffffffffffcff3fcff -> #7e003ff3fcffffffffffffffcff3fcff +dqcan265 copyabs #fe100ff3fcff3fcff3fcff3fcff3fcff -> #7e100ff3fcff3fcff3fcff3fcff3fcff +-- Inf +dqcan268 copyabs #f8002000000000000000000000000000 -> #78002000000000000000000000000000 +dqcan269 copyabs #f8000000000000700700700000000000 -> #78000000000000700700700000000000 + +----- CopyNegate: [does not usually canonicalize] +-- finites +dqcan270 copynegate #6e080ff3fcff3fcfffffff3fcfffffff -> #ee080ff3fcff3fcfffffff3fcfffffff +dqcan271 copynegate #ee080ff3fcff3ffff3fcff3ffff3fcff -> #6e080ff3fcff3ffff3fcff3ffff3fcff +-- NaNs +dqcan272 copynegate #7c000ff3fcffffffffffff3fcff3fcff -> #fc000ff3fcffffffffffff3fcff3fcff +dqcan273 copynegate #7c080ff3fcff3fcff3fcff3fcff3fcff -> #fc080ff3fcff3fcff3fcff3fcff3fcff +-- sNaN +dqcan274 copynegate #7e003ff3fcffffffffffffffcff3fcff -> #fe003ff3fcffffffffffffffcff3fcff +dqcan275 copynegate #7e100ff3fcff3fcff3fcff3fcff3fcff -> #fe100ff3fcff3fcff3fcff3fcff3fcff +-- Inf +dqcan278 copynegate #78002000000000000000000000000000 -> #f8002000000000000000000000000000 +dqcan279 copynegate #78000000000010000000000000100000 -> #f8000000000010000000000000100000 + +----- CopySign: [does not usually canonicalize] +-- finites +dqcan280 copysign #6e080ff3fcff3fcfffffff3fcfffffff -1 -> #ee080ff3fcff3fcfffffff3fcfffffff +dqcan281 copysign #ee080ff3fcff3ffff3fcff3ffff3fcff 1 -> #6e080ff3fcff3ffff3fcff3ffff3fcff +-- NaNs +dqcan282 copysign #7c000ff3fcffffffffffffffcff3fcff -1 -> #fc000ff3fcffffffffffffffcff3fcff +dqcan283 copysign #7c080ff3fcff3fcff3fcff3fcff3fcff 1 -> #7c080ff3fcff3fcff3fcff3fcff3fcff +-- sNaN +dqcan284 copysign #7e003ff3fcffffffffffffffcff3fcff -1 -> #fe003ff3fcffffffffffffffcff3fcff +dqcan285 copysign #7e100ff3fcff3fcff3fcff3fcff3fcff 1 -> #7e100ff3fcff3fcff3fcff3fcff3fcff +-- Inf +dqcan288 copysign #78002000000000000000000000000000 -1 -> #f8002000000000000000000000000000 +dqcan289 copysign #78000000000010000000000000100000 1 -> #78000000000010000000000000100000 + +----- Multiply: +-- Finites: neutral 0 +dqcan302 multiply 1 #77ffff3fcff3fcff0000000000000000 -> #77ffff3fcff3fcff0000000000000000 +dqcan303 multiply #77fcffffcff3fcff0000000000000000 1 -> #77fccfffcff3fcff0000000000000000 +-- negative +dqcan306 multiply -1 #77ffff3fcff3fcff0000000000000000 -> #f7ffff3fcff3fcff0000000000000000 +dqcan307 multiply #77fcffffcff3fcff0000000000000000 -1 -> #f7fccfffcff3fcff0000000000000000 +-- NaN: declets in payload +dqcan311 multiply 1 #7c03ff3fcff3fcff0000000000000000 -> #7c003f3fcff3fcff0000000000000000 +dqcan312 multiply #7c03ff3fcff3fcff0000000000000000 1 -> #7c003f3fcff3fcff0000000000000000 +-- NaN: exponent continuation bits [excluding sNaN selector] +dqcan313 multiply 1 #7c40ff3fcff3fcff0000000000000000 -> #7c003f3fcff3fcff0000000000000000 +dqcan314 multiply #7c40ff3fcff3fcff0000000000000000 1 -> #7c003f3fcff3fcff0000000000000000 +-- sNaN: declets in payload +dqcan315 multiply 1 #7e00ffffcff3fcff0000000000000000 -> #7c000fffcff3fcff0000000000000000 Invalid_operation +dqcan316 multiply #7e00ffffcff3fcff0000000000000000 1 -> #7c000fffcff3fcff0000000000000000 Invalid_operation +-- sNaN: exponent continuation bits [excluding sNaN selector] +dqcan317 multiply 1 #7e80ff3fcff3fcff0000000000000000 -> #7c003f3fcff3fcff0000000000000000 Invalid_operation +dqcan318 multiply #7e80ff3fcff3fcff0000000000000000 1 -> #7c003f3fcff3fcff0000000000000000 Invalid_operation +-- Inf: exponent continuation bits +dqcan320 multiply 1 #78800000000000000000000000000000 -> #78000000000000000000000000000000 +dqcan321 multiply #78800000000000000000000000000000 1 -> #78000000000000000000000000000000 +-- Inf: coefficient continuation bits +dqcan322 multiply 1 #78020000000000000000000000000000 -> #78000000000000000000000000000000 +dqcan323 multiply #78020000000000000000000000000000 1 -> #78000000000000000000000000000000 +dqcan324 multiply 1 #78000000000000010000000000000000 -> #78000000000000000000000000000000 +dqcan325 multiply #78000000000000010000000000000000 1 -> #78000000000000000000000000000000 +dqcan326 multiply 1 #78000020000000000000000000000000 -> #78000000000000000000000000000000 +dqcan327 multiply #78000020000000000000000000000000 1 -> #78000000000000000000000000000000 + +----- Quantize: +dqcan401 quantize #ee080ff3fcff3fcff3fffffffff3fcff 0 -> #ee080ff3fcff3fcff3fcff3fcff3fcff +dqcan402 quantize #ee080ff3fffffffffffcff3fcff3fcff 0 -> #ee080ff3fcff3fcff3fcff3fcff3fcff +dqcan403 quantize #78800000000000000000000000000000 Inf -> #78000000000000000000000000000000 +dqcan404 quantize #78020000000000000000000000000000 -Inf -> #78000000000000000000000000000000 +dqcan410 quantize #7c080ff3fcff3fcff3fcff3fcff3fcff 1 -> #7c000ff3fcff3fcff3fcff3fcff3fcff +dqcan411 quantize #fc000ff3fcfffffff3fcff3fcff3fcff 1 -> #fc000ff3fcff3fcff3fcff3fcff3fcff +dqcan412 quantize #7e100ff3fcff3fcff3fcff3fcff3fcff 1 -> #7c000ff3fcff3fcff3fcff3fcff3fcff Invalid_operation +dqcan413 quantize #fe000ff3fcff3fcff3ffffffcff3fcff 1 -> #fc000ff3fcff3fcff3fcff3fcff3fcff Invalid_operation + +----- Subtract: +-- Finites: neutral 0 +dqcan502 subtract 0E+6144 #77ffcff3fcff3fcffffcff3fcff3fcff -> #f7ffcff3fcff3fcff3fcff3fcff3fcff +dqcan503 subtract #77ffcff3fcff3fcff3fcff3ffff3fcff 0E+6144 -> #77ffcff3fcff3fcff3fcff3fcff3fcff +-- tiny zero +dqcan504 subtract 0E-6176 #77ffcff3ffff3fcff3fcff3fcff3fcff -> #f7ffcff3fcff3fcff3fcff3fcff3fcff Rounded +dqcan505 subtract #77ffcff3fcff3fcff3fcff3fcff3ffff 0E-6176 -> #77ffcff3fcff3fcff3fcff3fcff3fcff Rounded +-- tiny non zero +dqcan506 subtract -1E-6176 #77ffcff3fcff3fcff3fcff3fcfffffff -> #f7ffcff3fcff3fcff3fcff3fcff3fcff Inexact Rounded +dqcan507 subtract #77ffcffffffffffffffffffffff3fcff -1E-6176 -> #77ffcff3fcff3fcff3fcff3fcff3fcff Inexact Rounded +-- NaN: declets in payload +dqcan511 subtract 0 #7c000ff3fcff3fcff3fcfffffff3fcff -> #7c000ff3fcff3fcff3fcff3fcff3fcff +dqcan512 subtract #7c000ff3fcff3fcfffffff3fcff3fcff 0 -> #7c000ff3fcff3fcff3fcff3fcff3fcff +-- NaN: exponent continuation bits [excluding sNaN selector] +dqcan513 subtract 0 #7c400ff3fcff3fcff3fcff3fcff3fcff -> #7c000ff3fcff3fcff3fcff3fcff3fcff +dqcan514 subtract #7c020ff3fcff3fcff3fcff3fcff3fcff 0 -> #7c000ff3fcff3fcff3fcff3fcff3fcff +-- sNaN: declets in payload +dqcan515 subtract 0 #7e000ff3fcffffcff3fcff3fcff3fcff -> #7c000ff3fcff3fcff3fcff3fcff3fcff Invalid_operation +dqcan516 subtract #7e003ff3fcff3fcff3fcff3fcff3fcff 0 -> #7c000ff3fcff3fcff3fcff3fcff3fcff Invalid_operation +-- sNaN: exponent continuation bits [excluding sNaN selector] +dqcan517 subtract 0 #7e500ff3fcff3fcff3fcff3fcff3fcff -> #7c000ff3fcff3fcff3fcff3fcff3fcff Invalid_operation +dqcan518 subtract #7e0e0ff3fcff3fcff3fcff3fcff3fcff 0 -> #7c000ff3fcff3fcff3fcff3fcff3fcff Invalid_operation +-- Inf: exponent continuation bits +dqcan520 subtract 0 #78010000000000000000000000000000 -> #f8000000000000000000000000000000 +dqcan521 subtract #78680000000000000000000000000000 0 -> #78000000000000000000000000000000 +-- Inf: coefficient continuation bits +dqcan522 subtract 0 #78002000000000000000000000000000 -> #f8000000000000000000000000000000 +dqcan523 subtract #78000000000000000000000000000001 0 -> #78000000000000000000000000000000 +dqcan524 subtract 0 #78000002000000000000000000000000 -> #f8000000000000000000000000000000 +dqcan525 subtract #780000000000f0000000000000000000 0 -> #78000000000000000000000000000000 +dqcan526 subtract 0 #78000000000000000005000000000000 -> #f8000000000000000000000000000000 +dqcan527 subtract #780000000000000000000000000a0000 0 -> #78000000000000000000000000000000 + +----- ToIntegral: +dqcan601 tointegralx #6e080ff3fdff3fcff3fcff3fcff3fcff -> #6e080ff3fcff3fcff3fcff3fcff3fcff +dqcan602 tointegralx #ee080ff3fcff3ffff3fcff3fcff3fcff -> #ee080ff3fcff3fcff3fcff3fcff3fcff +dqcan603 tointegralx #78800000000000000000000000000000 -> #78000000000000000000000000000000 +dqcan604 tointegralx #78020000000000000000000000000000 -> #78000000000000000000000000000000 +dqcan614 tointegralx #7c100ff3fcff3fcff3fcff3fcff3fcff -> #7c000ff3fcff3fcff3fcff3fcff3fcff +dqcan615 tointegralx #fc000ff3fcff3fcff3fcffffcff3fcff -> #fc000ff3fcff3fcff3fcff3fcff3fcff +dqcan616 tointegralx #7e010ff3fcff3fcff3fcff3fcff3fcff -> #7c000ff3fcff3fcff3fcff3fcff3fcff Invalid_operation +dqcan617 tointegralx #fe000ff3fcff3fcff3fdff3fcff3fcff -> #fc000ff3fcff3fcff3fcff3fcff3fcff Invalid_operation +-- uncanonical 3999, 39.99, 3.99, 0.399, and negatives +dqcan618 tointegralx #22080000000000000000000000000fff -> #22080000000000000000000000000cff +dqcan619 tointegralx #22078000000000000000000000000fff -> #22080000000000000000000000000040 Inexact Rounded +dqcan620 tointegralx #22074000000000000000000000000fff -> #22080000000000000000000000000004 Inexact Rounded +dqcan621 tointegralx #22070000000000000000000000000fff -> #22080000000000000000000000000000 Inexact Rounded +dqcan622 tointegralx #a2080000000000000000000000000fff -> #a2080000000000000000000000000cff +dqcan623 tointegralx #a2078000000000000000000000000fff -> #a2080000000000000000000000000040 Inexact Rounded +dqcan624 tointegralx #a2074000000000000000000000000fff -> #a2080000000000000000000000000004 Inexact Rounded +dqcan625 tointegralx #a2070000000000000000000000000fff -> #a2080000000000000000000000000000 Inexact Rounded + + + Added: python/branches/release25-maint/Lib/test/decimaltestdata/dqClass.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/dqClass.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,77 @@ +------------------------------------------------------------------------ +-- dqClass.decTest -- decQuad Class operations -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- [New 2006.11.27] + +extended: 1 +clamp: 1 +precision: 34 +maxExponent: 6144 +minExponent: -6143 +rounding: half_even + +dqcla001 class 0 -> +Zero +dqcla002 class 0.00 -> +Zero +dqcla003 class 0E+5 -> +Zero +dqcla004 class 1E-6176 -> +Subnormal +dqcla005 class 0.1E-6143 -> +Subnormal +dqcla006 class 0.99999999999999999999999999999999E-6143 -> +Subnormal +dqcla007 class 1.00000000000000000000000000000000E-6143 -> +Normal +dqcla008 class 1E-6143 -> +Normal +dqcla009 class 1E-100 -> +Normal +dqcla010 class 1E-10 -> +Normal +dqcla012 class 1E-1 -> +Normal +dqcla013 class 1 -> +Normal +dqcla014 class 2.50 -> +Normal +dqcla015 class 100.100 -> +Normal +dqcla016 class 1E+30 -> +Normal +dqcla017 class 1E+6144 -> +Normal +dqcla018 class 9.99999999999999999999999999999999E+6144 -> +Normal +dqcla019 class Inf -> +Infinity + +dqcla021 class -0 -> -Zero +dqcla022 class -0.00 -> -Zero +dqcla023 class -0E+5 -> -Zero +dqcla024 class -1E-6176 -> -Subnormal +dqcla025 class -0.1E-6143 -> -Subnormal +dqcla026 class -0.99999999999999999999999999999999E-6143 -> -Subnormal +dqcla027 class -1.00000000000000000000000000000000E-6143 -> -Normal +dqcla028 class -1E-6143 -> -Normal +dqcla029 class -1E-100 -> -Normal +dqcla030 class -1E-10 -> -Normal +dqcla032 class -1E-1 -> -Normal +dqcla033 class -1 -> -Normal +dqcla034 class -2.50 -> -Normal +dqcla035 class -100.100 -> -Normal +dqcla036 class -1E+30 -> -Normal +dqcla037 class -1E+6144 -> -Normal +dqcla0614 class -9.99999999999999999999999999999999E+6144 -> -Normal +dqcla039 class -Inf -> -Infinity + +dqcla041 class NaN -> NaN +dqcla042 class -NaN -> NaN +dqcla043 class +NaN12345 -> NaN +dqcla044 class sNaN -> sNaN +dqcla045 class -sNaN -> sNaN +dqcla046 class +sNaN12345 -> sNaN + + + Added: python/branches/release25-maint/Lib/test/decimaltestdata/dqCompare.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/dqCompare.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,753 @@ +------------------------------------------------------------------------ +-- dqCompare.decTest -- decQuad comparison that allows quiet NaNs -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- Note that we cannot assume add/subtract tests cover paths adequately, +-- here, because the code might be quite different (comparison cannot +-- overflow or underflow, so actual subtractions are not necessary). + +-- All operands and results are decQuads. +extended: 1 +clamp: 1 +precision: 34 +maxExponent: 6144 +minExponent: -6143 +rounding: half_even + +-- sanity checks +dqcom001 compare -2 -2 -> 0 +dqcom002 compare -2 -1 -> -1 +dqcom003 compare -2 0 -> -1 +dqcom004 compare -2 1 -> -1 +dqcom005 compare -2 2 -> -1 +dqcom006 compare -1 -2 -> 1 +dqcom007 compare -1 -1 -> 0 +dqcom008 compare -1 0 -> -1 +dqcom009 compare -1 1 -> -1 +dqcom010 compare -1 2 -> -1 +dqcom011 compare 0 -2 -> 1 +dqcom012 compare 0 -1 -> 1 +dqcom013 compare 0 0 -> 0 +dqcom014 compare 0 1 -> -1 +dqcom015 compare 0 2 -> -1 +dqcom016 compare 1 -2 -> 1 +dqcom017 compare 1 -1 -> 1 +dqcom018 compare 1 0 -> 1 +dqcom019 compare 1 1 -> 0 +dqcom020 compare 1 2 -> -1 +dqcom021 compare 2 -2 -> 1 +dqcom022 compare 2 -1 -> 1 +dqcom023 compare 2 0 -> 1 +dqcom025 compare 2 1 -> 1 +dqcom026 compare 2 2 -> 0 + +dqcom031 compare -20 -20 -> 0 +dqcom032 compare -20 -10 -> -1 +dqcom033 compare -20 00 -> -1 +dqcom034 compare -20 10 -> -1 +dqcom035 compare -20 20 -> -1 +dqcom036 compare -10 -20 -> 1 +dqcom037 compare -10 -10 -> 0 +dqcom038 compare -10 00 -> -1 +dqcom039 compare -10 10 -> -1 +dqcom040 compare -10 20 -> -1 +dqcom041 compare 00 -20 -> 1 +dqcom042 compare 00 -10 -> 1 +dqcom043 compare 00 00 -> 0 +dqcom044 compare 00 10 -> -1 +dqcom045 compare 00 20 -> -1 +dqcom046 compare 10 -20 -> 1 +dqcom047 compare 10 -10 -> 1 +dqcom048 compare 10 00 -> 1 +dqcom049 compare 10 10 -> 0 +dqcom050 compare 10 20 -> -1 +dqcom051 compare 20 -20 -> 1 +dqcom052 compare 20 -10 -> 1 +dqcom053 compare 20 00 -> 1 +dqcom055 compare 20 10 -> 1 +dqcom056 compare 20 20 -> 0 + +dqcom061 compare -2.0 -2.0 -> 0 +dqcom062 compare -2.0 -1.0 -> -1 +dqcom063 compare -2.0 0.0 -> -1 +dqcom064 compare -2.0 1.0 -> -1 +dqcom065 compare -2.0 2.0 -> -1 +dqcom066 compare -1.0 -2.0 -> 1 +dqcom067 compare -1.0 -1.0 -> 0 +dqcom068 compare -1.0 0.0 -> -1 +dqcom069 compare -1.0 1.0 -> -1 +dqcom070 compare -1.0 2.0 -> -1 +dqcom071 compare 0.0 -2.0 -> 1 +dqcom072 compare 0.0 -1.0 -> 1 +dqcom073 compare 0.0 0.0 -> 0 +dqcom074 compare 0.0 1.0 -> -1 +dqcom075 compare 0.0 2.0 -> -1 +dqcom076 compare 1.0 -2.0 -> 1 +dqcom077 compare 1.0 -1.0 -> 1 +dqcom078 compare 1.0 0.0 -> 1 +dqcom079 compare 1.0 1.0 -> 0 +dqcom080 compare 1.0 2.0 -> -1 +dqcom081 compare 2.0 -2.0 -> 1 +dqcom082 compare 2.0 -1.0 -> 1 +dqcom083 compare 2.0 0.0 -> 1 +dqcom085 compare 2.0 1.0 -> 1 +dqcom086 compare 2.0 2.0 -> 0 + +-- now some cases which might overflow if subtract were used +dqcom090 compare 9.999999999999999999999999999999999E+6144 9.999999999999999999999999999999999E+6144 -> 0 +dqcom091 compare -9.999999999999999999999999999999999E+6144 9.999999999999999999999999999999999E+6144 -> -1 +dqcom092 compare 9.999999999999999999999999999999999E+6144 -9.999999999999999999999999999999999E+6144 -> 1 +dqcom093 compare -9.999999999999999999999999999999999E+6144 -9.999999999999999999999999999999999E+6144 -> 0 + +-- some differing length/exponent cases +dqcom100 compare 7.0 7.0 -> 0 +dqcom101 compare 7.0 7 -> 0 +dqcom102 compare 7 7.0 -> 0 +dqcom103 compare 7E+0 7.0 -> 0 +dqcom104 compare 70E-1 7.0 -> 0 +dqcom105 compare 0.7E+1 7 -> 0 +dqcom106 compare 70E-1 7 -> 0 +dqcom107 compare 7.0 7E+0 -> 0 +dqcom108 compare 7.0 70E-1 -> 0 +dqcom109 compare 7 0.7E+1 -> 0 +dqcom110 compare 7 70E-1 -> 0 + +dqcom120 compare 8.0 7.0 -> 1 +dqcom121 compare 8.0 7 -> 1 +dqcom122 compare 8 7.0 -> 1 +dqcom123 compare 8E+0 7.0 -> 1 +dqcom124 compare 80E-1 7.0 -> 1 +dqcom125 compare 0.8E+1 7 -> 1 +dqcom126 compare 80E-1 7 -> 1 +dqcom127 compare 8.0 7E+0 -> 1 +dqcom128 compare 8.0 70E-1 -> 1 +dqcom129 compare 8 0.7E+1 -> 1 +dqcom130 compare 8 70E-1 -> 1 + +dqcom140 compare 8.0 9.0 -> -1 +dqcom141 compare 8.0 9 -> -1 +dqcom142 compare 8 9.0 -> -1 +dqcom143 compare 8E+0 9.0 -> -1 +dqcom144 compare 80E-1 9.0 -> -1 +dqcom145 compare 0.8E+1 9 -> -1 +dqcom146 compare 80E-1 9 -> -1 +dqcom147 compare 8.0 9E+0 -> -1 +dqcom148 compare 8.0 90E-1 -> -1 +dqcom149 compare 8 0.9E+1 -> -1 +dqcom150 compare 8 90E-1 -> -1 + +-- and again, with sign changes -+ .. +dqcom200 compare -7.0 7.0 -> -1 +dqcom201 compare -7.0 7 -> -1 +dqcom202 compare -7 7.0 -> -1 +dqcom203 compare -7E+0 7.0 -> -1 +dqcom204 compare -70E-1 7.0 -> -1 +dqcom205 compare -0.7E+1 7 -> -1 +dqcom206 compare -70E-1 7 -> -1 +dqcom207 compare -7.0 7E+0 -> -1 +dqcom208 compare -7.0 70E-1 -> -1 +dqcom209 compare -7 0.7E+1 -> -1 +dqcom210 compare -7 70E-1 -> -1 + +dqcom220 compare -8.0 7.0 -> -1 +dqcom221 compare -8.0 7 -> -1 +dqcom222 compare -8 7.0 -> -1 +dqcom223 compare -8E+0 7.0 -> -1 +dqcom224 compare -80E-1 7.0 -> -1 +dqcom225 compare -0.8E+1 7 -> -1 +dqcom226 compare -80E-1 7 -> -1 +dqcom227 compare -8.0 7E+0 -> -1 +dqcom228 compare -8.0 70E-1 -> -1 +dqcom229 compare -8 0.7E+1 -> -1 +dqcom230 compare -8 70E-1 -> -1 + +dqcom240 compare -8.0 9.0 -> -1 +dqcom241 compare -8.0 9 -> -1 +dqcom242 compare -8 9.0 -> -1 +dqcom243 compare -8E+0 9.0 -> -1 +dqcom244 compare -80E-1 9.0 -> -1 +dqcom245 compare -0.8E+1 9 -> -1 +dqcom246 compare -80E-1 9 -> -1 +dqcom247 compare -8.0 9E+0 -> -1 +dqcom248 compare -8.0 90E-1 -> -1 +dqcom249 compare -8 0.9E+1 -> -1 +dqcom250 compare -8 90E-1 -> -1 + +-- and again, with sign changes +- .. +dqcom300 compare 7.0 -7.0 -> 1 +dqcom301 compare 7.0 -7 -> 1 +dqcom302 compare 7 -7.0 -> 1 +dqcom303 compare 7E+0 -7.0 -> 1 +dqcom304 compare 70E-1 -7.0 -> 1 +dqcom305 compare .7E+1 -7 -> 1 +dqcom306 compare 70E-1 -7 -> 1 +dqcom307 compare 7.0 -7E+0 -> 1 +dqcom308 compare 7.0 -70E-1 -> 1 +dqcom309 compare 7 -.7E+1 -> 1 +dqcom310 compare 7 -70E-1 -> 1 + +dqcom320 compare 8.0 -7.0 -> 1 +dqcom321 compare 8.0 -7 -> 1 +dqcom322 compare 8 -7.0 -> 1 +dqcom323 compare 8E+0 -7.0 -> 1 +dqcom324 compare 80E-1 -7.0 -> 1 +dqcom325 compare .8E+1 -7 -> 1 +dqcom326 compare 80E-1 -7 -> 1 +dqcom327 compare 8.0 -7E+0 -> 1 +dqcom328 compare 8.0 -70E-1 -> 1 +dqcom329 compare 8 -.7E+1 -> 1 +dqcom330 compare 8 -70E-1 -> 1 + +dqcom340 compare 8.0 -9.0 -> 1 +dqcom341 compare 8.0 -9 -> 1 +dqcom342 compare 8 -9.0 -> 1 +dqcom343 compare 8E+0 -9.0 -> 1 +dqcom344 compare 80E-1 -9.0 -> 1 +dqcom345 compare .8E+1 -9 -> 1 +dqcom346 compare 80E-1 -9 -> 1 +dqcom347 compare 8.0 -9E+0 -> 1 +dqcom348 compare 8.0 -90E-1 -> 1 +dqcom349 compare 8 -.9E+1 -> 1 +dqcom350 compare 8 -90E-1 -> 1 + +-- and again, with sign changes -- .. +dqcom400 compare -7.0 -7.0 -> 0 +dqcom401 compare -7.0 -7 -> 0 +dqcom402 compare -7 -7.0 -> 0 +dqcom403 compare -7E+0 -7.0 -> 0 +dqcom404 compare -70E-1 -7.0 -> 0 +dqcom405 compare -.7E+1 -7 -> 0 +dqcom406 compare -70E-1 -7 -> 0 +dqcom407 compare -7.0 -7E+0 -> 0 +dqcom408 compare -7.0 -70E-1 -> 0 +dqcom409 compare -7 -.7E+1 -> 0 +dqcom410 compare -7 -70E-1 -> 0 + +dqcom420 compare -8.0 -7.0 -> -1 +dqcom421 compare -8.0 -7 -> -1 +dqcom422 compare -8 -7.0 -> -1 +dqcom423 compare -8E+0 -7.0 -> -1 +dqcom424 compare -80E-1 -7.0 -> -1 +dqcom425 compare -.8E+1 -7 -> -1 +dqcom426 compare -80E-1 -7 -> -1 +dqcom427 compare -8.0 -7E+0 -> -1 +dqcom428 compare -8.0 -70E-1 -> -1 +dqcom429 compare -8 -.7E+1 -> -1 +dqcom430 compare -8 -70E-1 -> -1 + +dqcom440 compare -8.0 -9.0 -> 1 +dqcom441 compare -8.0 -9 -> 1 +dqcom442 compare -8 -9.0 -> 1 +dqcom443 compare -8E+0 -9.0 -> 1 +dqcom444 compare -80E-1 -9.0 -> 1 +dqcom445 compare -.8E+1 -9 -> 1 +dqcom446 compare -80E-1 -9 -> 1 +dqcom447 compare -8.0 -9E+0 -> 1 +dqcom448 compare -8.0 -90E-1 -> 1 +dqcom449 compare -8 -.9E+1 -> 1 +dqcom450 compare -8 -90E-1 -> 1 + +-- misalignment traps for little-endian +dqcom451 compare 1.0 0.1 -> 1 +dqcom452 compare 0.1 1.0 -> -1 +dqcom453 compare 10.0 0.1 -> 1 +dqcom454 compare 0.1 10.0 -> -1 +dqcom455 compare 100 1.0 -> 1 +dqcom456 compare 1.0 100 -> -1 +dqcom457 compare 1000 10.0 -> 1 +dqcom458 compare 10.0 1000 -> -1 +dqcom459 compare 10000 100.0 -> 1 +dqcom460 compare 100.0 10000 -> -1 +dqcom461 compare 100000 1000.0 -> 1 +dqcom462 compare 1000.0 100000 -> -1 +dqcom463 compare 1000000 10000.0 -> 1 +dqcom464 compare 10000.0 1000000 -> -1 + +-- testcases that subtract to lots of zeros at boundaries [pgr] +dqcom473 compare 123.9999999999999999994560000000000E-89 123.999999999999999999456E-89 -> 0 +dqcom474 compare 123.999999999999999999456000000000E+89 123.999999999999999999456E+89 -> 0 +dqcom475 compare 123.99999999999999999945600000000E-89 123.999999999999999999456E-89 -> 0 +dqcom476 compare 123.9999999999999999994560000000E+89 123.999999999999999999456E+89 -> 0 +dqcom477 compare 123.999999999999999999456000000E-89 123.999999999999999999456E-89 -> 0 +dqcom478 compare 123.99999999999999999945600000E+89 123.999999999999999999456E+89 -> 0 +dqcom479 compare 123.9999999999999999994560000E-89 123.999999999999999999456E-89 -> 0 +dqcom480 compare 123.999999999999999999456000E+89 123.999999999999999999456E+89 -> 0 +dqcom481 compare 123.99999999999999999945600E-89 123.999999999999999999456E-89 -> 0 +dqcom482 compare 123.9999999999999999994560E+89 123.999999999999999999456E+89 -> 0 +dqcom483 compare 123.999999999999999999456E-89 123.999999999999999999456E-89 -> 0 +dqcom487 compare 123.999999999999999999456E+89 123.9999999999999999994560000000000E+89 -> 0 +dqcom488 compare 123.999999999999999999456E-89 123.999999999999999999456000000000E-89 -> 0 +dqcom489 compare 123.999999999999999999456E+89 123.99999999999999999945600000000E+89 -> 0 +dqcom490 compare 123.999999999999999999456E-89 123.9999999999999999994560000000E-89 -> 0 +dqcom491 compare 123.999999999999999999456E+89 123.999999999999999999456000000E+89 -> 0 +dqcom492 compare 123.999999999999999999456E-89 123.99999999999999999945600000E-89 -> 0 +dqcom493 compare 123.999999999999999999456E+89 123.9999999999999999994560000E+89 -> 0 +dqcom494 compare 123.999999999999999999456E-89 123.999999999999999999456000E-89 -> 0 +dqcom495 compare 123.999999999999999999456E+89 123.99999999999999999945600E+89 -> 0 +dqcom496 compare 123.999999999999999999456E-89 123.9999999999999999994560E-89 -> 0 +dqcom497 compare 123.999999999999999999456E+89 123.999999999999999999456E+89 -> 0 + +-- wide-ranging, around precision; signs equal +dqcom500 compare 1 1E-15 -> 1 +dqcom501 compare 1 1E-14 -> 1 +dqcom502 compare 1 1E-13 -> 1 +dqcom503 compare 1 1E-12 -> 1 +dqcom504 compare 1 1E-11 -> 1 +dqcom505 compare 1 1E-10 -> 1 +dqcom506 compare 1 1E-9 -> 1 +dqcom507 compare 1 1E-8 -> 1 +dqcom508 compare 1 1E-7 -> 1 +dqcom509 compare 1 1E-6 -> 1 +dqcom510 compare 1 1E-5 -> 1 +dqcom511 compare 1 1E-4 -> 1 +dqcom512 compare 1 1E-3 -> 1 +dqcom513 compare 1 1E-2 -> 1 +dqcom514 compare 1 1E-1 -> 1 +dqcom515 compare 1 1E-0 -> 0 +dqcom516 compare 1 1E+1 -> -1 +dqcom517 compare 1 1E+2 -> -1 +dqcom518 compare 1 1E+3 -> -1 +dqcom519 compare 1 1E+4 -> -1 +dqcom521 compare 1 1E+5 -> -1 +dqcom522 compare 1 1E+6 -> -1 +dqcom523 compare 1 1E+7 -> -1 +dqcom524 compare 1 1E+8 -> -1 +dqcom525 compare 1 1E+9 -> -1 +dqcom526 compare 1 1E+10 -> -1 +dqcom527 compare 1 1E+11 -> -1 +dqcom528 compare 1 1E+12 -> -1 +dqcom529 compare 1 1E+13 -> -1 +dqcom530 compare 1 1E+14 -> -1 +dqcom531 compare 1 1E+15 -> -1 +-- LR swap +dqcom540 compare 1E-15 1 -> -1 +dqcom541 compare 1E-14 1 -> -1 +dqcom542 compare 1E-13 1 -> -1 +dqcom543 compare 1E-12 1 -> -1 +dqcom544 compare 1E-11 1 -> -1 +dqcom545 compare 1E-10 1 -> -1 +dqcom546 compare 1E-9 1 -> -1 +dqcom547 compare 1E-8 1 -> -1 +dqcom548 compare 1E-7 1 -> -1 +dqcom549 compare 1E-6 1 -> -1 +dqcom550 compare 1E-5 1 -> -1 +dqcom551 compare 1E-4 1 -> -1 +dqcom552 compare 1E-3 1 -> -1 +dqcom553 compare 1E-2 1 -> -1 +dqcom554 compare 1E-1 1 -> -1 +dqcom555 compare 1E-0 1 -> 0 +dqcom556 compare 1E+1 1 -> 1 +dqcom557 compare 1E+2 1 -> 1 +dqcom558 compare 1E+3 1 -> 1 +dqcom559 compare 1E+4 1 -> 1 +dqcom561 compare 1E+5 1 -> 1 +dqcom562 compare 1E+6 1 -> 1 +dqcom563 compare 1E+7 1 -> 1 +dqcom564 compare 1E+8 1 -> 1 +dqcom565 compare 1E+9 1 -> 1 +dqcom566 compare 1E+10 1 -> 1 +dqcom567 compare 1E+11 1 -> 1 +dqcom568 compare 1E+12 1 -> 1 +dqcom569 compare 1E+13 1 -> 1 +dqcom570 compare 1E+14 1 -> 1 +dqcom571 compare 1E+15 1 -> 1 +-- similar with a useful coefficient, one side only +dqcom580 compare 0.000000987654321 1E-15 -> 1 +dqcom581 compare 0.000000987654321 1E-14 -> 1 +dqcom582 compare 0.000000987654321 1E-13 -> 1 +dqcom583 compare 0.000000987654321 1E-12 -> 1 +dqcom584 compare 0.000000987654321 1E-11 -> 1 +dqcom585 compare 0.000000987654321 1E-10 -> 1 +dqcom586 compare 0.000000987654321 1E-9 -> 1 +dqcom587 compare 0.000000987654321 1E-8 -> 1 +dqcom588 compare 0.000000987654321 1E-7 -> 1 +dqcom589 compare 0.000000987654321 1E-6 -> -1 +dqcom590 compare 0.000000987654321 1E-5 -> -1 +dqcom591 compare 0.000000987654321 1E-4 -> -1 +dqcom592 compare 0.000000987654321 1E-3 -> -1 +dqcom593 compare 0.000000987654321 1E-2 -> -1 +dqcom594 compare 0.000000987654321 1E-1 -> -1 +dqcom595 compare 0.000000987654321 1E-0 -> -1 +dqcom596 compare 0.000000987654321 1E+1 -> -1 +dqcom597 compare 0.000000987654321 1E+2 -> -1 +dqcom598 compare 0.000000987654321 1E+3 -> -1 +dqcom599 compare 0.000000987654321 1E+4 -> -1 + +-- check some unit-y traps +dqcom600 compare 12 12.2345 -> -1 +dqcom601 compare 12.0 12.2345 -> -1 +dqcom602 compare 12.00 12.2345 -> -1 +dqcom603 compare 12.000 12.2345 -> -1 +dqcom604 compare 12.0000 12.2345 -> -1 +dqcom605 compare 12.00000 12.2345 -> -1 +dqcom606 compare 12.000000 12.2345 -> -1 +dqcom607 compare 12.0000000 12.2345 -> -1 +dqcom608 compare 12.00000000 12.2345 -> -1 +dqcom609 compare 12.000000000 12.2345 -> -1 +dqcom610 compare 12.1234 12 -> 1 +dqcom611 compare 12.1234 12.0 -> 1 +dqcom612 compare 12.1234 12.00 -> 1 +dqcom613 compare 12.1234 12.000 -> 1 +dqcom614 compare 12.1234 12.0000 -> 1 +dqcom615 compare 12.1234 12.00000 -> 1 +dqcom616 compare 12.1234 12.000000 -> 1 +dqcom617 compare 12.1234 12.0000000 -> 1 +dqcom618 compare 12.1234 12.00000000 -> 1 +dqcom619 compare 12.1234 12.000000000 -> 1 +dqcom620 compare -12 -12.2345 -> 1 +dqcom621 compare -12.0 -12.2345 -> 1 +dqcom622 compare -12.00 -12.2345 -> 1 +dqcom623 compare -12.000 -12.2345 -> 1 +dqcom624 compare -12.0000 -12.2345 -> 1 +dqcom625 compare -12.00000 -12.2345 -> 1 +dqcom626 compare -12.000000 -12.2345 -> 1 +dqcom627 compare -12.0000000 -12.2345 -> 1 +dqcom628 compare -12.00000000 -12.2345 -> 1 +dqcom629 compare -12.000000000 -12.2345 -> 1 +dqcom630 compare -12.1234 -12 -> -1 +dqcom631 compare -12.1234 -12.0 -> -1 +dqcom632 compare -12.1234 -12.00 -> -1 +dqcom633 compare -12.1234 -12.000 -> -1 +dqcom634 compare -12.1234 -12.0000 -> -1 +dqcom635 compare -12.1234 -12.00000 -> -1 +dqcom636 compare -12.1234 -12.000000 -> -1 +dqcom637 compare -12.1234 -12.0000000 -> -1 +dqcom638 compare -12.1234 -12.00000000 -> -1 +dqcom639 compare -12.1234 -12.000000000 -> -1 + +-- extended zeros +dqcom640 compare 0 0 -> 0 +dqcom641 compare 0 -0 -> 0 +dqcom642 compare 0 -0.0 -> 0 +dqcom643 compare 0 0.0 -> 0 +dqcom644 compare -0 0 -> 0 +dqcom645 compare -0 -0 -> 0 +dqcom646 compare -0 -0.0 -> 0 +dqcom647 compare -0 0.0 -> 0 +dqcom648 compare 0.0 0 -> 0 +dqcom649 compare 0.0 -0 -> 0 +dqcom650 compare 0.0 -0.0 -> 0 +dqcom651 compare 0.0 0.0 -> 0 +dqcom652 compare -0.0 0 -> 0 +dqcom653 compare -0.0 -0 -> 0 +dqcom654 compare -0.0 -0.0 -> 0 +dqcom655 compare -0.0 0.0 -> 0 + +dqcom656 compare -0E1 0.0 -> 0 +dqcom657 compare -0E2 0.0 -> 0 +dqcom658 compare 0E1 0.0 -> 0 +dqcom659 compare 0E2 0.0 -> 0 +dqcom660 compare -0E1 0 -> 0 +dqcom661 compare -0E2 0 -> 0 +dqcom662 compare 0E1 0 -> 0 +dqcom663 compare 0E2 0 -> 0 +dqcom664 compare -0E1 -0E1 -> 0 +dqcom665 compare -0E2 -0E1 -> 0 +dqcom666 compare 0E1 -0E1 -> 0 +dqcom667 compare 0E2 -0E1 -> 0 +dqcom668 compare -0E1 -0E2 -> 0 +dqcom669 compare -0E2 -0E2 -> 0 +dqcom670 compare 0E1 -0E2 -> 0 +dqcom671 compare 0E2 -0E2 -> 0 +dqcom672 compare -0E1 0E1 -> 0 +dqcom673 compare -0E2 0E1 -> 0 +dqcom674 compare 0E1 0E1 -> 0 +dqcom675 compare 0E2 0E1 -> 0 +dqcom676 compare -0E1 0E2 -> 0 +dqcom677 compare -0E2 0E2 -> 0 +dqcom678 compare 0E1 0E2 -> 0 +dqcom679 compare 0E2 0E2 -> 0 + +-- trailing zeros; unit-y +dqcom680 compare 12 12 -> 0 +dqcom681 compare 12 12.0 -> 0 +dqcom682 compare 12 12.00 -> 0 +dqcom683 compare 12 12.000 -> 0 +dqcom684 compare 12 12.0000 -> 0 +dqcom685 compare 12 12.00000 -> 0 +dqcom686 compare 12 12.000000 -> 0 +dqcom687 compare 12 12.0000000 -> 0 +dqcom688 compare 12 12.00000000 -> 0 +dqcom689 compare 12 12.000000000 -> 0 +dqcom690 compare 12 12 -> 0 +dqcom691 compare 12.0 12 -> 0 +dqcom692 compare 12.00 12 -> 0 +dqcom693 compare 12.000 12 -> 0 +dqcom694 compare 12.0000 12 -> 0 +dqcom695 compare 12.00000 12 -> 0 +dqcom696 compare 12.000000 12 -> 0 +dqcom697 compare 12.0000000 12 -> 0 +dqcom698 compare 12.00000000 12 -> 0 +dqcom699 compare 12.000000000 12 -> 0 + +-- first, second, & last digit +dqcom700 compare 1234567899999999999999999990123456 1234567899999999999999999990123455 -> 1 +dqcom701 compare 1234567899999999999999999990123456 1234567899999999999999999990123456 -> 0 +dqcom702 compare 1234567899999999999999999990123456 1234567899999999999999999990123457 -> -1 +dqcom703 compare 1234567899999999999999999990123456 0234567899999999999999999990123456 -> 1 +dqcom704 compare 1234567899999999999999999990123456 1234567899999999999999999990123456 -> 0 +dqcom705 compare 1234567899999999999999999990123456 2234567899999999999999999990123456 -> -1 +dqcom706 compare 1134567899999999999999999990123456 1034567899999999999999999990123456 -> 1 +dqcom707 compare 1134567899999999999999999990123456 1134567899999999999999999990123456 -> 0 +dqcom708 compare 1134567899999999999999999990123456 1234567899999999999999999990123456 -> -1 + +-- miscellaneous +dqcom721 compare 12345678000 1 -> 1 +dqcom722 compare 1 12345678000 -> -1 +dqcom723 compare 1234567800 1 -> 1 +dqcom724 compare 1 1234567800 -> -1 +dqcom725 compare 1234567890 1 -> 1 +dqcom726 compare 1 1234567890 -> -1 +dqcom727 compare 1234567891 1 -> 1 +dqcom728 compare 1 1234567891 -> -1 +dqcom729 compare 12345678901 1 -> 1 +dqcom730 compare 1 12345678901 -> -1 +dqcom731 compare 1234567896 1 -> 1 +dqcom732 compare 1 1234567896 -> -1 + +-- residue cases at lower precision +dqcom740 compare 1 0.9999999 -> 1 +dqcom741 compare 1 0.999999 -> 1 +dqcom742 compare 1 0.99999 -> 1 +dqcom743 compare 1 1.0000 -> 0 +dqcom744 compare 1 1.00001 -> -1 +dqcom745 compare 1 1.000001 -> -1 +dqcom746 compare 1 1.0000001 -> -1 +dqcom750 compare 0.9999999 1 -> -1 +dqcom751 compare 0.999999 1 -> -1 +dqcom752 compare 0.99999 1 -> -1 +dqcom753 compare 1.0000 1 -> 0 +dqcom754 compare 1.00001 1 -> 1 +dqcom755 compare 1.000001 1 -> 1 +dqcom756 compare 1.0000001 1 -> 1 + +-- Specials +dqcom780 compare Inf -Inf -> 1 +dqcom781 compare Inf -1000 -> 1 +dqcom782 compare Inf -1 -> 1 +dqcom783 compare Inf -0 -> 1 +dqcom784 compare Inf 0 -> 1 +dqcom785 compare Inf 1 -> 1 +dqcom786 compare Inf 1000 -> 1 +dqcom787 compare Inf Inf -> 0 +dqcom788 compare -1000 Inf -> -1 +dqcom789 compare -Inf Inf -> -1 +dqcom790 compare -1 Inf -> -1 +dqcom791 compare -0 Inf -> -1 +dqcom792 compare 0 Inf -> -1 +dqcom793 compare 1 Inf -> -1 +dqcom794 compare 1000 Inf -> -1 +dqcom795 compare Inf Inf -> 0 + +dqcom800 compare -Inf -Inf -> 0 +dqcom801 compare -Inf -1000 -> -1 +dqcom802 compare -Inf -1 -> -1 +dqcom803 compare -Inf -0 -> -1 +dqcom804 compare -Inf 0 -> -1 +dqcom805 compare -Inf 1 -> -1 +dqcom806 compare -Inf 1000 -> -1 +dqcom807 compare -Inf Inf -> -1 +dqcom808 compare -Inf -Inf -> 0 +dqcom809 compare -1000 -Inf -> 1 +dqcom810 compare -1 -Inf -> 1 +dqcom811 compare -0 -Inf -> 1 +dqcom812 compare 0 -Inf -> 1 +dqcom813 compare 1 -Inf -> 1 +dqcom814 compare 1000 -Inf -> 1 +dqcom815 compare Inf -Inf -> 1 + +dqcom821 compare NaN -Inf -> NaN +dqcom822 compare NaN -1000 -> NaN +dqcom823 compare NaN -1 -> NaN +dqcom824 compare NaN -0 -> NaN +dqcom825 compare NaN 0 -> NaN +dqcom826 compare NaN 1 -> NaN +dqcom827 compare NaN 1000 -> NaN +dqcom828 compare NaN Inf -> NaN +dqcom829 compare NaN NaN -> NaN +dqcom830 compare -Inf NaN -> NaN +dqcom831 compare -1000 NaN -> NaN +dqcom832 compare -1 NaN -> NaN +dqcom833 compare -0 NaN -> NaN +dqcom834 compare 0 NaN -> NaN +dqcom835 compare 1 NaN -> NaN +dqcom836 compare 1000 NaN -> NaN +dqcom837 compare Inf NaN -> NaN +dqcom838 compare -NaN -NaN -> -NaN +dqcom839 compare +NaN -NaN -> NaN +dqcom840 compare -NaN +NaN -> -NaN + +dqcom841 compare sNaN -Inf -> NaN Invalid_operation +dqcom842 compare sNaN -1000 -> NaN Invalid_operation +dqcom843 compare sNaN -1 -> NaN Invalid_operation +dqcom844 compare sNaN -0 -> NaN Invalid_operation +dqcom845 compare sNaN 0 -> NaN Invalid_operation +dqcom846 compare sNaN 1 -> NaN Invalid_operation +dqcom847 compare sNaN 1000 -> NaN Invalid_operation +dqcom848 compare sNaN NaN -> NaN Invalid_operation +dqcom849 compare sNaN sNaN -> NaN Invalid_operation +dqcom850 compare NaN sNaN -> NaN Invalid_operation +dqcom851 compare -Inf sNaN -> NaN Invalid_operation +dqcom852 compare -1000 sNaN -> NaN Invalid_operation +dqcom853 compare -1 sNaN -> NaN Invalid_operation +dqcom854 compare -0 sNaN -> NaN Invalid_operation +dqcom855 compare 0 sNaN -> NaN Invalid_operation +dqcom856 compare 1 sNaN -> NaN Invalid_operation +dqcom857 compare 1000 sNaN -> NaN Invalid_operation +dqcom858 compare Inf sNaN -> NaN Invalid_operation +dqcom859 compare NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +dqcom860 compare NaN9 -Inf -> NaN9 +dqcom861 compare NaN8 999 -> NaN8 +dqcom862 compare NaN77 Inf -> NaN77 +dqcom863 compare -NaN67 NaN5 -> -NaN67 +dqcom864 compare -Inf -NaN4 -> -NaN4 +dqcom865 compare -999 -NaN33 -> -NaN33 +dqcom866 compare Inf NaN2 -> NaN2 +dqcom867 compare -NaN41 -NaN42 -> -NaN41 +dqcom868 compare +NaN41 -NaN42 -> NaN41 +dqcom869 compare -NaN41 +NaN42 -> -NaN41 +dqcom870 compare +NaN41 +NaN42 -> NaN41 + +dqcom871 compare -sNaN99 -Inf -> -NaN99 Invalid_operation +dqcom872 compare sNaN98 -11 -> NaN98 Invalid_operation +dqcom873 compare sNaN97 NaN -> NaN97 Invalid_operation +dqcom874 compare sNaN16 sNaN94 -> NaN16 Invalid_operation +dqcom875 compare NaN85 sNaN83 -> NaN83 Invalid_operation +dqcom876 compare -Inf sNaN92 -> NaN92 Invalid_operation +dqcom877 compare 088 sNaN81 -> NaN81 Invalid_operation +dqcom878 compare Inf sNaN90 -> NaN90 Invalid_operation +dqcom879 compare NaN -sNaN89 -> -NaN89 Invalid_operation + +-- wide range +dqcom880 compare +1.23456789012345E-0 9E+6144 -> -1 +dqcom881 compare 9E+6144 +1.23456789012345E-0 -> 1 +dqcom882 compare +0.100 9E-6143 -> 1 +dqcom883 compare 9E-6143 +0.100 -> -1 +dqcom885 compare -1.23456789012345E-0 9E+6144 -> -1 +dqcom886 compare 9E+6144 -1.23456789012345E-0 -> 1 +dqcom887 compare -0.100 9E-6143 -> -1 +dqcom888 compare 9E-6143 -0.100 -> 1 + +-- signs +dqcom901 compare 1e+77 1e+11 -> 1 +dqcom902 compare 1e+77 -1e+11 -> 1 +dqcom903 compare -1e+77 1e+11 -> -1 +dqcom904 compare -1e+77 -1e+11 -> -1 +dqcom905 compare 1e-77 1e-11 -> -1 +dqcom906 compare 1e-77 -1e-11 -> 1 +dqcom907 compare -1e-77 1e-11 -> -1 +dqcom908 compare -1e-77 -1e-11 -> 1 + +-- full alignment range, both ways +dqcomp1001 compare 1 1.000000000000000000000000000000000 -> 0 +dqcomp1002 compare 1 1.00000000000000000000000000000000 -> 0 +dqcomp1003 compare 1 1.0000000000000000000000000000000 -> 0 +dqcomp1004 compare 1 1.000000000000000000000000000000 -> 0 +dqcomp1005 compare 1 1.00000000000000000000000000000 -> 0 +dqcomp1006 compare 1 1.0000000000000000000000000000 -> 0 +dqcomp1007 compare 1 1.000000000000000000000000000 -> 0 +dqcomp1008 compare 1 1.00000000000000000000000000 -> 0 +dqcomp1009 compare 1 1.0000000000000000000000000 -> 0 +dqcomp1010 compare 1 1.000000000000000000000000 -> 0 +dqcomp1011 compare 1 1.00000000000000000000000 -> 0 +dqcomp1012 compare 1 1.0000000000000000000000 -> 0 +dqcomp1013 compare 1 1.000000000000000000000 -> 0 +dqcomp1014 compare 1 1.00000000000000000000 -> 0 +dqcomp1015 compare 1 1.0000000000000000000 -> 0 +dqcomp1016 compare 1 1.000000000000000000 -> 0 +dqcomp1017 compare 1 1.00000000000000000 -> 0 +dqcomp1018 compare 1 1.0000000000000000 -> 0 +dqcomp1019 compare 1 1.000000000000000 -> 0 +dqcomp1020 compare 1 1.00000000000000 -> 0 +dqcomp1021 compare 1 1.0000000000000 -> 0 +dqcomp1022 compare 1 1.000000000000 -> 0 +dqcomp1023 compare 1 1.00000000000 -> 0 +dqcomp1024 compare 1 1.0000000000 -> 0 +dqcomp1025 compare 1 1.000000000 -> 0 +dqcomp1026 compare 1 1.00000000 -> 0 +dqcomp1027 compare 1 1.0000000 -> 0 +dqcomp1028 compare 1 1.000000 -> 0 +dqcomp1029 compare 1 1.00000 -> 0 +dqcomp1030 compare 1 1.0000 -> 0 +dqcomp1031 compare 1 1.000 -> 0 +dqcomp1032 compare 1 1.00 -> 0 +dqcomp1033 compare 1 1.0 -> 0 + +dqcomp1041 compare 1.000000000000000000000000000000000 1 -> 0 +dqcomp1042 compare 1.00000000000000000000000000000000 1 -> 0 +dqcomp1043 compare 1.0000000000000000000000000000000 1 -> 0 +dqcomp1044 compare 1.000000000000000000000000000000 1 -> 0 +dqcomp1045 compare 1.00000000000000000000000000000 1 -> 0 +dqcomp1046 compare 1.0000000000000000000000000000 1 -> 0 +dqcomp1047 compare 1.000000000000000000000000000 1 -> 0 +dqcomp1048 compare 1.00000000000000000000000000 1 -> 0 +dqcomp1049 compare 1.0000000000000000000000000 1 -> 0 +dqcomp1050 compare 1.000000000000000000000000 1 -> 0 +dqcomp1051 compare 1.00000000000000000000000 1 -> 0 +dqcomp1052 compare 1.0000000000000000000000 1 -> 0 +dqcomp1053 compare 1.000000000000000000000 1 -> 0 +dqcomp1054 compare 1.00000000000000000000 1 -> 0 +dqcomp1055 compare 1.0000000000000000000 1 -> 0 +dqcomp1056 compare 1.000000000000000000 1 -> 0 +dqcomp1057 compare 1.00000000000000000 1 -> 0 +dqcomp1058 compare 1.0000000000000000 1 -> 0 +dqcomp1059 compare 1.000000000000000 1 -> 0 +dqcomp1060 compare 1.00000000000000 1 -> 0 +dqcomp1061 compare 1.0000000000000 1 -> 0 +dqcomp1062 compare 1.000000000000 1 -> 0 +dqcomp1063 compare 1.00000000000 1 -> 0 +dqcomp1064 compare 1.0000000000 1 -> 0 +dqcomp1065 compare 1.000000000 1 -> 0 +dqcomp1066 compare 1.00000000 1 -> 0 +dqcomp1067 compare 1.0000000 1 -> 0 +dqcomp1068 compare 1.000000 1 -> 0 +dqcomp1069 compare 1.00000 1 -> 0 +dqcomp1070 compare 1.0000 1 -> 0 +dqcomp1071 compare 1.000 1 -> 0 +dqcomp1072 compare 1.00 1 -> 0 +dqcomp1073 compare 1.0 1 -> 0 + +-- check MSD always detected non-zero +dqcomp1080 compare 0 0.000000000000000000000000000000000 -> 0 +dqcomp1081 compare 0 1.000000000000000000000000000000000 -> -1 +dqcomp1082 compare 0 2.000000000000000000000000000000000 -> -1 +dqcomp1083 compare 0 3.000000000000000000000000000000000 -> -1 +dqcomp1084 compare 0 4.000000000000000000000000000000000 -> -1 +dqcomp1085 compare 0 5.000000000000000000000000000000000 -> -1 +dqcomp1086 compare 0 6.000000000000000000000000000000000 -> -1 +dqcomp1087 compare 0 7.000000000000000000000000000000000 -> -1 +dqcomp1088 compare 0 8.000000000000000000000000000000000 -> -1 +dqcomp1089 compare 0 9.000000000000000000000000000000000 -> -1 +dqcomp1090 compare 0.000000000000000000000000000000000 0 -> 0 +dqcomp1091 compare 1.000000000000000000000000000000000 0 -> 1 +dqcomp1092 compare 2.000000000000000000000000000000000 0 -> 1 +dqcomp1093 compare 3.000000000000000000000000000000000 0 -> 1 +dqcomp1094 compare 4.000000000000000000000000000000000 0 -> 1 +dqcomp1095 compare 5.000000000000000000000000000000000 0 -> 1 +dqcomp1096 compare 6.000000000000000000000000000000000 0 -> 1 +dqcomp1097 compare 7.000000000000000000000000000000000 0 -> 1 +dqcomp1098 compare 8.000000000000000000000000000000000 0 -> 1 +dqcomp1099 compare 9.000000000000000000000000000000000 0 -> 1 + +-- Null tests +dqcom990 compare 10 # -> NaN Invalid_operation +dqcom991 compare # 10 -> NaN Invalid_operation Added: python/branches/release25-maint/Lib/test/decimaltestdata/dqCompareSig.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/dqCompareSig.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,647 @@ +------------------------------------------------------------------------ +-- dqCompareSig.decTest -- decQuad comparison; all NaNs signal -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- Note that we cannot assume add/subtract tests cover paths adequately, +-- here, because the code might be quite different (comparison cannot +-- overflow or underflow, so actual subtractions are not necessary). + +-- All operands and results are decQuads. +extended: 1 +clamp: 1 +precision: 34 +maxExponent: 6144 +minExponent: -6143 +rounding: half_even + +-- sanity checks +dqcms001 comparesig -2 -2 -> 0 +dqcms002 comparesig -2 -1 -> -1 +dqcms003 comparesig -2 0 -> -1 +dqcms004 comparesig -2 1 -> -1 +dqcms005 comparesig -2 2 -> -1 +dqcms006 comparesig -1 -2 -> 1 +dqcms007 comparesig -1 -1 -> 0 +dqcms008 comparesig -1 0 -> -1 +dqcms009 comparesig -1 1 -> -1 +dqcms010 comparesig -1 2 -> -1 +dqcms011 comparesig 0 -2 -> 1 +dqcms012 comparesig 0 -1 -> 1 +dqcms013 comparesig 0 0 -> 0 +dqcms014 comparesig 0 1 -> -1 +dqcms015 comparesig 0 2 -> -1 +dqcms016 comparesig 1 -2 -> 1 +dqcms017 comparesig 1 -1 -> 1 +dqcms018 comparesig 1 0 -> 1 +dqcms019 comparesig 1 1 -> 0 +dqcms020 comparesig 1 2 -> -1 +dqcms021 comparesig 2 -2 -> 1 +dqcms022 comparesig 2 -1 -> 1 +dqcms023 comparesig 2 0 -> 1 +dqcms025 comparesig 2 1 -> 1 +dqcms026 comparesig 2 2 -> 0 + +dqcms031 comparesig -20 -20 -> 0 +dqcms032 comparesig -20 -10 -> -1 +dqcms033 comparesig -20 00 -> -1 +dqcms034 comparesig -20 10 -> -1 +dqcms035 comparesig -20 20 -> -1 +dqcms036 comparesig -10 -20 -> 1 +dqcms037 comparesig -10 -10 -> 0 +dqcms038 comparesig -10 00 -> -1 +dqcms039 comparesig -10 10 -> -1 +dqcms040 comparesig -10 20 -> -1 +dqcms041 comparesig 00 -20 -> 1 +dqcms042 comparesig 00 -10 -> 1 +dqcms043 comparesig 00 00 -> 0 +dqcms044 comparesig 00 10 -> -1 +dqcms045 comparesig 00 20 -> -1 +dqcms046 comparesig 10 -20 -> 1 +dqcms047 comparesig 10 -10 -> 1 +dqcms048 comparesig 10 00 -> 1 +dqcms049 comparesig 10 10 -> 0 +dqcms050 comparesig 10 20 -> -1 +dqcms051 comparesig 20 -20 -> 1 +dqcms052 comparesig 20 -10 -> 1 +dqcms053 comparesig 20 00 -> 1 +dqcms055 comparesig 20 10 -> 1 +dqcms056 comparesig 20 20 -> 0 + +dqcms061 comparesig -2.0 -2.0 -> 0 +dqcms062 comparesig -2.0 -1.0 -> -1 +dqcms063 comparesig -2.0 0.0 -> -1 +dqcms064 comparesig -2.0 1.0 -> -1 +dqcms065 comparesig -2.0 2.0 -> -1 +dqcms066 comparesig -1.0 -2.0 -> 1 +dqcms067 comparesig -1.0 -1.0 -> 0 +dqcms068 comparesig -1.0 0.0 -> -1 +dqcms069 comparesig -1.0 1.0 -> -1 +dqcms070 comparesig -1.0 2.0 -> -1 +dqcms071 comparesig 0.0 -2.0 -> 1 +dqcms072 comparesig 0.0 -1.0 -> 1 +dqcms073 comparesig 0.0 0.0 -> 0 +dqcms074 comparesig 0.0 1.0 -> -1 +dqcms075 comparesig 0.0 2.0 -> -1 +dqcms076 comparesig 1.0 -2.0 -> 1 +dqcms077 comparesig 1.0 -1.0 -> 1 +dqcms078 comparesig 1.0 0.0 -> 1 +dqcms079 comparesig 1.0 1.0 -> 0 +dqcms080 comparesig 1.0 2.0 -> -1 +dqcms081 comparesig 2.0 -2.0 -> 1 +dqcms082 comparesig 2.0 -1.0 -> 1 +dqcms083 comparesig 2.0 0.0 -> 1 +dqcms085 comparesig 2.0 1.0 -> 1 +dqcms086 comparesig 2.0 2.0 -> 0 + +-- now some cases which might overflow if subtract were used +dqcms090 comparesig 9.999999999999999999999999999999999E+6144 9.999999999999999999999999999999999E+6144 -> 0 +dqcms091 comparesig -9.999999999999999999999999999999999E+6144 9.999999999999999999999999999999999E+6144 -> -1 +dqcms092 comparesig 9.999999999999999999999999999999999E+6144 -9.999999999999999999999999999999999E+6144 -> 1 +dqcms093 comparesig -9.999999999999999999999999999999999E+6144 -9.999999999999999999999999999999999E+6144 -> 0 + +-- some differing length/exponent cases +dqcms100 comparesig 7.0 7.0 -> 0 +dqcms101 comparesig 7.0 7 -> 0 +dqcms102 comparesig 7 7.0 -> 0 +dqcms103 comparesig 7E+0 7.0 -> 0 +dqcms104 comparesig 70E-1 7.0 -> 0 +dqcms105 comparesig 0.7E+1 7 -> 0 +dqcms106 comparesig 70E-1 7 -> 0 +dqcms107 comparesig 7.0 7E+0 -> 0 +dqcms108 comparesig 7.0 70E-1 -> 0 +dqcms109 comparesig 7 0.7E+1 -> 0 +dqcms110 comparesig 7 70E-1 -> 0 + +dqcms120 comparesig 8.0 7.0 -> 1 +dqcms121 comparesig 8.0 7 -> 1 +dqcms122 comparesig 8 7.0 -> 1 +dqcms123 comparesig 8E+0 7.0 -> 1 +dqcms124 comparesig 80E-1 7.0 -> 1 +dqcms125 comparesig 0.8E+1 7 -> 1 +dqcms126 comparesig 80E-1 7 -> 1 +dqcms127 comparesig 8.0 7E+0 -> 1 +dqcms128 comparesig 8.0 70E-1 -> 1 +dqcms129 comparesig 8 0.7E+1 -> 1 +dqcms130 comparesig 8 70E-1 -> 1 + +dqcms140 comparesig 8.0 9.0 -> -1 +dqcms141 comparesig 8.0 9 -> -1 +dqcms142 comparesig 8 9.0 -> -1 +dqcms143 comparesig 8E+0 9.0 -> -1 +dqcms144 comparesig 80E-1 9.0 -> -1 +dqcms145 comparesig 0.8E+1 9 -> -1 +dqcms146 comparesig 80E-1 9 -> -1 +dqcms147 comparesig 8.0 9E+0 -> -1 +dqcms148 comparesig 8.0 90E-1 -> -1 +dqcms149 comparesig 8 0.9E+1 -> -1 +dqcms150 comparesig 8 90E-1 -> -1 + +-- and again, with sign changes -+ .. +dqcms200 comparesig -7.0 7.0 -> -1 +dqcms201 comparesig -7.0 7 -> -1 +dqcms202 comparesig -7 7.0 -> -1 +dqcms203 comparesig -7E+0 7.0 -> -1 +dqcms204 comparesig -70E-1 7.0 -> -1 +dqcms205 comparesig -0.7E+1 7 -> -1 +dqcms206 comparesig -70E-1 7 -> -1 +dqcms207 comparesig -7.0 7E+0 -> -1 +dqcms208 comparesig -7.0 70E-1 -> -1 +dqcms209 comparesig -7 0.7E+1 -> -1 +dqcms210 comparesig -7 70E-1 -> -1 + +dqcms220 comparesig -8.0 7.0 -> -1 +dqcms221 comparesig -8.0 7 -> -1 +dqcms222 comparesig -8 7.0 -> -1 +dqcms223 comparesig -8E+0 7.0 -> -1 +dqcms224 comparesig -80E-1 7.0 -> -1 +dqcms225 comparesig -0.8E+1 7 -> -1 +dqcms226 comparesig -80E-1 7 -> -1 +dqcms227 comparesig -8.0 7E+0 -> -1 +dqcms228 comparesig -8.0 70E-1 -> -1 +dqcms229 comparesig -8 0.7E+1 -> -1 +dqcms230 comparesig -8 70E-1 -> -1 + +dqcms240 comparesig -8.0 9.0 -> -1 +dqcms241 comparesig -8.0 9 -> -1 +dqcms242 comparesig -8 9.0 -> -1 +dqcms243 comparesig -8E+0 9.0 -> -1 +dqcms244 comparesig -80E-1 9.0 -> -1 +dqcms245 comparesig -0.8E+1 9 -> -1 +dqcms246 comparesig -80E-1 9 -> -1 +dqcms247 comparesig -8.0 9E+0 -> -1 +dqcms248 comparesig -8.0 90E-1 -> -1 +dqcms249 comparesig -8 0.9E+1 -> -1 +dqcms250 comparesig -8 90E-1 -> -1 + +-- and again, with sign changes +- .. +dqcms300 comparesig 7.0 -7.0 -> 1 +dqcms301 comparesig 7.0 -7 -> 1 +dqcms302 comparesig 7 -7.0 -> 1 +dqcms303 comparesig 7E+0 -7.0 -> 1 +dqcms304 comparesig 70E-1 -7.0 -> 1 +dqcms305 comparesig .7E+1 -7 -> 1 +dqcms306 comparesig 70E-1 -7 -> 1 +dqcms307 comparesig 7.0 -7E+0 -> 1 +dqcms308 comparesig 7.0 -70E-1 -> 1 +dqcms309 comparesig 7 -.7E+1 -> 1 +dqcms310 comparesig 7 -70E-1 -> 1 + +dqcms320 comparesig 8.0 -7.0 -> 1 +dqcms321 comparesig 8.0 -7 -> 1 +dqcms322 comparesig 8 -7.0 -> 1 +dqcms323 comparesig 8E+0 -7.0 -> 1 +dqcms324 comparesig 80E-1 -7.0 -> 1 +dqcms325 comparesig .8E+1 -7 -> 1 +dqcms326 comparesig 80E-1 -7 -> 1 +dqcms327 comparesig 8.0 -7E+0 -> 1 +dqcms328 comparesig 8.0 -70E-1 -> 1 +dqcms329 comparesig 8 -.7E+1 -> 1 +dqcms330 comparesig 8 -70E-1 -> 1 + +dqcms340 comparesig 8.0 -9.0 -> 1 +dqcms341 comparesig 8.0 -9 -> 1 +dqcms342 comparesig 8 -9.0 -> 1 +dqcms343 comparesig 8E+0 -9.0 -> 1 +dqcms344 comparesig 80E-1 -9.0 -> 1 +dqcms345 comparesig .8E+1 -9 -> 1 +dqcms346 comparesig 80E-1 -9 -> 1 +dqcms347 comparesig 8.0 -9E+0 -> 1 +dqcms348 comparesig 8.0 -90E-1 -> 1 +dqcms349 comparesig 8 -.9E+1 -> 1 +dqcms350 comparesig 8 -90E-1 -> 1 + +-- and again, with sign changes -- .. +dqcms400 comparesig -7.0 -7.0 -> 0 +dqcms401 comparesig -7.0 -7 -> 0 +dqcms402 comparesig -7 -7.0 -> 0 +dqcms403 comparesig -7E+0 -7.0 -> 0 +dqcms404 comparesig -70E-1 -7.0 -> 0 +dqcms405 comparesig -.7E+1 -7 -> 0 +dqcms406 comparesig -70E-1 -7 -> 0 +dqcms407 comparesig -7.0 -7E+0 -> 0 +dqcms408 comparesig -7.0 -70E-1 -> 0 +dqcms409 comparesig -7 -.7E+1 -> 0 +dqcms410 comparesig -7 -70E-1 -> 0 + +dqcms420 comparesig -8.0 -7.0 -> -1 +dqcms421 comparesig -8.0 -7 -> -1 +dqcms422 comparesig -8 -7.0 -> -1 +dqcms423 comparesig -8E+0 -7.0 -> -1 +dqcms424 comparesig -80E-1 -7.0 -> -1 +dqcms425 comparesig -.8E+1 -7 -> -1 +dqcms426 comparesig -80E-1 -7 -> -1 +dqcms427 comparesig -8.0 -7E+0 -> -1 +dqcms428 comparesig -8.0 -70E-1 -> -1 +dqcms429 comparesig -8 -.7E+1 -> -1 +dqcms430 comparesig -8 -70E-1 -> -1 + +dqcms440 comparesig -8.0 -9.0 -> 1 +dqcms441 comparesig -8.0 -9 -> 1 +dqcms442 comparesig -8 -9.0 -> 1 +dqcms443 comparesig -8E+0 -9.0 -> 1 +dqcms444 comparesig -80E-1 -9.0 -> 1 +dqcms445 comparesig -.8E+1 -9 -> 1 +dqcms446 comparesig -80E-1 -9 -> 1 +dqcms447 comparesig -8.0 -9E+0 -> 1 +dqcms448 comparesig -8.0 -90E-1 -> 1 +dqcms449 comparesig -8 -.9E+1 -> 1 +dqcms450 comparesig -8 -90E-1 -> 1 + + +-- testcases that subtract to lots of zeros at boundaries [pgr] +dqcms473 comparesig 123.9999999999999999994560000000000E-89 123.999999999999999999456E-89 -> 0 +dqcms474 comparesig 123.999999999999999999456000000000E+89 123.999999999999999999456E+89 -> 0 +dqcms475 comparesig 123.99999999999999999945600000000E-89 123.999999999999999999456E-89 -> 0 +dqcms476 comparesig 123.9999999999999999994560000000E+89 123.999999999999999999456E+89 -> 0 +dqcms477 comparesig 123.999999999999999999456000000E-89 123.999999999999999999456E-89 -> 0 +dqcms478 comparesig 123.99999999999999999945600000E+89 123.999999999999999999456E+89 -> 0 +dqcms479 comparesig 123.9999999999999999994560000E-89 123.999999999999999999456E-89 -> 0 +dqcms480 comparesig 123.999999999999999999456000E+89 123.999999999999999999456E+89 -> 0 +dqcms481 comparesig 123.99999999999999999945600E-89 123.999999999999999999456E-89 -> 0 +dqcms482 comparesig 123.9999999999999999994560E+89 123.999999999999999999456E+89 -> 0 +dqcms483 comparesig 123.999999999999999999456E-89 123.999999999999999999456E-89 -> 0 +dqcms487 comparesig 123.999999999999999999456E+89 123.9999999999999999994560000000000E+89 -> 0 +dqcms488 comparesig 123.999999999999999999456E-89 123.999999999999999999456000000000E-89 -> 0 +dqcms489 comparesig 123.999999999999999999456E+89 123.99999999999999999945600000000E+89 -> 0 +dqcms490 comparesig 123.999999999999999999456E-89 123.9999999999999999994560000000E-89 -> 0 +dqcms491 comparesig 123.999999999999999999456E+89 123.999999999999999999456000000E+89 -> 0 +dqcms492 comparesig 123.999999999999999999456E-89 123.99999999999999999945600000E-89 -> 0 +dqcms493 comparesig 123.999999999999999999456E+89 123.9999999999999999994560000E+89 -> 0 +dqcms494 comparesig 123.999999999999999999456E-89 123.999999999999999999456000E-89 -> 0 +dqcms495 comparesig 123.999999999999999999456E+89 123.99999999999999999945600E+89 -> 0 +dqcms496 comparesig 123.999999999999999999456E-89 123.9999999999999999994560E-89 -> 0 +dqcms497 comparesig 123.999999999999999999456E+89 123.999999999999999999456E+89 -> 0 + +-- wide-ranging, around precision; signs equal +dqcms500 comparesig 1 1E-15 -> 1 +dqcms501 comparesig 1 1E-14 -> 1 +dqcms502 comparesig 1 1E-13 -> 1 +dqcms503 comparesig 1 1E-12 -> 1 +dqcms504 comparesig 1 1E-11 -> 1 +dqcms505 comparesig 1 1E-10 -> 1 +dqcms506 comparesig 1 1E-9 -> 1 +dqcms507 comparesig 1 1E-8 -> 1 +dqcms508 comparesig 1 1E-7 -> 1 +dqcms509 comparesig 1 1E-6 -> 1 +dqcms510 comparesig 1 1E-5 -> 1 +dqcms511 comparesig 1 1E-4 -> 1 +dqcms512 comparesig 1 1E-3 -> 1 +dqcms513 comparesig 1 1E-2 -> 1 +dqcms514 comparesig 1 1E-1 -> 1 +dqcms515 comparesig 1 1E-0 -> 0 +dqcms516 comparesig 1 1E+1 -> -1 +dqcms517 comparesig 1 1E+2 -> -1 +dqcms518 comparesig 1 1E+3 -> -1 +dqcms519 comparesig 1 1E+4 -> -1 +dqcms521 comparesig 1 1E+5 -> -1 +dqcms522 comparesig 1 1E+6 -> -1 +dqcms523 comparesig 1 1E+7 -> -1 +dqcms524 comparesig 1 1E+8 -> -1 +dqcms525 comparesig 1 1E+9 -> -1 +dqcms526 comparesig 1 1E+10 -> -1 +dqcms527 comparesig 1 1E+11 -> -1 +dqcms528 comparesig 1 1E+12 -> -1 +dqcms529 comparesig 1 1E+13 -> -1 +dqcms530 comparesig 1 1E+14 -> -1 +dqcms531 comparesig 1 1E+15 -> -1 +-- LR swap +dqcms540 comparesig 1E-15 1 -> -1 +dqcms541 comparesig 1E-14 1 -> -1 +dqcms542 comparesig 1E-13 1 -> -1 +dqcms543 comparesig 1E-12 1 -> -1 +dqcms544 comparesig 1E-11 1 -> -1 +dqcms545 comparesig 1E-10 1 -> -1 +dqcms546 comparesig 1E-9 1 -> -1 +dqcms547 comparesig 1E-8 1 -> -1 +dqcms548 comparesig 1E-7 1 -> -1 +dqcms549 comparesig 1E-6 1 -> -1 +dqcms550 comparesig 1E-5 1 -> -1 +dqcms551 comparesig 1E-4 1 -> -1 +dqcms552 comparesig 1E-3 1 -> -1 +dqcms553 comparesig 1E-2 1 -> -1 +dqcms554 comparesig 1E-1 1 -> -1 +dqcms555 comparesig 1E-0 1 -> 0 +dqcms556 comparesig 1E+1 1 -> 1 +dqcms557 comparesig 1E+2 1 -> 1 +dqcms558 comparesig 1E+3 1 -> 1 +dqcms559 comparesig 1E+4 1 -> 1 +dqcms561 comparesig 1E+5 1 -> 1 +dqcms562 comparesig 1E+6 1 -> 1 +dqcms563 comparesig 1E+7 1 -> 1 +dqcms564 comparesig 1E+8 1 -> 1 +dqcms565 comparesig 1E+9 1 -> 1 +dqcms566 comparesig 1E+10 1 -> 1 +dqcms567 comparesig 1E+11 1 -> 1 +dqcms568 comparesig 1E+12 1 -> 1 +dqcms569 comparesig 1E+13 1 -> 1 +dqcms570 comparesig 1E+14 1 -> 1 +dqcms571 comparesig 1E+15 1 -> 1 +-- similar with a useful coefficient, one side only +dqcms580 comparesig 0.000000987654321 1E-15 -> 1 +dqcms581 comparesig 0.000000987654321 1E-14 -> 1 +dqcms582 comparesig 0.000000987654321 1E-13 -> 1 +dqcms583 comparesig 0.000000987654321 1E-12 -> 1 +dqcms584 comparesig 0.000000987654321 1E-11 -> 1 +dqcms585 comparesig 0.000000987654321 1E-10 -> 1 +dqcms586 comparesig 0.000000987654321 1E-9 -> 1 +dqcms587 comparesig 0.000000987654321 1E-8 -> 1 +dqcms588 comparesig 0.000000987654321 1E-7 -> 1 +dqcms589 comparesig 0.000000987654321 1E-6 -> -1 +dqcms590 comparesig 0.000000987654321 1E-5 -> -1 +dqcms591 comparesig 0.000000987654321 1E-4 -> -1 +dqcms592 comparesig 0.000000987654321 1E-3 -> -1 +dqcms593 comparesig 0.000000987654321 1E-2 -> -1 +dqcms594 comparesig 0.000000987654321 1E-1 -> -1 +dqcms595 comparesig 0.000000987654321 1E-0 -> -1 +dqcms596 comparesig 0.000000987654321 1E+1 -> -1 +dqcms597 comparesig 0.000000987654321 1E+2 -> -1 +dqcms598 comparesig 0.000000987654321 1E+3 -> -1 +dqcms599 comparesig 0.000000987654321 1E+4 -> -1 + +-- check some unit-y traps +dqcms600 comparesig 12 12.2345 -> -1 +dqcms601 comparesig 12.0 12.2345 -> -1 +dqcms602 comparesig 12.00 12.2345 -> -1 +dqcms603 comparesig 12.000 12.2345 -> -1 +dqcms604 comparesig 12.0000 12.2345 -> -1 +dqcms605 comparesig 12.00000 12.2345 -> -1 +dqcms606 comparesig 12.000000 12.2345 -> -1 +dqcms607 comparesig 12.0000000 12.2345 -> -1 +dqcms608 comparesig 12.00000000 12.2345 -> -1 +dqcms609 comparesig 12.000000000 12.2345 -> -1 +dqcms610 comparesig 12.1234 12 -> 1 +dqcms611 comparesig 12.1234 12.0 -> 1 +dqcms612 comparesig 12.1234 12.00 -> 1 +dqcms613 comparesig 12.1234 12.000 -> 1 +dqcms614 comparesig 12.1234 12.0000 -> 1 +dqcms615 comparesig 12.1234 12.00000 -> 1 +dqcms616 comparesig 12.1234 12.000000 -> 1 +dqcms617 comparesig 12.1234 12.0000000 -> 1 +dqcms618 comparesig 12.1234 12.00000000 -> 1 +dqcms619 comparesig 12.1234 12.000000000 -> 1 +dqcms620 comparesig -12 -12.2345 -> 1 +dqcms621 comparesig -12.0 -12.2345 -> 1 +dqcms622 comparesig -12.00 -12.2345 -> 1 +dqcms623 comparesig -12.000 -12.2345 -> 1 +dqcms624 comparesig -12.0000 -12.2345 -> 1 +dqcms625 comparesig -12.00000 -12.2345 -> 1 +dqcms626 comparesig -12.000000 -12.2345 -> 1 +dqcms627 comparesig -12.0000000 -12.2345 -> 1 +dqcms628 comparesig -12.00000000 -12.2345 -> 1 +dqcms629 comparesig -12.000000000 -12.2345 -> 1 +dqcms630 comparesig -12.1234 -12 -> -1 +dqcms631 comparesig -12.1234 -12.0 -> -1 +dqcms632 comparesig -12.1234 -12.00 -> -1 +dqcms633 comparesig -12.1234 -12.000 -> -1 +dqcms634 comparesig -12.1234 -12.0000 -> -1 +dqcms635 comparesig -12.1234 -12.00000 -> -1 +dqcms636 comparesig -12.1234 -12.000000 -> -1 +dqcms637 comparesig -12.1234 -12.0000000 -> -1 +dqcms638 comparesig -12.1234 -12.00000000 -> -1 +dqcms639 comparesig -12.1234 -12.000000000 -> -1 + +-- extended zeros +dqcms640 comparesig 0 0 -> 0 +dqcms641 comparesig 0 -0 -> 0 +dqcms642 comparesig 0 -0.0 -> 0 +dqcms643 comparesig 0 0.0 -> 0 +dqcms644 comparesig -0 0 -> 0 +dqcms645 comparesig -0 -0 -> 0 +dqcms646 comparesig -0 -0.0 -> 0 +dqcms647 comparesig -0 0.0 -> 0 +dqcms648 comparesig 0.0 0 -> 0 +dqcms649 comparesig 0.0 -0 -> 0 +dqcms650 comparesig 0.0 -0.0 -> 0 +dqcms651 comparesig 0.0 0.0 -> 0 +dqcms652 comparesig -0.0 0 -> 0 +dqcms653 comparesig -0.0 -0 -> 0 +dqcms654 comparesig -0.0 -0.0 -> 0 +dqcms655 comparesig -0.0 0.0 -> 0 + +dqcms656 comparesig -0E1 0.0 -> 0 +dqcms657 comparesig -0E2 0.0 -> 0 +dqcms658 comparesig 0E1 0.0 -> 0 +dqcms659 comparesig 0E2 0.0 -> 0 +dqcms660 comparesig -0E1 0 -> 0 +dqcms661 comparesig -0E2 0 -> 0 +dqcms662 comparesig 0E1 0 -> 0 +dqcms663 comparesig 0E2 0 -> 0 +dqcms664 comparesig -0E1 -0E1 -> 0 +dqcms665 comparesig -0E2 -0E1 -> 0 +dqcms666 comparesig 0E1 -0E1 -> 0 +dqcms667 comparesig 0E2 -0E1 -> 0 +dqcms668 comparesig -0E1 -0E2 -> 0 +dqcms669 comparesig -0E2 -0E2 -> 0 +dqcms670 comparesig 0E1 -0E2 -> 0 +dqcms671 comparesig 0E2 -0E2 -> 0 +dqcms672 comparesig -0E1 0E1 -> 0 +dqcms673 comparesig -0E2 0E1 -> 0 +dqcms674 comparesig 0E1 0E1 -> 0 +dqcms675 comparesig 0E2 0E1 -> 0 +dqcms676 comparesig -0E1 0E2 -> 0 +dqcms677 comparesig -0E2 0E2 -> 0 +dqcms678 comparesig 0E1 0E2 -> 0 +dqcms679 comparesig 0E2 0E2 -> 0 + +-- trailing zeros; unit-y +dqcms680 comparesig 12 12 -> 0 +dqcms681 comparesig 12 12.0 -> 0 +dqcms682 comparesig 12 12.00 -> 0 +dqcms683 comparesig 12 12.000 -> 0 +dqcms684 comparesig 12 12.0000 -> 0 +dqcms685 comparesig 12 12.00000 -> 0 +dqcms686 comparesig 12 12.000000 -> 0 +dqcms687 comparesig 12 12.0000000 -> 0 +dqcms688 comparesig 12 12.00000000 -> 0 +dqcms689 comparesig 12 12.000000000 -> 0 +dqcms690 comparesig 12 12 -> 0 +dqcms691 comparesig 12.0 12 -> 0 +dqcms692 comparesig 12.00 12 -> 0 +dqcms693 comparesig 12.000 12 -> 0 +dqcms694 comparesig 12.0000 12 -> 0 +dqcms695 comparesig 12.00000 12 -> 0 +dqcms696 comparesig 12.000000 12 -> 0 +dqcms697 comparesig 12.0000000 12 -> 0 +dqcms698 comparesig 12.00000000 12 -> 0 +dqcms699 comparesig 12.000000000 12 -> 0 + +-- first, second, & last digit +dqcms700 comparesig 1234567899999999999999999990123456 1234567899999999999999999990123455 -> 1 +dqcms701 comparesig 1234567899999999999999999990123456 1234567899999999999999999990123456 -> 0 +dqcms702 comparesig 1234567899999999999999999990123456 1234567899999999999999999990123457 -> -1 +dqcms703 comparesig 1234567899999999999999999990123456 0234567899999999999999999990123456 -> 1 +dqcms704 comparesig 1234567899999999999999999990123456 1234567899999999999999999990123456 -> 0 +dqcms705 comparesig 1234567899999999999999999990123456 2234567899999999999999999990123456 -> -1 +dqcms706 comparesig 1134567899999999999999999990123456 1034567899999999999999999990123456 -> 1 +dqcms707 comparesig 1134567899999999999999999990123456 1134567899999999999999999990123456 -> 0 +dqcms708 comparesig 1134567899999999999999999990123456 1234567899999999999999999990123456 -> -1 + +-- miscellaneous +dqcms721 comparesig 12345678000 1 -> 1 +dqcms722 comparesig 1 12345678000 -> -1 +dqcms723 comparesig 1234567800 1 -> 1 +dqcms724 comparesig 1 1234567800 -> -1 +dqcms725 comparesig 1234567890 1 -> 1 +dqcms726 comparesig 1 1234567890 -> -1 +dqcms727 comparesig 1234567891 1 -> 1 +dqcms728 comparesig 1 1234567891 -> -1 +dqcms729 comparesig 12345678901 1 -> 1 +dqcms730 comparesig 1 12345678901 -> -1 +dqcms731 comparesig 1234567896 1 -> 1 +dqcms732 comparesig 1 1234567896 -> -1 + +-- residue cases at lower precision +dqcms740 comparesig 1 0.9999999 -> 1 +dqcms741 comparesig 1 0.999999 -> 1 +dqcms742 comparesig 1 0.99999 -> 1 +dqcms743 comparesig 1 1.0000 -> 0 +dqcms744 comparesig 1 1.00001 -> -1 +dqcms745 comparesig 1 1.000001 -> -1 +dqcms746 comparesig 1 1.0000001 -> -1 +dqcms750 comparesig 0.9999999 1 -> -1 +dqcms751 comparesig 0.999999 1 -> -1 +dqcms752 comparesig 0.99999 1 -> -1 +dqcms753 comparesig 1.0000 1 -> 0 +dqcms754 comparesig 1.00001 1 -> 1 +dqcms755 comparesig 1.000001 1 -> 1 +dqcms756 comparesig 1.0000001 1 -> 1 + +-- Specials +dqcms780 comparesig Inf -Inf -> 1 +dqcms781 comparesig Inf -1000 -> 1 +dqcms782 comparesig Inf -1 -> 1 +dqcms783 comparesig Inf -0 -> 1 +dqcms784 comparesig Inf 0 -> 1 +dqcms785 comparesig Inf 1 -> 1 +dqcms786 comparesig Inf 1000 -> 1 +dqcms787 comparesig Inf Inf -> 0 +dqcms788 comparesig -1000 Inf -> -1 +dqcms789 comparesig -Inf Inf -> -1 +dqcms790 comparesig -1 Inf -> -1 +dqcms791 comparesig -0 Inf -> -1 +dqcms792 comparesig 0 Inf -> -1 +dqcms793 comparesig 1 Inf -> -1 +dqcms794 comparesig 1000 Inf -> -1 +dqcms795 comparesig Inf Inf -> 0 + +dqcms800 comparesig -Inf -Inf -> 0 +dqcms801 comparesig -Inf -1000 -> -1 +dqcms802 comparesig -Inf -1 -> -1 +dqcms803 comparesig -Inf -0 -> -1 +dqcms804 comparesig -Inf 0 -> -1 +dqcms805 comparesig -Inf 1 -> -1 +dqcms806 comparesig -Inf 1000 -> -1 +dqcms807 comparesig -Inf Inf -> -1 +dqcms808 comparesig -Inf -Inf -> 0 +dqcms809 comparesig -1000 -Inf -> 1 +dqcms810 comparesig -1 -Inf -> 1 +dqcms811 comparesig -0 -Inf -> 1 +dqcms812 comparesig 0 -Inf -> 1 +dqcms813 comparesig 1 -Inf -> 1 +dqcms814 comparesig 1000 -Inf -> 1 +dqcms815 comparesig Inf -Inf -> 1 + +dqcms821 comparesig NaN -Inf -> NaN Invalid_operation +dqcms822 comparesig NaN -1000 -> NaN Invalid_operation +dqcms823 comparesig NaN -1 -> NaN Invalid_operation +dqcms824 comparesig NaN -0 -> NaN Invalid_operation +dqcms825 comparesig NaN 0 -> NaN Invalid_operation +dqcms826 comparesig NaN 1 -> NaN Invalid_operation +dqcms827 comparesig NaN 1000 -> NaN Invalid_operation +dqcms828 comparesig NaN Inf -> NaN Invalid_operation +dqcms829 comparesig NaN NaN -> NaN Invalid_operation +dqcms830 comparesig -Inf NaN -> NaN Invalid_operation +dqcms831 comparesig -1000 NaN -> NaN Invalid_operation +dqcms832 comparesig -1 NaN -> NaN Invalid_operation +dqcms833 comparesig -0 NaN -> NaN Invalid_operation +dqcms834 comparesig 0 NaN -> NaN Invalid_operation +dqcms835 comparesig 1 NaN -> NaN Invalid_operation +dqcms836 comparesig 1000 NaN -> NaN Invalid_operation +dqcms837 comparesig Inf NaN -> NaN Invalid_operation +dqcms838 comparesig -NaN -NaN -> -NaN Invalid_operation +dqcms839 comparesig +NaN -NaN -> NaN Invalid_operation +dqcms840 comparesig -NaN +NaN -> -NaN Invalid_operation + +dqcms841 comparesig sNaN -Inf -> NaN Invalid_operation +dqcms842 comparesig sNaN -1000 -> NaN Invalid_operation +dqcms843 comparesig sNaN -1 -> NaN Invalid_operation +dqcms844 comparesig sNaN -0 -> NaN Invalid_operation +dqcms845 comparesig sNaN 0 -> NaN Invalid_operation +dqcms846 comparesig sNaN 1 -> NaN Invalid_operation +dqcms847 comparesig sNaN 1000 -> NaN Invalid_operation +dqcms848 comparesig sNaN NaN -> NaN Invalid_operation +dqcms849 comparesig sNaN sNaN -> NaN Invalid_operation +dqcms850 comparesig NaN sNaN -> NaN Invalid_operation +dqcms851 comparesig -Inf sNaN -> NaN Invalid_operation +dqcms852 comparesig -1000 sNaN -> NaN Invalid_operation +dqcms853 comparesig -1 sNaN -> NaN Invalid_operation +dqcms854 comparesig -0 sNaN -> NaN Invalid_operation +dqcms855 comparesig 0 sNaN -> NaN Invalid_operation +dqcms856 comparesig 1 sNaN -> NaN Invalid_operation +dqcms857 comparesig 1000 sNaN -> NaN Invalid_operation +dqcms858 comparesig Inf sNaN -> NaN Invalid_operation +dqcms859 comparesig NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +dqcms860 comparesig NaN9 -Inf -> NaN9 Invalid_operation +dqcms861 comparesig NaN8 999 -> NaN8 Invalid_operation +dqcms862 comparesig NaN77 Inf -> NaN77 Invalid_operation +dqcms863 comparesig -NaN67 NaN5 -> -NaN67 Invalid_operation +dqcms864 comparesig -Inf -NaN4 -> -NaN4 Invalid_operation +dqcms865 comparesig -999 -NaN33 -> -NaN33 Invalid_operation +dqcms866 comparesig Inf NaN2 -> NaN2 Invalid_operation +dqcms867 comparesig -NaN41 -NaN42 -> -NaN41 Invalid_operation +dqcms868 comparesig +NaN41 -NaN42 -> NaN41 Invalid_operation +dqcms869 comparesig -NaN41 +NaN42 -> -NaN41 Invalid_operation +dqcms870 comparesig +NaN41 +NaN42 -> NaN41 Invalid_operation + +dqcms871 comparesig -sNaN99 -Inf -> -NaN99 Invalid_operation +dqcms872 comparesig sNaN98 -11 -> NaN98 Invalid_operation +dqcms873 comparesig sNaN97 NaN -> NaN97 Invalid_operation +dqcms874 comparesig sNaN16 sNaN94 -> NaN16 Invalid_operation +dqcms875 comparesig NaN85 sNaN83 -> NaN83 Invalid_operation +dqcms876 comparesig -Inf sNaN92 -> NaN92 Invalid_operation +dqcms877 comparesig 088 sNaN81 -> NaN81 Invalid_operation +dqcms878 comparesig Inf sNaN90 -> NaN90 Invalid_operation +dqcms879 comparesig NaN -sNaN89 -> -NaN89 Invalid_operation + +-- wide range +dqcms880 comparesig +1.23456789012345E-0 9E+6144 -> -1 +dqcms881 comparesig 9E+6144 +1.23456789012345E-0 -> 1 +dqcms882 comparesig +0.100 9E-6143 -> 1 +dqcms883 comparesig 9E-6143 +0.100 -> -1 +dqcms885 comparesig -1.23456789012345E-0 9E+6144 -> -1 +dqcms886 comparesig 9E+6144 -1.23456789012345E-0 -> 1 +dqcms887 comparesig -0.100 9E-6143 -> -1 +dqcms888 comparesig 9E-6143 -0.100 -> 1 + +-- signs +dqcms901 comparesig 1e+77 1e+11 -> 1 +dqcms902 comparesig 1e+77 -1e+11 -> 1 +dqcms903 comparesig -1e+77 1e+11 -> -1 +dqcms904 comparesig -1e+77 -1e+11 -> -1 +dqcms905 comparesig 1e-77 1e-11 -> -1 +dqcms906 comparesig 1e-77 -1e-11 -> 1 +dqcms907 comparesig -1e-77 1e-11 -> -1 +dqcms908 comparesig -1e-77 -1e-11 -> 1 + +-- Null tests +dqcms990 comparesig 10 # -> NaN Invalid_operation +dqcms991 comparesig # 10 -> NaN Invalid_operation Added: python/branches/release25-maint/Lib/test/decimaltestdata/dqCompareTotal.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/dqCompareTotal.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,706 @@ +------------------------------------------------------------------------ +-- dqCompareTotal.decTest -- decQuad comparison using total ordering -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- Note that we cannot assume add/subtract tests cover paths adequately, +-- here, because the code might be quite different (comparison cannot +-- overflow or underflow, so actual subtractions are not necessary). +-- Similarly, comparetotal will have some radically different paths +-- than compare. + +-- All operands and results are decQuads. +extended: 1 +clamp: 1 +precision: 34 +maxExponent: 6144 +minExponent: -6143 +rounding: half_even + +-- sanity checks +dqcot001 comparetotal -2 -2 -> 0 +dqcot002 comparetotal -2 -1 -> -1 +dqcot003 comparetotal -2 0 -> -1 +dqcot004 comparetotal -2 1 -> -1 +dqcot005 comparetotal -2 2 -> -1 +dqcot006 comparetotal -1 -2 -> 1 +dqcot007 comparetotal -1 -1 -> 0 +dqcot008 comparetotal -1 0 -> -1 +dqcot009 comparetotal -1 1 -> -1 +dqcot010 comparetotal -1 2 -> -1 +dqcot011 comparetotal 0 -2 -> 1 +dqcot012 comparetotal 0 -1 -> 1 +dqcot013 comparetotal 0 0 -> 0 +dqcot014 comparetotal 0 1 -> -1 +dqcot015 comparetotal 0 2 -> -1 +dqcot016 comparetotal 1 -2 -> 1 +dqcot017 comparetotal 1 -1 -> 1 +dqcot018 comparetotal 1 0 -> 1 +dqcot019 comparetotal 1 1 -> 0 +dqcot020 comparetotal 1 2 -> -1 +dqcot021 comparetotal 2 -2 -> 1 +dqcot022 comparetotal 2 -1 -> 1 +dqcot023 comparetotal 2 0 -> 1 +dqcot025 comparetotal 2 1 -> 1 +dqcot026 comparetotal 2 2 -> 0 + +dqcot031 comparetotal -20 -20 -> 0 +dqcot032 comparetotal -20 -10 -> -1 +dqcot033 comparetotal -20 00 -> -1 +dqcot034 comparetotal -20 10 -> -1 +dqcot035 comparetotal -20 20 -> -1 +dqcot036 comparetotal -10 -20 -> 1 +dqcot037 comparetotal -10 -10 -> 0 +dqcot038 comparetotal -10 00 -> -1 +dqcot039 comparetotal -10 10 -> -1 +dqcot040 comparetotal -10 20 -> -1 +dqcot041 comparetotal 00 -20 -> 1 +dqcot042 comparetotal 00 -10 -> 1 +dqcot043 comparetotal 00 00 -> 0 +dqcot044 comparetotal 00 10 -> -1 +dqcot045 comparetotal 00 20 -> -1 +dqcot046 comparetotal 10 -20 -> 1 +dqcot047 comparetotal 10 -10 -> 1 +dqcot048 comparetotal 10 00 -> 1 +dqcot049 comparetotal 10 10 -> 0 +dqcot050 comparetotal 10 20 -> -1 +dqcot051 comparetotal 20 -20 -> 1 +dqcot052 comparetotal 20 -10 -> 1 +dqcot053 comparetotal 20 00 -> 1 +dqcot055 comparetotal 20 10 -> 1 +dqcot056 comparetotal 20 20 -> 0 + +dqcot061 comparetotal -2.0 -2.0 -> 0 +dqcot062 comparetotal -2.0 -1.0 -> -1 +dqcot063 comparetotal -2.0 0.0 -> -1 +dqcot064 comparetotal -2.0 1.0 -> -1 +dqcot065 comparetotal -2.0 2.0 -> -1 +dqcot066 comparetotal -1.0 -2.0 -> 1 +dqcot067 comparetotal -1.0 -1.0 -> 0 +dqcot068 comparetotal -1.0 0.0 -> -1 +dqcot069 comparetotal -1.0 1.0 -> -1 +dqcot070 comparetotal -1.0 2.0 -> -1 +dqcot071 comparetotal 0.0 -2.0 -> 1 +dqcot072 comparetotal 0.0 -1.0 -> 1 +dqcot073 comparetotal 0.0 0.0 -> 0 +dqcot074 comparetotal 0.0 1.0 -> -1 +dqcot075 comparetotal 0.0 2.0 -> -1 +dqcot076 comparetotal 1.0 -2.0 -> 1 +dqcot077 comparetotal 1.0 -1.0 -> 1 +dqcot078 comparetotal 1.0 0.0 -> 1 +dqcot079 comparetotal 1.0 1.0 -> 0 +dqcot080 comparetotal 1.0 2.0 -> -1 +dqcot081 comparetotal 2.0 -2.0 -> 1 +dqcot082 comparetotal 2.0 -1.0 -> 1 +dqcot083 comparetotal 2.0 0.0 -> 1 +dqcot085 comparetotal 2.0 1.0 -> 1 +dqcot086 comparetotal 2.0 2.0 -> 0 + +-- now some cases which might overflow if subtract were used +dqcot090 comparetotal 9.99999999999999999999999999999E+6144 9.99999999999999999999999999999E+6144 -> 0 +dqcot091 comparetotal -9.99999999999999999999999999999E+6144 9.99999999999999999999999999999E+6144 -> -1 +dqcot092 comparetotal 9.99999999999999999999999999999E+6144 -9.99999999999999999999999999999E+6144 -> 1 +dqcot093 comparetotal -9.99999999999999999999999999999E+6144 -9.99999999999999999999999999999E+6144 -> 0 + +-- some differing length/exponent cases +-- in this first group, compare would compare all equal +dqcot100 comparetotal 7.0 7.0 -> 0 +dqcot101 comparetotal 7.0 7 -> -1 +dqcot102 comparetotal 7 7.0 -> 1 +dqcot103 comparetotal 7E+0 7.0 -> 1 +dqcot104 comparetotal 70E-1 7.0 -> 0 +dqcot105 comparetotal 0.7E+1 7 -> 0 +dqcot106 comparetotal 70E-1 7 -> -1 +dqcot107 comparetotal 7.0 7E+0 -> -1 +dqcot108 comparetotal 7.0 70E-1 -> 0 +dqcot109 comparetotal 7 0.7E+1 -> 0 +dqcot110 comparetotal 7 70E-1 -> 1 + +dqcot120 comparetotal 8.0 7.0 -> 1 +dqcot121 comparetotal 8.0 7 -> 1 +dqcot122 comparetotal 8 7.0 -> 1 +dqcot123 comparetotal 8E+0 7.0 -> 1 +dqcot124 comparetotal 80E-1 7.0 -> 1 +dqcot125 comparetotal 0.8E+1 7 -> 1 +dqcot126 comparetotal 80E-1 7 -> 1 +dqcot127 comparetotal 8.0 7E+0 -> 1 +dqcot128 comparetotal 8.0 70E-1 -> 1 +dqcot129 comparetotal 8 0.7E+1 -> 1 +dqcot130 comparetotal 8 70E-1 -> 1 + +dqcot140 comparetotal 8.0 9.0 -> -1 +dqcot141 comparetotal 8.0 9 -> -1 +dqcot142 comparetotal 8 9.0 -> -1 +dqcot143 comparetotal 8E+0 9.0 -> -1 +dqcot144 comparetotal 80E-1 9.0 -> -1 +dqcot145 comparetotal 0.8E+1 9 -> -1 +dqcot146 comparetotal 80E-1 9 -> -1 +dqcot147 comparetotal 8.0 9E+0 -> -1 +dqcot148 comparetotal 8.0 90E-1 -> -1 +dqcot149 comparetotal 8 0.9E+1 -> -1 +dqcot150 comparetotal 8 90E-1 -> -1 + +-- and again, with sign changes -+ .. +dqcot200 comparetotal -7.0 7.0 -> -1 +dqcot201 comparetotal -7.0 7 -> -1 +dqcot202 comparetotal -7 7.0 -> -1 +dqcot203 comparetotal -7E+0 7.0 -> -1 +dqcot204 comparetotal -70E-1 7.0 -> -1 +dqcot205 comparetotal -0.7E+1 7 -> -1 +dqcot206 comparetotal -70E-1 7 -> -1 +dqcot207 comparetotal -7.0 7E+0 -> -1 +dqcot208 comparetotal -7.0 70E-1 -> -1 +dqcot209 comparetotal -7 0.7E+1 -> -1 +dqcot210 comparetotal -7 70E-1 -> -1 + +dqcot220 comparetotal -8.0 7.0 -> -1 +dqcot221 comparetotal -8.0 7 -> -1 +dqcot222 comparetotal -8 7.0 -> -1 +dqcot223 comparetotal -8E+0 7.0 -> -1 +dqcot224 comparetotal -80E-1 7.0 -> -1 +dqcot225 comparetotal -0.8E+1 7 -> -1 +dqcot226 comparetotal -80E-1 7 -> -1 +dqcot227 comparetotal -8.0 7E+0 -> -1 +dqcot228 comparetotal -8.0 70E-1 -> -1 +dqcot229 comparetotal -8 0.7E+1 -> -1 +dqcot230 comparetotal -8 70E-1 -> -1 + +dqcot240 comparetotal -8.0 9.0 -> -1 +dqcot241 comparetotal -8.0 9 -> -1 +dqcot242 comparetotal -8 9.0 -> -1 +dqcot243 comparetotal -8E+0 9.0 -> -1 +dqcot244 comparetotal -80E-1 9.0 -> -1 +dqcot245 comparetotal -0.8E+1 9 -> -1 +dqcot246 comparetotal -80E-1 9 -> -1 +dqcot247 comparetotal -8.0 9E+0 -> -1 +dqcot248 comparetotal -8.0 90E-1 -> -1 +dqcot249 comparetotal -8 0.9E+1 -> -1 +dqcot250 comparetotal -8 90E-1 -> -1 + +-- and again, with sign changes +- .. +dqcot300 comparetotal 7.0 -7.0 -> 1 +dqcot301 comparetotal 7.0 -7 -> 1 +dqcot302 comparetotal 7 -7.0 -> 1 +dqcot303 comparetotal 7E+0 -7.0 -> 1 +dqcot304 comparetotal 70E-1 -7.0 -> 1 +dqcot305 comparetotal .7E+1 -7 -> 1 +dqcot306 comparetotal 70E-1 -7 -> 1 +dqcot307 comparetotal 7.0 -7E+0 -> 1 +dqcot308 comparetotal 7.0 -70E-1 -> 1 +dqcot309 comparetotal 7 -.7E+1 -> 1 +dqcot310 comparetotal 7 -70E-1 -> 1 + +dqcot320 comparetotal 8.0 -7.0 -> 1 +dqcot321 comparetotal 8.0 -7 -> 1 +dqcot322 comparetotal 8 -7.0 -> 1 +dqcot323 comparetotal 8E+0 -7.0 -> 1 +dqcot324 comparetotal 80E-1 -7.0 -> 1 +dqcot325 comparetotal .8E+1 -7 -> 1 +dqcot326 comparetotal 80E-1 -7 -> 1 +dqcot327 comparetotal 8.0 -7E+0 -> 1 +dqcot328 comparetotal 8.0 -70E-1 -> 1 +dqcot329 comparetotal 8 -.7E+1 -> 1 +dqcot330 comparetotal 8 -70E-1 -> 1 + +dqcot340 comparetotal 8.0 -9.0 -> 1 +dqcot341 comparetotal 8.0 -9 -> 1 +dqcot342 comparetotal 8 -9.0 -> 1 +dqcot343 comparetotal 8E+0 -9.0 -> 1 +dqcot344 comparetotal 80E-1 -9.0 -> 1 +dqcot345 comparetotal .8E+1 -9 -> 1 +dqcot346 comparetotal 80E-1 -9 -> 1 +dqcot347 comparetotal 8.0 -9E+0 -> 1 +dqcot348 comparetotal 8.0 -90E-1 -> 1 +dqcot349 comparetotal 8 -.9E+1 -> 1 +dqcot350 comparetotal 8 -90E-1 -> 1 + +-- and again, with sign changes -- .. +dqcot400 comparetotal -7.0 -7.0 -> 0 +dqcot401 comparetotal -7.0 -7 -> 1 +dqcot402 comparetotal -7 -7.0 -> -1 +dqcot403 comparetotal -7E+0 -7.0 -> -1 +dqcot404 comparetotal -70E-1 -7.0 -> 0 +dqcot405 comparetotal -.7E+1 -7 -> 0 +dqcot406 comparetotal -70E-1 -7 -> 1 +dqcot407 comparetotal -7.0 -7E+0 -> 1 +dqcot408 comparetotal -7.0 -70E-1 -> 0 +dqcot409 comparetotal -7 -.7E+1 -> 0 +dqcot410 comparetotal -7 -70E-1 -> -1 + +dqcot420 comparetotal -8.0 -7.0 -> -1 +dqcot421 comparetotal -8.0 -7 -> -1 +dqcot422 comparetotal -8 -7.0 -> -1 +dqcot423 comparetotal -8E+0 -7.0 -> -1 +dqcot424 comparetotal -80E-1 -7.0 -> -1 +dqcot425 comparetotal -.8E+1 -7 -> -1 +dqcot426 comparetotal -80E-1 -7 -> -1 +dqcot427 comparetotal -8.0 -7E+0 -> -1 +dqcot428 comparetotal -8.0 -70E-1 -> -1 +dqcot429 comparetotal -8 -.7E+1 -> -1 +dqcot430 comparetotal -8 -70E-1 -> -1 + +dqcot440 comparetotal -8.0 -9.0 -> 1 +dqcot441 comparetotal -8.0 -9 -> 1 +dqcot442 comparetotal -8 -9.0 -> 1 +dqcot443 comparetotal -8E+0 -9.0 -> 1 +dqcot444 comparetotal -80E-1 -9.0 -> 1 +dqcot445 comparetotal -.8E+1 -9 -> 1 +dqcot446 comparetotal -80E-1 -9 -> 1 +dqcot447 comparetotal -8.0 -9E+0 -> 1 +dqcot448 comparetotal -8.0 -90E-1 -> 1 +dqcot449 comparetotal -8 -.9E+1 -> 1 +dqcot450 comparetotal -8 -90E-1 -> 1 + + +-- testcases that subtract to lots of zeros at boundaries [pgr] +dqcot473 comparetotal 123.4560000000000E-89 123.456E-89 -> -1 +dqcot474 comparetotal 123.456000000000E+89 123.456E+89 -> -1 +dqcot475 comparetotal 123.45600000000E-89 123.456E-89 -> -1 +dqcot476 comparetotal 123.4560000000E+89 123.456E+89 -> -1 +dqcot477 comparetotal 123.456000000E-89 123.456E-89 -> -1 +dqcot478 comparetotal 123.45600000E+89 123.456E+89 -> -1 +dqcot479 comparetotal 123.4560000E-89 123.456E-89 -> -1 +dqcot480 comparetotal 123.456000E+89 123.456E+89 -> -1 +dqcot481 comparetotal 123.45600E-89 123.456E-89 -> -1 +dqcot482 comparetotal 123.4560E+89 123.456E+89 -> -1 +dqcot483 comparetotal 123.456E-89 123.456E-89 -> 0 +dqcot487 comparetotal 123.456E+89 123.4560000000000E+89 -> 1 +dqcot488 comparetotal 123.456E-89 123.456000000000E-89 -> 1 +dqcot489 comparetotal 123.456E+89 123.45600000000E+89 -> 1 +dqcot490 comparetotal 123.456E-89 123.4560000000E-89 -> 1 +dqcot491 comparetotal 123.456E+89 123.456000000E+89 -> 1 +dqcot492 comparetotal 123.456E-89 123.45600000E-89 -> 1 +dqcot493 comparetotal 123.456E+89 123.4560000E+89 -> 1 +dqcot494 comparetotal 123.456E-89 123.456000E-89 -> 1 +dqcot495 comparetotal 123.456E+89 123.45600E+89 -> 1 +dqcot496 comparetotal 123.456E-89 123.4560E-89 -> 1 +dqcot497 comparetotal 123.456E+89 123.456E+89 -> 0 + +-- wide-ranging, around precision; signs equal +dqcot498 comparetotal 1 1E-17 -> 1 +dqcot499 comparetotal 1 1E-16 -> 1 +dqcot500 comparetotal 1 1E-15 -> 1 +dqcot501 comparetotal 1 1E-14 -> 1 +dqcot502 comparetotal 1 1E-13 -> 1 +dqcot503 comparetotal 1 1E-12 -> 1 +dqcot504 comparetotal 1 1E-11 -> 1 +dqcot505 comparetotal 1 1E-10 -> 1 +dqcot506 comparetotal 1 1E-9 -> 1 +dqcot507 comparetotal 1 1E-8 -> 1 +dqcot508 comparetotal 1 1E-7 -> 1 +dqcot509 comparetotal 1 1E-6 -> 1 +dqcot510 comparetotal 1 1E-5 -> 1 +dqcot511 comparetotal 1 1E-4 -> 1 +dqcot512 comparetotal 1 1E-3 -> 1 +dqcot513 comparetotal 1 1E-2 -> 1 +dqcot514 comparetotal 1 1E-1 -> 1 +dqcot515 comparetotal 1 1E-0 -> 0 +dqcot516 comparetotal 1 1E+1 -> -1 +dqcot517 comparetotal 1 1E+2 -> -1 +dqcot518 comparetotal 1 1E+3 -> -1 +dqcot519 comparetotal 1 1E+4 -> -1 +dqcot521 comparetotal 1 1E+5 -> -1 +dqcot522 comparetotal 1 1E+6 -> -1 +dqcot523 comparetotal 1 1E+7 -> -1 +dqcot524 comparetotal 1 1E+8 -> -1 +dqcot525 comparetotal 1 1E+9 -> -1 +dqcot526 comparetotal 1 1E+10 -> -1 +dqcot527 comparetotal 1 1E+11 -> -1 +dqcot528 comparetotal 1 1E+12 -> -1 +dqcot529 comparetotal 1 1E+13 -> -1 +dqcot530 comparetotal 1 1E+14 -> -1 +dqcot531 comparetotal 1 1E+15 -> -1 +dqcot532 comparetotal 1 1E+16 -> -1 +dqcot533 comparetotal 1 1E+17 -> -1 +-- LR swap +dqcot538 comparetotal 1E-17 1 -> -1 +dqcot539 comparetotal 1E-16 1 -> -1 +dqcot540 comparetotal 1E-15 1 -> -1 +dqcot541 comparetotal 1E-14 1 -> -1 +dqcot542 comparetotal 1E-13 1 -> -1 +dqcot543 comparetotal 1E-12 1 -> -1 +dqcot544 comparetotal 1E-11 1 -> -1 +dqcot545 comparetotal 1E-10 1 -> -1 +dqcot546 comparetotal 1E-9 1 -> -1 +dqcot547 comparetotal 1E-8 1 -> -1 +dqcot548 comparetotal 1E-7 1 -> -1 +dqcot549 comparetotal 1E-6 1 -> -1 +dqcot550 comparetotal 1E-5 1 -> -1 +dqcot551 comparetotal 1E-4 1 -> -1 +dqcot552 comparetotal 1E-3 1 -> -1 +dqcot553 comparetotal 1E-2 1 -> -1 +dqcot554 comparetotal 1E-1 1 -> -1 +dqcot555 comparetotal 1E-0 1 -> 0 +dqcot556 comparetotal 1E+1 1 -> 1 +dqcot557 comparetotal 1E+2 1 -> 1 +dqcot558 comparetotal 1E+3 1 -> 1 +dqcot559 comparetotal 1E+4 1 -> 1 +dqcot561 comparetotal 1E+5 1 -> 1 +dqcot562 comparetotal 1E+6 1 -> 1 +dqcot563 comparetotal 1E+7 1 -> 1 +dqcot564 comparetotal 1E+8 1 -> 1 +dqcot565 comparetotal 1E+9 1 -> 1 +dqcot566 comparetotal 1E+10 1 -> 1 +dqcot567 comparetotal 1E+11 1 -> 1 +dqcot568 comparetotal 1E+12 1 -> 1 +dqcot569 comparetotal 1E+13 1 -> 1 +dqcot570 comparetotal 1E+14 1 -> 1 +dqcot571 comparetotal 1E+15 1 -> 1 +dqcot572 comparetotal 1E+16 1 -> 1 +dqcot573 comparetotal 1E+17 1 -> 1 +-- similar with a useful coefficient, one side only +dqcot578 comparetotal 0.000000987654321 1E-17 -> 1 +dqcot579 comparetotal 0.000000987654321 1E-16 -> 1 +dqcot580 comparetotal 0.000000987654321 1E-15 -> 1 +dqcot581 comparetotal 0.000000987654321 1E-14 -> 1 +dqcot582 comparetotal 0.000000987654321 1E-13 -> 1 +dqcot583 comparetotal 0.000000987654321 1E-12 -> 1 +dqcot584 comparetotal 0.000000987654321 1E-11 -> 1 +dqcot585 comparetotal 0.000000987654321 1E-10 -> 1 +dqcot586 comparetotal 0.000000987654321 1E-9 -> 1 +dqcot587 comparetotal 0.000000987654321 1E-8 -> 1 +dqcot588 comparetotal 0.000000987654321 1E-7 -> 1 +dqcot589 comparetotal 0.000000987654321 1E-6 -> -1 +dqcot590 comparetotal 0.000000987654321 1E-5 -> -1 +dqcot591 comparetotal 0.000000987654321 1E-4 -> -1 +dqcot592 comparetotal 0.000000987654321 1E-3 -> -1 +dqcot593 comparetotal 0.000000987654321 1E-2 -> -1 +dqcot594 comparetotal 0.000000987654321 1E-1 -> -1 +dqcot595 comparetotal 0.000000987654321 1E-0 -> -1 +dqcot596 comparetotal 0.000000987654321 1E+1 -> -1 +dqcot597 comparetotal 0.000000987654321 1E+2 -> -1 +dqcot598 comparetotal 0.000000987654321 1E+3 -> -1 +dqcot599 comparetotal 0.000000987654321 1E+4 -> -1 + +-- check some unit-y traps +dqcot600 comparetotal 12 12.2345 -> -1 +dqcot601 comparetotal 12.0 12.2345 -> -1 +dqcot602 comparetotal 12.00 12.2345 -> -1 +dqcot603 comparetotal 12.000 12.2345 -> -1 +dqcot604 comparetotal 12.0000 12.2345 -> -1 +dqcot605 comparetotal 12.00000 12.2345 -> -1 +dqcot606 comparetotal 12.000000 12.2345 -> -1 +dqcot607 comparetotal 12.0000000 12.2345 -> -1 +dqcot608 comparetotal 12.00000000 12.2345 -> -1 +dqcot609 comparetotal 12.000000000 12.2345 -> -1 +dqcot610 comparetotal 12.1234 12 -> 1 +dqcot611 comparetotal 12.1234 12.0 -> 1 +dqcot612 comparetotal 12.1234 12.00 -> 1 +dqcot613 comparetotal 12.1234 12.000 -> 1 +dqcot614 comparetotal 12.1234 12.0000 -> 1 +dqcot615 comparetotal 12.1234 12.00000 -> 1 +dqcot616 comparetotal 12.1234 12.000000 -> 1 +dqcot617 comparetotal 12.1234 12.0000000 -> 1 +dqcot618 comparetotal 12.1234 12.00000000 -> 1 +dqcot619 comparetotal 12.1234 12.000000000 -> 1 +dqcot620 comparetotal -12 -12.2345 -> 1 +dqcot621 comparetotal -12.0 -12.2345 -> 1 +dqcot622 comparetotal -12.00 -12.2345 -> 1 +dqcot623 comparetotal -12.000 -12.2345 -> 1 +dqcot624 comparetotal -12.0000 -12.2345 -> 1 +dqcot625 comparetotal -12.00000 -12.2345 -> 1 +dqcot626 comparetotal -12.000000 -12.2345 -> 1 +dqcot627 comparetotal -12.0000000 -12.2345 -> 1 +dqcot628 comparetotal -12.00000000 -12.2345 -> 1 +dqcot629 comparetotal -12.000000000 -12.2345 -> 1 +dqcot630 comparetotal -12.1234 -12 -> -1 +dqcot631 comparetotal -12.1234 -12.0 -> -1 +dqcot632 comparetotal -12.1234 -12.00 -> -1 +dqcot633 comparetotal -12.1234 -12.000 -> -1 +dqcot634 comparetotal -12.1234 -12.0000 -> -1 +dqcot635 comparetotal -12.1234 -12.00000 -> -1 +dqcot636 comparetotal -12.1234 -12.000000 -> -1 +dqcot637 comparetotal -12.1234 -12.0000000 -> -1 +dqcot638 comparetotal -12.1234 -12.00000000 -> -1 +dqcot639 comparetotal -12.1234 -12.000000000 -> -1 + +-- extended zeros +dqcot640 comparetotal 0 0 -> 0 +dqcot641 comparetotal 0 -0 -> 1 +dqcot642 comparetotal 0 -0.0 -> 1 +dqcot643 comparetotal 0 0.0 -> 1 +dqcot644 comparetotal -0 0 -> -1 +dqcot645 comparetotal -0 -0 -> 0 +dqcot646 comparetotal -0 -0.0 -> -1 +dqcot647 comparetotal -0 0.0 -> -1 +dqcot648 comparetotal 0.0 0 -> -1 +dqcot649 comparetotal 0.0 -0 -> 1 +dqcot650 comparetotal 0.0 -0.0 -> 1 +dqcot651 comparetotal 0.0 0.0 -> 0 +dqcot652 comparetotal -0.0 0 -> -1 +dqcot653 comparetotal -0.0 -0 -> 1 +dqcot654 comparetotal -0.0 -0.0 -> 0 +dqcot655 comparetotal -0.0 0.0 -> -1 + +dqcot656 comparetotal -0E1 0.0 -> -1 +dqcot657 comparetotal -0E2 0.0 -> -1 +dqcot658 comparetotal 0E1 0.0 -> 1 +dqcot659 comparetotal 0E2 0.0 -> 1 +dqcot660 comparetotal -0E1 0 -> -1 +dqcot661 comparetotal -0E2 0 -> -1 +dqcot662 comparetotal 0E1 0 -> 1 +dqcot663 comparetotal 0E2 0 -> 1 +dqcot664 comparetotal -0E1 -0E1 -> 0 +dqcot665 comparetotal -0E2 -0E1 -> -1 +dqcot666 comparetotal 0E1 -0E1 -> 1 +dqcot667 comparetotal 0E2 -0E1 -> 1 +dqcot668 comparetotal -0E1 -0E2 -> 1 +dqcot669 comparetotal -0E2 -0E2 -> 0 +dqcot670 comparetotal 0E1 -0E2 -> 1 +dqcot671 comparetotal 0E2 -0E2 -> 1 +dqcot672 comparetotal -0E1 0E1 -> -1 +dqcot673 comparetotal -0E2 0E1 -> -1 +dqcot674 comparetotal 0E1 0E1 -> 0 +dqcot675 comparetotal 0E2 0E1 -> 1 +dqcot676 comparetotal -0E1 0E2 -> -1 +dqcot677 comparetotal -0E2 0E2 -> -1 +dqcot678 comparetotal 0E1 0E2 -> -1 +dqcot679 comparetotal 0E2 0E2 -> 0 + +-- trailing zeros; unit-y +dqcot680 comparetotal 12 12 -> 0 +dqcot681 comparetotal 12 12.0 -> 1 +dqcot682 comparetotal 12 12.00 -> 1 +dqcot683 comparetotal 12 12.000 -> 1 +dqcot684 comparetotal 12 12.0000 -> 1 +dqcot685 comparetotal 12 12.00000 -> 1 +dqcot686 comparetotal 12 12.000000 -> 1 +dqcot687 comparetotal 12 12.0000000 -> 1 +dqcot688 comparetotal 12 12.00000000 -> 1 +dqcot689 comparetotal 12 12.000000000 -> 1 +dqcot690 comparetotal 12 12 -> 0 +dqcot691 comparetotal 12.0 12 -> -1 +dqcot692 comparetotal 12.00 12 -> -1 +dqcot693 comparetotal 12.000 12 -> -1 +dqcot694 comparetotal 12.0000 12 -> -1 +dqcot695 comparetotal 12.00000 12 -> -1 +dqcot696 comparetotal 12.000000 12 -> -1 +dqcot697 comparetotal 12.0000000 12 -> -1 +dqcot698 comparetotal 12.00000000 12 -> -1 +dqcot699 comparetotal 12.000000000 12 -> -1 + +-- old long operand checks +dqcot701 comparetotal 12345678000 1 -> 1 +dqcot702 comparetotal 1 12345678000 -> -1 +dqcot703 comparetotal 1234567800 1 -> 1 +dqcot704 comparetotal 1 1234567800 -> -1 +dqcot705 comparetotal 1234567890 1 -> 1 +dqcot706 comparetotal 1 1234567890 -> -1 +dqcot707 comparetotal 1234567891 1 -> 1 +dqcot708 comparetotal 1 1234567891 -> -1 +dqcot709 comparetotal 12345678901 1 -> 1 +dqcot710 comparetotal 1 12345678901 -> -1 +dqcot711 comparetotal 1234567896 1 -> 1 +dqcot712 comparetotal 1 1234567896 -> -1 +dqcot713 comparetotal -1234567891 1 -> -1 +dqcot714 comparetotal 1 -1234567891 -> 1 +dqcot715 comparetotal -12345678901 1 -> -1 +dqcot716 comparetotal 1 -12345678901 -> 1 +dqcot717 comparetotal -1234567896 1 -> -1 +dqcot718 comparetotal 1 -1234567896 -> 1 + +-- old residue cases +dqcot740 comparetotal 1 0.9999999 -> 1 +dqcot741 comparetotal 1 0.999999 -> 1 +dqcot742 comparetotal 1 0.99999 -> 1 +dqcot743 comparetotal 1 1.0000 -> 1 +dqcot744 comparetotal 1 1.00001 -> -1 +dqcot745 comparetotal 1 1.000001 -> -1 +dqcot746 comparetotal 1 1.0000001 -> -1 +dqcot750 comparetotal 0.9999999 1 -> -1 +dqcot751 comparetotal 0.999999 1 -> -1 +dqcot752 comparetotal 0.99999 1 -> -1 +dqcot753 comparetotal 1.0000 1 -> -1 +dqcot754 comparetotal 1.00001 1 -> 1 +dqcot755 comparetotal 1.000001 1 -> 1 +dqcot756 comparetotal 1.0000001 1 -> 1 + +-- Specials +dqcot780 comparetotal Inf -Inf -> 1 +dqcot781 comparetotal Inf -1000 -> 1 +dqcot782 comparetotal Inf -1 -> 1 +dqcot783 comparetotal Inf -0 -> 1 +dqcot784 comparetotal Inf 0 -> 1 +dqcot785 comparetotal Inf 1 -> 1 +dqcot786 comparetotal Inf 1000 -> 1 +dqcot787 comparetotal Inf Inf -> 0 +dqcot788 comparetotal -1000 Inf -> -1 +dqcot789 comparetotal -Inf Inf -> -1 +dqcot790 comparetotal -1 Inf -> -1 +dqcot791 comparetotal -0 Inf -> -1 +dqcot792 comparetotal 0 Inf -> -1 +dqcot793 comparetotal 1 Inf -> -1 +dqcot794 comparetotal 1000 Inf -> -1 +dqcot795 comparetotal Inf Inf -> 0 + +dqcot800 comparetotal -Inf -Inf -> 0 +dqcot801 comparetotal -Inf -1000 -> -1 +dqcot802 comparetotal -Inf -1 -> -1 +dqcot803 comparetotal -Inf -0 -> -1 +dqcot804 comparetotal -Inf 0 -> -1 +dqcot805 comparetotal -Inf 1 -> -1 +dqcot806 comparetotal -Inf 1000 -> -1 +dqcot807 comparetotal -Inf Inf -> -1 +dqcot808 comparetotal -Inf -Inf -> 0 +dqcot809 comparetotal -1000 -Inf -> 1 +dqcot810 comparetotal -1 -Inf -> 1 +dqcot811 comparetotal -0 -Inf -> 1 +dqcot812 comparetotal 0 -Inf -> 1 +dqcot813 comparetotal 1 -Inf -> 1 +dqcot814 comparetotal 1000 -Inf -> 1 +dqcot815 comparetotal Inf -Inf -> 1 + +dqcot821 comparetotal NaN -Inf -> 1 +dqcot822 comparetotal NaN -1000 -> 1 +dqcot823 comparetotal NaN -1 -> 1 +dqcot824 comparetotal NaN -0 -> 1 +dqcot825 comparetotal NaN 0 -> 1 +dqcot826 comparetotal NaN 1 -> 1 +dqcot827 comparetotal NaN 1000 -> 1 +dqcot828 comparetotal NaN Inf -> 1 +dqcot829 comparetotal NaN NaN -> 0 +dqcot830 comparetotal -Inf NaN -> -1 +dqcot831 comparetotal -1000 NaN -> -1 +dqcot832 comparetotal -1 NaN -> -1 +dqcot833 comparetotal -0 NaN -> -1 +dqcot834 comparetotal 0 NaN -> -1 +dqcot835 comparetotal 1 NaN -> -1 +dqcot836 comparetotal 1000 NaN -> -1 +dqcot837 comparetotal Inf NaN -> -1 +dqcot838 comparetotal -NaN -NaN -> 0 +dqcot839 comparetotal +NaN -NaN -> 1 +dqcot840 comparetotal -NaN +NaN -> -1 + +dqcot841 comparetotal sNaN -sNaN -> 1 +dqcot842 comparetotal sNaN -NaN -> 1 +dqcot843 comparetotal sNaN -Inf -> 1 +dqcot844 comparetotal sNaN -1000 -> 1 +dqcot845 comparetotal sNaN -1 -> 1 +dqcot846 comparetotal sNaN -0 -> 1 +dqcot847 comparetotal sNaN 0 -> 1 +dqcot848 comparetotal sNaN 1 -> 1 +dqcot849 comparetotal sNaN 1000 -> 1 +dqcot850 comparetotal sNaN NaN -> -1 +dqcot851 comparetotal sNaN sNaN -> 0 + +dqcot852 comparetotal -sNaN sNaN -> -1 +dqcot853 comparetotal -NaN sNaN -> -1 +dqcot854 comparetotal -Inf sNaN -> -1 +dqcot855 comparetotal -1000 sNaN -> -1 +dqcot856 comparetotal -1 sNaN -> -1 +dqcot857 comparetotal -0 sNaN -> -1 +dqcot858 comparetotal 0 sNaN -> -1 +dqcot859 comparetotal 1 sNaN -> -1 +dqcot860 comparetotal 1000 sNaN -> -1 +dqcot861 comparetotal Inf sNaN -> -1 +dqcot862 comparetotal NaN sNaN -> 1 +dqcot863 comparetotal sNaN sNaN -> 0 + +dqcot871 comparetotal -sNaN -sNaN -> 0 +dqcot872 comparetotal -sNaN -NaN -> 1 +dqcot873 comparetotal -sNaN -Inf -> -1 +dqcot874 comparetotal -sNaN -1000 -> -1 +dqcot875 comparetotal -sNaN -1 -> -1 +dqcot876 comparetotal -sNaN -0 -> -1 +dqcot877 comparetotal -sNaN 0 -> -1 +dqcot878 comparetotal -sNaN 1 -> -1 +dqcot879 comparetotal -sNaN 1000 -> -1 +dqcot880 comparetotal -sNaN NaN -> -1 +dqcot881 comparetotal -sNaN sNaN -> -1 + +dqcot882 comparetotal -sNaN -sNaN -> 0 +dqcot883 comparetotal -NaN -sNaN -> -1 +dqcot884 comparetotal -Inf -sNaN -> 1 +dqcot885 comparetotal -1000 -sNaN -> 1 +dqcot886 comparetotal -1 -sNaN -> 1 +dqcot887 comparetotal -0 -sNaN -> 1 +dqcot888 comparetotal 0 -sNaN -> 1 +dqcot889 comparetotal 1 -sNaN -> 1 +dqcot890 comparetotal 1000 -sNaN -> 1 +dqcot891 comparetotal Inf -sNaN -> 1 +dqcot892 comparetotal NaN -sNaN -> 1 +dqcot893 comparetotal sNaN -sNaN -> 1 + +-- NaNs with payload +dqcot960 comparetotal NaN9 -Inf -> 1 +dqcot961 comparetotal NaN8 999 -> 1 +dqcot962 comparetotal NaN77 Inf -> 1 +dqcot963 comparetotal -NaN67 NaN5 -> -1 +dqcot964 comparetotal -Inf -NaN4 -> 1 +dqcot965 comparetotal -999 -NaN33 -> 1 +dqcot966 comparetotal Inf NaN2 -> -1 + +dqcot970 comparetotal -NaN41 -NaN42 -> 1 +dqcot971 comparetotal +NaN41 -NaN42 -> 1 +dqcot972 comparetotal -NaN41 +NaN42 -> -1 +dqcot973 comparetotal +NaN41 +NaN42 -> -1 +dqcot974 comparetotal -NaN42 -NaN01 -> -1 +dqcot975 comparetotal +NaN42 -NaN01 -> 1 +dqcot976 comparetotal -NaN42 +NaN01 -> -1 +dqcot977 comparetotal +NaN42 +NaN01 -> 1 + +dqcot980 comparetotal -sNaN771 -sNaN772 -> 1 +dqcot981 comparetotal +sNaN771 -sNaN772 -> 1 +dqcot982 comparetotal -sNaN771 +sNaN772 -> -1 +dqcot983 comparetotal +sNaN771 +sNaN772 -> -1 +dqcot984 comparetotal -sNaN772 -sNaN771 -> -1 +dqcot985 comparetotal +sNaN772 -sNaN771 -> 1 +dqcot986 comparetotal -sNaN772 +sNaN771 -> -1 +dqcot987 comparetotal +sNaN772 +sNaN771 -> 1 + +dqcot991 comparetotal -sNaN99 -Inf -> -1 +dqcot992 comparetotal sNaN98 -11 -> 1 +dqcot993 comparetotal sNaN97 NaN -> -1 +dqcot994 comparetotal sNaN16 sNaN94 -> -1 +dqcot995 comparetotal NaN85 sNaN83 -> 1 +dqcot996 comparetotal -Inf sNaN92 -> -1 +dqcot997 comparetotal 088 sNaN81 -> -1 +dqcot998 comparetotal Inf sNaN90 -> -1 +dqcot999 comparetotal NaN -sNaN89 -> 1 + +-- spread zeros +dqcot1110 comparetotal 0E-6143 0 -> -1 +dqcot1111 comparetotal 0E-6143 -0 -> 1 +dqcot1112 comparetotal -0E-6143 0 -> -1 +dqcot1113 comparetotal -0E-6143 -0 -> 1 +dqcot1114 comparetotal 0E-6143 0E+6144 -> -1 +dqcot1115 comparetotal 0E-6143 -0E+6144 -> 1 +dqcot1116 comparetotal -0E-6143 0E+6144 -> -1 +dqcot1117 comparetotal -0E-6143 -0E+6144 -> 1 +dqcot1118 comparetotal 0 0E+6144 -> -1 +dqcot1119 comparetotal 0 -0E+6144 -> 1 +dqcot1120 comparetotal -0 0E+6144 -> -1 +dqcot1121 comparetotal -0 -0E+6144 -> 1 + +dqcot1130 comparetotal 0E+6144 0 -> 1 +dqcot1131 comparetotal 0E+6144 -0 -> 1 +dqcot1132 comparetotal -0E+6144 0 -> -1 +dqcot1133 comparetotal -0E+6144 -0 -> -1 +dqcot1134 comparetotal 0E+6144 0E-6143 -> 1 +dqcot1135 comparetotal 0E+6144 -0E-6143 -> 1 +dqcot1136 comparetotal -0E+6144 0E-6143 -> -1 +dqcot1137 comparetotal -0E+6144 -0E-6143 -> -1 +dqcot1138 comparetotal 0 0E-6143 -> 1 +dqcot1139 comparetotal 0 -0E-6143 -> 1 +dqcot1140 comparetotal -0 0E-6143 -> -1 +dqcot1141 comparetotal -0 -0E-6143 -> -1 + +-- Null tests +dqcot9990 comparetotal 10 # -> NaN Invalid_operation +dqcot9991 comparetotal # 10 -> NaN Invalid_operation Added: python/branches/release25-maint/Lib/test/decimaltestdata/dqCompareTotalMag.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/dqCompareTotalMag.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,706 @@ +------------------------------------------------------------------------ +-- dqCompareTotalMag.decTest -- decQuad comparison; abs. total order -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- Note that we cannot assume add/subtract tests cover paths adequately, +-- here, because the code might be quite different (comparison cannot +-- overflow or underflow, so actual subtractions are not necessary). +-- Similarly, comparetotal will have some radically different paths +-- than compare. + +-- All operands and results are decQuads. +extended: 1 +clamp: 1 +precision: 34 +maxExponent: 6144 +minExponent: -6143 +rounding: half_even + +-- sanity checks +dqctm001 comparetotmag -2 -2 -> 0 +dqctm002 comparetotmag -2 -1 -> 1 +dqctm003 comparetotmag -2 0 -> 1 +dqctm004 comparetotmag -2 1 -> 1 +dqctm005 comparetotmag -2 2 -> 0 +dqctm006 comparetotmag -1 -2 -> -1 +dqctm007 comparetotmag -1 -1 -> 0 +dqctm008 comparetotmag -1 0 -> 1 +dqctm009 comparetotmag -1 1 -> 0 +dqctm010 comparetotmag -1 2 -> -1 +dqctm011 comparetotmag 0 -2 -> -1 +dqctm012 comparetotmag 0 -1 -> -1 +dqctm013 comparetotmag 0 0 -> 0 +dqctm014 comparetotmag 0 1 -> -1 +dqctm015 comparetotmag 0 2 -> -1 +dqctm016 comparetotmag 1 -2 -> -1 +dqctm017 comparetotmag 1 -1 -> 0 +dqctm018 comparetotmag 1 0 -> 1 +dqctm019 comparetotmag 1 1 -> 0 +dqctm020 comparetotmag 1 2 -> -1 +dqctm021 comparetotmag 2 -2 -> 0 +dqctm022 comparetotmag 2 -1 -> 1 +dqctm023 comparetotmag 2 0 -> 1 +dqctm025 comparetotmag 2 1 -> 1 +dqctm026 comparetotmag 2 2 -> 0 + +dqctm031 comparetotmag -20 -20 -> 0 +dqctm032 comparetotmag -20 -10 -> 1 +dqctm033 comparetotmag -20 00 -> 1 +dqctm034 comparetotmag -20 10 -> 1 +dqctm035 comparetotmag -20 20 -> 0 +dqctm036 comparetotmag -10 -20 -> -1 +dqctm037 comparetotmag -10 -10 -> 0 +dqctm038 comparetotmag -10 00 -> 1 +dqctm039 comparetotmag -10 10 -> 0 +dqctm040 comparetotmag -10 20 -> -1 +dqctm041 comparetotmag 00 -20 -> -1 +dqctm042 comparetotmag 00 -10 -> -1 +dqctm043 comparetotmag 00 00 -> 0 +dqctm044 comparetotmag 00 10 -> -1 +dqctm045 comparetotmag 00 20 -> -1 +dqctm046 comparetotmag 10 -20 -> -1 +dqctm047 comparetotmag 10 -10 -> 0 +dqctm048 comparetotmag 10 00 -> 1 +dqctm049 comparetotmag 10 10 -> 0 +dqctm050 comparetotmag 10 20 -> -1 +dqctm051 comparetotmag 20 -20 -> 0 +dqctm052 comparetotmag 20 -10 -> 1 +dqctm053 comparetotmag 20 00 -> 1 +dqctm055 comparetotmag 20 10 -> 1 +dqctm056 comparetotmag 20 20 -> 0 + +dqctm061 comparetotmag -2.0 -2.0 -> 0 +dqctm062 comparetotmag -2.0 -1.0 -> 1 +dqctm063 comparetotmag -2.0 0.0 -> 1 +dqctm064 comparetotmag -2.0 1.0 -> 1 +dqctm065 comparetotmag -2.0 2.0 -> 0 +dqctm066 comparetotmag -1.0 -2.0 -> -1 +dqctm067 comparetotmag -1.0 -1.0 -> 0 +dqctm068 comparetotmag -1.0 0.0 -> 1 +dqctm069 comparetotmag -1.0 1.0 -> 0 +dqctm070 comparetotmag -1.0 2.0 -> -1 +dqctm071 comparetotmag 0.0 -2.0 -> -1 +dqctm072 comparetotmag 0.0 -1.0 -> -1 +dqctm073 comparetotmag 0.0 0.0 -> 0 +dqctm074 comparetotmag 0.0 1.0 -> -1 +dqctm075 comparetotmag 0.0 2.0 -> -1 +dqctm076 comparetotmag 1.0 -2.0 -> -1 +dqctm077 comparetotmag 1.0 -1.0 -> 0 +dqctm078 comparetotmag 1.0 0.0 -> 1 +dqctm079 comparetotmag 1.0 1.0 -> 0 +dqctm080 comparetotmag 1.0 2.0 -> -1 +dqctm081 comparetotmag 2.0 -2.0 -> 0 +dqctm082 comparetotmag 2.0 -1.0 -> 1 +dqctm083 comparetotmag 2.0 0.0 -> 1 +dqctm085 comparetotmag 2.0 1.0 -> 1 +dqctm086 comparetotmag 2.0 2.0 -> 0 + +-- now some cases which might overflow if subtract were used +dqctm090 comparetotmag 9.99999999999999999999999999999E+6144 9.99999999999999999999999999999E+6144 -> 0 +dqctm091 comparetotmag -9.99999999999999999999999999999E+6144 9.99999999999999999999999999999E+6144 -> 0 +dqctm092 comparetotmag 9.99999999999999999999999999999E+6144 -9.99999999999999999999999999999E+6144 -> 0 +dqctm093 comparetotmag -9.99999999999999999999999999999E+6144 -9.99999999999999999999999999999E+6144 -> 0 + +-- some differing length/exponent cases +-- in this first group, compare would compare all equal +dqctm100 comparetotmag 7.0 7.0 -> 0 +dqctm101 comparetotmag 7.0 7 -> -1 +dqctm102 comparetotmag 7 7.0 -> 1 +dqctm103 comparetotmag 7E+0 7.0 -> 1 +dqctm104 comparetotmag 70E-1 7.0 -> 0 +dqctm105 comparetotmag 0.7E+1 7 -> 0 +dqctm106 comparetotmag 70E-1 7 -> -1 +dqctm107 comparetotmag 7.0 7E+0 -> -1 +dqctm108 comparetotmag 7.0 70E-1 -> 0 +dqctm109 comparetotmag 7 0.7E+1 -> 0 +dqctm110 comparetotmag 7 70E-1 -> 1 + +dqctm120 comparetotmag 8.0 7.0 -> 1 +dqctm121 comparetotmag 8.0 7 -> 1 +dqctm122 comparetotmag 8 7.0 -> 1 +dqctm123 comparetotmag 8E+0 7.0 -> 1 +dqctm124 comparetotmag 80E-1 7.0 -> 1 +dqctm125 comparetotmag 0.8E+1 7 -> 1 +dqctm126 comparetotmag 80E-1 7 -> 1 +dqctm127 comparetotmag 8.0 7E+0 -> 1 +dqctm128 comparetotmag 8.0 70E-1 -> 1 +dqctm129 comparetotmag 8 0.7E+1 -> 1 +dqctm130 comparetotmag 8 70E-1 -> 1 + +dqctm140 comparetotmag 8.0 9.0 -> -1 +dqctm141 comparetotmag 8.0 9 -> -1 +dqctm142 comparetotmag 8 9.0 -> -1 +dqctm143 comparetotmag 8E+0 9.0 -> -1 +dqctm144 comparetotmag 80E-1 9.0 -> -1 +dqctm145 comparetotmag 0.8E+1 9 -> -1 +dqctm146 comparetotmag 80E-1 9 -> -1 +dqctm147 comparetotmag 8.0 9E+0 -> -1 +dqctm148 comparetotmag 8.0 90E-1 -> -1 +dqctm149 comparetotmag 8 0.9E+1 -> -1 +dqctm150 comparetotmag 8 90E-1 -> -1 + +-- and again, with sign changes -+ .. +dqctm200 comparetotmag -7.0 7.0 -> 0 +dqctm201 comparetotmag -7.0 7 -> -1 +dqctm202 comparetotmag -7 7.0 -> 1 +dqctm203 comparetotmag -7E+0 7.0 -> 1 +dqctm204 comparetotmag -70E-1 7.0 -> 0 +dqctm205 comparetotmag -0.7E+1 7 -> 0 +dqctm206 comparetotmag -70E-1 7 -> -1 +dqctm207 comparetotmag -7.0 7E+0 -> -1 +dqctm208 comparetotmag -7.0 70E-1 -> 0 +dqctm209 comparetotmag -7 0.7E+1 -> 0 +dqctm210 comparetotmag -7 70E-1 -> 1 + +dqctm220 comparetotmag -8.0 7.0 -> 1 +dqctm221 comparetotmag -8.0 7 -> 1 +dqctm222 comparetotmag -8 7.0 -> 1 +dqctm223 comparetotmag -8E+0 7.0 -> 1 +dqctm224 comparetotmag -80E-1 7.0 -> 1 +dqctm225 comparetotmag -0.8E+1 7 -> 1 +dqctm226 comparetotmag -80E-1 7 -> 1 +dqctm227 comparetotmag -8.0 7E+0 -> 1 +dqctm228 comparetotmag -8.0 70E-1 -> 1 +dqctm229 comparetotmag -8 0.7E+1 -> 1 +dqctm230 comparetotmag -8 70E-1 -> 1 + +dqctm240 comparetotmag -8.0 9.0 -> -1 +dqctm241 comparetotmag -8.0 9 -> -1 +dqctm242 comparetotmag -8 9.0 -> -1 +dqctm243 comparetotmag -8E+0 9.0 -> -1 +dqctm244 comparetotmag -80E-1 9.0 -> -1 +dqctm245 comparetotmag -0.8E+1 9 -> -1 +dqctm246 comparetotmag -80E-1 9 -> -1 +dqctm247 comparetotmag -8.0 9E+0 -> -1 +dqctm248 comparetotmag -8.0 90E-1 -> -1 +dqctm249 comparetotmag -8 0.9E+1 -> -1 +dqctm250 comparetotmag -8 90E-1 -> -1 + +-- and again, with sign changes +- .. +dqctm300 comparetotmag 7.0 -7.0 -> 0 +dqctm301 comparetotmag 7.0 -7 -> -1 +dqctm302 comparetotmag 7 -7.0 -> 1 +dqctm303 comparetotmag 7E+0 -7.0 -> 1 +dqctm304 comparetotmag 70E-1 -7.0 -> 0 +dqctm305 comparetotmag .7E+1 -7 -> 0 +dqctm306 comparetotmag 70E-1 -7 -> -1 +dqctm307 comparetotmag 7.0 -7E+0 -> -1 +dqctm308 comparetotmag 7.0 -70E-1 -> 0 +dqctm309 comparetotmag 7 -.7E+1 -> 0 +dqctm310 comparetotmag 7 -70E-1 -> 1 + +dqctm320 comparetotmag 8.0 -7.0 -> 1 +dqctm321 comparetotmag 8.0 -7 -> 1 +dqctm322 comparetotmag 8 -7.0 -> 1 +dqctm323 comparetotmag 8E+0 -7.0 -> 1 +dqctm324 comparetotmag 80E-1 -7.0 -> 1 +dqctm325 comparetotmag .8E+1 -7 -> 1 +dqctm326 comparetotmag 80E-1 -7 -> 1 +dqctm327 comparetotmag 8.0 -7E+0 -> 1 +dqctm328 comparetotmag 8.0 -70E-1 -> 1 +dqctm329 comparetotmag 8 -.7E+1 -> 1 +dqctm330 comparetotmag 8 -70E-1 -> 1 + +dqctm340 comparetotmag 8.0 -9.0 -> -1 +dqctm341 comparetotmag 8.0 -9 -> -1 +dqctm342 comparetotmag 8 -9.0 -> -1 +dqctm343 comparetotmag 8E+0 -9.0 -> -1 +dqctm344 comparetotmag 80E-1 -9.0 -> -1 +dqctm345 comparetotmag .8E+1 -9 -> -1 +dqctm346 comparetotmag 80E-1 -9 -> -1 +dqctm347 comparetotmag 8.0 -9E+0 -> -1 +dqctm348 comparetotmag 8.0 -90E-1 -> -1 +dqctm349 comparetotmag 8 -.9E+1 -> -1 +dqctm350 comparetotmag 8 -90E-1 -> -1 + +-- and again, with sign changes -- .. +dqctm400 comparetotmag -7.0 -7.0 -> 0 +dqctm401 comparetotmag -7.0 -7 -> -1 +dqctm402 comparetotmag -7 -7.0 -> 1 +dqctm403 comparetotmag -7E+0 -7.0 -> 1 +dqctm404 comparetotmag -70E-1 -7.0 -> 0 +dqctm405 comparetotmag -.7E+1 -7 -> 0 +dqctm406 comparetotmag -70E-1 -7 -> -1 +dqctm407 comparetotmag -7.0 -7E+0 -> -1 +dqctm408 comparetotmag -7.0 -70E-1 -> 0 +dqctm409 comparetotmag -7 -.7E+1 -> 0 +dqctm410 comparetotmag -7 -70E-1 -> 1 + +dqctm420 comparetotmag -8.0 -7.0 -> 1 +dqctm421 comparetotmag -8.0 -7 -> 1 +dqctm422 comparetotmag -8 -7.0 -> 1 +dqctm423 comparetotmag -8E+0 -7.0 -> 1 +dqctm424 comparetotmag -80E-1 -7.0 -> 1 +dqctm425 comparetotmag -.8E+1 -7 -> 1 +dqctm426 comparetotmag -80E-1 -7 -> 1 +dqctm427 comparetotmag -8.0 -7E+0 -> 1 +dqctm428 comparetotmag -8.0 -70E-1 -> 1 +dqctm429 comparetotmag -8 -.7E+1 -> 1 +dqctm430 comparetotmag -8 -70E-1 -> 1 + +dqctm440 comparetotmag -8.0 -9.0 -> -1 +dqctm441 comparetotmag -8.0 -9 -> -1 +dqctm442 comparetotmag -8 -9.0 -> -1 +dqctm443 comparetotmag -8E+0 -9.0 -> -1 +dqctm444 comparetotmag -80E-1 -9.0 -> -1 +dqctm445 comparetotmag -.8E+1 -9 -> -1 +dqctm446 comparetotmag -80E-1 -9 -> -1 +dqctm447 comparetotmag -8.0 -9E+0 -> -1 +dqctm448 comparetotmag -8.0 -90E-1 -> -1 +dqctm449 comparetotmag -8 -.9E+1 -> -1 +dqctm450 comparetotmag -8 -90E-1 -> -1 + + +-- testcases that subtract to lots of zeros at boundaries [pgr] +dqctm473 comparetotmag 123.4560000000000E-89 123.456E-89 -> -1 +dqctm474 comparetotmag 123.456000000000E+89 123.456E+89 -> -1 +dqctm475 comparetotmag 123.45600000000E-89 123.456E-89 -> -1 +dqctm476 comparetotmag 123.4560000000E+89 123.456E+89 -> -1 +dqctm477 comparetotmag 123.456000000E-89 123.456E-89 -> -1 +dqctm478 comparetotmag 123.45600000E+89 123.456E+89 -> -1 +dqctm479 comparetotmag 123.4560000E-89 123.456E-89 -> -1 +dqctm480 comparetotmag 123.456000E+89 123.456E+89 -> -1 +dqctm481 comparetotmag 123.45600E-89 123.456E-89 -> -1 +dqctm482 comparetotmag 123.4560E+89 123.456E+89 -> -1 +dqctm483 comparetotmag 123.456E-89 123.456E-89 -> 0 +dqctm487 comparetotmag 123.456E+89 123.4560000000000E+89 -> 1 +dqctm488 comparetotmag 123.456E-89 123.456000000000E-89 -> 1 +dqctm489 comparetotmag 123.456E+89 123.45600000000E+89 -> 1 +dqctm490 comparetotmag 123.456E-89 123.4560000000E-89 -> 1 +dqctm491 comparetotmag 123.456E+89 123.456000000E+89 -> 1 +dqctm492 comparetotmag 123.456E-89 123.45600000E-89 -> 1 +dqctm493 comparetotmag 123.456E+89 123.4560000E+89 -> 1 +dqctm494 comparetotmag 123.456E-89 123.456000E-89 -> 1 +dqctm495 comparetotmag 123.456E+89 123.45600E+89 -> 1 +dqctm496 comparetotmag 123.456E-89 123.4560E-89 -> 1 +dqctm497 comparetotmag 123.456E+89 123.456E+89 -> 0 + +-- wide-ranging, around precision; signs equal +dqctm498 comparetotmag 1 1E-17 -> 1 +dqctm499 comparetotmag 1 1E-16 -> 1 +dqctm500 comparetotmag 1 1E-15 -> 1 +dqctm501 comparetotmag 1 1E-14 -> 1 +dqctm502 comparetotmag 1 1E-13 -> 1 +dqctm503 comparetotmag 1 1E-12 -> 1 +dqctm504 comparetotmag 1 1E-11 -> 1 +dqctm505 comparetotmag 1 1E-10 -> 1 +dqctm506 comparetotmag 1 1E-9 -> 1 +dqctm507 comparetotmag 1 1E-8 -> 1 +dqctm508 comparetotmag 1 1E-7 -> 1 +dqctm509 comparetotmag 1 1E-6 -> 1 +dqctm510 comparetotmag 1 1E-5 -> 1 +dqctm511 comparetotmag 1 1E-4 -> 1 +dqctm512 comparetotmag 1 1E-3 -> 1 +dqctm513 comparetotmag 1 1E-2 -> 1 +dqctm514 comparetotmag 1 1E-1 -> 1 +dqctm515 comparetotmag 1 1E-0 -> 0 +dqctm516 comparetotmag 1 1E+1 -> -1 +dqctm517 comparetotmag 1 1E+2 -> -1 +dqctm518 comparetotmag 1 1E+3 -> -1 +dqctm519 comparetotmag 1 1E+4 -> -1 +dqctm521 comparetotmag 1 1E+5 -> -1 +dqctm522 comparetotmag 1 1E+6 -> -1 +dqctm523 comparetotmag 1 1E+7 -> -1 +dqctm524 comparetotmag 1 1E+8 -> -1 +dqctm525 comparetotmag 1 1E+9 -> -1 +dqctm526 comparetotmag 1 1E+10 -> -1 +dqctm527 comparetotmag 1 1E+11 -> -1 +dqctm528 comparetotmag 1 1E+12 -> -1 +dqctm529 comparetotmag 1 1E+13 -> -1 +dqctm530 comparetotmag 1 1E+14 -> -1 +dqctm531 comparetotmag 1 1E+15 -> -1 +dqctm532 comparetotmag 1 1E+16 -> -1 +dqctm533 comparetotmag 1 1E+17 -> -1 +-- LR swap +dqctm538 comparetotmag 1E-17 1 -> -1 +dqctm539 comparetotmag 1E-16 1 -> -1 +dqctm540 comparetotmag 1E-15 1 -> -1 +dqctm541 comparetotmag 1E-14 1 -> -1 +dqctm542 comparetotmag 1E-13 1 -> -1 +dqctm543 comparetotmag 1E-12 1 -> -1 +dqctm544 comparetotmag 1E-11 1 -> -1 +dqctm545 comparetotmag 1E-10 1 -> -1 +dqctm546 comparetotmag 1E-9 1 -> -1 +dqctm547 comparetotmag 1E-8 1 -> -1 +dqctm548 comparetotmag 1E-7 1 -> -1 +dqctm549 comparetotmag 1E-6 1 -> -1 +dqctm550 comparetotmag 1E-5 1 -> -1 +dqctm551 comparetotmag 1E-4 1 -> -1 +dqctm552 comparetotmag 1E-3 1 -> -1 +dqctm553 comparetotmag 1E-2 1 -> -1 +dqctm554 comparetotmag 1E-1 1 -> -1 +dqctm555 comparetotmag 1E-0 1 -> 0 +dqctm556 comparetotmag 1E+1 1 -> 1 +dqctm557 comparetotmag 1E+2 1 -> 1 +dqctm558 comparetotmag 1E+3 1 -> 1 +dqctm559 comparetotmag 1E+4 1 -> 1 +dqctm561 comparetotmag 1E+5 1 -> 1 +dqctm562 comparetotmag 1E+6 1 -> 1 +dqctm563 comparetotmag 1E+7 1 -> 1 +dqctm564 comparetotmag 1E+8 1 -> 1 +dqctm565 comparetotmag 1E+9 1 -> 1 +dqctm566 comparetotmag 1E+10 1 -> 1 +dqctm567 comparetotmag 1E+11 1 -> 1 +dqctm568 comparetotmag 1E+12 1 -> 1 +dqctm569 comparetotmag 1E+13 1 -> 1 +dqctm570 comparetotmag 1E+14 1 -> 1 +dqctm571 comparetotmag 1E+15 1 -> 1 +dqctm572 comparetotmag 1E+16 1 -> 1 +dqctm573 comparetotmag 1E+17 1 -> 1 +-- similar with a useful coefficient, one side only +dqctm578 comparetotmag 0.000000987654321 1E-17 -> 1 +dqctm579 comparetotmag 0.000000987654321 1E-16 -> 1 +dqctm580 comparetotmag 0.000000987654321 1E-15 -> 1 +dqctm581 comparetotmag 0.000000987654321 1E-14 -> 1 +dqctm582 comparetotmag 0.000000987654321 1E-13 -> 1 +dqctm583 comparetotmag 0.000000987654321 1E-12 -> 1 +dqctm584 comparetotmag 0.000000987654321 1E-11 -> 1 +dqctm585 comparetotmag 0.000000987654321 1E-10 -> 1 +dqctm586 comparetotmag 0.000000987654321 1E-9 -> 1 +dqctm587 comparetotmag 0.000000987654321 1E-8 -> 1 +dqctm588 comparetotmag 0.000000987654321 1E-7 -> 1 +dqctm589 comparetotmag 0.000000987654321 1E-6 -> -1 +dqctm590 comparetotmag 0.000000987654321 1E-5 -> -1 +dqctm591 comparetotmag 0.000000987654321 1E-4 -> -1 +dqctm592 comparetotmag 0.000000987654321 1E-3 -> -1 +dqctm593 comparetotmag 0.000000987654321 1E-2 -> -1 +dqctm594 comparetotmag 0.000000987654321 1E-1 -> -1 +dqctm595 comparetotmag 0.000000987654321 1E-0 -> -1 +dqctm596 comparetotmag 0.000000987654321 1E+1 -> -1 +dqctm597 comparetotmag 0.000000987654321 1E+2 -> -1 +dqctm598 comparetotmag 0.000000987654321 1E+3 -> -1 +dqctm599 comparetotmag 0.000000987654321 1E+4 -> -1 + +-- check some unit-y traps +dqctm600 comparetotmag 12 12.2345 -> -1 +dqctm601 comparetotmag 12.0 12.2345 -> -1 +dqctm602 comparetotmag 12.00 12.2345 -> -1 +dqctm603 comparetotmag 12.000 12.2345 -> -1 +dqctm604 comparetotmag 12.0000 12.2345 -> -1 +dqctm605 comparetotmag 12.00000 12.2345 -> -1 +dqctm606 comparetotmag 12.000000 12.2345 -> -1 +dqctm607 comparetotmag 12.0000000 12.2345 -> -1 +dqctm608 comparetotmag 12.00000000 12.2345 -> -1 +dqctm609 comparetotmag 12.000000000 12.2345 -> -1 +dqctm610 comparetotmag 12.1234 12 -> 1 +dqctm611 comparetotmag 12.1234 12.0 -> 1 +dqctm612 comparetotmag 12.1234 12.00 -> 1 +dqctm613 comparetotmag 12.1234 12.000 -> 1 +dqctm614 comparetotmag 12.1234 12.0000 -> 1 +dqctm615 comparetotmag 12.1234 12.00000 -> 1 +dqctm616 comparetotmag 12.1234 12.000000 -> 1 +dqctm617 comparetotmag 12.1234 12.0000000 -> 1 +dqctm618 comparetotmag 12.1234 12.00000000 -> 1 +dqctm619 comparetotmag 12.1234 12.000000000 -> 1 +dqctm620 comparetotmag -12 -12.2345 -> -1 +dqctm621 comparetotmag -12.0 -12.2345 -> -1 +dqctm622 comparetotmag -12.00 -12.2345 -> -1 +dqctm623 comparetotmag -12.000 -12.2345 -> -1 +dqctm624 comparetotmag -12.0000 -12.2345 -> -1 +dqctm625 comparetotmag -12.00000 -12.2345 -> -1 +dqctm626 comparetotmag -12.000000 -12.2345 -> -1 +dqctm627 comparetotmag -12.0000000 -12.2345 -> -1 +dqctm628 comparetotmag -12.00000000 -12.2345 -> -1 +dqctm629 comparetotmag -12.000000000 -12.2345 -> -1 +dqctm630 comparetotmag -12.1234 -12 -> 1 +dqctm631 comparetotmag -12.1234 -12.0 -> 1 +dqctm632 comparetotmag -12.1234 -12.00 -> 1 +dqctm633 comparetotmag -12.1234 -12.000 -> 1 +dqctm634 comparetotmag -12.1234 -12.0000 -> 1 +dqctm635 comparetotmag -12.1234 -12.00000 -> 1 +dqctm636 comparetotmag -12.1234 -12.000000 -> 1 +dqctm637 comparetotmag -12.1234 -12.0000000 -> 1 +dqctm638 comparetotmag -12.1234 -12.00000000 -> 1 +dqctm639 comparetotmag -12.1234 -12.000000000 -> 1 + +-- extended zeros +dqctm640 comparetotmag 0 0 -> 0 +dqctm641 comparetotmag 0 -0 -> 0 +dqctm642 comparetotmag 0 -0.0 -> 1 +dqctm643 comparetotmag 0 0.0 -> 1 +dqctm644 comparetotmag -0 0 -> 0 +dqctm645 comparetotmag -0 -0 -> 0 +dqctm646 comparetotmag -0 -0.0 -> 1 +dqctm647 comparetotmag -0 0.0 -> 1 +dqctm648 comparetotmag 0.0 0 -> -1 +dqctm649 comparetotmag 0.0 -0 -> -1 +dqctm650 comparetotmag 0.0 -0.0 -> 0 +dqctm651 comparetotmag 0.0 0.0 -> 0 +dqctm652 comparetotmag -0.0 0 -> -1 +dqctm653 comparetotmag -0.0 -0 -> -1 +dqctm654 comparetotmag -0.0 -0.0 -> 0 +dqctm655 comparetotmag -0.0 0.0 -> 0 + +dqctm656 comparetotmag -0E1 0.0 -> 1 +dqctm657 comparetotmag -0E2 0.0 -> 1 +dqctm658 comparetotmag 0E1 0.0 -> 1 +dqctm659 comparetotmag 0E2 0.0 -> 1 +dqctm660 comparetotmag -0E1 0 -> 1 +dqctm661 comparetotmag -0E2 0 -> 1 +dqctm662 comparetotmag 0E1 0 -> 1 +dqctm663 comparetotmag 0E2 0 -> 1 +dqctm664 comparetotmag -0E1 -0E1 -> 0 +dqctm665 comparetotmag -0E2 -0E1 -> 1 +dqctm666 comparetotmag 0E1 -0E1 -> 0 +dqctm667 comparetotmag 0E2 -0E1 -> 1 +dqctm668 comparetotmag -0E1 -0E2 -> -1 +dqctm669 comparetotmag -0E2 -0E2 -> 0 +dqctm670 comparetotmag 0E1 -0E2 -> -1 +dqctm671 comparetotmag 0E2 -0E2 -> 0 +dqctm672 comparetotmag -0E1 0E1 -> 0 +dqctm673 comparetotmag -0E2 0E1 -> 1 +dqctm674 comparetotmag 0E1 0E1 -> 0 +dqctm675 comparetotmag 0E2 0E1 -> 1 +dqctm676 comparetotmag -0E1 0E2 -> -1 +dqctm677 comparetotmag -0E2 0E2 -> 0 +dqctm678 comparetotmag 0E1 0E2 -> -1 +dqctm679 comparetotmag 0E2 0E2 -> 0 + +-- trailing zeros; unit-y +dqctm680 comparetotmag 12 12 -> 0 +dqctm681 comparetotmag 12 12.0 -> 1 +dqctm682 comparetotmag 12 12.00 -> 1 +dqctm683 comparetotmag 12 12.000 -> 1 +dqctm684 comparetotmag 12 12.0000 -> 1 +dqctm685 comparetotmag 12 12.00000 -> 1 +dqctm686 comparetotmag 12 12.000000 -> 1 +dqctm687 comparetotmag 12 12.0000000 -> 1 +dqctm688 comparetotmag 12 12.00000000 -> 1 +dqctm689 comparetotmag 12 12.000000000 -> 1 +dqctm690 comparetotmag 12 12 -> 0 +dqctm691 comparetotmag 12.0 12 -> -1 +dqctm692 comparetotmag 12.00 12 -> -1 +dqctm693 comparetotmag 12.000 12 -> -1 +dqctm694 comparetotmag 12.0000 12 -> -1 +dqctm695 comparetotmag 12.00000 12 -> -1 +dqctm696 comparetotmag 12.000000 12 -> -1 +dqctm697 comparetotmag 12.0000000 12 -> -1 +dqctm698 comparetotmag 12.00000000 12 -> -1 +dqctm699 comparetotmag 12.000000000 12 -> -1 + +-- old long operand checks +dqctm701 comparetotmag 12345678000 1 -> 1 +dqctm702 comparetotmag 1 12345678000 -> -1 +dqctm703 comparetotmag 1234567800 1 -> 1 +dqctm704 comparetotmag 1 1234567800 -> -1 +dqctm705 comparetotmag 1234567890 1 -> 1 +dqctm706 comparetotmag 1 1234567890 -> -1 +dqctm707 comparetotmag 1234567891 1 -> 1 +dqctm708 comparetotmag 1 1234567891 -> -1 +dqctm709 comparetotmag 12345678901 1 -> 1 +dqctm710 comparetotmag 1 12345678901 -> -1 +dqctm711 comparetotmag 1234567896 1 -> 1 +dqctm712 comparetotmag 1 1234567896 -> -1 +dqctm713 comparetotmag -1234567891 1 -> 1 +dqctm714 comparetotmag 1 -1234567891 -> -1 +dqctm715 comparetotmag -12345678901 1 -> 1 +dqctm716 comparetotmag 1 -12345678901 -> -1 +dqctm717 comparetotmag -1234567896 1 -> 1 +dqctm718 comparetotmag 1 -1234567896 -> -1 + +-- old residue cases +dqctm740 comparetotmag 1 0.9999999 -> 1 +dqctm741 comparetotmag 1 0.999999 -> 1 +dqctm742 comparetotmag 1 0.99999 -> 1 +dqctm743 comparetotmag 1 1.0000 -> 1 +dqctm744 comparetotmag 1 1.00001 -> -1 +dqctm745 comparetotmag 1 1.000001 -> -1 +dqctm746 comparetotmag 1 1.0000001 -> -1 +dqctm750 comparetotmag 0.9999999 1 -> -1 +dqctm751 comparetotmag 0.999999 1 -> -1 +dqctm752 comparetotmag 0.99999 1 -> -1 +dqctm753 comparetotmag 1.0000 1 -> -1 +dqctm754 comparetotmag 1.00001 1 -> 1 +dqctm755 comparetotmag 1.000001 1 -> 1 +dqctm756 comparetotmag 1.0000001 1 -> 1 + +-- Specials +dqctm780 comparetotmag Inf -Inf -> 0 +dqctm781 comparetotmag Inf -1000 -> 1 +dqctm782 comparetotmag Inf -1 -> 1 +dqctm783 comparetotmag Inf -0 -> 1 +dqctm784 comparetotmag Inf 0 -> 1 +dqctm785 comparetotmag Inf 1 -> 1 +dqctm786 comparetotmag Inf 1000 -> 1 +dqctm787 comparetotmag Inf Inf -> 0 +dqctm788 comparetotmag -1000 Inf -> -1 +dqctm789 comparetotmag -Inf Inf -> 0 +dqctm790 comparetotmag -1 Inf -> -1 +dqctm791 comparetotmag -0 Inf -> -1 +dqctm792 comparetotmag 0 Inf -> -1 +dqctm793 comparetotmag 1 Inf -> -1 +dqctm794 comparetotmag 1000 Inf -> -1 +dqctm795 comparetotmag Inf Inf -> 0 + +dqctm800 comparetotmag -Inf -Inf -> 0 +dqctm801 comparetotmag -Inf -1000 -> 1 +dqctm802 comparetotmag -Inf -1 -> 1 +dqctm803 comparetotmag -Inf -0 -> 1 +dqctm804 comparetotmag -Inf 0 -> 1 +dqctm805 comparetotmag -Inf 1 -> 1 +dqctm806 comparetotmag -Inf 1000 -> 1 +dqctm807 comparetotmag -Inf Inf -> 0 +dqctm808 comparetotmag -Inf -Inf -> 0 +dqctm809 comparetotmag -1000 -Inf -> -1 +dqctm810 comparetotmag -1 -Inf -> -1 +dqctm811 comparetotmag -0 -Inf -> -1 +dqctm812 comparetotmag 0 -Inf -> -1 +dqctm813 comparetotmag 1 -Inf -> -1 +dqctm814 comparetotmag 1000 -Inf -> -1 +dqctm815 comparetotmag Inf -Inf -> 0 + +dqctm821 comparetotmag NaN -Inf -> 1 +dqctm822 comparetotmag NaN -1000 -> 1 +dqctm823 comparetotmag NaN -1 -> 1 +dqctm824 comparetotmag NaN -0 -> 1 +dqctm825 comparetotmag NaN 0 -> 1 +dqctm826 comparetotmag NaN 1 -> 1 +dqctm827 comparetotmag NaN 1000 -> 1 +dqctm828 comparetotmag NaN Inf -> 1 +dqctm829 comparetotmag NaN NaN -> 0 +dqctm830 comparetotmag -Inf NaN -> -1 +dqctm831 comparetotmag -1000 NaN -> -1 +dqctm832 comparetotmag -1 NaN -> -1 +dqctm833 comparetotmag -0 NaN -> -1 +dqctm834 comparetotmag 0 NaN -> -1 +dqctm835 comparetotmag 1 NaN -> -1 +dqctm836 comparetotmag 1000 NaN -> -1 +dqctm837 comparetotmag Inf NaN -> -1 +dqctm838 comparetotmag -NaN -NaN -> 0 +dqctm839 comparetotmag +NaN -NaN -> 0 +dqctm840 comparetotmag -NaN +NaN -> 0 + +dqctm841 comparetotmag sNaN -sNaN -> 0 +dqctm842 comparetotmag sNaN -NaN -> -1 +dqctm843 comparetotmag sNaN -Inf -> 1 +dqctm844 comparetotmag sNaN -1000 -> 1 +dqctm845 comparetotmag sNaN -1 -> 1 +dqctm846 comparetotmag sNaN -0 -> 1 +dqctm847 comparetotmag sNaN 0 -> 1 +dqctm848 comparetotmag sNaN 1 -> 1 +dqctm849 comparetotmag sNaN 1000 -> 1 +dqctm850 comparetotmag sNaN NaN -> -1 +dqctm851 comparetotmag sNaN sNaN -> 0 + +dqctm852 comparetotmag -sNaN sNaN -> 0 +dqctm853 comparetotmag -NaN sNaN -> 1 +dqctm854 comparetotmag -Inf sNaN -> -1 +dqctm855 comparetotmag -1000 sNaN -> -1 +dqctm856 comparetotmag -1 sNaN -> -1 +dqctm857 comparetotmag -0 sNaN -> -1 +dqctm858 comparetotmag 0 sNaN -> -1 +dqctm859 comparetotmag 1 sNaN -> -1 +dqctm860 comparetotmag 1000 sNaN -> -1 +dqctm861 comparetotmag Inf sNaN -> -1 +dqctm862 comparetotmag NaN sNaN -> 1 +dqctm863 comparetotmag sNaN sNaN -> 0 + +dqctm871 comparetotmag -sNaN -sNaN -> 0 +dqctm872 comparetotmag -sNaN -NaN -> -1 +dqctm873 comparetotmag -sNaN -Inf -> 1 +dqctm874 comparetotmag -sNaN -1000 -> 1 +dqctm875 comparetotmag -sNaN -1 -> 1 +dqctm876 comparetotmag -sNaN -0 -> 1 +dqctm877 comparetotmag -sNaN 0 -> 1 +dqctm878 comparetotmag -sNaN 1 -> 1 +dqctm879 comparetotmag -sNaN 1000 -> 1 +dqctm880 comparetotmag -sNaN NaN -> -1 +dqctm881 comparetotmag -sNaN sNaN -> 0 + +dqctm882 comparetotmag -sNaN -sNaN -> 0 +dqctm883 comparetotmag -NaN -sNaN -> 1 +dqctm884 comparetotmag -Inf -sNaN -> -1 +dqctm885 comparetotmag -1000 -sNaN -> -1 +dqctm886 comparetotmag -1 -sNaN -> -1 +dqctm887 comparetotmag -0 -sNaN -> -1 +dqctm888 comparetotmag 0 -sNaN -> -1 +dqctm889 comparetotmag 1 -sNaN -> -1 +dqctm890 comparetotmag 1000 -sNaN -> -1 +dqctm891 comparetotmag Inf -sNaN -> -1 +dqctm892 comparetotmag NaN -sNaN -> 1 +dqctm893 comparetotmag sNaN -sNaN -> 0 + +-- NaNs with payload +dqctm960 comparetotmag NaN9 -Inf -> 1 +dqctm961 comparetotmag NaN8 999 -> 1 +dqctm962 comparetotmag NaN77 Inf -> 1 +dqctm963 comparetotmag -NaN67 NaN5 -> 1 +dqctm964 comparetotmag -Inf -NaN4 -> -1 +dqctm965 comparetotmag -999 -NaN33 -> -1 +dqctm966 comparetotmag Inf NaN2 -> -1 + +dqctm970 comparetotmag -NaN41 -NaN42 -> -1 +dqctm971 comparetotmag +NaN41 -NaN42 -> -1 +dqctm972 comparetotmag -NaN41 +NaN42 -> -1 +dqctm973 comparetotmag +NaN41 +NaN42 -> -1 +dqctm974 comparetotmag -NaN42 -NaN01 -> 1 +dqctm975 comparetotmag +NaN42 -NaN01 -> 1 +dqctm976 comparetotmag -NaN42 +NaN01 -> 1 +dqctm977 comparetotmag +NaN42 +NaN01 -> 1 + +dqctm980 comparetotmag -sNaN771 -sNaN772 -> -1 +dqctm981 comparetotmag +sNaN771 -sNaN772 -> -1 +dqctm982 comparetotmag -sNaN771 +sNaN772 -> -1 +dqctm983 comparetotmag +sNaN771 +sNaN772 -> -1 +dqctm984 comparetotmag -sNaN772 -sNaN771 -> 1 +dqctm985 comparetotmag +sNaN772 -sNaN771 -> 1 +dqctm986 comparetotmag -sNaN772 +sNaN771 -> 1 +dqctm987 comparetotmag +sNaN772 +sNaN771 -> 1 + +dqctm991 comparetotmag -sNaN99 -Inf -> 1 +dqctm992 comparetotmag sNaN98 -11 -> 1 +dqctm993 comparetotmag sNaN97 NaN -> -1 +dqctm994 comparetotmag sNaN16 sNaN94 -> -1 +dqctm995 comparetotmag NaN85 sNaN83 -> 1 +dqctm996 comparetotmag -Inf sNaN92 -> -1 +dqctm997 comparetotmag 088 sNaN81 -> -1 +dqctm998 comparetotmag Inf sNaN90 -> -1 +dqctm999 comparetotmag NaN -sNaN89 -> 1 + +-- spread zeros +dqctm1110 comparetotmag 0E-6143 0 -> -1 +dqctm1111 comparetotmag 0E-6143 -0 -> -1 +dqctm1112 comparetotmag -0E-6143 0 -> -1 +dqctm1113 comparetotmag -0E-6143 -0 -> -1 +dqctm1114 comparetotmag 0E-6143 0E+6144 -> -1 +dqctm1115 comparetotmag 0E-6143 -0E+6144 -> -1 +dqctm1116 comparetotmag -0E-6143 0E+6144 -> -1 +dqctm1117 comparetotmag -0E-6143 -0E+6144 -> -1 +dqctm1118 comparetotmag 0 0E+6144 -> -1 +dqctm1119 comparetotmag 0 -0E+6144 -> -1 +dqctm1120 comparetotmag -0 0E+6144 -> -1 +dqctm1121 comparetotmag -0 -0E+6144 -> -1 + +dqctm1130 comparetotmag 0E+6144 0 -> 1 +dqctm1131 comparetotmag 0E+6144 -0 -> 1 +dqctm1132 comparetotmag -0E+6144 0 -> 1 +dqctm1133 comparetotmag -0E+6144 -0 -> 1 +dqctm1134 comparetotmag 0E+6144 0E-6143 -> 1 +dqctm1135 comparetotmag 0E+6144 -0E-6143 -> 1 +dqctm1136 comparetotmag -0E+6144 0E-6143 -> 1 +dqctm1137 comparetotmag -0E+6144 -0E-6143 -> 1 +dqctm1138 comparetotmag 0 0E-6143 -> 1 +dqctm1139 comparetotmag 0 -0E-6143 -> 1 +dqctm1140 comparetotmag -0 0E-6143 -> 1 +dqctm1141 comparetotmag -0 -0E-6143 -> 1 + +-- Null tests +dqctm9990 comparetotmag 10 # -> NaN Invalid_operation +dqctm9991 comparetotmag # 10 -> NaN Invalid_operation Added: python/branches/release25-maint/Lib/test/decimaltestdata/dqCopy.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/dqCopy.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,88 @@ +------------------------------------------------------------------------ +-- dqCopy.decTest -- quiet decQuad copy -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- All operands and results are decQuads. +extended: 1 +clamp: 1 +precision: 34 +maxExponent: 6144 +minExponent: -6143 +rounding: half_even + +-- Sanity check +dqcpy001 copy +7.50 -> 7.50 + +-- Infinities +dqcpy011 copy Infinity -> Infinity +dqcpy012 copy -Infinity -> -Infinity + +-- NaNs, 0 payload +dqcpy021 copy NaN -> NaN +dqcpy022 copy -NaN -> -NaN +dqcpy023 copy sNaN -> sNaN +dqcpy024 copy -sNaN -> -sNaN + +-- NaNs, non-0 payload +dqcpy031 copy NaN10 -> NaN10 +dqcpy032 copy -NaN10 -> -NaN10 +dqcpy033 copy sNaN10 -> sNaN10 +dqcpy034 copy -sNaN10 -> -sNaN10 +dqcpy035 copy NaN7 -> NaN7 +dqcpy036 copy -NaN7 -> -NaN7 +dqcpy037 copy sNaN101 -> sNaN101 +dqcpy038 copy -sNaN101 -> -sNaN101 + +-- finites +dqcpy101 copy 7 -> 7 +dqcpy102 copy -7 -> -7 +dqcpy103 copy 75 -> 75 +dqcpy104 copy -75 -> -75 +dqcpy105 copy 7.50 -> 7.50 +dqcpy106 copy -7.50 -> -7.50 +dqcpy107 copy 7.500 -> 7.500 +dqcpy108 copy -7.500 -> -7.500 + +-- zeros +dqcpy111 copy 0 -> 0 +dqcpy112 copy -0 -> -0 +dqcpy113 copy 0E+4 -> 0E+4 +dqcpy114 copy -0E+4 -> -0E+4 +dqcpy115 copy 0.0000 -> 0.0000 +dqcpy116 copy -0.0000 -> -0.0000 +dqcpy117 copy 0E-141 -> 0E-141 +dqcpy118 copy -0E-141 -> -0E-141 + +-- full coefficients, alternating bits +dqcpy121 copy 2682682682682682682682682682682682 -> 2682682682682682682682682682682682 +dqcpy122 copy -2682682682682682682682682682682682 -> -2682682682682682682682682682682682 +dqcpy123 copy 1341341341341341341341341341341341 -> 1341341341341341341341341341341341 +dqcpy124 copy -1341341341341341341341341341341341 -> -1341341341341341341341341341341341 + +-- Nmax, Nmin, Ntiny +dqcpy131 copy 9.999999999999999999999999999999999E+6144 -> 9.999999999999999999999999999999999E+6144 +dqcpy132 copy 1E-6143 -> 1E-6143 +dqcpy133 copy 1.000000000000000000000000000000000E-6143 -> 1.000000000000000000000000000000000E-6143 +dqcpy134 copy 1E-6176 -> 1E-6176 + +dqcpy135 copy -1E-6176 -> -1E-6176 +dqcpy136 copy -1.000000000000000000000000000000000E-6143 -> -1.000000000000000000000000000000000E-6143 +dqcpy137 copy -1E-6143 -> -1E-6143 +dqcpy138 copy -9.999999999999999999999999999999999E+6144 -> -9.999999999999999999999999999999999E+6144 Added: python/branches/release25-maint/Lib/test/decimaltestdata/dqCopyAbs.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/dqCopyAbs.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,88 @@ +------------------------------------------------------------------------ +-- dqCopyAbs.decTest -- quiet decQuad copy and set sign to zero -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- All operands and results are decQuads. +extended: 1 +clamp: 1 +precision: 34 +maxExponent: 6144 +minExponent: -6143 +rounding: half_even + +-- Sanity check +dqcpa001 copyabs +7.50 -> 7.50 + +-- Infinities +dqcpa011 copyabs Infinity -> Infinity +dqcpa012 copyabs -Infinity -> Infinity + +-- NaNs, 0 payload +dqcpa021 copyabs NaN -> NaN +dqcpa022 copyabs -NaN -> NaN +dqcpa023 copyabs sNaN -> sNaN +dqcpa024 copyabs -sNaN -> sNaN + +-- NaNs, non-0 payload +dqcpa031 copyabs NaN10 -> NaN10 +dqcpa032 copyabs -NaN15 -> NaN15 +dqcpa033 copyabs sNaN15 -> sNaN15 +dqcpa034 copyabs -sNaN10 -> sNaN10 +dqcpa035 copyabs NaN7 -> NaN7 +dqcpa036 copyabs -NaN7 -> NaN7 +dqcpa037 copyabs sNaN101 -> sNaN101 +dqcpa038 copyabs -sNaN101 -> sNaN101 + +-- finites +dqcpa101 copyabs 7 -> 7 +dqcpa102 copyabs -7 -> 7 +dqcpa103 copyabs 75 -> 75 +dqcpa104 copyabs -75 -> 75 +dqcpa105 copyabs 7.10 -> 7.10 +dqcpa106 copyabs -7.10 -> 7.10 +dqcpa107 copyabs 7.500 -> 7.500 +dqcpa108 copyabs -7.500 -> 7.500 + +-- zeros +dqcpa111 copyabs 0 -> 0 +dqcpa112 copyabs -0 -> 0 +dqcpa113 copyabs 0E+6 -> 0E+6 +dqcpa114 copyabs -0E+6 -> 0E+6 +dqcpa115 copyabs 0.0000 -> 0.0000 +dqcpa116 copyabs -0.0000 -> 0.0000 +dqcpa117 copyabs 0E-141 -> 0E-141 +dqcpa118 copyabs -0E-141 -> 0E-141 + +-- full coefficients, alternating bits +dqcpa121 copyabs 2682682682682682682682682682682682 -> 2682682682682682682682682682682682 +dqcpa122 copyabs -2682682682682682682682682682682682 -> 2682682682682682682682682682682682 +dqcpa123 copyabs 1341341341341341341341341341341341 -> 1341341341341341341341341341341341 +dqcpa124 copyabs -1341341341341341341341341341341341 -> 1341341341341341341341341341341341 + +-- Nmax, Nmin, Ntiny +dqcpa131 copyabs 9.999999999999999999999999999999999E+6144 -> 9.999999999999999999999999999999999E+6144 +dqcpa132 copyabs 1E-6143 -> 1E-6143 +dqcpa133 copyabs 1.000000000000000000000000000000000E-6143 -> 1.000000000000000000000000000000000E-6143 +dqcpa134 copyabs 1E-6176 -> 1E-6176 + +dqcpa135 copyabs -1E-6176 -> 1E-6176 +dqcpa136 copyabs -1.000000000000000000000000000000000E-6143 -> 1.000000000000000000000000000000000E-6143 +dqcpa137 copyabs -1E-6143 -> 1E-6143 +dqcpa138 copyabs -9.999999999999999999999999999999999E+6144 -> 9.999999999999999999999999999999999E+6144 Added: python/branches/release25-maint/Lib/test/decimaltestdata/dqCopyNegate.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/dqCopyNegate.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,88 @@ +------------------------------------------------------------------------ +-- dqCopyNegate.decTest -- quiet decQuad copy and negate -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- All operands and results are decQuads. +extended: 1 +clamp: 1 +precision: 34 +maxExponent: 6144 +minExponent: -6143 +rounding: half_even + +-- Sanity check +dqcpn001 copynegate +7.50 -> -7.50 + +-- Infinities +dqcpn011 copynegate Infinity -> -Infinity +dqcpn012 copynegate -Infinity -> Infinity + +-- NaNs, 0 payload +dqcpn021 copynegate NaN -> -NaN +dqcpn022 copynegate -NaN -> NaN +dqcpn023 copynegate sNaN -> -sNaN +dqcpn024 copynegate -sNaN -> sNaN + +-- NaNs, non-0 payload +dqcpn031 copynegate NaN13 -> -NaN13 +dqcpn032 copynegate -NaN13 -> NaN13 +dqcpn033 copynegate sNaN13 -> -sNaN13 +dqcpn034 copynegate -sNaN13 -> sNaN13 +dqcpn035 copynegate NaN70 -> -NaN70 +dqcpn036 copynegate -NaN70 -> NaN70 +dqcpn037 copynegate sNaN101 -> -sNaN101 +dqcpn038 copynegate -sNaN101 -> sNaN101 + +-- finites +dqcpn101 copynegate 7 -> -7 +dqcpn102 copynegate -7 -> 7 +dqcpn103 copynegate 75 -> -75 +dqcpn104 copynegate -75 -> 75 +dqcpn105 copynegate 7.50 -> -7.50 +dqcpn106 copynegate -7.50 -> 7.50 +dqcpn107 copynegate 7.500 -> -7.500 +dqcpn108 copynegate -7.500 -> 7.500 + +-- zeros +dqcpn111 copynegate 0 -> -0 +dqcpn112 copynegate -0 -> 0 +dqcpn113 copynegate 0E+4 -> -0E+4 +dqcpn114 copynegate -0E+4 -> 0E+4 +dqcpn115 copynegate 0.0000 -> -0.0000 +dqcpn116 copynegate -0.0000 -> 0.0000 +dqcpn117 copynegate 0E-141 -> -0E-141 +dqcpn118 copynegate -0E-141 -> 0E-141 + +-- full coefficients, alternating bits +dqcpn121 copynegate 2682682682682682682682682682682682 -> -2682682682682682682682682682682682 +dqcpn122 copynegate -2682682682682682682682682682682682 -> 2682682682682682682682682682682682 +dqcpn123 copynegate 1341341341341341341341341341341341 -> -1341341341341341341341341341341341 +dqcpn124 copynegate -1341341341341341341341341341341341 -> 1341341341341341341341341341341341 + +-- Nmax, Nmin, Ntiny +dqcpn131 copynegate 9.999999999999999999999999999999999E+6144 -> -9.999999999999999999999999999999999E+6144 +dqcpn132 copynegate 1E-6143 -> -1E-6143 +dqcpn133 copynegate 1.000000000000000000000000000000000E-6143 -> -1.000000000000000000000000000000000E-6143 +dqcpn134 copynegate 1E-6176 -> -1E-6176 + +dqcpn135 copynegate -1E-6176 -> 1E-6176 +dqcpn136 copynegate -1.000000000000000000000000000000000E-6143 -> 1.000000000000000000000000000000000E-6143 +dqcpn137 copynegate -1E-6143 -> 1E-6143 +dqcpn138 copynegate -9.999999999999999999999999999999999E+6144 -> 9.999999999999999999999999999999999E+6144 Added: python/branches/release25-maint/Lib/test/decimaltestdata/dqCopySign.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/dqCopySign.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,175 @@ +------------------------------------------------------------------------ +-- dqCopySign.decTest -- quiet decQuad copy with sign from rhs -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- All operands and results are decQuads. +extended: 1 +clamp: 1 +precision: 34 +maxExponent: 6144 +minExponent: -6143 +rounding: half_even + +-- Sanity check +dqcps001 copysign +7.50 11 -> 7.50 + +-- Infinities +dqcps011 copysign Infinity 11 -> Infinity +dqcps012 copysign -Infinity 11 -> Infinity + +-- NaNs, 0 payload +dqcps021 copysign NaN 11 -> NaN +dqcps022 copysign -NaN 11 -> NaN +dqcps023 copysign sNaN 11 -> sNaN +dqcps024 copysign -sNaN 11 -> sNaN + +-- NaNs, non-0 payload +dqcps031 copysign NaN10 11 -> NaN10 +dqcps032 copysign -NaN10 11 -> NaN10 +dqcps033 copysign sNaN10 11 -> sNaN10 +dqcps034 copysign -sNaN10 11 -> sNaN10 +dqcps035 copysign NaN7 11 -> NaN7 +dqcps036 copysign -NaN7 11 -> NaN7 +dqcps037 copysign sNaN101 11 -> sNaN101 +dqcps038 copysign -sNaN101 11 -> sNaN101 + +-- finites +dqcps101 copysign 7 11 -> 7 +dqcps102 copysign -7 11 -> 7 +dqcps103 copysign 75 11 -> 75 +dqcps104 copysign -75 11 -> 75 +dqcps105 copysign 7.50 11 -> 7.50 +dqcps106 copysign -7.50 11 -> 7.50 +dqcps107 copysign 7.500 11 -> 7.500 +dqcps108 copysign -7.500 11 -> 7.500 + +-- zeros +dqcps111 copysign 0 11 -> 0 +dqcps112 copysign -0 11 -> 0 +dqcps113 copysign 0E+4 11 -> 0E+4 +dqcps114 copysign -0E+4 11 -> 0E+4 +dqcps115 copysign 0.0000 11 -> 0.0000 +dqcps116 copysign -0.0000 11 -> 0.0000 +dqcps117 copysign 0E-141 11 -> 0E-141 +dqcps118 copysign -0E-141 11 -> 0E-141 + +-- full coefficients, alternating bits +dqcps121 copysign 2682682682682682682682682682682682 8 -> 2682682682682682682682682682682682 +dqcps122 copysign -2682682682682682682682682682682682 8 -> 2682682682682682682682682682682682 +dqcps123 copysign 1341341341341341341341341341341341 8 -> 1341341341341341341341341341341341 +dqcps124 copysign -1341341341341341341341341341341341 8 -> 1341341341341341341341341341341341 + +-- Nmax, Nmin, Ntiny +dqcps131 copysign 9.999999999999999999999999999999999E+6144 8 -> 9.999999999999999999999999999999999E+6144 +dqcps132 copysign 1E-6143 8 -> 1E-6143 +dqcps133 copysign 1.000000000000000000000000000000000E-6143 8 -> 1.000000000000000000000000000000000E-6143 +dqcps134 copysign 1E-6176 8 -> 1E-6176 + +dqcps135 copysign -1E-6176 8 -> 1E-6176 +dqcps136 copysign -1.000000000000000000000000000000000E-6143 8 -> 1.000000000000000000000000000000000E-6143 +dqcps137 copysign -1E-6143 8 -> 1E-6143 +dqcps138 copysign -9.999999999999999999999999999999999E+6144 8 -> 9.999999999999999999999999999999999E+6144 + +-- repeat with negative RHS + +-- Infinities +dqcps211 copysign Infinity -34 -> -Infinity +dqcps212 copysign -Infinity -34 -> -Infinity + +-- NaNs, 0 payload +dqcps221 copysign NaN -34 -> -NaN +dqcps222 copysign -NaN -34 -> -NaN +dqcps223 copysign sNaN -34 -> -sNaN +dqcps224 copysign -sNaN -34 -> -sNaN + +-- NaNs, non-0 payload +dqcps231 copysign NaN10 -34 -> -NaN10 +dqcps232 copysign -NaN10 -34 -> -NaN10 +dqcps233 copysign sNaN10 -34 -> -sNaN10 +dqcps234 copysign -sNaN10 -34 -> -sNaN10 +dqcps235 copysign NaN7 -34 -> -NaN7 +dqcps236 copysign -NaN7 -34 -> -NaN7 +dqcps237 copysign sNaN101 -34 -> -sNaN101 +dqcps238 copysign -sNaN101 -34 -> -sNaN101 + +-- finites +dqcps301 copysign 7 -34 -> -7 +dqcps302 copysign -7 -34 -> -7 +dqcps303 copysign 75 -34 -> -75 +dqcps304 copysign -75 -34 -> -75 +dqcps305 copysign 7.50 -34 -> -7.50 +dqcps306 copysign -7.50 -34 -> -7.50 +dqcps307 copysign 7.500 -34 -> -7.500 +dqcps308 copysign -7.500 -34 -> -7.500 + +-- zeros +dqcps311 copysign 0 -34 -> -0 +dqcps312 copysign -0 -34 -> -0 +dqcps313 copysign 0E+4 -34 -> -0E+4 +dqcps314 copysign -0E+4 -34 -> -0E+4 +dqcps315 copysign 0.0000 -34 -> -0.0000 +dqcps316 copysign -0.0000 -34 -> -0.0000 +dqcps317 copysign 0E-141 -34 -> -0E-141 +dqcps318 copysign -0E-141 -34 -> -0E-141 + +-- full coefficients, alternating bits +dqcps321 copysign 2682682682682682682682682682682682 -9 -> -2682682682682682682682682682682682 +dqcps322 copysign -2682682682682682682682682682682682 -9 -> -2682682682682682682682682682682682 +dqcps323 copysign 1341341341341341341341341341341341 -9 -> -1341341341341341341341341341341341 +dqcps324 copysign -1341341341341341341341341341341341 -9 -> -1341341341341341341341341341341341 + +-- Nmax, Nmin, Ntiny +dqcps331 copysign 9.999999999999999999999999999999999E+6144 -1 -> -9.999999999999999999999999999999999E+6144 +dqcps332 copysign 1E-6143 -1 -> -1E-6143 +dqcps333 copysign 1.000000000000000000000000000000000E-6143 -1 -> -1.000000000000000000000000000000000E-6143 +dqcps334 copysign 1E-6176 -1 -> -1E-6176 + +dqcps335 copysign -1E-6176 -3 -> -1E-6176 +dqcps336 copysign -1.000000000000000000000000000000000E-6143 -3 -> -1.000000000000000000000000000000000E-6143 +dqcps337 copysign -1E-6143 -3 -> -1E-6143 +dqcps338 copysign -9.999999999999999999999999999999999E+6144 -3 -> -9.999999999999999999999999999999999E+6144 + +-- Other kinds of RHS +dqcps401 copysign 701 -34 -> -701 +dqcps402 copysign -720 -34 -> -720 +dqcps403 copysign 701 -0 -> -701 +dqcps404 copysign -720 -0 -> -720 +dqcps405 copysign 701 +0 -> 701 +dqcps406 copysign -720 +0 -> 720 +dqcps407 copysign 701 +34 -> 701 +dqcps408 copysign -720 +34 -> 720 + +dqcps413 copysign 701 -Inf -> -701 +dqcps414 copysign -720 -Inf -> -720 +dqcps415 copysign 701 +Inf -> 701 +dqcps416 copysign -720 +Inf -> 720 + +dqcps420 copysign 701 -NaN -> -701 +dqcps421 copysign -720 -NaN -> -720 +dqcps422 copysign 701 +NaN -> 701 +dqcps423 copysign -720 +NaN -> 720 +dqcps425 copysign -720 +NaN8 -> 720 + +dqcps426 copysign 701 -sNaN -> -701 +dqcps427 copysign -720 -sNaN -> -720 +dqcps428 copysign 701 +sNaN -> 701 +dqcps429 copysign -720 +sNaN -> 720 +dqcps430 copysign -720 +sNaN3 -> 720 + Added: python/branches/release25-maint/Lib/test/decimaltestdata/dqDivide.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/dqDivide.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,808 @@ +------------------------------------------------------------------------ +-- dqDivide.decTest -- decQuad division -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +extended: 1 +clamp: 1 +precision: 34 +maxExponent: 6144 +minExponent: -6143 +rounding: half_even + +-- sanity checks +dqdiv001 divide 1 1 -> 1 +dqdiv002 divide 2 1 -> 2 +dqdiv003 divide 1 2 -> 0.5 +dqdiv004 divide 2 2 -> 1 +dqdiv005 divide 0 1 -> 0 +dqdiv006 divide 0 2 -> 0 +dqdiv007 divide 1 3 -> 0.3333333333333333333333333333333333 Inexact Rounded +dqdiv008 divide 2 3 -> 0.6666666666666666666666666666666667 Inexact Rounded +dqdiv009 divide 3 3 -> 1 + +dqdiv010 divide 2.4 1 -> 2.4 +dqdiv011 divide 2.4 -1 -> -2.4 +dqdiv012 divide -2.4 1 -> -2.4 +dqdiv013 divide -2.4 -1 -> 2.4 +dqdiv014 divide 2.40 1 -> 2.40 +dqdiv015 divide 2.400 1 -> 2.400 +dqdiv016 divide 2.4 2 -> 1.2 +dqdiv017 divide 2.400 2 -> 1.200 +dqdiv018 divide 2. 2 -> 1 +dqdiv019 divide 20 20 -> 1 + +dqdiv020 divide 187 187 -> 1 +dqdiv021 divide 5 2 -> 2.5 +dqdiv022 divide 50 20 -> 2.5 +dqdiv023 divide 500 200 -> 2.5 +dqdiv024 divide 50.0 20.0 -> 2.5 +dqdiv025 divide 5.00 2.00 -> 2.5 +dqdiv026 divide 5 2.0 -> 2.5 +dqdiv027 divide 5 2.000 -> 2.5 +dqdiv028 divide 5 0.20 -> 25 +dqdiv029 divide 5 0.200 -> 25 +dqdiv030 divide 10 1 -> 10 +dqdiv031 divide 100 1 -> 100 +dqdiv032 divide 1000 1 -> 1000 +dqdiv033 divide 1000 100 -> 10 + +dqdiv035 divide 1 2 -> 0.5 +dqdiv036 divide 1 4 -> 0.25 +dqdiv037 divide 1 8 -> 0.125 +dqdiv038 divide 1 16 -> 0.0625 +dqdiv039 divide 1 32 -> 0.03125 +dqdiv040 divide 1 64 -> 0.015625 +dqdiv041 divide 1 -2 -> -0.5 +dqdiv042 divide 1 -4 -> -0.25 +dqdiv043 divide 1 -8 -> -0.125 +dqdiv044 divide 1 -16 -> -0.0625 +dqdiv045 divide 1 -32 -> -0.03125 +dqdiv046 divide 1 -64 -> -0.015625 +dqdiv047 divide -1 2 -> -0.5 +dqdiv048 divide -1 4 -> -0.25 +dqdiv049 divide -1 8 -> -0.125 +dqdiv050 divide -1 16 -> -0.0625 +dqdiv051 divide -1 32 -> -0.03125 +dqdiv052 divide -1 64 -> -0.015625 +dqdiv053 divide -1 -2 -> 0.5 +dqdiv054 divide -1 -4 -> 0.25 +dqdiv055 divide -1 -8 -> 0.125 +dqdiv056 divide -1 -16 -> 0.0625 +dqdiv057 divide -1 -32 -> 0.03125 +dqdiv058 divide -1 -64 -> 0.015625 + +-- bcdTime +dqdiv060 divide 1 7 -> 0.1428571428571428571428571428571429 Inexact Rounded +dqdiv061 divide 1.2345678 1.9876543 -> 0.6211179680490717123193907511985359 Inexact Rounded + +-- 1234567890123456 +dqdiv067 divide 9999999999999999999999999999999999 1 -> 9999999999999999999999999999999999 +dqdiv068 divide 999999999999999999999999999999999 1 -> 999999999999999999999999999999999 +dqdiv069 divide 99999999999999999999999999999999 1 -> 99999999999999999999999999999999 +dqdiv070 divide 99999999999999999 1 -> 99999999999999999 +dqdiv071 divide 9999999999999999 1 -> 9999999999999999 +dqdiv072 divide 999999999999999 1 -> 999999999999999 +dqdiv073 divide 99999999999999 1 -> 99999999999999 +dqdiv074 divide 9999999999999 1 -> 9999999999999 +dqdiv075 divide 999999999999 1 -> 999999999999 +dqdiv076 divide 99999999999 1 -> 99999999999 +dqdiv077 divide 9999999999 1 -> 9999999999 +dqdiv078 divide 999999999 1 -> 999999999 +dqdiv079 divide 99999999 1 -> 99999999 +dqdiv080 divide 9999999 1 -> 9999999 +dqdiv081 divide 999999 1 -> 999999 +dqdiv082 divide 99999 1 -> 99999 +dqdiv083 divide 9999 1 -> 9999 +dqdiv084 divide 999 1 -> 999 +dqdiv085 divide 99 1 -> 99 +dqdiv086 divide 9 1 -> 9 + +dqdiv090 divide 0. 1 -> 0 +dqdiv091 divide .0 1 -> 0.0 +dqdiv092 divide 0.00 1 -> 0.00 +dqdiv093 divide 0.00E+9 1 -> 0E+7 +dqdiv094 divide 0.0000E-50 1 -> 0E-54 + +dqdiv095 divide 1 1E-8 -> 1E+8 +dqdiv096 divide 1 1E-9 -> 1E+9 +dqdiv097 divide 1 1E-10 -> 1E+10 +dqdiv098 divide 1 1E-11 -> 1E+11 +dqdiv099 divide 1 1E-12 -> 1E+12 + +dqdiv100 divide 1 1 -> 1 +dqdiv101 divide 1 2 -> 0.5 +dqdiv102 divide 1 3 -> 0.3333333333333333333333333333333333 Inexact Rounded +dqdiv103 divide 1 4 -> 0.25 +dqdiv104 divide 1 5 -> 0.2 +dqdiv105 divide 1 6 -> 0.1666666666666666666666666666666667 Inexact Rounded +dqdiv106 divide 1 7 -> 0.1428571428571428571428571428571429 Inexact Rounded +dqdiv107 divide 1 8 -> 0.125 +dqdiv108 divide 1 9 -> 0.1111111111111111111111111111111111 Inexact Rounded +dqdiv109 divide 1 10 -> 0.1 +dqdiv110 divide 1 1 -> 1 +dqdiv111 divide 2 1 -> 2 +dqdiv112 divide 3 1 -> 3 +dqdiv113 divide 4 1 -> 4 +dqdiv114 divide 5 1 -> 5 +dqdiv115 divide 6 1 -> 6 +dqdiv116 divide 7 1 -> 7 +dqdiv117 divide 8 1 -> 8 +dqdiv118 divide 9 1 -> 9 +dqdiv119 divide 10 1 -> 10 + +dqdiv120 divide 3E+1 0.001 -> 3E+4 +dqdiv121 divide 2.200 2 -> 1.100 + +dqdiv130 divide 12345 4.999 -> 2469.493898779755951190238047609522 Inexact Rounded +dqdiv131 divide 12345 4.99 -> 2473.947895791583166332665330661323 Inexact Rounded +dqdiv132 divide 12345 4.9 -> 2519.387755102040816326530612244898 Inexact Rounded +dqdiv133 divide 12345 5 -> 2469 +dqdiv134 divide 12345 5.1 -> 2420.588235294117647058823529411765 Inexact Rounded +dqdiv135 divide 12345 5.01 -> 2464.071856287425149700598802395210 Inexact Rounded +dqdiv136 divide 12345 5.001 -> 2468.506298740251949610077984403119 Inexact Rounded + +-- test possibly imprecise results +dqdiv220 divide 391 597 -> 0.6549413735343383584589614740368509 Inexact Rounded +dqdiv221 divide 391 -597 -> -0.6549413735343383584589614740368509 Inexact Rounded +dqdiv222 divide -391 597 -> -0.6549413735343383584589614740368509 Inexact Rounded +dqdiv223 divide -391 -597 -> 0.6549413735343383584589614740368509 Inexact Rounded + +-- test some cases that are close to exponent overflow +dqdiv270 divide 1 1e6144 -> 1E-6144 Subnormal +dqdiv271 divide 1 0.9e6144 -> 1.11111111111111111111111111111111E-6144 Rounded Inexact Subnormal Underflow +dqdiv272 divide 1 0.99e6144 -> 1.01010101010101010101010101010101E-6144 Rounded Inexact Subnormal Underflow +dqdiv273 divide 1 0.9999999999999999e6144 -> 1.00000000000000010000000000000001E-6144 Rounded Inexact Subnormal Underflow +dqdiv274 divide 9e6144 1 -> 9.000000000000000000000000000000000E+6144 Clamped +dqdiv275 divide 9.9e6144 1 -> 9.900000000000000000000000000000000E+6144 Clamped +dqdiv276 divide 9.99e6144 1 -> 9.990000000000000000000000000000000E+6144 Clamped +dqdiv277 divide 9.999999999999999e6144 1 -> 9.999999999999999000000000000000000E+6144 Clamped + +dqdiv278 divide 1 0.9999999999999999999999999999999999e6144 -> 1.00000000000000000000000000000000E-6144 Rounded Inexact Subnormal Underflow +dqdiv279 divide 9.999999999999999999999999999999999e6144 1 -> 9.999999999999999999999999999999999E+6144 + +-- Divide into 0 tests +dqdiv301 divide 0 7 -> 0 +dqdiv302 divide 0 7E-5 -> 0E+5 +dqdiv303 divide 0 7E-1 -> 0E+1 +dqdiv304 divide 0 7E+1 -> 0.0 +dqdiv305 divide 0 7E+5 -> 0.00000 +dqdiv306 divide 0 7E+6 -> 0.000000 +dqdiv307 divide 0 7E+7 -> 0E-7 +dqdiv308 divide 0 70E-5 -> 0E+5 +dqdiv309 divide 0 70E-1 -> 0E+1 +dqdiv310 divide 0 70E+0 -> 0 +dqdiv311 divide 0 70E+1 -> 0.0 +dqdiv312 divide 0 70E+5 -> 0.00000 +dqdiv313 divide 0 70E+6 -> 0.000000 +dqdiv314 divide 0 70E+7 -> 0E-7 +dqdiv315 divide 0 700E-5 -> 0E+5 +dqdiv316 divide 0 700E-1 -> 0E+1 +dqdiv317 divide 0 700E+0 -> 0 +dqdiv318 divide 0 700E+1 -> 0.0 +dqdiv319 divide 0 700E+5 -> 0.00000 +dqdiv320 divide 0 700E+6 -> 0.000000 +dqdiv321 divide 0 700E+7 -> 0E-7 +dqdiv322 divide 0 700E+77 -> 0E-77 + +dqdiv331 divide 0E-3 7E-5 -> 0E+2 +dqdiv332 divide 0E-3 7E-1 -> 0.00 +dqdiv333 divide 0E-3 7E+1 -> 0.0000 +dqdiv334 divide 0E-3 7E+5 -> 0E-8 +dqdiv335 divide 0E-1 7E-5 -> 0E+4 +dqdiv336 divide 0E-1 7E-1 -> 0 +dqdiv337 divide 0E-1 7E+1 -> 0.00 +dqdiv338 divide 0E-1 7E+5 -> 0.000000 +dqdiv339 divide 0E+1 7E-5 -> 0E+6 +dqdiv340 divide 0E+1 7E-1 -> 0E+2 +dqdiv341 divide 0E+1 7E+1 -> 0 +dqdiv342 divide 0E+1 7E+5 -> 0.0000 +dqdiv343 divide 0E+3 7E-5 -> 0E+8 +dqdiv344 divide 0E+3 7E-1 -> 0E+4 +dqdiv345 divide 0E+3 7E+1 -> 0E+2 +dqdiv346 divide 0E+3 7E+5 -> 0.00 + +-- These were 'input rounding' +dqdiv441 divide 12345678000 1 -> 12345678000 +dqdiv442 divide 1 12345678000 -> 8.100000664200054464404466081166219E-11 Inexact Rounded +dqdiv443 divide 1234567800 1 -> 1234567800 +dqdiv444 divide 1 1234567800 -> 8.100000664200054464404466081166219E-10 Inexact Rounded +dqdiv445 divide 1234567890 1 -> 1234567890 +dqdiv446 divide 1 1234567890 -> 8.100000073710000670761006103925156E-10 Inexact Rounded +dqdiv447 divide 1234567891 1 -> 1234567891 +dqdiv448 divide 1 1234567891 -> 8.100000067149000556665214614754629E-10 Inexact Rounded +dqdiv449 divide 12345678901 1 -> 12345678901 +dqdiv450 divide 1 12345678901 -> 8.100000073053900658873130042376760E-11 Inexact Rounded +dqdiv451 divide 1234567896 1 -> 1234567896 +dqdiv452 divide 1 1234567896 -> 8.100000034344000145618560617422697E-10 Inexact Rounded + +-- high-lows +dqdiv453 divide 1e+1 1 -> 1E+1 +dqdiv454 divide 1e+1 1.0 -> 1E+1 +dqdiv455 divide 1e+1 1.00 -> 1E+1 +dqdiv456 divide 1e+2 2 -> 5E+1 +dqdiv457 divide 1e+2 2.0 -> 5E+1 +dqdiv458 divide 1e+2 2.00 -> 5E+1 + +-- some from IEEE discussions +dqdiv460 divide 3e0 2e0 -> 1.5 +dqdiv461 divide 30e-1 2e0 -> 1.5 +dqdiv462 divide 300e-2 2e0 -> 1.50 +dqdiv464 divide 3000e-3 2e0 -> 1.500 +dqdiv465 divide 3e0 20e-1 -> 1.5 +dqdiv466 divide 30e-1 20e-1 -> 1.5 +dqdiv467 divide 300e-2 20e-1 -> 1.5 +dqdiv468 divide 3000e-3 20e-1 -> 1.50 +dqdiv469 divide 3e0 200e-2 -> 1.5 +dqdiv470 divide 30e-1 200e-2 -> 1.5 +dqdiv471 divide 300e-2 200e-2 -> 1.5 +dqdiv472 divide 3000e-3 200e-2 -> 1.5 +dqdiv473 divide 3e0 2000e-3 -> 1.5 +dqdiv474 divide 30e-1 2000e-3 -> 1.5 +dqdiv475 divide 300e-2 2000e-3 -> 1.5 +dqdiv476 divide 3000e-3 2000e-3 -> 1.5 + +-- some reciprocals +dqdiv480 divide 1 1.0E+33 -> 1E-33 +dqdiv481 divide 1 10E+33 -> 1E-34 +dqdiv482 divide 1 1.0E-33 -> 1E+33 +dqdiv483 divide 1 10E-33 -> 1E+32 + +-- RMS discussion table +dqdiv484 divide 0e5 1e3 -> 0E+2 +dqdiv485 divide 0e5 2e3 -> 0E+2 +dqdiv486 divide 0e5 10e2 -> 0E+3 +dqdiv487 divide 0e5 20e2 -> 0E+3 +dqdiv488 divide 0e5 100e1 -> 0E+4 +dqdiv489 divide 0e5 200e1 -> 0E+4 + +dqdiv491 divide 1e5 1e3 -> 1E+2 +dqdiv492 divide 1e5 2e3 -> 5E+1 +dqdiv493 divide 1e5 10e2 -> 1E+2 +dqdiv494 divide 1e5 20e2 -> 5E+1 +dqdiv495 divide 1e5 100e1 -> 1E+2 +dqdiv496 divide 1e5 200e1 -> 5E+1 + +-- tryzeros cases +rounding: half_up +dqdiv497 divide 0E+6108 1000E-33 -> 0E+6111 Clamped +dqdiv498 divide 0E-6170 1000E+33 -> 0E-6176 Clamped + +rounding: half_up + +-- focus on trailing zeros issues +dqdiv500 divide 1 9.9 -> 0.1010101010101010101010101010101010 Inexact Rounded +dqdiv501 divide 1 9.09 -> 0.1100110011001100110011001100110011 Inexact Rounded +dqdiv502 divide 1 9.009 -> 0.1110001110001110001110001110001110 Inexact Rounded + +dqdiv511 divide 1 2 -> 0.5 +dqdiv512 divide 1.0 2 -> 0.5 +dqdiv513 divide 1.00 2 -> 0.50 +dqdiv514 divide 1.000 2 -> 0.500 +dqdiv515 divide 1.0000 2 -> 0.5000 +dqdiv516 divide 1.00000 2 -> 0.50000 +dqdiv517 divide 1.000000 2 -> 0.500000 +dqdiv518 divide 1.0000000 2 -> 0.5000000 +dqdiv519 divide 1.00 2.00 -> 0.5 + +dqdiv521 divide 2 1 -> 2 +dqdiv522 divide 2 1.0 -> 2 +dqdiv523 divide 2 1.00 -> 2 +dqdiv524 divide 2 1.000 -> 2 +dqdiv525 divide 2 1.0000 -> 2 +dqdiv526 divide 2 1.00000 -> 2 +dqdiv527 divide 2 1.000000 -> 2 +dqdiv528 divide 2 1.0000000 -> 2 +dqdiv529 divide 2.00 1.00 -> 2 + +dqdiv530 divide 2.40 2 -> 1.20 +dqdiv531 divide 2.40 4 -> 0.60 +dqdiv532 divide 2.40 10 -> 0.24 +dqdiv533 divide 2.40 2.0 -> 1.2 +dqdiv534 divide 2.40 4.0 -> 0.6 +dqdiv535 divide 2.40 10.0 -> 0.24 +dqdiv536 divide 2.40 2.00 -> 1.2 +dqdiv537 divide 2.40 4.00 -> 0.6 +dqdiv538 divide 2.40 10.00 -> 0.24 +dqdiv539 divide 0.9 0.1 -> 9 +dqdiv540 divide 0.9 0.01 -> 9E+1 +dqdiv541 divide 0.9 0.001 -> 9E+2 +dqdiv542 divide 5 2 -> 2.5 +dqdiv543 divide 5 2.0 -> 2.5 +dqdiv544 divide 5 2.00 -> 2.5 +dqdiv545 divide 5 20 -> 0.25 +dqdiv546 divide 5 20.0 -> 0.25 +dqdiv547 divide 2.400 2 -> 1.200 +dqdiv548 divide 2.400 2.0 -> 1.20 +dqdiv549 divide 2.400 2.400 -> 1 + +dqdiv550 divide 240 1 -> 240 +dqdiv551 divide 240 10 -> 24 +dqdiv552 divide 240 100 -> 2.4 +dqdiv553 divide 240 1000 -> 0.24 +dqdiv554 divide 2400 1 -> 2400 +dqdiv555 divide 2400 10 -> 240 +dqdiv556 divide 2400 100 -> 24 +dqdiv557 divide 2400 1000 -> 2.4 + +-- +ve exponent +dqdiv600 divide 2.4E+9 2 -> 1.2E+9 +dqdiv601 divide 2.40E+9 2 -> 1.20E+9 +dqdiv602 divide 2.400E+9 2 -> 1.200E+9 +dqdiv603 divide 2.4000E+9 2 -> 1.2000E+9 +dqdiv604 divide 24E+8 2 -> 1.2E+9 +dqdiv605 divide 240E+7 2 -> 1.20E+9 +dqdiv606 divide 2400E+6 2 -> 1.200E+9 +dqdiv607 divide 24000E+5 2 -> 1.2000E+9 + +-- more zeros, etc. +dqdiv731 divide 5.00 1E-3 -> 5.00E+3 +dqdiv732 divide 00.00 0.000 -> NaN Division_undefined +dqdiv733 divide 00.00 0E-3 -> NaN Division_undefined +dqdiv734 divide 0 -0 -> NaN Division_undefined +dqdiv735 divide -0 0 -> NaN Division_undefined +dqdiv736 divide -0 -0 -> NaN Division_undefined + +dqdiv741 divide 0 -1 -> -0 +dqdiv742 divide -0 -1 -> 0 +dqdiv743 divide 0 1 -> 0 +dqdiv744 divide -0 1 -> -0 +dqdiv745 divide -1 0 -> -Infinity Division_by_zero +dqdiv746 divide -1 -0 -> Infinity Division_by_zero +dqdiv747 divide 1 0 -> Infinity Division_by_zero +dqdiv748 divide 1 -0 -> -Infinity Division_by_zero + +dqdiv751 divide 0.0 -1 -> -0.0 +dqdiv752 divide -0.0 -1 -> 0.0 +dqdiv753 divide 0.0 1 -> 0.0 +dqdiv754 divide -0.0 1 -> -0.0 +dqdiv755 divide -1.0 0 -> -Infinity Division_by_zero +dqdiv756 divide -1.0 -0 -> Infinity Division_by_zero +dqdiv757 divide 1.0 0 -> Infinity Division_by_zero +dqdiv758 divide 1.0 -0 -> -Infinity Division_by_zero + +dqdiv761 divide 0 -1.0 -> -0E+1 +dqdiv762 divide -0 -1.0 -> 0E+1 +dqdiv763 divide 0 1.0 -> 0E+1 +dqdiv764 divide -0 1.0 -> -0E+1 +dqdiv765 divide -1 0.0 -> -Infinity Division_by_zero +dqdiv766 divide -1 -0.0 -> Infinity Division_by_zero +dqdiv767 divide 1 0.0 -> Infinity Division_by_zero +dqdiv768 divide 1 -0.0 -> -Infinity Division_by_zero + +dqdiv771 divide 0.0 -1.0 -> -0 +dqdiv772 divide -0.0 -1.0 -> 0 +dqdiv773 divide 0.0 1.0 -> 0 +dqdiv774 divide -0.0 1.0 -> -0 +dqdiv775 divide -1.0 0.0 -> -Infinity Division_by_zero +dqdiv776 divide -1.0 -0.0 -> Infinity Division_by_zero +dqdiv777 divide 1.0 0.0 -> Infinity Division_by_zero +dqdiv778 divide 1.0 -0.0 -> -Infinity Division_by_zero + +-- Specials +dqdiv780 divide Inf -Inf -> NaN Invalid_operation +dqdiv781 divide Inf -1000 -> -Infinity +dqdiv782 divide Inf -1 -> -Infinity +dqdiv783 divide Inf -0 -> -Infinity +dqdiv784 divide Inf 0 -> Infinity +dqdiv785 divide Inf 1 -> Infinity +dqdiv786 divide Inf 1000 -> Infinity +dqdiv787 divide Inf Inf -> NaN Invalid_operation +dqdiv788 divide -1000 Inf -> -0E-6176 Clamped +dqdiv789 divide -Inf Inf -> NaN Invalid_operation +dqdiv790 divide -1 Inf -> -0E-6176 Clamped +dqdiv791 divide -0 Inf -> -0E-6176 Clamped +dqdiv792 divide 0 Inf -> 0E-6176 Clamped +dqdiv793 divide 1 Inf -> 0E-6176 Clamped +dqdiv794 divide 1000 Inf -> 0E-6176 Clamped +dqdiv795 divide Inf Inf -> NaN Invalid_operation + +dqdiv800 divide -Inf -Inf -> NaN Invalid_operation +dqdiv801 divide -Inf -1000 -> Infinity +dqdiv802 divide -Inf -1 -> Infinity +dqdiv803 divide -Inf -0 -> Infinity +dqdiv804 divide -Inf 0 -> -Infinity +dqdiv805 divide -Inf 1 -> -Infinity +dqdiv806 divide -Inf 1000 -> -Infinity +dqdiv807 divide -Inf Inf -> NaN Invalid_operation +dqdiv808 divide -1000 Inf -> -0E-6176 Clamped +dqdiv809 divide -Inf -Inf -> NaN Invalid_operation +dqdiv810 divide -1 -Inf -> 0E-6176 Clamped +dqdiv811 divide -0 -Inf -> 0E-6176 Clamped +dqdiv812 divide 0 -Inf -> -0E-6176 Clamped +dqdiv813 divide 1 -Inf -> -0E-6176 Clamped +dqdiv814 divide 1000 -Inf -> -0E-6176 Clamped +dqdiv815 divide Inf -Inf -> NaN Invalid_operation + +dqdiv821 divide NaN -Inf -> NaN +dqdiv822 divide NaN -1000 -> NaN +dqdiv823 divide NaN -1 -> NaN +dqdiv824 divide NaN -0 -> NaN +dqdiv825 divide NaN 0 -> NaN +dqdiv826 divide NaN 1 -> NaN +dqdiv827 divide NaN 1000 -> NaN +dqdiv828 divide NaN Inf -> NaN +dqdiv829 divide NaN NaN -> NaN +dqdiv830 divide -Inf NaN -> NaN +dqdiv831 divide -1000 NaN -> NaN +dqdiv832 divide -1 NaN -> NaN +dqdiv833 divide -0 NaN -> NaN +dqdiv834 divide 0 NaN -> NaN +dqdiv835 divide 1 NaN -> NaN +dqdiv836 divide 1000 NaN -> NaN +dqdiv837 divide Inf NaN -> NaN + +dqdiv841 divide sNaN -Inf -> NaN Invalid_operation +dqdiv842 divide sNaN -1000 -> NaN Invalid_operation +dqdiv843 divide sNaN -1 -> NaN Invalid_operation +dqdiv844 divide sNaN -0 -> NaN Invalid_operation +dqdiv845 divide sNaN 0 -> NaN Invalid_operation +dqdiv846 divide sNaN 1 -> NaN Invalid_operation +dqdiv847 divide sNaN 1000 -> NaN Invalid_operation +dqdiv848 divide sNaN NaN -> NaN Invalid_operation +dqdiv849 divide sNaN sNaN -> NaN Invalid_operation +dqdiv850 divide NaN sNaN -> NaN Invalid_operation +dqdiv851 divide -Inf sNaN -> NaN Invalid_operation +dqdiv852 divide -1000 sNaN -> NaN Invalid_operation +dqdiv853 divide -1 sNaN -> NaN Invalid_operation +dqdiv854 divide -0 sNaN -> NaN Invalid_operation +dqdiv855 divide 0 sNaN -> NaN Invalid_operation +dqdiv856 divide 1 sNaN -> NaN Invalid_operation +dqdiv857 divide 1000 sNaN -> NaN Invalid_operation +dqdiv858 divide Inf sNaN -> NaN Invalid_operation +dqdiv859 divide NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +dqdiv861 divide NaN9 -Inf -> NaN9 +dqdiv862 divide NaN8 1000 -> NaN8 +dqdiv863 divide NaN7 Inf -> NaN7 +dqdiv864 divide NaN6 NaN5 -> NaN6 +dqdiv865 divide -Inf NaN4 -> NaN4 +dqdiv866 divide -1000 NaN3 -> NaN3 +dqdiv867 divide Inf NaN2 -> NaN2 + +dqdiv871 divide sNaN99 -Inf -> NaN99 Invalid_operation +dqdiv872 divide sNaN98 -1 -> NaN98 Invalid_operation +dqdiv873 divide sNaN97 NaN -> NaN97 Invalid_operation +dqdiv874 divide sNaN96 sNaN94 -> NaN96 Invalid_operation +dqdiv875 divide NaN95 sNaN93 -> NaN93 Invalid_operation +dqdiv876 divide -Inf sNaN92 -> NaN92 Invalid_operation +dqdiv877 divide 0 sNaN91 -> NaN91 Invalid_operation +dqdiv878 divide Inf sNaN90 -> NaN90 Invalid_operation +dqdiv879 divide NaN sNaN89 -> NaN89 Invalid_operation + +dqdiv881 divide -NaN9 -Inf -> -NaN9 +dqdiv882 divide -NaN8 1000 -> -NaN8 +dqdiv883 divide -NaN7 Inf -> -NaN7 +dqdiv884 divide -NaN6 -NaN5 -> -NaN6 +dqdiv885 divide -Inf -NaN4 -> -NaN4 +dqdiv886 divide -1000 -NaN3 -> -NaN3 +dqdiv887 divide Inf -NaN2 -> -NaN2 + +dqdiv891 divide -sNaN99 -Inf -> -NaN99 Invalid_operation +dqdiv892 divide -sNaN98 -1 -> -NaN98 Invalid_operation +dqdiv893 divide -sNaN97 NaN -> -NaN97 Invalid_operation +dqdiv894 divide -sNaN96 -sNaN94 -> -NaN96 Invalid_operation +dqdiv895 divide -NaN95 -sNaN93 -> -NaN93 Invalid_operation +dqdiv896 divide -Inf -sNaN92 -> -NaN92 Invalid_operation +dqdiv897 divide 0 -sNaN91 -> -NaN91 Invalid_operation +dqdiv898 divide Inf -sNaN90 -> -NaN90 Invalid_operation +dqdiv899 divide -NaN -sNaN89 -> -NaN89 Invalid_operation + +-- Various flavours of divide by 0 +dqdiv901 divide 0 0 -> NaN Division_undefined +dqdiv902 divide 0.0E5 0 -> NaN Division_undefined +dqdiv903 divide 0.000 0 -> NaN Division_undefined +dqdiv904 divide 0.0001 0 -> Infinity Division_by_zero +dqdiv905 divide 0.01 0 -> Infinity Division_by_zero +dqdiv906 divide 0.1 0 -> Infinity Division_by_zero +dqdiv907 divide 1 0 -> Infinity Division_by_zero +dqdiv908 divide 1 0.0 -> Infinity Division_by_zero +dqdiv909 divide 10 0.0 -> Infinity Division_by_zero +dqdiv910 divide 1E+100 0.0 -> Infinity Division_by_zero +dqdiv911 divide 1E+100 0 -> Infinity Division_by_zero + +dqdiv921 divide -0.0001 0 -> -Infinity Division_by_zero +dqdiv922 divide -0.01 0 -> -Infinity Division_by_zero +dqdiv923 divide -0.1 0 -> -Infinity Division_by_zero +dqdiv924 divide -1 0 -> -Infinity Division_by_zero +dqdiv925 divide -1 0.0 -> -Infinity Division_by_zero +dqdiv926 divide -10 0.0 -> -Infinity Division_by_zero +dqdiv927 divide -1E+100 0.0 -> -Infinity Division_by_zero +dqdiv928 divide -1E+100 0 -> -Infinity Division_by_zero + +dqdiv931 divide 0.0001 -0 -> -Infinity Division_by_zero +dqdiv932 divide 0.01 -0 -> -Infinity Division_by_zero +dqdiv933 divide 0.1 -0 -> -Infinity Division_by_zero +dqdiv934 divide 1 -0 -> -Infinity Division_by_zero +dqdiv935 divide 1 -0.0 -> -Infinity Division_by_zero +dqdiv936 divide 10 -0.0 -> -Infinity Division_by_zero +dqdiv937 divide 1E+100 -0.0 -> -Infinity Division_by_zero +dqdiv938 divide 1E+100 -0 -> -Infinity Division_by_zero + +dqdiv941 divide -0.0001 -0 -> Infinity Division_by_zero +dqdiv942 divide -0.01 -0 -> Infinity Division_by_zero +dqdiv943 divide -0.1 -0 -> Infinity Division_by_zero +dqdiv944 divide -1 -0 -> Infinity Division_by_zero +dqdiv945 divide -1 -0.0 -> Infinity Division_by_zero +dqdiv946 divide -10 -0.0 -> Infinity Division_by_zero +dqdiv947 divide -1E+100 -0.0 -> Infinity Division_by_zero +dqdiv948 divide -1E+100 -0 -> Infinity Division_by_zero + +-- Examples from SQL proposal (Krishna Kulkarni) +dqdiv1021 divide 1E0 1E0 -> 1 +dqdiv1022 divide 1E0 2E0 -> 0.5 +dqdiv1023 divide 1E0 3E0 -> 0.3333333333333333333333333333333333 Inexact Rounded +dqdiv1024 divide 100E-2 1000E-3 -> 1 +dqdiv1025 divide 24E-1 2E0 -> 1.2 +dqdiv1026 divide 2400E-3 2E0 -> 1.200 +dqdiv1027 divide 5E0 2E0 -> 2.5 +dqdiv1028 divide 5E0 20E-1 -> 2.5 +dqdiv1029 divide 5E0 2000E-3 -> 2.5 +dqdiv1030 divide 5E0 2E-1 -> 25 +dqdiv1031 divide 5E0 20E-2 -> 25 +dqdiv1032 divide 480E-2 3E0 -> 1.60 +dqdiv1033 divide 47E-1 2E0 -> 2.35 + +-- ECMAScript bad examples +rounding: half_down +dqdiv1040 divide 5 9 -> 0.5555555555555555555555555555555556 Inexact Rounded +rounding: half_even +dqdiv1041 divide 6 11 -> 0.5454545454545454545454545454545455 Inexact Rounded + +-- Gyuris example +dqdiv1050 divide 8.336804418094040989630006819881709E-6143 8.336804418094040989630006819889000E-6143 -> 0.9999999999999999999999999999991254 Inexact Rounded + +-- overflow and underflow tests .. note subnormal results +-- signs +dqdiv1751 divide 1e+4277 1e-3311 -> Infinity Overflow Inexact Rounded +dqdiv1752 divide 1e+4277 -1e-3311 -> -Infinity Overflow Inexact Rounded +dqdiv1753 divide -1e+4277 1e-3311 -> -Infinity Overflow Inexact Rounded +dqdiv1754 divide -1e+4277 -1e-3311 -> Infinity Overflow Inexact Rounded +dqdiv1755 divide 1e-4277 1e+3311 -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqdiv1756 divide 1e-4277 -1e+3311 -> -0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqdiv1757 divide -1e-4277 1e+3311 -> -0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqdiv1758 divide -1e-4277 -1e+3311 -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped + +-- 'subnormal' boundary (all hard underflow or overflow in base arithemtic) +dqdiv1760 divide 1e-6069 1e+101 -> 1E-6170 Subnormal +dqdiv1761 divide 1e-6069 1e+102 -> 1E-6171 Subnormal +dqdiv1762 divide 1e-6069 1e+103 -> 1E-6172 Subnormal +dqdiv1763 divide 1e-6069 1e+104 -> 1E-6173 Subnormal +dqdiv1764 divide 1e-6069 1e+105 -> 1E-6174 Subnormal +dqdiv1765 divide 1e-6069 1e+106 -> 1E-6175 Subnormal +dqdiv1766 divide 1e-6069 1e+107 -> 1E-6176 Subnormal +dqdiv1767 divide 1e-6069 1e+108 -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqdiv1768 divide 1e-6069 1e+109 -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqdiv1769 divide 1e-6069 1e+110 -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped +-- [no equivalent of 'subnormal' for overflow] +dqdiv1770 divide 1e+40 1e-6101 -> 1.000000000000000000000000000000E+6141 Clamped +dqdiv1771 divide 1e+40 1e-6102 -> 1.0000000000000000000000000000000E+6142 Clamped +dqdiv1772 divide 1e+40 1e-6103 -> 1.00000000000000000000000000000000E+6143 Clamped +dqdiv1773 divide 1e+40 1e-6104 -> 1.000000000000000000000000000000000E+6144 Clamped +dqdiv1774 divide 1e+40 1e-6105 -> Infinity Overflow Inexact Rounded +dqdiv1775 divide 1e+40 1e-6106 -> Infinity Overflow Inexact Rounded +dqdiv1776 divide 1e+40 1e-6107 -> Infinity Overflow Inexact Rounded +dqdiv1777 divide 1e+40 1e-6108 -> Infinity Overflow Inexact Rounded +dqdiv1778 divide 1e+40 1e-6109 -> Infinity Overflow Inexact Rounded +dqdiv1779 divide 1e+40 1e-6110 -> Infinity Overflow Inexact Rounded + +dqdiv1801 divide 1.0000E-6172 1 -> 1.0000E-6172 Subnormal +dqdiv1802 divide 1.000E-6172 1e+1 -> 1.000E-6173 Subnormal +dqdiv1803 divide 1.00E-6172 1e+2 -> 1.00E-6174 Subnormal +dqdiv1804 divide 1.0E-6172 1e+3 -> 1.0E-6175 Subnormal +dqdiv1805 divide 1.0E-6172 1e+4 -> 1E-6176 Subnormal Rounded +dqdiv1806 divide 1.3E-6172 1e+4 -> 1E-6176 Underflow Subnormal Inexact Rounded +dqdiv1807 divide 1.5E-6172 1e+4 -> 2E-6176 Underflow Subnormal Inexact Rounded +dqdiv1808 divide 1.7E-6172 1e+4 -> 2E-6176 Underflow Subnormal Inexact Rounded +dqdiv1809 divide 2.3E-6172 1e+4 -> 2E-6176 Underflow Subnormal Inexact Rounded +dqdiv1810 divide 2.5E-6172 1e+4 -> 2E-6176 Underflow Subnormal Inexact Rounded +dqdiv1811 divide 2.7E-6172 1e+4 -> 3E-6176 Underflow Subnormal Inexact Rounded +dqdiv1812 divide 1.49E-6172 1e+4 -> 1E-6176 Underflow Subnormal Inexact Rounded +dqdiv1813 divide 1.50E-6172 1e+4 -> 2E-6176 Underflow Subnormal Inexact Rounded +dqdiv1814 divide 1.51E-6172 1e+4 -> 2E-6176 Underflow Subnormal Inexact Rounded +dqdiv1815 divide 2.49E-6172 1e+4 -> 2E-6176 Underflow Subnormal Inexact Rounded +dqdiv1816 divide 2.50E-6172 1e+4 -> 2E-6176 Underflow Subnormal Inexact Rounded +dqdiv1817 divide 2.51E-6172 1e+4 -> 3E-6176 Underflow Subnormal Inexact Rounded + +dqdiv1818 divide 1E-6172 1e+4 -> 1E-6176 Subnormal +dqdiv1819 divide 3E-6172 1e+5 -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqdiv1820 divide 5E-6172 1e+5 -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqdiv1821 divide 7E-6172 1e+5 -> 1E-6176 Underflow Subnormal Inexact Rounded +dqdiv1822 divide 9E-6172 1e+5 -> 1E-6176 Underflow Subnormal Inexact Rounded +dqdiv1823 divide 9.9E-6172 1e+5 -> 1E-6176 Underflow Subnormal Inexact Rounded + +dqdiv1824 divide 1E-6172 -1e+4 -> -1E-6176 Subnormal +dqdiv1825 divide 3E-6172 -1e+5 -> -0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqdiv1826 divide -5E-6172 1e+5 -> -0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqdiv1827 divide 7E-6172 -1e+5 -> -1E-6176 Underflow Subnormal Inexact Rounded +dqdiv1828 divide -9E-6172 1e+5 -> -1E-6176 Underflow Subnormal Inexact Rounded +dqdiv1829 divide 9.9E-6172 -1e+5 -> -1E-6176 Underflow Subnormal Inexact Rounded +dqdiv1830 divide 3.0E-6172 -1e+5 -> -0E-6176 Underflow Subnormal Inexact Rounded Clamped + +dqdiv1831 divide 1.0E-5977 1e+200 -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqdiv1832 divide 1.0E-5977 1e+199 -> 1E-6176 Subnormal Rounded +dqdiv1833 divide 1.0E-5977 1e+198 -> 1.0E-6175 Subnormal +dqdiv1834 divide 2.0E-5977 2e+198 -> 1.0E-6175 Subnormal +dqdiv1835 divide 4.0E-5977 4e+198 -> 1.0E-6175 Subnormal +dqdiv1836 divide 10.0E-5977 10e+198 -> 1.0E-6175 Subnormal +dqdiv1837 divide 30.0E-5977 30e+198 -> 1.0E-6175 Subnormal +dqdiv1838 divide 40.0E-5982 40e+166 -> 1.0E-6148 Subnormal +dqdiv1839 divide 40.0E-5982 40e+165 -> 1.0E-6147 Subnormal +dqdiv1840 divide 40.0E-5982 40e+164 -> 1.0E-6146 Subnormal + +-- randoms +rounding: half_even +dqdiv2010 divide -5231195652931651968034356117118850 -7243718664422548573203260970.34995 -> 722169.9095831284624736051460550680 Inexact Rounded +dqdiv2011 divide -89584669773927.82711237350022515352 -42077943728529635884.21142627532985 -> 0.000002129017291146471565928125887527266 Inexact Rounded +dqdiv2012 divide -2.828201693360723203806974891946180E-232 812596541221823960386384403089240.9 -> -3.480450075640521320040055759125120E-265 Inexact Rounded +dqdiv2013 divide -6442775372761069267502937539408720 24904085056.69185465145182606089196 -> -258703556388226463687701.4884719589 Inexact Rounded +dqdiv2014 divide 5.535520011272625629610079879714705 -44343664650.57203052003068113531208 -> -1.248322630728089308975940533493562E-10 Inexact Rounded +dqdiv2015 divide 65919273712517865964325.99419625010 -314733354141381737378622515.7789054 -> -0.0002094448295521490616379784758911632 Inexact Rounded +dqdiv2016 divide -7.779172568193197107115275140431129E+759 -140453015639.3988987652895178782143 -> 5.538629792161641534962774244238115E+748 Inexact Rounded +dqdiv2017 divide 644314832597569.0181226067518178797 -115024585257425.1635759521565201075 -> -5.601540150356479257367687450922795 Inexact Rounded +dqdiv2018 divide 6.898640941579611450676592553286870E-47 -11272429881407851485163914999.25943 -> -6.119923578285338689371137648319280E-75 Inexact Rounded +dqdiv2019 divide -3591344544888727133.30819750163254 5329395.423792795661446561090331037 -> -673874662941.1968525589460533725290 Inexact Rounded +dqdiv2020 divide -7.682356781384631313156462724425838E+747 -6.60375855512219057281922141809940E+703 -> 1.163330960279556016678379128875149E+44 Inexact Rounded +dqdiv2021 divide -4511495596596941820863224.274679699 3365395017.263329795449661616090724 -> -1340554548115304.904166888018346299 Inexact Rounded +dqdiv2022 divide 5.211164127840931517263639608151299 164.5566381356276567012533847006453 -> 0.03166790587655228864478260157156510 Inexact Rounded +dqdiv2023 divide -49891.2243893458830384077684620383 -47179.9312961860747554053371171530 -> 1.057467084386767291602189656430268 Inexact Rounded +dqdiv2024 divide 15065477.47214268488077415462413353 4366211.120892953261309529740552596 -> 3.450469309661227984244545513441359 Inexact Rounded +dqdiv2025 divide 1.575670269440761846109602429612644E+370 653199649324740300.006185482643439 -> 2.412233795700359170904588548041481E+352 Inexact Rounded +dqdiv2026 divide -2112422311733448924573432192.620145 -80067206.03590693153848215848613406 -> 26383115089417660175.20102646756574 Inexact Rounded +dqdiv2027 divide -67096536051279809.32218611548721839 -869685412881941081664251990181.1049 -> 7.715035236584805921278566365231168E-14 Inexact Rounded +dqdiv2028 divide -58612908548962047.21866913425488972 -978449597531.3873665583475633831644 -> 59903.86085991703091236507859837023 Inexact Rounded +dqdiv2029 divide -133032412010942.1476864138213319796 -7.882059293498670705446528648201359E-428 -> 1.687787506504433064549515681693715E+441 Inexact Rounded +dqdiv2030 divide 1.83746698338966029492299716360513E+977 -9.897926608979649951672839879128603E+154 -> -1.856416051542212552042390218062458E+822 Inexact Rounded +dqdiv2031 divide -113742475841399236307128962.1507063 8298602.203049834732657567965262989 -> -13706221006665137826.16557393919929 Inexact Rounded +dqdiv2032 divide 196.4787574650754152995941808331862 929.6553388472318094427422117172394 -> 0.2113458066176526651006917922814018 Inexact Rounded +dqdiv2033 divide 71931221465.43867996282803628130350 3838685934206426257090718.402248853 -> 1.873850132527423413607199513324021E-14 Inexact Rounded +dqdiv2034 divide 488.4282502289651653783596246312885 -80.68940956806634280078706577953188 -> -6.053189047280693318844801899473272 Inexact Rounded +dqdiv2035 divide 9.001764344963921754981762913247394E-162 -8.585540973667205753734967645386919E-729 -> -1.048479574271827326396012573232934E+567 Inexact Rounded +dqdiv2036 divide -7.404133959409894743706402857145471E-828 -51.38159929460289711134684843086265 -> 1.441008855516029461032061785219773E-829 Inexact Rounded +dqdiv2037 divide 2.967520235574419794048994436040717E-613 -6252513855.91394894949879262731889 -> -4.746123405656409127572998751885338E-623 Inexact Rounded +dqdiv2038 divide -18826852654824040505.83920366765051 -6336924877942437992590557460147340 -> 2.970976146546494669807886278519194E-15 Inexact Rounded +dqdiv2039 divide -8.101406784809197604949584001735949E+561 4.823300306948942821076681658771635E+361 -> -1.679639721610839204738445747238987E+200 Inexact Rounded +dqdiv2040 divide -6.11981977773094052331062585191723E+295 1.507610253755339328302779005586534E+238 -> -4.059285058911577244044418416044763E+57 Inexact Rounded +dqdiv2041 divide 6.472638850046815880599220534274055E-596 -4.475233712083047516933911786159972 -> -1.446324207062261745520496475778879E-596 Inexact Rounded +dqdiv2042 divide -84438593330.71277839631144509397112 -586684596204401664208947.4054879633 -> 1.439250218550041228759983937772504E-13 Inexact Rounded +dqdiv2043 divide 9.354533233294022616695815656704369E-24 405.500390626135304252144163591746 -> 2.306911028827774549740571229736198E-26 Inexact Rounded +dqdiv2044 divide 985606423350210.7374876650149957881 -36811563697.41925681866694859828794 -> -26774.36990864119445335813354717711 Inexact Rounded +dqdiv2045 divide -8.187280774177715706278002247766311E-123 -38784124393.91212870828430001300068 -> 2.110987653356139147357240727794365E-133 Inexact Rounded +dqdiv2046 divide -4.612203126350070903459245798371657E+912 7.971562182727956290901984736800519E+64 -> -5.785820922708683237098826662769748E+847 Inexact Rounded +dqdiv2047 divide 4.661015909421485298247928967977089E+888 -6.360911253323922338737311563845581E+388 -> -7.327591478321365980156654539638836E+499 Inexact Rounded +dqdiv2048 divide 9156078172903.257500003260710833030 7.189796653262147139071634237964074E-90 -> 1.273482215766000994365201545096026E+102 Inexact Rounded +dqdiv2049 divide -1.710722303327476586373477781276586E-311 -3167561628260156837329323.729380695 -> 5.400754599578613984875752958645655E-336 Inexact Rounded +dqdiv2050 divide -4.647935210881806238321616345413021E-878 209388.5431867744648177308460639582 -> -2.219765771394593733140494297388140E-883 Inexact Rounded +dqdiv2051 divide 5958.694728395760992719084781582700 4.541510156564315632536353171846096E-746 -> 1.312051393253638664947852693005480E+749 Inexact Rounded +dqdiv2052 divide -7.935732544649702175256699886872093E-489 -7.433329073664793138998765647467971E+360 -> 1.067587949626076917672271619664656E-849 Inexact Rounded +dqdiv2053 divide -2746650864601157.863589959939901350 7.016684945507647528907184694359598E+548 -> -3.914456593009309529351254950429932E-534 Inexact Rounded +dqdiv2054 divide 3605149408631197365447953.994569178 -75614025825649082.78264864428237833 -> -47678315.88472693507060063188020532 Inexact Rounded +dqdiv2055 divide 788194320921798404906375214.196349 -6.222718148433247384932573401976337E-418 -> -1.266639918634671803982222244977287E+444 Inexact Rounded +dqdiv2056 divide 5620722730534752.758208943447603211 6.843552841168538319123000917657759E-139 -> 8.213164800485434666629970443739554E+153 Inexact Rounded +dqdiv2057 divide 7304534676713703938102.403949019402 -576169.3685010935108153023803590835 -> -12677756014201995.31969237144394772 Inexact Rounded +dqdiv2058 divide 8067918762.134621639254916786945547 -8.774771480055536009105596163864758E+954 -> -9.194448858836332156766764605125245E-946 Inexact Rounded +dqdiv2059 divide 8.702093454123046507578256899537563E-324 -5.875399733016018404580201176576293E-401 -> -1.481106622452052581470443526957335E+77 Inexact Rounded +dqdiv2060 divide -41426.01662518451861386352415092356 90.00146621684478300510769802013464 -> -460.2815750287318692732067709176200 Inexact Rounded + +-- random divide tests with result near 1 +dqdiv4001 divide 2003100352770753969878925664524900 2003100352770753969878925664497824 -> 1.000000000000000000000000000013517 Inexact Rounded +dqdiv4002 divide 4817785793916490652579552318371645 4817785793916490652579552318362097 -> 1.000000000000000000000000000001982 Inexact Rounded +dqdiv4003 divide 8299187410920067325648068439560282 8299187410920067325648068439591159 -> 0.9999999999999999999999999999962795 Inexact Rounded +dqdiv4004 divide 5641088455897407044544461785365899 5641088455897407044544461785389965 -> 0.9999999999999999999999999999957338 Inexact Rounded +dqdiv4005 divide 5752274694706545359326361313490424 5752274694706545359326361313502723 -> 0.9999999999999999999999999999978619 Inexact Rounded +dqdiv4006 divide 6762079477373670594829319346099665 6762079477373670594829319346132579 -> 0.9999999999999999999999999999951326 Inexact Rounded +dqdiv4007 divide 7286425153691890341633023222602916 7286425153691890341633023222606556 -> 0.9999999999999999999999999999995004 Inexact Rounded +dqdiv4008 divide 9481233991901305727648306421946655 9481233991901305727648306421919124 -> 1.000000000000000000000000000002904 Inexact Rounded +dqdiv4009 divide 4282053941893951742029444065614311 4282053941893951742029444065583077 -> 1.000000000000000000000000000007294 Inexact Rounded +dqdiv4010 divide 626888225441250639741781850338695 626888225441250639741781850327299 -> 1.000000000000000000000000000018179 Inexact Rounded +dqdiv4011 divide 3860973649222028009456598604468547 3860973649222028009456598604476849 -> 0.9999999999999999999999999999978498 Inexact Rounded +dqdiv4012 divide 4753157080127468127908060607821839 4753157080127468127908060607788379 -> 1.000000000000000000000000000007040 Inexact Rounded +dqdiv4013 divide 552448546203754062805706277880419 552448546203754062805706277881903 -> 0.9999999999999999999999999999973138 Inexact Rounded +dqdiv4014 divide 8405954527952158455323713728917395 8405954527952158455323713728933866 -> 0.9999999999999999999999999999980406 Inexact Rounded +dqdiv4015 divide 7554096502235321142555802238016116 7554096502235321142555802238026546 -> 0.9999999999999999999999999999986193 Inexact Rounded +dqdiv4016 divide 4053257674127518606871054934746782 4053257674127518606871054934767355 -> 0.9999999999999999999999999999949243 Inexact Rounded +dqdiv4017 divide 7112419420755090454716888844011582 7112419420755090454716888844038105 -> 0.9999999999999999999999999999962709 Inexact Rounded +dqdiv4018 divide 3132302137520072728164549730911846 3132302137520072728164549730908416 -> 1.000000000000000000000000000001095 Inexact Rounded +dqdiv4019 divide 4788374045841416355706715048161013 4788374045841416355706715048190077 -> 0.9999999999999999999999999999939303 Inexact Rounded +dqdiv4020 divide 9466021636047630218238075099510597 9466021636047630218238075099484053 -> 1.000000000000000000000000000002804 Inexact Rounded +dqdiv4021 divide 912742745646765625597399692138650 912742745646765625597399692139042 -> 0.9999999999999999999999999999995705 Inexact Rounded +dqdiv4022 divide 9508402742933643208806264897188504 9508402742933643208806264897195973 -> 0.9999999999999999999999999999992145 Inexact Rounded +dqdiv4023 divide 1186956795727233704962361914360895 1186956795727233704962361914329577 -> 1.000000000000000000000000000026385 Inexact Rounded +dqdiv4024 divide 5972210268839014812696916170967938 5972210268839014812696916170954974 -> 1.000000000000000000000000000002171 Inexact Rounded +dqdiv4025 divide 2303801625521619930894460139793140 2303801625521619930894460139799643 -> 0.9999999999999999999999999999971773 Inexact Rounded +dqdiv4026 divide 6022231560002898264777393473966595 6022231560002898264777393473947198 -> 1.000000000000000000000000000003221 Inexact Rounded +dqdiv4027 divide 8426148335801396199969346032210893 8426148335801396199969346032203179 -> 1.000000000000000000000000000000915 Inexact Rounded +dqdiv4028 divide 8812278947028784637382847098411749 8812278947028784637382847098385317 -> 1.000000000000000000000000000002999 Inexact Rounded +dqdiv4029 divide 8145282002348367383264197170116146 8145282002348367383264197170083988 -> 1.000000000000000000000000000003948 Inexact Rounded +dqdiv4030 divide 6821577571876840153123510107387026 6821577571876840153123510107418008 -> 0.9999999999999999999999999999954582 Inexact Rounded +dqdiv4031 divide 9018555319518966970480565482023720 9018555319518966970480565482013346 -> 1.000000000000000000000000000001150 Inexact Rounded +dqdiv4032 divide 4602155712998228449640717252788864 4602155712998228449640717252818502 -> 0.9999999999999999999999999999935600 Inexact Rounded +dqdiv4033 divide 6675607481522785614506828292264472 6675607481522785614506828292277100 -> 0.9999999999999999999999999999981083 Inexact Rounded +dqdiv4034 divide 4015881516871833897766945836264472 4015881516871833897766945836262645 -> 1.000000000000000000000000000000455 Inexact Rounded +dqdiv4035 divide 1415580205933411837595459716910365 1415580205933411837595459716880139 -> 1.000000000000000000000000000021352 Inexact Rounded +dqdiv4036 divide 9432968297069542816752035276361552 9432968297069542816752035276353054 -> 1.000000000000000000000000000000901 Inexact Rounded +dqdiv4037 divide 4799319591303848500532766682140658 4799319591303848500532766682172655 -> 0.9999999999999999999999999999933330 Inexact Rounded +dqdiv4038 divide 316854270732839529790584284987472 316854270732839529790584285004832 -> 0.9999999999999999999999999999452114 Inexact Rounded +dqdiv4039 divide 3598981300592490427826027975697415 3598981300592490427826027975686712 -> 1.000000000000000000000000000002974 Inexact Rounded +dqdiv4040 divide 1664315435694461371155800682196520 1664315435694461371155800682195617 -> 1.000000000000000000000000000000543 Inexact Rounded +dqdiv4041 divide 1680872316531128890102855316510581 1680872316531128890102855316495545 -> 1.000000000000000000000000000008945 Inexact Rounded +dqdiv4042 divide 9881274879566405475755499281644730 9881274879566405475755499281615743 -> 1.000000000000000000000000000002934 Inexact Rounded +dqdiv4043 divide 4737225957717466960447204232279216 4737225957717466960447204232277452 -> 1.000000000000000000000000000000372 Inexact Rounded +dqdiv4044 divide 2482097379414867061213319346418288 2482097379414867061213319346387936 -> 1.000000000000000000000000000012228 Inexact Rounded +dqdiv4045 divide 7406977595233762723576434122161868 7406977595233762723576434122189042 -> 0.9999999999999999999999999999963313 Inexact Rounded +dqdiv4046 divide 228782057757566047086593281773577 228782057757566047086593281769727 -> 1.000000000000000000000000000016828 Inexact Rounded +dqdiv4047 divide 2956594270240579648823270540367653 2956594270240579648823270540368556 -> 0.9999999999999999999999999999996946 Inexact Rounded +dqdiv4048 divide 6326964098897620620534136767634340 6326964098897620620534136767619339 -> 1.000000000000000000000000000002371 Inexact Rounded +dqdiv4049 divide 414586440456590215247002678327800 414586440456590215247002678316922 -> 1.000000000000000000000000000026238 Inexact Rounded +dqdiv4050 divide 7364552208570039386220505636779125 7364552208570039386220505636803548 -> 0.9999999999999999999999999999966837 Inexact Rounded +dqdiv4051 divide 5626266749902369710022824950590056 5626266749902369710022824950591008 -> 0.9999999999999999999999999999998308 Inexact Rounded +dqdiv4052 divide 4863278293916197454987481343460484 4863278293916197454987481343442522 -> 1.000000000000000000000000000003693 Inexact Rounded +dqdiv4053 divide 1170713582030637359713249796835483 1170713582030637359713249796823345 -> 1.000000000000000000000000000010368 Inexact Rounded +dqdiv4054 divide 9838062494725965667776326556052931 9838062494725965667776326556061002 -> 0.9999999999999999999999999999991796 Inexact Rounded +dqdiv4055 divide 4071388731298861093005687091498922 4071388731298861093005687091498278 -> 1.000000000000000000000000000000158 Inexact Rounded +dqdiv4056 divide 8753155722324706795855038590272526 8753155722324706795855038590276656 -> 0.9999999999999999999999999999995282 Inexact Rounded +dqdiv4057 divide 4399941911533273418844742658240485 4399941911533273418844742658219891 -> 1.000000000000000000000000000004681 Inexact Rounded +dqdiv4058 divide 4127884159949503677776430620050269 4127884159949503677776430620026091 -> 1.000000000000000000000000000005857 Inexact Rounded +dqdiv4059 divide 5536160822360800067042528317438808 5536160822360800067042528317450687 -> 0.9999999999999999999999999999978543 Inexact Rounded +dqdiv4060 divide 3973234998468664936671088237710246 3973234998468664936671088237741886 -> 0.9999999999999999999999999999920367 Inexact Rounded +dqdiv4061 divide 9824855935638263593410444142327358 9824855935638263593410444142328576 -> 0.9999999999999999999999999999998760 Inexact Rounded +dqdiv4062 divide 5917078517340218131867327300814867 5917078517340218131867327300788701 -> 1.000000000000000000000000000004422 Inexact Rounded +dqdiv4063 divide 4354236601830544882286139612521362 4354236601830544882286139612543223 -> 0.9999999999999999999999999999949794 Inexact Rounded +dqdiv4064 divide 8058474772375259017342110013891294 8058474772375259017342110013906792 -> 0.9999999999999999999999999999980768 Inexact Rounded +dqdiv4065 divide 5519604020981748170517093746166328 5519604020981748170517093746181763 -> 0.9999999999999999999999999999972036 Inexact Rounded +dqdiv4066 divide 1502130966879805458831323782443139 1502130966879805458831323782412213 -> 1.000000000000000000000000000020588 Inexact Rounded +dqdiv4067 divide 562795633719481212915159787980270 562795633719481212915159788007066 -> 0.9999999999999999999999999999523877 Inexact Rounded +dqdiv4068 divide 6584743324494664273941281557268878 6584743324494664273941281557258945 -> 1.000000000000000000000000000001508 Inexact Rounded +dqdiv4069 divide 3632000327285743997976431109416500 3632000327285743997976431109408107 -> 1.000000000000000000000000000002311 Inexact Rounded +dqdiv4070 divide 1145827237315430089388953838561450 1145827237315430089388953838527332 -> 1.000000000000000000000000000029776 Inexact Rounded +dqdiv4071 divide 8874431010357691869725372317350380 8874431010357691869725372317316472 -> 1.000000000000000000000000000003821 Inexact Rounded +dqdiv4072 divide 992948718902804648119753141202196 992948718902804648119753141235222 -> 0.9999999999999999999999999999667395 Inexact Rounded +dqdiv4073 divide 2522735183374218505142417265439989 2522735183374218505142417265453779 -> 0.9999999999999999999999999999945337 Inexact Rounded +dqdiv4074 divide 2668419161912936508006872303501052 2668419161912936508006872303471036 -> 1.000000000000000000000000000011249 Inexact Rounded +dqdiv4075 divide 3036169085665186712590941111775092 3036169085665186712590941111808846 -> 0.9999999999999999999999999999888827 Inexact Rounded +dqdiv4076 divide 9441634604917231638508898934006147 9441634604917231638508898934000288 -> 1.000000000000000000000000000000621 Inexact Rounded +dqdiv4077 divide 2677301353164377091111458811839190 2677301353164377091111458811867722 -> 0.9999999999999999999999999999893430 Inexact Rounded +dqdiv4078 divide 6844979203112066166583765857171426 6844979203112066166583765857189682 -> 0.9999999999999999999999999999973329 Inexact Rounded +dqdiv4079 divide 2220337435141796724323783960231661 2220337435141796724323783960208778 -> 1.000000000000000000000000000010306 Inexact Rounded +dqdiv4080 divide 6447424700019783931569996989561380 6447424700019783931569996989572454 -> 0.9999999999999999999999999999982824 Inexact Rounded +dqdiv4081 divide 7512856762696607119847092195587180 7512856762696607119847092195557346 -> 1.000000000000000000000000000003971 Inexact Rounded +dqdiv4082 divide 7395261981193960399087819077237482 7395261981193960399087819077242487 -> 0.9999999999999999999999999999993232 Inexact Rounded +dqdiv4083 divide 2253442467682584035792724884376735 2253442467682584035792724884407178 -> 0.9999999999999999999999999999864904 Inexact Rounded +dqdiv4084 divide 8153138680300213135577336466190997 8153138680300213135577336466220607 -> 0.9999999999999999999999999999963683 Inexact Rounded +dqdiv4085 divide 4668731252254148074041022681801390 4668731252254148074041022681778101 -> 1.000000000000000000000000000004988 Inexact Rounded +dqdiv4086 divide 6078404557993669696040425501815056 6078404557993669696040425501797612 -> 1.000000000000000000000000000002870 Inexact Rounded +dqdiv4087 divide 2306352359874261623223356878316278 2306352359874261623223356878335612 -> 0.9999999999999999999999999999916171 Inexact Rounded +dqdiv4088 divide 3264842186668480362900909564091908 3264842186668480362900909564058658 -> 1.000000000000000000000000000010184 Inexact Rounded +dqdiv4089 divide 6971985047279636878957959608612204 6971985047279636878957959608615088 -> 0.9999999999999999999999999999995863 Inexact Rounded +dqdiv4090 divide 5262810889952721235466445973816257 5262810889952721235466445973783077 -> 1.000000000000000000000000000006305 Inexact Rounded +dqdiv4091 divide 7947944731035267178548357070080288 7947944731035267178548357070061339 -> 1.000000000000000000000000000002384 Inexact Rounded +dqdiv4092 divide 5071808908395375108383035800443229 5071808908395375108383035800412429 -> 1.000000000000000000000000000006073 Inexact Rounded +dqdiv4093 divide 2043146542084503655511507209262969 2043146542084503655511507209249263 -> 1.000000000000000000000000000006708 Inexact Rounded +dqdiv4094 divide 4097632735384534181661959731264802 4097632735384534181661959731234499 -> 1.000000000000000000000000000007395 Inexact Rounded +dqdiv4095 divide 3061477642831387489729464587044430 3061477642831387489729464587059452 -> 0.9999999999999999999999999999950932 Inexact Rounded +dqdiv4096 divide 3429854941039776159498802936252638 3429854941039776159498802936246415 -> 1.000000000000000000000000000001814 Inexact Rounded +dqdiv4097 divide 4874324979578599700024133278284545 4874324979578599700024133278262131 -> 1.000000000000000000000000000004598 Inexact Rounded +dqdiv4098 divide 5701652369691833541455978515820882 5701652369691833541455978515834854 -> 0.9999999999999999999999999999975495 Inexact Rounded +dqdiv4099 divide 2928205728402945266953255632343113 2928205728402945266953255632373794 -> 0.9999999999999999999999999999895223 Inexact Rounded + +-- Null tests +dqdiv9998 divide 10 # -> NaN Invalid_operation +dqdiv9999 divide # 10 -> NaN Invalid_operation + Added: python/branches/release25-maint/Lib/test/decimaltestdata/dqDivideInt.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/dqDivideInt.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,453 @@ +------------------------------------------------------------------------ +-- dqDivideInt.decTest -- decQuad integer division -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +extended: 1 +clamp: 1 +precision: 34 +maxExponent: 6144 +minExponent: -6143 +rounding: half_even + + +dqdvi001 divideint 1 1 -> 1 +dqdvi002 divideint 2 1 -> 2 +dqdvi003 divideint 1 2 -> 0 +dqdvi004 divideint 2 2 -> 1 +dqdvi005 divideint 0 1 -> 0 +dqdvi006 divideint 0 2 -> 0 +dqdvi007 divideint 1 3 -> 0 +dqdvi008 divideint 2 3 -> 0 +dqdvi009 divideint 3 3 -> 1 + +dqdvi010 divideint 2.4 1 -> 2 +dqdvi011 divideint 2.4 -1 -> -2 +dqdvi012 divideint -2.4 1 -> -2 +dqdvi013 divideint -2.4 -1 -> 2 +dqdvi014 divideint 2.40 1 -> 2 +dqdvi015 divideint 2.400 1 -> 2 +dqdvi016 divideint 2.4 2 -> 1 +dqdvi017 divideint 2.400 2 -> 1 +dqdvi018 divideint 2. 2 -> 1 +dqdvi019 divideint 20 20 -> 1 + +dqdvi020 divideint 187 187 -> 1 +dqdvi021 divideint 5 2 -> 2 +dqdvi022 divideint 5 2.0 -> 2 +dqdvi023 divideint 5 2.000 -> 2 +dqdvi024 divideint 5 0.200 -> 25 +dqdvi025 divideint 5 0.200 -> 25 + +dqdvi030 divideint 1 2 -> 0 +dqdvi031 divideint 1 4 -> 0 +dqdvi032 divideint 1 8 -> 0 +dqdvi033 divideint 1 16 -> 0 +dqdvi034 divideint 1 32 -> 0 +dqdvi035 divideint 1 64 -> 0 +dqdvi040 divideint 1 -2 -> -0 +dqdvi041 divideint 1 -4 -> -0 +dqdvi042 divideint 1 -8 -> -0 +dqdvi043 divideint 1 -16 -> -0 +dqdvi044 divideint 1 -32 -> -0 +dqdvi045 divideint 1 -64 -> -0 +dqdvi050 divideint -1 2 -> -0 +dqdvi051 divideint -1 4 -> -0 +dqdvi052 divideint -1 8 -> -0 +dqdvi053 divideint -1 16 -> -0 +dqdvi054 divideint -1 32 -> -0 +dqdvi055 divideint -1 64 -> -0 +dqdvi060 divideint -1 -2 -> 0 +dqdvi061 divideint -1 -4 -> 0 +dqdvi062 divideint -1 -8 -> 0 +dqdvi063 divideint -1 -16 -> 0 +dqdvi064 divideint -1 -32 -> 0 +dqdvi065 divideint -1 -64 -> 0 + +-- similar with powers of ten +dqdvi160 divideint 1 1 -> 1 +dqdvi161 divideint 1 10 -> 0 +dqdvi162 divideint 1 100 -> 0 +dqdvi163 divideint 1 1000 -> 0 +dqdvi164 divideint 1 10000 -> 0 +dqdvi165 divideint 1 100000 -> 0 +dqdvi166 divideint 1 1000000 -> 0 +dqdvi167 divideint 1 10000000 -> 0 +dqdvi168 divideint 1 100000000 -> 0 +dqdvi170 divideint 1 -1 -> -1 +dqdvi171 divideint 1 -10 -> -0 +dqdvi172 divideint 1 -100 -> -0 +dqdvi173 divideint 1 -1000 -> -0 +dqdvi174 divideint 1 -10000 -> -0 +dqdvi175 divideint 1 -100000 -> -0 +dqdvi176 divideint 1 -1000000 -> -0 +dqdvi177 divideint 1 -10000000 -> -0 +dqdvi178 divideint 1 -100000000 -> -0 +dqdvi180 divideint -1 1 -> -1 +dqdvi181 divideint -1 10 -> -0 +dqdvi182 divideint -1 100 -> -0 +dqdvi183 divideint -1 1000 -> -0 +dqdvi184 divideint -1 10000 -> -0 +dqdvi185 divideint -1 100000 -> -0 +dqdvi186 divideint -1 1000000 -> -0 +dqdvi187 divideint -1 10000000 -> -0 +dqdvi188 divideint -1 100000000 -> -0 +dqdvi190 divideint -1 -1 -> 1 +dqdvi191 divideint -1 -10 -> 0 +dqdvi192 divideint -1 -100 -> 0 +dqdvi193 divideint -1 -1000 -> 0 +dqdvi194 divideint -1 -10000 -> 0 +dqdvi195 divideint -1 -100000 -> 0 +dqdvi196 divideint -1 -1000000 -> 0 +dqdvi197 divideint -1 -10000000 -> 0 +dqdvi198 divideint -1 -100000000 -> 0 + +-- some long operand (at p=9) cases +dqdvi070 divideint 999999999 1 -> 999999999 +dqdvi071 divideint 999999999.4 1 -> 999999999 +dqdvi072 divideint 999999999.5 1 -> 999999999 +dqdvi073 divideint 999999999.9 1 -> 999999999 +dqdvi074 divideint 999999999.999 1 -> 999999999 + +dqdvi090 divideint 0. 1 -> 0 +dqdvi091 divideint .0 1 -> 0 +dqdvi092 divideint 0.00 1 -> 0 +dqdvi093 divideint 0.00E+9 1 -> 0 +dqdvi094 divideint 0.0000E-50 1 -> 0 + +dqdvi100 divideint 1 1 -> 1 +dqdvi101 divideint 1 2 -> 0 +dqdvi102 divideint 1 3 -> 0 +dqdvi103 divideint 1 4 -> 0 +dqdvi104 divideint 1 5 -> 0 +dqdvi105 divideint 1 6 -> 0 +dqdvi106 divideint 1 7 -> 0 +dqdvi107 divideint 1 8 -> 0 +dqdvi108 divideint 1 9 -> 0 +dqdvi109 divideint 1 10 -> 0 +dqdvi110 divideint 1 1 -> 1 +dqdvi111 divideint 2 1 -> 2 +dqdvi112 divideint 3 1 -> 3 +dqdvi113 divideint 4 1 -> 4 +dqdvi114 divideint 5 1 -> 5 +dqdvi115 divideint 6 1 -> 6 +dqdvi116 divideint 7 1 -> 7 +dqdvi117 divideint 8 1 -> 8 +dqdvi118 divideint 9 1 -> 9 +dqdvi119 divideint 10 1 -> 10 + +-- from DiagBigDecimal +dqdvi131 divideint 101.3 1 -> 101 +dqdvi132 divideint 101.0 1 -> 101 +dqdvi133 divideint 101.3 3 -> 33 +dqdvi134 divideint 101.0 3 -> 33 +dqdvi135 divideint 2.4 1 -> 2 +dqdvi136 divideint 2.400 1 -> 2 +dqdvi137 divideint 18 18 -> 1 +dqdvi138 divideint 1120 1000 -> 1 +dqdvi139 divideint 2.4 2 -> 1 +dqdvi140 divideint 2.400 2 -> 1 +dqdvi141 divideint 0.5 2.000 -> 0 +dqdvi142 divideint 8.005 7 -> 1 +dqdvi143 divideint 5 2 -> 2 +dqdvi144 divideint 0 2 -> 0 +dqdvi145 divideint 0.00 2 -> 0 + +-- Others +dqdvi150 divideint 12345 4.999 -> 2469 +dqdvi151 divideint 12345 4.99 -> 2473 +dqdvi152 divideint 12345 4.9 -> 2519 +dqdvi153 divideint 12345 5 -> 2469 +dqdvi154 divideint 12345 5.1 -> 2420 +dqdvi155 divideint 12345 5.01 -> 2464 +dqdvi156 divideint 12345 5.001 -> 2468 +dqdvi157 divideint 101 7.6 -> 13 + +-- Various flavours of divideint by 0 +dqdvi201 divideint 0 0 -> NaN Division_undefined +dqdvi202 divideint 0.0E5 0 -> NaN Division_undefined +dqdvi203 divideint 0.000 0 -> NaN Division_undefined +dqdvi204 divideint 0.0001 0 -> Infinity Division_by_zero +dqdvi205 divideint 0.01 0 -> Infinity Division_by_zero +dqdvi206 divideint 0.1 0 -> Infinity Division_by_zero +dqdvi207 divideint 1 0 -> Infinity Division_by_zero +dqdvi208 divideint 1 0.0 -> Infinity Division_by_zero +dqdvi209 divideint 10 0.0 -> Infinity Division_by_zero +dqdvi210 divideint 1E+100 0.0 -> Infinity Division_by_zero +dqdvi211 divideint 1E+380 0 -> Infinity Division_by_zero +dqdvi214 divideint -0.0001 0 -> -Infinity Division_by_zero +dqdvi215 divideint -0.01 0 -> -Infinity Division_by_zero +dqdvi216 divideint -0.1 0 -> -Infinity Division_by_zero +dqdvi217 divideint -1 0 -> -Infinity Division_by_zero +dqdvi218 divideint -1 0.0 -> -Infinity Division_by_zero +dqdvi219 divideint -10 0.0 -> -Infinity Division_by_zero +dqdvi220 divideint -1E+100 0.0 -> -Infinity Division_by_zero +dqdvi221 divideint -1E+380 0 -> -Infinity Division_by_zero + +-- test some cases that are close to exponent overflow +dqdvi270 divideint 1 1e384 -> 0 +dqdvi271 divideint 1 0.9e384 -> 0 +dqdvi272 divideint 1 0.99e384 -> 0 +dqdvi273 divideint 1 0.9999999999999999e384 -> 0 +dqdvi274 divideint 9e384 1 -> NaN Division_impossible +dqdvi275 divideint 9.9e384 1 -> NaN Division_impossible +dqdvi276 divideint 9.99e384 1 -> NaN Division_impossible +dqdvi277 divideint 9.999999999999999e384 1 -> NaN Division_impossible + +dqdvi280 divideint 0.1 9e-383 -> NaN Division_impossible +dqdvi281 divideint 0.1 99e-383 -> NaN Division_impossible +dqdvi282 divideint 0.1 999e-383 -> NaN Division_impossible +dqdvi283 divideint 0.1 9e-382 -> NaN Division_impossible +dqdvi284 divideint 0.1 99e-382 -> NaN Division_impossible + +-- GD edge cases: lhs smaller than rhs but more digits +dqdvi301 divideint 0.9 2 -> 0 +dqdvi302 divideint 0.9 2.0 -> 0 +dqdvi303 divideint 0.9 2.1 -> 0 +dqdvi304 divideint 0.9 2.00 -> 0 +dqdvi305 divideint 0.9 2.01 -> 0 +dqdvi306 divideint 0.12 1 -> 0 +dqdvi307 divideint 0.12 1.0 -> 0 +dqdvi308 divideint 0.12 1.00 -> 0 +dqdvi309 divideint 0.12 1.0 -> 0 +dqdvi310 divideint 0.12 1.00 -> 0 +dqdvi311 divideint 0.12 2 -> 0 +dqdvi312 divideint 0.12 2.0 -> 0 +dqdvi313 divideint 0.12 2.1 -> 0 +dqdvi314 divideint 0.12 2.00 -> 0 +dqdvi315 divideint 0.12 2.01 -> 0 + +-- edge cases of impossible +dqdvi330 divideint 1234567987654321987654321890123456 10 -> 123456798765432198765432189012345 +dqdvi331 divideint 1234567987654321987654321890123456 1 -> 1234567987654321987654321890123456 +dqdvi332 divideint 1234567987654321987654321890123456 0.1 -> NaN Division_impossible +dqdvi333 divideint 1234567987654321987654321890123456 0.01 -> NaN Division_impossible + +-- overflow and underflow tests [from divide] +dqdvi1051 divideint 1e+277 1e-311 -> NaN Division_impossible +dqdvi1052 divideint 1e+277 -1e-311 -> NaN Division_impossible +dqdvi1053 divideint -1e+277 1e-311 -> NaN Division_impossible +dqdvi1054 divideint -1e+277 -1e-311 -> NaN Division_impossible +dqdvi1055 divideint 1e-277 1e+311 -> 0 +dqdvi1056 divideint 1e-277 -1e+311 -> -0 +dqdvi1057 divideint -1e-277 1e+311 -> -0 +dqdvi1058 divideint -1e-277 -1e+311 -> 0 + +-- 'subnormal' boundary (all hard underflow or overflow in base arithemtic) +dqdvi1060 divideint 1e-291 1e+101 -> 0 +dqdvi1061 divideint 1e-291 1e+102 -> 0 +dqdvi1062 divideint 1e-291 1e+103 -> 0 +dqdvi1063 divideint 1e-291 1e+104 -> 0 +dqdvi1064 divideint 1e-291 1e+105 -> 0 +dqdvi1065 divideint 1e-291 1e+106 -> 0 +dqdvi1066 divideint 1e-291 1e+107 -> 0 +dqdvi1067 divideint 1e-291 1e+108 -> 0 +dqdvi1068 divideint 1e-291 1e+109 -> 0 +dqdvi1069 divideint 1e-291 1e+110 -> 0 + +dqdvi1101 divideint 1.0000E-394 1 -> 0 +dqdvi1102 divideint 1.000E-394 1e+1 -> 0 +dqdvi1103 divideint 1.00E-394 1e+2 -> 0 + +dqdvi1118 divideint 1E-394 1e+4 -> 0 +dqdvi1119 divideint 3E-394 -1e+5 -> -0 +dqdvi1120 divideint 5E-394 1e+5 -> 0 + +dqdvi1124 divideint 1E-394 -1e+4 -> -0 +dqdvi1130 divideint 3.0E-394 -1e+5 -> -0 + +dqdvi1131 divideint 1.0E-199 1e+200 -> 0 +dqdvi1132 divideint 1.0E-199 1e+199 -> 0 +dqdvi1133 divideint 1.0E-199 1e+198 -> 0 +dqdvi1134 divideint 2.0E-199 2e+198 -> 0 +dqdvi1135 divideint 4.0E-199 4e+198 -> 0 + +-- long operand checks +dqdvi401 divideint 12345678000 100 -> 123456780 +dqdvi402 divideint 1 12345678000 -> 0 +dqdvi403 divideint 1234567800 10 -> 123456780 +dqdvi404 divideint 1 1234567800 -> 0 +dqdvi405 divideint 1234567890 10 -> 123456789 +dqdvi406 divideint 1 1234567890 -> 0 +dqdvi407 divideint 1234567891 10 -> 123456789 +dqdvi408 divideint 1 1234567891 -> 0 +dqdvi409 divideint 12345678901 100 -> 123456789 +dqdvi410 divideint 1 12345678901 -> 0 +dqdvi411 divideint 1234567896 10 -> 123456789 +dqdvi412 divideint 1 1234567896 -> 0 +dqdvi413 divideint 12345678948 100 -> 123456789 +dqdvi414 divideint 12345678949 100 -> 123456789 +dqdvi415 divideint 12345678950 100 -> 123456789 +dqdvi416 divideint 12345678951 100 -> 123456789 +dqdvi417 divideint 12345678999 100 -> 123456789 +dqdvi441 divideint 12345678000 1 -> 12345678000 +dqdvi442 divideint 1 12345678000 -> 0 +dqdvi443 divideint 1234567800 1 -> 1234567800 +dqdvi444 divideint 1 1234567800 -> 0 +dqdvi445 divideint 1234567890 1 -> 1234567890 +dqdvi446 divideint 1 1234567890 -> 0 +dqdvi447 divideint 1234567891 1 -> 1234567891 +dqdvi448 divideint 1 1234567891 -> 0 +dqdvi449 divideint 12345678901 1 -> 12345678901 +dqdvi450 divideint 1 12345678901 -> 0 +dqdvi451 divideint 1234567896 1 -> 1234567896 +dqdvi452 divideint 1 1234567896 -> 0 + +-- more zeros, etc. +dqdvi531 divideint 5.00 1E-3 -> 5000 +dqdvi532 divideint 00.00 0.000 -> NaN Division_undefined +dqdvi533 divideint 00.00 0E-3 -> NaN Division_undefined +dqdvi534 divideint 0 -0 -> NaN Division_undefined +dqdvi535 divideint -0 0 -> NaN Division_undefined +dqdvi536 divideint -0 -0 -> NaN Division_undefined + +dqdvi541 divideint 0 -1 -> -0 +dqdvi542 divideint -0 -1 -> 0 +dqdvi543 divideint 0 1 -> 0 +dqdvi544 divideint -0 1 -> -0 +dqdvi545 divideint -1 0 -> -Infinity Division_by_zero +dqdvi546 divideint -1 -0 -> Infinity Division_by_zero +dqdvi547 divideint 1 0 -> Infinity Division_by_zero +dqdvi548 divideint 1 -0 -> -Infinity Division_by_zero + +dqdvi551 divideint 0.0 -1 -> -0 +dqdvi552 divideint -0.0 -1 -> 0 +dqdvi553 divideint 0.0 1 -> 0 +dqdvi554 divideint -0.0 1 -> -0 +dqdvi555 divideint -1.0 0 -> -Infinity Division_by_zero +dqdvi556 divideint -1.0 -0 -> Infinity Division_by_zero +dqdvi557 divideint 1.0 0 -> Infinity Division_by_zero +dqdvi558 divideint 1.0 -0 -> -Infinity Division_by_zero + +dqdvi561 divideint 0 -1.0 -> -0 +dqdvi562 divideint -0 -1.0 -> 0 +dqdvi563 divideint 0 1.0 -> 0 +dqdvi564 divideint -0 1.0 -> -0 +dqdvi565 divideint -1 0.0 -> -Infinity Division_by_zero +dqdvi566 divideint -1 -0.0 -> Infinity Division_by_zero +dqdvi567 divideint 1 0.0 -> Infinity Division_by_zero +dqdvi568 divideint 1 -0.0 -> -Infinity Division_by_zero + +dqdvi571 divideint 0.0 -1.0 -> -0 +dqdvi572 divideint -0.0 -1.0 -> 0 +dqdvi573 divideint 0.0 1.0 -> 0 +dqdvi574 divideint -0.0 1.0 -> -0 +dqdvi575 divideint -1.0 0.0 -> -Infinity Division_by_zero +dqdvi576 divideint -1.0 -0.0 -> Infinity Division_by_zero +dqdvi577 divideint 1.0 0.0 -> Infinity Division_by_zero +dqdvi578 divideint 1.0 -0.0 -> -Infinity Division_by_zero + +-- Specials +dqdvi580 divideint Inf -Inf -> NaN Invalid_operation +dqdvi581 divideint Inf -1000 -> -Infinity +dqdvi582 divideint Inf -1 -> -Infinity +dqdvi583 divideint Inf -0 -> -Infinity +dqdvi584 divideint Inf 0 -> Infinity +dqdvi585 divideint Inf 1 -> Infinity +dqdvi586 divideint Inf 1000 -> Infinity +dqdvi587 divideint Inf Inf -> NaN Invalid_operation +dqdvi588 divideint -1000 Inf -> -0 +dqdvi589 divideint -Inf Inf -> NaN Invalid_operation +dqdvi590 divideint -1 Inf -> -0 +dqdvi591 divideint -0 Inf -> -0 +dqdvi592 divideint 0 Inf -> 0 +dqdvi593 divideint 1 Inf -> 0 +dqdvi594 divideint 1000 Inf -> 0 +dqdvi595 divideint Inf Inf -> NaN Invalid_operation + +dqdvi600 divideint -Inf -Inf -> NaN Invalid_operation +dqdvi601 divideint -Inf -1000 -> Infinity +dqdvi602 divideint -Inf -1 -> Infinity +dqdvi603 divideint -Inf -0 -> Infinity +dqdvi604 divideint -Inf 0 -> -Infinity +dqdvi605 divideint -Inf 1 -> -Infinity +dqdvi606 divideint -Inf 1000 -> -Infinity +dqdvi607 divideint -Inf Inf -> NaN Invalid_operation +dqdvi608 divideint -1000 Inf -> -0 +dqdvi609 divideint -Inf -Inf -> NaN Invalid_operation +dqdvi610 divideint -1 -Inf -> 0 +dqdvi611 divideint -0 -Inf -> 0 +dqdvi612 divideint 0 -Inf -> -0 +dqdvi613 divideint 1 -Inf -> -0 +dqdvi614 divideint 1000 -Inf -> -0 +dqdvi615 divideint Inf -Inf -> NaN Invalid_operation + +dqdvi621 divideint NaN -Inf -> NaN +dqdvi622 divideint NaN -1000 -> NaN +dqdvi623 divideint NaN -1 -> NaN +dqdvi624 divideint NaN -0 -> NaN +dqdvi625 divideint NaN 0 -> NaN +dqdvi626 divideint NaN 1 -> NaN +dqdvi627 divideint NaN 1000 -> NaN +dqdvi628 divideint NaN Inf -> NaN +dqdvi629 divideint NaN NaN -> NaN +dqdvi630 divideint -Inf NaN -> NaN +dqdvi631 divideint -1000 NaN -> NaN +dqdvi632 divideint -1 NaN -> NaN +dqdvi633 divideint -0 NaN -> NaN +dqdvi634 divideint 0 NaN -> NaN +dqdvi635 divideint 1 NaN -> NaN +dqdvi636 divideint 1000 NaN -> NaN +dqdvi637 divideint Inf NaN -> NaN + +dqdvi641 divideint sNaN -Inf -> NaN Invalid_operation +dqdvi642 divideint sNaN -1000 -> NaN Invalid_operation +dqdvi643 divideint sNaN -1 -> NaN Invalid_operation +dqdvi644 divideint sNaN -0 -> NaN Invalid_operation +dqdvi645 divideint sNaN 0 -> NaN Invalid_operation +dqdvi646 divideint sNaN 1 -> NaN Invalid_operation +dqdvi647 divideint sNaN 1000 -> NaN Invalid_operation +dqdvi648 divideint sNaN NaN -> NaN Invalid_operation +dqdvi649 divideint sNaN sNaN -> NaN Invalid_operation +dqdvi650 divideint NaN sNaN -> NaN Invalid_operation +dqdvi651 divideint -Inf sNaN -> NaN Invalid_operation +dqdvi652 divideint -1000 sNaN -> NaN Invalid_operation +dqdvi653 divideint -1 sNaN -> NaN Invalid_operation +dqdvi654 divideint -0 sNaN -> NaN Invalid_operation +dqdvi655 divideint 0 sNaN -> NaN Invalid_operation +dqdvi656 divideint 1 sNaN -> NaN Invalid_operation +dqdvi657 divideint 1000 sNaN -> NaN Invalid_operation +dqdvi658 divideint Inf sNaN -> NaN Invalid_operation +dqdvi659 divideint NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +dqdvi661 divideint NaN9 -Inf -> NaN9 +dqdvi662 divideint NaN8 1000 -> NaN8 +dqdvi663 divideint NaN7 Inf -> NaN7 +dqdvi664 divideint -NaN6 NaN5 -> -NaN6 +dqdvi665 divideint -Inf NaN4 -> NaN4 +dqdvi666 divideint -1000 NaN3 -> NaN3 +dqdvi667 divideint Inf -NaN2 -> -NaN2 + +dqdvi671 divideint -sNaN99 -Inf -> -NaN99 Invalid_operation +dqdvi672 divideint sNaN98 -1 -> NaN98 Invalid_operation +dqdvi673 divideint sNaN97 NaN -> NaN97 Invalid_operation +dqdvi674 divideint sNaN96 sNaN94 -> NaN96 Invalid_operation +dqdvi675 divideint NaN95 sNaN93 -> NaN93 Invalid_operation +dqdvi676 divideint -Inf sNaN92 -> NaN92 Invalid_operation +dqdvi677 divideint 0 sNaN91 -> NaN91 Invalid_operation +dqdvi678 divideint Inf -sNaN90 -> -NaN90 Invalid_operation +dqdvi679 divideint NaN sNaN89 -> NaN89 Invalid_operation + +-- Gyuris example +dqdvi700 divideint 8.336804418094040989630006819881709E-6143 8.336804418094040989630006819889000E-6143 -> 0 + +-- Null tests +dqdvi900 divideint 10 # -> NaN Invalid_operation +dqdvi901 divideint # 10 -> NaN Invalid_operation Added: python/branches/release25-maint/Lib/test/decimaltestdata/dqEncode.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/dqEncode.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,477 @@ +------------------------------------------------------------------------ +-- dqEncode.decTest -- decimal sixteen-byte format testcases -- +-- Copyright (c) IBM Corporation, 2000, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +-- [Previously called decimal128.decTest] +version: 2.57 + +-- This set of tests is for the sixteen-byte concrete representation. +-- Its characteristics are: +-- +-- 1 bit sign +-- 5 bits combination field +-- 12 bits exponent continuation +-- 110 bits coefficient continuation +-- +-- Total exponent length 14 bits +-- Total coefficient length 114 bits (34 digits) +-- +-- Elimit = 12287 (maximum encoded exponent) +-- Emax = 6144 (largest exponent value) +-- Emin = -6143 (smallest exponent value) +-- bias = 6176 (subtracted from encoded exponent) = -Etiny + +-- The testcases here have only exactly representable data on the +-- 'left-hand-side'; rounding from strings is tested in 'base' +-- testcase groups. + +extended: 1 +clamp: 1 +precision: 34 +rounding: half_up +maxExponent: 6144 +minExponent: -6143 + +-- General testcases +-- (mostly derived from the Strawman 4 document and examples) +decq001 apply #A20780000000000000000000000003D0 -> -7.50 +decq002 apply -7.50 -> #A20780000000000000000000000003D0 +-- derivative canonical plain strings +decq003 apply #A20840000000000000000000000003D0 -> -7.50E+3 +decq004 apply -7.50E+3 -> #A20840000000000000000000000003D0 +decq005 apply #A20800000000000000000000000003D0 -> -750 +decq006 apply -750 -> #A20800000000000000000000000003D0 +decq007 apply #A207c0000000000000000000000003D0 -> -75.0 +decq008 apply -75.0 -> #A207c0000000000000000000000003D0 +decq009 apply #A20740000000000000000000000003D0 -> -0.750 +decq010 apply -0.750 -> #A20740000000000000000000000003D0 +decq011 apply #A20700000000000000000000000003D0 -> -0.0750 +decq012 apply -0.0750 -> #A20700000000000000000000000003D0 +decq013 apply #A20680000000000000000000000003D0 -> -0.000750 +decq014 apply -0.000750 -> #A20680000000000000000000000003D0 +decq015 apply #A20600000000000000000000000003D0 -> -0.00000750 +decq016 apply -0.00000750 -> #A20600000000000000000000000003D0 +decq017 apply #A205c0000000000000000000000003D0 -> -7.50E-7 +decq018 apply -7.50E-7 -> #A205c0000000000000000000000003D0 + +-- Normality +decq020 apply 1234567890123456789012345678901234 -> #2608134b9c1e28e56f3c127177823534 +decq021 apply -1234567890123456789012345678901234 -> #a608134b9c1e28e56f3c127177823534 +decq022 apply 1111111111111111111111111111111111 -> #26080912449124491244912449124491 + +-- Nmax and similar +decq031 apply 9.999999999999999999999999999999999E+6144 -> #77ffcff3fcff3fcff3fcff3fcff3fcff +decq032 apply #77ffcff3fcff3fcff3fcff3fcff3fcff -> 9.999999999999999999999999999999999E+6144 +decq033 apply 1.234567890123456789012345678901234E+6144 -> #47ffd34b9c1e28e56f3c127177823534 +decq034 apply #47ffd34b9c1e28e56f3c127177823534 -> 1.234567890123456789012345678901234E+6144 +-- fold-downs (more below) +decq035 apply 1.23E+6144 -> #47ffd300000000000000000000000000 Clamped +decq036 apply #47ffd300000000000000000000000000 -> 1.230000000000000000000000000000000E+6144 +decq037 apply 1E+6144 -> #47ffc000000000000000000000000000 Clamped +decq038 apply #47ffc000000000000000000000000000 -> 1.000000000000000000000000000000000E+6144 + +decq051 apply 12345 -> #220800000000000000000000000049c5 +decq052 apply #220800000000000000000000000049c5 -> 12345 +decq053 apply 1234 -> #22080000000000000000000000000534 +decq054 apply #22080000000000000000000000000534 -> 1234 +decq055 apply 123 -> #220800000000000000000000000000a3 +decq056 apply #220800000000000000000000000000a3 -> 123 +decq057 apply 12 -> #22080000000000000000000000000012 +decq058 apply #22080000000000000000000000000012 -> 12 +decq059 apply 1 -> #22080000000000000000000000000001 +decq060 apply #22080000000000000000000000000001 -> 1 +decq061 apply 1.23 -> #220780000000000000000000000000a3 +decq062 apply #220780000000000000000000000000a3 -> 1.23 +decq063 apply 123.45 -> #220780000000000000000000000049c5 +decq064 apply #220780000000000000000000000049c5 -> 123.45 + +-- Nmin and below +decq071 apply 1E-6143 -> #00084000000000000000000000000001 +decq072 apply #00084000000000000000000000000001 -> 1E-6143 +decq073 apply 1.000000000000000000000000000000000E-6143 -> #04000000000000000000000000000000 +decq074 apply #04000000000000000000000000000000 -> 1.000000000000000000000000000000000E-6143 +decq075 apply 1.000000000000000000000000000000001E-6143 -> #04000000000000000000000000000001 +decq076 apply #04000000000000000000000000000001 -> 1.000000000000000000000000000000001E-6143 + +decq077 apply 0.100000000000000000000000000000000E-6143 -> #00000800000000000000000000000000 Subnormal +decq078 apply #00000800000000000000000000000000 -> 1.00000000000000000000000000000000E-6144 Subnormal +decq079 apply 0.000000000000000000000000000000010E-6143 -> #00000000000000000000000000000010 Subnormal +decq080 apply #00000000000000000000000000000010 -> 1.0E-6175 Subnormal +decq081 apply 0.00000000000000000000000000000001E-6143 -> #00004000000000000000000000000001 Subnormal +decq082 apply #00004000000000000000000000000001 -> 1E-6175 Subnormal +decq083 apply 0.000000000000000000000000000000001E-6143 -> #00000000000000000000000000000001 Subnormal +decq084 apply #00000000000000000000000000000001 -> 1E-6176 Subnormal + +-- underflows cannot be tested for simple copies, check edge cases +decq090 apply 1e-6176 -> #00000000000000000000000000000001 Subnormal +decq100 apply 999999999999999999999999999999999e-6176 -> #00000ff3fcff3fcff3fcff3fcff3fcff Subnormal + +-- same again, negatives +-- Nmax and similar +decq122 apply -9.999999999999999999999999999999999E+6144 -> #f7ffcff3fcff3fcff3fcff3fcff3fcff +decq123 apply #f7ffcff3fcff3fcff3fcff3fcff3fcff -> -9.999999999999999999999999999999999E+6144 +decq124 apply -1.234567890123456789012345678901234E+6144 -> #c7ffd34b9c1e28e56f3c127177823534 +decq125 apply #c7ffd34b9c1e28e56f3c127177823534 -> -1.234567890123456789012345678901234E+6144 +-- fold-downs (more below) +decq130 apply -1.23E+6144 -> #c7ffd300000000000000000000000000 Clamped +decq131 apply #c7ffd300000000000000000000000000 -> -1.230000000000000000000000000000000E+6144 +decq132 apply -1E+6144 -> #c7ffc000000000000000000000000000 Clamped +decq133 apply #c7ffc000000000000000000000000000 -> -1.000000000000000000000000000000000E+6144 + +decq151 apply -12345 -> #a20800000000000000000000000049c5 +decq152 apply #a20800000000000000000000000049c5 -> -12345 +decq153 apply -1234 -> #a2080000000000000000000000000534 +decq154 apply #a2080000000000000000000000000534 -> -1234 +decq155 apply -123 -> #a20800000000000000000000000000a3 +decq156 apply #a20800000000000000000000000000a3 -> -123 +decq157 apply -12 -> #a2080000000000000000000000000012 +decq158 apply #a2080000000000000000000000000012 -> -12 +decq159 apply -1 -> #a2080000000000000000000000000001 +decq160 apply #a2080000000000000000000000000001 -> -1 +decq161 apply -1.23 -> #a20780000000000000000000000000a3 +decq162 apply #a20780000000000000000000000000a3 -> -1.23 +decq163 apply -123.45 -> #a20780000000000000000000000049c5 +decq164 apply #a20780000000000000000000000049c5 -> -123.45 + +-- Nmin and below +decq171 apply -1E-6143 -> #80084000000000000000000000000001 +decq172 apply #80084000000000000000000000000001 -> -1E-6143 +decq173 apply -1.000000000000000000000000000000000E-6143 -> #84000000000000000000000000000000 +decq174 apply #84000000000000000000000000000000 -> -1.000000000000000000000000000000000E-6143 +decq175 apply -1.000000000000000000000000000000001E-6143 -> #84000000000000000000000000000001 +decq176 apply #84000000000000000000000000000001 -> -1.000000000000000000000000000000001E-6143 + +decq177 apply -0.100000000000000000000000000000000E-6143 -> #80000800000000000000000000000000 Subnormal +decq178 apply #80000800000000000000000000000000 -> -1.00000000000000000000000000000000E-6144 Subnormal +decq179 apply -0.000000000000000000000000000000010E-6143 -> #80000000000000000000000000000010 Subnormal +decq180 apply #80000000000000000000000000000010 -> -1.0E-6175 Subnormal +decq181 apply -0.00000000000000000000000000000001E-6143 -> #80004000000000000000000000000001 Subnormal +decq182 apply #80004000000000000000000000000001 -> -1E-6175 Subnormal +decq183 apply -0.000000000000000000000000000000001E-6143 -> #80000000000000000000000000000001 Subnormal +decq184 apply #80000000000000000000000000000001 -> -1E-6176 Subnormal + +-- underflow edge cases +decq190 apply -1e-6176 -> #80000000000000000000000000000001 Subnormal +decq200 apply -999999999999999999999999999999999e-6176 -> #80000ff3fcff3fcff3fcff3fcff3fcff Subnormal + +-- zeros +decq400 apply 0E-8000 -> #00000000000000000000000000000000 Clamped +decq401 apply 0E-6177 -> #00000000000000000000000000000000 Clamped +decq402 apply 0E-6176 -> #00000000000000000000000000000000 +decq403 apply #00000000000000000000000000000000 -> 0E-6176 +decq404 apply 0.000000000000000000000000000000000E-6143 -> #00000000000000000000000000000000 +decq405 apply #00000000000000000000000000000000 -> 0E-6176 +decq406 apply 0E-2 -> #22078000000000000000000000000000 +decq407 apply #22078000000000000000000000000000 -> 0.00 +decq408 apply 0 -> #22080000000000000000000000000000 +decq409 apply #22080000000000000000000000000000 -> 0 +decq410 apply 0E+3 -> #2208c000000000000000000000000000 +decq411 apply #2208c000000000000000000000000000 -> 0E+3 +decq412 apply 0E+6111 -> #43ffc000000000000000000000000000 +decq413 apply #43ffc000000000000000000000000000 -> 0E+6111 +-- clamped zeros... +decq414 apply 0E+6112 -> #43ffc000000000000000000000000000 Clamped +decq415 apply #43ffc000000000000000000000000000 -> 0E+6111 +decq416 apply 0E+6144 -> #43ffc000000000000000000000000000 Clamped +decq417 apply #43ffc000000000000000000000000000 -> 0E+6111 +decq418 apply 0E+8000 -> #43ffc000000000000000000000000000 Clamped +decq419 apply #43ffc000000000000000000000000000 -> 0E+6111 + +-- negative zeros +decq420 apply -0E-8000 -> #80000000000000000000000000000000 Clamped +decq421 apply -0E-6177 -> #80000000000000000000000000000000 Clamped +decq422 apply -0E-6176 -> #80000000000000000000000000000000 +decq423 apply #80000000000000000000000000000000 -> -0E-6176 +decq424 apply -0.000000000000000000000000000000000E-6143 -> #80000000000000000000000000000000 +decq425 apply #80000000000000000000000000000000 -> -0E-6176 +decq426 apply -0E-2 -> #a2078000000000000000000000000000 +decq427 apply #a2078000000000000000000000000000 -> -0.00 +decq428 apply -0 -> #a2080000000000000000000000000000 +decq429 apply #a2080000000000000000000000000000 -> -0 +decq430 apply -0E+3 -> #a208c000000000000000000000000000 +decq431 apply #a208c000000000000000000000000000 -> -0E+3 +decq432 apply -0E+6111 -> #c3ffc000000000000000000000000000 +decq433 apply #c3ffc000000000000000000000000000 -> -0E+6111 +-- clamped zeros... +decq434 apply -0E+6112 -> #c3ffc000000000000000000000000000 Clamped +decq435 apply #c3ffc000000000000000000000000000 -> -0E+6111 +decq436 apply -0E+6144 -> #c3ffc000000000000000000000000000 Clamped +decq437 apply #c3ffc000000000000000000000000000 -> -0E+6111 +decq438 apply -0E+8000 -> #c3ffc000000000000000000000000000 Clamped +decq439 apply #c3ffc000000000000000000000000000 -> -0E+6111 + +-- exponent lengths +decq440 apply #22080000000000000000000000000007 -> 7 +decq441 apply 7 -> #22080000000000000000000000000007 +decq442 apply #220a4000000000000000000000000007 -> 7E+9 +decq443 apply 7E+9 -> #220a4000000000000000000000000007 +decq444 apply #2220c000000000000000000000000007 -> 7E+99 +decq445 apply 7E+99 -> #2220c000000000000000000000000007 +decq446 apply #2301c000000000000000000000000007 -> 7E+999 +decq447 apply 7E+999 -> #2301c000000000000000000000000007 +decq448 apply #43e3c000000000000000000000000007 -> 7E+5999 +decq449 apply 7E+5999 -> #43e3c000000000000000000000000007 + +-- Specials +decq500 apply Infinity -> #78000000000000000000000000000000 +decq501 apply #78787878787878787878787878787878 -> #78000000000000000000000000000000 +decq502 apply #78000000000000000000000000000000 -> Infinity +decq503 apply #79797979797979797979797979797979 -> #78000000000000000000000000000000 +decq504 apply #79000000000000000000000000000000 -> Infinity +decq505 apply #7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a -> #78000000000000000000000000000000 +decq506 apply #7a000000000000000000000000000000 -> Infinity +decq507 apply #7b7b7b7b7b7b7b7b7b7b7b7b7b7b7b7b -> #78000000000000000000000000000000 +decq508 apply #7b000000000000000000000000000000 -> Infinity + +decq509 apply NaN -> #7c000000000000000000000000000000 +decq510 apply #7c7c7c7c7c7c7c7c7c7c7c7c7c7c7c7c -> #7c003c7c7c7c7c7c7c7c7c7c7c7c7c7c +decq511 apply #7c000000000000000000000000000000 -> NaN +decq512 apply #7d7d7d7d7d7d7d7d7d7d7d7d7d7d7d7d -> #7c003d7d7d7d7d7d7d7d7d7d7d7d7d7d +decq513 apply #7d000000000000000000000000000000 -> NaN +decq514 apply #7e7e7e7e7e7e7e7e7e7e7e7e7e7e7e7e -> #7e003e7e7c7e7e7e7e7c7e7e7e7e7c7e +decq515 apply #7e000000000000000000000000000000 -> sNaN +decq516 apply #7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f -> #7e003f7f7c7f7f7f7f7c7f7f7f7f7c7f +decq517 apply #7f000000000000000000000000000000 -> sNaN +decq518 apply #7fffffffffffffffffffffffffffffff -> sNaN999999999999999999999999999999999 +decq519 apply #7fffffffffffffffffffffffffffffff -> #7e000ff3fcff3fcff3fcff3fcff3fcff + +decq520 apply -Infinity -> #f8000000000000000000000000000000 +decq521 apply #f8787878787878787878787878787878 -> #f8000000000000000000000000000000 +decq522 apply #f8000000000000000000000000000000 -> -Infinity +decq523 apply #f9797979797979797979797979797979 -> #f8000000000000000000000000000000 +decq524 apply #f9000000000000000000000000000000 -> -Infinity +decq525 apply #fa7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a -> #f8000000000000000000000000000000 +decq526 apply #fa000000000000000000000000000000 -> -Infinity +decq527 apply #fb7b7b7b7b7b7b7b7b7b7b7b7b7b7b7b -> #f8000000000000000000000000000000 +decq528 apply #fb000000000000000000000000000000 -> -Infinity + +decq529 apply -NaN -> #fc000000000000000000000000000000 +decq530 apply #fc7c7c7c7c7c7c7c7c7c7c7c7c7c7c7c -> #fc003c7c7c7c7c7c7c7c7c7c7c7c7c7c +decq531 apply #fc000000000000000000000000000000 -> -NaN +decq532 apply #fd7d7d7d7d7d7d7d7d7d7d7d7d7d7d7d -> #fc003d7d7d7d7d7d7d7d7d7d7d7d7d7d +decq533 apply #fd000000000000000000000000000000 -> -NaN +decq534 apply #fe7e7e7e7e7e7e7e7e7e7e7e7e7e7e7e -> #fe003e7e7c7e7e7e7e7c7e7e7e7e7c7e +decq535 apply #fe000000000000000000000000000000 -> -sNaN +decq536 apply #ff7f7f7f7f7f7f7f7f7f7f7f7f7f7f7f -> #fe003f7f7c7f7f7f7f7c7f7f7f7f7c7f +decq537 apply #ff000000000000000000000000000000 -> -sNaN +decq538 apply #ffffffffffffffffffffffffffffffff -> -sNaN999999999999999999999999999999999 +decq539 apply #ffffffffffffffffffffffffffffffff -> #fe000ff3fcff3fcff3fcff3fcff3fcff + +decq540 apply NaN -> #7c000000000000000000000000000000 +decq541 apply NaN0 -> #7c000000000000000000000000000000 +decq542 apply NaN1 -> #7c000000000000000000000000000001 +decq543 apply NaN12 -> #7c000000000000000000000000000012 +decq544 apply NaN79 -> #7c000000000000000000000000000079 +decq545 apply NaN12345 -> #7c0000000000000000000000000049c5 +decq546 apply NaN123456 -> #7c000000000000000000000000028e56 +decq547 apply NaN799799 -> #7c0000000000000000000000000f7fdf +decq548 apply NaN799799799799799799799799799799799 -> #7c003dff7fdff7fdff7fdff7fdff7fdf +decq549 apply NaN999999999999999999999999999999999 -> #7c000ff3fcff3fcff3fcff3fcff3fcff +decq550 apply 9999999999999999999999999999999999 -> #6e080ff3fcff3fcff3fcff3fcff3fcff + +-- fold-down full sequence +decq601 apply 1E+6144 -> #47ffc000000000000000000000000000 Clamped +decq602 apply #47ffc000000000000000000000000000 -> 1.000000000000000000000000000000000E+6144 +decq603 apply 1E+6143 -> #43ffc800000000000000000000000000 Clamped +decq604 apply #43ffc800000000000000000000000000 -> 1.00000000000000000000000000000000E+6143 +decq605 apply 1E+6142 -> #43ffc100000000000000000000000000 Clamped +decq606 apply #43ffc100000000000000000000000000 -> 1.0000000000000000000000000000000E+6142 +decq607 apply 1E+6141 -> #43ffc010000000000000000000000000 Clamped +decq608 apply #43ffc010000000000000000000000000 -> 1.000000000000000000000000000000E+6141 +decq609 apply 1E+6140 -> #43ffc002000000000000000000000000 Clamped +decq610 apply #43ffc002000000000000000000000000 -> 1.00000000000000000000000000000E+6140 +decq611 apply 1E+6139 -> #43ffc000400000000000000000000000 Clamped +decq612 apply #43ffc000400000000000000000000000 -> 1.0000000000000000000000000000E+6139 +decq613 apply 1E+6138 -> #43ffc000040000000000000000000000 Clamped +decq614 apply #43ffc000040000000000000000000000 -> 1.000000000000000000000000000E+6138 +decq615 apply 1E+6137 -> #43ffc000008000000000000000000000 Clamped +decq616 apply #43ffc000008000000000000000000000 -> 1.00000000000000000000000000E+6137 +decq617 apply 1E+6136 -> #43ffc000001000000000000000000000 Clamped +decq618 apply #43ffc000001000000000000000000000 -> 1.0000000000000000000000000E+6136 +decq619 apply 1E+6135 -> #43ffc000000100000000000000000000 Clamped +decq620 apply #43ffc000000100000000000000000000 -> 1.000000000000000000000000E+6135 +decq621 apply 1E+6134 -> #43ffc000000020000000000000000000 Clamped +decq622 apply #43ffc000000020000000000000000000 -> 1.00000000000000000000000E+6134 +decq623 apply 1E+6133 -> #43ffc000000004000000000000000000 Clamped +decq624 apply #43ffc000000004000000000000000000 -> 1.0000000000000000000000E+6133 +decq625 apply 1E+6132 -> #43ffc000000000400000000000000000 Clamped +decq626 apply #43ffc000000000400000000000000000 -> 1.000000000000000000000E+6132 +decq627 apply 1E+6131 -> #43ffc000000000080000000000000000 Clamped +decq628 apply #43ffc000000000080000000000000000 -> 1.00000000000000000000E+6131 +decq629 apply 1E+6130 -> #43ffc000000000010000000000000000 Clamped +decq630 apply #43ffc000000000010000000000000000 -> 1.0000000000000000000E+6130 +decq631 apply 1E+6129 -> #43ffc000000000001000000000000000 Clamped +decq632 apply #43ffc000000000001000000000000000 -> 1.000000000000000000E+6129 +decq633 apply 1E+6128 -> #43ffc000000000000200000000000000 Clamped +decq634 apply #43ffc000000000000200000000000000 -> 1.00000000000000000E+6128 +decq635 apply 1E+6127 -> #43ffc000000000000040000000000000 Clamped +decq636 apply #43ffc000000000000040000000000000 -> 1.0000000000000000E+6127 +decq637 apply 1E+6126 -> #43ffc000000000000004000000000000 Clamped +decq638 apply #43ffc000000000000004000000000000 -> 1.000000000000000E+6126 +decq639 apply 1E+6125 -> #43ffc000000000000000800000000000 Clamped +decq640 apply #43ffc000000000000000800000000000 -> 1.00000000000000E+6125 +decq641 apply 1E+6124 -> #43ffc000000000000000100000000000 Clamped +decq642 apply #43ffc000000000000000100000000000 -> 1.0000000000000E+6124 +decq643 apply 1E+6123 -> #43ffc000000000000000010000000000 Clamped +decq644 apply #43ffc000000000000000010000000000 -> 1.000000000000E+6123 +decq645 apply 1E+6122 -> #43ffc000000000000000002000000000 Clamped +decq646 apply #43ffc000000000000000002000000000 -> 1.00000000000E+6122 +decq647 apply 1E+6121 -> #43ffc000000000000000000400000000 Clamped +decq648 apply #43ffc000000000000000000400000000 -> 1.0000000000E+6121 +decq649 apply 1E+6120 -> #43ffc000000000000000000040000000 Clamped +decq650 apply #43ffc000000000000000000040000000 -> 1.000000000E+6120 +decq651 apply 1E+6119 -> #43ffc000000000000000000008000000 Clamped +decq652 apply #43ffc000000000000000000008000000 -> 1.00000000E+6119 +decq653 apply 1E+6118 -> #43ffc000000000000000000001000000 Clamped +decq654 apply #43ffc000000000000000000001000000 -> 1.0000000E+6118 +decq655 apply 1E+6117 -> #43ffc000000000000000000000100000 Clamped +decq656 apply #43ffc000000000000000000000100000 -> 1.000000E+6117 +decq657 apply 1E+6116 -> #43ffc000000000000000000000020000 Clamped +decq658 apply #43ffc000000000000000000000020000 -> 1.00000E+6116 +decq659 apply 1E+6115 -> #43ffc000000000000000000000004000 Clamped +decq660 apply #43ffc000000000000000000000004000 -> 1.0000E+6115 +decq661 apply 1E+6114 -> #43ffc000000000000000000000000400 Clamped +decq662 apply #43ffc000000000000000000000000400 -> 1.000E+6114 +decq663 apply 1E+6113 -> #43ffc000000000000000000000000080 Clamped +decq664 apply #43ffc000000000000000000000000080 -> 1.00E+6113 +decq665 apply 1E+6112 -> #43ffc000000000000000000000000010 Clamped +decq666 apply #43ffc000000000000000000000000010 -> 1.0E+6112 +decq667 apply 1E+6111 -> #43ffc000000000000000000000000001 +decq668 apply #43ffc000000000000000000000000001 -> 1E+6111 +decq669 apply 1E+6110 -> #43ff8000000000000000000000000001 +decq670 apply #43ff8000000000000000000000000001 -> 1E+6110 + +-- Selected DPD codes +decq700 apply #22080000000000000000000000000000 -> 0 +decq701 apply #22080000000000000000000000000009 -> 9 +decq702 apply #22080000000000000000000000000010 -> 10 +decq703 apply #22080000000000000000000000000019 -> 19 +decq704 apply #22080000000000000000000000000020 -> 20 +decq705 apply #22080000000000000000000000000029 -> 29 +decq706 apply #22080000000000000000000000000030 -> 30 +decq707 apply #22080000000000000000000000000039 -> 39 +decq708 apply #22080000000000000000000000000040 -> 40 +decq709 apply #22080000000000000000000000000049 -> 49 +decq710 apply #22080000000000000000000000000050 -> 50 +decq711 apply #22080000000000000000000000000059 -> 59 +decq712 apply #22080000000000000000000000000060 -> 60 +decq713 apply #22080000000000000000000000000069 -> 69 +decq714 apply #22080000000000000000000000000070 -> 70 +decq715 apply #22080000000000000000000000000071 -> 71 +decq716 apply #22080000000000000000000000000072 -> 72 +decq717 apply #22080000000000000000000000000073 -> 73 +decq718 apply #22080000000000000000000000000074 -> 74 +decq719 apply #22080000000000000000000000000075 -> 75 +decq720 apply #22080000000000000000000000000076 -> 76 +decq721 apply #22080000000000000000000000000077 -> 77 +decq722 apply #22080000000000000000000000000078 -> 78 +decq723 apply #22080000000000000000000000000079 -> 79 + +decq730 apply #2208000000000000000000000000029e -> 994 +decq731 apply #2208000000000000000000000000029f -> 995 +decq732 apply #220800000000000000000000000002a0 -> 520 +decq733 apply #220800000000000000000000000002a1 -> 521 + +-- DPD: one of each of the huffman groups +decq740 apply #220800000000000000000000000003f7 -> 777 +decq741 apply #220800000000000000000000000003f8 -> 778 +decq742 apply #220800000000000000000000000003eb -> 787 +decq743 apply #2208000000000000000000000000037d -> 877 +decq744 apply #2208000000000000000000000000039f -> 997 +decq745 apply #220800000000000000000000000003bf -> 979 +decq746 apply #220800000000000000000000000003df -> 799 +decq747 apply #2208000000000000000000000000006e -> 888 + + +-- DPD all-highs cases (includes the 24 redundant codes) +decq750 apply #2208000000000000000000000000006e -> 888 +decq751 apply #2208000000000000000000000000016e -> 888 +decq752 apply #2208000000000000000000000000026e -> 888 +decq753 apply #2208000000000000000000000000036e -> 888 +decq754 apply #2208000000000000000000000000006f -> 889 +decq755 apply #2208000000000000000000000000016f -> 889 +decq756 apply #2208000000000000000000000000026f -> 889 +decq757 apply #2208000000000000000000000000036f -> 889 + +decq760 apply #2208000000000000000000000000007e -> 898 +decq761 apply #2208000000000000000000000000017e -> 898 +decq762 apply #2208000000000000000000000000027e -> 898 +decq763 apply #2208000000000000000000000000037e -> 898 +decq764 apply #2208000000000000000000000000007f -> 899 +decq765 apply #2208000000000000000000000000017f -> 899 +decq766 apply #2208000000000000000000000000027f -> 899 +decq767 apply #2208000000000000000000000000037f -> 899 + +decq770 apply #220800000000000000000000000000ee -> 988 +decq771 apply #220800000000000000000000000001ee -> 988 +decq772 apply #220800000000000000000000000002ee -> 988 +decq773 apply #220800000000000000000000000003ee -> 988 +decq774 apply #220800000000000000000000000000ef -> 989 +decq775 apply #220800000000000000000000000001ef -> 989 +decq776 apply #220800000000000000000000000002ef -> 989 +decq777 apply #220800000000000000000000000003ef -> 989 + +decq780 apply #220800000000000000000000000000fe -> 998 +decq781 apply #220800000000000000000000000001fe -> 998 +decq782 apply #220800000000000000000000000002fe -> 998 +decq783 apply #220800000000000000000000000003fe -> 998 +decq784 apply #220800000000000000000000000000ff -> 999 +decq785 apply #220800000000000000000000000001ff -> 999 +decq786 apply #220800000000000000000000000002ff -> 999 +decq787 apply #220800000000000000000000000003ff -> 999 + +-- Miscellaneous (testers' queries, etc.) + +decq790 apply #2208000000000000000000000000c000 -> 30000 +decq791 apply #22080000000000000000000000007800 -> 890000 +decq792 apply 30000 -> #2208000000000000000000000000c000 +decq793 apply 890000 -> #22080000000000000000000000007800 + +-- values around [u]int32 edges (zeros done earlier) +decq800 apply -2147483646 -> #a208000000000000000000008c78af46 +decq801 apply -2147483647 -> #a208000000000000000000008c78af47 +decq802 apply -2147483648 -> #a208000000000000000000008c78af48 +decq803 apply -2147483649 -> #a208000000000000000000008c78af49 +decq804 apply 2147483646 -> #2208000000000000000000008c78af46 +decq805 apply 2147483647 -> #2208000000000000000000008c78af47 +decq806 apply 2147483648 -> #2208000000000000000000008c78af48 +decq807 apply 2147483649 -> #2208000000000000000000008c78af49 +decq808 apply 4294967294 -> #22080000000000000000000115afb55a +decq809 apply 4294967295 -> #22080000000000000000000115afb55b +decq810 apply 4294967296 -> #22080000000000000000000115afb57a +decq811 apply 4294967297 -> #22080000000000000000000115afb57b + +decq820 apply #a208000000000000000000008c78af46 -> -2147483646 +decq821 apply #a208000000000000000000008c78af47 -> -2147483647 +decq822 apply #a208000000000000000000008c78af48 -> -2147483648 +decq823 apply #a208000000000000000000008c78af49 -> -2147483649 +decq824 apply #2208000000000000000000008c78af46 -> 2147483646 +decq825 apply #2208000000000000000000008c78af47 -> 2147483647 +decq826 apply #2208000000000000000000008c78af48 -> 2147483648 +decq827 apply #2208000000000000000000008c78af49 -> 2147483649 +decq828 apply #22080000000000000000000115afb55a -> 4294967294 +decq829 apply #22080000000000000000000115afb55b -> 4294967295 +decq830 apply #22080000000000000000000115afb57a -> 4294967296 +decq831 apply #22080000000000000000000115afb57b -> 4294967297 + +-- VG testcase +decq840 apply #2080000000000000F294000000172636 -> 8.81125000000001349436E-1548 +decq841 apply #20800000000000008000000000000000 -> 8.000000000000000000E-1550 +decq842 apply #1EF98490000000010F6E4E0000000000 -> 7.049000000000010795488000000000000E-3097 +decq843 multiply #20800000000000008000000000000000 #2080000000000000F294000000172636 -> #1EF98490000000010F6E4E0000000000 Rounded + Added: python/branches/release25-maint/Lib/test/decimaltestdata/dqFMA.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/dqFMA.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,1786 @@ +------------------------------------------------------------------------ +-- dqFMA.decTest -- decQuad Fused Multiply Add -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +extended: 1 +clamp: 1 +precision: 34 +maxExponent: 6144 +minExponent: -6143 +rounding: half_even + +-- These tests comprese three parts: +-- 1. Sanity checks and other three-operand tests (especially those +-- where the fused operation makes a difference) +-- 2. Multiply tests (third operand is neutral zero [0E+emax]) +-- 3. Addition tests (first operand is 1) +-- The multiply and addition tests are extensive because FMA may have +-- its own dedicated multiplication or addition routine(s), and they +-- also inherently check the left-to-right properties. + +-- Sanity checks +dqfma0001 fma 1 1 1 -> 2 +dqfma0002 fma 1 1 2 -> 3 +dqfma0003 fma 2 2 3 -> 7 +dqfma0004 fma 9 9 9 -> 90 +dqfma0005 fma -1 1 1 -> 0 +dqfma0006 fma -1 1 2 -> 1 +dqfma0007 fma -2 2 3 -> -1 +dqfma0008 fma -9 9 9 -> -72 +dqfma0011 fma 1 -1 1 -> 0 +dqfma0012 fma 1 -1 2 -> 1 +dqfma0013 fma 2 -2 3 -> -1 +dqfma0014 fma 9 -9 9 -> -72 +dqfma0015 fma 1 1 -1 -> 0 +dqfma0016 fma 1 1 -2 -> -1 +dqfma0017 fma 2 2 -3 -> 1 +dqfma0018 fma 9 9 -9 -> 72 + +-- non-integer exacts +dqfma0100 fma 25.2 63.6 -438 -> 1164.72 +dqfma0101 fma 0.301 0.380 334 -> 334.114380 +dqfma0102 fma 49.2 -4.8 23.3 -> -212.86 +dqfma0103 fma 4.22 0.079 -94.6 -> -94.26662 +dqfma0104 fma 903 0.797 0.887 -> 720.578 +dqfma0105 fma 6.13 -161 65.9 -> -921.03 +dqfma0106 fma 28.2 727 5.45 -> 20506.85 +dqfma0107 fma 4 605 688 -> 3108 +dqfma0108 fma 93.3 0.19 0.226 -> 17.953 +dqfma0109 fma 0.169 -341 5.61 -> -52.019 +dqfma0110 fma -72.2 30 -51.2 -> -2217.2 +dqfma0111 fma -0.409 13 20.4 -> 15.083 +dqfma0112 fma 317 77.0 19.0 -> 24428.0 +dqfma0113 fma 47 6.58 1.62 -> 310.88 +dqfma0114 fma 1.36 0.984 0.493 -> 1.83124 +dqfma0115 fma 72.7 274 1.56 -> 19921.36 +dqfma0116 fma 335 847 83 -> 283828 +dqfma0117 fma 666 0.247 25.4 -> 189.902 +dqfma0118 fma -3.87 3.06 78.0 -> 66.1578 +dqfma0119 fma 0.742 192 35.6 -> 178.064 +dqfma0120 fma -91.6 5.29 0.153 -> -484.411 + +-- cases where result is different from separate multiply + add; each +-- is preceded by the result of unfused multiply and add +-- [this is about 20% of all similar cases in general] +-- -> 4.500119002100000209469729375698778E+38 +dqfma0202 fma 68537985861355864457.5694 6565875762972086605.85969 35892634447236753.172812 -> 4.500119002100000209469729375698779E+38 Inexact Rounded +-- -> 5.996248469584594346858881620185514E+41 +dqfma0208 fma 89261822344727628571.9 6717595845654131383336.89 5061036497288796076266.11 -> 5.996248469584594346858881620185513E+41 Inexact Rounded +-- -> 1.899242968678256924021594770874070E+34 +dqfma0210 fma 320506237232448685.495971 59257597764017967.984448 3205615239077711589912.85 -> 1.899242968678256924021594770874071E+34 Inexact Rounded +-- -> 7.078596978842809537929699954860309E+37 +dqfma0215 fma 220247843259112263.17995 321392340287987979002.80 47533279819997167655440 -> 7.078596978842809537929699954860308E+37 Inexact Rounded +-- -> 1.224955667581427559754106862350743E+37 +dqfma0226 fma 23880729790368880412.1449 512947333827064719.55407 217117438419590824502.963 -> 1.224955667581427559754106862350744E+37 Inexact Rounded +-- -> -2.530094043253148806272276368579144E+42 +dqfma0229 fma 2539892357016099706.4126 -996142232667504817717435 53682082598315949425.937 -> -2.530094043253148806272276368579143E+42 Inexact Rounded +-- -> 1.713387085759711954319391412788454E+37 +dqfma0233 fma 4546339491341624464.0804 3768717864169205581 83578980278690395184.620 -> 1.713387085759711954319391412788453E+37 Inexact Rounded +-- -> 4.062275663405823716411579117771547E+35 +dqfma0235 fma 409242119433816131.42253 992633815166741501.477249 70179636544416756129546 -> 4.062275663405823716411579117771548E+35 Inexact Rounded +-- -> 6.002604327732568490562249875306823E+47 +dqfma0258 fma 817941336593541742159684 733867339769310729266598 78563844650942419311830.8 -> 6.002604327732568490562249875306822E+47 Inexact Rounded +-- -> -2.027022514381452197510103395283874E+39 +dqfma0264 fma 387617310169161270.737532 -5229442703414956061216.62 57665666816652967150473.5 -> -2.027022514381452197510103395283873E+39 Inexact Rounded +-- -> -7.856525039803554001144089842730361E+37 +dqfma0267 fma -847655845720565274701.210 92685316564117739.83984 22780950041376424429.5686 -> -7.856525039803554001144089842730360E+37 Inexact Rounded +-- -> 1.695515562011520746125607502237559E+38 +dqfma0268 fma 21590290365127685.3675 7853139227576541379426.8 -3275859437236180.761544 -> 1.695515562011520746125607502237558E+38 Inexact Rounded +-- -> -8.448422935783289219748115038014710E+38 +dqfma0269 fma -974320636272862697.971586 867109103641860247440.756 -9775170775902454762.98 -> -8.448422935783289219748115038014709E+38 Inexact Rounded + +-- Cases where multiply would overflow or underflow if separate +dqfma0300 fma 9e+6144 10 0 -> Infinity Overflow Inexact Rounded +dqfma0301 fma 1e+6144 10 0 -> Infinity Overflow Inexact Rounded +dqfma0302 fma 1e+6144 10 -1e+6144 -> 9.000000000000000000000000000000000E+6144 Clamped +dqfma0303 fma 1e+6144 10 -9e+6144 -> 1.000000000000000000000000000000000E+6144 Clamped +-- subnormal etc. +dqfma0305 fma 1e-6176 0.1 0 -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqfma0306 fma 1e-6176 0.1 1 -> 1.000000000000000000000000000000000 Inexact Rounded +dqfma0307 fma 1e-6176 0.1 1e-6176 -> 1E-6176 Underflow Subnormal Inexact Rounded + +-- Infinite combinations +dqfma0800 fma Inf Inf Inf -> Infinity +dqfma0801 fma Inf Inf -Inf -> NaN Invalid_operation +dqfma0802 fma Inf -Inf Inf -> NaN Invalid_operation +dqfma0803 fma Inf -Inf -Inf -> -Infinity +dqfma0804 fma -Inf Inf Inf -> NaN Invalid_operation +dqfma0805 fma -Inf Inf -Inf -> -Infinity +dqfma0806 fma -Inf -Inf Inf -> Infinity +dqfma0807 fma -Inf -Inf -Inf -> NaN Invalid_operation + +-- Triple NaN propagation +dqfma0900 fma NaN2 NaN3 NaN5 -> NaN2 +dqfma0901 fma 0 NaN3 NaN5 -> NaN3 +dqfma0902 fma 0 0 NaN5 -> NaN5 +-- first sNaN wins (consider qNaN from earlier sNaN being +-- overridden by an sNaN in third operand) +dqfma0903 fma sNaN1 sNaN2 sNaN3 -> NaN1 Invalid_operation +dqfma0904 fma 0 sNaN2 sNaN3 -> NaN2 Invalid_operation +dqfma0905 fma 0 0 sNaN3 -> NaN3 Invalid_operation +dqfma0906 fma sNaN1 sNaN2 sNaN3 -> NaN1 Invalid_operation +dqfma0907 fma NaN7 sNaN2 sNaN3 -> NaN2 Invalid_operation +dqfma0908 fma NaN7 NaN5 sNaN3 -> NaN3 Invalid_operation + +-- MULTIPLICATION TESTS ------------------------------------------------ +rounding: half_even + +-- sanity checks +dqfma2000 fma 2 2 0e+6144 -> 4 +dqfma2001 fma 2 3 0e+6144 -> 6 +dqfma2002 fma 5 1 0e+6144 -> 5 +dqfma2003 fma 5 2 0e+6144 -> 10 +dqfma2004 fma 1.20 2 0e+6144 -> 2.40 +dqfma2005 fma 1.20 0 0e+6144 -> 0.00 +dqfma2006 fma 1.20 -2 0e+6144 -> -2.40 +dqfma2007 fma -1.20 2 0e+6144 -> -2.40 +dqfma2008 fma -1.20 0 0e+6144 -> 0.00 +dqfma2009 fma -1.20 -2 0e+6144 -> 2.40 +dqfma2010 fma 5.09 7.1 0e+6144 -> 36.139 +dqfma2011 fma 2.5 4 0e+6144 -> 10.0 +dqfma2012 fma 2.50 4 0e+6144 -> 10.00 +dqfma2013 fma 1.23456789 1.0000000000000000000000000000 0e+6144 -> 1.234567890000000000000000000000000 Rounded +dqfma2015 fma 2.50 4 0e+6144 -> 10.00 +dqfma2016 fma 9.99999999999999999 9.99999999999999999 0e+6144 -> 99.99999999999999980000000000000000 Inexact Rounded +dqfma2017 fma 9.99999999999999999 -9.99999999999999999 0e+6144 -> -99.99999999999999980000000000000000 Inexact Rounded +dqfma2018 fma -9.99999999999999999 9.99999999999999999 0e+6144 -> -99.99999999999999980000000000000000 Inexact Rounded +dqfma2019 fma -9.99999999999999999 -9.99999999999999999 0e+6144 -> 99.99999999999999980000000000000000 Inexact Rounded + +-- zeros, etc. +dqfma2021 fma 0 0 0e+6144 -> 0 +dqfma2022 fma 0 -0 0e+6144 -> 0 +dqfma2023 fma -0 0 0e+6144 -> 0 +dqfma2024 fma -0 -0 0e+6144 -> 0 +dqfma2025 fma -0.0 -0.0 0e+6144 -> 0.00 +dqfma2026 fma -0.0 -0.0 0e+6144 -> 0.00 +dqfma2027 fma -0.0 -0.0 0e+6144 -> 0.00 +dqfma2028 fma -0.0 -0.0 0e+6144 -> 0.00 +dqfma2030 fma 5.00 1E-3 0e+6144 -> 0.00500 +dqfma2031 fma 00.00 0.000 0e+6144 -> 0.00000 +dqfma2032 fma 00.00 0E-3 0e+6144 -> 0.00000 -- rhs is 0 +dqfma2033 fma 0E-3 00.00 0e+6144 -> 0.00000 -- lhs is 0 +dqfma2034 fma -5.00 1E-3 0e+6144 -> -0.00500 +dqfma2035 fma -00.00 0.000 0e+6144 -> 0.00000 +dqfma2036 fma -00.00 0E-3 0e+6144 -> 0.00000 -- rhs is 0 +dqfma2037 fma -0E-3 00.00 0e+6144 -> 0.00000 -- lhs is 0 +dqfma2038 fma 5.00 -1E-3 0e+6144 -> -0.00500 +dqfma2039 fma 00.00 -0.000 0e+6144 -> 0.00000 +dqfma2040 fma 00.00 -0E-3 0e+6144 -> 0.00000 -- rhs is 0 +dqfma2041 fma 0E-3 -00.00 0e+6144 -> 0.00000 -- lhs is 0 +dqfma2042 fma -5.00 -1E-3 0e+6144 -> 0.00500 +dqfma2043 fma -00.00 -0.000 0e+6144 -> 0.00000 +dqfma2044 fma -00.00 -0E-3 0e+6144 -> 0.00000 -- rhs is 0 +dqfma2045 fma -0E-3 -00.00 0e+6144 -> 0.00000 -- lhs is 0 + +-- examples from decarith +dqfma2050 fma 1.20 3 0e+6144 -> 3.60 +dqfma2051 fma 7 3 0e+6144 -> 21 +dqfma2052 fma 0.9 0.8 0e+6144 -> 0.72 +dqfma2053 fma 0.9 -0 0e+6144 -> 0.0 +dqfma2054 fma 654321 654321 0e+6144 -> 428135971041 + +dqfma2060 fma 123.45 1e7 0e+6144 -> 1.2345E+9 +dqfma2061 fma 123.45 1e8 0e+6144 -> 1.2345E+10 +dqfma2062 fma 123.45 1e+9 0e+6144 -> 1.2345E+11 +dqfma2063 fma 123.45 1e10 0e+6144 -> 1.2345E+12 +dqfma2064 fma 123.45 1e11 0e+6144 -> 1.2345E+13 +dqfma2065 fma 123.45 1e12 0e+6144 -> 1.2345E+14 +dqfma2066 fma 123.45 1e13 0e+6144 -> 1.2345E+15 + + +-- test some intermediate lengths +-- 1234567890123456 +dqfma2080 fma 0.1 1230123456456789 0e+6144 -> 123012345645678.9 +dqfma2084 fma 0.1 1230123456456789 0e+6144 -> 123012345645678.9 +dqfma2090 fma 1230123456456789 0.1 0e+6144 -> 123012345645678.9 +dqfma2094 fma 1230123456456789 0.1 0e+6144 -> 123012345645678.9 + +-- test some more edge cases and carries +dqfma2101 fma 9 9 0e+6144 -> 81 +dqfma2102 fma 9 90 0e+6144 -> 810 +dqfma2103 fma 9 900 0e+6144 -> 8100 +dqfma2104 fma 9 9000 0e+6144 -> 81000 +dqfma2105 fma 9 90000 0e+6144 -> 810000 +dqfma2106 fma 9 900000 0e+6144 -> 8100000 +dqfma2107 fma 9 9000000 0e+6144 -> 81000000 +dqfma2108 fma 9 90000000 0e+6144 -> 810000000 +dqfma2109 fma 9 900000000 0e+6144 -> 8100000000 +dqfma2110 fma 9 9000000000 0e+6144 -> 81000000000 +dqfma2111 fma 9 90000000000 0e+6144 -> 810000000000 +dqfma2112 fma 9 900000000000 0e+6144 -> 8100000000000 +dqfma2113 fma 9 9000000000000 0e+6144 -> 81000000000000 +dqfma2114 fma 9 90000000000000 0e+6144 -> 810000000000000 +dqfma2115 fma 9 900000000000000 0e+6144 -> 8100000000000000 +--dqfma2116 fma 9 9000000000000000 0e+6144 -> 81000000000000000 +--dqfma2117 fma 9 90000000000000000 0e+6144 -> 810000000000000000 +--dqfma2118 fma 9 900000000000000000 0e+6144 -> 8100000000000000000 +--dqfma2119 fma 9 9000000000000000000 0e+6144 -> 81000000000000000000 +--dqfma2120 fma 9 90000000000000000000 0e+6144 -> 810000000000000000000 +--dqfma2121 fma 9 900000000000000000000 0e+6144 -> 8100000000000000000000 +--dqfma2122 fma 9 9000000000000000000000 0e+6144 -> 81000000000000000000000 +--dqfma2123 fma 9 90000000000000000000000 0e+6144 -> 810000000000000000000000 +-- test some more edge cases without carries +dqfma2131 fma 3 3 0e+6144 -> 9 +dqfma2132 fma 3 30 0e+6144 -> 90 +dqfma2133 fma 3 300 0e+6144 -> 900 +dqfma2134 fma 3 3000 0e+6144 -> 9000 +dqfma2135 fma 3 30000 0e+6144 -> 90000 +dqfma2136 fma 3 300000 0e+6144 -> 900000 +dqfma2137 fma 3 3000000 0e+6144 -> 9000000 +dqfma2138 fma 3 30000000 0e+6144 -> 90000000 +dqfma2139 fma 3 300000000 0e+6144 -> 900000000 +dqfma2140 fma 3 3000000000 0e+6144 -> 9000000000 +dqfma2141 fma 3 30000000000 0e+6144 -> 90000000000 +dqfma2142 fma 3 300000000000 0e+6144 -> 900000000000 +dqfma2143 fma 3 3000000000000 0e+6144 -> 9000000000000 +dqfma2144 fma 3 30000000000000 0e+6144 -> 90000000000000 +dqfma2145 fma 3 300000000000000 0e+6144 -> 900000000000000 +dqfma2146 fma 3 3000000000000000 0e+6144 -> 9000000000000000 +dqfma2147 fma 3 30000000000000000 0e+6144 -> 90000000000000000 +dqfma2148 fma 3 300000000000000000 0e+6144 -> 900000000000000000 +dqfma2149 fma 3 3000000000000000000 0e+6144 -> 9000000000000000000 +dqfma2150 fma 3 30000000000000000000 0e+6144 -> 90000000000000000000 +dqfma2151 fma 3 300000000000000000000 0e+6144 -> 900000000000000000000 +dqfma2152 fma 3 3000000000000000000000 0e+6144 -> 9000000000000000000000 +dqfma2153 fma 3 30000000000000000000000 0e+6144 -> 90000000000000000000000 + +dqfma2263 fma 30269.587755640502150977251770554 4.8046009735990873395936309640543 0e+6144 -> 145433.2908011933696719165119928296 Inexact Rounded + +-- test some edge cases with exact rounding +dqfma2301 fma 900000000000000000 9 0e+6144 -> 8100000000000000000 +dqfma2302 fma 900000000000000000 90 0e+6144 -> 81000000000000000000 +dqfma2303 fma 900000000000000000 900 0e+6144 -> 810000000000000000000 +dqfma2304 fma 900000000000000000 9000 0e+6144 -> 8100000000000000000000 +dqfma2305 fma 900000000000000000 90000 0e+6144 -> 81000000000000000000000 +dqfma2306 fma 900000000000000000 900000 0e+6144 -> 810000000000000000000000 +dqfma2307 fma 900000000000000000 9000000 0e+6144 -> 8100000000000000000000000 +dqfma2308 fma 900000000000000000 90000000 0e+6144 -> 81000000000000000000000000 +dqfma2309 fma 900000000000000000 900000000 0e+6144 -> 810000000000000000000000000 +dqfma2310 fma 900000000000000000 9000000000 0e+6144 -> 8100000000000000000000000000 +dqfma2311 fma 900000000000000000 90000000000 0e+6144 -> 81000000000000000000000000000 +dqfma2312 fma 900000000000000000 900000000000 0e+6144 -> 810000000000000000000000000000 +dqfma2313 fma 900000000000000000 9000000000000 0e+6144 -> 8100000000000000000000000000000 +dqfma2314 fma 900000000000000000 90000000000000 0e+6144 -> 81000000000000000000000000000000 +dqfma2315 fma 900000000000000000 900000000000000 0e+6144 -> 810000000000000000000000000000000 +dqfma2316 fma 900000000000000000 9000000000000000 0e+6144 -> 8100000000000000000000000000000000 +dqfma2317 fma 9000000000000000000 9000000000000000 0e+6144 -> 8.100000000000000000000000000000000E+34 Rounded +dqfma2318 fma 90000000000000000000 9000000000000000 0e+6144 -> 8.100000000000000000000000000000000E+35 Rounded +dqfma2319 fma 900000000000000000000 9000000000000000 0e+6144 -> 8.100000000000000000000000000000000E+36 Rounded +dqfma2320 fma 9000000000000000000000 9000000000000000 0e+6144 -> 8.100000000000000000000000000000000E+37 Rounded +dqfma2321 fma 90000000000000000000000 9000000000000000 0e+6144 -> 8.100000000000000000000000000000000E+38 Rounded +dqfma2322 fma 900000000000000000000000 9000000000000000 0e+6144 -> 8.100000000000000000000000000000000E+39 Rounded +dqfma2323 fma 9000000000000000000000000 9000000000000000 0e+6144 -> 8.100000000000000000000000000000000E+40 Rounded + +-- tryzeros cases +dqfma2504 fma 0E-4260 1000E-4260 0e+6144 -> 0E-6176 Clamped +dqfma2505 fma 100E+4260 0E+4260 0e+6144 -> 0E+6111 Clamped + +-- mixed with zeros +dqfma2541 fma 0 -1 0e+6144 -> 0 +dqfma2542 fma -0 -1 0e+6144 -> 0 +dqfma2543 fma 0 1 0e+6144 -> 0 +dqfma2544 fma -0 1 0e+6144 -> 0 +dqfma2545 fma -1 0 0e+6144 -> 0 +dqfma2546 fma -1 -0 0e+6144 -> 0 +dqfma2547 fma 1 0 0e+6144 -> 0 +dqfma2548 fma 1 -0 0e+6144 -> 0 + +dqfma2551 fma 0.0 -1 0e+6144 -> 0.0 +dqfma2552 fma -0.0 -1 0e+6144 -> 0.0 +dqfma2553 fma 0.0 1 0e+6144 -> 0.0 +dqfma2554 fma -0.0 1 0e+6144 -> 0.0 +dqfma2555 fma -1.0 0 0e+6144 -> 0.0 +dqfma2556 fma -1.0 -0 0e+6144 -> 0.0 +dqfma2557 fma 1.0 0 0e+6144 -> 0.0 +dqfma2558 fma 1.0 -0 0e+6144 -> 0.0 + +dqfma2561 fma 0 -1.0 0e+6144 -> 0.0 +dqfma2562 fma -0 -1.0 0e+6144 -> 0.0 +dqfma2563 fma 0 1.0 0e+6144 -> 0.0 +dqfma2564 fma -0 1.0 0e+6144 -> 0.0 +dqfma2565 fma -1 0.0 0e+6144 -> 0.0 +dqfma2566 fma -1 -0.0 0e+6144 -> 0.0 +dqfma2567 fma 1 0.0 0e+6144 -> 0.0 +dqfma2568 fma 1 -0.0 0e+6144 -> 0.0 + +dqfma2571 fma 0.0 -1.0 0e+6144 -> 0.00 +dqfma2572 fma -0.0 -1.0 0e+6144 -> 0.00 +dqfma2573 fma 0.0 1.0 0e+6144 -> 0.00 +dqfma2574 fma -0.0 1.0 0e+6144 -> 0.00 +dqfma2575 fma -1.0 0.0 0e+6144 -> 0.00 +dqfma2576 fma -1.0 -0.0 0e+6144 -> 0.00 +dqfma2577 fma 1.0 0.0 0e+6144 -> 0.00 +dqfma2578 fma 1.0 -0.0 0e+6144 -> 0.00 +dqfma2579 fma 1.0 0.0 0e+6144 -> 0.00 +dqfma2530 fma -1.0 -0.0 0e+6144 -> 0.00 +dqfma2531 fma -1.0 0.0 0e+6144 -> 0.00 +dqfma2532 fma 1.0 -0.0 -0e+6144 -> -0.00 +dqfma2533 fma 1.0 0.0 -0e+6144 -> 0.00 +dqfma2534 fma -1.0 -0.0 -0e+6144 -> 0.00 +dqfma2535 fma -1.0 0.0 -0e+6144 -> -0.00 + + +-- Specials +dqfma2580 fma Inf -Inf 0e+6144 -> -Infinity +dqfma2581 fma Inf -1000 0e+6144 -> -Infinity +dqfma2582 fma Inf -1 0e+6144 -> -Infinity +dqfma2583 fma Inf -0 0e+6144 -> NaN Invalid_operation +dqfma2584 fma Inf 0 0e+6144 -> NaN Invalid_operation +dqfma2585 fma Inf 1 0e+6144 -> Infinity +dqfma2586 fma Inf 1000 0e+6144 -> Infinity +dqfma2587 fma Inf Inf 0e+6144 -> Infinity +dqfma2588 fma -1000 Inf 0e+6144 -> -Infinity +dqfma2589 fma -Inf Inf 0e+6144 -> -Infinity +dqfma2590 fma -1 Inf 0e+6144 -> -Infinity +dqfma2591 fma -0 Inf 0e+6144 -> NaN Invalid_operation +dqfma2592 fma 0 Inf 0e+6144 -> NaN Invalid_operation +dqfma2593 fma 1 Inf 0e+6144 -> Infinity +dqfma2594 fma 1000 Inf 0e+6144 -> Infinity +dqfma2595 fma Inf Inf 0e+6144 -> Infinity + +dqfma2600 fma -Inf -Inf 0e+6144 -> Infinity +dqfma2601 fma -Inf -1000 0e+6144 -> Infinity +dqfma2602 fma -Inf -1 0e+6144 -> Infinity +dqfma2603 fma -Inf -0 0e+6144 -> NaN Invalid_operation +dqfma2604 fma -Inf 0 0e+6144 -> NaN Invalid_operation +dqfma2605 fma -Inf 1 0e+6144 -> -Infinity +dqfma2606 fma -Inf 1000 0e+6144 -> -Infinity +dqfma2607 fma -Inf Inf 0e+6144 -> -Infinity +dqfma2608 fma -1000 Inf 0e+6144 -> -Infinity +dqfma2609 fma -Inf -Inf 0e+6144 -> Infinity +dqfma2610 fma -1 -Inf 0e+6144 -> Infinity +dqfma2611 fma -0 -Inf 0e+6144 -> NaN Invalid_operation +dqfma2612 fma 0 -Inf 0e+6144 -> NaN Invalid_operation +dqfma2613 fma 1 -Inf 0e+6144 -> -Infinity +dqfma2614 fma 1000 -Inf 0e+6144 -> -Infinity +dqfma2615 fma Inf -Inf 0e+6144 -> -Infinity + +dqfma2621 fma NaN -Inf 0e+6144 -> NaN +dqfma2622 fma NaN -1000 0e+6144 -> NaN +dqfma2623 fma NaN -1 0e+6144 -> NaN +dqfma2624 fma NaN -0 0e+6144 -> NaN +dqfma2625 fma NaN 0 0e+6144 -> NaN +dqfma2626 fma NaN 1 0e+6144 -> NaN +dqfma2627 fma NaN 1000 0e+6144 -> NaN +dqfma2628 fma NaN Inf 0e+6144 -> NaN +dqfma2629 fma NaN NaN 0e+6144 -> NaN +dqfma2630 fma -Inf NaN 0e+6144 -> NaN +dqfma2631 fma -1000 NaN 0e+6144 -> NaN +dqfma2632 fma -1 NaN 0e+6144 -> NaN +dqfma2633 fma -0 NaN 0e+6144 -> NaN +dqfma2634 fma 0 NaN 0e+6144 -> NaN +dqfma2635 fma 1 NaN 0e+6144 -> NaN +dqfma2636 fma 1000 NaN 0e+6144 -> NaN +dqfma2637 fma Inf NaN 0e+6144 -> NaN + +dqfma2641 fma sNaN -Inf 0e+6144 -> NaN Invalid_operation +dqfma2642 fma sNaN -1000 0e+6144 -> NaN Invalid_operation +dqfma2643 fma sNaN -1 0e+6144 -> NaN Invalid_operation +dqfma2644 fma sNaN -0 0e+6144 -> NaN Invalid_operation +dqfma2645 fma sNaN 0 0e+6144 -> NaN Invalid_operation +dqfma2646 fma sNaN 1 0e+6144 -> NaN Invalid_operation +dqfma2647 fma sNaN 1000 0e+6144 -> NaN Invalid_operation +dqfma2648 fma sNaN NaN 0e+6144 -> NaN Invalid_operation +dqfma2649 fma sNaN sNaN 0e+6144 -> NaN Invalid_operation +dqfma2650 fma NaN sNaN 0e+6144 -> NaN Invalid_operation +dqfma2651 fma -Inf sNaN 0e+6144 -> NaN Invalid_operation +dqfma2652 fma -1000 sNaN 0e+6144 -> NaN Invalid_operation +dqfma2653 fma -1 sNaN 0e+6144 -> NaN Invalid_operation +dqfma2654 fma -0 sNaN 0e+6144 -> NaN Invalid_operation +dqfma2655 fma 0 sNaN 0e+6144 -> NaN Invalid_operation +dqfma2656 fma 1 sNaN 0e+6144 -> NaN Invalid_operation +dqfma2657 fma 1000 sNaN 0e+6144 -> NaN Invalid_operation +dqfma2658 fma Inf sNaN 0e+6144 -> NaN Invalid_operation +dqfma2659 fma NaN sNaN 0e+6144 -> NaN Invalid_operation + +-- propagating NaNs +dqfma2661 fma NaN9 -Inf 0e+6144 -> NaN9 +dqfma2662 fma NaN8 999 0e+6144 -> NaN8 +dqfma2663 fma NaN71 Inf 0e+6144 -> NaN71 +dqfma2664 fma NaN6 NaN5 0e+6144 -> NaN6 +dqfma2665 fma -Inf NaN4 0e+6144 -> NaN4 +dqfma2666 fma -999 NaN33 0e+6144 -> NaN33 +dqfma2667 fma Inf NaN2 0e+6144 -> NaN2 + +dqfma2671 fma sNaN99 -Inf 0e+6144 -> NaN99 Invalid_operation +dqfma2672 fma sNaN98 -11 0e+6144 -> NaN98 Invalid_operation +dqfma2673 fma sNaN97 NaN 0e+6144 -> NaN97 Invalid_operation +dqfma2674 fma sNaN16 sNaN94 0e+6144 -> NaN16 Invalid_operation +dqfma2675 fma NaN95 sNaN93 0e+6144 -> NaN93 Invalid_operation +dqfma2676 fma -Inf sNaN92 0e+6144 -> NaN92 Invalid_operation +dqfma2677 fma 088 sNaN91 0e+6144 -> NaN91 Invalid_operation +dqfma2678 fma Inf sNaN90 0e+6144 -> NaN90 Invalid_operation +dqfma2679 fma NaN sNaN89 0e+6144 -> NaN89 Invalid_operation + +dqfma2681 fma -NaN9 -Inf 0e+6144 -> -NaN9 +dqfma2682 fma -NaN8 999 0e+6144 -> -NaN8 +dqfma2683 fma -NaN71 Inf 0e+6144 -> -NaN71 +dqfma2684 fma -NaN6 -NaN5 0e+6144 -> -NaN6 +dqfma2685 fma -Inf -NaN4 0e+6144 -> -NaN4 +dqfma2686 fma -999 -NaN33 0e+6144 -> -NaN33 +dqfma2687 fma Inf -NaN2 0e+6144 -> -NaN2 + +dqfma2691 fma -sNaN99 -Inf 0e+6144 -> -NaN99 Invalid_operation +dqfma2692 fma -sNaN98 -11 0e+6144 -> -NaN98 Invalid_operation +dqfma2693 fma -sNaN97 NaN 0e+6144 -> -NaN97 Invalid_operation +dqfma2694 fma -sNaN16 -sNaN94 0e+6144 -> -NaN16 Invalid_operation +dqfma2695 fma -NaN95 -sNaN93 0e+6144 -> -NaN93 Invalid_operation +dqfma2696 fma -Inf -sNaN92 0e+6144 -> -NaN92 Invalid_operation +dqfma2697 fma 088 -sNaN91 0e+6144 -> -NaN91 Invalid_operation +dqfma2698 fma Inf -sNaN90 0e+6144 -> -NaN90 Invalid_operation +dqfma2699 fma -NaN -sNaN89 0e+6144 -> -NaN89 Invalid_operation + +dqfma2701 fma -NaN -Inf 0e+6144 -> -NaN +dqfma2702 fma -NaN 999 0e+6144 -> -NaN +dqfma2703 fma -NaN Inf 0e+6144 -> -NaN +dqfma2704 fma -NaN -NaN 0e+6144 -> -NaN +dqfma2705 fma -Inf -NaN0 0e+6144 -> -NaN +dqfma2706 fma -999 -NaN 0e+6144 -> -NaN +dqfma2707 fma Inf -NaN 0e+6144 -> -NaN + +dqfma2711 fma -sNaN -Inf 0e+6144 -> -NaN Invalid_operation +dqfma2712 fma -sNaN -11 0e+6144 -> -NaN Invalid_operation +dqfma2713 fma -sNaN00 NaN 0e+6144 -> -NaN Invalid_operation +dqfma2714 fma -sNaN -sNaN 0e+6144 -> -NaN Invalid_operation +dqfma2715 fma -NaN -sNaN 0e+6144 -> -NaN Invalid_operation +dqfma2716 fma -Inf -sNaN 0e+6144 -> -NaN Invalid_operation +dqfma2717 fma 088 -sNaN 0e+6144 -> -NaN Invalid_operation +dqfma2718 fma Inf -sNaN 0e+6144 -> -NaN Invalid_operation +dqfma2719 fma -NaN -sNaN 0e+6144 -> -NaN Invalid_operation + +-- overflow and underflow tests .. note subnormal results +-- signs +dqfma2751 fma 1e+4277 1e+3311 0e+6144 -> Infinity Overflow Inexact Rounded +dqfma2752 fma 1e+4277 -1e+3311 0e+6144 -> -Infinity Overflow Inexact Rounded +dqfma2753 fma -1e+4277 1e+3311 0e+6144 -> -Infinity Overflow Inexact Rounded +dqfma2754 fma -1e+4277 -1e+3311 0e+6144 -> Infinity Overflow Inexact Rounded +dqfma2755 fma 1e-4277 1e-3311 0e+6144 -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqfma2756 fma 1e-4277 -1e-3311 0e+6144 -> -0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqfma2757 fma -1e-4277 1e-3311 0e+6144 -> -0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqfma2758 fma -1e-4277 -1e-3311 0e+6144 -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped + +-- 'subnormal' boundary (all hard underflow or overflow in base arithemtic) +dqfma2760 fma 1e-6069 1e-101 0e+6144 -> 1E-6170 Subnormal +dqfma2761 fma 1e-6069 1e-102 0e+6144 -> 1E-6171 Subnormal +dqfma2762 fma 1e-6069 1e-103 0e+6144 -> 1E-6172 Subnormal +dqfma2763 fma 1e-6069 1e-104 0e+6144 -> 1E-6173 Subnormal +dqfma2764 fma 1e-6069 1e-105 0e+6144 -> 1E-6174 Subnormal +dqfma2765 fma 1e-6069 1e-106 0e+6144 -> 1E-6175 Subnormal +dqfma2766 fma 1e-6069 1e-107 0e+6144 -> 1E-6176 Subnormal +dqfma2767 fma 1e-6069 1e-108 0e+6144 -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqfma2768 fma 1e-6069 1e-109 0e+6144 -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqfma2769 fma 1e-6069 1e-110 0e+6144 -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped +-- [no equivalent of 'subnormal' for overflow] +dqfma2770 fma 1e+40 1e+6101 0e+6144 -> 1.000000000000000000000000000000E+6141 Clamped +dqfma2771 fma 1e+40 1e+6102 0e+6144 -> 1.0000000000000000000000000000000E+6142 Clamped +dqfma2772 fma 1e+40 1e+6103 0e+6144 -> 1.00000000000000000000000000000000E+6143 Clamped +dqfma2773 fma 1e+40 1e+6104 0e+6144 -> 1.000000000000000000000000000000000E+6144 Clamped +dqfma2774 fma 1e+40 1e+6105 0e+6144 -> Infinity Overflow Inexact Rounded +dqfma2775 fma 1e+40 1e+6106 0e+6144 -> Infinity Overflow Inexact Rounded +dqfma2776 fma 1e+40 1e+6107 0e+6144 -> Infinity Overflow Inexact Rounded +dqfma2777 fma 1e+40 1e+6108 0e+6144 -> Infinity Overflow Inexact Rounded +dqfma2778 fma 1e+40 1e+6109 0e+6144 -> Infinity Overflow Inexact Rounded +dqfma2779 fma 1e+40 1e+6110 0e+6144 -> Infinity Overflow Inexact Rounded + +dqfma2801 fma 1.0000E-6172 1 0e+6144 -> 1.0000E-6172 Subnormal +dqfma2802 fma 1.000E-6172 1e-1 0e+6144 -> 1.000E-6173 Subnormal +dqfma2803 fma 1.00E-6172 1e-2 0e+6144 -> 1.00E-6174 Subnormal +dqfma2804 fma 1.0E-6172 1e-3 0e+6144 -> 1.0E-6175 Subnormal +dqfma2805 fma 1.0E-6172 1e-4 0e+6144 -> 1E-6176 Subnormal Rounded +dqfma2806 fma 1.3E-6172 1e-4 0e+6144 -> 1E-6176 Underflow Subnormal Inexact Rounded +dqfma2807 fma 1.5E-6172 1e-4 0e+6144 -> 2E-6176 Underflow Subnormal Inexact Rounded +dqfma2808 fma 1.7E-6172 1e-4 0e+6144 -> 2E-6176 Underflow Subnormal Inexact Rounded +dqfma2809 fma 2.3E-6172 1e-4 0e+6144 -> 2E-6176 Underflow Subnormal Inexact Rounded +dqfma2810 fma 2.5E-6172 1e-4 0e+6144 -> 2E-6176 Underflow Subnormal Inexact Rounded +dqfma2811 fma 2.7E-6172 1e-4 0e+6144 -> 3E-6176 Underflow Subnormal Inexact Rounded +dqfma2812 fma 1.49E-6172 1e-4 0e+6144 -> 1E-6176 Underflow Subnormal Inexact Rounded +dqfma2813 fma 1.50E-6172 1e-4 0e+6144 -> 2E-6176 Underflow Subnormal Inexact Rounded +dqfma2814 fma 1.51E-6172 1e-4 0e+6144 -> 2E-6176 Underflow Subnormal Inexact Rounded +dqfma2815 fma 2.49E-6172 1e-4 0e+6144 -> 2E-6176 Underflow Subnormal Inexact Rounded +dqfma2816 fma 2.50E-6172 1e-4 0e+6144 -> 2E-6176 Underflow Subnormal Inexact Rounded +dqfma2817 fma 2.51E-6172 1e-4 0e+6144 -> 3E-6176 Underflow Subnormal Inexact Rounded + +dqfma2818 fma 1E-6172 1e-4 0e+6144 -> 1E-6176 Subnormal +dqfma2819 fma 3E-6172 1e-5 0e+6144 -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqfma2820 fma 5E-6172 1e-5 0e+6144 -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqfma2821 fma 7E-6172 1e-5 0e+6144 -> 1E-6176 Underflow Subnormal Inexact Rounded +dqfma2822 fma 9E-6172 1e-5 0e+6144 -> 1E-6176 Underflow Subnormal Inexact Rounded +dqfma2823 fma 9.9E-6172 1e-5 0e+6144 -> 1E-6176 Underflow Subnormal Inexact Rounded + +dqfma2824 fma 1E-6172 -1e-4 0e+6144 -> -1E-6176 Subnormal +dqfma2825 fma 3E-6172 -1e-5 0e+6144 -> -0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqfma2826 fma -5E-6172 1e-5 0e+6144 -> -0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqfma2827 fma 7E-6172 -1e-5 0e+6144 -> -1E-6176 Underflow Subnormal Inexact Rounded +dqfma2828 fma -9E-6172 1e-5 0e+6144 -> -1E-6176 Underflow Subnormal Inexact Rounded +dqfma2829 fma 9.9E-6172 -1e-5 0e+6144 -> -1E-6176 Underflow Subnormal Inexact Rounded +dqfma2830 fma 3.0E-6172 -1e-5 0e+6144 -> -0E-6176 Underflow Subnormal Inexact Rounded Clamped + +dqfma2831 fma 1.0E-5977 1e-200 0e+6144 -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqfma2832 fma 1.0E-5977 1e-199 0e+6144 -> 1E-6176 Subnormal Rounded +dqfma2833 fma 1.0E-5977 1e-198 0e+6144 -> 1.0E-6175 Subnormal +dqfma2834 fma 2.0E-5977 2e-198 0e+6144 -> 4.0E-6175 Subnormal +dqfma2835 fma 4.0E-5977 4e-198 0e+6144 -> 1.60E-6174 Subnormal +dqfma2836 fma 10.0E-5977 10e-198 0e+6144 -> 1.000E-6173 Subnormal +dqfma2837 fma 30.0E-5977 30e-198 0e+6144 -> 9.000E-6173 Subnormal +dqfma2838 fma 40.0E-5982 40e-166 0e+6144 -> 1.6000E-6145 Subnormal +dqfma2839 fma 40.0E-5982 40e-165 0e+6144 -> 1.6000E-6144 Subnormal +dqfma2840 fma 40.0E-5982 40e-164 0e+6144 -> 1.6000E-6143 + +-- Long operand overflow may be a different path +dqfma2870 fma 100 9.999E+6143 0e+6144 -> Infinity Inexact Overflow Rounded +dqfma2871 fma 100 -9.999E+6143 0e+6144 -> -Infinity Inexact Overflow Rounded +dqfma2872 fma 9.999E+6143 100 0e+6144 -> Infinity Inexact Overflow Rounded +dqfma2873 fma -9.999E+6143 100 0e+6144 -> -Infinity Inexact Overflow Rounded + +-- check for double-rounded subnormals +dqfma2881 fma 1.2347E-6133 1.2347E-40 0e+6144 -> 1.524E-6173 Inexact Rounded Subnormal Underflow +dqfma2882 fma 1.234E-6133 1.234E-40 0e+6144 -> 1.523E-6173 Inexact Rounded Subnormal Underflow +dqfma2883 fma 1.23E-6133 1.23E-40 0e+6144 -> 1.513E-6173 Inexact Rounded Subnormal Underflow +dqfma2884 fma 1.2E-6133 1.2E-40 0e+6144 -> 1.44E-6173 Subnormal +dqfma2885 fma 1.2E-6133 1.2E-41 0e+6144 -> 1.44E-6174 Subnormal +dqfma2886 fma 1.2E-6133 1.2E-42 0e+6144 -> 1.4E-6175 Subnormal Inexact Rounded Underflow +dqfma2887 fma 1.2E-6133 1.3E-42 0e+6144 -> 1.6E-6175 Subnormal Inexact Rounded Underflow +dqfma2888 fma 1.3E-6133 1.3E-42 0e+6144 -> 1.7E-6175 Subnormal Inexact Rounded Underflow +dqfma2889 fma 1.3E-6133 1.3E-43 0e+6144 -> 2E-6176 Subnormal Inexact Rounded Underflow +dqfma2890 fma 1.3E-6134 1.3E-43 0e+6144 -> 0E-6176 Clamped Subnormal Inexact Rounded Underflow + +dqfma2891 fma 1.2345E-39 1.234E-6133 0e+6144 -> 1.5234E-6172 Inexact Rounded Subnormal Underflow +dqfma2892 fma 1.23456E-39 1.234E-6133 0e+6144 -> 1.5234E-6172 Inexact Rounded Subnormal Underflow +dqfma2893 fma 1.2345E-40 1.234E-6133 0e+6144 -> 1.523E-6173 Inexact Rounded Subnormal Underflow +dqfma2894 fma 1.23456E-40 1.234E-6133 0e+6144 -> 1.523E-6173 Inexact Rounded Subnormal Underflow +dqfma2895 fma 1.2345E-41 1.234E-6133 0e+6144 -> 1.52E-6174 Inexact Rounded Subnormal Underflow +dqfma2896 fma 1.23456E-41 1.234E-6133 0e+6144 -> 1.52E-6174 Inexact Rounded Subnormal Underflow + +-- Now explore the case where we get a normal result with Underflow +-- prove operands are exact +dqfma2906 fma 9.999999999999999999999999999999999E-6143 1 0e+6144 -> 9.999999999999999999999999999999999E-6143 +dqfma2907 fma 1 0.09999999999999999999999999999999999 0e+6144 -> 0.09999999999999999999999999999999999 +-- the next rounds to Nmin +dqfma2908 fma 9.999999999999999999999999999999999E-6143 0.09999999999999999999999999999999999 0e+6144 -> 1.000000000000000000000000000000000E-6143 Underflow Inexact Subnormal Rounded + +-- hugest +dqfma2909 fma 9999999999999999999999999999999999 9999999999999999999999999999999999 0e+6144 -> 9.999999999999999999999999999999998E+67 Inexact Rounded + +-- Examples from SQL proposal (Krishna Kulkarni) +precision: 34 +rounding: half_up +maxExponent: 6144 +minExponent: -6143 +dqfma21001 fma 130E-2 120E-2 0e+6144 -> 1.5600 +dqfma21002 fma 130E-2 12E-1 0e+6144 -> 1.560 +dqfma21003 fma 130E-2 1E0 0e+6144 -> 1.30 +dqfma21004 fma 1E2 1E4 0e+6144 -> 1E+6 + +-- Null tests +dqfma2990 fma 10 # 0e+6144 -> NaN Invalid_operation +dqfma2991 fma # 10 0e+6144 -> NaN Invalid_operation + + +-- ADDITION TESTS ------------------------------------------------------ +rounding: half_even + +-- [first group are 'quick confidence check'] +dqadd3001 fma 1 1 1 -> 2 +dqadd3002 fma 1 2 3 -> 5 +dqadd3003 fma 1 '5.75' '3.3' -> 9.05 +dqadd3004 fma 1 '5' '-3' -> 2 +dqadd3005 fma 1 '-5' '-3' -> -8 +dqadd3006 fma 1 '-7' '2.5' -> -4.5 +dqadd3007 fma 1 '0.7' '0.3' -> 1.0 +dqadd3008 fma 1 '1.25' '1.25' -> 2.50 +dqadd3009 fma 1 '1.23456789' '1.00000000' -> '2.23456789' +dqadd3010 fma 1 '1.23456789' '1.00000011' -> '2.23456800' + +-- 1234567890123456 1234567890123456 +dqadd3011 fma 1 '0.4444444444444444444444444444444446' '0.5555555555555555555555555555555555' -> '1.000000000000000000000000000000000' Inexact Rounded +dqadd3012 fma 1 '0.4444444444444444444444444444444445' '0.5555555555555555555555555555555555' -> '1.000000000000000000000000000000000' Rounded +dqadd3013 fma 1 '0.4444444444444444444444444444444444' '0.5555555555555555555555555555555555' -> '0.9999999999999999999999999999999999' +dqadd3014 fma 1 '4444444444444444444444444444444444' '0.49' -> '4444444444444444444444444444444444' Inexact Rounded +dqadd3015 fma 1 '4444444444444444444444444444444444' '0.499' -> '4444444444444444444444444444444444' Inexact Rounded +dqadd3016 fma 1 '4444444444444444444444444444444444' '0.4999' -> '4444444444444444444444444444444444' Inexact Rounded +dqadd3017 fma 1 '4444444444444444444444444444444444' '0.5000' -> '4444444444444444444444444444444444' Inexact Rounded +dqadd3018 fma 1 '4444444444444444444444444444444444' '0.5001' -> '4444444444444444444444444444444445' Inexact Rounded +dqadd3019 fma 1 '4444444444444444444444444444444444' '0.501' -> '4444444444444444444444444444444445' Inexact Rounded +dqadd3020 fma 1 '4444444444444444444444444444444444' '0.51' -> '4444444444444444444444444444444445' Inexact Rounded + +dqadd3021 fma 1 0 1 -> 1 +dqadd3022 fma 1 1 1 -> 2 +dqadd3023 fma 1 2 1 -> 3 +dqadd3024 fma 1 3 1 -> 4 +dqadd3025 fma 1 4 1 -> 5 +dqadd3026 fma 1 5 1 -> 6 +dqadd3027 fma 1 6 1 -> 7 +dqadd3028 fma 1 7 1 -> 8 +dqadd3029 fma 1 8 1 -> 9 +dqadd3030 fma 1 9 1 -> 10 + +-- some carrying effects +dqadd3031 fma 1 '0.9998' '0.0000' -> '0.9998' +dqadd3032 fma 1 '0.9998' '0.0001' -> '0.9999' +dqadd3033 fma 1 '0.9998' '0.0002' -> '1.0000' +dqadd3034 fma 1 '0.9998' '0.0003' -> '1.0001' + +dqadd3035 fma 1 '70' '10000e+34' -> '1.000000000000000000000000000000000E+38' Inexact Rounded +dqadd3036 fma 1 '700' '10000e+34' -> '1.000000000000000000000000000000000E+38' Inexact Rounded +dqadd3037 fma 1 '7000' '10000e+34' -> '1.000000000000000000000000000000000E+38' Inexact Rounded +dqadd3038 fma 1 '70000' '10000e+34' -> '1.000000000000000000000000000000001E+38' Inexact Rounded +dqadd3039 fma 1 '700000' '10000e+34' -> '1.000000000000000000000000000000007E+38' Rounded + +-- symmetry: +dqadd3040 fma 1 '10000e+34' '70' -> '1.000000000000000000000000000000000E+38' Inexact Rounded +dqadd3041 fma 1 '10000e+34' '700' -> '1.000000000000000000000000000000000E+38' Inexact Rounded +dqadd3042 fma 1 '10000e+34' '7000' -> '1.000000000000000000000000000000000E+38' Inexact Rounded +dqadd3044 fma 1 '10000e+34' '70000' -> '1.000000000000000000000000000000001E+38' Inexact Rounded +dqadd3045 fma 1 '10000e+34' '700000' -> '1.000000000000000000000000000000007E+38' Rounded + +-- same, without rounding +dqadd3046 fma 1 '10000e+9' '7' -> '10000000000007' +dqadd3047 fma 1 '10000e+9' '70' -> '10000000000070' +dqadd3048 fma 1 '10000e+9' '700' -> '10000000000700' +dqadd3049 fma 1 '10000e+9' '7000' -> '10000000007000' +dqadd3050 fma 1 '10000e+9' '70000' -> '10000000070000' +dqadd3051 fma 1 '10000e+9' '700000' -> '10000000700000' +dqadd3052 fma 1 '10000e+9' '7000000' -> '10000007000000' + +-- examples from decarith +dqadd3053 fma 1 '12' '7.00' -> '19.00' +dqadd3054 fma 1 '1.3' '-1.07' -> '0.23' +dqadd3055 fma 1 '1.3' '-1.30' -> '0.00' +dqadd3056 fma 1 '1.3' '-2.07' -> '-0.77' +dqadd3057 fma 1 '1E+2' '1E+4' -> '1.01E+4' + +-- leading zero preservation +dqadd3061 fma 1 1 '0.0001' -> '1.0001' +dqadd3062 fma 1 1 '0.00001' -> '1.00001' +dqadd3063 fma 1 1 '0.000001' -> '1.000001' +dqadd3064 fma 1 1 '0.0000001' -> '1.0000001' +dqadd3065 fma 1 1 '0.00000001' -> '1.00000001' + +-- some funny zeros [in case of bad signum] +dqadd3070 fma 1 1 0 -> 1 +dqadd3071 fma 1 1 0. -> 1 +dqadd3072 fma 1 1 .0 -> 1.0 +dqadd3073 fma 1 1 0.0 -> 1.0 +dqadd3074 fma 1 1 0.00 -> 1.00 +dqadd3075 fma 1 0 1 -> 1 +dqadd3076 fma 1 0. 1 -> 1 +dqadd3077 fma 1 .0 1 -> 1.0 +dqadd3078 fma 1 0.0 1 -> 1.0 +dqadd3079 fma 1 0.00 1 -> 1.00 + +-- some carries +dqadd3080 fma 1 999999998 1 -> 999999999 +dqadd3081 fma 1 999999999 1 -> 1000000000 +dqadd3082 fma 1 99999999 1 -> 100000000 +dqadd3083 fma 1 9999999 1 -> 10000000 +dqadd3084 fma 1 999999 1 -> 1000000 +dqadd3085 fma 1 99999 1 -> 100000 +dqadd3086 fma 1 9999 1 -> 10000 +dqadd3087 fma 1 999 1 -> 1000 +dqadd3088 fma 1 99 1 -> 100 +dqadd3089 fma 1 9 1 -> 10 + + +-- more LHS swaps +dqadd3090 fma 1 '-56267E-10' 0 -> '-0.0000056267' +dqadd3091 fma 1 '-56267E-6' 0 -> '-0.056267' +dqadd3092 fma 1 '-56267E-5' 0 -> '-0.56267' +dqadd3093 fma 1 '-56267E-4' 0 -> '-5.6267' +dqadd3094 fma 1 '-56267E-3' 0 -> '-56.267' +dqadd3095 fma 1 '-56267E-2' 0 -> '-562.67' +dqadd3096 fma 1 '-56267E-1' 0 -> '-5626.7' +dqadd3097 fma 1 '-56267E-0' 0 -> '-56267' +dqadd3098 fma 1 '-5E-10' 0 -> '-5E-10' +dqadd3099 fma 1 '-5E-7' 0 -> '-5E-7' +dqadd3100 fma 1 '-5E-6' 0 -> '-0.000005' +dqadd3101 fma 1 '-5E-5' 0 -> '-0.00005' +dqadd3102 fma 1 '-5E-4' 0 -> '-0.0005' +dqadd3103 fma 1 '-5E-1' 0 -> '-0.5' +dqadd3104 fma 1 '-5E0' 0 -> '-5' +dqadd3105 fma 1 '-5E1' 0 -> '-50' +dqadd3106 fma 1 '-5E5' 0 -> '-500000' +dqadd3107 fma 1 '-5E33' 0 -> '-5000000000000000000000000000000000' +dqadd3108 fma 1 '-5E34' 0 -> '-5.000000000000000000000000000000000E+34' Rounded +dqadd3109 fma 1 '-5E35' 0 -> '-5.000000000000000000000000000000000E+35' Rounded +dqadd3110 fma 1 '-5E36' 0 -> '-5.000000000000000000000000000000000E+36' Rounded +dqadd3111 fma 1 '-5E100' 0 -> '-5.000000000000000000000000000000000E+100' Rounded + +-- more RHS swaps +dqadd3113 fma 1 0 '-56267E-10' -> '-0.0000056267' +dqadd3114 fma 1 0 '-56267E-6' -> '-0.056267' +dqadd3116 fma 1 0 '-56267E-5' -> '-0.56267' +dqadd3117 fma 1 0 '-56267E-4' -> '-5.6267' +dqadd3119 fma 1 0 '-56267E-3' -> '-56.267' +dqadd3120 fma 1 0 '-56267E-2' -> '-562.67' +dqadd3121 fma 1 0 '-56267E-1' -> '-5626.7' +dqadd3122 fma 1 0 '-56267E-0' -> '-56267' +dqadd3123 fma 1 0 '-5E-10' -> '-5E-10' +dqadd3124 fma 1 0 '-5E-7' -> '-5E-7' +dqadd3125 fma 1 0 '-5E-6' -> '-0.000005' +dqadd3126 fma 1 0 '-5E-5' -> '-0.00005' +dqadd3127 fma 1 0 '-5E-4' -> '-0.0005' +dqadd3128 fma 1 0 '-5E-1' -> '-0.5' +dqadd3129 fma 1 0 '-5E0' -> '-5' +dqadd3130 fma 1 0 '-5E1' -> '-50' +dqadd3131 fma 1 0 '-5E5' -> '-500000' +dqadd3132 fma 1 0 '-5E33' -> '-5000000000000000000000000000000000' +dqadd3133 fma 1 0 '-5E34' -> '-5.000000000000000000000000000000000E+34' Rounded +dqadd3134 fma 1 0 '-5E35' -> '-5.000000000000000000000000000000000E+35' Rounded +dqadd3135 fma 1 0 '-5E36' -> '-5.000000000000000000000000000000000E+36' Rounded +dqadd3136 fma 1 0 '-5E100' -> '-5.000000000000000000000000000000000E+100' Rounded + +-- related +dqadd3137 fma 1 1 '0E-39' -> '1.000000000000000000000000000000000' Rounded +dqadd3138 fma 1 -1 '0E-39' -> '-1.000000000000000000000000000000000' Rounded +dqadd3139 fma 1 '0E-39' 1 -> '1.000000000000000000000000000000000' Rounded +dqadd3140 fma 1 '0E-39' -1 -> '-1.000000000000000000000000000000000' Rounded +dqadd3141 fma 1 1E+29 0.0000 -> '100000000000000000000000000000.0000' +dqadd3142 fma 1 1E+29 0.00000 -> '100000000000000000000000000000.0000' Rounded +dqadd3143 fma 1 0.000 1E+30 -> '1000000000000000000000000000000.000' +dqadd3144 fma 1 0.0000 1E+30 -> '1000000000000000000000000000000.000' Rounded + +-- [some of the next group are really constructor tests] +dqadd3146 fma 1 '00.0' 0 -> '0.0' +dqadd3147 fma 1 '0.00' 0 -> '0.00' +dqadd3148 fma 1 0 '0.00' -> '0.00' +dqadd3149 fma 1 0 '00.0' -> '0.0' +dqadd3150 fma 1 '00.0' '0.00' -> '0.00' +dqadd3151 fma 1 '0.00' '00.0' -> '0.00' +dqadd3152 fma 1 '3' '.3' -> '3.3' +dqadd3153 fma 1 '3.' '.3' -> '3.3' +dqadd3154 fma 1 '3.0' '.3' -> '3.3' +dqadd3155 fma 1 '3.00' '.3' -> '3.30' +dqadd3156 fma 1 '3' '3' -> '6' +dqadd3157 fma 1 '3' '+3' -> '6' +dqadd3158 fma 1 '3' '-3' -> '0' +dqadd3159 fma 1 '0.3' '-0.3' -> '0.0' +dqadd3160 fma 1 '0.03' '-0.03' -> '0.00' + +-- try borderline precision, with carries, etc. +dqadd3161 fma 1 '1E+12' '-1' -> '999999999999' +dqadd3162 fma 1 '1E+12' '1.11' -> '1000000000001.11' +dqadd3163 fma 1 '1.11' '1E+12' -> '1000000000001.11' +dqadd3164 fma 1 '-1' '1E+12' -> '999999999999' +dqadd3165 fma 1 '7E+12' '-1' -> '6999999999999' +dqadd3166 fma 1 '7E+12' '1.11' -> '7000000000001.11' +dqadd3167 fma 1 '1.11' '7E+12' -> '7000000000001.11' +dqadd3168 fma 1 '-1' '7E+12' -> '6999999999999' + +rounding: half_up +dqadd3170 fma 1 '4.444444444444444444444444444444444' '0.5555555555555555555555555555555567' -> '5.000000000000000000000000000000001' Inexact Rounded +dqadd3171 fma 1 '4.444444444444444444444444444444444' '0.5555555555555555555555555555555566' -> '5.000000000000000000000000000000001' Inexact Rounded +dqadd3172 fma 1 '4.444444444444444444444444444444444' '0.5555555555555555555555555555555565' -> '5.000000000000000000000000000000001' Inexact Rounded +dqadd3173 fma 1 '4.444444444444444444444444444444444' '0.5555555555555555555555555555555564' -> '5.000000000000000000000000000000000' Inexact Rounded +dqadd3174 fma 1 '4.444444444444444444444444444444444' '0.5555555555555555555555555555555553' -> '4.999999999999999999999999999999999' Inexact Rounded +dqadd3175 fma 1 '4.444444444444444444444444444444444' '0.5555555555555555555555555555555552' -> '4.999999999999999999999999999999999' Inexact Rounded +dqadd3176 fma 1 '4.444444444444444444444444444444444' '0.5555555555555555555555555555555551' -> '4.999999999999999999999999999999999' Inexact Rounded +dqadd3177 fma 1 '4.444444444444444444444444444444444' '0.5555555555555555555555555555555550' -> '4.999999999999999999999999999999999' Rounded +dqadd3178 fma 1 '4.444444444444444444444444444444444' '0.5555555555555555555555555555555545' -> '4.999999999999999999999999999999999' Inexact Rounded +dqadd3179 fma 1 '4.444444444444444444444444444444444' '0.5555555555555555555555555555555544' -> '4.999999999999999999999999999999998' Inexact Rounded +dqadd3180 fma 1 '4.444444444444444444444444444444444' '0.5555555555555555555555555555555543' -> '4.999999999999999999999999999999998' Inexact Rounded +dqadd3181 fma 1 '4.444444444444444444444444444444444' '0.5555555555555555555555555555555542' -> '4.999999999999999999999999999999998' Inexact Rounded +dqadd3182 fma 1 '4.444444444444444444444444444444444' '0.5555555555555555555555555555555541' -> '4.999999999999999999999999999999998' Inexact Rounded +dqadd3183 fma 1 '4.444444444444444444444444444444444' '0.5555555555555555555555555555555540' -> '4.999999999999999999999999999999998' Rounded + +-- and some more, including residue effects and different roundings +rounding: half_up +dqadd3200 fma 1 '1231234567890123456784560123456789' 0 -> '1231234567890123456784560123456789' +dqadd3201 fma 1 '1231234567890123456784560123456789' 0.000000001 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd3202 fma 1 '1231234567890123456784560123456789' 0.000001 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd3203 fma 1 '1231234567890123456784560123456789' 0.1 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd3204 fma 1 '1231234567890123456784560123456789' 0.4 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd3205 fma 1 '1231234567890123456784560123456789' 0.49 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd3206 fma 1 '1231234567890123456784560123456789' 0.499999 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd3207 fma 1 '1231234567890123456784560123456789' 0.499999999 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd3208 fma 1 '1231234567890123456784560123456789' 0.5 -> '1231234567890123456784560123456790' Inexact Rounded +dqadd3209 fma 1 '1231234567890123456784560123456789' 0.500000001 -> '1231234567890123456784560123456790' Inexact Rounded +dqadd3210 fma 1 '1231234567890123456784560123456789' 0.500001 -> '1231234567890123456784560123456790' Inexact Rounded +dqadd3211 fma 1 '1231234567890123456784560123456789' 0.51 -> '1231234567890123456784560123456790' Inexact Rounded +dqadd3212 fma 1 '1231234567890123456784560123456789' 0.6 -> '1231234567890123456784560123456790' Inexact Rounded +dqadd3213 fma 1 '1231234567890123456784560123456789' 0.9 -> '1231234567890123456784560123456790' Inexact Rounded +dqadd3214 fma 1 '1231234567890123456784560123456789' 0.99999 -> '1231234567890123456784560123456790' Inexact Rounded +dqadd3215 fma 1 '1231234567890123456784560123456789' 0.999999999 -> '1231234567890123456784560123456790' Inexact Rounded +dqadd3216 fma 1 '1231234567890123456784560123456789' 1 -> '1231234567890123456784560123456790' +dqadd3217 fma 1 '1231234567890123456784560123456789' 1.000000001 -> '1231234567890123456784560123456790' Inexact Rounded +dqadd3218 fma 1 '1231234567890123456784560123456789' 1.00001 -> '1231234567890123456784560123456790' Inexact Rounded +dqadd3219 fma 1 '1231234567890123456784560123456789' 1.1 -> '1231234567890123456784560123456790' Inexact Rounded + +rounding: half_even +dqadd3220 fma 1 '1231234567890123456784560123456789' 0 -> '1231234567890123456784560123456789' +dqadd3221 fma 1 '1231234567890123456784560123456789' 0.000000001 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd3222 fma 1 '1231234567890123456784560123456789' 0.000001 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd3223 fma 1 '1231234567890123456784560123456789' 0.1 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd3224 fma 1 '1231234567890123456784560123456789' 0.4 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd3225 fma 1 '1231234567890123456784560123456789' 0.49 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd3226 fma 1 '1231234567890123456784560123456789' 0.499999 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd3227 fma 1 '1231234567890123456784560123456789' 0.499999999 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd3228 fma 1 '1231234567890123456784560123456789' 0.5 -> '1231234567890123456784560123456790' Inexact Rounded +dqadd3229 fma 1 '1231234567890123456784560123456789' 0.500000001 -> '1231234567890123456784560123456790' Inexact Rounded +dqadd3230 fma 1 '1231234567890123456784560123456789' 0.500001 -> '1231234567890123456784560123456790' Inexact Rounded +dqadd3231 fma 1 '1231234567890123456784560123456789' 0.51 -> '1231234567890123456784560123456790' Inexact Rounded +dqadd3232 fma 1 '1231234567890123456784560123456789' 0.6 -> '1231234567890123456784560123456790' Inexact Rounded +dqadd3233 fma 1 '1231234567890123456784560123456789' 0.9 -> '1231234567890123456784560123456790' Inexact Rounded +dqadd3234 fma 1 '1231234567890123456784560123456789' 0.99999 -> '1231234567890123456784560123456790' Inexact Rounded +dqadd3235 fma 1 '1231234567890123456784560123456789' 0.999999999 -> '1231234567890123456784560123456790' Inexact Rounded +dqadd3236 fma 1 '1231234567890123456784560123456789' 1 -> '1231234567890123456784560123456790' +dqadd3237 fma 1 '1231234567890123456784560123456789' 1.00000001 -> '1231234567890123456784560123456790' Inexact Rounded +dqadd3238 fma 1 '1231234567890123456784560123456789' 1.00001 -> '1231234567890123456784560123456790' Inexact Rounded +dqadd3239 fma 1 '1231234567890123456784560123456789' 1.1 -> '1231234567890123456784560123456790' Inexact Rounded +-- critical few with even bottom digit... +dqadd3240 fma 1 '1231234567890123456784560123456788' 0.499999999 -> '1231234567890123456784560123456788' Inexact Rounded +dqadd3241 fma 1 '1231234567890123456784560123456788' 0.5 -> '1231234567890123456784560123456788' Inexact Rounded +dqadd3242 fma 1 '1231234567890123456784560123456788' 0.500000001 -> '1231234567890123456784560123456789' Inexact Rounded + +rounding: down +dqadd3250 fma 1 '1231234567890123456784560123456789' 0 -> '1231234567890123456784560123456789' +dqadd3251 fma 1 '1231234567890123456784560123456789' 0.000000001 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd3252 fma 1 '1231234567890123456784560123456789' 0.000001 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd3253 fma 1 '1231234567890123456784560123456789' 0.1 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd3254 fma 1 '1231234567890123456784560123456789' 0.4 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd3255 fma 1 '1231234567890123456784560123456789' 0.49 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd3256 fma 1 '1231234567890123456784560123456789' 0.499999 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd3257 fma 1 '1231234567890123456784560123456789' 0.499999999 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd3258 fma 1 '1231234567890123456784560123456789' 0.5 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd3259 fma 1 '1231234567890123456784560123456789' 0.500000001 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd3260 fma 1 '1231234567890123456784560123456789' 0.500001 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd3261 fma 1 '1231234567890123456784560123456789' 0.51 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd3262 fma 1 '1231234567890123456784560123456789' 0.6 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd3263 fma 1 '1231234567890123456784560123456789' 0.9 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd3264 fma 1 '1231234567890123456784560123456789' 0.99999 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd3265 fma 1 '1231234567890123456784560123456789' 0.999999999 -> '1231234567890123456784560123456789' Inexact Rounded +dqadd3266 fma 1 '1231234567890123456784560123456789' 1 -> '1231234567890123456784560123456790' +dqadd3267 fma 1 '1231234567890123456784560123456789' 1.00000001 -> '1231234567890123456784560123456790' Inexact Rounded +dqadd3268 fma 1 '1231234567890123456784560123456789' 1.00001 -> '1231234567890123456784560123456790' Inexact Rounded +dqadd3269 fma 1 '1231234567890123456784560123456789' 1.1 -> '1231234567890123456784560123456790' Inexact Rounded + +-- 1 in last place tests +rounding: half_up +dqadd3301 fma 1 -1 1 -> 0 +dqadd3302 fma 1 0 1 -> 1 +dqadd3303 fma 1 1 1 -> 2 +dqadd3304 fma 1 12 1 -> 13 +dqadd3305 fma 1 98 1 -> 99 +dqadd3306 fma 1 99 1 -> 100 +dqadd3307 fma 1 100 1 -> 101 +dqadd3308 fma 1 101 1 -> 102 +dqadd3309 fma 1 -1 -1 -> -2 +dqadd3310 fma 1 0 -1 -> -1 +dqadd3311 fma 1 1 -1 -> 0 +dqadd3312 fma 1 12 -1 -> 11 +dqadd3313 fma 1 98 -1 -> 97 +dqadd3314 fma 1 99 -1 -> 98 +dqadd3315 fma 1 100 -1 -> 99 +dqadd3316 fma 1 101 -1 -> 100 + +dqadd3321 fma 1 -0.01 0.01 -> 0.00 +dqadd3322 fma 1 0.00 0.01 -> 0.01 +dqadd3323 fma 1 0.01 0.01 -> 0.02 +dqadd3324 fma 1 0.12 0.01 -> 0.13 +dqadd3325 fma 1 0.98 0.01 -> 0.99 +dqadd3326 fma 1 0.99 0.01 -> 1.00 +dqadd3327 fma 1 1.00 0.01 -> 1.01 +dqadd3328 fma 1 1.01 0.01 -> 1.02 +dqadd3329 fma 1 -0.01 -0.01 -> -0.02 +dqadd3330 fma 1 0.00 -0.01 -> -0.01 +dqadd3331 fma 1 0.01 -0.01 -> 0.00 +dqadd3332 fma 1 0.12 -0.01 -> 0.11 +dqadd3333 fma 1 0.98 -0.01 -> 0.97 +dqadd3334 fma 1 0.99 -0.01 -> 0.98 +dqadd3335 fma 1 1.00 -0.01 -> 0.99 +dqadd3336 fma 1 1.01 -0.01 -> 1.00 + +-- some more cases where adding 0 affects the coefficient +dqadd3340 fma 1 1E+3 0 -> 1000 +dqadd3341 fma 1 1E+33 0 -> 1000000000000000000000000000000000 +dqadd3342 fma 1 1E+34 0 -> 1.000000000000000000000000000000000E+34 Rounded +dqadd3343 fma 1 1E+35 0 -> 1.000000000000000000000000000000000E+35 Rounded +-- which simply follow from these cases ... +dqadd3344 fma 1 1E+3 1 -> 1001 +dqadd3345 fma 1 1E+33 1 -> 1000000000000000000000000000000001 +dqadd3346 fma 1 1E+34 1 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd3347 fma 1 1E+35 1 -> 1.000000000000000000000000000000000E+35 Inexact Rounded +dqadd3348 fma 1 1E+3 7 -> 1007 +dqadd3349 fma 1 1E+33 7 -> 1000000000000000000000000000000007 +dqadd3350 fma 1 1E+34 7 -> 1.000000000000000000000000000000001E+34 Inexact Rounded +dqadd3351 fma 1 1E+35 7 -> 1.000000000000000000000000000000000E+35 Inexact Rounded + +-- tryzeros cases +rounding: half_up +dqadd3360 fma 1 0E+50 10000E+1 -> 1.0000E+5 +dqadd3361 fma 1 0E-50 10000E+1 -> 100000.0000000000000000000000000000 Rounded +dqadd3362 fma 1 10000E+1 0E-50 -> 100000.0000000000000000000000000000 Rounded +dqadd3363 fma 1 10000E+1 10000E-50 -> 100000.0000000000000000000000000000 Rounded Inexact +dqadd3364 fma 1 9.999999999999999999999999999999999E+6144 -9.999999999999999999999999999999999E+6144 -> 0E+6111 +-- 1 234567890123456789012345678901234 + +-- a curiosity from JSR 13 testing +rounding: half_down +dqadd3370 fma 1 999999999999999999999999999999999 815 -> 1000000000000000000000000000000814 +dqadd3371 fma 1 9999999999999999999999999999999999 815 -> 1.000000000000000000000000000000081E+34 Rounded Inexact +rounding: half_up +dqadd3372 fma 1 999999999999999999999999999999999 815 -> 1000000000000000000000000000000814 +dqadd3373 fma 1 9999999999999999999999999999999999 815 -> 1.000000000000000000000000000000081E+34 Rounded Inexact +rounding: half_even +dqadd3374 fma 1 999999999999999999999999999999999 815 -> 1000000000000000000000000000000814 +dqadd3375 fma 1 9999999999999999999999999999999999 815 -> 1.000000000000000000000000000000081E+34 Rounded Inexact + +-- ulp replacement tests +dqadd3400 fma 1 1 77e-32 -> 1.00000000000000000000000000000077 +dqadd3401 fma 1 1 77e-33 -> 1.000000000000000000000000000000077 +dqadd3402 fma 1 1 77e-34 -> 1.000000000000000000000000000000008 Inexact Rounded +dqadd3403 fma 1 1 77e-35 -> 1.000000000000000000000000000000001 Inexact Rounded +dqadd3404 fma 1 1 77e-36 -> 1.000000000000000000000000000000000 Inexact Rounded +dqadd3405 fma 1 1 77e-37 -> 1.000000000000000000000000000000000 Inexact Rounded +dqadd3406 fma 1 1 77e-299 -> 1.000000000000000000000000000000000 Inexact Rounded + +dqadd3410 fma 1 10 77e-32 -> 10.00000000000000000000000000000077 +dqadd3411 fma 1 10 77e-33 -> 10.00000000000000000000000000000008 Inexact Rounded +dqadd3412 fma 1 10 77e-34 -> 10.00000000000000000000000000000001 Inexact Rounded +dqadd3413 fma 1 10 77e-35 -> 10.00000000000000000000000000000000 Inexact Rounded +dqadd3414 fma 1 10 77e-36 -> 10.00000000000000000000000000000000 Inexact Rounded +dqadd3415 fma 1 10 77e-37 -> 10.00000000000000000000000000000000 Inexact Rounded +dqadd3416 fma 1 10 77e-299 -> 10.00000000000000000000000000000000 Inexact Rounded + +dqadd3420 fma 1 77e-32 1 -> 1.00000000000000000000000000000077 +dqadd3421 fma 1 77e-33 1 -> 1.000000000000000000000000000000077 +dqadd3422 fma 1 77e-34 1 -> 1.000000000000000000000000000000008 Inexact Rounded +dqadd3423 fma 1 77e-35 1 -> 1.000000000000000000000000000000001 Inexact Rounded +dqadd3424 fma 1 77e-36 1 -> 1.000000000000000000000000000000000 Inexact Rounded +dqadd3425 fma 1 77e-37 1 -> 1.000000000000000000000000000000000 Inexact Rounded +dqadd3426 fma 1 77e-299 1 -> 1.000000000000000000000000000000000 Inexact Rounded + +dqadd3430 fma 1 77e-32 10 -> 10.00000000000000000000000000000077 +dqadd3431 fma 1 77e-33 10 -> 10.00000000000000000000000000000008 Inexact Rounded +dqadd3432 fma 1 77e-34 10 -> 10.00000000000000000000000000000001 Inexact Rounded +dqadd3433 fma 1 77e-35 10 -> 10.00000000000000000000000000000000 Inexact Rounded +dqadd3434 fma 1 77e-36 10 -> 10.00000000000000000000000000000000 Inexact Rounded +dqadd3435 fma 1 77e-37 10 -> 10.00000000000000000000000000000000 Inexact Rounded +dqadd3436 fma 1 77e-299 10 -> 10.00000000000000000000000000000000 Inexact Rounded + +-- negative ulps +dqadd36440 fma 1 1 -77e-32 -> 0.99999999999999999999999999999923 +dqadd36441 fma 1 1 -77e-33 -> 0.999999999999999999999999999999923 +dqadd36442 fma 1 1 -77e-34 -> 0.9999999999999999999999999999999923 +dqadd36443 fma 1 1 -77e-35 -> 0.9999999999999999999999999999999992 Inexact Rounded +dqadd36444 fma 1 1 -77e-36 -> 0.9999999999999999999999999999999999 Inexact Rounded +dqadd36445 fma 1 1 -77e-37 -> 1.000000000000000000000000000000000 Inexact Rounded +dqadd36446 fma 1 1 -77e-99 -> 1.000000000000000000000000000000000 Inexact Rounded + +dqadd36450 fma 1 10 -77e-32 -> 9.99999999999999999999999999999923 +dqadd36451 fma 1 10 -77e-33 -> 9.999999999999999999999999999999923 +dqadd36452 fma 1 10 -77e-34 -> 9.999999999999999999999999999999992 Inexact Rounded +dqadd36453 fma 1 10 -77e-35 -> 9.999999999999999999999999999999999 Inexact Rounded +dqadd36454 fma 1 10 -77e-36 -> 10.00000000000000000000000000000000 Inexact Rounded +dqadd36455 fma 1 10 -77e-37 -> 10.00000000000000000000000000000000 Inexact Rounded +dqadd36456 fma 1 10 -77e-99 -> 10.00000000000000000000000000000000 Inexact Rounded + +dqadd36460 fma 1 -77e-32 1 -> 0.99999999999999999999999999999923 +dqadd36461 fma 1 -77e-33 1 -> 0.999999999999999999999999999999923 +dqadd36462 fma 1 -77e-34 1 -> 0.9999999999999999999999999999999923 +dqadd36463 fma 1 -77e-35 1 -> 0.9999999999999999999999999999999992 Inexact Rounded +dqadd36464 fma 1 -77e-36 1 -> 0.9999999999999999999999999999999999 Inexact Rounded +dqadd36465 fma 1 -77e-37 1 -> 1.000000000000000000000000000000000 Inexact Rounded +dqadd36466 fma 1 -77e-99 1 -> 1.000000000000000000000000000000000 Inexact Rounded + +dqadd36470 fma 1 -77e-32 10 -> 9.99999999999999999999999999999923 +dqadd36471 fma 1 -77e-33 10 -> 9.999999999999999999999999999999923 +dqadd36472 fma 1 -77e-34 10 -> 9.999999999999999999999999999999992 Inexact Rounded +dqadd36473 fma 1 -77e-35 10 -> 9.999999999999999999999999999999999 Inexact Rounded +dqadd36474 fma 1 -77e-36 10 -> 10.00000000000000000000000000000000 Inexact Rounded +dqadd36475 fma 1 -77e-37 10 -> 10.00000000000000000000000000000000 Inexact Rounded +dqadd36476 fma 1 -77e-99 10 -> 10.00000000000000000000000000000000 Inexact Rounded + +-- negative ulps +dqadd36480 fma 1 -1 77e-32 -> -0.99999999999999999999999999999923 +dqadd36481 fma 1 -1 77e-33 -> -0.999999999999999999999999999999923 +dqadd36482 fma 1 -1 77e-34 -> -0.9999999999999999999999999999999923 +dqadd36483 fma 1 -1 77e-35 -> -0.9999999999999999999999999999999992 Inexact Rounded +dqadd36484 fma 1 -1 77e-36 -> -0.9999999999999999999999999999999999 Inexact Rounded +dqadd36485 fma 1 -1 77e-37 -> -1.000000000000000000000000000000000 Inexact Rounded +dqadd36486 fma 1 -1 77e-99 -> -1.000000000000000000000000000000000 Inexact Rounded + +dqadd36490 fma 1 -10 77e-32 -> -9.99999999999999999999999999999923 +dqadd36491 fma 1 -10 77e-33 -> -9.999999999999999999999999999999923 +dqadd36492 fma 1 -10 77e-34 -> -9.999999999999999999999999999999992 Inexact Rounded +dqadd36493 fma 1 -10 77e-35 -> -9.999999999999999999999999999999999 Inexact Rounded +dqadd36494 fma 1 -10 77e-36 -> -10.00000000000000000000000000000000 Inexact Rounded +dqadd36495 fma 1 -10 77e-37 -> -10.00000000000000000000000000000000 Inexact Rounded +dqadd36496 fma 1 -10 77e-99 -> -10.00000000000000000000000000000000 Inexact Rounded + +dqadd36500 fma 1 77e-32 -1 -> -0.99999999999999999999999999999923 +dqadd36501 fma 1 77e-33 -1 -> -0.999999999999999999999999999999923 +dqadd36502 fma 1 77e-34 -1 -> -0.9999999999999999999999999999999923 +dqadd36503 fma 1 77e-35 -1 -> -0.9999999999999999999999999999999992 Inexact Rounded +dqadd36504 fma 1 77e-36 -1 -> -0.9999999999999999999999999999999999 Inexact Rounded +dqadd36505 fma 1 77e-37 -1 -> -1.000000000000000000000000000000000 Inexact Rounded +dqadd36506 fma 1 77e-99 -1 -> -1.000000000000000000000000000000000 Inexact Rounded + +dqadd36510 fma 1 77e-32 -10 -> -9.99999999999999999999999999999923 +dqadd36511 fma 1 77e-33 -10 -> -9.999999999999999999999999999999923 +dqadd36512 fma 1 77e-34 -10 -> -9.999999999999999999999999999999992 Inexact Rounded +dqadd36513 fma 1 77e-35 -10 -> -9.999999999999999999999999999999999 Inexact Rounded +dqadd36514 fma 1 77e-36 -10 -> -10.00000000000000000000000000000000 Inexact Rounded +dqadd36515 fma 1 77e-37 -10 -> -10.00000000000000000000000000000000 Inexact Rounded +dqadd36516 fma 1 77e-99 -10 -> -10.00000000000000000000000000000000 Inexact Rounded + +-- and some more residue effects and different roundings +rounding: half_up +dqadd36540 fma 1 '9876543219876543216543210123456789' 0 -> '9876543219876543216543210123456789' +dqadd36541 fma 1 '9876543219876543216543210123456789' 0.000000001 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd36542 fma 1 '9876543219876543216543210123456789' 0.000001 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd36543 fma 1 '9876543219876543216543210123456789' 0.1 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd36544 fma 1 '9876543219876543216543210123456789' 0.4 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd36545 fma 1 '9876543219876543216543210123456789' 0.49 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd36546 fma 1 '9876543219876543216543210123456789' 0.499999 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd36547 fma 1 '9876543219876543216543210123456789' 0.499999999 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd36548 fma 1 '9876543219876543216543210123456789' 0.5 -> '9876543219876543216543210123456790' Inexact Rounded +dqadd36549 fma 1 '9876543219876543216543210123456789' 0.500000001 -> '9876543219876543216543210123456790' Inexact Rounded +dqadd36550 fma 1 '9876543219876543216543210123456789' 0.500001 -> '9876543219876543216543210123456790' Inexact Rounded +dqadd36551 fma 1 '9876543219876543216543210123456789' 0.51 -> '9876543219876543216543210123456790' Inexact Rounded +dqadd36552 fma 1 '9876543219876543216543210123456789' 0.6 -> '9876543219876543216543210123456790' Inexact Rounded +dqadd36553 fma 1 '9876543219876543216543210123456789' 0.9 -> '9876543219876543216543210123456790' Inexact Rounded +dqadd36554 fma 1 '9876543219876543216543210123456789' 0.99999 -> '9876543219876543216543210123456790' Inexact Rounded +dqadd36555 fma 1 '9876543219876543216543210123456789' 0.999999999 -> '9876543219876543216543210123456790' Inexact Rounded +dqadd36556 fma 1 '9876543219876543216543210123456789' 1 -> '9876543219876543216543210123456790' +dqadd36557 fma 1 '9876543219876543216543210123456789' 1.000000001 -> '9876543219876543216543210123456790' Inexact Rounded +dqadd36558 fma 1 '9876543219876543216543210123456789' 1.00001 -> '9876543219876543216543210123456790' Inexact Rounded +dqadd36559 fma 1 '9876543219876543216543210123456789' 1.1 -> '9876543219876543216543210123456790' Inexact Rounded + +rounding: half_even +dqadd36560 fma 1 '9876543219876543216543210123456789' 0 -> '9876543219876543216543210123456789' +dqadd36561 fma 1 '9876543219876543216543210123456789' 0.000000001 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd36562 fma 1 '9876543219876543216543210123456789' 0.000001 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd36563 fma 1 '9876543219876543216543210123456789' 0.1 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd36564 fma 1 '9876543219876543216543210123456789' 0.4 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd36565 fma 1 '9876543219876543216543210123456789' 0.49 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd36566 fma 1 '9876543219876543216543210123456789' 0.499999 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd36567 fma 1 '9876543219876543216543210123456789' 0.499999999 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd36568 fma 1 '9876543219876543216543210123456789' 0.5 -> '9876543219876543216543210123456790' Inexact Rounded +dqadd36569 fma 1 '9876543219876543216543210123456789' 0.500000001 -> '9876543219876543216543210123456790' Inexact Rounded +dqadd36570 fma 1 '9876543219876543216543210123456789' 0.500001 -> '9876543219876543216543210123456790' Inexact Rounded +dqadd36571 fma 1 '9876543219876543216543210123456789' 0.51 -> '9876543219876543216543210123456790' Inexact Rounded +dqadd36572 fma 1 '9876543219876543216543210123456789' 0.6 -> '9876543219876543216543210123456790' Inexact Rounded +dqadd36573 fma 1 '9876543219876543216543210123456789' 0.9 -> '9876543219876543216543210123456790' Inexact Rounded +dqadd36574 fma 1 '9876543219876543216543210123456789' 0.99999 -> '9876543219876543216543210123456790' Inexact Rounded +dqadd36575 fma 1 '9876543219876543216543210123456789' 0.999999999 -> '9876543219876543216543210123456790' Inexact Rounded +dqadd36576 fma 1 '9876543219876543216543210123456789' 1 -> '9876543219876543216543210123456790' +dqadd36577 fma 1 '9876543219876543216543210123456789' 1.00000001 -> '9876543219876543216543210123456790' Inexact Rounded +dqadd36578 fma 1 '9876543219876543216543210123456789' 1.00001 -> '9876543219876543216543210123456790' Inexact Rounded +dqadd36579 fma 1 '9876543219876543216543210123456789' 1.1 -> '9876543219876543216543210123456790' Inexact Rounded + +-- critical few with even bottom digit... +dqadd37540 fma 1 '9876543219876543216543210123456788' 0.499999999 -> '9876543219876543216543210123456788' Inexact Rounded +dqadd37541 fma 1 '9876543219876543216543210123456788' 0.5 -> '9876543219876543216543210123456788' Inexact Rounded +dqadd37542 fma 1 '9876543219876543216543210123456788' 0.500000001 -> '9876543219876543216543210123456789' Inexact Rounded + +rounding: down +dqadd37550 fma 1 '9876543219876543216543210123456789' 0 -> '9876543219876543216543210123456789' +dqadd37551 fma 1 '9876543219876543216543210123456789' 0.000000001 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd37552 fma 1 '9876543219876543216543210123456789' 0.000001 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd37553 fma 1 '9876543219876543216543210123456789' 0.1 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd37554 fma 1 '9876543219876543216543210123456789' 0.4 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd37555 fma 1 '9876543219876543216543210123456789' 0.49 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd37556 fma 1 '9876543219876543216543210123456789' 0.499999 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd37557 fma 1 '9876543219876543216543210123456789' 0.499999999 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd37558 fma 1 '9876543219876543216543210123456789' 0.5 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd37559 fma 1 '9876543219876543216543210123456789' 0.500000001 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd37560 fma 1 '9876543219876543216543210123456789' 0.500001 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd37561 fma 1 '9876543219876543216543210123456789' 0.51 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd37562 fma 1 '9876543219876543216543210123456789' 0.6 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd37563 fma 1 '9876543219876543216543210123456789' 0.9 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd37564 fma 1 '9876543219876543216543210123456789' 0.99999 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd37565 fma 1 '9876543219876543216543210123456789' 0.999999999 -> '9876543219876543216543210123456789' Inexact Rounded +dqadd37566 fma 1 '9876543219876543216543210123456789' 1 -> '9876543219876543216543210123456790' +dqadd37567 fma 1 '9876543219876543216543210123456789' 1.00000001 -> '9876543219876543216543210123456790' Inexact Rounded +dqadd37568 fma 1 '9876543219876543216543210123456789' 1.00001 -> '9876543219876543216543210123456790' Inexact Rounded +dqadd37569 fma 1 '9876543219876543216543210123456789' 1.1 -> '9876543219876543216543210123456790' Inexact Rounded + +-- more zeros, etc. +rounding: half_even + +dqadd37701 fma 1 5.00 1.00E-3 -> 5.00100 +dqadd37702 fma 1 00.00 0.000 -> 0.000 +dqadd37703 fma 1 00.00 0E-3 -> 0.000 +dqadd37704 fma 1 0E-3 00.00 -> 0.000 + +dqadd37710 fma 1 0E+3 00.00 -> 0.00 +dqadd37711 fma 1 0E+3 00.0 -> 0.0 +dqadd37712 fma 1 0E+3 00. -> 0 +dqadd37713 fma 1 0E+3 00.E+1 -> 0E+1 +dqadd37714 fma 1 0E+3 00.E+2 -> 0E+2 +dqadd37715 fma 1 0E+3 00.E+3 -> 0E+3 +dqadd37716 fma 1 0E+3 00.E+4 -> 0E+3 +dqadd37717 fma 1 0E+3 00.E+5 -> 0E+3 +dqadd37718 fma 1 0E+3 -00.0 -> 0.0 +dqadd37719 fma 1 0E+3 -00. -> 0 +dqadd37731 fma 1 0E+3 -00.E+1 -> 0E+1 + +dqadd37720 fma 1 00.00 0E+3 -> 0.00 +dqadd37721 fma 1 00.0 0E+3 -> 0.0 +dqadd37722 fma 1 00. 0E+3 -> 0 +dqadd37723 fma 1 00.E+1 0E+3 -> 0E+1 +dqadd37724 fma 1 00.E+2 0E+3 -> 0E+2 +dqadd37725 fma 1 00.E+3 0E+3 -> 0E+3 +dqadd37726 fma 1 00.E+4 0E+3 -> 0E+3 +dqadd37727 fma 1 00.E+5 0E+3 -> 0E+3 +dqadd37728 fma 1 -00.00 0E+3 -> 0.00 +dqadd37729 fma 1 -00.0 0E+3 -> 0.0 +dqadd37730 fma 1 -00. 0E+3 -> 0 + +dqadd37732 fma 1 0 0 -> 0 +dqadd37733 fma 1 0 -0 -> 0 +dqadd37734 fma 1 -0 0 -> 0 +dqadd37735 fma 1 -0 -0 -> -0 -- IEEE 854 special case + +dqadd37736 fma 1 1 -1 -> 0 +dqadd37737 fma 1 -1 -1 -> -2 +dqadd37738 fma 1 1 1 -> 2 +dqadd37739 fma 1 -1 1 -> 0 + +dqadd37741 fma 1 0 -1 -> -1 +dqadd37742 fma 1 -0 -1 -> -1 +dqadd37743 fma 1 0 1 -> 1 +dqadd37744 fma 1 -0 1 -> 1 +dqadd37745 fma 1 -1 0 -> -1 +dqadd37746 fma 1 -1 -0 -> -1 +dqadd37747 fma 1 1 0 -> 1 +dqadd37748 fma 1 1 -0 -> 1 + +dqadd37751 fma 1 0.0 -1 -> -1.0 +dqadd37752 fma 1 -0.0 -1 -> -1.0 +dqadd37753 fma 1 0.0 1 -> 1.0 +dqadd37754 fma 1 -0.0 1 -> 1.0 +dqadd37755 fma 1 -1.0 0 -> -1.0 +dqadd37756 fma 1 -1.0 -0 -> -1.0 +dqadd37757 fma 1 1.0 0 -> 1.0 +dqadd37758 fma 1 1.0 -0 -> 1.0 + +dqadd37761 fma 1 0 -1.0 -> -1.0 +dqadd37762 fma 1 -0 -1.0 -> -1.0 +dqadd37763 fma 1 0 1.0 -> 1.0 +dqadd37764 fma 1 -0 1.0 -> 1.0 +dqadd37765 fma 1 -1 0.0 -> -1.0 +dqadd37766 fma 1 -1 -0.0 -> -1.0 +dqadd37767 fma 1 1 0.0 -> 1.0 +dqadd37768 fma 1 1 -0.0 -> 1.0 + +dqadd37771 fma 1 0.0 -1.0 -> -1.0 +dqadd37772 fma 1 -0.0 -1.0 -> -1.0 +dqadd37773 fma 1 0.0 1.0 -> 1.0 +dqadd37774 fma 1 -0.0 1.0 -> 1.0 +dqadd37775 fma 1 -1.0 0.0 -> -1.0 +dqadd37776 fma 1 -1.0 -0.0 -> -1.0 +dqadd37777 fma 1 1.0 0.0 -> 1.0 +dqadd37778 fma 1 1.0 -0.0 -> 1.0 + +-- Specials +dqadd37780 fma 1 -Inf -Inf -> -Infinity +dqadd37781 fma 1 -Inf -1000 -> -Infinity +dqadd37782 fma 1 -Inf -1 -> -Infinity +dqadd37783 fma 1 -Inf -0 -> -Infinity +dqadd37784 fma 1 -Inf 0 -> -Infinity +dqadd37785 fma 1 -Inf 1 -> -Infinity +dqadd37786 fma 1 -Inf 1000 -> -Infinity +dqadd37787 fma 1 -1000 -Inf -> -Infinity +dqadd37788 fma 1 -Inf -Inf -> -Infinity +dqadd37789 fma 1 -1 -Inf -> -Infinity +dqadd37790 fma 1 -0 -Inf -> -Infinity +dqadd37791 fma 1 0 -Inf -> -Infinity +dqadd37792 fma 1 1 -Inf -> -Infinity +dqadd37793 fma 1 1000 -Inf -> -Infinity +dqadd37794 fma 1 Inf -Inf -> NaN Invalid_operation + +dqadd37800 fma 1 Inf -Inf -> NaN Invalid_operation +dqadd37801 fma 1 Inf -1000 -> Infinity +dqadd37802 fma 1 Inf -1 -> Infinity +dqadd37803 fma 1 Inf -0 -> Infinity +dqadd37804 fma 1 Inf 0 -> Infinity +dqadd37805 fma 1 Inf 1 -> Infinity +dqadd37806 fma 1 Inf 1000 -> Infinity +dqadd37807 fma 1 Inf Inf -> Infinity +dqadd37808 fma 1 -1000 Inf -> Infinity +dqadd37809 fma 1 -Inf Inf -> NaN Invalid_operation +dqadd37810 fma 1 -1 Inf -> Infinity +dqadd37811 fma 1 -0 Inf -> Infinity +dqadd37812 fma 1 0 Inf -> Infinity +dqadd37813 fma 1 1 Inf -> Infinity +dqadd37814 fma 1 1000 Inf -> Infinity +dqadd37815 fma 1 Inf Inf -> Infinity + +dqadd37821 fma 1 NaN -Inf -> NaN +dqadd37822 fma 1 NaN -1000 -> NaN +dqadd37823 fma 1 NaN -1 -> NaN +dqadd37824 fma 1 NaN -0 -> NaN +dqadd37825 fma 1 NaN 0 -> NaN +dqadd37826 fma 1 NaN 1 -> NaN +dqadd37827 fma 1 NaN 1000 -> NaN +dqadd37828 fma 1 NaN Inf -> NaN +dqadd37829 fma 1 NaN NaN -> NaN +dqadd37830 fma 1 -Inf NaN -> NaN +dqadd37831 fma 1 -1000 NaN -> NaN +dqadd37832 fma 1 -1 NaN -> NaN +dqadd37833 fma 1 -0 NaN -> NaN +dqadd37834 fma 1 0 NaN -> NaN +dqadd37835 fma 1 1 NaN -> NaN +dqadd37836 fma 1 1000 NaN -> NaN +dqadd37837 fma 1 Inf NaN -> NaN + +dqadd37841 fma 1 sNaN -Inf -> NaN Invalid_operation +dqadd37842 fma 1 sNaN -1000 -> NaN Invalid_operation +dqadd37843 fma 1 sNaN -1 -> NaN Invalid_operation +dqadd37844 fma 1 sNaN -0 -> NaN Invalid_operation +dqadd37845 fma 1 sNaN 0 -> NaN Invalid_operation +dqadd37846 fma 1 sNaN 1 -> NaN Invalid_operation +dqadd37847 fma 1 sNaN 1000 -> NaN Invalid_operation +dqadd37848 fma 1 sNaN NaN -> NaN Invalid_operation +dqadd37849 fma 1 sNaN sNaN -> NaN Invalid_operation +dqadd37850 fma 1 NaN sNaN -> NaN Invalid_operation +dqadd37851 fma 1 -Inf sNaN -> NaN Invalid_operation +dqadd37852 fma 1 -1000 sNaN -> NaN Invalid_operation +dqadd37853 fma 1 -1 sNaN -> NaN Invalid_operation +dqadd37854 fma 1 -0 sNaN -> NaN Invalid_operation +dqadd37855 fma 1 0 sNaN -> NaN Invalid_operation +dqadd37856 fma 1 1 sNaN -> NaN Invalid_operation +dqadd37857 fma 1 1000 sNaN -> NaN Invalid_operation +dqadd37858 fma 1 Inf sNaN -> NaN Invalid_operation +dqadd37859 fma 1 NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +dqadd37861 fma 1 NaN1 -Inf -> NaN1 +dqadd37862 fma 1 +NaN2 -1000 -> NaN2 +dqadd37863 fma 1 NaN3 1000 -> NaN3 +dqadd37864 fma 1 NaN4 Inf -> NaN4 +dqadd37865 fma 1 NaN5 +NaN6 -> NaN5 +dqadd37866 fma 1 -Inf NaN7 -> NaN7 +dqadd37867 fma 1 -1000 NaN8 -> NaN8 +dqadd37868 fma 1 1000 NaN9 -> NaN9 +dqadd37869 fma 1 Inf +NaN10 -> NaN10 +dqadd37871 fma 1 sNaN11 -Inf -> NaN11 Invalid_operation +dqadd37872 fma 1 sNaN12 -1000 -> NaN12 Invalid_operation +dqadd37873 fma 1 sNaN13 1000 -> NaN13 Invalid_operation +dqadd37874 fma 1 sNaN14 NaN17 -> NaN14 Invalid_operation +dqadd37875 fma 1 sNaN15 sNaN18 -> NaN15 Invalid_operation +dqadd37876 fma 1 NaN16 sNaN19 -> NaN19 Invalid_operation +dqadd37877 fma 1 -Inf +sNaN20 -> NaN20 Invalid_operation +dqadd37878 fma 1 -1000 sNaN21 -> NaN21 Invalid_operation +dqadd37879 fma 1 1000 sNaN22 -> NaN22 Invalid_operation +dqadd37880 fma 1 Inf sNaN23 -> NaN23 Invalid_operation +dqadd37881 fma 1 +NaN25 +sNaN24 -> NaN24 Invalid_operation +dqadd37882 fma 1 -NaN26 NaN28 -> -NaN26 +dqadd37883 fma 1 -sNaN27 sNaN29 -> -NaN27 Invalid_operation +dqadd37884 fma 1 1000 -NaN30 -> -NaN30 +dqadd37885 fma 1 1000 -sNaN31 -> -NaN31 Invalid_operation + +-- Here we explore near the boundary of rounding a subnormal to Nmin +dqadd37575 fma 1 1E-6143 -1E-6176 -> 9.99999999999999999999999999999999E-6144 Subnormal +dqadd37576 fma 1 -1E-6143 +1E-6176 -> -9.99999999999999999999999999999999E-6144 Subnormal + +-- check overflow edge case +-- 1234567890123456 +dqadd37972 apply 9.999999999999999999999999999999999E+6144 -> 9.999999999999999999999999999999999E+6144 +dqadd37973 fma 1 9.999999999999999999999999999999999E+6144 1 -> 9.999999999999999999999999999999999E+6144 Inexact Rounded +dqadd37974 fma 1 9999999999999999999999999999999999E+6111 1 -> 9.999999999999999999999999999999999E+6144 Inexact Rounded +dqadd37975 fma 1 9999999999999999999999999999999999E+6111 1E+6111 -> Infinity Overflow Inexact Rounded +dqadd37976 fma 1 9999999999999999999999999999999999E+6111 9E+6110 -> Infinity Overflow Inexact Rounded +dqadd37977 fma 1 9999999999999999999999999999999999E+6111 8E+6110 -> Infinity Overflow Inexact Rounded +dqadd37978 fma 1 9999999999999999999999999999999999E+6111 7E+6110 -> Infinity Overflow Inexact Rounded +dqadd37979 fma 1 9999999999999999999999999999999999E+6111 6E+6110 -> Infinity Overflow Inexact Rounded +dqadd37980 fma 1 9999999999999999999999999999999999E+6111 5E+6110 -> Infinity Overflow Inexact Rounded +dqadd37981 fma 1 9999999999999999999999999999999999E+6111 4E+6110 -> 9.999999999999999999999999999999999E+6144 Inexact Rounded +dqadd37982 fma 1 9999999999999999999999999999999999E+6111 3E+6110 -> 9.999999999999999999999999999999999E+6144 Inexact Rounded +dqadd37983 fma 1 9999999999999999999999999999999999E+6111 2E+6110 -> 9.999999999999999999999999999999999E+6144 Inexact Rounded +dqadd37984 fma 1 9999999999999999999999999999999999E+6111 1E+6110 -> 9.999999999999999999999999999999999E+6144 Inexact Rounded + +dqadd37985 apply -9.999999999999999999999999999999999E+6144 -> -9.999999999999999999999999999999999E+6144 +dqadd37986 fma 1 -9.999999999999999999999999999999999E+6144 -1 -> -9.999999999999999999999999999999999E+6144 Inexact Rounded +dqadd37987 fma 1 -9999999999999999999999999999999999E+6111 -1 -> -9.999999999999999999999999999999999E+6144 Inexact Rounded +dqadd37988 fma 1 -9999999999999999999999999999999999E+6111 -1E+6111 -> -Infinity Overflow Inexact Rounded +dqadd37989 fma 1 -9999999999999999999999999999999999E+6111 -9E+6110 -> -Infinity Overflow Inexact Rounded +dqadd37990 fma 1 -9999999999999999999999999999999999E+6111 -8E+6110 -> -Infinity Overflow Inexact Rounded +dqadd37991 fma 1 -9999999999999999999999999999999999E+6111 -7E+6110 -> -Infinity Overflow Inexact Rounded +dqadd37992 fma 1 -9999999999999999999999999999999999E+6111 -6E+6110 -> -Infinity Overflow Inexact Rounded +dqadd37993 fma 1 -9999999999999999999999999999999999E+6111 -5E+6110 -> -Infinity Overflow Inexact Rounded +dqadd37994 fma 1 -9999999999999999999999999999999999E+6111 -4E+6110 -> -9.999999999999999999999999999999999E+6144 Inexact Rounded +dqadd37995 fma 1 -9999999999999999999999999999999999E+6111 -3E+6110 -> -9.999999999999999999999999999999999E+6144 Inexact Rounded +dqadd37996 fma 1 -9999999999999999999999999999999999E+6111 -2E+6110 -> -9.999999999999999999999999999999999E+6144 Inexact Rounded +dqadd37997 fma 1 -9999999999999999999999999999999999E+6111 -1E+6110 -> -9.999999999999999999999999999999999E+6144 Inexact Rounded + +-- And for round down full and subnormal results +rounding: down +dqadd371100 fma 1 1e+2 -1e-6143 -> 99.99999999999999999999999999999999 Rounded Inexact +dqadd371101 fma 1 1e+1 -1e-6143 -> 9.999999999999999999999999999999999 Rounded Inexact +dqadd371103 fma 1 +1 -1e-6143 -> 0.9999999999999999999999999999999999 Rounded Inexact +dqadd371104 fma 1 1e-1 -1e-6143 -> 0.09999999999999999999999999999999999 Rounded Inexact +dqadd371105 fma 1 1e-2 -1e-6143 -> 0.009999999999999999999999999999999999 Rounded Inexact +dqadd371106 fma 1 1e-3 -1e-6143 -> 0.0009999999999999999999999999999999999 Rounded Inexact +dqadd371107 fma 1 1e-4 -1e-6143 -> 0.00009999999999999999999999999999999999 Rounded Inexact +dqadd371108 fma 1 1e-5 -1e-6143 -> 0.000009999999999999999999999999999999999 Rounded Inexact +dqadd371109 fma 1 1e-6 -1e-6143 -> 9.999999999999999999999999999999999E-7 Rounded Inexact + +rounding: ceiling +dqadd371110 fma 1 -1e+2 +1e-6143 -> -99.99999999999999999999999999999999 Rounded Inexact +dqadd371111 fma 1 -1e+1 +1e-6143 -> -9.999999999999999999999999999999999 Rounded Inexact +dqadd371113 fma 1 -1 +1e-6143 -> -0.9999999999999999999999999999999999 Rounded Inexact +dqadd371114 fma 1 -1e-1 +1e-6143 -> -0.09999999999999999999999999999999999 Rounded Inexact +dqadd371115 fma 1 -1e-2 +1e-6143 -> -0.009999999999999999999999999999999999 Rounded Inexact +dqadd371116 fma 1 -1e-3 +1e-6143 -> -0.0009999999999999999999999999999999999 Rounded Inexact +dqadd371117 fma 1 -1e-4 +1e-6143 -> -0.00009999999999999999999999999999999999 Rounded Inexact +dqadd371118 fma 1 -1e-5 +1e-6143 -> -0.000009999999999999999999999999999999999 Rounded Inexact +dqadd371119 fma 1 -1e-6 +1e-6143 -> -9.999999999999999999999999999999999E-7 Rounded Inexact + +-- tests based on Gunnar Degnbol's edge case +rounding: half_even + +dqadd371300 fma 1 1E34 -0.5 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd371310 fma 1 1E34 -0.51 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd371311 fma 1 1E34 -0.501 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd371312 fma 1 1E34 -0.5001 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd371313 fma 1 1E34 -0.50001 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd371314 fma 1 1E34 -0.500001 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd371315 fma 1 1E34 -0.5000001 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd371316 fma 1 1E34 -0.50000001 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd371317 fma 1 1E34 -0.500000001 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd371318 fma 1 1E34 -0.5000000001 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd371319 fma 1 1E34 -0.50000000001 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd371320 fma 1 1E34 -0.500000000001 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd371321 fma 1 1E34 -0.5000000000001 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd371322 fma 1 1E34 -0.50000000000001 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd371323 fma 1 1E34 -0.500000000000001 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd371324 fma 1 1E34 -0.5000000000000001 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd371325 fma 1 1E34 -0.5000000000000000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd371326 fma 1 1E34 -0.500000000000000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd371327 fma 1 1E34 -0.50000000000000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd371328 fma 1 1E34 -0.5000000000000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd371329 fma 1 1E34 -0.500000000000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd371330 fma 1 1E34 -0.50000000000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd371331 fma 1 1E34 -0.5000000000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd371332 fma 1 1E34 -0.500000000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd371333 fma 1 1E34 -0.50000000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd371334 fma 1 1E34 -0.5000000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd371335 fma 1 1E34 -0.500000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd371336 fma 1 1E34 -0.50000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd371337 fma 1 1E34 -0.5000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd371338 fma 1 1E34 -0.500 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd371339 fma 1 1E34 -0.50 -> 1.000000000000000000000000000000000E+34 Inexact Rounded + +dqadd371340 fma 1 1E34 -5000000.000010001 -> 9999999999999999999999999995000000 Inexact Rounded +dqadd371341 fma 1 1E34 -5000000.000000001 -> 9999999999999999999999999995000000 Inexact Rounded + +dqadd371349 fma 1 9999999999999999999999999999999999 0.4 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd371350 fma 1 9999999999999999999999999999999999 0.49 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd371351 fma 1 9999999999999999999999999999999999 0.499 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd371352 fma 1 9999999999999999999999999999999999 0.4999 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd371353 fma 1 9999999999999999999999999999999999 0.49999 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd371354 fma 1 9999999999999999999999999999999999 0.499999 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd371355 fma 1 9999999999999999999999999999999999 0.4999999 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd371356 fma 1 9999999999999999999999999999999999 0.49999999 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd371357 fma 1 9999999999999999999999999999999999 0.499999999 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd371358 fma 1 9999999999999999999999999999999999 0.4999999999 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd371359 fma 1 9999999999999999999999999999999999 0.49999999999 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd371360 fma 1 9999999999999999999999999999999999 0.499999999999 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd371361 fma 1 9999999999999999999999999999999999 0.4999999999999 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd371362 fma 1 9999999999999999999999999999999999 0.49999999999999 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd371363 fma 1 9999999999999999999999999999999999 0.499999999999999 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd371364 fma 1 9999999999999999999999999999999999 0.4999999999999999 -> 9999999999999999999999999999999999 Inexact Rounded +dqadd371365 fma 1 9999999999999999999999999999999999 0.5000000000000000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd371367 fma 1 9999999999999999999999999999999999 0.500000000000000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd371368 fma 1 9999999999999999999999999999999999 0.50000000000000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd371369 fma 1 9999999999999999999999999999999999 0.5000000000000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd371370 fma 1 9999999999999999999999999999999999 0.500000000000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd371371 fma 1 9999999999999999999999999999999999 0.50000000000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd371372 fma 1 9999999999999999999999999999999999 0.5000000000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd371373 fma 1 9999999999999999999999999999999999 0.500000000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd371374 fma 1 9999999999999999999999999999999999 0.50000000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd371375 fma 1 9999999999999999999999999999999999 0.5000000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd371376 fma 1 9999999999999999999999999999999999 0.500000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd371377 fma 1 9999999999999999999999999999999999 0.50000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd371378 fma 1 9999999999999999999999999999999999 0.5000 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd371379 fma 1 9999999999999999999999999999999999 0.500 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd371380 fma 1 9999999999999999999999999999999999 0.50 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd371381 fma 1 9999999999999999999999999999999999 0.5 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd371382 fma 1 9999999999999999999999999999999999 0.5000000000000001 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd371383 fma 1 9999999999999999999999999999999999 0.500000000000001 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd371384 fma 1 9999999999999999999999999999999999 0.50000000000001 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd371385 fma 1 9999999999999999999999999999999999 0.5000000000001 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd371386 fma 1 9999999999999999999999999999999999 0.500000000001 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd371387 fma 1 9999999999999999999999999999999999 0.50000000001 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd371388 fma 1 9999999999999999999999999999999999 0.5000000001 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd371389 fma 1 9999999999999999999999999999999999 0.500000001 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd371390 fma 1 9999999999999999999999999999999999 0.50000001 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd371391 fma 1 9999999999999999999999999999999999 0.5000001 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd371392 fma 1 9999999999999999999999999999999999 0.500001 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd371393 fma 1 9999999999999999999999999999999999 0.50001 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd371394 fma 1 9999999999999999999999999999999999 0.5001 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd371395 fma 1 9999999999999999999999999999999999 0.501 -> 1.000000000000000000000000000000000E+34 Inexact Rounded +dqadd371396 fma 1 9999999999999999999999999999999999 0.51 -> 1.000000000000000000000000000000000E+34 Inexact Rounded + +-- More GD edge cases, where difference between the unadjusted +-- exponents is larger than the maximum precision and one side is 0 +dqadd371420 fma 1 0 1.123456789987654321123456789012345 -> 1.123456789987654321123456789012345 +dqadd371421 fma 1 0 1.123456789987654321123456789012345E-1 -> 0.1123456789987654321123456789012345 +dqadd371422 fma 1 0 1.123456789987654321123456789012345E-2 -> 0.01123456789987654321123456789012345 +dqadd371423 fma 1 0 1.123456789987654321123456789012345E-3 -> 0.001123456789987654321123456789012345 +dqadd371424 fma 1 0 1.123456789987654321123456789012345E-4 -> 0.0001123456789987654321123456789012345 +dqadd371425 fma 1 0 1.123456789987654321123456789012345E-5 -> 0.00001123456789987654321123456789012345 +dqadd371426 fma 1 0 1.123456789987654321123456789012345E-6 -> 0.000001123456789987654321123456789012345 +dqadd371427 fma 1 0 1.123456789987654321123456789012345E-7 -> 1.123456789987654321123456789012345E-7 +dqadd371428 fma 1 0 1.123456789987654321123456789012345E-8 -> 1.123456789987654321123456789012345E-8 +dqadd371429 fma 1 0 1.123456789987654321123456789012345E-9 -> 1.123456789987654321123456789012345E-9 +dqadd371430 fma 1 0 1.123456789987654321123456789012345E-10 -> 1.123456789987654321123456789012345E-10 +dqadd371431 fma 1 0 1.123456789987654321123456789012345E-11 -> 1.123456789987654321123456789012345E-11 +dqadd371432 fma 1 0 1.123456789987654321123456789012345E-12 -> 1.123456789987654321123456789012345E-12 +dqadd371433 fma 1 0 1.123456789987654321123456789012345E-13 -> 1.123456789987654321123456789012345E-13 +dqadd371434 fma 1 0 1.123456789987654321123456789012345E-14 -> 1.123456789987654321123456789012345E-14 +dqadd371435 fma 1 0 1.123456789987654321123456789012345E-15 -> 1.123456789987654321123456789012345E-15 +dqadd371436 fma 1 0 1.123456789987654321123456789012345E-16 -> 1.123456789987654321123456789012345E-16 +dqadd371437 fma 1 0 1.123456789987654321123456789012345E-17 -> 1.123456789987654321123456789012345E-17 +dqadd371438 fma 1 0 1.123456789987654321123456789012345E-18 -> 1.123456789987654321123456789012345E-18 +dqadd371439 fma 1 0 1.123456789987654321123456789012345E-19 -> 1.123456789987654321123456789012345E-19 +dqadd371440 fma 1 0 1.123456789987654321123456789012345E-20 -> 1.123456789987654321123456789012345E-20 +dqadd371441 fma 1 0 1.123456789987654321123456789012345E-21 -> 1.123456789987654321123456789012345E-21 +dqadd371442 fma 1 0 1.123456789987654321123456789012345E-22 -> 1.123456789987654321123456789012345E-22 +dqadd371443 fma 1 0 1.123456789987654321123456789012345E-23 -> 1.123456789987654321123456789012345E-23 +dqadd371444 fma 1 0 1.123456789987654321123456789012345E-24 -> 1.123456789987654321123456789012345E-24 +dqadd371445 fma 1 0 1.123456789987654321123456789012345E-25 -> 1.123456789987654321123456789012345E-25 +dqadd371446 fma 1 0 1.123456789987654321123456789012345E-26 -> 1.123456789987654321123456789012345E-26 +dqadd371447 fma 1 0 1.123456789987654321123456789012345E-27 -> 1.123456789987654321123456789012345E-27 +dqadd371448 fma 1 0 1.123456789987654321123456789012345E-28 -> 1.123456789987654321123456789012345E-28 +dqadd371449 fma 1 0 1.123456789987654321123456789012345E-29 -> 1.123456789987654321123456789012345E-29 +dqadd371450 fma 1 0 1.123456789987654321123456789012345E-30 -> 1.123456789987654321123456789012345E-30 +dqadd371451 fma 1 0 1.123456789987654321123456789012345E-31 -> 1.123456789987654321123456789012345E-31 +dqadd371452 fma 1 0 1.123456789987654321123456789012345E-32 -> 1.123456789987654321123456789012345E-32 +dqadd371453 fma 1 0 1.123456789987654321123456789012345E-33 -> 1.123456789987654321123456789012345E-33 +dqadd371454 fma 1 0 1.123456789987654321123456789012345E-34 -> 1.123456789987654321123456789012345E-34 +dqadd371455 fma 1 0 1.123456789987654321123456789012345E-35 -> 1.123456789987654321123456789012345E-35 +dqadd371456 fma 1 0 1.123456789987654321123456789012345E-36 -> 1.123456789987654321123456789012345E-36 + +-- same, reversed 0 +dqadd371460 fma 1 1.123456789987654321123456789012345 0 -> 1.123456789987654321123456789012345 +dqadd371461 fma 1 1.123456789987654321123456789012345E-1 0 -> 0.1123456789987654321123456789012345 +dqadd371462 fma 1 1.123456789987654321123456789012345E-2 0 -> 0.01123456789987654321123456789012345 +dqadd371463 fma 1 1.123456789987654321123456789012345E-3 0 -> 0.001123456789987654321123456789012345 +dqadd371464 fma 1 1.123456789987654321123456789012345E-4 0 -> 0.0001123456789987654321123456789012345 +dqadd371465 fma 1 1.123456789987654321123456789012345E-5 0 -> 0.00001123456789987654321123456789012345 +dqadd371466 fma 1 1.123456789987654321123456789012345E-6 0 -> 0.000001123456789987654321123456789012345 +dqadd371467 fma 1 1.123456789987654321123456789012345E-7 0 -> 1.123456789987654321123456789012345E-7 +dqadd371468 fma 1 1.123456789987654321123456789012345E-8 0 -> 1.123456789987654321123456789012345E-8 +dqadd371469 fma 1 1.123456789987654321123456789012345E-9 0 -> 1.123456789987654321123456789012345E-9 +dqadd371470 fma 1 1.123456789987654321123456789012345E-10 0 -> 1.123456789987654321123456789012345E-10 +dqadd371471 fma 1 1.123456789987654321123456789012345E-11 0 -> 1.123456789987654321123456789012345E-11 +dqadd371472 fma 1 1.123456789987654321123456789012345E-12 0 -> 1.123456789987654321123456789012345E-12 +dqadd371473 fma 1 1.123456789987654321123456789012345E-13 0 -> 1.123456789987654321123456789012345E-13 +dqadd371474 fma 1 1.123456789987654321123456789012345E-14 0 -> 1.123456789987654321123456789012345E-14 +dqadd371475 fma 1 1.123456789987654321123456789012345E-15 0 -> 1.123456789987654321123456789012345E-15 +dqadd371476 fma 1 1.123456789987654321123456789012345E-16 0 -> 1.123456789987654321123456789012345E-16 +dqadd371477 fma 1 1.123456789987654321123456789012345E-17 0 -> 1.123456789987654321123456789012345E-17 +dqadd371478 fma 1 1.123456789987654321123456789012345E-18 0 -> 1.123456789987654321123456789012345E-18 +dqadd371479 fma 1 1.123456789987654321123456789012345E-19 0 -> 1.123456789987654321123456789012345E-19 +dqadd371480 fma 1 1.123456789987654321123456789012345E-20 0 -> 1.123456789987654321123456789012345E-20 +dqadd371481 fma 1 1.123456789987654321123456789012345E-21 0 -> 1.123456789987654321123456789012345E-21 +dqadd371482 fma 1 1.123456789987654321123456789012345E-22 0 -> 1.123456789987654321123456789012345E-22 +dqadd371483 fma 1 1.123456789987654321123456789012345E-23 0 -> 1.123456789987654321123456789012345E-23 +dqadd371484 fma 1 1.123456789987654321123456789012345E-24 0 -> 1.123456789987654321123456789012345E-24 +dqadd371485 fma 1 1.123456789987654321123456789012345E-25 0 -> 1.123456789987654321123456789012345E-25 +dqadd371486 fma 1 1.123456789987654321123456789012345E-26 0 -> 1.123456789987654321123456789012345E-26 +dqadd371487 fma 1 1.123456789987654321123456789012345E-27 0 -> 1.123456789987654321123456789012345E-27 +dqadd371488 fma 1 1.123456789987654321123456789012345E-28 0 -> 1.123456789987654321123456789012345E-28 +dqadd371489 fma 1 1.123456789987654321123456789012345E-29 0 -> 1.123456789987654321123456789012345E-29 +dqadd371490 fma 1 1.123456789987654321123456789012345E-30 0 -> 1.123456789987654321123456789012345E-30 +dqadd371491 fma 1 1.123456789987654321123456789012345E-31 0 -> 1.123456789987654321123456789012345E-31 +dqadd371492 fma 1 1.123456789987654321123456789012345E-32 0 -> 1.123456789987654321123456789012345E-32 +dqadd371493 fma 1 1.123456789987654321123456789012345E-33 0 -> 1.123456789987654321123456789012345E-33 +dqadd371494 fma 1 1.123456789987654321123456789012345E-34 0 -> 1.123456789987654321123456789012345E-34 +dqadd371495 fma 1 1.123456789987654321123456789012345E-35 0 -> 1.123456789987654321123456789012345E-35 +dqadd371496 fma 1 1.123456789987654321123456789012345E-36 0 -> 1.123456789987654321123456789012345E-36 + +-- same, Es on the 0 +dqadd371500 fma 1 1.123456789987654321123456789012345 0E-0 -> 1.123456789987654321123456789012345 +dqadd371501 fma 1 1.123456789987654321123456789012345 0E-1 -> 1.123456789987654321123456789012345 +dqadd371502 fma 1 1.123456789987654321123456789012345 0E-2 -> 1.123456789987654321123456789012345 +dqadd371503 fma 1 1.123456789987654321123456789012345 0E-3 -> 1.123456789987654321123456789012345 +dqadd371504 fma 1 1.123456789987654321123456789012345 0E-4 -> 1.123456789987654321123456789012345 +dqadd371505 fma 1 1.123456789987654321123456789012345 0E-5 -> 1.123456789987654321123456789012345 +dqadd371506 fma 1 1.123456789987654321123456789012345 0E-6 -> 1.123456789987654321123456789012345 +dqadd371507 fma 1 1.123456789987654321123456789012345 0E-7 -> 1.123456789987654321123456789012345 +dqadd371508 fma 1 1.123456789987654321123456789012345 0E-8 -> 1.123456789987654321123456789012345 +dqadd371509 fma 1 1.123456789987654321123456789012345 0E-9 -> 1.123456789987654321123456789012345 +dqadd371510 fma 1 1.123456789987654321123456789012345 0E-10 -> 1.123456789987654321123456789012345 +dqadd371511 fma 1 1.123456789987654321123456789012345 0E-11 -> 1.123456789987654321123456789012345 +dqadd371512 fma 1 1.123456789987654321123456789012345 0E-12 -> 1.123456789987654321123456789012345 +dqadd371513 fma 1 1.123456789987654321123456789012345 0E-13 -> 1.123456789987654321123456789012345 +dqadd371514 fma 1 1.123456789987654321123456789012345 0E-14 -> 1.123456789987654321123456789012345 +dqadd371515 fma 1 1.123456789987654321123456789012345 0E-15 -> 1.123456789987654321123456789012345 +dqadd371516 fma 1 1.123456789987654321123456789012345 0E-16 -> 1.123456789987654321123456789012345 +dqadd371517 fma 1 1.123456789987654321123456789012345 0E-17 -> 1.123456789987654321123456789012345 +dqadd371518 fma 1 1.123456789987654321123456789012345 0E-18 -> 1.123456789987654321123456789012345 +dqadd371519 fma 1 1.123456789987654321123456789012345 0E-19 -> 1.123456789987654321123456789012345 +dqadd371520 fma 1 1.123456789987654321123456789012345 0E-20 -> 1.123456789987654321123456789012345 +dqadd371521 fma 1 1.123456789987654321123456789012345 0E-21 -> 1.123456789987654321123456789012345 +dqadd371522 fma 1 1.123456789987654321123456789012345 0E-22 -> 1.123456789987654321123456789012345 +dqadd371523 fma 1 1.123456789987654321123456789012345 0E-23 -> 1.123456789987654321123456789012345 +dqadd371524 fma 1 1.123456789987654321123456789012345 0E-24 -> 1.123456789987654321123456789012345 +dqadd371525 fma 1 1.123456789987654321123456789012345 0E-25 -> 1.123456789987654321123456789012345 +dqadd371526 fma 1 1.123456789987654321123456789012345 0E-26 -> 1.123456789987654321123456789012345 +dqadd371527 fma 1 1.123456789987654321123456789012345 0E-27 -> 1.123456789987654321123456789012345 +dqadd371528 fma 1 1.123456789987654321123456789012345 0E-28 -> 1.123456789987654321123456789012345 +dqadd371529 fma 1 1.123456789987654321123456789012345 0E-29 -> 1.123456789987654321123456789012345 +dqadd371530 fma 1 1.123456789987654321123456789012345 0E-30 -> 1.123456789987654321123456789012345 +dqadd371531 fma 1 1.123456789987654321123456789012345 0E-31 -> 1.123456789987654321123456789012345 +dqadd371532 fma 1 1.123456789987654321123456789012345 0E-32 -> 1.123456789987654321123456789012345 +dqadd371533 fma 1 1.123456789987654321123456789012345 0E-33 -> 1.123456789987654321123456789012345 +-- next four flag Rounded because the 0 extends the result +dqadd371534 fma 1 1.123456789987654321123456789012345 0E-34 -> 1.123456789987654321123456789012345 Rounded +dqadd371535 fma 1 1.123456789987654321123456789012345 0E-35 -> 1.123456789987654321123456789012345 Rounded +dqadd371536 fma 1 1.123456789987654321123456789012345 0E-36 -> 1.123456789987654321123456789012345 Rounded +dqadd371537 fma 1 1.123456789987654321123456789012345 0E-37 -> 1.123456789987654321123456789012345 Rounded + +-- sum of two opposite-sign operands is exactly 0 and floor => -0 +rounding: half_up +-- exact zeros from zeros +dqadd371600 fma 1 0 0E-19 -> 0E-19 +dqadd371601 fma 1 -0 0E-19 -> 0E-19 +dqadd371602 fma 1 0 -0E-19 -> 0E-19 +dqadd371603 fma 1 -0 -0E-19 -> -0E-19 +-- exact zeros from non-zeros +dqadd371611 fma 1 -11 11 -> 0 +dqadd371612 fma 1 11 -11 -> 0 +-- overflow +dqadd371613 fma 9E6144 10 1 -> Infinity Overflow Inexact Rounded +dqadd371614 fma -9E6144 10 1 -> -Infinity Overflow Inexact Rounded + +rounding: half_down +-- exact zeros from zeros +dqadd371620 fma 1 0 0E-19 -> 0E-19 +dqadd371621 fma 1 -0 0E-19 -> 0E-19 +dqadd371622 fma 1 0 -0E-19 -> 0E-19 +dqadd371623 fma 1 -0 -0E-19 -> -0E-19 +-- exact zeros from non-zeros +dqadd371631 fma 1 -11 11 -> 0 +dqadd371632 fma 1 11 -11 -> 0 +-- overflow +dqadd371633 fma 9E6144 10 1 -> Infinity Overflow Inexact Rounded +dqadd371634 fma -9E6144 10 1 -> -Infinity Overflow Inexact Rounded + +rounding: half_even +-- exact zeros from zeros +dqadd371640 fma 1 0 0E-19 -> 0E-19 +dqadd371641 fma 1 -0 0E-19 -> 0E-19 +dqadd371642 fma 1 0 -0E-19 -> 0E-19 +dqadd371643 fma 1 -0 -0E-19 -> -0E-19 +-- exact zeros from non-zeros +dqadd371651 fma 1 -11 11 -> 0 +dqadd371652 fma 1 11 -11 -> 0 +-- overflow +dqadd371653 fma 9E6144 10 1 -> Infinity Overflow Inexact Rounded +dqadd371654 fma -9E6144 10 1 -> -Infinity Overflow Inexact Rounded + +rounding: up +-- exact zeros from zeros +dqadd371660 fma 1 0 0E-19 -> 0E-19 +dqadd371661 fma 1 -0 0E-19 -> 0E-19 +dqadd371662 fma 1 0 -0E-19 -> 0E-19 +dqadd371663 fma 1 -0 -0E-19 -> -0E-19 +-- exact zeros from non-zeros +dqadd371671 fma 1 -11 11 -> 0 +dqadd371672 fma 1 11 -11 -> 0 +-- overflow +dqadd371673 fma 9E6144 10 1 -> Infinity Overflow Inexact Rounded +dqadd371674 fma -9E6144 10 1 -> -Infinity Overflow Inexact Rounded + +rounding: down +-- exact zeros from zeros +dqadd371680 fma 1 0 0E-19 -> 0E-19 +dqadd371681 fma 1 -0 0E-19 -> 0E-19 +dqadd371682 fma 1 0 -0E-19 -> 0E-19 +dqadd371683 fma 1 -0 -0E-19 -> -0E-19 +-- exact zeros from non-zeros +dqadd371691 fma 1 -11 11 -> 0 +dqadd371692 fma 1 11 -11 -> 0 +-- overflow +dqadd371693 fma 9E6144 10 1 -> 9.999999999999999999999999999999999E+6144 Overflow Inexact Rounded +dqadd371694 fma -9E6144 10 1 -> -9.999999999999999999999999999999999E+6144 Overflow Inexact Rounded + +rounding: ceiling +-- exact zeros from zeros +dqadd371700 fma 1 0 0E-19 -> 0E-19 +dqadd371701 fma 1 -0 0E-19 -> 0E-19 +dqadd371702 fma 1 0 -0E-19 -> 0E-19 +dqadd371703 fma 1 -0 -0E-19 -> -0E-19 +-- exact zeros from non-zeros +dqadd371711 fma 1 -11 11 -> 0 +dqadd371712 fma 1 11 -11 -> 0 +-- overflow +dqadd371713 fma 9E6144 10 1 -> Infinity Overflow Inexact Rounded +dqadd371714 fma -9E6144 10 1 -> -9.999999999999999999999999999999999E+6144 Overflow Inexact Rounded + +-- and the extra-special ugly case; unusual minuses marked by -- * +rounding: floor +-- exact zeros from zeros +dqadd371720 fma 1 0 0E-19 -> 0E-19 +dqadd371721 fma 1 -0 0E-19 -> -0E-19 -- * +dqadd371722 fma 1 0 -0E-19 -> -0E-19 -- * +dqadd371723 fma 1 -0 -0E-19 -> -0E-19 +-- exact zeros from non-zeros +dqadd371731 fma 1 -11 11 -> -0 -- * +dqadd371732 fma 1 11 -11 -> -0 -- * +-- overflow +dqadd371733 fma 9E6144 10 1 -> 9.999999999999999999999999999999999E+6144 Overflow Inexact Rounded +dqadd371734 fma -9E6144 10 1 -> -Infinity Overflow Inexact Rounded + +rounding: 05up +-- exact zeros from zeros +dqadd371740 fma 1 0 0E-19 -> 0E-19 +dqadd371741 fma 1 -0 0E-19 -> 0E-19 +dqadd371742 fma 1 0 -0E-19 -> 0E-19 +dqadd371743 fma 1 -0 -0E-19 -> -0E-19 +-- exact zeros from non-zeros +dqadd371751 fma 1 -11 11 -> 0 +dqadd371752 fma 1 11 -11 -> 0 +-- overflow +dqadd371753 fma 9E6144 10 1 -> 9.999999999999999999999999999999999E+6144 Overflow Inexact Rounded +dqadd371754 fma -9E6144 10 1 -> -9.999999999999999999999999999999999E+6144 Overflow Inexact Rounded + +-- Examples from SQL proposal (Krishna Kulkarni) +dqadd371761 fma 1 130E-2 120E-2 -> 2.50 +dqadd371762 fma 1 130E-2 12E-1 -> 2.50 +dqadd371763 fma 1 130E-2 1E0 -> 2.30 +dqadd371764 fma 1 1E2 1E4 -> 1.01E+4 +dqadd371765 fma 1 130E-2 -120E-2 -> 0.10 +dqadd371766 fma 1 130E-2 -12E-1 -> 0.10 +dqadd371767 fma 1 130E-2 -1E0 -> 0.30 +dqadd371768 fma 1 1E2 -1E4 -> -9.9E+3 + +-- Gappy coefficients; check residue handling even with full coefficient gap +rounding: half_even + +dqadd375001 fma 1 1239876543211234567894567890123456 1 -> 1239876543211234567894567890123457 +dqadd375002 fma 1 1239876543211234567894567890123456 0.6 -> 1239876543211234567894567890123457 Inexact Rounded +dqadd375003 fma 1 1239876543211234567894567890123456 0.06 -> 1239876543211234567894567890123456 Inexact Rounded +dqadd375004 fma 1 1239876543211234567894567890123456 6E-3 -> 1239876543211234567894567890123456 Inexact Rounded +dqadd375005 fma 1 1239876543211234567894567890123456 6E-4 -> 1239876543211234567894567890123456 Inexact Rounded +dqadd375006 fma 1 1239876543211234567894567890123456 6E-5 -> 1239876543211234567894567890123456 Inexact Rounded +dqadd375007 fma 1 1239876543211234567894567890123456 6E-6 -> 1239876543211234567894567890123456 Inexact Rounded +dqadd375008 fma 1 1239876543211234567894567890123456 6E-7 -> 1239876543211234567894567890123456 Inexact Rounded +dqadd375009 fma 1 1239876543211234567894567890123456 6E-8 -> 1239876543211234567894567890123456 Inexact Rounded +dqadd375010 fma 1 1239876543211234567894567890123456 6E-9 -> 1239876543211234567894567890123456 Inexact Rounded +dqadd375011 fma 1 1239876543211234567894567890123456 6E-10 -> 1239876543211234567894567890123456 Inexact Rounded +dqadd375012 fma 1 1239876543211234567894567890123456 6E-11 -> 1239876543211234567894567890123456 Inexact Rounded +dqadd375013 fma 1 1239876543211234567894567890123456 6E-12 -> 1239876543211234567894567890123456 Inexact Rounded +dqadd375014 fma 1 1239876543211234567894567890123456 6E-13 -> 1239876543211234567894567890123456 Inexact Rounded +dqadd375015 fma 1 1239876543211234567894567890123456 6E-14 -> 1239876543211234567894567890123456 Inexact Rounded +dqadd375016 fma 1 1239876543211234567894567890123456 6E-15 -> 1239876543211234567894567890123456 Inexact Rounded +dqadd375017 fma 1 1239876543211234567894567890123456 6E-16 -> 1239876543211234567894567890123456 Inexact Rounded +dqadd375018 fma 1 1239876543211234567894567890123456 6E-17 -> 1239876543211234567894567890123456 Inexact Rounded +dqadd375019 fma 1 1239876543211234567894567890123456 6E-18 -> 1239876543211234567894567890123456 Inexact Rounded +dqadd375020 fma 1 1239876543211234567894567890123456 6E-19 -> 1239876543211234567894567890123456 Inexact Rounded +dqadd375021 fma 1 1239876543211234567894567890123456 6E-20 -> 1239876543211234567894567890123456 Inexact Rounded + +-- widening second argument at gap +dqadd375030 fma 1 12398765432112345678945678 1 -> 12398765432112345678945679 +dqadd375031 fma 1 12398765432112345678945678 0.1 -> 12398765432112345678945678.1 +dqadd375032 fma 1 12398765432112345678945678 0.12 -> 12398765432112345678945678.12 +dqadd375033 fma 1 12398765432112345678945678 0.123 -> 12398765432112345678945678.123 +dqadd375034 fma 1 12398765432112345678945678 0.1234 -> 12398765432112345678945678.1234 +dqadd375035 fma 1 12398765432112345678945678 0.12345 -> 12398765432112345678945678.12345 +dqadd375036 fma 1 12398765432112345678945678 0.123456 -> 12398765432112345678945678.123456 +dqadd375037 fma 1 12398765432112345678945678 0.1234567 -> 12398765432112345678945678.1234567 +dqadd375038 fma 1 12398765432112345678945678 0.12345678 -> 12398765432112345678945678.12345678 +dqadd375039 fma 1 12398765432112345678945678 0.123456789 -> 12398765432112345678945678.12345679 Inexact Rounded +dqadd375040 fma 1 12398765432112345678945678 0.123456785 -> 12398765432112345678945678.12345678 Inexact Rounded +dqadd375041 fma 1 12398765432112345678945678 0.1234567850 -> 12398765432112345678945678.12345678 Inexact Rounded +dqadd375042 fma 1 12398765432112345678945678 0.1234567851 -> 12398765432112345678945678.12345679 Inexact Rounded +dqadd375043 fma 1 12398765432112345678945678 0.12345678501 -> 12398765432112345678945678.12345679 Inexact Rounded +dqadd375044 fma 1 12398765432112345678945678 0.123456785001 -> 12398765432112345678945678.12345679 Inexact Rounded +dqadd375045 fma 1 12398765432112345678945678 0.1234567850001 -> 12398765432112345678945678.12345679 Inexact Rounded +dqadd375046 fma 1 12398765432112345678945678 0.12345678500001 -> 12398765432112345678945678.12345679 Inexact Rounded +dqadd375047 fma 1 12398765432112345678945678 0.123456785000001 -> 12398765432112345678945678.12345679 Inexact Rounded +dqadd375048 fma 1 12398765432112345678945678 0.1234567850000001 -> 12398765432112345678945678.12345679 Inexact Rounded +dqadd375049 fma 1 12398765432112345678945678 0.1234567850000000 -> 12398765432112345678945678.12345678 Inexact Rounded +-- 90123456 +rounding: half_even +dqadd375050 fma 1 12398765432112345678945678 0.0234567750000000 -> 12398765432112345678945678.02345678 Inexact Rounded +dqadd375051 fma 1 12398765432112345678945678 0.0034567750000000 -> 12398765432112345678945678.00345678 Inexact Rounded +dqadd375052 fma 1 12398765432112345678945678 0.0004567750000000 -> 12398765432112345678945678.00045678 Inexact Rounded +dqadd375053 fma 1 12398765432112345678945678 0.0000567750000000 -> 12398765432112345678945678.00005678 Inexact Rounded +dqadd375054 fma 1 12398765432112345678945678 0.0000067750000000 -> 12398765432112345678945678.00000678 Inexact Rounded +dqadd375055 fma 1 12398765432112345678945678 0.0000007750000000 -> 12398765432112345678945678.00000078 Inexact Rounded +dqadd375056 fma 1 12398765432112345678945678 0.0000000750000000 -> 12398765432112345678945678.00000008 Inexact Rounded +dqadd375057 fma 1 12398765432112345678945678 0.0000000050000000 -> 12398765432112345678945678.00000000 Inexact Rounded +dqadd375060 fma 1 12398765432112345678945678 0.0234567750000001 -> 12398765432112345678945678.02345678 Inexact Rounded +dqadd375061 fma 1 12398765432112345678945678 0.0034567750000001 -> 12398765432112345678945678.00345678 Inexact Rounded +dqadd375062 fma 1 12398765432112345678945678 0.0004567750000001 -> 12398765432112345678945678.00045678 Inexact Rounded +dqadd375063 fma 1 12398765432112345678945678 0.0000567750000001 -> 12398765432112345678945678.00005678 Inexact Rounded +dqadd375064 fma 1 12398765432112345678945678 0.0000067750000001 -> 12398765432112345678945678.00000678 Inexact Rounded +dqadd375065 fma 1 12398765432112345678945678 0.0000007750000001 -> 12398765432112345678945678.00000078 Inexact Rounded +dqadd375066 fma 1 12398765432112345678945678 0.0000000750000001 -> 12398765432112345678945678.00000008 Inexact Rounded +dqadd375067 fma 1 12398765432112345678945678 0.0000000050000001 -> 12398765432112345678945678.00000001 Inexact Rounded +-- far-out residues (full coefficient gap is 16+15 digits) +rounding: up +dqadd375070 fma 1 12398765432112345678945678 1E-8 -> 12398765432112345678945678.00000001 +dqadd375071 fma 1 12398765432112345678945678 1E-9 -> 12398765432112345678945678.00000001 Inexact Rounded +dqadd375072 fma 1 12398765432112345678945678 1E-10 -> 12398765432112345678945678.00000001 Inexact Rounded +dqadd375073 fma 1 12398765432112345678945678 1E-11 -> 12398765432112345678945678.00000001 Inexact Rounded +dqadd375074 fma 1 12398765432112345678945678 1E-12 -> 12398765432112345678945678.00000001 Inexact Rounded +dqadd375075 fma 1 12398765432112345678945678 1E-13 -> 12398765432112345678945678.00000001 Inexact Rounded +dqadd375076 fma 1 12398765432112345678945678 1E-14 -> 12398765432112345678945678.00000001 Inexact Rounded +dqadd375077 fma 1 12398765432112345678945678 1E-15 -> 12398765432112345678945678.00000001 Inexact Rounded +dqadd375078 fma 1 12398765432112345678945678 1E-16 -> 12398765432112345678945678.00000001 Inexact Rounded +dqadd375079 fma 1 12398765432112345678945678 1E-17 -> 12398765432112345678945678.00000001 Inexact Rounded +dqadd375080 fma 1 12398765432112345678945678 1E-18 -> 12398765432112345678945678.00000001 Inexact Rounded +dqadd375081 fma 1 12398765432112345678945678 1E-19 -> 12398765432112345678945678.00000001 Inexact Rounded +dqadd375082 fma 1 12398765432112345678945678 1E-20 -> 12398765432112345678945678.00000001 Inexact Rounded +dqadd375083 fma 1 12398765432112345678945678 1E-25 -> 12398765432112345678945678.00000001 Inexact Rounded +dqadd375084 fma 1 12398765432112345678945678 1E-30 -> 12398765432112345678945678.00000001 Inexact Rounded +dqadd375085 fma 1 12398765432112345678945678 1E-31 -> 12398765432112345678945678.00000001 Inexact Rounded +dqadd375086 fma 1 12398765432112345678945678 1E-32 -> 12398765432112345678945678.00000001 Inexact Rounded +dqadd375087 fma 1 12398765432112345678945678 1E-33 -> 12398765432112345678945678.00000001 Inexact Rounded +dqadd375088 fma 1 12398765432112345678945678 1E-34 -> 12398765432112345678945678.00000001 Inexact Rounded +dqadd375089 fma 1 12398765432112345678945678 1E-35 -> 12398765432112345678945678.00000001 Inexact Rounded + +-- Destructive subtract (from remainder tests) + +-- +++ some of these will be off-by-one remainder vs remainderNear + +dqfma4000 fma -1234567890123456789012345678901233 1.000000000000000000000000000000001 1234567890123456789012345678901234 -> -0.234567890123456789012345678901233 +dqfma4001 fma -1234567890123456789012345678901222 1.00000000000000000000000000000001 1234567890123456789012345678901234 -> -0.34567890123456789012345678901222 +dqfma4002 fma -1234567890123456789012345678901111 1.0000000000000000000000000000001 1234567890123456789012345678901234 -> -0.4567890123456789012345678901111 +dqfma4003 fma -308641972530864197253086419725314 4.000000000000000000000000000000001 1234567890123456789012345678901255 -> -1.308641972530864197253086419725314 +dqfma4004 fma -308641972530864197253086419725308 4.000000000000000000000000000000001 1234567890123456789012345678901234 -> 1.691358027469135802746913580274692 +dqfma4005 fma -246913578024691357802469135780252 4.9999999999999999999999999999999 1234567890123456789012345678901234 -> -1.3086421975308642197530864219748 +dqfma4006 fma -246913578024691357802469135780247 4.99999999999999999999999999999999 1234567890123456789012345678901234 -> 1.46913578024691357802469135780247 +dqfma4007 fma -246913578024691357802469135780247 4.999999999999999999999999999999999 1234567890123456789012345678901234 -> -0.753086421975308642197530864219753 +dqfma4008 fma -246913578024691357802469135780247 5.000000000000000000000000000000001 1234567890123456789012345678901234 -> -1.246913578024691357802469135780247 +dqfma4009 fma -246913578024691357802469135780246 5.00000000000000000000000000000001 1234567890123456789012345678901234 -> 1.53086421975308642197530864219754 +dqfma4010 fma -246913578024691357802469135780242 5.0000000000000000000000000000001 1234567890123456789012345678901234 -> -0.6913578024691357802469135780242 +dqfma4011 fma -1234567890123456789012345678901232 1.000000000000000000000000000000001 1234567890123456789012345678901234 -> 0.765432109876543210987654321098768 +dqfma4012 fma -1234567890123456789012345678901221 1.00000000000000000000000000000001 1234567890123456789012345678901234 -> 0.65432109876543210987654321098779 +dqfma4013 fma -1234567890123456789012345678901110 1.0000000000000000000000000000001 1234567890123456789012345678901234 -> 0.5432109876543210987654321098890 +dqfma4014 fma -308641972530864197253086419725313 4.000000000000000000000000000000001 1234567890123456789012345678901255 -> 2.691358027469135802746913580274687 +dqfma4015 fma -308641972530864197253086419725308 4.000000000000000000000000000000001 1234567890123456789012345678901234 -> 1.691358027469135802746913580274692 +dqfma4016 fma -246913578024691357802469135780251 4.9999999999999999999999999999999 1234567890123456789012345678901234 -> 3.6913578024691357802469135780251 +dqfma4017 fma -246913578024691357802469135780247 4.99999999999999999999999999999999 1234567890123456789012345678901234 -> 1.46913578024691357802469135780247 +dqfma4018 fma -246913578024691357802469135780246 4.999999999999999999999999999999999 1234567890123456789012345678901234 -> 4.246913578024691357802469135780246 +dqfma4019 fma -246913578024691357802469135780241 5.0000000000000000000000000000001 1234567890123456789012345678901234 -> 4.3086421975308642197530864219759 + +-- Null tests +dqadd39990 fma 1 10 # -> NaN Invalid_operation +dqadd39991 fma 1 # 10 -> NaN Invalid_operation + + Added: python/branches/release25-maint/Lib/test/decimaltestdata/dqInvert.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/dqInvert.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,245 @@ +------------------------------------------------------------------------ +-- dqInvert.decTest -- digitwise logical INVERT for decQuads -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +extended: 1 +clamp: 1 +precision: 34 +maxExponent: 6144 +minExponent: -6143 +rounding: half_even + +-- Sanity check (truth table) +dqinv001 invert 0 -> 1111111111111111111111111111111111 +dqinv002 invert 1 -> 1111111111111111111111111111111110 +dqinv003 invert 10 -> 1111111111111111111111111111111101 +dqinv004 invert 111111111 -> 1111111111111111111111111000000000 +dqinv005 invert 000000000 -> 1111111111111111111111111111111111 +-- and at msd and msd-1 +dqinv007 invert 0000000000000000000000000000000000 -> 1111111111111111111111111111111111 +dqinv008 invert 1000000000000000000000000000000000 -> 111111111111111111111111111111111 +dqinv009 invert 0000000000000000000000000000000000 -> 1111111111111111111111111111111111 +dqinv010 invert 0100000000000000000000000000000000 -> 1011111111111111111111111111111111 +dqinv011 invert 0111111111111111111111111111111111 -> 1000000000000000000000000000000000 +dqinv012 invert 1111111111111111111111111111111111 -> 0 +dqinv013 invert 0011111111111111111111111111111111 -> 1100000000000000000000000000000000 +dqinv014 invert 0111111111111111111111111111111111 -> 1000000000000000000000000000000000 + +-- Various lengths +dqinv600 invert 0111111111111111111011111111111111 -> 1000000000000000000100000000000000 +dqinv601 invert 0011111111111111110101111111111111 -> 1100000000000000001010000000000000 +dqinv602 invert 0101111111111111101110111111111111 -> 1010000000000000010001000000000000 +dqinv603 invert 0110111111111111011111011111111111 -> 1001000000000000100000100000000000 +dqinv604 invert 0111011111111110111111101111111111 -> 1000100000000001000000010000000000 +dqinv605 invert 0111101111111101111111110111111111 -> 1000010000000010000000001000000000 +dqinv606 invert 0111110111111011111111111011111111 -> 1000001000000100000000000100000000 +dqinv607 invert 0111111011110111111111111101111111 -> 1000000100001000000000000010000000 +dqinv608 invert 0111111101101111111111111110111111 -> 1000000010010000000000000001000000 +dqinv609 invert 0111111110011111111111111111011111 -> 1000000001100000000000000000100000 +dqinv610 invert 0111111110011111111111111111101111 -> 1000000001100000000000000000010000 +dqinv611 invert 0111111101101111111111111111110111 -> 1000000010010000000000000000001000 +dqinv612 invert 0111111011110111111111111111111011 -> 1000000100001000000000000000000100 +dqinv613 invert 0111110111111011111111111111111101 -> 1000001000000100000000000000000010 +dqinv614 invert 0111101111111101111111111111111110 -> 1000010000000010000000000000000001 +dqinv615 invert 0111011111111110111111111111111111 -> 1000100000000001000000000000000000 +dqinv616 invert 0110111111111111011111111111111110 -> 1001000000000000100000000000000001 +dqinv617 invert 0101111111111111101111111111111101 -> 1010000000000000010000000000000010 +dqinv618 invert 0011111111111111110111111111111011 -> 1100000000000000001000000000000100 +dqinv619 invert 0101111111111111111011111111110111 -> 1010000000000000000100000000001000 +dqinv620 invert 0110111111111111111101111111101111 -> 1001000000000000000010000000010000 +dqinv621 invert 0111011111111111111110111111011111 -> 1000100000000000000001000000100000 +dqinv622 invert 0111101111111111111111011110111111 -> 1000010000000000000000100001000000 +dqinv623 invert 0111110111111111111111101101111111 -> 1000001000000000000000010010000000 +dqinv624 invert 0111111011111111111111110011111111 -> 1000000100000000000000001100000000 +dqinv625 invert 0111111101111111111111110011111111 -> 1000000010000000000000001100000000 +dqinv626 invert 0111111110111111111111101101111111 -> 1000000001000000000000010010000000 +dqinv627 invert 0111111111011111111111011110111111 -> 1000000000100000000000100001000000 +dqinv628 invert 0111111111101111111110111111011111 -> 1000000000010000000001000000100000 +dqinv629 invert 0111111111110111111101111111101111 -> 1000000000001000000010000000010000 +dqinv630 invert 0111111111111011111011111111110111 -> 1000000000000100000100000000001000 +dqinv631 invert 0111111111111101110111111111111011 -> 1000000000000010001000000000000100 +dqinv632 invert 0111111111111110101111111111111101 -> 1000000000000001010000000000000010 +dqinv633 invert 0111111111111111011111111111111110 -> 1000000000000000100000000000000001 + +dqinv021 invert 111111111 -> 1111111111111111111111111000000000 +dqinv022 invert 111111111111 -> 1111111111111111111111000000000000 +dqinv023 invert 11111111 -> 1111111111111111111111111100000000 +dqinv025 invert 1111111 -> 1111111111111111111111111110000000 +dqinv026 invert 111111 -> 1111111111111111111111111111000000 +dqinv027 invert 11111 -> 1111111111111111111111111111100000 +dqinv028 invert 1111 -> 1111111111111111111111111111110000 +dqinv029 invert 111 -> 1111111111111111111111111111111000 +dqinv031 invert 11 -> 1111111111111111111111111111111100 +dqinv032 invert 1 -> 1111111111111111111111111111111110 +dqinv033 invert 111111111111 -> 1111111111111111111111000000000000 +dqinv034 invert 11111111111 -> 1111111111111111111111100000000000 +dqinv035 invert 1111111111 -> 1111111111111111111111110000000000 +dqinv036 invert 111111111 -> 1111111111111111111111111000000000 + +dqinv040 invert 011111111 -> 1111111111111111111111111100000000 +dqinv041 invert 101111111 -> 1111111111111111111111111010000000 +dqinv042 invert 110111111 -> 1111111111111111111111111001000000 +dqinv043 invert 111011111 -> 1111111111111111111111111000100000 +dqinv044 invert 111101111 -> 1111111111111111111111111000010000 +dqinv045 invert 111110111 -> 1111111111111111111111111000001000 +dqinv046 invert 111111011 -> 1111111111111111111111111000000100 +dqinv047 invert 111111101 -> 1111111111111111111111111000000010 +dqinv048 invert 111111110 -> 1111111111111111111111111000000001 +dqinv049 invert 011111011 -> 1111111111111111111111111100000100 +dqinv050 invert 101111101 -> 1111111111111111111111111010000010 +dqinv051 invert 110111110 -> 1111111111111111111111111001000001 +dqinv052 invert 111011101 -> 1111111111111111111111111000100010 +dqinv053 invert 111101011 -> 1111111111111111111111111000010100 +dqinv054 invert 111110111 -> 1111111111111111111111111000001000 +dqinv055 invert 111101011 -> 1111111111111111111111111000010100 +dqinv056 invert 111011101 -> 1111111111111111111111111000100010 +dqinv057 invert 110111110 -> 1111111111111111111111111001000001 +dqinv058 invert 101111101 -> 1111111111111111111111111010000010 +dqinv059 invert 011111011 -> 1111111111111111111111111100000100 + +dqinv080 invert 1000000011111111 -> 1111111111111111110111111100000000 +dqinv081 invert 0100000101111111 -> 1111111111111111111011111010000000 +dqinv082 invert 0010000110111111 -> 1111111111111111111101111001000000 +dqinv083 invert 0001000111011111 -> 1111111111111111111110111000100000 +dqinv084 invert 0000100111101111 -> 1111111111111111111111011000010000 +dqinv085 invert 0000010111110111 -> 1111111111111111111111101000001000 +dqinv086 invert 0000001111111011 -> 1111111111111111111111110000000100 +dqinv087 invert 0000010111111101 -> 1111111111111111111111101000000010 +dqinv088 invert 0000100111111110 -> 1111111111111111111111011000000001 +dqinv089 invert 0001000011111011 -> 1111111111111111111110111100000100 +dqinv090 invert 0010000101111101 -> 1111111111111111111101111010000010 +dqinv091 invert 0100000110111110 -> 1111111111111111111011111001000001 +dqinv092 invert 1000000111011101 -> 1111111111111111110111111000100010 +dqinv093 invert 0100000111101011 -> 1111111111111111111011111000010100 +dqinv094 invert 0010000111110111 -> 1111111111111111111101111000001000 +dqinv095 invert 0001000111101011 -> 1111111111111111111110111000010100 +dqinv096 invert 0000100111011101 -> 1111111111111111111111011000100010 +dqinv097 invert 0000010110111110 -> 1111111111111111111111101001000001 +dqinv098 invert 0000001101111101 -> 1111111111111111111111110010000010 +dqinv099 invert 0000010011111011 -> 1111111111111111111111101100000100 + +-- and more thorough MSD/LSD tests [8 and 9 mght be encoded differently...] +dqinv151 invert 1111111111111111111111111111111110 -> 1 +dqinv152 invert 1111111111111111110000000000000000 -> 1111111111111111 +dqinv153 invert 1000000000000000001111111111111111 -> 111111111111111110000000000000000 +dqinv154 invert 1111111111111111111000000000000000 -> 111111111111111 +dqinv155 invert 0100000000000000000111111111111111 -> 1011111111111111111000000000000000 +dqinv156 invert 1011111111111111110100000000000000 -> 100000000000000001011111111111111 +dqinv157 invert 1101111111111111110111111111111111 -> 10000000000000001000000000000000 +dqinv158 invert 1110111111111111110011111111111111 -> 1000000000000001100000000000000 + +-- non-0/1 should not be accepted, nor should signs +dqinv220 invert 111111112 -> NaN Invalid_operation +dqinv221 invert 333333333 -> NaN Invalid_operation +dqinv222 invert 555555555 -> NaN Invalid_operation +dqinv223 invert 777777777 -> NaN Invalid_operation +dqinv224 invert 999999999 -> NaN Invalid_operation +dqinv225 invert 222222222 -> NaN Invalid_operation +dqinv226 invert 444444444 -> NaN Invalid_operation +dqinv227 invert 666666666 -> NaN Invalid_operation +dqinv228 invert 888888888 -> NaN Invalid_operation +dqinv229 invert 999999999 -> NaN Invalid_operation +dqinv230 invert 999999999 -> NaN Invalid_operation +dqinv231 invert 999999999 -> NaN Invalid_operation +dqinv232 invert 999999999 -> NaN Invalid_operation +-- a few randoms +dqinv240 invert 567468689 -> NaN Invalid_operation +dqinv241 invert 567367689 -> NaN Invalid_operation +dqinv242 invert -631917772 -> NaN Invalid_operation +dqinv243 invert -756253257 -> NaN Invalid_operation +dqinv244 invert 835590149 -> NaN Invalid_operation +-- test MSD +dqinv250 invert 2000000111000111000111000000000000 -> NaN Invalid_operation +dqinv251 invert 3000000111000111000111000000000000 -> NaN Invalid_operation +dqinv252 invert 4000000111000111000111000000000000 -> NaN Invalid_operation +dqinv253 invert 5000000111000111000111000000000000 -> NaN Invalid_operation +dqinv254 invert 6000000111000111000111000000000000 -> NaN Invalid_operation +dqinv255 invert 7000000111000111000111000000000000 -> NaN Invalid_operation +dqinv256 invert 8000000111000111000111000000000000 -> NaN Invalid_operation +dqinv257 invert 9000000111000111000111000000000000 -> NaN Invalid_operation +-- test MSD-1 +dqinv270 invert 0200000111000111000111001000000000 -> NaN Invalid_operation +dqinv271 invert 0300000111000111000111000100000000 -> NaN Invalid_operation +dqinv272 invert 0400000111000111000111000010000000 -> NaN Invalid_operation +dqinv273 invert 0500000111000111000111000001000000 -> NaN Invalid_operation +dqinv274 invert 1600000111000111000111000000100000 -> NaN Invalid_operation +dqinv275 invert 1700000111000111000111000000010000 -> NaN Invalid_operation +dqinv276 invert 1800000111000111000111000000001000 -> NaN Invalid_operation +dqinv277 invert 1900000111000111000111000000000100 -> NaN Invalid_operation +-- test LSD +dqinv280 invert 0010000111000111000111000000000002 -> NaN Invalid_operation +dqinv281 invert 0001000111000111000111000000000003 -> NaN Invalid_operation +dqinv282 invert 0000000111000111000111100000000004 -> NaN Invalid_operation +dqinv283 invert 0000000111000111000111010000000005 -> NaN Invalid_operation +dqinv284 invert 1000000111000111000111001000000006 -> NaN Invalid_operation +dqinv285 invert 1000000111000111000111000100000007 -> NaN Invalid_operation +dqinv286 invert 1000000111000111000111000010000008 -> NaN Invalid_operation +dqinv287 invert 1000000111000111000111000001000009 -> NaN Invalid_operation +-- test Middie +dqinv288 invert 0010000111000111000111000020000000 -> NaN Invalid_operation +dqinv289 invert 0001000111000111000111000030000001 -> NaN Invalid_operation +dqinv290 invert 0000000111000111000111100040000010 -> NaN Invalid_operation +dqinv291 invert 0000000111000111000111010050000100 -> NaN Invalid_operation +dqinv292 invert 1000000111000111000111001060001000 -> NaN Invalid_operation +dqinv293 invert 1000000111000111000111000170010000 -> NaN Invalid_operation +dqinv294 invert 1000000111000111000111000080100000 -> NaN Invalid_operation +dqinv295 invert 1000000111000111000111000091000000 -> NaN Invalid_operation +-- signs +dqinv296 invert -1000000111000111000111000001000000 -> NaN Invalid_operation +dqinv299 invert 1000000111000111000111000001000000 -> 111111000111000111000111110111111 + +-- Nmax, Nmin, Ntiny-like +dqinv341 invert 9.99999999E+2998 -> NaN Invalid_operation +dqinv342 invert 1E-2998 -> NaN Invalid_operation +dqinv343 invert 1.00000000E-2998 -> NaN Invalid_operation +dqinv344 invert 1E-2078 -> NaN Invalid_operation +dqinv345 invert -1E-2078 -> NaN Invalid_operation +dqinv346 invert -1.00000000E-2998 -> NaN Invalid_operation +dqinv347 invert -1E-2998 -> NaN Invalid_operation +dqinv348 invert -9.99999999E+2998 -> NaN Invalid_operation + +-- A few other non-integers +dqinv361 invert 1.0 -> NaN Invalid_operation +dqinv362 invert 1E+1 -> NaN Invalid_operation +dqinv363 invert 0.0 -> NaN Invalid_operation +dqinv364 invert 0E+1 -> NaN Invalid_operation +dqinv365 invert 9.9 -> NaN Invalid_operation +dqinv366 invert 9E+1 -> NaN Invalid_operation + +-- All Specials are in error +dqinv788 invert -Inf -> NaN Invalid_operation +dqinv794 invert Inf -> NaN Invalid_operation +dqinv821 invert NaN -> NaN Invalid_operation +dqinv841 invert sNaN -> NaN Invalid_operation +-- propagating NaNs +dqinv861 invert NaN1 -> NaN Invalid_operation +dqinv862 invert +NaN2 -> NaN Invalid_operation +dqinv863 invert NaN3 -> NaN Invalid_operation +dqinv864 invert NaN4 -> NaN Invalid_operation +dqinv865 invert NaN5 -> NaN Invalid_operation +dqinv871 invert sNaN11 -> NaN Invalid_operation +dqinv872 invert sNaN12 -> NaN Invalid_operation +dqinv873 invert sNaN13 -> NaN Invalid_operation +dqinv874 invert sNaN14 -> NaN Invalid_operation +dqinv875 invert sNaN15 -> NaN Invalid_operation +dqinv876 invert NaN16 -> NaN Invalid_operation +dqinv881 invert +NaN25 -> NaN Invalid_operation +dqinv882 invert -NaN26 -> NaN Invalid_operation +dqinv883 invert -sNaN27 -> NaN Invalid_operation Added: python/branches/release25-maint/Lib/test/decimaltestdata/dqLogB.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/dqLogB.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,160 @@ +------------------------------------------------------------------------ +-- dqLogB.decTest -- integral 754r adjusted exponent, for decQuads -- +-- Copyright (c) IBM Corporation, 2005, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +extended: 1 +clamp: 1 +precision: 34 +maxExponent: 6144 +minExponent: -6143 +rounding: half_even + +-- basics +dqlogb000 logb 0 -> -Infinity Division_by_zero +dqlogb001 logb 1E-6176 -> -6176 +dqlogb002 logb 1E-6143 -> -6143 +dqlogb003 logb 0.001 -> -3 +dqlogb004 logb 0.03 -> -2 +dqlogb005 logb 1 -> 0 +dqlogb006 logb 2 -> 0 +dqlogb007 logb 2.5 -> 0 +dqlogb008 logb 2.50 -> 0 +dqlogb009 logb 2.500 -> 0 +dqlogb010 logb 10 -> 1 +dqlogb011 logb 70 -> 1 +dqlogb012 logb 100 -> 2 +dqlogb013 logb 250 -> 2 +dqlogb014 logb 9E+6144 -> 6144 +dqlogb015 logb +Infinity -> Infinity + +-- negatives appear to be treated as positives +dqlogb021 logb -0 -> -Infinity Division_by_zero +dqlogb022 logb -1E-6176 -> -6176 +dqlogb023 logb -9E-6143 -> -6143 +dqlogb024 logb -0.001 -> -3 +dqlogb025 logb -1 -> 0 +dqlogb026 logb -2 -> 0 +dqlogb027 logb -10 -> 1 +dqlogb028 logb -70 -> 1 +dqlogb029 logb -100 -> 2 +dqlogb030 logb -9E+6144 -> 6144 +dqlogb031 logb -Infinity -> Infinity + +-- zeros +dqlogb111 logb 0 -> -Infinity Division_by_zero +dqlogb112 logb -0 -> -Infinity Division_by_zero +dqlogb113 logb 0E+4 -> -Infinity Division_by_zero +dqlogb114 logb -0E+4 -> -Infinity Division_by_zero +dqlogb115 logb 0.0000 -> -Infinity Division_by_zero +dqlogb116 logb -0.0000 -> -Infinity Division_by_zero +dqlogb117 logb 0E-141 -> -Infinity Division_by_zero +dqlogb118 logb -0E-141 -> -Infinity Division_by_zero + +-- full coefficients, alternating bits +dqlogb121 logb 268268268 -> 8 +dqlogb122 logb -268268268 -> 8 +dqlogb123 logb 134134134 -> 8 +dqlogb124 logb -134134134 -> 8 + +-- Nmax, Nmin, Ntiny +dqlogb131 logb 9.999999999999999999999999999999999E+6144 -> 6144 +dqlogb132 logb 1E-6143 -> -6143 +dqlogb133 logb 1.000000000000000000000000000000000E-6143 -> -6143 +dqlogb134 logb 1E-6176 -> -6176 + +dqlogb135 logb -1E-6176 -> -6176 +dqlogb136 logb -1.000000000000000000000000000000000E-6143 -> -6143 +dqlogb137 logb -1E-6143 -> -6143 +dqlogb1614 logb -9.999999999999999999999999999999999E+6144 -> 6144 + +-- ones +dqlogb0061 logb 1 -> 0 +dqlogb0062 logb 1.0 -> 0 +dqlogb0063 logb 1.000000000000000 -> 0 + +-- notable cases -- exact powers of 10 +dqlogb1100 logb 1 -> 0 +dqlogb1101 logb 10 -> 1 +dqlogb1102 logb 100 -> 2 +dqlogb1103 logb 1000 -> 3 +dqlogb1104 logb 10000 -> 4 +dqlogb1105 logb 100000 -> 5 +dqlogb1106 logb 1000000 -> 6 +dqlogb1107 logb 10000000 -> 7 +dqlogb1108 logb 100000000 -> 8 +dqlogb1109 logb 1000000000 -> 9 +dqlogb1110 logb 10000000000 -> 10 +dqlogb1111 logb 100000000000 -> 11 +dqlogb1112 logb 1000000000000 -> 12 +dqlogb1113 logb 0.00000000001 -> -11 +dqlogb1114 logb 0.0000000001 -> -10 +dqlogb1115 logb 0.000000001 -> -9 +dqlogb1116 logb 0.00000001 -> -8 +dqlogb1117 logb 0.0000001 -> -7 +dqlogb1118 logb 0.000001 -> -6 +dqlogb1119 logb 0.00001 -> -5 +dqlogb1120 logb 0.0001 -> -4 +dqlogb1121 logb 0.001 -> -3 +dqlogb1122 logb 0.01 -> -2 +dqlogb1123 logb 0.1 -> -1 +dqlogb1124 logb 1E-99 -> -99 +dqlogb1125 logb 1E-100 -> -100 +dqlogb1127 logb 1E-299 -> -299 +dqlogb1126 logb 1E-6143 -> -6143 + +-- suggestions from Ilan Nehama +dqlogb1400 logb 10E-3 -> -2 +dqlogb1401 logb 10E-2 -> -1 +dqlogb1402 logb 100E-2 -> 0 +dqlogb1403 logb 1000E-2 -> 1 +dqlogb1404 logb 10000E-2 -> 2 +dqlogb1405 logb 10E-1 -> 0 +dqlogb1406 logb 100E-1 -> 1 +dqlogb1407 logb 1000E-1 -> 2 +dqlogb1408 logb 10000E-1 -> 3 +dqlogb1409 logb 10E0 -> 1 +dqlogb1410 logb 100E0 -> 2 +dqlogb1411 logb 1000E0 -> 3 +dqlogb1412 logb 10000E0 -> 4 +dqlogb1413 logb 10E1 -> 2 +dqlogb1414 logb 100E1 -> 3 +dqlogb1415 logb 1000E1 -> 4 +dqlogb1416 logb 10000E1 -> 5 +dqlogb1417 logb 10E2 -> 3 +dqlogb1418 logb 100E2 -> 4 +dqlogb1419 logb 1000E2 -> 5 +dqlogb1420 logb 10000E2 -> 6 + +-- special values +dqlogb820 logb Infinity -> Infinity +dqlogb821 logb 0 -> -Infinity Division_by_zero +dqlogb822 logb NaN -> NaN +dqlogb823 logb sNaN -> NaN Invalid_operation +-- propagating NaNs +dqlogb824 logb sNaN123 -> NaN123 Invalid_operation +dqlogb825 logb -sNaN321 -> -NaN321 Invalid_operation +dqlogb826 logb NaN456 -> NaN456 +dqlogb827 logb -NaN654 -> -NaN654 +dqlogb828 logb NaN1 -> NaN1 + +-- Null test +dqlogb900 logb # -> NaN Invalid_operation + + Added: python/branches/release25-maint/Lib/test/decimaltestdata/dqMax.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/dqMax.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,322 @@ +------------------------------------------------------------------------ +-- dqMax.decTest -- decQuad maxnum -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- we assume that base comparison is tested in compare.decTest, so +-- these mainly cover special cases and rounding +extended: 1 +clamp: 1 +precision: 34 +maxExponent: 6144 +minExponent: -6143 +rounding: half_even + +-- sanity checks +dqmax001 max -2 -2 -> -2 +dqmax002 max -2 -1 -> -1 +dqmax003 max -2 0 -> 0 +dqmax004 max -2 1 -> 1 +dqmax005 max -2 2 -> 2 +dqmax006 max -1 -2 -> -1 +dqmax007 max -1 -1 -> -1 +dqmax008 max -1 0 -> 0 +dqmax009 max -1 1 -> 1 +dqmax010 max -1 2 -> 2 +dqmax011 max 0 -2 -> 0 +dqmax012 max 0 -1 -> 0 +dqmax013 max 0 0 -> 0 +dqmax014 max 0 1 -> 1 +dqmax015 max 0 2 -> 2 +dqmax016 max 1 -2 -> 1 +dqmax017 max 1 -1 -> 1 +dqmax018 max 1 0 -> 1 +dqmax019 max 1 1 -> 1 +dqmax020 max 1 2 -> 2 +dqmax021 max 2 -2 -> 2 +dqmax022 max 2 -1 -> 2 +dqmax023 max 2 0 -> 2 +dqmax025 max 2 1 -> 2 +dqmax026 max 2 2 -> 2 + +-- extended zeros +dqmax030 max 0 0 -> 0 +dqmax031 max 0 -0 -> 0 +dqmax032 max 0 -0.0 -> 0 +dqmax033 max 0 0.0 -> 0 +dqmax034 max -0 0 -> 0 -- note: -0 = 0, but 0 chosen +dqmax035 max -0 -0 -> -0 +dqmax036 max -0 -0.0 -> -0.0 +dqmax037 max -0 0.0 -> 0.0 +dqmax038 max 0.0 0 -> 0 +dqmax039 max 0.0 -0 -> 0.0 +dqmax040 max 0.0 -0.0 -> 0.0 +dqmax041 max 0.0 0.0 -> 0.0 +dqmax042 max -0.0 0 -> 0 +dqmax043 max -0.0 -0 -> -0.0 +dqmax044 max -0.0 -0.0 -> -0.0 +dqmax045 max -0.0 0.0 -> 0.0 + +dqmax050 max -0E1 0E1 -> 0E+1 +dqmax051 max -0E2 0E2 -> 0E+2 +dqmax052 max -0E2 0E1 -> 0E+1 +dqmax053 max -0E1 0E2 -> 0E+2 +dqmax054 max 0E1 -0E1 -> 0E+1 +dqmax055 max 0E2 -0E2 -> 0E+2 +dqmax056 max 0E2 -0E1 -> 0E+2 +dqmax057 max 0E1 -0E2 -> 0E+1 + +dqmax058 max 0E1 0E1 -> 0E+1 +dqmax059 max 0E2 0E2 -> 0E+2 +dqmax060 max 0E2 0E1 -> 0E+2 +dqmax061 max 0E1 0E2 -> 0E+2 +dqmax062 max -0E1 -0E1 -> -0E+1 +dqmax063 max -0E2 -0E2 -> -0E+2 +dqmax064 max -0E2 -0E1 -> -0E+1 +dqmax065 max -0E1 -0E2 -> -0E+1 + +-- Specials +dqmax090 max Inf -Inf -> Infinity +dqmax091 max Inf -1000 -> Infinity +dqmax092 max Inf -1 -> Infinity +dqmax093 max Inf -0 -> Infinity +dqmax094 max Inf 0 -> Infinity +dqmax095 max Inf 1 -> Infinity +dqmax096 max Inf 1000 -> Infinity +dqmax097 max Inf Inf -> Infinity +dqmax098 max -1000 Inf -> Infinity +dqmax099 max -Inf Inf -> Infinity +dqmax100 max -1 Inf -> Infinity +dqmax101 max -0 Inf -> Infinity +dqmax102 max 0 Inf -> Infinity +dqmax103 max 1 Inf -> Infinity +dqmax104 max 1000 Inf -> Infinity +dqmax105 max Inf Inf -> Infinity + +dqmax120 max -Inf -Inf -> -Infinity +dqmax121 max -Inf -1000 -> -1000 +dqmax122 max -Inf -1 -> -1 +dqmax123 max -Inf -0 -> -0 +dqmax124 max -Inf 0 -> 0 +dqmax125 max -Inf 1 -> 1 +dqmax126 max -Inf 1000 -> 1000 +dqmax127 max -Inf Inf -> Infinity +dqmax128 max -Inf -Inf -> -Infinity +dqmax129 max -1000 -Inf -> -1000 +dqmax130 max -1 -Inf -> -1 +dqmax131 max -0 -Inf -> -0 +dqmax132 max 0 -Inf -> 0 +dqmax133 max 1 -Inf -> 1 +dqmax134 max 1000 -Inf -> 1000 +dqmax135 max Inf -Inf -> Infinity + +-- 2004.08.02 754r chooses number over NaN in mixed cases +dqmax141 max NaN -Inf -> -Infinity +dqmax142 max NaN -1000 -> -1000 +dqmax143 max NaN -1 -> -1 +dqmax144 max NaN -0 -> -0 +dqmax145 max NaN 0 -> 0 +dqmax146 max NaN 1 -> 1 +dqmax147 max NaN 1000 -> 1000 +dqmax148 max NaN Inf -> Infinity +dqmax149 max NaN NaN -> NaN +dqmax150 max -Inf NaN -> -Infinity +dqmax151 max -1000 NaN -> -1000 +dqmax152 max -1 NaN -> -1 +dqmax153 max -0 NaN -> -0 +dqmax154 max 0 NaN -> 0 +dqmax155 max 1 NaN -> 1 +dqmax156 max 1000 NaN -> 1000 +dqmax157 max Inf NaN -> Infinity + +dqmax161 max sNaN -Inf -> NaN Invalid_operation +dqmax162 max sNaN -1000 -> NaN Invalid_operation +dqmax163 max sNaN -1 -> NaN Invalid_operation +dqmax164 max sNaN -0 -> NaN Invalid_operation +dqmax165 max sNaN 0 -> NaN Invalid_operation +dqmax166 max sNaN 1 -> NaN Invalid_operation +dqmax167 max sNaN 1000 -> NaN Invalid_operation +dqmax168 max sNaN NaN -> NaN Invalid_operation +dqmax169 max sNaN sNaN -> NaN Invalid_operation +dqmax170 max NaN sNaN -> NaN Invalid_operation +dqmax171 max -Inf sNaN -> NaN Invalid_operation +dqmax172 max -1000 sNaN -> NaN Invalid_operation +dqmax173 max -1 sNaN -> NaN Invalid_operation +dqmax174 max -0 sNaN -> NaN Invalid_operation +dqmax175 max 0 sNaN -> NaN Invalid_operation +dqmax176 max 1 sNaN -> NaN Invalid_operation +dqmax177 max 1000 sNaN -> NaN Invalid_operation +dqmax178 max Inf sNaN -> NaN Invalid_operation +dqmax179 max NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +dqmax181 max NaN9 -Inf -> -Infinity +dqmax182 max NaN8 9 -> 9 +dqmax183 max -NaN7 Inf -> Infinity + +dqmax184 max -NaN1 NaN11 -> -NaN1 +dqmax185 max NaN2 NaN12 -> NaN2 +dqmax186 max -NaN13 -NaN7 -> -NaN13 +dqmax187 max NaN14 -NaN5 -> NaN14 + +dqmax188 max -Inf NaN4 -> -Infinity +dqmax189 max -9 -NaN3 -> -9 +dqmax190 max Inf NaN2 -> Infinity + +dqmax191 max sNaN99 -Inf -> NaN99 Invalid_operation +dqmax192 max sNaN98 -1 -> NaN98 Invalid_operation +dqmax193 max -sNaN97 NaN -> -NaN97 Invalid_operation +dqmax194 max sNaN96 sNaN94 -> NaN96 Invalid_operation +dqmax195 max NaN95 sNaN93 -> NaN93 Invalid_operation +dqmax196 max -Inf sNaN92 -> NaN92 Invalid_operation +dqmax197 max 0 sNaN91 -> NaN91 Invalid_operation +dqmax198 max Inf -sNaN90 -> -NaN90 Invalid_operation +dqmax199 max NaN sNaN89 -> NaN89 Invalid_operation + +-- old rounding checks +dqmax221 max 12345678000 1 -> 12345678000 +dqmax222 max 1 12345678000 -> 12345678000 +dqmax223 max 1234567800 1 -> 1234567800 +dqmax224 max 1 1234567800 -> 1234567800 +dqmax225 max 1234567890 1 -> 1234567890 +dqmax226 max 1 1234567890 -> 1234567890 +dqmax227 max 1234567891 1 -> 1234567891 +dqmax228 max 1 1234567891 -> 1234567891 +dqmax229 max 12345678901 1 -> 12345678901 +dqmax230 max 1 12345678901 -> 12345678901 +dqmax231 max 1234567896 1 -> 1234567896 +dqmax232 max 1 1234567896 -> 1234567896 +dqmax233 max -1234567891 1 -> 1 +dqmax234 max 1 -1234567891 -> 1 +dqmax235 max -12345678901 1 -> 1 +dqmax236 max 1 -12345678901 -> 1 +dqmax237 max -1234567896 1 -> 1 +dqmax238 max 1 -1234567896 -> 1 + +-- from examples +dqmax280 max '3' '2' -> '3' +dqmax281 max '-10' '3' -> '3' +dqmax282 max '1.0' '1' -> '1' +dqmax283 max '1' '1.0' -> '1' +dqmax284 max '7' 'NaN' -> '7' + +-- expanded list from min/max 754r purple prose +-- [explicit tests for exponent ordering] +dqmax401 max Inf 1.1 -> Infinity +dqmax402 max 1.1 1 -> 1.1 +dqmax403 max 1 1.0 -> 1 +dqmax404 max 1.0 0.1 -> 1.0 +dqmax405 max 0.1 0.10 -> 0.1 +dqmax406 max 0.10 0.100 -> 0.10 +dqmax407 max 0.10 0 -> 0.10 +dqmax408 max 0 0.0 -> 0 +dqmax409 max 0.0 -0 -> 0.0 +dqmax410 max 0.0 -0.0 -> 0.0 +dqmax411 max 0.00 -0.0 -> 0.00 +dqmax412 max 0.0 -0.00 -> 0.0 +dqmax413 max 0 -0.0 -> 0 +dqmax414 max 0 -0 -> 0 +dqmax415 max -0.0 -0 -> -0.0 +dqmax416 max -0 -0.100 -> -0 +dqmax417 max -0.100 -0.10 -> -0.100 +dqmax418 max -0.10 -0.1 -> -0.10 +dqmax419 max -0.1 -1.0 -> -0.1 +dqmax420 max -1.0 -1 -> -1.0 +dqmax421 max -1 -1.1 -> -1 +dqmax423 max -1.1 -Inf -> -1.1 +-- same with operands reversed +dqmax431 max 1.1 Inf -> Infinity +dqmax432 max 1 1.1 -> 1.1 +dqmax433 max 1.0 1 -> 1 +dqmax434 max 0.1 1.0 -> 1.0 +dqmax435 max 0.10 0.1 -> 0.1 +dqmax436 max 0.100 0.10 -> 0.10 +dqmax437 max 0 0.10 -> 0.10 +dqmax438 max 0.0 0 -> 0 +dqmax439 max -0 0.0 -> 0.0 +dqmax440 max -0.0 0.0 -> 0.0 +dqmax441 max -0.0 0.00 -> 0.00 +dqmax442 max -0.00 0.0 -> 0.0 +dqmax443 max -0.0 0 -> 0 +dqmax444 max -0 0 -> 0 +dqmax445 max -0 -0.0 -> -0.0 +dqmax446 max -0.100 -0 -> -0 +dqmax447 max -0.10 -0.100 -> -0.100 +dqmax448 max -0.1 -0.10 -> -0.10 +dqmax449 max -1.0 -0.1 -> -0.1 +dqmax450 max -1 -1.0 -> -1.0 +dqmax451 max -1.1 -1 -> -1 +dqmax453 max -Inf -1.1 -> -1.1 +-- largies +dqmax460 max 1000 1E+3 -> 1E+3 +dqmax461 max 1E+3 1000 -> 1E+3 +dqmax462 max 1000 -1E+3 -> 1000 +dqmax463 max 1E+3 -1000 -> 1E+3 +dqmax464 max -1000 1E+3 -> 1E+3 +dqmax465 max -1E+3 1000 -> 1000 +dqmax466 max -1000 -1E+3 -> -1000 +dqmax467 max -1E+3 -1000 -> -1000 + +-- misalignment traps for little-endian +dqmax471 max 1.0 0.1 -> 1.0 +dqmax472 max 0.1 1.0 -> 1.0 +dqmax473 max 10.0 0.1 -> 10.0 +dqmax474 max 0.1 10.0 -> 10.0 +dqmax475 max 100 1.0 -> 100 +dqmax476 max 1.0 100 -> 100 +dqmax477 max 1000 10.0 -> 1000 +dqmax478 max 10.0 1000 -> 1000 +dqmax479 max 10000 100.0 -> 10000 +dqmax480 max 100.0 10000 -> 10000 +dqmax481 max 100000 1000.0 -> 100000 +dqmax482 max 1000.0 100000 -> 100000 +dqmax483 max 1000000 10000.0 -> 1000000 +dqmax484 max 10000.0 1000000 -> 1000000 + +-- subnormals +dqmax510 max 1.00E-6143 0 -> 1.00E-6143 +dqmax511 max 0.1E-6143 0 -> 1E-6144 Subnormal +dqmax512 max 0.10E-6143 0 -> 1.0E-6144 Subnormal +dqmax513 max 0.100E-6143 0 -> 1.00E-6144 Subnormal +dqmax514 max 0.01E-6143 0 -> 1E-6145 Subnormal +dqmax515 max 0.999E-6143 0 -> 9.99E-6144 Subnormal +dqmax516 max 0.099E-6143 0 -> 9.9E-6145 Subnormal +dqmax517 max 0.009E-6143 0 -> 9E-6146 Subnormal +dqmax518 max 0.001E-6143 0 -> 1E-6146 Subnormal +dqmax519 max 0.0009E-6143 0 -> 9E-6147 Subnormal +dqmax520 max 0.0001E-6143 0 -> 1E-6147 Subnormal + +dqmax530 max -1.00E-6143 0 -> 0 +dqmax531 max -0.1E-6143 0 -> 0 +dqmax532 max -0.10E-6143 0 -> 0 +dqmax533 max -0.100E-6143 0 -> 0 +dqmax534 max -0.01E-6143 0 -> 0 +dqmax535 max -0.999E-6143 0 -> 0 +dqmax536 max -0.099E-6143 0 -> 0 +dqmax537 max -0.009E-6143 0 -> 0 +dqmax538 max -0.001E-6143 0 -> 0 +dqmax539 max -0.0009E-6143 0 -> 0 +dqmax540 max -0.0001E-6143 0 -> 0 + +-- Null tests +dqmax900 max 10 # -> NaN Invalid_operation +dqmax901 max # 10 -> NaN Invalid_operation + + + Added: python/branches/release25-maint/Lib/test/decimaltestdata/dqMaxMag.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/dqMaxMag.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,304 @@ +------------------------------------------------------------------------ +-- dqMaxMag.decTest -- decQuad maxnummag -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- we assume that base comparison is tested in compare.decTest, so +-- these mainly cover special cases and rounding +extended: 1 +clamp: 1 +precision: 34 +maxExponent: 6144 +minExponent: -6143 +rounding: half_even + +-- sanity checks +dqmxg001 maxmag -2 -2 -> -2 +dqmxg002 maxmag -2 -1 -> -2 +dqmxg003 maxmag -2 0 -> -2 +dqmxg004 maxmag -2 1 -> -2 +dqmxg005 maxmag -2 2 -> 2 +dqmxg006 maxmag -1 -2 -> -2 +dqmxg007 maxmag -1 -1 -> -1 +dqmxg008 maxmag -1 0 -> -1 +dqmxg009 maxmag -1 1 -> 1 +dqmxg010 maxmag -1 2 -> 2 +dqmxg011 maxmag 0 -2 -> -2 +dqmxg012 maxmag 0 -1 -> -1 +dqmxg013 maxmag 0 0 -> 0 +dqmxg014 maxmag 0 1 -> 1 +dqmxg015 maxmag 0 2 -> 2 +dqmxg016 maxmag 1 -2 -> -2 +dqmxg017 maxmag 1 -1 -> 1 +dqmxg018 maxmag 1 0 -> 1 +dqmxg019 maxmag 1 1 -> 1 +dqmxg020 maxmag 1 2 -> 2 +dqmxg021 maxmag 2 -2 -> 2 +dqmxg022 maxmag 2 -1 -> 2 +dqmxg023 maxmag 2 0 -> 2 +dqmxg025 maxmag 2 1 -> 2 +dqmxg026 maxmag 2 2 -> 2 + +-- extended zeros +dqmxg030 maxmag 0 0 -> 0 +dqmxg031 maxmag 0 -0 -> 0 +dqmxg032 maxmag 0 -0.0 -> 0 +dqmxg033 maxmag 0 0.0 -> 0 +dqmxg034 maxmag -0 0 -> 0 -- note: -0 = 0, but 0 chosen +dqmxg035 maxmag -0 -0 -> -0 +dqmxg036 maxmag -0 -0.0 -> -0.0 +dqmxg037 maxmag -0 0.0 -> 0.0 +dqmxg038 maxmag 0.0 0 -> 0 +dqmxg039 maxmag 0.0 -0 -> 0.0 +dqmxg040 maxmag 0.0 -0.0 -> 0.0 +dqmxg041 maxmag 0.0 0.0 -> 0.0 +dqmxg042 maxmag -0.0 0 -> 0 +dqmxg043 maxmag -0.0 -0 -> -0.0 +dqmxg044 maxmag -0.0 -0.0 -> -0.0 +dqmxg045 maxmag -0.0 0.0 -> 0.0 + +dqmxg050 maxmag -0E1 0E1 -> 0E+1 +dqmxg051 maxmag -0E2 0E2 -> 0E+2 +dqmxg052 maxmag -0E2 0E1 -> 0E+1 +dqmxg053 maxmag -0E1 0E2 -> 0E+2 +dqmxg054 maxmag 0E1 -0E1 -> 0E+1 +dqmxg055 maxmag 0E2 -0E2 -> 0E+2 +dqmxg056 maxmag 0E2 -0E1 -> 0E+2 +dqmxg057 maxmag 0E1 -0E2 -> 0E+1 + +dqmxg058 maxmag 0E1 0E1 -> 0E+1 +dqmxg059 maxmag 0E2 0E2 -> 0E+2 +dqmxg060 maxmag 0E2 0E1 -> 0E+2 +dqmxg061 maxmag 0E1 0E2 -> 0E+2 +dqmxg062 maxmag -0E1 -0E1 -> -0E+1 +dqmxg063 maxmag -0E2 -0E2 -> -0E+2 +dqmxg064 maxmag -0E2 -0E1 -> -0E+1 +dqmxg065 maxmag -0E1 -0E2 -> -0E+1 + +-- Specials +dqmxg090 maxmag Inf -Inf -> Infinity +dqmxg091 maxmag Inf -1000 -> Infinity +dqmxg092 maxmag Inf -1 -> Infinity +dqmxg093 maxmag Inf -0 -> Infinity +dqmxg094 maxmag Inf 0 -> Infinity +dqmxg095 maxmag Inf 1 -> Infinity +dqmxg096 maxmag Inf 1000 -> Infinity +dqmxg097 maxmag Inf Inf -> Infinity +dqmxg098 maxmag -1000 Inf -> Infinity +dqmxg099 maxmag -Inf Inf -> Infinity +dqmxg100 maxmag -1 Inf -> Infinity +dqmxg101 maxmag -0 Inf -> Infinity +dqmxg102 maxmag 0 Inf -> Infinity +dqmxg103 maxmag 1 Inf -> Infinity +dqmxg104 maxmag 1000 Inf -> Infinity +dqmxg105 maxmag Inf Inf -> Infinity + +dqmxg120 maxmag -Inf -Inf -> -Infinity +dqmxg121 maxmag -Inf -1000 -> -Infinity +dqmxg122 maxmag -Inf -1 -> -Infinity +dqmxg123 maxmag -Inf -0 -> -Infinity +dqmxg124 maxmag -Inf 0 -> -Infinity +dqmxg125 maxmag -Inf 1 -> -Infinity +dqmxg126 maxmag -Inf 1000 -> -Infinity +dqmxg127 maxmag -Inf Inf -> Infinity +dqmxg128 maxmag -Inf -Inf -> -Infinity +dqmxg129 maxmag -1000 -Inf -> -Infinity +dqmxg130 maxmag -1 -Inf -> -Infinity +dqmxg131 maxmag -0 -Inf -> -Infinity +dqmxg132 maxmag 0 -Inf -> -Infinity +dqmxg133 maxmag 1 -Inf -> -Infinity +dqmxg134 maxmag 1000 -Inf -> -Infinity +dqmxg135 maxmag Inf -Inf -> Infinity + +-- 2004.08.02 754r chooses number over NaN in mixed cases +dqmxg141 maxmag NaN -Inf -> -Infinity +dqmxg142 maxmag NaN -1000 -> -1000 +dqmxg143 maxmag NaN -1 -> -1 +dqmxg144 maxmag NaN -0 -> -0 +dqmxg145 maxmag NaN 0 -> 0 +dqmxg146 maxmag NaN 1 -> 1 +dqmxg147 maxmag NaN 1000 -> 1000 +dqmxg148 maxmag NaN Inf -> Infinity +dqmxg149 maxmag NaN NaN -> NaN +dqmxg150 maxmag -Inf NaN -> -Infinity +dqmxg151 maxmag -1000 NaN -> -1000 +dqmxg152 maxmag -1 NaN -> -1 +dqmxg153 maxmag -0 NaN -> -0 +dqmxg154 maxmag 0 NaN -> 0 +dqmxg155 maxmag 1 NaN -> 1 +dqmxg156 maxmag 1000 NaN -> 1000 +dqmxg157 maxmag Inf NaN -> Infinity + +dqmxg161 maxmag sNaN -Inf -> NaN Invalid_operation +dqmxg162 maxmag sNaN -1000 -> NaN Invalid_operation +dqmxg163 maxmag sNaN -1 -> NaN Invalid_operation +dqmxg164 maxmag sNaN -0 -> NaN Invalid_operation +dqmxg165 maxmag sNaN 0 -> NaN Invalid_operation +dqmxg166 maxmag sNaN 1 -> NaN Invalid_operation +dqmxg167 maxmag sNaN 1000 -> NaN Invalid_operation +dqmxg168 maxmag sNaN NaN -> NaN Invalid_operation +dqmxg169 maxmag sNaN sNaN -> NaN Invalid_operation +dqmxg170 maxmag NaN sNaN -> NaN Invalid_operation +dqmxg171 maxmag -Inf sNaN -> NaN Invalid_operation +dqmxg172 maxmag -1000 sNaN -> NaN Invalid_operation +dqmxg173 maxmag -1 sNaN -> NaN Invalid_operation +dqmxg174 maxmag -0 sNaN -> NaN Invalid_operation +dqmxg175 maxmag 0 sNaN -> NaN Invalid_operation +dqmxg176 maxmag 1 sNaN -> NaN Invalid_operation +dqmxg177 maxmag 1000 sNaN -> NaN Invalid_operation +dqmxg178 maxmag Inf sNaN -> NaN Invalid_operation +dqmxg179 maxmag NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +dqmxg181 maxmag NaN9 -Inf -> -Infinity +dqmxg182 maxmag NaN8 9 -> 9 +dqmxg183 maxmag -NaN7 Inf -> Infinity + +dqmxg184 maxmag -NaN1 NaN11 -> -NaN1 +dqmxg185 maxmag NaN2 NaN12 -> NaN2 +dqmxg186 maxmag -NaN13 -NaN7 -> -NaN13 +dqmxg187 maxmag NaN14 -NaN5 -> NaN14 + +dqmxg188 maxmag -Inf NaN4 -> -Infinity +dqmxg189 maxmag -9 -NaN3 -> -9 +dqmxg190 maxmag Inf NaN2 -> Infinity + +dqmxg191 maxmag sNaN99 -Inf -> NaN99 Invalid_operation +dqmxg192 maxmag sNaN98 -1 -> NaN98 Invalid_operation +dqmxg193 maxmag -sNaN97 NaN -> -NaN97 Invalid_operation +dqmxg194 maxmag sNaN96 sNaN94 -> NaN96 Invalid_operation +dqmxg195 maxmag NaN95 sNaN93 -> NaN93 Invalid_operation +dqmxg196 maxmag -Inf sNaN92 -> NaN92 Invalid_operation +dqmxg197 maxmag 0 sNaN91 -> NaN91 Invalid_operation +dqmxg198 maxmag Inf -sNaN90 -> -NaN90 Invalid_operation +dqmxg199 maxmag NaN sNaN89 -> NaN89 Invalid_operation + +-- old rounding checks +dqmxg221 maxmag 12345678000 1 -> 12345678000 +dqmxg222 maxmag 1 12345678000 -> 12345678000 +dqmxg223 maxmag 1234567800 1 -> 1234567800 +dqmxg224 maxmag 1 1234567800 -> 1234567800 +dqmxg225 maxmag 1234567890 1 -> 1234567890 +dqmxg226 maxmag 1 1234567890 -> 1234567890 +dqmxg227 maxmag 1234567891 1 -> 1234567891 +dqmxg228 maxmag 1 1234567891 -> 1234567891 +dqmxg229 maxmag 12345678901 1 -> 12345678901 +dqmxg230 maxmag 1 12345678901 -> 12345678901 +dqmxg231 maxmag 1234567896 1 -> 1234567896 +dqmxg232 maxmag 1 1234567896 -> 1234567896 +dqmxg233 maxmag -1234567891 1 -> -1234567891 +dqmxg234 maxmag 1 -1234567891 -> -1234567891 +dqmxg235 maxmag -12345678901 1 -> -12345678901 +dqmxg236 maxmag 1 -12345678901 -> -12345678901 +dqmxg237 maxmag -1234567896 1 -> -1234567896 +dqmxg238 maxmag 1 -1234567896 -> -1234567896 + +-- from examples +dqmxg280 maxmag '3' '2' -> '3' +dqmxg281 maxmag '-10' '3' -> '-10' +dqmxg282 maxmag '1.0' '1' -> '1' +dqmxg283 maxmag '1' '1.0' -> '1' +dqmxg284 maxmag '7' 'NaN' -> '7' + +-- expanded list from min/max 754r purple prose +-- [explicit tests for exponent ordering] +dqmxg401 maxmag Inf 1.1 -> Infinity +dqmxg402 maxmag 1.1 1 -> 1.1 +dqmxg403 maxmag 1 1.0 -> 1 +dqmxg404 maxmag 1.0 0.1 -> 1.0 +dqmxg405 maxmag 0.1 0.10 -> 0.1 +dqmxg406 maxmag 0.10 0.100 -> 0.10 +dqmxg407 maxmag 0.10 0 -> 0.10 +dqmxg408 maxmag 0 0.0 -> 0 +dqmxg409 maxmag 0.0 -0 -> 0.0 +dqmxg410 maxmag 0.0 -0.0 -> 0.0 +dqmxg411 maxmag 0.00 -0.0 -> 0.00 +dqmxg412 maxmag 0.0 -0.00 -> 0.0 +dqmxg413 maxmag 0 -0.0 -> 0 +dqmxg414 maxmag 0 -0 -> 0 +dqmxg415 maxmag -0.0 -0 -> -0.0 +dqmxg416 maxmag -0 -0.100 -> -0.100 +dqmxg417 maxmag -0.100 -0.10 -> -0.100 +dqmxg418 maxmag -0.10 -0.1 -> -0.10 +dqmxg419 maxmag -0.1 -1.0 -> -1.0 +dqmxg420 maxmag -1.0 -1 -> -1.0 +dqmxg421 maxmag -1 -1.1 -> -1.1 +dqmxg423 maxmag -1.1 -Inf -> -Infinity +-- same with operands reversed +dqmxg431 maxmag 1.1 Inf -> Infinity +dqmxg432 maxmag 1 1.1 -> 1.1 +dqmxg433 maxmag 1.0 1 -> 1 +dqmxg434 maxmag 0.1 1.0 -> 1.0 +dqmxg435 maxmag 0.10 0.1 -> 0.1 +dqmxg436 maxmag 0.100 0.10 -> 0.10 +dqmxg437 maxmag 0 0.10 -> 0.10 +dqmxg438 maxmag 0.0 0 -> 0 +dqmxg439 maxmag -0 0.0 -> 0.0 +dqmxg440 maxmag -0.0 0.0 -> 0.0 +dqmxg441 maxmag -0.0 0.00 -> 0.00 +dqmxg442 maxmag -0.00 0.0 -> 0.0 +dqmxg443 maxmag -0.0 0 -> 0 +dqmxg444 maxmag -0 0 -> 0 +dqmxg445 maxmag -0 -0.0 -> -0.0 +dqmxg446 maxmag -0.100 -0 -> -0.100 +dqmxg447 maxmag -0.10 -0.100 -> -0.100 +dqmxg448 maxmag -0.1 -0.10 -> -0.10 +dqmxg449 maxmag -1.0 -0.1 -> -1.0 +dqmxg450 maxmag -1 -1.0 -> -1.0 +dqmxg451 maxmag -1.1 -1 -> -1.1 +dqmxg453 maxmag -Inf -1.1 -> -Infinity +-- largies +dqmxg460 maxmag 1000 1E+3 -> 1E+3 +dqmxg461 maxmag 1E+3 1000 -> 1E+3 +dqmxg462 maxmag 1000 -1E+3 -> 1000 +dqmxg463 maxmag 1E+3 -1000 -> 1E+3 +dqmxg464 maxmag -1000 1E+3 -> 1E+3 +dqmxg465 maxmag -1E+3 1000 -> 1000 +dqmxg466 maxmag -1000 -1E+3 -> -1000 +dqmxg467 maxmag -1E+3 -1000 -> -1000 + +-- subnormals +dqmxg510 maxmag 1.00E-6143 0 -> 1.00E-6143 +dqmxg511 maxmag 0.1E-6143 0 -> 1E-6144 Subnormal +dqmxg512 maxmag 0.10E-6143 0 -> 1.0E-6144 Subnormal +dqmxg513 maxmag 0.100E-6143 0 -> 1.00E-6144 Subnormal +dqmxg514 maxmag 0.01E-6143 0 -> 1E-6145 Subnormal +dqmxg515 maxmag 0.999E-6143 0 -> 9.99E-6144 Subnormal +dqmxg516 maxmag 0.099E-6143 0 -> 9.9E-6145 Subnormal +dqmxg517 maxmag 0.009E-6143 0 -> 9E-6146 Subnormal +dqmxg518 maxmag 0.001E-6143 0 -> 1E-6146 Subnormal +dqmxg519 maxmag 0.0009E-6143 0 -> 9E-6147 Subnormal +dqmxg520 maxmag 0.0001E-6143 0 -> 1E-6147 Subnormal + +dqmxg530 maxmag -1.00E-6143 0 -> -1.00E-6143 +dqmxg531 maxmag -0.1E-6143 0 -> -1E-6144 Subnormal +dqmxg532 maxmag -0.10E-6143 0 -> -1.0E-6144 Subnormal +dqmxg533 maxmag -0.100E-6143 0 -> -1.00E-6144 Subnormal +dqmxg534 maxmag -0.01E-6143 0 -> -1E-6145 Subnormal +dqmxg535 maxmag -0.999E-6143 0 -> -9.99E-6144 Subnormal +dqmxg536 maxmag -0.099E-6143 0 -> -9.9E-6145 Subnormal +dqmxg537 maxmag -0.009E-6143 0 -> -9E-6146 Subnormal +dqmxg538 maxmag -0.001E-6143 0 -> -1E-6146 Subnormal +dqmxg539 maxmag -0.0009E-6143 0 -> -9E-6147 Subnormal +dqmxg540 maxmag -0.0001E-6143 0 -> -1E-6147 Subnormal + +-- Null tests +dqmxg900 maxmag 10 # -> NaN Invalid_operation +dqmxg901 maxmag # 10 -> NaN Invalid_operation + Added: python/branches/release25-maint/Lib/test/decimaltestdata/dqMin.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/dqMin.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,309 @@ +------------------------------------------------------------------------ +-- dqMin.decTest -- decQuad minnum -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- we assume that base comparison is tested in compare.decTest, so +-- these mainly cover special cases and rounding +extended: 1 +clamp: 1 +precision: 34 +maxExponent: 6144 +minExponent: -6143 +rounding: half_even + +-- sanity checks +dqmin001 min -2 -2 -> -2 +dqmin002 min -2 -1 -> -2 +dqmin003 min -2 0 -> -2 +dqmin004 min -2 1 -> -2 +dqmin005 min -2 2 -> -2 +dqmin006 min -1 -2 -> -2 +dqmin007 min -1 -1 -> -1 +dqmin008 min -1 0 -> -1 +dqmin009 min -1 1 -> -1 +dqmin010 min -1 2 -> -1 +dqmin011 min 0 -2 -> -2 +dqmin012 min 0 -1 -> -1 +dqmin013 min 0 0 -> 0 +dqmin014 min 0 1 -> 0 +dqmin015 min 0 2 -> 0 +dqmin016 min 1 -2 -> -2 +dqmin017 min 1 -1 -> -1 +dqmin018 min 1 0 -> 0 +dqmin019 min 1 1 -> 1 +dqmin020 min 1 2 -> 1 +dqmin021 min 2 -2 -> -2 +dqmin022 min 2 -1 -> -1 +dqmin023 min 2 0 -> 0 +dqmin025 min 2 1 -> 1 +dqmin026 min 2 2 -> 2 + +-- extended zeros +dqmin030 min 0 0 -> 0 +dqmin031 min 0 -0 -> -0 +dqmin032 min 0 -0.0 -> -0.0 +dqmin033 min 0 0.0 -> 0.0 +dqmin034 min -0 0 -> -0 +dqmin035 min -0 -0 -> -0 +dqmin036 min -0 -0.0 -> -0 +dqmin037 min -0 0.0 -> -0 +dqmin038 min 0.0 0 -> 0.0 +dqmin039 min 0.0 -0 -> -0 +dqmin040 min 0.0 -0.0 -> -0.0 +dqmin041 min 0.0 0.0 -> 0.0 +dqmin042 min -0.0 0 -> -0.0 +dqmin043 min -0.0 -0 -> -0 +dqmin044 min -0.0 -0.0 -> -0.0 +dqmin045 min -0.0 0.0 -> -0.0 + +dqmin046 min 0E1 -0E1 -> -0E+1 +dqmin047 min -0E1 0E2 -> -0E+1 +dqmin048 min 0E2 0E1 -> 0E+1 +dqmin049 min 0E1 0E2 -> 0E+1 +dqmin050 min -0E3 -0E2 -> -0E+3 +dqmin051 min -0E2 -0E3 -> -0E+3 + +-- Specials +dqmin090 min Inf -Inf -> -Infinity +dqmin091 min Inf -1000 -> -1000 +dqmin092 min Inf -1 -> -1 +dqmin093 min Inf -0 -> -0 +dqmin094 min Inf 0 -> 0 +dqmin095 min Inf 1 -> 1 +dqmin096 min Inf 1000 -> 1000 +dqmin097 min Inf Inf -> Infinity +dqmin098 min -1000 Inf -> -1000 +dqmin099 min -Inf Inf -> -Infinity +dqmin100 min -1 Inf -> -1 +dqmin101 min -0 Inf -> -0 +dqmin102 min 0 Inf -> 0 +dqmin103 min 1 Inf -> 1 +dqmin104 min 1000 Inf -> 1000 +dqmin105 min Inf Inf -> Infinity + +dqmin120 min -Inf -Inf -> -Infinity +dqmin121 min -Inf -1000 -> -Infinity +dqmin122 min -Inf -1 -> -Infinity +dqmin123 min -Inf -0 -> -Infinity +dqmin124 min -Inf 0 -> -Infinity +dqmin125 min -Inf 1 -> -Infinity +dqmin126 min -Inf 1000 -> -Infinity +dqmin127 min -Inf Inf -> -Infinity +dqmin128 min -Inf -Inf -> -Infinity +dqmin129 min -1000 -Inf -> -Infinity +dqmin130 min -1 -Inf -> -Infinity +dqmin131 min -0 -Inf -> -Infinity +dqmin132 min 0 -Inf -> -Infinity +dqmin133 min 1 -Inf -> -Infinity +dqmin134 min 1000 -Inf -> -Infinity +dqmin135 min Inf -Inf -> -Infinity + +-- 2004.08.02 754r chooses number over NaN in mixed cases +dqmin141 min NaN -Inf -> -Infinity +dqmin142 min NaN -1000 -> -1000 +dqmin143 min NaN -1 -> -1 +dqmin144 min NaN -0 -> -0 +dqmin145 min NaN 0 -> 0 +dqmin146 min NaN 1 -> 1 +dqmin147 min NaN 1000 -> 1000 +dqmin148 min NaN Inf -> Infinity +dqmin149 min NaN NaN -> NaN +dqmin150 min -Inf NaN -> -Infinity +dqmin151 min -1000 NaN -> -1000 +dqmin152 min -1 -NaN -> -1 +dqmin153 min -0 NaN -> -0 +dqmin154 min 0 -NaN -> 0 +dqmin155 min 1 NaN -> 1 +dqmin156 min 1000 NaN -> 1000 +dqmin157 min Inf NaN -> Infinity + +dqmin161 min sNaN -Inf -> NaN Invalid_operation +dqmin162 min sNaN -1000 -> NaN Invalid_operation +dqmin163 min sNaN -1 -> NaN Invalid_operation +dqmin164 min sNaN -0 -> NaN Invalid_operation +dqmin165 min -sNaN 0 -> -NaN Invalid_operation +dqmin166 min -sNaN 1 -> -NaN Invalid_operation +dqmin167 min sNaN 1000 -> NaN Invalid_operation +dqmin168 min sNaN NaN -> NaN Invalid_operation +dqmin169 min sNaN sNaN -> NaN Invalid_operation +dqmin170 min NaN sNaN -> NaN Invalid_operation +dqmin171 min -Inf sNaN -> NaN Invalid_operation +dqmin172 min -1000 sNaN -> NaN Invalid_operation +dqmin173 min -1 sNaN -> NaN Invalid_operation +dqmin174 min -0 sNaN -> NaN Invalid_operation +dqmin175 min 0 sNaN -> NaN Invalid_operation +dqmin176 min 1 sNaN -> NaN Invalid_operation +dqmin177 min 1000 sNaN -> NaN Invalid_operation +dqmin178 min Inf sNaN -> NaN Invalid_operation +dqmin179 min NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +dqmin181 min NaN9 -Inf -> -Infinity +dqmin182 min -NaN8 9990 -> 9990 +dqmin183 min NaN71 Inf -> Infinity + +dqmin184 min NaN1 NaN54 -> NaN1 +dqmin185 min NaN22 -NaN53 -> NaN22 +dqmin186 min -NaN3 NaN6 -> -NaN3 +dqmin187 min -NaN44 NaN7 -> -NaN44 + +dqmin188 min -Inf NaN41 -> -Infinity +dqmin189 min -9999 -NaN33 -> -9999 +dqmin190 min Inf NaN2 -> Infinity + +dqmin191 min sNaN99 -Inf -> NaN99 Invalid_operation +dqmin192 min sNaN98 -11 -> NaN98 Invalid_operation +dqmin193 min -sNaN97 NaN8 -> -NaN97 Invalid_operation +dqmin194 min sNaN69 sNaN94 -> NaN69 Invalid_operation +dqmin195 min NaN95 sNaN93 -> NaN93 Invalid_operation +dqmin196 min -Inf sNaN92 -> NaN92 Invalid_operation +dqmin197 min 088 sNaN91 -> NaN91 Invalid_operation +dqmin198 min Inf -sNaN90 -> -NaN90 Invalid_operation +dqmin199 min NaN sNaN86 -> NaN86 Invalid_operation + +-- old rounding checks +dqmin221 min -12345678000 1 -> -12345678000 +dqmin222 min 1 -12345678000 -> -12345678000 +dqmin223 min -1234567800 1 -> -1234567800 +dqmin224 min 1 -1234567800 -> -1234567800 +dqmin225 min -1234567890 1 -> -1234567890 +dqmin226 min 1 -1234567890 -> -1234567890 +dqmin227 min -1234567891 1 -> -1234567891 +dqmin228 min 1 -1234567891 -> -1234567891 +dqmin229 min -12345678901 1 -> -12345678901 +dqmin230 min 1 -12345678901 -> -12345678901 +dqmin231 min -1234567896 1 -> -1234567896 +dqmin232 min 1 -1234567896 -> -1234567896 +dqmin233 min 1234567891 1 -> 1 +dqmin234 min 1 1234567891 -> 1 +dqmin235 min 12345678901 1 -> 1 +dqmin236 min 1 12345678901 -> 1 +dqmin237 min 1234567896 1 -> 1 +dqmin238 min 1 1234567896 -> 1 + +-- from examples +dqmin280 min '3' '2' -> '2' +dqmin281 min '-10' '3' -> '-10' +dqmin282 min '1.0' '1' -> '1.0' +dqmin283 min '1' '1.0' -> '1.0' +dqmin284 min '7' 'NaN' -> '7' + +-- expanded list from min/max 754r purple prose +-- [explicit tests for exponent ordering] +dqmin401 min Inf 1.1 -> 1.1 +dqmin402 min 1.1 1 -> 1 +dqmin403 min 1 1.0 -> 1.0 +dqmin404 min 1.0 0.1 -> 0.1 +dqmin405 min 0.1 0.10 -> 0.10 +dqmin406 min 0.10 0.100 -> 0.100 +dqmin407 min 0.10 0 -> 0 +dqmin408 min 0 0.0 -> 0.0 +dqmin409 min 0.0 -0 -> -0 +dqmin410 min 0.0 -0.0 -> -0.0 +dqmin411 min 0.00 -0.0 -> -0.0 +dqmin412 min 0.0 -0.00 -> -0.00 +dqmin413 min 0 -0.0 -> -0.0 +dqmin414 min 0 -0 -> -0 +dqmin415 min -0.0 -0 -> -0 +dqmin416 min -0 -0.100 -> -0.100 +dqmin417 min -0.100 -0.10 -> -0.10 +dqmin418 min -0.10 -0.1 -> -0.1 +dqmin419 min -0.1 -1.0 -> -1.0 +dqmin420 min -1.0 -1 -> -1 +dqmin421 min -1 -1.1 -> -1.1 +dqmin423 min -1.1 -Inf -> -Infinity +-- same with operands reversed +dqmin431 min 1.1 Inf -> 1.1 +dqmin432 min 1 1.1 -> 1 +dqmin433 min 1.0 1 -> 1.0 +dqmin434 min 0.1 1.0 -> 0.1 +dqmin435 min 0.10 0.1 -> 0.10 +dqmin436 min 0.100 0.10 -> 0.100 +dqmin437 min 0 0.10 -> 0 +dqmin438 min 0.0 0 -> 0.0 +dqmin439 min -0 0.0 -> -0 +dqmin440 min -0.0 0.0 -> -0.0 +dqmin441 min -0.0 0.00 -> -0.0 +dqmin442 min -0.00 0.0 -> -0.00 +dqmin443 min -0.0 0 -> -0.0 +dqmin444 min -0 0 -> -0 +dqmin445 min -0 -0.0 -> -0 +dqmin446 min -0.100 -0 -> -0.100 +dqmin447 min -0.10 -0.100 -> -0.10 +dqmin448 min -0.1 -0.10 -> -0.1 +dqmin449 min -1.0 -0.1 -> -1.0 +dqmin450 min -1 -1.0 -> -1 +dqmin451 min -1.1 -1 -> -1.1 +dqmin453 min -Inf -1.1 -> -Infinity +-- largies +dqmin460 min 1000 1E+3 -> 1000 +dqmin461 min 1E+3 1000 -> 1000 +dqmin462 min 1000 -1E+3 -> -1E+3 +dqmin463 min 1E+3 -384 -> -384 +dqmin464 min -384 1E+3 -> -384 +dqmin465 min -1E+3 1000 -> -1E+3 +dqmin466 min -384 -1E+3 -> -1E+3 +dqmin467 min -1E+3 -384 -> -1E+3 + +-- misalignment traps for little-endian +dqmin471 min 1.0 0.1 -> 0.1 +dqmin472 min 0.1 1.0 -> 0.1 +dqmin473 min 10.0 0.1 -> 0.1 +dqmin474 min 0.1 10.0 -> 0.1 +dqmin475 min 100 1.0 -> 1.0 +dqmin476 min 1.0 100 -> 1.0 +dqmin477 min 1000 10.0 -> 10.0 +dqmin478 min 10.0 1000 -> 10.0 +dqmin479 min 10000 100.0 -> 100.0 +dqmin480 min 100.0 10000 -> 100.0 +dqmin481 min 100000 1000.0 -> 1000.0 +dqmin482 min 1000.0 100000 -> 1000.0 +dqmin483 min 1000000 10000.0 -> 10000.0 +dqmin484 min 10000.0 1000000 -> 10000.0 + +-- subnormals +dqmin510 min 1.00E-6143 0 -> 0 +dqmin511 min 0.1E-6143 0 -> 0 +dqmin512 min 0.10E-6143 0 -> 0 +dqmin513 min 0.100E-6143 0 -> 0 +dqmin514 min 0.01E-6143 0 -> 0 +dqmin515 min 0.999E-6143 0 -> 0 +dqmin516 min 0.099E-6143 0 -> 0 +dqmin517 min 0.009E-6143 0 -> 0 +dqmin518 min 0.001E-6143 0 -> 0 +dqmin519 min 0.0009E-6143 0 -> 0 +dqmin520 min 0.0001E-6143 0 -> 0 + +dqmin530 min -1.00E-6143 0 -> -1.00E-6143 +dqmin531 min -0.1E-6143 0 -> -1E-6144 Subnormal +dqmin532 min -0.10E-6143 0 -> -1.0E-6144 Subnormal +dqmin533 min -0.100E-6143 0 -> -1.00E-6144 Subnormal +dqmin534 min -0.01E-6143 0 -> -1E-6145 Subnormal +dqmin535 min -0.999E-6143 0 -> -9.99E-6144 Subnormal +dqmin536 min -0.099E-6143 0 -> -9.9E-6145 Subnormal +dqmin537 min -0.009E-6143 0 -> -9E-6146 Subnormal +dqmin538 min -0.001E-6143 0 -> -1E-6146 Subnormal +dqmin539 min -0.0009E-6143 0 -> -9E-6147 Subnormal +dqmin540 min -0.0001E-6143 0 -> -1E-6147 Subnormal + + +-- Null tests +dqmin900 min 10 # -> NaN Invalid_operation +dqmin901 min # 10 -> NaN Invalid_operation Added: python/branches/release25-maint/Lib/test/decimaltestdata/dqMinMag.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/dqMinMag.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,293 @@ +------------------------------------------------------------------------ +-- dqMinMag.decTest -- decQuad minnummag -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- we assume that base comparison is tested in compare.decTest, so +-- these mainly cover special cases and rounding +extended: 1 +clamp: 1 +precision: 34 +maxExponent: 6144 +minExponent: -6143 +rounding: half_even + +-- sanity checks +dqmng001 minmag -2 -2 -> -2 +dqmng002 minmag -2 -1 -> -1 +dqmng003 minmag -2 0 -> 0 +dqmng004 minmag -2 1 -> 1 +dqmng005 minmag -2 2 -> -2 +dqmng006 minmag -1 -2 -> -1 +dqmng007 minmag -1 -1 -> -1 +dqmng008 minmag -1 0 -> 0 +dqmng009 minmag -1 1 -> -1 +dqmng010 minmag -1 2 -> -1 +dqmng011 minmag 0 -2 -> 0 +dqmng012 minmag 0 -1 -> 0 +dqmng013 minmag 0 0 -> 0 +dqmng014 minmag 0 1 -> 0 +dqmng015 minmag 0 2 -> 0 +dqmng016 minmag 1 -2 -> 1 +dqmng017 minmag 1 -1 -> -1 +dqmng018 minmag 1 0 -> 0 +dqmng019 minmag 1 1 -> 1 +dqmng020 minmag 1 2 -> 1 +dqmng021 minmag 2 -2 -> -2 +dqmng022 minmag 2 -1 -> -1 +dqmng023 minmag 2 0 -> 0 +dqmng025 minmag 2 1 -> 1 +dqmng026 minmag 2 2 -> 2 + +-- extended zeros +dqmng030 minmag 0 0 -> 0 +dqmng031 minmag 0 -0 -> -0 +dqmng032 minmag 0 -0.0 -> -0.0 +dqmng033 minmag 0 0.0 -> 0.0 +dqmng034 minmag -0 0 -> -0 +dqmng035 minmag -0 -0 -> -0 +dqmng036 minmag -0 -0.0 -> -0 +dqmng037 minmag -0 0.0 -> -0 +dqmng038 minmag 0.0 0 -> 0.0 +dqmng039 minmag 0.0 -0 -> -0 +dqmng040 minmag 0.0 -0.0 -> -0.0 +dqmng041 minmag 0.0 0.0 -> 0.0 +dqmng042 minmag -0.0 0 -> -0.0 +dqmng043 minmag -0.0 -0 -> -0 +dqmng044 minmag -0.0 -0.0 -> -0.0 +dqmng045 minmag -0.0 0.0 -> -0.0 + +dqmng046 minmag 0E1 -0E1 -> -0E+1 +dqmng047 minmag -0E1 0E2 -> -0E+1 +dqmng048 minmag 0E2 0E1 -> 0E+1 +dqmng049 minmag 0E1 0E2 -> 0E+1 +dqmng050 minmag -0E3 -0E2 -> -0E+3 +dqmng051 minmag -0E2 -0E3 -> -0E+3 + +-- Specials +dqmng090 minmag Inf -Inf -> -Infinity +dqmng091 minmag Inf -1000 -> -1000 +dqmng092 minmag Inf -1 -> -1 +dqmng093 minmag Inf -0 -> -0 +dqmng094 minmag Inf 0 -> 0 +dqmng095 minmag Inf 1 -> 1 +dqmng096 minmag Inf 1000 -> 1000 +dqmng097 minmag Inf Inf -> Infinity +dqmng098 minmag -1000 Inf -> -1000 +dqmng099 minmag -Inf Inf -> -Infinity +dqmng100 minmag -1 Inf -> -1 +dqmng101 minmag -0 Inf -> -0 +dqmng102 minmag 0 Inf -> 0 +dqmng103 minmag 1 Inf -> 1 +dqmng104 minmag 1000 Inf -> 1000 +dqmng105 minmag Inf Inf -> Infinity + +dqmng120 minmag -Inf -Inf -> -Infinity +dqmng121 minmag -Inf -1000 -> -1000 +dqmng122 minmag -Inf -1 -> -1 +dqmng123 minmag -Inf -0 -> -0 +dqmng124 minmag -Inf 0 -> 0 +dqmng125 minmag -Inf 1 -> 1 +dqmng126 minmag -Inf 1000 -> 1000 +dqmng127 minmag -Inf Inf -> -Infinity +dqmng128 minmag -Inf -Inf -> -Infinity +dqmng129 minmag -1000 -Inf -> -1000 +dqmng130 minmag -1 -Inf -> -1 +dqmng131 minmag -0 -Inf -> -0 +dqmng132 minmag 0 -Inf -> 0 +dqmng133 minmag 1 -Inf -> 1 +dqmng134 minmag 1000 -Inf -> 1000 +dqmng135 minmag Inf -Inf -> -Infinity + +-- 2004.08.02 754r chooses number over NaN in mixed cases +dqmng141 minmag NaN -Inf -> -Infinity +dqmng142 minmag NaN -1000 -> -1000 +dqmng143 minmag NaN -1 -> -1 +dqmng144 minmag NaN -0 -> -0 +dqmng145 minmag NaN 0 -> 0 +dqmng146 minmag NaN 1 -> 1 +dqmng147 minmag NaN 1000 -> 1000 +dqmng148 minmag NaN Inf -> Infinity +dqmng149 minmag NaN NaN -> NaN +dqmng150 minmag -Inf NaN -> -Infinity +dqmng151 minmag -1000 NaN -> -1000 +dqmng152 minmag -1 -NaN -> -1 +dqmng153 minmag -0 NaN -> -0 +dqmng154 minmag 0 -NaN -> 0 +dqmng155 minmag 1 NaN -> 1 +dqmng156 minmag 1000 NaN -> 1000 +dqmng157 minmag Inf NaN -> Infinity + +dqmng161 minmag sNaN -Inf -> NaN Invalid_operation +dqmng162 minmag sNaN -1000 -> NaN Invalid_operation +dqmng163 minmag sNaN -1 -> NaN Invalid_operation +dqmng164 minmag sNaN -0 -> NaN Invalid_operation +dqmng165 minmag -sNaN 0 -> -NaN Invalid_operation +dqmng166 minmag -sNaN 1 -> -NaN Invalid_operation +dqmng167 minmag sNaN 1000 -> NaN Invalid_operation +dqmng168 minmag sNaN NaN -> NaN Invalid_operation +dqmng169 minmag sNaN sNaN -> NaN Invalid_operation +dqmng170 minmag NaN sNaN -> NaN Invalid_operation +dqmng171 minmag -Inf sNaN -> NaN Invalid_operation +dqmng172 minmag -1000 sNaN -> NaN Invalid_operation +dqmng173 minmag -1 sNaN -> NaN Invalid_operation +dqmng174 minmag -0 sNaN -> NaN Invalid_operation +dqmng175 minmag 0 sNaN -> NaN Invalid_operation +dqmng176 minmag 1 sNaN -> NaN Invalid_operation +dqmng177 minmag 1000 sNaN -> NaN Invalid_operation +dqmng178 minmag Inf sNaN -> NaN Invalid_operation +dqmng179 minmag NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +dqmng181 minmag NaN9 -Inf -> -Infinity +dqmng182 minmag -NaN8 9990 -> 9990 +dqmng183 minmag NaN71 Inf -> Infinity + +dqmng184 minmag NaN1 NaN54 -> NaN1 +dqmng185 minmag NaN22 -NaN53 -> NaN22 +dqmng186 minmag -NaN3 NaN6 -> -NaN3 +dqmng187 minmag -NaN44 NaN7 -> -NaN44 + +dqmng188 minmag -Inf NaN41 -> -Infinity +dqmng189 minmag -9999 -NaN33 -> -9999 +dqmng190 minmag Inf NaN2 -> Infinity + +dqmng191 minmag sNaN99 -Inf -> NaN99 Invalid_operation +dqmng192 minmag sNaN98 -11 -> NaN98 Invalid_operation +dqmng193 minmag -sNaN97 NaN8 -> -NaN97 Invalid_operation +dqmng194 minmag sNaN69 sNaN94 -> NaN69 Invalid_operation +dqmng195 minmag NaN95 sNaN93 -> NaN93 Invalid_operation +dqmng196 minmag -Inf sNaN92 -> NaN92 Invalid_operation +dqmng197 minmag 088 sNaN91 -> NaN91 Invalid_operation +dqmng198 minmag Inf -sNaN90 -> -NaN90 Invalid_operation +dqmng199 minmag NaN sNaN86 -> NaN86 Invalid_operation + +-- old rounding checks +dqmng221 minmag -12345678000 1 -> 1 +dqmng222 minmag 1 -12345678000 -> 1 +dqmng223 minmag -1234567800 1 -> 1 +dqmng224 minmag 1 -1234567800 -> 1 +dqmng225 minmag -1234567890 1 -> 1 +dqmng226 minmag 1 -1234567890 -> 1 +dqmng227 minmag -1234567891 1 -> 1 +dqmng228 minmag 1 -1234567891 -> 1 +dqmng229 minmag -12345678901 1 -> 1 +dqmng230 minmag 1 -12345678901 -> 1 +dqmng231 minmag -1234567896 1 -> 1 +dqmng232 minmag 1 -1234567896 -> 1 +dqmng233 minmag 1234567891 1 -> 1 +dqmng234 minmag 1 1234567891 -> 1 +dqmng235 minmag 12345678901 1 -> 1 +dqmng236 minmag 1 12345678901 -> 1 +dqmng237 minmag 1234567896 1 -> 1 +dqmng238 minmag 1 1234567896 -> 1 + +-- from examples +dqmng280 minmag '3' '2' -> '2' +dqmng281 minmag '-10' '3' -> '3' +dqmng282 minmag '1.0' '1' -> '1.0' +dqmng283 minmag '1' '1.0' -> '1.0' +dqmng284 minmag '7' 'NaN' -> '7' + +-- expanded list from min/max 754r purple prose +-- [explicit tests for exponent ordering] +dqmng401 minmag Inf 1.1 -> 1.1 +dqmng402 minmag 1.1 1 -> 1 +dqmng403 minmag 1 1.0 -> 1.0 +dqmng404 minmag 1.0 0.1 -> 0.1 +dqmng405 minmag 0.1 0.10 -> 0.10 +dqmng406 minmag 0.10 0.100 -> 0.100 +dqmng407 minmag 0.10 0 -> 0 +dqmng408 minmag 0 0.0 -> 0.0 +dqmng409 minmag 0.0 -0 -> -0 +dqmng410 minmag 0.0 -0.0 -> -0.0 +dqmng411 minmag 0.00 -0.0 -> -0.0 +dqmng412 minmag 0.0 -0.00 -> -0.00 +dqmng413 minmag 0 -0.0 -> -0.0 +dqmng414 minmag 0 -0 -> -0 +dqmng415 minmag -0.0 -0 -> -0 +dqmng416 minmag -0 -0.100 -> -0 +dqmng417 minmag -0.100 -0.10 -> -0.10 +dqmng418 minmag -0.10 -0.1 -> -0.1 +dqmng419 minmag -0.1 -1.0 -> -0.1 +dqmng420 minmag -1.0 -1 -> -1 +dqmng421 minmag -1 -1.1 -> -1 +dqmng423 minmag -1.1 -Inf -> -1.1 +-- same with operands reversed +dqmng431 minmag 1.1 Inf -> 1.1 +dqmng432 minmag 1 1.1 -> 1 +dqmng433 minmag 1.0 1 -> 1.0 +dqmng434 minmag 0.1 1.0 -> 0.1 +dqmng435 minmag 0.10 0.1 -> 0.10 +dqmng436 minmag 0.100 0.10 -> 0.100 +dqmng437 minmag 0 0.10 -> 0 +dqmng438 minmag 0.0 0 -> 0.0 +dqmng439 minmag -0 0.0 -> -0 +dqmng440 minmag -0.0 0.0 -> -0.0 +dqmng441 minmag -0.0 0.00 -> -0.0 +dqmng442 minmag -0.00 0.0 -> -0.00 +dqmng443 minmag -0.0 0 -> -0.0 +dqmng444 minmag -0 0 -> -0 +dqmng445 minmag -0 -0.0 -> -0 +dqmng446 minmag -0.100 -0 -> -0 +dqmng447 minmag -0.10 -0.100 -> -0.10 +dqmng448 minmag -0.1 -0.10 -> -0.1 +dqmng449 minmag -1.0 -0.1 -> -0.1 +dqmng450 minmag -1 -1.0 -> -1 +dqmng451 minmag -1.1 -1 -> -1 +dqmng453 minmag -Inf -1.1 -> -1.1 +-- largies +dqmng460 minmag 1000 1E+3 -> 1000 +dqmng461 minmag 1E+3 1000 -> 1000 +dqmng462 minmag 1000 -1E+3 -> -1E+3 +dqmng463 minmag 1E+3 -384 -> -384 +dqmng464 minmag -384 1E+3 -> -384 +dqmng465 minmag -1E+3 1000 -> -1E+3 +dqmng466 minmag -384 -1E+3 -> -384 +dqmng467 minmag -1E+3 -384 -> -384 + +-- subnormals +dqmng510 minmag 1.00E-6143 0 -> 0 +dqmng511 minmag 0.1E-6143 0 -> 0 +dqmng512 minmag 0.10E-6143 0 -> 0 +dqmng513 minmag 0.100E-6143 0 -> 0 +dqmng514 minmag 0.01E-6143 0 -> 0 +dqmng515 minmag 0.999E-6143 0 -> 0 +dqmng516 minmag 0.099E-6143 0 -> 0 +dqmng517 minmag 0.009E-6143 0 -> 0 +dqmng518 minmag 0.001E-6143 0 -> 0 +dqmng519 minmag 0.0009E-6143 0 -> 0 +dqmng520 minmag 0.0001E-6143 0 -> 0 + +dqmng530 minmag -1.00E-6143 0 -> 0 +dqmng531 minmag -0.1E-6143 0 -> 0 +dqmng532 minmag -0.10E-6143 0 -> 0 +dqmng533 minmag -0.100E-6143 0 -> 0 +dqmng534 minmag -0.01E-6143 0 -> 0 +dqmng535 minmag -0.999E-6143 0 -> 0 +dqmng536 minmag -0.099E-6143 0 -> 0 +dqmng537 minmag -0.009E-6143 0 -> 0 +dqmng538 minmag -0.001E-6143 0 -> 0 +dqmng539 minmag -0.0009E-6143 0 -> 0 +dqmng540 minmag -0.0001E-6143 0 -> 0 + + +-- Null tests +dqmng900 minmag 10 # -> NaN Invalid_operation +dqmng901 minmag # 10 -> NaN Invalid_operation Added: python/branches/release25-maint/Lib/test/decimaltestdata/dqMinus.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/dqMinus.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,88 @@ +------------------------------------------------------------------------ +-- dqMinus.decTest -- decQuad 0-x -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- All operands and results are decQuads. +extended: 1 +clamp: 1 +precision: 34 +maxExponent: 6144 +minExponent: -6143 +rounding: half_even + +-- Sanity check +dqmns001 minus +7.50 -> -7.50 + +-- Infinities +dqmns011 minus Infinity -> -Infinity +dqmns012 minus -Infinity -> Infinity + +-- NaNs, 0 payload +dqmns021 minus NaN -> NaN +dqmns022 minus -NaN -> -NaN +dqmns023 minus sNaN -> NaN Invalid_operation +dqmns024 minus -sNaN -> -NaN Invalid_operation + +-- NaNs, non-0 payload +dqmns031 minus NaN13 -> NaN13 +dqmns032 minus -NaN13 -> -NaN13 +dqmns033 minus sNaN13 -> NaN13 Invalid_operation +dqmns034 minus -sNaN13 -> -NaN13 Invalid_operation +dqmns035 minus NaN70 -> NaN70 +dqmns036 minus -NaN70 -> -NaN70 +dqmns037 minus sNaN101 -> NaN101 Invalid_operation +dqmns038 minus -sNaN101 -> -NaN101 Invalid_operation + +-- finites +dqmns101 minus 7 -> -7 +dqmns102 minus -7 -> 7 +dqmns103 minus 75 -> -75 +dqmns104 minus -75 -> 75 +dqmns105 minus 7.50 -> -7.50 +dqmns106 minus -7.50 -> 7.50 +dqmns107 minus 7.500 -> -7.500 +dqmns108 minus -7.500 -> 7.500 + +-- zeros +dqmns111 minus 0 -> 0 +dqmns112 minus -0 -> 0 +dqmns113 minus 0E+4 -> 0E+4 +dqmns114 minus -0E+4 -> 0E+4 +dqmns115 minus 0.0000 -> 0.0000 +dqmns116 minus -0.0000 -> 0.0000 +dqmns117 minus 0E-141 -> 0E-141 +dqmns118 minus -0E-141 -> 0E-141 + +-- full coefficients, alternating bits +dqmns121 minus 2682682682682682682682682682682682 -> -2682682682682682682682682682682682 +dqmns122 minus -2682682682682682682682682682682682 -> 2682682682682682682682682682682682 +dqmns123 minus 1341341341341341341341341341341341 -> -1341341341341341341341341341341341 +dqmns124 minus -1341341341341341341341341341341341 -> 1341341341341341341341341341341341 + +-- Nmax, Nmin, Ntiny +dqmns131 minus 9.999999999999999999999999999999999E+6144 -> -9.999999999999999999999999999999999E+6144 +dqmns132 minus 1E-6143 -> -1E-6143 +dqmns133 minus 1.000000000000000000000000000000000E-6143 -> -1.000000000000000000000000000000000E-6143 +dqmns134 minus 1E-6176 -> -1E-6176 Subnormal + +dqmns135 minus -1E-6176 -> 1E-6176 Subnormal +dqmns136 minus -1.000000000000000000000000000000000E-6143 -> 1.000000000000000000000000000000000E-6143 +dqmns137 minus -1E-6143 -> 1E-6143 +dqmns138 minus -9.999999999999999999999999999999999E+6144 -> 9.999999999999999999999999999999999E+6144 Added: python/branches/release25-maint/Lib/test/decimaltestdata/dqMultiply.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/dqMultiply.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,589 @@ +------------------------------------------------------------------------ +-- dqMultiply.decTest -- decQuad multiplication -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- This set of tests are for decQuads only; all arguments are +-- representable in a decQuad +extended: 1 +clamp: 1 +precision: 34 +maxExponent: 6144 +minExponent: -6143 +rounding: half_even + +-- sanity checks +dqmul000 multiply 2 2 -> 4 +dqmul001 multiply 2 3 -> 6 +dqmul002 multiply 5 1 -> 5 +dqmul003 multiply 5 2 -> 10 +dqmul004 multiply 1.20 2 -> 2.40 +dqmul005 multiply 1.20 0 -> 0.00 +dqmul006 multiply 1.20 -2 -> -2.40 +dqmul007 multiply -1.20 2 -> -2.40 +dqmul008 multiply -1.20 0 -> -0.00 +dqmul009 multiply -1.20 -2 -> 2.40 +dqmul010 multiply 5.09 7.1 -> 36.139 +dqmul011 multiply 2.5 4 -> 10.0 +dqmul012 multiply 2.50 4 -> 10.00 +dqmul013 multiply 1.23456789 1.0000000000000000000000000000 -> 1.234567890000000000000000000000000 Rounded +dqmul015 multiply 2.50 4 -> 10.00 +dqmul016 multiply 9.99999999999999999 9.99999999999999999 -> 99.99999999999999980000000000000000 Inexact Rounded +dqmul017 multiply 9.99999999999999999 -9.99999999999999999 -> -99.99999999999999980000000000000000 Inexact Rounded +dqmul018 multiply -9.99999999999999999 9.99999999999999999 -> -99.99999999999999980000000000000000 Inexact Rounded +dqmul019 multiply -9.99999999999999999 -9.99999999999999999 -> 99.99999999999999980000000000000000 Inexact Rounded + +-- zeros, etc. +dqmul021 multiply 0 0 -> 0 +dqmul022 multiply 0 -0 -> -0 +dqmul023 multiply -0 0 -> -0 +dqmul024 multiply -0 -0 -> 0 +dqmul025 multiply -0.0 -0.0 -> 0.00 +dqmul026 multiply -0.0 -0.0 -> 0.00 +dqmul027 multiply -0.0 -0.0 -> 0.00 +dqmul028 multiply -0.0 -0.0 -> 0.00 +dqmul030 multiply 5.00 1E-3 -> 0.00500 +dqmul031 multiply 00.00 0.000 -> 0.00000 +dqmul032 multiply 00.00 0E-3 -> 0.00000 -- rhs is 0 +dqmul033 multiply 0E-3 00.00 -> 0.00000 -- lhs is 0 +dqmul034 multiply -5.00 1E-3 -> -0.00500 +dqmul035 multiply -00.00 0.000 -> -0.00000 +dqmul036 multiply -00.00 0E-3 -> -0.00000 -- rhs is 0 +dqmul037 multiply -0E-3 00.00 -> -0.00000 -- lhs is 0 +dqmul038 multiply 5.00 -1E-3 -> -0.00500 +dqmul039 multiply 00.00 -0.000 -> -0.00000 +dqmul040 multiply 00.00 -0E-3 -> -0.00000 -- rhs is 0 +dqmul041 multiply 0E-3 -00.00 -> -0.00000 -- lhs is 0 +dqmul042 multiply -5.00 -1E-3 -> 0.00500 +dqmul043 multiply -00.00 -0.000 -> 0.00000 +dqmul044 multiply -00.00 -0E-3 -> 0.00000 -- rhs is 0 +dqmul045 multiply -0E-3 -00.00 -> 0.00000 -- lhs is 0 + +-- examples from decarith +dqmul050 multiply 1.20 3 -> 3.60 +dqmul051 multiply 7 3 -> 21 +dqmul052 multiply 0.9 0.8 -> 0.72 +dqmul053 multiply 0.9 -0 -> -0.0 +dqmul054 multiply 654321 654321 -> 428135971041 + +dqmul060 multiply 123.45 1e7 -> 1.2345E+9 +dqmul061 multiply 123.45 1e8 -> 1.2345E+10 +dqmul062 multiply 123.45 1e+9 -> 1.2345E+11 +dqmul063 multiply 123.45 1e10 -> 1.2345E+12 +dqmul064 multiply 123.45 1e11 -> 1.2345E+13 +dqmul065 multiply 123.45 1e12 -> 1.2345E+14 +dqmul066 multiply 123.45 1e13 -> 1.2345E+15 + + +-- test some intermediate lengths +-- 1234567890123456 +dqmul080 multiply 0.1 1230123456456789 -> 123012345645678.9 +dqmul084 multiply 0.1 1230123456456789 -> 123012345645678.9 +dqmul090 multiply 1230123456456789 0.1 -> 123012345645678.9 +dqmul094 multiply 1230123456456789 0.1 -> 123012345645678.9 + +-- test some more edge cases and carries +dqmul101 multiply 9 9 -> 81 +dqmul102 multiply 9 90 -> 810 +dqmul103 multiply 9 900 -> 8100 +dqmul104 multiply 9 9000 -> 81000 +dqmul105 multiply 9 90000 -> 810000 +dqmul106 multiply 9 900000 -> 8100000 +dqmul107 multiply 9 9000000 -> 81000000 +dqmul108 multiply 9 90000000 -> 810000000 +dqmul109 multiply 9 900000000 -> 8100000000 +dqmul110 multiply 9 9000000000 -> 81000000000 +dqmul111 multiply 9 90000000000 -> 810000000000 +dqmul112 multiply 9 900000000000 -> 8100000000000 +dqmul113 multiply 9 9000000000000 -> 81000000000000 +dqmul114 multiply 9 90000000000000 -> 810000000000000 +dqmul115 multiply 9 900000000000000 -> 8100000000000000 +--dqmul116 multiply 9 9000000000000000 -> 81000000000000000 +--dqmul117 multiply 9 90000000000000000 -> 810000000000000000 +--dqmul118 multiply 9 900000000000000000 -> 8100000000000000000 +--dqmul119 multiply 9 9000000000000000000 -> 81000000000000000000 +--dqmul120 multiply 9 90000000000000000000 -> 810000000000000000000 +--dqmul121 multiply 9 900000000000000000000 -> 8100000000000000000000 +--dqmul122 multiply 9 9000000000000000000000 -> 81000000000000000000000 +--dqmul123 multiply 9 90000000000000000000000 -> 810000000000000000000000 +-- test some more edge cases without carries +dqmul131 multiply 3 3 -> 9 +dqmul132 multiply 3 30 -> 90 +dqmul133 multiply 3 300 -> 900 +dqmul134 multiply 3 3000 -> 9000 +dqmul135 multiply 3 30000 -> 90000 +dqmul136 multiply 3 300000 -> 900000 +dqmul137 multiply 3 3000000 -> 9000000 +dqmul138 multiply 3 30000000 -> 90000000 +dqmul139 multiply 3 300000000 -> 900000000 +dqmul140 multiply 3 3000000000 -> 9000000000 +dqmul141 multiply 3 30000000000 -> 90000000000 +dqmul142 multiply 3 300000000000 -> 900000000000 +dqmul143 multiply 3 3000000000000 -> 9000000000000 +dqmul144 multiply 3 30000000000000 -> 90000000000000 +dqmul145 multiply 3 300000000000000 -> 900000000000000 +dqmul146 multiply 3 3000000000000000 -> 9000000000000000 +dqmul147 multiply 3 30000000000000000 -> 90000000000000000 +dqmul148 multiply 3 300000000000000000 -> 900000000000000000 +dqmul149 multiply 3 3000000000000000000 -> 9000000000000000000 +dqmul150 multiply 3 30000000000000000000 -> 90000000000000000000 +dqmul151 multiply 3 300000000000000000000 -> 900000000000000000000 +dqmul152 multiply 3 3000000000000000000000 -> 9000000000000000000000 +dqmul153 multiply 3 30000000000000000000000 -> 90000000000000000000000 + +dqmul263 multiply 30269.587755640502150977251770554 4.8046009735990873395936309640543 -> 145433.2908011933696719165119928296 Inexact Rounded + +-- test some edge cases with exact rounding +dqmul301 multiply 900000000000000000 9 -> 8100000000000000000 +dqmul302 multiply 900000000000000000 90 -> 81000000000000000000 +dqmul303 multiply 900000000000000000 900 -> 810000000000000000000 +dqmul304 multiply 900000000000000000 9000 -> 8100000000000000000000 +dqmul305 multiply 900000000000000000 90000 -> 81000000000000000000000 +dqmul306 multiply 900000000000000000 900000 -> 810000000000000000000000 +dqmul307 multiply 900000000000000000 9000000 -> 8100000000000000000000000 +dqmul308 multiply 900000000000000000 90000000 -> 81000000000000000000000000 +dqmul309 multiply 900000000000000000 900000000 -> 810000000000000000000000000 +dqmul310 multiply 900000000000000000 9000000000 -> 8100000000000000000000000000 +dqmul311 multiply 900000000000000000 90000000000 -> 81000000000000000000000000000 +dqmul312 multiply 900000000000000000 900000000000 -> 810000000000000000000000000000 +dqmul313 multiply 900000000000000000 9000000000000 -> 8100000000000000000000000000000 +dqmul314 multiply 900000000000000000 90000000000000 -> 81000000000000000000000000000000 +dqmul315 multiply 900000000000000000 900000000000000 -> 810000000000000000000000000000000 +dqmul316 multiply 900000000000000000 9000000000000000 -> 8100000000000000000000000000000000 +dqmul317 multiply 9000000000000000000 9000000000000000 -> 8.100000000000000000000000000000000E+34 Rounded +dqmul318 multiply 90000000000000000000 9000000000000000 -> 8.100000000000000000000000000000000E+35 Rounded +dqmul319 multiply 900000000000000000000 9000000000000000 -> 8.100000000000000000000000000000000E+36 Rounded +dqmul320 multiply 9000000000000000000000 9000000000000000 -> 8.100000000000000000000000000000000E+37 Rounded +dqmul321 multiply 90000000000000000000000 9000000000000000 -> 8.100000000000000000000000000000000E+38 Rounded +dqmul322 multiply 900000000000000000000000 9000000000000000 -> 8.100000000000000000000000000000000E+39 Rounded +dqmul323 multiply 9000000000000000000000000 9000000000000000 -> 8.100000000000000000000000000000000E+40 Rounded + +-- tryzeros cases +dqmul504 multiply 0E-4260 1000E-4260 -> 0E-6176 Clamped +dqmul505 multiply 100E+4260 0E+4260 -> 0E+6111 Clamped + +-- mixed with zeros +dqmul541 multiply 0 -1 -> -0 +dqmul542 multiply -0 -1 -> 0 +dqmul543 multiply 0 1 -> 0 +dqmul544 multiply -0 1 -> -0 +dqmul545 multiply -1 0 -> -0 +dqmul546 multiply -1 -0 -> 0 +dqmul547 multiply 1 0 -> 0 +dqmul548 multiply 1 -0 -> -0 + +dqmul551 multiply 0.0 -1 -> -0.0 +dqmul552 multiply -0.0 -1 -> 0.0 +dqmul553 multiply 0.0 1 -> 0.0 +dqmul554 multiply -0.0 1 -> -0.0 +dqmul555 multiply -1.0 0 -> -0.0 +dqmul556 multiply -1.0 -0 -> 0.0 +dqmul557 multiply 1.0 0 -> 0.0 +dqmul558 multiply 1.0 -0 -> -0.0 + +dqmul561 multiply 0 -1.0 -> -0.0 +dqmul562 multiply -0 -1.0 -> 0.0 +dqmul563 multiply 0 1.0 -> 0.0 +dqmul564 multiply -0 1.0 -> -0.0 +dqmul565 multiply -1 0.0 -> -0.0 +dqmul566 multiply -1 -0.0 -> 0.0 +dqmul567 multiply 1 0.0 -> 0.0 +dqmul568 multiply 1 -0.0 -> -0.0 + +dqmul571 multiply 0.0 -1.0 -> -0.00 +dqmul572 multiply -0.0 -1.0 -> 0.00 +dqmul573 multiply 0.0 1.0 -> 0.00 +dqmul574 multiply -0.0 1.0 -> -0.00 +dqmul575 multiply -1.0 0.0 -> -0.00 +dqmul576 multiply -1.0 -0.0 -> 0.00 +dqmul577 multiply 1.0 0.0 -> 0.00 +dqmul578 multiply 1.0 -0.0 -> -0.00 + + +-- Specials +dqmul580 multiply Inf -Inf -> -Infinity +dqmul581 multiply Inf -1000 -> -Infinity +dqmul582 multiply Inf -1 -> -Infinity +dqmul583 multiply Inf -0 -> NaN Invalid_operation +dqmul584 multiply Inf 0 -> NaN Invalid_operation +dqmul585 multiply Inf 1 -> Infinity +dqmul586 multiply Inf 1000 -> Infinity +dqmul587 multiply Inf Inf -> Infinity +dqmul588 multiply -1000 Inf -> -Infinity +dqmul589 multiply -Inf Inf -> -Infinity +dqmul590 multiply -1 Inf -> -Infinity +dqmul591 multiply -0 Inf -> NaN Invalid_operation +dqmul592 multiply 0 Inf -> NaN Invalid_operation +dqmul593 multiply 1 Inf -> Infinity +dqmul594 multiply 1000 Inf -> Infinity +dqmul595 multiply Inf Inf -> Infinity + +dqmul600 multiply -Inf -Inf -> Infinity +dqmul601 multiply -Inf -1000 -> Infinity +dqmul602 multiply -Inf -1 -> Infinity +dqmul603 multiply -Inf -0 -> NaN Invalid_operation +dqmul604 multiply -Inf 0 -> NaN Invalid_operation +dqmul605 multiply -Inf 1 -> -Infinity +dqmul606 multiply -Inf 1000 -> -Infinity +dqmul607 multiply -Inf Inf -> -Infinity +dqmul608 multiply -1000 Inf -> -Infinity +dqmul609 multiply -Inf -Inf -> Infinity +dqmul610 multiply -1 -Inf -> Infinity +dqmul611 multiply -0 -Inf -> NaN Invalid_operation +dqmul612 multiply 0 -Inf -> NaN Invalid_operation +dqmul613 multiply 1 -Inf -> -Infinity +dqmul614 multiply 1000 -Inf -> -Infinity +dqmul615 multiply Inf -Inf -> -Infinity + +dqmul621 multiply NaN -Inf -> NaN +dqmul622 multiply NaN -1000 -> NaN +dqmul623 multiply NaN -1 -> NaN +dqmul624 multiply NaN -0 -> NaN +dqmul625 multiply NaN 0 -> NaN +dqmul626 multiply NaN 1 -> NaN +dqmul627 multiply NaN 1000 -> NaN +dqmul628 multiply NaN Inf -> NaN +dqmul629 multiply NaN NaN -> NaN +dqmul630 multiply -Inf NaN -> NaN +dqmul631 multiply -1000 NaN -> NaN +dqmul632 multiply -1 NaN -> NaN +dqmul633 multiply -0 NaN -> NaN +dqmul634 multiply 0 NaN -> NaN +dqmul635 multiply 1 NaN -> NaN +dqmul636 multiply 1000 NaN -> NaN +dqmul637 multiply Inf NaN -> NaN + +dqmul641 multiply sNaN -Inf -> NaN Invalid_operation +dqmul642 multiply sNaN -1000 -> NaN Invalid_operation +dqmul643 multiply sNaN -1 -> NaN Invalid_operation +dqmul644 multiply sNaN -0 -> NaN Invalid_operation +dqmul645 multiply sNaN 0 -> NaN Invalid_operation +dqmul646 multiply sNaN 1 -> NaN Invalid_operation +dqmul647 multiply sNaN 1000 -> NaN Invalid_operation +dqmul648 multiply sNaN NaN -> NaN Invalid_operation +dqmul649 multiply sNaN sNaN -> NaN Invalid_operation +dqmul650 multiply NaN sNaN -> NaN Invalid_operation +dqmul651 multiply -Inf sNaN -> NaN Invalid_operation +dqmul652 multiply -1000 sNaN -> NaN Invalid_operation +dqmul653 multiply -1 sNaN -> NaN Invalid_operation +dqmul654 multiply -0 sNaN -> NaN Invalid_operation +dqmul655 multiply 0 sNaN -> NaN Invalid_operation +dqmul656 multiply 1 sNaN -> NaN Invalid_operation +dqmul657 multiply 1000 sNaN -> NaN Invalid_operation +dqmul658 multiply Inf sNaN -> NaN Invalid_operation +dqmul659 multiply NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +dqmul661 multiply NaN9 -Inf -> NaN9 +dqmul662 multiply NaN8 999 -> NaN8 +dqmul663 multiply NaN71 Inf -> NaN71 +dqmul664 multiply NaN6 NaN5 -> NaN6 +dqmul665 multiply -Inf NaN4 -> NaN4 +dqmul666 multiply -999 NaN33 -> NaN33 +dqmul667 multiply Inf NaN2 -> NaN2 + +dqmul671 multiply sNaN99 -Inf -> NaN99 Invalid_operation +dqmul672 multiply sNaN98 -11 -> NaN98 Invalid_operation +dqmul673 multiply sNaN97 NaN -> NaN97 Invalid_operation +dqmul674 multiply sNaN16 sNaN94 -> NaN16 Invalid_operation +dqmul675 multiply NaN95 sNaN93 -> NaN93 Invalid_operation +dqmul676 multiply -Inf sNaN92 -> NaN92 Invalid_operation +dqmul677 multiply 088 sNaN91 -> NaN91 Invalid_operation +dqmul678 multiply Inf sNaN90 -> NaN90 Invalid_operation +dqmul679 multiply NaN sNaN89 -> NaN89 Invalid_operation + +dqmul681 multiply -NaN9 -Inf -> -NaN9 +dqmul682 multiply -NaN8 999 -> -NaN8 +dqmul683 multiply -NaN71 Inf -> -NaN71 +dqmul684 multiply -NaN6 -NaN5 -> -NaN6 +dqmul685 multiply -Inf -NaN4 -> -NaN4 +dqmul686 multiply -999 -NaN33 -> -NaN33 +dqmul687 multiply Inf -NaN2 -> -NaN2 + +dqmul691 multiply -sNaN99 -Inf -> -NaN99 Invalid_operation +dqmul692 multiply -sNaN98 -11 -> -NaN98 Invalid_operation +dqmul693 multiply -sNaN97 NaN -> -NaN97 Invalid_operation +dqmul694 multiply -sNaN16 -sNaN94 -> -NaN16 Invalid_operation +dqmul695 multiply -NaN95 -sNaN93 -> -NaN93 Invalid_operation +dqmul696 multiply -Inf -sNaN92 -> -NaN92 Invalid_operation +dqmul697 multiply 088 -sNaN91 -> -NaN91 Invalid_operation +dqmul698 multiply Inf -sNaN90 -> -NaN90 Invalid_operation +dqmul699 multiply -NaN -sNaN89 -> -NaN89 Invalid_operation + +dqmul701 multiply -NaN -Inf -> -NaN +dqmul702 multiply -NaN 999 -> -NaN +dqmul703 multiply -NaN Inf -> -NaN +dqmul704 multiply -NaN -NaN -> -NaN +dqmul705 multiply -Inf -NaN0 -> -NaN +dqmul706 multiply -999 -NaN -> -NaN +dqmul707 multiply Inf -NaN -> -NaN + +dqmul711 multiply -sNaN -Inf -> -NaN Invalid_operation +dqmul712 multiply -sNaN -11 -> -NaN Invalid_operation +dqmul713 multiply -sNaN00 NaN -> -NaN Invalid_operation +dqmul714 multiply -sNaN -sNaN -> -NaN Invalid_operation +dqmul715 multiply -NaN -sNaN -> -NaN Invalid_operation +dqmul716 multiply -Inf -sNaN -> -NaN Invalid_operation +dqmul717 multiply 088 -sNaN -> -NaN Invalid_operation +dqmul718 multiply Inf -sNaN -> -NaN Invalid_operation +dqmul719 multiply -NaN -sNaN -> -NaN Invalid_operation + +-- overflow and underflow tests .. note subnormal results +-- signs +dqmul751 multiply 1e+4277 1e+3311 -> Infinity Overflow Inexact Rounded +dqmul752 multiply 1e+4277 -1e+3311 -> -Infinity Overflow Inexact Rounded +dqmul753 multiply -1e+4277 1e+3311 -> -Infinity Overflow Inexact Rounded +dqmul754 multiply -1e+4277 -1e+3311 -> Infinity Overflow Inexact Rounded +dqmul755 multiply 1e-4277 1e-3311 -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqmul756 multiply 1e-4277 -1e-3311 -> -0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqmul757 multiply -1e-4277 1e-3311 -> -0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqmul758 multiply -1e-4277 -1e-3311 -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped + +-- 'subnormal' boundary (all hard underflow or overflow in base arithemtic) +dqmul760 multiply 1e-6069 1e-101 -> 1E-6170 Subnormal +dqmul761 multiply 1e-6069 1e-102 -> 1E-6171 Subnormal +dqmul762 multiply 1e-6069 1e-103 -> 1E-6172 Subnormal +dqmul763 multiply 1e-6069 1e-104 -> 1E-6173 Subnormal +dqmul764 multiply 1e-6069 1e-105 -> 1E-6174 Subnormal +dqmul765 multiply 1e-6069 1e-106 -> 1E-6175 Subnormal +dqmul766 multiply 1e-6069 1e-107 -> 1E-6176 Subnormal +dqmul767 multiply 1e-6069 1e-108 -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqmul768 multiply 1e-6069 1e-109 -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqmul769 multiply 1e-6069 1e-110 -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped +-- [no equivalent of 'subnormal' for overflow] +dqmul770 multiply 1e+40 1e+6101 -> 1.000000000000000000000000000000E+6141 Clamped +dqmul771 multiply 1e+40 1e+6102 -> 1.0000000000000000000000000000000E+6142 Clamped +dqmul772 multiply 1e+40 1e+6103 -> 1.00000000000000000000000000000000E+6143 Clamped +dqmul773 multiply 1e+40 1e+6104 -> 1.000000000000000000000000000000000E+6144 Clamped +dqmul774 multiply 1e+40 1e+6105 -> Infinity Overflow Inexact Rounded +dqmul775 multiply 1e+40 1e+6106 -> Infinity Overflow Inexact Rounded +dqmul776 multiply 1e+40 1e+6107 -> Infinity Overflow Inexact Rounded +dqmul777 multiply 1e+40 1e+6108 -> Infinity Overflow Inexact Rounded +dqmul778 multiply 1e+40 1e+6109 -> Infinity Overflow Inexact Rounded +dqmul779 multiply 1e+40 1e+6110 -> Infinity Overflow Inexact Rounded + +dqmul801 multiply 1.0000E-6172 1 -> 1.0000E-6172 Subnormal +dqmul802 multiply 1.000E-6172 1e-1 -> 1.000E-6173 Subnormal +dqmul803 multiply 1.00E-6172 1e-2 -> 1.00E-6174 Subnormal +dqmul804 multiply 1.0E-6172 1e-3 -> 1.0E-6175 Subnormal +dqmul805 multiply 1.0E-6172 1e-4 -> 1E-6176 Subnormal Rounded +dqmul806 multiply 1.3E-6172 1e-4 -> 1E-6176 Underflow Subnormal Inexact Rounded +dqmul807 multiply 1.5E-6172 1e-4 -> 2E-6176 Underflow Subnormal Inexact Rounded +dqmul808 multiply 1.7E-6172 1e-4 -> 2E-6176 Underflow Subnormal Inexact Rounded +dqmul809 multiply 2.3E-6172 1e-4 -> 2E-6176 Underflow Subnormal Inexact Rounded +dqmul810 multiply 2.5E-6172 1e-4 -> 2E-6176 Underflow Subnormal Inexact Rounded +dqmul811 multiply 2.7E-6172 1e-4 -> 3E-6176 Underflow Subnormal Inexact Rounded +dqmul812 multiply 1.49E-6172 1e-4 -> 1E-6176 Underflow Subnormal Inexact Rounded +dqmul813 multiply 1.50E-6172 1e-4 -> 2E-6176 Underflow Subnormal Inexact Rounded +dqmul814 multiply 1.51E-6172 1e-4 -> 2E-6176 Underflow Subnormal Inexact Rounded +dqmul815 multiply 2.49E-6172 1e-4 -> 2E-6176 Underflow Subnormal Inexact Rounded +dqmul816 multiply 2.50E-6172 1e-4 -> 2E-6176 Underflow Subnormal Inexact Rounded +dqmul817 multiply 2.51E-6172 1e-4 -> 3E-6176 Underflow Subnormal Inexact Rounded + +dqmul818 multiply 1E-6172 1e-4 -> 1E-6176 Subnormal +dqmul819 multiply 3E-6172 1e-5 -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqmul820 multiply 5E-6172 1e-5 -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqmul821 multiply 7E-6172 1e-5 -> 1E-6176 Underflow Subnormal Inexact Rounded +dqmul822 multiply 9E-6172 1e-5 -> 1E-6176 Underflow Subnormal Inexact Rounded +dqmul823 multiply 9.9E-6172 1e-5 -> 1E-6176 Underflow Subnormal Inexact Rounded + +dqmul824 multiply 1E-6172 -1e-4 -> -1E-6176 Subnormal +dqmul825 multiply 3E-6172 -1e-5 -> -0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqmul826 multiply -5E-6172 1e-5 -> -0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqmul827 multiply 7E-6172 -1e-5 -> -1E-6176 Underflow Subnormal Inexact Rounded +dqmul828 multiply -9E-6172 1e-5 -> -1E-6176 Underflow Subnormal Inexact Rounded +dqmul829 multiply 9.9E-6172 -1e-5 -> -1E-6176 Underflow Subnormal Inexact Rounded +dqmul830 multiply 3.0E-6172 -1e-5 -> -0E-6176 Underflow Subnormal Inexact Rounded Clamped + +dqmul831 multiply 1.0E-5977 1e-200 -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqmul832 multiply 1.0E-5977 1e-199 -> 1E-6176 Subnormal Rounded +dqmul833 multiply 1.0E-5977 1e-198 -> 1.0E-6175 Subnormal +dqmul834 multiply 2.0E-5977 2e-198 -> 4.0E-6175 Subnormal +dqmul835 multiply 4.0E-5977 4e-198 -> 1.60E-6174 Subnormal +dqmul836 multiply 10.0E-5977 10e-198 -> 1.000E-6173 Subnormal +dqmul837 multiply 30.0E-5977 30e-198 -> 9.000E-6173 Subnormal +dqmul838 multiply 40.0E-5982 40e-166 -> 1.6000E-6145 Subnormal +dqmul839 multiply 40.0E-5982 40e-165 -> 1.6000E-6144 Subnormal +dqmul840 multiply 40.0E-5982 40e-164 -> 1.6000E-6143 + +-- Long operand overflow may be a different path +dqmul870 multiply 100 9.999E+6143 -> Infinity Inexact Overflow Rounded +dqmul871 multiply 100 -9.999E+6143 -> -Infinity Inexact Overflow Rounded +dqmul872 multiply 9.999E+6143 100 -> Infinity Inexact Overflow Rounded +dqmul873 multiply -9.999E+6143 100 -> -Infinity Inexact Overflow Rounded + +-- check for double-rounded subnormals +dqmul881 multiply 1.2347E-6133 1.2347E-40 -> 1.524E-6173 Inexact Rounded Subnormal Underflow +dqmul882 multiply 1.234E-6133 1.234E-40 -> 1.523E-6173 Inexact Rounded Subnormal Underflow +dqmul883 multiply 1.23E-6133 1.23E-40 -> 1.513E-6173 Inexact Rounded Subnormal Underflow +dqmul884 multiply 1.2E-6133 1.2E-40 -> 1.44E-6173 Subnormal +dqmul885 multiply 1.2E-6133 1.2E-41 -> 1.44E-6174 Subnormal +dqmul886 multiply 1.2E-6133 1.2E-42 -> 1.4E-6175 Subnormal Inexact Rounded Underflow +dqmul887 multiply 1.2E-6133 1.3E-42 -> 1.6E-6175 Subnormal Inexact Rounded Underflow +dqmul888 multiply 1.3E-6133 1.3E-42 -> 1.7E-6175 Subnormal Inexact Rounded Underflow +dqmul889 multiply 1.3E-6133 1.3E-43 -> 2E-6176 Subnormal Inexact Rounded Underflow +dqmul890 multiply 1.3E-6134 1.3E-43 -> 0E-6176 Clamped Subnormal Inexact Rounded Underflow + +dqmul891 multiply 1.2345E-39 1.234E-6133 -> 1.5234E-6172 Inexact Rounded Subnormal Underflow +dqmul892 multiply 1.23456E-39 1.234E-6133 -> 1.5234E-6172 Inexact Rounded Subnormal Underflow +dqmul893 multiply 1.2345E-40 1.234E-6133 -> 1.523E-6173 Inexact Rounded Subnormal Underflow +dqmul894 multiply 1.23456E-40 1.234E-6133 -> 1.523E-6173 Inexact Rounded Subnormal Underflow +dqmul895 multiply 1.2345E-41 1.234E-6133 -> 1.52E-6174 Inexact Rounded Subnormal Underflow +dqmul896 multiply 1.23456E-41 1.234E-6133 -> 1.52E-6174 Inexact Rounded Subnormal Underflow + +-- Now explore the case where we get a normal result with Underflow +-- prove operands are exact +dqmul906 multiply 9.999999999999999999999999999999999E-6143 1 -> 9.999999999999999999999999999999999E-6143 +dqmul907 multiply 1 0.09999999999999999999999999999999999 -> 0.09999999999999999999999999999999999 +-- the next rounds to Nmin +dqmul908 multiply 9.999999999999999999999999999999999E-6143 0.09999999999999999999999999999999999 -> 1.000000000000000000000000000000000E-6143 Underflow Inexact Subnormal Rounded + +-- hugest +dqmul909 multiply 9999999999999999999999999999999999 9999999999999999999999999999999999 -> 9.999999999999999999999999999999998E+67 Inexact Rounded +-- VG case +dqmul910 multiply 8.81125000000001349436E-1548 8.000000000000000000E-1550 -> 7.049000000000010795488000000000000E-3097 Rounded + +-- Examples from SQL proposal (Krishna Kulkarni) +precision: 34 +rounding: half_up +maxExponent: 6144 +minExponent: -6143 +dqmul911 multiply 130E-2 120E-2 -> 1.5600 +dqmul912 multiply 130E-2 12E-1 -> 1.560 +dqmul913 multiply 130E-2 1E0 -> 1.30 +dqmul914 multiply 1E2 1E4 -> 1E+6 + +-- power-of-ten edge cases +dqmul1001 multiply 1 10 -> 10 +dqmul1002 multiply 1 100 -> 100 +dqmul1003 multiply 1 1000 -> 1000 +dqmul1004 multiply 1 10000 -> 10000 +dqmul1005 multiply 1 100000 -> 100000 +dqmul1006 multiply 1 1000000 -> 1000000 +dqmul1007 multiply 1 10000000 -> 10000000 +dqmul1008 multiply 1 100000000 -> 100000000 +dqmul1009 multiply 1 1000000000 -> 1000000000 +dqmul1010 multiply 1 10000000000 -> 10000000000 +dqmul1011 multiply 1 100000000000 -> 100000000000 +dqmul1012 multiply 1 1000000000000 -> 1000000000000 +dqmul1013 multiply 1 10000000000000 -> 10000000000000 +dqmul1014 multiply 1 100000000000000 -> 100000000000000 +dqmul1015 multiply 1 1000000000000000 -> 1000000000000000 + +dqmul1016 multiply 1 1000000000000000000 -> 1000000000000000000 +dqmul1017 multiply 1 100000000000000000000000000 -> 100000000000000000000000000 +dqmul1018 multiply 1 1000000000000000000000000000 -> 1000000000000000000000000000 +dqmul1019 multiply 1 10000000000000000000000000000 -> 10000000000000000000000000000 +dqmul1020 multiply 1 1000000000000000000000000000000000 -> 1000000000000000000000000000000000 + +dqmul1021 multiply 10 1 -> 10 +dqmul1022 multiply 10 10 -> 100 +dqmul1023 multiply 10 100 -> 1000 +dqmul1024 multiply 10 1000 -> 10000 +dqmul1025 multiply 10 10000 -> 100000 +dqmul1026 multiply 10 100000 -> 1000000 +dqmul1027 multiply 10 1000000 -> 10000000 +dqmul1028 multiply 10 10000000 -> 100000000 +dqmul1029 multiply 10 100000000 -> 1000000000 +dqmul1030 multiply 10 1000000000 -> 10000000000 +dqmul1031 multiply 10 10000000000 -> 100000000000 +dqmul1032 multiply 10 100000000000 -> 1000000000000 +dqmul1033 multiply 10 1000000000000 -> 10000000000000 +dqmul1034 multiply 10 10000000000000 -> 100000000000000 +dqmul1035 multiply 10 100000000000000 -> 1000000000000000 + +dqmul1036 multiply 10 100000000000000000 -> 1000000000000000000 +dqmul1037 multiply 10 10000000000000000000000000 -> 100000000000000000000000000 +dqmul1038 multiply 10 100000000000000000000000000 -> 1000000000000000000000000000 +dqmul1039 multiply 10 1000000000000000000000000000 -> 10000000000000000000000000000 +dqmul1040 multiply 10 100000000000000000000000000000000 -> 1000000000000000000000000000000000 + +dqmul1041 multiply 100 0.1 -> 10.0 +dqmul1042 multiply 100 1 -> 100 +dqmul1043 multiply 100 10 -> 1000 +dqmul1044 multiply 100 100 -> 10000 +dqmul1045 multiply 100 1000 -> 100000 +dqmul1046 multiply 100 10000 -> 1000000 +dqmul1047 multiply 100 100000 -> 10000000 +dqmul1048 multiply 100 1000000 -> 100000000 +dqmul1049 multiply 100 10000000 -> 1000000000 +dqmul1050 multiply 100 100000000 -> 10000000000 +dqmul1051 multiply 100 1000000000 -> 100000000000 +dqmul1052 multiply 100 10000000000 -> 1000000000000 +dqmul1053 multiply 100 100000000000 -> 10000000000000 +dqmul1054 multiply 100 1000000000000 -> 100000000000000 +dqmul1055 multiply 100 10000000000000 -> 1000000000000000 + +dqmul1056 multiply 100 10000000000000000 -> 1000000000000000000 +dqmul1057 multiply 100 1000000000000000000000000 -> 100000000000000000000000000 +dqmul1058 multiply 100 10000000000000000000000000 -> 1000000000000000000000000000 +dqmul1059 multiply 100 100000000000000000000000000 -> 10000000000000000000000000000 +dqmul1060 multiply 100 10000000000000000000000000000000 -> 1000000000000000000000000000000000 + +dqmul1061 multiply 1000 0.01 -> 10.00 +dqmul1062 multiply 1000 0.1 -> 100.0 +dqmul1063 multiply 1000 1 -> 1000 +dqmul1064 multiply 1000 10 -> 10000 +dqmul1065 multiply 1000 100 -> 100000 +dqmul1066 multiply 1000 1000 -> 1000000 +dqmul1067 multiply 1000 10000 -> 10000000 +dqmul1068 multiply 1000 100000 -> 100000000 +dqmul1069 multiply 1000 1000000 -> 1000000000 +dqmul1070 multiply 1000 10000000 -> 10000000000 +dqmul1071 multiply 1000 100000000 -> 100000000000 +dqmul1072 multiply 1000 1000000000 -> 1000000000000 +dqmul1073 multiply 1000 10000000000 -> 10000000000000 +dqmul1074 multiply 1000 100000000000 -> 100000000000000 +dqmul1075 multiply 1000 1000000000000 -> 1000000000000000 + +dqmul1076 multiply 1000 1000000000000000 -> 1000000000000000000 +dqmul1077 multiply 1000 100000000000000000000000 -> 100000000000000000000000000 +dqmul1078 multiply 1000 1000000000000000000000000 -> 1000000000000000000000000000 +dqmul1079 multiply 1000 10000000000000000000000000 -> 10000000000000000000000000000 +dqmul1080 multiply 1000 1000000000000000000000000000000 -> 1000000000000000000000000000000000 + +dqmul1081 multiply 10000 0.001 -> 10.000 +dqmul1082 multiply 10000 0.01 -> 100.00 +dqmul1083 multiply 10000 0.1 -> 1000.0 +dqmul1084 multiply 10000 1 -> 10000 +dqmul1085 multiply 10000 10 -> 100000 +dqmul1086 multiply 10000 100 -> 1000000 +dqmul1087 multiply 10000 1000 -> 10000000 +dqmul1088 multiply 10000 10000 -> 100000000 +dqmul1089 multiply 10000 100000 -> 1000000000 +dqmul1090 multiply 10000 1000000 -> 10000000000 +dqmul1091 multiply 10000 10000000 -> 100000000000 +dqmul1092 multiply 10000 100000000 -> 1000000000000 +dqmul1093 multiply 10000 1000000000 -> 10000000000000 +dqmul1094 multiply 10000 10000000000 -> 100000000000000 +dqmul1095 multiply 10000 100000000000 -> 1000000000000000 + +dqmul1096 multiply 10000 100000000000000 -> 1000000000000000000 +dqmul1097 multiply 10000 10000000000000000000000 -> 100000000000000000000000000 +dqmul1098 multiply 10000 100000000000000000000000 -> 1000000000000000000000000000 +dqmul1099 multiply 10000 1000000000000000000000000 -> 10000000000000000000000000000 +dqmul1100 multiply 10000 100000000000000000000000000000 -> 1000000000000000000000000000000000 + +dqmul1107 multiply 10000 99999999999 -> 999999999990000 +dqmul1108 multiply 10000 99999999999 -> 999999999990000 + +-- Null tests +dqmul9990 multiply 10 # -> NaN Invalid_operation +dqmul9991 multiply # 10 -> NaN Invalid_operation + Added: python/branches/release25-maint/Lib/test/decimaltestdata/dqNextMinus.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/dqNextMinus.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,126 @@ +------------------------------------------------------------------------ +-- dqNextMinus.decTest -- decQuad next that is less [754r nextdown] -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- All operands and results are decQuads. +extended: 1 +clamp: 1 +precision: 34 +maxExponent: 6144 +minExponent: -6143 +rounding: half_even + +dqnextm001 nextminus 0.9999999999999999999999999999999995 -> 0.9999999999999999999999999999999994 +dqnextm002 nextminus 0.9999999999999999999999999999999996 -> 0.9999999999999999999999999999999995 +dqnextm003 nextminus 0.9999999999999999999999999999999997 -> 0.9999999999999999999999999999999996 +dqnextm004 nextminus 0.9999999999999999999999999999999998 -> 0.9999999999999999999999999999999997 +dqnextm005 nextminus 0.9999999999999999999999999999999999 -> 0.9999999999999999999999999999999998 +dqnextm006 nextminus 1.000000000000000000000000000000000 -> 0.9999999999999999999999999999999999 +dqnextm007 nextminus 1.0 -> 0.9999999999999999999999999999999999 +dqnextm008 nextminus 1 -> 0.9999999999999999999999999999999999 +dqnextm009 nextminus 1.000000000000000000000000000000001 -> 1.000000000000000000000000000000000 +dqnextm010 nextminus 1.000000000000000000000000000000002 -> 1.000000000000000000000000000000001 +dqnextm011 nextminus 1.000000000000000000000000000000003 -> 1.000000000000000000000000000000002 +dqnextm012 nextminus 1.000000000000000000000000000000004 -> 1.000000000000000000000000000000003 +dqnextm013 nextminus 1.000000000000000000000000000000005 -> 1.000000000000000000000000000000004 +dqnextm014 nextminus 1.000000000000000000000000000000006 -> 1.000000000000000000000000000000005 +dqnextm015 nextminus 1.000000000000000000000000000000007 -> 1.000000000000000000000000000000006 +dqnextm016 nextminus 1.000000000000000000000000000000008 -> 1.000000000000000000000000000000007 +dqnextm017 nextminus 1.000000000000000000000000000000009 -> 1.000000000000000000000000000000008 +dqnextm018 nextminus 1.000000000000000000000000000000010 -> 1.000000000000000000000000000000009 +dqnextm019 nextminus 1.000000000000000000000000000000011 -> 1.000000000000000000000000000000010 +dqnextm020 nextminus 1.000000000000000000000000000000012 -> 1.000000000000000000000000000000011 + +dqnextm021 nextminus -0.9999999999999999999999999999999995 -> -0.9999999999999999999999999999999996 +dqnextm022 nextminus -0.9999999999999999999999999999999996 -> -0.9999999999999999999999999999999997 +dqnextm023 nextminus -0.9999999999999999999999999999999997 -> -0.9999999999999999999999999999999998 +dqnextm024 nextminus -0.9999999999999999999999999999999998 -> -0.9999999999999999999999999999999999 +dqnextm025 nextminus -0.9999999999999999999999999999999999 -> -1.000000000000000000000000000000000 +dqnextm026 nextminus -1.000000000000000000000000000000000 -> -1.000000000000000000000000000000001 +dqnextm027 nextminus -1.0 -> -1.000000000000000000000000000000001 +dqnextm028 nextminus -1 -> -1.000000000000000000000000000000001 +dqnextm029 nextminus -1.000000000000000000000000000000001 -> -1.000000000000000000000000000000002 +dqnextm030 nextminus -1.000000000000000000000000000000002 -> -1.000000000000000000000000000000003 +dqnextm031 nextminus -1.000000000000000000000000000000003 -> -1.000000000000000000000000000000004 +dqnextm032 nextminus -1.000000000000000000000000000000004 -> -1.000000000000000000000000000000005 +dqnextm033 nextminus -1.000000000000000000000000000000005 -> -1.000000000000000000000000000000006 +dqnextm034 nextminus -1.000000000000000000000000000000006 -> -1.000000000000000000000000000000007 +dqnextm035 nextminus -1.000000000000000000000000000000007 -> -1.000000000000000000000000000000008 +dqnextm036 nextminus -1.000000000000000000000000000000008 -> -1.000000000000000000000000000000009 +dqnextm037 nextminus -1.000000000000000000000000000000009 -> -1.000000000000000000000000000000010 +dqnextm038 nextminus -1.000000000000000000000000000000010 -> -1.000000000000000000000000000000011 +dqnextm039 nextminus -1.000000000000000000000000000000011 -> -1.000000000000000000000000000000012 + +-- ultra-tiny inputs +dqnextm062 nextminus 1E-6176 -> 0E-6176 +dqnextm065 nextminus -1E-6176 -> -2E-6176 + +-- Zeros +dqnextm100 nextminus -0 -> -1E-6176 +dqnextm101 nextminus 0 -> -1E-6176 +dqnextm102 nextminus 0.00 -> -1E-6176 +dqnextm103 nextminus -0.00 -> -1E-6176 +dqnextm104 nextminus 0E-300 -> -1E-6176 +dqnextm105 nextminus 0E+300 -> -1E-6176 +dqnextm106 nextminus 0E+30000 -> -1E-6176 +dqnextm107 nextminus -0E+30000 -> -1E-6176 + +-- specials +dqnextm150 nextminus Inf -> 9.999999999999999999999999999999999E+6144 +dqnextm151 nextminus -Inf -> -Infinity +dqnextm152 nextminus NaN -> NaN +dqnextm153 nextminus sNaN -> NaN Invalid_operation +dqnextm154 nextminus NaN77 -> NaN77 +dqnextm155 nextminus sNaN88 -> NaN88 Invalid_operation +dqnextm156 nextminus -NaN -> -NaN +dqnextm157 nextminus -sNaN -> -NaN Invalid_operation +dqnextm158 nextminus -NaN77 -> -NaN77 +dqnextm159 nextminus -sNaN88 -> -NaN88 Invalid_operation + +-- Nmax, Nmin, Ntiny, subnormals +dqnextm170 nextminus 9.999999999999999999999999999999999E+6144 -> 9.999999999999999999999999999999998E+6144 +dqnextm171 nextminus 9.999999999999999999999999999999998E+6144 -> 9.999999999999999999999999999999997E+6144 +dqnextm172 nextminus 1E-6143 -> 9.99999999999999999999999999999999E-6144 +dqnextm173 nextminus 1.000000000000000000000000000000000E-6143 -> 9.99999999999999999999999999999999E-6144 +dqnextm174 nextminus 9E-6176 -> 8E-6176 +dqnextm175 nextminus 9.9E-6175 -> 9.8E-6175 +dqnextm176 nextminus 9.99999999999999999999999999999E-6147 -> 9.99999999999999999999999999998E-6147 +dqnextm177 nextminus 9.99999999999999999999999999999999E-6144 -> 9.99999999999999999999999999999998E-6144 +dqnextm178 nextminus 9.99999999999999999999999999999998E-6144 -> 9.99999999999999999999999999999997E-6144 +dqnextm179 nextminus 9.99999999999999999999999999999997E-6144 -> 9.99999999999999999999999999999996E-6144 +dqnextm180 nextminus 0E-6176 -> -1E-6176 +dqnextm181 nextminus 1E-6176 -> 0E-6176 +dqnextm182 nextminus 2E-6176 -> 1E-6176 + +dqnextm183 nextminus -0E-6176 -> -1E-6176 +dqnextm184 nextminus -1E-6176 -> -2E-6176 +dqnextm185 nextminus -2E-6176 -> -3E-6176 +dqnextm186 nextminus -10E-6176 -> -1.1E-6175 +dqnextm187 nextminus -100E-6176 -> -1.01E-6174 +dqnextm188 nextminus -100000E-6176 -> -1.00001E-6171 +dqnextm189 nextminus -1.00000000000000000000000000000E-6143 -> -1.000000000000000000000000000000001E-6143 +dqnextm190 nextminus -1.000000000000000000000000000000000E-6143 -> -1.000000000000000000000000000000001E-6143 +dqnextm191 nextminus -1E-6143 -> -1.000000000000000000000000000000001E-6143 +dqnextm192 nextminus -9.999999999999999999999999999999998E+6144 -> -9.999999999999999999999999999999999E+6144 +dqnextm193 nextminus -9.999999999999999999999999999999999E+6144 -> -Infinity + +-- Null tests +dqnextm900 nextminus # -> NaN Invalid_operation + Added: python/branches/release25-maint/Lib/test/decimaltestdata/dqNextPlus.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/dqNextPlus.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,124 @@ +------------------------------------------------------------------------ +-- dqNextPlus.decTest -- decQuad next that is greater [754r nextup] -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- All operands and results are decQuads. +extended: 1 +clamp: 1 +precision: 34 +maxExponent: 6144 +minExponent: -6143 +rounding: half_even + +dqnextp001 nextplus 0.9999999999999999999999999999999995 -> 0.9999999999999999999999999999999996 +dqnextp002 nextplus 0.9999999999999999999999999999999996 -> 0.9999999999999999999999999999999997 +dqnextp003 nextplus 0.9999999999999999999999999999999997 -> 0.9999999999999999999999999999999998 +dqnextp004 nextplus 0.9999999999999999999999999999999998 -> 0.9999999999999999999999999999999999 +dqnextp005 nextplus 0.9999999999999999999999999999999999 -> 1.000000000000000000000000000000000 +dqnextp006 nextplus 1.000000000000000000000000000000000 -> 1.000000000000000000000000000000001 +dqnextp007 nextplus 1.0 -> 1.000000000000000000000000000000001 +dqnextp008 nextplus 1 -> 1.000000000000000000000000000000001 +dqnextp009 nextplus 1.000000000000000000000000000000001 -> 1.000000000000000000000000000000002 +dqnextp010 nextplus 1.000000000000000000000000000000002 -> 1.000000000000000000000000000000003 +dqnextp011 nextplus 1.000000000000000000000000000000003 -> 1.000000000000000000000000000000004 +dqnextp012 nextplus 1.000000000000000000000000000000004 -> 1.000000000000000000000000000000005 +dqnextp013 nextplus 1.000000000000000000000000000000005 -> 1.000000000000000000000000000000006 +dqnextp014 nextplus 1.000000000000000000000000000000006 -> 1.000000000000000000000000000000007 +dqnextp015 nextplus 1.000000000000000000000000000000007 -> 1.000000000000000000000000000000008 +dqnextp016 nextplus 1.000000000000000000000000000000008 -> 1.000000000000000000000000000000009 +dqnextp017 nextplus 1.000000000000000000000000000000009 -> 1.000000000000000000000000000000010 +dqnextp018 nextplus 1.000000000000000000000000000000010 -> 1.000000000000000000000000000000011 +dqnextp019 nextplus 1.000000000000000000000000000000011 -> 1.000000000000000000000000000000012 + +dqnextp021 nextplus -0.9999999999999999999999999999999995 -> -0.9999999999999999999999999999999994 +dqnextp022 nextplus -0.9999999999999999999999999999999996 -> -0.9999999999999999999999999999999995 +dqnextp023 nextplus -0.9999999999999999999999999999999997 -> -0.9999999999999999999999999999999996 +dqnextp024 nextplus -0.9999999999999999999999999999999998 -> -0.9999999999999999999999999999999997 +dqnextp025 nextplus -0.9999999999999999999999999999999999 -> -0.9999999999999999999999999999999998 +dqnextp026 nextplus -1.000000000000000000000000000000000 -> -0.9999999999999999999999999999999999 +dqnextp027 nextplus -1.0 -> -0.9999999999999999999999999999999999 +dqnextp028 nextplus -1 -> -0.9999999999999999999999999999999999 +dqnextp029 nextplus -1.000000000000000000000000000000001 -> -1.000000000000000000000000000000000 +dqnextp030 nextplus -1.000000000000000000000000000000002 -> -1.000000000000000000000000000000001 +dqnextp031 nextplus -1.000000000000000000000000000000003 -> -1.000000000000000000000000000000002 +dqnextp032 nextplus -1.000000000000000000000000000000004 -> -1.000000000000000000000000000000003 +dqnextp033 nextplus -1.000000000000000000000000000000005 -> -1.000000000000000000000000000000004 +dqnextp034 nextplus -1.000000000000000000000000000000006 -> -1.000000000000000000000000000000005 +dqnextp035 nextplus -1.000000000000000000000000000000007 -> -1.000000000000000000000000000000006 +dqnextp036 nextplus -1.000000000000000000000000000000008 -> -1.000000000000000000000000000000007 +dqnextp037 nextplus -1.000000000000000000000000000000009 -> -1.000000000000000000000000000000008 +dqnextp038 nextplus -1.000000000000000000000000000000010 -> -1.000000000000000000000000000000009 +dqnextp039 nextplus -1.000000000000000000000000000000011 -> -1.000000000000000000000000000000010 +dqnextp040 nextplus -1.000000000000000000000000000000012 -> -1.000000000000000000000000000000011 + +-- Zeros +dqnextp100 nextplus 0 -> 1E-6176 +dqnextp101 nextplus 0.00 -> 1E-6176 +dqnextp102 nextplus 0E-300 -> 1E-6176 +dqnextp103 nextplus 0E+300 -> 1E-6176 +dqnextp104 nextplus 0E+30000 -> 1E-6176 +dqnextp105 nextplus -0 -> 1E-6176 +dqnextp106 nextplus -0.00 -> 1E-6176 +dqnextp107 nextplus -0E-300 -> 1E-6176 +dqnextp108 nextplus -0E+300 -> 1E-6176 +dqnextp109 nextplus -0E+30000 -> 1E-6176 + +-- specials +dqnextp150 nextplus Inf -> Infinity +dqnextp151 nextplus -Inf -> -9.999999999999999999999999999999999E+6144 +dqnextp152 nextplus NaN -> NaN +dqnextp153 nextplus sNaN -> NaN Invalid_operation +dqnextp154 nextplus NaN77 -> NaN77 +dqnextp155 nextplus sNaN88 -> NaN88 Invalid_operation +dqnextp156 nextplus -NaN -> -NaN +dqnextp157 nextplus -sNaN -> -NaN Invalid_operation +dqnextp158 nextplus -NaN77 -> -NaN77 +dqnextp159 nextplus -sNaN88 -> -NaN88 Invalid_operation + +-- Nmax, Nmin, Ntiny, subnormals +dqnextp170 nextplus -9.999999999999999999999999999999999E+6144 -> -9.999999999999999999999999999999998E+6144 +dqnextp171 nextplus -9.999999999999999999999999999999998E+6144 -> -9.999999999999999999999999999999997E+6144 +dqnextp172 nextplus -1E-6143 -> -9.99999999999999999999999999999999E-6144 +dqnextp173 nextplus -1.000000000000000E-6143 -> -9.99999999999999999999999999999999E-6144 +dqnextp174 nextplus -9E-6176 -> -8E-6176 +dqnextp175 nextplus -9.9E-6175 -> -9.8E-6175 +dqnextp176 nextplus -9.99999999999999999999999999999E-6147 -> -9.99999999999999999999999999998E-6147 +dqnextp177 nextplus -9.99999999999999999999999999999999E-6144 -> -9.99999999999999999999999999999998E-6144 +dqnextp178 nextplus -9.99999999999999999999999999999998E-6144 -> -9.99999999999999999999999999999997E-6144 +dqnextp179 nextplus -9.99999999999999999999999999999997E-6144 -> -9.99999999999999999999999999999996E-6144 +dqnextp180 nextplus -0E-6176 -> 1E-6176 +dqnextp181 nextplus -1E-6176 -> -0E-6176 +dqnextp182 nextplus -2E-6176 -> -1E-6176 + +dqnextp183 nextplus 0E-6176 -> 1E-6176 +dqnextp184 nextplus 1E-6176 -> 2E-6176 +dqnextp185 nextplus 2E-6176 -> 3E-6176 +dqnextp186 nextplus 10E-6176 -> 1.1E-6175 +dqnextp187 nextplus 100E-6176 -> 1.01E-6174 +dqnextp188 nextplus 100000E-6176 -> 1.00001E-6171 +dqnextp189 nextplus 1.00000000000000000000000000000E-6143 -> 1.000000000000000000000000000000001E-6143 +dqnextp190 nextplus 1.000000000000000000000000000000000E-6143 -> 1.000000000000000000000000000000001E-6143 +dqnextp191 nextplus 1E-6143 -> 1.000000000000000000000000000000001E-6143 +dqnextp192 nextplus 9.999999999999999999999999999999998E+6144 -> 9.999999999999999999999999999999999E+6144 +dqnextp193 nextplus 9.999999999999999999999999999999999E+6144 -> Infinity + +-- Null tests +dqnextp900 nextplus # -> NaN Invalid_operation + Added: python/branches/release25-maint/Lib/test/decimaltestdata/dqNextToward.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/dqNextToward.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,375 @@ +------------------------------------------------------------------------ +-- dqNextToward.decTest -- decQuad next toward rhs [754r nextafter] -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- All operands and results are decQuads. +extended: 1 +clamp: 1 +precision: 34 +maxExponent: 6144 +minExponent: -6143 +rounding: half_even + + +-- Sanity check with a scattering of numerics +dqnextt001 nexttoward 10 10 -> 10 +dqnextt002 nexttoward -10 -10 -> -10 +dqnextt003 nexttoward 1 10 -> 1.000000000000000000000000000000001 +dqnextt004 nexttoward 1 -10 -> 0.9999999999999999999999999999999999 +dqnextt005 nexttoward -1 10 -> -0.9999999999999999999999999999999999 +dqnextt006 nexttoward -1 -10 -> -1.000000000000000000000000000000001 +dqnextt007 nexttoward 0 10 -> 1E-6176 Underflow Subnormal Inexact Rounded +dqnextt008 nexttoward 0 -10 -> -1E-6176 Underflow Subnormal Inexact Rounded +dqnextt009 nexttoward 9.999999999999999999999999999999999E+6144 +Infinity -> Infinity Overflow Inexact Rounded +dqnextt010 nexttoward -9.999999999999999999999999999999999E+6144 -Infinity -> -Infinity Overflow Inexact Rounded +dqnextt011 nexttoward 9.999999999999999999999999999999999 10 -> 10.00000000000000000000000000000000 +dqnextt012 nexttoward 10 9.999999999999999999999999999999999 -> 9.999999999999999999999999999999999 +dqnextt013 nexttoward -9.999999999999999999999999999999999 -10 -> -10.00000000000000000000000000000000 +dqnextt014 nexttoward -10 -9.999999999999999999999999999999999 -> -9.999999999999999999999999999999999 +dqnextt015 nexttoward 9.999999999999999999999999999999998 10 -> 9.999999999999999999999999999999999 +dqnextt016 nexttoward 10 9.999999999999999999999999999999998 -> 9.999999999999999999999999999999999 +dqnextt017 nexttoward -9.999999999999999999999999999999998 -10 -> -9.999999999999999999999999999999999 +dqnextt018 nexttoward -10 -9.999999999999999999999999999999998 -> -9.999999999999999999999999999999999 + +------- lhs=rhs +-- finites +dqnextt101 nexttoward 7 7 -> 7 +dqnextt102 nexttoward -7 -7 -> -7 +dqnextt103 nexttoward 75 75 -> 75 +dqnextt104 nexttoward -75 -75 -> -75 +dqnextt105 nexttoward 7.50 7.5 -> 7.50 +dqnextt106 nexttoward -7.50 -7.50 -> -7.50 +dqnextt107 nexttoward 7.500 7.5000 -> 7.500 +dqnextt108 nexttoward -7.500 -7.5 -> -7.500 + +-- zeros +dqnextt111 nexttoward 0 0 -> 0 +dqnextt112 nexttoward -0 -0 -> -0 +dqnextt113 nexttoward 0E+4 0 -> 0E+4 +dqnextt114 nexttoward -0E+4 -0 -> -0E+4 +dqnextt115 nexttoward 0.00000000000 0.000000000000 -> 0E-11 +dqnextt116 nexttoward -0.00000000000 -0.00 -> -0E-11 +dqnextt117 nexttoward 0E-141 0 -> 0E-141 +dqnextt118 nexttoward -0E-141 -000 -> -0E-141 + +-- full coefficients, alternating bits +dqnextt121 nexttoward 268268268 268268268 -> 268268268 +dqnextt122 nexttoward -268268268 -268268268 -> -268268268 +dqnextt123 nexttoward 134134134 134134134 -> 134134134 +dqnextt124 nexttoward -134134134 -134134134 -> -134134134 + +-- Nmax, Nmin, Ntiny +dqnextt131 nexttoward 9.999999999999999999999999999999999E+6144 9.999999999999999999999999999999999E+6144 -> 9.999999999999999999999999999999999E+6144 +dqnextt132 nexttoward 1E-6143 1E-6143 -> 1E-6143 +dqnextt133 nexttoward 1.000000000000000000000000000000000E-6143 1.000000000000000000000000000000000E-6143 -> 1.000000000000000000000000000000000E-6143 +dqnextt134 nexttoward 1E-6176 1E-6176 -> 1E-6176 + +dqnextt135 nexttoward -1E-6176 -1E-6176 -> -1E-6176 +dqnextt136 nexttoward -1.000000000000000000000000000000000E-6143 -1.000000000000000000000000000000000E-6143 -> -1.000000000000000000000000000000000E-6143 +dqnextt137 nexttoward -1E-6143 -1E-6143 -> -1E-6143 +dqnextt138 nexttoward -9.999999999999999999999999999999999E+6144 -9.999999999999999999999999999999999E+6144 -> -9.999999999999999999999999999999999E+6144 + +------- lhs 0.9999999999999999999999999999999996 +dqnextt202 nexttoward 0.9999999999999999999999999999999996 Infinity -> 0.9999999999999999999999999999999997 +dqnextt203 nexttoward 0.9999999999999999999999999999999997 Infinity -> 0.9999999999999999999999999999999998 +dqnextt204 nexttoward 0.9999999999999999999999999999999998 Infinity -> 0.9999999999999999999999999999999999 +dqnextt205 nexttoward 0.9999999999999999999999999999999999 Infinity -> 1.000000000000000000000000000000000 +dqnextt206 nexttoward 1.000000000000000000000000000000000 Infinity -> 1.000000000000000000000000000000001 +dqnextt207 nexttoward 1.0 Infinity -> 1.000000000000000000000000000000001 +dqnextt208 nexttoward 1 Infinity -> 1.000000000000000000000000000000001 +dqnextt209 nexttoward 1.000000000000000000000000000000001 Infinity -> 1.000000000000000000000000000000002 +dqnextt210 nexttoward 1.000000000000000000000000000000002 Infinity -> 1.000000000000000000000000000000003 +dqnextt211 nexttoward 1.000000000000000000000000000000003 Infinity -> 1.000000000000000000000000000000004 +dqnextt212 nexttoward 1.000000000000000000000000000000004 Infinity -> 1.000000000000000000000000000000005 +dqnextt213 nexttoward 1.000000000000000000000000000000005 Infinity -> 1.000000000000000000000000000000006 +dqnextt214 nexttoward 1.000000000000000000000000000000006 Infinity -> 1.000000000000000000000000000000007 +dqnextt215 nexttoward 1.000000000000000000000000000000007 Infinity -> 1.000000000000000000000000000000008 +dqnextt216 nexttoward 1.000000000000000000000000000000008 Infinity -> 1.000000000000000000000000000000009 +dqnextt217 nexttoward 1.000000000000000000000000000000009 Infinity -> 1.000000000000000000000000000000010 +dqnextt218 nexttoward 1.000000000000000000000000000000010 Infinity -> 1.000000000000000000000000000000011 +dqnextt219 nexttoward 1.000000000000000000000000000000011 Infinity -> 1.000000000000000000000000000000012 + +dqnextt221 nexttoward -0.9999999999999999999999999999999995 Infinity -> -0.9999999999999999999999999999999994 +dqnextt222 nexttoward -0.9999999999999999999999999999999996 Infinity -> -0.9999999999999999999999999999999995 +dqnextt223 nexttoward -0.9999999999999999999999999999999997 Infinity -> -0.9999999999999999999999999999999996 +dqnextt224 nexttoward -0.9999999999999999999999999999999998 Infinity -> -0.9999999999999999999999999999999997 +dqnextt225 nexttoward -0.9999999999999999999999999999999999 Infinity -> -0.9999999999999999999999999999999998 +dqnextt226 nexttoward -1.000000000000000000000000000000000 Infinity -> -0.9999999999999999999999999999999999 +dqnextt227 nexttoward -1.0 Infinity -> -0.9999999999999999999999999999999999 +dqnextt228 nexttoward -1 Infinity -> -0.9999999999999999999999999999999999 +dqnextt229 nexttoward -1.000000000000000000000000000000001 Infinity -> -1.000000000000000000000000000000000 +dqnextt230 nexttoward -1.000000000000000000000000000000002 Infinity -> -1.000000000000000000000000000000001 +dqnextt231 nexttoward -1.000000000000000000000000000000003 Infinity -> -1.000000000000000000000000000000002 +dqnextt232 nexttoward -1.000000000000000000000000000000004 Infinity -> -1.000000000000000000000000000000003 +dqnextt233 nexttoward -1.000000000000000000000000000000005 Infinity -> -1.000000000000000000000000000000004 +dqnextt234 nexttoward -1.000000000000000000000000000000006 Infinity -> -1.000000000000000000000000000000005 +dqnextt235 nexttoward -1.000000000000000000000000000000007 Infinity -> -1.000000000000000000000000000000006 +dqnextt236 nexttoward -1.000000000000000000000000000000008 Infinity -> -1.000000000000000000000000000000007 +dqnextt237 nexttoward -1.000000000000000000000000000000009 Infinity -> -1.000000000000000000000000000000008 +dqnextt238 nexttoward -1.000000000000000000000000000000010 Infinity -> -1.000000000000000000000000000000009 +dqnextt239 nexttoward -1.000000000000000000000000000000011 Infinity -> -1.000000000000000000000000000000010 +dqnextt240 nexttoward -1.000000000000000000000000000000012 Infinity -> -1.000000000000000000000000000000011 + +-- Zeros +dqnextt300 nexttoward 0 Infinity -> 1E-6176 Underflow Subnormal Inexact Rounded +dqnextt301 nexttoward 0.00 Infinity -> 1E-6176 Underflow Subnormal Inexact Rounded +dqnextt302 nexttoward 0E-300 Infinity -> 1E-6176 Underflow Subnormal Inexact Rounded +dqnextt303 nexttoward 0E+300 Infinity -> 1E-6176 Underflow Subnormal Inexact Rounded +dqnextt304 nexttoward 0E+30000 Infinity -> 1E-6176 Underflow Subnormal Inexact Rounded +dqnextt305 nexttoward -0 Infinity -> 1E-6176 Underflow Subnormal Inexact Rounded +dqnextt306 nexttoward -0.00 Infinity -> 1E-6176 Underflow Subnormal Inexact Rounded +dqnextt307 nexttoward -0E-300 Infinity -> 1E-6176 Underflow Subnormal Inexact Rounded +dqnextt308 nexttoward -0E+300 Infinity -> 1E-6176 Underflow Subnormal Inexact Rounded +dqnextt309 nexttoward -0E+30000 Infinity -> 1E-6176 Underflow Subnormal Inexact Rounded + +-- specials +dqnextt350 nexttoward Inf Infinity -> Infinity +dqnextt351 nexttoward -Inf Infinity -> -9.999999999999999999999999999999999E+6144 +dqnextt352 nexttoward NaN Infinity -> NaN +dqnextt353 nexttoward sNaN Infinity -> NaN Invalid_operation +dqnextt354 nexttoward NaN77 Infinity -> NaN77 +dqnextt355 nexttoward sNaN88 Infinity -> NaN88 Invalid_operation +dqnextt356 nexttoward -NaN Infinity -> -NaN +dqnextt357 nexttoward -sNaN Infinity -> -NaN Invalid_operation +dqnextt358 nexttoward -NaN77 Infinity -> -NaN77 +dqnextt359 nexttoward -sNaN88 Infinity -> -NaN88 Invalid_operation + +-- Nmax, Nmin, Ntiny, subnormals +dqnextt370 nexttoward -9.999999999999999999999999999999999E+6144 Infinity -> -9.999999999999999999999999999999998E+6144 +dqnextt371 nexttoward -9.999999999999999999999999999999998E+6144 Infinity -> -9.999999999999999999999999999999997E+6144 +dqnextt372 nexttoward -1E-6143 Infinity -> -9.99999999999999999999999999999999E-6144 Underflow Subnormal Inexact Rounded +dqnextt373 nexttoward -1.000000000000000E-6143 Infinity -> -9.99999999999999999999999999999999E-6144 Underflow Subnormal Inexact Rounded +dqnextt374 nexttoward -9E-6176 Infinity -> -8E-6176 Underflow Subnormal Inexact Rounded +dqnextt375 nexttoward -9.9E-6175 Infinity -> -9.8E-6175 Underflow Subnormal Inexact Rounded +dqnextt376 nexttoward -9.99999999999999999999999999999E-6147 Infinity -> -9.99999999999999999999999999998E-6147 Underflow Subnormal Inexact Rounded +dqnextt377 nexttoward -9.99999999999999999999999999999999E-6144 Infinity -> -9.99999999999999999999999999999998E-6144 Underflow Subnormal Inexact Rounded +dqnextt378 nexttoward -9.99999999999999999999999999999998E-6144 Infinity -> -9.99999999999999999999999999999997E-6144 Underflow Subnormal Inexact Rounded +dqnextt379 nexttoward -9.99999999999999999999999999999997E-6144 Infinity -> -9.99999999999999999999999999999996E-6144 Underflow Subnormal Inexact Rounded +dqnextt380 nexttoward -0E-6176 Infinity -> 1E-6176 Underflow Subnormal Inexact Rounded +dqnextt381 nexttoward -1E-6176 Infinity -> -0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqnextt382 nexttoward -2E-6176 Infinity -> -1E-6176 Underflow Subnormal Inexact Rounded + +dqnextt383 nexttoward 0E-6176 Infinity -> 1E-6176 Underflow Subnormal Inexact Rounded +dqnextt384 nexttoward 1E-6176 Infinity -> 2E-6176 Underflow Subnormal Inexact Rounded +dqnextt385 nexttoward 2E-6176 Infinity -> 3E-6176 Underflow Subnormal Inexact Rounded +dqnextt386 nexttoward 10E-6176 Infinity -> 1.1E-6175 Underflow Subnormal Inexact Rounded +dqnextt387 nexttoward 100E-6176 Infinity -> 1.01E-6174 Underflow Subnormal Inexact Rounded +dqnextt388 nexttoward 100000E-6176 Infinity -> 1.00001E-6171 Underflow Subnormal Inexact Rounded +dqnextt389 nexttoward 1.00000000000000000000000000000E-6143 Infinity -> 1.000000000000000000000000000000001E-6143 +dqnextt390 nexttoward 1.000000000000000000000000000000000E-6143 Infinity -> 1.000000000000000000000000000000001E-6143 +dqnextt391 nexttoward 1E-6143 Infinity -> 1.000000000000000000000000000000001E-6143 +dqnextt392 nexttoward 9.999999999999999999999999999999997E+6144 Infinity -> 9.999999999999999999999999999999998E+6144 +dqnextt393 nexttoward 9.999999999999999999999999999999998E+6144 Infinity -> 9.999999999999999999999999999999999E+6144 +dqnextt394 nexttoward 9.999999999999999999999999999999999E+6144 Infinity -> Infinity Overflow Inexact Rounded + +------- lhs>rhs +dqnextt401 nexttoward 0.9999999999999999999999999999999995 -Infinity -> 0.9999999999999999999999999999999994 +dqnextt402 nexttoward 0.9999999999999999999999999999999996 -Infinity -> 0.9999999999999999999999999999999995 +dqnextt403 nexttoward 0.9999999999999999999999999999999997 -Infinity -> 0.9999999999999999999999999999999996 +dqnextt404 nexttoward 0.9999999999999999999999999999999998 -Infinity -> 0.9999999999999999999999999999999997 +dqnextt405 nexttoward 0.9999999999999999999999999999999999 -Infinity -> 0.9999999999999999999999999999999998 +dqnextt406 nexttoward 1.000000000000000000000000000000000 -Infinity -> 0.9999999999999999999999999999999999 +dqnextt407 nexttoward 1.0 -Infinity -> 0.9999999999999999999999999999999999 +dqnextt408 nexttoward 1 -Infinity -> 0.9999999999999999999999999999999999 +dqnextt409 nexttoward 1.000000000000000000000000000000001 -Infinity -> 1.000000000000000000000000000000000 +dqnextt410 nexttoward 1.000000000000000000000000000000002 -Infinity -> 1.000000000000000000000000000000001 +dqnextt411 nexttoward 1.000000000000000000000000000000003 -Infinity -> 1.000000000000000000000000000000002 +dqnextt412 nexttoward 1.000000000000000000000000000000004 -Infinity -> 1.000000000000000000000000000000003 +dqnextt413 nexttoward 1.000000000000000000000000000000005 -Infinity -> 1.000000000000000000000000000000004 +dqnextt414 nexttoward 1.000000000000000000000000000000006 -Infinity -> 1.000000000000000000000000000000005 +dqnextt415 nexttoward 1.000000000000000000000000000000007 -Infinity -> 1.000000000000000000000000000000006 +dqnextt416 nexttoward 1.000000000000000000000000000000008 -Infinity -> 1.000000000000000000000000000000007 +dqnextt417 nexttoward 1.000000000000000000000000000000009 -Infinity -> 1.000000000000000000000000000000008 +dqnextt418 nexttoward 1.000000000000000000000000000000010 -Infinity -> 1.000000000000000000000000000000009 +dqnextt419 nexttoward 1.000000000000000000000000000000011 -Infinity -> 1.000000000000000000000000000000010 +dqnextt420 nexttoward 1.000000000000000000000000000000012 -Infinity -> 1.000000000000000000000000000000011 + +dqnextt421 nexttoward -0.9999999999999999999999999999999995 -Infinity -> -0.9999999999999999999999999999999996 +dqnextt422 nexttoward -0.9999999999999999999999999999999996 -Infinity -> -0.9999999999999999999999999999999997 +dqnextt423 nexttoward -0.9999999999999999999999999999999997 -Infinity -> -0.9999999999999999999999999999999998 +dqnextt424 nexttoward -0.9999999999999999999999999999999998 -Infinity -> -0.9999999999999999999999999999999999 +dqnextt425 nexttoward -0.9999999999999999999999999999999999 -Infinity -> -1.000000000000000000000000000000000 +dqnextt426 nexttoward -1.000000000000000000000000000000000 -Infinity -> -1.000000000000000000000000000000001 +dqnextt427 nexttoward -1.0 -Infinity -> -1.000000000000000000000000000000001 +dqnextt428 nexttoward -1 -Infinity -> -1.000000000000000000000000000000001 +dqnextt429 nexttoward -1.000000000000000000000000000000001 -Infinity -> -1.000000000000000000000000000000002 +dqnextt430 nexttoward -1.000000000000000000000000000000002 -Infinity -> -1.000000000000000000000000000000003 +dqnextt431 nexttoward -1.000000000000000000000000000000003 -Infinity -> -1.000000000000000000000000000000004 +dqnextt432 nexttoward -1.000000000000000000000000000000004 -Infinity -> -1.000000000000000000000000000000005 +dqnextt433 nexttoward -1.000000000000000000000000000000005 -Infinity -> -1.000000000000000000000000000000006 +dqnextt434 nexttoward -1.000000000000000000000000000000006 -Infinity -> -1.000000000000000000000000000000007 +dqnextt435 nexttoward -1.000000000000000000000000000000007 -Infinity -> -1.000000000000000000000000000000008 +dqnextt436 nexttoward -1.000000000000000000000000000000008 -Infinity -> -1.000000000000000000000000000000009 +dqnextt437 nexttoward -1.000000000000000000000000000000009 -Infinity -> -1.000000000000000000000000000000010 +dqnextt438 nexttoward -1.000000000000000000000000000000010 -Infinity -> -1.000000000000000000000000000000011 +dqnextt439 nexttoward -1.000000000000000000000000000000011 -Infinity -> -1.000000000000000000000000000000012 + +-- Zeros +dqnextt500 nexttoward -0 -Infinity -> -1E-6176 Underflow Subnormal Inexact Rounded +dqnextt501 nexttoward 0 -Infinity -> -1E-6176 Underflow Subnormal Inexact Rounded +dqnextt502 nexttoward 0.00 -Infinity -> -1E-6176 Underflow Subnormal Inexact Rounded +dqnextt503 nexttoward -0.00 -Infinity -> -1E-6176 Underflow Subnormal Inexact Rounded +dqnextt504 nexttoward 0E-300 -Infinity -> -1E-6176 Underflow Subnormal Inexact Rounded +dqnextt505 nexttoward 0E+300 -Infinity -> -1E-6176 Underflow Subnormal Inexact Rounded +dqnextt506 nexttoward 0E+30000 -Infinity -> -1E-6176 Underflow Subnormal Inexact Rounded +dqnextt507 nexttoward -0E+30000 -Infinity -> -1E-6176 Underflow Subnormal Inexact Rounded + +-- specials +dqnextt550 nexttoward Inf -Infinity -> 9.999999999999999999999999999999999E+6144 +dqnextt551 nexttoward -Inf -Infinity -> -Infinity +dqnextt552 nexttoward NaN -Infinity -> NaN +dqnextt553 nexttoward sNaN -Infinity -> NaN Invalid_operation +dqnextt554 nexttoward NaN77 -Infinity -> NaN77 +dqnextt555 nexttoward sNaN88 -Infinity -> NaN88 Invalid_operation +dqnextt556 nexttoward -NaN -Infinity -> -NaN +dqnextt557 nexttoward -sNaN -Infinity -> -NaN Invalid_operation +dqnextt558 nexttoward -NaN77 -Infinity -> -NaN77 +dqnextt559 nexttoward -sNaN88 -Infinity -> -NaN88 Invalid_operation + +-- Nmax, Nmin, Ntiny, subnormals +dqnextt670 nexttoward 9.999999999999999999999999999999999E+6144 -Infinity -> 9.999999999999999999999999999999998E+6144 +dqnextt671 nexttoward 9.999999999999999999999999999999998E+6144 -Infinity -> 9.999999999999999999999999999999997E+6144 +dqnextt672 nexttoward 1E-6143 -Infinity -> 9.99999999999999999999999999999999E-6144 Underflow Subnormal Inexact Rounded +dqnextt673 nexttoward 1.000000000000000000000000000000000E-6143 -Infinity -> 9.99999999999999999999999999999999E-6144 Underflow Subnormal Inexact Rounded +dqnextt674 nexttoward 9E-6176 -Infinity -> 8E-6176 Underflow Subnormal Inexact Rounded +dqnextt675 nexttoward 9.9E-6175 -Infinity -> 9.8E-6175 Underflow Subnormal Inexact Rounded +dqnextt676 nexttoward 9.99999999999999999999999999999E-6147 -Infinity -> 9.99999999999999999999999999998E-6147 Underflow Subnormal Inexact Rounded +dqnextt677 nexttoward 9.99999999999999999999999999999999E-6144 -Infinity -> 9.99999999999999999999999999999998E-6144 Underflow Subnormal Inexact Rounded +dqnextt678 nexttoward 9.99999999999999999999999999999998E-6144 -Infinity -> 9.99999999999999999999999999999997E-6144 Underflow Subnormal Inexact Rounded +dqnextt679 nexttoward 9.99999999999999999999999999999997E-6144 -Infinity -> 9.99999999999999999999999999999996E-6144 Underflow Subnormal Inexact Rounded +dqnextt680 nexttoward 0E-6176 -Infinity -> -1E-6176 Underflow Subnormal Inexact Rounded +dqnextt681 nexttoward 1E-6176 -Infinity -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqnextt682 nexttoward 2E-6176 -Infinity -> 1E-6176 Underflow Subnormal Inexact Rounded + +dqnextt683 nexttoward -0E-6176 -Infinity -> -1E-6176 Underflow Subnormal Inexact Rounded +dqnextt684 nexttoward -1E-6176 -Infinity -> -2E-6176 Underflow Subnormal Inexact Rounded +dqnextt685 nexttoward -2E-6176 -Infinity -> -3E-6176 Underflow Subnormal Inexact Rounded +dqnextt686 nexttoward -10E-6176 -Infinity -> -1.1E-6175 Underflow Subnormal Inexact Rounded +dqnextt687 nexttoward -100E-6176 -Infinity -> -1.01E-6174 Underflow Subnormal Inexact Rounded +dqnextt688 nexttoward -100000E-6176 -Infinity -> -1.00001E-6171 Underflow Subnormal Inexact Rounded +dqnextt689 nexttoward -1.00000000000000000000000000000E-6143 -Infinity -> -1.000000000000000000000000000000001E-6143 +dqnextt690 nexttoward -1.000000000000000000000000000000000E-6143 -Infinity -> -1.000000000000000000000000000000001E-6143 +dqnextt691 nexttoward -1E-6143 -Infinity -> -1.000000000000000000000000000000001E-6143 +dqnextt692 nexttoward -9.999999999999999999999999999999998E+6144 -Infinity -> -9.999999999999999999999999999999999E+6144 +dqnextt693 nexttoward -9.999999999999999999999999999999999E+6144 -Infinity -> -Infinity Overflow Inexact Rounded + +------- Specials +dqnextt780 nexttoward -Inf -Inf -> -Infinity +dqnextt781 nexttoward -Inf -1000 -> -9.999999999999999999999999999999999E+6144 +dqnextt782 nexttoward -Inf -1 -> -9.999999999999999999999999999999999E+6144 +dqnextt783 nexttoward -Inf -0 -> -9.999999999999999999999999999999999E+6144 +dqnextt784 nexttoward -Inf 0 -> -9.999999999999999999999999999999999E+6144 +dqnextt785 nexttoward -Inf 1 -> -9.999999999999999999999999999999999E+6144 +dqnextt786 nexttoward -Inf 1000 -> -9.999999999999999999999999999999999E+6144 +dqnextt787 nexttoward -1000 -Inf -> -1000.000000000000000000000000000001 +dqnextt788 nexttoward -Inf -Inf -> -Infinity +dqnextt789 nexttoward -1 -Inf -> -1.000000000000000000000000000000001 +dqnextt790 nexttoward -0 -Inf -> -1E-6176 Underflow Subnormal Inexact Rounded +dqnextt791 nexttoward 0 -Inf -> -1E-6176 Underflow Subnormal Inexact Rounded +dqnextt792 nexttoward 1 -Inf -> 0.9999999999999999999999999999999999 +dqnextt793 nexttoward 1000 -Inf -> 999.9999999999999999999999999999999 +dqnextt794 nexttoward Inf -Inf -> 9.999999999999999999999999999999999E+6144 + +dqnextt800 nexttoward Inf -Inf -> 9.999999999999999999999999999999999E+6144 +dqnextt801 nexttoward Inf -1000 -> 9.999999999999999999999999999999999E+6144 +dqnextt802 nexttoward Inf -1 -> 9.999999999999999999999999999999999E+6144 +dqnextt803 nexttoward Inf -0 -> 9.999999999999999999999999999999999E+6144 +dqnextt804 nexttoward Inf 0 -> 9.999999999999999999999999999999999E+6144 +dqnextt805 nexttoward Inf 1 -> 9.999999999999999999999999999999999E+6144 +dqnextt806 nexttoward Inf 1000 -> 9.999999999999999999999999999999999E+6144 +dqnextt807 nexttoward Inf Inf -> Infinity +dqnextt808 nexttoward -1000 Inf -> -999.9999999999999999999999999999999 +dqnextt809 nexttoward -Inf Inf -> -9.999999999999999999999999999999999E+6144 +dqnextt810 nexttoward -1 Inf -> -0.9999999999999999999999999999999999 +dqnextt811 nexttoward -0 Inf -> 1E-6176 Underflow Subnormal Inexact Rounded +dqnextt812 nexttoward 0 Inf -> 1E-6176 Underflow Subnormal Inexact Rounded +dqnextt813 nexttoward 1 Inf -> 1.000000000000000000000000000000001 +dqnextt814 nexttoward 1000 Inf -> 1000.000000000000000000000000000001 +dqnextt815 nexttoward Inf Inf -> Infinity + +dqnextt821 nexttoward NaN -Inf -> NaN +dqnextt822 nexttoward NaN -1000 -> NaN +dqnextt823 nexttoward NaN -1 -> NaN +dqnextt824 nexttoward NaN -0 -> NaN +dqnextt825 nexttoward NaN 0 -> NaN +dqnextt826 nexttoward NaN 1 -> NaN +dqnextt827 nexttoward NaN 1000 -> NaN +dqnextt828 nexttoward NaN Inf -> NaN +dqnextt829 nexttoward NaN NaN -> NaN +dqnextt830 nexttoward -Inf NaN -> NaN +dqnextt831 nexttoward -1000 NaN -> NaN +dqnextt832 nexttoward -1 NaN -> NaN +dqnextt833 nexttoward -0 NaN -> NaN +dqnextt834 nexttoward 0 NaN -> NaN +dqnextt835 nexttoward 1 NaN -> NaN +dqnextt836 nexttoward 1000 NaN -> NaN +dqnextt837 nexttoward Inf NaN -> NaN + +dqnextt841 nexttoward sNaN -Inf -> NaN Invalid_operation +dqnextt842 nexttoward sNaN -1000 -> NaN Invalid_operation +dqnextt843 nexttoward sNaN -1 -> NaN Invalid_operation +dqnextt844 nexttoward sNaN -0 -> NaN Invalid_operation +dqnextt845 nexttoward sNaN 0 -> NaN Invalid_operation +dqnextt846 nexttoward sNaN 1 -> NaN Invalid_operation +dqnextt847 nexttoward sNaN 1000 -> NaN Invalid_operation +dqnextt848 nexttoward sNaN NaN -> NaN Invalid_operation +dqnextt849 nexttoward sNaN sNaN -> NaN Invalid_operation +dqnextt850 nexttoward NaN sNaN -> NaN Invalid_operation +dqnextt851 nexttoward -Inf sNaN -> NaN Invalid_operation +dqnextt852 nexttoward -1000 sNaN -> NaN Invalid_operation +dqnextt853 nexttoward -1 sNaN -> NaN Invalid_operation +dqnextt854 nexttoward -0 sNaN -> NaN Invalid_operation +dqnextt855 nexttoward 0 sNaN -> NaN Invalid_operation +dqnextt856 nexttoward 1 sNaN -> NaN Invalid_operation +dqnextt857 nexttoward 1000 sNaN -> NaN Invalid_operation +dqnextt858 nexttoward Inf sNaN -> NaN Invalid_operation +dqnextt859 nexttoward NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +dqnextt861 nexttoward NaN1 -Inf -> NaN1 +dqnextt862 nexttoward +NaN2 -1000 -> NaN2 +dqnextt863 nexttoward NaN3 1000 -> NaN3 +dqnextt864 nexttoward NaN4 Inf -> NaN4 +dqnextt865 nexttoward NaN5 +NaN6 -> NaN5 +dqnextt866 nexttoward -Inf NaN7 -> NaN7 +dqnextt867 nexttoward -1000 NaN8 -> NaN8 +dqnextt868 nexttoward 1000 NaN9 -> NaN9 +dqnextt869 nexttoward Inf +NaN10 -> NaN10 +dqnextt871 nexttoward sNaN11 -Inf -> NaN11 Invalid_operation +dqnextt872 nexttoward sNaN12 -1000 -> NaN12 Invalid_operation +dqnextt873 nexttoward sNaN13 1000 -> NaN13 Invalid_operation +dqnextt874 nexttoward sNaN14 NaN17 -> NaN14 Invalid_operation +dqnextt875 nexttoward sNaN15 sNaN18 -> NaN15 Invalid_operation +dqnextt876 nexttoward NaN16 sNaN19 -> NaN19 Invalid_operation +dqnextt877 nexttoward -Inf +sNaN20 -> NaN20 Invalid_operation +dqnextt878 nexttoward -1000 sNaN21 -> NaN21 Invalid_operation +dqnextt879 nexttoward 1000 sNaN22 -> NaN22 Invalid_operation +dqnextt880 nexttoward Inf sNaN23 -> NaN23 Invalid_operation +dqnextt881 nexttoward +NaN25 +sNaN24 -> NaN24 Invalid_operation +dqnextt882 nexttoward -NaN26 NaN28 -> -NaN26 +dqnextt883 nexttoward -sNaN27 sNaN29 -> -NaN27 Invalid_operation +dqnextt884 nexttoward 1000 -NaN30 -> -NaN30 +dqnextt885 nexttoward 1000 -sNaN31 -> -NaN31 Invalid_operation + +-- Null tests +dqnextt900 nexttoward 1 # -> NaN Invalid_operation +dqnextt901 nexttoward # 1 -> NaN Invalid_operation + Added: python/branches/release25-maint/Lib/test/decimaltestdata/dqOr.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/dqOr.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,401 @@ +------------------------------------------------------------------------ +-- dqOr.decTest -- digitwise logical OR for decQuads -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +extended: 1 +clamp: 1 +precision: 34 +maxExponent: 6144 +minExponent: -6143 +rounding: half_even + +-- Sanity check (truth table) +dqor001 or 0 0 -> 0 +dqor002 or 0 1 -> 1 +dqor003 or 1 0 -> 1 +dqor004 or 1 1 -> 1 +dqor005 or 1100 1010 -> 1110 +-- and at msd and msd-1 +dqor006 or 0000000000000000000000000000000000 0000000000000000000000000000000000 -> 0 +dqor007 or 0000000000000000000000000000000000 1000000000000000000000000000000000 -> 1000000000000000000000000000000000 +dqor008 or 1000000000000000000000000000000000 0000000000000000000000000000000000 -> 1000000000000000000000000000000000 +dqor009 or 1000000000000000000000000000000000 1000000000000000000000000000000000 -> 1000000000000000000000000000000000 +dqor010 or 0000000000000000000000000000000000 0000000000000000000000000000000000 -> 0 +dqor011 or 0000000000000000000000000000000000 0100000000000000000000000000000000 -> 100000000000000000000000000000000 +dqor012 or 0100000000000000000000000000000000 0000000000000000000000000000000000 -> 100000000000000000000000000000000 +dqor013 or 0100000000000000000000000000000000 0100000000000000000000000000000000 -> 100000000000000000000000000000000 + +-- Various lengths +dqor601 or 0111111111111111111111111111111111 1111111111111111111111111111111110 -> 1111111111111111111111111111111111 +dqor602 or 1011111111111111111111111111111111 1111111111111111111111111111111101 -> 1111111111111111111111111111111111 +dqor603 or 1101111111111111111111111111111111 1111111111111111111111111111111011 -> 1111111111111111111111111111111111 +dqor604 or 1110111111111111111111111111111111 1111111111111111111111111111110111 -> 1111111111111111111111111111111111 +dqor605 or 1111011111111111111111111111111111 1111111111111111111111111111101111 -> 1111111111111111111111111111111111 +dqor606 or 1111101111111111111111111111111111 1111111111111111111111111111011111 -> 1111111111111111111111111111111111 +dqor607 or 1111110111111111111111111111111111 1111111111111111111111111110111111 -> 1111111111111111111111111111111111 +dqor608 or 1111111011111111111111111111111111 1111111111111111111111111101111111 -> 1111111111111111111111111111111111 +dqor609 or 1111111101111111111111111111111111 1111111111111111111111111011111111 -> 1111111111111111111111111111111111 +dqor610 or 1111111110111111111111111111111111 1111111111111111111111110111111111 -> 1111111111111111111111111111111111 +dqor611 or 1111111111011111111111111111111111 1111111111111111111111101111111111 -> 1111111111111111111111111111111111 +dqor612 or 1111111111101111111111111111111111 1111111111111111111111011111111111 -> 1111111111111111111111111111111111 +dqor613 or 1111111111110111111111111111111111 1111111111111111111110111111111111 -> 1111111111111111111111111111111111 +dqor614 or 1111111111111011111111111111111111 1111111111111111111101111111111111 -> 1111111111111111111111111111111111 +dqor615 or 1111111111111101111111111111111111 1111111111111111111011111111111111 -> 1111111111111111111111111111111111 +dqor616 or 1111111111111110111111111111111111 1111111111111111110111111111111111 -> 1111111111111111111111111111111111 +dqor617 or 1111111111111111011111111111111111 1111111111111111101111111111111111 -> 1111111111111111111111111111111111 +dqor618 or 1111111111111111101111111111111111 1111111111111111011111111111111111 -> 1111111111111111111111111111111111 +dqor619 or 1111111111111111110111111111111111 1111111111111110111111111111111111 -> 1111111111111111111111111111111111 +dqor620 or 1111111111111111111011111111111111 1111111111111101111111111111111111 -> 1111111111111111111111111111111111 +dqor621 or 1111111111111111111101111111111111 1111111111111011111111111111111111 -> 1111111111111111111111111111111111 +dqor622 or 1111111111111111111110111111111111 1111111111110111111111111111111111 -> 1111111111111111111111111111111111 +dqor623 or 1111111111111111111111011111111111 1111111111101111111111111111111111 -> 1111111111111111111111111111111111 +dqor624 or 1111111111111111111111101111111111 1111111111011111111111111111111111 -> 1111111111111111111111111111111111 +dqor625 or 1111111111111111111111110111111111 1111111110111111111111111111111111 -> 1111111111111111111111111111111111 +dqor626 or 1111111111111111111111111011111111 1111111101111111111111111111111111 -> 1111111111111111111111111111111111 +dqor627 or 1111111111111111111111111101111111 1111111011111111111111111111111111 -> 1111111111111111111111111111111111 +dqor628 or 1111111111111111111111111110111111 1111110111111111111111111111111111 -> 1111111111111111111111111111111111 +dqor629 or 1111111111111111111111111111011111 1111101111111111111111111111111111 -> 1111111111111111111111111111111111 +dqor630 or 1111111111111111111111111111101111 1111011111111111111111111111111111 -> 1111111111111111111111111111111111 +dqor631 or 1111111111111111111111111111110111 1110111111111111111111111111111111 -> 1111111111111111111111111111111111 +dqor632 or 1111111111111111111111111111111011 1101111111111111111111111111111111 -> 1111111111111111111111111111111111 +dqor633 or 1111111111111111111111111111111101 1011111111111111111111111111111111 -> 1111111111111111111111111111111111 +dqor634 or 1111111111111111111111111111111110 0111111111111111111111111111111111 -> 1111111111111111111111111111111111 + +dqor641 or 1111111111111111111111111111111110 0111111111111111111111111111111111 -> 1111111111111111111111111111111111 +dqor642 or 1111111111111111111111111111111101 1011111111111111111111111111111111 -> 1111111111111111111111111111111111 +dqor643 or 1111111111111111111111111111111011 1101111111111111111111111111111111 -> 1111111111111111111111111111111111 +dqor644 or 1111111111111111111111111111110111 1110111111111111111111111111111111 -> 1111111111111111111111111111111111 +dqor645 or 1111111111111111111111111111101111 1111011111111111111111111111111111 -> 1111111111111111111111111111111111 +dqor646 or 1111111111111111111111111111011111 1111101111111111111111111111111111 -> 1111111111111111111111111111111111 +dqor647 or 1111111111111111111111111110111111 1111110111111111111111111111111111 -> 1111111111111111111111111111111111 +dqor648 or 1111111111111111111111111101111111 1111111011111111111111111111111111 -> 1111111111111111111111111111111111 +dqor649 or 1111111111111111111111111011111111 1111111101111111111111111111111111 -> 1111111111111111111111111111111111 +dqor650 or 1111111111111111111111110111111111 1111111110111111111111111111111111 -> 1111111111111111111111111111111111 +dqor651 or 1111111111111111111111101111111111 1111111111011111111111111111111111 -> 1111111111111111111111111111111111 +dqor652 or 1111111111111111111111011111111111 1111111111101111111111111111111111 -> 1111111111111111111111111111111111 +dqor653 or 1111111111111111111110111111111111 1111111111110111111111111111111111 -> 1111111111111111111111111111111111 +dqor654 or 1111111111111111111101111111111111 1111111111111011111111111111111111 -> 1111111111111111111111111111111111 +dqor655 or 1111111111111111111011111111111111 1111111111111101111111111111111111 -> 1111111111111111111111111111111111 +dqor656 or 1111111111111111110111111111111111 1111111111111110111111111111111111 -> 1111111111111111111111111111111111 +dqor657 or 1010101010101010101010101010101010 1010101010101010001010101010101010 -> 1010101010101010101010101010101010 +dqor658 or 1111111111111111011111111111111111 1111111111111111101111111111111111 -> 1111111111111111111111111111111111 +dqor659 or 1111111111111110111111111111111111 1111111111111111110111111111111111 -> 1111111111111111111111111111111111 +dqor660 or 1111111111111101111111111111111111 1111111111111111111011111111111111 -> 1111111111111111111111111111111111 +dqor661 or 1111111111111011111111111111111111 1111111111111111111101111111111111 -> 1111111111111111111111111111111111 +dqor662 or 1111111111110111111111111111111111 1111111111111111111110111111111111 -> 1111111111111111111111111111111111 +dqor663 or 1111111111101111111111111111111111 1111111111111111111111011111111111 -> 1111111111111111111111111111111111 +dqor664 or 1111111111011111111111111111111111 1111111111111111111111101111111111 -> 1111111111111111111111111111111111 +dqor665 or 1111111110111111111111111111111111 1111111111111111111111110111111111 -> 1111111111111111111111111111111111 +dqor666 or 0101010101010101010101010101010101 0101010101010101010101010001010101 -> 101010101010101010101010101010101 +dqor667 or 1111111011111111111111111111111111 1111111111111111111111111101111111 -> 1111111111111111111111111111111111 +dqor668 or 1111110111111111111111111111111111 1111111111111111111111111110111111 -> 1111111111111111111111111111111111 +dqor669 or 1111101111111111111111111111111111 1111111111111111111111111111011111 -> 1111111111111111111111111111111111 +dqor670 or 1111011111111111111111111111111111 1111111111111111111111111111101111 -> 1111111111111111111111111111111111 +dqor671 or 1110111111111111111111111111111111 1111111111111111111111111111110111 -> 1111111111111111111111111111111111 +dqor672 or 1101111111111111111111111111111111 1111111111111111111111111111111011 -> 1111111111111111111111111111111111 +dqor673 or 1011111111111111111111111111111111 1111111111111111111111111111111101 -> 1111111111111111111111111111111111 +dqor674 or 0111111111111111111111111111111111 1111111111111111111111111111111110 -> 1111111111111111111111111111111111 +dqor675 or 0111111111111111111111111111111110 1111111111111111111111111111111110 -> 1111111111111111111111111111111110 +dqor676 or 1111111111111111111111111111111110 1111111111111111111111111111111110 -> 1111111111111111111111111111111110 + +dqor681 or 0111111111111111111111111111111111 0111111111011111111111111111111110 -> 111111111111111111111111111111111 +dqor682 or 1011111111111111111111111111111111 1011111110101111111111111111111101 -> 1011111111111111111111111111111111 +dqor683 or 1101111111111111111111111111111111 1101111101110111111111111111111011 -> 1101111111111111111111111111111111 +dqor684 or 1110111111111111111111111111111111 1110111011111011111111111111110111 -> 1110111111111111111111111111111111 +dqor685 or 1111011111111111111111111111111111 1111010111111101111111111111101111 -> 1111011111111111111111111111111111 +dqor686 or 1111101111111111111111111111111111 1111101111111110111111111111011111 -> 1111101111111111111111111111111111 +dqor687 or 1111110111111111111111111111111111 1111010111111111011111111110111111 -> 1111110111111111111111111111111111 +dqor688 or 1111111011111111111111111111111111 1110111011111111101111111101111111 -> 1111111011111111111111111111111111 +dqor689 or 1111111101111111111111111111111111 1101111101111111110111111011111111 -> 1111111101111111111111111111111111 +dqor690 or 1111111110111111111111111111111111 1011111110111111111011110111111110 -> 1111111110111111111111111111111111 +dqor691 or 1111111111011111111111111111111111 0111111111011111111101101111111101 -> 1111111111011111111111111111111111 +dqor692 or 1111111111101111111111111111111111 1111111111101111111110011111111011 -> 1111111111101111111111111111111111 +dqor693 or 1111111111110111111111111111111111 1111111111110111111110011111110111 -> 1111111111110111111111111111111111 +dqor694 or 1111111111111011111111111111111111 1111111111111011111101101111101111 -> 1111111111111011111111111111111111 +dqor695 or 1111111111111101111111111111111111 1111111111111101111011110111011111 -> 1111111111111101111111111111111111 +dqor696 or 1111111111111110111111111111111111 1111111111111110110111111010111111 -> 1111111111111110111111111111111111 +dqor697 or 1111111111111111011111111111111111 1111111111111111001111111101111111 -> 1111111111111111011111111111111111 +dqor698 or 1111111111111111101111111111111111 1111111111111111001111111010111111 -> 1111111111111111101111111111111111 +dqor699 or 1111111111111111110111111111111111 1111111111111110110111110111011111 -> 1111111111111111110111111111111111 +dqor700 or 1111111111111111111011111111111111 1111111111111101111011101111101111 -> 1111111111111111111011111111111111 +dqor701 or 1111111111111111111101111111111111 1111111111111011111101011111110111 -> 1111111111111111111101111111111111 +dqor702 or 1111111111111111111110111111111111 1111111111110111111110111111111011 -> 1111111111111111111110111111111111 +dqor703 or 1111111111111111111111011111111111 1111111111101111111101011111111101 -> 1111111111111111111111011111111111 +dqor704 or 1111111111111111111111101111111111 1111111111011111111011101111111110 -> 1111111111111111111111101111111111 +dqor705 or 1111111111111111111111110111111111 0111111110111111110111110111111111 -> 1111111111111111111111110111111111 +dqor706 or 1111111111111111111111111011111111 1011111101111111101111111011111111 -> 1111111111111111111111111011111111 +dqor707 or 1111111111111111111111111101111111 1101111011111111011111111101111111 -> 1111111111111111111111111101111111 +dqor708 or 1111111111111111111111111110111111 1110110111111110111111111110111111 -> 1111111111111111111111111110111111 +dqor709 or 1111111111111111111111111111011111 1111001111111101111111111111011111 -> 1111111111111111111111111111011111 +dqor710 or 1111111111111111111111111111101111 1111001111111011111111111111101111 -> 1111111111111111111111111111101111 +dqor711 or 1111111111111111111111111111110111 1110110111110111111111111111110111 -> 1111111111111111111111111111110111 +dqor712 or 1111111111111111111111111111111011 1101111011101111111111111111111011 -> 1111111111111111111111111111111011 +dqor713 or 1111111111111111111111111111111101 1011111101011111111111111111111101 -> 1111111111111111111111111111111101 +dqor714 or 1111111111111111111111111111111110 0111111110111111111111111111111110 -> 1111111111111111111111111111111110 + + + +-- 1234567890123456 1234567890123456 1234567890123456 +dqor020 or 1111111111111111 1111111111111111 -> 1111111111111111 +dqor021 or 111111111111111 111111111111111 -> 111111111111111 +dqor022 or 11111111111111 11111111111111 -> 11111111111111 +dqor023 or 1111111111111 1111111111111 -> 1111111111111 +dqor024 or 111111111111 111111111111 -> 111111111111 +dqor025 or 11111111111 11111111111 -> 11111111111 +dqor026 or 1111111111 1111111111 -> 1111111111 +dqor027 or 111111111 111111111 -> 111111111 +dqor028 or 11111111 11111111 -> 11111111 +dqor029 or 1111111 1111111 -> 1111111 +dqor030 or 111111 111111 -> 111111 +dqor031 or 11111 11111 -> 11111 +dqor032 or 1111 1111 -> 1111 +dqor033 or 111 111 -> 111 +dqor034 or 11 11 -> 11 +dqor035 or 1 1 -> 1 +dqor036 or 0 0 -> 0 + +dqor042 or 111111110000000 1111111110000000 -> 1111111110000000 +dqor043 or 11111110000000 1000000100000000 -> 1011111110000000 +dqor044 or 1111110000000 1000001000000000 -> 1001111110000000 +dqor045 or 111110000000 1000010000000000 -> 1000111110000000 +dqor046 or 11110000000 1000100000000000 -> 1000111110000000 +dqor047 or 1110000000 1001000000000000 -> 1001001110000000 +dqor048 or 110000000 1010000000000000 -> 1010000110000000 +dqor049 or 10000000 1100000000000000 -> 1100000010000000 + +dqor090 or 011111111 111101111 -> 111111111 +dqor091 or 101111111 111101111 -> 111111111 +dqor092 or 110111111 111101111 -> 111111111 +dqor093 or 111011111 111101111 -> 111111111 +dqor094 or 111101111 111101111 -> 111101111 +dqor095 or 111110111 111101111 -> 111111111 +dqor096 or 111111011 111101111 -> 111111111 +dqor097 or 111111101 111101111 -> 111111111 +dqor098 or 111111110 111101111 -> 111111111 + +dqor100 or 111101111 011111111 -> 111111111 +dqor101 or 111101111 101111111 -> 111111111 +dqor102 or 111101111 110111111 -> 111111111 +dqor103 or 111101111 111011111 -> 111111111 +dqor104 or 111101111 111101111 -> 111101111 +dqor105 or 111101111 111110111 -> 111111111 +dqor106 or 111101111 111111011 -> 111111111 +dqor107 or 111101111 111111101 -> 111111111 +dqor108 or 111101111 111111110 -> 111111111 + +-- non-0/1 should not be accepted, nor should signs +dqor220 or 111111112 111111111 -> NaN Invalid_operation +dqor221 or 333333333 333333333 -> NaN Invalid_operation +dqor222 or 555555555 555555555 -> NaN Invalid_operation +dqor223 or 777777777 777777777 -> NaN Invalid_operation +dqor224 or 999999999 999999999 -> NaN Invalid_operation +dqor225 or 222222222 999999999 -> NaN Invalid_operation +dqor226 or 444444444 999999999 -> NaN Invalid_operation +dqor227 or 666666666 999999999 -> NaN Invalid_operation +dqor228 or 888888888 999999999 -> NaN Invalid_operation +dqor229 or 999999999 222222222 -> NaN Invalid_operation +dqor230 or 999999999 444444444 -> NaN Invalid_operation +dqor231 or 999999999 666666666 -> NaN Invalid_operation +dqor232 or 999999999 888888888 -> NaN Invalid_operation +-- a few randoms +dqor240 or 567468689 -934981942 -> NaN Invalid_operation +dqor241 or 567367689 934981942 -> NaN Invalid_operation +dqor242 or -631917772 -706014634 -> NaN Invalid_operation +dqor243 or -756253257 138579234 -> NaN Invalid_operation +dqor244 or 835590149 567435400 -> NaN Invalid_operation +-- test MSD +dqor250 or 2000000111000111000111000000000000 1000000111000111000111000000000000 -> NaN Invalid_operation +dqor251 or 7000000111000111000111000000000000 1000000111000111000111000000000000 -> NaN Invalid_operation +dqor252 or 8000000111000111000111000000000000 1000000111000111000111000000000000 -> NaN Invalid_operation +dqor253 or 9000000111000111000111000000000000 1000000111000111000111000000000000 -> NaN Invalid_operation +dqor254 or 2000000111000111000111000000000000 0000000111000111000111000000000000 -> NaN Invalid_operation +dqor255 or 7000000111000111000111000000000000 0000000111000111000111000000000000 -> NaN Invalid_operation +dqor256 or 8000000111000111000111000000000000 0000000111000111000111000000000000 -> NaN Invalid_operation +dqor257 or 9000000111000111000111000000000000 0000000111000111000111000000000000 -> NaN Invalid_operation +dqor258 or 1000000111000111000111000000000000 2000000111000111000111000000000000 -> NaN Invalid_operation +dqor259 or 1000000111000111000111000000000000 7000000111000111000111000000000000 -> NaN Invalid_operation +dqor260 or 1000000111000111000111000000000000 8000000111000111000111000000000000 -> NaN Invalid_operation +dqor261 or 1000000111000111000111000000000000 9000000111000111000111000000000000 -> NaN Invalid_operation +dqor262 or 0000000111000111000111000000000000 2000000111000111000111000000000000 -> NaN Invalid_operation +dqor263 or 0000000111000111000111000000000000 7000000111000111000111000000000000 -> NaN Invalid_operation +dqor264 or 0000000111000111000111000000000000 8000000111000111000111000000000000 -> NaN Invalid_operation +dqor265 or 0000000111000111000111000000000000 9000000111000111000111000000000000 -> NaN Invalid_operation +-- test MSD-1 +dqor270 or 0200000111000111000111001000000000 1000000111000111000111100000000010 -> NaN Invalid_operation +dqor271 or 0700000111000111000111000100000000 1000000111000111000111010000000100 -> NaN Invalid_operation +dqor272 or 0800000111000111000111000010000000 1000000111000111000111001000001000 -> NaN Invalid_operation +dqor273 or 0900000111000111000111000001000000 1000000111000111000111000100010000 -> NaN Invalid_operation +dqor274 or 1000000111000111000111000000100000 0200000111000111000111000010100000 -> NaN Invalid_operation +dqor275 or 1000000111000111000111000000010000 0700000111000111000111000001000000 -> NaN Invalid_operation +dqor276 or 1000000111000111000111000000001000 0800000111000111000111000010100000 -> NaN Invalid_operation +dqor277 or 1000000111000111000111000000000100 0900000111000111000111000000010000 -> NaN Invalid_operation +-- test LSD +dqor280 or 0010000111000111000111000000000002 1000000111000111000111000100000001 -> NaN Invalid_operation +dqor281 or 0001000111000111000111000000000007 1000000111000111000111001000000011 -> NaN Invalid_operation +dqor282 or 0000000111000111000111100000000008 1000000111000111000111010000000001 -> NaN Invalid_operation +dqor283 or 0000000111000111000111010000000009 1000000111000111000111100000000001 -> NaN Invalid_operation +dqor284 or 1000000111000111000111001000000000 0001000111000111000111000000000002 -> NaN Invalid_operation +dqor285 or 1000000111000111000111000100000000 0010000111000111000111000000000007 -> NaN Invalid_operation +dqor286 or 1000000111000111000111000010000000 0100000111000111000111000000000008 -> NaN Invalid_operation +dqor287 or 1000000111000111000111000001000000 1000000111000111000111000000000009 -> NaN Invalid_operation +-- test Middie +dqor288 or 0010000111000111000111000020000000 1000000111000111000111001000000000 -> NaN Invalid_operation +dqor289 or 0001000111000111000111000070000001 1000000111000111000111000100000000 -> NaN Invalid_operation +dqor290 or 0000000111000111000111100080000010 1000000111000111000111000010000000 -> NaN Invalid_operation +dqor291 or 0000000111000111000111010090000100 1000000111000111000111000001000000 -> NaN Invalid_operation +dqor292 or 1000000111000111000111001000001000 0000000111000111000111000020100000 -> NaN Invalid_operation +dqor293 or 1000000111000111000111000100010000 0000000111000111000111000070010000 -> NaN Invalid_operation +dqor294 or 1000000111000111000111000010100000 0000000111000111000111000080001000 -> NaN Invalid_operation +dqor295 or 1000000111000111000111000001000000 0000000111000111000111000090000100 -> NaN Invalid_operation +-- signs +dqor296 or -1000000111000111000111000001000000 -0000001110001110001110010000000100 -> NaN Invalid_operation +dqor297 or -1000000111000111000111000001000000 0000001110001110001110000010000100 -> NaN Invalid_operation +dqor298 or 1000000111000111000111000001000000 -0000001110001110001110001000000100 -> NaN Invalid_operation +dqor299 or 1000000111000111000111000001000000 0000001110001110001110000011000100 -> 1000001111001111001111000011000100 + +-- Nmax, Nmin, Ntiny-like +dqor331 or 2 9.99999999E+1999 -> NaN Invalid_operation +dqor332 or 3 1E-1999 -> NaN Invalid_operation +dqor333 or 4 1.00000000E-1999 -> NaN Invalid_operation +dqor334 or 5 1E-1009 -> NaN Invalid_operation +dqor335 or 6 -1E-1009 -> NaN Invalid_operation +dqor336 or 7 -1.00000000E-1999 -> NaN Invalid_operation +dqor337 or 8 -1E-1999 -> NaN Invalid_operation +dqor338 or 9 -9.99999999E+1999 -> NaN Invalid_operation +dqor341 or 9.99999999E+2999 -18 -> NaN Invalid_operation +dqor342 or 1E-2999 01 -> NaN Invalid_operation +dqor343 or 1.00000000E-2999 -18 -> NaN Invalid_operation +dqor344 or 1E-1009 18 -> NaN Invalid_operation +dqor345 or -1E-1009 -10 -> NaN Invalid_operation +dqor346 or -1.00000000E-2999 18 -> NaN Invalid_operation +dqor347 or -1E-2999 10 -> NaN Invalid_operation +dqor348 or -9.99999999E+2999 -18 -> NaN Invalid_operation + +-- A few other non-integers +dqor361 or 1.0 1 -> NaN Invalid_operation +dqor362 or 1E+1 1 -> NaN Invalid_operation +dqor363 or 0.0 1 -> NaN Invalid_operation +dqor364 or 0E+1 1 -> NaN Invalid_operation +dqor365 or 9.9 1 -> NaN Invalid_operation +dqor366 or 9E+1 1 -> NaN Invalid_operation +dqor371 or 0 1.0 -> NaN Invalid_operation +dqor372 or 0 1E+1 -> NaN Invalid_operation +dqor373 or 0 0.0 -> NaN Invalid_operation +dqor374 or 0 0E+1 -> NaN Invalid_operation +dqor375 or 0 9.9 -> NaN Invalid_operation +dqor376 or 0 9E+1 -> NaN Invalid_operation + +-- All Specials are in error +dqor780 or -Inf -Inf -> NaN Invalid_operation +dqor781 or -Inf -1000 -> NaN Invalid_operation +dqor782 or -Inf -1 -> NaN Invalid_operation +dqor783 or -Inf -0 -> NaN Invalid_operation +dqor784 or -Inf 0 -> NaN Invalid_operation +dqor785 or -Inf 1 -> NaN Invalid_operation +dqor786 or -Inf 1000 -> NaN Invalid_operation +dqor787 or -1000 -Inf -> NaN Invalid_operation +dqor788 or -Inf -Inf -> NaN Invalid_operation +dqor789 or -1 -Inf -> NaN Invalid_operation +dqor790 or -0 -Inf -> NaN Invalid_operation +dqor791 or 0 -Inf -> NaN Invalid_operation +dqor792 or 1 -Inf -> NaN Invalid_operation +dqor793 or 1000 -Inf -> NaN Invalid_operation +dqor794 or Inf -Inf -> NaN Invalid_operation + +dqor800 or Inf -Inf -> NaN Invalid_operation +dqor801 or Inf -1000 -> NaN Invalid_operation +dqor802 or Inf -1 -> NaN Invalid_operation +dqor803 or Inf -0 -> NaN Invalid_operation +dqor804 or Inf 0 -> NaN Invalid_operation +dqor805 or Inf 1 -> NaN Invalid_operation +dqor806 or Inf 1000 -> NaN Invalid_operation +dqor807 or Inf Inf -> NaN Invalid_operation +dqor808 or -1000 Inf -> NaN Invalid_operation +dqor809 or -Inf Inf -> NaN Invalid_operation +dqor810 or -1 Inf -> NaN Invalid_operation +dqor811 or -0 Inf -> NaN Invalid_operation +dqor812 or 0 Inf -> NaN Invalid_operation +dqor813 or 1 Inf -> NaN Invalid_operation +dqor814 or 1000 Inf -> NaN Invalid_operation +dqor815 or Inf Inf -> NaN Invalid_operation + +dqor821 or NaN -Inf -> NaN Invalid_operation +dqor822 or NaN -1000 -> NaN Invalid_operation +dqor823 or NaN -1 -> NaN Invalid_operation +dqor824 or NaN -0 -> NaN Invalid_operation +dqor825 or NaN 0 -> NaN Invalid_operation +dqor826 or NaN 1 -> NaN Invalid_operation +dqor827 or NaN 1000 -> NaN Invalid_operation +dqor828 or NaN Inf -> NaN Invalid_operation +dqor829 or NaN NaN -> NaN Invalid_operation +dqor830 or -Inf NaN -> NaN Invalid_operation +dqor831 or -1000 NaN -> NaN Invalid_operation +dqor832 or -1 NaN -> NaN Invalid_operation +dqor833 or -0 NaN -> NaN Invalid_operation +dqor834 or 0 NaN -> NaN Invalid_operation +dqor835 or 1 NaN -> NaN Invalid_operation +dqor836 or 1000 NaN -> NaN Invalid_operation +dqor837 or Inf NaN -> NaN Invalid_operation + +dqor841 or sNaN -Inf -> NaN Invalid_operation +dqor842 or sNaN -1000 -> NaN Invalid_operation +dqor843 or sNaN -1 -> NaN Invalid_operation +dqor844 or sNaN -0 -> NaN Invalid_operation +dqor845 or sNaN 0 -> NaN Invalid_operation +dqor846 or sNaN 1 -> NaN Invalid_operation +dqor847 or sNaN 1000 -> NaN Invalid_operation +dqor848 or sNaN NaN -> NaN Invalid_operation +dqor849 or sNaN sNaN -> NaN Invalid_operation +dqor850 or NaN sNaN -> NaN Invalid_operation +dqor851 or -Inf sNaN -> NaN Invalid_operation +dqor852 or -1000 sNaN -> NaN Invalid_operation +dqor853 or -1 sNaN -> NaN Invalid_operation +dqor854 or -0 sNaN -> NaN Invalid_operation +dqor855 or 0 sNaN -> NaN Invalid_operation +dqor856 or 1 sNaN -> NaN Invalid_operation +dqor857 or 1000 sNaN -> NaN Invalid_operation +dqor858 or Inf sNaN -> NaN Invalid_operation +dqor859 or NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +dqor861 or NaN1 -Inf -> NaN Invalid_operation +dqor862 or +NaN2 -1000 -> NaN Invalid_operation +dqor863 or NaN3 1000 -> NaN Invalid_operation +dqor864 or NaN4 Inf -> NaN Invalid_operation +dqor865 or NaN5 +NaN6 -> NaN Invalid_operation +dqor866 or -Inf NaN7 -> NaN Invalid_operation +dqor867 or -1000 NaN8 -> NaN Invalid_operation +dqor868 or 1000 NaN9 -> NaN Invalid_operation +dqor869 or Inf +NaN10 -> NaN Invalid_operation +dqor871 or sNaN11 -Inf -> NaN Invalid_operation +dqor872 or sNaN12 -1000 -> NaN Invalid_operation +dqor873 or sNaN13 1000 -> NaN Invalid_operation +dqor874 or sNaN14 NaN17 -> NaN Invalid_operation +dqor875 or sNaN15 sNaN18 -> NaN Invalid_operation +dqor876 or NaN16 sNaN19 -> NaN Invalid_operation +dqor877 or -Inf +sNaN20 -> NaN Invalid_operation +dqor878 or -1000 sNaN21 -> NaN Invalid_operation +dqor879 or 1000 sNaN22 -> NaN Invalid_operation +dqor880 or Inf sNaN23 -> NaN Invalid_operation +dqor881 or +NaN25 +sNaN24 -> NaN Invalid_operation +dqor882 or -NaN26 NaN28 -> NaN Invalid_operation +dqor883 or -sNaN27 sNaN29 -> NaN Invalid_operation +dqor884 or 1000 -NaN30 -> NaN Invalid_operation +dqor885 or 1000 -sNaN31 -> NaN Invalid_operation Added: python/branches/release25-maint/Lib/test/decimaltestdata/dqPlus.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/dqPlus.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,88 @@ +------------------------------------------------------------------------ +-- dqPlus.decTest -- decQuad 0+x -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- All operands and results are decQuads. +extended: 1 +clamp: 1 +precision: 34 +maxExponent: 6144 +minExponent: -6143 +rounding: half_even + +-- Sanity check +dqpls001 plus +7.50 -> 7.50 + +-- Infinities +dqpls011 plus Infinity -> Infinity +dqpls012 plus -Infinity -> -Infinity + +-- NaNs, 0 payload +ddqls021 plus NaN -> NaN +ddqls022 plus -NaN -> -NaN +ddqls023 plus sNaN -> NaN Invalid_operation +ddqls024 plus -sNaN -> -NaN Invalid_operation + +-- NaNs, non-0 payload +ddqls031 plus NaN13 -> NaN13 +ddqls032 plus -NaN13 -> -NaN13 +ddqls033 plus sNaN13 -> NaN13 Invalid_operation +ddqls034 plus -sNaN13 -> -NaN13 Invalid_operation +ddqls035 plus NaN70 -> NaN70 +ddqls036 plus -NaN70 -> -NaN70 +ddqls037 plus sNaN101 -> NaN101 Invalid_operation +ddqls038 plus -sNaN101 -> -NaN101 Invalid_operation + +-- finites +dqpls101 plus 7 -> 7 +dqpls102 plus -7 -> -7 +dqpls103 plus 75 -> 75 +dqpls104 plus -75 -> -75 +dqpls105 plus 7.50 -> 7.50 +dqpls106 plus -7.50 -> -7.50 +dqpls107 plus 7.500 -> 7.500 +dqpls108 plus -7.500 -> -7.500 + +-- zeros +dqpls111 plus 0 -> 0 +dqpls112 plus -0 -> 0 +dqpls113 plus 0E+4 -> 0E+4 +dqpls114 plus -0E+4 -> 0E+4 +dqpls115 plus 0.0000 -> 0.0000 +dqpls116 plus -0.0000 -> 0.0000 +dqpls117 plus 0E-141 -> 0E-141 +dqpls118 plus -0E-141 -> 0E-141 + +-- full coefficients, alternating bits +dqpls121 plus 2682682682682682682682682682682682 -> 2682682682682682682682682682682682 +dqpls122 plus -2682682682682682682682682682682682 -> -2682682682682682682682682682682682 +dqpls123 plus 1341341341341341341341341341341341 -> 1341341341341341341341341341341341 +dqpls124 plus -1341341341341341341341341341341341 -> -1341341341341341341341341341341341 + +-- Nmax, Nmin, Ntiny +dqpls131 plus 9.999999999999999999999999999999999E+6144 -> 9.999999999999999999999999999999999E+6144 +dqpls132 plus 1E-6143 -> 1E-6143 +dqpls133 plus 1.000000000000000000000000000000000E-6143 -> 1.000000000000000000000000000000000E-6143 +dqpls134 plus 1E-6176 -> 1E-6176 Subnormal + +dqpls135 plus -1E-6176 -> -1E-6176 Subnormal +dqpls136 plus -1.000000000000000000000000000000000E-6143 -> -1.000000000000000000000000000000000E-6143 +dqpls137 plus -1E-6143 -> -1E-6143 +dqpls138 plus -9.999999999999999999999999999999999E+6144 -> -9.999999999999999999999999999999999E+6144 Added: python/branches/release25-maint/Lib/test/decimaltestdata/dqQuantize.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/dqQuantize.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,823 @@ +------------------------------------------------------------------------ +-- dqQuantize.decTest -- decQuad quantize operation -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- Most of the tests here assume a "regular pattern", where the +-- sign and coefficient are +1. +-- 2004.03.15 Underflow for quantize is suppressed +-- 2005.06.08 More extensive tests for 'does not fit' +-- [Forked from quantize.decTest 2006.11.25] + +extended: 1 +clamp: 1 +precision: 34 +maxExponent: 6144 +minExponent: -6143 +rounding: half_even + +-- sanity checks +dqqua001 quantize 0 1e0 -> 0 +dqqua002 quantize 1 1e0 -> 1 +dqqua003 quantize 0.1 1e+2 -> 0E+2 Inexact Rounded +dqqua005 quantize 0.1 1e+1 -> 0E+1 Inexact Rounded +dqqua006 quantize 0.1 1e0 -> 0 Inexact Rounded +dqqua007 quantize 0.1 1e-1 -> 0.1 +dqqua008 quantize 0.1 1e-2 -> 0.10 +dqqua009 quantize 0.1 1e-3 -> 0.100 +dqqua010 quantize 0.9 1e+2 -> 0E+2 Inexact Rounded +dqqua011 quantize 0.9 1e+1 -> 0E+1 Inexact Rounded +dqqua012 quantize 0.9 1e+0 -> 1 Inexact Rounded +dqqua013 quantize 0.9 1e-1 -> 0.9 +dqqua014 quantize 0.9 1e-2 -> 0.90 +dqqua015 quantize 0.9 1e-3 -> 0.900 +-- negatives +dqqua021 quantize -0 1e0 -> -0 +dqqua022 quantize -1 1e0 -> -1 +dqqua023 quantize -0.1 1e+2 -> -0E+2 Inexact Rounded +dqqua025 quantize -0.1 1e+1 -> -0E+1 Inexact Rounded +dqqua026 quantize -0.1 1e0 -> -0 Inexact Rounded +dqqua027 quantize -0.1 1e-1 -> -0.1 +dqqua028 quantize -0.1 1e-2 -> -0.10 +dqqua029 quantize -0.1 1e-3 -> -0.100 +dqqua030 quantize -0.9 1e+2 -> -0E+2 Inexact Rounded +dqqua031 quantize -0.9 1e+1 -> -0E+1 Inexact Rounded +dqqua032 quantize -0.9 1e+0 -> -1 Inexact Rounded +dqqua033 quantize -0.9 1e-1 -> -0.9 +dqqua034 quantize -0.9 1e-2 -> -0.90 +dqqua035 quantize -0.9 1e-3 -> -0.900 +dqqua036 quantize -0.5 1e+2 -> -0E+2 Inexact Rounded +dqqua037 quantize -0.5 1e+1 -> -0E+1 Inexact Rounded +dqqua038 quantize -0.5 1e+0 -> -0 Inexact Rounded +dqqua039 quantize -0.5 1e-1 -> -0.5 +dqqua040 quantize -0.5 1e-2 -> -0.50 +dqqua041 quantize -0.5 1e-3 -> -0.500 +dqqua042 quantize -0.9 1e+2 -> -0E+2 Inexact Rounded +dqqua043 quantize -0.9 1e+1 -> -0E+1 Inexact Rounded +dqqua044 quantize -0.9 1e+0 -> -1 Inexact Rounded +dqqua045 quantize -0.9 1e-1 -> -0.9 +dqqua046 quantize -0.9 1e-2 -> -0.90 +dqqua047 quantize -0.9 1e-3 -> -0.900 + +-- examples from Specification +dqqua060 quantize 2.17 0.001 -> 2.170 +dqqua061 quantize 2.17 0.01 -> 2.17 +dqqua062 quantize 2.17 0.1 -> 2.2 Inexact Rounded +dqqua063 quantize 2.17 1e+0 -> 2 Inexact Rounded +dqqua064 quantize 2.17 1e+1 -> 0E+1 Inexact Rounded +dqqua065 quantize -Inf Inf -> -Infinity +dqqua066 quantize 2 Inf -> NaN Invalid_operation +dqqua067 quantize -0.1 1 -> -0 Inexact Rounded +dqqua068 quantize -0 1e+5 -> -0E+5 +dqqua069 quantize +123451234567899876543216789012345.6 1e-2 -> NaN Invalid_operation +dqqua070 quantize -987651234567899876543214335236450.6 1e-2 -> NaN Invalid_operation +dqqua071 quantize 217 1e-1 -> 217.0 +dqqua072 quantize 217 1e+0 -> 217 +dqqua073 quantize 217 1e+1 -> 2.2E+2 Inexact Rounded +dqqua074 quantize 217 1e+2 -> 2E+2 Inexact Rounded + +-- general tests .. +dqqua089 quantize 12 1e+4 -> 0E+4 Inexact Rounded +dqqua090 quantize 12 1e+3 -> 0E+3 Inexact Rounded +dqqua091 quantize 12 1e+2 -> 0E+2 Inexact Rounded +dqqua092 quantize 12 1e+1 -> 1E+1 Inexact Rounded +dqqua093 quantize 1.2345 1e-2 -> 1.23 Inexact Rounded +dqqua094 quantize 1.2355 1e-2 -> 1.24 Inexact Rounded +dqqua095 quantize 1.2345 1e-6 -> 1.234500 +dqqua096 quantize 9.9999 1e-2 -> 10.00 Inexact Rounded +dqqua097 quantize 0.0001 1e-2 -> 0.00 Inexact Rounded +dqqua098 quantize 0.001 1e-2 -> 0.00 Inexact Rounded +dqqua099 quantize 0.009 1e-2 -> 0.01 Inexact Rounded +dqqua100 quantize 92 1e+2 -> 1E+2 Inexact Rounded + +dqqua101 quantize -1 1e0 -> -1 +dqqua102 quantize -1 1e-1 -> -1.0 +dqqua103 quantize -1 1e-2 -> -1.00 +dqqua104 quantize 0 1e0 -> 0 +dqqua105 quantize 0 1e-1 -> 0.0 +dqqua106 quantize 0 1e-2 -> 0.00 +dqqua107 quantize 0.00 1e0 -> 0 +dqqua108 quantize 0 1e+1 -> 0E+1 +dqqua109 quantize 0 1e+2 -> 0E+2 +dqqua110 quantize +1 1e0 -> 1 +dqqua111 quantize +1 1e-1 -> 1.0 +dqqua112 quantize +1 1e-2 -> 1.00 + +dqqua120 quantize 1.04 1e-3 -> 1.040 +dqqua121 quantize 1.04 1e-2 -> 1.04 +dqqua122 quantize 1.04 1e-1 -> 1.0 Inexact Rounded +dqqua123 quantize 1.04 1e0 -> 1 Inexact Rounded +dqqua124 quantize 1.05 1e-3 -> 1.050 +dqqua125 quantize 1.05 1e-2 -> 1.05 +dqqua126 quantize 1.05 1e-1 -> 1.0 Inexact Rounded +dqqua131 quantize 1.05 1e0 -> 1 Inexact Rounded +dqqua132 quantize 1.06 1e-3 -> 1.060 +dqqua133 quantize 1.06 1e-2 -> 1.06 +dqqua134 quantize 1.06 1e-1 -> 1.1 Inexact Rounded +dqqua135 quantize 1.06 1e0 -> 1 Inexact Rounded + +dqqua140 quantize -10 1e-2 -> -10.00 +dqqua141 quantize +1 1e-2 -> 1.00 +dqqua142 quantize +10 1e-2 -> 10.00 +dqqua143 quantize 1E+37 1e-2 -> NaN Invalid_operation +dqqua144 quantize 1E-37 1e-2 -> 0.00 Inexact Rounded +dqqua145 quantize 1E-3 1e-2 -> 0.00 Inexact Rounded +dqqua146 quantize 1E-2 1e-2 -> 0.01 +dqqua147 quantize 1E-1 1e-2 -> 0.10 +dqqua148 quantize 0E-37 1e-2 -> 0.00 + +dqqua150 quantize 1.0600 1e-5 -> 1.06000 +dqqua151 quantize 1.0600 1e-4 -> 1.0600 +dqqua152 quantize 1.0600 1e-3 -> 1.060 Rounded +dqqua153 quantize 1.0600 1e-2 -> 1.06 Rounded +dqqua154 quantize 1.0600 1e-1 -> 1.1 Inexact Rounded +dqqua155 quantize 1.0600 1e0 -> 1 Inexact Rounded + +-- a couple where rounding was different in base tests +rounding: half_up +dqqua157 quantize -0.5 1e+0 -> -1 Inexact Rounded +dqqua158 quantize 1.05 1e-1 -> 1.1 Inexact Rounded +dqqua159 quantize 1.06 1e0 -> 1 Inexact Rounded +rounding: half_even + +-- base tests with non-1 coefficients +dqqua161 quantize 0 -9e0 -> 0 +dqqua162 quantize 1 -7e0 -> 1 +dqqua163 quantize 0.1 -1e+2 -> 0E+2 Inexact Rounded +dqqua165 quantize 0.1 0e+1 -> 0E+1 Inexact Rounded +dqqua166 quantize 0.1 2e0 -> 0 Inexact Rounded +dqqua167 quantize 0.1 3e-1 -> 0.1 +dqqua168 quantize 0.1 44e-2 -> 0.10 +dqqua169 quantize 0.1 555e-3 -> 0.100 +dqqua170 quantize 0.9 6666e+2 -> 0E+2 Inexact Rounded +dqqua171 quantize 0.9 -777e+1 -> 0E+1 Inexact Rounded +dqqua172 quantize 0.9 -88e+0 -> 1 Inexact Rounded +dqqua173 quantize 0.9 -9e-1 -> 0.9 +dqqua174 quantize 0.9 0e-2 -> 0.90 +dqqua175 quantize 0.9 1.1e-3 -> 0.9000 +-- negatives +dqqua181 quantize -0 1.1e0 -> -0.0 +dqqua182 quantize -1 -1e0 -> -1 +dqqua183 quantize -0.1 11e+2 -> -0E+2 Inexact Rounded +dqqua185 quantize -0.1 111e+1 -> -0E+1 Inexact Rounded +dqqua186 quantize -0.1 71e0 -> -0 Inexact Rounded +dqqua187 quantize -0.1 -91e-1 -> -0.1 +dqqua188 quantize -0.1 -.1e-2 -> -0.100 +dqqua189 quantize -0.1 -1e-3 -> -0.100 +dqqua190 quantize -0.9 0e+2 -> -0E+2 Inexact Rounded +dqqua191 quantize -0.9 -0e+1 -> -0E+1 Inexact Rounded +dqqua192 quantize -0.9 -10e+0 -> -1 Inexact Rounded +dqqua193 quantize -0.9 100e-1 -> -0.9 +dqqua194 quantize -0.9 999e-2 -> -0.90 + +-- +ve exponents .. +dqqua201 quantize -1 1e+0 -> -1 +dqqua202 quantize -1 1e+1 -> -0E+1 Inexact Rounded +dqqua203 quantize -1 1e+2 -> -0E+2 Inexact Rounded +dqqua204 quantize 0 1e+0 -> 0 +dqqua205 quantize 0 1e+1 -> 0E+1 +dqqua206 quantize 0 1e+2 -> 0E+2 +dqqua207 quantize +1 1e+0 -> 1 +dqqua208 quantize +1 1e+1 -> 0E+1 Inexact Rounded +dqqua209 quantize +1 1e+2 -> 0E+2 Inexact Rounded + +dqqua220 quantize 1.04 1e+3 -> 0E+3 Inexact Rounded +dqqua221 quantize 1.04 1e+2 -> 0E+2 Inexact Rounded +dqqua222 quantize 1.04 1e+1 -> 0E+1 Inexact Rounded +dqqua223 quantize 1.04 1e+0 -> 1 Inexact Rounded +dqqua224 quantize 1.05 1e+3 -> 0E+3 Inexact Rounded +dqqua225 quantize 1.05 1e+2 -> 0E+2 Inexact Rounded +dqqua226 quantize 1.05 1e+1 -> 0E+1 Inexact Rounded +dqqua227 quantize 1.05 1e+0 -> 1 Inexact Rounded +dqqua228 quantize 1.05 1e+3 -> 0E+3 Inexact Rounded +dqqua229 quantize 1.05 1e+2 -> 0E+2 Inexact Rounded +dqqua230 quantize 1.05 1e+1 -> 0E+1 Inexact Rounded +dqqua231 quantize 1.05 1e+0 -> 1 Inexact Rounded +dqqua232 quantize 1.06 1e+3 -> 0E+3 Inexact Rounded +dqqua233 quantize 1.06 1e+2 -> 0E+2 Inexact Rounded +dqqua234 quantize 1.06 1e+1 -> 0E+1 Inexact Rounded +dqqua235 quantize 1.06 1e+0 -> 1 Inexact Rounded + +dqqua240 quantize -10 1e+1 -> -1E+1 Rounded +dqqua241 quantize +1 1e+1 -> 0E+1 Inexact Rounded +dqqua242 quantize +10 1e+1 -> 1E+1 Rounded +dqqua243 quantize 1E+1 1e+1 -> 1E+1 -- underneath this is E+1 +dqqua244 quantize 1E+2 1e+1 -> 1.0E+2 -- underneath this is E+1 +dqqua245 quantize 1E+3 1e+1 -> 1.00E+3 -- underneath this is E+1 +dqqua246 quantize 1E+4 1e+1 -> 1.000E+4 -- underneath this is E+1 +dqqua247 quantize 1E+5 1e+1 -> 1.0000E+5 -- underneath this is E+1 +dqqua248 quantize 1E+6 1e+1 -> 1.00000E+6 -- underneath this is E+1 +dqqua249 quantize 1E+7 1e+1 -> 1.000000E+7 -- underneath this is E+1 +dqqua250 quantize 1E+8 1e+1 -> 1.0000000E+8 -- underneath this is E+1 +dqqua251 quantize 1E+9 1e+1 -> 1.00000000E+9 -- underneath this is E+1 +-- next one tries to add 9 zeros +dqqua252 quantize 1E+37 1e+1 -> NaN Invalid_operation +dqqua253 quantize 1E-37 1e+1 -> 0E+1 Inexact Rounded +dqqua254 quantize 1E-2 1e+1 -> 0E+1 Inexact Rounded +dqqua255 quantize 0E-37 1e+1 -> 0E+1 +dqqua256 quantize -0E-37 1e+1 -> -0E+1 +dqqua257 quantize -0E-1 1e+1 -> -0E+1 +dqqua258 quantize -0 1e+1 -> -0E+1 +dqqua259 quantize -0E+1 1e+1 -> -0E+1 + +dqqua260 quantize -10 1e+2 -> -0E+2 Inexact Rounded +dqqua261 quantize +1 1e+2 -> 0E+2 Inexact Rounded +dqqua262 quantize +10 1e+2 -> 0E+2 Inexact Rounded +dqqua263 quantize 1E+1 1e+2 -> 0E+2 Inexact Rounded +dqqua264 quantize 1E+2 1e+2 -> 1E+2 +dqqua265 quantize 1E+3 1e+2 -> 1.0E+3 +dqqua266 quantize 1E+4 1e+2 -> 1.00E+4 +dqqua267 quantize 1E+5 1e+2 -> 1.000E+5 +dqqua268 quantize 1E+6 1e+2 -> 1.0000E+6 +dqqua269 quantize 1E+7 1e+2 -> 1.00000E+7 +dqqua270 quantize 1E+8 1e+2 -> 1.000000E+8 +dqqua271 quantize 1E+9 1e+2 -> 1.0000000E+9 +dqqua272 quantize 1E+10 1e+2 -> 1.00000000E+10 +dqqua273 quantize 1E-10 1e+2 -> 0E+2 Inexact Rounded +dqqua274 quantize 1E-2 1e+2 -> 0E+2 Inexact Rounded +dqqua275 quantize 0E-10 1e+2 -> 0E+2 + +dqqua280 quantize -10 1e+3 -> -0E+3 Inexact Rounded +dqqua281 quantize +1 1e+3 -> 0E+3 Inexact Rounded +dqqua282 quantize +10 1e+3 -> 0E+3 Inexact Rounded +dqqua283 quantize 1E+1 1e+3 -> 0E+3 Inexact Rounded +dqqua284 quantize 1E+2 1e+3 -> 0E+3 Inexact Rounded +dqqua285 quantize 1E+3 1e+3 -> 1E+3 +dqqua286 quantize 1E+4 1e+3 -> 1.0E+4 +dqqua287 quantize 1E+5 1e+3 -> 1.00E+5 +dqqua288 quantize 1E+6 1e+3 -> 1.000E+6 +dqqua289 quantize 1E+7 1e+3 -> 1.0000E+7 +dqqua290 quantize 1E+8 1e+3 -> 1.00000E+8 +dqqua291 quantize 1E+9 1e+3 -> 1.000000E+9 +dqqua292 quantize 1E+10 1e+3 -> 1.0000000E+10 +dqqua293 quantize 1E-10 1e+3 -> 0E+3 Inexact Rounded +dqqua294 quantize 1E-2 1e+3 -> 0E+3 Inexact Rounded +dqqua295 quantize 0E-10 1e+3 -> 0E+3 + +-- round up from below [sign wrong in JIT compiler once] +dqqua300 quantize 0.0078 1e-5 -> 0.00780 +dqqua301 quantize 0.0078 1e-4 -> 0.0078 +dqqua302 quantize 0.0078 1e-3 -> 0.008 Inexact Rounded +dqqua303 quantize 0.0078 1e-2 -> 0.01 Inexact Rounded +dqqua304 quantize 0.0078 1e-1 -> 0.0 Inexact Rounded +dqqua305 quantize 0.0078 1e0 -> 0 Inexact Rounded +dqqua306 quantize 0.0078 1e+1 -> 0E+1 Inexact Rounded +dqqua307 quantize 0.0078 1e+2 -> 0E+2 Inexact Rounded + +dqqua310 quantize -0.0078 1e-5 -> -0.00780 +dqqua311 quantize -0.0078 1e-4 -> -0.0078 +dqqua312 quantize -0.0078 1e-3 -> -0.008 Inexact Rounded +dqqua313 quantize -0.0078 1e-2 -> -0.01 Inexact Rounded +dqqua314 quantize -0.0078 1e-1 -> -0.0 Inexact Rounded +dqqua315 quantize -0.0078 1e0 -> -0 Inexact Rounded +dqqua316 quantize -0.0078 1e+1 -> -0E+1 Inexact Rounded +dqqua317 quantize -0.0078 1e+2 -> -0E+2 Inexact Rounded + +dqqua320 quantize 0.078 1e-5 -> 0.07800 +dqqua321 quantize 0.078 1e-4 -> 0.0780 +dqqua322 quantize 0.078 1e-3 -> 0.078 +dqqua323 quantize 0.078 1e-2 -> 0.08 Inexact Rounded +dqqua324 quantize 0.078 1e-1 -> 0.1 Inexact Rounded +dqqua325 quantize 0.078 1e0 -> 0 Inexact Rounded +dqqua326 quantize 0.078 1e+1 -> 0E+1 Inexact Rounded +dqqua327 quantize 0.078 1e+2 -> 0E+2 Inexact Rounded + +dqqua330 quantize -0.078 1e-5 -> -0.07800 +dqqua331 quantize -0.078 1e-4 -> -0.0780 +dqqua332 quantize -0.078 1e-3 -> -0.078 +dqqua333 quantize -0.078 1e-2 -> -0.08 Inexact Rounded +dqqua334 quantize -0.078 1e-1 -> -0.1 Inexact Rounded +dqqua335 quantize -0.078 1e0 -> -0 Inexact Rounded +dqqua336 quantize -0.078 1e+1 -> -0E+1 Inexact Rounded +dqqua337 quantize -0.078 1e+2 -> -0E+2 Inexact Rounded + +dqqua340 quantize 0.78 1e-5 -> 0.78000 +dqqua341 quantize 0.78 1e-4 -> 0.7800 +dqqua342 quantize 0.78 1e-3 -> 0.780 +dqqua343 quantize 0.78 1e-2 -> 0.78 +dqqua344 quantize 0.78 1e-1 -> 0.8 Inexact Rounded +dqqua345 quantize 0.78 1e0 -> 1 Inexact Rounded +dqqua346 quantize 0.78 1e+1 -> 0E+1 Inexact Rounded +dqqua347 quantize 0.78 1e+2 -> 0E+2 Inexact Rounded + +dqqua350 quantize -0.78 1e-5 -> -0.78000 +dqqua351 quantize -0.78 1e-4 -> -0.7800 +dqqua352 quantize -0.78 1e-3 -> -0.780 +dqqua353 quantize -0.78 1e-2 -> -0.78 +dqqua354 quantize -0.78 1e-1 -> -0.8 Inexact Rounded +dqqua355 quantize -0.78 1e0 -> -1 Inexact Rounded +dqqua356 quantize -0.78 1e+1 -> -0E+1 Inexact Rounded +dqqua357 quantize -0.78 1e+2 -> -0E+2 Inexact Rounded + +dqqua360 quantize 7.8 1e-5 -> 7.80000 +dqqua361 quantize 7.8 1e-4 -> 7.8000 +dqqua362 quantize 7.8 1e-3 -> 7.800 +dqqua363 quantize 7.8 1e-2 -> 7.80 +dqqua364 quantize 7.8 1e-1 -> 7.8 +dqqua365 quantize 7.8 1e0 -> 8 Inexact Rounded +dqqua366 quantize 7.8 1e+1 -> 1E+1 Inexact Rounded +dqqua367 quantize 7.8 1e+2 -> 0E+2 Inexact Rounded +dqqua368 quantize 7.8 1e+3 -> 0E+3 Inexact Rounded + +dqqua370 quantize -7.8 1e-5 -> -7.80000 +dqqua371 quantize -7.8 1e-4 -> -7.8000 +dqqua372 quantize -7.8 1e-3 -> -7.800 +dqqua373 quantize -7.8 1e-2 -> -7.80 +dqqua374 quantize -7.8 1e-1 -> -7.8 +dqqua375 quantize -7.8 1e0 -> -8 Inexact Rounded +dqqua376 quantize -7.8 1e+1 -> -1E+1 Inexact Rounded +dqqua377 quantize -7.8 1e+2 -> -0E+2 Inexact Rounded +dqqua378 quantize -7.8 1e+3 -> -0E+3 Inexact Rounded + +-- some individuals +dqqua380 quantize 1122334455667788991234567352364.506 1e-2 -> 1122334455667788991234567352364.51 Inexact Rounded +dqqua381 quantize 11223344556677889912345673523645.06 1e-2 -> 11223344556677889912345673523645.06 +dqqua382 quantize 112233445566778899123456735236450.6 1e-2 -> NaN Invalid_operation +dqqua383 quantize 1122334455667788991234567352364506 1e-2 -> NaN Invalid_operation +dqqua384 quantize -1122334455667788991234567352364.506 1e-2 -> -1122334455667788991234567352364.51 Inexact Rounded +dqqua385 quantize -11223344556677889912345673523645.06 1e-2 -> -11223344556677889912345673523645.06 +dqqua386 quantize -112233445566778899123456735236450.6 1e-2 -> NaN Invalid_operation +dqqua387 quantize -1122334455667788991234567352364506 1e-2 -> NaN Invalid_operation + +rounding: down +dqqua389 quantize 112233445566778899123456735236450.6 1e-2 -> NaN Invalid_operation +-- ? should that one instead have been: +-- dqqua389 quantize 112233445566778899123456735236450.6 1e-2 -> NaN Invalid_operation +rounding: half_up + +-- and a few more from e-mail discussions +dqqua391 quantize 11223344556677889912345678912.34567 1e-3 -> 11223344556677889912345678912.346 Inexact Rounded +dqqua392 quantize 112233445566778899123456789123.4567 1e-3 -> 112233445566778899123456789123.457 Inexact Rounded +dqqua393 quantize 1122334455667788991234567891234567. 1e-3 -> NaN Invalid_operation + +-- some 9999 round-up cases +dqqua400 quantize 9.999 1e-5 -> 9.99900 +dqqua401 quantize 9.999 1e-4 -> 9.9990 +dqqua402 quantize 9.999 1e-3 -> 9.999 +dqqua403 quantize 9.999 1e-2 -> 10.00 Inexact Rounded +dqqua404 quantize 9.999 1e-1 -> 10.0 Inexact Rounded +dqqua405 quantize 9.999 1e0 -> 10 Inexact Rounded +dqqua406 quantize 9.999 1e1 -> 1E+1 Inexact Rounded +dqqua407 quantize 9.999 1e2 -> 0E+2 Inexact Rounded + +dqqua410 quantize 0.999 1e-5 -> 0.99900 +dqqua411 quantize 0.999 1e-4 -> 0.9990 +dqqua412 quantize 0.999 1e-3 -> 0.999 +dqqua413 quantize 0.999 1e-2 -> 1.00 Inexact Rounded +dqqua414 quantize 0.999 1e-1 -> 1.0 Inexact Rounded +dqqua415 quantize 0.999 1e0 -> 1 Inexact Rounded +dqqua416 quantize 0.999 1e1 -> 0E+1 Inexact Rounded + +dqqua420 quantize 0.0999 1e-5 -> 0.09990 +dqqua421 quantize 0.0999 1e-4 -> 0.0999 +dqqua422 quantize 0.0999 1e-3 -> 0.100 Inexact Rounded +dqqua423 quantize 0.0999 1e-2 -> 0.10 Inexact Rounded +dqqua424 quantize 0.0999 1e-1 -> 0.1 Inexact Rounded +dqqua425 quantize 0.0999 1e0 -> 0 Inexact Rounded +dqqua426 quantize 0.0999 1e1 -> 0E+1 Inexact Rounded + +dqqua430 quantize 0.00999 1e-5 -> 0.00999 +dqqua431 quantize 0.00999 1e-4 -> 0.0100 Inexact Rounded +dqqua432 quantize 0.00999 1e-3 -> 0.010 Inexact Rounded +dqqua433 quantize 0.00999 1e-2 -> 0.01 Inexact Rounded +dqqua434 quantize 0.00999 1e-1 -> 0.0 Inexact Rounded +dqqua435 quantize 0.00999 1e0 -> 0 Inexact Rounded +dqqua436 quantize 0.00999 1e1 -> 0E+1 Inexact Rounded + +dqqua440 quantize 0.000999 1e-5 -> 0.00100 Inexact Rounded +dqqua441 quantize 0.000999 1e-4 -> 0.0010 Inexact Rounded +dqqua442 quantize 0.000999 1e-3 -> 0.001 Inexact Rounded +dqqua443 quantize 0.000999 1e-2 -> 0.00 Inexact Rounded +dqqua444 quantize 0.000999 1e-1 -> 0.0 Inexact Rounded +dqqua445 quantize 0.000999 1e0 -> 0 Inexact Rounded +dqqua446 quantize 0.000999 1e1 -> 0E+1 Inexact Rounded + +dqqua1001 quantize 0.000 0.001 -> 0.000 +dqqua1002 quantize 0.001 0.001 -> 0.001 +dqqua1003 quantize 0.0012 0.001 -> 0.001 Inexact Rounded +dqqua1004 quantize 0.0018 0.001 -> 0.002 Inexact Rounded +dqqua1005 quantize 0.501 0.001 -> 0.501 +dqqua1006 quantize 0.5012 0.001 -> 0.501 Inexact Rounded +dqqua1007 quantize 0.5018 0.001 -> 0.502 Inexact Rounded +dqqua1008 quantize 0.999 0.001 -> 0.999 + +dqqua481 quantize 12345678000 1e+3 -> 1.2345678E+10 Rounded +dqqua482 quantize 1234567800 1e+1 -> 1.23456780E+9 Rounded +dqqua483 quantize 1234567890 1e+1 -> 1.23456789E+9 Rounded +dqqua484 quantize 1234567891 1e+1 -> 1.23456789E+9 Inexact Rounded +dqqua485 quantize 12345678901 1e+2 -> 1.23456789E+10 Inexact Rounded +dqqua486 quantize 1234567896 1e+1 -> 1.23456790E+9 Inexact Rounded +-- a potential double-round +dqqua487 quantize 1234.987643 1e-4 -> 1234.9876 Inexact Rounded +dqqua488 quantize 1234.987647 1e-4 -> 1234.9876 Inexact Rounded + +dqqua491 quantize 12345678000 1e+3 -> 1.2345678E+10 Rounded +dqqua492 quantize 1234567800 1e+1 -> 1.23456780E+9 Rounded +dqqua493 quantize 1234567890 1e+1 -> 1.23456789E+9 Rounded +dqqua494 quantize 1234567891 1e+1 -> 1.23456789E+9 Inexact Rounded +dqqua495 quantize 12345678901 1e+2 -> 1.23456789E+10 Inexact Rounded +dqqua496 quantize 1234567896 1e+1 -> 1.23456790E+9 Inexact Rounded +dqqua497 quantize 1234.987643 1e-4 -> 1234.9876 Inexact Rounded +dqqua498 quantize 1234.987647 1e-4 -> 1234.9876 Inexact Rounded + +-- Zeros +dqqua500 quantize 0 1e1 -> 0E+1 +dqqua501 quantize 0 1e0 -> 0 +dqqua502 quantize 0 1e-1 -> 0.0 +dqqua503 quantize 0.0 1e-1 -> 0.0 +dqqua504 quantize 0.0 1e0 -> 0 +dqqua505 quantize 0.0 1e+1 -> 0E+1 +dqqua506 quantize 0E+1 1e-1 -> 0.0 +dqqua507 quantize 0E+1 1e0 -> 0 +dqqua508 quantize 0E+1 1e+1 -> 0E+1 +dqqua509 quantize -0 1e1 -> -0E+1 +dqqua510 quantize -0 1e0 -> -0 +dqqua511 quantize -0 1e-1 -> -0.0 +dqqua512 quantize -0.0 1e-1 -> -0.0 +dqqua513 quantize -0.0 1e0 -> -0 +dqqua514 quantize -0.0 1e+1 -> -0E+1 +dqqua515 quantize -0E+1 1e-1 -> -0.0 +dqqua516 quantize -0E+1 1e0 -> -0 +dqqua517 quantize -0E+1 1e+1 -> -0E+1 + +-- Suspicious RHS values +dqqua520 quantize 1.234 1e359 -> 0E+359 Inexact Rounded +dqqua521 quantize 123.456 1e359 -> 0E+359 Inexact Rounded +dqqua522 quantize 1.234 1e359 -> 0E+359 Inexact Rounded +dqqua523 quantize 123.456 1e359 -> 0E+359 Inexact Rounded +-- next four are "won't fit" overfl +dqqua526 quantize 1.234 1e-299 -> NaN Invalid_operation +dqqua527 quantize 123.456 1e-299 -> NaN Invalid_operation +dqqua528 quantize 1.234 1e-299 -> NaN Invalid_operation +dqqua529 quantize 123.456 1e-299 -> NaN Invalid_operation + +dqqua532 quantize 1.234E+299 1e299 -> 1E+299 Inexact Rounded +dqqua533 quantize 1.234E+298 1e299 -> 0E+299 Inexact Rounded +dqqua534 quantize 1.234 1e299 -> 0E+299 Inexact Rounded +dqqua537 quantize 0 1e-299 -> 0E-299 +-- next two are "won't fit" overflows +dqqua538 quantize 1.234 1e-299 -> NaN Invalid_operation +dqqua539 quantize 1.234 1e-300 -> NaN Invalid_operation +-- [more below] + +-- Specials +dqqua580 quantize Inf -Inf -> Infinity +dqqua581 quantize Inf 1e-299 -> NaN Invalid_operation +dqqua582 quantize Inf 1e-1 -> NaN Invalid_operation +dqqua583 quantize Inf 1e0 -> NaN Invalid_operation +dqqua584 quantize Inf 1e1 -> NaN Invalid_operation +dqqua585 quantize Inf 1e299 -> NaN Invalid_operation +dqqua586 quantize Inf Inf -> Infinity +dqqua587 quantize -1000 Inf -> NaN Invalid_operation +dqqua588 quantize -Inf Inf -> -Infinity +dqqua589 quantize -1 Inf -> NaN Invalid_operation +dqqua590 quantize 0 Inf -> NaN Invalid_operation +dqqua591 quantize 1 Inf -> NaN Invalid_operation +dqqua592 quantize 1000 Inf -> NaN Invalid_operation +dqqua593 quantize Inf Inf -> Infinity +dqqua594 quantize Inf 1e-0 -> NaN Invalid_operation +dqqua595 quantize -0 Inf -> NaN Invalid_operation + +dqqua600 quantize -Inf -Inf -> -Infinity +dqqua601 quantize -Inf 1e-299 -> NaN Invalid_operation +dqqua602 quantize -Inf 1e-1 -> NaN Invalid_operation +dqqua603 quantize -Inf 1e0 -> NaN Invalid_operation +dqqua604 quantize -Inf 1e1 -> NaN Invalid_operation +dqqua605 quantize -Inf 1e299 -> NaN Invalid_operation +dqqua606 quantize -Inf Inf -> -Infinity +dqqua607 quantize -1000 Inf -> NaN Invalid_operation +dqqua608 quantize -Inf -Inf -> -Infinity +dqqua609 quantize -1 -Inf -> NaN Invalid_operation +dqqua610 quantize 0 -Inf -> NaN Invalid_operation +dqqua611 quantize 1 -Inf -> NaN Invalid_operation +dqqua612 quantize 1000 -Inf -> NaN Invalid_operation +dqqua613 quantize Inf -Inf -> Infinity +dqqua614 quantize -Inf 1e-0 -> NaN Invalid_operation +dqqua615 quantize -0 -Inf -> NaN Invalid_operation + +dqqua621 quantize NaN -Inf -> NaN +dqqua622 quantize NaN 1e-299 -> NaN +dqqua623 quantize NaN 1e-1 -> NaN +dqqua624 quantize NaN 1e0 -> NaN +dqqua625 quantize NaN 1e1 -> NaN +dqqua626 quantize NaN 1e299 -> NaN +dqqua627 quantize NaN Inf -> NaN +dqqua628 quantize NaN NaN -> NaN +dqqua629 quantize -Inf NaN -> NaN +dqqua630 quantize -1000 NaN -> NaN +dqqua631 quantize -1 NaN -> NaN +dqqua632 quantize 0 NaN -> NaN +dqqua633 quantize 1 NaN -> NaN +dqqua634 quantize 1000 NaN -> NaN +dqqua635 quantize Inf NaN -> NaN +dqqua636 quantize NaN 1e-0 -> NaN +dqqua637 quantize -0 NaN -> NaN + +dqqua641 quantize sNaN -Inf -> NaN Invalid_operation +dqqua642 quantize sNaN 1e-299 -> NaN Invalid_operation +dqqua643 quantize sNaN 1e-1 -> NaN Invalid_operation +dqqua644 quantize sNaN 1e0 -> NaN Invalid_operation +dqqua645 quantize sNaN 1e1 -> NaN Invalid_operation +dqqua646 quantize sNaN 1e299 -> NaN Invalid_operation +dqqua647 quantize sNaN NaN -> NaN Invalid_operation +dqqua648 quantize sNaN sNaN -> NaN Invalid_operation +dqqua649 quantize NaN sNaN -> NaN Invalid_operation +dqqua650 quantize -Inf sNaN -> NaN Invalid_operation +dqqua651 quantize -1000 sNaN -> NaN Invalid_operation +dqqua652 quantize -1 sNaN -> NaN Invalid_operation +dqqua653 quantize 0 sNaN -> NaN Invalid_operation +dqqua654 quantize 1 sNaN -> NaN Invalid_operation +dqqua655 quantize 1000 sNaN -> NaN Invalid_operation +dqqua656 quantize Inf sNaN -> NaN Invalid_operation +dqqua657 quantize NaN sNaN -> NaN Invalid_operation +dqqua658 quantize sNaN 1e-0 -> NaN Invalid_operation +dqqua659 quantize -0 sNaN -> NaN Invalid_operation + +-- propagating NaNs +dqqua661 quantize NaN9 -Inf -> NaN9 +dqqua662 quantize NaN8 919 -> NaN8 +dqqua663 quantize NaN71 Inf -> NaN71 +dqqua664 quantize NaN6 NaN5 -> NaN6 +dqqua665 quantize -Inf NaN4 -> NaN4 +dqqua666 quantize -919 NaN31 -> NaN31 +dqqua667 quantize Inf NaN2 -> NaN2 + +dqqua671 quantize sNaN99 -Inf -> NaN99 Invalid_operation +dqqua672 quantize sNaN98 -11 -> NaN98 Invalid_operation +dqqua673 quantize sNaN97 NaN -> NaN97 Invalid_operation +dqqua674 quantize sNaN16 sNaN94 -> NaN16 Invalid_operation +dqqua675 quantize NaN95 sNaN93 -> NaN93 Invalid_operation +dqqua676 quantize -Inf sNaN92 -> NaN92 Invalid_operation +dqqua677 quantize 088 sNaN91 -> NaN91 Invalid_operation +dqqua678 quantize Inf sNaN90 -> NaN90 Invalid_operation +dqqua679 quantize NaN sNaN88 -> NaN88 Invalid_operation + +dqqua681 quantize -NaN9 -Inf -> -NaN9 +dqqua682 quantize -NaN8 919 -> -NaN8 +dqqua683 quantize -NaN71 Inf -> -NaN71 +dqqua684 quantize -NaN6 -NaN5 -> -NaN6 +dqqua685 quantize -Inf -NaN4 -> -NaN4 +dqqua686 quantize -919 -NaN31 -> -NaN31 +dqqua687 quantize Inf -NaN2 -> -NaN2 + +dqqua691 quantize -sNaN99 -Inf -> -NaN99 Invalid_operation +dqqua692 quantize -sNaN98 -11 -> -NaN98 Invalid_operation +dqqua693 quantize -sNaN97 NaN -> -NaN97 Invalid_operation +dqqua694 quantize -sNaN16 sNaN94 -> -NaN16 Invalid_operation +dqqua695 quantize -NaN95 -sNaN93 -> -NaN93 Invalid_operation +dqqua696 quantize -Inf -sNaN92 -> -NaN92 Invalid_operation +dqqua697 quantize 088 -sNaN91 -> -NaN91 Invalid_operation +dqqua698 quantize Inf -sNaN90 -> -NaN90 Invalid_operation +dqqua699 quantize NaN -sNaN88 -> -NaN88 Invalid_operation + +-- subnormals and underflow +dqqua710 quantize 1.00E-6143 1e-6143 -> 1E-6143 Rounded +dqqua711 quantize 0.1E-6143 2e-6144 -> 1E-6144 Subnormal +dqqua712 quantize 0.10E-6143 3e-6144 -> 1E-6144 Subnormal Rounded +dqqua713 quantize 0.100E-6143 4e-6144 -> 1E-6144 Subnormal Rounded +dqqua714 quantize 0.01E-6143 5e-6145 -> 1E-6145 Subnormal +-- next is rounded to Emin +dqqua715 quantize 0.999E-6143 1e-6143 -> 1E-6143 Inexact Rounded +dqqua716 quantize 0.099E-6143 10e-6144 -> 1E-6144 Inexact Rounded Subnormal + +dqqua717 quantize 0.009E-6143 1e-6145 -> 1E-6145 Inexact Rounded Subnormal +dqqua718 quantize 0.001E-6143 1e-6145 -> 0E-6145 Inexact Rounded +dqqua719 quantize 0.0009E-6143 1e-6145 -> 0E-6145 Inexact Rounded +dqqua720 quantize 0.0001E-6143 1e-6145 -> 0E-6145 Inexact Rounded + +dqqua730 quantize -1.00E-6143 1e-6143 -> -1E-6143 Rounded +dqqua731 quantize -0.1E-6143 1e-6143 -> -0E-6143 Rounded Inexact +dqqua732 quantize -0.10E-6143 1e-6143 -> -0E-6143 Rounded Inexact +dqqua733 quantize -0.100E-6143 1e-6143 -> -0E-6143 Rounded Inexact +dqqua734 quantize -0.01E-6143 1e-6143 -> -0E-6143 Inexact Rounded +-- next is rounded to Emin +dqqua735 quantize -0.999E-6143 90e-6143 -> -1E-6143 Inexact Rounded +dqqua736 quantize -0.099E-6143 -1e-6143 -> -0E-6143 Inexact Rounded +dqqua737 quantize -0.009E-6143 -1e-6143 -> -0E-6143 Inexact Rounded +dqqua738 quantize -0.001E-6143 -0e-6143 -> -0E-6143 Inexact Rounded +dqqua739 quantize -0.0001E-6143 0e-6143 -> -0E-6143 Inexact Rounded + +dqqua740 quantize -1.00E-6143 1e-6144 -> -1.0E-6143 Rounded +dqqua741 quantize -0.1E-6143 1e-6144 -> -1E-6144 Subnormal +dqqua742 quantize -0.10E-6143 1e-6144 -> -1E-6144 Subnormal Rounded +dqqua743 quantize -0.100E-6143 1e-6144 -> -1E-6144 Subnormal Rounded +dqqua744 quantize -0.01E-6143 1e-6144 -> -0E-6144 Inexact Rounded +-- next is rounded to Emin +dqqua745 quantize -0.999E-6143 1e-6144 -> -1.0E-6143 Inexact Rounded +dqqua746 quantize -0.099E-6143 1e-6144 -> -1E-6144 Inexact Rounded Subnormal +dqqua747 quantize -0.009E-6143 1e-6144 -> -0E-6144 Inexact Rounded +dqqua748 quantize -0.001E-6143 1e-6144 -> -0E-6144 Inexact Rounded +dqqua749 quantize -0.0001E-6143 1e-6144 -> -0E-6144 Inexact Rounded + +dqqua750 quantize -1.00E-6143 1e-6145 -> -1.00E-6143 +dqqua751 quantize -0.1E-6143 1e-6145 -> -1.0E-6144 Subnormal +dqqua752 quantize -0.10E-6143 1e-6145 -> -1.0E-6144 Subnormal +dqqua753 quantize -0.100E-6143 1e-6145 -> -1.0E-6144 Subnormal Rounded +dqqua754 quantize -0.01E-6143 1e-6145 -> -1E-6145 Subnormal +-- next is rounded to Emin +dqqua755 quantize -0.999E-6143 1e-6145 -> -1.00E-6143 Inexact Rounded +dqqua756 quantize -0.099E-6143 1e-6145 -> -1.0E-6144 Inexact Rounded Subnormal +dqqua757 quantize -0.009E-6143 1e-6145 -> -1E-6145 Inexact Rounded Subnormal +dqqua758 quantize -0.001E-6143 1e-6145 -> -0E-6145 Inexact Rounded +dqqua759 quantize -0.0001E-6143 1e-6145 -> -0E-6145 Inexact Rounded + +dqqua760 quantize -1.00E-6143 1e-6146 -> -1.000E-6143 +dqqua761 quantize -0.1E-6143 1e-6146 -> -1.00E-6144 Subnormal +dqqua762 quantize -0.10E-6143 1e-6146 -> -1.00E-6144 Subnormal +dqqua763 quantize -0.100E-6143 1e-6146 -> -1.00E-6144 Subnormal +dqqua764 quantize -0.01E-6143 1e-6146 -> -1.0E-6145 Subnormal +dqqua765 quantize -0.999E-6143 1e-6146 -> -9.99E-6144 Subnormal +dqqua766 quantize -0.099E-6143 1e-6146 -> -9.9E-6145 Subnormal +dqqua767 quantize -0.009E-6143 1e-6146 -> -9E-6146 Subnormal +dqqua768 quantize -0.001E-6143 1e-6146 -> -1E-6146 Subnormal +dqqua769 quantize -0.0001E-6143 1e-6146 -> -0E-6146 Inexact Rounded + +-- More from Fung Lee +dqqua1021 quantize 8.666666666666000E+6144 1.000000000000000E+6144 -> 8.666666666666000000000000000000000E+6144 Clamped +dqqua1022 quantize -8.666666666666000E+6144 1.000000000000000E+6144 -> -8.666666666666000000000000000000000E+6144 Clamped +dqqua1027 quantize 8.666666666666000E+323 1E+31 -> NaN Invalid_operation +dqqua1030 quantize 8.66666666E+3 1E+3 -> 9E+3 Inexact Rounded + +-- Int and uInt32 edge values for testing conversions +dqqua1040 quantize -2147483646 0 -> -2147483646 +dqqua1041 quantize -2147483647 0 -> -2147483647 +dqqua1042 quantize -2147483648 0 -> -2147483648 +dqqua1043 quantize -2147483649 0 -> -2147483649 +dqqua1044 quantize 2147483646 0 -> 2147483646 +dqqua1045 quantize 2147483647 0 -> 2147483647 +dqqua1046 quantize 2147483648 0 -> 2147483648 +dqqua1047 quantize 2147483649 0 -> 2147483649 +dqqua1048 quantize 4294967294 0 -> 4294967294 +dqqua1049 quantize 4294967295 0 -> 4294967295 +dqqua1050 quantize 4294967296 0 -> 4294967296 +dqqua1051 quantize 4294967297 0 -> 4294967297 + +-- Rounding swathe +rounding: half_even +dqqua1100 quantize 1.2300 1.00 -> 1.23 Rounded +dqqua1101 quantize 1.2301 1.00 -> 1.23 Inexact Rounded +dqqua1102 quantize 1.2310 1.00 -> 1.23 Inexact Rounded +dqqua1103 quantize 1.2350 1.00 -> 1.24 Inexact Rounded +dqqua1104 quantize 1.2351 1.00 -> 1.24 Inexact Rounded +dqqua1105 quantize 1.2450 1.00 -> 1.24 Inexact Rounded +dqqua1106 quantize 1.2451 1.00 -> 1.25 Inexact Rounded +dqqua1107 quantize 1.2360 1.00 -> 1.24 Inexact Rounded +dqqua1108 quantize 1.2370 1.00 -> 1.24 Inexact Rounded +dqqua1109 quantize 1.2399 1.00 -> 1.24 Inexact Rounded + +rounding: half_up +dqqua1200 quantize 1.2300 1.00 -> 1.23 Rounded +dqqua1201 quantize 1.2301 1.00 -> 1.23 Inexact Rounded +dqqua1202 quantize 1.2310 1.00 -> 1.23 Inexact Rounded +dqqua1203 quantize 1.2350 1.00 -> 1.24 Inexact Rounded +dqqua1204 quantize 1.2351 1.00 -> 1.24 Inexact Rounded +dqqua1205 quantize 1.2450 1.00 -> 1.25 Inexact Rounded +dqqua1206 quantize 1.2451 1.00 -> 1.25 Inexact Rounded +dqqua1207 quantize 1.2360 1.00 -> 1.24 Inexact Rounded +dqqua1208 quantize 1.2370 1.00 -> 1.24 Inexact Rounded +dqqua1209 quantize 1.2399 1.00 -> 1.24 Inexact Rounded + +rounding: half_down +dqqua1300 quantize 1.2300 1.00 -> 1.23 Rounded +dqqua1301 quantize 1.2301 1.00 -> 1.23 Inexact Rounded +dqqua1302 quantize 1.2310 1.00 -> 1.23 Inexact Rounded +dqqua1303 quantize 1.2350 1.00 -> 1.23 Inexact Rounded +dqqua1304 quantize 1.2351 1.00 -> 1.24 Inexact Rounded +dqqua1305 quantize 1.2450 1.00 -> 1.24 Inexact Rounded +dqqua1306 quantize 1.2451 1.00 -> 1.25 Inexact Rounded +dqqua1307 quantize 1.2360 1.00 -> 1.24 Inexact Rounded +dqqua1308 quantize 1.2370 1.00 -> 1.24 Inexact Rounded +dqqua1309 quantize 1.2399 1.00 -> 1.24 Inexact Rounded + +rounding: up +dqqua1400 quantize 1.2300 1.00 -> 1.23 Rounded +dqqua1401 quantize 1.2301 1.00 -> 1.24 Inexact Rounded +dqqua1402 quantize 1.2310 1.00 -> 1.24 Inexact Rounded +dqqua1403 quantize 1.2350 1.00 -> 1.24 Inexact Rounded +dqqua1404 quantize 1.2351 1.00 -> 1.24 Inexact Rounded +dqqua1405 quantize 1.2450 1.00 -> 1.25 Inexact Rounded +dqqua1406 quantize 1.2451 1.00 -> 1.25 Inexact Rounded +dqqua1407 quantize 1.2360 1.00 -> 1.24 Inexact Rounded +dqqua1408 quantize 1.2370 1.00 -> 1.24 Inexact Rounded +dqqua1409 quantize 1.2399 1.00 -> 1.24 Inexact Rounded +dqqua1411 quantize -1.2399 1.00 -> -1.24 Inexact Rounded + +rounding: down +dqqua1500 quantize 1.2300 1.00 -> 1.23 Rounded +dqqua1501 quantize 1.2301 1.00 -> 1.23 Inexact Rounded +dqqua1502 quantize 1.2310 1.00 -> 1.23 Inexact Rounded +dqqua1503 quantize 1.2350 1.00 -> 1.23 Inexact Rounded +dqqua1504 quantize 1.2351 1.00 -> 1.23 Inexact Rounded +dqqua1505 quantize 1.2450 1.00 -> 1.24 Inexact Rounded +dqqua1506 quantize 1.2451 1.00 -> 1.24 Inexact Rounded +dqqua1507 quantize 1.2360 1.00 -> 1.23 Inexact Rounded +dqqua1508 quantize 1.2370 1.00 -> 1.23 Inexact Rounded +dqqua1509 quantize 1.2399 1.00 -> 1.23 Inexact Rounded +dqqua1511 quantize -1.2399 1.00 -> -1.23 Inexact Rounded + +rounding: ceiling +dqqua1600 quantize 1.2300 1.00 -> 1.23 Rounded +dqqua1601 quantize 1.2301 1.00 -> 1.24 Inexact Rounded +dqqua1602 quantize 1.2310 1.00 -> 1.24 Inexact Rounded +dqqua1603 quantize 1.2350 1.00 -> 1.24 Inexact Rounded +dqqua1604 quantize 1.2351 1.00 -> 1.24 Inexact Rounded +dqqua1605 quantize 1.2450 1.00 -> 1.25 Inexact Rounded +dqqua1606 quantize 1.2451 1.00 -> 1.25 Inexact Rounded +dqqua1607 quantize 1.2360 1.00 -> 1.24 Inexact Rounded +dqqua1608 quantize 1.2370 1.00 -> 1.24 Inexact Rounded +dqqua1609 quantize 1.2399 1.00 -> 1.24 Inexact Rounded +dqqua1611 quantize -1.2399 1.00 -> -1.23 Inexact Rounded + +rounding: floor +dqqua1700 quantize 1.2300 1.00 -> 1.23 Rounded +dqqua1701 quantize 1.2301 1.00 -> 1.23 Inexact Rounded +dqqua1702 quantize 1.2310 1.00 -> 1.23 Inexact Rounded +dqqua1703 quantize 1.2350 1.00 -> 1.23 Inexact Rounded +dqqua1704 quantize 1.2351 1.00 -> 1.23 Inexact Rounded +dqqua1705 quantize 1.2450 1.00 -> 1.24 Inexact Rounded +dqqua1706 quantize 1.2451 1.00 -> 1.24 Inexact Rounded +dqqua1707 quantize 1.2360 1.00 -> 1.23 Inexact Rounded +dqqua1708 quantize 1.2370 1.00 -> 1.23 Inexact Rounded +dqqua1709 quantize 1.2399 1.00 -> 1.23 Inexact Rounded +dqqua1711 quantize -1.2399 1.00 -> -1.24 Inexact Rounded + +rounding: 05up +dqqua1800 quantize 1.2000 1.00 -> 1.20 Rounded +dqqua1801 quantize 1.2001 1.00 -> 1.21 Inexact Rounded +dqqua1802 quantize 1.2010 1.00 -> 1.21 Inexact Rounded +dqqua1803 quantize 1.2050 1.00 -> 1.21 Inexact Rounded +dqqua1804 quantize 1.2051 1.00 -> 1.21 Inexact Rounded +dqqua1807 quantize 1.2060 1.00 -> 1.21 Inexact Rounded +dqqua1808 quantize 1.2070 1.00 -> 1.21 Inexact Rounded +dqqua1809 quantize 1.2099 1.00 -> 1.21 Inexact Rounded +dqqua1811 quantize -1.2099 1.00 -> -1.21 Inexact Rounded + +dqqua1900 quantize 1.2100 1.00 -> 1.21 Rounded +dqqua1901 quantize 1.2101 1.00 -> 1.21 Inexact Rounded +dqqua1902 quantize 1.2110 1.00 -> 1.21 Inexact Rounded +dqqua1903 quantize 1.2150 1.00 -> 1.21 Inexact Rounded +dqqua1904 quantize 1.2151 1.00 -> 1.21 Inexact Rounded +dqqua1907 quantize 1.2160 1.00 -> 1.21 Inexact Rounded +dqqua1908 quantize 1.2170 1.00 -> 1.21 Inexact Rounded +dqqua1909 quantize 1.2199 1.00 -> 1.21 Inexact Rounded +dqqua1911 quantize -1.2199 1.00 -> -1.21 Inexact Rounded + +dqqua2000 quantize 1.2400 1.00 -> 1.24 Rounded +dqqua2001 quantize 1.2401 1.00 -> 1.24 Inexact Rounded +dqqua2002 quantize 1.2410 1.00 -> 1.24 Inexact Rounded +dqqua2003 quantize 1.2450 1.00 -> 1.24 Inexact Rounded +dqqua2004 quantize 1.2451 1.00 -> 1.24 Inexact Rounded +dqqua2007 quantize 1.2460 1.00 -> 1.24 Inexact Rounded +dqqua2008 quantize 1.2470 1.00 -> 1.24 Inexact Rounded +dqqua2009 quantize 1.2499 1.00 -> 1.24 Inexact Rounded +dqqua2011 quantize -1.2499 1.00 -> -1.24 Inexact Rounded + +dqqua2100 quantize 1.2500 1.00 -> 1.25 Rounded +dqqua2101 quantize 1.2501 1.00 -> 1.26 Inexact Rounded +dqqua2102 quantize 1.2510 1.00 -> 1.26 Inexact Rounded +dqqua2103 quantize 1.2550 1.00 -> 1.26 Inexact Rounded +dqqua2104 quantize 1.2551 1.00 -> 1.26 Inexact Rounded +dqqua2107 quantize 1.2560 1.00 -> 1.26 Inexact Rounded +dqqua2108 quantize 1.2570 1.00 -> 1.26 Inexact Rounded +dqqua2109 quantize 1.2599 1.00 -> 1.26 Inexact Rounded +dqqua2111 quantize -1.2599 1.00 -> -1.26 Inexact Rounded + +dqqua2200 quantize 1.2600 1.00 -> 1.26 Rounded +dqqua2201 quantize 1.2601 1.00 -> 1.26 Inexact Rounded +dqqua2202 quantize 1.2610 1.00 -> 1.26 Inexact Rounded +dqqua2203 quantize 1.2650 1.00 -> 1.26 Inexact Rounded +dqqua2204 quantize 1.2651 1.00 -> 1.26 Inexact Rounded +dqqua2207 quantize 1.2660 1.00 -> 1.26 Inexact Rounded +dqqua2208 quantize 1.2670 1.00 -> 1.26 Inexact Rounded +dqqua2209 quantize 1.2699 1.00 -> 1.26 Inexact Rounded +dqqua2211 quantize -1.2699 1.00 -> -1.26 Inexact Rounded + +dqqua2300 quantize 1.2900 1.00 -> 1.29 Rounded +dqqua2301 quantize 1.2901 1.00 -> 1.29 Inexact Rounded +dqqua2302 quantize 1.2910 1.00 -> 1.29 Inexact Rounded +dqqua2303 quantize 1.2950 1.00 -> 1.29 Inexact Rounded +dqqua2304 quantize 1.2951 1.00 -> 1.29 Inexact Rounded +dqqua2307 quantize 1.2960 1.00 -> 1.29 Inexact Rounded +dqqua2308 quantize 1.2970 1.00 -> 1.29 Inexact Rounded +dqqua2309 quantize 1.2999 1.00 -> 1.29 Inexact Rounded +dqqua2311 quantize -1.2999 1.00 -> -1.29 Inexact Rounded + +-- Null tests +dqqua998 quantize 10 # -> NaN Invalid_operation +dqqua999 quantize # 1e10 -> NaN Invalid_operation Added: python/branches/release25-maint/Lib/test/decimaltestdata/dqReduce.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/dqReduce.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,183 @@ +------------------------------------------------------------------------ +-- dqReduce.decTest -- remove trailing zeros from a decQuad -- +-- Copyright (c) IBM Corporation, 2003, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ + +version: 2.57 + +extended: 1 +clamp: 1 +precision: 34 +maxExponent: 6144 +minExponent: -6143 +rounding: half_even + +dqred001 reduce '1' -> '1' +dqred002 reduce '-1' -> '-1' +dqred003 reduce '1.00' -> '1' +dqred004 reduce '-1.00' -> '-1' +dqred005 reduce '0' -> '0' +dqred006 reduce '0.00' -> '0' +dqred007 reduce '00.0' -> '0' +dqred008 reduce '00.00' -> '0' +dqred009 reduce '00' -> '0' +dqred010 reduce '0E+1' -> '0' +dqred011 reduce '0E+5' -> '0' + +dqred012 reduce '-2' -> '-2' +dqred013 reduce '2' -> '2' +dqred014 reduce '-2.00' -> '-2' +dqred015 reduce '2.00' -> '2' +dqred016 reduce '-0' -> '-0' +dqred017 reduce '-0.00' -> '-0' +dqred018 reduce '-00.0' -> '-0' +dqred019 reduce '-00.00' -> '-0' +dqred020 reduce '-00' -> '-0' +dqred021 reduce '-0E+5' -> '-0' +dqred022 reduce '-0E+1' -> '-0' + +dqred030 reduce '+0.1' -> '0.1' +dqred031 reduce '-0.1' -> '-0.1' +dqred032 reduce '+0.01' -> '0.01' +dqred033 reduce '-0.01' -> '-0.01' +dqred034 reduce '+0.001' -> '0.001' +dqred035 reduce '-0.001' -> '-0.001' +dqred036 reduce '+0.000001' -> '0.000001' +dqred037 reduce '-0.000001' -> '-0.000001' +dqred038 reduce '+0.000000000001' -> '1E-12' +dqred039 reduce '-0.000000000001' -> '-1E-12' + +dqred041 reduce 1.1 -> 1.1 +dqred042 reduce 1.10 -> 1.1 +dqred043 reduce 1.100 -> 1.1 +dqred044 reduce 1.110 -> 1.11 +dqred045 reduce -1.1 -> -1.1 +dqred046 reduce -1.10 -> -1.1 +dqred047 reduce -1.100 -> -1.1 +dqred048 reduce -1.110 -> -1.11 +dqred049 reduce 9.9 -> 9.9 +dqred050 reduce 9.90 -> 9.9 +dqred051 reduce 9.900 -> 9.9 +dqred052 reduce 9.990 -> 9.99 +dqred053 reduce -9.9 -> -9.9 +dqred054 reduce -9.90 -> -9.9 +dqred055 reduce -9.900 -> -9.9 +dqred056 reduce -9.990 -> -9.99 + +-- some trailing fractional zeros with zeros in units +dqred060 reduce 10.0 -> 1E+1 +dqred061 reduce 10.00 -> 1E+1 +dqred062 reduce 100.0 -> 1E+2 +dqred063 reduce 100.00 -> 1E+2 +dqred064 reduce 1.1000E+3 -> 1.1E+3 +dqred065 reduce 1.10000E+3 -> 1.1E+3 +dqred066 reduce -10.0 -> -1E+1 +dqred067 reduce -10.00 -> -1E+1 +dqred068 reduce -100.0 -> -1E+2 +dqred069 reduce -100.00 -> -1E+2 +dqred070 reduce -1.1000E+3 -> -1.1E+3 +dqred071 reduce -1.10000E+3 -> -1.1E+3 + +-- some insignificant trailing zeros with positive exponent +dqred080 reduce 10E+1 -> 1E+2 +dqred081 reduce 100E+1 -> 1E+3 +dqred082 reduce 1.0E+2 -> 1E+2 +dqred083 reduce 1.0E+3 -> 1E+3 +dqred084 reduce 1.1E+3 -> 1.1E+3 +dqred085 reduce 1.00E+3 -> 1E+3 +dqred086 reduce 1.10E+3 -> 1.1E+3 +dqred087 reduce -10E+1 -> -1E+2 +dqred088 reduce -100E+1 -> -1E+3 +dqred089 reduce -1.0E+2 -> -1E+2 +dqred090 reduce -1.0E+3 -> -1E+3 +dqred091 reduce -1.1E+3 -> -1.1E+3 +dqred092 reduce -1.00E+3 -> -1E+3 +dqred093 reduce -1.10E+3 -> -1.1E+3 + +-- some significant trailing zeros, were we to be trimming +dqred100 reduce 11 -> 11 +dqred101 reduce 10 -> 1E+1 +dqred102 reduce 10. -> 1E+1 +dqred103 reduce 1.1E+1 -> 11 +dqred104 reduce 1.0E+1 -> 1E+1 +dqred105 reduce 1.10E+2 -> 1.1E+2 +dqred106 reduce 1.00E+2 -> 1E+2 +dqred107 reduce 1.100E+3 -> 1.1E+3 +dqred108 reduce 1.000E+3 -> 1E+3 +dqred109 reduce 1.000000E+6 -> 1E+6 +dqred110 reduce -11 -> -11 +dqred111 reduce -10 -> -1E+1 +dqred112 reduce -10. -> -1E+1 +dqred113 reduce -1.1E+1 -> -11 +dqred114 reduce -1.0E+1 -> -1E+1 +dqred115 reduce -1.10E+2 -> -1.1E+2 +dqred116 reduce -1.00E+2 -> -1E+2 +dqred117 reduce -1.100E+3 -> -1.1E+3 +dqred118 reduce -1.000E+3 -> -1E+3 +dqred119 reduce -1.00000E+5 -> -1E+5 +dqred120 reduce -1.000000E+6 -> -1E+6 +dqred121 reduce -10.00000E+6 -> -1E+7 +dqred122 reduce -100.0000E+6 -> -1E+8 +dqred123 reduce -1000.000E+6 -> -1E+9 +dqred124 reduce -10000.00E+6 -> -1E+10 +dqred125 reduce -100000.0E+6 -> -1E+11 +dqred126 reduce -1000000.E+6 -> -1E+12 + +-- examples from decArith +dqred140 reduce '2.1' -> '2.1' +dqred141 reduce '-2.0' -> '-2' +dqred142 reduce '1.200' -> '1.2' +dqred143 reduce '-120' -> '-1.2E+2' +dqred144 reduce '120.00' -> '1.2E+2' +dqred145 reduce '0.00' -> '0' + +-- Nmax, Nmin, Ntiny +-- note origami effect on some of these +dqred151 reduce 9.999999999999999999999999999999999E+6144 -> 9.999999999999999999999999999999999E+6144 +dqred152 reduce 9.999999999999999999999999000000000E+6140 -> 9.99999999999999999999999900000E+6140 +dqred153 reduce 9.999999999999999999999999999990000E+6144 -> 9.999999999999999999999999999990000E+6144 +dqred154 reduce 1E-6143 -> 1E-6143 +dqred155 reduce 1.000000000000000000000000000000000E-6143 -> 1E-6143 +dqred156 reduce 2.000E-6173 -> 2E-6173 Subnormal +dqred157 reduce 1E-6176 -> 1E-6176 Subnormal + +dqred161 reduce -1E-6176 -> -1E-6176 Subnormal +dqred162 reduce -2.000E-6173 -> -2E-6173 Subnormal +dqred163 reduce -1.000000000000000000000000000000000E-6143 -> -1E-6143 +dqred164 reduce -1E-6143 -> -1E-6143 +dqred165 reduce -9.999999999999999999999999000000000E+6140 -> -9.99999999999999999999999900000E+6140 +dqred166 reduce -9.999999999999999999999999999990000E+6144 -> -9.999999999999999999999999999990000E+6144 +dqred167 reduce -9.999999999999999999999999999999990E+6144 -> -9.999999999999999999999999999999990E+6144 +dqred168 reduce -9.999999999999999999999999999999999E+6144 -> -9.999999999999999999999999999999999E+6144 +dqred169 reduce -9.999999999999999999999999999999990E+6144 -> -9.999999999999999999999999999999990E+6144 + + +-- specials (reduce does not affect payload) +dqred820 reduce 'Inf' -> 'Infinity' +dqred821 reduce '-Inf' -> '-Infinity' +dqred822 reduce NaN -> NaN +dqred823 reduce sNaN -> NaN Invalid_operation +dqred824 reduce NaN101 -> NaN101 +dqred825 reduce sNaN010 -> NaN10 Invalid_operation +dqred827 reduce -NaN -> -NaN +dqred828 reduce -sNaN -> -NaN Invalid_operation +dqred829 reduce -NaN101 -> -NaN101 +dqred830 reduce -sNaN010 -> -NaN10 Invalid_operation + +-- Null test +dqred900 reduce # -> NaN Invalid_operation Added: python/branches/release25-maint/Lib/test/decimaltestdata/dqRemainder.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/dqRemainder.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,597 @@ +------------------------------------------------------------------------ +-- dqRemainder.decTest -- decQuad remainder -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +extended: 1 +clamp: 1 +precision: 34 +maxExponent: 6144 +minExponent: -6143 +rounding: half_even + +-- sanity checks (as base, above) +dqrem001 remainder 1 1 -> 0 +dqrem002 remainder 2 1 -> 0 +dqrem003 remainder 1 2 -> 1 +dqrem004 remainder 2 2 -> 0 +dqrem005 remainder 0 1 -> 0 +dqrem006 remainder 0 2 -> 0 +dqrem007 remainder 1 3 -> 1 +dqrem008 remainder 2 3 -> 2 +dqrem009 remainder 3 3 -> 0 + +dqrem010 remainder 2.4 1 -> 0.4 +dqrem011 remainder 2.4 -1 -> 0.4 +dqrem012 remainder -2.4 1 -> -0.4 +dqrem013 remainder -2.4 -1 -> -0.4 +dqrem014 remainder 2.40 1 -> 0.40 +dqrem015 remainder 2.400 1 -> 0.400 +dqrem016 remainder 2.4 2 -> 0.4 +dqrem017 remainder 2.400 2 -> 0.400 +dqrem018 remainder 2. 2 -> 0 +dqrem019 remainder 20 20 -> 0 + +dqrem020 remainder 187 187 -> 0 +dqrem021 remainder 5 2 -> 1 +dqrem022 remainder 5 2.0 -> 1.0 +dqrem023 remainder 5 2.000 -> 1.000 +dqrem024 remainder 5 0.200 -> 0.000 +dqrem025 remainder 5 0.200 -> 0.000 + +dqrem030 remainder 1 2 -> 1 +dqrem031 remainder 1 4 -> 1 +dqrem032 remainder 1 8 -> 1 + +dqrem033 remainder 1 16 -> 1 +dqrem034 remainder 1 32 -> 1 +dqrem035 remainder 1 64 -> 1 +dqrem040 remainder 1 -2 -> 1 +dqrem041 remainder 1 -4 -> 1 +dqrem042 remainder 1 -8 -> 1 +dqrem043 remainder 1 -16 -> 1 +dqrem044 remainder 1 -32 -> 1 +dqrem045 remainder 1 -64 -> 1 +dqrem050 remainder -1 2 -> -1 +dqrem051 remainder -1 4 -> -1 +dqrem052 remainder -1 8 -> -1 +dqrem053 remainder -1 16 -> -1 +dqrem054 remainder -1 32 -> -1 +dqrem055 remainder -1 64 -> -1 +dqrem060 remainder -1 -2 -> -1 +dqrem061 remainder -1 -4 -> -1 +dqrem062 remainder -1 -8 -> -1 +dqrem063 remainder -1 -16 -> -1 +dqrem064 remainder -1 -32 -> -1 +dqrem065 remainder -1 -64 -> -1 + +dqrem066 remainder 999999999 1 -> 0 +dqrem067 remainder 999999999.4 1 -> 0.4 +dqrem068 remainder 999999999.5 1 -> 0.5 +dqrem069 remainder 999999999.9 1 -> 0.9 +dqrem070 remainder 999999999.999 1 -> 0.999 +dqrem071 remainder 999999.999999 1 -> 0.999999 +dqrem072 remainder 9 1 -> 0 + +dqrem080 remainder 0. 1 -> 0 +dqrem081 remainder .0 1 -> 0.0 +dqrem082 remainder 0.00 1 -> 0.00 +dqrem083 remainder 0.00E+9 1 -> 0 +dqrem084 remainder 0.00E+3 1 -> 0 +dqrem085 remainder 0.00E+2 1 -> 0 +dqrem086 remainder 0.00E+1 1 -> 0.0 +dqrem087 remainder 0.00E+0 1 -> 0.00 +dqrem088 remainder 0.00E-0 1 -> 0.00 +dqrem089 remainder 0.00E-1 1 -> 0.000 +dqrem090 remainder 0.00E-2 1 -> 0.0000 +dqrem091 remainder 0.00E-3 1 -> 0.00000 +dqrem092 remainder 0.00E-4 1 -> 0.000000 +dqrem093 remainder 0.00E-5 1 -> 0E-7 +dqrem094 remainder 0.00E-6 1 -> 0E-8 +dqrem095 remainder 0.0000E-50 1 -> 0E-54 + +-- Various flavours of remainder by 0 +dqrem101 remainder 0 0 -> NaN Division_undefined +dqrem102 remainder 0 -0 -> NaN Division_undefined +dqrem103 remainder -0 0 -> NaN Division_undefined +dqrem104 remainder -0 -0 -> NaN Division_undefined +dqrem105 remainder 0.0E5 0 -> NaN Division_undefined +dqrem106 remainder 0.000 0 -> NaN Division_undefined +-- [Some think this next group should be Division_by_zero exception, but +-- IEEE 854 is explicit that it is Invalid operation .. for +-- remainder-near, anyway] +dqrem107 remainder 0.0001 0 -> NaN Invalid_operation +dqrem108 remainder 0.01 0 -> NaN Invalid_operation +dqrem109 remainder 0.1 0 -> NaN Invalid_operation +dqrem110 remainder 1 0 -> NaN Invalid_operation +dqrem111 remainder 1 0.0 -> NaN Invalid_operation +dqrem112 remainder 10 0.0 -> NaN Invalid_operation +dqrem113 remainder 1E+100 0.0 -> NaN Invalid_operation +dqrem114 remainder 1E+380 0 -> NaN Invalid_operation +dqrem115 remainder 0.0001 -0 -> NaN Invalid_operation +dqrem116 remainder 0.01 -0 -> NaN Invalid_operation +dqrem119 remainder 0.1 -0 -> NaN Invalid_operation +dqrem120 remainder 1 -0 -> NaN Invalid_operation +dqrem121 remainder 1 -0.0 -> NaN Invalid_operation +dqrem122 remainder 10 -0.0 -> NaN Invalid_operation +dqrem123 remainder 1E+100 -0.0 -> NaN Invalid_operation +dqrem124 remainder 1E+384 -0 -> NaN Invalid_operation +-- and zeros on left +dqrem130 remainder 0 1 -> 0 +dqrem131 remainder 0 -1 -> 0 +dqrem132 remainder 0.0 1 -> 0.0 +dqrem133 remainder 0.0 -1 -> 0.0 +dqrem134 remainder -0 1 -> -0 +dqrem135 remainder -0 -1 -> -0 +dqrem136 remainder -0.0 1 -> -0.0 +dqrem137 remainder -0.0 -1 -> -0.0 + +-- 0.5ers +dqrem143 remainder 0.5 2 -> 0.5 +dqrem144 remainder 0.5 2.1 -> 0.5 +dqrem145 remainder 0.5 2.01 -> 0.50 +dqrem146 remainder 0.5 2.001 -> 0.500 +dqrem147 remainder 0.50 2 -> 0.50 +dqrem148 remainder 0.50 2.01 -> 0.50 +dqrem149 remainder 0.50 2.001 -> 0.500 + +-- steadies +dqrem150 remainder 1 1 -> 0 +dqrem151 remainder 1 2 -> 1 +dqrem152 remainder 1 3 -> 1 +dqrem153 remainder 1 4 -> 1 +dqrem154 remainder 1 5 -> 1 +dqrem155 remainder 1 6 -> 1 +dqrem156 remainder 1 7 -> 1 +dqrem157 remainder 1 8 -> 1 +dqrem158 remainder 1 9 -> 1 +dqrem159 remainder 1 10 -> 1 +dqrem160 remainder 1 1 -> 0 +dqrem161 remainder 2 1 -> 0 +dqrem162 remainder 3 1 -> 0 +dqrem163 remainder 4 1 -> 0 +dqrem164 remainder 5 1 -> 0 +dqrem165 remainder 6 1 -> 0 +dqrem166 remainder 7 1 -> 0 +dqrem167 remainder 8 1 -> 0 +dqrem168 remainder 9 1 -> 0 +dqrem169 remainder 10 1 -> 0 + +-- some differences from remainderNear +dqrem171 remainder 0.4 1.020 -> 0.400 +dqrem172 remainder 0.50 1.020 -> 0.500 +dqrem173 remainder 0.51 1.020 -> 0.510 +dqrem174 remainder 0.52 1.020 -> 0.520 +dqrem175 remainder 0.6 1.020 -> 0.600 + +-- More flavours of remainder by 0 +dqrem201 remainder 0 0 -> NaN Division_undefined +dqrem202 remainder 0.0E5 0 -> NaN Division_undefined +dqrem203 remainder 0.000 0 -> NaN Division_undefined +dqrem204 remainder 0.0001 0 -> NaN Invalid_operation +dqrem205 remainder 0.01 0 -> NaN Invalid_operation +dqrem206 remainder 0.1 0 -> NaN Invalid_operation +dqrem207 remainder 1 0 -> NaN Invalid_operation +dqrem208 remainder 1 0.0 -> NaN Invalid_operation +dqrem209 remainder 10 0.0 -> NaN Invalid_operation +dqrem210 remainder 1E+100 0.0 -> NaN Invalid_operation +dqrem211 remainder 1E+380 0 -> NaN Invalid_operation + +-- some differences from remainderNear +dqrem231 remainder -0.4 1.020 -> -0.400 +dqrem232 remainder -0.50 1.020 -> -0.500 +dqrem233 remainder -0.51 1.020 -> -0.510 +dqrem234 remainder -0.52 1.020 -> -0.520 +dqrem235 remainder -0.6 1.020 -> -0.600 + +-- high Xs +dqrem240 remainder 1E+2 1.00 -> 0.00 + +-- dqrem3xx are from DiagBigDecimal +dqrem301 remainder 1 3 -> 1 +dqrem302 remainder 5 5 -> 0 +dqrem303 remainder 13 10 -> 3 +dqrem304 remainder 13 50 -> 13 +dqrem305 remainder 13 100 -> 13 +dqrem306 remainder 13 1000 -> 13 +dqrem307 remainder .13 1 -> 0.13 +dqrem308 remainder 0.133 1 -> 0.133 +dqrem309 remainder 0.1033 1 -> 0.1033 +dqrem310 remainder 1.033 1 -> 0.033 +dqrem311 remainder 10.33 1 -> 0.33 +dqrem312 remainder 10.33 10 -> 0.33 +dqrem313 remainder 103.3 1 -> 0.3 +dqrem314 remainder 133 10 -> 3 +dqrem315 remainder 1033 10 -> 3 +dqrem316 remainder 1033 50 -> 33 +dqrem317 remainder 101.0 3 -> 2.0 +dqrem318 remainder 102.0 3 -> 0.0 +dqrem319 remainder 103.0 3 -> 1.0 +dqrem320 remainder 2.40 1 -> 0.40 +dqrem321 remainder 2.400 1 -> 0.400 +dqrem322 remainder 2.4 1 -> 0.4 +dqrem323 remainder 2.4 2 -> 0.4 +dqrem324 remainder 2.400 2 -> 0.400 +dqrem325 remainder 1 0.3 -> 0.1 +dqrem326 remainder 1 0.30 -> 0.10 +dqrem327 remainder 1 0.300 -> 0.100 +dqrem328 remainder 1 0.3000 -> 0.1000 +dqrem329 remainder 1.0 0.3 -> 0.1 +dqrem330 remainder 1.00 0.3 -> 0.10 +dqrem331 remainder 1.000 0.3 -> 0.100 +dqrem332 remainder 1.0000 0.3 -> 0.1000 +dqrem333 remainder 0.5 2 -> 0.5 +dqrem334 remainder 0.5 2.1 -> 0.5 +dqrem335 remainder 0.5 2.01 -> 0.50 +dqrem336 remainder 0.5 2.001 -> 0.500 +dqrem337 remainder 0.50 2 -> 0.50 +dqrem338 remainder 0.50 2.01 -> 0.50 +dqrem339 remainder 0.50 2.001 -> 0.500 + +dqrem340 remainder 0.5 0.5000001 -> 0.5000000 +dqrem341 remainder 0.5 0.50000001 -> 0.50000000 +dqrem342 remainder 0.5 0.500000001 -> 0.500000000 +dqrem343 remainder 0.5 0.5000000001 -> 0.5000000000 +dqrem344 remainder 0.5 0.50000000001 -> 0.50000000000 +dqrem345 remainder 0.5 0.4999999 -> 1E-7 +dqrem346 remainder 0.5 0.49999999 -> 1E-8 +dqrem347 remainder 0.5 0.499999999 -> 1E-9 +dqrem348 remainder 0.5 0.4999999999 -> 1E-10 +dqrem349 remainder 0.5 0.49999999999 -> 1E-11 +dqrem350 remainder 0.5 0.499999999999 -> 1E-12 + +dqrem351 remainder 0.03 7 -> 0.03 +dqrem352 remainder 5 2 -> 1 +dqrem353 remainder 4.1 2 -> 0.1 +dqrem354 remainder 4.01 2 -> 0.01 +dqrem355 remainder 4.001 2 -> 0.001 +dqrem356 remainder 4.0001 2 -> 0.0001 +dqrem357 remainder 4.00001 2 -> 0.00001 +dqrem358 remainder 4.000001 2 -> 0.000001 +dqrem359 remainder 4.0000001 2 -> 1E-7 + +dqrem360 remainder 1.2 0.7345 -> 0.4655 +dqrem361 remainder 0.8 12 -> 0.8 +dqrem362 remainder 0.8 0.2 -> 0.0 +dqrem363 remainder 0.8 0.3 -> 0.2 +dqrem364 remainder 0.800 12 -> 0.800 +dqrem365 remainder 0.800 1.7 -> 0.800 +dqrem366 remainder 2.400 2 -> 0.400 + +dqrem371 remainder 2.400 2 -> 0.400 + +dqrem381 remainder 12345 1 -> 0 +dqrem382 remainder 12345 1.0001 -> 0.7657 +dqrem383 remainder 12345 1.001 -> 0.668 +dqrem384 remainder 12345 1.01 -> 0.78 +dqrem385 remainder 12345 1.1 -> 0.8 +dqrem386 remainder 12355 4 -> 3 +dqrem387 remainder 12345 4 -> 1 +dqrem388 remainder 12355 4.0001 -> 2.6912 +dqrem389 remainder 12345 4.0001 -> 0.6914 +dqrem390 remainder 12345 4.9 -> 1.9 +dqrem391 remainder 12345 4.99 -> 4.73 +dqrem392 remainder 12345 4.999 -> 2.469 +dqrem393 remainder 12345 4.9999 -> 0.2469 +dqrem394 remainder 12345 5 -> 0 +dqrem395 remainder 12345 5.0001 -> 4.7532 +dqrem396 remainder 12345 5.001 -> 2.532 +dqrem397 remainder 12345 5.01 -> 0.36 +dqrem398 remainder 12345 5.1 -> 3.0 + +-- the nasty division-by-1 cases +dqrem401 remainder 0.5 1 -> 0.5 +dqrem402 remainder 0.55 1 -> 0.55 +dqrem403 remainder 0.555 1 -> 0.555 +dqrem404 remainder 0.5555 1 -> 0.5555 +dqrem405 remainder 0.55555 1 -> 0.55555 +dqrem406 remainder 0.555555 1 -> 0.555555 +dqrem407 remainder 0.5555555 1 -> 0.5555555 +dqrem408 remainder 0.55555555 1 -> 0.55555555 +dqrem409 remainder 0.555555555 1 -> 0.555555555 + +-- folddowns +dqrem421 remainder 1E+6144 1 -> NaN Division_impossible +dqrem422 remainder 1E+6144 1E+6143 -> 0E+6111 Clamped +dqrem423 remainder 1E+6144 2E+6143 -> 0E+6111 Clamped +dqrem424 remainder 1E+6144 3E+6143 -> 1.00000000000000000000000000000000E+6143 Clamped +dqrem425 remainder 1E+6144 4E+6143 -> 2.00000000000000000000000000000000E+6143 Clamped +dqrem426 remainder 1E+6144 5E+6143 -> 0E+6111 Clamped +dqrem427 remainder 1E+6144 6E+6143 -> 4.00000000000000000000000000000000E+6143 Clamped +dqrem428 remainder 1E+6144 7E+6143 -> 3.00000000000000000000000000000000E+6143 Clamped +dqrem429 remainder 1E+6144 8E+6143 -> 2.00000000000000000000000000000000E+6143 Clamped +dqrem430 remainder 1E+6144 9E+6143 -> 1.00000000000000000000000000000000E+6143 Clamped +-- tinies +dqrem431 remainder 1E-6175 1E-6176 -> 0E-6176 +dqrem432 remainder 1E-6175 2E-6176 -> 0E-6176 +dqrem433 remainder 1E-6175 3E-6176 -> 1E-6176 Subnormal +dqrem434 remainder 1E-6175 4E-6176 -> 2E-6176 Subnormal +dqrem435 remainder 1E-6175 5E-6176 -> 0E-6176 +dqrem436 remainder 1E-6175 6E-6176 -> 4E-6176 Subnormal +dqrem437 remainder 1E-6175 7E-6176 -> 3E-6176 Subnormal +dqrem438 remainder 1E-6175 8E-6176 -> 2E-6176 Subnormal +dqrem439 remainder 1E-6175 9E-6176 -> 1E-6176 Subnormal +dqrem440 remainder 1E-6175 10E-6176 -> 0E-6176 +dqrem441 remainder 1E-6175 11E-6176 -> 1.0E-6175 Subnormal +dqrem442 remainder 100E-6175 11E-6176 -> 1.0E-6175 Subnormal +dqrem443 remainder 100E-6175 20E-6176 -> 0E-6176 +dqrem444 remainder 100E-6175 21E-6176 -> 1.3E-6175 Subnormal +dqrem445 remainder 100E-6175 30E-6176 -> 1.0E-6175 Subnormal + +-- zero signs +dqrem650 remainder 1 1 -> 0 +dqrem651 remainder -1 1 -> -0 +dqrem652 remainder 1 -1 -> 0 +dqrem653 remainder -1 -1 -> -0 +dqrem654 remainder 0 1 -> 0 +dqrem655 remainder -0 1 -> -0 +dqrem656 remainder 0 -1 -> 0 +dqrem657 remainder -0 -1 -> -0 +dqrem658 remainder 0.00 1 -> 0.00 +dqrem659 remainder -0.00 1 -> -0.00 + +-- Specials +dqrem680 remainder Inf -Inf -> NaN Invalid_operation +dqrem681 remainder Inf -1000 -> NaN Invalid_operation +dqrem682 remainder Inf -1 -> NaN Invalid_operation +dqrem683 remainder Inf 0 -> NaN Invalid_operation +dqrem684 remainder Inf -0 -> NaN Invalid_operation +dqrem685 remainder Inf 1 -> NaN Invalid_operation +dqrem686 remainder Inf 1000 -> NaN Invalid_operation +dqrem687 remainder Inf Inf -> NaN Invalid_operation +dqrem688 remainder -1000 Inf -> -1000 +dqrem689 remainder -Inf Inf -> NaN Invalid_operation +dqrem691 remainder -1 Inf -> -1 +dqrem692 remainder 0 Inf -> 0 +dqrem693 remainder -0 Inf -> -0 +dqrem694 remainder 1 Inf -> 1 +dqrem695 remainder 1000 Inf -> 1000 +dqrem696 remainder Inf Inf -> NaN Invalid_operation + +dqrem700 remainder -Inf -Inf -> NaN Invalid_operation +dqrem701 remainder -Inf -1000 -> NaN Invalid_operation +dqrem702 remainder -Inf -1 -> NaN Invalid_operation +dqrem703 remainder -Inf -0 -> NaN Invalid_operation +dqrem704 remainder -Inf 0 -> NaN Invalid_operation +dqrem705 remainder -Inf 1 -> NaN Invalid_operation +dqrem706 remainder -Inf 1000 -> NaN Invalid_operation +dqrem707 remainder -Inf Inf -> NaN Invalid_operation +dqrem708 remainder -Inf -Inf -> NaN Invalid_operation +dqrem709 remainder -1000 Inf -> -1000 +dqrem710 remainder -1 -Inf -> -1 +dqrem711 remainder -0 -Inf -> -0 +dqrem712 remainder 0 -Inf -> 0 +dqrem713 remainder 1 -Inf -> 1 +dqrem714 remainder 1000 -Inf -> 1000 +dqrem715 remainder Inf -Inf -> NaN Invalid_operation + +dqrem721 remainder NaN -Inf -> NaN +dqrem722 remainder NaN -1000 -> NaN +dqrem723 remainder NaN -1 -> NaN +dqrem724 remainder NaN -0 -> NaN +dqrem725 remainder -NaN 0 -> -NaN +dqrem726 remainder NaN 1 -> NaN +dqrem727 remainder NaN 1000 -> NaN +dqrem728 remainder NaN Inf -> NaN +dqrem729 remainder NaN -NaN -> NaN +dqrem730 remainder -Inf NaN -> NaN +dqrem731 remainder -1000 NaN -> NaN +dqrem732 remainder -1 NaN -> NaN +dqrem733 remainder -0 -NaN -> -NaN +dqrem734 remainder 0 NaN -> NaN +dqrem735 remainder 1 -NaN -> -NaN +dqrem736 remainder 1000 NaN -> NaN +dqrem737 remainder Inf NaN -> NaN + +dqrem741 remainder sNaN -Inf -> NaN Invalid_operation +dqrem742 remainder sNaN -1000 -> NaN Invalid_operation +dqrem743 remainder -sNaN -1 -> -NaN Invalid_operation +dqrem744 remainder sNaN -0 -> NaN Invalid_operation +dqrem745 remainder sNaN 0 -> NaN Invalid_operation +dqrem746 remainder sNaN 1 -> NaN Invalid_operation +dqrem747 remainder sNaN 1000 -> NaN Invalid_operation +dqrem749 remainder sNaN NaN -> NaN Invalid_operation +dqrem750 remainder sNaN sNaN -> NaN Invalid_operation +dqrem751 remainder NaN sNaN -> NaN Invalid_operation +dqrem752 remainder -Inf sNaN -> NaN Invalid_operation +dqrem753 remainder -1000 sNaN -> NaN Invalid_operation +dqrem754 remainder -1 sNaN -> NaN Invalid_operation +dqrem755 remainder -0 sNaN -> NaN Invalid_operation +dqrem756 remainder 0 sNaN -> NaN Invalid_operation +dqrem757 remainder 1 sNaN -> NaN Invalid_operation +dqrem758 remainder 1000 sNaN -> NaN Invalid_operation +dqrem759 remainder Inf -sNaN -> -NaN Invalid_operation + +-- propaging NaNs +dqrem760 remainder NaN1 NaN7 -> NaN1 +dqrem761 remainder sNaN2 NaN8 -> NaN2 Invalid_operation +dqrem762 remainder NaN3 sNaN9 -> NaN9 Invalid_operation +dqrem763 remainder sNaN4 sNaN10 -> NaN4 Invalid_operation +dqrem764 remainder 15 NaN11 -> NaN11 +dqrem765 remainder NaN6 NaN12 -> NaN6 +dqrem766 remainder Inf NaN13 -> NaN13 +dqrem767 remainder NaN14 -Inf -> NaN14 +dqrem768 remainder 0 NaN15 -> NaN15 +dqrem769 remainder NaN16 -0 -> NaN16 + +-- edge cases of impossible +dqrem770 remainder 1234568888888887777777777890123456 10 -> 6 +dqrem771 remainder 1234568888888887777777777890123456 1 -> 0 +dqrem772 remainder 1234568888888887777777777890123456 0.1 -> NaN Division_impossible +dqrem773 remainder 1234568888888887777777777890123456 0.01 -> NaN Division_impossible + +-- long operand checks +dqrem801 remainder 12345678000 100 -> 0 +dqrem802 remainder 1 12345678000 -> 1 +dqrem803 remainder 1234567800 10 -> 0 +dqrem804 remainder 1 1234567800 -> 1 +dqrem805 remainder 1234567890 10 -> 0 +dqrem806 remainder 1 1234567890 -> 1 +dqrem807 remainder 1234567891 10 -> 1 +dqrem808 remainder 1 1234567891 -> 1 +dqrem809 remainder 12345678901 100 -> 1 +dqrem810 remainder 1 12345678901 -> 1 +dqrem811 remainder 1234567896 10 -> 6 +dqrem812 remainder 1 1234567896 -> 1 + +dqrem821 remainder 12345678000 100 -> 0 +dqrem822 remainder 1 12345678000 -> 1 +dqrem823 remainder 1234567800 10 -> 0 +dqrem824 remainder 1 1234567800 -> 1 +dqrem825 remainder 1234567890 10 -> 0 +dqrem826 remainder 1 1234567890 -> 1 +dqrem827 remainder 1234567891 10 -> 1 +dqrem828 remainder 1 1234567891 -> 1 +dqrem829 remainder 12345678901 100 -> 1 +dqrem830 remainder 1 12345678901 -> 1 +dqrem831 remainder 1234567896 10 -> 6 +dqrem832 remainder 1 1234567896 -> 1 + +-- from divideint +dqrem840 remainder 100000000.0 1 -> 0.0 +dqrem841 remainder 100000000.4 1 -> 0.4 +dqrem842 remainder 100000000.5 1 -> 0.5 +dqrem843 remainder 100000000.9 1 -> 0.9 +dqrem844 remainder 100000000.999 1 -> 0.999 +dqrem850 remainder 100000003 5 -> 3 +dqrem851 remainder 10000003 5 -> 3 +dqrem852 remainder 1000003 5 -> 3 +dqrem853 remainder 100003 5 -> 3 +dqrem854 remainder 10003 5 -> 3 +dqrem855 remainder 1003 5 -> 3 +dqrem856 remainder 103 5 -> 3 +dqrem857 remainder 13 5 -> 3 +dqrem858 remainder 1 5 -> 1 + +-- Vladimir's cases 1234567890123456 +dqrem860 remainder 123.0e1 1000000000000000 -> 1230 +dqrem861 remainder 1230 1000000000000000 -> 1230 +dqrem862 remainder 12.3e2 1000000000000000 -> 1230 +dqrem863 remainder 1.23e3 1000000000000000 -> 1230 +dqrem864 remainder 123e1 1000000000000000 -> 1230 +dqrem870 remainder 123e1 1000000000000000 -> 1230 +dqrem871 remainder 123e1 100000000000000 -> 1230 +dqrem872 remainder 123e1 10000000000000 -> 1230 +dqrem873 remainder 123e1 1000000000000 -> 1230 +dqrem874 remainder 123e1 100000000000 -> 1230 +dqrem875 remainder 123e1 10000000000 -> 1230 +dqrem876 remainder 123e1 1000000000 -> 1230 +dqrem877 remainder 123e1 100000000 -> 1230 +dqrem878 remainder 1230 100000000 -> 1230 +dqrem879 remainder 123e1 10000000 -> 1230 +dqrem880 remainder 123e1 1000000 -> 1230 +dqrem881 remainder 123e1 100000 -> 1230 +dqrem882 remainder 123e1 10000 -> 1230 +dqrem883 remainder 123e1 1000 -> 230 +dqrem884 remainder 123e1 100 -> 30 +dqrem885 remainder 123e1 10 -> 0 +dqrem886 remainder 123e1 1 -> 0 + +dqrem890 remainder 123e1 2000000000000000 -> 1230 +dqrem891 remainder 123e1 200000000000000 -> 1230 +dqrem892 remainder 123e1 20000000000000 -> 1230 +dqrem893 remainder 123e1 2000000000000 -> 1230 +dqrem894 remainder 123e1 200000000000 -> 1230 +dqrem895 remainder 123e1 20000000000 -> 1230 +dqrem896 remainder 123e1 2000000000 -> 1230 +dqrem897 remainder 123e1 200000000 -> 1230 +dqrem899 remainder 123e1 20000000 -> 1230 +dqrem900 remainder 123e1 2000000 -> 1230 +dqrem901 remainder 123e1 200000 -> 1230 +dqrem902 remainder 123e1 20000 -> 1230 +dqrem903 remainder 123e1 2000 -> 1230 +dqrem904 remainder 123e1 200 -> 30 +dqrem905 remainder 123e1 20 -> 10 +dqrem906 remainder 123e1 2 -> 0 + +dqrem910 remainder 123e1 5000000000000000 -> 1230 +dqrem911 remainder 123e1 500000000000000 -> 1230 +dqrem912 remainder 123e1 50000000000000 -> 1230 +dqrem913 remainder 123e1 5000000000000 -> 1230 +dqrem914 remainder 123e1 500000000000 -> 1230 +dqrem915 remainder 123e1 50000000000 -> 1230 +dqrem916 remainder 123e1 5000000000 -> 1230 +dqrem917 remainder 123e1 500000000 -> 1230 +dqrem919 remainder 123e1 50000000 -> 1230 +dqrem920 remainder 123e1 5000000 -> 1230 +dqrem921 remainder 123e1 500000 -> 1230 +dqrem922 remainder 123e1 50000 -> 1230 +dqrem923 remainder 123e1 5000 -> 1230 +dqrem924 remainder 123e1 500 -> 230 +dqrem925 remainder 123e1 50 -> 30 +dqrem926 remainder 123e1 5 -> 0 + +dqrem930 remainder 123e1 9000000000000000 -> 1230 +dqrem931 remainder 123e1 900000000000000 -> 1230 +dqrem932 remainder 123e1 90000000000000 -> 1230 +dqrem933 remainder 123e1 9000000000000 -> 1230 +dqrem934 remainder 123e1 900000000000 -> 1230 +dqrem935 remainder 123e1 90000000000 -> 1230 +dqrem936 remainder 123e1 9000000000 -> 1230 +dqrem937 remainder 123e1 900000000 -> 1230 +dqrem939 remainder 123e1 90000000 -> 1230 +dqrem940 remainder 123e1 9000000 -> 1230 +dqrem941 remainder 123e1 900000 -> 1230 +dqrem942 remainder 123e1 90000 -> 1230 +dqrem943 remainder 123e1 9000 -> 1230 +dqrem944 remainder 123e1 900 -> 330 +dqrem945 remainder 123e1 90 -> 60 +dqrem946 remainder 123e1 9 -> 6 + +dqrem950 remainder 123e1 1000000000000000 -> 1230 +dqrem961 remainder 123e1 2999999999999999 -> 1230 +dqrem962 remainder 123e1 3999999999999999 -> 1230 +dqrem963 remainder 123e1 4999999999999999 -> 1230 +dqrem964 remainder 123e1 5999999999999999 -> 1230 +dqrem965 remainder 123e1 6999999999999999 -> 1230 +dqrem966 remainder 123e1 7999999999999999 -> 1230 +dqrem967 remainder 123e1 8999999999999999 -> 1230 +dqrem968 remainder 123e1 9999999999999999 -> 1230 +dqrem969 remainder 123e1 9876543210987654 -> 1230 + +dqrem980 remainder 123e1 1000E299 -> 1.23E+3 -- 123E+1 internally + +-- overflow and underflow tests [from divide] +dqrem1051 remainder 1e+277 1e-311 -> NaN Division_impossible +dqrem1052 remainder 1e+277 -1e-311 -> NaN Division_impossible +dqrem1053 remainder -1e+277 1e-311 -> NaN Division_impossible +dqrem1054 remainder -1e+277 -1e-311 -> NaN Division_impossible +dqrem1055 remainder 1e-277 1e+311 -> 1E-277 +dqrem1056 remainder 1e-277 -1e+311 -> 1E-277 +dqrem1057 remainder -1e-277 1e+311 -> -1E-277 +dqrem1058 remainder -1e-277 -1e+311 -> -1E-277 + +-- Gyuris example +dqrem1070 remainder 8.336804418094040989630006819881709E-6143 8.336804418094040989630006819889000E-6143 -> 8.336804418094040989630006819881709E-6143 + +-- destructive subtract +dqrem1120 remainder 1234567890123456789012345678901234 1.000000000000000000000000000000001 -> 0.765432109876543210987654321098768 +dqrem1121 remainder 1234567890123456789012345678901234 1.00000000000000000000000000000001 -> 0.65432109876543210987654321098779 +dqrem1122 remainder 1234567890123456789012345678901234 1.0000000000000000000000000000001 -> 0.5432109876543210987654321098890 +dqrem1123 remainder 1234567890123456789012345678901255 4.000000000000000000000000000000001 -> 2.691358027469135802746913580274687 +dqrem1124 remainder 1234567890123456789012345678901234 4.000000000000000000000000000000001 -> 1.691358027469135802746913580274692 +dqrem1125 remainder 1234567890123456789012345678901234 4.9999999999999999999999999999999 -> 3.6913578024691357802469135780251 +dqrem1126 remainder 1234567890123456789012345678901234 4.99999999999999999999999999999999 -> 1.46913578024691357802469135780247 +dqrem1127 remainder 1234567890123456789012345678901234 4.999999999999999999999999999999999 -> 4.246913578024691357802469135780246 +dqrem1128 remainder 1234567890123456789012345678901234 5.0000000000000000000000000000001 -> 4.3086421975308642197530864219759 + +-- Null tests +dqrem1000 remainder 10 # -> NaN Invalid_operation +dqrem1001 remainder # 10 -> NaN Invalid_operation + Added: python/branches/release25-maint/Lib/test/decimaltestdata/dqRemainderNear.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/dqRemainderNear.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,631 @@ +------------------------------------------------------------------------ +-- dqRemainderNear.decTest -- decQuad remainder-near -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +extended: 1 +clamp: 1 +precision: 34 +maxExponent: 6144 +minExponent: -6143 +rounding: half_even + +-- sanity checks (as base, above) +dqrmn001 remaindernear 1 1 -> 0 +dqrmn002 remaindernear 2 1 -> 0 +dqrmn003 remaindernear 1 2 -> 1 +dqrmn004 remaindernear 2 2 -> 0 +dqrmn005 remaindernear 0 1 -> 0 +dqrmn006 remaindernear 0 2 -> 0 +dqrmn007 remaindernear 1 3 -> 1 +dqrmn008 remaindernear 2 3 -> -1 +dqrmn009 remaindernear 3 3 -> 0 + +dqrmn010 remaindernear 2.4 1 -> 0.4 +dqrmn011 remaindernear 2.4 -1 -> 0.4 +dqrmn012 remaindernear -2.4 1 -> -0.4 +dqrmn013 remaindernear -2.4 -1 -> -0.4 +dqrmn014 remaindernear 2.40 1 -> 0.40 +dqrmn015 remaindernear 2.400 1 -> 0.400 +dqrmn016 remaindernear 2.4 2 -> 0.4 +dqrmn017 remaindernear 2.400 2 -> 0.400 +dqrmn018 remaindernear 2. 2 -> 0 +dqrmn019 remaindernear 20 20 -> 0 + +dqrmn020 remaindernear 187 187 -> 0 +dqrmn021 remaindernear 5 2 -> 1 +dqrmn022 remaindernear 5 2.0 -> 1.0 +dqrmn023 remaindernear 5 2.000 -> 1.000 +dqrmn024 remaindernear 5 0.200 -> 0.000 +dqrmn025 remaindernear 5 0.200 -> 0.000 + +dqrmn030 remaindernear 1 2 -> 1 +dqrmn031 remaindernear 1 4 -> 1 +dqrmn032 remaindernear 1 8 -> 1 + +dqrmn033 remaindernear 1 16 -> 1 +dqrmn034 remaindernear 1 32 -> 1 +dqrmn035 remaindernear 1 64 -> 1 +dqrmn040 remaindernear 1 -2 -> 1 +dqrmn041 remaindernear 1 -4 -> 1 +dqrmn042 remaindernear 1 -8 -> 1 +dqrmn043 remaindernear 1 -16 -> 1 +dqrmn044 remaindernear 1 -32 -> 1 +dqrmn045 remaindernear 1 -64 -> 1 +dqrmn050 remaindernear -1 2 -> -1 +dqrmn051 remaindernear -1 4 -> -1 +dqrmn052 remaindernear -1 8 -> -1 +dqrmn053 remaindernear -1 16 -> -1 +dqrmn054 remaindernear -1 32 -> -1 +dqrmn055 remaindernear -1 64 -> -1 +dqrmn060 remaindernear -1 -2 -> -1 +dqrmn061 remaindernear -1 -4 -> -1 +dqrmn062 remaindernear -1 -8 -> -1 +dqrmn063 remaindernear -1 -16 -> -1 +dqrmn064 remaindernear -1 -32 -> -1 +dqrmn065 remaindernear -1 -64 -> -1 + +dqrmn066 remaindernear 9.9 1 -> -0.1 +dqrmn067 remaindernear 99.7 1 -> -0.3 +dqrmn068 remaindernear 999999999 1 -> 0 +dqrmn069 remaindernear 999999999.4 1 -> 0.4 +dqrmn070 remaindernear 999999999.5 1 -> -0.5 +dqrmn071 remaindernear 999999999.9 1 -> -0.1 +dqrmn072 remaindernear 999999999.999 1 -> -0.001 +dqrmn073 remaindernear 999999.999999 1 -> -0.000001 +dqrmn074 remaindernear 9 1 -> 0 +dqrmn075 remaindernear 9999999999999999 1 -> 0 +dqrmn076 remaindernear 9999999999999999 2 -> -1 +dqrmn077 remaindernear 9999999999999999 3 -> 0 +dqrmn078 remaindernear 9999999999999999 4 -> -1 + +dqrmn080 remaindernear 0. 1 -> 0 +dqrmn081 remaindernear .0 1 -> 0.0 +dqrmn082 remaindernear 0.00 1 -> 0.00 +dqrmn083 remaindernear 0.00E+9 1 -> 0 +dqrmn084 remaindernear 0.00E+3 1 -> 0 +dqrmn085 remaindernear 0.00E+2 1 -> 0 +dqrmn086 remaindernear 0.00E+1 1 -> 0.0 +dqrmn087 remaindernear 0.00E+0 1 -> 0.00 +dqrmn088 remaindernear 0.00E-0 1 -> 0.00 +dqrmn089 remaindernear 0.00E-1 1 -> 0.000 +dqrmn090 remaindernear 0.00E-2 1 -> 0.0000 +dqrmn091 remaindernear 0.00E-3 1 -> 0.00000 +dqrmn092 remaindernear 0.00E-4 1 -> 0.000000 +dqrmn093 remaindernear 0.00E-5 1 -> 0E-7 +dqrmn094 remaindernear 0.00E-6 1 -> 0E-8 +dqrmn095 remaindernear 0.0000E-50 1 -> 0E-54 + +-- Various flavours of remaindernear by 0 +dqrmn101 remaindernear 0 0 -> NaN Division_undefined +dqrmn102 remaindernear 0 -0 -> NaN Division_undefined +dqrmn103 remaindernear -0 0 -> NaN Division_undefined +dqrmn104 remaindernear -0 -0 -> NaN Division_undefined +dqrmn105 remaindernear 0.0E5 0 -> NaN Division_undefined +dqrmn106 remaindernear 0.000 0 -> NaN Division_undefined +-- [Some think this next group should be Division_by_zero exception, but +-- IEEE 854 is explicit that it is Invalid operation .. for +-- remainder-near, anyway] +dqrmn107 remaindernear 0.0001 0 -> NaN Invalid_operation +dqrmn108 remaindernear 0.01 0 -> NaN Invalid_operation +dqrmn109 remaindernear 0.1 0 -> NaN Invalid_operation +dqrmn110 remaindernear 1 0 -> NaN Invalid_operation +dqrmn111 remaindernear 1 0.0 -> NaN Invalid_operation +dqrmn112 remaindernear 10 0.0 -> NaN Invalid_operation +dqrmn113 remaindernear 1E+100 0.0 -> NaN Invalid_operation +dqrmn114 remaindernear 1E+380 0 -> NaN Invalid_operation +dqrmn115 remaindernear 0.0001 -0 -> NaN Invalid_operation +dqrmn116 remaindernear 0.01 -0 -> NaN Invalid_operation +dqrmn119 remaindernear 0.1 -0 -> NaN Invalid_operation +dqrmn120 remaindernear 1 -0 -> NaN Invalid_operation +dqrmn121 remaindernear 1 -0.0 -> NaN Invalid_operation +dqrmn122 remaindernear 10 -0.0 -> NaN Invalid_operation +dqrmn123 remaindernear 1E+100 -0.0 -> NaN Invalid_operation +dqrmn124 remaindernear 1E+384 -0 -> NaN Invalid_operation +-- and zeros on left +dqrmn130 remaindernear 0 1 -> 0 +dqrmn131 remaindernear 0 -1 -> 0 +dqrmn132 remaindernear 0.0 1 -> 0.0 +dqrmn133 remaindernear 0.0 -1 -> 0.0 +dqrmn134 remaindernear -0 1 -> -0 +dqrmn135 remaindernear -0 -1 -> -0 +dqrmn136 remaindernear -0.0 1 -> -0.0 +dqrmn137 remaindernear -0.0 -1 -> -0.0 + +-- 0.5ers +dqrmn143 remaindernear 0.5 2 -> 0.5 +dqrmn144 remaindernear 0.5 2.1 -> 0.5 +dqrmn145 remaindernear 0.5 2.01 -> 0.50 +dqrmn146 remaindernear 0.5 2.001 -> 0.500 +dqrmn147 remaindernear 0.50 2 -> 0.50 +dqrmn148 remaindernear 0.50 2.01 -> 0.50 +dqrmn149 remaindernear 0.50 2.001 -> 0.500 + +-- steadies +dqrmn150 remaindernear 1 1 -> 0 +dqrmn151 remaindernear 1 2 -> 1 +dqrmn152 remaindernear 1 3 -> 1 +dqrmn153 remaindernear 1 4 -> 1 +dqrmn154 remaindernear 1 5 -> 1 +dqrmn155 remaindernear 1 6 -> 1 +dqrmn156 remaindernear 1 7 -> 1 +dqrmn157 remaindernear 1 8 -> 1 +dqrmn158 remaindernear 1 9 -> 1 +dqrmn159 remaindernear 1 10 -> 1 +dqrmn160 remaindernear 1 1 -> 0 +dqrmn161 remaindernear 2 1 -> 0 +dqrmn162 remaindernear 3 1 -> 0 +dqrmn163 remaindernear 4 1 -> 0 +dqrmn164 remaindernear 5 1 -> 0 +dqrmn165 remaindernear 6 1 -> 0 +dqrmn166 remaindernear 7 1 -> 0 +dqrmn167 remaindernear 8 1 -> 0 +dqrmn168 remaindernear 9 1 -> 0 +dqrmn169 remaindernear 10 1 -> 0 + +-- some differences from remainder +dqrmn171 remaindernear 0.4 1.020 -> 0.400 +dqrmn172 remaindernear 0.50 1.020 -> 0.500 +dqrmn173 remaindernear 0.51 1.020 -> 0.510 +dqrmn174 remaindernear 0.52 1.020 -> -0.500 +dqrmn175 remaindernear 0.6 1.020 -> -0.420 + +-- More flavours of remaindernear by 0 +dqrmn201 remaindernear 0 0 -> NaN Division_undefined +dqrmn202 remaindernear 0.0E5 0 -> NaN Division_undefined +dqrmn203 remaindernear 0.000 0 -> NaN Division_undefined +dqrmn204 remaindernear 0.0001 0 -> NaN Invalid_operation +dqrmn205 remaindernear 0.01 0 -> NaN Invalid_operation +dqrmn206 remaindernear 0.1 0 -> NaN Invalid_operation +dqrmn207 remaindernear 1 0 -> NaN Invalid_operation +dqrmn208 remaindernear 1 0.0 -> NaN Invalid_operation +dqrmn209 remaindernear 10 0.0 -> NaN Invalid_operation +dqrmn210 remaindernear 1E+100 0.0 -> NaN Invalid_operation +dqrmn211 remaindernear 1E+380 0 -> NaN Invalid_operation + +-- tests from the extended specification +dqrmn221 remaindernear 2.1 3 -> -0.9 +dqrmn222 remaindernear 10 6 -> -2 +dqrmn223 remaindernear 10 3 -> 1 +dqrmn224 remaindernear -10 3 -> -1 +dqrmn225 remaindernear 10.2 1 -> 0.2 +dqrmn226 remaindernear 10 0.3 -> 0.1 +dqrmn227 remaindernear 3.6 1.3 -> -0.3 + +-- some differences from remainder +dqrmn231 remaindernear -0.4 1.020 -> -0.400 +dqrmn232 remaindernear -0.50 1.020 -> -0.500 +dqrmn233 remaindernear -0.51 1.020 -> -0.510 +dqrmn234 remaindernear -0.52 1.020 -> 0.500 +dqrmn235 remaindernear -0.6 1.020 -> 0.420 + +-- high Xs +dqrmn240 remaindernear 1E+2 1.00 -> 0.00 + +-- dqrmn3xx are from DiagBigDecimal +dqrmn301 remaindernear 1 3 -> 1 +dqrmn302 remaindernear 5 5 -> 0 +dqrmn303 remaindernear 13 10 -> 3 +dqrmn304 remaindernear 13 50 -> 13 +dqrmn305 remaindernear 13 100 -> 13 +dqrmn306 remaindernear 13 1000 -> 13 +dqrmn307 remaindernear .13 1 -> 0.13 +dqrmn308 remaindernear 0.133 1 -> 0.133 +dqrmn309 remaindernear 0.1033 1 -> 0.1033 +dqrmn310 remaindernear 1.033 1 -> 0.033 +dqrmn311 remaindernear 10.33 1 -> 0.33 +dqrmn312 remaindernear 10.33 10 -> 0.33 +dqrmn313 remaindernear 103.3 1 -> 0.3 +dqrmn314 remaindernear 133 10 -> 3 +dqrmn315 remaindernear 1033 10 -> 3 +dqrmn316 remaindernear 1033 50 -> -17 +dqrmn317 remaindernear 101.0 3 -> -1.0 +dqrmn318 remaindernear 102.0 3 -> 0.0 +dqrmn319 remaindernear 103.0 3 -> 1.0 +dqrmn320 remaindernear 2.40 1 -> 0.40 +dqrmn321 remaindernear 2.400 1 -> 0.400 +dqrmn322 remaindernear 2.4 1 -> 0.4 +dqrmn323 remaindernear 2.4 2 -> 0.4 +dqrmn324 remaindernear 2.400 2 -> 0.400 +dqrmn325 remaindernear 1 0.3 -> 0.1 +dqrmn326 remaindernear 1 0.30 -> 0.10 +dqrmn327 remaindernear 1 0.300 -> 0.100 +dqrmn328 remaindernear 1 0.3000 -> 0.1000 +dqrmn329 remaindernear 1.0 0.3 -> 0.1 +dqrmn330 remaindernear 1.00 0.3 -> 0.10 +dqrmn331 remaindernear 1.000 0.3 -> 0.100 +dqrmn332 remaindernear 1.0000 0.3 -> 0.1000 +dqrmn333 remaindernear 0.5 2 -> 0.5 +dqrmn334 remaindernear 0.5 2.1 -> 0.5 +dqrmn335 remaindernear 0.5 2.01 -> 0.50 +dqrmn336 remaindernear 0.5 2.001 -> 0.500 +dqrmn337 remaindernear 0.50 2 -> 0.50 +dqrmn338 remaindernear 0.50 2.01 -> 0.50 +dqrmn339 remaindernear 0.50 2.001 -> 0.500 + +dqrmn340 remaindernear 0.5 0.5000001 -> -1E-7 +dqrmn341 remaindernear 0.5 0.50000001 -> -1E-8 +dqrmn342 remaindernear 0.5 0.500000001 -> -1E-9 +dqrmn343 remaindernear 0.5 0.5000000001 -> -1E-10 +dqrmn344 remaindernear 0.5 0.50000000001 -> -1E-11 +dqrmn345 remaindernear 0.5 0.4999999 -> 1E-7 +dqrmn346 remaindernear 0.5 0.49999999 -> 1E-8 +dqrmn347 remaindernear 0.5 0.499999999 -> 1E-9 +dqrmn348 remaindernear 0.5 0.4999999999 -> 1E-10 +dqrmn349 remaindernear 0.5 0.49999999999 -> 1E-11 +dqrmn350 remaindernear 0.5 0.499999999999 -> 1E-12 + +dqrmn351 remaindernear 0.03 7 -> 0.03 +dqrmn352 remaindernear 5 2 -> 1 +dqrmn353 remaindernear 4.1 2 -> 0.1 +dqrmn354 remaindernear 4.01 2 -> 0.01 +dqrmn355 remaindernear 4.001 2 -> 0.001 +dqrmn356 remaindernear 4.0001 2 -> 0.0001 +dqrmn357 remaindernear 4.00001 2 -> 0.00001 +dqrmn358 remaindernear 4.000001 2 -> 0.000001 +dqrmn359 remaindernear 4.0000001 2 -> 1E-7 + +dqrmn360 remaindernear 1.2 0.7345 -> -0.2690 +dqrmn361 remaindernear 0.8 12 -> 0.8 +dqrmn362 remaindernear 0.8 0.2 -> 0.0 +dqrmn363 remaindernear 0.8 0.3 -> -0.1 +dqrmn364 remaindernear 0.800 12 -> 0.800 +dqrmn365 remaindernear 0.800 1.7 -> 0.800 +dqrmn366 remaindernear 2.400 2 -> 0.400 + +-- round to even +dqrmn371 remaindernear 121 2 -> 1 +dqrmn372 remaindernear 122 2 -> 0 +dqrmn373 remaindernear 123 2 -> -1 +dqrmn374 remaindernear 124 2 -> 0 +dqrmn375 remaindernear 125 2 -> 1 +dqrmn376 remaindernear 126 2 -> 0 +dqrmn377 remaindernear 127 2 -> -1 + +dqrmn381 remaindernear 12345 1 -> 0 +dqrmn382 remaindernear 12345 1.0001 -> -0.2344 +dqrmn383 remaindernear 12345 1.001 -> -0.333 +dqrmn384 remaindernear 12345 1.01 -> -0.23 +dqrmn385 remaindernear 12345 1.1 -> -0.3 +dqrmn386 remaindernear 12355 4 -> -1 +dqrmn387 remaindernear 12345 4 -> 1 +dqrmn388 remaindernear 12355 4.0001 -> -1.3089 +dqrmn389 remaindernear 12345 4.0001 -> 0.6914 +dqrmn390 remaindernear 12345 4.9 -> 1.9 +dqrmn391 remaindernear 12345 4.99 -> -0.26 +dqrmn392 remaindernear 12345 4.999 -> 2.469 +dqrmn393 remaindernear 12345 4.9999 -> 0.2469 +dqrmn394 remaindernear 12345 5 -> 0 +dqrmn395 remaindernear 12345 5.0001 -> -0.2469 +dqrmn396 remaindernear 12345 5.001 -> -2.469 +dqrmn397 remaindernear 12345 5.01 -> 0.36 +dqrmn398 remaindernear 12345 5.1 -> -2.1 + +-- the nasty division-by-1 cases +dqrmn401 remaindernear 0.4 1 -> 0.4 +dqrmn402 remaindernear 0.45 1 -> 0.45 +dqrmn403 remaindernear 0.455 1 -> 0.455 +dqrmn404 remaindernear 0.4555 1 -> 0.4555 +dqrmn405 remaindernear 0.45555 1 -> 0.45555 +dqrmn406 remaindernear 0.455555 1 -> 0.455555 +dqrmn407 remaindernear 0.4555555 1 -> 0.4555555 +dqrmn408 remaindernear 0.45555555 1 -> 0.45555555 +dqrmn409 remaindernear 0.455555555 1 -> 0.455555555 +-- with spill... [412 exercises sticktab loop] +dqrmn411 remaindernear 0.5 1 -> 0.5 +dqrmn412 remaindernear 0.55 1 -> -0.45 +dqrmn413 remaindernear 0.555 1 -> -0.445 +dqrmn414 remaindernear 0.5555 1 -> -0.4445 +dqrmn415 remaindernear 0.55555 1 -> -0.44445 +dqrmn416 remaindernear 0.555555 1 -> -0.444445 +dqrmn417 remaindernear 0.5555555 1 -> -0.4444445 +dqrmn418 remaindernear 0.55555555 1 -> -0.44444445 +dqrmn419 remaindernear 0.555555555 1 -> -0.444444445 + +-- folddowns +dqrmn421 remaindernear 1E+6144 1 -> NaN Division_impossible +dqrmn422 remaindernear 1E+6144 1E+6143 -> 0E+6111 Clamped +dqrmn423 remaindernear 1E+6144 2E+6143 -> 0E+6111 Clamped +dqrmn424 remaindernear 1E+6144 3E+6143 -> 1.00000000000000000000000000000000E+6143 Clamped +dqrmn425 remaindernear 1E+6144 4E+6143 -> 2.00000000000000000000000000000000E+6143 Clamped +dqrmn426 remaindernear 1E+6144 5E+6143 -> 0E+6111 Clamped +dqrmn427 remaindernear 1E+6144 6E+6143 -> -2.00000000000000000000000000000000E+6143 Clamped +dqrmn428 remaindernear 1E+6144 7E+6143 -> 3.00000000000000000000000000000000E+6143 Clamped +dqrmn429 remaindernear 1E+6144 8E+6143 -> 2.00000000000000000000000000000000E+6143 Clamped +dqrmn430 remaindernear 1E+6144 9E+6143 -> 1.00000000000000000000000000000000E+6143 Clamped +-- tinies +dqrmn431 remaindernear 1E-6175 1E-6176 -> 0E-6176 +dqrmn432 remaindernear 1E-6175 2E-6176 -> 0E-6176 +dqrmn433 remaindernear 1E-6175 3E-6176 -> 1E-6176 Subnormal +dqrmn434 remaindernear 1E-6175 4E-6176 -> 2E-6176 Subnormal +dqrmn435 remaindernear 1E-6175 5E-6176 -> 0E-6176 +dqrmn436 remaindernear 1E-6175 6E-6176 -> -2E-6176 Subnormal +dqrmn437 remaindernear 1E-6175 7E-6176 -> 3E-6176 Subnormal +dqrmn438 remaindernear 1E-6175 8E-6176 -> 2E-6176 Subnormal +dqrmn439 remaindernear 1E-6175 9E-6176 -> 1E-6176 Subnormal +dqrmn440 remaindernear 1E-6175 10E-6176 -> 0E-6176 +dqrmn441 remaindernear 1E-6175 11E-6176 -> -1E-6176 Subnormal +dqrmn442 remaindernear 100E-6175 11E-6176 -> -1E-6176 Subnormal +dqrmn443 remaindernear 100E-6175 20E-6176 -> 0E-6176 +dqrmn444 remaindernear 100E-6175 21E-6176 -> -8E-6176 Subnormal +dqrmn445 remaindernear 100E-6175 30E-6176 -> 1.0E-6175 Subnormal + +-- zero signs +dqrmn650 remaindernear 1 1 -> 0 +dqrmn651 remaindernear -1 1 -> -0 +dqrmn652 remaindernear 1 -1 -> 0 +dqrmn653 remaindernear -1 -1 -> -0 +dqrmn654 remaindernear 0 1 -> 0 +dqrmn655 remaindernear -0 1 -> -0 +dqrmn656 remaindernear 0 -1 -> 0 +dqrmn657 remaindernear -0 -1 -> -0 +dqrmn658 remaindernear 0.00 1 -> 0.00 +dqrmn659 remaindernear -0.00 1 -> -0.00 + +-- Specials +dqrmn680 remaindernear Inf -Inf -> NaN Invalid_operation +dqrmn681 remaindernear Inf -1000 -> NaN Invalid_operation +dqrmn682 remaindernear Inf -1 -> NaN Invalid_operation +dqrmn683 remaindernear Inf 0 -> NaN Invalid_operation +dqrmn684 remaindernear Inf -0 -> NaN Invalid_operation +dqrmn685 remaindernear Inf 1 -> NaN Invalid_operation +dqrmn686 remaindernear Inf 1000 -> NaN Invalid_operation +dqrmn687 remaindernear Inf Inf -> NaN Invalid_operation +dqrmn688 remaindernear -1000 Inf -> -1000 +dqrmn689 remaindernear -Inf Inf -> NaN Invalid_operation +dqrmn691 remaindernear -1 Inf -> -1 +dqrmn692 remaindernear 0 Inf -> 0 +dqrmn693 remaindernear -0 Inf -> -0 +dqrmn694 remaindernear 1 Inf -> 1 +dqrmn695 remaindernear 1000 Inf -> 1000 +dqrmn696 remaindernear Inf Inf -> NaN Invalid_operation + +dqrmn700 remaindernear -Inf -Inf -> NaN Invalid_operation +dqrmn701 remaindernear -Inf -1000 -> NaN Invalid_operation +dqrmn702 remaindernear -Inf -1 -> NaN Invalid_operation +dqrmn703 remaindernear -Inf -0 -> NaN Invalid_operation +dqrmn704 remaindernear -Inf 0 -> NaN Invalid_operation +dqrmn705 remaindernear -Inf 1 -> NaN Invalid_operation +dqrmn706 remaindernear -Inf 1000 -> NaN Invalid_operation +dqrmn707 remaindernear -Inf Inf -> NaN Invalid_operation +dqrmn708 remaindernear -Inf -Inf -> NaN Invalid_operation +dqrmn709 remaindernear -1000 Inf -> -1000 +dqrmn710 remaindernear -1 -Inf -> -1 +dqrmn711 remaindernear -0 -Inf -> -0 +dqrmn712 remaindernear 0 -Inf -> 0 +dqrmn713 remaindernear 1 -Inf -> 1 +dqrmn714 remaindernear 1000 -Inf -> 1000 +dqrmn715 remaindernear Inf -Inf -> NaN Invalid_operation + +dqrmn721 remaindernear NaN -Inf -> NaN +dqrmn722 remaindernear NaN -1000 -> NaN +dqrmn723 remaindernear NaN -1 -> NaN +dqrmn724 remaindernear NaN -0 -> NaN +dqrmn725 remaindernear -NaN 0 -> -NaN +dqrmn726 remaindernear NaN 1 -> NaN +dqrmn727 remaindernear NaN 1000 -> NaN +dqrmn728 remaindernear NaN Inf -> NaN +dqrmn729 remaindernear NaN -NaN -> NaN +dqrmn730 remaindernear -Inf NaN -> NaN +dqrmn731 remaindernear -1000 NaN -> NaN +dqrmn732 remaindernear -1 NaN -> NaN +dqrmn733 remaindernear -0 -NaN -> -NaN +dqrmn734 remaindernear 0 NaN -> NaN +dqrmn735 remaindernear 1 -NaN -> -NaN +dqrmn736 remaindernear 1000 NaN -> NaN +dqrmn737 remaindernear Inf NaN -> NaN + +dqrmn741 remaindernear sNaN -Inf -> NaN Invalid_operation +dqrmn742 remaindernear sNaN -1000 -> NaN Invalid_operation +dqrmn743 remaindernear -sNaN -1 -> -NaN Invalid_operation +dqrmn744 remaindernear sNaN -0 -> NaN Invalid_operation +dqrmn745 remaindernear sNaN 0 -> NaN Invalid_operation +dqrmn746 remaindernear sNaN 1 -> NaN Invalid_operation +dqrmn747 remaindernear sNaN 1000 -> NaN Invalid_operation +dqrmn749 remaindernear sNaN NaN -> NaN Invalid_operation +dqrmn750 remaindernear sNaN sNaN -> NaN Invalid_operation +dqrmn751 remaindernear NaN sNaN -> NaN Invalid_operation +dqrmn752 remaindernear -Inf sNaN -> NaN Invalid_operation +dqrmn753 remaindernear -1000 sNaN -> NaN Invalid_operation +dqrmn754 remaindernear -1 sNaN -> NaN Invalid_operation +dqrmn755 remaindernear -0 sNaN -> NaN Invalid_operation +dqrmn756 remaindernear 0 sNaN -> NaN Invalid_operation +dqrmn757 remaindernear 1 sNaN -> NaN Invalid_operation +dqrmn758 remaindernear 1000 sNaN -> NaN Invalid_operation +dqrmn759 remaindernear Inf -sNaN -> -NaN Invalid_operation + +-- propaging NaNs +dqrmn760 remaindernear NaN1 NaN7 -> NaN1 +dqrmn761 remaindernear sNaN2 NaN8 -> NaN2 Invalid_operation +dqrmn762 remaindernear NaN3 sNaN9 -> NaN9 Invalid_operation +dqrmn763 remaindernear sNaN4 sNaN10 -> NaN4 Invalid_operation +dqrmn764 remaindernear 15 NaN11 -> NaN11 +dqrmn765 remaindernear NaN6 NaN12 -> NaN6 +dqrmn766 remaindernear Inf NaN13 -> NaN13 +dqrmn767 remaindernear NaN14 -Inf -> NaN14 +dqrmn768 remaindernear 0 NaN15 -> NaN15 +dqrmn769 remaindernear NaN16 -0 -> NaN16 + +-- edge cases of impossible +dqrmn770 remaindernear 1234500000000000000000067890123456 10 -> -4 +dqrmn771 remaindernear 1234500000000000000000067890123456 1 -> 0 +dqrmn772 remaindernear 1234500000000000000000067890123456 0.1 -> NaN Division_impossible +dqrmn773 remaindernear 1234500000000000000000067890123456 0.01 -> NaN Division_impossible + +-- long operand checks +dqrmn801 remaindernear 12345678000 100 -> 0 +dqrmn802 remaindernear 1 12345678000 -> 1 +dqrmn803 remaindernear 1234567800 10 -> 0 +dqrmn804 remaindernear 1 1234567800 -> 1 +dqrmn805 remaindernear 1234567890 10 -> 0 +dqrmn806 remaindernear 1 1234567890 -> 1 +dqrmn807 remaindernear 1234567891 10 -> 1 +dqrmn808 remaindernear 1 1234567891 -> 1 +dqrmn809 remaindernear 12345678901 100 -> 1 +dqrmn810 remaindernear 1 12345678901 -> 1 +dqrmn811 remaindernear 1234567896 10 -> -4 +dqrmn812 remaindernear 1 1234567896 -> 1 + +dqrmn821 remaindernear 12345678000 100 -> 0 +dqrmn822 remaindernear 1 12345678000 -> 1 +dqrmn823 remaindernear 1234567800 10 -> 0 +dqrmn824 remaindernear 1 1234567800 -> 1 +dqrmn825 remaindernear 1234567890 10 -> 0 +dqrmn826 remaindernear 1 1234567890 -> 1 +dqrmn827 remaindernear 1234567891 10 -> 1 +dqrmn828 remaindernear 1 1234567891 -> 1 +dqrmn829 remaindernear 12345678901 100 -> 1 +dqrmn830 remaindernear 1 12345678901 -> 1 +dqrmn831 remaindernear 1234567896 10 -> -4 +dqrmn832 remaindernear 1 1234567896 -> 1 + +-- from divideint +dqrmn840 remaindernear 100000000.0 1 -> 0.0 +dqrmn841 remaindernear 100000000.4 1 -> 0.4 +dqrmn842 remaindernear 100000000.5 1 -> 0.5 +dqrmn843 remaindernear 100000000.9 1 -> -0.1 +dqrmn844 remaindernear 100000000.999 1 -> -0.001 +dqrmn850 remaindernear 100000003 5 -> -2 +dqrmn851 remaindernear 10000003 5 -> -2 +dqrmn852 remaindernear 1000003 5 -> -2 +dqrmn853 remaindernear 100003 5 -> -2 +dqrmn854 remaindernear 10003 5 -> -2 +dqrmn855 remaindernear 1003 5 -> -2 +dqrmn856 remaindernear 103 5 -> -2 +dqrmn857 remaindernear 13 5 -> -2 +dqrmn858 remaindernear 1 5 -> 1 + +-- Vladimir's cases 1234567890123456 +dqrmn860 remaindernear 123.0e1 1000000000000000 -> 1230 +dqrmn861 remaindernear 1230 1000000000000000 -> 1230 +dqrmn862 remaindernear 12.3e2 1000000000000000 -> 1230 +dqrmn863 remaindernear 1.23e3 1000000000000000 -> 1230 +dqrmn864 remaindernear 123e1 1000000000000000 -> 1230 +dqrmn870 remaindernear 123e1 1000000000000000 -> 1230 +dqrmn871 remaindernear 123e1 100000000000000 -> 1230 +dqrmn872 remaindernear 123e1 10000000000000 -> 1230 +dqrmn873 remaindernear 123e1 1000000000000 -> 1230 +dqrmn874 remaindernear 123e1 100000000000 -> 1230 +dqrmn875 remaindernear 123e1 10000000000 -> 1230 +dqrmn876 remaindernear 123e1 1000000000 -> 1230 +dqrmn877 remaindernear 123e1 100000000 -> 1230 +dqrmn878 remaindernear 1230 100000000 -> 1230 +dqrmn879 remaindernear 123e1 10000000 -> 1230 +dqrmn880 remaindernear 123e1 1000000 -> 1230 +dqrmn881 remaindernear 123e1 100000 -> 1230 +dqrmn882 remaindernear 123e1 10000 -> 1230 +dqrmn883 remaindernear 123e1 1000 -> 230 +dqrmn884 remaindernear 123e1 100 -> 30 +dqrmn885 remaindernear 123e1 10 -> 0 +dqrmn886 remaindernear 123e1 1 -> 0 + +dqrmn890 remaindernear 123e1 2000000000000000 -> 1230 +dqrmn891 remaindernear 123e1 200000000000000 -> 1230 +dqrmn892 remaindernear 123e1 20000000000000 -> 1230 +dqrmn893 remaindernear 123e1 2000000000000 -> 1230 +dqrmn894 remaindernear 123e1 200000000000 -> 1230 +dqrmn895 remaindernear 123e1 20000000000 -> 1230 +dqrmn896 remaindernear 123e1 2000000000 -> 1230 +dqrmn897 remaindernear 123e1 200000000 -> 1230 +dqrmn899 remaindernear 123e1 20000000 -> 1230 +dqrmn900 remaindernear 123e1 2000000 -> 1230 +dqrmn901 remaindernear 123e1 200000 -> 1230 +dqrmn902 remaindernear 123e1 20000 -> 1230 +dqrmn903 remaindernear 123e1 2000 -> -770 +dqrmn904 remaindernear 123e1 200 -> 30 +dqrmn905 remaindernear 123e1 20 -> -10 +dqrmn906 remaindernear 123e1 2 -> 0 + +dqrmn910 remaindernear 123e1 5000000000000000 -> 1230 +dqrmn911 remaindernear 123e1 500000000000000 -> 1230 +dqrmn912 remaindernear 123e1 50000000000000 -> 1230 +dqrmn913 remaindernear 123e1 5000000000000 -> 1230 +dqrmn914 remaindernear 123e1 500000000000 -> 1230 +dqrmn915 remaindernear 123e1 50000000000 -> 1230 +dqrmn916 remaindernear 123e1 5000000000 -> 1230 +dqrmn917 remaindernear 123e1 500000000 -> 1230 +dqrmn919 remaindernear 123e1 50000000 -> 1230 +dqrmn920 remaindernear 123e1 5000000 -> 1230 +dqrmn921 remaindernear 123e1 500000 -> 1230 +dqrmn922 remaindernear 123e1 50000 -> 1230 +dqrmn923 remaindernear 123e1 5000 -> 1230 +dqrmn924 remaindernear 123e1 500 -> 230 +dqrmn925 remaindernear 123e1 50 -> -20 +dqrmn926 remaindernear 123e1 5 -> 0 + +dqrmn930 remaindernear 123e1 9000000000000000 -> 1230 +dqrmn931 remaindernear 123e1 900000000000000 -> 1230 +dqrmn932 remaindernear 123e1 90000000000000 -> 1230 +dqrmn933 remaindernear 123e1 9000000000000 -> 1230 +dqrmn934 remaindernear 123e1 900000000000 -> 1230 +dqrmn935 remaindernear 123e1 90000000000 -> 1230 +dqrmn936 remaindernear 123e1 9000000000 -> 1230 +dqrmn937 remaindernear 123e1 900000000 -> 1230 +dqrmn939 remaindernear 123e1 90000000 -> 1230 +dqrmn940 remaindernear 123e1 9000000 -> 1230 +dqrmn941 remaindernear 123e1 900000 -> 1230 +dqrmn942 remaindernear 123e1 90000 -> 1230 +dqrmn943 remaindernear 123e1 9000 -> 1230 +dqrmn944 remaindernear 123e1 900 -> 330 +dqrmn945 remaindernear 123e1 90 -> -30 +dqrmn946 remaindernear 123e1 9 -> -3 + +dqrmn950 remaindernear 123e1 1000000000000000 -> 1230 +dqrmn961 remaindernear 123e1 2999999999999999 -> 1230 +dqrmn962 remaindernear 123e1 3999999999999999 -> 1230 +dqrmn963 remaindernear 123e1 4999999999999999 -> 1230 +dqrmn964 remaindernear 123e1 5999999999999999 -> 1230 +dqrmn965 remaindernear 123e1 6999999999999999 -> 1230 +dqrmn966 remaindernear 123e1 7999999999999999 -> 1230 +dqrmn967 remaindernear 123e1 8999999999999999 -> 1230 +dqrmn968 remaindernear 123e1 9999999999999999 -> 1230 +dqrmn969 remaindernear 123e1 9876543210987654 -> 1230 + +dqrmn980 remaindernear 123e1 1000E299 -> 1.23E+3 -- 123E+1 internally + +-- overflow and underflow tests [from divide] +dqrmn1051 remaindernear 1e+277 1e-311 -> NaN Division_impossible +dqrmn1052 remaindernear 1e+277 -1e-311 -> NaN Division_impossible +dqrmn1053 remaindernear -1e+277 1e-311 -> NaN Division_impossible +dqrmn1054 remaindernear -1e+277 -1e-311 -> NaN Division_impossible +dqrmn1055 remaindernear 1e-277 1e+311 -> 1E-277 +dqrmn1056 remaindernear 1e-277 -1e+311 -> 1E-277 +dqrmn1057 remaindernear -1e-277 1e+311 -> -1E-277 +dqrmn1058 remaindernear -1e-277 -1e+311 -> -1E-277 + +-- Gyuris example +dqrmn1070 remainder 8.336804418094040989630006819881709E-6143 8.336804418094040989630006819889000E-6143 -> 8.336804418094040989630006819881709E-6143 + +-- destructive subtract +dqrmn1101 remaindernear 1234567890123456789012345678901234 1.000000000000000000000000000000001 -> -0.234567890123456789012345678901233 +dqrmn1102 remaindernear 1234567890123456789012345678901234 1.00000000000000000000000000000001 -> -0.34567890123456789012345678901222 +dqrmn1103 remaindernear 1234567890123456789012345678901234 1.0000000000000000000000000000001 -> -0.4567890123456789012345678901111 +dqrmn1104 remaindernear 1234567890123456789012345678901255 4.000000000000000000000000000000001 -> -1.308641972530864197253086419725314 +dqrmn1105 remaindernear 1234567890123456789012345678901234 4.000000000000000000000000000000001 -> 1.691358027469135802746913580274692 +dqrmn1106 remaindernear 1234567890123456789012345678901234 4.9999999999999999999999999999999 -> -1.3086421975308642197530864219748 +dqrmn1107 remaindernear 1234567890123456789012345678901234 4.99999999999999999999999999999999 -> 1.46913578024691357802469135780247 +dqrmn1108 remaindernear 1234567890123456789012345678901234 4.999999999999999999999999999999999 -> -0.753086421975308642197530864219753 +dqrmn1109 remaindernear 1234567890123456789012345678901234 5.000000000000000000000000000000001 -> -1.246913578024691357802469135780247 +dqrmn1110 remaindernear 1234567890123456789012345678901234 5.00000000000000000000000000000001 -> 1.53086421975308642197530864219754 +dqrmn1111 remaindernear 1234567890123456789012345678901234 5.0000000000000000000000000000001 -> -0.6913578024691357802469135780242 + +-- Null tests +dqrmn1000 remaindernear 10 # -> NaN Invalid_operation +dqrmn1001 remaindernear # 10 -> NaN Invalid_operation + Added: python/branches/release25-maint/Lib/test/decimaltestdata/dqRotate.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/dqRotate.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,298 @@ +------------------------------------------------------------------------ +-- dqRotate.decTest -- rotate decQuad coefficient left or right -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +extended: 1 +clamp: 1 +precision: 34 +maxExponent: 6144 +minExponent: -6143 +rounding: half_even + +-- Sanity check +dqrot001 rotate 0 0 -> 0 +dqrot002 rotate 0 2 -> 0 +dqrot003 rotate 1 2 -> 100 +dqrot004 rotate 1 33 -> 1000000000000000000000000000000000 +dqrot005 rotate 1 34 -> 1 +dqrot006 rotate 1 -1 -> 1000000000000000000000000000000000 +dqrot007 rotate 0 -2 -> 0 +dqrot008 rotate 1234567890123456789012345678901234 -1 -> 4123456789012345678901234567890123 +dqrot009 rotate 1234567890123456789012345678901234 -33 -> 2345678901234567890123456789012341 +dqrot010 rotate 1234567890123456789012345678901234 -34 -> 1234567890123456789012345678901234 +dqrot011 rotate 9934567890123456789012345678901234 -33 -> 9345678901234567890123456789012349 +dqrot012 rotate 9934567890123456789012345678901234 -34 -> 9934567890123456789012345678901234 + +-- rhs must be an integer +dqrot015 rotate 1 1.5 -> NaN Invalid_operation +dqrot016 rotate 1 1.0 -> NaN Invalid_operation +dqrot017 rotate 1 0.1 -> NaN Invalid_operation +dqrot018 rotate 1 0.0 -> NaN Invalid_operation +dqrot019 rotate 1 1E+1 -> NaN Invalid_operation +dqrot020 rotate 1 1E+99 -> NaN Invalid_operation +dqrot021 rotate 1 Inf -> NaN Invalid_operation +dqrot022 rotate 1 -Inf -> NaN Invalid_operation +-- and |rhs| <= precision +dqrot025 rotate 1 -1000 -> NaN Invalid_operation +dqrot026 rotate 1 -35 -> NaN Invalid_operation +dqrot027 rotate 1 35 -> NaN Invalid_operation +dqrot028 rotate 1 1000 -> NaN Invalid_operation + +-- full pattern +dqrot030 rotate 1234567890123456789012345678901234 -34 -> 1234567890123456789012345678901234 +dqrot031 rotate 1234567890123456789012345678901234 -33 -> 2345678901234567890123456789012341 +dqrot032 rotate 1234567890123456789012345678901234 -32 -> 3456789012345678901234567890123412 +dqrot033 rotate 1234567890123456789012345678901234 -31 -> 4567890123456789012345678901234123 +dqrot034 rotate 1234567890123456789012345678901234 -30 -> 5678901234567890123456789012341234 +dqrot035 rotate 1234567890123456789012345678901234 -29 -> 6789012345678901234567890123412345 +dqrot036 rotate 1234567890123456789012345678901234 -28 -> 7890123456789012345678901234123456 +dqrot037 rotate 1234567890123456789012345678901234 -27 -> 8901234567890123456789012341234567 +dqrot038 rotate 1234567890123456789012345678901234 -26 -> 9012345678901234567890123412345678 +dqrot039 rotate 1234567890123456789012345678901234 -25 -> 123456789012345678901234123456789 +dqrot040 rotate 1234567890123456789012345678901234 -24 -> 1234567890123456789012341234567890 +dqrot041 rotate 1234567890123456789012345678901234 -23 -> 2345678901234567890123412345678901 +dqrot042 rotate 1234567890123456789012345678901234 -22 -> 3456789012345678901234123456789012 +dqrot043 rotate 1234567890123456789012345678901234 -21 -> 4567890123456789012341234567890123 +dqrot044 rotate 1234567890123456789012345678901234 -20 -> 5678901234567890123412345678901234 +dqrot045 rotate 1234567890123456789012345678901234 -19 -> 6789012345678901234123456789012345 +dqrot047 rotate 1234567890123456789012345678901234 -18 -> 7890123456789012341234567890123456 +dqrot048 rotate 1234567890123456789012345678901234 -17 -> 8901234567890123412345678901234567 +dqrot049 rotate 1234567890123456789012345678901234 -16 -> 9012345678901234123456789012345678 +dqrot050 rotate 1234567890123456789012345678901234 -15 -> 123456789012341234567890123456789 +dqrot051 rotate 1234567890123456789012345678901234 -14 -> 1234567890123412345678901234567890 +dqrot052 rotate 1234567890123456789012345678901234 -13 -> 2345678901234123456789012345678901 +dqrot053 rotate 1234567890123456789012345678901234 -12 -> 3456789012341234567890123456789012 +dqrot054 rotate 1234567890123456789012345678901234 -11 -> 4567890123412345678901234567890123 +dqrot055 rotate 1234567890123456789012345678901234 -10 -> 5678901234123456789012345678901234 +dqrot056 rotate 1234567890123456789012345678901234 -9 -> 6789012341234567890123456789012345 +dqrot057 rotate 1234567890123456789012345678901234 -8 -> 7890123412345678901234567890123456 +dqrot058 rotate 1234567890123456789012345678901234 -7 -> 8901234123456789012345678901234567 +dqrot059 rotate 1234567890123456789012345678901234 -6 -> 9012341234567890123456789012345678 +dqrot060 rotate 1234567890123456789012345678901234 -5 -> 123412345678901234567890123456789 +dqrot061 rotate 1234567890123456789012345678901234 -4 -> 1234123456789012345678901234567890 +dqrot062 rotate 1234567890123456789012345678901234 -3 -> 2341234567890123456789012345678901 +dqrot063 rotate 1234567890123456789012345678901234 -2 -> 3412345678901234567890123456789012 +dqrot064 rotate 1234567890123456789012345678901234 -1 -> 4123456789012345678901234567890123 +dqrot065 rotate 1234567890123456789012345678901234 -0 -> 1234567890123456789012345678901234 + +dqrot066 rotate 1234567890123456789012345678901234 +0 -> 1234567890123456789012345678901234 +dqrot067 rotate 1234567890123456789012345678901234 +1 -> 2345678901234567890123456789012341 +dqrot068 rotate 1234567890123456789012345678901234 +2 -> 3456789012345678901234567890123412 +dqrot069 rotate 1234567890123456789012345678901234 +3 -> 4567890123456789012345678901234123 +dqrot070 rotate 1234567890123456789012345678901234 +4 -> 5678901234567890123456789012341234 +dqrot071 rotate 1234567890123456789012345678901234 +5 -> 6789012345678901234567890123412345 +dqrot072 rotate 1234567890123456789012345678901234 +6 -> 7890123456789012345678901234123456 +dqrot073 rotate 1234567890123456789012345678901234 +7 -> 8901234567890123456789012341234567 +dqrot074 rotate 1234567890123456789012345678901234 +8 -> 9012345678901234567890123412345678 +dqrot075 rotate 1234567890123456789012345678901234 +9 -> 123456789012345678901234123456789 +dqrot076 rotate 1234567890123456789012345678901234 +10 -> 1234567890123456789012341234567890 +dqrot077 rotate 1234567890123456789012345678901234 +11 -> 2345678901234567890123412345678901 +dqrot078 rotate 1234567890123456789012345678901234 +12 -> 3456789012345678901234123456789012 +dqrot079 rotate 1234567890123456789012345678901234 +13 -> 4567890123456789012341234567890123 +dqrot080 rotate 1234567890123456789012345678901234 +14 -> 5678901234567890123412345678901234 +dqrot081 rotate 1234567890123456789012345678901234 +15 -> 6789012345678901234123456789012345 +dqrot082 rotate 1234567890123456789012345678901234 +16 -> 7890123456789012341234567890123456 +dqrot083 rotate 1234567890123456789012345678901234 +17 -> 8901234567890123412345678901234567 +dqrot084 rotate 1234567890123456789012345678901234 +18 -> 9012345678901234123456789012345678 +dqrot085 rotate 1234567890123456789012345678901234 +19 -> 123456789012341234567890123456789 +dqrot086 rotate 1234567890123456789012345678901234 +20 -> 1234567890123412345678901234567890 +dqrot087 rotate 1234567890123456789012345678901234 +21 -> 2345678901234123456789012345678901 +dqrot088 rotate 1234567890123456789012345678901234 +22 -> 3456789012341234567890123456789012 +dqrot089 rotate 1234567890123456789012345678901234 +23 -> 4567890123412345678901234567890123 +dqrot090 rotate 1234567890123456789012345678901234 +24 -> 5678901234123456789012345678901234 +dqrot091 rotate 1234567890123456789012345678901234 +25 -> 6789012341234567890123456789012345 +dqrot092 rotate 1234567890123456789012345678901234 +26 -> 7890123412345678901234567890123456 +dqrot093 rotate 1234567890123456789012345678901234 +27 -> 8901234123456789012345678901234567 +dqrot094 rotate 1234567890123456789012345678901234 +28 -> 9012341234567890123456789012345678 +dqrot095 rotate 1234567890123456789012345678901234 +29 -> 123412345678901234567890123456789 +dqrot096 rotate 1234567890123456789012345678901234 +30 -> 1234123456789012345678901234567890 +dqrot097 rotate 1234567890123456789012345678901234 +31 -> 2341234567890123456789012345678901 +dqrot098 rotate 1234567890123456789012345678901234 +32 -> 3412345678901234567890123456789012 +dqrot099 rotate 1234567890123456789012345678901234 +33 -> 4123456789012345678901234567890123 +dqrot100 rotate 1234567890123456789012345678901234 +34 -> 1234567890123456789012345678901234 + +-- zeros +dqrot270 rotate 0E-10 +29 -> 0E-10 +dqrot271 rotate 0E-10 -29 -> 0E-10 +dqrot272 rotate 0.000 +29 -> 0.000 +dqrot273 rotate 0.000 -29 -> 0.000 +dqrot274 rotate 0E+10 +29 -> 0E+10 +dqrot275 rotate 0E+10 -29 -> 0E+10 +dqrot276 rotate -0E-10 +29 -> -0E-10 +dqrot277 rotate -0E-10 -29 -> -0E-10 +dqrot278 rotate -0.000 +29 -> -0.000 +dqrot279 rotate -0.000 -29 -> -0.000 +dqrot280 rotate -0E+10 +29 -> -0E+10 +dqrot281 rotate -0E+10 -29 -> -0E+10 + +-- Nmax, Nmin, Ntiny +dqrot141 rotate 9.999999999999999999999999999999999E+6144 -1 -> 9.999999999999999999999999999999999E+6144 +dqrot142 rotate 9.999999999999999999999999999999999E+6144 -33 -> 9.999999999999999999999999999999999E+6144 +dqrot143 rotate 9.999999999999999999999999999999999E+6144 1 -> 9.999999999999999999999999999999999E+6144 +dqrot144 rotate 9.999999999999999999999999999999999E+6144 33 -> 9.999999999999999999999999999999999E+6144 +dqrot145 rotate 1E-6143 -1 -> 1.000000000000000000000000000000000E-6110 +dqrot146 rotate 1E-6143 -33 -> 1.0E-6142 +dqrot147 rotate 1E-6143 1 -> 1.0E-6142 +dqrot148 rotate 1E-6143 33 -> 1.000000000000000000000000000000000E-6110 +dqrot151 rotate 1.000000000000000000000000000000000E-6143 -1 -> 1.00000000000000000000000000000000E-6144 +dqrot152 rotate 1.000000000000000000000000000000000E-6143 -33 -> 1E-6176 +dqrot153 rotate 1.000000000000000000000000000000000E-6143 1 -> 1E-6176 +dqrot154 rotate 1.000000000000000000000000000000000E-6143 33 -> 1.00000000000000000000000000000000E-6144 +dqrot155 rotate 9.000000000000000000000000000000000E-6143 -1 -> 9.00000000000000000000000000000000E-6144 +dqrot156 rotate 9.000000000000000000000000000000000E-6143 -33 -> 9E-6176 +dqrot157 rotate 9.000000000000000000000000000000000E-6143 1 -> 9E-6176 +dqrot158 rotate 9.000000000000000000000000000000000E-6143 33 -> 9.00000000000000000000000000000000E-6144 +dqrot160 rotate 1E-6176 -1 -> 1.000000000000000000000000000000000E-6143 +dqrot161 rotate 1E-6176 -33 -> 1.0E-6175 +dqrot162 rotate 1E-6176 1 -> 1.0E-6175 +dqrot163 rotate 1E-6176 33 -> 1.000000000000000000000000000000000E-6143 +-- negatives +dqrot171 rotate -9.999999999999999999999999999999999E+6144 -1 -> -9.999999999999999999999999999999999E+6144 +dqrot172 rotate -9.999999999999999999999999999999999E+6144 -33 -> -9.999999999999999999999999999999999E+6144 +dqrot173 rotate -9.999999999999999999999999999999999E+6144 1 -> -9.999999999999999999999999999999999E+6144 +dqrot174 rotate -9.999999999999999999999999999999999E+6144 33 -> -9.999999999999999999999999999999999E+6144 +dqrot175 rotate -1E-6143 -1 -> -1.000000000000000000000000000000000E-6110 +dqrot176 rotate -1E-6143 -33 -> -1.0E-6142 +dqrot177 rotate -1E-6143 1 -> -1.0E-6142 +dqrot178 rotate -1E-6143 33 -> -1.000000000000000000000000000000000E-6110 +dqrot181 rotate -1.000000000000000000000000000000000E-6143 -1 -> -1.00000000000000000000000000000000E-6144 +dqrot182 rotate -1.000000000000000000000000000000000E-6143 -33 -> -1E-6176 +dqrot183 rotate -1.000000000000000000000000000000000E-6143 1 -> -1E-6176 +dqrot184 rotate -1.000000000000000000000000000000000E-6143 33 -> -1.00000000000000000000000000000000E-6144 +dqrot185 rotate -9.000000000000000000000000000000000E-6143 -1 -> -9.00000000000000000000000000000000E-6144 +dqrot186 rotate -9.000000000000000000000000000000000E-6143 -33 -> -9E-6176 +dqrot187 rotate -9.000000000000000000000000000000000E-6143 1 -> -9E-6176 +dqrot188 rotate -9.000000000000000000000000000000000E-6143 33 -> -9.00000000000000000000000000000000E-6144 +dqrot190 rotate -1E-6176 -1 -> -1.000000000000000000000000000000000E-6143 +dqrot191 rotate -1E-6176 -33 -> -1.0E-6175 +dqrot192 rotate -1E-6176 1 -> -1.0E-6175 +dqrot193 rotate -1E-6176 33 -> -1.000000000000000000000000000000000E-6143 + +-- more negatives (of sanities) +dqrot201 rotate -0 0 -> -0 +dqrot202 rotate -0 2 -> -0 +dqrot203 rotate -1 2 -> -100 +dqrot204 rotate -1 33 -> -1000000000000000000000000000000000 +dqrot205 rotate -1 34 -> -1 +dqrot206 rotate -1 -1 -> -1000000000000000000000000000000000 +dqrot207 rotate -0 -2 -> -0 +dqrot208 rotate -1234567890123456789012345678901234 -1 -> -4123456789012345678901234567890123 +dqrot209 rotate -1234567890123456789012345678901234 -33 -> -2345678901234567890123456789012341 +dqrot210 rotate -1234567890123456789012345678901234 -34 -> -1234567890123456789012345678901234 +dqrot211 rotate -9934567890123456789012345678901234 -33 -> -9345678901234567890123456789012349 +dqrot212 rotate -9934567890123456789012345678901234 -34 -> -9934567890123456789012345678901234 + + +-- Specials; NaNs are handled as usual +dqrot781 rotate -Inf -8 -> -Infinity +dqrot782 rotate -Inf -1 -> -Infinity +dqrot783 rotate -Inf -0 -> -Infinity +dqrot784 rotate -Inf 0 -> -Infinity +dqrot785 rotate -Inf 1 -> -Infinity +dqrot786 rotate -Inf 8 -> -Infinity +dqrot787 rotate -1000 -Inf -> NaN Invalid_operation +dqrot788 rotate -Inf -Inf -> NaN Invalid_operation +dqrot789 rotate -1 -Inf -> NaN Invalid_operation +dqrot790 rotate -0 -Inf -> NaN Invalid_operation +dqrot791 rotate 0 -Inf -> NaN Invalid_operation +dqrot792 rotate 1 -Inf -> NaN Invalid_operation +dqrot793 rotate 1000 -Inf -> NaN Invalid_operation +dqrot794 rotate Inf -Inf -> NaN Invalid_operation + +dqrot800 rotate Inf -Inf -> NaN Invalid_operation +dqrot801 rotate Inf -8 -> Infinity +dqrot802 rotate Inf -1 -> Infinity +dqrot803 rotate Inf -0 -> Infinity +dqrot804 rotate Inf 0 -> Infinity +dqrot805 rotate Inf 1 -> Infinity +dqrot806 rotate Inf 8 -> Infinity +dqrot807 rotate Inf Inf -> NaN Invalid_operation +dqrot808 rotate -1000 Inf -> NaN Invalid_operation +dqrot809 rotate -Inf Inf -> NaN Invalid_operation +dqrot810 rotate -1 Inf -> NaN Invalid_operation +dqrot811 rotate -0 Inf -> NaN Invalid_operation +dqrot812 rotate 0 Inf -> NaN Invalid_operation +dqrot813 rotate 1 Inf -> NaN Invalid_operation +dqrot814 rotate 1000 Inf -> NaN Invalid_operation +dqrot815 rotate Inf Inf -> NaN Invalid_operation + +dqrot821 rotate NaN -Inf -> NaN +dqrot822 rotate NaN -1000 -> NaN +dqrot823 rotate NaN -1 -> NaN +dqrot824 rotate NaN -0 -> NaN +dqrot825 rotate NaN 0 -> NaN +dqrot826 rotate NaN 1 -> NaN +dqrot827 rotate NaN 1000 -> NaN +dqrot828 rotate NaN Inf -> NaN +dqrot829 rotate NaN NaN -> NaN +dqrot830 rotate -Inf NaN -> NaN +dqrot831 rotate -1000 NaN -> NaN +dqrot832 rotate -1 NaN -> NaN +dqrot833 rotate -0 NaN -> NaN +dqrot834 rotate 0 NaN -> NaN +dqrot835 rotate 1 NaN -> NaN +dqrot836 rotate 1000 NaN -> NaN +dqrot837 rotate Inf NaN -> NaN + +dqrot841 rotate sNaN -Inf -> NaN Invalid_operation +dqrot842 rotate sNaN -1000 -> NaN Invalid_operation +dqrot843 rotate sNaN -1 -> NaN Invalid_operation +dqrot844 rotate sNaN -0 -> NaN Invalid_operation +dqrot845 rotate sNaN 0 -> NaN Invalid_operation +dqrot846 rotate sNaN 1 -> NaN Invalid_operation +dqrot847 rotate sNaN 1000 -> NaN Invalid_operation +dqrot848 rotate sNaN NaN -> NaN Invalid_operation +dqrot849 rotate sNaN sNaN -> NaN Invalid_operation +dqrot850 rotate NaN sNaN -> NaN Invalid_operation +dqrot851 rotate -Inf sNaN -> NaN Invalid_operation +dqrot852 rotate -1000 sNaN -> NaN Invalid_operation +dqrot853 rotate -1 sNaN -> NaN Invalid_operation +dqrot854 rotate -0 sNaN -> NaN Invalid_operation +dqrot855 rotate 0 sNaN -> NaN Invalid_operation +dqrot856 rotate 1 sNaN -> NaN Invalid_operation +dqrot857 rotate 1000 sNaN -> NaN Invalid_operation +dqrot858 rotate Inf sNaN -> NaN Invalid_operation +dqrot859 rotate NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +dqrot861 rotate NaN1 -Inf -> NaN1 +dqrot862 rotate +NaN2 -1000 -> NaN2 +dqrot863 rotate NaN3 1000 -> NaN3 +dqrot864 rotate NaN4 Inf -> NaN4 +dqrot865 rotate NaN5 +NaN6 -> NaN5 +dqrot866 rotate -Inf NaN7 -> NaN7 +dqrot867 rotate -1000 NaN8 -> NaN8 +dqrot868 rotate 1000 NaN9 -> NaN9 +dqrot869 rotate Inf +NaN10 -> NaN10 +dqrot871 rotate sNaN11 -Inf -> NaN11 Invalid_operation +dqrot872 rotate sNaN12 -1000 -> NaN12 Invalid_operation +dqrot873 rotate sNaN13 1000 -> NaN13 Invalid_operation +dqrot874 rotate sNaN14 NaN17 -> NaN14 Invalid_operation +dqrot875 rotate sNaN15 sNaN18 -> NaN15 Invalid_operation +dqrot876 rotate NaN16 sNaN19 -> NaN19 Invalid_operation +dqrot877 rotate -Inf +sNaN20 -> NaN20 Invalid_operation +dqrot878 rotate -1000 sNaN21 -> NaN21 Invalid_operation +dqrot879 rotate 1000 sNaN22 -> NaN22 Invalid_operation +dqrot880 rotate Inf sNaN23 -> NaN23 Invalid_operation +dqrot881 rotate +NaN25 +sNaN24 -> NaN24 Invalid_operation +dqrot882 rotate -NaN26 NaN28 -> -NaN26 +dqrot883 rotate -sNaN27 sNaN29 -> -NaN27 Invalid_operation +dqrot884 rotate 1000 -NaN30 -> -NaN30 +dqrot885 rotate 1000 -sNaN31 -> -NaN31 Invalid_operation Added: python/branches/release25-maint/Lib/test/decimaltestdata/dqSameQuantum.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/dqSameQuantum.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,389 @@ +------------------------------------------------------------------------ +-- dqSameQuantum.decTest -- check decQuad quantums match -- +-- Copyright (c) IBM Corporation, 2001, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- All operands and results are decQuads. +extended: 1 +clamp: 1 +precision: 34 +maxExponent: 6144 +minExponent: -6143 +rounding: half_even + +dqsamq001 samequantum 0 0 -> 1 +dqsamq002 samequantum 0 1 -> 1 +dqsamq003 samequantum 1 0 -> 1 +dqsamq004 samequantum 1 1 -> 1 + +dqsamq011 samequantum 10 1E+1 -> 0 +dqsamq012 samequantum 10E+1 10E+1 -> 1 +dqsamq013 samequantum 100 10E+1 -> 0 +dqsamq014 samequantum 100 1E+2 -> 0 +dqsamq015 samequantum 0.1 1E-2 -> 0 +dqsamq016 samequantum 0.1 1E-1 -> 1 +dqsamq017 samequantum 0.1 1E-0 -> 0 +dqsamq018 samequantum 999 999 -> 1 +dqsamq019 samequantum 999E-1 99.9 -> 1 +dqsamq020 samequantum 111E-1 22.2 -> 1 +dqsamq021 samequantum 111E-1 1234.2 -> 1 + +-- zeros +dqsamq030 samequantum 0.0 1.1 -> 1 +dqsamq031 samequantum 0.0 1.11 -> 0 +dqsamq032 samequantum 0.0 0 -> 0 +dqsamq033 samequantum 0.0 0.0 -> 1 +dqsamq034 samequantum 0.0 0.00 -> 0 +dqsamq035 samequantum 0E+1 0E+0 -> 0 +dqsamq036 samequantum 0E+1 0E+1 -> 1 +dqsamq037 samequantum 0E+1 0E+2 -> 0 +dqsamq038 samequantum 0E-17 0E-16 -> 0 +dqsamq039 samequantum 0E-17 0E-17 -> 1 +dqsamq040 samequantum 0E-17 0E-18 -> 0 +dqsamq041 samequantum 0E-17 0.0E-15 -> 0 +dqsamq042 samequantum 0E-17 0.0E-16 -> 1 +dqsamq043 samequantum 0E-17 0.0E-17 -> 0 +dqsamq044 samequantum -0E-17 0.0E-16 -> 1 +dqsamq045 samequantum 0E-17 -0.0E-17 -> 0 +dqsamq046 samequantum 0E-17 -0.0E-16 -> 1 +dqsamq047 samequantum -0E-17 0.0E-17 -> 0 +dqsamq048 samequantum -0E-17 -0.0E-16 -> 1 +dqsamq049 samequantum -0E-17 -0.0E-17 -> 0 + +-- Nmax, Nmin, Ntiny +dqsamq051 samequantum 9.99999999999999999999999999999999E+6144 9.99999999999999999999999999999999E+6144 -> 1 +dqsamq052 samequantum 1E-6143 1E-6143 -> 1 +dqsamq053 samequantum 1.00000000000000000000000000000000E-6143 1.00000000000000000000000000000000E-6143 -> 1 +dqsamq054 samequantum 1E-6176 1E-6176 -> 1 +dqsamq055 samequantum 9.99999999999999999999999999999999E+6144 9.99999999999999999999999999999999E+6144 -> 1 +dqsamq056 samequantum 1E-6143 1E-6143 -> 1 +dqsamq057 samequantum 1.00000000000000000000000000000000E-6143 1.00000000000000000000000000000000E-6143 -> 1 +dqsamq058 samequantum 1E-6176 1E-6176 -> 1 + +dqsamq061 samequantum -1E-6176 -1E-6176 -> 1 +dqsamq062 samequantum -1.00000000000000000000000000000000E-6143 -1.00000000000000000000000000000000E-6143 -> 1 +dqsamq063 samequantum -1E-6143 -1E-6143 -> 1 +dqsamq064 samequantum -9.99999999999999999999999999999999E+6144 -9.99999999999999999999999999999999E+6144 -> 1 +dqsamq065 samequantum -1E-6176 -1E-6176 -> 1 +dqsamq066 samequantum -1.00000000000000000000000000000000E-6143 -1.00000000000000000000000000000000E-6143 -> 1 +dqsamq067 samequantum -1E-6143 -1E-6143 -> 1 +dqsamq068 samequantum -9.99999999999999999999999999999999E+6144 -9.99999999999999999999999999999999E+6144 -> 1 + +dqsamq071 samequantum -4E-6176 -1E-6176 -> 1 +dqsamq072 samequantum -4.00000000000000000000000000000000E-6143 -1.00000000000000000000000000004000E-6143 -> 1 +dqsamq073 samequantum -4E-6143 -1E-6143 -> 1 +dqsamq074 samequantum -4.99999999999999999999999999999999E+6144 -9.99949999999999999999999999999999E+6144 -> 1 +dqsamq075 samequantum -4E-6176 -1E-6176 -> 1 +dqsamq076 samequantum -4.00000000000000000000000000000000E-6143 -1.00400000000000000000000000000000E-6143 -> 1 +dqsamq077 samequantum -4E-6143 -1E-6143 -> 1 +dqsamq078 samequantum -4.99999999999999999999999999999999E+6144 -9.94999999999999999999999999999999E+6144 -> 1 + +dqsamq081 samequantum -4E-1006 -1E-6176 -> 0 +dqsamq082 samequantum -4.00000000000000000000000000000000E-6143 -1.00004000000000000000000000000000E-6136 -> 0 +dqsamq083 samequantum -4E-6140 -1E-6143 -> 0 +dqsamq084 samequantum -4.99999999999999999999999999999999E+6144 -9.99949999999999999999999999999999E+6136 -> 0 +dqsamq085 samequantum -4E-1006 -1E-6176 -> 0 +dqsamq086 samequantum -4.00000000000000000000000000000000E-6143 -1.00400000000000000000000000000000E-6136 -> 0 +dqsamq087 samequantum -4E-6133 -1E-6143 -> 0 +dqsamq088 samequantum -4.99999999999999999999999999999999E+6144 -9.94999999999999999999999999999999E+6136 -> 0 + +-- specials & combinations +dqsamq0110 samequantum -Inf -Inf -> 1 +dqsamq0111 samequantum -Inf Inf -> 1 +dqsamq0112 samequantum -Inf NaN -> 0 +dqsamq0113 samequantum -Inf -7E+3 -> 0 +dqsamq0114 samequantum -Inf -7 -> 0 +dqsamq0115 samequantum -Inf -7E-3 -> 0 +dqsamq0116 samequantum -Inf -0E-3 -> 0 +dqsamq0117 samequantum -Inf -0 -> 0 +dqsamq0118 samequantum -Inf -0E+3 -> 0 +dqsamq0119 samequantum -Inf 0E-3 -> 0 +dqsamq0120 samequantum -Inf 0 -> 0 +dqsamq0121 samequantum -Inf 0E+3 -> 0 +dqsamq0122 samequantum -Inf 7E-3 -> 0 +dqsamq0123 samequantum -Inf 7 -> 0 +dqsamq0124 samequantum -Inf 7E+3 -> 0 +dqsamq0125 samequantum -Inf sNaN -> 0 + +dqsamq0210 samequantum Inf -Inf -> 1 +dqsamq0211 samequantum Inf Inf -> 1 +dqsamq0212 samequantum Inf NaN -> 0 +dqsamq0213 samequantum Inf -7E+3 -> 0 +dqsamq0214 samequantum Inf -7 -> 0 +dqsamq0215 samequantum Inf -7E-3 -> 0 +dqsamq0216 samequantum Inf -0E-3 -> 0 +dqsamq0217 samequantum Inf -0 -> 0 +dqsamq0218 samequantum Inf -0E+3 -> 0 +dqsamq0219 samequantum Inf 0E-3 -> 0 +dqsamq0220 samequantum Inf 0 -> 0 +dqsamq0221 samequantum Inf 0E+3 -> 0 +dqsamq0222 samequantum Inf 7E-3 -> 0 +dqsamq0223 samequantum Inf 7 -> 0 +dqsamq0224 samequantum Inf 7E+3 -> 0 +dqsamq0225 samequantum Inf sNaN -> 0 + +dqsamq0310 samequantum NaN -Inf -> 0 +dqsamq0311 samequantum NaN Inf -> 0 +dqsamq0312 samequantum NaN NaN -> 1 +dqsamq0313 samequantum NaN -7E+3 -> 0 +dqsamq0314 samequantum NaN -7 -> 0 +dqsamq0315 samequantum NaN -7E-3 -> 0 +dqsamq0316 samequantum NaN -0E-3 -> 0 +dqsamq0317 samequantum NaN -0 -> 0 +dqsamq0318 samequantum NaN -0E+3 -> 0 +dqsamq0319 samequantum NaN 0E-3 -> 0 +dqsamq0320 samequantum NaN 0 -> 0 +dqsamq0321 samequantum NaN 0E+3 -> 0 +dqsamq0322 samequantum NaN 7E-3 -> 0 +dqsamq0323 samequantum NaN 7 -> 0 +dqsamq0324 samequantum NaN 7E+3 -> 0 +dqsamq0325 samequantum NaN sNaN -> 1 + +dqsamq0410 samequantum -7E+3 -Inf -> 0 +dqsamq0411 samequantum -7E+3 Inf -> 0 +dqsamq0412 samequantum -7E+3 NaN -> 0 +dqsamq0413 samequantum -7E+3 -7E+3 -> 1 +dqsamq0414 samequantum -7E+3 -7 -> 0 +dqsamq0415 samequantum -7E+3 -7E-3 -> 0 +dqsamq0416 samequantum -7E+3 -0E-3 -> 0 +dqsamq0417 samequantum -7E+3 -0 -> 0 +dqsamq0418 samequantum -7E+3 -0E+3 -> 1 +dqsamq0419 samequantum -7E+3 0E-3 -> 0 +dqsamq0420 samequantum -7E+3 0 -> 0 +dqsamq0421 samequantum -7E+3 0E+3 -> 1 +dqsamq0422 samequantum -7E+3 7E-3 -> 0 +dqsamq0423 samequantum -7E+3 7 -> 0 +dqsamq0424 samequantum -7E+3 7E+3 -> 1 +dqsamq0425 samequantum -7E+3 sNaN -> 0 + +dqsamq0510 samequantum -7 -Inf -> 0 +dqsamq0511 samequantum -7 Inf -> 0 +dqsamq0512 samequantum -7 NaN -> 0 +dqsamq0513 samequantum -7 -7E+3 -> 0 +dqsamq0514 samequantum -7 -7 -> 1 +dqsamq0515 samequantum -7 -7E-3 -> 0 +dqsamq0516 samequantum -7 -0E-3 -> 0 +dqsamq0517 samequantum -7 -0 -> 1 +dqsamq0518 samequantum -7 -0E+3 -> 0 +dqsamq0519 samequantum -7 0E-3 -> 0 +dqsamq0520 samequantum -7 0 -> 1 +dqsamq0521 samequantum -7 0E+3 -> 0 +dqsamq0522 samequantum -7 7E-3 -> 0 +dqsamq0523 samequantum -7 7 -> 1 +dqsamq0524 samequantum -7 7E+3 -> 0 +dqsamq0525 samequantum -7 sNaN -> 0 + +dqsamq0610 samequantum -7E-3 -Inf -> 0 +dqsamq0611 samequantum -7E-3 Inf -> 0 +dqsamq0612 samequantum -7E-3 NaN -> 0 +dqsamq0613 samequantum -7E-3 -7E+3 -> 0 +dqsamq0614 samequantum -7E-3 -7 -> 0 +dqsamq0615 samequantum -7E-3 -7E-3 -> 1 +dqsamq0616 samequantum -7E-3 -0E-3 -> 1 +dqsamq0617 samequantum -7E-3 -0 -> 0 +dqsamq0618 samequantum -7E-3 -0E+3 -> 0 +dqsamq0619 samequantum -7E-3 0E-3 -> 1 +dqsamq0620 samequantum -7E-3 0 -> 0 +dqsamq0621 samequantum -7E-3 0E+3 -> 0 +dqsamq0622 samequantum -7E-3 7E-3 -> 1 +dqsamq0623 samequantum -7E-3 7 -> 0 +dqsamq0624 samequantum -7E-3 7E+3 -> 0 +dqsamq0625 samequantum -7E-3 sNaN -> 0 + +dqsamq0710 samequantum -0E-3 -Inf -> 0 +dqsamq0711 samequantum -0E-3 Inf -> 0 +dqsamq0712 samequantum -0E-3 NaN -> 0 +dqsamq0713 samequantum -0E-3 -7E+3 -> 0 +dqsamq0714 samequantum -0E-3 -7 -> 0 +dqsamq0715 samequantum -0E-3 -7E-3 -> 1 +dqsamq0716 samequantum -0E-3 -0E-3 -> 1 +dqsamq0717 samequantum -0E-3 -0 -> 0 +dqsamq0718 samequantum -0E-3 -0E+3 -> 0 +dqsamq0719 samequantum -0E-3 0E-3 -> 1 +dqsamq0720 samequantum -0E-3 0 -> 0 +dqsamq0721 samequantum -0E-3 0E+3 -> 0 +dqsamq0722 samequantum -0E-3 7E-3 -> 1 +dqsamq0723 samequantum -0E-3 7 -> 0 +dqsamq0724 samequantum -0E-3 7E+3 -> 0 +dqsamq0725 samequantum -0E-3 sNaN -> 0 + +dqsamq0810 samequantum -0 -Inf -> 0 +dqsamq0811 samequantum -0 Inf -> 0 +dqsamq0812 samequantum -0 NaN -> 0 +dqsamq0813 samequantum -0 -7E+3 -> 0 +dqsamq0814 samequantum -0 -7 -> 1 +dqsamq0815 samequantum -0 -7E-3 -> 0 +dqsamq0816 samequantum -0 -0E-3 -> 0 +dqsamq0817 samequantum -0 -0 -> 1 +dqsamq0818 samequantum -0 -0E+3 -> 0 +dqsamq0819 samequantum -0 0E-3 -> 0 +dqsamq0820 samequantum -0 0 -> 1 +dqsamq0821 samequantum -0 0E+3 -> 0 +dqsamq0822 samequantum -0 7E-3 -> 0 +dqsamq0823 samequantum -0 7 -> 1 +dqsamq0824 samequantum -0 7E+3 -> 0 +dqsamq0825 samequantum -0 sNaN -> 0 + +dqsamq0910 samequantum -0E+3 -Inf -> 0 +dqsamq0911 samequantum -0E+3 Inf -> 0 +dqsamq0912 samequantum -0E+3 NaN -> 0 +dqsamq0913 samequantum -0E+3 -7E+3 -> 1 +dqsamq0914 samequantum -0E+3 -7 -> 0 +dqsamq0915 samequantum -0E+3 -7E-3 -> 0 +dqsamq0916 samequantum -0E+3 -0E-3 -> 0 +dqsamq0917 samequantum -0E+3 -0 -> 0 +dqsamq0918 samequantum -0E+3 -0E+3 -> 1 +dqsamq0919 samequantum -0E+3 0E-3 -> 0 +dqsamq0920 samequantum -0E+3 0 -> 0 +dqsamq0921 samequantum -0E+3 0E+3 -> 1 +dqsamq0922 samequantum -0E+3 7E-3 -> 0 +dqsamq0923 samequantum -0E+3 7 -> 0 +dqsamq0924 samequantum -0E+3 7E+3 -> 1 +dqsamq0925 samequantum -0E+3 sNaN -> 0 + +dqsamq1110 samequantum 0E-3 -Inf -> 0 +dqsamq1111 samequantum 0E-3 Inf -> 0 +dqsamq1112 samequantum 0E-3 NaN -> 0 +dqsamq1113 samequantum 0E-3 -7E+3 -> 0 +dqsamq1114 samequantum 0E-3 -7 -> 0 +dqsamq1115 samequantum 0E-3 -7E-3 -> 1 +dqsamq1116 samequantum 0E-3 -0E-3 -> 1 +dqsamq1117 samequantum 0E-3 -0 -> 0 +dqsamq1118 samequantum 0E-3 -0E+3 -> 0 +dqsamq1119 samequantum 0E-3 0E-3 -> 1 +dqsamq1120 samequantum 0E-3 0 -> 0 +dqsamq1121 samequantum 0E-3 0E+3 -> 0 +dqsamq1122 samequantum 0E-3 7E-3 -> 1 +dqsamq1123 samequantum 0E-3 7 -> 0 +dqsamq1124 samequantum 0E-3 7E+3 -> 0 +dqsamq1125 samequantum 0E-3 sNaN -> 0 + +dqsamq1210 samequantum 0 -Inf -> 0 +dqsamq1211 samequantum 0 Inf -> 0 +dqsamq1212 samequantum 0 NaN -> 0 +dqsamq1213 samequantum 0 -7E+3 -> 0 +dqsamq1214 samequantum 0 -7 -> 1 +dqsamq1215 samequantum 0 -7E-3 -> 0 +dqsamq1216 samequantum 0 -0E-3 -> 0 +dqsamq1217 samequantum 0 -0 -> 1 +dqsamq1218 samequantum 0 -0E+3 -> 0 +dqsamq1219 samequantum 0 0E-3 -> 0 +dqsamq1220 samequantum 0 0 -> 1 +dqsamq1221 samequantum 0 0E+3 -> 0 +dqsamq1222 samequantum 0 7E-3 -> 0 +dqsamq1223 samequantum 0 7 -> 1 +dqsamq1224 samequantum 0 7E+3 -> 0 +dqsamq1225 samequantum 0 sNaN -> 0 + +dqsamq1310 samequantum 0E+3 -Inf -> 0 +dqsamq1311 samequantum 0E+3 Inf -> 0 +dqsamq1312 samequantum 0E+3 NaN -> 0 +dqsamq1313 samequantum 0E+3 -7E+3 -> 1 +dqsamq1314 samequantum 0E+3 -7 -> 0 +dqsamq1315 samequantum 0E+3 -7E-3 -> 0 +dqsamq1316 samequantum 0E+3 -0E-3 -> 0 +dqsamq1317 samequantum 0E+3 -0 -> 0 +dqsamq1318 samequantum 0E+3 -0E+3 -> 1 +dqsamq1319 samequantum 0E+3 0E-3 -> 0 +dqsamq1320 samequantum 0E+3 0 -> 0 +dqsamq1321 samequantum 0E+3 0E+3 -> 1 +dqsamq1322 samequantum 0E+3 7E-3 -> 0 +dqsamq1323 samequantum 0E+3 7 -> 0 +dqsamq1324 samequantum 0E+3 7E+3 -> 1 +dqsamq1325 samequantum 0E+3 sNaN -> 0 + +dqsamq1410 samequantum 7E-3 -Inf -> 0 +dqsamq1411 samequantum 7E-3 Inf -> 0 +dqsamq1412 samequantum 7E-3 NaN -> 0 +dqsamq1413 samequantum 7E-3 -7E+3 -> 0 +dqsamq1414 samequantum 7E-3 -7 -> 0 +dqsamq1415 samequantum 7E-3 -7E-3 -> 1 +dqsamq1416 samequantum 7E-3 -0E-3 -> 1 +dqsamq1417 samequantum 7E-3 -0 -> 0 +dqsamq1418 samequantum 7E-3 -0E+3 -> 0 +dqsamq1419 samequantum 7E-3 0E-3 -> 1 +dqsamq1420 samequantum 7E-3 0 -> 0 +dqsamq1421 samequantum 7E-3 0E+3 -> 0 +dqsamq1422 samequantum 7E-3 7E-3 -> 1 +dqsamq1423 samequantum 7E-3 7 -> 0 +dqsamq1424 samequantum 7E-3 7E+3 -> 0 +dqsamq1425 samequantum 7E-3 sNaN -> 0 + +dqsamq1510 samequantum 7 -Inf -> 0 +dqsamq1511 samequantum 7 Inf -> 0 +dqsamq1512 samequantum 7 NaN -> 0 +dqsamq1513 samequantum 7 -7E+3 -> 0 +dqsamq1514 samequantum 7 -7 -> 1 +dqsamq1515 samequantum 7 -7E-3 -> 0 +dqsamq1516 samequantum 7 -0E-3 -> 0 +dqsamq1517 samequantum 7 -0 -> 1 +dqsamq1518 samequantum 7 -0E+3 -> 0 +dqsamq1519 samequantum 7 0E-3 -> 0 +dqsamq1520 samequantum 7 0 -> 1 +dqsamq1521 samequantum 7 0E+3 -> 0 +dqsamq1522 samequantum 7 7E-3 -> 0 +dqsamq1523 samequantum 7 7 -> 1 +dqsamq1524 samequantum 7 7E+3 -> 0 +dqsamq1525 samequantum 7 sNaN -> 0 + +dqsamq1610 samequantum 7E+3 -Inf -> 0 +dqsamq1611 samequantum 7E+3 Inf -> 0 +dqsamq1612 samequantum 7E+3 NaN -> 0 +dqsamq1613 samequantum 7E+3 -7E+3 -> 1 +dqsamq1614 samequantum 7E+3 -7 -> 0 +dqsamq1615 samequantum 7E+3 -7E-3 -> 0 +dqsamq1616 samequantum 7E+3 -0E-3 -> 0 +dqsamq1617 samequantum 7E+3 -0 -> 0 +dqsamq1618 samequantum 7E+3 -0E+3 -> 1 +dqsamq1619 samequantum 7E+3 0E-3 -> 0 +dqsamq1620 samequantum 7E+3 0 -> 0 +dqsamq1621 samequantum 7E+3 0E+3 -> 1 +dqsamq1622 samequantum 7E+3 7E-3 -> 0 +dqsamq1623 samequantum 7E+3 7 -> 0 +dqsamq1624 samequantum 7E+3 7E+3 -> 1 +dqsamq1625 samequantum 7E+3 sNaN -> 0 + +dqsamq1710 samequantum sNaN -Inf -> 0 +dqsamq1711 samequantum sNaN Inf -> 0 +dqsamq1712 samequantum sNaN NaN -> 1 +dqsamq1713 samequantum sNaN -7E+3 -> 0 +dqsamq1714 samequantum sNaN -7 -> 0 +dqsamq1715 samequantum sNaN -7E-3 -> 0 +dqsamq1716 samequantum sNaN -0E-3 -> 0 +dqsamq1717 samequantum sNaN -0 -> 0 +dqsamq1718 samequantum sNaN -0E+3 -> 0 +dqsamq1719 samequantum sNaN 0E-3 -> 0 +dqsamq1720 samequantum sNaN 0 -> 0 +dqsamq1721 samequantum sNaN 0E+3 -> 0 +dqsamq1722 samequantum sNaN 7E-3 -> 0 +dqsamq1723 samequantum sNaN 7 -> 0 +dqsamq1724 samequantum sNaN 7E+3 -> 0 +dqsamq1725 samequantum sNaN sNaN -> 1 +-- noisy NaNs +dqsamq1730 samequantum sNaN3 sNaN3 -> 1 +dqsamq1731 samequantum sNaN3 sNaN4 -> 1 +dqsamq1732 samequantum NaN3 NaN3 -> 1 +dqsamq1733 samequantum NaN3 NaN4 -> 1 +dqsamq1734 samequantum sNaN3 3 -> 0 +dqsamq1735 samequantum NaN3 3 -> 0 +dqsamq1736 samequantum 4 sNaN4 -> 0 +dqsamq1737 samequantum 3 NaN3 -> 0 +dqsamq1738 samequantum Inf sNaN4 -> 0 +dqsamq1739 samequantum -Inf NaN3 -> 0 + Added: python/branches/release25-maint/Lib/test/decimaltestdata/dqScaleB.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/dqScaleB.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,260 @@ +------------------------------------------------------------------------ +-- dqScalebB.decTest -- scale a decQuad by powers of 10 -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +extended: 1 +clamp: 1 +precision: 34 +maxExponent: 6144 +minExponent: -6143 +rounding: half_even + +-- Max |rhs| is 2*(6144+34) = 12356 + +-- Sanity checks +dqscb001 scaleb 7.50 10 -> 7.50E+10 +dqscb002 scaleb 7.50 3 -> 7.50E+3 +dqscb003 scaleb 7.50 2 -> 750 +dqscb004 scaleb 7.50 1 -> 75.0 +dqscb005 scaleb 7.50 0 -> 7.50 +dqscb006 scaleb 7.50 -1 -> 0.750 +dqscb007 scaleb 7.50 -2 -> 0.0750 +dqscb008 scaleb 7.50 -10 -> 7.50E-10 +dqscb009 scaleb -7.50 3 -> -7.50E+3 +dqscb010 scaleb -7.50 2 -> -750 +dqscb011 scaleb -7.50 1 -> -75.0 +dqscb012 scaleb -7.50 0 -> -7.50 +dqscb013 scaleb -7.50 -1 -> -0.750 + +-- Infinities +dqscb014 scaleb Infinity 1 -> Infinity +dqscb015 scaleb -Infinity 2 -> -Infinity +dqscb016 scaleb Infinity -1 -> Infinity +dqscb017 scaleb -Infinity -2 -> -Infinity + +-- Next two are somewhat undefined in 754r; treat as non-integer +dqscb018 scaleb 10 Infinity -> NaN Invalid_operation +dqscb019 scaleb 10 -Infinity -> NaN Invalid_operation + +-- NaNs are undefined in 754r; assume usual processing +-- NaNs, 0 payload +dqscb021 scaleb NaN 1 -> NaN +dqscb022 scaleb -NaN -1 -> -NaN +dqscb023 scaleb sNaN 1 -> NaN Invalid_operation +dqscb024 scaleb -sNaN 1 -> -NaN Invalid_operation +dqscb025 scaleb 4 NaN -> NaN +dqscb026 scaleb -Inf -NaN -> -NaN +dqscb027 scaleb 4 sNaN -> NaN Invalid_operation +dqscb028 scaleb Inf -sNaN -> -NaN Invalid_operation + +-- non-integer RHS +dqscb030 scaleb 1.23 1 -> 12.3 +dqscb031 scaleb 1.23 1.00 -> NaN Invalid_operation +dqscb032 scaleb 1.23 1.1 -> NaN Invalid_operation +dqscb033 scaleb 1.23 1.01 -> NaN Invalid_operation +dqscb034 scaleb 1.23 0.01 -> NaN Invalid_operation +dqscb035 scaleb 1.23 0.11 -> NaN Invalid_operation +dqscb036 scaleb 1.23 0.999999999 -> NaN Invalid_operation +dqscb037 scaleb 1.23 -1 -> 0.123 +dqscb0614 scaleb 1.23 -1.00 -> NaN Invalid_operation +dqscb039 scaleb 1.23 -1.1 -> NaN Invalid_operation +dqscb040 scaleb 1.23 -1.01 -> NaN Invalid_operation +dqscb041 scaleb 1.23 -0.01 -> NaN Invalid_operation +dqscb042 scaleb 1.23 -0.11 -> NaN Invalid_operation +dqscb043 scaleb 1.23 -0.999999999 -> NaN Invalid_operation +dqscb044 scaleb 1.23 0.1 -> NaN Invalid_operation +dqscb045 scaleb 1.23 1E+1 -> NaN Invalid_operation +dqscb046 scaleb 1.23 1.1234E+6 -> NaN Invalid_operation +dqscb047 scaleb 1.23 1.123E+4 -> NaN Invalid_operation + +-- out-of range RHS +dqscb120 scaleb 1.23 12355 -> Infinity Overflow Inexact Rounded +dqscb121 scaleb 1.23 12356 -> Infinity Overflow Inexact Rounded +dqscb122 scaleb 1.23 12357 -> NaN Invalid_operation +dqscb123 scaleb 1.23 12358 -> NaN Invalid_operation +dqscb124 scaleb 1.23 -12355 -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqscb125 scaleb 1.23 -12356 -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqscb126 scaleb 1.23 -12357 -> NaN Invalid_operation +dqscb127 scaleb 1.23 -12358 -> NaN Invalid_operation + +-- NaNs, non-0 payload +-- propagating NaNs +dqscb861 scaleb NaN01 -Inf -> NaN1 +dqscb862 scaleb -NaN02 -1000 -> -NaN2 +dqscb863 scaleb NaN03 1000 -> NaN3 +dqscb864 scaleb NaN04 Inf -> NaN4 +dqscb865 scaleb NaN05 NaN61 -> NaN5 +dqscb866 scaleb -Inf -NaN71 -> -NaN71 +dqscb867 scaleb -1000 NaN81 -> NaN81 +dqscb868 scaleb 1000 NaN91 -> NaN91 +dqscb869 scaleb Inf NaN101 -> NaN101 +dqscb871 scaleb sNaN011 -Inf -> NaN11 Invalid_operation +dqscb872 scaleb sNaN012 -1000 -> NaN12 Invalid_operation +dqscb873 scaleb -sNaN013 1000 -> -NaN13 Invalid_operation +dqscb874 scaleb sNaN014 NaN171 -> NaN14 Invalid_operation +dqscb875 scaleb sNaN015 sNaN181 -> NaN15 Invalid_operation +dqscb876 scaleb NaN016 sNaN191 -> NaN191 Invalid_operation +dqscb877 scaleb -Inf sNaN201 -> NaN201 Invalid_operation +dqscb878 scaleb -1000 sNaN211 -> NaN211 Invalid_operation +dqscb879 scaleb 1000 -sNaN221 -> -NaN221 Invalid_operation +dqscb880 scaleb Inf sNaN231 -> NaN231 Invalid_operation +dqscb881 scaleb NaN025 sNaN241 -> NaN241 Invalid_operation + +-- finites +dqscb051 scaleb 7 -2 -> 0.07 +dqscb052 scaleb -7 -2 -> -0.07 +dqscb053 scaleb 75 -2 -> 0.75 +dqscb054 scaleb -75 -2 -> -0.75 +dqscb055 scaleb 7.50 -2 -> 0.0750 +dqscb056 scaleb -7.50 -2 -> -0.0750 +dqscb057 scaleb 7.500 -2 -> 0.07500 +dqscb058 scaleb -7.500 -2 -> -0.07500 +dqscb061 scaleb 7 -1 -> 0.7 +dqscb062 scaleb -7 -1 -> -0.7 +dqscb063 scaleb 75 -1 -> 7.5 +dqscb064 scaleb -75 -1 -> -7.5 +dqscb065 scaleb 7.50 -1 -> 0.750 +dqscb066 scaleb -7.50 -1 -> -0.750 +dqscb067 scaleb 7.500 -1 -> 0.7500 +dqscb068 scaleb -7.500 -1 -> -0.7500 +dqscb071 scaleb 7 0 -> 7 +dqscb072 scaleb -7 0 -> -7 +dqscb073 scaleb 75 0 -> 75 +dqscb074 scaleb -75 0 -> -75 +dqscb075 scaleb 7.50 0 -> 7.50 +dqscb076 scaleb -7.50 0 -> -7.50 +dqscb077 scaleb 7.500 0 -> 7.500 +dqscb078 scaleb -7.500 0 -> -7.500 +dqscb081 scaleb 7 1 -> 7E+1 +dqscb082 scaleb -7 1 -> -7E+1 +dqscb083 scaleb 75 1 -> 7.5E+2 +dqscb084 scaleb -75 1 -> -7.5E+2 +dqscb085 scaleb 7.50 1 -> 75.0 +dqscb086 scaleb -7.50 1 -> -75.0 +dqscb087 scaleb 7.500 1 -> 75.00 +dqscb088 scaleb -7.500 1 -> -75.00 +dqscb091 scaleb 7 2 -> 7E+2 +dqscb092 scaleb -7 2 -> -7E+2 +dqscb093 scaleb 75 2 -> 7.5E+3 +dqscb094 scaleb -75 2 -> -7.5E+3 +dqscb095 scaleb 7.50 2 -> 750 +dqscb096 scaleb -7.50 2 -> -750 +dqscb097 scaleb 7.500 2 -> 750.0 +dqscb098 scaleb -7.500 2 -> -750.0 + +-- zeros +dqscb111 scaleb 0 1 -> 0E+1 +dqscb112 scaleb -0 2 -> -0E+2 +dqscb113 scaleb 0E+4 3 -> 0E+7 +dqscb114 scaleb -0E+4 4 -> -0E+8 +dqscb115 scaleb 0.0000 5 -> 0E+1 +dqscb116 scaleb -0.0000 6 -> -0E+2 +dqscb117 scaleb 0E-141 7 -> 0E-134 +dqscb118 scaleb -0E-141 8 -> -0E-133 + +-- Nmax, Nmin, Ntiny +dqscb132 scaleb 9.999999999999999999999999999999999E+6144 +6144 -> Infinity Overflow Inexact Rounded +dqscb133 scaleb 9.999999999999999999999999999999999E+6144 +10 -> Infinity Overflow Inexact Rounded +dqscb134 scaleb 9.999999999999999999999999999999999E+6144 +1 -> Infinity Overflow Inexact Rounded +dqscb135 scaleb 9.999999999999999999999999999999999E+6144 0 -> 9.999999999999999999999999999999999E+6144 +dqscb136 scaleb 9.999999999999999999999999999999999E+6144 -1 -> 9.999999999999999999999999999999999E+6143 +dqscb137 scaleb 1E-6143 +1 -> 1E-6142 +dqscb1614 scaleb 1E-6143 -0 -> 1E-6143 +dqscb139 scaleb 1E-6143 -1 -> 1E-6144 Subnormal +dqscb140 scaleb 1.000000000000000000000000000000000E-6143 +1 -> 1.000000000000000000000000000000000E-6142 +dqscb141 scaleb 1.000000000000000000000000000000000E-6143 0 -> 1.000000000000000000000000000000000E-6143 +dqscb142 scaleb 1.000000000000000000000000000000000E-6143 -1 -> 1.00000000000000000000000000000000E-6144 Subnormal Rounded +dqscb143 scaleb 1E-6176 +1 -> 1E-6175 Subnormal +dqscb144 scaleb 1E-6176 -0 -> 1E-6176 Subnormal +dqscb145 scaleb 1E-6176 -1 -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped + +dqscb150 scaleb -1E-6176 +1 -> -1E-6175 Subnormal +dqscb151 scaleb -1E-6176 -0 -> -1E-6176 Subnormal +dqscb152 scaleb -1E-6176 -1 -> -0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqscb153 scaleb -1.000000000000000000000000000000000E-6143 +1 -> -1.000000000000000000000000000000000E-6142 +dqscb154 scaleb -1.000000000000000000000000000000000E-6143 +0 -> -1.000000000000000000000000000000000E-6143 +dqscb155 scaleb -1.000000000000000000000000000000000E-6143 -1 -> -1.00000000000000000000000000000000E-6144 Subnormal Rounded +dqscb156 scaleb -1E-6143 +1 -> -1E-6142 +dqscb157 scaleb -1E-6143 -0 -> -1E-6143 +dqscb158 scaleb -1E-6143 -1 -> -1E-6144 Subnormal +dqscb159 scaleb -9.999999999999999999999999999999999E+6144 +1 -> -Infinity Overflow Inexact Rounded +dqscb160 scaleb -9.999999999999999999999999999999999E+6144 +0 -> -9.999999999999999999999999999999999E+6144 +dqscb161 scaleb -9.999999999999999999999999999999999E+6144 -1 -> -9.999999999999999999999999999999999E+6143 +dqscb162 scaleb -9E+6144 +1 -> -Infinity Overflow Inexact Rounded +dqscb163 scaleb -1E+6144 +1 -> -Infinity Overflow Inexact Rounded + +-- some Origami +-- (these check that overflow is being done correctly) +dqscb171 scaleb 1000E+6109 +1 -> 1.000E+6113 +dqscb172 scaleb 1000E+6110 +1 -> 1.000E+6114 +dqscb173 scaleb 1000E+6111 +1 -> 1.0000E+6115 Clamped +dqscb174 scaleb 1000E+6112 +1 -> 1.00000E+6116 Clamped +dqscb175 scaleb 1000E+6113 +1 -> 1.000000E+6117 Clamped +dqscb176 scaleb 1000E+6114 +1 -> 1.0000000E+6118 Clamped +dqscb177 scaleb 1000E+6131 +1 -> 1.000000000000000000000000E+6135 Clamped +dqscb178 scaleb 1000E+6132 +1 -> 1.0000000000000000000000000E+6136 Clamped +dqscb179 scaleb 1000E+6133 +1 -> 1.00000000000000000000000000E+6137 Clamped +dqscb180 scaleb 1000E+6134 +1 -> 1.000000000000000000000000000E+6138 Clamped +dqscb181 scaleb 1000E+6135 +1 -> 1.0000000000000000000000000000E+6139 Clamped +dqscb182 scaleb 1000E+6136 +1 -> 1.00000000000000000000000000000E+6140 Clamped +dqscb183 scaleb 1000E+6137 +1 -> 1.000000000000000000000000000000E+6141 Clamped +dqscb184 scaleb 1000E+6138 +1 -> 1.0000000000000000000000000000000E+6142 Clamped +dqscb185 scaleb 1000E+6139 +1 -> 1.00000000000000000000000000000000E+6143 Clamped +dqscb186 scaleb 1000E+6140 +1 -> 1.000000000000000000000000000000000E+6144 Clamped +dqscb187 scaleb 1000E+6141 +1 -> Infinity Overflow Inexact Rounded + +-- and a few more subnormal truncations +-- (these check that underflow is being done correctly) +dqscb221 scaleb 1.000000000000000000000000000000000E-6143 0 -> 1.000000000000000000000000000000000E-6143 +dqscb222 scaleb 1.000000000000000000000000000000000E-6143 -1 -> 1.00000000000000000000000000000000E-6144 Subnormal Rounded +dqscb223 scaleb 1.000000000000000000000000000000000E-6143 -2 -> 1.0000000000000000000000000000000E-6145 Subnormal Rounded +dqscb224 scaleb 1.000000000000000000000000000000000E-6143 -3 -> 1.000000000000000000000000000000E-6146 Subnormal Rounded +dqscb225 scaleb 1.000000000000000000000000000000000E-6143 -4 -> 1.00000000000000000000000000000E-6147 Subnormal Rounded +dqscb226 scaleb 1.000000000000000000000000000000000E-6143 -5 -> 1.0000000000000000000000000000E-6148 Subnormal Rounded +dqscb227 scaleb 1.000000000000000000000000000000000E-6143 -6 -> 1.000000000000000000000000000E-6149 Subnormal Rounded +dqscb228 scaleb 1.000000000000000000000000000000000E-6143 -7 -> 1.00000000000000000000000000E-6150 Subnormal Rounded +dqscb229 scaleb 1.000000000000000000000000000000000E-6143 -8 -> 1.0000000000000000000000000E-6151 Subnormal Rounded +dqscb230 scaleb 1.000000000000000000000000000000000E-6143 -9 -> 1.000000000000000000000000E-6152 Subnormal Rounded +dqscb231 scaleb 1.000000000000000000000000000000000E-6143 -10 -> 1.00000000000000000000000E-6153 Subnormal Rounded +dqscb232 scaleb 1.000000000000000000000000000000000E-6143 -11 -> 1.0000000000000000000000E-6154 Subnormal Rounded +dqscb233 scaleb 1.000000000000000000000000000000000E-6143 -12 -> 1.000000000000000000000E-6155 Subnormal Rounded +dqscb234 scaleb 1.000000000000000000000000000000000E-6143 -13 -> 1.00000000000000000000E-6156 Subnormal Rounded +dqscb235 scaleb 1.000000000000000000000000000000000E-6143 -14 -> 1.0000000000000000000E-6157 Subnormal Rounded +dqscb236 scaleb 1.000000000000000000000000000000000E-6143 -15 -> 1.000000000000000000E-6158 Subnormal Rounded +dqscb237 scaleb 1.000000000000000000000000000000000E-6143 -16 -> 1.00000000000000000E-6159 Subnormal Rounded +dqscb238 scaleb 1.000000000000000000000000000000000E-6143 -17 -> 1.0000000000000000E-6160 Subnormal Rounded +dqscb239 scaleb 1.000000000000000000000000000000000E-6143 -18 -> 1.000000000000000E-6161 Subnormal Rounded +dqscb202 scaleb 1.000000000000000000000000000000000E-6143 -19 -> 1.00000000000000E-6162 Subnormal Rounded +dqscb203 scaleb 1.000000000000000000000000000000000E-6143 -20 -> 1.0000000000000E-6163 Subnormal Rounded +dqscb204 scaleb 1.000000000000000000000000000000000E-6143 -21 -> 1.000000000000E-6164 Subnormal Rounded +dqscb205 scaleb 1.000000000000000000000000000000000E-6143 -22 -> 1.00000000000E-6165 Subnormal Rounded +dqscb206 scaleb 1.000000000000000000000000000000000E-6143 -23 -> 1.0000000000E-6166 Subnormal Rounded +dqscb207 scaleb 1.000000000000000000000000000000000E-6143 -24 -> 1.000000000E-6167 Subnormal Rounded +dqscb208 scaleb 1.000000000000000000000000000000000E-6143 -25 -> 1.00000000E-6168 Subnormal Rounded +dqscb209 scaleb 1.000000000000000000000000000000000E-6143 -26 -> 1.0000000E-6169 Subnormal Rounded +dqscb210 scaleb 1.000000000000000000000000000000000E-6143 -27 -> 1.000000E-6170 Subnormal Rounded +dqscb211 scaleb 1.000000000000000000000000000000000E-6143 -28 -> 1.00000E-6171 Subnormal Rounded +dqscb212 scaleb 1.000000000000000000000000000000000E-6143 -29 -> 1.0000E-6172 Subnormal Rounded +dqscb213 scaleb 1.000000000000000000000000000000000E-6143 -30 -> 1.000E-6173 Subnormal Rounded +dqscb214 scaleb 1.000000000000000000000000000000000E-6143 -31 -> 1.00E-6174 Subnormal Rounded +dqscb215 scaleb 1.000000000000000000000000000000000E-6143 -32 -> 1.0E-6175 Subnormal Rounded +dqscb216 scaleb 1.000000000000000000000000000000000E-6143 -33 -> 1E-6176 Subnormal Rounded +dqscb217 scaleb 1.000000000000000000000000000000000E-6143 -34 -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped +dqscb218 scaleb 1.000000000000000000000000000000000E-6143 -35 -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped Added: python/branches/release25-maint/Lib/test/decimaltestdata/dqShift.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/dqShift.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,298 @@ +------------------------------------------------------------------------ +-- dqShift.decTest -- shift decQuad coefficient left or right -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +extended: 1 +clamp: 1 +precision: 34 +maxExponent: 6144 +minExponent: -6143 +rounding: half_even + +-- Sanity check +dqshi001 shift 0 0 -> 0 +dqshi002 shift 0 2 -> 0 +dqshi003 shift 1 2 -> 100 +dqshi004 shift 1 33 -> 1000000000000000000000000000000000 +dqshi005 shift 1 34 -> 0 +dqshi006 shift 1 -1 -> 0 +dqshi007 shift 0 -2 -> 0 +dqshi008 shift 1234567890123456789012345678901234 -1 -> 123456789012345678901234567890123 +dqshi009 shift 1234567890123456789012345678901234 -33 -> 1 +dqshi010 shift 1234567890123456789012345678901234 -34 -> 0 +dqshi011 shift 9934567890123456789012345678901234 -33 -> 9 +dqshi012 shift 9934567890123456789012345678901234 -34 -> 0 + +-- rhs must be an integer +dqshi015 shift 1 1.5 -> NaN Invalid_operation +dqshi016 shift 1 1.0 -> NaN Invalid_operation +dqshi017 shift 1 0.1 -> NaN Invalid_operation +dqshi018 shift 1 0.0 -> NaN Invalid_operation +dqshi019 shift 1 1E+1 -> NaN Invalid_operation +dqshi020 shift 1 1E+99 -> NaN Invalid_operation +dqshi021 shift 1 Inf -> NaN Invalid_operation +dqshi022 shift 1 -Inf -> NaN Invalid_operation +-- and |rhs| <= precision +dqshi025 shift 1 -1000 -> NaN Invalid_operation +dqshi026 shift 1 -35 -> NaN Invalid_operation +dqshi027 shift 1 35 -> NaN Invalid_operation +dqshi028 shift 1 1000 -> NaN Invalid_operation + +-- full shifting pattern +dqshi030 shift 1234567890123456789012345678901234 -34 -> 0 +dqshi031 shift 1234567890123456789012345678901234 -33 -> 1 +dqshi032 shift 1234567890123456789012345678901234 -32 -> 12 +dqshi033 shift 1234567890123456789012345678901234 -31 -> 123 +dqshi034 shift 1234567890123456789012345678901234 -30 -> 1234 +dqshi035 shift 1234567890123456789012345678901234 -29 -> 12345 +dqshi036 shift 1234567890123456789012345678901234 -28 -> 123456 +dqshi037 shift 1234567890123456789012345678901234 -27 -> 1234567 +dqshi038 shift 1234567890123456789012345678901234 -26 -> 12345678 +dqshi039 shift 1234567890123456789012345678901234 -25 -> 123456789 +dqshi040 shift 1234567890123456789012345678901234 -24 -> 1234567890 +dqshi041 shift 1234567890123456789012345678901234 -23 -> 12345678901 +dqshi042 shift 1234567890123456789012345678901234 -22 -> 123456789012 +dqshi043 shift 1234567890123456789012345678901234 -21 -> 1234567890123 +dqshi044 shift 1234567890123456789012345678901234 -20 -> 12345678901234 +dqshi045 shift 1234567890123456789012345678901234 -19 -> 123456789012345 +dqshi047 shift 1234567890123456789012345678901234 -18 -> 1234567890123456 +dqshi048 shift 1234567890123456789012345678901234 -17 -> 12345678901234567 +dqshi049 shift 1234567890123456789012345678901234 -16 -> 123456789012345678 +dqshi050 shift 1234567890123456789012345678901234 -15 -> 1234567890123456789 +dqshi051 shift 1234567890123456789012345678901234 -14 -> 12345678901234567890 +dqshi052 shift 1234567890123456789012345678901234 -13 -> 123456789012345678901 +dqshi053 shift 1234567890123456789012345678901234 -12 -> 1234567890123456789012 +dqshi054 shift 1234567890123456789012345678901234 -11 -> 12345678901234567890123 +dqshi055 shift 1234567890123456789012345678901234 -10 -> 123456789012345678901234 +dqshi056 shift 1234567890123456789012345678901234 -9 -> 1234567890123456789012345 +dqshi057 shift 1234567890123456789012345678901234 -8 -> 12345678901234567890123456 +dqshi058 shift 1234567890123456789012345678901234 -7 -> 123456789012345678901234567 +dqshi059 shift 1234567890123456789012345678901234 -6 -> 1234567890123456789012345678 +dqshi060 shift 1234567890123456789012345678901234 -5 -> 12345678901234567890123456789 +dqshi061 shift 1234567890123456789012345678901234 -4 -> 123456789012345678901234567890 +dqshi062 shift 1234567890123456789012345678901234 -3 -> 1234567890123456789012345678901 +dqshi063 shift 1234567890123456789012345678901234 -2 -> 12345678901234567890123456789012 +dqshi064 shift 1234567890123456789012345678901234 -1 -> 123456789012345678901234567890123 +dqshi065 shift 1234567890123456789012345678901234 -0 -> 1234567890123456789012345678901234 + +dqshi066 shift 1234567890123456789012345678901234 +0 -> 1234567890123456789012345678901234 +dqshi067 shift 1234567890123456789012345678901234 +1 -> 2345678901234567890123456789012340 +dqshi068 shift 1234567890123456789012345678901234 +2 -> 3456789012345678901234567890123400 +dqshi069 shift 1234567890123456789012345678901234 +3 -> 4567890123456789012345678901234000 +dqshi070 shift 1234567890123456789012345678901234 +4 -> 5678901234567890123456789012340000 +dqshi071 shift 1234567890123456789012345678901234 +5 -> 6789012345678901234567890123400000 +dqshi072 shift 1234567890123456789012345678901234 +6 -> 7890123456789012345678901234000000 +dqshi073 shift 1234567890123456789012345678901234 +7 -> 8901234567890123456789012340000000 +dqshi074 shift 1234567890123456789012345678901234 +8 -> 9012345678901234567890123400000000 +dqshi075 shift 1234567890123456789012345678901234 +9 -> 123456789012345678901234000000000 +dqshi076 shift 1234567890123456789012345678901234 +10 -> 1234567890123456789012340000000000 +dqshi077 shift 1234567890123456789012345678901234 +11 -> 2345678901234567890123400000000000 +dqshi078 shift 1234567890123456789012345678901234 +12 -> 3456789012345678901234000000000000 +dqshi079 shift 1234567890123456789012345678901234 +13 -> 4567890123456789012340000000000000 +dqshi080 shift 1234567890123456789012345678901234 +14 -> 5678901234567890123400000000000000 +dqshi081 shift 1234567890123456789012345678901234 +15 -> 6789012345678901234000000000000000 +dqshi082 shift 1234567890123456789012345678901234 +16 -> 7890123456789012340000000000000000 +dqshi083 shift 1234567890123456789012345678901234 +17 -> 8901234567890123400000000000000000 +dqshi084 shift 1234567890123456789012345678901234 +18 -> 9012345678901234000000000000000000 +dqshi085 shift 1234567890123456789012345678901234 +19 -> 123456789012340000000000000000000 +dqshi086 shift 1234567890123456789012345678901234 +20 -> 1234567890123400000000000000000000 +dqshi087 shift 1234567890123456789012345678901234 +21 -> 2345678901234000000000000000000000 +dqshi088 shift 1234567890123456789012345678901234 +22 -> 3456789012340000000000000000000000 +dqshi089 shift 1234567890123456789012345678901234 +23 -> 4567890123400000000000000000000000 +dqshi090 shift 1234567890123456789012345678901234 +24 -> 5678901234000000000000000000000000 +dqshi091 shift 1234567890123456789012345678901234 +25 -> 6789012340000000000000000000000000 +dqshi092 shift 1234567890123456789012345678901234 +26 -> 7890123400000000000000000000000000 +dqshi093 shift 1234567890123456789012345678901234 +27 -> 8901234000000000000000000000000000 +dqshi094 shift 1234567890123456789012345678901234 +28 -> 9012340000000000000000000000000000 +dqshi095 shift 1234567890123456789012345678901234 +29 -> 123400000000000000000000000000000 +dqshi096 shift 1234567890123456789012345678901234 +30 -> 1234000000000000000000000000000000 +dqshi097 shift 1234567890123456789012345678901234 +31 -> 2340000000000000000000000000000000 +dqshi098 shift 1234567890123456789012345678901234 +32 -> 3400000000000000000000000000000000 +dqshi099 shift 1234567890123456789012345678901234 +33 -> 4000000000000000000000000000000000 +dqshi100 shift 1234567890123456789012345678901234 +34 -> 0 + +-- zeros +dqshi270 shift 0E-10 +29 -> 0E-10 +dqshi271 shift 0E-10 -29 -> 0E-10 +dqshi272 shift 0.000 +29 -> 0.000 +dqshi273 shift 0.000 -29 -> 0.000 +dqshi274 shift 0E+10 +29 -> 0E+10 +dqshi275 shift 0E+10 -29 -> 0E+10 +dqshi276 shift -0E-10 +29 -> -0E-10 +dqshi277 shift -0E-10 -29 -> -0E-10 +dqshi278 shift -0.000 +29 -> -0.000 +dqshi279 shift -0.000 -29 -> -0.000 +dqshi280 shift -0E+10 +29 -> -0E+10 +dqshi281 shift -0E+10 -29 -> -0E+10 + +-- Nmax, Nmin, Ntiny +dqshi141 shift 9.999999999999999999999999999999999E+6144 -1 -> 9.99999999999999999999999999999999E+6143 +dqshi142 shift 9.999999999999999999999999999999999E+6144 -33 -> 9E+6111 +dqshi143 shift 9.999999999999999999999999999999999E+6144 1 -> 9.999999999999999999999999999999990E+6144 +dqshi144 shift 9.999999999999999999999999999999999E+6144 33 -> 9.000000000000000000000000000000000E+6144 +dqshi145 shift 1E-6143 -1 -> 0E-6143 +dqshi146 shift 1E-6143 -33 -> 0E-6143 +dqshi147 shift 1E-6143 1 -> 1.0E-6142 +dqshi148 shift 1E-6143 33 -> 1.000000000000000000000000000000000E-6110 +dqshi151 shift 1.000000000000000000000000000000000E-6143 -1 -> 1.00000000000000000000000000000000E-6144 +dqshi152 shift 1.000000000000000000000000000000000E-6143 -33 -> 1E-6176 +dqshi153 shift 1.000000000000000000000000000000000E-6143 1 -> 0E-6176 +dqshi154 shift 1.000000000000000000000000000000000E-6143 33 -> 0E-6176 +dqshi155 shift 9.000000000000000000000000000000000E-6143 -1 -> 9.00000000000000000000000000000000E-6144 +dqshi156 shift 9.000000000000000000000000000000000E-6143 -33 -> 9E-6176 +dqshi157 shift 9.000000000000000000000000000000000E-6143 1 -> 0E-6176 +dqshi158 shift 9.000000000000000000000000000000000E-6143 33 -> 0E-6176 +dqshi160 shift 1E-6176 -1 -> 0E-6176 +dqshi161 shift 1E-6176 -33 -> 0E-6176 +dqshi162 shift 1E-6176 1 -> 1.0E-6175 +dqshi163 shift 1E-6176 33 -> 1.000000000000000000000000000000000E-6143 +-- negatives +dqshi171 shift -9.999999999999999999999999999999999E+6144 -1 -> -9.99999999999999999999999999999999E+6143 +dqshi172 shift -9.999999999999999999999999999999999E+6144 -33 -> -9E+6111 +dqshi173 shift -9.999999999999999999999999999999999E+6144 1 -> -9.999999999999999999999999999999990E+6144 +dqshi174 shift -9.999999999999999999999999999999999E+6144 33 -> -9.000000000000000000000000000000000E+6144 +dqshi175 shift -1E-6143 -1 -> -0E-6143 +dqshi176 shift -1E-6143 -33 -> -0E-6143 +dqshi177 shift -1E-6143 1 -> -1.0E-6142 +dqshi178 shift -1E-6143 33 -> -1.000000000000000000000000000000000E-6110 +dqshi181 shift -1.000000000000000000000000000000000E-6143 -1 -> -1.00000000000000000000000000000000E-6144 +dqshi182 shift -1.000000000000000000000000000000000E-6143 -33 -> -1E-6176 +dqshi183 shift -1.000000000000000000000000000000000E-6143 1 -> -0E-6176 +dqshi184 shift -1.000000000000000000000000000000000E-6143 33 -> -0E-6176 +dqshi185 shift -9.000000000000000000000000000000000E-6143 -1 -> -9.00000000000000000000000000000000E-6144 +dqshi186 shift -9.000000000000000000000000000000000E-6143 -33 -> -9E-6176 +dqshi187 shift -9.000000000000000000000000000000000E-6143 1 -> -0E-6176 +dqshi188 shift -9.000000000000000000000000000000000E-6143 33 -> -0E-6176 +dqshi190 shift -1E-6176 -1 -> -0E-6176 +dqshi191 shift -1E-6176 -33 -> -0E-6176 +dqshi192 shift -1E-6176 1 -> -1.0E-6175 +dqshi193 shift -1E-6176 33 -> -1.000000000000000000000000000000000E-6143 + +-- more negatives (of sanities) +dqshi201 shift -0 0 -> -0 +dqshi202 shift -0 2 -> -0 +dqshi203 shift -1 2 -> -100 +dqshi204 shift -1 33 -> -1000000000000000000000000000000000 +dqshi205 shift -1 34 -> -0 +dqshi206 shift -1 -1 -> -0 +dqshi207 shift -0 -2 -> -0 +dqshi208 shift -1234567890123456789012345678901234 -1 -> -123456789012345678901234567890123 +dqshi209 shift -1234567890123456789012345678901234 -33 -> -1 +dqshi210 shift -1234567890123456789012345678901234 -34 -> -0 +dqshi211 shift -9934567890123456789012345678901234 -33 -> -9 +dqshi212 shift -9934567890123456789012345678901234 -34 -> -0 + + +-- Specials; NaNs are handled as usual +dqshi781 shift -Inf -8 -> -Infinity +dqshi782 shift -Inf -1 -> -Infinity +dqshi783 shift -Inf -0 -> -Infinity +dqshi784 shift -Inf 0 -> -Infinity +dqshi785 shift -Inf 1 -> -Infinity +dqshi786 shift -Inf 8 -> -Infinity +dqshi787 shift -1000 -Inf -> NaN Invalid_operation +dqshi788 shift -Inf -Inf -> NaN Invalid_operation +dqshi789 shift -1 -Inf -> NaN Invalid_operation +dqshi790 shift -0 -Inf -> NaN Invalid_operation +dqshi791 shift 0 -Inf -> NaN Invalid_operation +dqshi792 shift 1 -Inf -> NaN Invalid_operation +dqshi793 shift 1000 -Inf -> NaN Invalid_operation +dqshi794 shift Inf -Inf -> NaN Invalid_operation + +dqshi800 shift Inf -Inf -> NaN Invalid_operation +dqshi801 shift Inf -8 -> Infinity +dqshi802 shift Inf -1 -> Infinity +dqshi803 shift Inf -0 -> Infinity +dqshi804 shift Inf 0 -> Infinity +dqshi805 shift Inf 1 -> Infinity +dqshi806 shift Inf 8 -> Infinity +dqshi807 shift Inf Inf -> NaN Invalid_operation +dqshi808 shift -1000 Inf -> NaN Invalid_operation +dqshi809 shift -Inf Inf -> NaN Invalid_operation +dqshi810 shift -1 Inf -> NaN Invalid_operation +dqshi811 shift -0 Inf -> NaN Invalid_operation +dqshi812 shift 0 Inf -> NaN Invalid_operation +dqshi813 shift 1 Inf -> NaN Invalid_operation +dqshi814 shift 1000 Inf -> NaN Invalid_operation +dqshi815 shift Inf Inf -> NaN Invalid_operation + +dqshi821 shift NaN -Inf -> NaN +dqshi822 shift NaN -1000 -> NaN +dqshi823 shift NaN -1 -> NaN +dqshi824 shift NaN -0 -> NaN +dqshi825 shift NaN 0 -> NaN +dqshi826 shift NaN 1 -> NaN +dqshi827 shift NaN 1000 -> NaN +dqshi828 shift NaN Inf -> NaN +dqshi829 shift NaN NaN -> NaN +dqshi830 shift -Inf NaN -> NaN +dqshi831 shift -1000 NaN -> NaN +dqshi832 shift -1 NaN -> NaN +dqshi833 shift -0 NaN -> NaN +dqshi834 shift 0 NaN -> NaN +dqshi835 shift 1 NaN -> NaN +dqshi836 shift 1000 NaN -> NaN +dqshi837 shift Inf NaN -> NaN + +dqshi841 shift sNaN -Inf -> NaN Invalid_operation +dqshi842 shift sNaN -1000 -> NaN Invalid_operation +dqshi843 shift sNaN -1 -> NaN Invalid_operation +dqshi844 shift sNaN -0 -> NaN Invalid_operation +dqshi845 shift sNaN 0 -> NaN Invalid_operation +dqshi846 shift sNaN 1 -> NaN Invalid_operation +dqshi847 shift sNaN 1000 -> NaN Invalid_operation +dqshi848 shift sNaN NaN -> NaN Invalid_operation +dqshi849 shift sNaN sNaN -> NaN Invalid_operation +dqshi850 shift NaN sNaN -> NaN Invalid_operation +dqshi851 shift -Inf sNaN -> NaN Invalid_operation +dqshi852 shift -1000 sNaN -> NaN Invalid_operation +dqshi853 shift -1 sNaN -> NaN Invalid_operation +dqshi854 shift -0 sNaN -> NaN Invalid_operation +dqshi855 shift 0 sNaN -> NaN Invalid_operation +dqshi856 shift 1 sNaN -> NaN Invalid_operation +dqshi857 shift 1000 sNaN -> NaN Invalid_operation +dqshi858 shift Inf sNaN -> NaN Invalid_operation +dqshi859 shift NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +dqshi861 shift NaN1 -Inf -> NaN1 +dqshi862 shift +NaN2 -1000 -> NaN2 +dqshi863 shift NaN3 1000 -> NaN3 +dqshi864 shift NaN4 Inf -> NaN4 +dqshi865 shift NaN5 +NaN6 -> NaN5 +dqshi866 shift -Inf NaN7 -> NaN7 +dqshi867 shift -1000 NaN8 -> NaN8 +dqshi868 shift 1000 NaN9 -> NaN9 +dqshi869 shift Inf +NaN10 -> NaN10 +dqshi871 shift sNaN11 -Inf -> NaN11 Invalid_operation +dqshi872 shift sNaN12 -1000 -> NaN12 Invalid_operation +dqshi873 shift sNaN13 1000 -> NaN13 Invalid_operation +dqshi874 shift sNaN14 NaN17 -> NaN14 Invalid_operation +dqshi875 shift sNaN15 sNaN18 -> NaN15 Invalid_operation +dqshi876 shift NaN16 sNaN19 -> NaN19 Invalid_operation +dqshi877 shift -Inf +sNaN20 -> NaN20 Invalid_operation +dqshi878 shift -1000 sNaN21 -> NaN21 Invalid_operation +dqshi879 shift 1000 sNaN22 -> NaN22 Invalid_operation +dqshi880 shift Inf sNaN23 -> NaN23 Invalid_operation +dqshi881 shift +NaN25 +sNaN24 -> NaN24 Invalid_operation +dqshi882 shift -NaN26 NaN28 -> -NaN26 +dqshi883 shift -sNaN27 sNaN29 -> -NaN27 Invalid_operation +dqshi884 shift 1000 -NaN30 -> -NaN30 +dqshi885 shift 1000 -sNaN31 -> -NaN31 Invalid_operation Added: python/branches/release25-maint/Lib/test/decimaltestdata/dqSubtract.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/dqSubtract.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,635 @@ +------------------------------------------------------------------------ +-- dqSubtract.decTest -- decQuad subtraction -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- This set of tests are for decQuads only; all arguments are +-- representable in a decQuad +extended: 1 +clamp: 1 +precision: 34 +maxExponent: 6144 +minExponent: -6143 +rounding: half_even + +-- [first group are 'quick confidence check'] +dqsub001 subtract 0 0 -> '0' +dqsub002 subtract 1 1 -> '0' +dqsub003 subtract 1 2 -> '-1' +dqsub004 subtract 2 1 -> '1' +dqsub005 subtract 2 2 -> '0' +dqsub006 subtract 3 2 -> '1' +dqsub007 subtract 2 3 -> '-1' + +dqsub011 subtract -0 0 -> '-0' +dqsub012 subtract -1 1 -> '-2' +dqsub013 subtract -1 2 -> '-3' +dqsub014 subtract -2 1 -> '-3' +dqsub015 subtract -2 2 -> '-4' +dqsub016 subtract -3 2 -> '-5' +dqsub017 subtract -2 3 -> '-5' + +dqsub021 subtract 0 -0 -> '0' +dqsub022 subtract 1 -1 -> '2' +dqsub023 subtract 1 -2 -> '3' +dqsub024 subtract 2 -1 -> '3' +dqsub025 subtract 2 -2 -> '4' +dqsub026 subtract 3 -2 -> '5' +dqsub027 subtract 2 -3 -> '5' + +dqsub030 subtract 11 1 -> 10 +dqsub031 subtract 10 1 -> 9 +dqsub032 subtract 9 1 -> 8 +dqsub033 subtract 1 1 -> 0 +dqsub034 subtract 0 1 -> -1 +dqsub035 subtract -1 1 -> -2 +dqsub036 subtract -9 1 -> -10 +dqsub037 subtract -10 1 -> -11 +dqsub038 subtract -11 1 -> -12 + +dqsub040 subtract '5.75' '3.3' -> '2.45' +dqsub041 subtract '5' '-3' -> '8' +dqsub042 subtract '-5' '-3' -> '-2' +dqsub043 subtract '-7' '2.5' -> '-9.5' +dqsub044 subtract '0.7' '0.3' -> '0.4' +dqsub045 subtract '1.3' '0.3' -> '1.0' +dqsub046 subtract '1.25' '1.25' -> '0.00' + +dqsub050 subtract '1.23456789' '1.00000000' -> '0.23456789' +dqsub051 subtract '1.23456789' '1.00000089' -> '0.23456700' + +dqsub060 subtract '70' '10000e+34' -> '-1.000000000000000000000000000000000E+38' Inexact Rounded +dqsub061 subtract '700' '10000e+34' -> '-1.000000000000000000000000000000000E+38' Inexact Rounded +dqsub062 subtract '7000' '10000e+34' -> '-9.999999999999999999999999999999999E+37' Inexact Rounded +dqsub063 subtract '70000' '10000e+34' -> '-9.999999999999999999999999999999993E+37' Rounded +dqsub064 subtract '700000' '10000e+34' -> '-9.999999999999999999999999999999930E+37' Rounded + -- symmetry: +dqsub065 subtract '10000e+34' '70' -> '1.000000000000000000000000000000000E+38' Inexact Rounded +dqsub066 subtract '10000e+34' '700' -> '1.000000000000000000000000000000000E+38' Inexact Rounded +dqsub067 subtract '10000e+34' '7000' -> '9.999999999999999999999999999999999E+37' Inexact Rounded +dqsub068 subtract '10000e+34' '70000' -> '9.999999999999999999999999999999993E+37' Rounded +dqsub069 subtract '10000e+34' '700000' -> '9.999999999999999999999999999999930E+37' Rounded + + -- some of the next group are really constructor tests +dqsub090 subtract '00.0' '0.0' -> '0.0' +dqsub091 subtract '00.0' '0.00' -> '0.00' +dqsub092 subtract '0.00' '00.0' -> '0.00' +dqsub093 subtract '00.0' '0.00' -> '0.00' +dqsub094 subtract '0.00' '00.0' -> '0.00' +dqsub095 subtract '3' '.3' -> '2.7' +dqsub096 subtract '3.' '.3' -> '2.7' +dqsub097 subtract '3.0' '.3' -> '2.7' +dqsub098 subtract '3.00' '.3' -> '2.70' +dqsub099 subtract '3' '3' -> '0' +dqsub100 subtract '3' '+3' -> '0' +dqsub101 subtract '3' '-3' -> '6' +dqsub102 subtract '3' '0.3' -> '2.7' +dqsub103 subtract '3.' '0.3' -> '2.7' +dqsub104 subtract '3.0' '0.3' -> '2.7' +dqsub105 subtract '3.00' '0.3' -> '2.70' +dqsub106 subtract '3' '3.0' -> '0.0' +dqsub107 subtract '3' '+3.0' -> '0.0' +dqsub108 subtract '3' '-3.0' -> '6.0' + +-- the above all from add; massaged and extended. Now some new ones... +-- [particularly important for comparisons] +-- NB: -xE-8 below were non-exponents pre-ANSI X3-274, and -1E-7 or 0E-7 +-- with input rounding. +dqsub120 subtract '10.23456784' '10.23456789' -> '-5E-8' +dqsub121 subtract '10.23456785' '10.23456789' -> '-4E-8' +dqsub122 subtract '10.23456786' '10.23456789' -> '-3E-8' +dqsub123 subtract '10.23456787' '10.23456789' -> '-2E-8' +dqsub124 subtract '10.23456788' '10.23456789' -> '-1E-8' +dqsub125 subtract '10.23456789' '10.23456789' -> '0E-8' +dqsub126 subtract '10.23456790' '10.23456789' -> '1E-8' +dqsub127 subtract '10.23456791' '10.23456789' -> '2E-8' +dqsub128 subtract '10.23456792' '10.23456789' -> '3E-8' +dqsub129 subtract '10.23456793' '10.23456789' -> '4E-8' +dqsub130 subtract '10.23456794' '10.23456789' -> '5E-8' +dqsub131 subtract '10.23456781' '10.23456786' -> '-5E-8' +dqsub132 subtract '10.23456782' '10.23456786' -> '-4E-8' +dqsub133 subtract '10.23456783' '10.23456786' -> '-3E-8' +dqsub134 subtract '10.23456784' '10.23456786' -> '-2E-8' +dqsub135 subtract '10.23456785' '10.23456786' -> '-1E-8' +dqsub136 subtract '10.23456786' '10.23456786' -> '0E-8' +dqsub137 subtract '10.23456787' '10.23456786' -> '1E-8' +dqsub138 subtract '10.23456788' '10.23456786' -> '2E-8' +dqsub139 subtract '10.23456789' '10.23456786' -> '3E-8' +dqsub140 subtract '10.23456790' '10.23456786' -> '4E-8' +dqsub141 subtract '10.23456791' '10.23456786' -> '5E-8' +dqsub142 subtract '1' '0.999999999' -> '1E-9' +dqsub143 subtract '0.999999999' '1' -> '-1E-9' +dqsub144 subtract '-10.23456780' '-10.23456786' -> '6E-8' +dqsub145 subtract '-10.23456790' '-10.23456786' -> '-4E-8' +dqsub146 subtract '-10.23456791' '-10.23456786' -> '-5E-8' + +-- additional scaled arithmetic tests [0.97 problem] +dqsub160 subtract '0' '.1' -> '-0.1' +dqsub161 subtract '00' '.97983' -> '-0.97983' +dqsub162 subtract '0' '.9' -> '-0.9' +dqsub163 subtract '0' '0.102' -> '-0.102' +dqsub164 subtract '0' '.4' -> '-0.4' +dqsub165 subtract '0' '.307' -> '-0.307' +dqsub166 subtract '0' '.43822' -> '-0.43822' +dqsub167 subtract '0' '.911' -> '-0.911' +dqsub168 subtract '.0' '.02' -> '-0.02' +dqsub169 subtract '00' '.392' -> '-0.392' +dqsub170 subtract '0' '.26' -> '-0.26' +dqsub171 subtract '0' '0.51' -> '-0.51' +dqsub172 subtract '0' '.2234' -> '-0.2234' +dqsub173 subtract '0' '.2' -> '-0.2' +dqsub174 subtract '.0' '.0008' -> '-0.0008' +-- 0. on left +dqsub180 subtract '0.0' '-.1' -> '0.1' +dqsub181 subtract '0.00' '-.97983' -> '0.97983' +dqsub182 subtract '0.0' '-.9' -> '0.9' +dqsub183 subtract '0.0' '-0.102' -> '0.102' +dqsub184 subtract '0.0' '-.4' -> '0.4' +dqsub185 subtract '0.0' '-.307' -> '0.307' +dqsub186 subtract '0.0' '-.43822' -> '0.43822' +dqsub187 subtract '0.0' '-.911' -> '0.911' +dqsub188 subtract '0.0' '-.02' -> '0.02' +dqsub189 subtract '0.00' '-.392' -> '0.392' +dqsub190 subtract '0.0' '-.26' -> '0.26' +dqsub191 subtract '0.0' '-0.51' -> '0.51' +dqsub192 subtract '0.0' '-.2234' -> '0.2234' +dqsub193 subtract '0.0' '-.2' -> '0.2' +dqsub194 subtract '0.0' '-.0008' -> '0.0008' +-- negatives of same +dqsub200 subtract '0' '-.1' -> '0.1' +dqsub201 subtract '00' '-.97983' -> '0.97983' +dqsub202 subtract '0' '-.9' -> '0.9' +dqsub203 subtract '0' '-0.102' -> '0.102' +dqsub204 subtract '0' '-.4' -> '0.4' +dqsub205 subtract '0' '-.307' -> '0.307' +dqsub206 subtract '0' '-.43822' -> '0.43822' +dqsub207 subtract '0' '-.911' -> '0.911' +dqsub208 subtract '.0' '-.02' -> '0.02' +dqsub209 subtract '00' '-.392' -> '0.392' +dqsub210 subtract '0' '-.26' -> '0.26' +dqsub211 subtract '0' '-0.51' -> '0.51' +dqsub212 subtract '0' '-.2234' -> '0.2234' +dqsub213 subtract '0' '-.2' -> '0.2' +dqsub214 subtract '.0' '-.0008' -> '0.0008' + +-- more fixed, LHS swaps [really the same as testcases under add] +dqsub220 subtract '-56267E-12' 0 -> '-5.6267E-8' +dqsub221 subtract '-56267E-11' 0 -> '-5.6267E-7' +dqsub222 subtract '-56267E-10' 0 -> '-0.0000056267' +dqsub223 subtract '-56267E-9' 0 -> '-0.000056267' +dqsub224 subtract '-56267E-8' 0 -> '-0.00056267' +dqsub225 subtract '-56267E-7' 0 -> '-0.0056267' +dqsub226 subtract '-56267E-6' 0 -> '-0.056267' +dqsub227 subtract '-56267E-5' 0 -> '-0.56267' +dqsub228 subtract '-56267E-2' 0 -> '-562.67' +dqsub229 subtract '-56267E-1' 0 -> '-5626.7' +dqsub230 subtract '-56267E-0' 0 -> '-56267' +-- symmetry ... +dqsub240 subtract 0 '-56267E-12' -> '5.6267E-8' +dqsub241 subtract 0 '-56267E-11' -> '5.6267E-7' +dqsub242 subtract 0 '-56267E-10' -> '0.0000056267' +dqsub243 subtract 0 '-56267E-9' -> '0.000056267' +dqsub244 subtract 0 '-56267E-8' -> '0.00056267' +dqsub245 subtract 0 '-56267E-7' -> '0.0056267' +dqsub246 subtract 0 '-56267E-6' -> '0.056267' +dqsub247 subtract 0 '-56267E-5' -> '0.56267' +dqsub248 subtract 0 '-56267E-2' -> '562.67' +dqsub249 subtract 0 '-56267E-1' -> '5626.7' +dqsub250 subtract 0 '-56267E-0' -> '56267' + +-- now some more from the 'new' add +dqsub301 subtract '1.23456789' '1.00000000' -> '0.23456789' +dqsub302 subtract '1.23456789' '1.00000011' -> '0.23456778' + +-- some carrying effects +dqsub321 subtract '0.9998' '0.0000' -> '0.9998' +dqsub322 subtract '0.9998' '0.0001' -> '0.9997' +dqsub323 subtract '0.9998' '0.0002' -> '0.9996' +dqsub324 subtract '0.9998' '0.0003' -> '0.9995' +dqsub325 subtract '0.9998' '-0.0000' -> '0.9998' +dqsub326 subtract '0.9998' '-0.0001' -> '0.9999' +dqsub327 subtract '0.9998' '-0.0002' -> '1.0000' +dqsub328 subtract '0.9998' '-0.0003' -> '1.0001' + +-- internal boundaries +dqsub346 subtract '10000e+9' '7' -> '9999999999993' +dqsub347 subtract '10000e+9' '70' -> '9999999999930' +dqsub348 subtract '10000e+9' '700' -> '9999999999300' +dqsub349 subtract '10000e+9' '7000' -> '9999999993000' +dqsub350 subtract '10000e+9' '70000' -> '9999999930000' +dqsub351 subtract '10000e+9' '700000' -> '9999999300000' +dqsub352 subtract '7' '10000e+9' -> '-9999999999993' +dqsub353 subtract '70' '10000e+9' -> '-9999999999930' +dqsub354 subtract '700' '10000e+9' -> '-9999999999300' +dqsub355 subtract '7000' '10000e+9' -> '-9999999993000' +dqsub356 subtract '70000' '10000e+9' -> '-9999999930000' +dqsub357 subtract '700000' '10000e+9' -> '-9999999300000' + +-- zero preservation +dqsub361 subtract 1 '0.0001' -> '0.9999' +dqsub362 subtract 1 '0.00001' -> '0.99999' +dqsub363 subtract 1 '0.000001' -> '0.999999' +dqsub364 subtract 1 '0.0000000000000000000000000000000001' -> '0.9999999999999999999999999999999999' +dqsub365 subtract 1 '0.00000000000000000000000000000000001' -> '1.000000000000000000000000000000000' Inexact Rounded +dqsub366 subtract 1 '0.000000000000000000000000000000000001' -> '1.000000000000000000000000000000000' Inexact Rounded + +-- some funny zeros [in case of bad signum] +dqsub370 subtract 1 0 -> 1 +dqsub371 subtract 1 0. -> 1 +dqsub372 subtract 1 .0 -> 1.0 +dqsub373 subtract 1 0.0 -> 1.0 +dqsub374 subtract 0 1 -> -1 +dqsub375 subtract 0. 1 -> -1 +dqsub376 subtract .0 1 -> -1.0 +dqsub377 subtract 0.0 1 -> -1.0 + +-- leading 0 digit before round +dqsub910 subtract -103519362 -51897955.3 -> -51621406.7 +dqsub911 subtract 159579.444 89827.5229 -> 69751.9211 + +dqsub920 subtract 333.0000000000000000000000000123456 33.00000000000000000000000001234566 -> 299.9999999999999999999999999999999 Inexact Rounded +dqsub921 subtract 333.0000000000000000000000000123456 33.00000000000000000000000001234565 -> 300.0000000000000000000000000000000 Inexact Rounded +dqsub922 subtract 133.0000000000000000000000000123456 33.00000000000000000000000001234565 -> 99.99999999999999999999999999999995 +dqsub923 subtract 133.0000000000000000000000000123456 33.00000000000000000000000001234564 -> 99.99999999999999999999999999999996 +dqsub924 subtract 133.0000000000000000000000000123456 33.00000000000000000000000001234540 -> 100.0000000000000000000000000000002 Rounded +dqsub925 subtract 133.0000000000000000000000000123456 43.00000000000000000000000001234560 -> 90.00000000000000000000000000000000 +dqsub926 subtract 133.0000000000000000000000000123456 43.00000000000000000000000001234561 -> 89.99999999999999999999999999999999 +dqsub927 subtract 133.0000000000000000000000000123456 43.00000000000000000000000001234566 -> 89.99999999999999999999999999999994 +dqsub928 subtract 101.0000000000000000000000000123456 91.00000000000000000000000001234566 -> 9.99999999999999999999999999999994 +dqsub929 subtract 101.0000000000000000000000000123456 99.00000000000000000000000001234566 -> 1.99999999999999999999999999999994 + +-- more LHS swaps [were fixed] +dqsub390 subtract '-56267E-10' 0 -> '-0.0000056267' +dqsub391 subtract '-56267E-6' 0 -> '-0.056267' +dqsub392 subtract '-56267E-5' 0 -> '-0.56267' +dqsub393 subtract '-56267E-4' 0 -> '-5.6267' +dqsub394 subtract '-56267E-3' 0 -> '-56.267' +dqsub395 subtract '-56267E-2' 0 -> '-562.67' +dqsub396 subtract '-56267E-1' 0 -> '-5626.7' +dqsub397 subtract '-56267E-0' 0 -> '-56267' +dqsub398 subtract '-5E-10' 0 -> '-5E-10' +dqsub399 subtract '-5E-7' 0 -> '-5E-7' +dqsub400 subtract '-5E-6' 0 -> '-0.000005' +dqsub401 subtract '-5E-5' 0 -> '-0.00005' +dqsub402 subtract '-5E-4' 0 -> '-0.0005' +dqsub403 subtract '-5E-1' 0 -> '-0.5' +dqsub404 subtract '-5E0' 0 -> '-5' +dqsub405 subtract '-5E1' 0 -> '-50' +dqsub406 subtract '-5E5' 0 -> '-500000' +dqsub407 subtract '-5E33' 0 -> '-5000000000000000000000000000000000' +dqsub408 subtract '-5E34' 0 -> '-5.000000000000000000000000000000000E+34' Rounded +dqsub409 subtract '-5E35' 0 -> '-5.000000000000000000000000000000000E+35' Rounded +dqsub410 subtract '-5E36' 0 -> '-5.000000000000000000000000000000000E+36' Rounded +dqsub411 subtract '-5E100' 0 -> '-5.000000000000000000000000000000000E+100' Rounded + +-- more RHS swaps [were fixed] +dqsub420 subtract 0 '-56267E-10' -> '0.0000056267' +dqsub421 subtract 0 '-56267E-6' -> '0.056267' +dqsub422 subtract 0 '-56267E-5' -> '0.56267' +dqsub423 subtract 0 '-56267E-4' -> '5.6267' +dqsub424 subtract 0 '-56267E-3' -> '56.267' +dqsub425 subtract 0 '-56267E-2' -> '562.67' +dqsub426 subtract 0 '-56267E-1' -> '5626.7' +dqsub427 subtract 0 '-56267E-0' -> '56267' +dqsub428 subtract 0 '-5E-10' -> '5E-10' +dqsub429 subtract 0 '-5E-7' -> '5E-7' +dqsub430 subtract 0 '-5E-6' -> '0.000005' +dqsub431 subtract 0 '-5E-5' -> '0.00005' +dqsub432 subtract 0 '-5E-4' -> '0.0005' +dqsub433 subtract 0 '-5E-1' -> '0.5' +dqsub434 subtract 0 '-5E0' -> '5' +dqsub435 subtract 0 '-5E1' -> '50' +dqsub436 subtract 0 '-5E5' -> '500000' +dqsub437 subtract 0 '-5E33' -> '5000000000000000000000000000000000' +dqsub438 subtract 0 '-5E34' -> '5.000000000000000000000000000000000E+34' Rounded +dqsub439 subtract 0 '-5E35' -> '5.000000000000000000000000000000000E+35' Rounded +dqsub440 subtract 0 '-5E36' -> '5.000000000000000000000000000000000E+36' Rounded +dqsub441 subtract 0 '-5E100' -> '5.000000000000000000000000000000000E+100' Rounded + + +-- try borderline precision, with carries, etc. +dqsub461 subtract '1E+16' '1' -> '9999999999999999' +dqsub462 subtract '1E+12' '-1.111' -> '1000000000001.111' +dqsub463 subtract '1.111' '-1E+12' -> '1000000000001.111' +dqsub464 subtract '-1' '-1E+16' -> '9999999999999999' +dqsub465 subtract '7E+15' '1' -> '6999999999999999' +dqsub466 subtract '7E+12' '-1.111' -> '7000000000001.111' +dqsub467 subtract '1.111' '-7E+12' -> '7000000000001.111' +dqsub468 subtract '-1' '-7E+15' -> '6999999999999999' + +-- 1234567890123456 1234567890123456 1 23456789012345 +dqsub470 subtract '0.4444444444444444444444444444444444' '-0.5555555555555555555555555555555563' -> '1.000000000000000000000000000000001' Inexact Rounded +dqsub471 subtract '0.4444444444444444444444444444444444' '-0.5555555555555555555555555555555562' -> '1.000000000000000000000000000000001' Inexact Rounded +dqsub472 subtract '0.4444444444444444444444444444444444' '-0.5555555555555555555555555555555561' -> '1.000000000000000000000000000000000' Inexact Rounded +dqsub473 subtract '0.4444444444444444444444444444444444' '-0.5555555555555555555555555555555560' -> '1.000000000000000000000000000000000' Inexact Rounded +dqsub474 subtract '0.4444444444444444444444444444444444' '-0.5555555555555555555555555555555559' -> '1.000000000000000000000000000000000' Inexact Rounded +dqsub475 subtract '0.4444444444444444444444444444444444' '-0.5555555555555555555555555555555558' -> '1.000000000000000000000000000000000' Inexact Rounded +dqsub476 subtract '0.4444444444444444444444444444444444' '-0.5555555555555555555555555555555557' -> '1.000000000000000000000000000000000' Inexact Rounded +dqsub477 subtract '0.4444444444444444444444444444444444' '-0.5555555555555555555555555555555556' -> '1.000000000000000000000000000000000' Rounded +dqsub478 subtract '0.4444444444444444444444444444444444' '-0.5555555555555555555555555555555555' -> '0.9999999999999999999999999999999999' +dqsub479 subtract '0.4444444444444444444444444444444444' '-0.5555555555555555555555555555555554' -> '0.9999999999999999999999999999999998' +dqsub480 subtract '0.4444444444444444444444444444444444' '-0.5555555555555555555555555555555553' -> '0.9999999999999999999999999999999997' +dqsub481 subtract '0.4444444444444444444444444444444444' '-0.5555555555555555555555555555555552' -> '0.9999999999999999999999999999999996' +dqsub482 subtract '0.4444444444444444444444444444444444' '-0.5555555555555555555555555555555551' -> '0.9999999999999999999999999999999995' +dqsub483 subtract '0.4444444444444444444444444444444444' '-0.5555555555555555555555555555555550' -> '0.9999999999999999999999999999999994' + +-- and some more, including residue effects and different roundings +rounding: half_up +dqsub500 subtract '1231234555555555555555555567456789' 0 -> '1231234555555555555555555567456789' +dqsub501 subtract '1231234555555555555555555567456789' 0.000000001 -> '1231234555555555555555555567456789' Inexact Rounded +dqsub502 subtract '1231234555555555555555555567456789' 0.000001 -> '1231234555555555555555555567456789' Inexact Rounded +dqsub503 subtract '1231234555555555555555555567456789' 0.1 -> '1231234555555555555555555567456789' Inexact Rounded +dqsub504 subtract '1231234555555555555555555567456789' 0.4 -> '1231234555555555555555555567456789' Inexact Rounded +dqsub505 subtract '1231234555555555555555555567456789' 0.49 -> '1231234555555555555555555567456789' Inexact Rounded +dqsub506 subtract '1231234555555555555555555567456789' 0.499999 -> '1231234555555555555555555567456789' Inexact Rounded +dqsub507 subtract '1231234555555555555555555567456789' 0.499999999 -> '1231234555555555555555555567456789' Inexact Rounded +dqsub508 subtract '1231234555555555555555555567456789' 0.5 -> '1231234555555555555555555567456789' Inexact Rounded +dqsub509 subtract '1231234555555555555555555567456789' 0.500000001 -> '1231234555555555555555555567456788' Inexact Rounded +dqsub510 subtract '1231234555555555555555555567456789' 0.500001 -> '1231234555555555555555555567456788' Inexact Rounded +dqsub511 subtract '1231234555555555555555555567456789' 0.51 -> '1231234555555555555555555567456788' Inexact Rounded +dqsub512 subtract '1231234555555555555555555567456789' 0.6 -> '1231234555555555555555555567456788' Inexact Rounded +dqsub513 subtract '1231234555555555555555555567456789' 0.9 -> '1231234555555555555555555567456788' Inexact Rounded +dqsub514 subtract '1231234555555555555555555567456789' 0.99999 -> '1231234555555555555555555567456788' Inexact Rounded +dqsub515 subtract '1231234555555555555555555567456789' 0.999999999 -> '1231234555555555555555555567456788' Inexact Rounded +dqsub516 subtract '1231234555555555555555555567456789' 1 -> '1231234555555555555555555567456788' +dqsub517 subtract '1231234555555555555555555567456789' 1.000000001 -> '1231234555555555555555555567456788' Inexact Rounded +dqsub518 subtract '1231234555555555555555555567456789' 1.00001 -> '1231234555555555555555555567456788' Inexact Rounded +dqsub519 subtract '1231234555555555555555555567456789' 1.1 -> '1231234555555555555555555567456788' Inexact Rounded + +rounding: half_even +dqsub520 subtract '1231234555555555555555555567456789' 0 -> '1231234555555555555555555567456789' +dqsub521 subtract '1231234555555555555555555567456789' 0.000000001 -> '1231234555555555555555555567456789' Inexact Rounded +dqsub522 subtract '1231234555555555555555555567456789' 0.000001 -> '1231234555555555555555555567456789' Inexact Rounded +dqsub523 subtract '1231234555555555555555555567456789' 0.1 -> '1231234555555555555555555567456789' Inexact Rounded +dqsub524 subtract '1231234555555555555555555567456789' 0.4 -> '1231234555555555555555555567456789' Inexact Rounded +dqsub525 subtract '1231234555555555555555555567456789' 0.49 -> '1231234555555555555555555567456789' Inexact Rounded +dqsub526 subtract '1231234555555555555555555567456789' 0.499999 -> '1231234555555555555555555567456789' Inexact Rounded +dqsub527 subtract '1231234555555555555555555567456789' 0.499999999 -> '1231234555555555555555555567456789' Inexact Rounded +dqsub528 subtract '1231234555555555555555555567456789' 0.5 -> '1231234555555555555555555567456788' Inexact Rounded +dqsub529 subtract '1231234555555555555555555567456789' 0.500000001 -> '1231234555555555555555555567456788' Inexact Rounded +dqsub530 subtract '1231234555555555555555555567456789' 0.500001 -> '1231234555555555555555555567456788' Inexact Rounded +dqsub531 subtract '1231234555555555555555555567456789' 0.51 -> '1231234555555555555555555567456788' Inexact Rounded +dqsub532 subtract '1231234555555555555555555567456789' 0.6 -> '1231234555555555555555555567456788' Inexact Rounded +dqsub533 subtract '1231234555555555555555555567456789' 0.9 -> '1231234555555555555555555567456788' Inexact Rounded +dqsub534 subtract '1231234555555555555555555567456789' 0.99999 -> '1231234555555555555555555567456788' Inexact Rounded +dqsub535 subtract '1231234555555555555555555567456789' 0.999999999 -> '1231234555555555555555555567456788' Inexact Rounded +dqsub536 subtract '1231234555555555555555555567456789' 1 -> '1231234555555555555555555567456788' +dqsub537 subtract '1231234555555555555555555567456789' 1.00000001 -> '1231234555555555555555555567456788' Inexact Rounded +dqsub538 subtract '1231234555555555555555555567456789' 1.00001 -> '1231234555555555555555555567456788' Inexact Rounded +dqsub539 subtract '1231234555555555555555555567456789' 1.1 -> '1231234555555555555555555567456788' Inexact Rounded +-- critical few with even bottom digit... +dqsub540 subtract '1231234555555555555555555567456788' 0.499999999 -> '1231234555555555555555555567456788' Inexact Rounded +dqsub541 subtract '1231234555555555555555555567456788' 0.5 -> '1231234555555555555555555567456788' Inexact Rounded +dqsub542 subtract '1231234555555555555555555567456788' 0.500000001 -> '1231234555555555555555555567456787' Inexact Rounded + +rounding: down +dqsub550 subtract '1231234555555555555555555567456789' 0 -> '1231234555555555555555555567456789' +dqsub551 subtract '1231234555555555555555555567456789' 0.000000001 -> '1231234555555555555555555567456788' Inexact Rounded +dqsub552 subtract '1231234555555555555555555567456789' 0.000001 -> '1231234555555555555555555567456788' Inexact Rounded +dqsub553 subtract '1231234555555555555555555567456789' 0.1 -> '1231234555555555555555555567456788' Inexact Rounded +dqsub554 subtract '1231234555555555555555555567456789' 0.4 -> '1231234555555555555555555567456788' Inexact Rounded +dqsub555 subtract '1231234555555555555555555567456789' 0.49 -> '1231234555555555555555555567456788' Inexact Rounded +dqsub556 subtract '1231234555555555555555555567456789' 0.499999 -> '1231234555555555555555555567456788' Inexact Rounded +dqsub557 subtract '1231234555555555555555555567456789' 0.499999999 -> '1231234555555555555555555567456788' Inexact Rounded +dqsub558 subtract '1231234555555555555555555567456789' 0.5 -> '1231234555555555555555555567456788' Inexact Rounded +dqsub559 subtract '1231234555555555555555555567456789' 0.500000001 -> '1231234555555555555555555567456788' Inexact Rounded +dqsub560 subtract '1231234555555555555555555567456789' 0.500001 -> '1231234555555555555555555567456788' Inexact Rounded +dqsub561 subtract '1231234555555555555555555567456789' 0.51 -> '1231234555555555555555555567456788' Inexact Rounded +dqsub562 subtract '1231234555555555555555555567456789' 0.6 -> '1231234555555555555555555567456788' Inexact Rounded +dqsub563 subtract '1231234555555555555555555567456789' 0.9 -> '1231234555555555555555555567456788' Inexact Rounded +dqsub564 subtract '1231234555555555555555555567456789' 0.99999 -> '1231234555555555555555555567456788' Inexact Rounded +dqsub565 subtract '1231234555555555555555555567456789' 0.999999999 -> '1231234555555555555555555567456788' Inexact Rounded +dqsub566 subtract '1231234555555555555555555567456789' 1 -> '1231234555555555555555555567456788' +dqsub567 subtract '1231234555555555555555555567456789' 1.00000001 -> '1231234555555555555555555567456787' Inexact Rounded +dqsub568 subtract '1231234555555555555555555567456789' 1.00001 -> '1231234555555555555555555567456787' Inexact Rounded +dqsub569 subtract '1231234555555555555555555567456789' 1.1 -> '1231234555555555555555555567456787' Inexact Rounded + +-- symmetry... +rounding: half_up +dqsub600 subtract 0 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456789' +dqsub601 subtract 0.000000001 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456789' Inexact Rounded +dqsub602 subtract 0.000001 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456789' Inexact Rounded +dqsub603 subtract 0.1 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456789' Inexact Rounded +dqsub604 subtract 0.4 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456789' Inexact Rounded +dqsub605 subtract 0.49 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456789' Inexact Rounded +dqsub606 subtract 0.499999 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456789' Inexact Rounded +dqsub607 subtract 0.499999999 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456789' Inexact Rounded +dqsub608 subtract 0.5 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456789' Inexact Rounded +dqsub609 subtract 0.500000001 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456788' Inexact Rounded +dqsub610 subtract 0.500001 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456788' Inexact Rounded +dqsub611 subtract 0.51 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456788' Inexact Rounded +dqsub612 subtract 0.6 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456788' Inexact Rounded +dqsub613 subtract 0.9 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456788' Inexact Rounded +dqsub614 subtract 0.99999 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456788' Inexact Rounded +dqsub615 subtract 0.999999999 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456788' Inexact Rounded +dqsub616 subtract 1 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456788' +dqsub617 subtract 1.000000001 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456788' Inexact Rounded +dqsub618 subtract 1.00001 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456788' Inexact Rounded +dqsub619 subtract 1.1 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456788' Inexact Rounded + +rounding: half_even +dqsub620 subtract 0 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456789' +dqsub621 subtract 0.000000001 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456789' Inexact Rounded +dqsub622 subtract 0.000001 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456789' Inexact Rounded +dqsub623 subtract 0.1 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456789' Inexact Rounded +dqsub624 subtract 0.4 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456789' Inexact Rounded +dqsub625 subtract 0.49 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456789' Inexact Rounded +dqsub626 subtract 0.499999 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456789' Inexact Rounded +dqsub627 subtract 0.499999999 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456789' Inexact Rounded +dqsub628 subtract 0.5 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456788' Inexact Rounded +dqsub629 subtract 0.500000001 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456788' Inexact Rounded +dqsub630 subtract 0.500001 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456788' Inexact Rounded +dqsub631 subtract 0.51 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456788' Inexact Rounded +dqsub632 subtract 0.6 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456788' Inexact Rounded +dqsub633 subtract 0.9 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456788' Inexact Rounded +dqsub634 subtract 0.99999 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456788' Inexact Rounded +dqsub635 subtract 0.999999999 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456788' Inexact Rounded +dqsub636 subtract 1 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456788' +dqsub637 subtract 1.00000001 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456788' Inexact Rounded +dqsub638 subtract 1.00001 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456788' Inexact Rounded +dqsub639 subtract 1.1 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456788' Inexact Rounded +-- critical few with even bottom digit... +dqsub640 subtract 0.499999999 '1231234555555555555555555567456788' -> '-1231234555555555555555555567456788' Inexact Rounded +dqsub641 subtract 0.5 '1231234555555555555555555567456788' -> '-1231234555555555555555555567456788' Inexact Rounded +dqsub642 subtract 0.500000001 '1231234555555555555555555567456788' -> '-1231234555555555555555555567456787' Inexact Rounded + +rounding: down +dqsub650 subtract 0 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456789' +dqsub651 subtract 0.000000001 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456788' Inexact Rounded +dqsub652 subtract 0.000001 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456788' Inexact Rounded +dqsub653 subtract 0.1 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456788' Inexact Rounded +dqsub654 subtract 0.4 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456788' Inexact Rounded +dqsub655 subtract 0.49 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456788' Inexact Rounded +dqsub656 subtract 0.499999 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456788' Inexact Rounded +dqsub657 subtract 0.499999999 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456788' Inexact Rounded +dqsub658 subtract 0.5 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456788' Inexact Rounded +dqsub659 subtract 0.500000001 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456788' Inexact Rounded +dqsub660 subtract 0.500001 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456788' Inexact Rounded +dqsub661 subtract 0.51 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456788' Inexact Rounded +dqsub662 subtract 0.6 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456788' Inexact Rounded +dqsub663 subtract 0.9 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456788' Inexact Rounded +dqsub664 subtract 0.99999 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456788' Inexact Rounded +dqsub665 subtract 0.999999999 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456788' Inexact Rounded +dqsub666 subtract 1 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456788' +dqsub667 subtract 1.00000001 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456787' Inexact Rounded +dqsub668 subtract 1.00001 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456787' Inexact Rounded +dqsub669 subtract 1.1 '1231234555555555555555555567456789' -> '-1231234555555555555555555567456787' Inexact Rounded + + +-- lots of leading zeros in intermediate result, and showing effects of +-- input rounding would have affected the following +rounding: half_up +dqsub670 subtract '1234567456789' '1234567456788.1' -> 0.9 +dqsub671 subtract '1234567456789' '1234567456788.9' -> 0.1 +dqsub672 subtract '1234567456789' '1234567456789.1' -> -0.1 +dqsub673 subtract '1234567456789' '1234567456789.5' -> -0.5 +dqsub674 subtract '1234567456789' '1234567456789.9' -> -0.9 + +rounding: half_even +dqsub680 subtract '1234567456789' '1234567456788.1' -> 0.9 +dqsub681 subtract '1234567456789' '1234567456788.9' -> 0.1 +dqsub682 subtract '1234567456789' '1234567456789.1' -> -0.1 +dqsub683 subtract '1234567456789' '1234567456789.5' -> -0.5 +dqsub684 subtract '1234567456789' '1234567456789.9' -> -0.9 + +dqsub685 subtract '1234567456788' '1234567456787.1' -> 0.9 +dqsub686 subtract '1234567456788' '1234567456787.9' -> 0.1 +dqsub687 subtract '1234567456788' '1234567456788.1' -> -0.1 +dqsub688 subtract '1234567456788' '1234567456788.5' -> -0.5 +dqsub689 subtract '1234567456788' '1234567456788.9' -> -0.9 + +rounding: down +dqsub690 subtract '1234567456789' '1234567456788.1' -> 0.9 +dqsub691 subtract '1234567456789' '1234567456788.9' -> 0.1 +dqsub692 subtract '1234567456789' '1234567456789.1' -> -0.1 +dqsub693 subtract '1234567456789' '1234567456789.5' -> -0.5 +dqsub694 subtract '1234567456789' '1234567456789.9' -> -0.9 + +-- Specials +dqsub780 subtract -Inf Inf -> -Infinity +dqsub781 subtract -Inf 1000 -> -Infinity +dqsub782 subtract -Inf 1 -> -Infinity +dqsub783 subtract -Inf -0 -> -Infinity +dqsub784 subtract -Inf -1 -> -Infinity +dqsub785 subtract -Inf -1000 -> -Infinity +dqsub787 subtract -1000 Inf -> -Infinity +dqsub788 subtract -Inf Inf -> -Infinity +dqsub789 subtract -1 Inf -> -Infinity +dqsub790 subtract 0 Inf -> -Infinity +dqsub791 subtract 1 Inf -> -Infinity +dqsub792 subtract 1000 Inf -> -Infinity + +dqsub800 subtract Inf Inf -> NaN Invalid_operation +dqsub801 subtract Inf 1000 -> Infinity +dqsub802 subtract Inf 1 -> Infinity +dqsub803 subtract Inf 0 -> Infinity +dqsub804 subtract Inf -0 -> Infinity +dqsub805 subtract Inf -1 -> Infinity +dqsub806 subtract Inf -1000 -> Infinity +dqsub807 subtract Inf -Inf -> Infinity +dqsub808 subtract -1000 -Inf -> Infinity +dqsub809 subtract -Inf -Inf -> NaN Invalid_operation +dqsub810 subtract -1 -Inf -> Infinity +dqsub811 subtract -0 -Inf -> Infinity +dqsub812 subtract 0 -Inf -> Infinity +dqsub813 subtract 1 -Inf -> Infinity +dqsub814 subtract 1000 -Inf -> Infinity +dqsub815 subtract Inf -Inf -> Infinity + +dqsub821 subtract NaN Inf -> NaN +dqsub822 subtract -NaN 1000 -> -NaN +dqsub823 subtract NaN 1 -> NaN +dqsub824 subtract NaN 0 -> NaN +dqsub825 subtract NaN -0 -> NaN +dqsub826 subtract NaN -1 -> NaN +dqsub827 subtract NaN -1000 -> NaN +dqsub828 subtract NaN -Inf -> NaN +dqsub829 subtract -NaN NaN -> -NaN +dqsub830 subtract -Inf NaN -> NaN +dqsub831 subtract -1000 NaN -> NaN +dqsub832 subtract -1 NaN -> NaN +dqsub833 subtract -0 NaN -> NaN +dqsub834 subtract 0 NaN -> NaN +dqsub835 subtract 1 NaN -> NaN +dqsub836 subtract 1000 -NaN -> -NaN +dqsub837 subtract Inf NaN -> NaN + +dqsub841 subtract sNaN Inf -> NaN Invalid_operation +dqsub842 subtract -sNaN 1000 -> -NaN Invalid_operation +dqsub843 subtract sNaN 1 -> NaN Invalid_operation +dqsub844 subtract sNaN 0 -> NaN Invalid_operation +dqsub845 subtract sNaN -0 -> NaN Invalid_operation +dqsub846 subtract sNaN -1 -> NaN Invalid_operation +dqsub847 subtract sNaN -1000 -> NaN Invalid_operation +dqsub848 subtract sNaN NaN -> NaN Invalid_operation +dqsub849 subtract sNaN sNaN -> NaN Invalid_operation +dqsub850 subtract NaN sNaN -> NaN Invalid_operation +dqsub851 subtract -Inf -sNaN -> -NaN Invalid_operation +dqsub852 subtract -1000 sNaN -> NaN Invalid_operation +dqsub853 subtract -1 sNaN -> NaN Invalid_operation +dqsub854 subtract -0 sNaN -> NaN Invalid_operation +dqsub855 subtract 0 sNaN -> NaN Invalid_operation +dqsub856 subtract 1 sNaN -> NaN Invalid_operation +dqsub857 subtract 1000 sNaN -> NaN Invalid_operation +dqsub858 subtract Inf sNaN -> NaN Invalid_operation +dqsub859 subtract NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +dqsub861 subtract NaN01 -Inf -> NaN1 +dqsub862 subtract -NaN02 -1000 -> -NaN2 +dqsub863 subtract NaN03 1000 -> NaN3 +dqsub864 subtract NaN04 Inf -> NaN4 +dqsub865 subtract NaN05 NaN61 -> NaN5 +dqsub866 subtract -Inf -NaN71 -> -NaN71 +dqsub867 subtract -1000 NaN81 -> NaN81 +dqsub868 subtract 1000 NaN91 -> NaN91 +dqsub869 subtract Inf NaN101 -> NaN101 +dqsub871 subtract sNaN011 -Inf -> NaN11 Invalid_operation +dqsub872 subtract sNaN012 -1000 -> NaN12 Invalid_operation +dqsub873 subtract -sNaN013 1000 -> -NaN13 Invalid_operation +dqsub874 subtract sNaN014 NaN171 -> NaN14 Invalid_operation +dqsub875 subtract sNaN015 sNaN181 -> NaN15 Invalid_operation +dqsub876 subtract NaN016 sNaN191 -> NaN191 Invalid_operation +dqsub877 subtract -Inf sNaN201 -> NaN201 Invalid_operation +dqsub878 subtract -1000 sNaN211 -> NaN211 Invalid_operation +dqsub879 subtract 1000 -sNaN221 -> -NaN221 Invalid_operation +dqsub880 subtract Inf sNaN231 -> NaN231 Invalid_operation +dqsub881 subtract NaN025 sNaN241 -> NaN241 Invalid_operation + +-- edge case spills +dqsub901 subtract 2.E-3 1.002 -> -1.000 +dqsub902 subtract 2.0E-3 1.002 -> -1.0000 +dqsub903 subtract 2.00E-3 1.0020 -> -1.00000 +dqsub904 subtract 2.000E-3 1.00200 -> -1.000000 +dqsub905 subtract 2.0000E-3 1.002000 -> -1.0000000 +dqsub906 subtract 2.00000E-3 1.0020000 -> -1.00000000 +dqsub907 subtract 2.000000E-3 1.00200000 -> -1.000000000 +dqsub908 subtract 2.0000000E-3 1.002000000 -> -1.0000000000 + +-- subnormals and overflows covered under Add + +-- Examples from SQL proposal (Krishna Kulkarni) +dqsub1125 subtract 130E-2 120E-2 -> 0.10 +dqsub1126 subtract 130E-2 12E-1 -> 0.10 +dqsub1127 subtract 130E-2 1E0 -> 0.30 +dqsub1128 subtract 1E2 1E4 -> -9.9E+3 + +-- Null tests +dqsub9990 subtract 10 # -> NaN Invalid_operation +dqsub9991 subtract # 10 -> NaN Invalid_operation Added: python/branches/release25-maint/Lib/test/decimaltestdata/dqToIntegral.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/dqToIntegral.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,257 @@ +------------------------------------------------------------------------ +-- dqToIntegral.decTest -- round Quad to integral value -- +-- Copyright (c) IBM Corporation, 2001, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- This set of tests tests the extended specification 'round-to-integral +-- value-exact' operations (from IEEE 854, later modified in 754r). +-- All non-zero results are defined as being those from either copy or +-- quantize, so those are assumed to have been tested extensively +-- elsewhere; the tests here are for integrity, rounding mode, etc. +-- Also, it is assumed the test harness will use these tests for both +-- ToIntegralExact (which does set Inexact) and the fixed-name +-- functions (which do not set Inexact). + +-- Note that decNumber implements an earlier definition of toIntegral +-- which never sets Inexact; the decTest operator for that is called +-- 'tointegral' instead of 'tointegralx'. + +extended: 1 +clamp: 1 +precision: 34 +maxExponent: 6144 +minExponent: -6143 +rounding: half_even + +dqintx001 tointegralx 0 -> 0 +dqintx002 tointegralx 0.0 -> 0 +dqintx003 tointegralx 0.1 -> 0 Inexact Rounded +dqintx004 tointegralx 0.2 -> 0 Inexact Rounded +dqintx005 tointegralx 0.3 -> 0 Inexact Rounded +dqintx006 tointegralx 0.4 -> 0 Inexact Rounded +dqintx007 tointegralx 0.5 -> 0 Inexact Rounded +dqintx008 tointegralx 0.6 -> 1 Inexact Rounded +dqintx009 tointegralx 0.7 -> 1 Inexact Rounded +dqintx010 tointegralx 0.8 -> 1 Inexact Rounded +dqintx011 tointegralx 0.9 -> 1 Inexact Rounded +dqintx012 tointegralx 1 -> 1 +dqintx013 tointegralx 1.0 -> 1 Rounded +dqintx014 tointegralx 1.1 -> 1 Inexact Rounded +dqintx015 tointegralx 1.2 -> 1 Inexact Rounded +dqintx016 tointegralx 1.3 -> 1 Inexact Rounded +dqintx017 tointegralx 1.4 -> 1 Inexact Rounded +dqintx018 tointegralx 1.5 -> 2 Inexact Rounded +dqintx019 tointegralx 1.6 -> 2 Inexact Rounded +dqintx020 tointegralx 1.7 -> 2 Inexact Rounded +dqintx021 tointegralx 1.8 -> 2 Inexact Rounded +dqintx022 tointegralx 1.9 -> 2 Inexact Rounded +-- negatives +dqintx031 tointegralx -0 -> -0 +dqintx032 tointegralx -0.0 -> -0 +dqintx033 tointegralx -0.1 -> -0 Inexact Rounded +dqintx034 tointegralx -0.2 -> -0 Inexact Rounded +dqintx035 tointegralx -0.3 -> -0 Inexact Rounded +dqintx036 tointegralx -0.4 -> -0 Inexact Rounded +dqintx037 tointegralx -0.5 -> -0 Inexact Rounded +dqintx038 tointegralx -0.6 -> -1 Inexact Rounded +dqintx039 tointegralx -0.7 -> -1 Inexact Rounded +dqintx040 tointegralx -0.8 -> -1 Inexact Rounded +dqintx041 tointegralx -0.9 -> -1 Inexact Rounded +dqintx042 tointegralx -1 -> -1 +dqintx043 tointegralx -1.0 -> -1 Rounded +dqintx044 tointegralx -1.1 -> -1 Inexact Rounded +dqintx045 tointegralx -1.2 -> -1 Inexact Rounded +dqintx046 tointegralx -1.3 -> -1 Inexact Rounded +dqintx047 tointegralx -1.4 -> -1 Inexact Rounded +dqintx048 tointegralx -1.5 -> -2 Inexact Rounded +dqintx049 tointegralx -1.6 -> -2 Inexact Rounded +dqintx050 tointegralx -1.7 -> -2 Inexact Rounded +dqintx051 tointegralx -1.8 -> -2 Inexact Rounded +dqintx052 tointegralx -1.9 -> -2 Inexact Rounded +-- next two would be NaN using quantize(x, 0) +dqintx053 tointegralx 10E+60 -> 1.0E+61 +dqintx054 tointegralx -10E+60 -> -1.0E+61 + +-- numbers around precision +dqintx060 tointegralx '56267E-17' -> '0' Inexact Rounded +dqintx061 tointegralx '56267E-5' -> '1' Inexact Rounded +dqintx062 tointegralx '56267E-2' -> '563' Inexact Rounded +dqintx063 tointegralx '56267E-1' -> '5627' Inexact Rounded +dqintx065 tointegralx '56267E-0' -> '56267' +dqintx066 tointegralx '56267E+0' -> '56267' +dqintx067 tointegralx '56267E+1' -> '5.6267E+5' +dqintx068 tointegralx '56267E+9' -> '5.6267E+13' +dqintx069 tointegralx '56267E+10' -> '5.6267E+14' +dqintx070 tointegralx '56267E+11' -> '5.6267E+15' +dqintx071 tointegralx '56267E+12' -> '5.6267E+16' +dqintx072 tointegralx '56267E+13' -> '5.6267E+17' +dqintx073 tointegralx '1.23E+96' -> '1.23E+96' +dqintx074 tointegralx '1.23E+6144' -> #47ffd300000000000000000000000000 Clamped + +dqintx080 tointegralx '-56267E-10' -> '-0' Inexact Rounded +dqintx081 tointegralx '-56267E-5' -> '-1' Inexact Rounded +dqintx082 tointegralx '-56267E-2' -> '-563' Inexact Rounded +dqintx083 tointegralx '-56267E-1' -> '-5627' Inexact Rounded +dqintx085 tointegralx '-56267E-0' -> '-56267' +dqintx086 tointegralx '-56267E+0' -> '-56267' +dqintx087 tointegralx '-56267E+1' -> '-5.6267E+5' +dqintx088 tointegralx '-56267E+9' -> '-5.6267E+13' +dqintx089 tointegralx '-56267E+10' -> '-5.6267E+14' +dqintx090 tointegralx '-56267E+11' -> '-5.6267E+15' +dqintx091 tointegralx '-56267E+12' -> '-5.6267E+16' +dqintx092 tointegralx '-56267E+13' -> '-5.6267E+17' +dqintx093 tointegralx '-1.23E+96' -> '-1.23E+96' +dqintx094 tointegralx '-1.23E+6144' -> #c7ffd300000000000000000000000000 Clamped + +-- subnormal inputs +dqintx100 tointegralx 1E-299 -> 0 Inexact Rounded +dqintx101 tointegralx 0.1E-299 -> 0 Inexact Rounded +dqintx102 tointegralx 0.01E-299 -> 0 Inexact Rounded +dqintx103 tointegralx 0E-299 -> 0 + +-- specials and zeros +dqintx120 tointegralx 'Inf' -> Infinity +dqintx121 tointegralx '-Inf' -> -Infinity +dqintx122 tointegralx NaN -> NaN +dqintx123 tointegralx sNaN -> NaN Invalid_operation +dqintx124 tointegralx 0 -> 0 +dqintx125 tointegralx -0 -> -0 +dqintx126 tointegralx 0.000 -> 0 +dqintx127 tointegralx 0.00 -> 0 +dqintx128 tointegralx 0.0 -> 0 +dqintx129 tointegralx 0 -> 0 +dqintx130 tointegralx 0E-3 -> 0 +dqintx131 tointegralx 0E-2 -> 0 +dqintx132 tointegralx 0E-1 -> 0 +dqintx133 tointegralx 0E-0 -> 0 +dqintx134 tointegralx 0E+1 -> 0E+1 +dqintx135 tointegralx 0E+2 -> 0E+2 +dqintx136 tointegralx 0E+3 -> 0E+3 +dqintx137 tointegralx 0E+4 -> 0E+4 +dqintx138 tointegralx 0E+5 -> 0E+5 +dqintx139 tointegralx -0.000 -> -0 +dqintx140 tointegralx -0.00 -> -0 +dqintx141 tointegralx -0.0 -> -0 +dqintx142 tointegralx -0 -> -0 +dqintx143 tointegralx -0E-3 -> -0 +dqintx144 tointegralx -0E-2 -> -0 +dqintx145 tointegralx -0E-1 -> -0 +dqintx146 tointegralx -0E-0 -> -0 +dqintx147 tointegralx -0E+1 -> -0E+1 +dqintx148 tointegralx -0E+2 -> -0E+2 +dqintx149 tointegralx -0E+3 -> -0E+3 +dqintx150 tointegralx -0E+4 -> -0E+4 +dqintx151 tointegralx -0E+5 -> -0E+5 +-- propagating NaNs +dqintx152 tointegralx NaN808 -> NaN808 +dqintx153 tointegralx sNaN080 -> NaN80 Invalid_operation +dqintx154 tointegralx -NaN808 -> -NaN808 +dqintx155 tointegralx -sNaN080 -> -NaN80 Invalid_operation +dqintx156 tointegralx -NaN -> -NaN +dqintx157 tointegralx -sNaN -> -NaN Invalid_operation + +-- examples +rounding: half_up +dqintx200 tointegralx 2.1 -> 2 Inexact Rounded +dqintx201 tointegralx 100 -> 100 +dqintx202 tointegralx 100.0 -> 100 Rounded +dqintx203 tointegralx 101.5 -> 102 Inexact Rounded +dqintx204 tointegralx -101.5 -> -102 Inexact Rounded +dqintx205 tointegralx 10E+5 -> 1.0E+6 +dqintx206 tointegralx 7.89E+77 -> 7.89E+77 +dqintx207 tointegralx -Inf -> -Infinity + + +-- all rounding modes +rounding: half_even +dqintx210 tointegralx 55.5 -> 56 Inexact Rounded +dqintx211 tointegralx 56.5 -> 56 Inexact Rounded +dqintx212 tointegralx 57.5 -> 58 Inexact Rounded +dqintx213 tointegralx -55.5 -> -56 Inexact Rounded +dqintx214 tointegralx -56.5 -> -56 Inexact Rounded +dqintx215 tointegralx -57.5 -> -58 Inexact Rounded + +rounding: half_up + +dqintx220 tointegralx 55.5 -> 56 Inexact Rounded +dqintx221 tointegralx 56.5 -> 57 Inexact Rounded +dqintx222 tointegralx 57.5 -> 58 Inexact Rounded +dqintx223 tointegralx -55.5 -> -56 Inexact Rounded +dqintx224 tointegralx -56.5 -> -57 Inexact Rounded +dqintx225 tointegralx -57.5 -> -58 Inexact Rounded + +rounding: half_down + +dqintx230 tointegralx 55.5 -> 55 Inexact Rounded +dqintx231 tointegralx 56.5 -> 56 Inexact Rounded +dqintx232 tointegralx 57.5 -> 57 Inexact Rounded +dqintx233 tointegralx -55.5 -> -55 Inexact Rounded +dqintx234 tointegralx -56.5 -> -56 Inexact Rounded +dqintx235 tointegralx -57.5 -> -57 Inexact Rounded + +rounding: up + +dqintx240 tointegralx 55.3 -> 56 Inexact Rounded +dqintx241 tointegralx 56.3 -> 57 Inexact Rounded +dqintx242 tointegralx 57.3 -> 58 Inexact Rounded +dqintx243 tointegralx -55.3 -> -56 Inexact Rounded +dqintx244 tointegralx -56.3 -> -57 Inexact Rounded +dqintx245 tointegralx -57.3 -> -58 Inexact Rounded + +rounding: down + +dqintx250 tointegralx 55.7 -> 55 Inexact Rounded +dqintx251 tointegralx 56.7 -> 56 Inexact Rounded +dqintx252 tointegralx 57.7 -> 57 Inexact Rounded +dqintx253 tointegralx -55.7 -> -55 Inexact Rounded +dqintx254 tointegralx -56.7 -> -56 Inexact Rounded +dqintx255 tointegralx -57.7 -> -57 Inexact Rounded + +rounding: ceiling + +dqintx260 tointegralx 55.3 -> 56 Inexact Rounded +dqintx261 tointegralx 56.3 -> 57 Inexact Rounded +dqintx262 tointegralx 57.3 -> 58 Inexact Rounded +dqintx263 tointegralx -55.3 -> -55 Inexact Rounded +dqintx264 tointegralx -56.3 -> -56 Inexact Rounded +dqintx265 tointegralx -57.3 -> -57 Inexact Rounded + +rounding: floor + +dqintx270 tointegralx 55.7 -> 55 Inexact Rounded +dqintx271 tointegralx 56.7 -> 56 Inexact Rounded +dqintx272 tointegralx 57.7 -> 57 Inexact Rounded +dqintx273 tointegralx -55.7 -> -56 Inexact Rounded +dqintx274 tointegralx -56.7 -> -57 Inexact Rounded +dqintx275 tointegralx -57.7 -> -58 Inexact Rounded + +-- Int and uInt32 edge values for testing conversions +dqintx300 tointegralx -2147483646 -> -2147483646 +dqintx301 tointegralx -2147483647 -> -2147483647 +dqintx302 tointegralx -2147483648 -> -2147483648 +dqintx303 tointegralx -2147483649 -> -2147483649 +dqintx304 tointegralx 2147483646 -> 2147483646 +dqintx305 tointegralx 2147483647 -> 2147483647 +dqintx306 tointegralx 2147483648 -> 2147483648 +dqintx307 tointegralx 2147483649 -> 2147483649 +dqintx308 tointegralx 4294967294 -> 4294967294 +dqintx309 tointegralx 4294967295 -> 4294967295 +dqintx310 tointegralx 4294967296 -> 4294967296 +dqintx311 tointegralx 4294967297 -> 4294967297 + Added: python/branches/release25-maint/Lib/test/decimaltestdata/dqXor.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/dqXor.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,410 @@ +------------------------------------------------------------------------ +-- dqXor.decTest -- digitwise logical XOR for decQuads -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +extended: 1 +clamp: 1 +precision: 34 +maxExponent: 6144 +minExponent: -6143 +rounding: half_even + +-- Sanity check (truth table) +dqxor001 xor 0 0 -> 0 +dqxor002 xor 0 1 -> 1 +dqxor003 xor 1 0 -> 1 +dqxor004 xor 1 1 -> 0 +dqxor005 xor 1100 1010 -> 110 +-- and at msd and msd-1 +dqxor006 xor 0000000000000000000000000000000000 0000000000000000000000000000000000 -> 0 +dqxor007 xor 0000000000000000000000000000000000 1000000000000000000000000000000000 -> 1000000000000000000000000000000000 +dqxor008 xor 1000000000000000000000000000000000 0000000000000000000000000000000000 -> 1000000000000000000000000000000000 +dqxor009 xor 1000000000000000000000000000000000 1000000000000000000000000000000000 -> 0 +dqxor010 xor 0000000000000000000000000000000000 0000000000000000000000000000000000 -> 0 +dqxor011 xor 0000000000000000000000000000000000 0100000000000000000000000000000000 -> 100000000000000000000000000000000 +dqxor012 xor 0100000000000000000000000000000000 0000000000000000000000000000000000 -> 100000000000000000000000000000000 +dqxor013 xor 0100000000000000000000000000000000 0100000000000000000000000000000000 -> 0 + +-- Various lengths +-- 1234567890123456789012345678901234 +dqxor601 xor 0111111111111111111111111111111111 1111111111111111111111111111111111 -> 1000000000000000000000000000000000 +dqxor602 xor 1011111111111111111111111111111111 1111111111111111111111111111111111 -> 100000000000000000000000000000000 +dqxor603 xor 1101111111111111111111111111111111 1111111111111111111111111111111111 -> 10000000000000000000000000000000 +dqxor604 xor 1110111111111111111111111111111111 1111111111111111111111111111111111 -> 1000000000000000000000000000000 +dqxor605 xor 1111011111111111111111111111111111 1111111111111111111111111111111111 -> 100000000000000000000000000000 +dqxor606 xor 1111101111111111111111111111111111 1111111111111111111111111111111111 -> 10000000000000000000000000000 +dqxor607 xor 1111110111111111111111111111111111 1111111111111111111111111111111111 -> 1000000000000000000000000000 +dqxor608 xor 1111111011111111111111111111111111 1111111111111111111111111111111111 -> 100000000000000000000000000 +dqxor609 xor 1111111101111111111111111111111111 1111111111111111111111111111111111 -> 10000000000000000000000000 +dqxor610 xor 1111111110111111111111111111111111 1111111111111111111111111111111111 -> 1000000000000000000000000 +dqxor611 xor 1111111111011111111111111111111111 1111111111111111111111111111111111 -> 100000000000000000000000 +dqxor612 xor 1111111111101111111111111111111111 1111111111111111111111111111111111 -> 10000000000000000000000 +dqxor613 xor 1111111111110111111111111111111111 1111111111111111111111111111111111 -> 1000000000000000000000 +dqxor614 xor 1111111111111011111111111111111111 1111111111111111111111111111111111 -> 100000000000000000000 +dqxor615 xor 1111111111111101111111111111111111 1111111111111111111111111111111111 -> 10000000000000000000 +dqxor616 xor 1111111111111110111111111111111111 1111111111111111111111111111111111 -> 1000000000000000000 +dqxor617 xor 1111111111111111011111111111111111 1111111111111111111111111111111111 -> 100000000000000000 +dqxor618 xor 1111111111111111101111111111111111 1111111111111111111111111111111111 -> 10000000000000000 +dqxor619 xor 1111111111111111110111111111111111 1111111111111111111111111111111111 -> 1000000000000000 +dqxor620 xor 1111111111111111111011111111111111 1111111111111111111111111111111111 -> 100000000000000 +dqxor621 xor 1111111111111111111101111111111111 1111111111111111111111111111111111 -> 10000000000000 +dqxor622 xor 1111111111111111111110111111111111 1111111111111111111111111111111111 -> 1000000000000 +dqxor623 xor 1111111111111111111111011111111111 1111111111111111111111111111111111 -> 100000000000 +dqxor624 xor 1111111111111111111111101111111111 1111111111111111111111111111111111 -> 10000000000 +dqxor625 xor 1111111111111111111111110111111111 1111111111111111111111111111111111 -> 1000000000 +dqxor626 xor 1111111111111111111111111011111111 1111111111111111111111111111111111 -> 100000000 +dqxor627 xor 1111111111111111111111111101111111 1111111111111111111111111111111111 -> 10000000 +dqxor628 xor 1111111111111111111111111110111111 1111111111111111111111111111111111 -> 1000000 +dqxor629 xor 1111111111111111111111111111011111 1111111111111111111111111111111111 -> 100000 +dqxor630 xor 1111111111111111111111111111101111 1111111111111111111111111111111111 -> 10000 +dqxor631 xor 1111111111111111111111111111110111 1111111111111111111111111111111111 -> 1000 +dqxor632 xor 1111111111111111111111111111111011 1111111111111111111111111111111111 -> 100 +dqxor633 xor 1111111111111111111111111111111101 1111111111111111111111111111111111 -> 10 +dqxor634 xor 1111111111111111111111111111111110 1111111111111111111111111111111111 -> 1 + +dqxor641 xor 1111111111111111111111111111111111 0111111111111111111111111111111111 -> 1000000000000000000000000000000000 +dqxor642 xor 1111111111111111111111111111111111 1011111111111111111111111111111111 -> 100000000000000000000000000000000 +dqxor643 xor 1111111111111111111111111111111111 1101111111111111111111111111111111 -> 10000000000000000000000000000000 +dqxor644 xor 1111111111111111111111111111111111 1110111111111111111111111111111111 -> 1000000000000000000000000000000 +dqxor645 xor 1111111111111111111111111111111111 1111011111111111111111111111111111 -> 100000000000000000000000000000 +dqxor646 xor 1111111111111111111111111111111111 1111101111111111111111111111111111 -> 10000000000000000000000000000 +dqxor647 xor 1111111111111111111111111111111111 1111110111111111111111111111111111 -> 1000000000000000000000000000 +dqxor648 xor 1111111111111111111111111111111111 1111111011111111111111111111111111 -> 100000000000000000000000000 +dqxor649 xor 1111111111111111111111111111111111 1111111101111111111111111111111111 -> 10000000000000000000000000 +dqxor650 xor 1111111111111111111111111111111111 1111111110111111111111111111111111 -> 1000000000000000000000000 +dqxor651 xor 1111111111111111111111111111111111 1111111111011111111111111111111111 -> 100000000000000000000000 +dqxor652 xor 1111111111111111111111111111111111 1111111111101111111111111111111111 -> 10000000000000000000000 +dqxor653 xor 1111111111111111111111111111111111 1111111111110111111111111111111111 -> 1000000000000000000000 +dqxor654 xor 1111111111111111111111111111111111 1111111111111011111111111111111111 -> 100000000000000000000 +dqxor655 xor 1111111111111111111111111111111111 1111111111111101111111111111111111 -> 10000000000000000000 +dqxor656 xor 1111111111111111111111111111111111 1111111111111110111111111111111111 -> 1000000000000000000 +dqxor657 xor 1111111111111111111111111111111111 1111111111111111011111111111111111 -> 100000000000000000 +dqxor658 xor 1111111111111111111111111111111111 1111111111111111101111111111111111 -> 10000000000000000 +dqxor659 xor 1111111111111111111111111111111111 1111111111111111110111111111111111 -> 1000000000000000 +dqxor660 xor 1111111111111111111111111111111111 1111111111111111111011111111111111 -> 100000000000000 +dqxor661 xor 1111111111111111111111111111111111 1111111111111111111101111111111111 -> 10000000000000 +dqxor662 xor 1111111111111111111111111111111111 1111111111111111111110111111111111 -> 1000000000000 +dqxor663 xor 1111111111111111111111111111111111 1111111111111111111111011111111111 -> 100000000000 +dqxor664 xor 1111111111111111111111111111111111 1111111111111111111111101111111111 -> 10000000000 +dqxor665 xor 1111111111111111111111111111111111 1111111111111111111111110111111111 -> 1000000000 +dqxor666 xor 1111111111111111111111111111111111 1111111111111111111111111011111111 -> 100000000 +dqxor667 xor 1111111111111111111111111111111111 1111111111111111111111111101111111 -> 10000000 +dqxor668 xor 1111111111111111111111111111111111 1111111111111111111111111110111111 -> 1000000 +dqxor669 xor 1111111111111111111111111111111111 1111111111111111111111111111011111 -> 100000 +dqxor670 xor 1111111111111111111111111111111111 1111111111111111111111111111101111 -> 10000 +dqxor671 xor 1111111111111111111111111111111111 1111111111111111111111111111110111 -> 1000 +dqxor672 xor 1111111111111111111111111111111111 1111111111111111111111111111111011 -> 100 +dqxor673 xor 1111111111111111111111111111111111 1111111111111111111111111111111101 -> 10 +dqxor674 xor 1111111111111111111111111111111111 1111111111111111111111111111111110 -> 1 +dqxor675 xor 0111111111111111111111111111111111 1111111111111111111111111111111110 -> 1000000000000000000000000000000001 +dqxor676 xor 1111111111111111111111111111111111 1111111111111111111111111111111110 -> 1 + + +dqxor021 xor 1111111110000000 1111111110000000 -> 0 +dqxor022 xor 111111110000000 111111110000000 -> 0 +dqxor023 xor 11111110000000 11111110000000 -> 0 +dqxor024 xor 1111110000000 1111110000000 -> 0 +dqxor025 xor 111110000000 111110000000 -> 0 +dqxor026 xor 11110000000 11110000000 -> 0 +dqxor027 xor 1110000000 1110000000 -> 0 +dqxor028 xor 110000000 110000000 -> 0 +dqxor029 xor 10000000 10000000 -> 0 +dqxor030 xor 1000000 1000000 -> 0 +dqxor031 xor 100000 100000 -> 0 +dqxor032 xor 10000 10000 -> 0 +dqxor033 xor 1000 1000 -> 0 +dqxor034 xor 100 100 -> 0 +dqxor035 xor 10 10 -> 0 +dqxor036 xor 1 1 -> 0 + +dqxor040 xor 111111111 111111111111 -> 111000000000 +dqxor041 xor 11111111 111111111111 -> 111100000000 +dqxor042 xor 11111111 111111111 -> 100000000 +dqxor043 xor 1111111 100000010 -> 101111101 +dqxor044 xor 111111 100000100 -> 100111011 +dqxor045 xor 11111 100001000 -> 100010111 +dqxor046 xor 1111 100010000 -> 100011111 +dqxor047 xor 111 100100000 -> 100100111 +dqxor048 xor 11 101000000 -> 101000011 +dqxor049 xor 1 110000000 -> 110000001 + +dqxor050 xor 1111111111 1 -> 1111111110 +dqxor051 xor 111111111 1 -> 111111110 +dqxor052 xor 11111111 1 -> 11111110 +dqxor053 xor 1111111 1 -> 1111110 +dqxor054 xor 111111 1 -> 111110 +dqxor055 xor 11111 1 -> 11110 +dqxor056 xor 1111 1 -> 1110 +dqxor057 xor 111 1 -> 110 +dqxor058 xor 11 1 -> 10 +dqxor059 xor 1 1 -> 0 + +dqxor060 xor 1111111111 0 -> 1111111111 +dqxor061 xor 111111111 0 -> 111111111 +dqxor062 xor 11111111 0 -> 11111111 +dqxor063 xor 1111111 0 -> 1111111 +dqxor064 xor 111111 0 -> 111111 +dqxor065 xor 11111 0 -> 11111 +dqxor066 xor 1111 0 -> 1111 +dqxor067 xor 111 0 -> 111 +dqxor068 xor 11 0 -> 11 +dqxor069 xor 1 0 -> 1 + +dqxor070 xor 1 1111111111 -> 1111111110 +dqxor071 xor 1 111111111 -> 111111110 +dqxor072 xor 1 11111111 -> 11111110 +dqxor073 xor 1 1111111 -> 1111110 +dqxor074 xor 1 111111 -> 111110 +dqxor075 xor 1 11111 -> 11110 +dqxor076 xor 1 1111 -> 1110 +dqxor077 xor 1 111 -> 110 +dqxor078 xor 1 11 -> 10 +dqxor079 xor 1 1 -> 0 + +dqxor080 xor 0 1111111111 -> 1111111111 +dqxor081 xor 0 111111111 -> 111111111 +dqxor082 xor 0 11111111 -> 11111111 +dqxor083 xor 0 1111111 -> 1111111 +dqxor084 xor 0 111111 -> 111111 +dqxor085 xor 0 11111 -> 11111 +dqxor086 xor 0 1111 -> 1111 +dqxor087 xor 0 111 -> 111 +dqxor088 xor 0 11 -> 11 +dqxor089 xor 0 1 -> 1 + +dqxor090 xor 011111111 111101111 -> 100010000 +dqxor091 xor 101111111 111101111 -> 10010000 +dqxor092 xor 110111111 111101111 -> 1010000 +dqxor093 xor 111011111 111101111 -> 110000 +dqxor094 xor 111101111 111101111 -> 0 +dqxor095 xor 111110111 111101111 -> 11000 +dqxor096 xor 111111011 111101111 -> 10100 +dqxor097 xor 111111101 111101111 -> 10010 +dqxor098 xor 111111110 111101111 -> 10001 + +dqxor100 xor 111101111 011111111 -> 100010000 +dqxor101 xor 111101111 101111111 -> 10010000 +dqxor102 xor 111101111 110111111 -> 1010000 +dqxor103 xor 111101111 111011111 -> 110000 +dqxor104 xor 111101111 111101111 -> 0 +dqxor105 xor 111101111 111110111 -> 11000 +dqxor106 xor 111101111 111111011 -> 10100 +dqxor107 xor 111101111 111111101 -> 10010 +dqxor108 xor 111101111 111111110 -> 10001 + +-- non-0/1 should not be accepted, nor should signs +dqxor220 xor 111111112 111111111 -> NaN Invalid_operation +dqxor221 xor 333333333 333333333 -> NaN Invalid_operation +dqxor222 xor 555555555 555555555 -> NaN Invalid_operation +dqxor223 xor 777777777 777777777 -> NaN Invalid_operation +dqxor224 xor 999999999 999999999 -> NaN Invalid_operation +dqxor225 xor 222222222 999999999 -> NaN Invalid_operation +dqxor226 xor 444444444 999999999 -> NaN Invalid_operation +dqxor227 xor 666666666 999999999 -> NaN Invalid_operation +dqxor228 xor 888888888 999999999 -> NaN Invalid_operation +dqxor229 xor 999999999 222222222 -> NaN Invalid_operation +dqxor230 xor 999999999 444444444 -> NaN Invalid_operation +dqxor231 xor 999999999 666666666 -> NaN Invalid_operation +dqxor232 xor 999999999 888888888 -> NaN Invalid_operation +-- a few randoms +dqxor240 xor 567468689 -934981942 -> NaN Invalid_operation +dqxor241 xor 567367689 934981942 -> NaN Invalid_operation +dqxor242 xor -631917772 -706014634 -> NaN Invalid_operation +dqxor243 xor -756253257 138579234 -> NaN Invalid_operation +dqxor244 xor 835590149 567435400 -> NaN Invalid_operation +-- test MSD +dqxor250 xor 2000000111000111000111000000000000 1000000111000111000111000000000000 -> NaN Invalid_operation +dqxor251 xor 7000000111000111000111000000000000 1000000111000111000111000000000000 -> NaN Invalid_operation +dqxor252 xor 8000000111000111000111000000000000 1000000111000111000111000000000000 -> NaN Invalid_operation +dqxor253 xor 9000000111000111000111000000000000 1000000111000111000111000000000000 -> NaN Invalid_operation +dqxor254 xor 2000000111000111000111000000000000 0000000111000111000111000000000000 -> NaN Invalid_operation +dqxor255 xor 7000000111000111000111000000000000 0000000111000111000111000000000000 -> NaN Invalid_operation +dqxor256 xor 8000000111000111000111000000000000 0000000111000111000111000000000000 -> NaN Invalid_operation +dqxor257 xor 9000000111000111000111000000000000 0000000111000111000111000000000000 -> NaN Invalid_operation +dqxor258 xor 1000000111000111000111000000000000 2000000111000111000111000000000000 -> NaN Invalid_operation +dqxor259 xor 1000000111000111000111000000000000 7000000111000111000111000000000000 -> NaN Invalid_operation +dqxor260 xor 1000000111000111000111000000000000 8000000111000111000111000000000000 -> NaN Invalid_operation +dqxor261 xor 1000000111000111000111000000000000 9000000111000111000111000000000000 -> NaN Invalid_operation +dqxor262 xor 0000000111000111000111000000000000 2000000111000111000111000000000000 -> NaN Invalid_operation +dqxor263 xor 0000000111000111000111000000000000 7000000111000111000111000000000000 -> NaN Invalid_operation +dqxor264 xor 0000000111000111000111000000000000 8000000111000111000111000000000000 -> NaN Invalid_operation +dqxor265 xor 0000000111000111000111000000000000 9000000111000111000111000000000000 -> NaN Invalid_operation +-- test MSD-1 +dqxor270 xor 0200000111000111000111001000000000 1000000111000111000111100000000010 -> NaN Invalid_operation +dqxor271 xor 0700000111000111000111000100000000 1000000111000111000111010000000100 -> NaN Invalid_operation +dqxor272 xor 0800000111000111000111000010000000 1000000111000111000111001000001000 -> NaN Invalid_operation +dqxor273 xor 0900000111000111000111000001000000 1000000111000111000111000100010000 -> NaN Invalid_operation +dqxor274 xor 1000000111000111000111000000100000 0200000111000111000111000010100000 -> NaN Invalid_operation +dqxor275 xor 1000000111000111000111000000010000 0700000111000111000111000001000000 -> NaN Invalid_operation +dqxor276 xor 1000000111000111000111000000001000 0800000111000111000111000010100000 -> NaN Invalid_operation +dqxor277 xor 1000000111000111000111000000000100 0900000111000111000111000000010000 -> NaN Invalid_operation +-- test LSD +dqxor280 xor 0010000111000111000111000000000002 1000000111000111000111000100000001 -> NaN Invalid_operation +dqxor281 xor 0001000111000111000111000000000007 1000000111000111000111001000000011 -> NaN Invalid_operation +dqxor282 xor 0000000111000111000111100000000008 1000000111000111000111010000000001 -> NaN Invalid_operation +dqxor283 xor 0000000111000111000111010000000009 1000000111000111000111100000000001 -> NaN Invalid_operation +dqxor284 xor 1000000111000111000111001000000000 0001000111000111000111000000000002 -> NaN Invalid_operation +dqxor285 xor 1000000111000111000111000100000000 0010000111000111000111000000000007 -> NaN Invalid_operation +dqxor286 xor 1000000111000111000111000010000000 0100000111000111000111000000000008 -> NaN Invalid_operation +dqxor287 xor 1000000111000111000111000001000000 1000000111000111000111000000000009 -> NaN Invalid_operation +-- test Middie +dqxor288 xor 0010000111000111000111000020000000 1000000111000111000111001000000000 -> NaN Invalid_operation +dqxor289 xor 0001000111000111000111000070000001 1000000111000111000111000100000000 -> NaN Invalid_operation +dqxor290 xor 0000000111000111000111100080000010 1000000111000111000111000010000000 -> NaN Invalid_operation +dqxor291 xor 0000000111000111000111010090000100 1000000111000111000111000001000000 -> NaN Invalid_operation +dqxor292 xor 1000000111000111000111001000001000 0000000111000111000111000020100000 -> NaN Invalid_operation +dqxor293 xor 1000000111000111000111000100010000 0000000111000111000111000070010000 -> NaN Invalid_operation +dqxor294 xor 1000000111000111000111000010100000 0000000111000111000111000080001000 -> NaN Invalid_operation +dqxor295 xor 1000000111000111000111000001000000 0000000111000111000111000090000100 -> NaN Invalid_operation +-- signs +dqxor296 xor -1000000111000111000111000001000000 -0000001110001110001110010000000100 -> NaN Invalid_operation +dqxor297 xor -1000000111000111000111000001000000 0000001110001110001110000010000100 -> NaN Invalid_operation +dqxor298 xor 1000000111000111000111000001000000 -0000001110001110001110001000000100 -> NaN Invalid_operation +dqxor299 xor 1000000111000111000111000001000000 0000001110001110001110000011000100 -> 1000001001001001001001000010000100 + +-- Nmax, Nmin, Ntiny-like +dqxor331 xor 2 9.99999999E+999 -> NaN Invalid_operation +dqxor332 xor 3 1E-999 -> NaN Invalid_operation +dqxor333 xor 4 1.00000000E-2821 -> NaN Invalid_operation +dqxor334 xor 5 1E-900 -> NaN Invalid_operation +dqxor335 xor 6 -1E-900 -> NaN Invalid_operation +dqxor336 xor 7 -1.00000000E-999 -> NaN Invalid_operation +dqxor337 xor 8 -1E-999 -> NaN Invalid_operation +dqxor338 xor 9 -9.99999999E+999 -> NaN Invalid_operation +dqxor341 xor 9.99999999E+999 -18 -> NaN Invalid_operation +dqxor342 xor 1E-999 01 -> NaN Invalid_operation +dqxor343 xor 1.00000000E-999 -18 -> NaN Invalid_operation +dqxor344 xor 1E-908 18 -> NaN Invalid_operation +dqxor345 xor -1E-907 -10 -> NaN Invalid_operation +dqxor346 xor -1.00000000E-999 18 -> NaN Invalid_operation +dqxor347 xor -1E-999 10 -> NaN Invalid_operation +dqxor348 xor -9.99999999E+2991 -18 -> NaN Invalid_operation + +-- A few other non-integers +dqxor361 xor 1.0 1 -> NaN Invalid_operation +dqxor362 xor 1E+1 1 -> NaN Invalid_operation +dqxor363 xor 0.0 1 -> NaN Invalid_operation +dqxor364 xor 0E+1 1 -> NaN Invalid_operation +dqxor365 xor 9.9 1 -> NaN Invalid_operation +dqxor366 xor 9E+1 1 -> NaN Invalid_operation +dqxor371 xor 0 1.0 -> NaN Invalid_operation +dqxor372 xor 0 1E+1 -> NaN Invalid_operation +dqxor373 xor 0 0.0 -> NaN Invalid_operation +dqxor374 xor 0 0E+1 -> NaN Invalid_operation +dqxor375 xor 0 9.9 -> NaN Invalid_operation +dqxor376 xor 0 9E+1 -> NaN Invalid_operation + +-- All Specials are in error +dqxor780 xor -Inf -Inf -> NaN Invalid_operation +dqxor781 xor -Inf -1000 -> NaN Invalid_operation +dqxor782 xor -Inf -1 -> NaN Invalid_operation +dqxor783 xor -Inf -0 -> NaN Invalid_operation +dqxor784 xor -Inf 0 -> NaN Invalid_operation +dqxor785 xor -Inf 1 -> NaN Invalid_operation +dqxor786 xor -Inf 1000 -> NaN Invalid_operation +dqxor787 xor -1000 -Inf -> NaN Invalid_operation +dqxor788 xor -Inf -Inf -> NaN Invalid_operation +dqxor789 xor -1 -Inf -> NaN Invalid_operation +dqxor790 xor -0 -Inf -> NaN Invalid_operation +dqxor791 xor 0 -Inf -> NaN Invalid_operation +dqxor792 xor 1 -Inf -> NaN Invalid_operation +dqxor793 xor 1000 -Inf -> NaN Invalid_operation +dqxor794 xor Inf -Inf -> NaN Invalid_operation + +dqxor800 xor Inf -Inf -> NaN Invalid_operation +dqxor801 xor Inf -1000 -> NaN Invalid_operation +dqxor802 xor Inf -1 -> NaN Invalid_operation +dqxor803 xor Inf -0 -> NaN Invalid_operation +dqxor804 xor Inf 0 -> NaN Invalid_operation +dqxor805 xor Inf 1 -> NaN Invalid_operation +dqxor806 xor Inf 1000 -> NaN Invalid_operation +dqxor807 xor Inf Inf -> NaN Invalid_operation +dqxor808 xor -1000 Inf -> NaN Invalid_operation +dqxor809 xor -Inf Inf -> NaN Invalid_operation +dqxor810 xor -1 Inf -> NaN Invalid_operation +dqxor811 xor -0 Inf -> NaN Invalid_operation +dqxor812 xor 0 Inf -> NaN Invalid_operation +dqxor813 xor 1 Inf -> NaN Invalid_operation +dqxor814 xor 1000 Inf -> NaN Invalid_operation +dqxor815 xor Inf Inf -> NaN Invalid_operation + +dqxor821 xor NaN -Inf -> NaN Invalid_operation +dqxor822 xor NaN -1000 -> NaN Invalid_operation +dqxor823 xor NaN -1 -> NaN Invalid_operation +dqxor824 xor NaN -0 -> NaN Invalid_operation +dqxor825 xor NaN 0 -> NaN Invalid_operation +dqxor826 xor NaN 1 -> NaN Invalid_operation +dqxor827 xor NaN 1000 -> NaN Invalid_operation +dqxor828 xor NaN Inf -> NaN Invalid_operation +dqxor829 xor NaN NaN -> NaN Invalid_operation +dqxor830 xor -Inf NaN -> NaN Invalid_operation +dqxor831 xor -1000 NaN -> NaN Invalid_operation +dqxor832 xor -1 NaN -> NaN Invalid_operation +dqxor833 xor -0 NaN -> NaN Invalid_operation +dqxor834 xor 0 NaN -> NaN Invalid_operation +dqxor835 xor 1 NaN -> NaN Invalid_operation +dqxor836 xor 1000 NaN -> NaN Invalid_operation +dqxor837 xor Inf NaN -> NaN Invalid_operation + +dqxor841 xor sNaN -Inf -> NaN Invalid_operation +dqxor842 xor sNaN -1000 -> NaN Invalid_operation +dqxor843 xor sNaN -1 -> NaN Invalid_operation +dqxor844 xor sNaN -0 -> NaN Invalid_operation +dqxor845 xor sNaN 0 -> NaN Invalid_operation +dqxor846 xor sNaN 1 -> NaN Invalid_operation +dqxor847 xor sNaN 1000 -> NaN Invalid_operation +dqxor848 xor sNaN NaN -> NaN Invalid_operation +dqxor849 xor sNaN sNaN -> NaN Invalid_operation +dqxor850 xor NaN sNaN -> NaN Invalid_operation +dqxor851 xor -Inf sNaN -> NaN Invalid_operation +dqxor852 xor -1000 sNaN -> NaN Invalid_operation +dqxor853 xor -1 sNaN -> NaN Invalid_operation +dqxor854 xor -0 sNaN -> NaN Invalid_operation +dqxor855 xor 0 sNaN -> NaN Invalid_operation +dqxor856 xor 1 sNaN -> NaN Invalid_operation +dqxor857 xor 1000 sNaN -> NaN Invalid_operation +dqxor858 xor Inf sNaN -> NaN Invalid_operation +dqxor859 xor NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +dqxor861 xor NaN1 -Inf -> NaN Invalid_operation +dqxor862 xor +NaN2 -1000 -> NaN Invalid_operation +dqxor863 xor NaN3 1000 -> NaN Invalid_operation +dqxor864 xor NaN4 Inf -> NaN Invalid_operation +dqxor865 xor NaN5 +NaN6 -> NaN Invalid_operation +dqxor866 xor -Inf NaN7 -> NaN Invalid_operation +dqxor867 xor -1000 NaN8 -> NaN Invalid_operation +dqxor868 xor 1000 NaN9 -> NaN Invalid_operation +dqxor869 xor Inf +NaN10 -> NaN Invalid_operation +dqxor871 xor sNaN11 -Inf -> NaN Invalid_operation +dqxor872 xor sNaN12 -1000 -> NaN Invalid_operation +dqxor873 xor sNaN13 1000 -> NaN Invalid_operation +dqxor874 xor sNaN14 NaN17 -> NaN Invalid_operation +dqxor875 xor sNaN15 sNaN18 -> NaN Invalid_operation +dqxor876 xor NaN16 sNaN19 -> NaN Invalid_operation +dqxor877 xor -Inf +sNaN20 -> NaN Invalid_operation +dqxor878 xor -1000 sNaN21 -> NaN Invalid_operation +dqxor879 xor 1000 sNaN22 -> NaN Invalid_operation +dqxor880 xor Inf sNaN23 -> NaN Invalid_operation +dqxor881 xor +NaN25 +sNaN24 -> NaN Invalid_operation +dqxor882 xor -NaN26 NaN28 -> NaN Invalid_operation +dqxor883 xor -sNaN27 sNaN29 -> NaN Invalid_operation +dqxor884 xor 1000 -NaN30 -> NaN Invalid_operation +dqxor885 xor 1000 -sNaN31 -> NaN Invalid_operation Added: python/branches/release25-maint/Lib/test/decimaltestdata/dsBase.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/dsBase.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,1062 @@ +------------------------------------------------------------------------ +-- dsBase.decTest -- base decSingle <--> string conversions -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- This file tests base conversions from string to a decimal number +-- and back to a string (in Scientific form) + +-- Note that unlike other operations the operand is subject to rounding +-- to conform to emax and precision settings (that is, numbers will +-- conform to rules and exponent will be in permitted range). The +-- 'left hand side', therefore, may have numbers that cannot be +-- represented in a decSingle. Some testcases go to the limit of the +-- next-wider format, and hence these testcases may also be used to +-- test narrowing and widening operations. + +extended: 1 +clamp: 1 +precision: 7 +maxExponent: 96 +minExponent: -95 +rounding: half_even + +dsbas001 toSci 0 -> 0 +dsbas002 toSci 1 -> 1 +dsbas003 toSci 1.0 -> 1.0 +dsbas004 toSci 1.00 -> 1.00 +dsbas005 toSci 10 -> 10 +dsbas006 toSci 1000 -> 1000 +dsbas007 toSci 10.0 -> 10.0 +dsbas008 toSci 10.1 -> 10.1 +dsbas009 toSci 10.4 -> 10.4 +dsbas010 toSci 10.5 -> 10.5 +dsbas011 toSci 10.6 -> 10.6 +dsbas012 toSci 10.9 -> 10.9 +dsbas013 toSci 11.0 -> 11.0 +dsbas014 toSci 1.234 -> 1.234 +dsbas015 toSci 0.123 -> 0.123 +dsbas016 toSci 0.012 -> 0.012 +dsbas017 toSci -0 -> -0 +dsbas018 toSci -0.0 -> -0.0 +dsbas019 toSci -00.00 -> -0.00 + +dsbas021 toSci -1 -> -1 +dsbas022 toSci -1.0 -> -1.0 +dsbas023 toSci -0.1 -> -0.1 +dsbas024 toSci -9.1 -> -9.1 +dsbas025 toSci -9.11 -> -9.11 +dsbas026 toSci -9.119 -> -9.119 +dsbas027 toSci -9.999 -> -9.999 + +dsbas030 toSci '1234.567' -> '1234.567' +dsbas031 toSci '1234.000' -> '1234.000' +dsbas032 toSci '1234912' -> '1234912' +dsbas033 toSci '0.00001234567' -> '0.00001234567' +dsbas034 toSci '0.000001234567' -> '0.000001234567' +dsbas035 toSci '0.0000001234567' -> '1.234567E-7' +dsbas036 toSci '0.00000001234567' -> '1.234567E-8' + +dsbas037 toSci '0.1234564' -> '0.1234564' +dsbas038 toSci '0.1234565' -> '0.1234565' + +-- test finite bounds (Negs of, then 0, Ntiny, Nmin, other, Nmax) +dsbsn001 toSci -9.999999E+96 -> -9.999999E+96 +dsbsn002 toSci -1E-95 -> -1E-95 +dsbsn003 toSci -1E-101 -> -1E-101 Subnormal +dsbsn004 toSci -0 -> -0 +dsbsn005 toSci +0 -> 0 +dsbsn006 toSci +1E-101 -> 1E-101 Subnormal +dsbsn007 toSci +1E-95 -> 1E-95 +dsbsn008 toSci +9.999999E+96 -> 9.999999E+96 + +-- String [many more examples are implicitly tested elsewhere] +-- strings without E cannot generate E in result +dsbas040 toSci "12" -> '12' +dsbas041 toSci "-76" -> '-76' +dsbas042 toSci "12.76" -> '12.76' +dsbas043 toSci "+12.76" -> '12.76' +dsbas044 toSci "012.76" -> '12.76' +dsbas045 toSci "+0.003" -> '0.003' +dsbas046 toSci "17." -> '17' +dsbas047 toSci ".5" -> '0.5' +dsbas048 toSci "044" -> '44' +dsbas049 toSci "0044" -> '44' +dsbas050 toSci "0.0005" -> '0.0005' +dsbas051 toSci "00.00005" -> '0.00005' +dsbas052 toSci "0.000005" -> '0.000005' +dsbas053 toSci "0.0000050" -> '0.0000050' +dsbas054 toSci "0.0000005" -> '5E-7' +dsbas055 toSci "0.00000005" -> '5E-8' +dsbas056 toSci "12678.54" -> '12678.54' +dsbas057 toSci "2678.543" -> '2678.543' +dsbas058 toSci "345678.5" -> '345678.5' +dsbas059 toSci "0678.5432" -> '678.5432' +dsbas060 toSci "678.5432" -> '678.5432' +dsbas061 toSci "+678.5432" -> '678.5432' +dsbas062 toSci "+0678.5432" -> '678.5432' +dsbas063 toSci "+00678.5432" -> '678.5432' +dsbas064 toSci "-678.5432" -> '-678.5432' +dsbas065 toSci "-0678.5432" -> '-678.5432' +dsbas066 toSci "-00678.5432" -> '-678.5432' +-- examples +dsbas067 toSci "5E-6" -> '0.000005' +dsbas068 toSci "50E-7" -> '0.0000050' +dsbas069 toSci "5E-7" -> '5E-7' + +-- [No exotics as no Unicode] + +-- rounded with dots in all (including edge) places +dsbas071 toSci .1234567890123456 -> 0.1234568 Inexact Rounded +dsbas072 toSci 1.234567890123456 -> 1.234568 Inexact Rounded +dsbas073 toSci 12.34567890123456 -> 12.34568 Inexact Rounded +dsbas074 toSci 123.4567890123456 -> 123.4568 Inexact Rounded +dsbas075 toSci 1234.567890123456 -> 1234.568 Inexact Rounded +dsbas076 toSci 12345.67890123456 -> 12345.68 Inexact Rounded +dsbas077 toSci 123456.7890123456 -> 123456.8 Inexact Rounded +dsbas078 toSci 1234567.890123456 -> 1234568 Inexact Rounded +dsbas079 toSci 12345678.90123456 -> 1.234568E+7 Inexact Rounded +dsbas080 toSci 123456789.0123456 -> 1.234568E+8 Inexact Rounded +dsbas081 toSci 1234567890.123456 -> 1.234568E+9 Inexact Rounded +dsbas082 toSci 12345678901.23456 -> 1.234568E+10 Inexact Rounded +dsbas083 toSci 123456789012.3456 -> 1.234568E+11 Inexact Rounded +dsbas084 toSci 1234567890123.456 -> 1.234568E+12 Inexact Rounded +dsbas085 toSci 12345678901234.56 -> 1.234568E+13 Inexact Rounded +dsbas086 toSci 123456789012345.6 -> 1.234568E+14 Inexact Rounded +dsbas087 toSci 1234567890123456. -> 1.234568E+15 Inexact Rounded +dsbas088 toSci 1234567890123456 -> 1.234568E+15 Inexact Rounded + +-- Numbers with E +dsbas130 toSci "0.000E-1" -> '0.0000' +dsbas131 toSci "0.000E-2" -> '0.00000' +dsbas132 toSci "0.000E-3" -> '0.000000' +dsbas133 toSci "0.000E-4" -> '0E-7' +dsbas134 toSci "0.00E-2" -> '0.0000' +dsbas135 toSci "0.00E-3" -> '0.00000' +dsbas136 toSci "0.00E-4" -> '0.000000' +dsbas137 toSci "0.00E-5" -> '0E-7' +dsbas138 toSci "+0E+9" -> '0E+9' +dsbas139 toSci "-0E+9" -> '-0E+9' +dsbas140 toSci "1E+9" -> '1E+9' +dsbas141 toSci "1e+09" -> '1E+9' +dsbas142 toSci "1E+90" -> '1E+90' +dsbas143 toSci "+1E+009" -> '1E+9' +dsbas144 toSci "0E+9" -> '0E+9' +dsbas145 toSci "1E+9" -> '1E+9' +dsbas146 toSci "1E+09" -> '1E+9' +dsbas147 toSci "1e+90" -> '1E+90' +dsbas148 toSci "1E+009" -> '1E+9' +dsbas149 toSci "000E+9" -> '0E+9' +dsbas150 toSci "1E9" -> '1E+9' +dsbas151 toSci "1e09" -> '1E+9' +dsbas152 toSci "1E90" -> '1E+90' +dsbas153 toSci "1E009" -> '1E+9' +dsbas154 toSci "0E9" -> '0E+9' +dsbas155 toSci "0.000e+0" -> '0.000' +dsbas156 toSci "0.000E-1" -> '0.0000' +dsbas157 toSci "4E+9" -> '4E+9' +dsbas158 toSci "44E+9" -> '4.4E+10' +dsbas159 toSci "0.73e-7" -> '7.3E-8' +dsbas160 toSci "00E+9" -> '0E+9' +dsbas161 toSci "00E-9" -> '0E-9' +dsbas162 toSci "10E+9" -> '1.0E+10' +dsbas163 toSci "10E+09" -> '1.0E+10' +dsbas164 toSci "10e+90" -> '1.0E+91' +dsbas165 toSci "10E+009" -> '1.0E+10' +dsbas166 toSci "100e+9" -> '1.00E+11' +dsbas167 toSci "100e+09" -> '1.00E+11' +dsbas168 toSci "100E+90" -> '1.00E+92' +dsbas169 toSci "100e+009" -> '1.00E+11' + +dsbas170 toSci "1.265" -> '1.265' +dsbas171 toSci "1.265E-20" -> '1.265E-20' +dsbas172 toSci "1.265E-8" -> '1.265E-8' +dsbas173 toSci "1.265E-4" -> '0.0001265' +dsbas174 toSci "1.265E-3" -> '0.001265' +dsbas175 toSci "1.265E-2" -> '0.01265' +dsbas176 toSci "1.265E-1" -> '0.1265' +dsbas177 toSci "1.265E-0" -> '1.265' +dsbas178 toSci "1.265E+1" -> '12.65' +dsbas179 toSci "1.265E+2" -> '126.5' +dsbas180 toSci "1.265E+3" -> '1265' +dsbas181 toSci "1.265E+4" -> '1.265E+4' +dsbas182 toSci "1.265E+8" -> '1.265E+8' +dsbas183 toSci "1.265E+20" -> '1.265E+20' + +dsbas190 toSci "12.65" -> '12.65' +dsbas191 toSci "12.65E-20" -> '1.265E-19' +dsbas192 toSci "12.65E-8" -> '1.265E-7' +dsbas193 toSci "12.65E-4" -> '0.001265' +dsbas194 toSci "12.65E-3" -> '0.01265' +dsbas195 toSci "12.65E-2" -> '0.1265' +dsbas196 toSci "12.65E-1" -> '1.265' +dsbas197 toSci "12.65E-0" -> '12.65' +dsbas198 toSci "12.65E+1" -> '126.5' +dsbas199 toSci "12.65E+2" -> '1265' +dsbas200 toSci "12.65E+3" -> '1.265E+4' +dsbas201 toSci "12.65E+4" -> '1.265E+5' +dsbas202 toSci "12.65E+8" -> '1.265E+9' +dsbas203 toSci "12.65E+20" -> '1.265E+21' + +dsbas210 toSci "126.5" -> '126.5' +dsbas211 toSci "126.5E-20" -> '1.265E-18' +dsbas212 toSci "126.5E-8" -> '0.000001265' +dsbas213 toSci "126.5E-4" -> '0.01265' +dsbas214 toSci "126.5E-3" -> '0.1265' +dsbas215 toSci "126.5E-2" -> '1.265' +dsbas216 toSci "126.5E-1" -> '12.65' +dsbas217 toSci "126.5E-0" -> '126.5' +dsbas218 toSci "126.5E+1" -> '1265' +dsbas219 toSci "126.5E+2" -> '1.265E+4' +dsbas220 toSci "126.5E+3" -> '1.265E+5' +dsbas221 toSci "126.5E+4" -> '1.265E+6' +dsbas222 toSci "126.5E+8" -> '1.265E+10' +dsbas223 toSci "126.5E+20" -> '1.265E+22' + +dsbas230 toSci "1265" -> '1265' +dsbas231 toSci "1265E-20" -> '1.265E-17' +dsbas232 toSci "1265E-8" -> '0.00001265' +dsbas233 toSci "1265E-4" -> '0.1265' +dsbas234 toSci "1265E-3" -> '1.265' +dsbas235 toSci "1265E-2" -> '12.65' +dsbas236 toSci "1265E-1" -> '126.5' +dsbas237 toSci "1265E-0" -> '1265' +dsbas238 toSci "1265E+1" -> '1.265E+4' +dsbas239 toSci "1265E+2" -> '1.265E+5' +dsbas240 toSci "1265E+3" -> '1.265E+6' +dsbas241 toSci "1265E+4" -> '1.265E+7' +dsbas242 toSci "1265E+8" -> '1.265E+11' +dsbas243 toSci "1265E+20" -> '1.265E+23' + +dsbas250 toSci "0.1265" -> '0.1265' +dsbas251 toSci "0.1265E-20" -> '1.265E-21' +dsbas252 toSci "0.1265E-8" -> '1.265E-9' +dsbas253 toSci "0.1265E-4" -> '0.00001265' +dsbas254 toSci "0.1265E-3" -> '0.0001265' +dsbas255 toSci "0.1265E-2" -> '0.001265' +dsbas256 toSci "0.1265E-1" -> '0.01265' +dsbas257 toSci "0.1265E-0" -> '0.1265' +dsbas258 toSci "0.1265E+1" -> '1.265' +dsbas259 toSci "0.1265E+2" -> '12.65' +dsbas260 toSci "0.1265E+3" -> '126.5' +dsbas261 toSci "0.1265E+4" -> '1265' +dsbas262 toSci "0.1265E+8" -> '1.265E+7' +dsbas263 toSci "0.1265E+20" -> '1.265E+19' + +-- some more negative zeros [systematic tests below] +dsbas290 toSci "-0.000E-1" -> '-0.0000' +dsbas291 toSci "-0.000E-2" -> '-0.00000' +dsbas292 toSci "-0.000E-3" -> '-0.000000' +dsbas293 toSci "-0.000E-4" -> '-0E-7' +dsbas294 toSci "-0.00E-2" -> '-0.0000' +dsbas295 toSci "-0.00E-3" -> '-0.00000' +dsbas296 toSci "-0.0E-2" -> '-0.000' +dsbas297 toSci "-0.0E-3" -> '-0.0000' +dsbas298 toSci "-0E-2" -> '-0.00' +dsbas299 toSci "-0E-3" -> '-0.000' + +-- Engineering notation tests +dsbas301 toSci 10e12 -> 1.0E+13 +dsbas302 toEng 10e12 -> 10E+12 +dsbas303 toSci 10e11 -> 1.0E+12 +dsbas304 toEng 10e11 -> 1.0E+12 +dsbas305 toSci 10e10 -> 1.0E+11 +dsbas306 toEng 10e10 -> 100E+9 +dsbas307 toSci 10e9 -> 1.0E+10 +dsbas308 toEng 10e9 -> 10E+9 +dsbas309 toSci 10e8 -> 1.0E+9 +dsbas310 toEng 10e8 -> 1.0E+9 +dsbas311 toSci 10e7 -> 1.0E+8 +dsbas312 toEng 10e7 -> 100E+6 +dsbas313 toSci 10e6 -> 1.0E+7 +dsbas314 toEng 10e6 -> 10E+6 +dsbas315 toSci 10e5 -> 1.0E+6 +dsbas316 toEng 10e5 -> 1.0E+6 +dsbas317 toSci 10e4 -> 1.0E+5 +dsbas318 toEng 10e4 -> 100E+3 +dsbas319 toSci 10e3 -> 1.0E+4 +dsbas320 toEng 10e3 -> 10E+3 +dsbas321 toSci 10e2 -> 1.0E+3 +dsbas322 toEng 10e2 -> 1.0E+3 +dsbas323 toSci 10e1 -> 1.0E+2 +dsbas324 toEng 10e1 -> 100 +dsbas325 toSci 10e0 -> 10 +dsbas326 toEng 10e0 -> 10 +dsbas327 toSci 10e-1 -> 1.0 +dsbas328 toEng 10e-1 -> 1.0 +dsbas329 toSci 10e-2 -> 0.10 +dsbas330 toEng 10e-2 -> 0.10 +dsbas331 toSci 10e-3 -> 0.010 +dsbas332 toEng 10e-3 -> 0.010 +dsbas333 toSci 10e-4 -> 0.0010 +dsbas334 toEng 10e-4 -> 0.0010 +dsbas335 toSci 10e-5 -> 0.00010 +dsbas336 toEng 10e-5 -> 0.00010 +dsbas337 toSci 10e-6 -> 0.000010 +dsbas338 toEng 10e-6 -> 0.000010 +dsbas339 toSci 10e-7 -> 0.0000010 +dsbas340 toEng 10e-7 -> 0.0000010 +dsbas341 toSci 10e-8 -> 1.0E-7 +dsbas342 toEng 10e-8 -> 100E-9 +dsbas343 toSci 10e-9 -> 1.0E-8 +dsbas344 toEng 10e-9 -> 10E-9 +dsbas345 toSci 10e-10 -> 1.0E-9 +dsbas346 toEng 10e-10 -> 1.0E-9 +dsbas347 toSci 10e-11 -> 1.0E-10 +dsbas348 toEng 10e-11 -> 100E-12 +dsbas349 toSci 10e-12 -> 1.0E-11 +dsbas350 toEng 10e-12 -> 10E-12 +dsbas351 toSci 10e-13 -> 1.0E-12 +dsbas352 toEng 10e-13 -> 1.0E-12 + +dsbas361 toSci 7E12 -> 7E+12 +dsbas362 toEng 7E12 -> 7E+12 +dsbas363 toSci 7E11 -> 7E+11 +dsbas364 toEng 7E11 -> 700E+9 +dsbas365 toSci 7E10 -> 7E+10 +dsbas366 toEng 7E10 -> 70E+9 +dsbas367 toSci 7E9 -> 7E+9 +dsbas368 toEng 7E9 -> 7E+9 +dsbas369 toSci 7E8 -> 7E+8 +dsbas370 toEng 7E8 -> 700E+6 +dsbas371 toSci 7E7 -> 7E+7 +dsbas372 toEng 7E7 -> 70E+6 +dsbas373 toSci 7E6 -> 7E+6 +dsbas374 toEng 7E6 -> 7E+6 +dsbas375 toSci 7E5 -> 7E+5 +dsbas376 toEng 7E5 -> 700E+3 +dsbas377 toSci 7E4 -> 7E+4 +dsbas378 toEng 7E4 -> 70E+3 +dsbas379 toSci 7E3 -> 7E+3 +dsbas380 toEng 7E3 -> 7E+3 +dsbas381 toSci 7E2 -> 7E+2 +dsbas382 toEng 7E2 -> 700 +dsbas383 toSci 7E1 -> 7E+1 +dsbas384 toEng 7E1 -> 70 +dsbas385 toSci 7E0 -> 7 +dsbas386 toEng 7E0 -> 7 +dsbas387 toSci 7E-1 -> 0.7 +dsbas388 toEng 7E-1 -> 0.7 +dsbas389 toSci 7E-2 -> 0.07 +dsbas390 toEng 7E-2 -> 0.07 +dsbas391 toSci 7E-3 -> 0.007 +dsbas392 toEng 7E-3 -> 0.007 +dsbas393 toSci 7E-4 -> 0.0007 +dsbas394 toEng 7E-4 -> 0.0007 +dsbas395 toSci 7E-5 -> 0.00007 +dsbas396 toEng 7E-5 -> 0.00007 +dsbas397 toSci 7E-6 -> 0.000007 +dsbas398 toEng 7E-6 -> 0.000007 +dsbas399 toSci 7E-7 -> 7E-7 +dsbas400 toEng 7E-7 -> 700E-9 +dsbas401 toSci 7E-8 -> 7E-8 +dsbas402 toEng 7E-8 -> 70E-9 +dsbas403 toSci 7E-9 -> 7E-9 +dsbas404 toEng 7E-9 -> 7E-9 +dsbas405 toSci 7E-10 -> 7E-10 +dsbas406 toEng 7E-10 -> 700E-12 +dsbas407 toSci 7E-11 -> 7E-11 +dsbas408 toEng 7E-11 -> 70E-12 +dsbas409 toSci 7E-12 -> 7E-12 +dsbas410 toEng 7E-12 -> 7E-12 +dsbas411 toSci 7E-13 -> 7E-13 +dsbas412 toEng 7E-13 -> 700E-15 + +-- Exacts remain exact up to precision .. +dsbas420 toSci 100 -> 100 +dsbas422 toSci 1000 -> 1000 +dsbas424 toSci 999.9 -> 999.9 +dsbas426 toSci 1000.0 -> 1000.0 +dsbas428 toSci 1000.1 -> 1000.1 +dsbas430 toSci 10000 -> 10000 +dsbas432 toSci 1000 -> 1000 +dsbas434 toSci 10000 -> 10000 +dsbas436 toSci 100000 -> 100000 +dsbas438 toSci 1000000 -> 1000000 +dsbas440 toSci 10000000 -> 1.000000E+7 Rounded +dsbas442 toSci 10000000 -> 1.000000E+7 Rounded +dsbas444 toSci 10000003 -> 1.000000E+7 Rounded Inexact +dsbas446 toSci 10000005 -> 1.000000E+7 Rounded Inexact +dsbas448 toSci 100000050 -> 1.000000E+8 Rounded Inexact +dsbas450 toSci 10000009 -> 1.000001E+7 Rounded Inexact +dsbas452 toSci 100000000 -> 1.000000E+8 Rounded +dsbas454 toSci 100000003 -> 1.000000E+8 Rounded Inexact +dsbas456 toSci 100000005 -> 1.000000E+8 Rounded Inexact +dsbas458 toSci 100000009 -> 1.000000E+8 Rounded Inexact +dsbas460 toSci 1000000000 -> 1.000000E+9 Rounded +dsbas462 toSci 1000000300 -> 1.000000E+9 Rounded Inexact +dsbas464 toSci 1000000500 -> 1.000000E+9 Rounded Inexact +dsbas466 toSci 1000000900 -> 1.000001E+9 Rounded Inexact +dsbas468 toSci 10000000000 -> 1.000000E+10 Rounded +dsbas470 toSci 10000003000 -> 1.000000E+10 Rounded Inexact +dsbas472 toSci 10000005000 -> 1.000000E+10 Rounded Inexact +dsbas474 toSci 10000009000 -> 1.000001E+10 Rounded Inexact + +-- check rounding modes heeded +rounding: ceiling +dsbsr401 toSci 1.1123450 -> 1.112345 Rounded +dsbsr402 toSci 1.11234549 -> 1.112346 Rounded Inexact +dsbsr403 toSci 1.11234550 -> 1.112346 Rounded Inexact +dsbsr404 toSci 1.11234551 -> 1.112346 Rounded Inexact +rounding: up +dsbsr405 toSci 1.1123450 -> 1.112345 Rounded +dsbsr406 toSci 1.11234549 -> 1.112346 Rounded Inexact +dsbsr407 toSci 1.11234550 -> 1.112346 Rounded Inexact +dsbsr408 toSci 1.11234551 -> 1.112346 Rounded Inexact +rounding: floor +dsbsr410 toSci 1.1123450 -> 1.112345 Rounded +dsbsr411 toSci 1.11234549 -> 1.112345 Rounded Inexact +dsbsr412 toSci 1.11234550 -> 1.112345 Rounded Inexact +dsbsr413 toSci 1.11234551 -> 1.112345 Rounded Inexact +rounding: half_down +dsbsr415 toSci 1.1123450 -> 1.112345 Rounded +dsbsr416 toSci 1.11234549 -> 1.112345 Rounded Inexact +dsbsr417 toSci 1.11234550 -> 1.112345 Rounded Inexact +dsbsr418 toSci 1.11234650 -> 1.112346 Rounded Inexact +dsbsr419 toSci 1.11234551 -> 1.112346 Rounded Inexact +rounding: half_even +dsbsr421 toSci 1.1123450 -> 1.112345 Rounded +dsbsr422 toSci 1.11234549 -> 1.112345 Rounded Inexact +dsbsr423 toSci 1.11234550 -> 1.112346 Rounded Inexact +dsbsr424 toSci 1.11234650 -> 1.112346 Rounded Inexact +dsbsr425 toSci 1.11234551 -> 1.112346 Rounded Inexact +rounding: down +dsbsr426 toSci 1.1123450 -> 1.112345 Rounded +dsbsr427 toSci 1.11234549 -> 1.112345 Rounded Inexact +dsbsr428 toSci 1.11234550 -> 1.112345 Rounded Inexact +dsbsr429 toSci 1.11234551 -> 1.112345 Rounded Inexact +rounding: half_up +dsbsr431 toSci 1.1123450 -> 1.112345 Rounded +dsbsr432 toSci 1.11234549 -> 1.112345 Rounded Inexact +dsbsr433 toSci 1.11234550 -> 1.112346 Rounded Inexact +dsbsr434 toSci 1.11234650 -> 1.112347 Rounded Inexact +dsbsr435 toSci 1.11234551 -> 1.112346 Rounded Inexact +-- negatives +rounding: ceiling +dsbsr501 toSci -1.1123450 -> -1.112345 Rounded +dsbsr502 toSci -1.11234549 -> -1.112345 Rounded Inexact +dsbsr503 toSci -1.11234550 -> -1.112345 Rounded Inexact +dsbsr504 toSci -1.11234551 -> -1.112345 Rounded Inexact +rounding: up +dsbsr505 toSci -1.1123450 -> -1.112345 Rounded +dsbsr506 toSci -1.11234549 -> -1.112346 Rounded Inexact +dsbsr507 toSci -1.11234550 -> -1.112346 Rounded Inexact +dsbsr508 toSci -1.11234551 -> -1.112346 Rounded Inexact +rounding: floor +dsbsr510 toSci -1.1123450 -> -1.112345 Rounded +dsbsr511 toSci -1.11234549 -> -1.112346 Rounded Inexact +dsbsr512 toSci -1.11234550 -> -1.112346 Rounded Inexact +dsbsr513 toSci -1.11234551 -> -1.112346 Rounded Inexact +rounding: half_down +dsbsr515 toSci -1.1123450 -> -1.112345 Rounded +dsbsr516 toSci -1.11234549 -> -1.112345 Rounded Inexact +dsbsr517 toSci -1.11234550 -> -1.112345 Rounded Inexact +dsbsr518 toSci -1.11234650 -> -1.112346 Rounded Inexact +dsbsr519 toSci -1.11234551 -> -1.112346 Rounded Inexact +rounding: half_even +dsbsr521 toSci -1.1123450 -> -1.112345 Rounded +dsbsr522 toSci -1.11234549 -> -1.112345 Rounded Inexact +dsbsr523 toSci -1.11234550 -> -1.112346 Rounded Inexact +dsbsr524 toSci -1.11234650 -> -1.112346 Rounded Inexact +dsbsr525 toSci -1.11234551 -> -1.112346 Rounded Inexact +rounding: down +dsbsr526 toSci -1.1123450 -> -1.112345 Rounded +dsbsr527 toSci -1.11234549 -> -1.112345 Rounded Inexact +dsbsr528 toSci -1.11234550 -> -1.112345 Rounded Inexact +dsbsr529 toSci -1.11234551 -> -1.112345 Rounded Inexact +rounding: half_up +dsbsr531 toSci -1.1123450 -> -1.112345 Rounded +dsbsr532 toSci -1.11234549 -> -1.112345 Rounded Inexact +dsbsr533 toSci -1.11234550 -> -1.112346 Rounded Inexact +dsbsr534 toSci -1.11234650 -> -1.112347 Rounded Inexact +dsbsr535 toSci -1.11234551 -> -1.112346 Rounded Inexact + +rounding: half_even + +-- The 'baddies' tests from DiagBigDecimal, plus some new ones +dsbas500 toSci '1..2' -> NaN Conversion_syntax +dsbas501 toSci '.' -> NaN Conversion_syntax +dsbas502 toSci '..' -> NaN Conversion_syntax +dsbas503 toSci '++1' -> NaN Conversion_syntax +dsbas504 toSci '--1' -> NaN Conversion_syntax +dsbas505 toSci '-+1' -> NaN Conversion_syntax +dsbas506 toSci '+-1' -> NaN Conversion_syntax +dsbas507 toSci '12e' -> NaN Conversion_syntax +dsbas508 toSci '12e++' -> NaN Conversion_syntax +dsbas509 toSci '12f4' -> NaN Conversion_syntax +dsbas510 toSci ' +1' -> NaN Conversion_syntax +dsbas511 toSci '+ 1' -> NaN Conversion_syntax +dsbas512 toSci '12 ' -> NaN Conversion_syntax +dsbas513 toSci ' + 1' -> NaN Conversion_syntax +dsbas514 toSci ' - 1 ' -> NaN Conversion_syntax +dsbas515 toSci 'x' -> NaN Conversion_syntax +dsbas516 toSci '-1-' -> NaN Conversion_syntax +dsbas517 toSci '12-' -> NaN Conversion_syntax +dsbas518 toSci '3+' -> NaN Conversion_syntax +dsbas519 toSci '' -> NaN Conversion_syntax +dsbas520 toSci '1e-' -> NaN Conversion_syntax +dsbas521 toSci '7e99999a' -> NaN Conversion_syntax +dsbas522 toSci '7e123567890x' -> NaN Conversion_syntax +dsbas523 toSci '7e12356789012x' -> NaN Conversion_syntax +dsbas524 toSci '' -> NaN Conversion_syntax +dsbas525 toSci 'e100' -> NaN Conversion_syntax +dsbas526 toSci '\u0e5a' -> NaN Conversion_syntax +dsbas527 toSci '\u0b65' -> NaN Conversion_syntax +dsbas528 toSci '123,65' -> NaN Conversion_syntax +dsbas529 toSci '1.34.5' -> NaN Conversion_syntax +dsbas530 toSci '.123.5' -> NaN Conversion_syntax +dsbas531 toSci '01.35.' -> NaN Conversion_syntax +dsbas532 toSci '01.35-' -> NaN Conversion_syntax +dsbas533 toSci '0000..' -> NaN Conversion_syntax +dsbas534 toSci '.0000.' -> NaN Conversion_syntax +dsbas535 toSci '00..00' -> NaN Conversion_syntax +dsbas536 toSci '111e*123' -> NaN Conversion_syntax +dsbas537 toSci '111e123-' -> NaN Conversion_syntax +dsbas538 toSci '111e+12+' -> NaN Conversion_syntax +dsbas539 toSci '111e1-3-' -> NaN Conversion_syntax +dsbas540 toSci '111e1*23' -> NaN Conversion_syntax +dsbas541 toSci '111e1e+3' -> NaN Conversion_syntax +dsbas542 toSci '1e1.0' -> NaN Conversion_syntax +dsbas543 toSci '1e123e' -> NaN Conversion_syntax +dsbas544 toSci 'ten' -> NaN Conversion_syntax +dsbas545 toSci 'ONE' -> NaN Conversion_syntax +dsbas546 toSci '1e.1' -> NaN Conversion_syntax +dsbas547 toSci '1e1.' -> NaN Conversion_syntax +dsbas548 toSci '1ee' -> NaN Conversion_syntax +dsbas549 toSci 'e+1' -> NaN Conversion_syntax +dsbas550 toSci '1.23.4' -> NaN Conversion_syntax +dsbas551 toSci '1.2.1' -> NaN Conversion_syntax +dsbas552 toSci '1E+1.2' -> NaN Conversion_syntax +dsbas553 toSci '1E+1.2.3' -> NaN Conversion_syntax +dsbas554 toSci '1E++1' -> NaN Conversion_syntax +dsbas555 toSci '1E--1' -> NaN Conversion_syntax +dsbas556 toSci '1E+-1' -> NaN Conversion_syntax +dsbas557 toSci '1E-+1' -> NaN Conversion_syntax +dsbas558 toSci '1E''1' -> NaN Conversion_syntax +dsbas559 toSci "1E""1" -> NaN Conversion_syntax +dsbas560 toSci "1E""""" -> NaN Conversion_syntax +-- Near-specials +dsbas561 toSci "qNaN" -> NaN Conversion_syntax +dsbas562 toSci "NaNq" -> NaN Conversion_syntax +dsbas563 toSci "NaNs" -> NaN Conversion_syntax +dsbas564 toSci "Infi" -> NaN Conversion_syntax +dsbas565 toSci "Infin" -> NaN Conversion_syntax +dsbas566 toSci "Infini" -> NaN Conversion_syntax +dsbas567 toSci "Infinit" -> NaN Conversion_syntax +dsbas568 toSci "-Infinit" -> NaN Conversion_syntax +dsbas569 toSci "0Inf" -> NaN Conversion_syntax +dsbas570 toSci "9Inf" -> NaN Conversion_syntax +dsbas571 toSci "-0Inf" -> NaN Conversion_syntax +dsbas572 toSci "-9Inf" -> NaN Conversion_syntax +dsbas573 toSci "-sNa" -> NaN Conversion_syntax +dsbas574 toSci "xNaN" -> NaN Conversion_syntax +dsbas575 toSci "0sNaN" -> NaN Conversion_syntax + +-- some baddies with dots and Es and dots and specials +dsbas576 toSci 'e+1' -> NaN Conversion_syntax +dsbas577 toSci '.e+1' -> NaN Conversion_syntax +dsbas578 toSci '+.e+1' -> NaN Conversion_syntax +dsbas579 toSci '-.e+' -> NaN Conversion_syntax +dsbas580 toSci '-.e' -> NaN Conversion_syntax +dsbas581 toSci 'E+1' -> NaN Conversion_syntax +dsbas582 toSci '.E+1' -> NaN Conversion_syntax +dsbas583 toSci '+.E+1' -> NaN Conversion_syntax +dsbas584 toSci '-.E+' -> NaN Conversion_syntax +dsbas585 toSci '-.E' -> NaN Conversion_syntax + +dsbas586 toSci '.NaN' -> NaN Conversion_syntax +dsbas587 toSci '-.NaN' -> NaN Conversion_syntax +dsbas588 toSci '+.sNaN' -> NaN Conversion_syntax +dsbas589 toSci '+.Inf' -> NaN Conversion_syntax +dsbas590 toSci '.Infinity' -> NaN Conversion_syntax + +-- Zeros +dsbas601 toSci 0.000000000 -> 0E-9 +dsbas602 toSci 0.00000000 -> 0E-8 +dsbas603 toSci 0.0000000 -> 0E-7 +dsbas604 toSci 0.000000 -> 0.000000 +dsbas605 toSci 0.00000 -> 0.00000 +dsbas606 toSci 0.0000 -> 0.0000 +dsbas607 toSci 0.000 -> 0.000 +dsbas608 toSci 0.00 -> 0.00 +dsbas609 toSci 0.0 -> 0.0 +dsbas610 toSci .0 -> 0.0 +dsbas611 toSci 0. -> 0 +dsbas612 toSci -.0 -> -0.0 +dsbas613 toSci -0. -> -0 +dsbas614 toSci -0.0 -> -0.0 +dsbas615 toSci -0.00 -> -0.00 +dsbas616 toSci -0.000 -> -0.000 +dsbas617 toSci -0.0000 -> -0.0000 +dsbas618 toSci -0.00000 -> -0.00000 +dsbas619 toSci -0.000000 -> -0.000000 +dsbas620 toSci -0.0000000 -> -0E-7 +dsbas621 toSci -0.00000000 -> -0E-8 +dsbas622 toSci -0.000000000 -> -0E-9 + +dsbas630 toSci 0.00E+0 -> 0.00 +dsbas631 toSci 0.00E+1 -> 0.0 +dsbas632 toSci 0.00E+2 -> 0 +dsbas633 toSci 0.00E+3 -> 0E+1 +dsbas634 toSci 0.00E+4 -> 0E+2 +dsbas635 toSci 0.00E+5 -> 0E+3 +dsbas636 toSci 0.00E+6 -> 0E+4 +dsbas637 toSci 0.00E+7 -> 0E+5 +dsbas638 toSci 0.00E+8 -> 0E+6 +dsbas639 toSci 0.00E+9 -> 0E+7 + +dsbas640 toSci 0.0E+0 -> 0.0 +dsbas641 toSci 0.0E+1 -> 0 +dsbas642 toSci 0.0E+2 -> 0E+1 +dsbas643 toSci 0.0E+3 -> 0E+2 +dsbas644 toSci 0.0E+4 -> 0E+3 +dsbas645 toSci 0.0E+5 -> 0E+4 +dsbas646 toSci 0.0E+6 -> 0E+5 +dsbas647 toSci 0.0E+7 -> 0E+6 +dsbas648 toSci 0.0E+8 -> 0E+7 +dsbas649 toSci 0.0E+9 -> 0E+8 + +dsbas650 toSci 0E+0 -> 0 +dsbas651 toSci 0E+1 -> 0E+1 +dsbas652 toSci 0E+2 -> 0E+2 +dsbas653 toSci 0E+3 -> 0E+3 +dsbas654 toSci 0E+4 -> 0E+4 +dsbas655 toSci 0E+5 -> 0E+5 +dsbas656 toSci 0E+6 -> 0E+6 +dsbas657 toSci 0E+7 -> 0E+7 +dsbas658 toSci 0E+8 -> 0E+8 +dsbas659 toSci 0E+9 -> 0E+9 + +dsbas660 toSci 0.0E-0 -> 0.0 +dsbas661 toSci 0.0E-1 -> 0.00 +dsbas662 toSci 0.0E-2 -> 0.000 +dsbas663 toSci 0.0E-3 -> 0.0000 +dsbas664 toSci 0.0E-4 -> 0.00000 +dsbas665 toSci 0.0E-5 -> 0.000000 +dsbas666 toSci 0.0E-6 -> 0E-7 +dsbas667 toSci 0.0E-7 -> 0E-8 +dsbas668 toSci 0.0E-8 -> 0E-9 +dsbas669 toSci 0.0E-9 -> 0E-10 + +dsbas670 toSci 0.00E-0 -> 0.00 +dsbas671 toSci 0.00E-1 -> 0.000 +dsbas672 toSci 0.00E-2 -> 0.0000 +dsbas673 toSci 0.00E-3 -> 0.00000 +dsbas674 toSci 0.00E-4 -> 0.000000 +dsbas675 toSci 0.00E-5 -> 0E-7 +dsbas676 toSci 0.00E-6 -> 0E-8 +dsbas677 toSci 0.00E-7 -> 0E-9 +dsbas678 toSci 0.00E-8 -> 0E-10 +dsbas679 toSci 0.00E-9 -> 0E-11 + +dsbas680 toSci 000000. -> 0 +dsbas681 toSci 00000. -> 0 +dsbas682 toSci 0000. -> 0 +dsbas683 toSci 000. -> 0 +dsbas684 toSci 00. -> 0 +dsbas685 toSci 0. -> 0 +dsbas686 toSci +00000. -> 0 +dsbas687 toSci -00000. -> -0 +dsbas688 toSci +0. -> 0 +dsbas689 toSci -0. -> -0 + +-- Specials +dsbas700 toSci "NaN" -> NaN +dsbas701 toSci "nan" -> NaN +dsbas702 toSci "nAn" -> NaN +dsbas703 toSci "NAN" -> NaN +dsbas704 toSci "+NaN" -> NaN +dsbas705 toSci "+nan" -> NaN +dsbas706 toSci "+nAn" -> NaN +dsbas707 toSci "+NAN" -> NaN +dsbas708 toSci "-NaN" -> -NaN +dsbas709 toSci "-nan" -> -NaN +dsbas710 toSci "-nAn" -> -NaN +dsbas711 toSci "-NAN" -> -NaN +dsbas712 toSci 'NaN0' -> NaN +dsbas713 toSci 'NaN1' -> NaN1 +dsbas714 toSci 'NaN12' -> NaN12 +dsbas715 toSci 'NaN123' -> NaN123 +dsbas716 toSci 'NaN1234' -> NaN1234 +dsbas717 toSci 'NaN01' -> NaN1 +dsbas718 toSci 'NaN012' -> NaN12 +dsbas719 toSci 'NaN0123' -> NaN123 +dsbas720 toSci 'NaN01234' -> NaN1234 +dsbas721 toSci 'NaN001' -> NaN1 +dsbas722 toSci 'NaN0012' -> NaN12 +dsbas723 toSci 'NaN00123' -> NaN123 +dsbas724 toSci 'NaN001234' -> NaN1234 +dsbas725 toSci 'NaN1234567890123456' -> NaN Conversion_syntax +dsbas726 toSci 'NaN123e+1' -> NaN Conversion_syntax +dsbas727 toSci 'NaN12.45' -> NaN Conversion_syntax +dsbas728 toSci 'NaN-12' -> NaN Conversion_syntax +dsbas729 toSci 'NaN+12' -> NaN Conversion_syntax + +dsbas730 toSci "sNaN" -> sNaN +dsbas731 toSci "snan" -> sNaN +dsbas732 toSci "SnAn" -> sNaN +dsbas733 toSci "SNAN" -> sNaN +dsbas734 toSci "+sNaN" -> sNaN +dsbas735 toSci "+snan" -> sNaN +dsbas736 toSci "+SnAn" -> sNaN +dsbas737 toSci "+SNAN" -> sNaN +dsbas738 toSci "-sNaN" -> -sNaN +dsbas739 toSci "-snan" -> -sNaN +dsbas740 toSci "-SnAn" -> -sNaN +dsbas741 toSci "-SNAN" -> -sNaN +dsbas742 toSci 'sNaN0000' -> sNaN +dsbas743 toSci 'sNaN7' -> sNaN7 +dsbas744 toSci 'sNaN007234' -> sNaN7234 +dsbas745 toSci 'sNaN7234561234567890' -> NaN Conversion_syntax +dsbas746 toSci 'sNaN72.45' -> NaN Conversion_syntax +dsbas747 toSci 'sNaN-72' -> NaN Conversion_syntax + +dsbas748 toSci "Inf" -> Infinity +dsbas749 toSci "inf" -> Infinity +dsbas750 toSci "iNf" -> Infinity +dsbas751 toSci "INF" -> Infinity +dsbas752 toSci "+Inf" -> Infinity +dsbas753 toSci "+inf" -> Infinity +dsbas754 toSci "+iNf" -> Infinity +dsbas755 toSci "+INF" -> Infinity +dsbas756 toSci "-Inf" -> -Infinity +dsbas757 toSci "-inf" -> -Infinity +dsbas758 toSci "-iNf" -> -Infinity +dsbas759 toSci "-INF" -> -Infinity + +dsbas760 toSci "Infinity" -> Infinity +dsbas761 toSci "infinity" -> Infinity +dsbas762 toSci "iNfInItY" -> Infinity +dsbas763 toSci "INFINITY" -> Infinity +dsbas764 toSci "+Infinity" -> Infinity +dsbas765 toSci "+infinity" -> Infinity +dsbas766 toSci "+iNfInItY" -> Infinity +dsbas767 toSci "+INFINITY" -> Infinity +dsbas768 toSci "-Infinity" -> -Infinity +dsbas769 toSci "-infinity" -> -Infinity +dsbas770 toSci "-iNfInItY" -> -Infinity +dsbas771 toSci "-INFINITY" -> -Infinity + +-- Specials and zeros for toEng +dsbast772 toEng "NaN" -> NaN +dsbast773 toEng "-Infinity" -> -Infinity +dsbast774 toEng "-sNaN" -> -sNaN +dsbast775 toEng "-NaN" -> -NaN +dsbast776 toEng "+Infinity" -> Infinity +dsbast778 toEng "+sNaN" -> sNaN +dsbast779 toEng "+NaN" -> NaN +dsbast780 toEng "INFINITY" -> Infinity +dsbast781 toEng "SNAN" -> sNaN +dsbast782 toEng "NAN" -> NaN +dsbast783 toEng "infinity" -> Infinity +dsbast784 toEng "snan" -> sNaN +dsbast785 toEng "nan" -> NaN +dsbast786 toEng "InFINITY" -> Infinity +dsbast787 toEng "SnAN" -> sNaN +dsbast788 toEng "nAN" -> NaN +dsbast789 toEng "iNfinity" -> Infinity +dsbast790 toEng "sNan" -> sNaN +dsbast791 toEng "Nan" -> NaN +dsbast792 toEng "Infinity" -> Infinity +dsbast793 toEng "sNaN" -> sNaN + +-- Zero toEng, etc. +dsbast800 toEng 0e+1 -> "0.00E+3" -- doc example + +dsbast801 toEng 0.000000000 -> 0E-9 +dsbast802 toEng 0.00000000 -> 0.00E-6 +dsbast803 toEng 0.0000000 -> 0.0E-6 +dsbast804 toEng 0.000000 -> 0.000000 +dsbast805 toEng 0.00000 -> 0.00000 +dsbast806 toEng 0.0000 -> 0.0000 +dsbast807 toEng 0.000 -> 0.000 +dsbast808 toEng 0.00 -> 0.00 +dsbast809 toEng 0.0 -> 0.0 +dsbast810 toEng .0 -> 0.0 +dsbast811 toEng 0. -> 0 +dsbast812 toEng -.0 -> -0.0 +dsbast813 toEng -0. -> -0 +dsbast814 toEng -0.0 -> -0.0 +dsbast815 toEng -0.00 -> -0.00 +dsbast816 toEng -0.000 -> -0.000 +dsbast817 toEng -0.0000 -> -0.0000 +dsbast818 toEng -0.00000 -> -0.00000 +dsbast819 toEng -0.000000 -> -0.000000 +dsbast820 toEng -0.0000000 -> -0.0E-6 +dsbast821 toEng -0.00000000 -> -0.00E-6 +dsbast822 toEng -0.000000000 -> -0E-9 + +dsbast830 toEng 0.00E+0 -> 0.00 +dsbast831 toEng 0.00E+1 -> 0.0 +dsbast832 toEng 0.00E+2 -> 0 +dsbast833 toEng 0.00E+3 -> 0.00E+3 +dsbast834 toEng 0.00E+4 -> 0.0E+3 +dsbast835 toEng 0.00E+5 -> 0E+3 +dsbast836 toEng 0.00E+6 -> 0.00E+6 +dsbast837 toEng 0.00E+7 -> 0.0E+6 +dsbast838 toEng 0.00E+8 -> 0E+6 +dsbast839 toEng 0.00E+9 -> 0.00E+9 + +dsbast840 toEng 0.0E+0 -> 0.0 +dsbast841 toEng 0.0E+1 -> 0 +dsbast842 toEng 0.0E+2 -> 0.00E+3 +dsbast843 toEng 0.0E+3 -> 0.0E+3 +dsbast844 toEng 0.0E+4 -> 0E+3 +dsbast845 toEng 0.0E+5 -> 0.00E+6 +dsbast846 toEng 0.0E+6 -> 0.0E+6 +dsbast847 toEng 0.0E+7 -> 0E+6 +dsbast848 toEng 0.0E+8 -> 0.00E+9 +dsbast849 toEng 0.0E+9 -> 0.0E+9 + +dsbast850 toEng 0E+0 -> 0 +dsbast851 toEng 0E+1 -> 0.00E+3 +dsbast852 toEng 0E+2 -> 0.0E+3 +dsbast853 toEng 0E+3 -> 0E+3 +dsbast854 toEng 0E+4 -> 0.00E+6 +dsbast855 toEng 0E+5 -> 0.0E+6 +dsbast856 toEng 0E+6 -> 0E+6 +dsbast857 toEng 0E+7 -> 0.00E+9 +dsbast858 toEng 0E+8 -> 0.0E+9 +dsbast859 toEng 0E+9 -> 0E+9 + +dsbast860 toEng 0.0E-0 -> 0.0 +dsbast861 toEng 0.0E-1 -> 0.00 +dsbast862 toEng 0.0E-2 -> 0.000 +dsbast863 toEng 0.0E-3 -> 0.0000 +dsbast864 toEng 0.0E-4 -> 0.00000 +dsbast865 toEng 0.0E-5 -> 0.000000 +dsbast866 toEng 0.0E-6 -> 0.0E-6 +dsbast867 toEng 0.0E-7 -> 0.00E-6 +dsbast868 toEng 0.0E-8 -> 0E-9 +dsbast869 toEng 0.0E-9 -> 0.0E-9 + +dsbast870 toEng 0.00E-0 -> 0.00 +dsbast871 toEng 0.00E-1 -> 0.000 +dsbast872 toEng 0.00E-2 -> 0.0000 +dsbast873 toEng 0.00E-3 -> 0.00000 +dsbast874 toEng 0.00E-4 -> 0.000000 +dsbast875 toEng 0.00E-5 -> 0.0E-6 +dsbast876 toEng 0.00E-6 -> 0.00E-6 +dsbast877 toEng 0.00E-7 -> 0E-9 +dsbast878 toEng 0.00E-8 -> 0.0E-9 +dsbast879 toEng 0.00E-9 -> 0.00E-9 + +-- long input strings +dsbas801 tosci '01234567' -> 1234567 +dsbas802 tosci '001234567' -> 1234567 +dsbas803 tosci '0001234567' -> 1234567 +dsbas804 tosci '00001234567' -> 1234567 +dsbas805 tosci '000001234567' -> 1234567 +dsbas806 tosci '0000001234567' -> 1234567 +dsbas807 tosci '00000001234567' -> 1234567 +dsbas808 tosci '000000001234567' -> 1234567 +dsbas809 tosci '0000000001234567' -> 1234567 +dsbas810 tosci '00000000001234567' -> 1234567 + +dsbas811 tosci '0.1234567' -> 0.1234567 +dsbas812 tosci '0.01234567' -> 0.01234567 +dsbas813 tosci '0.001234567' -> 0.001234567 +dsbas814 tosci '0.0001234567' -> 0.0001234567 +dsbas815 tosci '0.00001234567' -> 0.00001234567 +dsbas816 tosci '0.000001234567' -> 0.000001234567 +dsbas817 tosci '0.0000001234567' -> 1.234567E-7 +dsbas818 tosci '0.00000001234567' -> 1.234567E-8 +dsbas819 tosci '0.000000001234567' -> 1.234567E-9 +dsbas820 tosci '0.0000000001234567' -> 1.234567E-10 + +dsbas821 tosci '123456790' -> 1.234568E+8 Inexact Rounded +dsbas822 tosci '1234567901' -> 1.234568E+9 Inexact Rounded +dsbas823 tosci '12345679012' -> 1.234568E+10 Inexact Rounded +dsbas824 tosci '123456790123' -> 1.234568E+11 Inexact Rounded +dsbas825 tosci '1234567901234' -> 1.234568E+12 Inexact Rounded +dsbas826 tosci '12345679012345' -> 1.234568E+13 Inexact Rounded +dsbas827 tosci '123456790123456' -> 1.234568E+14 Inexact Rounded +dsbas828 tosci '1234567901234567' -> 1.234568E+15 Inexact Rounded +dsbas829 tosci '1234567890123456' -> 1.234568E+15 Inexact Rounded + +-- subnormals and overflows +dsbas906 toSci '99e999999999' -> Infinity Overflow Inexact Rounded +dsbas907 toSci '999e999999999' -> Infinity Overflow Inexact Rounded +dsbas908 toSci '0.9e-999999999' -> 0E-101 Underflow Subnormal Inexact Rounded Clamped +dsbas909 toSci '0.09e-999999999' -> 0E-101 Underflow Subnormal Inexact Rounded Clamped +dsbas910 toSci '0.1e1000000000' -> Infinity Overflow Inexact Rounded +dsbas911 toSci '10e-1000000000' -> 0E-101 Underflow Subnormal Inexact Rounded Clamped +dsbas912 toSci '0.9e9999999999' -> Infinity Overflow Inexact Rounded +dsbas913 toSci '99e-9999999999' -> 0E-101 Underflow Subnormal Inexact Rounded Clamped +dsbas914 toSci '111e9999999999' -> Infinity Overflow Inexact Rounded +dsbas915 toSci '1111e-9999999999' -> 0E-101 Underflow Subnormal Inexact Rounded Clamped +dsbas916 toSci '1111e-99999999999' -> 0E-101 Underflow Subnormal Inexact Rounded Clamped +dsbas917 toSci '7e1000000000' -> Infinity Overflow Inexact Rounded +-- negatives the same +dsbas918 toSci '-99e999999999' -> -Infinity Overflow Inexact Rounded +dsbas919 toSci '-999e999999999' -> -Infinity Overflow Inexact Rounded +dsbas920 toSci '-0.9e-999999999' -> -0E-101 Underflow Subnormal Inexact Rounded Clamped +dsbas921 toSci '-0.09e-999999999' -> -0E-101 Underflow Subnormal Inexact Rounded Clamped +dsbas922 toSci '-0.1e1000000000' -> -Infinity Overflow Inexact Rounded +dsbas923 toSci '-10e-1000000000' -> -0E-101 Underflow Subnormal Inexact Rounded Clamped +dsbas924 toSci '-0.9e9999999999' -> -Infinity Overflow Inexact Rounded +dsbas925 toSci '-99e-9999999999' -> -0E-101 Underflow Subnormal Inexact Rounded Clamped +dsbas926 toSci '-111e9999999999' -> -Infinity Overflow Inexact Rounded +dsbas927 toSci '-1111e-9999999999' -> -0E-101 Underflow Subnormal Inexact Rounded Clamped +dsbas928 toSci '-1111e-99999999999' -> -0E-101 Underflow Subnormal Inexact Rounded Clamped +dsbas929 toSci '-7e1000000000' -> -Infinity Overflow Inexact Rounded + +-- overflow results at different rounding modes +rounding: ceiling +dsbas930 toSci '7e10000' -> Infinity Overflow Inexact Rounded +dsbas931 toSci '-7e10000' -> -9.999999E+96 Overflow Inexact Rounded +rounding: up +dsbas932 toSci '7e10000' -> Infinity Overflow Inexact Rounded +dsbas933 toSci '-7e10000' -> -Infinity Overflow Inexact Rounded +rounding: down +dsbas934 toSci '7e10000' -> 9.999999E+96 Overflow Inexact Rounded +dsbas935 toSci '-7e10000' -> -9.999999E+96 Overflow Inexact Rounded +rounding: floor +dsbas936 toSci '7e10000' -> 9.999999E+96 Overflow Inexact Rounded +dsbas937 toSci '-7e10000' -> -Infinity Overflow Inexact Rounded + +rounding: half_up +dsbas938 toSci '7e10000' -> Infinity Overflow Inexact Rounded +dsbas939 toSci '-7e10000' -> -Infinity Overflow Inexact Rounded +rounding: half_even +dsbas940 toSci '7e10000' -> Infinity Overflow Inexact Rounded +dsbas941 toSci '-7e10000' -> -Infinity Overflow Inexact Rounded +rounding: half_down +dsbas942 toSci '7e10000' -> Infinity Overflow Inexact Rounded +dsbas943 toSci '-7e10000' -> -Infinity Overflow Inexact Rounded + +rounding: half_even + +-- Now check 854/754r some subnormals and underflow to 0 +dsbem400 toSci 1.0000E-86 -> 1.0000E-86 +dsbem401 toSci 0.1E-97 -> 1E-98 Subnormal +dsbem402 toSci 0.1000E-97 -> 1.000E-98 Subnormal +dsbem403 toSci 0.0100E-97 -> 1.00E-99 Subnormal +dsbem404 toSci 0.0010E-97 -> 1.0E-100 Subnormal +dsbem405 toSci 0.0001E-97 -> 1E-101 Subnormal +dsbem406 toSci 0.00010E-97 -> 1E-101 Subnormal Rounded +dsbem407 toSci 0.00013E-97 -> 1E-101 Underflow Subnormal Inexact Rounded +dsbem408 toSci 0.00015E-97 -> 2E-101 Underflow Subnormal Inexact Rounded +dsbem409 toSci 0.00017E-97 -> 2E-101 Underflow Subnormal Inexact Rounded +dsbem410 toSci 0.00023E-97 -> 2E-101 Underflow Subnormal Inexact Rounded +dsbem411 toSci 0.00025E-97 -> 2E-101 Underflow Subnormal Inexact Rounded +dsbem412 toSci 0.00027E-97 -> 3E-101 Underflow Subnormal Inexact Rounded +dsbem413 toSci 0.000149E-97 -> 1E-101 Underflow Subnormal Inexact Rounded +dsbem414 toSci 0.000150E-97 -> 2E-101 Underflow Subnormal Inexact Rounded +dsbem415 toSci 0.000151E-97 -> 2E-101 Underflow Subnormal Inexact Rounded +dsbem416 toSci 0.000249E-97 -> 2E-101 Underflow Subnormal Inexact Rounded +dsbem417 toSci 0.000250E-97 -> 2E-101 Underflow Subnormal Inexact Rounded +dsbem418 toSci 0.000251E-97 -> 3E-101 Underflow Subnormal Inexact Rounded +dsbem419 toSci 0.00009E-97 -> 1E-101 Underflow Subnormal Inexact Rounded +dsbem420 toSci 0.00005E-97 -> 0E-101 Underflow Subnormal Inexact Rounded Clamped +dsbem421 toSci 0.00003E-97 -> 0E-101 Underflow Subnormal Inexact Rounded Clamped +dsbem422 toSci 0.000009E-97 -> 0E-101 Underflow Subnormal Inexact Rounded Clamped +dsbem423 toSci 0.000005E-97 -> 0E-101 Underflow Subnormal Inexact Rounded Clamped +dsbem424 toSci 0.000003E-97 -> 0E-101 Underflow Subnormal Inexact Rounded Clamped + +dsbem425 toSci 0.001049E-97 -> 1.0E-100 Underflow Subnormal Inexact Rounded +dsbem426 toSci 0.001050E-97 -> 1.0E-100 Underflow Subnormal Inexact Rounded +dsbem427 toSci 0.001051E-97 -> 1.1E-100 Underflow Subnormal Inexact Rounded +dsbem428 toSci 0.001149E-97 -> 1.1E-100 Underflow Subnormal Inexact Rounded +dsbem429 toSci 0.001150E-97 -> 1.2E-100 Underflow Subnormal Inexact Rounded +dsbem430 toSci 0.001151E-97 -> 1.2E-100 Underflow Subnormal Inexact Rounded + +dsbem432 toSci 0.010049E-97 -> 1.00E-99 Underflow Subnormal Inexact Rounded +dsbem433 toSci 0.010050E-97 -> 1.00E-99 Underflow Subnormal Inexact Rounded +dsbem434 toSci 0.010051E-97 -> 1.01E-99 Underflow Subnormal Inexact Rounded +dsbem435 toSci 0.010149E-97 -> 1.01E-99 Underflow Subnormal Inexact Rounded +dsbem436 toSci 0.010150E-97 -> 1.02E-99 Underflow Subnormal Inexact Rounded +dsbem437 toSci 0.010151E-97 -> 1.02E-99 Underflow Subnormal Inexact Rounded + +dsbem440 toSci 0.10103E-97 -> 1.010E-98 Underflow Subnormal Inexact Rounded +dsbem441 toSci 0.10105E-97 -> 1.010E-98 Underflow Subnormal Inexact Rounded +dsbem442 toSci 0.10107E-97 -> 1.011E-98 Underflow Subnormal Inexact Rounded +dsbem443 toSci 0.10113E-97 -> 1.011E-98 Underflow Subnormal Inexact Rounded +dsbem444 toSci 0.10115E-97 -> 1.012E-98 Underflow Subnormal Inexact Rounded +dsbem445 toSci 0.10117E-97 -> 1.012E-98 Underflow Subnormal Inexact Rounded + +dsbem450 toSci 1.10730E-98 -> 1.107E-98 Underflow Subnormal Inexact Rounded +dsbem451 toSci 1.10750E-98 -> 1.108E-98 Underflow Subnormal Inexact Rounded +dsbem452 toSci 1.10770E-98 -> 1.108E-98 Underflow Subnormal Inexact Rounded +dsbem453 toSci 1.10830E-98 -> 1.108E-98 Underflow Subnormal Inexact Rounded +dsbem454 toSci 1.10850E-98 -> 1.108E-98 Underflow Subnormal Inexact Rounded +dsbem455 toSci 1.10870E-98 -> 1.109E-98 Underflow Subnormal Inexact Rounded + +-- make sure sign OK +dsbem456 toSci -0.10103E-97 -> -1.010E-98 Underflow Subnormal Inexact Rounded +dsbem457 toSci -0.10105E-97 -> -1.010E-98 Underflow Subnormal Inexact Rounded +dsbem458 toSci -0.10107E-97 -> -1.011E-98 Underflow Subnormal Inexact Rounded +dsbem459 toSci -0.10113E-97 -> -1.011E-98 Underflow Subnormal Inexact Rounded +dsbem460 toSci -0.10115E-97 -> -1.012E-98 Underflow Subnormal Inexact Rounded +dsbem461 toSci -0.10117E-97 -> -1.012E-98 Underflow Subnormal Inexact Rounded + +-- '999s' cases +dsbem464 toSci 999999E-98 -> 9.99999E-93 +dsbem465 toSci 99999.0E-97 -> 9.99990E-93 +dsbem466 toSci 99999.E-97 -> 9.9999E-93 +dsbem467 toSci 9999.9E-97 -> 9.9999E-94 +dsbem468 toSci 999.99E-97 -> 9.9999E-95 +dsbem469 toSci 99.999E-97 -> 9.9999E-96 Subnormal +dsbem470 toSci 9.9999E-97 -> 9.9999E-97 Subnormal +dsbem471 toSci 0.99999E-97 -> 1.0000E-97 Underflow Subnormal Inexact Rounded +dsbem472 toSci 0.099999E-97 -> 1.000E-98 Underflow Subnormal Inexact Rounded +dsbem473 toSci 0.0099999E-97 -> 1.00E-99 Underflow Subnormal Inexact Rounded +dsbem474 toSci 0.00099999E-97 -> 1.0E-100 Underflow Subnormal Inexact Rounded +dsbem475 toSci 0.000099999E-97 -> 1E-101 Underflow Subnormal Inexact Rounded +dsbem476 toSci 0.0000099999E-97 -> 0E-101 Underflow Subnormal Inexact Rounded Clamped +dsbem477 toSci 0.00000099999E-97 -> 0E-101 Underflow Subnormal Inexact Rounded Clamped +dsbem478 toSci 0.000000099999E-97 -> 0E-101 Underflow Subnormal Inexact Rounded Clamped + +-- Exponents with insignificant leading zeros +dsbas1001 toSci 1e999999999 -> Infinity Overflow Inexact Rounded +dsbas1002 toSci 1e0999999999 -> Infinity Overflow Inexact Rounded +dsbas1003 toSci 1e00999999999 -> Infinity Overflow Inexact Rounded +dsbas1004 toSci 1e000999999999 -> Infinity Overflow Inexact Rounded +dsbas1005 toSci 1e000000000000999999999 -> Infinity Overflow Inexact Rounded +dsbas1006 toSci 1e000000000001000000007 -> Infinity Overflow Inexact Rounded +dsbas1007 toSci 1e-999999999 -> 0E-101 Underflow Subnormal Inexact Rounded Clamped +dsbas1008 toSci 1e-0999999999 -> 0E-101 Underflow Subnormal Inexact Rounded Clamped +dsbas1009 toSci 1e-00999999999 -> 0E-101 Underflow Subnormal Inexact Rounded Clamped +dsbas1010 toSci 1e-000999999999 -> 0E-101 Underflow Subnormal Inexact Rounded Clamped +dsbas1011 toSci 1e-000000000000999999999 -> 0E-101 Underflow Subnormal Inexact Rounded Clamped +dsbas1012 toSci 1e-000000000001000000007 -> 0E-101 Underflow Subnormal Inexact Rounded Clamped + +-- check for double-rounded subnormals +dsbas1041 toSci 1.1152444E-96 -> 1.11524E-96 Inexact Rounded Subnormal Underflow +dsbas1042 toSci 1.1152445E-96 -> 1.11524E-96 Inexact Rounded Subnormal Underflow +dsbas1043 toSci 1.1152446E-96 -> 1.11524E-96 Inexact Rounded Subnormal Underflow + +-- clamped zeros [see also clamp.decTest] +dsbas1075 toSci 0e+10000 -> 0E+90 Clamped +dsbas1076 toSci 0e-10000 -> 0E-101 Clamped +dsbas1077 toSci -0e+10000 -> -0E+90 Clamped +dsbas1078 toSci -0e-10000 -> -0E-101 Clamped + +-- extreme values from next-wider +dsbas1101 toSci -9.999999999999999E+384 -> -Infinity Overflow Inexact Rounded +dsbas1102 toSci -1E-383 -> -0E-101 Inexact Rounded Subnormal Underflow Clamped +dsbas1103 toSci -1E-398 -> -0E-101 Inexact Rounded Subnormal Underflow Clamped +dsbas1104 toSci -0 -> -0 +dsbas1105 toSci +0 -> 0 +dsbas1106 toSci +1E-398 -> 0E-101 Inexact Rounded Subnormal Underflow Clamped +dsbas1107 toSci +1E-383 -> 0E-101 Inexact Rounded Subnormal Underflow Clamped +dsbas1108 toSci +9.999999999999999E+384 -> Infinity Overflow Inexact Rounded + +-- narrowing case +dsbas1110 toSci 2.000000000000000E-99 -> 2.00E-99 Rounded Subnormal Added: python/branches/release25-maint/Lib/test/decimaltestdata/dsEncode.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/dsEncode.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,372 @@ +------------------------------------------------------------------------ +-- dsEncode.decTest -- decimal four-byte format testcases -- +-- Copyright (c) IBM Corporation, 2000, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +-- [Previously called decimal32.decTest] +version: 2.57 + +-- This set of tests is for the four-byte concrete representation. +-- Its characteristics are: +-- +-- 1 bit sign +-- 5 bits combination field +-- 6 bits exponent continuation +-- 20 bits coefficient continuation +-- +-- Total exponent length 8 bits +-- Total coefficient length 24 bits (7 digits) +-- +-- Elimit = 191 (maximum encoded exponent) +-- Emax = 96 (largest exponent value) +-- Emin = -95 (smallest exponent value) +-- bias = 101 (subtracted from encoded exponent) = -Etiny + +-- The testcases here have only exactly representable data on the +-- 'left-hand-side'; rounding from strings is tested in 'base' +-- testcase groups. + +extended: 1 +clamp: 1 +precision: 7 +rounding: half_up +maxExponent: 96 +minExponent: -95 + +-- General testcases +-- (mostly derived from the Strawman 4 document and examples) +decs001 apply #A23003D0 -> -7.50 +decs002 apply -7.50 -> #A23003D0 +-- derivative canonical plain strings +decs003 apply #A26003D0 -> -7.50E+3 +decs004 apply -7.50E+3 -> #A26003D0 +decs005 apply #A25003D0 -> -750 +decs006 apply -750 -> #A25003D0 +decs007 apply #A24003D0 -> -75.0 +decs008 apply -75.0 -> #A24003D0 +decs009 apply #A22003D0 -> -0.750 +decs010 apply -0.750 -> #A22003D0 +decs011 apply #A21003D0 -> -0.0750 +decs012 apply -0.0750 -> #A21003D0 +decs013 apply #A1f003D0 -> -0.000750 +decs014 apply -0.000750 -> #A1f003D0 +decs015 apply #A1d003D0 -> -0.00000750 +decs016 apply -0.00000750 -> #A1d003D0 +decs017 apply #A1c003D0 -> -7.50E-7 +decs018 apply -7.50E-7 -> #A1c003D0 + +-- Normality +decs020 apply 1234567 -> #2654d2e7 +decs021 apply -1234567 -> #a654d2e7 +decs022 apply 1111111 -> #26524491 + +-- Nmax and similar +decs031 apply 9.999999E+96 -> #77f3fcff +decs032 apply #77f3fcff -> 9.999999E+96 +decs033 apply 1.234567E+96 -> #47f4d2e7 +decs034 apply #47f4d2e7 -> 1.234567E+96 +-- fold-downs (more below) +decs035 apply 1.23E+96 -> #47f4c000 Clamped +decs036 apply #47f4c000 -> 1.230000E+96 +decs037 apply 1E+96 -> #47f00000 Clamped +decs038 apply #47f00000 -> 1.000000E+96 + +decs051 apply 12345 -> #225049c5 +decs052 apply #225049c5 -> 12345 +decs053 apply 1234 -> #22500534 +decs054 apply #22500534 -> 1234 +decs055 apply 123 -> #225000a3 +decs056 apply #225000a3 -> 123 +decs057 apply 12 -> #22500012 +decs058 apply #22500012 -> 12 +decs059 apply 1 -> #22500001 +decs060 apply #22500001 -> 1 +decs061 apply 1.23 -> #223000a3 +decs062 apply #223000a3 -> 1.23 +decs063 apply 123.45 -> #223049c5 +decs064 apply #223049c5 -> 123.45 + +-- Nmin and below +decs071 apply 1E-95 -> #00600001 +decs072 apply #00600001 -> 1E-95 +decs073 apply 1.000000E-95 -> #04000000 +decs074 apply #04000000 -> 1.000000E-95 +decs075 apply 1.000001E-95 -> #04000001 +decs076 apply #04000001 -> 1.000001E-95 + +decs077 apply 0.100000E-95 -> #00020000 Subnormal +decs07x apply 1.00000E-96 -> 1.00000E-96 Subnormal +decs078 apply #00020000 -> 1.00000E-96 Subnormal +decs079 apply 0.000010E-95 -> #00000010 Subnormal +decs080 apply #00000010 -> 1.0E-100 Subnormal +decs081 apply 0.000001E-95 -> #00000001 Subnormal +decs082 apply #00000001 -> 1E-101 Subnormal +decs083 apply 1e-101 -> #00000001 Subnormal +decs084 apply #00000001 -> 1E-101 Subnormal +decs08x apply 1e-101 -> 1E-101 Subnormal + +-- underflows cannot be tested; just check edge case +decs090 apply 1e-101 -> #00000001 Subnormal + +-- same again, negatives -- + +-- Nmax and similar +decs122 apply -9.999999E+96 -> #f7f3fcff +decs123 apply #f7f3fcff -> -9.999999E+96 +decs124 apply -1.234567E+96 -> #c7f4d2e7 +decs125 apply #c7f4d2e7 -> -1.234567E+96 +-- fold-downs (more below) +decs130 apply -1.23E+96 -> #c7f4c000 Clamped +decs131 apply #c7f4c000 -> -1.230000E+96 +decs132 apply -1E+96 -> #c7f00000 Clamped +decs133 apply #c7f00000 -> -1.000000E+96 + +decs151 apply -12345 -> #a25049c5 +decs152 apply #a25049c5 -> -12345 +decs153 apply -1234 -> #a2500534 +decs154 apply #a2500534 -> -1234 +decs155 apply -123 -> #a25000a3 +decs156 apply #a25000a3 -> -123 +decs157 apply -12 -> #a2500012 +decs158 apply #a2500012 -> -12 +decs159 apply -1 -> #a2500001 +decs160 apply #a2500001 -> -1 +decs161 apply -1.23 -> #a23000a3 +decs162 apply #a23000a3 -> -1.23 +decs163 apply -123.45 -> #a23049c5 +decs164 apply #a23049c5 -> -123.45 + +-- Nmin and below +decs171 apply -1E-95 -> #80600001 +decs172 apply #80600001 -> -1E-95 +decs173 apply -1.000000E-95 -> #84000000 +decs174 apply #84000000 -> -1.000000E-95 +decs175 apply -1.000001E-95 -> #84000001 +decs176 apply #84000001 -> -1.000001E-95 + +decs177 apply -0.100000E-95 -> #80020000 Subnormal +decs178 apply #80020000 -> -1.00000E-96 Subnormal +decs179 apply -0.000010E-95 -> #80000010 Subnormal +decs180 apply #80000010 -> -1.0E-100 Subnormal +decs181 apply -0.000001E-95 -> #80000001 Subnormal +decs182 apply #80000001 -> -1E-101 Subnormal +decs183 apply -1e-101 -> #80000001 Subnormal +decs184 apply #80000001 -> -1E-101 Subnormal + +-- underflow edge case +decs190 apply -1e-101 -> #80000001 Subnormal + +-- zeros +decs400 apply 0E-400 -> #00000000 Clamped +decs401 apply 0E-101 -> #00000000 +decs402 apply #00000000 -> 0E-101 +decs403 apply 0.000000E-95 -> #00000000 +decs404 apply #00000000 -> 0E-101 +decs405 apply 0E-2 -> #22300000 +decs406 apply #22300000 -> 0.00 +decs407 apply 0 -> #22500000 +decs408 apply #22500000 -> 0 +decs409 apply 0E+3 -> #22800000 +decs410 apply #22800000 -> 0E+3 +decs411 apply 0E+90 -> #43f00000 +decs412 apply #43f00000 -> 0E+90 +-- clamped zeros... +decs413 apply 0E+91 -> #43f00000 Clamped +decs414 apply #43f00000 -> 0E+90 +decs415 apply 0E+96 -> #43f00000 Clamped +decs416 apply #43f00000 -> 0E+90 +decs417 apply 0E+400 -> #43f00000 Clamped +decs418 apply #43f00000 -> 0E+90 + +-- negative zeros +decs420 apply -0E-400 -> #80000000 Clamped +decs421 apply -0E-101 -> #80000000 +decs422 apply #80000000 -> -0E-101 +decs423 apply -0.000000E-95 -> #80000000 +decs424 apply #80000000 -> -0E-101 +decs425 apply -0E-2 -> #a2300000 +decs426 apply #a2300000 -> -0.00 +decs427 apply -0 -> #a2500000 +decs428 apply #a2500000 -> -0 +decs429 apply -0E+3 -> #a2800000 +decs430 apply #a2800000 -> -0E+3 +decs431 apply -0E+90 -> #c3f00000 +decs432 apply #c3f00000 -> -0E+90 +-- clamped zeros... +decs433 apply -0E+91 -> #c3f00000 Clamped +decs434 apply #c3f00000 -> -0E+90 +decs435 apply -0E+96 -> #c3f00000 Clamped +decs436 apply #c3f00000 -> -0E+90 +decs437 apply -0E+400 -> #c3f00000 Clamped +decs438 apply #c3f00000 -> -0E+90 + +-- Specials +decs500 apply Infinity -> #78000000 +decs501 apply #78787878 -> #78000000 +decs502 apply #78000000 -> Infinity +decs503 apply #79797979 -> #78000000 +decs504 apply #79000000 -> Infinity +decs505 apply #7a7a7a7a -> #78000000 +decs506 apply #7a000000 -> Infinity +decs507 apply #7b7b7b7b -> #78000000 +decs508 apply #7b000000 -> Infinity +decs509 apply #7c7c7c7c -> #7c0c7c7c + +decs510 apply NaN -> #7c000000 +decs511 apply #7c000000 -> NaN +decs512 apply #7d7d7d7d -> #7c0d7d7d +decs513 apply #7d000000 -> NaN +decs514 apply #7e7e7e7e -> #7e0e7c7e +decs515 apply #7e000000 -> sNaN +decs516 apply #7f7f7f7f -> #7e0f7c7f +decs517 apply #7f000000 -> sNaN +decs518 apply #7fffffff -> sNaN999999 +decs519 apply #7fffffff -> #7e03fcff + +decs520 apply -Infinity -> #f8000000 +decs521 apply #f8787878 -> #f8000000 +decs522 apply #f8000000 -> -Infinity +decs523 apply #f9797979 -> #f8000000 +decs524 apply #f9000000 -> -Infinity +decs525 apply #fa7a7a7a -> #f8000000 +decs526 apply #fa000000 -> -Infinity +decs527 apply #fb7b7b7b -> #f8000000 +decs528 apply #fb000000 -> -Infinity + +decs529 apply -NaN -> #fc000000 +decs530 apply #fc7c7c7c -> #fc0c7c7c +decs531 apply #fc000000 -> -NaN +decs532 apply #fd7d7d7d -> #fc0d7d7d +decs533 apply #fd000000 -> -NaN +decs534 apply #fe7e7e7e -> #fe0e7c7e +decs535 apply #fe000000 -> -sNaN +decs536 apply #ff7f7f7f -> #fe0f7c7f +decs537 apply #ff000000 -> -sNaN +decs538 apply #ffffffff -> -sNaN999999 +decs539 apply #ffffffff -> #fe03fcff + +-- diagnostic NaNs +decs540 apply NaN -> #7c000000 +decs541 apply NaN0 -> #7c000000 +decs542 apply NaN1 -> #7c000001 +decs543 apply NaN12 -> #7c000012 +decs544 apply NaN79 -> #7c000079 +decs545 apply NaN12345 -> #7c0049c5 +decs546 apply NaN123456 -> #7c028e56 +decs547 apply NaN799799 -> #7c0f7fdf +decs548 apply NaN999999 -> #7c03fcff + + +-- fold-down full sequence +decs601 apply 1E+96 -> #47f00000 Clamped +decs602 apply #47f00000 -> 1.000000E+96 +decs603 apply 1E+95 -> #43f20000 Clamped +decs604 apply #43f20000 -> 1.00000E+95 +decs605 apply 1E+94 -> #43f04000 Clamped +decs606 apply #43f04000 -> 1.0000E+94 +decs607 apply 1E+93 -> #43f00400 Clamped +decs608 apply #43f00400 -> 1.000E+93 +decs609 apply 1E+92 -> #43f00080 Clamped +decs610 apply #43f00080 -> 1.00E+92 +decs611 apply 1E+91 -> #43f00010 Clamped +decs612 apply #43f00010 -> 1.0E+91 +decs613 apply 1E+90 -> #43f00001 +decs614 apply #43f00001 -> 1E+90 + + +-- Selected DPD codes +decs700 apply #22500000 -> 0 +decs701 apply #22500009 -> 9 +decs702 apply #22500010 -> 10 +decs703 apply #22500019 -> 19 +decs704 apply #22500020 -> 20 +decs705 apply #22500029 -> 29 +decs706 apply #22500030 -> 30 +decs707 apply #22500039 -> 39 +decs708 apply #22500040 -> 40 +decs709 apply #22500049 -> 49 +decs710 apply #22500050 -> 50 +decs711 apply #22500059 -> 59 +decs712 apply #22500060 -> 60 +decs713 apply #22500069 -> 69 +decs714 apply #22500070 -> 70 +decs715 apply #22500071 -> 71 +decs716 apply #22500072 -> 72 +decs717 apply #22500073 -> 73 +decs718 apply #22500074 -> 74 +decs719 apply #22500075 -> 75 +decs720 apply #22500076 -> 76 +decs721 apply #22500077 -> 77 +decs722 apply #22500078 -> 78 +decs723 apply #22500079 -> 79 + +decs730 apply #2250029e -> 994 +decs731 apply #2250029f -> 995 +decs732 apply #225002a0 -> 520 +decs733 apply #225002a1 -> 521 + +-- DPD: one of each of the huffman groups +decs740 apply #225003f7 -> 777 +decs741 apply #225003f8 -> 778 +decs742 apply #225003eb -> 787 +decs743 apply #2250037d -> 877 +decs744 apply #2250039f -> 997 +decs745 apply #225003bf -> 979 +decs746 apply #225003df -> 799 +decs747 apply #2250006e -> 888 + + +-- DPD all-highs cases (includes the 24 redundant codes) +decs750 apply #2250006e -> 888 +decs751 apply #2250016e -> 888 +decs752 apply #2250026e -> 888 +decs753 apply #2250036e -> 888 +decs754 apply #2250006f -> 889 +decs755 apply #2250016f -> 889 +decs756 apply #2250026f -> 889 +decs757 apply #2250036f -> 889 + +decs760 apply #2250007e -> 898 +decs761 apply #2250017e -> 898 +decs762 apply #2250027e -> 898 +decs763 apply #2250037e -> 898 +decs764 apply #2250007f -> 899 +decs765 apply #2250017f -> 899 +decs766 apply #2250027f -> 899 +decs767 apply #2250037f -> 899 + +decs770 apply #225000ee -> 988 +decs771 apply #225001ee -> 988 +decs772 apply #225002ee -> 988 +decs773 apply #225003ee -> 988 +decs774 apply #225000ef -> 989 +decs775 apply #225001ef -> 989 +decs776 apply #225002ef -> 989 +decs777 apply #225003ef -> 989 + +decs780 apply #225000fe -> 998 +decs781 apply #225001fe -> 998 +decs782 apply #225002fe -> 998 +decs783 apply #225003fe -> 998 +decs784 apply #225000ff -> 999 +decs785 apply #225001ff -> 999 +decs786 apply #225002ff -> 999 +decs787 apply #225003ff -> 999 + +-- narrowing case +decs790 apply 2.00E-99 -> #00000100 Subnormal +decs791 apply #00000100 -> 2.00E-99 Subnormal Added: python/branches/release25-maint/Lib/test/decimaltestdata/exp.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/exp.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,674 @@ +------------------------------------------------------------------------ +-- exp.decTest -- decimal natural exponentiation -- +-- Copyright (c) IBM Corporation, 2005, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- Tests of the exponential funtion. Currently all testcases here +-- show results which are correctly rounded (within <= 0.5 ulp). + +extended: 1 +precision: 9 +rounding: half_even +maxExponent: 384 +minexponent: -383 + +-- basics (examples in specificiation, etc.) +expx001 exp -Infinity -> 0 +expx002 exp -10 -> 0.0000453999298 Inexact Rounded +expx003 exp -1 -> 0.367879441 Inexact Rounded +expx004 exp 0 -> 1 +expx005 exp -0 -> 1 +expx006 exp 1 -> 2.71828183 Inexact Rounded +expx007 exp 0.693147181 -> 2.00000000 Inexact Rounded +expx008 exp 10 -> 22026.4658 Inexact Rounded +expx009 exp +Infinity -> Infinity + +-- tiny edge cases +precision: 7 +expx011 exp 0.1 -> 1.105171 Inexact Rounded +expx012 exp 0.01 -> 1.010050 Inexact Rounded +expx013 exp 0.001 -> 1.001001 Inexact Rounded +expx014 exp 0.0001 -> 1.000100 Inexact Rounded +expx015 exp 0.00001 -> 1.000010 Inexact Rounded +expx016 exp 0.000001 -> 1.000001 Inexact Rounded +expx017 exp 0.0000001 -> 1.000000 Inexact Rounded +expx018 exp 0.0000003 -> 1.000000 Inexact Rounded +expx019 exp 0.0000004 -> 1.000000 Inexact Rounded +expx020 exp 0.0000005 -> 1.000001 Inexact Rounded +expx021 exp 0.0000008 -> 1.000001 Inexact Rounded +expx022 exp 0.0000009 -> 1.000001 Inexact Rounded +expx023 exp 0.0000010 -> 1.000001 Inexact Rounded +expx024 exp 0.0000011 -> 1.000001 Inexact Rounded +expx025 exp 0.00000009 -> 1.000000 Inexact Rounded +expx026 exp 0.00000005 -> 1.000000 Inexact Rounded +expx027 exp 0.00000004 -> 1.000000 Inexact Rounded +expx028 exp 0.00000001 -> 1.000000 Inexact Rounded + +-- and some more zeros +expx030 exp 0.00000000 -> 1 +expx031 exp 0E+100 -> 1 +expx032 exp 0E-100 -> 1 +expx033 exp -0.00000000 -> 1 +expx034 exp -0E+100 -> 1 +expx035 exp -0E-100 -> 1 + +-- basic e=0, e=1, e=2, e=4, e>=8 cases +precision: 7 +expx041 exp 1 -> 2.718282 Inexact Rounded +expx042 exp -1 -> 0.3678794 Inexact Rounded +expx043 exp 10 -> 22026.47 Inexact Rounded +expx044 exp -10 -> 0.00004539993 Inexact Rounded +expx045 exp 100 -> 2.688117E+43 Inexact Rounded +expx046 exp -100 -> 3.720076E-44 Inexact Rounded +expx047 exp 1000 -> Infinity Overflow Inexact Rounded +expx048 exp -1000 -> 0E-389 Underflow Inexact Rounded Clamped Subnormal +expx049 exp 100000000 -> Infinity Overflow Inexact Rounded +expx050 exp -100000000 -> 0E-389 Underflow Inexact Rounded Clamped Subnormal + +-- miscellanea +-- similar to 'VF bug' test, at 17, but with last digit corrected for decimal +precision: 16 +expx055 exp -5.42410311287441459172E+2 -> 2.717658486884572E-236 Inexact Rounded +-- result from NetRexx/Java prototype -> 2.7176584868845721117677929628617246054459644711108E-236 +-- result from Rexx (series) version -> 2.717658486884572111767792962861724605446E-236 +precision: 17 +expx056 exp -5.42410311287441459172E+2 -> 2.7176584868845721E-236 Inexact Rounded +precision: 18 +expx057 exp -5.42410311287441459172E+2 -> 2.71765848688457211E-236 Inexact Rounded +precision: 19 +expx058 exp -5.42410311287441459172E+2 -> 2.717658486884572112E-236 Inexact Rounded +precision: 20 +expx059 exp -5.42410311287441459172E+2 -> 2.7176584868845721118E-236 Inexact Rounded + +-- rounding in areas of ..500.., ..499.., ..100.., ..999.. sequences +precision: 50 +expx101 exp -9E-8 -> 0.99999991000000404999987850000273374995079250073811 Inexact Rounded +precision: 31 +expx102 exp -9E-8 -> 0.9999999100000040499998785000027 Inexact Rounded +precision: 30 +expx103 exp -9E-8 -> 0.999999910000004049999878500003 Inexact Rounded +precision: 29 +expx104 exp -9E-8 -> 0.99999991000000404999987850000 Inexact Rounded +precision: 28 +expx105 exp -9E-8 -> 0.9999999100000040499998785000 Inexact Rounded +precision: 27 +expx106 exp -9E-8 -> 0.999999910000004049999878500 Inexact Rounded +precision: 26 +expx107 exp -9E-8 -> 0.99999991000000404999987850 Inexact Rounded +precision: 25 +expx108 exp -9E-8 -> 0.9999999100000040499998785 Inexact Rounded +precision: 24 +expx109 exp -9E-8 -> 0.999999910000004049999879 Inexact Rounded +precision: 23 +expx110 exp -9E-8 -> 0.99999991000000404999988 Inexact Rounded +precision: 22 +expx111 exp -9E-8 -> 0.9999999100000040499999 Inexact Rounded +precision: 21 +expx112 exp -9E-8 -> 0.999999910000004050000 Inexact Rounded +precision: 20 +expx113 exp -9E-8 -> 0.99999991000000405000 Inexact Rounded +precision: 19 +expx114 exp -9E-8 -> 0.9999999100000040500 Inexact Rounded +precision: 18 +expx115 exp -9E-8 -> 0.999999910000004050 Inexact Rounded +precision: 17 +expx116 exp -9E-8 -> 0.99999991000000405 Inexact Rounded +precision: 16 +expx117 exp -9E-8 -> 0.9999999100000040 Inexact Rounded +precision: 15 +expx118 exp -9E-8 -> 0.999999910000004 Inexact Rounded +precision: 14 +expx119 exp -9E-8 -> 0.99999991000000 Inexact Rounded +precision: 13 +expx120 exp -9E-8 -> 0.9999999100000 Inexact Rounded +precision: 12 +expx121 exp -9E-8 -> 0.999999910000 Inexact Rounded +precision: 11 +expx122 exp -9E-8 -> 0.99999991000 Inexact Rounded +precision: 10 +expx123 exp -9E-8 -> 0.9999999100 Inexact Rounded +precision: 9 +expx124 exp -9E-8 -> 0.999999910 Inexact Rounded +precision: 8 +expx125 exp -9E-8 -> 0.99999991 Inexact Rounded +precision: 7 +expx126 exp -9E-8 -> 0.9999999 Inexact Rounded +precision: 6 +expx127 exp -9E-8 -> 1.00000 Inexact Rounded +precision: 5 +expx128 exp -9E-8 -> 1.0000 Inexact Rounded +precision: 4 +expx129 exp -9E-8 -> 1.000 Inexact Rounded +precision: 3 +expx130 exp -9E-8 -> 1.00 Inexact Rounded +precision: 2 +expx131 exp -9E-8 -> 1.0 Inexact Rounded +precision: 1 +expx132 exp -9E-8 -> 1 Inexact Rounded + + +-- sanity checks, with iteration counts [normalized so 0<=|x|<1] +precision: 50 + +expx210 exp 0 -> 1 +-- iterations: 2 +expx211 exp -1E-40 -> 0.99999999999999999999999999999999999999990000000000 Inexact Rounded +-- iterations: 8 +expx212 exp -9E-7 -> 0.99999910000040499987850002733749507925073811240510 Inexact Rounded +-- iterations: 6 +expx213 exp -9E-8 -> 0.99999991000000404999987850000273374995079250073811 Inexact Rounded +-- iterations: 15 +expx214 exp -0.003 -> 0.99700449550337297601206623409756091074177480489845 Inexact Rounded +-- iterations: 14 +expx215 exp -0.001 -> 0.99900049983337499166805535716765597470235590236008 Inexact Rounded +-- iterations: 26 +expx216 exp -0.1 -> 0.90483741803595957316424905944643662119470536098040 Inexact Rounded +-- iterations: 39 +expx217 exp -0.7 -> 0.49658530379140951470480009339752896170766716571182 Inexact Rounded +-- iterations: 41 +expx218 exp -0.9 -> 0.40656965974059911188345423964562598783370337617038 Inexact Rounded +-- iterations: 43 +expx219 exp -0.99 -> 0.37157669102204569053152411990820138691802885490501 Inexact Rounded +-- iterations: 26 +expx220 exp -1 -> 0.36787944117144232159552377016146086744581113103177 Inexact Rounded +-- iterations: 26 +expx221 exp -1.01 -> 0.36421897957152331975704629563734548959589139192482 Inexact Rounded +-- iterations: 27 +expx222 exp -1.1 -> 0.33287108369807955328884690643131552161247952156921 Inexact Rounded +-- iterations: 28 +expx223 exp -1.5 -> 0.22313016014842982893328047076401252134217162936108 Inexact Rounded +-- iterations: 30 +expx224 exp -2 -> 0.13533528323661269189399949497248440340763154590958 Inexact Rounded +-- iterations: 36 +expx225 exp -5 -> 0.0067379469990854670966360484231484242488495850273551 Inexact Rounded +-- iterations: 26 +expx226 exp -10 -> 0.000045399929762484851535591515560550610237918088866565 Inexact Rounded +-- iterations: 28 +expx227 exp -14 -> 8.3152871910356788406398514256526229460765836498457E-7 Inexact Rounded +-- iterations: 29 +expx228 exp -15 -> 3.0590232050182578837147949770228963937082078081856E-7 Inexact Rounded +-- iterations: 30 +expx233 exp 0 -> 1 +-- iterations: 2 +expx234 exp 1E-40 -> 1.0000000000000000000000000000000000000001000000000 Inexact Rounded +-- iterations: 7 +expx235 exp 9E-7 -> 1.0000009000004050001215000273375049207507381125949 Inexact Rounded +-- iterations: 6 +expx236 exp 9E-8 -> 1.0000000900000040500001215000027337500492075007381 Inexact Rounded +-- iterations: 15 +expx237 exp 0.003 -> 1.0030045045033770260129340913489002053318727195619 Inexact Rounded +-- iterations: 13 +expx238 exp 0.001 -> 1.0010005001667083416680557539930583115630762005807 Inexact Rounded +-- iterations: 25 +expx239 exp 0.1 -> 1.1051709180756476248117078264902466682245471947375 Inexact Rounded +-- iterations: 38 +expx240 exp 0.7 -> 2.0137527074704765216245493885830652700175423941459 Inexact Rounded +-- iterations: 41 +expx241 exp 0.9 -> 2.4596031111569496638001265636024706954217723064401 Inexact Rounded +-- iterations: 42 +expx242 exp 0.99 -> 2.6912344723492622890998794040710139721802931841030 Inexact Rounded +-- iterations: 26 +expx243 exp 1 -> 2.7182818284590452353602874713526624977572470937000 Inexact Rounded +-- iterations: 26 +expx244 exp 1.01 -> 2.7456010150169164939897763166603876240737508195960 Inexact Rounded +-- iterations: 26 +expx245 exp 1.1 -> 3.0041660239464331120584079535886723932826810260163 Inexact Rounded +-- iterations: 28 +expx246 exp 1.5 -> 4.4816890703380648226020554601192758190057498683697 Inexact Rounded +-- iterations: 29 +expx247 exp 2 -> 7.3890560989306502272304274605750078131803155705518 Inexact Rounded +-- iterations: 36 +expx248 exp 5 -> 148.41315910257660342111558004055227962348766759388 Inexact Rounded +-- iterations: 26 +expx249 exp 10 -> 22026.465794806716516957900645284244366353512618557 Inexact Rounded +-- iterations: 28 +expx250 exp 14 -> 1202604.2841647767777492367707678594494124865433761 Inexact Rounded +-- iterations: 28 +expx251 exp 15 -> 3269017.3724721106393018550460917213155057385438200 Inexact Rounded +-- iterations: 29 + +-- a biggie [result verified 3 ways] +precision: 250 +expx260 exp 1 -> 2.718281828459045235360287471352662497757247093699959574966967627724076630353547594571382178525166427427466391932003059921817413596629043572900334295260595630738132328627943490763233829880753195251019011573834187930702154089149934884167509244761460668 Inexact Rounded + +-- extreme range boundaries +precision: 16 +maxExponent: 999999 +minExponent: -999999 +-- Ntiny boundary +expx290 exp -2302618.022332529 -> 0E-1000014 Underflow Subnormal Inexact Rounded Clamped +expx291 exp -2302618.022332528 -> 1E-1000014 Underflow Subnormal Inexact Rounded +-- Nmax/10 and Nmax boundary +expx292 exp 2302582.790408952 -> 9.999999993100277E+999998 Inexact Rounded +expx293 exp 2302582.790408953 -> 1.000000000310028E+999999 Inexact Rounded +expx294 exp 2302585.092993946 -> 9.999999003159870E+999999 Inexact Rounded +expx295 exp 2302585.092994036 -> 9.999999903159821E+999999 Inexact Rounded +expx296 exp 2302585.092994045 -> 9.999999993159820E+999999 Inexact Rounded +expx297 exp 2302585.092994046 -> Infinity Overflow Inexact Rounded + +-- 0<-x<<1 effects +precision: 30 +expx320 exp -4.9999999999999E-8 -> 0.999999950000001250000979166617 Inexact Rounded +expx321 exp -5.0000000000000E-8 -> 0.999999950000001249999979166667 Inexact Rounded +expx322 exp -5.0000000000001E-8 -> 0.999999950000001249998979166717 Inexact Rounded +precision: 20 +expx323 exp -4.9999999999999E-8 -> 0.99999995000000125000 Inexact Rounded +expx324 exp -5.0000000000000E-8 -> 0.99999995000000125000 Inexact Rounded +expx325 exp -5.0000000000001E-8 -> 0.99999995000000125000 Inexact Rounded +precision: 14 +expx326 exp -4.9999999999999E-8 -> 0.99999995000000 Inexact Rounded +expx327 exp -5.0000000000000E-8 -> 0.99999995000000 Inexact Rounded +expx328 exp -5.0000000000001E-8 -> 0.99999995000000 Inexact Rounded +-- overprecise and 0<-x<<1 +precision: 8 +expx330 exp -4.9999999999999E-8 -> 0.99999995 Inexact Rounded +expx331 exp -5.0000000000000E-8 -> 0.99999995 Inexact Rounded +expx332 exp -5.0000000000001E-8 -> 0.99999995 Inexact Rounded +precision: 7 +expx333 exp -4.9999999999999E-8 -> 1.000000 Inexact Rounded +expx334 exp -5.0000000000000E-8 -> 1.000000 Inexact Rounded +expx335 exp -5.0000000000001E-8 -> 1.000000 Inexact Rounded +precision: 3 +expx336 exp -4.9999999999999E-8 -> 1.00 Inexact Rounded +expx337 exp -5.0000000000000E-8 -> 1.00 Inexact Rounded +expx338 exp -5.0000000000001E-8 -> 1.00 Inexact Rounded + +-- 0 1.00000005000000124999902083328 Inexact Rounded +expx341 exp 5.0000000000000E-8 -> 1.00000005000000125000002083333 Inexact Rounded +expx342 exp 5.0000000000001E-8 -> 1.00000005000000125000102083338 Inexact Rounded +precision: 20 +expx343 exp 4.9999999999999E-8 -> 1.0000000500000012500 Inexact Rounded +expx344 exp 5.0000000000000E-8 -> 1.0000000500000012500 Inexact Rounded +expx345 exp 5.0000000000001E-8 -> 1.0000000500000012500 Inexact Rounded +precision: 14 +expx346 exp 4.9999999999999E-8 -> 1.0000000500000 Inexact Rounded +expx347 exp 5.0000000000000E-8 -> 1.0000000500000 Inexact Rounded +expx348 exp 5.0000000000001E-8 -> 1.0000000500000 Inexact Rounded +-- overprecise and 0 1.0000001 Inexact Rounded +expx351 exp 5.0000000000000E-8 -> 1.0000001 Inexact Rounded +expx352 exp 5.0000000000001E-8 -> 1.0000001 Inexact Rounded +precision: 7 +expx353 exp 4.9999999999999E-8 -> 1.000000 Inexact Rounded +expx354 exp 5.0000000000000E-8 -> 1.000000 Inexact Rounded +expx355 exp 5.0000000000001E-8 -> 1.000000 Inexact Rounded +precision: 3 +expx356 exp 4.9999999999999E-8 -> 1.00 Inexact Rounded +expx357 exp 5.0000000000000E-8 -> 1.00 Inexact Rounded +expx358 exp 5.0000000000001E-8 -> 1.00 Inexact Rounded + +-- cases near 1 -- 1 2345678901234567890 +precision: 20 +expx401 exp 0.99999999999996 -> 2.7182818284589365041 Inexact Rounded +expx402 exp 0.99999999999997 -> 2.7182818284589636869 Inexact Rounded +expx403 exp 0.99999999999998 -> 2.7182818284589908697 Inexact Rounded +expx404 exp 0.99999999999999 -> 2.7182818284590180525 Inexact Rounded +expx405 exp 1.0000000000000 -> 2.7182818284590452354 Inexact Rounded +expx406 exp 1.0000000000001 -> 2.7182818284593170635 Inexact Rounded +expx407 exp 1.0000000000002 -> 2.7182818284595888917 Inexact Rounded +precision: 14 +expx411 exp 0.99999999999996 -> 2.7182818284589 Inexact Rounded +expx412 exp 0.99999999999997 -> 2.7182818284590 Inexact Rounded +expx413 exp 0.99999999999998 -> 2.7182818284590 Inexact Rounded +expx414 exp 0.99999999999999 -> 2.7182818284590 Inexact Rounded +expx415 exp 1.0000000000000 -> 2.7182818284590 Inexact Rounded +expx416 exp 1.0000000000001 -> 2.7182818284593 Inexact Rounded +expx417 exp 1.0000000000002 -> 2.7182818284596 Inexact Rounded +-- overprecise... +precision: 7 +expx421 exp 0.99999999999996 -> 2.718282 Inexact Rounded +expx422 exp 0.99999999999997 -> 2.718282 Inexact Rounded +expx423 exp 0.99999999999998 -> 2.718282 Inexact Rounded +expx424 exp 0.99999999999999 -> 2.718282 Inexact Rounded +expx425 exp 1.0000000000001 -> 2.718282 Inexact Rounded +expx426 exp 1.0000000000002 -> 2.718282 Inexact Rounded +expx427 exp 1.0000000000003 -> 2.718282 Inexact Rounded +precision: 2 +expx431 exp 0.99999999999996 -> 2.7 Inexact Rounded +expx432 exp 0.99999999999997 -> 2.7 Inexact Rounded +expx433 exp 0.99999999999998 -> 2.7 Inexact Rounded +expx434 exp 0.99999999999999 -> 2.7 Inexact Rounded +expx435 exp 1.0000000000001 -> 2.7 Inexact Rounded +expx436 exp 1.0000000000002 -> 2.7 Inexact Rounded +expx437 exp 1.0000000000003 -> 2.7 Inexact Rounded + +-- basics at low precisions +precision: 3 +expx501 exp -Infinity -> 0 +expx502 exp -10 -> 0.0000454 Inexact Rounded +expx503 exp -1 -> 0.368 Inexact Rounded +expx504 exp 0 -> 1 +expx505 exp -0 -> 1 +expx506 exp 1 -> 2.72 Inexact Rounded +expx507 exp 0.693147181 -> 2.00 Inexact Rounded +expx508 exp 10 -> 2.20E+4 Inexact Rounded +expx509 exp +Infinity -> Infinity +precision: 2 +expx511 exp -Infinity -> 0 +expx512 exp -10 -> 0.000045 Inexact Rounded +expx513 exp -1 -> 0.37 Inexact Rounded +expx514 exp 0 -> 1 +expx515 exp -0 -> 1 +expx516 exp 1 -> 2.7 Inexact Rounded +expx517 exp 0.693147181 -> 2.0 Inexact Rounded +expx518 exp 10 -> 2.2E+4 Inexact Rounded +expx519 exp +Infinity -> Infinity +precision: 1 +expx521 exp -Infinity -> 0 +expx522 exp -10 -> 0.00005 Inexact Rounded +expx523 exp -1 -> 0.4 Inexact Rounded +expx524 exp 0 -> 1 +expx525 exp -0 -> 1 +expx526 exp 1 -> 3 Inexact Rounded +expx527 exp 0.693147181 -> 2 Inexact Rounded +expx528 exp 10 -> 2E+4 Inexact Rounded +expx529 exp +Infinity -> Infinity + +-- overflows, including some overprecise borderlines +precision: 7 +maxExponent: 384 +minExponent: -383 +expx701 exp 1000000000 -> Infinity Overflow Inexact Rounded +expx702 exp 100000000 -> Infinity Overflow Inexact Rounded +expx703 exp 10000000 -> Infinity Overflow Inexact Rounded +expx704 exp 1000000 -> Infinity Overflow Inexact Rounded +expx705 exp 100000 -> Infinity Overflow Inexact Rounded +expx706 exp 10000 -> Infinity Overflow Inexact Rounded +expx707 exp 1000 -> Infinity Overflow Inexact Rounded +expx708 exp 886.4952608 -> Infinity Overflow Inexact Rounded +expx709 exp 886.4952607 -> 9.999999E+384 Inexact Rounded +expx710 exp 886.49527 -> Infinity Overflow Inexact Rounded +expx711 exp 886.49526 -> 9.999992E+384 Inexact Rounded +precision: 16 +expx721 exp 886.4952608027075883 -> Infinity Overflow Inexact Rounded +expx722 exp 886.4952608027075882 -> 9.999999999999999E+384 Inexact Rounded +expx723 exp 886.49526080270759 -> Infinity Overflow Inexact Rounded +expx724 exp 886.49526080270758 -> 9.999999999999917E+384 Inexact Rounded +expx725 exp 886.4952608027076 -> Infinity Overflow Inexact Rounded +expx726 exp 886.4952608027075 -> 9.999999999999117E+384 Inexact Rounded +-- and by special request ... +precision: 15 +expx731 exp 886.495260802708 -> Infinity Overflow Inexact Rounded +expx732 exp 886.495260802707 -> 9.99999999999412E+384 Inexact Rounded +expx733 exp 886.495260802706 -> 9.99999999998412E+384 Inexact Rounded +maxExponent: 999 +minExponent: -999 +expx735 exp 2302.58509299405 -> Infinity Overflow Inexact Rounded +expx736 exp 2302.58509299404 -> 9.99999999994316E+999 Inexact Rounded +expx737 exp 2302.58509299403 -> 9.99999999984316E+999 Inexact Rounded + +-- subnormals and underflows, including underflow-to-zero edge point +precision: 7 +maxExponent: 384 +minExponent: -383 +expx751 exp -1000000000 -> 0E-389 Underflow Inexact Rounded Clamped Subnormal +expx752 exp -100000000 -> 0E-389 Underflow Inexact Rounded Clamped Subnormal +expx753 exp -10000000 -> 0E-389 Underflow Inexact Rounded Clamped Subnormal +expx754 exp -1000000 -> 0E-389 Underflow Inexact Rounded Clamped Subnormal +expx755 exp -100000 -> 0E-389 Underflow Inexact Rounded Clamped Subnormal +expx756 exp -10000 -> 0E-389 Underflow Inexact Rounded Clamped Subnormal +expx757 exp -1000 -> 0E-389 Underflow Inexact Rounded Clamped Subnormal +expx758 exp -881.89009 -> 1.000001E-383 Inexact Rounded +expx759 exp -881.8901 -> 9.99991E-384 Inexact Rounded Underflow Subnormal +expx760 exp -885 -> 4.4605E-385 Inexact Rounded Underflow Subnormal +expx761 exp -888 -> 2.221E-386 Inexact Rounded Underflow Subnormal +expx762 exp -890 -> 3.01E-387 Inexact Rounded Underflow Subnormal +expx763 exp -892.9 -> 1.7E-388 Inexact Rounded Underflow Subnormal +expx764 exp -893 -> 1.5E-388 Inexact Rounded Underflow Subnormal +expx765 exp -893.5 -> 9E-389 Inexact Rounded Underflow Subnormal +expx766 exp -895.7056 -> 1E-389 Inexact Rounded Underflow Subnormal +expx769 exp -895.8 -> 1E-389 Inexact Rounded Underflow Subnormal +expx770 exp -895.73 -> 1E-389 Inexact Rounded Underflow Subnormal +expx771 exp -896.3987 -> 1E-389 Inexact Rounded Underflow Subnormal +expx772 exp -896.3988 -> 0E-389 Inexact Rounded Underflow Subnormal Clamped +expx773 exp -898.0081 -> 0E-389 Inexact Rounded Underflow Subnormal Clamped +expx774 exp -898.0082 -> 0E-389 Inexact Rounded Underflow Subnormal Clamped + +-- special values +maxexponent: 999 +minexponent: -999 +expx820 exp Inf -> Infinity +expx821 exp -Inf -> 0 +expx822 exp NaN -> NaN +expx823 exp sNaN -> NaN Invalid_operation +-- propagating NaNs +expx824 exp sNaN123 -> NaN123 Invalid_operation +expx825 exp -sNaN321 -> -NaN321 Invalid_operation +expx826 exp NaN456 -> NaN456 +expx827 exp -NaN654 -> -NaN654 +expx828 exp NaN1 -> NaN1 + +-- Invalid operations due to restrictions +-- [next two probably skipped by most test harnesses] +precision: 100000000 +expx901 exp -Infinity -> NaN Invalid_context +precision: 99999999 +expx902 exp -Infinity -> NaN Invalid_context + +precision: 9 +maxExponent: 1000000 +minExponent: -999999 +expx903 exp -Infinity -> NaN Invalid_context +maxExponent: 999999 +minExponent: -999999 +expx904 exp -Infinity -> 0 +maxExponent: 999999 +minExponent: -1000000 +expx905 exp -Infinity -> NaN Invalid_context +maxExponent: 999999 +minExponent: -999998 +expx906 exp -Infinity -> 0 + +-- +maxExponent: 384 +minExponent: -383 +precision: 16 +rounding: half_even + +-- Null test +expx900 exp # -> NaN Invalid_operation + + +-- Randoms P=50, within 0-999 +Precision: 50 +maxExponent: 384 +minExponent: -383 +expx1501 exp 656.35397950590285612266095596539934213943872885728 -> 1.1243757610640319783611178528839652672062820040314E+285 Inexact Rounded +expx1502 exp 0.93620571093652800225038550600780322831236082781471 -> 2.5502865130986176689199711857825771311178046842009 Inexact Rounded +expx1503 exp 0.00000000000000008340785856601514714183373874105791 -> 1.0000000000000000834078585660151506202691740252512 Inexact Rounded +expx1504 exp 0.00009174057262887789625745574686545163168788456203 -> 1.0000917447809239005146722341251524081006051473273 Inexact Rounded +expx1505 exp 33.909116897973797735657751591014926629051117541243 -> 532773181025002.03543618901306726495870476617232229 Inexact Rounded +expx1506 exp 0.00000740470413004406592124575295278456936809587311 -> 1.0000074047315449333590066395670306135567889210814 Inexact Rounded +expx1507 exp 0.00000000000124854922222108802453746922483071445492 -> 1.0000000000012485492222218674621176239911424968263 Inexact Rounded +expx1508 exp 4.1793280674155659794286951159430651258356014391382 -> 65.321946520147199404199787811336860087975118278185 Inexact Rounded +expx1509 exp 485.43595745460655893746179890255529919221550201686 -> 6.6398403920459617255950476953129377459845366585463E+210 Inexact Rounded +expx1510 exp 0.00000000003547259806590856032527875157830328156597 -> 1.0000000000354725980665377129320589406715000685515 Inexact Rounded +expx1511 exp 0.00000000000000759621497339104047930616478635042678 -> 1.0000000000000075962149733910693305471257715463887 Inexact Rounded +expx1512 exp 9.7959168821760339304571595474480640286072720233796 -> 17960.261146042955179164303653412650751681436352437 Inexact Rounded +expx1513 exp 0.00000000566642006258290526783901451194943164535581 -> 1.0000000056664200786370634609832438815665249347650 Inexact Rounded +expx1514 exp 741.29888791134298194088827572374718940925820027354 -> 8.7501694006317332808128946666402622432064923198731E+321 Inexact Rounded +expx1515 exp 032.75573003552517668808529099897153710887014947935 -> 168125196578678.17725841108617955904425345631092339 Inexact Rounded +expx1516 exp 42.333700726429333308594265553422902463737399437644 -> 2428245675864172475.4681119493045657797309369672012 Inexact Rounded +expx1517 exp 0.00000000000000559682616876491888197609158802835798 -> 1.0000000000000055968261687649345442076732739577049 Inexact Rounded +expx1518 exp 0.00000000000080703688668280193584758300973549486312 -> 1.0000000000008070368866831275901158164321867914342 Inexact Rounded +expx1519 exp 640.72396012796509482382712891709072570653606838251 -> 1.8318094990683394229304133068983914236995326891045E+278 Inexact Rounded +expx1520 exp 0.00000000000000509458922167631071416948112219512224 -> 1.0000000000000050945892216763236915891499324358556 Inexact Rounded +expx1521 exp 6.7670394314315206378625221583973414660727960241395 -> 868.73613012822031367806248697092884415119568271315 Inexact Rounded +expx1522 exp 04.823217407412963506638267226891024138054783122548 -> 124.36457929588837129731821077586705505565904205366 Inexact Rounded +expx1523 exp 193.51307878701196403991208482520115359690106143615 -> 1.1006830872854715677390914655452261550768957576034E+84 Inexact Rounded +expx1524 exp 5.7307749038303650539200345901210497015617393970463 -> 308.20800743106843083522721523715645950574866495196 Inexact Rounded +expx1525 exp 0.00000000000095217825199797965200541169123743500267 -> 1.0000000000009521782519984329737172007991390381273 Inexact Rounded +expx1526 exp 0.00027131440949183370966393682617930153495028919140 -> 1.0002713512185751022906058160480606598754913607364 Inexact Rounded +expx1527 exp 0.00000000064503059114680682343002315662069272707123 -> 1.0000000006450305913548390552323517403613135496633 Inexact Rounded +expx1528 exp 0.00000000000000095616643506527288866235238548440593 -> 1.0000000000000009561664350652733457894781582009094 Inexact Rounded +expx1529 exp 0.00000000000000086449942811678650244459550252743433 -> 1.0000000000000008644994281167868761242261096529986 Inexact Rounded +expx1530 exp 0.06223488355635359965683053157729204988381887621850 -> 1.0642122813392406657789688931838919323826250630831 Inexact Rounded +expx1531 exp 0.00000400710807804429435502657131912308680674057053 -> 1.0000040071161065125925620890019319832127863559260 Inexact Rounded +expx1532 exp 85.522796894744576211573232055494551429297878413017 -> 13870073686404228452757799770251085177.853337368935 Inexact Rounded +expx1533 exp 9.1496720811363678696938036379756663548353399954363 -> 9411.3537122832743386783597629161763057370034495157 Inexact Rounded +expx1534 exp 8.2215705240788294472944382056330516738577785177942 -> 3720.3406813383076953899654701615084425598377758189 Inexact Rounded +expx1535 exp 0.00000000015772064569640613142823203726821076239561 -> 1.0000000001577206457088440324683315788358926129830 Inexact Rounded +expx1536 exp 0.58179346473959531432624153576883440625538017532480 -> 1.7892445018275360163797022372655837188423194863605 Inexact Rounded +expx1537 exp 33.555726197149525061455517784870570470833498096559 -> 374168069896324.62578073148993526626307095854407952 Inexact Rounded +expx1538 exp 9.7898079803906215094140010009583375537259810398659 -> 17850.878119912208888217100998019986634620368538426 Inexact Rounded +expx1539 exp 89.157697327174521542502447953032536541038636966347 -> 525649152320166503771224149330448089550.67293829227 Inexact Rounded +expx1540 exp 25.022947600123328912029051897171319573322888514885 -> 73676343442.952517824345431437683153304645851960524 Inexact Rounded + +-- exp(1) at 34 +Precision: 34 +expx1200 exp 1 -> 2.718281828459045235360287471352662 Inexact Rounded + +-- Randoms P=34, within 0-999 +Precision: 34 +maxExponent: 6144 +minExponent: -6143 +expx1201 exp 309.5948855821510212996700645087188 -> 2.853319692901387521201738015050724E+134 Inexact Rounded +expx1202 exp 9.936543068706211420422803962680164 -> 20672.15839203171877476511093276022 Inexact Rounded +expx1203 exp 6.307870323881505684429839491707908 -> 548.8747777054637296137277391754665 Inexact Rounded +expx1204 exp 0.0003543281389438420535201308282503 -> 1.000354390920573746164733350843155 Inexact Rounded +expx1205 exp 0.0000037087453363918375598394920229 -> 1.000003708752213796324841920189323 Inexact Rounded +expx1206 exp 0.0020432312687512438040222444116585 -> 1.002045320088164826013561630975308 Inexact Rounded +expx1207 exp 6.856313340032177672550343216129586 -> 949.8587981604144147983589660524396 Inexact Rounded +expx1208 exp 0.0000000000402094928333815643326418 -> 1.000000000040209492834189965989612 Inexact Rounded +expx1209 exp 0.0049610784722412117632647003545839 -> 1.004973404997901987039589029277833 Inexact Rounded +expx1210 exp 0.0000891471883724066909746786702686 -> 1.000089151162101085412780088266699 Inexact Rounded +expx1211 exp 08.59979170376061890684723211112566 -> 5430.528314920905714615339273738097 Inexact Rounded +expx1212 exp 9.473117039341003854872778112752590 -> 13005.36234331224953460055897913917 Inexact Rounded +expx1213 exp 0.0999060724692207648429969999310118 -> 1.105067116975190602296052700726802 Inexact Rounded +expx1214 exp 0.0000000927804533555877884082269247 -> 1.000000092780457659694183954740772 Inexact Rounded +expx1215 exp 0.0376578583872889916298772818265677 -> 1.038375900489771946477857818447556 Inexact Rounded +expx1216 exp 261.6896411697539524911536116712307 -> 4.470613562127465095241600174941460E+113 Inexact Rounded +expx1217 exp 0.0709997423269162980875824213889626 -> 1.073580949235407949417814485533172 Inexact Rounded +expx1218 exp 0.0000000444605583295169895235658731 -> 1.000000044460559317887627657593900 Inexact Rounded +expx1219 exp 0.0000021224072854777512281369815185 -> 1.000002122409537785687390631070906 Inexact Rounded +expx1220 exp 547.5174462574156885473558485475052 -> 6.078629247383807942612114579728672E+237 Inexact Rounded +expx1221 exp 0.0000009067598041615192002339844670 -> 1.000000906760215268314680115374387 Inexact Rounded +expx1222 exp 0.0316476500308065365803455533244603 -> 1.032153761880187977658387961769034 Inexact Rounded +expx1223 exp 84.46160530377645101833996706384473 -> 4.799644995897968383503269871697856E+36 Inexact Rounded +expx1224 exp 0.0000000000520599740290848018904145 -> 1.000000000052059974030439922338393 Inexact Rounded +expx1225 exp 0.0000006748530640093620665651726708 -> 1.000000674853291722742292331812997 Inexact Rounded +expx1226 exp 0.0000000116853119761042020507916169 -> 1.000000011685312044377460306165203 Inexact Rounded +expx1227 exp 0.0022593818094258636727616886693280 -> 1.002261936135876893707094845543461 Inexact Rounded +expx1228 exp 0.0029398857673478912249856509667517 -> 1.002944211469495086813087651287012 Inexact Rounded +expx1229 exp 0.7511480029928802775376270557636963 -> 2.119431734510320169806976569366789 Inexact Rounded +expx1230 exp 174.9431952176750671150886423048447 -> 9.481222305374955011464619468044051E+75 Inexact Rounded +expx1231 exp 0.0000810612451694136129199895164424 -> 1.000081064530720924186615149646920 Inexact Rounded +expx1232 exp 51.06888989702669288180946272499035 -> 15098613888619165073959.89896018749 Inexact Rounded +expx1233 exp 0.0000000005992887599437093651494510 -> 1.000000000599288760123282874082758 Inexact Rounded +expx1234 exp 714.8549046761054856311108828903972 -> 2.867744544891081117381595080480784E+310 Inexact Rounded +expx1235 exp 0.0000000004468247802990643645607110 -> 1.000000000446824780398890556720233 Inexact Rounded +expx1236 exp 831.5818151589890366323551672043709 -> 1.417077409182624969435938062261655E+361 Inexact Rounded +expx1237 exp 0.0000000006868323825179605747108044 -> 1.000000000686832382753829935602454 Inexact Rounded +expx1238 exp 0.0000001306740266408976840228440255 -> 1.000000130674035178748675187648098 Inexact Rounded +expx1239 exp 0.3182210609022267704811502412335163 -> 1.374680115667798185758927247894859 Inexact Rounded +expx1240 exp 0.0147741234179104437440264644295501 -> 1.014883800239950682628277534839222 Inexact Rounded + +-- Randoms P=16, within 0-99 +Precision: 16 +maxExponent: 384 +minExponent: -383 +expx1101 exp 8.473011527013724 -> 4783.900643969246 Inexact Rounded +expx1102 exp 0.0000055753022764 -> 1.000005575317818 Inexact Rounded +expx1103 exp 0.0000323474114482 -> 1.000032347934631 Inexact Rounded +expx1104 exp 64.54374138544166 -> 1.073966476173531E+28 Inexact Rounded +expx1105 exp 90.47203246416569 -> 1.956610887250643E+39 Inexact Rounded +expx1106 exp 9.299931532342757 -> 10937.27033325227 Inexact Rounded +expx1107 exp 8.759678437852203 -> 6372.062234495381 Inexact Rounded +expx1108 exp 0.0000931755127172 -> 1.000093179853690 Inexact Rounded +expx1109 exp 0.0000028101158373 -> 1.000002810119786 Inexact Rounded +expx1110 exp 0.0000008008130919 -> 1.000000800813413 Inexact Rounded +expx1111 exp 8.339771722299049 -> 4187.133803081878 Inexact Rounded +expx1112 exp 0.0026140497995474 -> 1.002617469406750 Inexact Rounded +expx1113 exp 0.7478033356261771 -> 2.112354781975418 Inexact Rounded +expx1114 exp 51.77663761827966 -> 3.064135801120365E+22 Inexact Rounded +expx1115 exp 0.1524989783061012 -> 1.164741272084955 Inexact Rounded +expx1116 exp 0.0066298798669219 -> 1.006651906170791 Inexact Rounded +expx1117 exp 9.955141865534960 -> 21060.23334287038 Inexact Rounded +expx1118 exp 92.34503059198483 -> 1.273318993481226E+40 Inexact Rounded +expx1119 exp 0.0000709388677346 -> 1.000070941383956 Inexact Rounded +expx1120 exp 79.12883036433204 -> 2.318538899389243E+34 Inexact Rounded +expx1121 exp 0.0000090881548873 -> 1.000009088196185 Inexact Rounded +expx1122 exp 0.0424828809603411 -> 1.043398194245720 Inexact Rounded +expx1123 exp 0.8009035891427416 -> 2.227552811933310 Inexact Rounded +expx1124 exp 8.825786167283102 -> 6807.540455289995 Inexact Rounded +expx1125 exp 1.535457249746275 -> 4.643448260146849 Inexact Rounded +expx1126 exp 69.02254254355800 -> 9.464754500670653E+29 Inexact Rounded +expx1127 exp 0.0007050554368713 -> 1.000705304046880 Inexact Rounded +expx1128 exp 0.0000081206549504 -> 1.000008120687923 Inexact Rounded +expx1129 exp 0.621774854641137 -> 1.862230298554903 Inexact Rounded +expx1130 exp 3.847629031404354 -> 46.88177613568203 Inexact Rounded +expx1131 exp 24.81250184697732 -> 59694268456.19966 Inexact Rounded +expx1132 exp 5.107546500516044 -> 165.2643809755670 Inexact Rounded +expx1133 exp 79.17810943951986 -> 2.435656372541360E+34 Inexact Rounded +expx1134 exp 0.0051394695667015 -> 1.005152699295301 Inexact Rounded +expx1135 exp 57.44504488501725 -> 8.872908566929688E+24 Inexact Rounded +expx1136 exp 0.0000508388968036 -> 1.000050840189122 Inexact Rounded +expx1137 exp 69.71309932148997 -> 1.888053740693541E+30 Inexact Rounded +expx1138 exp 0.0064183412981502 -> 1.006438982988835 Inexact Rounded +expx1139 exp 9.346991220814677 -> 11464.27802035082 Inexact Rounded +expx1140 exp 33.09087139999152 -> 235062229168763.5 Inexact Rounded + +-- Randoms P=7, within 0-9 +Precision: 7 +maxExponent: 96 +minExponent: -95 +expx1001 exp 2.395441 -> 10.97304 Inexact Rounded +expx1002 exp 0.6406779 -> 1.897767 Inexact Rounded +expx1003 exp 0.5618218 -> 1.753865 Inexact Rounded +expx1004 exp 3.055120 -> 21.22373 Inexact Rounded +expx1005 exp 1.536792 -> 4.649650 Inexact Rounded +expx1006 exp 0.0801591 -> 1.083459 Inexact Rounded +expx1007 exp 0.0966875 -> 1.101516 Inexact Rounded +expx1008 exp 0.0646761 -> 1.066813 Inexact Rounded +expx1009 exp 0.0095670 -> 1.009613 Inexact Rounded +expx1010 exp 2.956859 -> 19.23745 Inexact Rounded +expx1011 exp 7.504679 -> 1816.522 Inexact Rounded +expx1012 exp 0.0045259 -> 1.004536 Inexact Rounded +expx1013 exp 3.810071 -> 45.15364 Inexact Rounded +expx1014 exp 1.502390 -> 4.492413 Inexact Rounded +expx1015 exp 0.0321523 -> 1.032675 Inexact Rounded +expx1016 exp 0.0057214 -> 1.005738 Inexact Rounded +expx1017 exp 9.811445 -> 18241.33 Inexact Rounded +expx1018 exp 3.245249 -> 25.66810 Inexact Rounded +expx1019 exp 0.3189742 -> 1.375716 Inexact Rounded +expx1020 exp 0.8621610 -> 2.368273 Inexact Rounded +expx1021 exp 0.0122511 -> 1.012326 Inexact Rounded +expx1022 exp 2.202088 -> 9.043877 Inexact Rounded +expx1023 exp 8.778203 -> 6491.202 Inexact Rounded +expx1024 exp 0.1896279 -> 1.208800 Inexact Rounded +expx1025 exp 0.4510947 -> 1.570030 Inexact Rounded +expx1026 exp 0.276413 -> 1.318392 Inexact Rounded +expx1027 exp 4.490067 -> 89.12742 Inexact Rounded +expx1028 exp 0.0439786 -> 1.044960 Inexact Rounded +expx1029 exp 0.8168245 -> 2.263301 Inexact Rounded +expx1030 exp 0.0391658 -> 1.039943 Inexact Rounded +expx1031 exp 9.261816 -> 10528.24 Inexact Rounded +expx1032 exp 9.611186 -> 14930.87 Inexact Rounded +expx1033 exp 9.118125 -> 9119.087 Inexact Rounded +expx1034 exp 9.469083 -> 12953.00 Inexact Rounded +expx1035 exp 0.0499983 -> 1.051269 Inexact Rounded +expx1036 exp 0.0050746 -> 1.005087 Inexact Rounded +expx1037 exp 0.0014696 -> 1.001471 Inexact Rounded +expx1038 exp 9.138494 -> 9306.739 Inexact Rounded +expx1039 exp 0.0065436 -> 1.006565 Inexact Rounded +expx1040 exp 0.7284803 -> 2.071930 Inexact Rounded + Added: python/branches/release25-maint/Lib/test/decimaltestdata/extra.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/extra.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,2673 @@ +version: ?.?? + +extended: 1 +rounding: half_even + +-- testing folddown and clamping +maxexponent: 9 +minexponent: -9 +precision: 6 +clamp: 1 +extr0000 apply 1E+11 -> Infinity Overflow Inexact Rounded +extr0001 apply 1E+10 -> Infinity Overflow Inexact Rounded +extr0002 apply 1E+9 -> 1.00000E+9 Clamped +extr0003 apply 1E+8 -> 1.0000E+8 Clamped +extr0004 apply 1E+7 -> 1.000E+7 Clamped +extr0005 apply 1E+6 -> 1.00E+6 Clamped +extr0006 apply 1E+5 -> 1.0E+5 Clamped +extr0007 apply 1E+4 -> 1E+4 +extr0008 apply 1E+3 -> 1E+3 +extr0009 apply 1E+2 -> 1E+2 +extr0010 apply 1E+1 -> 1E+1 +extr0011 apply 1 -> 1 +extr0012 apply 1E-1 -> 0.1 +extr0013 apply 1E-2 -> 0.01 +extr0014 apply 1E-3 -> 0.001 +extr0015 apply 1E-4 -> 0.0001 +extr0016 apply 1E-5 -> 0.00001 +extr0017 apply 1E-6 -> 0.000001 +extr0018 apply 1E-7 -> 1E-7 +extr0019 apply 1E-8 -> 1E-8 +extr0020 apply 1E-9 -> 1E-9 +extr0021 apply 1E-10 -> 1E-10 Subnormal +extr0022 apply 1E-11 -> 1E-11 Subnormal +extr0023 apply 1E-12 -> 1E-12 Subnormal +extr0024 apply 1E-13 -> 1E-13 Subnormal +extr0025 apply 1E-14 -> 1E-14 Subnormal +extr0026 apply 1E-15 -> 0E-14 Inexact Rounded Subnormal Underflow Clamped +extr0027 apply 1E-16 -> 0E-14 Inexact Rounded Subnormal Underflow Clamped +clamp: 0 + +-- large precision, small minimum and maximum exponent; in this case +-- it's possible that folddown is required on a subnormal result +maxexponent: 9 +minexponent: -9 +precision: 24 +clamp: 1 +extr0100 apply 1E+11 -> Infinity Overflow Inexact Rounded +extr0101 apply 1E+10 -> Infinity Overflow Inexact Rounded +extr0102 apply 1E+9 -> 1000000000.00000000000000 Clamped +extr0103 apply 1E+8 -> 100000000.00000000000000 Clamped +extr0104 apply 1E+7 -> 10000000.00000000000000 Clamped +extr0105 apply 1E+6 -> 1000000.00000000000000 Clamped +extr0106 apply 1E+5 -> 100000.00000000000000 Clamped +extr0107 apply 1E+4 -> 10000.00000000000000 Clamped +extr0108 apply 1E+3 -> 1000.00000000000000 Clamped +extr0109 apply 1E+2 -> 100.00000000000000 Clamped +extr0110 apply 1E+1 -> 10.00000000000000 Clamped +extr0111 apply 1 -> 1.00000000000000 Clamped +extr0112 apply 1E-1 -> 0.10000000000000 Clamped +extr0113 apply 1E-2 -> 0.01000000000000 Clamped +extr0114 apply 1E-3 -> 0.00100000000000 Clamped +extr0115 apply 1E-4 -> 0.00010000000000 Clamped +extr0116 apply 1E-5 -> 0.00001000000000 Clamped +extr0117 apply 1E-6 -> 0.00000100000000 Clamped +extr0118 apply 1E-7 -> 1.0000000E-7 Clamped +extr0119 apply 1E-8 -> 1.000000E-8 Clamped +extr0120 apply 1E-9 -> 1.00000E-9 Clamped +extr0121 apply 1E-10 -> 1.0000E-10 Subnormal Clamped +extr0122 apply 1E-11 -> 1.000E-11 Subnormal Clamped +extr0123 apply 1E-12 -> 1.00E-12 Subnormal Clamped +extr0124 apply 1E-13 -> 1.0E-13 Subnormal Clamped +extr0125 apply 1E-14 -> 1E-14 Subnormal +extr0126 apply 1E-15 -> 1E-15 Subnormal +extr0127 apply 1E-16 -> 1E-16 Subnormal +extr0128 apply 1E-17 -> 1E-17 Subnormal +extr0129 apply 1E-18 -> 1E-18 Subnormal +extr0130 apply 1E-19 -> 1E-19 Subnormal +extr0131 apply 1E-20 -> 1E-20 Subnormal +extr0132 apply 1E-21 -> 1E-21 Subnormal +extr0133 apply 1E-22 -> 1E-22 Subnormal +extr0134 apply 1E-23 -> 1E-23 Subnormal +extr0135 apply 1E-24 -> 1E-24 Subnormal +extr0136 apply 1E-25 -> 1E-25 Subnormal +extr0137 apply 1E-26 -> 1E-26 Subnormal +extr0138 apply 1E-27 -> 1E-27 Subnormal +extr0139 apply 1E-28 -> 1E-28 Subnormal +extr0140 apply 1E-29 -> 1E-29 Subnormal +extr0141 apply 1E-30 -> 1E-30 Subnormal +extr0142 apply 1E-31 -> 1E-31 Subnormal +extr0143 apply 1E-32 -> 1E-32 Subnormal +extr0144 apply 1E-33 -> 0E-32 Inexact Rounded Subnormal Underflow Clamped +extr0145 apply 1E-34 -> 0E-32 Inexact Rounded Subnormal Underflow Clamped +clamp: 0 + +-- some buggy addition cases from Python 2.5.x +maxexponent: 999 +minexponent: -999 +precision: 6 +extr1000 add 0E+1000 0E+2000 -> 0E+999 Clamped +extr1001 add 0E+1004 0E+1001 -> 0E+999 Clamped +clamp: 1 +extr1002 add 0E+1000 0E+1000 -> 0E+994 Clamped +clamp: 0 +extr1003 add 0E+1000 0E-1005 -> 0E-1004 Clamped +extr1004 add 0E-1006 0 -> 0E-1004 Clamped +extr1005 add 1E+1000 -1E+1000 -> 0E+999 Clamped +extr1006 add -3.1E+1004 3.1E+1004 -> 0E+999 Clamped +clamp: 1 +extr1007 add 1E+998 -1E+998 -> 0E+994 Clamped +clamp: 0 +extr1008 add 2E-1005 -2E-1005 -> 0E-1004 Clamped +extr1009 add -3.1E-1005 3.1E-1005 -> 0E-1004 Clamped + +precision: 3 +extr1010 add 99949.9 0.200000 -> 1.00E+5 Inexact Rounded +extr1011 add 99949.9 0.100000 -> 1.00E+5 Inexact Rounded +extr1012 add 99849.9 0.200000 -> 9.99E+4 Inexact Rounded +extr1013 add 99849.9 0.100000 -> 9.98E+4 Inexact Rounded +extr1014 add 1.0149 0.00011 -> 1.02 Inexact Rounded +extr1015 add 1.0149 0.00010 -> 1.02 Inexact Rounded +extr1016 add 1.0149 0.00009 -> 1.01 Inexact Rounded +extr1017 add 1.0049 0.00011 -> 1.01 Inexact Rounded +extr1018 add 1.0049 0.00010 -> 1.00 Inexact Rounded +extr1019 add 1.0049 0.00009 -> 1.00 Inexact Rounded +rounding: down +extr1020 add 99999.9 0.200000 -> 1.00E+5 Inexact Rounded +extr1021 add 99999.8 0.200000 -> 1.00E+5 Rounded +extr1022 add 99999.7 0.200000 -> 9.99E+4 Inexact Rounded +rounding: half_even + +-- a bug in _rescale caused the following to fail in Python 2.5.1 +maxexponent: 999 +minexponent: -999 +precision: 6 +extr1100 add 0E+1000 1E+1000 -> Infinity Overflow Inexact Rounded +extr1101 remainder 1E+1000 2E+1000 -> Infinity Overflow Inexact Rounded + +-- tests for scaleb in case where input precision > context precision. +-- Result should be rounded. (This isn't totally clear from the +-- specification, but the treatment of underflow in the testcases +-- suggests that rounding should occur in general. Furthermore, it's +-- the way that the reference implementation behaves.) +maxexponent: 999 +minexponent: -999 +precision: 3 +extr1200 scaleb 1234 1 -> 1.23E+4 Inexact Rounded +extr1201 scaleb 5678 0 -> 5.68E+3 Inexact Rounded +extr1202 scaleb -9105 -1 -> -910 Inexact Rounded + +-- Invalid operation from 0 * infinity in fma +-- takes precedence over a third-argument sNaN +extr1300 fma 0 Inf sNaN123 -> NaN Invalid_operation +extr1301 fma Inf 0 sNaN456 -> NaN Invalid_operation +extr1302 fma 0E123 -Inf sNaN789 -> NaN Invalid_operation +extr1302 fma -Inf 0E-456 sNaN148 -> NaN Invalid_operation + +-- Tests for the is_* boolean operations +precision: 9 +maxExponent: 999 +minExponent: -999 + +bool0000 iscanonical 0E-2000 -> 1 +bool0001 iscanonical -0E-2000 -> 1 +bool0002 iscanonical 0E-1008 -> 1 +bool0003 iscanonical -0E-1008 -> 1 +bool0004 iscanonical 0E-1007 -> 1 +bool0005 iscanonical -0E-1007 -> 1 +bool0006 iscanonical 0E-1006 -> 1 +bool0007 iscanonical -0E-1006 -> 1 +bool0008 iscanonical 0E-1000 -> 1 +bool0009 iscanonical -0E-1000 -> 1 +bool0010 iscanonical 0E-999 -> 1 +bool0011 iscanonical -0E-999 -> 1 +bool0012 iscanonical 0E-998 -> 1 +bool0013 iscanonical -0E-998 -> 1 +bool0014 iscanonical 0E-100 -> 1 +bool0015 iscanonical -0E-100 -> 1 +bool0016 iscanonical 0.000000 -> 1 +bool0017 iscanonical -0.000000 -> 1 +bool0018 iscanonical 0.000 -> 1 +bool0019 iscanonical -0.000 -> 1 +bool0020 iscanonical 0.00 -> 1 +bool0021 iscanonical -0.00 -> 1 +bool0022 iscanonical 0.0 -> 1 +bool0023 iscanonical -0.0 -> 1 +bool0024 iscanonical 0 -> 1 +bool0025 iscanonical -0 -> 1 +bool0026 iscanonical 0E+1 -> 1 +bool0027 iscanonical -0E+1 -> 1 +bool0028 iscanonical 0E+2 -> 1 +bool0029 iscanonical -0E+2 -> 1 +bool0030 iscanonical 0E+3 -> 1 +bool0031 iscanonical -0E+3 -> 1 +bool0032 iscanonical 0E+6 -> 1 +bool0033 iscanonical -0E+6 -> 1 +bool0034 iscanonical 0E+100 -> 1 +bool0035 iscanonical -0E+100 -> 1 +bool0036 iscanonical 0E+990 -> 1 +bool0037 iscanonical -0E+990 -> 1 +bool0038 iscanonical 0E+991 -> 1 +bool0039 iscanonical -0E+991 -> 1 +bool0040 iscanonical 0E+992 -> 1 +bool0041 iscanonical -0E+992 -> 1 +bool0042 iscanonical 0E+998 -> 1 +bool0043 iscanonical -0E+998 -> 1 +bool0044 iscanonical 0E+999 -> 1 +bool0045 iscanonical -0E+999 -> 1 +bool0046 iscanonical 0E+1000 -> 1 +bool0047 iscanonical -0E+1000 -> 1 +bool0048 iscanonical 0E+2000 -> 1 +bool0049 iscanonical -0E+2000 -> 1 +bool0050 iscanonical 1E-2000 -> 1 +bool0051 iscanonical -1E-2000 -> 1 +bool0052 iscanonical 1E-1008 -> 1 +bool0053 iscanonical -1E-1008 -> 1 +bool0054 iscanonical 1E-1007 -> 1 +bool0055 iscanonical -1E-1007 -> 1 +bool0056 iscanonical 1E-1006 -> 1 +bool0057 iscanonical -1E-1006 -> 1 +bool0058 iscanonical 1E-1000 -> 1 +bool0059 iscanonical -1E-1000 -> 1 +bool0060 iscanonical 1E-999 -> 1 +bool0061 iscanonical -1E-999 -> 1 +bool0062 iscanonical 1E-998 -> 1 +bool0063 iscanonical -1E-998 -> 1 +bool0064 iscanonical 1E-100 -> 1 +bool0065 iscanonical -1E-100 -> 1 +bool0066 iscanonical 0.000001 -> 1 +bool0067 iscanonical -0.000001 -> 1 +bool0068 iscanonical 0.001 -> 1 +bool0069 iscanonical -0.001 -> 1 +bool0070 iscanonical 0.01 -> 1 +bool0071 iscanonical -0.01 -> 1 +bool0072 iscanonical 0.1 -> 1 +bool0073 iscanonical -0.1 -> 1 +bool0074 iscanonical 1 -> 1 +bool0075 iscanonical -1 -> 1 +bool0076 iscanonical 1E+1 -> 1 +bool0077 iscanonical -1E+1 -> 1 +bool0078 iscanonical 1E+2 -> 1 +bool0079 iscanonical -1E+2 -> 1 +bool0080 iscanonical 1E+3 -> 1 +bool0081 iscanonical -1E+3 -> 1 +bool0082 iscanonical 1E+6 -> 1 +bool0083 iscanonical -1E+6 -> 1 +bool0084 iscanonical 1E+100 -> 1 +bool0085 iscanonical -1E+100 -> 1 +bool0086 iscanonical 1E+990 -> 1 +bool0087 iscanonical -1E+990 -> 1 +bool0088 iscanonical 1E+991 -> 1 +bool0089 iscanonical -1E+991 -> 1 +bool0090 iscanonical 1E+992 -> 1 +bool0091 iscanonical -1E+992 -> 1 +bool0092 iscanonical 1E+998 -> 1 +bool0093 iscanonical -1E+998 -> 1 +bool0094 iscanonical 1E+999 -> 1 +bool0095 iscanonical -1E+999 -> 1 +bool0096 iscanonical 1E+1000 -> 1 +bool0097 iscanonical -1E+1000 -> 1 +bool0098 iscanonical 1E+2000 -> 1 +bool0099 iscanonical -1E+2000 -> 1 +bool0100 iscanonical 9E-2000 -> 1 +bool0101 iscanonical -9E-2000 -> 1 +bool0102 iscanonical 9E-1008 -> 1 +bool0103 iscanonical -9E-1008 -> 1 +bool0104 iscanonical 9E-1007 -> 1 +bool0105 iscanonical -9E-1007 -> 1 +bool0106 iscanonical 9E-1006 -> 1 +bool0107 iscanonical -9E-1006 -> 1 +bool0108 iscanonical 9E-1000 -> 1 +bool0109 iscanonical -9E-1000 -> 1 +bool0110 iscanonical 9E-999 -> 1 +bool0111 iscanonical -9E-999 -> 1 +bool0112 iscanonical 9E-998 -> 1 +bool0113 iscanonical -9E-998 -> 1 +bool0114 iscanonical 9E-100 -> 1 +bool0115 iscanonical -9E-100 -> 1 +bool0116 iscanonical 0.000009 -> 1 +bool0117 iscanonical -0.000009 -> 1 +bool0118 iscanonical 0.009 -> 1 +bool0119 iscanonical -0.009 -> 1 +bool0120 iscanonical 0.09 -> 1 +bool0121 iscanonical -0.09 -> 1 +bool0122 iscanonical 0.9 -> 1 +bool0123 iscanonical -0.9 -> 1 +bool0124 iscanonical 9 -> 1 +bool0125 iscanonical -9 -> 1 +bool0126 iscanonical 9E+1 -> 1 +bool0127 iscanonical -9E+1 -> 1 +bool0128 iscanonical 9E+2 -> 1 +bool0129 iscanonical -9E+2 -> 1 +bool0130 iscanonical 9E+3 -> 1 +bool0131 iscanonical -9E+3 -> 1 +bool0132 iscanonical 9E+6 -> 1 +bool0133 iscanonical -9E+6 -> 1 +bool0134 iscanonical 9E+100 -> 1 +bool0135 iscanonical -9E+100 -> 1 +bool0136 iscanonical 9E+990 -> 1 +bool0137 iscanonical -9E+990 -> 1 +bool0138 iscanonical 9E+991 -> 1 +bool0139 iscanonical -9E+991 -> 1 +bool0140 iscanonical 9E+992 -> 1 +bool0141 iscanonical -9E+992 -> 1 +bool0142 iscanonical 9E+998 -> 1 +bool0143 iscanonical -9E+998 -> 1 +bool0144 iscanonical 9E+999 -> 1 +bool0145 iscanonical -9E+999 -> 1 +bool0146 iscanonical 9E+1000 -> 1 +bool0147 iscanonical -9E+1000 -> 1 +bool0148 iscanonical 9E+2000 -> 1 +bool0149 iscanonical -9E+2000 -> 1 +bool0150 iscanonical 9.99999999E-2000 -> 1 +bool0151 iscanonical -9.99999999E-2000 -> 1 +bool0152 iscanonical 9.99999999E-1008 -> 1 +bool0153 iscanonical -9.99999999E-1008 -> 1 +bool0154 iscanonical 9.99999999E-1007 -> 1 +bool0155 iscanonical -9.99999999E-1007 -> 1 +bool0156 iscanonical 9.99999999E-1006 -> 1 +bool0157 iscanonical -9.99999999E-1006 -> 1 +bool0158 iscanonical 9.99999999E-1000 -> 1 +bool0159 iscanonical -9.99999999E-1000 -> 1 +bool0160 iscanonical 9.99999999E-999 -> 1 +bool0161 iscanonical -9.99999999E-999 -> 1 +bool0162 iscanonical 9.99999999E-998 -> 1 +bool0163 iscanonical -9.99999999E-998 -> 1 +bool0164 iscanonical 9.99999999E-100 -> 1 +bool0165 iscanonical -9.99999999E-100 -> 1 +bool0166 iscanonical 0.00000999999999 -> 1 +bool0167 iscanonical -0.00000999999999 -> 1 +bool0168 iscanonical 0.00999999999 -> 1 +bool0169 iscanonical -0.00999999999 -> 1 +bool0170 iscanonical 0.0999999999 -> 1 +bool0171 iscanonical -0.0999999999 -> 1 +bool0172 iscanonical 0.999999999 -> 1 +bool0173 iscanonical -0.999999999 -> 1 +bool0174 iscanonical 9.99999999 -> 1 +bool0175 iscanonical -9.99999999 -> 1 +bool0176 iscanonical 99.9999999 -> 1 +bool0177 iscanonical -99.9999999 -> 1 +bool0178 iscanonical 999.999999 -> 1 +bool0179 iscanonical -999.999999 -> 1 +bool0180 iscanonical 9999.99999 -> 1 +bool0181 iscanonical -9999.99999 -> 1 +bool0182 iscanonical 9999999.99 -> 1 +bool0183 iscanonical -9999999.99 -> 1 +bool0184 iscanonical 9.99999999E+100 -> 1 +bool0185 iscanonical -9.99999999E+100 -> 1 +bool0186 iscanonical 9.99999999E+990 -> 1 +bool0187 iscanonical -9.99999999E+990 -> 1 +bool0188 iscanonical 9.99999999E+991 -> 1 +bool0189 iscanonical -9.99999999E+991 -> 1 +bool0190 iscanonical 9.99999999E+992 -> 1 +bool0191 iscanonical -9.99999999E+992 -> 1 +bool0192 iscanonical 9.99999999E+998 -> 1 +bool0193 iscanonical -9.99999999E+998 -> 1 +bool0194 iscanonical 9.99999999E+999 -> 1 +bool0195 iscanonical -9.99999999E+999 -> 1 +bool0196 iscanonical 9.99999999E+1000 -> 1 +bool0197 iscanonical -9.99999999E+1000 -> 1 +bool0198 iscanonical 9.99999999E+2000 -> 1 +bool0199 iscanonical -9.99999999E+2000 -> 1 +bool0200 iscanonical Infinity -> 1 +bool0201 iscanonical -Infinity -> 1 +bool0202 iscanonical NaN -> 1 +bool0203 iscanonical -NaN -> 1 +bool0204 iscanonical NaN123 -> 1 +bool0205 iscanonical -NaN123 -> 1 +bool0206 iscanonical sNaN -> 1 +bool0207 iscanonical -sNaN -> 1 +bool0208 iscanonical sNaN123 -> 1 +bool0209 iscanonical -sNaN123 -> 1 +bool0210 isfinite 0E-2000 -> 1 +bool0211 isfinite -0E-2000 -> 1 +bool0212 isfinite 0E-1008 -> 1 +bool0213 isfinite -0E-1008 -> 1 +bool0214 isfinite 0E-1007 -> 1 +bool0215 isfinite -0E-1007 -> 1 +bool0216 isfinite 0E-1006 -> 1 +bool0217 isfinite -0E-1006 -> 1 +bool0218 isfinite 0E-1000 -> 1 +bool0219 isfinite -0E-1000 -> 1 +bool0220 isfinite 0E-999 -> 1 +bool0221 isfinite -0E-999 -> 1 +bool0222 isfinite 0E-998 -> 1 +bool0223 isfinite -0E-998 -> 1 +bool0224 isfinite 0E-100 -> 1 +bool0225 isfinite -0E-100 -> 1 +bool0226 isfinite 0.000000 -> 1 +bool0227 isfinite -0.000000 -> 1 +bool0228 isfinite 0.000 -> 1 +bool0229 isfinite -0.000 -> 1 +bool0230 isfinite 0.00 -> 1 +bool0231 isfinite -0.00 -> 1 +bool0232 isfinite 0.0 -> 1 +bool0233 isfinite -0.0 -> 1 +bool0234 isfinite 0 -> 1 +bool0235 isfinite -0 -> 1 +bool0236 isfinite 0E+1 -> 1 +bool0237 isfinite -0E+1 -> 1 +bool0238 isfinite 0E+2 -> 1 +bool0239 isfinite -0E+2 -> 1 +bool0240 isfinite 0E+3 -> 1 +bool0241 isfinite -0E+3 -> 1 +bool0242 isfinite 0E+6 -> 1 +bool0243 isfinite -0E+6 -> 1 +bool0244 isfinite 0E+100 -> 1 +bool0245 isfinite -0E+100 -> 1 +bool0246 isfinite 0E+990 -> 1 +bool0247 isfinite -0E+990 -> 1 +bool0248 isfinite 0E+991 -> 1 +bool0249 isfinite -0E+991 -> 1 +bool0250 isfinite 0E+992 -> 1 +bool0251 isfinite -0E+992 -> 1 +bool0252 isfinite 0E+998 -> 1 +bool0253 isfinite -0E+998 -> 1 +bool0254 isfinite 0E+999 -> 1 +bool0255 isfinite -0E+999 -> 1 +bool0256 isfinite 0E+1000 -> 1 +bool0257 isfinite -0E+1000 -> 1 +bool0258 isfinite 0E+2000 -> 1 +bool0259 isfinite -0E+2000 -> 1 +bool0260 isfinite 1E-2000 -> 1 +bool0261 isfinite -1E-2000 -> 1 +bool0262 isfinite 1E-1008 -> 1 +bool0263 isfinite -1E-1008 -> 1 +bool0264 isfinite 1E-1007 -> 1 +bool0265 isfinite -1E-1007 -> 1 +bool0266 isfinite 1E-1006 -> 1 +bool0267 isfinite -1E-1006 -> 1 +bool0268 isfinite 1E-1000 -> 1 +bool0269 isfinite -1E-1000 -> 1 +bool0270 isfinite 1E-999 -> 1 +bool0271 isfinite -1E-999 -> 1 +bool0272 isfinite 1E-998 -> 1 +bool0273 isfinite -1E-998 -> 1 +bool0274 isfinite 1E-100 -> 1 +bool0275 isfinite -1E-100 -> 1 +bool0276 isfinite 0.000001 -> 1 +bool0277 isfinite -0.000001 -> 1 +bool0278 isfinite 0.001 -> 1 +bool0279 isfinite -0.001 -> 1 +bool0280 isfinite 0.01 -> 1 +bool0281 isfinite -0.01 -> 1 +bool0282 isfinite 0.1 -> 1 +bool0283 isfinite -0.1 -> 1 +bool0284 isfinite 1 -> 1 +bool0285 isfinite -1 -> 1 +bool0286 isfinite 1E+1 -> 1 +bool0287 isfinite -1E+1 -> 1 +bool0288 isfinite 1E+2 -> 1 +bool0289 isfinite -1E+2 -> 1 +bool0290 isfinite 1E+3 -> 1 +bool0291 isfinite -1E+3 -> 1 +bool0292 isfinite 1E+6 -> 1 +bool0293 isfinite -1E+6 -> 1 +bool0294 isfinite 1E+100 -> 1 +bool0295 isfinite -1E+100 -> 1 +bool0296 isfinite 1E+990 -> 1 +bool0297 isfinite -1E+990 -> 1 +bool0298 isfinite 1E+991 -> 1 +bool0299 isfinite -1E+991 -> 1 +bool0300 isfinite 1E+992 -> 1 +bool0301 isfinite -1E+992 -> 1 +bool0302 isfinite 1E+998 -> 1 +bool0303 isfinite -1E+998 -> 1 +bool0304 isfinite 1E+999 -> 1 +bool0305 isfinite -1E+999 -> 1 +bool0306 isfinite 1E+1000 -> 1 +bool0307 isfinite -1E+1000 -> 1 +bool0308 isfinite 1E+2000 -> 1 +bool0309 isfinite -1E+2000 -> 1 +bool0310 isfinite 9E-2000 -> 1 +bool0311 isfinite -9E-2000 -> 1 +bool0312 isfinite 9E-1008 -> 1 +bool0313 isfinite -9E-1008 -> 1 +bool0314 isfinite 9E-1007 -> 1 +bool0315 isfinite -9E-1007 -> 1 +bool0316 isfinite 9E-1006 -> 1 +bool0317 isfinite -9E-1006 -> 1 +bool0318 isfinite 9E-1000 -> 1 +bool0319 isfinite -9E-1000 -> 1 +bool0320 isfinite 9E-999 -> 1 +bool0321 isfinite -9E-999 -> 1 +bool0322 isfinite 9E-998 -> 1 +bool0323 isfinite -9E-998 -> 1 +bool0324 isfinite 9E-100 -> 1 +bool0325 isfinite -9E-100 -> 1 +bool0326 isfinite 0.000009 -> 1 +bool0327 isfinite -0.000009 -> 1 +bool0328 isfinite 0.009 -> 1 +bool0329 isfinite -0.009 -> 1 +bool0330 isfinite 0.09 -> 1 +bool0331 isfinite -0.09 -> 1 +bool0332 isfinite 0.9 -> 1 +bool0333 isfinite -0.9 -> 1 +bool0334 isfinite 9 -> 1 +bool0335 isfinite -9 -> 1 +bool0336 isfinite 9E+1 -> 1 +bool0337 isfinite -9E+1 -> 1 +bool0338 isfinite 9E+2 -> 1 +bool0339 isfinite -9E+2 -> 1 +bool0340 isfinite 9E+3 -> 1 +bool0341 isfinite -9E+3 -> 1 +bool0342 isfinite 9E+6 -> 1 +bool0343 isfinite -9E+6 -> 1 +bool0344 isfinite 9E+100 -> 1 +bool0345 isfinite -9E+100 -> 1 +bool0346 isfinite 9E+990 -> 1 +bool0347 isfinite -9E+990 -> 1 +bool0348 isfinite 9E+991 -> 1 +bool0349 isfinite -9E+991 -> 1 +bool0350 isfinite 9E+992 -> 1 +bool0351 isfinite -9E+992 -> 1 +bool0352 isfinite 9E+998 -> 1 +bool0353 isfinite -9E+998 -> 1 +bool0354 isfinite 9E+999 -> 1 +bool0355 isfinite -9E+999 -> 1 +bool0356 isfinite 9E+1000 -> 1 +bool0357 isfinite -9E+1000 -> 1 +bool0358 isfinite 9E+2000 -> 1 +bool0359 isfinite -9E+2000 -> 1 +bool0360 isfinite 9.99999999E-2000 -> 1 +bool0361 isfinite -9.99999999E-2000 -> 1 +bool0362 isfinite 9.99999999E-1008 -> 1 +bool0363 isfinite -9.99999999E-1008 -> 1 +bool0364 isfinite 9.99999999E-1007 -> 1 +bool0365 isfinite -9.99999999E-1007 -> 1 +bool0366 isfinite 9.99999999E-1006 -> 1 +bool0367 isfinite -9.99999999E-1006 -> 1 +bool0368 isfinite 9.99999999E-1000 -> 1 +bool0369 isfinite -9.99999999E-1000 -> 1 +bool0370 isfinite 9.99999999E-999 -> 1 +bool0371 isfinite -9.99999999E-999 -> 1 +bool0372 isfinite 9.99999999E-998 -> 1 +bool0373 isfinite -9.99999999E-998 -> 1 +bool0374 isfinite 9.99999999E-100 -> 1 +bool0375 isfinite -9.99999999E-100 -> 1 +bool0376 isfinite 0.00000999999999 -> 1 +bool0377 isfinite -0.00000999999999 -> 1 +bool0378 isfinite 0.00999999999 -> 1 +bool0379 isfinite -0.00999999999 -> 1 +bool0380 isfinite 0.0999999999 -> 1 +bool0381 isfinite -0.0999999999 -> 1 +bool0382 isfinite 0.999999999 -> 1 +bool0383 isfinite -0.999999999 -> 1 +bool0384 isfinite 9.99999999 -> 1 +bool0385 isfinite -9.99999999 -> 1 +bool0386 isfinite 99.9999999 -> 1 +bool0387 isfinite -99.9999999 -> 1 +bool0388 isfinite 999.999999 -> 1 +bool0389 isfinite -999.999999 -> 1 +bool0390 isfinite 9999.99999 -> 1 +bool0391 isfinite -9999.99999 -> 1 +bool0392 isfinite 9999999.99 -> 1 +bool0393 isfinite -9999999.99 -> 1 +bool0394 isfinite 9.99999999E+100 -> 1 +bool0395 isfinite -9.99999999E+100 -> 1 +bool0396 isfinite 9.99999999E+990 -> 1 +bool0397 isfinite -9.99999999E+990 -> 1 +bool0398 isfinite 9.99999999E+991 -> 1 +bool0399 isfinite -9.99999999E+991 -> 1 +bool0400 isfinite 9.99999999E+992 -> 1 +bool0401 isfinite -9.99999999E+992 -> 1 +bool0402 isfinite 9.99999999E+998 -> 1 +bool0403 isfinite -9.99999999E+998 -> 1 +bool0404 isfinite 9.99999999E+999 -> 1 +bool0405 isfinite -9.99999999E+999 -> 1 +bool0406 isfinite 9.99999999E+1000 -> 1 +bool0407 isfinite -9.99999999E+1000 -> 1 +bool0408 isfinite 9.99999999E+2000 -> 1 +bool0409 isfinite -9.99999999E+2000 -> 1 +bool0410 isfinite Infinity -> 0 +bool0411 isfinite -Infinity -> 0 +bool0412 isfinite NaN -> 0 +bool0413 isfinite -NaN -> 0 +bool0414 isfinite NaN123 -> 0 +bool0415 isfinite -NaN123 -> 0 +bool0416 isfinite sNaN -> 0 +bool0417 isfinite -sNaN -> 0 +bool0418 isfinite sNaN123 -> 0 +bool0419 isfinite -sNaN123 -> 0 +bool0420 isinfinite 0E-2000 -> 0 +bool0421 isinfinite -0E-2000 -> 0 +bool0422 isinfinite 0E-1008 -> 0 +bool0423 isinfinite -0E-1008 -> 0 +bool0424 isinfinite 0E-1007 -> 0 +bool0425 isinfinite -0E-1007 -> 0 +bool0426 isinfinite 0E-1006 -> 0 +bool0427 isinfinite -0E-1006 -> 0 +bool0428 isinfinite 0E-1000 -> 0 +bool0429 isinfinite -0E-1000 -> 0 +bool0430 isinfinite 0E-999 -> 0 +bool0431 isinfinite -0E-999 -> 0 +bool0432 isinfinite 0E-998 -> 0 +bool0433 isinfinite -0E-998 -> 0 +bool0434 isinfinite 0E-100 -> 0 +bool0435 isinfinite -0E-100 -> 0 +bool0436 isinfinite 0.000000 -> 0 +bool0437 isinfinite -0.000000 -> 0 +bool0438 isinfinite 0.000 -> 0 +bool0439 isinfinite -0.000 -> 0 +bool0440 isinfinite 0.00 -> 0 +bool0441 isinfinite -0.00 -> 0 +bool0442 isinfinite 0.0 -> 0 +bool0443 isinfinite -0.0 -> 0 +bool0444 isinfinite 0 -> 0 +bool0445 isinfinite -0 -> 0 +bool0446 isinfinite 0E+1 -> 0 +bool0447 isinfinite -0E+1 -> 0 +bool0448 isinfinite 0E+2 -> 0 +bool0449 isinfinite -0E+2 -> 0 +bool0450 isinfinite 0E+3 -> 0 +bool0451 isinfinite -0E+3 -> 0 +bool0452 isinfinite 0E+6 -> 0 +bool0453 isinfinite -0E+6 -> 0 +bool0454 isinfinite 0E+100 -> 0 +bool0455 isinfinite -0E+100 -> 0 +bool0456 isinfinite 0E+990 -> 0 +bool0457 isinfinite -0E+990 -> 0 +bool0458 isinfinite 0E+991 -> 0 +bool0459 isinfinite -0E+991 -> 0 +bool0460 isinfinite 0E+992 -> 0 +bool0461 isinfinite -0E+992 -> 0 +bool0462 isinfinite 0E+998 -> 0 +bool0463 isinfinite -0E+998 -> 0 +bool0464 isinfinite 0E+999 -> 0 +bool0465 isinfinite -0E+999 -> 0 +bool0466 isinfinite 0E+1000 -> 0 +bool0467 isinfinite -0E+1000 -> 0 +bool0468 isinfinite 0E+2000 -> 0 +bool0469 isinfinite -0E+2000 -> 0 +bool0470 isinfinite 1E-2000 -> 0 +bool0471 isinfinite -1E-2000 -> 0 +bool0472 isinfinite 1E-1008 -> 0 +bool0473 isinfinite -1E-1008 -> 0 +bool0474 isinfinite 1E-1007 -> 0 +bool0475 isinfinite -1E-1007 -> 0 +bool0476 isinfinite 1E-1006 -> 0 +bool0477 isinfinite -1E-1006 -> 0 +bool0478 isinfinite 1E-1000 -> 0 +bool0479 isinfinite -1E-1000 -> 0 +bool0480 isinfinite 1E-999 -> 0 +bool0481 isinfinite -1E-999 -> 0 +bool0482 isinfinite 1E-998 -> 0 +bool0483 isinfinite -1E-998 -> 0 +bool0484 isinfinite 1E-100 -> 0 +bool0485 isinfinite -1E-100 -> 0 +bool0486 isinfinite 0.000001 -> 0 +bool0487 isinfinite -0.000001 -> 0 +bool0488 isinfinite 0.001 -> 0 +bool0489 isinfinite -0.001 -> 0 +bool0490 isinfinite 0.01 -> 0 +bool0491 isinfinite -0.01 -> 0 +bool0492 isinfinite 0.1 -> 0 +bool0493 isinfinite -0.1 -> 0 +bool0494 isinfinite 1 -> 0 +bool0495 isinfinite -1 -> 0 +bool0496 isinfinite 1E+1 -> 0 +bool0497 isinfinite -1E+1 -> 0 +bool0498 isinfinite 1E+2 -> 0 +bool0499 isinfinite -1E+2 -> 0 +bool0500 isinfinite 1E+3 -> 0 +bool0501 isinfinite -1E+3 -> 0 +bool0502 isinfinite 1E+6 -> 0 +bool0503 isinfinite -1E+6 -> 0 +bool0504 isinfinite 1E+100 -> 0 +bool0505 isinfinite -1E+100 -> 0 +bool0506 isinfinite 1E+990 -> 0 +bool0507 isinfinite -1E+990 -> 0 +bool0508 isinfinite 1E+991 -> 0 +bool0509 isinfinite -1E+991 -> 0 +bool0510 isinfinite 1E+992 -> 0 +bool0511 isinfinite -1E+992 -> 0 +bool0512 isinfinite 1E+998 -> 0 +bool0513 isinfinite -1E+998 -> 0 +bool0514 isinfinite 1E+999 -> 0 +bool0515 isinfinite -1E+999 -> 0 +bool0516 isinfinite 1E+1000 -> 0 +bool0517 isinfinite -1E+1000 -> 0 +bool0518 isinfinite 1E+2000 -> 0 +bool0519 isinfinite -1E+2000 -> 0 +bool0520 isinfinite 9E-2000 -> 0 +bool0521 isinfinite -9E-2000 -> 0 +bool0522 isinfinite 9E-1008 -> 0 +bool0523 isinfinite -9E-1008 -> 0 +bool0524 isinfinite 9E-1007 -> 0 +bool0525 isinfinite -9E-1007 -> 0 +bool0526 isinfinite 9E-1006 -> 0 +bool0527 isinfinite -9E-1006 -> 0 +bool0528 isinfinite 9E-1000 -> 0 +bool0529 isinfinite -9E-1000 -> 0 +bool0530 isinfinite 9E-999 -> 0 +bool0531 isinfinite -9E-999 -> 0 +bool0532 isinfinite 9E-998 -> 0 +bool0533 isinfinite -9E-998 -> 0 +bool0534 isinfinite 9E-100 -> 0 +bool0535 isinfinite -9E-100 -> 0 +bool0536 isinfinite 0.000009 -> 0 +bool0537 isinfinite -0.000009 -> 0 +bool0538 isinfinite 0.009 -> 0 +bool0539 isinfinite -0.009 -> 0 +bool0540 isinfinite 0.09 -> 0 +bool0541 isinfinite -0.09 -> 0 +bool0542 isinfinite 0.9 -> 0 +bool0543 isinfinite -0.9 -> 0 +bool0544 isinfinite 9 -> 0 +bool0545 isinfinite -9 -> 0 +bool0546 isinfinite 9E+1 -> 0 +bool0547 isinfinite -9E+1 -> 0 +bool0548 isinfinite 9E+2 -> 0 +bool0549 isinfinite -9E+2 -> 0 +bool0550 isinfinite 9E+3 -> 0 +bool0551 isinfinite -9E+3 -> 0 +bool0552 isinfinite 9E+6 -> 0 +bool0553 isinfinite -9E+6 -> 0 +bool0554 isinfinite 9E+100 -> 0 +bool0555 isinfinite -9E+100 -> 0 +bool0556 isinfinite 9E+990 -> 0 +bool0557 isinfinite -9E+990 -> 0 +bool0558 isinfinite 9E+991 -> 0 +bool0559 isinfinite -9E+991 -> 0 +bool0560 isinfinite 9E+992 -> 0 +bool0561 isinfinite -9E+992 -> 0 +bool0562 isinfinite 9E+998 -> 0 +bool0563 isinfinite -9E+998 -> 0 +bool0564 isinfinite 9E+999 -> 0 +bool0565 isinfinite -9E+999 -> 0 +bool0566 isinfinite 9E+1000 -> 0 +bool0567 isinfinite -9E+1000 -> 0 +bool0568 isinfinite 9E+2000 -> 0 +bool0569 isinfinite -9E+2000 -> 0 +bool0570 isinfinite 9.99999999E-2000 -> 0 +bool0571 isinfinite -9.99999999E-2000 -> 0 +bool0572 isinfinite 9.99999999E-1008 -> 0 +bool0573 isinfinite -9.99999999E-1008 -> 0 +bool0574 isinfinite 9.99999999E-1007 -> 0 +bool0575 isinfinite -9.99999999E-1007 -> 0 +bool0576 isinfinite 9.99999999E-1006 -> 0 +bool0577 isinfinite -9.99999999E-1006 -> 0 +bool0578 isinfinite 9.99999999E-1000 -> 0 +bool0579 isinfinite -9.99999999E-1000 -> 0 +bool0580 isinfinite 9.99999999E-999 -> 0 +bool0581 isinfinite -9.99999999E-999 -> 0 +bool0582 isinfinite 9.99999999E-998 -> 0 +bool0583 isinfinite -9.99999999E-998 -> 0 +bool0584 isinfinite 9.99999999E-100 -> 0 +bool0585 isinfinite -9.99999999E-100 -> 0 +bool0586 isinfinite 0.00000999999999 -> 0 +bool0587 isinfinite -0.00000999999999 -> 0 +bool0588 isinfinite 0.00999999999 -> 0 +bool0589 isinfinite -0.00999999999 -> 0 +bool0590 isinfinite 0.0999999999 -> 0 +bool0591 isinfinite -0.0999999999 -> 0 +bool0592 isinfinite 0.999999999 -> 0 +bool0593 isinfinite -0.999999999 -> 0 +bool0594 isinfinite 9.99999999 -> 0 +bool0595 isinfinite -9.99999999 -> 0 +bool0596 isinfinite 99.9999999 -> 0 +bool0597 isinfinite -99.9999999 -> 0 +bool0598 isinfinite 999.999999 -> 0 +bool0599 isinfinite -999.999999 -> 0 +bool0600 isinfinite 9999.99999 -> 0 +bool0601 isinfinite -9999.99999 -> 0 +bool0602 isinfinite 9999999.99 -> 0 +bool0603 isinfinite -9999999.99 -> 0 +bool0604 isinfinite 9.99999999E+100 -> 0 +bool0605 isinfinite -9.99999999E+100 -> 0 +bool0606 isinfinite 9.99999999E+990 -> 0 +bool0607 isinfinite -9.99999999E+990 -> 0 +bool0608 isinfinite 9.99999999E+991 -> 0 +bool0609 isinfinite -9.99999999E+991 -> 0 +bool0610 isinfinite 9.99999999E+992 -> 0 +bool0611 isinfinite -9.99999999E+992 -> 0 +bool0612 isinfinite 9.99999999E+998 -> 0 +bool0613 isinfinite -9.99999999E+998 -> 0 +bool0614 isinfinite 9.99999999E+999 -> 0 +bool0615 isinfinite -9.99999999E+999 -> 0 +bool0616 isinfinite 9.99999999E+1000 -> 0 +bool0617 isinfinite -9.99999999E+1000 -> 0 +bool0618 isinfinite 9.99999999E+2000 -> 0 +bool0619 isinfinite -9.99999999E+2000 -> 0 +bool0620 isinfinite Infinity -> 1 +bool0621 isinfinite -Infinity -> 1 +bool0622 isinfinite NaN -> 0 +bool0623 isinfinite -NaN -> 0 +bool0624 isinfinite NaN123 -> 0 +bool0625 isinfinite -NaN123 -> 0 +bool0626 isinfinite sNaN -> 0 +bool0627 isinfinite -sNaN -> 0 +bool0628 isinfinite sNaN123 -> 0 +bool0629 isinfinite -sNaN123 -> 0 +bool0630 isnan 0E-2000 -> 0 +bool0631 isnan -0E-2000 -> 0 +bool0632 isnan 0E-1008 -> 0 +bool0633 isnan -0E-1008 -> 0 +bool0634 isnan 0E-1007 -> 0 +bool0635 isnan -0E-1007 -> 0 +bool0636 isnan 0E-1006 -> 0 +bool0637 isnan -0E-1006 -> 0 +bool0638 isnan 0E-1000 -> 0 +bool0639 isnan -0E-1000 -> 0 +bool0640 isnan 0E-999 -> 0 +bool0641 isnan -0E-999 -> 0 +bool0642 isnan 0E-998 -> 0 +bool0643 isnan -0E-998 -> 0 +bool0644 isnan 0E-100 -> 0 +bool0645 isnan -0E-100 -> 0 +bool0646 isnan 0.000000 -> 0 +bool0647 isnan -0.000000 -> 0 +bool0648 isnan 0.000 -> 0 +bool0649 isnan -0.000 -> 0 +bool0650 isnan 0.00 -> 0 +bool0651 isnan -0.00 -> 0 +bool0652 isnan 0.0 -> 0 +bool0653 isnan -0.0 -> 0 +bool0654 isnan 0 -> 0 +bool0655 isnan -0 -> 0 +bool0656 isnan 0E+1 -> 0 +bool0657 isnan -0E+1 -> 0 +bool0658 isnan 0E+2 -> 0 +bool0659 isnan -0E+2 -> 0 +bool0660 isnan 0E+3 -> 0 +bool0661 isnan -0E+3 -> 0 +bool0662 isnan 0E+6 -> 0 +bool0663 isnan -0E+6 -> 0 +bool0664 isnan 0E+100 -> 0 +bool0665 isnan -0E+100 -> 0 +bool0666 isnan 0E+990 -> 0 +bool0667 isnan -0E+990 -> 0 +bool0668 isnan 0E+991 -> 0 +bool0669 isnan -0E+991 -> 0 +bool0670 isnan 0E+992 -> 0 +bool0671 isnan -0E+992 -> 0 +bool0672 isnan 0E+998 -> 0 +bool0673 isnan -0E+998 -> 0 +bool0674 isnan 0E+999 -> 0 +bool0675 isnan -0E+999 -> 0 +bool0676 isnan 0E+1000 -> 0 +bool0677 isnan -0E+1000 -> 0 +bool0678 isnan 0E+2000 -> 0 +bool0679 isnan -0E+2000 -> 0 +bool0680 isnan 1E-2000 -> 0 +bool0681 isnan -1E-2000 -> 0 +bool0682 isnan 1E-1008 -> 0 +bool0683 isnan -1E-1008 -> 0 +bool0684 isnan 1E-1007 -> 0 +bool0685 isnan -1E-1007 -> 0 +bool0686 isnan 1E-1006 -> 0 +bool0687 isnan -1E-1006 -> 0 +bool0688 isnan 1E-1000 -> 0 +bool0689 isnan -1E-1000 -> 0 +bool0690 isnan 1E-999 -> 0 +bool0691 isnan -1E-999 -> 0 +bool0692 isnan 1E-998 -> 0 +bool0693 isnan -1E-998 -> 0 +bool0694 isnan 1E-100 -> 0 +bool0695 isnan -1E-100 -> 0 +bool0696 isnan 0.000001 -> 0 +bool0697 isnan -0.000001 -> 0 +bool0698 isnan 0.001 -> 0 +bool0699 isnan -0.001 -> 0 +bool0700 isnan 0.01 -> 0 +bool0701 isnan -0.01 -> 0 +bool0702 isnan 0.1 -> 0 +bool0703 isnan -0.1 -> 0 +bool0704 isnan 1 -> 0 +bool0705 isnan -1 -> 0 +bool0706 isnan 1E+1 -> 0 +bool0707 isnan -1E+1 -> 0 +bool0708 isnan 1E+2 -> 0 +bool0709 isnan -1E+2 -> 0 +bool0710 isnan 1E+3 -> 0 +bool0711 isnan -1E+3 -> 0 +bool0712 isnan 1E+6 -> 0 +bool0713 isnan -1E+6 -> 0 +bool0714 isnan 1E+100 -> 0 +bool0715 isnan -1E+100 -> 0 +bool0716 isnan 1E+990 -> 0 +bool0717 isnan -1E+990 -> 0 +bool0718 isnan 1E+991 -> 0 +bool0719 isnan -1E+991 -> 0 +bool0720 isnan 1E+992 -> 0 +bool0721 isnan -1E+992 -> 0 +bool0722 isnan 1E+998 -> 0 +bool0723 isnan -1E+998 -> 0 +bool0724 isnan 1E+999 -> 0 +bool0725 isnan -1E+999 -> 0 +bool0726 isnan 1E+1000 -> 0 +bool0727 isnan -1E+1000 -> 0 +bool0728 isnan 1E+2000 -> 0 +bool0729 isnan -1E+2000 -> 0 +bool0730 isnan 9E-2000 -> 0 +bool0731 isnan -9E-2000 -> 0 +bool0732 isnan 9E-1008 -> 0 +bool0733 isnan -9E-1008 -> 0 +bool0734 isnan 9E-1007 -> 0 +bool0735 isnan -9E-1007 -> 0 +bool0736 isnan 9E-1006 -> 0 +bool0737 isnan -9E-1006 -> 0 +bool0738 isnan 9E-1000 -> 0 +bool0739 isnan -9E-1000 -> 0 +bool0740 isnan 9E-999 -> 0 +bool0741 isnan -9E-999 -> 0 +bool0742 isnan 9E-998 -> 0 +bool0743 isnan -9E-998 -> 0 +bool0744 isnan 9E-100 -> 0 +bool0745 isnan -9E-100 -> 0 +bool0746 isnan 0.000009 -> 0 +bool0747 isnan -0.000009 -> 0 +bool0748 isnan 0.009 -> 0 +bool0749 isnan -0.009 -> 0 +bool0750 isnan 0.09 -> 0 +bool0751 isnan -0.09 -> 0 +bool0752 isnan 0.9 -> 0 +bool0753 isnan -0.9 -> 0 +bool0754 isnan 9 -> 0 +bool0755 isnan -9 -> 0 +bool0756 isnan 9E+1 -> 0 +bool0757 isnan -9E+1 -> 0 +bool0758 isnan 9E+2 -> 0 +bool0759 isnan -9E+2 -> 0 +bool0760 isnan 9E+3 -> 0 +bool0761 isnan -9E+3 -> 0 +bool0762 isnan 9E+6 -> 0 +bool0763 isnan -9E+6 -> 0 +bool0764 isnan 9E+100 -> 0 +bool0765 isnan -9E+100 -> 0 +bool0766 isnan 9E+990 -> 0 +bool0767 isnan -9E+990 -> 0 +bool0768 isnan 9E+991 -> 0 +bool0769 isnan -9E+991 -> 0 +bool0770 isnan 9E+992 -> 0 +bool0771 isnan -9E+992 -> 0 +bool0772 isnan 9E+998 -> 0 +bool0773 isnan -9E+998 -> 0 +bool0774 isnan 9E+999 -> 0 +bool0775 isnan -9E+999 -> 0 +bool0776 isnan 9E+1000 -> 0 +bool0777 isnan -9E+1000 -> 0 +bool0778 isnan 9E+2000 -> 0 +bool0779 isnan -9E+2000 -> 0 +bool0780 isnan 9.99999999E-2000 -> 0 +bool0781 isnan -9.99999999E-2000 -> 0 +bool0782 isnan 9.99999999E-1008 -> 0 +bool0783 isnan -9.99999999E-1008 -> 0 +bool0784 isnan 9.99999999E-1007 -> 0 +bool0785 isnan -9.99999999E-1007 -> 0 +bool0786 isnan 9.99999999E-1006 -> 0 +bool0787 isnan -9.99999999E-1006 -> 0 +bool0788 isnan 9.99999999E-1000 -> 0 +bool0789 isnan -9.99999999E-1000 -> 0 +bool0790 isnan 9.99999999E-999 -> 0 +bool0791 isnan -9.99999999E-999 -> 0 +bool0792 isnan 9.99999999E-998 -> 0 +bool0793 isnan -9.99999999E-998 -> 0 +bool0794 isnan 9.99999999E-100 -> 0 +bool0795 isnan -9.99999999E-100 -> 0 +bool0796 isnan 0.00000999999999 -> 0 +bool0797 isnan -0.00000999999999 -> 0 +bool0798 isnan 0.00999999999 -> 0 +bool0799 isnan -0.00999999999 -> 0 +bool0800 isnan 0.0999999999 -> 0 +bool0801 isnan -0.0999999999 -> 0 +bool0802 isnan 0.999999999 -> 0 +bool0803 isnan -0.999999999 -> 0 +bool0804 isnan 9.99999999 -> 0 +bool0805 isnan -9.99999999 -> 0 +bool0806 isnan 99.9999999 -> 0 +bool0807 isnan -99.9999999 -> 0 +bool0808 isnan 999.999999 -> 0 +bool0809 isnan -999.999999 -> 0 +bool0810 isnan 9999.99999 -> 0 +bool0811 isnan -9999.99999 -> 0 +bool0812 isnan 9999999.99 -> 0 +bool0813 isnan -9999999.99 -> 0 +bool0814 isnan 9.99999999E+100 -> 0 +bool0815 isnan -9.99999999E+100 -> 0 +bool0816 isnan 9.99999999E+990 -> 0 +bool0817 isnan -9.99999999E+990 -> 0 +bool0818 isnan 9.99999999E+991 -> 0 +bool0819 isnan -9.99999999E+991 -> 0 +bool0820 isnan 9.99999999E+992 -> 0 +bool0821 isnan -9.99999999E+992 -> 0 +bool0822 isnan 9.99999999E+998 -> 0 +bool0823 isnan -9.99999999E+998 -> 0 +bool0824 isnan 9.99999999E+999 -> 0 +bool0825 isnan -9.99999999E+999 -> 0 +bool0826 isnan 9.99999999E+1000 -> 0 +bool0827 isnan -9.99999999E+1000 -> 0 +bool0828 isnan 9.99999999E+2000 -> 0 +bool0829 isnan -9.99999999E+2000 -> 0 +bool0830 isnan Infinity -> 0 +bool0831 isnan -Infinity -> 0 +bool0832 isnan NaN -> 1 +bool0833 isnan -NaN -> 1 +bool0834 isnan NaN123 -> 1 +bool0835 isnan -NaN123 -> 1 +bool0836 isnan sNaN -> 1 +bool0837 isnan -sNaN -> 1 +bool0838 isnan sNaN123 -> 1 +bool0839 isnan -sNaN123 -> 1 +bool0840 isnormal 0E-2000 -> 0 +bool0841 isnormal -0E-2000 -> 0 +bool0842 isnormal 0E-1008 -> 0 +bool0843 isnormal -0E-1008 -> 0 +bool0844 isnormal 0E-1007 -> 0 +bool0845 isnormal -0E-1007 -> 0 +bool0846 isnormal 0E-1006 -> 0 +bool0847 isnormal -0E-1006 -> 0 +bool0848 isnormal 0E-1000 -> 0 +bool0849 isnormal -0E-1000 -> 0 +bool0850 isnormal 0E-999 -> 0 +bool0851 isnormal -0E-999 -> 0 +bool0852 isnormal 0E-998 -> 0 +bool0853 isnormal -0E-998 -> 0 +bool0854 isnormal 0E-100 -> 0 +bool0855 isnormal -0E-100 -> 0 +bool0856 isnormal 0.000000 -> 0 +bool0857 isnormal -0.000000 -> 0 +bool0858 isnormal 0.000 -> 0 +bool0859 isnormal -0.000 -> 0 +bool0860 isnormal 0.00 -> 0 +bool0861 isnormal -0.00 -> 0 +bool0862 isnormal 0.0 -> 0 +bool0863 isnormal -0.0 -> 0 +bool0864 isnormal 0 -> 0 +bool0865 isnormal -0 -> 0 +bool0866 isnormal 0E+1 -> 0 +bool0867 isnormal -0E+1 -> 0 +bool0868 isnormal 0E+2 -> 0 +bool0869 isnormal -0E+2 -> 0 +bool0870 isnormal 0E+3 -> 0 +bool0871 isnormal -0E+3 -> 0 +bool0872 isnormal 0E+6 -> 0 +bool0873 isnormal -0E+6 -> 0 +bool0874 isnormal 0E+100 -> 0 +bool0875 isnormal -0E+100 -> 0 +bool0876 isnormal 0E+990 -> 0 +bool0877 isnormal -0E+990 -> 0 +bool0878 isnormal 0E+991 -> 0 +bool0879 isnormal -0E+991 -> 0 +bool0880 isnormal 0E+992 -> 0 +bool0881 isnormal -0E+992 -> 0 +bool0882 isnormal 0E+998 -> 0 +bool0883 isnormal -0E+998 -> 0 +bool0884 isnormal 0E+999 -> 0 +bool0885 isnormal -0E+999 -> 0 +bool0886 isnormal 0E+1000 -> 0 +bool0887 isnormal -0E+1000 -> 0 +bool0888 isnormal 0E+2000 -> 0 +bool0889 isnormal -0E+2000 -> 0 +bool0890 isnormal 1E-2000 -> 0 +bool0891 isnormal -1E-2000 -> 0 +bool0892 isnormal 1E-1008 -> 0 +bool0893 isnormal -1E-1008 -> 0 +bool0894 isnormal 1E-1007 -> 0 +bool0895 isnormal -1E-1007 -> 0 +bool0896 isnormal 1E-1006 -> 0 +bool0897 isnormal -1E-1006 -> 0 +bool0898 isnormal 1E-1000 -> 0 +bool0899 isnormal -1E-1000 -> 0 +bool0900 isnormal 1E-999 -> 1 +bool0901 isnormal -1E-999 -> 1 +bool0902 isnormal 1E-998 -> 1 +bool0903 isnormal -1E-998 -> 1 +bool0904 isnormal 1E-100 -> 1 +bool0905 isnormal -1E-100 -> 1 +bool0906 isnormal 0.000001 -> 1 +bool0907 isnormal -0.000001 -> 1 +bool0908 isnormal 0.001 -> 1 +bool0909 isnormal -0.001 -> 1 +bool0910 isnormal 0.01 -> 1 +bool0911 isnormal -0.01 -> 1 +bool0912 isnormal 0.1 -> 1 +bool0913 isnormal -0.1 -> 1 +bool0914 isnormal 1 -> 1 +bool0915 isnormal -1 -> 1 +bool0916 isnormal 1E+1 -> 1 +bool0917 isnormal -1E+1 -> 1 +bool0918 isnormal 1E+2 -> 1 +bool0919 isnormal -1E+2 -> 1 +bool0920 isnormal 1E+3 -> 1 +bool0921 isnormal -1E+3 -> 1 +bool0922 isnormal 1E+6 -> 1 +bool0923 isnormal -1E+6 -> 1 +bool0924 isnormal 1E+100 -> 1 +bool0925 isnormal -1E+100 -> 1 +bool0926 isnormal 1E+990 -> 1 +bool0927 isnormal -1E+990 -> 1 +bool0928 isnormal 1E+991 -> 1 +bool0929 isnormal -1E+991 -> 1 +bool0930 isnormal 1E+992 -> 1 +bool0931 isnormal -1E+992 -> 1 +bool0932 isnormal 1E+998 -> 1 +bool0933 isnormal -1E+998 -> 1 +bool0934 isnormal 1E+999 -> 1 +bool0935 isnormal -1E+999 -> 1 +bool0936 isnormal 1E+1000 -> 0 +bool0937 isnormal -1E+1000 -> 0 +bool0938 isnormal 1E+2000 -> 0 +bool0939 isnormal -1E+2000 -> 0 +bool0940 isnormal 9E-2000 -> 0 +bool0941 isnormal -9E-2000 -> 0 +bool0942 isnormal 9E-1008 -> 0 +bool0943 isnormal -9E-1008 -> 0 +bool0944 isnormal 9E-1007 -> 0 +bool0945 isnormal -9E-1007 -> 0 +bool0946 isnormal 9E-1006 -> 0 +bool0947 isnormal -9E-1006 -> 0 +bool0948 isnormal 9E-1000 -> 0 +bool0949 isnormal -9E-1000 -> 0 +bool0950 isnormal 9E-999 -> 1 +bool0951 isnormal -9E-999 -> 1 +bool0952 isnormal 9E-998 -> 1 +bool0953 isnormal -9E-998 -> 1 +bool0954 isnormal 9E-100 -> 1 +bool0955 isnormal -9E-100 -> 1 +bool0956 isnormal 0.000009 -> 1 +bool0957 isnormal -0.000009 -> 1 +bool0958 isnormal 0.009 -> 1 +bool0959 isnormal -0.009 -> 1 +bool0960 isnormal 0.09 -> 1 +bool0961 isnormal -0.09 -> 1 +bool0962 isnormal 0.9 -> 1 +bool0963 isnormal -0.9 -> 1 +bool0964 isnormal 9 -> 1 +bool0965 isnormal -9 -> 1 +bool0966 isnormal 9E+1 -> 1 +bool0967 isnormal -9E+1 -> 1 +bool0968 isnormal 9E+2 -> 1 +bool0969 isnormal -9E+2 -> 1 +bool0970 isnormal 9E+3 -> 1 +bool0971 isnormal -9E+3 -> 1 +bool0972 isnormal 9E+6 -> 1 +bool0973 isnormal -9E+6 -> 1 +bool0974 isnormal 9E+100 -> 1 +bool0975 isnormal -9E+100 -> 1 +bool0976 isnormal 9E+990 -> 1 +bool0977 isnormal -9E+990 -> 1 +bool0978 isnormal 9E+991 -> 1 +bool0979 isnormal -9E+991 -> 1 +bool0980 isnormal 9E+992 -> 1 +bool0981 isnormal -9E+992 -> 1 +bool0982 isnormal 9E+998 -> 1 +bool0983 isnormal -9E+998 -> 1 +bool0984 isnormal 9E+999 -> 1 +bool0985 isnormal -9E+999 -> 1 +bool0986 isnormal 9E+1000 -> 0 +bool0987 isnormal -9E+1000 -> 0 +bool0988 isnormal 9E+2000 -> 0 +bool0989 isnormal -9E+2000 -> 0 +bool0990 isnormal 9.99999999E-2000 -> 0 +bool0991 isnormal -9.99999999E-2000 -> 0 +bool0992 isnormal 9.99999999E-1008 -> 0 +bool0993 isnormal -9.99999999E-1008 -> 0 +bool0994 isnormal 9.99999999E-1007 -> 0 +bool0995 isnormal -9.99999999E-1007 -> 0 +bool0996 isnormal 9.99999999E-1006 -> 0 +bool0997 isnormal -9.99999999E-1006 -> 0 +bool0998 isnormal 9.99999999E-1000 -> 0 +bool0999 isnormal -9.99999999E-1000 -> 0 +bool1000 isnormal 9.99999999E-999 -> 1 +bool1001 isnormal -9.99999999E-999 -> 1 +bool1002 isnormal 9.99999999E-998 -> 1 +bool1003 isnormal -9.99999999E-998 -> 1 +bool1004 isnormal 9.99999999E-100 -> 1 +bool1005 isnormal -9.99999999E-100 -> 1 +bool1006 isnormal 0.00000999999999 -> 1 +bool1007 isnormal -0.00000999999999 -> 1 +bool1008 isnormal 0.00999999999 -> 1 +bool1009 isnormal -0.00999999999 -> 1 +bool1010 isnormal 0.0999999999 -> 1 +bool1011 isnormal -0.0999999999 -> 1 +bool1012 isnormal 0.999999999 -> 1 +bool1013 isnormal -0.999999999 -> 1 +bool1014 isnormal 9.99999999 -> 1 +bool1015 isnormal -9.99999999 -> 1 +bool1016 isnormal 99.9999999 -> 1 +bool1017 isnormal -99.9999999 -> 1 +bool1018 isnormal 999.999999 -> 1 +bool1019 isnormal -999.999999 -> 1 +bool1020 isnormal 9999.99999 -> 1 +bool1021 isnormal -9999.99999 -> 1 +bool1022 isnormal 9999999.99 -> 1 +bool1023 isnormal -9999999.99 -> 1 +bool1024 isnormal 9.99999999E+100 -> 1 +bool1025 isnormal -9.99999999E+100 -> 1 +bool1026 isnormal 9.99999999E+990 -> 1 +bool1027 isnormal -9.99999999E+990 -> 1 +bool1028 isnormal 9.99999999E+991 -> 1 +bool1029 isnormal -9.99999999E+991 -> 1 +bool1030 isnormal 9.99999999E+992 -> 1 +bool1031 isnormal -9.99999999E+992 -> 1 +bool1032 isnormal 9.99999999E+998 -> 1 +bool1033 isnormal -9.99999999E+998 -> 1 +bool1034 isnormal 9.99999999E+999 -> 1 +bool1035 isnormal -9.99999999E+999 -> 1 +bool1036 isnormal 9.99999999E+1000 -> 0 +bool1037 isnormal -9.99999999E+1000 -> 0 +bool1038 isnormal 9.99999999E+2000 -> 0 +bool1039 isnormal -9.99999999E+2000 -> 0 +bool1040 isnormal Infinity -> 0 +bool1041 isnormal -Infinity -> 0 +bool1042 isnormal NaN -> 0 +bool1043 isnormal -NaN -> 0 +bool1044 isnormal NaN123 -> 0 +bool1045 isnormal -NaN123 -> 0 +bool1046 isnormal sNaN -> 0 +bool1047 isnormal -sNaN -> 0 +bool1048 isnormal sNaN123 -> 0 +bool1049 isnormal -sNaN123 -> 0 +bool1050 isqnan 0E-2000 -> 0 +bool1051 isqnan -0E-2000 -> 0 +bool1052 isqnan 0E-1008 -> 0 +bool1053 isqnan -0E-1008 -> 0 +bool1054 isqnan 0E-1007 -> 0 +bool1055 isqnan -0E-1007 -> 0 +bool1056 isqnan 0E-1006 -> 0 +bool1057 isqnan -0E-1006 -> 0 +bool1058 isqnan 0E-1000 -> 0 +bool1059 isqnan -0E-1000 -> 0 +bool1060 isqnan 0E-999 -> 0 +bool1061 isqnan -0E-999 -> 0 +bool1062 isqnan 0E-998 -> 0 +bool1063 isqnan -0E-998 -> 0 +bool1064 isqnan 0E-100 -> 0 +bool1065 isqnan -0E-100 -> 0 +bool1066 isqnan 0.000000 -> 0 +bool1067 isqnan -0.000000 -> 0 +bool1068 isqnan 0.000 -> 0 +bool1069 isqnan -0.000 -> 0 +bool1070 isqnan 0.00 -> 0 +bool1071 isqnan -0.00 -> 0 +bool1072 isqnan 0.0 -> 0 +bool1073 isqnan -0.0 -> 0 +bool1074 isqnan 0 -> 0 +bool1075 isqnan -0 -> 0 +bool1076 isqnan 0E+1 -> 0 +bool1077 isqnan -0E+1 -> 0 +bool1078 isqnan 0E+2 -> 0 +bool1079 isqnan -0E+2 -> 0 +bool1080 isqnan 0E+3 -> 0 +bool1081 isqnan -0E+3 -> 0 +bool1082 isqnan 0E+6 -> 0 +bool1083 isqnan -0E+6 -> 0 +bool1084 isqnan 0E+100 -> 0 +bool1085 isqnan -0E+100 -> 0 +bool1086 isqnan 0E+990 -> 0 +bool1087 isqnan -0E+990 -> 0 +bool1088 isqnan 0E+991 -> 0 +bool1089 isqnan -0E+991 -> 0 +bool1090 isqnan 0E+992 -> 0 +bool1091 isqnan -0E+992 -> 0 +bool1092 isqnan 0E+998 -> 0 +bool1093 isqnan -0E+998 -> 0 +bool1094 isqnan 0E+999 -> 0 +bool1095 isqnan -0E+999 -> 0 +bool1096 isqnan 0E+1000 -> 0 +bool1097 isqnan -0E+1000 -> 0 +bool1098 isqnan 0E+2000 -> 0 +bool1099 isqnan -0E+2000 -> 0 +bool1100 isqnan 1E-2000 -> 0 +bool1101 isqnan -1E-2000 -> 0 +bool1102 isqnan 1E-1008 -> 0 +bool1103 isqnan -1E-1008 -> 0 +bool1104 isqnan 1E-1007 -> 0 +bool1105 isqnan -1E-1007 -> 0 +bool1106 isqnan 1E-1006 -> 0 +bool1107 isqnan -1E-1006 -> 0 +bool1108 isqnan 1E-1000 -> 0 +bool1109 isqnan -1E-1000 -> 0 +bool1110 isqnan 1E-999 -> 0 +bool1111 isqnan -1E-999 -> 0 +bool1112 isqnan 1E-998 -> 0 +bool1113 isqnan -1E-998 -> 0 +bool1114 isqnan 1E-100 -> 0 +bool1115 isqnan -1E-100 -> 0 +bool1116 isqnan 0.000001 -> 0 +bool1117 isqnan -0.000001 -> 0 +bool1118 isqnan 0.001 -> 0 +bool1119 isqnan -0.001 -> 0 +bool1120 isqnan 0.01 -> 0 +bool1121 isqnan -0.01 -> 0 +bool1122 isqnan 0.1 -> 0 +bool1123 isqnan -0.1 -> 0 +bool1124 isqnan 1 -> 0 +bool1125 isqnan -1 -> 0 +bool1126 isqnan 1E+1 -> 0 +bool1127 isqnan -1E+1 -> 0 +bool1128 isqnan 1E+2 -> 0 +bool1129 isqnan -1E+2 -> 0 +bool1130 isqnan 1E+3 -> 0 +bool1131 isqnan -1E+3 -> 0 +bool1132 isqnan 1E+6 -> 0 +bool1133 isqnan -1E+6 -> 0 +bool1134 isqnan 1E+100 -> 0 +bool1135 isqnan -1E+100 -> 0 +bool1136 isqnan 1E+990 -> 0 +bool1137 isqnan -1E+990 -> 0 +bool1138 isqnan 1E+991 -> 0 +bool1139 isqnan -1E+991 -> 0 +bool1140 isqnan 1E+992 -> 0 +bool1141 isqnan -1E+992 -> 0 +bool1142 isqnan 1E+998 -> 0 +bool1143 isqnan -1E+998 -> 0 +bool1144 isqnan 1E+999 -> 0 +bool1145 isqnan -1E+999 -> 0 +bool1146 isqnan 1E+1000 -> 0 +bool1147 isqnan -1E+1000 -> 0 +bool1148 isqnan 1E+2000 -> 0 +bool1149 isqnan -1E+2000 -> 0 +bool1150 isqnan 9E-2000 -> 0 +bool1151 isqnan -9E-2000 -> 0 +bool1152 isqnan 9E-1008 -> 0 +bool1153 isqnan -9E-1008 -> 0 +bool1154 isqnan 9E-1007 -> 0 +bool1155 isqnan -9E-1007 -> 0 +bool1156 isqnan 9E-1006 -> 0 +bool1157 isqnan -9E-1006 -> 0 +bool1158 isqnan 9E-1000 -> 0 +bool1159 isqnan -9E-1000 -> 0 +bool1160 isqnan 9E-999 -> 0 +bool1161 isqnan -9E-999 -> 0 +bool1162 isqnan 9E-998 -> 0 +bool1163 isqnan -9E-998 -> 0 +bool1164 isqnan 9E-100 -> 0 +bool1165 isqnan -9E-100 -> 0 +bool1166 isqnan 0.000009 -> 0 +bool1167 isqnan -0.000009 -> 0 +bool1168 isqnan 0.009 -> 0 +bool1169 isqnan -0.009 -> 0 +bool1170 isqnan 0.09 -> 0 +bool1171 isqnan -0.09 -> 0 +bool1172 isqnan 0.9 -> 0 +bool1173 isqnan -0.9 -> 0 +bool1174 isqnan 9 -> 0 +bool1175 isqnan -9 -> 0 +bool1176 isqnan 9E+1 -> 0 +bool1177 isqnan -9E+1 -> 0 +bool1178 isqnan 9E+2 -> 0 +bool1179 isqnan -9E+2 -> 0 +bool1180 isqnan 9E+3 -> 0 +bool1181 isqnan -9E+3 -> 0 +bool1182 isqnan 9E+6 -> 0 +bool1183 isqnan -9E+6 -> 0 +bool1184 isqnan 9E+100 -> 0 +bool1185 isqnan -9E+100 -> 0 +bool1186 isqnan 9E+990 -> 0 +bool1187 isqnan -9E+990 -> 0 +bool1188 isqnan 9E+991 -> 0 +bool1189 isqnan -9E+991 -> 0 +bool1190 isqnan 9E+992 -> 0 +bool1191 isqnan -9E+992 -> 0 +bool1192 isqnan 9E+998 -> 0 +bool1193 isqnan -9E+998 -> 0 +bool1194 isqnan 9E+999 -> 0 +bool1195 isqnan -9E+999 -> 0 +bool1196 isqnan 9E+1000 -> 0 +bool1197 isqnan -9E+1000 -> 0 +bool1198 isqnan 9E+2000 -> 0 +bool1199 isqnan -9E+2000 -> 0 +bool1200 isqnan 9.99999999E-2000 -> 0 +bool1201 isqnan -9.99999999E-2000 -> 0 +bool1202 isqnan 9.99999999E-1008 -> 0 +bool1203 isqnan -9.99999999E-1008 -> 0 +bool1204 isqnan 9.99999999E-1007 -> 0 +bool1205 isqnan -9.99999999E-1007 -> 0 +bool1206 isqnan 9.99999999E-1006 -> 0 +bool1207 isqnan -9.99999999E-1006 -> 0 +bool1208 isqnan 9.99999999E-1000 -> 0 +bool1209 isqnan -9.99999999E-1000 -> 0 +bool1210 isqnan 9.99999999E-999 -> 0 +bool1211 isqnan -9.99999999E-999 -> 0 +bool1212 isqnan 9.99999999E-998 -> 0 +bool1213 isqnan -9.99999999E-998 -> 0 +bool1214 isqnan 9.99999999E-100 -> 0 +bool1215 isqnan -9.99999999E-100 -> 0 +bool1216 isqnan 0.00000999999999 -> 0 +bool1217 isqnan -0.00000999999999 -> 0 +bool1218 isqnan 0.00999999999 -> 0 +bool1219 isqnan -0.00999999999 -> 0 +bool1220 isqnan 0.0999999999 -> 0 +bool1221 isqnan -0.0999999999 -> 0 +bool1222 isqnan 0.999999999 -> 0 +bool1223 isqnan -0.999999999 -> 0 +bool1224 isqnan 9.99999999 -> 0 +bool1225 isqnan -9.99999999 -> 0 +bool1226 isqnan 99.9999999 -> 0 +bool1227 isqnan -99.9999999 -> 0 +bool1228 isqnan 999.999999 -> 0 +bool1229 isqnan -999.999999 -> 0 +bool1230 isqnan 9999.99999 -> 0 +bool1231 isqnan -9999.99999 -> 0 +bool1232 isqnan 9999999.99 -> 0 +bool1233 isqnan -9999999.99 -> 0 +bool1234 isqnan 9.99999999E+100 -> 0 +bool1235 isqnan -9.99999999E+100 -> 0 +bool1236 isqnan 9.99999999E+990 -> 0 +bool1237 isqnan -9.99999999E+990 -> 0 +bool1238 isqnan 9.99999999E+991 -> 0 +bool1239 isqnan -9.99999999E+991 -> 0 +bool1240 isqnan 9.99999999E+992 -> 0 +bool1241 isqnan -9.99999999E+992 -> 0 +bool1242 isqnan 9.99999999E+998 -> 0 +bool1243 isqnan -9.99999999E+998 -> 0 +bool1244 isqnan 9.99999999E+999 -> 0 +bool1245 isqnan -9.99999999E+999 -> 0 +bool1246 isqnan 9.99999999E+1000 -> 0 +bool1247 isqnan -9.99999999E+1000 -> 0 +bool1248 isqnan 9.99999999E+2000 -> 0 +bool1249 isqnan -9.99999999E+2000 -> 0 +bool1250 isqnan Infinity -> 0 +bool1251 isqnan -Infinity -> 0 +bool1252 isqnan NaN -> 1 +bool1253 isqnan -NaN -> 1 +bool1254 isqnan NaN123 -> 1 +bool1255 isqnan -NaN123 -> 1 +bool1256 isqnan sNaN -> 0 +bool1257 isqnan -sNaN -> 0 +bool1258 isqnan sNaN123 -> 0 +bool1259 isqnan -sNaN123 -> 0 +bool1260 issigned 0E-2000 -> 0 +bool1261 issigned -0E-2000 -> 1 +bool1262 issigned 0E-1008 -> 0 +bool1263 issigned -0E-1008 -> 1 +bool1264 issigned 0E-1007 -> 0 +bool1265 issigned -0E-1007 -> 1 +bool1266 issigned 0E-1006 -> 0 +bool1267 issigned -0E-1006 -> 1 +bool1268 issigned 0E-1000 -> 0 +bool1269 issigned -0E-1000 -> 1 +bool1270 issigned 0E-999 -> 0 +bool1271 issigned -0E-999 -> 1 +bool1272 issigned 0E-998 -> 0 +bool1273 issigned -0E-998 -> 1 +bool1274 issigned 0E-100 -> 0 +bool1275 issigned -0E-100 -> 1 +bool1276 issigned 0.000000 -> 0 +bool1277 issigned -0.000000 -> 1 +bool1278 issigned 0.000 -> 0 +bool1279 issigned -0.000 -> 1 +bool1280 issigned 0.00 -> 0 +bool1281 issigned -0.00 -> 1 +bool1282 issigned 0.0 -> 0 +bool1283 issigned -0.0 -> 1 +bool1284 issigned 0 -> 0 +bool1285 issigned -0 -> 1 +bool1286 issigned 0E+1 -> 0 +bool1287 issigned -0E+1 -> 1 +bool1288 issigned 0E+2 -> 0 +bool1289 issigned -0E+2 -> 1 +bool1290 issigned 0E+3 -> 0 +bool1291 issigned -0E+3 -> 1 +bool1292 issigned 0E+6 -> 0 +bool1293 issigned -0E+6 -> 1 +bool1294 issigned 0E+100 -> 0 +bool1295 issigned -0E+100 -> 1 +bool1296 issigned 0E+990 -> 0 +bool1297 issigned -0E+990 -> 1 +bool1298 issigned 0E+991 -> 0 +bool1299 issigned -0E+991 -> 1 +bool1300 issigned 0E+992 -> 0 +bool1301 issigned -0E+992 -> 1 +bool1302 issigned 0E+998 -> 0 +bool1303 issigned -0E+998 -> 1 +bool1304 issigned 0E+999 -> 0 +bool1305 issigned -0E+999 -> 1 +bool1306 issigned 0E+1000 -> 0 +bool1307 issigned -0E+1000 -> 1 +bool1308 issigned 0E+2000 -> 0 +bool1309 issigned -0E+2000 -> 1 +bool1310 issigned 1E-2000 -> 0 +bool1311 issigned -1E-2000 -> 1 +bool1312 issigned 1E-1008 -> 0 +bool1313 issigned -1E-1008 -> 1 +bool1314 issigned 1E-1007 -> 0 +bool1315 issigned -1E-1007 -> 1 +bool1316 issigned 1E-1006 -> 0 +bool1317 issigned -1E-1006 -> 1 +bool1318 issigned 1E-1000 -> 0 +bool1319 issigned -1E-1000 -> 1 +bool1320 issigned 1E-999 -> 0 +bool1321 issigned -1E-999 -> 1 +bool1322 issigned 1E-998 -> 0 +bool1323 issigned -1E-998 -> 1 +bool1324 issigned 1E-100 -> 0 +bool1325 issigned -1E-100 -> 1 +bool1326 issigned 0.000001 -> 0 +bool1327 issigned -0.000001 -> 1 +bool1328 issigned 0.001 -> 0 +bool1329 issigned -0.001 -> 1 +bool1330 issigned 0.01 -> 0 +bool1331 issigned -0.01 -> 1 +bool1332 issigned 0.1 -> 0 +bool1333 issigned -0.1 -> 1 +bool1334 issigned 1 -> 0 +bool1335 issigned -1 -> 1 +bool1336 issigned 1E+1 -> 0 +bool1337 issigned -1E+1 -> 1 +bool1338 issigned 1E+2 -> 0 +bool1339 issigned -1E+2 -> 1 +bool1340 issigned 1E+3 -> 0 +bool1341 issigned -1E+3 -> 1 +bool1342 issigned 1E+6 -> 0 +bool1343 issigned -1E+6 -> 1 +bool1344 issigned 1E+100 -> 0 +bool1345 issigned -1E+100 -> 1 +bool1346 issigned 1E+990 -> 0 +bool1347 issigned -1E+990 -> 1 +bool1348 issigned 1E+991 -> 0 +bool1349 issigned -1E+991 -> 1 +bool1350 issigned 1E+992 -> 0 +bool1351 issigned -1E+992 -> 1 +bool1352 issigned 1E+998 -> 0 +bool1353 issigned -1E+998 -> 1 +bool1354 issigned 1E+999 -> 0 +bool1355 issigned -1E+999 -> 1 +bool1356 issigned 1E+1000 -> 0 +bool1357 issigned -1E+1000 -> 1 +bool1358 issigned 1E+2000 -> 0 +bool1359 issigned -1E+2000 -> 1 +bool1360 issigned 9E-2000 -> 0 +bool1361 issigned -9E-2000 -> 1 +bool1362 issigned 9E-1008 -> 0 +bool1363 issigned -9E-1008 -> 1 +bool1364 issigned 9E-1007 -> 0 +bool1365 issigned -9E-1007 -> 1 +bool1366 issigned 9E-1006 -> 0 +bool1367 issigned -9E-1006 -> 1 +bool1368 issigned 9E-1000 -> 0 +bool1369 issigned -9E-1000 -> 1 +bool1370 issigned 9E-999 -> 0 +bool1371 issigned -9E-999 -> 1 +bool1372 issigned 9E-998 -> 0 +bool1373 issigned -9E-998 -> 1 +bool1374 issigned 9E-100 -> 0 +bool1375 issigned -9E-100 -> 1 +bool1376 issigned 0.000009 -> 0 +bool1377 issigned -0.000009 -> 1 +bool1378 issigned 0.009 -> 0 +bool1379 issigned -0.009 -> 1 +bool1380 issigned 0.09 -> 0 +bool1381 issigned -0.09 -> 1 +bool1382 issigned 0.9 -> 0 +bool1383 issigned -0.9 -> 1 +bool1384 issigned 9 -> 0 +bool1385 issigned -9 -> 1 +bool1386 issigned 9E+1 -> 0 +bool1387 issigned -9E+1 -> 1 +bool1388 issigned 9E+2 -> 0 +bool1389 issigned -9E+2 -> 1 +bool1390 issigned 9E+3 -> 0 +bool1391 issigned -9E+3 -> 1 +bool1392 issigned 9E+6 -> 0 +bool1393 issigned -9E+6 -> 1 +bool1394 issigned 9E+100 -> 0 +bool1395 issigned -9E+100 -> 1 +bool1396 issigned 9E+990 -> 0 +bool1397 issigned -9E+990 -> 1 +bool1398 issigned 9E+991 -> 0 +bool1399 issigned -9E+991 -> 1 +bool1400 issigned 9E+992 -> 0 +bool1401 issigned -9E+992 -> 1 +bool1402 issigned 9E+998 -> 0 +bool1403 issigned -9E+998 -> 1 +bool1404 issigned 9E+999 -> 0 +bool1405 issigned -9E+999 -> 1 +bool1406 issigned 9E+1000 -> 0 +bool1407 issigned -9E+1000 -> 1 +bool1408 issigned 9E+2000 -> 0 +bool1409 issigned -9E+2000 -> 1 +bool1410 issigned 9.99999999E-2000 -> 0 +bool1411 issigned -9.99999999E-2000 -> 1 +bool1412 issigned 9.99999999E-1008 -> 0 +bool1413 issigned -9.99999999E-1008 -> 1 +bool1414 issigned 9.99999999E-1007 -> 0 +bool1415 issigned -9.99999999E-1007 -> 1 +bool1416 issigned 9.99999999E-1006 -> 0 +bool1417 issigned -9.99999999E-1006 -> 1 +bool1418 issigned 9.99999999E-1000 -> 0 +bool1419 issigned -9.99999999E-1000 -> 1 +bool1420 issigned 9.99999999E-999 -> 0 +bool1421 issigned -9.99999999E-999 -> 1 +bool1422 issigned 9.99999999E-998 -> 0 +bool1423 issigned -9.99999999E-998 -> 1 +bool1424 issigned 9.99999999E-100 -> 0 +bool1425 issigned -9.99999999E-100 -> 1 +bool1426 issigned 0.00000999999999 -> 0 +bool1427 issigned -0.00000999999999 -> 1 +bool1428 issigned 0.00999999999 -> 0 +bool1429 issigned -0.00999999999 -> 1 +bool1430 issigned 0.0999999999 -> 0 +bool1431 issigned -0.0999999999 -> 1 +bool1432 issigned 0.999999999 -> 0 +bool1433 issigned -0.999999999 -> 1 +bool1434 issigned 9.99999999 -> 0 +bool1435 issigned -9.99999999 -> 1 +bool1436 issigned 99.9999999 -> 0 +bool1437 issigned -99.9999999 -> 1 +bool1438 issigned 999.999999 -> 0 +bool1439 issigned -999.999999 -> 1 +bool1440 issigned 9999.99999 -> 0 +bool1441 issigned -9999.99999 -> 1 +bool1442 issigned 9999999.99 -> 0 +bool1443 issigned -9999999.99 -> 1 +bool1444 issigned 9.99999999E+100 -> 0 +bool1445 issigned -9.99999999E+100 -> 1 +bool1446 issigned 9.99999999E+990 -> 0 +bool1447 issigned -9.99999999E+990 -> 1 +bool1448 issigned 9.99999999E+991 -> 0 +bool1449 issigned -9.99999999E+991 -> 1 +bool1450 issigned 9.99999999E+992 -> 0 +bool1451 issigned -9.99999999E+992 -> 1 +bool1452 issigned 9.99999999E+998 -> 0 +bool1453 issigned -9.99999999E+998 -> 1 +bool1454 issigned 9.99999999E+999 -> 0 +bool1455 issigned -9.99999999E+999 -> 1 +bool1456 issigned 9.99999999E+1000 -> 0 +bool1457 issigned -9.99999999E+1000 -> 1 +bool1458 issigned 9.99999999E+2000 -> 0 +bool1459 issigned -9.99999999E+2000 -> 1 +bool1460 issigned Infinity -> 0 +bool1461 issigned -Infinity -> 1 +bool1462 issigned NaN -> 0 +bool1463 issigned -NaN -> 1 +bool1464 issigned NaN123 -> 0 +bool1465 issigned -NaN123 -> 1 +bool1466 issigned sNaN -> 0 +bool1467 issigned -sNaN -> 1 +bool1468 issigned sNaN123 -> 0 +bool1469 issigned -sNaN123 -> 1 +bool1470 issnan 0E-2000 -> 0 +bool1471 issnan -0E-2000 -> 0 +bool1472 issnan 0E-1008 -> 0 +bool1473 issnan -0E-1008 -> 0 +bool1474 issnan 0E-1007 -> 0 +bool1475 issnan -0E-1007 -> 0 +bool1476 issnan 0E-1006 -> 0 +bool1477 issnan -0E-1006 -> 0 +bool1478 issnan 0E-1000 -> 0 +bool1479 issnan -0E-1000 -> 0 +bool1480 issnan 0E-999 -> 0 +bool1481 issnan -0E-999 -> 0 +bool1482 issnan 0E-998 -> 0 +bool1483 issnan -0E-998 -> 0 +bool1484 issnan 0E-100 -> 0 +bool1485 issnan -0E-100 -> 0 +bool1486 issnan 0.000000 -> 0 +bool1487 issnan -0.000000 -> 0 +bool1488 issnan 0.000 -> 0 +bool1489 issnan -0.000 -> 0 +bool1490 issnan 0.00 -> 0 +bool1491 issnan -0.00 -> 0 +bool1492 issnan 0.0 -> 0 +bool1493 issnan -0.0 -> 0 +bool1494 issnan 0 -> 0 +bool1495 issnan -0 -> 0 +bool1496 issnan 0E+1 -> 0 +bool1497 issnan -0E+1 -> 0 +bool1498 issnan 0E+2 -> 0 +bool1499 issnan -0E+2 -> 0 +bool1500 issnan 0E+3 -> 0 +bool1501 issnan -0E+3 -> 0 +bool1502 issnan 0E+6 -> 0 +bool1503 issnan -0E+6 -> 0 +bool1504 issnan 0E+100 -> 0 +bool1505 issnan -0E+100 -> 0 +bool1506 issnan 0E+990 -> 0 +bool1507 issnan -0E+990 -> 0 +bool1508 issnan 0E+991 -> 0 +bool1509 issnan -0E+991 -> 0 +bool1510 issnan 0E+992 -> 0 +bool1511 issnan -0E+992 -> 0 +bool1512 issnan 0E+998 -> 0 +bool1513 issnan -0E+998 -> 0 +bool1514 issnan 0E+999 -> 0 +bool1515 issnan -0E+999 -> 0 +bool1516 issnan 0E+1000 -> 0 +bool1517 issnan -0E+1000 -> 0 +bool1518 issnan 0E+2000 -> 0 +bool1519 issnan -0E+2000 -> 0 +bool1520 issnan 1E-2000 -> 0 +bool1521 issnan -1E-2000 -> 0 +bool1522 issnan 1E-1008 -> 0 +bool1523 issnan -1E-1008 -> 0 +bool1524 issnan 1E-1007 -> 0 +bool1525 issnan -1E-1007 -> 0 +bool1526 issnan 1E-1006 -> 0 +bool1527 issnan -1E-1006 -> 0 +bool1528 issnan 1E-1000 -> 0 +bool1529 issnan -1E-1000 -> 0 +bool1530 issnan 1E-999 -> 0 +bool1531 issnan -1E-999 -> 0 +bool1532 issnan 1E-998 -> 0 +bool1533 issnan -1E-998 -> 0 +bool1534 issnan 1E-100 -> 0 +bool1535 issnan -1E-100 -> 0 +bool1536 issnan 0.000001 -> 0 +bool1537 issnan -0.000001 -> 0 +bool1538 issnan 0.001 -> 0 +bool1539 issnan -0.001 -> 0 +bool1540 issnan 0.01 -> 0 +bool1541 issnan -0.01 -> 0 +bool1542 issnan 0.1 -> 0 +bool1543 issnan -0.1 -> 0 +bool1544 issnan 1 -> 0 +bool1545 issnan -1 -> 0 +bool1546 issnan 1E+1 -> 0 +bool1547 issnan -1E+1 -> 0 +bool1548 issnan 1E+2 -> 0 +bool1549 issnan -1E+2 -> 0 +bool1550 issnan 1E+3 -> 0 +bool1551 issnan -1E+3 -> 0 +bool1552 issnan 1E+6 -> 0 +bool1553 issnan -1E+6 -> 0 +bool1554 issnan 1E+100 -> 0 +bool1555 issnan -1E+100 -> 0 +bool1556 issnan 1E+990 -> 0 +bool1557 issnan -1E+990 -> 0 +bool1558 issnan 1E+991 -> 0 +bool1559 issnan -1E+991 -> 0 +bool1560 issnan 1E+992 -> 0 +bool1561 issnan -1E+992 -> 0 +bool1562 issnan 1E+998 -> 0 +bool1563 issnan -1E+998 -> 0 +bool1564 issnan 1E+999 -> 0 +bool1565 issnan -1E+999 -> 0 +bool1566 issnan 1E+1000 -> 0 +bool1567 issnan -1E+1000 -> 0 +bool1568 issnan 1E+2000 -> 0 +bool1569 issnan -1E+2000 -> 0 +bool1570 issnan 9E-2000 -> 0 +bool1571 issnan -9E-2000 -> 0 +bool1572 issnan 9E-1008 -> 0 +bool1573 issnan -9E-1008 -> 0 +bool1574 issnan 9E-1007 -> 0 +bool1575 issnan -9E-1007 -> 0 +bool1576 issnan 9E-1006 -> 0 +bool1577 issnan -9E-1006 -> 0 +bool1578 issnan 9E-1000 -> 0 +bool1579 issnan -9E-1000 -> 0 +bool1580 issnan 9E-999 -> 0 +bool1581 issnan -9E-999 -> 0 +bool1582 issnan 9E-998 -> 0 +bool1583 issnan -9E-998 -> 0 +bool1584 issnan 9E-100 -> 0 +bool1585 issnan -9E-100 -> 0 +bool1586 issnan 0.000009 -> 0 +bool1587 issnan -0.000009 -> 0 +bool1588 issnan 0.009 -> 0 +bool1589 issnan -0.009 -> 0 +bool1590 issnan 0.09 -> 0 +bool1591 issnan -0.09 -> 0 +bool1592 issnan 0.9 -> 0 +bool1593 issnan -0.9 -> 0 +bool1594 issnan 9 -> 0 +bool1595 issnan -9 -> 0 +bool1596 issnan 9E+1 -> 0 +bool1597 issnan -9E+1 -> 0 +bool1598 issnan 9E+2 -> 0 +bool1599 issnan -9E+2 -> 0 +bool1600 issnan 9E+3 -> 0 +bool1601 issnan -9E+3 -> 0 +bool1602 issnan 9E+6 -> 0 +bool1603 issnan -9E+6 -> 0 +bool1604 issnan 9E+100 -> 0 +bool1605 issnan -9E+100 -> 0 +bool1606 issnan 9E+990 -> 0 +bool1607 issnan -9E+990 -> 0 +bool1608 issnan 9E+991 -> 0 +bool1609 issnan -9E+991 -> 0 +bool1610 issnan 9E+992 -> 0 +bool1611 issnan -9E+992 -> 0 +bool1612 issnan 9E+998 -> 0 +bool1613 issnan -9E+998 -> 0 +bool1614 issnan 9E+999 -> 0 +bool1615 issnan -9E+999 -> 0 +bool1616 issnan 9E+1000 -> 0 +bool1617 issnan -9E+1000 -> 0 +bool1618 issnan 9E+2000 -> 0 +bool1619 issnan -9E+2000 -> 0 +bool1620 issnan 9.99999999E-2000 -> 0 +bool1621 issnan -9.99999999E-2000 -> 0 +bool1622 issnan 9.99999999E-1008 -> 0 +bool1623 issnan -9.99999999E-1008 -> 0 +bool1624 issnan 9.99999999E-1007 -> 0 +bool1625 issnan -9.99999999E-1007 -> 0 +bool1626 issnan 9.99999999E-1006 -> 0 +bool1627 issnan -9.99999999E-1006 -> 0 +bool1628 issnan 9.99999999E-1000 -> 0 +bool1629 issnan -9.99999999E-1000 -> 0 +bool1630 issnan 9.99999999E-999 -> 0 +bool1631 issnan -9.99999999E-999 -> 0 +bool1632 issnan 9.99999999E-998 -> 0 +bool1633 issnan -9.99999999E-998 -> 0 +bool1634 issnan 9.99999999E-100 -> 0 +bool1635 issnan -9.99999999E-100 -> 0 +bool1636 issnan 0.00000999999999 -> 0 +bool1637 issnan -0.00000999999999 -> 0 +bool1638 issnan 0.00999999999 -> 0 +bool1639 issnan -0.00999999999 -> 0 +bool1640 issnan 0.0999999999 -> 0 +bool1641 issnan -0.0999999999 -> 0 +bool1642 issnan 0.999999999 -> 0 +bool1643 issnan -0.999999999 -> 0 +bool1644 issnan 9.99999999 -> 0 +bool1645 issnan -9.99999999 -> 0 +bool1646 issnan 99.9999999 -> 0 +bool1647 issnan -99.9999999 -> 0 +bool1648 issnan 999.999999 -> 0 +bool1649 issnan -999.999999 -> 0 +bool1650 issnan 9999.99999 -> 0 +bool1651 issnan -9999.99999 -> 0 +bool1652 issnan 9999999.99 -> 0 +bool1653 issnan -9999999.99 -> 0 +bool1654 issnan 9.99999999E+100 -> 0 +bool1655 issnan -9.99999999E+100 -> 0 +bool1656 issnan 9.99999999E+990 -> 0 +bool1657 issnan -9.99999999E+990 -> 0 +bool1658 issnan 9.99999999E+991 -> 0 +bool1659 issnan -9.99999999E+991 -> 0 +bool1660 issnan 9.99999999E+992 -> 0 +bool1661 issnan -9.99999999E+992 -> 0 +bool1662 issnan 9.99999999E+998 -> 0 +bool1663 issnan -9.99999999E+998 -> 0 +bool1664 issnan 9.99999999E+999 -> 0 +bool1665 issnan -9.99999999E+999 -> 0 +bool1666 issnan 9.99999999E+1000 -> 0 +bool1667 issnan -9.99999999E+1000 -> 0 +bool1668 issnan 9.99999999E+2000 -> 0 +bool1669 issnan -9.99999999E+2000 -> 0 +bool1670 issnan Infinity -> 0 +bool1671 issnan -Infinity -> 0 +bool1672 issnan NaN -> 0 +bool1673 issnan -NaN -> 0 +bool1674 issnan NaN123 -> 0 +bool1675 issnan -NaN123 -> 0 +bool1676 issnan sNaN -> 1 +bool1677 issnan -sNaN -> 1 +bool1678 issnan sNaN123 -> 1 +bool1679 issnan -sNaN123 -> 1 +bool1680 issubnormal 0E-2000 -> 0 +bool1681 issubnormal -0E-2000 -> 0 +bool1682 issubnormal 0E-1008 -> 0 +bool1683 issubnormal -0E-1008 -> 0 +bool1684 issubnormal 0E-1007 -> 0 +bool1685 issubnormal -0E-1007 -> 0 +bool1686 issubnormal 0E-1006 -> 0 +bool1687 issubnormal -0E-1006 -> 0 +bool1688 issubnormal 0E-1000 -> 0 +bool1689 issubnormal -0E-1000 -> 0 +bool1690 issubnormal 0E-999 -> 0 +bool1691 issubnormal -0E-999 -> 0 +bool1692 issubnormal 0E-998 -> 0 +bool1693 issubnormal -0E-998 -> 0 +bool1694 issubnormal 0E-100 -> 0 +bool1695 issubnormal -0E-100 -> 0 +bool1696 issubnormal 0.000000 -> 0 +bool1697 issubnormal -0.000000 -> 0 +bool1698 issubnormal 0.000 -> 0 +bool1699 issubnormal -0.000 -> 0 +bool1700 issubnormal 0.00 -> 0 +bool1701 issubnormal -0.00 -> 0 +bool1702 issubnormal 0.0 -> 0 +bool1703 issubnormal -0.0 -> 0 +bool1704 issubnormal 0 -> 0 +bool1705 issubnormal -0 -> 0 +bool1706 issubnormal 0E+1 -> 0 +bool1707 issubnormal -0E+1 -> 0 +bool1708 issubnormal 0E+2 -> 0 +bool1709 issubnormal -0E+2 -> 0 +bool1710 issubnormal 0E+3 -> 0 +bool1711 issubnormal -0E+3 -> 0 +bool1712 issubnormal 0E+6 -> 0 +bool1713 issubnormal -0E+6 -> 0 +bool1714 issubnormal 0E+100 -> 0 +bool1715 issubnormal -0E+100 -> 0 +bool1716 issubnormal 0E+990 -> 0 +bool1717 issubnormal -0E+990 -> 0 +bool1718 issubnormal 0E+991 -> 0 +bool1719 issubnormal -0E+991 -> 0 +bool1720 issubnormal 0E+992 -> 0 +bool1721 issubnormal -0E+992 -> 0 +bool1722 issubnormal 0E+998 -> 0 +bool1723 issubnormal -0E+998 -> 0 +bool1724 issubnormal 0E+999 -> 0 +bool1725 issubnormal -0E+999 -> 0 +bool1726 issubnormal 0E+1000 -> 0 +bool1727 issubnormal -0E+1000 -> 0 +bool1728 issubnormal 0E+2000 -> 0 +bool1729 issubnormal -0E+2000 -> 0 +bool1730 issubnormal 1E-2000 -> 1 +bool1731 issubnormal -1E-2000 -> 1 +bool1732 issubnormal 1E-1008 -> 1 +bool1733 issubnormal -1E-1008 -> 1 +bool1734 issubnormal 1E-1007 -> 1 +bool1735 issubnormal -1E-1007 -> 1 +bool1736 issubnormal 1E-1006 -> 1 +bool1737 issubnormal -1E-1006 -> 1 +bool1738 issubnormal 1E-1000 -> 1 +bool1739 issubnormal -1E-1000 -> 1 +bool1740 issubnormal 1E-999 -> 0 +bool1741 issubnormal -1E-999 -> 0 +bool1742 issubnormal 1E-998 -> 0 +bool1743 issubnormal -1E-998 -> 0 +bool1744 issubnormal 1E-100 -> 0 +bool1745 issubnormal -1E-100 -> 0 +bool1746 issubnormal 0.000001 -> 0 +bool1747 issubnormal -0.000001 -> 0 +bool1748 issubnormal 0.001 -> 0 +bool1749 issubnormal -0.001 -> 0 +bool1750 issubnormal 0.01 -> 0 +bool1751 issubnormal -0.01 -> 0 +bool1752 issubnormal 0.1 -> 0 +bool1753 issubnormal -0.1 -> 0 +bool1754 issubnormal 1 -> 0 +bool1755 issubnormal -1 -> 0 +bool1756 issubnormal 1E+1 -> 0 +bool1757 issubnormal -1E+1 -> 0 +bool1758 issubnormal 1E+2 -> 0 +bool1759 issubnormal -1E+2 -> 0 +bool1760 issubnormal 1E+3 -> 0 +bool1761 issubnormal -1E+3 -> 0 +bool1762 issubnormal 1E+6 -> 0 +bool1763 issubnormal -1E+6 -> 0 +bool1764 issubnormal 1E+100 -> 0 +bool1765 issubnormal -1E+100 -> 0 +bool1766 issubnormal 1E+990 -> 0 +bool1767 issubnormal -1E+990 -> 0 +bool1768 issubnormal 1E+991 -> 0 +bool1769 issubnormal -1E+991 -> 0 +bool1770 issubnormal 1E+992 -> 0 +bool1771 issubnormal -1E+992 -> 0 +bool1772 issubnormal 1E+998 -> 0 +bool1773 issubnormal -1E+998 -> 0 +bool1774 issubnormal 1E+999 -> 0 +bool1775 issubnormal -1E+999 -> 0 +bool1776 issubnormal 1E+1000 -> 0 +bool1777 issubnormal -1E+1000 -> 0 +bool1778 issubnormal 1E+2000 -> 0 +bool1779 issubnormal -1E+2000 -> 0 +bool1780 issubnormal 9E-2000 -> 1 +bool1781 issubnormal -9E-2000 -> 1 +bool1782 issubnormal 9E-1008 -> 1 +bool1783 issubnormal -9E-1008 -> 1 +bool1784 issubnormal 9E-1007 -> 1 +bool1785 issubnormal -9E-1007 -> 1 +bool1786 issubnormal 9E-1006 -> 1 +bool1787 issubnormal -9E-1006 -> 1 +bool1788 issubnormal 9E-1000 -> 1 +bool1789 issubnormal -9E-1000 -> 1 +bool1790 issubnormal 9E-999 -> 0 +bool1791 issubnormal -9E-999 -> 0 +bool1792 issubnormal 9E-998 -> 0 +bool1793 issubnormal -9E-998 -> 0 +bool1794 issubnormal 9E-100 -> 0 +bool1795 issubnormal -9E-100 -> 0 +bool1796 issubnormal 0.000009 -> 0 +bool1797 issubnormal -0.000009 -> 0 +bool1798 issubnormal 0.009 -> 0 +bool1799 issubnormal -0.009 -> 0 +bool1800 issubnormal 0.09 -> 0 +bool1801 issubnormal -0.09 -> 0 +bool1802 issubnormal 0.9 -> 0 +bool1803 issubnormal -0.9 -> 0 +bool1804 issubnormal 9 -> 0 +bool1805 issubnormal -9 -> 0 +bool1806 issubnormal 9E+1 -> 0 +bool1807 issubnormal -9E+1 -> 0 +bool1808 issubnormal 9E+2 -> 0 +bool1809 issubnormal -9E+2 -> 0 +bool1810 issubnormal 9E+3 -> 0 +bool1811 issubnormal -9E+3 -> 0 +bool1812 issubnormal 9E+6 -> 0 +bool1813 issubnormal -9E+6 -> 0 +bool1814 issubnormal 9E+100 -> 0 +bool1815 issubnormal -9E+100 -> 0 +bool1816 issubnormal 9E+990 -> 0 +bool1817 issubnormal -9E+990 -> 0 +bool1818 issubnormal 9E+991 -> 0 +bool1819 issubnormal -9E+991 -> 0 +bool1820 issubnormal 9E+992 -> 0 +bool1821 issubnormal -9E+992 -> 0 +bool1822 issubnormal 9E+998 -> 0 +bool1823 issubnormal -9E+998 -> 0 +bool1824 issubnormal 9E+999 -> 0 +bool1825 issubnormal -9E+999 -> 0 +bool1826 issubnormal 9E+1000 -> 0 +bool1827 issubnormal -9E+1000 -> 0 +bool1828 issubnormal 9E+2000 -> 0 +bool1829 issubnormal -9E+2000 -> 0 +bool1830 issubnormal 9.99999999E-2000 -> 1 +bool1831 issubnormal -9.99999999E-2000 -> 1 +bool1832 issubnormal 9.99999999E-1008 -> 1 +bool1833 issubnormal -9.99999999E-1008 -> 1 +bool1834 issubnormal 9.99999999E-1007 -> 1 +bool1835 issubnormal -9.99999999E-1007 -> 1 +bool1836 issubnormal 9.99999999E-1006 -> 1 +bool1837 issubnormal -9.99999999E-1006 -> 1 +bool1838 issubnormal 9.99999999E-1000 -> 1 +bool1839 issubnormal -9.99999999E-1000 -> 1 +bool1840 issubnormal 9.99999999E-999 -> 0 +bool1841 issubnormal -9.99999999E-999 -> 0 +bool1842 issubnormal 9.99999999E-998 -> 0 +bool1843 issubnormal -9.99999999E-998 -> 0 +bool1844 issubnormal 9.99999999E-100 -> 0 +bool1845 issubnormal -9.99999999E-100 -> 0 +bool1846 issubnormal 0.00000999999999 -> 0 +bool1847 issubnormal -0.00000999999999 -> 0 +bool1848 issubnormal 0.00999999999 -> 0 +bool1849 issubnormal -0.00999999999 -> 0 +bool1850 issubnormal 0.0999999999 -> 0 +bool1851 issubnormal -0.0999999999 -> 0 +bool1852 issubnormal 0.999999999 -> 0 +bool1853 issubnormal -0.999999999 -> 0 +bool1854 issubnormal 9.99999999 -> 0 +bool1855 issubnormal -9.99999999 -> 0 +bool1856 issubnormal 99.9999999 -> 0 +bool1857 issubnormal -99.9999999 -> 0 +bool1858 issubnormal 999.999999 -> 0 +bool1859 issubnormal -999.999999 -> 0 +bool1860 issubnormal 9999.99999 -> 0 +bool1861 issubnormal -9999.99999 -> 0 +bool1862 issubnormal 9999999.99 -> 0 +bool1863 issubnormal -9999999.99 -> 0 +bool1864 issubnormal 9.99999999E+100 -> 0 +bool1865 issubnormal -9.99999999E+100 -> 0 +bool1866 issubnormal 9.99999999E+990 -> 0 +bool1867 issubnormal -9.99999999E+990 -> 0 +bool1868 issubnormal 9.99999999E+991 -> 0 +bool1869 issubnormal -9.99999999E+991 -> 0 +bool1870 issubnormal 9.99999999E+992 -> 0 +bool1871 issubnormal -9.99999999E+992 -> 0 +bool1872 issubnormal 9.99999999E+998 -> 0 +bool1873 issubnormal -9.99999999E+998 -> 0 +bool1874 issubnormal 9.99999999E+999 -> 0 +bool1875 issubnormal -9.99999999E+999 -> 0 +bool1876 issubnormal 9.99999999E+1000 -> 0 +bool1877 issubnormal -9.99999999E+1000 -> 0 +bool1878 issubnormal 9.99999999E+2000 -> 0 +bool1879 issubnormal -9.99999999E+2000 -> 0 +bool1880 issubnormal Infinity -> 0 +bool1881 issubnormal -Infinity -> 0 +bool1882 issubnormal NaN -> 0 +bool1883 issubnormal -NaN -> 0 +bool1884 issubnormal NaN123 -> 0 +bool1885 issubnormal -NaN123 -> 0 +bool1886 issubnormal sNaN -> 0 +bool1887 issubnormal -sNaN -> 0 +bool1888 issubnormal sNaN123 -> 0 +bool1889 issubnormal -sNaN123 -> 0 +bool1890 iszero 0E-2000 -> 1 +bool1891 iszero -0E-2000 -> 1 +bool1892 iszero 0E-1008 -> 1 +bool1893 iszero -0E-1008 -> 1 +bool1894 iszero 0E-1007 -> 1 +bool1895 iszero -0E-1007 -> 1 +bool1896 iszero 0E-1006 -> 1 +bool1897 iszero -0E-1006 -> 1 +bool1898 iszero 0E-1000 -> 1 +bool1899 iszero -0E-1000 -> 1 +bool1900 iszero 0E-999 -> 1 +bool1901 iszero -0E-999 -> 1 +bool1902 iszero 0E-998 -> 1 +bool1903 iszero -0E-998 -> 1 +bool1904 iszero 0E-100 -> 1 +bool1905 iszero -0E-100 -> 1 +bool1906 iszero 0.000000 -> 1 +bool1907 iszero -0.000000 -> 1 +bool1908 iszero 0.000 -> 1 +bool1909 iszero -0.000 -> 1 +bool1910 iszero 0.00 -> 1 +bool1911 iszero -0.00 -> 1 +bool1912 iszero 0.0 -> 1 +bool1913 iszero -0.0 -> 1 +bool1914 iszero 0 -> 1 +bool1915 iszero -0 -> 1 +bool1916 iszero 0E+1 -> 1 +bool1917 iszero -0E+1 -> 1 +bool1918 iszero 0E+2 -> 1 +bool1919 iszero -0E+2 -> 1 +bool1920 iszero 0E+3 -> 1 +bool1921 iszero -0E+3 -> 1 +bool1922 iszero 0E+6 -> 1 +bool1923 iszero -0E+6 -> 1 +bool1924 iszero 0E+100 -> 1 +bool1925 iszero -0E+100 -> 1 +bool1926 iszero 0E+990 -> 1 +bool1927 iszero -0E+990 -> 1 +bool1928 iszero 0E+991 -> 1 +bool1929 iszero -0E+991 -> 1 +bool1930 iszero 0E+992 -> 1 +bool1931 iszero -0E+992 -> 1 +bool1932 iszero 0E+998 -> 1 +bool1933 iszero -0E+998 -> 1 +bool1934 iszero 0E+999 -> 1 +bool1935 iszero -0E+999 -> 1 +bool1936 iszero 0E+1000 -> 1 +bool1937 iszero -0E+1000 -> 1 +bool1938 iszero 0E+2000 -> 1 +bool1939 iszero -0E+2000 -> 1 +bool1940 iszero 1E-2000 -> 0 +bool1941 iszero -1E-2000 -> 0 +bool1942 iszero 1E-1008 -> 0 +bool1943 iszero -1E-1008 -> 0 +bool1944 iszero 1E-1007 -> 0 +bool1945 iszero -1E-1007 -> 0 +bool1946 iszero 1E-1006 -> 0 +bool1947 iszero -1E-1006 -> 0 +bool1948 iszero 1E-1000 -> 0 +bool1949 iszero -1E-1000 -> 0 +bool1950 iszero 1E-999 -> 0 +bool1951 iszero -1E-999 -> 0 +bool1952 iszero 1E-998 -> 0 +bool1953 iszero -1E-998 -> 0 +bool1954 iszero 1E-100 -> 0 +bool1955 iszero -1E-100 -> 0 +bool1956 iszero 0.000001 -> 0 +bool1957 iszero -0.000001 -> 0 +bool1958 iszero 0.001 -> 0 +bool1959 iszero -0.001 -> 0 +bool1960 iszero 0.01 -> 0 +bool1961 iszero -0.01 -> 0 +bool1962 iszero 0.1 -> 0 +bool1963 iszero -0.1 -> 0 +bool1964 iszero 1 -> 0 +bool1965 iszero -1 -> 0 +bool1966 iszero 1E+1 -> 0 +bool1967 iszero -1E+1 -> 0 +bool1968 iszero 1E+2 -> 0 +bool1969 iszero -1E+2 -> 0 +bool1970 iszero 1E+3 -> 0 +bool1971 iszero -1E+3 -> 0 +bool1972 iszero 1E+6 -> 0 +bool1973 iszero -1E+6 -> 0 +bool1974 iszero 1E+100 -> 0 +bool1975 iszero -1E+100 -> 0 +bool1976 iszero 1E+990 -> 0 +bool1977 iszero -1E+990 -> 0 +bool1978 iszero 1E+991 -> 0 +bool1979 iszero -1E+991 -> 0 +bool1980 iszero 1E+992 -> 0 +bool1981 iszero -1E+992 -> 0 +bool1982 iszero 1E+998 -> 0 +bool1983 iszero -1E+998 -> 0 +bool1984 iszero 1E+999 -> 0 +bool1985 iszero -1E+999 -> 0 +bool1986 iszero 1E+1000 -> 0 +bool1987 iszero -1E+1000 -> 0 +bool1988 iszero 1E+2000 -> 0 +bool1989 iszero -1E+2000 -> 0 +bool1990 iszero 9E-2000 -> 0 +bool1991 iszero -9E-2000 -> 0 +bool1992 iszero 9E-1008 -> 0 +bool1993 iszero -9E-1008 -> 0 +bool1994 iszero 9E-1007 -> 0 +bool1995 iszero -9E-1007 -> 0 +bool1996 iszero 9E-1006 -> 0 +bool1997 iszero -9E-1006 -> 0 +bool1998 iszero 9E-1000 -> 0 +bool1999 iszero -9E-1000 -> 0 +bool2000 iszero 9E-999 -> 0 +bool2001 iszero -9E-999 -> 0 +bool2002 iszero 9E-998 -> 0 +bool2003 iszero -9E-998 -> 0 +bool2004 iszero 9E-100 -> 0 +bool2005 iszero -9E-100 -> 0 +bool2006 iszero 0.000009 -> 0 +bool2007 iszero -0.000009 -> 0 +bool2008 iszero 0.009 -> 0 +bool2009 iszero -0.009 -> 0 +bool2010 iszero 0.09 -> 0 +bool2011 iszero -0.09 -> 0 +bool2012 iszero 0.9 -> 0 +bool2013 iszero -0.9 -> 0 +bool2014 iszero 9 -> 0 +bool2015 iszero -9 -> 0 +bool2016 iszero 9E+1 -> 0 +bool2017 iszero -9E+1 -> 0 +bool2018 iszero 9E+2 -> 0 +bool2019 iszero -9E+2 -> 0 +bool2020 iszero 9E+3 -> 0 +bool2021 iszero -9E+3 -> 0 +bool2022 iszero 9E+6 -> 0 +bool2023 iszero -9E+6 -> 0 +bool2024 iszero 9E+100 -> 0 +bool2025 iszero -9E+100 -> 0 +bool2026 iszero 9E+990 -> 0 +bool2027 iszero -9E+990 -> 0 +bool2028 iszero 9E+991 -> 0 +bool2029 iszero -9E+991 -> 0 +bool2030 iszero 9E+992 -> 0 +bool2031 iszero -9E+992 -> 0 +bool2032 iszero 9E+998 -> 0 +bool2033 iszero -9E+998 -> 0 +bool2034 iszero 9E+999 -> 0 +bool2035 iszero -9E+999 -> 0 +bool2036 iszero 9E+1000 -> 0 +bool2037 iszero -9E+1000 -> 0 +bool2038 iszero 9E+2000 -> 0 +bool2039 iszero -9E+2000 -> 0 +bool2040 iszero 9.99999999E-2000 -> 0 +bool2041 iszero -9.99999999E-2000 -> 0 +bool2042 iszero 9.99999999E-1008 -> 0 +bool2043 iszero -9.99999999E-1008 -> 0 +bool2044 iszero 9.99999999E-1007 -> 0 +bool2045 iszero -9.99999999E-1007 -> 0 +bool2046 iszero 9.99999999E-1006 -> 0 +bool2047 iszero -9.99999999E-1006 -> 0 +bool2048 iszero 9.99999999E-1000 -> 0 +bool2049 iszero -9.99999999E-1000 -> 0 +bool2050 iszero 9.99999999E-999 -> 0 +bool2051 iszero -9.99999999E-999 -> 0 +bool2052 iszero 9.99999999E-998 -> 0 +bool2053 iszero -9.99999999E-998 -> 0 +bool2054 iszero 9.99999999E-100 -> 0 +bool2055 iszero -9.99999999E-100 -> 0 +bool2056 iszero 0.00000999999999 -> 0 +bool2057 iszero -0.00000999999999 -> 0 +bool2058 iszero 0.00999999999 -> 0 +bool2059 iszero -0.00999999999 -> 0 +bool2060 iszero 0.0999999999 -> 0 +bool2061 iszero -0.0999999999 -> 0 +bool2062 iszero 0.999999999 -> 0 +bool2063 iszero -0.999999999 -> 0 +bool2064 iszero 9.99999999 -> 0 +bool2065 iszero -9.99999999 -> 0 +bool2066 iszero 99.9999999 -> 0 +bool2067 iszero -99.9999999 -> 0 +bool2068 iszero 999.999999 -> 0 +bool2069 iszero -999.999999 -> 0 +bool2070 iszero 9999.99999 -> 0 +bool2071 iszero -9999.99999 -> 0 +bool2072 iszero 9999999.99 -> 0 +bool2073 iszero -9999999.99 -> 0 +bool2074 iszero 9.99999999E+100 -> 0 +bool2075 iszero -9.99999999E+100 -> 0 +bool2076 iszero 9.99999999E+990 -> 0 +bool2077 iszero -9.99999999E+990 -> 0 +bool2078 iszero 9.99999999E+991 -> 0 +bool2079 iszero -9.99999999E+991 -> 0 +bool2080 iszero 9.99999999E+992 -> 0 +bool2081 iszero -9.99999999E+992 -> 0 +bool2082 iszero 9.99999999E+998 -> 0 +bool2083 iszero -9.99999999E+998 -> 0 +bool2084 iszero 9.99999999E+999 -> 0 +bool2085 iszero -9.99999999E+999 -> 0 +bool2086 iszero 9.99999999E+1000 -> 0 +bool2087 iszero -9.99999999E+1000 -> 0 +bool2088 iszero 9.99999999E+2000 -> 0 +bool2089 iszero -9.99999999E+2000 -> 0 +bool2090 iszero Infinity -> 0 +bool2091 iszero -Infinity -> 0 +bool2092 iszero NaN -> 0 +bool2093 iszero -NaN -> 0 +bool2094 iszero NaN123 -> 0 +bool2095 iszero -NaN123 -> 0 +bool2096 iszero sNaN -> 0 +bool2097 iszero -sNaN -> 0 +bool2098 iszero sNaN123 -> 0 +bool2099 iszero -sNaN123 -> 0 + +------------------------------------------------------------------------ +-- The following tests (pwmx0 through pwmx440) are for the -- +-- three-argument version of power: -- +-- -- +-- pow(x, y, z) := x**y % z -- +-- -- +-- Note that the three-argument version of power is *not* part of -- +-- the IBM General Decimal Arithmetic specification. Questions -- +-- about it, or about these testcases, should go to one of the -- +-- Python decimal authors. -- +------------------------------------------------------------------------ + +extended: 1 +precision: 9 +rounding: down +maxExponent: 999 +minExponent: -999 + +-- Small numbers +-- Note that power(0, 0, m) is an error for any m +pwmx0 power 0 -0 1 -> NaN Invalid_operation +pwmx1 power 0 -0 2 -> NaN Invalid_operation +pwmx2 power 0 -0 3 -> NaN Invalid_operation +pwmx3 power 0 -0 4 -> NaN Invalid_operation +pwmx4 power 0 -0 -1 -> NaN Invalid_operation +pwmx5 power 0 -0 -2 -> NaN Invalid_operation +pwmx6 power 0 0 1 -> NaN Invalid_operation +pwmx7 power 0 0 2 -> NaN Invalid_operation +pwmx8 power 0 0 3 -> NaN Invalid_operation +pwmx9 power 0 0 4 -> NaN Invalid_operation +pwmx10 power 0 0 -1 -> NaN Invalid_operation +pwmx11 power 0 0 -2 -> NaN Invalid_operation +pwmx12 power 0 1 1 -> 0 +pwmx13 power 0 1 2 -> 0 +pwmx14 power 0 1 3 -> 0 +pwmx15 power 0 1 4 -> 0 +pwmx16 power 0 1 -1 -> 0 +pwmx17 power 0 1 -2 -> 0 +pwmx18 power 0 2 1 -> 0 +pwmx19 power 0 2 2 -> 0 +pwmx20 power 0 2 3 -> 0 +pwmx21 power 0 2 4 -> 0 +pwmx22 power 0 2 -1 -> 0 +pwmx23 power 0 2 -2 -> 0 +pwmx24 power 0 3 1 -> 0 +pwmx25 power 0 3 2 -> 0 +pwmx26 power 0 3 3 -> 0 +pwmx27 power 0 3 4 -> 0 +pwmx28 power 0 3 -1 -> 0 +pwmx29 power 0 3 -2 -> 0 +pwmx30 power 0 4 1 -> 0 +pwmx31 power 0 4 2 -> 0 +pwmx32 power 0 4 3 -> 0 +pwmx33 power 0 4 4 -> 0 +pwmx34 power 0 4 -1 -> 0 +pwmx35 power 0 4 -2 -> 0 +pwmx36 power 0 5 1 -> 0 +pwmx37 power 0 5 2 -> 0 +pwmx38 power 0 5 3 -> 0 +pwmx39 power 0 5 4 -> 0 +pwmx40 power 0 5 -1 -> 0 +pwmx41 power 0 5 -2 -> 0 +pwmx42 power 1 -0 1 -> 0 +pwmx43 power 1 -0 2 -> 1 +pwmx44 power 1 -0 3 -> 1 +pwmx45 power 1 -0 4 -> 1 +pwmx46 power 1 -0 -1 -> 0 +pwmx47 power 1 -0 -2 -> 1 +pwmx48 power 1 0 1 -> 0 +pwmx49 power 1 0 2 -> 1 +pwmx50 power 1 0 3 -> 1 +pwmx51 power 1 0 4 -> 1 +pwmx52 power 1 0 -1 -> 0 +pwmx53 power 1 0 -2 -> 1 +pwmx54 power 1 1 1 -> 0 +pwmx55 power 1 1 2 -> 1 +pwmx56 power 1 1 3 -> 1 +pwmx57 power 1 1 4 -> 1 +pwmx58 power 1 1 -1 -> 0 +pwmx59 power 1 1 -2 -> 1 +pwmx60 power 1 2 1 -> 0 +pwmx61 power 1 2 2 -> 1 +pwmx62 power 1 2 3 -> 1 +pwmx63 power 1 2 4 -> 1 +pwmx64 power 1 2 -1 -> 0 +pwmx65 power 1 2 -2 -> 1 +pwmx66 power 1 3 1 -> 0 +pwmx67 power 1 3 2 -> 1 +pwmx68 power 1 3 3 -> 1 +pwmx69 power 1 3 4 -> 1 +pwmx70 power 1 3 -1 -> 0 +pwmx71 power 1 3 -2 -> 1 +pwmx72 power 1 4 1 -> 0 +pwmx73 power 1 4 2 -> 1 +pwmx74 power 1 4 3 -> 1 +pwmx75 power 1 4 4 -> 1 +pwmx76 power 1 4 -1 -> 0 +pwmx77 power 1 4 -2 -> 1 +pwmx78 power 1 5 1 -> 0 +pwmx79 power 1 5 2 -> 1 +pwmx80 power 1 5 3 -> 1 +pwmx81 power 1 5 4 -> 1 +pwmx82 power 1 5 -1 -> 0 +pwmx83 power 1 5 -2 -> 1 +pwmx84 power 2 -0 1 -> 0 +pwmx85 power 2 -0 2 -> 1 +pwmx86 power 2 -0 3 -> 1 +pwmx87 power 2 -0 4 -> 1 +pwmx88 power 2 -0 -1 -> 0 +pwmx89 power 2 -0 -2 -> 1 +pwmx90 power 2 0 1 -> 0 +pwmx91 power 2 0 2 -> 1 +pwmx92 power 2 0 3 -> 1 +pwmx93 power 2 0 4 -> 1 +pwmx94 power 2 0 -1 -> 0 +pwmx95 power 2 0 -2 -> 1 +pwmx96 power 2 1 1 -> 0 +pwmx97 power 2 1 2 -> 0 +pwmx98 power 2 1 3 -> 2 +pwmx99 power 2 1 4 -> 2 +pwmx100 power 2 1 -1 -> 0 +pwmx101 power 2 1 -2 -> 0 +pwmx102 power 2 2 1 -> 0 +pwmx103 power 2 2 2 -> 0 +pwmx104 power 2 2 3 -> 1 +pwmx105 power 2 2 4 -> 0 +pwmx106 power 2 2 -1 -> 0 +pwmx107 power 2 2 -2 -> 0 +pwmx108 power 2 3 1 -> 0 +pwmx109 power 2 3 2 -> 0 +pwmx110 power 2 3 3 -> 2 +pwmx111 power 2 3 4 -> 0 +pwmx112 power 2 3 -1 -> 0 +pwmx113 power 2 3 -2 -> 0 +pwmx114 power 2 4 1 -> 0 +pwmx115 power 2 4 2 -> 0 +pwmx116 power 2 4 3 -> 1 +pwmx117 power 2 4 4 -> 0 +pwmx118 power 2 4 -1 -> 0 +pwmx119 power 2 4 -2 -> 0 +pwmx120 power 2 5 1 -> 0 +pwmx121 power 2 5 2 -> 0 +pwmx122 power 2 5 3 -> 2 +pwmx123 power 2 5 4 -> 0 +pwmx124 power 2 5 -1 -> 0 +pwmx125 power 2 5 -2 -> 0 +pwmx126 power 3 -0 1 -> 0 +pwmx127 power 3 -0 2 -> 1 +pwmx128 power 3 -0 3 -> 1 +pwmx129 power 3 -0 4 -> 1 +pwmx130 power 3 -0 -1 -> 0 +pwmx131 power 3 -0 -2 -> 1 +pwmx132 power 3 0 1 -> 0 +pwmx133 power 3 0 2 -> 1 +pwmx134 power 3 0 3 -> 1 +pwmx135 power 3 0 4 -> 1 +pwmx136 power 3 0 -1 -> 0 +pwmx137 power 3 0 -2 -> 1 +pwmx138 power 3 1 1 -> 0 +pwmx139 power 3 1 2 -> 1 +pwmx140 power 3 1 3 -> 0 +pwmx141 power 3 1 4 -> 3 +pwmx142 power 3 1 -1 -> 0 +pwmx143 power 3 1 -2 -> 1 +pwmx144 power 3 2 1 -> 0 +pwmx145 power 3 2 2 -> 1 +pwmx146 power 3 2 3 -> 0 +pwmx147 power 3 2 4 -> 1 +pwmx148 power 3 2 -1 -> 0 +pwmx149 power 3 2 -2 -> 1 +pwmx150 power 3 3 1 -> 0 +pwmx151 power 3 3 2 -> 1 +pwmx152 power 3 3 3 -> 0 +pwmx153 power 3 3 4 -> 3 +pwmx154 power 3 3 -1 -> 0 +pwmx155 power 3 3 -2 -> 1 +pwmx156 power 3 4 1 -> 0 +pwmx157 power 3 4 2 -> 1 +pwmx158 power 3 4 3 -> 0 +pwmx159 power 3 4 4 -> 1 +pwmx160 power 3 4 -1 -> 0 +pwmx161 power 3 4 -2 -> 1 +pwmx162 power 3 5 1 -> 0 +pwmx163 power 3 5 2 -> 1 +pwmx164 power 3 5 3 -> 0 +pwmx165 power 3 5 4 -> 3 +pwmx166 power 3 5 -1 -> 0 +pwmx167 power 3 5 -2 -> 1 +pwmx168 power -0 -0 1 -> NaN Invalid_operation +pwmx169 power -0 -0 2 -> NaN Invalid_operation +pwmx170 power -0 -0 3 -> NaN Invalid_operation +pwmx171 power -0 -0 4 -> NaN Invalid_operation +pwmx172 power -0 -0 -1 -> NaN Invalid_operation +pwmx173 power -0 -0 -2 -> NaN Invalid_operation +pwmx174 power -0 0 1 -> NaN Invalid_operation +pwmx175 power -0 0 2 -> NaN Invalid_operation +pwmx176 power -0 0 3 -> NaN Invalid_operation +pwmx177 power -0 0 4 -> NaN Invalid_operation +pwmx178 power -0 0 -1 -> NaN Invalid_operation +pwmx179 power -0 0 -2 -> NaN Invalid_operation +pwmx180 power -0 1 1 -> -0 +pwmx181 power -0 1 2 -> -0 +pwmx182 power -0 1 3 -> -0 +pwmx183 power -0 1 4 -> -0 +pwmx184 power -0 1 -1 -> -0 +pwmx185 power -0 1 -2 -> -0 +pwmx186 power -0 2 1 -> 0 +pwmx187 power -0 2 2 -> 0 +pwmx188 power -0 2 3 -> 0 +pwmx189 power -0 2 4 -> 0 +pwmx190 power -0 2 -1 -> 0 +pwmx191 power -0 2 -2 -> 0 +pwmx192 power -0 3 1 -> -0 +pwmx193 power -0 3 2 -> -0 +pwmx194 power -0 3 3 -> -0 +pwmx195 power -0 3 4 -> -0 +pwmx196 power -0 3 -1 -> -0 +pwmx197 power -0 3 -2 -> -0 +pwmx198 power -0 4 1 -> 0 +pwmx199 power -0 4 2 -> 0 +pwmx200 power -0 4 3 -> 0 +pwmx201 power -0 4 4 -> 0 +pwmx202 power -0 4 -1 -> 0 +pwmx203 power -0 4 -2 -> 0 +pwmx204 power -0 5 1 -> -0 +pwmx205 power -0 5 2 -> -0 +pwmx206 power -0 5 3 -> -0 +pwmx207 power -0 5 4 -> -0 +pwmx208 power -0 5 -1 -> -0 +pwmx209 power -0 5 -2 -> -0 +pwmx210 power -1 -0 1 -> 0 +pwmx211 power -1 -0 2 -> 1 +pwmx212 power -1 -0 3 -> 1 +pwmx213 power -1 -0 4 -> 1 +pwmx214 power -1 -0 -1 -> 0 +pwmx215 power -1 -0 -2 -> 1 +pwmx216 power -1 0 1 -> 0 +pwmx217 power -1 0 2 -> 1 +pwmx218 power -1 0 3 -> 1 +pwmx219 power -1 0 4 -> 1 +pwmx220 power -1 0 -1 -> 0 +pwmx221 power -1 0 -2 -> 1 +pwmx222 power -1 1 1 -> -0 +pwmx223 power -1 1 2 -> -1 +pwmx224 power -1 1 3 -> -1 +pwmx225 power -1 1 4 -> -1 +pwmx226 power -1 1 -1 -> -0 +pwmx227 power -1 1 -2 -> -1 +pwmx228 power -1 2 1 -> 0 +pwmx229 power -1 2 2 -> 1 +pwmx230 power -1 2 3 -> 1 +pwmx231 power -1 2 4 -> 1 +pwmx232 power -1 2 -1 -> 0 +pwmx233 power -1 2 -2 -> 1 +pwmx234 power -1 3 1 -> -0 +pwmx235 power -1 3 2 -> -1 +pwmx236 power -1 3 3 -> -1 +pwmx237 power -1 3 4 -> -1 +pwmx238 power -1 3 -1 -> -0 +pwmx239 power -1 3 -2 -> -1 +pwmx240 power -1 4 1 -> 0 +pwmx241 power -1 4 2 -> 1 +pwmx242 power -1 4 3 -> 1 +pwmx243 power -1 4 4 -> 1 +pwmx244 power -1 4 -1 -> 0 +pwmx245 power -1 4 -2 -> 1 +pwmx246 power -1 5 1 -> -0 +pwmx247 power -1 5 2 -> -1 +pwmx248 power -1 5 3 -> -1 +pwmx249 power -1 5 4 -> -1 +pwmx250 power -1 5 -1 -> -0 +pwmx251 power -1 5 -2 -> -1 + +-- Randomly chosen larger values +pwmx252 power 0 4 7 -> 0 +pwmx253 power -4 5 -9 -> -7 +pwmx254 power -5 4 -9 -> 4 +pwmx255 power -50 29 2 -> -0 +pwmx256 power -1 83 3 -> -1 +pwmx257 power -55 65 -75 -> -25 +pwmx258 power -613 151 -302 -> -9 +pwmx259 power 551 23 -35 -> 31 +pwmx260 power 51 142 942 -> 9 +pwmx261 power 6886 9204 -6091 -> 5034 +pwmx262 power 3057 5890 -3 -> 0 +pwmx263 power 56 4438 5365 -> 521 +pwmx264 power 96237 35669 -46669 -> 30717 +pwmx265 power 40011 34375 -57611 -> 625 +pwmx266 power 44317 38493 -12196 -> 11081 +pwmx267 power -282368 895633 -235870 -> -220928 +pwmx268 power 77328 852553 -405529 -> 129173 +pwmx269 power -929659 855713 650348 -> -90803 +pwmx270 power 907057 6574309 4924768 -> 3018257 +pwmx271 power -2887757 3198492 -5864352 -> 3440113 +pwmx272 power -247310 657371 -7415739 -> -1301840 +pwmx273 power -8399046 45334087 -22395020 -> -18515896 +pwmx274 power 79621397 4850236 1486555 -> 928706 +pwmx275 power 96012251 27971901 69609031 -> 50028729 +pwmx276 power -907335481 74127986 582330017 -> 51527187 +pwmx277 power -141192960 821063826 -260877928 -> 112318560 +pwmx278 power -501711702 934355994 82135143 -> 66586995 +pwmx279 power -9256358075 8900900138 -467222031 -> 95800246 +pwmx280 power -7031964291 1751257483 -935334498 -> -607626609 +pwmx281 power 8494314971 8740197252 107522491 -> 17373655 +pwmx282 power 88306216890 87477374166 -23498076 -> 15129528 +pwmx283 power -33939432478 7170196239 22133583 -> -11017036 +pwmx284 power 19466222767 30410710614 305752056 -> 191509537 +pwmx285 power -864942494008 370558899638 346688856 -> 56956768 +pwmx286 power -525406225603 345700226898 237163621 -> 56789534 +pwmx287 power 464612215955 312474621651 -329485700 -> 1853975 +pwmx288 power -1664283031244 3774474669855 919022867 -> -516034520 +pwmx289 power -3472438506913 7407327549995 -451206854 -> -74594761 +pwmx290 power -4223662152949 6891069279069 499843503 -> -80135290 +pwmx291 power -44022119276816 8168266170326 569679509 -> 375734475 +pwmx292 power -66195891207902 12532690555875 -243262129 -> -113186833 +pwmx293 power -69039911263164 52726605857673 360625196 -> -268662748 +pwmx294 power -299010116699208 885092589359231 -731310123 -> -104103765 +pwmx295 power -202495776299758 501159122943145 -686234870 -> -135511878 +pwmx296 power -595411478087676 836269270472481 -214614901 -> -183440819 +pwmx297 power -139555381056229 1324808520020507 -228944738 -> -218991473 +pwmx298 power 7846356250770543 1798045051036814 -101028985 -> 7805179 +pwmx299 power -4298015862709415 604966944844209 880212893 -> -87408671 +pwmx300 power -37384897538910893 76022206995659295 -930512842 -> -697757157 +pwmx301 power 82166659028005443 23375408251767704 817270700 -> 770697001 +pwmx302 power 97420301198165641 72213282983416924 947519716 -> 610711721 +pwmx303 power 913382043453243607 449681707248500262 211135545 -> 79544899 +pwmx304 power -313823613418052171 534579409610142937 -943062968 -> -446001379 +pwmx305 power -928106516894494093 760020177330116509 -50043994 -> -46010575 +pwmx306 power 4692146601679439796 4565354511806767804 -667339075 -> 480272081 +pwmx307 power 9722256633509177930 7276568791860505790 792675321 -> 182879752 +pwmx308 power 8689899484830064228 429082967129615261 -844555637 -> 270374557 + +-- All inputs must be integers +pwmx309 power 2.1 3 1 -> NaN Invalid_operation +pwmx310 power 0.4 1 5 -> NaN Invalid_operation +pwmx311 power 2 3.1 5 -> NaN Invalid_operation +pwmx312 power 13 -1.2 10 -> NaN Invalid_operation +pwmx313 power 2 3 5.1 -> NaN Invalid_operation + +-- Second argument must be nonnegative (-0 is okay) +pwmx314 power 2 -3 5 -> NaN Invalid_operation +pwmx315 power 7 -1 1 -> NaN Invalid_operation +pwmx316 power 0 -2 6 -> NaN Invalid_operation + +-- Third argument must be nonzero +pwmx317 power 13 1003 0 -> NaN Invalid_operation +pwmx318 power 1 0 0E+987 -> NaN Invalid_operation +pwmx319 power 0 2 -0 -> NaN Invalid_operation + +-- Integers are fine, no matter how they're expressed +pwmx320 power 13.0 117.00 1E+2 -> 33 +pwmx321 power -2E+3 1.1E+10 -12323 -> 4811 +pwmx322 power 20 0E-300 143 -> 1 +pwmx323 power -20 -0E+1005 1179 -> 1 +pwmx324 power 0E-1001 17 5.6E+4 -> 0 + +-- Modulus must not exceed precision +pwmx325 power 0 1 1234567890 -> NaN Invalid_operation +pwmx326 power 1 0 1000000000 -> NaN Invalid_operation +pwmx327 power -23 5 -1000000000 -> NaN Invalid_operation +pwmx328 power 41557 213 -999999999 -> 47650456 +pwmx329 power -2134 199 999999997 -> -946957912 + +-- Huge base shouldn't present any problems +pwmx330 power 1.23E+123456791 10123898 17291065 -> 5674045 + +-- Large exponent, may be slow +-- (if second argument is 1En then expect O(n) running time) +pwmx331 power 1000288896 9.87E+12347 93379908 -> 43224924 + +-- Triple NaN propagation (adapted from examples in fma.decTest) +pwmx400 power NaN2 NaN3 NaN5 -> NaN2 +pwmx401 power 1 NaN3 NaN5 -> NaN3 +pwmx402 power 1 1 NaN5 -> NaN5 +pwmx403 power sNaN1 sNaN2 sNaN3 -> NaN1 Invalid_operation +pwmx404 power 1 sNaN2 sNaN3 -> NaN2 Invalid_operation +pwmx405 power 1 1 sNaN3 -> NaN3 Invalid_operation +pwmx406 power sNaN1 sNaN2 sNaN3 -> NaN1 Invalid_operation +pwmx407 power NaN7 sNaN2 sNaN3 -> NaN2 Invalid_operation +pwmx408 power NaN7 NaN5 sNaN3 -> NaN3 Invalid_operation + +-- Infinities not allowed +pwmx410 power Inf 1 1 -> NaN Invalid_operation +pwmx411 power 1 Inf 1 -> NaN Invalid_operation +pwmx412 power 1 1 Inf -> NaN Invalid_operation +pwmx413 power -Inf 1 1 -> NaN Invalid_operation +pwmx414 power 1 -Inf 1 -> NaN Invalid_operation +pwmx415 power 1 1 -Inf -> NaN Invalid_operation + +-- Just for fun: 1729 is a Carmichael number +pwmx420 power 0 1728 1729 -> 0 +pwmx421 power 1 1728 1729 -> 1 +pwmx422 power 2 1728 1729 -> 1 +pwmx423 power 3 1728 1729 -> 1 +pwmx424 power 4 1728 1729 -> 1 +pwmx425 power 5 1728 1729 -> 1 +pwmx426 power 6 1728 1729 -> 1 +pwmx427 power 7 1728 1729 -> 742 +pwmx428 power 8 1728 1729 -> 1 +pwmx429 power 9 1728 1729 -> 1 +pwmx430 power 10 1728 1729 -> 1 +pwmx431 power 11 1728 1729 -> 1 +pwmx432 power 12 1728 1729 -> 1 +pwmx433 power 13 1728 1729 -> 533 +pwmx434 power 14 1728 1729 -> 742 +pwmx435 power 15 1728 1729 -> 1 +pwmx436 power 16 1728 1729 -> 1 +pwmx437 power 17 1728 1729 -> 1 +pwmx438 power 18 1728 1729 -> 1 +pwmx439 power 19 1728 1729 -> 456 +pwmx440 power 20 1728 1729 -> 1 Added: python/branches/release25-maint/Lib/test/decimaltestdata/fma.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/fma.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,3426 @@ +------------------------------------------------------------------------ +-- fma.decTest -- decimal fused multiply add -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +extended: 1 +precision: 9 +rounding: half_up +maxExponent: 384 +minexponent: -383 + +-- These tests comprese three parts: +-- 1. Sanity checks and other three-operand tests (especially those +-- where the fused operation makes a difference) +-- 2. Multiply tests (third operand is neutral zero [0E+emax]) +-- 3. Addition tests (first operand is 1) +-- The multiply and addition tests are extensive because FMA may have +-- its own dedicated multiplication or addition routine(s), and they +-- also inherently check the left-to-right properties. + +-- Sanity checks +fmax0001 fma 1 1 1 -> 2 +fmax0002 fma 1 1 2 -> 3 +fmax0003 fma 2 2 3 -> 7 +fmax0004 fma 9 9 9 -> 90 +fmax0005 fma -1 1 1 -> 0 +fmax0006 fma -1 1 2 -> 1 +fmax0007 fma -2 2 3 -> -1 +fmax0008 fma -9 9 9 -> -72 +fmax0011 fma 1 -1 1 -> 0 +fmax0012 fma 1 -1 2 -> 1 +fmax0013 fma 2 -2 3 -> -1 +fmax0014 fma 9 -9 9 -> -72 +fmax0015 fma 1 1 -1 -> 0 +fmax0016 fma 1 1 -2 -> -1 +fmax0017 fma 2 2 -3 -> 1 +fmax0018 fma 9 9 -9 -> 72 +fmax0019 fma 3 5 7 -> 22 +fmax0029 fma 3 -5 7 -> -8 + +-- non-integer exacts +fma0100 fma 25.2 63.6 -438 -> 1164.72 +fma0101 fma 0.301 0.380 334 -> 334.114380 +fma0102 fma 49.2 -4.8 23.3 -> -212.86 +fma0103 fma 4.22 0.079 -94.6 -> -94.26662 +fma0104 fma 903 0.797 0.887 -> 720.578 +fma0105 fma 6.13 -161 65.9 -> -921.03 +fma0106 fma 28.2 727 5.45 -> 20506.85 +fma0107 fma 4 605 688 -> 3108 +fma0108 fma 93.3 0.19 0.226 -> 17.953 +fma0109 fma 0.169 -341 5.61 -> -52.019 +fma0110 fma -72.2 30 -51.2 -> -2217.2 +fma0111 fma -0.409 13 20.4 -> 15.083 +fma0112 fma 317 77.0 19.0 -> 24428.0 +fma0113 fma 47 6.58 1.62 -> 310.88 +fma0114 fma 1.36 0.984 0.493 -> 1.83124 +fma0115 fma 72.7 274 1.56 -> 19921.36 +fma0116 fma 335 847 83 -> 283828 +fma0117 fma 666 0.247 25.4 -> 189.902 +fma0118 fma -3.87 3.06 78.0 -> 66.1578 +fma0119 fma 0.742 192 35.6 -> 178.064 +fma0120 fma -91.6 5.29 0.153 -> -484.411 + +-- cases where result is different from separate multiply + add; each +-- is preceded by the result of unfused multiply and add +-- [this is about 20% of all similar cases in general] +-- 888565290 1557.96930 -86087.7578 -> 1.38435735E+12 +fma0201 fma 888565290 1557.96930 -86087.7578 -> 1.38435736E+12 Inexact Rounded +-- -85519342.9 735155419 42010431 -> -6.28700084E+16 +fma0205 fma -85519342.9 735155419 42010431 -> -6.28700083E+16 Inexact Rounded +-- -98025.5 -294603.472 10414348.2 -> 2.88890669E+10 +fma0208 fma -98025.5 -294603.472 10414348.2 -> 2.88890670E+10 Inexact Rounded +-- 5967627.39 83526540.6 498494.810 -> 4.98455271E+14 +fma0211 fma 5967627.39 83526540.6 498494.810 -> 4.98455272E+14 Inexact Rounded +-- 3456.9433 874.39518 197866.615 -> 3220601.18 +fma0216 fma 3456.9433 874.39518 197866.615 -> 3220601.17 Inexact Rounded +-- 62769.8287 2096.98927 48.420317 -> 131627705 +fma0218 fma 62769.8287 2096.98927 48.420317 -> 131627706 Inexact Rounded +-- -68.81500 59961113.9 -8988862 -> -4.13521291E+9 +fma0219 fma -68.81500 59961113.9 -8988862 -> -4.13521292E+9 Inexact Rounded +-- 2126341.02 63491.5152 302427455 -> 1.35307040E+11 +fma0226 fma 2126341.02 63491.5152 302427455 -> 1.35307041E+11 Inexact Rounded + + +-- Infinite combinations +fmax0800 fma Inf Inf Inf -> Infinity +fmax0801 fma Inf Inf -Inf -> NaN Invalid_operation +fmax0802 fma Inf -Inf Inf -> NaN Invalid_operation +fmax0803 fma Inf -Inf -Inf -> -Infinity +fmax0804 fma -Inf Inf Inf -> NaN Invalid_operation +fmax0805 fma -Inf Inf -Inf -> -Infinity +fmax0806 fma -Inf -Inf Inf -> Infinity +fmax0807 fma -Inf -Inf -Inf -> NaN Invalid_operation +fmax0808 fma -Inf 0 1 -> NaN Invalid_operation +fmax0809 fma -Inf 0 NaN -> NaN Invalid_operation + +-- Triple NaN propagation +fmax0900 fma NaN2 NaN3 NaN5 -> NaN2 +fmax0901 fma 0 NaN3 NaN5 -> NaN3 +fmax0902 fma 0 0 NaN5 -> NaN5 +-- first sNaN wins (consider qNaN from earlier sNaN being +-- overridden by an sNaN in third operand) +fmax0903 fma sNaN1 sNaN2 sNaN3 -> NaN1 Invalid_operation +fmax0904 fma 0 sNaN2 sNaN3 -> NaN2 Invalid_operation +fmax0905 fma 0 0 sNaN3 -> NaN3 Invalid_operation +fmax0906 fma sNaN1 sNaN2 sNaN3 -> NaN1 Invalid_operation +fmax0907 fma NaN7 sNaN2 sNaN3 -> NaN2 Invalid_operation +fmax0908 fma NaN7 NaN5 sNaN3 -> NaN3 Invalid_operation + +-- MULTIPLICATION TESTS ------------------------------------------------ +-- sanity checks (as base, above) +fmax2000 fma 2 2 0E+999999 -> 4 +fmax2001 fma 2 3 0E+999999 -> 6 +fmax2002 fma 5 1 0E+999999 -> 5 +fmax2003 fma 5 2 0E+999999 -> 10 +fmax2004 fma 1.20 2 0E+999999 -> 2.40 +fmax2005 fma 1.20 0 0E+999999 -> 0.00 +fmax2006 fma 1.20 -2 0E+999999 -> -2.40 +fmax2007 fma -1.20 2 0E+999999 -> -2.40 +fmax2008 fma -1.20 0 0E+999999 -> 0.00 +fmax2009 fma -1.20 -2 0E+999999 -> 2.40 +fmax2010 fma 5.09 7.1 0E+999999 -> 36.139 +fmax2011 fma 2.5 4 0E+999999 -> 10.0 +fmax2012 fma 2.50 4 0E+999999 -> 10.00 +fmax2013 fma 1.23456789 1.00000000 0E+999999 -> 1.23456789 Rounded +fmax2014 fma 9.999999999 9.999999999 0E+999999 -> 100.000000 Inexact Rounded +fmax2015 fma 2.50 4 0E+999999 -> 10.00 +precision: 6 +fmax2016 fma 2.50 4 0E+999999 -> 10.00 +fmax2017 fma 9.999999 9.999999 0E+999999 -> 100.000 Inexact Rounded +fmax2018 fma 9.999999 -9.999999 0E+999999 -> -100.000 Inexact Rounded +fmax2019 fma -9.999999 9.999999 0E+999999 -> -100.000 Inexact Rounded +fmax2020 fma -9.999999 -9.999999 0E+999999 -> 100.000 Inexact Rounded + +-- 1999.12.21: next one is a edge case if intermediate longs are used +precision: 15 +fmax2059 fma 999999999999 9765625 0E+999999 -> 9.76562499999023E+18 Inexact Rounded +precision: 30 +fmax2160 fma 999999999999 9765625 0E+999999 -> 9765624999990234375 +precision: 9 +----- + +-- zeros, etc. +fmax2021 fma 0 0 0E+999999 -> 0 +fmax2022 fma 0 -0 0E+999999 -> 0 +fmax2023 fma -0 0 0E+999999 -> 0 +fmax2024 fma -0 -0 0E+999999 -> 0 +fmax2025 fma -0.0 -0.0 0E+999999 -> 0.00 +fmax2026 fma -0.0 -0.0 0E+999999 -> 0.00 +fmax2027 fma -0.0 -0.0 0E+999999 -> 0.00 +fmax2028 fma -0.0 -0.0 0E+999999 -> 0.00 +fmax2030 fma 5.00 1E-3 0E+999999 -> 0.00500 +fmax2031 fma 00.00 0.000 0E+999999 -> 0.00000 +fmax2032 fma 00.00 0E-3 0E+999999 -> 0.00000 -- rhs is 0 +fmax2033 fma 0E-3 00.00 0E+999999 -> 0.00000 -- lhs is 0 +fmax2034 fma -5.00 1E-3 0E+999999 -> -0.00500 +fmax2035 fma -00.00 0.000 0E+999999 -> 0.00000 +fmax2036 fma -00.00 0E-3 0E+999999 -> 0.00000 -- rhs is 0 +fmax2037 fma -0E-3 00.00 0E+999999 -> 0.00000 -- lhs is 0 +fmax2038 fma 5.00 -1E-3 0E+999999 -> -0.00500 +fmax2039 fma 00.00 -0.000 0E+999999 -> 0.00000 +fmax2040 fma 00.00 -0E-3 0E+999999 -> 0.00000 -- rhs is 0 +fmax2041 fma 0E-3 -00.00 0E+999999 -> 0.00000 -- lhs is 0 +fmax2042 fma -5.00 -1E-3 0E+999999 -> 0.00500 +fmax2043 fma -00.00 -0.000 0E+999999 -> 0.00000 +fmax2044 fma -00.00 -0E-3 0E+999999 -> 0.00000 -- rhs is 0 +fmax2045 fma -0E-3 -00.00 0E+999999 -> 0.00000 -- lhs is 0 + +-- examples from decarith multiply +fmax2050 fma 1.20 3 0E+999999 -> 3.60 +fmax2051 fma 7 3 0E+999999 -> 21 +fmax2052 fma 0.9 0.8 0E+999999 -> 0.72 +fmax2053 fma 0.9 -0 0E+999999 -> 0.0 +fmax2054 fma 654321 654321 0E+999999 -> 4.28135971E+11 Inexact Rounded + +fmax2060 fma 123.45 1e7 0E+999999 -> 1.2345E+9 +fmax2061 fma 123.45 1e8 0E+999999 -> 1.2345E+10 +fmax2062 fma 123.45 1e+9 0E+999999 -> 1.2345E+11 +fmax2063 fma 123.45 1e10 0E+999999 -> 1.2345E+12 +fmax2064 fma 123.45 1e11 0E+999999 -> 1.2345E+13 +fmax2065 fma 123.45 1e12 0E+999999 -> 1.2345E+14 +fmax2066 fma 123.45 1e13 0E+999999 -> 1.2345E+15 + + +-- test some intermediate lengths +precision: 9 +fmax2080 fma 0.1 123456789 0E+999999 -> 12345678.9 +fmax2081 fma 0.1 1234567891 0E+999999 -> 123456789 Inexact Rounded +fmax2082 fma 0.1 12345678912 0E+999999 -> 1.23456789E+9 Inexact Rounded +fmax2083 fma 0.1 12345678912345 0E+999999 -> 1.23456789E+12 Inexact Rounded +fmax2084 fma 0.1 123456789 0E+999999 -> 12345678.9 +precision: 8 +fmax2085 fma 0.1 12345678912 0E+999999 -> 1.2345679E+9 Inexact Rounded +fmax2086 fma 0.1 12345678912345 0E+999999 -> 1.2345679E+12 Inexact Rounded +precision: 7 +fmax2087 fma 0.1 12345678912 0E+999999 -> 1.234568E+9 Inexact Rounded +fmax2088 fma 0.1 12345678912345 0E+999999 -> 1.234568E+12 Inexact Rounded + +precision: 9 +fmax2090 fma 123456789 0.1 0E+999999 -> 12345678.9 +fmax2091 fma 1234567891 0.1 0E+999999 -> 123456789 Inexact Rounded +fmax2092 fma 12345678912 0.1 0E+999999 -> 1.23456789E+9 Inexact Rounded +fmax2093 fma 12345678912345 0.1 0E+999999 -> 1.23456789E+12 Inexact Rounded +fmax2094 fma 123456789 0.1 0E+999999 -> 12345678.9 +precision: 8 +fmax2095 fma 12345678912 0.1 0E+999999 -> 1.2345679E+9 Inexact Rounded +fmax2096 fma 12345678912345 0.1 0E+999999 -> 1.2345679E+12 Inexact Rounded +precision: 7 +fmax2097 fma 12345678912 0.1 0E+999999 -> 1.234568E+9 Inexact Rounded +fmax2098 fma 12345678912345 0.1 0E+999999 -> 1.234568E+12 Inexact Rounded + +-- test some more edge cases and carries +maxexponent: 9999 +minexponent: -9999 +precision: 33 +fmax2101 fma 9 9 0E+999999 -> 81 +fmax2102 fma 9 90 0E+999999 -> 810 +fmax2103 fma 9 900 0E+999999 -> 8100 +fmax2104 fma 9 9000 0E+999999 -> 81000 +fmax2105 fma 9 90000 0E+999999 -> 810000 +fmax2106 fma 9 900000 0E+999999 -> 8100000 +fmax2107 fma 9 9000000 0E+999999 -> 81000000 +fmax2108 fma 9 90000000 0E+999999 -> 810000000 +fmax2109 fma 9 900000000 0E+999999 -> 8100000000 +fmax2110 fma 9 9000000000 0E+999999 -> 81000000000 +fmax2111 fma 9 90000000000 0E+999999 -> 810000000000 +fmax2112 fma 9 900000000000 0E+999999 -> 8100000000000 +fmax2113 fma 9 9000000000000 0E+999999 -> 81000000000000 +fmax2114 fma 9 90000000000000 0E+999999 -> 810000000000000 +fmax2115 fma 9 900000000000000 0E+999999 -> 8100000000000000 +fmax2116 fma 9 9000000000000000 0E+999999 -> 81000000000000000 +fmax2117 fma 9 90000000000000000 0E+999999 -> 810000000000000000 +fmax2118 fma 9 900000000000000000 0E+999999 -> 8100000000000000000 +fmax2119 fma 9 9000000000000000000 0E+999999 -> 81000000000000000000 +fmax2120 fma 9 90000000000000000000 0E+999999 -> 810000000000000000000 +fmax2121 fma 9 900000000000000000000 0E+999999 -> 8100000000000000000000 +fmax2122 fma 9 9000000000000000000000 0E+999999 -> 81000000000000000000000 +fmax2123 fma 9 90000000000000000000000 0E+999999 -> 810000000000000000000000 +-- test some more edge cases without carries +fmax2131 fma 3 3 0E+999999 -> 9 +fmax2132 fma 3 30 0E+999999 -> 90 +fmax2133 fma 3 300 0E+999999 -> 900 +fmax2134 fma 3 3000 0E+999999 -> 9000 +fmax2135 fma 3 30000 0E+999999 -> 90000 +fmax2136 fma 3 300000 0E+999999 -> 900000 +fmax2137 fma 3 3000000 0E+999999 -> 9000000 +fmax2138 fma 3 30000000 0E+999999 -> 90000000 +fmax2139 fma 3 300000000 0E+999999 -> 900000000 +fmax2140 fma 3 3000000000 0E+999999 -> 9000000000 +fmax2141 fma 3 30000000000 0E+999999 -> 90000000000 +fmax2142 fma 3 300000000000 0E+999999 -> 900000000000 +fmax2143 fma 3 3000000000000 0E+999999 -> 9000000000000 +fmax2144 fma 3 30000000000000 0E+999999 -> 90000000000000 +fmax2145 fma 3 300000000000000 0E+999999 -> 900000000000000 +fmax2146 fma 3 3000000000000000 0E+999999 -> 9000000000000000 +fmax2147 fma 3 30000000000000000 0E+999999 -> 90000000000000000 +fmax2148 fma 3 300000000000000000 0E+999999 -> 900000000000000000 +fmax2149 fma 3 3000000000000000000 0E+999999 -> 9000000000000000000 +fmax2150 fma 3 30000000000000000000 0E+999999 -> 90000000000000000000 +fmax2151 fma 3 300000000000000000000 0E+999999 -> 900000000000000000000 +fmax2152 fma 3 3000000000000000000000 0E+999999 -> 9000000000000000000000 +fmax2153 fma 3 30000000000000000000000 0E+999999 -> 90000000000000000000000 + +maxexponent: 999999 +minexponent: -999999 +precision: 9 +-- test some cases that are close to exponent overflow/underflow +fmax2170 fma 1 9e999999 0E+999999 -> 9E+999999 +fmax2171 fma 1 9.9e999999 0E+999999 -> 9.9E+999999 +fmax2172 fma 1 9.99e999999 0E+999999 -> 9.99E+999999 +fmax2173 fma 9e999999 1 0E+999999 -> 9E+999999 +fmax2174 fma 9.9e999999 1 0E+999999 -> 9.9E+999999 +fmax2176 fma 9.99e999999 1 0E+999999 -> 9.99E+999999 +fmax2177 fma 1 9.99999e999999 0E+999999 -> 9.99999E+999999 +fmax2178 fma 9.99999e999999 1 0E+999999 -> 9.99999E+999999 + +fmax2180 fma 0.1 9e-999998 0E+999999 -> 9E-999999 +fmax2181 fma 0.1 99e-999998 0E+999999 -> 9.9E-999998 +fmax2182 fma 0.1 999e-999998 0E+999999 -> 9.99E-999997 + +fmax2183 fma 0.1 9e-999998 0E+999999 -> 9E-999999 +fmax2184 fma 0.1 99e-999998 0E+999999 -> 9.9E-999998 +fmax2185 fma 0.1 999e-999998 0E+999999 -> 9.99E-999997 +fmax2186 fma 0.1 999e-999997 0E+999999 -> 9.99E-999996 +fmax2187 fma 0.1 9999e-999997 0E+999999 -> 9.999E-999995 +fmax2188 fma 0.1 99999e-999997 0E+999999 -> 9.9999E-999994 + +fmax2190 fma 1 9e-999998 0E+999999 -> 9E-999998 +fmax2191 fma 1 99e-999998 0E+999999 -> 9.9E-999997 +fmax2192 fma 1 999e-999998 0E+999999 -> 9.99E-999996 +fmax2193 fma 9e-999998 1 0E+999999 -> 9E-999998 +fmax2194 fma 99e-999998 1 0E+999999 -> 9.9E-999997 +fmax2195 fma 999e-999998 1 0E+999999 -> 9.99E-999996 + +-- long operand triangle +precision: 33 +fmax2246 fma 30269.587755640502150977251770554 4.8046009735990873395936309640543 0E+999999 -> 145433.290801193369671916511992830 Inexact Rounded +precision: 32 +fmax2247 fma 30269.587755640502150977251770554 4.8046009735990873395936309640543 0E+999999 -> 145433.29080119336967191651199283 Inexact Rounded +precision: 31 +fmax2248 fma 30269.587755640502150977251770554 4.8046009735990873395936309640543 0E+999999 -> 145433.2908011933696719165119928 Inexact Rounded +precision: 30 +fmax2249 fma 30269.587755640502150977251770554 4.8046009735990873395936309640543 0E+999999 -> 145433.290801193369671916511993 Inexact Rounded +precision: 29 +fmax2250 fma 30269.587755640502150977251770554 4.8046009735990873395936309640543 0E+999999 -> 145433.29080119336967191651199 Inexact Rounded +precision: 28 +fmax2251 fma 30269.587755640502150977251770554 4.8046009735990873395936309640543 0E+999999 -> 145433.2908011933696719165120 Inexact Rounded +precision: 27 +fmax2252 fma 30269.587755640502150977251770554 4.8046009735990873395936309640543 0E+999999 -> 145433.290801193369671916512 Inexact Rounded +precision: 26 +fmax2253 fma 30269.587755640502150977251770554 4.8046009735990873395936309640543 0E+999999 -> 145433.29080119336967191651 Inexact Rounded +precision: 25 +fmax2254 fma 30269.587755640502150977251770554 4.8046009735990873395936309640543 0E+999999 -> 145433.2908011933696719165 Inexact Rounded +precision: 24 +fmax2255 fma 30269.587755640502150977251770554 4.8046009735990873395936309640543 0E+999999 -> 145433.290801193369671917 Inexact Rounded +precision: 23 +fmax2256 fma 30269.587755640502150977251770554 4.8046009735990873395936309640543 0E+999999 -> 145433.29080119336967192 Inexact Rounded +precision: 22 +fmax2257 fma 30269.587755640502150977251770554 4.8046009735990873395936309640543 0E+999999 -> 145433.2908011933696719 Inexact Rounded +precision: 21 +fmax2258 fma 30269.587755640502150977251770554 4.8046009735990873395936309640543 0E+999999 -> 145433.290801193369672 Inexact Rounded +precision: 20 +fmax2259 fma 30269.587755640502150977251770554 4.8046009735990873395936309640543 0E+999999 -> 145433.29080119336967 Inexact Rounded +precision: 19 +fmax2260 fma 30269.587755640502150977251770554 4.8046009735990873395936309640543 0E+999999 -> 145433.2908011933697 Inexact Rounded +precision: 18 +fmax2261 fma 30269.587755640502150977251770554 4.8046009735990873395936309640543 0E+999999 -> 145433.290801193370 Inexact Rounded +precision: 17 +fmax2262 fma 30269.587755640502150977251770554 4.8046009735990873395936309640543 0E+999999 -> 145433.29080119337 Inexact Rounded +precision: 16 +fmax2263 fma 30269.587755640502150977251770554 4.8046009735990873395936309640543 0E+999999 -> 145433.2908011934 Inexact Rounded +precision: 15 +fmax2264 fma 30269.587755640502150977251770554 4.8046009735990873395936309640543 0E+999999 -> 145433.290801193 Inexact Rounded +precision: 14 +fmax2265 fma 30269.587755640502150977251770554 4.8046009735990873395936309640543 0E+999999 -> 145433.29080119 Inexact Rounded +precision: 13 +fmax2266 fma 30269.587755640502150977251770554 4.8046009735990873395936309640543 0E+999999 -> 145433.2908012 Inexact Rounded +precision: 12 +fmax2267 fma 30269.587755640502150977251770554 4.8046009735990873395936309640543 0E+999999 -> 145433.290801 Inexact Rounded +precision: 11 +fmax2268 fma 30269.587755640502150977251770554 4.8046009735990873395936309640543 0E+999999 -> 145433.29080 Inexact Rounded +precision: 10 +fmax2269 fma 30269.587755640502150977251770554 4.8046009735990873395936309640543 0E+999999 -> 145433.2908 Inexact Rounded +precision: 9 +fmax2270 fma 30269.587755640502150977251770554 4.8046009735990873395936309640543 0E+999999 -> 145433.291 Inexact Rounded +precision: 8 +fmax2271 fma 30269.587755640502150977251770554 4.8046009735990873395936309640543 0E+999999 -> 145433.29 Inexact Rounded +precision: 7 +fmax2272 fma 30269.587755640502150977251770554 4.8046009735990873395936309640543 0E+999999 -> 145433.3 Inexact Rounded +precision: 6 +fmax2273 fma 30269.587755640502150977251770554 4.8046009735990873395936309640543 0E+999999 -> 145433 Inexact Rounded +precision: 5 +fmax2274 fma 30269.587755640502150977251770554 4.8046009735990873395936309640543 0E+999999 -> 1.4543E+5 Inexact Rounded +precision: 4 +fmax2275 fma 30269.587755640502150977251770554 4.8046009735990873395936309640543 0E+999999 -> 1.454E+5 Inexact Rounded +precision: 3 +fmax2276 fma 30269.587755640502150977251770554 4.8046009735990873395936309640543 0E+999999 -> 1.45E+5 Inexact Rounded +precision: 2 +fmax2277 fma 30269.587755640502150977251770554 4.8046009735990873395936309640543 0E+999999 -> 1.5E+5 Inexact Rounded +precision: 1 +fmax2278 fma 30269.587755640502150977251770554 4.8046009735990873395936309640543 0E+999999 -> 1E+5 Inexact Rounded + +-- test some edge cases with exact rounding +maxexponent: 9999 +minexponent: -9999 +precision: 9 +fmax2301 fma 9 9 0E+999999 -> 81 +fmax2302 fma 9 90 0E+999999 -> 810 +fmax2303 fma 9 900 0E+999999 -> 8100 +fmax2304 fma 9 9000 0E+999999 -> 81000 +fmax2305 fma 9 90000 0E+999999 -> 810000 +fmax2306 fma 9 900000 0E+999999 -> 8100000 +fmax2307 fma 9 9000000 0E+999999 -> 81000000 +fmax2308 fma 9 90000000 0E+999999 -> 810000000 +fmax2309 fma 9 900000000 0E+999999 -> 8.10000000E+9 Rounded +fmax2310 fma 9 9000000000 0E+999999 -> 8.10000000E+10 Rounded +fmax2311 fma 9 90000000000 0E+999999 -> 8.10000000E+11 Rounded +fmax2312 fma 9 900000000000 0E+999999 -> 8.10000000E+12 Rounded +fmax2313 fma 9 9000000000000 0E+999999 -> 8.10000000E+13 Rounded +fmax2314 fma 9 90000000000000 0E+999999 -> 8.10000000E+14 Rounded +fmax2315 fma 9 900000000000000 0E+999999 -> 8.10000000E+15 Rounded +fmax2316 fma 9 9000000000000000 0E+999999 -> 8.10000000E+16 Rounded +fmax2317 fma 9 90000000000000000 0E+999999 -> 8.10000000E+17 Rounded +fmax2318 fma 9 900000000000000000 0E+999999 -> 8.10000000E+18 Rounded +fmax2319 fma 9 9000000000000000000 0E+999999 -> 8.10000000E+19 Rounded +fmax2320 fma 9 90000000000000000000 0E+999999 -> 8.10000000E+20 Rounded +fmax2321 fma 9 900000000000000000000 0E+999999 -> 8.10000000E+21 Rounded +fmax2322 fma 9 9000000000000000000000 0E+999999 -> 8.10000000E+22 Rounded +fmax2323 fma 9 90000000000000000000000 0E+999999 -> 8.10000000E+23 Rounded + +-- fastpath breakers +precision: 29 +fmax2330 fma 1.491824697641270317824852952837224 1.105170918075647624811707826490246514675628614562883537345747603 0E+999999 -> 1.6487212707001281468486507878 Inexact Rounded +precision: 55 +fmax2331 fma 0.8958341352965282506768545828765117803873717284891040428 0.8958341352965282506768545828765117803873717284891040428 0E+999999 -> 0.8025187979624784829842553829934069955890983696752228299 Inexact Rounded + + +-- tryzeros cases +precision: 7 +rounding: half_up +maxExponent: 92 +minexponent: -92 +fmax2504 fma 0E-60 1000E-60 0E+999999 -> 0E-98 Clamped +fmax2505 fma 100E+60 0E+60 0E+999999 -> 0E+92 Clamped + +-- mixed with zeros +maxexponent: 999999 +minexponent: -999999 +precision: 9 +fmax2541 fma 0 -1 0E+999999 -> 0 +fmax2542 fma -0 -1 0E+999999 -> 0 +fmax2543 fma 0 1 0E+999999 -> 0 +fmax2544 fma -0 1 0E+999999 -> 0 +fmax2545 fma -1 0 0E+999999 -> 0 +fmax2546 fma -1 -0 0E+999999 -> 0 +fmax2547 fma 1 0 0E+999999 -> 0 +fmax2548 fma 1 -0 0E+999999 -> 0 + +fmax2551 fma 0.0 -1 0E+999999 -> 0.0 +fmax2552 fma -0.0 -1 0E+999999 -> 0.0 +fmax2553 fma 0.0 1 0E+999999 -> 0.0 +fmax2554 fma -0.0 1 0E+999999 -> 0.0 +fmax2555 fma -1.0 0 0E+999999 -> 0.0 +fmax2556 fma -1.0 -0 0E+999999 -> 0.0 +fmax2557 fma 1.0 0 0E+999999 -> 0.0 +fmax2558 fma 1.0 -0 0E+999999 -> 0.0 + +fmax2561 fma 0 -1.0 0E+999999 -> 0.0 +fmax2562 fma -0 -1.0 0E+999999 -> 0.0 +fmax2563 fma 0 1.0 0E+999999 -> 0.0 +fmax2564 fma -0 1.0 0E+999999 -> 0.0 +fmax2565 fma -1 0.0 0E+999999 -> 0.0 +fmax2566 fma -1 -0.0 0E+999999 -> 0.0 +fmax2567 fma 1 0.0 0E+999999 -> 0.0 +fmax2568 fma 1 -0.0 0E+999999 -> 0.0 + +fmax2571 fma 0.0 -1.0 0E+999999 -> 0.00 +fmax2572 fma -0.0 -1.0 0E+999999 -> 0.00 +fmax2573 fma 0.0 1.0 0E+999999 -> 0.00 +fmax2574 fma -0.0 1.0 0E+999999 -> 0.00 +fmax2575 fma -1.0 0.0 0E+999999 -> 0.00 +fmax2576 fma -1.0 -0.0 0E+999999 -> 0.00 +fmax2577 fma 1.0 0.0 0E+999999 -> 0.00 +fmax2578 fma 1.0 -0.0 0E+999999 -> 0.00 + + +-- Specials +fmax2580 fma Inf -Inf 0E+999999 -> -Infinity +fmax2581 fma Inf -1000 0E+999999 -> -Infinity +fmax2582 fma Inf -1 0E+999999 -> -Infinity +fmax2583 fma Inf -0 0E+999999 -> NaN Invalid_operation +fmax2584 fma Inf 0 0E+999999 -> NaN Invalid_operation +fmax2585 fma Inf 1 0E+999999 -> Infinity +fmax2586 fma Inf 1000 0E+999999 -> Infinity +fmax2587 fma Inf Inf 0E+999999 -> Infinity +fmax2588 fma -1000 Inf 0E+999999 -> -Infinity +fmax2589 fma -Inf Inf 0E+999999 -> -Infinity +fmax2590 fma -1 Inf 0E+999999 -> -Infinity +fmax2591 fma -0 Inf 0E+999999 -> NaN Invalid_operation +fmax2592 fma 0 Inf 0E+999999 -> NaN Invalid_operation +fmax2593 fma 1 Inf 0E+999999 -> Infinity +fmax2594 fma 1000 Inf 0E+999999 -> Infinity +fmax2595 fma Inf Inf 0E+999999 -> Infinity + +fmax2600 fma -Inf -Inf 0E+999999 -> Infinity +fmax2601 fma -Inf -1000 0E+999999 -> Infinity +fmax2602 fma -Inf -1 0E+999999 -> Infinity +fmax2603 fma -Inf -0 0E+999999 -> NaN Invalid_operation +fmax2604 fma -Inf 0 0E+999999 -> NaN Invalid_operation +fmax2605 fma -Inf 1 0E+999999 -> -Infinity +fmax2606 fma -Inf 1000 0E+999999 -> -Infinity +fmax2607 fma -Inf Inf 0E+999999 -> -Infinity +fmax2608 fma -1000 Inf 0E+999999 -> -Infinity +fmax2609 fma -Inf -Inf 0E+999999 -> Infinity +fmax2610 fma -1 -Inf 0E+999999 -> Infinity +fmax2611 fma -0 -Inf 0E+999999 -> NaN Invalid_operation +fmax2612 fma 0 -Inf 0E+999999 -> NaN Invalid_operation +fmax2613 fma 1 -Inf 0E+999999 -> -Infinity +fmax2614 fma 1000 -Inf 0E+999999 -> -Infinity +fmax2615 fma Inf -Inf 0E+999999 -> -Infinity + +fmax2621 fma NaN -Inf 0E+999999 -> NaN +fmax2622 fma NaN -1000 0E+999999 -> NaN +fmax2623 fma NaN -1 0E+999999 -> NaN +fmax2624 fma NaN -0 0E+999999 -> NaN +fmax2625 fma NaN 0 0E+999999 -> NaN +fmax2626 fma NaN 1 0E+999999 -> NaN +fmax2627 fma NaN 1000 0E+999999 -> NaN +fmax2628 fma NaN Inf 0E+999999 -> NaN +fmax2629 fma NaN NaN 0E+999999 -> NaN +fmax2630 fma -Inf NaN 0E+999999 -> NaN +fmax2631 fma -1000 NaN 0E+999999 -> NaN +fmax2632 fma -1 NaN 0E+999999 -> NaN +fmax2633 fma -0 NaN 0E+999999 -> NaN +fmax2634 fma 0 NaN 0E+999999 -> NaN +fmax2635 fma 1 NaN 0E+999999 -> NaN +fmax2636 fma 1000 NaN 0E+999999 -> NaN +fmax2637 fma Inf NaN 0E+999999 -> NaN + +fmax2641 fma sNaN -Inf 0E+999999 -> NaN Invalid_operation +fmax2642 fma sNaN -1000 0E+999999 -> NaN Invalid_operation +fmax2643 fma sNaN -1 0E+999999 -> NaN Invalid_operation +fmax2644 fma sNaN -0 0E+999999 -> NaN Invalid_operation +fmax2645 fma sNaN 0 0E+999999 -> NaN Invalid_operation +fmax2646 fma sNaN 1 0E+999999 -> NaN Invalid_operation +fmax2647 fma sNaN 1000 0E+999999 -> NaN Invalid_operation +fmax2648 fma sNaN NaN 0E+999999 -> NaN Invalid_operation +fmax2649 fma sNaN sNaN 0E+999999 -> NaN Invalid_operation +fmax2650 fma NaN sNaN 0E+999999 -> NaN Invalid_operation +fmax2651 fma -Inf sNaN 0E+999999 -> NaN Invalid_operation +fmax2652 fma -1000 sNaN 0E+999999 -> NaN Invalid_operation +fmax2653 fma -1 sNaN 0E+999999 -> NaN Invalid_operation +fmax2654 fma -0 sNaN 0E+999999 -> NaN Invalid_operation +fmax2655 fma 0 sNaN 0E+999999 -> NaN Invalid_operation +fmax2656 fma 1 sNaN 0E+999999 -> NaN Invalid_operation +fmax2657 fma 1000 sNaN 0E+999999 -> NaN Invalid_operation +fmax2658 fma Inf sNaN 0E+999999 -> NaN Invalid_operation +fmax2659 fma NaN sNaN 0E+999999 -> NaN Invalid_operation + +-- propagating NaNs +fmax2661 fma NaN9 -Inf 0E+999999 -> NaN9 +fmax2662 fma NaN8 999 0E+999999 -> NaN8 +fmax2663 fma NaN71 Inf 0E+999999 -> NaN71 +fmax2664 fma NaN6 NaN5 0E+999999 -> NaN6 +fmax2665 fma -Inf NaN4 0E+999999 -> NaN4 +fmax2666 fma -999 NaN33 0E+999999 -> NaN33 +fmax2667 fma Inf NaN2 0E+999999 -> NaN2 + +fmax2671 fma sNaN99 -Inf 0E+999999 -> NaN99 Invalid_operation +fmax2672 fma sNaN98 -11 0E+999999 -> NaN98 Invalid_operation +fmax2673 fma sNaN97 NaN 0E+999999 -> NaN97 Invalid_operation +fmax2674 fma sNaN16 sNaN94 0E+999999 -> NaN16 Invalid_operation +fmax2675 fma NaN95 sNaN93 0E+999999 -> NaN93 Invalid_operation +fmax2676 fma -Inf sNaN92 0E+999999 -> NaN92 Invalid_operation +fmax2677 fma 088 sNaN91 0E+999999 -> NaN91 Invalid_operation +fmax2678 fma Inf sNaN90 0E+999999 -> NaN90 Invalid_operation +fmax2679 fma NaN sNaN89 0E+999999 -> NaN89 Invalid_operation + +fmax2681 fma -NaN9 -Inf 0E+999999 -> -NaN9 +fmax2682 fma -NaN8 999 0E+999999 -> -NaN8 +fmax2683 fma -NaN71 Inf 0E+999999 -> -NaN71 +fmax2684 fma -NaN6 -NaN5 0E+999999 -> -NaN6 +fmax2685 fma -Inf -NaN4 0E+999999 -> -NaN4 +fmax2686 fma -999 -NaN33 0E+999999 -> -NaN33 +fmax2687 fma Inf -NaN2 0E+999999 -> -NaN2 + +fmax2691 fma -sNaN99 -Inf 0E+999999 -> -NaN99 Invalid_operation +fmax2692 fma -sNaN98 -11 0E+999999 -> -NaN98 Invalid_operation +fmax2693 fma -sNaN97 NaN 0E+999999 -> -NaN97 Invalid_operation +fmax2694 fma -sNaN16 -sNaN94 0E+999999 -> -NaN16 Invalid_operation +fmax2695 fma -NaN95 -sNaN93 0E+999999 -> -NaN93 Invalid_operation +fmax2696 fma -Inf -sNaN92 0E+999999 -> -NaN92 Invalid_operation +fmax2697 fma 088 -sNaN91 0E+999999 -> -NaN91 Invalid_operation +fmax2698 fma Inf -sNaN90 0E+999999 -> -NaN90 Invalid_operation +fmax2699 fma -NaN -sNaN89 0E+999999 -> -NaN89 Invalid_operation + +fmax2701 fma -NaN -Inf 0E+999999 -> -NaN +fmax2702 fma -NaN 999 0E+999999 -> -NaN +fmax2703 fma -NaN Inf 0E+999999 -> -NaN +fmax2704 fma -NaN -NaN 0E+999999 -> -NaN +fmax2705 fma -Inf -NaN0 0E+999999 -> -NaN +fmax2706 fma -999 -NaN 0E+999999 -> -NaN +fmax2707 fma Inf -NaN 0E+999999 -> -NaN + +fmax2711 fma -sNaN -Inf 0E+999999 -> -NaN Invalid_operation +fmax2712 fma -sNaN -11 0E+999999 -> -NaN Invalid_operation +fmax2713 fma -sNaN00 NaN 0E+999999 -> -NaN Invalid_operation +fmax2714 fma -sNaN -sNaN 0E+999999 -> -NaN Invalid_operation +fmax2715 fma -NaN -sNaN 0E+999999 -> -NaN Invalid_operation +fmax2716 fma -Inf -sNaN 0E+999999 -> -NaN Invalid_operation +fmax2717 fma 088 -sNaN 0E+999999 -> -NaN Invalid_operation +fmax2718 fma Inf -sNaN 0E+999999 -> -NaN Invalid_operation +fmax2719 fma -NaN -sNaN 0E+999999 -> -NaN Invalid_operation + +-- overflow and underflow tests .. note subnormal results +maxexponent: 999999 +minexponent: -999999 +fmax2730 fma +1.23456789012345E-0 9E+999999 0E+999999 -> Infinity Inexact Overflow Rounded +fmax2731 fma 9E+999999 +1.23456789012345E-0 0E+999999 -> Infinity Inexact Overflow Rounded +fmax2732 fma +0.100 9E-999999 0E+999999 -> 9.00E-1000000 Subnormal +fmax2733 fma 9E-999999 +0.100 0E+999999 -> 9.00E-1000000 Subnormal +fmax2735 fma -1.23456789012345E-0 9E+999999 0E+999999 -> -Infinity Inexact Overflow Rounded +fmax2736 fma 9E+999999 -1.23456789012345E-0 0E+999999 -> -Infinity Inexact Overflow Rounded +fmax2737 fma -0.100 9E-999999 0E+999999 -> -9.00E-1000000 Subnormal +fmax2738 fma 9E-999999 -0.100 0E+999999 -> -9.00E-1000000 Subnormal + +-- signs +fmax2751 fma 1e+777777 1e+411111 0E+999999 -> Infinity Overflow Inexact Rounded +fmax2752 fma 1e+777777 -1e+411111 0E+999999 -> -Infinity Overflow Inexact Rounded +fmax2753 fma -1e+777777 1e+411111 0E+999999 -> -Infinity Overflow Inexact Rounded +fmax2754 fma -1e+777777 -1e+411111 0E+999999 -> Infinity Overflow Inexact Rounded +fmax2755 fma 1e-777777 1e-411111 0E+999999 -> 0E-1000007 Underflow Subnormal Inexact Rounded Clamped +fmax2756 fma 1e-777777 -1e-411111 0E+999999 -> -0E-1000007 Underflow Subnormal Inexact Rounded Clamped +fmax2757 fma -1e-777777 1e-411111 0E+999999 -> -0E-1000007 Underflow Subnormal Inexact Rounded Clamped +fmax2758 fma -1e-777777 -1e-411111 0E+999999 -> 0E-1000007 Underflow Subnormal Inexact Rounded Clamped + +-- 'subnormal' boundary (all hard underflow or overflow in base arithemtic) +precision: 9 +fmax2760 fma 1e-600000 1e-400001 0E+999999 -> 1E-1000001 Subnormal +fmax2761 fma 1e-600000 1e-400002 0E+999999 -> 1E-1000002 Subnormal +fmax2762 fma 1e-600000 1e-400003 0E+999999 -> 1E-1000003 Subnormal +fmax2763 fma 1e-600000 1e-400004 0E+999999 -> 1E-1000004 Subnormal +fmax2764 fma 1e-600000 1e-400005 0E+999999 -> 1E-1000005 Subnormal +fmax2765 fma 1e-600000 1e-400006 0E+999999 -> 1E-1000006 Subnormal +fmax2766 fma 1e-600000 1e-400007 0E+999999 -> 1E-1000007 Subnormal +fmax2767 fma 1e-600000 1e-400008 0E+999999 -> 0E-1000007 Underflow Subnormal Inexact Rounded Clamped +fmax2768 fma 1e-600000 1e-400009 0E+999999 -> 0E-1000007 Underflow Subnormal Inexact Rounded Clamped +fmax2769 fma 1e-600000 1e-400010 0E+999999 -> 0E-1000007 Underflow Subnormal Inexact Rounded Clamped +-- [no equivalent of 'subnormal' for overflow] +fmax2770 fma 1e+600000 1e+400001 0E+999999 -> Infinity Overflow Inexact Rounded +fmax2771 fma 1e+600000 1e+400002 0E+999999 -> Infinity Overflow Inexact Rounded +fmax2772 fma 1e+600000 1e+400003 0E+999999 -> Infinity Overflow Inexact Rounded +fmax2773 fma 1e+600000 1e+400004 0E+999999 -> Infinity Overflow Inexact Rounded +fmax2774 fma 1e+600000 1e+400005 0E+999999 -> Infinity Overflow Inexact Rounded +fmax2775 fma 1e+600000 1e+400006 0E+999999 -> Infinity Overflow Inexact Rounded +fmax2776 fma 1e+600000 1e+400007 0E+999999 -> Infinity Overflow Inexact Rounded +fmax2777 fma 1e+600000 1e+400008 0E+999999 -> Infinity Overflow Inexact Rounded +fmax2778 fma 1e+600000 1e+400009 0E+999999 -> Infinity Overflow Inexact Rounded +fmax2779 fma 1e+600000 1e+400010 0E+999999 -> Infinity Overflow Inexact Rounded + +-- 'subnormal' test edge condition at higher precisions +precision: 99 +fmax2780 fma 1e-600000 1e-400007 0E+999999 -> 1E-1000007 Subnormal +fmax2781 fma 1e-600000 1e-400008 0E+999999 -> 1E-1000008 Subnormal +fmax2782 fma 1e-600000 1e-400097 0E+999999 -> 1E-1000097 Subnormal +fmax2783 fma 1e-600000 1e-400098 0E+999999 -> 0E-1000097 Underflow Subnormal Inexact Rounded Clamped +precision: 999 +fmax2784 fma 1e-600000 1e-400997 0E+999999 -> 1E-1000997 Subnormal +fmax2785 fma 1e-600000 1e-400998 0E+999999 -> 0E-1000997 Underflow Subnormal Inexact Rounded Clamped + +-- test subnormals rounding +precision: 5 +maxExponent: 999 +minexponent: -999 +rounding: half_even + +fmax2801 fma 1.0000E-999 1 0E+999999 -> 1.0000E-999 +fmax2802 fma 1.000E-999 1e-1 0E+999999 -> 1.000E-1000 Subnormal +fmax2803 fma 1.00E-999 1e-2 0E+999999 -> 1.00E-1001 Subnormal +fmax2804 fma 1.0E-999 1e-3 0E+999999 -> 1.0E-1002 Subnormal +fmax2805 fma 1.0E-999 1e-4 0E+999999 -> 1E-1003 Subnormal Rounded +fmax2806 fma 1.3E-999 1e-4 0E+999999 -> 1E-1003 Underflow Subnormal Inexact Rounded +fmax2807 fma 1.5E-999 1e-4 0E+999999 -> 2E-1003 Underflow Subnormal Inexact Rounded +fmax2808 fma 1.7E-999 1e-4 0E+999999 -> 2E-1003 Underflow Subnormal Inexact Rounded +fmax2809 fma 2.3E-999 1e-4 0E+999999 -> 2E-1003 Underflow Subnormal Inexact Rounded +fmax2810 fma 2.5E-999 1e-4 0E+999999 -> 2E-1003 Underflow Subnormal Inexact Rounded +fmax2811 fma 2.7E-999 1e-4 0E+999999 -> 3E-1003 Underflow Subnormal Inexact Rounded +fmax2812 fma 1.49E-999 1e-4 0E+999999 -> 1E-1003 Underflow Subnormal Inexact Rounded +fmax2813 fma 1.50E-999 1e-4 0E+999999 -> 2E-1003 Underflow Subnormal Inexact Rounded +fmax2814 fma 1.51E-999 1e-4 0E+999999 -> 2E-1003 Underflow Subnormal Inexact Rounded +fmax2815 fma 2.49E-999 1e-4 0E+999999 -> 2E-1003 Underflow Subnormal Inexact Rounded +fmax2816 fma 2.50E-999 1e-4 0E+999999 -> 2E-1003 Underflow Subnormal Inexact Rounded +fmax2817 fma 2.51E-999 1e-4 0E+999999 -> 3E-1003 Underflow Subnormal Inexact Rounded + +fmax2818 fma 1E-999 1e-4 0E+999999 -> 1E-1003 Subnormal +fmax2819 fma 3E-999 1e-5 0E+999999 -> 0E-1003 Underflow Subnormal Inexact Rounded Clamped +fmax2820 fma 5E-999 1e-5 0E+999999 -> 0E-1003 Underflow Subnormal Inexact Rounded Clamped +fmax2821 fma 7E-999 1e-5 0E+999999 -> 1E-1003 Underflow Subnormal Inexact Rounded +fmax2822 fma 9E-999 1e-5 0E+999999 -> 1E-1003 Underflow Subnormal Inexact Rounded +fmax2823 fma 9.9E-999 1e-5 0E+999999 -> 1E-1003 Underflow Subnormal Inexact Rounded + +fmax2824 fma 1E-999 -1e-4 0E+999999 -> -1E-1003 Subnormal +fmax2825 fma 3E-999 -1e-5 0E+999999 -> -0E-1003 Underflow Subnormal Inexact Rounded Clamped +fmax2826 fma -5E-999 1e-5 0E+999999 -> -0E-1003 Underflow Subnormal Inexact Rounded Clamped +fmax2827 fma 7E-999 -1e-5 0E+999999 -> -1E-1003 Underflow Subnormal Inexact Rounded +fmax2828 fma -9E-999 1e-5 0E+999999 -> -1E-1003 Underflow Subnormal Inexact Rounded +fmax2829 fma 9.9E-999 -1e-5 0E+999999 -> -1E-1003 Underflow Subnormal Inexact Rounded +fmax2830 fma 3.0E-999 -1e-5 0E+999999 -> -0E-1003 Underflow Subnormal Inexact Rounded Clamped + +fmax2831 fma 1.0E-501 1e-501 0E+999999 -> 1.0E-1002 Subnormal +fmax2832 fma 2.0E-501 2e-501 0E+999999 -> 4.0E-1002 Subnormal +fmax2833 fma 4.0E-501 4e-501 0E+999999 -> 1.60E-1001 Subnormal +fmax2834 fma 10.0E-501 10e-501 0E+999999 -> 1.000E-1000 Subnormal +fmax2835 fma 30.0E-501 30e-501 0E+999999 -> 9.000E-1000 Subnormal +fmax2836 fma 40.0E-501 40e-501 0E+999999 -> 1.6000E-999 + +-- squares +fmax2840 fma 1E-502 1e-502 0E+999999 -> 0E-1003 Underflow Subnormal Inexact Rounded Clamped +fmax2841 fma 1E-501 1e-501 0E+999999 -> 1E-1002 Subnormal +fmax2842 fma 2E-501 2e-501 0E+999999 -> 4E-1002 Subnormal +fmax2843 fma 4E-501 4e-501 0E+999999 -> 1.6E-1001 Subnormal +fmax2844 fma 10E-501 10e-501 0E+999999 -> 1.00E-1000 Subnormal +fmax2845 fma 30E-501 30e-501 0E+999999 -> 9.00E-1000 Subnormal +fmax2846 fma 40E-501 40e-501 0E+999999 -> 1.600E-999 + +-- cubes +fmax2850 fma 1E-670 1e-335 0E+999999 -> 0E-1003 Underflow Subnormal Inexact Rounded Clamped +fmax2851 fma 1E-668 1e-334 0E+999999 -> 1E-1002 Subnormal +fmax2852 fma 4E-668 2e-334 0E+999999 -> 8E-1002 Subnormal +fmax2853 fma 9E-668 3e-334 0E+999999 -> 2.7E-1001 Subnormal +fmax2854 fma 16E-668 4e-334 0E+999999 -> 6.4E-1001 Subnormal +fmax2855 fma 25E-668 5e-334 0E+999999 -> 1.25E-1000 Subnormal +fmax2856 fma 10E-668 100e-334 0E+999999 -> 1.000E-999 + +-- test derived from result of 0.099 ** 999 at 15 digits with unlimited exponent +precision: 19 +fmax2860 fma 6636851557994578716E-520 6636851557994578716E-520 0E+999999 -> 4.40477986028551E-1003 Underflow Subnormal Inexact Rounded + +-- Long operand overflow may be a different path +precision: 3 +maxExponent: 999999 +minexponent: -999999 +fmax2870 fma 1 9.999E+999999 0E+999999 -> Infinity Inexact Overflow Rounded +fmax2871 fma 1 -9.999E+999999 0E+999999 -> -Infinity Inexact Overflow Rounded +fmax2872 fma 9.999E+999999 1 0E+999999 -> Infinity Inexact Overflow Rounded +fmax2873 fma -9.999E+999999 1 0E+999999 -> -Infinity Inexact Overflow Rounded + +-- check for double-rounded subnormals +precision: 5 +maxexponent: 79 +minexponent: -79 +fmax2881 fma 1.2347E-40 1.2347E-40 0E+999999 -> 1.524E-80 Inexact Rounded Subnormal Underflow +fmax2882 fma 1.234E-40 1.234E-40 0E+999999 -> 1.523E-80 Inexact Rounded Subnormal Underflow +fmax2883 fma 1.23E-40 1.23E-40 0E+999999 -> 1.513E-80 Inexact Rounded Subnormal Underflow +fmax2884 fma 1.2E-40 1.2E-40 0E+999999 -> 1.44E-80 Subnormal +fmax2885 fma 1.2E-40 1.2E-41 0E+999999 -> 1.44E-81 Subnormal +fmax2886 fma 1.2E-40 1.2E-42 0E+999999 -> 1.4E-82 Subnormal Inexact Rounded Underflow +fmax2887 fma 1.2E-40 1.3E-42 0E+999999 -> 1.6E-82 Subnormal Inexact Rounded Underflow +fmax2888 fma 1.3E-40 1.3E-42 0E+999999 -> 1.7E-82 Subnormal Inexact Rounded Underflow +fmax2889 fma 1.3E-40 1.3E-43 0E+999999 -> 2E-83 Subnormal Inexact Rounded Underflow +fmax2890 fma 1.3E-41 1.3E-43 0E+999999 -> 0E-83 Clamped Subnormal Inexact Rounded Underflow + +fmax2891 fma 1.2345E-39 1.234E-40 0E+999999 -> 1.5234E-79 Inexact Rounded +fmax2892 fma 1.23456E-39 1.234E-40 0E+999999 -> 1.5234E-79 Inexact Rounded +fmax2893 fma 1.2345E-40 1.234E-40 0E+999999 -> 1.523E-80 Inexact Rounded Subnormal Underflow +fmax2894 fma 1.23456E-40 1.234E-40 0E+999999 -> 1.523E-80 Inexact Rounded Subnormal Underflow +fmax2895 fma 1.2345E-41 1.234E-40 0E+999999 -> 1.52E-81 Inexact Rounded Subnormal Underflow +fmax2896 fma 1.23456E-41 1.234E-40 0E+999999 -> 1.52E-81 Inexact Rounded Subnormal Underflow + +-- Now explore the case where we get a normal result with Underflow +precision: 16 +rounding: half_up +maxExponent: 384 +minExponent: -383 + +fmax2900 fma 0.3000000000E-191 0.3000000000E-191 0E+999999 -> 9.00000000000000E-384 Subnormal Rounded +fmax2901 fma 0.3000000001E-191 0.3000000001E-191 0E+999999 -> 9.00000000600000E-384 Underflow Inexact Subnormal Rounded +fmax2902 fma 9.999999999999999E-383 0.0999999999999 0E+999999 -> 9.99999999999000E-384 Underflow Inexact Subnormal Rounded +fmax2903 fma 9.999999999999999E-383 0.09999999999999 0E+999999 -> 9.99999999999900E-384 Underflow Inexact Subnormal Rounded +fmax2904 fma 9.999999999999999E-383 0.099999999999999 0E+999999 -> 9.99999999999990E-384 Underflow Inexact Subnormal Rounded +fmax2905 fma 9.999999999999999E-383 0.0999999999999999 0E+999999 -> 9.99999999999999E-384 Underflow Inexact Subnormal Rounded +-- prove operands are exact +fmax2906 fma 9.999999999999999E-383 1 0E+999999 -> 9.999999999999999E-383 +fmax2907 fma 1 0.09999999999999999 0E+999999 -> 0.09999999999999999 +-- the next rounds to Nmin +fmax2908 fma 9.999999999999999E-383 0.09999999999999999 0E+999999 -> 1.000000000000000E-383 Underflow Inexact Subnormal Rounded +fmax2909 fma 9.999999999999999E-383 0.099999999999999999 0E+999999 -> 1.000000000000000E-383 Underflow Inexact Subnormal Rounded +fmax2910 fma 9.999999999999999E-383 0.0999999999999999999 0E+999999 -> 1.000000000000000E-383 Underflow Inexact Subnormal Rounded +fmax2911 fma 9.999999999999999E-383 0.09999999999999999999 0E+999999 -> 1.000000000000000E-383 Underflow Inexact Subnormal Rounded + +-- Examples from SQL proposal (Krishna Kulkarni) +precision: 34 +rounding: half_up +maxExponent: 6144 +minExponent: -6143 +fmax2921 fma 130E-2 120E-2 0E+999999 -> 1.5600 +fmax2922 fma 130E-2 12E-1 0E+999999 -> 1.560 +fmax2923 fma 130E-2 1E0 0E+999999 -> 1.30 + +-- Null tests +fmax2990 fma # 10 0E+999999 -> NaN Invalid_operation +fmax2991 fma 10 # 0E+999999 -> NaN Invalid_operation + +-- ADDITION TESTS ------------------------------------------------------ +precision: 9 +rounding: half_up +maxExponent: 384 +minexponent: -383 + +-- [first group are 'quick confidence check'] +fmax3001 fma 1 1 1 -> 2 +fmax3002 fma 1 2 3 -> 5 +fmax3003 fma 1 '5.75' '3.3' -> 9.05 +fmax3004 fma 1 '5' '-3' -> 2 +fmax3005 fma 1 '-5' '-3' -> -8 +fmax3006 fma 1 '-7' '2.5' -> -4.5 +fmax3007 fma 1 '0.7' '0.3' -> 1.0 +fmax3008 fma 1 '1.25' '1.25' -> 2.50 +fmax3009 fma 1 '1.23456789' '1.00000000' -> '2.23456789' +fmax3010 fma 1 '1.23456789' '1.00000011' -> '2.23456800' + +fmax3011 fma 1 '0.4444444444' '0.5555555555' -> '1.00000000' Inexact Rounded +fmax3012 fma 1 '0.4444444440' '0.5555555555' -> '1.00000000' Inexact Rounded +fmax3013 fma 1 '0.4444444444' '0.5555555550' -> '0.999999999' Inexact Rounded +fmax3014 fma 1 '0.44444444449' '0' -> '0.444444444' Inexact Rounded +fmax3015 fma 1 '0.444444444499' '0' -> '0.444444444' Inexact Rounded +fmax3016 fma 1 '0.4444444444999' '0' -> '0.444444444' Inexact Rounded +fmax3017 fma 1 '0.4444444445000' '0' -> '0.444444445' Inexact Rounded +fmax3018 fma 1 '0.4444444445001' '0' -> '0.444444445' Inexact Rounded +fmax3019 fma 1 '0.444444444501' '0' -> '0.444444445' Inexact Rounded +fmax3020 fma 1 '0.44444444451' '0' -> '0.444444445' Inexact Rounded + +fmax3021 fma 1 0 1 -> 1 +fmax3022 fma 1 1 1 -> 2 +fmax3023 fma 1 2 1 -> 3 +fmax3024 fma 1 3 1 -> 4 +fmax3025 fma 1 4 1 -> 5 +fmax3026 fma 1 5 1 -> 6 +fmax3027 fma 1 6 1 -> 7 +fmax3028 fma 1 7 1 -> 8 +fmax3029 fma 1 8 1 -> 9 +fmax3030 fma 1 9 1 -> 10 + +-- some carrying effects +fmax3031 fma 1 '0.9998' '0.0000' -> '0.9998' +fmax3032 fma 1 '0.9998' '0.0001' -> '0.9999' +fmax3033 fma 1 '0.9998' '0.0002' -> '1.0000' +fmax3034 fma 1 '0.9998' '0.0003' -> '1.0001' + +fmax3035 fma 1 '70' '10000e+9' -> '1.00000000E+13' Inexact Rounded +fmax3036 fma 1 '700' '10000e+9' -> '1.00000000E+13' Inexact Rounded +fmax3037 fma 1 '7000' '10000e+9' -> '1.00000000E+13' Inexact Rounded +fmax3038 fma 1 '70000' '10000e+9' -> '1.00000001E+13' Inexact Rounded +fmax3039 fma 1 '700000' '10000e+9' -> '1.00000007E+13' Rounded + +-- symmetry: +fmax3040 fma 1 '10000e+9' '70' -> '1.00000000E+13' Inexact Rounded +fmax3041 fma 1 '10000e+9' '700' -> '1.00000000E+13' Inexact Rounded +fmax3042 fma 1 '10000e+9' '7000' -> '1.00000000E+13' Inexact Rounded +fmax3044 fma 1 '10000e+9' '70000' -> '1.00000001E+13' Inexact Rounded +fmax3045 fma 1 '10000e+9' '700000' -> '1.00000007E+13' Rounded + +-- same, higher precision +precision: 15 +fmax3046 fma 1 '10000e+9' '7' -> '10000000000007' +fmax3047 fma 1 '10000e+9' '70' -> '10000000000070' +fmax3048 fma 1 '10000e+9' '700' -> '10000000000700' +fmax3049 fma 1 '10000e+9' '7000' -> '10000000007000' +fmax3050 fma 1 '10000e+9' '70000' -> '10000000070000' +fmax3051 fma 1 '10000e+9' '700000' -> '10000000700000' +fmax3052 fma 1 '10000e+9' '7000000' -> '10000007000000' + +-- examples from decarith +fmax3053 fma 1 '12' '7.00' -> '19.00' +fmax3054 fma 1 '1.3' '-1.07' -> '0.23' +fmax3055 fma 1 '1.3' '-1.30' -> '0.00' +fmax3056 fma 1 '1.3' '-2.07' -> '-0.77' +fmax3057 fma 1 '1E+2' '1E+4' -> '1.01E+4' + +-- zero preservation +precision: 6 +fmax3060 fma 1 '10000e+9' '70000' -> '1.00000E+13' Inexact Rounded +fmax3061 fma 1 1 '0.0001' -> '1.0001' +fmax3062 fma 1 1 '0.00001' -> '1.00001' +fmax3063 fma 1 1 '0.000001' -> '1.00000' Inexact Rounded +fmax3064 fma 1 1 '0.0000001' -> '1.00000' Inexact Rounded +fmax3065 fma 1 1 '0.00000001' -> '1.00000' Inexact Rounded + +-- some funny zeros [in case of bad signum] +fmax3070 fma 1 1 0 -> 1 +fmax3071 fma 1 1 0. -> 1 +fmax3072 fma 1 1 .0 -> 1.0 +fmax3073 fma 1 1 0.0 -> 1.0 +fmax3074 fma 1 1 0.00 -> 1.00 +fmax3075 fma 1 0 1 -> 1 +fmax3076 fma 1 0. 1 -> 1 +fmax3077 fma 1 .0 1 -> 1.0 +fmax3078 fma 1 0.0 1 -> 1.0 +fmax3079 fma 1 0.00 1 -> 1.00 + +precision: 9 + +-- some carries +fmax3080 fma 1 999999998 1 -> 999999999 +fmax3081 fma 1 999999999 1 -> 1.00000000E+9 Rounded +fmax3082 fma 1 99999999 1 -> 100000000 +fmax3083 fma 1 9999999 1 -> 10000000 +fmax3084 fma 1 999999 1 -> 1000000 +fmax3085 fma 1 99999 1 -> 100000 +fmax3086 fma 1 9999 1 -> 10000 +fmax3087 fma 1 999 1 -> 1000 +fmax3088 fma 1 99 1 -> 100 +fmax3089 fma 1 9 1 -> 10 + + +-- more LHS swaps +fmax3090 fma 1 '-56267E-10' 0 -> '-0.0000056267' +fmax3091 fma 1 '-56267E-6' 0 -> '-0.056267' +fmax3092 fma 1 '-56267E-5' 0 -> '-0.56267' +fmax3093 fma 1 '-56267E-4' 0 -> '-5.6267' +fmax3094 fma 1 '-56267E-3' 0 -> '-56.267' +fmax3095 fma 1 '-56267E-2' 0 -> '-562.67' +fmax3096 fma 1 '-56267E-1' 0 -> '-5626.7' +fmax3097 fma 1 '-56267E-0' 0 -> '-56267' +fmax3098 fma 1 '-5E-10' 0 -> '-5E-10' +fmax3099 fma 1 '-5E-7' 0 -> '-5E-7' +fmax3100 fma 1 '-5E-6' 0 -> '-0.000005' +fmax3101 fma 1 '-5E-5' 0 -> '-0.00005' +fmax3102 fma 1 '-5E-4' 0 -> '-0.0005' +fmax3103 fma 1 '-5E-1' 0 -> '-0.5' +fmax3104 fma 1 '-5E0' 0 -> '-5' +fmax3105 fma 1 '-5E1' 0 -> '-50' +fmax3106 fma 1 '-5E5' 0 -> '-500000' +fmax3107 fma 1 '-5E8' 0 -> '-500000000' +fmax3108 fma 1 '-5E9' 0 -> '-5.00000000E+9' Rounded +fmax3109 fma 1 '-5E10' 0 -> '-5.00000000E+10' Rounded +fmax3110 fma 1 '-5E11' 0 -> '-5.00000000E+11' Rounded +fmax3111 fma 1 '-5E100' 0 -> '-5.00000000E+100' Rounded + +-- more RHS swaps +fmax3113 fma 1 0 '-56267E-10' -> '-0.0000056267' +fmax3114 fma 1 0 '-56267E-6' -> '-0.056267' +fmax3116 fma 1 0 '-56267E-5' -> '-0.56267' +fmax3117 fma 1 0 '-56267E-4' -> '-5.6267' +fmax3119 fma 1 0 '-56267E-3' -> '-56.267' +fmax3120 fma 1 0 '-56267E-2' -> '-562.67' +fmax3121 fma 1 0 '-56267E-1' -> '-5626.7' +fmax3122 fma 1 0 '-56267E-0' -> '-56267' +fmax3123 fma 1 0 '-5E-10' -> '-5E-10' +fmax3124 fma 1 0 '-5E-7' -> '-5E-7' +fmax3125 fma 1 0 '-5E-6' -> '-0.000005' +fmax3126 fma 1 0 '-5E-5' -> '-0.00005' +fmax3127 fma 1 0 '-5E-4' -> '-0.0005' +fmax3128 fma 1 0 '-5E-1' -> '-0.5' +fmax3129 fma 1 0 '-5E0' -> '-5' +fmax3130 fma 1 0 '-5E1' -> '-50' +fmax3131 fma 1 0 '-5E5' -> '-500000' +fmax3132 fma 1 0 '-5E8' -> '-500000000' +fmax3133 fma 1 0 '-5E9' -> '-5.00000000E+9' Rounded +fmax3134 fma 1 0 '-5E10' -> '-5.00000000E+10' Rounded +fmax3135 fma 1 0 '-5E11' -> '-5.00000000E+11' Rounded +fmax3136 fma 1 0 '-5E100' -> '-5.00000000E+100' Rounded + +-- related +fmax3137 fma 1 1 '0E-12' -> '1.00000000' Rounded +fmax3138 fma 1 -1 '0E-12' -> '-1.00000000' Rounded +fmax3139 fma 1 '0E-12' 1 -> '1.00000000' Rounded +fmax3140 fma 1 '0E-12' -1 -> '-1.00000000' Rounded +fmax3141 fma 1 1E+4 0.0000 -> '10000.0000' +fmax3142 fma 1 1E+4 0.00000 -> '10000.0000' Rounded +fmax3143 fma 1 0.000 1E+5 -> '100000.000' +fmax3144 fma 1 0.0000 1E+5 -> '100000.000' Rounded + +-- [some of the next group are really constructor tests] +fmax3146 fma 1 '00.0' 0 -> '0.0' +fmax3147 fma 1 '0.00' 0 -> '0.00' +fmax3148 fma 1 0 '0.00' -> '0.00' +fmax3149 fma 1 0 '00.0' -> '0.0' +fmax3150 fma 1 '00.0' '0.00' -> '0.00' +fmax3151 fma 1 '0.00' '00.0' -> '0.00' +fmax3152 fma 1 '3' '.3' -> '3.3' +fmax3153 fma 1 '3.' '.3' -> '3.3' +fmax3154 fma 1 '3.0' '.3' -> '3.3' +fmax3155 fma 1 '3.00' '.3' -> '3.30' +fmax3156 fma 1 '3' '3' -> '6' +fmax3157 fma 1 '3' '+3' -> '6' +fmax3158 fma 1 '3' '-3' -> '0' +fmax3159 fma 1 '0.3' '-0.3' -> '0.0' +fmax3160 fma 1 '0.03' '-0.03' -> '0.00' + +-- try borderline precision, with carries, etc. +precision: 15 +fmax3161 fma 1 '1E+12' '-1' -> '999999999999' +fmax3162 fma 1 '1E+12' '1.11' -> '1000000000001.11' +fmax3163 fma 1 '1.11' '1E+12' -> '1000000000001.11' +fmax3164 fma 1 '-1' '1E+12' -> '999999999999' +fmax3165 fma 1 '7E+12' '-1' -> '6999999999999' +fmax3166 fma 1 '7E+12' '1.11' -> '7000000000001.11' +fmax3167 fma 1 '1.11' '7E+12' -> '7000000000001.11' +fmax3168 fma 1 '-1' '7E+12' -> '6999999999999' + +-- 123456789012345 123456789012345 1 23456789012345 +fmax3170 fma 1 '0.444444444444444' '0.555555555555563' -> '1.00000000000001' Inexact Rounded +fmax3171 fma 1 '0.444444444444444' '0.555555555555562' -> '1.00000000000001' Inexact Rounded +fmax3172 fma 1 '0.444444444444444' '0.555555555555561' -> '1.00000000000001' Inexact Rounded +fmax3173 fma 1 '0.444444444444444' '0.555555555555560' -> '1.00000000000000' Inexact Rounded +fmax3174 fma 1 '0.444444444444444' '0.555555555555559' -> '1.00000000000000' Inexact Rounded +fmax3175 fma 1 '0.444444444444444' '0.555555555555558' -> '1.00000000000000' Inexact Rounded +fmax3176 fma 1 '0.444444444444444' '0.555555555555557' -> '1.00000000000000' Inexact Rounded +fmax3177 fma 1 '0.444444444444444' '0.555555555555556' -> '1.00000000000000' Rounded +fmax3178 fma 1 '0.444444444444444' '0.555555555555555' -> '0.999999999999999' +fmax3179 fma 1 '0.444444444444444' '0.555555555555554' -> '0.999999999999998' +fmax3180 fma 1 '0.444444444444444' '0.555555555555553' -> '0.999999999999997' +fmax3181 fma 1 '0.444444444444444' '0.555555555555552' -> '0.999999999999996' +fmax3182 fma 1 '0.444444444444444' '0.555555555555551' -> '0.999999999999995' +fmax3183 fma 1 '0.444444444444444' '0.555555555555550' -> '0.999999999999994' + +-- and some more, including residue effects and different roundings +precision: 9 +rounding: half_up +fmax3200 fma 1 '123456789' 0 -> '123456789' +fmax3201 fma 1 '123456789' 0.000000001 -> '123456789' Inexact Rounded +fmax3202 fma 1 '123456789' 0.000001 -> '123456789' Inexact Rounded +fmax3203 fma 1 '123456789' 0.1 -> '123456789' Inexact Rounded +fmax3204 fma 1 '123456789' 0.4 -> '123456789' Inexact Rounded +fmax3205 fma 1 '123456789' 0.49 -> '123456789' Inexact Rounded +fmax3206 fma 1 '123456789' 0.499999 -> '123456789' Inexact Rounded +fmax3207 fma 1 '123456789' 0.499999999 -> '123456789' Inexact Rounded +fmax3208 fma 1 '123456789' 0.5 -> '123456790' Inexact Rounded +fmax3209 fma 1 '123456789' 0.500000001 -> '123456790' Inexact Rounded +fmax3210 fma 1 '123456789' 0.500001 -> '123456790' Inexact Rounded +fmax3211 fma 1 '123456789' 0.51 -> '123456790' Inexact Rounded +fmax3212 fma 1 '123456789' 0.6 -> '123456790' Inexact Rounded +fmax3213 fma 1 '123456789' 0.9 -> '123456790' Inexact Rounded +fmax3214 fma 1 '123456789' 0.99999 -> '123456790' Inexact Rounded +fmax3215 fma 1 '123456789' 0.999999999 -> '123456790' Inexact Rounded +fmax3216 fma 1 '123456789' 1 -> '123456790' +fmax3217 fma 1 '123456789' 1.000000001 -> '123456790' Inexact Rounded +fmax3218 fma 1 '123456789' 1.00001 -> '123456790' Inexact Rounded +fmax3219 fma 1 '123456789' 1.1 -> '123456790' Inexact Rounded + +rounding: half_even +fmax3220 fma 1 '123456789' 0 -> '123456789' +fmax3221 fma 1 '123456789' 0.000000001 -> '123456789' Inexact Rounded +fmax3222 fma 1 '123456789' 0.000001 -> '123456789' Inexact Rounded +fmax3223 fma 1 '123456789' 0.1 -> '123456789' Inexact Rounded +fmax3224 fma 1 '123456789' 0.4 -> '123456789' Inexact Rounded +fmax3225 fma 1 '123456789' 0.49 -> '123456789' Inexact Rounded +fmax3226 fma 1 '123456789' 0.499999 -> '123456789' Inexact Rounded +fmax3227 fma 1 '123456789' 0.499999999 -> '123456789' Inexact Rounded +fmax3228 fma 1 '123456789' 0.5 -> '123456790' Inexact Rounded +fmax3229 fma 1 '123456789' 0.500000001 -> '123456790' Inexact Rounded +fmax3230 fma 1 '123456789' 0.500001 -> '123456790' Inexact Rounded +fmax3231 fma 1 '123456789' 0.51 -> '123456790' Inexact Rounded +fmax3232 fma 1 '123456789' 0.6 -> '123456790' Inexact Rounded +fmax3233 fma 1 '123456789' 0.9 -> '123456790' Inexact Rounded +fmax3234 fma 1 '123456789' 0.99999 -> '123456790' Inexact Rounded +fmax3235 fma 1 '123456789' 0.999999999 -> '123456790' Inexact Rounded +fmax3236 fma 1 '123456789' 1 -> '123456790' +fmax3237 fma 1 '123456789' 1.00000001 -> '123456790' Inexact Rounded +fmax3238 fma 1 '123456789' 1.00001 -> '123456790' Inexact Rounded +fmax3239 fma 1 '123456789' 1.1 -> '123456790' Inexact Rounded +-- critical few with even bottom digit... +fmax3240 fma 1 '123456788' 0.499999999 -> '123456788' Inexact Rounded +fmax3241 fma 1 '123456788' 0.5 -> '123456788' Inexact Rounded +fmax3242 fma 1 '123456788' 0.500000001 -> '123456789' Inexact Rounded + +rounding: down +fmax3250 fma 1 '123456789' 0 -> '123456789' +fmax3251 fma 1 '123456789' 0.000000001 -> '123456789' Inexact Rounded +fmax3252 fma 1 '123456789' 0.000001 -> '123456789' Inexact Rounded +fmax3253 fma 1 '123456789' 0.1 -> '123456789' Inexact Rounded +fmax3254 fma 1 '123456789' 0.4 -> '123456789' Inexact Rounded +fmax3255 fma 1 '123456789' 0.49 -> '123456789' Inexact Rounded +fmax3256 fma 1 '123456789' 0.499999 -> '123456789' Inexact Rounded +fmax3257 fma 1 '123456789' 0.499999999 -> '123456789' Inexact Rounded +fmax3258 fma 1 '123456789' 0.5 -> '123456789' Inexact Rounded +fmax3259 fma 1 '123456789' 0.500000001 -> '123456789' Inexact Rounded +fmax3260 fma 1 '123456789' 0.500001 -> '123456789' Inexact Rounded +fmax3261 fma 1 '123456789' 0.51 -> '123456789' Inexact Rounded +fmax3262 fma 1 '123456789' 0.6 -> '123456789' Inexact Rounded +fmax3263 fma 1 '123456789' 0.9 -> '123456789' Inexact Rounded +fmax3264 fma 1 '123456789' 0.99999 -> '123456789' Inexact Rounded +fmax3265 fma 1 '123456789' 0.999999999 -> '123456789' Inexact Rounded +fmax3266 fma 1 '123456789' 1 -> '123456790' +fmax3267 fma 1 '123456789' 1.00000001 -> '123456790' Inexact Rounded +fmax3268 fma 1 '123456789' 1.00001 -> '123456790' Inexact Rounded +fmax3269 fma 1 '123456789' 1.1 -> '123456790' Inexact Rounded + +-- input preparation tests (operands should not be rounded) +precision: 3 +rounding: half_up + +fmax3270 fma 1 '12345678900000' 9999999999999 -> '2.23E+13' Inexact Rounded +fmax3271 fma 1 '9999999999999' 12345678900000 -> '2.23E+13' Inexact Rounded + +fmax3272 fma 1 '12E+3' '3444' -> '1.54E+4' Inexact Rounded +fmax3273 fma 1 '12E+3' '3446' -> '1.54E+4' Inexact Rounded +fmax3274 fma 1 '12E+3' '3449.9' -> '1.54E+4' Inexact Rounded +fmax3275 fma 1 '12E+3' '3450.0' -> '1.55E+4' Inexact Rounded +fmax3276 fma 1 '12E+3' '3450.1' -> '1.55E+4' Inexact Rounded +fmax3277 fma 1 '12E+3' '3454' -> '1.55E+4' Inexact Rounded +fmax3278 fma 1 '12E+3' '3456' -> '1.55E+4' Inexact Rounded + +fmax3281 fma 1 '3444' '12E+3' -> '1.54E+4' Inexact Rounded +fmax3282 fma 1 '3446' '12E+3' -> '1.54E+4' Inexact Rounded +fmax3283 fma 1 '3449.9' '12E+3' -> '1.54E+4' Inexact Rounded +fmax3284 fma 1 '3450.0' '12E+3' -> '1.55E+4' Inexact Rounded +fmax3285 fma 1 '3450.1' '12E+3' -> '1.55E+4' Inexact Rounded +fmax3286 fma 1 '3454' '12E+3' -> '1.55E+4' Inexact Rounded +fmax3287 fma 1 '3456' '12E+3' -> '1.55E+4' Inexact Rounded + +rounding: half_down +fmax3291 fma 1 '3444' '12E+3' -> '1.54E+4' Inexact Rounded +fmax3292 fma 1 '3446' '12E+3' -> '1.54E+4' Inexact Rounded +fmax3293 fma 1 '3449.9' '12E+3' -> '1.54E+4' Inexact Rounded +fmax3294 fma 1 '3450.0' '12E+3' -> '1.54E+4' Inexact Rounded +fmax3295 fma 1 '3450.1' '12E+3' -> '1.55E+4' Inexact Rounded +fmax3296 fma 1 '3454' '12E+3' -> '1.55E+4' Inexact Rounded +fmax3297 fma 1 '3456' '12E+3' -> '1.55E+4' Inexact Rounded + +-- 1 in last place tests +rounding: half_up +fmax3301 fma 1 -1 1 -> 0 +fmax3302 fma 1 0 1 -> 1 +fmax3303 fma 1 1 1 -> 2 +fmax3304 fma 1 12 1 -> 13 +fmax3305 fma 1 98 1 -> 99 +fmax3306 fma 1 99 1 -> 100 +fmax3307 fma 1 100 1 -> 101 +fmax3308 fma 1 101 1 -> 102 +fmax3309 fma 1 -1 -1 -> -2 +fmax3310 fma 1 0 -1 -> -1 +fmax3311 fma 1 1 -1 -> 0 +fmax3312 fma 1 12 -1 -> 11 +fmax3313 fma 1 98 -1 -> 97 +fmax3314 fma 1 99 -1 -> 98 +fmax3315 fma 1 100 -1 -> 99 +fmax3316 fma 1 101 -1 -> 100 + +fmax3321 fma 1 -0.01 0.01 -> 0.00 +fmax3322 fma 1 0.00 0.01 -> 0.01 +fmax3323 fma 1 0.01 0.01 -> 0.02 +fmax3324 fma 1 0.12 0.01 -> 0.13 +fmax3325 fma 1 0.98 0.01 -> 0.99 +fmax3326 fma 1 0.99 0.01 -> 1.00 +fmax3327 fma 1 1.00 0.01 -> 1.01 +fmax3328 fma 1 1.01 0.01 -> 1.02 +fmax3329 fma 1 -0.01 -0.01 -> -0.02 +fmax3330 fma 1 0.00 -0.01 -> -0.01 +fmax3331 fma 1 0.01 -0.01 -> 0.00 +fmax3332 fma 1 0.12 -0.01 -> 0.11 +fmax3333 fma 1 0.98 -0.01 -> 0.97 +fmax3334 fma 1 0.99 -0.01 -> 0.98 +fmax3335 fma 1 1.00 -0.01 -> 0.99 +fmax3336 fma 1 1.01 -0.01 -> 1.00 + +-- some more cases where fma 1 ing 0 affects the coefficient +precision: 9 +fmax3340 fma 1 1E+3 0 -> 1000 +fmax3341 fma 1 1E+8 0 -> 100000000 +fmax3342 fma 1 1E+9 0 -> 1.00000000E+9 Rounded +fmax3343 fma 1 1E+10 0 -> 1.00000000E+10 Rounded +-- which simply follow from these cases ... +fmax3344 fma 1 1E+3 1 -> 1001 +fmax3345 fma 1 1E+8 1 -> 100000001 +fmax3346 fma 1 1E+9 1 -> 1.00000000E+9 Inexact Rounded +fmax3347 fma 1 1E+10 1 -> 1.00000000E+10 Inexact Rounded +fmax3348 fma 1 1E+3 7 -> 1007 +fmax3349 fma 1 1E+8 7 -> 100000007 +fmax3350 fma 1 1E+9 7 -> 1.00000001E+9 Inexact Rounded +fmax3351 fma 1 1E+10 7 -> 1.00000000E+10 Inexact Rounded + +-- tryzeros cases +precision: 7 +rounding: half_up +maxExponent: 92 +minexponent: -92 +fmax3361 fma 1 0E+50 10000E+1 -> 1.0000E+5 +fmax3362 fma 1 10000E+1 0E-50 -> 100000.0 Rounded +fmax3363 fma 1 10000E+1 10000E-50 -> 100000.0 Rounded Inexact +fmax3364 fma 1 9.999999E+92 -9.999999E+92 -> 0E+86 + +-- a curiosity from JSR 13 testing +rounding: half_down +precision: 10 +fmax3370 fma 1 99999999 81512 -> 100081511 +precision: 6 +fmax3371 fma 1 99999999 81512 -> 1.00082E+8 Rounded Inexact +rounding: half_up +precision: 10 +fmax3372 fma 1 99999999 81512 -> 100081511 +precision: 6 +fmax3373 fma 1 99999999 81512 -> 1.00082E+8 Rounded Inexact +rounding: half_even +precision: 10 +fmax3374 fma 1 99999999 81512 -> 100081511 +precision: 6 +fmax3375 fma 1 99999999 81512 -> 1.00082E+8 Rounded Inexact + +-- ulp replacement tests +precision: 9 +maxexponent: 999999 +minexponent: -999999 +fmax3400 fma 1 1 77e-7 -> 1.0000077 +fmax3401 fma 1 1 77e-8 -> 1.00000077 +fmax3402 fma 1 1 77e-9 -> 1.00000008 Inexact Rounded +fmax3403 fma 1 1 77e-10 -> 1.00000001 Inexact Rounded +fmax3404 fma 1 1 77e-11 -> 1.00000000 Inexact Rounded +fmax3405 fma 1 1 77e-12 -> 1.00000000 Inexact Rounded +fmax3406 fma 1 1 77e-999 -> 1.00000000 Inexact Rounded +fmax3407 fma 1 1 77e-999999 -> 1.00000000 Inexact Rounded + +fmax3410 fma 1 10 77e-7 -> 10.0000077 +fmax3411 fma 1 10 77e-8 -> 10.0000008 Inexact Rounded +fmax3412 fma 1 10 77e-9 -> 10.0000001 Inexact Rounded +fmax3413 fma 1 10 77e-10 -> 10.0000000 Inexact Rounded +fmax3414 fma 1 10 77e-11 -> 10.0000000 Inexact Rounded +fmax3415 fma 1 10 77e-12 -> 10.0000000 Inexact Rounded +fmax3416 fma 1 10 77e-999 -> 10.0000000 Inexact Rounded +fmax3417 fma 1 10 77e-999999 -> 10.0000000 Inexact Rounded + +fmax3420 fma 1 77e-7 1 -> 1.0000077 +fmax3421 fma 1 77e-8 1 -> 1.00000077 +fmax3422 fma 1 77e-9 1 -> 1.00000008 Inexact Rounded +fmax3423 fma 1 77e-10 1 -> 1.00000001 Inexact Rounded +fmax3424 fma 1 77e-11 1 -> 1.00000000 Inexact Rounded +fmax3425 fma 1 77e-12 1 -> 1.00000000 Inexact Rounded +fmax3426 fma 1 77e-999 1 -> 1.00000000 Inexact Rounded +fmax3427 fma 1 77e-999999 1 -> 1.00000000 Inexact Rounded + +fmax3430 fma 1 77e-7 10 -> 10.0000077 +fmax3431 fma 1 77e-8 10 -> 10.0000008 Inexact Rounded +fmax3432 fma 1 77e-9 10 -> 10.0000001 Inexact Rounded +fmax3433 fma 1 77e-10 10 -> 10.0000000 Inexact Rounded +fmax3434 fma 1 77e-11 10 -> 10.0000000 Inexact Rounded +fmax3435 fma 1 77e-12 10 -> 10.0000000 Inexact Rounded +fmax3436 fma 1 77e-999 10 -> 10.0000000 Inexact Rounded +fmax3437 fma 1 77e-999999 10 -> 10.0000000 Inexact Rounded + +-- negative ulps +fmax3440 fma 1 1 -77e-7 -> 0.9999923 +fmax3441 fma 1 1 -77e-8 -> 0.99999923 +fmax3442 fma 1 1 -77e-9 -> 0.999999923 +fmax3443 fma 1 1 -77e-10 -> 0.999999992 Inexact Rounded +fmax3444 fma 1 1 -77e-11 -> 0.999999999 Inexact Rounded +fmax3445 fma 1 1 -77e-12 -> 1.00000000 Inexact Rounded +fmax3446 fma 1 1 -77e-999 -> 1.00000000 Inexact Rounded +fmax3447 fma 1 1 -77e-999999 -> 1.00000000 Inexact Rounded + +fmax3450 fma 1 10 -77e-7 -> 9.9999923 +fmax3451 fma 1 10 -77e-8 -> 9.99999923 +fmax3452 fma 1 10 -77e-9 -> 9.99999992 Inexact Rounded +fmax3453 fma 1 10 -77e-10 -> 9.99999999 Inexact Rounded +fmax3454 fma 1 10 -77e-11 -> 10.0000000 Inexact Rounded +fmax3455 fma 1 10 -77e-12 -> 10.0000000 Inexact Rounded +fmax3456 fma 1 10 -77e-999 -> 10.0000000 Inexact Rounded +fmax3457 fma 1 10 -77e-999999 -> 10.0000000 Inexact Rounded + +fmax3460 fma 1 -77e-7 1 -> 0.9999923 +fmax3461 fma 1 -77e-8 1 -> 0.99999923 +fmax3462 fma 1 -77e-9 1 -> 0.999999923 +fmax3463 fma 1 -77e-10 1 -> 0.999999992 Inexact Rounded +fmax3464 fma 1 -77e-11 1 -> 0.999999999 Inexact Rounded +fmax3465 fma 1 -77e-12 1 -> 1.00000000 Inexact Rounded +fmax3466 fma 1 -77e-999 1 -> 1.00000000 Inexact Rounded +fmax3467 fma 1 -77e-999999 1 -> 1.00000000 Inexact Rounded + +fmax3470 fma 1 -77e-7 10 -> 9.9999923 +fmax3471 fma 1 -77e-8 10 -> 9.99999923 +fmax3472 fma 1 -77e-9 10 -> 9.99999992 Inexact Rounded +fmax3473 fma 1 -77e-10 10 -> 9.99999999 Inexact Rounded +fmax3474 fma 1 -77e-11 10 -> 10.0000000 Inexact Rounded +fmax3475 fma 1 -77e-12 10 -> 10.0000000 Inexact Rounded +fmax3476 fma 1 -77e-999 10 -> 10.0000000 Inexact Rounded +fmax3477 fma 1 -77e-999999 10 -> 10.0000000 Inexact Rounded + +-- negative ulps +fmax3480 fma 1 -1 77e-7 -> -0.9999923 +fmax3481 fma 1 -1 77e-8 -> -0.99999923 +fmax3482 fma 1 -1 77e-9 -> -0.999999923 +fmax3483 fma 1 -1 77e-10 -> -0.999999992 Inexact Rounded +fmax3484 fma 1 -1 77e-11 -> -0.999999999 Inexact Rounded +fmax3485 fma 1 -1 77e-12 -> -1.00000000 Inexact Rounded +fmax3486 fma 1 -1 77e-999 -> -1.00000000 Inexact Rounded +fmax3487 fma 1 -1 77e-999999 -> -1.00000000 Inexact Rounded + +fmax3490 fma 1 -10 77e-7 -> -9.9999923 +fmax3491 fma 1 -10 77e-8 -> -9.99999923 +fmax3492 fma 1 -10 77e-9 -> -9.99999992 Inexact Rounded +fmax3493 fma 1 -10 77e-10 -> -9.99999999 Inexact Rounded +fmax3494 fma 1 -10 77e-11 -> -10.0000000 Inexact Rounded +fmax3495 fma 1 -10 77e-12 -> -10.0000000 Inexact Rounded +fmax3496 fma 1 -10 77e-999 -> -10.0000000 Inexact Rounded +fmax3497 fma 1 -10 77e-999999 -> -10.0000000 Inexact Rounded + +fmax3500 fma 1 77e-7 -1 -> -0.9999923 +fmax3501 fma 1 77e-8 -1 -> -0.99999923 +fmax3502 fma 1 77e-9 -1 -> -0.999999923 +fmax3503 fma 1 77e-10 -1 -> -0.999999992 Inexact Rounded +fmax3504 fma 1 77e-11 -1 -> -0.999999999 Inexact Rounded +fmax3505 fma 1 77e-12 -1 -> -1.00000000 Inexact Rounded +fmax3506 fma 1 77e-999 -1 -> -1.00000000 Inexact Rounded +fmax3507 fma 1 77e-999999 -1 -> -1.00000000 Inexact Rounded + +fmax3510 fma 1 77e-7 -10 -> -9.9999923 +fmax3511 fma 1 77e-8 -10 -> -9.99999923 +fmax3512 fma 1 77e-9 -10 -> -9.99999992 Inexact Rounded +fmax3513 fma 1 77e-10 -10 -> -9.99999999 Inexact Rounded +fmax3514 fma 1 77e-11 -10 -> -10.0000000 Inexact Rounded +fmax3515 fma 1 77e-12 -10 -> -10.0000000 Inexact Rounded +fmax3516 fma 1 77e-999 -10 -> -10.0000000 Inexact Rounded +fmax3517 fma 1 77e-999999 -10 -> -10.0000000 Inexact Rounded + + +-- long operands +maxexponent: 999 +minexponent: -999 +precision: 9 +fmax3521 fma 1 12345678000 0 -> 1.23456780E+10 Rounded +fmax3522 fma 1 0 12345678000 -> 1.23456780E+10 Rounded +fmax3523 fma 1 1234567800 0 -> 1.23456780E+9 Rounded +fmax3524 fma 1 0 1234567800 -> 1.23456780E+9 Rounded +fmax3525 fma 1 1234567890 0 -> 1.23456789E+9 Rounded +fmax3526 fma 1 0 1234567890 -> 1.23456789E+9 Rounded +fmax3527 fma 1 1234567891 0 -> 1.23456789E+9 Inexact Rounded +fmax3528 fma 1 0 1234567891 -> 1.23456789E+9 Inexact Rounded +fmax3529 fma 1 12345678901 0 -> 1.23456789E+10 Inexact Rounded +fmax3530 fma 1 0 12345678901 -> 1.23456789E+10 Inexact Rounded +fmax3531 fma 1 1234567896 0 -> 1.23456790E+9 Inexact Rounded +fmax3532 fma 1 0 1234567896 -> 1.23456790E+9 Inexact Rounded + +precision: 15 +-- still checking +fmax3541 fma 1 12345678000 0 -> 12345678000 +fmax3542 fma 1 0 12345678000 -> 12345678000 +fmax3543 fma 1 1234567800 0 -> 1234567800 +fmax3544 fma 1 0 1234567800 -> 1234567800 +fmax3545 fma 1 1234567890 0 -> 1234567890 +fmax3546 fma 1 0 1234567890 -> 1234567890 +fmax3547 fma 1 1234567891 0 -> 1234567891 +fmax3548 fma 1 0 1234567891 -> 1234567891 +fmax3549 fma 1 12345678901 0 -> 12345678901 +fmax3550 fma 1 0 12345678901 -> 12345678901 +fmax3551 fma 1 1234567896 0 -> 1234567896 +fmax3552 fma 1 0 1234567896 -> 1234567896 + +-- verify a query +precision: 16 +maxExponent: +394 +minExponent: -393 +rounding: down +fmax3561 fma 1 1e-398 9.000000000000000E+384 -> 9.000000000000000E+384 Inexact Rounded +fmax3562 fma 1 0 9.000000000000000E+384 -> 9.000000000000000E+384 Rounded +-- and using decimal64 bounds... +precision: 16 +maxExponent: +384 +minExponent: -383 +rounding: down +fmax3563 fma 1 1e-388 9.000000000000000E+374 -> 9.000000000000000E+374 Inexact Rounded +fmax3564 fma 1 0 9.000000000000000E+374 -> 9.000000000000000E+374 Rounded + + +-- some more residue effects with extreme rounding +precision: 9 +rounding: half_up +fmax3601 fma 1 123456789 0.000001 -> 123456789 Inexact Rounded +rounding: half_even +fmax3602 fma 1 123456789 0.000001 -> 123456789 Inexact Rounded +rounding: half_down +fmax3603 fma 1 123456789 0.000001 -> 123456789 Inexact Rounded +rounding: floor +fmax3604 fma 1 123456789 0.000001 -> 123456789 Inexact Rounded +rounding: ceiling +fmax3605 fma 1 123456789 0.000001 -> 123456790 Inexact Rounded +rounding: up +fmax3606 fma 1 123456789 0.000001 -> 123456790 Inexact Rounded +rounding: down +fmax3607 fma 1 123456789 0.000001 -> 123456789 Inexact Rounded + +rounding: half_up +fmax3611 fma 1 123456789 -0.000001 -> 123456789 Inexact Rounded +rounding: half_even +fmax3612 fma 1 123456789 -0.000001 -> 123456789 Inexact Rounded +rounding: half_down +fmax3613 fma 1 123456789 -0.000001 -> 123456789 Inexact Rounded +rounding: floor +fmax3614 fma 1 123456789 -0.000001 -> 123456788 Inexact Rounded +rounding: ceiling +fmax3615 fma 1 123456789 -0.000001 -> 123456789 Inexact Rounded +rounding: up +fmax3616 fma 1 123456789 -0.000001 -> 123456789 Inexact Rounded +rounding: down +fmax3617 fma 1 123456789 -0.000001 -> 123456788 Inexact Rounded + +rounding: half_up +fmax3621 fma 1 123456789 0.499999 -> 123456789 Inexact Rounded +rounding: half_even +fmax3622 fma 1 123456789 0.499999 -> 123456789 Inexact Rounded +rounding: half_down +fmax3623 fma 1 123456789 0.499999 -> 123456789 Inexact Rounded +rounding: floor +fmax3624 fma 1 123456789 0.499999 -> 123456789 Inexact Rounded +rounding: ceiling +fmax3625 fma 1 123456789 0.499999 -> 123456790 Inexact Rounded +rounding: up +fmax3626 fma 1 123456789 0.499999 -> 123456790 Inexact Rounded +rounding: down +fmax3627 fma 1 123456789 0.499999 -> 123456789 Inexact Rounded + +rounding: half_up +fmax3631 fma 1 123456789 -0.499999 -> 123456789 Inexact Rounded +rounding: half_even +fmax3632 fma 1 123456789 -0.499999 -> 123456789 Inexact Rounded +rounding: half_down +fmax3633 fma 1 123456789 -0.499999 -> 123456789 Inexact Rounded +rounding: floor +fmax3634 fma 1 123456789 -0.499999 -> 123456788 Inexact Rounded +rounding: ceiling +fmax3635 fma 1 123456789 -0.499999 -> 123456789 Inexact Rounded +rounding: up +fmax3636 fma 1 123456789 -0.499999 -> 123456789 Inexact Rounded +rounding: down +fmax3637 fma 1 123456789 -0.499999 -> 123456788 Inexact Rounded + +rounding: half_up +fmax3641 fma 1 123456789 0.500001 -> 123456790 Inexact Rounded +rounding: half_even +fmax3642 fma 1 123456789 0.500001 -> 123456790 Inexact Rounded +rounding: half_down +fmax3643 fma 1 123456789 0.500001 -> 123456790 Inexact Rounded +rounding: floor +fmax3644 fma 1 123456789 0.500001 -> 123456789 Inexact Rounded +rounding: ceiling +fmax3645 fma 1 123456789 0.500001 -> 123456790 Inexact Rounded +rounding: up +fmax3646 fma 1 123456789 0.500001 -> 123456790 Inexact Rounded +rounding: down +fmax3647 fma 1 123456789 0.500001 -> 123456789 Inexact Rounded + +rounding: half_up +fmax3651 fma 1 123456789 -0.500001 -> 123456788 Inexact Rounded +rounding: half_even +fmax3652 fma 1 123456789 -0.500001 -> 123456788 Inexact Rounded +rounding: half_down +fmax3653 fma 1 123456789 -0.500001 -> 123456788 Inexact Rounded +rounding: floor +fmax3654 fma 1 123456789 -0.500001 -> 123456788 Inexact Rounded +rounding: ceiling +fmax3655 fma 1 123456789 -0.500001 -> 123456789 Inexact Rounded +rounding: up +fmax3656 fma 1 123456789 -0.500001 -> 123456789 Inexact Rounded +rounding: down +fmax3657 fma 1 123456789 -0.500001 -> 123456788 Inexact Rounded + +-- long operand triangle +rounding: half_up +precision: 37 +fmax3660 fma 1 98471198160.56524417578665886060 -23994.14313393939743548945165462 -> 98471174166.42211023638922337114834538 +precision: 36 +fmax3661 fma 1 98471198160.56524417578665886060 -23994.14313393939743548945165462 -> 98471174166.4221102363892233711483454 Inexact Rounded +precision: 35 +fmax3662 fma 1 98471198160.56524417578665886060 -23994.14313393939743548945165462 -> 98471174166.422110236389223371148345 Inexact Rounded +precision: 34 +fmax3663 fma 1 98471198160.56524417578665886060 -23994.14313393939743548945165462 -> 98471174166.42211023638922337114835 Inexact Rounded +precision: 33 +fmax3664 fma 1 98471198160.56524417578665886060 -23994.14313393939743548945165462 -> 98471174166.4221102363892233711483 Inexact Rounded +precision: 32 +fmax3665 fma 1 98471198160.56524417578665886060 -23994.14313393939743548945165462 -> 98471174166.422110236389223371148 Inexact Rounded +precision: 31 +fmax3666 fma 1 98471198160.56524417578665886060 -23994.14313393939743548945165462 -> 98471174166.42211023638922337115 Inexact Rounded +precision: 30 +fmax3667 fma 1 98471198160.56524417578665886060 -23994.14313393939743548945165462 -> 98471174166.4221102363892233711 Inexact Rounded +precision: 29 +fmax3668 fma 1 98471198160.56524417578665886060 -23994.14313393939743548945165462 -> 98471174166.422110236389223371 Inexact Rounded +precision: 28 +fmax3669 fma 1 98471198160.56524417578665886060 -23994.14313393939743548945165462 -> 98471174166.42211023638922337 Inexact Rounded +precision: 27 +fmax3670 fma 1 98471198160.56524417578665886060 -23994.14313393939743548945165462 -> 98471174166.4221102363892234 Inexact Rounded +precision: 26 +fmax3671 fma 1 98471198160.56524417578665886060 -23994.14313393939743548945165462 -> 98471174166.422110236389223 Inexact Rounded +precision: 25 +fmax3672 fma 1 98471198160.56524417578665886060 -23994.14313393939743548945165462 -> 98471174166.42211023638922 Inexact Rounded +precision: 24 +fmax3673 fma 1 98471198160.56524417578665886060 -23994.14313393939743548945165462 -> 98471174166.4221102363892 Inexact Rounded +precision: 23 +fmax3674 fma 1 98471198160.56524417578665886060 -23994.14313393939743548945165462 -> 98471174166.422110236389 Inexact Rounded +precision: 22 +fmax3675 fma 1 98471198160.56524417578665886060 -23994.14313393939743548945165462 -> 98471174166.42211023639 Inexact Rounded +precision: 21 +fmax3676 fma 1 98471198160.56524417578665886060 -23994.14313393939743548945165462 -> 98471174166.4221102364 Inexact Rounded +precision: 20 +fmax3677 fma 1 98471198160.56524417578665886060 -23994.14313393939743548945165462 -> 98471174166.422110236 Inexact Rounded +precision: 19 +fmax3678 fma 1 98471198160.56524417578665886060 -23994.14313393939743548945165462 -> 98471174166.42211024 Inexact Rounded +precision: 18 +fmax3679 fma 1 98471198160.56524417578665886060 -23994.14313393939743548945165462 -> 98471174166.4221102 Inexact Rounded +precision: 17 +fmax3680 fma 1 98471198160.56524417578665886060 -23994.14313393939743548945165462 -> 98471174166.422110 Inexact Rounded +precision: 16 +fmax3681 fma 1 98471198160.56524417578665886060 -23994.14313393939743548945165462 -> 98471174166.42211 Inexact Rounded +precision: 15 +fmax3682 fma 1 98471198160.56524417578665886060 -23994.14313393939743548945165462 -> 98471174166.4221 Inexact Rounded +precision: 14 +fmax3683 fma 1 98471198160.56524417578665886060 -23994.14313393939743548945165462 -> 98471174166.422 Inexact Rounded +precision: 13 +fmax3684 fma 1 98471198160.56524417578665886060 -23994.14313393939743548945165462 -> 98471174166.42 Inexact Rounded +precision: 12 +fmax3685 fma 1 98471198160.56524417578665886060 -23994.14313393939743548945165462 -> 98471174166.4 Inexact Rounded +precision: 11 +fmax3686 fma 1 98471198160.56524417578665886060 -23994.14313393939743548945165462 -> 98471174166 Inexact Rounded +precision: 10 +fmax3687 fma 1 98471198160.56524417578665886060 -23994.14313393939743548945165462 -> 9.847117417E+10 Inexact Rounded +precision: 9 +fmax3688 fma 1 98471198160.56524417578665886060 -23994.14313393939743548945165462 -> 9.84711742E+10 Inexact Rounded +precision: 8 +fmax3689 fma 1 98471198160.56524417578665886060 -23994.14313393939743548945165462 -> 9.8471174E+10 Inexact Rounded +precision: 7 +fmax3690 fma 1 98471198160.56524417578665886060 -23994.14313393939743548945165462 -> 9.847117E+10 Inexact Rounded +precision: 6 +fmax3691 fma 1 98471198160.56524417578665886060 -23994.14313393939743548945165462 -> 9.84712E+10 Inexact Rounded +precision: 5 +fmax3692 fma 1 98471198160.56524417578665886060 -23994.14313393939743548945165462 -> 9.8471E+10 Inexact Rounded +precision: 4 +fmax3693 fma 1 98471198160.56524417578665886060 -23994.14313393939743548945165462 -> 9.847E+10 Inexact Rounded +precision: 3 +fmax3694 fma 1 98471198160.56524417578665886060 -23994.14313393939743548945165462 -> 9.85E+10 Inexact Rounded +precision: 2 +fmax3695 fma 1 98471198160.56524417578665886060 -23994.14313393939743548945165462 -> 9.8E+10 Inexact Rounded +precision: 1 +fmax3696 fma 1 98471198160.56524417578665886060 -23994.14313393939743548945165462 -> 1E+11 Inexact Rounded + +-- more zeros, etc. +rounding: half_up +precision: 9 + +fmax3701 fma 1 5.00 1.00E-3 -> 5.00100 +fmax3702 fma 1 00.00 0.000 -> 0.000 +fmax3703 fma 1 00.00 0E-3 -> 0.000 +fmax3704 fma 1 0E-3 00.00 -> 0.000 + +fmax3710 fma 1 0E+3 00.00 -> 0.00 +fmax3711 fma 1 0E+3 00.0 -> 0.0 +fmax3712 fma 1 0E+3 00. -> 0 +fmax3713 fma 1 0E+3 00.E+1 -> 0E+1 +fmax3714 fma 1 0E+3 00.E+2 -> 0E+2 +fmax3715 fma 1 0E+3 00.E+3 -> 0E+3 +fmax3716 fma 1 0E+3 00.E+4 -> 0E+3 +fmax3717 fma 1 0E+3 00.E+5 -> 0E+3 +fmax3718 fma 1 0E+3 -00.0 -> 0.0 +fmax3719 fma 1 0E+3 -00. -> 0 +fmax3731 fma 1 0E+3 -00.E+1 -> 0E+1 + +fmax3720 fma 1 00.00 0E+3 -> 0.00 +fmax3721 fma 1 00.0 0E+3 -> 0.0 +fmax3722 fma 1 00. 0E+3 -> 0 +fmax3723 fma 1 00.E+1 0E+3 -> 0E+1 +fmax3724 fma 1 00.E+2 0E+3 -> 0E+2 +fmax3725 fma 1 00.E+3 0E+3 -> 0E+3 +fmax3726 fma 1 00.E+4 0E+3 -> 0E+3 +fmax3727 fma 1 00.E+5 0E+3 -> 0E+3 +fmax3728 fma 1 -00.00 0E+3 -> 0.00 +fmax3729 fma 1 -00.0 0E+3 -> 0.0 +fmax3730 fma 1 -00. 0E+3 -> 0 + +fmax3732 fma 1 0 0 -> 0 +fmax3733 fma 1 0 -0 -> 0 +fmax3734 fma 1 -0 0 -> 0 +fmax3735 fma 1 -0 -0 -> -0 -- IEEE 854 special case + +fmax3736 fma 1 1 -1 -> 0 +fmax3737 fma 1 -1 -1 -> -2 +fmax3738 fma 1 1 1 -> 2 +fmax3739 fma 1 -1 1 -> 0 + +fmax3741 fma 1 0 -1 -> -1 +fmax3742 fma 1 -0 -1 -> -1 +fmax3743 fma 1 0 1 -> 1 +fmax3744 fma 1 -0 1 -> 1 +fmax3745 fma 1 -1 0 -> -1 +fmax3746 fma 1 -1 -0 -> -1 +fmax3747 fma 1 1 0 -> 1 +fmax3748 fma 1 1 -0 -> 1 + +fmax3751 fma 1 0.0 -1 -> -1.0 +fmax3752 fma 1 -0.0 -1 -> -1.0 +fmax3753 fma 1 0.0 1 -> 1.0 +fmax3754 fma 1 -0.0 1 -> 1.0 +fmax3755 fma 1 -1.0 0 -> -1.0 +fmax3756 fma 1 -1.0 -0 -> -1.0 +fmax3757 fma 1 1.0 0 -> 1.0 +fmax3758 fma 1 1.0 -0 -> 1.0 + +fmax3761 fma 1 0 -1.0 -> -1.0 +fmax3762 fma 1 -0 -1.0 -> -1.0 +fmax3763 fma 1 0 1.0 -> 1.0 +fmax3764 fma 1 -0 1.0 -> 1.0 +fmax3765 fma 1 -1 0.0 -> -1.0 +fmax3766 fma 1 -1 -0.0 -> -1.0 +fmax3767 fma 1 1 0.0 -> 1.0 +fmax3768 fma 1 1 -0.0 -> 1.0 + +fmax3771 fma 1 0.0 -1.0 -> -1.0 +fmax3772 fma 1 -0.0 -1.0 -> -1.0 +fmax3773 fma 1 0.0 1.0 -> 1.0 +fmax3774 fma 1 -0.0 1.0 -> 1.0 +fmax3775 fma 1 -1.0 0.0 -> -1.0 +fmax3776 fma 1 -1.0 -0.0 -> -1.0 +fmax3777 fma 1 1.0 0.0 -> 1.0 +fmax3778 fma 1 1.0 -0.0 -> 1.0 + +-- Specials +fmax3780 fma 1 -Inf -Inf -> -Infinity +fmax3781 fma 1 -Inf -1000 -> -Infinity +fmax3782 fma 1 -Inf -1 -> -Infinity +fmax3783 fma 1 -Inf -0 -> -Infinity +fmax3784 fma 1 -Inf 0 -> -Infinity +fmax3785 fma 1 -Inf 1 -> -Infinity +fmax3786 fma 1 -Inf 1000 -> -Infinity +fmax3787 fma 1 -1000 -Inf -> -Infinity +fmax3788 fma 1 -Inf -Inf -> -Infinity +fmax3789 fma 1 -1 -Inf -> -Infinity +fmax3790 fma 1 -0 -Inf -> -Infinity +fmax3791 fma 1 0 -Inf -> -Infinity +fmax3792 fma 1 1 -Inf -> -Infinity +fmax3793 fma 1 1000 -Inf -> -Infinity +fmax3794 fma 1 Inf -Inf -> NaN Invalid_operation + +fmax3800 fma 1 Inf -Inf -> NaN Invalid_operation +fmax3801 fma 1 Inf -1000 -> Infinity +fmax3802 fma 1 Inf -1 -> Infinity +fmax3803 fma 1 Inf -0 -> Infinity +fmax3804 fma 1 Inf 0 -> Infinity +fmax3805 fma 1 Inf 1 -> Infinity +fmax3806 fma 1 Inf 1000 -> Infinity +fmax3807 fma 1 Inf Inf -> Infinity +fmax3808 fma 1 -1000 Inf -> Infinity +fmax3809 fma 1 -Inf Inf -> NaN Invalid_operation +fmax3810 fma 1 -1 Inf -> Infinity +fmax3811 fma 1 -0 Inf -> Infinity +fmax3812 fma 1 0 Inf -> Infinity +fmax3813 fma 1 1 Inf -> Infinity +fmax3814 fma 1 1000 Inf -> Infinity +fmax3815 fma 1 Inf Inf -> Infinity + +fmax3821 fma 1 NaN -Inf -> NaN +fmax3822 fma 1 NaN -1000 -> NaN +fmax3823 fma 1 NaN -1 -> NaN +fmax3824 fma 1 NaN -0 -> NaN +fmax3825 fma 1 NaN 0 -> NaN +fmax3826 fma 1 NaN 1 -> NaN +fmax3827 fma 1 NaN 1000 -> NaN +fmax3828 fma 1 NaN Inf -> NaN +fmax3829 fma 1 NaN NaN -> NaN +fmax3830 fma 1 -Inf NaN -> NaN +fmax3831 fma 1 -1000 NaN -> NaN +fmax3832 fma 1 -1 NaN -> NaN +fmax3833 fma 1 -0 NaN -> NaN +fmax3834 fma 1 0 NaN -> NaN +fmax3835 fma 1 1 NaN -> NaN +fmax3836 fma 1 1000 NaN -> NaN +fmax3837 fma 1 Inf NaN -> NaN + +fmax3841 fma 1 sNaN -Inf -> NaN Invalid_operation +fmax3842 fma 1 sNaN -1000 -> NaN Invalid_operation +fmax3843 fma 1 sNaN -1 -> NaN Invalid_operation +fmax3844 fma 1 sNaN -0 -> NaN Invalid_operation +fmax3845 fma 1 sNaN 0 -> NaN Invalid_operation +fmax3846 fma 1 sNaN 1 -> NaN Invalid_operation +fmax3847 fma 1 sNaN 1000 -> NaN Invalid_operation +fmax3848 fma 1 sNaN NaN -> NaN Invalid_operation +fmax3849 fma 1 sNaN sNaN -> NaN Invalid_operation +fmax3850 fma 1 NaN sNaN -> NaN Invalid_operation +fmax3851 fma 1 -Inf sNaN -> NaN Invalid_operation +fmax3852 fma 1 -1000 sNaN -> NaN Invalid_operation +fmax3853 fma 1 -1 sNaN -> NaN Invalid_operation +fmax3854 fma 1 -0 sNaN -> NaN Invalid_operation +fmax3855 fma 1 0 sNaN -> NaN Invalid_operation +fmax3856 fma 1 1 sNaN -> NaN Invalid_operation +fmax3857 fma 1 1000 sNaN -> NaN Invalid_operation +fmax3858 fma 1 Inf sNaN -> NaN Invalid_operation +fmax3859 fma 1 NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +fmax3861 fma 1 NaN1 -Inf -> NaN1 +fmax3862 fma 1 +NaN2 -1000 -> NaN2 +fmax3863 fma 1 NaN3 1000 -> NaN3 +fmax3864 fma 1 NaN4 Inf -> NaN4 +fmax3865 fma 1 NaN5 +NaN6 -> NaN5 +fmax3866 fma 1 -Inf NaN7 -> NaN7 +fmax3867 fma 1 -1000 NaN8 -> NaN8 +fmax3868 fma 1 1000 NaN9 -> NaN9 +fmax3869 fma 1 Inf +NaN10 -> NaN10 +fmax3871 fma 1 sNaN11 -Inf -> NaN11 Invalid_operation +fmax3872 fma 1 sNaN12 -1000 -> NaN12 Invalid_operation +fmax3873 fma 1 sNaN13 1000 -> NaN13 Invalid_operation +fmax3874 fma 1 sNaN14 NaN17 -> NaN14 Invalid_operation +fmax3875 fma 1 sNaN15 sNaN18 -> NaN15 Invalid_operation +fmax3876 fma 1 NaN16 sNaN19 -> NaN19 Invalid_operation +fmax3877 fma 1 -Inf +sNaN20 -> NaN20 Invalid_operation +fmax3878 fma 1 -1000 sNaN21 -> NaN21 Invalid_operation +fmax3879 fma 1 1000 sNaN22 -> NaN22 Invalid_operation +fmax3880 fma 1 Inf sNaN23 -> NaN23 Invalid_operation +fmax3881 fma 1 +NaN25 +sNaN24 -> NaN24 Invalid_operation +fmax3882 fma 1 -NaN26 NaN28 -> -NaN26 +fmax3883 fma 1 -sNaN27 sNaN29 -> -NaN27 Invalid_operation +fmax3884 fma 1 1000 -NaN30 -> -NaN30 +fmax3885 fma 1 1000 -sNaN31 -> -NaN31 Invalid_operation + +-- overflow, underflow and subnormal tests +maxexponent: 999999 +minexponent: -999999 +precision: 9 +fmax3890 fma 1 1E+999999 9E+999999 -> Infinity Overflow Inexact Rounded +fmax3891 fma 1 9E+999999 1E+999999 -> Infinity Overflow Inexact Rounded +fmax3892 fma 1 -1.1E-999999 1E-999999 -> -1E-1000000 Subnormal +fmax3893 fma 1 1E-999999 -1.1e-999999 -> -1E-1000000 Subnormal +fmax3894 fma 1 -1.0001E-999999 1E-999999 -> -1E-1000003 Subnormal +fmax3895 fma 1 1E-999999 -1.0001e-999999 -> -1E-1000003 Subnormal +fmax3896 fma 1 -1E+999999 -9E+999999 -> -Infinity Overflow Inexact Rounded +fmax3897 fma 1 -9E+999999 -1E+999999 -> -Infinity Overflow Inexact Rounded +fmax3898 fma 1 +1.1E-999999 -1E-999999 -> 1E-1000000 Subnormal +fmax3899 fma 1 -1E-999999 +1.1e-999999 -> 1E-1000000 Subnormal +fmax3900 fma 1 +1.0001E-999999 -1E-999999 -> 1E-1000003 Subnormal +fmax3901 fma 1 -1E-999999 +1.0001e-999999 -> 1E-1000003 Subnormal +fmax3902 fma 1 -1E+999999 +9E+999999 -> 8E+999999 +fmax3903 fma 1 -9E+999999 +1E+999999 -> -8E+999999 + +precision: 3 +fmax3904 fma 1 0 -9.999E+999999 -> -Infinity Inexact Overflow Rounded +fmax3905 fma 1 -9.999E+999999 0 -> -Infinity Inexact Overflow Rounded +fmax3906 fma 1 0 9.999E+999999 -> Infinity Inexact Overflow Rounded +fmax3907 fma 1 9.999E+999999 0 -> Infinity Inexact Overflow Rounded + +precision: 3 +maxexponent: 999 +minexponent: -999 +fmax3910 fma 1 1.00E-999 0 -> 1.00E-999 +fmax3911 fma 1 0.1E-999 0 -> 1E-1000 Subnormal +fmax3912 fma 1 0.10E-999 0 -> 1.0E-1000 Subnormal +fmax3913 fma 1 0.100E-999 0 -> 1.0E-1000 Subnormal Rounded +fmax3914 fma 1 0.01E-999 0 -> 1E-1001 Subnormal +-- next is rounded to Nmin +fmax3915 fma 1 0.999E-999 0 -> 1.00E-999 Inexact Rounded Subnormal Underflow +fmax3916 fma 1 0.099E-999 0 -> 1.0E-1000 Inexact Rounded Subnormal Underflow +fmax3917 fma 1 0.009E-999 0 -> 1E-1001 Inexact Rounded Subnormal Underflow +fmax3918 fma 1 0.001E-999 0 -> 0E-1001 Inexact Rounded Subnormal Underflow Clamped +fmax3919 fma 1 0.0009E-999 0 -> 0E-1001 Inexact Rounded Subnormal Underflow Clamped +fmax3920 fma 1 0.0001E-999 0 -> 0E-1001 Inexact Rounded Subnormal Underflow Clamped + +fmax3930 fma 1 -1.00E-999 0 -> -1.00E-999 +fmax3931 fma 1 -0.1E-999 0 -> -1E-1000 Subnormal +fmax3932 fma 1 -0.10E-999 0 -> -1.0E-1000 Subnormal +fmax3933 fma 1 -0.100E-999 0 -> -1.0E-1000 Subnormal Rounded +fmax3934 fma 1 -0.01E-999 0 -> -1E-1001 Subnormal +-- next is rounded to Nmin +fmax3935 fma 1 -0.999E-999 0 -> -1.00E-999 Inexact Rounded Subnormal Underflow +fmax3936 fma 1 -0.099E-999 0 -> -1.0E-1000 Inexact Rounded Subnormal Underflow +fmax3937 fma 1 -0.009E-999 0 -> -1E-1001 Inexact Rounded Subnormal Underflow +fmax3938 fma 1 -0.001E-999 0 -> -0E-1001 Inexact Rounded Subnormal Underflow Clamped +fmax3939 fma 1 -0.0009E-999 0 -> -0E-1001 Inexact Rounded Subnormal Underflow Clamped +fmax3940 fma 1 -0.0001E-999 0 -> -0E-1001 Inexact Rounded Subnormal Underflow Clamped + +-- some non-zero subnormal fma 1 s +fmax3950 fma 1 1.00E-999 0.1E-999 -> 1.10E-999 +fmax3951 fma 1 0.1E-999 0.1E-999 -> 2E-1000 Subnormal +fmax3952 fma 1 0.10E-999 0.1E-999 -> 2.0E-1000 Subnormal +fmax3953 fma 1 0.100E-999 0.1E-999 -> 2.0E-1000 Subnormal Rounded +fmax3954 fma 1 0.01E-999 0.1E-999 -> 1.1E-1000 Subnormal +fmax3955 fma 1 0.999E-999 0.1E-999 -> 1.10E-999 Inexact Rounded +fmax3956 fma 1 0.099E-999 0.1E-999 -> 2.0E-1000 Inexact Rounded Subnormal Underflow +fmax3957 fma 1 0.009E-999 0.1E-999 -> 1.1E-1000 Inexact Rounded Subnormal Underflow +fmax3958 fma 1 0.001E-999 0.1E-999 -> 1.0E-1000 Inexact Rounded Subnormal Underflow +fmax3959 fma 1 0.0009E-999 0.1E-999 -> 1.0E-1000 Inexact Rounded Subnormal Underflow +fmax3960 fma 1 0.0001E-999 0.1E-999 -> 1.0E-1000 Inexact Rounded Subnormal Underflow +-- negatives... +fmax3961 fma 1 1.00E-999 -0.1E-999 -> 9.0E-1000 Subnormal +fmax3962 fma 1 0.1E-999 -0.1E-999 -> 0E-1000 +fmax3963 fma 1 0.10E-999 -0.1E-999 -> 0E-1001 +fmax3964 fma 1 0.100E-999 -0.1E-999 -> 0E-1001 Clamped +fmax3965 fma 1 0.01E-999 -0.1E-999 -> -9E-1001 Subnormal +fmax3966 fma 1 0.999E-999 -0.1E-999 -> 9.0E-1000 Inexact Rounded Subnormal Underflow +fmax3967 fma 1 0.099E-999 -0.1E-999 -> -0E-1001 Inexact Rounded Subnormal Underflow Clamped +fmax3968 fma 1 0.009E-999 -0.1E-999 -> -9E-1001 Inexact Rounded Subnormal Underflow +fmax3969 fma 1 0.001E-999 -0.1E-999 -> -1.0E-1000 Inexact Rounded Subnormal Underflow +fmax3970 fma 1 0.0009E-999 -0.1E-999 -> -1.0E-1000 Inexact Rounded Subnormal Underflow +fmax3971 fma 1 0.0001E-999 -0.1E-999 -> -1.0E-1000 Inexact Rounded Subnormal Underflow + +-- some 'real' numbers +maxExponent: 384 +minExponent: -383 +precision: 8 +fmax3566 fma 1 99999061735E-394 0E-394 -> 9.999906E-384 Inexact Rounded Underflow Subnormal +precision: 7 +fmax3567 fma 1 99999061735E-394 0E-394 -> 9.99991E-384 Inexact Rounded Underflow Subnormal +precision: 6 +fmax3568 fma 1 99999061735E-394 0E-394 -> 9.9999E-384 Inexact Rounded Underflow Subnormal + +-- now the case where we can get underflow but the result is normal +-- [note this can't happen if the operands are also bounded, as we +-- cannot represent 1E-399, for example] +precision: 16 +rounding: half_up +maxExponent: 384 +minExponent: -383 + +fmax3571 fma 1 1E-383 0 -> 1E-383 +fmax3572 fma 1 1E-384 0 -> 1E-384 Subnormal +fmax3573 fma 1 1E-383 1E-384 -> 1.1E-383 +fmax3574 subtract 1E-383 1E-384 -> 9E-384 Subnormal + +-- Here we explore the boundary of rounding a subnormal to Nmin +fmax3575 subtract 1E-383 1E-398 -> 9.99999999999999E-384 Subnormal +fmax3576 subtract 1E-383 1E-398 -> 9.99999999999999E-384 Subnormal +fmax3577 subtract 1E-383 1E-399 -> 1.000000000000000E-383 Underflow Inexact Subnormal Rounded +fmax3578 subtract 1E-383 1E-400 -> 1.000000000000000E-383 Underflow Inexact Subnormal Rounded +fmax3579 subtract 1E-383 1E-401 -> 1.000000000000000E-383 Underflow Inexact Subnormal Rounded +fmax3580 subtract 1E-383 1E-402 -> 1.000000000000000E-383 Underflow Inexact Subnormal Rounded + +-- check for double-rounded subnormals +precision: 5 +maxexponent: 79 +minexponent: -79 +-- Add: lhs and rhs 0 +fmax31001 fma 1 1.52444E-80 0 -> 1.524E-80 Inexact Rounded Subnormal Underflow +fmax31002 fma 1 1.52445E-80 0 -> 1.524E-80 Inexact Rounded Subnormal Underflow +fmax31003 fma 1 1.52446E-80 0 -> 1.524E-80 Inexact Rounded Subnormal Underflow +fmax31004 fma 1 0 1.52444E-80 -> 1.524E-80 Inexact Rounded Subnormal Underflow +fmax31005 fma 1 0 1.52445E-80 -> 1.524E-80 Inexact Rounded Subnormal Underflow +fmax31006 fma 1 0 1.52446E-80 -> 1.524E-80 Inexact Rounded Subnormal Underflow + +-- Add: lhs >> rhs and vice versa +fmax31011 fma 1 1.52444E-80 1E-100 -> 1.524E-80 Inexact Rounded Subnormal Underflow +fmax31012 fma 1 1.52445E-80 1E-100 -> 1.524E-80 Inexact Rounded Subnormal Underflow +fmax31013 fma 1 1.52446E-80 1E-100 -> 1.524E-80 Inexact Rounded Subnormal Underflow +fmax31014 fma 1 1E-100 1.52444E-80 -> 1.524E-80 Inexact Rounded Subnormal Underflow +fmax31015 fma 1 1E-100 1.52445E-80 -> 1.524E-80 Inexact Rounded Subnormal Underflow +fmax31016 fma 1 1E-100 1.52446E-80 -> 1.524E-80 Inexact Rounded Subnormal Underflow + +-- Add: lhs + rhs fma 1 ition carried out +fmax31021 fma 1 1.52443E-80 1.00001E-80 -> 2.524E-80 Inexact Rounded Subnormal Underflow +fmax31022 fma 1 1.52444E-80 1.00001E-80 -> 2.524E-80 Inexact Rounded Subnormal Underflow +fmax31023 fma 1 1.52445E-80 1.00001E-80 -> 2.524E-80 Inexact Rounded Subnormal Underflow +fmax31024 fma 1 1.00001E-80 1.52443E-80 -> 2.524E-80 Inexact Rounded Subnormal Underflow +fmax31025 fma 1 1.00001E-80 1.52444E-80 -> 2.524E-80 Inexact Rounded Subnormal Underflow +fmax31026 fma 1 1.00001E-80 1.52445E-80 -> 2.524E-80 Inexact Rounded Subnormal Underflow + +-- And for round down full and subnormal results +precision: 16 +maxExponent: +384 +minExponent: -383 +rounding: down + +fmax31100 fma 1 1e+2 -1e-383 -> 99.99999999999999 Rounded Inexact +fmax31101 fma 1 1e+1 -1e-383 -> 9.999999999999999 Rounded Inexact +fmax31103 fma 1 +1 -1e-383 -> 0.9999999999999999 Rounded Inexact +fmax31104 fma 1 1e-1 -1e-383 -> 0.09999999999999999 Rounded Inexact +fmax31105 fma 1 1e-2 -1e-383 -> 0.009999999999999999 Rounded Inexact +fmax31106 fma 1 1e-3 -1e-383 -> 0.0009999999999999999 Rounded Inexact +fmax31107 fma 1 1e-4 -1e-383 -> 0.00009999999999999999 Rounded Inexact +fmax31108 fma 1 1e-5 -1e-383 -> 0.000009999999999999999 Rounded Inexact +fmax31109 fma 1 1e-6 -1e-383 -> 9.999999999999999E-7 Rounded Inexact + +rounding: ceiling +fmax31110 fma 1 -1e+2 +1e-383 -> -99.99999999999999 Rounded Inexact +fmax31111 fma 1 -1e+1 +1e-383 -> -9.999999999999999 Rounded Inexact +fmax31113 fma 1 -1 +1e-383 -> -0.9999999999999999 Rounded Inexact +fmax31114 fma 1 -1e-1 +1e-383 -> -0.09999999999999999 Rounded Inexact +fmax31115 fma 1 -1e-2 +1e-383 -> -0.009999999999999999 Rounded Inexact +fmax31116 fma 1 -1e-3 +1e-383 -> -0.0009999999999999999 Rounded Inexact +fmax31117 fma 1 -1e-4 +1e-383 -> -0.00009999999999999999 Rounded Inexact +fmax31118 fma 1 -1e-5 +1e-383 -> -0.000009999999999999999 Rounded Inexact +fmax31119 fma 1 -1e-6 +1e-383 -> -9.999999999999999E-7 Rounded Inexact + +rounding: down +precision: 7 +maxExponent: +96 +minExponent: -95 +fmax31130 fma 1 1 -1e-200 -> 0.9999999 Rounded Inexact +-- subnormal boundary +fmax31131 fma 1 1.000000E-94 -1e-200 -> 9.999999E-95 Rounded Inexact +fmax31132 fma 1 1.000001E-95 -1e-200 -> 1.000000E-95 Rounded Inexact +fmax31133 fma 1 1.000000E-95 -1e-200 -> 9.99999E-96 Rounded Inexact Subnormal Underflow +fmax31134 fma 1 0.999999E-95 -1e-200 -> 9.99998E-96 Rounded Inexact Subnormal Underflow +fmax31135 fma 1 0.001000E-95 -1e-200 -> 9.99E-99 Rounded Inexact Subnormal Underflow +fmax31136 fma 1 0.000999E-95 -1e-200 -> 9.98E-99 Rounded Inexact Subnormal Underflow +fmax31137 fma 1 1.000000E-95 -1e-101 -> 9.99999E-96 Subnormal +fmax31138 fma 1 10000E-101 -1e-200 -> 9.999E-98 Subnormal Inexact Rounded Underflow +fmax31139 fma 1 1000E-101 -1e-200 -> 9.99E-99 Subnormal Inexact Rounded Underflow +fmax31140 fma 1 100E-101 -1e-200 -> 9.9E-100 Subnormal Inexact Rounded Underflow +fmax31141 fma 1 10E-101 -1e-200 -> 9E-101 Subnormal Inexact Rounded Underflow +fmax31142 fma 1 1E-101 -1e-200 -> 0E-101 Subnormal Inexact Rounded Underflow Clamped +fmax31143 fma 1 0E-101 -1e-200 -> -0E-101 Subnormal Inexact Rounded Underflow Clamped +fmax31144 fma 1 1E-102 -1e-200 -> 0E-101 Subnormal Inexact Rounded Underflow Clamped + +fmax31151 fma 1 10000E-102 -1e-200 -> 9.99E-99 Subnormal Inexact Rounded Underflow +fmax31152 fma 1 1000E-102 -1e-200 -> 9.9E-100 Subnormal Inexact Rounded Underflow +fmax31153 fma 1 100E-102 -1e-200 -> 9E-101 Subnormal Inexact Rounded Underflow +fmax31154 fma 1 10E-102 -1e-200 -> 0E-101 Subnormal Inexact Rounded Underflow Clamped +fmax31155 fma 1 1E-102 -1e-200 -> 0E-101 Subnormal Inexact Rounded Underflow Clamped +fmax31156 fma 1 0E-102 -1e-200 -> -0E-101 Subnormal Inexact Rounded Underflow Clamped +fmax31157 fma 1 1E-103 -1e-200 -> 0E-101 Subnormal Inexact Rounded Underflow Clamped + +fmax31160 fma 1 100E-105 -1e-101 -> -0E-101 Subnormal Inexact Rounded Underflow Clamped +fmax31161 fma 1 100E-105 -1e-201 -> 0E-101 Subnormal Inexact Rounded Underflow Clamped + +-- tests based on Gunnar Degnbol's edge case +precision: 15 +rounding: half_up +maxExponent: 384 +minexponent: -383 + +fmax31200 fma 1 1E15 -0.5 -> 1.00000000000000E+15 Inexact Rounded +fmax31201 fma 1 1E15 -0.50 -> 1.00000000000000E+15 Inexact Rounded +fmax31210 fma 1 1E15 -0.51 -> 999999999999999 Inexact Rounded +fmax31211 fma 1 1E15 -0.501 -> 999999999999999 Inexact Rounded +fmax31212 fma 1 1E15 -0.5001 -> 999999999999999 Inexact Rounded +fmax31213 fma 1 1E15 -0.50001 -> 999999999999999 Inexact Rounded +fmax31214 fma 1 1E15 -0.500001 -> 999999999999999 Inexact Rounded +fmax31215 fma 1 1E15 -0.5000001 -> 999999999999999 Inexact Rounded +fmax31216 fma 1 1E15 -0.50000001 -> 999999999999999 Inexact Rounded +fmax31217 fma 1 1E15 -0.500000001 -> 999999999999999 Inexact Rounded +fmax31218 fma 1 1E15 -0.5000000001 -> 999999999999999 Inexact Rounded +fmax31219 fma 1 1E15 -0.50000000001 -> 999999999999999 Inexact Rounded +fmax31220 fma 1 1E15 -0.500000000001 -> 999999999999999 Inexact Rounded +fmax31221 fma 1 1E15 -0.5000000000001 -> 999999999999999 Inexact Rounded +fmax31222 fma 1 1E15 -0.50000000000001 -> 999999999999999 Inexact Rounded +fmax31223 fma 1 1E15 -0.500000000000001 -> 999999999999999 Inexact Rounded +fmax31224 fma 1 1E15 -0.5000000000000001 -> 999999999999999 Inexact Rounded +fmax31225 fma 1 1E15 -0.5000000000000000 -> 1.00000000000000E+15 Inexact Rounded +fmax31230 fma 1 1E15 -5000000.000000001 -> 999999995000000 Inexact Rounded + +precision: 16 + +fmax31300 fma 1 1E16 -0.5 -> 1.000000000000000E+16 Inexact Rounded +fmax31310 fma 1 1E16 -0.51 -> 9999999999999999 Inexact Rounded +fmax31311 fma 1 1E16 -0.501 -> 9999999999999999 Inexact Rounded +fmax31312 fma 1 1E16 -0.5001 -> 9999999999999999 Inexact Rounded +fmax31313 fma 1 1E16 -0.50001 -> 9999999999999999 Inexact Rounded +fmax31314 fma 1 1E16 -0.500001 -> 9999999999999999 Inexact Rounded +fmax31315 fma 1 1E16 -0.5000001 -> 9999999999999999 Inexact Rounded +fmax31316 fma 1 1E16 -0.50000001 -> 9999999999999999 Inexact Rounded +fmax31317 fma 1 1E16 -0.500000001 -> 9999999999999999 Inexact Rounded +fmax31318 fma 1 1E16 -0.5000000001 -> 9999999999999999 Inexact Rounded +fmax31319 fma 1 1E16 -0.50000000001 -> 9999999999999999 Inexact Rounded +fmax31320 fma 1 1E16 -0.500000000001 -> 9999999999999999 Inexact Rounded +fmax31321 fma 1 1E16 -0.5000000000001 -> 9999999999999999 Inexact Rounded +fmax31322 fma 1 1E16 -0.50000000000001 -> 9999999999999999 Inexact Rounded +fmax31323 fma 1 1E16 -0.500000000000001 -> 9999999999999999 Inexact Rounded +fmax31324 fma 1 1E16 -0.5000000000000001 -> 9999999999999999 Inexact Rounded +fmax31325 fma 1 1E16 -0.5000000000000000 -> 1.000000000000000E+16 Inexact Rounded +fmax31326 fma 1 1E16 -0.500000000000000 -> 1.000000000000000E+16 Inexact Rounded +fmax31327 fma 1 1E16 -0.50000000000000 -> 1.000000000000000E+16 Inexact Rounded +fmax31328 fma 1 1E16 -0.5000000000000 -> 1.000000000000000E+16 Inexact Rounded +fmax31329 fma 1 1E16 -0.500000000000 -> 1.000000000000000E+16 Inexact Rounded +fmax31330 fma 1 1E16 -0.50000000000 -> 1.000000000000000E+16 Inexact Rounded +fmax31331 fma 1 1E16 -0.5000000000 -> 1.000000000000000E+16 Inexact Rounded +fmax31332 fma 1 1E16 -0.500000000 -> 1.000000000000000E+16 Inexact Rounded +fmax31333 fma 1 1E16 -0.50000000 -> 1.000000000000000E+16 Inexact Rounded +fmax31334 fma 1 1E16 -0.5000000 -> 1.000000000000000E+16 Inexact Rounded +fmax31335 fma 1 1E16 -0.500000 -> 1.000000000000000E+16 Inexact Rounded +fmax31336 fma 1 1E16 -0.50000 -> 1.000000000000000E+16 Inexact Rounded +fmax31337 fma 1 1E16 -0.5000 -> 1.000000000000000E+16 Inexact Rounded +fmax31338 fma 1 1E16 -0.500 -> 1.000000000000000E+16 Inexact Rounded +fmax31339 fma 1 1E16 -0.50 -> 1.000000000000000E+16 Inexact Rounded + +fmax31340 fma 1 1E16 -5000000.000010001 -> 9999999995000000 Inexact Rounded +fmax31341 fma 1 1E16 -5000000.000000001 -> 9999999995000000 Inexact Rounded + +fmax31349 fma 1 9999999999999999 0.4 -> 9999999999999999 Inexact Rounded +fmax31350 fma 1 9999999999999999 0.49 -> 9999999999999999 Inexact Rounded +fmax31351 fma 1 9999999999999999 0.499 -> 9999999999999999 Inexact Rounded +fmax31352 fma 1 9999999999999999 0.4999 -> 9999999999999999 Inexact Rounded +fmax31353 fma 1 9999999999999999 0.49999 -> 9999999999999999 Inexact Rounded +fmax31354 fma 1 9999999999999999 0.499999 -> 9999999999999999 Inexact Rounded +fmax31355 fma 1 9999999999999999 0.4999999 -> 9999999999999999 Inexact Rounded +fmax31356 fma 1 9999999999999999 0.49999999 -> 9999999999999999 Inexact Rounded +fmax31357 fma 1 9999999999999999 0.499999999 -> 9999999999999999 Inexact Rounded +fmax31358 fma 1 9999999999999999 0.4999999999 -> 9999999999999999 Inexact Rounded +fmax31359 fma 1 9999999999999999 0.49999999999 -> 9999999999999999 Inexact Rounded +fmax31360 fma 1 9999999999999999 0.499999999999 -> 9999999999999999 Inexact Rounded +fmax31361 fma 1 9999999999999999 0.4999999999999 -> 9999999999999999 Inexact Rounded +fmax31362 fma 1 9999999999999999 0.49999999999999 -> 9999999999999999 Inexact Rounded +fmax31363 fma 1 9999999999999999 0.499999999999999 -> 9999999999999999 Inexact Rounded +fmax31364 fma 1 9999999999999999 0.4999999999999999 -> 9999999999999999 Inexact Rounded +fmax31365 fma 1 9999999999999999 0.5000000000000000 -> 1.000000000000000E+16 Inexact Rounded +fmax31367 fma 1 9999999999999999 0.500000000000000 -> 1.000000000000000E+16 Inexact Rounded +fmax31368 fma 1 9999999999999999 0.50000000000000 -> 1.000000000000000E+16 Inexact Rounded +fmax31369 fma 1 9999999999999999 0.5000000000000 -> 1.000000000000000E+16 Inexact Rounded +fmax31370 fma 1 9999999999999999 0.500000000000 -> 1.000000000000000E+16 Inexact Rounded +fmax31371 fma 1 9999999999999999 0.50000000000 -> 1.000000000000000E+16 Inexact Rounded +fmax31372 fma 1 9999999999999999 0.5000000000 -> 1.000000000000000E+16 Inexact Rounded +fmax31373 fma 1 9999999999999999 0.500000000 -> 1.000000000000000E+16 Inexact Rounded +fmax31374 fma 1 9999999999999999 0.50000000 -> 1.000000000000000E+16 Inexact Rounded +fmax31375 fma 1 9999999999999999 0.5000000 -> 1.000000000000000E+16 Inexact Rounded +fmax31376 fma 1 9999999999999999 0.500000 -> 1.000000000000000E+16 Inexact Rounded +fmax31377 fma 1 9999999999999999 0.50000 -> 1.000000000000000E+16 Inexact Rounded +fmax31378 fma 1 9999999999999999 0.5000 -> 1.000000000000000E+16 Inexact Rounded +fmax31379 fma 1 9999999999999999 0.500 -> 1.000000000000000E+16 Inexact Rounded +fmax31380 fma 1 9999999999999999 0.50 -> 1.000000000000000E+16 Inexact Rounded +fmax31381 fma 1 9999999999999999 0.5 -> 1.000000000000000E+16 Inexact Rounded +fmax31382 fma 1 9999999999999999 0.5000000000000001 -> 1.000000000000000E+16 Inexact Rounded +fmax31383 fma 1 9999999999999999 0.500000000000001 -> 1.000000000000000E+16 Inexact Rounded +fmax31384 fma 1 9999999999999999 0.50000000000001 -> 1.000000000000000E+16 Inexact Rounded +fmax31385 fma 1 9999999999999999 0.5000000000001 -> 1.000000000000000E+16 Inexact Rounded +fmax31386 fma 1 9999999999999999 0.500000000001 -> 1.000000000000000E+16 Inexact Rounded +fmax31387 fma 1 9999999999999999 0.50000000001 -> 1.000000000000000E+16 Inexact Rounded +fmax31388 fma 1 9999999999999999 0.5000000001 -> 1.000000000000000E+16 Inexact Rounded +fmax31389 fma 1 9999999999999999 0.500000001 -> 1.000000000000000E+16 Inexact Rounded +fmax31390 fma 1 9999999999999999 0.50000001 -> 1.000000000000000E+16 Inexact Rounded +fmax31391 fma 1 9999999999999999 0.5000001 -> 1.000000000000000E+16 Inexact Rounded +fmax31392 fma 1 9999999999999999 0.500001 -> 1.000000000000000E+16 Inexact Rounded +fmax31393 fma 1 9999999999999999 0.50001 -> 1.000000000000000E+16 Inexact Rounded +fmax31394 fma 1 9999999999999999 0.5001 -> 1.000000000000000E+16 Inexact Rounded +fmax31395 fma 1 9999999999999999 0.501 -> 1.000000000000000E+16 Inexact Rounded +fmax31396 fma 1 9999999999999999 0.51 -> 1.000000000000000E+16 Inexact Rounded + +-- More GD edge cases, where difference between the unadjusted +-- exponents is larger than the maximum precision and one side is 0 +precision: 15 +rounding: half_up +maxExponent: 384 +minexponent: -383 + +fmax31400 fma 1 0 1.23456789012345 -> 1.23456789012345 +fmax31401 fma 1 0 1.23456789012345E-1 -> 0.123456789012345 +fmax31402 fma 1 0 1.23456789012345E-2 -> 0.0123456789012345 +fmax31403 fma 1 0 1.23456789012345E-3 -> 0.00123456789012345 +fmax31404 fma 1 0 1.23456789012345E-4 -> 0.000123456789012345 +fmax31405 fma 1 0 1.23456789012345E-5 -> 0.0000123456789012345 +fmax31406 fma 1 0 1.23456789012345E-6 -> 0.00000123456789012345 +fmax31407 fma 1 0 1.23456789012345E-7 -> 1.23456789012345E-7 +fmax31408 fma 1 0 1.23456789012345E-8 -> 1.23456789012345E-8 +fmax31409 fma 1 0 1.23456789012345E-9 -> 1.23456789012345E-9 +fmax31410 fma 1 0 1.23456789012345E-10 -> 1.23456789012345E-10 +fmax31411 fma 1 0 1.23456789012345E-11 -> 1.23456789012345E-11 +fmax31412 fma 1 0 1.23456789012345E-12 -> 1.23456789012345E-12 +fmax31413 fma 1 0 1.23456789012345E-13 -> 1.23456789012345E-13 +fmax31414 fma 1 0 1.23456789012345E-14 -> 1.23456789012345E-14 +fmax31415 fma 1 0 1.23456789012345E-15 -> 1.23456789012345E-15 +fmax31416 fma 1 0 1.23456789012345E-16 -> 1.23456789012345E-16 +fmax31417 fma 1 0 1.23456789012345E-17 -> 1.23456789012345E-17 +fmax31418 fma 1 0 1.23456789012345E-18 -> 1.23456789012345E-18 +fmax31419 fma 1 0 1.23456789012345E-19 -> 1.23456789012345E-19 + +-- same, precision 16.. +precision: 16 +fmax31420 fma 1 0 1.123456789012345 -> 1.123456789012345 +fmax31421 fma 1 0 1.123456789012345E-1 -> 0.1123456789012345 +fmax31422 fma 1 0 1.123456789012345E-2 -> 0.01123456789012345 +fmax31423 fma 1 0 1.123456789012345E-3 -> 0.001123456789012345 +fmax31424 fma 1 0 1.123456789012345E-4 -> 0.0001123456789012345 +fmax31425 fma 1 0 1.123456789012345E-5 -> 0.00001123456789012345 +fmax31426 fma 1 0 1.123456789012345E-6 -> 0.000001123456789012345 +fmax31427 fma 1 0 1.123456789012345E-7 -> 1.123456789012345E-7 +fmax31428 fma 1 0 1.123456789012345E-8 -> 1.123456789012345E-8 +fmax31429 fma 1 0 1.123456789012345E-9 -> 1.123456789012345E-9 +fmax31430 fma 1 0 1.123456789012345E-10 -> 1.123456789012345E-10 +fmax31431 fma 1 0 1.123456789012345E-11 -> 1.123456789012345E-11 +fmax31432 fma 1 0 1.123456789012345E-12 -> 1.123456789012345E-12 +fmax31433 fma 1 0 1.123456789012345E-13 -> 1.123456789012345E-13 +fmax31434 fma 1 0 1.123456789012345E-14 -> 1.123456789012345E-14 +fmax31435 fma 1 0 1.123456789012345E-15 -> 1.123456789012345E-15 +fmax31436 fma 1 0 1.123456789012345E-16 -> 1.123456789012345E-16 +fmax31437 fma 1 0 1.123456789012345E-17 -> 1.123456789012345E-17 +fmax31438 fma 1 0 1.123456789012345E-18 -> 1.123456789012345E-18 +fmax31439 fma 1 0 1.123456789012345E-19 -> 1.123456789012345E-19 + +-- same, reversed 0 +fmax31440 fma 1 1.123456789012345 0 -> 1.123456789012345 +fmax31441 fma 1 1.123456789012345E-1 0 -> 0.1123456789012345 +fmax31442 fma 1 1.123456789012345E-2 0 -> 0.01123456789012345 +fmax31443 fma 1 1.123456789012345E-3 0 -> 0.001123456789012345 +fmax31444 fma 1 1.123456789012345E-4 0 -> 0.0001123456789012345 +fmax31445 fma 1 1.123456789012345E-5 0 -> 0.00001123456789012345 +fmax31446 fma 1 1.123456789012345E-6 0 -> 0.000001123456789012345 +fmax31447 fma 1 1.123456789012345E-7 0 -> 1.123456789012345E-7 +fmax31448 fma 1 1.123456789012345E-8 0 -> 1.123456789012345E-8 +fmax31449 fma 1 1.123456789012345E-9 0 -> 1.123456789012345E-9 +fmax31450 fma 1 1.123456789012345E-10 0 -> 1.123456789012345E-10 +fmax31451 fma 1 1.123456789012345E-11 0 -> 1.123456789012345E-11 +fmax31452 fma 1 1.123456789012345E-12 0 -> 1.123456789012345E-12 +fmax31453 fma 1 1.123456789012345E-13 0 -> 1.123456789012345E-13 +fmax31454 fma 1 1.123456789012345E-14 0 -> 1.123456789012345E-14 +fmax31455 fma 1 1.123456789012345E-15 0 -> 1.123456789012345E-15 +fmax31456 fma 1 1.123456789012345E-16 0 -> 1.123456789012345E-16 +fmax31457 fma 1 1.123456789012345E-17 0 -> 1.123456789012345E-17 +fmax31458 fma 1 1.123456789012345E-18 0 -> 1.123456789012345E-18 +fmax31459 fma 1 1.123456789012345E-19 0 -> 1.123456789012345E-19 + +-- same, Es on the 0 +fmax31460 fma 1 1.123456789012345 0E-0 -> 1.123456789012345 +fmax31461 fma 1 1.123456789012345 0E-1 -> 1.123456789012345 +fmax31462 fma 1 1.123456789012345 0E-2 -> 1.123456789012345 +fmax31463 fma 1 1.123456789012345 0E-3 -> 1.123456789012345 +fmax31464 fma 1 1.123456789012345 0E-4 -> 1.123456789012345 +fmax31465 fma 1 1.123456789012345 0E-5 -> 1.123456789012345 +fmax31466 fma 1 1.123456789012345 0E-6 -> 1.123456789012345 +fmax31467 fma 1 1.123456789012345 0E-7 -> 1.123456789012345 +fmax31468 fma 1 1.123456789012345 0E-8 -> 1.123456789012345 +fmax31469 fma 1 1.123456789012345 0E-9 -> 1.123456789012345 +fmax31470 fma 1 1.123456789012345 0E-10 -> 1.123456789012345 +fmax31471 fma 1 1.123456789012345 0E-11 -> 1.123456789012345 +fmax31472 fma 1 1.123456789012345 0E-12 -> 1.123456789012345 +fmax31473 fma 1 1.123456789012345 0E-13 -> 1.123456789012345 +fmax31474 fma 1 1.123456789012345 0E-14 -> 1.123456789012345 +fmax31475 fma 1 1.123456789012345 0E-15 -> 1.123456789012345 +-- next four flag Rounded because the 0 extends the result +fmax31476 fma 1 1.123456789012345 0E-16 -> 1.123456789012345 Rounded +fmax31477 fma 1 1.123456789012345 0E-17 -> 1.123456789012345 Rounded +fmax31478 fma 1 1.123456789012345 0E-18 -> 1.123456789012345 Rounded +fmax31479 fma 1 1.123456789012345 0E-19 -> 1.123456789012345 Rounded + +-- sum of two opposite-sign operands is exactly 0 and floor => -0 +precision: 16 +maxExponent: 384 +minexponent: -383 + +rounding: half_up +-- exact zeros from zeros +fmax31500 fma 1 0 0E-19 -> 0E-19 +fmax31501 fma 1 -0 0E-19 -> 0E-19 +fmax31502 fma 1 0 -0E-19 -> 0E-19 +fmax31503 fma 1 -0 -0E-19 -> -0E-19 +fmax31504 fma 1 0E-400 0E-19 -> 0E-398 Clamped +fmax31505 fma 1 -0E-400 0E-19 -> 0E-398 Clamped +fmax31506 fma 1 0E-400 -0E-19 -> 0E-398 Clamped +fmax31507 fma 1 -0E-400 -0E-19 -> -0E-398 Clamped +-- inexact zeros +fmax31511 fma 1 1E-401 1E-400 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +fmax31512 fma 1 -1E-401 1E-400 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +fmax31513 fma 1 1E-401 -1E-400 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped +fmax31514 fma 1 -1E-401 -1E-400 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped +-- some exact zeros from non-zeros +fmax31515 fma 1 1E-401 1E-401 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +fmax31516 fma 1 -1E-401 1E-401 -> 0E-398 Clamped +fmax31517 fma 1 1E-401 -1E-401 -> 0E-398 Clamped +fmax31518 fma 1 -1E-401 -1E-401 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped + +rounding: half_down +-- exact zeros from zeros +fmax31520 fma 1 0 0E-19 -> 0E-19 +fmax31521 fma 1 -0 0E-19 -> 0E-19 +fmax31522 fma 1 0 -0E-19 -> 0E-19 +fmax31523 fma 1 -0 -0E-19 -> -0E-19 +fmax31524 fma 1 0E-400 0E-19 -> 0E-398 Clamped +fmax31525 fma 1 -0E-400 0E-19 -> 0E-398 Clamped +fmax31526 fma 1 0E-400 -0E-19 -> 0E-398 Clamped +fmax31527 fma 1 -0E-400 -0E-19 -> -0E-398 Clamped +-- inexact zeros +fmax31531 fma 1 1E-401 1E-400 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +fmax31532 fma 1 -1E-401 1E-400 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +fmax31533 fma 1 1E-401 -1E-400 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped +fmax31534 fma 1 -1E-401 -1E-400 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped +-- some exact zeros from non-zeros +fmax31535 fma 1 1E-401 1E-401 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +fmax31536 fma 1 -1E-401 1E-401 -> 0E-398 Clamped +fmax31537 fma 1 1E-401 -1E-401 -> 0E-398 Clamped +fmax31538 fma 1 -1E-401 -1E-401 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped + +rounding: half_even +-- exact zeros from zeros +fmax31540 fma 1 0 0E-19 -> 0E-19 +fmax31541 fma 1 -0 0E-19 -> 0E-19 +fmax31542 fma 1 0 -0E-19 -> 0E-19 +fmax31543 fma 1 -0 -0E-19 -> -0E-19 +fmax31544 fma 1 0E-400 0E-19 -> 0E-398 Clamped +fmax31545 fma 1 -0E-400 0E-19 -> 0E-398 Clamped +fmax31546 fma 1 0E-400 -0E-19 -> 0E-398 Clamped +fmax31547 fma 1 -0E-400 -0E-19 -> -0E-398 Clamped +-- inexact zeros +fmax31551 fma 1 1E-401 1E-400 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +fmax31552 fma 1 -1E-401 1E-400 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +fmax31553 fma 1 1E-401 -1E-400 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped +fmax31554 fma 1 -1E-401 -1E-400 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped +-- some exact zeros from non-zeros +fmax31555 fma 1 1E-401 1E-401 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +fmax31556 fma 1 -1E-401 1E-401 -> 0E-398 Clamped +fmax31557 fma 1 1E-401 -1E-401 -> 0E-398 Clamped +fmax31558 fma 1 -1E-401 -1E-401 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped + +rounding: up +-- exact zeros from zeros +fmax31560 fma 1 0 0E-19 -> 0E-19 +fmax31561 fma 1 -0 0E-19 -> 0E-19 +fmax31562 fma 1 0 -0E-19 -> 0E-19 +fmax31563 fma 1 -0 -0E-19 -> -0E-19 +fmax31564 fma 1 0E-400 0E-19 -> 0E-398 Clamped +fmax31565 fma 1 -0E-400 0E-19 -> 0E-398 Clamped +fmax31566 fma 1 0E-400 -0E-19 -> 0E-398 Clamped +fmax31567 fma 1 -0E-400 -0E-19 -> -0E-398 Clamped +-- inexact zeros +fmax31571 fma 1 1E-401 1E-400 -> 1E-398 Subnormal Inexact Rounded Underflow +fmax31572 fma 1 -1E-401 1E-400 -> 1E-398 Subnormal Inexact Rounded Underflow +fmax31573 fma 1 1E-401 -1E-400 -> -1E-398 Subnormal Inexact Rounded Underflow +fmax31574 fma 1 -1E-401 -1E-400 -> -1E-398 Subnormal Inexact Rounded Underflow +-- some exact zeros from non-zeros +fmax31575 fma 1 1E-401 1E-401 -> 1E-398 Subnormal Inexact Rounded Underflow +fmax31576 fma 1 -1E-401 1E-401 -> 0E-398 Clamped +fmax31577 fma 1 1E-401 -1E-401 -> 0E-398 Clamped +fmax31578 fma 1 -1E-401 -1E-401 -> -1E-398 Subnormal Inexact Rounded Underflow + +rounding: down +-- exact zeros from zeros +fmax31580 fma 1 0 0E-19 -> 0E-19 +fmax31581 fma 1 -0 0E-19 -> 0E-19 +fmax31582 fma 1 0 -0E-19 -> 0E-19 +fmax31583 fma 1 -0 -0E-19 -> -0E-19 +fmax31584 fma 1 0E-400 0E-19 -> 0E-398 Clamped +fmax31585 fma 1 -0E-400 0E-19 -> 0E-398 Clamped +fmax31586 fma 1 0E-400 -0E-19 -> 0E-398 Clamped +fmax31587 fma 1 -0E-400 -0E-19 -> -0E-398 Clamped +-- inexact zeros +fmax31591 fma 1 1E-401 1E-400 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +fmax31592 fma 1 -1E-401 1E-400 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +fmax31593 fma 1 1E-401 -1E-400 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped +fmax31594 fma 1 -1E-401 -1E-400 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped +-- some exact zeros from non-zeros +fmax31595 fma 1 1E-401 1E-401 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +fmax31596 fma 1 -1E-401 1E-401 -> 0E-398 Clamped +fmax31597 fma 1 1E-401 -1E-401 -> 0E-398 Clamped +fmax31598 fma 1 -1E-401 -1E-401 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped + +rounding: ceiling +-- exact zeros from zeros +fmax31600 fma 1 0 0E-19 -> 0E-19 +fmax31601 fma 1 -0 0E-19 -> 0E-19 +fmax31602 fma 1 0 -0E-19 -> 0E-19 +fmax31603 fma 1 -0 -0E-19 -> -0E-19 +fmax31604 fma 1 0E-400 0E-19 -> 0E-398 Clamped +fmax31605 fma 1 -0E-400 0E-19 -> 0E-398 Clamped +fmax31606 fma 1 0E-400 -0E-19 -> 0E-398 Clamped +fmax31607 fma 1 -0E-400 -0E-19 -> -0E-398 Clamped +-- inexact zeros +fmax31611 fma 1 1E-401 1E-400 -> 1E-398 Subnormal Inexact Rounded Underflow +fmax31612 fma 1 -1E-401 1E-400 -> 1E-398 Subnormal Inexact Rounded Underflow +fmax31613 fma 1 1E-401 -1E-400 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped +fmax31614 fma 1 -1E-401 -1E-400 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped +-- some exact zeros from non-zeros +fmax31615 fma 1 1E-401 1E-401 -> 1E-398 Subnormal Inexact Rounded Underflow +fmax31616 fma 1 -1E-401 1E-401 -> 0E-398 Clamped +fmax31617 fma 1 1E-401 -1E-401 -> 0E-398 Clamped +fmax31618 fma 1 -1E-401 -1E-401 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped + +-- and the extra-special ugly case; unusual minuses marked by -- * +rounding: floor +-- exact zeros from zeros +fmax31620 fma 1 0 0E-19 -> 0E-19 +fmax31621 fma 1 -0 0E-19 -> -0E-19 -- * +fmax31622 fma 1 0 -0E-19 -> -0E-19 -- * +fmax31623 fma 1 -0 -0E-19 -> -0E-19 +fmax31624 fma 1 0E-400 0E-19 -> 0E-398 Clamped +fmax31625 fma 1 -0E-400 0E-19 -> -0E-398 Clamped -- * +fmax31626 fma 1 0E-400 -0E-19 -> -0E-398 Clamped -- * +fmax31627 fma 1 -0E-400 -0E-19 -> -0E-398 Clamped +-- inexact zeros +fmax31631 fma 1 1E-401 1E-400 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +fmax31632 fma 1 -1E-401 1E-400 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +fmax31633 fma 1 1E-401 -1E-400 -> -1E-398 Subnormal Inexact Rounded Underflow +fmax31634 fma 1 -1E-401 -1E-400 -> -1E-398 Subnormal Inexact Rounded Underflow +-- some exact zeros from non-zeros +fmax31635 fma 1 1E-401 1E-401 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +fmax31636 fma 1 -1E-401 1E-401 -> -0E-398 Clamped -- * +fmax31637 fma 1 1E-401 -1E-401 -> -0E-398 Clamped -- * +fmax31638 fma 1 -1E-401 -1E-401 -> -1E-398 Subnormal Inexact Rounded Underflow + +-- BigDecimal problem testcases 2006.01.23 +precision: 16 +maxExponent: 384 +minexponent: -383 + +rounding: down +precision: 7 +fmax31651 fma 1 10001E+2 -2E+1 -> 1.00008E+6 +precision: 6 +fmax31652 fma 1 10001E+2 -2E+1 -> 1.00008E+6 +precision: 5 +fmax31653 fma 1 10001E+2 -2E+1 -> 1.0000E+6 Inexact Rounded +precision: 4 +fmax31654 fma 1 10001E+2 -2E+1 -> 1.000E+6 Inexact Rounded +precision: 3 +fmax31655 fma 1 10001E+2 -2E+1 -> 1.00E+6 Inexact Rounded +precision: 2 +fmax31656 fma 1 10001E+2 -2E+1 -> 1.0E+6 Inexact Rounded +precision: 1 +fmax31657 fma 1 10001E+2 -2E+1 -> 1E+6 Inexact Rounded + +rounding: half_even +precision: 7 +fmax31661 fma 1 10001E+2 -2E+1 -> 1.00008E+6 +precision: 6 +fmax31662 fma 1 10001E+2 -2E+1 -> 1.00008E+6 +precision: 5 +fmax31663 fma 1 10001E+2 -2E+1 -> 1.0001E+6 Inexact Rounded +precision: 4 +fmax31664 fma 1 10001E+2 -2E+1 -> 1.000E+6 Inexact Rounded +precision: 3 +fmax31665 fma 1 10001E+2 -2E+1 -> 1.00E+6 Inexact Rounded +precision: 2 +fmax31666 fma 1 10001E+2 -2E+1 -> 1.0E+6 Inexact Rounded +precision: 1 +fmax31667 fma 1 10001E+2 -2E+1 -> 1E+6 Inexact Rounded + +rounding: up +precision: 7 +fmax31671 fma 1 10001E+2 -2E+1 -> 1.00008E+6 +precision: 6 +fmax31672 fma 1 10001E+2 -2E+1 -> 1.00008E+6 +precision: 5 +fmax31673 fma 1 10001E+2 -2E+1 -> 1.0001E+6 Inexact Rounded +precision: 4 +fmax31674 fma 1 10001E+2 -2E+1 -> 1.001E+6 Inexact Rounded +precision: 3 +fmax31675 fma 1 10001E+2 -2E+1 -> 1.01E+6 Inexact Rounded +precision: 2 +fmax31676 fma 1 10001E+2 -2E+1 -> 1.1E+6 Inexact Rounded +precision: 1 +fmax31677 fma 1 10001E+2 -2E+1 -> 2E+6 Inexact Rounded + +precision: 34 +rounding: half_up +maxExponent: 6144 +minExponent: -6143 +-- Examples from SQL proposal (Krishna Kulkarni) +fmax31701 fma 1 130E-2 120E-2 -> 2.50 +fmax31702 fma 1 130E-2 12E-1 -> 2.50 +fmax31703 fma 1 130E-2 1E0 -> 2.30 +fmax31704 fma 1 1E2 1E4 -> 1.01E+4 +fmax31705 subtract 130E-2 120E-2 -> 0.10 +fmax31706 subtract 130E-2 12E-1 -> 0.10 +fmax31707 subtract 130E-2 1E0 -> 0.30 +fmax31708 subtract 1E2 1E4 -> -9.9E+3 + +------------------------------------------------------------------------ +-- Same as above, using decimal64 default parameters -- +------------------------------------------------------------------------ +precision: 16 +rounding: half_even +maxExponent: 384 +minexponent: -383 + +-- [first group are 'quick confidence check'] +fmax36001 fma 1 1 1 -> 2 +fmax36002 fma 1 2 3 -> 5 +fmax36003 fma 1 '5.75' '3.3' -> 9.05 +fmax36004 fma 1 '5' '-3' -> 2 +fmax36005 fma 1 '-5' '-3' -> -8 +fmax36006 fma 1 '-7' '2.5' -> -4.5 +fmax36007 fma 1 '0.7' '0.3' -> 1.0 +fmax36008 fma 1 '1.25' '1.25' -> 2.50 +fmax36009 fma 1 '1.23456789' '1.00000000' -> '2.23456789' +fmax36010 fma 1 '1.23456789' '1.00000011' -> '2.23456800' + +fmax36011 fma 1 '0.44444444444444444' '0.55555555555555555' -> '1.000000000000000' Inexact Rounded +fmax36012 fma 1 '0.44444444444444440' '0.55555555555555555' -> '1.000000000000000' Inexact Rounded +fmax36013 fma 1 '0.44444444444444444' '0.55555555555555550' -> '0.9999999999999999' Inexact Rounded +fmax36014 fma 1 '0.444444444444444449' '0' -> '0.4444444444444444' Inexact Rounded +fmax36015 fma 1 '0.4444444444444444499' '0' -> '0.4444444444444444' Inexact Rounded +fmax36016 fma 1 '0.44444444444444444999' '0' -> '0.4444444444444444' Inexact Rounded +fmax36017 fma 1 '0.44444444444444445000' '0' -> '0.4444444444444444' Inexact Rounded +fmax36018 fma 1 '0.44444444444444445001' '0' -> '0.4444444444444445' Inexact Rounded +fmax36019 fma 1 '0.4444444444444444501' '0' -> '0.4444444444444445' Inexact Rounded +fmax36020 fma 1 '0.444444444444444451' '0' -> '0.4444444444444445' Inexact Rounded + +fmax36021 fma 1 0 1 -> 1 +fmax36022 fma 1 1 1 -> 2 +fmax36023 fma 1 2 1 -> 3 +fmax36024 fma 1 3 1 -> 4 +fmax36025 fma 1 4 1 -> 5 +fmax36026 fma 1 5 1 -> 6 +fmax36027 fma 1 6 1 -> 7 +fmax36028 fma 1 7 1 -> 8 +fmax36029 fma 1 8 1 -> 9 +fmax36030 fma 1 9 1 -> 10 + +-- some carrying effects +fmax36031 fma 1 '0.9998' '0.0000' -> '0.9998' +fmax36032 fma 1 '0.9998' '0.0001' -> '0.9999' +fmax36033 fma 1 '0.9998' '0.0002' -> '1.0000' +fmax36034 fma 1 '0.9998' '0.0003' -> '1.0001' + +fmax36035 fma 1 '70' '10000e+16' -> '1.000000000000000E+20' Inexact Rounded +fmax36036 fma 1 '700' '10000e+16' -> '1.000000000000000E+20' Inexact Rounded +fmax36037 fma 1 '7000' '10000e+16' -> '1.000000000000000E+20' Inexact Rounded +fmax36038 fma 1 '70000' '10000e+16' -> '1.000000000000001E+20' Inexact Rounded +fmax36039 fma 1 '700000' '10000e+16' -> '1.000000000000007E+20' Rounded + +-- symmetry: +fmax36040 fma 1 '10000e+16' '70' -> '1.000000000000000E+20' Inexact Rounded +fmax36041 fma 1 '10000e+16' '700' -> '1.000000000000000E+20' Inexact Rounded +fmax36042 fma 1 '10000e+16' '7000' -> '1.000000000000000E+20' Inexact Rounded +fmax36044 fma 1 '10000e+16' '70000' -> '1.000000000000001E+20' Inexact Rounded +fmax36045 fma 1 '10000e+16' '700000' -> '1.000000000000007E+20' Rounded + +fmax36046 fma 1 '10000e+9' '7' -> '10000000000007' +fmax36047 fma 1 '10000e+9' '70' -> '10000000000070' +fmax36048 fma 1 '10000e+9' '700' -> '10000000000700' +fmax36049 fma 1 '10000e+9' '7000' -> '10000000007000' +fmax36050 fma 1 '10000e+9' '70000' -> '10000000070000' +fmax36051 fma 1 '10000e+9' '700000' -> '10000000700000' + +-- examples from decarith +fmax36053 fma 1 '12' '7.00' -> '19.00' +fmax36054 fma 1 '1.3' '-1.07' -> '0.23' +fmax36055 fma 1 '1.3' '-1.30' -> '0.00' +fmax36056 fma 1 '1.3' '-2.07' -> '-0.77' +fmax36057 fma 1 '1E+2' '1E+4' -> '1.01E+4' + +-- from above +fmax36061 fma 1 1 '0.1' -> '1.1' +fmax36062 fma 1 1 '0.01' -> '1.01' +fmax36063 fma 1 1 '0.001' -> '1.001' +fmax36064 fma 1 1 '0.0001' -> '1.0001' +fmax36065 fma 1 1 '0.00001' -> '1.00001' +fmax36066 fma 1 1 '0.000001' -> '1.000001' +fmax36067 fma 1 1 '0.0000001' -> '1.0000001' +fmax36068 fma 1 1 '0.00000001' -> '1.00000001' + +-- some funny zeros [in case of bad signum] +fmax36070 fma 1 1 0 -> 1 +fmax36071 fma 1 1 0. -> 1 +fmax36072 fma 1 1 .0 -> 1.0 +fmax36073 fma 1 1 0.0 -> 1.0 +fmax36074 fma 1 1 0.00 -> 1.00 +fmax36075 fma 1 0 1 -> 1 +fmax36076 fma 1 0. 1 -> 1 +fmax36077 fma 1 .0 1 -> 1.0 +fmax36078 fma 1 0.0 1 -> 1.0 +fmax36079 fma 1 0.00 1 -> 1.00 + +-- some carries +fmax36080 fma 1 9999999999999998 1 -> 9999999999999999 +fmax36081 fma 1 9999999999999999 1 -> 1.000000000000000E+16 Rounded +fmax36082 fma 1 999999999999999 1 -> 1000000000000000 +fmax36083 fma 1 9999999999999 1 -> 10000000000000 +fmax36084 fma 1 99999999999 1 -> 100000000000 +fmax36085 fma 1 999999999 1 -> 1000000000 +fmax36086 fma 1 9999999 1 -> 10000000 +fmax36087 fma 1 99999 1 -> 100000 +fmax36088 fma 1 999 1 -> 1000 +fmax36089 fma 1 9 1 -> 10 + + +-- more LHS swaps +fmax36090 fma 1 '-56267E-10' 0 -> '-0.0000056267' +fmax36091 fma 1 '-56267E-6' 0 -> '-0.056267' +fmax36092 fma 1 '-56267E-5' 0 -> '-0.56267' +fmax36093 fma 1 '-56267E-4' 0 -> '-5.6267' +fmax36094 fma 1 '-56267E-3' 0 -> '-56.267' +fmax36095 fma 1 '-56267E-2' 0 -> '-562.67' +fmax36096 fma 1 '-56267E-1' 0 -> '-5626.7' +fmax36097 fma 1 '-56267E-0' 0 -> '-56267' +fmax36098 fma 1 '-5E-10' 0 -> '-5E-10' +fmax36099 fma 1 '-5E-7' 0 -> '-5E-7' +fmax36100 fma 1 '-5E-6' 0 -> '-0.000005' +fmax36101 fma 1 '-5E-5' 0 -> '-0.00005' +fmax36102 fma 1 '-5E-4' 0 -> '-0.0005' +fmax36103 fma 1 '-5E-1' 0 -> '-0.5' +fmax36104 fma 1 '-5E0' 0 -> '-5' +fmax36105 fma 1 '-5E1' 0 -> '-50' +fmax36106 fma 1 '-5E5' 0 -> '-500000' +fmax36107 fma 1 '-5E15' 0 -> '-5000000000000000' +fmax36108 fma 1 '-5E16' 0 -> '-5.000000000000000E+16' Rounded +fmax36109 fma 1 '-5E17' 0 -> '-5.000000000000000E+17' Rounded +fmax36110 fma 1 '-5E18' 0 -> '-5.000000000000000E+18' Rounded +fmax36111 fma 1 '-5E100' 0 -> '-5.000000000000000E+100' Rounded + +-- more RHS swaps +fmax36113 fma 1 0 '-56267E-10' -> '-0.0000056267' +fmax36114 fma 1 0 '-56267E-6' -> '-0.056267' +fmax36116 fma 1 0 '-56267E-5' -> '-0.56267' +fmax36117 fma 1 0 '-56267E-4' -> '-5.6267' +fmax36119 fma 1 0 '-56267E-3' -> '-56.267' +fmax36120 fma 1 0 '-56267E-2' -> '-562.67' +fmax36121 fma 1 0 '-56267E-1' -> '-5626.7' +fmax36122 fma 1 0 '-56267E-0' -> '-56267' +fmax36123 fma 1 0 '-5E-10' -> '-5E-10' +fmax36124 fma 1 0 '-5E-7' -> '-5E-7' +fmax36125 fma 1 0 '-5E-6' -> '-0.000005' +fmax36126 fma 1 0 '-5E-5' -> '-0.00005' +fmax36127 fma 1 0 '-5E-4' -> '-0.0005' +fmax36128 fma 1 0 '-5E-1' -> '-0.5' +fmax36129 fma 1 0 '-5E0' -> '-5' +fmax36130 fma 1 0 '-5E1' -> '-50' +fmax36131 fma 1 0 '-5E5' -> '-500000' +fmax36132 fma 1 0 '-5E15' -> '-5000000000000000' +fmax36133 fma 1 0 '-5E16' -> '-5.000000000000000E+16' Rounded +fmax36134 fma 1 0 '-5E17' -> '-5.000000000000000E+17' Rounded +fmax36135 fma 1 0 '-5E18' -> '-5.000000000000000E+18' Rounded +fmax36136 fma 1 0 '-5E100' -> '-5.000000000000000E+100' Rounded + +-- related +fmax36137 fma 1 1 '0E-19' -> '1.000000000000000' Rounded +fmax36138 fma 1 -1 '0E-19' -> '-1.000000000000000' Rounded +fmax36139 fma 1 '0E-19' 1 -> '1.000000000000000' Rounded +fmax36140 fma 1 '0E-19' -1 -> '-1.000000000000000' Rounded +fmax36141 fma 1 1E+11 0.0000 -> '100000000000.0000' +fmax36142 fma 1 1E+11 0.00000 -> '100000000000.0000' Rounded +fmax36143 fma 1 0.000 1E+12 -> '1000000000000.000' +fmax36144 fma 1 0.0000 1E+12 -> '1000000000000.000' Rounded + +-- [some of the next group are really constructor tests] +fmax36146 fma 1 '00.0' 0 -> '0.0' +fmax36147 fma 1 '0.00' 0 -> '0.00' +fmax36148 fma 1 0 '0.00' -> '0.00' +fmax36149 fma 1 0 '00.0' -> '0.0' +fmax36150 fma 1 '00.0' '0.00' -> '0.00' +fmax36151 fma 1 '0.00' '00.0' -> '0.00' +fmax36152 fma 1 '3' '.3' -> '3.3' +fmax36153 fma 1 '3.' '.3' -> '3.3' +fmax36154 fma 1 '3.0' '.3' -> '3.3' +fmax36155 fma 1 '3.00' '.3' -> '3.30' +fmax36156 fma 1 '3' '3' -> '6' +fmax36157 fma 1 '3' '+3' -> '6' +fmax36158 fma 1 '3' '-3' -> '0' +fmax36159 fma 1 '0.3' '-0.3' -> '0.0' +fmax36160 fma 1 '0.03' '-0.03' -> '0.00' + +-- try borderline precision, with carries, etc. +fmax36161 fma 1 '1E+13' '-1' -> '9999999999999' +fmax36162 fma 1 '1E+13' '1.11' -> '10000000000001.11' +fmax36163 fma 1 '1.11' '1E+13' -> '10000000000001.11' +fmax36164 fma 1 '-1' '1E+13' -> '9999999999999' +fmax36165 fma 1 '7E+13' '-1' -> '69999999999999' +fmax36166 fma 1 '7E+13' '1.11' -> '70000000000001.11' +fmax36167 fma 1 '1.11' '7E+13' -> '70000000000001.11' +fmax36168 fma 1 '-1' '7E+13' -> '69999999999999' + +-- 1234567890123456 1234567890123456 1 234567890123456 +fmax36170 fma 1 '0.4444444444444444' '0.5555555555555563' -> '1.000000000000001' Inexact Rounded +fmax36171 fma 1 '0.4444444444444444' '0.5555555555555562' -> '1.000000000000001' Inexact Rounded +fmax36172 fma 1 '0.4444444444444444' '0.5555555555555561' -> '1.000000000000000' Inexact Rounded +fmax36173 fma 1 '0.4444444444444444' '0.5555555555555560' -> '1.000000000000000' Inexact Rounded +fmax36174 fma 1 '0.4444444444444444' '0.5555555555555559' -> '1.000000000000000' Inexact Rounded +fmax36175 fma 1 '0.4444444444444444' '0.5555555555555558' -> '1.000000000000000' Inexact Rounded +fmax36176 fma 1 '0.4444444444444444' '0.5555555555555557' -> '1.000000000000000' Inexact Rounded +fmax36177 fma 1 '0.4444444444444444' '0.5555555555555556' -> '1.000000000000000' Rounded +fmax36178 fma 1 '0.4444444444444444' '0.5555555555555555' -> '0.9999999999999999' +fmax36179 fma 1 '0.4444444444444444' '0.5555555555555554' -> '0.9999999999999998' +fmax36180 fma 1 '0.4444444444444444' '0.5555555555555553' -> '0.9999999999999997' +fmax36181 fma 1 '0.4444444444444444' '0.5555555555555552' -> '0.9999999999999996' +fmax36182 fma 1 '0.4444444444444444' '0.5555555555555551' -> '0.9999999999999995' +fmax36183 fma 1 '0.4444444444444444' '0.5555555555555550' -> '0.9999999999999994' + +-- and some more, including residue effects and different roundings +rounding: half_up +fmax36200 fma 1 '6543210123456789' 0 -> '6543210123456789' +fmax36201 fma 1 '6543210123456789' 0.000000001 -> '6543210123456789' Inexact Rounded +fmax36202 fma 1 '6543210123456789' 0.000001 -> '6543210123456789' Inexact Rounded +fmax36203 fma 1 '6543210123456789' 0.1 -> '6543210123456789' Inexact Rounded +fmax36204 fma 1 '6543210123456789' 0.4 -> '6543210123456789' Inexact Rounded +fmax36205 fma 1 '6543210123456789' 0.49 -> '6543210123456789' Inexact Rounded +fmax36206 fma 1 '6543210123456789' 0.499999 -> '6543210123456789' Inexact Rounded +fmax36207 fma 1 '6543210123456789' 0.499999 -> '6543210123456789' Inexact Rounded +fmax36208 fma 1 '6543210123456789' 0.5 -> '6543210123456790' Inexact Rounded +fmax36209 fma 1 '6543210123456789' 0.500000001 -> '6543210123456790' Inexact Rounded +fmax36210 fma 1 '6543210123456789' 0.500001 -> '6543210123456790' Inexact Rounded +fmax36211 fma 1 '6543210123456789' 0.51 -> '6543210123456790' Inexact Rounded +fmax36212 fma 1 '6543210123456789' 0.6 -> '6543210123456790' Inexact Rounded +fmax36213 fma 1 '6543210123456789' 0.9 -> '6543210123456790' Inexact Rounded +fmax36214 fma 1 '6543210123456789' 0.99999 -> '6543210123456790' Inexact Rounded +fmax36215 fma 1 '6543210123456789' 0.999999 -> '6543210123456790' Inexact Rounded +fmax36216 fma 1 '6543210123456789' 1 -> '6543210123456790' +fmax36217 fma 1 '6543210123456789' 1.000000001 -> '6543210123456790' Inexact Rounded +fmax36218 fma 1 '6543210123456789' 1.00001 -> '6543210123456790' Inexact Rounded +fmax36219 fma 1 '6543210123456789' 1.1 -> '6543210123456790' Inexact Rounded + +rounding: half_even +fmax36220 fma 1 '6543210123456789' 0 -> '6543210123456789' +fmax36221 fma 1 '6543210123456789' 0.000000001 -> '6543210123456789' Inexact Rounded +fmax36222 fma 1 '6543210123456789' 0.000001 -> '6543210123456789' Inexact Rounded +fmax36223 fma 1 '6543210123456789' 0.1 -> '6543210123456789' Inexact Rounded +fmax36224 fma 1 '6543210123456789' 0.4 -> '6543210123456789' Inexact Rounded +fmax36225 fma 1 '6543210123456789' 0.49 -> '6543210123456789' Inexact Rounded +fmax36226 fma 1 '6543210123456789' 0.499999 -> '6543210123456789' Inexact Rounded +fmax36227 fma 1 '6543210123456789' 0.499999 -> '6543210123456789' Inexact Rounded +fmax36228 fma 1 '6543210123456789' 0.5 -> '6543210123456790' Inexact Rounded +fmax36229 fma 1 '6543210123456789' 0.500000001 -> '6543210123456790' Inexact Rounded +fmax36230 fma 1 '6543210123456789' 0.500001 -> '6543210123456790' Inexact Rounded +fmax36231 fma 1 '6543210123456789' 0.51 -> '6543210123456790' Inexact Rounded +fmax36232 fma 1 '6543210123456789' 0.6 -> '6543210123456790' Inexact Rounded +fmax36233 fma 1 '6543210123456789' 0.9 -> '6543210123456790' Inexact Rounded +fmax36234 fma 1 '6543210123456789' 0.99999 -> '6543210123456790' Inexact Rounded +fmax36235 fma 1 '6543210123456789' 0.999999 -> '6543210123456790' Inexact Rounded +fmax36236 fma 1 '6543210123456789' 1 -> '6543210123456790' +fmax36237 fma 1 '6543210123456789' 1.00000001 -> '6543210123456790' Inexact Rounded +fmax36238 fma 1 '6543210123456789' 1.00001 -> '6543210123456790' Inexact Rounded +fmax36239 fma 1 '6543210123456789' 1.1 -> '6543210123456790' Inexact Rounded +-- critical few with even bottom digit... +fmax36240 fma 1 '6543210123456788' 0.499999 -> '6543210123456788' Inexact Rounded +fmax36241 fma 1 '6543210123456788' 0.5 -> '6543210123456788' Inexact Rounded +fmax36242 fma 1 '6543210123456788' 0.500000001 -> '6543210123456789' Inexact Rounded + +rounding: down +fmax36250 fma 1 '6543210123456789' 0 -> '6543210123456789' +fmax36251 fma 1 '6543210123456789' 0.000000001 -> '6543210123456789' Inexact Rounded +fmax36252 fma 1 '6543210123456789' 0.000001 -> '6543210123456789' Inexact Rounded +fmax36253 fma 1 '6543210123456789' 0.1 -> '6543210123456789' Inexact Rounded +fmax36254 fma 1 '6543210123456789' 0.4 -> '6543210123456789' Inexact Rounded +fmax36255 fma 1 '6543210123456789' 0.49 -> '6543210123456789' Inexact Rounded +fmax36256 fma 1 '6543210123456789' 0.499999 -> '6543210123456789' Inexact Rounded +fmax36257 fma 1 '6543210123456789' 0.499999 -> '6543210123456789' Inexact Rounded +fmax36258 fma 1 '6543210123456789' 0.5 -> '6543210123456789' Inexact Rounded +fmax36259 fma 1 '6543210123456789' 0.500000001 -> '6543210123456789' Inexact Rounded +fmax36260 fma 1 '6543210123456789' 0.500001 -> '6543210123456789' Inexact Rounded +fmax36261 fma 1 '6543210123456789' 0.51 -> '6543210123456789' Inexact Rounded +fmax36262 fma 1 '6543210123456789' 0.6 -> '6543210123456789' Inexact Rounded +fmax36263 fma 1 '6543210123456789' 0.9 -> '6543210123456789' Inexact Rounded +fmax36264 fma 1 '6543210123456789' 0.99999 -> '6543210123456789' Inexact Rounded +fmax36265 fma 1 '6543210123456789' 0.999999 -> '6543210123456789' Inexact Rounded +fmax36266 fma 1 '6543210123456789' 1 -> '6543210123456790' +fmax36267 fma 1 '6543210123456789' 1.00000001 -> '6543210123456790' Inexact Rounded +fmax36268 fma 1 '6543210123456789' 1.00001 -> '6543210123456790' Inexact Rounded +fmax36269 fma 1 '6543210123456789' 1.1 -> '6543210123456790' Inexact Rounded + +-- 1 in last place tests +rounding: half_even +fmax36301 fma 1 -1 1 -> 0 +fmax36302 fma 1 0 1 -> 1 +fmax36303 fma 1 1 1 -> 2 +fmax36304 fma 1 12 1 -> 13 +fmax36305 fma 1 98 1 -> 99 +fmax36306 fma 1 99 1 -> 100 +fmax36307 fma 1 100 1 -> 101 +fmax36308 fma 1 101 1 -> 102 +fmax36309 fma 1 -1 -1 -> -2 +fmax36310 fma 1 0 -1 -> -1 +fmax36311 fma 1 1 -1 -> 0 +fmax36312 fma 1 12 -1 -> 11 +fmax36313 fma 1 98 -1 -> 97 +fmax36314 fma 1 99 -1 -> 98 +fmax36315 fma 1 100 -1 -> 99 +fmax36316 fma 1 101 -1 -> 100 + +fmax36321 fma 1 -0.01 0.01 -> 0.00 +fmax36322 fma 1 0.00 0.01 -> 0.01 +fmax36323 fma 1 0.01 0.01 -> 0.02 +fmax36324 fma 1 0.12 0.01 -> 0.13 +fmax36325 fma 1 0.98 0.01 -> 0.99 +fmax36326 fma 1 0.99 0.01 -> 1.00 +fmax36327 fma 1 1.00 0.01 -> 1.01 +fmax36328 fma 1 1.01 0.01 -> 1.02 +fmax36329 fma 1 -0.01 -0.01 -> -0.02 +fmax36330 fma 1 0.00 -0.01 -> -0.01 +fmax36331 fma 1 0.01 -0.01 -> 0.00 +fmax36332 fma 1 0.12 -0.01 -> 0.11 +fmax36333 fma 1 0.98 -0.01 -> 0.97 +fmax36334 fma 1 0.99 -0.01 -> 0.98 +fmax36335 fma 1 1.00 -0.01 -> 0.99 +fmax36336 fma 1 1.01 -0.01 -> 1.00 + +-- some more cases where fma 1 ing 0 affects the coefficient +fmax36340 fma 1 1E+3 0 -> 1000 +fmax36341 fma 1 1E+15 0 -> 1000000000000000 +fmax36342 fma 1 1E+16 0 -> 1.000000000000000E+16 Rounded +fmax36343 fma 1 1E+17 0 -> 1.000000000000000E+17 Rounded +-- which simply follow from these cases ... +fmax36344 fma 1 1E+3 1 -> 1001 +fmax36345 fma 1 1E+15 1 -> 1000000000000001 +fmax36346 fma 1 1E+16 1 -> 1.000000000000000E+16 Inexact Rounded +fmax36347 fma 1 1E+17 1 -> 1.000000000000000E+17 Inexact Rounded +fmax36348 fma 1 1E+3 7 -> 1007 +fmax36349 fma 1 1E+15 7 -> 1000000000000007 +fmax36350 fma 1 1E+16 7 -> 1.000000000000001E+16 Inexact Rounded +fmax36351 fma 1 1E+17 7 -> 1.000000000000000E+17 Inexact Rounded + +-- tryzeros cases +fmax36361 fma 1 0E+50 10000E+1 -> 1.0000E+5 +fmax36362 fma 1 10000E+1 0E-50 -> 100000.0000000000 Rounded +fmax36363 fma 1 10000E+1 10000E-50 -> 100000.0000000000 Rounded Inexact +fmax36364 fma 1 12.34 0e-398 -> 12.34000000000000 Rounded + +-- ulp replacement tests +fmax36400 fma 1 1 77e-14 -> 1.00000000000077 +fmax36401 fma 1 1 77e-15 -> 1.000000000000077 +fmax36402 fma 1 1 77e-16 -> 1.000000000000008 Inexact Rounded +fmax36403 fma 1 1 77e-17 -> 1.000000000000001 Inexact Rounded +fmax36404 fma 1 1 77e-18 -> 1.000000000000000 Inexact Rounded +fmax36405 fma 1 1 77e-19 -> 1.000000000000000 Inexact Rounded +fmax36406 fma 1 1 77e-99 -> 1.000000000000000 Inexact Rounded + +fmax36410 fma 1 10 77e-14 -> 10.00000000000077 +fmax36411 fma 1 10 77e-15 -> 10.00000000000008 Inexact Rounded +fmax36412 fma 1 10 77e-16 -> 10.00000000000001 Inexact Rounded +fmax36413 fma 1 10 77e-17 -> 10.00000000000000 Inexact Rounded +fmax36414 fma 1 10 77e-18 -> 10.00000000000000 Inexact Rounded +fmax36415 fma 1 10 77e-19 -> 10.00000000000000 Inexact Rounded +fmax36416 fma 1 10 77e-99 -> 10.00000000000000 Inexact Rounded + +fmax36420 fma 1 77e-14 1 -> 1.00000000000077 +fmax36421 fma 1 77e-15 1 -> 1.000000000000077 +fmax36422 fma 1 77e-16 1 -> 1.000000000000008 Inexact Rounded +fmax36423 fma 1 77e-17 1 -> 1.000000000000001 Inexact Rounded +fmax36424 fma 1 77e-18 1 -> 1.000000000000000 Inexact Rounded +fmax36425 fma 1 77e-19 1 -> 1.000000000000000 Inexact Rounded +fmax36426 fma 1 77e-99 1 -> 1.000000000000000 Inexact Rounded + +fmax36430 fma 1 77e-14 10 -> 10.00000000000077 +fmax36431 fma 1 77e-15 10 -> 10.00000000000008 Inexact Rounded +fmax36432 fma 1 77e-16 10 -> 10.00000000000001 Inexact Rounded +fmax36433 fma 1 77e-17 10 -> 10.00000000000000 Inexact Rounded +fmax36434 fma 1 77e-18 10 -> 10.00000000000000 Inexact Rounded +fmax36435 fma 1 77e-19 10 -> 10.00000000000000 Inexact Rounded +fmax36436 fma 1 77e-99 10 -> 10.00000000000000 Inexact Rounded + +-- negative ulps +fmax36440 fma 1 1 -77e-14 -> 0.99999999999923 +fmax36441 fma 1 1 -77e-15 -> 0.999999999999923 +fmax36442 fma 1 1 -77e-16 -> 0.9999999999999923 +fmax36443 fma 1 1 -77e-17 -> 0.9999999999999992 Inexact Rounded +fmax36444 fma 1 1 -77e-18 -> 0.9999999999999999 Inexact Rounded +fmax36445 fma 1 1 -77e-19 -> 1.000000000000000 Inexact Rounded +fmax36446 fma 1 1 -77e-99 -> 1.000000000000000 Inexact Rounded + +fmax36450 fma 1 10 -77e-14 -> 9.99999999999923 +fmax36451 fma 1 10 -77e-15 -> 9.999999999999923 +fmax36452 fma 1 10 -77e-16 -> 9.999999999999992 Inexact Rounded +fmax36453 fma 1 10 -77e-17 -> 9.999999999999999 Inexact Rounded +fmax36454 fma 1 10 -77e-18 -> 10.00000000000000 Inexact Rounded +fmax36455 fma 1 10 -77e-19 -> 10.00000000000000 Inexact Rounded +fmax36456 fma 1 10 -77e-99 -> 10.00000000000000 Inexact Rounded + +fmax36460 fma 1 -77e-14 1 -> 0.99999999999923 +fmax36461 fma 1 -77e-15 1 -> 0.999999999999923 +fmax36462 fma 1 -77e-16 1 -> 0.9999999999999923 +fmax36463 fma 1 -77e-17 1 -> 0.9999999999999992 Inexact Rounded +fmax36464 fma 1 -77e-18 1 -> 0.9999999999999999 Inexact Rounded +fmax36465 fma 1 -77e-19 1 -> 1.000000000000000 Inexact Rounded +fmax36466 fma 1 -77e-99 1 -> 1.000000000000000 Inexact Rounded + +fmax36470 fma 1 -77e-14 10 -> 9.99999999999923 +fmax36471 fma 1 -77e-15 10 -> 9.999999999999923 +fmax36472 fma 1 -77e-16 10 -> 9.999999999999992 Inexact Rounded +fmax36473 fma 1 -77e-17 10 -> 9.999999999999999 Inexact Rounded +fmax36474 fma 1 -77e-18 10 -> 10.00000000000000 Inexact Rounded +fmax36475 fma 1 -77e-19 10 -> 10.00000000000000 Inexact Rounded +fmax36476 fma 1 -77e-99 10 -> 10.00000000000000 Inexact Rounded + +-- negative ulps +fmax36480 fma 1 -1 77e-14 -> -0.99999999999923 +fmax36481 fma 1 -1 77e-15 -> -0.999999999999923 +fmax36482 fma 1 -1 77e-16 -> -0.9999999999999923 +fmax36483 fma 1 -1 77e-17 -> -0.9999999999999992 Inexact Rounded +fmax36484 fma 1 -1 77e-18 -> -0.9999999999999999 Inexact Rounded +fmax36485 fma 1 -1 77e-19 -> -1.000000000000000 Inexact Rounded +fmax36486 fma 1 -1 77e-99 -> -1.000000000000000 Inexact Rounded + +fmax36490 fma 1 -10 77e-14 -> -9.99999999999923 +fmax36491 fma 1 -10 77e-15 -> -9.999999999999923 +fmax36492 fma 1 -10 77e-16 -> -9.999999999999992 Inexact Rounded +fmax36493 fma 1 -10 77e-17 -> -9.999999999999999 Inexact Rounded +fmax36494 fma 1 -10 77e-18 -> -10.00000000000000 Inexact Rounded +fmax36495 fma 1 -10 77e-19 -> -10.00000000000000 Inexact Rounded +fmax36496 fma 1 -10 77e-99 -> -10.00000000000000 Inexact Rounded + +fmax36500 fma 1 77e-14 -1 -> -0.99999999999923 +fmax36501 fma 1 77e-15 -1 -> -0.999999999999923 +fmax36502 fma 1 77e-16 -1 -> -0.9999999999999923 +fmax36503 fma 1 77e-17 -1 -> -0.9999999999999992 Inexact Rounded +fmax36504 fma 1 77e-18 -1 -> -0.9999999999999999 Inexact Rounded +fmax36505 fma 1 77e-19 -1 -> -1.000000000000000 Inexact Rounded +fmax36506 fma 1 77e-99 -1 -> -1.000000000000000 Inexact Rounded + +fmax36510 fma 1 77e-14 -10 -> -9.99999999999923 +fmax36511 fma 1 77e-15 -10 -> -9.999999999999923 +fmax36512 fma 1 77e-16 -10 -> -9.999999999999992 Inexact Rounded +fmax36513 fma 1 77e-17 -10 -> -9.999999999999999 Inexact Rounded +fmax36514 fma 1 77e-18 -10 -> -10.00000000000000 Inexact Rounded +fmax36515 fma 1 77e-19 -10 -> -10.00000000000000 Inexact Rounded +fmax36516 fma 1 77e-99 -10 -> -10.00000000000000 Inexact Rounded + + +-- long operands +fmax36521 fma 1 101234562345678000 0 -> 1.012345623456780E+17 Rounded +fmax36522 fma 1 0 101234562345678000 -> 1.012345623456780E+17 Rounded +fmax36523 fma 1 10123456234567800 0 -> 1.012345623456780E+16 Rounded +fmax36524 fma 1 0 10123456234567800 -> 1.012345623456780E+16 Rounded +fmax36525 fma 1 10123456234567890 0 -> 1.012345623456789E+16 Rounded +fmax36526 fma 1 0 10123456234567890 -> 1.012345623456789E+16 Rounded +fmax36527 fma 1 10123456234567891 0 -> 1.012345623456789E+16 Inexact Rounded +fmax36528 fma 1 0 10123456234567891 -> 1.012345623456789E+16 Inexact Rounded +fmax36529 fma 1 101234562345678901 0 -> 1.012345623456789E+17 Inexact Rounded +fmax36530 fma 1 0 101234562345678901 -> 1.012345623456789E+17 Inexact Rounded +fmax36531 fma 1 10123456234567896 0 -> 1.012345623456790E+16 Inexact Rounded +fmax36532 fma 1 0 10123456234567896 -> 1.012345623456790E+16 Inexact Rounded + +-- verify a query +rounding: down +fmax36561 fma 1 1e-398 9.000000000000000E+384 -> 9.000000000000000E+384 Inexact Rounded +fmax36562 fma 1 0 9.000000000000000E+384 -> 9.000000000000000E+384 Rounded +-- and using decimal64 bounds... +rounding: down +fmax36563 fma 1 1e-388 9.000000000000000E+374 -> 9.000000000000000E+374 Inexact Rounded +fmax36564 fma 1 0 9.000000000000000E+374 -> 9.000000000000000E+374 Rounded + +-- more zeros, etc. +rounding: half_even + +fmax36701 fma 1 5.00 1.00E-3 -> 5.00100 +fmax36702 fma 1 00.00 0.000 -> 0.000 +fmax36703 fma 1 00.00 0E-3 -> 0.000 +fmax36704 fma 1 0E-3 00.00 -> 0.000 + +fmax36710 fma 1 0E+3 00.00 -> 0.00 +fmax36711 fma 1 0E+3 00.0 -> 0.0 +fmax36712 fma 1 0E+3 00. -> 0 +fmax36713 fma 1 0E+3 00.E+1 -> 0E+1 +fmax36714 fma 1 0E+3 00.E+2 -> 0E+2 +fmax36715 fma 1 0E+3 00.E+3 -> 0E+3 +fmax36716 fma 1 0E+3 00.E+4 -> 0E+3 +fmax36717 fma 1 0E+3 00.E+5 -> 0E+3 +fmax36718 fma 1 0E+3 -00.0 -> 0.0 +fmax36719 fma 1 0E+3 -00. -> 0 +fmax36731 fma 1 0E+3 -00.E+1 -> 0E+1 + +fmax36720 fma 1 00.00 0E+3 -> 0.00 +fmax36721 fma 1 00.0 0E+3 -> 0.0 +fmax36722 fma 1 00. 0E+3 -> 0 +fmax36723 fma 1 00.E+1 0E+3 -> 0E+1 +fmax36724 fma 1 00.E+2 0E+3 -> 0E+2 +fmax36725 fma 1 00.E+3 0E+3 -> 0E+3 +fmax36726 fma 1 00.E+4 0E+3 -> 0E+3 +fmax36727 fma 1 00.E+5 0E+3 -> 0E+3 +fmax36728 fma 1 -00.00 0E+3 -> 0.00 +fmax36729 fma 1 -00.0 0E+3 -> 0.0 +fmax36730 fma 1 -00. 0E+3 -> 0 + +fmax36732 fma 1 0 0 -> 0 +fmax36733 fma 1 0 -0 -> 0 +fmax36734 fma 1 -0 0 -> 0 +fmax36735 fma 1 -0 -0 -> -0 -- IEEE 854 special case + +fmax36736 fma 1 1 -1 -> 0 +fmax36737 fma 1 -1 -1 -> -2 +fmax36738 fma 1 1 1 -> 2 +fmax36739 fma 1 -1 1 -> 0 + +fmax36741 fma 1 0 -1 -> -1 +fmax36742 fma 1 -0 -1 -> -1 +fmax36743 fma 1 0 1 -> 1 +fmax36744 fma 1 -0 1 -> 1 +fmax36745 fma 1 -1 0 -> -1 +fmax36746 fma 1 -1 -0 -> -1 +fmax36747 fma 1 1 0 -> 1 +fmax36748 fma 1 1 -0 -> 1 + +fmax36751 fma 1 0.0 -1 -> -1.0 +fmax36752 fma 1 -0.0 -1 -> -1.0 +fmax36753 fma 1 0.0 1 -> 1.0 +fmax36754 fma 1 -0.0 1 -> 1.0 +fmax36755 fma 1 -1.0 0 -> -1.0 +fmax36756 fma 1 -1.0 -0 -> -1.0 +fmax36757 fma 1 1.0 0 -> 1.0 +fmax36758 fma 1 1.0 -0 -> 1.0 + +fmax36761 fma 1 0 -1.0 -> -1.0 +fmax36762 fma 1 -0 -1.0 -> -1.0 +fmax36763 fma 1 0 1.0 -> 1.0 +fmax36764 fma 1 -0 1.0 -> 1.0 +fmax36765 fma 1 -1 0.0 -> -1.0 +fmax36766 fma 1 -1 -0.0 -> -1.0 +fmax36767 fma 1 1 0.0 -> 1.0 +fmax36768 fma 1 1 -0.0 -> 1.0 + +fmax36771 fma 1 0.0 -1.0 -> -1.0 +fmax36772 fma 1 -0.0 -1.0 -> -1.0 +fmax36773 fma 1 0.0 1.0 -> 1.0 +fmax36774 fma 1 -0.0 1.0 -> 1.0 +fmax36775 fma 1 -1.0 0.0 -> -1.0 +fmax36776 fma 1 -1.0 -0.0 -> -1.0 +fmax36777 fma 1 1.0 0.0 -> 1.0 +fmax36778 fma 1 1.0 -0.0 -> 1.0 + +-- Specials +fmax36780 fma 1 -Inf -Inf -> -Infinity +fmax36781 fma 1 -Inf -1000 -> -Infinity +fmax36782 fma 1 -Inf -1 -> -Infinity +fmax36783 fma 1 -Inf -0 -> -Infinity +fmax36784 fma 1 -Inf 0 -> -Infinity +fmax36785 fma 1 -Inf 1 -> -Infinity +fmax36786 fma 1 -Inf 1000 -> -Infinity +fmax36787 fma 1 -1000 -Inf -> -Infinity +fmax36788 fma 1 -Inf -Inf -> -Infinity +fmax36789 fma 1 -1 -Inf -> -Infinity +fmax36790 fma 1 -0 -Inf -> -Infinity +fmax36791 fma 1 0 -Inf -> -Infinity +fmax36792 fma 1 1 -Inf -> -Infinity +fmax36793 fma 1 1000 -Inf -> -Infinity +fmax36794 fma 1 Inf -Inf -> NaN Invalid_operation + +fmax36800 fma 1 Inf -Inf -> NaN Invalid_operation +fmax36801 fma 1 Inf -1000 -> Infinity +fmax36802 fma 1 Inf -1 -> Infinity +fmax36803 fma 1 Inf -0 -> Infinity +fmax36804 fma 1 Inf 0 -> Infinity +fmax36805 fma 1 Inf 1 -> Infinity +fmax36806 fma 1 Inf 1000 -> Infinity +fmax36807 fma 1 Inf Inf -> Infinity +fmax36808 fma 1 -1000 Inf -> Infinity +fmax36809 fma 1 -Inf Inf -> NaN Invalid_operation +fmax36810 fma 1 -1 Inf -> Infinity +fmax36811 fma 1 -0 Inf -> Infinity +fmax36812 fma 1 0 Inf -> Infinity +fmax36813 fma 1 1 Inf -> Infinity +fmax36814 fma 1 1000 Inf -> Infinity +fmax36815 fma 1 Inf Inf -> Infinity + +fmax36821 fma 1 NaN -Inf -> NaN +fmax36822 fma 1 NaN -1000 -> NaN +fmax36823 fma 1 NaN -1 -> NaN +fmax36824 fma 1 NaN -0 -> NaN +fmax36825 fma 1 NaN 0 -> NaN +fmax36826 fma 1 NaN 1 -> NaN +fmax36827 fma 1 NaN 1000 -> NaN +fmax36828 fma 1 NaN Inf -> NaN +fmax36829 fma 1 NaN NaN -> NaN +fmax36830 fma 1 -Inf NaN -> NaN +fmax36831 fma 1 -1000 NaN -> NaN +fmax36832 fma 1 -1 NaN -> NaN +fmax36833 fma 1 -0 NaN -> NaN +fmax36834 fma 1 0 NaN -> NaN +fmax36835 fma 1 1 NaN -> NaN +fmax36836 fma 1 1000 NaN -> NaN +fmax36837 fma 1 Inf NaN -> NaN + +fmax36841 fma 1 sNaN -Inf -> NaN Invalid_operation +fmax36842 fma 1 sNaN -1000 -> NaN Invalid_operation +fmax36843 fma 1 sNaN -1 -> NaN Invalid_operation +fmax36844 fma 1 sNaN -0 -> NaN Invalid_operation +fmax36845 fma 1 sNaN 0 -> NaN Invalid_operation +fmax36846 fma 1 sNaN 1 -> NaN Invalid_operation +fmax36847 fma 1 sNaN 1000 -> NaN Invalid_operation +fmax36848 fma 1 sNaN NaN -> NaN Invalid_operation +fmax36849 fma 1 sNaN sNaN -> NaN Invalid_operation +fmax36850 fma 1 NaN sNaN -> NaN Invalid_operation +fmax36851 fma 1 -Inf sNaN -> NaN Invalid_operation +fmax36852 fma 1 -1000 sNaN -> NaN Invalid_operation +fmax36853 fma 1 -1 sNaN -> NaN Invalid_operation +fmax36854 fma 1 -0 sNaN -> NaN Invalid_operation +fmax36855 fma 1 0 sNaN -> NaN Invalid_operation +fmax36856 fma 1 1 sNaN -> NaN Invalid_operation +fmax36857 fma 1 1000 sNaN -> NaN Invalid_operation +fmax36858 fma 1 Inf sNaN -> NaN Invalid_operation +fmax36859 fma 1 NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +fmax36861 fma 1 NaN1 -Inf -> NaN1 +fmax36862 fma 1 +NaN2 -1000 -> NaN2 +fmax36863 fma 1 NaN3 1000 -> NaN3 +fmax36864 fma 1 NaN4 Inf -> NaN4 +fmax36865 fma 1 NaN5 +NaN6 -> NaN5 +fmax36866 fma 1 -Inf NaN7 -> NaN7 +fmax36867 fma 1 -1000 NaN8 -> NaN8 +fmax36868 fma 1 1000 NaN9 -> NaN9 +fmax36869 fma 1 Inf +NaN10 -> NaN10 +fmax36871 fma 1 sNaN11 -Inf -> NaN11 Invalid_operation +fmax36872 fma 1 sNaN12 -1000 -> NaN12 Invalid_operation +fmax36873 fma 1 sNaN13 1000 -> NaN13 Invalid_operation +fmax36874 fma 1 sNaN14 NaN17 -> NaN14 Invalid_operation +fmax36875 fma 1 sNaN15 sNaN18 -> NaN15 Invalid_operation +fmax36876 fma 1 NaN16 sNaN19 -> NaN19 Invalid_operation +fmax36877 fma 1 -Inf +sNaN20 -> NaN20 Invalid_operation +fmax36878 fma 1 -1000 sNaN21 -> NaN21 Invalid_operation +fmax36879 fma 1 1000 sNaN22 -> NaN22 Invalid_operation +fmax36880 fma 1 Inf sNaN23 -> NaN23 Invalid_operation +fmax36881 fma 1 +NaN25 +sNaN24 -> NaN24 Invalid_operation +fmax36882 fma 1 -NaN26 NaN28 -> -NaN26 +fmax36883 fma 1 -sNaN27 sNaN29 -> -NaN27 Invalid_operation +fmax36884 fma 1 1000 -NaN30 -> -NaN30 +fmax36885 fma 1 1000 -sNaN31 -> -NaN31 Invalid_operation + +-- now the case where we can get underflow but the result is normal +-- [note this can't happen if the operands are also bounded, as we +-- cannot represent 1E-399, for example] + +fmax36571 fma 1 1E-383 0 -> 1E-383 +fmax36572 fma 1 1E-384 0 -> 1E-384 Subnormal +fmax36573 fma 1 1E-383 1E-384 -> 1.1E-383 +fmax36574 subtract 1E-383 1E-384 -> 9E-384 Subnormal + +-- Here we explore the boundary of rounding a subnormal to Nmin +fmax36575 subtract 1E-383 1E-398 -> 9.99999999999999E-384 Subnormal +fmax36576 subtract 1E-383 1E-398 -> 9.99999999999999E-384 Subnormal +fmax36577 subtract 1E-383 1E-399 -> 1.000000000000000E-383 Underflow Inexact Subnormal Rounded +fmax36578 subtract 1E-383 1E-400 -> 1.000000000000000E-383 Underflow Inexact Subnormal Rounded +fmax36579 subtract 1E-383 1E-401 -> 1.000000000000000E-383 Underflow Inexact Subnormal Rounded +fmax36580 subtract 1E-383 1E-402 -> 1.000000000000000E-383 Underflow Inexact Subnormal Rounded + +-- check overflow edge case +-- 1234567890123456 +fmax36972 apply 9.999999999999999E+384 -> 9.999999999999999E+384 +fmax36973 fma 1 9.999999999999999E+384 1 -> 9.999999999999999E+384 Inexact Rounded +fmax36974 fma 1 9999999999999999E+369 1 -> 9.999999999999999E+384 Inexact Rounded +fmax36975 fma 1 9999999999999999E+369 1E+369 -> Infinity Overflow Inexact Rounded +fmax36976 fma 1 9999999999999999E+369 9E+368 -> Infinity Overflow Inexact Rounded +fmax36977 fma 1 9999999999999999E+369 8E+368 -> Infinity Overflow Inexact Rounded +fmax36978 fma 1 9999999999999999E+369 7E+368 -> Infinity Overflow Inexact Rounded +fmax36979 fma 1 9999999999999999E+369 6E+368 -> Infinity Overflow Inexact Rounded +fmax36980 fma 1 9999999999999999E+369 5E+368 -> Infinity Overflow Inexact Rounded +fmax36981 fma 1 9999999999999999E+369 4E+368 -> 9.999999999999999E+384 Inexact Rounded +fmax36982 fma 1 9999999999999999E+369 3E+368 -> 9.999999999999999E+384 Inexact Rounded +fmax36983 fma 1 9999999999999999E+369 2E+368 -> 9.999999999999999E+384 Inexact Rounded +fmax36984 fma 1 9999999999999999E+369 1E+368 -> 9.999999999999999E+384 Inexact Rounded + +fmax36985 apply -9.999999999999999E+384 -> -9.999999999999999E+384 +fmax36986 fma 1 -9.999999999999999E+384 -1 -> -9.999999999999999E+384 Inexact Rounded +fmax36987 fma 1 -9999999999999999E+369 -1 -> -9.999999999999999E+384 Inexact Rounded +fmax36988 fma 1 -9999999999999999E+369 -1E+369 -> -Infinity Overflow Inexact Rounded +fmax36989 fma 1 -9999999999999999E+369 -9E+368 -> -Infinity Overflow Inexact Rounded +fmax36990 fma 1 -9999999999999999E+369 -8E+368 -> -Infinity Overflow Inexact Rounded +fmax36991 fma 1 -9999999999999999E+369 -7E+368 -> -Infinity Overflow Inexact Rounded +fmax36992 fma 1 -9999999999999999E+369 -6E+368 -> -Infinity Overflow Inexact Rounded +fmax36993 fma 1 -9999999999999999E+369 -5E+368 -> -Infinity Overflow Inexact Rounded +fmax36994 fma 1 -9999999999999999E+369 -4E+368 -> -9.999999999999999E+384 Inexact Rounded +fmax36995 fma 1 -9999999999999999E+369 -3E+368 -> -9.999999999999999E+384 Inexact Rounded +fmax36996 fma 1 -9999999999999999E+369 -2E+368 -> -9.999999999999999E+384 Inexact Rounded +fmax36997 fma 1 -9999999999999999E+369 -1E+368 -> -9.999999999999999E+384 Inexact Rounded + +-- And for round down full and subnormal results +rounding: down +fmax361100 fma 1 1e+2 -1e-383 -> 99.99999999999999 Rounded Inexact +fmax361101 fma 1 1e+1 -1e-383 -> 9.999999999999999 Rounded Inexact +fmax361103 fma 1 +1 -1e-383 -> 0.9999999999999999 Rounded Inexact +fmax361104 fma 1 1e-1 -1e-383 -> 0.09999999999999999 Rounded Inexact +fmax361105 fma 1 1e-2 -1e-383 -> 0.009999999999999999 Rounded Inexact +fmax361106 fma 1 1e-3 -1e-383 -> 0.0009999999999999999 Rounded Inexact +fmax361107 fma 1 1e-4 -1e-383 -> 0.00009999999999999999 Rounded Inexact +fmax361108 fma 1 1e-5 -1e-383 -> 0.000009999999999999999 Rounded Inexact +fmax361109 fma 1 1e-6 -1e-383 -> 9.999999999999999E-7 Rounded Inexact + +rounding: ceiling +fmax361110 fma 1 -1e+2 +1e-383 -> -99.99999999999999 Rounded Inexact +fmax361111 fma 1 -1e+1 +1e-383 -> -9.999999999999999 Rounded Inexact +fmax361113 fma 1 -1 +1e-383 -> -0.9999999999999999 Rounded Inexact +fmax361114 fma 1 -1e-1 +1e-383 -> -0.09999999999999999 Rounded Inexact +fmax361115 fma 1 -1e-2 +1e-383 -> -0.009999999999999999 Rounded Inexact +fmax361116 fma 1 -1e-3 +1e-383 -> -0.0009999999999999999 Rounded Inexact +fmax361117 fma 1 -1e-4 +1e-383 -> -0.00009999999999999999 Rounded Inexact +fmax361118 fma 1 -1e-5 +1e-383 -> -0.000009999999999999999 Rounded Inexact +fmax361119 fma 1 -1e-6 +1e-383 -> -9.999999999999999E-7 Rounded Inexact + +-- tests based on Gunnar Degnbol's edge case +rounding: half_even + +fmax361300 fma 1 1E16 -0.5 -> 1.000000000000000E+16 Inexact Rounded +fmax361310 fma 1 1E16 -0.51 -> 9999999999999999 Inexact Rounded +fmax361311 fma 1 1E16 -0.501 -> 9999999999999999 Inexact Rounded +fmax361312 fma 1 1E16 -0.5001 -> 9999999999999999 Inexact Rounded +fmax361313 fma 1 1E16 -0.50001 -> 9999999999999999 Inexact Rounded +fmax361314 fma 1 1E16 -0.500001 -> 9999999999999999 Inexact Rounded +fmax361315 fma 1 1E16 -0.5000001 -> 9999999999999999 Inexact Rounded +fmax361316 fma 1 1E16 -0.50000001 -> 9999999999999999 Inexact Rounded +fmax361317 fma 1 1E16 -0.500000001 -> 9999999999999999 Inexact Rounded +fmax361318 fma 1 1E16 -0.5000000001 -> 9999999999999999 Inexact Rounded +fmax361319 fma 1 1E16 -0.50000000001 -> 9999999999999999 Inexact Rounded +fmax361320 fma 1 1E16 -0.500000000001 -> 9999999999999999 Inexact Rounded +fmax361321 fma 1 1E16 -0.5000000000001 -> 9999999999999999 Inexact Rounded +fmax361322 fma 1 1E16 -0.50000000000001 -> 9999999999999999 Inexact Rounded +fmax361323 fma 1 1E16 -0.500000000000001 -> 9999999999999999 Inexact Rounded +fmax361324 fma 1 1E16 -0.5000000000000001 -> 9999999999999999 Inexact Rounded +fmax361325 fma 1 1E16 -0.5000000000000000 -> 1.000000000000000E+16 Inexact Rounded +fmax361326 fma 1 1E16 -0.500000000000000 -> 1.000000000000000E+16 Inexact Rounded +fmax361327 fma 1 1E16 -0.50000000000000 -> 1.000000000000000E+16 Inexact Rounded +fmax361328 fma 1 1E16 -0.5000000000000 -> 1.000000000000000E+16 Inexact Rounded +fmax361329 fma 1 1E16 -0.500000000000 -> 1.000000000000000E+16 Inexact Rounded +fmax361330 fma 1 1E16 -0.50000000000 -> 1.000000000000000E+16 Inexact Rounded +fmax361331 fma 1 1E16 -0.5000000000 -> 1.000000000000000E+16 Inexact Rounded +fmax361332 fma 1 1E16 -0.500000000 -> 1.000000000000000E+16 Inexact Rounded +fmax361333 fma 1 1E16 -0.50000000 -> 1.000000000000000E+16 Inexact Rounded +fmax361334 fma 1 1E16 -0.5000000 -> 1.000000000000000E+16 Inexact Rounded +fmax361335 fma 1 1E16 -0.500000 -> 1.000000000000000E+16 Inexact Rounded +fmax361336 fma 1 1E16 -0.50000 -> 1.000000000000000E+16 Inexact Rounded +fmax361337 fma 1 1E16 -0.5000 -> 1.000000000000000E+16 Inexact Rounded +fmax361338 fma 1 1E16 -0.500 -> 1.000000000000000E+16 Inexact Rounded +fmax361339 fma 1 1E16 -0.50 -> 1.000000000000000E+16 Inexact Rounded + +fmax361340 fma 1 1E16 -5000000.000010001 -> 9999999995000000 Inexact Rounded +fmax361341 fma 1 1E16 -5000000.000000001 -> 9999999995000000 Inexact Rounded + +fmax361349 fma 1 9999999999999999 0.4 -> 9999999999999999 Inexact Rounded +fmax361350 fma 1 9999999999999999 0.49 -> 9999999999999999 Inexact Rounded +fmax361351 fma 1 9999999999999999 0.499 -> 9999999999999999 Inexact Rounded +fmax361352 fma 1 9999999999999999 0.4999 -> 9999999999999999 Inexact Rounded +fmax361353 fma 1 9999999999999999 0.49999 -> 9999999999999999 Inexact Rounded +fmax361354 fma 1 9999999999999999 0.499999 -> 9999999999999999 Inexact Rounded +fmax361355 fma 1 9999999999999999 0.4999999 -> 9999999999999999 Inexact Rounded +fmax361356 fma 1 9999999999999999 0.49999999 -> 9999999999999999 Inexact Rounded +fmax361357 fma 1 9999999999999999 0.499999999 -> 9999999999999999 Inexact Rounded +fmax361358 fma 1 9999999999999999 0.4999999999 -> 9999999999999999 Inexact Rounded +fmax361359 fma 1 9999999999999999 0.49999999999 -> 9999999999999999 Inexact Rounded +fmax361360 fma 1 9999999999999999 0.499999999999 -> 9999999999999999 Inexact Rounded +fmax361361 fma 1 9999999999999999 0.4999999999999 -> 9999999999999999 Inexact Rounded +fmax361362 fma 1 9999999999999999 0.49999999999999 -> 9999999999999999 Inexact Rounded +fmax361363 fma 1 9999999999999999 0.499999999999999 -> 9999999999999999 Inexact Rounded +fmax361364 fma 1 9999999999999999 0.4999999999999999 -> 9999999999999999 Inexact Rounded +fmax361365 fma 1 9999999999999999 0.5000000000000000 -> 1.000000000000000E+16 Inexact Rounded +fmax361367 fma 1 9999999999999999 0.500000000000000 -> 1.000000000000000E+16 Inexact Rounded +fmax361368 fma 1 9999999999999999 0.50000000000000 -> 1.000000000000000E+16 Inexact Rounded +fmax361369 fma 1 9999999999999999 0.5000000000000 -> 1.000000000000000E+16 Inexact Rounded +fmax361370 fma 1 9999999999999999 0.500000000000 -> 1.000000000000000E+16 Inexact Rounded +fmax361371 fma 1 9999999999999999 0.50000000000 -> 1.000000000000000E+16 Inexact Rounded +fmax361372 fma 1 9999999999999999 0.5000000000 -> 1.000000000000000E+16 Inexact Rounded +fmax361373 fma 1 9999999999999999 0.500000000 -> 1.000000000000000E+16 Inexact Rounded +fmax361374 fma 1 9999999999999999 0.50000000 -> 1.000000000000000E+16 Inexact Rounded +fmax361375 fma 1 9999999999999999 0.5000000 -> 1.000000000000000E+16 Inexact Rounded +fmax361376 fma 1 9999999999999999 0.500000 -> 1.000000000000000E+16 Inexact Rounded +fmax361377 fma 1 9999999999999999 0.50000 -> 1.000000000000000E+16 Inexact Rounded +fmax361378 fma 1 9999999999999999 0.5000 -> 1.000000000000000E+16 Inexact Rounded +fmax361379 fma 1 9999999999999999 0.500 -> 1.000000000000000E+16 Inexact Rounded +fmax361380 fma 1 9999999999999999 0.50 -> 1.000000000000000E+16 Inexact Rounded +fmax361381 fma 1 9999999999999999 0.5 -> 1.000000000000000E+16 Inexact Rounded +fmax361382 fma 1 9999999999999999 0.5000000000000001 -> 1.000000000000000E+16 Inexact Rounded +fmax361383 fma 1 9999999999999999 0.500000000000001 -> 1.000000000000000E+16 Inexact Rounded +fmax361384 fma 1 9999999999999999 0.50000000000001 -> 1.000000000000000E+16 Inexact Rounded +fmax361385 fma 1 9999999999999999 0.5000000000001 -> 1.000000000000000E+16 Inexact Rounded +fmax361386 fma 1 9999999999999999 0.500000000001 -> 1.000000000000000E+16 Inexact Rounded +fmax361387 fma 1 9999999999999999 0.50000000001 -> 1.000000000000000E+16 Inexact Rounded +fmax361388 fma 1 9999999999999999 0.5000000001 -> 1.000000000000000E+16 Inexact Rounded +fmax361389 fma 1 9999999999999999 0.500000001 -> 1.000000000000000E+16 Inexact Rounded +fmax361390 fma 1 9999999999999999 0.50000001 -> 1.000000000000000E+16 Inexact Rounded +fmax361391 fma 1 9999999999999999 0.5000001 -> 1.000000000000000E+16 Inexact Rounded +fmax361392 fma 1 9999999999999999 0.500001 -> 1.000000000000000E+16 Inexact Rounded +fmax361393 fma 1 9999999999999999 0.50001 -> 1.000000000000000E+16 Inexact Rounded +fmax361394 fma 1 9999999999999999 0.5001 -> 1.000000000000000E+16 Inexact Rounded +fmax361395 fma 1 9999999999999999 0.501 -> 1.000000000000000E+16 Inexact Rounded +fmax361396 fma 1 9999999999999999 0.51 -> 1.000000000000000E+16 Inexact Rounded + +-- More GD edge cases, where difference between the unadjusted +-- exponents is larger than the maximum precision and one side is 0 +fmax361420 fma 1 0 1.123456789012345 -> 1.123456789012345 +fmax361421 fma 1 0 1.123456789012345E-1 -> 0.1123456789012345 +fmax361422 fma 1 0 1.123456789012345E-2 -> 0.01123456789012345 +fmax361423 fma 1 0 1.123456789012345E-3 -> 0.001123456789012345 +fmax361424 fma 1 0 1.123456789012345E-4 -> 0.0001123456789012345 +fmax361425 fma 1 0 1.123456789012345E-5 -> 0.00001123456789012345 +fmax361426 fma 1 0 1.123456789012345E-6 -> 0.000001123456789012345 +fmax361427 fma 1 0 1.123456789012345E-7 -> 1.123456789012345E-7 +fmax361428 fma 1 0 1.123456789012345E-8 -> 1.123456789012345E-8 +fmax361429 fma 1 0 1.123456789012345E-9 -> 1.123456789012345E-9 +fmax361430 fma 1 0 1.123456789012345E-10 -> 1.123456789012345E-10 +fmax361431 fma 1 0 1.123456789012345E-11 -> 1.123456789012345E-11 +fmax361432 fma 1 0 1.123456789012345E-12 -> 1.123456789012345E-12 +fmax361433 fma 1 0 1.123456789012345E-13 -> 1.123456789012345E-13 +fmax361434 fma 1 0 1.123456789012345E-14 -> 1.123456789012345E-14 +fmax361435 fma 1 0 1.123456789012345E-15 -> 1.123456789012345E-15 +fmax361436 fma 1 0 1.123456789012345E-16 -> 1.123456789012345E-16 +fmax361437 fma 1 0 1.123456789012345E-17 -> 1.123456789012345E-17 +fmax361438 fma 1 0 1.123456789012345E-18 -> 1.123456789012345E-18 +fmax361439 fma 1 0 1.123456789012345E-19 -> 1.123456789012345E-19 + +-- same, reversed 0 +fmax361440 fma 1 1.123456789012345 0 -> 1.123456789012345 +fmax361441 fma 1 1.123456789012345E-1 0 -> 0.1123456789012345 +fmax361442 fma 1 1.123456789012345E-2 0 -> 0.01123456789012345 +fmax361443 fma 1 1.123456789012345E-3 0 -> 0.001123456789012345 +fmax361444 fma 1 1.123456789012345E-4 0 -> 0.0001123456789012345 +fmax361445 fma 1 1.123456789012345E-5 0 -> 0.00001123456789012345 +fmax361446 fma 1 1.123456789012345E-6 0 -> 0.000001123456789012345 +fmax361447 fma 1 1.123456789012345E-7 0 -> 1.123456789012345E-7 +fmax361448 fma 1 1.123456789012345E-8 0 -> 1.123456789012345E-8 +fmax361449 fma 1 1.123456789012345E-9 0 -> 1.123456789012345E-9 +fmax361450 fma 1 1.123456789012345E-10 0 -> 1.123456789012345E-10 +fmax361451 fma 1 1.123456789012345E-11 0 -> 1.123456789012345E-11 +fmax361452 fma 1 1.123456789012345E-12 0 -> 1.123456789012345E-12 +fmax361453 fma 1 1.123456789012345E-13 0 -> 1.123456789012345E-13 +fmax361454 fma 1 1.123456789012345E-14 0 -> 1.123456789012345E-14 +fmax361455 fma 1 1.123456789012345E-15 0 -> 1.123456789012345E-15 +fmax361456 fma 1 1.123456789012345E-16 0 -> 1.123456789012345E-16 +fmax361457 fma 1 1.123456789012345E-17 0 -> 1.123456789012345E-17 +fmax361458 fma 1 1.123456789012345E-18 0 -> 1.123456789012345E-18 +fmax361459 fma 1 1.123456789012345E-19 0 -> 1.123456789012345E-19 + +-- same, Es on the 0 +fmax361460 fma 1 1.123456789012345 0E-0 -> 1.123456789012345 +fmax361461 fma 1 1.123456789012345 0E-1 -> 1.123456789012345 +fmax361462 fma 1 1.123456789012345 0E-2 -> 1.123456789012345 +fmax361463 fma 1 1.123456789012345 0E-3 -> 1.123456789012345 +fmax361464 fma 1 1.123456789012345 0E-4 -> 1.123456789012345 +fmax361465 fma 1 1.123456789012345 0E-5 -> 1.123456789012345 +fmax361466 fma 1 1.123456789012345 0E-6 -> 1.123456789012345 +fmax361467 fma 1 1.123456789012345 0E-7 -> 1.123456789012345 +fmax361468 fma 1 1.123456789012345 0E-8 -> 1.123456789012345 +fmax361469 fma 1 1.123456789012345 0E-9 -> 1.123456789012345 +fmax361470 fma 1 1.123456789012345 0E-10 -> 1.123456789012345 +fmax361471 fma 1 1.123456789012345 0E-11 -> 1.123456789012345 +fmax361472 fma 1 1.123456789012345 0E-12 -> 1.123456789012345 +fmax361473 fma 1 1.123456789012345 0E-13 -> 1.123456789012345 +fmax361474 fma 1 1.123456789012345 0E-14 -> 1.123456789012345 +fmax361475 fma 1 1.123456789012345 0E-15 -> 1.123456789012345 +-- next four flag Rounded because the 0 extends the result +fmax361476 fma 1 1.123456789012345 0E-16 -> 1.123456789012345 Rounded +fmax361477 fma 1 1.123456789012345 0E-17 -> 1.123456789012345 Rounded +fmax361478 fma 1 1.123456789012345 0E-18 -> 1.123456789012345 Rounded +fmax361479 fma 1 1.123456789012345 0E-19 -> 1.123456789012345 Rounded + +-- sum of two opposite-sign operands is exactly 0 and floor => -0 +rounding: half_up +-- exact zeros from zeros +fmax361500 fma 1 0 0E-19 -> 0E-19 +fmax361501 fma 1 -0 0E-19 -> 0E-19 +fmax361502 fma 1 0 -0E-19 -> 0E-19 +fmax361503 fma 1 -0 -0E-19 -> -0E-19 +fmax361504 fma 1 0E-400 0E-19 -> 0E-398 Clamped +fmax361505 fma 1 -0E-400 0E-19 -> 0E-398 Clamped +fmax361506 fma 1 0E-400 -0E-19 -> 0E-398 Clamped +fmax361507 fma 1 -0E-400 -0E-19 -> -0E-398 Clamped +-- inexact zeros +fmax361511 fma 1 1E-401 1E-400 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +fmax361512 fma 1 -1E-401 1E-400 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +fmax361513 fma 1 1E-401 -1E-400 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped +fmax361514 fma 1 -1E-401 -1E-400 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped +-- some exact zeros from non-zeros +fmax361515 fma 1 1E-401 1E-401 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +fmax361516 fma 1 -1E-401 1E-401 -> 0E-398 Clamped +fmax361517 fma 1 1E-401 -1E-401 -> 0E-398 Clamped +fmax361518 fma 1 -1E-401 -1E-401 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped + +rounding: half_down +-- exact zeros from zeros +fmax361520 fma 1 0 0E-19 -> 0E-19 +fmax361521 fma 1 -0 0E-19 -> 0E-19 +fmax361522 fma 1 0 -0E-19 -> 0E-19 +fmax361523 fma 1 -0 -0E-19 -> -0E-19 +fmax361524 fma 1 0E-400 0E-19 -> 0E-398 Clamped +fmax361525 fma 1 -0E-400 0E-19 -> 0E-398 Clamped +fmax361526 fma 1 0E-400 -0E-19 -> 0E-398 Clamped +fmax361527 fma 1 -0E-400 -0E-19 -> -0E-398 Clamped +-- inexact zeros +fmax361531 fma 1 1E-401 1E-400 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +fmax361532 fma 1 -1E-401 1E-400 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +fmax361533 fma 1 1E-401 -1E-400 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped +fmax361534 fma 1 -1E-401 -1E-400 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped +-- some exact zeros from non-zeros +fmax361535 fma 1 1E-401 1E-401 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +fmax361536 fma 1 -1E-401 1E-401 -> 0E-398 Clamped +fmax361537 fma 1 1E-401 -1E-401 -> 0E-398 Clamped +fmax361538 fma 1 -1E-401 -1E-401 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped + +rounding: half_even +-- exact zeros from zeros +fmax361540 fma 1 0 0E-19 -> 0E-19 +fmax361541 fma 1 -0 0E-19 -> 0E-19 +fmax361542 fma 1 0 -0E-19 -> 0E-19 +fmax361543 fma 1 -0 -0E-19 -> -0E-19 +fmax361544 fma 1 0E-400 0E-19 -> 0E-398 Clamped +fmax361545 fma 1 -0E-400 0E-19 -> 0E-398 Clamped +fmax361546 fma 1 0E-400 -0E-19 -> 0E-398 Clamped +fmax361547 fma 1 -0E-400 -0E-19 -> -0E-398 Clamped +-- inexact zeros +fmax361551 fma 1 1E-401 1E-400 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +fmax361552 fma 1 -1E-401 1E-400 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +fmax361553 fma 1 1E-401 -1E-400 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped +fmax361554 fma 1 -1E-401 -1E-400 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped +-- some exact zeros from non-zeros +fmax361555 fma 1 1E-401 1E-401 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +fmax361556 fma 1 -1E-401 1E-401 -> 0E-398 Clamped +fmax361557 fma 1 1E-401 -1E-401 -> 0E-398 Clamped +fmax361558 fma 1 -1E-401 -1E-401 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped + +rounding: up +-- exact zeros from zeros +fmax361560 fma 1 0 0E-19 -> 0E-19 +fmax361561 fma 1 -0 0E-19 -> 0E-19 +fmax361562 fma 1 0 -0E-19 -> 0E-19 +fmax361563 fma 1 -0 -0E-19 -> -0E-19 +fmax361564 fma 1 0E-400 0E-19 -> 0E-398 Clamped +fmax361565 fma 1 -0E-400 0E-19 -> 0E-398 Clamped +fmax361566 fma 1 0E-400 -0E-19 -> 0E-398 Clamped +fmax361567 fma 1 -0E-400 -0E-19 -> -0E-398 Clamped +-- inexact zeros +fmax361571 fma 1 1E-401 1E-400 -> 1E-398 Subnormal Inexact Rounded Underflow +fmax361572 fma 1 -1E-401 1E-400 -> 1E-398 Subnormal Inexact Rounded Underflow +fmax361573 fma 1 1E-401 -1E-400 -> -1E-398 Subnormal Inexact Rounded Underflow +fmax361574 fma 1 -1E-401 -1E-400 -> -1E-398 Subnormal Inexact Rounded Underflow +-- some exact zeros from non-zeros +fmax361575 fma 1 1E-401 1E-401 -> 1E-398 Subnormal Inexact Rounded Underflow +fmax361576 fma 1 -1E-401 1E-401 -> 0E-398 Clamped +fmax361577 fma 1 1E-401 -1E-401 -> 0E-398 Clamped +fmax361578 fma 1 -1E-401 -1E-401 -> -1E-398 Subnormal Inexact Rounded Underflow + +rounding: down +-- exact zeros from zeros +fmax361580 fma 1 0 0E-19 -> 0E-19 +fmax361581 fma 1 -0 0E-19 -> 0E-19 +fmax361582 fma 1 0 -0E-19 -> 0E-19 +fmax361583 fma 1 -0 -0E-19 -> -0E-19 +fmax361584 fma 1 0E-400 0E-19 -> 0E-398 Clamped +fmax361585 fma 1 -0E-400 0E-19 -> 0E-398 Clamped +fmax361586 fma 1 0E-400 -0E-19 -> 0E-398 Clamped +fmax361587 fma 1 -0E-400 -0E-19 -> -0E-398 Clamped +-- inexact zeros +fmax361591 fma 1 1E-401 1E-400 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +fmax361592 fma 1 -1E-401 1E-400 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +fmax361593 fma 1 1E-401 -1E-400 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped +fmax361594 fma 1 -1E-401 -1E-400 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped +-- some exact zeros from non-zeros +fmax361595 fma 1 1E-401 1E-401 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +fmax361596 fma 1 -1E-401 1E-401 -> 0E-398 Clamped +fmax361597 fma 1 1E-401 -1E-401 -> 0E-398 Clamped +fmax361598 fma 1 -1E-401 -1E-401 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped + +rounding: ceiling +-- exact zeros from zeros +fmax361600 fma 1 0 0E-19 -> 0E-19 +fmax361601 fma 1 -0 0E-19 -> 0E-19 +fmax361602 fma 1 0 -0E-19 -> 0E-19 +fmax361603 fma 1 -0 -0E-19 -> -0E-19 +fmax361604 fma 1 0E-400 0E-19 -> 0E-398 Clamped +fmax361605 fma 1 -0E-400 0E-19 -> 0E-398 Clamped +fmax361606 fma 1 0E-400 -0E-19 -> 0E-398 Clamped +fmax361607 fma 1 -0E-400 -0E-19 -> -0E-398 Clamped +-- inexact zeros +fmax361611 fma 1 1E-401 1E-400 -> 1E-398 Subnormal Inexact Rounded Underflow +fmax361612 fma 1 -1E-401 1E-400 -> 1E-398 Subnormal Inexact Rounded Underflow +fmax361613 fma 1 1E-401 -1E-400 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped +fmax361614 fma 1 -1E-401 -1E-400 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped +-- some exact zeros from non-zeros +fmax361615 fma 1 1E-401 1E-401 -> 1E-398 Subnormal Inexact Rounded Underflow +fmax361616 fma 1 -1E-401 1E-401 -> 0E-398 Clamped +fmax361617 fma 1 1E-401 -1E-401 -> 0E-398 Clamped +fmax361618 fma 1 -1E-401 -1E-401 -> -0E-398 Subnormal Inexact Rounded Underflow Clamped + +-- and the extra-special ugly case; unusual minuses marked by -- * +rounding: floor +-- exact zeros from zeros +fmax361620 fma 1 0 0E-19 -> 0E-19 +fmax361621 fma 1 -0 0E-19 -> -0E-19 -- * +fmax361622 fma 1 0 -0E-19 -> -0E-19 -- * +fmax361623 fma 1 -0 -0E-19 -> -0E-19 +fmax361624 fma 1 0E-400 0E-19 -> 0E-398 Clamped +fmax361625 fma 1 -0E-400 0E-19 -> -0E-398 Clamped -- * +fmax361626 fma 1 0E-400 -0E-19 -> -0E-398 Clamped -- * +fmax361627 fma 1 -0E-400 -0E-19 -> -0E-398 Clamped +-- inexact zeros +fmax361631 fma 1 1E-401 1E-400 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +fmax361632 fma 1 -1E-401 1E-400 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +fmax361633 fma 1 1E-401 -1E-400 -> -1E-398 Subnormal Inexact Rounded Underflow +fmax361634 fma 1 -1E-401 -1E-400 -> -1E-398 Subnormal Inexact Rounded Underflow +-- some exact zeros from non-zeros +fmax361635 fma 1 1E-401 1E-401 -> 0E-398 Subnormal Inexact Rounded Underflow Clamped +fmax361636 fma 1 -1E-401 1E-401 -> -0E-398 Clamped -- * +fmax361637 fma 1 1E-401 -1E-401 -> -0E-398 Clamped -- * +fmax361638 fma 1 -1E-401 -1E-401 -> -1E-398 Subnormal Inexact Rounded Underflow + +-- Examples from SQL proposal (Krishna Kulkarni) +fmax361701 fma 1 130E-2 120E-2 -> 2.50 +fmax361702 fma 1 130E-2 12E-1 -> 2.50 +fmax361703 fma 1 130E-2 1E0 -> 2.30 +fmax361704 fma 1 1E2 1E4 -> 1.01E+4 +fmax361705 subtract 130E-2 120E-2 -> 0.10 +fmax361706 subtract 130E-2 12E-1 -> 0.10 +fmax361707 subtract 130E-2 1E0 -> 0.30 +fmax361708 subtract 1E2 1E4 -> -9.9E+3 + +-- Gappy coefficients; check residue handling even with full coefficient gap +rounding: half_even + +fmax362001 fma 1 1234567890123456 1 -> 1234567890123457 +fmax362002 fma 1 1234567890123456 0.6 -> 1234567890123457 Inexact Rounded +fmax362003 fma 1 1234567890123456 0.06 -> 1234567890123456 Inexact Rounded +fmax362004 fma 1 1234567890123456 6E-3 -> 1234567890123456 Inexact Rounded +fmax362005 fma 1 1234567890123456 6E-4 -> 1234567890123456 Inexact Rounded +fmax362006 fma 1 1234567890123456 6E-5 -> 1234567890123456 Inexact Rounded +fmax362007 fma 1 1234567890123456 6E-6 -> 1234567890123456 Inexact Rounded +fmax362008 fma 1 1234567890123456 6E-7 -> 1234567890123456 Inexact Rounded +fmax362009 fma 1 1234567890123456 6E-8 -> 1234567890123456 Inexact Rounded +fmax362010 fma 1 1234567890123456 6E-9 -> 1234567890123456 Inexact Rounded +fmax362011 fma 1 1234567890123456 6E-10 -> 1234567890123456 Inexact Rounded +fmax362012 fma 1 1234567890123456 6E-11 -> 1234567890123456 Inexact Rounded +fmax362013 fma 1 1234567890123456 6E-12 -> 1234567890123456 Inexact Rounded +fmax362014 fma 1 1234567890123456 6E-13 -> 1234567890123456 Inexact Rounded +fmax362015 fma 1 1234567890123456 6E-14 -> 1234567890123456 Inexact Rounded +fmax362016 fma 1 1234567890123456 6E-15 -> 1234567890123456 Inexact Rounded +fmax362017 fma 1 1234567890123456 6E-16 -> 1234567890123456 Inexact Rounded +fmax362018 fma 1 1234567890123456 6E-17 -> 1234567890123456 Inexact Rounded +fmax362019 fma 1 1234567890123456 6E-18 -> 1234567890123456 Inexact Rounded +fmax362020 fma 1 1234567890123456 6E-19 -> 1234567890123456 Inexact Rounded +fmax362021 fma 1 1234567890123456 6E-20 -> 1234567890123456 Inexact Rounded + +-- widening second argument at gap +fmax362030 fma 1 12345678 1 -> 12345679 +fmax362031 fma 1 12345678 0.1 -> 12345678.1 +fmax362032 fma 1 12345678 0.12 -> 12345678.12 +fmax362033 fma 1 12345678 0.123 -> 12345678.123 +fmax362034 fma 1 12345678 0.1234 -> 12345678.1234 +fmax362035 fma 1 12345678 0.12345 -> 12345678.12345 +fmax362036 fma 1 12345678 0.123456 -> 12345678.123456 +fmax362037 fma 1 12345678 0.1234567 -> 12345678.1234567 +fmax362038 fma 1 12345678 0.12345678 -> 12345678.12345678 +fmax362039 fma 1 12345678 0.123456789 -> 12345678.12345679 Inexact Rounded +fmax362040 fma 1 12345678 0.123456785 -> 12345678.12345678 Inexact Rounded +fmax362041 fma 1 12345678 0.1234567850 -> 12345678.12345678 Inexact Rounded +fmax362042 fma 1 12345678 0.1234567851 -> 12345678.12345679 Inexact Rounded +fmax362043 fma 1 12345678 0.12345678501 -> 12345678.12345679 Inexact Rounded +fmax362044 fma 1 12345678 0.123456785001 -> 12345678.12345679 Inexact Rounded +fmax362045 fma 1 12345678 0.1234567850001 -> 12345678.12345679 Inexact Rounded +fmax362046 fma 1 12345678 0.12345678500001 -> 12345678.12345679 Inexact Rounded +fmax362047 fma 1 12345678 0.123456785000001 -> 12345678.12345679 Inexact Rounded +fmax362048 fma 1 12345678 0.1234567850000001 -> 12345678.12345679 Inexact Rounded +fmax362049 fma 1 12345678 0.1234567850000000 -> 12345678.12345678 Inexact Rounded +-- 90123456 +rounding: half_even +fmax362050 fma 1 12345678 0.0234567750000000 -> 12345678.02345678 Inexact Rounded +fmax362051 fma 1 12345678 0.0034567750000000 -> 12345678.00345678 Inexact Rounded +fmax362052 fma 1 12345678 0.0004567750000000 -> 12345678.00045678 Inexact Rounded +fmax362053 fma 1 12345678 0.0000567750000000 -> 12345678.00005678 Inexact Rounded +fmax362054 fma 1 12345678 0.0000067750000000 -> 12345678.00000678 Inexact Rounded +fmax362055 fma 1 12345678 0.0000007750000000 -> 12345678.00000078 Inexact Rounded +fmax362056 fma 1 12345678 0.0000000750000000 -> 12345678.00000008 Inexact Rounded +fmax362057 fma 1 12345678 0.0000000050000000 -> 12345678.00000000 Inexact Rounded +fmax362060 fma 1 12345678 0.0234567750000001 -> 12345678.02345678 Inexact Rounded +fmax362061 fma 1 12345678 0.0034567750000001 -> 12345678.00345678 Inexact Rounded +fmax362062 fma 1 12345678 0.0004567750000001 -> 12345678.00045678 Inexact Rounded +fmax362063 fma 1 12345678 0.0000567750000001 -> 12345678.00005678 Inexact Rounded +fmax362064 fma 1 12345678 0.0000067750000001 -> 12345678.00000678 Inexact Rounded +fmax362065 fma 1 12345678 0.0000007750000001 -> 12345678.00000078 Inexact Rounded +fmax362066 fma 1 12345678 0.0000000750000001 -> 12345678.00000008 Inexact Rounded +fmax362067 fma 1 12345678 0.0000000050000001 -> 12345678.00000001 Inexact Rounded +-- far-out residues (full coefficient gap is 16+15 digits) +rounding: up +fmax362070 fma 1 12345678 1E-8 -> 12345678.00000001 +fmax362071 fma 1 12345678 1E-9 -> 12345678.00000001 Inexact Rounded +fmax362072 fma 1 12345678 1E-10 -> 12345678.00000001 Inexact Rounded +fmax362073 fma 1 12345678 1E-11 -> 12345678.00000001 Inexact Rounded +fmax362074 fma 1 12345678 1E-12 -> 12345678.00000001 Inexact Rounded +fmax362075 fma 1 12345678 1E-13 -> 12345678.00000001 Inexact Rounded +fmax362076 fma 1 12345678 1E-14 -> 12345678.00000001 Inexact Rounded +fmax362077 fma 1 12345678 1E-15 -> 12345678.00000001 Inexact Rounded +fmax362078 fma 1 12345678 1E-16 -> 12345678.00000001 Inexact Rounded +fmax362079 fma 1 12345678 1E-17 -> 12345678.00000001 Inexact Rounded +fmax362080 fma 1 12345678 1E-18 -> 12345678.00000001 Inexact Rounded +fmax362081 fma 1 12345678 1E-19 -> 12345678.00000001 Inexact Rounded +fmax362082 fma 1 12345678 1E-20 -> 12345678.00000001 Inexact Rounded +fmax362083 fma 1 12345678 1E-25 -> 12345678.00000001 Inexact Rounded +fmax362084 fma 1 12345678 1E-30 -> 12345678.00000001 Inexact Rounded +fmax362085 fma 1 12345678 1E-31 -> 12345678.00000001 Inexact Rounded +fmax362086 fma 1 12345678 1E-32 -> 12345678.00000001 Inexact Rounded +fmax362087 fma 1 12345678 1E-33 -> 12345678.00000001 Inexact Rounded +fmax362088 fma 1 12345678 1E-34 -> 12345678.00000001 Inexact Rounded +fmax362089 fma 1 12345678 1E-35 -> 12345678.00000001 Inexact Rounded + +-- payload decapitate x3 +precision: 5 +fmax363000 fma 1 1 sNaN1234567890 -> NaN67890 Invalid_operation +fmax363001 fma 1 -sNaN1234512345 1 -> -NaN12345 Invalid_operation +fmax363002 fma sNaN1234554321 1 1 -> NaN54321 Invalid_operation + +-- Null tests +fmax39990 fma 1 10 # -> NaN Invalid_operation +fmax39991 fma 1 # 10 -> NaN Invalid_operation Modified: python/branches/release25-maint/Lib/test/decimaltestdata/inexact.decTest ============================================================================== --- python/branches/release25-maint/Lib/test/decimaltestdata/inexact.decTest (original) +++ python/branches/release25-maint/Lib/test/decimaltestdata/inexact.decTest Tue Jan 8 17:20:31 2008 @@ -1,6 +1,6 @@ ------------------------------------------------------------------------ -- inexact.decTest -- decimal inexact and rounded edge cases -- --- Copyright (c) IBM Corporation, 1981, 2003. All rights reserved. -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- ------------------------------------------------------------------------ -- Please see the document "General Decimal Arithmetic Testcases" -- -- at http://www2.hursley.ibm.com/decimal for the description of -- @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc at uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.39 +version: 2.57 extended: 1 precision: 9 Added: python/branches/release25-maint/Lib/test/decimaltestdata/invert.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/invert.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,176 @@ +------------------------------------------------------------------------ +-- invert.decTest -- digitwise logical INVERT -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +extended: 1 +precision: 9 +rounding: half_up +maxExponent: 999 +minExponent: -999 + +-- Sanity check (truth table), and examples from decArith +invx001 invert 0 -> 111111111 +invx002 invert 1 -> 111111110 +invx003 invert 10 -> 111111101 +invx004 invert 111111111 -> 0 +invx005 invert 000000000 -> 111111111 +invx006 invert 101010101 -> '10101010' +-- and at msd and msd-1 +invx007 invert 000000000 -> 111111111 +invx009 invert 100000000 -> 11111111 +invx011 invert 000000000 -> 111111111 +invx013 invert 010000000 -> 101111111 + +-- Various lengths +-- 123456789 123456789 +invx021 invert 111111111 -> 0 +invx022 invert 111111111111 -> 0 +invx023 invert 11111111 -> 100000000 +invx025 invert 1111111 -> 110000000 +invx026 invert 111111 -> 111000000 +invx027 invert 11111 -> 111100000 +invx028 invert 1111 -> 111110000 +invx029 invert 111 -> 111111000 +invx031 invert 11 -> 111111100 +invx032 invert 1 -> 111111110 +invx033 invert 111111111111 -> 0 +invx034 invert 11111111111 -> 0 +invx035 invert 1111111111 -> 0 +invx036 invert 111111111 -> 0 + +invx080 invert 011111111 -> 100000000 +invx081 invert 101111111 -> 10000000 +invx082 invert 110111111 -> 1000000 +invx083 invert 111011111 -> 100000 +invx084 invert 111101111 -> 10000 +invx085 invert 111110111 -> 1000 +invx086 invert 111111011 -> 100 +invx087 invert 111111101 -> 10 +invx088 invert 111111110 -> 1 +invx089 invert 011111011 -> 100000100 +invx090 invert 101111101 -> 10000010 +invx091 invert 110111110 -> 1000001 +invx092 invert 111011101 -> 100010 +invx093 invert 111101011 -> 10100 +invx094 invert 111110111 -> 1000 +invx095 invert 111101011 -> 10100 +invx096 invert 111011101 -> 100010 +invx097 invert 110111110 -> 1000001 +invx098 invert 101111101 -> 10000010 +invx099 invert 011111011 -> 100000100 + +-- non-0/1 should not be accepted, nor should signs +invx220 invert 111111112 -> NaN Invalid_operation +invx221 invert 333333333 -> NaN Invalid_operation +invx222 invert 555555555 -> NaN Invalid_operation +invx223 invert 777777777 -> NaN Invalid_operation +invx224 invert 999999999 -> NaN Invalid_operation +invx225 invert 222222222 -> NaN Invalid_operation +invx226 invert 444444444 -> NaN Invalid_operation +invx227 invert 666666666 -> NaN Invalid_operation +invx228 invert 888888888 -> NaN Invalid_operation +invx229 invert 999999999 -> NaN Invalid_operation +invx230 invert 999999999 -> NaN Invalid_operation +invx231 invert 999999999 -> NaN Invalid_operation +invx232 invert 999999999 -> NaN Invalid_operation +-- a few randoms +invx240 invert 567468689 -> NaN Invalid_operation +invx241 invert 567367689 -> NaN Invalid_operation +invx242 invert -631917772 -> NaN Invalid_operation +invx243 invert -756253257 -> NaN Invalid_operation +invx244 invert 835590149 -> NaN Invalid_operation +-- test MSD +invx250 invert 200000000 -> NaN Invalid_operation +invx251 invert 300000000 -> NaN Invalid_operation +invx252 invert 400000000 -> NaN Invalid_operation +invx253 invert 500000000 -> NaN Invalid_operation +invx254 invert 600000000 -> NaN Invalid_operation +invx255 invert 700000000 -> NaN Invalid_operation +invx256 invert 800000000 -> NaN Invalid_operation +invx257 invert 900000000 -> NaN Invalid_operation +-- test MSD-1 +invx270 invert 021000000 -> NaN Invalid_operation +invx271 invert 030100000 -> NaN Invalid_operation +invx272 invert 040010000 -> NaN Invalid_operation +invx273 invert 050001000 -> NaN Invalid_operation +invx274 invert 160000100 -> NaN Invalid_operation +invx275 invert 170000010 -> NaN Invalid_operation +invx276 invert 180000000 -> NaN Invalid_operation +invx277 invert 190000000 -> NaN Invalid_operation +-- test LSD +invx280 invert 000000002 -> NaN Invalid_operation +invx281 invert 000000003 -> NaN Invalid_operation +invx282 invert 000000004 -> NaN Invalid_operation +invx283 invert 000000005 -> NaN Invalid_operation +invx284 invert 101000006 -> NaN Invalid_operation +invx285 invert 100100007 -> NaN Invalid_operation +invx286 invert 100010008 -> NaN Invalid_operation +invx287 invert 100001009 -> NaN Invalid_operation +-- test Middie +invx288 invert 000020000 -> NaN Invalid_operation +invx289 invert 000030001 -> NaN Invalid_operation +invx290 invert 000040000 -> NaN Invalid_operation +invx291 invert 000050000 -> NaN Invalid_operation +invx292 invert 101060000 -> NaN Invalid_operation +invx293 invert 100170010 -> NaN Invalid_operation +invx294 invert 100080100 -> NaN Invalid_operation +invx295 invert 100091000 -> NaN Invalid_operation +-- signs +invx296 invert -100001000 -> NaN Invalid_operation +invx299 invert 100001000 -> 11110111 + +-- Nmax, Nmin, Ntiny +invx341 invert 9.99999999E+999 -> NaN Invalid_operation +invx342 invert 1E-999 -> NaN Invalid_operation +invx343 invert 1.00000000E-999 -> NaN Invalid_operation +invx344 invert 1E-1007 -> NaN Invalid_operation +invx345 invert -1E-1007 -> NaN Invalid_operation +invx346 invert -1.00000000E-999 -> NaN Invalid_operation +invx347 invert -1E-999 -> NaN Invalid_operation +invx348 invert -9.99999999E+999 -> NaN Invalid_operation + +-- A few other non-integers +invx361 invert 1.0 -> NaN Invalid_operation +invx362 invert 1E+1 -> NaN Invalid_operation +invx363 invert 0.0 -> NaN Invalid_operation +invx364 invert 0E+1 -> NaN Invalid_operation +invx365 invert 9.9 -> NaN Invalid_operation +invx366 invert 9E+1 -> NaN Invalid_operation + +-- All Specials are in error +invx788 invert -Inf -> NaN Invalid_operation +invx794 invert Inf -> NaN Invalid_operation +invx821 invert NaN -> NaN Invalid_operation +invx841 invert sNaN -> NaN Invalid_operation +-- propagating NaNs +invx861 invert NaN1 -> NaN Invalid_operation +invx862 invert +NaN2 -> NaN Invalid_operation +invx863 invert NaN3 -> NaN Invalid_operation +invx864 invert NaN4 -> NaN Invalid_operation +invx865 invert NaN5 -> NaN Invalid_operation +invx871 invert sNaN11 -> NaN Invalid_operation +invx872 invert sNaN12 -> NaN Invalid_operation +invx873 invert sNaN13 -> NaN Invalid_operation +invx874 invert sNaN14 -> NaN Invalid_operation +invx875 invert sNaN15 -> NaN Invalid_operation +invx876 invert NaN16 -> NaN Invalid_operation +invx881 invert +NaN25 -> NaN Invalid_operation +invx882 invert -NaN26 -> NaN Invalid_operation +invx883 invert -sNaN27 -> NaN Invalid_operation Added: python/branches/release25-maint/Lib/test/decimaltestdata/ln.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/ln.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,611 @@ +------------------------------------------------------------------------ +-- ln.decTest -- decimal natural logarithm -- +-- Copyright (c) IBM Corporation, 2005, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +extended: 1 +precision: 16 +rounding: half_even +maxExponent: 384 +minexponent: -383 + +-- basics (examples in specification) +precision: 9 +lnxs001 ln 0 -> -Infinity +lnxs002 ln 1.000 -> 0 +lnxs003 ln 2.71828183 -> 1.00000000 Inexact Rounded +lnxs004 ln 10 -> 2.30258509 Inexact Rounded +lnxs005 ln +Infinity -> Infinity + + +-- basics +precision: 16 +lnx0001 ln 0 -> -Infinity +lnx0002 ln 1E-9 -> -20.72326583694641 Inexact Rounded +lnx0003 ln 0.0007 -> -7.264430222920869 Inexact Rounded +lnx0004 ln 0.1 -> -2.302585092994046 Inexact Rounded +lnx0005 ln 0.7 -> -0.3566749439387324 Inexact Rounded +lnx0006 ln 1 -> 0 +lnx0007 ln 1.000 -> 0 +lnx0008 ln 1.5 -> 0.4054651081081644 Inexact Rounded +lnx0009 ln 2 -> 0.6931471805599453 Inexact Rounded +lnx0010 ln 2.718281828459045 -> 0.9999999999999999 Inexact Rounded +lnx0011 ln 2.718281828459046 -> 1.000000000000000 Inexact Rounded +lnx0012 ln 2.718281828459047 -> 1.000000000000001 Inexact Rounded +lnx0013 ln 10 -> 2.302585092994046 Inexact Rounded +lnx0014 ln 10.5 -> 2.351375257163478 Inexact Rounded +lnx0015 ln 9999 -> 9.210240366975849 Inexact Rounded +lnx0016 ln 1E6 -> 13.81551055796427 Inexact Rounded +lnx0017 ln 1E+9 -> 20.72326583694641 Inexact Rounded +lnx0018 ln +Infinity -> Infinity + +-- notable cases +-- negatives +lnx0021 ln -1E-9 -> NaN Invalid_operation +lnx0022 ln -0.0007 -> NaN Invalid_operation +lnx0023 ln -0.1 -> NaN Invalid_operation +lnx0024 ln -0.7 -> NaN Invalid_operation +lnx0025 ln -1 -> NaN Invalid_operation +lnx0026 ln -1.5 -> NaN Invalid_operation +lnx0027 ln -2 -> NaN Invalid_operation +lnx0029 ln -10.5 -> NaN Invalid_operation +lnx0028 ln -9999 -> NaN Invalid_operation +lnx0030 ln -2.718281828459045 -> NaN Invalid_operation +lnx0031 ln -2.718281828459046 -> NaN Invalid_operation +lnx0032 ln -0 -> -Infinity +lnx0033 ln -0E+17 -> -Infinity +lnx0034 ln -0E-17 -> -Infinity +-- other zeros +lnx0041 ln 0 -> -Infinity +lnx0042 ln 0E+17 -> -Infinity +lnx0043 ln 0E-17 -> -Infinity +-- infinities +lnx0045 ln -Infinity -> NaN Invalid_operation +lnx0046 ln +Infinity -> Infinity +-- ones +lnx0050 ln 1 -> 0 +lnx0051 ln 1.0 -> 0 +lnx0052 ln 1.000000000000000 -> 0 +lnx0053 ln 1.000000000000000000 -> 0 + +-- lower precision basics +Precision: 7 +lnx0101 ln 0 -> -Infinity +lnx0102 ln 1E-9 -> -20.72327 Inexact Rounded +lnx0103 ln 0.0007 -> -7.264430 Inexact Rounded +lnx0104 ln 0.1 -> -2.302585 Inexact Rounded +lnx0105 ln 0.7 -> -0.3566749 Inexact Rounded +lnx0106 ln 1 -> 0 +lnx0107 ln 1.5 -> 0.4054651 Inexact Rounded +lnx0108 ln 2 -> 0.6931472 Inexact Rounded +lnx0109 ln 2.718281828459045 -> 1.000000 Inexact Rounded +lnx0110 ln 2.718281828459046 -> 1.000000 Inexact Rounded +lnx0111 ln 2.718281828459047 -> 1.000000 Inexact Rounded +lnx0112 ln 10 -> 2.302585 Inexact Rounded +lnx0113 ln 10.5 -> 2.351375 Inexact Rounded +lnx0114 ln 9999 -> 9.210240 Inexact Rounded +lnx0115 ln 1E6 -> 13.81551 Inexact Rounded +lnx0116 ln 1E+9 -> 20.72327 Inexact Rounded +lnx0117 ln +Infinity -> Infinity +Precision: 2 +lnx0121 ln 0 -> -Infinity +lnx0122 ln 1E-9 -> -21 Inexact Rounded +lnx0123 ln 0.0007 -> -7.3 Inexact Rounded +lnx0124 ln 0.1 -> -2.3 Inexact Rounded +lnx0125 ln 0.7 -> -0.36 Inexact Rounded +lnx0126 ln 1 -> 0 +lnx0127 ln 1.5 -> 0.41 Inexact Rounded +lnx0128 ln 2 -> 0.69 Inexact Rounded +lnx0129 ln 2.718281828459045 -> 1.0 Inexact Rounded +lnx0130 ln 2.718281828459046 -> 1.0 Inexact Rounded +lnx0131 ln 2.718281828459047 -> 1.0 Inexact Rounded +lnx0132 ln 10 -> 2.3 Inexact Rounded +lnx0133 ln 10.5 -> 2.4 Inexact Rounded +lnx0134 ln 9999 -> 9.2 Inexact Rounded +lnx0135 ln 1E6 -> 14 Inexact Rounded +lnx0136 ln 1E+9 -> 21 Inexact Rounded +lnx0137 ln +Infinity -> Infinity +Precision: 1 +lnx0141 ln 0 -> -Infinity +lnx0142 ln 1E-9 -> -2E+1 Inexact Rounded +lnx0143 ln 0.0007 -> -7 Inexact Rounded +lnx0144 ln 0.1 -> -2 Inexact Rounded +lnx0145 ln 0.7 -> -0.4 Inexact Rounded +lnx0146 ln 1 -> 0 +lnx0147 ln 1.5 -> 0.4 Inexact Rounded +lnx0148 ln 2 -> 0.7 Inexact Rounded +lnx0149 ln 2.718281828459045 -> 1 Inexact Rounded +lnx0150 ln 2.718281828459046 -> 1 Inexact Rounded +lnx0151 ln 2.718281828459047 -> 1 Inexact Rounded +lnx0152 ln 10 -> 2 Inexact Rounded +lnx0153 ln 10.5 -> 2 Inexact Rounded +lnx0154 ln 9999 -> 9 Inexact Rounded +lnx0155 ln 1E6 -> 1E+1 Inexact Rounded +lnx0156 ln 1E+9 -> 2E+1 Inexact Rounded +lnx0157 ln +Infinity -> Infinity + +-- group low-precision ln(1)s: +precision: 1 +lnx0161 ln 1 -> 0 +precision: 2 +lnx0162 ln 1 -> 0 +precision: 3 +lnx0163 ln 1 -> 0 +precision: 4 +lnx0164 ln 1 -> 0 +precision: 5 +lnx0165 ln 1 -> 0 +precision: 6 +lnx0166 ln 1 -> 0 +precision: 7 +lnx0167 ln 1 -> 0 +precision: 8 +lnx0168 ln 1 -> 0 + +-- edge-test ln(2) and ln(10) in case of lookasides +precision: 45 +lnx201 ln 2 -> 0.693147180559945309417232121458176568075500134 Inexact Rounded +lnx202 ln 10 -> 2.30258509299404568401799145468436420760110149 Inexact Rounded +precision: 44 +lnx203 ln 2 -> 0.69314718055994530941723212145817656807550013 Inexact Rounded +lnx204 ln 10 -> 2.3025850929940456840179914546843642076011015 Inexact Rounded +precision: 43 +lnx205 ln 2 -> 0.6931471805599453094172321214581765680755001 Inexact Rounded +lnx206 ln 10 -> 2.302585092994045684017991454684364207601101 Inexact Rounded +precision: 42 +lnx207 ln 2 -> 0.693147180559945309417232121458176568075500 Inexact Rounded +lnx208 ln 10 -> 2.30258509299404568401799145468436420760110 Inexact Rounded +precision: 41 +lnx209 ln 2 -> 0.69314718055994530941723212145817656807550 Inexact Rounded +lnx210 ln 10 -> 2.3025850929940456840179914546843642076011 Inexact Rounded +precision: 40 +lnx211 ln 2 -> 0.6931471805599453094172321214581765680755 Inexact Rounded +lnx212 ln 10 -> 2.302585092994045684017991454684364207601 Inexact Rounded +precision: 39 +lnx213 ln 2 -> 0.693147180559945309417232121458176568076 Inexact Rounded +lnx214 ln 10 -> 2.30258509299404568401799145468436420760 Inexact Rounded +precision: 38 +lnx215 ln 2 -> 0.69314718055994530941723212145817656808 Inexact Rounded +lnx216 ln 10 -> 2.3025850929940456840179914546843642076 Inexact Rounded +precision: 37 +lnx217 ln 2 -> 0.6931471805599453094172321214581765681 Inexact Rounded +lnx218 ln 10 -> 2.302585092994045684017991454684364208 Inexact Rounded +precision: 36 +lnx219 ln 2 -> 0.693147180559945309417232121458176568 Inexact Rounded +lnx220 ln 10 -> 2.30258509299404568401799145468436421 Inexact Rounded +precision: 35 +lnx221 ln 2 -> 0.69314718055994530941723212145817657 Inexact Rounded +lnx222 ln 10 -> 2.3025850929940456840179914546843642 Inexact Rounded +precision: 34 +lnx223 ln 2 -> 0.6931471805599453094172321214581766 Inexact Rounded +lnx224 ln 10 -> 2.302585092994045684017991454684364 Inexact Rounded +precision: 33 +lnx225 ln 2 -> 0.693147180559945309417232121458177 Inexact Rounded +lnx226 ln 10 -> 2.30258509299404568401799145468436 Inexact Rounded +precision: 32 +lnx227 ln 2 -> 0.69314718055994530941723212145818 Inexact Rounded +lnx228 ln 10 -> 2.3025850929940456840179914546844 Inexact Rounded +precision: 31 +lnx229 ln 2 -> 0.6931471805599453094172321214582 Inexact Rounded +lnx230 ln 10 -> 2.302585092994045684017991454684 Inexact Rounded +precision: 30 +lnx231 ln 2 -> 0.693147180559945309417232121458 Inexact Rounded +lnx232 ln 10 -> 2.30258509299404568401799145468 Inexact Rounded + +-- extreme input range values +maxExponent: 384 +minExponent: -383 +Precision: 16 + +lnx0901 ln 1e-400 -> -921.0340371976183 Inexact Rounded +lnx0902 ln 1e+400 -> 921.0340371976183 Inexact Rounded +lnx0903 ln 1e-999999 -> -2302582.790408953 Inexact Rounded +lnx0904 ln 1e+999999 -> 2302582.790408953 Inexact Rounded +lnx0905 ln 1e-1000013 -> -2302615.026600255 Inexact Rounded +lnx0906 ln 2e-1000013 -> -2302614.333453074 Inexact Rounded + +lnx0910 ln 9.999999e+999999 -> 2302585.092993946 Inexact Rounded +lnx0911 ln 9.9999999e+999999 -> 2302585.092994036 Inexact Rounded +lnx0912 ln 9.99999999e+999999 -> 2302585.092994045 Inexact Rounded +lnx0913 ln 9.999999999e+999999 -> 2302585.092994046 Inexact Rounded +lnx0914 ln 9.999999999999e+999999 -> 2302585.092994046 Inexact Rounded +lnx0915 ln 9.999999999999999e+999999 -> 2302585.092994046 Inexact Rounded +lnx0916 ln 9.999999999999999999999999e+999999 -> 2302585.092994046 Inexact Rounded + +-- randoms +-- P=50, within 0-999 +Precision: 50 +maxExponent: 384 +minExponent: -383 +lnx1501 ln 0.00098800906574486388604608477869812518857023768951 -> -6.9198186844033787995945147836955586009548513043689 Inexact Rounded +lnx1502 ln 158.15866624664623070184595045304145949900714987827 -> 5.0635987458895647454907806507503825602758392287684 Inexact Rounded +lnx1503 ln 0.00565661412059571925040285814021799775249288309321 -> -5.1749297776760632102047540300491550931651318975237 Inexact Rounded +lnx1504 ln 0.00000006914232532620489602008402091666547903180607 -> -16.487098770877825308138976818688771638172333034347 Inexact Rounded +lnx1505 ln 0.00025380374621297657504661540749355251231770070723 -> -8.2789492423005003205242162741569033124260321954589 Inexact Rounded +lnx1506 ln 83.033654063877426261108592599182418953442677554806 -> 4.4192459962647137976949249810815698465031609843669 Inexact Rounded +lnx1507 ln 0.00000000416863228092481651627734668440663678118729 -> -19.295677845122141772791294599714950175284915666430 Inexact Rounded +lnx1508 ln 0.00000140847873187820570181214271960511080523457669 -> -13.473000349581967189668305314384952251556809480339 Inexact Rounded +lnx1509 ln 66.176106555181527101630351127583944689752069132522 -> 4.1923194696232505883666171116966137694013431504252 Inexact Rounded +lnx1510 ln 0.00000000000009899043487403590900111602024562297908 -> -29.943753166877840985821508112917991506656545174163 Inexact Rounded +lnx1511 ln 0.00000000000324618296721747097510453388683912733569 -> -26.453541281444586819009546418577507163362590139422 Inexact Rounded +lnx1512 ln 72.646968818463546449499147579023555008392860423385 -> 4.2856116660689646882852128853423566276718230426479 Inexact Rounded +lnx1513 ln 0.00000000000000066755483124635612574263153825990523 -> -34.942910142802769319262875080398852491588707172483 Inexact Rounded +lnx1514 ln 61.002910447202398204114909451851111424657671911002 -> 4.1109215752843377323363182051446177066434038096529 Inexact Rounded +lnx1515 ln 917.06917611331980999227893584010544542312239174774 -> 6.8211829068303114128752453661946446979787826282907 Inexact Rounded +lnx1516 ln 0.00000000170823794883673083358549749078972003965194 -> -20.187803436976150477297246666771626827057191023004 Inexact Rounded +lnx1517 ln 0.53731767845358224445809761315159249898566542910649 -> -0.62116577939968409211736413628236285160048357000961 Inexact Rounded +lnx1518 ln 0.00000000000000008965291392882804161299758708033373 -> -36.950585970980857376081265073276303670820056916206 Inexact Rounded +lnx1519 ln 0.00000000006990244916026429904498278982530170295668 -> -23.383920429244457578373523508427783144589480420753 Inexact Rounded +lnx1520 ln 4.0312542977070300070506064666536478373801988540614 -> 1.3940775676592451945795752796421391871302024763305 Inexact Rounded +lnx1521 ln 271.84991311551875601432518819562391699324632396423 -> 5.6052501239873862517916679747146539808077431873478 Inexact Rounded +lnx1522 ln 7.4118671629373864667229445746862314443895404818689 -> 2.0030823863706344628239147639318289961917060121141 Inexact Rounded +lnx1523 ln 0.00000000000002026311452625364905357321664186034258 -> -31.529974180054438792043856877314043794320951134754 Inexact Rounded +lnx1524 ln 0.00000000000009563398651261756952398250624737809347 -> -29.978248130576972953141284136962670021368834792579 Inexact Rounded +lnx1525 ln 0.00000000009556772669409858653026558223465197808991 -> -23.071185939748285541228206161472956661196956741186 Inexact Rounded +lnx1526 ln 6.8441648298027301292342057248737326152250794026761 -> 1.9233964395801946597272589473417948024361005082908 Inexact Rounded +lnx1527 ln 0.00000000000073059699884439979394945822035704264577 -> -27.944914388353724718836101828677771967128509603158 Inexact Rounded +lnx1528 ln 0.00000000000000002610078280419082263138064745416787 -> -38.184566367516207885573773320135965798717120735115 Inexact Rounded +lnx1529 ln 0.00000000000000000150259517166294243088546806083283 -> -41.039337946266676108538170837580051699618334928421 Inexact Rounded +lnx1530 ln 0.00000000000000087919160541714580707181969708502091 -> -34.667528818827671507514319744047440696187358676848 Inexact Rounded +lnx1531 ln 0.00000000000395726725120787763271849577708068584598 -> -26.255467416961357741818735787226671938678424748431 Inexact Rounded +lnx1532 ln 0.00000000002014334901669366218018377213150715938355 -> -24.628146955635359035289123027319969201693737159108 Inexact Rounded +lnx1533 ln 0.00000008097927101101093117753938766241442896030637 -> -16.329072628469715178637178365710373398203190937454 Inexact Rounded +lnx1534 ln 0.00000000000017115834162632864392039668116243984176 -> -29.396187292434898225453626794459285157263177528034 Inexact Rounded +lnx1535 ln 0.39168317593866334087305459933723864294857086105035 -> -0.93730199062757240485836637306785037368746737693029 Inexact Rounded +lnx1536 ln 79.335036798971515026519630103325369729637514127617 -> 4.3736798570287828823772149735170431010616961976965 Inexact Rounded +lnx1537 ln 0.00000000000000056004952129926137413602116591493625 -> -35.118506463181870020730685884333000241039028127213 Inexact Rounded +lnx1538 ln 0.00000006006035907843890918832481099660639553666078 -> -16.627915795747112566532705974853114454405010472043 Inexact Rounded +lnx1539 ln 0.00000000085242024937414906371333826574632450587590 -> -20.882941460268101080186482230657774997273494107221 Inexact Rounded +lnx1540 ln 0.00000000000043671099499262350316173246550771951561 -> -28.459504757285639221776305968469058854558726593945 Inexact Rounded + +-- P=34, within 0-999 +Precision: 34 +lnx1201 ln 0.0086732880815927182997566810334394 -> -4.747507311920844752486938187973721 Inexact Rounded +lnx1202 ln 0.0007104103693460260609792222569854 -> -7.249667769903503023005549250347695 Inexact Rounded +lnx1203 ln 786.8398945385105190697541493392742 -> 6.668024790031836340471824147010546 Inexact Rounded +lnx1204 ln 0.7723073620282687656895190171967399 -> -0.2583726708506850868786816238217326 Inexact Rounded +lnx1205 ln 0.0061057951517197631287183938412200 -> -5.098516933918797347064454103742635 Inexact Rounded +lnx1206 ln 0.6181379708184393730103917562498745 -> -0.4810435926903365087463387760350021 Inexact Rounded +lnx1207 ln 09.13888261229039989110753389096760 -> 2.212538125507975574509563027696021 Inexact Rounded +lnx1208 ln 802.0105417063143696497292158147174 -> 6.687121752052341737234832203350214 Inexact Rounded +lnx1209 ln 778.7749710387773713523028497333058 -> 6.657722135126935472086625031413031 Inexact Rounded +lnx1210 ln 0.0024457295895346502513567679390616 -> -6.013411799940245345321348290398517 Inexact Rounded +lnx1211 ln 0.0000511296947872828310338864217860 -> -9.881145118237281798081573131711636 Inexact Rounded +lnx1212 ln 0.0000246803508602554924938685155658 -> -10.60950314264825661825360971430218 Inexact Rounded +lnx1213 ln 9.027898199253511668242977766616082 -> 2.200319582778899029786017830557293 Inexact Rounded +lnx1214 ln 0.0991812396542505631850692800904188 -> -2.310806398964672258823043180400384 Inexact Rounded +lnx1215 ln 0.0000000000070238810143028811223924 -> -25.68170519961636647174714538290075 Inexact Rounded +lnx1216 ln 2.630101665342826494730394729313167 -> 0.9670225014664367465128243039749559 Inexact Rounded +lnx1217 ln 0.0056878928594359587691526063254683 -> -5.169415422904037819736637399445096 Inexact Rounded +lnx1218 ln 567.3436047121057843908106573095590 -> 6.340965124964258486463444360787970 Inexact Rounded +lnx1219 ln 1.199291248124655996614605745649725 -> 0.1817307557425911805765087755675657 Inexact Rounded +lnx1220 ln 25.02050448582031098696267479135557 -> 3.219695668137659139544178905459317 Inexact Rounded +lnx1221 ln 0.0000000000009939597023558756961300 -> -27.63707972996537636504396558259058 Inexact Rounded +lnx1222 ln 0.0000007988551670159429716506430403 -> -14.04008617542597230988198612376415 Inexact Rounded +lnx1223 ln 4.681515800176129184873770605589795 -> 1.543621946415383338972124445445748 Inexact Rounded +lnx1224 ln 15.95126669161103011206658749345781 -> 2.769538242479483539275986395443539 Inexact Rounded +lnx1225 ln 0.0301626783922211213675457279076066 -> -3.501149933677283341023932281826341 Inexact Rounded +lnx1226 ln 000.0040544064881821770528475185674 -> -5.507950967557021671647165889608324 Inexact Rounded +lnx1227 ln 29.01617095935593792095913785100360 -> 3.367853293862745651888450004473297 Inexact Rounded +lnx1228 ln 78.01836167344736733024804243195323 -> 4.356944205055768575987781375003992 Inexact Rounded +lnx1229 ln 0.0000000096545319316965321158634893 -> -18.45583840160965814462095477365013 Inexact Rounded +lnx1230 ln 97.95475237720579752770587185074428 -> 4.584505661612812742208619358214729 Inexact Rounded +lnx1231 ln 528.0609262050423246402564228432371 -> 6.269211667589138113396583894315956 Inexact Rounded +lnx1232 ln 0.0000002250064349732969696660452972 -> -15.30713683526963996712167701738724 Inexact Rounded +lnx1233 ln 47.97063637767998658567199049725754 -> 3.870589081585660692195989854842372 Inexact Rounded +lnx1234 ln 0.0005394311344541432318853513414361 -> -7.524995428393925934087126702974121 Inexact Rounded +lnx1235 ln 0.0000000090973385649567471674972633 -> -18.51528393158931783447035004125791 Inexact Rounded +lnx1236 ln 0.0000000000238776490227576197317977 -> -24.45807828188389561331158879207262 Inexact Rounded +lnx1237 ln 0.0000236587000231921532145326218758 -> -10.65177964499823314952429277979034 Inexact Rounded +lnx1238 ln 499.1277448846130709827154556125942 -> 6.212862064761427967461188083514774 Inexact Rounded +lnx1239 ln 0.0000003960192300284787663712417647 -> -14.74180306619298548093697608293284 Inexact Rounded +lnx1240 ln 41.08268350829477451667228892495136 -> 3.715586706887278039173584859218960 Inexact Rounded + +-- P=16, within 0-99 +Precision: 16 +lnx1101 ln 7.964875261033948 -> 2.075041282352241 Inexact Rounded +lnx1102 ln 13.54527396845394 -> 2.606037701870263 Inexact Rounded +lnx1103 ln 0.0008026554341331 -> -7.127585034321814 Inexact Rounded +lnx1104 ln 0.0000030582233261 -> -12.69767642300625 Inexact Rounded +lnx1105 ln 0.0004477497509672 -> -7.711276073210766 Inexact Rounded +lnx1106 ln 7.616268622474371 -> 2.030286567675148 Inexact Rounded +lnx1107 ln 51.58329925806381 -> 3.943197962309569 Inexact Rounded +lnx1108 ln 0.0018197497951263 -> -6.309056262549345 Inexact Rounded +lnx1109 ln 2.956282457072984 -> 1.083932552334575 Inexact Rounded +lnx1110 ln 0.3843325579189906 -> -0.9562470649400558 Inexact Rounded +lnx1111 ln 0.0074466329265663 -> -4.899993304919237 Inexact Rounded +lnx1112 ln 0.0003372478532993 -> -7.994692428206378 Inexact Rounded +lnx1113 ln 0.0084792263167809 -> -4.770136069569271 Inexact Rounded +lnx1114 ln 5.926756998151102 -> 1.779477182834305 Inexact Rounded +lnx1115 ln 9.025699152180897 -> 2.200075969604119 Inexact Rounded +lnx1116 ln 1.910124643533526 -> 0.6471684983238183 Inexact Rounded +lnx1117 ln 0.8158922711411020 -> -0.2034729533939387 Inexact Rounded +lnx1118 ln 0.0067080016475322 -> -5.004454189414139 Inexact Rounded +lnx1119 ln 0.0047583242092716 -> -5.347859729601094 Inexact Rounded +lnx1120 ln 0.0386647411641339 -> -3.252827175263113 Inexact Rounded +lnx1121 ln 0.0050226427841761 -> -5.293799032774131 Inexact Rounded +lnx1122 ln 6.927937541637261 -> 1.935562155866906 Inexact Rounded +lnx1123 ln 0.0000095745343513 -> -11.55640365579814 Inexact Rounded +lnx1124 ln 1.602465492956538 -> 0.4715433763243936 Inexact Rounded +lnx1125 ln 38.98415625087535 -> 3.663155313610213 Inexact Rounded +lnx1126 ln 5.343182042276734 -> 1.675821363568112 Inexact Rounded +lnx1127 ln 55.89763703245816 -> 4.023522107934110 Inexact Rounded +lnx1128 ln 0.7445257810280847 -> -0.2950077988101030 Inexact Rounded +lnx1129 ln 1.631407314946094 -> 0.4894430257201248 Inexact Rounded +lnx1130 ln 0.0005462451932602 -> -7.512442611116852 Inexact Rounded +lnx1131 ln 0.0000864173269362 -> -9.356322359017317 Inexact Rounded +lnx1132 ln 5.227161719132849 -> 1.653868438439637 Inexact Rounded +lnx1133 ln 60.57078466941998 -> 4.103812675662452 Inexact Rounded +lnx1134 ln 0.0992864325333160 -> -2.309746348350318 Inexact Rounded +lnx1135 ln 09.48564268447325 -> 2.249779359074983 Inexact Rounded +lnx1136 ln 0.0036106089355634 -> -5.623878840650787 Inexact Rounded +lnx1137 ln 1.805176865587172 -> 0.5906585734593707 Inexact Rounded +lnx1138 ln 62.59363259642255 -> 4.136663557220559 Inexact Rounded +lnx1139 ln 4.373828261137201 -> 1.475638657912000 Inexact Rounded +lnx1140 ln 0.994483524148738 -> -0.005531747794938690 Inexact Rounded + +-- P=7, within 0-9 +Precision: 7 +lnx1001 ln 0.0912025 -> -2.394673 Inexact Rounded +lnx1002 ln 0.9728626 -> -0.02751242 Inexact Rounded +lnx1003 ln 0.3886032 -> -0.9451965 Inexact Rounded +lnx1004 ln 8.798639 -> 2.174597 Inexact Rounded +lnx1005 ln 2.459121 -> 0.8998040 Inexact Rounded +lnx1006 ln 2.013193 -> 0.6997220 Inexact Rounded +lnx1007 ln 9.064857 -> 2.204405 Inexact Rounded +lnx1008 ln 5.796417 -> 1.757240 Inexact Rounded +lnx1009 ln 0.1143471 -> -2.168517 Inexact Rounded +lnx1010 ln 0.5341542 -> -0.6270707 Inexact Rounded +lnx1011 ln 6.693781 -> 1.901179 Inexact Rounded +lnx1012 ln 0.0081779 -> -4.806320 Inexact Rounded +lnx1013 ln 8.313616 -> 2.117895 Inexact Rounded +lnx1014 ln 3.486925 -> 1.249020 Inexact Rounded +lnx1015 ln 0.1801401 -> -1.714020 Inexact Rounded +lnx1016 ln 0.5227148 -> -0.6487193 Inexact Rounded +lnx1017 ln 7.818111 -> 2.056443 Inexact Rounded +lnx1018 ln 0.0870671 -> -2.441076 Inexact Rounded +lnx1019 ln 8.153966 -> 2.098504 Inexact Rounded +lnx1020 ln 2.040975 -> 0.7134276 Inexact Rounded +lnx1021 ln 1.481642 -> 0.3931509 Inexact Rounded +lnx1022 ln 0.2610123 -> -1.343188 Inexact Rounded +lnx1023 ln 0.466723 -> -0.7620193 Inexact Rounded +lnx1024 ln 0.0518756 -> -2.958907 Inexact Rounded +lnx1025 ln 2.056410 -> 0.7209617 Inexact Rounded +lnx1026 ln 0.181522 -> -1.706378 Inexact Rounded +lnx1027 ln 0.515551 -> -0.6625190 Inexact Rounded +lnx1028 ln 8.425089 -> 2.131214 Inexact Rounded +lnx1029 ln 2.077091 -> 0.7309684 Inexact Rounded +lnx1030 ln 6.212705 -> 1.826596 Inexact Rounded +lnx1031 ln 5.729343 -> 1.745601 Inexact Rounded +lnx1032 ln 4.831251 -> 1.575105 Inexact Rounded +lnx1033 ln 2.029760 -> 0.7079176 Inexact Rounded +lnx1034 ln 8.615060 -> 2.153512 Inexact Rounded +lnx1035 ln 0.0611511 -> -2.794407 Inexact Rounded +lnx1036 ln 5.195269 -> 1.647748 Inexact Rounded +lnx1037 ln 9.617686 -> 2.263604 Inexact Rounded +lnx1038 ln 0.0049382 -> -5.310754 Inexact Rounded +lnx1039 ln 2.786840 -> 1.024908 Inexact Rounded +lnx1040 ln 0.0091073 -> -4.698679 Inexact Rounded + +-- from here 3-digit tests are based on reverse exp tests +precision: 9 +rounding: half_even +maxExponent: 384 +minexponent: -383 + +lnx001 ln 0 -> -Infinity +lnx002 ln 0.367879441 -> -1.00000000 Inexact Rounded +lnx003 ln 1 -> 0 +lnx005 ln 2.71828183 -> 1.00000000 Inexact Rounded +lnx006 ln 2.00000000 -> 0.693147181 Inexact Rounded +lnx007 ln +Infinity -> Infinity + +-- tiny edge cases +precision: 7 +lnx011 ln 1.105171 -> 0.1000001 Inexact Rounded +lnx012 ln 1.010050 -> 0.009999835 Inexact Rounded +lnx013 ln 1.000010 -> 0.000009999950 Inexact Rounded +lnx014 ln 1.000001 -> 9.999995E-7 Inexact Rounded +lnx015 ln 1.000000 -> 0 + +-- basic e=0, e=1, e=2, e=4, e>=8 cases +precision: 7 +lnx041 ln 2.718282 -> 1.000000 Inexact Rounded +lnx042 ln 0.3678794 -> -1.000000 Inexact Rounded +lnx043 ln 22026.47 -> 10.00000 Inexact Rounded +lnx044 ln 0.00004539993 -> -10.00000 Inexact Rounded +lnx045 ln 2.688117E+43 -> 100.0000 Inexact Rounded +lnx046 ln 3.720076E-44 -> -100.0000 Inexact Rounded +lnx047 ln Infinity -> Infinity +lnx048 ln 0E-389 -> -Infinity + +-- miscellanea +precision: 16 +lnx055 ln 2.717658486884572E-236 -> -542.4103112874415 Inexact Rounded +precision: 17 +lnx056 ln 2.7176584868845721E-236 -> -542.41031128744146 Inexact Rounded +precision: 18 +lnx057 ln 2.71765848688457211E-236 -> -542.410311287441459 Inexact Rounded +precision: 19 +lnx058 ln 2.717658486884572112E-236 -> -542.4103112874414592 Inexact Rounded +precision: 20 +lnx059 ln 2.7176584868845721118E-236 -> -542.41031128744145917 Inexact Rounded + +-- inputs ending in ..500.., ..499.., ..100.., ..999.. sequences +precision: 50 +lnx102 ln 0.9999999100000040499998785000027 -> -9.0000000000000000000000033749953829996446124861750E-8 Inexact Rounded +precision: 30 +lnx103 ln 0.999999910000004049999878500003 -> -8.99999999999999999999997337499E-8 Inexact Rounded +precision: 29 +lnx104 ln 0.99999991000000404999987850000 -> -9.0000000000000000000002733750E-8 Inexact Rounded +precision: 28 +lnx105 ln 0.9999999100000040499998785000 -> -9.000000000000000000000273375E-8 Inexact Rounded +precision: 27 +lnx106 ln 0.999999910000004049999878500 -> -9.00000000000000000000027338E-8 Inexact Rounded +precision: 26 +lnx107 ln 0.99999991000000404999987850 -> -9.0000000000000000000002734E-8 Inexact Rounded +precision: 25 +lnx108 ln 0.9999999100000040499998785 -> -9.000000000000000000000273E-8 Inexact Rounded +precision: 24 +lnx109 ln 0.999999910000004049999879 -> -8.99999999999999995000027E-8 Inexact Rounded +precision: 23 +lnx110 ln 0.99999991000000404999988 -> -8.9999999999999998500003E-8 Inexact Rounded +precision: 22 +lnx111 ln 0.9999999100000040499999 -> -8.999999999999997850000E-8 Inexact Rounded +precision: 21 +lnx112 ln 0.999999910000004050000 -> -8.99999999999998785000E-8 Inexact Rounded +precision: 20 +lnx113 ln 0.99999991000000405000 -> -8.9999999999999878500E-8 Inexact Rounded +precision: 19 +lnx114 ln 0.9999999100000040500 -> -8.999999999999987850E-8 Inexact Rounded +precision: 18 +lnx115 ln 0.999999910000004050 -> -8.99999999999998785E-8 Inexact Rounded +-- next may be a > 0.5ulp case; a more precise answer is: +-- -8.99999999999998784999918E-8 +precision: 17 +lnx116 ln 0.99999991000000405 -> -8.9999999999999878E-8 Inexact Rounded +precision: 16 +lnx117 ln 0.9999999100000040 -> -9.000000004999988E-8 Inexact Rounded +precision: 15 +lnx118 ln 0.999999910000004 -> -9.00000000499999E-8 Inexact Rounded +precision: 14 +lnx119 ln 0.99999991000000 -> -9.0000004050000E-8 Inexact Rounded +precision: 13 +lnx120 ln 0.9999999100000 -> -9.000000405000E-8 Inexact Rounded +precision: 12 +lnx121 ln 0.999999910000 -> -9.00000040500E-8 Inexact Rounded +precision: 11 +lnx122 ln 0.99999991000 -> -9.0000004050E-8 Inexact Rounded +precision: 10 +lnx123 ln 0.9999999100 -> -9.000000405E-8 Inexact Rounded +precision: 9 +lnx124 ln 0.999999910 -> -9.00000041E-8 Inexact Rounded +precision: 8 +lnx125 ln 0.99999991 -> -9.0000004E-8 Inexact Rounded +precision: 7 +lnx126 ln 0.9999999 -> -1.000000E-7 Inexact Rounded +precision: 16 +lnx126b ln 0.9999999 -> -1.000000050000003E-7 Inexact Rounded +precision: 6 +lnx127 ln 0.999999 -> -0.00000100000 Inexact Rounded +precision: 5 +lnx128 ln 0.99999 -> -0.000010000 Inexact Rounded +precision: 4 +lnx129 ln 0.9999 -> -0.0001000 Inexact Rounded +precision: 3 +lnx130 ln 0.999 -> -0.00100 Inexact Rounded +precision: 2 +lnx131 ln 0.99 -> -0.010 Inexact Rounded +precision: 1 +lnx132 ln 0.9 -> -0.1 Inexact Rounded + + +-- cases near 1 -- 1 2345678901234567890 +precision: 20 +lnx401 ln 2.7182818284589365041 -> 0.99999999999996000000 Inexact Rounded +lnx402 ln 2.7182818284589636869 -> 0.99999999999997000000 Inexact Rounded +lnx403 ln 2.7182818284589908697 -> 0.99999999999997999999 Inexact Rounded +lnx404 ln 2.7182818284590180525 -> 0.99999999999998999998 Inexact Rounded +lnx405 ln 2.7182818284590452354 -> 1.0000000000000000000 Inexact Rounded +lnx406 ln 2.7182818284593170635 -> 1.0000000000001000000 Inexact Rounded +lnx407 ln 2.7182818284595888917 -> 1.0000000000002000000 Inexact Rounded +precision: 14 +lnx411 ln 2.7182818284589 -> 0.99999999999995 Inexact Rounded +lnx413 ln 2.7182818284590 -> 0.99999999999998 Inexact Rounded +lnx416 ln 2.7182818284591 -> 1.0000000000000 Inexact Rounded +lnx417 ln 2.7182818284592 -> 1.0000000000001 Inexact Rounded + +-- overflows, including some exp overprecise borderlines +precision: 7 +maxExponent: 384 +minExponent: -383 +lnx709 ln 9.999999E+384 -> 886.4953 Inexact Rounded +lnx711 ln 9.999992E+384 -> 886.4953 Inexact Rounded +precision: 16 +lnx722 ln 9.999999999999999E+384 -> 886.4952608027076 Inexact Rounded +lnx724 ln 9.999999999999917E+384 -> 886.4952608027076 Inexact Rounded +lnx726 ln 9.999999999999117E+384 -> 886.4952608027075 Inexact Rounded +-- and more... +precision: 15 +maxExponent: 999 +minExponent: -999 +lnx731 ln 9.99999999999999E+999 -> 2302.58509299405 Inexact Rounded +-- next may be a > 0.5ulp case; a more precise answer is: +-- 2302.58509299404495001799145442 +lnx732 ln 9.99999999999266E+999 -> 2302.58509299404 Inexact Rounded +lnx733 ln 9.99999999999265E+999 -> 2302.58509299404 Inexact Rounded +lnx734 ln 9.99999999999264E+999 -> 2302.58509299404 Inexact Rounded + +-- subnormals and underflows for exp, including underflow-to-zero edge point +precision: 7 +maxExponent: 384 +minExponent: -383 +lnx751 ln 0E-389 -> -Infinity +lnx758 ln 1.000001E-383 -> -881.8901 Inexact Rounded +lnx759 ln 9.99991E-384 -> -881.8901 Inexact Rounded +lnx760 ln 4.4605E-385 -> -885.0000 Inexact Rounded +lnx761 ln 2.221E-386 -> -887.9999 Inexact Rounded +lnx762 ln 3.01E-387 -> -889.9985 Inexact Rounded +lnx763 ln 1.7E-388 -> -892.8724 Inexact Rounded +lnx764 ln 1.5E-388 -> -892.9976 Inexact Rounded +lnx765 ln 9E-389 -> -893.5084 Inexact Rounded +lnx766 ln 1E-389 -> -895.7056 Inexact Rounded +lnx774 ln 0E-389 -> -Infinity + +-- special values +lnx820 ln Infinity -> Infinity +lnx821 ln 0 -> -Infinity +lnx822 ln NaN -> NaN +lnx823 ln sNaN -> NaN Invalid_operation +-- propagating NaNs +lnx824 ln sNaN123 -> NaN123 Invalid_operation +lnx825 ln -sNaN321 -> -NaN321 Invalid_operation +lnx826 ln NaN456 -> NaN456 +lnx827 ln -NaN654 -> -NaN654 +lnx828 ln NaN1 -> NaN1 + +-- Invalid operations due to restrictions +-- [next two probably skipped by most test harnesses] +precision: 100000000 +lnx901 ln 1 -> NaN Invalid_context +precision: 99999999 +lnx902 ln 0 -> NaN Invalid_context + +precision: 9 +maxExponent: 1000000 +minExponent: -999999 +lnx903 ln 1 -> NaN Invalid_context +maxExponent: 999999 +minExponent: -999999 +lnx904 ln 0 -> -Infinity +maxExponent: 999999 +minExponent: -1000000 +lnx905 ln 1 -> NaN Invalid_context +maxExponent: 999999 +minExponent: -999998 +lnx906 ln 0 -> -Infinity + +-- payload decapitate +precision: 5 +lnx910 ln -sNaN1234567890 -> -NaN67890 Invalid_operation + +-- Null test +lnx900 ln # -> NaN Invalid_operation + + Added: python/branches/release25-maint/Lib/test/decimaltestdata/log10.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/log10.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,551 @@ +------------------------------------------------------------------------ +-- log10.decTest -- decimal logarithm in base 10 -- +-- Copyright (c) IBM Corporation, 2005, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- This emphasises the testing of notable cases, as they will often +-- have unusual paths (especially the 10**n results). + +extended: 1 +precision: 16 +rounding: half_even +maxExponent: 384 +minexponent: -383 + +-- examples in specification +precision: 9 +logxs000 log10 0 -> -Infinity +logxs001 log10 0.001 -> -3 +logxs002 log10 1 -> 0 +logxs003 log10 2 -> 0.301029996 Inexact Rounded +logxs004 log10 10 -> 1 +logxs005 log10 70 -> 1.84509804 Inexact Rounded +logxs006 log10 +Infinity -> Infinity + + +-- basics (examples in specification, etc.) +precision: 16 +logx0000 log10 0 -> -Infinity +logx0001 log10 7E-1000 -> -999.1549019599857 Inexact Rounded +logx0002 log10 1.1E-9 -> -8.958607314841775 Inexact Rounded +logx0003 log10 0.0007 -> -3.154901959985743 Inexact Rounded +logx0004 log10 0.11 -> -0.9586073148417750 Inexact Rounded +logx0005 log10 0.7 -> -0.1549019599857432 Inexact Rounded +logx0006 log10 1 -> 0 +logx0007 log10 1.5 -> 0.1760912590556812 Inexact Rounded +logx0008 log10 2 -> 0.3010299956639812 Inexact Rounded +logx0009 log10 2.718281828459045 -> 0.4342944819032518 Inexact Rounded +logx0010 log10 2.718281828459046 -> 0.4342944819032519 Inexact Rounded +logx0011 log10 2.718281828459047 -> 0.4342944819032521 Inexact Rounded +logx0012 log10 7 -> 0.8450980400142568 Inexact Rounded +logx0013 log10 10 -> 1 +logx0014 log10 10.5 -> 1.021189299069938 Inexact Rounded +logx0015 log10 11 -> 1.041392685158225 Inexact Rounded +logx0016 log10 70 -> 1.845098040014257 Inexact Rounded +logx0017 log10 9999 -> 3.999956568380192 Inexact Rounded +logx0018 log10 1.21E6 -> 6.082785370316450 Inexact Rounded +logx0019 log10 1.1E+9 -> 9.041392685158225 Inexact Rounded +logx0020 log10 7E+1000 -> 1000.845098040014 Inexact Rounded +logx0021 log10 +Infinity -> Infinity + +-- notable cases +-- negatives +logx0031 log10 -1E-9 -> NaN Invalid_operation +logx0032 log10 -0.0007 -> NaN Invalid_operation +logx0033 log10 -0.1 -> NaN Invalid_operation +logx0034 log10 -0.7 -> NaN Invalid_operation +logx0035 log10 -1 -> NaN Invalid_operation +logx0036 log10 -1.5 -> NaN Invalid_operation +logx0037 log10 -2 -> NaN Invalid_operation +logx0038 log10 -10.5 -> NaN Invalid_operation +logx0039 log10 -10.5 -> NaN Invalid_operation +logx0040 log10 -9999 -> NaN Invalid_operation +logx0041 log10 -10 -> NaN Invalid_operation +logx0042 log10 -0 -> -Infinity +logx0043 log10 -0E+17 -> -Infinity +logx0044 log10 -0E-17 -> -Infinity +-- other zeros +logx0051 log10 0 -> -Infinity +logx0052 log10 0E+17 -> -Infinity +logx0053 log10 0E-17 -> -Infinity +-- infinities +logx0055 log10 -Infinity -> NaN Invalid_operation +logx0056 log10 +Infinity -> Infinity +-- ones +logx0061 log10 1 -> 0 +logx0062 log10 1.0 -> 0 +logx0063 log10 1.000000000000000 -> 0 +logx0064 log10 1.000000000000000000 -> 0 + +-- notable cases -- exact powers of 10 +logx1100 log10 1 -> 0 +logx1101 log10 10 -> 1 +logx1102 log10 100 -> 2 +logx1103 log10 1000 -> 3 +logx1104 log10 10000 -> 4 +logx1105 log10 100000 -> 5 +logx1106 log10 1000000 -> 6 +logx1107 log10 10000000 -> 7 +logx1108 log10 100000000 -> 8 +logx1109 log10 1000000000 -> 9 +logx1110 log10 10000000000 -> 10 +logx1111 log10 100000000000 -> 11 +logx1112 log10 1000000000000 -> 12 +logx1113 log10 0.00000000001 -> -11 +logx1114 log10 0.0000000001 -> -10 +logx1115 log10 0.000000001 -> -9 +logx1116 log10 0.00000001 -> -8 +logx1117 log10 0.0000001 -> -7 +logx1118 log10 0.000001 -> -6 +logx1119 log10 0.00001 -> -5 +logx1120 log10 0.0001 -> -4 +logx1121 log10 0.001 -> -3 +logx1122 log10 0.01 -> -2 +logx1123 log10 0.1 -> -1 +logx1124 log10 1E-99 -> -99 +logx1125 log10 1E-100 -> -100 +logx1126 log10 1E-383 -> -383 + +-- check normally exact cases round properly +precision: 1 +logx1141 log10 10000000000 -> 1E+1 Rounded +logx1142 log10 1000000000000 -> 1E+1 Inexact Rounded +logx1143 log10 1E+100 -> 1E+2 Rounded +logx1144 log10 1E+123 -> 1E+2 Inexact Rounded +logx1145 log10 1E+126 -> 1E+2 Inexact Rounded +logx1146 log10 1E+916 -> 9E+2 Inexact Rounded +logx1147 log10 1E+999 -> 1E+3 Inexact Rounded + +precision: 2 +logx1151 log10 10000000000 -> 10 +logx1152 log10 1000000000000 -> 12 +logx1153 log10 1E+100 -> 1.0E+2 Rounded +logx1154 log10 1E+123 -> 1.2E+2 Inexact Rounded +logx1155 log10 1E+126 -> 1.3E+2 Inexact Rounded +logx1156 log10 1E+916 -> 9.2E+2 Inexact Rounded +logx1157 log10 1E+999 -> 1.0E+3 Inexact Rounded +-- some half-way point rounds, other cases, and negatives +logx1158 log10 1E+125 -> 1.2E+2 Inexact Rounded +logx1159 log10 1E+135 -> 1.4E+2 Inexact Rounded +logx1160 log10 1E+129 -> 1.3E+2 Inexact Rounded +logx1161 log10 1E+131 -> 1.3E+2 Inexact Rounded +logx1162 log10 1E-123 -> -1.2E+2 Inexact Rounded +logx1163 log10 1E-126 -> -1.3E+2 Inexact Rounded +logx1164 log10 1E-916 -> -9.2E+2 Inexact Rounded +logx1165 log10 1E-999 -> -1.0E+3 Inexact Rounded +logx1166 log10 1E-125 -> -1.2E+2 Inexact Rounded +logx1167 log10 1E-135 -> -1.4E+2 Inexact Rounded +logx1168 log10 1E-129 -> -1.3E+2 Inexact Rounded +logx1169 log10 1E-131 -> -1.3E+2 Inexact Rounded + +precision: 3 +logx1171 log10 10000000000 -> 10 +logx1172 log10 1000000000000 -> 12 +logx1173 log10 1E+100 -> 100 +logx1174 log10 1E+123 -> 123 +logx1175 log10 1E+126 -> 126 +logx1176 log10 1E+916 -> 916 +logx1177 log10 1E+999 -> 999 + +-- log10(2) .. tests both ln(2) and ln(10) constants, too +precision: 50 +logx1201 log10 2 -> 0.30102999566398119521373889472449302676818988146211 Inexact Rounded +logx1202 log10 2.000 -> 0.30102999566398119521373889472449302676818988146211 Inexact Rounded +logx1203 log10 0.2E1 -> 0.30102999566398119521373889472449302676818988146211 Inexact Rounded +precision: 49 +logx1204 log10 2 -> 0.3010299956639811952137388947244930267681898814621 Inexact Rounded +precision: 48 +logx1205 log10 2 -> 0.301029995663981195213738894724493026768189881462 Inexact Rounded +precision: 47 +logx1206 log10 2 -> 0.30102999566398119521373889472449302676818988146 Inexact Rounded +precision: 46 +logx1207 log10 2 -> 0.3010299956639811952137388947244930267681898815 Inexact Rounded +precision: 45 +logx1208 log10 2 -> 0.301029995663981195213738894724493026768189881 Inexact Rounded +precision: 44 +logx1209 log10 2 -> 0.30102999566398119521373889472449302676818988 Inexact Rounded +precision: 43 +logx1210 log10 2 -> 0.3010299956639811952137388947244930267681899 Inexact Rounded +precision: 42 +logx1211 log10 2 -> 0.301029995663981195213738894724493026768190 Inexact Rounded +precision: 41 +logx1212 log10 2 -> 0.30102999566398119521373889472449302676819 Inexact Rounded +precision: 40 +logx1213 log10 2 -> 0.3010299956639811952137388947244930267682 Inexact Rounded +precision: 39 +logx1214 log10 2 -> 0.301029995663981195213738894724493026768 Inexact Rounded +precision: 38 +logx1215 log10 2 -> 0.30102999566398119521373889472449302677 Inexact Rounded +precision: 37 +logx1216 log10 2 -> 0.3010299956639811952137388947244930268 Inexact Rounded +precision: 36 +logx1217 log10 2 -> 0.301029995663981195213738894724493027 Inexact Rounded +precision: 35 +logx1218 log10 2 -> 0.30102999566398119521373889472449303 Inexact Rounded +precision: 34 +logx1219 log10 2 -> 0.3010299956639811952137388947244930 Inexact Rounded +precision: 33 +logx1220 log10 2 -> 0.301029995663981195213738894724493 Inexact Rounded +precision: 32 +logx1221 log10 2 -> 0.30102999566398119521373889472449 Inexact Rounded +precision: 31 +logx1222 log10 2 -> 0.3010299956639811952137388947245 Inexact Rounded +precision: 30 +logx1223 log10 2 -> 0.301029995663981195213738894724 Inexact Rounded +precision: 29 +logx1224 log10 2 -> 0.30102999566398119521373889472 Inexact Rounded +precision: 28 +logx1225 log10 2 -> 0.3010299956639811952137388947 Inexact Rounded +precision: 27 +logx1226 log10 2 -> 0.301029995663981195213738895 Inexact Rounded +precision: 26 +logx1227 log10 2 -> 0.30102999566398119521373889 Inexact Rounded +precision: 25 +logx1228 log10 2 -> 0.3010299956639811952137389 Inexact Rounded +precision: 24 +logx1229 log10 2 -> 0.301029995663981195213739 Inexact Rounded +precision: 23 +logx1230 log10 2 -> 0.30102999566398119521374 Inexact Rounded +precision: 22 +logx1231 log10 2 -> 0.3010299956639811952137 Inexact Rounded +precision: 21 +logx1232 log10 2 -> 0.301029995663981195214 Inexact Rounded +precision: 20 +logx1233 log10 2 -> 0.30102999566398119521 Inexact Rounded +precision: 19 +logx1234 log10 2 -> 0.3010299956639811952 Inexact Rounded +precision: 18 +logx1235 log10 2 -> 0.301029995663981195 Inexact Rounded +precision: 17 +logx1236 log10 2 -> 0.30102999566398120 Inexact Rounded +precision: 16 +logx1237 log10 2 -> 0.3010299956639812 Inexact Rounded +precision: 15 +logx1238 log10 2 -> 0.301029995663981 Inexact Rounded +precision: 14 +logx1239 log10 2 -> 0.30102999566398 Inexact Rounded +precision: 13 +logx1240 log10 2 -> 0.3010299956640 Inexact Rounded +precision: 12 +logx1241 log10 2 -> 0.301029995664 Inexact Rounded +precision: 11 +logx1242 log10 2 -> 0.30102999566 Inexact Rounded +precision: 10 +logx1243 log10 2 -> 0.3010299957 Inexact Rounded +precision: 9 +logx1244 log10 2 -> 0.301029996 Inexact Rounded +precision: 8 +logx1245 log10 2 -> 0.30103000 Inexact Rounded +precision: 7 +logx1246 log10 2 -> 0.3010300 Inexact Rounded +precision: 6 +logx1247 log10 2 -> 0.301030 Inexact Rounded +precision: 5 +logx1248 log10 2 -> 0.30103 Inexact Rounded +precision: 4 +logx1249 log10 2 -> 0.3010 Inexact Rounded +precision: 3 +logx1250 log10 2 -> 0.301 Inexact Rounded +precision: 2 +logx1251 log10 2 -> 0.30 Inexact Rounded +precision: 1 +logx1252 log10 2 -> 0.3 Inexact Rounded + +maxExponent: 384 +minExponent: -383 +precision: 16 +rounding: half_even + +-- More close-to-e, etc., tests +precision: 34 +logx1301 log10 2.718281828459045235360287471352661 -> 0.4342944819032518276511289189166048 Inexact Rounded +logx1302 log10 2.718281828459045235360287471352662 -> 0.4342944819032518276511289189166050 Inexact Rounded +logx1303 log10 2.718281828459045235360287471352663 -> 0.4342944819032518276511289189166052 Inexact Rounded +logx1304 log10 0.99999999999999999999999999999999 -> -4.342944819032518276511289189166073E-33 Inexact Rounded +logx1305 log10 0.999999999999999999999999999999999 -> -4.342944819032518276511289189166053E-34 Inexact Rounded +logx1306 log10 0.9999999999999999999999999999999999 -> -4.342944819032518276511289189166051E-35 Inexact Rounded +logx1307 log10 1.000000000000000000000000000000000 -> 0 +logx1308 log10 1.0000000000000000000000000000000001 -> 4.342944819032518276511289189166051E-35 Inexact Rounded +logx1309 log10 1.000000000000000000000000000000001 -> 4.342944819032518276511289189166049E-34 Inexact Rounded +logx1310 log10 1.00000000000000000000000000000001 -> 4.342944819032518276511289189166029E-33 Inexact Rounded +-- lower p +precision: 7 +logx1320 log10 0.999999 -> -4.342947E-7 Inexact Rounded +logx1321 log10 0.9999999 -> -4.342945E-8 Inexact Rounded +logx1322 log10 0.99999999 -> -4.342945E-9 Inexact Rounded +logx1323 log10 0.999999999 -> -4.342945E-10 Inexact Rounded +logx1324 log10 1.00000000 -> 0 +logx1325 log10 1.00000001 -> 4.342945E-9 Inexact Rounded +logx1326 log10 1.0000001 -> 4.342945E-8 Inexact Rounded +logx1327 log10 1.000001 -> 4.342943E-7 Inexact Rounded + +-- near 10^3 +precision: 9 +logx1331 log10 999.9999998 -> 3.00000000 Inexact Rounded +logx1332 log10 999.9999999 -> 3.00000000 Inexact Rounded +logx1333 log10 1000.000000 -> 3 +logx1334 log10 1000.000001 -> 3.00000000 Inexact Rounded +logx1335 log10 1000.000002 -> 3.00000000 Inexact Rounded +precision: 16 +logx1341 log10 999.9999998 -> 2.999999999913141 Inexact Rounded +logx1342 log10 999.9999999 -> 2.999999999956571 Inexact Rounded +logx1343 log10 1000.000000 -> 3 +logx1344 log10 1000.000001 -> 3.000000000434294 Inexact Rounded +logx1345 log10 1000.000002 -> 3.000000000868589 Inexact Rounded + +-- suggestions from Ilan Nehama +logx1400 log10 10E-3 -> -2 +logx1401 log10 10E-2 -> -1 +logx1402 log10 100E-2 -> 0 +logx1403 log10 1000E-2 -> 1 +logx1404 log10 10000E-2 -> 2 +logx1405 log10 10E-1 -> 0 +logx1406 log10 100E-1 -> 1 +logx1407 log10 1000E-1 -> 2 +logx1408 log10 10000E-1 -> 3 +logx1409 log10 10E0 -> 1 +logx1410 log10 100E0 -> 2 +logx1411 log10 1000E0 -> 3 +logx1412 log10 10000E0 -> 4 +logx1413 log10 10E1 -> 2 +logx1414 log10 100E1 -> 3 +logx1415 log10 1000E1 -> 4 +logx1416 log10 10000E1 -> 5 +logx1417 log10 10E2 -> 3 +logx1418 log10 100E2 -> 4 +logx1419 log10 1000E2 -> 5 +logx1420 log10 10000E2 -> 6 + +-- Randoms +-- P=50, within 0-9999 +Precision: 50 +logx2501 log10 0.00035448001667968141775891246991912655961163345904 -> -3.4504082425411775290864053318247274944685586188505 Inexact Rounded +logx2502 log10 70.636455726424311228255338637935330826995136597644 -> 1.8490288998408492045793070255302335558140975719247 Inexact Rounded +logx2503 log10 0.00000000000000233550362473821889060812804063040169 -> -14.631619454343834858023578299142866557717904223667 Inexact Rounded +logx2504 log10 97.783628621523244679901260358286898958832135433764 -> 1.9902661493224219517897657964362571690592734407330 Inexact Rounded +logx2505 log10 0062.2377135315858392802612812022807838599572017342 -> 1.7940536293085066199287632725026837018486533544141 Inexact Rounded +logx2506 log10 6.3767634652071053619977602804724129652981747879532 -> 0.80460030789825961615100163576080761326857374098644 Inexact Rounded +logx2507 log10 63.297088981313278529306533814195068850532666658798 -> 1.8013837373724427092417170149098614410849353839673 Inexact Rounded +logx2508 log10 0.00000077239693316881797717820110898167721602299187 -> -6.1121594592718550613773886241951966264826760310047 Inexact Rounded +logx2509 log10 0.00000003953580359780185534830572461922527831395002 -> -7.4030094293833847136252547069905477213541787177561 Inexact Rounded +logx2510 log10 754.62905817369989169188998111527272688791544577204 -> 2.8777335243761300047758534304371912099958057545416 Inexact Rounded +logx2511 log10 0.00000048360378410241428936607147056283282849158312 -> -6.3155103095309353457604038397980091650760346334512 Inexact Rounded +logx2512 log10 0.00007509037583645612577196104591672080542932166089 -> -4.1244157219700166314012344705538088030592896111026 Inexact Rounded +logx2513 log10 0.00000000000705475944638915053419839063567898092064 -> -11.151517790256466048553810002525868198178167950377 Inexact Rounded +logx2514 log10 9.6210300460497657917445410947099633479609165120661 -> 0.98322157093260978206633922877716078683518617768411 Inexact Rounded +logx2515 log10 0.00000000050150361386555527496607245976120864985611 -> -9.2997259330798261040411086835563234390934934629340 Inexact Rounded +logx2516 log10 098.24754029731994125797723545333677604490074810751 -> 1.9923216862874337077795278629351060819105679670633 Inexact Rounded +logx2517 log10 7.5091998150046994320441463854301624742491015752980 -> 0.87559366078005924080766469158763499725414024128781 Inexact Rounded +logx2518 log10 0.00000000000079540571273330075193668596942268542425 -> -12.099411294165176028817305108475326325006250936963 Inexact Rounded +logx2519 log10 0.00000042395034799555215782907515074134154915491701 -> -6.3726850039125381134069450802108893075604464135297 Inexact Rounded +logx2520 log10 56.683376304674355481905023145238799909301732694982 -> 1.7534557107853480435703421826077606250636580091754 Inexact Rounded +logx2521 log10 48.734033811444195070807606721517169810438049581227 -> 1.6878323602741065190942654710049433808208291564049 Inexact Rounded +logx2522 log10 0.00074830310930046865009851706989430228561880221063 -> -3.1259224502209974082223667712016445572431791920618 Inexact Rounded +logx2523 log10 36.677348885111593384020836720396262497122708598359 -> 1.5643979364260796086754530282302605477567469395425 Inexact Rounded +logx2524 log10 0.00000000000000004495678560480432858812419145833744 -> -16.347204748239740510014320630363244015916029619561 Inexact Rounded +logx2525 log10 9509.5854013650642799374159131940108748594774307104 -> 3.9781615829916326741100166519726824430945406302661 Inexact Rounded +logx2526 log10 0.07834891268689177014044454793608715276615743819097 -> -1.1059670262197643147805517398621288897669876996348 Inexact Rounded +logx2527 log10 0.00000029584529880706128444454688454999032801904794 -> -6.5289353275814043710076526920566721570375026917206 Inexact Rounded +logx2528 log10 3.0713496544497618098794332787772186176981011904294 -> 0.48732926103896828546424341029492468100431414072994 Inexact Rounded +logx2529 log10 352.66392670788816474407442785460803833927136413943 -> 2.5473610388199562714709836398243933320284077008314 Inexact Rounded +logx2530 log10 0.00304743125181876267210516527361742185617091801650 -> -2.5160660830163981967774124745311497447050056400207 Inexact Rounded +logx2531 log10 0.00000076120535894952136499250364604538117729437183 -> -6.1184981629047051532448413863950776496652483019415 Inexact Rounded +logx2532 log10 769.88795978534353052965286195053735007473187735815 -> 2.8864275277862652709986498581064117950288798222100 Inexact Rounded +logx2533 log10 0.00000000000000041297494808612226304619570016336188 -> -15.384076292745415917510668454361868659468669804710 Inexact Rounded +logx2534 log10 860.88864595714426940247940960258558876903741966974 -> 2.9349469800554277915920278090647283233440859155176 Inexact Rounded +logx2535 log10 5839.0328812994787235900178587371051096898683972444 -> 3.7663409208972392569269125539438874737147906238543 Inexact Rounded +logx2536 log10 0.00000028532710151284840471670497112821201598377841 -> -6.5446569753514027675878879843238065488490618159490 Inexact Rounded +logx2537 log10 0.00000000000000009734490059931638483445631835651581 -> -16.011686794011271135978633880864278692254243106931 Inexact Rounded +logx2538 log10 5.8610949526439529489252302463450302981511714144330 -> 0.76797875722452549281028552067645732490929361952278 Inexact Rounded +logx2539 log10 6.6282432221115923372151148990137179611977576327206 -> 0.82139843639227213211012044000785757267155736071361 Inexact Rounded +logx2540 log10 0.00000000001994071862386846626954819923923344413454 -> -10.700259194632339980266559224447212260115021637626 Inexact Rounded + +-- P=34, within 0-9999 +Precision: 34 +logx2201 log10 1.522513203889714179088327328864183 -> 0.1825610677098896250496651330492109 Inexact Rounded +logx2202 log10 0.171123774769717316154080888930404 -> -0.7666896483548462582461898092764408 Inexact Rounded +logx2203 log10 0.0000000997467236251714283104963838 -> -7.001101360652518274271569010312115 Inexact Rounded +logx2204 log10 0.0008856103624122479769647543468633 -> -3.052757310476070891830490327138190 Inexact Rounded +logx2205 log10 1.938274868738032930709498221236758 -> 0.2874153648259449520201536171714594 Inexact Rounded +logx2206 log10 479.5667847823826713082613445010097 -> 2.680849095850361068709165157286435 Inexact Rounded +logx2207 log10 8856.136599178820202141823157336804 -> 3.947244306584767101480454261950559 Inexact Rounded +logx2208 log10 0.0000911026318801903982642871344858 -> -4.040469076434979398438617464033826 Inexact Rounded +logx2209 log10 0.0000000000017271112650427414732630 -> -11.76267968314038748995178212654921 Inexact Rounded +logx2210 log10 6.962605370078885647639503548229695 -> 0.8427717807200322352686396925992250 Inexact Rounded +logx2211 log10 0.3354804428992793132855923541692781 -> -0.4743327923012159170967636070844834 Inexact Rounded +logx2212 log10 2.079864257474859008252165836663504 -> 0.3180349916198059046812506741388856 Inexact Rounded +logx2213 log10 2805.479529292939499220276986621988 -> 3.448007104139974344565978780624744 Inexact Rounded +logx2214 log10 66.45731133034187374557028537213949 -> 1.822542767005644041661520936223086 Inexact Rounded +logx2215 log10 0.0000001206521261762681738274822835 -> -6.918465020390216969561494755767318 Inexact Rounded +logx2216 log10 0.0000000001884891916264401160472381 -> -9.724713548119065386091933007528633 Inexact Rounded +logx2217 log10 0.0000015467279551726326581314582759 -> -5.810586065070435383755759514608738 Inexact Rounded +logx2218 log10 0.0090776316728068586744633914135952 -> -2.042027442843745884503280954390114 Inexact Rounded +logx2219 log10 0.0000000000024541106528713393740030 -> -11.61010585935635713090119156069479 Inexact Rounded +logx2220 log10 14.12936879385863410081087750645856 -> 1.150122760895466989841057385742662 Inexact Rounded +logx2221 log10 0.0000036912481831392922922647231392 -> -5.432826753789892283556211380824203 Inexact Rounded +logx2222 log10 0.0000000004067477525420424270138734 -> -9.390674838050073122857868012475060 Inexact Rounded +logx2223 log10 7080.122562705399744969319589806194 -> 3.850040775747103318724330047546916 Inexact Rounded +logx2224 log10 261.3491411363679209175524790255725 -> 2.417221077227536319655699517530855 Inexact Rounded +logx2225 log10 003.9945581449915240094728380041494 -> 0.6014687471531988260823066997845691 Inexact Rounded +logx2226 log10 0.0000000000583549164588495206767840 -> -10.23392254834182677023231713519341 Inexact Rounded +logx2227 log10 9567.961832607240278342761088487484 -> 3.980819434211107631569386147016368 Inexact Rounded +logx2228 log10 06.26592979160342972777219828867033 -> 0.7969855243966221408595024012574729 Inexact Rounded +logx2229 log10 0.0000000000589847046598067273287319 -> -10.22926059078206218717755253582907 Inexact Rounded +logx2230 log10 567.9388648235589204769442863724997 -> 2.754301589058313576472380262907638 Inexact Rounded +logx2231 log10 039.7790325480037778918162264883415 -> 1.599654216592019199639285308997886 Inexact Rounded +logx2232 log10 0.0000000005123951921894162149817207 -> -9.290394953898862694847327137242690 Inexact Rounded +logx2233 log10 0.0000000000038500999723636904276723 -> -11.41452799337924056186867324854691 Inexact Rounded +logx2234 log10 0.0006726500658977759825616537935864 -> -3.172210810922768725687671849421792 Inexact Rounded +logx2235 log10 260.2400250475967528429943779126507 -> 2.415374092073799204236801383070064 Inexact Rounded +logx2236 log10 0.0000000006101942339385102585042548 -> -9.214531900562046557191261226632509 Inexact Rounded +logx2237 log10 0.0000000010846867501382746760066557 -> -8.964695664883282406359874242387236 Inexact Rounded +logx2238 log10 60.24078375568814769010333711509928 -> 1.779890613567084253168373266648922 Inexact Rounded +logx2239 log10 0.0012058738711757669337600252986093 -> -2.918698115012605915753728220896010 Inexact Rounded +logx2240 log10 230.9450930197841600611503095185600 -> 2.363508739056822846742942599628966 Inexact Rounded + +-- P=16, within 0-999 +Precision: 16 +logx2101 log10 0.0072067119605184 -> -2.142262835573038 Inexact Rounded +logx2102 log10 503.6828482226624 -> 2.702157162195652 Inexact Rounded +logx2103 log10 64.96074447821815 -> 1.812650993464174 Inexact Rounded +logx2104 log10 48.75408597467246 -> 1.688011018842600 Inexact Rounded +logx2105 log10 0.0329009839269587 -> -1.482791113975280 Inexact Rounded +logx2106 log10 223.5320415060633 -> 2.349339784523410 Inexact Rounded +logx2107 log10 73.12765002292194 -> 1.864081617476268 Inexact Rounded +logx2108 log10 487.3749378358509 -> 2.687863192802252 Inexact Rounded +logx2109 log10 0.0000019671987621 -> -5.706151757557926 Inexact Rounded +logx2110 log10 0.0570680660609784 -> -1.243606844697873 Inexact Rounded +logx2111 log10 33.10311638788998 -> 1.519868880976773 Inexact Rounded +logx2112 log10 0.0687382699187077 -> -1.162801402868185 Inexact Rounded +logx2113 log10 258.9416193626484 -> 2.413201859654145 Inexact Rounded +logx2114 log10 0.0005306100136736 -> -3.275224558269725 Inexact Rounded +logx2115 log10 65.78490393408572 -> 1.818126244825109 Inexact Rounded +logx2116 log10 504.2328842073510 -> 2.702631165346958 Inexact Rounded +logx2117 log10 9.417432755815027 -> 0.9739325278524503 Inexact Rounded +logx2118 log10 006.7054835355498 -> 0.8264301004947640 Inexact Rounded +logx2119 log10 0.0917012272363915 -> -1.037624852133399 Inexact Rounded +logx2120 log10 5.959404385244921 -> 0.7752028561953401 Inexact Rounded +logx2121 log10 0.0001209759148486 -> -3.917301084968903 Inexact Rounded +logx2122 log10 0.0004706112139838 -> -3.327337728428039 Inexact Rounded +logx2123 log10 0.0069700457377046 -> -2.156764372035771 Inexact Rounded +logx2124 log10 0.5155584569852619 -> -0.2877220847805025 Inexact Rounded +logx2125 log10 88.06005885607414 -> 1.944778971389913 Inexact Rounded +logx2126 log10 0.0448240038219866 -> -1.348489353509709 Inexact Rounded +logx2127 log10 3.419622484059565 -> 0.5339781639101145 Inexact Rounded +logx2128 log10 5.171123353858721 -> 0.7135848977142854 Inexact Rounded +logx2129 log10 0.0002133188319807 -> -3.670970802945872 Inexact Rounded +logx2130 log10 46.21086703136966 -> 1.664744117045149 Inexact Rounded +logx2131 log10 0.0000631053714415 -> -4.199933672639880 Inexact Rounded +logx2132 log10 78.66019196870698 -> 1.895755001962469 Inexact Rounded +logx2133 log10 0.0007152278351188 -> -3.145555592082297 Inexact Rounded +logx2134 log10 45.52509819928536 -> 1.658250891256892 Inexact Rounded +logx2135 log10 0.0000703227795740 -> -4.152903971697183 Inexact Rounded +logx2136 log10 26.24438641426669 -> 1.419036423550599 Inexact Rounded +logx2137 log10 0.0000044654829535 -> -5.350131564166817 Inexact Rounded +logx2138 log10 0.7360702733062529 -> -0.1330807211893611 Inexact Rounded +logx2139 log10 8.417059176469655 -> 0.9251603805112778 Inexact Rounded +logx2140 log10 0.0002926570767968 -> -3.533640969664818 Inexact Rounded + +-- P=7, within 0-99 +Precision: 7 +logx2001 log10 57.26089 -> 1.757858 Inexact Rounded +logx2002 log10 0.0575421 -> -1.240014 Inexact Rounded +logx2003 log10 0.5918465 -> -0.2277909 Inexact Rounded +logx2004 log10 0.0068776 -> -2.162563 Inexact Rounded +logx2005 log10 0.0066833 -> -2.175009 Inexact Rounded +logx2006 log10 9.926963 -> 0.9968164 Inexact Rounded +logx2007 log10 0.0041852 -> -2.378284 Inexact Rounded +logx2008 log10 84.15412 -> 1.925075 Inexact Rounded +logx2009 log10 2.466856 -> 0.3921438 Inexact Rounded +logx2010 log10 0.0058047 -> -2.236220 Inexact Rounded +logx2011 log10 9.885154 -> 0.9949834 Inexact Rounded +logx2012 log10 0.6667654 -> -0.1760269 Inexact Rounded +logx2013 log10 34.65736 -> 1.539795 Inexact Rounded +logx2014 log10 0.0026884 -> -2.570506 Inexact Rounded +logx2015 log10 0.0432767 -> -1.363746 Inexact Rounded +logx2016 log10 66.01407 -> 1.819637 Inexact Rounded +logx2017 log10 0.0070572 -> -2.151368 Inexact Rounded +logx2018 log10 0.0731613 -> -1.135719 Inexact Rounded +logx2019 log10 9.838983 -> 0.9929502 Inexact Rounded +logx2020 log10 15.89696 -> 1.201314 Inexact Rounded +logx2021 log10 8.459247 -> 0.9273317 Inexact Rounded +logx2022 log10 0.0010873 -> -2.963651 Inexact Rounded +logx2023 log10 0.6498619 -> -0.1871789 Inexact Rounded +logx2024 log10 0.0847008 -> -1.072112 Inexact Rounded +logx2025 log10 0.0075489 -> -2.122116 Inexact Rounded +logx2026 log10 51.11152 -> 1.708519 Inexact Rounded +logx2027 log10 0.7233866 -> -0.1406295 Inexact Rounded +logx2028 log10 2.254721 -> 0.3530928 Inexact Rounded +logx2029 log10 6.568444 -> 0.8174625 Inexact Rounded +logx2030 log10 83.72639 -> 1.922862 Inexact Rounded +logx2031 log10 6.720585 -> 0.8274071 Inexact Rounded +logx2032 log10 87.90366 -> 1.944007 Inexact Rounded +logx2033 log10 0.0433324 -> -1.363187 Inexact Rounded +logx2034 log10 34.63912 -> 1.539567 Inexact Rounded +logx2035 log10 0.8089059 -> -0.09210200 Inexact Rounded +logx2036 log10 7.793405 -> 0.8917272 Inexact Rounded +logx2037 log10 0.0041757 -> -2.379271 Inexact Rounded +logx2038 log10 7.135417 -> 0.8534194 Inexact Rounded +logx2039 log10 12.49570 -> 1.096761 Inexact Rounded +logx2040 log10 6.356276 -> 0.8032027 Inexact Rounded + +-------- +maxExponent: 384 +minExponent: -383 +precision: 16 +rounding: half_even + +-- special values +logx820 log10 Infinity -> Infinity +logx821 log10 0 -> -Infinity +logx822 log10 NaN -> NaN +logx823 log10 sNaN -> NaN Invalid_operation +-- propagating NaNs +logx824 log10 sNaN123 -> NaN123 Invalid_operation +logx825 log10 -sNaN321 -> -NaN321 Invalid_operation +logx826 log10 NaN456 -> NaN456 +logx827 log10 -NaN654 -> -NaN654 +logx828 log10 NaN1 -> NaN1 + + +-- Invalid operations due to restrictions +-- [next two probably skipped by most test harnesses] +precision: 100000000 +logx901 log10 1 -> NaN Invalid_context +precision: 99999999 +logx902 log10 0 -> NaN Invalid_context + +precision: 9 +maxExponent: 1000000 +minExponent: -999999 +logx903 log10 1 -> NaN Invalid_context +maxExponent: 999999 +minExponent: -999999 +logx904 log10 0 -> -Infinity +maxExponent: 999999 +minExponent: -1000000 +logx905 log10 1 -> NaN Invalid_context +maxExponent: 999999 +minExponent: -999998 +logx906 log10 0 -> -Infinity + +-- Null test +logx900 log10 # -> NaN Invalid_operation + + Added: python/branches/release25-maint/Lib/test/decimaltestdata/logb.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/logb.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,162 @@ +------------------------------------------------------------------------ +-- logb.decTest -- return integral adjusted exponent as per 754r -- +-- Copyright (c) IBM Corporation, 2005, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- This emphasises the testing of notable cases, as they will often +-- have unusual paths (especially the 10**n results). + +extended: 1 +rounding: half_even +maxExponent: 999 +minexponent: -999 + +-- basics & examples +precision: 9 +logbx001 logb 0 -> -Infinity Division_by_zero +logbx002 logb 1E-999 -> -999 +logbx003 logb 9E-999 -> -999 +logbx004 logb 0.001 -> -3 +logbx005 logb 0.03 -> -2 +logbx006 logb 1 -> 0 +logbx007 logb 2 -> 0 +logbx008 logb 2.5 -> 0 +logbx009 logb 2.50 -> 0 +logbx010 logb 10 -> 1 +logbx011 logb 70 -> 1 +logbx012 logb 100 -> 2 +logbx013 logb 250 -> 2 +logbx014 logb +Infinity -> Infinity + +-- negatives are treated as positives +logbx021 logb -0 -> -Infinity Division_by_zero +logbx022 logb -1E-999 -> -999 +logbx023 logb -9E-999 -> -999 +logbx024 logb -0.001 -> -3 +logbx025 logb -1 -> 0 +logbx026 logb -2 -> 0 +logbx027 logb -10 -> 1 +logbx028 logb -70 -> 1 +logbx029 logb -100 -> 2 +logbx030 logb -100000000 -> 8 +logbx031 logb -Infinity -> Infinity + +-- zeros +logbx111 logb 0 -> -Infinity Division_by_zero +logbx112 logb -0 -> -Infinity Division_by_zero +logbx113 logb 0E+4 -> -Infinity Division_by_zero +logbx114 logb -0E+4 -> -Infinity Division_by_zero +logbx115 logb 0.0000 -> -Infinity Division_by_zero +logbx116 logb -0.0000 -> -Infinity Division_by_zero +logbx117 logb 0E-141 -> -Infinity Division_by_zero +logbx118 logb -0E-141 -> -Infinity Division_by_zero + +-- full coefficients, alternating bits +logbx121 logb 268268268 -> 8 +logbx122 logb -268268268 -> 8 +logbx123 logb 134134134 -> 8 +logbx124 logb -134134134 -> 8 + +-- Nmax, Nmin, Ntiny +logbx131 logb 9.99999999E+999 -> 999 +logbx132 logb 1E-999 -> -999 +logbx133 logb 1.00000000E-999 -> -999 +logbx134 logb 1E-1007 -> -1007 + +logbx135 logb -1E-1007 -> -1007 +logbx136 logb -1.00000000E-999 -> -999 +logbx137 logb -1E-999 -> -999 +logbx138 logb -9.99999999E+999 -> 999 + +-- ones +logbx0061 logb 1 -> 0 +logbx0062 logb 1.0 -> 0 +logbx0063 logb 1.000000000000000 -> 0 +logbx0064 logb 1.000000000000000000 -> 0 + +-- notable cases -- exact powers of 10 +logbx1100 logb 1 -> 0 +logbx1101 logb 10 -> 1 +logbx1102 logb 100 -> 2 +logbx1103 logb 1000 -> 3 +logbx1104 logb 10000 -> 4 +logbx1105 logb 100000 -> 5 +logbx1106 logb 1000000 -> 6 +logbx1107 logb 10000000 -> 7 +logbx1108 logb 100000000 -> 8 +logbx1109 logb 1000000000 -> 9 +logbx1110 logb 10000000000 -> 10 +logbx1111 logb 100000000000 -> 11 +logbx1112 logb 1000000000000 -> 12 +logbx1113 logb 0.00000000001 -> -11 +logbx1114 logb 0.0000000001 -> -10 +logbx1115 logb 0.000000001 -> -9 +logbx1116 logb 0.00000001 -> -8 +logbx1117 logb 0.0000001 -> -7 +logbx1118 logb 0.000001 -> -6 +logbx1119 logb 0.00001 -> -5 +logbx1120 logb 0.0001 -> -4 +logbx1121 logb 0.001 -> -3 +logbx1122 logb 0.01 -> -2 +logbx1123 logb 0.1 -> -1 +logbx1124 logb 1E-99 -> -99 +logbx1125 logb 1E-100 -> -100 +logbx1126 logb 1E-383 -> -383 +logbx1127 logb 1E-999 -> -999 + +-- suggestions from Ilan Nehama +logbx1400 logb 10E-3 -> -2 +logbx1401 logb 10E-2 -> -1 +logbx1402 logb 100E-2 -> 0 +logbx1403 logb 1000E-2 -> 1 +logbx1404 logb 10000E-2 -> 2 +logbx1405 logb 10E-1 -> 0 +logbx1406 logb 100E-1 -> 1 +logbx1407 logb 1000E-1 -> 2 +logbx1408 logb 10000E-1 -> 3 +logbx1409 logb 10E0 -> 1 +logbx1410 logb 100E0 -> 2 +logbx1411 logb 1000E0 -> 3 +logbx1412 logb 10000E0 -> 4 +logbx1413 logb 10E1 -> 2 +logbx1414 logb 100E1 -> 3 +logbx1415 logb 1000E1 -> 4 +logbx1416 logb 10000E1 -> 5 +logbx1417 logb 10E2 -> 3 +logbx1418 logb 100E2 -> 4 +logbx1419 logb 1000E2 -> 5 +logbx1420 logb 10000E2 -> 6 + +-- special values +logbx820 logb Infinity -> Infinity +logbx821 logb -Infinity -> Infinity +logbx822 logb 0 -> -Infinity Division_by_zero +logbx823 logb NaN -> NaN +logbx824 logb sNaN -> NaN Invalid_operation +-- propagating NaNs +logbx825 logb sNaN123 -> NaN123 Invalid_operation +logbx826 logb -sNaN321 -> -NaN321 Invalid_operation +logbx827 logb NaN456 -> NaN456 +logbx828 logb -NaN654 -> -NaN654 +logbx829 logb NaN1 -> NaN1 + +-- Null test +logbx900 logb # -> NaN Invalid_operation + + Modified: python/branches/release25-maint/Lib/test/decimaltestdata/max.decTest ============================================================================== --- python/branches/release25-maint/Lib/test/decimaltestdata/max.decTest (original) +++ python/branches/release25-maint/Lib/test/decimaltestdata/max.decTest Tue Jan 8 17:20:31 2008 @@ -1,6 +1,6 @@ ------------------------------------------------------------------------ -- max.decTest -- decimal maximum -- --- Copyright (c) IBM Corporation, 1981, 2004. All rights reserved. -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- ------------------------------------------------------------------------ -- Please see the document "General Decimal Arithmetic Testcases" -- -- at http://www2.hursley.ibm.com/decimal for the description of -- @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc at uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.39 +version: 2.57 -- we assume that base comparison is tested in compare.decTest, so -- these mainly cover special cases and rounding @@ -331,6 +331,33 @@ maxx466 max -1000 -1E+3 -> -1000 maxx467 max -1E+3 -1000 -> -1000 +-- rounding (results treated as though plus) +maxexponent: 999999999 +minexponent: -999999999 +precision: 3 + +maxx470 max 1 .5 -> 1 +maxx471 max 10 5 -> 10 +maxx472 max 100 50 -> 100 +maxx473 max 1000 500 -> 1.00E+3 Rounded +maxx474 max 10000 5000 -> 1.00E+4 Rounded +maxx475 max 6 .5 -> 6 +maxx476 max 66 5 -> 66 +maxx477 max 666 50 -> 666 +maxx478 max 6666 500 -> 6.67E+3 Rounded Inexact +maxx479 max 66666 5000 -> 6.67E+4 Rounded Inexact +maxx480 max 33333 5000 -> 3.33E+4 Rounded Inexact +maxx481 max .5 1 -> 1 +maxx482 max .5 10 -> 10 +maxx483 max .5 100 -> 100 +maxx484 max .5 1000 -> 1.00E+3 Rounded +maxx485 max .5 10000 -> 1.00E+4 Rounded +maxx486 max .5 6 -> 6 +maxx487 max .5 66 -> 66 +maxx488 max .5 666 -> 666 +maxx489 max .5 6666 -> 6.67E+3 Rounded Inexact +maxx490 max .5 66666 -> 6.67E+4 Rounded Inexact +maxx491 max .5 33333 -> 3.33E+4 Rounded Inexact -- overflow tests maxexponent: 999999999 @@ -348,13 +375,13 @@ maxx512 max 0.10E-999 0 -> 1.0E-1000 Subnormal maxx513 max 0.100E-999 0 -> 1.0E-1000 Subnormal Rounded maxx514 max 0.01E-999 0 -> 1E-1001 Subnormal --- next is rounded to Emin +-- next is rounded to Nmin maxx515 max 0.999E-999 0 -> 1.00E-999 Inexact Rounded Subnormal Underflow maxx516 max 0.099E-999 0 -> 1.0E-1000 Inexact Rounded Subnormal Underflow maxx517 max 0.009E-999 0 -> 1E-1001 Inexact Rounded Subnormal Underflow -maxx518 max 0.001E-999 0 -> 0E-1001 Inexact Rounded Subnormal Underflow -maxx519 max 0.0009E-999 0 -> 0E-1001 Inexact Rounded Subnormal Underflow -maxx520 max 0.0001E-999 0 -> 0E-1001 Inexact Rounded Subnormal Underflow +maxx518 max 0.001E-999 0 -> 0E-1001 Inexact Rounded Subnormal Underflow Clamped +maxx519 max 0.0009E-999 0 -> 0E-1001 Inexact Rounded Subnormal Underflow Clamped +maxx520 max 0.0001E-999 0 -> 0E-1001 Inexact Rounded Subnormal Underflow Clamped maxx530 max -1.00E-999 0 -> 0 maxx531 max -0.1E-999 0 -> 0 @@ -368,6 +395,27 @@ maxx539 max -0.0009E-999 0 -> 0 maxx540 max -0.0001E-999 0 -> 0 +-- misalignment traps for little-endian +precision: 9 +maxx551 max 1.0 0.1 -> 1.0 +maxx552 max 0.1 1.0 -> 1.0 +maxx553 max 10.0 0.1 -> 10.0 +maxx554 max 0.1 10.0 -> 10.0 +maxx555 max 100 1.0 -> 100 +maxx556 max 1.0 100 -> 100 +maxx557 max 1000 10.0 -> 1000 +maxx558 max 10.0 1000 -> 1000 +maxx559 max 10000 100.0 -> 10000 +maxx560 max 100.0 10000 -> 10000 +maxx661 max 100000 1000.0 -> 100000 +maxx662 max 1000.0 100000 -> 100000 +maxx663 max 1000000 10000.0 -> 1000000 +maxx664 max 10000.0 1000000 -> 1000000 + +-- payload decapitate +precision: 5 +maxx670 max 11 -sNaN12345678901 -> -NaN78901 Invalid_operation + -- Null tests maxx900 max 10 # -> NaN Invalid_operation maxx901 max # 10 -> NaN Invalid_operation Added: python/branches/release25-maint/Lib/test/decimaltestdata/maxmag.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/maxmag.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,404 @@ +------------------------------------------------------------------------ +-- maxmag.decTest -- decimal maximum by magnitude -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- we assume that base comparison is tested in compare.decTest, so +-- these mainly cover special cases and rounding + +extended: 1 +precision: 9 +rounding: half_up +maxExponent: 384 +minexponent: -383 + +-- sanity checks +mxgx001 maxmag -2 -2 -> -2 +mxgx002 maxmag -2 -1 -> -2 +mxgx003 maxmag -2 0 -> -2 +mxgx004 maxmag -2 1 -> -2 +mxgx005 maxmag -2 2 -> 2 +mxgx006 maxmag -1 -2 -> -2 +mxgx007 maxmag -1 -1 -> -1 +mxgx008 maxmag -1 0 -> -1 +mxgx009 maxmag -1 1 -> 1 +mxgx010 maxmag -1 2 -> 2 +mxgx011 maxmag 0 -2 -> -2 +mxgx012 maxmag 0 -1 -> -1 +mxgx013 maxmag 0 0 -> 0 +mxgx014 maxmag 0 1 -> 1 +mxgx015 maxmag 0 2 -> 2 +mxgx016 maxmag 1 -2 -> -2 +mxgx017 maxmag 1 -1 -> 1 +mxgx018 maxmag 1 0 -> 1 +mxgx019 maxmag 1 1 -> 1 +mxgx020 maxmag 1 2 -> 2 +mxgx021 maxmag 2 -2 -> 2 +mxgx022 maxmag 2 -1 -> 2 +mxgx023 maxmag 2 0 -> 2 +mxgx025 maxmag 2 1 -> 2 +mxgx026 maxmag 2 2 -> 2 + +-- extended zeros +mxgx030 maxmag 0 0 -> 0 +mxgx031 maxmag 0 -0 -> 0 +mxgx032 maxmag 0 -0.0 -> 0 +mxgx033 maxmag 0 0.0 -> 0 +mxgx034 maxmag -0 0 -> 0 -- note: -0 = 0, but 0 chosen +mxgx035 maxmag -0 -0 -> -0 +mxgx036 maxmag -0 -0.0 -> -0.0 +mxgx037 maxmag -0 0.0 -> 0.0 +mxgx038 maxmag 0.0 0 -> 0 +mxgx039 maxmag 0.0 -0 -> 0.0 +mxgx040 maxmag 0.0 -0.0 -> 0.0 +mxgx041 maxmag 0.0 0.0 -> 0.0 +mxgx042 maxmag -0.0 0 -> 0 +mxgx043 maxmag -0.0 -0 -> -0.0 +mxgx044 maxmag -0.0 -0.0 -> -0.0 +mxgx045 maxmag -0.0 0.0 -> 0.0 + +mxgx050 maxmag -0E1 0E1 -> 0E+1 +mxgx051 maxmag -0E2 0E2 -> 0E+2 +mxgx052 maxmag -0E2 0E1 -> 0E+1 +mxgx053 maxmag -0E1 0E2 -> 0E+2 +mxgx054 maxmag 0E1 -0E1 -> 0E+1 +mxgx055 maxmag 0E2 -0E2 -> 0E+2 +mxgx056 maxmag 0E2 -0E1 -> 0E+2 +mxgx057 maxmag 0E1 -0E2 -> 0E+1 + +mxgx058 maxmag 0E1 0E1 -> 0E+1 +mxgx059 maxmag 0E2 0E2 -> 0E+2 +mxgx060 maxmag 0E2 0E1 -> 0E+2 +mxgx061 maxmag 0E1 0E2 -> 0E+2 +mxgx062 maxmag -0E1 -0E1 -> -0E+1 +mxgx063 maxmag -0E2 -0E2 -> -0E+2 +mxgx064 maxmag -0E2 -0E1 -> -0E+1 +mxgx065 maxmag -0E1 -0E2 -> -0E+1 + +-- Specials +precision: 9 +mxgx090 maxmag Inf -Inf -> Infinity +mxgx091 maxmag Inf -1000 -> Infinity +mxgx092 maxmag Inf -1 -> Infinity +mxgx093 maxmag Inf -0 -> Infinity +mxgx094 maxmag Inf 0 -> Infinity +mxgx095 maxmag Inf 1 -> Infinity +mxgx096 maxmag Inf 1000 -> Infinity +mxgx097 maxmag Inf Inf -> Infinity +mxgx098 maxmag -1000 Inf -> Infinity +mxgx099 maxmag -Inf Inf -> Infinity +mxgx100 maxmag -1 Inf -> Infinity +mxgx101 maxmag -0 Inf -> Infinity +mxgx102 maxmag 0 Inf -> Infinity +mxgx103 maxmag 1 Inf -> Infinity +mxgx104 maxmag 1000 Inf -> Infinity +mxgx105 maxmag Inf Inf -> Infinity + +mxgx120 maxmag -Inf -Inf -> -Infinity +mxgx121 maxmag -Inf -1000 -> -Infinity +mxgx122 maxmag -Inf -1 -> -Infinity +mxgx123 maxmag -Inf -0 -> -Infinity +mxgx124 maxmag -Inf 0 -> -Infinity +mxgx125 maxmag -Inf 1 -> -Infinity +mxgx126 maxmag -Inf 1000 -> -Infinity +mxgx127 maxmag -Inf Inf -> Infinity +mxgx128 maxmag -Inf -Inf -> -Infinity +mxgx129 maxmag -1000 -Inf -> -Infinity +mxgx130 maxmag -1 -Inf -> -Infinity +mxgx131 maxmag -0 -Inf -> -Infinity +mxgx132 maxmag 0 -Inf -> -Infinity +mxgx133 maxmag 1 -Inf -> -Infinity +mxgx134 maxmag 1000 -Inf -> -Infinity +mxgx135 maxmag Inf -Inf -> Infinity + +-- 2004.08.02 754r chooses number over NaN in mixed cases +mxgx141 maxmag NaN -Inf -> -Infinity +mxgx142 maxmag NaN -1000 -> -1000 +mxgx143 maxmag NaN -1 -> -1 +mxgx144 maxmag NaN -0 -> -0 +mxgx145 maxmag NaN 0 -> 0 +mxgx146 maxmag NaN 1 -> 1 +mxgx147 maxmag NaN 1000 -> 1000 +mxgx148 maxmag NaN Inf -> Infinity +mxgx149 maxmag NaN NaN -> NaN +mxgx150 maxmag -Inf NaN -> -Infinity +mxgx151 maxmag -1000 NaN -> -1000 +mxgx152 maxmag -1 NaN -> -1 +mxgx153 maxmag -0 NaN -> -0 +mxgx154 maxmag 0 NaN -> 0 +mxgx155 maxmag 1 NaN -> 1 +mxgx156 maxmag 1000 NaN -> 1000 +mxgx157 maxmag Inf NaN -> Infinity + +mxgx161 maxmag sNaN -Inf -> NaN Invalid_operation +mxgx162 maxmag sNaN -1000 -> NaN Invalid_operation +mxgx163 maxmag sNaN -1 -> NaN Invalid_operation +mxgx164 maxmag sNaN -0 -> NaN Invalid_operation +mxgx165 maxmag sNaN 0 -> NaN Invalid_operation +mxgx166 maxmag sNaN 1 -> NaN Invalid_operation +mxgx167 maxmag sNaN 1000 -> NaN Invalid_operation +mxgx168 maxmag sNaN NaN -> NaN Invalid_operation +mxgx169 maxmag sNaN sNaN -> NaN Invalid_operation +mxgx170 maxmag NaN sNaN -> NaN Invalid_operation +mxgx171 maxmag -Inf sNaN -> NaN Invalid_operation +mxgx172 maxmag -1000 sNaN -> NaN Invalid_operation +mxgx173 maxmag -1 sNaN -> NaN Invalid_operation +mxgx174 maxmag -0 sNaN -> NaN Invalid_operation +mxgx175 maxmag 0 sNaN -> NaN Invalid_operation +mxgx176 maxmag 1 sNaN -> NaN Invalid_operation +mxgx177 maxmag 1000 sNaN -> NaN Invalid_operation +mxgx178 maxmag Inf sNaN -> NaN Invalid_operation +mxgx179 maxmag NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +mxgx181 maxmag NaN9 -Inf -> -Infinity +mxgx182 maxmag NaN8 9 -> 9 +mxgx183 maxmag -NaN7 Inf -> Infinity + +mxgx184 maxmag -NaN1 NaN11 -> -NaN1 +mxgx185 maxmag NaN2 NaN12 -> NaN2 +mxgx186 maxmag -NaN13 -NaN7 -> -NaN13 +mxgx187 maxmag NaN14 -NaN5 -> NaN14 + +mxgx188 maxmag -Inf NaN4 -> -Infinity +mxgx189 maxmag -9 -NaN3 -> -9 +mxgx190 maxmag Inf NaN2 -> Infinity + +mxgx191 maxmag sNaN99 -Inf -> NaN99 Invalid_operation +mxgx192 maxmag sNaN98 -1 -> NaN98 Invalid_operation +mxgx193 maxmag -sNaN97 NaN -> -NaN97 Invalid_operation +mxgx194 maxmag sNaN96 sNaN94 -> NaN96 Invalid_operation +mxgx195 maxmag NaN95 sNaN93 -> NaN93 Invalid_operation +mxgx196 maxmag -Inf sNaN92 -> NaN92 Invalid_operation +mxgx197 maxmag 0 sNaN91 -> NaN91 Invalid_operation +mxgx198 maxmag Inf -sNaN90 -> -NaN90 Invalid_operation +mxgx199 maxmag NaN sNaN89 -> NaN89 Invalid_operation + +-- rounding checks +maxexponent: 999 +minexponent: -999 +precision: 9 +mxgx201 maxmag 12345678000 1 -> 1.23456780E+10 Rounded +mxgx202 maxmag 1 12345678000 -> 1.23456780E+10 Rounded +mxgx203 maxmag 1234567800 1 -> 1.23456780E+9 Rounded +mxgx204 maxmag 1 1234567800 -> 1.23456780E+9 Rounded +mxgx205 maxmag 1234567890 1 -> 1.23456789E+9 Rounded +mxgx206 maxmag 1 1234567890 -> 1.23456789E+9 Rounded +mxgx207 maxmag 1234567891 1 -> 1.23456789E+9 Inexact Rounded +mxgx208 maxmag 1 1234567891 -> 1.23456789E+9 Inexact Rounded +mxgx209 maxmag 12345678901 1 -> 1.23456789E+10 Inexact Rounded +mxgx210 maxmag 1 12345678901 -> 1.23456789E+10 Inexact Rounded +mxgx211 maxmag 1234567896 1 -> 1.23456790E+9 Inexact Rounded +mxgx212 maxmag 1 1234567896 -> 1.23456790E+9 Inexact Rounded +mxgx213 maxmag -1234567891 1 -> -1.23456789E+9 Inexact Rounded +mxgx214 maxmag 1 -1234567891 -> -1.23456789E+9 Inexact Rounded +mxgx215 maxmag -12345678901 1 -> -1.23456789E+10 Inexact Rounded +mxgx216 maxmag 1 -12345678901 -> -1.23456789E+10 Inexact Rounded +mxgx217 maxmag -1234567896 1 -> -1.23456790E+9 Inexact Rounded +mxgx218 maxmag 1 -1234567896 -> -1.23456790E+9 Inexact Rounded + +precision: 15 +mxgx221 maxmag 12345678000 1 -> 12345678000 +mxgx222 maxmag 1 12345678000 -> 12345678000 +mxgx223 maxmag 1234567800 1 -> 1234567800 +mxgx224 maxmag 1 1234567800 -> 1234567800 +mxgx225 maxmag 1234567890 1 -> 1234567890 +mxgx226 maxmag 1 1234567890 -> 1234567890 +mxgx227 maxmag 1234567891 1 -> 1234567891 +mxgx228 maxmag 1 1234567891 -> 1234567891 +mxgx229 maxmag 12345678901 1 -> 12345678901 +mxgx230 maxmag 1 12345678901 -> 12345678901 +mxgx231 maxmag 1234567896 1 -> 1234567896 +mxgx232 maxmag 1 1234567896 -> 1234567896 +mxgx233 maxmag -1234567891 1 -> -1234567891 +mxgx234 maxmag 1 -1234567891 -> -1234567891 +mxgx235 maxmag -12345678901 1 -> -12345678901 +mxgx236 maxmag 1 -12345678901 -> -12345678901 +mxgx237 maxmag -1234567896 1 -> -1234567896 +mxgx238 maxmag 1 -1234567896 -> -1234567896 + +-- from examples +mxgx280 maxmag '3' '2' -> '3' +mxgx281 maxmag '-10' '3' -> '-10' +mxgx282 maxmag '1.0' '1' -> '1' +mxgx283 maxmag '1' '1.0' -> '1' +mxgx284 maxmag '7' 'NaN' -> '7' + +-- overflow and underflow tests ... +maxExponent: 999999999 +minexponent: -999999999 +mxgx330 maxmag +1.23456789012345E-0 9E+999999999 -> 9E+999999999 +mxgx331 maxmag 9E+999999999 +1.23456789012345E-0 -> 9E+999999999 +mxgx332 maxmag +0.100 9E-999999999 -> 0.100 +mxgx333 maxmag 9E-999999999 +0.100 -> 0.100 +mxgx335 maxmag -1.23456789012345E-0 9E+999999999 -> 9E+999999999 +mxgx336 maxmag 9E+999999999 -1.23456789012345E-0 -> 9E+999999999 +mxgx337 maxmag -0.100 9E-999999999 -> -0.100 +mxgx338 maxmag 9E-999999999 -0.100 -> -0.100 + +mxgx339 maxmag 1e-599999999 1e-400000001 -> 1E-400000001 +mxgx340 maxmag 1e-599999999 1e-400000000 -> 1E-400000000 +mxgx341 maxmag 1e-600000000 1e-400000000 -> 1E-400000000 +mxgx342 maxmag 9e-999999998 0.01 -> 0.01 +mxgx343 maxmag 9e-999999998 0.1 -> 0.1 +mxgx344 maxmag 0.01 9e-999999998 -> 0.01 +mxgx345 maxmag 1e599999999 1e400000001 -> 1E+599999999 +mxgx346 maxmag 1e599999999 1e400000000 -> 1E+599999999 +mxgx347 maxmag 1e600000000 1e400000000 -> 1E+600000000 +mxgx348 maxmag 9e999999998 100 -> 9E+999999998 +mxgx349 maxmag 9e999999998 10 -> 9E+999999998 +mxgx350 maxmag 100 9e999999998 -> 9E+999999998 +-- signs +mxgx351 maxmag 1e+777777777 1e+411111111 -> 1E+777777777 +mxgx352 maxmag 1e+777777777 -1e+411111111 -> 1E+777777777 +mxgx353 maxmag -1e+777777777 1e+411111111 -> -1E+777777777 +mxgx354 maxmag -1e+777777777 -1e+411111111 -> -1E+777777777 +mxgx355 maxmag 1e-777777777 1e-411111111 -> 1E-411111111 +mxgx356 maxmag 1e-777777777 -1e-411111111 -> -1E-411111111 +mxgx357 maxmag -1e-777777777 1e-411111111 -> 1E-411111111 +mxgx358 maxmag -1e-777777777 -1e-411111111 -> -1E-411111111 + +-- expanded list from min/max 754r purple prose +-- [explicit tests for exponent ordering] +mxgx401 maxmag Inf 1.1 -> Infinity +mxgx402 maxmag 1.1 1 -> 1.1 +mxgx403 maxmag 1 1.0 -> 1 +mxgx404 maxmag 1.0 0.1 -> 1.0 +mxgx405 maxmag 0.1 0.10 -> 0.1 +mxgx406 maxmag 0.10 0.100 -> 0.10 +mxgx407 maxmag 0.10 0 -> 0.10 +mxgx408 maxmag 0 0.0 -> 0 +mxgx409 maxmag 0.0 -0 -> 0.0 +mxgx410 maxmag 0.0 -0.0 -> 0.0 +mxgx411 maxmag 0.00 -0.0 -> 0.00 +mxgx412 maxmag 0.0 -0.00 -> 0.0 +mxgx413 maxmag 0 -0.0 -> 0 +mxgx414 maxmag 0 -0 -> 0 +mxgx415 maxmag -0.0 -0 -> -0.0 +mxgx416 maxmag -0 -0.100 -> -0.100 +mxgx417 maxmag -0.100 -0.10 -> -0.100 +mxgx418 maxmag -0.10 -0.1 -> -0.10 +mxgx419 maxmag -0.1 -1.0 -> -1.0 +mxgx420 maxmag -1.0 -1 -> -1.0 +mxgx421 maxmag -1 -1.1 -> -1.1 +mxgx423 maxmag -1.1 -Inf -> -Infinity +-- same with operands reversed +mxgx431 maxmag 1.1 Inf -> Infinity +mxgx432 maxmag 1 1.1 -> 1.1 +mxgx433 maxmag 1.0 1 -> 1 +mxgx434 maxmag 0.1 1.0 -> 1.0 +mxgx435 maxmag 0.10 0.1 -> 0.1 +mxgx436 maxmag 0.100 0.10 -> 0.10 +mxgx437 maxmag 0 0.10 -> 0.10 +mxgx438 maxmag 0.0 0 -> 0 +mxgx439 maxmag -0 0.0 -> 0.0 +mxgx440 maxmag -0.0 0.0 -> 0.0 +mxgx441 maxmag -0.0 0.00 -> 0.00 +mxgx442 maxmag -0.00 0.0 -> 0.0 +mxgx443 maxmag -0.0 0 -> 0 +mxgx444 maxmag -0 0 -> 0 +mxgx445 maxmag -0 -0.0 -> -0.0 +mxgx446 maxmag -0.100 -0 -> -0.100 +mxgx447 maxmag -0.10 -0.100 -> -0.100 +mxgx448 maxmag -0.1 -0.10 -> -0.10 +mxgx449 maxmag -1.0 -0.1 -> -1.0 +mxgx450 maxmag -1 -1.0 -> -1.0 +mxgx451 maxmag -1.1 -1 -> -1.1 +mxgx453 maxmag -Inf -1.1 -> -Infinity +-- largies +mxgx460 maxmag 1000 1E+3 -> 1E+3 +mxgx461 maxmag 1E+3 1000 -> 1E+3 +mxgx462 maxmag 1000 -1E+3 -> 1000 +mxgx463 maxmag 1E+3 -1000 -> 1E+3 +mxgx464 maxmag -1000 1E+3 -> 1E+3 +mxgx465 maxmag -1E+3 1000 -> 1000 +mxgx466 maxmag -1000 -1E+3 -> -1000 +mxgx467 maxmag -1E+3 -1000 -> -1000 + +-- rounding (results treated as though plus) +maxexponent: 999999999 +minexponent: -999999999 +precision: 3 + +mxgx470 maxmag 1 .5 -> 1 +mxgx471 maxmag 10 5 -> 10 +mxgx472 maxmag 100 50 -> 100 +mxgx473 maxmag 1000 500 -> 1.00E+3 Rounded +mxgx474 maxmag 10000 5000 -> 1.00E+4 Rounded +mxgx475 maxmag 6 .5 -> 6 +mxgx476 maxmag 66 5 -> 66 +mxgx477 maxmag 666 50 -> 666 +mxgx478 maxmag 6666 500 -> 6.67E+3 Rounded Inexact +mxgx479 maxmag 66666 5000 -> 6.67E+4 Rounded Inexact +mxgx480 maxmag 33333 5000 -> 3.33E+4 Rounded Inexact +mxgx481 maxmag .5 1 -> 1 +mxgx482 maxmag .5 10 -> 10 +mxgx483 maxmag .5 100 -> 100 +mxgx484 maxmag .5 1000 -> 1.00E+3 Rounded +mxgx485 maxmag .5 10000 -> 1.00E+4 Rounded +mxgx486 maxmag .5 6 -> 6 +mxgx487 maxmag .5 66 -> 66 +mxgx488 maxmag .5 666 -> 666 +mxgx489 maxmag .5 6666 -> 6.67E+3 Rounded Inexact +mxgx490 maxmag .5 66666 -> 6.67E+4 Rounded Inexact +mxgx491 maxmag .5 33333 -> 3.33E+4 Rounded Inexact + +-- overflow tests +maxexponent: 999999999 +minexponent: -999999999 +precision: 3 +mxgx500 maxmag 9.999E+999999999 0 -> Infinity Inexact Overflow Rounded +mxgx501 maxmag -9.999E+999999999 0 -> -Infinity Inexact Overflow Rounded + +-- subnormals and underflow +precision: 3 +maxexponent: 999 +minexponent: -999 +mxgx510 maxmag 1.00E-999 0 -> 1.00E-999 +mxgx511 maxmag 0.1E-999 0 -> 1E-1000 Subnormal +mxgx512 maxmag 0.10E-999 0 -> 1.0E-1000 Subnormal +mxgx513 maxmag 0.100E-999 0 -> 1.0E-1000 Subnormal Rounded +mxgx514 maxmag 0.01E-999 0 -> 1E-1001 Subnormal +-- next is rounded to Nmin +mxgx515 maxmag 0.999E-999 0 -> 1.00E-999 Inexact Rounded Subnormal Underflow +mxgx516 maxmag 0.099E-999 0 -> 1.0E-1000 Inexact Rounded Subnormal Underflow +mxgx517 maxmag 0.009E-999 0 -> 1E-1001 Inexact Rounded Subnormal Underflow +mxgx518 maxmag 0.001E-999 0 -> 0E-1001 Inexact Rounded Subnormal Underflow Clamped +mxgx519 maxmag 0.0009E-999 0 -> 0E-1001 Inexact Rounded Subnormal Underflow Clamped +mxgx520 maxmag 0.0001E-999 0 -> 0E-1001 Inexact Rounded Subnormal Underflow Clamped + +mxgx530 maxmag -1.00E-999 0 -> -1.00E-999 +mxgx531 maxmag -0.1E-999 0 -> -1E-1000 Subnormal +mxgx532 maxmag -0.10E-999 0 -> -1.0E-1000 Subnormal +mxgx533 maxmag -0.100E-999 0 -> -1.0E-1000 Subnormal Rounded +mxgx534 maxmag -0.01E-999 0 -> -1E-1001 Subnormal +-- next is rounded to -Nmin +mxgx535 maxmag -0.999E-999 0 -> -1.00E-999 Inexact Rounded Subnormal Underflow +mxgx536 maxmag -0.099E-999 0 -> -1.0E-1000 Inexact Rounded Subnormal Underflow +mxgx537 maxmag -0.009E-999 0 -> -1E-1001 Inexact Rounded Subnormal Underflow +mxgx538 maxmag -0.001E-999 0 -> -0E-1001 Inexact Rounded Subnormal Underflow Clamped +mxgx539 maxmag -0.0009E-999 0 -> -0E-1001 Inexact Rounded Subnormal Underflow Clamped +mxgx540 maxmag -0.0001E-999 0 -> -0E-1001 Inexact Rounded Subnormal Underflow Clamped + +-- Null tests +mxgx900 maxmag 10 # -> NaN Invalid_operation +mxgx901 maxmag # 10 -> NaN Invalid_operation + + + Modified: python/branches/release25-maint/Lib/test/decimaltestdata/min.decTest ============================================================================== --- python/branches/release25-maint/Lib/test/decimaltestdata/min.decTest (original) +++ python/branches/release25-maint/Lib/test/decimaltestdata/min.decTest Tue Jan 8 17:20:31 2008 @@ -1,6 +1,6 @@ ------------------------------------------------------------------------ -- min.decTest -- decimal minimum -- --- Copyright (c) IBM Corporation, 1981, 2004. All rights reserved. -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- ------------------------------------------------------------------------ -- Please see the document "General Decimal Arithmetic Testcases" -- -- at http://www2.hursley.ibm.com/decimal for the description of -- @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc at uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.39 +version: 2.57 -- we assume that base comparison is tested in compare.decTest, so -- these mainly cover special cases and rounding @@ -320,6 +320,34 @@ mnmx466 min -1000 -1E+3 -> -1E+3 mnmx467 min -1E+3 -1000 -> -1E+3 +-- rounding (results treated as though plus) +maxexponent: 999999999 +minexponent: -999999999 +precision: 3 + +mnmx470 min 1 5 -> 1 +mnmx471 min 10 50 -> 10 +mnmx472 min 100 500 -> 100 +mnmx473 min 1000 5000 -> 1.00E+3 Rounded +mnmx474 min 10000 50000 -> 1.00E+4 Rounded +mnmx475 min 6 50 -> 6 +mnmx476 min 66 500 -> 66 +mnmx477 min 666 5000 -> 666 +mnmx478 min 6666 50000 -> 6.67E+3 Rounded Inexact +mnmx479 min 66666 500000 -> 6.67E+4 Rounded Inexact +mnmx480 min 33333 500000 -> 3.33E+4 Rounded Inexact +mnmx481 min 75401 1 -> 1 +mnmx482 min 75402 10 -> 10 +mnmx483 min 75403 100 -> 100 +mnmx484 min 75404 1000 -> 1.00E+3 Rounded +mnmx485 min 75405 10000 -> 1.00E+4 Rounded +mnmx486 min 75406 6 -> 6 +mnmx487 min 75407 66 -> 66 +mnmx488 min 75408 666 -> 666 +mnmx489 min 75409 6666 -> 6.67E+3 Rounded Inexact +mnmx490 min 75410 66666 -> 6.67E+4 Rounded Inexact +mnmx491 min 75411 33333 -> 3.33E+4 Rounded Inexact + -- overflow tests maxexponent: 999999999 @@ -349,14 +377,30 @@ mnmx532 min -0.10E-999 0 -> -1.0E-1000 Subnormal mnmx533 min -0.100E-999 0 -> -1.0E-1000 Subnormal Rounded mnmx534 min -0.01E-999 0 -> -1E-1001 Subnormal --- next is rounded to Emin +-- next is rounded to Nmin mnmx535 min -0.999E-999 0 -> -1.00E-999 Inexact Rounded Subnormal Underflow mnmx536 min -0.099E-999 0 -> -1.0E-1000 Inexact Rounded Subnormal Underflow mnmx537 min -0.009E-999 0 -> -1E-1001 Inexact Rounded Subnormal Underflow -mnmx538 min -0.001E-999 0 -> -0E-1001 Inexact Rounded Subnormal Underflow -mnmx539 min -0.0009E-999 0 -> -0E-1001 Inexact Rounded Subnormal Underflow -mnmx540 min -0.0001E-999 0 -> -0E-1001 Inexact Rounded Subnormal Underflow +mnmx538 min -0.001E-999 0 -> -0E-1001 Inexact Rounded Subnormal Underflow Clamped +mnmx539 min -0.0009E-999 0 -> -0E-1001 Inexact Rounded Subnormal Underflow Clamped +mnmx540 min -0.0001E-999 0 -> -0E-1001 Inexact Rounded Subnormal Underflow Clamped +-- misalignment traps for little-endian +precision: 9 +mnmx551 min 1.0 0.1 -> 0.1 +mnmx552 min 0.1 1.0 -> 0.1 +mnmx553 min 10.0 0.1 -> 0.1 +mnmx554 min 0.1 10.0 -> 0.1 +mnmx555 min 100 1.0 -> 1.0 +mnmx556 min 1.0 100 -> 1.0 +mnmx557 min 1000 10.0 -> 10.0 +mnmx558 min 10.0 1000 -> 10.0 +mnmx559 min 10000 100.0 -> 100.0 +mnmx560 min 100.0 10000 -> 100.0 +mnmx561 min 100000 1000.0 -> 1000.0 +mnmx562 min 1000.0 100000 -> 1000.0 +mnmx563 min 1000000 10000.0 -> 10000.0 +mnmx564 min 10000.0 1000000 -> 10000.0 -- Null tests mnm900 min 10 # -> NaN Invalid_operation Added: python/branches/release25-maint/Lib/test/decimaltestdata/minmag.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/minmag.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,390 @@ +------------------------------------------------------------------------ +-- minmag.decTest -- decimal minimum by magnitude -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- we assume that base comparison is tested in compare.decTest, so +-- these mainly cover special cases and rounding + +extended: 1 +precision: 9 +rounding: half_up +maxExponent: 384 +minexponent: -383 + +-- sanity checks +mngx001 minmag -2 -2 -> -2 +mngx002 minmag -2 -1 -> -1 +mngx003 minmag -2 0 -> 0 +mngx004 minmag -2 1 -> 1 +mngx005 minmag -2 2 -> -2 +mngx006 minmag -1 -2 -> -1 +mngx007 minmag -1 -1 -> -1 +mngx008 minmag -1 0 -> 0 +mngx009 minmag -1 1 -> -1 +mngx010 minmag -1 2 -> -1 +mngx011 minmag 0 -2 -> 0 +mngx012 minmag 0 -1 -> 0 +mngx013 minmag 0 0 -> 0 +mngx014 minmag 0 1 -> 0 +mngx015 minmag 0 2 -> 0 +mngx016 minmag 1 -2 -> 1 +mngx017 minmag 1 -1 -> -1 +mngx018 minmag 1 0 -> 0 +mngx019 minmag 1 1 -> 1 +mngx020 minmag 1 2 -> 1 +mngx021 minmag 2 -2 -> -2 +mngx022 minmag 2 -1 -> -1 +mngx023 minmag 2 0 -> 0 +mngx025 minmag 2 1 -> 1 +mngx026 minmag 2 2 -> 2 + +-- extended zeros +mngx030 minmag 0 0 -> 0 +mngx031 minmag 0 -0 -> -0 +mngx032 minmag 0 -0.0 -> -0.0 +mngx033 minmag 0 0.0 -> 0.0 +mngx034 minmag -0 0 -> -0 +mngx035 minmag -0 -0 -> -0 +mngx036 minmag -0 -0.0 -> -0 +mngx037 minmag -0 0.0 -> -0 +mngx038 minmag 0.0 0 -> 0.0 +mngx039 minmag 0.0 -0 -> -0 +mngx040 minmag 0.0 -0.0 -> -0.0 +mngx041 minmag 0.0 0.0 -> 0.0 +mngx042 minmag -0.0 0 -> -0.0 +mngx043 minmag -0.0 -0 -> -0 +mngx044 minmag -0.0 -0.0 -> -0.0 +mngx045 minmag -0.0 0.0 -> -0.0 + +mngx046 minmag 0E1 -0E1 -> -0E+1 +mngx047 minmag -0E1 0E2 -> -0E+1 +mngx048 minmag 0E2 0E1 -> 0E+1 +mngx049 minmag 0E1 0E2 -> 0E+1 +mngx050 minmag -0E3 -0E2 -> -0E+3 +mngx051 minmag -0E2 -0E3 -> -0E+3 + +-- Specials +precision: 9 +mngx090 minmag Inf -Inf -> -Infinity +mngx091 minmag Inf -1000 -> -1000 +mngx092 minmag Inf -1 -> -1 +mngx093 minmag Inf -0 -> -0 +mngx094 minmag Inf 0 -> 0 +mngx095 minmag Inf 1 -> 1 +mngx096 minmag Inf 1000 -> 1000 +mngx097 minmag Inf Inf -> Infinity +mngx098 minmag -1000 Inf -> -1000 +mngx099 minmag -Inf Inf -> -Infinity +mngx100 minmag -1 Inf -> -1 +mngx101 minmag -0 Inf -> -0 +mngx102 minmag 0 Inf -> 0 +mngx103 minmag 1 Inf -> 1 +mngx104 minmag 1000 Inf -> 1000 +mngx105 minmag Inf Inf -> Infinity + +mngx120 minmag -Inf -Inf -> -Infinity +mngx121 minmag -Inf -1000 -> -1000 +mngx122 minmag -Inf -1 -> -1 +mngx123 minmag -Inf -0 -> -0 +mngx124 minmag -Inf 0 -> 0 +mngx125 minmag -Inf 1 -> 1 +mngx126 minmag -Inf 1000 -> 1000 +mngx127 minmag -Inf Inf -> -Infinity +mngx128 minmag -Inf -Inf -> -Infinity +mngx129 minmag -1000 -Inf -> -1000 +mngx130 minmag -1 -Inf -> -1 +mngx131 minmag -0 -Inf -> -0 +mngx132 minmag 0 -Inf -> 0 +mngx133 minmag 1 -Inf -> 1 +mngx134 minmag 1000 -Inf -> 1000 +mngx135 minmag Inf -Inf -> -Infinity + +-- 2004.08.02 754r chooses number over NaN in mixed cases +mngx141 minmag NaN -Inf -> -Infinity +mngx142 minmag NaN -1000 -> -1000 +mngx143 minmag NaN -1 -> -1 +mngx144 minmag NaN -0 -> -0 +mngx145 minmag NaN 0 -> 0 +mngx146 minmag NaN 1 -> 1 +mngx147 minmag NaN 1000 -> 1000 +mngx148 minmag NaN Inf -> Infinity +mngx149 minmag NaN NaN -> NaN +mngx150 minmag -Inf NaN -> -Infinity +mngx151 minmag -1000 NaN -> -1000 +mngx152 minmag -1 -NaN -> -1 +mngx153 minmag -0 NaN -> -0 +mngx154 minmag 0 -NaN -> 0 +mngx155 minmag 1 NaN -> 1 +mngx156 minmag 1000 NaN -> 1000 +mngx157 minmag Inf NaN -> Infinity + +mngx161 minmag sNaN -Inf -> NaN Invalid_operation +mngx162 minmag sNaN -1000 -> NaN Invalid_operation +mngx163 minmag sNaN -1 -> NaN Invalid_operation +mngx164 minmag sNaN -0 -> NaN Invalid_operation +mngx165 minmag -sNaN 0 -> -NaN Invalid_operation +mngx166 minmag -sNaN 1 -> -NaN Invalid_operation +mngx167 minmag sNaN 1000 -> NaN Invalid_operation +mngx168 minmag sNaN NaN -> NaN Invalid_operation +mngx169 minmag sNaN sNaN -> NaN Invalid_operation +mngx170 minmag NaN sNaN -> NaN Invalid_operation +mngx171 minmag -Inf sNaN -> NaN Invalid_operation +mngx172 minmag -1000 sNaN -> NaN Invalid_operation +mngx173 minmag -1 sNaN -> NaN Invalid_operation +mngx174 minmag -0 sNaN -> NaN Invalid_operation +mngx175 minmag 0 sNaN -> NaN Invalid_operation +mngx176 minmag 1 sNaN -> NaN Invalid_operation +mngx177 minmag 1000 sNaN -> NaN Invalid_operation +mngx178 minmag Inf sNaN -> NaN Invalid_operation +mngx179 minmag NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +mngx181 minmag NaN9 -Inf -> -Infinity +mngx182 minmag -NaN8 9990 -> 9990 +mngx183 minmag NaN71 Inf -> Infinity + +mngx184 minmag NaN1 NaN54 -> NaN1 +mngx185 minmag NaN22 -NaN53 -> NaN22 +mngx186 minmag -NaN3 NaN6 -> -NaN3 +mngx187 minmag -NaN44 NaN7 -> -NaN44 + +mngx188 minmag -Inf NaN41 -> -Infinity +mngx189 minmag -9999 -NaN33 -> -9999 +mngx190 minmag Inf NaN2 -> Infinity + +mngx191 minmag sNaN99 -Inf -> NaN99 Invalid_operation +mngx192 minmag sNaN98 -11 -> NaN98 Invalid_operation +mngx193 minmag -sNaN97 NaN8 -> -NaN97 Invalid_operation +mngx194 minmag sNaN69 sNaN94 -> NaN69 Invalid_operation +mngx195 minmag NaN95 sNaN93 -> NaN93 Invalid_operation +mngx196 minmag -Inf sNaN92 -> NaN92 Invalid_operation +mngx197 minmag 088 sNaN91 -> NaN91 Invalid_operation +mngx198 minmag Inf -sNaN90 -> -NaN90 Invalid_operation +mngx199 minmag NaN sNaN86 -> NaN86 Invalid_operation + +-- rounding checks -- chosen is rounded, or not +maxExponent: 999 +minexponent: -999 +precision: 9 +mngx201 minmag -12345678000 1 -> 1 +mngx202 minmag 1 -12345678000 -> 1 +mngx203 minmag -1234567800 1 -> 1 +mngx204 minmag 1 -1234567800 -> 1 +mngx205 minmag -1234567890 1 -> 1 +mngx206 minmag 1 -1234567890 -> 1 +mngx207 minmag -1234567891 1 -> 1 +mngx208 minmag 1 -1234567891 -> 1 +mngx209 minmag -12345678901 1 -> 1 +mngx210 minmag 1 -12345678901 -> 1 +mngx211 minmag -1234567896 1 -> 1 +mngx212 minmag 1 -1234567896 -> 1 +mngx213 minmag 1234567891 1 -> 1 +mngx214 minmag 1 1234567891 -> 1 +mngx215 minmag 12345678901 1 -> 1 +mngx216 minmag 1 12345678901 -> 1 +mngx217 minmag 1234567896 1 -> 1 +mngx218 minmag 1 1234567896 -> 1 + +precision: 15 +mngx221 minmag -12345678000 1 -> 1 +mngx222 minmag 1 -12345678000 -> 1 +mngx223 minmag -1234567800 1 -> 1 +mngx224 minmag 1 -1234567800 -> 1 +mngx225 minmag -1234567890 1 -> 1 +mngx226 minmag 1 -1234567890 -> 1 +mngx227 minmag -1234567891 1 -> 1 +mngx228 minmag 1 -1234567891 -> 1 +mngx229 minmag -12345678901 1 -> 1 +mngx230 minmag 1 -12345678901 -> 1 +mngx231 minmag -1234567896 1 -> 1 +mngx232 minmag 1 -1234567896 -> 1 +mngx233 minmag 1234567891 1 -> 1 +mngx234 minmag 1 1234567891 -> 1 +mngx235 minmag 12345678901 1 -> 1 +mngx236 minmag 1 12345678901 -> 1 +mngx237 minmag 1234567896 1 -> 1 +mngx238 minmag 1 1234567896 -> 1 + +-- from examples +mngx280 minmag '3' '2' -> '2' +mngx281 minmag '-10' '3' -> '3' +mngx282 minmag '1.0' '1' -> '1.0' +mngx283 minmag '1' '1.0' -> '1.0' +mngx284 minmag '7' 'NaN' -> '7' + +-- overflow and underflow tests .. subnormal results [inputs] now allowed +maxExponent: 999999999 +minexponent: -999999999 +mngx330 minmag -1.23456789012345E-0 -9E+999999999 -> -1.23456789012345 +mngx331 minmag -9E+999999999 -1.23456789012345E-0 -> -1.23456789012345 +mngx332 minmag -0.100 -9E-999999999 -> -9E-999999999 +mngx333 minmag -9E-999999999 -0.100 -> -9E-999999999 +mngx335 minmag +1.23456789012345E-0 -9E+999999999 -> 1.23456789012345 +mngx336 minmag -9E+999999999 1.23456789012345E-0 -> 1.23456789012345 +mngx337 minmag +0.100 -9E-999999999 -> -9E-999999999 +mngx338 minmag -9E-999999999 0.100 -> -9E-999999999 + +mngx339 minmag -1e-599999999 -1e-400000001 -> -1E-599999999 +mngx340 minmag -1e-599999999 -1e-400000000 -> -1E-599999999 +mngx341 minmag -1e-600000000 -1e-400000000 -> -1E-600000000 +mngx342 minmag -9e-999999998 -0.01 -> -9E-999999998 +mngx343 minmag -9e-999999998 -0.1 -> -9E-999999998 +mngx344 minmag -0.01 -9e-999999998 -> -9E-999999998 +mngx345 minmag -1e599999999 -1e400000001 -> -1E+400000001 +mngx346 minmag -1e599999999 -1e400000000 -> -1E+400000000 +mngx347 minmag -1e600000000 -1e400000000 -> -1E+400000000 +mngx348 minmag -9e999999998 -100 -> -100 +mngx349 minmag -9e999999998 -10 -> -10 +mngx350 minmag -100 -9e999999998 -> -100 +-- signs +mngx351 minmag -1e+777777777 -1e+411111111 -> -1E+411111111 +mngx352 minmag -1e+777777777 +1e+411111111 -> 1E+411111111 +mngx353 minmag +1e+777777777 -1e+411111111 -> -1E+411111111 +mngx354 minmag +1e+777777777 +1e+411111111 -> 1E+411111111 +mngx355 minmag -1e-777777777 -1e-411111111 -> -1E-777777777 +mngx356 minmag -1e-777777777 +1e-411111111 -> -1E-777777777 +mngx357 minmag +1e-777777777 -1e-411111111 -> 1E-777777777 +mngx358 minmag +1e-777777777 +1e-411111111 -> 1E-777777777 + +-- expanded list from min/max 754r purple prose +-- [explicit tests for exponent ordering] +mngx401 minmag Inf 1.1 -> 1.1 +mngx402 minmag 1.1 1 -> 1 +mngx403 minmag 1 1.0 -> 1.0 +mngx404 minmag 1.0 0.1 -> 0.1 +mngx405 minmag 0.1 0.10 -> 0.10 +mngx406 minmag 0.10 0.100 -> 0.100 +mngx407 minmag 0.10 0 -> 0 +mngx408 minmag 0 0.0 -> 0.0 +mngx409 minmag 0.0 -0 -> -0 +mngx410 minmag 0.0 -0.0 -> -0.0 +mngx411 minmag 0.00 -0.0 -> -0.0 +mngx412 minmag 0.0 -0.00 -> -0.00 +mngx413 minmag 0 -0.0 -> -0.0 +mngx414 minmag 0 -0 -> -0 +mngx415 minmag -0.0 -0 -> -0 +mngx416 minmag -0 -0.100 -> -0 +mngx417 minmag -0.100 -0.10 -> -0.10 +mngx418 minmag -0.10 -0.1 -> -0.1 +mngx419 minmag -0.1 -1.0 -> -0.1 +mngx420 minmag -1.0 -1 -> -1 +mngx421 minmag -1 -1.1 -> -1 +mngx423 minmag -1.1 -Inf -> -1.1 +-- same with operands reversed +mngx431 minmag 1.1 Inf -> 1.1 +mngx432 minmag 1 1.1 -> 1 +mngx433 minmag 1.0 1 -> 1.0 +mngx434 minmag 0.1 1.0 -> 0.1 +mngx435 minmag 0.10 0.1 -> 0.10 +mngx436 minmag 0.100 0.10 -> 0.100 +mngx437 minmag 0 0.10 -> 0 +mngx438 minmag 0.0 0 -> 0.0 +mngx439 minmag -0 0.0 -> -0 +mngx440 minmag -0.0 0.0 -> -0.0 +mngx441 minmag -0.0 0.00 -> -0.0 +mngx442 minmag -0.00 0.0 -> -0.00 +mngx443 minmag -0.0 0 -> -0.0 +mngx444 minmag -0 0 -> -0 +mngx445 minmag -0 -0.0 -> -0 +mngx446 minmag -0.100 -0 -> -0 +mngx447 minmag -0.10 -0.100 -> -0.10 +mngx448 minmag -0.1 -0.10 -> -0.1 +mngx449 minmag -1.0 -0.1 -> -0.1 +mngx450 minmag -1 -1.0 -> -1 +mngx451 minmag -1.1 -1 -> -1 +mngx453 minmag -Inf -1.1 -> -1.1 +-- largies +mngx460 minmag 1000 1E+3 -> 1000 +mngx461 minmag 1E+3 1000 -> 1000 +mngx462 minmag 1000 -1E+3 -> -1E+3 +mngx463 minmag 1E+3 -1000 -> -1000 +mngx464 minmag -1000 1E+3 -> -1000 +mngx465 minmag -1E+3 1000 -> -1E+3 +mngx466 minmag -1000 -1E+3 -> -1E+3 +mngx467 minmag -1E+3 -1000 -> -1E+3 + +-- rounding (results treated as though plus) +maxexponent: 999999999 +minexponent: -999999999 +precision: 3 + +mngx470 minmag 1 5 -> 1 +mngx471 minmag 10 50 -> 10 +mngx472 minmag 100 500 -> 100 +mngx473 minmag 1000 5000 -> 1.00E+3 Rounded +mngx474 minmag 10000 50000 -> 1.00E+4 Rounded +mngx475 minmag 6 50 -> 6 +mngx476 minmag 66 500 -> 66 +mngx477 minmag 666 5000 -> 666 +mngx478 minmag 6666 50000 -> 6.67E+3 Rounded Inexact +mngx479 minmag 66666 500000 -> 6.67E+4 Rounded Inexact +mngx480 minmag 33333 500000 -> 3.33E+4 Rounded Inexact +mngx481 minmag 75401 1 -> 1 +mngx482 minmag 75402 10 -> 10 +mngx483 minmag 75403 100 -> 100 +mngx484 minmag 75404 1000 -> 1.00E+3 Rounded +mngx485 minmag 75405 10000 -> 1.00E+4 Rounded +mngx486 minmag 75406 6 -> 6 +mngx487 minmag 75407 66 -> 66 +mngx488 minmag 75408 666 -> 666 +mngx489 minmag 75409 6666 -> 6.67E+3 Rounded Inexact +mngx490 minmag 75410 66666 -> 6.67E+4 Rounded Inexact +mngx491 minmag 75411 33333 -> 3.33E+4 Rounded Inexact + + +-- overflow tests +maxexponent: 999999999 +minexponent: -999999999 +precision: 3 +mngx500 minmag 9.999E+999999999 0 -> 0 +mngx501 minmag -9.999E+999999999 0 -> 0 + +-- subnormals and underflow +precision: 3 +maxexponent: 999 +minexponent: -999 +mngx510 minmag 1.00E-999 0 -> 0 +mngx511 minmag 0.1E-999 0 -> 0 +mngx512 minmag 0.10E-999 0 -> 0 +mngx513 minmag 0.100E-999 0 -> 0 +mngx514 minmag 0.01E-999 0 -> 0 +mngx515 minmag 0.999E-999 0 -> 0 +mngx516 minmag 0.099E-999 0 -> 0 +mngx517 minmag 0.009E-999 0 -> 0 +mngx518 minmag 0.001E-999 0 -> 0 +mngx519 minmag 0.0009E-999 0 -> 0 +mngx520 minmag 0.0001E-999 0 -> 0 + +mngx530 minmag -1.00E-999 0 -> 0 +mngx531 minmag -0.1E-999 0 -> 0 +mngx532 minmag -0.10E-999 0 -> 0 +mngx533 minmag -0.100E-999 0 -> 0 +mngx534 minmag -0.01E-999 0 -> 0 +mngx535 minmag -0.999E-999 0 -> 0 +mngx536 minmag -0.099E-999 0 -> 0 +mngx537 minmag -0.009E-999 0 -> 0 +mngx538 minmag -0.001E-999 0 -> 0 +mngx539 minmag -0.0009E-999 0 -> 0 +mngx540 minmag -0.0001E-999 0 -> 0 + + +-- Null tests +mng900 minmag 10 # -> NaN Invalid_operation +mng901 minmag # 10 -> NaN Invalid_operation Modified: python/branches/release25-maint/Lib/test/decimaltestdata/minus.decTest ============================================================================== --- python/branches/release25-maint/Lib/test/decimaltestdata/minus.decTest (original) +++ python/branches/release25-maint/Lib/test/decimaltestdata/minus.decTest Tue Jan 8 17:20:31 2008 @@ -1,6 +1,6 @@ ------------------------------------------------------------------------ -- minus.decTest -- decimal negation -- --- Copyright (c) IBM Corporation, 1981, 2004. All rights reserved. -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- ------------------------------------------------------------------------ -- Please see the document "General Decimal Arithmetic Testcases" -- -- at http://www2.hursley.ibm.com/decimal for the description of -- @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc at uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.39 +version: 2.57 -- This set of tests primarily tests the existence of the operator. -- Subtraction, rounding, and more overflows are tested elsewhere. @@ -127,9 +127,9 @@ minx115 minus 0.999E-999 -> -1.00E-999 Inexact Rounded Subnormal Underflow minx116 minus 0.099E-999 -> -1.0E-1000 Inexact Rounded Subnormal Underflow minx117 minus 0.009E-999 -> -1E-1001 Inexact Rounded Subnormal Underflow -minx118 minus 0.001E-999 -> -0E-1001 Inexact Rounded Subnormal Underflow -minx119 minus 0.0009E-999 -> -0E-1001 Inexact Rounded Subnormal Underflow -minx120 minus 0.0001E-999 -> -0E-1001 Inexact Rounded Subnormal Underflow +minx118 minus 0.001E-999 -> -0E-1001 Inexact Rounded Subnormal Underflow Clamped +minx119 minus 0.0009E-999 -> -0E-1001 Inexact Rounded Subnormal Underflow Clamped +minx120 minus 0.0001E-999 -> -0E-1001 Inexact Rounded Subnormal Underflow Clamped minx130 minus -1.00E-999 -> 1.00E-999 minx131 minus -0.1E-999 -> 1E-1000 Subnormal @@ -140,9 +140,9 @@ minx135 minus -0.999E-999 -> 1.00E-999 Inexact Rounded Subnormal Underflow minx136 minus -0.099E-999 -> 1.0E-1000 Inexact Rounded Subnormal Underflow minx137 minus -0.009E-999 -> 1E-1001 Inexact Rounded Subnormal Underflow -minx138 minus -0.001E-999 -> 0E-1001 Inexact Rounded Subnormal Underflow -minx139 minus -0.0009E-999 -> 0E-1001 Inexact Rounded Subnormal Underflow -minx140 minus -0.0001E-999 -> 0E-1001 Inexact Rounded Subnormal Underflow +minx138 minus -0.001E-999 -> 0E-1001 Inexact Rounded Subnormal Underflow Clamped +minx139 minus -0.0009E-999 -> 0E-1001 Inexact Rounded Subnormal Underflow Clamped +minx140 minus -0.0001E-999 -> 0E-1001 Inexact Rounded Subnormal Underflow Clamped -- long operand checks Modified: python/branches/release25-maint/Lib/test/decimaltestdata/multiply.decTest ============================================================================== --- python/branches/release25-maint/Lib/test/decimaltestdata/multiply.decTest (original) +++ python/branches/release25-maint/Lib/test/decimaltestdata/multiply.decTest Tue Jan 8 17:20:31 2008 @@ -1,6 +1,6 @@ ------------------------------------------------------------------------ -- multiply.decTest -- decimal multiplication -- --- Copyright (c) IBM Corporation, 1981, 2004. All rights reserved. -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- ------------------------------------------------------------------------ -- Please see the document "General Decimal Arithmetic Testcases" -- -- at http://www2.hursley.ibm.com/decimal for the description of -- @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc at uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.39 +version: 2.57 extended: 1 precision: 9 @@ -44,21 +44,28 @@ mulx015 multiply 2.50 4 -> 10.00 precision: 6 mulx016 multiply 2.50 4 -> 10.00 -mulx017 multiply 9.999999999 9.999999999 -> 100.000 Inexact Rounded +mulx017 multiply 9.999999999 9.999999999 -> 100.000 Inexact Rounded +mulx018 multiply 9.999999999 -9.999999999 -> -100.000 Inexact Rounded +mulx019 multiply -9.999999999 9.999999999 -> -100.000 Inexact Rounded +mulx020 multiply -9.999999999 -9.999999999 -> 100.000 Inexact Rounded -- 1999.12.21: next one is a edge case if intermediate longs are used precision: 15 -mulx019 multiply 999999999999 9765625 -> 9.76562499999023E+18 Inexact Rounded +mulx059 multiply 999999999999 9765625 -> 9.76562499999023E+18 Inexact Rounded precision: 30 mulx160 multiply 999999999999 9765625 -> 9765624999990234375 precision: 9 ----- -- zeros, etc. -mulx020 multiply 0 0 -> 0 -mulx021 multiply 0 -0 -> -0 -mulx022 multiply -0 0 -> -0 -mulx023 multiply -0 -0 -> 0 +mulx021 multiply 0 0 -> 0 +mulx022 multiply 0 -0 -> -0 +mulx023 multiply -0 0 -> -0 +mulx024 multiply -0 -0 -> 0 +mulx025 multiply -0.0 -0.0 -> 0.00 +mulx026 multiply -0.0 -0.0 -> 0.00 +mulx027 multiply -0.0 -0.0 -> 0.00 +mulx028 multiply -0.0 -0.0 -> 0.00 mulx030 multiply 5.00 1E-3 -> 0.00500 mulx031 multiply 00.00 0.000 -> 0.00000 mulx032 multiply 00.00 0E-3 -> 0.00000 -- rhs is 0 @@ -94,17 +101,17 @@ -- test some intermediate lengths precision: 9 -mulx080 multiply 0.1 123456789 -> 12345678.9 -mulx081 multiply 0.1 1234567891 -> 123456789 Inexact Rounded -mulx082 multiply 0.1 12345678912 -> 1.23456789E+9 Inexact Rounded -mulx083 multiply 0.1 12345678912345 -> 1.23456789E+12 Inexact Rounded -mulx084 multiply 0.1 123456789 -> 12345678.9 +mulx080 multiply 0.1 123456789 -> 12345678.9 +mulx081 multiply 0.1 1234567891 -> 123456789 Inexact Rounded +mulx082 multiply 0.1 12345678912 -> 1.23456789E+9 Inexact Rounded +mulx083 multiply 0.1 12345678912345 -> 1.23456789E+12 Inexact Rounded +mulx084 multiply 0.1 123456789 -> 12345678.9 precision: 8 -mulx085 multiply 0.1 12345678912 -> 1.2345679E+9 Inexact Rounded -mulx086 multiply 0.1 12345678912345 -> 1.2345679E+12 Inexact Rounded +mulx085 multiply 0.1 12345678912 -> 1.2345679E+9 Inexact Rounded +mulx086 multiply 0.1 12345678912345 -> 1.2345679E+12 Inexact Rounded precision: 7 -mulx087 multiply 0.1 12345678912 -> 1.234568E+9 Inexact Rounded -mulx088 multiply 0.1 12345678912345 -> 1.234568E+12 Inexact Rounded +mulx087 multiply 0.1 12345678912 -> 1.234568E+9 Inexact Rounded +mulx088 multiply 0.1 12345678912345 -> 1.234568E+12 Inexact Rounded precision: 9 mulx090 multiply 123456789 0.1 -> 12345678.9 @@ -280,6 +287,41 @@ precision: 1 mulx278 multiply 30269.587755640502150977251770554 4.8046009735990873395936309640543 -> 1E+5 Inexact Rounded +-- test some edge cases with exact rounding +maxexponent: 9999 +minexponent: -9999 +precision: 9 +mulx301 multiply 9 9 -> 81 +mulx302 multiply 9 90 -> 810 +mulx303 multiply 9 900 -> 8100 +mulx304 multiply 9 9000 -> 81000 +mulx305 multiply 9 90000 -> 810000 +mulx306 multiply 9 900000 -> 8100000 +mulx307 multiply 9 9000000 -> 81000000 +mulx308 multiply 9 90000000 -> 810000000 +mulx309 multiply 9 900000000 -> 8.10000000E+9 Rounded +mulx310 multiply 9 9000000000 -> 8.10000000E+10 Rounded +mulx311 multiply 9 90000000000 -> 8.10000000E+11 Rounded +mulx312 multiply 9 900000000000 -> 8.10000000E+12 Rounded +mulx313 multiply 9 9000000000000 -> 8.10000000E+13 Rounded +mulx314 multiply 9 90000000000000 -> 8.10000000E+14 Rounded +mulx315 multiply 9 900000000000000 -> 8.10000000E+15 Rounded +mulx316 multiply 9 9000000000000000 -> 8.10000000E+16 Rounded +mulx317 multiply 9 90000000000000000 -> 8.10000000E+17 Rounded +mulx318 multiply 9 900000000000000000 -> 8.10000000E+18 Rounded +mulx319 multiply 9 9000000000000000000 -> 8.10000000E+19 Rounded +mulx320 multiply 9 90000000000000000000 -> 8.10000000E+20 Rounded +mulx321 multiply 9 900000000000000000000 -> 8.10000000E+21 Rounded +mulx322 multiply 9 9000000000000000000000 -> 8.10000000E+22 Rounded +mulx323 multiply 9 90000000000000000000000 -> 8.10000000E+23 Rounded + +-- fastpath breakers +precision: 29 +mulx330 multiply 1.491824697641270317824852952837224 1.105170918075647624811707826490246514675628614562883537345747603 -> 1.6487212707001281468486507878 Inexact Rounded +precision: 55 +mulx331 multiply 0.8958341352965282506768545828765117803873717284891040428 0.8958341352965282506768545828765117803873717284891040428 -> 0.8025187979624784829842553829934069955890983696752228299 Inexact Rounded + + -- tryzeros cases precision: 7 rounding: half_up @@ -486,10 +528,10 @@ mulx752 multiply 1e+777777777 -1e+411111111 -> -Infinity Overflow Inexact Rounded mulx753 multiply -1e+777777777 1e+411111111 -> -Infinity Overflow Inexact Rounded mulx754 multiply -1e+777777777 -1e+411111111 -> Infinity Overflow Inexact Rounded -mulx755 multiply 1e-777777777 1e-411111111 -> 0E-1000000007 Underflow Subnormal Inexact Rounded -mulx756 multiply 1e-777777777 -1e-411111111 -> -0E-1000000007 Underflow Subnormal Inexact Rounded -mulx757 multiply -1e-777777777 1e-411111111 -> -0E-1000000007 Underflow Subnormal Inexact Rounded -mulx758 multiply -1e-777777777 -1e-411111111 -> 0E-1000000007 Underflow Subnormal Inexact Rounded +mulx755 multiply 1e-777777777 1e-411111111 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped +mulx756 multiply 1e-777777777 -1e-411111111 -> -0E-1000000007 Underflow Subnormal Inexact Rounded Clamped +mulx757 multiply -1e-777777777 1e-411111111 -> -0E-1000000007 Underflow Subnormal Inexact Rounded Clamped +mulx758 multiply -1e-777777777 -1e-411111111 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped -- 'subnormal' boundary (all hard underflow or overflow in base arithemtic) precision: 9 @@ -500,9 +542,9 @@ mulx764 multiply 1e-600000000 1e-400000005 -> 1E-1000000005 Subnormal mulx765 multiply 1e-600000000 1e-400000006 -> 1E-1000000006 Subnormal mulx766 multiply 1e-600000000 1e-400000007 -> 1E-1000000007 Subnormal -mulx767 multiply 1e-600000000 1e-400000008 -> 0E-1000000007 Underflow Subnormal Inexact Rounded -mulx768 multiply 1e-600000000 1e-400000009 -> 0E-1000000007 Underflow Subnormal Inexact Rounded -mulx769 multiply 1e-600000000 1e-400000010 -> 0E-1000000007 Underflow Subnormal Inexact Rounded +mulx767 multiply 1e-600000000 1e-400000008 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped +mulx768 multiply 1e-600000000 1e-400000009 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped +mulx769 multiply 1e-600000000 1e-400000010 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped -- [no equivalent of 'subnormal' for overflow] mulx770 multiply 1e+600000000 1e+400000001 -> Infinity Overflow Inexact Rounded mulx771 multiply 1e+600000000 1e+400000002 -> Infinity Overflow Inexact Rounded @@ -520,31 +562,31 @@ mulx780 multiply 1e-600000000 1e-400000007 -> 1E-1000000007 Subnormal mulx781 multiply 1e-600000000 1e-400000008 -> 1E-1000000008 Subnormal mulx782 multiply 1e-600000000 1e-400000097 -> 1E-1000000097 Subnormal -mulx783 multiply 1e-600000000 1e-400000098 -> 0E-1000000097 Underflow Subnormal Inexact Rounded +mulx783 multiply 1e-600000000 1e-400000098 -> 0E-1000000097 Underflow Subnormal Inexact Rounded Clamped precision: 999 mulx784 multiply 1e-600000000 1e-400000997 -> 1E-1000000997 Subnormal -mulx785 multiply 1e-600000000 1e-400000998 -> 0E-1000000997 Underflow Subnormal Inexact Rounded +mulx785 multiply 1e-600000000 1e-400000998 -> 0E-1000000997 Underflow Subnormal Inexact Rounded Clamped -- following testcases [through mulx800] not yet run against code precision: 9999 mulx786 multiply 1e-600000000 1e-400009997 -> 1E-1000009997 Subnormal -mulx787 multiply 1e-600000000 1e-400009998 -> 0E-1000009997 Underflow Subnormal Inexact Rounded +mulx787 multiply 1e-600000000 1e-400009998 -> 0E-1000009997 Underflow Subnormal Inexact Rounded Clamped precision: 99999 mulx788 multiply 1e-600000000 1e-400099997 -> 1E-1000099997 Subnormal -mulx789 multiply 1e-600000000 1e-400099998 -> 0E-1000099997 Underflow Subnormal Inexact Rounded +mulx789 multiply 1e-600000000 1e-400099998 -> 0E-1000099997 Underflow Subnormal Inexact Rounded Clamped precision: 999999 mulx790 multiply 1e-600000000 1e-400999997 -> 1E-1000999997 Subnormal -mulx791 multiply 1e-600000000 1e-400999998 -> 0E-1000999997 Underflow Subnormal Inexact Rounded +mulx791 multiply 1e-600000000 1e-400999998 -> 0E-1000999997 Underflow Subnormal Inexact Rounded Clamped precision: 9999999 mulx792 multiply 1e-600000000 1e-409999997 -> 1E-1009999997 Subnormal -mulx793 multiply 1e-600000000 1e-409999998 -> 0E-1009999997 Underflow Subnormal Inexact Rounded +mulx793 multiply 1e-600000000 1e-409999998 -> 0E-1009999997 Underflow Subnormal Inexact Rounded Clamped precision: 99999999 mulx794 multiply 1e-600000000 1e-499999997 -> 1E-1099999997 Subnormal -mulx795 multiply 1e-600000000 1e-499999998 -> 0E-1099999997 Underflow Subnormal Inexact Rounded +mulx795 multiply 1e-600000000 1e-499999998 -> 0E-1099999997 Underflow Subnormal Inexact Rounded Clamped precision: 999999999 mulx796 multiply 1e-999999999 1e-999999997 -> 1E-1999999996 Subnormal mulx797 multiply 1e-999999999 1e-999999998 -> 1E-1999999997 Subnormal -mulx798 multiply 1e-999999999 1e-999999999 -> 0E-1999999997 Underflow Subnormal Inexact Rounded +mulx798 multiply 1e-999999999 1e-999999999 -> 0E-1999999997 Underflow Subnormal Inexact Rounded Clamped mulx799 multiply 1e-600000000 1e-400000007 -> 1E-1000000007 Subnormal mulx800 multiply 1e-600000000 1e-400000008 -> 1E-1000000008 Subnormal @@ -573,19 +615,19 @@ mulx817 multiply 2.51E-999 1e-4 -> 3E-1003 Underflow Subnormal Inexact Rounded mulx818 multiply 1E-999 1e-4 -> 1E-1003 Subnormal -mulx819 multiply 3E-999 1e-5 -> 0E-1003 Underflow Subnormal Inexact Rounded -mulx820 multiply 5E-999 1e-5 -> 0E-1003 Underflow Subnormal Inexact Rounded +mulx819 multiply 3E-999 1e-5 -> 0E-1003 Underflow Subnormal Inexact Rounded Clamped +mulx820 multiply 5E-999 1e-5 -> 0E-1003 Underflow Subnormal Inexact Rounded Clamped mulx821 multiply 7E-999 1e-5 -> 1E-1003 Underflow Subnormal Inexact Rounded mulx822 multiply 9E-999 1e-5 -> 1E-1003 Underflow Subnormal Inexact Rounded mulx823 multiply 9.9E-999 1e-5 -> 1E-1003 Underflow Subnormal Inexact Rounded mulx824 multiply 1E-999 -1e-4 -> -1E-1003 Subnormal -mulx825 multiply 3E-999 -1e-5 -> -0E-1003 Underflow Subnormal Inexact Rounded -mulx826 multiply -5E-999 1e-5 -> -0E-1003 Underflow Subnormal Inexact Rounded +mulx825 multiply 3E-999 -1e-5 -> -0E-1003 Underflow Subnormal Inexact Rounded Clamped +mulx826 multiply -5E-999 1e-5 -> -0E-1003 Underflow Subnormal Inexact Rounded Clamped mulx827 multiply 7E-999 -1e-5 -> -1E-1003 Underflow Subnormal Inexact Rounded mulx828 multiply -9E-999 1e-5 -> -1E-1003 Underflow Subnormal Inexact Rounded mulx829 multiply 9.9E-999 -1e-5 -> -1E-1003 Underflow Subnormal Inexact Rounded -mulx830 multiply 3.0E-999 -1e-5 -> -0E-1003 Underflow Subnormal Inexact Rounded +mulx830 multiply 3.0E-999 -1e-5 -> -0E-1003 Underflow Subnormal Inexact Rounded Clamped mulx831 multiply 1.0E-501 1e-501 -> 1.0E-1002 Subnormal mulx832 multiply 2.0E-501 2e-501 -> 4.0E-1002 Subnormal @@ -595,7 +637,7 @@ mulx836 multiply 40.0E-501 40e-501 -> 1.6000E-999 -- squares -mulx840 multiply 1E-502 1e-502 -> 0E-1003 Underflow Subnormal Inexact Rounded +mulx840 multiply 1E-502 1e-502 -> 0E-1003 Underflow Subnormal Inexact Rounded Clamped mulx841 multiply 1E-501 1e-501 -> 1E-1002 Subnormal mulx842 multiply 2E-501 2e-501 -> 4E-1002 Subnormal mulx843 multiply 4E-501 4e-501 -> 1.6E-1001 Subnormal @@ -604,7 +646,7 @@ mulx846 multiply 40E-501 40e-501 -> 1.600E-999 -- cubes -mulx850 multiply 1E-670 1e-335 -> 0E-1003 Underflow Subnormal Inexact Rounded +mulx850 multiply 1E-670 1e-335 -> 0E-1003 Underflow Subnormal Inexact Rounded Clamped mulx851 multiply 1E-668 1e-334 -> 1E-1002 Subnormal mulx852 multiply 4E-668 2e-334 -> 8E-1002 Subnormal mulx853 multiply 9E-668 3e-334 -> 2.7E-1001 Subnormal @@ -612,7 +654,7 @@ mulx855 multiply 25E-668 5e-334 -> 1.25E-1000 Subnormal mulx856 multiply 10E-668 100e-334 -> 1.000E-999 --- test from 0.099 ** 999 at 15 digits +-- test derived from result of 0.099 ** 999 at 15 digits with unlimited exponent precision: 19 mulx860 multiply 6636851557994578716E-520 6636851557994578716E-520 -> 4.40477986028551E-1003 Underflow Subnormal Inexact Rounded @@ -629,14 +671,16 @@ precision: 5 maxexponent: 79 minexponent: -79 -mulx881 multiply 1.2347E-40 1.2347E-40 -> 1.524E-80 Inexact Rounded Subnormal Underflow -mulx882 multiply 1.234E-40 1.234E-40 -> 1.523E-80 Inexact Rounded Subnormal Underflow -mulx883 multiply 1.23E-40 1.23E-40 -> 1.513E-80 Inexact Rounded Subnormal Underflow -mulx884 multiply 1.2E-40 1.2E-40 -> 1.44E-80 Subnormal -mulx885 multiply 1.2E-40 1.2E-41 -> 1.44E-81 Subnormal -mulx886 multiply 1.2E-40 1.2E-42 -> 1.4E-82 Subnormal Inexact Rounded Underflow -mulx887 multiply 1.2E-40 1.3E-42 -> 1.6E-82 Subnormal Inexact Rounded Underflow -mulx888 multiply 1.3E-40 1.3E-42 -> 1.7E-82 Subnormal Inexact Rounded Underflow +mulx881 multiply 1.2347E-40 1.2347E-40 -> 1.524E-80 Inexact Rounded Subnormal Underflow +mulx882 multiply 1.234E-40 1.234E-40 -> 1.523E-80 Inexact Rounded Subnormal Underflow +mulx883 multiply 1.23E-40 1.23E-40 -> 1.513E-80 Inexact Rounded Subnormal Underflow +mulx884 multiply 1.2E-40 1.2E-40 -> 1.44E-80 Subnormal +mulx885 multiply 1.2E-40 1.2E-41 -> 1.44E-81 Subnormal +mulx886 multiply 1.2E-40 1.2E-42 -> 1.4E-82 Subnormal Inexact Rounded Underflow +mulx887 multiply 1.2E-40 1.3E-42 -> 1.6E-82 Subnormal Inexact Rounded Underflow +mulx888 multiply 1.3E-40 1.3E-42 -> 1.7E-82 Subnormal Inexact Rounded Underflow +mulx889 multiply 1.3E-40 1.3E-43 -> 2E-83 Subnormal Inexact Rounded Underflow +mulx890 multiply 1.3E-41 1.3E-43 -> 0E-83 Clamped Subnormal Inexact Rounded Underflow mulx891 multiply 1.2345E-39 1.234E-40 -> 1.5234E-79 Inexact Rounded mulx892 multiply 1.23456E-39 1.234E-40 -> 1.5234E-79 Inexact Rounded @@ -645,7 +689,43 @@ mulx895 multiply 1.2345E-41 1.234E-40 -> 1.52E-81 Inexact Rounded Subnormal Underflow mulx896 multiply 1.23456E-41 1.234E-40 -> 1.52E-81 Inexact Rounded Subnormal Underflow +-- Now explore the case where we get a normal result with Underflow +precision: 16 +rounding: half_up +maxExponent: 384 +minExponent: -383 + +mulx900 multiply 0.3000000000E-191 0.3000000000E-191 -> 9.00000000000000E-384 Subnormal Rounded +mulx901 multiply 0.3000000001E-191 0.3000000001E-191 -> 9.00000000600000E-384 Underflow Inexact Subnormal Rounded +mulx902 multiply 9.999999999999999E-383 0.0999999999999 -> 9.99999999999000E-384 Underflow Inexact Subnormal Rounded +mulx903 multiply 9.999999999999999E-383 0.09999999999999 -> 9.99999999999900E-384 Underflow Inexact Subnormal Rounded +mulx904 multiply 9.999999999999999E-383 0.099999999999999 -> 9.99999999999990E-384 Underflow Inexact Subnormal Rounded +mulx905 multiply 9.999999999999999E-383 0.0999999999999999 -> 9.99999999999999E-384 Underflow Inexact Subnormal Rounded +-- prove operands are exact +mulx906 multiply 9.999999999999999E-383 1 -> 9.999999999999999E-383 +mulx907 multiply 1 0.09999999999999999 -> 0.09999999999999999 +-- the next rounds to Nmin +mulx908 multiply 9.999999999999999E-383 0.09999999999999999 -> 1.000000000000000E-383 Underflow Inexact Subnormal Rounded +mulx909 multiply 9.999999999999999E-383 0.099999999999999999 -> 1.000000000000000E-383 Underflow Inexact Subnormal Rounded +mulx910 multiply 9.999999999999999E-383 0.0999999999999999999 -> 1.000000000000000E-383 Underflow Inexact Subnormal Rounded +mulx911 multiply 9.999999999999999E-383 0.09999999999999999999 -> 1.000000000000000E-383 Underflow Inexact Subnormal Rounded + + +-- Examples from SQL proposal (Krishna Kulkarni) +precision: 34 +rounding: half_up +maxExponent: 6144 +minExponent: -6143 +mulx1001 multiply 130E-2 120E-2 -> 1.5600 +mulx1002 multiply 130E-2 12E-1 -> 1.560 +mulx1003 multiply 130E-2 1E0 -> 1.30 +mulx1004 multiply 1E2 1E4 -> 1E+6 + +-- payload decapitate +precision: 5 +mulx1010 multiply 11 -sNaN1234567890 -> -NaN67890 Invalid_operation + -- Null tests -mulx900 multiply 10 # -> NaN Invalid_operation -mulx901 multiply # 10 -> NaN Invalid_operation +mulx990 multiply 10 # -> NaN Invalid_operation +mulx991 multiply # 10 -> NaN Invalid_operation Added: python/branches/release25-maint/Lib/test/decimaltestdata/nextminus.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/nextminus.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,148 @@ +------------------------------------------------------------------------ +-- nextminus.decTest -- decimal next that is less [754r nextdown] -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +extended: 1 +precision: 9 +rounding: half_up +maxExponent: 384 +minexponent: -383 + +nextm001 nextminus 0.999999995 -> 0.999999994 +nextm002 nextminus 0.999999996 -> 0.999999995 +nextm003 nextminus 0.999999997 -> 0.999999996 +nextm004 nextminus 0.999999998 -> 0.999999997 +nextm005 nextminus 0.999999999 -> 0.999999998 +nextm006 nextminus 1.00000000 -> 0.999999999 +nextm007 nextminus 1.0 -> 0.999999999 +nextm008 nextminus 1 -> 0.999999999 +nextm009 nextminus 1.00000001 -> 1.00000000 +nextm010 nextminus 1.00000002 -> 1.00000001 +nextm011 nextminus 1.00000003 -> 1.00000002 +nextm012 nextminus 1.00000004 -> 1.00000003 +nextm013 nextminus 1.00000005 -> 1.00000004 +nextm014 nextminus 1.00000006 -> 1.00000005 +nextm015 nextminus 1.00000007 -> 1.00000006 +nextm016 nextminus 1.00000008 -> 1.00000007 +nextm017 nextminus 1.00000009 -> 1.00000008 +nextm018 nextminus 1.00000010 -> 1.00000009 +nextm019 nextminus 1.00000011 -> 1.00000010 +nextm020 nextminus 1.00000012 -> 1.00000011 + +nextm021 nextminus -0.999999995 -> -0.999999996 +nextm022 nextminus -0.999999996 -> -0.999999997 +nextm023 nextminus -0.999999997 -> -0.999999998 +nextm024 nextminus -0.999999998 -> -0.999999999 +nextm025 nextminus -0.999999999 -> -1.00000000 +nextm026 nextminus -1.00000000 -> -1.00000001 +nextm027 nextminus -1.0 -> -1.00000001 +nextm028 nextminus -1 -> -1.00000001 +nextm029 nextminus -1.00000001 -> -1.00000002 +nextm030 nextminus -1.00000002 -> -1.00000003 +nextm031 nextminus -1.00000003 -> -1.00000004 +nextm032 nextminus -1.00000004 -> -1.00000005 +nextm033 nextminus -1.00000005 -> -1.00000006 +nextm034 nextminus -1.00000006 -> -1.00000007 +nextm035 nextminus -1.00000007 -> -1.00000008 +nextm036 nextminus -1.00000008 -> -1.00000009 +nextm037 nextminus -1.00000009 -> -1.00000010 +nextm038 nextminus -1.00000010 -> -1.00000011 +nextm039 nextminus -1.00000011 -> -1.00000012 + +-- input operand is >precision +nextm041 nextminus 1.00000010998 -> 1.00000010 +nextm042 nextminus 1.00000010999 -> 1.00000010 +nextm043 nextminus 1.00000011000 -> 1.00000010 +nextm044 nextminus 1.00000011001 -> 1.00000011 +nextm045 nextminus 1.00000011002 -> 1.00000011 +nextm046 nextminus 1.00000011002 -> 1.00000011 +nextm047 nextminus 1.00000011052 -> 1.00000011 +nextm048 nextminus 1.00000011552 -> 1.00000011 +nextm049 nextminus -1.00000010998 -> -1.00000011 +nextm050 nextminus -1.00000010999 -> -1.00000011 +nextm051 nextminus -1.00000011000 -> -1.00000012 +nextm052 nextminus -1.00000011001 -> -1.00000012 +nextm053 nextminus -1.00000011002 -> -1.00000012 +nextm054 nextminus -1.00000011002 -> -1.00000012 +nextm055 nextminus -1.00000011052 -> -1.00000012 +nextm056 nextminus -1.00000011552 -> -1.00000012 +-- ultra-tiny inputs +nextm060 nextminus 1E-99999 -> 0E-391 +nextm061 nextminus 1E-999999999 -> 0E-391 +nextm062 nextminus 1E-391 -> 0E-391 +nextm063 nextminus -1E-99999 -> -1E-391 +nextm064 nextminus -1E-999999999 -> -1E-391 +nextm065 nextminus -1E-391 -> -2E-391 + +-- Zeros +nextm100 nextminus -0 -> -1E-391 +nextm101 nextminus 0 -> -1E-391 +nextm102 nextminus 0.00 -> -1E-391 +nextm103 nextminus -0.00 -> -1E-391 +nextm104 nextminus 0E-300 -> -1E-391 +nextm105 nextminus 0E+300 -> -1E-391 +nextm106 nextminus 0E+30000 -> -1E-391 +nextm107 nextminus -0E+30000 -> -1E-391 + +precision: 9 +maxExponent: 999 +minexponent: -999 +-- specials +nextm150 nextminus Inf -> 9.99999999E+999 +nextm151 nextminus -Inf -> -Infinity +nextm152 nextminus NaN -> NaN +nextm153 nextminus sNaN -> NaN Invalid_operation +nextm154 nextminus NaN77 -> NaN77 +nextm155 nextminus sNaN88 -> NaN88 Invalid_operation +nextm156 nextminus -NaN -> -NaN +nextm157 nextminus -sNaN -> -NaN Invalid_operation +nextm158 nextminus -NaN77 -> -NaN77 +nextm159 nextminus -sNaN88 -> -NaN88 Invalid_operation + +-- Nmax, Nmin, Ntiny, subnormals +nextm170 nextminus 9.99999999E+999 -> 9.99999998E+999 +nextm171 nextminus 9.99999998E+999 -> 9.99999997E+999 +nextm172 nextminus 1E-999 -> 9.9999999E-1000 +nextm173 nextminus 1.00000000E-999 -> 9.9999999E-1000 +nextm174 nextminus 9E-1007 -> 8E-1007 +nextm175 nextminus 9.9E-1006 -> 9.8E-1006 +nextm176 nextminus 9.9999E-1003 -> 9.9998E-1003 +nextm177 nextminus 9.9999999E-1000 -> 9.9999998E-1000 +nextm178 nextminus 9.9999998E-1000 -> 9.9999997E-1000 +nextm179 nextminus 9.9999997E-1000 -> 9.9999996E-1000 +nextm180 nextminus 0E-1007 -> -1E-1007 +nextm181 nextminus 1E-1007 -> 0E-1007 +nextm182 nextminus 2E-1007 -> 1E-1007 + +nextm183 nextminus -0E-1007 -> -1E-1007 +nextm184 nextminus -1E-1007 -> -2E-1007 +nextm185 nextminus -2E-1007 -> -3E-1007 +nextm186 nextminus -10E-1007 -> -1.1E-1006 +nextm187 nextminus -100E-1007 -> -1.01E-1005 +nextm188 nextminus -100000E-1007 -> -1.00001E-1002 +nextm189 nextminus -1.0000E-999 -> -1.00000001E-999 +nextm190 nextminus -1.00000000E-999 -> -1.00000001E-999 +nextm191 nextminus -1E-999 -> -1.00000001E-999 +nextm192 nextminus -9.99999998E+999 -> -9.99999999E+999 +nextm193 nextminus -9.99999999E+999 -> -Infinity + +-- Null tests +nextm900 nextminus # -> NaN Invalid_operation + Added: python/branches/release25-maint/Lib/test/decimaltestdata/nextplus.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/nextplus.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,150 @@ +------------------------------------------------------------------------ +-- nextplus.decTest -- decimal next that is greater [754r nextup] -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +extended: 1 +precision: 9 +rounding: half_up +maxExponent: 384 +minexponent: -383 + +nextp001 nextplus 0.999999995 -> 0.999999996 +nextp002 nextplus 0.999999996 -> 0.999999997 +nextp003 nextplus 0.999999997 -> 0.999999998 +nextp004 nextplus 0.999999998 -> 0.999999999 +nextp005 nextplus 0.999999999 -> 1.00000000 +nextp006 nextplus 1.00000000 -> 1.00000001 +nextp007 nextplus 1.0 -> 1.00000001 +nextp008 nextplus 1 -> 1.00000001 +nextp009 nextplus 1.00000001 -> 1.00000002 +nextp010 nextplus 1.00000002 -> 1.00000003 +nextp011 nextplus 1.00000003 -> 1.00000004 +nextp012 nextplus 1.00000004 -> 1.00000005 +nextp013 nextplus 1.00000005 -> 1.00000006 +nextp014 nextplus 1.00000006 -> 1.00000007 +nextp015 nextplus 1.00000007 -> 1.00000008 +nextp016 nextplus 1.00000008 -> 1.00000009 +nextp017 nextplus 1.00000009 -> 1.00000010 +nextp018 nextplus 1.00000010 -> 1.00000011 +nextp019 nextplus 1.00000011 -> 1.00000012 + +nextp021 nextplus -0.999999995 -> -0.999999994 +nextp022 nextplus -0.999999996 -> -0.999999995 +nextp023 nextplus -0.999999997 -> -0.999999996 +nextp024 nextplus -0.999999998 -> -0.999999997 +nextp025 nextplus -0.999999999 -> -0.999999998 +nextp026 nextplus -1.00000000 -> -0.999999999 +nextp027 nextplus -1.0 -> -0.999999999 +nextp028 nextplus -1 -> -0.999999999 +nextp029 nextplus -1.00000001 -> -1.00000000 +nextp030 nextplus -1.00000002 -> -1.00000001 +nextp031 nextplus -1.00000003 -> -1.00000002 +nextp032 nextplus -1.00000004 -> -1.00000003 +nextp033 nextplus -1.00000005 -> -1.00000004 +nextp034 nextplus -1.00000006 -> -1.00000005 +nextp035 nextplus -1.00000007 -> -1.00000006 +nextp036 nextplus -1.00000008 -> -1.00000007 +nextp037 nextplus -1.00000009 -> -1.00000008 +nextp038 nextplus -1.00000010 -> -1.00000009 +nextp039 nextplus -1.00000011 -> -1.00000010 +nextp040 nextplus -1.00000012 -> -1.00000011 + +-- input operand is >precision +nextp041 nextplus 1.00000010998 -> 1.00000011 +nextp042 nextplus 1.00000010999 -> 1.00000011 +nextp043 nextplus 1.00000011000 -> 1.00000012 +nextp044 nextplus 1.00000011001 -> 1.00000012 +nextp045 nextplus 1.00000011002 -> 1.00000012 +nextp046 nextplus 1.00000011002 -> 1.00000012 +nextp047 nextplus 1.00000011052 -> 1.00000012 +nextp048 nextplus 1.00000011552 -> 1.00000012 +nextp049 nextplus -1.00000010998 -> -1.00000010 +nextp050 nextplus -1.00000010999 -> -1.00000010 +nextp051 nextplus -1.00000011000 -> -1.00000010 +nextp052 nextplus -1.00000011001 -> -1.00000011 +nextp053 nextplus -1.00000011002 -> -1.00000011 +nextp054 nextplus -1.00000011002 -> -1.00000011 +nextp055 nextplus -1.00000011052 -> -1.00000011 +nextp056 nextplus -1.00000011552 -> -1.00000011 +-- ultra-tiny inputs +nextp060 nextplus 1E-99999 -> 1E-391 +nextp061 nextplus 1E-999999999 -> 1E-391 +nextp062 nextplus 1E-391 -> 2E-391 +nextp063 nextplus -1E-99999 -> -0E-391 +nextp064 nextplus -1E-999999999 -> -0E-391 +nextp065 nextplus -1E-391 -> -0E-391 + +-- Zeros +nextp100 nextplus 0 -> 1E-391 +nextp101 nextplus 0.00 -> 1E-391 +nextp102 nextplus 0E-300 -> 1E-391 +nextp103 nextplus 0E+300 -> 1E-391 +nextp104 nextplus 0E+30000 -> 1E-391 +nextp105 nextplus -0 -> 1E-391 +nextp106 nextplus -0.00 -> 1E-391 +nextp107 nextplus -0E-300 -> 1E-391 +nextp108 nextplus -0E+300 -> 1E-391 +nextp109 nextplus -0E+30000 -> 1E-391 + +maxExponent: 999 +minexponent: -999 +precision: 9 +-- specials +nextp150 nextplus Inf -> Infinity +nextp151 nextplus -Inf -> -9.99999999E+999 +nextp152 nextplus NaN -> NaN +nextp153 nextplus sNaN -> NaN Invalid_operation +nextp154 nextplus NaN77 -> NaN77 +nextp155 nextplus sNaN88 -> NaN88 Invalid_operation +nextp156 nextplus -NaN -> -NaN +nextp157 nextplus -sNaN -> -NaN Invalid_operation +nextp158 nextplus -NaN77 -> -NaN77 +nextp159 nextplus -sNaN88 -> -NaN88 Invalid_operation + +-- Nmax, Nmin, Ntiny, subnormals +nextp170 nextplus 9.99999999E+999 -> Infinity +nextp171 nextplus 9.99999998E+999 -> 9.99999999E+999 +nextp172 nextplus 1E-999 -> 1.00000001E-999 +nextp173 nextplus 1.00000000E-999 -> 1.00000001E-999 +nextp174 nextplus 9E-1007 -> 1.0E-1006 +nextp175 nextplus 9.9E-1006 -> 1.00E-1005 +nextp176 nextplus 9.9999E-1003 -> 1.00000E-1002 +nextp177 nextplus 9.9999999E-1000 -> 1.00000000E-999 +nextp178 nextplus 9.9999998E-1000 -> 9.9999999E-1000 +nextp179 nextplus 9.9999997E-1000 -> 9.9999998E-1000 +nextp180 nextplus 0E-1007 -> 1E-1007 +nextp181 nextplus 1E-1007 -> 2E-1007 +nextp182 nextplus 2E-1007 -> 3E-1007 + +nextp183 nextplus -0E-1007 -> 1E-1007 +nextp184 nextplus -1E-1007 -> -0E-1007 +nextp185 nextplus -2E-1007 -> -1E-1007 +nextp186 nextplus -10E-1007 -> -9E-1007 +nextp187 nextplus -100E-1007 -> -9.9E-1006 +nextp188 nextplus -100000E-1007 -> -9.9999E-1003 +nextp189 nextplus -1.0000E-999 -> -9.9999999E-1000 +nextp190 nextplus -1.00000000E-999 -> -9.9999999E-1000 +nextp191 nextplus -1E-999 -> -9.9999999E-1000 +nextp192 nextplus -9.99999998E+999 -> -9.99999997E+999 +nextp193 nextplus -9.99999999E+999 -> -9.99999998E+999 + +-- Null tests +nextp900 nextplus # -> NaN Invalid_operation + Added: python/branches/release25-maint/Lib/test/decimaltestdata/nexttoward.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/nexttoward.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,426 @@ +------------------------------------------------------------------------ +-- nexttoward.decTest -- decimal next toward rhs [754r nextafter] -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +extended: 1 +precision: 9 +rounding: half_up +maxExponent: 384 +minexponent: -383 + +-- Sanity check with a scattering of numerics +nextt001 nexttoward 10 10 -> 10 +nextt002 nexttoward -10 -10 -> -10 +nextt003 nexttoward 1 10 -> 1.00000001 +nextt004 nexttoward 1 -10 -> 0.999999999 +nextt005 nexttoward -1 10 -> -0.999999999 +nextt006 nexttoward -1 -10 -> -1.00000001 +nextt007 nexttoward 0 10 -> 1E-391 Underflow Subnormal Inexact Rounded +nextt008 nexttoward 0 -10 -> -1E-391 Underflow Subnormal Inexact Rounded +nextt009 nexttoward 9.99999999E+384 +Infinity -> Infinity Overflow Inexact Rounded +nextt010 nexttoward -9.99999999E+384 -Infinity -> -Infinity Overflow Inexact Rounded + +------- lhs=rhs +-- finites +nextt101 nexttoward 7 7 -> 7 +nextt102 nexttoward -7 -7 -> -7 +nextt103 nexttoward 75 75 -> 75 +nextt104 nexttoward -75 -75 -> -75 +nextt105 nexttoward 7.50 7.5 -> 7.50 +nextt106 nexttoward -7.50 -7.50 -> -7.50 +nextt107 nexttoward 7.500 7.5000 -> 7.500 +nextt108 nexttoward -7.500 -7.5 -> -7.500 + +-- zeros +nextt111 nexttoward 0 0 -> 0 +nextt112 nexttoward -0 -0 -> -0 +nextt113 nexttoward 0E+4 0 -> 0E+4 +nextt114 nexttoward -0E+4 -0 -> -0E+4 +nextt115 nexttoward 0.0000 0.00000 -> 0.0000 +nextt116 nexttoward -0.0000 -0.00 -> -0.0000 +nextt117 nexttoward 0E-141 0 -> 0E-141 +nextt118 nexttoward -0E-141 -000 -> -0E-141 + +-- full coefficients, alternating bits +nextt121 nexttoward 268268268 268268268 -> 268268268 +nextt122 nexttoward -268268268 -268268268 -> -268268268 +nextt123 nexttoward 134134134 134134134 -> 134134134 +nextt124 nexttoward -134134134 -134134134 -> -134134134 + +-- Nmax, Nmin, Ntiny +nextt131 nexttoward 9.99999999E+384 9.99999999E+384 -> 9.99999999E+384 +nextt132 nexttoward 1E-383 1E-383 -> 1E-383 +nextt133 nexttoward 1.00000000E-383 1.00000000E-383 -> 1.00000000E-383 +nextt134 nexttoward 1E-391 1E-391 -> 1E-391 + +nextt135 nexttoward -1E-391 -1E-391 -> -1E-391 +nextt136 nexttoward -1.00000000E-383 -1.00000000E-383 -> -1.00000000E-383 +nextt137 nexttoward -1E-383 -1E-383 -> -1E-383 +nextt138 nexttoward -9.99999999E+384 -9.99999999E+384 -> -9.99999999E+384 + +------- lhs 0.999999996 +nextt202 nexttoward 0.999999996 Infinity -> 0.999999997 +nextt203 nexttoward 0.999999997 Infinity -> 0.999999998 +nextt204 nexttoward 0.999999998 Infinity -> 0.999999999 +nextt205 nexttoward 0.999999999 Infinity -> 1.00000000 +nextt206 nexttoward 1.00000000 Infinity -> 1.00000001 +nextt207 nexttoward 1.0 Infinity -> 1.00000001 +nextt208 nexttoward 1 Infinity -> 1.00000001 +nextt209 nexttoward 1.00000001 Infinity -> 1.00000002 +nextt210 nexttoward 1.00000002 Infinity -> 1.00000003 +nextt211 nexttoward 1.00000003 Infinity -> 1.00000004 +nextt212 nexttoward 1.00000004 Infinity -> 1.00000005 +nextt213 nexttoward 1.00000005 Infinity -> 1.00000006 +nextt214 nexttoward 1.00000006 Infinity -> 1.00000007 +nextt215 nexttoward 1.00000007 Infinity -> 1.00000008 +nextt216 nexttoward 1.00000008 Infinity -> 1.00000009 +nextt217 nexttoward 1.00000009 Infinity -> 1.00000010 +nextt218 nexttoward 1.00000010 Infinity -> 1.00000011 +nextt219 nexttoward 1.00000011 Infinity -> 1.00000012 + +nextt221 nexttoward -0.999999995 Infinity -> -0.999999994 +nextt222 nexttoward -0.999999996 Infinity -> -0.999999995 +nextt223 nexttoward -0.999999997 Infinity -> -0.999999996 +nextt224 nexttoward -0.999999998 Infinity -> -0.999999997 +nextt225 nexttoward -0.999999999 Infinity -> -0.999999998 +nextt226 nexttoward -1.00000000 Infinity -> -0.999999999 +nextt227 nexttoward -1.0 Infinity -> -0.999999999 +nextt228 nexttoward -1 Infinity -> -0.999999999 +nextt229 nexttoward -1.00000001 Infinity -> -1.00000000 +nextt230 nexttoward -1.00000002 Infinity -> -1.00000001 +nextt231 nexttoward -1.00000003 Infinity -> -1.00000002 +nextt232 nexttoward -1.00000004 Infinity -> -1.00000003 +nextt233 nexttoward -1.00000005 Infinity -> -1.00000004 +nextt234 nexttoward -1.00000006 Infinity -> -1.00000005 +nextt235 nexttoward -1.00000007 Infinity -> -1.00000006 +nextt236 nexttoward -1.00000008 Infinity -> -1.00000007 +nextt237 nexttoward -1.00000009 Infinity -> -1.00000008 +nextt238 nexttoward -1.00000010 Infinity -> -1.00000009 +nextt239 nexttoward -1.00000011 Infinity -> -1.00000010 +nextt240 nexttoward -1.00000012 Infinity -> -1.00000011 + +-- input operand is >precision +nextt241 nexttoward 1.00000010998 Infinity -> 1.00000011 +nextt242 nexttoward 1.00000010999 Infinity -> 1.00000011 +nextt243 nexttoward 1.00000011000 Infinity -> 1.00000012 +nextt244 nexttoward 1.00000011001 Infinity -> 1.00000012 +nextt245 nexttoward 1.00000011002 Infinity -> 1.00000012 +nextt246 nexttoward 1.00000011002 Infinity -> 1.00000012 +nextt247 nexttoward 1.00000011052 Infinity -> 1.00000012 +nextt248 nexttoward 1.00000011552 Infinity -> 1.00000012 +nextt249 nexttoward -1.00000010998 Infinity -> -1.00000010 +nextt250 nexttoward -1.00000010999 Infinity -> -1.00000010 +nextt251 nexttoward -1.00000011000 Infinity -> -1.00000010 +nextt252 nexttoward -1.00000011001 Infinity -> -1.00000011 +nextt253 nexttoward -1.00000011002 Infinity -> -1.00000011 +nextt254 nexttoward -1.00000011002 Infinity -> -1.00000011 +nextt255 nexttoward -1.00000011052 Infinity -> -1.00000011 +nextt256 nexttoward -1.00000011552 Infinity -> -1.00000011 +-- ultra-tiny inputs +nextt260 nexttoward 1E-99999 Infinity -> 1E-391 Underflow Subnormal Inexact Rounded +nextt261 nexttoward 1E-999999999 Infinity -> 1E-391 Underflow Subnormal Inexact Rounded +nextt262 nexttoward 1E-391 Infinity -> 2E-391 Underflow Subnormal Inexact Rounded +nextt263 nexttoward -1E-99999 Infinity -> -0E-391 Underflow Subnormal Inexact Rounded Clamped +nextt264 nexttoward -1E-999999999 Infinity -> -0E-391 Underflow Subnormal Inexact Rounded Clamped +nextt265 nexttoward -1E-391 Infinity -> -0E-391 Underflow Subnormal Inexact Rounded Clamped + +-- Zeros +nextt300 nexttoward 0 Infinity -> 1E-391 Underflow Subnormal Inexact Rounded +nextt301 nexttoward 0.00 Infinity -> 1E-391 Underflow Subnormal Inexact Rounded +nextt302 nexttoward 0E-300 Infinity -> 1E-391 Underflow Subnormal Inexact Rounded +nextt303 nexttoward 0E+300 Infinity -> 1E-391 Underflow Subnormal Inexact Rounded +nextt304 nexttoward 0E+30000 Infinity -> 1E-391 Underflow Subnormal Inexact Rounded +nextt305 nexttoward -0 Infinity -> 1E-391 Underflow Subnormal Inexact Rounded +nextt306 nexttoward -0.00 Infinity -> 1E-391 Underflow Subnormal Inexact Rounded +nextt307 nexttoward -0E-300 Infinity -> 1E-391 Underflow Subnormal Inexact Rounded +nextt308 nexttoward -0E+300 Infinity -> 1E-391 Underflow Subnormal Inexact Rounded +nextt309 nexttoward -0E+30000 Infinity -> 1E-391 Underflow Subnormal Inexact Rounded + +-- specials +nextt350 nexttoward Inf Infinity -> Infinity +nextt351 nexttoward -Inf Infinity -> -9.99999999E+384 +nextt352 nexttoward NaN Infinity -> NaN +nextt353 nexttoward sNaN Infinity -> NaN Invalid_operation +nextt354 nexttoward NaN77 Infinity -> NaN77 +nextt355 nexttoward sNaN88 Infinity -> NaN88 Invalid_operation +nextt356 nexttoward -NaN Infinity -> -NaN +nextt357 nexttoward -sNaN Infinity -> -NaN Invalid_operation +nextt358 nexttoward -NaN77 Infinity -> -NaN77 +nextt359 nexttoward -sNaN88 Infinity -> -NaN88 Invalid_operation + +-- Nmax, Nmin, Ntiny, subnormals +maxExponent: 999 +minexponent: -999 +nextt370 nexttoward 9.99999999E+999 Infinity -> Infinity Overflow Inexact Rounded +nextt371 nexttoward 9.99999998E+999 Infinity -> 9.99999999E+999 +nextt372 nexttoward 1E-999 Infinity -> 1.00000001E-999 +nextt373 nexttoward 1.00000000E-999 Infinity -> 1.00000001E-999 +nextt374 nexttoward 0.999999999E-999 Infinity -> 1.00000000E-999 +nextt375 nexttoward 0.99999999E-999 Infinity -> 1.00000000E-999 +nextt376 nexttoward 9E-1007 Infinity -> 1.0E-1006 Underflow Subnormal Inexact Rounded +nextt377 nexttoward 9.9E-1006 Infinity -> 1.00E-1005 Underflow Subnormal Inexact Rounded +nextt378 nexttoward 9.9999E-1003 Infinity -> 1.00000E-1002 Underflow Subnormal Inexact Rounded +nextt379 nexttoward 9.9999998E-1000 Infinity -> 9.9999999E-1000 Underflow Subnormal Inexact Rounded +nextt380 nexttoward 9.9999997E-1000 Infinity -> 9.9999998E-1000 Underflow Subnormal Inexact Rounded +nextt381 nexttoward 0E-1007 Infinity -> 1E-1007 Underflow Subnormal Inexact Rounded +nextt382 nexttoward 1E-1007 Infinity -> 2E-1007 Underflow Subnormal Inexact Rounded +nextt383 nexttoward 2E-1007 Infinity -> 3E-1007 Underflow Subnormal Inexact Rounded + +nextt385 nexttoward -0E-1007 Infinity -> 1E-1007 Underflow Subnormal Inexact Rounded +nextt386 nexttoward -1E-1007 Infinity -> -0E-1007 Underflow Subnormal Inexact Rounded Clamped +nextt387 nexttoward -2E-1007 Infinity -> -1E-1007 Underflow Subnormal Inexact Rounded +nextt388 nexttoward -10E-1007 Infinity -> -9E-1007 Underflow Subnormal Inexact Rounded +nextt389 nexttoward -100E-1007 Infinity -> -9.9E-1006 Underflow Subnormal Inexact Rounded +nextt390 nexttoward -100000E-1007 Infinity -> -9.9999E-1003 Underflow Subnormal Inexact Rounded +nextt391 nexttoward -1.0000E-999 Infinity -> -9.9999999E-1000 Underflow Subnormal Inexact Rounded +nextt392 nexttoward -1.00000000E-999 Infinity -> -9.9999999E-1000 Underflow Subnormal Inexact Rounded +nextt393 nexttoward -1E-999 Infinity -> -9.9999999E-1000 Underflow Subnormal Inexact Rounded +nextt394 nexttoward -9.99999998E+999 Infinity -> -9.99999997E+999 +nextt395 nexttoward -9.99999999E+999 Infinity -> -9.99999998E+999 + +------- lhs>rhs +maxExponent: 384 +minexponent: -383 +nextt401 nexttoward 0.999999995 -Infinity -> 0.999999994 +nextt402 nexttoward 0.999999996 -Infinity -> 0.999999995 +nextt403 nexttoward 0.999999997 -Infinity -> 0.999999996 +nextt404 nexttoward 0.999999998 -Infinity -> 0.999999997 +nextt405 nexttoward 0.999999999 -Infinity -> 0.999999998 +nextt406 nexttoward 1.00000000 -Infinity -> 0.999999999 +nextt407 nexttoward 1.0 -Infinity -> 0.999999999 +nextt408 nexttoward 1 -Infinity -> 0.999999999 +nextt409 nexttoward 1.00000001 -Infinity -> 1.00000000 +nextt410 nexttoward 1.00000002 -Infinity -> 1.00000001 +nextt411 nexttoward 1.00000003 -Infinity -> 1.00000002 +nextt412 nexttoward 1.00000004 -Infinity -> 1.00000003 +nextt413 nexttoward 1.00000005 -Infinity -> 1.00000004 +nextt414 nexttoward 1.00000006 -Infinity -> 1.00000005 +nextt415 nexttoward 1.00000007 -Infinity -> 1.00000006 +nextt416 nexttoward 1.00000008 -Infinity -> 1.00000007 +nextt417 nexttoward 1.00000009 -Infinity -> 1.00000008 +nextt418 nexttoward 1.00000010 -Infinity -> 1.00000009 +nextt419 nexttoward 1.00000011 -Infinity -> 1.00000010 +nextt420 nexttoward 1.00000012 -Infinity -> 1.00000011 + +nextt421 nexttoward -0.999999995 -Infinity -> -0.999999996 +nextt422 nexttoward -0.999999996 -Infinity -> -0.999999997 +nextt423 nexttoward -0.999999997 -Infinity -> -0.999999998 +nextt424 nexttoward -0.999999998 -Infinity -> -0.999999999 +nextt425 nexttoward -0.999999999 -Infinity -> -1.00000000 +nextt426 nexttoward -1.00000000 -Infinity -> -1.00000001 +nextt427 nexttoward -1.0 -Infinity -> -1.00000001 +nextt428 nexttoward -1 -Infinity -> -1.00000001 +nextt429 nexttoward -1.00000001 -Infinity -> -1.00000002 +nextt430 nexttoward -1.00000002 -Infinity -> -1.00000003 +nextt431 nexttoward -1.00000003 -Infinity -> -1.00000004 +nextt432 nexttoward -1.00000004 -Infinity -> -1.00000005 +nextt433 nexttoward -1.00000005 -Infinity -> -1.00000006 +nextt434 nexttoward -1.00000006 -Infinity -> -1.00000007 +nextt435 nexttoward -1.00000007 -Infinity -> -1.00000008 +nextt436 nexttoward -1.00000008 -Infinity -> -1.00000009 +nextt437 nexttoward -1.00000009 -Infinity -> -1.00000010 +nextt438 nexttoward -1.00000010 -Infinity -> -1.00000011 +nextt439 nexttoward -1.00000011 -Infinity -> -1.00000012 + +-- input operand is >precision +nextt441 nexttoward 1.00000010998 -Infinity -> 1.00000010 +nextt442 nexttoward 1.00000010999 -Infinity -> 1.00000010 +nextt443 nexttoward 1.00000011000 -Infinity -> 1.00000010 +nextt444 nexttoward 1.00000011001 -Infinity -> 1.00000011 +nextt445 nexttoward 1.00000011002 -Infinity -> 1.00000011 +nextt446 nexttoward 1.00000011002 -Infinity -> 1.00000011 +nextt447 nexttoward 1.00000011052 -Infinity -> 1.00000011 +nextt448 nexttoward 1.00000011552 -Infinity -> 1.00000011 +nextt449 nexttoward -1.00000010998 -Infinity -> -1.00000011 +nextt450 nexttoward -1.00000010999 -Infinity -> -1.00000011 +nextt451 nexttoward -1.00000011000 -Infinity -> -1.00000012 +nextt452 nexttoward -1.00000011001 -Infinity -> -1.00000012 +nextt453 nexttoward -1.00000011002 -Infinity -> -1.00000012 +nextt454 nexttoward -1.00000011002 -Infinity -> -1.00000012 +nextt455 nexttoward -1.00000011052 -Infinity -> -1.00000012 +nextt456 nexttoward -1.00000011552 -Infinity -> -1.00000012 +-- ultra-tiny inputs +nextt460 nexttoward 1E-99999 -Infinity -> 0E-391 Underflow Subnormal Inexact Rounded Clamped +nextt461 nexttoward 1E-999999999 -Infinity -> 0E-391 Underflow Subnormal Inexact Rounded Clamped +nextt462 nexttoward 1E-391 -Infinity -> 0E-391 Underflow Subnormal Inexact Rounded Clamped +nextt463 nexttoward -1E-99999 -Infinity -> -1E-391 Underflow Subnormal Inexact Rounded +nextt464 nexttoward -1E-999999999 -Infinity -> -1E-391 Underflow Subnormal Inexact Rounded +nextt465 nexttoward -1E-391 -Infinity -> -2E-391 Underflow Subnormal Inexact Rounded + +-- Zeros +nextt500 nexttoward -0 -Infinity -> -1E-391 Underflow Subnormal Inexact Rounded +nextt501 nexttoward 0 -Infinity -> -1E-391 Underflow Subnormal Inexact Rounded +nextt502 nexttoward 0.00 -Infinity -> -1E-391 Underflow Subnormal Inexact Rounded +nextt503 nexttoward -0.00 -Infinity -> -1E-391 Underflow Subnormal Inexact Rounded +nextt504 nexttoward 0E-300 -Infinity -> -1E-391 Underflow Subnormal Inexact Rounded +nextt505 nexttoward 0E+300 -Infinity -> -1E-391 Underflow Subnormal Inexact Rounded +nextt506 nexttoward 0E+30000 -Infinity -> -1E-391 Underflow Subnormal Inexact Rounded +nextt507 nexttoward -0E+30000 -Infinity -> -1E-391 Underflow Subnormal Inexact Rounded +nextt508 nexttoward 0.00 -0.0000 -> -0.00 + +-- specials +nextt550 nexttoward Inf -Infinity -> 9.99999999E+384 +nextt551 nexttoward -Inf -Infinity -> -Infinity +nextt552 nexttoward NaN -Infinity -> NaN +nextt553 nexttoward sNaN -Infinity -> NaN Invalid_operation +nextt554 nexttoward NaN77 -Infinity -> NaN77 +nextt555 nexttoward sNaN88 -Infinity -> NaN88 Invalid_operation +nextt556 nexttoward -NaN -Infinity -> -NaN +nextt557 nexttoward -sNaN -Infinity -> -NaN Invalid_operation +nextt558 nexttoward -NaN77 -Infinity -> -NaN77 +nextt559 nexttoward -sNaN88 -Infinity -> -NaN88 Invalid_operation + +-- Nmax, Nmin, Ntiny, subnormals +maxExponent: 999 +minexponent: -999 +nextt570 nexttoward 9.99999999E+999 -Infinity -> 9.99999998E+999 +nextt571 nexttoward 9.99999998E+999 -Infinity -> 9.99999997E+999 +nextt572 nexttoward 1E-999 -Infinity -> 9.9999999E-1000 Underflow Subnormal Inexact Rounded +nextt573 nexttoward 1.00000000E-999 -Infinity -> 9.9999999E-1000 Underflow Subnormal Inexact Rounded +nextt574 nexttoward 9E-1007 -Infinity -> 8E-1007 Underflow Subnormal Inexact Rounded +nextt575 nexttoward 9.9E-1006 -Infinity -> 9.8E-1006 Underflow Subnormal Inexact Rounded +nextt576 nexttoward 9.9999E-1003 -Infinity -> 9.9998E-1003 Underflow Subnormal Inexact Rounded +nextt577 nexttoward 9.9999999E-1000 -Infinity -> 9.9999998E-1000 Underflow Subnormal Inexact Rounded +nextt578 nexttoward 9.9999998E-1000 -Infinity -> 9.9999997E-1000 Underflow Subnormal Inexact Rounded +nextt579 nexttoward 9.9999997E-1000 -Infinity -> 9.9999996E-1000 Underflow Subnormal Inexact Rounded +nextt580 nexttoward 0E-1007 -Infinity -> -1E-1007 Underflow Subnormal Inexact Rounded +nextt581 nexttoward 1E-1007 -Infinity -> 0E-1007 Underflow Subnormal Inexact Rounded Clamped +nextt582 nexttoward 2E-1007 -Infinity -> 1E-1007 Underflow Subnormal Inexact Rounded + +nextt583 nexttoward -0E-1007 -Infinity -> -1E-1007 Underflow Subnormal Inexact Rounded +nextt584 nexttoward -1E-1007 -Infinity -> -2E-1007 Underflow Subnormal Inexact Rounded +nextt585 nexttoward -2E-1007 -Infinity -> -3E-1007 Underflow Subnormal Inexact Rounded +nextt586 nexttoward -10E-1007 -Infinity -> -1.1E-1006 Underflow Subnormal Inexact Rounded +nextt587 nexttoward -100E-1007 -Infinity -> -1.01E-1005 Underflow Subnormal Inexact Rounded +nextt588 nexttoward -100000E-1007 -Infinity -> -1.00001E-1002 Underflow Subnormal Inexact Rounded +nextt589 nexttoward -1.0000E-999 -Infinity -> -1.00000001E-999 +nextt590 nexttoward -1.00000000E-999 -Infinity -> -1.00000001E-999 +nextt591 nexttoward -1E-999 -Infinity -> -1.00000001E-999 +nextt592 nexttoward -9.99999998E+999 -Infinity -> -9.99999999E+999 +nextt593 nexttoward -9.99999999E+999 -Infinity -> -Infinity Overflow Inexact Rounded + + + + +------- Specials +maxExponent: 384 +minexponent: -383 +nextt780 nexttoward -Inf -Inf -> -Infinity +nextt781 nexttoward -Inf -1000 -> -9.99999999E+384 +nextt782 nexttoward -Inf -1 -> -9.99999999E+384 +nextt783 nexttoward -Inf -0 -> -9.99999999E+384 +nextt784 nexttoward -Inf 0 -> -9.99999999E+384 +nextt785 nexttoward -Inf 1 -> -9.99999999E+384 +nextt786 nexttoward -Inf 1000 -> -9.99999999E+384 +nextt787 nexttoward -1000 -Inf -> -1000.00001 +nextt788 nexttoward -Inf -Inf -> -Infinity +nextt789 nexttoward -1 -Inf -> -1.00000001 +nextt790 nexttoward -0 -Inf -> -1E-391 Underflow Subnormal Inexact Rounded +nextt791 nexttoward 0 -Inf -> -1E-391 Underflow Subnormal Inexact Rounded +nextt792 nexttoward 1 -Inf -> 0.999999999 +nextt793 nexttoward 1000 -Inf -> 999.999999 +nextt794 nexttoward Inf -Inf -> 9.99999999E+384 + +nextt800 nexttoward Inf -Inf -> 9.99999999E+384 +nextt801 nexttoward Inf -1000 -> 9.99999999E+384 +nextt802 nexttoward Inf -1 -> 9.99999999E+384 +nextt803 nexttoward Inf -0 -> 9.99999999E+384 +nextt804 nexttoward Inf 0 -> 9.99999999E+384 +nextt805 nexttoward Inf 1 -> 9.99999999E+384 +nextt806 nexttoward Inf 1000 -> 9.99999999E+384 +nextt807 nexttoward Inf Inf -> Infinity +nextt808 nexttoward -1000 Inf -> -999.999999 +nextt809 nexttoward -Inf Inf -> -9.99999999E+384 +nextt810 nexttoward -1 Inf -> -0.999999999 +nextt811 nexttoward -0 Inf -> 1E-391 Underflow Subnormal Inexact Rounded +nextt812 nexttoward 0 Inf -> 1E-391 Underflow Subnormal Inexact Rounded +nextt813 nexttoward 1 Inf -> 1.00000001 +nextt814 nexttoward 1000 Inf -> 1000.00001 +nextt815 nexttoward Inf Inf -> Infinity + +nextt821 nexttoward NaN -Inf -> NaN +nextt822 nexttoward NaN -1000 -> NaN +nextt823 nexttoward NaN -1 -> NaN +nextt824 nexttoward NaN -0 -> NaN +nextt825 nexttoward NaN 0 -> NaN +nextt826 nexttoward NaN 1 -> NaN +nextt827 nexttoward NaN 1000 -> NaN +nextt828 nexttoward NaN Inf -> NaN +nextt829 nexttoward NaN NaN -> NaN +nextt830 nexttoward -Inf NaN -> NaN +nextt831 nexttoward -1000 NaN -> NaN +nextt832 nexttoward -1 NaN -> NaN +nextt833 nexttoward -0 NaN -> NaN +nextt834 nexttoward 0 NaN -> NaN +nextt835 nexttoward 1 NaN -> NaN +nextt836 nexttoward 1000 NaN -> NaN +nextt837 nexttoward Inf NaN -> NaN + +nextt841 nexttoward sNaN -Inf -> NaN Invalid_operation +nextt842 nexttoward sNaN -1000 -> NaN Invalid_operation +nextt843 nexttoward sNaN -1 -> NaN Invalid_operation +nextt844 nexttoward sNaN -0 -> NaN Invalid_operation +nextt845 nexttoward sNaN 0 -> NaN Invalid_operation +nextt846 nexttoward sNaN 1 -> NaN Invalid_operation +nextt847 nexttoward sNaN 1000 -> NaN Invalid_operation +nextt848 nexttoward sNaN NaN -> NaN Invalid_operation +nextt849 nexttoward sNaN sNaN -> NaN Invalid_operation +nextt850 nexttoward NaN sNaN -> NaN Invalid_operation +nextt851 nexttoward -Inf sNaN -> NaN Invalid_operation +nextt852 nexttoward -1000 sNaN -> NaN Invalid_operation +nextt853 nexttoward -1 sNaN -> NaN Invalid_operation +nextt854 nexttoward -0 sNaN -> NaN Invalid_operation +nextt855 nexttoward 0 sNaN -> NaN Invalid_operation +nextt856 nexttoward 1 sNaN -> NaN Invalid_operation +nextt857 nexttoward 1000 sNaN -> NaN Invalid_operation +nextt858 nexttoward Inf sNaN -> NaN Invalid_operation +nextt859 nexttoward NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +nextt861 nexttoward NaN1 -Inf -> NaN1 +nextt862 nexttoward +NaN2 -1000 -> NaN2 +nextt863 nexttoward NaN3 1000 -> NaN3 +nextt864 nexttoward NaN4 Inf -> NaN4 +nextt865 nexttoward NaN5 +NaN6 -> NaN5 +nextt866 nexttoward -Inf NaN7 -> NaN7 +nextt867 nexttoward -1000 NaN8 -> NaN8 +nextt868 nexttoward 1000 NaN9 -> NaN9 +nextt869 nexttoward Inf +NaN10 -> NaN10 +nextt871 nexttoward sNaN11 -Inf -> NaN11 Invalid_operation +nextt872 nexttoward sNaN12 -1000 -> NaN12 Invalid_operation +nextt873 nexttoward sNaN13 1000 -> NaN13 Invalid_operation +nextt874 nexttoward sNaN14 NaN17 -> NaN14 Invalid_operation +nextt875 nexttoward sNaN15 sNaN18 -> NaN15 Invalid_operation +nextt876 nexttoward NaN16 sNaN19 -> NaN19 Invalid_operation +nextt877 nexttoward -Inf +sNaN20 -> NaN20 Invalid_operation +nextt878 nexttoward -1000 sNaN21 -> NaN21 Invalid_operation +nextt879 nexttoward 1000 sNaN22 -> NaN22 Invalid_operation +nextt880 nexttoward Inf sNaN23 -> NaN23 Invalid_operation +nextt881 nexttoward +NaN25 +sNaN24 -> NaN24 Invalid_operation +nextt882 nexttoward -NaN26 NaN28 -> -NaN26 +nextt883 nexttoward -sNaN27 sNaN29 -> -NaN27 Invalid_operation +nextt884 nexttoward 1000 -NaN30 -> -NaN30 +nextt885 nexttoward 1000 -sNaN31 -> -NaN31 Invalid_operation + +-- Null tests +nextt900 nexttoward 1 # -> NaN Invalid_operation +nextt901 nexttoward # 1 -> NaN Invalid_operation + Deleted: /python/branches/release25-maint/Lib/test/decimaltestdata/normalize.decTest ============================================================================== --- /python/branches/release25-maint/Lib/test/decimaltestdata/normalize.decTest Tue Jan 8 17:20:31 2008 +++ (empty file) @@ -1,225 +0,0 @@ ------------------------------------------------------------------------- --- normalize.decTest -- remove trailing zeros -- --- Copyright (c) IBM Corporation, 2003. All rights reserved. -- ------------------------------------------------------------------------- --- Please see the document "General Decimal Arithmetic Testcases" -- --- at http://www2.hursley.ibm.com/decimal for the description of -- --- these testcases. -- --- -- --- These testcases are experimental ('beta' versions), and they -- --- may contain errors. They are offered on an as-is basis. In -- --- particular, achieving the same results as the tests here is not -- --- a guarantee that an implementation complies with any Standard -- --- or specification. The tests are not exhaustive. -- --- -- --- Please send comments, suggestions, and corrections to the author: -- --- Mike Cowlishaw, IBM Fellow -- --- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- --- mfc at uk.ibm.com -- ------------------------------------------------------------------------- -version: 2.39 - -extended: 1 -precision: 9 -rounding: half_up -maxExponent: 999 -minexponent: -999 - -nrmx001 normalize '1' -> '1' -nrmx002 normalize '-1' -> '-1' -nrmx003 normalize '1.00' -> '1' -nrmx004 normalize '-1.00' -> '-1' -nrmx005 normalize '0' -> '0' -nrmx006 normalize '0.00' -> '0' -nrmx007 normalize '00.0' -> '0' -nrmx008 normalize '00.00' -> '0' -nrmx009 normalize '00' -> '0' -nrmx010 normalize '0E+1' -> '0' -nrmx011 normalize '0E+5' -> '0' - -nrmx012 normalize '-2' -> '-2' -nrmx013 normalize '2' -> '2' -nrmx014 normalize '-2.00' -> '-2' -nrmx015 normalize '2.00' -> '2' -nrmx016 normalize '-0' -> '-0' -nrmx017 normalize '-0.00' -> '-0' -nrmx018 normalize '-00.0' -> '-0' -nrmx019 normalize '-00.00' -> '-0' -nrmx020 normalize '-00' -> '-0' -nrmx021 normalize '-0E+5' -> '-0' -nrmx022 normalize '-0E+1' -> '-0' - -nrmx030 normalize '+0.1' -> '0.1' -nrmx031 normalize '-0.1' -> '-0.1' -nrmx032 normalize '+0.01' -> '0.01' -nrmx033 normalize '-0.01' -> '-0.01' -nrmx034 normalize '+0.001' -> '0.001' -nrmx035 normalize '-0.001' -> '-0.001' -nrmx036 normalize '+0.000001' -> '0.000001' -nrmx037 normalize '-0.000001' -> '-0.000001' -nrmx038 normalize '+0.000000000001' -> '1E-12' -nrmx039 normalize '-0.000000000001' -> '-1E-12' - -nrmx041 normalize 1.1 -> 1.1 -nrmx042 normalize 1.10 -> 1.1 -nrmx043 normalize 1.100 -> 1.1 -nrmx044 normalize 1.110 -> 1.11 -nrmx045 normalize -1.1 -> -1.1 -nrmx046 normalize -1.10 -> -1.1 -nrmx047 normalize -1.100 -> -1.1 -nrmx048 normalize -1.110 -> -1.11 -nrmx049 normalize 9.9 -> 9.9 -nrmx050 normalize 9.90 -> 9.9 -nrmx051 normalize 9.900 -> 9.9 -nrmx052 normalize 9.990 -> 9.99 -nrmx053 normalize -9.9 -> -9.9 -nrmx054 normalize -9.90 -> -9.9 -nrmx055 normalize -9.900 -> -9.9 -nrmx056 normalize -9.990 -> -9.99 - --- some trailing fractional zeros with zeros in units -nrmx060 normalize 10.0 -> 1E+1 -nrmx061 normalize 10.00 -> 1E+1 -nrmx062 normalize 100.0 -> 1E+2 -nrmx063 normalize 100.00 -> 1E+2 -nrmx064 normalize 1.1000E+3 -> 1.1E+3 -nrmx065 normalize 1.10000E+3 -> 1.1E+3 -nrmx066 normalize -10.0 -> -1E+1 -nrmx067 normalize -10.00 -> -1E+1 -nrmx068 normalize -100.0 -> -1E+2 -nrmx069 normalize -100.00 -> -1E+2 -nrmx070 normalize -1.1000E+3 -> -1.1E+3 -nrmx071 normalize -1.10000E+3 -> -1.1E+3 - --- some insignificant trailing zeros with positive exponent -nrmx080 normalize 10E+1 -> 1E+2 -nrmx081 normalize 100E+1 -> 1E+3 -nrmx082 normalize 1.0E+2 -> 1E+2 -nrmx083 normalize 1.0E+3 -> 1E+3 -nrmx084 normalize 1.1E+3 -> 1.1E+3 -nrmx085 normalize 1.00E+3 -> 1E+3 -nrmx086 normalize 1.10E+3 -> 1.1E+3 -nrmx087 normalize -10E+1 -> -1E+2 -nrmx088 normalize -100E+1 -> -1E+3 -nrmx089 normalize -1.0E+2 -> -1E+2 -nrmx090 normalize -1.0E+3 -> -1E+3 -nrmx091 normalize -1.1E+3 -> -1.1E+3 -nrmx092 normalize -1.00E+3 -> -1E+3 -nrmx093 normalize -1.10E+3 -> -1.1E+3 - --- some significant trailing zeros, were we to be trimming -nrmx100 normalize 11 -> 11 -nrmx101 normalize 10 -> 1E+1 -nrmx102 normalize 10. -> 1E+1 -nrmx103 normalize 1.1E+1 -> 11 -nrmx104 normalize 1.0E+1 -> 1E+1 -nrmx105 normalize 1.10E+2 -> 1.1E+2 -nrmx106 normalize 1.00E+2 -> 1E+2 -nrmx107 normalize 1.100E+3 -> 1.1E+3 -nrmx108 normalize 1.000E+3 -> 1E+3 -nrmx109 normalize 1.000000E+6 -> 1E+6 -nrmx110 normalize -11 -> -11 -nrmx111 normalize -10 -> -1E+1 -nrmx112 normalize -10. -> -1E+1 -nrmx113 normalize -1.1E+1 -> -11 -nrmx114 normalize -1.0E+1 -> -1E+1 -nrmx115 normalize -1.10E+2 -> -1.1E+2 -nrmx116 normalize -1.00E+2 -> -1E+2 -nrmx117 normalize -1.100E+3 -> -1.1E+3 -nrmx118 normalize -1.000E+3 -> -1E+3 -nrmx119 normalize -1.00000E+5 -> -1E+5 -nrmx120 normalize -1.000000E+6 -> -1E+6 -nrmx121 normalize -10.00000E+6 -> -1E+7 -nrmx122 normalize -100.0000E+6 -> -1E+8 -nrmx123 normalize -1000.000E+6 -> -1E+9 -nrmx124 normalize -10000.00E+6 -> -1E+10 -nrmx125 normalize -100000.0E+6 -> -1E+11 -nrmx126 normalize -1000000.E+6 -> -1E+12 - --- examples from decArith -nrmx140 normalize '2.1' -> '2.1' -nrmx141 normalize '-2.0' -> '-2' -nrmx142 normalize '1.200' -> '1.2' -nrmx143 normalize '-120' -> '-1.2E+2' -nrmx144 normalize '120.00' -> '1.2E+2' -nrmx145 normalize '0.00' -> '0' - --- overflow tests -maxexponent: 999999999 -minexponent: -999999999 -precision: 3 -nrmx160 normalize 9.999E+999999999 -> Infinity Inexact Overflow Rounded -nrmx161 normalize -9.999E+999999999 -> -Infinity Inexact Overflow Rounded - --- subnormals and underflow -precision: 3 -maxexponent: 999 -minexponent: -999 -nrmx210 normalize 1.00E-999 -> 1E-999 -nrmx211 normalize 0.1E-999 -> 1E-1000 Subnormal -nrmx212 normalize 0.10E-999 -> 1E-1000 Subnormal -nrmx213 normalize 0.100E-999 -> 1E-1000 Subnormal Rounded -nrmx214 normalize 0.01E-999 -> 1E-1001 Subnormal --- next is rounded to Emin -nrmx215 normalize 0.999E-999 -> 1E-999 Inexact Rounded Subnormal Underflow -nrmx216 normalize 0.099E-999 -> 1E-1000 Inexact Rounded Subnormal Underflow -nrmx217 normalize 0.009E-999 -> 1E-1001 Inexact Rounded Subnormal Underflow -nrmx218 normalize 0.001E-999 -> 0 Inexact Rounded Subnormal Underflow -nrmx219 normalize 0.0009E-999 -> 0 Inexact Rounded Subnormal Underflow -nrmx220 normalize 0.0001E-999 -> 0 Inexact Rounded Subnormal Underflow - -nrmx230 normalize -1.00E-999 -> -1E-999 -nrmx231 normalize -0.1E-999 -> -1E-1000 Subnormal -nrmx232 normalize -0.10E-999 -> -1E-1000 Subnormal -nrmx233 normalize -0.100E-999 -> -1E-1000 Subnormal Rounded -nrmx234 normalize -0.01E-999 -> -1E-1001 Subnormal --- next is rounded to Emin -nrmx235 normalize -0.999E-999 -> -1E-999 Inexact Rounded Subnormal Underflow -nrmx236 normalize -0.099E-999 -> -1E-1000 Inexact Rounded Subnormal Underflow -nrmx237 normalize -0.009E-999 -> -1E-1001 Inexact Rounded Subnormal Underflow -nrmx238 normalize -0.001E-999 -> -0 Inexact Rounded Subnormal Underflow -nrmx239 normalize -0.0009E-999 -> -0 Inexact Rounded Subnormal Underflow -nrmx240 normalize -0.0001E-999 -> -0 Inexact Rounded Subnormal Underflow - --- more reshaping -precision: 9 -nrmx260 normalize '56260E-10' -> '0.000005626' -nrmx261 normalize '56260E-5' -> '0.5626' -nrmx262 normalize '56260E-2' -> '562.6' -nrmx263 normalize '56260E-1' -> '5626' -nrmx265 normalize '56260E-0' -> '5.626E+4' -nrmx266 normalize '56260E+0' -> '5.626E+4' -nrmx267 normalize '56260E+1' -> '5.626E+5' -nrmx268 normalize '56260E+2' -> '5.626E+6' -nrmx269 normalize '56260E+3' -> '5.626E+7' -nrmx270 normalize '56260E+4' -> '5.626E+8' -nrmx271 normalize '56260E+5' -> '5.626E+9' -nrmx272 normalize '56260E+6' -> '5.626E+10' -nrmx280 normalize '-56260E-10' -> '-0.000005626' -nrmx281 normalize '-56260E-5' -> '-0.5626' -nrmx282 normalize '-56260E-2' -> '-562.6' -nrmx283 normalize '-56260E-1' -> '-5626' -nrmx285 normalize '-56260E-0' -> '-5.626E+4' -nrmx286 normalize '-56260E+0' -> '-5.626E+4' -nrmx287 normalize '-56260E+1' -> '-5.626E+5' -nrmx288 normalize '-56260E+2' -> '-5.626E+6' -nrmx289 normalize '-56260E+3' -> '-5.626E+7' -nrmx290 normalize '-56260E+4' -> '-5.626E+8' -nrmx291 normalize '-56260E+5' -> '-5.626E+9' -nrmx292 normalize '-56260E+6' -> '-5.626E+10' - - --- specials -nrmx820 normalize 'Inf' -> 'Infinity' -nrmx821 normalize '-Inf' -> '-Infinity' -nrmx822 normalize NaN -> NaN -nrmx823 normalize sNaN -> NaN Invalid_operation -nrmx824 normalize NaN101 -> NaN101 -nrmx825 normalize sNaN010 -> NaN10 Invalid_operation -nrmx827 normalize -NaN -> -NaN -nrmx828 normalize -sNaN -> -NaN Invalid_operation -nrmx829 normalize -NaN101 -> -NaN101 -nrmx830 normalize -sNaN010 -> -NaN10 Invalid_operation - --- Null test -nrmx900 normalize # -> NaN Invalid_operation Added: python/branches/release25-maint/Lib/test/decimaltestdata/or.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/or.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,334 @@ +------------------------------------------------------------------------ +-- or.decTest -- digitwise logical OR -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +extended: 1 +precision: 9 +rounding: half_up +maxExponent: 999 +minExponent: -999 + +-- Sanity check (truth table) +orx001 or 0 0 -> 0 +orx002 or 0 1 -> 1 +orx003 or 1 0 -> 1 +orx004 or 1 1 -> 1 +orx005 or 1100 1010 -> 1110 +-- and at msd and msd-1 +orx006 or 000000000 000000000 -> 0 +orx007 or 000000000 100000000 -> 100000000 +orx008 or 100000000 000000000 -> 100000000 +orx009 or 100000000 100000000 -> 100000000 +orx010 or 000000000 000000000 -> 0 +orx011 or 000000000 010000000 -> 10000000 +orx012 or 010000000 000000000 -> 10000000 +orx013 or 010000000 010000000 -> 10000000 + +-- Various lengths +-- 123456789 123456789 123456789 +orx021 or 111111111 111111111 -> 111111111 +orx022 or 111111111111 111111111 -> 111111111 +orx023 or 11111111 11111111 -> 11111111 +orx025 or 1111111 1111111 -> 1111111 +orx026 or 111111 111111 -> 111111 +orx027 or 11111 11111 -> 11111 +orx028 or 1111 1111 -> 1111 +orx029 or 111 111 -> 111 +orx031 or 11 11 -> 11 +orx032 or 1 1 -> 1 +orx033 or 111111111111 1111111111 -> 111111111 +orx034 or 11111111111 11111111111 -> 111111111 +orx035 or 1111111111 111111111111 -> 111111111 +orx036 or 111111111 1111111111111 -> 111111111 + +orx040 or 111111111 111111111111 -> 111111111 +orx041 or 11111111 111111111111 -> 111111111 +orx042 or 11111111 111111111 -> 111111111 +orx043 or 1111111 100000010 -> 101111111 +orx044 or 111111 100000100 -> 100111111 +orx045 or 11111 100001000 -> 100011111 +orx046 or 1111 100010000 -> 100011111 +orx047 or 111 100100000 -> 100100111 +orx048 or 11 101000000 -> 101000011 +orx049 or 1 110000000 -> 110000001 + +orx050 or 1111111111 1 -> 111111111 +orx051 or 111111111 1 -> 111111111 +orx052 or 11111111 1 -> 11111111 +orx053 or 1111111 1 -> 1111111 +orx054 or 111111 1 -> 111111 +orx055 or 11111 1 -> 11111 +orx056 or 1111 1 -> 1111 +orx057 or 111 1 -> 111 +orx058 or 11 1 -> 11 +orx059 or 1 1 -> 1 + +orx060 or 1111111111 0 -> 111111111 +orx061 or 111111111 0 -> 111111111 +orx062 or 11111111 0 -> 11111111 +orx063 or 1111111 0 -> 1111111 +orx064 or 111111 0 -> 111111 +orx065 or 11111 0 -> 11111 +orx066 or 1111 0 -> 1111 +orx067 or 111 0 -> 111 +orx068 or 11 0 -> 11 +orx069 or 1 0 -> 1 + +orx070 or 1 1111111111 -> 111111111 +orx071 or 1 111111111 -> 111111111 +orx072 or 1 11111111 -> 11111111 +orx073 or 1 1111111 -> 1111111 +orx074 or 1 111111 -> 111111 +orx075 or 1 11111 -> 11111 +orx076 or 1 1111 -> 1111 +orx077 or 1 111 -> 111 +orx078 or 1 11 -> 11 +orx079 or 1 1 -> 1 + +orx080 or 0 1111111111 -> 111111111 +orx081 or 0 111111111 -> 111111111 +orx082 or 0 11111111 -> 11111111 +orx083 or 0 1111111 -> 1111111 +orx084 or 0 111111 -> 111111 +orx085 or 0 11111 -> 11111 +orx086 or 0 1111 -> 1111 +orx087 or 0 111 -> 111 +orx088 or 0 11 -> 11 +orx089 or 0 1 -> 1 + +orx090 or 011111111 111101111 -> 111111111 +orx091 or 101111111 111101111 -> 111111111 +orx092 or 110111111 111101111 -> 111111111 +orx093 or 111011111 111101111 -> 111111111 +orx094 or 111101111 111101111 -> 111101111 +orx095 or 111110111 111101111 -> 111111111 +orx096 or 111111011 111101111 -> 111111111 +orx097 or 111111101 111101111 -> 111111111 +orx098 or 111111110 111101111 -> 111111111 + +orx100 or 111101111 011111111 -> 111111111 +orx101 or 111101111 101111111 -> 111111111 +orx102 or 111101111 110111111 -> 111111111 +orx103 or 111101111 111011111 -> 111111111 +orx104 or 111101111 111101111 -> 111101111 +orx105 or 111101111 111110111 -> 111111111 +orx106 or 111101111 111111011 -> 111111111 +orx107 or 111101111 111111101 -> 111111111 +orx108 or 111101111 111111110 -> 111111111 + +-- non-0/1 should not be accepted, nor should signs +orx220 or 111111112 111111111 -> NaN Invalid_operation +orx221 or 333333333 333333333 -> NaN Invalid_operation +orx222 or 555555555 555555555 -> NaN Invalid_operation +orx223 or 777777777 777777777 -> NaN Invalid_operation +orx224 or 999999999 999999999 -> NaN Invalid_operation +orx225 or 222222222 999999999 -> NaN Invalid_operation +orx226 or 444444444 999999999 -> NaN Invalid_operation +orx227 or 666666666 999999999 -> NaN Invalid_operation +orx228 or 888888888 999999999 -> NaN Invalid_operation +orx229 or 999999999 222222222 -> NaN Invalid_operation +orx230 or 999999999 444444444 -> NaN Invalid_operation +orx231 or 999999999 666666666 -> NaN Invalid_operation +orx232 or 999999999 888888888 -> NaN Invalid_operation +-- a few randoms +orx240 or 567468689 -934981942 -> NaN Invalid_operation +orx241 or 567367689 934981942 -> NaN Invalid_operation +orx242 or -631917772 -706014634 -> NaN Invalid_operation +orx243 or -756253257 138579234 -> NaN Invalid_operation +orx244 or 835590149 567435400 -> NaN Invalid_operation +-- test MSD +orx250 or 200000000 100000000 -> NaN Invalid_operation +orx251 or 700000000 100000000 -> NaN Invalid_operation +orx252 or 800000000 100000000 -> NaN Invalid_operation +orx253 or 900000000 100000000 -> NaN Invalid_operation +orx254 or 200000000 000000000 -> NaN Invalid_operation +orx255 or 700000000 000000000 -> NaN Invalid_operation +orx256 or 800000000 000000000 -> NaN Invalid_operation +orx257 or 900000000 000000000 -> NaN Invalid_operation +orx258 or 100000000 200000000 -> NaN Invalid_operation +orx259 or 100000000 700000000 -> NaN Invalid_operation +orx260 or 100000000 800000000 -> NaN Invalid_operation +orx261 or 100000000 900000000 -> NaN Invalid_operation +orx262 or 000000000 200000000 -> NaN Invalid_operation +orx263 or 000000000 700000000 -> NaN Invalid_operation +orx264 or 000000000 800000000 -> NaN Invalid_operation +orx265 or 000000000 900000000 -> NaN Invalid_operation +-- test MSD-1 +orx270 or 020000000 100000000 -> NaN Invalid_operation +orx271 or 070100000 100000000 -> NaN Invalid_operation +orx272 or 080010000 100000001 -> NaN Invalid_operation +orx273 or 090001000 100000010 -> NaN Invalid_operation +orx274 or 100000100 020010100 -> NaN Invalid_operation +orx275 or 100000000 070001000 -> NaN Invalid_operation +orx276 or 100000010 080010100 -> NaN Invalid_operation +orx277 or 100000000 090000010 -> NaN Invalid_operation +-- test LSD +orx280 or 001000002 100000000 -> NaN Invalid_operation +orx281 or 000000007 100000000 -> NaN Invalid_operation +orx282 or 000000008 100000000 -> NaN Invalid_operation +orx283 or 000000009 100000000 -> NaN Invalid_operation +orx284 or 100000000 000100002 -> NaN Invalid_operation +orx285 or 100100000 001000007 -> NaN Invalid_operation +orx286 or 100010000 010000008 -> NaN Invalid_operation +orx287 or 100001000 100000009 -> NaN Invalid_operation +-- test Middie +orx288 or 001020000 100000000 -> NaN Invalid_operation +orx289 or 000070001 100000000 -> NaN Invalid_operation +orx290 or 000080000 100010000 -> NaN Invalid_operation +orx291 or 000090000 100001000 -> NaN Invalid_operation +orx292 or 100000010 000020100 -> NaN Invalid_operation +orx293 or 100100000 000070010 -> NaN Invalid_operation +orx294 or 100010100 000080001 -> NaN Invalid_operation +orx295 or 100001000 000090000 -> NaN Invalid_operation +-- signs +orx296 or -100001000 -000000000 -> NaN Invalid_operation +orx297 or -100001000 000010000 -> NaN Invalid_operation +orx298 or 100001000 -000000000 -> NaN Invalid_operation +orx299 or 100001000 000011000 -> 100011000 + +-- Nmax, Nmin, Ntiny +orx331 or 2 9.99999999E+999 -> NaN Invalid_operation +orx332 or 3 1E-999 -> NaN Invalid_operation +orx333 or 4 1.00000000E-999 -> NaN Invalid_operation +orx334 or 5 1E-1007 -> NaN Invalid_operation +orx335 or 6 -1E-1007 -> NaN Invalid_operation +orx336 or 7 -1.00000000E-999 -> NaN Invalid_operation +orx337 or 8 -1E-999 -> NaN Invalid_operation +orx338 or 9 -9.99999999E+999 -> NaN Invalid_operation +orx341 or 9.99999999E+999 -18 -> NaN Invalid_operation +orx342 or 1E-999 01 -> NaN Invalid_operation +orx343 or 1.00000000E-999 -18 -> NaN Invalid_operation +orx344 or 1E-1007 18 -> NaN Invalid_operation +orx345 or -1E-1007 -10 -> NaN Invalid_operation +orx346 or -1.00000000E-999 18 -> NaN Invalid_operation +orx347 or -1E-999 10 -> NaN Invalid_operation +orx348 or -9.99999999E+999 -18 -> NaN Invalid_operation + +-- A few other non-integers +orx361 or 1.0 1 -> NaN Invalid_operation +orx362 or 1E+1 1 -> NaN Invalid_operation +orx363 or 0.0 1 -> NaN Invalid_operation +orx364 or 0E+1 1 -> NaN Invalid_operation +orx365 or 9.9 1 -> NaN Invalid_operation +orx366 or 9E+1 1 -> NaN Invalid_operation +orx371 or 0 1.0 -> NaN Invalid_operation +orx372 or 0 1E+1 -> NaN Invalid_operation +orx373 or 0 0.0 -> NaN Invalid_operation +orx374 or 0 0E+1 -> NaN Invalid_operation +orx375 or 0 9.9 -> NaN Invalid_operation +orx376 or 0 9E+1 -> NaN Invalid_operation + +-- All Specials are in error +orx780 or -Inf -Inf -> NaN Invalid_operation +orx781 or -Inf -1000 -> NaN Invalid_operation +orx782 or -Inf -1 -> NaN Invalid_operation +orx783 or -Inf -0 -> NaN Invalid_operation +orx784 or -Inf 0 -> NaN Invalid_operation +orx785 or -Inf 1 -> NaN Invalid_operation +orx786 or -Inf 1000 -> NaN Invalid_operation +orx787 or -1000 -Inf -> NaN Invalid_operation +orx788 or -Inf -Inf -> NaN Invalid_operation +orx789 or -1 -Inf -> NaN Invalid_operation +orx790 or -0 -Inf -> NaN Invalid_operation +orx791 or 0 -Inf -> NaN Invalid_operation +orx792 or 1 -Inf -> NaN Invalid_operation +orx793 or 1000 -Inf -> NaN Invalid_operation +orx794 or Inf -Inf -> NaN Invalid_operation + +orx800 or Inf -Inf -> NaN Invalid_operation +orx801 or Inf -1000 -> NaN Invalid_operation +orx802 or Inf -1 -> NaN Invalid_operation +orx803 or Inf -0 -> NaN Invalid_operation +orx804 or Inf 0 -> NaN Invalid_operation +orx805 or Inf 1 -> NaN Invalid_operation +orx806 or Inf 1000 -> NaN Invalid_operation +orx807 or Inf Inf -> NaN Invalid_operation +orx808 or -1000 Inf -> NaN Invalid_operation +orx809 or -Inf Inf -> NaN Invalid_operation +orx810 or -1 Inf -> NaN Invalid_operation +orx811 or -0 Inf -> NaN Invalid_operation +orx812 or 0 Inf -> NaN Invalid_operation +orx813 or 1 Inf -> NaN Invalid_operation +orx814 or 1000 Inf -> NaN Invalid_operation +orx815 or Inf Inf -> NaN Invalid_operation + +orx821 or NaN -Inf -> NaN Invalid_operation +orx822 or NaN -1000 -> NaN Invalid_operation +orx823 or NaN -1 -> NaN Invalid_operation +orx824 or NaN -0 -> NaN Invalid_operation +orx825 or NaN 0 -> NaN Invalid_operation +orx826 or NaN 1 -> NaN Invalid_operation +orx827 or NaN 1000 -> NaN Invalid_operation +orx828 or NaN Inf -> NaN Invalid_operation +orx829 or NaN NaN -> NaN Invalid_operation +orx830 or -Inf NaN -> NaN Invalid_operation +orx831 or -1000 NaN -> NaN Invalid_operation +orx832 or -1 NaN -> NaN Invalid_operation +orx833 or -0 NaN -> NaN Invalid_operation +orx834 or 0 NaN -> NaN Invalid_operation +orx835 or 1 NaN -> NaN Invalid_operation +orx836 or 1000 NaN -> NaN Invalid_operation +orx837 or Inf NaN -> NaN Invalid_operation + +orx841 or sNaN -Inf -> NaN Invalid_operation +orx842 or sNaN -1000 -> NaN Invalid_operation +orx843 or sNaN -1 -> NaN Invalid_operation +orx844 or sNaN -0 -> NaN Invalid_operation +orx845 or sNaN 0 -> NaN Invalid_operation +orx846 or sNaN 1 -> NaN Invalid_operation +orx847 or sNaN 1000 -> NaN Invalid_operation +orx848 or sNaN NaN -> NaN Invalid_operation +orx849 or sNaN sNaN -> NaN Invalid_operation +orx850 or NaN sNaN -> NaN Invalid_operation +orx851 or -Inf sNaN -> NaN Invalid_operation +orx852 or -1000 sNaN -> NaN Invalid_operation +orx853 or -1 sNaN -> NaN Invalid_operation +orx854 or -0 sNaN -> NaN Invalid_operation +orx855 or 0 sNaN -> NaN Invalid_operation +orx856 or 1 sNaN -> NaN Invalid_operation +orx857 or 1000 sNaN -> NaN Invalid_operation +orx858 or Inf sNaN -> NaN Invalid_operation +orx859 or NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +orx861 or NaN1 -Inf -> NaN Invalid_operation +orx862 or +NaN2 -1000 -> NaN Invalid_operation +orx863 or NaN3 1000 -> NaN Invalid_operation +orx864 or NaN4 Inf -> NaN Invalid_operation +orx865 or NaN5 +NaN6 -> NaN Invalid_operation +orx866 or -Inf NaN7 -> NaN Invalid_operation +orx867 or -1000 NaN8 -> NaN Invalid_operation +orx868 or 1000 NaN9 -> NaN Invalid_operation +orx869 or Inf +NaN10 -> NaN Invalid_operation +orx871 or sNaN11 -Inf -> NaN Invalid_operation +orx872 or sNaN12 -1000 -> NaN Invalid_operation +orx873 or sNaN13 1000 -> NaN Invalid_operation +orx874 or sNaN14 NaN17 -> NaN Invalid_operation +orx875 or sNaN15 sNaN18 -> NaN Invalid_operation +orx876 or NaN16 sNaN19 -> NaN Invalid_operation +orx877 or -Inf +sNaN20 -> NaN Invalid_operation +orx878 or -1000 sNaN21 -> NaN Invalid_operation +orx879 or 1000 sNaN22 -> NaN Invalid_operation +orx880 or Inf sNaN23 -> NaN Invalid_operation +orx881 or +NaN25 +sNaN24 -> NaN Invalid_operation +orx882 or -NaN26 NaN28 -> NaN Invalid_operation +orx883 or -sNaN27 sNaN29 -> NaN Invalid_operation +orx884 or 1000 -NaN30 -> NaN Invalid_operation +orx885 or 1000 -sNaN31 -> NaN Invalid_operation Modified: python/branches/release25-maint/Lib/test/decimaltestdata/plus.decTest ============================================================================== --- python/branches/release25-maint/Lib/test/decimaltestdata/plus.decTest (original) +++ python/branches/release25-maint/Lib/test/decimaltestdata/plus.decTest Tue Jan 8 17:20:31 2008 @@ -1,6 +1,6 @@ ------------------------------------------------------------------------ -- plus.decTest -- decimal monadic addition -- --- Copyright (c) IBM Corporation, 1981, 2004. All rights reserved. -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- ------------------------------------------------------------------------ -- Please see the document "General Decimal Arithmetic Testcases" -- -- at http://www2.hursley.ibm.com/decimal for the description of -- @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc at uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.39 +version: 2.57 -- This set of tests primarily tests the existence of the operator. -- Addition and rounding, and most overflows, are tested elsewhere. @@ -138,9 +138,9 @@ plux215 plus 0.999E-999 -> 1.00E-999 Inexact Rounded Subnormal Underflow plux216 plus 0.099E-999 -> 1.0E-1000 Inexact Rounded Subnormal Underflow plux217 plus 0.009E-999 -> 1E-1001 Inexact Rounded Subnormal Underflow -plux218 plus 0.001E-999 -> 0E-1001 Inexact Rounded Subnormal Underflow -plux219 plus 0.0009E-999 -> 0E-1001 Inexact Rounded Subnormal Underflow -plux220 plus 0.0001E-999 -> 0E-1001 Inexact Rounded Subnormal Underflow +plux218 plus 0.001E-999 -> 0E-1001 Inexact Rounded Subnormal Underflow Clamped +plux219 plus 0.0009E-999 -> 0E-1001 Inexact Rounded Subnormal Underflow Clamped +plux220 plus 0.0001E-999 -> 0E-1001 Inexact Rounded Subnormal Underflow Clamped plux230 plus -1.00E-999 -> -1.00E-999 plux231 plus -0.1E-999 -> -1E-1000 Subnormal @@ -151,9 +151,23 @@ plux235 plus -0.999E-999 -> -1.00E-999 Inexact Rounded Subnormal Underflow plux236 plus -0.099E-999 -> -1.0E-1000 Inexact Rounded Subnormal Underflow plux237 plus -0.009E-999 -> -1E-1001 Inexact Rounded Subnormal Underflow -plux238 plus -0.001E-999 -> -0E-1001 Inexact Rounded Subnormal Underflow -plux239 plus -0.0009E-999 -> -0E-1001 Inexact Rounded Subnormal Underflow -plux240 plus -0.0001E-999 -> -0E-1001 Inexact Rounded Subnormal Underflow +plux238 plus -0.001E-999 -> -0E-1001 Inexact Rounded Subnormal Underflow Clamped +plux239 plus -0.0009E-999 -> -0E-1001 Inexact Rounded Subnormal Underflow Clamped +plux240 plus -0.0001E-999 -> -0E-1001 Inexact Rounded Subnormal Underflow Clamped + +-- subnormals clamped to 0-Etiny +precision: 16 +maxExponent: 384 +minExponent: -383 +plux251 plus 7E-398 -> 7E-398 Subnormal +plux252 plus 0E-398 -> 0E-398 +plux253 plus 7E-399 -> 1E-398 Subnormal Underflow Inexact Rounded +plux254 plus 4E-399 -> 0E-398 Clamped Subnormal Underflow Inexact Rounded +plux255 plus 7E-400 -> 0E-398 Clamped Subnormal Underflow Inexact Rounded +plux256 plus 7E-401 -> 0E-398 Clamped Subnormal Underflow Inexact Rounded +plux257 plus 0E-399 -> 0E-398 Clamped +plux258 plus 0E-400 -> 0E-398 Clamped +plux259 plus 0E-401 -> 0E-398 Clamped -- long operand checks maxexponent: 999 Modified: python/branches/release25-maint/Lib/test/decimaltestdata/power.decTest ============================================================================== --- python/branches/release25-maint/Lib/test/decimaltestdata/power.decTest (original) +++ python/branches/release25-maint/Lib/test/decimaltestdata/power.decTest Tue Jan 8 17:20:31 2008 @@ -1,6 +1,6 @@ ----------------------------------------------------------------------- --- power.decTest -- decimal exponentiation -- --- Copyright (c) IBM Corporation, 1981, 2003. All rights reserved. -- +------------------------------------------------------------------------ +-- power.decTest -- decimal exponentiation [power(x, y)] -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- ------------------------------------------------------------------------ -- Please see the document "General Decimal Arithmetic Testcases" -- -- at http://www2.hursley.ibm.com/decimal for the description of -- @@ -17,17 +17,17 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc at uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.39 +version: 2.57 --- This set of testcases tests raising numbers to an integer power only. --- If arbitrary powers were supported, 1 ulp differences would be --- permitted. +-- In addition to the power operator testcases here, see also the file +-- powersqrt.decTest which includes all the tests from +-- squareroot.decTest implemented using power(x, 0.5) extended: 1 -precision: 9 -rounding: half_up -maxExponent: 999 -minexponent: -999 +precision: 16 +rounding: half_even +maxExponent: 384 +minExponent: -383 -- base checks. Note 0**0 is an error. powx001 power '0' '0' -> NaN Invalid_operation @@ -52,51 +52,54 @@ powx022 power '2' '12' -> '4096' powx023 power '2' '15' -> '32768' powx024 power '2' '16' -> '65536' -powx025 power '2' '31' -> '2.14748365E+9' Inexact Rounded +powx025 power '2' '31' -> '2147483648' +-- NB 0 not stripped in next +powx026 power '2' '32' -> '4294967296' + +precision: 9 +powx027 power '2' '31' -> '2.14748365E+9' Inexact Rounded -- NB 0 not stripped in next -powx026 power '2' '32' -> '4.29496730E+9' Inexact Rounded +powx028 power '2' '32' -> '4.29496730E+9' Inexact Rounded precision: 10 -powx027 power '2' '31' -> '2147483648' -powx028 power '2' '32' -> '4294967296' +powx029 power '2' '31' -> '2147483648' +powx030 power '2' '32' -> '4294967296' precision: 9 -powx030 power '3' '2' -> 9 -powx031 power '4' '2' -> 16 -powx032 power '5' '2' -> 25 -powx033 power '6' '2' -> 36 -powx034 power '7' '2' -> 49 -powx035 power '8' '2' -> 64 -powx036 power '9' '2' -> 81 -powx037 power '10' '2' -> 100 -powx038 power '11' '2' -> 121 -powx039 power '12' '2' -> 144 - -powx040 power '3' '3' -> 27 -powx041 power '4' '3' -> 64 -powx042 power '5' '3' -> 125 -powx043 power '6' '3' -> 216 -powx044 power '7' '3' -> 343 - -powx050 power '10' '0' -> 1 -powx051 power '10' '1' -> 10 -powx052 power '10' '2' -> 100 -powx053 power '10' '3' -> 1000 -powx054 power '10' '4' -> 10000 -powx055 power '10' '5' -> 100000 -powx056 power '10' '6' -> 1000000 -powx057 power '10' '7' -> 10000000 -powx058 power '10' '8' -> 100000000 -powx059 power '10' '9' -> 1.00000000E+9 Rounded -powx060 power '10' '22' -> 1.00000000E+22 Rounded -powx061 power '10' '77' -> 1.00000000E+77 Rounded -powx062 power '10' '99' -> 1.00000000E+99 Rounded - -maxexponent: 999999999 -minexponent: -999999999 -powx063 power '10' '999999999' -> '1.00000000E+999999999' Rounded -powx064 power '10' '999999998' -> '1.00000000E+999999998' Rounded -powx065 power '10' '999999997' -> '1.00000000E+999999997' Rounded -powx066 power '10' '333333333' -> '1.00000000E+333333333' Rounded +powx031 power '3' '2' -> 9 +powx032 power '4' '2' -> 16 +powx033 power '5' '2' -> 25 +powx034 power '6' '2' -> 36 +powx035 power '7' '2' -> 49 +powx036 power '8' '2' -> 64 +powx037 power '9' '2' -> 81 +powx038 power '10' '2' -> 100 +powx039 power '11' '2' -> 121 +powx040 power '12' '2' -> 144 + +powx041 power '3' '3' -> 27 +powx042 power '4' '3' -> 64 +powx043 power '5' '3' -> 125 +powx044 power '6' '3' -> 216 +powx045 power '7' '3' -> 343 +powx047 power '-3' '3' -> -27 +powx048 power '-4' '3' -> -64 +powx049 power '-5' '3' -> -125 +powx050 power '-6' '3' -> -216 +powx051 power '-7' '3' -> -343 + +powx052 power '10' '0' -> 1 +powx053 power '10' '1' -> 10 +powx054 power '10' '2' -> 100 +powx055 power '10' '3' -> 1000 +powx056 power '10' '4' -> 10000 +powx057 power '10' '5' -> 100000 +powx058 power '10' '6' -> 1000000 +powx059 power '10' '7' -> 10000000 +powx060 power '10' '8' -> 100000000 +powx061 power '10' '9' -> 1.00000000E+9 Rounded +powx062 power '10' '22' -> 1.00000000E+22 Rounded +powx063 power '10' '77' -> 1.00000000E+77 Rounded +powx064 power '10' '99' -> 1.00000000E+99 Rounded powx070 power '0.3' '0' -> '1' powx071 power '0.3' '1' -> '0.3' @@ -127,71 +130,52 @@ powx095 power 101 7 -> 1.07213535E+14 Inexact Rounded -- negative powers -powx101 power '2' '-1' -> 0.5 -powx102 power '2' '-2' -> 0.25 -powx103 power '2' '-4' -> 0.0625 -powx104 power '2' '-8' -> 0.00390625 -powx105 power '2' '-16' -> 0.0000152587891 Inexact Rounded -powx106 power '2' '-32' -> 2.32830644E-10 Inexact Rounded -powx108 power '2' '-64' -> 5.42101086E-20 Inexact Rounded -powx110 power '10' '-8' -> 1E-8 -powx111 power '10' '-7' -> 1E-7 -powx112 power '10' '-6' -> 0.000001 -powx113 power '10' '-5' -> 0.00001 -powx114 power '10' '-4' -> 0.0001 -powx115 power '10' '-3' -> 0.001 -powx116 power '10' '-2' -> 0.01 -powx117 power '10' '-1' -> 0.1 - -powx118 power '10' '-333333333' -> 1E-333333333 -powx119 power '10' '-999999998' -> 1E-999999998 -powx120 power '10' '-999999999' -> 1E-999999999 -powx121 power '10' '-77' -> '1E-77' -powx122 power '10' '-22' -> '1E-22' - -powx123 power '2' '-1' -> '0.5' -powx124 power '2' '-2' -> '0.25' -powx125 power '2' '-4' -> '0.0625' -powx126 power '0' '-1' -> Infinity Division_by_zero -powx127 power '0' '-2' -> Infinity Division_by_zero -powx128 power -0 '-1' -> -Infinity Division_by_zero -powx129 power -0 '-2' -> Infinity Division_by_zero - --- out-of-range edge cases -powx181 power '7' '999999998' -> 2.10892313E+845098038 Inexact Rounded -powx182 power '7' '999999999' -> 1.47624619E+845098039 Inexact Rounded -powx183 power '7' '1000000000' -> NaN Invalid_operation -powx184 power '7' '1000000001' -> NaN Invalid_operation -powx185 power '7' '10000000000' -> NaN Invalid_operation -powx186 power '7' '-1000000001' -> NaN Invalid_operation -powx187 power '7' '-1000000000' -> NaN Invalid_operation -powx189 power '7' '-999999999' -> 6.77393787E-845098040 Inexact Rounded -powx190 power '7' '-999999998' -> 4.74175651E-845098039 Inexact Rounded - --- some baddies [more below] -powx191 power '2' '2.000001' -> NaN Invalid_operation -powx192 power '2' '2.00000000' -> 4 -powx193 power '2' '2.000000001' -> NaN Invalid_operation -powx194 power '2' '2.0000000001' -> NaN Invalid_operation +powx099 power '1' '-1' -> 1 +powx100 power '3' '-1' -> 0.333333333 Inexact Rounded +powx101 power '2' '-1' -> 0.5 +powx102 power '2' '-2' -> 0.25 +powx103 power '2' '-4' -> 0.0625 +powx104 power '2' '-8' -> 0.00390625 +powx105 power '2' '-16' -> 0.0000152587891 Inexact Rounded +powx106 power '2' '-32' -> 2.32830644E-10 Inexact Rounded +powx108 power '2' '-64' -> 5.42101086E-20 Inexact Rounded +powx110 power '10' '-8' -> 1E-8 +powx111 power '10' '-7' -> 1E-7 +powx112 power '10' '-6' -> 0.000001 +powx113 power '10' '-5' -> 0.00001 +powx114 power '10' '-4' -> 0.0001 +powx115 power '10' '-3' -> 0.001 +powx116 power '10' '-2' -> 0.01 +powx117 power '10' '-1' -> 0.1 +powx121 power '10' '-77' -> '1E-77' +powx122 power '10' '-22' -> '1E-22' + +powx123 power '2' '-1' -> '0.5' +powx124 power '2' '-2' -> '0.25' +powx125 power '2' '-4' -> '0.0625' + +powx126 power '0' '-1' -> Infinity +powx127 power '0' '-2' -> Infinity +powx128 power -0 '-1' -> -Infinity +powx129 power -0 '-2' -> Infinity -- "0.5" tests from original Rexx diagnostics [loop unrolled] -powx200 power 0.5 0 -> 1 -powx201 power 0.5 1 -> 0.5 -powx202 power 0.5 2 -> 0.25 -powx203 power 0.5 3 -> 0.125 -powx204 power 0.5 4 -> 0.0625 -powx205 power 0.5 5 -> 0.03125 -powx206 power 0.5 6 -> 0.015625 -powx207 power 0.5 7 -> 0.0078125 -powx208 power 0.5 8 -> 0.00390625 -powx209 power 0.5 9 -> 0.001953125 -powx210 power 0.5 10 -> 0.0009765625 +powx200 power 0.5 0 -> 1 +powx201 power 0.5 1 -> 0.5 +powx202 power 0.5 2 -> 0.25 +powx203 power 0.5 3 -> 0.125 +powx204 power 0.5 4 -> 0.0625 +powx205 power 0.5 5 -> 0.03125 +powx206 power 0.5 6 -> 0.015625 +powx207 power 0.5 7 -> 0.0078125 +powx208 power 0.5 8 -> 0.00390625 +powx209 power 0.5 9 -> 0.001953125 +powx210 power 0.5 10 -> 0.0009765625 + +powx211 power 1 100000000 -> 1 +powx212 power 1 999999998 -> 1 +powx213 power 1 999999999 -> 1 --- A (rare) case where the last digit is not within 0.5 ULP -precision: 9 -powx215 power "-21971575.0E+31454441" "-7" -> "-4.04549503E-220181139" Inexact Rounded -precision: 20 -powx216 power "-21971575.0E+31454441" "-7" -> "-4.0454950249324891788E-220181139" Inexact Rounded -- The Vienna case. Checks both setup and 1/acc working precision -- Modified 1998.12.14 as RHS no longer rounded before use (must fit) @@ -201,185 +185,64 @@ -- Modified 2002.10.06 -- finally, no input rounding -- With input rounding, result would be 8.74E-2226 precision: 3 +maxexponent: 5000 +minexponent: -5000 powx219 power '123456789E+10' '-1.23000e+2' -> '5.54E-2226' Inexact Rounded --- whole number checks -precision: 9 -powx221 power 1 1234 -> 1 -precision: 4 -powx222 power 1 1234 -> 1 -precision: 3 -powx223 power 1 1234 -> 1 -powx224 power 1 12.34e+2 -> 1 -powx225 power 1 12.3 -> NaN Invalid_operation -powx226 power 1 12.0 -> 1 -powx227 power 1 1.01 -> NaN Invalid_operation -powx228 power 2 1.00 -> 2 -powx229 power 2 2.00 -> 4 -precision: 9 -powx230 power 1 1.0001 -> NaN Invalid_operation -powx231 power 1 1.0000001 -> NaN Invalid_operation -powx232 power 1 1.0000000001 -> NaN Invalid_operation -powx233 power 1 1.0000000000001 -> NaN Invalid_operation -precision: 5 -powx234 power 1 1.0001 -> NaN Invalid_operation -powx235 power 1 1.0000001 -> NaN Invalid_operation -powx236 power 1 1.0000000001 -> NaN Invalid_operation -powx237 power 1 1.0000000000001 -> NaN Invalid_operation -powx238 power 1 1.0000000000001 -> NaN Invalid_operation - -maxexponent: 999999999 -minexponent: -999999999 -powx239 power 1 5.67E-987654321 -> NaN Invalid_operation - -powx240 power 1 100000000 -> 1 -powx241 power 1 999999998 -> 1 -powx242 power 1 999999999 -> 1 -powx243 power 1 1000000000 -> NaN Invalid_operation -powx244 power 1 9999999999 -> NaN Invalid_operation - --- Checks for 'Too much precision needed' --- For x^12, digits+elength+1 = digits+3 -precision: 999999999 -powx249 add 1 1 -> 2 -- check basic operation at this precision -powx250 power 2 12 -> Infinity Overflow -precision: 999999998 -powx251 power 2 12 -> Infinity Overflow -precision: 999999997 -powx252 power 2 12 -> Infinity Overflow -precision: 999999996 -powx253 power 2 12 -> 4096 -precision: 999999995 -powx254 power 2 12 -> 4096 - -- zeros maxexponent: +96 minexponent: -95 precision: 7 -powx260 power 0E-34 3 -> 0E-101 Clamped -powx261 power 0E-33 3 -> 0E-99 -powx262 power 0E-32 3 -> 0E-96 -powx263 power 0E-30 3 -> 0E-90 -powx264 power 0E-10 3 -> 0E-30 -powx265 power 0E-1 3 -> 0.000 -powx266 power 0E+0 3 -> 0 -powx267 power 0 3 -> 0 -powx268 power 0E+1 3 -> 0E+3 -powx269 power 0E+10 3 -> 0E+30 -powx270 power 0E+30 3 -> 0E+90 -powx271 power 0E+32 3 -> 0E+96 -powx272 power 0E+33 3 -> 0E+96 Clamped - --- overflow and underflow tests -maxexponent: 999999999 -minexponent: -999999999 -precision: 9 -powx280 power 9 999999999 -> 3.05550054E+954242508 Inexact Rounded -powx281 power 10 999999999 -> 1.00000000E+999999999 Rounded -powx282 power 10.0001 999999999 -> Infinity Overflow Inexact Rounded -powx283 power 10.1 999999999 -> Infinity Overflow Inexact Rounded -powx284 power 11 999999999 -> Infinity Overflow Inexact Rounded -powx285 power 12 999999999 -> Infinity Overflow Inexact Rounded -powx286 power 999 999999999 -> Infinity Overflow Inexact Rounded -powx287 power 999999 999999999 -> Infinity Overflow Inexact Rounded -powx288 power 999999999 999999999 -> Infinity Overflow Inexact Rounded -powx289 power 9.9E999999999 999999999 -> Infinity Overflow Inexact Rounded - -powx290 power 0.5 999999999 -> 4.33559594E-301029996 Inexact Rounded -powx291 power 0.1 999999999 -> 1E-999999999 -- unrounded -powx292 power 0.09 999999999 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped -powx293 power 0.05 999999999 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped -powx294 power 0.01 999999999 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped -powx295 power 0.0001 999999999 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped -powx297 power 0.0000001 999999999 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped -powx298 power 0.0000000001 999999999 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped -powx299 power 1E-999999999 999999999 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped - -powx310 power -9 999999999 -> -3.05550054E+954242508 Inexact Rounded -powx311 power -10 999999999 -> -1.00000000E+999999999 Rounded -powx312 power -10.0001 999999999 -> -Infinity Overflow Inexact Rounded -powx313 power -10.1 999999999 -> -Infinity Overflow Inexact Rounded -powx314 power -11 999999999 -> -Infinity Overflow Inexact Rounded -powx315 power -12 999999999 -> -Infinity Overflow Inexact Rounded -powx316 power -999 999999999 -> -Infinity Overflow Inexact Rounded -powx317 power -999999 999999999 -> -Infinity Overflow Inexact Rounded -powx318 power -999999999 999999999 -> -Infinity Overflow Inexact Rounded -powx319 power -9.9E999999999 999999999 -> -Infinity Overflow Inexact Rounded - -powx320 power -0.5 999999999 -> -4.33559594E-301029996 Inexact Rounded -powx321 power -0.1 999999999 -> -1E-999999999 -powx322 power -0.09 999999999 -> -0E-1000000007 Underflow Subnormal Inexact Rounded Clamped -powx323 power -0.05 999999999 -> -0E-1000000007 Underflow Subnormal Inexact Rounded Clamped -powx324 power -0.01 999999999 -> -0E-1000000007 Underflow Subnormal Inexact Rounded Clamped -powx325 power -0.0001 999999999 -> -0E-1000000007 Underflow Subnormal Inexact Rounded Clamped -powx327 power -0.0000001 999999999 -> -0E-1000000007 Underflow Subnormal Inexact Rounded Clamped -powx328 power -0.0000000001 999999999 -> -0E-1000000007 Underflow Subnormal Inexact Rounded Clamped -powx329 power -1E-999999999 999999999 -> -0E-1000000007 Underflow Subnormal Inexact Rounded Clamped +powx223 power 0E-30 3 -> 0 +powx224 power 0E-10 3 -> 0 +powx225 power 0E-1 3 -> 0 +powx226 power 0E+0 3 -> 0 +powx227 power 0 3 -> 0 +powx228 power 0E+1 3 -> 0 +powx229 power 0E+10 3 -> 0 +powx230 power 0E+30 3 -> 0 +powx231 power 3 0E-30 -> 1 +powx232 power 3 0E-10 -> 1 +powx233 power 3 0E-1 -> 1 +powx234 power 3 0E+0 -> 1 +powx235 power 3 0 -> 1 +powx236 power 3 0E+1 -> 1 +powx237 power 3 0E+10 -> 1 +powx238 power 3 0E+30 -> 1 +powx239 power 0E-30 -3 -> Infinity +powx240 power 0E-10 -3 -> Infinity +powx241 power 0E-1 -3 -> Infinity +powx242 power 0E+0 -3 -> Infinity +powx243 power 0 -3 -> Infinity +powx244 power 0E+1 -3 -> Infinity +powx245 power 0E+10 -3 -> Infinity +powx246 power 0E+30 -3 -> Infinity +powx247 power -3 0E-30 -> 1 +powx248 power -3 0E-10 -> 1 +powx249 power -3 0E-1 -> 1 +powx250 power -3 0E+0 -> 1 +powx251 power -3 0 -> 1 +powx252 power -3 0E+1 -> 1 +powx253 power -3 0E+10 -> 1 +powx254 power -3 0E+30 -> 1 --- note no trim of next result -powx330 power -9 999999998 -> 3.39500060E+954242507 Inexact Rounded -powx331 power -10 999999998 -> 1.00000000E+999999998 Rounded -powx332 power -10.0001 999999998 -> Infinity Overflow Inexact Rounded -powx333 power -10.1 999999998 -> Infinity Overflow Inexact Rounded -powx334 power -11 999999998 -> Infinity Overflow Inexact Rounded -powx335 power -12 999999998 -> Infinity Overflow Inexact Rounded -powx336 power -999 999999998 -> Infinity Overflow Inexact Rounded -powx337 power -999999 999999998 -> Infinity Overflow Inexact Rounded -powx338 power -999999999 999999998 -> Infinity Overflow Inexact Rounded -powx339 power -9.9E999999999 999999998 -> Infinity Overflow Inexact Rounded - -powx340 power -0.5 999999998 -> 8.67119187E-301029996 Inexact Rounded -powx341 power -0.1 999999998 -> 1E-999999998 -- NB exact unrounded -powx342 power -0.09 999999998 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped -powx343 power -0.05 999999998 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped -powx344 power -0.01 999999998 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped -powx345 power -0.0001 999999998 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped -powx347 power -0.0000001 999999998 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped -powx348 power -0.0000000001 999999998 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped -powx349 power -1E-999999999 999999998 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped - --- some subnormals +-- a few lhs negatives precision: 9 --- [precision is 9, so smallest exponent is -1000000007 -powx350 power 1e-1 500000000 -> 1E-500000000 -powx351 power 1e-2 999999999 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped -powx352 power 1e-2 500000000 -> 1E-1000000000 Subnormal -powx353 power 1e-2 500000001 -> 1E-1000000002 Subnormal -powx354 power 1e-2 500000002 -> 1E-1000000004 Subnormal -powx355 power 1e-2 500000003 -> 1E-1000000006 Subnormal -powx356 power 1e-2 500000004 -> 0E-1000000007 Underflow Subnormal Inexact Rounded - -powx360 power 0.010001 500000000 -> 4.34941988E-999978287 Inexact Rounded -powx361 power 0.010000001 500000000 -> 5.18469257E-999999979 Inexact Rounded -powx362 power 0.010000001 500000001 -> 5.18469309E-999999981 Inexact Rounded -powx363 power 0.0100000009 500000000 -> 3.49342003E-999999981 Inexact Rounded -powx364 power 0.0100000001 500000000 -> 1.48413155E-999999998 Inexact Rounded -powx365 power 0.01 500000000 -> 1E-1000000000 Subnormal -powx366 power 0.0099999999 500000000 -> 6.7379E-1000000003 Underflow Subnormal Inexact Rounded -powx367 power 0.0099999998 500000000 -> 4.54E-1000000005 Underflow Subnormal Inexact Rounded -powx368 power 0.0099999997 500000000 -> 3E-1000000007 Underflow Subnormal Inexact Rounded -powx369 power 0.0099999996 500000000 -> 0E-1000000007 Underflow Subnormal Inexact Rounded -powx370 power 0.009 500000000 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped - --- 1/subnormal -> overflow -powx371 power 1e-1 -500000000 -> 1E+500000000 -powx372 power 1e-2 -999999999 -> Infinity Overflow Inexact Rounded -powx373 power 1e-2 -500000000 -> Infinity Overflow Inexact Rounded -powx374 power 1e-2 -500000001 -> Infinity Overflow Inexact Rounded -powx375 power 1e-2 -500000002 -> Infinity Overflow Inexact Rounded -powx376 power 1e-2 -500000003 -> Infinity Overflow Inexact Rounded -powx377 power 1e-2 -500000004 -> Infinity Overflow Inexact Rounded - -powx381 power 0.010001 -500000000 -> 2.29915719E+999978286 Inexact Rounded -powx382 power 0.010000001 -500000000 -> 1.92875467E+999999978 Inexact Rounded -powx383 power 0.010000001 -500000001 -> 1.92875448E+999999980 Inexact Rounded -powx384 power 0.0100000009 -500000000 -> 2.86252438E+999999980 Inexact Rounded -powx385 power 0.0100000001 -500000000 -> 6.73794717E+999999997 Inexact Rounded -powx386 power 0.01 -500000000 -> Infinity Overflow Inexact Rounded -powx387 power 0.009999 -500000000 -> Infinity Overflow Inexact Rounded - --- negative power giving subnormal -powx388 power 100.000001 -500000000 -> 6.7379E-1000000003 Underflow Subnormal Inexact Rounded +maxExponent: 999 +minexponent: -999 +powx260 power -10 '0' -> 1 +powx261 power -10 '1' -> -10 +powx262 power -10 '2' -> 100 +powx263 power -10 '3' -> -1000 +powx264 power -10 '4' -> 10000 +powx265 power -10 '5' -> -100000 +powx266 power -10 '6' -> 1000000 +powx267 power -10 '7' -> -10000000 +powx268 power -10 '8' -> 100000000 +powx269 power -10 '9' -> -1.00000000E+9 Rounded +powx270 power -10 '22' -> 1.00000000E+22 Rounded +powx271 power -10 '77' -> -1.00000000E+77 Rounded +powx272 power -10 '99' -> -1.00000000E+99 Rounded -- some more edge cases precision: 15 @@ -389,8 +252,9 @@ powx392 power 0.099 999 -> 4.360732062E-1004 Underflow Subnormal Inexact Rounded powx393 power 0.098 999 -> 1.71731E-1008 Underflow Subnormal Inexact Rounded powx394 power 0.097 999 -> 6E-1013 Underflow Subnormal Inexact Rounded -powx395 power 0.096 999 -> 0E-1013 Underflow Subnormal Inexact Rounded +powx395 power 0.096 999 -> 0E-1013 Underflow Subnormal Inexact Rounded Clamped powx396 power 0.01 999 -> 0E-1013 Underflow Subnormal Inexact Rounded Clamped +powx397 power 0.02 100000000 -> 0E-1013 Underflow Subnormal Inexact Rounded Clamped -- multiply tests are here to aid checking and test for consistent handling -- of underflow @@ -399,7 +263,7 @@ minexponent: -999 -- squares -mulx400 multiply 1E-502 1e-502 -> 0E-1003 Subnormal Inexact Underflow Rounded +mulx400 multiply 1E-502 1e-502 -> 0E-1003 Subnormal Inexact Underflow Rounded Clamped mulx401 multiply 1E-501 1e-501 -> 1E-1002 Subnormal mulx402 multiply 2E-501 2e-501 -> 4E-1002 Subnormal mulx403 multiply 4E-501 4e-501 -> 1.6E-1001 Subnormal @@ -407,7 +271,7 @@ mulx405 multiply 30E-501 30e-501 -> 9.00E-1000 Subnormal mulx406 multiply 40E-501 40e-501 -> 1.600E-999 -powx400 power 1E-502 2 -> 0E-1003 Underflow Subnormal Inexact Rounded +powx400 power 1E-502 2 -> 0E-1003 Underflow Subnormal Inexact Rounded Clamped powx401 power 1E-501 2 -> 1E-1002 Subnormal powx402 power 2E-501 2 -> 4E-1002 Subnormal powx403 power 4E-501 2 -> 1.6E-1001 Subnormal @@ -416,7 +280,7 @@ powx406 power 40E-501 2 -> 1.600E-999 -- cubes -mulx410 multiply 1E-670 1e-335 -> 0E-1003 Underflow Subnormal Inexact Rounded +mulx410 multiply 1E-670 1e-335 -> 0E-1003 Underflow Subnormal Inexact Rounded Clamped mulx411 multiply 1E-668 1e-334 -> 1E-1002 Subnormal mulx412 multiply 4E-668 2e-334 -> 8E-1002 Subnormal mulx413 multiply 9E-668 3e-334 -> 2.7E-1001 Subnormal @@ -424,7 +288,7 @@ mulx415 multiply 25E-668 5e-334 -> 1.25E-1000 Subnormal mulx416 multiply 10E-668 100e-334 -> 1.000E-999 -powx410 power 1E-335 3 -> 0E-1003 Underflow Subnormal Inexact Rounded +powx410 power 1E-335 3 -> 0E-1003 Underflow Subnormal Inexact Rounded Clamped powx411 power 1E-334 3 -> 1E-1002 Subnormal powx412 power 2E-334 3 -> 8E-1002 Subnormal powx413 power 3E-334 3 -> 2.7E-1001 Subnormal @@ -442,24 +306,24 @@ powx423 power 2.5E+499 -2 -> 1.6E-999 powx424 power 2.5E+500 -2 -> 1.6E-1001 Subnormal powx425 power 2.5E+501 -2 -> 2E-1003 Underflow Subnormal Inexact Rounded -powx426 power 2.5E+502 -2 -> 0E-1003 Underflow Subnormal Inexact Rounded +powx426 power 2.5E+502 -2 -> 0E-1003 Underflow Subnormal Inexact Rounded Clamped powx427 power 0.25E+499 -2 -> 1.6E-997 powx428 power 0.25E+500 -2 -> 1.6E-999 powx429 power 0.25E+501 -2 -> 1.6E-1001 Subnormal powx430 power 0.25E+502 -2 -> 2E-1003 Underflow Subnormal Inexact Rounded -powx431 power 0.25E+503 -2 -> 0E-1003 Underflow Subnormal Inexact Rounded +powx431 power 0.25E+503 -2 -> 0E-1003 Underflow Subnormal Inexact Rounded Clamped powx432 power 0.04E+499 -2 -> 6.25E-996 powx433 power 0.04E+500 -2 -> 6.25E-998 powx434 power 0.04E+501 -2 -> 6.25E-1000 Subnormal -powx435 power 0.04E+502 -2 -> 6.3E-1002 Underflow Subnormal Inexact Rounded +powx435 power 0.04E+502 -2 -> 6.2E-1002 Underflow Subnormal Inexact Rounded powx436 power 0.04E+503 -2 -> 1E-1003 Underflow Subnormal Inexact Rounded -powx437 power 0.04E+504 -2 -> 0E-1003 Underflow Subnormal Inexact Rounded +powx437 power 0.04E+504 -2 -> 0E-1003 Underflow Subnormal Inexact Rounded Clamped powx441 power 0.04E+334 -3 -> 1.5625E-998 powx442 power 0.04E+335 -3 -> 1.56E-1001 Underflow Subnormal Inexact Rounded -powx443 power 0.04E+336 -3 -> 0E-1003 Underflow Subnormal Inexact Rounded +powx443 power 0.04E+336 -3 -> 0E-1003 Underflow Subnormal Inexact Rounded Clamped powx444 power 0.25E+333 -3 -> 6.4E-998 powx445 power 0.25E+334 -3 -> 6.4E-1001 Subnormal powx446 power 0.25E+335 -3 -> 1E-1003 Underflow Subnormal Inexact Rounded @@ -467,7 +331,7 @@ -- check sign for cubes and a few squares powx448 power -0.04E+334 -3 -> -1.5625E-998 powx449 power -0.04E+335 -3 -> -1.56E-1001 Underflow Subnormal Inexact Rounded -powx450 power -0.04E+336 -3 -> -0E-1003 Underflow Subnormal Inexact Rounded +powx450 power -0.04E+336 -3 -> -0E-1003 Underflow Subnormal Inexact Rounded Clamped powx451 power -0.25E+333 -3 -> -6.4E-998 powx452 power -0.25E+334 -3 -> -6.4E-1001 Subnormal powx453 power -0.25E+335 -3 -> -1E-1003 Underflow Subnormal Inexact Rounded @@ -475,7 +339,7 @@ powx455 power -0.04E+499 -2 -> 6.25E-996 powx456 power -0.04E+500 -2 -> 6.25E-998 powx457 power -0.04E+501 -2 -> 6.25E-1000 Subnormal -powx458 power -0.04E+502 -2 -> 6.3E-1002 Underflow Subnormal Inexact Rounded +powx458 power -0.04E+502 -2 -> 6.2E-1002 Underflow Subnormal Inexact Rounded -- test -0s precision: 9 @@ -488,123 +352,124 @@ powx566 power -1 0 -> 1 powx567 power -1 -0 -> 1 powx568 power 0 1 -> 0 -powx569 power 0 -1 -> Infinity Division_by_zero +powx569 power 0 -1 -> Infinity powx570 power -0 1 -> -0 -powx571 power -0 -1 -> -Infinity Division_by_zero +powx571 power -0 -1 -> -Infinity powx572 power 0 2 -> 0 -powx573 power 0 -2 -> Infinity Division_by_zero +powx573 power 0 -2 -> Infinity powx574 power -0 2 -> 0 -powx575 power -0 -2 -> Infinity Division_by_zero +powx575 power -0 -2 -> Infinity powx576 power 0 3 -> 0 -powx577 power 0 -3 -> Infinity Division_by_zero +powx577 power 0 -3 -> Infinity powx578 power -0 3 -> -0 -powx579 power -0 -3 -> -Infinity Division_by_zero +powx579 power -0 -3 -> -Infinity -- Specials -powx580 power Inf -Inf -> NaN Invalid_operation +powx580 power Inf -Inf -> 0 powx581 power Inf -1000 -> 0 powx582 power Inf -1 -> 0 -powx583 power Inf -0 -> 1 -powx584 power Inf 0 -> 1 -powx585 power Inf 1 -> Infinity -powx586 power Inf 1000 -> Infinity -powx587 power Inf Inf -> NaN Invalid_operation -powx588 power -1000 Inf -> NaN Invalid_operation -powx589 power -Inf Inf -> NaN Invalid_operation -powx590 power -1 Inf -> NaN Invalid_operation -powx591 power -0 Inf -> NaN Invalid_operation -powx592 power 0 Inf -> NaN Invalid_operation -powx593 power 1 Inf -> NaN Invalid_operation -powx594 power 1000 Inf -> NaN Invalid_operation -powx595 power Inf Inf -> NaN Invalid_operation +powx583 power Inf -0.5 -> 0 +powx584 power Inf -0 -> 1 +powx585 power Inf 0 -> 1 +powx586 power Inf 0.5 -> Infinity +powx587 power Inf 1 -> Infinity +powx588 power Inf 1000 -> Infinity +powx589 power Inf Inf -> Infinity +powx590 power -1000 Inf -> NaN Invalid_operation +powx591 power -Inf Inf -> NaN Invalid_operation +powx592 power -1 Inf -> NaN Invalid_operation +powx593 power -0.5 Inf -> NaN Invalid_operation +powx594 power -0 Inf -> 0 +powx595 power 0 Inf -> 0 +powx596 power 0.5 Inf -> 0 +powx597 power 1 Inf -> 1.00000000 Inexact Rounded +powx598 power 1000 Inf -> Infinity +powx599 power Inf Inf -> Infinity powx600 power -Inf -Inf -> NaN Invalid_operation powx601 power -Inf -1000 -> 0 powx602 power -Inf -1 -> -0 -powx603 power -Inf -0 -> 1 -powx604 power -Inf 0 -> 1 -powx605 power -Inf 1 -> -Infinity -powx606 power -Inf 1000 -> Infinity -powx607 power -Inf Inf -> NaN Invalid_operation -powx608 power -1000 Inf -> NaN Invalid_operation -powx609 power -Inf -Inf -> NaN Invalid_operation -powx610 power -1 -Inf -> NaN Invalid_operation -powx611 power -0 -Inf -> NaN Invalid_operation -powx612 power 0 -Inf -> NaN Invalid_operation -powx613 power 1 -Inf -> NaN Invalid_operation -powx614 power 1000 -Inf -> NaN Invalid_operation -powx615 power Inf -Inf -> NaN Invalid_operation +powx603 power -Inf -0.5 -> NaN Invalid_operation +powx604 power -Inf -0 -> 1 +powx605 power -Inf 0 -> 1 +powx606 power -Inf 0.5 -> NaN Invalid_operation +powx607 power -Inf 1 -> -Infinity +powx608 power -Inf 1000 -> Infinity +powx609 power -Inf Inf -> NaN Invalid_operation +powx610 power -1000 Inf -> NaN Invalid_operation +powx611 power -Inf -Inf -> NaN Invalid_operation +powx612 power -1 -Inf -> NaN Invalid_operation +powx613 power -0.5 -Inf -> NaN Invalid_operation +powx614 power -0 -Inf -> Infinity +powx615 power 0 -Inf -> Infinity +powx616 power 0.5 -Inf -> Infinity +powx617 power 1 -Inf -> 1.00000000 Inexact Rounded +powx618 power 1000 -Inf -> 0 +powx619 power Inf -Inf -> 0 -powx621 power NaN -Inf -> NaN Invalid_operation +powx621 power NaN -Inf -> NaN powx622 power NaN -1000 -> NaN powx623 power NaN -1 -> NaN -powx624 power NaN -0 -> NaN -powx625 power NaN 0 -> NaN -powx626 power NaN 1 -> NaN -powx627 power NaN 1000 -> NaN -powx628 power NaN Inf -> NaN Invalid_operation -powx629 power NaN NaN -> NaN -powx630 power -Inf NaN -> NaN -powx631 power -1000 NaN -> NaN -powx632 power -1 NaN -> NaN -powx633 power -0 NaN -> NaN -powx634 power 0 NaN -> NaN -powx635 power 1 NaN -> NaN -powx636 power 1000 NaN -> NaN -powx637 power Inf NaN -> NaN +powx624 power NaN -0.5 -> NaN +powx625 power NaN -0 -> NaN +powx626 power NaN 0 -> NaN +powx627 power NaN 0.5 -> NaN +powx628 power NaN 1 -> NaN +powx629 power NaN 1000 -> NaN +powx630 power NaN Inf -> NaN +powx631 power NaN NaN -> NaN +powx632 power -Inf NaN -> NaN +powx633 power -1000 NaN -> NaN +powx634 power -1 NaN -> NaN +powx635 power -0 NaN -> NaN +powx636 power 0 NaN -> NaN +powx637 power 1 NaN -> NaN +powx638 power 1000 NaN -> NaN +powx639 power Inf NaN -> NaN powx641 power sNaN -Inf -> NaN Invalid_operation powx642 power sNaN -1000 -> NaN Invalid_operation powx643 power sNaN -1 -> NaN Invalid_operation -powx644 power sNaN -0 -> NaN Invalid_operation -powx645 power sNaN 0 -> NaN Invalid_operation -powx646 power sNaN 1 -> NaN Invalid_operation -powx647 power sNaN 1000 -> NaN Invalid_operation -powx648 power sNaN NaN -> NaN Invalid_operation -powx649 power sNaN sNaN -> NaN Invalid_operation -powx650 power NaN sNaN -> NaN Invalid_operation -powx651 power -Inf sNaN -> NaN Invalid_operation -powx652 power -1000 sNaN -> NaN Invalid_operation -powx653 power -1 sNaN -> NaN Invalid_operation -powx654 power -0 sNaN -> NaN Invalid_operation -powx655 power 0 sNaN -> NaN Invalid_operation -powx656 power 1 sNaN -> NaN Invalid_operation -powx657 power 1000 sNaN -> NaN Invalid_operation -powx658 power Inf sNaN -> NaN Invalid_operation -powx659 power NaN sNaN -> NaN Invalid_operation +powx644 power sNaN -0.5 -> NaN Invalid_operation +powx645 power sNaN -0 -> NaN Invalid_operation +powx646 power sNaN 0 -> NaN Invalid_operation +powx647 power sNaN 0.5 -> NaN Invalid_operation +powx648 power sNaN 1 -> NaN Invalid_operation +powx649 power sNaN 1000 -> NaN Invalid_operation +powx650 power sNaN NaN -> NaN Invalid_operation +powx651 power sNaN sNaN -> NaN Invalid_operation +powx652 power NaN sNaN -> NaN Invalid_operation +powx653 power -Inf sNaN -> NaN Invalid_operation +powx654 power -1000 sNaN -> NaN Invalid_operation +powx655 power -1 sNaN -> NaN Invalid_operation +powx656 power -0.5 sNaN -> NaN Invalid_operation +powx657 power -0 sNaN -> NaN Invalid_operation +powx658 power 0 sNaN -> NaN Invalid_operation +powx659 power 0.5 sNaN -> NaN Invalid_operation +powx660 power 1 sNaN -> NaN Invalid_operation +powx661 power 1000 sNaN -> NaN Invalid_operation +powx662 power Inf sNaN -> NaN Invalid_operation +powx663 power NaN sNaN -> NaN Invalid_operation -- NaN propagation -powx660 power NaN3 sNaN7 -> NaN7 Invalid_operation -powx661 power sNaN8 NaN6 -> NaN8 Invalid_operation -powx662 power 1 sNaN7 -> NaN7 Invalid_operation -powx663 power sNaN8 1 -> NaN8 Invalid_operation -powx664 power Inf sNaN7 -> NaN7 Invalid_operation -powx665 power sNaN8 Inf -> NaN Invalid_operation -powx666 power Inf NaN9 -> NaN9 -powx667 power NaN6 Inf -> NaN Invalid_operation -powx668 power 1 NaN5 -> NaN5 -powx669 power NaN2 1 -> NaN2 -powx670 power NaN2 Nan4 -> NaN2 -powx671 power NaN Nan4 -> NaN -powx672 power NaN345 Nan -> NaN345 -powx673 power Inf -sNaN7 -> -NaN7 Invalid_operation -powx674 power -sNaN8 Inf -> NaN Invalid_operation -powx675 power Inf -NaN9 -> -NaN9 -powx676 power -NaN6 Inf -> NaN Invalid_operation -powx677 power -NaN2 -Nan4 -> -NaN2 - --- Examples from extended specification -powx690 power Inf -2 -> 0 -powx691 power Inf -1 -> 0 -powx692 power Inf 0 -> 1 -powx693 power Inf 1 -> Infinity -powx694 power Inf 2 -> Infinity -powx695 power -Inf -2 -> 0 -powx696 power -Inf -1 -> -0 -powx697 power -Inf 0 -> 1 -powx698 power -Inf 1 -> -Infinity -powx699 power -Inf 2 -> Infinity -powx700 power 0 0 -> NaN Invalid_operation +powx670 power NaN3 sNaN7 -> NaN7 Invalid_operation +powx671 power sNaN8 NaN6 -> NaN8 Invalid_operation +powx672 power 1 sNaN7 -> NaN7 Invalid_operation +powx673 power sNaN8 1 -> NaN8 Invalid_operation +powx674 power Inf sNaN7 -> NaN7 Invalid_operation +powx675 power sNaN8 Inf -> NaN8 Invalid_operation +powx676 power Inf NaN9 -> NaN9 +powx677 power NaN6 Inf -> NaN6 +powx678 power 1 NaN5 -> NaN5 +powx679 power NaN2 1 -> NaN2 +powx680 power NaN2 Nan4 -> NaN2 +powx681 power NaN Nan4 -> NaN +powx682 power NaN345 Nan -> NaN345 +powx683 power Inf -sNaN7 -> -NaN7 Invalid_operation +powx684 power -sNaN8 Inf -> -NaN8 Invalid_operation +powx685 power Inf -NaN9 -> -NaN9 +powx686 power -NaN6 Inf -> -NaN6 +powx687 power -NaN2 -Nan4 -> -NaN2 -- long operand and RHS range checks maxexponent: 999 @@ -616,15 +481,6 @@ powx704 power 1234567891 1 -> 1.23456789E+9 Inexact Rounded powx705 power 12345678901 1 -> 1.23456789E+10 Inexact Rounded powx706 power 1234567896 1 -> 1.23456790E+9 Inexact Rounded -powx707 power 1 12345678000 -> NaN Invalid_operation -powx708 power 1 1234567800 -> NaN Invalid_operation -powx709 power 1 1234567890 -> NaN Invalid_operation -powx710 power 1 11234567891 -> NaN Invalid_operation -powx711 power 1 12345678901 -> NaN Invalid_operation -powx712 power 1 1234567896 -> NaN Invalid_operation -powx713 power 1 -1234567896 -> NaN Invalid_operation -powx714 power 1 1000000000 -> NaN Invalid_operation -powx715 power 1 -1000000000 -> NaN Invalid_operation precision: 15 -- still checking @@ -634,12 +490,182 @@ powx744 power 1234567891 1 -> 1234567891 powx745 power 12345678901 1 -> 12345678901 powx746 power 1234567896 1 -> 1234567896 -powx747 power 1 12345678000 -> NaN Invalid_operation -powx748 power 1 -1234567896 -> NaN Invalid_operation -powx749 power 1 1000000000 -> NaN Invalid_operation -powx740 power 1 -1000000000 -> NaN Invalid_operation --- check for double-rounded subnormals +maxexponent: 999999 +minexponent: -999999 +precision: 9 + +-- near out-of-range edge cases +powx163 power '10' '999999' -> '1.00000000E+999999' Rounded +powx164 power '10' '999998' -> '1.00000000E+999998' Rounded +powx165 power '10' '999997' -> '1.00000000E+999997' Rounded +powx166 power '10' '333333' -> '1.00000000E+333333' Rounded +powx183 power '7' '1000000' -> 1.09651419E+845098 Inexact Rounded +powx184 power '7' '1000001' -> 7.67559934E+845098 Inexact Rounded +powx186 power '7' '-1000001' -> 1.30282986E-845099 Inexact Rounded +powx187 power '7' '-1000000' -> 9.11980901E-845099 Inexact Rounded +powx118 power '10' '-333333' -> 1E-333333 +powx119 power '10' '-999998' -> 1E-999998 +powx120 power '10' '-999999' -> 1E-999999 +powx181 power '7' '999998' -> 2.23778406E+845096 Inexact Rounded +powx182 power '7' '999999' -> 1.56644884E+845097 Inexact Rounded +powx189 power '7' '-999999' -> 6.38386631E-845098 Inexact Rounded +powx190 power '7' '-999998' -> 4.46870641E-845097 Inexact Rounded + +-- overflow and underflow tests +precision: 9 + +powx277 power 9 999999 -> 3.59084629E+954241 Inexact Rounded +powx278 power 9.99999999 999999 -> 9.99000501E+999998 Inexact Rounded +powx279 power 10 999999 -> 1.00000000E+999999 Rounded +powx280 power 10.0000001 999999 -> 1.01005016E+999999 Inexact Rounded +powx281 power 10.000001 999999 -> 1.10517080E+999999 Inexact Rounded +powx282 power 10.00001 999999 -> 2.71827775E+999999 Inexact Rounded +powx283 power 10.0001 999999 -> Infinity Overflow Inexact Rounded +powx285 power 11 999999 -> Infinity Overflow Inexact Rounded +powx286 power 12 999999 -> Infinity Overflow Inexact Rounded +powx287 power 999 999999 -> Infinity Overflow Inexact Rounded +powx288 power 999999999 999999 -> Infinity Overflow Inexact Rounded +powx289 power 9.9E999999999 999999 -> Infinity Overflow Inexact Rounded + +powx290 power 0.5 999999 -> 2.02006812E-301030 Inexact Rounded +powx291 power 0.1 999999 -> 1E-999999 -- unrounded +powx292 power 0.09 999999 -> 0E-1000007 Underflow Subnormal Inexact Rounded Clamped +powx293 power 0.05 999999 -> 0E-1000007 Underflow Subnormal Inexact Rounded Clamped +powx294 power 0.01 999999 -> 0E-1000007 Underflow Subnormal Inexact Rounded Clamped +powx295 power 0.0001 999999 -> 0E-1000007 Underflow Subnormal Inexact Rounded Clamped +powx297 power 0.0000001 999999 -> 0E-1000007 Underflow Subnormal Inexact Rounded Clamped +powx298 power 0.0000000001 999999 -> 0E-1000007 Underflow Subnormal Inexact Rounded Clamped +powx299 power 1E-999999999 999999 -> 0E-1000007 Underflow Subnormal Inexact Rounded Clamped + +powx310 power -9 999999 -> -3.59084629E+954241 Inexact Rounded +powx311 power -10 999999 -> -1.00000000E+999999 Rounded +powx312 power -10.0001 999999 -> -Infinity Overflow Inexact Rounded +powx313 power -10.1 999999 -> -Infinity Overflow Inexact Rounded +powx314 power -11 999999 -> -Infinity Overflow Inexact Rounded +powx315 power -12 999999 -> -Infinity Overflow Inexact Rounded +powx316 power -999 999999 -> -Infinity Overflow Inexact Rounded +powx317 power -999999 999999 -> -Infinity Overflow Inexact Rounded +powx318 power -999999999 999999 -> -Infinity Overflow Inexact Rounded +powx319 power -9.9E999999999 999999 -> -Infinity Overflow Inexact Rounded + +powx320 power -0.5 999999 -> -2.02006812E-301030 Inexact Rounded +powx321 power -0.1 999999 -> -1E-999999 +powx322 power -0.09 999999 -> -0E-1000007 Underflow Subnormal Inexact Rounded Clamped +powx323 power -0.05 999999 -> -0E-1000007 Underflow Subnormal Inexact Rounded Clamped +powx324 power -0.01 999999 -> -0E-1000007 Underflow Subnormal Inexact Rounded Clamped +powx325 power -0.0001 999999 -> -0E-1000007 Underflow Subnormal Inexact Rounded Clamped +powx327 power -0.0000001 999999 -> -0E-1000007 Underflow Subnormal Inexact Rounded Clamped +powx328 power -0.0000000001 999999 -> -0E-1000007 Underflow Subnormal Inexact Rounded Clamped +powx329 power -1E-999999999 999999 -> -0E-1000007 Underflow Subnormal Inexact Rounded Clamped + +-- note no trim of next result +powx330 power -9 999998 -> 3.98982921E+954240 Inexact Rounded +powx331 power -10 999998 -> 1.00000000E+999998 Rounded +powx332 power -10.0001 999998 -> Infinity Overflow Inexact Rounded +powx333 power -10.1 999998 -> Infinity Overflow Inexact Rounded +powx334 power -11 999998 -> Infinity Overflow Inexact Rounded +powx335 power -12 999998 -> Infinity Overflow Inexact Rounded +powx336 power -999 999998 -> Infinity Overflow Inexact Rounded +powx337 power -999999 999998 -> Infinity Overflow Inexact Rounded +powx338 power -999999999 999998 -> Infinity Overflow Inexact Rounded +powx339 power -9.9E999999999 999998 -> Infinity Overflow Inexact Rounded + +powx340 power -0.5 999998 -> 4.04013624E-301030 Inexact Rounded +powx341 power -0.1 999998 -> 1E-999998 -- NB exact unrounded +powx342 power -0.09 999998 -> 0E-1000007 Underflow Subnormal Inexact Rounded Clamped +powx343 power -0.05 999998 -> 0E-1000007 Underflow Subnormal Inexact Rounded Clamped +powx344 power -0.01 999998 -> 0E-1000007 Underflow Subnormal Inexact Rounded Clamped +powx345 power -0.0001 999998 -> 0E-1000007 Underflow Subnormal Inexact Rounded Clamped +powx347 power -0.0000001 999998 -> 0E-1000007 Underflow Subnormal Inexact Rounded Clamped +powx348 power -0.0000000001 999998 -> 0E-1000007 Underflow Subnormal Inexact Rounded Clamped +powx349 power -1E-999999999 999998 -> 0E-1000007 Underflow Subnormal Inexact Rounded Clamped + +-- some subnormals +precision: 9 +-- [precision is 9, so smallest exponent is -1000000007 +powx350 power 1e-1 500000 -> 1E-500000 +powx351 power 1e-2 999999 -> 0E-1000007 Underflow Subnormal Inexact Rounded Clamped +powx352 power 1e-2 500000 -> 1E-1000000 Subnormal +powx353 power 1e-2 500001 -> 1E-1000002 Subnormal +powx354 power 1e-2 500002 -> 1E-1000004 Subnormal +powx355 power 1e-2 500003 -> 1E-1000006 Subnormal +powx356 power 1e-2 500004 -> 0E-1000007 Underflow Subnormal Inexact Rounded Clamped + +powx360 power 0.010001 500000 -> 5.17176082E-999979 Inexact Rounded +powx361 power 0.010000001 500000 -> 1.0512711E-1000000 Underflow Subnormal Inexact Rounded +powx362 power 0.010000001 500001 -> 1.05127E-1000002 Underflow Subnormal Inexact Rounded +powx363 power 0.0100000009 500000 -> 1.0460279E-1000000 Underflow Subnormal Inexact Rounded +powx364 power 0.0100000001 500000 -> 1.0050125E-1000000 Underflow Subnormal Inexact Rounded +powx365 power 0.01 500000 -> 1E-1000000 Subnormal +powx366 power 0.0099999999 500000 -> 9.950125E-1000001 Underflow Subnormal Inexact Rounded +powx367 power 0.0099999998 500000 -> 9.900498E-1000001 Underflow Subnormal Inexact Rounded +powx368 power 0.0099999997 500000 -> 9.851119E-1000001 Underflow Subnormal Inexact Rounded +powx369 power 0.0099999996 500000 -> 9.801987E-1000001 Underflow Subnormal Inexact Rounded +powx370 power 0.009 500000 -> 0E-1000007 Underflow Subnormal Inexact Rounded Clamped + +-- 1/subnormal -> overflow +powx371 power 1e-1 -500000 -> 1E+500000 +powx372 power 1e-2 -999999 -> Infinity Overflow Inexact Rounded +powx373 power 1e-2 -500000 -> Infinity Overflow Inexact Rounded +powx374 power 1e-2 -500001 -> Infinity Overflow Inexact Rounded +powx375 power 1e-2 -500002 -> Infinity Overflow Inexact Rounded +powx376 power 1e-2 -500003 -> Infinity Overflow Inexact Rounded +powx377 power 1e-2 -500004 -> Infinity Overflow Inexact Rounded + +powx381 power 0.010001 -500000 -> 1.93357743E+999978 Inexact Rounded +powx382 power 0.010000001 -500000 -> 9.51229427E+999999 Inexact Rounded +powx383 power 0.010000001 -500001 -> Infinity Overflow Inexact Rounded +powx384 power 0.0100000009 -500000 -> 9.55997484E+999999 Inexact Rounded +powx385 power 0.0100000001 -500000 -> 9.95012479E+999999 Inexact Rounded +powx386 power 0.01 -500000 -> Infinity Overflow Inexact Rounded +powx387 power 0.009999 -500000 -> Infinity Overflow Inexact Rounded + +-- negative power giving subnormal +powx388 power 100.000001 -500000 -> 9.950125E-1000001 Underflow Subnormal Inexact Rounded + + +-- test some 'false integer' boundaries +precision: 16 +rounding: half_even +maxExponent: 384 +minExponent: -383 +powx501 power 100 1E+1 -> 1.000000000000000E+20 Rounded +powx502 power 100 1E+2 -> 1.000000000000000E+200 Rounded +powx503 power 100 1E+3 -> Infinity Overflow Inexact Rounded +powx504 power 100 1E+4 -> Infinity Overflow Inexact Rounded +powx505 power 100 1E+5 -> Infinity Overflow Inexact Rounded +powx506 power 100 1E+6 -> Infinity Overflow Inexact Rounded +powx507 power 100 1E+7 -> Infinity Overflow Inexact Rounded +powx508 power 100 1E+8 -> Infinity Overflow Inexact Rounded +powx509 power 100 1E+9 -> Infinity Overflow Inexact Rounded +powx510 power 100 1E+10 -> Infinity Overflow Inexact Rounded +powx511 power 100 1E+11 -> Infinity Overflow Inexact Rounded +powx512 power 100 1E+12 -> Infinity Overflow Inexact Rounded +powx513 power 100 1E+13 -> Infinity Overflow Inexact Rounded +powx514 power 100 1E+14 -> Infinity Overflow Inexact Rounded +powx515 power 100 1E+15 -> Infinity Overflow Inexact Rounded +powx516 power 100 1E+16 -> Infinity Overflow Inexact Rounded +powx517 power 100 1E+17 -> Infinity Overflow Inexact Rounded +powx518 power 100 1E+18 -> Infinity Overflow Inexact Rounded +powx519 power 100 1E+19 -> Infinity Overflow Inexact Rounded +powx520 power 100 1E+20 -> Infinity Overflow Inexact Rounded +powx521 power 100 1E+21 -> Infinity Overflow Inexact Rounded +powx522 power 100 1E+22 -> Infinity Overflow Inexact Rounded +powx523 power 100 1E+23 -> Infinity Overflow Inexact Rounded +powx524 power 100 1E+24 -> Infinity Overflow Inexact Rounded +powx525 power 100 1E+25 -> Infinity Overflow Inexact Rounded +powx526 power 100 1E+26 -> Infinity Overflow Inexact Rounded +powx527 power 100 1E+27 -> Infinity Overflow Inexact Rounded +powx528 power 100 1E+28 -> Infinity Overflow Inexact Rounded +powx529 power 100 1E+29 -> Infinity Overflow Inexact Rounded +powx530 power 100 1E+30 -> Infinity Overflow Inexact Rounded +powx531 power 100 1E+40 -> Infinity Overflow Inexact Rounded +powx532 power 100 1E+50 -> Infinity Overflow Inexact Rounded +powx533 power 100 1E+100 -> Infinity Overflow Inexact Rounded +powx534 power 100 1E+383 -> Infinity Overflow Inexact Rounded + +-- a check for double-rounded subnormals precision: 5 maxexponent: 79 minexponent: -79 @@ -649,3 +675,950 @@ powx900 power 1 # -> NaN Invalid_operation powx901 power # 1 -> NaN Invalid_operation +---------------------------------------------------------------------- +-- Below here are tests with a precision or context outside of the -- +-- decNumber 'mathematical functions' restricted range. These -- +-- remain supported in decNumber to minimize breakage, but may be -- +-- outside the range of other implementations. -- +---------------------------------------------------------------------- +maxexponent: 999999999 +minexponent: -999999999 +precision: 9 +powx1063 power '10' '999999999' -> '1.00000000E+999999999' Rounded +powx1064 power '10' '999999998' -> '1.00000000E+999999998' Rounded +powx1065 power '10' '999999997' -> '1.00000000E+999999997' Rounded +powx1066 power '10' '333333333' -> '1.00000000E+333333333' Rounded +-- next two are integer-out-of range +powx1183 power '7' '1000000000' -> NaN Invalid_context +powx1184 power '7' '1000000001' -> NaN Invalid_context +powx1186 power '7' '-1000000001' -> 1.38243630E-845098041 Inexact Rounded +powx1187 power '7' '-1000000000' -> 9.67705411E-845098041 Inexact Rounded + +-- out-of-range edge cases +powx1118 power '10' '-333333333' -> 1E-333333333 +powx1119 power '10' '-999999998' -> 1E-999999998 +powx1120 power '10' '-999999999' -> 1E-999999999 +powx1181 power '7' '999999998' -> 2.10892313E+845098038 Inexact Rounded +powx1182 power '7' '999999999' -> 1.47624619E+845098039 Inexact Rounded +powx1189 power '7' '-999999999' -> 6.77393787E-845098040 Inexact Rounded +powx1190 power '7' '-999999998' -> 4.74175651E-845098039 Inexact Rounded + +-- A (rare) case where the last digit is not within 0.5 ULP with classic precision +precision: 9 +powx1215 power "-21971575.0E+31454441" "-7" -> "-4.04549502E-220181139" Inexact Rounded +precision: 20 +powx1216 power "-21971575.0E+31454441" "-7" -> "-4.0454950249324891788E-220181139" Inexact Rounded + +-- overflow and underflow tests +precision: 9 +powx1280 power 9 999999999 -> 3.05550054E+954242508 Inexact Rounded +powx1281 power 10 999999999 -> 1.00000000E+999999999 Rounded +powx1282 power 10.0001 999999999 -> Infinity Overflow Inexact Rounded +powx1283 power 10.1 999999999 -> Infinity Overflow Inexact Rounded +powx1284 power 11 999999999 -> Infinity Overflow Inexact Rounded +powx1285 power 12 999999999 -> Infinity Overflow Inexact Rounded +powx1286 power 999 999999999 -> Infinity Overflow Inexact Rounded +powx1287 power 999999 999999999 -> Infinity Overflow Inexact Rounded +powx1288 power 999999999 999999999 -> Infinity Overflow Inexact Rounded +powx1289 power 9.9E999999999 999999999 -> Infinity Overflow Inexact Rounded + +powx1290 power 0.5 999999999 -> 4.33559594E-301029996 Inexact Rounded +powx1291 power 0.1 999999999 -> 1E-999999999 -- unrounded +powx1292 power 0.09 999999999 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped +powx1293 power 0.05 999999999 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped +powx1294 power 0.01 999999999 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped +powx1295 power 0.0001 999999999 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped +powx1297 power 0.0000001 999999999 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped +powx1298 power 0.0000000001 999999999 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped +powx1299 power 1E-999999999 999999999 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped + +powx1310 power -9 999999999 -> -3.05550054E+954242508 Inexact Rounded +powx1311 power -10 999999999 -> -1.00000000E+999999999 Rounded +powx1312 power -10.0001 999999999 -> -Infinity Overflow Inexact Rounded +powx1313 power -10.1 999999999 -> -Infinity Overflow Inexact Rounded +powx1314 power -11 999999999 -> -Infinity Overflow Inexact Rounded +powx1315 power -12 999999999 -> -Infinity Overflow Inexact Rounded +powx1316 power -999 999999999 -> -Infinity Overflow Inexact Rounded +powx1317 power -999999 999999999 -> -Infinity Overflow Inexact Rounded +powx1318 power -999999999 999999999 -> -Infinity Overflow Inexact Rounded +powx1319 power -9.9E999999999 999999999 -> -Infinity Overflow Inexact Rounded + +powx1320 power -0.5 999999999 -> -4.33559594E-301029996 Inexact Rounded +powx1321 power -0.1 999999999 -> -1E-999999999 +powx1322 power -0.09 999999999 -> -0E-1000000007 Underflow Subnormal Inexact Rounded Clamped +powx1323 power -0.05 999999999 -> -0E-1000000007 Underflow Subnormal Inexact Rounded Clamped +powx1324 power -0.01 999999999 -> -0E-1000000007 Underflow Subnormal Inexact Rounded Clamped +powx1325 power -0.0001 999999999 -> -0E-1000000007 Underflow Subnormal Inexact Rounded Clamped +powx1327 power -0.0000001 999999999 -> -0E-1000000007 Underflow Subnormal Inexact Rounded Clamped +powx1328 power -0.0000000001 999999999 -> -0E-1000000007 Underflow Subnormal Inexact Rounded Clamped +powx1329 power -1E-999999999 999999999 -> -0E-1000000007 Underflow Subnormal Inexact Rounded Clamped + +-- note no trim of next result +powx1330 power -9 999999998 -> 3.39500060E+954242507 Inexact Rounded +powx1331 power -10 999999998 -> 1.00000000E+999999998 Rounded +powx1332 power -10.0001 999999998 -> Infinity Overflow Inexact Rounded +powx1333 power -10.1 999999998 -> Infinity Overflow Inexact Rounded +powx1334 power -11 999999998 -> Infinity Overflow Inexact Rounded +powx1335 power -12 999999998 -> Infinity Overflow Inexact Rounded +powx1336 power -999 999999998 -> Infinity Overflow Inexact Rounded +powx1337 power -999999 999999998 -> Infinity Overflow Inexact Rounded +powx1338 power -999999999 999999998 -> Infinity Overflow Inexact Rounded +powx1339 power -9.9E999999999 999999998 -> Infinity Overflow Inexact Rounded + +powx1340 power -0.5 999999998 -> 8.67119187E-301029996 Inexact Rounded +powx1341 power -0.1 999999998 -> 1E-999999998 -- NB exact unrounded +powx1342 power -0.09 999999998 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped +powx1343 power -0.05 999999998 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped +powx1344 power -0.01 999999998 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped +powx1345 power -0.0001 999999998 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped +powx1347 power -0.0000001 999999998 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped +powx1348 power -0.0000000001 999999998 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped +powx1349 power -1E-999999999 999999998 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped + +-- some subnormals +precision: 9 +-- [precision is 9, so smallest exponent is -1000000007 +powx1350 power 1e-1 500000000 -> 1E-500000000 +powx1351 power 1e-2 999999999 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped +powx1352 power 1e-2 500000000 -> 1E-1000000000 Subnormal +powx1353 power 1e-2 500000001 -> 1E-1000000002 Subnormal +powx1354 power 1e-2 500000002 -> 1E-1000000004 Subnormal +powx1355 power 1e-2 500000003 -> 1E-1000000006 Subnormal +powx1356 power 1e-2 500000004 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped + +powx1360 power 0.010001 500000000 -> 4.34941988E-999978287 Inexact Rounded +powx1361 power 0.010000001 500000000 -> 5.18469257E-999999979 Inexact Rounded +powx1362 power 0.010000001 500000001 -> 5.18469309E-999999981 Inexact Rounded +powx1363 power 0.0100000009 500000000 -> 3.49342003E-999999981 Inexact Rounded +powx1364 power 0.0100000001 500000000 -> 1.48413155E-999999998 Inexact Rounded +powx1365 power 0.01 500000000 -> 1E-1000000000 Subnormal +powx1366 power 0.0099999999 500000000 -> 6.7379E-1000000003 Underflow Subnormal Inexact Rounded +powx1367 power 0.0099999998 500000000 -> 4.54E-1000000005 Underflow Subnormal Inexact Rounded +powx1368 power 0.0099999997 500000000 -> 3E-1000000007 Underflow Subnormal Inexact Rounded +powx1369 power 0.0099999996 500000000 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped +powx1370 power 0.009 500000000 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped + +-- 1/subnormal -> overflow +powx1371 power 1e-1 -500000000 -> 1E+500000000 +powx1372 power 1e-2 -999999999 -> Infinity Overflow Inexact Rounded +powx1373 power 1e-2 -500000000 -> Infinity Overflow Inexact Rounded +powx1374 power 1e-2 -500000001 -> Infinity Overflow Inexact Rounded +powx1375 power 1e-2 -500000002 -> Infinity Overflow Inexact Rounded +powx1376 power 1e-2 -500000003 -> Infinity Overflow Inexact Rounded +powx1377 power 1e-2 -500000004 -> Infinity Overflow Inexact Rounded + +powx1381 power 0.010001 -500000000 -> 2.29915719E+999978286 Inexact Rounded +powx1382 power 0.010000001 -500000000 -> 1.92875467E+999999978 Inexact Rounded +powx1383 power 0.010000001 -500000001 -> 1.92875448E+999999980 Inexact Rounded +powx1384 power 0.0100000009 -500000000 -> 2.86252438E+999999980 Inexact Rounded +powx1385 power 0.0100000001 -500000000 -> 6.73794717E+999999997 Inexact Rounded +powx1386 power 0.01 -500000000 -> Infinity Overflow Inexact Rounded +powx1387 power 0.009999 -500000000 -> Infinity Overflow Inexact Rounded + +-- negative power giving subnormal +powx1388 power 100.000001 -500000000 -> 6.7379E-1000000003 Underflow Subnormal Inexact Rounded + +---------------------------------------------------------------------- +-- Below here are the tests with a non-integer rhs, including the -- +-- tests that previously caused Invalid operation. An integer-only -- +-- (on rhs) implementation should handle all the tests above as -- +-- shown, and would flag most of the following tests as Invalid. -- +---------------------------------------------------------------------- +precision: 16 +rounding: half_even +maxExponent: 384 +minExponent: -383 + +powx2000 power 7 '10000000000' -> Infinity Overflow Inexact Rounded +powx2001 power 2 '2.000001' -> 4.000002772589683 Inexact Rounded +powx2002 power 2 '2.00000000' -> 4 +powx2003 power 2 '2.000000001' -> 4.000000002772589 Inexact Rounded +powx2004 power 2 '2.0000000001' -> 4.000000000277259 Inexact Rounded +powx2005 power 2 '2.00000000001' -> 4.000000000027726 Inexact Rounded +powx2006 power 2 '2.000000000001' -> 4.000000000002773 Inexact Rounded +powx2007 power 2 '2.0000000000001' -> 4.000000000000277 Inexact Rounded +powx2008 power 2 '2.00000000000001' -> 4.000000000000028 Inexact Rounded +powx2009 power 2 '2.000000000000001' -> 4.000000000000003 Inexact Rounded +powx2010 power 2 '2.0000000000000001' -> 4.000000000000000 Inexact Rounded +-- 1 234567890123456 + +powx2011 power 1 1234 -> 1 +precision: 4 +powx2012 power 1 1234 -> 1 +precision: 3 +powx2013 power 1 1234 -> 1 +powx2014 power 1 12.34e+2 -> 1 +powx2015 power 1 12.3 -> 1.00 Inexact Rounded +powx2016 power 1 12.0 -> 1 +powx2017 power 1 1.01 -> 1.00 Inexact Rounded +powx2018 power 2 1.00 -> 2 +powx2019 power 2 2.00 -> 4 +precision: 9 +powx2030 power 1 1.0001 -> 1.00000000 Inexact Rounded +powx2031 power 1 1.0000001 -> 1.00000000 Inexact Rounded +powx2032 power 1 1.0000000001 -> 1.00000000 Inexact Rounded +powx2033 power 1 1.0000000000001 -> 1.00000000 Inexact Rounded +precision: 5 +powx2034 power 1 1.0001 -> 1.0000 Inexact Rounded +powx2035 power 1 1.0000001 -> 1.0000 Inexact Rounded +powx2036 power 1 1.0000000001 -> 1.0000 Inexact Rounded +powx2037 power 1 1.0000000000001 -> 1.0000 Inexact Rounded +powx2038 power 1 1.0000000000001 -> 1.0000 Inexact Rounded + +rounding: ceiling +precision: 3 +powx2039 power 1 1.01 -> 1.00 Inexact Rounded +powx2040 power 1 12.3 -> 1.00 Inexact Rounded +rounding: half_even + +-- 1 ** any integer, including big ones, should be exact +powx2041 power 1 1000000000 -> 1 +powx2042 power 1 9999999999 -> 1 +powx2043 power 1 12345678000 -> 1 +powx2044 power 1 1234567800 -> 1 +powx2045 power 1 1234567890 -> 1 +powx2046 power 1 11234567891 -> 1 +powx2047 power 1 12345678901 -> 1 +powx2048 power 1 1234567896 -> 1 +powx2049 power 1 -1234567896 -> 1 +powx2051 power 1 1000000000 -> 1 +powx2052 power 1 -1000000000 -> 1 +powx2053 power 1 12345678000 -> 1 +powx2054 power 1 -1234567896 -> 1 +powx2055 power 1 1000000000 -> 1 +powx2056 power 1 4300000000 -> 1 +powx2057 power 1 -1000000000 -> 1 +-- negatives ... but not out of range for decNumber +powx2061 power -1 100000 -> 1 +powx2062 power -1 999999 -> -1 +powx2063 power -1 1278000 -> 1 +powx2064 power -1 127803 -> -1 +powx2065 power -1 127890 -> 1 +powx2066 power -1 1167891 -> -1 +powx2067 power -1 1278901 -> -1 +powx2068 power -1 127896 -> 1 +powx2069 power -1 -167897 -> -1 +powx2071 power -1 100000 -> 1 +powx2072 power -1 -100001 -> -1 +powx2073 power -1 1278000 -> 1 +powx2074 power -1 -167896 -> 1 +powx2075 power -1 100000 -> 1 +powx2076 power -1 -100009 -> -1 + +-- The above were derived from the earlier version of power.decTest; +-- now start new tests for power(x,y) for non-integer y +precision: 9 + +-- tests from specification +powx2081 power 2 3 -> '8' +powx2082 power -2 3 -> '-8' +powx2083 power 2 -3 -> '0.125' +powx2084 power 1.7 '8' -> '69.7575744' Inexact Rounded +powx2085 power 10 0.301029996 -> 2.00000000 Inexact Rounded +powx2086 power Infinity '-1' -> '0' +powx2087 power Infinity '0' -> '1' +powx2088 power Infinity '1' -> 'Infinity' +powx2089 power -Infinity '-1' -> '-0' +powx2090 power -Infinity '0' -> '1' +powx2091 power -Infinity '1' -> '-Infinity' +powx2092 power -Infinity '2' -> 'Infinity' +powx2093 power 0 0 -> 'NaN' Invalid_operation + +precision: 16 +rounding: half_even +maxExponent: 384 +minExponent: -383 + +-- basics +powx2100 power 1E-7 1E-7 -> 0.9999983881917339 Inexact Rounded +powx2101 power 0.003 1E-7 -> 0.9999994190858697 Inexact Rounded +powx2102 power 0.7 1E-7 -> 0.9999999643325062 Inexact Rounded +powx2103 power 1.2 1E-7 -> 1.000000018232156 Inexact Rounded +powx2104 power 71 1E-7 -> 1.000000426268079 Inexact Rounded +powx2105 power 9E+9 1E-7 -> 1.000002292051668 Inexact Rounded + +powx2110 power 1E-7 0.003 -> 0.9527961640236519 Inexact Rounded +powx2111 power 0.003 0.003 -> 0.9827235503366797 Inexact Rounded +powx2112 power 0.7 0.003 -> 0.9989305474406207 Inexact Rounded +powx2113 power 1.2 0.003 -> 1.000547114282834 Inexact Rounded +powx2114 power 71 0.003 -> 1.012870156273545 Inexact Rounded +powx2115 power 9E+9 0.003 -> 1.071180671278787 Inexact Rounded + +powx2120 power 1E-7 0.7 -> 0.00001258925411794167 Inexact Rounded +powx2121 power 0.003 0.7 -> 0.01713897630281030 Inexact Rounded +powx2122 power 0.7 0.7 -> 0.7790559126704491 Inexact Rounded +powx2123 power 1.2 0.7 -> 1.136126977198889 Inexact Rounded +powx2124 power 71 0.7 -> 19.76427300093870 Inexact Rounded +powx2125 power 9E+9 0.7 -> 9289016.976853710 Inexact Rounded + +powx2130 power 1E-7 1.2 -> 3.981071705534973E-9 Inexact Rounded +powx2131 power 0.003 1.2 -> 0.0009387403933595694 Inexact Rounded +powx2132 power 0.7 1.2 -> 0.6518049405663864 Inexact Rounded +powx2133 power 1.2 1.2 -> 1.244564747203978 Inexact Rounded +powx2134 power 71 1.2 -> 166.5367244638552 Inexact Rounded +powx2135 power 9E+9 1.2 -> 881233526124.8791 Inexact Rounded + +powx2140 power 1E-7 71 -> 0E-398 Inexact Rounded Underflow Subnormal Clamped +powx2141 power 0.003 71 -> 7.509466514979725E-180 Inexact Rounded +powx2142 power 0.7 71 -> 1.004525211269079E-11 Inexact Rounded +powx2143 power 1.2 71 -> 418666.7483186515 Inexact Rounded +powx2144 power 71 71 -> 2.750063734834616E+131 Inexact Rounded +powx2145 power 9E+9 71 -> Infinity Inexact Rounded Overflow + +powx2150 power 1E-7 9E+9 -> 0E-398 Inexact Rounded Underflow Subnormal Clamped +powx2151 power 0.003 9E+9 -> 0E-398 Inexact Rounded Underflow Subnormal Clamped +powx2152 power 0.7 9E+9 -> 0E-398 Inexact Rounded Underflow Subnormal Clamped +powx2153 power 1.2 9E+9 -> Infinity Inexact Rounded Overflow +powx2154 power 71 9E+9 -> Infinity Inexact Rounded Overflow +powx2155 power 9E+9 9E+9 -> Infinity Inexact Rounded Overflow + +-- number line milestones with lhs<1 and lhs>1 + +-- Overflow boundary (Nmax) +powx2202 power 71 207.966651583983200 -> Infinity Inexact Rounded Overflow +powx2201 power 71 207.966651583983199 -> 9.999999999999994E+384 Inexact Rounded +powx2204 power 0.003 -152.603449817093577 -> Infinity Inexact Rounded Overflow +powx2203 power 0.003 -152.603449817093576 -> 9.999999999999994E+384 Inexact Rounded + +-- Nmin boundary +powx2211 power 71 -206.886305341988480 -> 1.000000000000005E-383 Inexact Rounded +powx2212 power 71 -206.886305341988481 -> 1.000000000000001E-383 Inexact Rounded +powx2213 power 71 -206.886305341988482 -> 9.99999999999997E-384 Inexact Rounded Underflow Subnormal +powx2214 power 71 -206.886305341988483 -> 9.99999999999992E-384 Inexact Rounded Underflow Subnormal +-- 9.999999999999924565357019820 + +powx2215 power 0.003 151.810704623238543 -> 1.000000000000009E-383 Inexact Rounded +powx2216 power 0.003 151.810704623238544 -> 1.000000000000003E-383 Inexact Rounded +powx2217 power 0.003 151.810704623238545 -> 9.99999999999997E-384 Inexact Rounded Underflow Subnormal +powx2218 power 0.003 151.810704623238546 -> 9.99999999999991E-384 Inexact Rounded Underflow Subnormal + +-- Ntiny boundary, these edge cases determined using half_up rounding +rounding: half_up +powx2221 power 71 -215.151510469220498 -> 1E-398 Inexact Rounded Underflow Subnormal +powx2222 power 71 -215.151510469220499 -> 1E-398 Inexact Rounded Underflow Subnormal +powx2223 power 71 -215.151510469220500 -> 0E-398 Inexact Rounded Underflow Subnormal Clamped +powx2224 power 71 -215.151510469220501 -> 0E-398 Inexact Rounded Underflow Subnormal Clamped + +powx2225 power 0.003 157.875613618285691 -> 1E-398 Inexact Rounded Underflow Subnormal +powx2226 power 0.003 157.875613618285692 -> 1E-398 Inexact Rounded Underflow Subnormal +powx2227 power 0.003 157.875613618285693 -> 0E-398 Inexact Rounded Underflow Subnormal Clamped +powx2228 power 0.003 220 -> 0E-398 Inexact Rounded Underflow Subnormal Clamped +rounding: half_even + +-- power(10, y) are important ... + +-- Integer powers are exact, unless over/underflow +powx2301 power 10 385 -> Infinity Overflow Inexact Rounded +powx2302 power 10 384 -> 1.000000000000000E+384 Rounded +powx2303 power 10 17 -> 1.000000000000000E+17 Rounded +powx2304 power 10 16 -> 1.000000000000000E+16 Rounded +powx2305 power 10 15 -> 1000000000000000 +powx2306 power 10 10 -> 10000000000 +powx2307 power 10 5 -> 100000 +powx2308 power 10 1 -> 10 +powx2309 power 10 0 -> 1 +powx2310 power 10 -1 -> 0.1 +powx2311 power 10 -5 -> 0.00001 +powx2312 power 10 -6 -> 0.000001 +powx2313 power 10 -7 -> 1E-7 +powx2314 power 10 -8 -> 1E-8 +powx2315 power 10 -9 -> 1E-9 +powx2316 power 10 -10 -> 1E-10 +powx2317 power 10 -383 -> 1E-383 +powx2318 power 10 -384 -> 1E-384 Subnormal +powx2319 power 10 -385 -> 1E-385 Subnormal +powx2320 power 10 -397 -> 1E-397 Subnormal +powx2321 power 10 -398 -> 1E-398 Subnormal +powx2322 power 10 -399 -> 0E-398 Subnormal Underflow Inexact Rounded Clamped +powx2323 power 10 -400 -> 0E-398 Subnormal Underflow Inexact Rounded Clamped + +-- Independent sanity check: 1961 Godfrey & Siddons four-figure logs +powx2351 power 10 0.0000 -> 1 +powx2352 power 10 0.3010 -> 1.999861869632744 Inexact Rounded +powx2353 power 10 0.4771 -> 2.999853181190793 Inexact Rounded +powx2354 power 10 0.6021 -> 4.000368510461250 Inexact Rounded +powx2355 power 10 0.6990 -> 5.000345349769785 Inexact Rounded +powx2356 power 10 0.7782 -> 6.000673538641164 Inexact Rounded +powx2357 power 10 0.8451 -> 7.000031591308969 Inexact Rounded +powx2358 power 10 0.9031 -> 8.000184448550990 Inexact Rounded +powx2359 power 10 0.9542 -> 8.999119108700520 Inexact Rounded +powx2360 power 10 0.9956 -> 9.899197750805841 Inexact Rounded +powx2361 power 10 0.9996 -> 9.990793899844618 Inexact Rounded +precision: 4 +powx2371 power 10 0.0000 -> 1 +powx2372 power 10 0.3010 -> 2.000 Inexact Rounded +powx2373 power 10 0.4771 -> 3.000 Inexact Rounded +powx2374 power 10 0.6021 -> 4.000 Inexact Rounded +powx2375 power 10 0.6990 -> 5.000 Inexact Rounded +powx2376 power 10 0.7782 -> 6.001 Inexact Rounded +powx2377 power 10 0.8451 -> 7.000 Inexact Rounded +powx2378 power 10 0.9031 -> 8.000 Inexact Rounded +powx2379 power 10 0.9542 -> 8.999 Inexact Rounded +powx2380 power 10 0.9956 -> 9.899 Inexact Rounded +powx2381 power 10 0.9996 -> 9.991 Inexact Rounded + +-- 10**x ~=2 (inverse of the test in log10.decTest) +precision: 50 +powx2401 power 10 0.30102999566398119521373889472449302676818988146211 -> 2.0000000000000000000000000000000000000000000000000 Inexact Rounded +precision: 49 +powx2402 power 10 0.3010299956639811952137388947244930267681898814621 -> 2.000000000000000000000000000000000000000000000000 Inexact Rounded +precision: 48 +powx2403 power 10 0.301029995663981195213738894724493026768189881462 -> 2.00000000000000000000000000000000000000000000000 Inexact Rounded +precision: 47 +powx2404 power 10 0.30102999566398119521373889472449302676818988146 -> 2.0000000000000000000000000000000000000000000000 Inexact Rounded +precision: 46 +powx2405 power 10 0.3010299956639811952137388947244930267681898815 -> 2.000000000000000000000000000000000000000000000 Inexact Rounded +precision: 45 +powx2406 power 10 0.301029995663981195213738894724493026768189881 -> 2.00000000000000000000000000000000000000000000 Inexact Rounded +precision: 44 +powx2407 power 10 0.30102999566398119521373889472449302676818988 -> 2.0000000000000000000000000000000000000000000 Inexact Rounded +precision: 43 +powx2408 power 10 0.3010299956639811952137388947244930267681899 -> 2.000000000000000000000000000000000000000000 Inexact Rounded +precision: 42 +powx2409 power 10 0.301029995663981195213738894724493026768190 -> 2.00000000000000000000000000000000000000000 Inexact Rounded +precision: 41 +powx2410 power 10 0.30102999566398119521373889472449302676819 -> 2.0000000000000000000000000000000000000000 Inexact Rounded +precision: 40 +powx2411 power 10 0.3010299956639811952137388947244930267682 -> 2.000000000000000000000000000000000000000 Inexact Rounded +precision: 39 +powx2412 power 10 0.301029995663981195213738894724493026768 -> 2.00000000000000000000000000000000000000 Inexact Rounded +precision: 38 +powx2413 power 10 0.30102999566398119521373889472449302677 -> 2.0000000000000000000000000000000000000 Inexact Rounded +precision: 37 +powx2414 power 10 0.3010299956639811952137388947244930268 -> 2.000000000000000000000000000000000000 Inexact Rounded +precision: 36 +powx2415 power 10 0.301029995663981195213738894724493027 -> 2.00000000000000000000000000000000000 Inexact Rounded +precision: 35 +powx2416 power 10 0.30102999566398119521373889472449303 -> 2.0000000000000000000000000000000000 Inexact Rounded +precision: 34 +powx2417 power 10 0.3010299956639811952137388947244930 -> 2.000000000000000000000000000000000 Inexact Rounded +precision: 33 +powx2418 power 10 0.301029995663981195213738894724493 -> 2.00000000000000000000000000000000 Inexact Rounded +precision: 32 +powx2419 power 10 0.30102999566398119521373889472449 -> 2.0000000000000000000000000000000 Inexact Rounded +precision: 31 +powx2420 power 10 0.3010299956639811952137388947245 -> 2.000000000000000000000000000000 Inexact Rounded +precision: 30 +powx2421 power 10 0.301029995663981195213738894725 -> 2.00000000000000000000000000000 Inexact Rounded +precision: 29 +powx2422 power 10 0.30102999566398119521373889472 -> 2.0000000000000000000000000000 Inexact Rounded +precision: 28 +powx2423 power 10 0.3010299956639811952137388947 -> 2.000000000000000000000000000 Inexact Rounded +precision: 27 +powx2424 power 10 0.301029995663981195213738895 -> 2.00000000000000000000000000 Inexact Rounded +precision: 26 +powx2425 power 10 0.30102999566398119521373889 -> 2.0000000000000000000000000 Inexact Rounded +precision: 25 +powx2426 power 10 0.3010299956639811952137389 -> 2.000000000000000000000000 Inexact Rounded +precision: 24 +powx2427 power 10 0.301029995663981195213739 -> 2.00000000000000000000000 Inexact Rounded +precision: 23 +powx2428 power 10 0.30102999566398119521374 -> 2.0000000000000000000000 Inexact Rounded +precision: 22 +powx2429 power 10 0.3010299956639811952137 -> 2.000000000000000000000 Inexact Rounded +precision: 21 +powx2430 power 10 0.301029995663981195214 -> 2.00000000000000000000 Inexact Rounded +precision: 20 +powx2431 power 10 0.30102999566398119521 -> 2.0000000000000000000 Inexact Rounded +precision: 19 +powx2432 power 10 0.3010299956639811952 -> 2.000000000000000000 Inexact Rounded +precision: 18 +powx2433 power 10 0.301029995663981195 -> 2.00000000000000000 Inexact Rounded +precision: 17 +powx2434 power 10 0.30102999566398120 -> 2.0000000000000000 Inexact Rounded +precision: 16 +powx2435 power 10 0.3010299956639812 -> 2.000000000000000 Inexact Rounded +precision: 15 +powx2436 power 10 0.301029995663981 -> 2.00000000000000 Inexact Rounded +precision: 14 +powx2437 power 10 0.30102999566398 -> 2.0000000000000 Inexact Rounded +precision: 13 +powx2438 power 10 0.3010299956640 -> 2.000000000000 Inexact Rounded +precision: 12 +powx2439 power 10 0.301029995664 -> 2.00000000000 Inexact Rounded +precision: 11 +powx2440 power 10 0.30102999566 -> 2.0000000000 Inexact Rounded +precision: 10 +powx2441 power 10 0.3010299957 -> 2.000000000 Inexact Rounded +precision: 9 +powx2442 power 10 0.301029996 -> 2.00000000 Inexact Rounded +precision: 8 +powx2443 power 10 0.30103000 -> 2.0000000 Inexact Rounded +precision: 7 +powx2444 power 10 0.3010300 -> 2.000000 Inexact Rounded +precision: 6 +powx2445 power 10 0.301030 -> 2.00000 Inexact Rounded +precision: 5 +powx2446 power 10 0.30103 -> 2.0000 Inexact Rounded +precision: 4 +powx2447 power 10 0.3010 -> 2.000 Inexact Rounded +precision: 3 +powx2448 power 10 0.301 -> 2.00 Inexact Rounded +precision: 2 +powx2449 power 10 0.30 -> 2.0 Inexact Rounded +precision: 1 +powx2450 power 10 0.3 -> 2 Inexact Rounded + +maxExponent: 384 +minExponent: -383 +precision: 16 +rounding: half_even + +-- Close-to-e tests +precision: 34 +powx2500 power 10 0.4342944819032518276511289189166048 -> 2.718281828459045235360287471352661 Inexact Rounded +powx2501 power 10 0.4342944819032518276511289189166049 -> 2.718281828459045235360287471352661 Inexact Rounded +powx2502 power 10 0.4342944819032518276511289189166050 -> 2.718281828459045235360287471352662 Inexact Rounded +powx2503 power 10 0.4342944819032518276511289189166051 -> 2.718281828459045235360287471352663 Inexact Rounded +powx2504 power 10 0.4342944819032518276511289189166052 -> 2.718281828459045235360287471352663 Inexact Rounded + +-- e**e, 16->34 +powx2505 power 2.718281828459045 2.718281828459045 -> '15.15426224147925705633739513098219' Inexact Rounded + +-- Sequence around an integer +powx2512 power 10 2.9999999999999999999999999999999997 -> 999.9999999999999999999999999999993 Inexact Rounded +powx2513 power 10 2.9999999999999999999999999999999998 -> 999.9999999999999999999999999999995 Inexact Rounded +powx2514 power 10 2.9999999999999999999999999999999999 -> 999.9999999999999999999999999999998 Inexact Rounded +powx2515 power 10 3.0000000000000000000000000000000000 -> 1000 +powx2516 power 10 3.0000000000000000000000000000000001 -> 1000.000000000000000000000000000000 Inexact Rounded +powx2517 power 10 3.0000000000000000000000000000000002 -> 1000.000000000000000000000000000000 Inexact Rounded +powx2518 power 10 3.0000000000000000000000000000000003 -> 1000.000000000000000000000000000001 Inexact Rounded + +-- randomly generated tests +maxExponent: 384 +minExponent: -383 + +-- P=34, within 0-999 -- positive arg2 +Precision: 34 +powx3201 power 5.301557744131969249145904611290735 369.3175647984435534243813466380579 -> 3.427165676345688240023113326603960E+267 Inexact Rounded +powx3202 power 0.0000000000506875655819165973738225 21.93514102704466434121826965196878 -> 1.498169860033487321566659495340789E-226 Inexact Rounded +powx3203 power 97.88877680721519917858007810494043 5.159898445242793470476673109899554 -> 18705942904.43290467281449559427982 Inexact Rounded +powx3204 power 7.380441015594399747973924380493799 17.93614173904818313507525109033288 -> 3715757985820076.273336082702577274 Inexact Rounded +powx3205 power 2.045623627647350918819219169855040 1082.999652407430697958175966996254 -> 4.208806435006704867447150904279854E+336 Inexact Rounded +powx3206 power 0.0000000762582873112118926142955423 20.30534237055073996975203864170432 -> 2.967574278677013090697130349198877E-145 Inexact Rounded +powx3207 power 0.0000000000194091470907814855660535 14.71164213947722238856835440242911 -> 2.564391397469554735037158345963280E-158 Inexact Rounded +powx3208 power 0.0000000000509434185382818596853504 20.97051498204188277347203735421595 -> 1.420157372748083000927138678417272E-216 Inexact Rounded +powx3209 power 0.0005389217212073307301395750745119 43.96798225485747315858678755538971 -> 1.957850185781292007977898626137240E-144 Inexact Rounded +powx3210 power 498.5690105989136050444077447411198 128.1038813807243375878831104745803 -> 3.882212970903893127009102293596268E+345 Inexact Rounded +powx3211 power 0.0000000935428918637303954281938975 5.736933454863278597460091596496099 -> 4.733219644540496152403967823635195E-41 Inexact Rounded +powx3212 power 8.581586784734161309180363110126352 252.0229459968869784643374981477208 -> 1.907464842458674622356177850049873E+235 Inexact Rounded +powx3213 power 294.1005302951621709143320795278305 155.5466374141708615975111014663722 -> 9.251717033292072959166737280729728E+383 Inexact Rounded +powx3214 power 0.0000000041253343654396865855722090 19.00170974760425576247662125110472 -> 4.779566288553864405790921353593512E-160 Inexact Rounded +powx3215 power 0.0000000000046912257352141395184092 24.66089523148729269098773236636878 -> 4.205126874048597849476723538057527E-280 Inexact Rounded +powx3216 power 0.0000000000036796674296520639450494 22.09713956900694689234335912523078 -> 2.173081843837539818472071316420405E-253 Inexact Rounded +powx3217 power 9.659887100303037657934372148567685 277.3765665424320875993026404492216 -> 1.614974043145519382749740616665041E+273 Inexact Rounded +powx3218 power 0.0000083231310642229204398943076403 29.33123211782131466471359128190372 -> 1.013330439786660210757226597785328E-149 Inexact Rounded +powx3219 power 0.0938084859086450954956863725653664 262.6091918199905272837286784975012 -> 1.262802485286301066967555821509344E-270 Inexact Rounded +powx3220 power 8.194926977580900145696305910223304 184.3705133945546202012995485297248 -> 2.696353910907824016690021495828584E+168 Inexact Rounded +powx3221 power 72.39594594653085161522285114566120 168.7721909489321402152033939836725 -> 7.379858293630460043361584410795031E+313 Inexact Rounded +powx3222 power 0.0000000000003436856010144185445537 26.34329868961274988994452526178983 -> 4.585379573595865689605567720192768E-329 Inexact Rounded +powx3223 power 20.18365633762226550254542489492623 127.2099705237021350103678072707790 -> 1.020919629336979353690271762206060E+166 Inexact Rounded +powx3224 power 0.0000000553723990761530290129268131 8.157597566134754638015199501162405 -> 6.349030513396147480954474615067145E-60 Inexact Rounded +powx3225 power 0.0001028742674265840656614682618035 93.99842317306603797965470281716482 -> 1.455871110222736531854990397769940E-375 Inexact Rounded +powx3226 power 95.90195152775543876489746343266050 143.5992850002211509777720799352475 -> 3.881540015848530405189834366588567E+284 Inexact Rounded +powx3227 power 0.0000000000041783747057233878360333 12.14591167764993506821334760954430 -> 6.190998557456885985124592807383163E-139 Inexact Rounded +powx3228 power 0.5572830497086740798434917090018768 1001.921811263919522230330241349166 -> 3.871145158537170450093833881625838E-255 Inexact Rounded +powx3229 power 516.4754759779093954790813881333232 29.23812463126309057800793645336343 -> 2.110986192408878294012450052929185E+79 Inexact Rounded +powx3230 power 0.0000835892099464584776847299020706 27.64279992884843877453592659341588 -> 1.891535098905506689512376224943293E-113 Inexact Rounded +powx3231 power 72.45836577748571838139900165184955 166.2562890735032545091688015160084 -> 1.784091549041561516923092542939141E+309 Inexact Rounded +powx3232 power 305.1823317643335924007629563009032 83.01065159508472884219290136319623 -> 1.757493136164395229602456782779110E+206 Inexact Rounded +powx3233 power 7.108527102951713603542835791733786 145.7057852766236365450463428821948 -> 1.285934774113104362663619896550528E+124 Inexact Rounded +powx3234 power 6.471393503175464828149365697049824 64.11741937262455725284754171995720 -> 9.978990355881803195280027533011699E+51 Inexact Rounded +powx3235 power 39.72898094138459885662380866268385 239.9677288017447400786672779735168 -> 5.422218208517098335832848487375086E+383 Inexact Rounded +powx3236 power 0.0002865592332736973000183287329933 90.34733869590583787065642532641096 -> 8.293733126976212033209243257136796E-321 Inexact Rounded +powx3237 power 0.0000011343384394864811195077357936 1.926568285528399656789140809399396 -> 3.516055639378350146874261077470142E-12 Inexact Rounded +powx3238 power 0.0000000035321610295065299384889224 7.583861778824284092434085265265582 -> 7.970899823817369764381976286536230E-65 Inexact Rounded +powx3239 power 657.5028301569352677543770758346683 90.55778453811965116200206020172758 -> 1.522530898581564200655160665723268E+255 Inexact Rounded +powx3240 power 8.484756398325748879450577520251447 389.7468292476262478578280531222417 -> 8.595142803587368093392510310811218E+361 Inexact Rounded + +-- P=16, within 0-99 -- positive arg2 +Precision: 16 +powx3101 power 0.0000215524639223 48.37532522355252 -> 1.804663257287277E-226 Inexact Rounded +powx3102 power 00.80705856227999 2706.777535121391 -> 1.029625065876157E-252 Inexact Rounded +powx3103 power 3.445441676383689 428.5185892455830 -> 1.657401683096454E+230 Inexact Rounded +powx3104 power 0.0040158689495826 159.5725558816240 -> 4.255743665762492E-383 Inexact Rounded +powx3105 power 0.0000841553281215 38.32504413453944 -> 6.738653902512052E-157 Inexact Rounded +powx3106 power 0.7322610252571353 502.1254457674118 -> 1.109978126985943E-68 Inexact Rounded +powx3107 power 10.75052532144880 67.34180604734781 -> 2.873015019470189E+69 Inexact Rounded +powx3108 power 26.20425952945617 104.6002671186488 -> 2.301859355777030E+148 Inexact Rounded +powx3109 power 0.0000055737473850 31.16285859005424 -> 1.883348470100446E-164 Inexact Rounded +powx3110 power 61.06096011360700 10.93608439088726 -> 3.382686473028249E+19 Inexact Rounded +powx3111 power 9.340880853257137 179.9094938131726 -> 3.819299795937696E+174 Inexact Rounded +powx3112 power 0.0000050767371756 72.03346394186741 -> 4.216236691569869E-382 Inexact Rounded +powx3113 power 6.838478807860596 47.49665590602285 -> 4.547621630099203E+39 Inexact Rounded +powx3114 power 0.1299324346439081 397.7440523576938 -> 3.065047705553981E-353 Inexact Rounded +powx3115 power 0.0003418047034264 20.00516791512018 -> 4.546189665380487E-70 Inexact Rounded +powx3116 power 0.0001276899611715 78.12968287355703 -> 5.960217405063995E-305 Inexact Rounded +powx3117 power 25.93160588180509 252.6245071004620 -> 1.472171597589146E+357 Inexact Rounded +powx3118 power 35.47516857763178 86.14723037360925 -> 3.324299908481125E+133 Inexact Rounded +powx3119 power 0.0000048171086721 43.31965603038666 -> 4.572331516616228E-231 Inexact Rounded +powx3120 power 17.97652681097851 144.4684576550292 -> 1.842509906097860E+181 Inexact Rounded +powx3121 power 3.622765141518729 305.1948680344950 -> 4.132320967578704E+170 Inexact Rounded +powx3122 power 0.0080959002453519 143.9899444945627 -> 6.474627812947047E-302 Inexact Rounded +powx3123 power 9.841699927276571 299.2466668837188 -> 1.489097656208736E+297 Inexact Rounded +powx3124 power 0.0786659206232355 347.4750796962570 -> 2.05764809646925E-384 Inexact Rounded Underflow Subnormal +powx3125 power 0.0000084459792645 52.47348690745487 -> 6.076251876516942E-267 Inexact Rounded +powx3126 power 27.86589909967504 191.7296537102283 -> 1.157064112989386E+277 Inexact Rounded +powx3127 power 0.0000419907937234 58.44957702730767 -> 1.496950672075162E-256 Inexact Rounded +powx3128 power 0.0000664977739382 80.06749213261876 -> 3.488517620107875E-335 Inexact Rounded +powx3129 power 58.49554484886656 125.8480768373499 -> 2.449089862146640E+222 Inexact Rounded +powx3130 power 15.02820060024449 212.3527988973338 -> 8.307913932682067E+249 Inexact Rounded +powx3131 power 0.0002650089942992 30.92173123678761 -> 2.517827664836147E-111 Inexact Rounded +powx3132 power 0.0007342977426578 69.49168880741123 -> 1.600168665674440E-218 Inexact Rounded +powx3133 power 0.0063816068650629 150.1400094183812 -> 2.705057295799001E-330 Inexact Rounded +powx3134 power 9.912921122728791 297.8274013633411 -> 4.967624993438900E+296 Inexact Rounded +powx3135 power 1.988603563989245 768.4862967922182 -> 2.692842474899596E+229 Inexact Rounded +powx3136 power 8.418014519517691 164.2431359980725 -> 9.106211585888836E+151 Inexact Rounded +powx3137 power 6.068823604450686 120.2955212365837 -> 1.599431918105982E+94 Inexact Rounded +powx3138 power 56.90062738303850 54.90468294683645 -> 2.312839177902428E+96 Inexact Rounded +powx3139 power 5.710905139750871 73.44608752962156 -> 3.775876053709929E+55 Inexact Rounded +powx3140 power 0.0000017446761203 1.223981492228899 -> 8.952936595465635E-8 Inexact Rounded + +-- P=7, within 0-9 -- positive arg2 +Precision: 7 +powx3001 power 8.738689 55.96523 -> 4.878180E+52 Inexact Rounded +powx3002 power 0.0404763 147.4965 -> 3.689722E-206 Inexact Rounded +powx3003 power 0.0604232 76.69778 -> 3.319183E-94 Inexact Rounded +powx3004 power 0.0058855 107.5018 -> 1.768875E-240 Inexact Rounded +powx3005 power 2.058302 1173.050 -> 5.778899E+367 Inexact Rounded +powx3006 power 0.0056998 85.70157 -> 4.716783E-193 Inexact Rounded +powx3007 power 0.8169297 3693.537 -> 4.475962E-325 Inexact Rounded +powx3008 power 0.2810153 659.9568 -> 1.533177E-364 Inexact Rounded +powx3009 power 4.617478 15.68308 -> 2.629748E+10 Inexact Rounded +powx3010 power 0.0296418 244.2302 -> 6.207949E-374 Inexact Rounded +powx3011 power 0.0036456 127.9987 -> 8.120891E-313 Inexact Rounded +powx3012 power 0.5012813 577.5418 -> 6.088802E-174 Inexact Rounded +powx3013 power 0.0033275 119.9800 -> 5.055049E-298 Inexact Rounded +powx3014 power 0.0037652 111.7092 -> 1.560351E-271 Inexact Rounded +powx3015 power 0.6463252 239.0568 -> 4.864564E-46 Inexact Rounded +powx3016 power 4.784378 475.0521 -> 8.964460E+322 Inexact Rounded +powx3017 power 4.610305 563.1791 -> 6.290298E+373 Inexact Rounded +powx3018 power 0.0175167 80.52208 -> 3.623472E-142 Inexact Rounded +powx3019 power 5.238307 356.7944 -> 4.011461E+256 Inexact Rounded +powx3020 power 0.0003527 96.26347 -> 4.377932E-333 Inexact Rounded +powx3021 power 0.0015155 136.0516 -> 2.57113E-384 Inexact Rounded Underflow Subnormal +powx3022 power 5.753573 273.2340 -> 4.373184E+207 Inexact Rounded +powx3023 power 7.778665 332.7917 -> 3.060640E+296 Inexact Rounded +powx3024 power 1.432479 2046.064 -> 2.325829E+319 Inexact Rounded +powx3025 power 5.610516 136.4563 -> 1.607502E+102 Inexact Rounded +powx3026 power 0.0050697 137.4513 -> 3.522315E-316 Inexact Rounded +powx3027 power 5.678737 85.16253 -> 1.713909E+64 Inexact Rounded +powx3028 power 0.0816167 236.1973 -> 9.228802E-258 Inexact Rounded +powx3029 power 0.2602805 562.0157 -> 2.944556E-329 Inexact Rounded +powx3030 power 0.0080936 24.25367 -> 1.839755E-51 Inexact Rounded +powx3031 power 4.092016 82.94603 -> 5.724948E+50 Inexact Rounded +powx3032 power 0.0078255 7.204184 -> 6.675342E-16 Inexact Rounded +powx3033 power 0.9917693 29846.44 -> 7.430177E-108 Inexact Rounded +powx3034 power 1.610380 301.2467 -> 2.170142E+62 Inexact Rounded +powx3035 power 0.0588236 212.1097 -> 1.023196E-261 Inexact Rounded +powx3036 power 2.498069 531.4647 -> 2.054561E+211 Inexact Rounded +powx3037 power 9.964342 326.5438 -> 1.089452E+326 Inexact Rounded +powx3038 power 0.0820626 268.8718 -> 1.107350E-292 Inexact Rounded +powx3039 power 6.176486 360.7779 -> 1.914449E+285 Inexact Rounded +powx3040 power 4.206363 16.17288 -> 1.231314E+10 Inexact Rounded + +-- P=34, within 0-999 -- negative arg2 +Precision: 34 +powx3701 power 376.0915270000109486633402827007902 -35.69822349904102131649243701958463 -> 1.165722831225506457828653413200143E-92 Inexact Rounded +powx3702 power 0.0000000503747440074613191665845314 -9.520308341497979093021813571450575 -> 3.000432478861883953977971226770410E+69 Inexact Rounded +powx3703 power 290.6858731495339778337953407938308 -118.5459048597789693292455673428367 -> 9.357969047113989238392527565200302E-293 Inexact Rounded +powx3704 power 4.598864607620052062908700928454182 -299.8323667698931125720218537483753 -> 2.069641269855413539579128114448478E-199 Inexact Rounded +powx3705 power 2.556952676986830645708349254938903 -425.1755373251941383147998924703593 -> 4.428799777833598654260883861514638E-174 Inexact Rounded +powx3706 power 0.0000005656198763404221986640610118 -32.83361380678301321230028730075315 -> 1.340270622401829145968477601029251E+205 Inexact Rounded +powx3707 power 012.4841978642452960750801410372125 -214.3734291828712962809866663321921 -> 9.319857751170603140459057535971202E-236 Inexact Rounded +powx3708 power 0.0000000056041586148066919174315551 -37.21129049213858341528033343116533 -> 1.118345010652454313186702341873169E+307 Inexact Rounded +powx3709 power 0.0694569218941833767199998804202152 -8.697509072368973932501239815677732 -> 11862866995.51026489032838174290271 Inexact Rounded +powx3710 power 6.380984024259450398729243522354144 -451.0635696889193561457985486366827 -> 8.800353109387322474809325670314330E-364 Inexact Rounded +powx3711 power 786.0264840756809048288007204917801 -43.09935384678762773057342161718540 -> 1.616324183365644133979585419925934E-125 Inexact Rounded +powx3712 power 96.07836427113204744101287948445130 -185.1414572546330024388914720271876 -> 8.586320815218383004023264980018610E-368 Inexact Rounded +powx3713 power 0.0000000002332189796855870659792406 -5.779561613164628076880609893753327 -> 4.678450775876385793618570483345066E+55 Inexact Rounded +powx3714 power 0.7254146672024602242369943237968857 -2115.512891397828615710130092245691 -> 8.539080958041689288202111403102495E+294 Inexact Rounded +powx3715 power 0.0017380543649702864796144008592137 -6.307668017761022788220578633538713 -> 256309141459075651.2275798017695017 Inexact Rounded +powx3716 power 05.29498758952276908267649116142379 -287.3233896734103442991981056134167 -> 1.039130027847489364009368608104291E-208 Inexact Rounded +powx3717 power 15.64403593865932622003462779104178 -110.5296633358063267478609032002475 -> 9.750540276026524527375125980296142E-133 Inexact Rounded +powx3718 power 89.69639006761571087634945077373508 -181.3209914139357665609268339422627 -> 8.335034232277762924539395632025281E-355 Inexact Rounded +powx3719 power 6.974087483731006359914914110135058 -174.6815625746710345173615508179842 -> 4.553072265122011176641590109568031E-148 Inexact Rounded +powx3720 power 0.0034393024010554821130553772681993 -93.60931598413919272595497100497364 -> 4.067468855817145539589988349449394E+230 Inexact Rounded +powx3721 power 63.32834072300379155053737260965633 -168.3926799435088324825751446957616 -> 4.207907835462640471617519501741094E-304 Inexact Rounded +powx3722 power 00.00216088174206276369011255907785 -70.12279562855442784757874508991013 -> 8.000657143378187029609343435067057E+186 Inexact Rounded +powx3723 power 934.5957982703545893572134393004375 -102.2287735565878252484031426026726 -> 2.073813769209257617246544424827240E-304 Inexact Rounded +powx3724 power 107.9116792558793921873995885441177 -44.11941092260869786313838181499158 -> 2.005476533631183268912552168759595E-90 Inexact Rounded +powx3725 power 0.0000000000188049827381428191769262 -19.32118917192242027966847501724073 -> 1.713174297100918857053338286389034E+207 Inexact Rounded +powx3726 power 614.9820907366248142166636259027728 -4.069913257030791586645250035698123 -> 4.462432572576935752713876293746717E-12 Inexact Rounded +powx3727 power 752.0655175769182096165651274049422 -22.59292060348797472013598378334370 -> 1.039881526694635205040192531504131E-65 Inexact Rounded +powx3728 power 72.20446632047659449616175456059013 -175.4705356401853924020842356605072 -> 7.529540175791582421966947814549028E-327 Inexact Rounded +powx3729 power 518.8346486600403405764055847937416 -65.87320268592761588756963215588232 -> 1.420189426992170936958891180073151E-179 Inexact Rounded +powx3730 power 3.457164372003960576453458502270716 -440.3201118177861273814529713443698 -> 6.176418595751201287186292664257369E-238 Inexact Rounded +powx3731 power 7.908352793344189720739467675503991 -298.6646112894719680394152664740255 -> 5.935857120229147638104675057695125E-269 Inexact Rounded +powx3732 power 0.0000004297399403788595027926075086 -22.66504617185071293588817501468339 -> 2.012270405520600820469665145636204E+144 Inexact Rounded +powx3733 power 0.0000008592124097322966354868716443 -9.913109586558030204789520190180906 -> 1.354958763843310237046818832755215E+60 Inexact Rounded +powx3734 power 161.4806080561258105880907470989925 -70.72907837434814261716311990271578 -> 6.632555003698945544941329872901929E-157 Inexact Rounded +powx3735 power 0.0000000090669568624173832705631918 -36.53759624613665940127058439106640 -> 7.161808401023414735428130112941559E+293 Inexact Rounded +powx3736 power 0.0000000000029440295978365709342752 -1.297354238738921988884421117731562 -> 911731060579291.7661267358872917380 Inexact Rounded +powx3737 power 21.37477220144832172175460425143692 -76.95949933640539226475686997477889 -> 4.481741242418091914011962399912885E-103 Inexact Rounded +powx3738 power 0.0000000000186657798201636342150903 -20.18296240350678245567049161730909 -> 3.483954007114900406906338526575672E+216 Inexact Rounded +powx3739 power 0.0006522464792960191985996959126792 -80.03762491483514679886504099194414 -> 9.266548513614215557228467517053035E+254 Inexact Rounded +powx3740 power 0.0000000032851343694200568966168055 -21.53462116926375512242403160008026 -> 4.873201679668455240861376213601189E+182 Inexact Rounded + +-- P=16, within 0-99 -- negative arg2 +Precision: 16 +powx3601 power 0.0000151338748474 -40.84655618364688 -> 7.628470824137755E+196 Inexact Rounded +powx3602 power 0.1542771848654862 -435.8830009466800 -> 6.389817177800744E+353 Inexact Rounded +powx3603 power 48.28477749367364 -218.5929209902050 -> 8.531049532576154E-369 Inexact Rounded +powx3604 power 7.960775891584911 -12.78113732182505 -> 3.053270889769488E-12 Inexact Rounded +powx3605 power 0.9430340651863058 -9010.470056913748 -> 3.313374654923807E+229 Inexact Rounded +powx3606 power 0.0000202661501602 -65.57915207383306 -> 5.997379176536464E+307 Inexact Rounded +powx3607 power 04.33007440798390 -232.0476834666588 -> 2.007827183010456E-148 Inexact Rounded +powx3608 power 0.0000141944643914 -11.32407921958717 -> 7.902934485074846E+54 Inexact Rounded +powx3609 power 0.0000021977758261 -53.53706138253307 -> 8.195631772317815E+302 Inexact Rounded +powx3610 power 39.51297655474188 -19.40370976012326 -> 1.040699608072659E-31 Inexact Rounded +powx3611 power 38.71210232488775 -66.58341618227921 -> 1.886855066146495E-106 Inexact Rounded +powx3612 power 0.0000804235229062 -6.715207948992859 -> 3.134757864389333E+27 Inexact Rounded +powx3613 power 0.0000073547092399 -11.27725685719934 -> 7.781428390953695E+57 Inexact Rounded +powx3614 power 52.72181272599316 -186.1422311607435 -> 2.916601998744177E-321 Inexact Rounded +powx3615 power 0.0969519963083306 -280.8220862151369 -> 3.955906885970987E+284 Inexact Rounded +powx3616 power 94.07263302150081 -148.2031146071230 -> 3.361958990752490E-293 Inexact Rounded +powx3617 power 85.80286965053704 -90.21453695813759 -> 3.715602429645798E-175 Inexact Rounded +powx3618 power 03.52699858152259 -492.0414362539196 -> 4.507309220081092E-270 Inexact Rounded +powx3619 power 0.0508278086396068 -181.0871731572167 -> 2.034428013017949E+234 Inexact Rounded +powx3620 power 0.395576740303172 -915.5524507432392 -> 5.706585187437578E+368 Inexact Rounded +powx3621 power 38.06105826789202 -49.75913753435335 -> 2.273188991431738E-79 Inexact Rounded +powx3622 power 0.0003656748910646 -73.28988491310354 -> 7.768936940568763E+251 Inexact Rounded +powx3623 power 0.0000006373551809 -51.30825234200690 -> 7.697618167701985E+317 Inexact Rounded +powx3624 power 82.41729920673856 -35.73319631625699 -> 3.424042354585529E-69 Inexact Rounded +powx3625 power 0.7845821453127670 -971.4982028897663 -> 2.283415527661089E+102 Inexact Rounded +powx3626 power 4.840983673433497 -182.3730452370515 -> 1.220591407927770E-125 Inexact Rounded +powx3627 power 0.0000006137592139 -2.122139474431484 -> 15231217034839.29 Inexact Rounded +powx3628 power 0.0003657962862984 -35.97993782448099 -> 4.512701319250839E+123 Inexact Rounded +powx3629 power 40.93693004443150 -165.1362408792997 -> 6.044276411057239E-267 Inexact Rounded +powx3630 power 0.2941552583028898 -17.41046264945892 -> 1787833103.503346 Inexact Rounded +powx3631 power 63.99335135369977 -69.92417205168579 -> 5.099359804872509E-127 Inexact Rounded +powx3632 power 0.0000657924467388 -89.14497293588313 -> 6.145878266688521E+372 Inexact Rounded +powx3633 power 11.35071250339147 -323.3705865614542 -> 6.863626248766775E-342 Inexact Rounded +powx3634 power 23.88024718470895 -277.7117513329510 -> 2.006441422612815E-383 Inexact Rounded +powx3635 power 0.0000009111939914 -58.51782946929182 -> 2.954352883996773E+353 Inexact Rounded +powx3636 power 0.0000878179048782 -75.81060420238669 -> 3.306878455207585E+307 Inexact Rounded +powx3637 power 07.39190564273779 -287.5047307244636 -> 1.692080354659805E-250 Inexact Rounded +powx3638 power 0.0000298310819799 -1.844740377759355 -> 222874718.7238888 Inexact Rounded +powx3639 power 0.0000006412929384 -28.24850078229290 -> 8.737164230666529E+174 Inexact Rounded +powx3640 power 0.0000010202965998 -47.17573701956498 -> 4.392845306049341E+282 Inexact Rounded + +-- P=7, within 0-9 -- negative arg2 +Precision: 7 +powx3501 power 0.326324 -71.96509 -> 1.000673E+35 Inexact Rounded +powx3502 power 0.0017635 -0.7186967 -> 95.28419 Inexact Rounded +powx3503 power 8.564155 -253.0899 -> 8.850512E-237 Inexact Rounded +powx3504 power 8.987272 -2.155789 -> 0.008793859 Inexact Rounded +powx3505 power 9.604856 -139.9630 -> 3.073492E-138 Inexact Rounded +powx3506 power 0.8472919 -2539.085 -> 5.372686E+182 Inexact Rounded +powx3507 power 5.312329 -60.32965 -> 1.753121E-44 Inexact Rounded +powx3508 power 0.0338294 -100.5440 -> 7.423939E+147 Inexact Rounded +powx3509 power 0.0017777 -130.8583 -> 7.565629E+359 Inexact Rounded +powx3510 power 8.016154 -405.5689 -> 2.395977E-367 Inexact Rounded +powx3511 power 5.016570 -327.8906 -> 2.203784E-230 Inexact Rounded +powx3512 power 0.8161743 -744.5276 -> 4.786899E+65 Inexact Rounded +powx3513 power 0.0666343 -164.7320 -> 5.951240E+193 Inexact Rounded +powx3514 power 0.0803966 -202.2666 -> 2.715512E+221 Inexact Rounded +powx3515 power 0.0014752 -12.55547 -> 3.518905E+35 Inexact Rounded +powx3516 power 9.737565 -14.69615 -> 2.975672E-15 Inexact Rounded +powx3517 power 0.6634172 -152.7308 -> 1.654458E+27 Inexact Rounded +powx3518 power 0.0009337 -33.32939 -> 9.575039E+100 Inexact Rounded +powx3519 power 8.679922 -224.4194 -> 2.392446E-211 Inexact Rounded +powx3520 power 7.390494 -161.9483 -> 2.088375E-141 Inexact Rounded +powx3521 power 0.4631489 -417.1673 -> 2.821106E+139 Inexact Rounded +powx3522 power 0.0095471 -7.677458 -> 3.231855E+15 Inexact Rounded +powx3523 power 6.566339 -176.1867 -> 9.965633E-145 Inexact Rounded +powx3524 power 2.696128 -26.15501 -> 5.419731E-12 Inexact Rounded +powx3525 power 0.4464366 -852.1893 -> 2.957725E+298 Inexact Rounded +powx3526 power 0.4772006 -921.4111 -> 1.118105E+296 Inexact Rounded +powx3527 power 8.923696 -359.2211 -> 3.501573E-342 Inexact Rounded +powx3528 power 0.0018008 -66.91252 -> 4.402718E+183 Inexact Rounded +powx3529 power 0.0811964 -92.83278 -> 1.701111E+101 Inexact Rounded +powx3530 power 0.0711219 -58.94347 -> 4.644148E+67 Inexact Rounded +powx3531 power 7.958121 -50.66123 -> 2.311161E-46 Inexact Rounded +powx3532 power 6.106466 -81.83610 -> 4.943285E-65 Inexact Rounded +powx3533 power 4.557634 -129.5268 -> 4.737917E-86 Inexact Rounded +powx3534 power 0.0027348 -9.180135 -> 3.383524E+23 Inexact Rounded +powx3535 power 0.0083924 -46.24016 -> 9.996212E+95 Inexact Rounded +powx3536 power 2.138523 -47.25897 -> 2.507009E-16 Inexact Rounded +powx3537 power 1.626728 -1573.830 -> 2.668117E-333 Inexact Rounded +powx3538 power 0.082615 -164.5842 -> 1.717882E+178 Inexact Rounded +powx3539 power 7.636003 -363.6763 -> 8.366174E-322 Inexact Rounded +powx3540 power 0.0021481 -138.0065 -> 1.562505E+368 Inexact Rounded + + +-- Invalid operations due to restrictions +-- [next two probably skipped by most test harnesses] +precision: 100000000 +powx4001 power 1 1.1 -> NaN Invalid_context +precision: 99999999 +powx4002 power 1 1.1 -> NaN Invalid_context + +precision: 9 +maxExponent: 1000000 +minExponent: -999999 +powx4003 power 1 1.1 -> NaN Invalid_context +maxExponent: 999999 +minExponent: -999999 +powx4004 power 1 1.1 -> 1.00000000 Inexact Rounded +maxExponent: 999999 +minExponent: -1000000 +powx4005 power 1 1.1 -> NaN Invalid_context +maxExponent: 999999 +minExponent: -999998 +powx4006 power 1 1.1 -> 1.00000000 Inexact Rounded + +-- operand range violations +powx4007 power 1 1.1E+999999 -> 1 +powx4008 power 1 1.1E+1000000 -> NaN Invalid_operation +powx4009 power 1.1E+999999 1.1 -> Infinity Overflow Inexact Rounded +powx4010 power 1.1E+1000000 1.1 -> NaN Invalid_operation +powx4011 power 1 1.1E-1999997 -> 1.00000000 Inexact Rounded +powx4012 power 1 1.1E-1999998 -> NaN Invalid_operation +powx4013 power 1.1E-1999997 1.1 -> 0E-1000006 Underflow Inexact Rounded Clamped Subnormal +powx4014 power 1.1E-1999998 1.1 -> NaN Invalid_operation + +-- rounding modes -- power is sensitive +precision: 7 +maxExponent: 99 +minExponent: -99 + +-- 0.7 ** 3.3 => 0.30819354053418943822 +-- 0.7 ** 3.4 => 0.29739477638272533854 +-- -1.2 ** 17 => -22.18611106740436992 +-- -1.3 ** 17 => -86.50415919381337933 +-- 0.5 ** 11 => 0.00048828125 +-- 3.15 ** 3 => 31.255875 + +rounding: up +powx4100 power 0.7 3.3 -> 0.3081936 Inexact Rounded +powx4101 power 0.7 3.4 -> 0.2973948 Inexact Rounded +powx4102 power -1.2 17 -> -22.18612 Inexact Rounded +powx4103 power -1.3 17 -> -86.50416 Inexact Rounded +powx4104 power 17 81.27115 -> 9.999974E+99 Inexact Rounded +powx4105 power 17 81.27116 -> Infinity Overflow Inexact Rounded + +rounding: down +powx4120 power 0.7 3.3 -> 0.3081935 Inexact Rounded +powx4121 power 0.7 3.4 -> 0.2973947 Inexact Rounded +powx4122 power -1.2 17 -> -22.18611 Inexact Rounded +powx4123 power -1.3 17 -> -86.50415 Inexact Rounded +powx4124 power 17 81.27115 -> 9.999973E+99 Inexact Rounded +powx4125 power 17 81.27116 -> 9.999999E+99 Overflow Inexact Rounded + +rounding: floor +powx4140 power 0.7 3.3 -> 0.3081935 Inexact Rounded +powx4141 power 0.7 3.4 -> 0.2973947 Inexact Rounded +powx4142 power -1.2 17 -> -22.18612 Inexact Rounded +powx4143 power -1.3 17 -> -86.50416 Inexact Rounded +powx4144 power 17 81.27115 -> 9.999973E+99 Inexact Rounded +powx4145 power 17 81.27116 -> 9.999999E+99 Overflow Inexact Rounded + +rounding: ceiling +powx4160 power 0.7 3.3 -> 0.3081936 Inexact Rounded +powx4161 power 0.7 3.4 -> 0.2973948 Inexact Rounded +powx4162 power -1.2 17 -> -22.18611 Inexact Rounded +powx4163 power -1.3 17 -> -86.50415 Inexact Rounded +powx4164 power 17 81.27115 -> 9.999974E+99 Inexact Rounded +powx4165 power 17 81.27116 -> Infinity Overflow Inexact Rounded + +rounding: half_up +powx4180 power 0.7 3.3 -> 0.3081935 Inexact Rounded +powx4181 power 0.7 3.4 -> 0.2973948 Inexact Rounded +powx4182 power -1.2 17 -> -22.18611 Inexact Rounded +powx4183 power -1.3 17 -> -86.50416 Inexact Rounded +powx4184 power 0.5 11 -> 0.0004882813 Inexact Rounded +powx4185 power 3.15 3 -> 31.25588 Inexact Rounded +powx4186 power 17 81.27115 -> 9.999974E+99 Inexact Rounded +powx4187 power 17 81.27116 -> Infinity Overflow Inexact Rounded + +rounding: half_even +powx4200 power 0.7 3.3 -> 0.3081935 Inexact Rounded +powx4201 power 0.7 3.4 -> 0.2973948 Inexact Rounded +powx4202 power -1.2 17 -> -22.18611 Inexact Rounded +powx4203 power -1.3 17 -> -86.50416 Inexact Rounded +powx4204 power 0.5 11 -> 0.0004882812 Inexact Rounded +powx4205 power 3.15 3 -> 31.25588 Inexact Rounded +powx4206 power 17 81.27115 -> 9.999974E+99 Inexact Rounded +powx4207 power 17 81.27116 -> Infinity Overflow Inexact Rounded + +rounding: half_down +powx4220 power 0.7 3.3 -> 0.3081935 Inexact Rounded +powx4221 power 0.7 3.4 -> 0.2973948 Inexact Rounded +powx4222 power -1.2 17 -> -22.18611 Inexact Rounded +powx4223 power -1.3 17 -> -86.50416 Inexact Rounded +powx4224 power 0.5 11 -> 0.0004882812 Inexact Rounded +powx4225 power 3.15 3 -> 31.25587 Inexact Rounded +powx4226 power -3.15 3 -> -31.25587 Inexact Rounded +powx4227 power 17 81.27115 -> 9.999974E+99 Inexact Rounded +powx4228 power 17 81.27116 -> Infinity Overflow Inexact Rounded + + +-- more rounding tests as per Ilan Nehama's suggestions & analysis +-- these are likely to show > 0.5 ulp error for very small powers +precision: 7 +maxExponent: 96 +minExponent: -95 + +-- For x=nextfp(1)=1.00..001 (where the number of 0s is precision-2) +-- power(x,y)=x when the rounding is up (e.g., toward_pos_inf or +-- ceil) for any y in (0,1]. +rounding: ceiling +powx4301 power 1.000001 0 -> 1 +-- The next test should be skipped for decNumber +powx4302 power 1.000001 1e-101 -> 1.000001 Inexact Rounded +-- The next test should be skipped for decNumber +powx4303 power 1.000001 1e-95 -> 1.000001 Inexact Rounded +powx4304 power 1.000001 1e-10 -> 1.000001 Inexact Rounded +powx4305 power 1.000001 0.1 -> 1.000001 Inexact Rounded +powx4306 power 1.000001 0.1234567 -> 1.000001 Inexact Rounded +powx4307 power 1.000001 0.7 -> 1.000001 Inexact Rounded +powx4308 power 1.000001 0.9999999 -> 1.000001 Inexact Rounded +powx4309 power 1.000001 1.000000 -> 1.000001 +-- power(x,y)=1 when the rounding is down (e.g. toward_zero or +-- floor) for any y in [0,1). +rounding: floor +powx4321 power 1.000001 0 -> 1 +powx4322 power 1.000001 1e-101 -> 1.000000 Inexact Rounded +powx4323 power 1.000001 1e-95 -> 1.000000 Inexact Rounded +powx4324 power 1.000001 1e-10 -> 1.000000 Inexact Rounded +powx4325 power 1.000001 0.1 -> 1.000000 Inexact Rounded +powx4326 power 1.000001 0.1234567 -> 1.000000 Inexact Rounded +powx4327 power 1.000001 0.7 -> 1.000000 Inexact Rounded +powx4328 power 1.000001 0.9999999 -> 1.000000 Inexact Rounded +powx4329 power 1.000001 1.000000 -> 1.000001 + +-- For x=prevfp(1)=0.99..99 (where the number of 9s is precision) +-- power(x,y)=x when the rounding is down for any y in (0,1]. +rounding: floor +powx4341 power 0.9999999 0 -> 1 +-- The next test should be skipped for decNumber +powx4342 power 0.9999999 1e-101 -> 0.9999999 Inexact Rounded +-- The next test should be skipped for decNumber +powx4343 power 0.9999999 1e-95 -> 0.9999999 Inexact Rounded +powx4344 power 0.9999999 1e-10 -> 0.9999999 Inexact Rounded +powx4345 power 0.9999999 0.1 -> 0.9999999 Inexact Rounded +powx4346 power 0.9999999 0.1234567 -> 0.9999999 Inexact Rounded +powx4347 power 0.9999999 0.7 -> 0.9999999 Inexact Rounded +powx4348 power 0.9999999 0.9999999 -> 0.9999999 Inexact Rounded +powx4349 power 0.9999999 1.000000 -> 0.9999999 +-- power(x,y)=1 when the rounding is up for any y in (0,1]. +rounding: ceiling +powx4361 power 0.9999999 0 -> 1 +powx4362 power 0.9999999 1e-101 -> 1.000000 Inexact Rounded +powx4363 power 0.9999999 1e-95 -> 1.000000 Inexact Rounded +powx4364 power 0.9999999 1e-10 -> 1.000000 Inexact Rounded +powx4365 power 0.9999999 0.1 -> 1.000000 Inexact Rounded +powx4366 power 0.9999999 0.1234567 -> 1.000000 Inexact Rounded +powx4367 power 0.9999999 0.7 -> 1.000000 Inexact Rounded +powx4368 power 0.9999999 0.9999999 -> 1.000000 Inexact Rounded +powx4369 power 0.9999999 1.000000 -> 0.9999999 + +-- For x=nextfp(0) +-- power(x,y)=0 when the rounding is down for any y larger than 1. +rounding: floor +powx4382 power 1e-101 0 -> 1 +powx4383 power 1e-101 0.9999999 -> 1E-101 Underflow Subnormal Inexact Rounded +powx4384 power 1e-101 1.000000 -> 1E-101 Subnormal +powx4385 power 1e-101 1.000001 -> 0E-101 Underflow Subnormal Inexact Rounded Clamped +powx4386 power 1e-101 2.000000 -> 0E-101 Underflow Subnormal Inexact Rounded Clamped Added: python/branches/release25-maint/Lib/test/decimaltestdata/powersqrt.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/powersqrt.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,2970 @@ +------------------------------------------------------------------------ +-- powersqrt.decTest -- decimal square root, using power -- +-- Copyright (c) IBM Corporation, 2004, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- These testcases are taken from squareroot.decTest but are +-- evaluated using the power operator. The differences in results +-- (153 out of 2856) fall into the following categories: +-- +-- x ** 0.5 (x>0) has no preferred exponent, and is Inexact +-- (and hence full precision); almost all differences are +-- in this category +-- 0.00 ** 0.5 becomes 0 (not 0.0), etc. +-- -0 ** 0.5 becomes 0 (never -0) +-- Some exact subnormals become inexact and hence underflows + +extended: 1 +precision: 9 +rounding: half_even +maxExponent: 384 +minexponent: -383 + +-- basics +pwsx001 power 1 0.5 -> 1.00000000 Inexact Rounded +pwsx002 power -1 0.5 -> NaN Invalid_operation +pwsx003 power 1.00 0.5 -> 1.00000000 Inexact Rounded +pwsx004 power -1.00 0.5 -> NaN Invalid_operation +pwsx005 power 0 0.5 -> 0 +pwsx006 power 00.0 0.5 -> 0 +pwsx007 power 0.00 0.5 -> 0 +pwsx008 power 00.00 0.5 -> 0 +pwsx009 power 00.000 0.5 -> 0 +pwsx010 power 00.0000 0.5 -> 0 +pwsx011 power 00 0.5 -> 0 + +pwsx012 power -2 0.5 -> NaN Invalid_operation +pwsx013 power 2 0.5 -> 1.41421356 Inexact Rounded +pwsx014 power -2.00 0.5 -> NaN Invalid_operation +pwsx015 power 2.00 0.5 -> 1.41421356 Inexact Rounded +pwsx016 power -0 0.5 -> 0 +pwsx017 power -0.0 0.5 -> 0 +pwsx018 power -00.00 0.5 -> 0 +pwsx019 power -00.000 0.5 -> 0 +pwsx020 power -0.0000 0.5 -> 0 +pwsx021 power -0E+9 0.5 -> 0 +pwsx022 power -0E+10 0.5 -> 0 +pwsx023 power -0E+11 0.5 -> 0 +pwsx024 power -0E+12 0.5 -> 0 +pwsx025 power -00 0.5 -> 0 +pwsx026 power 0E+5 0.5 -> 0 +pwsx027 power 4.0 0.5 -> 2.00000000 Inexact Rounded +pwsx028 power 4.00 0.5 -> 2.00000000 Inexact Rounded + +pwsx030 power +0.1 0.5 -> 0.316227766 Inexact Rounded +pwsx031 power -0.1 0.5 -> NaN Invalid_operation +pwsx032 power +0.01 0.5 -> 0.100000000 Inexact Rounded +pwsx033 power -0.01 0.5 -> NaN Invalid_operation +pwsx034 power +0.001 0.5 -> 0.0316227766 Inexact Rounded +pwsx035 power -0.001 0.5 -> NaN Invalid_operation +pwsx036 power +0.000001 0.5 -> 0.00100000000 Inexact Rounded +pwsx037 power -0.000001 0.5 -> NaN Invalid_operation +pwsx038 power +0.000000000001 0.5 -> 0.00000100000000 Inexact Rounded +pwsx039 power -0.000000000001 0.5 -> NaN Invalid_operation + +pwsx041 power 1.1 0.5 -> 1.04880885 Inexact Rounded +pwsx042 power 1.10 0.5 -> 1.04880885 Inexact Rounded +pwsx043 power 1.100 0.5 -> 1.04880885 Inexact Rounded +pwsx044 power 1.110 0.5 -> 1.05356538 Inexact Rounded +pwsx045 power -1.1 0.5 -> NaN Invalid_operation +pwsx046 power -1.10 0.5 -> NaN Invalid_operation +pwsx047 power -1.100 0.5 -> NaN Invalid_operation +pwsx048 power -1.110 0.5 -> NaN Invalid_operation +pwsx049 power 9.9 0.5 -> 3.14642654 Inexact Rounded +pwsx050 power 9.90 0.5 -> 3.14642654 Inexact Rounded +pwsx051 power 9.900 0.5 -> 3.14642654 Inexact Rounded +pwsx052 power 9.990 0.5 -> 3.16069613 Inexact Rounded +pwsx053 power -9.9 0.5 -> NaN Invalid_operation +pwsx054 power -9.90 0.5 -> NaN Invalid_operation +pwsx055 power -9.900 0.5 -> NaN Invalid_operation +pwsx056 power -9.990 0.5 -> NaN Invalid_operation + +pwsx060 power 1 0.5 -> 1.00000000 Inexact Rounded +pwsx061 power 1.0 0.5 -> 1.00000000 Inexact Rounded +pwsx062 power 1.00 0.5 -> 1.00000000 Inexact Rounded +pwsx063 power 10.0 0.5 -> 3.16227766 Inexact Rounded +pwsx064 power 10.0 0.5 -> 3.16227766 Inexact Rounded +pwsx065 power 10.0 0.5 -> 3.16227766 Inexact Rounded +pwsx066 power 10.00 0.5 -> 3.16227766 Inexact Rounded +pwsx067 power 100 0.5 -> 10.0000000 Inexact Rounded +pwsx068 power 100.0 0.5 -> 10.0000000 Inexact Rounded +pwsx069 power 100.00 0.5 -> 10.0000000 Inexact Rounded +pwsx070 power 1.1000E+3 0.5 -> 33.1662479 Inexact Rounded +pwsx071 power 1.10000E+3 0.5 -> 33.1662479 Inexact Rounded +pwsx072 power -10.0 0.5 -> NaN Invalid_operation +pwsx073 power -10.00 0.5 -> NaN Invalid_operation +pwsx074 power -100.0 0.5 -> NaN Invalid_operation +pwsx075 power -100.00 0.5 -> NaN Invalid_operation +pwsx076 power -1.1000E+3 0.5 -> NaN Invalid_operation +pwsx077 power -1.10000E+3 0.5 -> NaN Invalid_operation + +-- famous squares +pwsx080 power 1 0.5 -> 1.00000000 Inexact Rounded +pwsx081 power 4 0.5 -> 2.00000000 Inexact Rounded +pwsx082 power 9 0.5 -> 3.00000000 Inexact Rounded +pwsx083 power 16 0.5 -> 4.00000000 Inexact Rounded +pwsx084 power 25 0.5 -> 5.00000000 Inexact Rounded +pwsx085 power 36 0.5 -> 6.00000000 Inexact Rounded +pwsx086 power 49 0.5 -> 7.00000000 Inexact Rounded +pwsx087 power 64 0.5 -> 8.00000000 Inexact Rounded +pwsx088 power 81 0.5 -> 9.00000000 Inexact Rounded +pwsx089 power 100 0.5 -> 10.0000000 Inexact Rounded +pwsx090 power 121 0.5 -> 11.0000000 Inexact Rounded +pwsx091 power 144 0.5 -> 12.0000000 Inexact Rounded +pwsx092 power 169 0.5 -> 13.0000000 Inexact Rounded +pwsx093 power 256 0.5 -> 16.0000000 Inexact Rounded +pwsx094 power 1024 0.5 -> 32.0000000 Inexact Rounded +pwsx095 power 4096 0.5 -> 64.0000000 Inexact Rounded +pwsx100 power 0.01 0.5 -> 0.100000000 Inexact Rounded +pwsx101 power 0.04 0.5 -> 0.200000000 Inexact Rounded +pwsx102 power 0.09 0.5 -> 0.300000000 Inexact Rounded +pwsx103 power 0.16 0.5 -> 0.400000000 Inexact Rounded +pwsx104 power 0.25 0.5 -> 0.500000000 Inexact Rounded +pwsx105 power 0.36 0.5 -> 0.600000000 Inexact Rounded +pwsx106 power 0.49 0.5 -> 0.700000000 Inexact Rounded +pwsx107 power 0.64 0.5 -> 0.800000000 Inexact Rounded +pwsx108 power 0.81 0.5 -> 0.900000000 Inexact Rounded +pwsx109 power 1.00 0.5 -> 1.00000000 Inexact Rounded +pwsx110 power 1.21 0.5 -> 1.10000000 Inexact Rounded +pwsx111 power 1.44 0.5 -> 1.20000000 Inexact Rounded +pwsx112 power 1.69 0.5 -> 1.30000000 Inexact Rounded +pwsx113 power 2.56 0.5 -> 1.60000000 Inexact Rounded +pwsx114 power 10.24 0.5 -> 3.20000000 Inexact Rounded +pwsx115 power 40.96 0.5 -> 6.40000000 Inexact Rounded + +-- Precision 1 squareroot tests [exhaustive, plus exponent adjusts] +rounding: half_even +maxExponent: 999 +minexponent: -999 +precision: 1 +pwsx1201 power 0.1 0.5 -> 0.3 Inexact Rounded +pwsx1202 power 0.01 0.5 -> 0.1 Inexact Rounded +pwsx1203 power 1.0E-1 0.5 -> 0.3 Inexact Rounded +pwsx1204 power 1.00E-2 0.5 -> 0.1 Inexact Rounded +pwsx1205 power 1E-3 0.5 -> 0.03 Inexact Rounded +pwsx1206 power 1E+1 0.5 -> 3 Inexact Rounded +pwsx1207 power 1E+2 0.5 -> 1E+1 Inexact Rounded +pwsx1208 power 1E+3 0.5 -> 3E+1 Inexact Rounded +pwsx1209 power 0.2 0.5 -> 0.4 Inexact Rounded +pwsx1210 power 0.02 0.5 -> 0.1 Inexact Rounded +pwsx1211 power 2.0E-1 0.5 -> 0.4 Inexact Rounded +pwsx1212 power 2.00E-2 0.5 -> 0.1 Inexact Rounded +pwsx1213 power 2E-3 0.5 -> 0.04 Inexact Rounded +pwsx1214 power 2E+1 0.5 -> 4 Inexact Rounded +pwsx1215 power 2E+2 0.5 -> 1E+1 Inexact Rounded +pwsx1216 power 2E+3 0.5 -> 4E+1 Inexact Rounded +pwsx1217 power 0.3 0.5 -> 0.5 Inexact Rounded +pwsx1218 power 0.03 0.5 -> 0.2 Inexact Rounded +pwsx1219 power 3.0E-1 0.5 -> 0.5 Inexact Rounded +pwsx1220 power 3.00E-2 0.5 -> 0.2 Inexact Rounded +pwsx1221 power 3E-3 0.5 -> 0.05 Inexact Rounded +pwsx1222 power 3E+1 0.5 -> 5 Inexact Rounded +pwsx1223 power 3E+2 0.5 -> 2E+1 Inexact Rounded +pwsx1224 power 3E+3 0.5 -> 5E+1 Inexact Rounded +pwsx1225 power 0.4 0.5 -> 0.6 Inexact Rounded +pwsx1226 power 0.04 0.5 -> 0.2 Inexact Rounded +pwsx1227 power 4.0E-1 0.5 -> 0.6 Inexact Rounded +pwsx1228 power 4.00E-2 0.5 -> 0.2 Inexact Rounded +pwsx1229 power 4E-3 0.5 -> 0.06 Inexact Rounded +pwsx1230 power 4E+1 0.5 -> 6 Inexact Rounded +pwsx1231 power 4E+2 0.5 -> 2E+1 Inexact Rounded +pwsx1232 power 4E+3 0.5 -> 6E+1 Inexact Rounded +pwsx1233 power 0.5 0.5 -> 0.7 Inexact Rounded +pwsx1234 power 0.05 0.5 -> 0.2 Inexact Rounded +pwsx1235 power 5.0E-1 0.5 -> 0.7 Inexact Rounded +pwsx1236 power 5.00E-2 0.5 -> 0.2 Inexact Rounded +pwsx1237 power 5E-3 0.5 -> 0.07 Inexact Rounded +pwsx1238 power 5E+1 0.5 -> 7 Inexact Rounded +pwsx1239 power 5E+2 0.5 -> 2E+1 Inexact Rounded +pwsx1240 power 5E+3 0.5 -> 7E+1 Inexact Rounded +pwsx1241 power 0.6 0.5 -> 0.8 Inexact Rounded +pwsx1242 power 0.06 0.5 -> 0.2 Inexact Rounded +pwsx1243 power 6.0E-1 0.5 -> 0.8 Inexact Rounded +pwsx1244 power 6.00E-2 0.5 -> 0.2 Inexact Rounded +pwsx1245 power 6E-3 0.5 -> 0.08 Inexact Rounded +pwsx1246 power 6E+1 0.5 -> 8 Inexact Rounded +pwsx1247 power 6E+2 0.5 -> 2E+1 Inexact Rounded +pwsx1248 power 6E+3 0.5 -> 8E+1 Inexact Rounded +pwsx1249 power 0.7 0.5 -> 0.8 Inexact Rounded +pwsx1250 power 0.07 0.5 -> 0.3 Inexact Rounded +pwsx1251 power 7.0E-1 0.5 -> 0.8 Inexact Rounded +pwsx1252 power 7.00E-2 0.5 -> 0.3 Inexact Rounded +pwsx1253 power 7E-3 0.5 -> 0.08 Inexact Rounded +pwsx1254 power 7E+1 0.5 -> 8 Inexact Rounded +pwsx1255 power 7E+2 0.5 -> 3E+1 Inexact Rounded +pwsx1256 power 7E+3 0.5 -> 8E+1 Inexact Rounded +pwsx1257 power 0.8 0.5 -> 0.9 Inexact Rounded +pwsx1258 power 0.08 0.5 -> 0.3 Inexact Rounded +pwsx1259 power 8.0E-1 0.5 -> 0.9 Inexact Rounded +pwsx1260 power 8.00E-2 0.5 -> 0.3 Inexact Rounded +pwsx1261 power 8E-3 0.5 -> 0.09 Inexact Rounded +pwsx1262 power 8E+1 0.5 -> 9 Inexact Rounded +pwsx1263 power 8E+2 0.5 -> 3E+1 Inexact Rounded +pwsx1264 power 8E+3 0.5 -> 9E+1 Inexact Rounded +pwsx1265 power 0.9 0.5 -> 0.9 Inexact Rounded +pwsx1266 power 0.09 0.5 -> 0.3 Inexact Rounded +pwsx1267 power 9.0E-1 0.5 -> 0.9 Inexact Rounded +pwsx1268 power 9.00E-2 0.5 -> 0.3 Inexact Rounded +pwsx1269 power 9E-3 0.5 -> 0.09 Inexact Rounded +pwsx1270 power 9E+1 0.5 -> 9 Inexact Rounded +pwsx1271 power 9E+2 0.5 -> 3E+1 Inexact Rounded +pwsx1272 power 9E+3 0.5 -> 9E+1 Inexact Rounded + +-- Precision 2 squareroot tests [exhaustive, plus exponent adjusts] +rounding: half_even +maxExponent: 999 +minexponent: -999 +precision: 2 +pwsx2201 power 0.1 0.5 -> 0.32 Inexact Rounded +pwsx2202 power 0.01 0.5 -> 0.10 Inexact Rounded +pwsx2203 power 1.0E-1 0.5 -> 0.32 Inexact Rounded +pwsx2204 power 1.00E-2 0.5 -> 0.10 Inexact Rounded +pwsx2205 power 1E-3 0.5 -> 0.032 Inexact Rounded +pwsx2206 power 1E+1 0.5 -> 3.2 Inexact Rounded +pwsx2207 power 1E+2 0.5 -> 10 Inexact Rounded +pwsx2208 power 1E+3 0.5 -> 32 Inexact Rounded +pwsx2209 power 0.2 0.5 -> 0.45 Inexact Rounded +pwsx2210 power 0.02 0.5 -> 0.14 Inexact Rounded +pwsx2211 power 2.0E-1 0.5 -> 0.45 Inexact Rounded +pwsx2212 power 2.00E-2 0.5 -> 0.14 Inexact Rounded +pwsx2213 power 2E-3 0.5 -> 0.045 Inexact Rounded +pwsx2214 power 2E+1 0.5 -> 4.5 Inexact Rounded +pwsx2215 power 2E+2 0.5 -> 14 Inexact Rounded +pwsx2216 power 2E+3 0.5 -> 45 Inexact Rounded +pwsx2217 power 0.3 0.5 -> 0.55 Inexact Rounded +pwsx2218 power 0.03 0.5 -> 0.17 Inexact Rounded +pwsx2219 power 3.0E-1 0.5 -> 0.55 Inexact Rounded +pwsx2220 power 3.00E-2 0.5 -> 0.17 Inexact Rounded +pwsx2221 power 3E-3 0.5 -> 0.055 Inexact Rounded +pwsx2222 power 3E+1 0.5 -> 5.5 Inexact Rounded +pwsx2223 power 3E+2 0.5 -> 17 Inexact Rounded +pwsx2224 power 3E+3 0.5 -> 55 Inexact Rounded +pwsx2225 power 0.4 0.5 -> 0.63 Inexact Rounded +pwsx2226 power 0.04 0.5 -> 0.20 Inexact Rounded +pwsx2227 power 4.0E-1 0.5 -> 0.63 Inexact Rounded +pwsx2228 power 4.00E-2 0.5 -> 0.20 Inexact Rounded +pwsx2229 power 4E-3 0.5 -> 0.063 Inexact Rounded +pwsx2230 power 4E+1 0.5 -> 6.3 Inexact Rounded +pwsx2231 power 4E+2 0.5 -> 20 Inexact Rounded +pwsx2232 power 4E+3 0.5 -> 63 Inexact Rounded +pwsx2233 power 0.5 0.5 -> 0.71 Inexact Rounded +pwsx2234 power 0.05 0.5 -> 0.22 Inexact Rounded +pwsx2235 power 5.0E-1 0.5 -> 0.71 Inexact Rounded +pwsx2236 power 5.00E-2 0.5 -> 0.22 Inexact Rounded +pwsx2237 power 5E-3 0.5 -> 0.071 Inexact Rounded +pwsx2238 power 5E+1 0.5 -> 7.1 Inexact Rounded +pwsx2239 power 5E+2 0.5 -> 22 Inexact Rounded +pwsx2240 power 5E+3 0.5 -> 71 Inexact Rounded +pwsx2241 power 0.6 0.5 -> 0.77 Inexact Rounded +pwsx2242 power 0.06 0.5 -> 0.24 Inexact Rounded +pwsx2243 power 6.0E-1 0.5 -> 0.77 Inexact Rounded +pwsx2244 power 6.00E-2 0.5 -> 0.24 Inexact Rounded +pwsx2245 power 6E-3 0.5 -> 0.077 Inexact Rounded +pwsx2246 power 6E+1 0.5 -> 7.7 Inexact Rounded +pwsx2247 power 6E+2 0.5 -> 24 Inexact Rounded +pwsx2248 power 6E+3 0.5 -> 77 Inexact Rounded +pwsx2249 power 0.7 0.5 -> 0.84 Inexact Rounded +pwsx2250 power 0.07 0.5 -> 0.26 Inexact Rounded +pwsx2251 power 7.0E-1 0.5 -> 0.84 Inexact Rounded +pwsx2252 power 7.00E-2 0.5 -> 0.26 Inexact Rounded +pwsx2253 power 7E-3 0.5 -> 0.084 Inexact Rounded +pwsx2254 power 7E+1 0.5 -> 8.4 Inexact Rounded +pwsx2255 power 7E+2 0.5 -> 26 Inexact Rounded +pwsx2256 power 7E+3 0.5 -> 84 Inexact Rounded +pwsx2257 power 0.8 0.5 -> 0.89 Inexact Rounded +pwsx2258 power 0.08 0.5 -> 0.28 Inexact Rounded +pwsx2259 power 8.0E-1 0.5 -> 0.89 Inexact Rounded +pwsx2260 power 8.00E-2 0.5 -> 0.28 Inexact Rounded +pwsx2261 power 8E-3 0.5 -> 0.089 Inexact Rounded +pwsx2262 power 8E+1 0.5 -> 8.9 Inexact Rounded +pwsx2263 power 8E+2 0.5 -> 28 Inexact Rounded +pwsx2264 power 8E+3 0.5 -> 89 Inexact Rounded +pwsx2265 power 0.9 0.5 -> 0.95 Inexact Rounded +pwsx2266 power 0.09 0.5 -> 0.30 Inexact Rounded +pwsx2267 power 9.0E-1 0.5 -> 0.95 Inexact Rounded +pwsx2268 power 9.00E-2 0.5 -> 0.30 Inexact Rounded +pwsx2269 power 9E-3 0.5 -> 0.095 Inexact Rounded +pwsx2270 power 9E+1 0.5 -> 9.5 Inexact Rounded +pwsx2271 power 9E+2 0.5 -> 30 Inexact Rounded +pwsx2272 power 9E+3 0.5 -> 95 Inexact Rounded +pwsx2273 power 0.10 0.5 -> 0.32 Inexact Rounded +pwsx2274 power 0.010 0.5 -> 0.10 Inexact Rounded +pwsx2275 power 10.0E-1 0.5 -> 1.0 Inexact Rounded +pwsx2276 power 10.00E-2 0.5 -> 0.32 Inexact Rounded +pwsx2277 power 10E-3 0.5 -> 0.10 Inexact Rounded +pwsx2278 power 10E+1 0.5 -> 10 Inexact Rounded +pwsx2279 power 10E+2 0.5 -> 32 Inexact Rounded +pwsx2280 power 10E+3 0.5 -> 1.0E+2 Inexact Rounded +pwsx2281 power 0.11 0.5 -> 0.33 Inexact Rounded +pwsx2282 power 0.011 0.5 -> 0.10 Inexact Rounded +pwsx2283 power 11.0E-1 0.5 -> 1.0 Inexact Rounded +pwsx2284 power 11.00E-2 0.5 -> 0.33 Inexact Rounded +pwsx2285 power 11E-3 0.5 -> 0.10 Inexact Rounded +pwsx2286 power 11E+1 0.5 -> 10 Inexact Rounded +pwsx2287 power 11E+2 0.5 -> 33 Inexact Rounded +pwsx2288 power 11E+3 0.5 -> 1.0E+2 Inexact Rounded +pwsx2289 power 0.12 0.5 -> 0.35 Inexact Rounded +pwsx2290 power 0.012 0.5 -> 0.11 Inexact Rounded +pwsx2291 power 12.0E-1 0.5 -> 1.1 Inexact Rounded +pwsx2292 power 12.00E-2 0.5 -> 0.35 Inexact Rounded +pwsx2293 power 12E-3 0.5 -> 0.11 Inexact Rounded +pwsx2294 power 12E+1 0.5 -> 11 Inexact Rounded +pwsx2295 power 12E+2 0.5 -> 35 Inexact Rounded +pwsx2296 power 12E+3 0.5 -> 1.1E+2 Inexact Rounded +pwsx2297 power 0.13 0.5 -> 0.36 Inexact Rounded +pwsx2298 power 0.013 0.5 -> 0.11 Inexact Rounded +pwsx2299 power 13.0E-1 0.5 -> 1.1 Inexact Rounded +pwsx2300 power 13.00E-2 0.5 -> 0.36 Inexact Rounded +pwsx2301 power 13E-3 0.5 -> 0.11 Inexact Rounded +pwsx2302 power 13E+1 0.5 -> 11 Inexact Rounded +pwsx2303 power 13E+2 0.5 -> 36 Inexact Rounded +pwsx2304 power 13E+3 0.5 -> 1.1E+2 Inexact Rounded +pwsx2305 power 0.14 0.5 -> 0.37 Inexact Rounded +pwsx2306 power 0.014 0.5 -> 0.12 Inexact Rounded +pwsx2307 power 14.0E-1 0.5 -> 1.2 Inexact Rounded +pwsx2308 power 14.00E-2 0.5 -> 0.37 Inexact Rounded +pwsx2309 power 14E-3 0.5 -> 0.12 Inexact Rounded +pwsx2310 power 14E+1 0.5 -> 12 Inexact Rounded +pwsx2311 power 14E+2 0.5 -> 37 Inexact Rounded +pwsx2312 power 14E+3 0.5 -> 1.2E+2 Inexact Rounded +pwsx2313 power 0.15 0.5 -> 0.39 Inexact Rounded +pwsx2314 power 0.015 0.5 -> 0.12 Inexact Rounded +pwsx2315 power 15.0E-1 0.5 -> 1.2 Inexact Rounded +pwsx2316 power 15.00E-2 0.5 -> 0.39 Inexact Rounded +pwsx2317 power 15E-3 0.5 -> 0.12 Inexact Rounded +pwsx2318 power 15E+1 0.5 -> 12 Inexact Rounded +pwsx2319 power 15E+2 0.5 -> 39 Inexact Rounded +pwsx2320 power 15E+3 0.5 -> 1.2E+2 Inexact Rounded +pwsx2321 power 0.16 0.5 -> 0.40 Inexact Rounded +pwsx2322 power 0.016 0.5 -> 0.13 Inexact Rounded +pwsx2323 power 16.0E-1 0.5 -> 1.3 Inexact Rounded +pwsx2324 power 16.00E-2 0.5 -> 0.40 Inexact Rounded +pwsx2325 power 16E-3 0.5 -> 0.13 Inexact Rounded +pwsx2326 power 16E+1 0.5 -> 13 Inexact Rounded +pwsx2327 power 16E+2 0.5 -> 40 Inexact Rounded +pwsx2328 power 16E+3 0.5 -> 1.3E+2 Inexact Rounded +pwsx2329 power 0.17 0.5 -> 0.41 Inexact Rounded +pwsx2330 power 0.017 0.5 -> 0.13 Inexact Rounded +pwsx2331 power 17.0E-1 0.5 -> 1.3 Inexact Rounded +pwsx2332 power 17.00E-2 0.5 -> 0.41 Inexact Rounded +pwsx2333 power 17E-3 0.5 -> 0.13 Inexact Rounded +pwsx2334 power 17E+1 0.5 -> 13 Inexact Rounded +pwsx2335 power 17E+2 0.5 -> 41 Inexact Rounded +pwsx2336 power 17E+3 0.5 -> 1.3E+2 Inexact Rounded +pwsx2337 power 0.18 0.5 -> 0.42 Inexact Rounded +pwsx2338 power 0.018 0.5 -> 0.13 Inexact Rounded +pwsx2339 power 18.0E-1 0.5 -> 1.3 Inexact Rounded +pwsx2340 power 18.00E-2 0.5 -> 0.42 Inexact Rounded +pwsx2341 power 18E-3 0.5 -> 0.13 Inexact Rounded +pwsx2342 power 18E+1 0.5 -> 13 Inexact Rounded +pwsx2343 power 18E+2 0.5 -> 42 Inexact Rounded +pwsx2344 power 18E+3 0.5 -> 1.3E+2 Inexact Rounded +pwsx2345 power 0.19 0.5 -> 0.44 Inexact Rounded +pwsx2346 power 0.019 0.5 -> 0.14 Inexact Rounded +pwsx2347 power 19.0E-1 0.5 -> 1.4 Inexact Rounded +pwsx2348 power 19.00E-2 0.5 -> 0.44 Inexact Rounded +pwsx2349 power 19E-3 0.5 -> 0.14 Inexact Rounded +pwsx2350 power 19E+1 0.5 -> 14 Inexact Rounded +pwsx2351 power 19E+2 0.5 -> 44 Inexact Rounded +pwsx2352 power 19E+3 0.5 -> 1.4E+2 Inexact Rounded +pwsx2353 power 0.20 0.5 -> 0.45 Inexact Rounded +pwsx2354 power 0.020 0.5 -> 0.14 Inexact Rounded +pwsx2355 power 20.0E-1 0.5 -> 1.4 Inexact Rounded +pwsx2356 power 20.00E-2 0.5 -> 0.45 Inexact Rounded +pwsx2357 power 20E-3 0.5 -> 0.14 Inexact Rounded +pwsx2358 power 20E+1 0.5 -> 14 Inexact Rounded +pwsx2359 power 20E+2 0.5 -> 45 Inexact Rounded +pwsx2360 power 20E+3 0.5 -> 1.4E+2 Inexact Rounded +pwsx2361 power 0.21 0.5 -> 0.46 Inexact Rounded +pwsx2362 power 0.021 0.5 -> 0.14 Inexact Rounded +pwsx2363 power 21.0E-1 0.5 -> 1.4 Inexact Rounded +pwsx2364 power 21.00E-2 0.5 -> 0.46 Inexact Rounded +pwsx2365 power 21E-3 0.5 -> 0.14 Inexact Rounded +pwsx2366 power 21E+1 0.5 -> 14 Inexact Rounded +pwsx2367 power 21E+2 0.5 -> 46 Inexact Rounded +pwsx2368 power 21E+3 0.5 -> 1.4E+2 Inexact Rounded +pwsx2369 power 0.22 0.5 -> 0.47 Inexact Rounded +pwsx2370 power 0.022 0.5 -> 0.15 Inexact Rounded +pwsx2371 power 22.0E-1 0.5 -> 1.5 Inexact Rounded +pwsx2372 power 22.00E-2 0.5 -> 0.47 Inexact Rounded +pwsx2373 power 22E-3 0.5 -> 0.15 Inexact Rounded +pwsx2374 power 22E+1 0.5 -> 15 Inexact Rounded +pwsx2375 power 22E+2 0.5 -> 47 Inexact Rounded +pwsx2376 power 22E+3 0.5 -> 1.5E+2 Inexact Rounded +pwsx2377 power 0.23 0.5 -> 0.48 Inexact Rounded +pwsx2378 power 0.023 0.5 -> 0.15 Inexact Rounded +pwsx2379 power 23.0E-1 0.5 -> 1.5 Inexact Rounded +pwsx2380 power 23.00E-2 0.5 -> 0.48 Inexact Rounded +pwsx2381 power 23E-3 0.5 -> 0.15 Inexact Rounded +pwsx2382 power 23E+1 0.5 -> 15 Inexact Rounded +pwsx2383 power 23E+2 0.5 -> 48 Inexact Rounded +pwsx2384 power 23E+3 0.5 -> 1.5E+2 Inexact Rounded +pwsx2385 power 0.24 0.5 -> 0.49 Inexact Rounded +pwsx2386 power 0.024 0.5 -> 0.15 Inexact Rounded +pwsx2387 power 24.0E-1 0.5 -> 1.5 Inexact Rounded +pwsx2388 power 24.00E-2 0.5 -> 0.49 Inexact Rounded +pwsx2389 power 24E-3 0.5 -> 0.15 Inexact Rounded +pwsx2390 power 24E+1 0.5 -> 15 Inexact Rounded +pwsx2391 power 24E+2 0.5 -> 49 Inexact Rounded +pwsx2392 power 24E+3 0.5 -> 1.5E+2 Inexact Rounded +pwsx2393 power 0.25 0.5 -> 0.50 Inexact Rounded +pwsx2394 power 0.025 0.5 -> 0.16 Inexact Rounded +pwsx2395 power 25.0E-1 0.5 -> 1.6 Inexact Rounded +pwsx2396 power 25.00E-2 0.5 -> 0.50 Inexact Rounded +pwsx2397 power 25E-3 0.5 -> 0.16 Inexact Rounded +pwsx2398 power 25E+1 0.5 -> 16 Inexact Rounded +pwsx2399 power 25E+2 0.5 -> 50 Inexact Rounded +pwsx2400 power 25E+3 0.5 -> 1.6E+2 Inexact Rounded +pwsx2401 power 0.26 0.5 -> 0.51 Inexact Rounded +pwsx2402 power 0.026 0.5 -> 0.16 Inexact Rounded +pwsx2403 power 26.0E-1 0.5 -> 1.6 Inexact Rounded +pwsx2404 power 26.00E-2 0.5 -> 0.51 Inexact Rounded +pwsx2405 power 26E-3 0.5 -> 0.16 Inexact Rounded +pwsx2406 power 26E+1 0.5 -> 16 Inexact Rounded +pwsx2407 power 26E+2 0.5 -> 51 Inexact Rounded +pwsx2408 power 26E+3 0.5 -> 1.6E+2 Inexact Rounded +pwsx2409 power 0.27 0.5 -> 0.52 Inexact Rounded +pwsx2410 power 0.027 0.5 -> 0.16 Inexact Rounded +pwsx2411 power 27.0E-1 0.5 -> 1.6 Inexact Rounded +pwsx2412 power 27.00E-2 0.5 -> 0.52 Inexact Rounded +pwsx2413 power 27E-3 0.5 -> 0.16 Inexact Rounded +pwsx2414 power 27E+1 0.5 -> 16 Inexact Rounded +pwsx2415 power 27E+2 0.5 -> 52 Inexact Rounded +pwsx2416 power 27E+3 0.5 -> 1.6E+2 Inexact Rounded +pwsx2417 power 0.28 0.5 -> 0.53 Inexact Rounded +pwsx2418 power 0.028 0.5 -> 0.17 Inexact Rounded +pwsx2419 power 28.0E-1 0.5 -> 1.7 Inexact Rounded +pwsx2420 power 28.00E-2 0.5 -> 0.53 Inexact Rounded +pwsx2421 power 28E-3 0.5 -> 0.17 Inexact Rounded +pwsx2422 power 28E+1 0.5 -> 17 Inexact Rounded +pwsx2423 power 28E+2 0.5 -> 53 Inexact Rounded +pwsx2424 power 28E+3 0.5 -> 1.7E+2 Inexact Rounded +pwsx2425 power 0.29 0.5 -> 0.54 Inexact Rounded +pwsx2426 power 0.029 0.5 -> 0.17 Inexact Rounded +pwsx2427 power 29.0E-1 0.5 -> 1.7 Inexact Rounded +pwsx2428 power 29.00E-2 0.5 -> 0.54 Inexact Rounded +pwsx2429 power 29E-3 0.5 -> 0.17 Inexact Rounded +pwsx2430 power 29E+1 0.5 -> 17 Inexact Rounded +pwsx2431 power 29E+2 0.5 -> 54 Inexact Rounded +pwsx2432 power 29E+3 0.5 -> 1.7E+2 Inexact Rounded +pwsx2433 power 0.30 0.5 -> 0.55 Inexact Rounded +pwsx2434 power 0.030 0.5 -> 0.17 Inexact Rounded +pwsx2435 power 30.0E-1 0.5 -> 1.7 Inexact Rounded +pwsx2436 power 30.00E-2 0.5 -> 0.55 Inexact Rounded +pwsx2437 power 30E-3 0.5 -> 0.17 Inexact Rounded +pwsx2438 power 30E+1 0.5 -> 17 Inexact Rounded +pwsx2439 power 30E+2 0.5 -> 55 Inexact Rounded +pwsx2440 power 30E+3 0.5 -> 1.7E+2 Inexact Rounded +pwsx2441 power 0.31 0.5 -> 0.56 Inexact Rounded +pwsx2442 power 0.031 0.5 -> 0.18 Inexact Rounded +pwsx2443 power 31.0E-1 0.5 -> 1.8 Inexact Rounded +pwsx2444 power 31.00E-2 0.5 -> 0.56 Inexact Rounded +pwsx2445 power 31E-3 0.5 -> 0.18 Inexact Rounded +pwsx2446 power 31E+1 0.5 -> 18 Inexact Rounded +pwsx2447 power 31E+2 0.5 -> 56 Inexact Rounded +pwsx2448 power 31E+3 0.5 -> 1.8E+2 Inexact Rounded +pwsx2449 power 0.32 0.5 -> 0.57 Inexact Rounded +pwsx2450 power 0.032 0.5 -> 0.18 Inexact Rounded +pwsx2451 power 32.0E-1 0.5 -> 1.8 Inexact Rounded +pwsx2452 power 32.00E-2 0.5 -> 0.57 Inexact Rounded +pwsx2453 power 32E-3 0.5 -> 0.18 Inexact Rounded +pwsx2454 power 32E+1 0.5 -> 18 Inexact Rounded +pwsx2455 power 32E+2 0.5 -> 57 Inexact Rounded +pwsx2456 power 32E+3 0.5 -> 1.8E+2 Inexact Rounded +pwsx2457 power 0.33 0.5 -> 0.57 Inexact Rounded +pwsx2458 power 0.033 0.5 -> 0.18 Inexact Rounded +pwsx2459 power 33.0E-1 0.5 -> 1.8 Inexact Rounded +pwsx2460 power 33.00E-2 0.5 -> 0.57 Inexact Rounded +pwsx2461 power 33E-3 0.5 -> 0.18 Inexact Rounded +pwsx2462 power 33E+1 0.5 -> 18 Inexact Rounded +pwsx2463 power 33E+2 0.5 -> 57 Inexact Rounded +pwsx2464 power 33E+3 0.5 -> 1.8E+2 Inexact Rounded +pwsx2465 power 0.34 0.5 -> 0.58 Inexact Rounded +pwsx2466 power 0.034 0.5 -> 0.18 Inexact Rounded +pwsx2467 power 34.0E-1 0.5 -> 1.8 Inexact Rounded +pwsx2468 power 34.00E-2 0.5 -> 0.58 Inexact Rounded +pwsx2469 power 34E-3 0.5 -> 0.18 Inexact Rounded +pwsx2470 power 34E+1 0.5 -> 18 Inexact Rounded +pwsx2471 power 34E+2 0.5 -> 58 Inexact Rounded +pwsx2472 power 34E+3 0.5 -> 1.8E+2 Inexact Rounded +pwsx2473 power 0.35 0.5 -> 0.59 Inexact Rounded +pwsx2474 power 0.035 0.5 -> 0.19 Inexact Rounded +pwsx2475 power 35.0E-1 0.5 -> 1.9 Inexact Rounded +pwsx2476 power 35.00E-2 0.5 -> 0.59 Inexact Rounded +pwsx2477 power 35E-3 0.5 -> 0.19 Inexact Rounded +pwsx2478 power 35E+1 0.5 -> 19 Inexact Rounded +pwsx2479 power 35E+2 0.5 -> 59 Inexact Rounded +pwsx2480 power 35E+3 0.5 -> 1.9E+2 Inexact Rounded +pwsx2481 power 0.36 0.5 -> 0.60 Inexact Rounded +pwsx2482 power 0.036 0.5 -> 0.19 Inexact Rounded +pwsx2483 power 36.0E-1 0.5 -> 1.9 Inexact Rounded +pwsx2484 power 36.00E-2 0.5 -> 0.60 Inexact Rounded +pwsx2485 power 36E-3 0.5 -> 0.19 Inexact Rounded +pwsx2486 power 36E+1 0.5 -> 19 Inexact Rounded +pwsx2487 power 36E+2 0.5 -> 60 Inexact Rounded +pwsx2488 power 36E+3 0.5 -> 1.9E+2 Inexact Rounded +pwsx2489 power 0.37 0.5 -> 0.61 Inexact Rounded +pwsx2490 power 0.037 0.5 -> 0.19 Inexact Rounded +pwsx2491 power 37.0E-1 0.5 -> 1.9 Inexact Rounded +pwsx2492 power 37.00E-2 0.5 -> 0.61 Inexact Rounded +pwsx2493 power 37E-3 0.5 -> 0.19 Inexact Rounded +pwsx2494 power 37E+1 0.5 -> 19 Inexact Rounded +pwsx2495 power 37E+2 0.5 -> 61 Inexact Rounded +pwsx2496 power 37E+3 0.5 -> 1.9E+2 Inexact Rounded +pwsx2497 power 0.38 0.5 -> 0.62 Inexact Rounded +pwsx2498 power 0.038 0.5 -> 0.19 Inexact Rounded +pwsx2499 power 38.0E-1 0.5 -> 1.9 Inexact Rounded +pwsx2500 power 38.00E-2 0.5 -> 0.62 Inexact Rounded +pwsx2501 power 38E-3 0.5 -> 0.19 Inexact Rounded +pwsx2502 power 38E+1 0.5 -> 19 Inexact Rounded +pwsx2503 power 38E+2 0.5 -> 62 Inexact Rounded +pwsx2504 power 38E+3 0.5 -> 1.9E+2 Inexact Rounded +pwsx2505 power 0.39 0.5 -> 0.62 Inexact Rounded +pwsx2506 power 0.039 0.5 -> 0.20 Inexact Rounded +pwsx2507 power 39.0E-1 0.5 -> 2.0 Inexact Rounded +pwsx2508 power 39.00E-2 0.5 -> 0.62 Inexact Rounded +pwsx2509 power 39E-3 0.5 -> 0.20 Inexact Rounded +pwsx2510 power 39E+1 0.5 -> 20 Inexact Rounded +pwsx2511 power 39E+2 0.5 -> 62 Inexact Rounded +pwsx2512 power 39E+3 0.5 -> 2.0E+2 Inexact Rounded +pwsx2513 power 0.40 0.5 -> 0.63 Inexact Rounded +pwsx2514 power 0.040 0.5 -> 0.20 Inexact Rounded +pwsx2515 power 40.0E-1 0.5 -> 2.0 Inexact Rounded +pwsx2516 power 40.00E-2 0.5 -> 0.63 Inexact Rounded +pwsx2517 power 40E-3 0.5 -> 0.20 Inexact Rounded +pwsx2518 power 40E+1 0.5 -> 20 Inexact Rounded +pwsx2519 power 40E+2 0.5 -> 63 Inexact Rounded +pwsx2520 power 40E+3 0.5 -> 2.0E+2 Inexact Rounded +pwsx2521 power 0.41 0.5 -> 0.64 Inexact Rounded +pwsx2522 power 0.041 0.5 -> 0.20 Inexact Rounded +pwsx2523 power 41.0E-1 0.5 -> 2.0 Inexact Rounded +pwsx2524 power 41.00E-2 0.5 -> 0.64 Inexact Rounded +pwsx2525 power 41E-3 0.5 -> 0.20 Inexact Rounded +pwsx2526 power 41E+1 0.5 -> 20 Inexact Rounded +pwsx2527 power 41E+2 0.5 -> 64 Inexact Rounded +pwsx2528 power 41E+3 0.5 -> 2.0E+2 Inexact Rounded +pwsx2529 power 0.42 0.5 -> 0.65 Inexact Rounded +pwsx2530 power 0.042 0.5 -> 0.20 Inexact Rounded +pwsx2531 power 42.0E-1 0.5 -> 2.0 Inexact Rounded +pwsx2532 power 42.00E-2 0.5 -> 0.65 Inexact Rounded +pwsx2533 power 42E-3 0.5 -> 0.20 Inexact Rounded +pwsx2534 power 42E+1 0.5 -> 20 Inexact Rounded +pwsx2535 power 42E+2 0.5 -> 65 Inexact Rounded +pwsx2536 power 42E+3 0.5 -> 2.0E+2 Inexact Rounded +pwsx2537 power 0.43 0.5 -> 0.66 Inexact Rounded +pwsx2538 power 0.043 0.5 -> 0.21 Inexact Rounded +pwsx2539 power 43.0E-1 0.5 -> 2.1 Inexact Rounded +pwsx2540 power 43.00E-2 0.5 -> 0.66 Inexact Rounded +pwsx2541 power 43E-3 0.5 -> 0.21 Inexact Rounded +pwsx2542 power 43E+1 0.5 -> 21 Inexact Rounded +pwsx2543 power 43E+2 0.5 -> 66 Inexact Rounded +pwsx2544 power 43E+3 0.5 -> 2.1E+2 Inexact Rounded +pwsx2545 power 0.44 0.5 -> 0.66 Inexact Rounded +pwsx2546 power 0.044 0.5 -> 0.21 Inexact Rounded +pwsx2547 power 44.0E-1 0.5 -> 2.1 Inexact Rounded +pwsx2548 power 44.00E-2 0.5 -> 0.66 Inexact Rounded +pwsx2549 power 44E-3 0.5 -> 0.21 Inexact Rounded +pwsx2550 power 44E+1 0.5 -> 21 Inexact Rounded +pwsx2551 power 44E+2 0.5 -> 66 Inexact Rounded +pwsx2552 power 44E+3 0.5 -> 2.1E+2 Inexact Rounded +pwsx2553 power 0.45 0.5 -> 0.67 Inexact Rounded +pwsx2554 power 0.045 0.5 -> 0.21 Inexact Rounded +pwsx2555 power 45.0E-1 0.5 -> 2.1 Inexact Rounded +pwsx2556 power 45.00E-2 0.5 -> 0.67 Inexact Rounded +pwsx2557 power 45E-3 0.5 -> 0.21 Inexact Rounded +pwsx2558 power 45E+1 0.5 -> 21 Inexact Rounded +pwsx2559 power 45E+2 0.5 -> 67 Inexact Rounded +pwsx2560 power 45E+3 0.5 -> 2.1E+2 Inexact Rounded +pwsx2561 power 0.46 0.5 -> 0.68 Inexact Rounded +pwsx2562 power 0.046 0.5 -> 0.21 Inexact Rounded +pwsx2563 power 46.0E-1 0.5 -> 2.1 Inexact Rounded +pwsx2564 power 46.00E-2 0.5 -> 0.68 Inexact Rounded +pwsx2565 power 46E-3 0.5 -> 0.21 Inexact Rounded +pwsx2566 power 46E+1 0.5 -> 21 Inexact Rounded +pwsx2567 power 46E+2 0.5 -> 68 Inexact Rounded +pwsx2568 power 46E+3 0.5 -> 2.1E+2 Inexact Rounded +pwsx2569 power 0.47 0.5 -> 0.69 Inexact Rounded +pwsx2570 power 0.047 0.5 -> 0.22 Inexact Rounded +pwsx2571 power 47.0E-1 0.5 -> 2.2 Inexact Rounded +pwsx2572 power 47.00E-2 0.5 -> 0.69 Inexact Rounded +pwsx2573 power 47E-3 0.5 -> 0.22 Inexact Rounded +pwsx2574 power 47E+1 0.5 -> 22 Inexact Rounded +pwsx2575 power 47E+2 0.5 -> 69 Inexact Rounded +pwsx2576 power 47E+3 0.5 -> 2.2E+2 Inexact Rounded +pwsx2577 power 0.48 0.5 -> 0.69 Inexact Rounded +pwsx2578 power 0.048 0.5 -> 0.22 Inexact Rounded +pwsx2579 power 48.0E-1 0.5 -> 2.2 Inexact Rounded +pwsx2580 power 48.00E-2 0.5 -> 0.69 Inexact Rounded +pwsx2581 power 48E-3 0.5 -> 0.22 Inexact Rounded +pwsx2582 power 48E+1 0.5 -> 22 Inexact Rounded +pwsx2583 power 48E+2 0.5 -> 69 Inexact Rounded +pwsx2584 power 48E+3 0.5 -> 2.2E+2 Inexact Rounded +pwsx2585 power 0.49 0.5 -> 0.70 Inexact Rounded +pwsx2586 power 0.049 0.5 -> 0.22 Inexact Rounded +pwsx2587 power 49.0E-1 0.5 -> 2.2 Inexact Rounded +pwsx2588 power 49.00E-2 0.5 -> 0.70 Inexact Rounded +pwsx2589 power 49E-3 0.5 -> 0.22 Inexact Rounded +pwsx2590 power 49E+1 0.5 -> 22 Inexact Rounded +pwsx2591 power 49E+2 0.5 -> 70 Inexact Rounded +pwsx2592 power 49E+3 0.5 -> 2.2E+2 Inexact Rounded +pwsx2593 power 0.50 0.5 -> 0.71 Inexact Rounded +pwsx2594 power 0.050 0.5 -> 0.22 Inexact Rounded +pwsx2595 power 50.0E-1 0.5 -> 2.2 Inexact Rounded +pwsx2596 power 50.00E-2 0.5 -> 0.71 Inexact Rounded +pwsx2597 power 50E-3 0.5 -> 0.22 Inexact Rounded +pwsx2598 power 50E+1 0.5 -> 22 Inexact Rounded +pwsx2599 power 50E+2 0.5 -> 71 Inexact Rounded +pwsx2600 power 50E+3 0.5 -> 2.2E+2 Inexact Rounded +pwsx2601 power 0.51 0.5 -> 0.71 Inexact Rounded +pwsx2602 power 0.051 0.5 -> 0.23 Inexact Rounded +pwsx2603 power 51.0E-1 0.5 -> 2.3 Inexact Rounded +pwsx2604 power 51.00E-2 0.5 -> 0.71 Inexact Rounded +pwsx2605 power 51E-3 0.5 -> 0.23 Inexact Rounded +pwsx2606 power 51E+1 0.5 -> 23 Inexact Rounded +pwsx2607 power 51E+2 0.5 -> 71 Inexact Rounded +pwsx2608 power 51E+3 0.5 -> 2.3E+2 Inexact Rounded +pwsx2609 power 0.52 0.5 -> 0.72 Inexact Rounded +pwsx2610 power 0.052 0.5 -> 0.23 Inexact Rounded +pwsx2611 power 52.0E-1 0.5 -> 2.3 Inexact Rounded +pwsx2612 power 52.00E-2 0.5 -> 0.72 Inexact Rounded +pwsx2613 power 52E-3 0.5 -> 0.23 Inexact Rounded +pwsx2614 power 52E+1 0.5 -> 23 Inexact Rounded +pwsx2615 power 52E+2 0.5 -> 72 Inexact Rounded +pwsx2616 power 52E+3 0.5 -> 2.3E+2 Inexact Rounded +pwsx2617 power 0.53 0.5 -> 0.73 Inexact Rounded +pwsx2618 power 0.053 0.5 -> 0.23 Inexact Rounded +pwsx2619 power 53.0E-1 0.5 -> 2.3 Inexact Rounded +pwsx2620 power 53.00E-2 0.5 -> 0.73 Inexact Rounded +pwsx2621 power 53E-3 0.5 -> 0.23 Inexact Rounded +pwsx2622 power 53E+1 0.5 -> 23 Inexact Rounded +pwsx2623 power 53E+2 0.5 -> 73 Inexact Rounded +pwsx2624 power 53E+3 0.5 -> 2.3E+2 Inexact Rounded +pwsx2625 power 0.54 0.5 -> 0.73 Inexact Rounded +pwsx2626 power 0.054 0.5 -> 0.23 Inexact Rounded +pwsx2627 power 54.0E-1 0.5 -> 2.3 Inexact Rounded +pwsx2628 power 54.00E-2 0.5 -> 0.73 Inexact Rounded +pwsx2629 power 54E-3 0.5 -> 0.23 Inexact Rounded +pwsx2630 power 54E+1 0.5 -> 23 Inexact Rounded +pwsx2631 power 54E+2 0.5 -> 73 Inexact Rounded +pwsx2632 power 54E+3 0.5 -> 2.3E+2 Inexact Rounded +pwsx2633 power 0.55 0.5 -> 0.74 Inexact Rounded +pwsx2634 power 0.055 0.5 -> 0.23 Inexact Rounded +pwsx2635 power 55.0E-1 0.5 -> 2.3 Inexact Rounded +pwsx2636 power 55.00E-2 0.5 -> 0.74 Inexact Rounded +pwsx2637 power 55E-3 0.5 -> 0.23 Inexact Rounded +pwsx2638 power 55E+1 0.5 -> 23 Inexact Rounded +pwsx2639 power 55E+2 0.5 -> 74 Inexact Rounded +pwsx2640 power 55E+3 0.5 -> 2.3E+2 Inexact Rounded +pwsx2641 power 0.56 0.5 -> 0.75 Inexact Rounded +pwsx2642 power 0.056 0.5 -> 0.24 Inexact Rounded +pwsx2643 power 56.0E-1 0.5 -> 2.4 Inexact Rounded +pwsx2644 power 56.00E-2 0.5 -> 0.75 Inexact Rounded +pwsx2645 power 56E-3 0.5 -> 0.24 Inexact Rounded +pwsx2646 power 56E+1 0.5 -> 24 Inexact Rounded +pwsx2647 power 56E+2 0.5 -> 75 Inexact Rounded +pwsx2648 power 56E+3 0.5 -> 2.4E+2 Inexact Rounded +pwsx2649 power 0.57 0.5 -> 0.75 Inexact Rounded +pwsx2650 power 0.057 0.5 -> 0.24 Inexact Rounded +pwsx2651 power 57.0E-1 0.5 -> 2.4 Inexact Rounded +pwsx2652 power 57.00E-2 0.5 -> 0.75 Inexact Rounded +pwsx2653 power 57E-3 0.5 -> 0.24 Inexact Rounded +pwsx2654 power 57E+1 0.5 -> 24 Inexact Rounded +pwsx2655 power 57E+2 0.5 -> 75 Inexact Rounded +pwsx2656 power 57E+3 0.5 -> 2.4E+2 Inexact Rounded +pwsx2657 power 0.58 0.5 -> 0.76 Inexact Rounded +pwsx2658 power 0.058 0.5 -> 0.24 Inexact Rounded +pwsx2659 power 58.0E-1 0.5 -> 2.4 Inexact Rounded +pwsx2660 power 58.00E-2 0.5 -> 0.76 Inexact Rounded +pwsx2661 power 58E-3 0.5 -> 0.24 Inexact Rounded +pwsx2662 power 58E+1 0.5 -> 24 Inexact Rounded +pwsx2663 power 58E+2 0.5 -> 76 Inexact Rounded +pwsx2664 power 58E+3 0.5 -> 2.4E+2 Inexact Rounded +pwsx2665 power 0.59 0.5 -> 0.77 Inexact Rounded +pwsx2666 power 0.059 0.5 -> 0.24 Inexact Rounded +pwsx2667 power 59.0E-1 0.5 -> 2.4 Inexact Rounded +pwsx2668 power 59.00E-2 0.5 -> 0.77 Inexact Rounded +pwsx2669 power 59E-3 0.5 -> 0.24 Inexact Rounded +pwsx2670 power 59E+1 0.5 -> 24 Inexact Rounded +pwsx2671 power 59E+2 0.5 -> 77 Inexact Rounded +pwsx2672 power 59E+3 0.5 -> 2.4E+2 Inexact Rounded +pwsx2673 power 0.60 0.5 -> 0.77 Inexact Rounded +pwsx2674 power 0.060 0.5 -> 0.24 Inexact Rounded +pwsx2675 power 60.0E-1 0.5 -> 2.4 Inexact Rounded +pwsx2676 power 60.00E-2 0.5 -> 0.77 Inexact Rounded +pwsx2677 power 60E-3 0.5 -> 0.24 Inexact Rounded +pwsx2678 power 60E+1 0.5 -> 24 Inexact Rounded +pwsx2679 power 60E+2 0.5 -> 77 Inexact Rounded +pwsx2680 power 60E+3 0.5 -> 2.4E+2 Inexact Rounded +pwsx2681 power 0.61 0.5 -> 0.78 Inexact Rounded +pwsx2682 power 0.061 0.5 -> 0.25 Inexact Rounded +pwsx2683 power 61.0E-1 0.5 -> 2.5 Inexact Rounded +pwsx2684 power 61.00E-2 0.5 -> 0.78 Inexact Rounded +pwsx2685 power 61E-3 0.5 -> 0.25 Inexact Rounded +pwsx2686 power 61E+1 0.5 -> 25 Inexact Rounded +pwsx2687 power 61E+2 0.5 -> 78 Inexact Rounded +pwsx2688 power 61E+3 0.5 -> 2.5E+2 Inexact Rounded +pwsx2689 power 0.62 0.5 -> 0.79 Inexact Rounded +pwsx2690 power 0.062 0.5 -> 0.25 Inexact Rounded +pwsx2691 power 62.0E-1 0.5 -> 2.5 Inexact Rounded +pwsx2692 power 62.00E-2 0.5 -> 0.79 Inexact Rounded +pwsx2693 power 62E-3 0.5 -> 0.25 Inexact Rounded +pwsx2694 power 62E+1 0.5 -> 25 Inexact Rounded +pwsx2695 power 62E+2 0.5 -> 79 Inexact Rounded +pwsx2696 power 62E+3 0.5 -> 2.5E+2 Inexact Rounded +pwsx2697 power 0.63 0.5 -> 0.79 Inexact Rounded +pwsx2698 power 0.063 0.5 -> 0.25 Inexact Rounded +pwsx2699 power 63.0E-1 0.5 -> 2.5 Inexact Rounded +pwsx2700 power 63.00E-2 0.5 -> 0.79 Inexact Rounded +pwsx2701 power 63E-3 0.5 -> 0.25 Inexact Rounded +pwsx2702 power 63E+1 0.5 -> 25 Inexact Rounded +pwsx2703 power 63E+2 0.5 -> 79 Inexact Rounded +pwsx2704 power 63E+3 0.5 -> 2.5E+2 Inexact Rounded +pwsx2705 power 0.64 0.5 -> 0.80 Inexact Rounded +pwsx2706 power 0.064 0.5 -> 0.25 Inexact Rounded +pwsx2707 power 64.0E-1 0.5 -> 2.5 Inexact Rounded +pwsx2708 power 64.00E-2 0.5 -> 0.80 Inexact Rounded +pwsx2709 power 64E-3 0.5 -> 0.25 Inexact Rounded +pwsx2710 power 64E+1 0.5 -> 25 Inexact Rounded +pwsx2711 power 64E+2 0.5 -> 80 Inexact Rounded +pwsx2712 power 64E+3 0.5 -> 2.5E+2 Inexact Rounded +pwsx2713 power 0.65 0.5 -> 0.81 Inexact Rounded +pwsx2714 power 0.065 0.5 -> 0.25 Inexact Rounded +pwsx2715 power 65.0E-1 0.5 -> 2.5 Inexact Rounded +pwsx2716 power 65.00E-2 0.5 -> 0.81 Inexact Rounded +pwsx2717 power 65E-3 0.5 -> 0.25 Inexact Rounded +pwsx2718 power 65E+1 0.5 -> 25 Inexact Rounded +pwsx2719 power 65E+2 0.5 -> 81 Inexact Rounded +pwsx2720 power 65E+3 0.5 -> 2.5E+2 Inexact Rounded +pwsx2721 power 0.66 0.5 -> 0.81 Inexact Rounded +pwsx2722 power 0.066 0.5 -> 0.26 Inexact Rounded +pwsx2723 power 66.0E-1 0.5 -> 2.6 Inexact Rounded +pwsx2724 power 66.00E-2 0.5 -> 0.81 Inexact Rounded +pwsx2725 power 66E-3 0.5 -> 0.26 Inexact Rounded +pwsx2726 power 66E+1 0.5 -> 26 Inexact Rounded +pwsx2727 power 66E+2 0.5 -> 81 Inexact Rounded +pwsx2728 power 66E+3 0.5 -> 2.6E+2 Inexact Rounded +pwsx2729 power 0.67 0.5 -> 0.82 Inexact Rounded +pwsx2730 power 0.067 0.5 -> 0.26 Inexact Rounded +pwsx2731 power 67.0E-1 0.5 -> 2.6 Inexact Rounded +pwsx2732 power 67.00E-2 0.5 -> 0.82 Inexact Rounded +pwsx2733 power 67E-3 0.5 -> 0.26 Inexact Rounded +pwsx2734 power 67E+1 0.5 -> 26 Inexact Rounded +pwsx2735 power 67E+2 0.5 -> 82 Inexact Rounded +pwsx2736 power 67E+3 0.5 -> 2.6E+2 Inexact Rounded +pwsx2737 power 0.68 0.5 -> 0.82 Inexact Rounded +pwsx2738 power 0.068 0.5 -> 0.26 Inexact Rounded +pwsx2739 power 68.0E-1 0.5 -> 2.6 Inexact Rounded +pwsx2740 power 68.00E-2 0.5 -> 0.82 Inexact Rounded +pwsx2741 power 68E-3 0.5 -> 0.26 Inexact Rounded +pwsx2742 power 68E+1 0.5 -> 26 Inexact Rounded +pwsx2743 power 68E+2 0.5 -> 82 Inexact Rounded +pwsx2744 power 68E+3 0.5 -> 2.6E+2 Inexact Rounded +pwsx2745 power 0.69 0.5 -> 0.83 Inexact Rounded +pwsx2746 power 0.069 0.5 -> 0.26 Inexact Rounded +pwsx2747 power 69.0E-1 0.5 -> 2.6 Inexact Rounded +pwsx2748 power 69.00E-2 0.5 -> 0.83 Inexact Rounded +pwsx2749 power 69E-3 0.5 -> 0.26 Inexact Rounded +pwsx2750 power 69E+1 0.5 -> 26 Inexact Rounded +pwsx2751 power 69E+2 0.5 -> 83 Inexact Rounded +pwsx2752 power 69E+3 0.5 -> 2.6E+2 Inexact Rounded +pwsx2753 power 0.70 0.5 -> 0.84 Inexact Rounded +pwsx2754 power 0.070 0.5 -> 0.26 Inexact Rounded +pwsx2755 power 70.0E-1 0.5 -> 2.6 Inexact Rounded +pwsx2756 power 70.00E-2 0.5 -> 0.84 Inexact Rounded +pwsx2757 power 70E-3 0.5 -> 0.26 Inexact Rounded +pwsx2758 power 70E+1 0.5 -> 26 Inexact Rounded +pwsx2759 power 70E+2 0.5 -> 84 Inexact Rounded +pwsx2760 power 70E+3 0.5 -> 2.6E+2 Inexact Rounded +pwsx2761 power 0.71 0.5 -> 0.84 Inexact Rounded +pwsx2762 power 0.071 0.5 -> 0.27 Inexact Rounded +pwsx2763 power 71.0E-1 0.5 -> 2.7 Inexact Rounded +pwsx2764 power 71.00E-2 0.5 -> 0.84 Inexact Rounded +pwsx2765 power 71E-3 0.5 -> 0.27 Inexact Rounded +pwsx2766 power 71E+1 0.5 -> 27 Inexact Rounded +pwsx2767 power 71E+2 0.5 -> 84 Inexact Rounded +pwsx2768 power 71E+3 0.5 -> 2.7E+2 Inexact Rounded +pwsx2769 power 0.72 0.5 -> 0.85 Inexact Rounded +pwsx2770 power 0.072 0.5 -> 0.27 Inexact Rounded +pwsx2771 power 72.0E-1 0.5 -> 2.7 Inexact Rounded +pwsx2772 power 72.00E-2 0.5 -> 0.85 Inexact Rounded +pwsx2773 power 72E-3 0.5 -> 0.27 Inexact Rounded +pwsx2774 power 72E+1 0.5 -> 27 Inexact Rounded +pwsx2775 power 72E+2 0.5 -> 85 Inexact Rounded +pwsx2776 power 72E+3 0.5 -> 2.7E+2 Inexact Rounded +pwsx2777 power 0.73 0.5 -> 0.85 Inexact Rounded +pwsx2778 power 0.073 0.5 -> 0.27 Inexact Rounded +pwsx2779 power 73.0E-1 0.5 -> 2.7 Inexact Rounded +pwsx2780 power 73.00E-2 0.5 -> 0.85 Inexact Rounded +pwsx2781 power 73E-3 0.5 -> 0.27 Inexact Rounded +pwsx2782 power 73E+1 0.5 -> 27 Inexact Rounded +pwsx2783 power 73E+2 0.5 -> 85 Inexact Rounded +pwsx2784 power 73E+3 0.5 -> 2.7E+2 Inexact Rounded +pwsx2785 power 0.74 0.5 -> 0.86 Inexact Rounded +pwsx2786 power 0.074 0.5 -> 0.27 Inexact Rounded +pwsx2787 power 74.0E-1 0.5 -> 2.7 Inexact Rounded +pwsx2788 power 74.00E-2 0.5 -> 0.86 Inexact Rounded +pwsx2789 power 74E-3 0.5 -> 0.27 Inexact Rounded +pwsx2790 power 74E+1 0.5 -> 27 Inexact Rounded +pwsx2791 power 74E+2 0.5 -> 86 Inexact Rounded +pwsx2792 power 74E+3 0.5 -> 2.7E+2 Inexact Rounded +pwsx2793 power 0.75 0.5 -> 0.87 Inexact Rounded +pwsx2794 power 0.075 0.5 -> 0.27 Inexact Rounded +pwsx2795 power 75.0E-1 0.5 -> 2.7 Inexact Rounded +pwsx2796 power 75.00E-2 0.5 -> 0.87 Inexact Rounded +pwsx2797 power 75E-3 0.5 -> 0.27 Inexact Rounded +pwsx2798 power 75E+1 0.5 -> 27 Inexact Rounded +pwsx2799 power 75E+2 0.5 -> 87 Inexact Rounded +pwsx2800 power 75E+3 0.5 -> 2.7E+2 Inexact Rounded +pwsx2801 power 0.76 0.5 -> 0.87 Inexact Rounded +pwsx2802 power 0.076 0.5 -> 0.28 Inexact Rounded +pwsx2803 power 76.0E-1 0.5 -> 2.8 Inexact Rounded +pwsx2804 power 76.00E-2 0.5 -> 0.87 Inexact Rounded +pwsx2805 power 76E-3 0.5 -> 0.28 Inexact Rounded +pwsx2806 power 76E+1 0.5 -> 28 Inexact Rounded +pwsx2807 power 76E+2 0.5 -> 87 Inexact Rounded +pwsx2808 power 76E+3 0.5 -> 2.8E+2 Inexact Rounded +pwsx2809 power 0.77 0.5 -> 0.88 Inexact Rounded +pwsx2810 power 0.077 0.5 -> 0.28 Inexact Rounded +pwsx2811 power 77.0E-1 0.5 -> 2.8 Inexact Rounded +pwsx2812 power 77.00E-2 0.5 -> 0.88 Inexact Rounded +pwsx2813 power 77E-3 0.5 -> 0.28 Inexact Rounded +pwsx2814 power 77E+1 0.5 -> 28 Inexact Rounded +pwsx2815 power 77E+2 0.5 -> 88 Inexact Rounded +pwsx2816 power 77E+3 0.5 -> 2.8E+2 Inexact Rounded +pwsx2817 power 0.78 0.5 -> 0.88 Inexact Rounded +pwsx2818 power 0.078 0.5 -> 0.28 Inexact Rounded +pwsx2819 power 78.0E-1 0.5 -> 2.8 Inexact Rounded +pwsx2820 power 78.00E-2 0.5 -> 0.88 Inexact Rounded +pwsx2821 power 78E-3 0.5 -> 0.28 Inexact Rounded +pwsx2822 power 78E+1 0.5 -> 28 Inexact Rounded +pwsx2823 power 78E+2 0.5 -> 88 Inexact Rounded +pwsx2824 power 78E+3 0.5 -> 2.8E+2 Inexact Rounded +pwsx2825 power 0.79 0.5 -> 0.89 Inexact Rounded +pwsx2826 power 0.079 0.5 -> 0.28 Inexact Rounded +pwsx2827 power 79.0E-1 0.5 -> 2.8 Inexact Rounded +pwsx2828 power 79.00E-2 0.5 -> 0.89 Inexact Rounded +pwsx2829 power 79E-3 0.5 -> 0.28 Inexact Rounded +pwsx2830 power 79E+1 0.5 -> 28 Inexact Rounded +pwsx2831 power 79E+2 0.5 -> 89 Inexact Rounded +pwsx2832 power 79E+3 0.5 -> 2.8E+2 Inexact Rounded +pwsx2833 power 0.80 0.5 -> 0.89 Inexact Rounded +pwsx2834 power 0.080 0.5 -> 0.28 Inexact Rounded +pwsx2835 power 80.0E-1 0.5 -> 2.8 Inexact Rounded +pwsx2836 power 80.00E-2 0.5 -> 0.89 Inexact Rounded +pwsx2837 power 80E-3 0.5 -> 0.28 Inexact Rounded +pwsx2838 power 80E+1 0.5 -> 28 Inexact Rounded +pwsx2839 power 80E+2 0.5 -> 89 Inexact Rounded +pwsx2840 power 80E+3 0.5 -> 2.8E+2 Inexact Rounded +pwsx2841 power 0.81 0.5 -> 0.90 Inexact Rounded +pwsx2842 power 0.081 0.5 -> 0.28 Inexact Rounded +pwsx2843 power 81.0E-1 0.5 -> 2.8 Inexact Rounded +pwsx2844 power 81.00E-2 0.5 -> 0.90 Inexact Rounded +pwsx2845 power 81E-3 0.5 -> 0.28 Inexact Rounded +pwsx2846 power 81E+1 0.5 -> 28 Inexact Rounded +pwsx2847 power 81E+2 0.5 -> 90 Inexact Rounded +pwsx2848 power 81E+3 0.5 -> 2.8E+2 Inexact Rounded +pwsx2849 power 0.82 0.5 -> 0.91 Inexact Rounded +pwsx2850 power 0.082 0.5 -> 0.29 Inexact Rounded +pwsx2851 power 82.0E-1 0.5 -> 2.9 Inexact Rounded +pwsx2852 power 82.00E-2 0.5 -> 0.91 Inexact Rounded +pwsx2853 power 82E-3 0.5 -> 0.29 Inexact Rounded +pwsx2854 power 82E+1 0.5 -> 29 Inexact Rounded +pwsx2855 power 82E+2 0.5 -> 91 Inexact Rounded +pwsx2856 power 82E+3 0.5 -> 2.9E+2 Inexact Rounded +pwsx2857 power 0.83 0.5 -> 0.91 Inexact Rounded +pwsx2858 power 0.083 0.5 -> 0.29 Inexact Rounded +pwsx2859 power 83.0E-1 0.5 -> 2.9 Inexact Rounded +pwsx2860 power 83.00E-2 0.5 -> 0.91 Inexact Rounded +pwsx2861 power 83E-3 0.5 -> 0.29 Inexact Rounded +pwsx2862 power 83E+1 0.5 -> 29 Inexact Rounded +pwsx2863 power 83E+2 0.5 -> 91 Inexact Rounded +pwsx2864 power 83E+3 0.5 -> 2.9E+2 Inexact Rounded +pwsx2865 power 0.84 0.5 -> 0.92 Inexact Rounded +pwsx2866 power 0.084 0.5 -> 0.29 Inexact Rounded +pwsx2867 power 84.0E-1 0.5 -> 2.9 Inexact Rounded +pwsx2868 power 84.00E-2 0.5 -> 0.92 Inexact Rounded +pwsx2869 power 84E-3 0.5 -> 0.29 Inexact Rounded +pwsx2870 power 84E+1 0.5 -> 29 Inexact Rounded +pwsx2871 power 84E+2 0.5 -> 92 Inexact Rounded +pwsx2872 power 84E+3 0.5 -> 2.9E+2 Inexact Rounded +pwsx2873 power 0.85 0.5 -> 0.92 Inexact Rounded +pwsx2874 power 0.085 0.5 -> 0.29 Inexact Rounded +pwsx2875 power 85.0E-1 0.5 -> 2.9 Inexact Rounded +pwsx2876 power 85.00E-2 0.5 -> 0.92 Inexact Rounded +pwsx2877 power 85E-3 0.5 -> 0.29 Inexact Rounded +pwsx2878 power 85E+1 0.5 -> 29 Inexact Rounded +pwsx2879 power 85E+2 0.5 -> 92 Inexact Rounded +pwsx2880 power 85E+3 0.5 -> 2.9E+2 Inexact Rounded +pwsx2881 power 0.86 0.5 -> 0.93 Inexact Rounded +pwsx2882 power 0.086 0.5 -> 0.29 Inexact Rounded +pwsx2883 power 86.0E-1 0.5 -> 2.9 Inexact Rounded +pwsx2884 power 86.00E-2 0.5 -> 0.93 Inexact Rounded +pwsx2885 power 86E-3 0.5 -> 0.29 Inexact Rounded +pwsx2886 power 86E+1 0.5 -> 29 Inexact Rounded +pwsx2887 power 86E+2 0.5 -> 93 Inexact Rounded +pwsx2888 power 86E+3 0.5 -> 2.9E+2 Inexact Rounded +pwsx2889 power 0.87 0.5 -> 0.93 Inexact Rounded +pwsx2890 power 0.087 0.5 -> 0.29 Inexact Rounded +pwsx2891 power 87.0E-1 0.5 -> 2.9 Inexact Rounded +pwsx2892 power 87.00E-2 0.5 -> 0.93 Inexact Rounded +pwsx2893 power 87E-3 0.5 -> 0.29 Inexact Rounded +pwsx2894 power 87E+1 0.5 -> 29 Inexact Rounded +pwsx2895 power 87E+2 0.5 -> 93 Inexact Rounded +pwsx2896 power 87E+3 0.5 -> 2.9E+2 Inexact Rounded +pwsx2897 power 0.88 0.5 -> 0.94 Inexact Rounded +pwsx2898 power 0.088 0.5 -> 0.30 Inexact Rounded +pwsx2899 power 88.0E-1 0.5 -> 3.0 Inexact Rounded +pwsx2900 power 88.00E-2 0.5 -> 0.94 Inexact Rounded +pwsx2901 power 88E-3 0.5 -> 0.30 Inexact Rounded +pwsx2902 power 88E+1 0.5 -> 30 Inexact Rounded +pwsx2903 power 88E+2 0.5 -> 94 Inexact Rounded +pwsx2904 power 88E+3 0.5 -> 3.0E+2 Inexact Rounded +pwsx2905 power 0.89 0.5 -> 0.94 Inexact Rounded +pwsx2906 power 0.089 0.5 -> 0.30 Inexact Rounded +pwsx2907 power 89.0E-1 0.5 -> 3.0 Inexact Rounded +pwsx2908 power 89.00E-2 0.5 -> 0.94 Inexact Rounded +pwsx2909 power 89E-3 0.5 -> 0.30 Inexact Rounded +pwsx2910 power 89E+1 0.5 -> 30 Inexact Rounded +pwsx2911 power 89E+2 0.5 -> 94 Inexact Rounded +pwsx2912 power 89E+3 0.5 -> 3.0E+2 Inexact Rounded +pwsx2913 power 0.90 0.5 -> 0.95 Inexact Rounded +pwsx2914 power 0.090 0.5 -> 0.30 Inexact Rounded +pwsx2915 power 90.0E-1 0.5 -> 3.0 Inexact Rounded +pwsx2916 power 90.00E-2 0.5 -> 0.95 Inexact Rounded +pwsx2917 power 90E-3 0.5 -> 0.30 Inexact Rounded +pwsx2918 power 90E+1 0.5 -> 30 Inexact Rounded +pwsx2919 power 90E+2 0.5 -> 95 Inexact Rounded +pwsx2920 power 90E+3 0.5 -> 3.0E+2 Inexact Rounded +pwsx2921 power 0.91 0.5 -> 0.95 Inexact Rounded +pwsx2922 power 0.091 0.5 -> 0.30 Inexact Rounded +pwsx2923 power 91.0E-1 0.5 -> 3.0 Inexact Rounded +pwsx2924 power 91.00E-2 0.5 -> 0.95 Inexact Rounded +pwsx2925 power 91E-3 0.5 -> 0.30 Inexact Rounded +pwsx2926 power 91E+1 0.5 -> 30 Inexact Rounded +pwsx2927 power 91E+2 0.5 -> 95 Inexact Rounded +pwsx2928 power 91E+3 0.5 -> 3.0E+2 Inexact Rounded +pwsx2929 power 0.92 0.5 -> 0.96 Inexact Rounded +pwsx2930 power 0.092 0.5 -> 0.30 Inexact Rounded +pwsx2931 power 92.0E-1 0.5 -> 3.0 Inexact Rounded +pwsx2932 power 92.00E-2 0.5 -> 0.96 Inexact Rounded +pwsx2933 power 92E-3 0.5 -> 0.30 Inexact Rounded +pwsx2934 power 92E+1 0.5 -> 30 Inexact Rounded +pwsx2935 power 92E+2 0.5 -> 96 Inexact Rounded +pwsx2936 power 92E+3 0.5 -> 3.0E+2 Inexact Rounded +pwsx2937 power 0.93 0.5 -> 0.96 Inexact Rounded +pwsx2938 power 0.093 0.5 -> 0.30 Inexact Rounded +pwsx2939 power 93.0E-1 0.5 -> 3.0 Inexact Rounded +pwsx2940 power 93.00E-2 0.5 -> 0.96 Inexact Rounded +pwsx2941 power 93E-3 0.5 -> 0.30 Inexact Rounded +pwsx2942 power 93E+1 0.5 -> 30 Inexact Rounded +pwsx2943 power 93E+2 0.5 -> 96 Inexact Rounded +pwsx2944 power 93E+3 0.5 -> 3.0E+2 Inexact Rounded +pwsx2945 power 0.94 0.5 -> 0.97 Inexact Rounded +pwsx2946 power 0.094 0.5 -> 0.31 Inexact Rounded +pwsx2947 power 94.0E-1 0.5 -> 3.1 Inexact Rounded +pwsx2948 power 94.00E-2 0.5 -> 0.97 Inexact Rounded +pwsx2949 power 94E-3 0.5 -> 0.31 Inexact Rounded +pwsx2950 power 94E+1 0.5 -> 31 Inexact Rounded +pwsx2951 power 94E+2 0.5 -> 97 Inexact Rounded +pwsx2952 power 94E+3 0.5 -> 3.1E+2 Inexact Rounded +pwsx2953 power 0.95 0.5 -> 0.97 Inexact Rounded +pwsx2954 power 0.095 0.5 -> 0.31 Inexact Rounded +pwsx2955 power 95.0E-1 0.5 -> 3.1 Inexact Rounded +pwsx2956 power 95.00E-2 0.5 -> 0.97 Inexact Rounded +pwsx2957 power 95E-3 0.5 -> 0.31 Inexact Rounded +pwsx2958 power 95E+1 0.5 -> 31 Inexact Rounded +pwsx2959 power 95E+2 0.5 -> 97 Inexact Rounded +pwsx2960 power 95E+3 0.5 -> 3.1E+2 Inexact Rounded +pwsx2961 power 0.96 0.5 -> 0.98 Inexact Rounded +pwsx2962 power 0.096 0.5 -> 0.31 Inexact Rounded +pwsx2963 power 96.0E-1 0.5 -> 3.1 Inexact Rounded +pwsx2964 power 96.00E-2 0.5 -> 0.98 Inexact Rounded +pwsx2965 power 96E-3 0.5 -> 0.31 Inexact Rounded +pwsx2966 power 96E+1 0.5 -> 31 Inexact Rounded +pwsx2967 power 96E+2 0.5 -> 98 Inexact Rounded +pwsx2968 power 96E+3 0.5 -> 3.1E+2 Inexact Rounded +pwsx2969 power 0.97 0.5 -> 0.98 Inexact Rounded +pwsx2970 power 0.097 0.5 -> 0.31 Inexact Rounded +pwsx2971 power 97.0E-1 0.5 -> 3.1 Inexact Rounded +pwsx2972 power 97.00E-2 0.5 -> 0.98 Inexact Rounded +pwsx2973 power 97E-3 0.5 -> 0.31 Inexact Rounded +pwsx2974 power 97E+1 0.5 -> 31 Inexact Rounded +pwsx2975 power 97E+2 0.5 -> 98 Inexact Rounded +pwsx2976 power 97E+3 0.5 -> 3.1E+2 Inexact Rounded +pwsx2977 power 0.98 0.5 -> 0.99 Inexact Rounded +pwsx2978 power 0.098 0.5 -> 0.31 Inexact Rounded +pwsx2979 power 98.0E-1 0.5 -> 3.1 Inexact Rounded +pwsx2980 power 98.00E-2 0.5 -> 0.99 Inexact Rounded +pwsx2981 power 98E-3 0.5 -> 0.31 Inexact Rounded +pwsx2982 power 98E+1 0.5 -> 31 Inexact Rounded +pwsx2983 power 98E+2 0.5 -> 99 Inexact Rounded +pwsx2984 power 98E+3 0.5 -> 3.1E+2 Inexact Rounded +pwsx2985 power 0.99 0.5 -> 0.99 Inexact Rounded +pwsx2986 power 0.099 0.5 -> 0.31 Inexact Rounded +pwsx2987 power 99.0E-1 0.5 -> 3.1 Inexact Rounded +pwsx2988 power 99.00E-2 0.5 -> 0.99 Inexact Rounded +pwsx2989 power 99E-3 0.5 -> 0.31 Inexact Rounded +pwsx2990 power 99E+1 0.5 -> 31 Inexact Rounded +pwsx2991 power 99E+2 0.5 -> 99 Inexact Rounded +pwsx2992 power 99E+3 0.5 -> 3.1E+2 Inexact Rounded + +-- Precision 3 squareroot tests [exhaustive, f and f/10] +rounding: half_even +maxExponent: 999 +minexponent: -999 +precision: 3 +pwsx3001 power 0.1 0.5 -> 0.316 Inexact Rounded +pwsx3002 power 0.01 0.5 -> 0.100 Inexact Rounded +pwsx3003 power 0.2 0.5 -> 0.447 Inexact Rounded +pwsx3004 power 0.02 0.5 -> 0.141 Inexact Rounded +pwsx3005 power 0.3 0.5 -> 0.548 Inexact Rounded +pwsx3006 power 0.03 0.5 -> 0.173 Inexact Rounded +pwsx3007 power 0.4 0.5 -> 0.632 Inexact Rounded +pwsx3008 power 0.04 0.5 -> 0.200 Inexact Rounded +pwsx3009 power 0.5 0.5 -> 0.707 Inexact Rounded +pwsx3010 power 0.05 0.5 -> 0.224 Inexact Rounded +pwsx3011 power 0.6 0.5 -> 0.775 Inexact Rounded +pwsx3012 power 0.06 0.5 -> 0.245 Inexact Rounded +pwsx3013 power 0.7 0.5 -> 0.837 Inexact Rounded +pwsx3014 power 0.07 0.5 -> 0.265 Inexact Rounded +pwsx3015 power 0.8 0.5 -> 0.894 Inexact Rounded +pwsx3016 power 0.08 0.5 -> 0.283 Inexact Rounded +pwsx3017 power 0.9 0.5 -> 0.949 Inexact Rounded +pwsx3018 power 0.09 0.5 -> 0.300 Inexact Rounded +pwsx3019 power 0.11 0.5 -> 0.332 Inexact Rounded +pwsx3020 power 0.011 0.5 -> 0.105 Inexact Rounded +pwsx3021 power 0.12 0.5 -> 0.346 Inexact Rounded +pwsx3022 power 0.012 0.5 -> 0.110 Inexact Rounded +pwsx3023 power 0.13 0.5 -> 0.361 Inexact Rounded +pwsx3024 power 0.013 0.5 -> 0.114 Inexact Rounded +pwsx3025 power 0.14 0.5 -> 0.374 Inexact Rounded +pwsx3026 power 0.014 0.5 -> 0.118 Inexact Rounded +pwsx3027 power 0.15 0.5 -> 0.387 Inexact Rounded +pwsx3028 power 0.015 0.5 -> 0.122 Inexact Rounded +pwsx3029 power 0.16 0.5 -> 0.400 Inexact Rounded +pwsx3030 power 0.016 0.5 -> 0.126 Inexact Rounded +pwsx3031 power 0.17 0.5 -> 0.412 Inexact Rounded +pwsx3032 power 0.017 0.5 -> 0.130 Inexact Rounded +pwsx3033 power 0.18 0.5 -> 0.424 Inexact Rounded +pwsx3034 power 0.018 0.5 -> 0.134 Inexact Rounded +pwsx3035 power 0.19 0.5 -> 0.436 Inexact Rounded +pwsx3036 power 0.019 0.5 -> 0.138 Inexact Rounded +pwsx3037 power 0.21 0.5 -> 0.458 Inexact Rounded +pwsx3038 power 0.021 0.5 -> 0.145 Inexact Rounded +pwsx3039 power 0.22 0.5 -> 0.469 Inexact Rounded +pwsx3040 power 0.022 0.5 -> 0.148 Inexact Rounded +pwsx3041 power 0.23 0.5 -> 0.480 Inexact Rounded +pwsx3042 power 0.023 0.5 -> 0.152 Inexact Rounded +pwsx3043 power 0.24 0.5 -> 0.490 Inexact Rounded +pwsx3044 power 0.024 0.5 -> 0.155 Inexact Rounded +pwsx3045 power 0.25 0.5 -> 0.500 Inexact Rounded +pwsx3046 power 0.025 0.5 -> 0.158 Inexact Rounded +pwsx3047 power 0.26 0.5 -> 0.510 Inexact Rounded +pwsx3048 power 0.026 0.5 -> 0.161 Inexact Rounded +pwsx3049 power 0.27 0.5 -> 0.520 Inexact Rounded +pwsx3050 power 0.027 0.5 -> 0.164 Inexact Rounded +pwsx3051 power 0.28 0.5 -> 0.529 Inexact Rounded +pwsx3052 power 0.028 0.5 -> 0.167 Inexact Rounded +pwsx3053 power 0.29 0.5 -> 0.539 Inexact Rounded +pwsx3054 power 0.029 0.5 -> 0.170 Inexact Rounded +pwsx3055 power 0.31 0.5 -> 0.557 Inexact Rounded +pwsx3056 power 0.031 0.5 -> 0.176 Inexact Rounded +pwsx3057 power 0.32 0.5 -> 0.566 Inexact Rounded +pwsx3058 power 0.032 0.5 -> 0.179 Inexact Rounded +pwsx3059 power 0.33 0.5 -> 0.574 Inexact Rounded +pwsx3060 power 0.033 0.5 -> 0.182 Inexact Rounded +pwsx3061 power 0.34 0.5 -> 0.583 Inexact Rounded +pwsx3062 power 0.034 0.5 -> 0.184 Inexact Rounded +pwsx3063 power 0.35 0.5 -> 0.592 Inexact Rounded +pwsx3064 power 0.035 0.5 -> 0.187 Inexact Rounded +pwsx3065 power 0.36 0.5 -> 0.600 Inexact Rounded +pwsx3066 power 0.036 0.5 -> 0.190 Inexact Rounded +pwsx3067 power 0.37 0.5 -> 0.608 Inexact Rounded +pwsx3068 power 0.037 0.5 -> 0.192 Inexact Rounded +pwsx3069 power 0.38 0.5 -> 0.616 Inexact Rounded +pwsx3070 power 0.038 0.5 -> 0.195 Inexact Rounded +pwsx3071 power 0.39 0.5 -> 0.624 Inexact Rounded +pwsx3072 power 0.039 0.5 -> 0.197 Inexact Rounded +pwsx3073 power 0.41 0.5 -> 0.640 Inexact Rounded +pwsx3074 power 0.041 0.5 -> 0.202 Inexact Rounded +pwsx3075 power 0.42 0.5 -> 0.648 Inexact Rounded +pwsx3076 power 0.042 0.5 -> 0.205 Inexact Rounded +pwsx3077 power 0.43 0.5 -> 0.656 Inexact Rounded +pwsx3078 power 0.043 0.5 -> 0.207 Inexact Rounded +pwsx3079 power 0.44 0.5 -> 0.663 Inexact Rounded +pwsx3080 power 0.044 0.5 -> 0.210 Inexact Rounded +pwsx3081 power 0.45 0.5 -> 0.671 Inexact Rounded +pwsx3082 power 0.045 0.5 -> 0.212 Inexact Rounded +pwsx3083 power 0.46 0.5 -> 0.678 Inexact Rounded +pwsx3084 power 0.046 0.5 -> 0.214 Inexact Rounded +pwsx3085 power 0.47 0.5 -> 0.686 Inexact Rounded +pwsx3086 power 0.047 0.5 -> 0.217 Inexact Rounded +pwsx3087 power 0.48 0.5 -> 0.693 Inexact Rounded +pwsx3088 power 0.048 0.5 -> 0.219 Inexact Rounded +pwsx3089 power 0.49 0.5 -> 0.700 Inexact Rounded +pwsx3090 power 0.049 0.5 -> 0.221 Inexact Rounded +pwsx3091 power 0.51 0.5 -> 0.714 Inexact Rounded +pwsx3092 power 0.051 0.5 -> 0.226 Inexact Rounded +pwsx3093 power 0.52 0.5 -> 0.721 Inexact Rounded +pwsx3094 power 0.052 0.5 -> 0.228 Inexact Rounded +pwsx3095 power 0.53 0.5 -> 0.728 Inexact Rounded +pwsx3096 power 0.053 0.5 -> 0.230 Inexact Rounded +pwsx3097 power 0.54 0.5 -> 0.735 Inexact Rounded +pwsx3098 power 0.054 0.5 -> 0.232 Inexact Rounded +pwsx3099 power 0.55 0.5 -> 0.742 Inexact Rounded +pwsx3100 power 0.055 0.5 -> 0.235 Inexact Rounded +pwsx3101 power 0.56 0.5 -> 0.748 Inexact Rounded +pwsx3102 power 0.056 0.5 -> 0.237 Inexact Rounded +pwsx3103 power 0.57 0.5 -> 0.755 Inexact Rounded +pwsx3104 power 0.057 0.5 -> 0.239 Inexact Rounded +pwsx3105 power 0.58 0.5 -> 0.762 Inexact Rounded +pwsx3106 power 0.058 0.5 -> 0.241 Inexact Rounded +pwsx3107 power 0.59 0.5 -> 0.768 Inexact Rounded +pwsx3108 power 0.059 0.5 -> 0.243 Inexact Rounded +pwsx3109 power 0.61 0.5 -> 0.781 Inexact Rounded +pwsx3110 power 0.061 0.5 -> 0.247 Inexact Rounded +pwsx3111 power 0.62 0.5 -> 0.787 Inexact Rounded +pwsx3112 power 0.062 0.5 -> 0.249 Inexact Rounded +pwsx3113 power 0.63 0.5 -> 0.794 Inexact Rounded +pwsx3114 power 0.063 0.5 -> 0.251 Inexact Rounded +pwsx3115 power 0.64 0.5 -> 0.800 Inexact Rounded +pwsx3116 power 0.064 0.5 -> 0.253 Inexact Rounded +pwsx3117 power 0.65 0.5 -> 0.806 Inexact Rounded +pwsx3118 power 0.065 0.5 -> 0.255 Inexact Rounded +pwsx3119 power 0.66 0.5 -> 0.812 Inexact Rounded +pwsx3120 power 0.066 0.5 -> 0.257 Inexact Rounded +pwsx3121 power 0.67 0.5 -> 0.819 Inexact Rounded +pwsx3122 power 0.067 0.5 -> 0.259 Inexact Rounded +pwsx3123 power 0.68 0.5 -> 0.825 Inexact Rounded +pwsx3124 power 0.068 0.5 -> 0.261 Inexact Rounded +pwsx3125 power 0.69 0.5 -> 0.831 Inexact Rounded +pwsx3126 power 0.069 0.5 -> 0.263 Inexact Rounded +pwsx3127 power 0.71 0.5 -> 0.843 Inexact Rounded +pwsx3128 power 0.071 0.5 -> 0.266 Inexact Rounded +pwsx3129 power 0.72 0.5 -> 0.849 Inexact Rounded +pwsx3130 power 0.072 0.5 -> 0.268 Inexact Rounded +pwsx3131 power 0.73 0.5 -> 0.854 Inexact Rounded +pwsx3132 power 0.073 0.5 -> 0.270 Inexact Rounded +pwsx3133 power 0.74 0.5 -> 0.860 Inexact Rounded +pwsx3134 power 0.074 0.5 -> 0.272 Inexact Rounded +pwsx3135 power 0.75 0.5 -> 0.866 Inexact Rounded +pwsx3136 power 0.075 0.5 -> 0.274 Inexact Rounded +pwsx3137 power 0.76 0.5 -> 0.872 Inexact Rounded +pwsx3138 power 0.076 0.5 -> 0.276 Inexact Rounded +pwsx3139 power 0.77 0.5 -> 0.877 Inexact Rounded +pwsx3140 power 0.077 0.5 -> 0.277 Inexact Rounded +pwsx3141 power 0.78 0.5 -> 0.883 Inexact Rounded +pwsx3142 power 0.078 0.5 -> 0.279 Inexact Rounded +pwsx3143 power 0.79 0.5 -> 0.889 Inexact Rounded +pwsx3144 power 0.079 0.5 -> 0.281 Inexact Rounded +pwsx3145 power 0.81 0.5 -> 0.900 Inexact Rounded +pwsx3146 power 0.081 0.5 -> 0.285 Inexact Rounded +pwsx3147 power 0.82 0.5 -> 0.906 Inexact Rounded +pwsx3148 power 0.082 0.5 -> 0.286 Inexact Rounded +pwsx3149 power 0.83 0.5 -> 0.911 Inexact Rounded +pwsx3150 power 0.083 0.5 -> 0.288 Inexact Rounded +pwsx3151 power 0.84 0.5 -> 0.917 Inexact Rounded +pwsx3152 power 0.084 0.5 -> 0.290 Inexact Rounded +pwsx3153 power 0.85 0.5 -> 0.922 Inexact Rounded +pwsx3154 power 0.085 0.5 -> 0.292 Inexact Rounded +pwsx3155 power 0.86 0.5 -> 0.927 Inexact Rounded +pwsx3156 power 0.086 0.5 -> 0.293 Inexact Rounded +pwsx3157 power 0.87 0.5 -> 0.933 Inexact Rounded +pwsx3158 power 0.087 0.5 -> 0.295 Inexact Rounded +pwsx3159 power 0.88 0.5 -> 0.938 Inexact Rounded +pwsx3160 power 0.088 0.5 -> 0.297 Inexact Rounded +pwsx3161 power 0.89 0.5 -> 0.943 Inexact Rounded +pwsx3162 power 0.089 0.5 -> 0.298 Inexact Rounded +pwsx3163 power 0.91 0.5 -> 0.954 Inexact Rounded +pwsx3164 power 0.091 0.5 -> 0.302 Inexact Rounded +pwsx3165 power 0.92 0.5 -> 0.959 Inexact Rounded +pwsx3166 power 0.092 0.5 -> 0.303 Inexact Rounded +pwsx3167 power 0.93 0.5 -> 0.964 Inexact Rounded +pwsx3168 power 0.093 0.5 -> 0.305 Inexact Rounded +pwsx3169 power 0.94 0.5 -> 0.970 Inexact Rounded +pwsx3170 power 0.094 0.5 -> 0.307 Inexact Rounded +pwsx3171 power 0.95 0.5 -> 0.975 Inexact Rounded +pwsx3172 power 0.095 0.5 -> 0.308 Inexact Rounded +pwsx3173 power 0.96 0.5 -> 0.980 Inexact Rounded +pwsx3174 power 0.096 0.5 -> 0.310 Inexact Rounded +pwsx3175 power 0.97 0.5 -> 0.985 Inexact Rounded +pwsx3176 power 0.097 0.5 -> 0.311 Inexact Rounded +pwsx3177 power 0.98 0.5 -> 0.990 Inexact Rounded +pwsx3178 power 0.098 0.5 -> 0.313 Inexact Rounded +pwsx3179 power 0.99 0.5 -> 0.995 Inexact Rounded +pwsx3180 power 0.099 0.5 -> 0.315 Inexact Rounded +pwsx3181 power 0.101 0.5 -> 0.318 Inexact Rounded +pwsx3182 power 0.0101 0.5 -> 0.100 Inexact Rounded +pwsx3183 power 0.102 0.5 -> 0.319 Inexact Rounded +pwsx3184 power 0.0102 0.5 -> 0.101 Inexact Rounded +pwsx3185 power 0.103 0.5 -> 0.321 Inexact Rounded +pwsx3186 power 0.0103 0.5 -> 0.101 Inexact Rounded +pwsx3187 power 0.104 0.5 -> 0.322 Inexact Rounded +pwsx3188 power 0.0104 0.5 -> 0.102 Inexact Rounded +pwsx3189 power 0.105 0.5 -> 0.324 Inexact Rounded +pwsx3190 power 0.0105 0.5 -> 0.102 Inexact Rounded +pwsx3191 power 0.106 0.5 -> 0.326 Inexact Rounded +pwsx3192 power 0.0106 0.5 -> 0.103 Inexact Rounded +pwsx3193 power 0.107 0.5 -> 0.327 Inexact Rounded +pwsx3194 power 0.0107 0.5 -> 0.103 Inexact Rounded +pwsx3195 power 0.108 0.5 -> 0.329 Inexact Rounded +pwsx3196 power 0.0108 0.5 -> 0.104 Inexact Rounded +pwsx3197 power 0.109 0.5 -> 0.330 Inexact Rounded +pwsx3198 power 0.0109 0.5 -> 0.104 Inexact Rounded +pwsx3199 power 0.111 0.5 -> 0.333 Inexact Rounded +pwsx3200 power 0.0111 0.5 -> 0.105 Inexact Rounded +pwsx3201 power 0.112 0.5 -> 0.335 Inexact Rounded +pwsx3202 power 0.0112 0.5 -> 0.106 Inexact Rounded +pwsx3203 power 0.113 0.5 -> 0.336 Inexact Rounded +pwsx3204 power 0.0113 0.5 -> 0.106 Inexact Rounded +pwsx3205 power 0.114 0.5 -> 0.338 Inexact Rounded +pwsx3206 power 0.0114 0.5 -> 0.107 Inexact Rounded +pwsx3207 power 0.115 0.5 -> 0.339 Inexact Rounded +pwsx3208 power 0.0115 0.5 -> 0.107 Inexact Rounded +pwsx3209 power 0.116 0.5 -> 0.341 Inexact Rounded +pwsx3210 power 0.0116 0.5 -> 0.108 Inexact Rounded +pwsx3211 power 0.117 0.5 -> 0.342 Inexact Rounded +pwsx3212 power 0.0117 0.5 -> 0.108 Inexact Rounded +pwsx3213 power 0.118 0.5 -> 0.344 Inexact Rounded +pwsx3214 power 0.0118 0.5 -> 0.109 Inexact Rounded +pwsx3215 power 0.119 0.5 -> 0.345 Inexact Rounded +pwsx3216 power 0.0119 0.5 -> 0.109 Inexact Rounded +pwsx3217 power 0.121 0.5 -> 0.348 Inexact Rounded +pwsx3218 power 0.0121 0.5 -> 0.110 Inexact Rounded +pwsx3219 power 0.122 0.5 -> 0.349 Inexact Rounded +pwsx3220 power 0.0122 0.5 -> 0.110 Inexact Rounded +pwsx3221 power 0.123 0.5 -> 0.351 Inexact Rounded +pwsx3222 power 0.0123 0.5 -> 0.111 Inexact Rounded +pwsx3223 power 0.124 0.5 -> 0.352 Inexact Rounded +pwsx3224 power 0.0124 0.5 -> 0.111 Inexact Rounded +pwsx3225 power 0.125 0.5 -> 0.354 Inexact Rounded +pwsx3226 power 0.0125 0.5 -> 0.112 Inexact Rounded +pwsx3227 power 0.126 0.5 -> 0.355 Inexact Rounded +pwsx3228 power 0.0126 0.5 -> 0.112 Inexact Rounded +pwsx3229 power 0.127 0.5 -> 0.356 Inexact Rounded +pwsx3230 power 0.0127 0.5 -> 0.113 Inexact Rounded +pwsx3231 power 0.128 0.5 -> 0.358 Inexact Rounded +pwsx3232 power 0.0128 0.5 -> 0.113 Inexact Rounded +pwsx3233 power 0.129 0.5 -> 0.359 Inexact Rounded +pwsx3234 power 0.0129 0.5 -> 0.114 Inexact Rounded +pwsx3235 power 0.131 0.5 -> 0.362 Inexact Rounded +pwsx3236 power 0.0131 0.5 -> 0.114 Inexact Rounded +pwsx3237 power 0.132 0.5 -> 0.363 Inexact Rounded +pwsx3238 power 0.0132 0.5 -> 0.115 Inexact Rounded +pwsx3239 power 0.133 0.5 -> 0.365 Inexact Rounded +pwsx3240 power 0.0133 0.5 -> 0.115 Inexact Rounded +pwsx3241 power 0.134 0.5 -> 0.366 Inexact Rounded +pwsx3242 power 0.0134 0.5 -> 0.116 Inexact Rounded +pwsx3243 power 0.135 0.5 -> 0.367 Inexact Rounded +pwsx3244 power 0.0135 0.5 -> 0.116 Inexact Rounded +pwsx3245 power 0.136 0.5 -> 0.369 Inexact Rounded +pwsx3246 power 0.0136 0.5 -> 0.117 Inexact Rounded +pwsx3247 power 0.137 0.5 -> 0.370 Inexact Rounded +pwsx3248 power 0.0137 0.5 -> 0.117 Inexact Rounded +pwsx3249 power 0.138 0.5 -> 0.371 Inexact Rounded +pwsx3250 power 0.0138 0.5 -> 0.117 Inexact Rounded +pwsx3251 power 0.139 0.5 -> 0.373 Inexact Rounded +pwsx3252 power 0.0139 0.5 -> 0.118 Inexact Rounded +pwsx3253 power 0.141 0.5 -> 0.375 Inexact Rounded +pwsx3254 power 0.0141 0.5 -> 0.119 Inexact Rounded +pwsx3255 power 0.142 0.5 -> 0.377 Inexact Rounded +pwsx3256 power 0.0142 0.5 -> 0.119 Inexact Rounded +pwsx3257 power 0.143 0.5 -> 0.378 Inexact Rounded +pwsx3258 power 0.0143 0.5 -> 0.120 Inexact Rounded +pwsx3259 power 0.144 0.5 -> 0.379 Inexact Rounded +pwsx3260 power 0.0144 0.5 -> 0.120 Inexact Rounded +pwsx3261 power 0.145 0.5 -> 0.381 Inexact Rounded +pwsx3262 power 0.0145 0.5 -> 0.120 Inexact Rounded +pwsx3263 power 0.146 0.5 -> 0.382 Inexact Rounded +pwsx3264 power 0.0146 0.5 -> 0.121 Inexact Rounded +pwsx3265 power 0.147 0.5 -> 0.383 Inexact Rounded +pwsx3266 power 0.0147 0.5 -> 0.121 Inexact Rounded +pwsx3267 power 0.148 0.5 -> 0.385 Inexact Rounded +pwsx3268 power 0.0148 0.5 -> 0.122 Inexact Rounded +pwsx3269 power 0.149 0.5 -> 0.386 Inexact Rounded +pwsx3270 power 0.0149 0.5 -> 0.122 Inexact Rounded +pwsx3271 power 0.151 0.5 -> 0.389 Inexact Rounded +pwsx3272 power 0.0151 0.5 -> 0.123 Inexact Rounded +pwsx3273 power 0.152 0.5 -> 0.390 Inexact Rounded +pwsx3274 power 0.0152 0.5 -> 0.123 Inexact Rounded +pwsx3275 power 0.153 0.5 -> 0.391 Inexact Rounded +pwsx3276 power 0.0153 0.5 -> 0.124 Inexact Rounded +pwsx3277 power 0.154 0.5 -> 0.392 Inexact Rounded +pwsx3278 power 0.0154 0.5 -> 0.124 Inexact Rounded +pwsx3279 power 0.155 0.5 -> 0.394 Inexact Rounded +pwsx3280 power 0.0155 0.5 -> 0.124 Inexact Rounded +pwsx3281 power 0.156 0.5 -> 0.395 Inexact Rounded +pwsx3282 power 0.0156 0.5 -> 0.125 Inexact Rounded +pwsx3283 power 0.157 0.5 -> 0.396 Inexact Rounded +pwsx3284 power 0.0157 0.5 -> 0.125 Inexact Rounded +pwsx3285 power 0.158 0.5 -> 0.397 Inexact Rounded +pwsx3286 power 0.0158 0.5 -> 0.126 Inexact Rounded +pwsx3287 power 0.159 0.5 -> 0.399 Inexact Rounded +pwsx3288 power 0.0159 0.5 -> 0.126 Inexact Rounded +pwsx3289 power 0.161 0.5 -> 0.401 Inexact Rounded +pwsx3290 power 0.0161 0.5 -> 0.127 Inexact Rounded +pwsx3291 power 0.162 0.5 -> 0.402 Inexact Rounded +pwsx3292 power 0.0162 0.5 -> 0.127 Inexact Rounded +pwsx3293 power 0.163 0.5 -> 0.404 Inexact Rounded +pwsx3294 power 0.0163 0.5 -> 0.128 Inexact Rounded +pwsx3295 power 0.164 0.5 -> 0.405 Inexact Rounded +pwsx3296 power 0.0164 0.5 -> 0.128 Inexact Rounded +pwsx3297 power 0.165 0.5 -> 0.406 Inexact Rounded +pwsx3298 power 0.0165 0.5 -> 0.128 Inexact Rounded +pwsx3299 power 0.166 0.5 -> 0.407 Inexact Rounded +pwsx3300 power 0.0166 0.5 -> 0.129 Inexact Rounded +pwsx3301 power 0.167 0.5 -> 0.409 Inexact Rounded +pwsx3302 power 0.0167 0.5 -> 0.129 Inexact Rounded +pwsx3303 power 0.168 0.5 -> 0.410 Inexact Rounded +pwsx3304 power 0.0168 0.5 -> 0.130 Inexact Rounded +pwsx3305 power 0.169 0.5 -> 0.411 Inexact Rounded +pwsx3306 power 0.0169 0.5 -> 0.130 Inexact Rounded +pwsx3307 power 0.171 0.5 -> 0.414 Inexact Rounded +pwsx3308 power 0.0171 0.5 -> 0.131 Inexact Rounded +pwsx3309 power 0.172 0.5 -> 0.415 Inexact Rounded +pwsx3310 power 0.0172 0.5 -> 0.131 Inexact Rounded +pwsx3311 power 0.173 0.5 -> 0.416 Inexact Rounded +pwsx3312 power 0.0173 0.5 -> 0.132 Inexact Rounded +pwsx3313 power 0.174 0.5 -> 0.417 Inexact Rounded +pwsx3314 power 0.0174 0.5 -> 0.132 Inexact Rounded +pwsx3315 power 0.175 0.5 -> 0.418 Inexact Rounded +pwsx3316 power 0.0175 0.5 -> 0.132 Inexact Rounded +pwsx3317 power 0.176 0.5 -> 0.420 Inexact Rounded +pwsx3318 power 0.0176 0.5 -> 0.133 Inexact Rounded +pwsx3319 power 0.177 0.5 -> 0.421 Inexact Rounded +pwsx3320 power 0.0177 0.5 -> 0.133 Inexact Rounded +pwsx3321 power 0.178 0.5 -> 0.422 Inexact Rounded +pwsx3322 power 0.0178 0.5 -> 0.133 Inexact Rounded +pwsx3323 power 0.179 0.5 -> 0.423 Inexact Rounded +pwsx3324 power 0.0179 0.5 -> 0.134 Inexact Rounded +pwsx3325 power 0.181 0.5 -> 0.425 Inexact Rounded +pwsx3326 power 0.0181 0.5 -> 0.135 Inexact Rounded +pwsx3327 power 0.182 0.5 -> 0.427 Inexact Rounded +pwsx3328 power 0.0182 0.5 -> 0.135 Inexact Rounded +pwsx3329 power 0.183 0.5 -> 0.428 Inexact Rounded +pwsx3330 power 0.0183 0.5 -> 0.135 Inexact Rounded +pwsx3331 power 0.184 0.5 -> 0.429 Inexact Rounded +pwsx3332 power 0.0184 0.5 -> 0.136 Inexact Rounded +pwsx3333 power 0.185 0.5 -> 0.430 Inexact Rounded +pwsx3334 power 0.0185 0.5 -> 0.136 Inexact Rounded +pwsx3335 power 0.186 0.5 -> 0.431 Inexact Rounded +pwsx3336 power 0.0186 0.5 -> 0.136 Inexact Rounded +pwsx3337 power 0.187 0.5 -> 0.432 Inexact Rounded +pwsx3338 power 0.0187 0.5 -> 0.137 Inexact Rounded +pwsx3339 power 0.188 0.5 -> 0.434 Inexact Rounded +pwsx3340 power 0.0188 0.5 -> 0.137 Inexact Rounded +pwsx3341 power 0.189 0.5 -> 0.435 Inexact Rounded +pwsx3342 power 0.0189 0.5 -> 0.137 Inexact Rounded +pwsx3343 power 0.191 0.5 -> 0.437 Inexact Rounded +pwsx3344 power 0.0191 0.5 -> 0.138 Inexact Rounded +pwsx3345 power 0.192 0.5 -> 0.438 Inexact Rounded +pwsx3346 power 0.0192 0.5 -> 0.139 Inexact Rounded +pwsx3347 power 0.193 0.5 -> 0.439 Inexact Rounded +pwsx3348 power 0.0193 0.5 -> 0.139 Inexact Rounded +pwsx3349 power 0.194 0.5 -> 0.440 Inexact Rounded +pwsx3350 power 0.0194 0.5 -> 0.139 Inexact Rounded +pwsx3351 power 0.195 0.5 -> 0.442 Inexact Rounded +pwsx3352 power 0.0195 0.5 -> 0.140 Inexact Rounded +pwsx3353 power 0.196 0.5 -> 0.443 Inexact Rounded +pwsx3354 power 0.0196 0.5 -> 0.140 Inexact Rounded +pwsx3355 power 0.197 0.5 -> 0.444 Inexact Rounded +pwsx3356 power 0.0197 0.5 -> 0.140 Inexact Rounded +pwsx3357 power 0.198 0.5 -> 0.445 Inexact Rounded +pwsx3358 power 0.0198 0.5 -> 0.141 Inexact Rounded +pwsx3359 power 0.199 0.5 -> 0.446 Inexact Rounded +pwsx3360 power 0.0199 0.5 -> 0.141 Inexact Rounded +pwsx3361 power 0.201 0.5 -> 0.448 Inexact Rounded +pwsx3362 power 0.0201 0.5 -> 0.142 Inexact Rounded +pwsx3363 power 0.202 0.5 -> 0.449 Inexact Rounded +pwsx3364 power 0.0202 0.5 -> 0.142 Inexact Rounded +pwsx3365 power 0.203 0.5 -> 0.451 Inexact Rounded +pwsx3366 power 0.0203 0.5 -> 0.142 Inexact Rounded +pwsx3367 power 0.204 0.5 -> 0.452 Inexact Rounded +pwsx3368 power 0.0204 0.5 -> 0.143 Inexact Rounded +pwsx3369 power 0.205 0.5 -> 0.453 Inexact Rounded +pwsx3370 power 0.0205 0.5 -> 0.143 Inexact Rounded +pwsx3371 power 0.206 0.5 -> 0.454 Inexact Rounded +pwsx3372 power 0.0206 0.5 -> 0.144 Inexact Rounded +pwsx3373 power 0.207 0.5 -> 0.455 Inexact Rounded +pwsx3374 power 0.0207 0.5 -> 0.144 Inexact Rounded +pwsx3375 power 0.208 0.5 -> 0.456 Inexact Rounded +pwsx3376 power 0.0208 0.5 -> 0.144 Inexact Rounded +pwsx3377 power 0.209 0.5 -> 0.457 Inexact Rounded +pwsx3378 power 0.0209 0.5 -> 0.145 Inexact Rounded +pwsx3379 power 0.211 0.5 -> 0.459 Inexact Rounded +pwsx3380 power 0.0211 0.5 -> 0.145 Inexact Rounded +pwsx3381 power 0.212 0.5 -> 0.460 Inexact Rounded +pwsx3382 power 0.0212 0.5 -> 0.146 Inexact Rounded +pwsx3383 power 0.213 0.5 -> 0.462 Inexact Rounded +pwsx3384 power 0.0213 0.5 -> 0.146 Inexact Rounded +pwsx3385 power 0.214 0.5 -> 0.463 Inexact Rounded +pwsx3386 power 0.0214 0.5 -> 0.146 Inexact Rounded +pwsx3387 power 0.215 0.5 -> 0.464 Inexact Rounded +pwsx3388 power 0.0215 0.5 -> 0.147 Inexact Rounded +pwsx3389 power 0.216 0.5 -> 0.465 Inexact Rounded +pwsx3390 power 0.0216 0.5 -> 0.147 Inexact Rounded +pwsx3391 power 0.217 0.5 -> 0.466 Inexact Rounded +pwsx3392 power 0.0217 0.5 -> 0.147 Inexact Rounded +pwsx3393 power 0.218 0.5 -> 0.467 Inexact Rounded +pwsx3394 power 0.0218 0.5 -> 0.148 Inexact Rounded +pwsx3395 power 0.219 0.5 -> 0.468 Inexact Rounded +pwsx3396 power 0.0219 0.5 -> 0.148 Inexact Rounded +pwsx3397 power 0.221 0.5 -> 0.470 Inexact Rounded +pwsx3398 power 0.0221 0.5 -> 0.149 Inexact Rounded +pwsx3399 power 0.222 0.5 -> 0.471 Inexact Rounded +pwsx3400 power 0.0222 0.5 -> 0.149 Inexact Rounded +pwsx3401 power 0.223 0.5 -> 0.472 Inexact Rounded +pwsx3402 power 0.0223 0.5 -> 0.149 Inexact Rounded +pwsx3403 power 0.224 0.5 -> 0.473 Inexact Rounded +pwsx3404 power 0.0224 0.5 -> 0.150 Inexact Rounded +pwsx3405 power 0.225 0.5 -> 0.474 Inexact Rounded +pwsx3406 power 0.0225 0.5 -> 0.150 Inexact Rounded +pwsx3407 power 0.226 0.5 -> 0.475 Inexact Rounded +pwsx3408 power 0.0226 0.5 -> 0.150 Inexact Rounded +pwsx3409 power 0.227 0.5 -> 0.476 Inexact Rounded +pwsx3410 power 0.0227 0.5 -> 0.151 Inexact Rounded +pwsx3411 power 0.228 0.5 -> 0.477 Inexact Rounded +pwsx3412 power 0.0228 0.5 -> 0.151 Inexact Rounded +pwsx3413 power 0.229 0.5 -> 0.479 Inexact Rounded +pwsx3414 power 0.0229 0.5 -> 0.151 Inexact Rounded +pwsx3415 power 0.231 0.5 -> 0.481 Inexact Rounded +pwsx3416 power 0.0231 0.5 -> 0.152 Inexact Rounded +pwsx3417 power 0.232 0.5 -> 0.482 Inexact Rounded +pwsx3418 power 0.0232 0.5 -> 0.152 Inexact Rounded +pwsx3419 power 0.233 0.5 -> 0.483 Inexact Rounded +pwsx3420 power 0.0233 0.5 -> 0.153 Inexact Rounded +pwsx3421 power 0.234 0.5 -> 0.484 Inexact Rounded +pwsx3422 power 0.0234 0.5 -> 0.153 Inexact Rounded +pwsx3423 power 0.235 0.5 -> 0.485 Inexact Rounded +pwsx3424 power 0.0235 0.5 -> 0.153 Inexact Rounded +pwsx3425 power 0.236 0.5 -> 0.486 Inexact Rounded +pwsx3426 power 0.0236 0.5 -> 0.154 Inexact Rounded +pwsx3427 power 0.237 0.5 -> 0.487 Inexact Rounded +pwsx3428 power 0.0237 0.5 -> 0.154 Inexact Rounded +pwsx3429 power 0.238 0.5 -> 0.488 Inexact Rounded +pwsx3430 power 0.0238 0.5 -> 0.154 Inexact Rounded +pwsx3431 power 0.239 0.5 -> 0.489 Inexact Rounded +pwsx3432 power 0.0239 0.5 -> 0.155 Inexact Rounded +pwsx3433 power 0.241 0.5 -> 0.491 Inexact Rounded +pwsx3434 power 0.0241 0.5 -> 0.155 Inexact Rounded +pwsx3435 power 0.242 0.5 -> 0.492 Inexact Rounded +pwsx3436 power 0.0242 0.5 -> 0.156 Inexact Rounded +pwsx3437 power 0.243 0.5 -> 0.493 Inexact Rounded +pwsx3438 power 0.0243 0.5 -> 0.156 Inexact Rounded +pwsx3439 power 0.244 0.5 -> 0.494 Inexact Rounded +pwsx3440 power 0.0244 0.5 -> 0.156 Inexact Rounded +pwsx3441 power 0.245 0.5 -> 0.495 Inexact Rounded +pwsx3442 power 0.0245 0.5 -> 0.157 Inexact Rounded +pwsx3443 power 0.246 0.5 -> 0.496 Inexact Rounded +pwsx3444 power 0.0246 0.5 -> 0.157 Inexact Rounded +pwsx3445 power 0.247 0.5 -> 0.497 Inexact Rounded +pwsx3446 power 0.0247 0.5 -> 0.157 Inexact Rounded +pwsx3447 power 0.248 0.5 -> 0.498 Inexact Rounded +pwsx3448 power 0.0248 0.5 -> 0.157 Inexact Rounded +pwsx3449 power 0.249 0.5 -> 0.499 Inexact Rounded +pwsx3450 power 0.0249 0.5 -> 0.158 Inexact Rounded +pwsx3451 power 0.251 0.5 -> 0.501 Inexact Rounded +pwsx3452 power 0.0251 0.5 -> 0.158 Inexact Rounded +pwsx3453 power 0.252 0.5 -> 0.502 Inexact Rounded +pwsx3454 power 0.0252 0.5 -> 0.159 Inexact Rounded +pwsx3455 power 0.253 0.5 -> 0.503 Inexact Rounded +pwsx3456 power 0.0253 0.5 -> 0.159 Inexact Rounded +pwsx3457 power 0.254 0.5 -> 0.504 Inexact Rounded +pwsx3458 power 0.0254 0.5 -> 0.159 Inexact Rounded +pwsx3459 power 0.255 0.5 -> 0.505 Inexact Rounded +pwsx3460 power 0.0255 0.5 -> 0.160 Inexact Rounded +pwsx3461 power 0.256 0.5 -> 0.506 Inexact Rounded +pwsx3462 power 0.0256 0.5 -> 0.160 Inexact Rounded +pwsx3463 power 0.257 0.5 -> 0.507 Inexact Rounded +pwsx3464 power 0.0257 0.5 -> 0.160 Inexact Rounded +pwsx3465 power 0.258 0.5 -> 0.508 Inexact Rounded +pwsx3466 power 0.0258 0.5 -> 0.161 Inexact Rounded +pwsx3467 power 0.259 0.5 -> 0.509 Inexact Rounded +pwsx3468 power 0.0259 0.5 -> 0.161 Inexact Rounded +pwsx3469 power 0.261 0.5 -> 0.511 Inexact Rounded +pwsx3470 power 0.0261 0.5 -> 0.162 Inexact Rounded +pwsx3471 power 0.262 0.5 -> 0.512 Inexact Rounded +pwsx3472 power 0.0262 0.5 -> 0.162 Inexact Rounded +pwsx3473 power 0.263 0.5 -> 0.513 Inexact Rounded +pwsx3474 power 0.0263 0.5 -> 0.162 Inexact Rounded +pwsx3475 power 0.264 0.5 -> 0.514 Inexact Rounded +pwsx3476 power 0.0264 0.5 -> 0.162 Inexact Rounded +pwsx3477 power 0.265 0.5 -> 0.515 Inexact Rounded +pwsx3478 power 0.0265 0.5 -> 0.163 Inexact Rounded +pwsx3479 power 0.266 0.5 -> 0.516 Inexact Rounded +pwsx3480 power 0.0266 0.5 -> 0.163 Inexact Rounded +pwsx3481 power 0.267 0.5 -> 0.517 Inexact Rounded +pwsx3482 power 0.0267 0.5 -> 0.163 Inexact Rounded +pwsx3483 power 0.268 0.5 -> 0.518 Inexact Rounded +pwsx3484 power 0.0268 0.5 -> 0.164 Inexact Rounded +pwsx3485 power 0.269 0.5 -> 0.519 Inexact Rounded +pwsx3486 power 0.0269 0.5 -> 0.164 Inexact Rounded +pwsx3487 power 0.271 0.5 -> 0.521 Inexact Rounded +pwsx3488 power 0.0271 0.5 -> 0.165 Inexact Rounded +pwsx3489 power 0.272 0.5 -> 0.522 Inexact Rounded +pwsx3490 power 0.0272 0.5 -> 0.165 Inexact Rounded +pwsx3491 power 0.273 0.5 -> 0.522 Inexact Rounded +pwsx3492 power 0.0273 0.5 -> 0.165 Inexact Rounded +pwsx3493 power 0.274 0.5 -> 0.523 Inexact Rounded +pwsx3494 power 0.0274 0.5 -> 0.166 Inexact Rounded +pwsx3495 power 0.275 0.5 -> 0.524 Inexact Rounded +pwsx3496 power 0.0275 0.5 -> 0.166 Inexact Rounded +pwsx3497 power 0.276 0.5 -> 0.525 Inexact Rounded +pwsx3498 power 0.0276 0.5 -> 0.166 Inexact Rounded +pwsx3499 power 0.277 0.5 -> 0.526 Inexact Rounded +pwsx3500 power 0.0277 0.5 -> 0.166 Inexact Rounded +pwsx3501 power 0.278 0.5 -> 0.527 Inexact Rounded +pwsx3502 power 0.0278 0.5 -> 0.167 Inexact Rounded +pwsx3503 power 0.279 0.5 -> 0.528 Inexact Rounded +pwsx3504 power 0.0279 0.5 -> 0.167 Inexact Rounded +pwsx3505 power 0.281 0.5 -> 0.530 Inexact Rounded +pwsx3506 power 0.0281 0.5 -> 0.168 Inexact Rounded +pwsx3507 power 0.282 0.5 -> 0.531 Inexact Rounded +pwsx3508 power 0.0282 0.5 -> 0.168 Inexact Rounded +pwsx3509 power 0.283 0.5 -> 0.532 Inexact Rounded +pwsx3510 power 0.0283 0.5 -> 0.168 Inexact Rounded +pwsx3511 power 0.284 0.5 -> 0.533 Inexact Rounded +pwsx3512 power 0.0284 0.5 -> 0.169 Inexact Rounded +pwsx3513 power 0.285 0.5 -> 0.534 Inexact Rounded +pwsx3514 power 0.0285 0.5 -> 0.169 Inexact Rounded +pwsx3515 power 0.286 0.5 -> 0.535 Inexact Rounded +pwsx3516 power 0.0286 0.5 -> 0.169 Inexact Rounded +pwsx3517 power 0.287 0.5 -> 0.536 Inexact Rounded +pwsx3518 power 0.0287 0.5 -> 0.169 Inexact Rounded +pwsx3519 power 0.288 0.5 -> 0.537 Inexact Rounded +pwsx3520 power 0.0288 0.5 -> 0.170 Inexact Rounded +pwsx3521 power 0.289 0.5 -> 0.538 Inexact Rounded +pwsx3522 power 0.0289 0.5 -> 0.170 Inexact Rounded +pwsx3523 power 0.291 0.5 -> 0.539 Inexact Rounded +pwsx3524 power 0.0291 0.5 -> 0.171 Inexact Rounded +pwsx3525 power 0.292 0.5 -> 0.540 Inexact Rounded +pwsx3526 power 0.0292 0.5 -> 0.171 Inexact Rounded +pwsx3527 power 0.293 0.5 -> 0.541 Inexact Rounded +pwsx3528 power 0.0293 0.5 -> 0.171 Inexact Rounded +pwsx3529 power 0.294 0.5 -> 0.542 Inexact Rounded +pwsx3530 power 0.0294 0.5 -> 0.171 Inexact Rounded +pwsx3531 power 0.295 0.5 -> 0.543 Inexact Rounded +pwsx3532 power 0.0295 0.5 -> 0.172 Inexact Rounded +pwsx3533 power 0.296 0.5 -> 0.544 Inexact Rounded +pwsx3534 power 0.0296 0.5 -> 0.172 Inexact Rounded +pwsx3535 power 0.297 0.5 -> 0.545 Inexact Rounded +pwsx3536 power 0.0297 0.5 -> 0.172 Inexact Rounded +pwsx3537 power 0.298 0.5 -> 0.546 Inexact Rounded +pwsx3538 power 0.0298 0.5 -> 0.173 Inexact Rounded +pwsx3539 power 0.299 0.5 -> 0.547 Inexact Rounded +pwsx3540 power 0.0299 0.5 -> 0.173 Inexact Rounded +pwsx3541 power 0.301 0.5 -> 0.549 Inexact Rounded +pwsx3542 power 0.0301 0.5 -> 0.173 Inexact Rounded +pwsx3543 power 0.302 0.5 -> 0.550 Inexact Rounded +pwsx3544 power 0.0302 0.5 -> 0.174 Inexact Rounded +pwsx3545 power 0.303 0.5 -> 0.550 Inexact Rounded +pwsx3546 power 0.0303 0.5 -> 0.174 Inexact Rounded +pwsx3547 power 0.304 0.5 -> 0.551 Inexact Rounded +pwsx3548 power 0.0304 0.5 -> 0.174 Inexact Rounded +pwsx3549 power 0.305 0.5 -> 0.552 Inexact Rounded +pwsx3550 power 0.0305 0.5 -> 0.175 Inexact Rounded +pwsx3551 power 0.306 0.5 -> 0.553 Inexact Rounded +pwsx3552 power 0.0306 0.5 -> 0.175 Inexact Rounded +pwsx3553 power 0.307 0.5 -> 0.554 Inexact Rounded +pwsx3554 power 0.0307 0.5 -> 0.175 Inexact Rounded +pwsx3555 power 0.308 0.5 -> 0.555 Inexact Rounded +pwsx3556 power 0.0308 0.5 -> 0.175 Inexact Rounded +pwsx3557 power 0.309 0.5 -> 0.556 Inexact Rounded +pwsx3558 power 0.0309 0.5 -> 0.176 Inexact Rounded +pwsx3559 power 0.311 0.5 -> 0.558 Inexact Rounded +pwsx3560 power 0.0311 0.5 -> 0.176 Inexact Rounded +pwsx3561 power 0.312 0.5 -> 0.559 Inexact Rounded +pwsx3562 power 0.0312 0.5 -> 0.177 Inexact Rounded +pwsx3563 power 0.313 0.5 -> 0.559 Inexact Rounded +pwsx3564 power 0.0313 0.5 -> 0.177 Inexact Rounded +pwsx3565 power 0.314 0.5 -> 0.560 Inexact Rounded +pwsx3566 power 0.0314 0.5 -> 0.177 Inexact Rounded +pwsx3567 power 0.315 0.5 -> 0.561 Inexact Rounded +pwsx3568 power 0.0315 0.5 -> 0.177 Inexact Rounded +pwsx3569 power 0.316 0.5 -> 0.562 Inexact Rounded +pwsx3570 power 0.0316 0.5 -> 0.178 Inexact Rounded +pwsx3571 power 0.317 0.5 -> 0.563 Inexact Rounded +pwsx3572 power 0.0317 0.5 -> 0.178 Inexact Rounded +pwsx3573 power 0.318 0.5 -> 0.564 Inexact Rounded +pwsx3574 power 0.0318 0.5 -> 0.178 Inexact Rounded +pwsx3575 power 0.319 0.5 -> 0.565 Inexact Rounded +pwsx3576 power 0.0319 0.5 -> 0.179 Inexact Rounded +pwsx3577 power 0.321 0.5 -> 0.567 Inexact Rounded +pwsx3578 power 0.0321 0.5 -> 0.179 Inexact Rounded +pwsx3579 power 0.322 0.5 -> 0.567 Inexact Rounded +pwsx3580 power 0.0322 0.5 -> 0.179 Inexact Rounded +pwsx3581 power 0.323 0.5 -> 0.568 Inexact Rounded +pwsx3582 power 0.0323 0.5 -> 0.180 Inexact Rounded +pwsx3583 power 0.324 0.5 -> 0.569 Inexact Rounded +pwsx3584 power 0.0324 0.5 -> 0.180 Inexact Rounded +pwsx3585 power 0.325 0.5 -> 0.570 Inexact Rounded +pwsx3586 power 0.0325 0.5 -> 0.180 Inexact Rounded +pwsx3587 power 0.326 0.5 -> 0.571 Inexact Rounded +pwsx3588 power 0.0326 0.5 -> 0.181 Inexact Rounded +pwsx3589 power 0.327 0.5 -> 0.572 Inexact Rounded +pwsx3590 power 0.0327 0.5 -> 0.181 Inexact Rounded +pwsx3591 power 0.328 0.5 -> 0.573 Inexact Rounded +pwsx3592 power 0.0328 0.5 -> 0.181 Inexact Rounded +pwsx3593 power 0.329 0.5 -> 0.574 Inexact Rounded +pwsx3594 power 0.0329 0.5 -> 0.181 Inexact Rounded +pwsx3595 power 0.331 0.5 -> 0.575 Inexact Rounded +pwsx3596 power 0.0331 0.5 -> 0.182 Inexact Rounded +pwsx3597 power 0.332 0.5 -> 0.576 Inexact Rounded +pwsx3598 power 0.0332 0.5 -> 0.182 Inexact Rounded +pwsx3599 power 0.333 0.5 -> 0.577 Inexact Rounded +pwsx3600 power 0.0333 0.5 -> 0.182 Inexact Rounded +pwsx3601 power 0.334 0.5 -> 0.578 Inexact Rounded +pwsx3602 power 0.0334 0.5 -> 0.183 Inexact Rounded +pwsx3603 power 0.335 0.5 -> 0.579 Inexact Rounded +pwsx3604 power 0.0335 0.5 -> 0.183 Inexact Rounded +pwsx3605 power 0.336 0.5 -> 0.580 Inexact Rounded +pwsx3606 power 0.0336 0.5 -> 0.183 Inexact Rounded +pwsx3607 power 0.337 0.5 -> 0.581 Inexact Rounded +pwsx3608 power 0.0337 0.5 -> 0.184 Inexact Rounded +pwsx3609 power 0.338 0.5 -> 0.581 Inexact Rounded +pwsx3610 power 0.0338 0.5 -> 0.184 Inexact Rounded +pwsx3611 power 0.339 0.5 -> 0.582 Inexact Rounded +pwsx3612 power 0.0339 0.5 -> 0.184 Inexact Rounded +pwsx3613 power 0.341 0.5 -> 0.584 Inexact Rounded +pwsx3614 power 0.0341 0.5 -> 0.185 Inexact Rounded +pwsx3615 power 0.342 0.5 -> 0.585 Inexact Rounded +pwsx3616 power 0.0342 0.5 -> 0.185 Inexact Rounded +pwsx3617 power 0.343 0.5 -> 0.586 Inexact Rounded +pwsx3618 power 0.0343 0.5 -> 0.185 Inexact Rounded +pwsx3619 power 0.344 0.5 -> 0.587 Inexact Rounded +pwsx3620 power 0.0344 0.5 -> 0.185 Inexact Rounded +pwsx3621 power 0.345 0.5 -> 0.587 Inexact Rounded +pwsx3622 power 0.0345 0.5 -> 0.186 Inexact Rounded +pwsx3623 power 0.346 0.5 -> 0.588 Inexact Rounded +pwsx3624 power 0.0346 0.5 -> 0.186 Inexact Rounded +pwsx3625 power 0.347 0.5 -> 0.589 Inexact Rounded +pwsx3626 power 0.0347 0.5 -> 0.186 Inexact Rounded +pwsx3627 power 0.348 0.5 -> 0.590 Inexact Rounded +pwsx3628 power 0.0348 0.5 -> 0.187 Inexact Rounded +pwsx3629 power 0.349 0.5 -> 0.591 Inexact Rounded +pwsx3630 power 0.0349 0.5 -> 0.187 Inexact Rounded +pwsx3631 power 0.351 0.5 -> 0.592 Inexact Rounded +pwsx3632 power 0.0351 0.5 -> 0.187 Inexact Rounded +pwsx3633 power 0.352 0.5 -> 0.593 Inexact Rounded +pwsx3634 power 0.0352 0.5 -> 0.188 Inexact Rounded +pwsx3635 power 0.353 0.5 -> 0.594 Inexact Rounded +pwsx3636 power 0.0353 0.5 -> 0.188 Inexact Rounded +pwsx3637 power 0.354 0.5 -> 0.595 Inexact Rounded +pwsx3638 power 0.0354 0.5 -> 0.188 Inexact Rounded +pwsx3639 power 0.355 0.5 -> 0.596 Inexact Rounded +pwsx3640 power 0.0355 0.5 -> 0.188 Inexact Rounded +pwsx3641 power 0.356 0.5 -> 0.597 Inexact Rounded +pwsx3642 power 0.0356 0.5 -> 0.189 Inexact Rounded +pwsx3643 power 0.357 0.5 -> 0.597 Inexact Rounded +pwsx3644 power 0.0357 0.5 -> 0.189 Inexact Rounded +pwsx3645 power 0.358 0.5 -> 0.598 Inexact Rounded +pwsx3646 power 0.0358 0.5 -> 0.189 Inexact Rounded +pwsx3647 power 0.359 0.5 -> 0.599 Inexact Rounded +pwsx3648 power 0.0359 0.5 -> 0.189 Inexact Rounded +pwsx3649 power 0.361 0.5 -> 0.601 Inexact Rounded +pwsx3650 power 0.0361 0.5 -> 0.190 Inexact Rounded +pwsx3651 power 0.362 0.5 -> 0.602 Inexact Rounded +pwsx3652 power 0.0362 0.5 -> 0.190 Inexact Rounded +pwsx3653 power 0.363 0.5 -> 0.602 Inexact Rounded +pwsx3654 power 0.0363 0.5 -> 0.191 Inexact Rounded +pwsx3655 power 0.364 0.5 -> 0.603 Inexact Rounded +pwsx3656 power 0.0364 0.5 -> 0.191 Inexact Rounded +pwsx3657 power 0.365 0.5 -> 0.604 Inexact Rounded +pwsx3658 power 0.0365 0.5 -> 0.191 Inexact Rounded +pwsx3659 power 0.366 0.5 -> 0.605 Inexact Rounded +pwsx3660 power 0.0366 0.5 -> 0.191 Inexact Rounded +pwsx3661 power 0.367 0.5 -> 0.606 Inexact Rounded +pwsx3662 power 0.0367 0.5 -> 0.192 Inexact Rounded +pwsx3663 power 0.368 0.5 -> 0.607 Inexact Rounded +pwsx3664 power 0.0368 0.5 -> 0.192 Inexact Rounded +pwsx3665 power 0.369 0.5 -> 0.607 Inexact Rounded +pwsx3666 power 0.0369 0.5 -> 0.192 Inexact Rounded +pwsx3667 power 0.371 0.5 -> 0.609 Inexact Rounded +pwsx3668 power 0.0371 0.5 -> 0.193 Inexact Rounded +pwsx3669 power 0.372 0.5 -> 0.610 Inexact Rounded +pwsx3670 power 0.0372 0.5 -> 0.193 Inexact Rounded +pwsx3671 power 0.373 0.5 -> 0.611 Inexact Rounded +pwsx3672 power 0.0373 0.5 -> 0.193 Inexact Rounded +pwsx3673 power 0.374 0.5 -> 0.612 Inexact Rounded +pwsx3674 power 0.0374 0.5 -> 0.193 Inexact Rounded +pwsx3675 power 0.375 0.5 -> 0.612 Inexact Rounded +pwsx3676 power 0.0375 0.5 -> 0.194 Inexact Rounded +pwsx3677 power 0.376 0.5 -> 0.613 Inexact Rounded +pwsx3678 power 0.0376 0.5 -> 0.194 Inexact Rounded +pwsx3679 power 0.377 0.5 -> 0.614 Inexact Rounded +pwsx3680 power 0.0377 0.5 -> 0.194 Inexact Rounded +pwsx3681 power 0.378 0.5 -> 0.615 Inexact Rounded +pwsx3682 power 0.0378 0.5 -> 0.194 Inexact Rounded +pwsx3683 power 0.379 0.5 -> 0.616 Inexact Rounded +pwsx3684 power 0.0379 0.5 -> 0.195 Inexact Rounded +pwsx3685 power 0.381 0.5 -> 0.617 Inexact Rounded +pwsx3686 power 0.0381 0.5 -> 0.195 Inexact Rounded +pwsx3687 power 0.382 0.5 -> 0.618 Inexact Rounded +pwsx3688 power 0.0382 0.5 -> 0.195 Inexact Rounded +pwsx3689 power 0.383 0.5 -> 0.619 Inexact Rounded +pwsx3690 power 0.0383 0.5 -> 0.196 Inexact Rounded +pwsx3691 power 0.384 0.5 -> 0.620 Inexact Rounded +pwsx3692 power 0.0384 0.5 -> 0.196 Inexact Rounded +pwsx3693 power 0.385 0.5 -> 0.620 Inexact Rounded +pwsx3694 power 0.0385 0.5 -> 0.196 Inexact Rounded +pwsx3695 power 0.386 0.5 -> 0.621 Inexact Rounded +pwsx3696 power 0.0386 0.5 -> 0.196 Inexact Rounded +pwsx3697 power 0.387 0.5 -> 0.622 Inexact Rounded +pwsx3698 power 0.0387 0.5 -> 0.197 Inexact Rounded +pwsx3699 power 0.388 0.5 -> 0.623 Inexact Rounded +pwsx3700 power 0.0388 0.5 -> 0.197 Inexact Rounded +pwsx3701 power 0.389 0.5 -> 0.624 Inexact Rounded +pwsx3702 power 0.0389 0.5 -> 0.197 Inexact Rounded +pwsx3703 power 0.391 0.5 -> 0.625 Inexact Rounded +pwsx3704 power 0.0391 0.5 -> 0.198 Inexact Rounded +pwsx3705 power 0.392 0.5 -> 0.626 Inexact Rounded +pwsx3706 power 0.0392 0.5 -> 0.198 Inexact Rounded +pwsx3707 power 0.393 0.5 -> 0.627 Inexact Rounded +pwsx3708 power 0.0393 0.5 -> 0.198 Inexact Rounded +pwsx3709 power 0.394 0.5 -> 0.628 Inexact Rounded +pwsx3710 power 0.0394 0.5 -> 0.198 Inexact Rounded +pwsx3711 power 0.395 0.5 -> 0.628 Inexact Rounded +pwsx3712 power 0.0395 0.5 -> 0.199 Inexact Rounded +pwsx3713 power 0.396 0.5 -> 0.629 Inexact Rounded +pwsx3714 power 0.0396 0.5 -> 0.199 Inexact Rounded +pwsx3715 power 0.397 0.5 -> 0.630 Inexact Rounded +pwsx3716 power 0.0397 0.5 -> 0.199 Inexact Rounded +pwsx3717 power 0.398 0.5 -> 0.631 Inexact Rounded +pwsx3718 power 0.0398 0.5 -> 0.199 Inexact Rounded +pwsx3719 power 0.399 0.5 -> 0.632 Inexact Rounded +pwsx3720 power 0.0399 0.5 -> 0.200 Inexact Rounded +pwsx3721 power 0.401 0.5 -> 0.633 Inexact Rounded +pwsx3722 power 0.0401 0.5 -> 0.200 Inexact Rounded +pwsx3723 power 0.402 0.5 -> 0.634 Inexact Rounded +pwsx3724 power 0.0402 0.5 -> 0.200 Inexact Rounded +pwsx3725 power 0.403 0.5 -> 0.635 Inexact Rounded +pwsx3726 power 0.0403 0.5 -> 0.201 Inexact Rounded +pwsx3727 power 0.404 0.5 -> 0.636 Inexact Rounded +pwsx3728 power 0.0404 0.5 -> 0.201 Inexact Rounded +pwsx3729 power 0.405 0.5 -> 0.636 Inexact Rounded +pwsx3730 power 0.0405 0.5 -> 0.201 Inexact Rounded +pwsx3731 power 0.406 0.5 -> 0.637 Inexact Rounded +pwsx3732 power 0.0406 0.5 -> 0.201 Inexact Rounded +pwsx3733 power 0.407 0.5 -> 0.638 Inexact Rounded +pwsx3734 power 0.0407 0.5 -> 0.202 Inexact Rounded +pwsx3735 power 0.408 0.5 -> 0.639 Inexact Rounded +pwsx3736 power 0.0408 0.5 -> 0.202 Inexact Rounded +pwsx3737 power 0.409 0.5 -> 0.640 Inexact Rounded +pwsx3738 power 0.0409 0.5 -> 0.202 Inexact Rounded +pwsx3739 power 0.411 0.5 -> 0.641 Inexact Rounded +pwsx3740 power 0.0411 0.5 -> 0.203 Inexact Rounded +pwsx3741 power 0.412 0.5 -> 0.642 Inexact Rounded +pwsx3742 power 0.0412 0.5 -> 0.203 Inexact Rounded +pwsx3743 power 0.413 0.5 -> 0.643 Inexact Rounded +pwsx3744 power 0.0413 0.5 -> 0.203 Inexact Rounded +pwsx3745 power 0.414 0.5 -> 0.643 Inexact Rounded +pwsx3746 power 0.0414 0.5 -> 0.203 Inexact Rounded +pwsx3747 power 0.415 0.5 -> 0.644 Inexact Rounded +pwsx3748 power 0.0415 0.5 -> 0.204 Inexact Rounded +pwsx3749 power 0.416 0.5 -> 0.645 Inexact Rounded +pwsx3750 power 0.0416 0.5 -> 0.204 Inexact Rounded +pwsx3751 power 0.417 0.5 -> 0.646 Inexact Rounded +pwsx3752 power 0.0417 0.5 -> 0.204 Inexact Rounded +pwsx3753 power 0.418 0.5 -> 0.647 Inexact Rounded +pwsx3754 power 0.0418 0.5 -> 0.204 Inexact Rounded +pwsx3755 power 0.419 0.5 -> 0.647 Inexact Rounded +pwsx3756 power 0.0419 0.5 -> 0.205 Inexact Rounded +pwsx3757 power 0.421 0.5 -> 0.649 Inexact Rounded +pwsx3758 power 0.0421 0.5 -> 0.205 Inexact Rounded +pwsx3759 power 0.422 0.5 -> 0.650 Inexact Rounded +pwsx3760 power 0.0422 0.5 -> 0.205 Inexact Rounded +pwsx3761 power 0.423 0.5 -> 0.650 Inexact Rounded +pwsx3762 power 0.0423 0.5 -> 0.206 Inexact Rounded +pwsx3763 power 0.424 0.5 -> 0.651 Inexact Rounded +pwsx3764 power 0.0424 0.5 -> 0.206 Inexact Rounded +pwsx3765 power 0.425 0.5 -> 0.652 Inexact Rounded +pwsx3766 power 0.0425 0.5 -> 0.206 Inexact Rounded +pwsx3767 power 0.426 0.5 -> 0.653 Inexact Rounded +pwsx3768 power 0.0426 0.5 -> 0.206 Inexact Rounded +pwsx3769 power 0.427 0.5 -> 0.653 Inexact Rounded +pwsx3770 power 0.0427 0.5 -> 0.207 Inexact Rounded +pwsx3771 power 0.428 0.5 -> 0.654 Inexact Rounded +pwsx3772 power 0.0428 0.5 -> 0.207 Inexact Rounded +pwsx3773 power 0.429 0.5 -> 0.655 Inexact Rounded +pwsx3774 power 0.0429 0.5 -> 0.207 Inexact Rounded +pwsx3775 power 0.431 0.5 -> 0.657 Inexact Rounded +pwsx3776 power 0.0431 0.5 -> 0.208 Inexact Rounded +pwsx3777 power 0.432 0.5 -> 0.657 Inexact Rounded +pwsx3778 power 0.0432 0.5 -> 0.208 Inexact Rounded +pwsx3779 power 0.433 0.5 -> 0.658 Inexact Rounded +pwsx3780 power 0.0433 0.5 -> 0.208 Inexact Rounded +pwsx3781 power 0.434 0.5 -> 0.659 Inexact Rounded +pwsx3782 power 0.0434 0.5 -> 0.208 Inexact Rounded +pwsx3783 power 0.435 0.5 -> 0.660 Inexact Rounded +pwsx3784 power 0.0435 0.5 -> 0.209 Inexact Rounded +pwsx3785 power 0.436 0.5 -> 0.660 Inexact Rounded +pwsx3786 power 0.0436 0.5 -> 0.209 Inexact Rounded +pwsx3787 power 0.437 0.5 -> 0.661 Inexact Rounded +pwsx3788 power 0.0437 0.5 -> 0.209 Inexact Rounded +pwsx3789 power 0.438 0.5 -> 0.662 Inexact Rounded +pwsx3790 power 0.0438 0.5 -> 0.209 Inexact Rounded +pwsx3791 power 0.439 0.5 -> 0.663 Inexact Rounded +pwsx3792 power 0.0439 0.5 -> 0.210 Inexact Rounded +pwsx3793 power 0.441 0.5 -> 0.664 Inexact Rounded +pwsx3794 power 0.0441 0.5 -> 0.210 Inexact Rounded +pwsx3795 power 0.442 0.5 -> 0.665 Inexact Rounded +pwsx3796 power 0.0442 0.5 -> 0.210 Inexact Rounded +pwsx3797 power 0.443 0.5 -> 0.666 Inexact Rounded +pwsx3798 power 0.0443 0.5 -> 0.210 Inexact Rounded +pwsx3799 power 0.444 0.5 -> 0.666 Inexact Rounded +pwsx3800 power 0.0444 0.5 -> 0.211 Inexact Rounded +pwsx3801 power 0.445 0.5 -> 0.667 Inexact Rounded +pwsx3802 power 0.0445 0.5 -> 0.211 Inexact Rounded +pwsx3803 power 0.446 0.5 -> 0.668 Inexact Rounded +pwsx3804 power 0.0446 0.5 -> 0.211 Inexact Rounded +pwsx3805 power 0.447 0.5 -> 0.669 Inexact Rounded +pwsx3806 power 0.0447 0.5 -> 0.211 Inexact Rounded +pwsx3807 power 0.448 0.5 -> 0.669 Inexact Rounded +pwsx3808 power 0.0448 0.5 -> 0.212 Inexact Rounded +pwsx3809 power 0.449 0.5 -> 0.670 Inexact Rounded +pwsx3810 power 0.0449 0.5 -> 0.212 Inexact Rounded +pwsx3811 power 0.451 0.5 -> 0.672 Inexact Rounded +pwsx3812 power 0.0451 0.5 -> 0.212 Inexact Rounded +pwsx3813 power 0.452 0.5 -> 0.672 Inexact Rounded +pwsx3814 power 0.0452 0.5 -> 0.213 Inexact Rounded +pwsx3815 power 0.453 0.5 -> 0.673 Inexact Rounded +pwsx3816 power 0.0453 0.5 -> 0.213 Inexact Rounded +pwsx3817 power 0.454 0.5 -> 0.674 Inexact Rounded +pwsx3818 power 0.0454 0.5 -> 0.213 Inexact Rounded +pwsx3819 power 0.455 0.5 -> 0.675 Inexact Rounded +pwsx3820 power 0.0455 0.5 -> 0.213 Inexact Rounded +pwsx3821 power 0.456 0.5 -> 0.675 Inexact Rounded +pwsx3822 power 0.0456 0.5 -> 0.214 Inexact Rounded +pwsx3823 power 0.457 0.5 -> 0.676 Inexact Rounded +pwsx3824 power 0.0457 0.5 -> 0.214 Inexact Rounded +pwsx3825 power 0.458 0.5 -> 0.677 Inexact Rounded +pwsx3826 power 0.0458 0.5 -> 0.214 Inexact Rounded +pwsx3827 power 0.459 0.5 -> 0.677 Inexact Rounded +pwsx3828 power 0.0459 0.5 -> 0.214 Inexact Rounded +pwsx3829 power 0.461 0.5 -> 0.679 Inexact Rounded +pwsx3830 power 0.0461 0.5 -> 0.215 Inexact Rounded +pwsx3831 power 0.462 0.5 -> 0.680 Inexact Rounded +pwsx3832 power 0.0462 0.5 -> 0.215 Inexact Rounded +pwsx3833 power 0.463 0.5 -> 0.680 Inexact Rounded +pwsx3834 power 0.0463 0.5 -> 0.215 Inexact Rounded +pwsx3835 power 0.464 0.5 -> 0.681 Inexact Rounded +pwsx3836 power 0.0464 0.5 -> 0.215 Inexact Rounded +pwsx3837 power 0.465 0.5 -> 0.682 Inexact Rounded +pwsx3838 power 0.0465 0.5 -> 0.216 Inexact Rounded +pwsx3839 power 0.466 0.5 -> 0.683 Inexact Rounded +pwsx3840 power 0.0466 0.5 -> 0.216 Inexact Rounded +pwsx3841 power 0.467 0.5 -> 0.683 Inexact Rounded +pwsx3842 power 0.0467 0.5 -> 0.216 Inexact Rounded +pwsx3843 power 0.468 0.5 -> 0.684 Inexact Rounded +pwsx3844 power 0.0468 0.5 -> 0.216 Inexact Rounded +pwsx3845 power 0.469 0.5 -> 0.685 Inexact Rounded +pwsx3846 power 0.0469 0.5 -> 0.217 Inexact Rounded +pwsx3847 power 0.471 0.5 -> 0.686 Inexact Rounded +pwsx3848 power 0.0471 0.5 -> 0.217 Inexact Rounded +pwsx3849 power 0.472 0.5 -> 0.687 Inexact Rounded +pwsx3850 power 0.0472 0.5 -> 0.217 Inexact Rounded +pwsx3851 power 0.473 0.5 -> 0.688 Inexact Rounded +pwsx3852 power 0.0473 0.5 -> 0.217 Inexact Rounded +pwsx3853 power 0.474 0.5 -> 0.688 Inexact Rounded +pwsx3854 power 0.0474 0.5 -> 0.218 Inexact Rounded +pwsx3855 power 0.475 0.5 -> 0.689 Inexact Rounded +pwsx3856 power 0.0475 0.5 -> 0.218 Inexact Rounded +pwsx3857 power 0.476 0.5 -> 0.690 Inexact Rounded +pwsx3858 power 0.0476 0.5 -> 0.218 Inexact Rounded +pwsx3859 power 0.477 0.5 -> 0.691 Inexact Rounded +pwsx3860 power 0.0477 0.5 -> 0.218 Inexact Rounded +pwsx3861 power 0.478 0.5 -> 0.691 Inexact Rounded +pwsx3862 power 0.0478 0.5 -> 0.219 Inexact Rounded +pwsx3863 power 0.479 0.5 -> 0.692 Inexact Rounded +pwsx3864 power 0.0479 0.5 -> 0.219 Inexact Rounded +pwsx3865 power 0.481 0.5 -> 0.694 Inexact Rounded +pwsx3866 power 0.0481 0.5 -> 0.219 Inexact Rounded +pwsx3867 power 0.482 0.5 -> 0.694 Inexact Rounded +pwsx3868 power 0.0482 0.5 -> 0.220 Inexact Rounded +pwsx3869 power 0.483 0.5 -> 0.695 Inexact Rounded +pwsx3870 power 0.0483 0.5 -> 0.220 Inexact Rounded +pwsx3871 power 0.484 0.5 -> 0.696 Inexact Rounded +pwsx3872 power 0.0484 0.5 -> 0.220 Inexact Rounded +pwsx3873 power 0.485 0.5 -> 0.696 Inexact Rounded +pwsx3874 power 0.0485 0.5 -> 0.220 Inexact Rounded +pwsx3875 power 0.486 0.5 -> 0.697 Inexact Rounded +pwsx3876 power 0.0486 0.5 -> 0.220 Inexact Rounded +pwsx3877 power 0.487 0.5 -> 0.698 Inexact Rounded +pwsx3878 power 0.0487 0.5 -> 0.221 Inexact Rounded +pwsx3879 power 0.488 0.5 -> 0.699 Inexact Rounded +pwsx3880 power 0.0488 0.5 -> 0.221 Inexact Rounded +pwsx3881 power 0.489 0.5 -> 0.699 Inexact Rounded +pwsx3882 power 0.0489 0.5 -> 0.221 Inexact Rounded +pwsx3883 power 0.491 0.5 -> 0.701 Inexact Rounded +pwsx3884 power 0.0491 0.5 -> 0.222 Inexact Rounded +pwsx3885 power 0.492 0.5 -> 0.701 Inexact Rounded +pwsx3886 power 0.0492 0.5 -> 0.222 Inexact Rounded +pwsx3887 power 0.493 0.5 -> 0.702 Inexact Rounded +pwsx3888 power 0.0493 0.5 -> 0.222 Inexact Rounded +pwsx3889 power 0.494 0.5 -> 0.703 Inexact Rounded +pwsx3890 power 0.0494 0.5 -> 0.222 Inexact Rounded +pwsx3891 power 0.495 0.5 -> 0.704 Inexact Rounded +pwsx3892 power 0.0495 0.5 -> 0.222 Inexact Rounded +pwsx3893 power 0.496 0.5 -> 0.704 Inexact Rounded +pwsx3894 power 0.0496 0.5 -> 0.223 Inexact Rounded +pwsx3895 power 0.497 0.5 -> 0.705 Inexact Rounded +pwsx3896 power 0.0497 0.5 -> 0.223 Inexact Rounded +pwsx3897 power 0.498 0.5 -> 0.706 Inexact Rounded +pwsx3898 power 0.0498 0.5 -> 0.223 Inexact Rounded +pwsx3899 power 0.499 0.5 -> 0.706 Inexact Rounded +pwsx3900 power 0.0499 0.5 -> 0.223 Inexact Rounded +pwsx3901 power 0.501 0.5 -> 0.708 Inexact Rounded +pwsx3902 power 0.0501 0.5 -> 0.224 Inexact Rounded +pwsx3903 power 0.502 0.5 -> 0.709 Inexact Rounded +pwsx3904 power 0.0502 0.5 -> 0.224 Inexact Rounded +pwsx3905 power 0.503 0.5 -> 0.709 Inexact Rounded +pwsx3906 power 0.0503 0.5 -> 0.224 Inexact Rounded +pwsx3907 power 0.504 0.5 -> 0.710 Inexact Rounded +pwsx3908 power 0.0504 0.5 -> 0.224 Inexact Rounded +pwsx3909 power 0.505 0.5 -> 0.711 Inexact Rounded +pwsx3910 power 0.0505 0.5 -> 0.225 Inexact Rounded +pwsx3911 power 0.506 0.5 -> 0.711 Inexact Rounded +pwsx3912 power 0.0506 0.5 -> 0.225 Inexact Rounded +pwsx3913 power 0.507 0.5 -> 0.712 Inexact Rounded +pwsx3914 power 0.0507 0.5 -> 0.225 Inexact Rounded +pwsx3915 power 0.508 0.5 -> 0.713 Inexact Rounded +pwsx3916 power 0.0508 0.5 -> 0.225 Inexact Rounded +pwsx3917 power 0.509 0.5 -> 0.713 Inexact Rounded +pwsx3918 power 0.0509 0.5 -> 0.226 Inexact Rounded +pwsx3919 power 0.511 0.5 -> 0.715 Inexact Rounded +pwsx3920 power 0.0511 0.5 -> 0.226 Inexact Rounded +pwsx3921 power 0.512 0.5 -> 0.716 Inexact Rounded +pwsx3922 power 0.0512 0.5 -> 0.226 Inexact Rounded +pwsx3923 power 0.513 0.5 -> 0.716 Inexact Rounded +pwsx3924 power 0.0513 0.5 -> 0.226 Inexact Rounded +pwsx3925 power 0.514 0.5 -> 0.717 Inexact Rounded +pwsx3926 power 0.0514 0.5 -> 0.227 Inexact Rounded +pwsx3927 power 0.515 0.5 -> 0.718 Inexact Rounded +pwsx3928 power 0.0515 0.5 -> 0.227 Inexact Rounded +pwsx3929 power 0.516 0.5 -> 0.718 Inexact Rounded +pwsx3930 power 0.0516 0.5 -> 0.227 Inexact Rounded +pwsx3931 power 0.517 0.5 -> 0.719 Inexact Rounded +pwsx3932 power 0.0517 0.5 -> 0.227 Inexact Rounded +pwsx3933 power 0.518 0.5 -> 0.720 Inexact Rounded +pwsx3934 power 0.0518 0.5 -> 0.228 Inexact Rounded +pwsx3935 power 0.519 0.5 -> 0.720 Inexact Rounded +pwsx3936 power 0.0519 0.5 -> 0.228 Inexact Rounded +pwsx3937 power 0.521 0.5 -> 0.722 Inexact Rounded +pwsx3938 power 0.0521 0.5 -> 0.228 Inexact Rounded +pwsx3939 power 0.522 0.5 -> 0.722 Inexact Rounded +pwsx3940 power 0.0522 0.5 -> 0.228 Inexact Rounded +pwsx3941 power 0.523 0.5 -> 0.723 Inexact Rounded +pwsx3942 power 0.0523 0.5 -> 0.229 Inexact Rounded +pwsx3943 power 0.524 0.5 -> 0.724 Inexact Rounded +pwsx3944 power 0.0524 0.5 -> 0.229 Inexact Rounded +pwsx3945 power 0.525 0.5 -> 0.725 Inexact Rounded +pwsx3946 power 0.0525 0.5 -> 0.229 Inexact Rounded +pwsx3947 power 0.526 0.5 -> 0.725 Inexact Rounded +pwsx3948 power 0.0526 0.5 -> 0.229 Inexact Rounded +pwsx3949 power 0.527 0.5 -> 0.726 Inexact Rounded +pwsx3950 power 0.0527 0.5 -> 0.230 Inexact Rounded +pwsx3951 power 0.528 0.5 -> 0.727 Inexact Rounded +pwsx3952 power 0.0528 0.5 -> 0.230 Inexact Rounded +pwsx3953 power 0.529 0.5 -> 0.727 Inexact Rounded +pwsx3954 power 0.0529 0.5 -> 0.230 Inexact Rounded +pwsx3955 power 0.531 0.5 -> 0.729 Inexact Rounded +pwsx3956 power 0.0531 0.5 -> 0.230 Inexact Rounded +pwsx3957 power 0.532 0.5 -> 0.729 Inexact Rounded +pwsx3958 power 0.0532 0.5 -> 0.231 Inexact Rounded +pwsx3959 power 0.533 0.5 -> 0.730 Inexact Rounded +pwsx3960 power 0.0533 0.5 -> 0.231 Inexact Rounded +pwsx3961 power 0.534 0.5 -> 0.731 Inexact Rounded +pwsx3962 power 0.0534 0.5 -> 0.231 Inexact Rounded +pwsx3963 power 0.535 0.5 -> 0.731 Inexact Rounded +pwsx3964 power 0.0535 0.5 -> 0.231 Inexact Rounded +pwsx3965 power 0.536 0.5 -> 0.732 Inexact Rounded +pwsx3966 power 0.0536 0.5 -> 0.232 Inexact Rounded +pwsx3967 power 0.537 0.5 -> 0.733 Inexact Rounded +pwsx3968 power 0.0537 0.5 -> 0.232 Inexact Rounded +pwsx3969 power 0.538 0.5 -> 0.733 Inexact Rounded +pwsx3970 power 0.0538 0.5 -> 0.232 Inexact Rounded +pwsx3971 power 0.539 0.5 -> 0.734 Inexact Rounded +pwsx3972 power 0.0539 0.5 -> 0.232 Inexact Rounded +pwsx3973 power 0.541 0.5 -> 0.736 Inexact Rounded +pwsx3974 power 0.0541 0.5 -> 0.233 Inexact Rounded +pwsx3975 power 0.542 0.5 -> 0.736 Inexact Rounded +pwsx3976 power 0.0542 0.5 -> 0.233 Inexact Rounded +pwsx3977 power 0.543 0.5 -> 0.737 Inexact Rounded +pwsx3978 power 0.0543 0.5 -> 0.233 Inexact Rounded +pwsx3979 power 0.544 0.5 -> 0.738 Inexact Rounded +pwsx3980 power 0.0544 0.5 -> 0.233 Inexact Rounded +pwsx3981 power 0.545 0.5 -> 0.738 Inexact Rounded +pwsx3982 power 0.0545 0.5 -> 0.233 Inexact Rounded +pwsx3983 power 0.546 0.5 -> 0.739 Inexact Rounded +pwsx3984 power 0.0546 0.5 -> 0.234 Inexact Rounded +pwsx3985 power 0.547 0.5 -> 0.740 Inexact Rounded +pwsx3986 power 0.0547 0.5 -> 0.234 Inexact Rounded +pwsx3987 power 0.548 0.5 -> 0.740 Inexact Rounded +pwsx3988 power 0.0548 0.5 -> 0.234 Inexact Rounded +pwsx3989 power 0.549 0.5 -> 0.741 Inexact Rounded +pwsx3990 power 0.0549 0.5 -> 0.234 Inexact Rounded +pwsx3991 power 0.551 0.5 -> 0.742 Inexact Rounded +pwsx3992 power 0.0551 0.5 -> 0.235 Inexact Rounded +pwsx3993 power 0.552 0.5 -> 0.743 Inexact Rounded +pwsx3994 power 0.0552 0.5 -> 0.235 Inexact Rounded +pwsx3995 power 0.553 0.5 -> 0.744 Inexact Rounded +pwsx3996 power 0.0553 0.5 -> 0.235 Inexact Rounded +pwsx3997 power 0.554 0.5 -> 0.744 Inexact Rounded +pwsx3998 power 0.0554 0.5 -> 0.235 Inexact Rounded +pwsx3999 power 0.555 0.5 -> 0.745 Inexact Rounded +pwsx4000 power 0.0555 0.5 -> 0.236 Inexact Rounded +pwsx4001 power 0.556 0.5 -> 0.746 Inexact Rounded +pwsx4002 power 0.0556 0.5 -> 0.236 Inexact Rounded +pwsx4003 power 0.557 0.5 -> 0.746 Inexact Rounded +pwsx4004 power 0.0557 0.5 -> 0.236 Inexact Rounded +pwsx4005 power 0.558 0.5 -> 0.747 Inexact Rounded +pwsx4006 power 0.0558 0.5 -> 0.236 Inexact Rounded +pwsx4007 power 0.559 0.5 -> 0.748 Inexact Rounded +pwsx4008 power 0.0559 0.5 -> 0.236 Inexact Rounded +pwsx4009 power 0.561 0.5 -> 0.749 Inexact Rounded +pwsx4010 power 0.0561 0.5 -> 0.237 Inexact Rounded +pwsx4011 power 0.562 0.5 -> 0.750 Inexact Rounded +pwsx4012 power 0.0562 0.5 -> 0.237 Inexact Rounded +pwsx4013 power 0.563 0.5 -> 0.750 Inexact Rounded +pwsx4014 power 0.0563 0.5 -> 0.237 Inexact Rounded +pwsx4015 power 0.564 0.5 -> 0.751 Inexact Rounded +pwsx4016 power 0.0564 0.5 -> 0.237 Inexact Rounded +pwsx4017 power 0.565 0.5 -> 0.752 Inexact Rounded +pwsx4018 power 0.0565 0.5 -> 0.238 Inexact Rounded +pwsx4019 power 0.566 0.5 -> 0.752 Inexact Rounded +pwsx4020 power 0.0566 0.5 -> 0.238 Inexact Rounded +pwsx4021 power 0.567 0.5 -> 0.753 Inexact Rounded +pwsx4022 power 0.0567 0.5 -> 0.238 Inexact Rounded +pwsx4023 power 0.568 0.5 -> 0.754 Inexact Rounded +pwsx4024 power 0.0568 0.5 -> 0.238 Inexact Rounded +pwsx4025 power 0.569 0.5 -> 0.754 Inexact Rounded +pwsx4026 power 0.0569 0.5 -> 0.239 Inexact Rounded +pwsx4027 power 0.571 0.5 -> 0.756 Inexact Rounded +pwsx4028 power 0.0571 0.5 -> 0.239 Inexact Rounded +pwsx4029 power 0.572 0.5 -> 0.756 Inexact Rounded +pwsx4030 power 0.0572 0.5 -> 0.239 Inexact Rounded +pwsx4031 power 0.573 0.5 -> 0.757 Inexact Rounded +pwsx4032 power 0.0573 0.5 -> 0.239 Inexact Rounded +pwsx4033 power 0.574 0.5 -> 0.758 Inexact Rounded +pwsx4034 power 0.0574 0.5 -> 0.240 Inexact Rounded +pwsx4035 power 0.575 0.5 -> 0.758 Inexact Rounded +pwsx4036 power 0.0575 0.5 -> 0.240 Inexact Rounded +pwsx4037 power 0.576 0.5 -> 0.759 Inexact Rounded +pwsx4038 power 0.0576 0.5 -> 0.240 Inexact Rounded +pwsx4039 power 0.577 0.5 -> 0.760 Inexact Rounded +pwsx4040 power 0.0577 0.5 -> 0.240 Inexact Rounded +pwsx4041 power 0.578 0.5 -> 0.760 Inexact Rounded +pwsx4042 power 0.0578 0.5 -> 0.240 Inexact Rounded +pwsx4043 power 0.579 0.5 -> 0.761 Inexact Rounded +pwsx4044 power 0.0579 0.5 -> 0.241 Inexact Rounded +pwsx4045 power 0.581 0.5 -> 0.762 Inexact Rounded +pwsx4046 power 0.0581 0.5 -> 0.241 Inexact Rounded +pwsx4047 power 0.582 0.5 -> 0.763 Inexact Rounded +pwsx4048 power 0.0582 0.5 -> 0.241 Inexact Rounded +pwsx4049 power 0.583 0.5 -> 0.764 Inexact Rounded +pwsx4050 power 0.0583 0.5 -> 0.241 Inexact Rounded +pwsx4051 power 0.584 0.5 -> 0.764 Inexact Rounded +pwsx4052 power 0.0584 0.5 -> 0.242 Inexact Rounded +pwsx4053 power 0.585 0.5 -> 0.765 Inexact Rounded +pwsx4054 power 0.0585 0.5 -> 0.242 Inexact Rounded +pwsx4055 power 0.586 0.5 -> 0.766 Inexact Rounded +pwsx4056 power 0.0586 0.5 -> 0.242 Inexact Rounded +pwsx4057 power 0.587 0.5 -> 0.766 Inexact Rounded +pwsx4058 power 0.0587 0.5 -> 0.242 Inexact Rounded +pwsx4059 power 0.588 0.5 -> 0.767 Inexact Rounded +pwsx4060 power 0.0588 0.5 -> 0.242 Inexact Rounded +pwsx4061 power 0.589 0.5 -> 0.767 Inexact Rounded +pwsx4062 power 0.0589 0.5 -> 0.243 Inexact Rounded +pwsx4063 power 0.591 0.5 -> 0.769 Inexact Rounded +pwsx4064 power 0.0591 0.5 -> 0.243 Inexact Rounded +pwsx4065 power 0.592 0.5 -> 0.769 Inexact Rounded +pwsx4066 power 0.0592 0.5 -> 0.243 Inexact Rounded +pwsx4067 power 0.593 0.5 -> 0.770 Inexact Rounded +pwsx4068 power 0.0593 0.5 -> 0.244 Inexact Rounded +pwsx4069 power 0.594 0.5 -> 0.771 Inexact Rounded +pwsx4070 power 0.0594 0.5 -> 0.244 Inexact Rounded +pwsx4071 power 0.595 0.5 -> 0.771 Inexact Rounded +pwsx4072 power 0.0595 0.5 -> 0.244 Inexact Rounded +pwsx4073 power 0.596 0.5 -> 0.772 Inexact Rounded +pwsx4074 power 0.0596 0.5 -> 0.244 Inexact Rounded +pwsx4075 power 0.597 0.5 -> 0.773 Inexact Rounded +pwsx4076 power 0.0597 0.5 -> 0.244 Inexact Rounded +pwsx4077 power 0.598 0.5 -> 0.773 Inexact Rounded +pwsx4078 power 0.0598 0.5 -> 0.245 Inexact Rounded +pwsx4079 power 0.599 0.5 -> 0.774 Inexact Rounded +pwsx4080 power 0.0599 0.5 -> 0.245 Inexact Rounded +pwsx4081 power 0.601 0.5 -> 0.775 Inexact Rounded +pwsx4082 power 0.0601 0.5 -> 0.245 Inexact Rounded +pwsx4083 power 0.602 0.5 -> 0.776 Inexact Rounded +pwsx4084 power 0.0602 0.5 -> 0.245 Inexact Rounded +pwsx4085 power 0.603 0.5 -> 0.777 Inexact Rounded +pwsx4086 power 0.0603 0.5 -> 0.246 Inexact Rounded +pwsx4087 power 0.604 0.5 -> 0.777 Inexact Rounded +pwsx4088 power 0.0604 0.5 -> 0.246 Inexact Rounded +pwsx4089 power 0.605 0.5 -> 0.778 Inexact Rounded +pwsx4090 power 0.0605 0.5 -> 0.246 Inexact Rounded +pwsx4091 power 0.606 0.5 -> 0.778 Inexact Rounded +pwsx4092 power 0.0606 0.5 -> 0.246 Inexact Rounded +pwsx4093 power 0.607 0.5 -> 0.779 Inexact Rounded +pwsx4094 power 0.0607 0.5 -> 0.246 Inexact Rounded +pwsx4095 power 0.608 0.5 -> 0.780 Inexact Rounded +pwsx4096 power 0.0608 0.5 -> 0.247 Inexact Rounded +pwsx4097 power 0.609 0.5 -> 0.780 Inexact Rounded +pwsx4098 power 0.0609 0.5 -> 0.247 Inexact Rounded +pwsx4099 power 0.611 0.5 -> 0.782 Inexact Rounded +pwsx4100 power 0.0611 0.5 -> 0.247 Inexact Rounded +pwsx4101 power 0.612 0.5 -> 0.782 Inexact Rounded +pwsx4102 power 0.0612 0.5 -> 0.247 Inexact Rounded +pwsx4103 power 0.613 0.5 -> 0.783 Inexact Rounded +pwsx4104 power 0.0613 0.5 -> 0.248 Inexact Rounded +pwsx4105 power 0.614 0.5 -> 0.784 Inexact Rounded +pwsx4106 power 0.0614 0.5 -> 0.248 Inexact Rounded +pwsx4107 power 0.615 0.5 -> 0.784 Inexact Rounded +pwsx4108 power 0.0615 0.5 -> 0.248 Inexact Rounded +pwsx4109 power 0.616 0.5 -> 0.785 Inexact Rounded +pwsx4110 power 0.0616 0.5 -> 0.248 Inexact Rounded +pwsx4111 power 0.617 0.5 -> 0.785 Inexact Rounded +pwsx4112 power 0.0617 0.5 -> 0.248 Inexact Rounded +pwsx4113 power 0.618 0.5 -> 0.786 Inexact Rounded +pwsx4114 power 0.0618 0.5 -> 0.249 Inexact Rounded +pwsx4115 power 0.619 0.5 -> 0.787 Inexact Rounded +pwsx4116 power 0.0619 0.5 -> 0.249 Inexact Rounded +pwsx4117 power 0.621 0.5 -> 0.788 Inexact Rounded +pwsx4118 power 0.0621 0.5 -> 0.249 Inexact Rounded +pwsx4119 power 0.622 0.5 -> 0.789 Inexact Rounded +pwsx4120 power 0.0622 0.5 -> 0.249 Inexact Rounded +pwsx4121 power 0.623 0.5 -> 0.789 Inexact Rounded +pwsx4122 power 0.0623 0.5 -> 0.250 Inexact Rounded +pwsx4123 power 0.624 0.5 -> 0.790 Inexact Rounded +pwsx4124 power 0.0624 0.5 -> 0.250 Inexact Rounded +pwsx4125 power 0.625 0.5 -> 0.791 Inexact Rounded +pwsx4126 power 0.0625 0.5 -> 0.250 Inexact Rounded +pwsx4127 power 0.626 0.5 -> 0.791 Inexact Rounded +pwsx4128 power 0.0626 0.5 -> 0.250 Inexact Rounded +pwsx4129 power 0.627 0.5 -> 0.792 Inexact Rounded +pwsx4130 power 0.0627 0.5 -> 0.250 Inexact Rounded +pwsx4131 power 0.628 0.5 -> 0.792 Inexact Rounded +pwsx4132 power 0.0628 0.5 -> 0.251 Inexact Rounded +pwsx4133 power 0.629 0.5 -> 0.793 Inexact Rounded +pwsx4134 power 0.0629 0.5 -> 0.251 Inexact Rounded +pwsx4135 power 0.631 0.5 -> 0.794 Inexact Rounded +pwsx4136 power 0.0631 0.5 -> 0.251 Inexact Rounded +pwsx4137 power 0.632 0.5 -> 0.795 Inexact Rounded +pwsx4138 power 0.0632 0.5 -> 0.251 Inexact Rounded +pwsx4139 power 0.633 0.5 -> 0.796 Inexact Rounded +pwsx4140 power 0.0633 0.5 -> 0.252 Inexact Rounded +pwsx4141 power 0.634 0.5 -> 0.796 Inexact Rounded +pwsx4142 power 0.0634 0.5 -> 0.252 Inexact Rounded +pwsx4143 power 0.635 0.5 -> 0.797 Inexact Rounded +pwsx4144 power 0.0635 0.5 -> 0.252 Inexact Rounded +pwsx4145 power 0.636 0.5 -> 0.797 Inexact Rounded +pwsx4146 power 0.0636 0.5 -> 0.252 Inexact Rounded +pwsx4147 power 0.637 0.5 -> 0.798 Inexact Rounded +pwsx4148 power 0.0637 0.5 -> 0.252 Inexact Rounded +pwsx4149 power 0.638 0.5 -> 0.799 Inexact Rounded +pwsx4150 power 0.0638 0.5 -> 0.253 Inexact Rounded +pwsx4151 power 0.639 0.5 -> 0.799 Inexact Rounded +pwsx4152 power 0.0639 0.5 -> 0.253 Inexact Rounded +pwsx4153 power 0.641 0.5 -> 0.801 Inexact Rounded +pwsx4154 power 0.0641 0.5 -> 0.253 Inexact Rounded +pwsx4155 power 0.642 0.5 -> 0.801 Inexact Rounded +pwsx4156 power 0.0642 0.5 -> 0.253 Inexact Rounded +pwsx4157 power 0.643 0.5 -> 0.802 Inexact Rounded +pwsx4158 power 0.0643 0.5 -> 0.254 Inexact Rounded +pwsx4159 power 0.644 0.5 -> 0.802 Inexact Rounded +pwsx4160 power 0.0644 0.5 -> 0.254 Inexact Rounded +pwsx4161 power 0.645 0.5 -> 0.803 Inexact Rounded +pwsx4162 power 0.0645 0.5 -> 0.254 Inexact Rounded +pwsx4163 power 0.646 0.5 -> 0.804 Inexact Rounded +pwsx4164 power 0.0646 0.5 -> 0.254 Inexact Rounded +pwsx4165 power 0.647 0.5 -> 0.804 Inexact Rounded +pwsx4166 power 0.0647 0.5 -> 0.254 Inexact Rounded +pwsx4167 power 0.648 0.5 -> 0.805 Inexact Rounded +pwsx4168 power 0.0648 0.5 -> 0.255 Inexact Rounded +pwsx4169 power 0.649 0.5 -> 0.806 Inexact Rounded +pwsx4170 power 0.0649 0.5 -> 0.255 Inexact Rounded +pwsx4171 power 0.651 0.5 -> 0.807 Inexact Rounded +pwsx4172 power 0.0651 0.5 -> 0.255 Inexact Rounded +pwsx4173 power 0.652 0.5 -> 0.807 Inexact Rounded +pwsx4174 power 0.0652 0.5 -> 0.255 Inexact Rounded +pwsx4175 power 0.653 0.5 -> 0.808 Inexact Rounded +pwsx4176 power 0.0653 0.5 -> 0.256 Inexact Rounded +pwsx4177 power 0.654 0.5 -> 0.809 Inexact Rounded +pwsx4178 power 0.0654 0.5 -> 0.256 Inexact Rounded +pwsx4179 power 0.655 0.5 -> 0.809 Inexact Rounded +pwsx4180 power 0.0655 0.5 -> 0.256 Inexact Rounded +pwsx4181 power 0.656 0.5 -> 0.810 Inexact Rounded +pwsx4182 power 0.0656 0.5 -> 0.256 Inexact Rounded +pwsx4183 power 0.657 0.5 -> 0.811 Inexact Rounded +pwsx4184 power 0.0657 0.5 -> 0.256 Inexact Rounded +pwsx4185 power 0.658 0.5 -> 0.811 Inexact Rounded +pwsx4186 power 0.0658 0.5 -> 0.257 Inexact Rounded +pwsx4187 power 0.659 0.5 -> 0.812 Inexact Rounded +pwsx4188 power 0.0659 0.5 -> 0.257 Inexact Rounded +pwsx4189 power 0.661 0.5 -> 0.813 Inexact Rounded +pwsx4190 power 0.0661 0.5 -> 0.257 Inexact Rounded +pwsx4191 power 0.662 0.5 -> 0.814 Inexact Rounded +pwsx4192 power 0.0662 0.5 -> 0.257 Inexact Rounded +pwsx4193 power 0.663 0.5 -> 0.814 Inexact Rounded +pwsx4194 power 0.0663 0.5 -> 0.257 Inexact Rounded +pwsx4195 power 0.664 0.5 -> 0.815 Inexact Rounded +pwsx4196 power 0.0664 0.5 -> 0.258 Inexact Rounded +pwsx4197 power 0.665 0.5 -> 0.815 Inexact Rounded +pwsx4198 power 0.0665 0.5 -> 0.258 Inexact Rounded +pwsx4199 power 0.666 0.5 -> 0.816 Inexact Rounded +pwsx4200 power 0.0666 0.5 -> 0.258 Inexact Rounded +pwsx4201 power 0.667 0.5 -> 0.817 Inexact Rounded +pwsx4202 power 0.0667 0.5 -> 0.258 Inexact Rounded +pwsx4203 power 0.668 0.5 -> 0.817 Inexact Rounded +pwsx4204 power 0.0668 0.5 -> 0.258 Inexact Rounded +pwsx4205 power 0.669 0.5 -> 0.818 Inexact Rounded +pwsx4206 power 0.0669 0.5 -> 0.259 Inexact Rounded +pwsx4207 power 0.671 0.5 -> 0.819 Inexact Rounded +pwsx4208 power 0.0671 0.5 -> 0.259 Inexact Rounded +pwsx4209 power 0.672 0.5 -> 0.820 Inexact Rounded +pwsx4210 power 0.0672 0.5 -> 0.259 Inexact Rounded +pwsx4211 power 0.673 0.5 -> 0.820 Inexact Rounded +pwsx4212 power 0.0673 0.5 -> 0.259 Inexact Rounded +pwsx4213 power 0.674 0.5 -> 0.821 Inexact Rounded +pwsx4214 power 0.0674 0.5 -> 0.260 Inexact Rounded +pwsx4215 power 0.675 0.5 -> 0.822 Inexact Rounded +pwsx4216 power 0.0675 0.5 -> 0.260 Inexact Rounded +pwsx4217 power 0.676 0.5 -> 0.822 Inexact Rounded +pwsx4218 power 0.0676 0.5 -> 0.260 Inexact Rounded +pwsx4219 power 0.677 0.5 -> 0.823 Inexact Rounded +pwsx4220 power 0.0677 0.5 -> 0.260 Inexact Rounded +pwsx4221 power 0.678 0.5 -> 0.823 Inexact Rounded +pwsx4222 power 0.0678 0.5 -> 0.260 Inexact Rounded +pwsx4223 power 0.679 0.5 -> 0.824 Inexact Rounded +pwsx4224 power 0.0679 0.5 -> 0.261 Inexact Rounded +pwsx4225 power 0.681 0.5 -> 0.825 Inexact Rounded +pwsx4226 power 0.0681 0.5 -> 0.261 Inexact Rounded +pwsx4227 power 0.682 0.5 -> 0.826 Inexact Rounded +pwsx4228 power 0.0682 0.5 -> 0.261 Inexact Rounded +pwsx4229 power 0.683 0.5 -> 0.826 Inexact Rounded +pwsx4230 power 0.0683 0.5 -> 0.261 Inexact Rounded +pwsx4231 power 0.684 0.5 -> 0.827 Inexact Rounded +pwsx4232 power 0.0684 0.5 -> 0.262 Inexact Rounded +pwsx4233 power 0.685 0.5 -> 0.828 Inexact Rounded +pwsx4234 power 0.0685 0.5 -> 0.262 Inexact Rounded +pwsx4235 power 0.686 0.5 -> 0.828 Inexact Rounded +pwsx4236 power 0.0686 0.5 -> 0.262 Inexact Rounded +pwsx4237 power 0.687 0.5 -> 0.829 Inexact Rounded +pwsx4238 power 0.0687 0.5 -> 0.262 Inexact Rounded +pwsx4239 power 0.688 0.5 -> 0.829 Inexact Rounded +pwsx4240 power 0.0688 0.5 -> 0.262 Inexact Rounded +pwsx4241 power 0.689 0.5 -> 0.830 Inexact Rounded +pwsx4242 power 0.0689 0.5 -> 0.262 Inexact Rounded +pwsx4243 power 0.691 0.5 -> 0.831 Inexact Rounded +pwsx4244 power 0.0691 0.5 -> 0.263 Inexact Rounded +pwsx4245 power 0.692 0.5 -> 0.832 Inexact Rounded +pwsx4246 power 0.0692 0.5 -> 0.263 Inexact Rounded +pwsx4247 power 0.693 0.5 -> 0.832 Inexact Rounded +pwsx4248 power 0.0693 0.5 -> 0.263 Inexact Rounded +pwsx4249 power 0.694 0.5 -> 0.833 Inexact Rounded +pwsx4250 power 0.0694 0.5 -> 0.263 Inexact Rounded +pwsx4251 power 0.695 0.5 -> 0.834 Inexact Rounded +pwsx4252 power 0.0695 0.5 -> 0.264 Inexact Rounded +pwsx4253 power 0.696 0.5 -> 0.834 Inexact Rounded +pwsx4254 power 0.0696 0.5 -> 0.264 Inexact Rounded +pwsx4255 power 0.697 0.5 -> 0.835 Inexact Rounded +pwsx4256 power 0.0697 0.5 -> 0.264 Inexact Rounded +pwsx4257 power 0.698 0.5 -> 0.835 Inexact Rounded +pwsx4258 power 0.0698 0.5 -> 0.264 Inexact Rounded +pwsx4259 power 0.699 0.5 -> 0.836 Inexact Rounded +pwsx4260 power 0.0699 0.5 -> 0.264 Inexact Rounded +pwsx4261 power 0.701 0.5 -> 0.837 Inexact Rounded +pwsx4262 power 0.0701 0.5 -> 0.265 Inexact Rounded +pwsx4263 power 0.702 0.5 -> 0.838 Inexact Rounded +pwsx4264 power 0.0702 0.5 -> 0.265 Inexact Rounded +pwsx4265 power 0.703 0.5 -> 0.838 Inexact Rounded +pwsx4266 power 0.0703 0.5 -> 0.265 Inexact Rounded +pwsx4267 power 0.704 0.5 -> 0.839 Inexact Rounded +pwsx4268 power 0.0704 0.5 -> 0.265 Inexact Rounded +pwsx4269 power 0.705 0.5 -> 0.840 Inexact Rounded +pwsx4270 power 0.0705 0.5 -> 0.266 Inexact Rounded +pwsx4271 power 0.706 0.5 -> 0.840 Inexact Rounded +pwsx4272 power 0.0706 0.5 -> 0.266 Inexact Rounded +pwsx4273 power 0.707 0.5 -> 0.841 Inexact Rounded +pwsx4274 power 0.0707 0.5 -> 0.266 Inexact Rounded +pwsx4275 power 0.708 0.5 -> 0.841 Inexact Rounded +pwsx4276 power 0.0708 0.5 -> 0.266 Inexact Rounded +pwsx4277 power 0.709 0.5 -> 0.842 Inexact Rounded +pwsx4278 power 0.0709 0.5 -> 0.266 Inexact Rounded +pwsx4279 power 0.711 0.5 -> 0.843 Inexact Rounded +pwsx4280 power 0.0711 0.5 -> 0.267 Inexact Rounded +pwsx4281 power 0.712 0.5 -> 0.844 Inexact Rounded +pwsx4282 power 0.0712 0.5 -> 0.267 Inexact Rounded +pwsx4283 power 0.713 0.5 -> 0.844 Inexact Rounded +pwsx4284 power 0.0713 0.5 -> 0.267 Inexact Rounded +pwsx4285 power 0.714 0.5 -> 0.845 Inexact Rounded +pwsx4286 power 0.0714 0.5 -> 0.267 Inexact Rounded +pwsx4287 power 0.715 0.5 -> 0.846 Inexact Rounded +pwsx4288 power 0.0715 0.5 -> 0.267 Inexact Rounded +pwsx4289 power 0.716 0.5 -> 0.846 Inexact Rounded +pwsx4290 power 0.0716 0.5 -> 0.268 Inexact Rounded +pwsx4291 power 0.717 0.5 -> 0.847 Inexact Rounded +pwsx4292 power 0.0717 0.5 -> 0.268 Inexact Rounded +pwsx4293 power 0.718 0.5 -> 0.847 Inexact Rounded +pwsx4294 power 0.0718 0.5 -> 0.268 Inexact Rounded +pwsx4295 power 0.719 0.5 -> 0.848 Inexact Rounded +pwsx4296 power 0.0719 0.5 -> 0.268 Inexact Rounded +pwsx4297 power 0.721 0.5 -> 0.849 Inexact Rounded +pwsx4298 power 0.0721 0.5 -> 0.269 Inexact Rounded +pwsx4299 power 0.722 0.5 -> 0.850 Inexact Rounded +pwsx4300 power 0.0722 0.5 -> 0.269 Inexact Rounded +pwsx4301 power 0.723 0.5 -> 0.850 Inexact Rounded +pwsx4302 power 0.0723 0.5 -> 0.269 Inexact Rounded +pwsx4303 power 0.724 0.5 -> 0.851 Inexact Rounded +pwsx4304 power 0.0724 0.5 -> 0.269 Inexact Rounded +pwsx4305 power 0.725 0.5 -> 0.851 Inexact Rounded +pwsx4306 power 0.0725 0.5 -> 0.269 Inexact Rounded +pwsx4307 power 0.726 0.5 -> 0.852 Inexact Rounded +pwsx4308 power 0.0726 0.5 -> 0.269 Inexact Rounded +pwsx4309 power 0.727 0.5 -> 0.853 Inexact Rounded +pwsx4310 power 0.0727 0.5 -> 0.270 Inexact Rounded +pwsx4311 power 0.728 0.5 -> 0.853 Inexact Rounded +pwsx4312 power 0.0728 0.5 -> 0.270 Inexact Rounded +pwsx4313 power 0.729 0.5 -> 0.854 Inexact Rounded +pwsx4314 power 0.0729 0.5 -> 0.270 Inexact Rounded +pwsx4315 power 0.731 0.5 -> 0.855 Inexact Rounded +pwsx4316 power 0.0731 0.5 -> 0.270 Inexact Rounded +pwsx4317 power 0.732 0.5 -> 0.856 Inexact Rounded +pwsx4318 power 0.0732 0.5 -> 0.271 Inexact Rounded +pwsx4319 power 0.733 0.5 -> 0.856 Inexact Rounded +pwsx4320 power 0.0733 0.5 -> 0.271 Inexact Rounded +pwsx4321 power 0.734 0.5 -> 0.857 Inexact Rounded +pwsx4322 power 0.0734 0.5 -> 0.271 Inexact Rounded +pwsx4323 power 0.735 0.5 -> 0.857 Inexact Rounded +pwsx4324 power 0.0735 0.5 -> 0.271 Inexact Rounded +pwsx4325 power 0.736 0.5 -> 0.858 Inexact Rounded +pwsx4326 power 0.0736 0.5 -> 0.271 Inexact Rounded +pwsx4327 power 0.737 0.5 -> 0.858 Inexact Rounded +pwsx4328 power 0.0737 0.5 -> 0.271 Inexact Rounded +pwsx4329 power 0.738 0.5 -> 0.859 Inexact Rounded +pwsx4330 power 0.0738 0.5 -> 0.272 Inexact Rounded +pwsx4331 power 0.739 0.5 -> 0.860 Inexact Rounded +pwsx4332 power 0.0739 0.5 -> 0.272 Inexact Rounded +pwsx4333 power 0.741 0.5 -> 0.861 Inexact Rounded +pwsx4334 power 0.0741 0.5 -> 0.272 Inexact Rounded +pwsx4335 power 0.742 0.5 -> 0.861 Inexact Rounded +pwsx4336 power 0.0742 0.5 -> 0.272 Inexact Rounded +pwsx4337 power 0.743 0.5 -> 0.862 Inexact Rounded +pwsx4338 power 0.0743 0.5 -> 0.273 Inexact Rounded +pwsx4339 power 0.744 0.5 -> 0.863 Inexact Rounded +pwsx4340 power 0.0744 0.5 -> 0.273 Inexact Rounded +pwsx4341 power 0.745 0.5 -> 0.863 Inexact Rounded +pwsx4342 power 0.0745 0.5 -> 0.273 Inexact Rounded +pwsx4343 power 0.746 0.5 -> 0.864 Inexact Rounded +pwsx4344 power 0.0746 0.5 -> 0.273 Inexact Rounded +pwsx4345 power 0.747 0.5 -> 0.864 Inexact Rounded +pwsx4346 power 0.0747 0.5 -> 0.273 Inexact Rounded +pwsx4347 power 0.748 0.5 -> 0.865 Inexact Rounded +pwsx4348 power 0.0748 0.5 -> 0.273 Inexact Rounded +pwsx4349 power 0.749 0.5 -> 0.865 Inexact Rounded +pwsx4350 power 0.0749 0.5 -> 0.274 Inexact Rounded +pwsx4351 power 0.751 0.5 -> 0.867 Inexact Rounded +pwsx4352 power 0.0751 0.5 -> 0.274 Inexact Rounded +pwsx4353 power 0.752 0.5 -> 0.867 Inexact Rounded +pwsx4354 power 0.0752 0.5 -> 0.274 Inexact Rounded +pwsx4355 power 0.753 0.5 -> 0.868 Inexact Rounded +pwsx4356 power 0.0753 0.5 -> 0.274 Inexact Rounded +pwsx4357 power 0.754 0.5 -> 0.868 Inexact Rounded +pwsx4358 power 0.0754 0.5 -> 0.275 Inexact Rounded +pwsx4359 power 0.755 0.5 -> 0.869 Inexact Rounded +pwsx4360 power 0.0755 0.5 -> 0.275 Inexact Rounded +pwsx4361 power 0.756 0.5 -> 0.869 Inexact Rounded +pwsx4362 power 0.0756 0.5 -> 0.275 Inexact Rounded +pwsx4363 power 0.757 0.5 -> 0.870 Inexact Rounded +pwsx4364 power 0.0757 0.5 -> 0.275 Inexact Rounded +pwsx4365 power 0.758 0.5 -> 0.871 Inexact Rounded +pwsx4366 power 0.0758 0.5 -> 0.275 Inexact Rounded +pwsx4367 power 0.759 0.5 -> 0.871 Inexact Rounded +pwsx4368 power 0.0759 0.5 -> 0.275 Inexact Rounded +pwsx4369 power 0.761 0.5 -> 0.872 Inexact Rounded +pwsx4370 power 0.0761 0.5 -> 0.276 Inexact Rounded +pwsx4371 power 0.762 0.5 -> 0.873 Inexact Rounded +pwsx4372 power 0.0762 0.5 -> 0.276 Inexact Rounded +pwsx4373 power 0.763 0.5 -> 0.873 Inexact Rounded +pwsx4374 power 0.0763 0.5 -> 0.276 Inexact Rounded +pwsx4375 power 0.764 0.5 -> 0.874 Inexact Rounded +pwsx4376 power 0.0764 0.5 -> 0.276 Inexact Rounded +pwsx4377 power 0.765 0.5 -> 0.875 Inexact Rounded +pwsx4378 power 0.0765 0.5 -> 0.277 Inexact Rounded +pwsx4379 power 0.766 0.5 -> 0.875 Inexact Rounded +pwsx4380 power 0.0766 0.5 -> 0.277 Inexact Rounded +pwsx4381 power 0.767 0.5 -> 0.876 Inexact Rounded +pwsx4382 power 0.0767 0.5 -> 0.277 Inexact Rounded +pwsx4383 power 0.768 0.5 -> 0.876 Inexact Rounded +pwsx4384 power 0.0768 0.5 -> 0.277 Inexact Rounded +pwsx4385 power 0.769 0.5 -> 0.877 Inexact Rounded +pwsx4386 power 0.0769 0.5 -> 0.277 Inexact Rounded +pwsx4387 power 0.771 0.5 -> 0.878 Inexact Rounded +pwsx4388 power 0.0771 0.5 -> 0.278 Inexact Rounded +pwsx4389 power 0.772 0.5 -> 0.879 Inexact Rounded +pwsx4390 power 0.0772 0.5 -> 0.278 Inexact Rounded +pwsx4391 power 0.773 0.5 -> 0.879 Inexact Rounded +pwsx4392 power 0.0773 0.5 -> 0.278 Inexact Rounded +pwsx4393 power 0.774 0.5 -> 0.880 Inexact Rounded +pwsx4394 power 0.0774 0.5 -> 0.278 Inexact Rounded +pwsx4395 power 0.775 0.5 -> 0.880 Inexact Rounded +pwsx4396 power 0.0775 0.5 -> 0.278 Inexact Rounded +pwsx4397 power 0.776 0.5 -> 0.881 Inexact Rounded +pwsx4398 power 0.0776 0.5 -> 0.279 Inexact Rounded +pwsx4399 power 0.777 0.5 -> 0.881 Inexact Rounded +pwsx4400 power 0.0777 0.5 -> 0.279 Inexact Rounded +pwsx4401 power 0.778 0.5 -> 0.882 Inexact Rounded +pwsx4402 power 0.0778 0.5 -> 0.279 Inexact Rounded +pwsx4403 power 0.779 0.5 -> 0.883 Inexact Rounded +pwsx4404 power 0.0779 0.5 -> 0.279 Inexact Rounded +pwsx4405 power 0.781 0.5 -> 0.884 Inexact Rounded +pwsx4406 power 0.0781 0.5 -> 0.279 Inexact Rounded +pwsx4407 power 0.782 0.5 -> 0.884 Inexact Rounded +pwsx4408 power 0.0782 0.5 -> 0.280 Inexact Rounded +pwsx4409 power 0.783 0.5 -> 0.885 Inexact Rounded +pwsx4410 power 0.0783 0.5 -> 0.280 Inexact Rounded +pwsx4411 power 0.784 0.5 -> 0.885 Inexact Rounded +pwsx4412 power 0.0784 0.5 -> 0.280 Inexact Rounded +pwsx4413 power 0.785 0.5 -> 0.886 Inexact Rounded +pwsx4414 power 0.0785 0.5 -> 0.280 Inexact Rounded +pwsx4415 power 0.786 0.5 -> 0.887 Inexact Rounded +pwsx4416 power 0.0786 0.5 -> 0.280 Inexact Rounded +pwsx4417 power 0.787 0.5 -> 0.887 Inexact Rounded +pwsx4418 power 0.0787 0.5 -> 0.281 Inexact Rounded +pwsx4419 power 0.788 0.5 -> 0.888 Inexact Rounded +pwsx4420 power 0.0788 0.5 -> 0.281 Inexact Rounded +pwsx4421 power 0.789 0.5 -> 0.888 Inexact Rounded +pwsx4422 power 0.0789 0.5 -> 0.281 Inexact Rounded +pwsx4423 power 0.791 0.5 -> 0.889 Inexact Rounded +pwsx4424 power 0.0791 0.5 -> 0.281 Inexact Rounded +pwsx4425 power 0.792 0.5 -> 0.890 Inexact Rounded +pwsx4426 power 0.0792 0.5 -> 0.281 Inexact Rounded +pwsx4427 power 0.793 0.5 -> 0.891 Inexact Rounded +pwsx4428 power 0.0793 0.5 -> 0.282 Inexact Rounded +pwsx4429 power 0.794 0.5 -> 0.891 Inexact Rounded +pwsx4430 power 0.0794 0.5 -> 0.282 Inexact Rounded +pwsx4431 power 0.795 0.5 -> 0.892 Inexact Rounded +pwsx4432 power 0.0795 0.5 -> 0.282 Inexact Rounded +pwsx4433 power 0.796 0.5 -> 0.892 Inexact Rounded +pwsx4434 power 0.0796 0.5 -> 0.282 Inexact Rounded +pwsx4435 power 0.797 0.5 -> 0.893 Inexact Rounded +pwsx4436 power 0.0797 0.5 -> 0.282 Inexact Rounded +pwsx4437 power 0.798 0.5 -> 0.893 Inexact Rounded +pwsx4438 power 0.0798 0.5 -> 0.282 Inexact Rounded +pwsx4439 power 0.799 0.5 -> 0.894 Inexact Rounded +pwsx4440 power 0.0799 0.5 -> 0.283 Inexact Rounded +pwsx4441 power 0.801 0.5 -> 0.895 Inexact Rounded +pwsx4442 power 0.0801 0.5 -> 0.283 Inexact Rounded +pwsx4443 power 0.802 0.5 -> 0.896 Inexact Rounded +pwsx4444 power 0.0802 0.5 -> 0.283 Inexact Rounded +pwsx4445 power 0.803 0.5 -> 0.896 Inexact Rounded +pwsx4446 power 0.0803 0.5 -> 0.283 Inexact Rounded +pwsx4447 power 0.804 0.5 -> 0.897 Inexact Rounded +pwsx4448 power 0.0804 0.5 -> 0.284 Inexact Rounded +pwsx4449 power 0.805 0.5 -> 0.897 Inexact Rounded +pwsx4450 power 0.0805 0.5 -> 0.284 Inexact Rounded +pwsx4451 power 0.806 0.5 -> 0.898 Inexact Rounded +pwsx4452 power 0.0806 0.5 -> 0.284 Inexact Rounded +pwsx4453 power 0.807 0.5 -> 0.898 Inexact Rounded +pwsx4454 power 0.0807 0.5 -> 0.284 Inexact Rounded +pwsx4455 power 0.808 0.5 -> 0.899 Inexact Rounded +pwsx4456 power 0.0808 0.5 -> 0.284 Inexact Rounded +pwsx4457 power 0.809 0.5 -> 0.899 Inexact Rounded +pwsx4458 power 0.0809 0.5 -> 0.284 Inexact Rounded +pwsx4459 power 0.811 0.5 -> 0.901 Inexact Rounded +pwsx4460 power 0.0811 0.5 -> 0.285 Inexact Rounded +pwsx4461 power 0.812 0.5 -> 0.901 Inexact Rounded +pwsx4462 power 0.0812 0.5 -> 0.285 Inexact Rounded +pwsx4463 power 0.813 0.5 -> 0.902 Inexact Rounded +pwsx4464 power 0.0813 0.5 -> 0.285 Inexact Rounded +pwsx4465 power 0.814 0.5 -> 0.902 Inexact Rounded +pwsx4466 power 0.0814 0.5 -> 0.285 Inexact Rounded +pwsx4467 power 0.815 0.5 -> 0.903 Inexact Rounded +pwsx4468 power 0.0815 0.5 -> 0.285 Inexact Rounded +pwsx4469 power 0.816 0.5 -> 0.903 Inexact Rounded +pwsx4470 power 0.0816 0.5 -> 0.286 Inexact Rounded +pwsx4471 power 0.817 0.5 -> 0.904 Inexact Rounded +pwsx4472 power 0.0817 0.5 -> 0.286 Inexact Rounded +pwsx4473 power 0.818 0.5 -> 0.904 Inexact Rounded +pwsx4474 power 0.0818 0.5 -> 0.286 Inexact Rounded +pwsx4475 power 0.819 0.5 -> 0.905 Inexact Rounded +pwsx4476 power 0.0819 0.5 -> 0.286 Inexact Rounded +pwsx4477 power 0.821 0.5 -> 0.906 Inexact Rounded +pwsx4478 power 0.0821 0.5 -> 0.287 Inexact Rounded +pwsx4479 power 0.822 0.5 -> 0.907 Inexact Rounded +pwsx4480 power 0.0822 0.5 -> 0.287 Inexact Rounded +pwsx4481 power 0.823 0.5 -> 0.907 Inexact Rounded +pwsx4482 power 0.0823 0.5 -> 0.287 Inexact Rounded +pwsx4483 power 0.824 0.5 -> 0.908 Inexact Rounded +pwsx4484 power 0.0824 0.5 -> 0.287 Inexact Rounded +pwsx4485 power 0.825 0.5 -> 0.908 Inexact Rounded +pwsx4486 power 0.0825 0.5 -> 0.287 Inexact Rounded +pwsx4487 power 0.826 0.5 -> 0.909 Inexact Rounded +pwsx4488 power 0.0826 0.5 -> 0.287 Inexact Rounded +pwsx4489 power 0.827 0.5 -> 0.909 Inexact Rounded +pwsx4490 power 0.0827 0.5 -> 0.288 Inexact Rounded +pwsx4491 power 0.828 0.5 -> 0.910 Inexact Rounded +pwsx4492 power 0.0828 0.5 -> 0.288 Inexact Rounded +pwsx4493 power 0.829 0.5 -> 0.910 Inexact Rounded +pwsx4494 power 0.0829 0.5 -> 0.288 Inexact Rounded +pwsx4495 power 0.831 0.5 -> 0.912 Inexact Rounded +pwsx4496 power 0.0831 0.5 -> 0.288 Inexact Rounded +pwsx4497 power 0.832 0.5 -> 0.912 Inexact Rounded +pwsx4498 power 0.0832 0.5 -> 0.288 Inexact Rounded +pwsx4499 power 0.833 0.5 -> 0.913 Inexact Rounded +pwsx4500 power 0.0833 0.5 -> 0.289 Inexact Rounded +pwsx4501 power 0.834 0.5 -> 0.913 Inexact Rounded +pwsx4502 power 0.0834 0.5 -> 0.289 Inexact Rounded +pwsx4503 power 0.835 0.5 -> 0.914 Inexact Rounded +pwsx4504 power 0.0835 0.5 -> 0.289 Inexact Rounded +pwsx4505 power 0.836 0.5 -> 0.914 Inexact Rounded +pwsx4506 power 0.0836 0.5 -> 0.289 Inexact Rounded +pwsx4507 power 0.837 0.5 -> 0.915 Inexact Rounded +pwsx4508 power 0.0837 0.5 -> 0.289 Inexact Rounded +pwsx4509 power 0.838 0.5 -> 0.915 Inexact Rounded +pwsx4510 power 0.0838 0.5 -> 0.289 Inexact Rounded +pwsx4511 power 0.839 0.5 -> 0.916 Inexact Rounded +pwsx4512 power 0.0839 0.5 -> 0.290 Inexact Rounded +pwsx4513 power 0.841 0.5 -> 0.917 Inexact Rounded +pwsx4514 power 0.0841 0.5 -> 0.290 Inexact Rounded +pwsx4515 power 0.842 0.5 -> 0.918 Inexact Rounded +pwsx4516 power 0.0842 0.5 -> 0.290 Inexact Rounded +pwsx4517 power 0.843 0.5 -> 0.918 Inexact Rounded +pwsx4518 power 0.0843 0.5 -> 0.290 Inexact Rounded +pwsx4519 power 0.844 0.5 -> 0.919 Inexact Rounded +pwsx4520 power 0.0844 0.5 -> 0.291 Inexact Rounded +pwsx4521 power 0.845 0.5 -> 0.919 Inexact Rounded +pwsx4522 power 0.0845 0.5 -> 0.291 Inexact Rounded +pwsx4523 power 0.846 0.5 -> 0.920 Inexact Rounded +pwsx4524 power 0.0846 0.5 -> 0.291 Inexact Rounded +pwsx4525 power 0.847 0.5 -> 0.920 Inexact Rounded +pwsx4526 power 0.0847 0.5 -> 0.291 Inexact Rounded +pwsx4527 power 0.848 0.5 -> 0.921 Inexact Rounded +pwsx4528 power 0.0848 0.5 -> 0.291 Inexact Rounded +pwsx4529 power 0.849 0.5 -> 0.921 Inexact Rounded +pwsx4530 power 0.0849 0.5 -> 0.291 Inexact Rounded +pwsx4531 power 0.851 0.5 -> 0.922 Inexact Rounded +pwsx4532 power 0.0851 0.5 -> 0.292 Inexact Rounded +pwsx4533 power 0.852 0.5 -> 0.923 Inexact Rounded +pwsx4534 power 0.0852 0.5 -> 0.292 Inexact Rounded +pwsx4535 power 0.853 0.5 -> 0.924 Inexact Rounded +pwsx4536 power 0.0853 0.5 -> 0.292 Inexact Rounded +pwsx4537 power 0.854 0.5 -> 0.924 Inexact Rounded +pwsx4538 power 0.0854 0.5 -> 0.292 Inexact Rounded +pwsx4539 power 0.855 0.5 -> 0.925 Inexact Rounded +pwsx4540 power 0.0855 0.5 -> 0.292 Inexact Rounded +pwsx4541 power 0.856 0.5 -> 0.925 Inexact Rounded +pwsx4542 power 0.0856 0.5 -> 0.293 Inexact Rounded +pwsx4543 power 0.857 0.5 -> 0.926 Inexact Rounded +pwsx4544 power 0.0857 0.5 -> 0.293 Inexact Rounded +pwsx4545 power 0.858 0.5 -> 0.926 Inexact Rounded +pwsx4546 power 0.0858 0.5 -> 0.293 Inexact Rounded +pwsx4547 power 0.859 0.5 -> 0.927 Inexact Rounded +pwsx4548 power 0.0859 0.5 -> 0.293 Inexact Rounded +pwsx4549 power 0.861 0.5 -> 0.928 Inexact Rounded +pwsx4550 power 0.0861 0.5 -> 0.293 Inexact Rounded +pwsx4551 power 0.862 0.5 -> 0.928 Inexact Rounded +pwsx4552 power 0.0862 0.5 -> 0.294 Inexact Rounded +pwsx4553 power 0.863 0.5 -> 0.929 Inexact Rounded +pwsx4554 power 0.0863 0.5 -> 0.294 Inexact Rounded +pwsx4555 power 0.864 0.5 -> 0.930 Inexact Rounded +pwsx4556 power 0.0864 0.5 -> 0.294 Inexact Rounded +pwsx4557 power 0.865 0.5 -> 0.930 Inexact Rounded +pwsx4558 power 0.0865 0.5 -> 0.294 Inexact Rounded +pwsx4559 power 0.866 0.5 -> 0.931 Inexact Rounded +pwsx4560 power 0.0866 0.5 -> 0.294 Inexact Rounded +pwsx4561 power 0.867 0.5 -> 0.931 Inexact Rounded +pwsx4562 power 0.0867 0.5 -> 0.294 Inexact Rounded +pwsx4563 power 0.868 0.5 -> 0.932 Inexact Rounded +pwsx4564 power 0.0868 0.5 -> 0.295 Inexact Rounded +pwsx4565 power 0.869 0.5 -> 0.932 Inexact Rounded +pwsx4566 power 0.0869 0.5 -> 0.295 Inexact Rounded +pwsx4567 power 0.871 0.5 -> 0.933 Inexact Rounded +pwsx4568 power 0.0871 0.5 -> 0.295 Inexact Rounded +pwsx4569 power 0.872 0.5 -> 0.934 Inexact Rounded +pwsx4570 power 0.0872 0.5 -> 0.295 Inexact Rounded +pwsx4571 power 0.873 0.5 -> 0.934 Inexact Rounded +pwsx4572 power 0.0873 0.5 -> 0.295 Inexact Rounded +pwsx4573 power 0.874 0.5 -> 0.935 Inexact Rounded +pwsx4574 power 0.0874 0.5 -> 0.296 Inexact Rounded +pwsx4575 power 0.875 0.5 -> 0.935 Inexact Rounded +pwsx4576 power 0.0875 0.5 -> 0.296 Inexact Rounded +pwsx4577 power 0.876 0.5 -> 0.936 Inexact Rounded +pwsx4578 power 0.0876 0.5 -> 0.296 Inexact Rounded +pwsx4579 power 0.877 0.5 -> 0.936 Inexact Rounded +pwsx4580 power 0.0877 0.5 -> 0.296 Inexact Rounded +pwsx4581 power 0.878 0.5 -> 0.937 Inexact Rounded +pwsx4582 power 0.0878 0.5 -> 0.296 Inexact Rounded +pwsx4583 power 0.879 0.5 -> 0.938 Inexact Rounded +pwsx4584 power 0.0879 0.5 -> 0.296 Inexact Rounded +pwsx4585 power 0.881 0.5 -> 0.939 Inexact Rounded +pwsx4586 power 0.0881 0.5 -> 0.297 Inexact Rounded +pwsx4587 power 0.882 0.5 -> 0.939 Inexact Rounded +pwsx4588 power 0.0882 0.5 -> 0.297 Inexact Rounded +pwsx4589 power 0.883 0.5 -> 0.940 Inexact Rounded +pwsx4590 power 0.0883 0.5 -> 0.297 Inexact Rounded +pwsx4591 power 0.884 0.5 -> 0.940 Inexact Rounded +pwsx4592 power 0.0884 0.5 -> 0.297 Inexact Rounded +pwsx4593 power 0.885 0.5 -> 0.941 Inexact Rounded +pwsx4594 power 0.0885 0.5 -> 0.297 Inexact Rounded +pwsx4595 power 0.886 0.5 -> 0.941 Inexact Rounded +pwsx4596 power 0.0886 0.5 -> 0.298 Inexact Rounded +pwsx4597 power 0.887 0.5 -> 0.942 Inexact Rounded +pwsx4598 power 0.0887 0.5 -> 0.298 Inexact Rounded +pwsx4599 power 0.888 0.5 -> 0.942 Inexact Rounded +pwsx4600 power 0.0888 0.5 -> 0.298 Inexact Rounded +pwsx4601 power 0.889 0.5 -> 0.943 Inexact Rounded +pwsx4602 power 0.0889 0.5 -> 0.298 Inexact Rounded +pwsx4603 power 0.891 0.5 -> 0.944 Inexact Rounded +pwsx4604 power 0.0891 0.5 -> 0.298 Inexact Rounded +pwsx4605 power 0.892 0.5 -> 0.944 Inexact Rounded +pwsx4606 power 0.0892 0.5 -> 0.299 Inexact Rounded +pwsx4607 power 0.893 0.5 -> 0.945 Inexact Rounded +pwsx4608 power 0.0893 0.5 -> 0.299 Inexact Rounded +pwsx4609 power 0.894 0.5 -> 0.946 Inexact Rounded +pwsx4610 power 0.0894 0.5 -> 0.299 Inexact Rounded +pwsx4611 power 0.895 0.5 -> 0.946 Inexact Rounded +pwsx4612 power 0.0895 0.5 -> 0.299 Inexact Rounded +pwsx4613 power 0.896 0.5 -> 0.947 Inexact Rounded +pwsx4614 power 0.0896 0.5 -> 0.299 Inexact Rounded +pwsx4615 power 0.897 0.5 -> 0.947 Inexact Rounded +pwsx4616 power 0.0897 0.5 -> 0.299 Inexact Rounded +pwsx4617 power 0.898 0.5 -> 0.948 Inexact Rounded +pwsx4618 power 0.0898 0.5 -> 0.300 Inexact Rounded +pwsx4619 power 0.899 0.5 -> 0.948 Inexact Rounded +pwsx4620 power 0.0899 0.5 -> 0.300 Inexact Rounded +pwsx4621 power 0.901 0.5 -> 0.949 Inexact Rounded +pwsx4622 power 0.0901 0.5 -> 0.300 Inexact Rounded +pwsx4623 power 0.902 0.5 -> 0.950 Inexact Rounded +pwsx4624 power 0.0902 0.5 -> 0.300 Inexact Rounded +pwsx4625 power 0.903 0.5 -> 0.950 Inexact Rounded +pwsx4626 power 0.0903 0.5 -> 0.300 Inexact Rounded +pwsx4627 power 0.904 0.5 -> 0.951 Inexact Rounded +pwsx4628 power 0.0904 0.5 -> 0.301 Inexact Rounded +pwsx4629 power 0.905 0.5 -> 0.951 Inexact Rounded +pwsx4630 power 0.0905 0.5 -> 0.301 Inexact Rounded +pwsx4631 power 0.906 0.5 -> 0.952 Inexact Rounded +pwsx4632 power 0.0906 0.5 -> 0.301 Inexact Rounded +pwsx4633 power 0.907 0.5 -> 0.952 Inexact Rounded +pwsx4634 power 0.0907 0.5 -> 0.301 Inexact Rounded +pwsx4635 power 0.908 0.5 -> 0.953 Inexact Rounded +pwsx4636 power 0.0908 0.5 -> 0.301 Inexact Rounded +pwsx4637 power 0.909 0.5 -> 0.953 Inexact Rounded +pwsx4638 power 0.0909 0.5 -> 0.301 Inexact Rounded +pwsx4639 power 0.911 0.5 -> 0.954 Inexact Rounded +pwsx4640 power 0.0911 0.5 -> 0.302 Inexact Rounded +pwsx4641 power 0.912 0.5 -> 0.955 Inexact Rounded +pwsx4642 power 0.0912 0.5 -> 0.302 Inexact Rounded +pwsx4643 power 0.913 0.5 -> 0.956 Inexact Rounded +pwsx4644 power 0.0913 0.5 -> 0.302 Inexact Rounded +pwsx4645 power 0.914 0.5 -> 0.956 Inexact Rounded +pwsx4646 power 0.0914 0.5 -> 0.302 Inexact Rounded +pwsx4647 power 0.915 0.5 -> 0.957 Inexact Rounded +pwsx4648 power 0.0915 0.5 -> 0.302 Inexact Rounded +pwsx4649 power 0.916 0.5 -> 0.957 Inexact Rounded +pwsx4650 power 0.0916 0.5 -> 0.303 Inexact Rounded +pwsx4651 power 0.917 0.5 -> 0.958 Inexact Rounded +pwsx4652 power 0.0917 0.5 -> 0.303 Inexact Rounded +pwsx4653 power 0.918 0.5 -> 0.958 Inexact Rounded +pwsx4654 power 0.0918 0.5 -> 0.303 Inexact Rounded +pwsx4655 power 0.919 0.5 -> 0.959 Inexact Rounded +pwsx4656 power 0.0919 0.5 -> 0.303 Inexact Rounded +pwsx4657 power 0.921 0.5 -> 0.960 Inexact Rounded +pwsx4658 power 0.0921 0.5 -> 0.303 Inexact Rounded +pwsx4659 power 0.922 0.5 -> 0.960 Inexact Rounded +pwsx4660 power 0.0922 0.5 -> 0.304 Inexact Rounded +pwsx4661 power 0.923 0.5 -> 0.961 Inexact Rounded +pwsx4662 power 0.0923 0.5 -> 0.304 Inexact Rounded +pwsx4663 power 0.924 0.5 -> 0.961 Inexact Rounded +pwsx4664 power 0.0924 0.5 -> 0.304 Inexact Rounded +pwsx4665 power 0.925 0.5 -> 0.962 Inexact Rounded +pwsx4666 power 0.0925 0.5 -> 0.304 Inexact Rounded +pwsx4667 power 0.926 0.5 -> 0.962 Inexact Rounded +pwsx4668 power 0.0926 0.5 -> 0.304 Inexact Rounded +pwsx4669 power 0.927 0.5 -> 0.963 Inexact Rounded +pwsx4670 power 0.0927 0.5 -> 0.304 Inexact Rounded +pwsx4671 power 0.928 0.5 -> 0.963 Inexact Rounded +pwsx4672 power 0.0928 0.5 -> 0.305 Inexact Rounded +pwsx4673 power 0.929 0.5 -> 0.964 Inexact Rounded +pwsx4674 power 0.0929 0.5 -> 0.305 Inexact Rounded +pwsx4675 power 0.931 0.5 -> 0.965 Inexact Rounded +pwsx4676 power 0.0931 0.5 -> 0.305 Inexact Rounded +pwsx4677 power 0.932 0.5 -> 0.965 Inexact Rounded +pwsx4678 power 0.0932 0.5 -> 0.305 Inexact Rounded +pwsx4679 power 0.933 0.5 -> 0.966 Inexact Rounded +pwsx4680 power 0.0933 0.5 -> 0.305 Inexact Rounded +pwsx4681 power 0.934 0.5 -> 0.966 Inexact Rounded +pwsx4682 power 0.0934 0.5 -> 0.306 Inexact Rounded +pwsx4683 power 0.935 0.5 -> 0.967 Inexact Rounded +pwsx4684 power 0.0935 0.5 -> 0.306 Inexact Rounded +pwsx4685 power 0.936 0.5 -> 0.967 Inexact Rounded +pwsx4686 power 0.0936 0.5 -> 0.306 Inexact Rounded +pwsx4687 power 0.937 0.5 -> 0.968 Inexact Rounded +pwsx4688 power 0.0937 0.5 -> 0.306 Inexact Rounded +pwsx4689 power 0.938 0.5 -> 0.969 Inexact Rounded +pwsx4690 power 0.0938 0.5 -> 0.306 Inexact Rounded +pwsx4691 power 0.939 0.5 -> 0.969 Inexact Rounded +pwsx4692 power 0.0939 0.5 -> 0.306 Inexact Rounded +pwsx4693 power 0.941 0.5 -> 0.970 Inexact Rounded +pwsx4694 power 0.0941 0.5 -> 0.307 Inexact Rounded +pwsx4695 power 0.942 0.5 -> 0.971 Inexact Rounded +pwsx4696 power 0.0942 0.5 -> 0.307 Inexact Rounded +pwsx4697 power 0.943 0.5 -> 0.971 Inexact Rounded +pwsx4698 power 0.0943 0.5 -> 0.307 Inexact Rounded +pwsx4699 power 0.944 0.5 -> 0.972 Inexact Rounded +pwsx4700 power 0.0944 0.5 -> 0.307 Inexact Rounded +pwsx4701 power 0.945 0.5 -> 0.972 Inexact Rounded +pwsx4702 power 0.0945 0.5 -> 0.307 Inexact Rounded +pwsx4703 power 0.946 0.5 -> 0.973 Inexact Rounded +pwsx4704 power 0.0946 0.5 -> 0.308 Inexact Rounded +pwsx4705 power 0.947 0.5 -> 0.973 Inexact Rounded +pwsx4706 power 0.0947 0.5 -> 0.308 Inexact Rounded +pwsx4707 power 0.948 0.5 -> 0.974 Inexact Rounded +pwsx4708 power 0.0948 0.5 -> 0.308 Inexact Rounded +pwsx4709 power 0.949 0.5 -> 0.974 Inexact Rounded +pwsx4710 power 0.0949 0.5 -> 0.308 Inexact Rounded +pwsx4711 power 0.951 0.5 -> 0.975 Inexact Rounded +pwsx4712 power 0.0951 0.5 -> 0.308 Inexact Rounded +pwsx4713 power 0.952 0.5 -> 0.976 Inexact Rounded +pwsx4714 power 0.0952 0.5 -> 0.309 Inexact Rounded +pwsx4715 power 0.953 0.5 -> 0.976 Inexact Rounded +pwsx4716 power 0.0953 0.5 -> 0.309 Inexact Rounded +pwsx4717 power 0.954 0.5 -> 0.977 Inexact Rounded +pwsx4718 power 0.0954 0.5 -> 0.309 Inexact Rounded +pwsx4719 power 0.955 0.5 -> 0.977 Inexact Rounded +pwsx4720 power 0.0955 0.5 -> 0.309 Inexact Rounded +pwsx4721 power 0.956 0.5 -> 0.978 Inexact Rounded +pwsx4722 power 0.0956 0.5 -> 0.309 Inexact Rounded +pwsx4723 power 0.957 0.5 -> 0.978 Inexact Rounded +pwsx4724 power 0.0957 0.5 -> 0.309 Inexact Rounded +pwsx4725 power 0.958 0.5 -> 0.979 Inexact Rounded +pwsx4726 power 0.0958 0.5 -> 0.310 Inexact Rounded +pwsx4727 power 0.959 0.5 -> 0.979 Inexact Rounded +pwsx4728 power 0.0959 0.5 -> 0.310 Inexact Rounded +pwsx4729 power 0.961 0.5 -> 0.980 Inexact Rounded +pwsx4730 power 0.0961 0.5 -> 0.310 Inexact Rounded +pwsx4731 power 0.962 0.5 -> 0.981 Inexact Rounded +pwsx4732 power 0.0962 0.5 -> 0.310 Inexact Rounded +pwsx4733 power 0.963 0.5 -> 0.981 Inexact Rounded +pwsx4734 power 0.0963 0.5 -> 0.310 Inexact Rounded +pwsx4735 power 0.964 0.5 -> 0.982 Inexact Rounded +pwsx4736 power 0.0964 0.5 -> 0.310 Inexact Rounded +pwsx4737 power 0.965 0.5 -> 0.982 Inexact Rounded +pwsx4738 power 0.0965 0.5 -> 0.311 Inexact Rounded +pwsx4739 power 0.966 0.5 -> 0.983 Inexact Rounded +pwsx4740 power 0.0966 0.5 -> 0.311 Inexact Rounded +pwsx4741 power 0.967 0.5 -> 0.983 Inexact Rounded +pwsx4742 power 0.0967 0.5 -> 0.311 Inexact Rounded +pwsx4743 power 0.968 0.5 -> 0.984 Inexact Rounded +pwsx4744 power 0.0968 0.5 -> 0.311 Inexact Rounded +pwsx4745 power 0.969 0.5 -> 0.984 Inexact Rounded +pwsx4746 power 0.0969 0.5 -> 0.311 Inexact Rounded +pwsx4747 power 0.971 0.5 -> 0.985 Inexact Rounded +pwsx4748 power 0.0971 0.5 -> 0.312 Inexact Rounded +pwsx4749 power 0.972 0.5 -> 0.986 Inexact Rounded +pwsx4750 power 0.0972 0.5 -> 0.312 Inexact Rounded +pwsx4751 power 0.973 0.5 -> 0.986 Inexact Rounded +pwsx4752 power 0.0973 0.5 -> 0.312 Inexact Rounded +pwsx4753 power 0.974 0.5 -> 0.987 Inexact Rounded +pwsx4754 power 0.0974 0.5 -> 0.312 Inexact Rounded +pwsx4755 power 0.975 0.5 -> 0.987 Inexact Rounded +pwsx4756 power 0.0975 0.5 -> 0.312 Inexact Rounded +pwsx4757 power 0.976 0.5 -> 0.988 Inexact Rounded +pwsx4758 power 0.0976 0.5 -> 0.312 Inexact Rounded +pwsx4759 power 0.977 0.5 -> 0.988 Inexact Rounded +pwsx4760 power 0.0977 0.5 -> 0.313 Inexact Rounded +pwsx4761 power 0.978 0.5 -> 0.989 Inexact Rounded +pwsx4762 power 0.0978 0.5 -> 0.313 Inexact Rounded +pwsx4763 power 0.979 0.5 -> 0.989 Inexact Rounded +pwsx4764 power 0.0979 0.5 -> 0.313 Inexact Rounded +pwsx4765 power 0.981 0.5 -> 0.990 Inexact Rounded +pwsx4766 power 0.0981 0.5 -> 0.313 Inexact Rounded +pwsx4767 power 0.982 0.5 -> 0.991 Inexact Rounded +pwsx4768 power 0.0982 0.5 -> 0.313 Inexact Rounded +pwsx4769 power 0.983 0.5 -> 0.991 Inexact Rounded +pwsx4770 power 0.0983 0.5 -> 0.314 Inexact Rounded +pwsx4771 power 0.984 0.5 -> 0.992 Inexact Rounded +pwsx4772 power 0.0984 0.5 -> 0.314 Inexact Rounded +pwsx4773 power 0.985 0.5 -> 0.992 Inexact Rounded +pwsx4774 power 0.0985 0.5 -> 0.314 Inexact Rounded +pwsx4775 power 0.986 0.5 -> 0.993 Inexact Rounded +pwsx4776 power 0.0986 0.5 -> 0.314 Inexact Rounded +pwsx4777 power 0.987 0.5 -> 0.993 Inexact Rounded +pwsx4778 power 0.0987 0.5 -> 0.314 Inexact Rounded +pwsx4779 power 0.988 0.5 -> 0.994 Inexact Rounded +pwsx4780 power 0.0988 0.5 -> 0.314 Inexact Rounded +pwsx4781 power 0.989 0.5 -> 0.994 Inexact Rounded +pwsx4782 power 0.0989 0.5 -> 0.314 Inexact Rounded +pwsx4783 power 0.991 0.5 -> 0.995 Inexact Rounded +pwsx4784 power 0.0991 0.5 -> 0.315 Inexact Rounded +pwsx4785 power 0.992 0.5 -> 0.996 Inexact Rounded +pwsx4786 power 0.0992 0.5 -> 0.315 Inexact Rounded +pwsx4787 power 0.993 0.5 -> 0.996 Inexact Rounded +pwsx4788 power 0.0993 0.5 -> 0.315 Inexact Rounded +pwsx4789 power 0.994 0.5 -> 0.997 Inexact Rounded +pwsx4790 power 0.0994 0.5 -> 0.315 Inexact Rounded +pwsx4791 power 0.995 0.5 -> 0.997 Inexact Rounded +pwsx4792 power 0.0995 0.5 -> 0.315 Inexact Rounded +pwsx4793 power 0.996 0.5 -> 0.998 Inexact Rounded +pwsx4794 power 0.0996 0.5 -> 0.316 Inexact Rounded +pwsx4795 power 0.997 0.5 -> 0.998 Inexact Rounded +pwsx4796 power 0.0997 0.5 -> 0.316 Inexact Rounded +pwsx4797 power 0.998 0.5 -> 0.999 Inexact Rounded +pwsx4798 power 0.0998 0.5 -> 0.316 Inexact Rounded +pwsx4799 power 0.999 0.5 -> 0.999 Inexact Rounded +pwsx4800 power 0.0999 0.5 -> 0.316 Inexact Rounded + +-- A group of precision 4 tests where Hull & Abrham adjustments are +-- needed in some cases (both up and down) [see Hull1985b] +rounding: half_even +maxExponent: 999 +minexponent: -999 +precision: 4 +pwsx5001 power 0.0118 0.5 -> 0.1086 Inexact Rounded +pwsx5002 power 0.119 0.5 -> 0.3450 Inexact Rounded +pwsx5003 power 0.0119 0.5 -> 0.1091 Inexact Rounded +pwsx5004 power 0.121 0.5 -> 0.3479 Inexact Rounded +pwsx5005 power 0.0121 0.5 -> 0.1100 Inexact Rounded +pwsx5006 power 0.122 0.5 -> 0.3493 Inexact Rounded +pwsx5007 power 0.0122 0.5 -> 0.1105 Inexact Rounded +pwsx5008 power 0.123 0.5 -> 0.3507 Inexact Rounded +pwsx5009 power 0.494 0.5 -> 0.7029 Inexact Rounded +pwsx5010 power 0.0669 0.5 -> 0.2587 Inexact Rounded +pwsx5011 power 0.9558 0.5 -> 0.9777 Inexact Rounded +pwsx5012 power 0.9348 0.5 -> 0.9669 Inexact Rounded +pwsx5013 power 0.9345 0.5 -> 0.9667 Inexact Rounded +pwsx5014 power 0.09345 0.5 -> 0.3057 Inexact Rounded +pwsx5015 power 0.9346 0.5 -> 0.9667 Inexact Rounded +pwsx5016 power 0.09346 0.5 -> 0.3057 Inexact Rounded +pwsx5017 power 0.9347 0.5 -> 0.9668 Inexact Rounded + +-- examples from decArith +precision: 9 +pwsx700 power 0 0.5 -> '0' +pwsx701 power -0 0.5 -> '0' +pwsx702 power 0.39 0.5 -> 0.624499800 Inexact Rounded +pwsx703 power 100 0.5 -> '10.0000000' Inexact Rounded +pwsx704 power 1.00 0.5 -> '1.00000000' Inexact Rounded +pwsx705 power 7 0.5 -> '2.64575131' Inexact Rounded +pwsx706 power 10 0.5 -> 3.16227766 Inexact Rounded + +-- some one-offs +precision: 9 +pwsx711 power 0.1 0.5 -> 0.316227766 Inexact Rounded +pwsx712 power 0.2 0.5 -> 0.447213595 Inexact Rounded +pwsx713 power 0.3 0.5 -> 0.547722558 Inexact Rounded +pwsx714 power 0.4 0.5 -> 0.632455532 Inexact Rounded +pwsx715 power 0.5 0.5 -> 0.707106781 Inexact Rounded +pwsx716 power 0.6 0.5 -> 0.774596669 Inexact Rounded +pwsx717 power 0.7 0.5 -> 0.836660027 Inexact Rounded +pwsx718 power 0.8 0.5 -> 0.894427191 Inexact Rounded +pwsx719 power 0.9 0.5 -> 0.948683298 Inexact Rounded +precision: 10 -- note no normalizatoin here +pwsx720 power +0.1 0.5 -> 0.3162277660 Inexact Rounded +precision: 11 +pwsx721 power +0.1 0.5 -> 0.31622776602 Inexact Rounded +precision: 12 +pwsx722 power +0.1 0.5 -> 0.316227766017 Inexact Rounded +precision: 9 +pwsx723 power 0.39 0.5 -> 0.624499800 Inexact Rounded +precision: 15 +pwsx724 power 0.39 0.5 -> 0.624499799839840 Inexact Rounded + +-- discussion cases +precision: 7 +pwsx731 power 9 0.5 -> 3.000000 Inexact Rounded +pwsx732 power 100 0.5 -> 10.00000 Inexact Rounded +pwsx733 power 123 0.5 -> 11.09054 Inexact Rounded +pwsx734 power 144 0.5 -> 12.00000 Inexact Rounded +pwsx735 power 156 0.5 -> 12.49000 Inexact Rounded +pwsx736 power 10000 0.5 -> 100.0000 Inexact Rounded + +-- values close to overflow (if there were input rounding) +maxexponent: 99 +minexponent: -99 +precision: 5 +pwsx760 power 9.9997E+99 0.5 -> 9.9998E+49 Inexact Rounded +pwsx761 power 9.9998E+99 0.5 -> 9.9999E+49 Inexact Rounded +pwsx762 power 9.9999E+99 0.5 -> 9.9999E+49 Inexact Rounded +pwsx763 power 9.99991E+99 0.5 -> 1.0000E+50 Inexact Rounded +pwsx764 power 9.99994E+99 0.5 -> 1.0000E+50 Inexact Rounded +pwsx765 power 9.99995E+99 0.5 -> 1.0000E+50 Inexact Rounded +pwsx766 power 9.99999E+99 0.5 -> 1.0000E+50 Inexact Rounded +precision: 9 +pwsx770 power 9.9997E+99 0.5 -> 9.99985000E+49 Inexact Rounded +pwsx771 power 9.9998E+99 0.5 -> 9.99990000E+49 Inexact Rounded +pwsx772 power 9.9999E+99 0.5 -> 9.99995000E+49 Inexact Rounded +pwsx773 power 9.99991E+99 0.5 -> 9.99995500E+49 Inexact Rounded +pwsx774 power 9.99994E+99 0.5 -> 9.99997000E+49 Inexact Rounded +pwsx775 power 9.99995E+99 0.5 -> 9.99997500E+49 Inexact Rounded +pwsx776 power 9.99999E+99 0.5 -> 9.99999500E+49 Inexact Rounded +precision: 20 +pwsx780 power 9.9997E+99 0.5 -> '9.9998499988749831247E+49' Inexact Rounded +pwsx781 power 9.9998E+99 0.5 -> '9.9998999994999949999E+49' Inexact Rounded +pwsx782 power 9.9999E+99 0.5 -> '9.9999499998749993750E+49' Inexact Rounded +pwsx783 power 9.99991E+99 0.5 -> '9.9999549998987495444E+49' Inexact Rounded +pwsx784 power 9.99994E+99 0.5 -> '9.9999699999549998650E+49' Inexact Rounded +pwsx785 power 9.99995E+99 0.5 -> '9.9999749999687499219E+49' Inexact Rounded +pwsx786 power 9.99999E+99 0.5 -> '9.9999949999987499994E+49' Inexact Rounded + +-- subnormals and underflows [these can only result when eMax is < digits+1] +-- Etiny = -(Emax + (precision-1)) +-- start with subnormal operands and normal results +maxexponent: 9 +minexponent: -9 +precision: 9 -- Etiny=-17 +pwsx800 power 1E-17 0.5 -> 3.16227766E-9 Inexact Rounded +pwsx801 power 10E-17 0.5 -> 1.00000000E-8 Inexact Rounded +precision: 10 -- Etiny=-18 +pwsx802 power 10E-18 0.5 -> 3.162277660E-9 Inexact Rounded +pwsx803 power 1E-18 0.5 -> 1.000000000E-9 Inexact Rounded + +precision: 11 -- Etiny=-19 +pwsx804 power 1E-19 0.5 -> 3.162277660E-10 Underflow Subnormal Inexact Rounded +-- The next test should be skipped for decNumber +pwsx805 power 10E-19 0.5 -> 1.0000000000E-9 Inexact Rounded +precision: 12 -- Etiny=-20 +pwsx806 power 10E-20 0.5 -> 3.1622776602E-10 Underflow Subnormal Inexact Rounded +pwsx807 power 1E-20 0.5 -> 1.0000000000E-10 Underflow Subnormal Inexact Rounded + +precision: 13 -- Etiny=-21 +pwsx808 power 1E-21 0.5 -> 3.1622776602E-11 Underflow Subnormal Inexact Rounded +pwsx809 power 10E-21 0.5 -> 1.00000000000E-10 Underflow Subnormal Inexact Rounded +precision: 14 -- Etiny=-22 +pwsx810 power 1E-21 0.5 -> 3.16227766017E-11 Underflow Subnormal Inexact Rounded +pwsx811 power 10E-22 0.5 -> 3.16227766017E-11 Underflow Subnormal Inexact Rounded +pwsx812 power 1E-22 0.5 -> 1.00000000000E-11 Underflow Subnormal Inexact Rounded + + +-- special values +maxexponent: 999 +minexponent: -999 +pwsx820 power Inf 0.5 -> Infinity +pwsx821 power -Inf 0.5 -> NaN Invalid_operation +pwsx822 power NaN 0.5 -> NaN +pwsx823 power sNaN 0.5 -> NaN Invalid_operation +-- propagating NaNs +pwsx824 power sNaN123 0.5 -> NaN123 Invalid_operation +pwsx825 power -sNaN321 0.5 -> -NaN321 Invalid_operation +pwsx826 power NaN456 0.5 -> NaN456 +pwsx827 power -NaN654 0.5 -> -NaN654 +pwsx828 power NaN1 0.5 -> NaN1 + +-- Null test +pwsx900 power # 0.5 -> NaN Invalid_operation Modified: python/branches/release25-maint/Lib/test/decimaltestdata/quantize.decTest ============================================================================== --- python/branches/release25-maint/Lib/test/decimaltestdata/quantize.decTest (original) +++ python/branches/release25-maint/Lib/test/decimaltestdata/quantize.decTest Tue Jan 8 17:20:31 2008 @@ -1,6 +1,6 @@ ------------------------------------------------------------------------ -- quantize.decTest -- decimal quantize operation -- --- Copyright (c) IBM Corporation, 1981, 2004. All rights reserved. -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- ------------------------------------------------------------------------ -- Please see the document "General Decimal Arithmetic Testcases" -- -- at http://www2.hursley.ibm.com/decimal for the description of -- @@ -17,11 +17,12 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc at uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.39 +version: 2.57 -- Most of the tests here assume a "regular pattern", where the -- sign and coefficient are +1. -- 2004.03.15 Underflow for quantize is suppressed +-- 2005.06.08 More extensive tests for 'does not fit' extended: 1 precision: 9 @@ -123,10 +124,6 @@ quax124 quantize 1.05 1e-3 -> 1.050 quax125 quantize 1.05 1e-2 -> 1.05 quax126 quantize 1.05 1e-1 -> 1.1 Inexact Rounded -quax127 quantize 1.05 1e0 -> 1 Inexact Rounded -quax128 quantize 1.05 1e-3 -> 1.050 -quax129 quantize 1.05 1e-2 -> 1.05 -quax130 quantize 1.05 1e-1 -> 1.1 Inexact Rounded quax131 quantize 1.05 1e0 -> 1 Inexact Rounded quax132 quantize 1.06 1e-3 -> 1.060 quax133 quantize 1.06 1e-2 -> 1.06 @@ -435,6 +432,102 @@ quax472 quantize 9.999E-15 1e0 -> 0 Inexact Rounded quax473 quantize 9.999E-15 1e1 -> 0E+1 Inexact Rounded +precision: 7 +quax900 quantize 9.999E-15 1e-22 -> NaN Invalid_operation +quax901 quantize 9.999E-15 1e-21 -> 9.999000E-15 +quax902 quantize 9.999E-15 1e-20 -> 9.99900E-15 +quax903 quantize 9.999E-15 1e-19 -> 9.9990E-15 +quax904 quantize 9.999E-15 1e-18 -> 9.999E-15 +quax905 quantize 9.999E-15 1e-17 -> 1.000E-14 Inexact Rounded +quax906 quantize 9.999E-15 1e-16 -> 1.00E-14 Inexact Rounded +quax907 quantize 9.999E-15 1e-15 -> 1.0E-14 Inexact Rounded +quax908 quantize 9.999E-15 1e-14 -> 1E-14 Inexact Rounded +quax909 quantize 9.999E-15 1e-13 -> 0E-13 Inexact Rounded +quax910 quantize 9.999E-15 1e-12 -> 0E-12 Inexact Rounded +quax911 quantize 9.999E-15 1e-11 -> 0E-11 Inexact Rounded +quax912 quantize 9.999E-15 1e-10 -> 0E-10 Inexact Rounded +quax913 quantize 9.999E-15 1e-9 -> 0E-9 Inexact Rounded +quax914 quantize 9.999E-15 1e-8 -> 0E-8 Inexact Rounded +quax915 quantize 9.999E-15 1e-7 -> 0E-7 Inexact Rounded +quax916 quantize 9.999E-15 1e-6 -> 0.000000 Inexact Rounded +quax917 quantize 9.999E-15 1e-5 -> 0.00000 Inexact Rounded +quax918 quantize 9.999E-15 1e-4 -> 0.0000 Inexact Rounded +quax919 quantize 9.999E-15 1e-3 -> 0.000 Inexact Rounded +quax920 quantize 9.999E-15 1e-2 -> 0.00 Inexact Rounded +quax921 quantize 9.999E-15 1e-1 -> 0.0 Inexact Rounded +quax922 quantize 9.999E-15 1e0 -> 0 Inexact Rounded +quax923 quantize 9.999E-15 1e1 -> 0E+1 Inexact Rounded + +precision: 6 +quax930 quantize 9.999E-15 1e-22 -> NaN Invalid_operation +quax931 quantize 9.999E-15 1e-21 -> NaN Invalid_operation +quax932 quantize 9.999E-15 1e-20 -> 9.99900E-15 +quax933 quantize 9.999E-15 1e-19 -> 9.9990E-15 +quax934 quantize 9.999E-15 1e-18 -> 9.999E-15 +quax935 quantize 9.999E-15 1e-17 -> 1.000E-14 Inexact Rounded +quax936 quantize 9.999E-15 1e-16 -> 1.00E-14 Inexact Rounded +quax937 quantize 9.999E-15 1e-15 -> 1.0E-14 Inexact Rounded +quax938 quantize 9.999E-15 1e-14 -> 1E-14 Inexact Rounded +quax939 quantize 9.999E-15 1e-13 -> 0E-13 Inexact Rounded +quax940 quantize 9.999E-15 1e-12 -> 0E-12 Inexact Rounded +quax941 quantize 9.999E-15 1e-11 -> 0E-11 Inexact Rounded +quax942 quantize 9.999E-15 1e-10 -> 0E-10 Inexact Rounded +quax943 quantize 9.999E-15 1e-9 -> 0E-9 Inexact Rounded +quax944 quantize 9.999E-15 1e-8 -> 0E-8 Inexact Rounded +quax945 quantize 9.999E-15 1e-7 -> 0E-7 Inexact Rounded +quax946 quantize 9.999E-15 1e-6 -> 0.000000 Inexact Rounded +quax947 quantize 9.999E-15 1e-5 -> 0.00000 Inexact Rounded +quax948 quantize 9.999E-15 1e-4 -> 0.0000 Inexact Rounded +quax949 quantize 9.999E-15 1e-3 -> 0.000 Inexact Rounded +quax950 quantize 9.999E-15 1e-2 -> 0.00 Inexact Rounded +quax951 quantize 9.999E-15 1e-1 -> 0.0 Inexact Rounded +quax952 quantize 9.999E-15 1e0 -> 0 Inexact Rounded +quax953 quantize 9.999E-15 1e1 -> 0E+1 Inexact Rounded + +precision: 3 +quax960 quantize 9.999E-15 1e-22 -> NaN Invalid_operation +quax961 quantize 9.999E-15 1e-21 -> NaN Invalid_operation +quax962 quantize 9.999E-15 1e-20 -> NaN Invalid_operation +quax963 quantize 9.999E-15 1e-19 -> NaN Invalid_operation +quax964 quantize 9.999E-15 1e-18 -> NaN Invalid_operation +quax965 quantize 9.999E-15 1e-17 -> NaN Invalid_operation +quax966 quantize 9.999E-15 1e-16 -> 1.00E-14 Inexact Rounded +quax967 quantize 9.999E-15 1e-15 -> 1.0E-14 Inexact Rounded +quax968 quantize 9.999E-15 1e-14 -> 1E-14 Inexact Rounded +quax969 quantize 9.999E-15 1e-13 -> 0E-13 Inexact Rounded +quax970 quantize 9.999E-15 1e-12 -> 0E-12 Inexact Rounded +quax971 quantize 9.999E-15 1e-11 -> 0E-11 Inexact Rounded +quax972 quantize 9.999E-15 1e-10 -> 0E-10 Inexact Rounded +quax973 quantize 9.999E-15 1e-9 -> 0E-9 Inexact Rounded +quax974 quantize 9.999E-15 1e-8 -> 0E-8 Inexact Rounded +quax975 quantize 9.999E-15 1e-7 -> 0E-7 Inexact Rounded +quax976 quantize 9.999E-15 1e-6 -> 0.000000 Inexact Rounded +quax977 quantize 9.999E-15 1e-5 -> 0.00000 Inexact Rounded +quax978 quantize 9.999E-15 1e-4 -> 0.0000 Inexact Rounded +quax979 quantize 9.999E-15 1e-3 -> 0.000 Inexact Rounded +quax980 quantize 9.999E-15 1e-2 -> 0.00 Inexact Rounded +quax981 quantize 9.999E-15 1e-1 -> 0.0 Inexact Rounded +quax982 quantize 9.999E-15 1e0 -> 0 Inexact Rounded +quax983 quantize 9.999E-15 1e1 -> 0E+1 Inexact Rounded + +-- Fung Lee's case & similar +precision: 3 +quax1001 quantize 0.000 0.001 -> 0.000 +quax1002 quantize 0.001 0.001 -> 0.001 +quax1003 quantize 0.0012 0.001 -> 0.001 Inexact Rounded +quax1004 quantize 0.0018 0.001 -> 0.002 Inexact Rounded +quax1005 quantize 0.501 0.001 -> 0.501 +quax1006 quantize 0.5012 0.001 -> 0.501 Inexact Rounded +quax1007 quantize 0.5018 0.001 -> 0.502 Inexact Rounded +quax1008 quantize 0.999 0.001 -> 0.999 +quax1009 quantize 0.9992 0.001 -> 0.999 Inexact Rounded +quax1010 quantize 0.9998 0.001 -> NaN Invalid_operation +quax1011 quantize 1.0001 0.001 -> NaN Invalid_operation +quax1012 quantize 1.0051 0.001 -> NaN Invalid_operation +quax1013 quantize 1.0551 0.001 -> NaN Invalid_operation +quax1014 quantize 1.5551 0.001 -> NaN Invalid_operation +quax1015 quantize 1.9999 0.001 -> NaN Invalid_operation + -- long operand checks [rhs checks removed] maxexponent: 999 minexponent: -999 @@ -775,6 +868,81 @@ quax865 quantize 1 1e-2147483648 -> NaN Invalid_operation quax866 quantize 1 1e-2147483649 -> NaN Invalid_operation +-- More from Fung Lee +precision: 16 +rounding: half_up +maxExponent: 384 +minExponent: -383 +quax1021 quantize 8.666666666666000E+384 1.000000000000000E+384 -> 8.666666666666000E+384 +quax1022 quantize 64#8.666666666666000E+384 64#1.000000000000000E+384 -> 8.666666666666000E+384 +quax1023 quantize 64#8.666666666666000E+384 128#1.000000000000000E+384 -> 8.666666666666000E+384 +quax1024 quantize 64#8.666666666666000E+384 64#1E+384 -> 8.666666666666000E+384 +quax1025 quantize 64#8.666666666666000E+384 64#1E+384 -> 64#8.666666666666000E+384 +quax1026 quantize 64#8.666666666666000E+384 128#1E+384 -> 64#9E+384 Inexact Rounded Clamped +quax1027 quantize 64#8.666666666666000E+323 64#1E+31 -> NaN Invalid_operation +quax1028 quantize 64#8.666666666666000E+323 128#1E+31 -> NaN Invalid_operation +quax1029 quantize 64#8.66666666E+3 128#1E+10 -> 64#0E10 Inexact Rounded +quax1030 quantize 8.66666666E+3 1E+3 -> 9E+3 Inexact Rounded + +-- Int and uInt32 edge values for testing conversions +quax1040 quantize -2147483646 0 -> -2147483646 +quax1041 quantize -2147483647 0 -> -2147483647 +quax1042 quantize -2147483648 0 -> -2147483648 +quax1043 quantize -2147483649 0 -> -2147483649 +quax1044 quantize 2147483646 0 -> 2147483646 +quax1045 quantize 2147483647 0 -> 2147483647 +quax1046 quantize 2147483648 0 -> 2147483648 +quax1047 quantize 2147483649 0 -> 2147483649 +quax1048 quantize 4294967294 0 -> 4294967294 +quax1049 quantize 4294967295 0 -> 4294967295 +quax1050 quantize 4294967296 0 -> 4294967296 +quax1051 quantize 4294967297 0 -> 4294967297 +-- and powers of ten for same +quax1101 quantize 5000000000 0 -> 5000000000 +quax1102 quantize 4000000000 0 -> 4000000000 +quax1103 quantize 2000000000 0 -> 2000000000 +quax1104 quantize 1000000000 0 -> 1000000000 +quax1105 quantize 0100000000 0 -> 100000000 +quax1106 quantize 0010000000 0 -> 10000000 +quax1107 quantize 0001000000 0 -> 1000000 +quax1108 quantize 0000100000 0 -> 100000 +quax1109 quantize 0000010000 0 -> 10000 +quax1110 quantize 0000001000 0 -> 1000 +quax1111 quantize 0000000100 0 -> 100 +quax1112 quantize 0000000010 0 -> 10 +quax1113 quantize 0000000001 0 -> 1 +quax1114 quantize 0000000000 0 -> 0 +-- and powers of ten for same +quax1121 quantize -5000000000 0 -> -5000000000 +quax1122 quantize -4000000000 0 -> -4000000000 +quax1123 quantize -2000000000 0 -> -2000000000 +quax1124 quantize -1000000000 0 -> -1000000000 +quax1125 quantize -0100000000 0 -> -100000000 +quax1126 quantize -0010000000 0 -> -10000000 +quax1127 quantize -0001000000 0 -> -1000000 +quax1128 quantize -0000100000 0 -> -100000 +quax1129 quantize -0000010000 0 -> -10000 +quax1130 quantize -0000001000 0 -> -1000 +quax1131 quantize -0000000100 0 -> -100 +quax1132 quantize -0000000010 0 -> -10 +quax1133 quantize -0000000001 0 -> -1 +quax1134 quantize -0000000000 0 -> -0 + +-- Some miscellany +precision: 34 +rounding: half_up +maxExponent: 6144 +minExponent: -6143 +-- 1 2 3 +-- 1 234567890123456789012345678901234 +quax0a1 quantize 8.555555555555555555555555555555555E+6143 1E+6143 -> 9E+6143 Inexact Rounded +quax0a2 quantize 128#8.555555555555555555555555555555555E+6143 128#1E+6143 -> 8.55555555555555555555555555555556E+6143 Rounded Inexact +quax0a3 quantize 128#8.555555555555555555555555555555555E+6144 128#1E+6144 -> 8.555555555555555555555555555555555E+6144 + +-- payload decapitate +precision: 5 +quax62100 quantize 11 -sNaN1234567890 -> -NaN67890 Invalid_operation + -- Null tests -quax900 quantize 10 # -> NaN Invalid_operation -quax901 quantize # 1e10 -> NaN Invalid_operation +quax998 quantize 10 # -> NaN Invalid_operation +quax999 quantize # 1e10 -> NaN Invalid_operation Modified: python/branches/release25-maint/Lib/test/decimaltestdata/randomBound32.decTest ============================================================================== --- python/branches/release25-maint/Lib/test/decimaltestdata/randomBound32.decTest (original) +++ python/branches/release25-maint/Lib/test/decimaltestdata/randomBound32.decTest Tue Jan 8 17:20:31 2008 @@ -1,6 +1,6 @@ ------------------------------------------------------------------------ -- randomBound32.decTest -- decimal testcases -- boundaries near 32 -- --- Copyright (c) IBM Corporation, 1981, 2003. All rights reserved. -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- ------------------------------------------------------------------------ -- Please see the document "General Decimal Arithmetic Testcases" -- -- at http://www2.hursley.ibm.com/decimal for the description of -- @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc at uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.39 +version: 2.57 -- These testcases test calculations at precisions 31, 32, and 33, to -- exercise the boundaries around 2**5 @@ -90,7 +90,7 @@ divx3008 divide 75353574493.84484153484918212042 -8684111695095849922263044191221 -> -8.677177026223536475531592432118E-21 Inexact Rounded dvix3008 divideint 75353574493.84484153484918212042 -8684111695095849922263044191221 -> -0 mulx3008 multiply 75353574493.84484153484918212042 -8684111695095849922263044191221 -> -6.543788575292743281456830701127E+41 Inexact Rounded -powx3008 power 75353574493.84484153484918212042 -9 -> 1.276630670287906925570645490708E-98 Inexact Rounded +powx3008 power 75353574493.84484153484918212042 -9 -> 1.276630670287906925570645490707E-98 Inexact Rounded remx3008 remainder 75353574493.84484153484918212042 -8684111695095849922263044191221 -> 75353574493.84484153484918212042 subx3008 subtract 75353574493.84484153484918212042 -8684111695095849922263044191221 -> 8684111695095849922338397765715 Inexact Rounded addx3009 add 6907058.216435355874729592373011 2.857005446917670515662398741545 -> 6907061.073440802792400108035410 Inexact Rounded @@ -1040,7 +1040,7 @@ divx3226 divide 47.525676459351505682005359699680E+704 -58631943508436657383369760970210 -> -8.1057651538555854520994438038537E+673 Inexact Rounded dvix3226 divideint 47.525676459351505682005359699680E+704 -58631943508436657383369760970210 -> NaN Division_impossible mulx3226 multiply 47.525676459351505682005359699680E+704 -58631943508436657383369760970210 -> -2.7865227773649353769876975366506E+737 Inexact Rounded -powx3226 power 47.525676459351505682005359699680E+704 -6 -> 8.6782100393941226535150385475463E-4235 Inexact Rounded +powx3226 power 47.525676459351505682005359699680E+704 -6 -> 8.6782100393941226535150385475464E-4235 Inexact Rounded remx3226 remainder 47.525676459351505682005359699680E+704 -58631943508436657383369760970210 -> NaN Division_impossible subx3226 subtract 47.525676459351505682005359699680E+704 -58631943508436657383369760970210 -> 4.7525676459351505682005359699680E+705 Inexact Rounded addx3227 add -74396862273800.625679130772935550 -115616605.52826981284183992013157 -> -74396977890406.153948943614775470 Inexact Rounded Modified: python/branches/release25-maint/Lib/test/decimaltestdata/randoms.decTest ============================================================================== --- python/branches/release25-maint/Lib/test/decimaltestdata/randoms.decTest (original) +++ python/branches/release25-maint/Lib/test/decimaltestdata/randoms.decTest Tue Jan 8 17:20:31 2008 @@ -1,6 +1,6 @@ ------------------------------------------------------------------------ -- randoms.decTest -- decimal random testcases -- --- Copyright (c) IBM Corporation, 1981, 2003. All rights reserved. -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- ------------------------------------------------------------------------ -- Please see the document "General Decimal Arithmetic Testcases" -- -- at http://www2.hursley.ibm.com/decimal for the description of -- @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc at uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.39 +version: 2.57 extended: 1 maxexponent: 999999999 @@ -264,7 +264,7 @@ xdiv030 divide -225094.28 -88.7723542 -> 2535.63491 Inexact Rounded xdvi030 divideint -225094.28 -88.7723542 -> 2535 xmul030 multiply -225094.28 -88.7723542 -> 19982149.2 Inexact Rounded -xpow030 power -225094.28 -89 -> -4.36076964E-477 Inexact Rounded +xpow030 power -225094.28 -89 -> -4.36076965E-477 Inexact Rounded xrem030 remainder -225094.28 -88.7723542 -> -56.3621030 xsub030 subtract -225094.28 -88.7723542 -> -225005.508 Inexact Rounded xadd031 add 50.4442340 82.7952169E+880120759 -> 8.27952169E+880120760 Inexact Rounded @@ -295,7 +295,7 @@ xcom034 compare 592.142173E-419941416 -3.46079109E-844011845 -> 1 xdiv034 divide 592.142173E-419941416 -3.46079109E-844011845 -> -1.71100236E+424070431 Inexact Rounded xdvi034 divideint 592.142173E-419941416 -3.46079109E-844011845 -> NaN Division_impossible -xmul034 multiply 592.142173E-419941416 -3.46079109E-844011845 -> -0E-1000000007 Underflow Subnormal Inexact Rounded +xmul034 multiply 592.142173E-419941416 -3.46079109E-844011845 -> -0E-1000000007 Underflow Subnormal Inexact Rounded Clamped xpow034 power 592.142173E-419941416 -3 -> Infinity Overflow Inexact Rounded xrem034 remainder 592.142173E-419941416 -3.46079109E-844011845 -> NaN Division_impossible xsub034 subtract 592.142173E-419941416 -3.46079109E-844011845 -> 5.92142173E-419941414 Inexact Rounded @@ -487,7 +487,7 @@ xcom058 compare 151795163E-371727182 -488.09788E-738852245 -> 1 xdiv058 divide 151795163E-371727182 -488.09788E-738852245 -> -3.10993285E+367125068 Inexact Rounded xdvi058 divideint 151795163E-371727182 -488.09788E-738852245 -> NaN Division_impossible -xmul058 multiply 151795163E-371727182 -488.09788E-738852245 -> -0E-1000000007 Underflow Subnormal Inexact Rounded +xmul058 multiply 151795163E-371727182 -488.09788E-738852245 -> -0E-1000000007 Underflow Subnormal Inexact Rounded Clamped xpow058 power 151795163E-371727182 -5 -> Infinity Overflow Inexact Rounded xrem058 remainder 151795163E-371727182 -488.09788E-738852245 -> NaN Division_impossible xsub058 subtract 151795163E-371727182 -488.09788E-738852245 -> 1.51795163E-371727174 Inexact Rounded @@ -568,7 +568,7 @@ xdiv068 divide -12393257.2 76803689E+949125770 -> -1.61362786E-949125771 Inexact Rounded xdvi068 divideint -12393257.2 76803689E+949125770 -> -0 xmul068 multiply -12393257.2 76803689E+949125770 -> -9.51847872E+949125784 Inexact Rounded -xpow068 power -12393257.2 8 -> 5.56523750E+56 Inexact Rounded +xpow068 power -12393257.2 8 -> 5.56523749E+56 Inexact Rounded xrem068 remainder -12393257.2 76803689E+949125770 -> -12393257.2 xsub068 subtract -12393257.2 76803689E+949125770 -> -7.68036890E+949125777 Inexact Rounded xadd069 add -754771634.E+716555026 -292336.311 -> -7.54771634E+716555034 Inexact Rounded @@ -775,7 +775,7 @@ xcom094 compare -671.507198E-908587890 3057429.32E-555230623 -> -1 xdiv094 divide -671.507198E-908587890 3057429.32E-555230623 -> -2.19631307E-353357271 Inexact Rounded xdvi094 divideint -671.507198E-908587890 3057429.32E-555230623 -> -0 -xmul094 multiply -671.507198E-908587890 3057429.32E-555230623 -> -0E-1000000007 Underflow Subnormal Inexact Rounded +xmul094 multiply -671.507198E-908587890 3057429.32E-555230623 -> -0E-1000000007 Underflow Subnormal Inexact Rounded Clamped xpow094 power -671.507198E-908587890 3 -> -0E-1000000007 Underflow Subnormal Inexact Rounded Clamped xrem094 remainder -671.507198E-908587890 3057429.32E-555230623 -> -6.71507198E-908587888 xsub094 subtract -671.507198E-908587890 3057429.32E-555230623 -> -3.05742932E-555230617 Inexact Rounded @@ -856,7 +856,7 @@ xdiv104 divide 553527296. -7924.40185 -> -69850.9877 Inexact Rounded xdvi104 divideint 553527296. -7924.40185 -> -69850 xmul104 multiply 553527296. -7924.40185 -> -4.38637273E+12 Inexact Rounded -xpow104 power 553527296. -7924 -> 2.32397213E-69281 Inexact Rounded +xpow104 power 553527296. -7924 -> 2.32397214E-69281 Inexact Rounded xrem104 remainder 553527296. -7924.40185 -> 7826.77750 xsub104 subtract 553527296. -7924.40185 -> 553535220 Inexact Rounded xadd105 add -38.7465207 64936.2942 -> 64897.5477 Inexact Rounded @@ -919,7 +919,7 @@ xcom112 compare -51.1632090E-753968082 8.96207471E-585797887 -> -1 xdiv112 divide -51.1632090E-753968082 8.96207471E-585797887 -> -5.70885768E-168170195 Inexact Rounded xdvi112 divideint -51.1632090E-753968082 8.96207471E-585797887 -> -0 -xmul112 multiply -51.1632090E-753968082 8.96207471E-585797887 -> -0E-1000000007 Underflow Subnormal Inexact Rounded +xmul112 multiply -51.1632090E-753968082 8.96207471E-585797887 -> -0E-1000000007 Underflow Subnormal Inexact Rounded Clamped xpow112 power -51.1632090E-753968082 9 -> -0E-1000000007 Underflow Subnormal Inexact Rounded Clamped xrem112 remainder -51.1632090E-753968082 8.96207471E-585797887 -> -5.11632090E-753968081 xsub112 subtract -51.1632090E-753968082 8.96207471E-585797887 -> -8.96207471E-585797887 Inexact Rounded @@ -989,7 +989,7 @@ xsub120 subtract 14239029. -36527.2221 -> 14275556.2 Inexact Rounded xadd121 add 72333.2654E-544425548 -690.664836E+662155120 -> -6.90664836E+662155122 Inexact Rounded xcom121 compare 72333.2654E-544425548 -690.664836E+662155120 -> 1 -xdiv121 divide 72333.2654E-544425548 -690.664836E+662155120 -> -0E-1000000007 Inexact Rounded Underflow Subnormal +xdiv121 divide 72333.2654E-544425548 -690.664836E+662155120 -> -0E-1000000007 Inexact Rounded Underflow Subnormal Clamped xdvi121 divideint 72333.2654E-544425548 -690.664836E+662155120 -> -0 xmul121 multiply 72333.2654E-544425548 -690.664836E+662155120 -> -4.99580429E+117729579 Inexact Rounded xpow121 power 72333.2654E-544425548 -7 -> Infinity Overflow Inexact Rounded @@ -1005,7 +1005,7 @@ xsub122 subtract -37721.1567E-115787341 -828949864E-76251747 -> 8.28949864E-76251739 Inexact Rounded xadd123 add -2078852.83E-647080089 -119779858.E+734665461 -> -1.19779858E+734665469 Inexact Rounded xcom123 compare -2078852.83E-647080089 -119779858.E+734665461 -> 1 -xdiv123 divide -2078852.83E-647080089 -119779858.E+734665461 -> 0E-1000000007 Inexact Rounded Underflow Subnormal +xdiv123 divide -2078852.83E-647080089 -119779858.E+734665461 -> 0E-1000000007 Inexact Rounded Underflow Subnormal Clamped xdvi123 divideint -2078852.83E-647080089 -119779858.E+734665461 -> 0 xmul123 multiply -2078852.83E-647080089 -119779858.E+734665461 -> 2.49004697E+87585386 Inexact Rounded xpow123 power -2078852.83E-647080089 -1 -> -4.81034533E+647080082 Inexact Rounded @@ -1183,7 +1183,7 @@ xcom145 compare -477067757.E-961684940 7.70122608E-741072245 -> -1 xdiv145 divide -477067757.E-961684940 7.70122608E-741072245 -> -6.19469877E-220612688 Inexact Rounded xdvi145 divideint -477067757.E-961684940 7.70122608E-741072245 -> -0 -xmul145 multiply -477067757.E-961684940 7.70122608E-741072245 -> -0E-1000000007 Underflow Subnormal Inexact Rounded +xmul145 multiply -477067757.E-961684940 7.70122608E-741072245 -> -0E-1000000007 Underflow Subnormal Inexact Rounded Clamped xpow145 power -477067757.E-961684940 8 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped xrem145 remainder -477067757.E-961684940 7.70122608E-741072245 -> -4.77067757E-961684932 xsub145 subtract -477067757.E-961684940 7.70122608E-741072245 -> -7.70122608E-741072245 Inexact Rounded @@ -1296,7 +1296,7 @@ xdiv159 divide -18861647. 99794586.7 -> -0.189004711 Inexact Rounded xdvi159 divideint -18861647. 99794586.7 -> -0 xmul159 multiply -18861647. 99794586.7 -> -1.88229027E+15 Inexact Rounded -xpow159 power -18861647. 99794587 -> -4.28957460E+726063462 Inexact Rounded +xpow159 power -18861647. 99794587 -> -4.28957459E+726063462 Inexact Rounded xrem159 remainder -18861647. 99794586.7 -> -18861647.0 xsub159 subtract -18861647. 99794586.7 -> -118656234 Inexact Rounded xadd160 add 322192.407 461.67044 -> 322654.077 Inexact Rounded @@ -1519,7 +1519,7 @@ xcom187 compare -29.356551E-282816139 37141748E-903397821 -> -1 xdiv187 divide -29.356551E-282816139 37141748E-903397821 -> -7.90392283E+620581675 Inexact Rounded xdvi187 divideint -29.356551E-282816139 37141748E-903397821 -> NaN Division_impossible -xmul187 multiply -29.356551E-282816139 37141748E-903397821 -> -0E-1000000007 Underflow Subnormal Inexact Rounded +xmul187 multiply -29.356551E-282816139 37141748E-903397821 -> -0E-1000000007 Underflow Subnormal Inexact Rounded Clamped xpow187 power -29.356551E-282816139 4 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped xrem187 remainder -29.356551E-282816139 37141748E-903397821 -> NaN Division_impossible xsub187 subtract -29.356551E-282816139 37141748E-903397821 -> -2.93565510E-282816138 Inexact Rounded @@ -1760,7 +1760,7 @@ xdiv217 divide 7428219.97 667.326760 -> 11131.3084 Inexact Rounded xdvi217 divideint 7428219.97 667.326760 -> 11131 xmul217 multiply 7428219.97 667.326760 -> 4.95704997E+9 Inexact Rounded -xpow217 power 7428219.97 667 -> 7.58808510E+4582 Inexact Rounded +xpow217 power 7428219.97 667 -> 7.58808509E+4582 Inexact Rounded xrem217 remainder 7428219.97 667.326760 -> 205.804440 xsub217 subtract 7428219.97 667.326760 -> 7427552.64 Inexact Rounded xadd218 add -7291.19212 209.64966E-588526476 -> -7291.19212 Inexact Rounded @@ -2200,7 +2200,7 @@ xdiv272 divide 513115529. 27775075.6E+217133352 -> 1.84739562E-217133351 Inexact Rounded xdvi272 divideint 513115529. 27775075.6E+217133352 -> 0 xmul272 multiply 513115529. 27775075.6E+217133352 -> 1.42518226E+217133368 Inexact Rounded -xpow272 power 513115529. 3 -> 1.35096929E+26 Inexact Rounded +xpow272 power 513115529. 3 -> 1.35096928E+26 Inexact Rounded xrem272 remainder 513115529. 27775075.6E+217133352 -> 513115529 xsub272 subtract 513115529. 27775075.6E+217133352 -> -2.77750756E+217133359 Inexact Rounded xadd273 add -247157.208 -532990.453 -> -780147.661 @@ -2327,7 +2327,7 @@ xcom288 compare -4.18074650E-858746879 571035.277E-279409165 -> -1 xdiv288 divide -4.18074650E-858746879 571035.277E-279409165 -> -7.32134540E-579337720 Inexact Rounded xdvi288 divideint -4.18074650E-858746879 571035.277E-279409165 -> -0 -xmul288 multiply -4.18074650E-858746879 571035.277E-279409165 -> -0E-1000000007 Underflow Subnormal Inexact Rounded +xmul288 multiply -4.18074650E-858746879 571035.277E-279409165 -> -0E-1000000007 Underflow Subnormal Inexact Rounded Clamped xpow288 power -4.18074650E-858746879 6 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped xrem288 remainder -4.18074650E-858746879 571035.277E-279409165 -> -4.18074650E-858746879 xsub288 subtract -4.18074650E-858746879 571035.277E-279409165 -> -5.71035277E-279409160 Inexact Rounded @@ -2599,7 +2599,7 @@ xcom322 compare 82.4185291E-321919303 -215747737.E-995147400 -> 1 xdiv322 divide 82.4185291E-321919303 -215747737.E-995147400 -> -3.82013412E+673228090 Inexact Rounded xdvi322 divideint 82.4185291E-321919303 -215747737.E-995147400 -> NaN Division_impossible -xmul322 multiply 82.4185291E-321919303 -215747737.E-995147400 -> -0E-1000000007 Underflow Subnormal Inexact Rounded +xmul322 multiply 82.4185291E-321919303 -215747737.E-995147400 -> -0E-1000000007 Underflow Subnormal Inexact Rounded Clamped xpow322 power 82.4185291E-321919303 -2 -> 1.47214396E+643838602 Inexact Rounded xrem322 remainder 82.4185291E-321919303 -215747737.E-995147400 -> NaN Division_impossible xsub322 subtract 82.4185291E-321919303 -215747737.E-995147400 -> 8.24185291E-321919302 Inexact Rounded @@ -2640,7 +2640,7 @@ xdiv327 divide 2512953.3 -3769170.35E-993621645 -> -6.66712583E+993621644 Inexact Rounded xdvi327 divideint 2512953.3 -3769170.35E-993621645 -> NaN Division_impossible xmul327 multiply 2512953.3 -3769170.35E-993621645 -> -9.47174907E-993621633 Inexact Rounded -xpow327 power 2512953.3 -4 -> 2.50762349E-26 Inexact Rounded +xpow327 power 2512953.3 -4 -> 2.50762348E-26 Inexact Rounded xrem327 remainder 2512953.3 -3769170.35E-993621645 -> NaN Division_impossible xsub327 subtract 2512953.3 -3769170.35E-993621645 -> 2512953.30 Inexact Rounded xadd328 add -682.796370 71131.0224 -> 70448.2260 Inexact Rounded @@ -2656,7 +2656,7 @@ xdiv329 divide 89.9997490 -4993.69831 -> -0.0180226644 Inexact Rounded xdvi329 divideint 89.9997490 -4993.69831 -> -0 xmul329 multiply 89.9997490 -4993.69831 -> -449431.594 Inexact Rounded -xpow329 power 89.9997490 -4994 -> 3.30336526E-9760 Inexact Rounded +xpow329 power 89.9997490 -4994 -> 3.30336525E-9760 Inexact Rounded xrem329 remainder 89.9997490 -4993.69831 -> 89.9997490 xsub329 subtract 89.9997490 -4993.69831 -> 5083.69806 Inexact Rounded xadd330 add 76563354.6E-112338836 278271.585E-511481095 -> 7.65633546E-112338829 Inexact Rounded @@ -2821,7 +2821,7 @@ xsub349 subtract -4037911.02E+641367645 29.5713010 -> -4.03791102E+641367651 Inexact Rounded xadd350 add -688755561.E-95301699 978.275312E+913812609 -> 9.78275312E+913812611 Inexact Rounded xcom350 compare -688755561.E-95301699 978.275312E+913812609 -> -1 -xdiv350 divide -688755561.E-95301699 978.275312E+913812609 -> -0E-1000000007 Inexact Rounded Underflow Subnormal +xdiv350 divide -688755561.E-95301699 978.275312E+913812609 -> -0E-1000000007 Inexact Rounded Underflow Subnormal Clamped xdvi350 divideint -688755561.E-95301699 978.275312E+913812609 -> -0 xmul350 multiply -688755561.E-95301699 978.275312E+913812609 -> -6.73792561E+818510921 Inexact Rounded xpow350 power -688755561.E-95301699 10 -> 2.40243244E-953016902 Inexact Rounded @@ -3024,7 +3024,7 @@ xdiv375 divide -5549320.1 -93580684.1 -> 0.0592998454 Inexact Rounded xdvi375 divideint -5549320.1 -93580684.1 -> 0 xmul375 multiply -5549320.1 -93580684.1 -> 5.19309171E+14 Inexact Rounded -xpow375 power -5549320.1 -93580684 -> 4.20662080E-631130572 Inexact Rounded +xpow375 power -5549320.1 -93580684 -> 4.20662079E-631130572 Inexact Rounded xrem375 remainder -5549320.1 -93580684.1 -> -5549320.1 xsub375 subtract -5549320.1 -93580684.1 -> 88031364.0 xadd376 add -14677053.1 -25784.7358 -> -14702837.8 Inexact Rounded @@ -3191,7 +3191,7 @@ xcom396 compare 4880.06442E-382222621 -115627239E-912834031 -> 1 xdiv396 divide 4880.06442E-382222621 -115627239E-912834031 -> -4.22051453E+530611405 Inexact Rounded xdvi396 divideint 4880.06442E-382222621 -115627239E-912834031 -> NaN Division_impossible -xmul396 multiply 4880.06442E-382222621 -115627239E-912834031 -> -0E-1000000007 Underflow Subnormal Inexact Rounded +xmul396 multiply 4880.06442E-382222621 -115627239E-912834031 -> -0E-1000000007 Underflow Subnormal Inexact Rounded Clamped xpow396 power 4880.06442E-382222621 -1 -> 2.04915328E+382222617 Inexact Rounded xrem396 remainder 4880.06442E-382222621 -115627239E-912834031 -> NaN Division_impossible xsub396 subtract 4880.06442E-382222621 -115627239E-912834031 -> 4.88006442E-382222618 Inexact Rounded @@ -3295,7 +3295,7 @@ xcom409 compare -54.3684171E-807210192 1.04592973E-984041807 -> -1 xdiv409 divide -54.3684171E-807210192 1.04592973E-984041807 -> -5.19809463E+176831616 Inexact Rounded xdvi409 divideint -54.3684171E-807210192 1.04592973E-984041807 -> NaN Division_impossible -xmul409 multiply -54.3684171E-807210192 1.04592973E-984041807 -> -0E-1000000007 Underflow Subnormal Inexact Rounded +xmul409 multiply -54.3684171E-807210192 1.04592973E-984041807 -> -0E-1000000007 Underflow Subnormal Inexact Rounded Clamped xpow409 power -54.3684171E-807210192 1 -> -5.43684171E-807210191 xrem409 remainder -54.3684171E-807210192 1.04592973E-984041807 -> NaN Division_impossible xsub409 subtract -54.3684171E-807210192 1.04592973E-984041807 -> -5.43684171E-807210191 Inexact Rounded @@ -3391,7 +3391,7 @@ xcom421 compare -4.09492571E-301749490 434.20199E-749390952 -> -1 xdiv421 divide -4.09492571E-301749490 434.20199E-749390952 -> -9.43092341E+447641459 Inexact Rounded xdvi421 divideint -4.09492571E-301749490 434.20199E-749390952 -> NaN Division_impossible -xmul421 multiply -4.09492571E-301749490 434.20199E-749390952 -> -0E-1000000007 Underflow Subnormal Inexact Rounded +xmul421 multiply -4.09492571E-301749490 434.20199E-749390952 -> -0E-1000000007 Underflow Subnormal Inexact Rounded Clamped xpow421 power -4.09492571E-301749490 4 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped xrem421 remainder -4.09492571E-301749490 434.20199E-749390952 -> NaN Division_impossible xsub421 subtract -4.09492571E-301749490 434.20199E-749390952 -> -4.09492571E-301749490 Inexact Rounded @@ -3423,7 +3423,7 @@ xcom425 compare 6.88891136E-935467395 -785049.562E-741671442 -> 1 xdiv425 divide 6.88891136E-935467395 -785049.562E-741671442 -> -8.77512923E-193795959 Inexact Rounded xdvi425 divideint 6.88891136E-935467395 -785049.562E-741671442 -> -0 -xmul425 multiply 6.88891136E-935467395 -785049.562E-741671442 -> -0E-1000000007 Underflow Subnormal Inexact Rounded +xmul425 multiply 6.88891136E-935467395 -785049.562E-741671442 -> -0E-1000000007 Underflow Subnormal Inexact Rounded Clamped xpow425 power 6.88891136E-935467395 -8 -> Infinity Overflow Inexact Rounded xrem425 remainder 6.88891136E-935467395 -785049.562E-741671442 -> 6.88891136E-935467395 xsub425 subtract 6.88891136E-935467395 -785049.562E-741671442 -> 7.85049562E-741671437 Inexact Rounded @@ -3535,7 +3535,7 @@ xcom439 compare 971113.655E-695540249 -419351120E-977743823 -> 1 xdiv439 divide 971113.655E-695540249 -419351120E-977743823 -> -2.31575310E+282203571 Inexact Rounded xdvi439 divideint 971113.655E-695540249 -419351120E-977743823 -> NaN Division_impossible -xmul439 multiply 971113.655E-695540249 -419351120E-977743823 -> -0E-1000000007 Underflow Subnormal Inexact Rounded +xmul439 multiply 971113.655E-695540249 -419351120E-977743823 -> -0E-1000000007 Underflow Subnormal Inexact Rounded Clamped xpow439 power 971113.655E-695540249 -4 -> Infinity Overflow Inexact Rounded xrem439 remainder 971113.655E-695540249 -419351120E-977743823 -> NaN Division_impossible xsub439 subtract 971113.655E-695540249 -419351120E-977743823 -> 9.71113655E-695540244 Inexact Rounded @@ -3600,7 +3600,7 @@ xdiv447 divide -9.95836312 -866466703 -> 1.14930707E-8 Inexact Rounded xdvi447 divideint -9.95836312 -866466703 -> 0 xmul447 multiply -9.95836312 -866466703 -> 8.62859006E+9 Inexact Rounded -xpow447 power -9.95836312 -866466703 -> -6.71744368E-864896630 Inexact Rounded +xpow447 power -9.95836312 -866466703 -> -6.71744369E-864896630 Inexact Rounded xrem447 remainder -9.95836312 -866466703 -> -9.95836312 xsub447 subtract -9.95836312 -866466703 -> 866466693 Inexact Rounded xadd448 add 80919339.2E-967231586 219.824266 -> 219.824266 Inexact Rounded @@ -3616,7 +3616,7 @@ xdiv449 divide 159579.444 -89827.5229 -> -1.77650946 Inexact Rounded xdvi449 divideint 159579.444 -89827.5229 -> -1 xmul449 multiply 159579.444 -89827.5229 -> -1.43346262E+10 Inexact Rounded -xpow449 power 159579.444 -89828 -> 9.69955849E-467374 Inexact Rounded +xpow449 power 159579.444 -89828 -> 9.69955850E-467374 Inexact Rounded xrem449 remainder 159579.444 -89827.5229 -> 69751.9211 xsub449 subtract 159579.444 -89827.5229 -> 249406.967 Inexact Rounded xadd450 add -4.54000153 6966333.74 -> 6966329.20 Inexact Rounded @@ -3640,7 +3640,7 @@ xdiv452 divide -361382575. -7976.15286E+898491169 -> 4.53078798E-898491165 Inexact Rounded xdvi452 divideint -361382575. -7976.15286E+898491169 -> 0 xmul452 multiply -361382575. -7976.15286E+898491169 -> 2.88244266E+898491181 Inexact Rounded -xpow452 power -361382575. -8 -> 3.43765536E-69 Inexact Rounded +xpow452 power -361382575. -8 -> 3.43765537E-69 Inexact Rounded xrem452 remainder -361382575. -7976.15286E+898491169 -> -361382575 xsub452 subtract -361382575. -7976.15286E+898491169 -> 7.97615286E+898491172 Inexact Rounded xadd453 add 7021805.61 1222952.83 -> 8244758.44 @@ -3720,7 +3720,7 @@ xdiv462 divide -51592.2698 -713885.741 -> 0.0722696460 Inexact Rounded xdvi462 divideint -51592.2698 -713885.741 -> 0 xmul462 multiply -51592.2698 -713885.741 -> 3.68309858E+10 Inexact Rounded -xpow462 power -51592.2698 -713886 -> 6.38576921E-3364249 Inexact Rounded +xpow462 power -51592.2698 -713886 -> 6.38576920E-3364249 Inexact Rounded xrem462 remainder -51592.2698 -713885.741 -> -51592.2698 xsub462 subtract -51592.2698 -713885.741 -> 662293.471 Inexact Rounded xadd463 add 51.2279848E+80439745 207.55925E+865165070 -> 2.07559250E+865165072 Inexact Rounded @@ -3768,7 +3768,7 @@ xdiv468 divide -5.32711606 -8447286.21 -> 6.30630468E-7 Inexact Rounded xdvi468 divideint -5.32711606 -8447286.21 -> 0 xmul468 multiply -5.32711606 -8447286.21 -> 44999674.0 Inexact Rounded -xpow468 power -5.32711606 -8447286 -> 9.09138729E-6136888 Inexact Rounded +xpow468 power -5.32711606 -8447286 -> 9.09138728E-6136888 Inexact Rounded xrem468 remainder -5.32711606 -8447286.21 -> -5.32711606 xsub468 subtract -5.32711606 -8447286.21 -> 8447280.88 Inexact Rounded xadd469 add -82272171.8 -776.238587E-372690416 -> -82272171.8 Inexact Rounded @@ -4027,3 +4027,4 @@ xpow500 power -525445087.E+231529167 188227460 -> Infinity Overflow Inexact Rounded xrem500 remainder -525445087.E+231529167 188227460 -> NaN Division_impossible xsub500 subtract -525445087.E+231529167 188227460 -> -5.25445087E+231529175 Inexact Rounded + Added: python/branches/release25-maint/Lib/test/decimaltestdata/reduce.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/reduce.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,234 @@ +------------------------------------------------------------------------ +-- reduce.decTest -- remove trailing zeros -- +-- Copyright (c) IBM Corporation, 2003, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +-- [This used to be called normalize.] + +version: 2.57 + +extended: 1 +precision: 9 +rounding: half_up +maxExponent: 999 +minexponent: -999 + +redx001 reduce '1' -> '1' +redx002 reduce '-1' -> '-1' +redx003 reduce '1.00' -> '1' +redx004 reduce '-1.00' -> '-1' +redx005 reduce '0' -> '0' +redx006 reduce '0.00' -> '0' +redx007 reduce '00.0' -> '0' +redx008 reduce '00.00' -> '0' +redx009 reduce '00' -> '0' +redx010 reduce '0E+1' -> '0' +redx011 reduce '0E+5' -> '0' + +redx012 reduce '-2' -> '-2' +redx013 reduce '2' -> '2' +redx014 reduce '-2.00' -> '-2' +redx015 reduce '2.00' -> '2' +redx016 reduce '-0' -> '-0' +redx017 reduce '-0.00' -> '-0' +redx018 reduce '-00.0' -> '-0' +redx019 reduce '-00.00' -> '-0' +redx020 reduce '-00' -> '-0' +redx021 reduce '-0E+5' -> '-0' +redx022 reduce '-0E+1' -> '-0' + +redx030 reduce '+0.1' -> '0.1' +redx031 reduce '-0.1' -> '-0.1' +redx032 reduce '+0.01' -> '0.01' +redx033 reduce '-0.01' -> '-0.01' +redx034 reduce '+0.001' -> '0.001' +redx035 reduce '-0.001' -> '-0.001' +redx036 reduce '+0.000001' -> '0.000001' +redx037 reduce '-0.000001' -> '-0.000001' +redx038 reduce '+0.000000000001' -> '1E-12' +redx039 reduce '-0.000000000001' -> '-1E-12' + +redx041 reduce 1.1 -> 1.1 +redx042 reduce 1.10 -> 1.1 +redx043 reduce 1.100 -> 1.1 +redx044 reduce 1.110 -> 1.11 +redx045 reduce -1.1 -> -1.1 +redx046 reduce -1.10 -> -1.1 +redx047 reduce -1.100 -> -1.1 +redx048 reduce -1.110 -> -1.11 +redx049 reduce 9.9 -> 9.9 +redx050 reduce 9.90 -> 9.9 +redx051 reduce 9.900 -> 9.9 +redx052 reduce 9.990 -> 9.99 +redx053 reduce -9.9 -> -9.9 +redx054 reduce -9.90 -> -9.9 +redx055 reduce -9.900 -> -9.9 +redx056 reduce -9.990 -> -9.99 + +-- some trailing fractional zeros with zeros in units +redx060 reduce 10.0 -> 1E+1 +redx061 reduce 10.00 -> 1E+1 +redx062 reduce 100.0 -> 1E+2 +redx063 reduce 100.00 -> 1E+2 +redx064 reduce 1.1000E+3 -> 1.1E+3 +redx065 reduce 1.10000E+3 -> 1.1E+3 +redx066 reduce -10.0 -> -1E+1 +redx067 reduce -10.00 -> -1E+1 +redx068 reduce -100.0 -> -1E+2 +redx069 reduce -100.00 -> -1E+2 +redx070 reduce -1.1000E+3 -> -1.1E+3 +redx071 reduce -1.10000E+3 -> -1.1E+3 + +-- some insignificant trailing zeros with positive exponent +redx080 reduce 10E+1 -> 1E+2 +redx081 reduce 100E+1 -> 1E+3 +redx082 reduce 1.0E+2 -> 1E+2 +redx083 reduce 1.0E+3 -> 1E+3 +redx084 reduce 1.1E+3 -> 1.1E+3 +redx085 reduce 1.00E+3 -> 1E+3 +redx086 reduce 1.10E+3 -> 1.1E+3 +redx087 reduce -10E+1 -> -1E+2 +redx088 reduce -100E+1 -> -1E+3 +redx089 reduce -1.0E+2 -> -1E+2 +redx090 reduce -1.0E+3 -> -1E+3 +redx091 reduce -1.1E+3 -> -1.1E+3 +redx092 reduce -1.00E+3 -> -1E+3 +redx093 reduce -1.10E+3 -> -1.1E+3 + +-- some significant trailing zeros, were we to be trimming +redx100 reduce 11 -> 11 +redx101 reduce 10 -> 1E+1 +redx102 reduce 10. -> 1E+1 +redx103 reduce 1.1E+1 -> 11 +redx104 reduce 1.0E+1 -> 1E+1 +redx105 reduce 1.10E+2 -> 1.1E+2 +redx106 reduce 1.00E+2 -> 1E+2 +redx107 reduce 1.100E+3 -> 1.1E+3 +redx108 reduce 1.000E+3 -> 1E+3 +redx109 reduce 1.000000E+6 -> 1E+6 +redx110 reduce -11 -> -11 +redx111 reduce -10 -> -1E+1 +redx112 reduce -10. -> -1E+1 +redx113 reduce -1.1E+1 -> -11 +redx114 reduce -1.0E+1 -> -1E+1 +redx115 reduce -1.10E+2 -> -1.1E+2 +redx116 reduce -1.00E+2 -> -1E+2 +redx117 reduce -1.100E+3 -> -1.1E+3 +redx118 reduce -1.000E+3 -> -1E+3 +redx119 reduce -1.00000E+5 -> -1E+5 +redx120 reduce -1.000000E+6 -> -1E+6 +redx121 reduce -10.00000E+6 -> -1E+7 +redx122 reduce -100.0000E+6 -> -1E+8 +redx123 reduce -1000.000E+6 -> -1E+9 +redx124 reduce -10000.00E+6 -> -1E+10 +redx125 reduce -100000.0E+6 -> -1E+11 +redx126 reduce -1000000.E+6 -> -1E+12 + +-- examples from decArith +redx140 reduce '2.1' -> '2.1' +redx141 reduce '-2.0' -> '-2' +redx142 reduce '1.200' -> '1.2' +redx143 reduce '-120' -> '-1.2E+2' +redx144 reduce '120.00' -> '1.2E+2' +redx145 reduce '0.00' -> '0' + +-- overflow tests +maxexponent: 999999999 +minexponent: -999999999 +precision: 3 +redx160 reduce 9.999E+999999999 -> Infinity Inexact Overflow Rounded +redx161 reduce -9.999E+999999999 -> -Infinity Inexact Overflow Rounded + +-- subnormals and underflow +precision: 3 +maxexponent: 999 +minexponent: -999 +redx210 reduce 1.00E-999 -> 1E-999 +redx211 reduce 0.1E-999 -> 1E-1000 Subnormal +redx212 reduce 0.10E-999 -> 1E-1000 Subnormal +redx213 reduce 0.100E-999 -> 1E-1000 Subnormal Rounded +redx214 reduce 0.01E-999 -> 1E-1001 Subnormal +-- next is rounded to Emin +redx215 reduce 0.999E-999 -> 1E-999 Inexact Rounded Subnormal Underflow +redx216 reduce 0.099E-999 -> 1E-1000 Inexact Rounded Subnormal Underflow +redx217 reduce 0.009E-999 -> 1E-1001 Inexact Rounded Subnormal Underflow +redx218 reduce 0.001E-999 -> 0 Inexact Rounded Subnormal Underflow Clamped +redx219 reduce 0.0009E-999 -> 0 Inexact Rounded Subnormal Underflow Clamped +redx220 reduce 0.0001E-999 -> 0 Inexact Rounded Subnormal Underflow Clamped + +redx230 reduce -1.00E-999 -> -1E-999 +redx231 reduce -0.1E-999 -> -1E-1000 Subnormal +redx232 reduce -0.10E-999 -> -1E-1000 Subnormal +redx233 reduce -0.100E-999 -> -1E-1000 Subnormal Rounded +redx234 reduce -0.01E-999 -> -1E-1001 Subnormal +-- next is rounded to Emin +redx235 reduce -0.999E-999 -> -1E-999 Inexact Rounded Subnormal Underflow +redx236 reduce -0.099E-999 -> -1E-1000 Inexact Rounded Subnormal Underflow +redx237 reduce -0.009E-999 -> -1E-1001 Inexact Rounded Subnormal Underflow +redx238 reduce -0.001E-999 -> -0 Inexact Rounded Subnormal Underflow Clamped +redx239 reduce -0.0009E-999 -> -0 Inexact Rounded Subnormal Underflow Clamped +redx240 reduce -0.0001E-999 -> -0 Inexact Rounded Subnormal Underflow Clamped + +-- more reshaping +precision: 9 +redx260 reduce '56260E-10' -> '0.000005626' +redx261 reduce '56260E-5' -> '0.5626' +redx262 reduce '56260E-2' -> '562.6' +redx263 reduce '56260E-1' -> '5626' +redx265 reduce '56260E-0' -> '5.626E+4' +redx266 reduce '56260E+0' -> '5.626E+4' +redx267 reduce '56260E+1' -> '5.626E+5' +redx268 reduce '56260E+2' -> '5.626E+6' +redx269 reduce '56260E+3' -> '5.626E+7' +redx270 reduce '56260E+4' -> '5.626E+8' +redx271 reduce '56260E+5' -> '5.626E+9' +redx272 reduce '56260E+6' -> '5.626E+10' +redx280 reduce '-56260E-10' -> '-0.000005626' +redx281 reduce '-56260E-5' -> '-0.5626' +redx282 reduce '-56260E-2' -> '-562.6' +redx283 reduce '-56260E-1' -> '-5626' +redx285 reduce '-56260E-0' -> '-5.626E+4' +redx286 reduce '-56260E+0' -> '-5.626E+4' +redx287 reduce '-56260E+1' -> '-5.626E+5' +redx288 reduce '-56260E+2' -> '-5.626E+6' +redx289 reduce '-56260E+3' -> '-5.626E+7' +redx290 reduce '-56260E+4' -> '-5.626E+8' +redx291 reduce '-56260E+5' -> '-5.626E+9' +redx292 reduce '-56260E+6' -> '-5.626E+10' + +-- FL test +precision: 40 +redx295 reduce 9892345673.0123456780000000000 -> 9892345673.012345678 + +-- specials +redx820 reduce 'Inf' -> 'Infinity' +redx821 reduce '-Inf' -> '-Infinity' +redx822 reduce NaN -> NaN +redx823 reduce sNaN -> NaN Invalid_operation +redx824 reduce NaN101 -> NaN101 +redx825 reduce sNaN010 -> NaN10 Invalid_operation +redx827 reduce -NaN -> -NaN +redx828 reduce -sNaN -> -NaN Invalid_operation +redx829 reduce -NaN101 -> -NaN101 +redx830 reduce -sNaN010 -> -NaN10 Invalid_operation + +-- payload decapitate +precision: 5 +redx62100 reduce sNaN1234567890 -> NaN67890 Invalid_operation + +-- Null test +redx900 reduce # -> NaN Invalid_operation Modified: python/branches/release25-maint/Lib/test/decimaltestdata/remainder.decTest ============================================================================== --- python/branches/release25-maint/Lib/test/decimaltestdata/remainder.decTest (original) +++ python/branches/release25-maint/Lib/test/decimaltestdata/remainder.decTest Tue Jan 8 17:20:31 2008 @@ -1,6 +1,6 @@ ------------------------------------------------------------------------ -- remainder.decTest -- decimal remainder -- --- Copyright (c) IBM Corporation, 1981, 2004. All rights reserved. -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- ------------------------------------------------------------------------ -- Please see the document "General Decimal Arithmetic Testcases" -- -- at http://www2.hursley.ibm.com/decimal for the description of -- @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc at uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.39 +version: 2.57 extended: 1 precision: 9 @@ -351,6 +351,17 @@ remx408 remainder 0.55555555 1 -> 0.55555555 remx409 remainder 0.555555555 1 -> 0.555555555 +-- zero signs +remx650 remainder 1 1 -> 0 +remx651 remainder -1 1 -> -0 +remx652 remainder 1 -1 -> 0 +remx653 remainder -1 -1 -> -0 +remx654 remainder 0 1 -> 0 +remx655 remainder -0 1 -> -0 +remx656 remainder 0 -1 -> 0 +remx657 remainder -0 -1 -> -0 +remx658 remainder 0.00 1 -> 0.00 +remx659 remainder -0.00 1 -> -0.00 -- Specials remx680 remainder Inf -Inf -> NaN Invalid_operation Modified: python/branches/release25-maint/Lib/test/decimaltestdata/remainderNear.decTest ============================================================================== --- python/branches/release25-maint/Lib/test/decimaltestdata/remainderNear.decTest (original) +++ python/branches/release25-maint/Lib/test/decimaltestdata/remainderNear.decTest Tue Jan 8 17:20:31 2008 @@ -1,6 +1,6 @@ ------------------------------------------------------------------------ -- remainderNear.decTest -- decimal remainder-near (IEEE remainder) -- --- Copyright (c) IBM Corporation, 1981, 2004. All rights reserved. -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- ------------------------------------------------------------------------ -- Please see the document "General Decimal Arithmetic Testcases" -- -- at http://www2.hursley.ibm.com/decimal for the description of -- @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc at uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.39 +version: 2.57 extended: 1 precision: 9 @@ -413,6 +413,18 @@ rmnx606 remaindernear 31.5 3 -> 1.5 -- i=10 rmnx607 remaindernear 34.5 3 -> -1.5 -- i=11 +-- zero signs +rmnx650 remaindernear 1 1 -> 0 +rmnx651 remaindernear -1 1 -> -0 +rmnx652 remaindernear 1 -1 -> 0 +rmnx653 remaindernear -1 -1 -> -0 +rmnx654 remaindernear 0 1 -> 0 +rmnx655 remaindernear -0 1 -> -0 +rmnx656 remaindernear 0 -1 -> 0 +rmnx657 remaindernear -0 -1 -> -0 +rmnx658 remaindernear 0.00 1 -> 0.00 +rmnx659 remaindernear -0.00 1 -> -0.00 + -- Specials rmnx680 remaindernear Inf -Inf -> NaN Invalid_operation rmnx681 remaindernear Inf -1000 -> NaN Invalid_operation Modified: python/branches/release25-maint/Lib/test/decimaltestdata/rescale.decTest ============================================================================== --- python/branches/release25-maint/Lib/test/decimaltestdata/rescale.decTest (original) +++ python/branches/release25-maint/Lib/test/decimaltestdata/rescale.decTest Tue Jan 8 17:20:31 2008 @@ -1,6 +1,6 @@ ------------------------------------------------------------------------ -- rescale.decTest -- decimal rescale operation -- --- Copyright (c) IBM Corporation, 1981, 2004. All rights reserved. -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- ------------------------------------------------------------------------ -- Please see the document "General Decimal Arithmetic Testcases" -- -- at http://www2.hursley.ibm.com/decimal for the description of -- @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc at uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.39 +version: 2.57 -- [obsolete] Quantize.decTest has the improved version @@ -379,7 +379,7 @@ resx446 rescale 0.000999 1 -> 0E+1 Inexact Rounded precision: 8 -resx449 rescale 9.999E-15 -23 -> NaN Invalid_operation +resx449 rescale 9.999E-15 -23 -> NaN Invalid_operation resx450 rescale 9.999E-15 -22 -> 9.9990000E-15 resx451 rescale 9.999E-15 -21 -> 9.999000E-15 resx452 rescale 9.999E-15 -20 -> 9.99900E-15 @@ -405,6 +405,12 @@ resx472 rescale 9.999E-15 0 -> 0 Inexact Rounded resx473 rescale 9.999E-15 1 -> 0E+1 Inexact Rounded +-- [additional tests for "don't fit" edge cases are in +-- quantize.decTest. Here's a critical one.] +precision: 3 +resx480 rescale 0.9999 -3 -> NaN Invalid_operation + + -- long operand checks [rhs checks removed] maxexponent: 999 minexponent: -999 Added: python/branches/release25-maint/Lib/test/decimaltestdata/rotate.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/rotate.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,247 @@ +------------------------------------------------------------------------ +-- rotate.decTest -- rotate coefficient left or right -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +extended: 1 +precision: 9 +rounding: half_up +maxExponent: 999 +minExponent: -999 + +-- Sanity check +rotx001 rotate 0 0 -> 0 +rotx002 rotate 0 2 -> 0 +rotx003 rotate 1 2 -> 100 +rotx004 rotate 34 8 -> 400000003 +rotx005 rotate 1 9 -> 1 +rotx006 rotate 1 -1 -> 100000000 +rotx007 rotate 123456789 -1 -> 912345678 +rotx008 rotate 123456789 -8 -> 234567891 +rotx009 rotate 123456789 -9 -> 123456789 +rotx010 rotate 0 -2 -> 0 + +-- rhs must be an integer +rotx011 rotate 1 1.5 -> NaN Invalid_operation +rotx012 rotate 1 1.0 -> NaN Invalid_operation +rotx013 rotate 1 0.1 -> NaN Invalid_operation +rotx014 rotate 1 0.0 -> NaN Invalid_operation +rotx015 rotate 1 1E+1 -> NaN Invalid_operation +rotx016 rotate 1 1E+99 -> NaN Invalid_operation +rotx017 rotate 1 Inf -> NaN Invalid_operation +rotx018 rotate 1 -Inf -> NaN Invalid_operation +-- and |rhs| <= precision +rotx020 rotate 1 -1000 -> NaN Invalid_operation +rotx021 rotate 1 -10 -> NaN Invalid_operation +rotx022 rotate 1 10 -> NaN Invalid_operation +rotx023 rotate 1 1000 -> NaN Invalid_operation + +-- full pattern +rotx030 rotate 123456789 -9 -> 123456789 +rotx031 rotate 123456789 -8 -> 234567891 +rotx032 rotate 123456789 -7 -> 345678912 +rotx033 rotate 123456789 -6 -> 456789123 +rotx034 rotate 123456789 -5 -> 567891234 +rotx035 rotate 123456789 -4 -> 678912345 +rotx036 rotate 123456789 -3 -> 789123456 +rotx037 rotate 123456789 -2 -> 891234567 +rotx038 rotate 123456789 -1 -> 912345678 +rotx039 rotate 123456789 -0 -> 123456789 +rotx040 rotate 123456789 +0 -> 123456789 +rotx041 rotate 123456789 +1 -> 234567891 +rotx042 rotate 123456789 +2 -> 345678912 +rotx043 rotate 123456789 +3 -> 456789123 +rotx044 rotate 123456789 +4 -> 567891234 +rotx045 rotate 123456789 +5 -> 678912345 +rotx046 rotate 123456789 +6 -> 789123456 +rotx047 rotate 123456789 +7 -> 891234567 +rotx048 rotate 123456789 +8 -> 912345678 +rotx049 rotate 123456789 +9 -> 123456789 + +-- zeros +rotx060 rotate 0E-10 +9 -> 0E-10 +rotx061 rotate 0E-10 -9 -> 0E-10 +rotx062 rotate 0.000 +9 -> 0.000 +rotx063 rotate 0.000 -9 -> 0.000 +rotx064 rotate 0E+10 +9 -> 0E+10 +rotx065 rotate 0E+10 -9 -> 0E+10 +rotx066 rotate -0E-10 +9 -> -0E-10 +rotx067 rotate -0E-10 -9 -> -0E-10 +rotx068 rotate -0.000 +9 -> -0.000 +rotx069 rotate -0.000 -9 -> -0.000 +rotx070 rotate -0E+10 +9 -> -0E+10 +rotx071 rotate -0E+10 -9 -> -0E+10 + +-- Nmax, Nmin, Ntiny +rotx141 rotate 9.99999999E+999 -1 -> 9.99999999E+999 +rotx142 rotate 9.99999999E+999 -8 -> 9.99999999E+999 +rotx143 rotate 9.99999999E+999 1 -> 9.99999999E+999 +rotx144 rotate 9.99999999E+999 8 -> 9.99999999E+999 +rotx145 rotate 1E-999 -1 -> 1.00000000E-991 +rotx146 rotate 1E-999 -8 -> 1.0E-998 +rotx147 rotate 1E-999 1 -> 1.0E-998 +rotx148 rotate 1E-999 8 -> 1.00000000E-991 +rotx151 rotate 1.00000000E-999 -1 -> 1.0000000E-1000 +rotx152 rotate 1.00000000E-999 -8 -> 1E-1007 +rotx153 rotate 1.00000000E-999 1 -> 1E-1007 +rotx154 rotate 1.00000000E-999 8 -> 1.0000000E-1000 +rotx155 rotate 9.00000000E-999 -1 -> 9.0000000E-1000 +rotx156 rotate 9.00000000E-999 -8 -> 9E-1007 +rotx157 rotate 9.00000000E-999 1 -> 9E-1007 +rotx158 rotate 9.00000000E-999 8 -> 9.0000000E-1000 +rotx160 rotate 1E-1007 -1 -> 1.00000000E-999 +rotx161 rotate 1E-1007 -8 -> 1.0E-1006 +rotx162 rotate 1E-1007 1 -> 1.0E-1006 +rotx163 rotate 1E-1007 8 -> 1.00000000E-999 +-- negatives +rotx171 rotate -9.99999999E+999 -1 -> -9.99999999E+999 +rotx172 rotate -9.99999999E+999 -8 -> -9.99999999E+999 +rotx173 rotate -9.99999999E+999 1 -> -9.99999999E+999 +rotx174 rotate -9.99999999E+999 8 -> -9.99999999E+999 +rotx175 rotate -1E-999 -1 -> -1.00000000E-991 +rotx176 rotate -1E-999 -8 -> -1.0E-998 +rotx177 rotate -1E-999 1 -> -1.0E-998 +rotx178 rotate -1E-999 8 -> -1.00000000E-991 +rotx181 rotate -1.00000000E-999 -1 -> -1.0000000E-1000 +rotx182 rotate -1.00000000E-999 -8 -> -1E-1007 +rotx183 rotate -1.00000000E-999 1 -> -1E-1007 +rotx184 rotate -1.00000000E-999 8 -> -1.0000000E-1000 +rotx185 rotate -9.00000000E-999 -1 -> -9.0000000E-1000 +rotx186 rotate -9.00000000E-999 -8 -> -9E-1007 +rotx187 rotate -9.00000000E-999 1 -> -9E-1007 +rotx188 rotate -9.00000000E-999 8 -> -9.0000000E-1000 +rotx190 rotate -1E-1007 -1 -> -1.00000000E-999 +rotx191 rotate -1E-1007 -8 -> -1.0E-1006 +rotx192 rotate -1E-1007 1 -> -1.0E-1006 +rotx193 rotate -1E-1007 8 -> -1.00000000E-999 + +-- more negatives (of sanities) +rotx201 rotate -0 0 -> -0 +rotx202 rotate -0 2 -> -0 +rotx203 rotate -1 2 -> -100 +rotx204 rotate -1 8 -> -100000000 +rotx205 rotate -1 9 -> -1 +rotx206 rotate -1 -1 -> -100000000 +rotx207 rotate -123456789 -1 -> -912345678 +rotx208 rotate -123456789 -8 -> -234567891 +rotx209 rotate -123456789 -9 -> -123456789 +rotx210 rotate -0 -2 -> -0 + +-- Specials; NaNs are handled as usual +rotx781 rotate -Inf -8 -> -Infinity +rotx782 rotate -Inf -1 -> -Infinity +rotx783 rotate -Inf -0 -> -Infinity +rotx784 rotate -Inf 0 -> -Infinity +rotx785 rotate -Inf 1 -> -Infinity +rotx786 rotate -Inf 8 -> -Infinity +rotx787 rotate -1000 -Inf -> NaN Invalid_operation +rotx788 rotate -Inf -Inf -> NaN Invalid_operation +rotx789 rotate -1 -Inf -> NaN Invalid_operation +rotx790 rotate -0 -Inf -> NaN Invalid_operation +rotx791 rotate 0 -Inf -> NaN Invalid_operation +rotx792 rotate 1 -Inf -> NaN Invalid_operation +rotx793 rotate 1000 -Inf -> NaN Invalid_operation +rotx794 rotate Inf -Inf -> NaN Invalid_operation + +rotx800 rotate Inf -Inf -> NaN Invalid_operation +rotx801 rotate Inf -8 -> Infinity +rotx802 rotate Inf -1 -> Infinity +rotx803 rotate Inf -0 -> Infinity +rotx804 rotate Inf 0 -> Infinity +rotx805 rotate Inf 1 -> Infinity +rotx806 rotate Inf 8 -> Infinity +rotx807 rotate Inf Inf -> NaN Invalid_operation +rotx808 rotate -1000 Inf -> NaN Invalid_operation +rotx809 rotate -Inf Inf -> NaN Invalid_operation +rotx810 rotate -1 Inf -> NaN Invalid_operation +rotx811 rotate -0 Inf -> NaN Invalid_operation +rotx812 rotate 0 Inf -> NaN Invalid_operation +rotx813 rotate 1 Inf -> NaN Invalid_operation +rotx814 rotate 1000 Inf -> NaN Invalid_operation +rotx815 rotate Inf Inf -> NaN Invalid_operation + +rotx821 rotate NaN -Inf -> NaN +rotx822 rotate NaN -1000 -> NaN +rotx823 rotate NaN -1 -> NaN +rotx824 rotate NaN -0 -> NaN +rotx825 rotate NaN 0 -> NaN +rotx826 rotate NaN 1 -> NaN +rotx827 rotate NaN 1000 -> NaN +rotx828 rotate NaN Inf -> NaN +rotx829 rotate NaN NaN -> NaN +rotx830 rotate -Inf NaN -> NaN +rotx831 rotate -1000 NaN -> NaN +rotx832 rotate -1 NaN -> NaN +rotx833 rotate -0 NaN -> NaN +rotx834 rotate 0 NaN -> NaN +rotx835 rotate 1 NaN -> NaN +rotx836 rotate 1000 NaN -> NaN +rotx837 rotate Inf NaN -> NaN + + + +rotx841 rotate sNaN -Inf -> NaN Invalid_operation +rotx842 rotate sNaN -1000 -> NaN Invalid_operation +rotx843 rotate sNaN -1 -> NaN Invalid_operation +rotx844 rotate sNaN -0 -> NaN Invalid_operation +rotx845 rotate sNaN 0 -> NaN Invalid_operation +rotx846 rotate sNaN 1 -> NaN Invalid_operation +rotx847 rotate sNaN 1000 -> NaN Invalid_operation +rotx848 rotate sNaN NaN -> NaN Invalid_operation +rotx849 rotate sNaN sNaN -> NaN Invalid_operation +rotx850 rotate NaN sNaN -> NaN Invalid_operation +rotx851 rotate -Inf sNaN -> NaN Invalid_operation +rotx852 rotate -1000 sNaN -> NaN Invalid_operation +rotx853 rotate -1 sNaN -> NaN Invalid_operation +rotx854 rotate -0 sNaN -> NaN Invalid_operation +rotx855 rotate 0 sNaN -> NaN Invalid_operation +rotx856 rotate 1 sNaN -> NaN Invalid_operation +rotx857 rotate 1000 sNaN -> NaN Invalid_operation +rotx858 rotate Inf sNaN -> NaN Invalid_operation +rotx859 rotate NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +rotx861 rotate NaN1 -Inf -> NaN1 +rotx862 rotate +NaN2 -1000 -> NaN2 +rotx863 rotate NaN3 1000 -> NaN3 +rotx864 rotate NaN4 Inf -> NaN4 +rotx865 rotate NaN5 +NaN6 -> NaN5 +rotx866 rotate -Inf NaN7 -> NaN7 +rotx867 rotate -1000 NaN8 -> NaN8 +rotx868 rotate 1000 NaN9 -> NaN9 +rotx869 rotate Inf +NaN10 -> NaN10 +rotx871 rotate sNaN11 -Inf -> NaN11 Invalid_operation +rotx872 rotate sNaN12 -1000 -> NaN12 Invalid_operation +rotx873 rotate sNaN13 1000 -> NaN13 Invalid_operation +rotx874 rotate sNaN14 NaN17 -> NaN14 Invalid_operation +rotx875 rotate sNaN15 sNaN18 -> NaN15 Invalid_operation +rotx876 rotate NaN16 sNaN19 -> NaN19 Invalid_operation +rotx877 rotate -Inf +sNaN20 -> NaN20 Invalid_operation +rotx878 rotate -1000 sNaN21 -> NaN21 Invalid_operation +rotx879 rotate 1000 sNaN22 -> NaN22 Invalid_operation +rotx880 rotate Inf sNaN23 -> NaN23 Invalid_operation +rotx881 rotate +NaN25 +sNaN24 -> NaN24 Invalid_operation +rotx882 rotate -NaN26 NaN28 -> -NaN26 +rotx883 rotate -sNaN27 sNaN29 -> -NaN27 Invalid_operation +rotx884 rotate 1000 -NaN30 -> -NaN30 +rotx885 rotate 1000 -sNaN31 -> -NaN31 Invalid_operation + +-- payload decapitate +precision: 5 +rotx886 rotate 11 -sNaN1234567890 -> -NaN67890 Invalid_operation Modified: python/branches/release25-maint/Lib/test/decimaltestdata/rounding.decTest ============================================================================== --- python/branches/release25-maint/Lib/test/decimaltestdata/rounding.decTest (original) +++ python/branches/release25-maint/Lib/test/decimaltestdata/rounding.decTest Tue Jan 8 17:20:31 2008 @@ -1,6 +1,6 @@ ------------------------------------------------------------------------ -- rounding.decTest -- decimal rounding modes testcases -- --- Copyright (c) IBM Corporation, 1981, 2003. All rights reserved. -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- ------------------------------------------------------------------------ -- Please see the document "General Decimal Arithmetic Testcases" -- -- at http://www2.hursley.ibm.com/decimal for the description of -- @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc at uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.39 +version: 2.57 -- These tests require that implementations take account of residues in -- order to get correct results for some rounding modes. Rather than @@ -26,8 +26,11 @@ -- is rounding of negatives (if the latter works for addition, assume it -- works for the others, too).] -- --- Underflow Subnormal and overflow behaviours are tested under the individual --- operators. +-- Round-for-reround (05UP) is tested as a separate block, mostly for +-- 'historical' reasons. +-- +-- Underflow Subnormal and overflow behaviours are tested under the +-- individual operators. extended: 1 precision: 5 -- for easier visual inspection @@ -980,8 +983,8 @@ rounding: down rovx100 multiply 10 9E+999999999 -> 9.9999E+999999999 Overflow Inexact Rounded rovx101 multiply -10 9E+999999999 -> -9.9999E+999999999 Overflow Inexact Rounded -rovx102 divide 1E-9 9E+999999999 -> 0E-1000000003 Underflow Subnormal Inexact Rounded -rovx104 divide -1E-9 9E+999999999 -> -0E-1000000003 Underflow Subnormal Inexact Rounded +rovx102 divide 1E-9 9E+999999999 -> 0E-1000000003 Underflow Subnormal Inexact Rounded Clamped +rovx104 divide -1E-9 9E+999999999 -> -0E-1000000003 Underflow Subnormal Inexact Rounded Clamped rounding: up rovx110 multiply 10 9E+999999999 -> Infinity Overflow Inexact Rounded @@ -993,31 +996,31 @@ rovx120 multiply 10 9E+999999999 -> Infinity Overflow Inexact Rounded rovx121 multiply -10 9E+999999999 -> -9.9999E+999999999 Overflow Inexact Rounded rovx122 divide 1E-9 9E+999999999 -> 1E-1000000003 Underflow Subnormal Inexact Rounded -rovx124 divide -1E-9 9E+999999999 -> -0E-1000000003 Underflow Subnormal Inexact Rounded +rovx124 divide -1E-9 9E+999999999 -> -0E-1000000003 Underflow Subnormal Inexact Rounded Clamped rounding: floor rovx130 multiply 10 9E+999999999 -> 9.9999E+999999999 Overflow Inexact Rounded rovx131 multiply -10 9E+999999999 -> -Infinity Overflow Inexact Rounded -rovx132 divide 1E-9 9E+999999999 -> 0E-1000000003 Underflow Subnormal Inexact Rounded +rovx132 divide 1E-9 9E+999999999 -> 0E-1000000003 Underflow Subnormal Inexact Rounded Clamped rovx134 divide -1E-9 9E+999999999 -> -1E-1000000003 Underflow Subnormal Inexact Rounded rounding: half_up rovx140 multiply 10 9E+999999999 -> Infinity Overflow Inexact Rounded rovx141 multiply -10 9E+999999999 -> -Infinity Overflow Inexact Rounded -rovx142 divide 1E-9 9E+999999999 -> 0E-1000000003 Underflow Subnormal Inexact Rounded -rovx144 divide -1E-9 9E+999999999 -> -0E-1000000003 Underflow Subnormal Inexact Rounded +rovx142 divide 1E-9 9E+999999999 -> 0E-1000000003 Underflow Subnormal Inexact Rounded Clamped +rovx144 divide -1E-9 9E+999999999 -> -0E-1000000003 Underflow Subnormal Inexact Rounded Clamped rounding: half_even rovx150 multiply 10 9E+999999999 -> Infinity Overflow Inexact Rounded rovx151 multiply -10 9E+999999999 -> -Infinity Overflow Inexact Rounded -rovx152 divide 1E-9 9E+999999999 -> 0E-1000000003 Underflow Subnormal Inexact Rounded -rovx154 divide -1E-9 9E+999999999 -> -0E-1000000003 Underflow Subnormal Inexact Rounded +rovx152 divide 1E-9 9E+999999999 -> 0E-1000000003 Underflow Subnormal Inexact Rounded Clamped +rovx154 divide -1E-9 9E+999999999 -> -0E-1000000003 Underflow Subnormal Inexact Rounded Clamped rounding: half_down rovx160 multiply 10 9E+999999999 -> Infinity Overflow Inexact Rounded rovx161 multiply -10 9E+999999999 -> -Infinity Overflow Inexact Rounded -rovx162 divide 1E-9 9E+999999999 -> 0E-1000000003 Underflow Subnormal Inexact Rounded -rovx164 divide -1E-9 9E+999999999 -> -0E-1000000003 Underflow Subnormal Inexact Rounded +rovx162 divide 1E-9 9E+999999999 -> 0E-1000000003 Underflow Subnormal Inexact Rounded Clamped +rovx164 divide -1E-9 9E+999999999 -> -0E-1000000003 Underflow Subnormal Inexact Rounded Clamped -- check maximum finite value over a range of precisions rounding: down @@ -1077,3 +1080,224 @@ rmex412 multiply -9.999E+999999999 10 -> -9.99999999E+999999999 Overflow Inexact Rounded rmex413 multiply 9.999E+999999999 10 -> 9.99999999E+999999999 Overflow Inexact Rounded +----- Round-for-reround ----- +rounding: 05up +precision: 5 -- for easier visual inspection +maxExponent: 999 +minexponent: -999 + +-- basic rounding; really is just 0 and 5 up +r05up001 add 12340 0.001 -> 12341 Inexact Rounded +r05up002 add 12341 0.001 -> 12341 Inexact Rounded +r05up003 add 12342 0.001 -> 12342 Inexact Rounded +r05up004 add 12343 0.001 -> 12343 Inexact Rounded +r05up005 add 12344 0.001 -> 12344 Inexact Rounded +r05up006 add 12345 0.001 -> 12346 Inexact Rounded +r05up007 add 12346 0.001 -> 12346 Inexact Rounded +r05up008 add 12347 0.001 -> 12347 Inexact Rounded +r05up009 add 12348 0.001 -> 12348 Inexact Rounded +r05up010 add 12349 0.001 -> 12349 Inexact Rounded + +r05up011 add 12340 0.000 -> 12340 Rounded +r05up012 add 12341 0.000 -> 12341 Rounded +r05up013 add 12342 0.000 -> 12342 Rounded +r05up014 add 12343 0.000 -> 12343 Rounded +r05up015 add 12344 0.000 -> 12344 Rounded +r05up016 add 12345 0.000 -> 12345 Rounded +r05up017 add 12346 0.000 -> 12346 Rounded +r05up018 add 12347 0.000 -> 12347 Rounded +r05up019 add 12348 0.000 -> 12348 Rounded +r05up020 add 12349 0.000 -> 12349 Rounded + +r05up021 add 12340 0.901 -> 12341 Inexact Rounded +r05up022 add 12341 0.901 -> 12341 Inexact Rounded +r05up023 add 12342 0.901 -> 12342 Inexact Rounded +r05up024 add 12343 0.901 -> 12343 Inexact Rounded +r05up025 add 12344 0.901 -> 12344 Inexact Rounded +r05up026 add 12345 0.901 -> 12346 Inexact Rounded +r05up027 add 12346 0.901 -> 12346 Inexact Rounded +r05up028 add 12347 0.901 -> 12347 Inexact Rounded +r05up029 add 12348 0.901 -> 12348 Inexact Rounded +r05up030 add 12349 0.901 -> 12349 Inexact Rounded + +r05up031 add -12340 -0.001 -> -12341 Inexact Rounded +r05up032 add -12341 -0.001 -> -12341 Inexact Rounded +r05up033 add -12342 -0.001 -> -12342 Inexact Rounded +r05up034 add -12343 -0.001 -> -12343 Inexact Rounded +r05up035 add -12344 -0.001 -> -12344 Inexact Rounded +r05up036 add -12345 -0.001 -> -12346 Inexact Rounded +r05up037 add -12346 -0.001 -> -12346 Inexact Rounded +r05up038 add -12347 -0.001 -> -12347 Inexact Rounded +r05up039 add -12348 -0.001 -> -12348 Inexact Rounded +r05up040 add -12349 -0.001 -> -12349 Inexact Rounded + +r05up041 add -12340 0.001 -> -12339 Inexact Rounded +r05up042 add -12341 0.001 -> -12341 Inexact Rounded +r05up043 add -12342 0.001 -> -12341 Inexact Rounded +r05up044 add -12343 0.001 -> -12342 Inexact Rounded +r05up045 add -12344 0.001 -> -12343 Inexact Rounded +r05up046 add -12345 0.001 -> -12344 Inexact Rounded +r05up047 add -12346 0.001 -> -12346 Inexact Rounded +r05up048 add -12347 0.001 -> -12346 Inexact Rounded +r05up049 add -12348 0.001 -> -12347 Inexact Rounded +r05up050 add -12349 0.001 -> -12348 Inexact Rounded + +-- Addition operators ------------------------------------------------- +-- [The first few of these check negative residue possibilities; these +-- cases may be implemented as a negative residue in fastpaths] + +r0adx100 add 12345 -0.1 -> 12344 Inexact Rounded +r0adx101 add 12345 -0.01 -> 12344 Inexact Rounded +r0adx102 add 12345 -0.001 -> 12344 Inexact Rounded +r0adx103 add 12345 -0.00001 -> 12344 Inexact Rounded +r0adx104 add 12345 -0.000001 -> 12344 Inexact Rounded +r0adx105 add 12345 -0.0000001 -> 12344 Inexact Rounded +r0adx106 add 12345 0 -> 12345 +r0adx107 add 12345 0.0000001 -> 12346 Inexact Rounded +r0adx108 add 12345 0.000001 -> 12346 Inexact Rounded +r0adx109 add 12345 0.00001 -> 12346 Inexact Rounded +r0adx110 add 12345 0.0001 -> 12346 Inexact Rounded +r0adx111 add 12345 0.001 -> 12346 Inexact Rounded +r0adx112 add 12345 0.01 -> 12346 Inexact Rounded +r0adx113 add 12345 0.1 -> 12346 Inexact Rounded + +r0adx115 add 12346 0.49999 -> 12346 Inexact Rounded +r0adx116 add 12346 0.5 -> 12346 Inexact Rounded +r0adx117 add 12346 0.50001 -> 12346 Inexact Rounded + +r0adx120 add 12345 0.4 -> 12346 Inexact Rounded +r0adx121 add 12345 0.49 -> 12346 Inexact Rounded +r0adx122 add 12345 0.499 -> 12346 Inexact Rounded +r0adx123 add 12345 0.49999 -> 12346 Inexact Rounded +r0adx124 add 12345 0.5 -> 12346 Inexact Rounded +r0adx125 add 12345 0.50001 -> 12346 Inexact Rounded +r0adx126 add 12345 0.5001 -> 12346 Inexact Rounded +r0adx127 add 12345 0.501 -> 12346 Inexact Rounded +r0adx128 add 12345 0.51 -> 12346 Inexact Rounded +r0adx129 add 12345 0.6 -> 12346 Inexact Rounded + +-- negatives... + +r0sux100 add -12345 -0.1 -> -12346 Inexact Rounded +r0sux101 add -12345 -0.01 -> -12346 Inexact Rounded +r0sux102 add -12345 -0.001 -> -12346 Inexact Rounded +r0sux103 add -12345 -0.00001 -> -12346 Inexact Rounded +r0sux104 add -12345 -0.000001 -> -12346 Inexact Rounded +r0sux105 add -12345 -0.0000001 -> -12346 Inexact Rounded +r0sux106 add -12345 0 -> -12345 +r0sux107 add -12345 0.0000001 -> -12344 Inexact Rounded +r0sux108 add -12345 0.000001 -> -12344 Inexact Rounded +r0sux109 add -12345 0.00001 -> -12344 Inexact Rounded +r0sux110 add -12345 0.0001 -> -12344 Inexact Rounded +r0sux111 add -12345 0.001 -> -12344 Inexact Rounded +r0sux112 add -12345 0.01 -> -12344 Inexact Rounded +r0sux113 add -12345 0.1 -> -12344 Inexact Rounded + +r0sux115 add -12346 0.49999 -> -12346 Inexact Rounded +r0sux116 add -12346 0.5 -> -12346 Inexact Rounded +r0sux117 add -12346 0.50001 -> -12346 Inexact Rounded + +r0sux120 add -12345 0.4 -> -12344 Inexact Rounded +r0sux121 add -12345 0.49 -> -12344 Inexact Rounded +r0sux122 add -12345 0.499 -> -12344 Inexact Rounded +r0sux123 add -12345 0.49999 -> -12344 Inexact Rounded +r0sux124 add -12345 0.5 -> -12344 Inexact Rounded +r0sux125 add -12345 0.50001 -> -12344 Inexact Rounded +r0sux126 add -12345 0.5001 -> -12344 Inexact Rounded +r0sux127 add -12345 0.501 -> -12344 Inexact Rounded +r0sux128 add -12345 0.51 -> -12344 Inexact Rounded +r0sux129 add -12345 0.6 -> -12344 Inexact Rounded + +-- Check cancellation subtractions +-- (The IEEE 854 'curious rule' in $6.3) + +r0zex001 add 0 0 -> 0 +r0zex002 add 0 -0 -> 0 +r0zex003 add -0 0 -> 0 +r0zex004 add -0 -0 -> -0 +r0zex005 add 1 -1 -> 0 +r0zex006 add -1 1 -> 0 +r0zex007 add 1.5 -1.5 -> 0.0 +r0zex008 add -1.5 1.5 -> 0.0 +r0zex009 add 2 -2 -> 0 +r0zex010 add -2 2 -> 0 + + +-- Division operators ------------------------------------------------- + +r0dvx101 divide 12345 1 -> 12345 +r0dvx102 divide 12345 1.0001 -> 12343 Inexact Rounded +r0dvx103 divide 12345 1.001 -> 12332 Inexact Rounded +r0dvx104 divide 12345 1.01 -> 12222 Inexact Rounded +r0dvx105 divide 12345 1.1 -> 11222 Inexact Rounded +r0dvx106 divide 12355 4 -> 3088.7 Inexact Rounded +r0dvx107 divide 12345 4 -> 3086.2 Inexact Rounded +r0dvx108 divide 12355 4.0001 -> 3088.6 Inexact Rounded +r0dvx109 divide 12345 4.0001 -> 3086.1 Inexact Rounded +r0dvx110 divide 12345 4.9 -> 2519.3 Inexact Rounded +r0dvx111 divide 12345 4.99 -> 2473.9 Inexact Rounded +r0dvx112 divide 12345 4.999 -> 2469.4 Inexact Rounded +r0dvx113 divide 12345 4.9999 -> 2469.1 Inexact Rounded +r0dvx114 divide 12345 5 -> 2469 +r0dvx115 divide 12345 5.0001 -> 2468.9 Inexact Rounded +r0dvx116 divide 12345 5.001 -> 2468.6 Inexact Rounded +r0dvx117 divide 12345 5.01 -> 2464.1 Inexact Rounded +r0dvx118 divide 12345 5.1 -> 2420.6 Inexact Rounded + +-- [divideInteger and remainder unaffected] + +-- Multiplication operator -------------------------------------------- + +r0mux101 multiply 12345 1 -> 12345 +r0mux102 multiply 12345 1.0001 -> 12346 Inexact Rounded +r0mux103 multiply 12345 1.001 -> 12357 Inexact Rounded +r0mux104 multiply 12345 1.01 -> 12468 Inexact Rounded +r0mux105 multiply 12345 1.1 -> 13579 Inexact Rounded +r0mux106 multiply 12345 4 -> 49380 +r0mux107 multiply 12345 4.0001 -> 49381 Inexact Rounded +r0mux108 multiply 12345 4.9 -> 60491 Inexact Rounded +r0mux109 multiply 12345 4.99 -> 61601 Inexact Rounded +r0mux110 multiply 12345 4.999 -> 61712 Inexact Rounded +r0mux111 multiply 12345 4.9999 -> 61723 Inexact Rounded +r0mux112 multiply 12345 5 -> 61725 +r0mux113 multiply 12345 5.0001 -> 61726 Inexact Rounded +r0mux114 multiply 12345 5.001 -> 61737 Inexact Rounded +r0mux115 multiply 12345 5.01 -> 61848 Inexact Rounded +r0mux116 multiply 12345 12 -> 1.4814E+5 Rounded +r0mux117 multiply 12345 13 -> 1.6048E+5 Inexact Rounded +r0mux118 multiply 12355 12 -> 1.4826E+5 Rounded +r0mux119 multiply 12355 13 -> 1.6061E+5 Inexact Rounded + + +-- Power operator ----------------------------------------------------- + +r0pox101 power 12345 -5 -> 3.4877E-21 Inexact Rounded +r0pox102 power 12345 -4 -> 4.3056E-17 Inexact Rounded +r0pox103 power 12345 -3 -> 5.3152E-13 Inexact Rounded +r0pox104 power 12345 -2 -> 6.5617E-9 Inexact Rounded +r0pox105 power 12345 -1 -> 0.000081004 Inexact Rounded +r0pox106 power 12345 0 -> 1 +r0pox107 power 12345 1 -> 12345 +r0pox108 power 12345 2 -> 1.5239E+8 Inexact Rounded +r0pox109 power 12345 3 -> 1.8813E+12 Inexact Rounded +r0pox110 power 12345 4 -> 2.3226E+16 Inexact Rounded +r0pox111 power 12345 5 -> 2.8671E+20 Inexact Rounded +r0pox112 power 415 2 -> 1.7222E+5 Inexact Rounded +r0pox113 power 75 3 -> 4.2187E+5 Inexact Rounded + + +-- Underflow Subnormal and overflow values vary with rounding mode and sign +maxexponent: 999999999 +minexponent: -999999999 +-- [round down gives Nmax on first two and .0E... on the next two] +r0ovx100 multiply 10 9E+999999999 -> 9.9999E+999999999 Overflow Inexact Rounded +r0ovx101 multiply -10 9E+999999999 -> -9.9999E+999999999 Overflow Inexact Rounded +r0ovx102 divide 1E-9 9E+999999999 -> 1E-1000000003 Underflow Subnormal Inexact Rounded +r0ovx104 divide -1E-9 9E+999999999 -> -1E-1000000003 Underflow Subnormal Inexact Rounded + +-- reprise rounding mode effect (using multiplies so precision directive used) +precision: 9 +maxexponent: 999999999 +r0mex412 multiply -9.999E+999999999 10 -> -9.99999999E+999999999 Overflow Inexact Rounded +r0mex413 multiply 9.999E+999999999 10 -> 9.99999999E+999999999 Overflow Inexact Rounded + Modified: python/branches/release25-maint/Lib/test/decimaltestdata/samequantum.decTest ============================================================================== --- python/branches/release25-maint/Lib/test/decimaltestdata/samequantum.decTest (original) +++ python/branches/release25-maint/Lib/test/decimaltestdata/samequantum.decTest Tue Jan 8 17:20:31 2008 @@ -1,6 +1,6 @@ ------------------------------------------------------------------------ -- samequantum.decTest -- check quantums match -- --- Copyright (c) IBM Corporation, 2001, 2003. All rights reserved. -- +-- Copyright (c) IBM Corporation, 2001, 2007. All rights reserved. -- ------------------------------------------------------------------------ -- Please see the document "General Decimal Arithmetic Testcases" -- -- at http://www2.hursley.ibm.com/decimal for the description of -- @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc at uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.39 +version: 2.57 extended: 1 precision: 9 @@ -64,8 +64,44 @@ samq048 samequantum -0E-17 -0.0E-16 -> 1 samq049 samequantum -0E-17 -0.0E-17 -> 0 --- specials & combinations +-- Nmax, Nmin, Ntiny +samq051 samequantum 9.99999999E+999 9.99999999E+999 -> 1 +samq052 samequantum 1E-999 1E-999 -> 1 +samq053 samequantum 1.00000000E-999 1.00000000E-999 -> 1 +samq054 samequantum 1E-1007 1E-1007 -> 1 +samq055 samequantum 9.99999999E+999 9.99999999E+999 -> 1 +samq056 samequantum 1E-999 1E-999 -> 1 +samq057 samequantum 1.00000000E-999 1.00000000E-999 -> 1 +samq058 samequantum 1E-1007 1E-1007 -> 1 + +samq061 samequantum -1E-1007 -1E-1007 -> 1 +samq062 samequantum -1.00000000E-999 -1.00000000E-999 -> 1 +samq063 samequantum -1E-999 -1E-999 -> 1 +samq064 samequantum -9.99999999E+999 -9.99999999E+999 -> 1 +samq065 samequantum -1E-1007 -1E-1007 -> 1 +samq066 samequantum -1.00000000E-999 -1.00000000E-999 -> 1 +samq067 samequantum -1E-999 -1E-999 -> 1 +samq068 samequantum -9.99999999E+999 -9.99999999E+999 -> 1 + +samq071 samequantum -4E-1007 -1E-1007 -> 1 +samq072 samequantum -4.00000000E-999 -1.00004000E-999 -> 1 +samq073 samequantum -4E-999 -1E-999 -> 1 +samq074 samequantum -4.99999999E+999 -9.99949999E+999 -> 1 +samq075 samequantum -4E-1007 -1E-1007 -> 1 +samq076 samequantum -4.00000000E-999 -1.00400000E-999 -> 1 +samq077 samequantum -4E-999 -1E-999 -> 1 +samq078 samequantum -4.99999999E+999 -9.94999999E+999 -> 1 + +samq081 samequantum -4E-1006 -1E-1007 -> 0 +samq082 samequantum -4.00000000E-999 -1.00004000E-996 -> 0 +samq083 samequantum -4E-996 -1E-999 -> 0 +samq084 samequantum -4.99999999E+999 -9.99949999E+996 -> 0 +samq085 samequantum -4E-1006 -1E-1007 -> 0 +samq086 samequantum -4.00000000E-999 -1.00400000E-996 -> 0 +samq087 samequantum -4E-996 -1E-999 -> 0 +samq088 samequantum -4.99999999E+999 -9.94999999E+996 -> 0 +-- specials & combinations samq0110 samequantum -Inf -Inf -> 1 samq0111 samequantum -Inf Inf -> 1 samq0112 samequantum -Inf NaN -> 0 Added: python/branches/release25-maint/Lib/test/decimaltestdata/scaleb.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/scaleb.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,200 @@ +------------------------------------------------------------------------ +-- scaleb.decTest -- scale a number by powers of 10 -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +extended: 1 +precision: 9 +rounding: half_up +maxExponent: 999 +minExponent: -999 + +-- Max |rhs| is 2*(999+9) = 2016 + +-- Sanity checks +scbx001 scaleb 7.50 10 -> 7.50E+10 +scbx002 scaleb 7.50 3 -> 7.50E+3 +scbx003 scaleb 7.50 2 -> 750 +scbx004 scaleb 7.50 1 -> 75.0 +scbx005 scaleb 7.50 0 -> 7.50 +scbx006 scaleb 7.50 -1 -> 0.750 +scbx007 scaleb 7.50 -2 -> 0.0750 +scbx008 scaleb 7.50 -10 -> 7.50E-10 +scbx009 scaleb -7.50 3 -> -7.50E+3 +scbx010 scaleb -7.50 2 -> -750 +scbx011 scaleb -7.50 1 -> -75.0 +scbx012 scaleb -7.50 0 -> -7.50 +scbx013 scaleb -7.50 -1 -> -0.750 + +-- Infinities +scbx014 scaleb Infinity 1 -> Infinity +scbx015 scaleb -Infinity 2 -> -Infinity +scbx016 scaleb Infinity -1 -> Infinity +scbx017 scaleb -Infinity -2 -> -Infinity + +-- Next two are somewhat undefined in 754r; treat as non-integer +scbx018 scaleb 10 Infinity -> NaN Invalid_operation +scbx019 scaleb 10 -Infinity -> NaN Invalid_operation + +-- NaNs are undefined in 754r; assume usual processing +-- NaNs, 0 payload +scbx021 scaleb NaN 1 -> NaN +scbx022 scaleb -NaN -1 -> -NaN +scbx023 scaleb sNaN 1 -> NaN Invalid_operation +scbx024 scaleb -sNaN 1 -> -NaN Invalid_operation +scbx025 scaleb 4 NaN -> NaN +scbx026 scaleb -Inf -NaN -> -NaN +scbx027 scaleb 4 sNaN -> NaN Invalid_operation +scbx028 scaleb Inf -sNaN -> -NaN Invalid_operation + +-- non-integer RHS +scbx030 scaleb 1.23 1 -> 12.3 +scbx031 scaleb 1.23 1.00 -> NaN Invalid_operation +scbx032 scaleb 1.23 1.1 -> NaN Invalid_operation +scbx033 scaleb 1.23 1.01 -> NaN Invalid_operation +scbx034 scaleb 1.23 0.01 -> NaN Invalid_operation +scbx035 scaleb 1.23 0.11 -> NaN Invalid_operation +scbx036 scaleb 1.23 0.999999999 -> NaN Invalid_operation +scbx037 scaleb 1.23 -1 -> 0.123 +scbx038 scaleb 1.23 -1.00 -> NaN Invalid_operation +scbx039 scaleb 1.23 -1.1 -> NaN Invalid_operation +scbx040 scaleb 1.23 -1.01 -> NaN Invalid_operation +scbx041 scaleb 1.23 -0.01 -> NaN Invalid_operation +scbx042 scaleb 1.23 -0.11 -> NaN Invalid_operation +scbx043 scaleb 1.23 -0.999999999 -> NaN Invalid_operation +scbx044 scaleb 1.23 0.1 -> NaN Invalid_operation +scbx045 scaleb 1.23 1E+1 -> NaN Invalid_operation +scbx046 scaleb 1.23 1.1234E+6 -> NaN Invalid_operation +scbx047 scaleb 1.23 1.123E+4 -> NaN Invalid_operation + + +scbx120 scaleb 1.23 2015 -> Infinity Overflow Inexact Rounded +scbx121 scaleb 1.23 2016 -> Infinity Overflow Inexact Rounded +scbx122 scaleb 1.23 2017 -> NaN Invalid_operation +scbx123 scaleb 1.23 2018 -> NaN Invalid_operation +scbx124 scaleb 1.23 -2015 -> 0E-1007 Underflow Subnormal Inexact Rounded Clamped +scbx125 scaleb 1.23 -2016 -> 0E-1007 Underflow Subnormal Inexact Rounded Clamped +scbx126 scaleb 1.23 -2017 -> NaN Invalid_operation +scbx127 scaleb 1.23 -2018 -> NaN Invalid_operation + +-- NaNs, non-0 payload +-- propagating NaNs +scbx861 scaleb NaN01 -Inf -> NaN1 +scbx862 scaleb -NaN02 -1000 -> -NaN2 +scbx863 scaleb NaN03 1000 -> NaN3 +scbx864 scaleb NaN04 Inf -> NaN4 +scbx865 scaleb NaN05 NaN61 -> NaN5 +scbx866 scaleb -Inf -NaN71 -> -NaN71 +scbx867 scaleb -1000 NaN81 -> NaN81 +scbx868 scaleb 1000 NaN91 -> NaN91 +scbx869 scaleb Inf NaN101 -> NaN101 +scbx871 scaleb sNaN011 -Inf -> NaN11 Invalid_operation +scbx872 scaleb sNaN012 -1000 -> NaN12 Invalid_operation +scbx873 scaleb -sNaN013 1000 -> -NaN13 Invalid_operation +scbx874 scaleb sNaN014 NaN171 -> NaN14 Invalid_operation +scbx875 scaleb sNaN015 sNaN181 -> NaN15 Invalid_operation +scbx876 scaleb NaN016 sNaN191 -> NaN191 Invalid_operation +scbx877 scaleb -Inf sNaN201 -> NaN201 Invalid_operation +scbx878 scaleb -1000 sNaN211 -> NaN211 Invalid_operation +scbx879 scaleb 1000 -sNaN221 -> -NaN221 Invalid_operation +scbx880 scaleb Inf sNaN231 -> NaN231 Invalid_operation +scbx881 scaleb NaN025 sNaN241 -> NaN241 Invalid_operation + +-- finites +scbx051 scaleb 7 -2 -> 0.07 +scbx052 scaleb -7 -2 -> -0.07 +scbx053 scaleb 75 -2 -> 0.75 +scbx054 scaleb -75 -2 -> -0.75 +scbx055 scaleb 7.50 -2 -> 0.0750 +scbx056 scaleb -7.50 -2 -> -0.0750 +scbx057 scaleb 7.500 -2 -> 0.07500 +scbx058 scaleb -7.500 -2 -> -0.07500 +scbx061 scaleb 7 -1 -> 0.7 +scbx062 scaleb -7 -1 -> -0.7 +scbx063 scaleb 75 -1 -> 7.5 +scbx064 scaleb -75 -1 -> -7.5 +scbx065 scaleb 7.50 -1 -> 0.750 +scbx066 scaleb -7.50 -1 -> -0.750 +scbx067 scaleb 7.500 -1 -> 0.7500 +scbx068 scaleb -7.500 -1 -> -0.7500 +scbx071 scaleb 7 0 -> 7 +scbx072 scaleb -7 0 -> -7 +scbx073 scaleb 75 0 -> 75 +scbx074 scaleb -75 0 -> -75 +scbx075 scaleb 7.50 0 -> 7.50 +scbx076 scaleb -7.50 0 -> -7.50 +scbx077 scaleb 7.500 0 -> 7.500 +scbx078 scaleb -7.500 0 -> -7.500 +scbx081 scaleb 7 1 -> 7E+1 +scbx082 scaleb -7 1 -> -7E+1 +scbx083 scaleb 75 1 -> 7.5E+2 +scbx084 scaleb -75 1 -> -7.5E+2 +scbx085 scaleb 7.50 1 -> 75.0 +scbx086 scaleb -7.50 1 -> -75.0 +scbx087 scaleb 7.500 1 -> 75.00 +scbx088 scaleb -7.500 1 -> -75.00 +scbx091 scaleb 7 2 -> 7E+2 +scbx092 scaleb -7 2 -> -7E+2 +scbx093 scaleb 75 2 -> 7.5E+3 +scbx094 scaleb -75 2 -> -7.5E+3 +scbx095 scaleb 7.50 2 -> 750 +scbx096 scaleb -7.50 2 -> -750 +scbx097 scaleb 7.500 2 -> 750.0 +scbx098 scaleb -7.500 2 -> -750.0 + +-- zeros +scbx111 scaleb 0 1 -> 0E+1 +scbx112 scaleb -0 2 -> -0E+2 +scbx113 scaleb 0E+4 3 -> 0E+7 +scbx114 scaleb -0E+4 4 -> -0E+8 +scbx115 scaleb 0.0000 5 -> 0E+1 +scbx116 scaleb -0.0000 6 -> -0E+2 +scbx117 scaleb 0E-141 7 -> 0E-134 +scbx118 scaleb -0E-141 8 -> -0E-133 + +-- Nmax, Nmin, Ntiny +scbx132 scaleb 9.99999999E+999 +999 -> Infinity Overflow Inexact Rounded +scbx133 scaleb 9.99999999E+999 +10 -> Infinity Overflow Inexact Rounded +scbx134 scaleb 9.99999999E+999 +1 -> Infinity Overflow Inexact Rounded +scbx135 scaleb 9.99999999E+999 0 -> 9.99999999E+999 +scbx136 scaleb 9.99999999E+999 -1 -> 9.99999999E+998 +scbx137 scaleb 1E-999 +1 -> 1E-998 +scbx138 scaleb 1E-999 -0 -> 1E-999 +scbx139 scaleb 1E-999 -1 -> 1E-1000 Subnormal +scbx140 scaleb 1.00000000E-999 +1 -> 1.00000000E-998 +scbx141 scaleb 1.00000000E-999 0 -> 1.00000000E-999 +scbx142 scaleb 1.00000000E-999 -1 -> 1.0000000E-1000 Subnormal Rounded +scbx143 scaleb 1E-1007 +1 -> 1E-1006 Subnormal +scbx144 scaleb 1E-1007 -0 -> 1E-1007 Subnormal +scbx145 scaleb 1E-1007 -1 -> 0E-1007 Underflow Subnormal Inexact Rounded Clamped + +scbx150 scaleb -1E-1007 +1 -> -1E-1006 Subnormal +scbx151 scaleb -1E-1007 -0 -> -1E-1007 Subnormal +scbx152 scaleb -1E-1007 -1 -> -0E-1007 Underflow Subnormal Inexact Rounded Clamped +scbx153 scaleb -1.00000000E-999 +1 -> -1.00000000E-998 +scbx154 scaleb -1.00000000E-999 +0 -> -1.00000000E-999 +scbx155 scaleb -1.00000000E-999 -1 -> -1.0000000E-1000 Subnormal Rounded +scbx156 scaleb -1E-999 +1 -> -1E-998 +scbx157 scaleb -1E-999 -0 -> -1E-999 +scbx158 scaleb -1E-999 -1 -> -1E-1000 Subnormal +scbx159 scaleb -9.99999999E+999 +1 -> -Infinity Overflow Inexact Rounded +scbx160 scaleb -9.99999999E+999 +0 -> -9.99999999E+999 +scbx161 scaleb -9.99999999E+999 -1 -> -9.99999999E+998 +scbx162 scaleb -9E+999 +1 -> -Infinity Overflow Inexact Rounded +scbx163 scaleb -1E+999 +1 -> -Infinity Overflow Inexact Rounded Added: python/branches/release25-maint/Lib/test/decimaltestdata/shift.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/shift.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,250 @@ +------------------------------------------------------------------------ +-- shift.decTest -- shift coefficient left or right -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +extended: 1 +precision: 9 +rounding: half_up +maxExponent: 999 +minExponent: -999 + +-- Sanity check +shix001 shift 0 0 -> 0 +shix002 shift 0 2 -> 0 +shix003 shift 1 2 -> 100 +shix004 shift 1 8 -> 100000000 +shix005 shift 1 9 -> 0 +shix006 shift 1 -1 -> 0 +shix007 shift 123456789 -1 -> 12345678 +shix008 shift 123456789 -8 -> 1 +shix009 shift 123456789 -9 -> 0 +shix010 shift 0 -2 -> 0 + +-- rhs must be an integer +shix011 shift 1 1.5 -> NaN Invalid_operation +shix012 shift 1 1.0 -> NaN Invalid_operation +shix013 shift 1 0.1 -> NaN Invalid_operation +shix014 shift 1 0.0 -> NaN Invalid_operation +shix015 shift 1 1E+1 -> NaN Invalid_operation +shix016 shift 1 1E+99 -> NaN Invalid_operation +shix017 shift 1 Inf -> NaN Invalid_operation +shix018 shift 1 -Inf -> NaN Invalid_operation +-- and |rhs| <= precision +shix020 shift 1 -1000 -> NaN Invalid_operation +shix021 shift 1 -10 -> NaN Invalid_operation +shix022 shift 1 10 -> NaN Invalid_operation +shix023 shift 1 1000 -> NaN Invalid_operation + +-- full shifting pattern +shix030 shift 123456789 -9 -> 0 +shix031 shift 123456789 -8 -> 1 +shix032 shift 123456789 -7 -> 12 +shix033 shift 123456789 -6 -> 123 +shix034 shift 123456789 -5 -> 1234 +shix035 shift 123456789 -4 -> 12345 +shix036 shift 123456789 -3 -> 123456 +shix037 shift 123456789 -2 -> 1234567 +shix038 shift 123456789 -1 -> 12345678 +shix039 shift 123456789 -0 -> 123456789 +shix040 shift 123456789 +0 -> 123456789 +shix041 shift 123456789 +1 -> 234567890 +shix042 shift 123456789 +2 -> 345678900 +shix043 shift 123456789 +3 -> 456789000 +shix044 shift 123456789 +4 -> 567890000 +shix045 shift 123456789 +5 -> 678900000 +shix046 shift 123456789 +6 -> 789000000 +shix047 shift 123456789 +7 -> 890000000 +shix048 shift 123456789 +8 -> 900000000 +shix049 shift 123456789 +9 -> 0 + +-- from examples +shix051 shift 34 8 -> '400000000' +shix052 shift 12 9 -> '0' +shix053 shift 123456789 -2 -> '1234567' +shix054 shift 123456789 0 -> '123456789' +shix055 shift 123456789 +2 -> '345678900' + +-- zeros +shix060 shift 0E-10 +9 -> 0E-10 +shix061 shift 0E-10 -9 -> 0E-10 +shix062 shift 0.000 +9 -> 0.000 +shix063 shift 0.000 -9 -> 0.000 +shix064 shift 0E+10 +9 -> 0E+10 +shix065 shift 0E+10 -9 -> 0E+10 +shix066 shift -0E-10 +9 -> -0E-10 +shix067 shift -0E-10 -9 -> -0E-10 +shix068 shift -0.000 +9 -> -0.000 +shix069 shift -0.000 -9 -> -0.000 +shix070 shift -0E+10 +9 -> -0E+10 +shix071 shift -0E+10 -9 -> -0E+10 + +-- Nmax, Nmin, Ntiny +shix141 shift 9.99999999E+999 -1 -> 9.9999999E+998 +shix142 shift 9.99999999E+999 -8 -> 9E+991 +shix143 shift 9.99999999E+999 1 -> 9.99999990E+999 +shix144 shift 9.99999999E+999 8 -> 9.00000000E+999 +shix145 shift 1E-999 -1 -> 0E-999 +shix146 shift 1E-999 -8 -> 0E-999 +shix147 shift 1E-999 1 -> 1.0E-998 +shix148 shift 1E-999 8 -> 1.00000000E-991 +shix151 shift 1.00000000E-999 -1 -> 1.0000000E-1000 +shix152 shift 1.00000000E-999 -8 -> 1E-1007 +shix153 shift 1.00000000E-999 1 -> 0E-1007 +shix154 shift 1.00000000E-999 8 -> 0E-1007 +shix155 shift 9.00000000E-999 -1 -> 9.0000000E-1000 +shix156 shift 9.00000000E-999 -8 -> 9E-1007 +shix157 shift 9.00000000E-999 1 -> 0E-1007 +shix158 shift 9.00000000E-999 8 -> 0E-1007 +shix160 shift 1E-1007 -1 -> 0E-1007 +shix161 shift 1E-1007 -8 -> 0E-1007 +shix162 shift 1E-1007 1 -> 1.0E-1006 +shix163 shift 1E-1007 8 -> 1.00000000E-999 +-- negatives +shix171 shift -9.99999999E+999 -1 -> -9.9999999E+998 +shix172 shift -9.99999999E+999 -8 -> -9E+991 +shix173 shift -9.99999999E+999 1 -> -9.99999990E+999 +shix174 shift -9.99999999E+999 8 -> -9.00000000E+999 +shix175 shift -1E-999 -1 -> -0E-999 +shix176 shift -1E-999 -8 -> -0E-999 +shix177 shift -1E-999 1 -> -1.0E-998 +shix178 shift -1E-999 8 -> -1.00000000E-991 +shix181 shift -1.00000000E-999 -1 -> -1.0000000E-1000 +shix182 shift -1.00000000E-999 -8 -> -1E-1007 +shix183 shift -1.00000000E-999 1 -> -0E-1007 +shix184 shift -1.00000000E-999 8 -> -0E-1007 +shix185 shift -9.00000000E-999 -1 -> -9.0000000E-1000 +shix186 shift -9.00000000E-999 -8 -> -9E-1007 +shix187 shift -9.00000000E-999 1 -> -0E-1007 +shix188 shift -9.00000000E-999 8 -> -0E-1007 +shix190 shift -1E-1007 -1 -> -0E-1007 +shix191 shift -1E-1007 -8 -> -0E-1007 +shix192 shift -1E-1007 1 -> -1.0E-1006 +shix193 shift -1E-1007 8 -> -1.00000000E-999 + +-- more negatives (of sanities) +shix201 shift -0 0 -> -0 +shix202 shift -0 2 -> -0 +shix203 shift -1 2 -> -100 +shix204 shift -1 8 -> -100000000 +shix205 shift -1 9 -> -0 +shix206 shift -1 -1 -> -0 +shix207 shift -123456789 -1 -> -12345678 +shix208 shift -123456789 -8 -> -1 +shix209 shift -123456789 -9 -> -0 +shix210 shift -0 -2 -> -0 +shix211 shift -0 -0 -> -0 + + +-- Specials; NaNs are handled as usual +shix781 shift -Inf -8 -> -Infinity +shix782 shift -Inf -1 -> -Infinity +shix783 shift -Inf -0 -> -Infinity +shix784 shift -Inf 0 -> -Infinity +shix785 shift -Inf 1 -> -Infinity +shix786 shift -Inf 8 -> -Infinity +shix787 shift -1000 -Inf -> NaN Invalid_operation +shix788 shift -Inf -Inf -> NaN Invalid_operation +shix789 shift -1 -Inf -> NaN Invalid_operation +shix790 shift -0 -Inf -> NaN Invalid_operation +shix791 shift 0 -Inf -> NaN Invalid_operation +shix792 shift 1 -Inf -> NaN Invalid_operation +shix793 shift 1000 -Inf -> NaN Invalid_operation +shix794 shift Inf -Inf -> NaN Invalid_operation + +shix800 shift Inf -Inf -> NaN Invalid_operation +shix801 shift Inf -8 -> Infinity +shix802 shift Inf -1 -> Infinity +shix803 shift Inf -0 -> Infinity +shix804 shift Inf 0 -> Infinity +shix805 shift Inf 1 -> Infinity +shix806 shift Inf 8 -> Infinity +shix807 shift Inf Inf -> NaN Invalid_operation +shix808 shift -1000 Inf -> NaN Invalid_operation +shix809 shift -Inf Inf -> NaN Invalid_operation +shix810 shift -1 Inf -> NaN Invalid_operation +shix811 shift -0 Inf -> NaN Invalid_operation +shix812 shift 0 Inf -> NaN Invalid_operation +shix813 shift 1 Inf -> NaN Invalid_operation +shix814 shift 1000 Inf -> NaN Invalid_operation +shix815 shift Inf Inf -> NaN Invalid_operation + +shix821 shift NaN -Inf -> NaN +shix822 shift NaN -1000 -> NaN +shix823 shift NaN -1 -> NaN +shix824 shift NaN -0 -> NaN +shix825 shift NaN 0 -> NaN +shix826 shift NaN 1 -> NaN +shix827 shift NaN 1000 -> NaN +shix828 shift NaN Inf -> NaN +shix829 shift NaN NaN -> NaN +shix830 shift -Inf NaN -> NaN +shix831 shift -1000 NaN -> NaN +shix832 shift -1 NaN -> NaN +shix833 shift -0 NaN -> NaN +shix834 shift 0 NaN -> NaN +shix835 shift 1 NaN -> NaN +shix836 shift 1000 NaN -> NaN +shix837 shift Inf NaN -> NaN + +shix841 shift sNaN -Inf -> NaN Invalid_operation +shix842 shift sNaN -1000 -> NaN Invalid_operation +shix843 shift sNaN -1 -> NaN Invalid_operation +shix844 shift sNaN -0 -> NaN Invalid_operation +shix845 shift sNaN 0 -> NaN Invalid_operation +shix846 shift sNaN 1 -> NaN Invalid_operation +shix847 shift sNaN 1000 -> NaN Invalid_operation +shix848 shift sNaN NaN -> NaN Invalid_operation +shix849 shift sNaN sNaN -> NaN Invalid_operation +shix850 shift NaN sNaN -> NaN Invalid_operation +shix851 shift -Inf sNaN -> NaN Invalid_operation +shix852 shift -1000 sNaN -> NaN Invalid_operation +shix853 shift -1 sNaN -> NaN Invalid_operation +shix854 shift -0 sNaN -> NaN Invalid_operation +shix855 shift 0 sNaN -> NaN Invalid_operation +shix856 shift 1 sNaN -> NaN Invalid_operation +shix857 shift 1000 sNaN -> NaN Invalid_operation +shix858 shift Inf sNaN -> NaN Invalid_operation +shix859 shift NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +shix861 shift NaN1 -Inf -> NaN1 +shix862 shift +NaN2 -1000 -> NaN2 +shix863 shift NaN3 1000 -> NaN3 +shix864 shift NaN4 Inf -> NaN4 +shix865 shift NaN5 +NaN6 -> NaN5 +shix866 shift -Inf NaN7 -> NaN7 +shix867 shift -1000 NaN8 -> NaN8 +shix868 shift 1000 NaN9 -> NaN9 +shix869 shift Inf +NaN10 -> NaN10 +shix871 shift sNaN11 -Inf -> NaN11 Invalid_operation +shix872 shift sNaN12 -1000 -> NaN12 Invalid_operation +shix873 shift sNaN13 1000 -> NaN13 Invalid_operation +shix874 shift sNaN14 NaN17 -> NaN14 Invalid_operation +shix875 shift sNaN15 sNaN18 -> NaN15 Invalid_operation +shix876 shift NaN16 sNaN19 -> NaN19 Invalid_operation +shix877 shift -Inf +sNaN20 -> NaN20 Invalid_operation +shix878 shift -1000 sNaN21 -> NaN21 Invalid_operation +shix879 shift 1000 sNaN22 -> NaN22 Invalid_operation +shix880 shift Inf sNaN23 -> NaN23 Invalid_operation +shix881 shift +NaN25 +sNaN24 -> NaN24 Invalid_operation +shix882 shift -NaN26 NaN28 -> -NaN26 +shix883 shift -sNaN27 sNaN29 -> -NaN27 Invalid_operation +shix884 shift 1000 -NaN30 -> -NaN30 +shix885 shift 1000 -sNaN31 -> -NaN31 Invalid_operation Modified: python/branches/release25-maint/Lib/test/decimaltestdata/squareroot.decTest ============================================================================== --- python/branches/release25-maint/Lib/test/decimaltestdata/squareroot.decTest (original) +++ python/branches/release25-maint/Lib/test/decimaltestdata/squareroot.decTest Tue Jan 8 17:20:31 2008 @@ -1,6 +1,6 @@ ------------------------------------------------------------------------ -- squareroot.decTest -- decimal square root -- --- Copyright (c) IBM Corporation, 2004. All rights reserved. -- +-- Copyright (c) IBM Corporation, 2003, 2007. All rights reserved. -- ------------------------------------------------------------------------ -- Please see the document "General Decimal Arithmetic Testcases" -- -- at http://www2.hursley.ibm.com/decimal for the description of -- @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc at uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.39 +version: 2.57 extended: 1 precision: 9 @@ -102,6 +102,8 @@ sqtx075 squareroot -100.00 -> NaN Invalid_operation sqtx076 squareroot -1.1000E+3 -> NaN Invalid_operation sqtx077 squareroot -1.10000E+3 -> NaN Invalid_operation +sqtx078 squareroot 1.000 -> 1.00 +sqtx079 squareroot 1.0000 -> 1.00 -- famous squares sqtx080 squareroot 1 -> 1 @@ -2926,19 +2928,26 @@ precision: 11 -- Etiny=-19 sqtx804 squareroot 1E-19 -> 3.162277660E-10 Underflow Subnormal Inexact Rounded -sqtx805 squareroot 10E-19 -> 1.0E-9 +sqtx805 squareroot 10E-19 -> 1.0E-9 -- exact precision: 12 -- Etiny=-20 sqtx806 squareroot 10E-20 -> 3.1622776602E-10 Underflow Subnormal Inexact Rounded -sqtx807 squareroot 1E-20 -> 1E-10 Subnormal -- Exact Subnormal case +sqtx807 squareroot 1E-20 -> 1E-10 Subnormal -- exact Subnormal case precision: 13 -- Etiny=-21 sqtx808 squareroot 1E-21 -> 3.1622776602E-11 Underflow Subnormal Inexact Rounded -sqtx809 squareroot 10E-21 -> 1.0E-10 Subnormal +sqtx809 squareroot 10E-21 -> 1.0E-10 Subnormal -- exact Subnormal case precision: 14 -- Etiny=-22 sqtx810 squareroot 1E-21 -> 3.16227766017E-11 Underflow Subnormal Inexact Rounded sqtx811 squareroot 10E-22 -> 3.16227766017E-11 Underflow Subnormal Inexact Rounded -sqtx812 squareroot 1E-22 -> 1E-11 Subnormal -- Exact Subnormal case +sqtx812 squareroot 1E-22 -> 1E-11 Subnormal -- exact Subnormal case +-- Not enough digits? +precision: 16 +maxExponent: 384 +minExponent: -383 +rounding: half_even +sqtx815 squareroot 1.0000000001000000E-78 -> 1.000000000050000E-39 Inexact Rounded +-- 1 234567890123456 -- special values maxexponent: 999 @@ -2954,5 +2963,842 @@ sqtx827 squareroot -NaN654 -> -NaN654 sqtx828 squareroot NaN1 -> NaN1 +-- payload decapitate +precision: 5 +sqtx840 squareroot -sNaN1234567890 -> -NaN67890 Invalid_operation + +------------------------------------------------------------------------ +-- +-- Special thanks to Mark Dickinson for tests in the range 8000-8999. +-- +-- Extra tests for the square root function, dealing with a variety of +-- corner cases. In particular, these tests concentrate on +-- (1) cases where the input precision exceeds the context precision, and +-- (2) cases where the input exponent is outside the current context, +-- and in particular when the result is subnormal +-- +-- maxexponent and minexponent are set to 9 and -9 for most of these +-- cases; only the precision changes. The rounding also does not +-- change, because it is ignored for this operation. +maxexponent: 9 +minexponent: -9 + +-- exact results, input precision > context precision +precision: 1 +sqtx8000 squareroot 0 -> 0 +sqtx8001 squareroot 1 -> 1 +sqtx8002 squareroot 4 -> 2 +sqtx8003 squareroot 9 -> 3 +sqtx8004 squareroot 16 -> 4 +sqtx8005 squareroot 25 -> 5 +sqtx8006 squareroot 36 -> 6 +sqtx8007 squareroot 49 -> 7 +sqtx8008 squareroot 64 -> 8 +sqtx8009 squareroot 81 -> 9 +sqtx8010 squareroot 100 -> 1E+1 Rounded +sqtx8011 squareroot 121 -> 1E+1 Inexact Rounded + +precision: 2 +sqtx8012 squareroot 0 -> 0 +sqtx8013 squareroot 1 -> 1 +sqtx8014 squareroot 4 -> 2 +sqtx8015 squareroot 9 -> 3 +sqtx8016 squareroot 16 -> 4 +sqtx8017 squareroot 25 -> 5 +sqtx8018 squareroot 36 -> 6 +sqtx8019 squareroot 49 -> 7 +sqtx8020 squareroot 64 -> 8 +sqtx8021 squareroot 81 -> 9 +sqtx8022 squareroot 100 -> 10 +sqtx8023 squareroot 121 -> 11 +sqtx8024 squareroot 144 -> 12 +sqtx8025 squareroot 169 -> 13 +sqtx8026 squareroot 196 -> 14 +sqtx8027 squareroot 225 -> 15 +sqtx8028 squareroot 256 -> 16 +sqtx8029 squareroot 289 -> 17 +sqtx8030 squareroot 324 -> 18 +sqtx8031 squareroot 361 -> 19 +sqtx8032 squareroot 400 -> 20 +sqtx8033 squareroot 441 -> 21 +sqtx8034 squareroot 484 -> 22 +sqtx8035 squareroot 529 -> 23 +sqtx8036 squareroot 576 -> 24 +sqtx8037 squareroot 625 -> 25 +sqtx8038 squareroot 676 -> 26 +sqtx8039 squareroot 729 -> 27 +sqtx8040 squareroot 784 -> 28 +sqtx8041 squareroot 841 -> 29 +sqtx8042 squareroot 900 -> 30 +sqtx8043 squareroot 961 -> 31 +sqtx8044 squareroot 1024 -> 32 +sqtx8045 squareroot 1089 -> 33 +sqtx8046 squareroot 1156 -> 34 +sqtx8047 squareroot 1225 -> 35 +sqtx8048 squareroot 1296 -> 36 +sqtx8049 squareroot 1369 -> 37 +sqtx8050 squareroot 1444 -> 38 +sqtx8051 squareroot 1521 -> 39 +sqtx8052 squareroot 1600 -> 40 +sqtx8053 squareroot 1681 -> 41 +sqtx8054 squareroot 1764 -> 42 +sqtx8055 squareroot 1849 -> 43 +sqtx8056 squareroot 1936 -> 44 +sqtx8057 squareroot 2025 -> 45 +sqtx8058 squareroot 2116 -> 46 +sqtx8059 squareroot 2209 -> 47 +sqtx8060 squareroot 2304 -> 48 +sqtx8061 squareroot 2401 -> 49 +sqtx8062 squareroot 2500 -> 50 +sqtx8063 squareroot 2601 -> 51 +sqtx8064 squareroot 2704 -> 52 +sqtx8065 squareroot 2809 -> 53 +sqtx8066 squareroot 2916 -> 54 +sqtx8067 squareroot 3025 -> 55 +sqtx8068 squareroot 3136 -> 56 +sqtx8069 squareroot 3249 -> 57 +sqtx8070 squareroot 3364 -> 58 +sqtx8071 squareroot 3481 -> 59 +sqtx8072 squareroot 3600 -> 60 +sqtx8073 squareroot 3721 -> 61 +sqtx8074 squareroot 3844 -> 62 +sqtx8075 squareroot 3969 -> 63 +sqtx8076 squareroot 4096 -> 64 +sqtx8077 squareroot 4225 -> 65 +sqtx8078 squareroot 4356 -> 66 +sqtx8079 squareroot 4489 -> 67 +sqtx8080 squareroot 4624 -> 68 +sqtx8081 squareroot 4761 -> 69 +sqtx8082 squareroot 4900 -> 70 +sqtx8083 squareroot 5041 -> 71 +sqtx8084 squareroot 5184 -> 72 +sqtx8085 squareroot 5329 -> 73 +sqtx8086 squareroot 5476 -> 74 +sqtx8087 squareroot 5625 -> 75 +sqtx8088 squareroot 5776 -> 76 +sqtx8089 squareroot 5929 -> 77 +sqtx8090 squareroot 6084 -> 78 +sqtx8091 squareroot 6241 -> 79 +sqtx8092 squareroot 6400 -> 80 +sqtx8093 squareroot 6561 -> 81 +sqtx8094 squareroot 6724 -> 82 +sqtx8095 squareroot 6889 -> 83 +sqtx8096 squareroot 7056 -> 84 +sqtx8097 squareroot 7225 -> 85 +sqtx8098 squareroot 7396 -> 86 +sqtx8099 squareroot 7569 -> 87 +sqtx8100 squareroot 7744 -> 88 +sqtx8101 squareroot 7921 -> 89 +sqtx8102 squareroot 8100 -> 90 +sqtx8103 squareroot 8281 -> 91 +sqtx8104 squareroot 8464 -> 92 +sqtx8105 squareroot 8649 -> 93 +sqtx8106 squareroot 8836 -> 94 +sqtx8107 squareroot 9025 -> 95 +sqtx8108 squareroot 9216 -> 96 +sqtx8109 squareroot 9409 -> 97 +sqtx8110 squareroot 9604 -> 98 +sqtx8111 squareroot 9801 -> 99 +sqtx8112 squareroot 10000 -> 1.0E+2 Rounded +sqtx8113 squareroot 10201 -> 1.0E+2 Inexact Rounded + +precision: 3 +sqtx8114 squareroot 841 -> 29 +sqtx8115 squareroot 1600 -> 40 +sqtx8116 squareroot 2209 -> 47 +sqtx8117 squareroot 9604 -> 98 +sqtx8118 squareroot 21316 -> 146 +sqtx8119 squareroot 52441 -> 229 +sqtx8120 squareroot 68644 -> 262 +sqtx8121 squareroot 69696 -> 264 +sqtx8122 squareroot 70225 -> 265 +sqtx8123 squareroot 76729 -> 277 +sqtx8124 squareroot 130321 -> 361 +sqtx8125 squareroot 171396 -> 414 +sqtx8126 squareroot 270400 -> 520 +sqtx8127 squareroot 279841 -> 529 +sqtx8128 squareroot 407044 -> 638 +sqtx8129 squareroot 408321 -> 639 +sqtx8130 squareroot 480249 -> 693 +sqtx8131 squareroot 516961 -> 719 +sqtx8132 squareroot 692224 -> 832 +sqtx8133 squareroot 829921 -> 911 + +-- selection of random exact results +precision: 6 +sqtx8134 squareroot 2.25E-12 -> 0.0000015 +sqtx8135 squareroot 8.41E-14 -> 2.9E-7 +sqtx8136 squareroot 6.241E-15 -> 7.9E-8 +sqtx8137 squareroot 5.041E+13 -> 7.1E+6 +sqtx8138 squareroot 4761 -> 69 +sqtx8139 squareroot 1.369E+17 -> 3.7E+8 +sqtx8140 squareroot 0.00002116 -> 0.0046 +sqtx8141 squareroot 7.29E+4 -> 2.7E+2 +sqtx8142 squareroot 4.624E-13 -> 6.8E-7 +sqtx8143 squareroot 3.969E+5 -> 6.3E+2 +sqtx8144 squareroot 3.73321E-11 -> 0.00000611 +sqtx8145 squareroot 5.61001E+17 -> 7.49E+8 +sqtx8146 squareroot 2.30400E-11 -> 0.00000480 +sqtx8147 squareroot 4.30336E+17 -> 6.56E+8 +sqtx8148 squareroot 0.057121 -> 0.239 +sqtx8149 squareroot 7.225E+17 -> 8.5E+8 +sqtx8150 squareroot 3.14721E+13 -> 5.61E+6 +sqtx8151 squareroot 4.61041E+17 -> 6.79E+8 +sqtx8152 squareroot 1.39876E-15 -> 3.74E-8 +sqtx8153 squareroot 6.19369E-9 -> 0.0000787 +sqtx8154 squareroot 1.620529E-10 -> 0.00001273 +sqtx8155 squareroot 1177.1761 -> 34.31 +sqtx8156 squareroot 67043344 -> 8188 +sqtx8157 squareroot 4.84E+6 -> 2.2E+3 +sqtx8158 squareroot 1.23904E+11 -> 3.52E+5 +sqtx8159 squareroot 32604100 -> 5710 +sqtx8160 squareroot 2.9757025E-11 -> 0.000005455 +sqtx8161 squareroot 6.3760225E-9 -> 0.00007985 +sqtx8162 squareroot 4.5198729E-11 -> 0.000006723 +sqtx8163 squareroot 1.4745600E-11 -> 0.000003840 +sqtx8164 squareroot 18964283.04 -> 4354.8 +sqtx8165 squareroot 3.308895529E+13 -> 5.7523E+6 +sqtx8166 squareroot 0.0028590409 -> 0.05347 +sqtx8167 squareroot 3572.213824 -> 59.768 +sqtx8168 squareroot 4.274021376E+15 -> 6.5376E+7 +sqtx8169 squareroot 4455476.64 -> 2110.8 +sqtx8170 squareroot 38.44 -> 6.2 +sqtx8171 squareroot 68.558400 -> 8.280 +sqtx8172 squareroot 715402009 -> 26747 +sqtx8173 squareroot 93.373569 -> 9.663 +sqtx8174 squareroot 2.62144000000E+15 -> 5.12000E+7 +sqtx8175 squareroot 7.48225000000E+15 -> 8.65000E+7 +sqtx8176 squareroot 3.38724000000E-9 -> 0.0000582000 +sqtx8177 squareroot 5.64001000000E-13 -> 7.51000E-7 +sqtx8178 squareroot 5.06944000000E-15 -> 7.12000E-8 +sqtx8179 squareroot 4.95616000000E+17 -> 7.04000E+8 +sqtx8180 squareroot 0.0000242064000000 -> 0.00492000 +sqtx8181 squareroot 1.48996000000E-15 -> 3.86000E-8 +sqtx8182 squareroot 9.37024000000E+17 -> 9.68000E+8 +sqtx8183 squareroot 7128900.0000 -> 2670.00 +sqtx8184 squareroot 8.2311610000E-10 -> 0.0000286900 +sqtx8185 squareroot 482747040000 -> 694800 +sqtx8186 squareroot 4.14478440000E+17 -> 6.43800E+8 +sqtx8187 squareroot 5.10510250000E-7 -> 0.000714500 +sqtx8188 squareroot 355096.810000 -> 595.900 +sqtx8189 squareroot 14288400.0000 -> 3780.00 +sqtx8190 squareroot 3.36168040000E-15 -> 5.79800E-8 +sqtx8191 squareroot 1.70899560000E-13 -> 4.13400E-7 +sqtx8192 squareroot 0.0000378348010000 -> 0.00615100 +sqtx8193 squareroot 2.00972890000E-13 -> 4.48300E-7 +sqtx8194 squareroot 4.07222659600E-13 -> 6.38140E-7 +sqtx8195 squareroot 131486012100 -> 362610 +sqtx8196 squareroot 818192611600 -> 904540 +sqtx8197 squareroot 9.8558323600E+16 -> 3.13940E+8 +sqtx8198 squareroot 5641.06144900 -> 75.1070 +sqtx8199 squareroot 4.58789475600E+17 -> 6.77340E+8 +sqtx8200 squareroot 3.21386948100E-9 -> 0.0000566910 +sqtx8201 squareroot 3.9441960000E-8 -> 0.000198600 +sqtx8202 squareroot 242723.728900 -> 492.670 +sqtx8203 squareroot 1874.89000000 -> 43.3000 +sqtx8204 squareroot 2.56722595684E+15 -> 5.06678E+7 +sqtx8205 squareroot 3.96437714689E-17 -> 6.29633E-9 +sqtx8206 squareroot 3.80106774784E-17 -> 6.16528E-9 +sqtx8207 squareroot 1.42403588496E-13 -> 3.77364E-7 +sqtx8208 squareroot 4604.84388100 -> 67.8590 +sqtx8209 squareroot 2157100869.16 -> 46444.6 +sqtx8210 squareroot 355288570.81 -> 18849.1 +sqtx8211 squareroot 4.69775901604E-11 -> 0.00000685402 +sqtx8212 squareroot 8.22115770436E+17 -> 9.06706E+8 +sqtx8213 squareroot 7.16443744900E+15 -> 8.46430E+7 +sqtx8214 squareroot 9.48995498896E+15 -> 9.74164E+7 +sqtx8215 squareroot 0.0000419091801129 -> 0.00647373 +sqtx8216 squareroot 5862627996.84 -> 76567.8 +sqtx8217 squareroot 9369537.3409 -> 3060.97 +sqtx8218 squareroot 7.74792529729E+17 -> 8.80223E+8 +sqtx8219 squareroot 1.08626931396E+17 -> 3.29586E+8 +sqtx8220 squareroot 8.89584739684E-7 -> 0.000943178 +sqtx8221 squareroot 4.0266040896E-18 -> 2.00664E-9 +sqtx8222 squareroot 9.27669480336E-7 -> 0.000963156 +sqtx8223 squareroot 0.00225497717956 -> 0.0474866 + +-- test use of round-half-even for ties +precision: 1 +sqtx8224 squareroot 225 -> 2E+1 Inexact Rounded +sqtx8225 squareroot 625 -> 2E+1 Inexact Rounded +sqtx8226 squareroot 1225 -> 4E+1 Inexact Rounded +sqtx8227 squareroot 2025 -> 4E+1 Inexact Rounded +sqtx8228 squareroot 3025 -> 6E+1 Inexact Rounded +sqtx8229 squareroot 4225 -> 6E+1 Inexact Rounded +sqtx8230 squareroot 5625 -> 8E+1 Inexact Rounded +sqtx8231 squareroot 7225 -> 8E+1 Inexact Rounded +sqtx8232 squareroot 9025 -> 1E+2 Inexact Rounded + +precision: 2 +sqtx8233 squareroot 11025 -> 1.0E+2 Inexact Rounded +sqtx8234 squareroot 13225 -> 1.2E+2 Inexact Rounded +sqtx8235 squareroot 15625 -> 1.2E+2 Inexact Rounded +sqtx8236 squareroot 18225 -> 1.4E+2 Inexact Rounded +sqtx8237 squareroot 21025 -> 1.4E+2 Inexact Rounded +sqtx8238 squareroot 24025 -> 1.6E+2 Inexact Rounded +sqtx8239 squareroot 27225 -> 1.6E+2 Inexact Rounded +sqtx8240 squareroot 30625 -> 1.8E+2 Inexact Rounded +sqtx8241 squareroot 34225 -> 1.8E+2 Inexact Rounded +sqtx8242 squareroot 38025 -> 2.0E+2 Inexact Rounded +sqtx8243 squareroot 42025 -> 2.0E+2 Inexact Rounded +sqtx8244 squareroot 46225 -> 2.2E+2 Inexact Rounded +sqtx8245 squareroot 50625 -> 2.2E+2 Inexact Rounded +sqtx8246 squareroot 55225 -> 2.4E+2 Inexact Rounded +sqtx8247 squareroot 60025 -> 2.4E+2 Inexact Rounded +sqtx8248 squareroot 65025 -> 2.6E+2 Inexact Rounded +sqtx8249 squareroot 70225 -> 2.6E+2 Inexact Rounded +sqtx8250 squareroot 75625 -> 2.8E+2 Inexact Rounded +sqtx8251 squareroot 81225 -> 2.8E+2 Inexact Rounded +sqtx8252 squareroot 87025 -> 3.0E+2 Inexact Rounded +sqtx8253 squareroot 93025 -> 3.0E+2 Inexact Rounded +sqtx8254 squareroot 99225 -> 3.2E+2 Inexact Rounded +sqtx8255 squareroot 105625 -> 3.2E+2 Inexact Rounded +sqtx8256 squareroot 112225 -> 3.4E+2 Inexact Rounded +sqtx8257 squareroot 119025 -> 3.4E+2 Inexact Rounded +sqtx8258 squareroot 126025 -> 3.6E+2 Inexact Rounded +sqtx8259 squareroot 133225 -> 3.6E+2 Inexact Rounded +sqtx8260 squareroot 140625 -> 3.8E+2 Inexact Rounded +sqtx8261 squareroot 148225 -> 3.8E+2 Inexact Rounded +sqtx8262 squareroot 156025 -> 4.0E+2 Inexact Rounded +sqtx8263 squareroot 164025 -> 4.0E+2 Inexact Rounded +sqtx8264 squareroot 172225 -> 4.2E+2 Inexact Rounded +sqtx8265 squareroot 180625 -> 4.2E+2 Inexact Rounded +sqtx8266 squareroot 189225 -> 4.4E+2 Inexact Rounded +sqtx8267 squareroot 198025 -> 4.4E+2 Inexact Rounded +sqtx8268 squareroot 207025 -> 4.6E+2 Inexact Rounded +sqtx8269 squareroot 216225 -> 4.6E+2 Inexact Rounded +sqtx8270 squareroot 225625 -> 4.8E+2 Inexact Rounded +sqtx8271 squareroot 235225 -> 4.8E+2 Inexact Rounded +sqtx8272 squareroot 245025 -> 5.0E+2 Inexact Rounded +sqtx8273 squareroot 255025 -> 5.0E+2 Inexact Rounded +sqtx8274 squareroot 265225 -> 5.2E+2 Inexact Rounded +sqtx8275 squareroot 275625 -> 5.2E+2 Inexact Rounded +sqtx8276 squareroot 286225 -> 5.4E+2 Inexact Rounded +sqtx8277 squareroot 297025 -> 5.4E+2 Inexact Rounded +sqtx8278 squareroot 308025 -> 5.6E+2 Inexact Rounded +sqtx8279 squareroot 319225 -> 5.6E+2 Inexact Rounded +sqtx8280 squareroot 330625 -> 5.8E+2 Inexact Rounded +sqtx8281 squareroot 342225 -> 5.8E+2 Inexact Rounded +sqtx8282 squareroot 354025 -> 6.0E+2 Inexact Rounded +sqtx8283 squareroot 366025 -> 6.0E+2 Inexact Rounded +sqtx8284 squareroot 378225 -> 6.2E+2 Inexact Rounded +sqtx8285 squareroot 390625 -> 6.2E+2 Inexact Rounded +sqtx8286 squareroot 403225 -> 6.4E+2 Inexact Rounded +sqtx8287 squareroot 416025 -> 6.4E+2 Inexact Rounded +sqtx8288 squareroot 429025 -> 6.6E+2 Inexact Rounded +sqtx8289 squareroot 442225 -> 6.6E+2 Inexact Rounded +sqtx8290 squareroot 455625 -> 6.8E+2 Inexact Rounded +sqtx8291 squareroot 469225 -> 6.8E+2 Inexact Rounded +sqtx8292 squareroot 483025 -> 7.0E+2 Inexact Rounded +sqtx8293 squareroot 497025 -> 7.0E+2 Inexact Rounded +sqtx8294 squareroot 511225 -> 7.2E+2 Inexact Rounded +sqtx8295 squareroot 525625 -> 7.2E+2 Inexact Rounded +sqtx8296 squareroot 540225 -> 7.4E+2 Inexact Rounded +sqtx8297 squareroot 555025 -> 7.4E+2 Inexact Rounded +sqtx8298 squareroot 570025 -> 7.6E+2 Inexact Rounded +sqtx8299 squareroot 585225 -> 7.6E+2 Inexact Rounded +sqtx8300 squareroot 600625 -> 7.8E+2 Inexact Rounded +sqtx8301 squareroot 616225 -> 7.8E+2 Inexact Rounded +sqtx8302 squareroot 632025 -> 8.0E+2 Inexact Rounded +sqtx8303 squareroot 648025 -> 8.0E+2 Inexact Rounded +sqtx8304 squareroot 664225 -> 8.2E+2 Inexact Rounded +sqtx8305 squareroot 680625 -> 8.2E+2 Inexact Rounded +sqtx8306 squareroot 697225 -> 8.4E+2 Inexact Rounded +sqtx8307 squareroot 714025 -> 8.4E+2 Inexact Rounded +sqtx8308 squareroot 731025 -> 8.6E+2 Inexact Rounded +sqtx8309 squareroot 748225 -> 8.6E+2 Inexact Rounded +sqtx8310 squareroot 765625 -> 8.8E+2 Inexact Rounded +sqtx8311 squareroot 783225 -> 8.8E+2 Inexact Rounded +sqtx8312 squareroot 801025 -> 9.0E+2 Inexact Rounded +sqtx8313 squareroot 819025 -> 9.0E+2 Inexact Rounded +sqtx8314 squareroot 837225 -> 9.2E+2 Inexact Rounded +sqtx8315 squareroot 855625 -> 9.2E+2 Inexact Rounded +sqtx8316 squareroot 874225 -> 9.4E+2 Inexact Rounded +sqtx8317 squareroot 893025 -> 9.4E+2 Inexact Rounded +sqtx8318 squareroot 912025 -> 9.6E+2 Inexact Rounded +sqtx8319 squareroot 931225 -> 9.6E+2 Inexact Rounded +sqtx8320 squareroot 950625 -> 9.8E+2 Inexact Rounded +sqtx8321 squareroot 970225 -> 9.8E+2 Inexact Rounded +sqtx8322 squareroot 990025 -> 1.0E+3 Inexact Rounded + +precision: 6 +sqtx8323 squareroot 88975734963025 -> 9.43270E+6 Inexact Rounded +sqtx8324 squareroot 71085555000625 -> 8.43122E+6 Inexact Rounded +sqtx8325 squareroot 39994304.051025 -> 6324.10 Inexact Rounded +sqtx8326 squareroot 0.000007327172265625 -> 0.00270688 Inexact Rounded +sqtx8327 squareroot 1.0258600439025E-13 -> 3.20290E-7 Inexact Rounded +sqtx8328 squareroot 0.0034580574275625 -> 0.0588052 Inexact Rounded +sqtx8329 squareroot 7.6842317700625E-7 -> 0.000876598 Inexact Rounded +sqtx8330 squareroot 1263834495.2025 -> 35550.4 Inexact Rounded +sqtx8331 squareroot 433970666460.25 -> 658764 Inexact Rounded +sqtx8332 squareroot 4.5879286230625E-7 -> 0.000677342 Inexact Rounded +sqtx8333 squareroot 0.0029305603306225 -> 0.0541346 Inexact Rounded +sqtx8334 squareroot 70218282.733225 -> 8379.64 Inexact Rounded +sqtx8335 squareroot 11942519.082025 -> 3455.80 Inexact Rounded +sqtx8336 squareroot 0.0021230668905625 -> 0.0460768 Inexact Rounded +sqtx8337 squareroot 0.90081833411025 -> 0.949114 Inexact Rounded +sqtx8338 squareroot 5.5104120936225E-17 -> 7.42322E-9 Inexact Rounded +sqtx8339 squareroot 0.10530446854225 -> 0.324506 Inexact Rounded +sqtx8340 squareroot 8.706069866025E-14 -> 2.95060E-7 Inexact Rounded +sqtx8341 squareroot 23838.58800625 -> 154.398 Inexact Rounded +sqtx8342 squareroot 0.0013426911275625 -> 0.0366428 Inexact Rounded + +-- test use of round-half-even in underflow situations + +-- precisions 2; all cases where result is both subnormal and a tie +precision: 2 +sqtx8343 squareroot 2.5E-21 -> 0E-10 Underflow Subnormal Inexact Rounded Clamped +sqtx8344 squareroot 2.25E-20 -> 2E-10 Underflow Subnormal Inexact Rounded +sqtx8345 squareroot 6.25E-20 -> 2E-10 Underflow Subnormal Inexact Rounded +sqtx8346 squareroot 1.225E-19 -> 4E-10 Underflow Subnormal Inexact Rounded +sqtx8347 squareroot 2.025E-19 -> 4E-10 Underflow Subnormal Inexact Rounded +sqtx8348 squareroot 3.025E-19 -> 6E-10 Underflow Subnormal Inexact Rounded +sqtx8349 squareroot 4.225E-19 -> 6E-10 Underflow Subnormal Inexact Rounded +sqtx8350 squareroot 5.625E-19 -> 8E-10 Underflow Subnormal Inexact Rounded +sqtx8351 squareroot 7.225E-19 -> 8E-10 Underflow Subnormal Inexact Rounded +sqtx8352 squareroot 9.025E-19 -> 1.0E-9 Underflow Subnormal Inexact Rounded + +-- precision 3, input precision <= 5 +precision: 3 +sqtx8353 squareroot 2.5E-23 -> 0E-11 Underflow Subnormal Inexact Rounded Clamped +sqtx8354 squareroot 2.25E-22 -> 2E-11 Underflow Subnormal Inexact Rounded +sqtx8355 squareroot 6.25E-22 -> 2E-11 Underflow Subnormal Inexact Rounded +sqtx8356 squareroot 1.225E-21 -> 4E-11 Underflow Subnormal Inexact Rounded +sqtx8357 squareroot 2.025E-21 -> 4E-11 Underflow Subnormal Inexact Rounded +sqtx8358 squareroot 3.025E-21 -> 6E-11 Underflow Subnormal Inexact Rounded +sqtx8359 squareroot 4.225E-21 -> 6E-11 Underflow Subnormal Inexact Rounded +sqtx8360 squareroot 5.625E-21 -> 8E-11 Underflow Subnormal Inexact Rounded +sqtx8361 squareroot 7.225E-21 -> 8E-11 Underflow Subnormal Inexact Rounded +sqtx8362 squareroot 9.025E-21 -> 1.0E-10 Underflow Subnormal Inexact Rounded +sqtx8363 squareroot 1.1025E-20 -> 1.0E-10 Underflow Subnormal Inexact Rounded +sqtx8364 squareroot 1.3225E-20 -> 1.2E-10 Underflow Subnormal Inexact Rounded +sqtx8365 squareroot 1.5625E-20 -> 1.2E-10 Underflow Subnormal Inexact Rounded +sqtx8366 squareroot 1.8225E-20 -> 1.4E-10 Underflow Subnormal Inexact Rounded +sqtx8367 squareroot 2.1025E-20 -> 1.4E-10 Underflow Subnormal Inexact Rounded +sqtx8368 squareroot 2.4025E-20 -> 1.6E-10 Underflow Subnormal Inexact Rounded +sqtx8369 squareroot 2.7225E-20 -> 1.6E-10 Underflow Subnormal Inexact Rounded +sqtx8370 squareroot 3.0625E-20 -> 1.8E-10 Underflow Subnormal Inexact Rounded +sqtx8371 squareroot 3.4225E-20 -> 1.8E-10 Underflow Subnormal Inexact Rounded +sqtx8372 squareroot 3.8025E-20 -> 2.0E-10 Underflow Subnormal Inexact Rounded +sqtx8373 squareroot 4.2025E-20 -> 2.0E-10 Underflow Subnormal Inexact Rounded +sqtx8374 squareroot 4.6225E-20 -> 2.2E-10 Underflow Subnormal Inexact Rounded +sqtx8375 squareroot 5.0625E-20 -> 2.2E-10 Underflow Subnormal Inexact Rounded +sqtx8376 squareroot 5.5225E-20 -> 2.4E-10 Underflow Subnormal Inexact Rounded +sqtx8377 squareroot 6.0025E-20 -> 2.4E-10 Underflow Subnormal Inexact Rounded +sqtx8378 squareroot 6.5025E-20 -> 2.6E-10 Underflow Subnormal Inexact Rounded +sqtx8379 squareroot 7.0225E-20 -> 2.6E-10 Underflow Subnormal Inexact Rounded +sqtx8380 squareroot 7.5625E-20 -> 2.8E-10 Underflow Subnormal Inexact Rounded +sqtx8381 squareroot 8.1225E-20 -> 2.8E-10 Underflow Subnormal Inexact Rounded +sqtx8382 squareroot 8.7025E-20 -> 3.0E-10 Underflow Subnormal Inexact Rounded +sqtx8383 squareroot 9.3025E-20 -> 3.0E-10 Underflow Subnormal Inexact Rounded +sqtx8384 squareroot 9.9225E-20 -> 3.2E-10 Underflow Subnormal Inexact Rounded + +--precision 4, input precision <= 4 +precision: 4 +sqtx8385 squareroot 2.5E-25 -> 0E-12 Underflow Subnormal Inexact Rounded Clamped +sqtx8386 squareroot 2.25E-24 -> 2E-12 Underflow Subnormal Inexact Rounded +sqtx8387 squareroot 6.25E-24 -> 2E-12 Underflow Subnormal Inexact Rounded +sqtx8388 squareroot 1.225E-23 -> 4E-12 Underflow Subnormal Inexact Rounded +sqtx8389 squareroot 2.025E-23 -> 4E-12 Underflow Subnormal Inexact Rounded +sqtx8390 squareroot 3.025E-23 -> 6E-12 Underflow Subnormal Inexact Rounded +sqtx8391 squareroot 4.225E-23 -> 6E-12 Underflow Subnormal Inexact Rounded +sqtx8392 squareroot 5.625E-23 -> 8E-12 Underflow Subnormal Inexact Rounded +sqtx8393 squareroot 7.225E-23 -> 8E-12 Underflow Subnormal Inexact Rounded +sqtx8394 squareroot 9.025E-23 -> 1.0E-11 Underflow Subnormal Inexact Rounded + +--precision 5, input precision <= 5 +precision: 5 +sqtx8395 squareroot 2.5E-27 -> 0E-13 Underflow Subnormal Inexact Rounded Clamped +sqtx8396 squareroot 2.25E-26 -> 2E-13 Underflow Subnormal Inexact Rounded +sqtx8397 squareroot 6.25E-26 -> 2E-13 Underflow Subnormal Inexact Rounded +sqtx8398 squareroot 1.225E-25 -> 4E-13 Underflow Subnormal Inexact Rounded +sqtx8399 squareroot 2.025E-25 -> 4E-13 Underflow Subnormal Inexact Rounded +sqtx8400 squareroot 3.025E-25 -> 6E-13 Underflow Subnormal Inexact Rounded +sqtx8401 squareroot 4.225E-25 -> 6E-13 Underflow Subnormal Inexact Rounded +sqtx8402 squareroot 5.625E-25 -> 8E-13 Underflow Subnormal Inexact Rounded +sqtx8403 squareroot 7.225E-25 -> 8E-13 Underflow Subnormal Inexact Rounded +sqtx8404 squareroot 9.025E-25 -> 1.0E-12 Underflow Subnormal Inexact Rounded +sqtx8405 squareroot 1.1025E-24 -> 1.0E-12 Underflow Subnormal Inexact Rounded +sqtx8406 squareroot 1.3225E-24 -> 1.2E-12 Underflow Subnormal Inexact Rounded +sqtx8407 squareroot 1.5625E-24 -> 1.2E-12 Underflow Subnormal Inexact Rounded +sqtx8408 squareroot 1.8225E-24 -> 1.4E-12 Underflow Subnormal Inexact Rounded +sqtx8409 squareroot 2.1025E-24 -> 1.4E-12 Underflow Subnormal Inexact Rounded +sqtx8410 squareroot 2.4025E-24 -> 1.6E-12 Underflow Subnormal Inexact Rounded +sqtx8411 squareroot 2.7225E-24 -> 1.6E-12 Underflow Subnormal Inexact Rounded +sqtx8412 squareroot 3.0625E-24 -> 1.8E-12 Underflow Subnormal Inexact Rounded +sqtx8413 squareroot 3.4225E-24 -> 1.8E-12 Underflow Subnormal Inexact Rounded +sqtx8414 squareroot 3.8025E-24 -> 2.0E-12 Underflow Subnormal Inexact Rounded +sqtx8415 squareroot 4.2025E-24 -> 2.0E-12 Underflow Subnormal Inexact Rounded +sqtx8416 squareroot 4.6225E-24 -> 2.2E-12 Underflow Subnormal Inexact Rounded +sqtx8417 squareroot 5.0625E-24 -> 2.2E-12 Underflow Subnormal Inexact Rounded +sqtx8418 squareroot 5.5225E-24 -> 2.4E-12 Underflow Subnormal Inexact Rounded +sqtx8419 squareroot 6.0025E-24 -> 2.4E-12 Underflow Subnormal Inexact Rounded +sqtx8420 squareroot 6.5025E-24 -> 2.6E-12 Underflow Subnormal Inexact Rounded +sqtx8421 squareroot 7.0225E-24 -> 2.6E-12 Underflow Subnormal Inexact Rounded +sqtx8422 squareroot 7.5625E-24 -> 2.8E-12 Underflow Subnormal Inexact Rounded +sqtx8423 squareroot 8.1225E-24 -> 2.8E-12 Underflow Subnormal Inexact Rounded +sqtx8424 squareroot 8.7025E-24 -> 3.0E-12 Underflow Subnormal Inexact Rounded +sqtx8425 squareroot 9.3025E-24 -> 3.0E-12 Underflow Subnormal Inexact Rounded +sqtx8426 squareroot 9.9225E-24 -> 3.2E-12 Underflow Subnormal Inexact Rounded + +-- a random selection of values that Python2.5.1 rounds incorrectly +precision: 1 +sqtx8427 squareroot 227 -> 2E+1 Inexact Rounded +sqtx8428 squareroot 625 -> 2E+1 Inexact Rounded +sqtx8429 squareroot 1215 -> 3E+1 Inexact Rounded +sqtx8430 squareroot 2008 -> 4E+1 Inexact Rounded +sqtx8431 squareroot 2020 -> 4E+1 Inexact Rounded +sqtx8432 squareroot 2026 -> 5E+1 Inexact Rounded +sqtx8433 squareroot 2027 -> 5E+1 Inexact Rounded +sqtx8434 squareroot 2065 -> 5E+1 Inexact Rounded +sqtx8435 squareroot 2075 -> 5E+1 Inexact Rounded +sqtx8436 squareroot 2088 -> 5E+1 Inexact Rounded +sqtx8437 squareroot 3049 -> 6E+1 Inexact Rounded +sqtx8438 squareroot 3057 -> 6E+1 Inexact Rounded +sqtx8439 squareroot 3061 -> 6E+1 Inexact Rounded +sqtx8440 squareroot 3092 -> 6E+1 Inexact Rounded +sqtx8441 squareroot 4222 -> 6E+1 Inexact Rounded +sqtx8442 squareroot 5676 -> 8E+1 Inexact Rounded +sqtx8443 squareroot 5686 -> 8E+1 Inexact Rounded +sqtx8444 squareroot 7215 -> 8E+1 Inexact Rounded +sqtx8445 squareroot 9086 -> 1E+2 Inexact Rounded +sqtx8446 squareroot 9095 -> 1E+2 Inexact Rounded + +precision: 2 +sqtx8447 squareroot 1266 -> 36 Inexact Rounded +sqtx8448 squareroot 2552 -> 51 Inexact Rounded +sqtx8449 squareroot 5554 -> 75 Inexact Rounded +sqtx8450 squareroot 7832 -> 88 Inexact Rounded +sqtx8451 squareroot 13201 -> 1.1E+2 Inexact Rounded +sqtx8452 squareroot 15695 -> 1.3E+2 Inexact Rounded +sqtx8453 squareroot 18272 -> 1.4E+2 Inexact Rounded +sqtx8454 squareroot 21026 -> 1.5E+2 Inexact Rounded +sqtx8455 squareroot 24069 -> 1.6E+2 Inexact Rounded +sqtx8456 squareroot 34277 -> 1.9E+2 Inexact Rounded +sqtx8457 squareroot 46233 -> 2.2E+2 Inexact Rounded +sqtx8458 squareroot 46251 -> 2.2E+2 Inexact Rounded +sqtx8459 squareroot 46276 -> 2.2E+2 Inexact Rounded +sqtx8460 squareroot 70214 -> 2.6E+2 Inexact Rounded +sqtx8461 squareroot 81249 -> 2.9E+2 Inexact Rounded +sqtx8462 squareroot 81266 -> 2.9E+2 Inexact Rounded +sqtx8463 squareroot 93065 -> 3.1E+2 Inexact Rounded +sqtx8464 squareroot 93083 -> 3.1E+2 Inexact Rounded +sqtx8465 squareroot 99230 -> 3.2E+2 Inexact Rounded +sqtx8466 squareroot 99271 -> 3.2E+2 Inexact Rounded + +precision: 3 +sqtx8467 squareroot 11349 -> 107 Inexact Rounded +sqtx8468 squareroot 26738 -> 164 Inexact Rounded +sqtx8469 squareroot 31508 -> 178 Inexact Rounded +sqtx8470 squareroot 44734 -> 212 Inexact Rounded +sqtx8471 squareroot 44738 -> 212 Inexact Rounded +sqtx8472 squareroot 51307 -> 227 Inexact Rounded +sqtx8473 squareroot 62259 -> 250 Inexact Rounded +sqtx8474 squareroot 75901 -> 276 Inexact Rounded +sqtx8475 squareroot 76457 -> 277 Inexact Rounded +sqtx8476 squareroot 180287 -> 425 Inexact Rounded +sqtx8477 squareroot 202053 -> 450 Inexact Rounded +sqtx8478 squareroot 235747 -> 486 Inexact Rounded +sqtx8479 squareroot 256537 -> 506 Inexact Rounded +sqtx8480 squareroot 299772 -> 548 Inexact Rounded +sqtx8481 squareroot 415337 -> 644 Inexact Rounded +sqtx8482 squareroot 617067 -> 786 Inexact Rounded +sqtx8483 squareroot 628022 -> 792 Inexact Rounded +sqtx8484 squareroot 645629 -> 804 Inexact Rounded +sqtx8485 squareroot 785836 -> 886 Inexact Rounded +sqtx8486 squareroot 993066 -> 997 Inexact Rounded + +precision: 6 +sqtx8487 squareroot 14917781 -> 3862.35 Inexact Rounded +sqtx8488 squareroot 17237238 -> 4151.78 Inexact Rounded +sqtx8489 squareroot 18054463 -> 4249.05 Inexact Rounded +sqtx8490 squareroot 19990694 -> 4471.10 Inexact Rounded +sqtx8491 squareroot 29061855 -> 5390.90 Inexact Rounded +sqtx8492 squareroot 49166257 -> 7011.87 Inexact Rounded +sqtx8493 squareroot 53082086 -> 7285.75 Inexact Rounded +sqtx8494 squareroot 56787909 -> 7535.78 Inexact Rounded +sqtx8495 squareroot 81140019 -> 9007.78 Inexact Rounded +sqtx8496 squareroot 87977554 -> 9379.64 Inexact Rounded +sqtx8497 squareroot 93624683 -> 9675.98 Inexact Rounded +sqtx8498 squareroot 98732747 -> 9936.44 Inexact Rounded +sqtx8499 squareroot 99222813 -> 9961.06 Inexact Rounded +sqtx8500 squareroot 143883626 -> 11995.2 Inexact Rounded +sqtx8501 squareroot 180433301 -> 13432.5 Inexact Rounded +sqtx8502 squareroot 227034020 -> 15067.6 Inexact Rounded +sqtx8503 squareroot 283253992 -> 16830.2 Inexact Rounded +sqtx8504 squareroot 617047954 -> 24840.4 Inexact Rounded +sqtx8505 squareroot 736870094 -> 27145.4 Inexact Rounded +sqtx8506 squareroot 897322915 -> 29955.3 Inexact Rounded + +-- results close to minimum normal +precision: 1 +sqtx8507 squareroot 1E-20 -> 0E-9 Underflow Subnormal Inexact Rounded Clamped +sqtx8508 squareroot 1E-19 -> 0E-9 Underflow Subnormal Inexact Rounded Clamped +sqtx8509 squareroot 1E-18 -> 1E-9 + +precision: 2 +sqtx8510 squareroot 8.1E-19 -> 9E-10 Subnormal +sqtx8511 squareroot 8.10E-19 -> 9E-10 Subnormal Rounded +sqtx8512 squareroot 9.0E-19 -> 9E-10 Underflow Subnormal Inexact Rounded +sqtx8513 squareroot 9.02E-19 -> 9E-10 Underflow Subnormal Inexact Rounded +sqtx8514 squareroot 9.03E-19 -> 1.0E-9 Underflow Subnormal Inexact Rounded +sqtx8515 squareroot 9.1E-19 -> 1.0E-9 Underflow Subnormal Inexact Rounded +sqtx8516 squareroot 9.9E-19 -> 1.0E-9 Underflow Subnormal Inexact Rounded +sqtx8517 squareroot 9.91E-19 -> 1.0E-9 Underflow Subnormal Inexact Rounded +sqtx8518 squareroot 9.92E-19 -> 1.0E-9 Underflow Subnormal Inexact Rounded +sqtx8519 squareroot 9.95E-19 -> 1.0E-9 Underflow Subnormal Inexact Rounded +sqtx8520 squareroot 9.98E-19 -> 1.0E-9 Underflow Subnormal Inexact Rounded +sqtx8521 squareroot 9.99E-19 -> 1.0E-9 Underflow Subnormal Inexact Rounded +sqtx8522 squareroot 1E-18 -> 1E-9 +sqtx8523 squareroot 1.0E-18 -> 1.0E-9 +sqtx8524 squareroot 1.00E-18 -> 1.0E-9 +sqtx8525 squareroot 1.000E-18 -> 1.0E-9 Rounded +sqtx8526 squareroot 1.0000E-18 -> 1.0E-9 Rounded +sqtx8527 squareroot 1.01E-18 -> 1.0E-9 Inexact Rounded +sqtx8528 squareroot 1.02E-18 -> 1.0E-9 Inexact Rounded +sqtx8529 squareroot 1.1E-18 -> 1.0E-9 Inexact Rounded + +precision: 3 +sqtx8530 squareroot 8.1E-19 -> 9E-10 Subnormal +sqtx8531 squareroot 8.10E-19 -> 9.0E-10 Subnormal +sqtx8532 squareroot 8.100E-19 -> 9.0E-10 Subnormal +sqtx8533 squareroot 8.1000E-19 -> 9.0E-10 Subnormal Rounded +sqtx8534 squareroot 9.9E-19 -> 9.9E-10 Underflow Subnormal Inexact Rounded +sqtx8535 squareroot 9.91E-19 -> 1.00E-9 Underflow Subnormal Inexact Rounded +sqtx8536 squareroot 9.99E-19 -> 1.00E-9 Underflow Subnormal Inexact Rounded +sqtx8537 squareroot 9.998E-19 -> 1.00E-9 Underflow Subnormal Inexact Rounded +sqtx8538 squareroot 1E-18 -> 1E-9 +sqtx8539 squareroot 1.0E-18 -> 1.0E-9 +sqtx8540 squareroot 1.00E-18 -> 1.0E-9 +sqtx8541 squareroot 1.000E-18 -> 1.00E-9 +sqtx8542 squareroot 1.0000E-18 -> 1.00E-9 +sqtx8543 squareroot 1.00000E-18 -> 1.00E-9 Rounded +sqtx8544 squareroot 1.000000E-18 -> 1.00E-9 Rounded +sqtx8545 squareroot 1.01E-18 -> 1.00E-9 Inexact Rounded +sqtx8546 squareroot 1.02E-18 -> 1.01E-9 Inexact Rounded + +-- result exactly representable with precision p, but not necessarily +-- exactly representable as a subnormal; check the correct flags are raised +precision: 2 +sqtx8547 squareroot 1.21E-20 -> 1E-10 Underflow Subnormal Inexact Rounded +sqtx8548 squareroot 1.44E-20 -> 1E-10 Underflow Subnormal Inexact Rounded +sqtx8549 squareroot 9.61E-20 -> 3E-10 Underflow Subnormal Inexact Rounded +sqtx8550 squareroot 8.836E-19 -> 9E-10 Underflow Subnormal Inexact Rounded +sqtx8551 squareroot 9.216E-19 -> 1.0E-9 Underflow Subnormal Inexact Rounded + +precision: 3 +sqtx8552 squareroot 1.21E-22 -> 1E-11 Underflow Subnormal Inexact Rounded +sqtx8553 squareroot 1.21E-20 -> 1.1E-10 Subnormal +sqtx8554 squareroot 1.96E-22 -> 1E-11 Underflow Subnormal Inexact Rounded +sqtx8555 squareroot 1.96E-20 -> 1.4E-10 Subnormal +sqtx8556 squareroot 2.56E-22 -> 2E-11 Underflow Subnormal Inexact Rounded +sqtx8557 squareroot 4.00E-22 -> 2E-11 Subnormal Rounded +sqtx8558 squareroot 7.84E-22 -> 3E-11 Underflow Subnormal Inexact Rounded +sqtx8559 squareroot 9.801E-21 -> 1.0E-10 Underflow Subnormal Inexact Rounded +sqtx8560 squareroot 9.801E-19 -> 9.9E-10 Subnormal +sqtx8561 squareroot 1.0201E-20 -> 1.0E-10 Underflow Subnormal Inexact Rounded +sqtx8562 squareroot 1.1025E-20 -> 1.0E-10 Underflow Subnormal Inexact Rounded +sqtx8563 squareroot 1.1236E-20 -> 1.1E-10 Underflow Subnormal Inexact Rounded +sqtx8564 squareroot 1.2996E-20 -> 1.1E-10 Underflow Subnormal Inexact Rounded +sqtx8565 squareroot 1.3225E-20 -> 1.2E-10 Underflow Subnormal Inexact Rounded + +-- A selection of subnormal results prone to double rounding errors +precision: 2 +sqtx8566 squareroot 2.3E-21 -> 0E-10 Underflow Subnormal Inexact Rounded Clamped +sqtx8567 squareroot 2.4E-21 -> 0E-10 Underflow Subnormal Inexact Rounded Clamped +sqtx8568 squareroot 2.5E-21 -> 0E-10 Underflow Subnormal Inexact Rounded Clamped +sqtx8569 squareroot 2.6E-21 -> 1E-10 Underflow Subnormal Inexact Rounded +sqtx8570 squareroot 2.7E-21 -> 1E-10 Underflow Subnormal Inexact Rounded +sqtx8571 squareroot 2.8E-21 -> 1E-10 Underflow Subnormal Inexact Rounded +sqtx8572 squareroot 2.2E-20 -> 1E-10 Underflow Subnormal Inexact Rounded +sqtx8573 squareroot 2.3E-20 -> 2E-10 Underflow Subnormal Inexact Rounded +sqtx8574 squareroot 2.4E-20 -> 2E-10 Underflow Subnormal Inexact Rounded +sqtx8575 squareroot 6.2E-20 -> 2E-10 Underflow Subnormal Inexact Rounded +sqtx8576 squareroot 6.3E-20 -> 3E-10 Underflow Subnormal Inexact Rounded +sqtx8577 squareroot 6.4E-20 -> 3E-10 Underflow Subnormal Inexact Rounded +sqtx8578 squareroot 6.5E-20 -> 3E-10 Underflow Subnormal Inexact Rounded +sqtx8579 squareroot 1.2E-19 -> 3E-10 Underflow Subnormal Inexact Rounded +sqtx8580 squareroot 2.0E-19 -> 4E-10 Underflow Subnormal Inexact Rounded +sqtx8581 squareroot 4.2E-19 -> 6E-10 Underflow Subnormal Inexact Rounded +sqtx8582 squareroot 5.6E-19 -> 7E-10 Underflow Subnormal Inexact Rounded +sqtx8583 squareroot 5.7E-19 -> 8E-10 Underflow Subnormal Inexact Rounded +sqtx8584 squareroot 9.0E-19 -> 9E-10 Underflow Subnormal Inexact Rounded +sqtx8585 squareroot 9.1E-19 -> 1.0E-9 Underflow Subnormal Inexact Rounded +precision: 3 +sqtx8586 squareroot 2.6E-23 -> 1E-11 Underflow Subnormal Inexact Rounded +sqtx8587 squareroot 2.22E-22 -> 1E-11 Underflow Subnormal Inexact Rounded +sqtx8588 squareroot 6.07E-22 -> 2E-11 Underflow Subnormal Inexact Rounded +sqtx8589 squareroot 6.25E-22 -> 2E-11 Underflow Subnormal Inexact Rounded +sqtx8590 squareroot 6.45E-22 -> 3E-11 Underflow Subnormal Inexact Rounded +sqtx8591 squareroot 6.50E-22 -> 3E-11 Underflow Subnormal Inexact Rounded +sqtx8592 squareroot 1.22E-21 -> 3E-11 Underflow Subnormal Inexact Rounded +sqtx8593 squareroot 1.24E-21 -> 4E-11 Underflow Subnormal Inexact Rounded +sqtx8594 squareroot 4.18E-21 -> 6E-11 Underflow Subnormal Inexact Rounded +sqtx8595 squareroot 7.19E-21 -> 8E-11 Underflow Subnormal Inexact Rounded +sqtx8596 squareroot 8.94E-21 -> 9E-11 Underflow Subnormal Inexact Rounded +sqtx8597 squareroot 1.81E-20 -> 1.3E-10 Underflow Subnormal Inexact Rounded +sqtx8598 squareroot 4.64E-20 -> 2.2E-10 Underflow Subnormal Inexact Rounded +sqtx8599 squareroot 5.06E-20 -> 2.2E-10 Underflow Subnormal Inexact Rounded +sqtx8600 squareroot 5.08E-20 -> 2.3E-10 Underflow Subnormal Inexact Rounded +sqtx8601 squareroot 7.00E-20 -> 2.6E-10 Underflow Subnormal Inexact Rounded +sqtx8602 squareroot 1.81E-19 -> 4.3E-10 Underflow Subnormal Inexact Rounded +sqtx8603 squareroot 6.64E-19 -> 8.1E-10 Underflow Subnormal Inexact Rounded +sqtx8604 squareroot 7.48E-19 -> 8.6E-10 Underflow Subnormal Inexact Rounded +sqtx8605 squareroot 9.91E-19 -> 1.00E-9 Underflow Subnormal Inexact Rounded +precision: 4 +sqtx8606 squareroot 6.24E-24 -> 2E-12 Underflow Subnormal Inexact Rounded +sqtx8607 squareroot 7.162E-23 -> 8E-12 Underflow Subnormal Inexact Rounded +sqtx8608 squareroot 7.243E-23 -> 9E-12 Underflow Subnormal Inexact Rounded +sqtx8609 squareroot 8.961E-23 -> 9E-12 Underflow Subnormal Inexact Rounded +sqtx8610 squareroot 9.029E-23 -> 1.0E-11 Underflow Subnormal Inexact Rounded +sqtx8611 squareroot 4.624E-22 -> 2.2E-11 Underflow Subnormal Inexact Rounded +sqtx8612 squareroot 5.980E-22 -> 2.4E-11 Underflow Subnormal Inexact Rounded +sqtx8613 squareroot 6.507E-22 -> 2.6E-11 Underflow Subnormal Inexact Rounded +sqtx8614 squareroot 1.483E-21 -> 3.9E-11 Underflow Subnormal Inexact Rounded +sqtx8615 squareroot 3.903E-21 -> 6.2E-11 Underflow Subnormal Inexact Rounded +sqtx8616 squareroot 8.733E-21 -> 9.3E-11 Underflow Subnormal Inexact Rounded +sqtx8617 squareroot 1.781E-20 -> 1.33E-10 Underflow Subnormal Inexact Rounded +sqtx8618 squareroot 6.426E-20 -> 2.53E-10 Underflow Subnormal Inexact Rounded +sqtx8619 squareroot 7.102E-20 -> 2.66E-10 Underflow Subnormal Inexact Rounded +sqtx8620 squareroot 7.535E-20 -> 2.74E-10 Underflow Subnormal Inexact Rounded +sqtx8621 squareroot 9.892E-20 -> 3.15E-10 Underflow Subnormal Inexact Rounded +sqtx8622 squareroot 1.612E-19 -> 4.01E-10 Underflow Subnormal Inexact Rounded +sqtx8623 squareroot 1.726E-19 -> 4.15E-10 Underflow Subnormal Inexact Rounded +sqtx8624 squareroot 1.853E-19 -> 4.30E-10 Underflow Subnormal Inexact Rounded +sqtx8625 squareroot 4.245E-19 -> 6.52E-10 Underflow Subnormal Inexact Rounded + +-- clamping and overflow for large exponents +precision: 1 +sqtx8626 squareroot 1E+18 -> 1E+9 +sqtx8627 squareroot 1E+19 -> 3E+9 Inexact Rounded +sqtx8628 squareroot 9E+19 -> 9E+9 Inexact Rounded +sqtx8629 squareroot 9.1E+19 -> Infinity Overflow Inexact Rounded +sqtx8630 squareroot 1E+20 -> Infinity Overflow Inexact Rounded + +precision: 2 +sqtx8631 squareroot 1E+18 -> 1E+9 +sqtx8632 squareroot 1.0E+18 -> 1.0E+9 +sqtx8633 squareroot 1.00E+18 -> 1.0E+9 +sqtx8634 squareroot 1.000E+18 -> 1.0E+9 Rounded +sqtx8635 squareroot 1E+20 -> Infinity Overflow Inexact Rounded +clamp: 1 +sqtx8636 squareroot 1E+18 -> 1.0E+9 Clamped +sqtx8637 squareroot 1.0E+18 -> 1.0E+9 +sqtx8638 squareroot 1E+20 -> Infinity Overflow Inexact Rounded +clamp: 0 + +precision: 6 +sqtx8639 squareroot 1E+18 -> 1E+9 +sqtx8640 squareroot 1.0000000000E+18 -> 1.00000E+9 +sqtx8641 squareroot 1.00000000000E+18 -> 1.00000E+9 Rounded +sqtx8642 squareroot 1E+20 -> Infinity Overflow Inexact Rounded +clamp: 1 +sqtx8643 squareroot 1E+8 -> 1E+4 +sqtx8644 squareroot 1E+10 -> 1.0E+5 Clamped +sqtx8645 squareroot 1.0E+10 -> 1.0E+5 +sqtx8646 squareroot 1E+12 -> 1.00E+6 Clamped +sqtx8647 squareroot 1.0E+12 -> 1.00E+6 Clamped +sqtx8648 squareroot 1.00E+12 -> 1.00E+6 Clamped +sqtx8649 squareroot 1.000E+12 -> 1.00E+6 +sqtx8650 squareroot 1E+18 -> 1.00000E+9 Clamped +sqtx8651 squareroot 1.00000000E+18 -> 1.00000E+9 Clamped +sqtx8652 squareroot 1.000000000E+18 -> 1.00000E+9 +sqtx8653 squareroot 1E+20 -> Infinity Overflow Inexact Rounded +clamp: 0 + +-- The following example causes a TypeError in Python 2.5.1 +precision: 3 +maxexponent: 9 +minexponent: -9 +sqtx8654 squareroot 10000000000 -> 1.00E+5 Rounded + +-- Additional tricky cases of underflown subnormals +rounding: half_even +precision: 5 +maxexponent: 999 +minexponent: -999 +sqtx8700 squareroot 2.8073E-2000 -> 1.675E-1000 Underflow Subnormal Inexact Rounded +sqtx8701 squareroot 2.8883E-2000 -> 1.699E-1000 Underflow Subnormal Inexact Rounded +sqtx8702 squareroot 3.1524E-2000 -> 1.775E-1000 Underflow Subnormal Inexact Rounded +sqtx8703 squareroot 3.2382E-2000 -> 1.799E-1000 Underflow Subnormal Inexact Rounded +sqtx8704 squareroot 3.5175E-2000 -> 1.875E-1000 Underflow Subnormal Inexact Rounded +sqtx8705 squareroot 3.6081E-2000 -> 1.899E-1000 Underflow Subnormal Inexact Rounded +sqtx8706 squareroot 3.9026E-2000 -> 1.975E-1000 Underflow Subnormal Inexact Rounded +sqtx8707 squareroot 3.9980E-2000 -> 1.999E-1000 Underflow Subnormal Inexact Rounded +sqtx8708 squareroot 4.3077E-2000 -> 2.075E-1000 Underflow Subnormal Inexact Rounded +sqtx8709 squareroot 4.4079E-2000 -> 2.099E-1000 Underflow Subnormal Inexact Rounded +sqtx8710 squareroot 4.7328E-2000 -> 2.175E-1000 Underflow Subnormal Inexact Rounded +sqtx8711 squareroot 4.8378E-2000 -> 2.199E-1000 Underflow Subnormal Inexact Rounded +sqtx8712 squareroot 5.1779E-2000 -> 2.275E-1000 Underflow Subnormal Inexact Rounded +sqtx8713 squareroot 5.2877E-2000 -> 2.299E-1000 Underflow Subnormal Inexact Rounded +sqtx8714 squareroot 5.6430E-2000 -> 2.375E-1000 Underflow Subnormal Inexact Rounded +sqtx8715 squareroot 5.7576E-2000 -> 2.399E-1000 Underflow Subnormal Inexact Rounded +sqtx8716 squareroot 6.1281E-2000 -> 2.475E-1000 Underflow Subnormal Inexact Rounded +sqtx8717 squareroot 6.2475E-2000 -> 2.499E-1000 Underflow Subnormal Inexact Rounded +sqtx8718 squareroot 6.6332E-2000 -> 2.575E-1000 Underflow Subnormal Inexact Rounded +sqtx8719 squareroot 6.7574E-2000 -> 2.599E-1000 Underflow Subnormal Inexact Rounded +sqtx8720 squareroot 7.1583E-2000 -> 2.675E-1000 Underflow Subnormal Inexact Rounded +sqtx8721 squareroot 7.2873E-2000 -> 2.699E-1000 Underflow Subnormal Inexact Rounded +sqtx8722 squareroot 7.7034E-2000 -> 2.775E-1000 Underflow Subnormal Inexact Rounded +sqtx8723 squareroot 7.8372E-2000 -> 2.799E-1000 Underflow Subnormal Inexact Rounded +sqtx8724 squareroot 8.2685E-2000 -> 2.875E-1000 Underflow Subnormal Inexact Rounded +sqtx8725 squareroot 8.4071E-2000 -> 2.899E-1000 Underflow Subnormal Inexact Rounded +sqtx8726 squareroot 8.8536E-2000 -> 2.975E-1000 Underflow Subnormal Inexact Rounded +sqtx8727 squareroot 8.9970E-2000 -> 2.999E-1000 Underflow Subnormal Inexact Rounded +sqtx8728 squareroot 9.4587E-2000 -> 3.075E-1000 Underflow Subnormal Inexact Rounded +sqtx8729 squareroot 9.6069E-2000 -> 3.099E-1000 Underflow Subnormal Inexact Rounded +-- (End of Mark Dickinson's testcases.) + + +-- Some additional edge cases +maxexponent: 9 +minexponent: -9 +precision: 2 +sqtx9000 squareroot 9980.01 -> 1.0E+2 Inexact Rounded +precision: 3 +sqtx9001 squareroot 9980.01 -> 99.9 +precision: 4 +sqtx9002 squareroot 9980.01 -> 99.9 + +-- Exact from over-precise +precision: 4 +sqtx9003 squareroot 11025 -> 105 +precision: 3 +sqtx9004 squareroot 11025 -> 105 +precision: 2 +sqtx9005 squareroot 11025 -> 1.0E+2 Inexact Rounded +precision: 1 +sqtx9006 squareroot 11025 -> 1E+2 Inexact Rounded + +-- Out-of-bounds zeros +precision: 4 +sqtx9010 squareroot 0E-9 -> 0.00000 +sqtx9011 squareroot 0E-10 -> 0.00000 +sqtx9012 squareroot 0E-11 -> 0.000000 +sqtx9013 squareroot 0E-12 -> 0.000000 +sqtx9014 squareroot 0E-13 -> 0E-7 +sqtx9015 squareroot 0E-14 -> 0E-7 +sqtx9020 squareroot 0E-17 -> 0E-9 +sqtx9021 squareroot 0E-20 -> 0E-10 +sqtx9022 squareroot 0E-22 -> 0E-11 +sqtx9023 squareroot 0E-24 -> 0E-12 +sqtx9024 squareroot 0E-25 -> 0E-12 Clamped +sqtx9025 squareroot 0E-26 -> 0E-12 Clamped +sqtx9026 squareroot 0E-27 -> 0E-12 Clamped +sqtx9027 squareroot 0E-28 -> 0E-12 Clamped + +sqtx9030 squareroot 0E+8 -> 0E+4 +sqtx9031 squareroot 0E+10 -> 0E+5 +sqtx9032 squareroot 0E+12 -> 0E+6 +sqtx9033 squareroot 0E+14 -> 0E+7 +sqtx9034 squareroot 0E+15 -> 0E+7 +sqtx9035 squareroot 0E+16 -> 0E+8 +sqtx9036 squareroot 0E+18 -> 0E+9 +sqtx9037 squareroot 0E+19 -> 0E+9 +sqtx9038 squareroot 0E+20 -> 0E+9 Clamped +sqtx9039 squareroot 0E+21 -> 0E+9 Clamped +sqtx9040 squareroot 0E+22 -> 0E+9 Clamped + + -- Null test -sqtx900 squareroot # -> NaN Invalid_operation +sqtx9900 squareroot # -> NaN Invalid_operation Modified: python/branches/release25-maint/Lib/test/decimaltestdata/subtract.decTest ============================================================================== --- python/branches/release25-maint/Lib/test/decimaltestdata/subtract.decTest (original) +++ python/branches/release25-maint/Lib/test/decimaltestdata/subtract.decTest Tue Jan 8 17:20:31 2008 @@ -1,6 +1,6 @@ ------------------------------------------------------------------------ -- subtract.decTest -- decimal subtraction -- --- Copyright (c) IBM Corporation, 1981, 2004. All rights reserved. -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- ------------------------------------------------------------------------ -- Please see the document "General Decimal Arithmetic Testcases" -- -- at http://www2.hursley.ibm.com/decimal for the description of -- @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc at uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.39 +version: 2.57 extended: 1 precision: 9 @@ -805,9 +805,9 @@ subx1015 subtract 0 0.999E-999 -> -1.00E-999 Inexact Rounded Subnormal Underflow subx1016 subtract 0 0.099E-999 -> -1.0E-1000 Inexact Rounded Subnormal Underflow subx1017 subtract 0 0.009E-999 -> -1E-1001 Inexact Rounded Subnormal Underflow -subx1018 subtract 0 0.001E-999 -> -0E-1001 Inexact Rounded Subnormal Underflow -subx1019 subtract 0 0.0009E-999 -> -0E-1001 Inexact Rounded Subnormal Underflow -subx1020 subtract 0 0.0001E-999 -> -0E-1001 Inexact Rounded Subnormal Underflow +subx1018 subtract 0 0.001E-999 -> -0E-1001 Inexact Rounded Subnormal Underflow Clamped +subx1019 subtract 0 0.0009E-999 -> -0E-1001 Inexact Rounded Subnormal Underflow Clamped +subx1020 subtract 0 0.0001E-999 -> -0E-1001 Inexact Rounded Subnormal Underflow Clamped subx1030 subtract 0 -1.00E-999 -> 1.00E-999 subx1031 subtract 0 -0.1E-999 -> 1E-1000 Subnormal @@ -818,9 +818,9 @@ subx1035 subtract 0 -0.999E-999 -> 1.00E-999 Inexact Rounded Subnormal Underflow subx1036 subtract 0 -0.099E-999 -> 1.0E-1000 Inexact Rounded Subnormal Underflow subx1037 subtract 0 -0.009E-999 -> 1E-1001 Inexact Rounded Subnormal Underflow -subx1038 subtract 0 -0.001E-999 -> 0E-1001 Inexact Rounded Subnormal Underflow -subx1039 subtract 0 -0.0009E-999 -> 0E-1001 Inexact Rounded Subnormal Underflow -subx1040 subtract 0 -0.0001E-999 -> 0E-1001 Inexact Rounded Subnormal Underflow +subx1038 subtract 0 -0.001E-999 -> 0E-1001 Inexact Rounded Subnormal Underflow Clamped +subx1039 subtract 0 -0.0009E-999 -> 0E-1001 Inexact Rounded Subnormal Underflow Clamped +subx1040 subtract 0 -0.0001E-999 -> 0E-1001 Inexact Rounded Subnormal Underflow Clamped -- some non-zero subnormal subtracts -- subx1056 is a tricky case @@ -831,7 +831,7 @@ subx1053 subtract 0.100E-999 0.1E-999 -> 0E-1001 Clamped subx1054 subtract 0.01E-999 0.1E-999 -> -9E-1001 Subnormal subx1055 subtract 0.999E-999 0.1E-999 -> 9.0E-1000 Inexact Rounded Subnormal Underflow -subx1056 subtract 0.099E-999 0.1E-999 -> -0E-1001 Inexact Rounded Subnormal Underflow +subx1056 subtract 0.099E-999 0.1E-999 -> -0E-1001 Inexact Rounded Subnormal Underflow Clamped subx1057 subtract 0.009E-999 0.1E-999 -> -9E-1001 Inexact Rounded Subnormal Underflow subx1058 subtract 0.001E-999 0.1E-999 -> -1.0E-1000 Inexact Rounded Subnormal Underflow subx1059 subtract 0.0009E-999 0.1E-999 -> -1.0E-1000 Inexact Rounded Subnormal Underflow @@ -849,15 +849,25 @@ subx1105 subtract 1.52445E-80 0 -> 1.524E-80 Inexact Rounded Subnormal Underflow subx1106 subtract 1.52446E-80 0 -> 1.524E-80 Inexact Rounded Subnormal Underflow -subx1111 subtract 1.2345678E-80 1.2345671E-80 -> 0E-83 Inexact Rounded Subnormal Underflow -subx1112 subtract 1.2345678E-80 1.2345618E-80 -> 0E-83 Inexact Rounded Subnormal Underflow -subx1113 subtract 1.2345678E-80 1.2345178E-80 -> 0E-83 Inexact Rounded Subnormal Underflow -subx1114 subtract 1.2345678E-80 1.2341678E-80 -> 0E-83 Inexact Rounded Subnormal Underflow +subx1111 subtract 1.2345678E-80 1.2345671E-80 -> 0E-83 Inexact Rounded Subnormal Underflow Clamped +subx1112 subtract 1.2345678E-80 1.2345618E-80 -> 0E-83 Inexact Rounded Subnormal Underflow Clamped +subx1113 subtract 1.2345678E-80 1.2345178E-80 -> 0E-83 Inexact Rounded Subnormal Underflow Clamped +subx1114 subtract 1.2345678E-80 1.2341678E-80 -> 0E-83 Inexact Rounded Subnormal Underflow Clamped subx1115 subtract 1.2345678E-80 1.2315678E-80 -> 3E-83 Rounded Subnormal subx1116 subtract 1.2345678E-80 1.2145678E-80 -> 2.0E-82 Rounded Subnormal subx1117 subtract 1.2345678E-80 1.1345678E-80 -> 1.00E-81 Rounded Subnormal subx1118 subtract 1.2345678E-80 0.2345678E-80 -> 1.000E-80 Rounded Subnormal +precision: 34 +rounding: half_up +maxExponent: 6144 +minExponent: -6143 +-- Examples from SQL proposal (Krishna Kulkarni) +subx1125 subtract 130E-2 120E-2 -> 0.10 +subx1126 subtract 130E-2 12E-1 -> 0.10 +subx1127 subtract 130E-2 1E0 -> 0.30 +subx1128 subtract 1E2 1E4 -> -9.9E+3 + -- Null tests subx9990 subtract 10 # -> NaN Invalid_operation subx9991 subtract # 10 -> NaN Invalid_operation Modified: python/branches/release25-maint/Lib/test/decimaltestdata/testall.decTest ============================================================================== --- python/branches/release25-maint/Lib/test/decimaltestdata/testall.decTest (original) +++ python/branches/release25-maint/Lib/test/decimaltestdata/testall.decTest Tue Jan 8 17:20:31 2008 @@ -1,6 +1,6 @@ ------------------------------------------------------------------------ -- testall.decTest -- run all general decimal arithmetic testcases -- --- Copyright (c) IBM Corporation, 1981, 2004. All rights reserved. -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- ------------------------------------------------------------------------ -- Please see the document "General Decimal Arithmetic Testcases" -- -- at http://www2.hursley.ibm.com/decimal for the description of -- @@ -17,41 +17,70 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc at uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.39 +version: 2.57 -- core tests (using Extended: 1) -------------------------------------- dectest: base + dectest: abs dectest: add +dectest: and dectest: clamp +dectest: class dectest: compare +dectest: comparesig +dectest: comparetotal +dectest: comparetotmag +dectest: copy +dectest: copyabs +dectest: copynegate +dectest: copysign dectest: divide dectest: divideint +dectest: exp +dectest: fma dectest: inexact +dectest: invert +dectest: ln +dectest: logb +dectest: log10 dectest: max +dectest: maxmag dectest: min +dectest: minmag dectest: minus dectest: multiply -dectest: normalize +dectest: nextminus +dectest: nextplus +dectest: nexttoward +dectest: or dectest: plus dectest: power +dectest: powersqrt dectest: quantize dectest: randoms +dectest: reduce -- [was called normalize] dectest: remainder dectest: remaindernear dectest: rescale -- [obsolete] +dectest: rotate dectest: rounding dectest: samequantum +dectest: scaleb +dectest: shift dectest: squareroot dectest: subtract dectest: tointegral +dectest: tointegralx dectest: trim +dectest: xor --- The next are for the Strawman 4d concrete representations -dectest: decimal32 -dectest: decimal64 -dectest: decimal128 - +-- The next are for the Strawman 4d concrete representations and +-- tests at those sizes [including dsEncode, ddEncode, and dqEncode, +-- which replace decimal32, decimal64, and decimal128] +dectest: decSingle +dectest: decDouble +dectest: decQuad -- General 31->33-digit boundary tests dectest: randombound32 Modified: python/branches/release25-maint/Lib/test/decimaltestdata/tointegral.decTest ============================================================================== --- python/branches/release25-maint/Lib/test/decimaltestdata/tointegral.decTest (original) +++ python/branches/release25-maint/Lib/test/decimaltestdata/tointegral.decTest Tue Jan 8 17:20:31 2008 @@ -1,6 +1,6 @@ ------------------------------------------------------------------------ -- tointegral.decTest -- round decimal to integral value -- --- Copyright (c) IBM Corporation, 2001, 2003. All rights reserved. -- +-- Copyright (c) IBM Corporation, 2001, 2007. All rights reserved. -- ------------------------------------------------------------------------ -- Please see the document "General Decimal Arithmetic Testcases" -- -- at http://www2.hursley.ibm.com/decimal for the description of -- @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc at uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.39 +version: 2.57 -- This set of tests tests the extended specification 'round-to-integral -- value' operation (from IEEE 854, later modified in 754r). @@ -174,3 +174,68 @@ intx206 tointegral 7.89E+77 -> 7.89E+77 intx207 tointegral -Inf -> -Infinity + +-- all rounding modes +rounding: half_even + +intx210 tointegral 55.5 -> 56 +intx211 tointegral 56.5 -> 56 +intx212 tointegral 57.5 -> 58 +intx213 tointegral -55.5 -> -56 +intx214 tointegral -56.5 -> -56 +intx215 tointegral -57.5 -> -58 + +rounding: half_up + +intx220 tointegral 55.5 -> 56 +intx221 tointegral 56.5 -> 57 +intx222 tointegral 57.5 -> 58 +intx223 tointegral -55.5 -> -56 +intx224 tointegral -56.5 -> -57 +intx225 tointegral -57.5 -> -58 + +rounding: half_down + +intx230 tointegral 55.5 -> 55 +intx231 tointegral 56.5 -> 56 +intx232 tointegral 57.5 -> 57 +intx233 tointegral -55.5 -> -55 +intx234 tointegral -56.5 -> -56 +intx235 tointegral -57.5 -> -57 + +rounding: up + +intx240 tointegral 55.3 -> 56 +intx241 tointegral 56.3 -> 57 +intx242 tointegral 57.3 -> 58 +intx243 tointegral -55.3 -> -56 +intx244 tointegral -56.3 -> -57 +intx245 tointegral -57.3 -> -58 + +rounding: down + +intx250 tointegral 55.7 -> 55 +intx251 tointegral 56.7 -> 56 +intx252 tointegral 57.7 -> 57 +intx253 tointegral -55.7 -> -55 +intx254 tointegral -56.7 -> -56 +intx255 tointegral -57.7 -> -57 + +rounding: ceiling + +intx260 tointegral 55.3 -> 56 +intx261 tointegral 56.3 -> 57 +intx262 tointegral 57.3 -> 58 +intx263 tointegral -55.3 -> -55 +intx264 tointegral -56.3 -> -56 +intx265 tointegral -57.3 -> -57 + +rounding: floor + +intx270 tointegral 55.7 -> 55 +intx271 tointegral 56.7 -> 56 +intx272 tointegral 57.7 -> 57 +intx273 tointegral -55.7 -> -56 +intx274 tointegral -56.7 -> -57 +intx275 tointegral -57.7 -> -58 + Added: python/branches/release25-maint/Lib/test/decimaltestdata/tointegralx.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/tointegralx.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,255 @@ +------------------------------------------------------------------------ +-- tointegralx.decTest -- round decimal to integral value, exact -- +-- Copyright (c) IBM Corporation, 2001, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +-- This set of tests tests the extended specification 'round-to-integral +-- value' operation (from IEEE 854, later modified in 754r). +-- All non-zero results are defined as being those from either copy or +-- quantize, so those are assumed to have been tested. + +-- This tests toIntegraExact, which may set Inexact + +extended: 1 +precision: 9 +rounding: half_up +maxExponent: 999 +minExponent: -999 + +intxx001 tointegralx 0 -> 0 +intxx002 tointegralx 0.0 -> 0 +intxx003 tointegralx 0.1 -> 0 Inexact Rounded +intxx004 tointegralx 0.2 -> 0 Inexact Rounded +intxx005 tointegralx 0.3 -> 0 Inexact Rounded +intxx006 tointegralx 0.4 -> 0 Inexact Rounded +intxx007 tointegralx 0.5 -> 1 Inexact Rounded +intxx008 tointegralx 0.6 -> 1 Inexact Rounded +intxx009 tointegralx 0.7 -> 1 Inexact Rounded +intxx010 tointegralx 0.8 -> 1 Inexact Rounded +intxx011 tointegralx 0.9 -> 1 Inexact Rounded +intxx012 tointegralx 1 -> 1 +intxx013 tointegralx 1.0 -> 1 Rounded +intxx014 tointegralx 1.1 -> 1 Inexact Rounded +intxx015 tointegralx 1.2 -> 1 Inexact Rounded +intxx016 tointegralx 1.3 -> 1 Inexact Rounded +intxx017 tointegralx 1.4 -> 1 Inexact Rounded +intxx018 tointegralx 1.5 -> 2 Inexact Rounded +intxx019 tointegralx 1.6 -> 2 Inexact Rounded +intxx020 tointegralx 1.7 -> 2 Inexact Rounded +intxx021 tointegralx 1.8 -> 2 Inexact Rounded +intxx022 tointegralx 1.9 -> 2 Inexact Rounded +-- negatives +intxx031 tointegralx -0 -> -0 +intxx032 tointegralx -0.0 -> -0 +intxx033 tointegralx -0.1 -> -0 Inexact Rounded +intxx034 tointegralx -0.2 -> -0 Inexact Rounded +intxx035 tointegralx -0.3 -> -0 Inexact Rounded +intxx036 tointegralx -0.4 -> -0 Inexact Rounded +intxx037 tointegralx -0.5 -> -1 Inexact Rounded +intxx038 tointegralx -0.6 -> -1 Inexact Rounded +intxx039 tointegralx -0.7 -> -1 Inexact Rounded +intxx040 tointegralx -0.8 -> -1 Inexact Rounded +intxx041 tointegralx -0.9 -> -1 Inexact Rounded +intxx042 tointegralx -1 -> -1 +intxx043 tointegralx -1.0 -> -1 Rounded +intxx044 tointegralx -1.1 -> -1 Inexact Rounded +intxx045 tointegralx -1.2 -> -1 Inexact Rounded +intxx046 tointegralx -1.3 -> -1 Inexact Rounded +intxx047 tointegralx -1.4 -> -1 Inexact Rounded +intxx048 tointegralx -1.5 -> -2 Inexact Rounded +intxx049 tointegralx -1.6 -> -2 Inexact Rounded +intxx050 tointegralx -1.7 -> -2 Inexact Rounded +intxx051 tointegralx -1.8 -> -2 Inexact Rounded +intxx052 tointegralx -1.9 -> -2 Inexact Rounded +-- next two would be NaN using quantize(x, 0) +intxx053 tointegralx 10E+30 -> 1.0E+31 +intxx054 tointegralx -10E+30 -> -1.0E+31 + +-- numbers around precision +precision: 9 +intxx060 tointegralx '56267E-10' -> '0' Inexact Rounded +intxx061 tointegralx '56267E-5' -> '1' Inexact Rounded +intxx062 tointegralx '56267E-2' -> '563' Inexact Rounded +intxx063 tointegralx '56267E-1' -> '5627' Inexact Rounded +intxx065 tointegralx '56267E-0' -> '56267' +intxx066 tointegralx '56267E+0' -> '56267' +intxx067 tointegralx '56267E+1' -> '5.6267E+5' +intxx068 tointegralx '56267E+2' -> '5.6267E+6' +intxx069 tointegralx '56267E+3' -> '5.6267E+7' +intxx070 tointegralx '56267E+4' -> '5.6267E+8' +intxx071 tointegralx '56267E+5' -> '5.6267E+9' +intxx072 tointegralx '56267E+6' -> '5.6267E+10' +intxx073 tointegralx '1.23E+96' -> '1.23E+96' +intxx074 tointegralx '1.23E+384' -> '1.23E+384' +intxx075 tointegralx '1.23E+999' -> '1.23E+999' + +intxx080 tointegralx '-56267E-10' -> '-0' Inexact Rounded +intxx081 tointegralx '-56267E-5' -> '-1' Inexact Rounded +intxx082 tointegralx '-56267E-2' -> '-563' Inexact Rounded +intxx083 tointegralx '-56267E-1' -> '-5627' Inexact Rounded +intxx085 tointegralx '-56267E-0' -> '-56267' +intxx086 tointegralx '-56267E+0' -> '-56267' +intxx087 tointegralx '-56267E+1' -> '-5.6267E+5' +intxx088 tointegralx '-56267E+2' -> '-5.6267E+6' +intxx089 tointegralx '-56267E+3' -> '-5.6267E+7' +intxx090 tointegralx '-56267E+4' -> '-5.6267E+8' +intxx091 tointegralx '-56267E+5' -> '-5.6267E+9' +intxx092 tointegralx '-56267E+6' -> '-5.6267E+10' +intxx093 tointegralx '-1.23E+96' -> '-1.23E+96' +intxx094 tointegralx '-1.23E+384' -> '-1.23E+384' +intxx095 tointegralx '-1.23E+999' -> '-1.23E+999' + +-- subnormal inputs +intxx100 tointegralx 1E-999 -> 0 Inexact Rounded +intxx101 tointegralx 0.1E-999 -> 0 Inexact Rounded +intxx102 tointegralx 0.01E-999 -> 0 Inexact Rounded +intxx103 tointegralx 0E-999 -> 0 + +-- specials and zeros +intxx120 tointegralx 'Inf' -> Infinity +intxx121 tointegralx '-Inf' -> -Infinity +intxx122 tointegralx NaN -> NaN +intxx123 tointegralx sNaN -> NaN Invalid_operation +intxx124 tointegralx 0 -> 0 +intxx125 tointegralx -0 -> -0 +intxx126 tointegralx 0.000 -> 0 +intxx127 tointegralx 0.00 -> 0 +intxx128 tointegralx 0.0 -> 0 +intxx129 tointegralx 0 -> 0 +intxx130 tointegralx 0E-3 -> 0 +intxx131 tointegralx 0E-2 -> 0 +intxx132 tointegralx 0E-1 -> 0 +intxx133 tointegralx 0E-0 -> 0 +intxx134 tointegralx 0E+1 -> 0E+1 +intxx135 tointegralx 0E+2 -> 0E+2 +intxx136 tointegralx 0E+3 -> 0E+3 +intxx137 tointegralx 0E+4 -> 0E+4 +intxx138 tointegralx 0E+5 -> 0E+5 +intxx139 tointegralx -0.000 -> -0 +intxx140 tointegralx -0.00 -> -0 +intxx141 tointegralx -0.0 -> -0 +intxx142 tointegralx -0 -> -0 +intxx143 tointegralx -0E-3 -> -0 +intxx144 tointegralx -0E-2 -> -0 +intxx145 tointegralx -0E-1 -> -0 +intxx146 tointegralx -0E-0 -> -0 +intxx147 tointegralx -0E+1 -> -0E+1 +intxx148 tointegralx -0E+2 -> -0E+2 +intxx149 tointegralx -0E+3 -> -0E+3 +intxx150 tointegralx -0E+4 -> -0E+4 +intxx151 tointegralx -0E+5 -> -0E+5 +-- propagating NaNs +intxx152 tointegralx NaN808 -> NaN808 +intxx153 tointegralx sNaN080 -> NaN80 Invalid_operation +intxx154 tointegralx -NaN808 -> -NaN808 +intxx155 tointegralx -sNaN080 -> -NaN80 Invalid_operation +intxx156 tointegralx -NaN -> -NaN +intxx157 tointegralx -sNaN -> -NaN Invalid_operation + +-- examples +rounding: half_up +precision: 9 +intxx200 tointegralx 2.1 -> 2 Inexact Rounded +intxx201 tointegralx 100 -> 100 +intxx202 tointegralx 100.0 -> 100 Rounded +intxx203 tointegralx 101.5 -> 102 Inexact Rounded +intxx204 tointegralx -101.5 -> -102 Inexact Rounded +intxx205 tointegralx 10E+5 -> 1.0E+6 +intxx206 tointegralx 7.89E+77 -> 7.89E+77 +intxx207 tointegralx -Inf -> -Infinity + + +-- all rounding modes +rounding: half_even + +intxx210 tointegralx 55.5 -> 56 Inexact Rounded +intxx211 tointegralx 56.5 -> 56 Inexact Rounded +intxx212 tointegralx 57.5 -> 58 Inexact Rounded +intxx213 tointegralx -55.5 -> -56 Inexact Rounded +intxx214 tointegralx -56.5 -> -56 Inexact Rounded +intxx215 tointegralx -57.5 -> -58 Inexact Rounded + +rounding: half_up + +intxx220 tointegralx 55.5 -> 56 Inexact Rounded +intxx221 tointegralx 56.5 -> 57 Inexact Rounded +intxx222 tointegralx 57.5 -> 58 Inexact Rounded +intxx223 tointegralx -55.5 -> -56 Inexact Rounded +intxx224 tointegralx -56.5 -> -57 Inexact Rounded +intxx225 tointegralx -57.5 -> -58 Inexact Rounded + +rounding: half_down + +intxx230 tointegralx 55.5 -> 55 Inexact Rounded +intxx231 tointegralx 56.5 -> 56 Inexact Rounded +intxx232 tointegralx 57.5 -> 57 Inexact Rounded +intxx233 tointegralx -55.5 -> -55 Inexact Rounded +intxx234 tointegralx -56.5 -> -56 Inexact Rounded +intxx235 tointegralx -57.5 -> -57 Inexact Rounded + +rounding: up + +intxx240 tointegralx 55.3 -> 56 Inexact Rounded +intxx241 tointegralx 56.3 -> 57 Inexact Rounded +intxx242 tointegralx 57.3 -> 58 Inexact Rounded +intxx243 tointegralx -55.3 -> -56 Inexact Rounded +intxx244 tointegralx -56.3 -> -57 Inexact Rounded +intxx245 tointegralx -57.3 -> -58 Inexact Rounded + +rounding: down + +intxx250 tointegralx 55.7 -> 55 Inexact Rounded +intxx251 tointegralx 56.7 -> 56 Inexact Rounded +intxx252 tointegralx 57.7 -> 57 Inexact Rounded +intxx253 tointegralx -55.7 -> -55 Inexact Rounded +intxx254 tointegralx -56.7 -> -56 Inexact Rounded +intxx255 tointegralx -57.7 -> -57 Inexact Rounded + +rounding: ceiling + +intxx260 tointegralx 55.3 -> 56 Inexact Rounded +intxx261 tointegralx 56.3 -> 57 Inexact Rounded +intxx262 tointegralx 57.3 -> 58 Inexact Rounded +intxx263 tointegralx -55.3 -> -55 Inexact Rounded +intxx264 tointegralx -56.3 -> -56 Inexact Rounded +intxx265 tointegralx -57.3 -> -57 Inexact Rounded + +rounding: floor + +intxx270 tointegralx 55.7 -> 55 Inexact Rounded +intxx271 tointegralx 56.7 -> 56 Inexact Rounded +intxx272 tointegralx 57.7 -> 57 Inexact Rounded +intxx273 tointegralx -55.7 -> -56 Inexact Rounded +intxx274 tointegralx -56.7 -> -57 Inexact Rounded +intxx275 tointegralx -57.7 -> -58 Inexact Rounded + +-- Int and uInt32 edge values for testing conversions +precision: 16 +intxx300 tointegralx -2147483646 -> -2147483646 +intxx301 tointegralx -2147483647 -> -2147483647 +intxx302 tointegralx -2147483648 -> -2147483648 +intxx303 tointegralx -2147483649 -> -2147483649 +intxx304 tointegralx 2147483646 -> 2147483646 +intxx305 tointegralx 2147483647 -> 2147483647 +intxx306 tointegralx 2147483648 -> 2147483648 +intxx307 tointegralx 2147483649 -> 2147483649 +intxx308 tointegralx 4294967294 -> 4294967294 +intxx309 tointegralx 4294967295 -> 4294967295 +intxx310 tointegralx 4294967296 -> 4294967296 +intxx311 tointegralx 4294967297 -> 4294967297 Added: python/branches/release25-maint/Lib/test/decimaltestdata/xor.decTest ============================================================================== --- (empty file) +++ python/branches/release25-maint/Lib/test/decimaltestdata/xor.decTest Tue Jan 8 17:20:31 2008 @@ -0,0 +1,335 @@ +------------------------------------------------------------------------ +-- xor.decTest -- digitwise logical XOR -- +-- Copyright (c) IBM Corporation, 1981, 2007. All rights reserved. -- +------------------------------------------------------------------------ +-- Please see the document "General Decimal Arithmetic Testcases" -- +-- at http://www2.hursley.ibm.com/decimal for the description of -- +-- these testcases. -- +-- -- +-- These testcases are experimental ('beta' versions), and they -- +-- may contain errors. They are offered on an as-is basis. In -- +-- particular, achieving the same results as the tests here is not -- +-- a guarantee that an implementation complies with any Standard -- +-- or specification. The tests are not exhaustive. -- +-- -- +-- Please send comments, suggestions, and corrections to the author: -- +-- Mike Cowlishaw, IBM Fellow -- +-- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- +-- mfc at uk.ibm.com -- +------------------------------------------------------------------------ +version: 2.57 + +extended: 1 +precision: 9 +rounding: half_up +maxExponent: 999 +minExponent: -999 + +-- Sanity check (truth table) +xorx001 xor 0 0 -> 0 +xorx002 xor 0 1 -> 1 +xorx003 xor 1 0 -> 1 +xorx004 xor 1 1 -> 0 +xorx005 xor 1100 1010 -> 110 +xorx006 xor 1111 10 -> 1101 +-- and at msd and msd-1 +xorx010 xor 000000000 000000000 -> 0 +xorx011 xor 000000000 100000000 -> 100000000 +xorx012 xor 100000000 000000000 -> 100000000 +xorx013 xor 100000000 100000000 -> 0 +xorx014 xor 000000000 000000000 -> 0 +xorx015 xor 000000000 010000000 -> 10000000 +xorx016 xor 010000000 000000000 -> 10000000 +xorx017 xor 010000000 010000000 -> 0 + +-- Various lengths +-- 123456789 123456789 123456789 +xorx021 xor 111111111 111111111 -> 0 +xorx022 xor 111111111111 111111111 -> 0 +xorx023 xor 11111111 11111111 -> 0 +xorx025 xor 1111111 1111111 -> 0 +xorx026 xor 111111 111111 -> 0 +xorx027 xor 11111 11111 -> 0 +xorx028 xor 1111 1111 -> 0 +xorx029 xor 111 111 -> 0 +xorx031 xor 11 11 -> 0 +xorx032 xor 1 1 -> 0 +xorx033 xor 111111111111 1111111111 -> 0 +xorx034 xor 11111111111 11111111111 -> 0 +xorx035 xor 1111111111 111111111111 -> 0 +xorx036 xor 111111111 1111111111111 -> 0 + +xorx040 xor 111111111 111111111111 -> 0 +xorx041 xor 11111111 111111111111 -> 100000000 +xorx042 xor 11111111 111111111 -> 100000000 +xorx043 xor 1111111 100000010 -> 101111101 +xorx044 xor 111111 100000100 -> 100111011 +xorx045 xor 11111 100001000 -> 100010111 +xorx046 xor 1111 100010000 -> 100011111 +xorx047 xor 111 100100000 -> 100100111 +xorx048 xor 11 101000000 -> 101000011 +xorx049 xor 1 110000000 -> 110000001 + +xorx050 xor 1111111111 1 -> 111111110 +xorx051 xor 111111111 1 -> 111111110 +xorx052 xor 11111111 1 -> 11111110 +xorx053 xor 1111111 1 -> 1111110 +xorx054 xor 111111 1 -> 111110 +xorx055 xor 11111 1 -> 11110 +xorx056 xor 1111 1 -> 1110 +xorx057 xor 111 1 -> 110 +xorx058 xor 11 1 -> 10 +xorx059 xor 1 1 -> 0 + +xorx060 xor 1111111111 0 -> 111111111 +xorx061 xor 111111111 0 -> 111111111 +xorx062 xor 11111111 0 -> 11111111 +xorx063 xor 1111111 0 -> 1111111 +xorx064 xor 111111 0 -> 111111 +xorx065 xor 11111 0 -> 11111 +xorx066 xor 1111 0 -> 1111 +xorx067 xor 111 0 -> 111 +xorx068 xor 11 0 -> 11 +xorx069 xor 1 0 -> 1 + +xorx070 xor 1 1111111111 -> 111111110 +xorx071 xor 1 111111111 -> 111111110 +xorx072 xor 1 11111111 -> 11111110 +xorx073 xor 1 1111111 -> 1111110 +xorx074 xor 1 111111 -> 111110 +xorx075 xor 1 11111 -> 11110 +xorx076 xor 1 1111 -> 1110 +xorx077 xor 1 111 -> 110 +xorx078 xor 1 11 -> 10 +xorx079 xor 1 1 -> 0 + +xorx080 xor 0 1111111111 -> 111111111 +xorx081 xor 0 111111111 -> 111111111 +xorx082 xor 0 11111111 -> 11111111 +xorx083 xor 0 1111111 -> 1111111 +xorx084 xor 0 111111 -> 111111 +xorx085 xor 0 11111 -> 11111 +xorx086 xor 0 1111 -> 1111 +xorx087 xor 0 111 -> 111 +xorx088 xor 0 11 -> 11 +xorx089 xor 0 1 -> 1 + +xorx090 xor 011111111 111101111 -> 100010000 +xorx091 xor 101111111 111101111 -> 10010000 +xorx092 xor 110111111 111101111 -> 1010000 +xorx093 xor 111011111 111101111 -> 110000 +xorx094 xor 111101111 111101111 -> 0 +xorx095 xor 111110111 111101111 -> 11000 +xorx096 xor 111111011 111101111 -> 10100 +xorx097 xor 111111101 111101111 -> 10010 +xorx098 xor 111111110 111101111 -> 10001 + +xorx100 xor 111101111 011111111 -> 100010000 +xorx101 xor 111101111 101111111 -> 10010000 +xorx102 xor 111101111 110111111 -> 1010000 +xorx103 xor 111101111 111011111 -> 110000 +xorx104 xor 111101111 111101111 -> 0 +xorx105 xor 111101111 111110111 -> 11000 +xorx106 xor 111101111 111111011 -> 10100 +xorx107 xor 111101111 111111101 -> 10010 +xorx108 xor 111101111 111111110 -> 10001 + +-- non-0/1 should not be accepted, nor should signs +xorx220 xor 111111112 111111111 -> NaN Invalid_operation +xorx221 xor 333333333 333333333 -> NaN Invalid_operation +xorx222 xor 555555555 555555555 -> NaN Invalid_operation +xorx223 xor 777777777 777777777 -> NaN Invalid_operation +xorx224 xor 999999999 999999999 -> NaN Invalid_operation +xorx225 xor 222222222 999999999 -> NaN Invalid_operation +xorx226 xor 444444444 999999999 -> NaN Invalid_operation +xorx227 xor 666666666 999999999 -> NaN Invalid_operation +xorx228 xor 888888888 999999999 -> NaN Invalid_operation +xorx229 xor 999999999 222222222 -> NaN Invalid_operation +xorx230 xor 999999999 444444444 -> NaN Invalid_operation +xorx231 xor 999999999 666666666 -> NaN Invalid_operation +xorx232 xor 999999999 888888888 -> NaN Invalid_operation +-- a few randoms +xorx240 xor 567468689 -934981942 -> NaN Invalid_operation +xorx241 xor 567367689 934981942 -> NaN Invalid_operation +xorx242 xor -631917772 -706014634 -> NaN Invalid_operation +xorx243 xor -756253257 138579234 -> NaN Invalid_operation +xorx244 xor 835590149 567435400 -> NaN Invalid_operation +-- test MSD +xorx250 xor 200000000 100000000 -> NaN Invalid_operation +xorx251 xor 700000000 100000000 -> NaN Invalid_operation +xorx252 xor 800000000 100000000 -> NaN Invalid_operation +xorx253 xor 900000000 100000000 -> NaN Invalid_operation +xorx254 xor 200000000 000000000 -> NaN Invalid_operation +xorx255 xor 700000000 000000000 -> NaN Invalid_operation +xorx256 xor 800000000 000000000 -> NaN Invalid_operation +xorx257 xor 900000000 000000000 -> NaN Invalid_operation +xorx258 xor 100000000 200000000 -> NaN Invalid_operation +xorx259 xor 100000000 700000000 -> NaN Invalid_operation +xorx260 xor 100000000 800000000 -> NaN Invalid_operation +xorx261 xor 100000000 900000000 -> NaN Invalid_operation +xorx262 xor 000000000 200000000 -> NaN Invalid_operation +xorx263 xor 000000000 700000000 -> NaN Invalid_operation +xorx264 xor 000000000 800000000 -> NaN Invalid_operation +xorx265 xor 000000000 900000000 -> NaN Invalid_operation +-- test MSD-1 +xorx270 xor 020000000 100000000 -> NaN Invalid_operation +xorx271 xor 070100000 100000000 -> NaN Invalid_operation +xorx272 xor 080010000 100000001 -> NaN Invalid_operation +xorx273 xor 090001000 100000010 -> NaN Invalid_operation +xorx274 xor 100000100 020010100 -> NaN Invalid_operation +xorx275 xor 100000000 070001000 -> NaN Invalid_operation +xorx276 xor 100000010 080010100 -> NaN Invalid_operation +xorx277 xor 100000000 090000010 -> NaN Invalid_operation +-- test LSD +xorx280 xor 001000002 100000000 -> NaN Invalid_operation +xorx281 xor 000000007 100000000 -> NaN Invalid_operation +xorx282 xor 000000008 100000000 -> NaN Invalid_operation +xorx283 xor 000000009 100000000 -> NaN Invalid_operation +xorx284 xor 100000000 000100002 -> NaN Invalid_operation +xorx285 xor 100100000 001000007 -> NaN Invalid_operation +xorx286 xor 100010000 010000008 -> NaN Invalid_operation +xorx287 xor 100001000 100000009 -> NaN Invalid_operation +-- test Middie +xorx288 xor 001020000 100000000 -> NaN Invalid_operation +xorx289 xor 000070001 100000000 -> NaN Invalid_operation +xorx290 xor 000080000 100010000 -> NaN Invalid_operation +xorx291 xor 000090000 100001000 -> NaN Invalid_operation +xorx292 xor 100000010 000020100 -> NaN Invalid_operation +xorx293 xor 100100000 000070010 -> NaN Invalid_operation +xorx294 xor 100010100 000080001 -> NaN Invalid_operation +xorx295 xor 100001000 000090000 -> NaN Invalid_operation +-- signs +xorx296 xor -100001000 -000000000 -> NaN Invalid_operation +xorx297 xor -100001000 000010000 -> NaN Invalid_operation +xorx298 xor 100001000 -000000000 -> NaN Invalid_operation +xorx299 xor 100001000 000011000 -> 100010000 + +-- Nmax, Nmin, Ntiny +xorx331 xor 2 9.99999999E+999 -> NaN Invalid_operation +xorx332 xor 3 1E-999 -> NaN Invalid_operation +xorx333 xor 4 1.00000000E-999 -> NaN Invalid_operation +xorx334 xor 5 1E-1007 -> NaN Invalid_operation +xorx335 xor 6 -1E-1007 -> NaN Invalid_operation +xorx336 xor 7 -1.00000000E-999 -> NaN Invalid_operation +xorx337 xor 8 -1E-999 -> NaN Invalid_operation +xorx338 xor 9 -9.99999999E+999 -> NaN Invalid_operation +xorx341 xor 9.99999999E+999 -18 -> NaN Invalid_operation +xorx342 xor 1E-999 01 -> NaN Invalid_operation +xorx343 xor 1.00000000E-999 -18 -> NaN Invalid_operation +xorx344 xor 1E-1007 18 -> NaN Invalid_operation +xorx345 xor -1E-1007 -10 -> NaN Invalid_operation +xorx346 xor -1.00000000E-999 18 -> NaN Invalid_operation +xorx347 xor -1E-999 10 -> NaN Invalid_operation +xorx348 xor -9.99999999E+999 -18 -> NaN Invalid_operation + +-- A few other non-integers +xorx361 xor 1.0 1 -> NaN Invalid_operation +xorx362 xor 1E+1 1 -> NaN Invalid_operation +xorx363 xor 0.0 1 -> NaN Invalid_operation +xorx364 xor 0E+1 1 -> NaN Invalid_operation +xorx365 xor 9.9 1 -> NaN Invalid_operation +xorx366 xor 9E+1 1 -> NaN Invalid_operation +xorx371 xor 0 1.0 -> NaN Invalid_operation +xorx372 xor 0 1E+1 -> NaN Invalid_operation +xorx373 xor 0 0.0 -> NaN Invalid_operation +xorx374 xor 0 0E+1 -> NaN Invalid_operation +xorx375 xor 0 9.9 -> NaN Invalid_operation +xorx376 xor 0 9E+1 -> NaN Invalid_operation + +-- All Specials are in error +xorx780 xor -Inf -Inf -> NaN Invalid_operation +xorx781 xor -Inf -1000 -> NaN Invalid_operation +xorx782 xor -Inf -1 -> NaN Invalid_operation +xorx783 xor -Inf -0 -> NaN Invalid_operation +xorx784 xor -Inf 0 -> NaN Invalid_operation +xorx785 xor -Inf 1 -> NaN Invalid_operation +xorx786 xor -Inf 1000 -> NaN Invalid_operation +xorx787 xor -1000 -Inf -> NaN Invalid_operation +xorx788 xor -Inf -Inf -> NaN Invalid_operation +xorx789 xor -1 -Inf -> NaN Invalid_operation +xorx790 xor -0 -Inf -> NaN Invalid_operation +xorx791 xor 0 -Inf -> NaN Invalid_operation +xorx792 xor 1 -Inf -> NaN Invalid_operation +xorx793 xor 1000 -Inf -> NaN Invalid_operation +xorx794 xor Inf -Inf -> NaN Invalid_operation + +xorx800 xor Inf -Inf -> NaN Invalid_operation +xorx801 xor Inf -1000 -> NaN Invalid_operation +xorx802 xor Inf -1 -> NaN Invalid_operation +xorx803 xor Inf -0 -> NaN Invalid_operation +xorx804 xor Inf 0 -> NaN Invalid_operation +xorx805 xor Inf 1 -> NaN Invalid_operation +xorx806 xor Inf 1000 -> NaN Invalid_operation +xorx807 xor Inf Inf -> NaN Invalid_operation +xorx808 xor -1000 Inf -> NaN Invalid_operation +xorx809 xor -Inf Inf -> NaN Invalid_operation +xorx810 xor -1 Inf -> NaN Invalid_operation +xorx811 xor -0 Inf -> NaN Invalid_operation +xorx812 xor 0 Inf -> NaN Invalid_operation +xorx813 xor 1 Inf -> NaN Invalid_operation +xorx814 xor 1000 Inf -> NaN Invalid_operation +xorx815 xor Inf Inf -> NaN Invalid_operation + +xorx821 xor NaN -Inf -> NaN Invalid_operation +xorx822 xor NaN -1000 -> NaN Invalid_operation +xorx823 xor NaN -1 -> NaN Invalid_operation +xorx824 xor NaN -0 -> NaN Invalid_operation +xorx825 xor NaN 0 -> NaN Invalid_operation +xorx826 xor NaN 1 -> NaN Invalid_operation +xorx827 xor NaN 1000 -> NaN Invalid_operation +xorx828 xor NaN Inf -> NaN Invalid_operation +xorx829 xor NaN NaN -> NaN Invalid_operation +xorx830 xor -Inf NaN -> NaN Invalid_operation +xorx831 xor -1000 NaN -> NaN Invalid_operation +xorx832 xor -1 NaN -> NaN Invalid_operation +xorx833 xor -0 NaN -> NaN Invalid_operation +xorx834 xor 0 NaN -> NaN Invalid_operation +xorx835 xor 1 NaN -> NaN Invalid_operation +xorx836 xor 1000 NaN -> NaN Invalid_operation +xorx837 xor Inf NaN -> NaN Invalid_operation + +xorx841 xor sNaN -Inf -> NaN Invalid_operation +xorx842 xor sNaN -1000 -> NaN Invalid_operation +xorx843 xor sNaN -1 -> NaN Invalid_operation +xorx844 xor sNaN -0 -> NaN Invalid_operation +xorx845 xor sNaN 0 -> NaN Invalid_operation +xorx846 xor sNaN 1 -> NaN Invalid_operation +xorx847 xor sNaN 1000 -> NaN Invalid_operation +xorx848 xor sNaN NaN -> NaN Invalid_operation +xorx849 xor sNaN sNaN -> NaN Invalid_operation +xorx850 xor NaN sNaN -> NaN Invalid_operation +xorx851 xor -Inf sNaN -> NaN Invalid_operation +xorx852 xor -1000 sNaN -> NaN Invalid_operation +xorx853 xor -1 sNaN -> NaN Invalid_operation +xorx854 xor -0 sNaN -> NaN Invalid_operation +xorx855 xor 0 sNaN -> NaN Invalid_operation +xorx856 xor 1 sNaN -> NaN Invalid_operation +xorx857 xor 1000 sNaN -> NaN Invalid_operation +xorx858 xor Inf sNaN -> NaN Invalid_operation +xorx859 xor NaN sNaN -> NaN Invalid_operation + +-- propagating NaNs +xorx861 xor NaN1 -Inf -> NaN Invalid_operation +xorx862 xor +NaN2 -1000 -> NaN Invalid_operation +xorx863 xor NaN3 1000 -> NaN Invalid_operation +xorx864 xor NaN4 Inf -> NaN Invalid_operation +xorx865 xor NaN5 +NaN6 -> NaN Invalid_operation +xorx866 xor -Inf NaN7 -> NaN Invalid_operation +xorx867 xor -1000 NaN8 -> NaN Invalid_operation +xorx868 xor 1000 NaN9 -> NaN Invalid_operation +xorx869 xor Inf +NaN10 -> NaN Invalid_operation +xorx871 xor sNaN11 -Inf -> NaN Invalid_operation +xorx872 xor sNaN12 -1000 -> NaN Invalid_operation +xorx873 xor sNaN13 1000 -> NaN Invalid_operation +xorx874 xor sNaN14 NaN17 -> NaN Invalid_operation +xorx875 xor sNaN15 sNaN18 -> NaN Invalid_operation +xorx876 xor NaN16 sNaN19 -> NaN Invalid_operation +xorx877 xor -Inf +sNaN20 -> NaN Invalid_operation +xorx878 xor -1000 sNaN21 -> NaN Invalid_operation +xorx879 xor 1000 sNaN22 -> NaN Invalid_operation +xorx880 xor Inf sNaN23 -> NaN Invalid_operation +xorx881 xor +NaN25 +sNaN24 -> NaN Invalid_operation +xorx882 xor -NaN26 NaN28 -> NaN Invalid_operation +xorx883 xor -sNaN27 sNaN29 -> NaN Invalid_operation +xorx884 xor 1000 -NaN30 -> NaN Invalid_operation +xorx885 xor 1000 -sNaN31 -> NaN Invalid_operation Modified: python/branches/release25-maint/Lib/test/test_decimal.py ============================================================================== --- python/branches/release25-maint/Lib/test/test_decimal.py (original) +++ python/branches/release25-maint/Lib/test/test_decimal.py Tue Jan 8 17:20:31 2008 @@ -65,9 +65,7 @@ # Slower, since it runs some things several times. EXTENDEDERRORTEST = False - #Map the test cases' error names to the actual errors - ErrorNames = {'clamped' : Clamped, 'conversion_syntax' : InvalidOperation, 'division_by_zero' : DivisionByZero, @@ -92,20 +90,88 @@ 'half_down' : ROUND_HALF_DOWN, 'half_even' : ROUND_HALF_EVEN, 'half_up' : ROUND_HALF_UP, - 'up' : ROUND_UP} + 'up' : ROUND_UP, + '05up' : ROUND_05UP} # Name adapter to be able to change the Decimal and Context # interface without changing the test files from Cowlishaw -nameAdapter = {'toeng':'to_eng_string', - 'tosci':'to_sci_string', - 'samequantum':'same_quantum', - 'tointegral':'to_integral', - 'remaindernear':'remainder_near', +nameAdapter = {'and':'logical_and', + 'apply':'_apply', + 'class':'number_class', + 'comparesig':'compare_signal', + 'comparetotal':'compare_total', + 'comparetotmag':'compare_total_mag', + 'copy':'copy_decimal', + 'copyabs':'copy_abs', + 'copynegate':'copy_negate', + 'copysign':'copy_sign', 'divideint':'divide_int', + 'invert':'logical_invert', + 'iscanonical':'is_canonical', + 'isfinite':'is_finite', + 'isinfinite':'is_infinite', + 'isnan':'is_nan', + 'isnormal':'is_normal', + 'isqnan':'is_qnan', + 'issigned':'is_signed', + 'issnan':'is_snan', + 'issubnormal':'is_subnormal', + 'iszero':'is_zero', + 'maxmag':'max_mag', + 'minmag':'min_mag', + 'nextminus':'next_minus', + 'nextplus':'next_plus', + 'nexttoward':'next_toward', + 'or':'logical_or', + 'reduce':'normalize', + 'remaindernear':'remainder_near', + 'samequantum':'same_quantum', 'squareroot':'sqrt', - 'apply':'_apply', + 'toeng':'to_eng_string', + 'tointegral':'to_integral_value', + 'tointegralx':'to_integral_exact', + 'tosci':'to_sci_string', + 'xor':'logical_xor', } +# The following functions return True/False rather than a Decimal instance + +LOGICAL_FUNCTIONS = ( + 'is_canonical', + 'is_finite', + 'is_infinite', + 'is_nan', + 'is_normal', + 'is_qnan', + 'is_signed', + 'is_snan', + 'is_subnormal', + 'is_zero', + 'same_quantum', + ) + +# For some operations (currently exp, ln, log10, power), the decNumber +# reference implementation imposes additional restrictions on the +# context and operands. These restrictions are not part of the +# specification; however, the effect of these restrictions does show +# up in some of the testcases. We skip testcases that violate these +# restrictions, since Decimal behaves differently from decNumber for +# these testcases so these testcases would otherwise fail. + +decNumberRestricted = ('power', 'ln', 'log10', 'exp') +DEC_MAX_MATH = 999999 +def outside_decNumber_bounds(v, context): + if (context.prec > DEC_MAX_MATH or + context.Emax > DEC_MAX_MATH or + -context.Emin > DEC_MAX_MATH): + return True + if not v._is_special and v and ( + len(v._int) > DEC_MAX_MATH or + v.adjusted() > DEC_MAX_MATH or + v.adjusted() < 1-2*DEC_MAX_MATH): + return True + return False + class DecimalTest(unittest.TestCase): """Class which tests the Decimal class against the test cases. @@ -142,10 +208,6 @@ #print line try: t = self.eval_line(line) - except InvalidOperation: - print 'Error in test cases:' - print line - continue except DecimalException, exception: #Exception raised where there shoudn't have been one. self.fail('Exception "'+exception.__class__.__name__ + '" raised on line '+line) @@ -194,7 +256,8 @@ Sides = s.split('->') L = Sides[0].strip().split() id = L[0] -# print id, + if DEBUG: + print "Test ", id, funct = L[1].lower() valstemp = L[2:] L = Sides[1].strip().split() @@ -246,11 +309,27 @@ self.context.traps[error] = 0 v = self.context.create_decimal(v) else: - v = Decimal(v) + v = Decimal(v, self.context) vals.append(v) ans = FixQuotes(ans) + # skip tests that are related to bounds imposed in the decNumber + # reference implementation + if fname in decNumberRestricted: + if fname == 'power': + if not (vals[1]._isinteger() and + -1999999997 <= vals[1] <= 999999999): + if outside_decNumber_bounds(vals[0], self.context) or \ + outside_decNumber_bounds(vals[1], self.context): + #print "Skipping test %s" % s + return + else: + if outside_decNumber_bounds(vals[0], self.context): + #print "Skipping test %s" % s + return + + if EXTENDEDERRORTEST and fname not in ('to_sci_string', 'to_eng_string'): for error in theirexceptions: self.context.traps[error] = 1 @@ -264,9 +343,11 @@ else: self.fail("Did not raise %s in %s" % (error, s)) self.context.traps[error] = 0 + if DEBUG: + print "--", self.context try: result = str(funct(*vals)) - if fname == 'same_quantum': + if fname in LOGICAL_FUNCTIONS: result = str(int(eval(result))) # 'True', 'False' -> '1', '0' except Signals, error: self.fail("Raised %s in %s" % (error, s)) @@ -283,8 +364,7 @@ self.assertEqual(result, ans, 'Incorrect answer for ' + s + ' -- got ' + result) self.assertEqual(myexceptions, theirexceptions, - 'Incorrect flags set in ' + s + ' -- got ' \ - + str(myexceptions)) + 'Incorrect flags set in ' + s + ' -- got ' + str(myexceptions)) return def getexceptions(self): @@ -301,17 +381,6 @@ def change_clamp(self, clamp): self.context._clamp = clamp -# Dynamically build custom test definition for each file in the test -# directory and add the definitions to the DecimalTest class. This -# procedure insures that new files do not get skipped. -for filename in os.listdir(directory): - if '.decTest' not in filename: - continue - head, tail = filename.split('.') - tester = lambda self, f=filename: self.eval_file(directory + f) - setattr(DecimalTest, 'test_' + head, tester) - del filename, head, tail, tester - # The following classes test the behaviour of Decimal according to PEP 327 @@ -383,13 +452,19 @@ #bad sign self.assertRaises(ValueError, Decimal, (8, (4, 3, 4, 9, 1), 2) ) + self.assertRaises(ValueError, Decimal, (0., (4, 3, 4, 9, 1), 2) ) + self.assertRaises(ValueError, Decimal, (Decimal(1), (4, 3, 4, 9, 1), 2)) #bad exp self.assertRaises(ValueError, Decimal, (1, (4, 3, 4, 9, 1), 'wrong!') ) + self.assertRaises(ValueError, Decimal, (1, (4, 3, 4, 9, 1), 0.) ) + self.assertRaises(ValueError, Decimal, (1, (4, 3, 4, 9, 1), '1') ) #bad coefficients self.assertRaises(ValueError, Decimal, (1, (4, 3, 4, None, 1), 2) ) self.assertRaises(ValueError, Decimal, (1, (4, -3, 4, 9, 1), 2) ) + self.assertRaises(ValueError, Decimal, (1, (4, 10, 4, 9, 1), 2) ) + self.assertRaises(ValueError, Decimal, (1, (4, 3, 4, 'a', 1), 2) ) def test_explicit_from_Decimal(self): @@ -803,7 +878,7 @@ th2.start() self.finish1.wait() - self.finish1.wait() + self.finish2.wait() return if threading is None: @@ -853,6 +928,10 @@ a.sort() self.assertEqual(a, b) + # with None + self.assertFalse(Decimal(1) < None) + self.assertTrue(Decimal(1) > None) + def test_copy_and_deepcopy_methods(self): d = Decimal('43.24') c = copy.copy(d) @@ -863,12 +942,54 @@ def test_hash_method(self): #just that it's hashable hash(Decimal(23)) + + test_values = [Decimal(sign*(2**m + n)) + for m in [0, 14, 15, 16, 17, 30, 31, + 32, 33, 62, 63, 64, 65, 66] + for n in range(-10, 10) + for sign in [-1, 1]] + test_values.extend([ + Decimal("-0"), # zeros + Decimal("0.00"), + Decimal("-0.000"), + Decimal("0E10"), + Decimal("-0E12"), + Decimal("10.0"), # negative exponent + Decimal("-23.00000"), + Decimal("1230E100"), # positive exponent + Decimal("-4.5678E50"), + # a value for which hash(n) != hash(n % (2**64-1)) + # in Python pre-2.6 + Decimal(2**64 + 2**32 - 1), + ]) + + # check that hash(d) == hash(int(d)) for integral values + for value in test_values: + self.assertEqual(hash(value), hash(int(value))) + #the same hash that to an int self.assertEqual(hash(Decimal(23)), hash(23)) self.assertRaises(TypeError, hash, Decimal('NaN')) self.assert_(hash(Decimal('Inf'))) self.assert_(hash(Decimal('-Inf'))) + # check that the value of the hash doesn't depend on the + # current context (issue #1757) + c = getcontext() + old_precision = c.prec + x = Decimal("123456789.1") + + c.prec = 6 + h1 = hash(x) + c.prec = 10 + h2 = hash(x) + c.prec = 16 + h3 = hash(x) + + self.assertEqual(h1, h2) + self.assertEqual(h1, h3) + c.prec = old_precision + def test_min_and_max_methods(self): d1 = Decimal('15.32') @@ -955,13 +1076,35 @@ d = Decimal("Infinity") self.assertEqual(d.as_tuple(), (0, (0,), 'F') ) + #leading zeros in coefficient should be stripped + d = Decimal( (0, (0, 0, 4, 0, 5, 3, 4), -2) ) + self.assertEqual(d.as_tuple(), (0, (4, 0, 5, 3, 4), -2) ) + d = Decimal( (1, (0, 0, 0), 37) ) + self.assertEqual(d.as_tuple(), (1, (0,), 37)) + d = Decimal( (1, (), 37) ) + self.assertEqual(d.as_tuple(), (1, (0,), 37)) + + #leading zeros in NaN diagnostic info should be stripped + d = Decimal( (0, (0, 0, 4, 0, 5, 3, 4), 'n') ) + self.assertEqual(d.as_tuple(), (0, (4, 0, 5, 3, 4), 'n') ) + d = Decimal( (1, (0, 0, 0), 'N') ) + self.assertEqual(d.as_tuple(), (1, (), 'N') ) + d = Decimal( (1, (), 'n') ) + self.assertEqual(d.as_tuple(), (1, (), 'n') ) + + #coefficient in infinity should be ignored + d = Decimal( (0, (4, 5, 3, 4), 'F') ) + self.assertEqual(d.as_tuple(), (0, (0,), 'F')) + d = Decimal( (1, (0, 2, 7, 1), 'F') ) + self.assertEqual(d.as_tuple(), (1, (0,), 'F')) + def test_immutability_operations(self): # Do operations and check that it didn't change change internal objects. d1 = Decimal('-25e55') b1 = Decimal('-25e55') - d2 = Decimal('33e-33') - b2 = Decimal('33e-33') + d2 = Decimal('33e+33') + b2 = Decimal('33e+33') def checkSameDec(operation, useOther=False): if useOther: @@ -1025,6 +1168,21 @@ checkSameDec("to_eng_string") checkSameDec("to_integral") + def test_subclassing(self): + # Different behaviours when subclassing Decimal + + class MyDecimal(Decimal): + pass + + d1 = MyDecimal(1) + d2 = MyDecimal(2) + d = d1 + d2 + self.assertTrue(type(d) is Decimal) + + d = d1.max(d2) + self.assertTrue(type(d) is Decimal) + + class DecimalPythonAPItests(unittest.TestCase): def test_pickle(self): @@ -1091,7 +1249,59 @@ self.assert_(new_ctx is not set_ctx, 'did not copy the context') self.assert_(set_ctx is enter_ctx, '__enter__ returned wrong context') -def test_main(arith=False, verbose=None): +class ContextFlags(unittest.TestCase): + def test_flags_irrelevant(self): + # check that the result (numeric result + flags raised) of an + # arithmetic operation doesn't depend on the current flags + + context = Context(prec=9, Emin = -999999999, Emax = 999999999, + rounding=ROUND_HALF_EVEN, traps=[], flags=[]) + + # operations that raise various flags, in the form (function, arglist) + operations = [ + (context._apply, [Decimal("100E-1000000009")]), + (context.sqrt, [Decimal(2)]), + (context.add, [Decimal("1.23456789"), Decimal("9.87654321")]), + (context.multiply, [Decimal("1.23456789"), Decimal("9.87654321")]), + (context.subtract, [Decimal("1.23456789"), Decimal("9.87654321")]), + ] + + # try various flags individually, then a whole lot at once + flagsets = [[Inexact], [Rounded], [Underflow], [Clamped], [Subnormal], + [Inexact, Rounded, Underflow, Clamped, Subnormal]] + + for fn, args in operations: + # find answer and flags raised using a clean context + context.clear_flags() + ans = fn(*args) + flags = [k for k, v in context.flags.items() if v] + + for extra_flags in flagsets: + # set flags, before calling operation + context.clear_flags() + for flag in extra_flags: + context._raise_error(flag) + new_ans = fn(*args) + + # flags that we expect to be set after the operation + expected_flags = list(flags) + for flag in extra_flags: + if flag not in expected_flags: + expected_flags.append(flag) + expected_flags.sort() + + # flags we actually got + new_flags = [k for k,v in context.flags.items() if v] + new_flags.sort() + + self.assertEqual(ans, new_ans, + "operation produces different answers depending on flags set: " + + "expected %s, got %s." % (ans, new_ans)) + self.assertEqual(new_flags, expected_flags, + "operation raises different flags depending on flags set: " + + "expected %s, got %s" % (expected_flags, new_flags)) + +def test_main(arith=False, verbose=None, todo_tests=None, debug=None): """ Execute the tests. Runs all arithmetic tests if arith is True or if the "decimal" resource @@ -1099,35 +1309,58 @@ """ init() - global TEST_ALL + global TEST_ALL, DEBUG TEST_ALL = arith or is_resource_enabled('decimal') + DEBUG = debug + + if todo_tests is None: + test_classes = [ + DecimalExplicitConstructionTest, + DecimalImplicitConstructionTest, + DecimalArithmeticOperatorsTest, + DecimalUseOfContextTest, + DecimalUsabilityTest, + DecimalPythonAPItests, + ContextAPItests, + DecimalTest, + WithStatementTest, + ContextFlags + ] + else: + test_classes = [DecimalTest] + + # Dynamically build custom test definition for each file in the test + # directory and add the definitions to the DecimalTest class. This + # procedure insures that new files do not get skipped. + for filename in os.listdir(directory): + if '.decTest' not in filename or filename.startswith("."): + continue + head, tail = filename.split('.') + if todo_tests is not None and head not in todo_tests: + continue + tester = lambda self, f=filename: self.eval_file(directory + f) + setattr(DecimalTest, 'test_' + head, tester) + del filename, head, tail, tester - test_classes = [ - DecimalExplicitConstructionTest, - DecimalImplicitConstructionTest, - DecimalArithmeticOperatorsTest, - DecimalUseOfContextTest, - DecimalUsabilityTest, - DecimalPythonAPItests, - ContextAPItests, - DecimalTest, - WithStatementTest, - ] try: run_unittest(*test_classes) - import decimal as DecimalModule - run_doctest(DecimalModule, verbose) + if todo_tests is None: + import decimal as DecimalModule + run_doctest(DecimalModule, verbose) finally: setcontext(ORIGINAL_CONTEXT) if __name__ == '__main__': - # Calling with no arguments runs all tests. - # Calling with "Skip" will skip over 90% of the arithmetic tests. - if len(sys.argv) == 1: - test_main(arith=True, verbose=True) - elif len(sys.argv) == 2: - arith = sys.argv[1].lower() != 'skip' - test_main(arith=arith, verbose=True) + import optparse + p = optparse.OptionParser("test_decimal.py [--debug] [{--skip | test1 [test2 [...]]}]") + p.add_option('--debug', '-d', action='store_true', help='shows the test number and context before each test') + p.add_option('--skip', '-s', action='store_true', help='skip over 90% of the arithmetic tests') + (opt, args) = p.parse_args() + + if opt.skip: + test_main(arith=False, verbose=True) + elif args: + test_main(arith=True, verbose=True, todo_tests=args, debug=opt.debug) else: - raise ValueError("test called with wrong arguments, use test_Decimal [Skip]") + test_main(arith=True, verbose=True) From buildbot at python.org Tue Jan 8 17:26:07 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 08 Jan 2008 16:26:07 +0000 Subject: [Python-checkins] buildbot failure in x86 gentoo trunk Message-ID: <20080108162607.E11D81E4005@bag.python.org> The Buildbot has detected a new failure of x86 gentoo trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20gentoo%20trunk/builds/2849 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-x86 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_socket_ssl make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Tue Jan 8 18:35:47 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 08 Jan 2008 17:35:47 +0000 Subject: [Python-checkins] buildbot failure in ppc Debian unstable trunk Message-ID: <20080108173548.181141E4026@bag.python.org> The Buildbot has detected a new failure of ppc Debian unstable trunk. Full details are available at: http://www.python.org/dev/buildbot/all/ppc%20Debian%20unstable%20trunk/builds/554 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: christian.heimes,thomas.heller BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30995, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/SocketServer.py", line 523, in __init__ self.handle() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/BaseHTTPServer.py", line 310, in handle_one_request method() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/SimpleXMLRPCServer.py", line 449, in do_POST self.report_404() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/SimpleXMLRPCServer.py", line 507, in report_404 self.connection.shutdown(1) File "", line 1, in shutdown error: [Errno 107] Transport endpoint is not connected 1 test failed: test_xmlrpc ====================================================================== ERROR: test_fail_no_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_xmlrpc.py", line 560, in test_fail_no_info p.pow(6,8) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1157, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1447, in __request verbose=self.__verbose File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1195, in request errcode, errmsg, headers = h.getreply() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 1006, in getreply response = self._conn.getresponse() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 932, in getresponse response.begin() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 415, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 271, in readheaders line = self.fp.readline() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/socket.py", line 354, in readline data = recv(1) error: [Errno 104] Connection reset by peer make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Tue Jan 8 18:45:52 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 08 Jan 2008 17:45:52 +0000 Subject: [Python-checkins] buildbot failure in g4 osx.4 2.5 Message-ID: <20080108174552.731021E4005@bag.python.org> The Buildbot has detected a new failure of g4 osx.4 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/g4%20osx.4%202.5/builds/481 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: psf-g4 Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: facundo.batista BUILD FAILED: failed test Excerpt from the test logfile: 2 tests failed: test_urllib2 test_urllib2net ====================================================================== ERROR: test_trivial (test.test_urllib2.TrivialTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/test/test_urllib2.py", line 19, in test_trivial self.assertRaises(ValueError, urllib2.urlopen, 'bogus url') File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/unittest.py", line 320, in failUnlessRaises callableObj(*args, **kwargs) File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib2.py", line 123, in urlopen _opener = build_opener() File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib2.py", line 462, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib2.py", line 669, in __init__ proxies = getproxies() File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib.py", line 1330, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_file (test.test_urllib2.HandlerTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/test/test_urllib2.py", line 617, in test_file r = h.file_open(Request(url)) File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib2.py", line 1203, in file_open return self.open_local_file(req) File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib2.py", line 1222, in open_local_file localfile = url2pathname(file) File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib.py", line 55, in url2pathname return unquote(pathname) TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_http (test.test_urllib2.HandlerTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/test/test_urllib2.py", line 721, in test_http r.read; r.readline # wrapped MockFile methods AttributeError: addinfourl instance has no attribute 'read' ====================================================================== ERROR: test_build_opener (test.test_urllib2.MiscTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/test/test_urllib2.py", line 1019, in test_build_opener o = build_opener(FooHandler, BarHandler) File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib2.py", line 462, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib2.py", line 669, in __init__ proxies = getproxies() File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib.py", line 1330, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: testURLread (test.test_urllib2net.URLTimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/test/test_urllib2net.py", line 24, in testURLread f = urllib2.urlopen("http://www.python.org/") File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib2.py", line 123, in urlopen _opener = build_opener() File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib2.py", line 462, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib2.py", line 669, in __init__ proxies = getproxies() File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib.py", line 1330, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_bad_address (test.test_urllib2net.urlopenNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/test/test_urllib2net.py", line 147, in test_bad_address urllib2.urlopen, "http://www.python.invalid./") File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/unittest.py", line 320, in failUnlessRaises callableObj(*args, **kwargs) File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib2.py", line 123, in urlopen _opener = build_opener() File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib2.py", line 462, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib2.py", line 669, in __init__ proxies = getproxies() File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib.py", line 1330, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_basic (test.test_urllib2net.urlopenNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/test/test_urllib2net.py", line 105, in test_basic open_url = urllib2.urlopen("http://www.python.org/") File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib2.py", line 123, in urlopen _opener = build_opener() File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib2.py", line 462, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib2.py", line 669, in __init__ proxies = getproxies() File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib.py", line 1330, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_geturl (test.test_urllib2net.urlopenNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/test/test_urllib2net.py", line 129, in test_geturl open_url = urllib2.urlopen(URL) File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib2.py", line 123, in urlopen _opener = build_opener() File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib2.py", line 462, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib2.py", line 669, in __init__ proxies = getproxies() File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib.py", line 1330, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_info (test.test_urllib2net.urlopenNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/test/test_urllib2net.py", line 116, in test_info open_url = urllib2.urlopen("http://www.python.org/") File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib2.py", line 123, in urlopen _opener = build_opener() File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib2.py", line 462, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib2.py", line 669, in __init__ proxies = getproxies() File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib.py", line 1330, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_file (test.test_urllib2net.OtherNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/test/test_urllib2net.py", line 202, in test_file self._test_urls(urls, self._extra_handlers()) File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/test/test_urllib2net.py", line 250, in _test_urls urllib2.install_opener(urllib2.build_opener(*handlers)) File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib2.py", line 462, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib2.py", line 669, in __init__ proxies = getproxies() File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib.py", line 1330, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_ftp (test.test_urllib2net.OtherNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/test/test_urllib2net.py", line 174, in test_ftp self._test_urls(urls, self._extra_handlers()) File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/test/test_urllib2net.py", line 250, in _test_urls urllib2.install_opener(urllib2.build_opener(*handlers)) File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib2.py", line 462, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib2.py", line 669, in __init__ proxies = getproxies() File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib.py", line 1330, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_gopher (test.test_urllib2net.OtherNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/test/test_urllib2net.py", line 187, in test_gopher self._test_urls(urls, self._extra_handlers()) File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/test/test_urllib2net.py", line 250, in _test_urls urllib2.install_opener(urllib2.build_opener(*handlers)) File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib2.py", line 462, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib2.py", line 669, in __init__ proxies = getproxies() File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib.py", line 1330, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_http (test.test_urllib2net.OtherNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/test/test_urllib2net.py", line 214, in test_http self._test_urls(urls, self._extra_handlers()) File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/test/test_urllib2net.py", line 250, in _test_urls urllib2.install_opener(urllib2.build_opener(*handlers)) File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib2.py", line 462, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib2.py", line 669, in __init__ proxies = getproxies() File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib.py", line 1330, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_range (test.test_urllib2net.OtherNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/test/test_urllib2net.py", line 160, in test_range result = urllib2.urlopen(req) File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib2.py", line 123, in urlopen _opener = build_opener() File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib2.py", line 462, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib2.py", line 669, in __init__ proxies = getproxies() File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib.py", line 1330, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_close (test.test_urllib2net.CloseSocketTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/test/test_urllib2net.py", line 76, in test_close response = urllib2.urlopen("http://www.python.org/") File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib2.py", line 123, in urlopen _opener = build_opener() File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib2.py", line 462, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib2.py", line 669, in __init__ proxies = getproxies() File "/Users/buildslave/bb/2.5.psf-g4/build/Lib/urllib.py", line 1330, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Tue Jan 8 20:42:30 2008 From: python-checkins at python.org (georg.brandl) Date: Tue, 8 Jan 2008 20:42:30 +0100 (CET) Subject: [Python-checkins] r59860 - python/trunk/Doc/using/windows.rst Message-ID: <20080108194230.D15E91E4005@bag.python.org> Author: georg.brandl Date: Tue Jan 8 20:42:30 2008 New Revision: 59860 Modified: python/trunk/Doc/using/windows.rst Log: Better method for associating .py files with the interpreter. Modified: python/trunk/Doc/using/windows.rst ============================================================================== --- python/trunk/Doc/using/windows.rst (original) +++ python/trunk/Doc/using/windows.rst Tue Jan 8 20:42:30 2008 @@ -188,16 +188,17 @@ startup. You can also make all ``.py`` scripts execute with :program:`pythonw.exe`, -setting this through the usual facilites, for example (names might differ, -depending on your version of Windows): - -#. Open the context menu of a :file:`{*}.py` file. -#. Click :menuselection:`Open with...`. -#. Choose the interpreter of your choice (utilize :guilabel:`Other...` or - :guilabel:`Choose Program...` if it is not in the list of default programs). -#. Check :guilabel:`Always open files with this program`. -#. Click :guilabel:`OK`. +setting this through the usual facilites, for example (might require +administrative rights): +#. Launch a command prompt. +#. Associate the correct file group with ``.py`` scripts:: + + assoc .py=Python.File + +#. Redirect all Python files to the new executable:: + + ftype Python.File=C:\Path\to\pythonw.exe "%1" %* Additional modules From python-checkins at python.org Tue Jan 8 20:54:25 2008 From: python-checkins at python.org (martin.v.loewis) Date: Tue, 8 Jan 2008 20:54:25 +0100 (CET) Subject: [Python-checkins] r59861 - tracker/roundup-src/roundup/roundupdb.py Message-ID: <20080108195425.38C501E4005@bag.python.org> Author: martin.v.loewis Date: Tue Jan 8 20:54:24 2008 New Revision: 59861 Modified: tracker/roundup-src/roundup/roundupdb.py Log: Generate additional headers. Modified: tracker/roundup-src/roundup/roundupdb.py ============================================================================== --- tracker/roundup-src/roundup/roundupdb.py (original) +++ tracker/roundup-src/roundup/roundupdb.py Tue Jan 8 20:54:24 2008 @@ -395,6 +395,39 @@ if inreplyto: writer.addheader('In-Reply-To', inreplyto) + # Additional headers for bugs.python.org + # 20080106 mvl + + # Generate a header for each link or multilink to + # a class that has a name attribute + for propname, prop in self.getprops().items(): + if not isinstance(prop, (hyperdb.Link, hyperdb.Multilink)): + continue + cl = self.db.getclass(prop.classname) + if not 'name' in cl.getprops(): + continue + if isinstance(prop, hyperdb.Link): + value = self.get(nodeid, propname) + if value is None: + continue + values = [value] + else: + values = self.get(nodeid, propname) + if not values: + continue + values = [cl.get(v, 'name') for v in values] + values = ', '.join(values) + writer.addheader("X-Roundup-%s-%s" % (self.classname, propname), + values) + if not inreplyto: + # Default the reply to the first message + msgs = self.get(nodeid, 'messages') + # Assume messages are sorted by increasing message number here + if msgs[0] != nodeid: + inreplyto = messages.get(msgs[0], 'messageid') + writer.addheader('In-Reply-To', inreplyto) + # end additional headers + # attach files if message_files: part = writer.startmultipartbody('mixed') From python-checkins at python.org Tue Jan 8 22:10:12 2008 From: python-checkins at python.org (facundo.batista) Date: Tue, 8 Jan 2008 22:10:12 +0100 (CET) Subject: [Python-checkins] r59862 - in python/trunk: Misc/NEWS Modules/_sre.c Message-ID: <20080108211012.E14601E4005@bag.python.org> Author: facundo.batista Date: Tue Jan 8 22:10:12 2008 New Revision: 59862 Modified: python/trunk/Misc/NEWS python/trunk/Modules/_sre.c Log: Issue 846388. Adds a call to PyErr_CheckSignals to SRE_MATCH so that signal handlers can be invoked during long regular expression matches. It also adds a new error return value indicating that an exception occurred in a signal handler during the match, allowing exceptions in the signal handler to propagate up to the main loop. Thanks Josh Hoyt and Ralf Schmitt. Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Tue Jan 8 22:10:12 2008 @@ -348,6 +348,9 @@ Library ------- +- Issue #846388. re.match is interruptible now, which is particularly + good for long regular expression matches. + - pyexpat, patch #1137: allow setting buffer_size attribute on Parser objects to set the character data buffer size. Modified: python/trunk/Modules/_sre.c ============================================================================== --- python/trunk/Modules/_sre.c (original) +++ python/trunk/Modules/_sre.c Tue Jan 8 22:10:12 2008 @@ -99,6 +99,7 @@ #define SRE_ERROR_STATE -2 /* illegal state */ #define SRE_ERROR_RECURSION_LIMIT -3 /* runaway recursion */ #define SRE_ERROR_MEMORY -9 /* out of memory */ +#define SRE_ERROR_INTERRUPTED -10 /* signal handler raised exception */ #if defined(VERBOSE) #define TRACE(v) printf v @@ -809,6 +810,7 @@ Py_ssize_t alloc_pos, ctx_pos = -1; Py_ssize_t i, ret = 0; Py_ssize_t jump; + unsigned int sigcount=0; SRE_MATCH_CONTEXT* ctx; SRE_MATCH_CONTEXT* nextctx; @@ -837,6 +839,9 @@ } for (;;) { + ++sigcount; + if ((0 == (sigcount & 0xfff)) && PyErr_CheckSignals()) + RETURN_ERROR(SRE_ERROR_INTERRUPTED); switch (*ctx->pattern++) { @@ -1834,6 +1839,9 @@ case SRE_ERROR_MEMORY: PyErr_NoMemory(); break; + case SRE_ERROR_INTERRUPTED: + /* An exception has already been raised, so let it fly */ + break; default: /* other error codes indicate compiler/engine bugs */ PyErr_SetString( From python-checkins at python.org Tue Jan 8 22:42:04 2008 From: python-checkins at python.org (mark.dickinson) Date: Tue, 8 Jan 2008 22:42:04 +0100 (CET) Subject: [Python-checkins] r59863 - in python/branches/release25-maint/Lib: decimal.py test/test_decimal.py Message-ID: <20080108214204.0BADC1E4005@bag.python.org> Author: mark.dickinson Date: Tue Jan 8 22:42:03 2008 New Revision: 59863 Modified: python/branches/release25-maint/Lib/decimal.py python/branches/release25-maint/Lib/test/test_decimal.py Log: Fix Decimal hash in Python 2.5 maintenance branch so that hash(x) == hash(int(x)) for any integral Decimal instance x. Modified: python/branches/release25-maint/Lib/decimal.py ============================================================================== --- python/branches/release25-maint/Lib/decimal.py (original) +++ python/branches/release25-maint/Lib/decimal.py Tue Jan 8 22:42:03 2008 @@ -800,13 +800,7 @@ return 0 if self._isinteger(): op = _WorkRep(self.to_integral_value()) - # to make computation feasible for Decimals with large - # exponent, we use the fact that hash(n) == hash(m) for - # any two nonzero integers n and m such that (i) n and m - # have the same sign, and (ii) n is congruent to m modulo - # 2**64-1. So we can replace hash((-1)**s*c*10**e) with - # hash((-1)**s*c*pow(10, e, 2**64-1). - return hash((-1)**op.sign*op.int*pow(10, op.exp, 2**64-1)) + return hash((-1)**op.sign*op.int*10**op.exp) # The value of a nonzero nonspecial Decimal instance is # faithfully represented by the triple consisting of its sign, # its adjusted exponent, and its coefficient with trailing Modified: python/branches/release25-maint/Lib/test/test_decimal.py ============================================================================== --- python/branches/release25-maint/Lib/test/test_decimal.py (original) +++ python/branches/release25-maint/Lib/test/test_decimal.py Tue Jan 8 22:42:03 2008 @@ -961,6 +961,16 @@ # a value for which hash(n) != hash(n % (2**64-1)) # in Python pre-2.6 Decimal(2**64 + 2**32 - 1), + # selection of values which fail with the Python 2.6 + # version of Decimal.__hash__ and the Python 2.5 + # version of long.__hash__. Included here to prevent + # an accidental backport of the Decimal.__hash__ from + # Python 2.6 to Python 2.5. + Decimal("1.634E100"), + Decimal("90.697E100"), + Decimal("188.83E100"), + Decimal("1652.9E100"), + Decimal("56531E100"), ]) # check that hash(d) == hash(int(d)) for integral values From buildbot at python.org Tue Jan 8 22:57:12 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 08 Jan 2008 21:57:12 +0000 Subject: [Python-checkins] buildbot failure in x86 FreeBSD trunk Message-ID: <20080108215712.989471E4018@bag.python.org> The Buildbot has detected a new failure of x86 FreeBSD trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20FreeBSD%20trunk/builds/365 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-freebsd Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: facundo.batista,georg.brandl BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 523, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable 1 test failed: test_xmlrpc sincerely, -The Buildbot From nnorwitz at gmail.com Tue Jan 8 23:56:06 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Tue, 8 Jan 2008 17:56:06 -0500 Subject: [Python-checkins] Python Regression Test Failures all (1) Message-ID: <20080108225606.GA26307@python.psfb.org> test_grammar test_opcodes test_dict test_builtin test_exceptions test_types test_unittest test_doctest test_doctest2 test_MimeWriter test_StringIO test___all__ test___future__ test__locale test_abc test_abstract_numbers test_aepack test_aepack skipped -- No module named aepack test_al test_al skipped -- No module named al test_anydbm test_applesingle test_applesingle skipped -- No module named macostools test_array test_ast test_asynchat WARNING: failed to listen on port 54322, trying another WARNING: failed to listen on port 9907, trying another test_asyncore test_atexit test_audioop test_augassign test_base64 test_bastion test_bigaddrspace test_bigmem test_binascii test_binhex test_binop test_bisect test_bool test_bsddb test_bsddb185 test_bsddb185 skipped -- No module named bsddb185 test_bsddb3 test test_bsddb3 failed -- errors occurred; run in verbose mode for details test_buffer test_bufio test_bz2 test_cProfile test_calendar test_call test_capi test_cd test_cd skipped -- No module named cd test_cfgparser test_cgi test_charmapcodec test_cl test_cl skipped -- No module named cl test_class test_cmath test_cmd test_cmd_line test_cmd_line_script test_code test_codeccallbacks test_codecencodings_cn test_codecencodings_hk test_codecencodings_jp test_codecencodings_kr test_codecencodings_tw test_codecmaps_cn test_codecmaps_hk test_codecmaps_jp test_codecmaps_kr test_codecmaps_tw test_codecs test_codeop test_coding test_coercion test_collections test_colorsys test_commands test_compare test_compile test_compiler testCompileLibrary still working, be patient... test_complex test_complex_args test_contains test_contextlib test_cookie test_cookielib test_copy test_copy_reg test_cpickle test_crypt test_csv test_ctypes test_datetime test_dbm test_decimal test_decorators test_defaultdict test_deque test_descr test_descrtut test_difflib test_dircache test_dis test_distutils test_dl test_docxmlrpc test_dumbdbm test_dummy_thread test_dummy_threading test_email test_email_codecs test_email_renamed test_enumerate test_eof test_errno test_exception_variations test_extcall test_fcntl test_file test_filecmp test_fileinput test_float test_fnmatch test_fork1 test_format test_fpformat test_frozen test_ftplib test_funcattrs test_functools test_future test_gc test_gdbm test_generators test_genericpath test_genexps test_getargs test_getargs2 test_getopt test_gettext test_gl test_gl skipped -- No module named gl test_glob test_global test_grp test_gzip test_hash test_hashlib test_heapq test_hexoct test_hmac test_hotshot test_htmllib test_htmlparser test_httplib test_imageop test_imageop skipped -- No module named imgfile test_imaplib test_imgfile test_imgfile skipped -- No module named imgfile test_imp test_import test_importhooks test_index test_inspect test_ioctl test_ioctl skipped -- Unable to open /dev/tty test_isinstance test_iter test_iterlen test_itertools test_largefile test_list test_locale test_logging test_long test_long_future test_longexp test_macostools test_macostools skipped -- No module named macostools test_macpath test_mailbox test_marshal test_math test_md5 test_mhlib test_mimetools test_mimetypes test_minidom test_mmap test_module test_modulefinder test_multibytecodec test_multibytecodec_support test_multifile test_mutants test_netrc test_new test_nis test_normalization test_ntpath test_old_mailbox test_openpty test_operator test_optparse test_os test_parser test_peepholer test_pep247 test_pep263 test_pep277 test_pep277 skipped -- test works only on NT+ test_pep292 test_pep352 test_pickle test_pickletools test_pipes test_pkg test_pkgimport test_platform test_plistlib test_plistlib skipped -- No module named plistlib test_poll test_popen [7429 refs] [7429 refs] [7429 refs] test_popen2 test_poplib test_posix test_posixpath test_pow test_pprint test_profile test_profilehooks test_property test_pty test_pwd test_pyclbr test_pyexpat test_queue test_quopri [7808 refs] [7808 refs] test_random test_re test_repr test_resource test_rfc822 test_richcmp test_robotparser test_runpy test_sax test_scope test_scriptpackages test_scriptpackages skipped -- No module named aetools test_select test_set test_sets test_sgmllib test_sha test_shelve test_shlex test_shutil test_signal test_site test_slice test_smtplib test_socket test_socket_ssl /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:94: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ssl_sock = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:60: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:130: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:144: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) test_socketserver test_softspace test_sort test_sqlite test_ssl test_startfile test_startfile skipped -- cannot import name startfile test_str test_strftime test_string test_stringprep test_strop test_strptime test_struct test_structmembers test_structseq test_subprocess [7424 refs] [7425 refs] [7424 refs] [7424 refs] [7424 refs] [7424 refs] [7424 refs] [7424 refs] [7424 refs] [7424 refs] [7425 refs] [9044 refs] [7642 refs] [7425 refs] [7424 refs] [7424 refs] [7424 refs] [7424 refs] [7424 refs] . [7424 refs] [7424 refs] this bit of output is from a test of stdout in a different process ... [7424 refs] [7424 refs] [7642 refs] test_sunaudiodev test_sunaudiodev skipped -- No module named sunaudiodev test_sundry test_symtable test_syntax test_sys [7424 refs] [7424 refs] test_tarfile test_tcl test_tcl skipped -- No module named _tkinter test_telnetlib test_tempfile [7431 refs] test_textwrap test_thread test_threaded_import test_threadedtempfile test_threading [10566 refs] test_threading_local test_threadsignals test_time test_timeout test_tokenize test_trace test_traceback test_transformer test_tuple test_typechecks test_ucn test_unary test_unicode test_unicode_file test_unicode_file skipped -- No Unicode filesystem semantics on this platform. test_unicodedata test_univnewlines test_unpack test_urllib test_urllib2 test_urllib2_localnet test_urllib2net test_urllibnet test_urlparse test_userdict test_userlist test_userstring test_uu test_uuid WARNING: uuid.getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._ifconfig_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._unixdll_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. test_wait3 test_wait4 test_warnings test_wave test_weakref test_whichdb test_winreg test_winreg skipped -- No module named _winreg test_winsound test_winsound skipped -- No module named winsound test_with test_wsgiref test_xdrlib test_xml_etree test_xml_etree_c test_xmllib test_xmlrpc test_xpickle test_xrange test_zipfile test_zipfile64 test_zipfile64 skipped -- test requires loads of disk-space bytes and a long time to run test_zipimport test_zlib 312 tests OK. 1 test failed: test_bsddb3 21 tests skipped: test_aepack test_al test_applesingle test_bsddb185 test_cd test_cl test_gl test_imageop test_imgfile test_ioctl test_macostools test_pep277 test_plistlib test_scriptpackages test_startfile test_sunaudiodev test_tcl test_unicode_file test_winreg test_winsound test_zipfile64 1 skip unexpected on linux2: test_ioctl [535767 refs] From buildbot at python.org Tue Jan 8 23:35:43 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 08 Jan 2008 22:35:43 +0000 Subject: [Python-checkins] buildbot failure in hppa Ubuntu trunk Message-ID: <20080108223543.AB6141E4016@bag.python.org> The Buildbot has detected a new failure of hppa Ubuntu trunk. Full details are available at: http://www.python.org/dev/buildbot/all/hppa%20Ubuntu%20trunk/builds/484 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-ubuntu-hppa Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: facundo.batista,georg.brandl BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_bsddb3 ====================================================================== ERROR: test00_associateDBError (bsddb.test.test_associate.AssociateErrorTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 104, in setUp self.env.open(homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateBTreeTxnTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateBTreeTxnTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test13_associate_in_transaction (bsddb.test.test_associate.AssociateBTreeTxnTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ShelveAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ShelveAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ShelveAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ThreadedAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ThreadedAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ThreadedAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ThreadedAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ThreadedAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ThreadedAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_EnvRemoveAndRename (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_EnvRemoveAndRename (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Transactions (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_TxnTruncate (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test08_TxnLateUse (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Transactions (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_TxnTruncate (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test08_TxnLateUse (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test09_MultiDB (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test09_MultiDB (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_both (bsddb.test.test_dbobj.dbobjTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbobj.py", line 45, in test01_both self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbobj.py", line 39, in open return apply(self._cobj.open, args, kwargs) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_dbobj_dict_interface (bsddb.test.test_dbobj.dbobjTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbobj.py", line 58, in test02_dbobj_dict_interface self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbobj.py", line 39, in open return apply(self._cobj.open, args, kwargs) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01 (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02 (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03 (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_MultiCondSelect (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_CondObjs (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_CreateOrExtend (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_Delete (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_Modify (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_close_dbenv_before_db (bsddb.test.test_env_close.DBEnvClosedEarlyCrash) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_env_close.py", line 53, in test01_close_dbenv_before_db 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_close_dbenv_delete_db_success (bsddb.test.test_env_close.DBEnvClosedEarlyCrash) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_env_close.py", line 78, in test02_close_dbenv_delete_db_success 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_join (bsddb.test.test_join.JoinTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_join.py", line 57, in setUp self.env.open(homeDir, db.DB_CREATE | db.DB_INIT_MPOOL | db.DB_INIT_LOCK ) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_simple (bsddb.test.test_lock.LockingTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_lock.py", line 38, in setUp db.DB_INIT_LOCK | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_threaded (bsddb.test.test_lock.LockingTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_lock.py", line 38, in setUp db.DB_INIT_LOCK | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_set_timeout (bsddb.test.test_lock.LockingTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_lock.py", line 38, in setUp db.DB_INIT_LOCK | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_db_home (bsddb.test.test_misc.MiscTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_misc.py", line 45, in test02_db_home env.open(self.homeDir, db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_1WriterMultiReaders (bsddb.test.test_thread.BTreeConcurrentDataStore) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_1WriterMultiReaders (bsddb.test.test_thread.HashConcurrentDataStore) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_SimpleLocks (bsddb.test.test_thread.BTreeSimpleThreaded) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_SimpleLocks (bsddb.test.test_thread.HashSimpleThreaded) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.BTreeThreadedTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.HashThreadedTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.BTreeThreadedNoWaitTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.HashThreadedNoWaitTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_cachesize (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_flags (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_get (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_get_dbp (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_get_key (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_range (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_remove (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_stat (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_pget (bsddb.test.test_cursor_pget_bug.pget_bugTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_cursor_pget_bug.py", line 25, in setUp self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Wed Jan 9 02:02:07 2008 From: python-checkins at python.org (mark.dickinson) Date: Wed, 9 Jan 2008 02:02:07 +0100 (CET) Subject: [Python-checkins] r59865 - python/branches/release25-maint/Misc/NEWS Message-ID: <20080109010207.861031E4018@bag.python.org> Author: mark.dickinson Date: Wed Jan 9 02:02:07 2008 New Revision: 59865 Modified: python/branches/release25-maint/Misc/NEWS Log: Add Decimal backport to Misc/NEWS Modified: python/branches/release25-maint/Misc/NEWS ============================================================================== --- python/branches/release25-maint/Misc/NEWS (original) +++ python/branches/release25-maint/Misc/NEWS Wed Jan 9 02:02:07 2008 @@ -53,6 +53,11 @@ Library ------- +- Issue #1182: many arithmetic bugs in the decimal module have been + fixed, and the decimal module has been updated to comply with the + latest IBM Decimal Arithmetic specification (version 1.66) and + testsuite (version 2.57). (Backported from Python 2.6a0.) + - Patch #1637: fix urlparse for URLs like 'http://x.com?arg=/foo'. - Issue #1735: TarFile.extractall() now correctly sets directory permissions From buildbot at python.org Wed Jan 9 02:05:38 2008 From: buildbot at python.org (buildbot at python.org) Date: Wed, 09 Jan 2008 01:05:38 +0000 Subject: [Python-checkins] buildbot failure in x86 FreeBSD 3.0 Message-ID: <20080109010538.928021E4017@bag.python.org> The Buildbot has detected a new failure of x86 FreeBSD 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20FreeBSD%203.0/builds/377 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-freebsd Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_asynchat ====================================================================== FAIL: test_close_when_done (test.test_asynchat.TestAsynchat) ---------------------------------------------------------------------- Traceback (most recent call last): File "/usr/home/db3l/buildarea/3.0.bolen-freebsd/build/Lib/test/test_asynchat.py", line 211, in test_close_when_done self.assertTrue(len(s.buffer) > 0) AssertionError: None ====================================================================== FAIL: test_close_when_done (test.test_asynchat.TestAsynchat_WithPoll) ---------------------------------------------------------------------- Traceback (most recent call last): File "/usr/home/db3l/buildarea/3.0.bolen-freebsd/build/Lib/test/test_asynchat.py", line 211, in test_close_when_done self.assertTrue(len(s.buffer) > 0) AssertionError: None sincerely, -The Buildbot From guido at python.org Wed Jan 9 03:25:42 2008 From: guido at python.org (Guido van Rossum) Date: Tue, 8 Jan 2008 18:25:42 -0800 Subject: [Python-checkins] r59865 - python/branches/release25-maint/Misc/NEWS In-Reply-To: <20080109010207.861031E4018@bag.python.org> References: <20080109010207.861031E4018@bag.python.org> Message-ID: Hm. "updated" sounds like new features (e.g. new APIs). Is this the case? Then it isn't appropriate for 2.5. On Jan 8, 2008 5:02 PM, mark.dickinson wrote: > Author: mark.dickinson > Date: Wed Jan 9 02:02:07 2008 > New Revision: 59865 > > Modified: > python/branches/release25-maint/Misc/NEWS > Log: > Add Decimal backport to Misc/NEWS > > > Modified: python/branches/release25-maint/Misc/NEWS > ============================================================================== > --- python/branches/release25-maint/Misc/NEWS (original) > +++ python/branches/release25-maint/Misc/NEWS Wed Jan 9 02:02:07 2008 > @@ -53,6 +53,11 @@ > Library > ------- > > +- Issue #1182: many arithmetic bugs in the decimal module have been > + fixed, and the decimal module has been updated to comply with the > + latest IBM Decimal Arithmetic specification (version 1.66) and > + testsuite (version 2.57). (Backported from Python 2.6a0.) > + > - Patch #1637: fix urlparse for URLs like 'http://x.com?arg=/foo'. > > - Issue #1735: TarFile.extractall() now correctly sets directory permissions > _______________________________________________ > Python-checkins mailing list > Python-checkins at python.org > http://mail.python.org/mailman/listinfo/python-checkins > -- --Guido van Rossum (home page: http://www.python.org/~guido/) From python-checkins at python.org Wed Jan 9 04:02:23 2008 From: python-checkins at python.org (raymond.hettinger) Date: Wed, 9 Jan 2008 04:02:23 +0100 (CET) Subject: [Python-checkins] r59866 - python/trunk/Doc/library/collections.rst Message-ID: <20080109030223.760C11E4017@bag.python.org> Author: raymond.hettinger Date: Wed Jan 9 04:02:23 2008 New Revision: 59866 Modified: python/trunk/Doc/library/collections.rst Log: Syntax highlighting only works when >>> lines are accompanied by ... lines Modified: python/trunk/Doc/library/collections.rst ============================================================================== --- python/trunk/Doc/library/collections.rst (original) +++ python/trunk/Doc/library/collections.rst Wed Jan 9 04:02:23 2008 @@ -479,7 +479,7 @@ Point(x=33, y=22) >>> for partnum, record in inventory.items(): - inventory[partnum] = record._replace(price=newprices[partnum], timestamp=time.now()) + ... inventory[partnum] = record._replace(price=newprices[partnum], timestamp=time.now()) .. attribute:: somenamedtuple._fields @@ -513,14 +513,14 @@ a fixed-width print format:: >>> class Point(namedtuple('Point', 'x y')): - @property - def hypot(self): - return (self.x ** 2 + self.y ** 2) ** 0.5 - def __str__(self): - return 'Point: x=%6.3f y=%6.3f hypot=%6.3f' % (self.x, self.y, self.hypot) + ... @property + ... def hypot(self): + ... return (self.x ** 2 + self.y ** 2) ** 0.5 + ... def __str__(self): + ... return 'Point: x=%6.3f y=%6.3f hypot=%6.3f' % (self.x, self.y, self.hypot) >>> for p in Point(3,4), Point(14,5), Point(9./7,6): - print p + ... print p Point: x= 3.000 y= 4.000 hypot= 5.000 Point: x=14.000 y= 5.000 hypot=14.866 @@ -529,7 +529,7 @@ Another use for subclassing is to replace performance critcal methods with faster versions that bypass error-checking and that localize variable access:: - >>> class Point(namedtuple('Point', 'x y')): + class Point(namedtuple('Point', 'x y')): _make = classmethod(tuple.__new__) def _replace(self, _map=map, **kwds): return self._make(_map(kwds.get, ('x', 'y'), self)) From python-checkins at python.org Wed Jan 9 04:11:29 2008 From: python-checkins at python.org (fred.drake) Date: Wed, 9 Jan 2008 04:11:29 +0100 (CET) Subject: [Python-checkins] r59867 - python/trunk/Misc/NEWS Message-ID: <20080109031129.5924B1E4017@bag.python.org> Author: fred.drake Date: Wed Jan 9 04:11:28 2008 New Revision: 59867 Modified: python/trunk/Misc/NEWS Log: minor cleaning Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Wed Jan 9 04:11:28 2008 @@ -947,8 +947,8 @@ Extension Modules ----------------- -- _winreg's HKEY object have gained __enter__ and __exit__ functions to support he - context manager protocol. The _winreg module also got a new function +- _winreg's HKEY object has gained __enter__ and __exit__ methods to support + the context manager protocol. The _winreg module also gained a new function ``ExpandEnvironmentStrings`` to expand REG_EXPAND_SZ keys. - Issue #1646: Make socket support TIPC. The socket module now has support From python-checkins at python.org Wed Jan 9 04:13:20 2008 From: python-checkins at python.org (raymond.hettinger) Date: Wed, 9 Jan 2008 04:13:20 +0100 (CET) Subject: [Python-checkins] r59868 - python/trunk/Doc/library/collections.rst Message-ID: <20080109031320.9518E1E401E@bag.python.org> Author: raymond.hettinger Date: Wed Jan 9 04:13:20 2008 New Revision: 59868 Modified: python/trunk/Doc/library/collections.rst Log: Fix typo Modified: python/trunk/Doc/library/collections.rst ============================================================================== --- python/trunk/Doc/library/collections.rst (original) +++ python/trunk/Doc/library/collections.rst Wed Jan 9 04:13:20 2008 @@ -494,7 +494,7 @@ >>> Color = namedtuple('Color', 'red green blue') >>> Pixel = namedtuple('Pixel', Point._fields + Color._fields) >>> Pixel(11, 22, 128, 255, 0) - Pixel(x=11, y=22, red=128, green=255, blue=0)' + Pixel(x=11, y=22, red=128, green=255, blue=0) To retrieve a field whose name is stored in a string, use the :func:`getattr` function:: From ncoghlan at gmail.com Wed Jan 9 10:56:51 2008 From: ncoghlan at gmail.com (Nick Coghlan) Date: Wed, 09 Jan 2008 19:56:51 +1000 Subject: [Python-checkins] r59865 - python/branches/release25-maint/Misc/NEWS In-Reply-To: References: <20080109010207.861031E4018@bag.python.org> Message-ID: <47849A63.4070006@gmail.com> Guido van Rossum wrote: > Hm. "updated" sounds like new features (e.g. new APIs). Is this the > case? Then it isn't appropriate for 2.5. Way back when the Decimal PEP was written, the decision was to treat spec changes as bugs and backport them. That's where these updates came from. I believe you'll need to have an argument with Raymond and Facundo if you would prefer to change that policy :) Cheers, Nick. -- Nick Coghlan | ncoghlan at gmail.com | Brisbane, Australia --------------------------------------------------------------- http://www.boredomandlaziness.org From nnorwitz at gmail.com Wed Jan 9 11:46:26 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Wed, 9 Jan 2008 05:46:26 -0500 Subject: [Python-checkins] Python Regression Test Failures all (1) Message-ID: <20080109104626.GA28738@python.psfb.org> test_grammar test_opcodes test_dict test_builtin test_exceptions test_types test_unittest test_doctest test_doctest2 test_MimeWriter test_StringIO test___all__ test___future__ test__locale test_abc test_abstract_numbers test_aepack test_aepack skipped -- No module named aepack test_al test_al skipped -- No module named al test_anydbm test_applesingle test_applesingle skipped -- No module named macostools test_array test_ast test_asynchat WARNING: failed to listen on port 54322, trying another WARNING: failed to listen on port 9907, trying another test_asyncore test_atexit test_audioop test_augassign test_base64 test_bastion test_bigaddrspace test_bigmem test_binascii test_binhex test_binop test_bisect test_bool test_bsddb test_bsddb185 test_bsddb185 skipped -- No module named bsddb185 test_bsddb3 test test_bsddb3 failed -- errors occurred; run in verbose mode for details test_buffer test_bufio test_bz2 test_cProfile test_calendar test_call test_capi test_cd test_cd skipped -- No module named cd test_cfgparser test_cgi test_charmapcodec test_cl test_cl skipped -- No module named cl test_class test_cmath test_cmd test_cmd_line test_cmd_line_script test_code test_codeccallbacks test_codecencodings_cn test_codecencodings_hk test_codecencodings_jp test_codecencodings_kr test_codecencodings_tw test_codecmaps_cn test_codecmaps_hk test_codecmaps_jp test_codecmaps_kr test_codecmaps_tw test_codecs test_codeop test_coding test_coercion test_collections test_colorsys test_commands test_compare test_compile test_compiler testCompileLibrary still working, be patient... test_complex test_complex_args test_contains test_contextlib test_cookie test_cookielib test_copy test_copy_reg test_cpickle test_crypt test_csv test_ctypes test_datetime test_dbm test_decimal test_decorators test_defaultdict test_deque test_descr test_descrtut test_difflib test_dircache test_dis test_distutils test_dl test_docxmlrpc test_dumbdbm test_dummy_thread test_dummy_threading test_email test_email_codecs test_email_renamed test_enumerate test_eof test_errno test_exception_variations test_extcall test_fcntl test_file test_filecmp test_fileinput test_float test_fnmatch test_fork1 test_format test_fpformat test_frozen test_ftplib test_funcattrs test_functools test_future test_gc test_gdbm test_generators test_genericpath test_genexps test_getargs test_getargs2 test_getopt test_gettext test_gl test_gl skipped -- No module named gl test_glob test_global test_grp test_gzip test_hash test_hashlib test_heapq test_hexoct test_hmac test_hotshot test_htmllib test_htmlparser test_httplib test_imageop test_imageop skipped -- No module named imgfile test_imaplib test_imgfile test_imgfile skipped -- No module named imgfile test_imp test_import test_importhooks test_index test_inspect test_ioctl test_ioctl skipped -- Unable to open /dev/tty test_isinstance test_iter test_iterlen test_itertools test_largefile test_list test_locale test_logging test_long test_long_future test_longexp test_macostools test_macostools skipped -- No module named macostools test_macpath test_mailbox test_marshal test_math test_md5 test_mhlib test_mimetools test_mimetypes test_minidom test_mmap test_module test_modulefinder test_multibytecodec test_multibytecodec_support test_multifile test_mutants test_netrc test_new test_nis test_normalization test_ntpath test_old_mailbox test_openpty test_operator test_optparse test_os test_parser test_peepholer test_pep247 test_pep263 test_pep277 test_pep277 skipped -- test works only on NT+ test_pep292 test_pep352 test_pickle test_pickletools test_pipes test_pkg test_pkgimport test_platform test_plistlib test_plistlib skipped -- No module named plistlib test_poll test_popen [7429 refs] [7429 refs] [7429 refs] test_popen2 test_poplib test_posix test_posixpath test_pow test_pprint test_profile test_profilehooks test_property test_pty test_pwd test_pyclbr test_pyexpat test_queue test_quopri [7808 refs] [7808 refs] test_random test_re test_repr test_resource test_rfc822 test_richcmp test_robotparser test_runpy test_sax test_scope test_scriptpackages test_scriptpackages skipped -- No module named aetools test_select test_set test_sets test_sgmllib test_sha test_shelve test_shlex test_shutil test_signal test_site test_slice test_smtplib test_socket test_socket_ssl /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:94: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ssl_sock = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:60: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:130: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:144: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) test_socketserver test_softspace test_sort test_sqlite test_ssl test_startfile test_startfile skipped -- cannot import name startfile test_str test_strftime test_string test_stringprep test_strop test_strptime test_struct test_structmembers test_structseq test_subprocess [7424 refs] [7425 refs] [7424 refs] [7424 refs] [7424 refs] [7424 refs] [7424 refs] [7424 refs] [7424 refs] [7424 refs] [7425 refs] [9044 refs] [7642 refs] [7425 refs] [7424 refs] [7424 refs] [7424 refs] [7424 refs] [7424 refs] . [7424 refs] [7424 refs] this bit of output is from a test of stdout in a different process ... [7424 refs] [7424 refs] [7642 refs] test_sunaudiodev test_sunaudiodev skipped -- No module named sunaudiodev test_sundry test_symtable test_syntax test_sys [7424 refs] [7424 refs] test_tarfile test_tcl test_tcl skipped -- No module named _tkinter test_telnetlib test_tempfile [7431 refs] test_textwrap test_thread test_threaded_import test_threadedtempfile test_threading [10566 refs] test_threading_local test_threadsignals test_time test_timeout test_tokenize test_trace test_traceback test_transformer test_tuple test_typechecks test_ucn test_unary test_unicode test_unicode_file test_unicode_file skipped -- No Unicode filesystem semantics on this platform. test_unicodedata test_univnewlines test_unpack test_urllib test_urllib2 test_urllib2_localnet test_urllib2net test_urllibnet test_urlparse test_userdict test_userlist test_userstring test_uu test_uuid WARNING: uuid.getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._ifconfig_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._unixdll_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. test_wait3 test_wait4 test_warnings test_wave test_weakref test_whichdb test_winreg test_winreg skipped -- No module named _winreg test_winsound test_winsound skipped -- No module named winsound test_with test_wsgiref test_xdrlib test_xml_etree test_xml_etree_c test_xmllib test_xmlrpc test_xpickle test_xrange test_zipfile test_zipfile64 test_zipfile64 skipped -- test requires loads of disk-space bytes and a long time to run test_zipimport test_zlib 312 tests OK. 1 test failed: test_bsddb3 21 tests skipped: test_aepack test_al test_applesingle test_bsddb185 test_cd test_cl test_gl test_imageop test_imgfile test_ioctl test_macostools test_pep277 test_plistlib test_scriptpackages test_startfile test_sunaudiodev test_tcl test_unicode_file test_winreg test_winsound test_zipfile64 1 skip unexpected on linux2: test_ioctl [535767 refs] From python-checkins at python.org Wed Jan 9 12:19:19 2008 From: python-checkins at python.org (thomas.heller) Date: Wed, 9 Jan 2008 12:19:19 +0100 (CET) Subject: [Python-checkins] r59869 - python/trunk/PCbuild/_ctypes.vcproj Message-ID: <20080109111919.9D3781E4019@bag.python.org> Author: thomas.heller Date: Wed Jan 9 12:19:19 2008 New Revision: 59869 Modified: python/trunk/PCbuild/_ctypes.vcproj Log: Set the output file in the _ctypes Debug|x64 configuration. Modified: python/trunk/PCbuild/_ctypes.vcproj ============================================================================== --- python/trunk/PCbuild/_ctypes.vcproj (original) +++ python/trunk/PCbuild/_ctypes.vcproj Wed Jan 9 12:19:19 2008 @@ -1,7 +1,7 @@ The Buildbot has detected a new failure of x86 gentoo trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20gentoo%20trunk/builds/2851 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-x86 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: fred.drake,raymond.hettinger,thomas.heller BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30996, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Traceback (most recent call last): File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30996, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Traceback (most recent call last): File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30996, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Traceback (most recent call last): File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30996, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Traceback (most recent call last): File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30996, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') 1 test failed: test_socket_ssl make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Wed Jan 9 13:27:41 2008 From: python-checkins at python.org (andrew.kuchling) Date: Wed, 9 Jan 2008 13:27:41 +0100 (CET) Subject: [Python-checkins] r59870 - python/trunk/Modules/_cursesmodule.c Message-ID: <20080109122741.F2E011E4019@bag.python.org> Author: andrew.kuchling Date: Wed Jan 9 13:27:41 2008 New Revision: 59870 Modified: python/trunk/Modules/_cursesmodule.c Log: Related to patch #1114: fix another place where attr_t is assumed to be a long Modified: python/trunk/Modules/_cursesmodule.c ============================================================================== --- python/trunk/Modules/_cursesmodule.c (original) +++ python/trunk/Modules/_cursesmodule.c Wed Jan 9 13:27:41 2008 @@ -670,25 +670,30 @@ int num = -1; short color; attr_t attr = A_NORMAL; + long lattr; int use_xy = FALSE; switch (PyTuple_Size(args)) { case 1: - if (!PyArg_ParseTuple(args,"l;attr", &attr)) + if (!PyArg_ParseTuple(args,"l;attr", &lattr)) return NULL; + attr = lattr; break; case 2: - if (!PyArg_ParseTuple(args,"il;n,attr", &num, &attr)) + if (!PyArg_ParseTuple(args,"il;n,attr", &num, &lattr)) return NULL; + attr = lattr; break; case 3: - if (!PyArg_ParseTuple(args,"iil;int,int,attr", &y, &x, &attr)) + if (!PyArg_ParseTuple(args,"iil;int,int,attr", &y, &x, &lattr)) return NULL; + attr = lattr; use_xy = TRUE; break; case 4: - if (!PyArg_ParseTuple(args,"iiil;int,int,n,attr", &y, &x, &num, &attr)) + if (!PyArg_ParseTuple(args,"iiil;int,int,n,attr", &y, &x, &num, &lattr)) return NULL; + attr = lattr; use_xy = TRUE; break; default: From python-checkins at python.org Wed Jan 9 13:43:57 2008 From: python-checkins at python.org (andrew.kuchling) Date: Wed, 9 Jan 2008 13:43:57 +0100 (CET) Subject: [Python-checkins] r59871 - python/branches/release25-maint/Doc/README Message-ID: <20080109124357.476E11E4026@bag.python.org> Author: andrew.kuchling Date: Wed Jan 9 13:43:55 2008 New Revision: 59871 Modified: python/branches/release25-maint/Doc/README Log: Update reference to bug tracker Modified: python/branches/release25-maint/Doc/README ============================================================================== --- python/branches/release25-maint/Doc/README (original) +++ python/branches/release25-maint/Doc/README Wed Jan 9 13:43:55 2008 @@ -61,7 +61,7 @@ Specific bugs and patches should be reported using our bug & patch databases at: - http://sourceforge.net/projects/python + http://bugs.python.org Other suggestions or questions should be sent to the Python Documentation Team: From buildbot at python.org Wed Jan 9 14:20:01 2008 From: buildbot at python.org (buildbot at python.org) Date: Wed, 09 Jan 2008 13:20:01 +0000 Subject: [Python-checkins] buildbot failure in x86 FreeBSD trunk Message-ID: <20080109132002.1BC291E4006@bag.python.org> The Buildbot has detected a new failure of x86 FreeBSD trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20FreeBSD%20trunk/builds/367 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-freebsd Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: andrew.kuchling BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 523, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 523, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 523, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable 1 test failed: test_xmlrpc sincerely, -The Buildbot From python-checkins at python.org Wed Jan 9 14:28:06 2008 From: python-checkins at python.org (andrew.kuchling) Date: Wed, 9 Jan 2008 14:28:06 +0100 (CET) Subject: [Python-checkins] r59872 - peps/trunk/pep-0301.txt Message-ID: <20080109132806.361791E4006@bag.python.org> Author: andrew.kuchling Date: Wed Jan 9 14:28:05 2008 New Revision: 59872 Modified: peps/trunk/pep-0301.txt Log: Update URL Modified: peps/trunk/pep-0301.txt ============================================================================== --- peps/trunk/pep-0301.txt (original) +++ peps/trunk/pep-0301.txt Wed Jan 9 14:28:05 2008 @@ -353,7 +353,7 @@ (http://www.python.org/doc/current/lib/module-distutils.html) .. [2] Trove - (http://tuxedo.org/~esr/trove/) + (http://www.catb.org/~esr/trove/) .. [3] Vaults of Parnassus (http://www.vex.net/parnassus/) From python-checkins at python.org Wed Jan 9 15:46:10 2008 From: python-checkins at python.org (christian.heimes) Date: Wed, 9 Jan 2008 15:46:10 +0100 (CET) Subject: [Python-checkins] r59873 - python/trunk/PC/VS8.0/_ctypes.vcproj Message-ID: <20080109144610.F122F1E4021@bag.python.org> Author: christian.heimes Date: Wed Jan 9 15:46:10 2008 New Revision: 59873 Modified: python/trunk/PC/VS8.0/_ctypes.vcproj Log: vs9to8 sync Modified: python/trunk/PC/VS8.0/_ctypes.vcproj ============================================================================== --- python/trunk/PC/VS8.0/_ctypes.vcproj (original) +++ python/trunk/PC/VS8.0/_ctypes.vcproj Wed Jan 9 15:46:10 2008 @@ -643,6 +643,7 @@ The Buildbot has detected a new failure of ia64 Ubuntu trunk. Full details are available at: http://www.python.org/dev/buildbot/all/ia64%20Ubuntu%20trunk/builds/1251 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ia64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: christian.heimes BUILD FAILED: failed failed slave lost sincerely, -The Buildbot From python-checkins at python.org Wed Jan 9 17:37:02 2008 From: python-checkins at python.org (facundo.batista) Date: Wed, 9 Jan 2008 17:37:02 +0100 (CET) Subject: [Python-checkins] r59874 - python/branches/release25-maint/Doc/ref/ref3.tex Message-ID: <20080109163702.904611E4006@bag.python.org> Author: facundo.batista Date: Wed Jan 9 17:37:02 2008 New Revision: 59874 Modified: python/branches/release25-maint/Doc/ref/ref3.tex Log: Link to external documentation about new style classes was wrong. Fix issue 1774. Modified: python/branches/release25-maint/Doc/ref/ref3.tex ============================================================================== --- python/branches/release25-maint/Doc/ref/ref3.tex (original) +++ python/branches/release25-maint/Doc/ref/ref3.tex Wed Jan 9 17:37:02 2008 @@ -25,7 +25,7 @@ undergoes extensive revision, it must now be taken as authoritative only regarding ``classic classes'', that are still the default, for compatibility purposes, in Python 2.2 and 2.3. For more information, -see \url{http://www.python.org/doc/newstyle.html}.} +see \url{http://www.python.org/doc/newstyle/}.} An object's type determines the operations that the object supports (e.g., ``does it have a length?'') and also defines the possible values for objects of that type. The @@ -1101,7 +1101,7 @@ in case of multiple inheritance. This manual is not up-to-date with respect to new-style classes. For now, -please see \url{http://www.python.org/doc/newstyle.html} for more information. +please see \url{http://www.python.org/doc/newstyle/} for more information. The plan is to eventually drop old-style classes, leaving only the semantics of new-style classes. This change will probably only be feasible in Python 3.0. From python-checkins at python.org Wed Jan 9 19:51:07 2008 From: python-checkins at python.org (martin.v.loewis) Date: Wed, 9 Jan 2008 19:51:07 +0100 (CET) Subject: [Python-checkins] r59875 - tracker/roundup-src/roundup/roundupdb.py Message-ID: <20080109185107.5DEF91E4006@bag.python.org> Author: martin.v.loewis Date: Wed Jan 9 19:51:07 2008 New Revision: 59875 Modified: tracker/roundup-src/roundup/roundupdb.py Log: Only point In-Reply-To to the first message if that actually has a messageid. Modified: tracker/roundup-src/roundup/roundupdb.py ============================================================================== --- tracker/roundup-src/roundup/roundupdb.py (original) +++ tracker/roundup-src/roundup/roundupdb.py Wed Jan 9 19:51:07 2008 @@ -425,7 +425,8 @@ # Assume messages are sorted by increasing message number here if msgs[0] != nodeid: inreplyto = messages.get(msgs[0], 'messageid') - writer.addheader('In-Reply-To', inreplyto) + if inreplyto: + writer.addheader('In-Reply-To', inreplyto) # end additional headers # attach files From python-checkins at python.org Wed Jan 9 20:56:33 2008 From: python-checkins at python.org (christian.heimes) Date: Wed, 9 Jan 2008 20:56:33 +0100 (CET) Subject: [Python-checkins] r59876 - in python/trunk: Lib/test/test_import.py Misc/NEWS Python/import.c Message-ID: <20080109195633.B80EC1E401E@bag.python.org> Author: christian.heimes Date: Wed Jan 9 20:56:33 2008 New Revision: 59876 Modified: python/trunk/Lib/test/test_import.py python/trunk/Misc/NEWS python/trunk/Python/import.c Log: Fixed #1776. __import__() no longer imports modules by file name Modified: python/trunk/Lib/test/test_import.py ============================================================================== --- python/trunk/Lib/test/test_import.py (original) +++ python/trunk/Lib/test/test_import.py Wed Jan 9 20:56:33 2008 @@ -1,4 +1,4 @@ -?from test.test_support import TESTFN, run_unittest, catch_warning +from test.test_support import TESTFN, run_unittest, catch_warning import unittest import os @@ -223,6 +223,16 @@ warnings.simplefilter('error', ImportWarning) self.assertRaises(ImportWarning, __import__, "site-packages") + def test_importbyfilename(self): + path = os.path.abspath(TESTFN) + try: + __import__(path) + except ImportError, err: + self.assertEqual("Import by filename is not supported.", + err.args[0]) + else: + self.fail("import by path didn't raise an exception") + class PathsTests(unittest.TestCase): path = TESTFN Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Wed Jan 9 20:56:33 2008 @@ -12,6 +12,10 @@ Core and builtins ----------------- +- Bug #1776: __import__ must not accept filenames. Python 2.6 does no longer + support module loading by filename. It worked on some system by coincident + but it was never intended to work. + - Patch #1668: renamed THREADDEBUG envvar to PYTHONTHREADDEBUG. - Patch #602345: Add -B command line option, PYTHONDONTWRITEBYTECODE envvar Modified: python/trunk/Python/import.c ============================================================================== --- python/trunk/Python/import.c (original) +++ python/trunk/Python/import.c Wed Jan 9 20:56:33 2008 @@ -2055,6 +2055,16 @@ Py_ssize_t buflen = 0; PyObject *parent, *head, *next, *tail; + if (strchr(name, '/') != NULL +#ifdef MS_WINDOWS + || strchr(name, '\\') != NULL +#endif + ) { + PyErr_SetString(PyExc_ImportError, + "Import by filename is not supported."); + return NULL; + } + parent = get_parent(globals, buf, &buflen, level); if (parent == NULL) return NULL; From python-checkins at python.org Wed Jan 9 21:01:34 2008 From: python-checkins at python.org (georg.brandl) Date: Wed, 9 Jan 2008 21:01:34 +0100 (CET) Subject: [Python-checkins] r59877 - tracker/instances/python-dev/detectors/cia.py Message-ID: <20080109200134.04B5D1E402C@bag.python.org> Author: georg.brandl Date: Wed Jan 9 21:01:33 2008 New Revision: 59877 Modified: tracker/instances/python-dev/detectors/cia.py Log: Escape text strings when putting them into XML. Modified: tracker/instances/python-dev/detectors/cia.py ============================================================================== --- tracker/instances/python-dev/detectors/cia.py (original) +++ tracker/instances/python-dev/detectors/cia.py Wed Jan 9 21:01:33 2008 @@ -1,13 +1,14 @@ # Reactor for sending changes to CIA.vc import xmlrpclib +import cgi server = "http://CIA.vc" parameters = { 'name':'Roundup Reactor for CIA', 'revision': "$Revision$"[11:-2], - 'project': 'python', - 'branch': 'Roundup', + 'project': 'Python', + 'branch': 'roundup', 'urlprefix': 'http://bugs.python.org/issue', } @@ -64,10 +65,10 @@ log = log.replace('\n', ' ') params = parameters.copy() - params['file'] = db.issue.get(nodeid, 'title') + params['file'] = cgi.escape(db.issue.get(nodeid, 'title')) params['nodeid'] = nodeid params['author'] = db.user.get(db.getuid(), 'username') - params['log'] = log + params['log'] = cgi.escape(log) payload = TEMPLATE % params From buildbot at python.org Wed Jan 9 21:40:38 2008 From: buildbot at python.org (buildbot at python.org) Date: Wed, 09 Jan 2008 20:40:38 +0000 Subject: [Python-checkins] buildbot failure in ppc Debian unstable trunk Message-ID: <20080109204039.25E791E4026@bag.python.org> The Buildbot has detected a new failure of ppc Debian unstable trunk. Full details are available at: http://www.python.org/dev/buildbot/all/ppc%20Debian%20unstable%20trunk/builds/559 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_xmlrpc ====================================================================== ERROR: test_fail_no_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_xmlrpc.py", line 560, in test_fail_no_info p.pow(6,8) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1157, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1447, in __request verbose=self.__verbose File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1195, in request errcode, errmsg, headers = h.getreply() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 1006, in getreply response = self._conn.getresponse() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 932, in getresponse response.begin() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 415, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 271, in readheaders line = self.fp.readline() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/socket.py", line 354, in readline data = recv(1) error: [Errno 104] Connection reset by peer ====================================================================== ERROR: test_fail_with_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_xmlrpc.py", line 580, in test_fail_with_info p.pow(6,8) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1157, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1447, in __request verbose=self.__verbose File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1195, in request errcode, errmsg, headers = h.getreply() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 1006, in getreply response = self._conn.getresponse() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 932, in getresponse response.begin() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 415, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 271, in readheaders line = self.fp.readline() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/socket.py", line 354, in readline data = recv(1) error: [Errno 104] Connection reset by peer make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Wed Jan 9 22:35:04 2008 From: python-checkins at python.org (thomas.heller) Date: Wed, 9 Jan 2008 22:35:04 +0100 (CET) Subject: [Python-checkins] r59879 - python/trunk/Tools/buildbot/external-amd64.bat Message-ID: <20080109213504.7BE951E4006@bag.python.org> Author: thomas.heller Date: Wed Jan 9 22:35:04 2008 New Revision: 59879 Modified: python/trunk/Tools/buildbot/external-amd64.bat Log: Change amd64 buildbot scripts to use Visual Studio 2008, and to use the required versions of external sources. External sources are not yet built, so the build-step fails to built some targets. Modified: python/trunk/Tools/buildbot/external-amd64.bat ============================================================================== --- python/trunk/Tools/buildbot/external-amd64.bat (original) +++ python/trunk/Tools/buildbot/external-amd64.bat Wed Jan 9 22:35:04 2008 @@ -1,50 +1,43 @@ @rem Fetches (and builds if necessary) external dependencies -setlocal - at rem need this so that 'devenv' is found -call "%VS71COMNTOOLS%vsvars32.bat" - at rem set the build environment -call "%MSSdk%\SetEnv" /XP64 /RETAIL + at REM XXX FIXME - building for x64 disabled for now. @rem Assume we start inside the Python source directory -for %%i in (.) do set CWD=%%~fi cd .. - - at rem sqlite -if not exist sqlite-source-3.3.4 ( - svn export http://svn.python.org/projects/external/sqlite-source-3.3.4 - if exist %CWD%\PCbuild\sqlite3.dll del %CWD%\PCbuild\sqlite3.dll -) -if not exist %CWD%\PCbuild\sqlite3.dll ( - cd sqlite-source-3.3.4\amd64 - cl ..\*.c - link /def:..\sqlite3.def /dll *.obj /out:sqlite3.dll bufferoverflowU.lib - cd ..\.. - copy sqlite-source-3.3.4\amd64\sqlite3.dll %CWD%\PCbuild -) +call "%VS90COMNTOOLS%vsvars32.bat" @rem bzip if not exist bzip2-1.0.3 svn export http://svn.python.org/projects/external/bzip2-1.0.3 -if not exist bzip2-1.0.3\libbz2.lib ( - cd bzip2-1.0.3 - nmake /f makefile.msc CFLAGS="-DWIN32 -MD -Ox -D_FILE_OFFSET_BITS=64 -nologo /GS-" - cd .. -) @rem Sleepycat db if not exist db-4.4.20 svn export http://svn.python.org/projects/external/db-4.4.20 -if not exist "db-4.4.20\build_win32\Release_AMD64\libdb44s.lib" ( - cd db-4.4.20\build_win32 - devenv Berkeley_DB.sln /build "Release AMD64" /project db_static /useenv - cd ..\.. -) + at REM if not exist db-4.4.20\build_win32\debug\libdb44sd.lib ( + at REM vcbuild db-4.4.20\build_win32\Berkeley_DB.sln /build Debug /project db_static + at REM ) @rem OpenSSL -if not exist openssl-0.9.8a svn export http://svn.python.org/projects/external/openssl-0.9.8a +if not exist openssl-0.9.8g ( + if exist openssl-0.9.8a rd /s/q openssl-0.9.8a + svn export http://svn.python.org/projects/external/openssl-0.9.8g +) @rem tcltk -if not exist tcl8.4.12 ( +if not exist tcl8.4.16 ( if exist tcltk rd /s/q tcltk - svn export http://svn.python.org/projects/external/tcl8.4.12 - svn export http://svn.python.org/projects/external/tk8.4.12 + if exist tcl8.4.12 rd /s/q tcl8.4.12 + if exist tk8.4.12 rd /s/q tk8.4.12 + svn export http://svn.python.org/projects/external/tcl8.4.16 + svn export http://svn.python.org/projects/external/tk8.4.16 + at REM cd tcl8.4.16\win + at REM nmake -f makefile.vc COMPILERFLAGS=-DWINVER=0x0500 + at REM nmake -f makefile.vc COMPILERFLAGS=-DWINVER=0x0500 INSTALLDIR=..\..\tcltk install + at REM cd ..\.. + at REM cd tk8.4.16\win + at REM nmake -f makefile.vc COMPILERFLAGS=-DWINVER=0x0500 TCLDIR=..\..\tcl8.4.16 + at REM nmake -f makefile.vc COMPILERFLAGS=-DWINVER=0x0500 TCLDIR=..\..\tcl8.4.16 INSTALLDIR=..\..\tcltk install + at REM cd ..\.. ) + + at rem sqlite +if not exist sqlite-source-3.3.4 svn export http://svn.python.org/projects/external/sqlite-source-3.3.4 + at REM if not exist build\PCbuild\sqlite3.dll copy sqlite-source-3.3.4\sqlite3.dll build\PCbuild From python-checkins at python.org Wed Jan 9 22:35:44 2008 From: python-checkins at python.org (thomas.heller) Date: Wed, 9 Jan 2008 22:35:44 +0100 (CET) Subject: [Python-checkins] r59880 - python/trunk/Tools/buildbot/build-amd64.bat python/trunk/Tools/buildbot/clean-amd64.bat Message-ID: <20080109213544.07EEA1E4006@bag.python.org> Author: thomas.heller Date: Wed Jan 9 22:35:43 2008 New Revision: 59880 Modified: python/trunk/Tools/buildbot/build-amd64.bat python/trunk/Tools/buildbot/clean-amd64.bat Log: Change amd64 buildbot scripts to use Visual Studio 2008, and to use the required versions of external sources. External sources are not yet built, so the build-step fails to built some targets. Modified: python/trunk/Tools/buildbot/build-amd64.bat ============================================================================== --- python/trunk/Tools/buildbot/build-amd64.bat (original) +++ python/trunk/Tools/buildbot/build-amd64.bat Wed Jan 9 22:35:43 2008 @@ -1,6 +1,5 @@ @rem Used by the buildbot "compile" step. -setlocal cmd /c Tools\buildbot\external-amd64.bat -call "%VS71COMNTOOLS%vsvars32.bat" +call "%VS90COMNTOOLS%vsvars32.bat" REM cmd /q/c Tools\buildbot\kill_python.bat -devenv.com /build ReleaseAMD64 PC\VS7.1\pcbuild.sln +vcbuild PCbuild\pcbuild.sln "Debug|x64" Modified: python/trunk/Tools/buildbot/clean-amd64.bat ============================================================================== --- python/trunk/Tools/buildbot/clean-amd64.bat (original) +++ python/trunk/Tools/buildbot/clean-amd64.bat Wed Jan 9 22:35:43 2008 @@ -1,6 +1,7 @@ @rem Used by the buildbot "clean" step. -call "%VS71COMNTOOLS%vsvars32.bat" -cd PC\VS7.1 +call "%VS90COMNTOOLS%vsvars32.bat" +cd PCbuild @echo Deleting .pyc/.pyo files ... del /s Lib\*.pyc Lib\*.pyo -devenv.com /clean ReleaseAMD64 pcbuild.sln +vcbuild /clean pcbuild.sln "Release|x64" +vcbuild /clean pcbuild.sln "Debug|x64" From buildbot at python.org Wed Jan 9 23:53:20 2008 From: buildbot at python.org (buildbot at python.org) Date: Wed, 09 Jan 2008 22:53:20 +0000 Subject: [Python-checkins] buildbot failure in ia64 Ubuntu trunk Message-ID: <20080109225320.635631E4006@bag.python.org> The Buildbot has detected a new failure of ia64 Ubuntu trunk. Full details are available at: http://www.python.org/dev/buildbot/all/ia64%20Ubuntu%20trunk/builds/1253 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ia64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: thomas.heller BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_urllib2net make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Thu Jan 10 01:26:57 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 10 Jan 2008 00:26:57 +0000 Subject: [Python-checkins] buildbot failure in amd64 XP 3.0 Message-ID: <20080110002657.A2E8F1E400E@bag.python.org> The Buildbot has detected a new failure of amd64 XP 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/amd64%20XP%203.0/builds/468 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: heller-windows-amd64 Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes BUILD FAILED: failed compile sincerely, -The Buildbot From buildbot at python.org Thu Jan 10 02:09:05 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 10 Jan 2008 01:09:05 +0000 Subject: [Python-checkins] buildbot failure in ia64 Ubuntu 3.0 Message-ID: <20080110010906.422141E400E@bag.python.org> The Buildbot has detected a new failure of ia64 Ubuntu 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/ia64%20Ubuntu%203.0/builds/449 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ia64 Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ia64/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/home/pybot/buildarea/3.0.klose-debian-ia64/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/home/pybot/buildarea/3.0.klose-debian-ia64/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/home/pybot/buildarea/3.0.klose-debian-ia64/build/Lib/SocketServer.py", line 522, in __init__ self.handle() File "/home/pybot/buildarea/3.0.klose-debian-ia64/build/Lib/BaseHTTPServer.py", line 330, in handle self.handle_one_request() File "/home/pybot/buildarea/3.0.klose-debian-ia64/build/Lib/BaseHTTPServer.py", line 324, in handle_one_request method() File "/home/pybot/buildarea/3.0.klose-debian-ia64/build/Lib/SimpleXMLRPCServer.py", line 430, in do_POST self.report_404() File "/home/pybot/buildarea/3.0.klose-debian-ia64/build/Lib/SimpleXMLRPCServer.py", line 489, in report_404 self.connection.shutdown(1) socket.error: [Errno 107] Transport endpoint is not connected 1 test failed: test_xmlrpc make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Thu Jan 10 06:42:59 2008 From: python-checkins at python.org (neal.norwitz) Date: Thu, 10 Jan 2008 06:42:59 +0100 (CET) Subject: [Python-checkins] r59887 - python/trunk/Misc/NEWS Message-ID: <20080110054259.0814E1E400E@bag.python.org> Author: neal.norwitz Date: Thu Jan 10 06:42:58 2008 New Revision: 59887 Modified: python/trunk/Misc/NEWS Log: Reword entry, not sure I made it much better though. Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Thu Jan 10 06:42:58 2008 @@ -12,9 +12,8 @@ Core and builtins ----------------- -- Bug #1776: __import__ must not accept filenames. Python 2.6 does no longer - support module loading by filename. It worked on some system by coincident - but it was never intended to work. +- Bug #1776: __import__() no longer accepts filenames on any platform. + The first parameter to __import__() must be a valid module name. - Patch #1668: renamed THREADDEBUG envvar to PYTHONTHREADDEBUG. From python-checkins at python.org Thu Jan 10 14:37:13 2008 From: python-checkins at python.org (andrew.kuchling) Date: Thu, 10 Jan 2008 14:37:13 +0100 (CET) Subject: [Python-checkins] r59888 - python/trunk/Modules/mmapmodule.c Message-ID: <20080110133713.20E1C1E400E@bag.python.org> Author: andrew.kuchling Date: Thu Jan 10 14:37:12 2008 New Revision: 59888 Modified: python/trunk/Modules/mmapmodule.c Log: Check for fd of -1 to save fsync() and fstat() call Modified: python/trunk/Modules/mmapmodule.c ============================================================================== --- python/trunk/Modules/mmapmodule.c (original) +++ python/trunk/Modules/mmapmodule.c Thu Jan 10 14:37:12 2008 @@ -1059,9 +1059,11 @@ #ifdef HAVE_FSTAT # ifdef __VMS /* on OpenVMS we must ensure that all bytes are written to the file */ - fsync(fd); + if (fd != -1) { + fsync(fd); + } # endif - if (fstat(fd, &st) == 0 && S_ISREG(st.st_mode)) { + if (fd != -1 && fstat(fd, &st) == 0 && S_ISREG(st.st_mode)) { if (map_size == 0) { map_size = st.st_size; } else if ((size_t)offset + (size_t)map_size > st.st_size) { From python-checkins at python.org Thu Jan 10 19:45:40 2008 From: python-checkins at python.org (thomas.heller) Date: Thu, 10 Jan 2008 19:45:40 +0100 (CET) Subject: [Python-checkins] r59891 - python/trunk/PCbuild/readme.txt Message-ID: <20080110184540.EB4F01E401C@bag.python.org> Author: thomas.heller Date: Thu Jan 10 19:45:40 2008 New Revision: 59891 Modified: python/trunk/PCbuild/readme.txt Log: Reflow a paragraph, and fix a typo. Modified: python/trunk/PCbuild/readme.txt ============================================================================== --- python/trunk/PCbuild/readme.txt (original) +++ python/trunk/PCbuild/readme.txt Thu Jan 10 19:45:40 2008 @@ -117,7 +117,7 @@ Build with build_tkinter.py --------------------------- The PCbuild directory contains a Python script which automates all - steps. Run the script in a Visual Studio 2009 command prompt with + steps. Run the script in a Visual Studio 2008 command prompt with python build_tkinter.py Win32 @@ -312,9 +312,11 @@ Profile Guided Optimization --------------------------- -The solution has two configurations for PGO. The PGInstrument configuration -must be build first. The PGInstrument binaries are lniked against a profiling -library and contain extra debug information. The PGUpdate configuration takes the profiling data and generates optimized binaries. +The solution has two configurations for PGO. The PGInstrument +configuration must be build first. The PGInstrument binaries are +lniked against a profiling library and contain extra debug +information. The PGUpdate configuration takes the profiling data and +generates optimized binaries. The build_pgo.bat script automates the creation of optimized binaries. It creates the PGI files, runs the unit test suite or PyBench with the PGI From python-checkins at python.org Thu Jan 10 20:15:10 2008 From: python-checkins at python.org (raymond.hettinger) Date: Thu, 10 Jan 2008 20:15:10 +0100 (CET) Subject: [Python-checkins] r59892 - in python/trunk: Doc/library/collections.rst Lib/collections.py Message-ID: <20080110191510.6B2651E400A@bag.python.org> Author: raymond.hettinger Date: Thu Jan 10 20:15:10 2008 New Revision: 59892 Modified: python/trunk/Doc/library/collections.rst python/trunk/Lib/collections.py Log: Examples for named tuple subclassing should include __slots__ Modified: python/trunk/Doc/library/collections.rst ============================================================================== --- python/trunk/Doc/library/collections.rst (original) +++ python/trunk/Doc/library/collections.rst Thu Jan 10 20:15:10 2008 @@ -513,23 +513,24 @@ a fixed-width print format:: >>> class Point(namedtuple('Point', 'x y')): + ... __slots__ = () ... @property ... def hypot(self): ... return (self.x ** 2 + self.y ** 2) ** 0.5 ... def __str__(self): ... return 'Point: x=%6.3f y=%6.3f hypot=%6.3f' % (self.x, self.y, self.hypot) - >>> for p in Point(3,4), Point(14,5), Point(9./7,6): + >>> for p in Point(3, 4), Point(14, 5/7.): ... print p Point: x= 3.000 y= 4.000 hypot= 5.000 - Point: x=14.000 y= 5.000 hypot=14.866 - Point: x= 1.286 y= 6.000 hypot= 6.136 + Point: x=14.000 y= 0.714 hypot=14.018 Another use for subclassing is to replace performance critcal methods with faster versions that bypass error-checking and that localize variable access:: class Point(namedtuple('Point', 'x y')): + __slots__ = () _make = classmethod(tuple.__new__) def _replace(self, _map=map, **kwds): return self._make(_map(kwds.get, ('x', 'y'), self)) Modified: python/trunk/Lib/collections.py ============================================================================== --- python/trunk/Lib/collections.py (original) +++ python/trunk/Lib/collections.py Thu Jan 10 20:15:10 2008 @@ -118,17 +118,19 @@ # test and demonstrate ability to override methods class Point(namedtuple('Point', 'x y')): + __slots__ = () @property def hypot(self): return (self.x ** 2 + self.y ** 2) ** 0.5 def __str__(self): return 'Point: x=%6.3f y=%6.3f hypot=%6.3f' % (self.x, self.y, self.hypot) - for p in Point(3,4), Point(14,5), Point(9./7,6): + for p in Point(3, 4), Point(14, 5/7.): print p class Point(namedtuple('Point', 'x y')): 'Point class with optimized _make() and _replace() without error-checking' + __slots__ = () _make = classmethod(tuple.__new__) def _replace(self, _map=map, **kwds): return self._make(_map(kwds.get, ('x', 'y'), self)) From buildbot at python.org Thu Jan 10 21:10:51 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 10 Jan 2008 20:10:51 +0000 Subject: [Python-checkins] buildbot failure in hppa Ubuntu trunk Message-ID: <20080110201051.795AA1E4009@bag.python.org> The Buildbot has detected a new failure of hppa Ubuntu trunk. Full details are available at: http://www.python.org/dev/buildbot/all/hppa%20Ubuntu%20trunk/builds/491 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-ubuntu-hppa Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: thomas.heller BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_bsddb3 ====================================================================== ERROR: test00_associateDBError (bsddb.test.test_associate.AssociateErrorTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 104, in setUp self.env.open(homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateBTreeTxnTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateBTreeTxnTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test13_associate_in_transaction (bsddb.test.test_associate.AssociateBTreeTxnTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ShelveAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ShelveAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ShelveAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ThreadedAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ThreadedAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ThreadedAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ThreadedAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ThreadedAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ThreadedAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_EnvRemoveAndRename (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_EnvRemoveAndRename (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Transactions (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_TxnTruncate (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test08_TxnLateUse (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Transactions (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_TxnTruncate (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test08_TxnLateUse (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test09_MultiDB (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test09_MultiDB (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_both (bsddb.test.test_dbobj.dbobjTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbobj.py", line 45, in test01_both self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbobj.py", line 39, in open return apply(self._cobj.open, args, kwargs) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_dbobj_dict_interface (bsddb.test.test_dbobj.dbobjTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbobj.py", line 58, in test02_dbobj_dict_interface self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbobj.py", line 39, in open return apply(self._cobj.open, args, kwargs) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01 (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02 (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03 (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_MultiCondSelect (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_CondObjs (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_CreateOrExtend (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_Delete (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_Modify (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_close_dbenv_before_db (bsddb.test.test_env_close.DBEnvClosedEarlyCrash) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_env_close.py", line 53, in test01_close_dbenv_before_db 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_close_dbenv_delete_db_success (bsddb.test.test_env_close.DBEnvClosedEarlyCrash) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_env_close.py", line 78, in test02_close_dbenv_delete_db_success 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_join (bsddb.test.test_join.JoinTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_join.py", line 57, in setUp self.env.open(homeDir, db.DB_CREATE | db.DB_INIT_MPOOL | db.DB_INIT_LOCK ) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_simple (bsddb.test.test_lock.LockingTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_lock.py", line 38, in setUp db.DB_INIT_LOCK | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_threaded (bsddb.test.test_lock.LockingTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_lock.py", line 38, in setUp db.DB_INIT_LOCK | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_set_timeout (bsddb.test.test_lock.LockingTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_lock.py", line 38, in setUp db.DB_INIT_LOCK | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_db_home (bsddb.test.test_misc.MiscTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_misc.py", line 45, in test02_db_home env.open(self.homeDir, db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_1WriterMultiReaders (bsddb.test.test_thread.BTreeConcurrentDataStore) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_1WriterMultiReaders (bsddb.test.test_thread.HashConcurrentDataStore) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_SimpleLocks (bsddb.test.test_thread.BTreeSimpleThreaded) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_SimpleLocks (bsddb.test.test_thread.HashSimpleThreaded) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.BTreeThreadedTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.HashThreadedTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.BTreeThreadedNoWaitTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.HashThreadedNoWaitTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_cachesize (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_flags (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_get (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_get_dbp (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_get_key (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_range (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_remove (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_stat (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_pget (bsddb.test.test_cursor_pget_bug.pget_bugTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_cursor_pget_bug.py", line 25, in setUp self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Thu Jan 10 21:37:12 2008 From: python-checkins at python.org (raymond.hettinger) Date: Thu, 10 Jan 2008 21:37:12 +0100 (CET) Subject: [Python-checkins] r59895 - in python/trunk: Doc/library/collections.rst Lib/collections.py Message-ID: <20080110203712.4B1A81E4022@bag.python.org> Author: raymond.hettinger Date: Thu Jan 10 21:37:12 2008 New Revision: 59895 Modified: python/trunk/Doc/library/collections.rst python/trunk/Lib/collections.py Log: Clarify how to add a field to a named tuple. Modified: python/trunk/Doc/library/collections.rst ============================================================================== --- python/trunk/Doc/library/collections.rst (original) +++ python/trunk/Doc/library/collections.rst Thu Jan 10 21:37:12 2008 @@ -538,7 +538,7 @@ Subclassing is not useful for adding new, stored fields. Instead, simply create a new named tuple type from the :attr:`_fields` attribute:: - >>> Pixel = namedtuple('Pixel', Point._fields + Color._fields) + >>> Point3D = namedtuple('Point3D', Point._fields + ('z',)) Default values can be implemented by using :meth:`_replace` to customize a prototype instance:: Modified: python/trunk/Lib/collections.py ============================================================================== --- python/trunk/Lib/collections.py (original) +++ python/trunk/Lib/collections.py Thu Jan 10 21:37:12 2008 @@ -137,6 +137,9 @@ print Point(11, 22)._replace(x=100) + Point3D = namedtuple('Point3D', Point._fields + ('z',)) + print Point3D.__doc__ + import doctest TestResults = namedtuple('TestResults', 'failed attempted') print TestResults(*doctest.testmod()) From python-checkins at python.org Thu Jan 10 22:59:42 2008 From: python-checkins at python.org (amaury.forgeotdarc) Date: Thu, 10 Jan 2008 22:59:42 +0100 (CET) Subject: [Python-checkins] r59896 - in python/trunk: Doc/library/re.rst Lib/test/test_re.py Message-ID: <20080110215942.C0D9C1E4009@bag.python.org> Author: amaury.forgeotdarc Date: Thu Jan 10 22:59:42 2008 New Revision: 59896 Modified: python/trunk/Doc/library/re.rst python/trunk/Lib/test/test_re.py Log: Closing issue1761. Surprising behaviour of the "$" regexp: it matches the end of the string, AND just before the newline at the end of the string:: re.sub('$', '#', 'foo\n') == 'foo#\n#' Python is consistent with Perl and the pcre library, so we just document it. Guido prefers "\Z" to match only the end of the string. Modified: python/trunk/Doc/library/re.rst ============================================================================== --- python/trunk/Doc/library/re.rst (original) +++ python/trunk/Doc/library/re.rst Thu Jan 10 22:59:42 2008 @@ -98,7 +98,9 @@ string, and in :const:`MULTILINE` mode also matches before a newline. ``foo`` matches both 'foo' and 'foobar', while the regular expression ``foo$`` matches only 'foo'. More interestingly, searching for ``foo.$`` in ``'foo1\nfoo2\n'`` - matches 'foo2' normally, but 'foo1' in :const:`MULTILINE` mode. + matches 'foo2' normally, but 'foo1' in :const:`MULTILINE` mode; searching for + a single ``$`` in ``'foo\n'`` will find two (empty) matches: one just before + the newline, and one at the end of the string. ``'*'`` Causes the resulting RE to match 0 or more repetitions of the preceding RE, as Modified: python/trunk/Lib/test/test_re.py ============================================================================== --- python/trunk/Lib/test/test_re.py (original) +++ python/trunk/Lib/test/test_re.py Thu Jan 10 22:59:42 2008 @@ -671,6 +671,18 @@ q = p.match(upper_char) self.assertNotEqual(q, None) + def test_dollar_matches_twice(self): + "$ matches the end of string, and just before the terminating \n" + pattern = re.compile('$') + self.assertEqual(pattern.sub('#', 'a\nb\n'), 'a\nb#\n#') + self.assertEqual(pattern.sub('#', 'a\nb\nc'), 'a\nb\nc#') + self.assertEqual(pattern.sub('#', '\n'), '#\n#') + + pattern = re.compile('$', re.MULTILINE) + self.assertEqual(pattern.sub('#', 'a\nb\n' ), 'a#\nb#\n#' ) + self.assertEqual(pattern.sub('#', 'a\nb\nc'), 'a#\nb#\nc#') + self.assertEqual(pattern.sub('#', '\n'), '#\n#') + def run_re_tests(): from test.re_tests import benchmarks, tests, SUCCEED, FAIL, SYNTAX_ERROR From python-checkins at python.org Fri Jan 11 00:00:02 2008 From: python-checkins at python.org (raymond.hettinger) Date: Fri, 11 Jan 2008 00:00:02 +0100 (CET) Subject: [Python-checkins] r59898 - in python/trunk: Doc/library/collections.rst Lib/collections.py Message-ID: <20080110230002.156391E4009@bag.python.org> Author: raymond.hettinger Date: Fri Jan 11 00:00:01 2008 New Revision: 59898 Modified: python/trunk/Doc/library/collections.rst python/trunk/Lib/collections.py Log: Neaten-up the named tuple docs Modified: python/trunk/Doc/library/collections.rst ============================================================================== --- python/trunk/Doc/library/collections.rst (original) +++ python/trunk/Doc/library/collections.rst Fri Jan 11 00:00:01 2008 @@ -364,8 +364,8 @@ method which lists the tuple contents in a ``name=value`` format. The *fieldnames* are a single string with each fieldname separated by whitespace - and/or commas (for example 'x y' or 'x, y'). Alternatively, *fieldnames* - can be a sequence of strings (such as ['x', 'y']). + and/or commas, for example ``'x y'`` or ``'x, y'``. Alternatively, *fieldnames* + can be a sequence of strings such as ``['x', 'y']``. Any valid Python identifier may be used for a fieldname except for names starting with an underscore. Valid identifiers consist of letters, digits, @@ -373,7 +373,7 @@ a :mod:`keyword` such as *class*, *for*, *return*, *global*, *pass*, *print*, or *raise*. - If *verbose* is true, will print the class definition. + If *verbose* is true, the class definition is printed just before being built. Named tuple instances do not have per-instance dictionaries, so they are lightweight and require no more memory than regular tuples. @@ -518,16 +518,16 @@ ... def hypot(self): ... return (self.x ** 2 + self.y ** 2) ** 0.5 ... def __str__(self): - ... return 'Point: x=%6.3f y=%6.3f hypot=%6.3f' % (self.x, self.y, self.hypot) + ... return 'Point: x=%6.3f y=%6.3f hypot=%6.3f' % (self.x, self.y, self.hypot) >>> for p in Point(3, 4), Point(14, 5/7.): ... print p - Point: x= 3.000 y= 4.000 hypot= 5.000 - Point: x=14.000 y= 0.714 hypot=14.018 + Point: x= 3.000 y= 4.000 hypot= 5.000 + Point: x=14.000 y= 0.714 hypot=14.018 Another use for subclassing is to replace performance critcal methods with -faster versions that bypass error-checking and that localize variable access:: +faster versions that bypass error-checking:: class Point(namedtuple('Point', 'x y')): __slots__ = () Modified: python/trunk/Lib/collections.py ============================================================================== --- python/trunk/Lib/collections.py (original) +++ python/trunk/Lib/collections.py Fri Jan 11 00:00:01 2008 @@ -123,7 +123,7 @@ def hypot(self): return (self.x ** 2 + self.y ** 2) ** 0.5 def __str__(self): - return 'Point: x=%6.3f y=%6.3f hypot=%6.3f' % (self.x, self.y, self.hypot) + return 'Point: x=%6.3f y=%6.3f hypot=%6.3f' % (self.x, self.y, self.hypot) for p in Point(3, 4), Point(14, 5/7.): print p From python-checkins at python.org Fri Jan 11 01:23:13 2008 From: python-checkins at python.org (raymond.hettinger) Date: Fri, 11 Jan 2008 01:23:13 +0100 (CET) Subject: [Python-checkins] r59900 - in python/trunk: Doc/library/collections.rst Lib/test/test_collections.py Message-ID: <20080111002313.811961E4009@bag.python.org> Author: raymond.hettinger Date: Fri Jan 11 01:23:13 2008 New Revision: 59900 Modified: python/trunk/Doc/library/collections.rst python/trunk/Lib/test/test_collections.py Log: Run doctests on the collections module Modified: python/trunk/Doc/library/collections.rst ============================================================================== --- python/trunk/Doc/library/collections.rst (original) +++ python/trunk/Doc/library/collections.rst Fri Jan 11 01:23:13 2008 @@ -502,7 +502,7 @@ >>> getattr(p, 'x') 11 -To cast a dictionary to a named tuple, use the double-star-operator [#]_:: +To convert a dictionary to a named tuple, use the double-star-operator [#]_:: >>> d = {'x': 11, 'y': 22} >>> Point(**d) Modified: python/trunk/Lib/test/test_collections.py ============================================================================== --- python/trunk/Lib/test/test_collections.py (original) +++ python/trunk/Lib/test/test_collections.py Fri Jan 11 01:23:13 2008 @@ -1,4 +1,4 @@ -import unittest +import unittest, doctest from test import test_support from collections import namedtuple from collections import Hashable, Iterable, Iterator @@ -304,10 +304,12 @@ self.failUnless(issubclass(sample, MutableSequence)) self.failIf(issubclass(basestring, MutableSequence)) +import doctest, collections +NamedTupleDocs = doctest.DocTestSuite(module=collections) def test_main(verbose=None): import collections as CollectionsModule - test_classes = [TestNamedTuple, TestOneTrickPonyABCs, TestCollectionABCs] + test_classes = [TestNamedTuple, NamedTupleDocs, TestOneTrickPonyABCs, TestCollectionABCs] test_support.run_unittest(*test_classes) test_support.run_doctest(CollectionsModule, verbose) From python-checkins at python.org Fri Jan 11 02:25:54 2008 From: python-checkins at python.org (raymond.hettinger) Date: Fri, 11 Jan 2008 02:25:54 +0100 (CET) Subject: [Python-checkins] r59903 - in python/trunk: Lib/doctest.py Lib/test/test_doctest.py Misc/NEWS Message-ID: <20080111012554.CA9EA1E4009@bag.python.org> Author: raymond.hettinger Date: Fri Jan 11 02:25:54 2008 New Revision: 59903 Modified: python/trunk/Lib/doctest.py python/trunk/Lib/test/test_doctest.py python/trunk/Misc/NEWS Log: Doctest results return a named tuple for readability Modified: python/trunk/Lib/doctest.py ============================================================================== --- python/trunk/Lib/doctest.py (original) +++ python/trunk/Lib/doctest.py Fri Jan 11 02:25:54 2008 @@ -99,6 +99,9 @@ import unittest, difflib, pdb, tempfile import warnings from StringIO import StringIO +from collections import namedtuple + +TestResults = namedtuple('TestResults', 'failed attempted') # There are 4 basic classes: # - Example: a pair, plus an intra-docstring line number. @@ -1028,10 +1031,10 @@ >>> tests.sort(key = lambda test: test.name) >>> for test in tests: ... print test.name, '->', runner.run(test) - _TestClass -> (0, 2) - _TestClass.__init__ -> (0, 2) - _TestClass.get -> (0, 2) - _TestClass.square -> (0, 1) + _TestClass -> TestResults(failed=0, attempted=2) + _TestClass.__init__ -> TestResults(failed=0, attempted=2) + _TestClass.get -> TestResults(failed=0, attempted=2) + _TestClass.square -> TestResults(failed=0, attempted=1) The `summarize` method prints a summary of all the test cases that have been run by the runner, and returns an aggregated `(f, t)` @@ -1046,7 +1049,7 @@ 7 tests in 4 items. 7 passed and 0 failed. Test passed. - (0, 7) + TestResults(failed=0, attempted=7) The aggregated number of tried examples and failed examples is also available via the `tries` and `failures` attributes: @@ -1289,7 +1292,7 @@ # Record and return the number of failures and tries. self.__record_outcome(test, failures, tries) - return failures, tries + return TestResults(failures, tries) def __record_outcome(self, test, f, t): """ @@ -1421,7 +1424,7 @@ print "***Test Failed***", totalf, "failures." elif verbose: print "Test passed." - return totalf, totalt + return TestResults(totalf, totalt) #///////////////////////////////////////////////////////////////// # Backward compatibility cruft to maintain doctest.master. @@ -1692,7 +1695,7 @@ ... ''', {}, 'foo', 'foo.py', 0) >>> runner.run(test) - (0, 1) + TestResults(failed=0, attempted=1) >>> test.globs {} @@ -1822,7 +1825,7 @@ else: master.merge(runner) - return runner.failures, runner.tries + return TestResults(runner.failures, runner.tries) def testfile(filename, module_relative=True, name=None, package=None, globs=None, verbose=None, report=True, optionflags=0, @@ -1945,7 +1948,7 @@ else: master.merge(runner) - return runner.failures, runner.tries + return TestResults(runner.failures, runner.tries) def run_docstring_examples(f, globs, verbose=False, name="NoName", compileflags=None, optionflags=0): @@ -2004,7 +2007,7 @@ (f,t) = self.testrunner.run(test) if self.verbose: print f, "of", t, "examples failed in string", name - return (f,t) + return TestResults(f,t) def rundoc(self, object, name=None, module=None): f = t = 0 @@ -2013,7 +2016,7 @@ for test in tests: (f2, t2) = self.testrunner.run(test) (f,t) = (f+f2, t+t2) - return (f,t) + return TestResults(f,t) def rundict(self, d, name, module=None): import types Modified: python/trunk/Lib/test/test_doctest.py ============================================================================== --- python/trunk/Lib/test/test_doctest.py (original) +++ python/trunk/Lib/test/test_doctest.py Fri Jan 11 02:25:54 2008 @@ -658,7 +658,7 @@ of tried tests. >>> doctest.DocTestRunner(verbose=False).run(test) - (0, 3) + TestResults(failed=0, attempted=3) If any example produces incorrect output, then the test runner reports the failure and proceeds to the next example: @@ -695,7 +695,7 @@ Expecting: 6 ok - (1, 3) + TestResults(failed=1, attempted=3) """ def verbose_flag(): r""" The `verbose` flag makes the test runner generate more detailed @@ -726,7 +726,7 @@ Expecting: 6 ok - (0, 3) + TestResults(failed=0, attempted=3) If the `verbose` flag is unspecified, then the output will be verbose iff `-v` appears in sys.argv: @@ -737,7 +737,7 @@ >>> # If -v does not appear in sys.argv, then output isn't verbose. >>> sys.argv = ['test'] >>> doctest.DocTestRunner().run(test) - (0, 3) + TestResults(failed=0, attempted=3) >>> # If -v does appear in sys.argv, then output is verbose. >>> sys.argv = ['test', '-v'] @@ -756,7 +756,7 @@ Expecting: 6 ok - (0, 3) + TestResults(failed=0, attempted=3) >>> # Restore sys.argv >>> sys.argv = old_argv @@ -780,7 +780,7 @@ ... ''' >>> test = doctest.DocTestFinder().find(f)[0] >>> doctest.DocTestRunner(verbose=False).run(test) - (0, 2) + TestResults(failed=0, attempted=2) An example may not generate output before it raises an exception; if it does, then the traceback message will not be recognized as @@ -805,7 +805,7 @@ Exception raised: ... ZeroDivisionError: integer division or modulo by zero - (1, 2) + TestResults(failed=1, attempted=2) Exception messages may contain newlines: @@ -819,7 +819,7 @@ ... ''' >>> test = doctest.DocTestFinder().find(f)[0] >>> doctest.DocTestRunner(verbose=False).run(test) - (0, 1) + TestResults(failed=0, attempted=1) If an exception is expected, but an exception with the wrong type or message is raised, then it is reported as a failure: @@ -844,7 +844,7 @@ Traceback (most recent call last): ... ValueError: message - (1, 1) + TestResults(failed=1, attempted=1) However, IGNORE_EXCEPTION_DETAIL can be used to allow a mismatch in the detail: @@ -857,7 +857,7 @@ ... ''' >>> test = doctest.DocTestFinder().find(f)[0] >>> doctest.DocTestRunner(verbose=False).run(test) - (0, 1) + TestResults(failed=0, attempted=1) But IGNORE_EXCEPTION_DETAIL does not allow a mismatch in the exception type: @@ -881,7 +881,7 @@ Traceback (most recent call last): ... ValueError: message - (1, 1) + TestResults(failed=1, attempted=1) If an exception is raised but not expected, then it is reported as an unexpected exception: @@ -902,7 +902,7 @@ Traceback (most recent call last): ... ZeroDivisionError: integer division or modulo by zero - (1, 1) + TestResults(failed=1, attempted=1) """ def optionflags(): r""" Tests of `DocTestRunner`'s option flag handling. @@ -921,7 +921,7 @@ >>> # Without the flag: >>> test = doctest.DocTestFinder().find(f)[0] >>> doctest.DocTestRunner(verbose=False).run(test) - (0, 1) + TestResults(failed=0, attempted=1) >>> # With the flag: >>> test = doctest.DocTestFinder().find(f)[0] @@ -936,7 +936,7 @@ 1 Got: True - (1, 1) + TestResults(failed=1, attempted=1) The DONT_ACCEPT_BLANKLINE flag disables the match between blank lines and the '' marker: @@ -947,7 +947,7 @@ >>> # Without the flag: >>> test = doctest.DocTestFinder().find(f)[0] >>> doctest.DocTestRunner(verbose=False).run(test) - (0, 1) + TestResults(failed=0, attempted=1) >>> # With the flag: >>> test = doctest.DocTestFinder().find(f)[0] @@ -966,7 +966,7 @@ a b - (1, 1) + TestResults(failed=1, attempted=1) The NORMALIZE_WHITESPACE flag causes all sequences of whitespace to be treated as equal: @@ -987,13 +987,13 @@ 3 Got: 1 2 3 - (1, 1) + TestResults(failed=1, attempted=1) >>> # With the flag: >>> test = doctest.DocTestFinder().find(f)[0] >>> flags = doctest.NORMALIZE_WHITESPACE >>> doctest.DocTestRunner(verbose=False, optionflags=flags).run(test) - (0, 1) + TestResults(failed=0, attempted=1) An example from the docs: >>> print range(20) #doctest: +NORMALIZE_WHITESPACE @@ -1018,13 +1018,13 @@ [0, 1, 2, ..., 14] Got: [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14] - (1, 1) + TestResults(failed=1, attempted=1) >>> # With the flag: >>> test = doctest.DocTestFinder().find(f)[0] >>> flags = doctest.ELLIPSIS >>> doctest.DocTestRunner(verbose=False, optionflags=flags).run(test) - (0, 1) + TestResults(failed=0, attempted=1) ... also matches nothing: @@ -1105,7 +1105,7 @@ e f g - (1, 1) + TestResults(failed=1, attempted=1) >>> # With the flag: >>> test = doctest.DocTestFinder().find(f)[0] @@ -1127,7 +1127,7 @@ f g -h - (1, 1) + TestResults(failed=1, attempted=1) The REPORT_CDIFF flag causes failures that involve multi-line expected and actual outputs to be displayed using a context diff: @@ -1159,7 +1159,7 @@ + e f g - (1, 1) + TestResults(failed=1, attempted=1) The REPORT_NDIFF flag causes failures to use the difflib.Differ algorithm @@ -1184,7 +1184,7 @@ ? ^ + a b c d e f g h i j k l m ? + ++ ^ - (1, 1) + TestResults(failed=1, attempted=1) The REPORT_ONLY_FIRST_FAILURE supresses result output after the first failing example: @@ -1214,7 +1214,7 @@ 200 Got: 2 - (3, 5) + TestResults(failed=3, attempted=5) However, output from `report_start` is not supressed: @@ -1237,7 +1237,7 @@ 200 Got: 2 - (3, 5) + TestResults(failed=3, attempted=5) For the purposes of REPORT_ONLY_FIRST_FAILURE, unexpected exceptions count as failures: @@ -1266,7 +1266,7 @@ Exception raised: ... ValueError: 2 - (3, 5) + TestResults(failed=3, attempted=5) New option flags can also be registered, via register_optionflag(). Here we reach into doctest's internals a bit. @@ -1315,7 +1315,7 @@ [0, 1, ..., 9] Got: [0, 1, 2, 3, 4, 5, 6, 7, 8, 9] - (1, 2) + TestResults(failed=1, attempted=2) To turn an option off for an example, follow that example with a comment of the form ``# doctest: -OPTION``: @@ -1340,7 +1340,7 @@ [0, 1, ..., 9] Got: [0, 1, 2, 3, 4, 5, 6, 7, 8, 9] - (1, 2) + TestResults(failed=1, attempted=2) Option directives affect only the example that they appear with; they do not change the options for surrounding examples: @@ -1374,7 +1374,7 @@ [0, 1, ..., 9] Got: [0, 1, 2, 3, 4, 5, 6, 7, 8, 9] - (2, 3) + TestResults(failed=2, attempted=3) Multiple options may be modified by a single option directive. They may be separated by whitespace, commas, or both: @@ -1397,7 +1397,7 @@ [0, 1, ..., 9] Got: [0, 1, 2, 3, 4, 5, 6, 7, 8, 9] - (1, 2) + TestResults(failed=1, attempted=2) >>> def f(x): r''' ... >>> print range(10) # Should fail @@ -1417,7 +1417,7 @@ [0, 1, ..., 9] Got: [0, 1, 2, 3, 4, 5, 6, 7, 8, 9] - (1, 2) + TestResults(failed=1, attempted=2) >>> def f(x): r''' ... >>> print range(10) # Should fail @@ -1437,7 +1437,7 @@ [0, 1, ..., 9] Got: [0, 1, 2, 3, 4, 5, 6, 7, 8, 9] - (1, 2) + TestResults(failed=1, attempted=2) The option directive may be put on the line following the source, as long as a continuation prompt is used: @@ -1449,7 +1449,7 @@ ... ''' >>> test = doctest.DocTestFinder().find(f)[0] >>> doctest.DocTestRunner(verbose=False).run(test) - (0, 1) + TestResults(failed=0, attempted=1) For examples with multi-line source, the option directive may appear at the end of any line: @@ -1465,7 +1465,7 @@ ... ''' >>> test = doctest.DocTestFinder().find(f)[0] >>> doctest.DocTestRunner(verbose=False).run(test) - (0, 2) + TestResults(failed=0, attempted=2) If more than one line of an example with multi-line source has an option directive, then they are combined: @@ -1478,7 +1478,7 @@ ... ''' >>> test = doctest.DocTestFinder().find(f)[0] >>> doctest.DocTestRunner(verbose=False).run(test) - (0, 1) + TestResults(failed=0, attempted=1) It is an error to have a comment of the form ``# doctest:`` that is *not* followed by words of the form ``+OPTION`` or ``-OPTION``, where @@ -1613,7 +1613,7 @@ (Pdb) print x 42 (Pdb) continue - (0, 2) + TestResults(failed=0, attempted=2) You can also put pdb.set_trace in a function called from a test: @@ -1649,7 +1649,7 @@ (Pdb) print x 1 (Pdb) continue - (0, 2) + TestResults(failed=0, attempted=2) During interactive debugging, source code is shown, even for doctest examples: @@ -1706,7 +1706,7 @@ Expected nothing Got: 9 - (1, 3) + TestResults(failed=1, attempted=3) """ def test_pdb_set_trace_nested(): @@ -1791,7 +1791,7 @@ (Pdb) print foo *** NameError: name 'foo' is not defined (Pdb) continue - (0, 2) + TestResults(failed=0, attempted=2) """ def test_DocTestSuite(): @@ -2152,7 +2152,7 @@ 1 items had failures: 1 of 2 in test_doctest.txt ***Test Failed*** 1 failures. - (1, 2) + TestResults(failed=1, attempted=2) >>> doctest.master = None # Reset master. (Note: we'll be clearing doctest.master after each call to @@ -2163,7 +2163,7 @@ >>> globs = {'favorite_color': 'blue'} >>> doctest.testfile('test_doctest.txt', globs=globs) - (0, 2) + TestResults(failed=0, attempted=2) >>> doctest.master = None # Reset master. >>> extraglobs = {'favorite_color': 'red'} @@ -2181,7 +2181,7 @@ 1 items had failures: 1 of 2 in test_doctest.txt ***Test Failed*** 1 failures. - (1, 2) + TestResults(failed=1, attempted=2) >>> doctest.master = None # Reset master. The file may be made relative to a given module or package, using the @@ -2189,7 +2189,7 @@ >>> doctest.testfile('test_doctest.txt', globs=globs, ... module_relative='test') - (0, 2) + TestResults(failed=0, attempted=2) >>> doctest.master = None # Reset master. Verbosity can be increased with the optional `verbose` paremter: @@ -2215,7 +2215,7 @@ 2 tests in 1 items. 2 passed and 0 failed. Test passed. - (0, 2) + TestResults(failed=0, attempted=2) >>> doctest.master = None # Reset master. The name of the test may be specified with the optional `name` @@ -2226,7 +2226,7 @@ ********************************************************************** File "...", line 6, in newname ... - (1, 2) + TestResults(failed=1, attempted=2) >>> doctest.master = None # Reset master. The summary report may be supressed with the optional `report` @@ -2241,7 +2241,7 @@ Exception raised: ... NameError: name 'favorite_color' is not defined - (1, 2) + TestResults(failed=1, attempted=2) >>> doctest.master = None # Reset master. The optional keyword argument `raise_on_error` can be used to raise an @@ -2273,11 +2273,11 @@ 1 items had failures: 2 of 4 in test_doctest4.txt ***Test Failed*** 2 failures. - (2, 4) + TestResults(failed=2, attempted=4) >>> doctest.master = None # Reset master. >>> doctest.testfile('test_doctest4.txt', encoding='utf-8') - (0, 4) + TestResults(failed=0, attempted=4) >>> doctest.master = None # Reset master. """ @@ -2307,15 +2307,15 @@ 42 Got: 84 -(1, 2) +TestResults(failed=1, attempted=2) >>> t.runstring(">>> x = x * 2\n>>> print x\n84\n", 'example2') -(0, 2) +TestResults(failed=0, attempted=2) >>> t.summarize() ********************************************************************** 1 items had failures: 1 of 2 in XYZ ***Test Failed*** 1 failures. -(1, 4) +TestResults(failed=1, attempted=4) >>> t.summarize(verbose=1) 1 items passed all tests: 2 tests in example2 @@ -2325,7 +2325,7 @@ 4 tests in 2 items. 3 passed and 1 failed. ***Test Failed*** 1 failures. -(1, 4) +TestResults(failed=1, attempted=4) """ def old_test2(): r""" @@ -2349,7 +2349,7 @@ 3 ok 0 of 2 examples failed in string Example - (0, 2) + TestResults(failed=0, attempted=2) """ def old_test3(): r""" @@ -2362,7 +2362,7 @@ ... return 32 ... >>> t.rundoc(_f) # expect 0 failures in 1 example - (0, 1) + TestResults(failed=0, attempted=1) """ def old_test4(): """ @@ -2392,19 +2392,19 @@ >>> from doctest import Tester >>> t = Tester(globs={}, verbose=0) >>> t.rundict(m1.__dict__, "rundict_test", m1) # f2 and g2 and h2 skipped - (0, 4) + TestResults(failed=0, attempted=4) Once more, not excluding stuff outside m1: >>> t = Tester(globs={}, verbose=0) >>> t.rundict(m1.__dict__, "rundict_test_pvt") # None are skipped. - (0, 8) + TestResults(failed=0, attempted=8) The exclusion of objects from outside the designated module is meant to be invoked automagically by testmod. >>> doctest.testmod(m1, verbose=False) - (0, 4) + TestResults(failed=0, attempted=4) """ ###################################################################### Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Fri Jan 11 02:25:54 2008 @@ -351,6 +351,9 @@ Library ------- +- Doctest now returns results as a named tuple for readability: + (0, 7) --> TestResults(failed=0, attempted=7) + - Issue #846388. re.match is interruptible now, which is particularly good for long regular expression matches. From python-checkins at python.org Fri Jan 11 03:12:34 2008 From: python-checkins at python.org (raymond.hettinger) Date: Fri, 11 Jan 2008 03:12:34 +0100 (CET) Subject: [Python-checkins] r59904 - python/trunk/Modules/socketmodule.c Message-ID: <20080111021234.1FD381E400A@bag.python.org> Author: raymond.hettinger Date: Fri Jan 11 03:12:33 2008 New Revision: 59904 Modified: python/trunk/Modules/socketmodule.c Log: Comment-out missing constant (from rev 59819) Modified: python/trunk/Modules/socketmodule.c ============================================================================== --- python/trunk/Modules/socketmodule.c (original) +++ python/trunk/Modules/socketmodule.c Fri Jan 11 03:12:33 2008 @@ -4591,7 +4591,7 @@ /* for subscriptions */ PyModule_AddIntConstant(m, "TIPC_SUB_PORTS", TIPC_SUB_PORTS); PyModule_AddIntConstant(m, "TIPC_SUB_SERVICE", TIPC_SUB_SERVICE); - PyModule_AddIntConstant(m, "TIPC_SUB_CANCEL", TIPC_SUB_CANCEL); + /* PyModule_AddIntConstant(m, "TIPC_SUB_CANCEL", TIPC_SUB_CANCEL); XXX This var is missing on gcc (GCC) 4.1.1 (Gentoo 4.1.1) and it breaks the build */ PyModule_AddIntConstant(m, "TIPC_WAIT_FOREVER", TIPC_WAIT_FOREVER); PyModule_AddIntConstant(m, "TIPC_PUBLISHED", TIPC_PUBLISHED); PyModule_AddIntConstant(m, "TIPC_WITHDRAWN", TIPC_WITHDRAWN); From python-checkins at python.org Fri Jan 11 03:24:13 2008 From: python-checkins at python.org (raymond.hettinger) Date: Fri, 11 Jan 2008 03:24:13 +0100 (CET) Subject: [Python-checkins] r59905 - python/trunk/Lib/decimal.py Message-ID: <20080111022413.962961E4009@bag.python.org> Author: raymond.hettinger Date: Fri Jan 11 03:24:13 2008 New Revision: 59905 Modified: python/trunk/Lib/decimal.py Log: Have Decimal.as_tuple return a named tuple. Modified: python/trunk/Lib/decimal.py ============================================================================== --- python/trunk/Lib/decimal.py (original) +++ python/trunk/Lib/decimal.py Fri Jan 11 03:24:13 2008 @@ -136,6 +136,12 @@ import copy as _copy +try: + from collections import namedtuple as _namedtuple + DecimalTuple = _namedtuple('DecimalTuple', 'sign digits exponent') +except ImportError: + DecimalTuple = lambda *args: args + # Rounding ROUND_DOWN = 'ROUND_DOWN' ROUND_HALF_UP = 'ROUND_HALF_UP' @@ -820,7 +826,7 @@ To show the internals exactly as they are. """ - return (self._sign, tuple(map(int, self._int)), self._exp) + return DecimalTuple(self._sign, tuple(map(int, self._int)), self._exp) def __repr__(self): """Represents the number as an instance of Decimal.""" From buildbot at python.org Fri Jan 11 03:28:34 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 11 Jan 2008 02:28:34 +0000 Subject: [Python-checkins] buildbot failure in hppa Ubuntu trunk Message-ID: <20080111022835.11B021E4009@bag.python.org> The Buildbot has detected a new failure of hppa Ubuntu trunk. Full details are available at: http://www.python.org/dev/buildbot/all/hppa%20Ubuntu%20trunk/builds/496 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-ubuntu-hppa Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_bsddb3 ====================================================================== ERROR: test00_associateDBError (bsddb.test.test_associate.AssociateErrorTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 104, in setUp self.env.open(homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateBTreeTxnTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateBTreeTxnTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test13_associate_in_transaction (bsddb.test.test_associate.AssociateBTreeTxnTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ShelveAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ShelveAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ShelveAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ThreadedAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ThreadedAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ThreadedAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ThreadedAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ThreadedAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ThreadedAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_EnvRemoveAndRename (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_EnvRemoveAndRename (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Transactions (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_TxnTruncate (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test08_TxnLateUse (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Transactions (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_TxnTruncate (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test08_TxnLateUse (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test09_MultiDB (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test09_MultiDB (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_both (bsddb.test.test_dbobj.dbobjTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbobj.py", line 45, in test01_both self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbobj.py", line 39, in open return apply(self._cobj.open, args, kwargs) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_dbobj_dict_interface (bsddb.test.test_dbobj.dbobjTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbobj.py", line 58, in test02_dbobj_dict_interface self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbobj.py", line 39, in open return apply(self._cobj.open, args, kwargs) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01 (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02 (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03 (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_MultiCondSelect (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_CondObjs (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_CreateOrExtend (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_Delete (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_Modify (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_close_dbenv_before_db (bsddb.test.test_env_close.DBEnvClosedEarlyCrash) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_env_close.py", line 53, in test01_close_dbenv_before_db 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_close_dbenv_delete_db_success (bsddb.test.test_env_close.DBEnvClosedEarlyCrash) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_env_close.py", line 78, in test02_close_dbenv_delete_db_success 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_join (bsddb.test.test_join.JoinTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_join.py", line 57, in setUp self.env.open(homeDir, db.DB_CREATE | db.DB_INIT_MPOOL | db.DB_INIT_LOCK ) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_simple (bsddb.test.test_lock.LockingTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_lock.py", line 38, in setUp db.DB_INIT_LOCK | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_threaded (bsddb.test.test_lock.LockingTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_lock.py", line 38, in setUp db.DB_INIT_LOCK | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_set_timeout (bsddb.test.test_lock.LockingTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_lock.py", line 38, in setUp db.DB_INIT_LOCK | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_db_home (bsddb.test.test_misc.MiscTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_misc.py", line 45, in test02_db_home env.open(self.homeDir, db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_1WriterMultiReaders (bsddb.test.test_thread.BTreeConcurrentDataStore) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_1WriterMultiReaders (bsddb.test.test_thread.HashConcurrentDataStore) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_SimpleLocks (bsddb.test.test_thread.BTreeSimpleThreaded) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_SimpleLocks (bsddb.test.test_thread.HashSimpleThreaded) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.BTreeThreadedTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.HashThreadedTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.BTreeThreadedNoWaitTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.HashThreadedNoWaitTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_cachesize (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_flags (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_get (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_get_dbp (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_get_key (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_range (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_remove (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_stat (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_pget (bsddb.test.test_cursor_pget_bug.pget_bugTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_cursor_pget_bug.py", line 25, in setUp self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Fri Jan 11 04:04:51 2008 From: python-checkins at python.org (raymond.hettinger) Date: Fri, 11 Jan 2008 04:04:51 +0100 (CET) Subject: [Python-checkins] r59906 - python/trunk/Lib/inspect.py Message-ID: <20080111030451.0EDE31E4009@bag.python.org> Author: raymond.hettinger Date: Fri Jan 11 04:04:50 2008 New Revision: 59906 Modified: python/trunk/Lib/inspect.py Log: Let most inspect functions return named tuples Modified: python/trunk/Lib/inspect.py ============================================================================== --- python/trunk/Lib/inspect.py (original) +++ python/trunk/Lib/inspect.py Fri Jan 11 04:04:50 2008 @@ -30,6 +30,7 @@ import sys, os, types, string, re, dis, imp, tokenize, linecache from operator import attrgetter +from collections import namedtuple # ----------------------------------------------------------- type-checking def ismodule(object): @@ -209,6 +210,8 @@ results.sort() return results +Attribute = namedtuple('Attribute', 'name kind defining_class object') + def classify_class_attrs(cls): """Return list of attribute-descriptor tuples. @@ -275,7 +278,7 @@ else: kind = "data" - result.append((name, kind, homecls, obj)) + result.append(Attribute(name, kind, homecls, obj)) return result @@ -363,6 +366,8 @@ raise TypeError('arg is not a module, class, method, ' 'function, traceback, frame, or code object') +ModuleInfo = namedtuple('ModuleInfo', 'name suffix mode module_type') + def getmoduleinfo(path): """Get the module name, suffix, mode, and module type for a given file.""" filename = os.path.basename(path) @@ -371,7 +376,7 @@ suffixes.sort() # try longest suffixes first, in case they overlap for neglen, suffix, mode, mtype in suffixes: if filename[neglen:] == suffix: - return filename[:neglen], suffix, mode, mtype + return ModuleInfo(filename[:neglen], suffix, mode, mtype) def getmodulename(path): """Return the module name for a given file, or None.""" @@ -669,6 +674,8 @@ # These constants are from Python's compile.h. CO_OPTIMIZED, CO_NEWLOCALS, CO_VARARGS, CO_VARKEYWORDS = 1, 2, 4, 8 +Arguments = namedtuple('Arguments', 'args varargs keywords') + def getargs(co): """Get information about the arguments accepted by a code object. @@ -725,7 +732,9 @@ varkw = None if co.co_flags & CO_VARKEYWORDS: varkw = co.co_varnames[nargs] - return args, varargs, varkw + return Arguments(args, varargs, varkw) + +ArgSpec = namedtuple('ArgSpec', 'args varargs keywords defaults') def getargspec(func): """Get the names and default values of a function's arguments. @@ -741,7 +750,9 @@ if not isfunction(func): raise TypeError('arg is not a Python function') args, varargs, varkw = getargs(func.func_code) - return args, varargs, varkw, func.func_defaults + return ArgSpec(args, varargs, varkw, func.func_defaults) + +ArgInfo = namedtuple('ArgInfo', 'args varargs keywords locals') def getargvalues(frame): """Get information about arguments passed into a particular frame. @@ -817,6 +828,9 @@ return '(' + string.join(specs, ', ') + ')' # -------------------------------------------------- stack frame extraction + +Traceback = namedtuple('Traceback', 'filename lineno function code_context index') + def getframeinfo(frame, context=1): """Get information about a frame or traceback object. @@ -848,7 +862,7 @@ else: lines = index = None - return (filename, lineno, frame.f_code.co_name, lines, index) + return Traceback(filename, lineno, frame.f_code.co_name, lines, index) def getlineno(frame): """Get the line number from a frame object, allowing for optimization.""" From python-checkins at python.org Fri Jan 11 04:20:55 2008 From: python-checkins at python.org (raymond.hettinger) Date: Fri, 11 Jan 2008 04:20:55 +0100 (CET) Subject: [Python-checkins] r59907 - python/trunk/Lib/difflib.py Message-ID: <20080111032055.1187B1E4009@bag.python.org> Author: raymond.hettinger Date: Fri Jan 11 04:20:54 2008 New Revision: 59907 Modified: python/trunk/Lib/difflib.py Log: Improve usability of the SequenceMatcher by returning named tuples describing match ranges. Modified: python/trunk/Lib/difflib.py ============================================================================== --- python/trunk/Lib/difflib.py (original) +++ python/trunk/Lib/difflib.py Fri Jan 11 04:20:54 2008 @@ -30,9 +30,12 @@ __all__ = ['get_close_matches', 'ndiff', 'restore', 'SequenceMatcher', 'Differ','IS_CHARACTER_JUNK', 'IS_LINE_JUNK', 'context_diff', - 'unified_diff', 'HtmlDiff'] + 'unified_diff', 'HtmlDiff', 'Match'] import heapq +from collections import namedtuple as _namedtuple + +Match = _namedtuple('Match', 'a b size') def _calculate_ratio(matches, length): if length: @@ -363,7 +366,7 @@ >>> s = SequenceMatcher(None, " abcd", "abcd abcd") >>> s.find_longest_match(0, 5, 0, 9) - (0, 4, 5) + Match(a=0, b=4, size=5) If isjunk is defined, first the longest matching block is determined as above, but with the additional restriction that no @@ -379,13 +382,13 @@ >>> s = SequenceMatcher(lambda x: x==" ", " abcd", "abcd abcd") >>> s.find_longest_match(0, 5, 0, 9) - (1, 0, 4) + Match(a=1, b=0, size=4) If no blocks match, return (alo, blo, 0). >>> s = SequenceMatcher(None, "ab", "c") >>> s.find_longest_match(0, 2, 0, 1) - (0, 0, 0) + Match(a=0, b=0, size=0) """ # CAUTION: stripping common prefix or suffix would be incorrect. @@ -452,7 +455,7 @@ a[besti+bestsize] == b[bestj+bestsize]: bestsize = bestsize + 1 - return besti, bestj, bestsize + return Match(besti, bestj, bestsize) def get_matching_blocks(self): """Return list of triples describing matching subsequences. @@ -470,7 +473,7 @@ >>> s = SequenceMatcher(None, "abxcd", "abcd") >>> s.get_matching_blocks() - [(0, 0, 2), (3, 2, 2), (5, 4, 0)] + [Match(a=0, b=0, size=2), Match(a=3, b=2, size=2), Match(a=5, b=4, size=0)] """ if self.matching_blocks is not None: @@ -523,7 +526,7 @@ non_adjacent.append( (la, lb, 0) ) self.matching_blocks = non_adjacent - return self.matching_blocks + return map(Match._make, self.matching_blocks) def get_opcodes(self): """Return list of 5-tuples describing how to turn a into b. From python-checkins at python.org Fri Jan 11 09:04:04 2008 From: python-checkins at python.org (thomas.heller) Date: Fri, 11 Jan 2008 09:04:04 +0100 (CET) Subject: [Python-checkins] r59909 - python/trunk/PCbuild/build_tkinter.py Message-ID: <20080111080404.122471E400A@bag.python.org> Author: thomas.heller Date: Fri Jan 11 09:04:03 2008 New Revision: 59909 Modified: python/trunk/PCbuild/build_tkinter.py Log: Add an important missing blank. Modified: python/trunk/PCbuild/build_tkinter.py ============================================================================== --- python/trunk/PCbuild/build_tkinter.py (original) +++ python/trunk/PCbuild/build_tkinter.py Fri Jan 11 09:04:03 2008 @@ -25,7 +25,7 @@ # Windows 2000 compatibility: WINVER 0x0500 # http://msdn2.microsoft.com/en-us/library/aa383745.aspx NMAKE = ('nmake /nologo /f %s ' - 'COMPILERFLAGS=\"-DWINVER=0x0500 -D_WIN32_WINNT=0x0500 -DNTDDI_VERSION=NTDDI_WIN2KSP4\"' + 'COMPILERFLAGS=\"-DWINVER=0x0500 -D_WIN32_WINNT=0x0500 -DNTDDI_VERSION=NTDDI_WIN2KSP4\" ' '%s %s') def nmake(makefile, command="", **kw): From buildbot at python.org Fri Jan 11 09:41:05 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 11 Jan 2008 08:41:05 +0000 Subject: [Python-checkins] buildbot failure in x86 XP-3 trunk Message-ID: <20080111084105.5FBEE1E400A@bag.python.org> The Buildbot has detected a new failure of x86 XP-3 trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20XP-3%20trunk/builds/637 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: heller-windows Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: thomas.heller BUILD FAILED: failed test Excerpt from the test logfile: sincerely, -The Buildbot From python-checkins at python.org Fri Jan 11 10:19:11 2008 From: python-checkins at python.org (georg.brandl) Date: Fri, 11 Jan 2008 10:19:11 +0100 (CET) Subject: [Python-checkins] r59910 - python/trunk/Modules/socketmodule.c Message-ID: <20080111091911.E20F11E4021@bag.python.org> Author: georg.brandl Date: Fri Jan 11 10:19:11 2008 New Revision: 59910 Modified: python/trunk/Modules/socketmodule.c Log: Guard definition of TIPC_SUB_CANCEL with an #ifdef. Modified: python/trunk/Modules/socketmodule.c ============================================================================== --- python/trunk/Modules/socketmodule.c (original) +++ python/trunk/Modules/socketmodule.c Fri Jan 11 10:19:11 2008 @@ -4591,7 +4591,10 @@ /* for subscriptions */ PyModule_AddIntConstant(m, "TIPC_SUB_PORTS", TIPC_SUB_PORTS); PyModule_AddIntConstant(m, "TIPC_SUB_SERVICE", TIPC_SUB_SERVICE); - /* PyModule_AddIntConstant(m, "TIPC_SUB_CANCEL", TIPC_SUB_CANCEL); XXX This var is missing on gcc (GCC) 4.1.1 (Gentoo 4.1.1) and it breaks the build */ +#ifdef TIPC_SUB_CANCEL + /* doesn't seem to be available everywhere */ + PyModule_AddIntConstant(m, "TIPC_SUB_CANCEL", TIPC_SUB_CANCEL); +#endif PyModule_AddIntConstant(m, "TIPC_WAIT_FOREVER", TIPC_WAIT_FOREVER); PyModule_AddIntConstant(m, "TIPC_PUBLISHED", TIPC_PUBLISHED); PyModule_AddIntConstant(m, "TIPC_WITHDRAWN", TIPC_WITHDRAWN); From python-checkins at python.org Fri Jan 11 10:20:58 2008 From: python-checkins at python.org (georg.brandl) Date: Fri, 11 Jan 2008 10:20:58 +0100 (CET) Subject: [Python-checkins] r59911 - python/trunk/Misc/NEWS Message-ID: <20080111092058.889A71E402B@bag.python.org> Author: georg.brandl Date: Fri Jan 11 10:20:58 2008 New Revision: 59911 Modified: python/trunk/Misc/NEWS Log: News entries for rev. 5990[567]. Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Fri Jan 11 10:20:58 2008 @@ -351,6 +351,9 @@ Library ------- +- Decimal.as_tuple(), difflib.find_longest_match() and inspect functions + that returned a tuple now return a named tuple. + - Doctest now returns results as a named tuple for readability: (0, 7) --> TestResults(failed=0, attempted=7) From python-checkins at python.org Fri Jan 11 10:55:53 2008 From: python-checkins at python.org (georg.brandl) Date: Fri, 11 Jan 2008 10:55:53 +0100 (CET) Subject: [Python-checkins] r59912 - in python/trunk/Doc: glossary.rst library/decimal.rst library/difflib.rst library/doctest.rst library/inspect.rst Message-ID: <20080111095553.B282B1E400C@bag.python.org> Author: georg.brandl Date: Fri Jan 11 10:55:53 2008 New Revision: 59912 Modified: python/trunk/Doc/glossary.rst python/trunk/Doc/library/decimal.rst python/trunk/Doc/library/difflib.rst python/trunk/Doc/library/doctest.rst python/trunk/Doc/library/inspect.rst Log: Documentation for r5990[3567]. Modified: python/trunk/Doc/glossary.rst ============================================================================== --- python/trunk/Doc/glossary.rst (original) +++ python/trunk/Doc/glossary.rst Fri Jan 11 10:55:53 2008 @@ -338,6 +338,13 @@ mutable Mutable objects can change their value but keep their :func:`id`. See also :term:`immutable`. + + named tuple + A tuple subclass whose elements also are accessible as attributes via + fixed names (the class name and field names are indicated in the + individual documentation of a named tuple type, like ``TestResults(failed, + attempted)``). Named tuple classes are created by + :func:`collections.namedtuple`. namespace The place where a variable is stored. Namespaces are implemented as Modified: python/trunk/Doc/library/decimal.rst ============================================================================== --- python/trunk/Doc/library/decimal.rst (original) +++ python/trunk/Doc/library/decimal.rst Fri Jan 11 10:55:53 2008 @@ -333,7 +333,11 @@ .. method:: Decimal.as_tuple() - Return a tuple representation of the number: ``(sign, digit_tuple, exponent)``. + Return a :term:`named tuple` representation of the number: + ``DecimalTuple(sign, digits, exponent)``. + + .. versionchanged:: 2.6 + Use a named tuple. .. method:: Decimal.canonical() Modified: python/trunk/Doc/library/difflib.rst ============================================================================== --- python/trunk/Doc/library/difflib.rst (original) +++ python/trunk/Doc/library/difflib.rst Fri Jan 11 10:55:53 2008 @@ -344,7 +344,7 @@ Find longest matching block in ``a[alo:ahi]`` and ``b[blo:bhi]``. - If *isjunk* was omitted or ``None``, :meth:`get_longest_match` returns ``(i, j, + If *isjunk* was omitted or ``None``, :meth:`find_longest_match` returns ``(i, j, k)`` such that ``a[i:i+k]`` is equal to ``b[j:j+k]``, where ``alo <= i <= i+k <= ahi`` and ``blo <= j <= j+k <= bhi``. For all ``(i', j', k')`` meeting those conditions, the additional conditions ``k >= k'``, ``i <= i'``, and if ``i == @@ -373,6 +373,9 @@ If no blocks match, this returns ``(alo, blo, 0)``. + .. versionchanged:: 2.6 + This method returns a :term:`named tuple` ``Match(a, b, size)``. + .. method:: SequenceMatcher.get_matching_blocks() Modified: python/trunk/Doc/library/doctest.rst ============================================================================== --- python/trunk/Doc/library/doctest.rst (original) +++ python/trunk/Doc/library/doctest.rst Fri Jan 11 10:55:53 2008 @@ -1506,11 +1506,14 @@ .. method:: DocTestRunner.summarize([verbose]) Print a summary of all the test cases that have been run by this DocTestRunner, - and return a tuple ``(failure_count, test_count)``. + and return a :term:`named tuple` ``TestResults(failed, attempted)``. The optional *verbose* argument controls how detailed the summary is. If the verbosity is not specified, then the :class:`DocTestRunner`'s verbosity is used. + .. versionchanged:: 2.6 + Use a named tuple. + .. _doctest-outputchecker: Modified: python/trunk/Doc/library/inspect.rst ============================================================================== --- python/trunk/Doc/library/inspect.rst (original) +++ python/trunk/Doc/library/inspect.rst Fri Jan 11 10:55:53 2008 @@ -214,6 +214,10 @@ defined in the :mod:`imp` module; see the documentation for that module for more information on module types. + .. versionchanged:: 2.6 + Returns a :term:`named tuple` ``ModuleInfo(name, suffix, mode, + module_type)``. + .. function:: getmodulename(path) @@ -405,6 +409,10 @@ default argument values or None if there are no default arguments; if this tuple has *n* elements, they correspond to the last *n* elements listed in *args*. + .. versionchanged:: 2.6 + Returns a :term:`named tuple` ``ArgSpec(args, varargs, keywords, + defaults)``. + .. function:: getargvalues(frame) @@ -414,6 +422,10 @@ names of the ``*`` and ``**`` arguments or ``None``. *locals* is the locals dictionary of the given frame. + .. versionchanged:: 2.6 + Returns a :term:`named tuple` ``ArgInfo(args, varargs, keywords, + locals)``. + .. function:: formatargspec(args[, varargs, varkw, defaults, formatarg, formatvarargs, formatvarkw, formatvalue, join]) @@ -479,6 +491,10 @@ Get information about a frame or traceback object. A 5-tuple is returned, the last five elements of the frame's frame record. + .. versionchanged:: 2.6 + Returns a :term:`named tuple` ``Traceback(filename, lineno, function, + code_context, index)``. + .. function:: getouterframes(frame[, context]) From buildbot at python.org Fri Jan 11 11:28:56 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 11 Jan 2008 10:28:56 +0000 Subject: [Python-checkins] buildbot failure in x86 FreeBSD trunk Message-ID: <20080111102856.E53431E400A@bag.python.org> The Buildbot has detected a new failure of x86 FreeBSD trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20FreeBSD%20trunk/builds/381 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-freebsd Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: georg.brandl BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 523, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable 1 test failed: test_xmlrpc Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 523, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 523, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 523, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable ====================================================================== ERROR: test_introspection3 (test.test_xmlrpc.SimpleServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/test/test_xmlrpc.py", line 436, in test_introspection3 myfunction = p.system.methodHelp('my_function') File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/xmlrpclib.py", line 1157, in __call__ return self.__send(self.__name, args) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/xmlrpclib.py", line 1447, in __request verbose=self.__verbose File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/xmlrpclib.py", line 1193, in request self.send_content(h, request_body) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/xmlrpclib.py", line 1309, in send_content connection.send(request_body) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/httplib.py", line 701, in send self.sock.sendall(str) File "", line 1, in sendall error: [Errno 32] Broken pipe sincerely, -The Buildbot From python-checkins at python.org Fri Jan 11 13:41:39 2008 From: python-checkins at python.org (thomas.heller) Date: Fri, 11 Jan 2008 13:41:39 +0100 (CET) Subject: [Python-checkins] r59913 - python/trunk/PCbuild/_sqlite3.vcproj Message-ID: <20080111124139.B67A21E400A@bag.python.org> Author: thomas.heller Date: Fri Jan 11 13:41:39 2008 New Revision: 59913 Modified: python/trunk/PCbuild/_sqlite3.vcproj Log: The sqlite3 dll, when compiled in debug mode, must be linked with /MDd to use the debug runtime library. Further, the dll will be named sqlite3_d.dll. Modified: python/trunk/PCbuild/_sqlite3.vcproj ============================================================================== --- python/trunk/PCbuild/_sqlite3.vcproj (original) +++ python/trunk/PCbuild/_sqlite3.vcproj Fri Jan 11 13:41:39 2008 @@ -54,11 +54,11 @@ The Buildbot has detected a new failure of ppc Debian unstable trunk. Full details are available at: http://www.python.org/dev/buildbot/all/ppc%20Debian%20unstable%20trunk/builds/574 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: georg.brandl,thomas.heller BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30995, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') 1 test failed: test_xmlrpc Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/SocketServer.py", line 523, in __init__ self.handle() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/BaseHTTPServer.py", line 310, in handle_one_request method() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/SimpleXMLRPCServer.py", line 449, in do_POST self.report_404() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/SimpleXMLRPCServer.py", line 507, in report_404 self.connection.shutdown(1) File "", line 1, in shutdown error: [Errno 107] Transport endpoint is not connected ====================================================================== ERROR: test_fail_with_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_xmlrpc.py", line 580, in test_fail_with_info p.pow(6,8) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1157, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1447, in __request verbose=self.__verbose File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1195, in request errcode, errmsg, headers = h.getreply() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 1006, in getreply response = self._conn.getresponse() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 932, in getresponse response.begin() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 415, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 271, in readheaders line = self.fp.readline() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/socket.py", line 354, in readline data = recv(1) error: [Errno 104] Connection reset by peer make: *** [buildbottest] Error 1 sincerely, -The Buildbot From amauryfa at gmail.com Fri Jan 11 14:49:14 2008 From: amauryfa at gmail.com (Amaury Forgeot d'Arc) Date: Fri, 11 Jan 2008 14:49:14 +0100 Subject: [Python-checkins] r59913 - python/trunk/PCbuild/_sqlite3.vcproj Message-ID: Hello Thomas, It seems that you modified the PGInstrument and PGUpdate configurations. Is it on purpose? IMO they should not be considered as debug builds. Also, in addition of the /MDd option, I propose to use all the usual debug options. My preferred are: cl /nologo /DNO_TCL /D_DEBUG /Od /Zi /MDd ..\*.c link /nologo /dll /debug /def:..\sqlite3.def /out:sqlite3_d.dll *.obj -- Amaury Forgeot d'Arc From python-checkins at python.org Fri Jan 11 15:08:11 2008 From: python-checkins at python.org (georg.brandl) Date: Fri, 11 Jan 2008 15:08:11 +0100 (CET) Subject: [Python-checkins] r59915 - doctools/trunk/sphinx/roles.py Message-ID: <20080111140811.D3BE81E4092@bag.python.org> Author: georg.brandl Date: Fri Jan 11 15:08:11 2008 New Revision: 59915 Modified: doctools/trunk/sphinx/roles.py Log: Remove parentheses if the occur in :func: etc. roles. Modified: doctools/trunk/sphinx/roles.py ============================================================================== --- doctools/trunk/sphinx/roles.py (original) +++ doctools/trunk/sphinx/roles.py Fri Jan 11 15:08:11 2008 @@ -105,9 +105,13 @@ def xfileref_role(typ, rawtext, text, lineno, inliner, options={}, content=[]): env = inliner.document.settings.env text = utils.unescape(text) - if typ in ('func', 'meth', 'cfunc') and \ - env.config.get('add_function_parentheses', True): - text += '()' + if typ in ('func', 'meth', 'cfunc'): + if text.endswith('()'): + # remove parentheses + text = text[:-2] + if env.config.get('add_function_parentheses', True): + # add them back to all occurrences if configured + text += '()' # if the first character is a bang, don't cross-reference at all if text[0:1] == '!': text = text[1:] From theller at ctypes.org Fri Jan 11 15:14:02 2008 From: theller at ctypes.org (Thomas Heller) Date: Fri, 11 Jan 2008 15:14:02 +0100 Subject: [Python-checkins] r59913 - python/trunk/PCbuild/_sqlite3.vcproj In-Reply-To: References: Message-ID: <478779AA.7040003@ctypes.org> Amaury Forgeot d'Arc schrieb: > Hello Thomas, > > It seems that you modified the PGInstrument and PGUpdate > configurations. Is it on purpose? IMO they should not be considered as > debug builds. No, that was not intended. > Also, in addition of the /MDd option, I propose to use all the usual > debug options. My preferred are: > cl /nologo /DNO_TCL /D_DEBUG /Od /Zi /MDd ..\*.c > link /nologo /dll /debug /def:..\sqlite3.def /out:sqlite3_d.dll *.obj > Yes, but I'm no longer sure whether sqlite3.dll should be compiled in debug mode for a Python debug build at all. I made this change only because the debug python cannot import the sqlite3 module because the (non-debug) MSVCR90.DLL runtime library is not found. I tried to install the Microsoft.VC90.CRT non-debug runtime in several ways, but I did not succeed. Do you (or anyone else) know how to make that library available so that it will be found by sqlite3.dll when running the debug Python? The same problem occurs with tcl/tk. Even wish84.exe does not start... I think it's best to revert this checkin. Thomas BTW: The win/amd64 version is in an even sadder state. tcl/tk does not build with visual studio 2008 because it links with the non-existing bufferoverflowU.lib (it does still build with the SDK compiler), and bsddb does not build in debug mode at all - it does not even create a libdb44*.lib static link library). From python-checkins at python.org Fri Jan 11 15:18:20 2008 From: python-checkins at python.org (georg.brandl) Date: Fri, 11 Jan 2008 15:18:20 +0100 (CET) Subject: [Python-checkins] r59916 - in doctools/trunk: convert.py converter/__init__.py converter/docnodes.py converter/filenamemap.py converter/latexparser.py converter/restwriter.py converter/tokenizer.py converter/util.py sphinx-build.py sphinx-web.py sphinx/__init__.py sphinx/_jinja.py sphinx/addnodes.py sphinx/builder.py sphinx/directives.py sphinx/environment.py sphinx/highlighting.py sphinx/htmlhelp.py sphinx/htmlwriter.py sphinx/latexwriter.py sphinx/patchlevel.py sphinx/refcounting.py sphinx/roles.py sphinx/search.py sphinx/util/__init__.py sphinx/util/console.py sphinx/util/json.py sphinx/web/__init__.py sphinx/web/admin.py sphinx/web/antispam.py sphinx/web/application.py sphinx/web/database.py sphinx/web/feed.py sphinx/web/mail.py sphinx/web/markup.py sphinx/web/oldurls.py sphinx/web/robots.py sphinx/web/serve.py sphinx/web/userdb.py sphinx/web/util.py sphinx/web/wsgiutil.py Message-ID: <20080111141820.419FA1E400A@bag.python.org> Author: georg.brandl Date: Fri Jan 11 15:18:19 2008 New Revision: 59916 Modified: doctools/trunk/convert.py doctools/trunk/converter/__init__.py doctools/trunk/converter/docnodes.py doctools/trunk/converter/filenamemap.py doctools/trunk/converter/latexparser.py doctools/trunk/converter/restwriter.py doctools/trunk/converter/tokenizer.py doctools/trunk/converter/util.py doctools/trunk/sphinx-build.py doctools/trunk/sphinx-web.py doctools/trunk/sphinx/__init__.py doctools/trunk/sphinx/_jinja.py doctools/trunk/sphinx/addnodes.py doctools/trunk/sphinx/builder.py doctools/trunk/sphinx/directives.py doctools/trunk/sphinx/environment.py doctools/trunk/sphinx/highlighting.py doctools/trunk/sphinx/htmlhelp.py doctools/trunk/sphinx/htmlwriter.py doctools/trunk/sphinx/latexwriter.py doctools/trunk/sphinx/patchlevel.py doctools/trunk/sphinx/refcounting.py doctools/trunk/sphinx/roles.py doctools/trunk/sphinx/search.py doctools/trunk/sphinx/util/__init__.py doctools/trunk/sphinx/util/console.py doctools/trunk/sphinx/util/json.py doctools/trunk/sphinx/web/__init__.py doctools/trunk/sphinx/web/admin.py doctools/trunk/sphinx/web/antispam.py doctools/trunk/sphinx/web/application.py doctools/trunk/sphinx/web/database.py doctools/trunk/sphinx/web/feed.py doctools/trunk/sphinx/web/mail.py doctools/trunk/sphinx/web/markup.py doctools/trunk/sphinx/web/oldurls.py doctools/trunk/sphinx/web/robots.py doctools/trunk/sphinx/web/serve.py doctools/trunk/sphinx/web/userdb.py doctools/trunk/sphinx/web/util.py doctools/trunk/sphinx/web/wsgiutil.py Log: Update copyright years and change license to BSD. Modified: doctools/trunk/convert.py ============================================================================== --- doctools/trunk/convert.py (original) +++ doctools/trunk/convert.py Fri Jan 11 15:18:19 2008 @@ -3,8 +3,8 @@ Convert the Python documentation to Sphinx ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - :copyright: 2007 by Georg Brandl. - :license: Python license. + :copyright: 2007-2008 by Georg Brandl. + :license: BSD. """ import sys Modified: doctools/trunk/converter/__init__.py ============================================================================== --- doctools/trunk/converter/__init__.py (original) +++ doctools/trunk/converter/__init__.py Fri Jan 11 15:18:19 2008 @@ -3,8 +3,8 @@ Documentation converter - high level functions ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - :copyright: 2007 by Georg Brandl. - :license: Python license. + :copyright: 2007-2008 by Georg Brandl. + :license: BSD. """ import sys Modified: doctools/trunk/converter/docnodes.py ============================================================================== --- doctools/trunk/converter/docnodes.py (original) +++ doctools/trunk/converter/docnodes.py Fri Jan 11 15:18:19 2008 @@ -3,8 +3,8 @@ Python documentation LaTeX parser - document nodes ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - :copyright: 2007 by Georg Brandl. - :license: Python license. + :copyright: 2007-2008 by Georg Brandl. + :license: BSD. """ Modified: doctools/trunk/converter/filenamemap.py ============================================================================== --- doctools/trunk/converter/filenamemap.py (original) +++ doctools/trunk/converter/filenamemap.py Fri Jan 11 15:18:19 2008 @@ -3,8 +3,8 @@ Map LaTeX filenames to ReST filenames ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - :copyright: 2007 by Georg Brandl. - :license: Python license. + :copyright: 2007-2008 by Georg Brandl. + :license: BSD. """ # '' means: use same name, strip prefix if applicable. Modified: doctools/trunk/converter/latexparser.py ============================================================================== --- doctools/trunk/converter/latexparser.py (original) +++ doctools/trunk/converter/latexparser.py Fri Jan 11 15:18:19 2008 @@ -5,8 +5,8 @@ For more documentation, look into the ``restwriter.py`` file. - :copyright: 2007 by Georg Brandl. - :license: Python license. + :copyright: 2007-2008 by Georg Brandl. + :license: BSD. """ from .docnodes import CommentNode, RootNode, NodeList, ParaSepNode, \ Modified: doctools/trunk/converter/restwriter.py ============================================================================== --- doctools/trunk/converter/restwriter.py (original) +++ doctools/trunk/converter/restwriter.py Fri Jan 11 15:18:19 2008 @@ -53,8 +53,8 @@ - Block level markup inside "alltt" environments doesn't work. - :copyright: 2007 by Georg Brandl. - :license: Python license. + :copyright: 2007-2008 by Georg Brandl. + :license: BSD. """ # yay! Modified: doctools/trunk/converter/tokenizer.py ============================================================================== --- doctools/trunk/converter/tokenizer.py (original) +++ doctools/trunk/converter/tokenizer.py Fri Jan 11 15:18:19 2008 @@ -5,8 +5,8 @@ For more documentation, look into the ``restwriter.py`` file. - :copyright: 2007 by Georg Brandl. - :license: Python license. + :copyright: 2007-2008 by Georg Brandl. + :license: BSD. """ import re Modified: doctools/trunk/converter/util.py ============================================================================== --- doctools/trunk/converter/util.py (original) +++ doctools/trunk/converter/util.py Fri Jan 11 15:18:19 2008 @@ -3,8 +3,8 @@ Python documentation conversion utils ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - :copyright: 2007 by Georg Brandl. - :license: Python license. + :copyright: 2007-2008 by Georg Brandl. + :license: BSD. """ import re Modified: doctools/trunk/sphinx-build.py ============================================================================== --- doctools/trunk/sphinx-build.py (original) +++ doctools/trunk/sphinx-build.py Fri Jan 11 15:18:19 2008 @@ -3,8 +3,8 @@ Sphinx - Python documentation toolchain ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - :copyright: 2007 by Georg Brandl. - :license: Python license. + :copyright: 2007-2008 by Georg Brandl. + :license: BSD. """ import sys Modified: doctools/trunk/sphinx-web.py ============================================================================== --- doctools/trunk/sphinx-web.py (original) +++ doctools/trunk/sphinx-web.py Fri Jan 11 15:18:19 2008 @@ -3,8 +3,8 @@ Sphinx - Python documentation webserver ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - :copyright: 2007 by Armin Ronacher, Georg Brandl. - :license: Python license. + :copyright: 2007-2008 by Armin Ronacher, Georg Brandl. + :license: BSD. """ import sys Modified: doctools/trunk/sphinx/__init__.py ============================================================================== --- doctools/trunk/sphinx/__init__.py (original) +++ doctools/trunk/sphinx/__init__.py Fri Jan 11 15:18:19 2008 @@ -5,8 +5,8 @@ The Python documentation toolchain. - :copyright: 2007 by Georg Brandl. - :license: Python license. + :copyright: 2007-2008 by Georg Brandl. + :license: BSD. """ import sys Modified: doctools/trunk/sphinx/_jinja.py ============================================================================== --- doctools/trunk/sphinx/_jinja.py (original) +++ doctools/trunk/sphinx/_jinja.py Fri Jan 11 15:18:19 2008 @@ -5,8 +5,8 @@ Jinja glue. - :copyright: 2007 by Georg Brandl. - :license: Python license. + :copyright: 2007-2008 by Georg Brandl. + :license: BSD. """ from __future__ import absolute_import Modified: doctools/trunk/sphinx/addnodes.py ============================================================================== --- doctools/trunk/sphinx/addnodes.py (original) +++ doctools/trunk/sphinx/addnodes.py Fri Jan 11 15:18:19 2008 @@ -3,8 +3,8 @@ sphinx.addnodes ~~~~~~~~~~~~~~~ - :copyright: 2007 by Georg Brandl. - :license: Python license. + :copyright: 2007-2008 by Georg Brandl. + :license: BSD. """ from docutils import nodes Modified: doctools/trunk/sphinx/builder.py ============================================================================== --- doctools/trunk/sphinx/builder.py (original) +++ doctools/trunk/sphinx/builder.py Fri Jan 11 15:18:19 2008 @@ -5,8 +5,8 @@ Builder classes for different output formats. - :copyright: 2007 by Georg Brandl. - :license: Python license. + :copyright: 2007-2008 by Georg Brandl. + :license: BSD. """ from __future__ import with_statement Modified: doctools/trunk/sphinx/directives.py ============================================================================== --- doctools/trunk/sphinx/directives.py (original) +++ doctools/trunk/sphinx/directives.py Fri Jan 11 15:18:19 2008 @@ -5,8 +5,8 @@ Handlers for additional ReST directives. - :copyright: 2007 by Georg Brandl. - :license: Python license. + :copyright: 2007-2008 by Georg Brandl. + :license: BSD. """ from __future__ import with_statement Modified: doctools/trunk/sphinx/environment.py ============================================================================== --- doctools/trunk/sphinx/environment.py (original) +++ doctools/trunk/sphinx/environment.py Fri Jan 11 15:18:19 2008 @@ -5,8 +5,8 @@ Global creation environment. - :copyright: 2007 by Georg Brandl. - :license: Python license. + :copyright: 2007-2008 by Georg Brandl. + :license: BSD. """ from __future__ import with_statement Modified: doctools/trunk/sphinx/highlighting.py ============================================================================== --- doctools/trunk/sphinx/highlighting.py (original) +++ doctools/trunk/sphinx/highlighting.py Fri Jan 11 15:18:19 2008 @@ -5,8 +5,8 @@ Highlight code blocks using Pygments. - :copyright: 2007 by Georg Brandl. - :license: Python license. + :copyright: 2007-2008 by Georg Brandl. + :license: BSD. """ import cgi Modified: doctools/trunk/sphinx/htmlhelp.py ============================================================================== --- doctools/trunk/sphinx/htmlhelp.py (original) +++ doctools/trunk/sphinx/htmlhelp.py Fri Jan 11 15:18:19 2008 @@ -6,8 +6,8 @@ Build HTML help support files. Adapted from the original Doc/tools/prechm.py. - :copyright: 2007 by Georg Brandl. - :license: Python license. + :copyright: 2007-2008 by Georg Brandl. + :license: BSD. """ from __future__ import with_statement Modified: doctools/trunk/sphinx/htmlwriter.py ============================================================================== --- doctools/trunk/sphinx/htmlwriter.py (original) +++ doctools/trunk/sphinx/htmlwriter.py Fri Jan 11 15:18:19 2008 @@ -5,8 +5,8 @@ docutils writers handling Sphinx' custom nodes. - :copyright: 2007 by Georg Brandl. - :license: Python license. + :copyright: 2007-2008 by Georg Brandl. + :license: BSD. """ from docutils import nodes Modified: doctools/trunk/sphinx/latexwriter.py ============================================================================== --- doctools/trunk/sphinx/latexwriter.py (original) +++ doctools/trunk/sphinx/latexwriter.py Fri Jan 11 15:18:19 2008 @@ -8,8 +8,8 @@ Much of this code is adapted from Dave Kuhlman's "docpy" writer from his docutils sandbox. - :copyright: 2007 by Georg Brandl, Dave Kuhlman. - :license: Python license. + :copyright: 2007-2008 by Georg Brandl, Dave Kuhlman. + :license: BSD. """ import re Modified: doctools/trunk/sphinx/patchlevel.py ============================================================================== --- doctools/trunk/sphinx/patchlevel.py (original) +++ doctools/trunk/sphinx/patchlevel.py Fri Jan 11 15:18:19 2008 @@ -6,8 +6,8 @@ Extract version info from Include/patchlevel.h. Adapted from Doc/tools/getversioninfo. - :copyright: 2007 by Georg Brandl. - :license: Python license. + :copyright: 2007-2008 by Georg Brandl. + :license: BSD. """ from __future__ import with_statement Modified: doctools/trunk/sphinx/refcounting.py ============================================================================== --- doctools/trunk/sphinx/refcounting.py (original) +++ doctools/trunk/sphinx/refcounting.py Fri Jan 11 15:18:19 2008 @@ -6,8 +6,8 @@ Handle reference counting annotations, based on refcount.py and anno-api.py. - :copyright: 2007 by Georg Brandl. - :license: Python license. + :copyright: 2007-2008 by Georg Brandl. + :license: BSD. """ from __future__ import with_statement Modified: doctools/trunk/sphinx/roles.py ============================================================================== --- doctools/trunk/sphinx/roles.py (original) +++ doctools/trunk/sphinx/roles.py Fri Jan 11 15:18:19 2008 @@ -5,8 +5,8 @@ Handlers for additional ReST roles. - :copyright: 2007 by Georg Brandl. - :license: Python license. + :copyright: 2007-2008 by Georg Brandl. + :license: BSD. """ import re Modified: doctools/trunk/sphinx/search.py ============================================================================== --- doctools/trunk/sphinx/search.py (original) +++ doctools/trunk/sphinx/search.py Fri Jan 11 15:18:19 2008 @@ -5,8 +5,8 @@ Create a search index for offline search. - :copyright: 2007 by Armin Ronacher. - :license: Python license. + :copyright: 2007-2008 by Armin Ronacher. + :license: BSD. """ import re import pickle Modified: doctools/trunk/sphinx/util/__init__.py ============================================================================== --- doctools/trunk/sphinx/util/__init__.py (original) +++ doctools/trunk/sphinx/util/__init__.py Fri Jan 11 15:18:19 2008 @@ -5,8 +5,8 @@ Utility functions for Sphinx. - :copyright: 2007 by Georg Brandl. - :license: Python license. + :copyright: 2007-2008 by Georg Brandl. + :license: BSD. """ import os Modified: doctools/trunk/sphinx/util/console.py ============================================================================== --- doctools/trunk/sphinx/util/console.py (original) +++ doctools/trunk/sphinx/util/console.py Fri Jan 11 15:18:19 2008 @@ -5,8 +5,8 @@ Format colored console output. - :copyright: 2007 by Georg Brandl. - :license: Python license. + :copyright: 2007-2008 by Georg Brandl. + :license: BSD. """ codes = {} Modified: doctools/trunk/sphinx/util/json.py ============================================================================== --- doctools/trunk/sphinx/util/json.py (original) +++ doctools/trunk/sphinx/util/json.py Fri Jan 11 15:18:19 2008 @@ -10,8 +10,8 @@ Uses the basestring encode function from simplejson. - :copyright: 2007 by Armin Ronacher, Bob Ippolito. - :license: Python license. + :copyright: 2007-2008 by Armin Ronacher, Bob Ippolito. + :license: BSD. """ import re Modified: doctools/trunk/sphinx/web/__init__.py ============================================================================== --- doctools/trunk/sphinx/web/__init__.py (original) +++ doctools/trunk/sphinx/web/__init__.py Fri Jan 11 15:18:19 2008 @@ -5,8 +5,8 @@ A web application to serve the Python docs interactively. - :copyright: 2007 by Georg Brandl. - :license: Python license. + :copyright: 2007-2008 by Georg Brandl. + :license: BSD. """ import os Modified: doctools/trunk/sphinx/web/admin.py ============================================================================== --- doctools/trunk/sphinx/web/admin.py (original) +++ doctools/trunk/sphinx/web/admin.py Fri Jan 11 15:18:19 2008 @@ -5,8 +5,8 @@ Admin application parts. - :copyright: 2007 by Georg Brandl, Armin Ronacher. - :license: Python license. + :copyright: 2007-2008 by Georg Brandl, Armin Ronacher. + :license: BSD. """ from .util import render_template Modified: doctools/trunk/sphinx/web/antispam.py ============================================================================== --- doctools/trunk/sphinx/web/antispam.py (original) +++ doctools/trunk/sphinx/web/antispam.py Fri Jan 11 15:18:19 2008 @@ -6,8 +6,8 @@ Small module that performs anti spam tests based on the bad content regex list provided by moin moin. - :copyright: 2007 by Armin Ronacher. - :license: Python license. + :copyright: 2007-2008 by Armin Ronacher. + :license: BSD. """ from __future__ import with_statement import re Modified: doctools/trunk/sphinx/web/application.py ============================================================================== --- doctools/trunk/sphinx/web/application.py (original) +++ doctools/trunk/sphinx/web/application.py Fri Jan 11 15:18:19 2008 @@ -6,8 +6,8 @@ A simple WSGI application that serves an interactive version of the python documentation. - :copyright: 2007 by Georg Brandl, Armin Ronacher. - :license: Python license. + :copyright: 2007-2008 by Georg Brandl, Armin Ronacher. + :license: BSD. """ from __future__ import with_statement Modified: doctools/trunk/sphinx/web/database.py ============================================================================== --- doctools/trunk/sphinx/web/database.py (original) +++ doctools/trunk/sphinx/web/database.py Fri Jan 11 15:18:19 2008 @@ -9,8 +9,8 @@ usable connection which is also set as the connection for the thread that called that function. - :copyright: 2007 by Georg Brandl, Armin Ronacher. - :license: Python license. + :copyright: 2007-2008 by Georg Brandl, Armin Ronacher. + :license: BSD. """ import time import sqlite3 Modified: doctools/trunk/sphinx/web/feed.py ============================================================================== --- doctools/trunk/sphinx/web/feed.py (original) +++ doctools/trunk/sphinx/web/feed.py Fri Jan 11 15:18:19 2008 @@ -5,8 +5,8 @@ Nifty module that generates RSS feeds. - :copyright: 2007 by Armin Ronacher. - :license: Python license. + :copyright: 2007-2008 by Armin Ronacher. + :license: BSD. """ import time from datetime import datetime Modified: doctools/trunk/sphinx/web/mail.py ============================================================================== --- doctools/trunk/sphinx/web/mail.py (original) +++ doctools/trunk/sphinx/web/mail.py Fri Jan 11 15:18:19 2008 @@ -6,8 +6,8 @@ A simple module for sending e-mails, based on simplemail.py. :copyright: 2004-2007 by Gerold Penz. - 2007 by Georg Brandl. - :license: Python license. + :copyright: 2007-2008 by Georg Brandl. + :license: BSD. """ import os.path Modified: doctools/trunk/sphinx/web/markup.py ============================================================================== --- doctools/trunk/sphinx/web/markup.py (original) +++ doctools/trunk/sphinx/web/markup.py Fri Jan 11 15:18:19 2008 @@ -35,8 +35,8 @@ cite someone Like

in HTML. - :copyright: 2007 by Armin Ronacher. - :license: Python license. + :copyright: 2007-2008 by Armin Ronacher. + :license: BSD. """ import cgi import re Modified: doctools/trunk/sphinx/web/oldurls.py ============================================================================== --- doctools/trunk/sphinx/web/oldurls.py (original) +++ doctools/trunk/sphinx/web/oldurls.py Fri Jan 11 15:18:19 2008 @@ -5,8 +5,8 @@ Handle old URLs gracefully. - :copyright: 2007 by Georg Brandl. - :license: Python license. + :copyright: 2007-2008 by Georg Brandl. + :license: BSD. """ import re Modified: doctools/trunk/sphinx/web/robots.py ============================================================================== --- doctools/trunk/sphinx/web/robots.py (original) +++ doctools/trunk/sphinx/web/robots.py Fri Jan 11 15:18:19 2008 @@ -5,8 +5,8 @@ robots.txt - :copyright: 2007 by Georg Brandl. - :license: Python license. + :copyright: 2007-2008 by Georg Brandl. + :license: BSD. """ robots_txt = """\ Modified: doctools/trunk/sphinx/web/serve.py ============================================================================== --- doctools/trunk/sphinx/web/serve.py (original) +++ doctools/trunk/sphinx/web/serve.py Fri Jan 11 15:18:19 2008 @@ -7,8 +7,8 @@ automatically. Works with any WSGI application but it won't help in non `wsgiref` environments. Use it only for development. - :copyright: 2007 by Armin Ronacher, Georg Brandl. - :license: Python license. + :copyright: 2007-2008 by Armin Ronacher, Georg Brandl. + :license: BSD. """ import os import sys Modified: doctools/trunk/sphinx/web/userdb.py ============================================================================== --- doctools/trunk/sphinx/web/userdb.py (original) +++ doctools/trunk/sphinx/web/userdb.py Fri Jan 11 15:18:19 2008 @@ -7,8 +7,8 @@ that stores users and their passwords so that they can gain access to the administration system. - :copyright: 2007 by Armin Ronacher. - :license: Python license. + :copyright: 2007-2008 by Armin Ronacher. + :license: BSD. """ from __future__ import with_statement from os import path Modified: doctools/trunk/sphinx/web/util.py ============================================================================== --- doctools/trunk/sphinx/web/util.py (original) +++ doctools/trunk/sphinx/web/util.py Fri Jan 11 15:18:19 2008 @@ -5,8 +5,8 @@ Miscellaneous utilities. - :copyright: 2007 by Georg Brandl. - :license: Python license. + :copyright: 2007-2008 by Georg Brandl. + :license: BSD. """ from __future__ import with_statement Modified: doctools/trunk/sphinx/web/wsgiutil.py ============================================================================== --- doctools/trunk/sphinx/web/wsgiutil.py (original) +++ doctools/trunk/sphinx/web/wsgiutil.py Fri Jan 11 15:18:19 2008 @@ -6,8 +6,8 @@ To avoid further dependencies this module collects some of the classes werkzeug provides and use in other views. - :copyright: 2007 by Armin Ronacher. - :license: Python license. + :copyright: 2007-2008 by Armin Ronacher. + :license: BSD. """ from __future__ import with_statement From python-checkins at python.org Fri Jan 11 15:19:54 2008 From: python-checkins at python.org (georg.brandl) Date: Fri, 11 Jan 2008 15:19:54 +0100 (CET) Subject: [Python-checkins] r59917 - doctools/trunk/AUTHORS doctools/trunk/LICENSE Message-ID: <20080111141954.4F8DB1E400A@bag.python.org> Author: georg.brandl Date: Fri Jan 11 15:19:54 2008 New Revision: 59917 Added: doctools/trunk/AUTHORS doctools/trunk/LICENSE Log: Add authors and license files. Added: doctools/trunk/AUTHORS ============================================================================== --- (empty file) +++ doctools/trunk/AUTHORS Fri Jan 11 15:19:54 2008 @@ -0,0 +1,6 @@ +The doctools are written and maintained by Georg Brandl . + +Other contributors are noted in the :copyright: fields within the docstrings +of the respective files. + +Many thanks for all contributions! Added: doctools/trunk/LICENSE ============================================================================== --- (empty file) +++ doctools/trunk/LICENSE Fri Jan 11 15:19:54 2008 @@ -0,0 +1,30 @@ +Copyright (c) 2007-2008 by the respective authors (see AUTHORS file). +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are +met: + + * Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + + * Redistributions in binary form must reproduce the above + copyright notice, this list of conditions and the following + disclaimer in the documentation and/or other materials provided + with the distribution. + + * The names of the contributors may not be used to endorse or + promote products derived from this software without specific + prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. From python-checkins at python.org Fri Jan 11 15:21:06 2008 From: python-checkins at python.org (georg.brandl) Date: Fri, 11 Jan 2008 15:21:06 +0100 (CET) Subject: [Python-checkins] r59918 - doctools/trunk/AUTHORS Message-ID: <20080111142106.E42981E4021@bag.python.org> Author: georg.brandl Date: Fri Jan 11 15:21:06 2008 New Revision: 59918 Modified: doctools/trunk/AUTHORS Log: Armin deserves special mention. Modified: doctools/trunk/AUTHORS ============================================================================== --- doctools/trunk/AUTHORS (original) +++ doctools/trunk/AUTHORS Fri Jan 11 15:21:06 2008 @@ -1,4 +1,6 @@ The doctools are written and maintained by Georg Brandl . +Substantial parts of the templates and the web application were written by +Armin Ronacher . Other contributors are noted in the :copyright: fields within the docstrings of the respective files. From martin at v.loewis.de Fri Jan 11 16:03:11 2008 From: martin at v.loewis.de (=?ISO-8859-1?Q?=22Martin_v=2E_L=F6wis=22?=) Date: Fri, 11 Jan 2008 16:03:11 +0100 Subject: [Python-checkins] r59913 - python/trunk/PCbuild/_sqlite3.vcproj In-Reply-To: <478779AA.7040003@ctypes.org> References: <478779AA.7040003@ctypes.org> Message-ID: <4787852F.9020401@v.loewis.de> > Yes, but I'm no longer sure whether sqlite3.dll should be compiled in > debug mode for a Python debug build at all. I don't think it should. > I tried to install the Microsoft.VC90.CRT non-debug runtime in several ways, but I > did not succeed. Do you (or anyone else) know how to make that library available > so that it will be found by sqlite3.dll when running the debug Python? Did you install the redistributable package? That should work. Otherwise, copy the assembly descriptor into the same directory as sqlite3.dll. Regards, Martin From amauryfa at gmail.com Fri Jan 11 16:22:34 2008 From: amauryfa at gmail.com (Amaury Forgeot d'Arc) Date: Fri, 11 Jan 2008 16:22:34 +0100 Subject: [Python-checkins] r59913 - python/trunk/PCbuild/_sqlite3.vcproj In-Reply-To: <478779AA.7040003@ctypes.org> References: <478779AA.7040003@ctypes.org> Message-ID: Thomas Heller wrote: > Yes, but I'm no longer sure whether sqlite3.dll should be compiled in > debug mode for a Python debug build at all. > I made this change only because the debug python cannot import the sqlite3 > module because the (non-debug) MSVCR90.DLL runtime library is not found. > > I tried to install the Microsoft.VC90.CRT non-debug runtime in several ways, but I > did not succeed. Do you (or anyone else) know how to make that library available > so that it will be found by sqlite3.dll when running the debug Python? > > The same problem occurs with tcl/tk. Even wish84.exe does not start... I had the same problem, but managed to tweak the compilation of external libraries to use debug mode. It was useful more than once to step into tcl/tk or sqlite3. Another possible solution is to add the /ALLOWISOLATION:NO linker option for python_d.exe, then copy msvcr90.dll in the application directory or somewhere in the PATH. Will try this tonight. -- Amaury Forgeot d'Arc From lists at cheimes.de Fri Jan 11 16:26:25 2008 From: lists at cheimes.de (Christian Heimes) Date: Fri, 11 Jan 2008 16:26:25 +0100 Subject: [Python-checkins] r59913 - python/trunk/PCbuild/_sqlite3.vcproj In-Reply-To: <4787852F.9020401@v.loewis.de> References: <478779AA.7040003@ctypes.org> <4787852F.9020401@v.loewis.de> Message-ID: <47878AA1.6040004@cheimes.de> Martin v. L?wis wrote: > Did you install the redistributable package? That should work. > > Otherwise, copy the assembly descriptor into the same directory as > sqlite3.dll. On Windows XP and newer you can't simply copy an assembly DLL next to the executable and assume that it picks up the DLL. It must either be installed as a global side-by-side assembly (SxS) or a private assembly. http://msdn2.microsoft.com/en-us/library/aa370850.aspx http://msdn2.microsoft.com/en-us/library/aa374224.aspx Christian From lists at cheimes.de Fri Jan 11 16:26:25 2008 From: lists at cheimes.de (Christian Heimes) Date: Fri, 11 Jan 2008 16:26:25 +0100 Subject: [Python-checkins] r59913 - python/trunk/PCbuild/_sqlite3.vcproj In-Reply-To: <4787852F.9020401@v.loewis.de> References: <478779AA.7040003@ctypes.org> <4787852F.9020401@v.loewis.de> Message-ID: <47878AA1.6040004@cheimes.de> Martin v. L?wis wrote: > Did you install the redistributable package? That should work. > > Otherwise, copy the assembly descriptor into the same directory as > sqlite3.dll. On Windows XP and newer you can't simply copy an assembly DLL next to the executable and assume that it picks up the DLL. It must either be installed as a global side-by-side assembly (SxS) or a private assembly. http://msdn2.microsoft.com/en-us/library/aa370850.aspx http://msdn2.microsoft.com/en-us/library/aa374224.aspx Christian From lists at cheimes.de Fri Jan 11 16:32:27 2008 From: lists at cheimes.de (Christian Heimes) Date: Fri, 11 Jan 2008 16:32:27 +0100 Subject: [Python-checkins] r59913 - python/trunk/PCbuild/_sqlite3.vcproj In-Reply-To: <478779AA.7040003@ctypes.org> References: <478779AA.7040003@ctypes.org> Message-ID: <47878C0B.70102@cheimes.de> Thomas Heller wrote: >> It seems that you modified the PGInstrument and PGUpdate >> configurations. Is it on purpose? IMO they should not be considered as >> debug builds. > > No, that was not intended. Could you please revert the changes for the PGI and PGU builds? > BTW: The win/amd64 version is in an even sadder state. > tcl/tk does not build with visual studio 2008 because it links > with the non-existing bufferoverflowU.lib (it does still build > with the SDK compiler), and bsddb does not build in debug mode at all - > it does not even create a libdb44*.lib static link library). I don't have a x64 CPU and I'm not able to test the 64bit builds for AMD64 on my machines. I'm aware that tcl doesn't compile on x64. I spent some time trying to fix it but it required too many chances and I didn't feel like fixing a lot of 3rd party code I didn't fully understand. IIRC Martin plans to switch to 8.5 soonish. However libdb44 worked for me, I'm sure even the X64|Debug build compiled. Christian From theller at ctypes.org Fri Jan 11 16:34:14 2008 From: theller at ctypes.org (Thomas Heller) Date: Fri, 11 Jan 2008 16:34:14 +0100 Subject: [Python-checkins] r59913 - python/trunk/PCbuild/_sqlite3.vcproj In-Reply-To: <4787852F.9020401@v.loewis.de> References: <478779AA.7040003@ctypes.org> <4787852F.9020401@v.loewis.de> Message-ID: <47878C76.6040906@ctypes.org> Martin v. L?wis schrieb: >> Yes, but I'm no longer sure whether sqlite3.dll should be compiled in >> debug mode for a Python debug build at all. > > I don't think it should. As I said, I will revert it. >> I tried to install the Microsoft.VC90.CRT non-debug runtime in several ways, but I >> did not succeed. Do you (or anyone else) know how to make that library available >> so that it will be found by sqlite3.dll when running the debug Python? > > Did you install the redistributable package? That should work. > > Otherwise, copy the assembly descriptor into the same directory as > sqlite3.dll. Does still not work. Also note that I try this on machines where Visual Studio 2008 *is* installed, so it should not be neccessary AT ALL. What works (win XP, SP2, x86): Building Python from source (complete, with tcl/tk, bsddb, and sqlite) in release mode. Testsuite passes, with some small failures. In debug mode, building all this also works, but when I try to import sqlite3 (or tkinter?) a messagebox is shown that MSVCR90.DLL is not found. The same happens when I try to start wish84.exe from the tcltk/bin directory that was built according to the instructions. Here is what I tried to solve this problem (but was not able to): - copy MSVCR90.DLL into the PCBuild directory. - copy *all* the files from VC\redist\x86\Microsoft.VC90.CRT into PCBuild - copy the VC\redist\x86\Microsoft.VC90.CRT *folder* into PCBuild - download the "Microsoft Visual C++ 2008 Redistributable Package (x86)" from http://www.microsoft.com.nsatc.net/downloads/details.aspx?familyid=9B2DA534-3E03-4391-8A4D-074B9F2BC1BF&displaylang=en and install it Strange. From theller at ctypes.org Fri Jan 11 16:35:26 2008 From: theller at ctypes.org (Thomas Heller) Date: Fri, 11 Jan 2008 16:35:26 +0100 Subject: [Python-checkins] r59913 - python/trunk/PCbuild/_sqlite3.vcproj In-Reply-To: <47878C0B.70102@cheimes.de> References: <478779AA.7040003@ctypes.org> <47878C0B.70102@cheimes.de> Message-ID: <47878CBE.7080703@ctypes.org> Christian Heimes schrieb: > Thomas Heller wrote: >>> It seems that you modified the PGInstrument and PGUpdate >>> configurations. Is it on purpose? IMO they should not be considered as >>> debug builds. >> >> No, that was not intended. > > Could you please revert the changes for the PGI and PGU builds? I'll revert the complete change. Thomas From python-checkins at python.org Fri Jan 11 16:38:50 2008 From: python-checkins at python.org (thomas.heller) Date: Fri, 11 Jan 2008 16:38:50 +0100 (CET) Subject: [Python-checkins] r59919 - python/trunk/PCbuild/_sqlite3.vcproj Message-ID: <20080111153850.26CCE1E400A@bag.python.org> Author: thomas.heller Date: Fri Jan 11 16:38:46 2008 New Revision: 59919 Modified: python/trunk/PCbuild/_sqlite3.vcproj Log: Revert revision 59913, because it was wrong: The sqlite3 dll, when compiled in debug mode, must be linked with /MDd to use the debug runtime library. Further, the dll will be named sqlite3_d.dll. Modified: python/trunk/PCbuild/_sqlite3.vcproj ============================================================================== --- python/trunk/PCbuild/_sqlite3.vcproj (original) +++ python/trunk/PCbuild/_sqlite3.vcproj Fri Jan 11 16:38:46 2008 @@ -54,11 +54,11 @@ Author: christian.heimes Date: Fri Jan 11 16:42:29 2008 New Revision: 59920 Modified: python/trunk/Modules/socketmodule.c Log: Removed unused variable Modified: python/trunk/Modules/socketmodule.c ============================================================================== --- python/trunk/Modules/socketmodule.c (original) +++ python/trunk/Modules/socketmodule.c Fri Jan 11 16:42:29 2008 @@ -4334,7 +4334,7 @@ PyMODINIT_FUNC init_socket(void) { - PyObject *m, *has_ipv6, *tmp; + PyObject *m, *has_ipv6; if (!os_init()) return; From theller at ctypes.org Fri Jan 11 16:43:19 2008 From: theller at ctypes.org (Thomas Heller) Date: Fri, 11 Jan 2008 16:43:19 +0100 Subject: [Python-checkins] r59913 - python/trunk/PCbuild/_sqlite3.vcproj In-Reply-To: <47878AA1.6040004@cheimes.de> References: <478779AA.7040003@ctypes.org> <4787852F.9020401@v.loewis.de> <47878AA1.6040004@cheimes.de> Message-ID: <47878E97.9040200@ctypes.org> Christian Heimes schrieb: > On Windows XP and newer you can't simply copy an assembly DLL next to > the executable and assume that it picks up the DLL. It must either be > installed as a global side-by-side assembly (SxS) or a private assembly. > I don't have time now to read the references that you gave, but do you have an answer to these questions: Doesn't the VC 2008 installation install the global SxS assemblies? These are the dlls that Python uses when it is run on the build machine IIUC. And how does it come that python_d.exe can load the debug dll, but the sqlite3.dll in the same process can NOT load the release dll? Thomas From amauryfa at gmail.com Fri Jan 11 17:56:31 2008 From: amauryfa at gmail.com (Amaury Forgeot d'Arc) Date: Fri, 11 Jan 2008 17:56:31 +0100 Subject: [Python-checkins] r59913 - python/trunk/PCbuild/_sqlite3.vcproj In-Reply-To: <47878E97.9040200@ctypes.org> References: <478779AA.7040003@ctypes.org> <4787852F.9020401@v.loewis.de> <47878AA1.6040004@cheimes.de> <47878E97.9040200@ctypes.org> Message-ID: Thomas Heller wrote: > Christian Heimes schrieb: > > On Windows XP and newer you can't simply copy an assembly DLL next to > > the executable and assume that it picks up the DLL. It must either be > > installed as a global side-by-side assembly (SxS) or a private assembly. > > > > I don't have time now to read the references that you gave, but do you > have an answer to these questions: > > Doesn't the VC 2008 installation install the global SxS assemblies? > These are the dlls that Python uses when it is run on the build machine IIUC. > > And how does it come that python_d.exe can load the debug dll, but the > sqlite3.dll in the same process can NOT load the release dll? Tentative explanation: "Manifests" are embedded in binaries, and are used to check dlls at load time. python_d.exe contains the manifest for the debug dll: see the "Embedding Manifest" step in the build log. But sqlite3.dll was compiled "by hand", and does not contain manifest. So there is no manifest at all for the release dll, and it will not load. -- Amaury Forgeot d'Arc From lists at cheimes.de Fri Jan 11 18:01:36 2008 From: lists at cheimes.de (Christian Heimes) Date: Fri, 11 Jan 2008 18:01:36 +0100 Subject: [Python-checkins] r59913 - python/trunk/PCbuild/_sqlite3.vcproj In-Reply-To: References: <478779AA.7040003@ctypes.org> <4787852F.9020401@v.loewis.de> <47878AA1.6040004@cheimes.de> <47878E97.9040200@ctypes.org> Message-ID: <4787A0F0.8030301@cheimes.de> Amaury Forgeot d'Arc wrote: > But sqlite3.dll was compiled "by hand", and does not contain manifest. > So there is no manifest at all for the release dll, and it will not > load. It doesn't have an embedded manifest? Uh, it should probably have one. Christian From buildbot at python.org Fri Jan 11 18:08:35 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 11 Jan 2008 17:08:35 +0000 Subject: [Python-checkins] buildbot failure in x86 FreeBSD 3.0 Message-ID: <20080111170835.58E991E400B@bag.python.org> The Buildbot has detected a new failure of x86 FreeBSD 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20FreeBSD%203.0/builds/382 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-freebsd Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes,georg.brandl BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_asynchat ====================================================================== FAIL: test_close_when_done (test.test_asynchat.TestAsynchat) ---------------------------------------------------------------------- Traceback (most recent call last): File "/usr/home/db3l/buildarea/3.0.bolen-freebsd/build/Lib/test/test_asynchat.py", line 211, in test_close_when_done self.assertTrue(len(s.buffer) > 0) AssertionError: None ====================================================================== FAIL: test_close_when_done (test.test_asynchat.TestAsynchat_WithPoll) ---------------------------------------------------------------------- Traceback (most recent call last): File "/usr/home/db3l/buildarea/3.0.bolen-freebsd/build/Lib/test/test_asynchat.py", line 211, in test_close_when_done self.assertTrue(len(s.buffer) > 0) AssertionError: None sincerely, -The Buildbot From theller at ctypes.org Fri Jan 11 18:13:45 2008 From: theller at ctypes.org (Thomas Heller) Date: Fri, 11 Jan 2008 18:13:45 +0100 Subject: [Python-checkins] r59913 - python/trunk/PCbuild/_sqlite3.vcproj In-Reply-To: <4787A0F0.8030301@cheimes.de> References: <478779AA.7040003@ctypes.org> <4787852F.9020401@v.loewis.de> <47878AA1.6040004@cheimes.de> <47878E97.9040200@ctypes.org> <4787A0F0.8030301@cheimes.de> Message-ID: <4787A3C9.3010402@ctypes.org> Christian Heimes schrieb: > Amaury Forgeot d'Arc wrote: >> But sqlite3.dll was compiled "by hand", and does not contain manifest. >> So there is no manifest at all for the release dll, and it will not >> load. > > It doesn't have an embedded manifest? Uh, it should probably have one. Somehow I get the impression that it would be easier to compile the sqlite sources into the _sqlite3(_d).pyd file, that would avoid the whole hassle. And it is also what is recommended on the sqlite mailing list. However, this doesn't solve the problem for tcltk. How can tcltk load the runtime lib when compiled with VS 2008? Or do we have to wait for a new version? Thomas From python-checkins at python.org Fri Jan 11 19:04:56 2008 From: python-checkins at python.org (raymond.hettinger) Date: Fri, 11 Jan 2008 19:04:56 +0100 (CET) Subject: [Python-checkins] r59923 - python/trunk/Lib/urlparse.py Message-ID: <20080111180456.0EE7E1E4022@bag.python.org> Author: raymond.hettinger Date: Fri Jan 11 19:04:55 2008 New Revision: 59923 Modified: python/trunk/Lib/urlparse.py Log: Speed-up and simplify code urlparse's result objects. Modified: python/trunk/Lib/urlparse.py ============================================================================== --- python/trunk/Lib/urlparse.py (original) +++ python/trunk/Lib/urlparse.py Fri Jan 11 19:04:55 2008 @@ -37,46 +37,11 @@ def clear_cache(): """Clear the parse cache.""" - global _parse_cache - _parse_cache = {} + _parse_cache.clear() -class BaseResult(tuple): - """Base class for the parsed result objects. - - This provides the attributes shared by the two derived result - objects as read-only properties. The derived classes are - responsible for checking the right number of arguments were - supplied to the constructor. - - """ - - __slots__ = () - - # Attributes that access the basic components of the URL: - - @property - def scheme(self): - return self[0] - - @property - def netloc(self): - return self[1] - - @property - def path(self): - return self[2] - - @property - def query(self): - return self[-2] - - @property - def fragment(self): - return self[-1] - - # Additional attributes that provide access to parsed-out portions - # of the netloc: +class ResultMixin(object): + """Shared methods for the parsed result objects.""" @property def username(self): @@ -116,31 +81,20 @@ return int(port, 10) return None +from collections import namedtuple -class SplitResult(BaseResult): +class SplitResult(namedtuple('SplitResult', 'scheme netloc path query fragment'), ResultMixin): __slots__ = () - def __new__(cls, scheme, netloc, path, query, fragment): - return BaseResult.__new__( - cls, (scheme, netloc, path, query, fragment)) - def geturl(self): return urlunsplit(self) -class ParseResult(BaseResult): +class ParseResult(namedtuple('ParseResult', 'scheme netloc path params query fragment'), ResultMixin): __slots__ = () - def __new__(cls, scheme, netloc, path, params, query, fragment): - return BaseResult.__new__( - cls, (scheme, netloc, path, params, query, fragment)) - - @property - def params(self): - return self[3] - def geturl(self): return urlunparse(self) From buildbot at python.org Fri Jan 11 20:29:01 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 11 Jan 2008 19:29:01 +0000 Subject: [Python-checkins] buildbot failure in hppa Ubuntu trunk Message-ID: <20080111192901.C19051E400B@bag.python.org> The Buildbot has detected a new failure of hppa Ubuntu trunk. Full details are available at: http://www.python.org/dev/buildbot/all/hppa%20Ubuntu%20trunk/builds/503 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-ubuntu-hppa Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_bsddb3 ====================================================================== ERROR: test00_associateDBError (bsddb.test.test_associate.AssociateErrorTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 104, in setUp self.env.open(homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.AssociateBTreeTxnTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.AssociateBTreeTxnTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test13_associate_in_transaction (bsddb.test.test_associate.AssociateBTreeTxnTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ShelveAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ShelveAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ShelveAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ThreadedAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ThreadedAssociateHashTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ThreadedAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ThreadedAssociateBTreeTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_associateWithDB (bsddb.test.test_associate.ThreadedAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_associateAfterDB (bsddb.test.test_associate.ThreadedAssociateRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_associate.py", line 165, in setUp db.DB_INIT_LOCK | db.DB_THREAD | self.envFlags) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_EnvRemoveAndRename (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_EnvRemoveAndRename (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Transactions (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_TxnTruncate (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test08_TxnLateUse (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Transactions (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test07_TxnTruncate (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test08_TxnLateUse (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test09_MultiDB (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test09_MultiDB (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_basics.py", line 71, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_both (bsddb.test.test_dbobj.dbobjTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbobj.py", line 45, in test01_both self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbobj.py", line 39, in open return apply(self._cobj.open, args, kwargs) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_dbobj_dict_interface (bsddb.test.test_dbobj.dbobjTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbobj.py", line 58, in test02_dbobj_dict_interface self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbobj.py", line 39, in open return apply(self._cobj.open, args, kwargs) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01 (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02 (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03 (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test04_MultiCondSelect (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_CondObjs (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_CreateOrExtend (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_Delete (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_Modify (bsddb.test.test_dbtables.TableDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_dbtables.py", line 57, in setUp filename='tabletest.db', dbhome=homeDir, create=1) File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/dbtables.py", line 161, in __init__ self.env.open(dbhome, myflags | flagsforenv) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_close_dbenv_before_db (bsddb.test.test_env_close.DBEnvClosedEarlyCrash) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_env_close.py", line 53, in test01_close_dbenv_before_db 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_close_dbenv_delete_db_success (bsddb.test.test_env_close.DBEnvClosedEarlyCrash) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_env_close.py", line 78, in test02_close_dbenv_delete_db_success 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_join (bsddb.test.test_join.JoinTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_join.py", line 57, in setUp self.env.open(homeDir, db.DB_CREATE | db.DB_INIT_MPOOL | db.DB_INIT_LOCK ) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_simple (bsddb.test.test_lock.LockingTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_lock.py", line 38, in setUp db.DB_INIT_LOCK | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_threaded (bsddb.test.test_lock.LockingTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_lock.py", line 38, in setUp db.DB_INIT_LOCK | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_set_timeout (bsddb.test.test_lock.LockingTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_lock.py", line 38, in setUp db.DB_INIT_LOCK | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_db_home (bsddb.test.test_misc.MiscTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_misc.py", line 45, in test02_db_home env.open(self.homeDir, db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_1WriterMultiReaders (bsddb.test.test_thread.BTreeConcurrentDataStore) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test01_1WriterMultiReaders (bsddb.test.test_thread.HashConcurrentDataStore) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_SimpleLocks (bsddb.test.test_thread.BTreeSimpleThreaded) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test02_SimpleLocks (bsddb.test.test_thread.HashSimpleThreaded) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.BTreeThreadedTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.HashThreadedTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.BTreeThreadedNoWaitTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.HashThreadedNoWaitTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_cachesize (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_flags (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_get (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_get_dbp (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_get_key (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_range (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_remove (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_stat (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 29, in setUp self.dbenv.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL, 0666) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') ====================================================================== ERROR: test_pget (bsddb.test.test_cursor_pget_bug.pget_bugTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-ubuntu-hppa/build/Lib/bsddb/test/test_cursor_pget_bug.py", line 25, in setUp self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) DBInvalidArgError: (22, 'Invalid argument -- Berkeley DB library configured to support only private environments') make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Fri Jan 11 20:33:25 2008 From: python-checkins at python.org (andrew.kuchling) Date: Fri, 11 Jan 2008 20:33:25 +0100 (CET) Subject: [Python-checkins] r59924 - python/trunk/Doc/library/xmlrpclib.rst Message-ID: <20080111193325.0D4121E4012@bag.python.org> Author: andrew.kuchling Date: Fri Jan 11 20:33:24 2008 New Revision: 59924 Modified: python/trunk/Doc/library/xmlrpclib.rst Log: Bug #1790: update link; remove outdated paragraph Modified: python/trunk/Doc/library/xmlrpclib.rst ============================================================================== --- python/trunk/Doc/library/xmlrpclib.rst (original) +++ python/trunk/Doc/library/xmlrpclib.rst Fri Jan 11 20:33:24 2008 @@ -120,12 +120,11 @@ .. seealso:: `XML-RPC HOWTO `_ - A good description of XML operation and client software in several languages. + A good description of XML-RPC operation and client software in several languages. Contains pretty much everything an XML-RPC client developer needs to know. - `XML-RPC Hacks page `_ - Extensions for various open-source libraries to support introspection and - multicall. + `XML-RPC Introspection `_ + Describes the XML-RPC protocol extension for introspection. .. _serverproxy-objects: @@ -177,11 +176,6 @@ no such string is available, an empty string is returned. The documentation string may contain HTML markup. -Introspection methods are currently supported by servers written in PHP, C and -Microsoft .NET. Partial introspection support is included in recent updates to -UserLand Frontier. Introspection support for Perl, Python and Java is available -at the `XML-RPC Hacks `_ page. - .. _boolean-objects: From python-checkins at python.org Fri Jan 11 20:34:06 2008 From: python-checkins at python.org (thomas.heller) Date: Fri, 11 Jan 2008 20:34:06 +0100 (CET) Subject: [Python-checkins] r59925 - in python/trunk: Lib/ctypes/test/test_funcptr.py Modules/_ctypes/_ctypes.c Message-ID: <20080111193406.D87C11E400B@bag.python.org> Author: thomas.heller Date: Fri Jan 11 20:34:06 2008 New Revision: 59925 Modified: python/trunk/Lib/ctypes/test/test_funcptr.py python/trunk/Modules/_ctypes/_ctypes.c Log: Raise an error instead of crashing with a segfault when a NULL function pointer is called. Will backport to release25-maint. Modified: python/trunk/Lib/ctypes/test/test_funcptr.py ============================================================================== --- python/trunk/Lib/ctypes/test/test_funcptr.py (original) +++ python/trunk/Lib/ctypes/test/test_funcptr.py Fri Jan 11 20:34:06 2008 @@ -123,5 +123,11 @@ self.failUnlessEqual(strtok(None, "\n"), "c") self.failUnlessEqual(strtok(None, "\n"), None) + def test_NULL_funcptr(self): + tp = CFUNCTYPE(c_int) + func = tp() # NULL function pointer + # raise a ValueError when we try to call it + self.assertRaises(ValueError, func) + if __name__ == '__main__': unittest.main() Modified: python/trunk/Modules/_ctypes/_ctypes.c ============================================================================== --- python/trunk/Modules/_ctypes/_ctypes.c (original) +++ python/trunk/Modules/_ctypes/_ctypes.c Fri Jan 11 20:34:06 2008 @@ -3312,6 +3312,11 @@ pProc = *(void **)self->b_ptr; + if (pProc == NULL) { + PyErr_SetString(PyExc_ValueError, + "attempt to call NULL function pointer"); + return NULL; + } #ifdef MS_WIN32 if (self->index) { /* It's a COM method */ From python-checkins at python.org Fri Jan 11 20:48:46 2008 From: python-checkins at python.org (thomas.heller) Date: Fri, 11 Jan 2008 20:48:46 +0100 (CET) Subject: [Python-checkins] r59926 - in python/branches/release25-maint: Lib/ctypes Lib/ctypes/test/test_funcptr.py Misc/NEWS Modules/_ctypes Modules/_ctypes/_ctypes.c Message-ID: <20080111194846.9E3F91E400B@bag.python.org> Author: thomas.heller Date: Fri Jan 11 20:48:46 2008 New Revision: 59926 Modified: python/branches/release25-maint/Lib/ctypes/ (props changed) python/branches/release25-maint/Lib/ctypes/test/test_funcptr.py python/branches/release25-maint/Misc/NEWS python/branches/release25-maint/Modules/_ctypes/ (props changed) python/branches/release25-maint/Modules/_ctypes/_ctypes.c Log: Added NEWS entry, plus: Merged revisions 59925 via svnmerge from svn+ssh://pythondev at svn.python.org/python/trunk/Modules/_ctypes ........ r59925 | thomas.heller | 2008-01-11 20:34:06 +0100 (Fr, 11 Jan 2008) | 5 lines Raise an error instead of crashing with a segfault when a NULL function pointer is called. Will backport to release25-maint. ........ Modified: python/branches/release25-maint/Lib/ctypes/test/test_funcptr.py ============================================================================== --- python/branches/release25-maint/Lib/ctypes/test/test_funcptr.py (original) +++ python/branches/release25-maint/Lib/ctypes/test/test_funcptr.py Fri Jan 11 20:48:46 2008 @@ -123,5 +123,11 @@ self.failUnlessEqual(strtok(None, "\n"), "c") self.failUnlessEqual(strtok(None, "\n"), None) + def test_NULL_funcptr(self): + tp = CFUNCTYPE(c_int) + func = tp() # NULL function pointer + # raise a ValueError when we try to call it + self.assertRaises(ValueError, func) + if __name__ == '__main__': unittest.main() Modified: python/branches/release25-maint/Misc/NEWS ============================================================================== --- python/branches/release25-maint/Misc/NEWS (original) +++ python/branches/release25-maint/Misc/NEWS Fri Jan 11 20:48:46 2008 @@ -12,6 +12,8 @@ Core and builtins ----------------- +- Prevent a segfault when a ctypes NULL function pointer is called. + - Bug #1517: Possible segfault in lookup(). - Issue #1638: %zd configure test fails on Linux. Modified: python/branches/release25-maint/Modules/_ctypes/_ctypes.c ============================================================================== --- python/branches/release25-maint/Modules/_ctypes/_ctypes.c (original) +++ python/branches/release25-maint/Modules/_ctypes/_ctypes.c Fri Jan 11 20:48:46 2008 @@ -3305,6 +3305,11 @@ pProc = *(void **)self->b_ptr; + if (pProc == NULL) { + PyErr_SetString(PyExc_ValueError, + "attempt to call NULL function pointer"); + return NULL; + } #ifdef MS_WIN32 if (self->index) { /* It's a COM method */ From buildbot at python.org Fri Jan 11 21:13:50 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 11 Jan 2008 20:13:50 +0000 Subject: [Python-checkins] buildbot failure in x86 XP-3 2.5 Message-ID: <20080111201350.975381E400B@bag.python.org> The Buildbot has detected a new failure of x86 XP-3 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20XP-3%202.5/builds/139 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: heller-windows Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: andrew.kuchling,facundo.batista,mark.dickinson,thomas.heller BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_winreg sincerely, -The Buildbot From gki at pldtdsl.net Sun Jan 13 13:02:02 2008 From: gki at pldtdsl.net (Global Knowledge PH) Date: Sun, 13 Jan 2008 04:02:02 -0800 Subject: [Python-checkins] Securing Windows Vista Training on Jan 24-26 and Crystal Report 10 Advanced Jan 24-25, 2008 Message-ID: <1270801c855dc$1bcac9e0$2701a8c0@exam3> Securing Windows Vista Jan 24-26, 2008 (Thurs-Sat) P15,000.00+VAT/Person About the course This intended to teach something to users and administrators alike at every level, but is optimized for those with a little bit of experience in administering Windows. While a beginning administrator can easily implement any of the discussed techniques, it helps to have a firm foundation of Windows basic fundamentals, especially as they apply in Windows 2000 or later, before reading any book of this nature. After the end of the course you come to be among the most informed Windows user and/or administrator in the business. After finishing, participants should understand the strengths and weaknesses of Windows Vista, and of computer security in general. Along with all the new material presented, we hope that you walk away with answers to many questions that you've had for years about existing technologies and techniques. Thus, this lecture gives a healthy dose of security skepticism, both directed toward all the glowing Windows Vista marketing literature and toward its critics. We firmly believe that Windows Vista is among the most readily secured operating systems for PCs and is highly appropriate for most networks and users. Tools All the programs and tools discussed or recommended in this book are installed with Windows Vista or are readily available for downloading (most for free) on the Internet Training Duration Minimum of three (3) days which includes lectures and hands on to facilitate concepts/theories presented. A one (1) day lecture will suffice all topics. Course Organization Part I is an overview of the new security features of Windows Vista, how malicious hackers hack, and how Windows functions in general. Part II focuses on general host-based security controls, such as User Account Control, Windows Defender, and application security. Because most of today's computer attacks use client-side, host-based vectors, this is an especially important section. Part III focuses on securing Internet Explorer and e-mail from the client perspective and IIS from the server perspective. Browser and e-mail programs are involved in most of today's malicious exploits. Part III introduces Internet Explorer 7, Windows Mail, and IIS 7 Part IV discusses the improved Windows Firewall, IPsec, and wireless security. Part IV also includes a section about one of the most promising network security techniques available today-Server and Domain Isolation. Part V focuses on automating security using group policy and finishes in Module 15 with point-counterpoint discussions between the two authors. The last Module summarizes the authors' strongest held defense beliefs and recommendations. Course Prize: P15,000.00+VAT Part I - Introducing Windows Vista Module 1 New Security Features Module 2 How Hackers Attack Module 3 Windows Infrastructure Part II - Host-Based Security Module 4 User Account Control Module 5 Managing Access Control Module 6 Application Security Module 7 Vista Client Protection Part III - Securing Internet and E-mail Access Module 8 Securing Internet Explorer Module 9 Introducing IIS 7 Module 10 Protecting E-mail Part IV - Securing Windows Networks Module 11 Managing Windows Firewall Module 12 Server and Domain Isolation Module 13 Wireless Security Part V - Group Policy and Best Practices Module 14 Using Group Policy Module 15 Thinking about Security Crystal Reports Design 10.0 Advanced Jan 24-25, 2008 (Thurs-Fri) 2 days | 9am-5pm P15,000.00+VAT/Person Overview This workshop is designed for to enhance your basic report writing skills and move you into creating more complex reports. Time will be spent walking you through the tips and tricks of advanced report writing along with a good amount of hands on practice. In addition, you will cover the Crystal Report 10 Architecture, Custom Functions, Professional Design, Report Efficiency and Advanced Formulas. This course incorporates a number of hands on exercises that reinforce the learning process. Prerequisites User must have taken the Introductory Report Design 10.0 course and/or understand basic report design concepts such as linking, record selection, sorting, grouping, summarizing, basic formulas, conditional reporting and section formatting. Proficient knowledge of Windows environment and a thorough understanding of relational database concepts are required. COURSE OUTLINE Refresher Exercise Review of Planning a Report Creating the Report Helpful Hints for Formatting the Report Power Formatting with Multiple Sections Using Multiple Sections in Reports Using the Section Expert to Work with Sections Conditionally Formatting Multiple Sections Advanced Drill Down Group Level Using the Running Totals Feature Understanding Running Totals Creating Running Totals for a List of Numbers Conditional Running Totals Prompting with Parameters Parameter Fields Overview Parameter Field Considerations Creating a Parameter Field Using a Parameter to Select Records Using a Parameter Field Creating a Pick List for Parameter Values Adding Parameter Values to Text Objects Allowing Multiple Values in Parameters Using Multiple Parameter Fields in Reports Specifying and Limiting a Range for a Parameter Using Parameters in Conditional Formatting Using an Edit Mask to Limit String Parameters Sorting with a Parameter Displaying Parameter Fields Using Advanced Formula Features Understanding How Crystal Reports Processes the Data Working with Variables Separating Statements in Complex Formulas Working with Arrays Understanding the Formula Evaluation Time Debugger Using Subreporting as a Workaround Solution Understanding Subreports Unlinked versus Linked Subreports Creating an Unlinked Subreport Linking a Subreport Database Links versus Subreports in One-to-Many Situations Formatting the Subreport Passing Data from the Main Report into a Subreport Creating On-Demand Subreports Creating Hyperlinks Using Subreports to Link "Unlinkable" Data Creating Powerful Groups Customizing the Group Name Field Creating Custom Groups Grouping on a Formula Field Using Group Selection to Filter the Records in the Report Grouping Hierarchically Working with Cross-Tab Reports Understanding How Cross-Tabs Affect Your Data Creating a Cross-Tab Report Creating a Cross-Tab with Multiple Rows or Column Applying a Formatting Style to the Cross-Tab Customizing the Cross-Tab Format Charting Cross-Tabs Customizing Cross-Tab Group Names CurrentFieldValue Report Alerts What are Report Alerts Creating Report Alerts Basing Report Formulas or Conditional Formatting on Report Alerts Creative Usage for Report Alerts Report Templates What is a Report Template Standard Report Creation Wizard and Templates The Template Expert Applying a Template and the Consequences Template Considerations Creating your Own Templates Custom Functions What is a Custom Function Custom Function Arguments When to Use a Custom Function Creating Custom Functions Creating a Custom Function Using the Custom Function Editor Custom Functions Properties Using the Formula Expert and Custom Functions Using the Formula Extractor Custom Function Limitations Advanced Formula Syntax Review of if...then...else Expressions Select Case Statement Immediate If Function IIF(expression, truePart,falsePart) For Loop Exit For While Do Loops Join Functions The Split Function Crystal Reports, Data Access and SQL What is SQL Direct Database Driver ODBC OLE DB Viewing the SQL SQL Commands Creating a SQL Command Adding a Parameter to the Command SQL Expressions Creating a SQL Expression Advanced Database Concepts Using the Database Expert For Linking Adding and Removing Databases from the Report Adding Tables to a Report Multiple Times Changing the Join Type for a Link Database Changes Database Verification Set DataSource Location Re-mapping Database Fields ENROLL NOW! GLOBAL KNOWLEDGE ASSOCIATES INC. 25TH Flr. Unit 2502b West Tower, Philippine Stock Exchange, Ortigas Center Pasig City Tel. No. (632) 683-0969 / 637-3657 Email: sandra at globalknowledgeph.com URL: www.globalknowledge.com.ph _____ If you want to unsubscribe from this mailing list. Please Click it -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.python.org/pipermail/python-checkins/attachments/20080113/0c46f0c8/attachment-0001.htm From buildbot at python.org Fri Jan 11 21:25:07 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 11 Jan 2008 20:25:07 +0000 Subject: [Python-checkins] buildbot failure in x86 XP-4 2.5 Message-ID: <20080111202507.7FFBF1E4032@bag.python.org> The Buildbot has detected a new failure of x86 XP-4 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20XP-4%202.5/builds/88 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-windows Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: andrew.kuchling,facundo.batista,mark.dickinson,thomas.heller BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_winreg sincerely, -The Buildbot From python-checkins at python.org Fri Jan 11 21:29:20 2008 From: python-checkins at python.org (thomas.heller) Date: Fri, 11 Jan 2008 21:29:20 +0100 (CET) Subject: [Python-checkins] r59927 - python/trunk/Modules/_ctypes/_ctypes.c Message-ID: <20080111202920.1B4A71E4020@bag.python.org> Author: thomas.heller Date: Fri Jan 11 21:29:19 2008 New Revision: 59927 Modified: python/trunk/Modules/_ctypes/_ctypes.c Log: Fix a potential 'SystemError: NULL result without error'. NULL may be a valid return value from PyLong_AsVoidPtr. Will backport to release25-maint. Modified: python/trunk/Modules/_ctypes/_ctypes.c ============================================================================== --- python/trunk/Modules/_ctypes/_ctypes.c (original) +++ python/trunk/Modules/_ctypes/_ctypes.c Fri Jan 11 21:29:19 2008 @@ -2899,7 +2899,7 @@ || PyLong_Check(PyTuple_GET_ITEM(args, 0)))) { CDataObject *ob; void *ptr = PyLong_AsVoidPtr(PyTuple_GET_ITEM(args, 0)); - if (ptr == NULL) + if (ptr == NULL && PyErr_Occurred()) return NULL; ob = (CDataObject *)GenericCData_new(type, args, kwds); if (ob == NULL) From buildbot at python.org Fri Jan 11 21:55:29 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 11 Jan 2008 20:55:29 +0000 Subject: [Python-checkins] buildbot failure in alpha Tru64 5.1 2.5 Message-ID: <20080111205529.6D8521E4023@bag.python.org> The Buildbot has detected a new failure of alpha Tru64 5.1 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/alpha%20Tru64%205.1%202.5/builds/394 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-tru64 Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: andrew.kuchling,facundo.batista,mark.dickinson,thomas.heller BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_socket ====================================================================== FAIL: testInterruptedTimeout (test.test_socket.TCPTimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/net/taipan/scratch1/nnorwitz/python/2.5.norwitz-tru64/build/Lib/test/test_socket.py", line 879, in testInterruptedTimeout self.fail("got Alarm in wrong place") AssertionError: got Alarm in wrong place sincerely, -The Buildbot From buildbot at python.org Fri Jan 11 22:02:51 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 11 Jan 2008 21:02:51 +0000 Subject: [Python-checkins] buildbot failure in x86 gentoo trunk Message-ID: <20080111210251.7F1641E400C@bag.python.org> The Buildbot has detected a new failure of x86 gentoo trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20gentoo%20trunk/builds/2874 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-x86 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: thomas.heller BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_xmlrpc make: *** [buildbottest] Error 1 sincerely, -The Buildbot From amauryfa at gmail.com Fri Jan 11 22:08:38 2008 From: amauryfa at gmail.com (Amaury Forgeot d'Arc) Date: Fri, 11 Jan 2008 22:08:38 +0100 Subject: [Python-checkins] r59913 - python/trunk/PCbuild/_sqlite3.vcproj In-Reply-To: <4787852F.9020401@v.loewis.de> References: <478779AA.7040003@ctypes.org> <4787852F.9020401@v.loewis.de> Message-ID: Martin v. L?wis wrote: > > Yes, but I'm no longer sure whether sqlite3.dll should be compiled in > > debug mode for a Python debug build at all. > > I don't think it should. Why so? full debug mode is sometimes useful, especially for modules that may call back into the Python interpreter. -- Amaury Forgeot d'Arc From buildbot at python.org Fri Jan 11 22:28:10 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 11 Jan 2008 21:28:10 +0000 Subject: [Python-checkins] buildbot failure in ppc Debian unstable trunk Message-ID: <20080111212810.DF3431E400C@bag.python.org> The Buildbot has detected a new failure of ppc Debian unstable trunk. Full details are available at: http://www.python.org/dev/buildbot/all/ppc%20Debian%20unstable%20trunk/builds/578 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: thomas.heller BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/SocketServer.py", line 523, in __init__ self.handle() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/BaseHTTPServer.py", line 310, in handle_one_request method() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/SimpleXMLRPCServer.py", line 449, in do_POST self.report_404() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/SimpleXMLRPCServer.py", line 507, in report_404 self.connection.shutdown(1) File "", line 1, in shutdown error: [Errno 107] Transport endpoint is not connected 1 test failed: test_xmlrpc ====================================================================== ERROR: test_fail_no_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_xmlrpc.py", line 560, in test_fail_no_info p.pow(6,8) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1157, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1447, in __request verbose=self.__verbose File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1195, in request errcode, errmsg, headers = h.getreply() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 1006, in getreply response = self._conn.getresponse() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 932, in getresponse response.begin() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 415, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 271, in readheaders line = self.fp.readline() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/socket.py", line 354, in readline data = recv(1) error: [Errno 104] Connection reset by peer ====================================================================== ERROR: test_fail_with_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_xmlrpc.py", line 580, in test_fail_with_info p.pow(6,8) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1157, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1447, in __request verbose=self.__verbose File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1195, in request errcode, errmsg, headers = h.getreply() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 1006, in getreply response = self._conn.getresponse() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 932, in getresponse response.begin() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 415, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 271, in readheaders line = self.fp.readline() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/socket.py", line 354, in readline data = recv(1) error: [Errno 104] Connection reset by peer make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Fri Jan 11 22:47:16 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 11 Jan 2008 21:47:16 +0000 Subject: [Python-checkins] buildbot failure in sparc solaris10 gcc trunk Message-ID: <20080111214716.3F8D21E400C@bag.python.org> The Buildbot has detected a new failure of sparc solaris10 gcc trunk. Full details are available at: http://www.python.org/dev/buildbot/all/sparc%20solaris10%20gcc%20trunk/builds/2597 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-sun Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: thomas.heller BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/SocketServer.py", line 523, in __init__ self.handle() File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 11] Resource temporarily unavailable 1 test failed: test_xmlrpc sincerely, -The Buildbot From python-checkins at python.org Sat Jan 12 00:25:18 2008 From: python-checkins at python.org (raymond.hettinger) Date: Sat, 12 Jan 2008 00:25:18 +0100 (CET) Subject: [Python-checkins] r59928 - python/trunk/Doc/library/dis.rst Message-ID: <20080111232518.B06FA1E4027@bag.python.org> Author: raymond.hettinger Date: Sat Jan 12 00:25:18 2008 New Revision: 59928 Modified: python/trunk/Doc/library/dis.rst Log: Update the opcode docs for STORE_MAP and BUILD_MAP Modified: python/trunk/Doc/library/dis.rst ============================================================================== --- python/trunk/Doc/library/dis.rst (original) +++ python/trunk/Doc/library/dis.rst Sat Jan 12 00:25:18 2008 @@ -608,10 +608,10 @@ Works as ``BUILD_TUPLE``, but creates a list. -.. opcode:: BUILD_MAP (zero) +.. opcode:: BUILD_MAP (count) - Pushes a new empty dictionary object onto the stack. The argument is ignored - and set to zero by the compiler. + Pushes a new dictionary object onto the stack. The dictionary is pre-sized + to hold *count* entries. .. opcode:: LOAD_ATTR (namei) @@ -691,6 +691,10 @@ Pushes a try block from a try-except clause onto the block stack. *delta* points to the finally block. +.. opcode:: STORE_MAP () + + Store a key and value pair in a dictionary. Pops the key and value while leaving + the dictionary on the stack. .. opcode:: LOAD_FAST (var_num) From python-checkins at python.org Sat Jan 12 02:56:00 2008 From: python-checkins at python.org (mark.dickinson) Date: Sat, 12 Jan 2008 02:56:00 +0100 (CET) Subject: [Python-checkins] r59929 - in python/trunk: Doc/library/decimal.rst Lib/decimal.py Lib/test/test_decimal.py Misc/NEWS Message-ID: <20080112015600.ED40F1E4012@bag.python.org> Author: mark.dickinson Date: Sat Jan 12 02:56:00 2008 New Revision: 59929 Modified: python/trunk/Doc/library/decimal.rst python/trunk/Lib/decimal.py python/trunk/Lib/test/test_decimal.py python/trunk/Misc/NEWS Log: Issue 1780: Allow leading and trailing whitespace in Decimal constructor, when constructing from a string. Disallow trailing newlines in Context.create_decimal. Modified: python/trunk/Doc/library/decimal.rst ============================================================================== --- python/trunk/Doc/library/decimal.rst (original) +++ python/trunk/Doc/library/decimal.rst Sat Jan 12 02:56:00 2008 @@ -281,9 +281,10 @@ Construct a new :class:`Decimal` object based from *value*. - *value* can be an integer, string, tuple, or another :class:`Decimal` object. If - no *value* is given, returns ``Decimal("0")``. If *value* is a string, it - should conform to the decimal numeric string syntax:: + *value* can be an integer, string, tuple, or another :class:`Decimal` + object. If no *value* is given, returns ``Decimal("0")``. If *value* is a + string, it should conform to the decimal numeric string syntax after leading + and trailing whitespace characters are removed:: sign ::= '+' | '-' digit ::= '0' | '1' | '2' | '3' | '4' | '5' | '6' | '7' | '8' | '9' @@ -313,6 +314,10 @@ Once constructed, :class:`Decimal` objects are immutable. + .. versionchanged:: 2.6 + leading and trailing whitespace characters are permitted when + creating a Decimal instance from a string. + Decimal floating point objects share many properties with the other built-in numeric types such as :class:`float` and :class:`int`. All of the usual math operations and special methods apply. Likewise, decimal objects can be copied, @@ -973,6 +978,9 @@ >>> Decimal("3.4445") + Decimal(0) + Decimal("1.0023") Decimal("4.44") + This method implements the to-number operation of the IBM + specification. If the argument is a string, no leading or trailing + whitespace is permitted. .. method:: Context.Etiny() Modified: python/trunk/Lib/decimal.py ============================================================================== --- python/trunk/Lib/decimal.py (original) +++ python/trunk/Lib/decimal.py Sat Jan 12 02:56:00 2008 @@ -523,6 +523,8 @@ Decimal("314") >>> Decimal(Decimal(314)) # another decimal instance Decimal("314") + >>> Decimal(' 3.14 \\n') # leading and trailing whitespace okay + Decimal("3.14") """ # Note that the coefficient, self._int, is actually stored as @@ -538,7 +540,7 @@ # From a string # REs insist on real strings, so we can too. if isinstance(value, basestring): - m = _parser(value) + m = _parser(value.strip()) if m is None: if context is None: context = getcontext() @@ -3533,7 +3535,16 @@ return rounding def create_decimal(self, num='0'): - """Creates a new Decimal instance but using self as context.""" + """Creates a new Decimal instance but using self as context. + + This method implements the to-number operation of the + IBM Decimal specification.""" + + if isinstance(num, basestring) and num != num.strip(): + return self._raise_error(ConversionSyntax, + "no trailing or leading whitespace is " + "permitted.") + d = Decimal(num, context=self) if d._isnan() and len(d._int) > self.prec - self._clamp: return self._raise_error(ConversionSyntax, @@ -5148,7 +5159,7 @@ (?P\d*) # with (possibly empty) diagnostic information. ) # \s* - $ + \Z """, re.VERBOSE | re.IGNORECASE).match _all_zeros = re.compile('0*$').match Modified: python/trunk/Lib/test/test_decimal.py ============================================================================== --- python/trunk/Lib/test/test_decimal.py (original) +++ python/trunk/Lib/test/test_decimal.py Sat Jan 12 02:56:00 2008 @@ -429,6 +429,10 @@ #just not a number self.assertEqual(str(Decimal('ugly')), 'NaN') + #leading and trailing whitespace permitted + self.assertEqual(str(Decimal('1.3E4 \n')), '1.3E+4') + self.assertEqual(str(Decimal(' -7.89')), '-7.89') + def test_explicit_from_tuples(self): #zero @@ -517,6 +521,10 @@ self.assertEqual(str(d), '456789') d = nc.create_decimal('456789') self.assertEqual(str(d), '4.57E+5') + # leading and trailing whitespace should result in a NaN; + # spaces are already checked in Cowlishaw's test-suite, so + # here we just check that a trailing newline results in a NaN + self.assertEqual(str(nc.create_decimal('3.14\n')), 'NaN') # from tuples d = Decimal( (1, (4, 3, 4, 9, 1, 3, 5, 3, 4), -25) ) Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Sat Jan 12 02:56:00 2008 @@ -351,6 +351,10 @@ Library ------- +- Issue #1780: The Decimal constructor now accepts arbitrary leading + and trailing whitespace when constructing from a string. + Context.create_decimal no longer accepts trailing newlines. + - Decimal.as_tuple(), difflib.find_longest_match() and inspect functions that returned a tuple now return a named tuple. From python-checkins at python.org Sat Jan 12 11:53:29 2008 From: python-checkins at python.org (georg.brandl) Date: Sat, 12 Jan 2008 11:53:29 +0100 (CET) Subject: [Python-checkins] r59930 - python/trunk/Doc/library/exceptions.rst python/trunk/Doc/library/os.rst python/trunk/Doc/library/posix.rst Message-ID: <20080112105329.9DC4F1E400D@bag.python.org> Author: georg.brandl Date: Sat Jan 12 11:53:29 2008 New Revision: 59930 Modified: python/trunk/Doc/library/exceptions.rst python/trunk/Doc/library/os.rst python/trunk/Doc/library/posix.rst Log: Move OSError docs to exceptions doc, remove obsolete descriptions from os docs, rework posix docs. Modified: python/trunk/Doc/library/exceptions.rst ============================================================================== --- python/trunk/Doc/library/exceptions.rst (original) +++ python/trunk/Doc/library/exceptions.rst Sat Jan 12 11:53:29 2008 @@ -233,11 +233,24 @@ .. exception:: OSError - This class is derived from :exc:`EnvironmentError` and is used primarily as the - :mod:`os` module's ``os.error`` exception. See :exc:`EnvironmentError` above for - a description of the possible associated values. + and is used primarily as + the :mod:`os` module's :exc:`os.error` exception. See :exc:`EnvironmentError` + above for a description of the possible associated values. .. versionadded:: 1.5.2 + .. index:: module: errno + + This exception is derived from :exc:`EnvironmentError`. It is raised when a + function returns a system-related error (not for illegal argument types or + other incidental errors). The :attr:`errno` attribute is a numeric error + code from :cdata:`errno`, and the :attr:`strerror` attribute is the + corresponding string, as would be printed by the C function :cfunc:`perror`. + See the module :mod:`errno`, which contains names for the error codes defined + by the underlying operating system. + + For exceptions that involve a file system path (such as :func:`chdir` or + :func:`unlink`), the exception instance will contain a third attribute, + :attr:`filename`, which is the file name passed to the function. .. exception:: OverflowError Modified: python/trunk/Doc/library/os.rst ============================================================================== --- python/trunk/Doc/library/os.rst (original) +++ python/trunk/Doc/library/os.rst Sat Jan 12 11:53:29 2008 @@ -1,4 +1,3 @@ - :mod:`os` --- Miscellaneous operating system interfaces ======================================================= @@ -6,54 +5,33 @@ :synopsis: Miscellaneous operating system interfaces. -This module provides a more portable way of using operating system dependent -functionality than importing an operating system dependent built-in module like -:mod:`posix` or :mod:`nt`. If you just want to read or write a file see -:func:`open`, if you want to manipulate paths, see the :mod:`os.path` -module, and if you want to read all the lines in all the files on the -command line see the :mod:`fileinput` module. For creating temporary -files and directories see the :mod:`tempfile` module, and for high-level -file and directory handling see the :mod:`shutil` module. - -This module searches for an operating system dependent built-in module like -:mod:`mac` or :mod:`posix` and exports the same functions and data as found -there. The design of all built-in operating system dependent modules of Python -is such that as long as the same functionality is available, it uses the same -interface; for example, the function ``os.stat(path)`` returns stat information -about *path* in the same format (which happens to have originated with the POSIX +This module provides a portable way of using operating system dependent +functionality. If you just want to read or write a file see :func:`open`, if +you want to manipulate paths, see the :mod:`os.path` module, and if you want to +read all the lines in all the files on the command line see the :mod:`fileinput` +module. For creating temporary files and directories see the :mod:`tempfile` +module, and for high-level file and directory handling see the :mod:`shutil` +module. + +The design of all built-in operating system dependent modules of Python is such +that as long as the same functionality is available, it uses the same interface; +for example, the function ``os.stat(path)`` returns stat information about +*path* in the same format (which happens to have originated with the POSIX interface). Extensions peculiar to a particular operating system are also available through the :mod:`os` module, but using them is of course a threat to portability! -Note that after the first time :mod:`os` is imported, there is *no* performance -penalty in using functions from :mod:`os` instead of directly from the operating -system dependent built-in module, so there should be *no* reason not to use -:mod:`os`! +.. note:: -The :mod:`os` module contains many functions and data values. The items below -and in the following sub-sections are all available directly from the :mod:`os` -module. + All functions in this module raise :exc:`OSError` in the case of invalid or + inaccessible file names and paths, or other arguments that have the correct + type, but are not accepted by the operating system. .. exception:: error - .. index:: module: errno - - This exception is raised when a function returns a system-related error (not for - illegal argument types or other incidental errors). This is also known as the - built-in exception :exc:`OSError`. The accompanying value is a pair containing - the numeric error code from :cdata:`errno` and the corresponding string, as - would be printed by the C function :cfunc:`perror`. See the module - :mod:`errno`, which contains names for the error codes defined by the underlying - operating system. - - When exceptions are classes, this exception carries two attributes, - :attr:`errno` and :attr:`strerror`. The first holds the value of the C - :cdata:`errno` variable, and the latter holds the corresponding error message - from :cfunc:`strerror`. For exceptions that involve a file system path (such as - :func:`chdir` or :func:`unlink`), the exception instance will contain a third - attribute, :attr:`filename`, which is the file name passed to the function. + An alias for the built-in :exc:`OSError` exception. .. data:: name @@ -748,7 +726,6 @@ Files and Directories --------------------- - .. function:: access(path, mode) Use the real uid/gid to test for access to *path*. Note that most operations @@ -2032,8 +2009,8 @@ .. function:: getloadavg() - Return the number of processes in the system run queue averaged over the last 1, - 5, and 15 minutes or raises :exc:`OSError` if the load average was + Return the number of processes in the system run queue averaged over the last + 1, 5, and 15 minutes or raises :exc:`OSError` if the load average was unobtainable. .. versionadded:: 2.3 Modified: python/trunk/Doc/library/posix.rst ============================================================================== --- python/trunk/Doc/library/posix.rst (original) +++ python/trunk/Doc/library/posix.rst Sat Jan 12 11:53:29 2008 @@ -1,4 +1,3 @@ - :mod:`posix` --- The most common POSIX system calls =================================================== @@ -22,13 +21,8 @@ :mod:`os` provides some additional functionality, such as automatically calling :func:`putenv` when an entry in ``os.environ`` is changed. -The descriptions below are very terse; refer to the corresponding Unix manual -(or POSIX documentation) entry for more information. Arguments called *path* -refer to a pathname given as a string. - Errors are reported as exceptions; the usual exceptions are given for type -errors, while errors reported by the system calls raise :exc:`error` (a synonym -for the standard exception :exc:`OSError`), described below. +errors, while errors reported by the system calls raise :exc:`OSError`. .. _posix-large-files: @@ -42,9 +36,8 @@ .. sectionauthor:: Steve Clift - -Several operating systems (including AIX, HPUX, Irix and Solaris) provide -support for files that are larger than 2 Gb from a C programming model where +Several operating systems (including AIX, HP-UX, Irix and Solaris) provide +support for files that are larger than 2 GB from a C programming model where :ctype:`int` and :ctype:`long` are 32-bit values. This is typically accomplished by defining the relevant size and offset types as 64-bit values. Such files are sometimes referred to as :dfn:`large files`. @@ -68,16 +61,16 @@ .. _posix-contents: -Module Contents ---------------- - -Module :mod:`posix` defines the following data item: +Notable Module Contents +----------------------- +In addition to many functions described in the :mod:`os` module documentation, +:mod:`posix` defines the following data item: .. data:: environ - A dictionary representing the string environment at the time the interpreter was - started. For example, ``environ['HOME']`` is the pathname of your home + A dictionary representing the string environment at the time the interpreter + was started. For example, ``environ['HOME']`` is the pathname of your home directory, equivalent to ``getenv("HOME")`` in C. Modifying this dictionary does not affect the string environment passed on by @@ -91,7 +84,3 @@ updates the environment on modification. Note also that updating ``os.environ`` will render this dictionary obsolete. Use of the :mod:`os` module version of this is recommended over direct access to the :mod:`posix` module. - -Additional contents of this module should only be accessed via the :mod:`os` -module; refer to the documentation for that module for further information. - From python-checkins at python.org Sat Jan 12 14:47:58 2008 From: python-checkins at python.org (georg.brandl) Date: Sat, 12 Jan 2008 14:47:58 +0100 (CET) Subject: [Python-checkins] r59931 - in python/trunk: Include/object.h Misc/NEWS Objects/object.c Objects/typeobject.c Message-ID: <20080112134758.83C0C1E400D@bag.python.org> Author: georg.brandl Date: Sat Jan 12 14:47:57 2008 New Revision: 59931 Modified: python/trunk/Include/object.h python/trunk/Misc/NEWS python/trunk/Objects/object.c python/trunk/Objects/typeobject.c Log: Patch #1700288: Method cache optimization, by Armin Rigo, ported to 2.6 by Kevin Jacobs. Modified: python/trunk/Include/object.h ============================================================================== --- python/trunk/Include/object.h (original) +++ python/trunk/Include/object.h Sat Jan 12 14:47:57 2008 @@ -345,6 +345,9 @@ PyObject *tp_weaklist; destructor tp_del; + /* Type attribute cache version tag. Added in version 2.6 */ + unsigned int tp_version_tag; + #ifdef COUNT_ALLOCS /* these must be last and never explicitly initialized */ Py_ssize_t tp_allocs; @@ -529,6 +532,10 @@ /* Objects support nb_index in PyNumberMethods */ #define Py_TPFLAGS_HAVE_INDEX (1L<<17) +/* Objects support type attribute cache */ +#define Py_TPFLAGS_HAVE_VERSION_TAG (1L<<18) +#define Py_TPFLAGS_VALID_VERSION_TAG (1L<<19) + /* These flags are used to determine if a type is a subclass. */ #define Py_TPFLAGS_INT_SUBCLASS (1L<<23) #define Py_TPFLAGS_LONG_SUBCLASS (1L<<24) @@ -550,6 +557,7 @@ Py_TPFLAGS_HAVE_CLASS | \ Py_TPFLAGS_HAVE_STACKLESS_EXTENSION | \ Py_TPFLAGS_HAVE_INDEX | \ + Py_TPFLAGS_HAVE_VERSION_TAG | \ 0) #define PyType_HasFeature(t,f) (((t)->tp_flags & (f)) != 0) Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Sat Jan 12 14:47:57 2008 @@ -12,6 +12,9 @@ Core and builtins ----------------- +- Patch #1700288: added a type attribute cache that caches method accesses, + resulting in speedups in heavily object-oriented code. + - Bug #1776: __import__() no longer accepts filenames on any platform. The first parameter to __import__() must be a valid module name. Modified: python/trunk/Objects/object.c ============================================================================== --- python/trunk/Objects/object.c (original) +++ python/trunk/Objects/object.c Sat Jan 12 14:47:57 2008 @@ -1287,6 +1287,7 @@ goto done; } +#if 0 /* XXX this is not quite _PyType_Lookup anymore */ /* Inline _PyType_Lookup */ { Py_ssize_t i, n; @@ -1311,6 +1312,9 @@ break; } } +#else + descr = _PyType_Lookup(tp, name); +#endif Py_XINCREF(descr); Modified: python/trunk/Objects/typeobject.c ============================================================================== --- python/trunk/Objects/typeobject.c (original) +++ python/trunk/Objects/typeobject.c Sat Jan 12 14:47:57 2008 @@ -5,6 +5,171 @@ #include + +/* Support type attribute cache */ + +/* The cache can keep references to the names alive for longer than + they normally would. This is why the maximum size is limited to + MCACHE_MAX_ATTR_SIZE, since it might be a problem if very large + strings are used as attribute names. */ +#define MCACHE_MAX_ATTR_SIZE 100 +#define MCACHE_SIZE_EXP 10 +#define MCACHE_HASH(version, name_hash) \ + (((unsigned int)(version) * (unsigned int)(name_hash)) \ + >> (8*sizeof(unsigned int) - MCACHE_SIZE_EXP)) +#define MCACHE_HASH_METHOD(type, name) \ + MCACHE_HASH((type)->tp_version_tag, \ + ((PyStringObject *)(name))->ob_shash) +#define MCACHE_CACHEABLE_NAME(name) \ + PyString_CheckExact(name) && \ + PyString_GET_SIZE(name) <= MCACHE_MAX_ATTR_SIZE + +struct method_cache_entry { + unsigned int version; + PyObject *name; /* reference to exactly a str or None */ + PyObject *value; /* borrowed */ +}; + +static struct method_cache_entry method_cache[1 << MCACHE_SIZE_EXP]; +static unsigned int next_version_tag = 0; + +static void +type_modified(PyTypeObject *type) +{ + /* Invalidate any cached data for the specified type and all + subclasses. This function is called after the base + classes, mro, or attributes of the type are altered. + + Invariants: + + - Py_TPFLAGS_VALID_VERSION_TAG is never set if + Py_TPFLAGS_HAVE_VERSION_TAG is not set (e.g. on type + objects coming from non-recompiled extension modules) + + - before Py_TPFLAGS_VALID_VERSION_TAG can be set on a type, + it must first be set on all super types. + + This function clears the Py_TPFLAGS_VALID_VERSION_TAG of a + type (so it must first clear it on all subclasses). The + tp_version_tag value is meaningless unless this flag is set. + We don't assign new version tags eagerly, but only as + needed. + */ + PyObject *raw, *ref; + Py_ssize_t i, n; + + if(!PyType_HasFeature(type, Py_TPFLAGS_VALID_VERSION_TAG)) + return; + + raw = type->tp_subclasses; + if (raw != NULL) { + n = PyList_GET_SIZE(raw); + for (i = 0; i < n; i++) { + ref = PyList_GET_ITEM(raw, i); + ref = PyWeakref_GET_OBJECT(ref); + if (ref != Py_None) { + type_modified((PyTypeObject *)ref); + } + } + } + type->tp_flags &= ~Py_TPFLAGS_VALID_VERSION_TAG; +} + +static void +type_mro_modified(PyTypeObject *type, PyObject *bases) { + /* + Check that all base classes or elements of the mro of type are + able to be cached. This function is called after the base + classes or mro of the type are altered. + + Unset HAVE_VERSION_TAG and VALID_VERSION_TAG if the type + inherits from an old-style class, either directly or if it + appears in the MRO of a new-style class. No support either for + custom MROs that include types that are not officially super + types. + + Called from mro_internal, which will subsequently be called on + each subclass when their mro is recursively updated. + */ + Py_ssize_t i, n; + int clear = 0; + + if(!PyType_HasFeature(type, Py_TPFLAGS_HAVE_VERSION_TAG)) + return; + + n = PyTuple_GET_SIZE(bases); + for (i = 0; i < n; i++) { + PyObject *b = PyTuple_GET_ITEM(bases, i); + PyTypeObject *cls; + + if (!PyType_Check(b) ) { + clear = 1; + break; + } + + cls = (PyTypeObject *)b; + + if (!PyType_HasFeature(cls, Py_TPFLAGS_HAVE_VERSION_TAG) || + !PyType_IsSubtype(type, cls)) { + clear = 1; + break; + } + } + + if (clear) + type->tp_flags &= ~(Py_TPFLAGS_HAVE_VERSION_TAG| + Py_TPFLAGS_VALID_VERSION_TAG); +} + +static int +assign_version_tag(PyTypeObject *type) +{ + /* Ensure that the tp_version_tag is valid and set + Py_TPFLAGS_VALID_VERSION_TAG. To respect the invariant, this + must first be done on all super classes. Return 0 if this + cannot be done, 1 if Py_TPFLAGS_VALID_VERSION_TAG. + */ + Py_ssize_t i, n; + PyObject *bases; + + if (PyType_HasFeature(type, Py_TPFLAGS_VALID_VERSION_TAG)) + return 1; + if (!PyType_HasFeature(type, Py_TPFLAGS_HAVE_VERSION_TAG)) + return 0; + if (!PyType_HasFeature(type, Py_TPFLAGS_READY)) + return 0; + + type->tp_version_tag = next_version_tag++; + /* for stress-testing: next_version_tag &= 0xFF; */ + + if (type->tp_version_tag == 0) { + /* wrap-around or just starting Python - clear the whole + cache by filling names with references to Py_None. + Values are also set to NULL for added protection, as they + are borrowed reference */ + for (i = 0; i < (1 << MCACHE_SIZE_EXP); i++) { + method_cache[i].value = NULL; + Py_XDECREF(method_cache[i].name); + method_cache[i].name = Py_None; + Py_INCREF(Py_None); + } + /* mark all version tags as invalid */ + type_modified(&PyBaseObject_Type); + return 1; + } + bases = type->tp_bases; + n = PyTuple_GET_SIZE(bases); + for (i = 0; i < n; i++) { + PyObject *b = PyTuple_GET_ITEM(bases, i); + assert(PyType_Check(b)); + if (!assign_version_tag((PyTypeObject *)b)) + return 0; + } + type->tp_flags |= Py_TPFLAGS_VALID_VERSION_TAG; + return 1; +} + + static PyMemberDef type_members[] = { {"__basicsize__", T_INT, offsetof(PyTypeObject,tp_basicsize),READONLY}, {"__itemsize__", T_INT, offsetof(PyTypeObject, tp_itemsize), READONLY}, @@ -117,6 +282,8 @@ return -1; } + type_modified(type); + return PyDict_SetItemString(type->tp_dict, "__module__", value); } @@ -1351,6 +1518,14 @@ } } type->tp_mro = tuple; + + type_mro_modified(type, type->tp_mro); + /* corner case: the old-style super class might have been hidden + from the custom MRO */ + type_mro_modified(type, type->tp_bases); + + type_modified(type); + return 0; } @@ -2143,6 +2318,16 @@ { Py_ssize_t i, n; PyObject *mro, *res, *base, *dict; + unsigned int h; + + if (MCACHE_CACHEABLE_NAME(name) && + PyType_HasFeature(type,Py_TPFLAGS_VALID_VERSION_TAG)) { + /* fast path */ + h = MCACHE_HASH_METHOD(type, name); + if (method_cache[h].version == type->tp_version_tag && + method_cache[h].name == name) + return method_cache[h].value; + } /* Look in tp_dict of types in MRO */ mro = type->tp_mro; @@ -2153,6 +2338,7 @@ if (mro == NULL) return NULL; + res = NULL; assert(PyTuple_Check(mro)); n = PyTuple_GET_SIZE(mro); for (i = 0; i < n; i++) { @@ -2166,9 +2352,18 @@ assert(dict && PyDict_Check(dict)); res = PyDict_GetItem(dict, name); if (res != NULL) - return res; + break; } - return NULL; + + if (MCACHE_CACHEABLE_NAME(name) && assign_version_tag(type)) { + h = MCACHE_HASH_METHOD(type, name); + method_cache[h].version = type->tp_version_tag; + method_cache[h].value = res; /* borrowed */ + Py_INCREF(name); + Py_DECREF(method_cache[h].name); + method_cache[h].name = name; + } + return res; } /* This is similar to PyObject_GenericGetAttr(), @@ -2258,10 +2453,6 @@ type->tp_name); return -1; } - /* XXX Example of how I expect this to be used... - if (update_subclasses(type, name, invalidate_cache, NULL) < 0) - return -1; - */ if (PyObject_GenericSetAttr((PyObject *)type, name, value) < 0) return -1; return update_slot(type, name); @@ -5684,6 +5875,13 @@ slotdef **pp; int offset; + /* Clear the VALID_VERSION flag of 'type' and all its + subclasses. This could possibly be unified with the + update_subclasses() recursion below, but carefully: + they each have their own conditions on which to stop + recursing into subclasses. */ + type_modified(type); + init_slotdefs(); pp = ptrs; for (p = slotdefs; p->name; p++) { From buildbot at python.org Sat Jan 12 15:15:13 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 12 Jan 2008 14:15:13 +0000 Subject: [Python-checkins] buildbot failure in x86 mvlgcc trunk Message-ID: <20080112141513.B80501E400D@bag.python.org> The Buildbot has detected a new failure of x86 mvlgcc trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20mvlgcc%20trunk/builds/1192 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-linux Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: georg.brandl BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_ctypes ====================================================================== ERROR: test_incomplete_example (ctypes.test.test_incomplete.MyTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home2/buildbot/slave/trunk.loewis-linux/build/Lib/ctypes/test/test_incomplete.py", line 32, in test_incomplete_example p = p.next[0] AttributeError: 'cell' object has no attribute 'next' make: *** [buildbottest] Fehler 1 sincerely, -The Buildbot From buildbot at python.org Sat Jan 12 15:15:28 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 12 Jan 2008 14:15:28 +0000 Subject: [Python-checkins] buildbot failure in x86 gentoo trunk Message-ID: <20080112141528.CEE331E4013@bag.python.org> The Buildbot has detected a new failure of x86 gentoo trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20gentoo%20trunk/builds/2876 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-x86 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: georg.brandl BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30996, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Traceback (most recent call last): File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30996, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Traceback (most recent call last): File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30996, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Traceback (most recent call last): File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30996, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') 1 test failed: test_ctypes ====================================================================== ERROR: test_incomplete_example (ctypes.test.test_incomplete.MyTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/ctypes/test/test_incomplete.py", line 32, in test_incomplete_example p = p.next[0] AttributeError: 'cell' object has no attribute 'next' make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Sat Jan 12 15:37:50 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 12 Jan 2008 14:37:50 +0000 Subject: [Python-checkins] buildbot failure in sparc solaris10 gcc trunk Message-ID: <20080112143750.5F9FB1E4012@bag.python.org> The Buildbot has detected a new failure of sparc solaris10 gcc trunk. Full details are available at: http://www.python.org/dev/buildbot/all/sparc%20solaris10%20gcc%20trunk/builds/2599 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-sun Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: georg.brandl BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_ctypes ====================================================================== ERROR: test_incomplete_example (ctypes.test.test_incomplete.MyTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/ctypes/test/test_incomplete.py", line 32, in test_incomplete_example p = p.next[0] AttributeError: 'cell' object has no attribute 'next' sincerely, -The Buildbot From buildbot at python.org Sat Jan 12 15:44:13 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 12 Jan 2008 14:44:13 +0000 Subject: [Python-checkins] buildbot failure in g4 osx.4 trunk Message-ID: <20080112144413.E17891E400F@bag.python.org> The Buildbot has detected a new failure of g4 osx.4 trunk. Full details are available at: http://www.python.org/dev/buildbot/all/g4%20osx.4%20trunk/builds/2599 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: psf-g4 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: georg.brandl BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_ctypes ====================================================================== ERROR: test_incomplete_example (ctypes.test.test_incomplete.MyTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/ctypes/test/test_incomplete.py", line 32, in test_incomplete_example p = p.next[0] AttributeError: 'cell' object has no attribute 'next' make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Sat Jan 12 15:55:12 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 12 Jan 2008 14:55:12 +0000 Subject: [Python-checkins] buildbot failure in ia64 Ubuntu trunk Message-ID: <20080112145512.ECA671E400D@bag.python.org> The Buildbot has detected a new failure of ia64 Ubuntu trunk. Full details are available at: http://www.python.org/dev/buildbot/all/ia64%20Ubuntu%20trunk/builds/1271 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ia64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: georg.brandl BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_ctypes ====================================================================== ERROR: test_incomplete_example (ctypes.test.test_incomplete.MyTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ia64/build/Lib/ctypes/test/test_incomplete.py", line 32, in test_incomplete_example p = p.next[0] AttributeError: 'cell' object has no attribute 'next' make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Sat Jan 12 17:11:10 2008 From: python-checkins at python.org (georg.brandl) Date: Sat, 12 Jan 2008 17:11:10 +0100 (CET) Subject: [Python-checkins] r59932 - python/trunk/Doc/library/exceptions.rst Message-ID: <20080112161110.14A5B1E400D@bag.python.org> Author: georg.brandl Date: Sat Jan 12 17:11:09 2008 New Revision: 59932 Modified: python/trunk/Doc/library/exceptions.rst Log: Fix editing glitch. Modified: python/trunk/Doc/library/exceptions.rst ============================================================================== --- python/trunk/Doc/library/exceptions.rst (original) +++ python/trunk/Doc/library/exceptions.rst Sat Jan 12 17:11:09 2008 @@ -233,11 +233,6 @@ .. exception:: OSError - and is used primarily as - the :mod:`os` module's :exc:`os.error` exception. See :exc:`EnvironmentError` - above for a description of the possible associated values. - - .. versionadded:: 1.5.2 .. index:: module: errno This exception is derived from :exc:`EnvironmentError`. It is raised when a @@ -252,6 +247,8 @@ :func:`unlink`), the exception instance will contain a third attribute, :attr:`filename`, which is the file name passed to the function. + .. versionadded:: 1.5.2 + .. exception:: OverflowError From martin at v.loewis.de Sat Jan 12 18:08:16 2008 From: martin at v.loewis.de (=?ISO-8859-1?Q?=22Martin_v=2E_L=F6wis=22?=) Date: Sat, 12 Jan 2008 18:08:16 +0100 Subject: [Python-checkins] r59913 - python/trunk/PCbuild/_sqlite3.vcproj In-Reply-To: <47878AA1.6040004@cheimes.de> References: <478779AA.7040003@ctypes.org> <4787852F.9020401@v.loewis.de> <47878AA1.6040004@cheimes.de> Message-ID: <4788F400.9070809@v.loewis.de> >> Otherwise, copy the assembly descriptor into the same directory as >> sqlite3.dll. > > On Windows XP and newer you can't simply copy an assembly DLL next to > the executable and assume that it picks up the DLL. That's why I said you should copy the assembly descriptor. That works. Regards, Martin From martin at v.loewis.de Sat Jan 12 18:11:29 2008 From: martin at v.loewis.de (=?ISO-8859-1?Q?=22Martin_v=2E_L=F6wis=22?=) Date: Sat, 12 Jan 2008 18:11:29 +0100 Subject: [Python-checkins] r59913 - python/trunk/PCbuild/_sqlite3.vcproj In-Reply-To: References: <478779AA.7040003@ctypes.org> <4787852F.9020401@v.loewis.de> Message-ID: <4788F4C1.5010101@v.loewis.de> >>> Yes, but I'm no longer sure whether sqlite3.dll should be compiled in >>> debug mode for a Python debug build at all. >> I don't think it should. > > Why so? full debug mode is sometimes useful, especially for modules > that may call back into the Python interpreter. If somebody wants to debug sqlite - sure. However, for the build process, it *should* be simpler to have only one build mode (assuming we know that mixing CRTs would actually work in that case). Regards, Martin From buildbot at python.org Sat Jan 12 21:03:37 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 12 Jan 2008 20:03:37 +0000 Subject: [Python-checkins] buildbot failure in hppa Ubuntu 3.0 Message-ID: <20080112200337.D59241E400F@bag.python.org> The Buildbot has detected a new failure of hppa Ubuntu 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/hppa%20Ubuntu%203.0/builds/437 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-ubuntu-hppa Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: make: *** [buildbottest] Unknown signal 37 sincerely, -The Buildbot From buildbot at python.org Sat Jan 12 21:52:23 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 12 Jan 2008 20:52:23 +0000 Subject: [Python-checkins] buildbot failure in ppc Debian unstable 3.0 Message-ID: <20080112205223.B64081E4020@bag.python.org> The Buildbot has detected a new failure of ppc Debian unstable 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/ppc%20Debian%20unstable%203.0/builds/459 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: guido.van.rossum BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_xmlrpc ====================================================================== ERROR: test_fail_no_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/test/test_xmlrpc.py", line 497, in test_fail_no_info p.pow(6,8) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1091, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1349, in __request verbose=self.__verbose File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1121, in request resp = http_conn.getresponse() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/httplib.py", line 961, in getresponse response.begin() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/httplib.py", line 425, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/httplib.py", line 267, in readheaders line = str(self.fp.readline(), "iso-8859-1") File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/io.py", line 413, in readline b = self.read(nreadahead()) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/io.py", line 475, in read n = self.readinto(b) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/socket.py", line 217, in readinto return self._sock.recv_into(b) socket.error: [Errno 104] Connection reset by peer ====================================================================== ERROR: test_fail_with_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/test/test_xmlrpc.py", line 515, in test_fail_with_info p.pow(6,8) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1091, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1349, in __request verbose=self.__verbose File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1121, in request resp = http_conn.getresponse() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/httplib.py", line 961, in getresponse response.begin() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/httplib.py", line 425, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/httplib.py", line 267, in readheaders line = str(self.fp.readline(), "iso-8859-1") File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/io.py", line 413, in readline b = self.read(nreadahead()) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/io.py", line 475, in read n = self.readinto(b) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/socket.py", line 217, in readinto return self._sock.recv_into(b) socket.error: [Errno 104] Connection reset by peer make: *** [buildbottest] Error 1 sincerely, -The Buildbot From nnorwitz at gmail.com Sat Jan 12 23:28:56 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Sat, 12 Jan 2008 17:28:56 -0500 Subject: [Python-checkins] Python Regression Test Failures refleak (8) Message-ID: <20080112222856.GA6487@python.psfb.org> test_opcodes leaked [-2, 0, 2] references, sum=0 test_doctest leaked [0, 0, -4] references, sum=-4 test_descrtut leaked [0, 0, -2] references, sum=-2 test_dummy_thread leaked [0, 0, -2] references, sum=-2 test_gc leaked [4, 0, -2] references, sum=2 test_genericpath leaked [0, 0, -2] references, sum=-2 test_getargs leaked [-2, 0, 0] references, sum=-2 test_importhooks leaked [10, -8, 0] references, sum=2 test_os leaked [0, -2, 2] references, sum=0 test_ssl leaked [-2, 0, 0] references, sum=-2 test_urllib2_localnet leaked [3, 3, 3] references, sum=9 From theller at ctypes.org Sun Jan 13 00:09:56 2008 From: theller at ctypes.org (Thomas Heller) Date: Sun, 13 Jan 2008 00:09:56 +0100 Subject: [Python-checkins] r59920 - python/trunk/Modules/socketmodule.c In-Reply-To: <20080111154230.274731E400A@bag.python.org> References: <20080111154230.274731E400A@bag.python.org> Message-ID: christian.heimes schrieb: > Author: christian.heimes > Date: Fri Jan 11 16:42:29 2008 > New Revision: 59920 > > Modified: > python/trunk/Modules/socketmodule.c > Log: > Removed unused variable > > Modified: python/trunk/Modules/socketmodule.c > ============================================================================== > --- python/trunk/Modules/socketmodule.c (original) > +++ python/trunk/Modules/socketmodule.c Fri Jan 11 16:42:29 2008 > @@ -4334,7 +4334,7 @@ > PyMODINIT_FUNC > init_socket(void) > { > - PyObject *m, *has_ipv6, *tmp; > + PyObject *m, *has_ipv6; > > if (!os_init()) > return; This variable is NOT unused. It causes compilation to fail when SIO_RCVALL is defined. Thomas From python-checkins at python.org Sun Jan 13 07:15:16 2008 From: python-checkins at python.org (raymond.hettinger) Date: Sun, 13 Jan 2008 07:15:16 +0100 (CET) Subject: [Python-checkins] r59935 - python/trunk/Doc/glossary.rst Message-ID: <20080113061516.1A1E31E401B@bag.python.org> Author: raymond.hettinger Date: Sun Jan 13 07:15:15 2008 New Revision: 59935 Modified: python/trunk/Doc/glossary.rst Log: Named tuple is a concept, not a specific type. Modified: python/trunk/Doc/glossary.rst ============================================================================== --- python/trunk/Doc/glossary.rst (original) +++ python/trunk/Doc/glossary.rst Sun Jan 13 07:15:15 2008 @@ -340,11 +340,17 @@ also :term:`immutable`. named tuple - A tuple subclass whose elements also are accessible as attributes via - fixed names (the class name and field names are indicated in the - individual documentation of a named tuple type, like ``TestResults(failed, - attempted)``). Named tuple classes are created by - :func:`collections.namedtuple`. + Any tuple-like class whose indexable fields are also accessible with + named attributes (for example, :func:`time.localtime` returns a + tuple-like object where the *year* is accessable either with an + index such as ``t[0]`` or with a named attribute like ``t.tm_year``). + + A named tuple can be a built-in type such as :class:`time.struct_time`, + or it can be created with a regular class definition. A full featured + named tuple can also be created with the factory function + :func:`collections.namedtuple`. The latter approach automatically + provides extra features such as a self-documenting representation like + ``Employee(name='jones', title='programmer')``. namespace The place where a variable is stored. Namespaces are implemented as From python-checkins at python.org Sun Jan 13 07:18:08 2008 From: python-checkins at python.org (raymond.hettinger) Date: Sun, 13 Jan 2008 07:18:08 +0100 (CET) Subject: [Python-checkins] r59936 - python/trunk/Doc/glossary.rst Message-ID: <20080113061808.3FE2E1E401B@bag.python.org> Author: raymond.hettinger Date: Sun Jan 13 07:18:07 2008 New Revision: 59936 Modified: python/trunk/Doc/glossary.rst Log: Fix spelling. Modified: python/trunk/Doc/glossary.rst ============================================================================== --- python/trunk/Doc/glossary.rst (original) +++ python/trunk/Doc/glossary.rst Sun Jan 13 07:18:07 2008 @@ -342,7 +342,7 @@ named tuple Any tuple-like class whose indexable fields are also accessible with named attributes (for example, :func:`time.localtime` returns a - tuple-like object where the *year* is accessable either with an + tuple-like object where the *year* is accessible either with an index such as ``t[0]`` or with a named attribute like ``t.tm_year``). A named tuple can be a built-in type such as :class:`time.struct_time`, From python-checkins at python.org Sun Jan 13 10:36:18 2008 From: python-checkins at python.org (georg.brandl) Date: Sun, 13 Jan 2008 10:36:18 +0100 (CET) Subject: [Python-checkins] r59937 - python/trunk/Doc/library/functions.rst Message-ID: <20080113093618.4FECD1E401B@bag.python.org> Author: georg.brandl Date: Sun Jan 13 10:36:18 2008 New Revision: 59937 Modified: python/trunk/Doc/library/functions.rst Log: Clarify the effect of text mode. Modified: python/trunk/Doc/library/functions.rst ============================================================================== --- python/trunk/Doc/library/functions.rst (original) +++ python/trunk/Doc/library/functions.rst Sun Jan 13 10:36:18 2008 @@ -734,7 +734,9 @@ writing (truncating the file if it already exists), and ``'a'`` for appending (which on *some* Unix systems means that *all* writes append to the end of the file regardless of the current seek position). If *mode* is omitted, it - defaults to ``'r'``. When opening a binary file, you should append ``'b'`` to + defaults to ``'r'``. The default is to use text mode, which may convert + ``'\n'`` characters to a platform-specific representation on writing and back + on reading. Thus, when opening a binary file, you should append ``'b'`` to the *mode* value to open the file in binary mode, which will improve portability. (Appending ``'b'`` is useful even on systems that don't treat binary and text files differently, where it serves as documentation.) See below From nnorwitz at gmail.com Sun Jan 13 11:28:06 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Sun, 13 Jan 2008 05:28:06 -0500 Subject: [Python-checkins] Python Regression Test Failures refleak (8) Message-ID: <20080113102806.GA29244@python.psfb.org> test_opcodes leaked [-2, 0, 2] references, sum=0 test_doctest leaked [0, 0, -4] references, sum=-4 test_descrtut leaked [0, 0, -2] references, sum=-2 test_dummy_thread leaked [0, 0, -2] references, sum=-2 test_gc leaked [4, 0, -2] references, sum=2 test_genericpath leaked [0, 0, -2] references, sum=-2 test_getargs leaked [-2, 0, 0] references, sum=-2 test_importhooks leaked [10, -8, 0] references, sum=2 test_os leaked [0, -2, 2] references, sum=0 test_time leaked [0, -2, 0] references, sum=-2 test_urllib2_localnet leaked [3, 3, 3] references, sum=9 From python-checkins at python.org Sun Jan 13 12:19:43 2008 From: python-checkins at python.org (thomas.heller) Date: Sun, 13 Jan 2008 12:19:43 +0100 (CET) Subject: [Python-checkins] r59938 - python/trunk/Modules/socketmodule.c Message-ID: <20080113111943.EA8661E4004@bag.python.org> Author: thomas.heller Date: Sun Jan 13 12:19:43 2008 New Revision: 59938 Modified: python/trunk/Modules/socketmodule.c Log: Make Modules/socketobject.c compile for Windows again. Modified: python/trunk/Modules/socketmodule.c ============================================================================== --- python/trunk/Modules/socketmodule.c (original) +++ python/trunk/Modules/socketmodule.c Sun Jan 13 12:19:43 2008 @@ -5218,10 +5218,13 @@ #endif #ifdef SIO_RCVALL - tmp = PyLong_FromUnsignedLong(SIO_RCVALL); - if (tmp == NULL) - return; - PyModule_AddObject(m, "SIO_RCVALL", tmp); + { + PyObject *tmp; + tmp = PyLong_FromUnsignedLong(SIO_RCVALL); + if (tmp == NULL) + return; + PyModule_AddObject(m, "SIO_RCVALL", tmp); + } PyModule_AddIntConstant(m, "RCVALL_OFF", RCVALL_OFF); PyModule_AddIntConstant(m, "RCVALL_ON", RCVALL_ON); PyModule_AddIntConstant(m, "RCVALL_SOCKETLEVELONLY", RCVALL_SOCKETLEVELONLY); From python-checkins at python.org Sun Jan 13 12:25:13 2008 From: python-checkins at python.org (ka-ping.yee) Date: Sun, 13 Jan 2008 12:25:13 +0100 (CET) Subject: [Python-checkins] r59939 - python/trunk/Lib/pydoc.py Message-ID: <20080113112513.8AD5D1E402C@bag.python.org> Author: ka-ping.yee Date: Sun Jan 13 12:25:13 2008 New Revision: 59939 Modified: python/trunk/Lib/pydoc.py Log: Check in the patch proposed by Ben Hayden (benjhayden) for issue #1550: help('modules') broken by several 3rd party libraries. Tested with Python build: trunk:54235:59936M -- the reported error occurs with Django installed (or with any __init__.py present on the path that raises an exception), and such errors indeed go away when this change is applied. Modified: python/trunk/Lib/pydoc.py ============================================================================== --- python/trunk/Lib/pydoc.py (original) +++ python/trunk/Lib/pydoc.py Sun Jan 13 12:25:13 2008 @@ -1816,7 +1816,9 @@ modname = modname[:-9] + ' (package)' if find(modname, '.') < 0: modules[modname] = 1 - ModuleScanner().run(callback) + def onerror(modname): + callback(None, modname, None) + ModuleScanner().run(callback, onerror=onerror) self.list(modules.keys()) self.output.write(''' Enter any module name to get more help. Or, type "modules spam" to search @@ -1852,7 +1854,7 @@ class ModuleScanner: """An interruptible scanner that searches module synopses.""" - def run(self, callback, key=None, completer=None): + def run(self, callback, key=None, completer=None, onerror=None): if key: key = lower(key) self.quit = False seen = {} @@ -1867,7 +1869,7 @@ if find(lower(modname + ' - ' + desc), key) >= 0: callback(None, modname, desc) - for importer, modname, ispkg in pkgutil.walk_packages(): + for importer, modname, ispkg in pkgutil.walk_packages(onerror=onerror): if self.quit: break if key is None: From theller at ctypes.org Sun Jan 13 12:50:16 2008 From: theller at ctypes.org (Thomas Heller) Date: Sun, 13 Jan 2008 12:50:16 +0100 Subject: [Python-checkins] r59913 - python/trunk/PCbuild/_sqlite3.vcproj In-Reply-To: <4788F400.9070809@v.loewis.de> References: <478779AA.7040003@ctypes.org> <4787852F.9020401@v.loewis.de> <47878AA1.6040004@cheimes.de> <4788F400.9070809@v.loewis.de> Message-ID: <4789FAF8.3080605@ctypes.org> Martin v. L?wis schrieb: >>> Otherwise, copy the assembly descriptor into the same directory as >>> sqlite3.dll. >> >> On Windows XP and newer you can't simply copy an assembly DLL next to >> the executable and assume that it picks up the DLL. > > That's why I said you should copy the assembly descriptor. That works. Hm, I don't get it, sorry. What is the 'assembly descriptor'? Thanks, Thomas From python-checkins at python.org Sun Jan 13 16:04:06 2008 From: python-checkins at python.org (georg.brandl) Date: Sun, 13 Jan 2008 16:04:06 +0100 (CET) Subject: [Python-checkins] r59940 - in python/trunk: Include/object.h Misc/NEWS Objects/object.c Objects/typeobject.c Message-ID: <20080113150406.071991E4004@bag.python.org> Author: georg.brandl Date: Sun Jan 13 16:04:05 2008 New Revision: 59940 Modified: python/trunk/Include/object.h python/trunk/Misc/NEWS python/trunk/Objects/object.c python/trunk/Objects/typeobject.c Log: Back out r59931 - test_ctypes fails with it. Modified: python/trunk/Include/object.h ============================================================================== --- python/trunk/Include/object.h (original) +++ python/trunk/Include/object.h Sun Jan 13 16:04:05 2008 @@ -345,9 +345,6 @@ PyObject *tp_weaklist; destructor tp_del; - /* Type attribute cache version tag. Added in version 2.6 */ - unsigned int tp_version_tag; - #ifdef COUNT_ALLOCS /* these must be last and never explicitly initialized */ Py_ssize_t tp_allocs; @@ -532,10 +529,6 @@ /* Objects support nb_index in PyNumberMethods */ #define Py_TPFLAGS_HAVE_INDEX (1L<<17) -/* Objects support type attribute cache */ -#define Py_TPFLAGS_HAVE_VERSION_TAG (1L<<18) -#define Py_TPFLAGS_VALID_VERSION_TAG (1L<<19) - /* These flags are used to determine if a type is a subclass. */ #define Py_TPFLAGS_INT_SUBCLASS (1L<<23) #define Py_TPFLAGS_LONG_SUBCLASS (1L<<24) @@ -557,7 +550,6 @@ Py_TPFLAGS_HAVE_CLASS | \ Py_TPFLAGS_HAVE_STACKLESS_EXTENSION | \ Py_TPFLAGS_HAVE_INDEX | \ - Py_TPFLAGS_HAVE_VERSION_TAG | \ 0) #define PyType_HasFeature(t,f) (((t)->tp_flags & (f)) != 0) Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Sun Jan 13 16:04:05 2008 @@ -12,9 +12,6 @@ Core and builtins ----------------- -- Patch #1700288: added a type attribute cache that caches method accesses, - resulting in speedups in heavily object-oriented code. - - Bug #1776: __import__() no longer accepts filenames on any platform. The first parameter to __import__() must be a valid module name. Modified: python/trunk/Objects/object.c ============================================================================== --- python/trunk/Objects/object.c (original) +++ python/trunk/Objects/object.c Sun Jan 13 16:04:05 2008 @@ -1287,7 +1287,6 @@ goto done; } -#if 0 /* XXX this is not quite _PyType_Lookup anymore */ /* Inline _PyType_Lookup */ { Py_ssize_t i, n; @@ -1312,9 +1311,6 @@ break; } } -#else - descr = _PyType_Lookup(tp, name); -#endif Py_XINCREF(descr); Modified: python/trunk/Objects/typeobject.c ============================================================================== --- python/trunk/Objects/typeobject.c (original) +++ python/trunk/Objects/typeobject.c Sun Jan 13 16:04:05 2008 @@ -5,171 +5,6 @@ #include - -/* Support type attribute cache */ - -/* The cache can keep references to the names alive for longer than - they normally would. This is why the maximum size is limited to - MCACHE_MAX_ATTR_SIZE, since it might be a problem if very large - strings are used as attribute names. */ -#define MCACHE_MAX_ATTR_SIZE 100 -#define MCACHE_SIZE_EXP 10 -#define MCACHE_HASH(version, name_hash) \ - (((unsigned int)(version) * (unsigned int)(name_hash)) \ - >> (8*sizeof(unsigned int) - MCACHE_SIZE_EXP)) -#define MCACHE_HASH_METHOD(type, name) \ - MCACHE_HASH((type)->tp_version_tag, \ - ((PyStringObject *)(name))->ob_shash) -#define MCACHE_CACHEABLE_NAME(name) \ - PyString_CheckExact(name) && \ - PyString_GET_SIZE(name) <= MCACHE_MAX_ATTR_SIZE - -struct method_cache_entry { - unsigned int version; - PyObject *name; /* reference to exactly a str or None */ - PyObject *value; /* borrowed */ -}; - -static struct method_cache_entry method_cache[1 << MCACHE_SIZE_EXP]; -static unsigned int next_version_tag = 0; - -static void -type_modified(PyTypeObject *type) -{ - /* Invalidate any cached data for the specified type and all - subclasses. This function is called after the base - classes, mro, or attributes of the type are altered. - - Invariants: - - - Py_TPFLAGS_VALID_VERSION_TAG is never set if - Py_TPFLAGS_HAVE_VERSION_TAG is not set (e.g. on type - objects coming from non-recompiled extension modules) - - - before Py_TPFLAGS_VALID_VERSION_TAG can be set on a type, - it must first be set on all super types. - - This function clears the Py_TPFLAGS_VALID_VERSION_TAG of a - type (so it must first clear it on all subclasses). The - tp_version_tag value is meaningless unless this flag is set. - We don't assign new version tags eagerly, but only as - needed. - */ - PyObject *raw, *ref; - Py_ssize_t i, n; - - if(!PyType_HasFeature(type, Py_TPFLAGS_VALID_VERSION_TAG)) - return; - - raw = type->tp_subclasses; - if (raw != NULL) { - n = PyList_GET_SIZE(raw); - for (i = 0; i < n; i++) { - ref = PyList_GET_ITEM(raw, i); - ref = PyWeakref_GET_OBJECT(ref); - if (ref != Py_None) { - type_modified((PyTypeObject *)ref); - } - } - } - type->tp_flags &= ~Py_TPFLAGS_VALID_VERSION_TAG; -} - -static void -type_mro_modified(PyTypeObject *type, PyObject *bases) { - /* - Check that all base classes or elements of the mro of type are - able to be cached. This function is called after the base - classes or mro of the type are altered. - - Unset HAVE_VERSION_TAG and VALID_VERSION_TAG if the type - inherits from an old-style class, either directly or if it - appears in the MRO of a new-style class. No support either for - custom MROs that include types that are not officially super - types. - - Called from mro_internal, which will subsequently be called on - each subclass when their mro is recursively updated. - */ - Py_ssize_t i, n; - int clear = 0; - - if(!PyType_HasFeature(type, Py_TPFLAGS_HAVE_VERSION_TAG)) - return; - - n = PyTuple_GET_SIZE(bases); - for (i = 0; i < n; i++) { - PyObject *b = PyTuple_GET_ITEM(bases, i); - PyTypeObject *cls; - - if (!PyType_Check(b) ) { - clear = 1; - break; - } - - cls = (PyTypeObject *)b; - - if (!PyType_HasFeature(cls, Py_TPFLAGS_HAVE_VERSION_TAG) || - !PyType_IsSubtype(type, cls)) { - clear = 1; - break; - } - } - - if (clear) - type->tp_flags &= ~(Py_TPFLAGS_HAVE_VERSION_TAG| - Py_TPFLAGS_VALID_VERSION_TAG); -} - -static int -assign_version_tag(PyTypeObject *type) -{ - /* Ensure that the tp_version_tag is valid and set - Py_TPFLAGS_VALID_VERSION_TAG. To respect the invariant, this - must first be done on all super classes. Return 0 if this - cannot be done, 1 if Py_TPFLAGS_VALID_VERSION_TAG. - */ - Py_ssize_t i, n; - PyObject *bases; - - if (PyType_HasFeature(type, Py_TPFLAGS_VALID_VERSION_TAG)) - return 1; - if (!PyType_HasFeature(type, Py_TPFLAGS_HAVE_VERSION_TAG)) - return 0; - if (!PyType_HasFeature(type, Py_TPFLAGS_READY)) - return 0; - - type->tp_version_tag = next_version_tag++; - /* for stress-testing: next_version_tag &= 0xFF; */ - - if (type->tp_version_tag == 0) { - /* wrap-around or just starting Python - clear the whole - cache by filling names with references to Py_None. - Values are also set to NULL for added protection, as they - are borrowed reference */ - for (i = 0; i < (1 << MCACHE_SIZE_EXP); i++) { - method_cache[i].value = NULL; - Py_XDECREF(method_cache[i].name); - method_cache[i].name = Py_None; - Py_INCREF(Py_None); - } - /* mark all version tags as invalid */ - type_modified(&PyBaseObject_Type); - return 1; - } - bases = type->tp_bases; - n = PyTuple_GET_SIZE(bases); - for (i = 0; i < n; i++) { - PyObject *b = PyTuple_GET_ITEM(bases, i); - assert(PyType_Check(b)); - if (!assign_version_tag((PyTypeObject *)b)) - return 0; - } - type->tp_flags |= Py_TPFLAGS_VALID_VERSION_TAG; - return 1; -} - - static PyMemberDef type_members[] = { {"__basicsize__", T_INT, offsetof(PyTypeObject,tp_basicsize),READONLY}, {"__itemsize__", T_INT, offsetof(PyTypeObject, tp_itemsize), READONLY}, @@ -282,8 +117,6 @@ return -1; } - type_modified(type); - return PyDict_SetItemString(type->tp_dict, "__module__", value); } @@ -1518,14 +1351,6 @@ } } type->tp_mro = tuple; - - type_mro_modified(type, type->tp_mro); - /* corner case: the old-style super class might have been hidden - from the custom MRO */ - type_mro_modified(type, type->tp_bases); - - type_modified(type); - return 0; } @@ -2318,16 +2143,6 @@ { Py_ssize_t i, n; PyObject *mro, *res, *base, *dict; - unsigned int h; - - if (MCACHE_CACHEABLE_NAME(name) && - PyType_HasFeature(type,Py_TPFLAGS_VALID_VERSION_TAG)) { - /* fast path */ - h = MCACHE_HASH_METHOD(type, name); - if (method_cache[h].version == type->tp_version_tag && - method_cache[h].name == name) - return method_cache[h].value; - } /* Look in tp_dict of types in MRO */ mro = type->tp_mro; @@ -2338,7 +2153,6 @@ if (mro == NULL) return NULL; - res = NULL; assert(PyTuple_Check(mro)); n = PyTuple_GET_SIZE(mro); for (i = 0; i < n; i++) { @@ -2352,18 +2166,9 @@ assert(dict && PyDict_Check(dict)); res = PyDict_GetItem(dict, name); if (res != NULL) - break; - } - - if (MCACHE_CACHEABLE_NAME(name) && assign_version_tag(type)) { - h = MCACHE_HASH_METHOD(type, name); - method_cache[h].version = type->tp_version_tag; - method_cache[h].value = res; /* borrowed */ - Py_INCREF(name); - Py_DECREF(method_cache[h].name); - method_cache[h].name = name; + return res; } - return res; + return NULL; } /* This is similar to PyObject_GenericGetAttr(), @@ -2453,6 +2258,10 @@ type->tp_name); return -1; } + /* XXX Example of how I expect this to be used... + if (update_subclasses(type, name, invalidate_cache, NULL) < 0) + return -1; + */ if (PyObject_GenericSetAttr((PyObject *)type, name, value) < 0) return -1; return update_slot(type, name); @@ -5875,13 +5684,6 @@ slotdef **pp; int offset; - /* Clear the VALID_VERSION flag of 'type' and all its - subclasses. This could possibly be unified with the - update_subclasses() recursion below, but carefully: - they each have their own conditions on which to stop - recursing into subclasses. */ - type_modified(type); - init_slotdefs(); pp = ptrs; for (p = slotdefs; p->name; p++) { From python-checkins at python.org Mon Jan 14 01:22:44 2008 From: python-checkins at python.org (amaury.forgeotdarc) Date: Mon, 14 Jan 2008 01:22:44 +0100 (CET) Subject: [Python-checkins] r59943 - python/trunk/Modules/_ctypes/_ctypes.c python/trunk/Modules/_ctypes/stgdict.c Message-ID: <20080114002244.D016E1E4016@bag.python.org> Author: amaury.forgeotdarc Date: Mon Jan 14 01:22:44 2008 New Revision: 59943 Modified: python/trunk/Modules/_ctypes/_ctypes.c python/trunk/Modules/_ctypes/stgdict.c Log: As discussed in issue 1700288: ctypes takes some liberties when creating python types: it modifies the types' __dict__ directly, bypassing all the machinery of type objects which deal with special methods. And this broke recent optimisations of method lookup. Now we try to modify the type with more "official" functions. Modified: python/trunk/Modules/_ctypes/_ctypes.c ============================================================================== --- python/trunk/Modules/_ctypes/_ctypes.c (original) +++ python/trunk/Modules/_ctypes/_ctypes.c Mon Jan 14 01:22:44 2008 @@ -410,7 +410,7 @@ StructType_setattro(PyObject *self, PyObject *key, PyObject *value) { /* XXX Should we disallow deleting _fields_? */ - if (-1 == PyObject_GenericSetAttr(self, key, value)) + if (-1 == Py_TYPE(self)->tp_base->tp_setattro(self, key, value)) return -1; if (value && PyString_Check(key) && Modified: python/trunk/Modules/_ctypes/stgdict.c ============================================================================== --- python/trunk/Modules/_ctypes/stgdict.c (original) +++ python/trunk/Modules/_ctypes/stgdict.c Mon Jan 14 01:22:44 2008 @@ -470,7 +470,7 @@ Py_DECREF(pair); return -1; } - if (-1 == PyDict_SetItem(realdict, name, prop)) { + if (-1 == PyObject_SetAttr(type, name, prop)) { Py_DECREF(prop); Py_DECREF(pair); return -1; From python-checkins at python.org Mon Jan 14 01:29:41 2008 From: python-checkins at python.org (amaury.forgeotdarc) Date: Mon, 14 Jan 2008 01:29:41 +0100 (CET) Subject: [Python-checkins] r59944 - in python/trunk: Include/object.h Misc/NEWS Objects/object.c Objects/typeobject.c Message-ID: <20080114002941.D0B481E4016@bag.python.org> Author: amaury.forgeotdarc Date: Mon Jan 14 01:29:41 2008 New Revision: 59944 Modified: python/trunk/Include/object.h python/trunk/Misc/NEWS python/trunk/Objects/object.c python/trunk/Objects/typeobject.c Log: Re-apply patch #1700288 (first applied in r59931, rolled back in r59940) now that ctypes uses a more supported method to create types: Method cache optimization, by Armin Rigo, ported to 2.6 by Kevin Jacobs. Modified: python/trunk/Include/object.h ============================================================================== --- python/trunk/Include/object.h (original) +++ python/trunk/Include/object.h Mon Jan 14 01:29:41 2008 @@ -345,6 +345,9 @@ PyObject *tp_weaklist; destructor tp_del; + /* Type attribute cache version tag. Added in version 2.6 */ + unsigned int tp_version_tag; + #ifdef COUNT_ALLOCS /* these must be last and never explicitly initialized */ Py_ssize_t tp_allocs; @@ -529,6 +532,10 @@ /* Objects support nb_index in PyNumberMethods */ #define Py_TPFLAGS_HAVE_INDEX (1L<<17) +/* Objects support type attribute cache */ +#define Py_TPFLAGS_HAVE_VERSION_TAG (1L<<18) +#define Py_TPFLAGS_VALID_VERSION_TAG (1L<<19) + /* These flags are used to determine if a type is a subclass. */ #define Py_TPFLAGS_INT_SUBCLASS (1L<<23) #define Py_TPFLAGS_LONG_SUBCLASS (1L<<24) @@ -550,6 +557,7 @@ Py_TPFLAGS_HAVE_CLASS | \ Py_TPFLAGS_HAVE_STACKLESS_EXTENSION | \ Py_TPFLAGS_HAVE_INDEX | \ + Py_TPFLAGS_HAVE_VERSION_TAG | \ 0) #define PyType_HasFeature(t,f) (((t)->tp_flags & (f)) != 0) Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Mon Jan 14 01:29:41 2008 @@ -12,6 +12,9 @@ Core and builtins ----------------- +- Patch #1700288: added a type attribute cache that caches method accesses, + resulting in speedups in heavily object-oriented code. + - Bug #1776: __import__() no longer accepts filenames on any platform. The first parameter to __import__() must be a valid module name. Modified: python/trunk/Objects/object.c ============================================================================== --- python/trunk/Objects/object.c (original) +++ python/trunk/Objects/object.c Mon Jan 14 01:29:41 2008 @@ -1287,6 +1287,7 @@ goto done; } +#if 0 /* XXX this is not quite _PyType_Lookup anymore */ /* Inline _PyType_Lookup */ { Py_ssize_t i, n; @@ -1311,6 +1312,9 @@ break; } } +#else + descr = _PyType_Lookup(tp, name); +#endif Py_XINCREF(descr); Modified: python/trunk/Objects/typeobject.c ============================================================================== --- python/trunk/Objects/typeobject.c (original) +++ python/trunk/Objects/typeobject.c Mon Jan 14 01:29:41 2008 @@ -5,6 +5,171 @@ #include + +/* Support type attribute cache */ + +/* The cache can keep references to the names alive for longer than + they normally would. This is why the maximum size is limited to + MCACHE_MAX_ATTR_SIZE, since it might be a problem if very large + strings are used as attribute names. */ +#define MCACHE_MAX_ATTR_SIZE 100 +#define MCACHE_SIZE_EXP 10 +#define MCACHE_HASH(version, name_hash) \ + (((unsigned int)(version) * (unsigned int)(name_hash)) \ + >> (8*sizeof(unsigned int) - MCACHE_SIZE_EXP)) +#define MCACHE_HASH_METHOD(type, name) \ + MCACHE_HASH((type)->tp_version_tag, \ + ((PyStringObject *)(name))->ob_shash) +#define MCACHE_CACHEABLE_NAME(name) \ + PyString_CheckExact(name) && \ + PyString_GET_SIZE(name) <= MCACHE_MAX_ATTR_SIZE + +struct method_cache_entry { + unsigned int version; + PyObject *name; /* reference to exactly a str or None */ + PyObject *value; /* borrowed */ +}; + +static struct method_cache_entry method_cache[1 << MCACHE_SIZE_EXP]; +static unsigned int next_version_tag = 0; + +static void +type_modified(PyTypeObject *type) +{ + /* Invalidate any cached data for the specified type and all + subclasses. This function is called after the base + classes, mro, or attributes of the type are altered. + + Invariants: + + - Py_TPFLAGS_VALID_VERSION_TAG is never set if + Py_TPFLAGS_HAVE_VERSION_TAG is not set (e.g. on type + objects coming from non-recompiled extension modules) + + - before Py_TPFLAGS_VALID_VERSION_TAG can be set on a type, + it must first be set on all super types. + + This function clears the Py_TPFLAGS_VALID_VERSION_TAG of a + type (so it must first clear it on all subclasses). The + tp_version_tag value is meaningless unless this flag is set. + We don't assign new version tags eagerly, but only as + needed. + */ + PyObject *raw, *ref; + Py_ssize_t i, n; + + if(!PyType_HasFeature(type, Py_TPFLAGS_VALID_VERSION_TAG)) + return; + + raw = type->tp_subclasses; + if (raw != NULL) { + n = PyList_GET_SIZE(raw); + for (i = 0; i < n; i++) { + ref = PyList_GET_ITEM(raw, i); + ref = PyWeakref_GET_OBJECT(ref); + if (ref != Py_None) { + type_modified((PyTypeObject *)ref); + } + } + } + type->tp_flags &= ~Py_TPFLAGS_VALID_VERSION_TAG; +} + +static void +type_mro_modified(PyTypeObject *type, PyObject *bases) { + /* + Check that all base classes or elements of the mro of type are + able to be cached. This function is called after the base + classes or mro of the type are altered. + + Unset HAVE_VERSION_TAG and VALID_VERSION_TAG if the type + inherits from an old-style class, either directly or if it + appears in the MRO of a new-style class. No support either for + custom MROs that include types that are not officially super + types. + + Called from mro_internal, which will subsequently be called on + each subclass when their mro is recursively updated. + */ + Py_ssize_t i, n; + int clear = 0; + + if(!PyType_HasFeature(type, Py_TPFLAGS_HAVE_VERSION_TAG)) + return; + + n = PyTuple_GET_SIZE(bases); + for (i = 0; i < n; i++) { + PyObject *b = PyTuple_GET_ITEM(bases, i); + PyTypeObject *cls; + + if (!PyType_Check(b) ) { + clear = 1; + break; + } + + cls = (PyTypeObject *)b; + + if (!PyType_HasFeature(cls, Py_TPFLAGS_HAVE_VERSION_TAG) || + !PyType_IsSubtype(type, cls)) { + clear = 1; + break; + } + } + + if (clear) + type->tp_flags &= ~(Py_TPFLAGS_HAVE_VERSION_TAG| + Py_TPFLAGS_VALID_VERSION_TAG); +} + +static int +assign_version_tag(PyTypeObject *type) +{ + /* Ensure that the tp_version_tag is valid and set + Py_TPFLAGS_VALID_VERSION_TAG. To respect the invariant, this + must first be done on all super classes. Return 0 if this + cannot be done, 1 if Py_TPFLAGS_VALID_VERSION_TAG. + */ + Py_ssize_t i, n; + PyObject *bases; + + if (PyType_HasFeature(type, Py_TPFLAGS_VALID_VERSION_TAG)) + return 1; + if (!PyType_HasFeature(type, Py_TPFLAGS_HAVE_VERSION_TAG)) + return 0; + if (!PyType_HasFeature(type, Py_TPFLAGS_READY)) + return 0; + + type->tp_version_tag = next_version_tag++; + /* for stress-testing: next_version_tag &= 0xFF; */ + + if (type->tp_version_tag == 0) { + /* wrap-around or just starting Python - clear the whole + cache by filling names with references to Py_None. + Values are also set to NULL for added protection, as they + are borrowed reference */ + for (i = 0; i < (1 << MCACHE_SIZE_EXP); i++) { + method_cache[i].value = NULL; + Py_XDECREF(method_cache[i].name); + method_cache[i].name = Py_None; + Py_INCREF(Py_None); + } + /* mark all version tags as invalid */ + type_modified(&PyBaseObject_Type); + return 1; + } + bases = type->tp_bases; + n = PyTuple_GET_SIZE(bases); + for (i = 0; i < n; i++) { + PyObject *b = PyTuple_GET_ITEM(bases, i); + assert(PyType_Check(b)); + if (!assign_version_tag((PyTypeObject *)b)) + return 0; + } + type->tp_flags |= Py_TPFLAGS_VALID_VERSION_TAG; + return 1; +} + + static PyMemberDef type_members[] = { {"__basicsize__", T_INT, offsetof(PyTypeObject,tp_basicsize),READONLY}, {"__itemsize__", T_INT, offsetof(PyTypeObject, tp_itemsize), READONLY}, @@ -117,6 +282,8 @@ return -1; } + type_modified(type); + return PyDict_SetItemString(type->tp_dict, "__module__", value); } @@ -1351,6 +1518,14 @@ } } type->tp_mro = tuple; + + type_mro_modified(type, type->tp_mro); + /* corner case: the old-style super class might have been hidden + from the custom MRO */ + type_mro_modified(type, type->tp_bases); + + type_modified(type); + return 0; } @@ -2143,6 +2318,16 @@ { Py_ssize_t i, n; PyObject *mro, *res, *base, *dict; + unsigned int h; + + if (MCACHE_CACHEABLE_NAME(name) && + PyType_HasFeature(type,Py_TPFLAGS_VALID_VERSION_TAG)) { + /* fast path */ + h = MCACHE_HASH_METHOD(type, name); + if (method_cache[h].version == type->tp_version_tag && + method_cache[h].name == name) + return method_cache[h].value; + } /* Look in tp_dict of types in MRO */ mro = type->tp_mro; @@ -2153,6 +2338,7 @@ if (mro == NULL) return NULL; + res = NULL; assert(PyTuple_Check(mro)); n = PyTuple_GET_SIZE(mro); for (i = 0; i < n; i++) { @@ -2166,9 +2352,18 @@ assert(dict && PyDict_Check(dict)); res = PyDict_GetItem(dict, name); if (res != NULL) - return res; + break; } - return NULL; + + if (MCACHE_CACHEABLE_NAME(name) && assign_version_tag(type)) { + h = MCACHE_HASH_METHOD(type, name); + method_cache[h].version = type->tp_version_tag; + method_cache[h].value = res; /* borrowed */ + Py_INCREF(name); + Py_DECREF(method_cache[h].name); + method_cache[h].name = name; + } + return res; } /* This is similar to PyObject_GenericGetAttr(), @@ -2258,10 +2453,6 @@ type->tp_name); return -1; } - /* XXX Example of how I expect this to be used... - if (update_subclasses(type, name, invalidate_cache, NULL) < 0) - return -1; - */ if (PyObject_GenericSetAttr((PyObject *)type, name, value) < 0) return -1; return update_slot(type, name); @@ -5684,6 +5875,13 @@ slotdef **pp; int offset; + /* Clear the VALID_VERSION flag of 'type' and all its + subclasses. This could possibly be unified with the + update_subclasses() recursion below, but carefully: + they each have their own conditions on which to stop + recursing into subclasses. */ + type_modified(type); + init_slotdefs(); pp = ptrs; for (p = slotdefs; p->name; p++) { From buildbot at python.org Mon Jan 14 01:31:18 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 14 Jan 2008 00:31:18 +0000 Subject: [Python-checkins] buildbot failure in sparc solaris10 gcc trunk Message-ID: <20080114003118.27DBA1E4016@bag.python.org> The Buildbot has detected a new failure of sparc solaris10 gcc trunk. Full details are available at: http://www.python.org/dev/buildbot/all/sparc%20solaris10%20gcc%20trunk/builds/2603 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-sun Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: amaury.forgeotdarc BUILD FAILED: failed test Excerpt from the test logfile: sincerely, -The Buildbot From buildbot at python.org Mon Jan 14 01:32:57 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 14 Jan 2008 00:32:57 +0000 Subject: [Python-checkins] buildbot failure in x86 gentoo trunk Message-ID: <20080114003257.C106D1E4016@bag.python.org> The Buildbot has detected a new failure of x86 gentoo trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20gentoo%20trunk/builds/2880 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-x86 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: amaury.forgeotdarc BUILD FAILED: failed test Excerpt from the test logfile: make: *** [buildbottest] Segmentation fault sincerely, -The Buildbot From buildbot at python.org Mon Jan 14 01:33:07 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 14 Jan 2008 00:33:07 +0000 Subject: [Python-checkins] buildbot failure in x86 mvlgcc trunk Message-ID: <20080114003307.39FEA1E4016@bag.python.org> The Buildbot has detected a new failure of x86 mvlgcc trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20mvlgcc%20trunk/builds/1196 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-linux Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: amaury.forgeotdarc BUILD FAILED: failed test Excerpt from the test logfile: make: *** [buildbottest] Speicherzugriffsfehler sincerely, -The Buildbot From buildbot at python.org Mon Jan 14 01:33:10 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 14 Jan 2008 00:33:10 +0000 Subject: [Python-checkins] buildbot failure in x86 XP-3 trunk Message-ID: <20080114003310.BBB3D1E4029@bag.python.org> The Buildbot has detected a new failure of x86 XP-3 trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20XP-3%20trunk/builds/648 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: heller-windows Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: amaury.forgeotdarc BUILD FAILED: failed test Excerpt from the test logfile: sincerely, -The Buildbot From python-checkins at python.org Mon Jan 14 02:07:27 2008 From: python-checkins at python.org (amaury.forgeotdarc) Date: Mon, 14 Jan 2008 02:07:27 +0100 (CET) Subject: [Python-checkins] r59946 - python/trunk/Modules/_ctypes/_ctypes.c Message-ID: <20080114010727.A64291E4016@bag.python.org> Author: amaury.forgeotdarc Date: Mon Jan 14 02:07:27 2008 New Revision: 59946 Modified: python/trunk/Modules/_ctypes/_ctypes.c Log: ?Why did my tests not notice this before? Slots inheritance is very different from OO inheritance. This code lead to infinite recursion on classes derived from StructType. Modified: python/trunk/Modules/_ctypes/_ctypes.c ============================================================================== --- python/trunk/Modules/_ctypes/_ctypes.c (original) +++ python/trunk/Modules/_ctypes/_ctypes.c Mon Jan 14 02:07:27 2008 @@ -410,7 +410,7 @@ StructType_setattro(PyObject *self, PyObject *key, PyObject *value) { /* XXX Should we disallow deleting _fields_? */ - if (-1 == Py_TYPE(self)->tp_base->tp_setattro(self, key, value)) + if (-1 == PyType_Type.tp_setattro(self, key, value)) return -1; if (value && PyString_Check(key) && From buildbot at python.org Mon Jan 14 02:21:50 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 14 Jan 2008 01:21:50 +0000 Subject: [Python-checkins] buildbot failure in x86 FreeBSD trunk Message-ID: <20080114012150.D5C5F1E4016@bag.python.org> The Buildbot has detected a new failure of x86 FreeBSD trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20FreeBSD%20trunk/builds/391 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-freebsd Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: amaury.forgeotdarc BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30995, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30995, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/bsddb/test/test_thread.py", line 245, in writerThread self.assertEqual(data, self.makeData(key)) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/unittest.py", line 343, in failUnlessEqual (msg or '%r != %r' % (first, second)) AssertionError: None != '0147-0147-0147-0147-0147' Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/bsddb/test/test_thread.py", line 260, in writerThread self.assertEqual(data, self.makeData(key)) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/unittest.py", line 343, in failUnlessEqual (msg or '%r != %r' % (first, second)) AssertionError: None != '1000-1000-1000-1000-1000' Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/bsddb/test/test_thread.py", line 260, in writerThread self.assertEqual(data, self.makeData(key)) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/unittest.py", line 343, in failUnlessEqual (msg or '%r != %r' % (first, second)) AssertionError: None != '2000-2000-2000-2000-2000' Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 523, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable sincerely, -The Buildbot From buildbot at python.org Mon Jan 14 02:32:10 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 14 Jan 2008 01:32:10 +0000 Subject: [Python-checkins] buildbot failure in g4 osx.4 trunk Message-ID: <20080114013210.3A6071E401A@bag.python.org> The Buildbot has detected a new failure of g4 osx.4 trunk. Full details are available at: http://www.python.org/dev/buildbot/all/g4%20osx.4%20trunk/builds/2603 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: psf-g4 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: amaury.forgeotdarc BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30995, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30995, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30995, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30995, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') make: *** [buildbottest] Segmentation fault sincerely, -The Buildbot From buildbot at python.org Mon Jan 14 02:36:57 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 14 Jan 2008 01:36:57 +0000 Subject: [Python-checkins] buildbot failure in ia64 Ubuntu trunk Message-ID: <20080114013657.36CC41E401A@bag.python.org> The Buildbot has detected a new failure of ia64 Ubuntu trunk. Full details are available at: http://www.python.org/dev/buildbot/all/ia64%20Ubuntu%20trunk/builds/1275 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ia64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: amaury.forgeotdarc BUILD FAILED: failed test Excerpt from the test logfile: make: *** [buildbottest] Killed sincerely, -The Buildbot From python-checkins at python.org Mon Jan 14 04:33:53 2008 From: python-checkins at python.org (christian.heimes) Date: Mon, 14 Jan 2008 04:33:53 +0100 (CET) Subject: [Python-checkins] r59947 - in python/trunk: Lib/test/test_structseq.py Misc/NEWS Message-ID: <20080114033353.2B9241E401A@bag.python.org> Author: christian.heimes Date: Mon Jan 14 04:33:52 2008 New Revision: 59947 Modified: python/trunk/Lib/test/test_structseq.py python/trunk/Misc/NEWS Log: Added new an better structseq representation. E.g. repr(time.gmtime(0)) now returns 'time.struct_time(tm_year=1970, tm_mon=1, tm_mday=1, tm_hour=0, tm_min=0, tm_sec=0, tm_wday=3, tm_yday=1, tm_isdst=0)' instead of '(1970, 1, 1, 0, 0, 0, 3, 1, 0)'. The feature is part of #1816: sys.flags Modified: python/trunk/Lib/test/test_structseq.py ============================================================================== --- python/trunk/Lib/test/test_structseq.py (original) +++ python/trunk/Lib/test/test_structseq.py Mon Jan 14 04:33:52 2008 @@ -28,7 +28,11 @@ def test_repr(self): t = time.gmtime() - repr(t) + self.assert_(repr(t)) + t = time.gmtime(0) + self.assertEqual(repr(t), + "time.struct_time(tm_year=1970, tm_mon=1, tm_mday=1, tm_hour=0, " + "tm_min=0, tm_sec=0, tm_wday=3, tm_yday=1, tm_isdst=0)") def test_concat(self): t1 = time.gmtime() Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Mon Jan 14 04:33:52 2008 @@ -12,6 +12,9 @@ Core and builtins ----------------- +- Object/structseq.c: Implemented new structseq representation. structseqs + like the return value of os.stat are more readable. + - Patch #1700288: added a type attribute cache that caches method accesses, resulting in speedups in heavily object-oriented code. From python-checkins at python.org Mon Jan 14 04:35:38 2008 From: python-checkins at python.org (christian.heimes) Date: Mon, 14 Jan 2008 04:35:38 +0100 (CET) Subject: [Python-checkins] r59948 - python/trunk/Objects/structseq.c Message-ID: <20080114033539.001AB1E401A@bag.python.org> Author: christian.heimes Date: Mon Jan 14 04:35:38 2008 New Revision: 59948 Modified: python/trunk/Objects/structseq.c Log: I missed the most important file Modified: python/trunk/Objects/structseq.c ============================================================================== --- python/trunk/Objects/structseq.c (original) +++ python/trunk/Objects/structseq.c Mon Jan 14 04:35:38 2008 @@ -30,7 +30,7 @@ PyStructSequence_New(PyTypeObject *type) { PyStructSequence *obj; - + obj = PyObject_New(PyStructSequence, type); Py_SIZE(obj) = VISIBLE_SIZE_TP(type); @@ -230,11 +230,64 @@ static PyObject * structseq_repr(PyStructSequence *obj) { - PyObject *tup, *str; - tup = make_tuple(obj); - str = PyObject_Repr(tup); + PyObject *tup, *val, *repr; + PyTypeObject *typ = Py_TYPE(obj); + int i, len; + char buf[250+5]; /* "...)\0" */ + char *cname, *crepr; + char *pbuf = buf; + char *endbuf = &buf[250]; + + strncpy(pbuf, typ->tp_name, 50); + pbuf += strlen(typ->tp_name) > 50 ? 50 : strlen(typ->tp_name); + *pbuf++ = '('; + + if ((tup = make_tuple(obj)) == NULL) { + return NULL; + } + for (i=0; i < VISIBLE_SIZE(obj); i++) { + cname = typ->tp_members[i].name; + val = PyTuple_GetItem(tup, i); + if (cname == NULL || val == NULL) { + return NULL; + } + repr = PyObject_Repr(val); + if (repr == NULL) { + Py_DECREF(tup); + return NULL; + } + crepr = PyString_AsString(repr); + if (crepr == NULL) { + Py_DECREF(tup); + Py_DECREF(repr); + return NULL; + } + len = strlen(cname) + strlen(crepr) + 3; + if ((pbuf+len) < endbuf) { + strcpy(pbuf, cname); + pbuf += strlen(cname); + *pbuf++ = '='; + strcpy(pbuf, crepr); + pbuf += strlen(crepr); + *pbuf++ = ','; + *pbuf++ = ' '; + Py_DECREF(repr); + } + else { + strcpy(pbuf, "..."); + pbuf += 5; + Py_DECREF(repr); + break; + } + } Py_DECREF(tup); - return str; + + pbuf-=2; + *pbuf++ = ')'; + *pbuf = '\0'; + + repr = PyString_FromString(buf); + return repr; } static PyObject * From python-checkins at python.org Mon Jan 14 04:42:48 2008 From: python-checkins at python.org (christian.heimes) Date: Mon, 14 Jan 2008 04:42:48 +0100 (CET) Subject: [Python-checkins] r59949 - in python/trunk: Doc/library/sys.rst Lib/test/test_sys.py Misc/NEWS Python/sysmodule.c Message-ID: <20080114034248.F04111E4025@bag.python.org> Author: christian.heimes Date: Mon Jan 14 04:42:48 2008 New Revision: 59949 Modified: python/trunk/Doc/library/sys.rst python/trunk/Lib/test/test_sys.py python/trunk/Misc/NEWS python/trunk/Python/sysmodule.c Log: Applied patch #1816: sys.flags patch Modified: python/trunk/Doc/library/sys.rst ============================================================================== --- python/trunk/Doc/library/sys.rst (original) +++ python/trunk/Doc/library/sys.rst Mon Jan 14 04:42:48 2008 @@ -240,6 +240,44 @@ Use :mod:`atexit` instead. +.. data:: flags + + The struct sequence *flags* exposes the status of command line flags. The + attributes are read only. + + +------------------------------+------------------------------------------+ + | attribute | flag | + +==============================+==========================================+ + | :const:`debug` | -d | + +------------------------------+------------------------------------------+ + | :const:`py3k_warning` | -3 | + +------------------------------+------------------------------------------+ + | :const:`division_warning` | -Q | + +------------------------------+------------------------------------------+ + | :const:`division_new` | -Qnew | + +------------------------------+------------------------------------------+ + | :const:`inspect` | -i | + +------------------------------+------------------------------------------+ + | :const:`interactive` | -i | + +------------------------------+------------------------------------------+ + | :const:`optimize` | -O or -OO | + +------------------------------+------------------------------------------+ + | :const:`dont_write_bytecode` | -B | + +------------------------------+------------------------------------------+ + | :const:`no_site` | -S | + +------------------------------+------------------------------------------+ + | :const:`ingnore_environment` | -E | + +------------------------------+------------------------------------------+ + | :const:`tabcheck` | -t or -tt | + +------------------------------+------------------------------------------+ + | :const:`verbose` | -v | + +------------------------------+------------------------------------------+ + | :const:`unicode` | -U | + +------------------------------+------------------------------------------+ + + .. versionadded:: 2.6 + + .. data:: float_info A dict holding information about the float type. It contains low level Modified: python/trunk/Lib/test/test_sys.py ============================================================================== --- python/trunk/Lib/test/test_sys.py (original) +++ python/trunk/Lib/test/test_sys.py Mon Jan 14 04:42:48 2008 @@ -352,6 +352,18 @@ # the test runs under regrtest. self.assert_(sys.__stdout__.encoding == sys.__stderr__.encoding) + def test_sys_flags(self): + self.failUnless(sys.flags) + attrs = ("debug", "py3k_warning", "division_warning", "division_new", + "inspect", "interactive", "optimize", "dont_write_bytecode", + "no_site", "ingnore_environment", "tabcheck", "verbose", + "unicode") + for attr in attrs: + self.assert_(hasattr(sys.flags, attr), attr) + self.assertEqual(type(getattr(sys.flags, attr)), int, attr) + self.assert_(repr(sys.flags)) + + def test_main(): test.test_support.run_unittest(SysModuleTest) Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Mon Jan 14 04:42:48 2008 @@ -12,8 +12,11 @@ Core and builtins ----------------- -- Object/structseq.c: Implemented new structseq representation. structseqs - like the return value of os.stat are more readable. +- Patch #1816: Added sys.flags structseq. It exposes the status of most + command line arguments and PYTHON* environment variables. + +- Object/structseq.c: Implemented new structseq representation. The patch + makes structseqs (e.g. the return value of os.stat) more readable. - Patch #1700288: added a type attribute cache that caches method accesses, resulting in speedups in heavily object-oriented code. Modified: python/trunk/Python/sysmodule.c ============================================================================== --- python/trunk/Python/sysmodule.c (original) +++ python/trunk/Python/sysmodule.c Mon Jan 14 04:42:48 2008 @@ -15,6 +15,7 @@ */ #include "Python.h" +#include "structseq.h" #include "code.h" #include "frameobject.h" #include "eval.h" @@ -1045,6 +1046,90 @@ return shortbranch; } + +PyDoc_STRVAR(flags__doc__, +"sys.flags\n\ +\n\ +Flags provided through command line arguments or environment vars."); + +static PyTypeObject FlagsType; + +static PyStructSequence_Field flags_fields[] = { + {"debug", "-d"}, + {"py3k_warning", "-3"}, + {"division_warning", "-Q"}, + {"division_new", "-Qnew"}, + {"inspect", "-i"}, + {"interactive", "-i"}, + {"optimize", "-O or -OO"}, + {"dont_write_bytecode", "-B"}, + /* {"no_user_site", "-s"}, */ + {"no_site", "-S"}, + {"ingnore_environment", "-E"}, + {"tabcheck", "-t or -tt"}, + {"verbose", "-v"}, +#ifdef RISCOS + {"ricos_wimp", "???"}, +#endif + /* {"unbuffered", "-u"}, */ + {"unicode", "-U"}, + /* {"skip_first", "-x"}, */ + {0} +}; + +static PyStructSequence_Desc flags_desc = { + "sys.flags", /* name */ + flags__doc__, /* doc */ + flags_fields, /* fields */ +#ifdef RISCOS + 14 +#else + 13 +#endif +}; + +static PyObject* +make_flags(void) +{ + int pos = 0; + PyObject *seq; + + seq = PyStructSequence_New(&FlagsType); + if (seq == NULL) + return NULL; + +#define SetFlag(flag) \ + PyStructSequence_SET_ITEM(seq, pos++, PyInt_FromLong(flag)) + + SetFlag(Py_DebugFlag); + SetFlag(Py_Py3kWarningFlag); + SetFlag(Py_DivisionWarningFlag); + SetFlag(_Py_QnewFlag); + SetFlag(Py_InspectFlag); + SetFlag(Py_InteractiveFlag); + SetFlag(Py_OptimizeFlag); + SetFlag(Py_DontWriteBytecodeFlag); + /* SetFlag(Py_NoUserSiteDirectory); */ + SetFlag(Py_NoSiteFlag); + SetFlag(Py_IgnoreEnvironmentFlag); + SetFlag(Py_TabcheckFlag); + SetFlag(Py_VerboseFlag); +#ifdef RISCOS + SetFlag(Py_RISCOSWimpFlag); +#endif + /* SetFlag(saw_unbuffered_flag); */ + SetFlag(Py_UnicodeFlag); + /* SetFlag(skipfirstline); */ +#undef SetFlag + + if (PyErr_Occurred()) { + return NULL; + } + + Py_INCREF(seq); + return seq; +} + PyObject * _PySys_Init(void) { @@ -1128,9 +1213,9 @@ v = Py_BuildValue("(ssz)", "CPython", branch, svn_revision); PyDict_SetItemString(sysdict, "subversion", v); Py_XDECREF(v); - PyDict_SetItemString(sysdict, "dont_write_bytecode", - v = PyBool_FromLong(Py_DontWriteBytecodeFlag)); - Py_XDECREF(v); + PyDict_SetItemString(sysdict, "dont_write_bytecode", + v = PyBool_FromLong(Py_DontWriteBytecodeFlag)); + Py_XDECREF(v); /* * These release level checks are mutually exclusive and cover * the field, so don't get too fancy with the pre-processor! @@ -1211,6 +1296,12 @@ PyDict_SetItemString(sysdict, "warnoptions", warnoptions); } + PyStructSequence_InitType(&FlagsType, &flags_desc); + PyDict_SetItemString(sysdict, "flags", make_flags()); + /* prevent user from creating new instances */ + FlagsType.tp_init = NULL; + FlagsType.tp_new = NULL; + if (PyErr_Occurred()) return NULL; return m; From python at rcn.com Mon Jan 14 04:53:57 2008 From: python at rcn.com (Raymond Hettinger) Date: Sun, 13 Jan 2008 19:53:57 -0800 Subject: [Python-checkins] r59947 - in python/trunk:Lib/test/test_structseq.py Misc/NEWS References: <20080114033353.2B9241E401A@bag.python.org> Message-ID: <001201c85661$181a4390$6800a8c0@RaymondLaptop1> [Christian Heimes] > Log: > Added new an better structseq representation. E.g. repr(time.gmtime(0)) now returns 'time.struct_time(tm_year=1970, tm_mon=1, > tm_mday=1, tm_hour=0, tm_min=0, tm_sec=0, tm_wday=3, tm_yday=1, tm_isdst=0)' instead of '(1970, 1, 1, 0, 0, 0, 3, 1, 0)'. The > feature is part of #1816: sys.flags FWIW, I was looking into something similar but didn't proceed because it would break eval(repr(s)) == s as the constructor signature wants all the args in a tuple and won't accept keywords. Still, I think what you did is a nice improvement. Here's a couple more if you want to proceed down that path: 1. Have structseq subclass from PyTupleObject so that isinstance(s, tuple) returns True. This makes the object usable whenever tuples are needed. 2. Add _fields, _asdict, and _replace to match the API in collections.namedtuple(). The _fields tuple should only include the visible positional fields while _asdict() and _replace() should include all of the fields whether visible or accessible only by attribute access. Thanks for the nice work. Raymond From python-checkins at python.org Mon Jan 14 05:13:38 2008 From: python-checkins at python.org (christian.heimes) Date: Mon, 14 Jan 2008 05:13:38 +0100 (CET) Subject: [Python-checkins] r59950 - in python/trunk: Doc/c-api/concrete.rst Doc/library/sys.rst Lib/test/test_sys.py Misc/NEWS Objects/floatobject.c Message-ID: <20080114041338.16AC61E401A@bag.python.org> Author: christian.heimes Date: Mon Jan 14 05:13:37 2008 New Revision: 59950 Modified: python/trunk/Doc/c-api/concrete.rst python/trunk/Doc/library/sys.rst python/trunk/Lib/test/test_sys.py python/trunk/Misc/NEWS python/trunk/Objects/floatobject.c Log: Now that I've learnt about structseq objects I felt like converting sys.float_info to a structseq. It's readonly and help(sys.float_info) explains the attributes nicely. Modified: python/trunk/Doc/c-api/concrete.rst ============================================================================== --- python/trunk/Doc/c-api/concrete.rst (original) +++ python/trunk/Doc/c-api/concrete.rst Mon Jan 14 05:13:37 2008 @@ -559,7 +559,7 @@ .. cfunction:: PyObject* PyFloat_GetInfo(void) - Return a :ctype:`PyDictObject` object which contains information about the + Return a structseq instance which contains information about the precision, minimum and maximum values of a float. It's a thin wrapper around the header file :file:`float.h`. Modified: python/trunk/Doc/library/sys.rst ============================================================================== --- python/trunk/Doc/library/sys.rst (original) +++ python/trunk/Doc/library/sys.rst Mon Jan 14 05:13:37 2008 @@ -280,12 +280,12 @@ .. data:: float_info - A dict holding information about the float type. It contains low level + A structseq holding information about the float type. It contains low level information about the precision and internal representation. Please study your system's :file:`float.h` for more information. +---------------------+--------------------------------------------------+ - | key | explanation | + | attribute | explanation | +=====================+==================================================+ | :const:`epsilon` | Difference between 1 and the next representable | | | floating point number | Modified: python/trunk/Lib/test/test_sys.py ============================================================================== --- python/trunk/Lib/test/test_sys.py (original) +++ python/trunk/Lib/test/test_sys.py Mon Jan 14 05:13:37 2008 @@ -329,8 +329,8 @@ self.assert_(isinstance(sys.copyright, basestring)) self.assert_(isinstance(sys.exec_prefix, basestring)) self.assert_(isinstance(sys.executable, basestring)) - self.assert_(isinstance(sys.float_info, dict)) self.assertEqual(len(sys.float_info), 11) + self.assertEqual(sys.float_info.radix, 2) self.assert_(isinstance(sys.hexversion, int)) self.assert_(isinstance(sys.maxint, int)) if test.test_support.have_unicode: Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Mon Jan 14 05:13:37 2008 @@ -12,6 +12,9 @@ Core and builtins ----------------- +- sys.float_info / PyFloat_GetInfo: The floating point information + object was converted from a dict to a specialized structseq object. + - Patch #1816: Added sys.flags structseq. It exposes the status of most command line arguments and PYTHON* environment variables. Modified: python/trunk/Objects/floatobject.c ============================================================================== --- python/trunk/Objects/floatobject.c (original) +++ python/trunk/Objects/floatobject.c Mon Jan 14 05:13:37 2008 @@ -5,10 +5,12 @@ for any kind of float exception without losing portability. */ #include "Python.h" +#include "structseq.h" #include #include + #if !defined(__STDC__) extern double fmod(double, double); extern double pow(double, double); @@ -59,40 +61,87 @@ return DBL_MIN; } +static PyTypeObject FloatInfoType = {0}; + +PyDoc_STRVAR(floatinfo__doc__, +"sys.floatinfo\n\ +\n\ +A structseq holding information about the float type. It contains low level\n\ +information about the precision and internal representation. Please study\n\ +your system's :file:`float.h` for more information."); + +static PyStructSequence_Field floatinfo_fields[] = { + {"max", "DBL_MAX -- maximum representable finite float"}, + {"max_exp", "DBL_MAX_EXP -- maximum int e such that radix**(e-1) " + "is representable"}, + {"max_10_exp", "DBL_MAX_10_EXP -- maximum int e such that 10**e " + "is representable"}, + {"min", "DBL_MIN -- Minimum positive normalizer float"}, + {"min_exp", "DBL_MIN_EXP -- minimum int e such that radix**(e-1) " + "is a normalized float"}, + {"min_10_exp", "DBL_MIN_10_EXP -- minimum int e such that 10**e is " + "a normalized"}, + {"dig", "DBL_DIG -- digits"}, + {"mant_dig", "DBL_MANT_DIG -- mantissa digits"}, + {"epsilon", "DBL_EPSILON -- Difference between 1 and the next " + "representable float"}, + {"radix", "FLT_RADIX -- radix of exponent"}, + {"rounds", "FLT_ROUNDS -- addition rounds"}, + {0} +}; + +static PyStructSequence_Desc floatinfo_desc = { + "sys.floatinfo", /* name */ + floatinfo__doc__, /* doc */ + floatinfo_fields, /* fields */ + 11 +}; + PyObject * PyFloat_GetInfo(void) { - PyObject *d, *tmp; + static PyObject* floatinfo; + int pos = 0; + + if (floatinfo != NULL) { + Py_INCREF(floatinfo); + return floatinfo; + } + PyStructSequence_InitType(&FloatInfoType, &floatinfo_desc); + + floatinfo = PyStructSequence_New(&FloatInfoType); + if (floatinfo == NULL) { + return NULL; + } -#define SET_FLOAT_CONST(d, key, const) \ - tmp = PyFloat_FromDouble(const); \ - if (tmp == NULL) return NULL; \ - if (PyDict_SetItemString(d, key, tmp)) return NULL; \ - Py_DECREF(tmp) -#define SET_INT_CONST(d, key, const) \ - tmp = PyInt_FromLong(const); \ - if (tmp == NULL) return NULL; \ - if (PyDict_SetItemString(d, key, tmp)) return NULL; \ - Py_DECREF(tmp) - - d = PyDict_New(); - - SET_FLOAT_CONST(d, "max", DBL_MAX); - SET_INT_CONST(d, "max_exp", DBL_MAX_EXP); - SET_INT_CONST(d, "max_10_exp", DBL_MAX_10_EXP); - SET_FLOAT_CONST(d, "min", DBL_MIN); - SET_INT_CONST(d, "min_exp", DBL_MIN_EXP); - SET_INT_CONST(d, "min_10_exp", DBL_MIN_10_EXP); - SET_INT_CONST(d, "dig", DBL_DIG); - SET_INT_CONST(d, "mant_dig", DBL_MANT_DIG); - SET_FLOAT_CONST(d, "epsilon", DBL_EPSILON); - SET_INT_CONST(d, "radix", FLT_RADIX); - SET_INT_CONST(d, "rounds", FLT_ROUNDS); +#define SetIntFlag(flag) \ + PyStructSequence_SET_ITEM(floatinfo, pos++, PyInt_FromLong(flag)) +#define SetDblFlag(flag) \ + PyStructSequence_SET_ITEM(floatinfo, pos++, PyFloat_FromDouble(flag)) + + SetDblFlag(DBL_MAX); + SetIntFlag(DBL_MAX_EXP); + SetIntFlag(DBL_MAX_10_EXP); + SetDblFlag(DBL_MIN); + SetIntFlag(DBL_MIN_EXP); + SetIntFlag(DBL_MIN_10_EXP); + SetIntFlag(DBL_DIG); + SetIntFlag(DBL_MANT_DIG); + SetDblFlag(DBL_EPSILON); + SetIntFlag(FLT_RADIX); + SetIntFlag(FLT_ROUNDS); +#undef SetIntFlag +#undef SetDblFlag + + if (PyErr_Occurred()) { + Py_CLEAR(floatinfo); + return NULL; + } - return d; + Py_INCREF(floatinfo); + return floatinfo; } - PyObject * PyFloat_FromDouble(double fval) { From guido at python.org Mon Jan 14 05:15:57 2008 From: guido at python.org (Guido van Rossum) Date: Sun, 13 Jan 2008 20:15:57 -0800 Subject: [Python-checkins] [Python-Dev] r59947 - in python/trunk:Lib/test/test_structseq.py Misc/NEWS In-Reply-To: <001201c85661$181a4390$6800a8c0@RaymondLaptop1> References: <20080114033353.2B9241E401A@bag.python.org> <001201c85661$181a4390$6800a8c0@RaymondLaptop1> Message-ID: On Jan 13, 2008 7:53 PM, Raymond Hettinger wrote: > [Christian Heimes] > > Log: > > Added new an better structseq representation. E.g. repr(time.gmtime(0)) now returns 'time.struct_time(tm_year=1970, tm_mon=1, > > tm_mday=1, tm_hour=0, tm_min=0, tm_sec=0, tm_wday=3, tm_yday=1, tm_isdst=0)' instead of '(1970, 1, 1, 0, 0, 0, 3, 1, 0)'. The > > feature is part of #1816: sys.flags > > FWIW, I was looking into something similar but didn't proceed because it would break eval(repr(s)) == s as the constructor signature > wants all the args in a tuple and won't accept keywords. Still, I think what you did is a nice improvement. > > Here's a couple more if you want to proceed down that path: > > 1. Have structseq subclass from PyTupleObject so that isinstance(s, tuple) returns True. This makes the object usable whenever > tuples are needed. Hmm, is that really necessary? structseq has been in use for quite a while and this need hasn't come up -- it's been designed to be quite compatible with tuple *except* for isinstance checks, and that has worked well. > 2. Add _fields, _asdict, and _replace to match the API in collections.namedtuple(). The _fields tuple should only include the > visible positional fields while _asdict() and _replace() should include all of the fields whether visible or accessible only by > attribute access. > > Thanks for the nice work. > > > Raymond > _______________________________________________ > Python-Dev mailing list > Python-Dev at python.org > http://mail.python.org/mailman/listinfo/python-dev > Unsubscribe: http://mail.python.org/mailman/options/python-dev/guido%40python.org > -- --Guido van Rossum (home page: http://www.python.org/~guido/) From lists at cheimes.de Mon Jan 14 05:25:44 2008 From: lists at cheimes.de (Christian Heimes) Date: Mon, 14 Jan 2008 05:25:44 +0100 Subject: [Python-checkins] r59947 - in python/trunk:Lib/test/test_structseq.py Misc/NEWS In-Reply-To: <001201c85661$181a4390$6800a8c0@RaymondLaptop1> References: <20080114033353.2B9241E401A@bag.python.org> <001201c85661$181a4390$6800a8c0@RaymondLaptop1> Message-ID: <478AE448.10704@cheimes.de> Raymond Hettinger wrote: > FWIW, I was looking into something similar but didn't proceed because it would break eval(repr(s)) == s as the constructor signature > wants all the args in a tuple and won't accept keywords. Still, I think what you did is a nice improvement. I agree that eval(repr(s)) == s is nice to have but most complex object don't support it. In this very case the readability of the repr() is more important than eval(repr(s)). I'm sure lots of users still think that os.stat or time.time() return an ordinary tuple. I've turned your request into an issue: http://bugs.python.org/issue1820 It's a feasible yet challenging task for a new CPython coder. Christian From python at rcn.com Mon Jan 14 05:26:45 2008 From: python at rcn.com (Raymond Hettinger) Date: Sun, 13 Jan 2008 20:26:45 -0800 Subject: [Python-checkins] [Python-Dev] r59947 - in python/trunk:Lib/test/test_structseq.py Misc/NEWS References: <20080114033353.2B9241E401A@bag.python.org> <001201c85661$181a4390$6800a8c0@RaymondLaptop1> Message-ID: <000a01c85665$ad028bd0$6800a8c0@RaymondLaptop1> >> 1. Have structseq subclass from PyTupleObject so that isinstance(s, tuple) returns True. This makes the object usable whenever >> tuples are needed. > > Hmm, is that really necessary? structseq has been in use for quite a > while and this need hasn't come up -- it's been designed to be quite > compatible with tuple *except* for isinstance checks, and that has > worked well. It looks like that is the only difference, so subclassing from tuple won't cause any other behavioral changes. It looks like making it a subtype involves only changing a few lines. I think it can only help, especially if we start to use structseq for more things in the future. Also, I would like the API to match collections.namedtuple() as closely as possible so that there is just a single useful concept that gets applied whereever needed. The idea is basically that they *are* tuples with the added nicity of attribute access and a self-documenting repr. Raymond From nnorwitz at gmail.com Mon Jan 14 06:30:01 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Sun, 13 Jan 2008 21:30:01 -0800 Subject: [Python-checkins] r59948 - python/trunk/Objects/structseq.c In-Reply-To: <20080114033539.001AB1E401A@bag.python.org> References: <20080114033539.001AB1E401A@bag.python.org> Message-ID: Christian, Can you add some comments to the code? I'll give more detailed code review below. On Jan 13, 2008 7:35 PM, christian.heimes wrote: > Author: christian.heimes > Date: Mon Jan 14 04:35:38 2008 > New Revision: 59948 > > Modified: > python/trunk/Objects/structseq.c > Log: > I missed the most important file > > Modified: python/trunk/Objects/structseq.c > ============================================================================== > --- python/trunk/Objects/structseq.c (original) > +++ python/trunk/Objects/structseq.c Mon Jan 14 04:35:38 2008 > @@ -30,7 +30,7 @@ > PyStructSequence_New(PyTypeObject *type) > { > PyStructSequence *obj; > - > + > obj = PyObject_New(PyStructSequence, type); > Py_SIZE(obj) = VISIBLE_SIZE_TP(type); > > @@ -230,11 +230,64 @@ > static PyObject * > structseq_repr(PyStructSequence *obj) > { > - PyObject *tup, *str; > - tup = make_tuple(obj); > - str = PyObject_Repr(tup); > + PyObject *tup, *val, *repr; > + PyTypeObject *typ = Py_TYPE(obj); > + int i, len; > + char buf[250+5]; /* "...)\0" */ > + char *cname, *crepr; It would be nice to limit scope for cname, crepr and any others that are only used inside the loop. > + char *pbuf = buf; > + char *endbuf = &buf[250]; Is 250 enough? How did you calculate? This would be good to doc. Also, it seems like it would be better to use either MACRO_SIZE or sizeof() calculations so these can't get out of sync. > + strncpy(pbuf, typ->tp_name, 50); > + pbuf += strlen(typ->tp_name) > 50 ? 50 : strlen(typ->tp_name); 50 is mentioned 3 times. Perhaps a TYPE_NAME_SIZE? Also it would probably be better to calculate the size you want to copy first and then pass that to strncpy. It seems less likely to break if only one line is changed or moved. The dependency would be clearer to me. > + *pbuf++ = '('; > + > + if ((tup = make_tuple(obj)) == NULL) { > + return NULL; > + } > + for (i=0; i < VISIBLE_SIZE(obj); i++) { > + cname = typ->tp_members[i].name; > + val = PyTuple_GetItem(tup, i); > + if (cname == NULL || val == NULL) { > + return NULL; > + } > + repr = PyObject_Repr(val); > + if (repr == NULL) { > + Py_DECREF(tup); > + return NULL; > + } > + crepr = PyString_AsString(repr); > + if (crepr == NULL) { > + Py_DECREF(tup); > + Py_DECREF(repr); > + return NULL; > + } > + len = strlen(cname) + strlen(crepr) + 3; This is a potential buffer overflow. The addition should be checked. Also note that strlen() returns size_t which is unsigned and could be larger than an int, eg on 64-bit platforms. > + if ((pbuf+len) < endbuf) { If this is the last element the condition above could be false, even though its possible for the data to fit. > + strcpy(pbuf, cname); > + pbuf += strlen(cname); > + *pbuf++ = '='; > + strcpy(pbuf, crepr); > + pbuf += strlen(crepr); > + *pbuf++ = ','; > + *pbuf++ = ' '; > + Py_DECREF(repr); > + } > + else { > + strcpy(pbuf, "..."); > + pbuf += 5; It took me a long time to figure out why 5. I don't like that this is dependent on the 5 added to the buffer above and that you are copying 3 bytes here. I understood once I saw the -= 2 below. But this should be documented and perhaps refactored to try to prevent breakage if one part of the code is modified, but not the rest. > + Py_DECREF(repr); > + break; > + } > + } > Py_DECREF(tup); > - return str; > + > + pbuf-=2; If the tuple is empty, this will print TypeNam) rather than TypeName(). While this is an unusual use of structseq, it should still work. > + *pbuf++ = ')'; > + *pbuf = '\0'; > + > + repr = PyString_FromString(buf); > + return repr; > } > > static PyObject * > _______________________________________________ > Python-checkins mailing list > Python-checkins at python.org > http://mail.python.org/mailman/listinfo/python-checkins > From buildbot at python.org Mon Jan 14 06:36:37 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 14 Jan 2008 05:36:37 +0000 Subject: [Python-checkins] buildbot failure in x86 FreeBSD trunk Message-ID: <20080114053637.B88771E401A@bag.python.org> The Buildbot has detected a new failure of x86 FreeBSD trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20FreeBSD%20trunk/builds/394 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-freebsd Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: 2 tests failed: test_socket_ssl test_ssl sincerely, -The Buildbot From python-checkins at python.org Mon Jan 14 07:06:19 2008 From: python-checkins at python.org (christian.heimes) Date: Mon, 14 Jan 2008 07:06:19 +0100 (CET) Subject: [Python-checkins] r59951 - python/trunk/Objects/structseq.c Message-ID: <20080114060619.83C0E1E401A@bag.python.org> Author: christian.heimes Date: Mon Jan 14 07:06:19 2008 New Revision: 59951 Modified: python/trunk/Objects/structseq.c Log: Added more comments to the new structseq repr code and implemented several of Neal's suggestions. Modified: python/trunk/Objects/structseq.c ============================================================================== --- python/trunk/Objects/structseq.c (original) +++ python/trunk/Objects/structseq.c Mon Jan 14 07:06:19 2008 @@ -230,23 +230,37 @@ static PyObject * structseq_repr(PyStructSequence *obj) { - PyObject *tup, *val, *repr; + /* buffer and type size were chosen well considered. */ +#define REPR_BUFFER_SIZE 512 +#define TYPE_MAXSIZE 100 + + PyObject *tup; PyTypeObject *typ = Py_TYPE(obj); - int i, len; - char buf[250+5]; /* "...)\0" */ - char *cname, *crepr; - char *pbuf = buf; - char *endbuf = &buf[250]; + int i, removelast = 0; + Py_ssize_t len; + char buf[REPR_BUFFER_SIZE]; + char *endofbuf, *pbuf = buf; - strncpy(pbuf, typ->tp_name, 50); - pbuf += strlen(typ->tp_name) > 50 ? 50 : strlen(typ->tp_name); - *pbuf++ = '('; + /* pointer to end of writeable buffer; safes space for "...)\0" */ + endofbuf= &buf[REPR_BUFFER_SIZE-5]; if ((tup = make_tuple(obj)) == NULL) { return NULL; } + + /* "typename(", limited to TYPE_MAXSIZE */ + len = strlen(typ->tp_name) > TYPE_MAXSIZE ? TYPE_MAXSIZE : + strlen(typ->tp_name); + strncpy(pbuf, typ->tp_name, len); + pbuf += len; + *pbuf++ = '('; + for (i=0; i < VISIBLE_SIZE(obj); i++) { + PyObject *val, *repr; + char *cname, *crepr; + cname = typ->tp_members[i].name; + val = PyTuple_GetItem(tup, i); if (cname == NULL || val == NULL) { return NULL; @@ -262,8 +276,10 @@ Py_DECREF(repr); return NULL; } - len = strlen(cname) + strlen(crepr) + 3; - if ((pbuf+len) < endbuf) { + + /* + 3: keep space for "=" and ", " */ + len = strlen(cname) + strlen(crepr) + 3; + if ((pbuf+len) <= endofbuf) { strcpy(pbuf, cname); pbuf += strlen(cname); *pbuf++ = '='; @@ -271,23 +287,26 @@ pbuf += strlen(crepr); *pbuf++ = ','; *pbuf++ = ' '; + removelast = 1; Py_DECREF(repr); } else { strcpy(pbuf, "..."); - pbuf += 5; + pbuf += 3; + removelast = 0; Py_DECREF(repr); break; } } Py_DECREF(tup); - - pbuf-=2; + if (removelast) { + /* overwrite last ", " */ + pbuf-=2; + } *pbuf++ = ')'; *pbuf = '\0'; - repr = PyString_FromString(buf); - return repr; + return PyString_FromString(buf); } static PyObject * From lists at cheimes.de Mon Jan 14 07:15:01 2008 From: lists at cheimes.de (Christian Heimes) Date: Mon, 14 Jan 2008 07:15:01 +0100 Subject: [Python-checkins] r59948 - python/trunk/Objects/structseq.c In-Reply-To: References: <20080114033539.001AB1E401A@bag.python.org> Message-ID: <478AFDE5.8020801@cheimes.de> Neal Norwitz wrote: > Christian, > > Can you add some comments to the code? I'll give more detailed code > review below. Done > It would be nice to limit scope for cname, crepr and any others that > are only used inside the loop. Does a local variable cost some CPU cycles to free and alloc space on the stack? Is there a speed difference between int i; for(...) {} and for (...) [ int i; } ? > Is 250 enough? How did you calculate? This would be good to doc. > Also, it seems like it would be better to use either MACRO_SIZE or > sizeof() calculations so these can't get out of sync. I chose 250 out of gut feeling. It's more than large enough for os.stat, time and sys.flags but fits in about 4 lines of output. > This is a potential buffer overflow. The addition should be checked. > Also note that strlen() returns size_t which is unsigned and could be > larger than an int, eg on 64-bit platforms. I don't see how the code could overflow. It doesn't add the string if "key=value, " doesn't fit in the buffer before endofbuf. > If this is the last element the condition above could be false, even > though its possible for the data to fit. Oh right, good catch. > It took me a long time to figure out why 5. I don't like that this is > dependent on the 5 added to the buffer above and that you are copying > 3 bytes here. I understood once I saw the -= 2 below. But this > should be documented and perhaps refactored to try to prevent breakage > if one part of the code is modified, but not the rest. You are right, it's too magic and tricky. The code now uses a variable removelast which should be self explaining. > If the tuple is empty, this will print TypeNam) rather than > TypeName(). While this is an unusual use of structseq, it should > still work. Fixed Christian From buildbot at python.org Mon Jan 14 07:33:44 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 14 Jan 2008 06:33:44 +0000 Subject: [Python-checkins] buildbot failure in x86 mvlgcc trunk Message-ID: <20080114063344.4E4541E4028@bag.python.org> The Buildbot has detected a new failure of x86 mvlgcc trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20mvlgcc%20trunk/builds/1202 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-linux Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_xmlrpc make: *** [buildbottest] Fehler 1 sincerely, -The Buildbot From martin at v.loewis.de Mon Jan 14 08:22:09 2008 From: martin at v.loewis.de (=?ISO-8859-1?Q?=22Martin_v=2E_L=F6wis=22?=) Date: Mon, 14 Jan 2008 08:22:09 +0100 Subject: [Python-checkins] [Python-Dev] r59947 - in python/trunk:Lib/test/test_structseq.py Misc/NEWS In-Reply-To: References: <20080114033353.2B9241E401A@bag.python.org> <001201c85661$181a4390$6800a8c0@RaymondLaptop1> Message-ID: <478B0DA1.3030405@v.loewis.de> > Hmm, is that really necessary? structseq has been in use for quite a > while and this need hasn't come up -- it's been designed to be quite > compatible with tuple *except* for isinstance checks, and that has > worked well. In addition, I would like to suggest that the current structseq usage is changed to regular classes (perhaps with slots) in Python 3. structseq was a compatibility mechanism for existing code that assumes the things returned are tuples, when they are really objects with named fields. So for struct stat and struct tm in particular, I think the indexed access should be removed in Python 3. Whether then structseq needs to be preserved at all, I don't know. Regards, Martin From nnorwitz at gmail.com Mon Jan 14 11:28:54 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Mon, 14 Jan 2008 05:28:54 -0500 Subject: [Python-checkins] Python Regression Test Failures refleak (7) Message-ID: <20080114102854.GA5920@python.psfb.org> test_opcodes leaked [-2, 0, 2] references, sum=0 test_doctest leaked [0, 0, -4] references, sum=-4 test_cmd_line leaked [0, -23, 0] references, sum=-23 test_descrtut leaked [0, 4, -2] references, sum=2 test_funcattrs leaked [0, -2, 2] references, sum=0 test_functools leaked [-2, 0, 0] references, sum=-2 test_gc leaked [2, 0, 0] references, sum=2 test_gdbm leaked [0, -2, 0] references, sum=-2 test_genexps leaked [-2, 0, 2] references, sum=0 test_importhooks leaked [-2, 8, -6] references, sum=0 test_os leaked [0, 0, -2] references, sum=-2 test_poll leaked [0, 0, -2] references, sum=-2 test_threadsignals leaked [0, 0, -2] references, sum=-2 test_urllib2_localnet leaked [3, 3, 3] references, sum=9 From python-checkins at python.org Mon Jan 14 11:35:29 2008 From: python-checkins at python.org (thomas.heller) Date: Mon, 14 Jan 2008 11:35:29 +0100 (CET) Subject: [Python-checkins] r59952 - python/trunk/Modules/_ctypes/libffi/configure python/trunk/Modules/_ctypes/libffi/configure.ac Message-ID: <20080114103529.458771E4027@bag.python.org> Author: thomas.heller Date: Mon Jan 14 11:35:28 2008 New Revision: 59952 Modified: python/trunk/Modules/_ctypes/libffi/configure python/trunk/Modules/_ctypes/libffi/configure.ac Log: Issue 1821: configure libffi for amd64 on FreeeBSD. Modified: python/trunk/Modules/_ctypes/libffi/configure ============================================================================== --- python/trunk/Modules/_ctypes/libffi/configure (original) +++ python/trunk/Modules/_ctypes/libffi/configure Mon Jan 14 11:35:28 2008 @@ -934,7 +934,7 @@ else echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 fi - cd $ac_popdir + cd "$ac_popdir" done fi @@ -1973,8 +1973,7 @@ cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -z "$ac_c_werror_flag" - || test ! -s conftest.err' + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? @@ -2032,8 +2031,7 @@ cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -z "$ac_c_werror_flag" - || test ! -s conftest.err' + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? @@ -2149,8 +2147,7 @@ cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -z "$ac_c_werror_flag" - || test ! -s conftest.err' + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? @@ -2204,8 +2201,7 @@ cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -z "$ac_c_werror_flag" - || test ! -s conftest.err' + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? @@ -2250,8 +2246,7 @@ cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -z "$ac_c_werror_flag" - || test ! -s conftest.err' + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? @@ -2295,8 +2290,7 @@ cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -z "$ac_c_werror_flag" - || test ! -s conftest.err' + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? @@ -2623,8 +2617,7 @@ cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -z "$ac_c_werror_flag" - || test ! -s conftest.err' + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? @@ -2794,8 +2787,7 @@ cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -z "$ac_c_werror_flag" - || test ! -s conftest.err' + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? @@ -2862,8 +2854,7 @@ cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -z "$ac_c_werror_flag" - || test ! -s conftest.err' + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? @@ -3047,8 +3038,7 @@ cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -z "$ac_c_werror_flag" - || test ! -s conftest.err' + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? @@ -3111,8 +3101,7 @@ cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -z "$ac_c_werror_flag" - || test ! -s conftest.err' + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? @@ -3290,8 +3279,7 @@ cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -z "$ac_c_werror_flag" - || test ! -s conftest.err' + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? @@ -3408,8 +3396,7 @@ cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -z "$ac_c_werror_flag" - || test ! -s conftest.err' + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? @@ -3529,7 +3516,7 @@ cris-*-*) TARGET=LIBFFI_CRIS; TARGETDIR=cris;; s390-*-linux-*) TARGET=S390; TARGETDIR=s390;; s390x-*-linux-*) TARGET=S390; TARGETDIR=s390;; -x86_64-*-linux* | x86_64-*-freebsd* | x86_64-*-kfreebsd*-gnu) TARGET=X86_64; TARGETDIR=x86;; +amd64-*-freebsd* | x86_64-*-linux* | x86_64-*-freebsd* | x86_64-*-kfreebsd*-gnu) TARGET=X86_64; TARGETDIR=x86;; sh-*-linux* | sh[34]*-*-linux*) TARGET=SH; TARGETDIR=sh;; sh-*-rtems*) TARGET=SH; TARGETDIR=sh;; sh64-*-linux* | sh5*-*-linux*) TARGET=SH64; TARGETDIR=sh64;; @@ -3582,8 +3569,7 @@ cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -z "$ac_c_werror_flag" - || test ! -s conftest.err' + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? @@ -3784,8 +3770,7 @@ cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -z "$ac_c_werror_flag" - || test ! -s conftest.err' + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? @@ -3848,8 +3833,7 @@ cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -z "$ac_c_werror_flag" - || test ! -s conftest.err' + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? @@ -3930,8 +3914,7 @@ cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -z "$ac_c_werror_flag" - || test ! -s conftest.err' + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? @@ -4072,8 +4055,7 @@ cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -z "$ac_c_werror_flag" - || test ! -s conftest.err' + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? @@ -4209,8 +4191,7 @@ cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -z "$ac_c_werror_flag" - || test ! -s conftest.err' + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? @@ -4272,8 +4253,7 @@ cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -z "$ac_c_werror_flag" - || test ! -s conftest.err' + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? @@ -4313,8 +4293,7 @@ cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -z "$ac_c_werror_flag" - || test ! -s conftest.err' + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? @@ -4370,8 +4349,7 @@ cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -z "$ac_c_werror_flag" - || test ! -s conftest.err' + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? @@ -4411,8 +4389,7 @@ cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -z "$ac_c_werror_flag" - || test ! -s conftest.err' + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? @@ -4476,8 +4453,7 @@ cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -z "$ac_c_werror_flag" - || test ! -s conftest.err' + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? @@ -4508,10 +4484,8 @@ esac else if test "$cross_compiling" = yes; then - { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling -See \`config.log' for more details." >&5 -echo "$as_me: error: cannot run test program while cross compiling -See \`config.log' for more details." >&2;} + { { echo "$as_me:$LINENO: error: internal error: not reached in cross-compile" >&5 +echo "$as_me: error: internal error: not reached in cross-compile" >&2;} { (exit 1); exit 1; }; } else cat >conftest.$ac_ext <<_ACEOF @@ -4623,8 +4597,7 @@ cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -z "$ac_c_werror_flag" - || test ! -s conftest.err' + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? @@ -4686,8 +4659,7 @@ cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -z "$ac_c_werror_flag" - || test ! -s conftest.err' + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? @@ -4727,8 +4699,7 @@ cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -z "$ac_c_werror_flag" - || test ! -s conftest.err' + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? @@ -4784,8 +4755,7 @@ cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -z "$ac_c_werror_flag" - || test ! -s conftest.err' + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? @@ -4825,8 +4795,7 @@ cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -z "$ac_c_werror_flag" - || test ! -s conftest.err' + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? @@ -4890,8 +4859,7 @@ cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -z "$ac_c_werror_flag" - || test ! -s conftest.err' + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? @@ -4922,10 +4890,8 @@ esac else if test "$cross_compiling" = yes; then - { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling -See \`config.log' for more details." >&5 -echo "$as_me: error: cannot run test program while cross compiling -See \`config.log' for more details." >&2;} + { { echo "$as_me:$LINENO: error: internal error: not reached in cross-compile" >&5 +echo "$as_me: error: internal error: not reached in cross-compile" >&2;} { (exit 1); exit 1; }; } else cat >conftest.$ac_ext <<_ACEOF @@ -5047,8 +5013,7 @@ cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -z "$ac_c_werror_flag" - || test ! -s conftest.err' + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? @@ -5109,8 +5074,7 @@ cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -z "$ac_c_werror_flag" - || test ! -s conftest.err' + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? @@ -5172,8 +5136,7 @@ cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -z "$ac_c_werror_flag" - || test ! -s conftest.err' + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? @@ -5213,8 +5176,7 @@ cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -z "$ac_c_werror_flag" - || test ! -s conftest.err' + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? @@ -5270,8 +5232,7 @@ cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -z "$ac_c_werror_flag" - || test ! -s conftest.err' + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? @@ -5311,8 +5272,7 @@ cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -z "$ac_c_werror_flag" - || test ! -s conftest.err' + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? @@ -5376,8 +5336,7 @@ cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -z "$ac_c_werror_flag" - || test ! -s conftest.err' + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? @@ -5408,10 +5367,8 @@ esac else if test "$cross_compiling" = yes; then - { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling -See \`config.log' for more details." >&5 -echo "$as_me: error: cannot run test program while cross compiling -See \`config.log' for more details." >&2;} + { { echo "$as_me:$LINENO: error: internal error: not reached in cross-compile" >&5 +echo "$as_me: error: internal error: not reached in cross-compile" >&2;} { (exit 1); exit 1; }; } else cat >conftest.$ac_ext <<_ACEOF @@ -5528,8 +5485,7 @@ cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -z "$ac_c_werror_flag" - || test ! -s conftest.err' + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? @@ -5571,8 +5527,7 @@ cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -z "$ac_c_werror_flag" - || test ! -s conftest.err' + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? @@ -5629,8 +5584,7 @@ cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -z "$ac_c_werror_flag" - || test ! -s conftest.err' + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? @@ -5762,8 +5716,7 @@ cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -z "$ac_c_werror_flag" - || test ! -s conftest.err' + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? @@ -5829,8 +5782,7 @@ cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && - { ac_try='test -z "$ac_c_werror_flag" - || test ! -s conftest.err' + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? @@ -6789,11 +6741,6 @@ - if test x"$ac_file" != x-; then - { echo "$as_me:$LINENO: creating $ac_file" >&5 -echo "$as_me: creating $ac_file" >&6;} - rm -f "$ac_file" - fi # Let's still pretend it is `configure' which instantiates (i.e., don't # use $as_me), people would be surprised to read: # /* config.h. Generated by config.status. */ @@ -6832,6 +6779,12 @@ fi;; esac done` || { (exit 1); exit 1; } + + if test x"$ac_file" != x-; then + { echo "$as_me:$LINENO: creating $ac_file" >&5 +echo "$as_me: creating $ac_file" >&6;} + rm -f "$ac_file" + fi _ACEOF cat >>$CONFIG_STATUS <<_ACEOF sed "$ac_vpsub Modified: python/trunk/Modules/_ctypes/libffi/configure.ac ============================================================================== --- python/trunk/Modules/_ctypes/libffi/configure.ac (original) +++ python/trunk/Modules/_ctypes/libffi/configure.ac Mon Jan 14 11:35:28 2008 @@ -67,7 +67,7 @@ cris-*-*) TARGET=LIBFFI_CRIS; TARGETDIR=cris;; s390-*-linux-*) TARGET=S390; TARGETDIR=s390;; s390x-*-linux-*) TARGET=S390; TARGETDIR=s390;; -x86_64-*-linux* | x86_64-*-freebsd* | x86_64-*-kfreebsd*-gnu) TARGET=X86_64; TARGETDIR=x86;; +amd64-*-freebsd* | x86_64-*-linux* | x86_64-*-freebsd* | x86_64-*-kfreebsd*-gnu) TARGET=X86_64; TARGETDIR=x86;; sh-*-linux* | sh[[34]]*-*-linux*) TARGET=SH; TARGETDIR=sh;; sh-*-rtems*) TARGET=SH; TARGETDIR=sh;; sh64-*-linux* | sh5*-*-linux*) TARGET=SH64; TARGETDIR=sh64;; From buildbot at python.org Mon Jan 14 12:17:27 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 14 Jan 2008 11:17:27 +0000 Subject: [Python-checkins] buildbot failure in ppc Debian unstable trunk Message-ID: <20080114111727.F3F801E401F@bag.python.org> The Buildbot has detected a new failure of ppc Debian unstable trunk. Full details are available at: http://www.python.org/dev/buildbot/all/ppc%20Debian%20unstable%20trunk/builds/588 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: thomas.heller BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_xmlrpc ====================================================================== ERROR: test_fail_no_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_xmlrpc.py", line 560, in test_fail_no_info p.pow(6,8) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1157, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1447, in __request verbose=self.__verbose File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1195, in request errcode, errmsg, headers = h.getreply() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 1006, in getreply response = self._conn.getresponse() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 932, in getresponse response.begin() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 415, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 271, in readheaders line = self.fp.readline() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/socket.py", line 354, in readline data = recv(1) error: [Errno 104] Connection reset by peer ====================================================================== ERROR: test_fail_with_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_xmlrpc.py", line 580, in test_fail_with_info p.pow(6,8) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1157, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1447, in __request verbose=self.__verbose File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1195, in request errcode, errmsg, headers = h.getreply() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 1006, in getreply response = self._conn.getresponse() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 932, in getresponse response.begin() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 415, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 271, in readheaders line = self.fp.readline() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/socket.py", line 354, in readline data = recv(1) error: [Errno 104] Connection reset by peer make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Mon Jan 14 15:48:44 2008 From: python-checkins at python.org (andrew.kuchling) Date: Mon, 14 Jan 2008 15:48:44 +0100 (CET) Subject: [Python-checkins] r59953 - python/trunk/Doc/whatsnew/2.6.rst Message-ID: <20080114144844.19F421E401D@bag.python.org> Author: andrew.kuchling Date: Mon Jan 14 15:48:43 2008 New Revision: 59953 Modified: python/trunk/Doc/whatsnew/2.6.rst Log: Update description of float_info Modified: python/trunk/Doc/whatsnew/2.6.rst ============================================================================== --- python/trunk/Doc/whatsnew/2.6.rst (original) +++ python/trunk/Doc/whatsnew/2.6.rst Mon Jan 14 15:48:43 2008 @@ -935,11 +935,11 @@ .. Patch #957003 * A new variable in the :mod:`sys` module, - :attr:`float_info`, is a dictionary + :attr:`float_info`, is an object containing information about the platform's floating-point support - derived from the :file:`float.h` file. Key/value pairs - in this dictionary include - ``"mant_dig"`` (number of digits in the mantissa), ``"epsilon"`` + derived from the :file:`float.h` file. Attributes of this object + include + :attr:`mant_dig` (number of digits in the mantissa), :attr:`epsilon` (smallest difference between 1.0 and the next largest value representable), and several others. (Contributed by Christian Heimes.) From guido at python.org Mon Jan 14 16:37:45 2008 From: guido at python.org (Guido van Rossum) Date: Mon, 14 Jan 2008 07:37:45 -0800 Subject: [Python-checkins] [Python-Dev] r59947 - in python/trunk:Lib/test/test_structseq.py Misc/NEWS In-Reply-To: <478B0DA1.3030405@v.loewis.de> References: <20080114033353.2B9241E401A@bag.python.org> <001201c85661$181a4390$6800a8c0@RaymondLaptop1> <478B0DA1.3030405@v.loewis.de> Message-ID: On Jan 13, 2008 11:22 PM, "Martin v. L?wis" wrote: > > Hmm, is that really necessary? structseq has been in use for quite a > > while and this need hasn't come up -- it's been designed to be quite > > compatible with tuple *except* for isinstance checks, and that has > > worked well. > > In addition, I would like to suggest that the current structseq usage > is changed to regular classes (perhaps with slots) in Python 3. > structseq was a compatibility mechanism for existing code that assumes > the things returned are tuples, when they are really objects with named > fields. > > So for struct stat and struct tm in particular, I think the indexed > access should be removed in Python 3. Whether then structseq needs > to be preserved at all, I don't know. There seems to be a use case for it still, otherwise collections.namedtuple wouldn't be added to 2.6, right? I agree that it's time to clean up the tuple-ness of the stat and tm structures (especially since they both may have "hidden" fields that are not accessible via the tuple structure). And I see no need for the new sys.flags object to be a tuple at all. -- --Guido van Rossum (home page: http://www.python.org/~guido/) From buildbot at python.org Mon Jan 14 17:17:05 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 14 Jan 2008 16:17:05 +0000 Subject: [Python-checkins] buildbot failure in ARM Linux EABI 3.0 Message-ID: <20080114161706.1A7CE1E401D@bag.python.org> The Buildbot has detected a new failure of ARM Linux EABI 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/ARM%20Linux%20EABI%203.0/builds/0 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-linux-armeabi Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: alexandre.vassalotti,amaury.forgeotdarc,christian.heimes,eric.smith,georg.brandl,guido.van.rossum,jeffrey.yasskin,kurt.kaiser,raymond.hettinger BUILD FAILED: failed compile sincerely, -The Buildbot From buildbot at python.org Mon Jan 14 19:33:15 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 14 Jan 2008 18:33:15 +0000 Subject: [Python-checkins] buildbot failure in MIPS Debian trunk Message-ID: <20080114183315.7FB071E401F@bag.python.org> The Buildbot has detected a new failure of MIPS Debian trunk. Full details are available at: http://www.python.org/dev/buildbot/all/MIPS%20Debian%20trunk/builds/239 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-mips Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: amaury.forgeotdarc,andrew.kuchling,christian.heimes,facundo.batista,fred.drake,georg.brandl,guido.van.rossum,jeffrey.yasskin,ka-ping.yee,mark.dickinson,mark.summerfield,martin.v.loewis,neal.norwitz,raymond.hettinger,thomas.heller,vinay.sajip BUILD FAILED: failed test Excerpt from the test logfile: 3 tests failed: test_telnetlib test_urllib2net test_xmlrpc ====================================================================== ERROR: test_ftp (test.test_urllib2net.OtherNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/test/test_urllib2net.py", line 175, in test_ftp self._test_urls(urls, self._extra_handlers()) File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/test/test_urllib2net.py", line 244, in _test_urls f = urllib2.urlopen(url, req) File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/urllib2.py", line 124, in urlopen return _opener.open(url, data, timeout) File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/urllib2.py", line 380, in open response = self._open(req, data) File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/urllib2.py", line 398, in _open '_open', req) File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/urllib2.py", line 358, in _call_chain result = func(*args) File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/urllib2.py", line 1277, in ftp_open fw = self.connect_ftp(user, passwd, host, port, dirs, req.timeout) File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/urllib2.py", line 1323, in connect_ftp self.cache[key] = ftpwrapper(user, passwd, host, port, dirs, timeout) File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/urllib.py", line 842, in __init__ self.init() File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/urllib.py", line 848, in init self.ftp.connect(self.host, self.port, self.timeout) File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/ftplib.py", line 129, in connect self.sock = socket.create_connection((self.host, self.port), self.timeout) File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/socket.py", line 465, in create_connection raise error, msg TypeError: __init__() takes exactly 2 arguments (3 given) ====================================================================== ERROR: test_ftp_NoneNodefault (test.test_urllib2net.TimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/test/test_urllib2net.py", line 304, in test_ftp_NoneNodefault u = urllib2.urlopen("ftp://ftp.mirror.nl/pub/mirror/gnu/", timeout=None) File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/urllib2.py", line 124, in urlopen return _opener.open(url, data, timeout) File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/urllib2.py", line 380, in open response = self._open(req, data) File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/urllib2.py", line 398, in _open '_open', req) File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/urllib2.py", line 358, in _call_chain result = func(*args) File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/urllib2.py", line 1277, in ftp_open fw = self.connect_ftp(user, passwd, host, port, dirs, req.timeout) File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/urllib2.py", line 1323, in connect_ftp self.cache[key] = ftpwrapper(user, passwd, host, port, dirs, timeout) File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/urllib.py", line 842, in __init__ self.init() File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/urllib.py", line 848, in init self.ftp.connect(self.host, self.port, self.timeout) File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/ftplib.py", line 129, in connect self.sock = socket.create_connection((self.host, self.port), self.timeout) File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/socket.py", line 465, in create_connection raise error, msg TypeError: __init__() takes exactly 2 arguments (3 given) ====================================================================== ERROR: test_ftp_NoneWithdefault (test.test_urllib2net.TimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/test/test_urllib2net.py", line 298, in test_ftp_NoneWithdefault u = urllib2.urlopen("ftp://ftp.mirror.nl/pub/mirror/gnu/", timeout=None) File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/urllib2.py", line 124, in urlopen return _opener.open(url, data, timeout) File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/urllib2.py", line 380, in open response = self._open(req, data) File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/urllib2.py", line 398, in _open '_open', req) File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/urllib2.py", line 358, in _call_chain result = func(*args) File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/urllib2.py", line 1277, in ftp_open fw = self.connect_ftp(user, passwd, host, port, dirs, req.timeout) File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/urllib2.py", line 1323, in connect_ftp self.cache[key] = ftpwrapper(user, passwd, host, port, dirs, timeout) File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/urllib.py", line 842, in __init__ self.init() File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/urllib.py", line 848, in init self.ftp.connect(self.host, self.port, self.timeout) File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/ftplib.py", line 129, in connect self.sock = socket.create_connection((self.host, self.port), self.timeout) File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/socket.py", line 465, in create_connection raise error, msg TypeError: __init__() takes exactly 2 arguments (3 given) ====================================================================== ERROR: test_ftp_Value (test.test_urllib2net.TimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/test/test_urllib2net.py", line 308, in test_ftp_Value u = urllib2.urlopen("ftp://ftp.mirror.nl/pub/mirror/gnu/", timeout=60) File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/urllib2.py", line 124, in urlopen return _opener.open(url, data, timeout) File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/urllib2.py", line 380, in open response = self._open(req, data) File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/urllib2.py", line 398, in _open '_open', req) File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/urllib2.py", line 358, in _call_chain result = func(*args) File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/urllib2.py", line 1277, in ftp_open fw = self.connect_ftp(user, passwd, host, port, dirs, req.timeout) File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/urllib2.py", line 1323, in connect_ftp self.cache[key] = ftpwrapper(user, passwd, host, port, dirs, timeout) File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/urllib.py", line 842, in __init__ self.init() File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/urllib.py", line 848, in init self.ftp.connect(self.host, self.port, self.timeout) File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/ftplib.py", line 129, in connect self.sock = socket.create_connection((self.host, self.port), self.timeout) File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/socket.py", line 465, in create_connection raise error, msg TypeError: __init__() takes exactly 2 arguments (3 given) ====================================================================== ERROR: test_ftp_basic (test.test_urllib2net.TimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/test/test_urllib2net.py", line 291, in test_ftp_basic u = urllib2.urlopen("ftp://ftp.mirror.nl/pub/mirror/gnu/") File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/urllib2.py", line 124, in urlopen return _opener.open(url, data, timeout) File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/urllib2.py", line 380, in open response = self._open(req, data) File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/urllib2.py", line 398, in _open '_open', req) File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/urllib2.py", line 358, in _call_chain result = func(*args) File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/urllib2.py", line 1277, in ftp_open fw = self.connect_ftp(user, passwd, host, port, dirs, req.timeout) File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/urllib2.py", line 1323, in connect_ftp self.cache[key] = ftpwrapper(user, passwd, host, port, dirs, timeout) File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/urllib.py", line 842, in __init__ self.init() File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/urllib.py", line 848, in init self.ftp.connect(self.host, self.port, self.timeout) File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/ftplib.py", line 129, in connect self.sock = socket.create_connection((self.host, self.port), self.timeout) File "/home/pybot/buildarea/trunk.klose-debian-mips/build/Lib/socket.py", line 465, in create_connection raise error, msg TypeError: __init__() takes exactly 2 arguments (3 given) make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Mon Jan 14 20:16:36 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 14 Jan 2008 19:16:36 +0000 Subject: [Python-checkins] buildbot failure in ARM Linux EABI 2.5 Message-ID: <20080114191637.1DE811E403B@bag.python.org> The Buildbot has detected a new failure of ARM Linux EABI 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/ARM%20Linux%20EABI%202.5/builds/0 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-linux-armeabi Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: andrew.kuchling,christian.heimes,facundo.batista,guido.van.rossum,lars.gustaebel,mark.dickinson,martin.v.loewis,thomas.heller BUILD FAILED: failed test Excerpt from the test logfile: sincerely, -The Buildbot From buildbot at python.org Mon Jan 14 20:28:35 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 14 Jan 2008 19:28:35 +0000 Subject: [Python-checkins] buildbot failure in ppc Debian unstable 3.0 Message-ID: <20080114192835.3E1B01E4007@bag.python.org> The Buildbot has detected a new failure of ppc Debian unstable 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/ppc%20Debian%20unstable%203.0/builds/462 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 522, in __init__ self.handle() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/BaseHTTPServer.py", line 330, in handle self.handle_one_request() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/BaseHTTPServer.py", line 324, in handle_one_request method() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SimpleXMLRPCServer.py", line 430, in do_POST self.report_404() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SimpleXMLRPCServer.py", line 489, in report_404 self.connection.shutdown(1) socket.error: [Errno 107] Transport endpoint is not connected 1 test failed: test_xmlrpc Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 522, in __init__ self.handle() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/BaseHTTPServer.py", line 330, in handle self.handle_one_request() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/BaseHTTPServer.py", line 324, in handle_one_request method() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SimpleXMLRPCServer.py", line 430, in do_POST self.report_404() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SimpleXMLRPCServer.py", line 489, in report_404 self.connection.shutdown(1) socket.error: [Errno 107] Transport endpoint is not connected make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Mon Jan 14 21:42:39 2008 From: python-checkins at python.org (christian.heimes) Date: Mon, 14 Jan 2008 21:42:39 +0100 (CET) Subject: [Python-checkins] r59955 - peps/trunk/pep-0000.txt peps/trunk/pep-0369.txt peps/trunk/pep-0370.txt Message-ID: <20080114204239.C71661E401F@bag.python.org> Author: christian.heimes Date: Mon Jan 14 21:42:39 2008 New Revision: 59955 Added: peps/trunk/pep-0369.txt (contents, props changed) peps/trunk/pep-0370.txt (contents, props changed) Modified: peps/trunk/pep-0000.txt Log: Added PEP 369 and PEP 370 Modified: peps/trunk/pep-0000.txt ============================================================================== --- peps/trunk/pep-0000.txt (original) +++ peps/trunk/pep-0000.txt Mon Jan 14 21:42:39 2008 @@ -94,6 +94,8 @@ S 364 Transitioning to the Py3K Standard Library Warsaw S 365 Adding the pkg_resources module Eby S 368 Standard image protocol and class Mastrodomenico + S 369 Post import hooks Heimes + S 370 Per user site-packages directory Heimes S 3108 Standard Library Reorganization Cannon S 3134 Exception Chaining and Embedded Tracebacks Yee S 3135 New Super Spealman, Delaney @@ -467,6 +469,8 @@ SF 366 Main module explicit relative imports Coghlan SR 367 New Super Spealman, Delaney S 368 Standard image protocol and class Mastrodomenico + S 369 Post import hooks Heimes + S 370 Per user site-packages directory Heimes SR 666 Reject Foolish Indentation Creighton SR 754 IEEE 754 Floating Point Special Values Warnes P 3000 Python 3000 GvR @@ -571,6 +575,7 @@ Griffin, Grant g2 at iowegian.com Hammond, Mark mhammond at skippinet.com.au Harris, Peter scav at blueyonder.co.uk + Heimes, Christian christian at cheimes.de Heller, Thomas theller at python.net Hetland, Magnus Lie magnus at hetland.org Hettinger, Raymond python at rcn.com Added: peps/trunk/pep-0369.txt ============================================================================== --- (empty file) +++ peps/trunk/pep-0369.txt Mon Jan 14 21:42:39 2008 @@ -0,0 +1,235 @@ +PEP: 369 +Title: Post import hooks +Version: $Revision$ +Last-Modified: $Date$ +Author: Christian Heimes +Status: Draft +Type: Standards Track +Content-Type: text/x-rst +Created: 02-Jan-2008 +Python-Version: 2.6, 3.0 +Post-History: + + +Abstract +======== + +This PEP proposes enhancements for the import machinery to add +post import hooks. It is intended primarily to support the wider +use of abstract base classes that is expected in Python 3.0. + +The PEP originally started as a combined PEP for lazy imports and +post import hooks. After some discussion on the python-dev mailing +list the PEP was parted in two separate PEPs. [1]_ + + +Rationale +========= + +Python has no API to hook into the import machinery and execute code +*after* a module is successfully loaded. The import hooks of PEP 302 are +about finding modules and loading modules but they were not designed to +as post import hooks. + + +Use cases +========= + +A use case for a post import hook is mentioned in Nick Coghlan's initial +posting [2]_. about callbacks on module import. It was found during the +development of Python 3.0 and its ABCs. We wanted to register classes +like decimal.Decimal with an ABC but the module should not be imported +on every interpreter startup. Nick came up with this example:: + + @imp.when_imported('decimal') + def register(decimal): + Inexact.register(decimal.Decimal) + +The function ``register`` is registered as callback for the module named +'decimal'. When decimal is imported the function is called with the +module object as argument. + +While this particular example isn't necessary in practice, (as +decimal.Decimal will inherit from the appropriate abstract Number base +class in 2.6 and 3.0), it still illustrates the principle. + + +Existing implementations +======================== + +PJE's peak.util.imports [3]_ implements post load hooks. My +implementation shares a lot with his and it's partly based on his ideas. + + +Post import hook implementation +=============================== + +Post import hooks are called after a module has been loaded. The hooks +are callable which take one argument, the module instance. They are +registered by the dotted name of the module, e.g. 'os' or 'os.path'. + +The callable are stored in the dict ``sys.post_import_hooks`` which +is a mapping from names (as string) to a list of callables or None. + + +States +------ + +No hook was registered +'''''''''''''''''''''' + +sys.post_import_hooks contains no entry for the module + +A hook is registered and the module is not loaded yet +''''''''''''''''''''''''''''''''''''''''''''''''''''' + +The import hook registry contains an entry +sys.post_import_hooks["name"] = [hook1] + +A module is successfully loaded +''''''''''''''''''''''''''''''' + +The import machinery checks if sys.post_import_hooks contains post import +hooks for the newly loaded module. If hooks are found then the hooks are +called in the order they were registered with the module instance as first +argument. The processing of the hooks is stopped when a method raises an +exception. At the end the entry for the module name is removed from +sys.post_import_hooks, even when an error has occured. + +A module can't be loaded +'''''''''''''''''''''''' + +The import hooks are neither called nor removed from the registry. It +may be possible to load the module later. + +A hook is registered but the module is already loaded +''''''''''''''''''''''''''''''''''''''''''''''''''''' + +The hook is fired immediately. + + +C API +----- + +New PyImport_* API functions +'''''''''''''''''''''''''''' + +``PyObject* PyImport_GetPostImportHooks(void)`` + Returns the dict sys.post_import_hooks or NULL + +``PyObject* PyImport_NotifyModuleLoaded(PyObject *module)`` + Notify the post import system that a module was requested. Returns the + module or NULL if an error has occured. + +``PyObject* PyImport_RegisterPostImportHook(PyObject *callable, PyObject *mod_name)`` + Register a new hook ``callable`` for the module ``mod_name`` + +The ``PyImport_PostImportNotify()`` method is called by +``PyImport_ImportModuleLevel()``:: + + PyImport_ImportModuleLevel(...) + { + ... + result = import_module_level(name, globals, locals, fromlist, level); + result = PyImport_PostImportNotify(result); + ... + } + + +Python API +---------- + +The import hook registry and two new API methods are exposed through the +``sys`` and ``imp`` module. + +sys.post_import_hooks + The dict contains the post import hooks: {"name" : [hook1, hook2], ...} + +imp.register_post_import_hook(hook: "callable", name: str) + Register a new hook *hook* for the module *name* + +imp.notify_module_loaded(module: "module instance") -> module + Notify the system that a module has been loaded. The method is provided + for compatibility with existing lazy / deferred import extensions. + +The when_imported function decorator is also in the imp module, +which is equivalent to:: + + def when_imported(name): + def register(hook): + register_post_import_hook(hook, name) + return register + +imp.when_imported(name) -> decorator function + for @when_imported(name) def hook(module): pass + + +Open issues +=========== + +The when_imported decorator hasn't been written. + +The code contains several XXX comments. They are mostly about error +handling in edge cases. + + +Backwards Compatibility +======================= + +The new features and API don't conflict with old import system of Python +and don't cause any backward compatibility issues for most software. +However systems like PEAK and Zope which implement their own lazy import +magic need to follow some rules. + +The post import hooks carefully designed to cooperate with existing +deferred and lazy import systems. It's the suggestion of the PEP author +to replace own on-load-hooks with the new hook API. The alternative +lazy or deferred imports will still work but the implementations must +call the ``imp.notify_module_loaded`` function. + + +Reference Implementation +======================== + +A reference implementation is already written and is available in the +*py3k-importhook* branch. [4]_ It still requires some cleanups, +documentation updates and additional unit tests. + + +Acknowledgments +=============== + +Nick Coghlan, for proof reading and the initial discussion +Phillip J. Eby, for his implementation in PEAK and help with my own implementation + + +Copyright +========= + +This document has been placed in the public domain. + + +References +========== + +.. [1] PEP: Lazy module imports and post import hook + http://permalink.gmane.org/gmane.comp.python.devel/90949 + +.. [2] Interest in PEP for callbacks on module import + http://permalink.gmane.org/gmane.comp.python.python-3000.devel/11126 + +.. [3] peak.utils.imports + http://svn.eby-sarna.com/Importing/peak/util/imports.py?view=markup + +.. [4] py3k-importhook branch + http://svn.python.org/view/python/branches/py3k-importhook/ + + +.. + Local Variables: + mode: indented-text + indent-tabs-mode: nil + sentence-end-double-space: t + fill-column: 70 + coding: utf-8 + End: Added: peps/trunk/pep-0370.txt ============================================================================== --- (empty file) +++ peps/trunk/pep-0370.txt Mon Jan 14 21:42:39 2008 @@ -0,0 +1,229 @@ +PEP: 370 +Title: Per user site-packages directory +Version: $Revision$ +Last-Modified: $Date$ +Author: Christian Heimes +Status: Draft +Type: Standards Track +Content-Type: text/x-rst +Created: 11-Jan-2008 +Python-Version: 2.6, 3.0 +Post-History: + + +Abstract +======== + +This PEP proposes a new a per user site-packages directory to allow +users the local installation of Python packages in their home directory. + + +Rationale +========= + +Current Python versions don't have an unified way to install packages +into the home directory of an user (except for Mac Framework +builds). Users are either forced to ask the system administrator to +install or update a package for them or to use one of the many +workaround like Virtual Python [1]_, Working Env [2]_ or +Virtual Env [3]_. + +It's not the goal of the PEP to replace the tools or to implement +isolated installations of Python. It only implements the most common +use case of an additional site-packages directory for each user. + +The feature can't be implemented using the environment variable +*PYTHONPATH*. The env var just inserts a new directory to the beginning +of *sys.path* but it doesn't parse the pth files in the directory. A +full blown site-packages path is required for several applications +and Python eggs. + + +Specification +============= + +site directory (site-packages) + + A directory in ``sys.path``. In contrast to ordinary directories the pth + files in the directory are processed, too. + +user site directory + + A site directory inside the users' home directory. An user site + directory is specific to a Python version. The path contains + the version number (major and minor only). + + Mac + ``~/Library/Python/2.6/site-packages`` + Unix + ``~/.local/lib/python2.6/site-packages`` + + Windows + ``%APPDATA%/Python/Python26/site-packages`` + +user configuration directory + + Usually the parent directory of the user site directory. It's meant + for Python version specific data like config files. + + Mac + ``~/Library/Python/2.6`` + Unix + ``~/.local/lib/python2.6`` + Windows + ``%APPDATA%/Python/Python26`` + +user base directory + + It's located inside the user's home directory. The user site and + use config directory are inside the base directory. On some systems + the directory may be shared with 3rd party apps. + + Mac + ``~/Library/Python`` + + Unix + ``~/.local`` + Windows + ``%APPDATA%/Python`` + +user script directory + + A directory for binaries and scripts. [10]_ It's shared across Python + versions and the destination directory for scripts. + + Mac + ``~/Library/Python/bin`` + Unix + ``~/.local/bin`` + Windows + ``%APPDATA%/Python/Scripts`` + + +On Windows ``APPDATA`` was chosen because it is the most logical place for +application data. Microsoft recommands that software doesn't write to +``USERPROFILE`` [5]_ and ``My Documents`` is not suited for application data, +too. [8]_ + +On Linux ``~/.local`` was chosen in favor over ``~/.python`` because the +directory is already used by several other programs in analogy to +``/usr/local``. [7]_ + + +Implementation +============== + +The site module gets a new method ``adduserpackage()`` which adds the +appropriate directory to the search path. The directory is not added if +it doesn't exist when Python is started. However the location of the +user site directory and user base directory is stored in an internal +variable for distutils. + +The user site directory is added before the system site directories +but after Python's search paths and ``PYTHONPATH``. This setup allows +the user to install a different version of a package than the system +administrator but it prevents the user from accidently overwriting a +stdlib module. Stdlib modules can still be overwritten with +``PYTHONPATH``. + +For security reasons the user site directory is *not* added to +``sys.path`` when the effective user id is not equal to the process +user id [9]_. It prevents users from injecting Python code into suid +apps. + +The user site directory can be suppressed with a new option ``-s`` or +the environment variable ``PYTHONNOUSERSITE``. The feature can be +disabled globally by setting ``site.ENABLE_USER_SITE`` to the value +``False``. It must be set by editing ``site.py``. It can't be altered +``in sitecustomize.py`` or later. + +``distutils.command.install`` (setup.py install) gets a new argument +``--user`` to install packages in the user site directory. The required +directories are created on demand. + +``distutils.sysconfig`` will get methods to access the private variables +of site. (not yet implemented) + +The Windows updater needs to be updated, too. It should create an menu +item which opens the user site directory in a new explorer windows. + + +Backwards Compatibility +======================= + +TBD + + +Open Questions +============== + +* Are the directories for Windows, Mac and Unix fine? + +* Mac: Should framework and non-framework builds of Python use the + same directories? + +* The patch also adds a usecustomize hook to site. Is it useful and + should it stay? + +* Should the site package directory also be ignored if process gid != + effective gid? + +* Should the Windows installer add ``%APPDATA%/Python/Scripts`` to + ``PATH``? + + +Reference Implementation +======================== + +A reference implementation is available in the bug tracker. [4]_ + + +Copyright +========= + +This document has been placed in the public domain. + + +References +========== + +.. [1] Virtual Python + http://peak.telecommunity.com/DevCenter/EasyInstall#creating-a-virtual-python + +.. [2] Working Env + http://pypi.python.org/pypi/workingenv.py + http://blog.ianbicking.org/workingenv-revisited.html + +.. [3] Virtual Env + http://pypi.python.org/pypi/virtualenv + +.. [4] reference implementation + http://bugs.python.org/issue1799 + +.. [5] MSDN: CSIDL + http://msdn2.microsoft.com/en-us/library/bb762494.aspx + +.. [6] Initial suggestion for a per user site-packages directory + http://permalink.gmane.org/gmane.comp.python.devel/90902 + +.. [7] Suggestion of ~/.local/ + http://permalink.gmane.org/gmane.comp.python.devel/90925 + +.. [8] APPDATA discussion + http://permalink.gmane.org/gmane.comp.python.devel/90932 + +.. [9] Security concerns and -s option + http://permalink.gmane.org/gmane.comp.python.devel/91063 + +.. [10] Discussion about the bin directory + http://permalink.gmane.org/gmane.comp.python.devel/91095 + + +.. + Local Variables: + mode: indented-text + indent-tabs-mode: nil + sentence-end-double-space: t + fill-column: 70 + coding: utf-8 + End: From python-checkins at python.org Mon Jan 14 21:54:07 2008 From: python-checkins at python.org (christian.heimes) Date: Mon, 14 Jan 2008 21:54:07 +0100 (CET) Subject: [Python-checkins] r59956 - sandbox/trunk/pep370 Message-ID: <20080114205407.6FBDD1E4027@bag.python.org> Author: christian.heimes Date: Mon Jan 14 21:54:07 2008 New Revision: 59956 Added: sandbox/trunk/pep370/ - copied from r59955, python/trunk/ Log: Creating branch for PEP 370: per user site packages directory From python-checkins at python.org Mon Jan 14 22:11:23 2008 From: python-checkins at python.org (christian.heimes) Date: Mon, 14 Jan 2008 22:11:23 +0100 (CET) Subject: [Python-checkins] r59957 - in sandbox/trunk/pep370: Include/pydebug.h Lib/distutils/command/install.py Lib/site.py Lib/test/test_site.py Modules/main.c Python/pythonrun.c Python/sysmodule.c Message-ID: <20080114211123.EA4AB1E4036@bag.python.org> Author: christian.heimes Date: Mon Jan 14 22:11:23 2008 New Revision: 59957 Modified: sandbox/trunk/pep370/Include/pydebug.h sandbox/trunk/pep370/Lib/distutils/command/install.py sandbox/trunk/pep370/Lib/site.py sandbox/trunk/pep370/Lib/test/test_site.py sandbox/trunk/pep370/Modules/main.c sandbox/trunk/pep370/Python/pythonrun.c sandbox/trunk/pep370/Python/sysmodule.c Log: Applied latest patch for PEP 370. By the way I wasn't able to run Python until I've changed the subversion code in Python/sysmodule.c. The code doesn't like sandbox urls. Modified: sandbox/trunk/pep370/Include/pydebug.h ============================================================================== --- sandbox/trunk/pep370/Include/pydebug.h (original) +++ sandbox/trunk/pep370/Include/pydebug.h Mon Jan 14 22:11:23 2008 @@ -18,6 +18,7 @@ PyAPI_DATA(int) Py_IgnoreEnvironmentFlag; PyAPI_DATA(int) Py_DivisionWarningFlag; PyAPI_DATA(int) Py_DontWriteBytecodeFlag; +PyAPI_DATA(int) Py_NoUserSiteDirectory; /* _XXX Py_QnewFlag should go away in 3.0. It's true iff -Qnew is passed, on the command line, and is used in 2.2 by ceval.c to make all "/" divisions true divisions (which they will be in 3.0). */ Modified: sandbox/trunk/pep370/Lib/distutils/command/install.py ============================================================================== --- sandbox/trunk/pep370/Lib/distutils/command/install.py (original) +++ sandbox/trunk/pep370/Lib/distutils/command/install.py Mon Jan 14 22:11:23 2008 @@ -18,6 +18,8 @@ from distutils.util import convert_path, subst_vars, change_root from distutils.errors import DistutilsOptionError from glob import glob +from site import USER_BASE +from site import USER_SITE if sys.version < "2.2": WINDOWS_SCHEME = { @@ -51,7 +53,21 @@ 'scripts': '$base/bin', 'data' : '$base', }, + 'unix_user': { + 'purelib': '$usersite', + 'platlib': '$usersite', + 'headers': '$userbase/include/python$py_version_short/$dist_name', + 'scripts': '$userbase/bin', + 'data' : '$userbase', + }, 'nt': WINDOWS_SCHEME, + 'nt_user': { + 'purelib': '$usersite', + 'platlib': '$usersite', + 'headers': '$userbase/Python$py_version_nodot/Include/$dist_name', + 'scripts': '$userbase/Scripts', + 'data' : '$userbase', + }, 'mac': { 'purelib': '$base/Lib/site-packages', 'platlib': '$base/Lib/site-packages', @@ -59,13 +75,27 @@ 'scripts': '$base/Scripts', 'data' : '$base', }, + 'mac_user': { + 'purelib': '$usersite', + 'platlib': '$usersite', + 'headers': '$userbase/$py_version_short/include/$dist_name', + 'scripts': '$userbase/bin', + 'data' : '$userbase', + }, 'os2': { 'purelib': '$base/Lib/site-packages', 'platlib': '$base/Lib/site-packages', 'headers': '$base/Include/$dist_name', 'scripts': '$base/Scripts', 'data' : '$base', - } + }, + 'os2_home': { + 'purelib': '$usersite', + 'platlib': '$usersite', + 'headers': '$userbase/include/python$py_version_short/$dist_name', + 'scripts': '$userbase/bin', + 'data' : '$userbase', + }, } # The keys to an installation scheme; if any new types of files are to be @@ -86,6 +116,8 @@ "(Unix only) prefix for platform-specific files"), ('home=', None, "(Unix only) home directory to install under"), + ('user', None, + "install in user site-package '%s'" % USER_SITE), # Or, just set the base director(y|ies) ('install-base=', None, @@ -137,7 +169,7 @@ "filename in which to record list of installed files"), ] - boolean_options = ['compile', 'force', 'skip-build'] + boolean_options = ['compile', 'force', 'skip-build', 'user'] negative_opt = {'no-compile' : 'compile'} @@ -148,6 +180,7 @@ self.prefix = None self.exec_prefix = None self.home = None + self.user = 0 # These select only the installation base; it's up to the user to # specify the installation scheme (currently, that means supplying @@ -166,6 +199,8 @@ self.install_lib = None # set to either purelib or platlib self.install_scripts = None self.install_data = None + self.install_userbase = USER_BASE + self.install_usersite = USER_SITE self.compile = None self.optimize = None @@ -241,6 +276,11 @@ raise DistutilsOptionError, \ "must supply either home or prefix/exec-prefix -- not both" + if self.user and (self.prefix or self.exec_prefix or self.home or + self.install_base or self.install_platbase): + raise DistutilsOptionError("can't combine user with with prefix/" + "exec_prefix/home or install_(plat)base") + # Next, stuff that's wrong (or dubious) only on certain platforms. if os.name != "posix": if self.exec_prefix: @@ -276,10 +316,13 @@ 'dist_fullname': self.distribution.get_fullname(), 'py_version': py_version, 'py_version_short': py_version[0:3], + 'py_version_nodot': py_version[0] + py_version[2], 'sys_prefix': prefix, 'prefix': prefix, 'sys_exec_prefix': exec_prefix, 'exec_prefix': exec_prefix, + 'userbase': self.install_userbase, + 'usersite': self.install_usersite, } self.expand_basedirs() @@ -301,6 +344,10 @@ self.dump_dirs("post-expand_dirs()") + # Create directories in the home dir: + if self.user: + self.create_home_path() + # Pick the actual directory to install all modules to: either # install_purelib or install_platlib, depending on whether this # module distribution is pure or not. Of course, if the user @@ -315,7 +362,8 @@ # Convert directories from Unix /-separated syntax to the local # convention. self.convert_paths('lib', 'purelib', 'platlib', - 'scripts', 'data', 'headers') + 'scripts', 'data', 'headers', + 'userbase', 'usersite') # Well, we're not actually fully completely finalized yet: we still # have to deal with 'extra_path', which is the hack for allowing @@ -376,7 +424,10 @@ "installation scheme is incomplete") return - if self.home is not None: + if self.user: + self.install_base = self.install_platbase = self.install_userbase + self.select_scheme("unix_user") + elif self.home is not None: self.install_base = self.install_platbase = self.home self.select_scheme("unix_home") else: @@ -401,7 +452,10 @@ def finalize_other (self): # Windows and Mac OS for now - if self.home is not None: + if self.user: + self.install_base = self.install_platbase = self.install_userbase + self.select_scheme(os.name + "_user") + elif self.home is not None: self.install_base = self.install_platbase = self.home self.select_scheme("unix_home") else: @@ -431,7 +485,7 @@ for attr in attrs: val = getattr(self, attr) if val is not None: - if os.name == 'posix': + if os.name == 'posix' or os.name == 'nt': val = os.path.expanduser(val) val = subst_vars(val, self.config_vars) setattr(self, attr, val) @@ -496,6 +550,16 @@ attr = "install_" + name setattr(self, attr, change_root(self.root, getattr(self, attr))) + def create_home_path(self): + """Create directories under ~ + """ + if not self.user: + return + home = convert_path(os.path.expanduser("~")) + for name, path in self.config_vars.iteritems(): + if path.startswith(home) and not os.path.isdir(path): + self.debug_print("os.makedirs('%s', 0700)" % path) + os.makedirs(path, 0700) # -- Command execution methods ------------------------------------- Modified: sandbox/trunk/pep370/Lib/site.py ============================================================================== --- sandbox/trunk/pep370/Lib/site.py (original) +++ sandbox/trunk/pep370/Lib/site.py Mon Jan 14 22:11:23 2008 @@ -62,11 +62,21 @@ import os import __builtin__ +# Prefixes for site-packages; add additional prefixes like /usr/local here +PREFIXES = [sys.prefix, sys.exec_prefix] +# Enable per user site-packages directory +# set it to False to disable the feature or True to force the feature +ENABLE_USER_SITE = None +# for distutils.commands.install +USER_SITE = None +USER_BASE = None + def makepath(*paths): dir = os.path.abspath(os.path.join(*paths)) return dir, os.path.normcase(dir) + def abs__file__(): """Set all module' __file__ attribute to an absolute path""" for m in sys.modules.values(): @@ -77,6 +87,7 @@ except AttributeError: continue + def removeduppaths(): """ Remove duplicate entries from sys.path along with making them absolute""" @@ -105,6 +116,7 @@ s = os.path.join(os.path.dirname(sys.path[-1]), s) sys.path.append(s) + def _init_pathinfo(): """Return a set containing all existing directory entries from sys.path""" d = set() @@ -117,6 +129,7 @@ continue return d + def addpackage(sitedir, name, known_paths): """Process a .pth file within the site-packages directory: For each line in the file, either combine it with sitedir to a path @@ -132,11 +145,11 @@ f = open(fullname, "rU") except IOError: return - try: + with f: for line in f: if line.startswith("#"): continue - if line.startswith("import ") or line.startswith("import\t"): + if line.startswith(("import ", "import\t")): exec line continue line = line.rstrip() @@ -144,12 +157,11 @@ if not dircase in known_paths and os.path.exists(dir): sys.path.append(dir) known_paths.add(dircase) - finally: - f.close() if reset: known_paths = None return known_paths + def addsitedir(sitedir, known_paths=None): """Add 'sitedir' argument to sys.path if missing and handle .pth files in 'sitedir'""" @@ -165,48 +177,112 @@ names = os.listdir(sitedir) except os.error: return - names.sort() - for name in names: - if name.endswith(os.extsep + "pth"): - addpackage(sitedir, name, known_paths) + dotpth = os.extsep + "pth" + names = [name for name in names if name.endswith(dotpth)] + for name in sorted(names): + addpackage(sitedir, name, known_paths) if reset: known_paths = None return known_paths + +def check_enableusersite(): + """Check if user site directory is safe for inclusion + + The functions tests for the command line flag (including environment var), + process uid equal to effective uid. + + None: Disabled for security reasons + False: Disabled by user (command line option) + True: Safe and enabled + """ + if sys.flags.no_user_site: + return False + + if hasattr(os, "getuid") and hasattr(os, "geteuid"): + # check process uid == effective uid + if os.geteuid() != os.getuid(): + return None + + return True + + +def addusersitepackages(known_paths): + """Add a per user site-package to sys.path + + Each user has its own python directory with site-packages in the + home directory. _global_userdirs contains (basedir, user site-packages) + although the directories may not exist. + + basedir is the root directory for all Python versions, userdir is the + user specific site-packages directory. userdir/.. can be used for + configuration data. + """ + global USER_BASE, USER_SITE + def joinuser(*args): + return os.path.expanduser(os.path.join(*args)) + + #if sys.platform in ('os2emx', 'riscos'): + # # Don't know what to put here + # USER_BASE = '' + # USER_SITE = '' + if sys.platform == "darwin": + USER_BASE = joinuser("~", "Library", "Python") + USER_SITE = os.path.join(USER_BASE, sys.version[:3], + "site-packages") + elif os.name == "nt": + base = os.environ.get("APPDATA") or "~" + USER_BASE = joinuser(base, "Python") + USER_SITE = os.path.join(USER_BASE, + "Python" + sys.version[0] + sys.version[2], + "site-packages") + else: + USER_BASE = joinuser("~", ".local") + USER_SITE = os.path.join(USER_BASE, "lib", + "python" + sys.version[:3], + "site-packages") + + if os.path.isdir(USER_SITE): + addsitedir(USER_SITE, known_paths) + return known_paths + + def addsitepackages(known_paths): """Add site-packages (and possibly site-python) to sys.path""" - prefixes = [sys.prefix] - if sys.exec_prefix != sys.prefix: - prefixes.append(sys.exec_prefix) - for prefix in prefixes: - if prefix: - if sys.platform in ('os2emx', 'riscos'): - sitedirs = [os.path.join(prefix, "Lib", "site-packages")] - elif os.sep == '/': - sitedirs = [os.path.join(prefix, - "lib", - "python" + sys.version[:3], - "site-packages"), - os.path.join(prefix, "lib", "site-python")] - else: - sitedirs = [prefix, os.path.join(prefix, "lib", "site-packages")] - if sys.platform == 'darwin': - # for framework builds *only* we add the standard Apple - # locations. Currently only per-user, but /Library and - # /Network/Library could be added too - if 'Python.framework' in prefix: - home = os.environ.get('HOME') - if home: - sitedirs.append( - os.path.join(home, - 'Library', - 'Python', - sys.version[:3], - 'site-packages')) - for sitedir in sitedirs: - if os.path.isdir(sitedir): - addsitedir(sitedir, known_paths) - return None + sitedirs = [] + seen = [] + + for prefix in PREFIXES: + if not prefix or prefix in seen: + continue + seen.append(prefix) + + if sys.platform in ('os2emx', 'riscos'): + sitedirs.append(os.path.join(prefix, "Lib", "site-packages")) + elif os.sep == '/': + sitedirs.append(os.path.join(prefix, "lib", + "python" + sys.version[:3], + "site-packages")) + sitedirs.append(os.path.join(prefix, "lib", "site-python")) + else: + sitedirs.append(prefix) + sitedirs.append(os.path.join(prefix, "lib", "site-packages")) + + #if sys.platform == "darwin": + # # for framework builds *only* we add the standard Apple + # # locations. Currently only per-user, but /Library and + # # /Network/Library could be added too + # if 'Python.framework' in prefix: + # sitedirs.append( + # os.path.expanduser( + # os.path.join("~", "Library", "Python", + # sys.version[:3], "site-packages"))) + + for sitedir in sitedirs: + if os.path.isdir(sitedir): + addsitedir(sitedir, known_paths) + + return known_paths def setBEGINLIBPATH(): @@ -393,13 +469,27 @@ pass +def execusercustomize(): + """Run custom user specific code, if available.""" + try: + import usercustomize + except ImportError: + pass + + def main(): + global ENABLE_USER_SITE + abs__file__() - paths_in_sys = removeduppaths() + known_paths = removeduppaths() if (os.name == "posix" and sys.path and os.path.basename(sys.path[-1]) == "Modules"): addbuilddir() - paths_in_sys = addsitepackages(paths_in_sys) + if ENABLE_USER_SITE is None: + ENABLE_USER_SITE = check_enableusersite() + if ENABLE_USER_SITE: + known_paths = addusersitepackages(known_paths) + known_paths = addsitepackages(known_paths) if sys.platform == 'os2emx': setBEGINLIBPATH() setquit() @@ -408,6 +498,8 @@ aliasmbcs() setencoding() execsitecustomize() + if ENABLE_USER_SITE: + execusercustomize() # Remove sys.setdefaultencoding() so that users cannot change the # encoding after initialization. The test for presence is needed when # this module is run as a script, because this code is executed twice. Modified: sandbox/trunk/pep370/Lib/test/test_site.py ============================================================================== --- sandbox/trunk/pep370/Lib/test/test_site.py (original) +++ sandbox/trunk/pep370/Lib/test/test_site.py Mon Jan 14 22:11:23 2008 @@ -11,6 +11,7 @@ import sys import encodings import tempfile +import subprocess # Need to make sure to not import 'site' if someone specified ``-S`` at the # command-line. Detect this by just making sure 'site' has not been imported # already. @@ -31,7 +32,7 @@ """Save a copy of sys.path""" self.sys_path = sys.path[:] - def tearDown(self): + """Restore sys.path""" sys.path = self.sys_path @@ -91,6 +92,16 @@ finally: pth_file.cleanup() + def test_s_option(self): + usersite = site.USER_SITE + self.assert_(usersite in sys.path) + cmd = [sys.executable, "-c", + "\"import sys; sys.exit('%s' in sys.path)\"" % usersite + ] + p = subprocess.Popen(cmd) + self.assertEqual(p.wait(), 0) + + class PthFile(object): """Helper class for handling testing of .pth files""" Modified: sandbox/trunk/pep370/Modules/main.c ============================================================================== --- sandbox/trunk/pep370/Modules/main.c (original) +++ sandbox/trunk/pep370/Modules/main.c Mon Jan 14 22:11:23 2008 @@ -40,7 +40,7 @@ static int orig_argc; /* command line options */ -#define BASE_OPTS "3Bc:dEhim:OQ:StuUvVW:xX?" +#define BASE_OPTS "3Bc:dEhim:OQ:sStuUvVW:xX?" #ifndef RISCOS #define PROGRAM_OPTS BASE_OPTS @@ -72,6 +72,7 @@ -O : optimize generated bytecode slightly; also PYTHONOPTIMIZE=x\n\ -OO : remove doc-strings in addition to the -O optimizations\n\ -Q arg : division options: -Qold (default), -Qwarn, -Qwarnall, -Qnew\n\ +-s : don't add user site directory to sys.path; also PYTHONNOUSERSITE\n\ -S : don't imply 'import site' on initialization\n\ -t : issue warnings about inconsistent tab usage (-tt: issue errors)\n\ "; @@ -345,6 +346,10 @@ Py_DontWriteBytecodeFlag++; break; + case 's': + Py_NoUserSiteDirectory++; + break; + case 'S': Py_NoSiteFlag++; break; @@ -415,6 +420,10 @@ (p = Py_GETENV("PYTHONUNBUFFERED")) && *p != '\0') unbuffered = 1; + if (!Py_NoUserSiteDirectory && + (p = Py_GETENV("PYTHONNOUSERSITE")) && *p != '\0') + Py_NoUserSiteDirectory = 1; + if (command == NULL && module == NULL && _PyOS_optind < argc && strcmp(argv[_PyOS_optind], "-") != 0) { Modified: sandbox/trunk/pep370/Python/pythonrun.c ============================================================================== --- sandbox/trunk/pep370/Python/pythonrun.c (original) +++ sandbox/trunk/pep370/Python/pythonrun.c Mon Jan 14 22:11:23 2008 @@ -81,6 +81,7 @@ on the command line, and is used in 2.2 by ceval.c to make all "/" divisions true divisions (which they will be in 2.3). */ int _Py_QnewFlag = 0; +int Py_NoUserSiteDirectory = 0; /* for -s and site.py */ /* Reference to 'warnings' module, to avoid importing it on the fly when the import lock may be held. See 683658/771097 Modified: sandbox/trunk/pep370/Python/sysmodule.c ============================================================================== --- sandbox/trunk/pep370/Python/sysmodule.c (original) +++ sandbox/trunk/pep370/Python/sysmodule.c Mon Jan 14 22:11:23 2008 @@ -979,6 +979,12 @@ return; python = strstr(headurl, "/python/"); + if (python) { + br_start = python + 8; + } + else if ((python = strstr(headurl, "/sandbox/")) != NULL) { + br_start = python + 9; + } if (!python) Py_FatalError("subversion keywords missing"); @@ -1006,8 +1012,10 @@ shortbranch[len] = '\0'; } else { - Py_FatalError("bad HeadURL"); - return; + /* Py_FatalError("bad HeadURL"); + return; */ + *branch = '\0'; + *shortbranch = '\0'; } @@ -1063,7 +1071,7 @@ {"interactive", "-i"}, {"optimize", "-O or -OO"}, {"dont_write_bytecode", "-B"}, - /* {"no_user_site", "-s"}, */ + {"no_user_site", "-s"}, {"no_site", "-S"}, {"ingnore_environment", "-E"}, {"tabcheck", "-t or -tt"}, @@ -1082,9 +1090,9 @@ flags__doc__, /* doc */ flags_fields, /* fields */ #ifdef RISCOS - 14 + 15 #else - 13 + 14 #endif }; @@ -1109,7 +1117,7 @@ SetFlag(Py_InteractiveFlag); SetFlag(Py_OptimizeFlag); SetFlag(Py_DontWriteBytecodeFlag); - /* SetFlag(Py_NoUserSiteDirectory); */ + SetFlag(Py_NoUserSiteDirectory); SetFlag(Py_NoSiteFlag); SetFlag(Py_IgnoreEnvironmentFlag); SetFlag(Py_TabcheckFlag); From martin at v.loewis.de Mon Jan 14 22:41:00 2008 From: martin at v.loewis.de (=?ISO-8859-1?Q?=22Martin_v=2E_L=F6wis=22?=) Date: Mon, 14 Jan 2008 22:41:00 +0100 Subject: [Python-checkins] [Python-Dev] r59947 - in python/trunk:Lib/test/test_structseq.py Misc/NEWS In-Reply-To: References: <20080114033353.2B9241E401A@bag.python.org> <001201c85661$181a4390$6800a8c0@RaymondLaptop1> <478B0DA1.3030405@v.loewis.de> Message-ID: <478BD6EC.3080600@v.loewis.de> > There seems to be a use case for it still, otherwise > collections.namedtuple wouldn't be added to 2.6, right? Perhaps; I'm not strongly opposed to keeping structseq. I'll work on making stat_result and struct_time regular fixed-size types, for 3.0. Regards, Martin From buildbot at python.org Mon Jan 14 23:02:56 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 14 Jan 2008 22:02:56 +0000 Subject: [Python-checkins] buildbot failure in ARM Linux trunk Message-ID: <20080114220257.12BFC1E4028@bag.python.org> The Buildbot has detected a new failure of ARM Linux trunk. Full details are available at: http://www.python.org/dev/buildbot/all/ARM%20Linux%20trunk/builds/0 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-linux-arm Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: amaury.forgeotdarc,andrew.kuchling,christian.heimes,facundo.batista,fred.drake,georg.brandl,guido.van.rossum,jeffrey.yasskin,ka-ping.yee,kurt.kaiser,lars.gustaebel,mark.dickinson,mark.summerfield,martin.v.loewis,neal.norwitz,raymond.hettinger,thomas.heller,vinay.sajip BUILD FAILED: failed test Excerpt from the test logfile: sincerely, -The Buildbot From nnorwitz at gmail.com Mon Jan 14 23:28:40 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Mon, 14 Jan 2008 17:28:40 -0500 Subject: [Python-checkins] Python Regression Test Failures refleak (8) Message-ID: <20080114222840.GA10031@python.psfb.org> test_opcodes leaked [-2, 0, 2] references, sum=0 test_doctest leaked [0, 0, -4] references, sum=-4 test_descrtut leaked [0, 4, -2] references, sum=2 test_funcattrs leaked [0, -2, 2] references, sum=0 test_functools leaked [-2, 0, 0] references, sum=-2 test_gc leaked [2, 0, 0] references, sum=2 test_gdbm leaked [0, -2, 0] references, sum=-2 test_genexps leaked [-2, 0, 2] references, sum=0 test_importhooks leaked [-2, 8, -6] references, sum=0 test_os leaked [0, 0, -2] references, sum=-2 test_poll leaked [0, 0, -2] references, sum=-2 test_urllib2_localnet leaked [-7, 13, 3] references, sum=9 test_weakref leaked [2, 0, 0] references, sum=2 From buildbot at python.org Mon Jan 14 23:29:50 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 14 Jan 2008 22:29:50 +0000 Subject: [Python-checkins] buildbot failure in x86 FreeBSD 3.0 Message-ID: <20080114222950.CF33E1E4028@bag.python.org> The Buildbot has detected a new failure of x86 FreeBSD 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20FreeBSD%203.0/builds/388 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-freebsd Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/usr/home/db3l/buildarea/3.0.bolen-freebsd/build/Lib/threading.py", line 485, in _bootstrap_inner self.run() File "/usr/home/db3l/buildarea/3.0.bolen-freebsd/build/Lib/threading.py", line 445, in run self._target(*self._args, **self._kwargs) File "/usr/home/db3l/buildarea/3.0.bolen-freebsd/build/Lib/bsddb/test/test_thread.py", line 80, in writerThread self._writerThread(*args, **kwargs) File "/usr/home/db3l/buildarea/3.0.bolen-freebsd/build/Lib/bsddb/test/test_thread.py", line 269, in _writerThread self.assertEqual(data, self.makeData(key)) File "/usr/home/db3l/buildarea/3.0.bolen-freebsd/build/Lib/unittest.py", line 325, in failUnlessEqual raise self.failureException(msg or '%r != %r' % (first, second)) AssertionError: None != b'0002-0002-0002-0002-0002' Traceback (most recent call last): File "/usr/home/db3l/buildarea/3.0.bolen-freebsd/build/Lib/threading.py", line 485, in _bootstrap_inner self.run() File "/usr/home/db3l/buildarea/3.0.bolen-freebsd/build/Lib/threading.py", line 445, in run self._target(*self._args, **self._kwargs) File "/usr/home/db3l/buildarea/3.0.bolen-freebsd/build/Lib/bsddb/test/test_thread.py", line 80, in writerThread self._writerThread(*args, **kwargs) File "/usr/home/db3l/buildarea/3.0.bolen-freebsd/build/Lib/bsddb/test/test_thread.py", line 269, in _writerThread self.assertEqual(data, self.makeData(key)) File "/usr/home/db3l/buildarea/3.0.bolen-freebsd/build/Lib/unittest.py", line 325, in failUnlessEqual raise self.failureException(msg or '%r != %r' % (first, second)) AssertionError: None != b'1001-1001-1001-1001-1001' Traceback (most recent call last): File "/usr/home/db3l/buildarea/3.0.bolen-freebsd/build/Lib/threading.py", line 485, in _bootstrap_inner self.run() File "/usr/home/db3l/buildarea/3.0.bolen-freebsd/build/Lib/threading.py", line 445, in run self._target(*self._args, **self._kwargs) File "/usr/home/db3l/buildarea/3.0.bolen-freebsd/build/Lib/bsddb/test/test_thread.py", line 80, in writerThread self._writerThread(*args, **kwargs) File "/usr/home/db3l/buildarea/3.0.bolen-freebsd/build/Lib/bsddb/test/test_thread.py", line 269, in _writerThread self.assertEqual(data, self.makeData(key)) File "/usr/home/db3l/buildarea/3.0.bolen-freebsd/build/Lib/unittest.py", line 325, in failUnlessEqual raise self.failureException(msg or '%r != %r' % (first, second)) AssertionError: None != b'2000-2000-2000-2000-2000' 1 test failed: test_asynchat ====================================================================== FAIL: test_close_when_done (test.test_asynchat.TestAsynchat) ---------------------------------------------------------------------- Traceback (most recent call last): File "/usr/home/db3l/buildarea/3.0.bolen-freebsd/build/Lib/test/test_asynchat.py", line 211, in test_close_when_done self.assertTrue(len(s.buffer) > 0) AssertionError: None ====================================================================== FAIL: test_close_when_done (test.test_asynchat.TestAsynchat_WithPoll) ---------------------------------------------------------------------- Traceback (most recent call last): File "/usr/home/db3l/buildarea/3.0.bolen-freebsd/build/Lib/test/test_asynchat.py", line 211, in test_close_when_done self.assertTrue(len(s.buffer) > 0) AssertionError: None sincerely, -The Buildbot From python-checkins at python.org Mon Jan 14 23:58:05 2008 From: python-checkins at python.org (raymond.hettinger) Date: Mon, 14 Jan 2008 23:58:05 +0100 (CET) Subject: [Python-checkins] r59959 - in python/trunk: Lib/zipfile.py Misc/NEWS Message-ID: <20080114225805.C6F451E4028@bag.python.org> Author: raymond.hettinger Date: Mon Jan 14 23:58:05 2008 New Revision: 59959 Modified: python/trunk/Lib/zipfile.py python/trunk/Misc/NEWS Log: Fix 1698398: Zipfile.printdir() crashed because the format string expected a tuple object of length six instead of a time.struct_time object. Modified: python/trunk/Lib/zipfile.py ============================================================================== --- python/trunk/Lib/zipfile.py (original) +++ python/trunk/Lib/zipfile.py Mon Jan 14 23:58:05 2008 @@ -710,7 +710,7 @@ """Print a table of contents for the zip file.""" print "%-46s %19s %12s" % ("File Name", "Modified ", "Size") for zinfo in self.filelist: - date = "%d-%02d-%02d %02d:%02d:%02d" % zinfo.date_time + date = "%d-%02d-%02d %02d:%02d:%02d" % zinfo.date_time[:6] print "%-46s %s %12d" % (zinfo.filename, date, zinfo.file_size) def testzip(self): @@ -961,7 +961,7 @@ the name of the file in the archive.""" if not isinstance(zinfo_or_arcname, ZipInfo): zinfo = ZipInfo(filename=zinfo_or_arcname, - date_time=time.localtime(time.time())) + date_time=time.localtime(time.time())[:6]) zinfo.compress_type = self.compression else: zinfo = zinfo_or_arcname Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Mon Jan 14 23:58:05 2008 @@ -363,6 +363,9 @@ Library ------- +- Issue #1698398 Zipfile.printdir() crashed because the format string + expected a tuple type of length six instead of time.struct_time object. + - Issue #1780: The Decimal constructor now accepts arbitrary leading and trailing whitespace when constructing from a string. Context.create_decimal no longer accepts trailing newlines. From python-checkins at python.org Tue Jan 15 00:02:51 2008 From: python-checkins at python.org (raymond.hettinger) Date: Tue, 15 Jan 2008 00:02:51 +0100 (CET) Subject: [Python-checkins] r59960 - in python/branches/release25-maint: Lib/zipfile.py Misc/NEWS Message-ID: <20080114230251.E5F711E4028@bag.python.org> Author: raymond.hettinger Date: Tue Jan 15 00:02:51 2008 New Revision: 59960 Modified: python/branches/release25-maint/Lib/zipfile.py python/branches/release25-maint/Misc/NEWS Log: Fix 1698398: Zipfile.printdir() crashed because the format string expected a tuple object of length six instead of a time.struct_time object. Modified: python/branches/release25-maint/Lib/zipfile.py ============================================================================== --- python/branches/release25-maint/Lib/zipfile.py (original) +++ python/branches/release25-maint/Lib/zipfile.py Tue Jan 15 00:02:51 2008 @@ -445,7 +445,7 @@ """Print a table of contents for the zip file.""" print "%-46s %19s %12s" % ("File Name", "Modified ", "Size") for zinfo in self.filelist: - date = "%d-%02d-%02d %02d:%02d:%02d" % zinfo.date_time + date = "%d-%02d-%02d %02d:%02d:%02d" % zinfo.date_time[:6] print "%-46s %s %12d" % (zinfo.filename, date, zinfo.file_size) def testzip(self): @@ -606,7 +606,7 @@ the name of the file in the archive.""" if not isinstance(zinfo_or_arcname, ZipInfo): zinfo = ZipInfo(filename=zinfo_or_arcname, - date_time=time.localtime(time.time())) + date_time=time.localtime(time.time())[:6]) zinfo.compress_type = self.compression else: zinfo = zinfo_or_arcname Modified: python/branches/release25-maint/Misc/NEWS ============================================================================== --- python/branches/release25-maint/Misc/NEWS (original) +++ python/branches/release25-maint/Misc/NEWS Tue Jan 15 00:02:51 2008 @@ -414,6 +414,9 @@ - Bug #1653736: Fix signature of time_isoformat. +- Issue #1698398 Zipfile.printdir() crashed because the format string + expected a tuple type of length six instead of time.struct_time object. + - operator.count() now raises an OverflowError when the count reaches sys.maxint. - Bug #1575169: operator.isSequenceType() now returns False for subclasses of dict. From buildbot at python.org Tue Jan 15 00:16:27 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 14 Jan 2008 23:16:27 +0000 Subject: [Python-checkins] buildbot failure in ARM Linux 3.0 Message-ID: <20080114231627.59BAA1E4039@bag.python.org> The Buildbot has detected a new failure of ARM Linux 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/ARM%20Linux%203.0/builds/0 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-linux-arm Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: alexandre.vassalotti,amaury.forgeotdarc,christian.heimes,eric.smith,georg.brandl,guido.van.rossum,jeffrey.yasskin,kurt.kaiser,raymond.hettinger BUILD FAILED: failed failed slave lost sincerely, -The Buildbot From buildbot at python.org Tue Jan 15 00:22:55 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 14 Jan 2008 23:22:55 +0000 Subject: [Python-checkins] buildbot failure in ARM Linux EABI trunk Message-ID: <20080114232256.222451E4028@bag.python.org> The Buildbot has detected a new failure of ARM Linux EABI trunk. Full details are available at: http://www.python.org/dev/buildbot/all/ARM%20Linux%20EABI%20trunk/builds/1 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-linux-armeabi Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: thomas.heller BUILD FAILED: failed failed slave lost sincerely, -The Buildbot From buildbot at python.org Tue Jan 15 00:44:08 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 14 Jan 2008 23:44:08 +0000 Subject: [Python-checkins] buildbot failure in x86 gentoo 2.5 Message-ID: <20080114234408.C52401E4029@bag.python.org> The Buildbot has detected a new failure of x86 gentoo 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20gentoo%202.5/builds/500 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-x86 Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_urllib2net make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Tue Jan 15 00:44:18 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 14 Jan 2008 23:44:18 +0000 Subject: [Python-checkins] buildbot failure in x86 mvlgcc 2.5 Message-ID: <20080114234418.600A21E4029@bag.python.org> The Buildbot has detected a new failure of x86 mvlgcc 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20mvlgcc%202.5/builds/376 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-linux Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_urllib2net make: *** [buildbottest] Fehler 1 sincerely, -The Buildbot From buildbot at python.org Tue Jan 15 00:47:12 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 14 Jan 2008 23:47:12 +0000 Subject: [Python-checkins] buildbot failure in PPC64 Debian trunk Message-ID: <20080114234713.0C14B1E4028@bag.python.org> The Buildbot has detected a new failure of PPC64 Debian trunk. Full details are available at: http://www.python.org/dev/buildbot/all/PPC64%20Debian%20trunk/builds/102 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: andrew.kuchling,raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_xmlrpc make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Tue Jan 15 00:54:11 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 14 Jan 2008 23:54:11 +0000 Subject: [Python-checkins] buildbot failure in x86 FreeBSD trunk Message-ID: <20080114235411.9E5921E4028@bag.python.org> The Buildbot has detected a new failure of x86 FreeBSD trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20FreeBSD%20trunk/builds/397 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-freebsd Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: andrew.kuchling,raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_signal sincerely, -The Buildbot From python-checkins at python.org Tue Jan 15 02:29:16 2008 From: python-checkins at python.org (andrew.kuchling) Date: Tue, 15 Jan 2008 02:29:16 +0100 (CET) Subject: [Python-checkins] r59961 - in python/trunk: Doc/library/sys.rst Lib/test/test_sys.py Python/sysmodule.c Message-ID: <20080115012916.D79F91E4006@bag.python.org> Author: andrew.kuchling Date: Tue Jan 15 02:29:16 2008 New Revision: 59961 Modified: python/trunk/Doc/library/sys.rst python/trunk/Lib/test/test_sys.py python/trunk/Python/sysmodule.c Log: Typo fixes Modified: python/trunk/Doc/library/sys.rst ============================================================================== --- python/trunk/Doc/library/sys.rst (original) +++ python/trunk/Doc/library/sys.rst Tue Jan 15 02:29:16 2008 @@ -266,7 +266,7 @@ +------------------------------+------------------------------------------+ | :const:`no_site` | -S | +------------------------------+------------------------------------------+ - | :const:`ingnore_environment` | -E | + | :const:`ignore_environment` | -E | +------------------------------+------------------------------------------+ | :const:`tabcheck` | -t or -tt | +------------------------------+------------------------------------------+ Modified: python/trunk/Lib/test/test_sys.py ============================================================================== --- python/trunk/Lib/test/test_sys.py (original) +++ python/trunk/Lib/test/test_sys.py Tue Jan 15 02:29:16 2008 @@ -356,7 +356,7 @@ self.failUnless(sys.flags) attrs = ("debug", "py3k_warning", "division_warning", "division_new", "inspect", "interactive", "optimize", "dont_write_bytecode", - "no_site", "ingnore_environment", "tabcheck", "verbose", + "no_site", "ignore_environment", "tabcheck", "verbose", "unicode") for attr in attrs: self.assert_(hasattr(sys.flags, attr), attr) Modified: python/trunk/Python/sysmodule.c ============================================================================== --- python/trunk/Python/sysmodule.c (original) +++ python/trunk/Python/sysmodule.c Tue Jan 15 02:29:16 2008 @@ -1065,11 +1065,11 @@ {"dont_write_bytecode", "-B"}, /* {"no_user_site", "-s"}, */ {"no_site", "-S"}, - {"ingnore_environment", "-E"}, + {"ignore_environment", "-E"}, {"tabcheck", "-t or -tt"}, {"verbose", "-v"}, #ifdef RISCOS - {"ricos_wimp", "???"}, + {"riscos_wimp", "???"}, #endif /* {"unbuffered", "-u"}, */ {"unicode", "-U"}, From python-checkins at python.org Tue Jan 15 02:29:44 2008 From: python-checkins at python.org (andrew.kuchling) Date: Tue, 15 Jan 2008 02:29:44 +0100 (CET) Subject: [Python-checkins] r59962 - python/trunk/Doc/library/test.rst Message-ID: <20080115012944.587F61E4006@bag.python.org> Author: andrew.kuchling Date: Tue Jan 15 02:29:44 2008 New Revision: 59962 Modified: python/trunk/Doc/library/test.rst Log: Markup fix Modified: python/trunk/Doc/library/test.rst ============================================================================== --- python/trunk/Doc/library/test.rst (original) +++ python/trunk/Doc/library/test.rst Tue Jan 15 02:29:44 2008 @@ -302,7 +302,7 @@ This is a context manager than runs the :keyword:`with` statement body using a :class:`StringIO.StringIO` object as sys.stdout. That object can be - retrieved using the ``as`` clause of the with statement. + retrieved using the ``as`` clause of the :keyword:`with` statement. Example use:: From lists at cheimes.de Tue Jan 15 02:37:12 2008 From: lists at cheimes.de (Christian Heimes) Date: Tue, 15 Jan 2008 02:37:12 +0100 Subject: [Python-checkins] r59961 - in python/trunk: Doc/library/sys.rst Lib/test/test_sys.py Python/sysmodule.c In-Reply-To: <20080115012916.D79F91E4006@bag.python.org> References: <20080115012916.D79F91E4006@bag.python.org> Message-ID: <478C0E48.4060704@cheimes.de> andrew.kuchling wrote: > Author: andrew.kuchling > Date: Tue Jan 15 02:29:16 2008 > New Revision: 59961 > > Modified: > python/trunk/Doc/library/sys.rst > python/trunk/Lib/test/test_sys.py > python/trunk/Python/sysmodule.c > Log: > Typo fixes > > Modified: python/trunk/Doc/library/sys.rst > ============================================================================== > --- python/trunk/Doc/library/sys.rst (original) > +++ python/trunk/Doc/library/sys.rst Tue Jan 15 02:29:16 2008 > @@ -266,7 +266,7 @@ > +------------------------------+------------------------------------------+ > | :const:`no_site` | -S | > +------------------------------+------------------------------------------+ > - | :const:`ingnore_environment` | -E | > + | :const:`ignore_environment` | -E | > +------------------------------+------------------------------------------+ > | :const:`tabcheck` | -t or -tt | > +------------------------------+------------------------------------------+ > > Modified: python/trunk/Lib/test/test_sys.py > ============================================================================== > --- python/trunk/Lib/test/test_sys.py (original) > +++ python/trunk/Lib/test/test_sys.py Tue Jan 15 02:29:16 2008 > @@ -356,7 +356,7 @@ > self.failUnless(sys.flags) > attrs = ("debug", "py3k_warning", "division_warning", "division_new", > "inspect", "interactive", "optimize", "dont_write_bytecode", > - "no_site", "ingnore_environment", "tabcheck", "verbose", > + "no_site", "ignore_environment", "tabcheck", "verbose", > "unicode") > for attr in attrs: > self.assert_(hasattr(sys.flags, attr), attr) > > Modified: python/trunk/Python/sysmodule.c > ============================================================================== > --- python/trunk/Python/sysmodule.c (original) > +++ python/trunk/Python/sysmodule.c Tue Jan 15 02:29:16 2008 > @@ -1065,11 +1065,11 @@ > {"dont_write_bytecode", "-B"}, > /* {"no_user_site", "-s"}, */ > {"no_site", "-S"}, > - {"ingnore_environment", "-E"}, > + {"ignore_environment", "-E"}, > {"tabcheck", "-t or -tt"}, > {"verbose", "-v"}, > #ifdef RISCOS > - {"ricos_wimp", "???"}, > + {"riscos_wimp", "???"}, > #endif > /* {"unbuffered", "-u"}, */ > {"unicode", "-U"}, Wow, it's fascinating how far a bug can travel with copy 'n paste programming. O:-) Christian From lists at cheimes.de Tue Jan 15 02:37:12 2008 From: lists at cheimes.de (Christian Heimes) Date: Tue, 15 Jan 2008 02:37:12 +0100 Subject: [Python-checkins] r59961 - in python/trunk: Doc/library/sys.rst Lib/test/test_sys.py Python/sysmodule.c In-Reply-To: <20080115012916.D79F91E4006@bag.python.org> References: <20080115012916.D79F91E4006@bag.python.org> Message-ID: <478C0E48.4060704@cheimes.de> andrew.kuchling wrote: > Author: andrew.kuchling > Date: Tue Jan 15 02:29:16 2008 > New Revision: 59961 > > Modified: > python/trunk/Doc/library/sys.rst > python/trunk/Lib/test/test_sys.py > python/trunk/Python/sysmodule.c > Log: > Typo fixes > > Modified: python/trunk/Doc/library/sys.rst > ============================================================================== > --- python/trunk/Doc/library/sys.rst (original) > +++ python/trunk/Doc/library/sys.rst Tue Jan 15 02:29:16 2008 > @@ -266,7 +266,7 @@ > +------------------------------+------------------------------------------+ > | :const:`no_site` | -S | > +------------------------------+------------------------------------------+ > - | :const:`ingnore_environment` | -E | > + | :const:`ignore_environment` | -E | > +------------------------------+------------------------------------------+ > | :const:`tabcheck` | -t or -tt | > +------------------------------+------------------------------------------+ > > Modified: python/trunk/Lib/test/test_sys.py > ============================================================================== > --- python/trunk/Lib/test/test_sys.py (original) > +++ python/trunk/Lib/test/test_sys.py Tue Jan 15 02:29:16 2008 > @@ -356,7 +356,7 @@ > self.failUnless(sys.flags) > attrs = ("debug", "py3k_warning", "division_warning", "division_new", > "inspect", "interactive", "optimize", "dont_write_bytecode", > - "no_site", "ingnore_environment", "tabcheck", "verbose", > + "no_site", "ignore_environment", "tabcheck", "verbose", > "unicode") > for attr in attrs: > self.assert_(hasattr(sys.flags, attr), attr) > > Modified: python/trunk/Python/sysmodule.c > ============================================================================== > --- python/trunk/Python/sysmodule.c (original) > +++ python/trunk/Python/sysmodule.c Tue Jan 15 02:29:16 2008 > @@ -1065,11 +1065,11 @@ > {"dont_write_bytecode", "-B"}, > /* {"no_user_site", "-s"}, */ > {"no_site", "-S"}, > - {"ingnore_environment", "-E"}, > + {"ignore_environment", "-E"}, > {"tabcheck", "-t or -tt"}, > {"verbose", "-v"}, > #ifdef RISCOS > - {"ricos_wimp", "???"}, > + {"riscos_wimp", "???"}, > #endif > /* {"unbuffered", "-u"}, */ > {"unicode", "-U"}, Wow, it's fascinating how far a bug can travel with copy 'n paste programming. O:-) Christian From python-checkins at python.org Tue Jan 15 02:47:33 2008 From: python-checkins at python.org (andrew.kuchling) Date: Tue, 15 Jan 2008 02:47:33 +0100 (CET) Subject: [Python-checkins] r59963 - python/trunk/Doc/whatsnew/2.6.rst Message-ID: <20080115014733.7FE871E4006@bag.python.org> Author: andrew.kuchling Date: Tue Jan 15 02:47:32 2008 New Revision: 59963 Modified: python/trunk/Doc/whatsnew/2.6.rst Log: Add many items Modified: python/trunk/Doc/whatsnew/2.6.rst ============================================================================== --- python/trunk/Doc/whatsnew/2.6.rst (original) +++ python/trunk/Doc/whatsnew/2.6.rst Tue Jan 15 02:47:32 2008 @@ -426,6 +426,29 @@ .. ====================================================================== +.. :: + + .. _pep-0370: + + PEP 370: XXX + ===================================================== + + When you run Python, the module search page ``sys.modules`` usually + includes a directory whose path ends in ``"site-packages"``. This + directory is intended to hold locally-installed packages available to + all users on a machine or using a particular site installation. + + Python 2.6 introduces a convention for user-specific site directories. + + .. seealso:: + + :pep:`370` - XXX + + PEP written by XXX; implemented by Christian Heimes. + + +.. ====================================================================== + .. _pep-3110: PEP 3110: Exception-Handling Changes @@ -650,6 +673,16 @@ Optimizations ------------- +* Type objects now have a cache of methods that can reduc + the amount of work required to find the correct method implementation + for a particular class; the interpreter may not need to traverse base + classes + + (Original optimization implemented by Armin Rigo, updated for + Python 2.6 by Kevin Jacobs.) + + .. % Patch 1700288 + * All of the functions in the :mod:`struct` module have been rewritten in C, thanks to work at the Need For Speed sprint. (Contributed by Raymond Hettinger.) @@ -700,6 +733,11 @@ >>> v2 variable(id=1, name='amplitude', type='int', size=4) + Where the new :class:`namedtuple` type proved suitable, the standard + library has been modified to return them. For example, + the :meth:`Decimal.as_tuple` method now returns a named tuple with + :attr:`sign`, :attr:`digits`, and :attr:`exponent` fields. + (Contributed by Raymond Hettinger.) * Another change to the :mod:`collections` module is that the @@ -758,7 +796,17 @@ >>> Decimal(1000).log10() Decimal("3") - (Implemented by Facundo Batista and Mark Dickinson.) + The :meth:`as_tuple` method of :class:`Decimal` objects now returns a + named tuple with :attr:`sign`, :attr:`digits`, and :attr:`exponent` fields. + + (Implemented by Facundo Batista and Mark Dickinson. Named tuple + support added by Raymond Hettinger.) + +* The :mod:`difflib` module's :class:`SequenceMatcher` class + now returns named tuples representing matches. + In addition to behaving like tuples, the returned values + also have :attr:`a`, :attr:`b`, and :attr:`size` attributes. + (Contributed by Raymond Hettinger.) * An optional ``timeout`` parameter was added to the :class:`ftplib.FTP` class constructor as well as the :meth:`connect` @@ -795,6 +843,12 @@ class constructors, specifying a timeout measured in seconds. (Added by Facundo Batista.) +* Most of the :mod:`inspect` module's functions, such as + :func:`getmoduleinfo` and :func:`getargs`, now return named tuples. + In addition to behaving like tuples, the elements of the return value + can also be accessed as attributes. + (Contributed by Raymond Hettinger.) + * A new function in the :mod:`itertools` module: ``izip_longest(iter1, iter2, ...[, fillvalue])`` makes tuples from each of the elements; if some of the iterables are shorter than others, the missing values are set to *fillvalue*. @@ -891,6 +945,13 @@ .. Issue 1727780 +* Long regular expression searches carried out by the :mod:`re` + module will now check for signals being delivered, so especially + long searches can now be interrupted. + (Contributed by Josh Hoyt and Ralf Schmitt.) + + .. % Patch 846388 + * The :mod:`rgbimg` module has been removed. * The :mod:`sets` module has been deprecated; it's better to @@ -934,6 +995,13 @@ .. Patch #957003 +* The :mod:`socket` module now supports TIPC (http://tipc.sf.net), + a high-performance non-IP-based protocol designed for use in clustered + environments. TIPC addresses are 4- or 5-tuples. + (Contributed by Alberto Bertogli.) + + .. Patch #1646 + * A new variable in the :mod:`sys` module, :attr:`float_info`, is an object containing information about the platform's floating-point support @@ -945,6 +1013,21 @@ .. Patch 1534 + Information about the command-line arguments supplied to the Python + interpreter are available as attributes of a ``sys.flags`` named + tuple. For example, the :attr:`verbose` attribute is true if Python + was executed in verbose mode, :attr:`debug` is true in debugging mode, etc. + These attributes are all read-only. + (Contributed by Christian Heimes.) + + The :attr:`dont_write_bytecode` variable controls whether Python + writes any :file:`.pyc` or :file:`.pyo` files on importing a module. + If this variable is true, the compiled files are not written. The + variable can be set by Python code, by supplying the :option:`-B` + switch, or by setting the :envvar:`PYTHONDONTWRITEBYTECODE` + environment variable to any non-empty string when running the Python + interpreter. + * The :mod:`tarfile` module now supports POSIX.1-2001 (pax) and POSIX.1-1988 (ustar) format tarfiles, in addition to the GNU tar format that was already supported. The default format @@ -1061,6 +1144,22 @@ information. (Contributed by Alan McIntyre as part of his project for Google's Summer of Code 2007.) +* The :mod:`zipfile` module's :class:`ZipFile` class now has + :meth:`extract` and :meth:`extractall` methods that will unpack + a single file or all the files in the archive to the current directory, or + to a specified directory:: + + z = zipfile.ZipFile('python-251.zip') + + # Unpack a single file, writing it relative to the /tmp directory. + z.extract('Python/sysmodule.c', '/tmp') + + # Unpack all the files in the archive. + z.extractall() + + (Contributed by Alan McIntyre.) + .. % Patch 467924 + .. ====================================================================== .. whole new modules get described in subsections here @@ -1143,7 +1242,12 @@ value, as does the :func:`getwche` function. The :func:`putwch` function takes a Unicode character and writes it to the console. -Platform-specific changes go here. +* The :mod:`_winreg` module now has a function, + :func:`ExpandEnvironmentStrings`, + that expands environment variable references such as ``%NAME%`` + in an input string. The handle objects provided by this + module now support the context protocol, so they can be used + in :keyword:`with` statements. .. ====================================================================== @@ -1153,14 +1257,21 @@ Other Changes and Fixes ======================= -As usual, there were a bunch of other improvements and bugfixes scattered -throughout the source tree. A search through the change logs finds there were -XXX patches applied and YYY bugs fixed between Python 2.5 and 2.6. Both figures -are likely to be underestimates. +As usual, there were a bunch of other improvements and bugfixes +scattered throughout the source tree. A search through the change +logs finds there were XXX patches applied and YYY bugs fixed between +Python 2.5 and 2.6. Both figures are likely to be underestimates. Some of the more notable changes are: -* Details will go here. +* It's now possible to prevent Python from writing any :file:`.pyc` + or :file:`.pyo` files by either supplying the :option:`-B` switch + or setting the :envvar:`PYTHONDONTWRITEBYTECODE` environment variable + to any non-empty string when running the Python interpreter. These + are used to set a :attr:`dont_write_bytecode` variable in the + :mod:`sys` module. Python code can change this variable to + control whether bytecode files are subsequently written. + (Contributed by Neal Norwitz and Georg Brandl.) .. ====================================================================== @@ -1177,6 +1288,19 @@ before adding elements from the iterable. This change makes the behavior match that of ``list.__init__()``. +* The :class:`Decimal` constructor now accepts leading and trailing + whitespace when passed a string. Previously it would raise an + :exc:`InvalidOperation` exception. On the other hand, the + :meth:`create_decimal` method of :class:`Context` objects now + explicitly disallows extra whitespace, raising a + :exc:`ConversionSyntax` exception. + +* Due to an implementation accident, if you passed a file path to + the built-in :func:`__import__` function, it would actually import + the specified file. This was never intended to work, however, and + the implementation now explicitly checks for this case and raises + an :exc:`ImportError`. + * The :mod:`socket` module exception :exc:`socket.error` now inherits from :exc:`IOError`. Previously it wasn't a subclass of :exc:`StandardError` but now it is, through :exc:`IOError`. From python-checkins at python.org Tue Jan 15 02:55:32 2008 From: python-checkins at python.org (andrew.kuchling) Date: Tue, 15 Jan 2008 02:55:32 +0100 (CET) Subject: [Python-checkins] r59964 - python/trunk/Doc/whatsnew/2.6.rst Message-ID: <20080115015532.BEFE81E4006@bag.python.org> Author: andrew.kuchling Date: Tue Jan 15 02:55:32 2008 New Revision: 59964 Modified: python/trunk/Doc/whatsnew/2.6.rst Log: Repair unfinished sentence Modified: python/trunk/Doc/whatsnew/2.6.rst ============================================================================== --- python/trunk/Doc/whatsnew/2.6.rst (original) +++ python/trunk/Doc/whatsnew/2.6.rst Tue Jan 15 02:55:32 2008 @@ -675,9 +675,11 @@ * Type objects now have a cache of methods that can reduc the amount of work required to find the correct method implementation - for a particular class; the interpreter may not need to traverse base - classes - + for a particular class; once cached, the interpreter doesn't need to + traverse base classes to figure out the right method to call. + The cache is cleared if a base class or the class itself is modified, + so the cache should remain correct even in the face of Python's dynamic + nature. (Original optimization implemented by Armin Rigo, updated for Python 2.6 by Kevin Jacobs.) From lists at cheimes.de Tue Jan 15 03:31:40 2008 From: lists at cheimes.de (Christian Heimes) Date: Tue, 15 Jan 2008 03:31:40 +0100 Subject: [Python-checkins] r59963 - python/trunk/Doc/whatsnew/2.6.rst In-Reply-To: <20080115014733.7FE871E4006@bag.python.org> References: <20080115014733.7FE871E4006@bag.python.org> Message-ID: <478C1B0C.3050306@cheimes.de> andrew.kuchling wrote: > +.. :: > + > + .. _pep-0370: > + > + PEP 370: XXX > + ===================================================== > + > + When you run Python, the module search page ``sys.modules`` usually > + includes a directory whose path ends in ``"site-packages"``. This > + directory is intended to hold locally-installed packages available to > + all users on a machine or using a particular site installation. > + > + Python 2.6 introduces a convention for user-specific site directories. > + > + .. seealso:: > + > + :pep:`370` - XXX > + > + PEP written by XXX; implemented by Christian Heimes. > + > + > +.. ====================================================================== > + Thanks for the future documentation but the PEP hasn't been accepted yet. :) Christian From python-checkins at python.org Tue Jan 15 04:02:37 2008 From: python-checkins at python.org (raymond.hettinger) Date: Tue, 15 Jan 2008 04:02:37 +0100 (CET) Subject: [Python-checkins] r59967 - in python/trunk: Lib/test/test_structseq.py Misc/ACKS Misc/NEWS Objects/structseq.c Message-ID: <20080115030237.B4F651E4006@bag.python.org> Author: raymond.hettinger Date: Tue Jan 15 04:02:37 2008 New Revision: 59967 Modified: python/trunk/Lib/test/test_structseq.py python/trunk/Misc/ACKS python/trunk/Misc/NEWS python/trunk/Objects/structseq.c Log: Issue 1820: structseq objects did not work with the % formatting operator or isinstance(t, tuple). Orignal patch (without tests) by Leif Walsh. Modified: python/trunk/Lib/test/test_structseq.py ============================================================================== --- python/trunk/Lib/test/test_structseq.py (original) +++ python/trunk/Lib/test/test_structseq.py Tue Jan 15 04:02:37 2008 @@ -26,6 +26,12 @@ for i in xrange(-len(t), len(t)-1): self.assertEqual(t[i], astuple[i]) + def test_tuple_subclass(self): + # Issue 1820 + t = time.localtime() + s = ('%s ' * len(t)) % t # This used to fail because t was not a tuple subclass + self.assert_(isinstance(t, tuple)) + def test_repr(self): t = time.gmtime() self.assert_(repr(t)) Modified: python/trunk/Misc/ACKS ============================================================================== --- python/trunk/Misc/ACKS (original) +++ python/trunk/Misc/ACKS Tue Jan 15 04:02:37 2008 @@ -686,6 +686,7 @@ Charles Waldman Richard Walker Larry Wall +Leif Walsh Greg Ward Barry Warsaw Steve Waterbury Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Tue Jan 15 04:02:37 2008 @@ -975,6 +975,10 @@ Extension Modules ----------------- +- Issue 1820: structseq objects did not subclass from tuple so they did + not pass isinstance(t, tuple) tests and they could not be passed to + the % string formatting operator as an input tuple. + - _winreg's HKEY object has gained __enter__ and __exit__ methods to support the context manager protocol. The _winreg module also gained a new function ``ExpandEnvironmentStrings`` to expand REG_EXPAND_SZ keys. Modified: python/trunk/Objects/structseq.c ============================================================================== --- python/trunk/Objects/structseq.c (original) +++ python/trunk/Objects/structseq.c Tue Jan 15 04:02:37 2008 @@ -460,7 +460,7 @@ structseq_methods, /* tp_methods */ NULL, /* tp_members */ 0, /* tp_getset */ - 0, /* tp_base */ + &PyTuple_Type, /* tp_base */ 0, /* tp_dict */ 0, /* tp_descr_get */ 0, /* tp_descr_set */ From python-checkins at python.org Tue Jan 15 04:07:42 2008 From: python-checkins at python.org (raymond.hettinger) Date: Tue, 15 Jan 2008 04:07:42 +0100 (CET) Subject: [Python-checkins] r59968 - python/trunk/Doc/glossary.rst Message-ID: <20080115030742.648F01E4006@bag.python.org> Author: raymond.hettinger Date: Tue Jan 15 04:07:42 2008 New Revision: 59968 Modified: python/trunk/Doc/glossary.rst Log: Tighten the definition of a named tuple. Modified: python/trunk/Doc/glossary.rst ============================================================================== --- python/trunk/Doc/glossary.rst (original) +++ python/trunk/Doc/glossary.rst Tue Jan 15 04:07:42 2008 @@ -340,7 +340,7 @@ also :term:`immutable`. named tuple - Any tuple-like class whose indexable fields are also accessible with + Any tuple subclass whose indexable fields are also accessible with named attributes (for example, :func:`time.localtime` returns a tuple-like object where the *year* is accessible either with an index such as ``t[0]`` or with a named attribute like ``t.tm_year``). From buildbot at python.org Tue Jan 15 04:08:40 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 15 Jan 2008 03:08:40 +0000 Subject: [Python-checkins] buildbot failure in x86 gentoo trunk Message-ID: <20080115030840.75EA21E4006@bag.python.org> The Buildbot has detected a new failure of x86 gentoo trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20gentoo%20trunk/builds/2890 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-x86 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: andrew.kuchling,raymond.hettinger BUILD FAILED: failed compile sincerely, -The Buildbot From buildbot at python.org Tue Jan 15 04:08:56 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 15 Jan 2008 03:08:56 +0000 Subject: [Python-checkins] buildbot failure in x86 mvlgcc trunk Message-ID: <20080115030856.454501E4006@bag.python.org> The Buildbot has detected a new failure of x86 mvlgcc trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20mvlgcc%20trunk/builds/1206 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-linux Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: andrew.kuchling,raymond.hettinger BUILD FAILED: failed compile sincerely, -The Buildbot From buildbot at python.org Tue Jan 15 04:11:20 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 15 Jan 2008 03:11:20 +0000 Subject: [Python-checkins] buildbot failure in sparc solaris10 gcc trunk Message-ID: <20080115031120.8F88E1E4006@bag.python.org> The Buildbot has detected a new failure of sparc solaris10 gcc trunk. Full details are available at: http://www.python.org/dev/buildbot/all/sparc%20solaris10%20gcc%20trunk/builds/2612 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-sun Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: andrew.kuchling,raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: sincerely, -The Buildbot From buildbot at python.org Tue Jan 15 04:19:46 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 15 Jan 2008 03:19:46 +0000 Subject: [Python-checkins] buildbot failure in PPC64 Debian trunk Message-ID: <20080115031946.5105B1E4006@bag.python.org> The Buildbot has detected a new failure of PPC64 Debian trunk. Full details are available at: http://www.python.org/dev/buildbot/all/PPC64%20Debian%20trunk/builds/104 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: andrew.kuchling,raymond.hettinger BUILD FAILED: failed compile sincerely, -The Buildbot From buildbot at python.org Tue Jan 15 04:27:28 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 15 Jan 2008 03:27:28 +0000 Subject: [Python-checkins] buildbot failure in ia64 Ubuntu trunk Message-ID: <20080115032728.C968F1E4006@bag.python.org> The Buildbot has detected a new failure of ia64 Ubuntu trunk. Full details are available at: http://www.python.org/dev/buildbot/all/ia64%20Ubuntu%20trunk/builds/1283 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ia64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: andrew.kuchling,raymond.hettinger BUILD FAILED: failed compile sincerely, -The Buildbot From buildbot at python.org Tue Jan 15 04:30:47 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 15 Jan 2008 03:30:47 +0000 Subject: [Python-checkins] buildbot failure in g4 osx.4 trunk Message-ID: <20080115033047.D9CDA1E4037@bag.python.org> The Buildbot has detected a new failure of g4 osx.4 trunk. Full details are available at: http://www.python.org/dev/buildbot/all/g4%20osx.4%20trunk/builds/2611 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: psf-g4 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: andrew.kuchling,raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: make: *** [buildbottest] Abort trap sincerely, -The Buildbot From buildbot at python.org Tue Jan 15 04:33:09 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 15 Jan 2008 03:33:09 +0000 Subject: [Python-checkins] buildbot failure in x86 FreeBSD trunk Message-ID: <20080115033309.B09321E4030@bag.python.org> The Buildbot has detected a new failure of x86 FreeBSD trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20FreeBSD%20trunk/builds/399 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-freebsd Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: andrew.kuchling,raymond.hettinger BUILD FAILED: failed compile sincerely, -The Buildbot From python-checkins at python.org Tue Jan 15 04:40:21 2008 From: python-checkins at python.org (skip.montanaro) Date: Tue, 15 Jan 2008 04:40:21 +0100 (CET) Subject: [Python-checkins] r59969 - python/trunk/Doc/library/queue.rst Message-ID: <20080115034021.26BB01E4028@bag.python.org> Author: skip.montanaro Date: Tue Jan 15 04:40:20 2008 New Revision: 59969 Modified: python/trunk/Doc/library/queue.rst Log: Better (?) text describing the lack of guarantees provided by qsize(), empty() and full(). Modified: python/trunk/Doc/library/queue.rst ============================================================================== --- python/trunk/Doc/library/queue.rst (original) +++ python/trunk/Doc/library/queue.rst Tue Jan 15 04:40:20 2008 @@ -49,20 +49,25 @@ .. method:: Queue.qsize() - Return the approximate size of the queue. Because of multithreading semantics, - this number is not reliable. + Return the approximate size of the queue. qsize() > 0 doesn't guarantee + that a subsequent get() will not block, nor that qsize() < maxsize + guarantee that put() will not block. .. method:: Queue.empty() - Return ``True`` if the queue is empty, ``False`` otherwise. Because of - multithreading semantics, this is not reliable. + Return ``True`` if the queue is empty, ``False`` otherwise. If empty() + returns ``True`` it doesn't guarantee that a subsequent call to put() + will not block. Similarly, if empty() returns ``False`` it doesn't + guarantee that a subsequent call to get() will not block. .. method:: Queue.full() - Return ``True`` if the queue is full, ``False`` otherwise. Because of - multithreading semantics, this is not reliable. + Return ``True`` if the queue is full, ``False`` otherwise. If full() + returns ``True`` it doesn't guarantee that a subsequent call to get() + will not block. Similarly, if full() returns ``False`` it doesn't + guarantee that a subsequent call to put() will not block. .. method:: Queue.put(item[, block[, timeout]]) From buildbot at python.org Tue Jan 15 05:11:57 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 15 Jan 2008 04:11:57 +0000 Subject: [Python-checkins] buildbot failure in ppc Debian unstable trunk Message-ID: <20080115041157.707851E4028@bag.python.org> The Buildbot has detected a new failure of ppc Debian unstable trunk. Full details are available at: http://www.python.org/dev/buildbot/all/ppc%20Debian%20unstable%20trunk/builds/591 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: andrew.kuchling,raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: make: *** [buildbottest] Aborted sincerely, -The Buildbot From buildbot at python.org Tue Jan 15 05:55:10 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 15 Jan 2008 04:55:10 +0000 Subject: [Python-checkins] buildbot failure in hppa Ubuntu trunk Message-ID: <20080115045510.C91961E403B@bag.python.org> The Buildbot has detected a new failure of hppa Ubuntu trunk. Full details are available at: http://www.python.org/dev/buildbot/all/hppa%20Ubuntu%20trunk/builds/518 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-ubuntu-hppa Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: andrew.kuchling,raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: make: *** [buildbottest] Aborted sincerely, -The Buildbot From martin at v.loewis.de Tue Jan 15 06:34:13 2008 From: martin at v.loewis.de (=?ISO-8859-1?Q?=22Martin_v=2E_L=F6wis=22?=) Date: Tue, 15 Jan 2008 06:34:13 +0100 Subject: [Python-checkins] r59969 - python/trunk/Doc/library/queue.rst In-Reply-To: <20080115034021.26BB01E4028@bag.python.org> References: <20080115034021.26BB01E4028@bag.python.org> Message-ID: <478C45D5.4090103@v.loewis.de> > Better (?) text describing the lack of guarantees provided by qsize(), > empty() and full(). These are indeed better. Readers can now consider whether the guarantees that are not given indeed may hold for their applications. E.g. if you know that there is only one consumer thread, then if .empty() returns False, you know that .get() *will* not block. These issues all exist only when there are multiple consumers or multiple producers. Regards, Martin From python-checkins at python.org Tue Jan 15 06:40:01 2008 From: python-checkins at python.org (raymond.hettinger) Date: Tue, 15 Jan 2008 06:40:01 +0100 (CET) Subject: [Python-checkins] r59970 - in python/trunk: Lib/test/test_structseq.py Misc/ACKS Misc/NEWS Objects/structseq.c Message-ID: <20080115054001.4F2B91E4028@bag.python.org> Author: raymond.hettinger Date: Tue Jan 15 06:39:59 2008 New Revision: 59970 Modified: python/trunk/Lib/test/test_structseq.py python/trunk/Misc/ACKS python/trunk/Misc/NEWS python/trunk/Objects/structseq.c Log: Temporarily revert 59967 until GC can be added. Modified: python/trunk/Lib/test/test_structseq.py ============================================================================== --- python/trunk/Lib/test/test_structseq.py (original) +++ python/trunk/Lib/test/test_structseq.py Tue Jan 15 06:39:59 2008 @@ -26,12 +26,6 @@ for i in xrange(-len(t), len(t)-1): self.assertEqual(t[i], astuple[i]) - def test_tuple_subclass(self): - # Issue 1820 - t = time.localtime() - s = ('%s ' * len(t)) % t # This used to fail because t was not a tuple subclass - self.assert_(isinstance(t, tuple)) - def test_repr(self): t = time.gmtime() self.assert_(repr(t)) Modified: python/trunk/Misc/ACKS ============================================================================== --- python/trunk/Misc/ACKS (original) +++ python/trunk/Misc/ACKS Tue Jan 15 06:39:59 2008 @@ -686,7 +686,6 @@ Charles Waldman Richard Walker Larry Wall -Leif Walsh Greg Ward Barry Warsaw Steve Waterbury Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Tue Jan 15 06:39:59 2008 @@ -975,10 +975,6 @@ Extension Modules ----------------- -- Issue 1820: structseq objects did not subclass from tuple so they did - not pass isinstance(t, tuple) tests and they could not be passed to - the % string formatting operator as an input tuple. - - _winreg's HKEY object has gained __enter__ and __exit__ methods to support the context manager protocol. The _winreg module also gained a new function ``ExpandEnvironmentStrings`` to expand REG_EXPAND_SZ keys. Modified: python/trunk/Objects/structseq.c ============================================================================== --- python/trunk/Objects/structseq.c (original) +++ python/trunk/Objects/structseq.c Tue Jan 15 06:39:59 2008 @@ -460,7 +460,7 @@ structseq_methods, /* tp_methods */ NULL, /* tp_members */ 0, /* tp_getset */ - &PyTuple_Type, /* tp_base */ + 0, /* tp_base */ 0, /* tp_dict */ 0, /* tp_descr_get */ 0, /* tp_descr_set */ From python-checkins at python.org Tue Jan 15 06:46:43 2008 From: python-checkins at python.org (raymond.hettinger) Date: Tue, 15 Jan 2008 06:46:43 +0100 (CET) Subject: [Python-checkins] r59971 - python/trunk/Doc/library/queue.rst Message-ID: <20080115054643.92D9E1E4028@bag.python.org> Author: raymond.hettinger Date: Tue Jan 15 06:46:43 2008 New Revision: 59971 Modified: python/trunk/Doc/library/queue.rst Log: Small grammar nit Modified: python/trunk/Doc/library/queue.rst ============================================================================== --- python/trunk/Doc/library/queue.rst (original) +++ python/trunk/Doc/library/queue.rst Tue Jan 15 06:46:43 2008 @@ -49,8 +49,8 @@ .. method:: Queue.qsize() - Return the approximate size of the queue. qsize() > 0 doesn't guarantee - that a subsequent get() will not block, nor that qsize() < maxsize + Return the approximate size of the queue. Note, qsize() > 0 doesn't + guarantee that a subsequent get() will not block, nor will qsize() < maxsize guarantee that put() will not block. From python-checkins at python.org Tue Jan 15 07:55:56 2008 From: python-checkins at python.org (georg.brandl) Date: Tue, 15 Jan 2008 07:55:56 +0100 (CET) Subject: [Python-checkins] r59972 - python/trunk/Doc/whatsnew/2.6.rst Message-ID: <20080115065556.8939A1E4028@bag.python.org> Author: georg.brandl Date: Tue Jan 15 07:55:56 2008 New Revision: 59972 Modified: python/trunk/Doc/whatsnew/2.6.rst Log: Typo. Modified: python/trunk/Doc/whatsnew/2.6.rst ============================================================================== --- python/trunk/Doc/whatsnew/2.6.rst (original) +++ python/trunk/Doc/whatsnew/2.6.rst Tue Jan 15 07:55:56 2008 @@ -673,7 +673,7 @@ Optimizations ------------- -* Type objects now have a cache of methods that can reduc +* Type objects now have a cache of methods that can reduce the amount of work required to find the correct method implementation for a particular class; once cached, the interpreter doesn't need to traverse base classes to figure out the right method to call. From python-checkins at python.org Tue Jan 15 07:58:16 2008 From: python-checkins at python.org (georg.brandl) Date: Tue, 15 Jan 2008 07:58:16 +0100 (CET) Subject: [Python-checkins] r59973 - python/trunk/Doc/whatsnew/2.6.rst Message-ID: <20080115065816.16DBE1E4028@bag.python.org> Author: georg.brandl Date: Tue Jan 15 07:58:15 2008 New Revision: 59973 Modified: python/trunk/Doc/whatsnew/2.6.rst Log: Remove duplicate entry. Modified: python/trunk/Doc/whatsnew/2.6.rst ============================================================================== --- python/trunk/Doc/whatsnew/2.6.rst (original) +++ python/trunk/Doc/whatsnew/2.6.rst Tue Jan 15 07:58:15 2008 @@ -1022,14 +1022,6 @@ These attributes are all read-only. (Contributed by Christian Heimes.) - The :attr:`dont_write_bytecode` variable controls whether Python - writes any :file:`.pyc` or :file:`.pyo` files on importing a module. - If this variable is true, the compiled files are not written. The - variable can be set by Python code, by supplying the :option:`-B` - switch, or by setting the :envvar:`PYTHONDONTWRITEBYTECODE` - environment variable to any non-empty string when running the Python - interpreter. - * The :mod:`tarfile` module now supports POSIX.1-2001 (pax) and POSIX.1-1988 (ustar) format tarfiles, in addition to the GNU tar format that was already supported. The default format @@ -1270,9 +1262,9 @@ or :file:`.pyo` files by either supplying the :option:`-B` switch or setting the :envvar:`PYTHONDONTWRITEBYTECODE` environment variable to any non-empty string when running the Python interpreter. These - are used to set a :attr:`dont_write_bytecode` variable in the - :mod:`sys` module. Python code can change this variable to - control whether bytecode files are subsequently written. + are also used to set the :data:`sys.dont_write_bytecode` attribute; + Python code can change this variable to control whether bytecode + files are subsequently written. (Contributed by Neal Norwitz and Georg Brandl.) .. ====================================================================== From buildbot at python.org Tue Jan 15 08:02:46 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 15 Jan 2008 07:02:46 +0000 Subject: [Python-checkins] buildbot failure in ARM Linux EABI 3.0 Message-ID: <20080115070246.F0BD11E4028@bag.python.org> The Buildbot has detected a new failure of ARM Linux EABI 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/ARM%20Linux%20EABI%203.0/builds/2 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-linux-armeabi Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed compile sincerely, -The Buildbot From python-checkins at python.org Tue Jan 15 08:46:25 2008 From: python-checkins at python.org (jeffrey.yasskin) Date: Tue, 15 Jan 2008 08:46:25 +0100 (CET) Subject: [Python-checkins] r59974 - in python/trunk: Demo/classes/Rat.py Doc/library/numeric.rst Doc/library/rational.rst Lib/numbers.py Lib/rational.py Lib/test/test_rational.py Message-ID: <20080115074625.ED3F11E403A@bag.python.org> Author: jeffrey.yasskin Date: Tue Jan 15 08:46:24 2008 New Revision: 59974 Added: python/trunk/Doc/library/rational.rst python/trunk/Lib/rational.py - copied, changed from r59671, python/trunk/Demo/classes/Rat.py python/trunk/Lib/test/test_rational.py Removed: python/trunk/Demo/classes/Rat.py Modified: python/trunk/Doc/library/numeric.rst python/trunk/Lib/numbers.py Log: Add rational.Rational as an implementation of numbers.Rational with infinite precision. This has been discussed at http://bugs.python.org/issue1682. It's useful primarily for teaching, but it also demonstrates how to implement a member of the numeric tower, including fallbacks for mixed-mode arithmetic. I expect to write a couple more patches in this area: * Rational.from_decimal() * Rational.trim/approximate() (maybe with different names) * Maybe remove the parentheses from Rational.__str__() * Maybe rename one of the Rational classes * Maybe make Rational('3/2') work. Deleted: /python/trunk/Demo/classes/Rat.py ============================================================================== --- /python/trunk/Demo/classes/Rat.py Tue Jan 15 08:46:24 2008 +++ (empty file) @@ -1,310 +0,0 @@ -'''\ -This module implements rational numbers. - -The entry point of this module is the function - rat(numerator, denominator) -If either numerator or denominator is of an integral or rational type, -the result is a rational number, else, the result is the simplest of -the types float and complex which can hold numerator/denominator. -If denominator is omitted, it defaults to 1. -Rational numbers can be used in calculations with any other numeric -type. The result of the calculation will be rational if possible. - -There is also a test function with calling sequence - test() -The documentation string of the test function contains the expected -output. -''' - -# Contributed by Sjoerd Mullender - -from types import * - -def gcd(a, b): - '''Calculate the Greatest Common Divisor.''' - while b: - a, b = b, a%b - return a - -def rat(num, den = 1): - # must check complex before float - if isinstance(num, complex) or isinstance(den, complex): - # numerator or denominator is complex: return a complex - return complex(num) / complex(den) - if isinstance(num, float) or isinstance(den, float): - # numerator or denominator is float: return a float - return float(num) / float(den) - # otherwise return a rational - return Rat(num, den) - -class Rat: - '''This class implements rational numbers.''' - - def __init__(self, num, den = 1): - if den == 0: - raise ZeroDivisionError, 'rat(x, 0)' - - # normalize - - # must check complex before float - if (isinstance(num, complex) or - isinstance(den, complex)): - # numerator or denominator is complex: - # normalized form has denominator == 1+0j - self.__num = complex(num) / complex(den) - self.__den = complex(1) - return - if isinstance(num, float) or isinstance(den, float): - # numerator or denominator is float: - # normalized form has denominator == 1.0 - self.__num = float(num) / float(den) - self.__den = 1.0 - return - if (isinstance(num, self.__class__) or - isinstance(den, self.__class__)): - # numerator or denominator is rational - new = num / den - if not isinstance(new, self.__class__): - self.__num = new - if isinstance(new, complex): - self.__den = complex(1) - else: - self.__den = 1.0 - else: - self.__num = new.__num - self.__den = new.__den - else: - # make sure numerator and denominator don't - # have common factors - # this also makes sure that denominator > 0 - g = gcd(num, den) - self.__num = num / g - self.__den = den / g - # try making numerator and denominator of IntType if they fit - try: - numi = int(self.__num) - deni = int(self.__den) - except (OverflowError, TypeError): - pass - else: - if self.__num == numi and self.__den == deni: - self.__num = numi - self.__den = deni - - def __repr__(self): - return 'Rat(%s,%s)' % (self.__num, self.__den) - - def __str__(self): - if self.__den == 1: - return str(self.__num) - else: - return '(%s/%s)' % (str(self.__num), str(self.__den)) - - # a + b - def __add__(a, b): - try: - return rat(a.__num * b.__den + b.__num * a.__den, - a.__den * b.__den) - except OverflowError: - return rat(long(a.__num) * long(b.__den) + - long(b.__num) * long(a.__den), - long(a.__den) * long(b.__den)) - - def __radd__(b, a): - return Rat(a) + b - - # a - b - def __sub__(a, b): - try: - return rat(a.__num * b.__den - b.__num * a.__den, - a.__den * b.__den) - except OverflowError: - return rat(long(a.__num) * long(b.__den) - - long(b.__num) * long(a.__den), - long(a.__den) * long(b.__den)) - - def __rsub__(b, a): - return Rat(a) - b - - # a * b - def __mul__(a, b): - try: - return rat(a.__num * b.__num, a.__den * b.__den) - except OverflowError: - return rat(long(a.__num) * long(b.__num), - long(a.__den) * long(b.__den)) - - def __rmul__(b, a): - return Rat(a) * b - - # a / b - def __div__(a, b): - try: - return rat(a.__num * b.__den, a.__den * b.__num) - except OverflowError: - return rat(long(a.__num) * long(b.__den), - long(a.__den) * long(b.__num)) - - def __rdiv__(b, a): - return Rat(a) / b - - # a % b - def __mod__(a, b): - div = a / b - try: - div = int(div) - except OverflowError: - div = long(div) - return a - b * div - - def __rmod__(b, a): - return Rat(a) % b - - # a ** b - def __pow__(a, b): - if b.__den != 1: - if isinstance(a.__num, complex): - a = complex(a) - else: - a = float(a) - if isinstance(b.__num, complex): - b = complex(b) - else: - b = float(b) - return a ** b - try: - return rat(a.__num ** b.__num, a.__den ** b.__num) - except OverflowError: - return rat(long(a.__num) ** b.__num, - long(a.__den) ** b.__num) - - def __rpow__(b, a): - return Rat(a) ** b - - # -a - def __neg__(a): - try: - return rat(-a.__num, a.__den) - except OverflowError: - # a.__num == sys.maxint - return rat(-long(a.__num), a.__den) - - # abs(a) - def __abs__(a): - return rat(abs(a.__num), a.__den) - - # int(a) - def __int__(a): - return int(a.__num / a.__den) - - # long(a) - def __long__(a): - return long(a.__num) / long(a.__den) - - # float(a) - def __float__(a): - return float(a.__num) / float(a.__den) - - # complex(a) - def __complex__(a): - return complex(a.__num) / complex(a.__den) - - # cmp(a,b) - def __cmp__(a, b): - diff = Rat(a - b) - if diff.__num < 0: - return -1 - elif diff.__num > 0: - return 1 - else: - return 0 - - def __rcmp__(b, a): - return cmp(Rat(a), b) - - # a != 0 - def __nonzero__(a): - return a.__num != 0 - - # coercion - def __coerce__(a, b): - return a, Rat(b) - -def test(): - '''\ - Test function for rat module. - - The expected output is (module some differences in floating - precission): - -1 - -1 - 0 0L 0.1 (0.1+0j) - [Rat(1,2), Rat(-3,10), Rat(1,25), Rat(1,4)] - [Rat(-3,10), Rat(1,25), Rat(1,4), Rat(1,2)] - 0 - (11/10) - (11/10) - 1.1 - OK - 2 1.5 (3/2) (1.5+1.5j) (15707963/5000000) - 2 2 2.0 (2+0j) - - 4 0 4 1 4 0 - 3.5 0.5 3.0 1.33333333333 2.82842712475 1 - (7/2) (1/2) 3 (4/3) 2.82842712475 1 - (3.5+1.5j) (0.5-1.5j) (3+3j) (0.666666666667-0.666666666667j) (1.43248815986+2.43884761145j) 1 - 1.5 1 1.5 (1.5+0j) - - 3.5 -0.5 3.0 0.75 2.25 -1 - 3.0 0.0 2.25 1.0 1.83711730709 0 - 3.0 0.0 2.25 1.0 1.83711730709 1 - (3+1.5j) -1.5j (2.25+2.25j) (0.5-0.5j) (1.50768393746+1.04970907623j) -1 - (3/2) 1 1.5 (1.5+0j) - - (7/2) (-1/2) 3 (3/4) (9/4) -1 - 3.0 0.0 2.25 1.0 1.83711730709 -1 - 3 0 (9/4) 1 1.83711730709 0 - (3+1.5j) -1.5j (2.25+2.25j) (0.5-0.5j) (1.50768393746+1.04970907623j) -1 - (1.5+1.5j) (1.5+1.5j) - - (3.5+1.5j) (-0.5+1.5j) (3+3j) (0.75+0.75j) 4.5j -1 - (3+1.5j) 1.5j (2.25+2.25j) (1+1j) (1.18235814075+2.85446505899j) 1 - (3+1.5j) 1.5j (2.25+2.25j) (1+1j) (1.18235814075+2.85446505899j) 1 - (3+3j) 0j 4.5j (1+0j) (-0.638110484918+0.705394566962j) 0 - ''' - print rat(-1L, 1) - print rat(1, -1) - a = rat(1, 10) - print int(a), long(a), float(a), complex(a) - b = rat(2, 5) - l = [a+b, a-b, a*b, a/b] - print l - l.sort() - print l - print rat(0, 1) - print a+1 - print a+1L - print a+1.0 - try: - print rat(1, 0) - raise SystemError, 'should have been ZeroDivisionError' - except ZeroDivisionError: - print 'OK' - print rat(2), rat(1.5), rat(3, 2), rat(1.5+1.5j), rat(31415926,10000000) - list = [2, 1.5, rat(3,2), 1.5+1.5j] - for i in list: - print i, - if not isinstance(i, complex): - print int(i), float(i), - print complex(i) - print - for j in list: - print i + j, i - j, i * j, i / j, i ** j, - if not (isinstance(i, complex) or - isinstance(j, complex)): - print cmp(i, j) - print - - -if __name__ == '__main__': - test() Modified: python/trunk/Doc/library/numeric.rst ============================================================================== --- python/trunk/Doc/library/numeric.rst (original) +++ python/trunk/Doc/library/numeric.rst Tue Jan 15 08:46:24 2008 @@ -21,6 +21,7 @@ math.rst cmath.rst decimal.rst + rational.rst random.rst itertools.rst functools.rst Added: python/trunk/Doc/library/rational.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/library/rational.rst Tue Jan 15 08:46:24 2008 @@ -0,0 +1,65 @@ + +:mod:`rational` --- Rational numbers +==================================== + +.. module:: rational + :synopsis: Rational numbers. +.. moduleauthor:: Jeffrey Yasskin +.. sectionauthor:: Jeffrey Yasskin +.. versionadded:: 2.6 + + +The :mod:`rational` module defines an immutable, infinite-precision +Rational number class. + + +.. class:: Rational(numerator=0, denominator=1) + Rational(other_rational) + + The first version requires that *numerator* and *denominator* are + instances of :class:`numbers.Integral` and returns a new + ``Rational`` representing ``numerator/denominator``. If + *denominator* is :const:`0`, raises a :exc:`ZeroDivisionError`. The + second version requires that *other_rational* is an instance of + :class:`numbers.Rational` and returns an instance of + :class:`Rational` with the same value. + + Implements all of the methods and operations from + :class:`numbers.Rational` and is hashable. + + +.. method:: Rational.from_float(flt) + + This classmethod constructs a :class:`Rational` representing the + exact value of *flt*, which must be a :class:`float`. Beware that + ``Rational.from_float(0.3)`` is not the same value as ``Rational(3, + 10)`` + + +.. method:: Rational.__floor__() + + Returns the greatest :class:`int` ``<= self``. Will be accessible + through :func:`math.floor` in Py3k. + + +.. method:: Rational.__ceil__() + + Returns the least :class:`int` ``>= self``. Will be accessible + through :func:`math.ceil` in Py3k. + + +.. method:: Rational.__round__() + Rational.__round__(ndigits) + + The first version returns the nearest :class:`int` to ``self``, + rounding half to even. The second version rounds ``self`` to the + nearest multiple of ``Rational(1, 10**ndigits)`` (logically, if + ``ndigits`` is negative), again rounding half toward even. Will be + accessible through :func:`round` in Py3k. + + +.. seealso:: + + Module :mod:`numbers` + The abstract base classes making up the numeric tower. + Modified: python/trunk/Lib/numbers.py ============================================================================== --- python/trunk/Lib/numbers.py (original) +++ python/trunk/Lib/numbers.py Tue Jan 15 08:46:24 2008 @@ -5,6 +5,7 @@ TODO: Fill out more detailed documentation on the operators.""" +from __future__ import division from abc import ABCMeta, abstractmethod, abstractproperty __all__ = ["Number", "Exact", "Inexact", @@ -63,7 +64,8 @@ def __complex__(self): """Return a builtin complex instance. Called for complex(self).""" - def __bool__(self): + # Will be __bool__ in 3.0. + def __nonzero__(self): """True if self != 0. Called for bool(self).""" return self != 0 @@ -98,6 +100,7 @@ """-self""" raise NotImplementedError + @abstractmethod def __pos__(self): """+self""" raise NotImplementedError @@ -122,12 +125,28 @@ @abstractmethod def __div__(self, other): - """self / other; should promote to float or complex when necessary.""" + """self / other without __future__ division + + May promote to float. + """ raise NotImplementedError @abstractmethod def __rdiv__(self, other): - """other / self""" + """other / self without __future__ division""" + raise NotImplementedError + + @abstractmethod + def __truediv__(self, other): + """self / other with __future__ division. + + Should promote to float when necessary. + """ + raise NotImplementedError + + @abstractmethod + def __rtruediv__(self, other): + """other / self with __future__ division""" raise NotImplementedError @abstractmethod Copied: python/trunk/Lib/rational.py (from r59671, python/trunk/Demo/classes/Rat.py) ============================================================================== --- python/trunk/Demo/classes/Rat.py (original) +++ python/trunk/Lib/rational.py Tue Jan 15 08:46:24 2008 @@ -1,310 +1,410 @@ -'''\ -This module implements rational numbers. +# Originally contributed by Sjoerd Mullender. +# Significantly modified by Jeffrey Yasskin . -The entry point of this module is the function - rat(numerator, denominator) -If either numerator or denominator is of an integral or rational type, -the result is a rational number, else, the result is the simplest of -the types float and complex which can hold numerator/denominator. -If denominator is omitted, it defaults to 1. -Rational numbers can be used in calculations with any other numeric -type. The result of the calculation will be rational if possible. - -There is also a test function with calling sequence - test() -The documentation string of the test function contains the expected -output. -''' +"""Rational, infinite-precision, real numbers.""" -# Contributed by Sjoerd Mullender +from __future__ import division +import math +import numbers +import operator -from types import * +__all__ = ["Rational"] -def gcd(a, b): - '''Calculate the Greatest Common Divisor.''' +RationalAbc = numbers.Rational + + +def _gcd(a, b): + """Calculate the Greatest Common Divisor. + + Unless b==0, the result will have the same sign as b (so that when + b is divided by it, the result comes out positive). + """ while b: a, b = b, a%b return a -def rat(num, den = 1): - # must check complex before float - if isinstance(num, complex) or isinstance(den, complex): - # numerator or denominator is complex: return a complex - return complex(num) / complex(den) - if isinstance(num, float) or isinstance(den, float): - # numerator or denominator is float: return a float - return float(num) / float(den) - # otherwise return a rational - return Rat(num, den) - -class Rat: - '''This class implements rational numbers.''' - - def __init__(self, num, den = 1): - if den == 0: - raise ZeroDivisionError, 'rat(x, 0)' - - # normalize - - # must check complex before float - if (isinstance(num, complex) or - isinstance(den, complex)): - # numerator or denominator is complex: - # normalized form has denominator == 1+0j - self.__num = complex(num) / complex(den) - self.__den = complex(1) - return - if isinstance(num, float) or isinstance(den, float): - # numerator or denominator is float: - # normalized form has denominator == 1.0 - self.__num = float(num) / float(den) - self.__den = 1.0 - return - if (isinstance(num, self.__class__) or - isinstance(den, self.__class__)): - # numerator or denominator is rational - new = num / den - if not isinstance(new, self.__class__): - self.__num = new - if isinstance(new, complex): - self.__den = complex(1) - else: - self.__den = 1.0 - else: - self.__num = new.__num - self.__den = new.__den - else: - # make sure numerator and denominator don't - # have common factors - # this also makes sure that denominator > 0 - g = gcd(num, den) - self.__num = num / g - self.__den = den / g - # try making numerator and denominator of IntType if they fit - try: - numi = int(self.__num) - deni = int(self.__den) - except (OverflowError, TypeError): - pass - else: - if self.__num == numi and self.__den == deni: - self.__num = numi - self.__den = deni + +def _binary_float_to_ratio(x): + """x -> (top, bot), a pair of ints s.t. x = top/bot. + + The conversion is done exactly, without rounding. + bot > 0 guaranteed. + Some form of binary fp is assumed. + Pass NaNs or infinities at your own risk. + + >>> _binary_float_to_ratio(10.0) + (10, 1) + >>> _binary_float_to_ratio(0.0) + (0, 1) + >>> _binary_float_to_ratio(-.25) + (-1, 4) + """ + + if x == 0: + return 0, 1 + f, e = math.frexp(x) + signbit = 1 + if f < 0: + f = -f + signbit = -1 + assert 0.5 <= f < 1.0 + # x = signbit * f * 2**e exactly + + # Suck up CHUNK bits at a time; 28 is enough so that we suck + # up all bits in 2 iterations for all known binary double- + # precision formats, and small enough to fit in an int. + CHUNK = 28 + top = 0 + # invariant: x = signbit * (top + f) * 2**e exactly + while f: + f = math.ldexp(f, CHUNK) + digit = trunc(f) + assert digit >> CHUNK == 0 + top = (top << CHUNK) | digit + f = f - digit + assert 0.0 <= f < 1.0 + e = e - CHUNK + assert top + + # Add in the sign bit. + top = signbit * top + + # now x = top * 2**e exactly; fold in 2**e + if e>0: + return (top * 2**e, 1) + else: + return (top, 2 ** -e) + + +class Rational(RationalAbc): + """This class implements rational numbers. + + Rational(8, 6) will produce a rational number equivalent to + 4/3. Both arguments must be Integral. The numerator defaults to 0 + and the denominator defaults to 1 so that Rational(3) == 3 and + Rational() == 0. + + """ + + __slots__ = ('_numerator', '_denominator') + + def __init__(self, numerator=0, denominator=1): + if (not isinstance(numerator, numbers.Integral) and + isinstance(numerator, RationalAbc) and + denominator == 1): + # Handle copies from other rationals. + other_rational = numerator + numerator = other_rational.numerator + denominator = other_rational.denominator + + if (not isinstance(numerator, numbers.Integral) or + not isinstance(denominator, numbers.Integral)): + raise TypeError("Rational(%(numerator)s, %(denominator)s):" + " Both arguments must be integral." % locals()) + + if denominator == 0: + raise ZeroDivisionError('Rational(%s, 0)' % numerator) + + g = _gcd(numerator, denominator) + self._numerator = int(numerator // g) + self._denominator = int(denominator // g) + + @classmethod + def from_float(cls, f): + """Converts a float to a rational number, exactly.""" + if not isinstance(f, float): + raise TypeError("%s.from_float() only takes floats, not %r (%s)" % + (cls.__name__, f, type(f).__name__)) + if math.isnan(f) or math.isinf(f): + raise TypeError("Cannot convert %r to %s." % (f, cls.__name__)) + return cls(*_binary_float_to_ratio(f)) + + @property + def numerator(a): + return a._numerator + + @property + def denominator(a): + return a._denominator def __repr__(self): - return 'Rat(%s,%s)' % (self.__num, self.__den) + """repr(self)""" + return ('rational.Rational(%r,%r)' % + (self.numerator, self.denominator)) def __str__(self): - if self.__den == 1: - return str(self.__num) + """str(self)""" + if self.denominator == 1: + return str(self.numerator) else: - return '(%s/%s)' % (str(self.__num), str(self.__den)) + return '(%s/%s)' % (self.numerator, self.denominator) - # a + b - def __add__(a, b): - try: - return rat(a.__num * b.__den + b.__num * a.__den, - a.__den * b.__den) - except OverflowError: - return rat(long(a.__num) * long(b.__den) + - long(b.__num) * long(a.__den), - long(a.__den) * long(b.__den)) + def _operator_fallbacks(monomorphic_operator, fallback_operator): + """Generates forward and reverse operators given a purely-rational + operator and a function from the operator module. + + Use this like: + __op__, __rop__ = _operator_fallbacks(just_rational_op, operator.op) + + """ + def forward(a, b): + if isinstance(b, RationalAbc): + # Includes ints. + return monomorphic_operator(a, b) + elif isinstance(b, float): + return fallback_operator(float(a), b) + elif isinstance(b, complex): + return fallback_operator(complex(a), b) + else: + return NotImplemented + forward.__name__ = '__' + fallback_operator.__name__ + '__' + forward.__doc__ = monomorphic_operator.__doc__ + + def reverse(b, a): + if isinstance(a, RationalAbc): + # Includes ints. + return monomorphic_operator(a, b) + elif isinstance(a, numbers.Real): + return fallback_operator(float(a), float(b)) + elif isinstance(a, numbers.Complex): + return fallback_operator(complex(a), complex(b)) + else: + return NotImplemented + reverse.__name__ = '__r' + fallback_operator.__name__ + '__' + reverse.__doc__ = monomorphic_operator.__doc__ - def __radd__(b, a): - return Rat(a) + b + return forward, reverse - # a - b - def __sub__(a, b): - try: - return rat(a.__num * b.__den - b.__num * a.__den, - a.__den * b.__den) - except OverflowError: - return rat(long(a.__num) * long(b.__den) - - long(b.__num) * long(a.__den), - long(a.__den) * long(b.__den)) + def _add(a, b): + """a + b""" + return Rational(a.numerator * b.denominator + + b.numerator * a.denominator, + a.denominator * b.denominator) - def __rsub__(b, a): - return Rat(a) - b + __add__, __radd__ = _operator_fallbacks(_add, operator.add) - # a * b - def __mul__(a, b): - try: - return rat(a.__num * b.__num, a.__den * b.__den) - except OverflowError: - return rat(long(a.__num) * long(b.__num), - long(a.__den) * long(b.__den)) + def _sub(a, b): + """a - b""" + return Rational(a.numerator * b.denominator - + b.numerator * a.denominator, + a.denominator * b.denominator) - def __rmul__(b, a): - return Rat(a) * b + __sub__, __rsub__ = _operator_fallbacks(_sub, operator.sub) - # a / b - def __div__(a, b): - try: - return rat(a.__num * b.__den, a.__den * b.__num) - except OverflowError: - return rat(long(a.__num) * long(b.__den), - long(a.__den) * long(b.__num)) + def _mul(a, b): + """a * b""" + return Rational(a.numerator * b.numerator, a.denominator * b.denominator) - def __rdiv__(b, a): - return Rat(a) / b + __mul__, __rmul__ = _operator_fallbacks(_mul, operator.mul) - # a % b - def __mod__(a, b): + def _div(a, b): + """a / b""" + return Rational(a.numerator * b.denominator, + a.denominator * b.numerator) + + __truediv__, __rtruediv__ = _operator_fallbacks(_div, operator.truediv) + __div__, __rdiv__ = _operator_fallbacks(_div, operator.div) + + @classmethod + def _floordiv(cls, a, b): div = a / b - try: - div = int(div) - except OverflowError: - div = long(div) + if isinstance(div, RationalAbc): + # trunc(math.floor(div)) doesn't work if the rational is + # more precise than a float because the intermediate + # rounding may cross an integer boundary. + return div.numerator // div.denominator + else: + return math.floor(div) + + def __floordiv__(a, b): + """a // b""" + # Will be math.floor(a / b) in 3.0. + return a._floordiv(a, b) + + def __rfloordiv__(b, a): + """a // b""" + # Will be math.floor(a / b) in 3.0. + return b._floordiv(a, b) + + @classmethod + def _mod(cls, a, b): + div = a // b return a - b * div + def __mod__(a, b): + """a % b""" + return a._mod(a, b) + def __rmod__(b, a): - return Rat(a) % b + """a % b""" + return b._mod(a, b) - # a ** b def __pow__(a, b): - if b.__den != 1: - if isinstance(a.__num, complex): - a = complex(a) - else: - a = float(a) - if isinstance(b.__num, complex): - b = complex(b) + """a ** b + + If b is not an integer, the result will be a float or complex + since roots are generally irrational. If b is an integer, the + result will be rational. + + """ + if isinstance(b, RationalAbc): + if b.denominator == 1: + power = b.numerator + if power >= 0: + return Rational(a.numerator ** power, + a.denominator ** power) + else: + return Rational(a.denominator ** -power, + a.numerator ** -power) else: - b = float(b) - return a ** b - try: - return rat(a.__num ** b.__num, a.__den ** b.__num) - except OverflowError: - return rat(long(a.__num) ** b.__num, - long(a.__den) ** b.__num) + # A fractional power will generally produce an + # irrational number. + return float(a) ** float(b) + else: + return float(a) ** b def __rpow__(b, a): - return Rat(a) ** b + """a ** b""" + if b.denominator == 1 and b.numerator >= 0: + # If a is an int, keep it that way if possible. + return a ** b.numerator + + if isinstance(a, RationalAbc): + return Rational(a.numerator, a.denominator) ** b + + if b.denominator == 1: + return a ** b.numerator + + return a ** float(b) + + def __pos__(a): + """+a: Coerces a subclass instance to Rational""" + return Rational(a.numerator, a.denominator) - # -a def __neg__(a): - try: - return rat(-a.__num, a.__den) - except OverflowError: - # a.__num == sys.maxint - return rat(-long(a.__num), a.__den) + """-a""" + return Rational(-a.numerator, a.denominator) - # abs(a) def __abs__(a): - return rat(abs(a.__num), a.__den) + """abs(a)""" + return Rational(abs(a.numerator), a.denominator) - # int(a) - def __int__(a): - return int(a.__num / a.__den) - - # long(a) - def __long__(a): - return long(a.__num) / long(a.__den) - - # float(a) - def __float__(a): - return float(a.__num) / float(a.__den) - - # complex(a) - def __complex__(a): - return complex(a.__num) / complex(a.__den) - - # cmp(a,b) - def __cmp__(a, b): - diff = Rat(a - b) - if diff.__num < 0: - return -1 - elif diff.__num > 0: - return 1 + def __trunc__(a): + """trunc(a)""" + if a.numerator < 0: + return -(-a.numerator // a.denominator) else: - return 0 + return a.numerator // a.denominator - def __rcmp__(b, a): - return cmp(Rat(a), b) + def __floor__(a): + """Will be math.floor(a) in 3.0.""" + return a.numerator // a.denominator + + def __ceil__(a): + """Will be math.ceil(a) in 3.0.""" + # The negations cleverly convince floordiv to return the ceiling. + return -(-a.numerator // a.denominator) + + def __round__(self, ndigits=None): + """Will be round(self, ndigits) in 3.0. + + Rounds half toward even. + """ + if ndigits is None: + floor, remainder = divmod(self.numerator, self.denominator) + if remainder * 2 < self.denominator: + return floor + elif remainder * 2 > self.denominator: + return floor + 1 + # Deal with the half case: + elif floor % 2 == 0: + return floor + else: + return floor + 1 + shift = 10**abs(ndigits) + # See _operator_fallbacks.forward to check that the results of + # these operations will always be Rational and therefore have + # __round__(). + if ndigits > 0: + return Rational((self * shift).__round__(), shift) + else: + return Rational((self / shift).__round__() * shift) - # a != 0 - def __nonzero__(a): - return a.__num != 0 + def __hash__(self): + """hash(self) - # coercion - def __coerce__(a, b): - return a, Rat(b) - -def test(): - '''\ - Test function for rat module. - - The expected output is (module some differences in floating - precission): - -1 - -1 - 0 0L 0.1 (0.1+0j) - [Rat(1,2), Rat(-3,10), Rat(1,25), Rat(1,4)] - [Rat(-3,10), Rat(1,25), Rat(1,4), Rat(1,2)] - 0 - (11/10) - (11/10) - 1.1 - OK - 2 1.5 (3/2) (1.5+1.5j) (15707963/5000000) - 2 2 2.0 (2+0j) - - 4 0 4 1 4 0 - 3.5 0.5 3.0 1.33333333333 2.82842712475 1 - (7/2) (1/2) 3 (4/3) 2.82842712475 1 - (3.5+1.5j) (0.5-1.5j) (3+3j) (0.666666666667-0.666666666667j) (1.43248815986+2.43884761145j) 1 - 1.5 1 1.5 (1.5+0j) - - 3.5 -0.5 3.0 0.75 2.25 -1 - 3.0 0.0 2.25 1.0 1.83711730709 0 - 3.0 0.0 2.25 1.0 1.83711730709 1 - (3+1.5j) -1.5j (2.25+2.25j) (0.5-0.5j) (1.50768393746+1.04970907623j) -1 - (3/2) 1 1.5 (1.5+0j) - - (7/2) (-1/2) 3 (3/4) (9/4) -1 - 3.0 0.0 2.25 1.0 1.83711730709 -1 - 3 0 (9/4) 1 1.83711730709 0 - (3+1.5j) -1.5j (2.25+2.25j) (0.5-0.5j) (1.50768393746+1.04970907623j) -1 - (1.5+1.5j) (1.5+1.5j) - - (3.5+1.5j) (-0.5+1.5j) (3+3j) (0.75+0.75j) 4.5j -1 - (3+1.5j) 1.5j (2.25+2.25j) (1+1j) (1.18235814075+2.85446505899j) 1 - (3+1.5j) 1.5j (2.25+2.25j) (1+1j) (1.18235814075+2.85446505899j) 1 - (3+3j) 0j 4.5j (1+0j) (-0.638110484918+0.705394566962j) 0 - ''' - print rat(-1L, 1) - print rat(1, -1) - a = rat(1, 10) - print int(a), long(a), float(a), complex(a) - b = rat(2, 5) - l = [a+b, a-b, a*b, a/b] - print l - l.sort() - print l - print rat(0, 1) - print a+1 - print a+1L - print a+1.0 - try: - print rat(1, 0) - raise SystemError, 'should have been ZeroDivisionError' - except ZeroDivisionError: - print 'OK' - print rat(2), rat(1.5), rat(3, 2), rat(1.5+1.5j), rat(31415926,10000000) - list = [2, 1.5, rat(3,2), 1.5+1.5j] - for i in list: - print i, - if not isinstance(i, complex): - print int(i), float(i), - print complex(i) - print - for j in list: - print i + j, i - j, i * j, i / j, i ** j, - if not (isinstance(i, complex) or - isinstance(j, complex)): - print cmp(i, j) - print + Tricky because values that are exactly representable as a + float must have the same hash as that float. + """ + if self.denominator == 1: + # Get integers right. + return hash(self.numerator) + # Expensive check, but definitely correct. + if self == float(self): + return hash(float(self)) + else: + # Use tuple's hash to avoid a high collision rate on + # simple fractions. + return hash((self.numerator, self.denominator)) + + def __eq__(a, b): + """a == b""" + if isinstance(b, RationalAbc): + return (a.numerator == b.numerator and + a.denominator == b.denominator) + if isinstance(b, numbers.Complex) and b.imag == 0: + b = b.real + if isinstance(b, float): + return a == a.from_float(b) + else: + # XXX: If b.__eq__ is implemented like this method, it may + # give the wrong answer after float(a) changes a's + # value. Better ways of doing this are welcome. + return float(a) == b + + def _subtractAndCompareToZero(a, b, op): + """Helper function for comparison operators. + + Subtracts b from a, exactly if possible, and compares the + result with 0 using op, in such a way that the comparison + won't recurse. If the difference raises a TypeError, returns + NotImplemented instead. + + """ + if isinstance(b, numbers.Complex) and b.imag == 0: + b = b.real + if isinstance(b, float): + b = a.from_float(b) + try: + # XXX: If b <: Real but not <: RationalAbc, this is likely + # to fall back to a float. If the actual values differ by + # less than MIN_FLOAT, this could falsely call them equal, + # which would make <= inconsistent with ==. Better ways of + # doing this are welcome. + diff = a - b + except TypeError: + return NotImplemented + if isinstance(diff, RationalAbc): + return op(diff.numerator, 0) + return op(diff, 0) + + def __lt__(a, b): + """a < b""" + return a._subtractAndCompareToZero(b, operator.lt) + + def __gt__(a, b): + """a > b""" + return a._subtractAndCompareToZero(b, operator.gt) + + def __le__(a, b): + """a <= b""" + return a._subtractAndCompareToZero(b, operator.le) + + def __ge__(a, b): + """a >= b""" + return a._subtractAndCompareToZero(b, operator.ge) -if __name__ == '__main__': - test() + def __nonzero__(a): + """a != 0""" + return a.numerator != 0 Added: python/trunk/Lib/test/test_rational.py ============================================================================== --- (empty file) +++ python/trunk/Lib/test/test_rational.py Tue Jan 15 08:46:24 2008 @@ -0,0 +1,279 @@ +"""Tests for Lib/rational.py.""" + +from decimal import Decimal +from test.test_support import run_unittest, verbose +import math +import operator +import rational +import unittest +R = rational.Rational + +def _components(r): + return (r.numerator, r.denominator) + +class RationalTest(unittest.TestCase): + + def assertTypedEquals(self, expected, actual): + """Asserts that both the types and values are the same.""" + self.assertEquals(type(expected), type(actual)) + self.assertEquals(expected, actual) + + def assertRaisesMessage(self, exc_type, message, + callable, *args, **kwargs): + """Asserts that callable(*args, **kwargs) raises exc_type(message).""" + try: + callable(*args, **kwargs) + except exc_type, e: + self.assertEquals(message, str(e)) + else: + self.fail("%s not raised" % exc_type.__name__) + + def testInit(self): + self.assertEquals((0, 1), _components(R())) + self.assertEquals((7, 1), _components(R(7))) + self.assertEquals((7, 3), _components(R(R(7, 3)))) + + self.assertEquals((-1, 1), _components(R(-1, 1))) + self.assertEquals((-1, 1), _components(R(1, -1))) + self.assertEquals((1, 1), _components(R(-2, -2))) + self.assertEquals((1, 2), _components(R(5, 10))) + self.assertEquals((7, 15), _components(R(7, 15))) + self.assertEquals((10**23, 1), _components(R(10**23))) + + self.assertRaisesMessage(ZeroDivisionError, "Rational(12, 0)", + R, 12, 0) + self.assertRaises(TypeError, R, 1.5) + self.assertRaises(TypeError, R, 1.5 + 3j) + + def testFromFloat(self): + self.assertRaisesMessage( + TypeError, "Rational.from_float() only takes floats, not 3 (int)", + R.from_float, 3) + + self.assertEquals((0, 1), _components(R.from_float(-0.0))) + self.assertEquals((10, 1), _components(R.from_float(10.0))) + self.assertEquals((-5, 2), _components(R.from_float(-2.5))) + self.assertEquals((99999999999999991611392, 1), + _components(R.from_float(1e23))) + self.assertEquals(float(10**23), float(R.from_float(1e23))) + self.assertEquals((3602879701896397, 1125899906842624), + _components(R.from_float(3.2))) + self.assertEquals(3.2, float(R.from_float(3.2))) + + inf = 1e1000 + nan = inf - inf + self.assertRaisesMessage( + TypeError, "Cannot convert inf to Rational.", + R.from_float, inf) + self.assertRaisesMessage( + TypeError, "Cannot convert -inf to Rational.", + R.from_float, -inf) + self.assertRaisesMessage( + TypeError, "Cannot convert nan to Rational.", + R.from_float, nan) + + def testConversions(self): + self.assertTypedEquals(-1, trunc(R(-11, 10))) + self.assertTypedEquals(-2, R(-11, 10).__floor__()) + self.assertTypedEquals(-1, R(-11, 10).__ceil__()) + self.assertTypedEquals(-1, R(-10, 10).__ceil__()) + + self.assertTypedEquals(0, R(-1, 10).__round__()) + self.assertTypedEquals(0, R(-5, 10).__round__()) + self.assertTypedEquals(-2, R(-15, 10).__round__()) + self.assertTypedEquals(-1, R(-7, 10).__round__()) + + self.assertEquals(False, bool(R(0, 1))) + self.assertEquals(True, bool(R(3, 2))) + self.assertTypedEquals(0.1, float(R(1, 10))) + + # Check that __float__ isn't implemented by converting the + # numerator and denominator to float before dividing. + self.assertRaises(OverflowError, float, long('2'*400+'7')) + self.assertAlmostEquals(2.0/3, + float(R(long('2'*400+'7'), long('3'*400+'1')))) + + self.assertTypedEquals(0.1+0j, complex(R(1,10))) + + def testRound(self): + self.assertTypedEquals(R(-200), R(-150).__round__(-2)) + self.assertTypedEquals(R(-200), R(-250).__round__(-2)) + self.assertTypedEquals(R(30), R(26).__round__(-1)) + self.assertTypedEquals(R(-2, 10), R(-15, 100).__round__(1)) + self.assertTypedEquals(R(-2, 10), R(-25, 100).__round__(1)) + + + def testArithmetic(self): + self.assertEquals(R(1, 2), R(1, 10) + R(2, 5)) + self.assertEquals(R(-3, 10), R(1, 10) - R(2, 5)) + self.assertEquals(R(1, 25), R(1, 10) * R(2, 5)) + self.assertEquals(R(1, 4), R(1, 10) / R(2, 5)) + self.assertTypedEquals(2, R(9, 10) // R(2, 5)) + self.assertTypedEquals(10**23, R(10**23, 1) // R(1)) + self.assertEquals(R(2, 3), R(-7, 3) % R(3, 2)) + self.assertEquals(R(8, 27), R(2, 3) ** R(3)) + self.assertEquals(R(27, 8), R(2, 3) ** R(-3)) + self.assertTypedEquals(2.0, R(4) ** R(1, 2)) + # Will return 1j in 3.0: + self.assertRaises(ValueError, pow, R(-1), R(1, 2)) + + def testMixedArithmetic(self): + self.assertTypedEquals(R(11, 10), R(1, 10) + 1) + self.assertTypedEquals(1.1, R(1, 10) + 1.0) + self.assertTypedEquals(1.1 + 0j, R(1, 10) + (1.0 + 0j)) + self.assertTypedEquals(R(11, 10), 1 + R(1, 10)) + self.assertTypedEquals(1.1, 1.0 + R(1, 10)) + self.assertTypedEquals(1.1 + 0j, (1.0 + 0j) + R(1, 10)) + + self.assertTypedEquals(R(-9, 10), R(1, 10) - 1) + self.assertTypedEquals(-0.9, R(1, 10) - 1.0) + self.assertTypedEquals(-0.9 + 0j, R(1, 10) - (1.0 + 0j)) + self.assertTypedEquals(R(9, 10), 1 - R(1, 10)) + self.assertTypedEquals(0.9, 1.0 - R(1, 10)) + self.assertTypedEquals(0.9 + 0j, (1.0 + 0j) - R(1, 10)) + + self.assertTypedEquals(R(1, 10), R(1, 10) * 1) + self.assertTypedEquals(0.1, R(1, 10) * 1.0) + self.assertTypedEquals(0.1 + 0j, R(1, 10) * (1.0 + 0j)) + self.assertTypedEquals(R(1, 10), 1 * R(1, 10)) + self.assertTypedEquals(0.1, 1.0 * R(1, 10)) + self.assertTypedEquals(0.1 + 0j, (1.0 + 0j) * R(1, 10)) + + self.assertTypedEquals(R(1, 10), R(1, 10) / 1) + self.assertTypedEquals(0.1, R(1, 10) / 1.0) + self.assertTypedEquals(0.1 + 0j, R(1, 10) / (1.0 + 0j)) + self.assertTypedEquals(R(10, 1), 1 / R(1, 10)) + self.assertTypedEquals(10.0, 1.0 / R(1, 10)) + self.assertTypedEquals(10.0 + 0j, (1.0 + 0j) / R(1, 10)) + + self.assertTypedEquals(0, R(1, 10) // 1) + self.assertTypedEquals(0.0, R(1, 10) // 1.0) + self.assertTypedEquals(10, 1 // R(1, 10)) + self.assertTypedEquals(10**23, 10**22 // R(1, 10)) + self.assertTypedEquals(10.0, 1.0 // R(1, 10)) + + self.assertTypedEquals(R(1, 10), R(1, 10) % 1) + self.assertTypedEquals(0.1, R(1, 10) % 1.0) + self.assertTypedEquals(R(0, 1), 1 % R(1, 10)) + self.assertTypedEquals(0.0, 1.0 % R(1, 10)) + + # No need for divmod since we don't override it. + + # ** has more interesting conversion rules. + self.assertTypedEquals(R(100, 1), R(1, 10) ** -2) + self.assertTypedEquals(R(100, 1), R(10, 1) ** 2) + self.assertTypedEquals(0.1, R(1, 10) ** 1.0) + self.assertTypedEquals(0.1 + 0j, R(1, 10) ** (1.0 + 0j)) + self.assertTypedEquals(4 , 2 ** R(2, 1)) + # Will return 1j in 3.0: + self.assertRaises(ValueError, pow, (-1), R(1, 2)) + self.assertTypedEquals(R(1, 4) , 2 ** R(-2, 1)) + self.assertTypedEquals(2.0 , 4 ** R(1, 2)) + self.assertTypedEquals(0.25, 2.0 ** R(-2, 1)) + self.assertTypedEquals(1.0 + 0j, (1.0 + 0j) ** R(1, 10)) + + def testMixingWithDecimal(self): + """Decimal refuses mixed comparisons.""" + self.assertRaisesMessage( + TypeError, + "unsupported operand type(s) for +: 'Rational' and 'Decimal'", + operator.add, R(3,11), Decimal('3.1415926')) + self.assertNotEquals(R(5, 2), Decimal('2.5')) + + def testComparisons(self): + self.assertTrue(R(1, 2) < R(2, 3)) + self.assertFalse(R(1, 2) < R(1, 2)) + self.assertTrue(R(1, 2) <= R(2, 3)) + self.assertTrue(R(1, 2) <= R(1, 2)) + self.assertFalse(R(2, 3) <= R(1, 2)) + self.assertTrue(R(1, 2) == R(1, 2)) + self.assertFalse(R(1, 2) == R(1, 3)) + + def testMixedLess(self): + self.assertTrue(2 < R(5, 2)) + self.assertFalse(2 < R(4, 2)) + self.assertTrue(R(5, 2) < 3) + self.assertFalse(R(4, 2) < 2) + + self.assertTrue(R(1, 2) < 0.6) + self.assertFalse(R(1, 2) < 0.4) + self.assertTrue(0.4 < R(1, 2)) + self.assertFalse(0.5 < R(1, 2)) + + def testMixedLessEqual(self): + self.assertTrue(0.5 <= R(1, 2)) + self.assertFalse(0.6 <= R(1, 2)) + self.assertTrue(R(1, 2) <= 0.5) + self.assertFalse(R(1, 2) <= 0.4) + self.assertTrue(2 <= R(4, 2)) + self.assertFalse(2 <= R(3, 2)) + self.assertTrue(R(4, 2) <= 2) + self.assertFalse(R(5, 2) <= 2) + + def testBigFloatComparisons(self): + # Because 10**23 can't be represented exactly as a float: + self.assertFalse(R(10**23) == float(10**23)) + # The first test demonstrates why these are important. + self.assertFalse(1e23 < float(R(trunc(1e23) + 1))) + self.assertTrue(1e23 < R(trunc(1e23) + 1)) + self.assertFalse(1e23 <= R(trunc(1e23) - 1)) + self.assertTrue(1e23 > R(trunc(1e23) - 1)) + self.assertFalse(1e23 >= R(trunc(1e23) + 1)) + + def testBigComplexComparisons(self): + self.assertFalse(R(10**23) == complex(10**23)) + self.assertTrue(R(10**23) > complex(10**23)) + self.assertFalse(R(10**23) <= complex(10**23)) + + def testMixedEqual(self): + self.assertTrue(0.5 == R(1, 2)) + self.assertFalse(0.6 == R(1, 2)) + self.assertTrue(R(1, 2) == 0.5) + self.assertFalse(R(1, 2) == 0.4) + self.assertTrue(2 == R(4, 2)) + self.assertFalse(2 == R(3, 2)) + self.assertTrue(R(4, 2) == 2) + self.assertFalse(R(5, 2) == 2) + + def testStringification(self): + self.assertEquals("rational.Rational(7,3)", repr(R(7, 3))) + self.assertEquals("(7/3)", str(R(7, 3))) + self.assertEquals("7", str(R(7, 1))) + + def testHash(self): + self.assertEquals(hash(2.5), hash(R(5, 2))) + self.assertEquals(hash(10**50), hash(R(10**50))) + self.assertNotEquals(hash(float(10**23)), hash(R(10**23))) + + def testApproximatePi(self): + # Algorithm borrowed from + # http://docs.python.org/lib/decimal-recipes.html + three = R(3) + lasts, t, s, n, na, d, da = 0, three, 3, 1, 0, 0, 24 + while abs(s - lasts) > R(1, 10**9): + lasts = s + n, na = n+na, na+8 + d, da = d+da, da+32 + t = (t * n) / d + s += t + self.assertAlmostEquals(math.pi, s) + + def testApproximateCos1(self): + # Algorithm borrowed from + # http://docs.python.org/lib/decimal-recipes.html + x = R(1) + i, lasts, s, fact, num, sign = 0, 0, R(1), 1, 1, 1 + while abs(s - lasts) > R(1, 10**9): + lasts = s + i += 2 + fact *= i * (i-1) + num *= x * x + sign *= -1 + s += num / fact * sign + self.assertAlmostEquals(math.cos(1), s) + +def test_main(): + run_unittest(RationalTest) + +if __name__ == '__main__': + test_main() From nnorwitz at gmail.com Tue Jan 15 11:28:22 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Tue, 15 Jan 2008 05:28:22 -0500 Subject: [Python-checkins] Python Regression Test Failures refleak (9) Message-ID: <20080115102822.GA6917@python.psfb.org> test_opcodes leaked [-2, 0, 2] references, sum=0 test_doctest leaked [0, 0, -4] references, sum=-4 test_descrtut leaked [0, 4, -2] references, sum=2 test_funcattrs leaked [0, -2, 2] references, sum=0 test_functools leaked [-2, 0, 0] references, sum=-2 test_gc leaked [2, 0, 0] references, sum=2 test_gdbm leaked [0, -2, 0] references, sum=-2 test_genexps leaked [-2, 0, 2] references, sum=0 test_importhooks leaked [-2, 8, -6] references, sum=0 test_os leaked [0, 0, -2] references, sum=-2 test_poll leaked [0, 0, -2] references, sum=-2 test_sqlite leaked [2, 0, 0] references, sum=2 test_urllib2_localnet leaked [3, 3, 3] references, sum=9 test_urllib2net leaked [-2, 0, 0] references, sum=-2 From python-checkins at python.org Tue Jan 15 13:06:20 2008 From: python-checkins at python.org (andrew.kuchling) Date: Tue, 15 Jan 2008 13:06:20 +0100 (CET) Subject: [Python-checkins] r59975 - peps/trunk/PyRSS2Gen.py peps/trunk/pep2rss.py Message-ID: <20080115120620.22D801E4008@bag.python.org> Author: andrew.kuchling Date: Tue Jan 15 13:06:19 2008 New Revision: 59975 Modified: peps/trunk/PyRSS2Gen.py peps/trunk/pep2rss.py Log: Patch from Frank Benkstein: * Fix links for three-digit PEPs. The leading zero was eaten by an integer conversion. * PEPs are encoded as UTF-8 as per PEP 1. Change the input and output encodings from latin1 to utf-8 to make the feed render correctly. Modified: peps/trunk/PyRSS2Gen.py ============================================================================== --- peps/trunk/PyRSS2Gen.py (original) +++ peps/trunk/PyRSS2Gen.py Tue Jan 15 13:06:19 2008 @@ -10,14 +10,14 @@ # Could make this the base class; will need to add 'publish' class WriteXmlMixin: - def write_xml(self, outfile, encoding = "iso-8859-1"): + def write_xml(self, outfile, encoding = "utf-8"): from xml.sax import saxutils handler = saxutils.XMLGenerator(outfile, encoding) handler.startDocument() self.publish(handler) handler.endDocument() - def to_xml(self, encoding = "iso-8859-1"): + def to_xml(self, encoding = "utf-8"): try: import cStringIO as StringIO except ImportError: Modified: peps/trunk/pep2rss.py ============================================================================== --- peps/trunk/pep2rss.py (original) +++ peps/trunk/pep2rss.py Tue Jan 15 13:06:19 2008 @@ -4,13 +4,14 @@ # (standard post-commit args) import os, glob, time, datetime, stat, re, sys +import codecs from subprocess import Popen, PIPE import PyRSS2Gen as rssgen RSS_PATH = os.path.join(sys.argv[1], 'peps.rss') def firstline_startingwith(full_path, text): - for line in file(full_path): + for line in codecs.open(full_path, encoding="utf-8"): if line.startswith(text): return line[len(text):].strip() return None @@ -46,7 +47,7 @@ pass title = firstline_startingwith(full_path, 'Title:') author = firstline_startingwith(full_path, 'Author:') - url = 'http://www.python.org/dev/peps/pep-%d' % n + url = 'http://www.python.org/dev/peps/pep-%0.4d' % n item = rssgen.RSSItem( title = 'PEP %d: %s' % (n, title), link = url, From buildbot at python.org Tue Jan 15 13:22:17 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 15 Jan 2008 12:22:17 +0000 Subject: [Python-checkins] buildbot failure in ARM Linux 2.5 Message-ID: <20080115122217.DD21F1E403D@bag.python.org> The Buildbot has detected a new failure of ARM Linux 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/ARM%20Linux%202.5/builds/1 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-linux-arm Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed failed slave lost sincerely, -The Buildbot From python-checkins at python.org Tue Jan 15 14:56:50 2008 From: python-checkins at python.org (andrew.kuchling) Date: Tue, 15 Jan 2008 14:56:50 +0100 (CET) Subject: [Python-checkins] r59976 - peps/trunk/pep2rss.py Message-ID: <20080115135650.F30B31E4028@bag.python.org> Author: andrew.kuchling Date: Tue Jan 15 14:56:50 2008 New Revision: 59976 Modified: peps/trunk/pep2rss.py Log: Cosmetic patch from Frank Benksten: * Show most recent items in reverse order so the newest item is at the top. Modified: peps/trunk/pep2rss.py ============================================================================== --- peps/trunk/pep2rss.py (original) +++ peps/trunk/pep2rss.py Tue Jan 15 14:56:50 2008 @@ -36,11 +36,12 @@ t = time.strptime(created_str, '%d-%B-%Y') return datetime.datetime(*t[:6]) peps_with_dt = [(pep_creation_dt(full_path), full_path) for full_path in peps] -peps_with_dt.sort() +# sort peps by date, newest first +peps_with_dt.sort(reverse=True) # generate rss items for 10 most recent peps items = [] -for dt, full_path in peps_with_dt[-10:]: +for dt, full_path in peps_with_dt[:10]: try: n = int(full_path.split('-')[-1].split('.')[0]) except ValueError: From python-checkins at python.org Tue Jan 15 15:00:17 2008 From: python-checkins at python.org (andrew.kuchling) Date: Tue, 15 Jan 2008 15:00:17 +0100 (CET) Subject: [Python-checkins] r59977 - peps/trunk/pep2rss.py Message-ID: <20080115140017.0DEE21E4045@bag.python.org> Author: andrew.kuchling Date: Tue Jan 15 15:00:16 2008 New Revision: 59977 Modified: peps/trunk/pep2rss.py Log: Remove unused import Modified: peps/trunk/pep2rss.py ============================================================================== --- peps/trunk/pep2rss.py (original) +++ peps/trunk/pep2rss.py Tue Jan 15 15:00:16 2008 @@ -5,7 +5,6 @@ import os, glob, time, datetime, stat, re, sys import codecs -from subprocess import Popen, PIPE import PyRSS2Gen as rssgen RSS_PATH = os.path.join(sys.argv[1], 'peps.rss') From python-checkins at python.org Tue Jan 15 15:38:05 2008 From: python-checkins at python.org (andrew.kuchling) Date: Tue, 15 Jan 2008 15:38:05 +0100 (CET) Subject: [Python-checkins] r59978 - python/trunk/Doc/whatsnew/2.6.rst Message-ID: <20080115143805.9B7911E400E@bag.python.org> Author: andrew.kuchling Date: Tue Jan 15 15:38:05 2008 New Revision: 59978 Modified: python/trunk/Doc/whatsnew/2.6.rst Log: Restore description of sys.dont_write_bytecode. The duplication is intentional -- this paragraph is in a section describing additions to the sys module, and there's a later section that mentions the switch. I think most people scan the what's-new and don't read it in detail, so a bit of duplication is OK. Modified: python/trunk/Doc/whatsnew/2.6.rst ============================================================================== --- python/trunk/Doc/whatsnew/2.6.rst (original) +++ python/trunk/Doc/whatsnew/2.6.rst Tue Jan 15 15:38:05 2008 @@ -1015,6 +1015,17 @@ .. Patch 1534 + Another new variable, :attr:`dont_write_bytecode`, controls whether Python + writes any :file:`.pyc` or :file:`.pyo` files on importing a module. + If this variable is true, the compiled files are not written. The + variable is initially set on start-up by supplying the :option:`-B` + switch to the Python interpreter, or by setting the + :envvar:`PYTHONDONTWRITEBYTECODE` environment variable before + running the interpreter. Python code can subsequently + change the value of this variable to control whether bytecode files + are written or not. + (Contributed by Neal Norwitz and Georg Brandl.) + Information about the command-line arguments supplied to the Python interpreter are available as attributes of a ``sys.flags`` named tuple. For example, the :attr:`verbose` attribute is true if Python From python-checkins at python.org Tue Jan 15 18:44:17 2008 From: python-checkins at python.org (phillip.eby) Date: Tue, 15 Jan 2008 18:44:17 +0100 (CET) Subject: [Python-checkins] r59980 - sandbox/trunk/setuptools/setuptools/command/easy_install.py Message-ID: <20080115174417.D3A4C1E4028@bag.python.org> Author: phillip.eby Date: Tue Jan 15 18:44:17 2008 New Revision: 59980 Modified: sandbox/trunk/setuptools/setuptools/command/easy_install.py Log: Fix not picking up dependency links from recursive dependencies. Modified: sandbox/trunk/setuptools/setuptools/command/easy_install.py ============================================================================== --- sandbox/trunk/setuptools/setuptools/command/easy_install.py (original) +++ sandbox/trunk/setuptools/setuptools/command/easy_install.py Tue Jan 15 18:44:17 2008 @@ -497,6 +497,10 @@ self.install_egg_scripts(dist) self.installed_projects[dist.key] = dist log.info(self.installation_report(requirement, dist, *info)) + if dist.has_metadata('dependency_links.txt'): + self.package_index.add_find_links( + dist.get_metadata_lines('dependency_links.txt') + ) if not deps and not self.always_copy: return elif requirement is not None and dist.key != requirement.key: @@ -509,10 +513,6 @@ requirement = Requirement( distreq.project_name, distreq.specs, requirement.extras ) - if dist.has_metadata('dependency_links.txt'): - self.package_index.add_find_links( - dist.get_metadata_lines('dependency_links.txt') - ) log.info("Processing dependencies for %s", requirement) try: distros = WorkingSet([]).resolve( From python-checkins at python.org Tue Jan 15 18:46:13 2008 From: python-checkins at python.org (phillip.eby) Date: Tue, 15 Jan 2008 18:46:13 +0100 (CET) Subject: [Python-checkins] r59981 - in sandbox/branches/setuptools-0.6: EasyInstall.txt setuptools/command/easy_install.py Message-ID: <20080115174613.61A761E4028@bag.python.org> Author: phillip.eby Date: Tue Jan 15 18:46:13 2008 New Revision: 59981 Modified: sandbox/branches/setuptools-0.6/EasyInstall.txt sandbox/branches/setuptools-0.6/setuptools/command/easy_install.py Log: Fix not picking up dependency links from recursive dependencies. (backport from trunk) Modified: sandbox/branches/setuptools-0.6/EasyInstall.txt ============================================================================== --- sandbox/branches/setuptools-0.6/EasyInstall.txt (original) +++ sandbox/branches/setuptools-0.6/EasyInstall.txt Tue Jan 15 18:46:13 2008 @@ -1239,6 +1239,8 @@ * Fixed GUI scripts sometimes not executing on Windows + * Fixed not picking up dependency links from recursive dependencies. + 0.6c7 * ``ftp:`` download URLs now work correctly. Modified: sandbox/branches/setuptools-0.6/setuptools/command/easy_install.py ============================================================================== --- sandbox/branches/setuptools-0.6/setuptools/command/easy_install.py (original) +++ sandbox/branches/setuptools-0.6/setuptools/command/easy_install.py Tue Jan 15 18:46:13 2008 @@ -497,6 +497,10 @@ self.install_egg_scripts(dist) self.installed_projects[dist.key] = dist log.info(self.installation_report(requirement, dist, *info)) + if dist.has_metadata('dependency_links.txt'): + self.package_index.add_find_links( + dist.get_metadata_lines('dependency_links.txt') + ) if not deps and not self.always_copy: return elif requirement is not None and dist.key != requirement.key: @@ -509,10 +513,6 @@ requirement = Requirement( distreq.project_name, distreq.specs, requirement.extras ) - if dist.has_metadata('dependency_links.txt'): - self.package_index.add_find_links( - dist.get_metadata_lines('dependency_links.txt') - ) log.info("Processing dependencies for %s", requirement) try: distros = WorkingSet([]).resolve( From python-checkins at python.org Tue Jan 15 18:52:23 2008 From: python-checkins at python.org (phillip.eby) Date: Tue, 15 Jan 2008 18:52:23 +0100 (CET) Subject: [Python-checkins] r59982 - sandbox/trunk/setuptools/setuptools/command/build_ext.py Message-ID: <20080115175223.C42C71E4028@bag.python.org> Author: phillip.eby Date: Tue Jan 15 18:52:23 2008 New Revision: 59982 Modified: sandbox/trunk/setuptools/setuptools/command/build_ext.py Log: Update Pyrex/swig_sources workaround for newer Pyrex versions Modified: sandbox/trunk/setuptools/setuptools/command/build_ext.py ============================================================================== --- sandbox/trunk/setuptools/setuptools/command/build_ext.py (original) +++ sandbox/trunk/setuptools/setuptools/command/build_ext.py Tue Jan 15 18:52:23 2008 @@ -70,7 +70,7 @@ self.write_stub(package_dir or os.curdir, ext, True) - if _build_ext is not _du_build_ext: + if _build_ext is not _du_build_ext and not hasattr(_build_ext,'pyrex_sources'): # Workaround for problems using some Pyrex versions w/SWIG and/or 2.4 def swig_sources(self, sources, *otherargs): # first do any Pyrex processing From python-checkins at python.org Tue Jan 15 18:53:54 2008 From: python-checkins at python.org (phillip.eby) Date: Tue, 15 Jan 2008 18:53:54 +0100 (CET) Subject: [Python-checkins] r59983 - in sandbox/branches/setuptools-0.6: setuptools.txt setuptools/command/build_ext.py Message-ID: <20080115175354.D58D81E403A@bag.python.org> Author: phillip.eby Date: Tue Jan 15 18:53:54 2008 New Revision: 59983 Modified: sandbox/branches/setuptools-0.6/setuptools.txt sandbox/branches/setuptools-0.6/setuptools/command/build_ext.py Log: Update Pyrex/swig_sources workaround for newer Pyrex versions (backport) Modified: sandbox/branches/setuptools-0.6/setuptools.txt ============================================================================== --- sandbox/branches/setuptools-0.6/setuptools.txt (original) +++ sandbox/branches/setuptools-0.6/setuptools.txt Tue Jan 15 18:53:54 2008 @@ -2616,6 +2616,8 @@ non-Windows platforms, due to distutils not handling manifest file line endings correctly. + * Updated Pyrex support to work with Pyrex 0.9.6 and higher. + 0.6c7 * Fixed ``distutils.filelist.findall()`` crashing on broken symlinks, and ``egg_info`` command failing on new, uncommitted SVN directories. Modified: sandbox/branches/setuptools-0.6/setuptools/command/build_ext.py ============================================================================== --- sandbox/branches/setuptools-0.6/setuptools/command/build_ext.py (original) +++ sandbox/branches/setuptools-0.6/setuptools/command/build_ext.py Tue Jan 15 18:53:54 2008 @@ -70,7 +70,7 @@ self.write_stub(package_dir or os.curdir, ext, True) - if _build_ext is not _du_build_ext: + if _build_ext is not _du_build_ext and not hasattr(_build_ext,'pyrex_sources'): # Workaround for problems using some Pyrex versions w/SWIG and/or 2.4 def swig_sources(self, sources, *otherargs): # first do any Pyrex processing From python-checkins at python.org Tue Jan 15 18:59:29 2008 From: python-checkins at python.org (guido.van.rossum) Date: Tue, 15 Jan 2008 18:59:29 +0100 (CET) Subject: [Python-checkins] r59984 - in python/trunk: Lib/pdb.py Misc/NEWS Message-ID: <20080115175929.B65B31E4028@bag.python.org> Author: guido.van.rossum Date: Tue Jan 15 18:59:29 2008 New Revision: 59984 Modified: python/trunk/Lib/pdb.py python/trunk/Misc/NEWS Log: Issue #1786 (by myself): pdb should use its own stdin/stdout around an exec call and when creating a recursive instance. Modified: python/trunk/Lib/pdb.py ============================================================================== --- python/trunk/Lib/pdb.py (original) +++ python/trunk/Lib/pdb.py Tue Jan 15 18:59:29 2008 @@ -199,7 +199,13 @@ globals = self.curframe.f_globals try: code = compile(line + '\n', '', 'single') - exec code in globals, locals + try: + sys.stdin = self.stdin + sys.stdout = self.stdout + exec code in globals, locals + finally: + sys.stdout = save_stdout + sys.stdin = save_stdin except: t, v = sys.exc_info()[:2] if type(t) == type(''): @@ -659,7 +665,7 @@ sys.settrace(None) globals = self.curframe.f_globals locals = self.curframe.f_locals - p = Pdb() + p = Pdb(self.completekey, self.stdin, self.stdout) p.prompt = "(%s) " % self.prompt.strip() print >>self.stdout, "ENTERING RECURSIVE DEBUGGER" sys.call_tracing(p.run, (arg, globals, locals)) Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Tue Jan 15 18:59:29 2008 @@ -358,11 +358,15 @@ - Bug #1664966: Fix crash in exec if Unicode filename can't be decoded. -- Issue #1537: Changed GeneratorExit's base class from Exception to BaseException. +- Issue #1537: Changed GeneratorExit's base class from Exception to + BaseException. Library ------- +- Issue #1786: pdb should use its own stdin/stdout around an exec call + and when creating a recursive instance. + - Issue #1698398 Zipfile.printdir() crashed because the format string expected a tuple type of length six instead of time.struct_time object. From amk at amk.ca Tue Jan 15 19:22:24 2008 From: amk at amk.ca (A.M. Kuchling) Date: Tue, 15 Jan 2008 13:22:24 -0500 Subject: [Python-checkins] r59963 - python/trunk/Doc/whatsnew/2.6.rst In-Reply-To: <478C1B0C.3050306@cheimes.de> References: <20080115014733.7FE871E4006@bag.python.org> <478C1B0C.3050306@cheimes.de> Message-ID: <20080115182224.GA7077@amk-desktop.matrixgroup.net> On Tue, Jan 15, 2008 at 03:31:40AM +0100, Christian Heimes wrote: > andrew.kuchling wrote: > > + PEP 370: XXX > > + ===================================================== > > Thanks for the future documentation but the PEP hasn't been accepted yet. :) Yes, I'd already written that much of the section before realizing that I was looking at a commit to the sandbox. I'll leave it in for now, and remove it if the PEP is set aside. --amk From buildbot at python.org Tue Jan 15 19:26:34 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 15 Jan 2008 18:26:34 +0000 Subject: [Python-checkins] buildbot failure in x86 gentoo trunk Message-ID: <20080115182634.86D4B1E4033@bag.python.org> The Buildbot has detected a new failure of x86 gentoo trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20gentoo%20trunk/builds/2893 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-x86 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: andrew.kuchling,guido.van.rossum BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_doctest make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Tue Jan 15 19:29:31 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 15 Jan 2008 18:29:31 +0000 Subject: [Python-checkins] buildbot failure in x86 mvlgcc trunk Message-ID: <20080115182932.04E271E4028@bag.python.org> The Buildbot has detected a new failure of x86 mvlgcc trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20mvlgcc%20trunk/builds/1209 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-linux Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: andrew.kuchling,guido.van.rossum BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_doctest make: *** [buildbottest] Fehler 1 sincerely, -The Buildbot From buildbot at python.org Tue Jan 15 19:42:01 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 15 Jan 2008 18:42:01 +0000 Subject: [Python-checkins] buildbot failure in g4 osx.4 3.0 Message-ID: <20080115184201.C8BAE1E4028@bag.python.org> The Buildbot has detected a new failure of g4 osx.4 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/g4%20osx.4%203.0/builds/438 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: psf-g4 Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: guido.van.rossum BUILD FAILED: failed test Excerpt from the test logfile: 2 tests failed: test_urllib2 test_urllib2net ====================================================================== ERROR: testURLread (test.test_urllib2net.URLTimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/test/test_urllib2net.py", line 24, in testURLread f = urllib2.urlopen("http://www.python.org/") File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 121, in urlopen _opener = build_opener() File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 458, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 667, in __init__ proxies = getproxies() File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib.py", line 1270, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_bad_address (test.test_urllib2net.urlopenNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/test/test_urllib2net.py", line 145, in test_bad_address urllib2.urlopen, "http://www.python.invalid./") File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/unittest.py", line 311, in failUnlessRaises callableObj(*args, **kwargs) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 121, in urlopen _opener = build_opener() File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 458, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 667, in __init__ proxies = getproxies() File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib.py", line 1270, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_basic (test.test_urllib2net.urlopenNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/test/test_urllib2net.py", line 103, in test_basic open_url = urllib2.urlopen("http://www.python.org/") File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 121, in urlopen _opener = build_opener() File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 458, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 667, in __init__ proxies = getproxies() File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib.py", line 1270, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_geturl (test.test_urllib2net.urlopenNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/test/test_urllib2net.py", line 127, in test_geturl open_url = urllib2.urlopen(URL) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 121, in urlopen _opener = build_opener() File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 458, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 667, in __init__ proxies = getproxies() File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib.py", line 1270, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_info (test.test_urllib2net.urlopenNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/test/test_urllib2net.py", line 114, in test_info open_url = urllib2.urlopen("http://www.python.org/") File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 121, in urlopen _opener = build_opener() File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 458, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 667, in __init__ proxies = getproxies() File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib.py", line 1270, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_file (test.test_urllib2net.OtherNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/test/test_urllib2net.py", line 185, in test_file self._test_urls(urls, self._extra_handlers()) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/test/test_urllib2net.py", line 233, in _test_urls urllib2.install_opener(urllib2.build_opener(*handlers)) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 458, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 667, in __init__ proxies = getproxies() File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib.py", line 1270, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_ftp (test.test_urllib2net.OtherNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/test/test_urllib2net.py", line 173, in test_ftp self._test_urls(urls, self._extra_handlers()) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/test/test_urllib2net.py", line 233, in _test_urls urllib2.install_opener(urllib2.build_opener(*handlers)) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 458, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 667, in __init__ proxies = getproxies() File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib.py", line 1270, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_http (test.test_urllib2net.OtherNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/test/test_urllib2net.py", line 197, in test_http self._test_urls(urls, self._extra_handlers()) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/test/test_urllib2net.py", line 233, in _test_urls urllib2.install_opener(urllib2.build_opener(*handlers)) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 458, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 667, in __init__ proxies = getproxies() File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib.py", line 1270, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_range (test.test_urllib2net.OtherNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/test/test_urllib2net.py", line 158, in test_range result = urllib2.urlopen(req) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 121, in urlopen _opener = build_opener() File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 458, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 667, in __init__ proxies = getproxies() File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib.py", line 1270, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_close (test.test_urllib2net.CloseSocketTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/test/test_urllib2net.py", line 76, in test_close response = urllib2.urlopen("http://www.python.org/") File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 121, in urlopen _opener = build_opener() File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 458, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 667, in __init__ proxies = getproxies() File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib.py", line 1270, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_ftp_NoneNodefault (test.test_urllib2net.TimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/test/test_urllib2net.py", line 304, in test_ftp_NoneNodefault timeout=None) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 121, in urlopen _opener = build_opener() File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 458, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 667, in __init__ proxies = getproxies() File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib.py", line 1270, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_ftp_NoneWithdefault (test.test_urllib2net.TimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/test/test_urllib2net.py", line 297, in test_ftp_NoneWithdefault timeout=None) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 121, in urlopen _opener = build_opener() File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 458, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 667, in __init__ proxies = getproxies() File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib.py", line 1270, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_ftp_Value (test.test_urllib2net.TimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/test/test_urllib2net.py", line 308, in test_ftp_Value u = urllib2.urlopen("ftp://ftp.mirror.nl/pub/mirror/gnu/", timeout=60) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 121, in urlopen _opener = build_opener() File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 458, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 667, in __init__ proxies = getproxies() File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib.py", line 1270, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_ftp_basic (test.test_urllib2net.TimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/test/test_urllib2net.py", line 289, in test_ftp_basic u = urllib2.urlopen("ftp://ftp.mirror.nl/pub/mirror/gnu/") File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 121, in urlopen _opener = build_opener() File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 458, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 667, in __init__ proxies = getproxies() File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib.py", line 1270, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_http_NoneNodefault (test.test_urllib2net.TimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/test/test_urllib2net.py", line 285, in test_http_NoneNodefault u = urllib2.urlopen("http://www.python.org", timeout=None) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 121, in urlopen _opener = build_opener() File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 458, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 667, in __init__ proxies = getproxies() File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib.py", line 1270, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_http_NoneWithdefault (test.test_urllib2net.TimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/test/test_urllib2net.py", line 275, in test_http_NoneWithdefault u = urllib2.urlopen("http://www.python.org", timeout=None) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 121, in urlopen _opener = build_opener() File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 458, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 667, in __init__ proxies = getproxies() File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib.py", line 1270, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_http_Value (test.test_urllib2net.TimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/test/test_urllib2net.py", line 281, in test_http_Value u = urllib2.urlopen("http://www.python.org", timeout=120) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 121, in urlopen _opener = build_opener() File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 458, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 667, in __init__ proxies = getproxies() File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib.py", line 1270, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_http_basic (test.test_urllib2net.TimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/test/test_urllib2net.py", line 268, in test_http_basic u = urllib2.urlopen("http://www.python.org") File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 121, in urlopen _opener = build_opener() File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 458, in build_opener opener.add_handler(klass()) File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib2.py", line 667, in __init__ proxies = getproxies() File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/urllib.py", line 1270, in getproxies return getproxies_environment() or getproxies_internetconfig() TypeError: 'NoneType' object is not callable make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Tue Jan 15 19:58:47 2008 From: python-checkins at python.org (thomas.heller) Date: Tue, 15 Jan 2008 19:58:47 +0100 (CET) Subject: [Python-checkins] r59985 - peps/trunk/pep-3118.txt Message-ID: <20080115185847.572541E4010@bag.python.org> Author: thomas.heller Date: Tue Jan 15 19:58:47 2008 New Revision: 59985 Modified: peps/trunk/pep-3118.txt Log: Fix typos. Modified: peps/trunk/pep-3118.txt ============================================================================== --- peps/trunk/pep-3118.txt (original) +++ peps/trunk/pep-3118.txt Tue Jan 15 19:58:47 2008 @@ -18,7 +18,7 @@ Python 3.0 In particular, it is proposed that the character buffer portion -of the API be elminated and the multiple-segment portion be +of the API be eliminated and the multiple-segment portion be re-designed in conjunction with allowing for strided memory to be shared. In addition, the new buffer interface will allow the sharing of any multi-dimensional nature of the @@ -218,7 +218,7 @@ ================ ================= ========================== Care should be taken not to LOCK the buffer unless it is really - necessary (especially the exlcusive write lock) as it makes the + necessary (especially the exclusive write lock) as it makes the object unable to share its memory until the lock is released. ``PyBUF_FORMAT`` From buildbot at python.org Tue Jan 15 20:12:43 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 15 Jan 2008 19:12:43 +0000 Subject: [Python-checkins] buildbot failure in x86 FreeBSD trunk Message-ID: <20080115191243.6C1271E4036@bag.python.org> The Buildbot has detected a new failure of x86 FreeBSD trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20FreeBSD%20trunk/builds/402 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-freebsd Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: andrew.kuchling,guido.van.rossum BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 523, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable 2 tests failed: test_doctest test_xmlrpc sincerely, -The Buildbot From buildbot at python.org Tue Jan 15 20:13:47 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 15 Jan 2008 19:13:47 +0000 Subject: [Python-checkins] buildbot failure in sparc solaris10 gcc trunk Message-ID: <20080115191347.20A381E4010@bag.python.org> The Buildbot has detected a new failure of sparc solaris10 gcc trunk. Full details are available at: http://www.python.org/dev/buildbot/all/sparc%20solaris10%20gcc%20trunk/builds/2615 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-sun Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: andrew.kuchling,guido.van.rossum BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_doctest sincerely, -The Buildbot From buildbot at python.org Tue Jan 15 20:33:41 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 15 Jan 2008 19:33:41 +0000 Subject: [Python-checkins] buildbot failure in g4 osx.4 trunk Message-ID: <20080115193341.E321E1E4010@bag.python.org> The Buildbot has detected a new failure of g4 osx.4 trunk. Full details are available at: http://www.python.org/dev/buildbot/all/g4%20osx.4%20trunk/builds/2614 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: psf-g4 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: andrew.kuchling,guido.van.rossum BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_doctest make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Tue Jan 15 20:38:30 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 15 Jan 2008 19:38:30 +0000 Subject: [Python-checkins] buildbot failure in ia64 Ubuntu trunk Message-ID: <20080115193830.B95071E4010@bag.python.org> The Buildbot has detected a new failure of ia64 Ubuntu trunk. Full details are available at: http://www.python.org/dev/buildbot/all/ia64%20Ubuntu%20trunk/builds/1286 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ia64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: andrew.kuchling,guido.van.rossum BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_doctest make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Tue Jan 15 20:52:56 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 15 Jan 2008 19:52:56 +0000 Subject: [Python-checkins] buildbot failure in hppa Ubuntu trunk Message-ID: <20080115195256.4DAF61E4010@bag.python.org> The Buildbot has detected a new failure of hppa Ubuntu trunk. Full details are available at: http://www.python.org/dev/buildbot/all/hppa%20Ubuntu%20trunk/builds/521 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-ubuntu-hppa Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: andrew.kuchling,guido.van.rossum BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_doctest make: *** [buildbottest] Error 1 sincerely, -The Buildbot From nnorwitz at gmail.com Tue Jan 15 22:08:54 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Tue, 15 Jan 2008 16:08:54 -0500 Subject: [Python-checkins] Python Regression Test Failures basics (1) Message-ID: <20080115210854.GA746@python.psfb.org> test_grammar test_opcodes test_dict test_builtin test_exceptions test_types test_unittest test_doctest ********************************************************************** File "/tmp/python-test/local/lib/python2.6/test/test_doctest.py", line 1567, in test.test_doctest.test_debug Failed example: try: doctest.debug_src(s) finally: sys.stdin = real_stdin Expected: > (1)() (Pdb) next 12 --Return-- > (1)()->None (Pdb) print x 12 (Pdb) continue Got: > (1)() (Pdb) next 12 --Return-- > (1)()->None (Pdb) print x 12 *** NameError: name 'save_stdout' is not defined (Pdb) continue ********************************************************************** File "/tmp/python-test/local/lib/python2.6/test/test_doctest.py", line 1608, in test.test_doctest.test_pdb_set_trace Failed example: try: runner.run(test) finally: sys.stdin = real_stdin Expected: --Return-- > (1)()->None -> import pdb; pdb.set_trace() (Pdb) print x 42 (Pdb) continue TestResults(failed=0, attempted=2) Got: --Return-- > (1)()->None -> import pdb; pdb.set_trace() (Pdb) print x 42 *** NameError: name 'save_stdout' is not defined (Pdb) continue TestResults(failed=0, attempted=2) ********************************************************************** File "/tmp/python-test/local/lib/python2.6/test/test_doctest.py", line 1637, in test.test_doctest.test_pdb_set_trace Failed example: try: runner.run(test) finally: sys.stdin = real_stdin Expected: --Return-- > (3)calls_set_trace()->None -> import pdb; pdb.set_trace() (Pdb) print y 2 (Pdb) up > (1)() -> calls_set_trace() (Pdb) print x 1 (Pdb) continue TestResults(failed=0, attempted=2) Got: --Return-- > (3)calls_set_trace()->None -> import pdb; pdb.set_trace() (Pdb) print y 2 *** NameError: name 'save_stdout' is not defined (Pdb) up > (1)() -> calls_set_trace() (Pdb) print x 1 *** NameError: name 'save_stdout' is not defined (Pdb) continue TestResults(failed=0, attempted=2) ********************************************************************** File "/tmp/python-test/local/lib/python2.6/test/test_doctest.py", line 1748, in test.test_doctest.test_pdb_set_trace_nested Failed example: try: runner.run(test) finally: sys.stdin = real_stdin Expected: > (5)calls_set_trace() -> self.f1() (Pdb) print y 1 (Pdb) step --Call-- > (7)f1() -> def f1(self): (Pdb) step > (8)f1() -> x = 1 (Pdb) step > (9)f1() -> self.f2() (Pdb) step --Call-- > (11)f2() -> def f2(self): (Pdb) step > (12)f2() -> z = 1 (Pdb) step > (13)f2() -> z = 2 (Pdb) print z 1 (Pdb) up > (9)f1() -> self.f2() (Pdb) print x 1 (Pdb) up > (5)calls_set_trace() -> self.f1() (Pdb) print y 1 (Pdb) up > (1)() -> calls_set_trace() (Pdb) print foo *** NameError: name 'foo' is not defined (Pdb) continue TestResults(failed=0, attempted=2) Got: > (5)calls_set_trace() -> self.f1() (Pdb) print y 1 *** NameError: name 'save_stdout' is not defined (Pdb) step --Call-- > (7)f1() -> def f1(self): (Pdb) step > (8)f1() -> x = 1 (Pdb) step > (9)f1() -> self.f2() (Pdb) step --Call-- > (11)f2() -> def f2(self): (Pdb) step > (12)f2() -> z = 1 (Pdb) step > (13)f2() -> z = 2 (Pdb) print z 1 *** NameError: name 'save_stdout' is not defined (Pdb) up > (9)f1() -> self.f2() (Pdb) print x 1 *** NameError: name 'save_stdout' is not defined (Pdb) up > (5)calls_set_trace() -> self.f1() (Pdb) print y 1 *** NameError: name 'save_stdout' is not defined (Pdb) up > (1)() -> calls_set_trace() (Pdb) print foo *** NameError: name 'save_stdout' is not defined (Pdb) continue TestResults(failed=0, attempted=2) ********************************************************************** 3 items had failures: 1 of 5 in test.test_doctest.test_debug 2 of 19 in test.test_doctest.test_pdb_set_trace 1 of 9 in test.test_doctest.test_pdb_set_trace_nested ***Test Failed*** 4 failures. test test_doctest failed -- 4 of 419 doctests failed test_doctest2 test_MimeWriter test_StringIO test___all__ test___future__ test__locale test_abc test_abstract_numbers test_aepack test_aepack skipped -- No module named aepack test_al test_al skipped -- No module named al test_anydbm test_applesingle test_applesingle skipped -- No module named macostools test_array test_ast test_asynchat WARNING: failed to listen on port 54322, trying another WARNING: failed to listen on port 9907, trying another test_asyncore test_atexit test_audioop test_augassign test_base64 test_bastion test_bigaddrspace test_bigmem test_binascii test_binhex test_binop test_bisect test_bool test_bsddb test_bsddb185 test_bsddb185 skipped -- No module named bsddb185 test_bsddb3 test_bsddb3 skipped -- Use of the `bsddb' resource not enabled test_buffer test_bufio test_bz2 test_cProfile test_calendar test_call test_capi test_cd test_cd skipped -- No module named cd test_cfgparser test_cgi test_charmapcodec test_cl test_cl skipped -- No module named cl test_class test_cmath test_cmd test_cmd_line test_cmd_line_script test_code test_codeccallbacks test_codecencodings_cn test_codecencodings_hk test_codecencodings_jp test_codecencodings_kr test_codecencodings_tw test_codecmaps_cn test_codecmaps_cn skipped -- Use of the `urlfetch' resource not enabled test_codecmaps_hk test_codecmaps_hk skipped -- Use of the `urlfetch' resource not enabled test_codecmaps_jp test_codecmaps_jp skipped -- Use of the `urlfetch' resource not enabled test_codecmaps_kr test_codecmaps_kr skipped -- Use of the `urlfetch' resource not enabled test_codecmaps_tw test_codecmaps_tw skipped -- Use of the `urlfetch' resource not enabled test_codecs test_codeop test_coding test_coercion test_collections test_colorsys test_commands test_compare test_compile test_compiler test_complex test_complex_args test_contains test_contextlib test_cookie test_cookielib test_copy test_copy_reg test_cpickle test_crypt test_csv test_ctypes test_curses test_curses skipped -- Use of the `curses' resource not enabled test_datetime test_dbm test_decimal test_decorators test_defaultdict test_deque test_descr test_descrtut test_difflib test_dircache test_dis test_distutils test_dl test_docxmlrpc test_dumbdbm test_dummy_thread test_dummy_threading test_email test_email_codecs test_email_renamed test_enumerate test_eof test_errno test_exception_variations test_extcall test_fcntl test_file test_filecmp test_fileinput test_float test_fnmatch test_fork1 test_format test_fpformat test_frozen test_ftplib test_funcattrs test_functools test_future test_gc test_gdbm test_generators test_genericpath test_genexps test_getargs test_getargs2 test_getopt test_gettext test_gl test_gl skipped -- No module named gl test_glob test_global test_grp test_gzip test_hash test_hashlib test_heapq test_hexoct test_hmac test_hotshot test_htmllib test_htmlparser test_httplib test_imageop test_imageop skipped -- No module named imgfile test_imaplib test_imgfile test_imgfile skipped -- No module named imgfile test_imp test_import test_importhooks test_index test_inspect test_ioctl test_ioctl skipped -- Unable to open /dev/tty test_isinstance test_iter test_iterlen test_itertools test_largefile test_linuxaudiodev test_linuxaudiodev skipped -- Use of the `audio' resource not enabled test_list test_locale test_logging test_long test_long_future test_longexp test_macostools test_macostools skipped -- No module named macostools test_macpath test_mailbox test_marshal test_math test_md5 test_mhlib test_mimetools test_mimetypes test_minidom test_mmap test_module test_modulefinder test_multibytecodec test_multibytecodec_support test_multifile test_mutants test_netrc test_new test_nis test_normalization test_normalization skipped -- Use of the `urlfetch' resource not enabled test_ntpath test_old_mailbox test_openpty test_operator test_optparse test_os test_ossaudiodev test_ossaudiodev skipped -- Use of the `audio' resource not enabled test_parser test_peepholer test_pep247 test_pep263 test_pep277 test_pep277 skipped -- test works only on NT+ test_pep292 test_pep352 test_pickle test_pickletools test_pipes test_pkg test_pkgimport test_platform test_plistlib test_plistlib skipped -- No module named plistlib test_poll test_popen [8896 refs] [8896 refs] [8896 refs] test_popen2 test_poplib test_posix test_posixpath test_pow test_pprint test_profile test_profilehooks test_property test_pty test_pwd test_pyclbr test_pyexpat test_queue test_quopri [9265 refs] [9265 refs] test_random test_rational test_re test_repr test_resource test_rfc822 test_richcmp test_robotparser test_runpy test_sax test_scope test_scriptpackages test_scriptpackages skipped -- No module named aetools test_select test_set test_sets test_sgmllib test_sha test_shelve test_shlex test_shutil test_signal test_site test_slice test_smtplib test_socket test_socket_ssl /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:94: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ssl_sock = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:130: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:144: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) test_socketserver test_socketserver skipped -- Use of the `network' resource not enabled test_softspace test_sort test_sqlite test_ssl test_startfile test_startfile skipped -- cannot import name startfile test_str test_strftime test_string test_stringprep test_strop test_strptime test_struct test_structmembers test_structseq test_subprocess [8891 refs] [8894 refs] [8891 refs] [8891 refs] [8891 refs] [8891 refs] [8891 refs] [8891 refs] [8891 refs] [8893 refs] [8894 refs] [10445 refs] [9109 refs] [8894 refs] [8891 refs] [8891 refs] [8891 refs] [8891 refs] [8891 refs] . [8891 refs] [8891 refs] this bit of output is from a test of stdout in a different process ... [8891 refs] [8891 refs] [9109 refs] test_sunaudiodev test_sunaudiodev skipped -- No module named sunaudiodev test_sundry test_symtable test_syntax test_sys [8891 refs] [8891 refs] test_tarfile test_tcl test_tcl skipped -- No module named _tkinter test_telnetlib test_tempfile [8897 refs] test_textwrap test_thread test_threaded_import test_threadedtempfile test_threading [11941 refs] test_threading_local test_threadsignals test_time test_timeout test_timeout skipped -- Use of the `network' resource not enabled test_tokenize test_trace test_traceback test_transformer test_tuple test_typechecks test_ucn test_unary test_unicode test_unicode_file test_unicode_file skipped -- No Unicode filesystem semantics on this platform. test_unicodedata test_univnewlines test_unpack test_urllib test_urllib2 test_urllib2_localnet test_urllib2net test_urllib2net skipped -- Use of the `network' resource not enabled test_urllibnet test_urllibnet skipped -- Use of the `network' resource not enabled test_urlparse test_userdict test_userlist test_userstring test_uu test_uuid WARNING: uuid.getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._ifconfig_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._unixdll_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. test_wait3 test_wait4 test_warnings test_wave test_weakref test_whichdb test_winreg test_winreg skipped -- No module named _winreg test_winsound test_winsound skipped -- No module named winsound test_with test_wsgiref test_xdrlib test_xml_etree test_xml_etree_c test_xmllib test_xmlrpc test_xpickle test_xrange test_zipfile test_zipfile64 test_zipfile64 skipped -- test requires loads of disk-space bytes and a long time to run test_zipimport test_zlib 302 tests OK. 1 test failed: test_doctest 35 tests skipped: test_aepack test_al test_applesingle test_bsddb185 test_bsddb3 test_cd test_cl test_codecmaps_cn test_codecmaps_hk test_codecmaps_jp test_codecmaps_kr test_codecmaps_tw test_curses test_gl test_imageop test_imgfile test_ioctl test_linuxaudiodev test_macostools test_normalization test_ossaudiodev test_pep277 test_plistlib test_scriptpackages test_socketserver test_startfile test_sunaudiodev test_tcl test_timeout test_unicode_file test_urllib2net test_urllibnet test_winreg test_winsound test_zipfile64 1 skip unexpected on linux2: test_ioctl [531144 refs] From python-checkins at python.org Tue Jan 15 21:52:42 2008 From: python-checkins at python.org (raymond.hettinger) Date: Tue, 15 Jan 2008 21:52:42 +0100 (CET) Subject: [Python-checkins] r59987 - in python/trunk: Doc/library/collections.rst Lib/Queue.py Message-ID: <20080115205242.DA8C71E4010@bag.python.org> Author: raymond.hettinger Date: Tue Jan 15 21:52:42 2008 New Revision: 59987 Modified: python/trunk/Doc/library/collections.rst python/trunk/Lib/Queue.py Log: Refactor if/elif chain for clarity and speed. Remove dependency on subclasses having to implement _empty and _full. Modified: python/trunk/Doc/library/collections.rst ============================================================================== --- python/trunk/Doc/library/collections.rst (original) +++ python/trunk/Doc/library/collections.rst Tue Jan 15 21:52:42 2008 @@ -535,6 +535,14 @@ def _replace(self, _map=map, **kwds): return self._make(_map(kwds.get, ('x', 'y'), self)) +Note, subclasses should set ``__slots__`` to an empty tuple so that +an instance dictionary will not be created and the memory overhead +will be kept to zero. + +Note, subclasses should set ``__slots__`` to an empty tuple. This +reduces memory usage by + + Subclassing is not useful for adding new, stored fields. Instead, simply create a new named tuple type from the :attr:`_fields` attribute:: Modified: python/trunk/Lib/Queue.py ============================================================================== --- python/trunk/Lib/Queue.py (original) +++ python/trunk/Lib/Queue.py Tue Jan 15 21:52:42 2008 @@ -23,6 +23,7 @@ import threading except ImportError: import dummy_threading as threading + self.maxsize = maxsize self._init(maxsize) # mutex must be held whenever the queue is mutating. All methods # that acquire mutex must release it before returning. mutex @@ -91,14 +92,14 @@ def empty(self): """Return True if the queue is empty, False otherwise (not reliable!).""" self.mutex.acquire() - n = self._empty() + n = not self._qsize() self.mutex.release() return n def full(self): """Return True if the queue is full, False otherwise (not reliable!).""" self.mutex.acquire() - n = self._full() + n = 0 < self.maxsize == self._qsize() self.mutex.release() return n @@ -115,21 +116,22 @@ """ self.not_full.acquire() try: - if not block: - if self._full(): - raise Full - elif timeout is None: - while self._full(): - self.not_full.wait() - else: - if timeout < 0: - raise ValueError("'timeout' must be a positive number") - endtime = _time() + timeout - while self._full(): - remaining = endtime - _time() - if remaining <= 0.0: + if self.maxsize > 0: + if not block: + if self._qsize() == self.maxsize: raise Full - self.not_full.wait(remaining) + elif timeout is None: + while self._qsize() == self.maxsize: + self.not_full.wait() + elif timeout < 0: + raise ValueError("'timeout' must be a positive number") + else: + endtime = _time() + timeout + while self._qsize() == self.maxsize: + remaining = endtime - _time() + if remaining <= 0.0: + raise Full + self.not_full.wait(remaining) self._put(item) self.unfinished_tasks += 1 self.not_empty.notify() @@ -158,16 +160,16 @@ self.not_empty.acquire() try: if not block: - if self._empty(): + if not self._qsize(): raise Empty elif timeout is None: - while self._empty(): + while not self._qsize(): self.not_empty.wait() + elif timeout < 0: + raise ValueError("'timeout' must be a positive number") else: - if timeout < 0: - raise ValueError("'timeout' must be a positive number") endtime = _time() + timeout - while self._empty(): + while not self._qsize(): remaining = endtime - _time() if remaining <= 0.0: raise Empty @@ -192,20 +194,11 @@ # Initialize the queue representation def _init(self, maxsize): - self.maxsize = maxsize self.queue = deque() def _qsize(self): return len(self.queue) - # Check whether the queue is empty - def _empty(self): - return not self.queue - - # Check whether the queue is full - def _full(self): - return self.maxsize > 0 and len(self.queue) == self.maxsize - # Put a new item in the queue def _put(self, item): self.queue.append(item) From nnorwitz at gmail.com Tue Jan 15 22:18:58 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Tue, 15 Jan 2008 16:18:58 -0500 Subject: [Python-checkins] Python Regression Test Failures opt (1) Message-ID: <20080115211858.GA4939@python.psfb.org> test_grammar test_opcodes test_dict test_builtin test_exceptions test_types test_unittest test_doctest ********************************************************************** File "/tmp/python-test/local/lib/python2.6/test/test_doctest.py", line 1567, in test.test_doctest.test_debug Failed example: try: doctest.debug_src(s) finally: sys.stdin = real_stdin Expected: > (1)() (Pdb) next 12 --Return-- > (1)()->None (Pdb) print x 12 (Pdb) continue Got: > (1)() (Pdb) next 12 --Return-- > (1)()->None (Pdb) print x 12 *** NameError: name 'save_stdout' is not defined (Pdb) continue ********************************************************************** File "/tmp/python-test/local/lib/python2.6/test/test_doctest.py", line 1608, in test.test_doctest.test_pdb_set_trace Failed example: try: runner.run(test) finally: sys.stdin = real_stdin Expected: --Return-- > (1)()->None -> import pdb; pdb.set_trace() (Pdb) print x 42 (Pdb) continue TestResults(failed=0, attempted=2) Got: --Return-- > (1)()->None -> import pdb; pdb.set_trace() (Pdb) print x 42 *** NameError: name 'save_stdout' is not defined (Pdb) continue TestResults(failed=0, attempted=2) ********************************************************************** File "/tmp/python-test/local/lib/python2.6/test/test_doctest.py", line 1637, in test.test_doctest.test_pdb_set_trace Failed example: try: runner.run(test) finally: sys.stdin = real_stdin Expected: --Return-- > (3)calls_set_trace()->None -> import pdb; pdb.set_trace() (Pdb) print y 2 (Pdb) up > (1)() -> calls_set_trace() (Pdb) print x 1 (Pdb) continue TestResults(failed=0, attempted=2) Got: --Return-- > (3)calls_set_trace()->None -> import pdb; pdb.set_trace() (Pdb) print y 2 *** NameError: name 'save_stdout' is not defined (Pdb) up > (1)() -> calls_set_trace() (Pdb) print x 1 *** NameError: name 'save_stdout' is not defined (Pdb) continue TestResults(failed=0, attempted=2) ********************************************************************** File "/tmp/python-test/local/lib/python2.6/test/test_doctest.py", line 1748, in test.test_doctest.test_pdb_set_trace_nested Failed example: try: runner.run(test) finally: sys.stdin = real_stdin Expected: > (5)calls_set_trace() -> self.f1() (Pdb) print y 1 (Pdb) step --Call-- > (7)f1() -> def f1(self): (Pdb) step > (8)f1() -> x = 1 (Pdb) step > (9)f1() -> self.f2() (Pdb) step --Call-- > (11)f2() -> def f2(self): (Pdb) step > (12)f2() -> z = 1 (Pdb) step > (13)f2() -> z = 2 (Pdb) print z 1 (Pdb) up > (9)f1() -> self.f2() (Pdb) print x 1 (Pdb) up > (5)calls_set_trace() -> self.f1() (Pdb) print y 1 (Pdb) up > (1)() -> calls_set_trace() (Pdb) print foo *** NameError: name 'foo' is not defined (Pdb) continue TestResults(failed=0, attempted=2) Got: > (5)calls_set_trace() -> self.f1() (Pdb) print y 1 *** NameError: name 'save_stdout' is not defined (Pdb) step --Call-- > (7)f1() -> def f1(self): (Pdb) step > (8)f1() -> x = 1 (Pdb) step > (9)f1() -> self.f2() (Pdb) step --Call-- > (11)f2() -> def f2(self): (Pdb) step > (12)f2() -> z = 1 (Pdb) step > (13)f2() -> z = 2 (Pdb) print z 1 *** NameError: name 'save_stdout' is not defined (Pdb) up > (9)f1() -> self.f2() (Pdb) print x 1 *** NameError: name 'save_stdout' is not defined (Pdb) up > (5)calls_set_trace() -> self.f1() (Pdb) print y 1 *** NameError: name 'save_stdout' is not defined (Pdb) up > (1)() -> calls_set_trace() (Pdb) print foo *** NameError: name 'save_stdout' is not defined (Pdb) continue TestResults(failed=0, attempted=2) ********************************************************************** 3 items had failures: 1 of 5 in test.test_doctest.test_debug 2 of 19 in test.test_doctest.test_pdb_set_trace 1 of 9 in test.test_doctest.test_pdb_set_trace_nested ***Test Failed*** 4 failures. test test_doctest failed -- 4 of 419 doctests failed test_doctest2 test_MimeWriter test_StringIO test___all__ test___future__ test__locale test_abc test_abstract_numbers test_aepack test_aepack skipped -- No module named aepack test_al test_al skipped -- No module named al test_anydbm test_applesingle test_applesingle skipped -- No module named macostools test_array test_ast test_asynchat WARNING: failed to listen on port 54322, trying another WARNING: failed to listen on port 9907, trying another test_asyncore test_atexit test_audioop test_augassign test_base64 test_bastion test_bigaddrspace test_bigmem test_binascii test_binhex test_binop test_bisect test_bool test_bsddb test_bsddb185 test_bsddb185 skipped -- No module named bsddb185 test_bsddb3 test_bsddb3 skipped -- Use of the `bsddb' resource not enabled test_buffer test_bufio test_bz2 test_cProfile test_calendar test_call test_capi test_cd test_cd skipped -- No module named cd test_cfgparser test_cgi test_charmapcodec test_cl test_cl skipped -- No module named cl test_class test_cmath test_cmd test_cmd_line test_cmd_line_script test_code test_codeccallbacks test_codecencodings_cn test_codecencodings_hk test_codecencodings_jp test_codecencodings_kr test_codecencodings_tw test_codecmaps_cn test_codecmaps_cn skipped -- Use of the `urlfetch' resource not enabled test_codecmaps_hk test_codecmaps_hk skipped -- Use of the `urlfetch' resource not enabled test_codecmaps_jp test_codecmaps_jp skipped -- Use of the `urlfetch' resource not enabled test_codecmaps_kr test_codecmaps_kr skipped -- Use of the `urlfetch' resource not enabled test_codecmaps_tw test_codecmaps_tw skipped -- Use of the `urlfetch' resource not enabled test_codecs test_codeop test_coding test_coercion test_collections test_colorsys test_commands test_compare test_compile test_compiler test_complex test_complex_args test_contains test_contextlib test_cookie test_cookielib test_copy test_copy_reg test_cpickle test_crypt test_csv test_ctypes test_curses test_curses skipped -- Use of the `curses' resource not enabled test_datetime test_dbm test_decimal test_decorators test_defaultdict test_deque test_descr test_descrtut test_difflib test_dircache test_dis test_distutils [10620 refs] test_dl test_docxmlrpc test_dumbdbm test_dummy_thread test_dummy_threading test_email test_email_codecs test_email_renamed test_enumerate test_eof test_errno test_exception_variations test_extcall test_fcntl test_file test_filecmp test_fileinput test_float test_fnmatch test_fork1 test_format test_fpformat test_frozen test_ftplib test_funcattrs test_functools test_future test_gc test_gdbm test_generators test_genericpath test_genexps test_getargs test_getargs2 test_getopt test_gettext test_gl test_gl skipped -- No module named gl test_glob test_global test_grp test_gzip test_hash test_hashlib test_heapq test_hexoct test_hmac test_hotshot test_htmllib test_htmlparser test_httplib test_imageop test_imageop skipped -- No module named imgfile test_imaplib test_imgfile test_imgfile skipped -- No module named imgfile test_imp test_import test_importhooks test_index test_inspect test_ioctl test_ioctl skipped -- Unable to open /dev/tty test_isinstance test_iter test_iterlen test_itertools test_largefile test_linuxaudiodev test_linuxaudiodev skipped -- Use of the `audio' resource not enabled test_list test_locale test_logging test_long test_long_future test_longexp test_macostools test_macostools skipped -- No module named macostools test_macpath test_mailbox test_marshal test_math test_md5 test_mhlib test_mimetools test_mimetypes test_minidom test_mmap test_module test_modulefinder test_multibytecodec test_multibytecodec_support test_multifile test_mutants test_netrc test_new test_nis test_normalization test_normalization skipped -- Use of the `urlfetch' resource not enabled test_ntpath test_old_mailbox test_openpty test_operator test_optparse test_os test_ossaudiodev test_ossaudiodev skipped -- Use of the `audio' resource not enabled test_parser test_peepholer test_pep247 test_pep263 test_pep277 test_pep277 skipped -- test works only on NT+ test_pep292 test_pep352 test_pickle test_pickletools test_pipes test_pkg test_pkgimport test_platform test_plistlib test_plistlib skipped -- No module named plistlib test_poll test_popen [8896 refs] [8896 refs] [8896 refs] test_popen2 test_poplib test test_poplib failed -- errors occurred; run in verbose mode for details test_posix test_posixpath test_pow test_pprint test_profile test_profilehooks test_property test_pty test_pwd test_pyclbr test_pyexpat test_queue test_quopri [9265 refs] [9265 refs] test_random test_rational test_re test_repr test_resource test_rfc822 test_richcmp test_robotparser test_runpy test_sax test_scope test_scriptpackages test_scriptpackages skipped -- No module named aetools test_select test_set test_sets test_sgmllib test_sha test_shelve test_shlex test_shutil test_signal test_site test_slice test_smtplib test_socket test_socket_ssl /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:94: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ssl_sock = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:130: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:144: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) test_socketserver test_socketserver skipped -- Use of the `network' resource not enabled test_softspace test_sort test_sqlite test_ssl test_startfile test_startfile skipped -- cannot import name startfile test_str test_strftime test_string test_stringprep test_strop test_strptime test_struct test_structmembers test_structseq test_subprocess [8891 refs] [8894 refs] [8891 refs] [8891 refs] [8891 refs] [8891 refs] [8891 refs] [8891 refs] [8891 refs] [8893 refs] [8894 refs] [10445 refs] [9109 refs] [8894 refs] [8891 refs] [8891 refs] [8891 refs] [8891 refs] [8891 refs] . [8891 refs] [8891 refs] this bit of output is from a test of stdout in a different process ... [8891 refs] [8891 refs] [9109 refs] test_sunaudiodev test_sunaudiodev skipped -- No module named sunaudiodev test_sundry test_symtable test_syntax test_sys [8891 refs] [8891 refs] test_tarfile test_tcl test_tcl skipped -- No module named _tkinter test_telnetlib test_tempfile [8897 refs] test_textwrap test_thread test_threaded_import test_threadedtempfile test_threading [11941 refs] test_threading_local test_threadsignals test_time test_timeout test_timeout skipped -- Use of the `network' resource not enabled test_tokenize test_trace test_traceback test_transformer test_tuple test_typechecks test_ucn test_unary test_unicode test_unicode_file test_unicode_file skipped -- No Unicode filesystem semantics on this platform. test_unicodedata test_univnewlines test_unpack test_urllib test_urllib2 test_urllib2_localnet test_urllib2net test_urllib2net skipped -- Use of the `network' resource not enabled test_urllibnet test_urllibnet skipped -- Use of the `network' resource not enabled test_urlparse test_userdict test_userlist test_userstring test_uu test_uuid WARNING: uuid.getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._ifconfig_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._unixdll_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. test_wait3 test_wait4 test_warnings test_wave test_weakref test_whichdb test_winreg test_winreg skipped -- No module named _winreg test_winsound test_winsound skipped -- No module named winsound test_with test_wsgiref test_xdrlib test_xml_etree test_xml_etree_c test_xmllib test_xmlrpc test_xpickle test_xrange test_zipfile test_zipfile64 test_zipfile64 skipped -- test requires loads of disk-space bytes and a long time to run test_zipimport test_zlib 301 tests OK. 2 tests failed: test_doctest test_poplib 35 tests skipped: test_aepack test_al test_applesingle test_bsddb185 test_bsddb3 test_cd test_cl test_codecmaps_cn test_codecmaps_hk test_codecmaps_jp test_codecmaps_kr test_codecmaps_tw test_curses test_gl test_imageop test_imgfile test_ioctl test_linuxaudiodev test_macostools test_normalization test_ossaudiodev test_pep277 test_plistlib test_scriptpackages test_socketserver test_startfile test_sunaudiodev test_tcl test_timeout test_unicode_file test_urllib2net test_urllibnet test_winreg test_winsound test_zipfile64 1 skip unexpected on linux2: test_ioctl [530771 refs] From buildbot at python.org Tue Jan 15 22:21:17 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 15 Jan 2008 21:21:17 +0000 Subject: [Python-checkins] buildbot failure in ppc Debian unstable 3.0 Message-ID: <20080115212117.B52EE1E4010@bag.python.org> The Buildbot has detected a new failure of ppc Debian unstable 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/ppc%20Debian%20unstable%203.0/builds/466 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_xmlrpc Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 522, in __init__ self.handle() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/BaseHTTPServer.py", line 330, in handle self.handle_one_request() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/BaseHTTPServer.py", line 324, in handle_one_request method() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SimpleXMLRPCServer.py", line 430, in do_POST self.report_404() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SimpleXMLRPCServer.py", line 489, in report_404 self.connection.shutdown(1) socket.error: [Errno 107] Transport endpoint is not connected ====================================================================== ERROR: test_fail_no_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/test/test_xmlrpc.py", line 497, in test_fail_no_info p.pow(6,8) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1091, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1349, in __request verbose=self.__verbose File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1121, in request resp = http_conn.getresponse() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/httplib.py", line 961, in getresponse response.begin() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/httplib.py", line 425, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/httplib.py", line 267, in readheaders line = str(self.fp.readline(), "iso-8859-1") File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/io.py", line 413, in readline b = self.read(nreadahead()) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/io.py", line 475, in read n = self.readinto(b) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/socket.py", line 217, in readinto return self._sock.recv_into(b) socket.error: [Errno 104] Connection reset by peer ====================================================================== ERROR: test_fail_with_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/test/test_xmlrpc.py", line 515, in test_fail_with_info p.pow(6,8) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1091, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1349, in __request verbose=self.__verbose File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1121, in request resp = http_conn.getresponse() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/httplib.py", line 961, in getresponse response.begin() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/httplib.py", line 425, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/httplib.py", line 267, in readheaders line = str(self.fp.readline(), "iso-8859-1") File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/io.py", line 413, in readline b = self.read(nreadahead()) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/io.py", line 475, in read n = self.readinto(b) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/socket.py", line 217, in readinto return self._sock.recv_into(b) socket.error: [Errno 104] Connection reset by peer make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Tue Jan 15 22:22:47 2008 From: python-checkins at python.org (raymond.hettinger) Date: Tue, 15 Jan 2008 22:22:47 +0100 (CET) Subject: [Python-checkins] r59988 - python/trunk/Doc/library/collections.rst Message-ID: <20080115212247.D1FEF1E4010@bag.python.org> Author: raymond.hettinger Date: Tue Jan 15 22:22:47 2008 New Revision: 59988 Modified: python/trunk/Doc/library/collections.rst Log: Fix-up half-written paragraph in the docs Modified: python/trunk/Doc/library/collections.rst ============================================================================== --- python/trunk/Doc/library/collections.rst (original) +++ python/trunk/Doc/library/collections.rst Tue Jan 15 22:22:47 2008 @@ -535,13 +535,9 @@ def _replace(self, _map=map, **kwds): return self._make(_map(kwds.get, ('x', 'y'), self)) -Note, subclasses should set ``__slots__`` to an empty tuple so that -an instance dictionary will not be created and the memory overhead -will be kept to zero. - -Note, subclasses should set ``__slots__`` to an empty tuple. This -reduces memory usage by - +The subclasses shown above set ``__slots__`` to an empty tuple. This keeps +the named tuples from having per-instance dictionaries, so they will +continue to be lightweight and require no more memory than regular tuples. Subclassing is not useful for adding new, stored fields. Instead, simply create a new named tuple type from the :attr:`_fields` attribute:: From python-checkins at python.org Tue Jan 15 22:25:11 2008 From: python-checkins at python.org (amaury.forgeotdarc) Date: Tue, 15 Jan 2008 22:25:11 +0100 (CET) Subject: [Python-checkins] r59989 - python/trunk/Lib/pdb.py Message-ID: <20080115212511.C54601E4010@bag.python.org> Author: amaury.forgeotdarc Date: Tue Jan 15 22:25:11 2008 New Revision: 59989 Modified: python/trunk/Lib/pdb.py Log: test_doctest fails since r59984. Not sure if these are the correct values, but save_stdout has to be set before its usage... Modified: python/trunk/Lib/pdb.py ============================================================================== --- python/trunk/Lib/pdb.py (original) +++ python/trunk/Lib/pdb.py Tue Jan 15 22:25:11 2008 @@ -199,6 +199,8 @@ globals = self.curframe.f_globals try: code = compile(line + '\n', '', 'single') + save_stdout = sys.stdout + save_stdin = sys.stdin try: sys.stdin = self.stdin sys.stdout = self.stdout From python-checkins at python.org Wed Jan 16 01:32:03 2008 From: python-checkins at python.org (andrew.kuchling) Date: Wed, 16 Jan 2008 01:32:03 +0100 (CET) Subject: [Python-checkins] r59992 - python/trunk/Lib/decimal.py Message-ID: <20080116003203.58F901E4010@bag.python.org> Author: andrew.kuchling Date: Wed Jan 16 01:32:03 2008 New Revision: 59992 Modified: python/trunk/Lib/decimal.py Log: Docstring typos Modified: python/trunk/Lib/decimal.py ============================================================================== --- python/trunk/Lib/decimal.py (original) +++ python/trunk/Lib/decimal.py Wed Jan 16 01:32:03 2008 @@ -2971,7 +2971,7 @@ def _islogical(self): """Return True if self is a logical operand. - For being logical, it must be a finite numbers with a sign of 0, + For being logical, it must be a finite number with a sign of 0, an exponent of 0, and a coefficient whose digits must all be either 0 or 1. """ @@ -4089,7 +4089,7 @@ """max compares two values numerically and returns the maximum. If either operand is a NaN then the general rules apply. - Otherwise, the operands are compared as as though by the compare + Otherwise, the operands are compared as though by the compare operation. If they are numerically equal then the left-hand operand is chosen as the result. Otherwise the maximum (closer to positive infinity) of the two operands is chosen as the result. @@ -4113,7 +4113,7 @@ """min compares two values numerically and returns the minimum. If either operand is a NaN then the general rules apply. - Otherwise, the operands are compared as as though by the compare + Otherwise, the operands are compared as though by the compare operation. If they are numerically equal then the left-hand operand is chosen as the result. Otherwise the minimum (closer to negative infinity) of the two operands is chosen as the result. From python-checkins at python.org Wed Jan 16 04:17:26 2008 From: python-checkins at python.org (andrew.kuchling) Date: Wed, 16 Jan 2008 04:17:26 +0100 (CET) Subject: [Python-checkins] r59993 - python/trunk/Doc/whatsnew/2.6.rst Message-ID: <20080116031726.50B1A1E4010@bag.python.org> Author: andrew.kuchling Date: Wed Jan 16 04:17:25 2008 New Revision: 59993 Modified: python/trunk/Doc/whatsnew/2.6.rst Log: Add PEP 3141 section Modified: python/trunk/Doc/whatsnew/2.6.rst ============================================================================== --- python/trunk/Doc/whatsnew/2.6.rst (original) +++ python/trunk/Doc/whatsnew/2.6.rst Wed Jan 16 04:17:25 2008 @@ -541,6 +541,100 @@ Implemented by XXX. Backported to 2.6 by Benjamin Aranguren, with Alex Martelli. +.. ====================================================================== + +.. _pep-3141: + +PEP 3141: A Type Hierarchy for Numbers +===================================================== + +In Python 3.0, several abstract base classes for numeric types, +inspired by Scheme's numeric tower (XXX add link), are being added. +This change was backported to 2.6 as the :mod:`numbers` module. + +The most general ABC is :class:`Number`. It defines no operations at +all, and only exists to allow checking if an object is a number by +doing ``isinstance(obj, Number)``. + +Numbers are further divided into :class:`Exact` and :class:`Inexact`. +Exact numbers can represent values precisely and operations never +round off the results or introduce tiny errors that may break the +communtativity and associativity properties; inexact numbers may +perform such rounding or introduce small errors. Integers, long +integers, and rational numbers are exact, while floating-point +and complex numbers are inexact. + +:class:`Complex` is a subclass of :class:`Number`. Complex numbers +can undergo the basic operations of addition, subtraction, +multiplication, division, and exponentiation, and you can retrieve the +real and imaginary parts and obtain a number's conjugate. Python's built-in +complex type is an implementation of :class:`Complex`. + +:class:`Real` further derives from :class:`Complex`, and adds +operations that only work on real numbers: :func:`floor`, :func:`trunc`, +rounding, taking the remainder mod N, floor division, +and comparisons. + +:class:`Rational` numbers derive from :class:`Real`, have +:attr:`numerator` and :attr:`denominator` properties, and can be +converted to floats. Python 2.6 adds a simple rational-number class +in the :mod:`rational` module. + +:class:`Integral` numbers derive from :class:`Rational`, and +can be shifted left and right with ``<<`` and ``>>``, +combined using bitwise operations such as ``&`` and ``|``, +and can be used as array indexes and slice boundaries. + +The PEP slightly redefines the existing built-ins :func:`math.floor`, +:func:`math.ceil`, :func:`round`, and adds a new one, :func:`trunc`. All of them +take a :class:`Real` value and return an :class:`Integral`. + +* :func:`math.floor` returns the closest :class:`Integral` that's + smaller than the function's argument. Numeric types can define a + :meth:`__floor__` method to provide a custom implementation. + +* :func:`math.ceil` returns the closest :class:`Integral` that's + greater than the function's argument. It can be provided by a + :meth:`__ceil__` method. + +* :func:`trunc` rounds toward zero, returning the closest + :class:`Integral` that's between the function's argument and zero. + It can be provided by a :meth:`__trunc` method. + +* :func:`round` takes a :class:`Real` and rounds it off, optionally to a + specified number of decimal places. It will call a :meth:`__round__` + method. Whether .5 should be rounded up, or down, or toward the + nearest even number, is left up to the type's implementation. + + +The Rational Module +-------------------------------------------------- + +To fill out the hierarchy of numeric types, a rational-number class +has been added as the :mod:`rational` module. Rational numbers are +represented as a fraction; rational numbers can exactly represent +numbers such as two-thirds that floating-point numbers can only +approximate. + +The :class:`Rational` constructor takes two :class:`Integral` values +that will be the numerator and denominator of the resulting fraction. :: + + >>> from rational import Rational + >>> a = Rational(2, 3) + >>> b = Rational(2, 5) + >>> float(a), float(b) + (0.66666666666666663, 0.40000000000000002) + >>> a+b + rational.Rational(16,15) + >>> a/b + rational.Rational(5,3) + +The :mod:`rational` module is based upon an implementation by Sjoerd +Mullender that was in Python's :file:`Demo/classes/` directory for a +long time. This implementation was significantly updated by Jeffrey +Yaskin. + + Other Language Changes ====================== From buildbot at python.org Wed Jan 16 04:26:17 2008 From: buildbot at python.org (buildbot at python.org) Date: Wed, 16 Jan 2008 03:26:17 +0000 Subject: [Python-checkins] buildbot failure in ARM Linux EABI trunk Message-ID: <20080116032617.6C1F81E4019@bag.python.org> The Buildbot has detected a new failure of ARM Linux EABI trunk. Full details are available at: http://www.python.org/dev/buildbot/all/ARM%20Linux%20EABI%20trunk/builds/7 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-linux-armeabi Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: andrew.kuchling BUILD FAILED: failed test Excerpt from the test logfile: sincerely, -The Buildbot From nnorwitz at gmail.com Wed Jan 16 11:28:15 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Wed, 16 Jan 2008 05:28:15 -0500 Subject: [Python-checkins] Python Regression Test Failures refleak (6) Message-ID: <20080116102815.GA24065@python.psfb.org> test_opcodes leaked [-2, 0, 2] references, sum=0 test_doctest leaked [0, 0, -4] references, sum=-4 test_cmd_line leaked [0, -23, 23] references, sum=0 test_descrtut leaked [-2, 0, 2] references, sum=0 test_dircache leaked [0, 0, -2] references, sum=-2 test_gc leaked [0, -2, 2] references, sum=0 test_genexps leaked [-2, 2, -2] references, sum=-2 test_importhooks leaked [2, 4, 0] references, sum=6 test_os leaked [0, -2, 2] references, sum=0 test_pkgimport leaked [0, -2, 2] references, sum=0 test_sqlite leaked [2, 0, 0] references, sum=2 test_urllib2_localnet leaked [3, 3, 3] references, sum=9 test_urllib2net leaked [0, -2, 0] references, sum=-2 test_weakref leaked [-2, 2, 0] references, sum=0 From python-checkins at python.org Wed Jan 16 11:18:13 2008 From: python-checkins at python.org (christian.heimes) Date: Wed, 16 Jan 2008 11:18:13 +0100 (CET) Subject: [Python-checkins] r59996 - in sandbox/trunk/pep370/Lib: distutils/command/install.py test/test_site.py Message-ID: <20080116101813.596A31E4028@bag.python.org> Author: christian.heimes Date: Wed Jan 16 11:18:12 2008 New Revision: 59996 Modified: sandbox/trunk/pep370/Lib/distutils/command/install.py sandbox/trunk/pep370/Lib/test/test_site.py Log: Finished the integration test for the -s option Added some checks to distutils.commands.install Modified: sandbox/trunk/pep370/Lib/distutils/command/install.py ============================================================================== --- sandbox/trunk/pep370/Lib/distutils/command/install.py (original) +++ sandbox/trunk/pep370/Lib/distutils/command/install.py Wed Jan 16 11:18:12 2008 @@ -425,6 +425,9 @@ return if self.user: + if self.install_userbase is None: + raise DistutilsPlatformError( + "User base directory is not specified") self.install_base = self.install_platbase = self.install_userbase self.select_scheme("unix_user") elif self.home is not None: @@ -453,6 +456,9 @@ def finalize_other (self): # Windows and Mac OS for now if self.user: + if self.install_userbase is None: + raise DistutilsPlatformError( + "User base directory is not specified") self.install_base = self.install_platbase = self.install_userbase self.select_scheme(os.name + "_user") elif self.home is not None: Modified: sandbox/trunk/pep370/Lib/test/test_site.py ============================================================================== --- sandbox/trunk/pep370/Lib/test/test_site.py (original) +++ sandbox/trunk/pep370/Lib/test/test_site.py Wed Jan 16 11:18:12 2008 @@ -95,11 +95,21 @@ def test_s_option(self): usersite = site.USER_SITE self.assert_(usersite in sys.path) - cmd = [sys.executable, "-c", - "\"import sys; sys.exit('%s' in sys.path)\"" % usersite - ] - p = subprocess.Popen(cmd) - self.assertEqual(p.wait(), 0) + + rc = subprocess.call([sys.executable, '-c', + 'import sys; sys.exit("%s" in sys.path)' % usersite]) + self.assertEqual(rc, 1) + + rc = subprocess.call([sys.executable, '-s', '-c', + 'import sys; sys.exit("%s" in sys.path)' % usersite]) + self.assertEqual(rc, 0) + + env = os.environ.copy() + env["PYTHONNOUSERSITE"] = "1" + rc = subprocess.call([sys.executable, '-c', + 'import sys; sys.exit("%s" in sys.path)' % usersite], + env=env) + self.assertEqual(rc, 0) class PthFile(object): From python-checkins at python.org Wed Jan 16 11:21:04 2008 From: python-checkins at python.org (christian.heimes) Date: Wed, 16 Jan 2008 11:21:04 +0100 (CET) Subject: [Python-checkins] r59997 - peps/trunk/pep-0369.txt peps/trunk/pep-0370.txt Message-ID: <20080116102104.20CA81E4028@bag.python.org> Author: christian.heimes Date: Wed Jan 16 11:21:03 2008 New Revision: 59997 Modified: peps/trunk/pep-0369.txt peps/trunk/pep-0370.txt Log: Some updates on PEP 369 and 370. PEP 369 still doesn't reflect all changes but it's more up to date Modified: peps/trunk/pep-0369.txt ============================================================================== --- peps/trunk/pep-0369.txt (original) +++ peps/trunk/pep-0369.txt Wed Jan 16 11:21:03 2008 @@ -80,12 +80,14 @@ sys.post_import_hooks contains no entry for the module + A hook is registered and the module is not loaded yet ''''''''''''''''''''''''''''''''''''''''''''''''''''' The import hook registry contains an entry sys.post_import_hooks["name"] = [hook1] + A module is successfully loaded ''''''''''''''''''''''''''''''' @@ -93,8 +95,14 @@ hooks for the newly loaded module. If hooks are found then the hooks are called in the order they were registered with the module instance as first argument. The processing of the hooks is stopped when a method raises an -exception. At the end the entry for the module name is removed from -sys.post_import_hooks, even when an error has occured. +exception. At the end the entry for the module name set to None, even +when an error has occured. + +Additionally the new ``__notified__`` slot of the module object is set +to ``True`` in order to prevent infinity recursions when the notification +method is called inside a hook. For object which don't subclass from +``PyModule`` a new attribute is added instead. + A module can't be loaded '''''''''''''''''''''''' @@ -102,38 +110,80 @@ The import hooks are neither called nor removed from the registry. It may be possible to load the module later. + A hook is registered but the module is already loaded ''''''''''''''''''''''''''''''''''''''''''''''''''''' The hook is fired immediately. +Invariants +---------- + +The import hook system guarentees certain invariants. XXX + + +Sample Python implementation +---------------------------- + +A Python implemenation may look like:: + + def notify(name): + try: + module = sys.modules[name] + except KeyError: + raise ImportError("Module %s has not been imported" % (name,)) + if module.__notified__: + return + try: + module.__notified__ = True + if '.' in name: + notify(name[:name.rfind('.')]) + for callback in post_import_hooks[name]: + callback(module) + finally: + post_import_hooks[name] = None + + XXX + + C API ----- -New PyImport_* API functions -'''''''''''''''''''''''''''' +New C API functions +''''''''''''''''''' ``PyObject* PyImport_GetPostImportHooks(void)`` Returns the dict sys.post_import_hooks or NULL -``PyObject* PyImport_NotifyModuleLoaded(PyObject *module)`` +``PyObject* PyImport_NotifyLoadedByModule(PyObject *module)`` Notify the post import system that a module was requested. Returns the - module or NULL if an error has occured. + a borrowed reference to the same module object or NULL if an error has + occured. The function calls only the hooks for the module itself an not + its parents. The function must be called with the import lock acquired. + +``PyObject* PyImport_NotifyLoadedByName(const char *name)`` + ``PyImport_NotifyLoadedByName("a.b.c")`` calls + ``PyImport_NotifyLoadedByModule()`` for ``a``, ``a.b`` and ``a.b.c`` + in that particular order. The modules are retrieved from + ``sys.modules``. If a module can't be retrieved, an exception is raised + otherwise the a borrowed reference to ``modname`` is returned. + The hook calls always start with the prime parent module. + The caller of PyImport_NotifyLoadedByName() must hold the import lock! ``PyObject* PyImport_RegisterPostImportHook(PyObject *callable, PyObject *mod_name)`` Register a new hook ``callable`` for the module ``mod_name`` -The ``PyImport_PostImportNotify()`` method is called by -``PyImport_ImportModuleLevel()``:: +``int PyModule_GetNotified(PyObject *module)`` + Returns the status of the ``__notified__`` slot / attribute. - PyImport_ImportModuleLevel(...) - { - ... - result = import_module_level(name, globals, locals, fromlist, level); - result = PyImport_PostImportNotify(result); - ... - } +``int PyModule_SetNotified(PyObject *module, int status)`` + Set the status of the ``__notified__`` slot / attribute. + + +The ``PyImport_NotifyLoadedByModule()`` method is called inside +``import_submodule()``. The import system makes sure that the import lock +is acquired and the hooks for the parent modules are already called. Python API @@ -142,16 +192,21 @@ The import hook registry and two new API methods are exposed through the ``sys`` and ``imp`` module. -sys.post_import_hooks - The dict contains the post import hooks: {"name" : [hook1, hook2], ...} +``sys.post_import_hooks`` + The dict contains the post import hooks:: -imp.register_post_import_hook(hook: "callable", name: str) + {"name" : [hook1, hook2], ...} + +``imp.register_post_import_hook(hook: "callable", name: str)`` Register a new hook *hook* for the module *name* -imp.notify_module_loaded(module: "module instance") -> module +``imp.notify_module_loaded(module: "module instance") -> module`` Notify the system that a module has been loaded. The method is provided for compatibility with existing lazy / deferred import extensions. +``module.__notified__`` + A slot of a module instance. XXX + The when_imported function decorator is also in the imp module, which is equivalent to:: Modified: peps/trunk/pep-0370.txt ============================================================================== --- peps/trunk/pep-0370.txt (original) +++ peps/trunk/pep-0370.txt Wed Jan 16 11:21:03 2008 @@ -57,14 +57,14 @@ ``~/Library/Python/2.6/site-packages`` Unix ``~/.local/lib/python2.6/site-packages`` - Windows ``%APPDATA%/Python/Python26/site-packages`` -user configuration directory +user data directory Usually the parent directory of the user site directory. It's meant - for Python version specific data like config files. + for Python version specific data like config files, docs, images + and translations. Mac ``~/Library/Python/2.6`` @@ -81,7 +81,6 @@ Mac ``~/Library/Python`` - Unix ``~/.local`` Windows @@ -107,7 +106,7 @@ On Linux ``~/.local`` was chosen in favor over ``~/.python`` because the directory is already used by several other programs in analogy to -``/usr/local``. [7]_ +``/usr/local``. [7]_ [11]_ Implementation @@ -171,6 +170,9 @@ * Should the Windows installer add ``%APPDATA%/Python/Scripts`` to ``PATH``? +* Should the base directory be configurable with an environment variable + like ``PYTHONUSERHOME``? + Reference Implementation ======================== @@ -199,6 +201,7 @@ .. [4] reference implementation http://bugs.python.org/issue1799 + http://svn.python.org/view/sandbox/trunk/pep370 .. [5] MSDN: CSIDL http://msdn2.microsoft.com/en-us/library/bb762494.aspx @@ -218,7 +221,9 @@ .. [10] Discussion about the bin directory http://permalink.gmane.org/gmane.comp.python.devel/91095 - +.. [11] freedesktop.org XGD basedir specs mentions ~/.local + http://www.freedesktop.org/wiki/Specifications/basedir-spec + .. Local Variables: mode: indented-text From python-checkins at python.org Wed Jan 16 14:01:52 2008 From: python-checkins at python.org (andrew.kuchling) Date: Wed, 16 Jan 2008 14:01:52 +0100 (CET) Subject: [Python-checkins] r59998 - python/trunk/Doc/library/socket.rst Message-ID: <20080116130152.335321E402B@bag.python.org> Author: andrew.kuchling Date: Wed Jan 16 14:01:51 2008 New Revision: 59998 Modified: python/trunk/Doc/library/socket.rst Log: Markup fix Modified: python/trunk/Doc/library/socket.rst ============================================================================== --- python/trunk/Doc/library/socket.rst (original) +++ python/trunk/Doc/library/socket.rst Wed Jan 16 14:01:51 2008 @@ -590,7 +590,7 @@ :platform: Windows - The `meth:ioctl` method is a limited interface to the WSAIoctl system + The :meth:`ioctl` method is a limited interface to the WSAIoctl system interface. Please refer to the MSDN documentation for more information. .. versionadded:: 2.6 From python-checkins at python.org Wed Jan 16 17:56:30 2008 From: python-checkins at python.org (georg.brandl) Date: Wed, 16 Jan 2008 17:56:30 +0100 (CET) Subject: [Python-checkins] r59999 - python/trunk/Doc/library/msilib.rst Message-ID: <20080116165630.412D71E4038@bag.python.org> Author: georg.brandl Date: Wed Jan 16 17:56:29 2008 New Revision: 59999 Modified: python/trunk/Doc/library/msilib.rst Log: Fix MSDN library URL. (#1854) Modified: python/trunk/Doc/library/msilib.rst ============================================================================== --- python/trunk/Doc/library/msilib.rst (original) +++ python/trunk/Doc/library/msilib.rst Wed Jan 16 17:56:29 2008 @@ -149,7 +149,7 @@ .. seealso:: - `MSIOpenView `_ + `MSIDatabaseOpenView `_ `MSIDatabaseCommit `_ `MSIGetSummaryInformation `_ From python-checkins at python.org Wed Jan 16 17:57:19 2008 From: python-checkins at python.org (georg.brandl) Date: Wed, 16 Jan 2008 17:57:19 +0100 (CET) Subject: [Python-checkins] r60000 - python/branches/release25-maint/Doc/lib/libmsilib.tex Message-ID: <20080116165719.CCD271E4003@bag.python.org> Author: georg.brandl Date: Wed Jan 16 17:57:19 2008 New Revision: 60000 Modified: python/branches/release25-maint/Doc/lib/libmsilib.tex Log: Backport r59999: fix MSDN link. (#1854) Modified: python/branches/release25-maint/Doc/lib/libmsilib.tex ============================================================================== --- python/branches/release25-maint/Doc/lib/libmsilib.tex (original) +++ python/branches/release25-maint/Doc/lib/libmsilib.tex Wed Jan 16 17:57:19 2008 @@ -138,7 +138,7 @@ \end{methoddesc} \begin{seealso} - \seetitle[http://msdn.microsoft.com/library/default.asp?url=/library/en-us/msi/setup/msiopenview.asp]{MSIOpenView}{} + \seetitle[http://msdn.microsoft.com/library/default.asp?url=/library/en-us/msi/setup/msidatabaseopenview.asp]{MSIDatabaseOpenView}{} \seetitle[http://msdn.microsoft.com/library/default.asp?url=/library/en-us/msi/setup/msidatabasecommit.asp]{MSIDatabaseCommit}{} \seetitle[http://msdn.microsoft.com/library/default.asp?url=/library/en-us/msi/setup/msigetsummaryinformation.asp]{MSIGetSummaryInformation}{} \end{seealso} From python-checkins at python.org Wed Jan 16 20:16:28 2008 From: python-checkins at python.org (thomas.heller) Date: Wed, 16 Jan 2008 20:16:28 +0100 (CET) Subject: [Python-checkins] r60001 - in python/trunk: Lib/ctypes/test/test_arrays.py Misc/NEWS Modules/_ctypes/_ctypes.c Message-ID: <20080116191628.4A22D1E4003@bag.python.org> Author: thomas.heller Date: Wed Jan 16 20:16:27 2008 New Revision: 60001 Modified: python/trunk/Lib/ctypes/test/test_arrays.py python/trunk/Misc/NEWS python/trunk/Modules/_ctypes/_ctypes.c Log: Convert the internal ctypes array type cache to a WeakValueDict so that array types do not live longer than needed. Modified: python/trunk/Lib/ctypes/test/test_arrays.py ============================================================================== --- python/trunk/Lib/ctypes/test/test_arrays.py (original) +++ python/trunk/Lib/ctypes/test/test_arrays.py Wed Jan 16 20:16:27 2008 @@ -116,5 +116,19 @@ self.failUnlessEqual(sz[1:4:2], "o") self.failUnlessEqual(sz.value, "foo") + def test_cache(self): + # Array types are cached internally in the _ctypes extension, + # in a WeakValueDictionary. Make sure the array type is + # removed from the cache when the itemtype goes away. This + # test will not fail, but will show a leak in the testsuite. + + # Create a new type: + class my_int(c_int): + pass + # Create a new array type based on it: + t1 = my_int * 1 + t2 = my_int * 1 + self.failUnless(t1 is t2) + if __name__ == '__main__': unittest.main() Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Wed Jan 16 20:16:27 2008 @@ -364,6 +364,9 @@ Library ------- +- Convert the internal ctypes array type cache to a WeakValueDict so + that array types do not live longer than needed. + - Issue #1786: pdb should use its own stdin/stdout around an exec call and when creating a recursive instance. Modified: python/trunk/Modules/_ctypes/_ctypes.c ============================================================================== --- python/trunk/Modules/_ctypes/_ctypes.c (original) +++ python/trunk/Modules/_ctypes/_ctypes.c Wed Jan 16 20:16:27 2008 @@ -127,6 +127,7 @@ PyObject *PyExc_ArgError; static PyTypeObject Simple_Type; +PyObject *array_types_cache; char *conversion_mode_encoding = NULL; char *conversion_mode_errors = NULL; @@ -4086,16 +4087,10 @@ PyObject * CreateArrayType(PyObject *itemtype, Py_ssize_t length) { - static PyObject *cache; PyObject *key; PyObject *result; char name[256]; - if (cache == NULL) { - cache = PyDict_New(); - if (cache == NULL) - return NULL; - } #if (PY_VERSION_HEX < 0x02050000) key = Py_BuildValue("(Oi)", itemtype, length); #else @@ -4103,12 +4098,12 @@ #endif if (!key) return NULL; - result = PyDict_GetItem(cache, key); + result = PyObject_GetItem(array_types_cache, key); if (result) { - Py_INCREF(result); Py_DECREF(key); return result; - } + } else + PyErr_Clear(); if (!PyType_Check(itemtype)) { PyErr_SetString(PyExc_TypeError, @@ -4138,7 +4133,11 @@ ); if (!result) return NULL; - PyDict_SetItem(cache, key, result); + if (-1 == PyObject_SetItem(array_types_cache, key, result)) { + Py_DECREF(key); + Py_DECREF(result); + return NULL; + } Py_DECREF(key); return result; } @@ -4951,6 +4950,7 @@ init_ctypes(void) { PyObject *m; + PyObject *weakref; /* Note: ob_type is the metatype (the 'type'), defaults to PyType_Type, @@ -4963,6 +4963,16 @@ if (!m) return; + weakref = PyImport_ImportModule("weakref"); + if (weakref == NULL) + return; + array_types_cache = PyObject_CallMethod(weakref, + "WeakValueDictionary", + NULL); + if (array_types_cache == NULL) + return; + Py_DECREF(weakref); + if (PyType_Ready(&PyCArg_Type) < 0) return; From buildbot at python.org Wed Jan 16 20:22:38 2008 From: buildbot at python.org (buildbot at python.org) Date: Wed, 16 Jan 2008 19:22:38 +0000 Subject: [Python-checkins] buildbot failure in ppc Debian unstable trunk Message-ID: <20080116192239.1C76A1E4003@bag.python.org> The Buildbot has detected a new failure of ppc Debian unstable trunk. Full details are available at: http://www.python.org/dev/buildbot/all/ppc%20Debian%20unstable%20trunk/builds/598 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: andrew.kuchling,georg.brandl,thomas.heller BUILD FAILED: failed failed slave lost sincerely, -The Buildbot From buildbot at python.org Wed Jan 16 20:22:39 2008 From: buildbot at python.org (buildbot at python.org) Date: Wed, 16 Jan 2008 19:22:39 +0000 Subject: [Python-checkins] buildbot failure in PPC64 Debian trunk Message-ID: <20080116192240.190FB1E4003@bag.python.org> The Buildbot has detected a new failure of PPC64 Debian trunk. Full details are available at: http://www.python.org/dev/buildbot/all/PPC64%20Debian%20trunk/builds/111 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: andrew.kuchling,georg.brandl,thomas.heller BUILD FAILED: failed failed slave lost sincerely, -The Buildbot From python-checkins at python.org Wed Jan 16 20:24:21 2008 From: python-checkins at python.org (thomas.heller) Date: Wed, 16 Jan 2008 20:24:21 +0100 (CET) Subject: [Python-checkins] r60002 - in python/branches/release25-maint: Misc/NEWS Modules/_ctypes/_ctypes.c Message-ID: <20080116192421.2E56D1E4003@bag.python.org> Author: thomas.heller Date: Wed Jan 16 20:24:20 2008 New Revision: 60002 Modified: python/branches/release25-maint/Misc/NEWS python/branches/release25-maint/Modules/_ctypes/_ctypes.c Log: Backport from trunk: Fix a potential 'SystemError: NULL result without error'. NULL may be a valid return value from PyLong_AsVoidPtr. Also move an older ctypes NEWS item in the correct category. Modified: python/branches/release25-maint/Misc/NEWS ============================================================================== --- python/branches/release25-maint/Misc/NEWS (original) +++ python/branches/release25-maint/Misc/NEWS Wed Jan 16 20:24:20 2008 @@ -12,8 +12,6 @@ Core and builtins ----------------- -- Prevent a segfault when a ctypes NULL function pointer is called. - - Bug #1517: Possible segfault in lookup(). - Issue #1638: %zd configure test fails on Linux. @@ -171,6 +169,10 @@ Extension Modules ----------------- +- Fix a potential 'SystemError: NULL result without error' in _ctypes. + +- Prevent a segfault when a ctypes NULL function pointer is called. + - Bug #1301: Bad assert in _tkinter fixed. - Patch #1114: fix curses module compilation on 64-bit AIX, & possibly Modified: python/branches/release25-maint/Modules/_ctypes/_ctypes.c ============================================================================== --- python/branches/release25-maint/Modules/_ctypes/_ctypes.c (original) +++ python/branches/release25-maint/Modules/_ctypes/_ctypes.c Wed Jan 16 20:24:20 2008 @@ -2896,7 +2896,7 @@ || PyLong_Check(PyTuple_GET_ITEM(args, 0)))) { CDataObject *ob; void *ptr = PyLong_AsVoidPtr(PyTuple_GET_ITEM(args, 0)); - if (ptr == NULL) + if (ptr == NULL && PyErr_Occurred()) return NULL; ob = (CDataObject *)GenericCData_new(type, args, kwds); if (ob == NULL) From python-checkins at python.org Wed Jan 16 20:37:33 2008 From: python-checkins at python.org (thomas.heller) Date: Wed, 16 Jan 2008 20:37:33 +0100 (CET) Subject: [Python-checkins] r60003 - in python/trunk: Lib/ctypes/test/test_structures.py Misc/NEWS Modules/_ctypes/_ctypes.c Message-ID: <20080116193733.A91361E403A@bag.python.org> Author: thomas.heller Date: Wed Jan 16 20:37:33 2008 New Revision: 60003 Modified: python/trunk/Lib/ctypes/test/test_structures.py python/trunk/Misc/NEWS python/trunk/Modules/_ctypes/_ctypes.c Log: Raise a TypeError if conflicting positional and named arguments are passed to a Structure or Union constructor. Modified: python/trunk/Lib/ctypes/test/test_structures.py ============================================================================== --- python/trunk/Lib/ctypes/test/test_structures.py (original) +++ python/trunk/Lib/ctypes/test/test_structures.py Wed Jan 16 20:37:33 2008 @@ -215,6 +215,15 @@ # too long self.assertRaises(ValueError, Person, "1234567", 5) + def test_conflicting_initializers(self): + class POINT(Structure): + _fields_ = [("x", c_int), ("y", c_int)] + # conflicting positional and keyword args + self.assertRaises(TypeError, POINT, 2, 3, x=4) + self.assertRaises(TypeError, POINT, 2, 3, y=4) + + # Should this raise TypeError instead? + self.assertRaises(ValueError, POINT, 2, 3, 4) def test_keyword_initializers(self): class POINT(Structure): Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Wed Jan 16 20:37:33 2008 @@ -364,6 +364,9 @@ Library ------- +- Issue #1831: ctypes now raises a TypeError if conflicting positional + and named arguments are passed to a Structure or Union initializer. + - Convert the internal ctypes array type cache to a WeakValueDict so that array types do not live longer than needed. Modified: python/trunk/Modules/_ctypes/_ctypes.c ============================================================================== --- python/trunk/Modules/_ctypes/_ctypes.c (original) +++ python/trunk/Modules/_ctypes/_ctypes.c Wed Jan 16 20:37:33 2008 @@ -3578,6 +3578,21 @@ return IBUG("_fields_[i][0] failed"); } + if (kwds && PyDict_GetItem(kwds, name)) { + char *field = PyString_AsString(name); + if (field == NULL) { + PyErr_Clear(); + field = "???"; + } + PyErr_Format(PyExc_TypeError, + "duplicate values for field %s", + field); + Py_DECREF(pair); + Py_DECREF(name); + Py_DECREF(fields); + return -1; + } + val = PyTuple_GET_ITEM(args, i); if (-1 == PyObject_SetAttr(self, name, val)) { Py_DECREF(pair); From python-checkins at python.org Wed Jan 16 20:45:51 2008 From: python-checkins at python.org (thomas.heller) Date: Wed, 16 Jan 2008 20:45:51 +0100 (CET) Subject: [Python-checkins] r60004 - in python/trunk: Lib/ctypes/test/test_structures.py Misc/NEWS Modules/_ctypes/_ctypes.c Message-ID: <20080116194551.862E41E4033@bag.python.org> Author: thomas.heller Date: Wed Jan 16 20:45:51 2008 New Revision: 60004 Modified: python/trunk/Lib/ctypes/test/test_structures.py python/trunk/Misc/NEWS python/trunk/Modules/_ctypes/_ctypes.c Log: Raise a TypeError instead of a ValueError when too many initializers are used in a Structure or Union constructor. Modified: python/trunk/Lib/ctypes/test/test_structures.py ============================================================================== --- python/trunk/Lib/ctypes/test/test_structures.py (original) +++ python/trunk/Lib/ctypes/test/test_structures.py Wed Jan 16 20:45:51 2008 @@ -222,8 +222,8 @@ self.assertRaises(TypeError, POINT, 2, 3, x=4) self.assertRaises(TypeError, POINT, 2, 3, y=4) - # Should this raise TypeError instead? - self.assertRaises(ValueError, POINT, 2, 3, 4) + # too many initializers + self.assertRaises(TypeError, POINT, 2, 3, 4) def test_keyword_initializers(self): class POINT(Structure): @@ -320,9 +320,9 @@ self.failUnlessEqual(cls, RuntimeError) if issubclass(Exception, object): self.failUnlessEqual(msg, - "(Phone) : too many initializers") + "(Phone) : too many initializers") else: - self.failUnlessEqual(msg, "(Phone) exceptions.ValueError: too many initializers") + self.failUnlessEqual(msg, "(Phone) exceptions.TypeError: too many initializers") def get_except(self, func, *args): Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Wed Jan 16 20:45:51 2008 @@ -366,6 +366,8 @@ - Issue #1831: ctypes now raises a TypeError if conflicting positional and named arguments are passed to a Structure or Union initializer. + When too many positional arguments are passed, also a TypeError is + raised instead of a ValueError. - Convert the internal ctypes array type cache to a WeakValueDict so that array types do not live longer than needed. Modified: python/trunk/Modules/_ctypes/_ctypes.c ============================================================================== --- python/trunk/Modules/_ctypes/_ctypes.c (original) +++ python/trunk/Modules/_ctypes/_ctypes.c Wed Jan 16 20:45:51 2008 @@ -3557,7 +3557,7 @@ if (PyTuple_GET_SIZE(args) > PySequence_Length(fields)) { Py_DECREF(fields); - PyErr_SetString(PyExc_ValueError, + PyErr_SetString(PyExc_TypeError, "too many initializers"); return -1; } From buildbot at python.org Wed Jan 16 20:55:48 2008 From: buildbot at python.org (buildbot at python.org) Date: Wed, 16 Jan 2008 19:55:48 +0000 Subject: [Python-checkins] buildbot failure in x86 XP-3 trunk Message-ID: <20080116195549.07C761E402C@bag.python.org> The Buildbot has detected a new failure of x86 XP-3 trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20XP-3%20trunk/builds/665 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: heller-windows Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: andrew.kuchling,georg.brandl,thomas.heller BUILD FAILED: failed test Excerpt from the test logfile: 2 tests failed: test_winreg test_zipfile ====================================================================== FAIL: testLocalMachineRegistryWorks (test.test_winreg.WinregTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\trunk.heller-windows\build\lib\test\test_winreg.py", line 151, in testLocalMachineRegistryWorks self.TestAll(HKEY_CURRENT_USER) File "C:\buildbot\work\trunk.heller-windows\build\lib\test\test_winreg.py", line 146, in TestAll self.WriteTestData(root_key) File "C:\buildbot\work\trunk.heller-windows\build\lib\test\test_winreg.py", line 48, in WriteTestData self.assertEquals(nkeys, 1, "Not the correct number of sub keys") AssertionError: Not the correct number of sub keys ====================================================================== ERROR: testExtract (test.test_zipfile.TestsWithSourceFile) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\trunk.heller-windows\build\lib\test\test_zipfile.py", line 357, in tearDown os.remove(TESTFN2) WindowsError: [Error 32] The process cannot access the file because it is being used by another process: '@test2' ====================================================================== FAIL: testExtract (test.test_zipfile.TestsWithSourceFile) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\trunk.heller-windows\build\lib\test\test_zipfile.py", line 320, in testExtract self.assertEqual(writtenfile, correctfile) AssertionError: 'C:\\buildbot\\work\\trunk.heller-windows\\build\\PCbuild\\ziptest2dir\\_ziptest2' != 'C:\\buildbot\\work\\trunk.heller-windows\\build\\PCbuild\\ziptest2dir/_ziptest2' sincerely, -The Buildbot From python-checkins at python.org Wed Jan 16 21:27:27 2008 From: python-checkins at python.org (georg.brandl) Date: Wed, 16 Jan 2008 21:27:27 +0100 (CET) Subject: [Python-checkins] r60005 - in doctools/trunk/sphinx: __init__.py _jinja.py addnodes.py builder.py directives.py environment.py highlighting.py htmlhelp.py htmlwriter.py latexwriter.py patchlevel.py refcounting.py roles.py search.py style/default.css style/rightsidebar.css style/searchtools.js style/stickysidebar.css style/traditional.css templates/_commentform.html templates/admin templates/changes templates/changes/frameset.html templates/changes/rstsource.html templates/changes/versionchanges.html templates/commentform.html templates/comments.html templates/download.html templates/edit.html templates/index.html templates/inlinecomments.html templates/keyword_not_found.html templates/layout.html templates/not_found.html templates/rstsource.html templates/search.html templates/settings.html templates/show_source.html templates/sidebar.html templates/submitted.html templates/versionchanges.html templates/versionchanges_frameset.html templates/web templates/web/_commentform.html templates/web/admin templates/web/admin/moderate_comments.html templates/web/commentform.html templates/web/comments.html templates/web/edit.html templates/web/inlinecomments.html templates/web/keyword_not_found.html templates/web/not_found.html templates/web/settings.html templates/web/submitted.html util/__init__.py util/stemmer.py web/admin.py web/antispam.py web/application.py web/database.py web/markup.py web/oldurls.py web/serve.py web/userdb.py web/util.py web/webconf.py web/wsgiutil.py Message-ID: <20080116202727.F137C1E4003@bag.python.org> Author: georg.brandl Date: Wed Jan 16 21:27:25 2008 New Revision: 60005 Added: doctools/trunk/sphinx/templates/changes/ doctools/trunk/sphinx/templates/changes/frameset.html - copied, changed from r59608, doctools/trunk/sphinx/templates/versionchanges_frameset.html doctools/trunk/sphinx/templates/changes/rstsource.html - copied, changed from r59608, doctools/trunk/sphinx/templates/rstsource.html doctools/trunk/sphinx/templates/changes/versionchanges.html - copied, changed from r59608, doctools/trunk/sphinx/templates/versionchanges.html doctools/trunk/sphinx/templates/web/ doctools/trunk/sphinx/templates/web/_commentform.html - copied unchanged from r57711, doctools/trunk/sphinx/templates/_commentform.html doctools/trunk/sphinx/templates/web/admin/ - copied from r57711, doctools/trunk/sphinx/templates/admin/ doctools/trunk/sphinx/templates/web/commentform.html - copied, changed from r57711, doctools/trunk/sphinx/templates/commentform.html doctools/trunk/sphinx/templates/web/comments.html - copied unchanged from r57711, doctools/trunk/sphinx/templates/comments.html doctools/trunk/sphinx/templates/web/edit.html - copied, changed from r57711, doctools/trunk/sphinx/templates/edit.html doctools/trunk/sphinx/templates/web/inlinecomments.html - copied unchanged from r57711, doctools/trunk/sphinx/templates/inlinecomments.html doctools/trunk/sphinx/templates/web/keyword_not_found.html - copied, changed from r57711, doctools/trunk/sphinx/templates/keyword_not_found.html doctools/trunk/sphinx/templates/web/not_found.html - copied, changed from r57711, doctools/trunk/sphinx/templates/not_found.html doctools/trunk/sphinx/templates/web/settings.html - copied, changed from r57711, doctools/trunk/sphinx/templates/settings.html doctools/trunk/sphinx/templates/web/submitted.html - copied, changed from r57711, doctools/trunk/sphinx/templates/submitted.html Removed: doctools/trunk/sphinx/templates/_commentform.html doctools/trunk/sphinx/templates/admin/ doctools/trunk/sphinx/templates/commentform.html doctools/trunk/sphinx/templates/comments.html doctools/trunk/sphinx/templates/download.html doctools/trunk/sphinx/templates/edit.html doctools/trunk/sphinx/templates/inlinecomments.html doctools/trunk/sphinx/templates/keyword_not_found.html doctools/trunk/sphinx/templates/not_found.html doctools/trunk/sphinx/templates/rstsource.html doctools/trunk/sphinx/templates/settings.html doctools/trunk/sphinx/templates/show_source.html doctools/trunk/sphinx/templates/sidebar.html doctools/trunk/sphinx/templates/submitted.html doctools/trunk/sphinx/templates/versionchanges.html doctools/trunk/sphinx/templates/versionchanges_frameset.html Modified: doctools/trunk/sphinx/__init__.py doctools/trunk/sphinx/_jinja.py doctools/trunk/sphinx/addnodes.py doctools/trunk/sphinx/builder.py doctools/trunk/sphinx/directives.py doctools/trunk/sphinx/environment.py doctools/trunk/sphinx/highlighting.py doctools/trunk/sphinx/htmlhelp.py doctools/trunk/sphinx/htmlwriter.py doctools/trunk/sphinx/latexwriter.py doctools/trunk/sphinx/patchlevel.py doctools/trunk/sphinx/refcounting.py doctools/trunk/sphinx/roles.py doctools/trunk/sphinx/search.py doctools/trunk/sphinx/style/default.css doctools/trunk/sphinx/style/rightsidebar.css doctools/trunk/sphinx/style/searchtools.js doctools/trunk/sphinx/style/stickysidebar.css doctools/trunk/sphinx/style/traditional.css doctools/trunk/sphinx/templates/index.html doctools/trunk/sphinx/templates/layout.html doctools/trunk/sphinx/templates/search.html doctools/trunk/sphinx/templates/web/admin/moderate_comments.html doctools/trunk/sphinx/util/__init__.py doctools/trunk/sphinx/util/stemmer.py doctools/trunk/sphinx/web/admin.py doctools/trunk/sphinx/web/antispam.py doctools/trunk/sphinx/web/application.py doctools/trunk/sphinx/web/database.py doctools/trunk/sphinx/web/markup.py doctools/trunk/sphinx/web/oldurls.py doctools/trunk/sphinx/web/serve.py doctools/trunk/sphinx/web/userdb.py doctools/trunk/sphinx/web/util.py doctools/trunk/sphinx/web/webconf.py doctools/trunk/sphinx/web/wsgiutil.py Log: A few refactorings in Sphinx. Modified: doctools/trunk/sphinx/__init__.py ============================================================================== --- doctools/trunk/sphinx/__init__.py (original) +++ doctools/trunk/sphinx/__init__.py Wed Jan 16 21:27:25 2008 @@ -3,7 +3,7 @@ Sphinx ~~~~~~ - The Python documentation toolchain. + The Sphinx documentation toolchain. :copyright: 2007-2008 by Georg Brandl. :license: BSD. @@ -14,8 +14,8 @@ from os import path from cStringIO import StringIO -from .builder import builders -from .util.console import nocolor +from sphinx.builder import builders +from sphinx.util.console import nocolor __version__ = '$Revision: 5369 $' @@ -31,7 +31,6 @@ -E -- don't use a saved environment, always read all files -d -- path for the cached environment and doctree files (default outdir/.doctrees) - -O -- give option to to the builder (-O help for list) -D -- override a setting in sourcedir/conf.py -N -- do not do colored output -q -- no output on stdout, just warnings on stderr @@ -44,7 +43,7 @@ def main(argv): try: - opts, args = getopt.getopt(argv[1:], 'ab:d:O:D:NEqP') + opts, args = getopt.getopt(argv[1:], 'ab:d:D:NEqP') srcdirname = path.abspath(args[0]) if not path.isdir(srcdirname): print >>sys.stderr, 'Error: Cannot find source directory.' @@ -70,9 +69,8 @@ return 1 builder = all_files = None - opt_help = freshenv = use_pdb = False + freshenv = use_pdb = False status = sys.stdout - options = {} confoverrides = {} doctreedir = path.join(outdirname, '.doctrees') for opt, val in opts: @@ -88,18 +86,6 @@ all_files = True elif opt == '-d': doctreedir = val - elif opt == '-O': - if val == 'help': - opt_help = True - continue - if '=' in val: - key, val = val.split('=') - try: - val = int(val) - except: pass - else: - key, val = val, True - options[key] = val elif opt == '-D': key, val = val.split('=') try: @@ -125,14 +111,8 @@ builderobj = builders[builder] - if opt_help: - print 'Options recognized by the %s builder:' % builder - for optname, description in builderobj.option_spec.iteritems(): - print ' * %s: %s' % (optname, description) - return 0 - try: - builderobj = builderobj(srcdirname, outdirname, doctreedir, options, + builderobj = builderobj(srcdirname, outdirname, doctreedir, status_stream=status, warning_stream=sys.stderr, confoverrides=confoverrides, @@ -146,7 +126,8 @@ except: if not use_pdb: raise - import pdb + import pdb, traceback + traceback.print_exc() pdb.post_mortem(sys.exc_info()[2]) Modified: doctools/trunk/sphinx/_jinja.py ============================================================================== --- doctools/trunk/sphinx/_jinja.py (original) +++ doctools/trunk/sphinx/_jinja.py Wed Jan 16 21:27:25 2008 @@ -8,11 +8,41 @@ :copyright: 2007-2008 by Georg Brandl. :license: BSD. """ -from __future__ import absolute_import import sys +import codecs from os import path sys.path.insert(0, path.dirname(__file__)) -from jinja import Environment, FileSystemLoader +from jinja import Environment +from jinja.loaders import BaseLoader +from jinja.exceptions import TemplateNotFound + +class SphinxFileSystemLoader(BaseLoader): + """ + A loader that loads templates either relative to one of a list of given + paths, or from an absolute path. + """ + + def __init__(self, paths): + self.searchpaths = map(path.abspath, paths) + + def get_source(self, environment, name, parent): + name = name.replace('/', path.sep) + if path.isabs(name): + if not path.exists(name): + raise TemplateNotFound(name) + filename = name + else: + for searchpath in self.searchpaths: + if path.exists(path.join(searchpath, name)): + filename = path.join(searchpath, name) + break + else: + raise TemplateNotFound(name) + f = codecs.open(filename, 'r', environment.template_charset) + try: + return f.read() + finally: + f.close() Modified: doctools/trunk/sphinx/addnodes.py ============================================================================== --- doctools/trunk/sphinx/addnodes.py (original) +++ doctools/trunk/sphinx/addnodes.py Wed Jan 16 21:27:25 2008 @@ -3,6 +3,8 @@ sphinx.addnodes ~~~~~~~~~~~~~~~ + Additional docutils nodes. + :copyright: 2007-2008 by Georg Brandl. :license: BSD. """ Modified: doctools/trunk/sphinx/builder.py ============================================================================== --- doctools/trunk/sphinx/builder.py (original) +++ doctools/trunk/sphinx/builder.py Wed Jan 16 21:27:25 2008 @@ -8,7 +8,6 @@ :copyright: 2007-2008 by Georg Brandl. :license: BSD. """ -from __future__ import with_statement import os import sys @@ -21,26 +20,27 @@ from os import path from cgi import escape +from docutils import nodes from docutils.io import StringOutput, FileOutput, DocTreeInput from docutils.core import publish_parts from docutils.utils import new_document from docutils.readers import doctree from docutils.frontend import OptionParser -from .util import (get_matching_files, attrdict, status_iterator, ensuredir, - get_category, relative_uri, os_path, SEP) -from .htmlhelp import build_hhx -from .patchlevel import get_version_info, get_sys_version_info -from .htmlwriter import HTMLWriter -from .latexwriter import LaTeXWriter -from .environment import BuildEnvironment, NoUri -from .highlighting import pygments, highlight_block, get_stylesheet -from .util.console import bold, purple, green +from sphinx import addnodes +from sphinx.util import (get_matching_files, attrdict, status_iterator, + ensuredir, relative_uri, os_path, SEP) +from sphinx.htmlhelp import build_hhx +from sphinx.patchlevel import get_version_info, get_sys_version_info +from sphinx.htmlwriter import HTMLWriter +from sphinx.latexwriter import LaTeXWriter +from sphinx.environment import BuildEnvironment, NoUri +from sphinx.highlighting import pygments, highlight_block, get_stylesheet +from sphinx.util.console import bold, purple, green -from . import addnodes # side effect: registers roles and directives -from . import roles -from . import directives +from sphinx import roles +from sphinx import directives ENV_PICKLE_FILENAME = 'environment.pickle' LAST_BUILD_FILENAME = 'last_build' @@ -53,33 +53,18 @@ self.builder = builder def __call__(self, otheruri, resource=False): if not resource: - otheruri = self.builder.get_target_uri(otheruri) + otheruri = self.builder.get_target_uri(otheruri + '.rst') return relative_uri(self.baseuri, otheruri) -class collect_env_warnings(object): - def __init__(self, builder): - self.builder = builder - self.warnings = [] - def __enter__(self): - self.builder.env.set_warnfunc(self.warnings.append) - def __exit__(self, *args): - self.builder.env.set_warnfunc(self.builder.warn) - for warning in self.warnings: - self.builder.warn(warning) - - class Builder(object): """ Builds target formats from the reST sources. """ - option_spec = {} - def __init__(self, srcdirname, outdirname, doctreedirname, - options, confoverrides=None, env=None, - status_stream=None, warning_stream=None, - freshenv=False): + confoverrides=None, env=None, freshenv=False, + status_stream=None, warning_stream=None): self.srcdir = srcdirname self.outdir = outdirname self.doctreedir = doctreedirname @@ -87,9 +72,6 @@ os.mkdir(doctreedirname) self.freshenv = freshenv - self.options = attrdict(options) - self.validate_options() - self.status_stream = status_stream or sys.stdout self.warning_stream = warning_stream or sys.stderr @@ -97,7 +79,12 @@ self.env = env self.config = {} - execfile(path.join(srcdirname, 'conf.py'), self.config) + olddir = os.getcwd() + try: + os.chdir(srcdirname) + execfile(path.join(srcdirname, 'conf.py'), self.config) + finally: + os.chdir(olddir) # remove potentially pickling-problematic values del self.config['__builtins__'] for key, val in self.config.items(): @@ -105,31 +92,23 @@ del self.config[key] if confoverrides: self.config.update(confoverrides) - # replace version info if 'auto' - if self.config['version'] == 'auto' or self.config['release'] == 'auto': + # replace version info if '' + if self.config['version'] == '' or self.config['release'] == '': try: version, release = get_version_info(srcdirname) except (IOError, OSError): version, release = get_sys_version_info() self.warn('Can\'t get version info from Include/patchlevel.h, ' 'using version of this interpreter (%s).' % release) - if self.config['version'] == 'auto': + if self.config['version'] == '': self.config['version'] = version - if self.config['release'] == 'auto': + if self.config['release'] == '': self.config['release'] = release self.init() # helper methods - def validate_options(self): - for option in self.options: - if option not in self.option_spec: - raise ValueError('Got unexpected option %s' % option) - for option in self.option_spec: - if option not in self.options: - self.options[option] = False - def msg(self, message='', nonl=False, nobold=False): if not nobold: message = bold(message) if nonl: @@ -214,16 +193,20 @@ updated_filenames = [] # while reading, collect all warnings from docutils - with collect_env_warnings(self): - self.msg('reading, updating environment:', nonl=1) - iterator = self.env.update(self.config) - self.msg(iterator.next(), nonl=1, nobold=1) - for filename in iterator: - if not updated_filenames: - self.msg('') - updated_filenames.append(filename) - self.msg(purple(filename), nonl=1, nobold=1) - self.msg() + warnings = [] + self.env.set_warnfunc(warnings.append) + self.msg('reading, updating environment:', nonl=1) + iterator = self.env.update(self.config) + self.msg(iterator.next(), nonl=1, nobold=1) + for filename in iterator: + if not updated_filenames: + self.msg('') + updated_filenames.append(filename) + self.msg(purple(filename), nonl=1, nobold=1) + self.msg() + for warning in warnings: + self.warn(warning) + self.env.set_warnfunc(self.warn) if updated_filenames: # save the environment @@ -260,12 +243,16 @@ self.prepare_writing(filenames) # write target files - with collect_env_warnings(self): - self.msg('writing output...') - for filename in status_iterator(sorted(filenames), green, - stream=self.status_stream): - doctree = self.env.get_and_resolve_doctree(filename, self) - self.write_file(filename, doctree) + warnings = [] + self.env.set_warnfunc(warnings.append) + self.msg('writing output...') + for filename in status_iterator(sorted(filenames), green, + stream=self.status_stream): + doctree = self.env.get_and_resolve_doctree(filename, self) + self.write_file(filename, doctree) + for warning in warnings: + self.warn(warning) + self.env.set_warnfunc(self.warn) def prepare_writing(self, filenames): raise NotImplementedError @@ -288,22 +275,28 @@ def init(self): """Load templates.""" # lazily import this, maybe other builders won't need it - from ._jinja import Environment, FileSystemLoader + from sphinx._jinja import Environment, SphinxFileSystemLoader # load templates self.templates = {} templates_path = path.join(path.dirname(__file__), 'templates') - jinja_env = Environment(loader=FileSystemLoader(templates_path), - # disable traceback, more likely that something in the - # application is broken than in the templates - friendly_traceback=False) + self.jinja_env = Environment(loader=SphinxFileSystemLoader([templates_path]), + # disable traceback, more likely that something + # in the application is broken than in the templates + friendly_traceback=False) + # pre-load built-in templates for fname in os.listdir(templates_path): if fname.endswith('.html'): - self.templates[fname[:-5]] = jinja_env.get_template(fname) + self.templates[fname] = self.jinja_env.get_template(fname) + + def get_template(self, name): + if name in self.templates: + return self.templates[name] + return self.jinja_env.get_template(name) def render_partial(self, node): """Utility: Render a lone doctree node.""" - doc = new_document('foo') + doc = new_document('') doc.append(node) return publish_parts( doc, @@ -314,7 +307,7 @@ ) def prepare_writing(self, filenames): - from .search import IndexBuilder + from sphinx.search import IndexBuilder self.indexer = IndexBuilder() self.load_indexer(filenames) self.docwriter = HTMLWriter(self) @@ -331,13 +324,15 @@ self.last_updated = None self.globalcontext = dict( - last_updated = self.last_updated, - builder = self.name, + project = self.config.get('project', 'Python'), + copyright = self.config.get('copyright', ''), release = self.config['release'], version = self.config['version'], + last_updated = self.last_updated, + builder = self.name, parents = [], - len = len, titles = {}, + len = len, # the built-in ) def write_file(self, filename, doctree): @@ -375,7 +370,6 @@ context = dict( title = title, sourcename = sourcename, - pathto = relpath_to(self, self.get_target_uri(filename)), body = self.docwriter.parts['fragment'], toc = self.render_partial(self.env.get_toc_for(filename))['fragment'], # only display a TOC if there's more than one item to show @@ -386,7 +380,7 @@ ) self.index_file(filename, doctree, title) - self.handle_file(filename, context) + self.handle_page(filename[:-4], context) def finish(self): self.msg('writing additional files...') @@ -402,10 +396,8 @@ genindexcontext = dict( genindexentries = self.env.index, genindexcounts = indexcounts, - current_page_name = 'genindex', - pathto = relpath_to(self, self.get_target_uri('genindex.rst')), ) - self.handle_file('genindex.rst', genindexcontext, 'genindex') + self.handle_page('genindex', genindexcontext, 'genindex.html') # the global module index @@ -422,12 +414,12 @@ cg = 0 # collapse group fl = '' # first letter for mn, (fn, sy, pl, dep) in modules: - pl = pl.split(', ') if pl else [] + pl = pl and pl.split(', ') or [] platforms.update(pl) if fl != mn[0].lower() and mn[0] != '_': modindexentries.append(['', False, 0, False, mn[0].upper(), '', [], False]) - tn = mn.partition('.')[0] + tn = mn.split('.')[0] if tn != mn: # submodule if pmn == tn: @@ -447,32 +439,22 @@ modindexcontext = dict( modindexentries = modindexentries, platforms = platforms, - current_page_name = 'modindex', - pathto = relpath_to(self, self.get_target_uri('modindex.rst')), ) - self.handle_file('modindex.rst', modindexcontext, 'modindex') + self.handle_page('modindex', modindexcontext, 'modindex.html') - # the download page - downloadcontext = dict( - pathto = relpath_to(self, self.get_target_uri('download.rst')), - current_page_name = 'download', - download_base_url = self.config['html_download_base_url'], - ) - self.handle_file('download.rst', downloadcontext, 'download') + # the search page + self.handle_page('search', {}, 'search.html') - # the index page - indexcontext = dict( - pathto = relpath_to(self, self.get_target_uri('index.rst')), - current_page_name = 'index', - ) - self.handle_file('index.rst', indexcontext, 'index') + # additional pages from conf.py + for pagename, template in self.config.get('html_additional_pages', {}).items(): + template = path.join(self.srcdir, template) + self.handle_page(pagename, {}, template) - # the search page - searchcontext = dict( - pathto = relpath_to(self, self.get_target_uri('search.rst')), - current_page_name = 'search', - ) - self.handle_file('search.rst', searchcontext, 'search') + # the index page + indextemplate = self.config.get('html_index') + if indextemplate: + indextemplate = path.join(self.srcdir, indextemplate) + self.handle_page('index', {'indextemplate': indextemplate}, 'index.html') # copy style files self.msg('copying style files...') @@ -512,8 +494,11 @@ def load_indexer(self, filenames): try: - with open(path.join(self.outdir, 'searchindex.json'), 'r') as f: + f = open(path.join(self.outdir, 'searchindex.json'), 'r') + try: self.indexer.load(f, 'json') + finally: + f.close() except (IOError, OSError): pass # delete all entries for files that will be rebuilt @@ -522,32 +507,43 @@ def index_file(self, filename, doctree, title): # only index pages with title if self.indexer is not None and title: - category = get_category(filename) - if category is not None: - self.indexer.feed(self.get_target_uri(filename)[:-5], # strip '.html' - category, title, doctree) + self.indexer.feed(self.get_target_uri(filename)[:-5], # strip '.html' + title, doctree) - def handle_file(self, filename, context, templatename='page'): + def handle_page(self, pagename, context, templatename='page.html'): ctx = self.globalcontext.copy() + ctx['current_page_name'] = pagename + ctx['pathto'] = relpath_to(self, self.get_target_uri(pagename+'.rst')) + ctx['hasdoc'] = lambda name: name+'.rst' in self.env.all_files + sidebarfile = self.config.get('html_sidebars', {}).get(pagename) + if sidebarfile: + ctx['customsidebar'] = path.join(self.srcdir, sidebarfile) ctx.update(context) - output = self.templates[templatename].render(ctx) - outfilename = path.join(self.outdir, os_path(filename)[:-4] + '.html') + + output = self.get_template(templatename).render(ctx) + outfilename = path.join(self.outdir, os_path(pagename) + '.html') ensuredir(path.dirname(outfilename)) # normally different from self.outdir try: - with codecs.open(outfilename, 'w', 'utf-8') as fp: - fp.write(output) + f = codecs.open(outfilename, 'w', 'utf-8') + try: + f.write(output) + finally: + f.close() except (IOError, OSError), err: self.warn("Error writing file %s: %s" % (outfilename, err)) if self.copysource and context.get('sourcename'): # copy the source file for the "show source" link - shutil.copyfile(path.join(self.srcdir, os_path(filename)), + shutil.copyfile(path.join(self.srcdir, os_path(pagename+'.rst')), path.join(self.outdir, os_path(context['sourcename']))) def handle_finish(self): self.msg('dumping search index...') self.indexer.prune([self.get_target_uri(fn)[:-5] for fn in self.env.all_files]) - with open(path.join(self.outdir, 'searchindex.json'), 'w') as f: + f = open(path.join(self.outdir, 'searchindex.json'), 'w') + try: self.indexer.dump(f, 'json') + finally: + f.close() class WebHTMLBuilder(StandaloneHTMLBuilder): @@ -581,44 +577,57 @@ def load_indexer(self, filenames): try: - with open(path.join(self.outdir, 'searchindex.pickle'), 'r') as f: + f = open(path.join(self.outdir, 'searchindex.pickle'), 'r') + try: self.indexer.load(f, 'pickle') + finally: + f.close() except (IOError, OSError): pass # delete all entries for files that will be rebuilt self.indexer.prune(set(self.env.all_files) - set(filenames)) def index_file(self, filename, doctree, title): - # only index pages with title and category + # only index pages with title if self.indexer is not None and title: - category = get_category(filename) - if category is not None: - self.indexer.feed(filename, category, title, doctree) + self.indexer.feed(filename, title, doctree) - def handle_file(self, filename, context, templatename='page'): - outfilename = path.join(self.outdir, os_path(filename)[:-4] + '.fpickle') + def handle_page(self, pagename, context, templatename='page.html'): + context['current_page_name'] = pagename + sidebarfile = self.config.get('html_sidebars', {}).get(pagename, '') + if sidebarfile: + context['customsidebar'] = path.join(self.srcdir, sidebarfile) + outfilename = path.join(self.outdir, os_path(pagename) + '.fpickle') ensuredir(path.dirname(outfilename)) - context.pop('pathto', None) # can't be pickled - with file(outfilename, 'wb') as fp: - pickle.dump(context, fp, 2) + f = open(outfilename, 'wb') + try: + pickle.dump(context, f, 2) + finally: + f.close() # if there is a source file, copy the source file for the "show source" link if context.get('sourcename'): source_name = path.join(self.outdir, 'sources', os_path(context['sourcename'])) ensuredir(path.dirname(source_name)) - shutil.copyfile(path.join(self.srcdir, os_path(filename)), source_name) + shutil.copyfile(path.join(self.srcdir, os_path(pagename)+'.rst'), source_name) def handle_finish(self): # dump the global context outfilename = path.join(self.outdir, 'globalcontext.pickle') - with file(outfilename, 'wb') as fp: - pickle.dump(self.globalcontext, fp, 2) + f = open(outfilename, 'wb') + try: + pickle.dump(self.globalcontext, f, 2) + finally: + f.close() self.msg('dumping search index...') self.indexer.prune(self.env.all_files) - with open(path.join(self.outdir, 'searchindex.pickle'), 'wb') as f: + f = open(path.join(self.outdir, 'searchindex.pickle'), 'wb') + try: self.indexer.dump(f, 'pickle') + finally: + f.close() # copy the environment file from the doctree dir to the output dir # as needed by the web app @@ -641,15 +650,11 @@ """ name = 'htmlhelp' - option_spec = { - 'outname': 'Output file base name (default "pydoc")' - } - # don't copy the reST source copysource = False def handle_finish(self): - build_hhx(self, self.outdir, self.options.get('outname') or 'pydoc') + build_hhx(self, self.outdir, self.config.get('htmlhelp_basename', 'pydoc')) class LaTeXBuilder(Builder): @@ -660,6 +665,17 @@ def init(self): self.filenames = [] + self.document_data = map(list, self.config.get('latex_documents', ())) + + # assign subdirs to titles + self.titles = [] + for entry in self.document_data: + # replace version with real version + entry[0] = entry[0].replace('', self.config['version']) + sourcename = entry[0] + if sourcename.endswith('/index.rst'): + sourcename = sourcename[:-9] + self.titles.append((sourcename, entry[2])) def get_outdated_files(self): return 'all documents' # for now @@ -674,49 +690,42 @@ else: return '' - def get_document_data(self): - # Python specific... - for toplevel in ["c-api", "distutils", "documenting", "extending", - "install", "reference", "tutorial", "using", "library"]: - yield (toplevel + SEP + 'index.rst', toplevel+'.tex', 'manual') - yield ('whatsnew' + SEP + self.config['version'] + '.rst', - 'whatsnew.tex', 'howto') - for howto in [fn for fn in self.env.all_files - if fn.startswith('howto'+SEP) - and not fn.endswith('index.rst')]: - yield (howto, 'howto-'+howto[6:-4]+'.tex', 'howto') - def write(self, *ignored): - # first, assemble the "special" docs that are in every PDF - specials = [] - for fname in ["glossary", "about", "license", "copyright"]: - specials.append(self.env.get_doctree(fname+".rst")) + # first, assemble the "appendix" docs that are in every PDF + appendices = [] + for fname in self.config.get('latex_appendices', []): + appendices.append(self.env.get_doctree(fname)) docwriter = LaTeXWriter(self) docsettings = OptionParser( defaults=self.env.settings, components=(docwriter,)).get_default_values() - for sourcename, targetname, docclass in self.get_document_data(): + if not self.document_data: + self.warn('No "latex_documents" config setting found; no documents ' + 'will be written.') + + for sourcename, targetname, title, author, docclass in self.document_data: destination = FileOutput( destination_path=path.join(self.outdir, targetname), encoding='utf-8') print "processing", targetname + "...", doctree = self.assemble_doctree( - sourcename, specials=(docclass == 'manual') and specials or []) + sourcename, appendices=(docclass == 'manual') and appendices or []) print "writing...", doctree.settings = docsettings + doctree.settings.author = author doctree.settings.filename = sourcename doctree.settings.docclass = docclass output = docwriter.write(doctree, destination) print "done" - def assemble_doctree(self, indexfile, specials): + def assemble_doctree(self, indexfile, appendices): self.filenames = set([indexfile, 'glossary.rst', 'about.rst', 'license.rst', 'copyright.rst']) print green(indexfile), def process_tree(filename, tree): - #tree = tree.deepcopy() XXX + tree = tree.deepcopy() for toctreenode in tree.traverse(addnodes.toctree): newnodes = [] includefiles = map(str, toctreenode['includefiles']) @@ -734,11 +743,25 @@ toctreenode.parent.replace(toctreenode, newnodes) return tree largetree = process_tree(indexfile, self.env.get_doctree(indexfile)) - largetree.extend(specials) + largetree.extend(appendices) print print "resolving references..." - # XXX problem here: :ref:s to distant tex files self.env.resolve_references(largetree, indexfile, self) + # resolve :ref:s to distant tex files -- we can't add a cross-reference, + # but append the document name + for pendingnode in largetree.traverse(addnodes.pending_xref): + filename = pendingnode['reffilename'] + sectname = pendingnode['refsectname'] + newnodes = [nodes.emphasis(sectname, sectname)] + for subdir, title in self.titles: + if filename.startswith(subdir): + newnodes.append(nodes.Text(' (in ', ' (in ')) + newnodes.append(nodes.emphasis(title, title)) + newnodes.append(nodes.Text(')', ')')) + break + else: + pass + pendingnode.replace_self(newnodes) return largetree def finish(self): @@ -757,15 +780,15 @@ name = 'changes' def init(self): - from ._jinja import Environment, FileSystemLoader + from sphinx._jinja import Environment, FileSystemLoader templates_path = path.join(path.dirname(__file__), 'templates') - jinja_env = Environment(loader=FileSystemLoader(templates_path), + jinja_env = Environment(loader=SphinxFileSystemLoader([templates_path]), # disable traceback, more likely that something in the # application is broken than in the templates friendly_traceback=False) - self.ftemplate = jinja_env.get_template('versionchanges_frameset.html') - self.vtemplate = jinja_env.get_template('versionchanges.html') - self.stemplate = jinja_env.get_template('rstsource.html') + self.ftemplate = jinja_env.get_template('changes/frameset.html') + self.vtemplate = jinja_env.get_template('changes/versionchanges.html') + self.stemplate = jinja_env.get_template('changes/rstsource.html') def get_outdated_files(self): return self.outdir @@ -813,15 +836,22 @@ (entry, filename, lineno)) ctx = { + 'project': self.config.get('project', 'Python'), 'version': ver, 'libchanges': sorted(libchanges.iteritems()), 'apichanges': sorted(apichanges), 'otherchanges': sorted(otherchanges.iteritems()), } - with open(path.join(self.outdir, 'index.html'), 'w') as f: + f = open(path.join(self.outdir, 'index.html'), 'w') + try: f.write(self.ftemplate.render(ctx)) - with open(path.join(self.outdir, 'changes.html'), 'w') as f: + finally: + f.close() + f = open(path.join(self.outdir, 'changes.html'), 'w') + try: f.write(self.vtemplate.render(ctx)) + finally: + f.close() hltext = ['.. versionadded:: %s' % ver, '.. versionchanged:: %s' % ver, @@ -837,14 +867,17 @@ self.msg('copying source files...') for filename in self.env.all_files: - with open(path.join(self.srcdir, os_path(filename))) as f: - lines = f.readlines() + f = open(path.join(self.srcdir, os_path(filename))) + lines = f.readlines() targetfn = path.join(self.outdir, 'rst', os_path(filename)) + '.html' ensuredir(path.dirname(targetfn)) - with codecs.open(targetfn, 'w', 'utf8') as f: + f = codecs.open(targetfn, 'w', 'utf8') + try: text = ''.join(hl(i+1, line) for (i, line) in enumerate(lines)) ctx = {'filename': filename, 'text': text} f.write(self.stemplate.render(ctx)) + finally: + f.close() shutil.copyfile(path.join(path.dirname(__file__), 'style', 'default.css'), path.join(self.outdir, 'default.css')) Modified: doctools/trunk/sphinx/directives.py ============================================================================== --- doctools/trunk/sphinx/directives.py (original) +++ doctools/trunk/sphinx/directives.py Wed Jan 16 21:27:25 2008 @@ -8,7 +8,6 @@ :copyright: 2007-2008 by Georg Brandl. :license: BSD. """ -from __future__ import with_statement import re import string @@ -19,7 +18,7 @@ from docutils.parsers.rst import directives, roles from docutils.parsers.rst.directives import admonitions -from . import addnodes +from sphinx import addnodes # ------ index markup -------------------------------------------------------------- @@ -142,7 +141,7 @@ else: fullname = env.currclass + '.' + name else: - fullname = classname + name if classname else name + fullname = classname and classname + name or name if classname: signode += addnodes.desc_classname(classname, classname) @@ -285,7 +284,7 @@ if entry.result_refs is None: rc += "Always NULL." else: - rc += ("New" if entry.result_refs else "Borrowed") + " reference." + rc += (entry.result_refs and "New" or "Borrowed") + " reference." node += addnodes.refcount(rc, rc) @@ -347,7 +346,7 @@ # only add target and index entry if this is the first description of the # function name in this desc block if not noindex and name not in names: - fullname = (env.currmodule + '.' if env.currmodule else '') + name + fullname = (env.currmodule and env.currmodule + '.' or '') + name # note target if fullname not in state.document.ids: signode['names'].append(fullname) @@ -612,8 +611,9 @@ fn = path.normpath(path.join(source_dir, fn)) try: - with open(fn) as f: - text = f.read() + f = open(fn) + text = f.read() + f.close() except (IOError, OSError): retnode = state.document.reporter.warning( 'Include file %r not found or reading it failed' % arguments[0], line=lineno) Modified: doctools/trunk/sphinx/environment.py ============================================================================== --- doctools/trunk/sphinx/environment.py (original) +++ doctools/trunk/sphinx/environment.py Wed Jan 16 21:27:25 2008 @@ -8,18 +8,22 @@ :copyright: 2007-2008 by Georg Brandl. :license: BSD. """ -from __future__ import with_statement import re import os import time import heapq -import hashlib import difflib import itertools import cPickle as pickle from os import path from string import uppercase +try: + import hashlib + md5 = hashlib.md5 +except: + import md5 + md5 = md5.new from docutils import nodes from docutils.io import FileInput @@ -37,9 +41,9 @@ Body.enum.converters['lowerroman'] = \ Body.enum.converters['upperroman'] = lambda x: None -from . import addnodes -from .util import get_matching_files, os_path, SEP -from .refcounting import Refcounts +from sphinx import addnodes +from sphinx.util import get_matching_files, os_path, SEP +from sphinx.refcounting import Refcounts default_settings = { 'embed_stylesheet': False, @@ -156,8 +160,11 @@ @staticmethod def frompickle(filename): - with open(filename, 'rb') as picklefile: + picklefile = open(filename, 'rb') + try: env = pickle.load(picklefile) + finally: + picklefile.close() if env.version != ENV_VERSION: raise IOError('env version not current') return env @@ -166,8 +173,11 @@ # remove unpicklable attributes warnfunc = self._warnfunc self.set_warnfunc(None) - with open(filename, 'wb') as picklefile: + picklefile = open(filename, 'wb') + try: pickle.dump(self, picklefile, pickle.HIGHEST_PROTOCOL) + finally: + picklefile.close() # reset stream self.set_warnfunc(warnfunc) @@ -178,9 +188,8 @@ self.srcdir = srcdir self.config = {} - # read the refcounts file - self.refcounts = Refcounts.fromfile( - path.join(self.srcdir, 'data', 'refcounts.dat')) + # refcount data if present + self.refcounts = {} # the docutils settings for building self.settings = default_settings.copy() @@ -194,7 +203,7 @@ # Build times -- to determine changed files # Also use this as an inventory of all existing and built filenames. - self.all_files = {} # filename -> (mtime, md5) at the time of build + self.all_files = {} # filename -> (mtime, md5sum) at the time of build # File metadata self.metadata = {} # filename -> dict of metadata items @@ -291,21 +300,22 @@ os_path(filename)[:-3] + 'doctree')): changed.append(filename) continue - mtime, md5 = self.all_files[filename] + mtime, md5sum = self.all_files[filename] newmtime = path.getmtime(path.join(self.srcdir, os_path(filename))) if newmtime == mtime: continue # check the MD5 #with file(path.join(self.srcdir, filename), 'rb') as f: - # newmd5 = hashlib.md5(f.read()).digest() - #if newmd5 != md5: + # newmd5sum = md5(f.read()).digest() + #if newmd5sum != md5sum: changed.append(filename) return added, changed, removed # If one of these config values changes, all files need to be re-read. influential_config_values = [ - 'version', 'release', 'today', 'today_fmt', 'unused_files' + 'version', 'release', 'today', 'today_fmt', 'unused_files', + 'project', 'refcount_file', 'add_function_parentheses', 'add_module_names' ] def update(self, config): @@ -330,14 +340,15 @@ self.config = config + # read the refcounts file + if self.config.get('refcount_file'): + self.refcounts = Refcounts.fromfile( + path.join(self.srcdir, self.config['refcount_file'])) + # clear all files no longer present for filename in removed: self.clear_file(filename) - # re-read the refcount file - self.refcounts = Refcounts.fromfile( - path.join(self.srcdir, 'data', 'refcounts.dat')) - # read all new and changed files for filename in added + changed: yield filename @@ -364,9 +375,12 @@ self.build_toc_from(filename, doctree) # calculate the MD5 of the file at time of build - with file(src_path, 'rb') as f: - md5 = hashlib.md5(f.read()).digest() - self.all_files[filename] = (path.getmtime(src_path), md5) + f = open(src_path, 'rb') + try: + md5sum = md5(f.read()).digest() + finally: + f.close() + self.all_files[filename] = (path.getmtime(src_path), md5sum) # make it picklable doctree.reporter = None @@ -388,8 +402,11 @@ dirname = path.dirname(doctree_filename) if not path.isdir(dirname): os.makedirs(dirname) - with file(doctree_filename, 'wb') as f: + f = open(doctree_filename, 'wb') + try: pickle.dump(doctree, f, pickle.HIGHEST_PROTOCOL) + finally: + f.close() else: return doctree @@ -446,9 +463,9 @@ includefiles_len = len(includefiles) for i, includefile in enumerate(includefiles): # the "previous" file for the first toctree item is the parent - previous = includefiles[i-1] if i > 0 else filename + previous = i > 0 and includefiles[i-1] or filename # the "next" file for the last toctree item is the parent again - next = includefiles[i+1] if i < includefiles_len-1 else filename + next = i < includefiles_len-1 and includefiles[i+1] or filename self.toctree_relations[includefile] = [filename, previous, next] # note that if the included file is rebuilt, this one must be # too (since the TOC of the included file could have changed) @@ -539,8 +556,11 @@ def get_doctree(self, filename): """Read the doctree for a file from the pickle and return it.""" doctree_filename = path.join(self.doctreedir, os_path(filename)[:-3] + 'doctree') - with file(doctree_filename, 'rb') as f: + f = open(doctree_filename, 'rb') + try: doctree = pickle.load(f) + finally: + f.close() doctree.reporter = Reporter(filename, 2, 4, stream=RedirStream(self._warnfunc)) return doctree @@ -617,9 +637,11 @@ if filename == docfilename: newnode['refid'] = labelid else: - # in case the following calls raises NoUri... - # else the final node will contain a label name - contnode = innernode + # set more info in contnode in case the following call + # raises NoUri, the builder will have to resolve these + contnode = addnodes.pending_xref('') + contnode['reffilename'] = filename + contnode['refsectname'] = sectname newnode['refuri'] = builder.get_relative_uri( docfilename, filename) + '#' + labelid newnode.append(innernode) @@ -669,14 +691,14 @@ newnode['refuri'] = ( builder.get_relative_uri(docfilename, filename) + anchor) newnode['reftitle'] = '%s%s%s' % ( - ('(%s) ' % platform if platform else ''), - synopsis, (' (deprecated)' if deprecated else '')) + (platform and '(%s) ' % platform), + synopsis, (deprecated and ' (deprecated)' or '')) newnode.append(contnode) else: # "descrefs" modname = node['modname'] clsname = node['classname'] - searchorder = 1 if node.hasattr('refspecific') else 0 + searchorder = node.hasattr('refspecific') and 1 or 0 name, desc = self.find_desc(modname, clsname, target, typ, searchorder) if not desc: @@ -716,7 +738,10 @@ # new entry types must be listed in directives.py! for type, string, tid, alias in entries: if type == 'single': - entry, _, subentry = string.partition(';') + try: + entry, subentry = string.split(';', 1) + except: + entry, subentry = string, '' add_entry(entry.strip(), subentry.strip()) elif type == 'pair': first, second = map(lambda x: x.strip(), string.split(';', 1)) Modified: doctools/trunk/sphinx/highlighting.py ============================================================================== --- doctools/trunk/sphinx/highlighting.py (original) +++ doctools/trunk/sphinx/highlighting.py Wed Jan 16 21:27:25 2008 @@ -9,9 +9,9 @@ :license: BSD. """ +import sys import cgi import parser -from collections import defaultdict try: import pygments @@ -42,7 +42,7 @@ Number: '#208050', }) - lexers = defaultdict(TextLexer, + lexers = dict( none = TextLexer(), python = PythonLexer(), pycon = PythonConsoleLexer(), @@ -71,8 +71,12 @@ else: # maybe Python -- try parsing it try: - parser.suite('from __future__ import with_statement\n' + - source + '\n') + # if we're using 2.5, use the with statement + if sys.version_info >= (2, 5): + parser.suite('from __future__ import with_statement\n' + + source + '\n') + else: + parser.suite(source + '\n') except (SyntaxError, UnicodeEncodeError): return unhighlighted() else: Modified: doctools/trunk/sphinx/htmlhelp.py ============================================================================== --- doctools/trunk/sphinx/htmlhelp.py (original) +++ doctools/trunk/sphinx/htmlhelp.py Wed Jan 16 21:27:25 2008 @@ -9,7 +9,6 @@ :copyright: 2007-2008 by Georg Brandl. :license: BSD. """ -from __future__ import with_statement import os import cgi @@ -17,7 +16,7 @@ from docutils import nodes -from . import addnodes +from sphinx import addnodes # Project file (*.hhp) template. 'outname' is the file basename (like # the pythlp in pythlp.hhp); 'version' is the doc version number (like @@ -64,10 +63,10 @@ Full-text search=Yes Index file=%(outname)s.hhk Language=0x409 -Title=Python %(version)s Documentation +Title=%(project)s %(version)s Documentation [WINDOWS] -%(outname)s="Python %(version)s Documentation","%(outname)s.hhc","%(outname)s.hhk",\ +%(outname)s="%(project)s %(version)s Documentation","%(outname)s.hhc","%(outname)s.hhk",\ "index.html","index.html",,,,,0x63520,220,0x10384e,[0,0,1024,768],,,,,,,0 [FILES] @@ -119,24 +118,32 @@ def build_hhx(builder, outdir, outname): builder.msg('dumping stopword list...') - with open(path.join(outdir, outname+'.stp'), 'w') as f: + f = open(path.join(outdir, outname+'.stp'), 'w') + try: for word in sorted(stopwords): print >>f, word + finally: + f.close() builder.msg('writing project file...') - with open(path.join(outdir, outname+'.hhp'), 'w') as f: + f = open(path.join(outdir, outname+'.hhp'), 'w') + try: f.write(project_template % {'outname': outname, - 'version': builder.config['version']}) + 'version': builder.config['version'], + 'project': builder.config['project']}) if not outdir.endswith(os.sep): outdir += os.sep olen = len(outdir) for root, dirs, files in os.walk(outdir): for fn in files: - if fn.endswith(('.html', '.css', '.js')): + if fn.endswith('.html') or fn.endswith('.css') or fn.endswith('.js'): print >>f, path.join(root, fn)[olen:].replace('/', '\\') + finally: + f.close() builder.msg('writing TOC file...') - with open(path.join(outdir, outname+'.hhc'), 'w') as f: + f = open(path.join(outdir, outname+'.hhc'), 'w') + try: f.write(contents_header) # special books f.write('
  • ' + object_sitemap % ('Main page', 'index.html')) @@ -167,9 +174,12 @@ write_toc(node[0], ullevel) write_toc(toc) f.write(contents_footer) + finally: + f.close() builder.msg('writing index file...') - with open(path.join(outdir, outname+'.hhk'), 'w') as f: + f = open(path.join(outdir, outname+'.hhk'), 'w') + try: f.write('
      \n') def write_index(title, refs, subitems): if refs: @@ -186,3 +196,5 @@ for title, (refs, subitems) in group: write_index(title, refs, subitems) f.write('
    \n') + finally: + f.close() Modified: doctools/trunk/sphinx/htmlwriter.py ============================================================================== --- doctools/trunk/sphinx/htmlwriter.py (original) +++ doctools/trunk/sphinx/htmlwriter.py Wed Jan 16 21:27:25 2008 @@ -12,7 +12,7 @@ from docutils import nodes from docutils.writers.html4css1 import Writer, HTMLTranslator as BaseTranslator -from .util.smartypants import sphinx_smarty_pants +from sphinx.util.smartypants import sphinx_smarty_pants class HTMLWriter(Writer): @@ -162,7 +162,7 @@ # overwritten def visit_literal_block(self, node): - from .highlighting import highlight_block + from sphinx.highlighting import highlight_block self.body.append(highlight_block(node.rawsource, self.highlightlang)) raise nodes.SkipNode @@ -246,7 +246,8 @@ def depart_title(self, node): close_tag = self.context[-1] if builder.name != 'htmlhelp' and \ - close_tag.startswith((' set(filenames) self._mapping = {} - # category -> set(filenames) - self._categories = {} def load(self, stream, format): """Reconstruct from frozen data.""" frozen = self.formats[format][1](stream.read()) index2fn = frozen[0] - self._titles = dict(zip(frozen[0], frozen[2])) - self._categories = dict((k, set(index2fn[i] for i in v)) - for (k, v) in frozen[1].iteritems()) + self._titles = dict(zip(frozen[0], frozen[1])) self._mapping = dict((k, set(index2fn[i] for i in v)) - for (k, v) in frozen[3].iteritems()) + for (k, v) in frozen[2].iteritems()) def dump(self, stream, format): """Dump the frozen index to a stream.""" @@ -87,8 +82,6 @@ fn2index = dict((f, i) for (i, f) in enumerate(fns)) return [ fns, - dict((k, [fn2index[fn] for fn in v]) - for (k, v) in self._categories.iteritems()), titles, dict((k, [fn2index[fn] for fn in v]) for (k, v) in self._mapping.iteritems()), @@ -103,13 +96,10 @@ self._titles = new_titles for wordnames in self._mapping.itervalues(): wordnames.intersection_update(filenames) - for catnames in self._categories.itervalues(): - catnames.intersection_update(filenames) - def feed(self, filename, category, title, doctree): + def feed(self, filename, title, doctree): """Feed a doctree to the index.""" self._titles[filename] = title - self._categories.setdefault(category, set()).add(filename) visitor = WordCollector(doctree) doctree.walk(visitor) @@ -125,25 +115,24 @@ """ def __init__(self, index): - self.filenames, self.areas, self.titles, self.words = index + self.filenames, self.titles, self.words = index self._stemmer = Stemmer() - def query(self, required, excluded, areas): - file_map = defaultdict(set) + def query(self, required, excluded): + file_map = {} for word in required: if word not in self.words: break for fid in self.words[word]: - file_map[fid].add(word) + file_map.setdefault(fid, set()).add(word) return sorted(((self.filenames[fid], self.titles[fid]) for fid, words in file_map.iteritems() - if len(words) == len(required) and - any(fid in self.areas.get(area, ()) for area in areas) and not + if len(words) == len(required) and not any(fid in self.words.get(word, ()) for word in excluded) ), key=lambda x: x[1].lower()) - def search(self, searchstring, areas): + def search(self, searchstring): required = set() excluded = set() for word in searchstring.split(): @@ -154,4 +143,4 @@ storage = required storage.add(self._stemmer.stem(word.lower())) - return self.query(required, excluded, areas) + return self.query(required, excluded) Modified: doctools/trunk/sphinx/style/default.css ============================================================================== --- doctools/trunk/sphinx/style/default.css (original) +++ doctools/trunk/sphinx/style/default.css Wed Jan 16 21:27:25 2008 @@ -1,5 +1,5 @@ /** - * Python Doc Design + * Sphinx Doc Design */ body { Modified: doctools/trunk/sphinx/style/rightsidebar.css ============================================================================== --- doctools/trunk/sphinx/style/rightsidebar.css (original) +++ doctools/trunk/sphinx/style/rightsidebar.css Wed Jan 16 21:27:25 2008 @@ -1,5 +1,5 @@ /** - * Python Doc Design -- Right Side Bar Overrides + * Sphinx Doc Design -- Right Side Bar Overrides */ Modified: doctools/trunk/sphinx/style/searchtools.js ============================================================================== --- doctools/trunk/sphinx/style/searchtools.js (original) +++ doctools/trunk/sphinx/style/searchtools.js Wed Jan 16 21:27:25 2008 @@ -228,27 +228,15 @@ var params = $.getQueryParameters(); if (params.q) { var query = params.q[0]; - var areas = params.area || []; - - // auto default - if (areas.length == 1 && areas[0] == 'default') { - areas = ['tutorial', 'library', 'install', 'distutils']; - } - - // update input fields - $('input[@type="checkbox"]').each(function() { - this.checked = $.contains(areas, this.value); - }); $('input[@name="q"]')[0].value = query; - - this.performSearch(query, areas); + this.performSearch(query); } }, /** * perform a search for something */ - performSearch : function(query, areas) { + performSearch : function(query) { // create the required interface elements var out = $('#search-results'); var title = $('

    Searching

    ').appendTo(out); @@ -301,14 +289,12 @@ console.debug('SEARCH: searching for:'); console.info('required: ', searchwords); console.info('excluded: ', excluded); - console.info('areas: ', areas); // fetch searchindex and perform search $.getJSON('searchindex.json', function(data) { // prepare search var filenames = data[0]; - var areaMap = data[1]; var titles = data[2] var words = data[3]; var fileMap = {}; @@ -342,38 +328,25 @@ if (fileMap[file].length != searchwords.length) { continue; } - var valid = false; - - // check if the file is in one of the searched - // areas. - for (var i = 0; i < areas.length; i++) { - if ($.contains(areaMap[areas[i]] || [], file)) { - valid = true; - break; - } - }; - // ensure that none of the excluded words is in the // search result. - if (valid) { - for (var i = 0; i < excluded.length; i++) { - if ($.contains(words[excluded[i]] || [], file)) { - valid = false; - break; - } + for (var i = 0; i < excluded.length; i++) { + if ($.contains(words[excluded[i]] || [], file)) { + valid = false; + break; } + } - // if we have still a valid result we can add it - // to the result list - if (valid) { - results.push([filenames[file], titles[file]]); - } + // if we have still a valid result we can add it + // to the result list + if (valid) { + results.push([filenames[file], titles[file]]); } } // delete unused variables in order to not waste // memory until list is retrieved completely - delete filenames, areaMap, titles, words, data; + delete filenames, titles, words, data; // now sort the results by title results.sort(function(a, b) { Modified: doctools/trunk/sphinx/style/stickysidebar.css ============================================================================== --- doctools/trunk/sphinx/style/stickysidebar.css (original) +++ doctools/trunk/sphinx/style/stickysidebar.css Wed Jan 16 21:27:25 2008 @@ -1,5 +1,5 @@ /** - * Python Doc Design -- Sticky Sidebar Overrides + * Sphinx Doc Design -- Sticky Sidebar Overrides */ div.sidebar { Modified: doctools/trunk/sphinx/style/traditional.css ============================================================================== --- doctools/trunk/sphinx/style/traditional.css (original) +++ doctools/trunk/sphinx/style/traditional.css Wed Jan 16 21:27:25 2008 @@ -1,5 +1,5 @@ /** - * Python Doc Design + * Sphinx Doc Design -- traditional python.org style */ body { Deleted: /doctools/trunk/sphinx/templates/_commentform.html ============================================================================== --- /doctools/trunk/sphinx/templates/_commentform.html Wed Jan 16 21:27:25 2008 +++ (empty file) @@ -1,34 +0,0 @@ -
    - {% if comments_form.error %} -
    {{ comments_form.error|e }}
    - {% endif %} -

    Note: you can also suggest - changes to the official documentation text.

    -
    -
    Name:
    -
    -
    E-Mail Address:
    -
    -
    Comment Title:
    -
    -
    - - - {% if preview %} -
    -

    Preview

    -
    -

    {{ preview.title|e or ' ' }}

    -
    {{ preview.parsed_comment_body or ' ' }}
    -
    by {{ preview.author|e }}, written on - {{ preview.pub_date|datetimeformat }} | - #
    -
    -
    - {% endif %} -
    - - - -
    -
    Copied: doctools/trunk/sphinx/templates/changes/frameset.html (from r59608, doctools/trunk/sphinx/templates/versionchanges_frameset.html) ============================================================================== --- doctools/trunk/sphinx/templates/versionchanges_frameset.html (original) +++ doctools/trunk/sphinx/templates/changes/frameset.html Wed Jan 16 21:27:25 2008 @@ -2,7 +2,7 @@ "http://www.w3.org/TR/html4/frameset.dtd"> - Changes in Version {{ version }} — Python Documentation + Changes in Version {{ version }} — {{ project }} Documentation Copied: doctools/trunk/sphinx/templates/changes/rstsource.html (from r59608, doctools/trunk/sphinx/templates/rstsource.html) ============================================================================== --- doctools/trunk/sphinx/templates/rstsource.html (original) +++ doctools/trunk/sphinx/templates/changes/rstsource.html Wed Jan 16 21:27:25 2008 @@ -2,7 +2,7 @@ "http://www.w3.org/TR/html4/loose.dtd"> - {{ filename }} — Python Documentation + {{ filename }} — {{ project }} Documentation Copied: doctools/trunk/sphinx/templates/changes/versionchanges.html (from r59608, doctools/trunk/sphinx/templates/versionchanges.html) ============================================================================== --- doctools/trunk/sphinx/templates/versionchanges.html (original) +++ doctools/trunk/sphinx/templates/changes/versionchanges.html Wed Jan 16 21:27:25 2008 @@ -9,7 +9,7 @@ - Changes in Version {{ version }} — Python Documentation + Changes in Version {{ version }} — {{ project }} Documentation
    Deleted: /doctools/trunk/sphinx/templates/commentform.html ============================================================================== --- /doctools/trunk/sphinx/templates/commentform.html Wed Jan 16 21:27:25 2008 +++ (empty file) @@ -1,26 +0,0 @@ -{% extends "layout.html" %} -{% block body %} -
    -

    New Comment

    - {{ form }} -
    -

    - You can format a comment using the - following syntax elements provided: -

    -

    - `code` / ``code too`` / **strong** / - *emphasized* / !!!important!!! / - [[link_target Link Title]] / - [[link_target_only]] / <code>code block with - syntax highlighting</code> / <quote>some - quoted text</quote>. -

    -

    - HTML is not supported, relative link targets are treated as - quicklinks and code blocks that start with ">>>" are - highlighted as interactive python sessions. -

    -
    -
    -{% endblock %} Deleted: /doctools/trunk/sphinx/templates/comments.html ============================================================================== --- /doctools/trunk/sphinx/templates/comments.html Wed Jan 16 21:27:25 2008 +++ (empty file) @@ -1,22 +0,0 @@ -
    -

    Comments

    - {% for comment in comments %} -
    -

    {{ comment.title|e }} - {%- if comment.associated_name %} — on - {{- - comment.associated_name }}{% endif %}

    -
    {{ comment.parsed_comment_body }}
    -
    by {{ comment.author|e }}, written on - {{ comment.pub_date|datetimeformat }} | - #
    -
    - {% else %} -
    - There are no user contributed notes for this page. -
    - {% endfor %} - -
    Deleted: /doctools/trunk/sphinx/templates/download.html ============================================================================== --- /doctools/trunk/sphinx/templates/download.html Wed Jan 16 21:27:25 2008 +++ (empty file) @@ -1,53 +0,0 @@ -{% extends "layout.html" %} -{% set title = 'Download' %} -{% block body %} - -

    Download Python {{ release }} Documentation - {%- if last_updated %} (last updated on {{ last_updated }}){% endif %}

    - -

    To download an archive containing all the documents for this version of -Python in one of various formats, follow one of links in this table. The numbers -in the table are the size of the download files in Kilobytes.

    - -{# XXX download links, relative to download_base_url #} - - -

    These archives contain all the content in the documentation section.

    - -

    Unpacking

    - -

    Unix users should download the .tar.bz2 archives; these are bzipped tar -archives and can be handled in the usual way using tar and the bzip2 -program. The InfoZIP unzip program can be -used to handle the ZIP archives if desired. The .tar.bz2 archives provide the -best compression and fastest download times.

    - -

    Windows users can use the ZIP archives since those are customary on that -platform. These are created on Unix using the InfoZIP zip program. They may be -unpacked using the free WiZ tool (from the InfoZIP developers) or any other -tool for handling ZIP archives; any of them should work.

    - -

    Note that the .tar.bz2 files are smaller than the other archives; Windows -users may want to install the bzip2 tools on their systems as well. Windows -binaries for a command-line tool are available at The bzip2 and libbzip2 official home page, but -most other archiving utilities support the tar and bzip2 formats as well.

    - - -

    Problems

    - -

    Printing PDFs using Adobe Acrobat Reader 5.0: Adobe has -reportedly admitted that there is a bug in Acrobat Reader 5.0 which causes it -not to print at least some PDF files generated by pdfTeX. This software is used -to produce the PDF version of the Python documentation, and our documents -definately trigger this bug in Acrobat Reader. To print the PDF files, use -Acrobat Reader 4.x, ghostscript, or xpdf.

    - -

    Reportedly, Acrobat Reader 6.0 can print these documents without this -problem, but we've not yet had an opportunity to confirm the report. Sadly, -version 6.0 is not yet available on Unix platforms.

    - -

    If you have comments or suggestions for the Python documentation, please send -email to docs at python.org.

    - -{% endblock %} Deleted: /doctools/trunk/sphinx/templates/edit.html ============================================================================== --- /doctools/trunk/sphinx/templates/edit.html Wed Jan 16 21:27:25 2008 +++ (empty file) @@ -1,53 +0,0 @@ -{% extends "layout.html" %} -{% if rendered %}{% set title = "Suggest changes - Preview" %} -{% else %}{% set title = "Suggest changes" %}{% endif %} -{% block body %} -{% if rendered %} -

    Preview

    -
    -
    - {{ rendered }} -
    -
    - {% if warnings %} -

    Warnings

    -

    You must fix these warnings before you can submit your patch.

    -
      - {% for warning in warnings %} -
    • {{ warning }}
    • - {% endfor %} -
    - {% endif %} -{% endif %} -

    Suggest changes for this page

    -{% if not rendered %} -

    Here you can edit the source of “{{ doctitle|striptags }}” and - submit the results as a patch to the Python documentation team. If you want - to know more about reST, the markup language used, read - Documenting Python.

    -{% endif %} -
    -
    - - {# XXX: shortcuts to make the edit area larger/smaller #} - {% if form_error %} -
    {{ form_error|e }}
    - {% endif %} -
    -
    Name:
    -
    -
    E-mail Address:
    -
    -
    Summary of the change:
    -
    -
    - -
    - - - - -
    -
    -
    -{% endblock %} Modified: doctools/trunk/sphinx/templates/index.html ============================================================================== --- doctools/trunk/sphinx/templates/index.html (original) +++ doctools/trunk/sphinx/templates/index.html Wed Jan 16 21:27:25 2008 @@ -4,67 +4,27 @@ (pathto('@rss/recent'), 'application/rss+xml', 'Recent Comments') ] %} {% block body %} -

    Python Documentation

    +

    {{ project }} Documentation

    - Welcome! This is the documentation for Python + Welcome! This is the documentation for {{ project }} {{ release }}{% if last_updated %}, last updated {{ last_updated }}{% endif %}.

    - -

    Parts of the documentation:

    - - -
    - - - - - - - - - - - - -
    - + {% if indextemplate %} + {{ rendertemplate(indextemplate) }} + {% else %}

    Indices and tables:

    -
    - - - - - - -
    - -

    Meta information:

    - -
    - - + - - + +
    - + {% endif %} {% endblock %} Deleted: /doctools/trunk/sphinx/templates/inlinecomments.html ============================================================================== --- /doctools/trunk/sphinx/templates/inlinecomments.html Wed Jan 16 21:27:25 2008 +++ (empty file) @@ -1,36 +0,0 @@ -{# rendered for inline comments -#} -
    -{%- if mode == 'bottom' %} - {%- if comments -%} - [Read Comments] - {%- else -%} - [Write Comments] - {%- endif %} -{%- else %} -
    - {%- if comments -%} - [{{ comments|length }} Comments] - {%- else -%} - [Write Comment] - {%- endif -%} -
    - {%- if comments %} -
    -

    Comments

    - - {%- for comment in comments %} -
    -

    {{ comment.title|e }}

    -
    {{ comment.parsed_comment_body }}
    -
    by {{ comment.author|e }}, written on - {{ comment.pub_date|datetimeformat }} | - #
    -
    - {%- endfor %} -
    - {%- endif %} -{%- endif %} -
    Deleted: /doctools/trunk/sphinx/templates/keyword_not_found.html ============================================================================== --- /doctools/trunk/sphinx/templates/keyword_not_found.html Wed Jan 16 21:27:25 2008 +++ (empty file) @@ -1,31 +0,0 @@ -{% extends "layout.html" %} -{% set title = 'Keyword Not Found' %} -{% block body %} -

    Keyword Not Found

    -

    - The keyword {{ keyword|e }} is not directly associated with - a page. {% if close_matches %}A similarity search returned {{ - close_matches|length }} items that are possible matches. - {% if good_matches_count %}{{ good_matches_count }} of them are really - good matches and emphasized.{% endif %}{% endif %} -

    - {% if close_matches %} -
      - {% for item in close_matches %} - {{ item.title|e }} ({{ - item.type }}) {% if item.description - %} — {{ item.description|e }}{% endif %} - {% endfor %} -
    - {% endif %} -

    - If you want to search the entire Python documentation for the string - "{{ keyword|e }}", then use the search function. -

    -

    - For a quick overview over all documented modules, - click here. -

    -{% endblock %} Modified: doctools/trunk/sphinx/templates/layout.html ============================================================================== --- doctools/trunk/sphinx/templates/layout.html (original) +++ doctools/trunk/sphinx/templates/layout.html Wed Jan 16 21:27:25 2008 @@ -1,4 +1,4 @@ -{% if builder != 'htmlhelp' %}{% set titlesuffix = " — Python Documentation" %}{% endif -%} +{% if builder != 'htmlhelp' %}{% set titlesuffix = " — " + project + " Documentation" %}{% endif -%} @@ -6,7 +6,7 @@ {{ title|striptags }}{{ titlesuffix }} {%- if builder == 'web' %} - {%- for link, type, title in page_links %} @@ -26,12 +26,16 @@ {%- endif %} - - - - - - + {%- if hasdoc('about') %} + + {%- endif %} + + + + {%- if hasdoc('copyright') %} + + {%- endif %} + {%- if parents %} {%- endif %} @@ -48,8 +52,8 @@
    Copied: doctools/trunk/sphinx/templates/web/edit.html (from r57711, doctools/trunk/sphinx/templates/edit.html) ============================================================================== --- doctools/trunk/sphinx/templates/edit.html (original) +++ doctools/trunk/sphinx/templates/web/edit.html Wed Jan 16 21:27:25 2008 @@ -22,9 +22,10 @@

    Suggest changes for this page

    {% if not rendered %}

    Here you can edit the source of “{{ doctitle|striptags }}” and - submit the results as a patch to the Python documentation team. If you want - to know more about reST, the markup language used, read - Documenting Python.

    + submit the results as a patch to the {{ project }} documentation team. + {# XXX Python specific #} + If you want to know more about reST, the markup language used, read + Documenting Python.

    {% endif %}
    Copied: doctools/trunk/sphinx/templates/web/keyword_not_found.html (from r57711, doctools/trunk/sphinx/templates/keyword_not_found.html) ============================================================================== --- doctools/trunk/sphinx/templates/keyword_not_found.html (original) +++ doctools/trunk/sphinx/templates/web/keyword_not_found.html Wed Jan 16 21:27:25 2008 @@ -20,12 +20,12 @@ {% endif %}

    - If you want to search the entire Python documentation for the string - "{{ keyword|e }}", then use the search function.

    For a quick overview over all documented modules, - click here. + click here.

    {% endblock %} Copied: doctools/trunk/sphinx/templates/web/not_found.html (from r57711, doctools/trunk/sphinx/templates/not_found.html) ============================================================================== --- doctools/trunk/sphinx/templates/not_found.html (original) +++ doctools/trunk/sphinx/templates/web/not_found.html Wed Jan 16 21:27:25 2008 @@ -6,6 +6,6 @@ The page {{ req.path|e }} does not exist on this server.

    - Click here to return to the index. + Click here to return to the index.

    {% endblock %} Copied: doctools/trunk/sphinx/templates/web/settings.html (from r57711, doctools/trunk/sphinx/templates/settings.html) ============================================================================== --- doctools/trunk/sphinx/templates/settings.html (original) +++ doctools/trunk/sphinx/templates/web/settings.html Wed Jan 16 21:27:25 2008 @@ -2,13 +2,13 @@ {% set title = 'Settings' %} {% set current_page_name = 'settings' %} {% block body %} -

    Python Documentation Settings

    +

    {{ project }} Documentation Settings

    - Here you can customize how you want to view the Python documentation. + Here you can customize how you want to view the {{ project }} documentation. These settings are saved using a cookie on your computer.

    - +

    Select your stylesheet:

    {%- for design, (foo, descr) in known_designs %} Copied: doctools/trunk/sphinx/templates/web/submitted.html (from r57711, doctools/trunk/sphinx/templates/submitted.html) ============================================================================== --- doctools/trunk/sphinx/templates/submitted.html (original) +++ doctools/trunk/sphinx/templates/web/submitted.html Wed Jan 16 21:27:25 2008 @@ -5,7 +5,7 @@ {% endblock %} {% block body %}

    Patch submitted

    -

    Your patch has been submitted to the Python documentation team and will be +

    Your patch has been submitted to the {{ project }} documentation team and will be processed shortly.

    You will be redirected to the original documentation page shortly.

    Modified: doctools/trunk/sphinx/util/__init__.py ============================================================================== --- doctools/trunk/sphinx/util/__init__.py (original) +++ doctools/trunk/sphinx/util/__init__.py Wed Jan 16 21:27:25 2008 @@ -77,14 +77,6 @@ yield canonical_path(qualified_name) -def get_category(filename): - """Get the "category" part of a RST filename.""" - parts = filename.split(SEP, 1) - if len(parts) < 2: - return - return parts[0] - - def shorten_result(text='', keywords=[], maxlen=240, fuzz=60): if not text: text = '' Modified: doctools/trunk/sphinx/util/stemmer.py ============================================================================== --- doctools/trunk/sphinx/util/stemmer.py (original) +++ doctools/trunk/sphinx/util/stemmer.py Wed Jan 16 21:27:25 2008 @@ -1,4 +1,3 @@ -#!/usr/bin/env python # -*- coding: utf-8 -*- """ sphinx.util.stemmer Modified: doctools/trunk/sphinx/web/admin.py ============================================================================== --- doctools/trunk/sphinx/web/admin.py (original) +++ doctools/trunk/sphinx/web/admin.py Wed Jan 16 21:27:25 2008 @@ -9,9 +9,9 @@ :license: BSD. """ -from .util import render_template -from .wsgiutil import Response, RedirectResponse, NotFound -from .database import Comment +from sphinx.web.util import render_template +from sphinx.web.wsgiutil import Response, RedirectResponse, NotFound +from sphinx.web.database import Comment class AdminPanel(object): Modified: doctools/trunk/sphinx/web/antispam.py ============================================================================== --- doctools/trunk/sphinx/web/antispam.py (original) +++ doctools/trunk/sphinx/web/antispam.py Wed Jan 16 21:27:25 2008 @@ -9,7 +9,7 @@ :copyright: 2007-2008 by Armin Ronacher. :license: BSD. """ -from __future__ import with_statement + import re import urllib import time @@ -43,14 +43,20 @@ else: lines = [l.strip() for l in data.splitlines() if not l.startswith('#')] - with file(bad_content_file, 'w') as f: + f = open(bad_content_file, 'w') + try: f.write('\n'.join(lines)) + finally: + f.close() last_change = int(time.time()) if lines is None: try: - with file(bad_content_file) as f: + f = open(bad_content_file) + try: lines = [l.strip() for l in f] + finally: + f.close() except: lines = [] self.rules = [re.compile(rule) for rule in lines if rule] Modified: doctools/trunk/sphinx/web/application.py ============================================================================== --- doctools/trunk/sphinx/web/application.py (original) +++ doctools/trunk/sphinx/web/application.py Wed Jan 16 21:27:25 2008 @@ -9,7 +9,6 @@ :copyright: 2007-2008 by Georg Brandl, Armin Ronacher. :license: BSD. """ -from __future__ import with_statement import os import re @@ -24,24 +23,23 @@ import cStringIO as StringIO from os import path from itertools import groupby -from collections import defaultdict -from .feed import Feed -from .mail import Email -from .util import render_template, get_target_uri, blackhole_dict, striptags -from .admin import AdminPanel -from .userdb import UserDatabase -from .robots import robots_txt -from .oldurls import handle_html_url -from .antispam import AntiSpam -from .database import connect, set_connection, Comment -from .wsgiutil import Request, Response, RedirectResponse, \ +from sphinx.web.feed import Feed +from sphinx.web.mail import Email +from sphinx.web.util import render_template, get_target_uri, blackhole_dict, striptags +from sphinx.web.admin import AdminPanel +from sphinx.web.userdb import UserDatabase +from sphinx.web.robots import robots_txt +from sphinx.web.oldurls import handle_html_url +from sphinx.web.antispam import AntiSpam +from sphinx.web.database import connect, set_connection, Comment +from sphinx.web.wsgiutil import Request, Response, RedirectResponse, \ JSONResponse, SharedDataMiddleware, NotFound, get_base_uri -from ..util import relative_uri -from ..search import SearchFrontend -from ..htmlwriter import HTMLWriter -from ..builder import LAST_BUILD_FILENAME, ENV_PICKLE_FILENAME +from sphinx.util import relative_uri +from sphinx.search import SearchFrontend +from sphinx.htmlwriter import HTMLWriter +from sphinx.builder import LAST_BUILD_FILENAME, ENV_PICKLE_FILENAME from docutils.io import StringOutput from docutils.utils import Reporter @@ -123,8 +121,11 @@ """ def __init__(self, config): - self.cache = blackhole_dict() if config['debug'] else {} - self.freqmodules = defaultdict(int) + if config['debug']: + self.cache = blackhole_dict() + else: + self.cache = {} + self.freqmodules = {} self.last_most_frequent = [] self.generated_stylesheets = {} self.config = config @@ -139,19 +140,31 @@ def load_env(self, new_mtime): - with env_lock: + env_lock.acquire() + try: if self.buildmtime == new_mtime: # happens if another thread already reloaded the env return print "* Loading the environment..." - with file(path.join(self.data_root, ENV_PICKLE_FILENAME), 'rb') as f: + f = open(path.join(self.data_root, ENV_PICKLE_FILENAME), 'rb') + try: self.env = pickle.load(f) - with file(path.join(self.data_root, 'globalcontext.pickle'), 'rb') as f: + finally: + f.close() + f = open(path.join(self.data_root, 'globalcontext.pickle'), 'rb') + try: self.globalcontext = pickle.load(f) - with file(path.join(self.data_root, 'searchindex.pickle'), 'rb') as f: + finally: + f.close() + f = open(path.join(self.data_root, 'searchindex.pickle'), 'rb') + try: self.search_frontend = SearchFrontend(pickle.load(f)) + finally: + f.close() self.buildmtime = new_mtime self.cache.clear() + finally: + env_lock.release() def search(self, req): @@ -167,12 +180,15 @@ """ Get the reST source of a page. """ - page_id = self.env.get_real_filename(page) + page_id = self.env.get_real_filename(page)[:-4] if page_id is None: raise NotFound() - filename = path.join(self.data_root, 'sources', page_id)[:-3] + 'txt' - with file(filename) as f: + filename = path.join(self.data_root, 'sources', page_id) + '.txt' + f = open(filename) + try: return page_id, f.read() + finally: + f.close() def show_source(self, req, page): @@ -191,7 +207,7 @@ return Response(render_template(req, 'edit.html', self.globalcontext, dict( contents=contents, pagename=page, - doctitle=self.globalcontext['titles'].get(page_id) or 'this page', + doctitle=self.globalcontext['titles'].get(page_id+'.rst') or 'this page', submiturl=relative_uri('/@edit/'+page+'/', '/@submit/'+page), ))) @@ -209,11 +225,11 @@ builder = MockBuilder() builder.config = env2.config writer = HTMLWriter(builder) - doctree = env2.read_file(page_id, pathname, save_parsed=False) - doctree = env2.get_and_resolve_doctree(page_id, builder, doctree) + doctree = env2.read_file(page_id+'.rst', pathname, save_parsed=False) + doctree = env2.get_and_resolve_doctree(page_id+'.rst', builder, doctree) doctree.settings = OptionParser(defaults=env2.settings, components=(writer,)).get_default_values() - doctree.reporter = Reporter(page_id, 2, 4, stream=warning_stream) + doctree.reporter = Reporter(page_id+'.rst', 2, 4, stream=warning_stream) output = writer.write(doctree, destination) writer.assemble_parts() return writer.parts['fragment'] @@ -302,7 +318,7 @@ referer = '' else: referer = referer[len(base):] - referer = referer.rpartition('?')[0] or referer + referer = referer.split('?')[0] or referer if req.method == 'POST': if req.form.get('cancel'): @@ -362,8 +378,11 @@ yield '@modindex' filename = path.join(self.data_root, 'modindex.fpickle') - with open(filename, 'rb') as f: + f = open(filename, 'rb') + try: context = pickle.load(f) + finally: + f.close() if showpf: entries = context['modindexentries'] i = 0 @@ -386,7 +405,7 @@ """ Show the "new comment" form. """ - page_id = self.env.get_real_filename(page) + page_id = self.env.get_real_filename(page)[:-4] ajax_mode = req.args.get('mode') == 'ajax' target = req.args.get('target') page_comment_mode = not target @@ -466,7 +485,7 @@ return comment_url = '@comments/%s/' % url - page_id = self.env.get_real_filename(url) + page_id = self.env.get_real_filename(url)[:-4] tx = context['body'] all_comments = Comment.get_for_page(page_id) global_comments = [] @@ -509,17 +528,17 @@ Show the requested documentation page or raise an `NotFound` exception to display a page with close matches. """ - page_id = self.env.get_real_filename(url) + page_id = self.env.get_real_filename(url)[:-4] if page_id is None: raise NotFound(show_keyword_matches=True) # increment view count of all modules on that page - for modname in self.env.filemodules.get(page_id, ()): - self.freqmodules[modname] += 1 + for modname in self.env.filemodules.get(page_id+'.rst', ()): + self.freqmodules[modname] = self.freqmodules.get(modname, 0) + 1 # comments enabled? - comments = self.env.metadata[page_id].get('nocomments', False) + comments = self.env.metadata[page_id+'.rst'].get('nocomments', False) # how does the user want to view comments? - commentmode = req.session.get('comments', 'inline') if comments else '' + commentmode = comments and req.session.get('comments', 'inline') or '' # show "old URL" message? -> no caching possible oldurl = req.args.get('oldurl') @@ -530,9 +549,12 @@ yield page_id + '|' + commentmode # cache miss; load the page and render it - filename = path.join(self.data_root, page_id[:-3] + 'fpickle') - with open(filename, 'rb') as f: + filename = path.join(self.data_root, page_id + '.fpickle') + f = open(filename, 'rb') + try: context = pickle.load(f) + finally: + f.close() # add comments to paqe text if commentmode != 'none': @@ -546,8 +568,11 @@ def get_special_page(self, req, name): yield '@'+name filename = path.join(self.data_root, name + '.fpickle') - with open(filename, 'rb') as f: + f = open(filename, 'rb') + try: context = pickle.load(f) + finally: + f.close() yield render_template(req, name+'.html', self.globalcontext, context) @@ -559,8 +584,8 @@ feed.add_item(comment.title, comment.author, comment.url, comment.parsed_comment_body, comment.pub_date) else: - page_id = self.env.get_real_filename(url) - doctitle = striptags(self.globalcontext['titles'].get(page_id, url)) + page_id = self.env.get_real_filename(url)[:-4] + doctitle = striptags(self.globalcontext['titles'].get(page_id+'.rst', url)) feed = Feed(req, 'Comments for "%s"' % doctitle, 'List of comments for the topic "%s"' % doctitle, url) for comment in Comment.get_for_page(page_id): @@ -632,7 +657,7 @@ 'close_matches': close_matches, 'good_matches_count': good_matches, 'keyword': term - }, self.globalcontext), status=404 if is_error_page else 404) + }, self.globalcontext), status=404) def get_user_stylesheet(self, req): @@ -650,15 +675,21 @@ else: stylesheet = [] for filename in known_designs[style][0]: - with file(path.join(self.data_root, 'style', filename)) as f: + f = open(path.join(self.data_root, 'style', filename)) + try: stylesheet.append(f.read()) + finally: + f.close() stylesheet = '\n'.join(stylesheet) if not self.config.get('debug'): self.generated_stylesheets[style] = stylesheet if req.args.get('admin') == 'yes': - with file(path.join(self.data_root, 'style', 'admin.css')) as f: + f = open(path.join(self.data_root, 'style', 'admin.css')) + try: stylesheet += '\n' + f.read() + finally: + f.close() # XXX: add timestamp based http caching return Response(stylesheet, mimetype='text/css') Modified: doctools/trunk/sphinx/web/database.py ============================================================================== --- doctools/trunk/sphinx/web/database.py (original) +++ doctools/trunk/sphinx/web/database.py Wed Jan 16 21:27:25 2008 @@ -17,7 +17,7 @@ from datetime import datetime from threading import local -from .markup import markup +from sphinx.web.markup import markup _thread_local = local() @@ -88,14 +88,14 @@ @property def url(self): return '%s#comment-%s' % ( - self.associated_page[:-4], + self.associated_page, self.comment_id ) @property def parsed_comment_body(self): - from .util import get_target_uri - from ..util import relative_uri + from sphinx.web.util import get_target_uri + from sphinx.util import relative_uri uri = get_target_uri(self.associated_page) def make_rel_link(keyword): return relative_uri(uri, 'q/%s/' % keyword) @@ -153,7 +153,7 @@ cur = get_cursor() cur.execute('''select * from comments where associated_page = ? order by associated_name, comment_id %s''' % - ('desc' if reverse else 'asc'), + (reverse and 'desc' or 'asc'), (associated_page,)) try: return [Comment._make_comment(row) for row in cur] Modified: doctools/trunk/sphinx/web/markup.py ============================================================================== --- doctools/trunk/sphinx/web/markup.py (original) +++ doctools/trunk/sphinx/web/markup.py Wed Jan 16 21:27:25 2008 @@ -42,7 +42,7 @@ import re from urlparse import urlparse -from ..highlighting import highlight_block +from sphinx.highlighting import highlight_block inline_formatting = { @@ -212,7 +212,7 @@ elif protocol == 'javascript': href = href[11:] paragraph.append('%s' % (cgi.escape(href), - ' rel="nofollow"' if nofollow else '', + nofollow and ' rel="nofollow"' or '', cgi.escape(caption))) elif token == 'code_block': result.append(highlight_block(data, 'python')) Modified: doctools/trunk/sphinx/web/oldurls.py ============================================================================== --- doctools/trunk/sphinx/web/oldurls.py (original) +++ doctools/trunk/sphinx/web/oldurls.py Wed Jan 16 21:27:25 2008 @@ -11,7 +11,7 @@ import re -from .wsgiutil import RedirectResponse, NotFound +from sphinx.web.wsgiutil import RedirectResponse, NotFound _module_re = re.compile(r'module-(.*)\.html') @@ -78,7 +78,7 @@ # tutorial elif url[:4] == 'tut/': try: - node = int(url[8:].partition('.html')[0]) + node = int(url[8:].split('.html')[0]) except ValueError: pass else: Modified: doctools/trunk/sphinx/web/serve.py ============================================================================== --- doctools/trunk/sphinx/web/serve.py (original) +++ doctools/trunk/sphinx/web/serve.py Wed Jan 16 21:27:25 2008 @@ -63,7 +63,7 @@ def run_with_reloader(main_func, extra_watch): """ - Run the given function in an independent python interpreter. + Run the given function in an independent Python interpreter. """ if os.environ.get('RUN_MAIN') == 'true': thread.start_new_thread(main_func, ()) Modified: doctools/trunk/sphinx/web/userdb.py ============================================================================== --- doctools/trunk/sphinx/web/userdb.py (original) +++ doctools/trunk/sphinx/web/userdb.py Wed Jan 16 21:27:25 2008 @@ -10,11 +10,10 @@ :copyright: 2007-2008 by Armin Ronacher. :license: BSD. """ -from __future__ import with_statement + from os import path from hashlib import sha1 from random import choice, randrange -from collections import defaultdict def gen_password(length=8, add_numbers=True, mix_case=True, @@ -56,17 +55,19 @@ def __init__(self, filename): self.filename = filename self.users = {} - self.privileges = defaultdict(set) + self.privileges = {} if path.exists(filename): - with file(filename) as f: + f = open(filename) + try: for line in f: line = line.strip() if line and line[0] != '#': parts = line.split(':') self.users[parts[0]] = parts[1] - self.privileges[parts[0]].update(x for x in - parts[2].split(',') - if x) + self.privileges.setdefault(parts[0], set()).update( + x for x in parts[2].split(',') if x) + finally: + f.close() def set_password(self, user, password): """Encode the password for a user (also adds users).""" @@ -84,7 +85,10 @@ self.users[user] == sha1('%s|%s' % (user, password)).hexdigest() def save(self): - with file(self.filename, 'w') as f: + f = open(self.filename, 'w') + try: for username, password in self.users.iteritems(): privileges = ','.join(self.privileges.get(username, ())) f.write('%s:%s:%s\n' % (username, password, privileges)) + finally: + f.close() Modified: doctools/trunk/sphinx/web/util.py ============================================================================== --- doctools/trunk/sphinx/web/util.py (original) +++ doctools/trunk/sphinx/web/util.py Wed Jan 16 21:27:25 2008 @@ -8,22 +8,21 @@ :copyright: 2007-2008 by Georg Brandl. :license: BSD. """ -from __future__ import with_statement import re from os import path -from ..util import relative_uri -from .._jinja import Environment, FileSystemLoader +from sphinx.util import relative_uri +from sphinx._jinja import Environment, FileSystemLoader def get_target_uri(source_filename): - """Get the web-URI for a given reST file name.""" - if source_filename == 'index.rst': + """Get the web-URI for a given reST file name (without extension).""" + if source_filename == 'index': return '' - if source_filename.endswith('/index.rst'): - return source_filename[:-9] # up to / - return source_filename[:-4] + '/' + if source_filename.endswith('/index'): + return source_filename[:-5] # up to / + return source_filename + '/' # ------------------------------------------------------------------------------ Modified: doctools/trunk/sphinx/web/webconf.py ============================================================================== --- doctools/trunk/sphinx/web/webconf.py (original) +++ doctools/trunk/sphinx/web/webconf.py Wed Jan 16 21:27:25 2008 @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- # -# Python documentation web application configuration file +# Sphinx documentation web application configuration file # # Where the server listens. Modified: doctools/trunk/sphinx/web/wsgiutil.py ============================================================================== --- doctools/trunk/sphinx/web/wsgiutil.py (original) +++ doctools/trunk/sphinx/web/wsgiutil.py Wed Jan 16 21:27:25 2008 @@ -9,7 +9,6 @@ :copyright: 2007-2008 by Armin Ronacher. :license: BSD. """ -from __future__ import with_statement import cgi import urllib @@ -23,8 +22,8 @@ from datetime import datetime from cStringIO import StringIO -from .util import lazy_property -from ..util.json import dump_json +from sphinx.web.util import lazy_property +from sphinx.util.json import dump_json HTTP_STATUS_CODES = { @@ -371,8 +370,11 @@ self.sid = sid if sid is not None: if path.exists(self.filename): - with file(self.filename, 'rb') as f: + f = open(self.filename, 'rb') + try: self.update(pickle.load(f)) + finally: + f.close() self._orig = dict(self) @property @@ -387,8 +389,11 @@ def save(self): if self.sid is None: self.sid = sha1('%s|%s' % (time(), random())).hexdigest() - with file(self.filename, 'wb') as f: + f = open(self.filename, 'wb') + try: pickle.dump(dict(self), f, pickle.HIGHEST_PROTOCOL) + finally: + f.close() self._orig = dict(self) @@ -669,8 +674,11 @@ start_response('200 OK', [('Content-Type', mime_type), ('Cache-Control', 'public'), ('Expires', expiry)]) - with open(filename, 'rb') as f: + f = open(filename, 'rb') + try: return [f.read()] + finally: + f.close() def __call__(self, environ, start_response): p = environ.get('PATH_INFO', '') From python-checkins at python.org Wed Jan 16 21:27:56 2008 From: python-checkins at python.org (georg.brandl) Date: Wed, 16 Jan 2008 21:27:56 +0100 (CET) Subject: [Python-checkins] r60006 - in python/trunk/Doc: conf.py tools/sphinx-build.py tools/sphinxext tools/sphinxext/download.html tools/sphinxext/indexcontent.html tools/sphinxext/indexsidebar.html Message-ID: <20080116202756.C65581E4003@bag.python.org> Author: georg.brandl Date: Wed Jan 16 21:27:56 2008 New Revision: 60006 Added: python/trunk/Doc/tools/sphinxext/ python/trunk/Doc/tools/sphinxext/download.html python/trunk/Doc/tools/sphinxext/indexcontent.html python/trunk/Doc/tools/sphinxext/indexsidebar.html Modified: python/trunk/Doc/conf.py python/trunk/Doc/tools/sphinx-build.py Log: Add Python-specific content to Doc dir. Update configuration file to work with the newest Sphinx. Modified: python/trunk/Doc/conf.py ============================================================================== --- python/trunk/Doc/conf.py (original) +++ python/trunk/Doc/conf.py Wed Jan 16 21:27:56 2008 @@ -2,22 +2,28 @@ # # Python documentation build configuration file # +# This file is execfile()d with the current directory set to its containing dir. +# # The contents of this file are pickled, so don't put values in the namespace # that aren't pickleable (module imports are okay, they're removed automatically). # General configuration # --------------------- +# General substitutions. +project = 'Python' +copyright = '1990-2007, Python Software Foundation' + # The default replacements for |version| and |release|. -# If 'auto', Sphinx looks for the Include/patchlevel.h file in the current Python +# If '', Sphinx looks for the Include/patchlevel.h file in the current Python # source tree and replaces the values accordingly. # # The short X.Y version. # version = '2.6' -version = 'auto' +version = '' # The full version, including alpha/beta/rc tags. # release = '2.6a0' -release = 'auto' +release = '' # There are two options for replacing |today|: either, you set today to some # non-false value, then it is used: @@ -38,6 +44,9 @@ 'library/xml.etree.rst', ] +# Relative filename of the reference count data file. +refcount_file = 'data/refcounts.dat' + # If true, '()' will be appended to :func: etc. cross-reference text. add_function_parentheses = True @@ -49,9 +58,6 @@ # Options for HTML output # ----------------------- -# The base URL for download links. -html_download_base_url = 'http://docs.python.org/ftp/python/doc/' - # If not '', a 'Last updated on:' timestamp is inserted at every page bottom, # using the given strftime format. html_last_updated_fmt = '%b %d, %Y' @@ -60,12 +66,71 @@ # typographically correct entities. html_use_smartypants = True +# Content template for the index page, filename relative to this file. +html_index = 'tools/sphinxext/indexcontent.html' + +# Custom sidebar templates, filenames relative to this file. +html_sidebars = { + 'index': 'tools/sphinxext/indexsidebar.html', +} + +# Additional templates that should be rendered to pages. +html_additional_pages = { + 'download': 'tools/sphinxext/download.html', +} + +# Output file base name for HTML help builder. +htmlhelp_basename = 'pydoc' + # Options for LaTeX output # ------------------------ -# The paper size ("letter" or "a4"). -latex_paper_size = "a4" +# The paper size ('letter' or 'a4'). +latex_paper_size = 'a4' + +# The font size ('10pt', '11pt' or '12pt'). +latex_font_size = '10pt' + +# Grouping the document tree into LaTeX files. List of tuples +# (source start file, target name, title, author, document class [howto/manual]). +_stdauthor = r'Guido van Rossum\\Fred L. Drake, Jr., editor' +latex_documents = [ + ('c-api/index.rst', 'c-api.tex', + 'The Python/C API', _stdauthor, 'manual'), + ('distutils/index.rst', 'distutils.tex', + 'Distributing Python Modules', _stdauthor, 'manual'), + ('documenting/index.rst', 'documenting.tex', + 'Documenting Python', 'Georg Brandl', 'manual'), + ('extending/index.rst', 'extending.tex', + 'Extending and Embedding Python', _stdauthor, 'manual'), + ('install/index.rst', 'install.tex', + 'Installing Python Modules', _stdauthor, 'manual'), + ('library/index.rst', 'library.tex', + 'The Python Library Reference', _stdauthor, 'manual'), + ('reference/index.rst', 'reference.tex', + 'The Python Language Reference', _stdauthor, 'manual'), + ('tutorial/index.rst', 'tutorial.tex', + 'Python Tutorial', _stdauthor, 'manual'), + ('using/index.rst', 'using.tex', + 'Using Python', _stdauthor, 'manual'), + ('whatsnew/' + version + '.rst', 'whatsnew.tex', + 'What\'s New in Python', 'A. M. Kuchling', 'howto'), +] +# Collect all HOWTOs individually +import os +latex_documents.extend(('howto/' + fn, 'howto-' + fn[:-4] + '.tex', + 'HOWTO', _stdauthor, 'howto') + for fn in os.listdir('howto') + if fn.endswith('.rst') and fn != 'index.rst') + +# Additional stuff for the LaTeX preamble. +latex_preamble = r''' +\authoraddress{ + \strong{Python Software Foundation}\\ + Email: \email{docs at python.org} +} +''' -# The font size ("10pt", "11pt" or "12pt"). -latex_font_size = "10pt" +# Documents to append as an appendix to all manuals. +latex_appendices = ['glossary.rst', 'about.rst', 'license.rst', 'copyright.rst'] Modified: python/trunk/Doc/tools/sphinx-build.py ============================================================================== --- python/trunk/Doc/tools/sphinx-build.py (original) +++ python/trunk/Doc/tools/sphinx-build.py Wed Jan 16 21:27:56 2008 @@ -11,14 +11,14 @@ if __name__ == '__main__': - if sys.version_info[:3] < (2, 5, 1): - print >>sys.stderr, """\ -Error: Sphinx needs to be executed with Python 2.5.1 or newer -(If you run this from the Makefile, you can set the PYTHON variable -to the path of an alternative interpreter executable, e.g., -``make html PYTHON=python2.5``). -""" - sys.exit(1) +# if sys.version_info[:3] < (2, 5, 1): +# print >>sys.stderr, """\ +#Error: Sphinx needs to be executed with Python 2.5.1 or newer +#(If you run this from the Makefile, you can set the PYTHON variable +#to the path of an alternative interpreter executable, e.g., +#``make html PYTHON=python2.5``). +#""" +# sys.exit(1) from sphinx import main sys.exit(main(sys.argv)) Added: python/trunk/Doc/tools/sphinxext/download.html ============================================================================== --- (empty file) +++ python/trunk/Doc/tools/sphinxext/download.html Wed Jan 16 21:27:56 2008 @@ -0,0 +1,53 @@ +{% extends "layout.html" %} +{% set title = 'Download' %} +{% block body %} + +

    Download Python {{ release }} Documentation + {%- if last_updated %} (last updated on {{ last_updated }}){% endif %}

    + +

    To download an archive containing all the documents for this version of +Python in one of various formats, follow one of links in this table. The numbers +in the table are the size of the download files in Kilobytes.

    + +{# XXX download links #} + + +

    These archives contain all the content in the documentation section.

    + +

    Unpacking

    + +

    Unix users should download the .tar.bz2 archives; these are bzipped tar +archives and can be handled in the usual way using tar and the bzip2 +program. The InfoZIP unzip program can be +used to handle the ZIP archives if desired. The .tar.bz2 archives provide the +best compression and fastest download times.

    + +

    Windows users can use the ZIP archives since those are customary on that +platform. These are created on Unix using the InfoZIP zip program. They may be +unpacked using the free WiZ tool (from the InfoZIP developers) or any other +tool for handling ZIP archives; any of them should work.

    + +

    Note that the .tar.bz2 files are smaller than the other archives; Windows +users may want to install the bzip2 tools on their systems as well. Windows +binaries for a command-line tool are available at The bzip2 and libbzip2 official home page, but +most other archiving utilities support the tar and bzip2 formats as well.

    + + +

    Problems

    + +

    Printing PDFs using Adobe Acrobat Reader 5.0: Adobe has +reportedly admitted that there is a bug in Acrobat Reader 5.0 which causes it +not to print at least some PDF files generated by pdfTeX. This software is used +to produce the PDF version of the Python documentation, and our documents +definately trigger this bug in Acrobat Reader. To print the PDF files, use +Acrobat Reader 4.x, ghostscript, or xpdf.

    + +

    Reportedly, Acrobat Reader 6.0 can print these documents without this +problem, but we've not yet had an opportunity to confirm the report. Sadly, +version 6.0 is not yet available on Unix platforms.

    + +

    If you have comments or suggestions for the Python documentation, please send +email to docs at python.org.

    + +{% endblock %} Added: python/trunk/Doc/tools/sphinxext/indexcontent.html ============================================================================== --- (empty file) +++ python/trunk/Doc/tools/sphinxext/indexcontent.html Wed Jan 16 21:27:56 2008 @@ -0,0 +1,56 @@ +

    Parts of the documentation:

    + + +
    + + + + + + + + + + + + +
    + +

    Indices and tables:

    + + +
    + + + + + + +
    + +

    Meta information:

    + + +
    + + + + + +
    Added: python/trunk/Doc/tools/sphinxext/indexsidebar.html ============================================================================== --- (empty file) +++ python/trunk/Doc/tools/sphinxext/indexsidebar.html Wed Jan 16 21:27:56 2008 @@ -0,0 +1,19 @@ +

    Download

    +

    Download these documents

    +

    Other resources

    + From python-checkins at python.org Wed Jan 16 21:29:00 2008 From: python-checkins at python.org (georg.brandl) Date: Wed, 16 Jan 2008 21:29:00 +0100 (CET) Subject: [Python-checkins] r60007 - python/trunk/Doc/tools/sphinx-build.py Message-ID: <20080116202900.B6BCD1E402C@bag.python.org> Author: georg.brandl Date: Wed Jan 16 21:29:00 2008 New Revision: 60007 Modified: python/trunk/Doc/tools/sphinx-build.py Log: Doc build should work with 2.4 now. Modified: python/trunk/Doc/tools/sphinx-build.py ============================================================================== --- python/trunk/Doc/tools/sphinx-build.py (original) +++ python/trunk/Doc/tools/sphinx-build.py Wed Jan 16 21:29:00 2008 @@ -11,14 +11,14 @@ if __name__ == '__main__': -# if sys.version_info[:3] < (2, 5, 1): -# print >>sys.stderr, """\ -#Error: Sphinx needs to be executed with Python 2.5.1 or newer -#(If you run this from the Makefile, you can set the PYTHON variable -#to the path of an alternative interpreter executable, e.g., -#``make html PYTHON=python2.5``). -#""" -# sys.exit(1) + if sys.version_info[:3] < (2, 4, 0): + print >>sys.stderr, """\ +Error: Sphinx needs to be executed with Python 2.4 or newer +(If you run this from the Makefile, you can set the PYTHON variable +to the path of an alternative interpreter executable, e.g., +``make html PYTHON=python2.5``). +""" + sys.exit(1) from sphinx import main sys.exit(main(sys.argv)) From python-checkins at python.org Wed Jan 16 21:34:38 2008 From: python-checkins at python.org (thomas.heller) Date: Wed, 16 Jan 2008 21:34:38 +0100 (CET) Subject: [Python-checkins] r60008 - in python/trunk: Lib/ctypes/__init__.py Modules/_ctypes/_ctypes.c Modules/_ctypes/cfield.c Message-ID: <20080116203438.4C92E1E400A@bag.python.org> Author: thomas.heller Date: Wed Jan 16 21:34:37 2008 New Revision: 60008 Modified: python/trunk/Lib/ctypes/__init__.py python/trunk/Modules/_ctypes/_ctypes.c python/trunk/Modules/_ctypes/cfield.c Log: Use 'g' instead of 'D' as the ctypes typecode for c_longdouble, for compliance with PEP 3118. Modified: python/trunk/Lib/ctypes/__init__.py ============================================================================== --- python/trunk/Lib/ctypes/__init__.py (original) +++ python/trunk/Lib/ctypes/__init__.py Wed Jan 16 21:34:37 2008 @@ -185,7 +185,7 @@ _check_size(c_double) class c_longdouble(_SimpleCData): - _type_ = "D" + _type_ = "g" if sizeof(c_longdouble) == sizeof(c_double): c_longdouble = c_double Modified: python/trunk/Modules/_ctypes/_ctypes.c ============================================================================== --- python/trunk/Modules/_ctypes/_ctypes.c (original) +++ python/trunk/Modules/_ctypes/_ctypes.c Wed Jan 16 21:34:37 2008 @@ -1113,7 +1113,7 @@ */ -static char *SIMPLE_TYPE_CHARS = "cbBhHiIlLdfuzZqQPXOvtD"; +static char *SIMPLE_TYPE_CHARS = "cbBhHiIlLdfuzZqQPXOvtg"; static PyObject * c_wchar_p_from_param(PyObject *type, PyObject *value) Modified: python/trunk/Modules/_ctypes/cfield.c ============================================================================== --- python/trunk/Modules/_ctypes/cfield.c (original) +++ python/trunk/Modules/_ctypes/cfield.c Wed Jan 16 21:34:37 2008 @@ -995,7 +995,7 @@ static PyObject * -D_set(void *ptr, PyObject *value, Py_ssize_t size) +g_set(void *ptr, PyObject *value, Py_ssize_t size) { long double x; @@ -1011,7 +1011,7 @@ } static PyObject * -D_get(void *ptr, Py_ssize_t size) +g_get(void *ptr, Py_ssize_t size) { long double val; memcpy(&val, ptr, sizeof(long double)); @@ -1612,7 +1612,7 @@ { 'B', B_set, B_get, &ffi_type_uchar}, { 'c', c_set, c_get, &ffi_type_schar}, { 'd', d_set, d_get, &ffi_type_double, d_set_sw, d_get_sw}, - { 'D', D_set, D_get, &ffi_type_longdouble}, + { 'g', g_set, g_get, &ffi_type_longdouble}, { 'f', f_set, f_get, &ffi_type_float, f_set_sw, f_get_sw}, { 'h', h_set, h_get, &ffi_type_sshort, h_set_sw, h_get_sw}, { 'H', H_set, H_get, &ffi_type_ushort, H_set_sw, H_get_sw}, From nnorwitz at gmail.com Wed Jan 16 22:13:34 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Wed, 16 Jan 2008 16:13:34 -0500 Subject: [Python-checkins] Python Regression Test Failures basics (1) Message-ID: <20080116211334.GA24219@python.psfb.org> test_grammar test_opcodes test_dict test_builtin test_exceptions test_types test_unittest test_doctest test_doctest2 test_MimeWriter test_StringIO test___all__ test___future__ test__locale test_abc test_abstract_numbers test_aepack test_aepack skipped -- No module named aepack test_al test_al skipped -- No module named al test_anydbm test_applesingle test_applesingle skipped -- No module named macostools test_array test_ast test_asynchat WARNING: failed to listen on port 54322, trying another WARNING: failed to listen on port 9907, trying another WARNING: failed to listen on port 10243, trying another test_asyncore test_atexit test_audioop test_augassign test_base64 test_bastion test_bigaddrspace test_bigmem test_binascii test_binhex test_binop test_bisect test_bool test_bsddb test_bsddb185 test_bsddb185 skipped -- No module named bsddb185 test_bsddb3 test_bsddb3 skipped -- Use of the `bsddb' resource not enabled test_buffer test_bufio test_bz2 test_cProfile test_calendar test_call test_capi test_cd test_cd skipped -- No module named cd test_cfgparser test_cgi test_charmapcodec test_cl test_cl skipped -- No module named cl test_class test_cmath test_cmd test_cmd_line test_cmd_line_script test_code test_codeccallbacks test_codecencodings_cn test_codecencodings_hk test_codecencodings_jp test_codecencodings_kr test_codecencodings_tw test_codecmaps_cn test_codecmaps_cn skipped -- Use of the `urlfetch' resource not enabled test_codecmaps_hk test_codecmaps_hk skipped -- Use of the `urlfetch' resource not enabled test_codecmaps_jp test_codecmaps_jp skipped -- Use of the `urlfetch' resource not enabled test_codecmaps_kr test_codecmaps_kr skipped -- Use of the `urlfetch' resource not enabled test_codecmaps_tw test_codecmaps_tw skipped -- Use of the `urlfetch' resource not enabled test_codecs test_codeop test_coding test_coercion test_collections test_colorsys test_commands test_compare test_compile test_compiler test_complex test_complex_args test_contains test_contextlib test_cookie test_cookielib test_copy test_copy_reg test_cpickle test_crypt test_csv test_ctypes test_curses test_curses skipped -- Use of the `curses' resource not enabled test_datetime test_dbm test_decimal test_decorators test_defaultdict test_deque test_descr test_descrtut test_difflib test_dircache test_dis test_distutils test_dl test_docxmlrpc test_dumbdbm test_dummy_thread test_dummy_threading test_email test_email_codecs test_email_renamed test_enumerate test_eof test_errno test_exception_variations test_extcall test_fcntl test_file test_filecmp test_fileinput test_float test_fnmatch test_fork1 test_format test_fpformat test_frozen test_ftplib test test_ftplib failed -- Traceback (most recent call last): File "/tmp/python-test/local/lib/python2.6/test/test_ftplib.py", line 42, in testBasic ftp = ftplib.FTP("localhost") File "/tmp/python-test/local/lib/python2.6/ftplib.py", line 114, in __init__ self.connect(host) File "/tmp/python-test/local/lib/python2.6/ftplib.py", line 129, in connect self.sock = socket.create_connection((self.host, self.port), self.timeout) File "/tmp/python-test/local/lib/python2.6/socket.py", line 465, in create_connection raise error, msg error: [Errno 111] Connection refused test_funcattrs test_functools test_future test_gc test_gdbm test_generators test_genericpath test_genexps test_getargs test_getargs2 test_getopt test_gettext test_gl test_gl skipped -- No module named gl test_glob test_global test_grp test_gzip test_hash test_hashlib test_heapq test_hexoct test_hmac test_hotshot test_htmllib test_htmlparser test_httplib test_imageop test_imageop skipped -- No module named imgfile test_imaplib test_imgfile test_imgfile skipped -- No module named imgfile test_imp test_import test_importhooks test_index test_inspect test_ioctl test_ioctl skipped -- Unable to open /dev/tty test_isinstance test_iter test_iterlen test_itertools test_largefile test_linuxaudiodev test_linuxaudiodev skipped -- Use of the `audio' resource not enabled test_list test_locale test_logging test_long test_long_future test_longexp test_macostools test_macostools skipped -- No module named macostools test_macpath test_mailbox test_marshal test_math test_md5 test_mhlib test_mimetools test_mimetypes test_minidom test_mmap test_module test_modulefinder test_multibytecodec test_multibytecodec_support test_multifile test_mutants test_netrc test_new test_nis test_normalization test_normalization skipped -- Use of the `urlfetch' resource not enabled test_ntpath test_old_mailbox test_openpty test_operator test_optparse test_os test_ossaudiodev test_ossaudiodev skipped -- Use of the `audio' resource not enabled test_parser test_peepholer test_pep247 test_pep263 test_pep277 test_pep277 skipped -- test works only on NT+ test_pep292 test_pep352 test_pickle test_pickletools test_pipes test_pkg test_pkgimport test_platform test_plistlib test_plistlib skipped -- No module named plistlib test_poll test_popen [8896 refs] [8896 refs] [8896 refs] test_popen2 test_poplib test_posix test_posixpath test_pow test_pprint test_profile test_profilehooks test_property test_pty test_pwd test_pyclbr test_pyexpat test_queue test_quopri [9265 refs] [9265 refs] test_random test_rational test_re test_repr test_resource test_rfc822 test_richcmp test_robotparser test_runpy test_sax test_scope test_scriptpackages test_scriptpackages skipped -- No module named aetools test_select test_set test_sets test_sgmllib test_sha test_shelve test_shlex test_shutil test_signal test_site test_slice test_smtplib test_socket test_socket_ssl /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:94: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ssl_sock = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:130: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:144: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) test_socketserver test_socketserver skipped -- Use of the `network' resource not enabled test_softspace test_sort test_sqlite test_ssl test_startfile test_startfile skipped -- cannot import name startfile test_str test_strftime test_string test_stringprep test_strop test_strptime test_struct test_structmembers test_structseq test_subprocess [8891 refs] [8894 refs] [8891 refs] [8891 refs] [8891 refs] [8891 refs] [8891 refs] [8891 refs] [8891 refs] [8893 refs] [8894 refs] [10445 refs] [9109 refs] [8894 refs] [8891 refs] [8891 refs] [8891 refs] [8891 refs] [8891 refs] . [8891 refs] [8891 refs] this bit of output is from a test of stdout in a different process ... [8891 refs] [8891 refs] [9109 refs] test_sunaudiodev test_sunaudiodev skipped -- No module named sunaudiodev test_sundry test_symtable test_syntax test_sys [8891 refs] [8891 refs] test_tarfile test_tcl test_tcl skipped -- No module named _tkinter test_telnetlib test_tempfile [8897 refs] test_textwrap test_thread test_threaded_import test_threadedtempfile test_threading [13139 refs] test_threading_local test_threadsignals test_time test_timeout test_timeout skipped -- Use of the `network' resource not enabled test_tokenize test_trace test_traceback test_transformer test_tuple test_typechecks test_ucn test_unary test_unicode test_unicode_file test_unicode_file skipped -- No Unicode filesystem semantics on this platform. test_unicodedata test_univnewlines test_unpack test_urllib test_urllib2 test_urllib2_localnet test_urllib2net test_urllib2net skipped -- Use of the `network' resource not enabled test_urllibnet test_urllibnet skipped -- Use of the `network' resource not enabled test_urlparse test_userdict test_userlist test_userstring test_uu test_uuid WARNING: uuid.getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._ifconfig_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._unixdll_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. test_wait3 test_wait4 test_warnings test_wave test_weakref test_whichdb test_winreg test_winreg skipped -- No module named _winreg test_winsound test_winsound skipped -- No module named winsound test_with test_wsgiref test_xdrlib test_xml_etree test_xml_etree_c test_xmllib test_xmlrpc test_xpickle test_xrange test_zipfile test_zipfile64 test_zipfile64 skipped -- test requires loads of disk-space bytes and a long time to run test_zipimport test_zlib 302 tests OK. 1 test failed: test_ftplib 35 tests skipped: test_aepack test_al test_applesingle test_bsddb185 test_bsddb3 test_cd test_cl test_codecmaps_cn test_codecmaps_hk test_codecmaps_jp test_codecmaps_kr test_codecmaps_tw test_curses test_gl test_imageop test_imgfile test_ioctl test_linuxaudiodev test_macostools test_normalization test_ossaudiodev test_pep277 test_plistlib test_scriptpackages test_socketserver test_startfile test_sunaudiodev test_tcl test_timeout test_unicode_file test_urllib2net test_urllibnet test_winreg test_winsound test_zipfile64 1 skip unexpected on linux2: test_ioctl [529659 refs] From buildbot at python.org Wed Jan 16 21:57:06 2008 From: buildbot at python.org (buildbot at python.org) Date: Wed, 16 Jan 2008 20:57:06 +0000 Subject: [Python-checkins] buildbot failure in hppa Ubuntu trunk Message-ID: <20080116205706.C231B1E4003@bag.python.org> The Buildbot has detected a new failure of hppa Ubuntu trunk. Full details are available at: http://www.python.org/dev/buildbot/all/hppa%20Ubuntu%20trunk/builds/525 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-ubuntu-hppa Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: andrew.kuchling,georg.brandl,thomas.heller BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_timeout make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Wed Jan 16 22:18:38 2008 From: buildbot at python.org (buildbot at python.org) Date: Wed, 16 Jan 2008 21:18:38 +0000 Subject: [Python-checkins] buildbot failure in x86 gentoo trunk Message-ID: <20080116211838.B3EA31E4003@bag.python.org> The Buildbot has detected a new failure of x86 gentoo trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20gentoo%20trunk/builds/2899 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-x86 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: thomas.heller BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30996, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Traceback (most recent call last): File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30996, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Traceback (most recent call last): File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30996, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Traceback (most recent call last): File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30996, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Traceback (most recent call last): File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30996, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') sincerely, -The Buildbot From ncoghlan at gmail.com Wed Jan 16 23:02:57 2008 From: ncoghlan at gmail.com (Nick Coghlan) Date: Thu, 17 Jan 2008 08:02:57 +1000 Subject: [Python-checkins] r59993 - python/trunk/Doc/whatsnew/2.6.rst In-Reply-To: <20080116031726.50B1A1E4010@bag.python.org> References: <20080116031726.50B1A1E4010@bag.python.org> Message-ID: <478E7F11.3010701@gmail.com> andrew.kuchling wrote: > +The PEP slightly redefines the existing built-ins :func:`math.floor`, > +:func:`math.ceil`, :func:`round`, and adds a new one, :func:`trunc`. All of them > +take a :class:`Real` value and return an :class:`Integral`. While that's true of the Py3k version, I don't think it got backported that way - I'm pretty sure the 2.6 version leaves the return types of these functions unchanged. Cheers, Nick. -- Nick Coghlan | ncoghlan at gmail.com | Brisbane, Australia --------------------------------------------------------------- http://www.boredomandlaziness.org From nnorwitz at gmail.com Wed Jan 16 23:38:50 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Wed, 16 Jan 2008 17:38:50 -0500 Subject: [Python-checkins] Python Regression Test Failures refleak (8) Message-ID: <20080116223850.GA13665@python.psfb.org> test_opcodes leaked [-2, 0, 2] references, sum=0 test_doctest leaked [0, 0, -4] references, sum=-4 test_descrtut leaked [-2, 0, 0] references, sum=-2 test_difflib leaked [0, -2, 0] references, sum=-2 test_gc leaked [0, 4, -2] references, sum=2 test_genexps leaked [0, 0, -2] references, sum=-2 test_importhooks leaked [6, -4, 6] references, sum=8 test_os leaked [0, 0, -2] references, sum=-2 test_parser leaked [-2, 0, 0] references, sum=-2 test_popen2 leaked [-23, -26, 52] references, sum=3 test_sqlite leaked [0, -2, 2] references, sum=0 test_urllib2_localnet leaked [3, 3, 3] references, sum=9 From nnorwitz at gmail.com Thu Jan 17 00:01:25 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Wed, 16 Jan 2008 18:01:25 -0500 Subject: [Python-checkins] Python Regression Test Failures doc (1) Message-ID: <20080116230125.GA15680@python.psfb.org> svn update tools/sphinx U tools/sphinx/_jinja.py U tools/sphinx/__init__.py U tools/sphinx/htmlwriter.py U tools/sphinx/directives.py U tools/sphinx/environment.py U tools/sphinx/search.py U tools/sphinx/highlighting.py D tools/sphinx/templates/versionchanges.html D tools/sphinx/templates/inlinecomments.html D tools/sphinx/templates/edit.html D tools/sphinx/templates/comments.html D tools/sphinx/templates/admin D tools/sphinx/templates/_commentform.html D tools/sphinx/templates/commentform.html D tools/sphinx/templates/rstsource.html D tools/sphinx/templates/not_found.html D tools/sphinx/templates/keyword_not_found.html D tools/sphinx/templates/settings.html D tools/sphinx/templates/show_source.html D tools/sphinx/templates/submitted.html D tools/sphinx/templates/versionchanges_frameset.html D tools/sphinx/templates/download.html D tools/sphinx/templates/sidebar.html U tools/sphinx/templates/layout.html A tools/sphinx/templates/changes A tools/sphinx/templates/changes/versionchanges.html A tools/sphinx/templates/changes/frameset.html A tools/sphinx/templates/changes/rstsource.html U tools/sphinx/templates/search.html U tools/sphinx/templates/index.html A tools/sphinx/templates/web A tools/sphinx/templates/web/keyword_not_found.html A tools/sphinx/templates/web/settings.html A tools/sphinx/templates/web/submitted.html A tools/sphinx/templates/web/inlinecomments.html A tools/sphinx/templates/web/_commentform.html A tools/sphinx/templates/web/admin A tools/sphinx/templates/web/admin/layout.html A tools/sphinx/templates/web/admin/moderate_comments.html A tools/sphinx/templates/web/admin/change_password.html A tools/sphinx/templates/web/admin/index.html A tools/sphinx/templates/web/admin/login.html A tools/sphinx/templates/web/admin/manage_users.html A tools/sphinx/templates/web/comments.html A tools/sphinx/templates/web/edit.html A tools/sphinx/templates/web/commentform.html A tools/sphinx/templates/web/not_found.html U tools/sphinx/style/stickysidebar.css U tools/sphinx/style/rightsidebar.css U tools/sphinx/style/searchtools.js U tools/sphinx/style/traditional.css U tools/sphinx/style/default.css U tools/sphinx/latexwriter.py U tools/sphinx/htmlhelp.py U tools/sphinx/addnodes.py U tools/sphinx/refcounting.py U tools/sphinx/roles.py U tools/sphinx/builder.py U tools/sphinx/util/stemmer.py U tools/sphinx/util/__init__.py U tools/sphinx/web/admin.py U tools/sphinx/web/antispam.py U tools/sphinx/web/util.py U tools/sphinx/web/markup.py U tools/sphinx/web/application.py U tools/sphinx/web/webconf.py U tools/sphinx/web/database.py U tools/sphinx/web/oldurls.py U tools/sphinx/web/serve.py U tools/sphinx/web/userdb.py U tools/sphinx/web/wsgiutil.py U tools/sphinx/patchlevel.py Fetching external item into 'tools/sphinx/jinja' Updated external to revision 60008. Updated to revision 60008. svn update tools/docutils At revision 60008. svn update tools/pygments At revision 60008. mkdir -p build/html build/doctrees python tools/sphinx-build.py -b html -d build/doctrees -D latex_paper_size= . build/html trying to load pickled env... done building [html]: targets for 2 source files that are out of date reading, updating environment: [config changed] 395 added, 0 changed, 0 removed about.rst bugs.rst contents.rst copyright.rst glossary.rst license.rst c-api/abstract.rst c-api/concrete.rst c-api/exceptions.rst c-api/index.rst c-api/init.rst c-api/intro.rst c-api/memory.rst c-api/newtypes.rst c-api/refcounting.rst c-api/utilities.rst c-api/veryhigh.rst distutils/apiref.rst distutils/builtdist.rst distutils/commandref.rst distutils/configfile.rst distutils/examples.rst distutils/extending.rst distutils/index.rst distutils/introduction.rst distutils/packageindex.rst distutils/setupscript.rst distutils/sourcedist.rst distutils/uploading.rst documenting/fromlatex.rst documenting/index.rst documenting/intro.rst documenting/markup.rst documenting/rest.rst documenting/sphinx.rst documenting/style.rst extending/building.rst extending/embedding.rst extending/extending.rst extending/index.rst extending/newtypes.rst extending/windows.rst howto/advocacy.rst howto/curses.rst howto/doanddont.rst howto/functional.rst howto/index.rst howto/regex.rst howto/sockets.rst howto/unicode.rst howto/urllib2.rst install/index.rst library/__builtin__.rst library/__future__.rst library/__main__.rst library/_ast.rst library/_winreg.rst library/aepack.rst library/aetools.rst library/aetypes.rst library/aifc.rst library/al.rst library/allos.rst library/anydbm.rst library/archiving.rst library/array.rst library/asynchat.rst library/asyncore.rst library/atexit.rst library/audioop.rst library/autogil.rst library/base64.rst library/basehttpserver.rst library/bastion.rst library/bdb.rst library/binascii.rst library/binhex.rst library/bisect.rst library/bsddb.rst library/bz2.rst library/calendar.rst library/carbon.rst library/cd.rst library/cgi.rst library/cgihttpserver.rst library/cgitb.rst library/chunk.rst library/cmath.rst library/cmd.rst library/code.rst library/codecs.rst library/codeop.rst library/collections.rst library/colorpicker.rst library/colorsys.rst library/commands.rst library/compileall.rst library/compiler.rst library/configparser.rst library/constants.rst library/contextlib.rst library/cookie.rst library/cookielib.rst library/copy.rst library/copy_reg.rst library/crypt.rst library/crypto.rst library/csv.rst library/ctypes.rst library/curses.ascii.rst library/curses.panel.rst library/curses.rst library/custominterp.rst library/datatypes.rst library/datetime.rst library/dbhash.rst library/dbm.rst library/debug.rst library/decimal.rst library/development.rst library/difflib.rst library/dircache.rst library/dis.rst library/distutils.rst library/dl.rst library/doctest.rst library/docxmlrpcserver.rst library/dumbdbm.rst library/dummy_thread.rst library/dummy_threading.rst library/easydialogs.rst library/email-examples.rst library/email.charset.rst library/email.encoders.rst library/email.errors.rst library/email.generator.rst library/email.header.rst library/email.iterators.rst library/email.message.rst library/email.mime.rst library/email.parser.rst library/email.rst library/email.util.rst library/errno.rst library/exceptions.rst library/fcntl.rst library/filecmp.rst library/fileformats.rst library/fileinput.rst library/filesys.rst library/fl.rst library/fm.rst library/fnmatch.rst library/formatter.rst library/fpectl.rst library/fpformat.rst library/framework.rst library/frameworks.rst library/ftplib.rst library/functions.rst library/functools.rst library/gc.rst library/gdbm.rst library/gensuitemodule.rst library/getopt.rst library/getpass.rst library/gettext.rst library/gl.rst library/glob.rst library/grp.rst library/gzip.rst library/hashlib.rst library/heapq.rst library/hmac.rst library/hotshot.rst library/htmllib.rst library/htmlparser.rst library/httplib.rst library/i18n.rst library/ic.rst library/idle.rst library/imageop.rst library/imaplib.rst library/imgfile.rst library/imghdr.rst library/imp.rst library/imputil.rst library/index.rst library/inspect.rst library/internet.rst library/intro.rst library/ipc.rst library/itertools.rst library/jpeg.rst library/keyword.rst library/language.rst library/linecache.rst library/locale.rst library/logging.rst library/mac.rst library/macos.rst library/macosa.rst library/macostools.rst library/macpath.rst library/mailbox.rst library/mailcap.rst library/markup.rst library/marshal.rst library/math.rst library/md5.rst library/mhlib.rst library/mimetools.rst library/mimetypes.rst library/mimewriter.rst library/mimify.rst library/miniaeframe.rst library/misc.rst library/mm.rst library/mmap.rst library/modulefinder.rst library/modules.rst library/msilib.rst library/msvcrt.rst library/multifile.rst library/mutex.rst library/netdata.rst library/netrc.rst library/new.rst library/nis.rst library/nntplib.rst library/numbers.rst library/numeric.rst library/objects.rst library/operator.rst library/optparse.rst library/os.path.rst library/os.rst library/ossaudiodev.rst library/othergui.rst library/parser.rst library/pdb.rst library/persistence.rst library/pickle.rst library/pickletools.rst library/pipes.rst library/pkgutil.rst library/platform.rst library/popen2.rst library/poplib.rst library/posix.rst library/posixfile.rst library/pprint.rst library/profile.rst library/pty.rst library/pwd.rst library/py_compile.rst library/pyclbr.rst library/pydoc.rst library/pyexpat.rst library/python.rst library/queue.rst library/quopri.rst library/random.rst library/rational.rst library/re.rst library/readline.rst library/repr.rst library/resource.rst library/restricted.rst library/rexec.rst library/rfc822.rst library/rlcompleter.rst library/robotparser.rst library/runpy.rst library/sched.rst library/scrolledtext.rst library/select.rst library/sets.rst library/sgi.rst library/sgmllib.rst library/sha.rst library/shelve.rst library/shlex.rst library/shutil.rst library/signal.rst library/simplehttpserver.rst library/simplexmlrpcserver.rst library/site.rst library/smtpd.rst library/smtplib.rst library/sndhdr.rst library/socket.rst library/socketserver.rst library/someos.rst library/spwd.rst library/sqlite3.rst library/ssl.rst library/stat.rst library/statvfs.rst library/stdtypes.rst library/string.rst library/stringio.rst library/stringprep.rst library/strings.rst library/struct.rst library/subprocess.rst library/sun.rst library/sunau.rst library/sunaudio.rst library/symbol.rst library/sys.rst library/syslog.rst library/tabnanny.rst library/tarfile.rst library/telnetlib.rst library/tempfile.rst library/termios.rst library/test.rst library/textwrap.rst library/thread.rst library/threading.rst library/time.rst library/timeit.rst library/tix.rst library/tk.rst library/tkinter.rst library/token.rst library/tokenize.rst library/trace.rst library/traceback.rst library/tty.rst library/turtle.rst library/types.rst library/undoc.rst library/unicodedata.rst library/unittest.rst library/unix.rst library/urllib.rst library/urllib2.rst library/urlparse.rst library/user.rst library/userdict.rst library/uu.rst library/uuid.rst library/warnings.rst library/wave.rst library/weakref.rst library/webbrowser.rst library/whichdb.rst library/windows.rst library/winsound.rst library/wsgiref.rst library/xdrlib.rst library/xml.dom.minidom.rst library/xml.dom.pulldom.rst library/xml.dom.rst library/xml.etree.elementtree.rst library/xml.sax.handler.rst library/xml.sax.reader.rst library/xml.sax.rst library/xml.sax.utils.rst library/xmlrpclib.rst library/zipfile.rst library/zipimport.rst library/zlib.rst reference/compound_stmts.rst reference/datamodel.rst reference/executionmodel.rst reference/expressions.rst reference/index.rst reference/introduction.rst reference/lexical_analysis.rst reference/simple_stmts.rst reference/toplevel_components.rst tutorial/appetite.rst tutorial/classes.rst tutorial/controlflow.rst tutorial/datastructures.rst tutorial/errors.rst tutorial/floatingpoint.rst tutorial/index.rst tutorial/inputoutput.rst tutorial/interactive.rst tutorial/interpreter.rst tutorial/introduction.rst tutorial/modules.rst tutorial/stdlib.rst tutorial/stdlib2.rst tutorial/whatnow.rst using/cmdline.rst using/index.rst using/mac.rst using/unix.rst using/windows.rst whatsnew/2.6.rst pickling the env... done checking consistency... creating index... Traceback (most recent call last): File "tools/sphinx-build.py", line 24, in sys.exit(main(sys.argv)) File "/home/neal/python/trunk/Doc/tools/sphinx/__init__.py", line 125, in main builderobj.build_update() File "/home/neal/python/trunk/Doc/tools/sphinx/builder.py", line 187, in build_update 'out of date' % len(to_build)) File "/home/neal/python/trunk/Doc/tools/sphinx/builder.py", line 223, in build self.write(filenames, updated_filenames) File "/home/neal/python/trunk/Doc/tools/sphinx/builder.py", line 243, in write self.prepare_writing(filenames) File "/home/neal/python/trunk/Doc/tools/sphinx/builder.py", line 312, in prepare_writing self.load_indexer(filenames) File "/home/neal/python/trunk/Doc/tools/sphinx/builder.py", line 499, in load_indexer self.indexer.load(f, 'json') File "/home/neal/python/trunk/Doc/tools/sphinx/search.py", line 70, in load for (k, v) in frozen[2].iteritems()) AttributeError: 'list' object has no attribute 'iteritems' make: *** [build] Error 1 From buildbot at python.org Thu Jan 17 00:29:35 2008 From: buildbot at python.org (buildbot at python.org) Date: Wed, 16 Jan 2008 23:29:35 +0000 Subject: [Python-checkins] buildbot failure in x86 FreeBSD trunk Message-ID: <20080116232935.A0EB11E402B@bag.python.org> The Buildbot has detected a new failure of x86 FreeBSD trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20FreeBSD%20trunk/builds/407 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-freebsd Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: georg.brandl,thomas.heller BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_smtplib sincerely, -The Buildbot From buildbot at python.org Thu Jan 17 00:32:40 2008 From: buildbot at python.org (buildbot at python.org) Date: Wed, 16 Jan 2008 23:32:40 +0000 Subject: [Python-checkins] buildbot failure in ARM Linux EABI 2.5 Message-ID: <20080116233240.B9FF41E400A@bag.python.org> The Buildbot has detected a new failure of ARM Linux EABI 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/ARM%20Linux%20EABI%202.5/builds/2 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-linux-armeabi Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: georg.brandl,thomas.heller BUILD FAILED: failed failed slave lost sincerely, -The Buildbot From python-checkins at python.org Thu Jan 17 00:38:16 2008 From: python-checkins at python.org (raymond.hettinger) Date: Thu, 17 Jan 2008 00:38:16 +0100 (CET) Subject: [Python-checkins] r60009 - python/trunk/Doc/library/collections.rst python/trunk/Doc/library/queue.rst Message-ID: <20080116233816.81F241E400A@bag.python.org> Author: raymond.hettinger Date: Thu Jan 17 00:38:16 2008 New Revision: 60009 Modified: python/trunk/Doc/library/collections.rst python/trunk/Doc/library/queue.rst Log: Minor wordsmithing. Modified: python/trunk/Doc/library/collections.rst ============================================================================== --- python/trunk/Doc/library/collections.rst (original) +++ python/trunk/Doc/library/collections.rst Thu Jan 17 00:38:16 2008 @@ -536,8 +536,7 @@ return self._make(_map(kwds.get, ('x', 'y'), self)) The subclasses shown above set ``__slots__`` to an empty tuple. This keeps -the named tuples from having per-instance dictionaries, so they will -continue to be lightweight and require no more memory than regular tuples. +keep memory requirements low by preventing the creation of instance dictionaries. Subclassing is not useful for adding new, stored fields. Instead, simply create a new named tuple type from the :attr:`_fields` attribute:: Modified: python/trunk/Doc/library/queue.rst ============================================================================== --- python/trunk/Doc/library/queue.rst (original) +++ python/trunk/Doc/library/queue.rst Thu Jan 17 00:38:16 2008 @@ -6,23 +6,46 @@ :synopsis: A synchronized queue class. -The :mod:`Queue` module implements a multi-producer, multi-consumer FIFO queue. +The :mod:`Queue` module implements multi-producer, multi-consumer queues. It is especially useful in threaded programming when information must be exchanged safely between multiple threads. The :class:`Queue` class in this module implements all the required locking semantics. It depends on the availability of thread support in Python; see the :mod:`threading` module. -The :mod:`Queue` module defines the following class and exception: +Implements three types of queue whose only difference is the order that +the entries are retrieved. In a FIFO queue, the first tasks added are +the first retrieved. In a LIFO queue, the most recently added entry is +the first retrieved (operating like a stack). With a priority queue, +the entries are kept sorted (using the :mod:`heapq` module) and the +lowest valued entry is retrieved first. +The :mod:`Queue` module defines the following classes and exceptions: .. class:: Queue(maxsize) - Constructor for the class. *maxsize* is an integer that sets the upperbound + Constructor for a FIFO queue. *maxsize* is an integer that sets the upperbound limit on the number of items that can be placed in the queue. Insertion will block once this size has been reached, until queue items are consumed. If *maxsize* is less than or equal to zero, the queue size is infinite. +.. class:: LifoQueue(maxsize) + + Constructor for a LIFO queue. *maxsize* is an integer that sets the upperbound + limit on the number of items that can be placed in the queue. Insertion will + block once this size has been reached, until queue items are consumed. If + *maxsize* is less than or equal to zero, the queue size is infinite. + +.. class:: PriorityQueue(maxsize) + + Constructor for a priority queue. *maxsize* is an integer that sets the upperbound + limit on the number of items that can be placed in the queue. Insertion will + block once this size has been reached, until queue items are consumed. If + *maxsize* is less than or equal to zero, the queue size is infinite. + + The lowest valued entries are retrieved first (the lowest valued entry is the + one returned by ``sorted(list(entries))[0]``). A typical pattern for entries + is a tuple in the form: ``(priority_number, data)``. .. exception:: Empty @@ -41,10 +64,8 @@ Queue Objects ------------- -Class :class:`Queue` implements queue objects and has the methods described -below. This class can be derived from in order to implement other queue -organizations (e.g. stack) but the inheritable interface is not described here. -See the source code for details. The public methods are: +Queue objects (:class:``Queue``, :class:``LifoQueue``, or :class:``PriorityQueue`` +provide the public methods described below. .. method:: Queue.qsize() From python-checkins at python.org Thu Jan 17 00:40:45 2008 From: python-checkins at python.org (raymond.hettinger) Date: Thu, 17 Jan 2008 00:40:45 +0100 (CET) Subject: [Python-checkins] r60010 - in python/trunk/Lib: Queue.py test/test_queue.py Message-ID: <20080116234045.9E0F01E400A@bag.python.org> Author: raymond.hettinger Date: Thu Jan 17 00:40:45 2008 New Revision: 60010 Modified: python/trunk/Lib/Queue.py python/trunk/Lib/test/test_queue.py Log: Add queues will alternative fetch orders (priority based and stack based). Modified: python/trunk/Lib/Queue.py ============================================================================== --- python/trunk/Lib/Queue.py (original) +++ python/trunk/Lib/Queue.py Thu Jan 17 00:40:45 2008 @@ -2,8 +2,9 @@ from time import time as _time from collections import deque +import heapq -__all__ = ['Empty', 'Full', 'Queue'] +__all__ = ['Empty', 'Full', 'Queue', 'PriorityQueue', 'LifoQueue'] class Empty(Exception): "Exception raised by Queue.get(block=0)/get_nowait()." @@ -196,7 +197,7 @@ def _init(self, maxsize): self.queue = deque() - def _qsize(self): + def _qsize(self, len=len): return len(self.queue) # Put a new item in the queue @@ -206,3 +207,38 @@ # Get an item from the queue def _get(self): return self.queue.popleft() + + +class PriorityQueue(Queue): + '''Variant of Queue that retrieves open entries in priority order (lowest first). + + Entries are typically tuples of the form: (priority number, data). + ''' + + def _init(self, maxsize): + self.queue = [] + + def _qsize(self, len=len): + return len(self.queue) + + def _put(self, item, heappush=heapq.heappush): + heappush(self.queue, item) + + def _get(self, heappop=heapq.heappop): + return heappop(self.queue) + + +class LifoQueue(Queue): + '''Variant of Queue that retrieves most recently added entries first.''' + + def _init(self, maxsize): + self.queue = [] + + def _qsize(self, len=len): + return len(self.queue) + + def _put(self, item): + self.queue.append(item) + + def _get(self): + return self.queue.pop() Modified: python/trunk/Lib/test/test_queue.py ============================================================================== --- python/trunk/Lib/test/test_queue.py (original) +++ python/trunk/Lib/test/test_queue.py Thu Jan 17 00:40:45 2008 @@ -181,8 +181,13 @@ raise RuntimeError, "Call this function with an empty queue" # I guess we better check things actually queue correctly a little :) q.put(111) + q.put(333) q.put(222) - verify(q.get() == 111 and q.get() == 222, + target_order = dict(Queue = [111, 333, 222], + LifoQueue = [222, 333, 111], + PriorityQueue = [111, 222, 333]) + actual_order = [q.get(), q.get(), q.get()] + verify(actual_order == target_order[q.__class__.__name__], "Didn't seem to queue the correct data!") for i in range(QUEUE_SIZE-1): q.put(i) @@ -260,18 +265,20 @@ raise TestFailed("Did not detect task count going negative") def test(): - q = Queue.Queue() - QueueTaskDoneTest(q) - QueueJoinTest(q) - QueueJoinTest(q) - QueueTaskDoneTest(q) - - q = Queue.Queue(QUEUE_SIZE) - # Do it a couple of times on the same queue - SimpleQueueTest(q) - SimpleQueueTest(q) - if verbose: - print "Simple Queue tests seemed to work" + for Q in Queue.Queue, Queue.LifoQueue, Queue.PriorityQueue: + q = Q() + QueueTaskDoneTest(q) + QueueJoinTest(q) + QueueJoinTest(q) + QueueTaskDoneTest(q) + + q = Q(QUEUE_SIZE) + # Do it a couple of times on the same queue + SimpleQueueTest(q) + SimpleQueueTest(q) + if verbose: + print "Simple Queue tests seemed to work for", Q.__name__ + q = FailingQueue(QUEUE_SIZE) FailingQueueTest(q) FailingQueueTest(q) From python-checkins at python.org Thu Jan 17 00:49:35 2008 From: python-checkins at python.org (raymond.hettinger) Date: Thu, 17 Jan 2008 00:49:35 +0100 (CET) Subject: [Python-checkins] r60011 - python/trunk/Misc/NEWS Message-ID: <20080116234935.A91411E400A@bag.python.org> Author: raymond.hettinger Date: Thu Jan 17 00:49:35 2008 New Revision: 60011 Modified: python/trunk/Misc/NEWS Log: Add news entry. Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Thu Jan 17 00:49:35 2008 @@ -364,6 +364,8 @@ Library ------- +- #1837: The queue module now also supports a LIFO queue and a priority queue. + - Issue #1831: ctypes now raises a TypeError if conflicting positional and named arguments are passed to a Structure or Union initializer. When too many positional arguments are passed, also a TypeError is From buildbot at python.org Thu Jan 17 01:33:12 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 17 Jan 2008 00:33:12 +0000 Subject: [Python-checkins] buildbot failure in sparc solaris10 gcc trunk Message-ID: <20080117003312.6F2BF1E400A@bag.python.org> The Buildbot has detected a new failure of sparc solaris10 gcc trunk. Full details are available at: http://www.python.org/dev/buildbot/all/sparc%20solaris10%20gcc%20trunk/builds/2622 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-sun Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_urllib2net sincerely, -The Buildbot From python-checkins at python.org Thu Jan 17 04:02:15 2008 From: python-checkins at python.org (raymond.hettinger) Date: Thu, 17 Jan 2008 04:02:15 +0100 (CET) Subject: [Python-checkins] r60013 - in python/trunk: Doc/library/itertools.rst Lib/test/test_itertools.py Misc/NEWS Modules/itertoolsmodule.c Message-ID: <20080117030215.1AD681E400A@bag.python.org> Author: raymond.hettinger Date: Thu Jan 17 04:02:14 2008 New Revision: 60013 Modified: python/trunk/Doc/library/itertools.rst python/trunk/Lib/test/test_itertools.py python/trunk/Misc/NEWS python/trunk/Modules/itertoolsmodule.c Log: Make starmap() match its pure python definition and accept any itertable input (not just tuples). Modified: python/trunk/Doc/library/itertools.rst ============================================================================== --- python/trunk/Doc/library/itertools.rst (original) +++ python/trunk/Doc/library/itertools.rst Thu Jan 17 04:02:14 2008 @@ -330,17 +330,19 @@ .. function:: starmap(function, iterable) - Make an iterator that computes the function using arguments tuples obtained from + Make an iterator that computes the function using arguments obtained from the iterable. Used instead of :func:`imap` when argument parameters are already grouped in tuples from a single iterable (the data has been "pre-zipped"). The difference between :func:`imap` and :func:`starmap` parallels the distinction between ``function(a,b)`` and ``function(*c)``. Equivalent to:: def starmap(function, iterable): - iterable = iter(iterable) - while True: - yield function(*iterable.next()) + for args in iterable: + yield function(*args) + .. versionchanged:: 2.6 + Previously, :func:`starmap` required the function arguments to be tuples. + Now, any iterable is allowed. .. function:: takewhile(predicate, iterable) Modified: python/trunk/Lib/test/test_itertools.py ============================================================================== --- python/trunk/Lib/test/test_itertools.py (original) +++ python/trunk/Lib/test/test_itertools.py Thu Jan 17 04:02:14 2008 @@ -292,7 +292,8 @@ self.assertEqual(take(3, starmap(operator.pow, izip(count(), count(1)))), [0**1, 1**2, 2**3]) self.assertEqual(list(starmap(operator.pow, [])), []) - self.assertRaises(TypeError, list, starmap(operator.pow, [[4,5]])) + self.assertEqual(list(starmap(operator.pow, [iter([4,5])])), [4**5]) + self.assertRaises(TypeError, list, starmap(operator.pow, [None])) self.assertRaises(TypeError, starmap) self.assertRaises(TypeError, starmap, operator.pow, [(4,5)], 'extra') self.assertRaises(TypeError, starmap(10, [(4,5)]).next) Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Thu Jan 17 04:02:14 2008 @@ -993,6 +993,9 @@ the context manager protocol. The _winreg module also gained a new function ``ExpandEnvironmentStrings`` to expand REG_EXPAND_SZ keys. +- itertools.starmap() now accepts any iterable input. Previously, it required + the function inputs to be tuples. + - Issue #1646: Make socket support TIPC. The socket module now has support for TIPC under Linux, see http://tipc.sf.net/ for more information. Modified: python/trunk/Modules/itertoolsmodule.c ============================================================================== --- python/trunk/Modules/itertoolsmodule.c (original) +++ python/trunk/Modules/itertoolsmodule.c Thu Jan 17 04:02:14 2008 @@ -1356,10 +1356,11 @@ if (args == NULL) return NULL; if (!PyTuple_CheckExact(args)) { + PyObject *newargs = PySequence_Tuple(args); Py_DECREF(args); - PyErr_SetString(PyExc_TypeError, - "iterator must return a tuple"); - return NULL; + if (newargs == NULL) + return NULL; + args = newargs; } result = PyObject_Call(lz->func, args, NULL); Py_DECREF(args); From buildbot at python.org Thu Jan 17 04:25:41 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 17 Jan 2008 03:25:41 +0000 Subject: [Python-checkins] buildbot failure in ARM Linux EABI trunk Message-ID: <20080117032541.9E1331E400B@bag.python.org> The Buildbot has detected a new failure of ARM Linux EABI trunk. Full details are available at: http://www.python.org/dev/buildbot/all/ARM%20Linux%20EABI%20trunk/builds/10 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-linux-armeabi Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: sincerely, -The Buildbot From buildbot at python.org Thu Jan 17 05:27:10 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 17 Jan 2008 04:27:10 +0000 Subject: [Python-checkins] buildbot failure in x86 FreeBSD trunk Message-ID: <20080117042710.BAFA51E400B@bag.python.org> The Buildbot has detected a new failure of x86 FreeBSD trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20FreeBSD%20trunk/builds/409 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-freebsd Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 523, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable 2 tests failed: test_smtplib test_xmlrpc sincerely, -The Buildbot From python-checkins at python.org Thu Jan 17 08:43:21 2008 From: python-checkins at python.org (gregory.p.smith) Date: Thu, 17 Jan 2008 08:43:21 +0100 (CET) Subject: [Python-checkins] r60015 - in python/trunk: Doc/whatsnew/2.6.rst Lib/smtplib.py Message-ID: <20080117074321.4464E1E401E@bag.python.org> Author: gregory.p.smith Date: Thu Jan 17 08:43:20 2008 New Revision: 60015 Modified: python/trunk/Doc/whatsnew/2.6.rst python/trunk/Lib/smtplib.py Log: Comply with RFC 3207. Fixes issue 829951 - http://bugs.python.org/issue829951 Modified: python/trunk/Doc/whatsnew/2.6.rst ============================================================================== --- python/trunk/Doc/whatsnew/2.6.rst (original) +++ python/trunk/Doc/whatsnew/2.6.rst Thu Jan 17 08:43:20 2008 @@ -1091,6 +1091,12 @@ .. Patch #957003 +* In the :mod:`smtplib` module, SMTP.starttls() now complies with :rfc:`3207` + and forgets any knowledge obtained from the server not obtained from + the TLS negotiation itself. Patch contributed by Bill Fenner. + + .. Issue 829951 + * The :mod:`socket` module now supports TIPC (http://tipc.sf.net), a high-performance non-IP-based protocol designed for use in clustered environments. TIPC addresses are 4- or 5-tuples. Modified: python/trunk/Lib/smtplib.py ============================================================================== --- python/trunk/Lib/smtplib.py (original) +++ python/trunk/Lib/smtplib.py Thu Jan 17 08:43:20 2008 @@ -589,6 +589,14 @@ raise RuntimeError("No SSL support included in this Python") self.sock = ssl.wrap_socket(self.sock, keyfile, certfile) self.file = SSLFakeFile(self.sock) + # RFC 3207: + # The client MUST discard any knowledge obtained from + # the server, such as the list of SMTP service extensions, + # which was not obtained from the TLS negotiation itself. + self.helo_resp = None + self.ehlo_resp = None + self.esmtp_features = {} + self.does_esmtp = 0 return (resp, reply) def sendmail(self, from_addr, to_addrs, msg, mail_options=[], From python-checkins at python.org Thu Jan 17 08:54:47 2008 From: python-checkins at python.org (gregory.p.smith) Date: Thu, 17 Jan 2008 08:54:47 +0100 (CET) Subject: [Python-checkins] r60017 - in python/branches/release25-maint: Lib/smtplib.py Misc/NEWS Message-ID: <20080117075447.9A6381E401E@bag.python.org> Author: gregory.p.smith Date: Thu Jan 17 08:54:47 2008 New Revision: 60017 Modified: python/branches/release25-maint/Lib/smtplib.py python/branches/release25-maint/Misc/NEWS Log: ** backport r60015 from trunk. - Issue829951: In the smtplib module, SMTP.starttls() now complies with RFC 3207 and forgets any knowledge obtained from the server not obtained from the TLS negotiation itself. Patch contributed by Bill Fenner. Modified: python/branches/release25-maint/Lib/smtplib.py ============================================================================== --- python/branches/release25-maint/Lib/smtplib.py (original) +++ python/branches/release25-maint/Lib/smtplib.py Thu Jan 17 08:54:47 2008 @@ -605,6 +605,14 @@ sslobj = socket.ssl(self.sock, keyfile, certfile) self.sock = SSLFakeSocket(self.sock, sslobj) self.file = SSLFakeFile(sslobj) + # RFC 3207: + # The client MUST discard any knowledge obtained from + # the server, such as the list of SMTP service extensions, + # which was not obtained from the TLS negotiation itself. + self.helo_resp = None + self.ehlo_resp = None + self.esmtp_features = {} + self.does_esmtp = 0 return (resp, reply) def sendmail(self, from_addr, to_addrs, msg, mail_options=[], Modified: python/branches/release25-maint/Misc/NEWS ============================================================================== --- python/branches/release25-maint/Misc/NEWS (original) +++ python/branches/release25-maint/Misc/NEWS Thu Jan 17 08:54:47 2008 @@ -165,6 +165,10 @@ - Issue1385: The hmac module now computes the correct hmac when using hashes with a block size other than 64 bytes (such as sha384 and sha512). +- Issue829951: In the smtplib module, SMTP.starttls() now complies with + RFC 3207 and forgets any knowledge obtained from the server not obtained + from the TLS negotiation itself. Patch contributed by Bill Fenner. + Extension Modules ----------------- From python-checkins at python.org Thu Jan 17 09:03:17 2008 From: python-checkins at python.org (gregory.p.smith) Date: Thu, 17 Jan 2008 09:03:17 +0100 (CET) Subject: [Python-checkins] r60018 - python/trunk/Misc/NEWS Message-ID: <20080117080317.65F651E401E@bag.python.org> Author: gregory.p.smith Date: Thu Jan 17 09:03:17 2008 New Revision: 60018 Modified: python/trunk/Misc/NEWS Log: entry for r60015 Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Thu Jan 17 09:03:17 2008 @@ -986,6 +986,10 @@ - The implementation of UnicodeError objects has been simplified (start and end attributes are now stored directly as Py_ssize_t members). +- Issue829951: In the smtplib module, SMTP.starttls() now complies with + RFC 3207 and forgets any knowledge obtained from the server not obtained + from the TLS negotiation itself. Patch contributed by Bill Fenner. + Extension Modules ----------------- From python-checkins at python.org Thu Jan 17 09:07:05 2008 From: python-checkins at python.org (raymond.hettinger) Date: Thu, 17 Jan 2008 09:07:05 +0100 (CET) Subject: [Python-checkins] r60019 - python/trunk/Doc/library/queue.rst Message-ID: <20080117080705.830C11E401E@bag.python.org> Author: raymond.hettinger Date: Thu Jan 17 09:07:05 2008 New Revision: 60019 Modified: python/trunk/Doc/library/queue.rst Log: Note versionadded. Modified: python/trunk/Doc/library/queue.rst ============================================================================== --- python/trunk/Doc/library/queue.rst (original) +++ python/trunk/Doc/library/queue.rst Thu Jan 17 09:07:05 2008 @@ -36,6 +36,8 @@ block once this size has been reached, until queue items are consumed. If *maxsize* is less than or equal to zero, the queue size is infinite. + .. versionadded:: 2.6 + .. class:: PriorityQueue(maxsize) Constructor for a priority queue. *maxsize* is an integer that sets the upperbound @@ -47,6 +49,8 @@ one returned by ``sorted(list(entries))[0]``). A typical pattern for entries is a tuple in the form: ``(priority_number, data)``. + .. versionadded:: 2.6 + .. exception:: Empty Exception raised when non-blocking :meth:`get` (or :meth:`get_nowait`) is called From buildbot at python.org Thu Jan 17 09:34:52 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 17 Jan 2008 08:34:52 +0000 Subject: [Python-checkins] buildbot failure in ia64 Ubuntu 3.0 Message-ID: <20080117083452.A80E61E401E@bag.python.org> The Buildbot has detected a new failure of ia64 Ubuntu 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/ia64%20Ubuntu%203.0/builds/466 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ia64 Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: jeffrey.yasskin BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ia64/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/home/pybot/buildarea/3.0.klose-debian-ia64/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/home/pybot/buildarea/3.0.klose-debian-ia64/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/home/pybot/buildarea/3.0.klose-debian-ia64/build/Lib/SocketServer.py", line 522, in __init__ self.handle() File "/home/pybot/buildarea/3.0.klose-debian-ia64/build/Lib/BaseHTTPServer.py", line 330, in handle self.handle_one_request() File "/home/pybot/buildarea/3.0.klose-debian-ia64/build/Lib/BaseHTTPServer.py", line 324, in handle_one_request method() File "/home/pybot/buildarea/3.0.klose-debian-ia64/build/Lib/SimpleXMLRPCServer.py", line 430, in do_POST self.report_404() File "/home/pybot/buildarea/3.0.klose-debian-ia64/build/Lib/SimpleXMLRPCServer.py", line 489, in report_404 self.connection.shutdown(1) socket.error: [Errno 107] Transport endpoint is not connected 1 test failed: test_xmlrpc make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Thu Jan 17 09:35:50 2008 From: python-checkins at python.org (gregory.p.smith) Date: Thu, 17 Jan 2008 09:35:50 +0100 (CET) Subject: [Python-checkins] r60020 - in python/trunk: Doc/library/smtplib.rst Lib/smtplib.py Misc/NEWS Message-ID: <20080117083550.78FA61E402E@bag.python.org> Author: gregory.p.smith Date: Thu Jan 17 09:35:49 2008 New Revision: 60020 Modified: python/trunk/Doc/library/smtplib.rst python/trunk/Lib/smtplib.py python/trunk/Misc/NEWS Log: Fixes (accepts patch) issue1339 - http://bugs.python.org/issue1339 - Factor out the duplication of EHLO/HELO in login() and sendmail() to a new function, ehlo_or_helo_if_needed(). - Use ehlo_or_helo_if_needed() in starttls() - Check for the starttls exception in starttls() in the same way as login() checks for the auth extension. Contributed by Bill Fenner. Modified: python/trunk/Doc/library/smtplib.rst ============================================================================== --- python/trunk/Doc/library/smtplib.rst (original) +++ python/trunk/Doc/library/smtplib.rst Thu Jan 17 09:35:49 2008 @@ -191,6 +191,16 @@ necessary to call this method explicitly. It will be implicitly called by :meth:`sendmail` when necessary. +.. method:: SMTP.ehlo_or_helo_if_needed() + + This method call :meth:`ehlo` and or :meth:`helo` if there has been no + previous ``EHLO`` or ``HELO`` command this session. It tries ESMTP ``EHLO`` + first. + + :exc:SMTPHeloError + The server didn't reply properly to the ``HELO`` greeting. + + .. versionadded:: 2.6 .. method:: SMTP.has_extn(name) @@ -237,6 +247,22 @@ If *keyfile* and *certfile* are provided, these are passed to the :mod:`socket` module's :func:`ssl` function. + If there has been no previous ``EHLO`` or ``HELO`` command this session, + this method tries ESMTP ``EHLO`` first. + + .. versionchanged:: 2.6 + + :exc:`SMTPHeloError` + The server didn't reply properly to the ``HELO`` greeting. + + :exc:`SMTPException` + The server does not support the STARTTLS extension. + + .. versionchanged:: 2.6 + + :exc:`RuntimeError` + SSL/TLS support is not available to your python interpreter. + .. method:: SMTP.sendmail(from_addr, to_addrs, msg[, mail_options, rcpt_options]) Modified: python/trunk/Lib/smtplib.py ============================================================================== --- python/trunk/Lib/smtplib.py (original) +++ python/trunk/Lib/smtplib.py Thu Jan 17 09:35:49 2008 @@ -492,6 +492,23 @@ # some useful methods + def ehlo_or_helo_if_needed(self): + """Call self.ehlo() and/or self.helo() if needed. + + If there has been no previous EHLO or HELO command this session, this + method tries ESMTP EHLO first. + + This method may raise the following exceptions: + + SMTPHeloError The server didn't reply properly to + the helo greeting. + """ + if self.helo_resp is None and self.ehlo_resp is None: + if not (200 <= self.ehlo()[0] <= 299): + (code, resp) = self.helo() + if not (200 <= code <= 299): + raise SMTPHeloError(code, resp) + def login(self, user, password): """Log in on an SMTP server that requires authentication. @@ -527,11 +544,7 @@ AUTH_CRAM_MD5 = "CRAM-MD5" AUTH_LOGIN = "LOGIN" - if self.helo_resp is None and self.ehlo_resp is None: - if not (200 <= self.ehlo()[0] <= 299): - (code, resp) = self.helo() - if not (200 <= code <= 299): - raise SMTPHeloError(code, resp) + self.ehlo_or_helo_if_needed() if not self.has_extn("auth"): raise SMTPException("SMTP AUTH extension not supported by server.") @@ -577,12 +590,23 @@ def starttls(self, keyfile = None, certfile = None): """Puts the connection to the SMTP server into TLS mode. + If there has been no previous EHLO or HELO command this session, this + method tries ESMTP EHLO first. + If the server supports TLS, this will encrypt the rest of the SMTP session. If you provide the keyfile and certfile parameters, the identity of the SMTP server and client can be checked. This, however, depends on whether the socket module really checks the certificates. + + This method may raise the following exceptions: + + SMTPHeloError The server didn't reply properly to + the helo greeting. """ + self.ehlo_or_helo_if_needed() + if not self.has_extn("starttls"): + raise SMTPException("STARTTLS extension not supported by server.") (resp, reply) = self.docmd("STARTTLS") if resp == 220: if not _have_ssl: @@ -656,11 +680,7 @@ empty dictionary. """ - if self.helo_resp is None and self.ehlo_resp is None: - if not (200 <= self.ehlo()[0] <= 299): - (code,resp) = self.helo() - if not (200 <= code <= 299): - raise SMTPHeloError(code, resp) + self.ehlo_or_helo_if_needed() esmtp_opts = [] if self.does_esmtp: # Hmmm? what's this? -ddm Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Thu Jan 17 09:35:49 2008 @@ -990,6 +990,12 @@ RFC 3207 and forgets any knowledge obtained from the server not obtained from the TLS negotiation itself. Patch contributed by Bill Fenner. +- Issue1339: The smtplib.SMTP class has been refactored a bit such + that the SMTP.starttls() caller no longer needs to call ehlo() + beforehand. SMTP.starttls() now raises an exception of the server + does not claim to support starttls. Adds the SMTP.ehlo_or_helo_if_needed() + method. Patch contributed by Bill Fenner. + Extension Modules ----------------- From nnorwitz at gmail.com Thu Jan 17 10:10:12 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Thu, 17 Jan 2008 04:10:12 -0500 Subject: [Python-checkins] Python Regression Test Failures basics (1) Message-ID: <20080117091012.GA15969@python.psfb.org> test_grammar test_opcodes test_dict test_builtin test_exceptions test_types test_unittest test_doctest test_doctest2 test_MimeWriter test_StringIO test___all__ test___future__ test__locale test_abc test_abstract_numbers test_aepack test_aepack skipped -- No module named aepack test_al test_al skipped -- No module named al test_anydbm test_applesingle test_applesingle skipped -- No module named macostools test_array test_ast test_asynchat WARNING: failed to listen on port 54322, trying another WARNING: failed to listen on port 9907, trying another WARNING: failed to listen on port 10243, trying another test_asyncore test_atexit test_audioop test_augassign test_base64 test_bastion test_bigaddrspace test_bigmem test_binascii test_binhex test_binop test_bisect test_bool test_bsddb test_bsddb185 test_bsddb185 skipped -- No module named bsddb185 test_bsddb3 test_bsddb3 skipped -- Use of the `bsddb' resource not enabled test_buffer test_bufio test_bz2 test_cProfile test_calendar test_call test_capi test_cd test_cd skipped -- No module named cd test_cfgparser test_cgi test_charmapcodec test_cl test_cl skipped -- No module named cl test_class test_cmath test_cmd test_cmd_line test_cmd_line_script test_code test_codeccallbacks test_codecencodings_cn test_codecencodings_hk test_codecencodings_jp test_codecencodings_kr test_codecencodings_tw test_codecmaps_cn test_codecmaps_cn skipped -- Use of the `urlfetch' resource not enabled test_codecmaps_hk test_codecmaps_hk skipped -- Use of the `urlfetch' resource not enabled test_codecmaps_jp test_codecmaps_jp skipped -- Use of the `urlfetch' resource not enabled test_codecmaps_kr test_codecmaps_kr skipped -- Use of the `urlfetch' resource not enabled test_codecmaps_tw test_codecmaps_tw skipped -- Use of the `urlfetch' resource not enabled test_codecs test_codeop test_coding test_coercion test_collections test_colorsys test_commands test_compare test_compile test_compiler test_complex test_complex_args test_contains test_contextlib test_cookie test_cookielib test_copy test_copy_reg test_cpickle test_crypt test_csv test_ctypes test_curses test_curses skipped -- Use of the `curses' resource not enabled test_datetime test_dbm test_decimal test_decorators test_defaultdict test_deque test_descr test_descrtut test_difflib test_dircache test_dis test_distutils test_dl test_docxmlrpc test_dumbdbm test_dummy_thread test_dummy_threading test_email test_email_codecs test_email_renamed test_enumerate test_eof test_errno test_exception_variations test_extcall test_fcntl test_file test_filecmp test_fileinput test_float test_fnmatch test_fork1 test_format test_fpformat test_frozen test_ftplib test_funcattrs test_functools test_future test_gc test_gdbm test_generators test_genericpath test_genexps test_getargs test_getargs2 test_getopt test_gettext test_gl test_gl skipped -- No module named gl test_glob test_global test_grp test_gzip test_hash test_hashlib test_heapq test_hexoct test_hmac test_hotshot test_htmllib test_htmlparser test_httplib test_imageop test_imageop skipped -- No module named imgfile test_imaplib test_imgfile test_imgfile skipped -- No module named imgfile test_imp test_import test_importhooks test_index test_inspect test_ioctl test_ioctl skipped -- Unable to open /dev/tty test_isinstance test_iter test_iterlen test_itertools test_largefile test_linuxaudiodev test_linuxaudiodev skipped -- Use of the `audio' resource not enabled test_list test_locale test_logging test_long test_long_future test_longexp test_macostools test_macostools skipped -- No module named macostools test_macpath test_mailbox test_marshal test_math test_md5 test_mhlib test_mimetools test_mimetypes test_minidom test_mmap test_module test_modulefinder test_multibytecodec test_multibytecodec_support test_multifile test_mutants test_netrc test_new test_nis test_normalization test_normalization skipped -- Use of the `urlfetch' resource not enabled test_ntpath test_old_mailbox test_openpty test_operator test_optparse test_os test_ossaudiodev test_ossaudiodev skipped -- Use of the `audio' resource not enabled test_parser test_peepholer test_pep247 test_pep263 test_pep277 test_pep277 skipped -- test works only on NT+ test_pep292 test_pep352 test_pickle test_pickletools test_pipes test_pkg test_pkgimport test_platform test_plistlib test_plistlib skipped -- No module named plistlib test_poll test_popen [8896 refs] [8896 refs] [8896 refs] test_popen2 test_poplib test_posix test_posixpath test_pow test_pprint test_profile test_profilehooks test_property test_pty test_pwd test_pyclbr test_pyexpat test_queue test_quopri [9265 refs] [9265 refs] test_random test_rational test_re test_repr test_resource test_rfc822 test_richcmp test_robotparser test_runpy test_sax test_scope test_scriptpackages test_scriptpackages skipped -- No module named aetools test_select test_set test_sets test_sgmllib test_sha test_shelve test_shlex test_shutil test_signal test_site test_slice test_smtplib test_socket test_socket_ssl /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:94: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ssl_sock = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:130: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:144: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) test_socketserver test_socketserver skipped -- Use of the `network' resource not enabled test_softspace test_sort test_sqlite test_ssl test_startfile test_startfile skipped -- cannot import name startfile test_str test_strftime test_string test_stringprep test_strop test_strptime test_struct test_structmembers test_structseq test_subprocess [8891 refs] [8894 refs] [8891 refs] [8891 refs] [8891 refs] [8891 refs] [8891 refs] [8891 refs] [8891 refs] [8893 refs] [8894 refs] [10445 refs] [9109 refs] [8894 refs] [8891 refs] [8891 refs] [8891 refs] [8891 refs] [8891 refs] . [8891 refs] [8891 refs] this bit of output is from a test of stdout in a different process ... [8891 refs] [8891 refs] [9109 refs] test_sunaudiodev test_sunaudiodev skipped -- No module named sunaudiodev test_sundry test_symtable test_syntax test_sys [8891 refs] [8891 refs] test_tarfile test_tcl test_tcl skipped -- No module named _tkinter test_telnetlib test_tempfile [8897 refs] test_textwrap test_thread test_threaded_import test_threadedtempfile test_threading [13139 refs] test_threading_local test_threadsignals test_time test_timeout test_timeout skipped -- Use of the `network' resource not enabled test_tokenize test_trace test_traceback test_transformer test_tuple test_typechecks test_ucn test_unary test_unicode test_unicode_file test_unicode_file skipped -- No Unicode filesystem semantics on this platform. test_unicodedata test_univnewlines test_unpack test_urllib test_urllib2 test_urllib2_localnet test_urllib2net test_urllib2net skipped -- Use of the `network' resource not enabled test_urllibnet test_urllibnet skipped -- Use of the `network' resource not enabled test_urlparse test_userdict test_userlist test_userstring test_uu test_uuid WARNING: uuid.getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._ifconfig_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._unixdll_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. test_wait3 test_wait4 test test_wait4 failed -- Traceback (most recent call last): File "/tmp/python-test/local/lib/python2.6/test/fork_wait.py", line 56, in test_wait self.assertEquals(a, range(NUM_THREADS)) AssertionError: [] != [0, 1, 2, 3] test_warnings test_wave test_weakref test_whichdb test_winreg test_winreg skipped -- No module named _winreg test_winsound test_winsound skipped -- No module named winsound test_with test_wsgiref test_xdrlib test_xml_etree test_xml_etree_c test_xmllib test_xmlrpc test_xpickle test_xrange test_zipfile test_zipfile64 test_zipfile64 skipped -- test requires loads of disk-space bytes and a long time to run test_zipimport test_zlib 302 tests OK. 1 test failed: test_wait4 35 tests skipped: test_aepack test_al test_applesingle test_bsddb185 test_bsddb3 test_cd test_cl test_codecmaps_cn test_codecmaps_hk test_codecmaps_jp test_codecmaps_kr test_codecmaps_tw test_curses test_gl test_imageop test_imgfile test_ioctl test_linuxaudiodev test_macostools test_normalization test_ossaudiodev test_pep277 test_plistlib test_scriptpackages test_socketserver test_startfile test_sunaudiodev test_tcl test_timeout test_unicode_file test_urllib2net test_urllibnet test_winreg test_winsound test_zipfile64 1 skip unexpected on linux2: test_ioctl Unhandled exception in thread started by Traceback (most recent call last): Unhandled exception in thread started by Traceback (most recent call last): Unhandled exception in thread started by Traceback (most recent call last): Unhandled exception in thread started by Traceback (most recent call last): File "/tmp/python-test/local/lib/python2.6/unittest.py", line 255, in __repr__ File "/tmp/python-test/local/lib/python2.6/unittest.py", line 255, in __repr__ File "/tmp/python-test/local/lib/python2.6/unittest.py", line 255, in __repr__ File "/tmp/python-test/local/lib/python2.6/unittest.py", line 255, in __repr__ (_strclass(self.__class__), self._testMethodName) (_strclass(self.__class__), self._testMethodName) (_strclass(self.__class__), self._testMethodName) (_strclass(self.__class__), self._testMethodName) TypeErrorTypeErrorTypeErrorTypeError: : : : 'NoneType' object is not callable'NoneType' object is not callable'NoneType' object is not callable'NoneType' object is not callable [529672 refs] From python-checkins at python.org Thu Jan 17 13:00:15 2008 From: python-checkins at python.org (andrew.kuchling) Date: Thu, 17 Jan 2008 13:00:15 +0100 (CET) Subject: [Python-checkins] r60021 - python/trunk/Doc/whatsnew/2.6.rst Message-ID: <20080117120015.A33A41E4028@bag.python.org> Author: andrew.kuchling Date: Thu Jan 17 13:00:15 2008 New Revision: 60021 Modified: python/trunk/Doc/whatsnew/2.6.rst Log: Revise 3141 section a bit; add some Windows items Modified: python/trunk/Doc/whatsnew/2.6.rst ============================================================================== --- python/trunk/Doc/whatsnew/2.6.rst (original) +++ python/trunk/Doc/whatsnew/2.6.rst Thu Jan 17 13:00:15 2008 @@ -549,7 +549,7 @@ ===================================================== In Python 3.0, several abstract base classes for numeric types, -inspired by Scheme's numeric tower (XXX add link), are being added. +inspired by Scheme's numeric tower, are being added. This change was backported to 2.6 as the :mod:`numbers` module. The most general ABC is :class:`Number`. It defines no operations at @@ -585,27 +585,17 @@ combined using bitwise operations such as ``&`` and ``|``, and can be used as array indexes and slice boundaries. -The PEP slightly redefines the existing built-ins :func:`math.floor`, -:func:`math.ceil`, :func:`round`, and adds a new one, :func:`trunc`. All of them -take a :class:`Real` value and return an :class:`Integral`. - -* :func:`math.floor` returns the closest :class:`Integral` that's - smaller than the function's argument. Numeric types can define a - :meth:`__floor__` method to provide a custom implementation. - -* :func:`math.ceil` returns the closest :class:`Integral` that's - greater than the function's argument. It can be provided by a - :meth:`__ceil__` method. - -* :func:`trunc` rounds toward zero, returning the closest - :class:`Integral` that's between the function's argument and zero. - It can be provided by a :meth:`__trunc` method. - -* :func:`round` takes a :class:`Real` and rounds it off, optionally to a - specified number of decimal places. It will call a :meth:`__round__` - method. Whether .5 should be rounded up, or down, or toward the - nearest even number, is left up to the type's implementation. +In Python 3.0, the PEP slightly redefines the existing built-ins +:func:`math.floor`, :func:`math.ceil`, :func:`round`, and adds a new +one, :func:`trunc`, that's been backported to Python 2.6. +:func:`trunc` rounds toward zero, returning the closest +:class:`Integral` that's between the function's argument and zero. +.. seealso:: + + XXX link: Discusses Scheme's numeric tower. + + The Rational Module -------------------------------------------------- @@ -1347,6 +1337,14 @@ value, as does the :func:`getwche` function. The :func:`putwch` function takes a Unicode character and writes it to the console. +* :func:`os.path.expandvars` will now expand environment variables + in the form "%var%", and "~user" will be expanded into the + user's home directory path. (Contributed by Josiah Carlson.) + +* The :mod:`socket` module's socket objects now have an + :meth:`ioctl` method that provides a limited interface to the + :cfunc:`WSAIoctl` system interface. + * The :mod:`_winreg` module now has a function, :func:`ExpandEnvironmentStrings`, that expands environment variable references such as ``%NAME%`` From jimjjewett at gmail.com Thu Jan 17 15:29:40 2008 From: jimjjewett at gmail.com (Jim Jewett) Date: Thu, 17 Jan 2008 09:29:40 -0500 Subject: [Python-checkins] r59993 - python/trunk/Doc/whatsnew/2.6.rst In-Reply-To: <20080116031726.50B1A1E4010@bag.python.org> References: <20080116031726.50B1A1E4010@bag.python.org> Message-ID: I would put in an explicit warning, along the lines of: Note duck-typing is still primary in python. Existing classes which already implement the full interface won't show up in an isinstance check until they are registered. Conversely, classes which are registered with (but don't inherit from) the ABC may be lying. -jJ On 1/15/08, andrew.kuchling wrote: > Author: andrew.kuchling > Date: Wed Jan 16 04:17:25 2008 > New Revision: 59993 > > Modified: > python/trunk/Doc/whatsnew/2.6.rst > Log: > Add PEP 3141 section > > Modified: python/trunk/Doc/whatsnew/2.6.rst > ============================================================================== > --- python/trunk/Doc/whatsnew/2.6.rst (original) > +++ python/trunk/Doc/whatsnew/2.6.rst Wed Jan 16 04:17:25 2008 > @@ -541,6 +541,100 @@ > Implemented by XXX. > Backported to 2.6 by Benjamin Aranguren, with Alex Martelli. > > +.. ====================================================================== > + > +.. _pep-3141: > + > +PEP 3141: A Type Hierarchy for Numbers > +===================================================== > + > +In Python 3.0, several abstract base classes for numeric types, > +inspired by Scheme's numeric tower (XXX add link), are being added. > +This change was backported to 2.6 as the :mod:`numbers` module. > + > +The most general ABC is :class:`Number`. It defines no operations at > +all, and only exists to allow checking if an object is a number by > +doing ``isinstance(obj, Number)``. > + > +Numbers are further divided into :class:`Exact` and :class:`Inexact`. > +Exact numbers can represent values precisely and operations never > +round off the results or introduce tiny errors that may break the > +communtativity and associativity properties; inexact numbers may > +perform such rounding or introduce small errors. Integers, long > +integers, and rational numbers are exact, while floating-point > +and complex numbers are inexact. > + > +:class:`Complex` is a subclass of :class:`Number`. Complex numbers > +can undergo the basic operations of addition, subtraction, > +multiplication, division, and exponentiation, and you can retrieve the > +real and imaginary parts and obtain a number's conjugate. Python's built-in > +complex type is an implementation of :class:`Complex`. > + > +:class:`Real` further derives from :class:`Complex`, and adds > +operations that only work on real numbers: :func:`floor`, :func:`trunc`, > +rounding, taking the remainder mod N, floor division, > +and comparisons. > + > +:class:`Rational` numbers derive from :class:`Real`, have > +:attr:`numerator` and :attr:`denominator` properties, and can be > +converted to floats. Python 2.6 adds a simple rational-number class > +in the :mod:`rational` module. > + > +:class:`Integral` numbers derive from :class:`Rational`, and > +can be shifted left and right with ``<<`` and ``>>``, > +combined using bitwise operations such as ``&`` and ``|``, > +and can be used as array indexes and slice boundaries. > + > +The PEP slightly redefines the existing built-ins :func:`math.floor`, > +:func:`math.ceil`, :func:`round`, and adds a new one, :func:`trunc`. All of them > +take a :class:`Real` value and return an :class:`Integral`. > + > +* :func:`math.floor` returns the closest :class:`Integral` that's > + smaller than the function's argument. Numeric types can define a > + :meth:`__floor__` method to provide a custom implementation. > + > +* :func:`math.ceil` returns the closest :class:`Integral` that's > + greater than the function's argument. It can be provided by a > + :meth:`__ceil__` method. > + > +* :func:`trunc` rounds toward zero, returning the closest > + :class:`Integral` that's between the function's argument and zero. > + It can be provided by a :meth:`__trunc` method. > + > +* :func:`round` takes a :class:`Real` and rounds it off, optionally to a > + specified number of decimal places. It will call a :meth:`__round__` > + method. Whether .5 should be rounded up, or down, or toward the > + nearest even number, is left up to the type's implementation. > + > + > +The Rational Module > +-------------------------------------------------- > + > +To fill out the hierarchy of numeric types, a rational-number class > +has been added as the :mod:`rational` module. Rational numbers are > +represented as a fraction; rational numbers can exactly represent > +numbers such as two-thirds that floating-point numbers can only > +approximate. > + > +The :class:`Rational` constructor takes two :class:`Integral` values > +that will be the numerator and denominator of the resulting fraction. :: > + > + >>> from rational import Rational > + >>> a = Rational(2, 3) > + >>> b = Rational(2, 5) > + >>> float(a), float(b) > + (0.66666666666666663, 0.40000000000000002) > + >>> a+b > + rational.Rational(16,15) > + >>> a/b > + rational.Rational(5,3) > + > +The :mod:`rational` module is based upon an implementation by Sjoerd > +Mullender that was in Python's :file:`Demo/classes/` directory for a > +long time. This implementation was significantly updated by Jeffrey > +Yaskin. > + > + > Other Language Changes > ====================== > > _______________________________________________ > Python-checkins mailing list > Python-checkins at python.org > http://mail.python.org/mailman/listinfo/python-checkins > From python-checkins at python.org Thu Jan 17 19:45:11 2008 From: python-checkins at python.org (brett.cannon) Date: Thu, 17 Jan 2008 19:45:11 +0100 (CET) Subject: [Python-checkins] r60022 - python/trunk/Modules/_ctypes/libffi/src/x86/ffi_darwin.c Message-ID: <20080117184511.0D3961E400D@bag.python.org> Author: brett.cannon Date: Thu Jan 17 19:45:10 2008 New Revision: 60022 Modified: python/trunk/Modules/_ctypes/libffi/src/x86/ffi_darwin.c Log: Fix a function pointer declaration to silence the compiler. Modified: python/trunk/Modules/_ctypes/libffi/src/x86/ffi_darwin.c ============================================================================== --- python/trunk/Modules/_ctypes/libffi/src/x86/ffi_darwin.c (original) +++ python/trunk/Modules/_ctypes/libffi/src/x86/ffi_darwin.c Thu Jan 17 19:45:10 2008 @@ -217,7 +217,7 @@ #endif /* X86_WIN32 */ void ffi_call(/*@dependent@*/ ffi_cif *cif, - void (*fn)(), + void (*fn)(void), /*@out@*/ void *rvalue, /*@dependent@*/ void **avalue) { From buildbot at python.org Thu Jan 17 19:52:06 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 17 Jan 2008 18:52:06 +0000 Subject: [Python-checkins] buildbot failure in hppa Ubuntu trunk Message-ID: <20080117185206.BFDBD1E400D@bag.python.org> The Buildbot has detected a new failure of hppa Ubuntu trunk. Full details are available at: http://www.python.org/dev/buildbot/all/hppa%20Ubuntu%20trunk/builds/530 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-ubuntu-hppa Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: gregory.p.smith,raymond.hettinger BUILD FAILED: failed failed slave lost sincerely, -The Buildbot From python-checkins at python.org Thu Jan 17 20:31:39 2008 From: python-checkins at python.org (raymond.hettinger) Date: Thu, 17 Jan 2008 20:31:39 +0100 (CET) Subject: [Python-checkins] r60024 - in python/trunk: Doc/library/sched.rst Lib/sched.py Misc/NEWS Message-ID: <20080117193139.393981E4032@bag.python.org> Author: raymond.hettinger Date: Thu Jan 17 20:31:38 2008 New Revision: 60024 Modified: python/trunk/Doc/library/sched.rst python/trunk/Lib/sched.py python/trunk/Misc/NEWS Log: Issue #1861: Add read-only attribute listing upcoming events in the order they will be run. Modified: python/trunk/Doc/library/sched.rst ============================================================================== --- python/trunk/Doc/library/sched.rst (original) +++ python/trunk/Doc/library/sched.rst Thu Jan 17 20:31:38 2008 @@ -47,7 +47,7 @@ Scheduler Objects ----------------- -:class:`scheduler` instances have the following methods: +:class:`scheduler` instances have the following methods and attributes: .. method:: scheduler.enterabs(time, priority, action, argument) @@ -98,3 +98,8 @@ the calling code is responsible for canceling events which are no longer pertinent. +.. attribute:: scheduler.queue + + Read-only attribute returning a list of upcoming events in the order they + will be run. Each event is shown as a :term:`named tuple` with the + following fields: time, priority, action, argument. Modified: python/trunk/Lib/sched.py ============================================================================== --- python/trunk/Lib/sched.py (original) +++ python/trunk/Lib/sched.py Thu Jan 17 20:31:38 2008 @@ -29,14 +29,17 @@ # XXX the global state of your particular time and delay functions. import heapq +from collections import namedtuple __all__ = ["scheduler"] +Event = namedtuple('Event', 'time, priority, action, argument') + class scheduler: def __init__(self, timefunc, delayfunc): """Initialize a new instance, passing the time and delay functions""" - self.queue = [] + self._queue = [] self.timefunc = timefunc self.delayfunc = delayfunc @@ -47,8 +50,8 @@ if necessary. """ - event = time, priority, action, argument - heapq.heappush(self.queue, event) + event = Event(time, priority, action, argument) + heapq.heappush(self._queue, event) return event # The ID def enter(self, delay, priority, action, argument): @@ -67,12 +70,12 @@ If the event is not in the queue, this raises RuntimeError. """ - self.queue.remove(event) - heapq.heapify(self.queue) + self._queue.remove(event) + heapq.heapify(self._queue) def empty(self): """Check whether the queue is empty.""" - return not self.queue + return not self._queue def run(self): """Execute events until the queue is empty. @@ -97,7 +100,7 @@ """ # localize variable access to minimize overhead # and to improve thread safety - q = self.queue + q = self._queue delayfunc = self.delayfunc timefunc = self.timefunc pop = heapq.heappop @@ -115,3 +118,17 @@ delayfunc(0) # Let other threads run else: heapq.heappush(event) + + @property + def queue(self): + """An ordered list of upcoming events. + + Events are named tuples with fields for: + time, priority, action, arguments + + """ + # Use heapq to sort the queue rather than using 'sorted(self._queue)'. + # With heapq, two events scheduled at the same time will show in + # the actual order they would be retrieved. + events = self._queue[:] + return map(heapq.heappop, [events]*len(events)) Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Thu Jan 17 20:31:38 2008 @@ -364,6 +364,9 @@ Library ------- +- #1861: Added an attribute to the sched module which returns an ordered + list of upcoming events (displayed as named tuples). + - #1837: The queue module now also supports a LIFO queue and a priority queue. - Issue #1831: ctypes now raises a TypeError if conflicting positional From buildbot at python.org Thu Jan 17 20:46:55 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 17 Jan 2008 19:46:55 +0000 Subject: [Python-checkins] buildbot failure in x86 XP-3 trunk Message-ID: <20080117194655.5888E1E4021@bag.python.org> The Buildbot has detected a new failure of x86 XP-3 trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20XP-3%20trunk/builds/673 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: heller-windows Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: sincerely, -The Buildbot From python-checkins at python.org Thu Jan 17 20:49:24 2008 From: python-checkins at python.org (andrew.kuchling) Date: Thu, 17 Jan 2008 20:49:24 +0100 (CET) Subject: [Python-checkins] r60025 - python/trunk/Doc/howto/curses.rst Message-ID: <20080117194924.69E951E4029@bag.python.org> Author: andrew.kuchling Date: Thu Jan 17 20:49:24 2008 New Revision: 60025 Modified: python/trunk/Doc/howto/curses.rst Log: Correction from Jordan Lewis: halfdelay() uses tenths of a second, not milliseconds Modified: python/trunk/Doc/howto/curses.rst ============================================================================== --- python/trunk/Doc/howto/curses.rst (original) +++ python/trunk/Doc/howto/curses.rst Thu Jan 17 20:49:24 2008 @@ -367,8 +367,8 @@ ``nodelay(1)``, :meth:`getch` for the window becomes non-blocking and returns ``curses.ERR`` (a value of -1) when no input is ready. There's also a :func:`halfdelay` function, which can be used to (in effect) set a timer on each -:meth:`getch`; if no input becomes available within the number of milliseconds -specified as the argument to :func:`halfdelay`, curses raises an exception. +:meth:`getch`; if no input becomes available within a specified +delay (measured in tenths of a second), curses raises an exception. The :meth:`getch` method returns an integer; if it's between 0 and 255, it represents the ASCII code of the key pressed. Values greater than 255 are From buildbot at python.org Thu Jan 17 21:25:52 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 17 Jan 2008 20:25:52 +0000 Subject: [Python-checkins] buildbot failure in x86 FreeBSD trunk Message-ID: <20080117202552.E25281E403B@bag.python.org> The Buildbot has detected a new failure of x86 FreeBSD trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20FreeBSD%20trunk/builds/412 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-freebsd Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: andrew.kuchling,brett.cannon BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 523, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 523, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable 1 test failed: test_xmlrpc sincerely, -The Buildbot From buildbot at python.org Thu Jan 17 22:03:44 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 17 Jan 2008 21:03:44 +0000 Subject: [Python-checkins] buildbot failure in sparc solaris10 gcc trunk Message-ID: <20080117210344.671081E4040@bag.python.org> The Buildbot has detected a new failure of sparc solaris10 gcc trunk. Full details are available at: http://www.python.org/dev/buildbot/all/sparc%20solaris10%20gcc%20trunk/builds/2627 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-sun Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/SocketServer.py", line 523, in __init__ self.handle() File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 11] Resource temporarily unavailable 1 test failed: test_xmlrpc sincerely, -The Buildbot From nnorwitz at gmail.com Thu Jan 17 23:29:06 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Thu, 17 Jan 2008 17:29:06 -0500 Subject: [Python-checkins] Python Regression Test Failures refleak (9) Message-ID: <20080117222906.GA13242@python.psfb.org> test_opcodes leaked [-2, 0, 2] references, sum=0 test_doctest leaked [0, 0, -4] references, sum=-4 test_descrtut leaked [-2, 2, 2] references, sum=2 test_difflib leaked [-2, 0, 0] references, sum=-2 test_future leaked [0, 0, -2] references, sum=-2 test_gc leaked [0, 2, 0] references, sum=2 test_importhooks leaked [10, -2, -2] references, sum=6 test_parser leaked [-2, 0, 0] references, sum=-2 test_popen leaked [0, 0, -2] references, sum=-2 test_sqlite leaked [-2, 2, 0] references, sum=0 test_timeout leaked [0, -2, 0] references, sum=-2 test_urllib2_localnet leaked [3, 3, 3] references, sum=9 From nnorwitz at gmail.com Thu Jan 17 23:48:10 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Thu, 17 Jan 2008 17:48:10 -0500 Subject: [Python-checkins] Python Regression Test Failures doc (1) Message-ID: <20080117224810.GA15239@python.psfb.org> svn update tools/sphinx Fetching external item into 'tools/sphinx/jinja' External at revision 60025. At revision 60025. svn update tools/docutils At revision 60025. svn update tools/pygments At revision 60025. mkdir -p build/html build/doctrees python tools/sphinx-build.py -b html -d build/doctrees -D latex_paper_size= . build/html trying to load pickled env... done building [html]: targets for 9 source files that are out of date reading, updating environment: 0 added, 7 changed, 0 removed howto/curses.rst library/collections.rst library/itertools.rst library/queue.rst library/sched.rst library/smtplib.rst whatsnew/2.6.rst pickling the env... done checking consistency... creating index... Traceback (most recent call last): File "tools/sphinx-build.py", line 24, in sys.exit(main(sys.argv)) File "/home/neal/python/trunk/Doc/tools/sphinx/__init__.py", line 125, in main builderobj.build_update() File "/home/neal/python/trunk/Doc/tools/sphinx/builder.py", line 187, in build_update 'out of date' % len(to_build)) File "/home/neal/python/trunk/Doc/tools/sphinx/builder.py", line 223, in build self.write(filenames, updated_filenames) File "/home/neal/python/trunk/Doc/tools/sphinx/builder.py", line 243, in write self.prepare_writing(filenames) File "/home/neal/python/trunk/Doc/tools/sphinx/builder.py", line 312, in prepare_writing self.load_indexer(filenames) File "/home/neal/python/trunk/Doc/tools/sphinx/builder.py", line 499, in load_indexer self.indexer.load(f, 'json') File "/home/neal/python/trunk/Doc/tools/sphinx/search.py", line 70, in load for (k, v) in frozen[2].iteritems()) AttributeError: 'list' object has no attribute 'iteritems' make: *** [build] Error 1 From python-checkins at python.org Thu Jan 17 23:27:49 2008 From: python-checkins at python.org (raymond.hettinger) Date: Thu, 17 Jan 2008 23:27:49 +0100 (CET) Subject: [Python-checkins] r60026 - python/trunk/Doc/library/sched.rst Message-ID: <20080117222749.DEDB11E4011@bag.python.org> Author: raymond.hettinger Date: Thu Jan 17 23:27:49 2008 New Revision: 60026 Modified: python/trunk/Doc/library/sched.rst Log: Add advice on choosing between scheduler and threading.Timer(). Modified: python/trunk/Doc/library/sched.rst ============================================================================== --- python/trunk/Doc/library/sched.rst (original) +++ python/trunk/Doc/library/sched.rst Thu Jan 17 23:27:49 2008 @@ -41,6 +41,31 @@ From print_time 930343700.273 930343700.276 +In multi-threaded environments, the :class:`scheduler` class has limitations +with respect to thread-safety, inability to insert a new task before +the one currently pending in a running scheduler, and holding-up the main +thread until the event queue is empty. Instead, the preferred approach +is to use the :class:`threading.Timer` class instead. + +Example:: + + >>> import time + >>> from threading import Timer + >>> def print_time(): + ... print "From print_time", time.time() + ... + >>> def print_some_times(): + ... print time.time() + ... Timer(5, print_time, ()).start() + ... Timer(10, 1, print_time, ()) + ... print time.time() # executes before the time-delay events + ... + >>> print_some_times() + 930343690.257 + 930343690.301 + From print_time 930343695.274 + From print_time 930343700.273 + .. _scheduler-objects: From python-checkins at python.org Thu Jan 17 23:44:16 2008 From: python-checkins at python.org (brett.cannon) Date: Thu, 17 Jan 2008 23:44:16 +0100 (CET) Subject: [Python-checkins] r60027 - peps/trunk/pep-3108.txt Message-ID: <20080117224416.51B881E4011@bag.python.org> Author: brett.cannon Date: Thu Jan 17 23:44:16 2008 New Revision: 60027 Modified: peps/trunk/pep-3108.txt Log: List sched for removal; threading.Timer is a better replacement. Modified: peps/trunk/pep-3108.txt ============================================================================== --- peps/trunk/pep-3108.txt (original) +++ peps/trunk/pep-3108.txt Thu Jan 17 23:44:16 2008 @@ -319,6 +319,10 @@ + Replaced by ossaudiodev. +* sched + + + Replaced by threading.Timer. + * stat + ``os.stat`` now returns a tuple with attributes. From python-checkins at python.org Fri Jan 18 00:01:44 2008 From: python-checkins at python.org (christian.heimes) Date: Fri, 18 Jan 2008 00:01:44 +0100 (CET) Subject: [Python-checkins] r60028 - python/trunk/Doc/whatsnew/2.6.rst Message-ID: <20080117230144.C323E1E4011@bag.python.org> Author: christian.heimes Date: Fri Jan 18 00:01:44 2008 New Revision: 60028 Modified: python/trunk/Doc/whatsnew/2.6.rst Log: Updated new property syntax. An elaborate example for subclassing and the getter was missing. Added comment about VS 2008 and PGO builds. Modified: python/trunk/Doc/whatsnew/2.6.rst ============================================================================== --- python/trunk/Doc/whatsnew/2.6.rst (original) +++ python/trunk/Doc/whatsnew/2.6.rst Fri Jan 18 00:01:44 2008 @@ -652,10 +652,10 @@ .. Revision 57619 -* Properties now have two attributes, +* Properties now have three attributes, :attr:`getter`, :attr:`setter` and :attr:`deleter`, that are useful shortcuts for - adding a setter or deleter function to an existing property. - You would use them like this:: + adding or modifying a getter, setter or deleter function to an + existing property. You would use them like this:: class C(object): @property @@ -670,6 +670,15 @@ def x(self): del self._x + class D(C): + @C.x.getter + def x(self): + return self._x * 2 + + @x.setter + def x(self, value): + self._x = value / 2 + * C functions and methods that use :cfunc:`PyComplex_AsCComplex` will now accept arguments that @@ -1336,6 +1345,7 @@ API. The :func:`getwch` function reads a keypress and returns a Unicode value, as does the :func:`getwche` function. The :func:`putwch` function takes a Unicode character and writes it to the console. + (Contributed by Christian Heimes.) * :func:`os.path.expandvars` will now expand environment variables in the form "%var%", and "~user" will be expanded into the @@ -1350,7 +1360,15 @@ that expands environment variable references such as ``%NAME%`` in an input string. The handle objects provided by this module now support the context protocol, so they can be used - in :keyword:`with` statements. + in :keyword:`with` statements. (Contributed by Christian Heimes.) + +* The new default compiler on Windows is Visual Studio 2008 (VS 9.0). The + build directories for Visual Studio 2003 (VS7.1) and 2005 (VS8.0) + were moved into the PC/ directory. The new PCbuild directory supports + cross compilation for X64, debug builds and Profile Guided Optimization + (PGO). PGO builds are roughly 10% faster than normal builds. + (Contributed by Christian Heimes with help from Amaury Forgeot d'Arc and + Martin von Loewis.) .. ====================================================================== From python-checkins at python.org Fri Jan 18 00:32:01 2008 From: python-checkins at python.org (raymond.hettinger) Date: Fri, 18 Jan 2008 00:32:01 +0100 (CET) Subject: [Python-checkins] r60029 - python/trunk/Doc/library/sched.rst Message-ID: <20080117233201.E24C21E4011@bag.python.org> Author: raymond.hettinger Date: Fri Jan 18 00:32:01 2008 New Revision: 60029 Modified: python/trunk/Doc/library/sched.rst Log: Fix-up Timer() example. Modified: python/trunk/Doc/library/sched.rst ============================================================================== --- python/trunk/Doc/library/sched.rst (original) +++ python/trunk/Doc/library/sched.rst Fri Jan 18 00:32:01 2008 @@ -57,14 +57,15 @@ >>> def print_some_times(): ... print time.time() ... Timer(5, print_time, ()).start() - ... Timer(10, 1, print_time, ()) - ... print time.time() # executes before the time-delay events + ... Timer(10, print_time, ()).start() + ... time.sleep(11) # sleep while time-delay events execute + ... print time.time() ... >>> print_some_times() 930343690.257 - 930343690.301 From print_time 930343695.274 From print_time 930343700.273 + 930343701.301 .. _scheduler-objects: From python-checkins at python.org Fri Jan 18 00:56:56 2008 From: python-checkins at python.org (raymond.hettinger) Date: Fri, 18 Jan 2008 00:56:56 +0100 (CET) Subject: [Python-checkins] r60030 - python/trunk/Doc/library/sched.rst Message-ID: <20080117235656.89DA21E4011@bag.python.org> Author: raymond.hettinger Date: Fri Jan 18 00:56:56 2008 New Revision: 60030 Modified: python/trunk/Doc/library/sched.rst Log: Fix markup Modified: python/trunk/Doc/library/sched.rst ============================================================================== --- python/trunk/Doc/library/sched.rst (original) +++ python/trunk/Doc/library/sched.rst Fri Jan 18 00:56:56 2008 @@ -129,3 +129,5 @@ Read-only attribute returning a list of upcoming events in the order they will be run. Each event is shown as a :term:`named tuple` with the following fields: time, priority, action, argument. + + .. versionadded:: 2.6 From python-checkins at python.org Fri Jan 18 01:10:42 2008 From: python-checkins at python.org (raymond.hettinger) Date: Fri, 18 Jan 2008 01:10:42 +0100 (CET) Subject: [Python-checkins] r60031 - python/trunk/Modules/_struct.c Message-ID: <20080118001042.9C56E1E4029@bag.python.org> Author: raymond.hettinger Date: Fri Jan 18 01:10:42 2008 New Revision: 60031 Modified: python/trunk/Modules/_struct.c Log: clearcache() needs to remove the dict as well as clear it. Modified: python/trunk/Modules/_struct.c ============================================================================== --- python/trunk/Modules/_struct.c (original) +++ python/trunk/Modules/_struct.c Fri Jan 18 01:10:42 2008 @@ -1887,8 +1887,7 @@ static PyObject * clearcache(PyObject *self) { - if (cache != NULL) - PyDict_Clear(cache); + Py_CLEAR(cache); Py_RETURN_NONE; } From python-checkins at python.org Fri Jan 18 01:31:21 2008 From: python-checkins at python.org (guido.van.rossum) Date: Fri, 18 Jan 2008 01:31:21 +0100 (CET) Subject: [Python-checkins] r60032 - peps/trunk/pep-0101.txt Message-ID: <20080118003122.0699C1E4032@bag.python.org> Author: guido.van.rossum Date: Fri Jan 18 01:31:21 2008 New Revision: 60032 Modified: peps/trunk/pep-0101.txt Log: Quick checkin of an updated version by Neal Norwitz. No guarantees that this is correct, but it's definitely better than what we had before. At least *some* of the CVS references have been replaced by SVN references. Modified: peps/trunk/pep-0101.txt ============================================================================== --- peps/trunk/pep-0101.txt (original) +++ peps/trunk/pep-0101.txt Fri Jan 18 01:31:21 2008 @@ -2,7 +2,7 @@ Title: Doing Python Releases 101 Version: $Revision$ Last-Modified: $Date$ -Author: barry at python.org (Barry Warsaw), guido at python.org (Guido van Rossum) +Author: barry at python.org (Barry A. Warsaw), guido at python.org (Guido van Rossum) Status: Active Type: Informational Created: 22-Aug-2001 @@ -20,25 +20,31 @@ recipe and you can actually print this out and check items off as you complete them. + XXX: This version is a partial update by Neal Norwitz. There are + undoubtedly still many places where reality differs! + How to Make A Release Here are the steps taken to make a Python release. Some steps are more fuzzy than others because there's little that can be automated (e.g. writing the NEWS entries). Where a step is - usually performed by An Expert, the name of that expert is given. + usually performed by An Expert, the role of that expert is given. Otherwise, assume the step is done by the Release Manager (RM), - the designated person performing the release. Almost every place - the RM is mentioned below, this step can also be done by the BDFL - of course! + the designated person performing the release. The roles and their + current experts are: + + * WE = Windows: Martin von Loewis + * ME = Mac: Ronald Oussoren + * DE = Documentation: Fred Drake XXX: We should include a dependency graph to illustrate the steps that can be taken in parallel, or those that depend on other steps. We use the following conventions in the examples below. Where a - release number is given, it is of the form X.YaZ, e.g. 2.5a3 for - Python 2.5 alpha 3, where "a" == alpha, "b" == beta, "rc" == + release number is given, it is of the form X.YaZ, e.g. 2.6a3 for + Python 2.6 alpha 3, where "a" == alpha, "b" == beta, "c" == release candidate. Final releases are named "releaseXY". The branch tag is @@ -48,19 +54,20 @@ say X.Y.MaZ. Note: This document has been updated to reflect the more - streamlined procedures used to release Python 2.5 (including the + streamlined procedures used to release Python 2.6 (including the alphas and betas). ___ Impose a check-in freeze. Send a message to python-dev at python.org telling people not to make any check-ins on the tree until further notice. - At this point, nobody except the RM should make any commits to - the branch (or his duly assigned agents, i.e. Guido the BDFL, - Fred Drake for documentation, or Martin v. Loewis for Windows). - If the RM screwed up and some desperate last minute change to the - branch is necessary, it can mean extra work for Fred and Martin. - So try to avoid this! + At this point, nobody except the RM or his duly assigned agents + should make any commits to the branch. The assigned agents are + either from the list above or by coordination as necessary. If + a checkin needs to made, make sure to state in the checkin + comment that the change was approved. If the RM screwed up and + some desperate last minute change to the branch is necessary, it + can mean extra work for others. So try to avoid this! ___ Log into irc.freenode.net and join the #python-dev channel. @@ -68,38 +75,36 @@ world. This IRC channel is where we've arranged to meet. ___ The most important thing to do is to update the Misc/NEWS file. - Tim will need this in order to do the Windows release and he - likes to stay up late. This step can be pretty tedious, so it's - best to get to it immediately after making the branch, or even - before you've made the branch. + This step can be pretty tedious, so it's best to get to it + immediately after making the branch, or even before you've made + the branch. Add high level items new to this release. E.g. if we're - releasing 2.5a3, there must be a section at the top of the file - explaining "What's new in Python 2.5a3". It will be followed by - a section entitled "What's new in Python 2.5a2". + releasing 2.6a3, there must be a section at the top of the file + explaining "What's new in Python 2.6a3". It will be followed by + a section entitled "What's new in Python 2.6a2". Note that you /hope/ that as developers add new features to the trunk, they've updated the NEWS file accordingly. You can't be - positive, so double check. If you're a Unix weenie, it helps to - verify with Tim Peters about changes on Windows, and Jack Jansen - about changes on the Mac. + positive, so double check. It helps to verify with the Windows + and Mac experts. This command should help you: - % cvs log | python Tools/scripts/logmerge.py > /tmp/news.txt + % svn log -r '{YYYY-MM-DD}:HEAD' > /tmp/news.txt - IOW, you're printing out all the cvs log entries from the - previous release until now. You can then troll through the + IOW, you're printing out all the svn log entries from the + previous release date until now. You can then troll through the news.txt file looking for interesting things to add to NEWS. - ___ For major releases (e.g. 2.5 final), move any historical "what's + ___ For major releases (e.g. 2.6 final), move any historical "what's new" entries from Misc/NEWS to Misc/HISTORY. ___ Check with the IDLE maintainer to be sure that Lib/idlelib/NEWS.txt has been similarly updated. - ___ For final (non-alpha/beta/candidate) releases, make sure the - release date is fully spelled out in Doc/commontex/boilerplate.tex. + ___ Make sure the release date is fully spelled out in + Doc/commontex/boilerplate.tex. ___ Tag and/or branch the tree for release X.YaZ @@ -114,31 +119,30 @@ a short-lived release branch. Practically speaking, we tag and branch just before making the - release. Tagging too early causes too much merging work. - - ___ Do a CVS update with the -A, -d, and -P flags, e.g. - % cvs -q update -d -P -A + release. Branching too early causes too much merging work. - To tag the tree, do the following: + When making a major release (e.g., for 2.6), you should branch. + To create a _branch_ (e.g., release26-maint), do the following: - ___ cvs tag rXYaZ + ___ svn copy \ + svn+ssh://pythondev at svn.python.org/python/trunk \ + svn+ssh://pythondev at svn.python.org/python/branches/release26-maint - To create a maintenance branch the following steps are taken: + When making a minor release (e.g., for 2.6a1 or 2.6.1), you should tag. + To create a _tag_ (e.g., r26a1), do the following: - ___ CVS tag the trunk with the symbolic name "releaseXY-fork", e.g. - % cvs tag releaseXY-fork - - ___ Make the branch with the symbolic name "releaseXY-maint", e.g. - % cvs tag -b releaseXY-maint + ___ svn copy \ + svn+ssh://pythondev at svn.python.org/python/branches/release26-maint \ + svn+ssh://pythondev at svn.python.org/python/tags/r26a1 ___ Check out a clean version of the branch into a new directory. You'll be doing a lot of work in this directory and you want to keep it straight from your trunk working directory. E.g. - % export CVSROOT=cvs.sf.net:/cvsroot/python - % cvs -q co -d python-25a3 -r release25-maint python/dist/src + % svn co \ + svn+ssh://pythondev at svn.python.org/python/branches/release26-maint - ___ cd into the branch directory. + ___ cd relesae26-maint # cd into the branch directory. ___ Change Include/patchlevel.h in two places, to reflect the new version number you've just created. You'll want @@ -151,6 +155,9 @@ release date. Then update Lib/idlelib/idlever.py to show a matching version. + ___ distutils also maintains its own versioning file + (Lib/distutils/__init__.py). Update this file with the Python version. + ___ Change the "%define version" line of Misc/RPM/python-2.5.spec to the same string as PY_VERSION was changed to above. E.g. @@ -169,10 +176,8 @@ different than is in the name of the current "Misc/RPM/python-*.spec" file, rename the file: - % mv python-2.5.spec python-2.6.spec - % cvs remove python-2.5.spec - % cvs add python-2.6.spec - % cvs commit + % svn rename python-2.5.spec python-2.6.spec + % svn commit ___ If this is a release candidate, mail Sean noting the impending release, so that RPMs can be built and @@ -185,7 +190,11 @@ number changes, also update the LICENSE file. ___ There's a copy of the license in - Doc/commontex/license.tex; Fred usually takes care of that. + Doc/commontex/license.tex; the DE usually takes care of that. + + ___ If the minor (middle) digit of the version number changes, update: + + ___ Doc/tut/tut.tex (4 references to [Pp]ython26) ___ Check the years on the copyright notice. If the last release was some time last year, add the current year to the copyright @@ -193,7 +202,7 @@ ___ README - ___ LICENSE + ___ LICENSE (make sure to change on trunk and the branch) ___ Python/getcopyright.c @@ -215,9 +224,9 @@ Doc/whatsnew/whatsnewXX.tex to include the actual release date; e.g. "Python 2.5 was released on August 1, 2003." There's no need to edit this for alpha or beta releases. Note - that Andrew often takes care of this. + that Andrew Kuchling often takes care of this. - ___ At this point, Fred will create the formatted versions of the + ___ At this point, the DE will create the formatted versions of the documentation and push the appropriate files out to their FTP locations on www.python.org. The HTML format is used to build the HTML Help format for the Windows installer, but the RM @@ -225,7 +234,7 @@ Help format will typically be generated by whoever builds the Windows installer. - Once Fred is done, there can be no further checkins on the + Once the DE is done, there can be no further checkins on the branch in the Doc/ directory -- not even by the RM. Building the documentation is done using the Makefile in the @@ -311,36 +320,40 @@ required actions are described in a separate step of this checklist. - ___ Martin grabs the HTML to build the Windows helpfile. + ___ Ping Neal Norwitz (or anyone else with access to the PSF box + which runs the automated builds) to fix conflicts that arise + in the checked out working areas. + + ___ The WE grabs the HTML to build the Windows helpfile. The HTML files are unpacked into a new src/html directory, and runs this command to create the project files for MS HTML Workshop: - % python ..\Doc\tools\prechm.py -v 2.5 python25 + % python ..\Doc\tools\prechm.py -v 2.6 python26 HTML Workshop is then fired up on the created python25.hhp file, - finally resulting in an python25.chm file. He then copies the + finally resulting in an python26.chm file. He then copies the file into the Doc directories of the build trees (once for each target architecture). - ___ Martin then generates Windows installer files for each Windows - target architecture (for Python 2.5, this means x86, Itanium, + ___ The WE then generates Windows installer files for each Windows + target architecture (for Python 2.6, this means x86 and AMD64). He has one checkout tree per target architecture, and builds the pcbuild.sln project for the appropriate architecture. He then edits Tools/msi/config.py to update full_current_version, and runs msi.py with ActivePython 2.5. For that to work, the following prerequisites must be met: - - PC/icons.mak must have been run with nmake. + - PC\icons.mak must have been run with nmake. - The cmd.exe window in which this is run must have Cygwin/bin in its path (atleast for x86). - The cmd.exe window must have MS compiler tools for the target architecture in its path (VS 2003 for x86, the platform - SDK for Itanium and AMD64). + SDK for AMD64). - Martin checksums the files (*.msi and *.chm), uploads them to + The WE checksums the files (*.msi and *.chm), uploads them to some place in the net, and emails you the location and md5sums. ___ Sean Reifschneider grabs the HTML and uses this to build the @@ -351,48 +364,50 @@ ___ Time to build the source tarball. If you created a branch, be sure to cd to your working directory for the branch. E.g. - % cd .../python-25a3 + % cd .../python-26a3 - ___ Do a "cvs update" in this directory. Do NOT include the -A flag - if you're working on a branch, but do include it if you're - working on the trunk. + ___ Do a "svn update ; svn status" in this directory. - You should not see any "M" files, but you may see several "P" or - "U" files. I.e. you better not have any uncommitted changes in - your working directory, but you may pick up some of Fred's or - Martin's last minute changes. + You should not see any files. I.e. you better not have any + uncommitted changes in your working directory, but you may pick + up some of the expert's last minute changes. - ___ If you've seen updates to existing files, update the cvs tag: + ___ If you've seen updates to existing files, update the svn tag: - % cvs tag -F r25a3 + % svn copy \ + svn+ssh://pythondev at svn.python.org/python/trunk \ + svn+ssh://pythondev at svn.python.org/python/tags/r26a3 If you created a maintenance branch and you've changed any files since you branched, tag the tree -- in the branch -- now with something like - % cvs tag r25 + % svn copy \ + svn+ssh://pythondev at svn.python.org/python/trunk \ + svn+ssh://pythondev at svn.python.org/python/tags/r26 This is the tag you will use below. ___ Change to a neutral directory, i.e. one in which you can do a - fresh, virgin, cvs export of the branch. You will be creating a - new directory at this location, to be named "Python-X.YaZ". Do - a CVS export of the tagged branch. + fresh, virgin, svn export of the branch. You will be creating a + new directory at this location, to be named "Python-X.YaZ". Export + the tagged branch. % cd ~ - % export CVSROOT=cvs.sf.net:/cvsroot/python - % cvs export -rr25c2 -d Python-2.5c2 python/dist/src + % svn export -rr26c2 -d Python-2.6c2 python - ___ Generate the tarball. Note that we're not using the `z' option + ___ Generate the tarballs. Note that we're not using the `z' option on the tar command because 1) that's only supported by GNU tar as far as we know, and 2) we're going to max out the compression level, which isn't a supported option. - % tar cf - Python-2.5c2 | gzip -9 > Python-2.5c2.tgz + % tar cf - Python-2.6c2 | gzip -9 > Python-2.6c2.tgz + % tar cf - Python-2.6c2 | bzip2 -9 > Python-2.6c2.tar.bz2 - ___ Calculate the MD5 checksum of the tgz file you just created + ___ Calculate the MD5 checksums of the files you just created - % md5sum Python-2.5c2.tgz + % md5sum Python-2.6c2.tgz + % md5sum Python-2.6c2.tar.bz2 Note that if you don't have the md5sum program, there is a Python replacement in the Tools/scripts/md5sum.py file. @@ -403,8 +418,8 @@ steps to take: % cd /tmp - % tar zxvf ~/Python-2.5c2.tgz - % cd Python-2.5c2 + % tar zxvf ~/Python-2.6c2.tgz # tar xjvf ~/Python-2.6c2.tar.bz2 + % cd Python-2.6c2 % ls (Do things look reasonable?) % ./configure @@ -424,22 +439,26 @@ ___ Upload the tgz file to dinsdale.python.org using scp. + # XXX(nnorwitz): this entire section dealing with the website is outdated. + # The website uses SVN and the build process has changed. ___ While you're waiting, you can start twiddling the web pages to include the announcement. ___ If necessary, and if you have the right permissions (the python.org sysadmins must set this up for you), check out the - web site CVS tree by doing: + web site tree by doing: % cvs -d :ext:@dinsdale.python.org:/usr/local/cvsroot co pydotorg - ___ In the python.org web site CVS tree, cd to the X.Y + XXX: what's the svn equivalent? + + ___ In the python.org web site SVN tree, cd to the X.Y subdirectory, and copy index.ht to new-index.ht. Be sure to - do a "cvs update" first! + do a "svn update" first! % cd .../pydotorg - % cvs -q up -P -d - % cd 2.5 + % svn up + % cd 2.6 % cp index.ht new-index.ht ___ Edit the file for content: usually you can globally replace @@ -475,29 +494,29 @@ releases. We keep all old releases, moving them into a "prev" subdirectory when we have a new release. - So, there's a directory called "2.5" which contains - Python-2.5a2.exe and Python-2.5a2.tgz, along with a "prev" - subdirectory containing Python-2.5a1.exe and Python-2.5a1.tgz. + So, there's a directory called "2.6" which contains + Python-2.5a2.exe and Python-2.6a2.tgz, along with a "prev" + subdirectory containing Python-2.6a1.msi, Python-2.6a1.tgz, + Python-2.6a1.tar.bz2, etc. So... - ___ On dinsdale, cd to ~ftp/pub/python/X.Y creating it if - necessary. + ___ On dinsdale, cd /data/ftp.python.org/pub/python/X.Y[.Z] + creating it if necessary. ___ Move the previous release files to a directory called "prev" creating the directory if necessary (make sure the directory has g+ws bits on). If this is the first alpha release of a new Python version, skip this step. - ___ Move the .tgz file and the .exe file to this directory. Make + ___ Move the .tgz, tar.bz2, and .msi files to this directory. Make sure they are world readable. They should also be group writable, and group-owned by webmaster. ___ md5sum the files and make sure they got uploaded intact. - ___ Update the X.Y/bugs.ht file if necessary. It is best to get - BDFL input for this step. + ___ Update the X.Y/bugs.ht file if necessary. ___ Now preview the new-index.ht file once more. IMPORTANT: follow every link on the page to make sure it goes where you expect it @@ -510,8 +529,7 @@ ___ Now it's time to write the announcement for the mailing lists. This is the fuzzy bit because not much can be automated. You - can use one of Guido's earlier announcements as a template, but - please edit it for content! + can use an earlier announcement as a template, but edit it for content! Once the announcement is ready, send it to the following addresses: @@ -524,16 +542,6 @@ pydotorg:doc/faq/general.ht (section "How stable is Python?") - ___ Send a SourceForge News Item about the release. From the - project's "menu bar", select the "News" link; once in News, - select the "Submit" link. Type a suitable subject (e.g. "Python - 2.5c1 released" :-) in the Subject box, add some text to the - Details box (at the very least including the release URL at - www.python.org and the fact that you're happy with the release) - and click the SUBMIT button. - - Feel free to remove any old news items. - ___ Make the last change to the documentation area on python.org. (Remember those from the documentation items above? It's time now.) @@ -560,11 +568,12 @@ ___ Check out a completely clean, virgin working directory of the trunk, by doing this in the directory that is the parent of your branch working directory python-XYaZ: - % cvs -d co -d python-clean python/dist/src + % svn co \ + svn+ssh://pythondev at svn.python.org/python/trunk python-clean ___ Run a diff against your branch by doing this in the common parent directory containing both python-clean and python-XYaZ: - % diff -r python-clean python-25a2 | grep ^diff | grep -v CVS \ + % diff -r python-clean python-26a2 | grep ^diff | grep -v /.svn/ \ > /tmp/diffcmd.sh ___ Edit diffcmd.sh to get rid of files that you know don't have @@ -594,7 +603,7 @@ patch, try using -p0 instead of -p1. Otherwise, your diff command was messed up, so try again. - ___ cd to python-clean and do a "cvs commit". Use as your log + ___ cd to python-clean and do a "svn commit". Use as your log message something like "Merging the rXYaZ-maint tag back into the trunk". @@ -603,7 +612,7 @@ indicating that the trunk is going to be moving forward with development. E.g. the line should look like: - #define PY_VERSION "2.5a2+" + #define PY_VERSION "2.6a2+" Make sure that the other PY_ version macros contain the correct values. Commit this change. @@ -640,15 +649,6 @@ You've just made a Python release! - Actually, there is one more step. You should turn over ownership - of the branch to Jack Jansen. All this means is that now he will - be responsible for making commits to the branch. He's going to - use this to build the MacOS versions. He may send you information - about the Mac release that should be merged into the informational - pages on www.python.org. When he's done, he'll tag the branch - something like "rX.YaZ-mac". He'll also be responsible for - merging any Mac-related changes back into the trunk. - Final Release Notes @@ -658,13 +658,10 @@ of weeks, but final releases can last for years!). For this reason we want to have a higher coordination between the - three major releases: Windows, Mac, and source. The Windows and - source releases benefit from the close proximity of the respective - release-bots. But the Mac-bot, Jack Jansen, is 6 hours away. So - we add this extra step to the release process for a final - release: + three major releases: Windows, Mac, and source. So we add this + extra step to the release process for a final release: - ___ Hold up the final release until Jack approves, or until we + ___ Hold up the final release until the WE and ME approve, or until we lose patience . @@ -675,7 +672,7 @@ precompiled "foreign" binaries (Tcl/Tk, expat, etc). So Windows testing is tiresome but very necessary. - Concurrent with uploading the installer, Martin installs Python + Concurrent with uploading the installer, the WE installs Python from it twice: once into the default directory suggested by the installer, and later into a directory with embedded spaces in its name. For each installation, he runs the full regression suite @@ -687,8 +684,8 @@ Help -> Python Documentation works. When trying pydoc this way (the "Module Docs" Start menu entry), make sure the "Start Browser" button works, and make sure you can search for a random - module (Tim uses "random" ) and then that the "go to - selected" button works. + module (like "random" ) and then that the "go to selected" + button works. It's amazing how much can go wrong here -- and even more amazing how often last-second checkins break one of these things. If @@ -701,7 +698,7 @@ can, also test the installer on Windows 9x. WRT Step 5 above (verify the release media), since by the time - release files are ready to download Tim has generally run many + release files are ready to download the WE has generally run many Windows tests on the installer he uploaded, he usually doesn't do anything for Step 5 except a full byte-comparison ("fc /b" if using a Windows shell) of the downloaded file against the file he From python-checkins at python.org Fri Jan 18 03:26:16 2008 From: python-checkins at python.org (andrew.kuchling) Date: Fri, 18 Jan 2008 03:26:16 +0100 (CET) Subject: [Python-checkins] r60033 - python/trunk/Doc/howto/curses.rst Message-ID: <20080118022616.6DE0A1E400F@bag.python.org> Author: andrew.kuchling Date: Fri Jan 18 03:26:16 2008 New Revision: 60033 Modified: python/trunk/Doc/howto/curses.rst Log: Bump verson Modified: python/trunk/Doc/howto/curses.rst ============================================================================== --- python/trunk/Doc/howto/curses.rst (original) +++ python/trunk/Doc/howto/curses.rst Fri Jan 18 03:26:16 2008 @@ -3,7 +3,7 @@ ********************************** :Author: A.M. Kuchling, Eric S. Raymond -:Release: 2.02 +:Release: 2.03 .. topic:: Abstract From python-checkins at python.org Fri Jan 18 03:42:52 2008 From: python-checkins at python.org (andrew.kuchling) Date: Fri, 18 Jan 2008 03:42:52 +0100 (CET) Subject: [Python-checkins] r60034 - python/trunk/Doc/library/sched.rst Message-ID: <20080118024252.924E51E400F@bag.python.org> Author: andrew.kuchling Date: Fri Jan 18 03:42:52 2008 New Revision: 60034 Modified: python/trunk/Doc/library/sched.rst Log: Typo fix Modified: python/trunk/Doc/library/sched.rst ============================================================================== --- python/trunk/Doc/library/sched.rst (original) +++ python/trunk/Doc/library/sched.rst Fri Jan 18 03:42:52 2008 @@ -43,7 +43,7 @@ In multi-threaded environments, the :class:`scheduler` class has limitations with respect to thread-safety, inability to insert a new task before -the one currently pending in a running scheduler, and holding-up the main +the one currently pending in a running scheduler, and holding up the main thread until the event queue is empty. Instead, the preferred approach is to use the :class:`threading.Timer` class instead. From python-checkins at python.org Fri Jan 18 08:30:20 2008 From: python-checkins at python.org (christian.heimes) Date: Fri, 18 Jan 2008 08:30:20 +0100 (CET) Subject: [Python-checkins] r60035 - python/trunk/Modules/zipimport.c Message-ID: <20080118073020.EEEEC1E4012@bag.python.org> Author: christian.heimes Date: Fri Jan 18 08:30:20 2008 New Revision: 60035 Modified: python/trunk/Modules/zipimport.c Log: Coverity issue CID #197 var_decl: Declared variable "stm" without initializer ninit_use_in_call: Using uninitialized value "stm" (field "stm".tm_zone uninitialized) in call to function "mktime" Modified: python/trunk/Modules/zipimport.c ============================================================================== --- python/trunk/Modules/zipimport.c (original) +++ python/trunk/Modules/zipimport.c Fri Jan 18 08:30:20 2008 @@ -1001,6 +1001,8 @@ { struct tm stm; + memset((void *) &stm, '\0', sizeof(stm)); + stm.tm_sec = (dostime & 0x1f) * 2; stm.tm_min = (dostime >> 5) & 0x3f; stm.tm_hour = (dostime >> 11) & 0x1f; From python-checkins at python.org Fri Jan 18 08:45:30 2008 From: python-checkins at python.org (christian.heimes) Date: Fri, 18 Jan 2008 08:45:30 +0100 (CET) Subject: [Python-checkins] r60036 - python/trunk/Parser/pgen.c Message-ID: <20080118074530.9BBA41E4013@bag.python.org> Author: christian.heimes Date: Fri Jan 18 08:45:30 2008 New Revision: 60036 Modified: python/trunk/Parser/pgen.c Log: Coverity issue CID #167 Event alloc_fn: Called allocation function "metacompile" [model] Event var_assign: Assigned variable "gr" to storage returned from "metacompile" gr = metacompile(n); Event pass_arg: Variable "gr" not freed or pointed-to in function "maketables" [model] g = maketables(gr); translatelabels(g); addfirstsets(g); Event leaked_storage: Returned without freeing storage "gr" return g; Modified: python/trunk/Parser/pgen.c ============================================================================== --- python/trunk/Parser/pgen.c (original) +++ python/trunk/Parser/pgen.c Fri Jan 18 08:45:30 2008 @@ -667,6 +667,7 @@ g = maketables(gr); translatelabels(g); addfirstsets(g); + PyObject_FREE(gr); return g; } From buildbot at python.org Fri Jan 18 08:59:53 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 18 Jan 2008 07:59:53 +0000 Subject: [Python-checkins] buildbot failure in x86 gentoo trunk Message-ID: <20080118075954.0239B1E4013@bag.python.org> The Buildbot has detected a new failure of x86 gentoo trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20gentoo%20trunk/builds/2908 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-x86 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: andrew.kuchling,christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_xmlrpc make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Fri Jan 18 09:01:21 2008 From: python-checkins at python.org (thomas.heller) Date: Fri, 18 Jan 2008 09:01:21 +0100 (CET) Subject: [Python-checkins] r60037 - peps/trunk/pep-3118.txt Message-ID: <20080118080121.49AA81E4013@bag.python.org> Author: thomas.heller Date: Fri Jan 18 09:01:20 2008 New Revision: 60037 Modified: peps/trunk/pep-3118.txt Log: Fix typo. Modified: peps/trunk/pep-3118.txt ============================================================================== --- peps/trunk/pep-3118.txt (original) +++ peps/trunk/pep-3118.txt Fri Jan 18 09:01:20 2008 @@ -686,7 +686,7 @@ 'w' ucs-4 'O' pointer to Python Object 'Z' complex (whatever the next specifier is) -'&' specific pointer (prefix before another charater) +'&' specific pointer (prefix before another character) 'T{}' structure (detailed layout inside {}) '(k1,k2,...,kn)' multi-dimensional array of whatever follows ':name:' optional name of the preceeding element From python-checkins at python.org Fri Jan 18 09:04:57 2008 From: python-checkins at python.org (christian.heimes) Date: Fri, 18 Jan 2008 09:04:57 +0100 (CET) Subject: [Python-checkins] r60038 - python/trunk/Modules/_elementtree.c Message-ID: <20080118080457.834911E402E@bag.python.org> Author: christian.heimes Date: Fri Jan 18 09:04:57 2008 New Revision: 60038 Modified: python/trunk/Modules/_elementtree.c Log: Coverity issue CID #182 size_error: Allocating 1 bytes to pointer "children", which needs at least 4 bytes Modified: python/trunk/Modules/_elementtree.c ============================================================================== --- python/trunk/Modules/_elementtree.c (original) +++ python/trunk/Modules/_elementtree.c Fri Jan 18 09:04:57 2008 @@ -369,7 +369,17 @@ if (size > self->extra->allocated) { /* use Python 2.4's list growth strategy */ size = (size >> 3) + (size < 9 ? 3 : 6) + size; + /* Coverity CID #182 size_error: Allocating 1 bytes to pointer "children" + * which needs at least 4 bytes. + * Although it's a false alarm always assume at least one child to + * be safe. + */ + size = size ? size : 1; if (self->extra->children != self->extra->_children) { + /* Coverity CID #182 size_error: Allocating 1 bytes to pointer + * "children", which needs at least 4 bytes. Although it's a + * false alarm always assume at least one child to be safe. + */ children = PyObject_Realloc(self->extra->children, size * sizeof(PyObject*)); if (!children) From python-checkins at python.org Fri Jan 18 09:36:51 2008 From: python-checkins at python.org (christian.heimes) Date: Fri, 18 Jan 2008 09:36:51 +0100 (CET) Subject: [Python-checkins] r60039 - peps/trunk/pep-0754.txt Message-ID: <20080118083651.59D331E402E@bag.python.org> Author: christian.heimes Date: Fri Jan 18 09:36:51 2008 New Revision: 60039 Modified: peps/trunk/pep-0754.txt Log: Updated PEP 754 to mention the new Python 2.6 features. Modified: peps/trunk/pep-0754.txt ============================================================================== --- peps/trunk/pep-0754.txt (original) +++ peps/trunk/pep-0754.txt Fri Jan 18 09:36:51 2008 @@ -17,6 +17,24 @@ This PEP has been rejected. After sitting open for four years, it has failed to generate sufficient community interest. +Several ideas of this PEP were implemented for Python 2.6. ``float('inf')`` +and ``repr(float('inf'))`` are now guaranteed to work on every supported +platform with IEEE 754 semantics. However the ``eval(repr(float('inf')))`` +roundtrip is still not supported unless you define inf and nan yourself:: + + >>> inf = float('inf') + >>> inf, 1E400 + (inf, inf) + >>> neginf = float('-inf') + >>> neginf, -1E400 + (-inf, -inf) + >>> nan = float('nan') + >>> nan, inf * 0. + (nan, nan) + +The math and the sys module also have gained additional features, +``sys.float_info``, ``math.isinf``, ``math.isnan``, ``math.copysign``. + Abstract ======== From python-checkins at python.org Fri Jan 18 09:37:17 2008 From: python-checkins at python.org (christian.heimes) Date: Fri, 18 Jan 2008 09:37:17 +0100 (CET) Subject: [Python-checkins] r60040 - peps/trunk/pep-0370.txt Message-ID: <20080118083717.3C3811E4015@bag.python.org> Author: christian.heimes Date: Fri Jan 18 09:37:16 2008 New Revision: 60040 Modified: peps/trunk/pep-0370.txt Log: Fixed a typo usecustomize -> usercustomize Modified: peps/trunk/pep-0370.txt ============================================================================== --- peps/trunk/pep-0370.txt (original) +++ peps/trunk/pep-0370.txt Fri Jan 18 09:37:16 2008 @@ -161,7 +161,7 @@ * Mac: Should framework and non-framework builds of Python use the same directories? -* The patch also adds a usecustomize hook to site. Is it useful and +* The patch also adds a usercustomize hook to site. Is it useful and should it stay? * Should the site package directory also be ignored if process gid != From python-checkins at python.org Fri Jan 18 09:47:59 2008 From: python-checkins at python.org (christian.heimes) Date: Fri, 18 Jan 2008 09:47:59 +0100 (CET) Subject: [Python-checkins] r60041 - python/trunk/Python/traceback.c Message-ID: <20080118084759.738641E4013@bag.python.org> Author: christian.heimes Date: Fri Jan 18 09:47:59 2008 New Revision: 60041 Modified: python/trunk/Python/traceback.c Log: Coverity issue CID #169 local_ptr_assign_local: Assigning address of stack variable "namebuf" to pointer "filename" out_of_scope: Variable "namebuf" goes out of scope use_invalid: Used "filename" pointing to out-of-scope variable "namebuf" Modified: python/trunk/Python/traceback.c ============================================================================== --- python/trunk/Python/traceback.c (original) +++ python/trunk/Python/traceback.c Fri Jan 18 09:47:59 2008 @@ -129,6 +129,8 @@ FILE *xfp; char linebuf[2000]; int i; + char namebuf[MAXPATHLEN+1]; + if (filename == NULL || name == NULL) return -1; /* This is needed by Emacs' compile command */ @@ -147,7 +149,6 @@ Py_ssize_t _npath = PyList_Size(path); int npath = Py_SAFE_DOWNCAST(_npath, Py_ssize_t, int); size_t taillen = strlen(tail); - char namebuf[MAXPATHLEN+1]; for (i = 0; i < npath; i++) { PyObject *v = PyList_GetItem(path, i); if (v == NULL) { From python-checkins at python.org Fri Jan 18 09:53:46 2008 From: python-checkins at python.org (christian.heimes) Date: Fri, 18 Jan 2008 09:53:46 +0100 (CET) Subject: [Python-checkins] r60042 - python/trunk/Modules/main.c Message-ID: <20080118085346.23A881E4013@bag.python.org> Author: christian.heimes Date: Fri Jan 18 09:53:45 2008 New Revision: 60042 Modified: python/trunk/Modules/main.c Log: Coverity CID #168 leaked_storage: Returned without freeing storage "fp" Modified: python/trunk/Modules/main.c ============================================================================== --- python/trunk/Modules/main.c (original) +++ python/trunk/Modules/main.c Fri Jan 18 09:53:45 2008 @@ -565,6 +565,7 @@ if (fstat(fileno(fp), &sb) == 0 && S_ISDIR(sb.st_mode)) { fprintf(stderr, "%s: '%s' is a directory, cannot continue\n", argv[0], filename); + fclose(fp); return 1; } } From python-checkins at python.org Fri Jan 18 10:51:44 2008 From: python-checkins at python.org (christian.heimes) Date: Fri, 18 Jan 2008 10:51:44 +0100 (CET) Subject: [Python-checkins] r60043 - python/trunk/setup.py Message-ID: <20080118095144.107C41E4020@bag.python.org> Author: christian.heimes Date: Fri Jan 18 10:51:43 2008 New Revision: 60043 Modified: python/trunk/setup.py Log: Build _ctypes after the other extensions. Its build process depends on the _weakref extension (and maybe other modules, too) Modified: python/trunk/setup.py ============================================================================== --- python/trunk/setup.py (original) +++ python/trunk/setup.py Fri Jan 18 10:51:43 2008 @@ -101,8 +101,14 @@ missing = self.detect_modules() # Remove modules that are present on the disabled list - self.extensions = [ext for ext in self.extensions - if ext.name not in disabled_module_list] + extensions = [ext for ext in self.extensions + if ext.name not in disabled_module_list] + # move ctypes to the end, it depends on other modules + ext_map = dict((ext.name, i) for i, ext in enumerate(extensions)) + if "_ctypes" in ext_map: + ctypes = extensions.pop(ext_map["_ctypes"]) + extensions.append(ctypes) + self.extensions = extensions # Fix up the autodetected modules, prefixing all the source files # with Modules/ and adding Python's include directory to the path. From buildbot at python.org Fri Jan 18 12:03:13 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 18 Jan 2008 11:03:13 +0000 Subject: [Python-checkins] buildbot failure in x86 XP-4 3.0 Message-ID: <20080118110313.47CE61E403D@bag.python.org> The Buildbot has detected a new failure of x86 XP-4 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20XP-4%203.0/builds/428 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-windows Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: sincerely, -The Buildbot From python-checkins at python.org Fri Jan 18 12:09:19 2008 From: python-checkins at python.org (christian.heimes) Date: Fri, 18 Jan 2008 12:09:19 +0100 (CET) Subject: [Python-checkins] r60045 - peps/trunk/pep-0370.txt Message-ID: <20080118110919.0B5711E4013@bag.python.org> Author: christian.heimes Date: Fri Jan 18 12:09:18 2008 New Revision: 60045 Modified: peps/trunk/pep-0370.txt Log: PEP 370 update I added or changed some points of the PEP as discussed on the mailing list recently Modified: peps/trunk/pep-0370.txt ============================================================================== --- peps/trunk/pep-0370.txt (original) +++ peps/trunk/pep-0370.txt Fri Jan 18 12:09:18 2008 @@ -53,9 +53,7 @@ directory is specific to a Python version. The path contains the version number (major and minor only). - Mac - ``~/Library/Python/2.6/site-packages`` - Unix + Unix (including Mac) ``~/.local/lib/python2.6/site-packages`` Windows ``%APPDATA%/Python/Python26/site-packages`` @@ -66,9 +64,7 @@ for Python version specific data like config files, docs, images and translations. - Mac - ``~/Library/Python/2.6`` - Unix + Unix (including Mac) ``~/.local/lib/python2.6`` Windows ``%APPDATA%/Python/Python26`` @@ -79,9 +75,7 @@ use config directory are inside the base directory. On some systems the directory may be shared with 3rd party apps. - Mac - ``~/Library/Python`` - Unix + Unix (including Mac) ``~/.local`` Windows ``%APPDATA%/Python`` @@ -91,24 +85,46 @@ A directory for binaries and scripts. [10]_ It's shared across Python versions and the destination directory for scripts. - Mac - ``~/Library/Python/bin`` - Unix + Unix (including Mac) ``~/.local/bin`` Windows ``%APPDATA%/Python/Scripts`` -On Windows ``APPDATA`` was chosen because it is the most logical place for -application data. Microsoft recommands that software doesn't write to -``USERPROFILE`` [5]_ and ``My Documents`` is not suited for application data, -too. [8]_ +Windows Notes +------------- -On Linux ``~/.local`` was chosen in favor over ``~/.python`` because the +On Windows the *Application Data* directory (aka ``APPDATA``) was chosen +because it is the most designated place for application data. Microsoft +recommands that software doesn't write to ``USERPROFILE`` [5]_ and +``My Documents`` is not suited for application data, too. [8]_ The code +doesn't query the Win32 API, instead it uses the environment variable +%APPDATA%. + +The application data directory is part of the roaming profile. In networks +with domain logins the application data may be copied from and to the a +central server. This can slow down log-in and log-off. Users can keep +the data on the server by e.g. setting PYTHONUSERBASE to the value +"%HOMEDRIVE%%HOMEPATH%\Applicata Data". Users should consult their local +adminstrator for more information. [13]_ + + +Unix Notes +---------- + +On Unix ``~/.local`` was chosen in favor over ``~/.python`` because the directory is already used by several other programs in analogy to ``/usr/local``. [7]_ [11]_ +Mac OS X Notes +-------------- + +On Mac OS X Python uses ~/.local directory as well. [12]_ Framework builds +if Python include ``~/Library/Python/2.6/site-packages`` as an additional +search path. + + Implementation ============== @@ -126,9 +142,10 @@ ``PYTHONPATH``. For security reasons the user site directory is *not* added to -``sys.path`` when the effective user id is not equal to the process -user id [9]_. It prevents users from injecting Python code into suid -apps. +``sys.path`` when the effective user id or group id is not equal to the +process uid / gid [9]_. It's an additional barrier against code injection +into suid apps. However Python suid scripts *must* always use the -E +and -s option or users can sneak in their own code. The user site directory can be suppressed with a new option ``-s`` or the environment variable ``PYTHONNOUSERSITE``. The feature can be @@ -136,6 +153,10 @@ ``False``. It must be set by editing ``site.py``. It can't be altered ``in sitecustomize.py`` or later. +The path to the user base directory can be overwritten with the +environment variable ``PYTHONUSERBASE``. The default location is used +when ``PYTHONUSERBASE`` is not set or empty. + ``distutils.command.install`` (setup.py install) gets a new argument ``--user`` to install packages in the user site directory. The required directories are created on demand. @@ -153,27 +174,6 @@ TBD -Open Questions -============== - -* Are the directories for Windows, Mac and Unix fine? - -* Mac: Should framework and non-framework builds of Python use the - same directories? - -* The patch also adds a usercustomize hook to site. Is it useful and - should it stay? - -* Should the site package directory also be ignored if process gid != - effective gid? - -* Should the Windows installer add ``%APPDATA%/Python/Scripts`` to - ``PATH``? - -* Should the base directory be configurable with an environment variable - like ``PYTHONUSERHOME``? - - Reference Implementation ======================== @@ -224,6 +224,12 @@ .. [11] freedesktop.org XGD basedir specs mentions ~/.local http://www.freedesktop.org/wiki/Specifications/basedir-spec +.. [12] ~/.local for Mac and usercustomize file + http://permalink.gmane.org/gmane.comp.python.devel/91167 + +.. [13] Roaming profile on Windows + http://permalink.gmane.org/gmane.comp.python.devel/91187 + .. Local Variables: mode: indented-text From python-checkins at python.org Fri Jan 18 12:09:23 2008 From: python-checkins at python.org (christian.heimes) Date: Fri, 18 Jan 2008 12:09:23 +0100 (CET) Subject: [Python-checkins] r60046 - in sandbox/trunk/pep370/Lib: site.py test/test_site.py Message-ID: <20080118110923.2CD001E4014@bag.python.org> Author: christian.heimes Date: Fri Jan 18 12:09:22 2008 New Revision: 60046 Modified: sandbox/trunk/pep370/Lib/site.py sandbox/trunk/pep370/Lib/test/test_site.py Log: Follow up on PEP 370 update Modified: sandbox/trunk/pep370/Lib/site.py ============================================================================== --- sandbox/trunk/pep370/Lib/site.py (original) +++ sandbox/trunk/pep370/Lib/site.py Fri Jan 18 12:09:22 2008 @@ -190,7 +190,7 @@ """Check if user site directory is safe for inclusion The functions tests for the command line flag (including environment var), - process uid equal to effective uid. + process uid/gid equal to effective uid/gid. None: Disabled for security reasons False: Disabled by user (command line option) @@ -203,6 +203,10 @@ # check process uid == effective uid if os.geteuid() != os.getuid(): return None + if hasattr(os, "getgid") and hasattr(os, "getegid"): + # check process gid == effective gid + if os.getegid() != os.getgid(): + return None return True @@ -219,6 +223,8 @@ configuration data. """ global USER_BASE, USER_SITE + env_base = os.environ.get("PYTHONUSERBASE", None) + def joinuser(*args): return os.path.expanduser(os.path.join(*args)) @@ -226,21 +232,17 @@ # # Don't know what to put here # USER_BASE = '' # USER_SITE = '' - if sys.platform == "darwin": - USER_BASE = joinuser("~", "Library", "Python") - USER_SITE = os.path.join(USER_BASE, sys.version[:3], - "site-packages") - elif os.name == "nt": + if os.name == "nt": base = os.environ.get("APPDATA") or "~" - USER_BASE = joinuser(base, "Python") + USER_BASE = env_base if env_base else joinuser(base, "Python") USER_SITE = os.path.join(USER_BASE, "Python" + sys.version[0] + sys.version[2], "site-packages") else: - USER_BASE = joinuser("~", ".local") - USER_SITE = os.path.join(USER_BASE, "lib", - "python" + sys.version[:3], - "site-packages") + USER_BASE = env_base if env_base else joinuser("~", ".local") + USER_SITE = os.path.join(USER_BASE, "lib", + "python" + sys.version[:3], + "site-packages") if os.path.isdir(USER_SITE): addsitedir(USER_SITE, known_paths) @@ -268,15 +270,15 @@ sitedirs.append(prefix) sitedirs.append(os.path.join(prefix, "lib", "site-packages")) - #if sys.platform == "darwin": - # # for framework builds *only* we add the standard Apple - # # locations. Currently only per-user, but /Library and - # # /Network/Library could be added too - # if 'Python.framework' in prefix: - # sitedirs.append( - # os.path.expanduser( - # os.path.join("~", "Library", "Python", - # sys.version[:3], "site-packages"))) + if sys.platform == "darwin": + # for framework builds *only* we add the standard Apple + # locations. Currently only per-user, but /Library and + # /Network/Library could be added too + if 'Python.framework' in prefix: + sitedirs.append( + os.path.expanduser( + os.path.join("~", "Library", "Python", + sys.version[:3], "site-packages"))) for sitedir in sitedirs: if os.path.isdir(sitedir): Modified: sandbox/trunk/pep370/Lib/test/test_site.py ============================================================================== --- sandbox/trunk/pep370/Lib/test/test_site.py (original) +++ sandbox/trunk/pep370/Lib/test/test_site.py Fri Jan 18 12:09:22 2008 @@ -111,6 +111,13 @@ env=env) self.assertEqual(rc, 0) + env = os.environ.copy() + env["PYTHONUSERBASE"] = "/tmp" + rc = subprocess.call([sys.executable, '-c', + 'import sys, user; sys.exit(user.USER_BASE.startswith("tmp"))'], + env=env) + self.assertEqual(rc, 1) + class PthFile(object): """Helper class for handling testing of .pth files""" From python-checkins at python.org Fri Jan 18 12:30:35 2008 From: python-checkins at python.org (christian.heimes) Date: Fri, 18 Jan 2008 12:30:35 +0100 (CET) Subject: [Python-checkins] r60047 - sandbox/trunk/pep370/Lib/test/test_site.py Message-ID: <20080118113035.069F61E4013@bag.python.org> Author: christian.heimes Date: Fri Jan 18 12:30:34 2008 New Revision: 60047 Modified: sandbox/trunk/pep370/Lib/test/test_site.py Log: Fixed unit test Modified: sandbox/trunk/pep370/Lib/test/test_site.py ============================================================================== --- sandbox/trunk/pep370/Lib/test/test_site.py (original) +++ sandbox/trunk/pep370/Lib/test/test_site.py Fri Jan 18 12:30:34 2008 @@ -114,7 +114,7 @@ env = os.environ.copy() env["PYTHONUSERBASE"] = "/tmp" rc = subprocess.call([sys.executable, '-c', - 'import sys, user; sys.exit(user.USER_BASE.startswith("tmp"))'], + 'import sys, site; sys.exit(site.USER_BASE.startswith("/tmp"))'], env=env) self.assertEqual(rc, 1) From python-checkins at python.org Fri Jan 18 12:58:51 2008 From: python-checkins at python.org (christian.heimes) Date: Fri, 18 Jan 2008 12:58:51 +0100 (CET) Subject: [Python-checkins] r60048 - in python/trunk: Doc/builddoc.bat Misc/NEWS Tools/scripts/win_add2path.py Message-ID: <20080118115851.6055F1E4013@bag.python.org> Author: christian.heimes Date: Fri Jan 18 12:58:50 2008 New Revision: 60048 Added: python/trunk/Doc/builddoc.bat python/trunk/Tools/scripts/win_add2path.py (contents, props changed) Modified: python/trunk/Misc/NEWS Log: Added win_add2path.py to Tools/scripts/ Added builddoc.bat to Doc/ Added: python/trunk/Doc/builddoc.bat ============================================================================== --- (empty file) +++ python/trunk/Doc/builddoc.bat Fri Jan 18 12:58:50 2008 @@ -0,0 +1,52 @@ + at echo off +setlocal + +set SVNROOT=http://svn.python.org/projects +if "%PYTHON%" EQU "" set PYTHON=python25 + +if "%1" EQU "" goto help +if "%1" EQU "html" goto build +if "%1" EQU "htmlhelp" goto build +if "%1" EQU "web" goto build +if "%1" EQU "webrun" goto webrun +if "%1" EQU "checkout" goto checkout +if "%1" EQU "update" goto update + +:help +echo HELP +echo. +echo builddoc checkout +echo builddoc update +echo builddoc html +echo builddoc htmlhelp +echo builddoc web +echo builddoc webrun +echo. +goto end + +:checkout +svn co %SVNROOT%/doctools/trunk/sphinx tools/sphinx +svn co %SVNROOT%/external/docutils-0.4/docutils tools/docutils +svn co %SVNROOT%/external/Pygments-0.9/pygments tools/pygments +goto end + +:update +svn update tools/sphinx +svn update tools/docutils +svn update tools/pygments +goto end + +:build +if not exist build mkdir build +if not exist build\%1 mkdir build\%1 +if not exist build\doctrees mkdir build\doctrees +cmd /C %PYTHON% tools\sphinx-build.py -b%1 -dbuild\doctrees . build\%1 +if "%1" EQU "htmlhelp" "%ProgramFiles%\HTML Help Workshop\hhc.exe" build\htmlhelp\pydoc.hhp +goto end + +:webrun +set PYTHONPATH=tools +%PYTHON% -m sphinx.web build\web +goto end + +:end Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Fri Jan 18 12:58:50 2008 @@ -1196,6 +1196,10 @@ Tools ----- +- Tools/scripts/win_add2path.py was added. The simple script modifes the + PATH environment var of the HKCU tree and adds the python bin and script + directory. + - Tools/18n/pygettext.py was added to the list of scripts installed by Tools/scripts/setup.py (tracker item 642309). Added: python/trunk/Tools/scripts/win_add2path.py ============================================================================== --- (empty file) +++ python/trunk/Tools/scripts/win_add2path.py Fri Jan 18 12:58:50 2008 @@ -0,0 +1,57 @@ +"""Add Python to the search path on Windows + +This is a simple script to add Python to the Windows search path. It +modifies the current user (HKCU) tree of the registry. + +Copyright (c) 2008 by Christian Heimes +Licensed to PSF under a Contributor Agreement. +""" + +import sys +import site +import os +import _winreg + +HKCU = _winreg.HKEY_CURRENT_USER +ENV = "Environment" +PATH = "PATH" +DEFAULT = u"%PATH%" + +def modify(): + pythonpath = os.path.dirname(os.path.normpath(sys.executable)) + scripts = os.path.join(pythonpath, "Scripts") + appdata = os.environ["APPDATA"] + if hasattr(site, "USER_SITE"): + userpath = site.USER_SITE.replace(appdata, "%APPDATA%") + userscripts = os.path.join(userpath, "Scripts") + else: + userscripts = None + + with _winreg.CreateKey(HKCU, ENV) as key: + try: + envpath = _winreg.QueryValueEx(key, PATH)[0] + except WindowsError: + envpath = DEFAULT + + paths = [envpath] + for path in (pythonpath, scripts, userscripts): + if path and path not in envpath and os.path.isdir(path): + paths.append(path) + + envpath = os.pathsep.join(paths) + _winreg.SetValueEx(key, PATH, 0, _winreg.REG_EXPAND_SZ, envpath) + return paths, envpath + +def main(): + paths, envpath = modify() + if len(paths) > 1: + print "Path(s) added:" + print '\n'.join(paths[1:]) + else: + print "No path was added" + print "\nPATH is now:\n%s\n" % envpath + print "Expanded:" + print _winreg.ExpandEnvironmentStrings(envpath) + +if __name__ == '__main__': + main() From python-checkins at python.org Fri Jan 18 16:54:14 2008 From: python-checkins at python.org (vinay.sajip) Date: Fri, 18 Jan 2008 16:54:14 +0100 (CET) Subject: [Python-checkins] r60049 - python/trunk/Doc/library/logging.rst Message-ID: <20080118155414.A91261E4013@bag.python.org> Author: vinay.sajip Date: Fri Jan 18 16:54:14 2008 New Revision: 60049 Modified: python/trunk/Doc/library/logging.rst Log: Added section on passing contextual information to logging and documentation for the LoggerAdapter class. Modified: python/trunk/Doc/library/logging.rst ============================================================================== --- python/trunk/Doc/library/logging.rst (original) +++ python/trunk/Doc/library/logging.rst Fri Jan 18 16:54:14 2008 @@ -1155,33 +1155,113 @@ be hard to manage if the number of :class:`Logger` instances becomes effectively unbounded. -There are a number of other ways you can pass contextual information to be -output along with logging event information. +An easy way in which you can pass contextual information to be output along +with logging event information is to use the :class:`LoggerAdapter` class. +This class is designed to look like a :class:`Logger`, so that you can call +:meth:`debug`, :meth:`info`, :meth:`warning`, :meth:`error`, +:meth:`exception`, :meth:`critical` and :meth:`log`. These methods have the +same signatures as their counterparts in :class:`Logger`, so you can use the +two types of instances interchangeably. + +When you create an instance of :class:`LoggerAdapter`, you pass it a +:class:`Logger` instance and a dict-like object which contains your contextual +information. When you call one of the logging methods on an instance of +:class:`LoggerAdapter`, it delegates the call to the underlying instance of +:class:`Logger` passed to its constructor, and arranges to pass the contextual +information in the delegated call. Here's a snippet from the code of +:class:`LoggerAdapter`:: + + def debug(self, msg, *args, **kwargs): + """ + Delegate a debug call to the underlying logger, after adding + contextual information from this adapter instance. + """ + msg, kwargs = self.process(msg, kwargs) + self.logger.debug(msg, *args, **kwargs) + +The :meth:`process` method of :class:`LoggerAdapter` is where the contextual +information is added to the logging output. It's passed the message and +keyword arguments of the logging call, and it passes back (potentially) +modified versions of these to use in the call to the underlying logger. The +default implementation of this method leaves the message alone, but inserts +an "extra" key in the keyword argument whose value is the dict-like object +passed to the constructor. Of course, if you had passed an "extra" keyword +argument in the call to the adapter, it will be silently overwritten. + +The advantage of using "extra" is that the values in the dict-like object are +merged into the :class:`LogRecord` instance's __dict__, allowing you to use +customized strings with your :class:`Formatter` instances which know about +the keys of the dict-like object. If you need a different method, e.g. if you +want to prepend or append the contextual information to the message string, +you just need to subclass :class:`LoggerAdapter` and override :meth:`process` +to do what you need. Here's an example script which uses this class, which +also illustrates what dict-like behaviour is needed from an arbitrary +"dict-like" object for use in the constructor:: + +import logging + +class ConnInfo: + """ + An example class which shows how an arbitrary class can be used as + the 'extra' context information repository passed to a LoggerAdapter. + """ + + def __getitem__(self, name): + """ + To allow this instance to look like a dict. + """ + from random import choice + if name == "ip": + result = choice(["127.0.0.1", "192.168.0.1"]) + elif name == "user": + result = choice(["jim", "fred", "sheila"]) + else: + result = self.__dict__.get(name, "?") + return result + + def __iter__(self): + """ + To allow iteration over keys, which will be merged into + the LogRecord dict before formatting and output. + """ + keys = ["ip", "user"] + keys.extend(self.__dict__.keys()) + return keys.__iter__() + +if __name__ == "__main__": + from random import choice + levels = (logging.DEBUG, logging.INFO, logging.WARNING, logging.ERROR, logging.CRITICAL) + a1 = logging.LoggerAdapter(logging.getLogger("a.b.c"), + { "ip" : "123.231.231.123", "user" : "sheila" }) + logging.basicConfig(level=logging.DEBUG, + format="%(asctime)-15s %(name)-5s %(levelname)-8s IP: %(ip)-15s User: %(user)-8s %(message)s") + a1.debug("A debug message") + a1.info("An info message with %s", "some parameters") + a2 = logging.LoggerAdapter(logging.getLogger("d.e.f"), ConnInfo()) + for x in range(10): + lvl = choice(levels) + lvlname = logging.getLevelName(lvl) + a2.log(lvl, "A message at %s level with %d %s", lvlname, 2, "parameters") + +When this script is run, the output should look something like this:: + +2008-01-18 14:49:54,023 a.b.c DEBUG IP: 123.231.231.123 User: sheila A debug message +2008-01-18 14:49:54,023 a.b.c INFO IP: 123.231.231.123 User: sheila An info message with some parameters +2008-01-18 14:49:54,023 d.e.f CRITICAL IP: 192.168.0.1 User: jim A message at CRITICAL level with 2 parameters +2008-01-18 14:49:54,033 d.e.f INFO IP: 192.168.0.1 User: jim A message at INFO level with 2 parameters +2008-01-18 14:49:54,033 d.e.f WARNING IP: 192.168.0.1 User: sheila A message at WARNING level with 2 parameters +2008-01-18 14:49:54,033 d.e.f ERROR IP: 127.0.0.1 User: fred A message at ERROR level with 2 parameters +2008-01-18 14:49:54,033 d.e.f ERROR IP: 127.0.0.1 User: sheila A message at ERROR level with 2 parameters +2008-01-18 14:49:54,033 d.e.f WARNING IP: 192.168.0.1 User: sheila A message at WARNING level with 2 parameters +2008-01-18 14:49:54,033 d.e.f WARNING IP: 192.168.0.1 User: jim A message at WARNING level with 2 parameters +2008-01-18 14:49:54,033 d.e.f INFO IP: 192.168.0.1 User: fred A message at INFO level with 2 parameters +2008-01-18 14:49:54,033 d.e.f WARNING IP: 192.168.0.1 User: sheila A message at WARNING level with 2 parameters +2008-01-18 14:49:54,033 d.e.f WARNING IP: 127.0.0.1 User: jim A message at WARNING level with 2 parameters + +.. versionadded:: 2.6 + +The :class:`LoggerAdapter` class was not present in previous versions. -* Use an adapter class which has access to the contextual information and - which defines methods :meth:`debug`, :meth:`info` etc. with the same - signatures as used by :class:`Logger`. You instantiate the adapter with a - name, which will be used to create an underlying :class:`Logger` with that - name. In each adpater method, the passed-in message is modified to include - whatever contextual information you want. - -* Use something other than a string to pass the message. Although normally - the first argument to a logger method such as :meth:`debug`, :meth:`info` - etc. is usually a string, it can in fact be any object. This object is the - argument to a :func:`str()` call which is made, in - :meth:`LogRecord.getMessage`, to obtain the actual message string. You can - use this behavior to pass an instance which may be initialized with a - logging message, which redefines :meth:__str__ to return a modified version - of that message with the contextual information added. - -* Use a specialized :class:`Formatter` subclass to add additional information - to the formatted output. The subclass could, for instance, merge some thread - local contextual information (or contextual information obtained in some - other way) with the output generated by the base :class:`Formatter`. - -In each of these three approaches, thread locals can sometimes be a useful way -of passing contextual information without undue coupling between different -parts of your code. .. _network-logging: @@ -2077,6 +2157,33 @@ Returns the message for this :class:`LogRecord` instance after merging any user-supplied arguments with the message. +LoggerAdapter Objects +--------------------- + +.. versionadded:: 2.6 + +:class:`LoggerAdapter` instances are used to conveniently pass contextual +information into logging calls. For a usage example , see context-info_. + +.. class:: LoggerAdapter(logger, extra) + + Returns an instance of :class:`LoggerAdapter` initialized with an + underlying :class:`Logger` instance and a dict-like object. + +.. method:: LoggerAdapter.process(msg, kwargs) + + Modifies the message and/or keyword arguments passed to a logging call in + order to insert contextual information. This implementation takes the + object passed as *extra* to the constructor and adds it to *kwargs* using + key 'extra'. The return value is a (*msg*, *kwargs*) tuple which has the + (possibly modified) versions of the arguments passed in. + +In addition to the above, :class:`LoggerAdapter` supports all the logging +methods of :class:`Logger`, i.e. :meth:`debug`, :meth:`info`, :meth:`warning`, +:meth:`error`, :meth:`exception`, :meth:`critical` and :meth:`log`. These +methods have the same signatures as their counterparts in :class:`Logger`, so +you can use the two types of instances interchangeably. + Thread Safety ------------- From python-checkins at python.org Fri Jan 18 16:55:58 2008 From: python-checkins at python.org (vinay.sajip) Date: Fri, 18 Jan 2008 16:55:58 +0100 (CET) Subject: [Python-checkins] r60050 - python/trunk/Lib/logging/__init__.py Message-ID: <20080118155558.4A3E81E4013@bag.python.org> Author: vinay.sajip Date: Fri Jan 18 16:55:57 2008 New Revision: 60050 Modified: python/trunk/Lib/logging/__init__.py Log: Added LoggerAdapter class, changed copyright dates, made check for extra parameter passed to logging methods explicitly against None rather than a truth value. Modified: python/trunk/Lib/logging/__init__.py ============================================================================== --- python/trunk/Lib/logging/__init__.py (original) +++ python/trunk/Lib/logging/__init__.py Fri Jan 18 16:55:57 2008 @@ -1,4 +1,4 @@ -# Copyright 2001-2007 by Vinay Sajip. All Rights Reserved. +# Copyright 2001-2008 by Vinay Sajip. All Rights Reserved. # # Permission to use, copy, modify, and distribute this software and its # documentation for any purpose and without fee is hereby granted, @@ -21,7 +21,7 @@ Should work under Python versions >= 1.5.2, except that source line information is not available unless 'sys._getframe()' is. -Copyright (C) 2001-2007 Vinay Sajip. All Rights Reserved. +Copyright (C) 2001-2008 Vinay Sajip. All Rights Reserved. To use, simply 'import logging' and log away! """ @@ -41,8 +41,8 @@ __author__ = "Vinay Sajip " __status__ = "production" -__version__ = "0.5.0.3" -__date__ = "26 September 2007" +__version__ = "0.5.0.4" +__date__ = "18 January 2008" #--------------------------------------------------------------------------- # Miscellaneous module data @@ -1080,7 +1080,7 @@ specialized LogRecords. """ rv = LogRecord(name, level, fn, lno, msg, args, exc_info, func) - if extra: + if extra is not None: for key in extra: if (key in ["message", "asctime"]) or (key in rv.__dict__): raise KeyError("Attempt to overwrite %r in LogRecord" % key) @@ -1193,6 +1193,96 @@ _loggerClass = Logger +class LoggerAdapter: + """ + An adapter for loggers which makes it easier to specify contextual + information in logging output. + """ + + def __init__(self, logger, extra): + """ + Initialize the adapter with a logger and a dict-like object which + provides contextual information. This constructor signature allows + easy stacking of LoggerAdapters, if so desired. + + You can effectively pass keyword arguments as shown in the + following example: + + adapter = LoggerAdapter(someLogger, dict(p1=v1, p2="v2")) + """ + self.logger = logger + self.extra = extra + + def process(self, msg, kwargs): + """ + Process the logging message and keyword arguments passed in to + a logging call to insert contextual information. You can either + manipulate the message itself, the keyword args or both. Return + the message and kwargs modified (or not) to suit your needs. + + Normally, you'll only need to override this one method in a + LoggerAdapter subclass for your specific needs. + """ + kwargs["extra"] = self.extra + return msg, kwargs + + def debug(self, msg, *args, **kwargs): + """ + Delegate a debug call to the underlying logger, after adding + contextual information from this adapter instance. + """ + msg, kwargs = self.process(msg, kwargs) + self.logger.debug(msg, *args, **kwargs) + + def info(self, msg, *args, **kwargs): + """ + Delegate an info call to the underlying logger, after adding + contextual information from this adapter instance. + """ + msg, kwargs = self.process(msg, kwargs) + self.logger.info(msg, *args, **kwargs) + + def warning(self, msg, *args, **kwargs): + """ + Delegate a warning call to the underlying logger, after adding + contextual information from this adapter instance. + """ + msg, kwargs = self.process(msg, kwargs) + self.logger.warning(msg, *args, **kwargs) + + def error(self, msg, *args, **kwargs): + """ + Delegate an error call to the underlying logger, after adding + contextual information from this adapter instance. + """ + msg, kwargs = self.process(msg, kwargs) + self.logger.error(msg, *args, **kwargs) + + def exception(self, msg, *args, **kwargs): + """ + Delegate an exception call to the underlying logger, after adding + contextual information from this adapter instance. + """ + msg, kwargs = self.process(msg, kwargs) + kwargs["exc_info"] = 1 + self.logger.error(msg, *args, **kwargs) + + def critical(self, msg, *args, **kwargs): + """ + Delegate a critical call to the underlying logger, after adding + contextual information from this adapter instance. + """ + msg, kwargs = self.process(msg, kwargs) + self.logger.critical(msg, *args, **kwargs) + + def log(self, level, msg, *args, **kwargs): + """ + Delegate a log call to the underlying logger, after adding + contextual information from this adapter instance. + """ + msg, kwargs = self.process(msg, kwargs) + self.logger.log(level, msg, *args, **kwargs) + root = RootLogger(WARNING) Logger.root = root Logger.manager = Manager(Logger.root) From lists at cheimes.de Fri Jan 18 17:01:52 2008 From: lists at cheimes.de (Christian Heimes) Date: Fri, 18 Jan 2008 17:01:52 +0100 Subject: [Python-checkins] r60050 - python/trunk/Lib/logging/__init__.py In-Reply-To: <20080118155558.4A3E81E4013@bag.python.org> References: <20080118155558.4A3E81E4013@bag.python.org> Message-ID: <4790CD70.108@cheimes.de> vinay.sajip wrote: > Author: vinay.sajip > Date: Fri Jan 18 16:55:57 2008 > New Revision: 60050 > > Modified: > python/trunk/Lib/logging/__init__.py > Log: > Added LoggerAdapter class, changed copyright dates, made check for extra parameter passed to logging methods explicitly against None rather than a truth value. Please update Misc/NEWS, too Christian From python-checkins at python.org Fri Jan 18 17:42:57 2008 From: python-checkins at python.org (georg.brandl) Date: Fri, 18 Jan 2008 17:42:57 +0100 (CET) Subject: [Python-checkins] r60051 - python/trunk/Doc/reference/executionmodel.rst Message-ID: <20080118164258.001F91E4037@bag.python.org> Author: georg.brandl Date: Fri Jan 18 17:42:57 2008 New Revision: 60051 Modified: python/trunk/Doc/reference/executionmodel.rst Log: Note that genexps are function scopes too and therefore won't see class attributes. Modified: python/trunk/Doc/reference/executionmodel.rst ============================================================================== --- python/trunk/Doc/reference/executionmodel.rst (original) +++ python/trunk/Doc/reference/executionmodel.rst Fri Jan 18 17:42:57 2008 @@ -52,7 +52,13 @@ definition occurs in a function block, the scope extends to any blocks contained within the defining one, unless a contained block introduces a different binding for the name. The scope of names defined in a class block is limited to the -class block; it does not extend to the code blocks of methods. +class block; it does not extend to the code blocks of methods -- this includes +generator expressions since they are implemented using a function scope. This +means that the following will fail:: + + class A: + a = 42 + b = list(a + i for i in range(10)) .. index:: single: environment From python-checkins at python.org Fri Jan 18 19:24:08 2008 From: python-checkins at python.org (christian.heimes) Date: Fri, 18 Jan 2008 19:24:08 +0100 (CET) Subject: [Python-checkins] r60052 - in python/trunk: Lib/test/test_string.py Lib/tokenize.py Misc/NEWS Parser/tokenizer.c Python/ast.c Python/bltinmodule.c Message-ID: <20080118182408.4FC971E4014@bag.python.org> Author: christian.heimes Date: Fri Jan 18 19:24:07 2008 New Revision: 60052 Modified: python/trunk/Lib/test/test_string.py python/trunk/Lib/tokenize.py python/trunk/Misc/NEWS python/trunk/Parser/tokenizer.c python/trunk/Python/ast.c python/trunk/Python/bltinmodule.c Log: Added bytes and b'' as aliases for str and '' Modified: python/trunk/Lib/test/test_string.py ============================================================================== --- python/trunk/Lib/test/test_string.py (original) +++ python/trunk/Lib/test/test_string.py Fri Jan 18 19:24:07 2008 @@ -106,8 +106,19 @@ self.assertEqual(string.capwords('ABC-DEF-GHI', '-'), 'Abc-Def-Ghi') self.assertEqual(string.capwords('ABC-def DEF-ghi GHI'), 'Abc-def Def-ghi Ghi') +class BytesAliasTest(unittest.TestCase): + + def test_builtin(self): + self.assert_(str is bytes) + + def test_syntax(self): + self.assertEqual(b"spam", "spam") + self.assertEqual(br"egg\foo", "egg\\foo") + self.assert_(type(b""), str) + self.assert_(type(br""), str) + def test_main(): - test_support.run_unittest(StringTest, ModuleTest) + test_support.run_unittest(StringTest, ModuleTest, BytesAliasTest) if __name__ == "__main__": test_main() Modified: python/trunk/Lib/tokenize.py ============================================================================== --- python/trunk/Lib/tokenize.py (original) +++ python/trunk/Lib/tokenize.py Fri Jan 18 19:24:07 2008 @@ -109,21 +109,34 @@ "uR'''": single3prog, 'uR"""': double3prog, "Ur'''": single3prog, 'Ur"""': double3prog, "UR'''": single3prog, 'UR"""': double3prog, - 'r': None, 'R': None, 'u': None, 'U': None} + "b'''": single3prog, 'b"""': double3prog, + "br'''": single3prog, 'br"""': double3prog, + "B'''": single3prog, 'B"""': double3prog, + "bR'''": single3prog, 'bR"""': double3prog, + "Br'''": single3prog, 'Br"""': double3prog, + "BR'''": single3prog, 'BR"""': double3prog, + 'r': None, 'R': None, 'u': None, 'U': None, + 'b': None, 'B': None} triple_quoted = {} for t in ("'''", '"""', "r'''", 'r"""', "R'''", 'R"""', "u'''", 'u"""', "U'''", 'U"""', "ur'''", 'ur"""', "Ur'''", 'Ur"""', - "uR'''", 'uR"""', "UR'''", 'UR"""'): + "uR'''", 'uR"""', "UR'''", 'UR"""', + "b'''", 'b"""', "B'''", 'B"""', + "br'''", 'br"""', "Br'''", 'Br"""', + "bR'''", 'bR"""', "BR'''", 'BR"""'): triple_quoted[t] = t single_quoted = {} for t in ("'", '"', "r'", 'r"', "R'", 'R"', "u'", 'u"', "U'", 'U"', "ur'", 'ur"', "Ur'", 'Ur"', - "uR'", 'uR"', "UR'", 'UR"' ): + "uR'", 'uR"', "UR'", 'UR"', + "b'", 'b"', "B'", 'B"', + "br'", 'br"', "Br'", 'Br"', + "bR'", 'bR"', "BR'", 'BR"' ): single_quoted[t] = t tabsize = 8 Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Fri Jan 18 19:24:07 2008 @@ -12,6 +12,9 @@ Core and builtins ----------------- +- Issue #1865: Bytes as an alias for str and b"" as an alias "" were + added. + - sys.float_info / PyFloat_GetInfo: The floating point information object was converted from a dict to a specialized structseq object. Modified: python/trunk/Parser/tokenizer.c ============================================================================== --- python/trunk/Parser/tokenizer.c (original) +++ python/trunk/Parser/tokenizer.c Fri Jan 18 19:24:07 2008 @@ -1263,6 +1263,14 @@ if (isalpha(c) || c == '_') { /* Process r"", u"" and ur"" */ switch (c) { + case 'b': + case 'B': + c = tok_nextc(tok); + if (c == 'r' || c == 'R') + c = tok_nextc(tok); + if (c == '"' || c == '\'') + goto letter_quote; + break; case 'r': case 'R': c = tok_nextc(tok); Modified: python/trunk/Python/ast.c ============================================================================== --- python/trunk/Python/ast.c (original) +++ python/trunk/Python/ast.c Fri Jan 18 19:24:07 2008 @@ -3238,6 +3238,9 @@ quote = *++s; unicode = 1; } + if (quote == 'b' || quote == 'B') { + quote = *++s; + } if (quote == 'r' || quote == 'R') { quote = *++s; rawmode = 1; Modified: python/trunk/Python/bltinmodule.c ============================================================================== --- python/trunk/Python/bltinmodule.c (original) +++ python/trunk/Python/bltinmodule.c Fri Jan 18 19:24:07 2008 @@ -2446,6 +2446,7 @@ SETBUILTIN("True", Py_True); SETBUILTIN("basestring", &PyBaseString_Type); SETBUILTIN("bool", &PyBool_Type); + SETBUILTIN("bytes", &PyString_Type); SETBUILTIN("buffer", &PyBuffer_Type); SETBUILTIN("classmethod", &PyClassMethod_Type); #ifndef WITHOUT_COMPLEX From python-checkins at python.org Fri Jan 18 20:12:57 2008 From: python-checkins at python.org (christian.heimes) Date: Fri, 18 Jan 2008 20:12:57 +0100 (CET) Subject: [Python-checkins] r60054 - in python/trunk: Modules/_sre.c Objects/longobject.c Message-ID: <20080118191257.4E3451E4014@bag.python.org> Author: christian.heimes Date: Fri Jan 18 20:12:56 2008 New Revision: 60054 Modified: python/trunk/Modules/_sre.c python/trunk/Objects/longobject.c Log: Silence Coverity false alerts with CIDs #172, #183, #184 Modified: python/trunk/Modules/_sre.c ============================================================================== --- python/trunk/Modules/_sre.c (original) +++ python/trunk/Modules/_sre.c Fri Jan 18 20:12:56 2008 @@ -2678,7 +2678,7 @@ return NULL; n = PyList_GET_SIZE(code); - + /* coverity[ampersand_in_size] */ self = PyObject_NEW_VAR(PatternObject, &Pattern_Type, n); if (!self) return NULL; @@ -3185,6 +3185,7 @@ if (status > 0) { /* create match object (with room for extra group marks) */ + /* coverity[ampersand_in_size] */ match = PyObject_NEW_VAR(MatchObject, &Match_Type, 2*(pattern->groups+1)); if (!match) Modified: python/trunk/Objects/longobject.c ============================================================================== --- python/trunk/Objects/longobject.c (original) +++ python/trunk/Objects/longobject.c Fri Jan 18 20:12:56 2008 @@ -70,6 +70,7 @@ PyErr_NoMemory(); return NULL; } + /* coverity[ampersand_in_size] */ return PyObject_NEW_VAR(PyLongObject, &PyLong_Type, size); } From buildbot at python.org Fri Jan 18 20:38:12 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 18 Jan 2008 19:38:12 +0000 Subject: [Python-checkins] buildbot failure in x86 XP-3 3.0 Message-ID: <20080118193813.1AB8E1E4014@bag.python.org> The Buildbot has detected a new failure of x86 XP-3 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20XP-3%203.0/builds/490 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: heller-windows Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: 8 tests failed: test_anydbm test_bsddb test_bsddb3 test_mailbox test_shelve test_whichdb test_winreg test_zipfile ====================================================================== ERROR: test_anydbm_access (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_anydbm.py", line 90, in test_anydbm_access self.init_db() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_anydbm.py", line 103, in init_db f = anydbm.open(_fname, 'n') File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_anydbm_creation (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_anydbm.py", line 63, in test_anydbm_creation f = anydbm.open(_fname, 'c') File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_anydbm_keys (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_anydbm.py", line 84, in test_anydbm_keys self.init_db() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_anydbm.py", line 103, in init_db f = anydbm.open(_fname, 'n') File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_anydbm_modification (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_anydbm.py", line 71, in test_anydbm_modification self.init_db() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_anydbm.py", line 103, in init_db f = anydbm.open(_fname, 'n') File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_anydbm_read (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_anydbm.py", line 78, in test_anydbm_read self.init_[24638 refs] [25667 refs] ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') Traceback (most recent call last): File "../lib/test/regrtest.py", line 596, in runtest_inner indirect_test() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb3.py", line 64, in test_main run_unittest(suite()) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb3.py", line 28, in suite import bsddb.test.test_1413192 File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\test\test_1413192.py", line 38, in context = Context() File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\test\test_1413192.py", line 26, in __init__ db.DB_CREATE | db.DB_INIT_TXN | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_flush (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 703, in tearDown self._delete_recursively(self._path) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 47, in _delete_recursively os.remove(target) WindowsError: [Error 32] The process cannot access the file because it is being used by another process: '@test' ====================================================================== ERROR: test_popitem (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 336, in test_popitem self.assertEqual(int(msg.get_payload()), keys.index(key)) ValueError: invalid literal for int() with base 10: 'From: foo 0 F' ====================================================================== ERROR: test_flush (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 703, in tearDown self._delete_recursively(self._path) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 47, in _delete_recursively os.remove(target) WindowsError: [Error 32] The process cannot access the file because it is being used by another process: '@test' ====================================================================== ERROR: test_popitem (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 336, in test_popitem self.assertEqual(int(msg.get_payload()), keys.index(key)) ValueError: invalid literal for int() with base 10: 'From: foo 0 \x01' ====================================================================== ERROR: test_flush (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 926, in tearDown self._delete_recursively(self._path) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 47, in _delete_recursively os.remove(target) WindowsError: [Error 32] The process cannot access the file because it is being used by another process: '@test' ====================================================================== ERROR: test_popitem (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 336, in test_popitem self.assertEqual(int(msg.get_payload()), keys.index(key)) ValueError: invalid literal for int() with base 10: 'From: foo *** EOOH *** From: foo 0 1,, From: foo *** EOOH *** From: foo 1 1,, From: foo *** EOOH *** From: foo 2 1,, From: foo *** EOOH *** From: foo 3 ' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestMaildir) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_add (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 77, in test_add self.assertEqual(self._box.get_string(keys[0]), self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\nF' != 'From: foo\n\n0' ====================================================================== FAIL: test_add_and_close (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 743, in test_add_and_close self.assertEqual(contents, open(self._path, 'r').read()) AssertionError: 'From MAILER-DAEMON Fri Jan 18 22:09:54 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Fri Jan 18 22:09:54 2008\n\nFrom: foo\n\n0\n\nFrom MAILER-DAEMON Fri Jan 18 22:09:54 2008\n\nFrom: foo\n\n1\n\nFrom MAILER-DAEMON Fri Jan 18 22:09:54 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Fri Jan 18 22:09:54 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'From MAILER-DAEMON Fri Jan 18 22:09:54 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Fri Jan 18 22:09:54 2008\n\nFrom: foo\n\n0\n\nFrom MAILER-DAEMON Fri Jan 18 22:09:54 2008\n\nFrom: foo\n\n1\n\nFrom MAILER-DAEMON Fri Jan 18 22:09:54 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Fri Jan 18 22:09:54 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Fri Jan 18 22:09:54 2008\n\nFrom: foo\n\n0\n\nFrom MAILER-DAEMON Fri Jan 18 22:09:54 2008\n\nFrom: foo\n\n1\n\nFrom MAILER-DAEMON Fri Jan 18 22:09:54 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Fri Jan 18 22:09:54 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Fri Jan 18 22:09:54 2008\n\nFrom: foo\n\n1\n\nFrom MAILER-DAEMON Fri Jan 18 22:09:54 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Fri Jan 18 22:09:54 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Fri Jan 18 22:09:54 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Fri Jan 18 22:09:54 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Fri Jan 18 22:09:54 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' ====================================================================== FAIL: test_add_from_string (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 710, in test_add_from_string self.assertEqual(self._box[key].get_from(), 'foo at bar blah') AssertionError: 'foo at bar blah\n' != 'foo at bar blah' ====================================================================== FAIL: test_close (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 389, in test_close self._test_flush_or_close(self._box.close) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 6 != 3 ====================================================================== FAIL: test_delitem (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 87, in test_delitem self._test_remove_or_delitem(self._box.__delitem__) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n1' != 'From: foo\n\n1' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_flush (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 377, in test_flush self._test_flush_or_close(self._box.flush) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 6 != 3 ====================================================================== FAIL: test_get (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 129, in test_get self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_file (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 174, in test_get_file self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\nF' != 'From: foo\n\n0' ====================================================================== FAIL: test_get_message (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 156, in test_get_message self.assertEqual(msg0['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_string (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 164, in test_get_string self.assertEqual(self._box.get_string(key0), self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\nF' != 'From: foo\n\n0' ====================================================================== FAIL: test_getitem (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 144, in test_getitem self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_items (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 207, in test_items self._check_iteration(self._box.items, do_keys=True, do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iter (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 194, in test_iter do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iteritems (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 203, in test_iteritems do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_itervalues (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 189, in test_itervalues do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_open_close_open (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 727, in test_open_close_open self.assertEqual(len(self._box), 3) AssertionError: 6 != 3 ====================================================================== FAIL: test_pop (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 313, in test_pop self.assertEqual(self._box.pop(key0).get_payload(), '0') AssertionError: 'From: foo\n\n0\n\nF' != '0' ====================================================================== FAIL: test_remove (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 83, in test_remove self._test_remove_or_delitem(self._box.remove) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n1' != 'From: foo\n\n1' ====================================================================== FAIL: test_set_item (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 272, in test_set_item self._template % 'original 0') AssertionError: '\nFrom: foo\n\noriginal 0' != 'From: foo\n\noriginal 0' ====================================================================== FAIL: test_update (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 350, in test_update self._template % 'changed 0') AssertionError: '\nFrom: foo\n\nchanged 0\n\nF' != 'From: foo\n\nchanged 0' ====================================================================== FAIL: test_values (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 198, in test_values self._check_iteration(self._box.values, do_keys=False, do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_add (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 77, in test_add self.assertEqual(self._box.get_string(keys[0]), self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\n\x01' != 'From: foo\n\n0' ====================================================================== FAIL: test_add_and_close (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 743, in test_add_and_close self.assertEqual(contents, open(self._path, 'r').read()) AssertionError: '\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Fri Jan 18 22:10:00 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Fri Jan 18 22:10:00 2008\n\nFrom: foo\n\n0\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Fri Jan 18 22:10:00 2008\n\nFrom: foo\n\n1\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Fri Jan 18 22:10:00 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Fri Jan 18 22:10:00 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n' != '\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Fri Jan 18 22:10:00 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Fri Jan 18 22:10:00 2008\n\nFrom: foo\n\n0\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Fri Jan 18 22:10:00 2008\n\nFrom: foo\n\n1\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Fri Jan 18 22:10:00 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Fri Jan 18 22:10:00 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Fri Jan 18 22:10:00 2008\n\nFrom: foo\n\n0\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Fri Jan 18 22:10:00 2008\n\nFrom: foo\n\n1\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Fri Jan 18 22:10:00 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Fri Jan 18 22:10:00 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Fri Jan 18 22:10:00 2008\n\nFrom: foo\n\n1\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Fri Jan 18 22:10:00 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Fri Jan 18 22:10:00 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Fri Jan 18 22:10:00 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Fri Jan 18 22:10:00 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Fri Jan 18 22:10:00 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n' ====================================================================== FAIL: test_add_from_string (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 710, in test_add_from_string self.assertEqual(self._box[key].get_from(), 'foo at bar blah') AssertionError: 'foo at bar blah\n' != 'foo at bar blah' ====================================================================== FAIL: test_close (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 389, in test_close self._test_flush_or_close(self._box.close) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_delitem (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 87, in test_delitem self._test_remove_or_delitem(self._box.__delitem__) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n1\n\n\x01' != 'From: foo\n\n1' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_flush (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 377, in test_flush self._test_flush_or_close(self._box.flush) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_get (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 129, in test_get self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_file (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 174, in test_get_file self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\n\x01' != 'From: foo\n\n0' ====================================================================== FAIL: test_get_message (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 156, in test_get_message self.assertEqual(msg0['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_string (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 164, in test_get_string self.assertEqual(self._box.get_string(key0), self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\n\x01' != 'From: foo\n\n0' ====================================================================== FAIL: test_getitem (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 144, in test_getitem self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_items (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 207, in test_items self._check_iteration(self._box.items, do_keys=True, do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iter (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 194, in test_iter do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iteritems (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 203, in test_iteritems do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_itervalues (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 189, in test_itervalues do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_open_close_open (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 727, in test_open_close_open self.assertEqual(len(self._box), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_pop (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 313, in test_pop self.assertEqual(self._box.pop(key0).get_payload(), '0') AssertionError: 'From: foo\n\n0\n\n\x01' != '0' ====================================================================== FAIL: test_remove (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 83, in test_remove self._test_remove_or_delitem(self._box.remove) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n1\n\n\x01' != 'From: foo\n\n1' ====================================================================== FAIL: test_set_item (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 272, in test_set_item self._template % 'original 0') AssertionError: '\nFrom: foo\n\noriginal 0\n\n\x01' != 'From: foo\n\noriginal 0' ====================================================================== FAIL: test_update (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 350, in test_update self._template % 'changed 0') AssertionError: '\nFrom: foo\n\nchanged 0\n\n\x01' != 'From: foo\n\nchanged 0' ====================================================================== FAIL: test_values (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 198, in test_values self._check_iteration(self._box.values, do_keys=False, do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestMH) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_add (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 77, in test_add self.assertEqual(self._box.get_string(keys[0]), self._template % 0) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n0\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f' != 'From: foo\n\n0' ====================================================================== FAIL: test_close (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 389, in test_close self._test_flush_or_close(self._box.close) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_delitem (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 87, in test_delitem self._test_remove_or_delitem(self._box.__delitem__) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n1\n\n\x1f' != 'From: foo\n\n1' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_flush (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 377, in test_flush self._test_flush_or_close(self._box.flush) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_get (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 129, in test_get self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_file (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 174, in test_get_file self._template % 0) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n0\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f' != 'From: foo\n\n0' ====================================================================== FAIL: test_get_message (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 156, in test_get_message self.assertEqual(msg0['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_string (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 164, in test_get_string self.assertEqual(self._box.get_string(key0), self._template % 0) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n0\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f' != 'From: foo\n\n0' ====================================================================== FAIL: test_getitem (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 144, in test_getitem self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_items (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 207, in test_items self._check_iteration(self._box.items, do_keys=True, do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iter (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 194, in test_iter do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iteritems (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 203, in test_iteritems do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_itervalues (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 189, in test_itervalues do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_pop (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 313, in test_pop self.assertEqual(self._box.pop(key0).get_payload(), '0') AssertionError: 'From: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n0\n\n\x1f\x0c\n\n1,,\n\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n1\n\n\x1f' != '0' ====================================================================== FAIL: test_remove (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 83, in test_remove self._test_remove_or_delitem(self._box.remove) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n1\n\n\x1f' != 'From: foo\n\n1' ====================================================================== FAIL: test_set_item (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 272, in test_set_item self._template % 'original 0') AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\noriginal 0\n\n\x1f' != 'From: foo\n\noriginal 0' ====================================================================== FAIL: test_update (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 350, in test_update self._template % 'changed 0') AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\nchanged 0\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f' != 'From: foo\n\nchanged 0' ====================================================================== FAIL: test_values (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 198, in test_values self._check_iteration(self._box.values, do_keys=False, do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== ERROR: test_bool (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 136, in test_bool self.assert_(not self._empty_mapping()) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_constructor (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 133, in test_constructor self.assertEqual(self._empty_mapping(), self._empty_mapping()) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 270, in test_get d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_items (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 156, in test_items d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keys (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 142, in test_keys d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 162, in test_len d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 293, in test_pop d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 288, in test_popitem d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_read (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 44, in test_read p = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 284, in test_setdefault d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 174, in test_update d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_values (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 150, in test_values d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_write (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 92, in test_write p = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_bool (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 136, in test_bool self.assert_(not self._empty_mapping()) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_constructor (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 133, in test_constructor self.assertEqual(self._empty_mapping(), self._empty_mapping()) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 270, in test_get d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_items (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 156, in test_items d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keys (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 142, in test_keys d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 162, in test_len d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 293, in test_pop d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 288, in test_popitem d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_read (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 44, in test_read p = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 284, in test_setdefault d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 174, in test_update d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_values (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 150, in test_values d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_write (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 92, in test_write p = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_bool (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 136, in test_bool self.assert_(not self._empty_mapping()) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_constructor (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 133, in test_constructor self.assertEqual(self._empty_mapping(), self._empty_mapping()) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 270, in test_get d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_items (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 156, in test_items d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keys (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 142, in test_keys d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 162, in test_len d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 293, in test_pop d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 288, in test_popitem d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_read (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 44, in test_read p = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 284, in test_setdefault d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 174, in test_update d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_values (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 150, in test_values d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_write (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 92, in test_write p = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_ascii_file_shelf (test.test_shelve.TestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 46, in test_ascii_file_shelf s = shelve.open(self.fn, protocol=0) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_binary_file_shelf (test.test_shelve.TestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 54, in test_binary_file_shelf s = shelve.open(self.fn, protocol=1) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_proto2_file_shelf (test.test_shelve.TestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 62, in test_proto2_file_shelf s = shelve.open(self.fn, protocol=2) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_whichdb (test.test_whichdb.WhichDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_whichdb.py", line 32, in test_whichdb f = module.open(_fname, 'c') File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== FAIL: testLocalMachineRegistryWorks (test.test_winreg.WinregTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_winreg.py", line 144, in testLocalMachineRegistryWorks self.TestAll(HKEY_CURRENT_USER) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_winreg.py", line 139, in TestAll self.WriteTestData(root_key, subkeystr) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_winreg.py", line 41, in WriteTestData self.assertEquals(nkeys, 1, "Not the correct number of sub keys") AssertionError: Not the correct number of sub keys ====================================================================== ERROR: testExtract (test.test_zipfile.TestsWithSourceFile) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_zipfile.py", line 350, in tearDown os.remove(TESTFN2) WindowsError: [Error 32] The process cannot access the file because it is being used by another process: '@test2' ====================================================================== FAIL: testExtract (test.test_zipfile.TestsWithSourceFile) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_zipfile.py", line 313, in testExtract self.assertEqual(writtenfile, correctfile) AssertionError: 'C:\\buildbot\\work\\3.0.heller-windows\\build\\PCbuild\\ziptest2dir\\_ziptest2' != 'C:\\buildbot\\work\\3.0.heller-windows\\build\\PCbuild\\ziptest2dir/_ziptest2' sincerely, -The Buildbot From python-checkins at python.org Fri Jan 18 21:53:37 2008 From: python-checkins at python.org (guido.van.rossum) Date: Fri, 18 Jan 2008 21:53:37 +0100 (CET) Subject: [Python-checkins] r60056 - python/branches/release25-maint/Objects/classobject.c Message-ID: <20080118205337.AF0B91E4004@bag.python.org> Author: guido.van.rossum Date: Fri Jan 18 21:53:37 2008 New Revision: 60056 Modified: python/branches/release25-maint/Objects/classobject.c Log: Fix an edge case whereby the __del__() method of a classic class could create a new weakref to the object. Modified: python/branches/release25-maint/Objects/classobject.c ============================================================================== --- python/branches/release25-maint/Objects/classobject.c (original) +++ python/branches/release25-maint/Objects/classobject.c Fri Jan 18 21:53:37 2008 @@ -646,6 +646,16 @@ */ assert(inst->ob_refcnt > 0); if (--inst->ob_refcnt == 0) { + + /* New weakrefs could be created during the finalizer call. + If this occurs, clear them out without calling their + finalizers since they might rely on part of the object + being finalized that has already been destroyed. */ + while (inst->in_weakreflist != NULL) { + _PyWeakref_ClearRef((PyWeakReference *) + (inst->in_weakreflist)); + } + Py_DECREF(inst->in_class); Py_XDECREF(inst->in_dict); PyObject_GC_Del(inst); From python-checkins at python.org Fri Jan 18 21:56:31 2008 From: python-checkins at python.org (guido.van.rossum) Date: Fri, 18 Jan 2008 21:56:31 +0100 (CET) Subject: [Python-checkins] r60057 - python/trunk/Objects/classobject.c Message-ID: <20080118205631.3CED91E4004@bag.python.org> Author: guido.van.rossum Date: Fri Jan 18 21:56:30 2008 New Revision: 60057 Modified: python/trunk/Objects/classobject.c Log: Fix an edge case whereby the __del__() method of a classic class could create a new weakref to the object. Modified: python/trunk/Objects/classobject.c ============================================================================== --- python/trunk/Objects/classobject.c (original) +++ python/trunk/Objects/classobject.c Fri Jan 18 21:56:30 2008 @@ -646,6 +646,16 @@ */ assert(inst->ob_refcnt > 0); if (--inst->ob_refcnt == 0) { + + /* New weakrefs could be created during the finalizer call. + If this occurs, clear them out without calling their + finalizers since they might rely on part of the object + being finalized that has already been destroyed. */ + while (inst->in_weakreflist != NULL) { + _PyWeakref_ClearRef((PyWeakReference *) + (inst->in_weakreflist)); + } + Py_DECREF(inst->in_class); Py_XDECREF(inst->in_dict); PyObject_GC_Del(inst); From python-checkins at python.org Fri Jan 18 22:14:58 2008 From: python-checkins at python.org (raymond.hettinger) Date: Fri, 18 Jan 2008 22:14:58 +0100 (CET) Subject: [Python-checkins] r60058 - python/trunk/Doc/library/collections.rst Message-ID: <20080118211458.7759B1E4004@bag.python.org> Author: raymond.hettinger Date: Fri Jan 18 22:14:58 2008 New Revision: 60058 Modified: python/trunk/Doc/library/collections.rst Log: Better variable name in an example. Modified: python/trunk/Doc/library/collections.rst ============================================================================== --- python/trunk/Doc/library/collections.rst (original) +++ python/trunk/Doc/library/collections.rst Fri Jan 18 22:14:58 2008 @@ -547,8 +547,8 @@ customize a prototype instance:: >>> Account = namedtuple('Account', 'owner balance transaction_count') - >>> model_account = Account('', 0.0, 0) - >>> johns_account = model_account._replace(owner='John') + >>> default_account = Account('', 0.0, 0) + >>> johns_account = default_account._replace(owner='John') .. rubric:: Footnotes From python-checkins at python.org Fri Jan 18 22:31:32 2008 From: python-checkins at python.org (guido.van.rossum) Date: Fri, 18 Jan 2008 22:31:32 +0100 (CET) Subject: [Python-checkins] r60060 - in python/branches/release25-maint: Lib/test/crashers/dangerous_subclassing.py Lib/test/crashers/modify_dict_attr.py Lib/test/test_descr.py Objects/typeobject.c Message-ID: <20080118213133.0053C1E4004@bag.python.org> Author: guido.van.rossum Date: Fri Jan 18 22:31:32 2008 New Revision: 60060 Removed: python/branches/release25-maint/Lib/test/crashers/dangerous_subclassing.py python/branches/release25-maint/Lib/test/crashers/modify_dict_attr.py Modified: python/branches/release25-maint/Lib/test/test_descr.py python/branches/release25-maint/Objects/typeobject.c Log: Backport r55080: Fix for #1303614 and #1174712: - __dict__ descriptor abuse for subclasses of built-in types - subclassing from both ModuleType and another built-in types Deleted: /python/branches/release25-maint/Lib/test/crashers/dangerous_subclassing.py ============================================================================== --- /python/branches/release25-maint/Lib/test/crashers/dangerous_subclassing.py Fri Jan 18 22:31:32 2008 +++ (empty file) @@ -1,12 +0,0 @@ - -# http://python.org/sf/1174712 - -import types - -class X(types.ModuleType, str): - """Such a subclassing is incorrectly allowed -- - see the SF bug report for explanations""" - -if __name__ == '__main__': - X('name') # segfault: ModuleType.__init__() reads - # the dict at the wrong offset Deleted: /python/branches/release25-maint/Lib/test/crashers/modify_dict_attr.py ============================================================================== --- /python/branches/release25-maint/Lib/test/crashers/modify_dict_attr.py Fri Jan 18 22:31:32 2008 +++ (empty file) @@ -1,19 +0,0 @@ - -# http://python.org/sf/1303614 - -class Y(object): - pass - -class type_with_modifiable_dict(Y, type): - pass - -class MyClass(object): - """This class has its __dict__ attribute completely exposed: - user code can read, reassign and even delete it. - """ - __metaclass__ = type_with_modifiable_dict - - -if __name__ == '__main__': - del MyClass.__dict__ # if we set tp_dict to NULL, - print MyClass # doing anything with MyClass segfaults Modified: python/branches/release25-maint/Lib/test/test_descr.py ============================================================================== --- python/branches/release25-maint/Lib/test/test_descr.py (original) +++ python/branches/release25-maint/Lib/test/test_descr.py Fri Jan 18 22:31:32 2008 @@ -3,6 +3,7 @@ from test.test_support import verify, vereq, verbose, TestFailed, TESTFN, get_original_stdout from copy import deepcopy import warnings +import types warnings.filterwarnings("ignore", r'complex divmod\(\), // and % are deprecated$', @@ -845,6 +846,16 @@ ("getattr", "foo"), ("delattr", "foo")]) + # http://python.org/sf/1174712 + try: + class Module(types.ModuleType, str): + pass + except TypeError: + pass + else: + raise TestFailed("inheriting from ModuleType and str at the " + "same time should fail") + def multi(): if verbose: print "Testing multiple inheritance..." class C(object): @@ -2815,8 +2826,73 @@ cant(a, []) cant(a, 1) del a.__dict__ # Deleting __dict__ is allowed - # Classes don't allow __dict__ assignment - cant(C, {}) + + class Base(object): + pass + def verify_dict_readonly(x): + """ + x has to be an instance of a class inheriting from Base. + """ + cant(x, {}) + try: + del x.__dict__ + except (AttributeError, TypeError): + pass + else: + raise TestFailed, "shouldn't allow del %r.__dict__" % x + dict_descr = Base.__dict__["__dict__"] + try: + dict_descr.__set__(x, {}) + except (AttributeError, TypeError): + pass + else: + raise TestFailed, "dict_descr allowed access to %r's dict" % x + + # Classes don't allow __dict__ assignment and have readonly dicts + class Meta1(type, Base): + pass + class Meta2(Base, type): + pass + class D(object): + __metaclass__ = Meta1 + class E(object): + __metaclass__ = Meta2 + for cls in C, D, E: + verify_dict_readonly(cls) + class_dict = cls.__dict__ + try: + class_dict["spam"] = "eggs" + except TypeError: + pass + else: + raise TestFailed, "%r's __dict__ can be modified" % cls + + # Modules also disallow __dict__ assignment + class Module1(types.ModuleType, Base): + pass + class Module2(Base, types.ModuleType): + pass + for ModuleType in Module1, Module2: + mod = ModuleType("spam") + verify_dict_readonly(mod) + mod.__dict__["spam"] = "eggs" + + # Exception's __dict__ can be replaced, but not deleted + class Exception1(Exception, Base): + pass + class Exception2(Base, Exception): + pass + for ExceptionType in Exception, Exception1, Exception2: + e = ExceptionType() + e.__dict__ = {"a": 1} + vereq(e.a, 1) + try: + del e.__dict__ + except (TypeError, AttributeError): + pass + else: + raise TestFaied, "%r's __dict__ can be deleted" % e + def pickles(): if verbose: Modified: python/branches/release25-maint/Objects/typeobject.c ============================================================================== --- python/branches/release25-maint/Objects/typeobject.c (original) +++ python/branches/release25-maint/Objects/typeobject.c Fri Jan 18 22:31:32 2008 @@ -1422,10 +1422,12 @@ type->tp_itemsize != base->tp_itemsize; } if (type->tp_weaklistoffset && base->tp_weaklistoffset == 0 && - type->tp_weaklistoffset + sizeof(PyObject *) == t_size) + type->tp_weaklistoffset + sizeof(PyObject *) == t_size && + type->tp_flags & Py_TPFLAGS_HEAPTYPE) t_size -= sizeof(PyObject *); if (type->tp_dictoffset && base->tp_dictoffset == 0 && - type->tp_dictoffset + sizeof(PyObject *) == t_size) + type->tp_dictoffset + sizeof(PyObject *) == t_size && + type->tp_flags & Py_TPFLAGS_HEAPTYPE) t_size -= sizeof(PyObject *); return t_size != b_size; @@ -1451,12 +1453,73 @@ static int update_slot(PyTypeObject *, PyObject *); static void fixup_slot_dispatchers(PyTypeObject *); +/* + * Helpers for __dict__ descriptor. We don't want to expose the dicts + * inherited from various builtin types. The builtin base usually provides + * its own __dict__ descriptor, so we use that when we can. + */ +static PyTypeObject * +get_builtin_base_with_dict(PyTypeObject *type) +{ + while (type->tp_base != NULL) { + if (type->tp_dictoffset != 0 && + !(type->tp_flags & Py_TPFLAGS_HEAPTYPE)) + return type; + type = type->tp_base; + } + return NULL; +} + +static PyObject * +get_dict_descriptor(PyTypeObject *type) +{ + static PyObject *dict_str; + PyObject *descr; + + if (dict_str == NULL) { + dict_str = PyString_InternFromString("__dict__"); + if (dict_str == NULL) + return NULL; + } + descr = _PyType_Lookup(type, dict_str); + if (descr == NULL || !PyDescr_IsData(descr)) + return NULL; + + return descr; +} + +static void +raise_dict_descr_error(PyObject *obj) +{ + PyErr_Format(PyExc_TypeError, + "this __dict__ descriptor does not support " + "'%.200s' objects", obj->ob_type->tp_name); +} + static PyObject * subtype_dict(PyObject *obj, void *context) { - PyObject **dictptr = _PyObject_GetDictPtr(obj); + PyObject **dictptr; PyObject *dict; + PyTypeObject *base; + + base = get_builtin_base_with_dict(obj->ob_type); + if (base != NULL) { + descrgetfunc func; + PyObject *descr = get_dict_descriptor(base); + if (descr == NULL) { + raise_dict_descr_error(obj); + return NULL; + } + func = descr->ob_type->tp_descr_get; + if (func == NULL) { + raise_dict_descr_error(obj); + return NULL; + } + return func(descr, obj, (PyObject *)(obj->ob_type)); + } + dictptr = _PyObject_GetDictPtr(obj); if (dictptr == NULL) { PyErr_SetString(PyExc_AttributeError, "This object has no __dict__"); @@ -1472,9 +1535,27 @@ static int subtype_setdict(PyObject *obj, PyObject *value, void *context) { - PyObject **dictptr = _PyObject_GetDictPtr(obj); + PyObject **dictptr; PyObject *dict; + PyTypeObject *base; + + base = get_builtin_base_with_dict(obj->ob_type); + if (base != NULL) { + descrsetfunc func; + PyObject *descr = get_dict_descriptor(base); + if (descr == NULL) { + raise_dict_descr_error(obj); + return -1; + } + func = descr->ob_type->tp_descr_set; + if (func == NULL) { + raise_dict_descr_error(obj); + return -1; + } + return func(descr, obj, value); + } + dictptr = _PyObject_GetDictPtr(obj); if (dictptr == NULL) { PyErr_SetString(PyExc_AttributeError, "This object has no __dict__"); From buildbot at python.org Fri Jan 18 22:33:38 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 18 Jan 2008 21:33:38 +0000 Subject: [Python-checkins] buildbot failure in x86 gentoo 2.5 Message-ID: <20080118213339.26E871E4004@bag.python.org> The Buildbot has detected a new failure of x86 gentoo 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20gentoo%202.5/builds/503 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-x86 Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: guido.van.rossum BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/home/buildslave/python-trunk/2.5.norwitz-x86/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildslave/python-trunk/2.5.norwitz-x86/build/Lib/test/test_asynchat.py", line 17, in run PORT = test_support.bind_port(sock, HOST, PORT) File "/home/buildslave/python-trunk/2.5.norwitz-x86/build/Lib/test/test_support.py", line 108, in bind_port raise TestFailed, 'unable to find port to listen on' TestFailed: unable to find port to listen on sincerely, -The Buildbot From python-checkins at python.org Fri Jan 18 22:47:09 2008 From: python-checkins at python.org (phillip.eby) Date: Fri, 18 Jan 2008 22:47:09 +0100 (CET) Subject: [Python-checkins] r60061 - in sandbox/trunk/setuptools/setuptools: command/bdist_egg.py command/easy_install.py command/install_scripts.py tests/test_packageindex.py tests/test_resources.py Message-ID: <20080118214709.DA1E21E4004@bag.python.org> Author: phillip.eby Date: Fri Jan 18 22:47:09 2008 New Revision: 60061 Modified: sandbox/trunk/setuptools/setuptools/command/bdist_egg.py sandbox/trunk/setuptools/setuptools/command/easy_install.py sandbox/trunk/setuptools/setuptools/command/install_scripts.py sandbox/trunk/setuptools/setuptools/tests/test_packageindex.py sandbox/trunk/setuptools/setuptools/tests/test_resources.py Log: chmod/test cleanups and Jython support. Modified: sandbox/trunk/setuptools/setuptools/command/bdist_egg.py ============================================================================== --- sandbox/trunk/setuptools/setuptools/command/bdist_egg.py (original) +++ sandbox/trunk/setuptools/setuptools/command/bdist_egg.py Fri Jan 18 22:47:09 2008 @@ -382,7 +382,7 @@ for flag,fn in safety_flags.items(): if os.path.exists(os.path.join(egg_dir,'EGG-INFO',fn)): return flag - + if not can_scan(): return False safe = True for base, dirs, files in walk_egg(egg_dir): for name in files: @@ -449,6 +449,47 @@ for name in iter_symbols(const): yield name +def can_scan(): + if not sys.platform.startswith('java') and sys.platform != 'cli': + # CPython, PyPy, etc. + return True + log.warn("Unable to analyze compiled code on this platform.") + log.warn("Please ask the author to include a 'zip_safe'" + " setting (either True or False) in the package's setup.py") + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + # Attribute names of options for commands that might need to be convinced to # install to the egg build directory Modified: sandbox/trunk/setuptools/setuptools/command/easy_install.py ============================================================================== --- sandbox/trunk/setuptools/setuptools/command/easy_install.py (original) +++ sandbox/trunk/setuptools/setuptools/command/easy_install.py Fri Jan 18 22:47:09 2008 @@ -608,10 +608,10 @@ f = open(target,"w"+mode) f.write(contents) f.close() - try: - os.chmod(target,0755) - except (AttributeError, os.error): - pass + chmod(target,0755) + + + def install_eggs(self, spec, dist_filename, tmpdir): # .egg dirs or files are already built, so just return them @@ -988,18 +988,18 @@ def pf(src,dst): if dst.endswith('.py') and not src.startswith('EGG-INFO/'): to_compile.append(dst) - self.unpack_progress(src,dst); to_chmod.append(dst) + to_chmod.append(dst) + elif dst.endswith('.dll') or dst.endswith('.so'): + to_chmod.append(dst) + self.unpack_progress(src,dst) return not self.dry_run and dst or None unpack_archive(egg_path, destination, pf) self.byte_compile(to_compile) if not self.dry_run: - flags = stat.S_IXGRP|stat.S_IXGRP for f in to_chmod: - mode = ((os.stat(f)[stat.ST_MODE]) | 0555) & 07777 - log.debug("changing mode of %s to %o", f, mode) - os.chmod(f, mode) - + mode = ((os.stat(f)[stat.ST_MODE]) | 0555) & 07755 + chmod(f, mode) def byte_compile(self, to_compile): from distutils.util import byte_compile @@ -1435,7 +1435,7 @@ def auto_chmod(func, arg, exc): if func is os.remove and os.name=='nt': - os.chmod(arg, stat.S_IWRITE) + chmod(arg, stat.S_IWRITE) return func(arg) exc = sys.exc_info() raise exc[0], (exc[1][0], exc[1][1] + (" %s %s" % (func,arg))) @@ -1530,18 +1530,18 @@ return False # Not any Python I can recognize +try: + from os import chmod as _chmod +except ImportError: + # Jython compatibility + def _chmod(*args): pass - - - - - - - - - - - +def chmod(path, mode): + log.debug("changing mode of %s to %o", path, mode) + try: + _chmod(path, mode) + except os.error, e: + log.debug("chmod failed: %s", e) Modified: sandbox/trunk/setuptools/setuptools/command/install_scripts.py ============================================================================== --- sandbox/trunk/setuptools/setuptools/command/install_scripts.py (original) +++ sandbox/trunk/setuptools/setuptools/command/install_scripts.py Fri Jan 18 22:47:09 2008 @@ -1,6 +1,6 @@ from distutils.command.install_scripts import install_scripts \ as _install_scripts -from easy_install import get_script_args, sys_executable +from easy_install import get_script_args, sys_executable, chmod from pkg_resources import Distribution, PathMetadata, ensure_directory import os from distutils import log @@ -50,10 +50,10 @@ f = open(target,"w"+mode) f.write(contents) f.close() - try: - os.chmod(target,0755) - except (AttributeError, os.error): - pass + chmod(target,0755) + + + Modified: sandbox/trunk/setuptools/setuptools/tests/test_packageindex.py ============================================================================== --- sandbox/trunk/setuptools/setuptools/tests/test_packageindex.py (original) +++ sandbox/trunk/setuptools/setuptools/tests/test_packageindex.py Fri Jan 18 22:47:09 2008 @@ -2,7 +2,7 @@ """ # More would be better! -import os, shutil, tempfile, unittest +import os, shutil, tempfile, unittest, urllib2 import pkg_resources import setuptools.package_index @@ -12,8 +12,8 @@ index = setuptools.package_index.PackageIndex() url = 'http://127.0.0.1/nonesuch/test_package_index' try: - index.open_url(url) + v = index.open_url(url) except Exception, v: self.assert_(url in str(v)) else: - self.assert_(False) + self.assert_(isinstance(v,urllib2.HTTPError)) Modified: sandbox/trunk/setuptools/setuptools/tests/test_resources.py ============================================================================== --- sandbox/trunk/setuptools/setuptools/tests/test_resources.py (original) +++ sandbox/trunk/setuptools/setuptools/tests/test_resources.py Fri Jan 18 22:47:09 2008 @@ -39,8 +39,6 @@ # But only 1 package self.assertEqual(list(ad), ['foopkg']) - - # Distributions sort by version self.assertEqual( [dist.version for dist in ad['FooPkg']], ['1.4','1.3-1','1.2'] @@ -255,14 +253,15 @@ else: raise AssertionError("Should've been bad", ep) def checkSubMap(self, m): - self.assertEqual(str(m), - "{'feature2': EntryPoint.parse(" - "'feature2 = another.module:SomeClass [extra1,extra2]'), " - "'feature3': EntryPoint.parse('feature3 = this.module [something]'), " - "'feature1': EntryPoint.parse(" - "'feature1 = somemodule:somefunction')}" - ) - + self.assertEqual(len(m), len(self.submap_expect)) + for key, ep in self.submap_expect.iteritems(): + self.assertEqual(repr(m.get(key)), repr(ep)) + + submap_expect = dict( + feature1=EntryPoint('feature1', 'somemodule', ['somefunction']), + feature2=EntryPoint('feature2', 'another.module', ['SomeClass'], ['extra1','extra2']), + feature3=EntryPoint('feature3', 'this.module', extras=['something']) + ) submap_str = """ # define features for blah blah feature1 = somemodule:somefunction @@ -286,7 +285,6 @@ self.assertRaises(ValueError, EntryPoint.parse_map, ["[xyz]", "[xyz]"]) self.assertRaises(ValueError, EntryPoint.parse_map, self.submap_str) - class RequirementsTests(TestCase): def testBasics(self): From python-checkins at python.org Fri Jan 18 22:51:24 2008 From: python-checkins at python.org (phillip.eby) Date: Fri, 18 Jan 2008 22:51:24 +0100 (CET) Subject: [Python-checkins] r60062 - in sandbox/branches/setuptools-0.6: EasyInstall.txt setuptools.txt setuptools/command/bdist_egg.py setuptools/command/easy_install.py setuptools/command/install_scripts.py setuptools/tests/test_packageindex.py setuptools/tests/test_resources.py Message-ID: <20080118215124.286041E4031@bag.python.org> Author: phillip.eby Date: Fri Jan 18 22:51:23 2008 New Revision: 60062 Modified: sandbox/branches/setuptools-0.6/EasyInstall.txt sandbox/branches/setuptools-0.6/setuptools.txt sandbox/branches/setuptools-0.6/setuptools/command/bdist_egg.py sandbox/branches/setuptools-0.6/setuptools/command/easy_install.py sandbox/branches/setuptools-0.6/setuptools/command/install_scripts.py sandbox/branches/setuptools-0.6/setuptools/tests/test_packageindex.py sandbox/branches/setuptools-0.6/setuptools/tests/test_resources.py Log: chmod/test cleanups and Jython compatibility (backport from trunk) Modified: sandbox/branches/setuptools-0.6/EasyInstall.txt ============================================================================== --- sandbox/branches/setuptools-0.6/EasyInstall.txt (original) +++ sandbox/branches/setuptools-0.6/EasyInstall.txt Fri Jan 18 22:51:23 2008 @@ -1241,6 +1241,10 @@ * Fixed not picking up dependency links from recursive dependencies. + * Only make ``.py``, ``.dll`` and ``.so`` files executable when unpacking eggs + + * Changes for Jython compatibility + 0.6c7 * ``ftp:`` download URLs now work correctly. Modified: sandbox/branches/setuptools-0.6/setuptools.txt ============================================================================== --- sandbox/branches/setuptools-0.6/setuptools.txt (original) +++ sandbox/branches/setuptools-0.6/setuptools.txt Fri Jan 18 22:51:23 2008 @@ -2618,6 +2618,8 @@ * Updated Pyrex support to work with Pyrex 0.9.6 and higher. + * Minor changes for Jython compatibility + 0.6c7 * Fixed ``distutils.filelist.findall()`` crashing on broken symlinks, and ``egg_info`` command failing on new, uncommitted SVN directories. Modified: sandbox/branches/setuptools-0.6/setuptools/command/bdist_egg.py ============================================================================== --- sandbox/branches/setuptools-0.6/setuptools/command/bdist_egg.py (original) +++ sandbox/branches/setuptools-0.6/setuptools/command/bdist_egg.py Fri Jan 18 22:51:23 2008 @@ -382,7 +382,7 @@ for flag,fn in safety_flags.items(): if os.path.exists(os.path.join(egg_dir,'EGG-INFO',fn)): return flag - + if not can_scan(): return False safe = True for base, dirs, files in walk_egg(egg_dir): for name in files: @@ -449,6 +449,47 @@ for name in iter_symbols(const): yield name +def can_scan(): + if not sys.platform.startswith('java') and sys.platform != 'cli': + # CPython, PyPy, etc. + return True + log.warn("Unable to analyze compiled code on this platform.") + log.warn("Please ask the author to include a 'zip_safe'" + " setting (either True or False) in the package's setup.py") + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + # Attribute names of options for commands that might need to be convinced to # install to the egg build directory Modified: sandbox/branches/setuptools-0.6/setuptools/command/easy_install.py ============================================================================== --- sandbox/branches/setuptools-0.6/setuptools/command/easy_install.py (original) +++ sandbox/branches/setuptools-0.6/setuptools/command/easy_install.py Fri Jan 18 22:51:23 2008 @@ -608,10 +608,10 @@ f = open(target,"w"+mode) f.write(contents) f.close() - try: - os.chmod(target,0755) - except (AttributeError, os.error): - pass + chmod(target,0755) + + + def install_eggs(self, spec, dist_filename, tmpdir): # .egg dirs or files are already built, so just return them @@ -988,18 +988,18 @@ def pf(src,dst): if dst.endswith('.py') and not src.startswith('EGG-INFO/'): to_compile.append(dst) - self.unpack_progress(src,dst); to_chmod.append(dst) + to_chmod.append(dst) + elif dst.endswith('.dll') or dst.endswith('.so'): + to_chmod.append(dst) + self.unpack_progress(src,dst) return not self.dry_run and dst or None unpack_archive(egg_path, destination, pf) self.byte_compile(to_compile) if not self.dry_run: - flags = stat.S_IXGRP|stat.S_IXGRP for f in to_chmod: - mode = ((os.stat(f)[stat.ST_MODE]) | 0555) & 07777 - log.debug("changing mode of %s to %o", f, mode) - os.chmod(f, mode) - + mode = ((os.stat(f)[stat.ST_MODE]) | 0555) & 07755 + chmod(f, mode) def byte_compile(self, to_compile): from distutils.util import byte_compile @@ -1435,7 +1435,7 @@ def auto_chmod(func, arg, exc): if func is os.remove and os.name=='nt': - os.chmod(arg, stat.S_IWRITE) + chmod(arg, stat.S_IWRITE) return func(arg) exc = sys.exc_info() raise exc[0], (exc[1][0], exc[1][1] + (" %s %s" % (func,arg))) @@ -1530,18 +1530,18 @@ return False # Not any Python I can recognize +try: + from os import chmod as _chmod +except ImportError: + # Jython compatibility + def _chmod(*args): pass - - - - - - - - - - - +def chmod(path, mode): + log.debug("changing mode of %s to %o", path, mode) + try: + _chmod(path, mode) + except os.error, e: + log.debug("chmod failed: %s", e) Modified: sandbox/branches/setuptools-0.6/setuptools/command/install_scripts.py ============================================================================== --- sandbox/branches/setuptools-0.6/setuptools/command/install_scripts.py (original) +++ sandbox/branches/setuptools-0.6/setuptools/command/install_scripts.py Fri Jan 18 22:51:23 2008 @@ -1,6 +1,6 @@ from distutils.command.install_scripts import install_scripts \ as _install_scripts -from easy_install import get_script_args, sys_executable +from easy_install import get_script_args, sys_executable, chmod from pkg_resources import Distribution, PathMetadata, ensure_directory import os from distutils import log @@ -50,10 +50,10 @@ f = open(target,"w"+mode) f.write(contents) f.close() - try: - os.chmod(target,0755) - except (AttributeError, os.error): - pass + chmod(target,0755) + + + Modified: sandbox/branches/setuptools-0.6/setuptools/tests/test_packageindex.py ============================================================================== --- sandbox/branches/setuptools-0.6/setuptools/tests/test_packageindex.py (original) +++ sandbox/branches/setuptools-0.6/setuptools/tests/test_packageindex.py Fri Jan 18 22:51:23 2008 @@ -2,7 +2,7 @@ """ # More would be better! -import os, shutil, tempfile, unittest +import os, shutil, tempfile, unittest, urllib2 import pkg_resources import setuptools.package_index @@ -12,8 +12,8 @@ index = setuptools.package_index.PackageIndex() url = 'http://127.0.0.1/nonesuch/test_package_index' try: - index.open_url(url) + v = index.open_url(url) except Exception, v: self.assert_(url in str(v)) else: - self.assert_(False) + self.assert_(isinstance(v,urllib2.HTTPError)) Modified: sandbox/branches/setuptools-0.6/setuptools/tests/test_resources.py ============================================================================== --- sandbox/branches/setuptools-0.6/setuptools/tests/test_resources.py (original) +++ sandbox/branches/setuptools-0.6/setuptools/tests/test_resources.py Fri Jan 18 22:51:23 2008 @@ -39,8 +39,6 @@ # But only 1 package self.assertEqual(list(ad), ['foopkg']) - - # Distributions sort by version self.assertEqual( [dist.version for dist in ad['FooPkg']], ['1.4','1.3-1','1.2'] @@ -255,14 +253,15 @@ else: raise AssertionError("Should've been bad", ep) def checkSubMap(self, m): - self.assertEqual(str(m), - "{'feature2': EntryPoint.parse(" - "'feature2 = another.module:SomeClass [extra1,extra2]'), " - "'feature3': EntryPoint.parse('feature3 = this.module [something]'), " - "'feature1': EntryPoint.parse(" - "'feature1 = somemodule:somefunction')}" - ) - + self.assertEqual(len(m), len(self.submap_expect)) + for key, ep in self.submap_expect.iteritems(): + self.assertEqual(repr(m.get(key)), repr(ep)) + + submap_expect = dict( + feature1=EntryPoint('feature1', 'somemodule', ['somefunction']), + feature2=EntryPoint('feature2', 'another.module', ['SomeClass'], ['extra1','extra2']), + feature3=EntryPoint('feature3', 'this.module', extras=['something']) + ) submap_str = """ # define features for blah blah feature1 = somemodule:somefunction @@ -286,7 +285,6 @@ self.assertRaises(ValueError, EntryPoint.parse_map, ["[xyz]", "[xyz]"]) self.assertRaises(ValueError, EntryPoint.parse_map, self.submap_str) - class RequirementsTests(TestCase): def testBasics(self): From nnorwitz at gmail.com Fri Jan 18 23:41:37 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Fri, 18 Jan 2008 17:41:37 -0500 Subject: [Python-checkins] Python Regression Test Failures refleak (9) Message-ID: <20080118224137.GA6633@python.psfb.org> test_opcodes leaked [-2, 0, 2] references, sum=0 test_doctest leaked [0, 0, -4] references, sum=-4 test_descrtut leaked [-6, 6, -2] references, sum=-2 test_difflib leaked [0, -4, 0] references, sum=-4 test_dummy_threading leaked [-2, 0, 0] references, sum=-2 test_future leaked [0, -2, 0] references, sum=-2 test_generators leaked [0, -2, 2] references, sum=0 test_genexps leaked [0, 0, -2] references, sum=-2 test_importhooks leaked [4, -4, 6] references, sum=6 test_index leaked [-2, 0, 0] references, sum=-2 test_pkgimport leaked [2, 0, 0] references, sum=2 test_popen2 leaked [26, -26, 0] references, sum=0 test_cmd_line leaked [0, 0, 23] references, sum=23 test_sqlite leaked [-2, 2, 0] references, sum=0 test_sys leaked [-140, 140, -140] references, sum=-140 test_urllib2_localnet leaked [3, 3, 3] references, sum=9 test_popen2 leaked [49, -23, 26] references, sum=52 test_weakref leaked [0, -2, 2] references, sum=0 From buildbot at python.org Fri Jan 18 23:23:07 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 18 Jan 2008 22:23:07 +0000 Subject: [Python-checkins] buildbot failure in sparc solaris10 gcc trunk Message-ID: <20080118222307.4A6CC1E4020@bag.python.org> The Buildbot has detected a new failure of sparc solaris10 gcc trunk. Full details are available at: http://www.python.org/dev/buildbot/all/sparc%20solaris10%20gcc%20trunk/builds/2637 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-sun Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: guido.van.rossum BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/SocketServer.py", line 523, in __init__ self.handle() File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 11] Resource temporarily unavailable 1 test failed: test_xmlrpc sincerely, -The Buildbot From nnorwitz at gmail.com Sat Jan 19 00:00:11 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Fri, 18 Jan 2008 18:00:11 -0500 Subject: [Python-checkins] Python Regression Test Failures all (1) Message-ID: <20080118230011.GA11011@python.psfb.org> test_grammar test_opcodes test_dict test_builtin test_exceptions test_types test_unittest test_doctest test_doctest2 test_MimeWriter test_StringIO test___all__ test___future__ test__locale test_abc test_abstract_numbers test_aepack test_aepack skipped -- No module named aepack test_al test_al skipped -- No module named al test_anydbm test_applesingle test_applesingle skipped -- No module named macostools test_array test_ast test_asynchat test_asyncore test_atexit test_audioop test_augassign test_base64 test_bastion test_bigaddrspace test_bigmem test_binascii test_binhex test_binop test_bisect test_bool test_bsddb test_bsddb185 test_bsddb185 skipped -- No module named bsddb185 test_bsddb3 test test_bsddb3 failed -- errors occurred; run in verbose mode for details test_buffer test_bufio test_bz2 test_cProfile test_calendar test_call test_capi test_cd test_cd skipped -- No module named cd test_cfgparser test_cgi test_charmapcodec test_cl test_cl skipped -- No module named cl test_class test_cmath test_cmd test_cmd_line test_cmd_line_script test_code test_codeccallbacks test_codecencodings_cn test_codecencodings_hk test_codecencodings_jp test_codecencodings_kr test_codecencodings_tw test_codecmaps_cn test_codecmaps_hk test_codecmaps_jp test_codecmaps_kr test_codecmaps_tw test_codecs test_codeop test_coding test_coercion test_collections test_colorsys test_commands test_compare test_compile test_compiler testCompileLibrary still working, be patient... test_complex test_complex_args test_contains test_contextlib test_cookie test_cookielib test_copy test_copy_reg test_cpickle test_crypt test_csv test_ctypes test_datetime test_dbm test_decimal test_decorators test_defaultdict test_deque test_descr test_descrtut test_difflib test_dircache test_dis test_distutils test_dl test_docxmlrpc test_dumbdbm test_dummy_thread test_dummy_threading test_email test_email_codecs test_email_renamed test_enumerate test_eof test_errno test_exception_variations test_extcall test_fcntl test_file test_filecmp test_fileinput test_float test_fnmatch test_fork1 test_format test_fpformat test_frozen test_ftplib test_funcattrs test_functools test_future test_gc test_gdbm test_generators test_genericpath test_genexps test_getargs test_getargs2 test_getopt test_gettext test_gl test_gl skipped -- No module named gl test_glob test_global test_grp test_gzip test_hash test_hashlib test_heapq test_hexoct test_hmac test_hotshot test_htmllib test_htmlparser test_httplib test_imageop test_imageop skipped -- No module named imgfile test_imaplib test_imgfile test_imgfile skipped -- No module named imgfile test_imp test_import test_importhooks test_index test_inspect test_ioctl test_ioctl skipped -- Unable to open /dev/tty test_isinstance test_iter test_iterlen test_itertools test_largefile test_list test_locale test_logging test_long test_long_future test_longexp test_macostools test_macostools skipped -- No module named macostools test_macpath test_mailbox test_marshal test_math test_md5 test_mhlib test_mimetools test_mimetypes test_minidom test_mmap test_module test_modulefinder test_multibytecodec test_multibytecodec_support test_multifile test_mutants test_netrc test_new test_nis test_normalization test_ntpath test_old_mailbox test_openpty test_operator test_optparse test_os test_parser test_peepholer test_pep247 test_pep263 test_pep277 test_pep277 skipped -- test works only on NT+ test_pep292 test_pep352 test_pickle test_pickletools test_pipes test_pkg test_pkgimport test_platform test_plistlib test_plistlib skipped -- No module named plistlib test_poll test_popen [8900 refs] [8900 refs] [8900 refs] test_popen2 test_poplib test_posix test_posixpath test_pow test_pprint test_profile test_profilehooks test_property test_pty test_pwd test_pyclbr test_pyexpat test_queue test_quopri [9269 refs] [9269 refs] test_random test_rational test_re test_repr test_resource test_rfc822 test_richcmp test_robotparser test_runpy test_sax test_scope test_scriptpackages test_scriptpackages skipped -- No module named aetools test_select test_set test_sets test_sgmllib test_sha test_shelve test_shlex test_shutil test_signal test_site test_slice test_smtplib test_socket test_socket_ssl /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:94: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ssl_sock = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:60: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:130: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:144: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) test_socketserver test_softspace test_sort test_sqlite test_ssl test_startfile test_startfile skipped -- cannot import name startfile test_str test_strftime test_string test_stringprep test_strop test_strptime test_struct test_structmembers test_structseq test_subprocess [8895 refs] [8898 refs] [8895 refs] [8895 refs] [8895 refs] [8895 refs] [8895 refs] [8895 refs] [8895 refs] [8897 refs] [8898 refs] [10449 refs] [9113 refs] [8898 refs] [8895 refs] [8895 refs] [8895 refs] [8895 refs] [8895 refs] . [8895 refs] [8895 refs] this bit of output is from a test of stdout in a different process ... [8895 refs] [8895 refs] [9113 refs] test_sunaudiodev test_sunaudiodev skipped -- No module named sunaudiodev test_sundry test_symtable test_syntax test_sys [8895 refs] [8895 refs] test_tarfile test_tcl test_tcl skipped -- No module named _tkinter test_telnetlib test_tempfile [8901 refs] test_textwrap test_thread test_threaded_import test_threadedtempfile test_threading [13143 refs] test_threading_local test_threadsignals test_time test_timeout test_tokenize test_trace test_traceback test_transformer test_tuple test_typechecks test_ucn test_unary test_unicode test_unicode_file test_unicode_file skipped -- No Unicode filesystem semantics on this platform. test_unicodedata test_univnewlines test_unpack test_urllib test_urllib2 test_urllib2_localnet test_urllib2net test_urllibnet test_urlparse test_userdict test_userlist test_userstring test_uu test_uuid WARNING: uuid.getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._ifconfig_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._unixdll_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. test_wait3 test_wait4 test_warnings test_wave test_weakref test_whichdb test_winreg test_winreg skipped -- No module named _winreg test_winsound test_winsound skipped -- No module named winsound test_with test_wsgiref test_xdrlib test_xml_etree test_xml_etree_c test_xmllib test_xmlrpc test_xpickle test_xrange test_zipfile test_zipfile64 test_zipfile64 skipped -- test requires loads of disk-space bytes and a long time to run test_zipimport test_zlib 313 tests OK. 1 test failed: test_bsddb3 21 tests skipped: test_aepack test_al test_applesingle test_bsddb185 test_cd test_cl test_gl test_imageop test_imgfile test_ioctl test_macostools test_pep277 test_plistlib test_scriptpackages test_startfile test_sunaudiodev test_tcl test_unicode_file test_winreg test_winsound test_zipfile64 1 skip unexpected on linux2: test_ioctl [540163 refs] From nnorwitz at gmail.com Sat Jan 19 00:19:36 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Fri, 18 Jan 2008 18:19:36 -0500 Subject: [Python-checkins] Python Regression Test Failures refleak (9) Message-ID: <20080118231936.GA13607@python.psfb.org> test_opcodes leaked [-2, 0, 2] references, sum=0 test_doctest leaked [0, 0, -4] references, sum=-4 test_descrtut leaked [-6, 6, -2] references, sum=-2 test_difflib leaked [0, -4, 0] references, sum=-4 test_dummy_threading leaked [-2, 0, 0] references, sum=-2 test_future leaked [0, -2, 0] references, sum=-2 test_generators leaked [0, -2, 2] references, sum=0 test_genexps leaked [0, 0, -2] references, sum=-2 test_importhooks leaked [4, -4, 6] references, sum=6 test_index leaked [-2, 0, 0] references, sum=-2 test_pkgimport leaked [2, 0, 0] references, sum=2 test_popen2 leaked [26, -26, 0] references, sum=0 test_cmd_line leaked [0, 0, 23] references, sum=23 test_sqlite leaked [-2, 2, 0] references, sum=0 test_sys leaked [-140, 140, -140] references, sum=-140 test_urllib2_localnet leaked [3, 3, 3] references, sum=9 test_popen2 leaked [49, -23, 26] references, sum=52 test_weakref leaked [0, -2, 2] references, sum=0 test_urllib2_localnet leaked [4, 3, 3] references, sum=10 From python-checkins at python.org Sat Jan 19 00:05:40 2008 From: python-checkins at python.org (guido.van.rossum) Date: Sat, 19 Jan 2008 00:05:40 +0100 (CET) Subject: [Python-checkins] r60063 - python/trunk/Lib/test/crashers/weakref_in_del.py Message-ID: <20080118230540.DB87B1E4004@bag.python.org> Author: guido.van.rossum Date: Sat Jan 19 00:05:40 2008 New Revision: 60063 Removed: python/trunk/Lib/test/crashers/weakref_in_del.py Log: This got fixed for classic classes in r60057, and backported to 2.5.2 in 60056. Deleted: /python/trunk/Lib/test/crashers/weakref_in_del.py ============================================================================== --- /python/trunk/Lib/test/crashers/weakref_in_del.py Sat Jan 19 00:05:40 2008 +++ (empty file) @@ -1,17 +0,0 @@ -import weakref - -# http://python.org/sf/1377858 -# Fixed for new-style classes in 2.5c1. - -ref = None - -def test_weakref_in_del(): - class Target(): - def __del__(self): - global ref - ref = weakref.ref(self) - - w = Target() - -if __name__ == '__main__': - test_weakref_in_del() From python-checkins at python.org Sat Jan 19 00:06:49 2008 From: python-checkins at python.org (guido.van.rossum) Date: Sat, 19 Jan 2008 00:06:49 +0100 (CET) Subject: [Python-checkins] r60064 - python/branches/release25-maint/Lib/test/crashers/weakref_in_del.py Message-ID: <20080118230649.D2EDE1E4004@bag.python.org> Author: guido.van.rossum Date: Sat Jan 19 00:06:49 2008 New Revision: 60064 Removed: python/branches/release25-maint/Lib/test/crashers/weakref_in_del.py Log: This got fixed in r60056. Deleted: /python/branches/release25-maint/Lib/test/crashers/weakref_in_del.py ============================================================================== --- /python/branches/release25-maint/Lib/test/crashers/weakref_in_del.py Sat Jan 19 00:06:49 2008 +++ (empty file) @@ -1,17 +0,0 @@ -import weakref - -# http://python.org/sf/1377858 -# Fixed for new-style classes in 2.5c1. - -ref = None - -def test_weakref_in_del(): - class Target(): - def __del__(self): - global ref - ref = weakref.ref(self) - - w = Target() - -if __name__ == '__main__': - test_weakref_in_del() From buildbot at python.org Sat Jan 19 00:09:31 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 18 Jan 2008 23:09:31 +0000 Subject: [Python-checkins] buildbot failure in alpha Tru64 5.1 2.5 Message-ID: <20080118230931.B0EF01E4004@bag.python.org> The Buildbot has detected a new failure of alpha Tru64 5.1 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/alpha%20Tru64%205.1%202.5/builds/399 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-tru64 Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: guido.van.rossum BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_socket ====================================================================== FAIL: testInterruptedTimeout (test.test_socket.TCPTimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/net/taipan/scratch1/nnorwitz/python/2.5.norwitz-tru64/build/Lib/test/test_socket.py", line 879, in testInterruptedTimeout self.fail("got Alarm in wrong place") AssertionError: got Alarm in wrong place sincerely, -The Buildbot From nnorwitz at gmail.com Sat Jan 19 00:37:54 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Fri, 18 Jan 2008 18:37:54 -0500 Subject: [Python-checkins] Python Regression Test Failures all (1) Message-ID: <20080118233754.GA25228@python.psfb.org> test_grammar test_opcodes test_dict test_builtin test_exceptions test_types test_unittest test_doctest test_doctest2 test_MimeWriter test_StringIO test___all__ test___future__ test__locale test_abc test_abstract_numbers test_aepack test_aepack skipped -- No module named aepack test_al test_al skipped -- No module named al test_anydbm test_applesingle test_applesingle skipped -- No module named macostools test_array test_ast test_asynchat test_asyncore test_atexit test_audioop test_augassign test_base64 test_bastion test_bigaddrspace test_bigmem test_binascii test_binhex test_binop test_bisect test_bool test_bsddb test_bsddb185 test_bsddb185 skipped -- No module named bsddb185 test_bsddb3 test test_bsddb3 failed -- errors occurred; run in verbose mode for details test_buffer test_bufio test_bz2 test_cProfile test_calendar test_call test_capi test_cd test_cd skipped -- No module named cd test_cfgparser test_cgi test_charmapcodec test_cl test_cl skipped -- No module named cl test_class test_cmath test_cmd test_cmd_line test_cmd_line_script test_code test_codeccallbacks test_codecencodings_cn test_codecencodings_hk test_codecencodings_jp test_codecencodings_kr test_codecencodings_tw test_codecmaps_cn test_codecmaps_hk test_codecmaps_jp test_codecmaps_kr test_codecmaps_tw test_codecs test_codeop test_coding test_coercion test_collections test_colorsys test_commands test_compare test_compile test_compiler testCompileLibrary still working, be patient... test_complex test_complex_args test_contains test_contextlib test_cookie test_cookielib test_copy test_copy_reg test_cpickle test_crypt test_csv test_ctypes test_datetime test_dbm test_decimal test_decorators test_defaultdict test_deque test_descr test_descrtut test_difflib test_dircache test_dis test_distutils test_dl test_docxmlrpc test_dumbdbm test_dummy_thread test_dummy_threading test_email test_email_codecs test_email_renamed test_enumerate test_eof test_errno test_exception_variations test_extcall test_fcntl test_file test_filecmp test_fileinput test_float test_fnmatch test_fork1 test_format test_fpformat test_frozen test_ftplib test_funcattrs test_functools test_future test_gc test_gdbm test_generators test_genericpath test_genexps test_getargs test_getargs2 test_getopt test_gettext test_gl test_gl skipped -- No module named gl test_glob test_global test_grp test_gzip test_hash test_hashlib test_heapq test_hexoct test_hmac test_hotshot test_htmllib test_htmlparser test_httplib test_imageop test_imageop skipped -- No module named imgfile test_imaplib test_imgfile test_imgfile skipped -- No module named imgfile test_imp test_import test_importhooks test_index test_inspect test_ioctl test_ioctl skipped -- Unable to open /dev/tty test_isinstance test_iter test_iterlen test_itertools test_largefile test_list test_locale test_logging test_long test_long_future test_longexp test_macostools test_macostools skipped -- No module named macostools test_macpath test_mailbox test_marshal test_math test_md5 test_mhlib test_mimetools test_mimetypes test_minidom test_mmap test_module test_modulefinder test_multibytecodec test_multibytecodec_support test_multifile test_mutants test_netrc test_new test_nis test_normalization test_ntpath test_old_mailbox test_openpty test_operator test_optparse test_os test_parser test_peepholer test_pep247 test_pep263 test_pep277 test_pep277 skipped -- test works only on NT+ test_pep292 test_pep352 test_pickle test_pickletools test_pipes test_pkg test_pkgimport test_platform test_plistlib test_plistlib skipped -- No module named plistlib test_poll test_popen [8900 refs] [8900 refs] [8900 refs] test_popen2 test_poplib test_posix test_posixpath test_pow test_pprint test_profile test_profilehooks test_property test_pty test_pwd test_pyclbr test_pyexpat test_queue test_quopri [9269 refs] [9269 refs] test_random test_rational test_re test_repr test_resource test_rfc822 test_richcmp test_robotparser test_runpy test_sax test_scope test_scriptpackages test_scriptpackages skipped -- No module named aetools test_select test_set test_sets test_sgmllib test_sha test_shelve test_shlex test_shutil test_signal test_site test_slice test_smtplib test_socket test_socket_ssl /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:94: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ssl_sock = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:60: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:130: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:144: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) test_socketserver test_softspace test_sort test_sqlite test_ssl test_startfile test_startfile skipped -- cannot import name startfile test_str test_strftime test_string test_stringprep test_strop test_strptime test_struct test_structmembers test_structseq test_subprocess [8895 refs] [8898 refs] [8895 refs] [8895 refs] [8895 refs] [8895 refs] [8895 refs] [8895 refs] [8895 refs] [8897 refs] [8898 refs] [10449 refs] [9113 refs] [8898 refs] [8895 refs] [8895 refs] [8895 refs] [8895 refs] [8895 refs] . [8895 refs] [8895 refs] this bit of output is from a test of stdout in a different process ... [8895 refs] [8895 refs] [9113 refs] test_sunaudiodev test_sunaudiodev skipped -- No module named sunaudiodev test_sundry test_symtable test_syntax test_sys [8895 refs] [8895 refs] test_tarfile test_tcl test_tcl skipped -- No module named _tkinter test_telnetlib test_tempfile [8901 refs] test_textwrap test_thread test_threaded_import test_threadedtempfile test_threading [13143 refs] test_threading_local test_threadsignals test_time test_timeout test_tokenize test_trace test_traceback test_transformer test_tuple test_typechecks test_ucn test_unary test_unicode test_unicode_file test_unicode_file skipped -- No Unicode filesystem semantics on this platform. test_unicodedata test_univnewlines test_unpack test_urllib test_urllib2 test_urllib2_localnet test_urllib2net test_urllibnet test_urlparse test_userdict test_userlist test_userstring test_uu test_uuid WARNING: uuid.getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._ifconfig_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._unixdll_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. test_wait3 test_wait4 test_warnings test_wave test_weakref test_whichdb test_winreg test_winreg skipped -- No module named _winreg test_winsound test_winsound skipped -- No module named winsound test_with test_wsgiref test_xdrlib test_xml_etree test_xml_etree_c test_xmllib test_xmlrpc test_xpickle test_xrange test_zipfile test_zipfile64 test_zipfile64 skipped -- test requires loads of disk-space bytes and a long time to run test_zipimport test_zlib 313 tests OK. 1 test failed: test_bsddb3 21 tests skipped: test_aepack test_al test_applesingle test_bsddb185 test_cd test_cl test_gl test_imageop test_imgfile test_ioctl test_macostools test_pep277 test_plistlib test_scriptpackages test_startfile test_sunaudiodev test_tcl test_unicode_file test_winreg test_winsound test_zipfile64 1 skip unexpected on linux2: test_ioctl [540161 refs] From buildbot at python.org Sat Jan 19 00:32:53 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 18 Jan 2008 23:32:53 +0000 Subject: [Python-checkins] buildbot failure in x86 mvlgcc trunk Message-ID: <20080118233253.54DF41E4004@bag.python.org> The Buildbot has detected a new failure of x86 mvlgcc trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20mvlgcc%20trunk/builds/1235 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-linux Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: guido.van.rossum,raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_xmlrpc make: *** [buildbottest] Fehler 1 sincerely, -The Buildbot From python-checkins at python.org Sat Jan 19 03:46:51 2008 From: python-checkins at python.org (phillip.eby) Date: Sat, 19 Jan 2008 03:46:51 +0100 (CET) Subject: [Python-checkins] r60065 - in sandbox/trunk/setuptools: setuptools.egg-info/entry_points.txt setuptools/command/develop.py setuptools/command/easy_install.py setuptools/command/install.py setuptools/command/test.py Message-ID: <20080119024651.B19F81E4005@bag.python.org> Author: phillip.eby Date: Sat Jan 19 03:46:51 2008 New Revision: 60065 Modified: sandbox/trunk/setuptools/setuptools.egg-info/entry_points.txt sandbox/trunk/setuptools/setuptools/command/develop.py sandbox/trunk/setuptools/setuptools/command/easy_install.py sandbox/trunk/setuptools/setuptools/command/install.py sandbox/trunk/setuptools/setuptools/command/test.py Log: Fix interactions between the various "require" options, so that downloads aren't repeated and needed eggs are always installed, even if they were downloaded to the setup directory already. Modified: sandbox/trunk/setuptools/setuptools.egg-info/entry_points.txt ============================================================================== --- sandbox/trunk/setuptools/setuptools.egg-info/entry_points.txt (original) +++ sandbox/trunk/setuptools/setuptools.egg-info/entry_points.txt Sat Jan 19 03:46:51 2008 @@ -7,7 +7,6 @@ saveopts = setuptools.command.saveopts:saveopts egg_info = setuptools.command.egg_info:egg_info register = setuptools.command.register:register -upload = setuptools.command.upload:upload install_egg_info = setuptools.command.install_egg_info:install_egg_info alias = setuptools.command.alias:alias easy_install = setuptools.command.easy_install:easy_install @@ -32,7 +31,7 @@ [console_scripts] easy_install = setuptools.command.easy_install:main -easy_install-2.3 = setuptools.command.easy_install:main +easy_install-2.5 = setuptools.command.easy_install:main [setuptools.file_finders] svn_cvs = setuptools.command.sdist:_default_revctrl Modified: sandbox/trunk/setuptools/setuptools/command/develop.py ============================================================================== --- sandbox/trunk/setuptools/setuptools/command/develop.py (original) +++ sandbox/trunk/setuptools/setuptools/command/develop.py Sat Jan 19 03:46:51 2008 @@ -3,7 +3,7 @@ from pkg_resources import Distribution, PathMetadata, normalize_path from distutils import log from distutils.errors import * -import sys, os, setuptools +import sys, os, setuptools, glob class develop(easy_install): """Set up package for development""" @@ -32,7 +32,7 @@ self.egg_path = None easy_install.initialize_options(self) self.setup_path = None - + self.always_copy_from = '.' # always copy eggs installed in curdir @@ -48,9 +48,11 @@ ) self.args = [ei.egg_name] easy_install.finalize_options(self) + # pick up setup-dir .egg files only: no .egg-info + self.package_index.scan(glob.glob('*.egg')) + self.egg_link = os.path.join(self.install_dir, ei.egg_name+'.egg-link') self.egg_base = ei.egg_base - if self.egg_path is None: self.egg_path = os.path.abspath(ei.egg_base) @@ -60,7 +62,6 @@ "--egg-path must be a relative path from the install" " directory to "+target ) - # Make a distribution for the package's source self.dist = Distribution( @@ -79,7 +80,6 @@ "Can't get a consistent path to setup script from" " installation directory", p, normalize_path(os.curdir)) - def install_for_development(self): # Ensure metadata is up-to-date self.run_command('egg_info') Modified: sandbox/trunk/setuptools/setuptools/command/easy_install.py ============================================================================== --- sandbox/trunk/setuptools/setuptools/command/easy_install.py (original) +++ sandbox/trunk/setuptools/setuptools/command/easy_install.py Sat Jan 19 03:46:51 2008 @@ -94,7 +94,7 @@ # Options not specifiable via command line self.package_index = None - self.pth_file = None + self.pth_file = self.always_copy_from = None self.delete_conflicting = None self.ignore_conflicts_at_my_risk = None self.site_dirs = None @@ -455,6 +455,11 @@ install_needed = install_needed or self.always_copy install_needed = install_needed or os.path.dirname(download) == tmpdir install_needed = install_needed or not download.endswith('.egg') + install_needed = install_needed or ( + self.always_copy_from is not None and + os.path.dirname(normalize_path(download)) == + normalize_path(self.always_copy_from) + ) if spec and not install_needed: # at this point, we know it's a local .egg, we just don't know if @@ -485,11 +490,6 @@ - - - - - def process_distribution(self, requirement, dist, deps=True, *info): self.update_pth(dist) self.package_index.add(dist) @@ -527,7 +527,7 @@ "Installed distribution %s conflicts with requirement %s" % e.args ) - if self.always_copy: + if self.always_copy or self.always_copy_from: # Force all the relevant distros to be copied or activated for dist in distros: if dist.key not in self.installed_projects: Modified: sandbox/trunk/setuptools/setuptools/command/install.py ============================================================================== --- sandbox/trunk/setuptools/setuptools/command/install.py (original) +++ sandbox/trunk/setuptools/setuptools/command/install.py Sat Jan 19 03:46:51 2008 @@ -1,4 +1,4 @@ -import setuptools, sys +import setuptools, sys, glob from distutils.command.install import install as _install from distutils.errors import DistutilsArgError @@ -88,6 +88,10 @@ self.distribution, args="x", root=self.root, record=self.record, ) cmd.ensure_finalized() # finalize before bdist_egg munges install cmd + cmd.always_copy_from = '.' # make sure local-dir eggs get installed + + # pick up setup-dir .egg files only: no .egg-info + cmd.package_index.scan(glob.glob('*.egg')) self.run_command('bdist_egg') args = [self.distribution.get_command_obj('bdist_egg').egg_output] @@ -116,8 +120,4 @@ - - - - # Modified: sandbox/trunk/setuptools/setuptools/command/test.py ============================================================================== --- sandbox/trunk/setuptools/setuptools/command/test.py (original) +++ sandbox/trunk/setuptools/setuptools/command/test.py Sat Jan 19 03:46:51 2008 @@ -107,6 +107,8 @@ def run(self): + if self.distribution.install_requires: + self.distribution.fetch_build_eggs(self.distribution.install_requires) if self.distribution.tests_require: self.distribution.fetch_build_eggs(self.distribution.tests_require) @@ -119,8 +121,6 @@ self.with_project_on_sys_path(self.run_tests) - - def run_tests(self): import unittest loader_ep = EntryPoint.parse("x="+self.test_loader) From python-checkins at python.org Sat Jan 19 03:55:04 2008 From: python-checkins at python.org (phillip.eby) Date: Sat, 19 Jan 2008 03:55:04 +0100 (CET) Subject: [Python-checkins] r60066 - in sandbox/branches/setuptools-0.6: setuptools.txt setuptools/command/develop.py setuptools/command/easy_install.py setuptools/command/install.py setuptools/command/test.py Message-ID: <20080119025504.2DB0E1E4014@bag.python.org> Author: phillip.eby Date: Sat Jan 19 03:55:03 2008 New Revision: 60066 Modified: sandbox/branches/setuptools-0.6/setuptools.txt sandbox/branches/setuptools-0.6/setuptools/command/develop.py sandbox/branches/setuptools-0.6/setuptools/command/easy_install.py sandbox/branches/setuptools-0.6/setuptools/command/install.py sandbox/branches/setuptools-0.6/setuptools/command/test.py Log: Fix interactions between the various "require" options, so that downloads aren't repeated and needed eggs are always installed, even if they were downloaded to the setup directory already. (backport from trunk) Modified: sandbox/branches/setuptools-0.6/setuptools.txt ============================================================================== --- sandbox/branches/setuptools-0.6/setuptools.txt (original) +++ sandbox/branches/setuptools-0.6/setuptools.txt Sat Jan 19 03:55:03 2008 @@ -2620,6 +2620,11 @@ * Minor changes for Jython compatibility + * Fixed not installing eggs in ``install_requires`` if they were also used for + ``setup_requires`` or ``tests_require``. + + * Fixed not fetching eggs in ``install_requires`` when running tests. + 0.6c7 * Fixed ``distutils.filelist.findall()`` crashing on broken symlinks, and ``egg_info`` command failing on new, uncommitted SVN directories. Modified: sandbox/branches/setuptools-0.6/setuptools/command/develop.py ============================================================================== --- sandbox/branches/setuptools-0.6/setuptools/command/develop.py (original) +++ sandbox/branches/setuptools-0.6/setuptools/command/develop.py Sat Jan 19 03:55:03 2008 @@ -3,7 +3,7 @@ from pkg_resources import Distribution, PathMetadata, normalize_path from distutils import log from distutils.errors import * -import sys, os, setuptools +import sys, os, setuptools, glob class develop(easy_install): """Set up package for development""" @@ -32,7 +32,7 @@ self.egg_path = None easy_install.initialize_options(self) self.setup_path = None - + self.always_copy_from = '.' # always copy eggs installed in curdir @@ -48,9 +48,11 @@ ) self.args = [ei.egg_name] easy_install.finalize_options(self) + # pick up setup-dir .egg files only: no .egg-info + self.package_index.scan(glob.glob('*.egg')) + self.egg_link = os.path.join(self.install_dir, ei.egg_name+'.egg-link') self.egg_base = ei.egg_base - if self.egg_path is None: self.egg_path = os.path.abspath(ei.egg_base) @@ -60,7 +62,6 @@ "--egg-path must be a relative path from the install" " directory to "+target ) - # Make a distribution for the package's source self.dist = Distribution( @@ -79,7 +80,6 @@ "Can't get a consistent path to setup script from" " installation directory", p, normalize_path(os.curdir)) - def install_for_development(self): # Ensure metadata is up-to-date self.run_command('egg_info') Modified: sandbox/branches/setuptools-0.6/setuptools/command/easy_install.py ============================================================================== --- sandbox/branches/setuptools-0.6/setuptools/command/easy_install.py (original) +++ sandbox/branches/setuptools-0.6/setuptools/command/easy_install.py Sat Jan 19 03:55:03 2008 @@ -94,7 +94,7 @@ # Options not specifiable via command line self.package_index = None - self.pth_file = None + self.pth_file = self.always_copy_from = None self.delete_conflicting = None self.ignore_conflicts_at_my_risk = None self.site_dirs = None @@ -455,6 +455,11 @@ install_needed = install_needed or self.always_copy install_needed = install_needed or os.path.dirname(download) == tmpdir install_needed = install_needed or not download.endswith('.egg') + install_needed = install_needed or ( + self.always_copy_from is not None and + os.path.dirname(normalize_path(download)) == + normalize_path(self.always_copy_from) + ) if spec and not install_needed: # at this point, we know it's a local .egg, we just don't know if @@ -485,11 +490,6 @@ - - - - - def process_distribution(self, requirement, dist, deps=True, *info): self.update_pth(dist) self.package_index.add(dist) @@ -527,7 +527,7 @@ "Installed distribution %s conflicts with requirement %s" % e.args ) - if self.always_copy: + if self.always_copy or self.always_copy_from: # Force all the relevant distros to be copied or activated for dist in distros: if dist.key not in self.installed_projects: Modified: sandbox/branches/setuptools-0.6/setuptools/command/install.py ============================================================================== --- sandbox/branches/setuptools-0.6/setuptools/command/install.py (original) +++ sandbox/branches/setuptools-0.6/setuptools/command/install.py Sat Jan 19 03:55:03 2008 @@ -1,4 +1,4 @@ -import setuptools, sys +import setuptools, sys, glob from distutils.command.install import install as _install from distutils.errors import DistutilsArgError @@ -88,6 +88,10 @@ self.distribution, args="x", root=self.root, record=self.record, ) cmd.ensure_finalized() # finalize before bdist_egg munges install cmd + cmd.always_copy_from = '.' # make sure local-dir eggs get installed + + # pick up setup-dir .egg files only: no .egg-info + cmd.package_index.scan(glob.glob('*.egg')) self.run_command('bdist_egg') args = [self.distribution.get_command_obj('bdist_egg').egg_output] @@ -116,8 +120,4 @@ - - - - # Modified: sandbox/branches/setuptools-0.6/setuptools/command/test.py ============================================================================== --- sandbox/branches/setuptools-0.6/setuptools/command/test.py (original) +++ sandbox/branches/setuptools-0.6/setuptools/command/test.py Sat Jan 19 03:55:03 2008 @@ -107,6 +107,8 @@ def run(self): + if self.distribution.install_requires: + self.distribution.fetch_build_eggs(self.distribution.install_requires) if self.distribution.tests_require: self.distribution.fetch_build_eggs(self.distribution.tests_require) @@ -119,8 +121,6 @@ self.with_project_on_sys_path(self.run_tests) - - def run_tests(self): import unittest loader_ep = EntryPoint.parse("x="+self.test_loader) From python-checkins at python.org Sat Jan 19 10:56:06 2008 From: python-checkins at python.org (jeffrey.yasskin) Date: Sat, 19 Jan 2008 10:56:06 +0100 (CET) Subject: [Python-checkins] r60068 - in python/trunk: Doc/library/rational.rst Lib/rational.py Lib/test/test_rational.py Message-ID: <20080119095606.BFB5E1E4014@bag.python.org> Author: jeffrey.yasskin Date: Sat Jan 19 10:56:06 2008 New Revision: 60068 Modified: python/trunk/Doc/library/rational.rst python/trunk/Lib/rational.py python/trunk/Lib/test/test_rational.py Log: Several tweaks: add construction from strings and .from_decimal(), change __init__ to __new__ to enforce immutability, and remove "rational." from repr and the parens from str. Modified: python/trunk/Doc/library/rational.rst ============================================================================== --- python/trunk/Doc/library/rational.rst (original) +++ python/trunk/Doc/library/rational.rst Sat Jan 19 10:56:06 2008 @@ -15,6 +15,7 @@ .. class:: Rational(numerator=0, denominator=1) Rational(other_rational) + Rational(string) The first version requires that *numerator* and *denominator* are instances of :class:`numbers.Integral` and returns a new @@ -22,10 +23,12 @@ *denominator* is :const:`0`, raises a :exc:`ZeroDivisionError`. The second version requires that *other_rational* is an instance of :class:`numbers.Rational` and returns an instance of - :class:`Rational` with the same value. + :class:`Rational` with the same value. The third version expects a + string of the form ``[-+]?[0-9]+(/[0-9]+)?``, optionally surrounded + by spaces. Implements all of the methods and operations from - :class:`numbers.Rational` and is hashable. + :class:`numbers.Rational` and is immutable and hashable. .. method:: Rational.from_float(flt) @@ -36,6 +39,13 @@ 10)`` +.. method:: Rational.from_decimal(dec) + + This classmethod constructs a :class:`Rational` representing the + exact value of *dec*, which must be a + :class:`decimal.Decimal`. + + .. method:: Rational.__floor__() Returns the greatest :class:`int` ``<= self``. Will be accessible Modified: python/trunk/Lib/rational.py ============================================================================== --- python/trunk/Lib/rational.py (original) +++ python/trunk/Lib/rational.py Sat Jan 19 10:56:06 2008 @@ -7,6 +7,7 @@ import math import numbers import operator +import re __all__ = ["Rational"] @@ -76,6 +77,10 @@ return (top, 2 ** -e) +_RATIONAL_FORMAT = re.compile( + r'^\s*(?P[-+]?)(?P\d+)(?:/(?P\d+))?\s*$') + + class Rational(RationalAbc): """This class implements rational numbers. @@ -84,18 +89,41 @@ and the denominator defaults to 1 so that Rational(3) == 3 and Rational() == 0. + Rationals can also be constructed from strings of the form + '[-+]?[0-9]+(/[0-9]+)?', optionally surrounded by spaces. + """ __slots__ = ('_numerator', '_denominator') - def __init__(self, numerator=0, denominator=1): - if (not isinstance(numerator, numbers.Integral) and - isinstance(numerator, RationalAbc) and - denominator == 1): - # Handle copies from other rationals. - other_rational = numerator - numerator = other_rational.numerator - denominator = other_rational.denominator + # We're immutable, so use __new__ not __init__ + def __new__(cls, numerator=0, denominator=1): + """Constructs a Rational. + + Takes a string, another Rational, or a numerator/denominator pair. + + """ + self = super(Rational, cls).__new__(cls) + + if denominator == 1: + if isinstance(numerator, basestring): + # Handle construction from strings. + input = numerator + m = _RATIONAL_FORMAT.match(input) + if m is None: + raise ValueError('Invalid literal for Rational: ' + input) + numerator = int(m.group('num')) + # Default denominator to 1. That's the only optional group. + denominator = int(m.group('denom') or 1) + if m.group('sign') == '-': + numerator = -numerator + + elif (not isinstance(numerator, numbers.Integral) and + isinstance(numerator, RationalAbc)): + # Handle copies from other rationals. + other_rational = numerator + numerator = other_rational.numerator + denominator = other_rational.denominator if (not isinstance(numerator, numbers.Integral) or not isinstance(denominator, numbers.Integral)): @@ -108,10 +136,15 @@ g = _gcd(numerator, denominator) self._numerator = int(numerator // g) self._denominator = int(denominator // g) + return self @classmethod def from_float(cls, f): - """Converts a float to a rational number, exactly.""" + """Converts a finite float to a rational number, exactly. + + Beware that Rational.from_float(0.3) != Rational(3, 10). + + """ if not isinstance(f, float): raise TypeError("%s.from_float() only takes floats, not %r (%s)" % (cls.__name__, f, type(f).__name__)) @@ -119,6 +152,26 @@ raise TypeError("Cannot convert %r to %s." % (f, cls.__name__)) return cls(*_binary_float_to_ratio(f)) + @classmethod + def from_decimal(cls, dec): + """Converts a finite Decimal instance to a rational number, exactly.""" + from decimal import Decimal + if not isinstance(dec, Decimal): + raise TypeError( + "%s.from_decimal() only takes Decimals, not %r (%s)" % + (cls.__name__, dec, type(dec).__name__)) + if not dec.is_finite(): + # Catches infinities and nans. + raise TypeError("Cannot convert %s to %s." % (dec, cls.__name__)) + sign, digits, exp = dec.as_tuple() + digits = int(''.join(map(str, digits))) + if sign: + digits = -digits + if exp >= 0: + return cls(digits * 10 ** exp) + else: + return cls(digits, 10 ** -exp) + @property def numerator(a): return a._numerator @@ -129,15 +182,14 @@ def __repr__(self): """repr(self)""" - return ('rational.Rational(%r,%r)' % - (self.numerator, self.denominator)) + return ('Rational(%r,%r)' % (self.numerator, self.denominator)) def __str__(self): """str(self)""" if self.denominator == 1: return str(self.numerator) else: - return '(%s/%s)' % (self.numerator, self.denominator) + return '%s/%s' % (self.numerator, self.denominator) def _operator_fallbacks(monomorphic_operator, fallback_operator): """Generates forward and reverse operators given a purely-rational Modified: python/trunk/Lib/test/test_rational.py ============================================================================== --- python/trunk/Lib/test/test_rational.py (original) +++ python/trunk/Lib/test/test_rational.py Sat Jan 19 10:56:06 2008 @@ -45,6 +45,44 @@ self.assertRaises(TypeError, R, 1.5) self.assertRaises(TypeError, R, 1.5 + 3j) + self.assertRaises(TypeError, R, R(1, 2), 3) + self.assertRaises(TypeError, R, "3/2", 3) + + def testFromString(self): + self.assertEquals((5, 1), _components(R("5"))) + self.assertEquals((3, 2), _components(R("3/2"))) + self.assertEquals((3, 2), _components(R(" \n +3/2"))) + self.assertEquals((-3, 2), _components(R("-3/2 "))) + self.assertEquals((3, 2), _components(R(" 03/02 \n "))) + self.assertEquals((3, 2), _components(R(u" 03/02 \n "))) + + self.assertRaisesMessage( + ZeroDivisionError, "Rational(3, 0)", + R, "3/0") + self.assertRaisesMessage( + ValueError, "Invalid literal for Rational: 3/", + R, "3/") + self.assertRaisesMessage( + ValueError, "Invalid literal for Rational: 3 /2", + R, "3 /2") + self.assertRaisesMessage( + # Denominators don't need a sign. + ValueError, "Invalid literal for Rational: 3/+2", + R, "3/+2") + self.assertRaisesMessage( + # Imitate float's parsing. + ValueError, "Invalid literal for Rational: + 3/2", + R, "+ 3/2") + self.assertRaisesMessage( + # Only parse fractions, not decimals. + ValueError, "Invalid literal for Rational: 3.2", + R, "3.2") + + def testImmutable(self): + r = R(7, 3) + r.__init__(2, 15) + self.assertEquals((7, 3), _components(r)) + def testFromFloat(self): self.assertRaisesMessage( TypeError, "Rational.from_float() only takes floats, not 3 (int)", @@ -72,6 +110,31 @@ TypeError, "Cannot convert nan to Rational.", R.from_float, nan) + def testFromDecimal(self): + self.assertRaisesMessage( + TypeError, + "Rational.from_decimal() only takes Decimals, not 3 (int)", + R.from_decimal, 3) + self.assertEquals(R(0), R.from_decimal(Decimal("-0"))) + self.assertEquals(R(5, 10), R.from_decimal(Decimal("0.5"))) + self.assertEquals(R(5, 1000), R.from_decimal(Decimal("5e-3"))) + self.assertEquals(R(5000), R.from_decimal(Decimal("5e3"))) + self.assertEquals(1 - R(1, 10**30), + R.from_decimal(Decimal("0." + "9" * 30))) + + self.assertRaisesMessage( + TypeError, "Cannot convert Infinity to Rational.", + R.from_decimal, Decimal("inf")) + self.assertRaisesMessage( + TypeError, "Cannot convert -Infinity to Rational.", + R.from_decimal, Decimal("-inf")) + self.assertRaisesMessage( + TypeError, "Cannot convert NaN to Rational.", + R.from_decimal, Decimal("nan")) + self.assertRaisesMessage( + TypeError, "Cannot convert sNaN to Rational.", + R.from_decimal, Decimal("snan")) + def testConversions(self): self.assertTypedEquals(-1, trunc(R(-11, 10))) self.assertTypedEquals(-2, R(-11, 10).__floor__()) @@ -173,7 +236,7 @@ self.assertTypedEquals(1.0 + 0j, (1.0 + 0j) ** R(1, 10)) def testMixingWithDecimal(self): - """Decimal refuses mixed comparisons.""" + # Decimal refuses mixed comparisons. self.assertRaisesMessage( TypeError, "unsupported operand type(s) for +: 'Rational' and 'Decimal'", @@ -236,8 +299,8 @@ self.assertFalse(R(5, 2) == 2) def testStringification(self): - self.assertEquals("rational.Rational(7,3)", repr(R(7, 3))) - self.assertEquals("(7/3)", str(R(7, 3))) + self.assertEquals("Rational(7,3)", repr(R(7, 3))) + self.assertEquals("7/3", str(R(7, 3))) self.assertEquals("7", str(R(7, 1))) def testHash(self): From nnorwitz at gmail.com Sat Jan 19 11:28:56 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Sat, 19 Jan 2008 05:28:56 -0500 Subject: [Python-checkins] Python Regression Test Failures refleak (9) Message-ID: <20080119102856.GA21750@python.psfb.org> test_opcodes leaked [-2, 0, 2] references, sum=0 test_doctest leaked [0, 0, -4] references, sum=-4 test_descrtut leaked [-2, 2, 2] references, sum=2 test_difflib leaked [-2, 0, 0] references, sum=-2 test_future leaked [0, 0, -2] references, sum=-2 test_gc leaked [0, 2, 0] references, sum=2 test_importhooks leaked [10, -2, -2] references, sum=6 test_parser leaked [-2, 0, 0] references, sum=-2 test_popen leaked [0, 0, -2] references, sum=-2 test_urllib2_localnet leaked [3, 3, 3] references, sum=9 test_weakref leaked [2, 0, 0] references, sum=2 From python-checkins at python.org Sat Jan 19 11:11:28 2008 From: python-checkins at python.org (georg.brandl) Date: Sat, 19 Jan 2008 11:11:28 +0100 (CET) Subject: [Python-checkins] r60069 - python/trunk/Doc/library/logging.rst Message-ID: <20080119101128.385781E4016@bag.python.org> Author: georg.brandl Date: Sat Jan 19 11:11:27 2008 New Revision: 60069 Modified: python/trunk/Doc/library/logging.rst Log: Fix markup. Modified: python/trunk/Doc/library/logging.rst ============================================================================== --- python/trunk/Doc/library/logging.rst (original) +++ python/trunk/Doc/library/logging.rst Sat Jan 19 11:11:27 2008 @@ -1198,65 +1198,65 @@ also illustrates what dict-like behaviour is needed from an arbitrary "dict-like" object for use in the constructor:: -import logging - -class ConnInfo: - """ - An example class which shows how an arbitrary class can be used as - the 'extra' context information repository passed to a LoggerAdapter. - """ - - def __getitem__(self, name): - """ - To allow this instance to look like a dict. - """ - from random import choice - if name == "ip": - result = choice(["127.0.0.1", "192.168.0.1"]) - elif name == "user": - result = choice(["jim", "fred", "sheila"]) - else: - result = self.__dict__.get(name, "?") - return result - - def __iter__(self): - """ - To allow iteration over keys, which will be merged into - the LogRecord dict before formatting and output. - """ - keys = ["ip", "user"] - keys.extend(self.__dict__.keys()) - return keys.__iter__() - -if __name__ == "__main__": - from random import choice - levels = (logging.DEBUG, logging.INFO, logging.WARNING, logging.ERROR, logging.CRITICAL) - a1 = logging.LoggerAdapter(logging.getLogger("a.b.c"), - { "ip" : "123.231.231.123", "user" : "sheila" }) - logging.basicConfig(level=logging.DEBUG, - format="%(asctime)-15s %(name)-5s %(levelname)-8s IP: %(ip)-15s User: %(user)-8s %(message)s") - a1.debug("A debug message") - a1.info("An info message with %s", "some parameters") - a2 = logging.LoggerAdapter(logging.getLogger("d.e.f"), ConnInfo()) - for x in range(10): - lvl = choice(levels) - lvlname = logging.getLevelName(lvl) - a2.log(lvl, "A message at %s level with %d %s", lvlname, 2, "parameters") + import logging + + class ConnInfo: + """ + An example class which shows how an arbitrary class can be used as + the 'extra' context information repository passed to a LoggerAdapter. + """ + + def __getitem__(self, name): + """ + To allow this instance to look like a dict. + """ + from random import choice + if name == "ip": + result = choice(["127.0.0.1", "192.168.0.1"]) + elif name == "user": + result = choice(["jim", "fred", "sheila"]) + else: + result = self.__dict__.get(name, "?") + return result + + def __iter__(self): + """ + To allow iteration over keys, which will be merged into + the LogRecord dict before formatting and output. + """ + keys = ["ip", "user"] + keys.extend(self.__dict__.keys()) + return keys.__iter__() + + if __name__ == "__main__": + from random import choice + levels = (logging.DEBUG, logging.INFO, logging.WARNING, logging.ERROR, logging.CRITICAL) + a1 = logging.LoggerAdapter(logging.getLogger("a.b.c"), + { "ip" : "123.231.231.123", "user" : "sheila" }) + logging.basicConfig(level=logging.DEBUG, + format="%(asctime)-15s %(name)-5s %(levelname)-8s IP: %(ip)-15s User: %(user)-8s %(message)s") + a1.debug("A debug message") + a1.info("An info message with %s", "some parameters") + a2 = logging.LoggerAdapter(logging.getLogger("d.e.f"), ConnInfo()) + for x in range(10): + lvl = choice(levels) + lvlname = logging.getLevelName(lvl) + a2.log(lvl, "A message at %s level with %d %s", lvlname, 2, "parameters") When this script is run, the output should look something like this:: -2008-01-18 14:49:54,023 a.b.c DEBUG IP: 123.231.231.123 User: sheila A debug message -2008-01-18 14:49:54,023 a.b.c INFO IP: 123.231.231.123 User: sheila An info message with some parameters -2008-01-18 14:49:54,023 d.e.f CRITICAL IP: 192.168.0.1 User: jim A message at CRITICAL level with 2 parameters -2008-01-18 14:49:54,033 d.e.f INFO IP: 192.168.0.1 User: jim A message at INFO level with 2 parameters -2008-01-18 14:49:54,033 d.e.f WARNING IP: 192.168.0.1 User: sheila A message at WARNING level with 2 parameters -2008-01-18 14:49:54,033 d.e.f ERROR IP: 127.0.0.1 User: fred A message at ERROR level with 2 parameters -2008-01-18 14:49:54,033 d.e.f ERROR IP: 127.0.0.1 User: sheila A message at ERROR level with 2 parameters -2008-01-18 14:49:54,033 d.e.f WARNING IP: 192.168.0.1 User: sheila A message at WARNING level with 2 parameters -2008-01-18 14:49:54,033 d.e.f WARNING IP: 192.168.0.1 User: jim A message at WARNING level with 2 parameters -2008-01-18 14:49:54,033 d.e.f INFO IP: 192.168.0.1 User: fred A message at INFO level with 2 parameters -2008-01-18 14:49:54,033 d.e.f WARNING IP: 192.168.0.1 User: sheila A message at WARNING level with 2 parameters -2008-01-18 14:49:54,033 d.e.f WARNING IP: 127.0.0.1 User: jim A message at WARNING level with 2 parameters + 2008-01-18 14:49:54,023 a.b.c DEBUG IP: 123.231.231.123 User: sheila A debug message + 2008-01-18 14:49:54,023 a.b.c INFO IP: 123.231.231.123 User: sheila An info message with some parameters + 2008-01-18 14:49:54,023 d.e.f CRITICAL IP: 192.168.0.1 User: jim A message at CRITICAL level with 2 parameters + 2008-01-18 14:49:54,033 d.e.f INFO IP: 192.168.0.1 User: jim A message at INFO level with 2 parameters + 2008-01-18 14:49:54,033 d.e.f WARNING IP: 192.168.0.1 User: sheila A message at WARNING level with 2 parameters + 2008-01-18 14:49:54,033 d.e.f ERROR IP: 127.0.0.1 User: fred A message at ERROR level with 2 parameters + 2008-01-18 14:49:54,033 d.e.f ERROR IP: 127.0.0.1 User: sheila A message at ERROR level with 2 parameters + 2008-01-18 14:49:54,033 d.e.f WARNING IP: 192.168.0.1 User: sheila A message at WARNING level with 2 parameters + 2008-01-18 14:49:54,033 d.e.f WARNING IP: 192.168.0.1 User: jim A message at WARNING level with 2 parameters + 2008-01-18 14:49:54,033 d.e.f INFO IP: 192.168.0.1 User: fred A message at INFO level with 2 parameters + 2008-01-18 14:49:54,033 d.e.f WARNING IP: 192.168.0.1 User: sheila A message at WARNING level with 2 parameters + 2008-01-18 14:49:54,033 d.e.f WARNING IP: 127.0.0.1 User: jim A message at WARNING level with 2 parameters .. versionadded:: 2.6 From python-checkins at python.org Sat Jan 19 11:16:09 2008 From: python-checkins at python.org (georg.brandl) Date: Sat, 19 Jan 2008 11:16:09 +0100 (CET) Subject: [Python-checkins] r60070 - python/trunk/Doc/library/curses.rst Message-ID: <20080119101609.947961E4014@bag.python.org> Author: georg.brandl Date: Sat Jan 19 11:16:09 2008 New Revision: 60070 Modified: python/trunk/Doc/library/curses.rst Log: Amend curses docs by info how to write non-ascii characters. Thanks to Jeroen Ruigrok van der Werven. Modified: python/trunk/Doc/library/curses.rst ============================================================================== --- python/trunk/Doc/library/curses.rst (original) +++ python/trunk/Doc/library/curses.rst Sat Jan 19 11:16:09 2008 @@ -19,6 +19,19 @@ designed to match the API of ncurses, an open-source curses library hosted on Linux and the BSD variants of Unix. +.. note:: + + Since version 5.4, the ncurses library decides how to interpret non-ASCII data + using the ``nl_langinfo`` function. That means that you have to call + :func:`locale.setlocale` in the application and use one of the system's + available encodings to encode Unicode strings with it. This example uses the + system's default encoding:: + + import locale + locale.setlocale(locale.LC_ALL, '') + code = locale.getpreferredencoding() + + Then use *code* as the encoding for :meth:`str.encode` calls. .. seealso:: From python-checkins at python.org Sat Jan 19 11:18:07 2008 From: python-checkins at python.org (georg.brandl) Date: Sat, 19 Jan 2008 11:18:07 +0100 (CET) Subject: [Python-checkins] r60071 - python/trunk/Objects/complexobject.c Message-ID: <20080119101807.62FF71E4014@bag.python.org> Author: georg.brandl Date: Sat Jan 19 11:18:07 2008 New Revision: 60071 Modified: python/trunk/Objects/complexobject.c Log: Indentation normalization. Modified: python/trunk/Objects/complexobject.c ============================================================================== --- python/trunk/Objects/complexobject.c (original) +++ python/trunk/Objects/complexobject.c Sat Jan 19 11:18:07 2008 @@ -489,7 +489,7 @@ static PyObject * complex_remainder(PyComplexObject *v, PyComplexObject *w) { - Py_complex div, mod; + Py_complex div, mod; if (PyErr_Warn(PyExc_DeprecationWarning, "complex divmod(), // and % are deprecated") < 0) @@ -512,7 +512,7 @@ static PyObject * complex_divmod(PyComplexObject *v, PyComplexObject *w) { - Py_complex div, mod; + Py_complex div, mod; PyObject *d, *m, *z; if (PyErr_Warn(PyExc_DeprecationWarning, @@ -543,8 +543,8 @@ Py_complex exponent; long int_exponent; Py_complex a, b; - TO_COMPLEX(v, a); - TO_COMPLEX(w, b); + TO_COMPLEX(v, a); + TO_COMPLEX(w, b); if (z!=Py_None) { PyErr_SetString(PyExc_ValueError, "complex modulo"); @@ -809,11 +809,11 @@ start = s; while (*s && isspace(Py_CHARMASK(*s))) s++; - if (s[0] == '\0') { + if (s[0] == '\0') { PyErr_SetString(PyExc_ValueError, "complex() arg is an empty string"); return NULL; - } + } if (s[0] == '(') { /* Skip over possible bracket from repr(). */ got_bracket = 1; @@ -973,7 +973,7 @@ "complex() can't take second arg" " if first is a string"); return NULL; - } + } return complex_subtype_from_string(type, r); } if (i != NULL && (PyString_Check(i) || PyUnicode_Check(i))) { @@ -1051,7 +1051,7 @@ return NULL; } cr.real = PyFloat_AsDouble(tmp); - cr.imag = 0.0; /* Shut up compiler warning */ + cr.imag = 0.0; /* Shut up compiler warning */ Py_DECREF(tmp); } if (i == NULL) { From nnorwitz at gmail.com Sat Jan 19 11:46:12 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Sat, 19 Jan 2008 05:46:12 -0500 Subject: [Python-checkins] Python Regression Test Failures all (1) Message-ID: <20080119104612.GA23660@python.psfb.org> test_grammar test_opcodes test_dict test_builtin test_exceptions test_types test_unittest test_doctest test_doctest2 test_MimeWriter test_StringIO test___all__ test___future__ test__locale test_abc test_abstract_numbers test_aepack test_aepack skipped -- No module named aepack test_al test_al skipped -- No module named al test_anydbm test_applesingle test_applesingle skipped -- No module named macostools test_array test_ast test_asynchat test_asyncore test_atexit test_audioop test_augassign test_base64 test_bastion test_bigaddrspace test_bigmem test_binascii test_binhex test_binop test_bisect test_bool test_bsddb test_bsddb185 test_bsddb185 skipped -- No module named bsddb185 test_bsddb3 test test_bsddb3 failed -- errors occurred; run in verbose mode for details test_buffer test_bufio test_bz2 test_cProfile test_calendar test_call test_capi test_cd test_cd skipped -- No module named cd test_cfgparser test_cgi test_charmapcodec test_cl test_cl skipped -- No module named cl test_class test_cmath test_cmd test_cmd_line test_cmd_line_script test_code test_codeccallbacks test_codecencodings_cn test_codecencodings_hk test_codecencodings_jp test_codecencodings_kr test_codecencodings_tw test_codecmaps_cn test_codecmaps_hk test_codecmaps_jp test_codecmaps_kr test_codecmaps_tw test_codecs test_codeop test_coding test_coercion test_collections test_colorsys test_commands test_compare test_compile test_compiler testCompileLibrary still working, be patient... test_complex test_complex_args test_contains test_contextlib test_cookie test_cookielib test_copy test_copy_reg test_cpickle test_crypt test_csv test_ctypes test_datetime test_dbm test_decimal test_decorators test_defaultdict test_deque test_descr test_descrtut test_difflib test_dircache test_dis test_distutils test_dl test_docxmlrpc test_dumbdbm test_dummy_thread test_dummy_threading test_email test_email_codecs test_email_renamed test_enumerate test_eof test_errno test_exception_variations test_extcall test_fcntl test_file test_filecmp test_fileinput test_float test_fnmatch test_fork1 test_format test_fpformat test_frozen test_ftplib test_funcattrs test_functools test_future test_gc test_gdbm test_generators test_genericpath test_genexps test_getargs test_getargs2 test_getopt test_gettext test_gl test_gl skipped -- No module named gl test_glob test_global test_grp test_gzip test_hash test_hashlib test_heapq test_hexoct test_hmac test_hotshot test_htmllib test_htmlparser test_httplib test_imageop test_imageop skipped -- No module named imgfile test_imaplib test_imgfile test_imgfile skipped -- No module named imgfile test_imp test_import test_importhooks test_index test_inspect test_ioctl test_ioctl skipped -- Unable to open /dev/tty test_isinstance test_iter test_iterlen test_itertools test_largefile test_list test_locale test_logging test_long test_long_future test_longexp test_macostools test_macostools skipped -- No module named macostools test_macpath test_mailbox test_marshal test_math test_md5 test_mhlib test_mimetools test_mimetypes test_minidom test_mmap test_module test_modulefinder test_multibytecodec test_multibytecodec_support test_multifile test_mutants test_netrc test_new test_nis test_normalization test_ntpath test_old_mailbox test_openpty test_operator test_optparse test_os test_parser test_peepholer test_pep247 test_pep263 test_pep277 test_pep277 skipped -- test works only on NT+ test_pep292 test_pep352 test_pickle test_pickletools test_pipes test_pkg test_pkgimport test_platform test_plistlib test_plistlib skipped -- No module named plistlib test_poll test_popen [8900 refs] [8900 refs] [8900 refs] test_popen2 test_poplib test_posix test_posixpath test_pow test_pprint test_profile test_profilehooks test_property test_pty test_pwd test_pyclbr test_pyexpat test_queue test_quopri [9269 refs] [9269 refs] test_random test_rational test_re test_repr test_resource test_rfc822 test_richcmp test_robotparser test_runpy test_sax test_scope test_scriptpackages test_scriptpackages skipped -- No module named aetools test_select test_set test_sets test_sgmllib test_sha test_shelve test_shlex test_shutil test_signal test_site test_slice test_smtplib test_socket test_socket_ssl /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:94: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ssl_sock = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:60: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:130: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:144: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) test_socketserver test_softspace test_sort test_sqlite test_ssl test_startfile test_startfile skipped -- cannot import name startfile test_str test_strftime test_string test_stringprep test_strop test_strptime test_struct test_structmembers test_structseq test_subprocess [8895 refs] [8898 refs] [8895 refs] [8895 refs] [8895 refs] [8895 refs] [8895 refs] [8895 refs] [8895 refs] [8897 refs] [8898 refs] [10449 refs] [9113 refs] [8898 refs] [8895 refs] [8895 refs] [8895 refs] [8895 refs] [8895 refs] . [8895 refs] [8895 refs] this bit of output is from a test of stdout in a different process ... [8895 refs] [8895 refs] [9113 refs] test_sunaudiodev test_sunaudiodev skipped -- No module named sunaudiodev test_sundry test_symtable test_syntax test_sys [8895 refs] [8895 refs] test_tarfile test_tcl test_tcl skipped -- No module named _tkinter test_telnetlib test_tempfile [8901 refs] test_textwrap test_thread test_threaded_import test_threadedtempfile test_threading [13143 refs] test_threading_local test_threadsignals test_time test_timeout test_tokenize test_trace test_traceback test_transformer test_tuple test_typechecks test_ucn test_unary test_unicode test_unicode_file test_unicode_file skipped -- No Unicode filesystem semantics on this platform. test_unicodedata test_univnewlines test_unpack test_urllib test_urllib2 test_urllib2_localnet test_urllib2net test_urllibnet test_urlparse test_userdict test_userlist test_userstring test_uu test_uuid WARNING: uuid.getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._ifconfig_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._unixdll_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. test_wait3 test_wait4 test_warnings test_wave test_weakref test_whichdb test_winreg test_winreg skipped -- No module named _winreg test_winsound test_winsound skipped -- No module named winsound test_with test_wsgiref test_xdrlib test_xml_etree test_xml_etree_c test_xmllib test_xmlrpc test_xpickle test_xrange test_zipfile test_zipfile64 test_zipfile64 skipped -- test requires loads of disk-space bytes and a long time to run test_zipimport test_zlib 313 tests OK. 1 test failed: test_bsddb3 21 tests skipped: test_aepack test_al test_applesingle test_bsddb185 test_cd test_cl test_gl test_imageop test_imgfile test_ioctl test_macostools test_pep277 test_plistlib test_scriptpackages test_startfile test_sunaudiodev test_tcl test_unicode_file test_winreg test_winsound test_zipfile64 1 skip unexpected on linux2: test_ioctl [540163 refs] From buildbot at python.org Sat Jan 19 12:47:57 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 19 Jan 2008 11:47:57 +0000 Subject: [Python-checkins] buildbot failure in g4 osx.4 trunk Message-ID: <20080119114757.CB2331E4014@bag.python.org> The Buildbot has detected a new failure of g4 osx.4 trunk. Full details are available at: http://www.python.org/dev/buildbot/all/g4%20osx.4%20trunk/builds/2639 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: psf-g4 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: georg.brandl BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30995, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30995, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30995, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/bsddb/test/test_thread.py", line 260, in writerThread self.assertEqual(data, self.makeData(key)) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/unittest.py", line 343, in failUnlessEqual (msg or '%r != %r' % (first, second)) AssertionError: None != '0004-0004-0004-0004-0004' Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/bsddb/test/test_thread.py", line 260, in writerThread self.assertEqual(data, self.makeData(key)) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/unittest.py", line 343, in failUnlessEqual (msg or '%r != %r' % (first, second)) AssertionError: None != '2000-2000-2000-2000-2000' Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/bsddb/test/test_thread.py", line 260, in writerThread self.assertEqual(data, self.makeData(key)) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/unittest.py", line 343, in failUnlessEqual (msg or '%r != %r' % (first, second)) AssertionError: None != '1005-1005-1005-1005-1005' 1 test failed: test_urllibnet make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Sat Jan 19 12:49:37 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 19 Jan 2008 11:49:37 +0000 Subject: [Python-checkins] buildbot failure in x86 FreeBSD trunk Message-ID: <20080119114937.D74A11E4014@bag.python.org> The Buildbot has detected a new failure of x86 FreeBSD trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20FreeBSD%20trunk/builds/423 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-freebsd Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: jeffrey.yasskin BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 523, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable 1 test failed: test_socket_ssl sincerely, -The Buildbot From python-checkins at python.org Sat Jan 19 13:32:27 2008 From: python-checkins at python.org (facundo.batista) Date: Sat, 19 Jan 2008 13:32:27 +0100 (CET) Subject: [Python-checkins] r60073 - in python/trunk: Lib/email/mime/multipart.py Lib/email/test/test_email.py Misc/NEWS Message-ID: <20080119123227.F177B1E4016@bag.python.org> Author: facundo.batista Date: Sat Jan 19 13:32:27 2008 New Revision: 60073 Modified: python/trunk/Lib/email/mime/multipart.py python/trunk/Lib/email/test/test_email.py python/trunk/Misc/NEWS Log: Fix issue #1822: MIMEMultipart.is_multipart() behaves correctly for a just-created (and empty) instance. Added tests for this. Thanks Jonathan Share. Modified: python/trunk/Lib/email/mime/multipart.py ============================================================================== --- python/trunk/Lib/email/mime/multipart.py (original) +++ python/trunk/Lib/email/mime/multipart.py Sat Jan 19 13:32:27 2008 @@ -34,6 +34,12 @@ keyword arguments (or passed into the _params argument). """ MIMEBase.__init__(self, 'multipart', _subtype, **_params) + + # Initialise _payload to an empty list as the Message superclass's + # implementation of is_multipart assumes that _payload is a list for + # multipart messages. + self._payload = [] + if _subparts: for p in _subparts: self.attach(p) Modified: python/trunk/Lib/email/test/test_email.py ============================================================================== --- python/trunk/Lib/email/test/test_email.py (original) +++ python/trunk/Lib/email/test/test_email.py Sat Jan 19 13:32:27 2008 @@ -1861,6 +1861,9 @@ eq(msg.get_payload(0), text1) eq(msg.get_payload(1), text2) + def test_default_multipart_constructor(self): + msg = MIMEMultipart() + self.assertTrue(msg.is_multipart()) # A general test of parser->model->generator idempotency. IOW, read a message Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Sat Jan 19 13:32:27 2008 @@ -367,6 +367,9 @@ Library ------- +- #1822: MIMEMultipart.is_multipart() behaves correctly for a just-created + (and empty) instance. Thanks Jonathan Share. + - #1861: Added an attribute to the sched module which returns an ordered list of upcoming events (displayed as named tuples). From buildbot at python.org Sat Jan 19 14:15:19 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 19 Jan 2008 13:15:19 +0000 Subject: [Python-checkins] buildbot failure in ppc Debian unstable 3.0 Message-ID: <20080119131519.556861E4016@bag.python.org> The Buildbot has detected a new failure of ppc Debian unstable 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/ppc%20Debian%20unstable%203.0/builds/469 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes,jeffrey.yasskin,raymond.hettinger,thomas.heller BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 522, in __init__ self.handle() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/BaseHTTPServer.py", line 330, in handle self.handle_one_request() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/BaseHTTPServer.py", line 324, in handle_one_request method() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SimpleXMLRPCServer.py", line 430, in do_POST self.report_404() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SimpleXMLRPCServer.py", line 489, in report_404 self.connection.shutdown(1) socket.error: [Errno 107] Transport endpoint is not connected 1 test failed: test_xmlrpc Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 522, in __init__ self.handle() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/BaseHTTPServer.py", line 330, in handle self.handle_one_request() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/BaseHTTPServer.py", line 324, in handle_one_request method() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SimpleXMLRPCServer.py", line 430, in do_POST self.report_404() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SimpleXMLRPCServer.py", line 489, in report_404 self.connection.shutdown(1) socket.error: [Errno 107] Transport endpoint is not connected ====================================================================== ERROR: test_fail_no_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/test/test_xmlrpc.py", line 497, in test_fail_no_info p.pow(6,8) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1091, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1349, in __request verbose=self.__verbose File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1121, in request resp = http_conn.getresponse() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/httplib.py", line 961, in getresponse response.begin() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/httplib.py", line 425, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/httplib.py", line 267, in readheaders line = str(self.fp.readline(), "iso-8859-1") File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/io.py", line 413, in readline b = self.read(nreadahead()) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/io.py", line 475, in read n = self.readinto(b) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/socket.py", line 217, in readinto return self._sock.recv_into(b) socket.error: [Errno 104] Connection reset by peer ====================================================================== ERROR: test_fail_with_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/test/test_xmlrpc.py", line 515, in test_fail_with_info p.pow(6,8) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1091, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1349, in __request verbose=self.__verbose File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1121, in request resp = http_conn.getresponse() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/httplib.py", line 961, in getresponse response.begin() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/httplib.py", line 425, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/httplib.py", line 267, in readheaders line = str(self.fp.readline(), "iso-8859-1") File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/io.py", line 413, in readline b = self.read(nreadahead()) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/io.py", line 475, in read n = self.readinto(b) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/socket.py", line 217, in readinto return self._sock.recv_into(b) socket.error: [Errno 104] Connection reset by peer make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Sat Jan 19 14:33:21 2008 From: python-checkins at python.org (andrew.kuchling) Date: Sat, 19 Jan 2008 14:33:21 +0100 (CET) Subject: [Python-checkins] r60074 - python/trunk/Doc/library/curses.rst Message-ID: <20080119133321.319981E4016@bag.python.org> Author: andrew.kuchling Date: Sat Jan 19 14:33:20 2008 New Revision: 60074 Modified: python/trunk/Doc/library/curses.rst Log: Polish sentence Modified: python/trunk/Doc/library/curses.rst ============================================================================== --- python/trunk/Doc/library/curses.rst (original) +++ python/trunk/Doc/library/curses.rst Sat Jan 19 14:33:20 2008 @@ -23,8 +23,8 @@ Since version 5.4, the ncurses library decides how to interpret non-ASCII data using the ``nl_langinfo`` function. That means that you have to call - :func:`locale.setlocale` in the application and use one of the system's - available encodings to encode Unicode strings with it. This example uses the + :func:`locale.setlocale` in the application and encode Unicode strings + using one of the system's available encodings. This example uses the system's default encoding:: import locale From python-checkins at python.org Sat Jan 19 14:46:07 2008 From: python-checkins at python.org (christian.heimes) Date: Sat, 19 Jan 2008 14:46:07 +0100 (CET) Subject: [Python-checkins] r60075 - python/trunk/Lib/test/test_threading_local.py Message-ID: <20080119134607.5D3021E4016@bag.python.org> Author: christian.heimes Date: Sat Jan 19 14:46:06 2008 New Revision: 60075 Modified: python/trunk/Lib/test/test_threading_local.py Log: Added unit test to verify that threading.local doesn't cause ref leaks. It seems that the thread local storage always keeps the storage of the last stopped thread alive. Can anybody comment on it, please? Modified: python/trunk/Lib/test/test_threading_local.py ============================================================================== --- python/trunk/Lib/test/test_threading_local.py (original) +++ python/trunk/Lib/test/test_threading_local.py Sat Jan 19 14:46:06 2008 @@ -1,9 +1,35 @@ import unittest from doctest import DocTestSuite from test import test_support +import threading +import weakref + +class Weak(object): + pass + +def target(local, weaklist): + weak = Weak() + local.weak = weak + weaklist.append(weakref.ref(weak)) + +class ThreadingLocalTest(unittest.TestCase): + def test_local_refs(self): + local = threading.local() + weaklist = [] + n = 20 + for i in range(n): + t = threading.Thread(target=target, args=(local, weaklist)) + t.start() + t.join() + self.assertEqual(len(weaklist), n) + deadlist = [weak for weak in weaklist if weak() is None] + # XXX threading.local keeps the local of the last stopped thread alive + self.assertEqual(len(deadlist), n-1) def test_main(): - suite = DocTestSuite('_threading_local') + suite = unittest.TestSuite() + suite.addTest(DocTestSuite('_threading_local')) + suite.addTest(unittest.makeSuite(ThreadingLocalTest)) try: from thread import _local From buildbot at python.org Sat Jan 19 16:03:06 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 19 Jan 2008 15:03:06 +0000 Subject: [Python-checkins] buildbot failure in ppc Debian unstable trunk Message-ID: <20080119150306.DF1641E4016@bag.python.org> The Buildbot has detected a new failure of ppc Debian unstable trunk. Full details are available at: http://www.python.org/dev/buildbot/all/ppc%20Debian%20unstable%20trunk/builds/600 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: andrew.kuchling,christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/SocketServer.py", line 523, in __init__ self.handle() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/BaseHTTPServer.py", line 310, in handle_one_request method() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/SimpleXMLRPCServer.py", line 449, in do_POST self.report_404() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/SimpleXMLRPCServer.py", line 507, in report_404 self.connection.shutdown(1) File "", line 1, in shutdown error: [Errno 107] Transport endpoint is not connected 2 tests failed: test_socket_ssl test_xmlrpc ====================================================================== ERROR: test_fail_no_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_xmlrpc.py", line 560, in test_fail_no_info p.pow(6,8) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1157, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1447, in __request verbose=self.__verbose File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1195, in request errcode, errmsg, headers = h.getreply() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 1006, in getreply response = self._conn.getresponse() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 932, in getresponse response.begin() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 415, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 271, in readheaders line = self.fp.readline() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/socket.py", line 354, in readline data = recv(1) error: [Errno 104] Connection reset by peer ====================================================================== ERROR: test_fail_with_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_xmlrpc.py", line 580, in test_fail_with_info p.pow(6,8) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1157, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1447, in __request verbose=self.__verbose File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1195, in request errcode, errmsg, headers = h.getreply() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 1006, in getreply response = self._conn.getresponse() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 932, in getresponse response.begin() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 415, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 271, in readheaders line = self.fp.readline() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/socket.py", line 354, in readline data = recv(1) error: [Errno 104] Connection reset by peer make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Sat Jan 19 16:06:09 2008 From: python-checkins at python.org (christian.heimes) Date: Sat, 19 Jan 2008 16:06:09 +0100 (CET) Subject: [Python-checkins] r60076 - python/trunk/Lib/test/test_threading_local.py Message-ID: <20080119150609.93CBC1E4016@bag.python.org> Author: christian.heimes Date: Sat Jan 19 16:06:09 2008 New Revision: 60076 Modified: python/trunk/Lib/test/test_threading_local.py Log: Update for threading.local test. Modified: python/trunk/Lib/test/test_threading_local.py ============================================================================== --- python/trunk/Lib/test/test_threading_local.py (original) +++ python/trunk/Lib/test/test_threading_local.py Sat Jan 19 16:06:09 2008 @@ -3,6 +3,7 @@ from test import test_support import threading import weakref +import gc class Weak(object): pass @@ -13,19 +14,34 @@ weaklist.append(weakref.ref(weak)) class ThreadingLocalTest(unittest.TestCase): + def test_local_refs(self): + self._local_refs(20) + self._local_refs(50) + self._local_refs(100) + + def _local_refs(self, n): local = threading.local() weaklist = [] - n = 20 for i in range(n): t = threading.Thread(target=target, args=(local, weaklist)) t.start() t.join() + del t + + gc.collect() self.assertEqual(len(weaklist), n) + + # XXX threading.local keeps the local of the last stopped thread alive. deadlist = [weak for weak in weaklist if weak() is None] - # XXX threading.local keeps the local of the last stopped thread alive self.assertEqual(len(deadlist), n-1) + # Assignment to the same thread local frees it sometimes (!) + local.someothervar = None + gc.collect() + deadlist = [weak for weak in weaklist if weak() is None] + self.assert_(len(deadlist) in (n-1, n), (n, len(deadlist))) + def test_main(): suite = unittest.TestSuite() suite.addTest(DocTestSuite('_threading_local')) From python-checkins at python.org Sat Jan 19 16:16:38 2008 From: python-checkins at python.org (andrew.kuchling) Date: Sat, 19 Jan 2008 16:16:38 +0100 (CET) Subject: [Python-checkins] r60077 - python/trunk/Doc/c-api/utilities.rst Message-ID: <20080119151638.02A971E402F@bag.python.org> Author: andrew.kuchling Date: Sat Jan 19 16:16:37 2008 New Revision: 60077 Modified: python/trunk/Doc/c-api/utilities.rst Log: Polish sentence Modified: python/trunk/Doc/c-api/utilities.rst ============================================================================== --- python/trunk/Doc/c-api/utilities.rst (original) +++ python/trunk/Doc/c-api/utilities.rst Sat Jan 19 16:16:37 2008 @@ -207,12 +207,12 @@ .. cfunction:: PyObject* PyImport_ImportModuleNoBlock(const char *name) This version of :cfunc:`PyImport_ImportModule` does not block. It's intended - to be used in C function which import other modules to execute a function. + to be used in C functions that import other modules to execute a function. The import may block if another thread holds the import lock. The function - :cfunc:`PyImport_ImportModuleNoBlock` doesn't block. It first tries to fetch + :cfunc:`PyImport_ImportModuleNoBlock` never blocks. It first tries to fetch the module from sys.modules and falls back to :cfunc:`PyImport_ImportModule` - unless the the lock is hold. In the latter case the function raises an - ImportError. + unless the lock is held, in which case the function will raise an + :exc:`ImportError`. .. versionadded:: 2.6 From python-checkins at python.org Sat Jan 19 16:22:17 2008 From: python-checkins at python.org (georg.brandl) Date: Sat, 19 Jan 2008 16:22:17 +0100 (CET) Subject: [Python-checkins] r60078 - python/trunk/Doc/c-api/concrete.rst Message-ID: <20080119152217.59AF21E4029@bag.python.org> Author: georg.brandl Date: Sat Jan 19 16:22:16 2008 New Revision: 60078 Modified: python/trunk/Doc/c-api/concrete.rst Log: Fix typos. Modified: python/trunk/Doc/c-api/concrete.rst ============================================================================== --- python/trunk/Doc/c-api/concrete.rst (original) +++ python/trunk/Doc/c-api/concrete.rst Sat Jan 19 16:22:16 2008 @@ -1320,7 +1320,7 @@ .. cfunction:: PyObject* PyUnicode_AsUTF8String(PyObject *unicode) - Encode a Unicode objects using UTF-8 and return the result as Python string + Encode a Unicode object using UTF-8 and return the result as Python string object. Error handling is "strict". Return *NULL* if an exception was raised by the codec. @@ -1482,7 +1482,7 @@ .. cfunction:: PyObject* PyUnicode_AsUnicodeEscapeString(PyObject *unicode) - Encode a Unicode objects using Unicode-Escape and return the result as Python + Encode a Unicode object using Unicode-Escape and return the result as Python string object. Error handling is "strict". Return *NULL* if an exception was raised by the codec. @@ -1506,7 +1506,7 @@ .. cfunction:: PyObject* PyUnicode_AsRawUnicodeEscapeString(PyObject *unicode) - Encode a Unicode objects using Raw-Unicode-Escape and return the result as + Encode a Unicode object using Raw-Unicode-Escape and return the result as Python string object. Error handling is "strict". Return *NULL* if an exception was raised by the codec. @@ -1530,7 +1530,7 @@ .. cfunction:: PyObject* PyUnicode_AsLatin1String(PyObject *unicode) - Encode a Unicode objects using Latin-1 and return the result as Python string + Encode a Unicode object using Latin-1 and return the result as Python string object. Error handling is "strict". Return *NULL* if an exception was raised by the codec. @@ -1554,7 +1554,7 @@ .. cfunction:: PyObject* PyUnicode_AsASCIIString(PyObject *unicode) - Encode a Unicode objects using ASCII and return the result as Python string + Encode a Unicode object using ASCII and return the result as Python string object. Error handling is "strict". Return *NULL* if an exception was raised by the codec. @@ -1606,7 +1606,7 @@ .. cfunction:: PyObject* PyUnicode_AsCharmapString(PyObject *unicode, PyObject *mapping) - Encode a Unicode objects using the given *mapping* object and return the result + Encode a Unicode object using the given *mapping* object and return the result as Python string object. Error handling is "strict". Return *NULL* if an exception was raised by the codec. @@ -1658,7 +1658,7 @@ .. cfunction:: PyObject* PyUnicode_AsMBCSString(PyObject *unicode) - Encode a Unicode objects using MBCS and return the result as Python string + Encode a Unicode object using MBCS and return the result as Python string object. Error handling is "strict". Return *NULL* if an exception was raised by the codec. From buildbot at python.org Sat Jan 19 16:51:19 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 19 Jan 2008 15:51:19 +0000 Subject: [Python-checkins] buildbot failure in PPC64 Debian trunk Message-ID: <20080119155120.0A9F61E4016@bag.python.org> The Buildbot has detected a new failure of PPC64 Debian trunk. Full details are available at: http://www.python.org/dev/buildbot/all/PPC64%20Debian%20trunk/builds/114 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/SocketServer.py", line 523, in __init__ self.handle() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/BaseHTTPServer.py", line 310, in handle_one_request method() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/SimpleXMLRPCServer.py", line 449, in do_POST self.report_404() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/SimpleXMLRPCServer.py", line 507, in report_404 self.connection.shutdown(1) File "", line 1, in shutdown error: [Errno 107] Transport endpoint is not connected 1 test failed: test_xmlrpc ====================================================================== ERROR: test_fail_no_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/test/test_xmlrpc.py", line 560, in test_fail_no_info p.pow(6,8) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/xmlrpclib.py", line 1157, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/xmlrpclib.py", line 1447, in __request verbose=self.__verbose File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/xmlrpclib.py", line 1195, in request errcode, errmsg, headers = h.getreply() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 1006, in getreply response = self._conn.getresponse() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 932, in getresponse response.begin() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 415, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 271, in readheaders line = self.fp.readline() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/socket.py", line 354, in readline data = recv(1) error: [Errno 104] Connection reset by peer ====================================================================== ERROR: test_fail_with_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/test/test_xmlrpc.py", line 580, in test_fail_with_info p.pow(6,8) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/xmlrpclib.py", line 1157, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/xmlrpclib.py", line 1447, in __request verbose=self.__verbose File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/xmlrpclib.py", line 1195, in request errcode, errmsg, headers = h.getreply() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 1006, in getreply response = self._conn.getresponse() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 932, in getresponse response.begin() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 415, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/httplib.py", line 271, in readheaders line = self.fp.readline() File "/home/pybot/buildarea64/trunk.klose-debian-ppc64/build/Lib/socket.py", line 354, in readline data = recv(1) error: [Errno 104] Connection reset by peer make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Sat Jan 19 17:26:13 2008 From: python-checkins at python.org (andrew.kuchling) Date: Sat, 19 Jan 2008 17:26:13 +0100 (CET) Subject: [Python-checkins] r60080 - in python/trunk: Doc/library/socketserver.rst Lib/SocketServer.py Misc/ACKS Misc/NEWS Message-ID: <20080119162613.8ECCF1E4016@bag.python.org> Author: andrew.kuchling Date: Sat Jan 19 17:26:13 2008 New Revision: 60080 Modified: python/trunk/Doc/library/socketserver.rst python/trunk/Lib/SocketServer.py python/trunk/Misc/ACKS python/trunk/Misc/NEWS Log: Patch #742598 from Michael Pomraning: add .timeout attribute to SocketServer that will call .handle_timeout() method when no requests are received within the timeout period. Modified: python/trunk/Doc/library/socketserver.rst ============================================================================== --- python/trunk/Doc/library/socketserver.rst (original) +++ python/trunk/Doc/library/socketserver.rst Sat Jan 19 17:26:13 2008 @@ -44,7 +44,7 @@ not exit until all threads created by :class:`ThreadingMixIn` have exited. Server classes have the same external methods and attributes, no matter what -network protocol they use: +network protocol they use. Server Creation Notes @@ -193,6 +193,13 @@ The type of socket used by the server; :const:`socket.SOCK_STREAM` and :const:`socket.SOCK_DGRAM` are two possible values. +.. data:: timeout + + Timeout duration, measured in seconds, or :const:`None` if no timeout is desired. + If no incoming requests are received within the timeout period, + the :meth:`handle_timeout` method is called and then the server resumes waiting for + requests. + There are various server methods that can be overridden by subclasses of base server classes like :class:`TCPServer`; these methods aren't useful to external users of the server object. @@ -220,6 +227,13 @@ method raises an exception. The default action is to print the traceback to standard output and continue handling further requests. +.. function:: handle_timeout() + + This function is called when the :attr:`timeout` attribute has been set to a + value other than :const:`None` and the timeout period has passed with no + requests being received. The default action for forking servers is + to collect the status of any child processes that have exited, while + in threading servers this method does nothing. .. function:: process_request(request, client_address) Modified: python/trunk/Lib/SocketServer.py ============================================================================== --- python/trunk/Lib/SocketServer.py (original) +++ python/trunk/Lib/SocketServer.py Sat Jan 19 17:26:13 2008 @@ -158,6 +158,7 @@ - server_bind() - server_activate() - get_request() -> request, client_address + - handle_timeout() - verify_request(request, client_address) - server_close() - process_request(request, client_address) @@ -171,6 +172,7 @@ Class variables that may be overridden by derived classes or instances: + - timeout - address_family - socket_type - allow_reuse_address @@ -182,6 +184,8 @@ """ + timeout = None + def __init__(self, server_address, RequestHandlerClass): """Constructor. May be extended, do not override.""" self.server_address = server_address @@ -204,8 +208,9 @@ # finishing a request is fairly arbitrary. Remember: # # - handle_request() is the top-level call. It calls - # get_request(), verify_request() and process_request() - # - get_request() is different for stream or datagram sockets + # await_request(), verify_request() and process_request() + # - get_request(), called by await_request(), is different for + # stream or datagram sockets # - process_request() is the place that may fork a new process # or create a new thread to finish the request # - finish_request() instantiates the request handler class; @@ -214,7 +219,7 @@ def handle_request(self): """Handle one request, possibly blocking.""" try: - request, client_address = self.get_request() + request, client_address = self.await_request() except socket.error: return if self.verify_request(request, client_address): @@ -224,6 +229,28 @@ self.handle_error(request, client_address) self.close_request(request) + def await_request(self): + """Call get_request or handle_timeout, observing self.timeout. + + Returns value from get_request() or raises socket.timeout exception if + timeout was exceeded. + """ + if self.timeout is not None: + # If timeout == 0, you're responsible for your own fd magic. + import select + fd_sets = select.select([self], [], [], self.timeout) + if not fd_sets[0]: + self.handle_timeout() + raise socket.timeout("Listening timed out") + return self.get_request() + + def handle_timeout(self): + """Called if no new request arrives within self.timeout. + + Overridden by ForkingMixIn. + """ + pass + def verify_request(self, request, client_address): """Verify the request. May be overridden. @@ -289,6 +316,7 @@ - server_bind() - server_activate() - get_request() -> request, client_address + - handle_timeout() - verify_request(request, client_address) - process_request(request, client_address) - close_request(request) @@ -301,6 +329,7 @@ Class variables that may be overridden by derived classes or instances: + - timeout - address_family - socket_type - request_queue_size (only for stream sockets) @@ -405,11 +434,12 @@ """Mix-in class to handle each request in a new process.""" + timeout = 300 active_children = None max_children = 40 def collect_children(self): - """Internal routine to wait for died children.""" + """Internal routine to wait for children that have exited.""" while self.active_children: if len(self.active_children) < self.max_children: options = os.WNOHANG @@ -424,6 +454,13 @@ if not pid: break self.active_children.remove(pid) + def handle_timeout(self): + """Wait for zombies after self.timeout seconds of inactivity. + + May be extended, do not override. + """ + self.collect_children() + def process_request(self, request, client_address): """Fork a new subprocess to process the request.""" self.collect_children() Modified: python/trunk/Misc/ACKS ============================================================================== --- python/trunk/Misc/ACKS (original) +++ python/trunk/Misc/ACKS Sat Jan 19 17:26:13 2008 @@ -521,6 +521,7 @@ Fran?ois Pinard Zach Pincus Michael Piotrowski +Michael Pomraning Iustin Pop John Popplewell Amrit Prem Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Sat Jan 19 17:26:13 2008 @@ -704,6 +704,9 @@ be equal to calling getsockname() on the server's socket. Fixed by patch #1545011. +- Patch #742598: Add .timeout attribute to SocketServer that calls + .handle_timeout() when no requests are received. + - Bug #1651235: When a tuple was passed to a ctypes function call, Python would crash instead of raising an error. From python-checkins at python.org Sat Jan 19 17:34:09 2008 From: python-checkins at python.org (andrew.kuchling) Date: Sat, 19 Jan 2008 17:34:09 +0100 (CET) Subject: [Python-checkins] r60081 - python/trunk/Doc/whatsnew/2.6.rst Message-ID: <20080119163409.F2D031E4016@bag.python.org> Author: andrew.kuchling Date: Sat Jan 19 17:34:09 2008 New Revision: 60081 Modified: python/trunk/Doc/whatsnew/2.6.rst Log: Add item Modified: python/trunk/Doc/whatsnew/2.6.rst ============================================================================== --- python/trunk/Doc/whatsnew/2.6.rst (original) +++ python/trunk/Doc/whatsnew/2.6.rst Sat Jan 19 17:34:09 2008 @@ -1102,6 +1102,13 @@ (Contributed by Alberto Bertogli.) .. Patch #1646 + +* The base classes in the :mod:`SocketServer` module now support + calling a :meth:`handle_timeout` method after a span of inactivity + specified by the server's :attr:`timeout` attribute. (Contributed + by Michael Pomraning.) + + .. Patch #742598 * A new variable in the :mod:`sys` module, :attr:`float_info`, is an object From python-checkins at python.org Sat Jan 19 17:39:28 2008 From: python-checkins at python.org (christian.heimes) Date: Sat, 19 Jan 2008 17:39:28 +0100 (CET) Subject: [Python-checkins] r60082 - python/trunk/Lib/test/test_socket.py python/trunk/Lib/test/test_ssl.py python/trunk/Lib/test/test_xmlrpc.py Message-ID: <20080119163928.5C7451E4016@bag.python.org> Author: christian.heimes Date: Sat Jan 19 17:39:27 2008 New Revision: 60082 Modified: python/trunk/Lib/test/test_socket.py python/trunk/Lib/test/test_ssl.py python/trunk/Lib/test/test_xmlrpc.py Log: Disabled test_xmlrpc:test_404. It's causing lots of false alarms. I also disabled a test in test_ssl which requires network access to svn.python.org. This fixes a bug Skip has reported a while ago. Modified: python/trunk/Lib/test/test_socket.py ============================================================================== --- python/trunk/Lib/test/test_socket.py (original) +++ python/trunk/Lib/test/test_socket.py Sat Jan 19 17:39:27 2008 @@ -279,7 +279,6 @@ def testRefCountGetNameInfo(self): # Testing reference count for getnameinfo - import sys if hasattr(sys, "getrefcount"): try: # On some versions, this loses a reference Modified: python/trunk/Lib/test/test_ssl.py ============================================================================== --- python/trunk/Lib/test/test_ssl.py (original) +++ python/trunk/Lib/test/test_ssl.py Sat Jan 19 17:39:27 2008 @@ -37,7 +37,8 @@ class BasicTests(unittest.TestCase): def testSSLconnect(self): - import os + if not test_support.is_resource_enabled('network'): + return s = ssl.wrap_socket(socket.socket(socket.AF_INET), cert_reqs=ssl.CERT_NONE) s.connect(("svn.python.org", 443)) @@ -101,7 +102,6 @@ class NetworkTests(unittest.TestCase): def testConnect(self): - import os s = ssl.wrap_socket(socket.socket(socket.AF_INET), cert_reqs=ssl.CERT_NONE) s.connect(("svn.python.org", 443)) Modified: python/trunk/Lib/test/test_xmlrpc.py ============================================================================== --- python/trunk/Lib/test/test_xmlrpc.py (original) +++ python/trunk/Lib/test/test_xmlrpc.py Sat Jan 19 17:39:27 2008 @@ -392,7 +392,8 @@ # protocol error; provide additional information in test output self.fail("%s\n%s" % (e, e.headers)) - def test_404(self): + # [ch] The test 404 is causing lots of false alarms. + def XXXtest_404(self): # send POST with httplib, it should return 404 header and # 'Not Found' message. conn = httplib.HTTPConnection('localhost', PORT) From buildbot at python.org Sat Jan 19 18:08:28 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 19 Jan 2008 17:08:28 +0000 Subject: [Python-checkins] buildbot failure in sparc solaris10 gcc 3.0 Message-ID: <20080119170828.479E81E4016@bag.python.org> The Buildbot has detected a new failure of sparc solaris10 gcc 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/sparc%20solaris10%20gcc%203.0/builds/499 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-sun Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes,georg.brandl BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_ctypes sincerely, -The Buildbot From python-checkins at python.org Sat Jan 19 18:38:53 2008 From: python-checkins at python.org (georg.brandl) Date: Sat, 19 Jan 2008 18:38:53 +0100 (CET) Subject: [Python-checkins] r60083 - python/trunk/Doc/library/threading.rst Message-ID: <20080119173853.576161E4017@bag.python.org> Author: georg.brandl Date: Sat Jan 19 18:38:53 2008 New Revision: 60083 Modified: python/trunk/Doc/library/threading.rst Log: Clarify thread.join() docs. #1873. Modified: python/trunk/Doc/library/threading.rst ============================================================================== --- python/trunk/Doc/library/threading.rst (original) +++ python/trunk/Doc/library/threading.rst Sat Jan 19 18:38:53 2008 @@ -622,18 +622,19 @@ When the *timeout* argument is present and not ``None``, it should be a floating point number specifying a timeout for the operation in seconds (or fractions - thereof). As :meth:`join` always returns ``None``, you must call - :meth:`isAlive` to decide whether a timeout happened. + thereof). As :meth:`join` always returns ``None``, you must call :meth:`isAlive` + after :meth:`join` to decide whether a timeout happened -- if the thread is + still alive, the :meth:`join` call timed out. When the *timeout* argument is not present or ``None``, the operation will block until the thread terminates. A thread can be :meth:`join`\ ed many times. - :meth:`join` may throw a :exc:`RuntimeError`, if an attempt is made to join the - current thread as that would cause a deadlock. It is also an error to - :meth:`join` a thread before it has been started and attempts to do so raises - same exception. + :meth:`join` raises a :exc:`RuntimeError` if an attempt is made to join + the current thread as that would cause a deadlock. It is also an error to + :meth:`join` a thread before it has been started and attempts to do so + raises the same exception. .. method:: Thread.getName() From python-checkins at python.org Sat Jan 19 19:02:46 2008 From: python-checkins at python.org (georg.brandl) Date: Sat, 19 Jan 2008 19:02:46 +0100 (CET) Subject: [Python-checkins] r60084 - python/trunk/Python/modsupport.c Message-ID: <20080119180246.E9C161E4018@bag.python.org> Author: georg.brandl Date: Sat Jan 19 19:02:46 2008 New Revision: 60084 Modified: python/trunk/Python/modsupport.c Log: #1782: don't leak in error case in PyModule_AddXxxConstant. Patch by Hrvoje Nik?i?. Modified: python/trunk/Python/modsupport.c ============================================================================== --- python/trunk/Python/modsupport.c (original) +++ python/trunk/Python/modsupport.c Sat Jan 19 19:02:46 2008 @@ -621,11 +621,23 @@ int PyModule_AddIntConstant(PyObject *m, const char *name, long value) { - return PyModule_AddObject(m, name, PyInt_FromLong(value)); + PyObject *o = PyInt_FromLong(value); + if (!o) + return -1; + if (PyModule_AddObject(m, name, o) == 0) + return 0; + Py_DECREF(o); + return -1; } int PyModule_AddStringConstant(PyObject *m, const char *name, const char *value) { - return PyModule_AddObject(m, name, PyString_FromString(value)); + PyObject *o = PyString_FromString(value); + if (!o) + return -1; + if (PyModule_AddObject(m, name, o) == 0) + return 0; + Py_DECREF(o); + return -1; } From python-checkins at python.org Sat Jan 19 19:08:53 2008 From: python-checkins at python.org (andrew.kuchling) Date: Sat, 19 Jan 2008 19:08:53 +0100 (CET) Subject: [Python-checkins] r60085 - python/trunk/Misc/ACKS Message-ID: <20080119180853.3F6A01E4018@bag.python.org> Author: andrew.kuchling Date: Sat Jan 19 19:08:52 2008 New Revision: 60085 Modified: python/trunk/Misc/ACKS Log: Sort two names into position Modified: python/trunk/Misc/ACKS ============================================================================== --- python/trunk/Misc/ACKS (original) +++ python/trunk/Misc/ACKS Sat Jan 19 19:08:52 2008 @@ -109,8 +109,6 @@ Brett Cannon Mike Carlton Terry Carroll -Brian Leair -Luke Kenneth Casson Leighton Donn Cave Per Cederqvist Octavian Cerna @@ -387,6 +385,7 @@ Ben Laurie Simon Law Chris Lawrence +Brian Leair Christopher Lee Inyeol Lee John J. Lee @@ -394,6 +393,7 @@ Luc Lefebvre Kip Lehman Joerg Lehmann +Luke Kenneth Casson Leighton Marc-Andre Lemburg Mark Levinson William Lewis From buildbot at python.org Sat Jan 19 19:15:25 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 19 Jan 2008 18:15:25 +0000 Subject: [Python-checkins] buildbot failure in ppc Debian unstable trunk Message-ID: <20080119181525.D7F6C1E4029@bag.python.org> The Buildbot has detected a new failure of ppc Debian unstable trunk. Full details are available at: http://www.python.org/dev/buildbot/all/ppc%20Debian%20unstable%20trunk/builds/603 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: andrew.kuchling,christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_xmlrpc ====================================================================== ERROR: test_fail_no_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_xmlrpc.py", line 561, in test_fail_no_info p.pow(6,8) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1157, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1447, in __request verbose=self.__verbose File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1195, in request errcode, errmsg, headers = h.getreply() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 1006, in getreply response = self._conn.getresponse() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 932, in getresponse response.begin() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 415, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 271, in readheaders line = self.fp.readline() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/socket.py", line 354, in readline data = recv(1) error: [Errno 104] Connection reset by peer ====================================================================== ERROR: test_fail_with_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_xmlrpc.py", line 581, in test_fail_with_info p.pow(6,8) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1157, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1447, in __request verbose=self.__verbose File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1195, in request errcode, errmsg, headers = h.getreply() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 1006, in getreply response = self._conn.getresponse() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 932, in getresponse response.begin() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 415, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 271, in readheaders line = self.fp.readline() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/socket.py", line 354, in readline data = recv(1) error: [Errno 104] Connection reset by peer make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Sat Jan 19 19:18:41 2008 From: python-checkins at python.org (andrew.kuchling) Date: Sat, 19 Jan 2008 19:18:41 +0100 (CET) Subject: [Python-checkins] r60086 - in python/trunk: Doc/library/mmap.rst Lib/test/test_mmap.py Misc/ACKS Misc/NEWS Modules/mmapmodule.c Message-ID: <20080119181841.BE01B1E4018@bag.python.org> Author: andrew.kuchling Date: Sat Jan 19 19:18:41 2008 New Revision: 60086 Modified: python/trunk/Doc/library/mmap.rst python/trunk/Lib/test/test_mmap.py python/trunk/Misc/ACKS python/trunk/Misc/NEWS python/trunk/Modules/mmapmodule.c Log: Patch #976880: add mmap .rfind() method, and 'end' paramter to .find(). Contributed by John Lenton. Modified: python/trunk/Doc/library/mmap.rst ============================================================================== --- python/trunk/Doc/library/mmap.rst (original) +++ python/trunk/Doc/library/mmap.rst Sat Jan 19 19:18:41 2008 @@ -139,11 +139,12 @@ an exception being raised. -.. method:: mmap.find(string[, start]) +.. method:: mmap.find(string[, start[, end]]) - Returns the lowest index in the object where the substring *string* is found. - Returns ``-1`` on failure. *start* is the index at which the search begins, and - defaults to zero. + Returns the lowest index in the object where the substring *string* is found, + such that *string* is contained in the range [*start*, *end*]. Optional + arguments *start* and *end* are interpreted as in slice notation. + Returns ``-1`` on failure. .. method:: mmap.flush([offset, size]) @@ -188,6 +189,14 @@ :exc:`TypeError` exception. +.. method:: mmap.rfind(string[, start[, end]]) + + Returns the highest index in the object where the substring *string* is + found, such that *string* is contained in the range [*start*, + *end*]. Optional arguments *start* and *end* are interpreted as in slice + notation. Returns ``-1`` on failure. + + .. method:: mmap.seek(pos[, whence]) Set the file's current position. *whence* argument is optional and defaults to Modified: python/trunk/Lib/test/test_mmap.py ============================================================================== --- python/trunk/Lib/test/test_mmap.py (original) +++ python/trunk/Lib/test/test_mmap.py Sat Jan 19 19:18:41 2008 @@ -255,6 +255,42 @@ self.assertEqual(m.find(slice + 'x'), -1) m.close() + def test_find_end(self): + # test the new 'end' parameter works as expected + f = open(TESTFN, 'w+') + data = 'one two ones' + n = len(data) + f.write(data) + f.flush() + m = mmap.mmap(f.fileno(), n) + f.close() + + self.assertEqual(m.find('one'), 0) + self.assertEqual(m.find('ones'), 8) + self.assertEqual(m.find('one', 0, -1), 0) + self.assertEqual(m.find('one', 1), 8) + self.assertEqual(m.find('one', 1, -1), 8) + self.assertEqual(m.find('one', 1, -2), -1) + + + def test_rfind(self): + # test the new 'end' parameter works as expected + f = open(TESTFN, 'w+') + data = 'one two ones' + n = len(data) + f.write(data) + f.flush() + m = mmap.mmap(f.fileno(), n) + f.close() + + self.assertEqual(m.rfind('one'), 8) + self.assertEqual(m.rfind('one '), 0) + self.assertEqual(m.rfind('one', 0, -1), 8) + self.assertEqual(m.rfind('one', 0, -2), 0) + self.assertEqual(m.rfind('one', 1, -1), 8) + self.assertEqual(m.rfind('one', 1, -2), -1) + + def test_double_close(self): # make sure a double close doesn't crash on Solaris (Bug# 665913) f = open(TESTFN, 'w+') Modified: python/trunk/Misc/ACKS ============================================================================== --- python/trunk/Misc/ACKS (original) +++ python/trunk/Misc/ACKS Sat Jan 19 19:18:41 2008 @@ -395,6 +395,7 @@ Joerg Lehmann Luke Kenneth Casson Leighton Marc-Andre Lemburg +John Lenton Mark Levinson William Lewis Robert van Liere Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Sat Jan 19 19:18:41 2008 @@ -1011,6 +1011,10 @@ Extension Modules ----------------- +- Patch 976880: ``mmap`` objects now have an ``rfind`` method that + works as expected. ``mmap.find`` also takes an optional ``end`` + parameter. + - _winreg's HKEY object has gained __enter__ and __exit__ methods to support the context manager protocol. The _winreg module also gained a new function ``ExpandEnvironmentStrings`` to expand REG_EXPAND_SZ keys. Modified: python/trunk/Modules/mmapmodule.c ============================================================================== --- python/trunk/Modules/mmapmodule.c (original) +++ python/trunk/Modules/mmapmodule.c Sat Jan 19 19:18:41 2008 @@ -248,19 +248,22 @@ } static PyObject * -mmap_find_method(mmap_object *self, - PyObject *args) +mmap_gfind(mmap_object *self, + PyObject *args, + int reverse) { Py_ssize_t start = self->pos; + Py_ssize_t end = self->size; char *needle; Py_ssize_t len; CHECK_VALID(NULL); - if (!PyArg_ParseTuple(args, "s#|n:find", &needle, &len, &start)) { + if (!PyArg_ParseTuple(args, reverse ? "s#|nn:rfind" : "s#|nn:find", + &needle, &len, &start, &end)) { return NULL; } else { char *p; - char *e = self->data + self->size; + char sign = reverse ? -1 : 1; if (start < 0) start += self->size; @@ -269,7 +272,18 @@ else if ((size_t)start > self->size) start = self->size; - for (p = self->data + start; p + len <= e; ++p) { + if (end < 0) + end += self->size; + if (end < 0) + end = 0; + else if ((size_t)end > self->size) + end = self->size; + + start += (Py_ssize_t)self->data; + end += (Py_ssize_t)self->data; + + for (p = (char *)(reverse ? end - len : start); + p >= (char *)start && p + len <= (char *)end; p+=sign) { Py_ssize_t i; for (i = 0; i < len && needle[i] == p[i]; ++i) /* nothing */; @@ -281,6 +295,20 @@ } } +static PyObject * +mmap_find_method(mmap_object *self, + PyObject *args) +{ + return mmap_gfind(self, args, 0); +} + +static PyObject * +mmap_rfind_method(mmap_object *self, + PyObject *args) +{ + return mmap_gfind(self, args, 1); +} + static int is_writeable(mmap_object *self) { @@ -593,6 +621,7 @@ static struct PyMethodDef mmap_object_methods[] = { {"close", (PyCFunction) mmap_close_method, METH_NOARGS}, {"find", (PyCFunction) mmap_find_method, METH_VARARGS}, + {"rfind", (PyCFunction) mmap_rfind_method, METH_VARARGS}, {"flush", (PyCFunction) mmap_flush_method, METH_VARARGS}, {"move", (PyCFunction) mmap_move_method, METH_VARARGS}, {"read", (PyCFunction) mmap_read_method, METH_VARARGS}, From python-checkins at python.org Sat Jan 19 19:38:20 2008 From: python-checkins at python.org (facundo.batista) Date: Sat, 19 Jan 2008 19:38:20 +0100 (CET) Subject: [Python-checkins] r60087 - in python/trunk: Doc/library/trace.rst Lib/trace.py Message-ID: <20080119183820.30F1D1E401D@bag.python.org> Author: facundo.batista Date: Sat Jan 19 19:38:19 2008 New Revision: 60087 Modified: python/trunk/Doc/library/trace.rst python/trunk/Lib/trace.py Log: Fix #1693149. Now you can pass several modules separated by coma to trace.py in the same --ignore-module option. Thanks Raghuram Devarakonda. Modified: python/trunk/Doc/library/trace.rst ============================================================================== --- python/trunk/Doc/library/trace.rst (original) +++ python/trunk/Doc/library/trace.rst Sat Jan 19 19:38:19 2008 @@ -64,12 +64,14 @@ stdout for each file processed. :option:`--ignore-module` - Ignore the named module and its submodules (if it is a package). May be given + Accepts comma separated list of module names. Ignore each of the named + module and its submodules (if it is a package). May be given multiple times. :option:`--ignore-dir` - Ignore all modules and packages in the named directory and subdirectories. May - be given multiple times. + Ignore all modules and packages in the named directory and subdirectories + (multiple directories can be joined by os.pathsep). May be given multiple + times. .. _trace-api: Modified: python/trunk/Lib/trace.py ============================================================================== --- python/trunk/Lib/trace.py (original) +++ python/trunk/Lib/trace.py Sat Jan 19 19:38:19 2008 @@ -100,8 +100,9 @@ (Can only be used with --count or --report.) Filters, may be repeated multiple times: ---ignore-module= Ignore the given module and its submodules - (if it is a package). +--ignore-module= Ignore the given module(s) and its submodules + (if it is a package). Accepts comma separated + list of module names --ignore-dir= Ignore files in the given directory (multiple directories can be joined by os.pathsep). """ % sys.argv[0]) @@ -729,7 +730,8 @@ continue if opt == "--ignore-module": - ignore_modules.append(val) + for mod in val.split(","): + ignore_modules.append(mod.strip()) continue if opt == "--ignore-dir": From python-checkins at python.org Sat Jan 19 19:45:47 2008 From: python-checkins at python.org (facundo.batista) Date: Sat, 19 Jan 2008 19:45:47 +0100 (CET) Subject: [Python-checkins] r60088 - python/trunk/Misc/NEWS Message-ID: <20080119184547.08D111E401A@bag.python.org> Author: facundo.batista Date: Sat Jan 19 19:45:46 2008 New Revision: 60088 Modified: python/trunk/Misc/NEWS Log: Comment in NEWS regarding the change in trace.py. Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Sat Jan 19 19:45:46 2008 @@ -1611,6 +1611,9 @@ Library ------- +- Fix #1693149. Now you can pass several modules separated by + comma to trace.py in the same --ignore-module option. + - Correction of patch #1455898: In the mbcs decoder, set final=False for stream decoder, but final=True for the decode function. From python-checkins at python.org Sat Jan 19 19:47:24 2008 From: python-checkins at python.org (skip.montanaro) Date: Sat, 19 Jan 2008 19:47:24 +0100 (CET) Subject: [Python-checkins] r60089 - python/trunk/Misc/NEWS Message-ID: <20080119184724.D7C841E4686@bag.python.org> Author: skip.montanaro Date: Sat Jan 19 19:47:24 2008 New Revision: 60089 Modified: python/trunk/Misc/NEWS Log: missing from r60088 checkin. Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Sat Jan 19 19:47:24 2008 @@ -367,6 +367,9 @@ Library ------- +- #1693149: trace.py --ignore-module - accept multiple comma-separated + modules to be given. + - #1822: MIMEMultipart.is_multipart() behaves correctly for a just-created (and empty) instance. Thanks Jonathan Share. From python-checkins at python.org Sat Jan 19 20:14:05 2008 From: python-checkins at python.org (andrew.kuchling) Date: Sat, 19 Jan 2008 20:14:05 +0100 (CET) Subject: [Python-checkins] r60091 - python/trunk/Doc/whatsnew/2.6.rst Message-ID: <20080119191405.8E2951E4032@bag.python.org> Author: andrew.kuchling Date: Sat Jan 19 20:14:05 2008 New Revision: 60091 Modified: python/trunk/Doc/whatsnew/2.6.rst Log: Add item Modified: python/trunk/Doc/whatsnew/2.6.rst ============================================================================== --- python/trunk/Doc/whatsnew/2.6.rst (original) +++ python/trunk/Doc/whatsnew/2.6.rst Sat Jan 19 20:14:05 2008 @@ -960,6 +960,13 @@ .. Patch #1490190 +* :class:`mmap` objects now have a :meth:`rfind` method that finds + a substring, beginning at the end of the string and searching + backwards. The :meth:`find` method + also gained a *end* parameter containing the index at which to stop + the forward search. + (Contributed by John Lenton.) + * The :mod:`new` module has been removed from Python 3.0. Importing it therefore triggers a warning message when Python is running in 3.0-warning From python-checkins at python.org Sat Jan 19 20:27:06 2008 From: python-checkins at python.org (georg.brandl) Date: Sat, 19 Jan 2008 20:27:06 +0100 (CET) Subject: [Python-checkins] r60092 - in python/trunk: Lib/test/test_builtin.py Lib/test/test_grammar.py Lib/tokenize.py Misc/NEWS Parser/tokenizer.c Python/mystrtoul.c Message-ID: <20080119192706.9B3CA1E401B@bag.python.org> Author: georg.brandl Date: Sat Jan 19 20:27:05 2008 New Revision: 60092 Modified: python/trunk/Lib/test/test_builtin.py python/trunk/Lib/test/test_grammar.py python/trunk/Lib/tokenize.py python/trunk/Misc/NEWS python/trunk/Parser/tokenizer.c python/trunk/Python/mystrtoul.c Log: Fix #1679: "0x" was taken as a valid integer literal. Fixes the tokenizer, tokenize.py and int() to reject this. Patches by Martin Rinehart. Modified: python/trunk/Lib/test/test_builtin.py ============================================================================== --- python/trunk/Lib/test/test_builtin.py (original) +++ python/trunk/Lib/test/test_builtin.py Sat Jan 19 20:27:05 2008 @@ -816,6 +816,11 @@ self.assertEqual(int('0123', 0), 83) self.assertEqual(int('0x123', 16), 291) + # Bug 1679: "0x" is not a valid hex literal + self.assertRaises(ValueError, int, "0x", 16) + self.assertRaises(ValueError, int, "0x", 0) + + # SF bug 1334662: int(string, base) wrong answers # Various representations of 2**32 evaluated to 0 # rather than 2**32 in previous versions Modified: python/trunk/Lib/test/test_grammar.py ============================================================================== --- python/trunk/Lib/test/test_grammar.py (original) +++ python/trunk/Lib/test/test_grammar.py Sat Jan 19 20:27:05 2008 @@ -30,6 +30,8 @@ self.assertEquals(0xff, 255) self.assertEquals(0377, 255) self.assertEquals(2147483647, 017777777777) + # "0x" is not a valid literal + self.assertRaises(SyntaxError, eval, "0x") from sys import maxint if maxint == 2147483647: self.assertEquals(-2147483647-1, -020000000000) Modified: python/trunk/Lib/tokenize.py ============================================================================== --- python/trunk/Lib/tokenize.py (original) +++ python/trunk/Lib/tokenize.py Sat Jan 19 20:27:05 2008 @@ -50,7 +50,7 @@ Ignore = Whitespace + any(r'\\\r?\n' + Whitespace) + maybe(Comment) Name = r'[a-zA-Z_]\w*' -Hexnumber = r'0[xX][\da-fA-F]*[lL]?' +Hexnumber = r'0[xX][\da-fA-F]+[lL]?' Octnumber = r'0[0-7]*[lL]?' Decnumber = r'[1-9]\d*[lL]?' Intnumber = group(Hexnumber, Octnumber, Decnumber) Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Sat Jan 19 20:27:05 2008 @@ -12,6 +12,8 @@ Core and builtins ----------------- +- Issue #1679: "0x" was taken as a valid integer literal. + - Issue #1865: Bytes as an alias for str and b"" as an alias "" were added. Modified: python/trunk/Parser/tokenizer.c ============================================================================== --- python/trunk/Parser/tokenizer.c (original) +++ python/trunk/Parser/tokenizer.c Sat Jan 19 20:27:05 2008 @@ -1332,7 +1332,14 @@ goto imaginary; #endif if (c == 'x' || c == 'X') { + /* Hex */ + c = tok_nextc(tok); + if (!isxdigit(c)) { + tok->done = E_TOKEN; + tok_backup(tok, c); + return ERRORTOKEN; + } do { c = tok_nextc(tok); } while (isxdigit(c)); Modified: python/trunk/Python/mystrtoul.c ============================================================================== --- python/trunk/Python/mystrtoul.c (original) +++ python/trunk/Python/mystrtoul.c Sat Jan 19 20:27:05 2008 @@ -112,27 +112,40 @@ /* check for leading 0 or 0x for auto-base or base 16 */ switch (base) { - case 0: /* look for leading 0, 0x or 0X */ - if (*str == '0') { - ++str; - if (*str == 'x' || *str == 'X') { - ++str; - base = 16; + case 0: /* look for leading 0, 0x or 0X */ + if (*str == '0') { + ++str; + if (*str == 'x' || *str == 'X') { + /* there must be at least one digit after 0x */ + if (_PyLong_DigitValue[Py_CHARMASK(str[1])] >= 16) { + if (ptr) + *ptr = str; + return 0; } - else - base = 8; + ++str; + base = 16; } else - base = 10; - break; + base = 8; + } + else + base = 10; + break; - case 16: /* skip leading 0x or 0X */ - if (*str == '0') { + case 16: /* skip leading 0x or 0X */ + if (*str == '0') { + ++str; + if (*str == 'x' || *str == 'X') { + /* there must be at least one digit after 0x */ + if (_PyLong_DigitValue[Py_CHARMASK(str[1])] >= 16) { + if (ptr) + *ptr = str; + return 0; + } ++str; - if (*str == 'x' || *str == 'X') - ++str; } - break; + } + break; } /* catch silly bases */ From python-checkins at python.org Sat Jan 19 20:48:19 2008 From: python-checkins at python.org (georg.brandl) Date: Sat, 19 Jan 2008 20:48:19 +0100 (CET) Subject: [Python-checkins] r60093 - in python/trunk: Lib/test/test_textwrap.py Lib/textwrap.py Misc/NEWS Message-ID: <20080119194819.9B13B1E401A@bag.python.org> Author: georg.brandl Date: Sat Jan 19 20:48:19 2008 New Revision: 60093 Modified: python/trunk/Lib/test/test_textwrap.py python/trunk/Lib/textwrap.py python/trunk/Misc/NEWS Log: Fix #1146: TextWrap vs words 1-character shorter than the width. Patch by Quentin Gallet-Gilles. Modified: python/trunk/Lib/test/test_textwrap.py ============================================================================== --- python/trunk/Lib/test/test_textwrap.py (original) +++ python/trunk/Lib/test/test_textwrap.py Sat Jan 19 20:48:19 2008 @@ -398,6 +398,19 @@ ' o'], subsequent_indent = ' '*15) + # bug 1146. Prevent a long word to be wrongly wrapped when the + # preceding word is exactly one character shorter than the width + self.check_wrap(self.text, 12, + ['Did you say ', + '"supercalifr', + 'agilisticexp', + 'ialidocious?', + '" How *do*', + 'you spell', + 'that odd', + 'word,', + 'anyways?']) + def test_nobreak_long(self): # Test with break_long_words disabled self.wrapper.break_long_words = 0 Modified: python/trunk/Lib/textwrap.py ============================================================================== --- python/trunk/Lib/textwrap.py (original) +++ python/trunk/Lib/textwrap.py Sat Jan 19 20:48:19 2008 @@ -173,7 +173,12 @@ Handle a chunk of text (most likely a word, not whitespace) that is too long to fit in any line. """ - space_left = max(width - cur_len, 1) + # Figure out when indent is larger than the specified width, and make + # sure at least one character is stripped off on every pass + if width < 1: + space_left = 1 + else: + space_left = width - cur_len # If we're allowed to break long words, then do so: put as much # of the next chunk onto the current line as will fit. Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Sat Jan 19 20:48:19 2008 @@ -369,6 +369,9 @@ Library ------- +- #1146: fix how textwrap breaks a long word that would start in the + last column of a line. + - #1693149: trace.py --ignore-module - accept multiple comma-separated modules to be given. From buildbot at python.org Sat Jan 19 21:03:55 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 19 Jan 2008 20:03:55 +0000 Subject: [Python-checkins] buildbot failure in ppc Debian unstable 3.0 Message-ID: <20080119200356.1D4D81E401A@bag.python.org> The Buildbot has detected a new failure of ppc Debian unstable 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/ppc%20Debian%20unstable%203.0/builds/471 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: facundo.batista BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 522, in __init__ self.handle() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/BaseHTTPServer.py", line 330, in handle self.handle_one_request() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/BaseHTTPServer.py", line 324, in handle_one_request method() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SimpleXMLRPCServer.py", line 430, in do_POST self.report_404() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SimpleXMLRPCServer.py", line 489, in report_404 self.connection.shutdown(1) socket.error: [Errno 107] Transport endpoint is not connected 1 test failed: test_xmlrpc Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 222, in handle_request self.process_request(request, client_address) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 241, in process_request self.finish_request(request, client_address) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 254, in finish_request self.RequestHandlerClass(request, client_address, self) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SocketServer.py", line 522, in __init__ self.handle() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/BaseHTTPServer.py", line 330, in handle self.handle_one_request() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/BaseHTTPServer.py", line 324, in handle_one_request method() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SimpleXMLRPCServer.py", line 430, in do_POST self.report_404() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/SimpleXMLRPCServer.py", line 489, in report_404 self.connection.shutdown(1) socket.error: [Errno 107] Transport endpoint is not connected ====================================================================== ERROR: test_fail_with_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/test/test_xmlrpc.py", line 515, in test_fail_with_info p.pow(6,8) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1091, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1349, in __request verbose=self.__verbose File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1121, in request resp = http_conn.getresponse() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/httplib.py", line 961, in getresponse response.begin() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/httplib.py", line 425, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/httplib.py", line 267, in readheaders line = str(self.fp.readline(), "iso-8859-1") File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/io.py", line 413, in readline b = self.read(nreadahead()) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/io.py", line 475, in read n = self.readinto(b) File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/socket.py", line 217, in readinto return self._sock.recv_into(b) socket.error: [Errno 104] Connection reset by peer make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Sat Jan 19 21:11:19 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 19 Jan 2008 20:11:19 +0000 Subject: [Python-checkins] buildbot failure in x86 FreeBSD trunk Message-ID: <20080119201119.88EC11E401A@bag.python.org> The Buildbot has detected a new failure of x86 FreeBSD trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20FreeBSD%20trunk/builds/427 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-freebsd Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: andrew.kuchling,christian.heimes,georg.brandl BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 227, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 268, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 281, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 560, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable 1 test failed: test_smtplib sincerely, -The Buildbot From python-checkins at python.org Sat Jan 19 21:12:04 2008 From: python-checkins at python.org (andrew.kuchling) Date: Sat, 19 Jan 2008 21:12:04 +0100 (CET) Subject: [Python-checkins] r60095 - in python/trunk/Lib: mailbox.py test/test_mailbox.py Message-ID: <20080119201204.7B70F1E401A@bag.python.org> Author: andrew.kuchling Date: Sat Jan 19 21:12:04 2008 New Revision: 60095 Modified: python/trunk/Lib/mailbox.py python/trunk/Lib/test/test_mailbox.py Log: Bug 1277: make Maildir use the user-provided factory instead of hard-wiring MaildirMessage. 2.5.2 bugfix candidate. Modified: python/trunk/Lib/mailbox.py ============================================================================== --- python/trunk/Lib/mailbox.py (original) +++ python/trunk/Lib/mailbox.py Sat Jan 19 21:12:04 2008 @@ -315,7 +315,10 @@ subpath = self._lookup(key) f = open(os.path.join(self._path, subpath), 'r') try: - msg = MaildirMessage(f) + if self._factory: + msg = self._factory(f) + else: + msg = MaildirMessage(f) finally: f.close() subdir, name = os.path.split(subpath) Modified: python/trunk/Lib/test/test_mailbox.py ============================================================================== --- python/trunk/Lib/test/test_mailbox.py (original) +++ python/trunk/Lib/test/test_mailbox.py Sat Jan 19 21:12:04 2008 @@ -509,6 +509,20 @@ self.assert_(msg_returned.get_flags() == 'S') self.assert_(msg_returned.get_payload() == '3') + def test_consistent_factory(self): + # Add a message. + msg = mailbox.MaildirMessage(self._template % 0) + msg.set_subdir('cur') + msg.set_flags('RF') + key = self._box.add(msg) + + # Create new mailbox with + class FakeMessage(mailbox.MaildirMessage): + pass + box = mailbox.Maildir(self._path, factory=FakeMessage) + msg2 = box.get_message(key) + self.assert_(isinstance(msg2, FakeMessage)) + def test_initialize_new(self): # Initialize a non-existent mailbox self.tearDown() From python-checkins at python.org Sat Jan 19 21:14:40 2008 From: python-checkins at python.org (andrew.kuchling) Date: Sat, 19 Jan 2008 21:14:40 +0100 (CET) Subject: [Python-checkins] r60096 - in python/branches/release25-maint/Lib: mailbox.py test/test_mailbox.py Message-ID: <20080119201440.85C7C1E401A@bag.python.org> Author: andrew.kuchling Date: Sat Jan 19 21:14:40 2008 New Revision: 60096 Modified: python/branches/release25-maint/Lib/mailbox.py python/branches/release25-maint/Lib/test/test_mailbox.py Log: Bug 1277: make Maildir use the user-provided factory instead of hard-wiring MaildirMessage. Modified: python/branches/release25-maint/Lib/mailbox.py ============================================================================== --- python/branches/release25-maint/Lib/mailbox.py (original) +++ python/branches/release25-maint/Lib/mailbox.py Sat Jan 19 21:14:40 2008 @@ -315,7 +315,10 @@ subpath = self._lookup(key) f = open(os.path.join(self._path, subpath), 'r') try: - msg = MaildirMessage(f) + if self._factory: + msg = self._factory(f) + else: + msg = MaildirMessage(f) finally: f.close() subdir, name = os.path.split(subpath) Modified: python/branches/release25-maint/Lib/test/test_mailbox.py ============================================================================== --- python/branches/release25-maint/Lib/test/test_mailbox.py (original) +++ python/branches/release25-maint/Lib/test/test_mailbox.py Sat Jan 19 21:14:40 2008 @@ -508,6 +508,20 @@ self.assert_(msg_returned.get_flags() == 'S') self.assert_(msg_returned.get_payload() == '3') + def test_consistent_factory(self): + # Add a message. + msg = mailbox.MaildirMessage(self._template % 0) + msg.set_subdir('cur') + msg.set_flags('RF') + key = self._box.add(msg) + + # Create new mailbox with + class FakeMessage(mailbox.MaildirMessage): + pass + box = mailbox.Maildir(self._path, factory=FakeMessage) + msg2 = box.get_message(key) + self.assert_(isinstance(msg2, FakeMessage)) + def test_initialize_new(self): # Initialize a non-existent mailbox self.tearDown() From python-checkins at python.org Sat Jan 19 21:22:14 2008 From: python-checkins at python.org (georg.brandl) Date: Sat, 19 Jan 2008 21:22:14 +0100 (CET) Subject: [Python-checkins] r60097 - in python/trunk: Doc/library/os.rst Lib/subprocess.py Lib/test/test_os.py Misc/NEWS Modules/posixmodule.c Message-ID: <20080119202214.041F01E401B@bag.python.org> Author: georg.brandl Date: Sat Jan 19 21:22:13 2008 New Revision: 60097 Modified: python/trunk/Doc/library/os.rst python/trunk/Lib/subprocess.py python/trunk/Lib/test/test_os.py python/trunk/Misc/NEWS python/trunk/Modules/posixmodule.c Log: #1663329: add os.closerange() to close a range of fds, ignoring errors, and use this in subprocess to speed up subprocess creation in close_fds mode. Patch by Mike Klaas. Modified: python/trunk/Doc/library/os.rst ============================================================================== --- python/trunk/Doc/library/os.rst (original) +++ python/trunk/Doc/library/os.rst Sat Jan 19 21:22:13 2008 @@ -481,6 +481,20 @@ :func:`fdopen`, use its :meth:`close` method. +.. function:: closerange(fd_low, fd_high) + + Close all file descriptors from *fd_low* (inclusive) to *fd_high* (exclusive), + ignoring errors. Availability: Macintosh, Unix, Windows. Equivalent to:: + + for fd in xrange(fd_low, fd_high): + try: + os.close(fd) + except OSError: + pass + + .. versionadded:: 2.6 + + .. function:: dup(fd) Return a duplicate of file descriptor *fd*. Availability: Macintosh, Unix, Modified: python/trunk/Lib/subprocess.py ============================================================================== --- python/trunk/Lib/subprocess.py (original) +++ python/trunk/Lib/subprocess.py Sat Jan 19 21:22:13 2008 @@ -965,13 +965,8 @@ def _close_fds(self, but): - for i in xrange(3, MAXFD): - if i == but: - continue - try: - os.close(i) - except: - pass + os.closerange(3, but) + os.closerange(but + 1, MAXFD) def _execute_child(self, args, executable, preexec_fn, close_fds, Modified: python/trunk/Lib/test/test_os.py ============================================================================== --- python/trunk/Lib/test/test_os.py (original) +++ python/trunk/Lib/test/test_os.py Sat Jan 19 21:22:13 2008 @@ -23,6 +23,12 @@ os.close(f) self.assert_(os.access(test_support.TESTFN, os.W_OK)) + def test_closerange(self): + f = os.open(test_support.TESTFN, os.O_CREAT|os.O_RDWR) + # close a fd that is open, and one that isn't + os.closerange(f, f+2) + self.assertRaises(OSError, os.write, f, "a") + class TemporaryFileTests(unittest.TestCase): def setUp(self): Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Sat Jan 19 21:22:13 2008 @@ -1019,6 +1019,9 @@ Extension Modules ----------------- +- Patch #1663329: added ``os.closerange()`` function to quickly close a range + of file descriptors without considering errors. + - Patch 976880: ``mmap`` objects now have an ``rfind`` method that works as expected. ``mmap.find`` also takes an optional ``end`` parameter. Modified: python/trunk/Modules/posixmodule.c ============================================================================== --- python/trunk/Modules/posixmodule.c (original) +++ python/trunk/Modules/posixmodule.c Sat Jan 19 21:22:13 2008 @@ -6156,6 +6156,24 @@ } +PyDoc_STRVAR(posix_closerange__doc__, +"closerange(fd_low, fd_high)\n\n\ +Closes all file descriptors in [fd_low, fd_high), ignoring errors."); + +static PyObject * +posix_closerange(PyObject *self, PyObject *args) +{ + int fd_from, fd_to, i; + if (!PyArg_ParseTuple(args, "ii:closerange", &fd_from, &fd_to)) + return NULL; + Py_BEGIN_ALLOW_THREADS + for (i = fd_from; i < fd_to; i++) + close(i); + Py_END_ALLOW_THREADS + Py_RETURN_NONE; +} + + PyDoc_STRVAR(posix_dup__doc__, "dup(fd) -> fd2\n\n\ Return a duplicate of a file descriptor."); @@ -8451,6 +8469,7 @@ #endif /* HAVE_TCSETPGRP */ {"open", posix_open, METH_VARARGS, posix_open__doc__}, {"close", posix_close, METH_VARARGS, posix_close__doc__}, + {"closerange", posix_closerange, METH_VARARGS, posix_closerange__doc__}, {"dup", posix_dup, METH_VARARGS, posix_dup__doc__}, {"dup2", posix_dup2, METH_VARARGS, posix_dup2__doc__}, {"lseek", posix_lseek, METH_VARARGS, posix_lseek__doc__}, From python-checkins at python.org Sat Jan 19 21:34:19 2008 From: python-checkins at python.org (georg.brandl) Date: Sat, 19 Jan 2008 21:34:19 +0100 (CET) Subject: [Python-checkins] r60098 - in python/branches/release25-maint: Lib/plat-mac/plistlib.py Misc/NEWS Message-ID: <20080119203419.D0F8F1E4007@bag.python.org> Author: georg.brandl Date: Sat Jan 19 21:34:19 2008 New Revision: 60098 Modified: python/branches/release25-maint/Lib/plat-mac/plistlib.py python/branches/release25-maint/Misc/NEWS Log: Backport r59688. Modified: python/branches/release25-maint/Lib/plat-mac/plistlib.py ============================================================================== --- python/branches/release25-maint/Lib/plat-mac/plistlib.py (original) +++ python/branches/release25-maint/Lib/plat-mac/plistlib.py Sat Jan 19 21:34:19 2008 @@ -240,8 +240,8 @@ self.simpleElement("true") else: self.simpleElement("false") - elif isinstance(value, int): - self.simpleElement("integer", str(value)) + elif isinstance(value, (int, long)): + self.simpleElement("integer", "%d" % value) elif isinstance(value, float): self.simpleElement("real", repr(value)) elif isinstance(value, dict): Modified: python/branches/release25-maint/Misc/NEWS ============================================================================== --- python/branches/release25-maint/Misc/NEWS (original) +++ python/branches/release25-maint/Misc/NEWS Sat Jan 19 21:34:19 2008 @@ -53,6 +53,8 @@ Library ------- +- Bug #1687: Fixed plistlib.py restricts to Python int when writing. + - Issue #1182: many arithmetic bugs in the decimal module have been fixed, and the decimal module has been updated to comply with the latest IBM Decimal Arithmetic specification (version 1.66) and From python-checkins at python.org Sat Jan 19 21:40:25 2008 From: python-checkins at python.org (georg.brandl) Date: Sat, 19 Jan 2008 21:40:25 +0100 (CET) Subject: [Python-checkins] r60099 - python/trunk/Doc/library/xml.sax.utils.rst Message-ID: <20080119204025.25C051E4007@bag.python.org> Author: georg.brandl Date: Sat Jan 19 21:40:24 2008 New Revision: 60099 Modified: python/trunk/Doc/library/xml.sax.utils.rst Log: #1411695: clarify behavior of xml.sax.utils.[un]escape. Modified: python/trunk/Doc/library/xml.sax.utils.rst ============================================================================== --- python/trunk/Doc/library/xml.sax.utils.rst (original) +++ python/trunk/Doc/library/xml.sax.utils.rst Sat Jan 19 21:40:24 2008 @@ -21,7 +21,8 @@ You can escape other strings of data by passing a dictionary as the optional *entities* parameter. The keys and values must all be strings; each key will be - replaced with its corresponding value. + replaced with its corresponding value. The characters ``'&'``, ``'<'`` and + ``'>'`` are always escaped, even if *entities* is provided. .. function:: unescape(data[, entities]) @@ -30,7 +31,8 @@ You can unescape other strings of data by passing a dictionary as the optional *entities* parameter. The keys and values must all be strings; each key will be - replaced with its corresponding value. + replaced with its corresponding value. ``'&'``, ``'<'``, and ``'>'`` + are always unescaped, even if *entities* is provided. .. versionadded:: 2.3 From python-checkins at python.org Sat Jan 19 21:47:59 2008 From: python-checkins at python.org (andrew.kuchling) Date: Sat, 19 Jan 2008 21:47:59 +0100 (CET) Subject: [Python-checkins] r60101 - in python/trunk: Misc/ACKS Misc/NEWS Modules/socketmodule.c Message-ID: <20080119204759.F28161E4007@bag.python.org> Author: andrew.kuchling Date: Sat Jan 19 21:47:59 2008 New Revision: 60101 Modified: python/trunk/Misc/ACKS python/trunk/Misc/NEWS python/trunk/Modules/socketmodule.c Log: Patch #1019808 from Federico Schwindt: Return correct socket error when a default timeout has been set, by using getsockopt() to get the error condition (instead of trying another connect() call, which seems to be a Linuxism). 2.5 bugfix candidate, assuming no one reports any problems with this change. Modified: python/trunk/Misc/ACKS ============================================================================== --- python/trunk/Misc/ACKS (original) +++ python/trunk/Misc/ACKS Sat Jan 19 21:47:59 2008 @@ -589,6 +589,7 @@ Sam Schulenburg Stefan Schwarzer Dietmar Schwertberger +Federico Schwindt Barry Scott Steven Scott Nick Seidenman Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Sat Jan 19 21:47:59 2008 @@ -1120,6 +1120,9 @@ - Patch #1544279: Improve thread-safety of the socket module by moving the sock_addr_t storage out of the socket object. +- Patch #1019808: fix bug that causes an incorrect error to be returned + when a socket timeout is set and a connection attempt fails. + - Speed up function calls into the math module. - Bug #1588217: don't parse "= " as a soft line break in binascii's Modified: python/trunk/Modules/socketmodule.c ============================================================================== --- python/trunk/Modules/socketmodule.c (original) +++ python/trunk/Modules/socketmodule.c Sat Jan 19 21:47:59 2008 @@ -1986,15 +1986,22 @@ #else if (s->sock_timeout > 0.0) { - if (res < 0 && errno == EINPROGRESS && IS_SELECTABLE(s)) { - timeout = internal_select(s, 1); - if (timeout == 0) { - res = connect(s->sock_fd, addr, addrlen); - if (res < 0 && errno == EISCONN) - res = 0; - } - else if (timeout == -1) - res = errno; /* had error */ + if (res < 0 && errno == EINPROGRESS && IS_SELECTABLE(s)) { + timeout = internal_select(s, 1); + if (timeout == 0) { + /* Bug #1019808: in case of an EINPROGRESS, + use getsockopt(SO_ERROR) to get the real + error. */ + socklen_t res_size = sizeof res; + (void)getsockopt(s->sock_fd, SOL_SOCKET, + SO_ERROR, &res, &res_size); + if (res == EISCONN) + res = 0; + errno = res; + } + else if (timeout == -1) { + res = errno; /* had error */ + } else res = EWOULDBLOCK; /* timed out */ } From python-checkins at python.org Sat Jan 19 21:49:02 2008 From: python-checkins at python.org (gregory.p.smith) Date: Sat, 19 Jan 2008 21:49:02 +0100 (CET) Subject: [Python-checkins] r60102 - in python/trunk/Lib: subprocess.py test/test_subprocess.py Message-ID: <20080119204902.DA2481E4007@bag.python.org> Author: gregory.p.smith Date: Sat Jan 19 21:49:02 2008 New Revision: 60102 Modified: python/trunk/Lib/subprocess.py python/trunk/Lib/test/test_subprocess.py Log: fix comment typos, use not arg instead of arg == "", add test coverage for inside of the final if needquotes: within subprocess.list2cmdline(). Modified: python/trunk/Lib/subprocess.py ============================================================================== --- python/trunk/Lib/subprocess.py (original) +++ python/trunk/Lib/subprocess.py Sat Jan 19 21:49:02 2008 @@ -497,7 +497,7 @@ if result: result.append(' ') - needquote = (" " in arg) or ("\t" in arg) or arg == "" + needquote = (" " in arg) or ("\t" in arg) or not arg if needquote: result.append('"') @@ -506,7 +506,7 @@ # Don't know if we need to double yet. bs_buf.append(c) elif c == '"': - # Double backspaces. + # Double backslashes. result.append('\\' * len(bs_buf)*2) bs_buf = [] result.append('\\"') @@ -517,7 +517,7 @@ bs_buf = [] result.append(c) - # Add remaining backspaces, if any. + # Add remaining backslashes, if any. if bs_buf: result.extend(bs_buf) Modified: python/trunk/Lib/test/test_subprocess.py ============================================================================== --- python/trunk/Lib/test/test_subprocess.py (original) +++ python/trunk/Lib/test/test_subprocess.py Sat Jan 19 21:49:02 2008 @@ -422,6 +422,8 @@ '"a b c" d e') self.assertEqual(subprocess.list2cmdline(['ab"c', '\\', 'd']), 'ab\\"c \\ d') + self.assertEqual(subprocess.list2cmdline(['ab"c', ' \\', 'd']), + 'ab\\"c " \\\\" d') self.assertEqual(subprocess.list2cmdline(['a\\\\\\b', 'de fg', 'h']), 'a\\\\\\b "de fg" h') self.assertEqual(subprocess.list2cmdline(['a\\"b', 'c', 'd']), From nnorwitz at gmail.com Sat Jan 19 22:12:40 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Sat, 19 Jan 2008 16:12:40 -0500 Subject: [Python-checkins] Python Regression Test Failures basics (1) Message-ID: <20080119211240.GA27778@python.psfb.org> test_grammar test_opcodes test_dict test_builtin test_exceptions test_types test_unittest test_doctest test_doctest2 test_MimeWriter test_StringIO test___all__ test___future__ test__locale test_abc test_abstract_numbers test_aepack test_aepack skipped -- No module named aepack test_al test_al skipped -- No module named al test_anydbm test_applesingle test_applesingle skipped -- No module named macostools test_array test_ast test_asynchat test_asyncore test_atexit test_audioop test_augassign test_base64 test_bastion test_bigaddrspace test_bigmem test_binascii test_binhex test_binop test_bisect test_bool test_bsddb test_bsddb185 test_bsddb185 skipped -- No module named bsddb185 test_bsddb3 test_bsddb3 skipped -- Use of the `bsddb' resource not enabled test_buffer test_bufio test_bz2 test_cProfile test_calendar test_call test_capi test_cd test_cd skipped -- No module named cd test_cfgparser test_cgi test_charmapcodec test_cl test_cl skipped -- No module named cl test_class test_cmath test_cmd test_cmd_line test_cmd_line_script test_code test_codeccallbacks test_codecencodings_cn test_codecencodings_hk test_codecencodings_jp test_codecencodings_kr test_codecencodings_tw test_codecmaps_cn test_codecmaps_cn skipped -- Use of the `urlfetch' resource not enabled test_codecmaps_hk test_codecmaps_hk skipped -- Use of the `urlfetch' resource not enabled test_codecmaps_jp test_codecmaps_jp skipped -- Use of the `urlfetch' resource not enabled test_codecmaps_kr test_codecmaps_kr skipped -- Use of the `urlfetch' resource not enabled test_codecmaps_tw test_codecmaps_tw skipped -- Use of the `urlfetch' resource not enabled test_codecs test_codeop test_coding test_coercion test_collections test_colorsys test_commands test_compare test_compile test_compiler test_complex test_complex_args test_contains test_contextlib test_cookie test_cookielib test_copy test_copy_reg test_cpickle test_crypt test_csv test_ctypes test_curses test_curses skipped -- Use of the `curses' resource not enabled test_datetime test_dbm test_decimal test_decorators test_defaultdict test_deque test_descr test_descrtut test_difflib test_dircache test_dis test_distutils test_dl test_docxmlrpc test_dumbdbm test_dummy_thread test_dummy_threading test_email test_email_codecs test_email_renamed test_enumerate test_eof test_errno test_exception_variations test_extcall test_fcntl test_file test_filecmp test_fileinput test_float test_fnmatch test_fork1 test_format test_fpformat test_frozen test_ftplib test test_ftplib failed -- Traceback (most recent call last): File "/tmp/python-test/local/lib/python2.6/test/test_ftplib.py", line 72, in testTimeoutDirectAccess ftp.connect("localhost") File "/tmp/python-test/local/lib/python2.6/ftplib.py", line 129, in connect self.sock = socket.create_connection((self.host, self.port), self.timeout) File "/tmp/python-test/local/lib/python2.6/socket.py", line 465, in create_connection raise error, msg error: [Errno 111] Connection refused test_funcattrs test_functools test_future test_gc test_gdbm test_generators test_genericpath test_genexps test_getargs test_getargs2 test_getopt test_gettext test_gl test_gl skipped -- No module named gl test_glob test_global test_grp test_gzip test_hash test_hashlib test_heapq test_hexoct test_hmac test_hotshot test_htmllib test_htmlparser test_httplib test_imageop test_imageop skipped -- No module named imgfile test_imaplib test_imgfile test_imgfile skipped -- No module named imgfile test_imp test_import test_importhooks test_index test_inspect test_ioctl test_ioctl skipped -- Unable to open /dev/tty test_isinstance test_iter test_iterlen test_itertools test_largefile test_linuxaudiodev test_linuxaudiodev skipped -- Use of the `audio' resource not enabled test_list test_locale test_logging test_long test_long_future test_longexp test_macostools test_macostools skipped -- No module named macostools test_macpath test_mailbox test_marshal test_math test_md5 test_mhlib test_mimetools test_mimetypes test_minidom test_mmap test_module test_modulefinder test_multibytecodec test_multibytecodec_support test_multifile test_mutants test_netrc test_new test_nis test_normalization test_normalization skipped -- Use of the `urlfetch' resource not enabled test_ntpath test_old_mailbox test_openpty test_operator test_optparse test_os test_ossaudiodev test_ossaudiodev skipped -- Use of the `audio' resource not enabled test_parser test_peepholer test_pep247 test_pep263 test_pep277 test_pep277 skipped -- test works only on NT+ test_pep292 test_pep352 test_pickle test_pickletools test_pipes test_pkg test_pkgimport test_platform test_plistlib test_plistlib skipped -- No module named plistlib test_poll test_popen [8900 refs] [8900 refs] [8900 refs] test_popen2 test_poplib test_posix test_posixpath test_pow test_pprint test_profile test_profilehooks test_property test_pty test_pwd test_pyclbr test_pyexpat test_queue test_quopri [9269 refs] [9269 refs] test_random test_rational test_re test_repr test_resource test_rfc822 test_richcmp test_robotparser test_runpy test_sax test_scope test_scriptpackages test_scriptpackages skipped -- No module named aetools test_select test_set test_sets test_sgmllib test_sha test_shelve test_shlex test_shutil test_signal test_site test_slice test_smtplib test_socket test_socket_ssl /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:94: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ssl_sock = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:130: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:144: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) test_socketserver test_socketserver skipped -- Use of the `network' resource not enabled test_softspace test_sort test_sqlite test_ssl test_startfile test_startfile skipped -- cannot import name startfile test_str test_strftime test_string test_stringprep test_strop test_strptime test_struct test_structmembers test_structseq test_subprocess [8895 refs] [8898 refs] [8895 refs] [8895 refs] [8895 refs] [8895 refs] [8895 refs] [8895 refs] [8895 refs] [8897 refs] [8898 refs] [10449 refs] [9113 refs] [8898 refs] [8895 refs] [8895 refs] [8895 refs] [8895 refs] [8895 refs] . [8895 refs] [8895 refs] this bit of output is from a test of stdout in a different process ... [8895 refs] [8895 refs] [9113 refs] test_sunaudiodev test_sunaudiodev skipped -- No module named sunaudiodev test_sundry test_symtable test_syntax test_sys [8895 refs] [8895 refs] test_tarfile test_tcl test_tcl skipped -- No module named _tkinter test_telnetlib test_tempfile [8901 refs] test_textwrap test_thread test_threaded_import test_threadedtempfile test_threading [13143 refs] test_threading_local test_threadsignals test_time test_timeout test_timeout skipped -- Use of the `network' resource not enabled test_tokenize test_trace test_traceback test_transformer test_tuple test_typechecks test_ucn test_unary test_unicode test_unicode_file test_unicode_file skipped -- No Unicode filesystem semantics on this platform. test_unicodedata test_univnewlines test_unpack test_urllib test_urllib2 test_urllib2_localnet test_urllib2net test_urllib2net skipped -- Use of the `network' resource not enabled test_urllibnet test_urllibnet skipped -- Use of the `network' resource not enabled test_urlparse test_userdict test_userlist test_userstring test_uu test_uuid WARNING: uuid.getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._ifconfig_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._unixdll_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. test_wait3 test_wait4 test_warnings test_wave test_weakref test_whichdb test_winreg test_winreg skipped -- No module named _winreg test_winsound test_winsound skipped -- No module named winsound test_with test_wsgiref test_xdrlib test_xml_etree test_xml_etree_c test_xmllib test_xmlrpc test_xpickle test_xrange test_zipfile test_zipfile64 test_zipfile64 skipped -- test requires loads of disk-space bytes and a long time to run test_zipimport test_zlib 302 tests OK. 1 test failed: test_ftplib 35 tests skipped: test_aepack test_al test_applesingle test_bsddb185 test_bsddb3 test_cd test_cl test_codecmaps_cn test_codecmaps_hk test_codecmaps_jp test_codecmaps_kr test_codecmaps_tw test_curses test_gl test_imageop test_imgfile test_ioctl test_linuxaudiodev test_macostools test_normalization test_ossaudiodev test_pep277 test_plistlib test_scriptpackages test_socketserver test_startfile test_sunaudiodev test_tcl test_timeout test_unicode_file test_urllib2net test_urllibnet test_winreg test_winsound test_zipfile64 1 skip unexpected on linux2: test_ioctl [530560 refs] From python-checkins at python.org Sat Jan 19 21:53:08 2008 From: python-checkins at python.org (georg.brandl) Date: Sat, 19 Jan 2008 21:53:08 +0100 (CET) Subject: [Python-checkins] r60103 - in python/trunk: Doc/library/sqlite3.rst Modules/_sqlite/cursor.c Message-ID: <20080119205308.100ED1E4007@bag.python.org> Author: georg.brandl Date: Sat Jan 19 21:53:07 2008 New Revision: 60103 Modified: python/trunk/Doc/library/sqlite3.rst python/trunk/Modules/_sqlite/cursor.c Log: #1509: fix sqlite3 docstrings and docs w.r.t. cursor.fetchXXX methods. Modified: python/trunk/Doc/library/sqlite3.rst ============================================================================== --- python/trunk/Doc/library/sqlite3.rst (original) +++ python/trunk/Doc/library/sqlite3.rst Sat Jan 19 21:53:07 2008 @@ -1,4 +1,3 @@ - :mod:`sqlite3` --- DB-API 2.0 interface for SQLite databases ============================================================ @@ -389,7 +388,7 @@ .. method:: Cursor.execute(sql, [parameters]) - Executes a SQL statement. The SQL statement may be parametrized (i. e. + Executes an SQL statement. The SQL statement may be parametrized (i. e. placeholders instead of SQL literals). The :mod:`sqlite3` module supports two kinds of placeholders: question marks (qmark style) and named placeholders (named style). @@ -410,7 +409,7 @@ .. method:: Cursor.executemany(sql, seq_of_parameters) - Executes a SQL command against all parameter sequences or mappings found in + Executes an SQL command against all parameter sequences or mappings found in the sequence *sql*. The :mod:`sqlite3` module also allows using an :term:`iterator` yielding parameters instead of a sequence. @@ -434,6 +433,35 @@ .. literalinclude:: ../includes/sqlite3/executescript.py +.. method:: Cursor.fetchone() + + Fetches the next row of a query result set, returning a single sequence, + or ``None`` when no more data is available. + + +.. method:: Cursor.fetchmany([size=cursor.arraysize]) + + Fetches the next set of rows of a query result, returning a list. An empty + list is returned when no more rows are available. + + The number of rows to fetch per call is specified by the *size* parameter. + If it is not given, the cursor's arraysize determines the number of rows + to be fetched. The method should try to fetch as many rows as indicated by + the size parameter. If this is not possible due to the specified number of + rows not being available, fewer rows may be returned. + + Note there are performance considerations involved with the *size* parameter. + For optimal performance, it is usually best to use the arraysize attribute. + If the *size* parameter is used, then it is best for it to retain the same + value from one :meth:`fetchmany` call to the next. + +.. method:: Cursor.fetchall() + + Fetches all (remaining) rows of a query result, returning a list. Note that + the cursor's arraysize attribute can affect the performance of this operation. + An empty list is returned when no rows are available. + + .. attribute:: Cursor.rowcount Although the :class:`Cursor` class of the :mod:`sqlite3` module implements this Modified: python/trunk/Modules/_sqlite/cursor.c ============================================================================== --- python/trunk/Modules/_sqlite/cursor.c (original) +++ python/trunk/Modules/_sqlite/cursor.c Sat Jan 19 21:53:07 2008 @@ -991,11 +991,11 @@ {"executescript", (PyCFunction)pysqlite_cursor_executescript, METH_VARARGS, PyDoc_STR("Executes a multiple SQL statements at once. Non-standard.")}, {"fetchone", (PyCFunction)pysqlite_cursor_fetchone, METH_NOARGS, - PyDoc_STR("Fetches several rows from the resultset.")}, + PyDoc_STR("Fetches one row from the resultset.")}, {"fetchmany", (PyCFunction)pysqlite_cursor_fetchmany, METH_VARARGS, - PyDoc_STR("Fetches all rows from the resultset.")}, + PyDoc_STR("Fetches several rows from the resultset.")}, {"fetchall", (PyCFunction)pysqlite_cursor_fetchall, METH_NOARGS, - PyDoc_STR("Fetches one row from the resultset.")}, + PyDoc_STR("Fetches all rows from the resultset.")}, {"close", (PyCFunction)pysqlite_cursor_close, METH_NOARGS, PyDoc_STR("Closes the cursor.")}, {"setinputsizes", (PyCFunction)pysqlite_noop, METH_VARARGS, From python-checkins at python.org Sat Jan 19 21:57:59 2008 From: python-checkins at python.org (gregory.p.smith) Date: Sat, 19 Jan 2008 21:57:59 +0100 (CET) Subject: [Python-checkins] r60104 - python/trunk/Lib/subprocess.py Message-ID: <20080119205759.C740B1E4007@bag.python.org> Author: gregory.p.smith Date: Sat Jan 19 21:57:59 2008 New Revision: 60104 Modified: python/trunk/Lib/subprocess.py Log: Fixes issue1336 - a race condition could occur when forking if the gc kicked in during the critical section. solution: disable gc during that section. Patch contributed by jpa and updated by me to cover the race condition still existing what therve from twistedmatrix pointed out (already seen and fixed in twisted's own subprocess code). Modified: python/trunk/Lib/subprocess.py ============================================================================== --- python/trunk/Lib/subprocess.py (original) +++ python/trunk/Lib/subprocess.py Sat Jan 19 21:57:59 2008 @@ -356,6 +356,7 @@ import os import types import traceback +import gc # Exception classes used by this module. class CalledProcessError(Exception): @@ -994,66 +995,78 @@ errpipe_read, errpipe_write = os.pipe() self._set_cloexec_flag(errpipe_write) - self.pid = os.fork() - self._child_created = True - if self.pid == 0: - # Child - try: - # Close parent's pipe ends - if p2cwrite is not None: - os.close(p2cwrite) - if c2pread is not None: - os.close(c2pread) - if errread is not None: - os.close(errread) - os.close(errpipe_read) - - # Dup fds for child - if p2cread is not None: - os.dup2(p2cread, 0) - if c2pwrite is not None: - os.dup2(c2pwrite, 1) - if errwrite is not None: - os.dup2(errwrite, 2) - - # Close pipe fds. Make sure we don't close the same - # fd more than once, or standard fds. - if p2cread is not None and p2cread not in (0,): - os.close(p2cread) - if c2pwrite is not None and c2pwrite not in (p2cread, 1): - os.close(c2pwrite) - if errwrite is not None and errwrite not in (p2cread, c2pwrite, 2): - os.close(errwrite) - - # Close all other fds, if asked for - if close_fds: - self._close_fds(but=errpipe_write) - - if cwd is not None: - os.chdir(cwd) - - if preexec_fn: - apply(preexec_fn) - - if env is None: - os.execvp(executable, args) - else: - os.execvpe(executable, args, env) - - except: - exc_type, exc_value, tb = sys.exc_info() - # Save the traceback and attach it to the exception object - exc_lines = traceback.format_exception(exc_type, - exc_value, - tb) - exc_value.child_traceback = ''.join(exc_lines) - os.write(errpipe_write, pickle.dumps(exc_value)) - - # This exitcode won't be reported to applications, so it - # really doesn't matter what we return. - os._exit(255) + gc_was_enabled = gc.isenabled() + # Disable gc to avoid bug where gc -> file_dealloc -> + # write to stderr -> hang. http://bugs.python.org/issue1336 + gc.disable() + try: + self.pid = os.fork() + except: + if gc_was_enabled: + gc.enable() + raise + else: + self._child_created = True + if self.pid == 0: + # Child + try: + # Close parent's pipe ends + if p2cwrite is not None: + os.close(p2cwrite) + if c2pread is not None: + os.close(c2pread) + if errread is not None: + os.close(errread) + os.close(errpipe_read) + + # Dup fds for child + if p2cread is not None: + os.dup2(p2cread, 0) + if c2pwrite is not None: + os.dup2(c2pwrite, 1) + if errwrite is not None: + os.dup2(errwrite, 2) + + # Close pipe fds. Make sure we don't close the same + # fd more than once, or standard fds. + if p2cread is not None and p2cread not in (0,): + os.close(p2cread) + if c2pwrite is not None and c2pwrite not in (p2cread, 1): + os.close(c2pwrite) + if errwrite is not None and errwrite not in (p2cread, c2pwrite, 2): + os.close(errwrite) + + # Close all other fds, if asked for + if close_fds: + self._close_fds(but=errpipe_write) + + if cwd is not None: + os.chdir(cwd) + + if preexec_fn: + apply(preexec_fn) + + if env is None: + os.execvp(executable, args) + else: + os.execvpe(executable, args, env) + + except: + exc_type, exc_value, tb = sys.exc_info() + # Save the traceback and attach it to the exception object + exc_lines = traceback.format_exception(exc_type, + exc_value, + tb) + exc_value.child_traceback = ''.join(exc_lines) + os.write(errpipe_write, pickle.dumps(exc_value)) + + # This exitcode won't be reported to applications, so it + # really doesn't matter what we return. + os._exit(255) # Parent + if gc_was_enabled: + gc.enable() os.close(errpipe_write) if p2cread is not None and p2cwrite is not None: os.close(p2cread) From python-checkins at python.org Sat Jan 19 22:00:38 2008 From: python-checkins at python.org (gregory.p.smith) Date: Sat, 19 Jan 2008 22:00:38 +0100 (CET) Subject: [Python-checkins] r60105 - python/trunk/Misc/NEWS Message-ID: <20080119210038.0A0041E4007@bag.python.org> Author: gregory.p.smith Date: Sat Jan 19 22:00:37 2008 New Revision: 60105 Modified: python/trunk/Misc/NEWS Log: note about r60104 Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Sat Jan 19 22:00:37 2008 @@ -369,6 +369,10 @@ Library ------- +- #1336: fix a race condition in subprocess.Popen if the garbage + collector kicked in at the wrong time that would cause the process + to hang when the child wrote to stderr. + - #1146: fix how textwrap breaks a long word that would start in the last column of a line. From python-checkins at python.org Sat Jan 19 22:00:38 2008 From: python-checkins at python.org (andrew.kuchling) Date: Sat, 19 Jan 2008 22:00:38 +0100 (CET) Subject: [Python-checkins] r60106 - python/trunk/Doc/library/optparse.rst Message-ID: <20080119210038.97A1B1E4007@bag.python.org> Author: andrew.kuchling Date: Sat Jan 19 22:00:38 2008 New Revision: 60106 Modified: python/trunk/Doc/library/optparse.rst Log: Bug 1296: restore text describing OptionGroup Modified: python/trunk/Doc/library/optparse.rst ============================================================================== --- python/trunk/Doc/library/optparse.rst (original) +++ python/trunk/Doc/library/optparse.rst Sat Jan 19 22:00:38 2008 @@ -539,6 +539,35 @@ default value. If an option has no default value (or the default value is ``None``), ``%default`` expands to ``none``. +When dealing with many options, it is convenient to group these +options for better help output. An :class:`OptionParser` can contain +several option groups, each of which can contain several options. + +Continuing with the parser defined above, adding an +:class:`OptionGroup` to a parser is easy:: + + group = OptionGroup(parser, "Dangerous Options", + "Caution: use these options at your own risk. " + "It is believed that some of them bite.") + group.add_option("-g", action="store_true", help="Group option.") + parser.add_option_group(group) + +This would result in the following help output:: + + usage: [options] arg1 arg2 + + options: + -h, --help show this help message and exit + -v, --verbose make lots of noise [default] + -q, --quiet be vewwy quiet (I'm hunting wabbits) + -fFILE, --file=FILE write output to FILE + -mMODE, --mode=MODE interaction mode: one of 'novice', 'intermediate' + [default], 'expert' + + Dangerous Options: + Caution: use of these options is at your own risk. It is believed that + some of them bite. + -g Group option. .. _optparse-printing-version-string: From python-checkins at python.org Sat Jan 19 22:01:39 2008 From: python-checkins at python.org (andrew.kuchling) Date: Sat, 19 Jan 2008 22:01:39 +0100 (CET) Subject: [Python-checkins] r60107 - python/branches/release25-maint/Doc/lib/liboptparse.tex Message-ID: <20080119210139.8F3E91E4007@bag.python.org> Author: andrew.kuchling Date: Sat Jan 19 22:01:39 2008 New Revision: 60107 Modified: python/branches/release25-maint/Doc/lib/liboptparse.tex Log: Bug 1296: restore text describing OptionGroup Modified: python/branches/release25-maint/Doc/lib/liboptparse.tex ============================================================================== --- python/branches/release25-maint/Doc/lib/liboptparse.tex (original) +++ python/branches/release25-maint/Doc/lib/liboptparse.tex Sat Jan 19 22:01:39 2008 @@ -558,6 +558,39 @@ \end{itemize} +When dealing with many options, it is convenient to group these +options for better help output. An \class{OptionParser} can contain +several option groups, each of which can contain several options. + +Continuing with the parser defined above, adding an +\class{OptionGroup} to a parser is easy: + +\begin{verbatim} +group = OptionGroup(parser, ``Dangerous Options'', + ``Caution: use these options at your own risk. `` + ``It is believed that some of them bite.'') +group.add_option(``-g'', action=''store_true'', help=''Group option.'') +parser.add_option_group(group) +\end{verbatim} + +This would result in the following help output: + +\begin{verbatim} +usage: [options] arg1 arg2 + +options: + -h, --help show this help message and exit + -v, --verbose make lots of noise [default] + -q, --quiet be vewwy quiet (I'm hunting wabbits) + -fFILE, --file=FILE write output to FILE + -mMODE, --mode=MODE interaction mode: one of 'novice', 'intermediate' + [default], 'expert' + + Dangerous Options: + Caution: use of these options is at your own risk. It is believed that + some of them bite. + -g Group option. +\end{verbatim} \subsubsection{Printing a version string\label{optparse-printing-version-string}} From buildbot at python.org Sat Jan 19 22:04:43 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 19 Jan 2008 21:04:43 +0000 Subject: [Python-checkins] buildbot failure in x86 gentoo 2.5 Message-ID: <20080119210444.150891E4007@bag.python.org> The Buildbot has detected a new failure of x86 gentoo 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20gentoo%202.5/builds/507 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-x86 Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: georg.brandl BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_socketserver make: *** [buildbottest] Error 1 sincerely, -The Buildbot From lists at cheimes.de Sat Jan 19 22:17:05 2008 From: lists at cheimes.de (Christian Heimes) Date: Sat, 19 Jan 2008 22:17:05 +0100 Subject: [Python-checkins] r60104 - python/trunk/Lib/subprocess.py In-Reply-To: <20080119205759.C740B1E4007@bag.python.org> References: <20080119205759.C740B1E4007@bag.python.org> Message-ID: <479268D1.6070309@cheimes.de> gregory.p.smith wrote: > Author: gregory.p.smith > Date: Sat Jan 19 21:57:59 2008 > New Revision: 60104 > > Modified: > python/trunk/Lib/subprocess.py > Log: > Fixes issue1336 - a race condition could occur when forking if the gc > kicked in during the critical section. solution: disable gc during > that section. Patch contributed by jpa and updated by me to cover the > race condition still existing what therve from twistedmatrix pointed > out (already seen and fixed in twisted's own subprocess code). > > > Modified: python/trunk/Lib/subprocess.py > ============================================================================== > --- python/trunk/Lib/subprocess.py (original) > +++ python/trunk/Lib/subprocess.py Sat Jan 19 21:57:59 2008 > @@ -356,6 +356,7 @@ > import os > import types > import traceback > +import gc > > # Exception classes used by this module. > class CalledProcessError(Exception): > @@ -994,66 +995,78 @@ > errpipe_read, errpipe_write = os.pipe() > self._set_cloexec_flag(errpipe_write) > > + gc_was_enabled = gc.isenabled() > + # Disable gc to avoid bug where gc -> file_dealloc -> > + # write to stderr -> hang. http://bugs.python.org/issue1336 > + gc.disable() [lots of lines which may fail] > > # Parent > + if gc_was_enabled: > + gc.enable() > os.close(errpipe_write) > if p2cread is not None and p2cwrite is not None: > os.close(p2cread) I'd feel better if the large block is surrounded by a try/finally block with finally: gc.enable() Christian, the paranoid From python-checkins at python.org Sat Jan 19 23:08:24 2008 From: python-checkins at python.org (georg.brandl) Date: Sat, 19 Jan 2008 23:08:24 +0100 (CET) Subject: [Python-checkins] r60109 - python/trunk/Doc/c-api/abstract.rst python/trunk/Doc/c-api/allocation.rst python/trunk/Doc/c-api/bool.rst python/trunk/Doc/c-api/buffer.rst python/trunk/Doc/c-api/cell.rst python/trunk/Doc/c-api/class.rst python/trunk/Doc/c-api/cobject.rst python/trunk/Doc/c-api/complex.rst python/trunk/Doc/c-api/concrete.rst python/trunk/Doc/c-api/datetime.rst python/trunk/Doc/c-api/descriptor.rst python/trunk/Doc/c-api/dict.rst python/trunk/Doc/c-api/file.rst python/trunk/Doc/c-api/float.rst python/trunk/Doc/c-api/function.rst python/trunk/Doc/c-api/gcsupport.rst python/trunk/Doc/c-api/gen.rst python/trunk/Doc/c-api/index.rst python/trunk/Doc/c-api/int.rst python/trunk/Doc/c-api/iter.rst python/trunk/Doc/c-api/iterator.rst python/trunk/Doc/c-api/list.rst python/trunk/Doc/c-api/long.rst python/trunk/Doc/c-api/mapping.rst python/trunk/Doc/c-api/method.rst python/trunk/Doc/c-api/module.rst python/trunk/Doc/c-api/newtypes.rst python/trunk/Doc/c-api/none.rst python/trunk/Doc/c-api/number.rst python/trunk/Doc/c-api/objbuffer.rst python/trunk/Doc/c-api/object.rst python/trunk/Doc/c-api/objimpl.rst python/trunk/Doc/c-api/sequence.rst python/trunk/Doc/c-api/set.rst python/trunk/Doc/c-api/slice.rst python/trunk/Doc/c-api/string.rst python/trunk/Doc/c-api/structures.rst python/trunk/Doc/c-api/tuple.rst python/trunk/Doc/c-api/type.rst python/trunk/Doc/c-api/typeobj.rst python/trunk/Doc/c-api/unicode.rst python/trunk/Doc/c-api/weakref.rst Message-ID: <20080119220824.782301E401A@bag.python.org> Author: georg.brandl Date: Sat Jan 19 23:08:21 2008 New Revision: 60109 Added: python/trunk/Doc/c-api/allocation.rst python/trunk/Doc/c-api/bool.rst python/trunk/Doc/c-api/buffer.rst python/trunk/Doc/c-api/cell.rst python/trunk/Doc/c-api/class.rst python/trunk/Doc/c-api/cobject.rst python/trunk/Doc/c-api/complex.rst python/trunk/Doc/c-api/datetime.rst python/trunk/Doc/c-api/descriptor.rst python/trunk/Doc/c-api/dict.rst python/trunk/Doc/c-api/file.rst python/trunk/Doc/c-api/float.rst python/trunk/Doc/c-api/function.rst python/trunk/Doc/c-api/gcsupport.rst python/trunk/Doc/c-api/gen.rst python/trunk/Doc/c-api/int.rst python/trunk/Doc/c-api/iter.rst python/trunk/Doc/c-api/iterator.rst python/trunk/Doc/c-api/list.rst python/trunk/Doc/c-api/long.rst python/trunk/Doc/c-api/mapping.rst python/trunk/Doc/c-api/method.rst python/trunk/Doc/c-api/module.rst python/trunk/Doc/c-api/none.rst python/trunk/Doc/c-api/number.rst python/trunk/Doc/c-api/objbuffer.rst python/trunk/Doc/c-api/object.rst python/trunk/Doc/c-api/objimpl.rst - copied, changed from r60093, python/trunk/Doc/c-api/newtypes.rst python/trunk/Doc/c-api/sequence.rst python/trunk/Doc/c-api/set.rst python/trunk/Doc/c-api/slice.rst python/trunk/Doc/c-api/string.rst python/trunk/Doc/c-api/structures.rst python/trunk/Doc/c-api/tuple.rst python/trunk/Doc/c-api/type.rst python/trunk/Doc/c-api/typeobj.rst python/trunk/Doc/c-api/unicode.rst python/trunk/Doc/c-api/weakref.rst Removed: python/trunk/Doc/c-api/newtypes.rst Modified: python/trunk/Doc/c-api/abstract.rst python/trunk/Doc/c-api/concrete.rst python/trunk/Doc/c-api/index.rst Log: Split the monstrous C API manual files in smaller parts. Modified: python/trunk/Doc/c-api/abstract.rst ============================================================================== --- python/trunk/Doc/c-api/abstract.rst (original) +++ python/trunk/Doc/c-api/abstract.rst Sat Jan 19 23:08:21 2008 @@ -16,1010 +16,11 @@ initialized, such as a list object that has been created by :cfunc:`PyList_New`, but whose items have not been set to some non-\ ``NULL`` value yet. +.. toctree:: -.. _object: - -Object Protocol -=============== - - -.. cfunction:: int PyObject_Print(PyObject *o, FILE *fp, int flags) - - Print an object *o*, on file *fp*. Returns ``-1`` on error. The flags argument - is used to enable certain printing options. The only option currently supported - is :const:`Py_PRINT_RAW`; if given, the :func:`str` of the object is written - instead of the :func:`repr`. - - -.. cfunction:: int PyObject_HasAttr(PyObject *o, PyObject *attr_name) - - Returns ``1`` if *o* has the attribute *attr_name*, and ``0`` otherwise. This - is equivalent to the Python expression ``hasattr(o, attr_name)``. This function - always succeeds. - - -.. cfunction:: int PyObject_HasAttrString(PyObject *o, const char *attr_name) - - Returns ``1`` if *o* has the attribute *attr_name*, and ``0`` otherwise. This - is equivalent to the Python expression ``hasattr(o, attr_name)``. This function - always succeeds. - - -.. cfunction:: PyObject* PyObject_GetAttr(PyObject *o, PyObject *attr_name) - - Retrieve an attribute named *attr_name* from object *o*. Returns the attribute - value on success, or *NULL* on failure. This is the equivalent of the Python - expression ``o.attr_name``. - - -.. cfunction:: PyObject* PyObject_GetAttrString(PyObject *o, const char *attr_name) - - Retrieve an attribute named *attr_name* from object *o*. Returns the attribute - value on success, or *NULL* on failure. This is the equivalent of the Python - expression ``o.attr_name``. - - -.. cfunction:: int PyObject_SetAttr(PyObject *o, PyObject *attr_name, PyObject *v) - - Set the value of the attribute named *attr_name*, for object *o*, to the value - *v*. Returns ``-1`` on failure. This is the equivalent of the Python statement - ``o.attr_name = v``. - - -.. cfunction:: int PyObject_SetAttrString(PyObject *o, const char *attr_name, PyObject *v) - - Set the value of the attribute named *attr_name*, for object *o*, to the value - *v*. Returns ``-1`` on failure. This is the equivalent of the Python statement - ``o.attr_name = v``. - - -.. cfunction:: int PyObject_DelAttr(PyObject *o, PyObject *attr_name) - - Delete attribute named *attr_name*, for object *o*. Returns ``-1`` on failure. - This is the equivalent of the Python statement ``del o.attr_name``. - - -.. cfunction:: int PyObject_DelAttrString(PyObject *o, const char *attr_name) - - Delete attribute named *attr_name*, for object *o*. Returns ``-1`` on failure. - This is the equivalent of the Python statement ``del o.attr_name``. - - -.. cfunction:: PyObject* PyObject_RichCompare(PyObject *o1, PyObject *o2, int opid) - - Compare the values of *o1* and *o2* using the operation specified by *opid*, - which must be one of :const:`Py_LT`, :const:`Py_LE`, :const:`Py_EQ`, - :const:`Py_NE`, :const:`Py_GT`, or :const:`Py_GE`, corresponding to ``<``, - ``<=``, ``==``, ``!=``, ``>``, or ``>=`` respectively. This is the equivalent of - the Python expression ``o1 op o2``, where ``op`` is the operator corresponding - to *opid*. Returns the value of the comparison on success, or *NULL* on failure. - - -.. cfunction:: int PyObject_RichCompareBool(PyObject *o1, PyObject *o2, int opid) - - Compare the values of *o1* and *o2* using the operation specified by *opid*, - which must be one of :const:`Py_LT`, :const:`Py_LE`, :const:`Py_EQ`, - :const:`Py_NE`, :const:`Py_GT`, or :const:`Py_GE`, corresponding to ``<``, - ``<=``, ``==``, ``!=``, ``>``, or ``>=`` respectively. Returns ``-1`` on error, - ``0`` if the result is false, ``1`` otherwise. This is the equivalent of the - Python expression ``o1 op o2``, where ``op`` is the operator corresponding to - *opid*. - - -.. cfunction:: int PyObject_Cmp(PyObject *o1, PyObject *o2, int *result) - - .. index:: builtin: cmp - - Compare the values of *o1* and *o2* using a routine provided by *o1*, if one - exists, otherwise with a routine provided by *o2*. The result of the comparison - is returned in *result*. Returns ``-1`` on failure. This is the equivalent of - the Python statement ``result = cmp(o1, o2)``. - - -.. cfunction:: int PyObject_Compare(PyObject *o1, PyObject *o2) - - .. index:: builtin: cmp - - Compare the values of *o1* and *o2* using a routine provided by *o1*, if one - exists, otherwise with a routine provided by *o2*. Returns the result of the - comparison on success. On error, the value returned is undefined; use - :cfunc:`PyErr_Occurred` to detect an error. This is equivalent to the Python - expression ``cmp(o1, o2)``. - - -.. cfunction:: PyObject* PyObject_Repr(PyObject *o) - - .. index:: builtin: repr - - Compute a string representation of object *o*. Returns the string - representation on success, *NULL* on failure. This is the equivalent of the - Python expression ``repr(o)``. Called by the :func:`repr` built-in function and - by reverse quotes. - - -.. cfunction:: PyObject* PyObject_Str(PyObject *o) - - .. index:: builtin: str - - Compute a string representation of object *o*. Returns the string - representation on success, *NULL* on failure. This is the equivalent of the - Python expression ``str(o)``. Called by the :func:`str` built-in function and - by the :keyword:`print` statement. - - -.. cfunction:: PyObject* PyObject_Unicode(PyObject *o) - - .. index:: builtin: unicode - - Compute a Unicode string representation of object *o*. Returns the Unicode - string representation on success, *NULL* on failure. This is the equivalent of - the Python expression ``unicode(o)``. Called by the :func:`unicode` built-in - function. - - -.. cfunction:: int PyObject_IsInstance(PyObject *inst, PyObject *cls) - - Returns ``1`` if *inst* is an instance of the class *cls* or a subclass of - *cls*, or ``0`` if not. On error, returns ``-1`` and sets an exception. If - *cls* is a type object rather than a class object, :cfunc:`PyObject_IsInstance` - returns ``1`` if *inst* is of type *cls*. If *cls* is a tuple, the check will - be done against every entry in *cls*. The result will be ``1`` when at least one - of the checks returns ``1``, otherwise it will be ``0``. If *inst* is not a - class instance and *cls* is neither a type object, nor a class object, nor a - tuple, *inst* must have a :attr:`__class__` attribute --- the class relationship - of the value of that attribute with *cls* will be used to determine the result - of this function. - - .. versionadded:: 2.1 - - .. versionchanged:: 2.2 - Support for a tuple as the second argument added. - -Subclass determination is done in a fairly straightforward way, but includes a -wrinkle that implementors of extensions to the class system may want to be aware -of. If :class:`A` and :class:`B` are class objects, :class:`B` is a subclass of -:class:`A` if it inherits from :class:`A` either directly or indirectly. If -either is not a class object, a more general mechanism is used to determine the -class relationship of the two objects. When testing if *B* is a subclass of -*A*, if *A* is *B*, :cfunc:`PyObject_IsSubclass` returns true. If *A* and *B* -are different objects, *B*'s :attr:`__bases__` attribute is searched in a -depth-first fashion for *A* --- the presence of the :attr:`__bases__` attribute -is considered sufficient for this determination. - - -.. cfunction:: int PyObject_IsSubclass(PyObject *derived, PyObject *cls) - - Returns ``1`` if the class *derived* is identical to or derived from the class - *cls*, otherwise returns ``0``. In case of an error, returns ``-1``. If *cls* - is a tuple, the check will be done against every entry in *cls*. The result will - be ``1`` when at least one of the checks returns ``1``, otherwise it will be - ``0``. If either *derived* or *cls* is not an actual class object (or tuple), - this function uses the generic algorithm described above. - - .. versionadded:: 2.1 - - .. versionchanged:: 2.3 - Older versions of Python did not support a tuple as the second argument. - - -.. cfunction:: int PyCallable_Check(PyObject *o) - - Determine if the object *o* is callable. Return ``1`` if the object is callable - and ``0`` otherwise. This function always succeeds. - - -.. cfunction:: PyObject* PyObject_Call(PyObject *callable_object, PyObject *args, PyObject *kw) - - .. index:: builtin: apply - - Call a callable Python object *callable_object*, with arguments given by the - tuple *args*, and named arguments given by the dictionary *kw*. If no named - arguments are needed, *kw* may be *NULL*. *args* must not be *NULL*, use an - empty tuple if no arguments are needed. Returns the result of the call on - success, or *NULL* on failure. This is the equivalent of the Python expression - ``apply(callable_object, args, kw)`` or ``callable_object(*args, **kw)``. - - .. versionadded:: 2.2 - - -.. cfunction:: PyObject* PyObject_CallObject(PyObject *callable_object, PyObject *args) - - .. index:: builtin: apply - - Call a callable Python object *callable_object*, with arguments given by the - tuple *args*. If no arguments are needed, then *args* may be *NULL*. Returns - the result of the call on success, or *NULL* on failure. This is the equivalent - of the Python expression ``apply(callable_object, args)`` or - ``callable_object(*args)``. - - -.. cfunction:: PyObject* PyObject_CallFunction(PyObject *callable, char *format, ...) - - .. index:: builtin: apply - - Call a callable Python object *callable*, with a variable number of C arguments. - The C arguments are described using a :cfunc:`Py_BuildValue` style format - string. The format may be *NULL*, indicating that no arguments are provided. - Returns the result of the call on success, or *NULL* on failure. This is the - equivalent of the Python expression ``apply(callable, args)`` or - ``callable(*args)``. Note that if you only pass :ctype:`PyObject \*` args, - :cfunc:`PyObject_CallFunctionObjArgs` is a faster alternative. - - -.. cfunction:: PyObject* PyObject_CallMethod(PyObject *o, char *method, char *format, ...) - - Call the method named *method* of object *o* with a variable number of C - arguments. The C arguments are described by a :cfunc:`Py_BuildValue` format - string that should produce a tuple. The format may be *NULL*, indicating that - no arguments are provided. Returns the result of the call on success, or *NULL* - on failure. This is the equivalent of the Python expression ``o.method(args)``. - Note that if you only pass :ctype:`PyObject \*` args, - :cfunc:`PyObject_CallMethodObjArgs` is a faster alternative. - - -.. cfunction:: PyObject* PyObject_CallFunctionObjArgs(PyObject *callable, ..., NULL) - - Call a callable Python object *callable*, with a variable number of - :ctype:`PyObject\*` arguments. The arguments are provided as a variable number - of parameters followed by *NULL*. Returns the result of the call on success, or - *NULL* on failure. - - .. versionadded:: 2.2 - - -.. cfunction:: PyObject* PyObject_CallMethodObjArgs(PyObject *o, PyObject *name, ..., NULL) - - Calls a method of the object *o*, where the name of the method is given as a - Python string object in *name*. It is called with a variable number of - :ctype:`PyObject\*` arguments. The arguments are provided as a variable number - of parameters followed by *NULL*. Returns the result of the call on success, or - *NULL* on failure. - - .. versionadded:: 2.2 - - -.. cfunction:: long PyObject_Hash(PyObject *o) - - .. index:: builtin: hash - - Compute and return the hash value of an object *o*. On failure, return ``-1``. - This is the equivalent of the Python expression ``hash(o)``. - - -.. cfunction:: int PyObject_IsTrue(PyObject *o) - - Returns ``1`` if the object *o* is considered to be true, and ``0`` otherwise. - This is equivalent to the Python expression ``not not o``. On failure, return - ``-1``. - - -.. cfunction:: int PyObject_Not(PyObject *o) - - Returns ``0`` if the object *o* is considered to be true, and ``1`` otherwise. - This is equivalent to the Python expression ``not o``. On failure, return - ``-1``. - - -.. cfunction:: PyObject* PyObject_Type(PyObject *o) - - .. index:: builtin: type - - When *o* is non-*NULL*, returns a type object corresponding to the object type - of object *o*. On failure, raises :exc:`SystemError` and returns *NULL*. This - is equivalent to the Python expression ``type(o)``. This function increments the - reference count of the return value. There's really no reason to use this - function instead of the common expression ``o->ob_type``, which returns a - pointer of type :ctype:`PyTypeObject\*`, except when the incremented reference - count is needed. - - -.. cfunction:: int PyObject_TypeCheck(PyObject *o, PyTypeObject *type) - - Return true if the object *o* is of type *type* or a subtype of *type*. Both - parameters must be non-*NULL*. - - .. versionadded:: 2.2 - - -.. cfunction:: Py_ssize_t PyObject_Length(PyObject *o) - Py_ssize_t PyObject_Size(PyObject *o) - - .. index:: builtin: len - - Return the length of object *o*. If the object *o* provides either the sequence - and mapping protocols, the sequence length is returned. On error, ``-1`` is - returned. This is the equivalent to the Python expression ``len(o)``. - - -.. cfunction:: PyObject* PyObject_GetItem(PyObject *o, PyObject *key) - - Return element of *o* corresponding to the object *key* or *NULL* on failure. - This is the equivalent of the Python expression ``o[key]``. - - -.. cfunction:: int PyObject_SetItem(PyObject *o, PyObject *key, PyObject *v) - - Map the object *key* to the value *v*. Returns ``-1`` on failure. This is the - equivalent of the Python statement ``o[key] = v``. - - -.. cfunction:: int PyObject_DelItem(PyObject *o, PyObject *key) - - Delete the mapping for *key* from *o*. Returns ``-1`` on failure. This is the - equivalent of the Python statement ``del o[key]``. - - -.. cfunction:: int PyObject_AsFileDescriptor(PyObject *o) - - Derives a file descriptor from a Python object. If the object is an integer or - long integer, its value is returned. If not, the object's :meth:`fileno` method - is called if it exists; the method must return an integer or long integer, which - is returned as the file descriptor value. Returns ``-1`` on failure. - - -.. cfunction:: PyObject* PyObject_Dir(PyObject *o) - - This is equivalent to the Python expression ``dir(o)``, returning a (possibly - empty) list of strings appropriate for the object argument, or *NULL* if there - was an error. If the argument is *NULL*, this is like the Python ``dir()``, - returning the names of the current locals; in this case, if no execution frame - is active then *NULL* is returned but :cfunc:`PyErr_Occurred` will return false. - - -.. cfunction:: PyObject* PyObject_GetIter(PyObject *o) - - This is equivalent to the Python expression ``iter(o)``. It returns a new - iterator for the object argument, or the object itself if the object is already - an iterator. Raises :exc:`TypeError` and returns *NULL* if the object cannot be - iterated. - - -.. _number: - -Number Protocol -=============== - - -.. cfunction:: int PyNumber_Check(PyObject *o) - - Returns ``1`` if the object *o* provides numeric protocols, and false otherwise. - This function always succeeds. - - -.. cfunction:: PyObject* PyNumber_Add(PyObject *o1, PyObject *o2) - - Returns the result of adding *o1* and *o2*, or *NULL* on failure. This is the - equivalent of the Python expression ``o1 + o2``. - - -.. cfunction:: PyObject* PyNumber_Subtract(PyObject *o1, PyObject *o2) - - Returns the result of subtracting *o2* from *o1*, or *NULL* on failure. This is - the equivalent of the Python expression ``o1 - o2``. - - -.. cfunction:: PyObject* PyNumber_Multiply(PyObject *o1, PyObject *o2) - - Returns the result of multiplying *o1* and *o2*, or *NULL* on failure. This is - the equivalent of the Python expression ``o1 * o2``. - - -.. cfunction:: PyObject* PyNumber_Divide(PyObject *o1, PyObject *o2) - - Returns the result of dividing *o1* by *o2*, or *NULL* on failure. This is the - equivalent of the Python expression ``o1 / o2``. - - -.. cfunction:: PyObject* PyNumber_FloorDivide(PyObject *o1, PyObject *o2) - - Return the floor of *o1* divided by *o2*, or *NULL* on failure. This is - equivalent to the "classic" division of integers. - - .. versionadded:: 2.2 - - -.. cfunction:: PyObject* PyNumber_TrueDivide(PyObject *o1, PyObject *o2) - - Return a reasonable approximation for the mathematical value of *o1* divided by - *o2*, or *NULL* on failure. The return value is "approximate" because binary - floating point numbers are approximate; it is not possible to represent all real - numbers in base two. This function can return a floating point value when - passed two integers. - - .. versionadded:: 2.2 - - -.. cfunction:: PyObject* PyNumber_Remainder(PyObject *o1, PyObject *o2) - - Returns the remainder of dividing *o1* by *o2*, or *NULL* on failure. This is - the equivalent of the Python expression ``o1 % o2``. - - -.. cfunction:: PyObject* PyNumber_Divmod(PyObject *o1, PyObject *o2) - - .. index:: builtin: divmod - - See the built-in function :func:`divmod`. Returns *NULL* on failure. This is - the equivalent of the Python expression ``divmod(o1, o2)``. - - -.. cfunction:: PyObject* PyNumber_Power(PyObject *o1, PyObject *o2, PyObject *o3) - - .. index:: builtin: pow - - See the built-in function :func:`pow`. Returns *NULL* on failure. This is the - equivalent of the Python expression ``pow(o1, o2, o3)``, where *o3* is optional. - If *o3* is to be ignored, pass :cdata:`Py_None` in its place (passing *NULL* for - *o3* would cause an illegal memory access). - - -.. cfunction:: PyObject* PyNumber_Negative(PyObject *o) - - Returns the negation of *o* on success, or *NULL* on failure. This is the - equivalent of the Python expression ``-o``. - - -.. cfunction:: PyObject* PyNumber_Positive(PyObject *o) - - Returns *o* on success, or *NULL* on failure. This is the equivalent of the - Python expression ``+o``. - - -.. cfunction:: PyObject* PyNumber_Absolute(PyObject *o) - - .. index:: builtin: abs - - Returns the absolute value of *o*, or *NULL* on failure. This is the equivalent - of the Python expression ``abs(o)``. - - -.. cfunction:: PyObject* PyNumber_Invert(PyObject *o) - - Returns the bitwise negation of *o* on success, or *NULL* on failure. This is - the equivalent of the Python expression ``~o``. - - -.. cfunction:: PyObject* PyNumber_Lshift(PyObject *o1, PyObject *o2) - - Returns the result of left shifting *o1* by *o2* on success, or *NULL* on - failure. This is the equivalent of the Python expression ``o1 << o2``. - - -.. cfunction:: PyObject* PyNumber_Rshift(PyObject *o1, PyObject *o2) - - Returns the result of right shifting *o1* by *o2* on success, or *NULL* on - failure. This is the equivalent of the Python expression ``o1 >> o2``. - - -.. cfunction:: PyObject* PyNumber_And(PyObject *o1, PyObject *o2) - - Returns the "bitwise and" of *o1* and *o2* on success and *NULL* on failure. - This is the equivalent of the Python expression ``o1 & o2``. - - -.. cfunction:: PyObject* PyNumber_Xor(PyObject *o1, PyObject *o2) - - Returns the "bitwise exclusive or" of *o1* by *o2* on success, or *NULL* on - failure. This is the equivalent of the Python expression ``o1 ^ o2``. - - -.. cfunction:: PyObject* PyNumber_Or(PyObject *o1, PyObject *o2) - - Returns the "bitwise or" of *o1* and *o2* on success, or *NULL* on failure. - This is the equivalent of the Python expression ``o1 | o2``. - - -.. cfunction:: PyObject* PyNumber_InPlaceAdd(PyObject *o1, PyObject *o2) - - Returns the result of adding *o1* and *o2*, or *NULL* on failure. The operation - is done *in-place* when *o1* supports it. This is the equivalent of the Python - statement ``o1 += o2``. - - -.. cfunction:: PyObject* PyNumber_InPlaceSubtract(PyObject *o1, PyObject *o2) - - Returns the result of subtracting *o2* from *o1*, or *NULL* on failure. The - operation is done *in-place* when *o1* supports it. This is the equivalent of - the Python statement ``o1 -= o2``. - - -.. cfunction:: PyObject* PyNumber_InPlaceMultiply(PyObject *o1, PyObject *o2) - - Returns the result of multiplying *o1* and *o2*, or *NULL* on failure. The - operation is done *in-place* when *o1* supports it. This is the equivalent of - the Python statement ``o1 *= o2``. - - -.. cfunction:: PyObject* PyNumber_InPlaceDivide(PyObject *o1, PyObject *o2) - - Returns the result of dividing *o1* by *o2*, or *NULL* on failure. The - operation is done *in-place* when *o1* supports it. This is the equivalent of - the Python statement ``o1 /= o2``. - - -.. cfunction:: PyObject* PyNumber_InPlaceFloorDivide(PyObject *o1, PyObject *o2) - - Returns the mathematical floor of dividing *o1* by *o2*, or *NULL* on failure. - The operation is done *in-place* when *o1* supports it. This is the equivalent - of the Python statement ``o1 //= o2``. - - .. versionadded:: 2.2 - - -.. cfunction:: PyObject* PyNumber_InPlaceTrueDivide(PyObject *o1, PyObject *o2) - - Return a reasonable approximation for the mathematical value of *o1* divided by - *o2*, or *NULL* on failure. The return value is "approximate" because binary - floating point numbers are approximate; it is not possible to represent all real - numbers in base two. This function can return a floating point value when - passed two integers. The operation is done *in-place* when *o1* supports it. - - .. versionadded:: 2.2 - - -.. cfunction:: PyObject* PyNumber_InPlaceRemainder(PyObject *o1, PyObject *o2) - - Returns the remainder of dividing *o1* by *o2*, or *NULL* on failure. The - operation is done *in-place* when *o1* supports it. This is the equivalent of - the Python statement ``o1 %= o2``. - - -.. cfunction:: PyObject* PyNumber_InPlacePower(PyObject *o1, PyObject *o2, PyObject *o3) - - .. index:: builtin: pow - - See the built-in function :func:`pow`. Returns *NULL* on failure. The operation - is done *in-place* when *o1* supports it. This is the equivalent of the Python - statement ``o1 **= o2`` when o3 is :cdata:`Py_None`, or an in-place variant of - ``pow(o1, o2, o3)`` otherwise. If *o3* is to be ignored, pass :cdata:`Py_None` - in its place (passing *NULL* for *o3* would cause an illegal memory access). - - -.. cfunction:: PyObject* PyNumber_InPlaceLshift(PyObject *o1, PyObject *o2) - - Returns the result of left shifting *o1* by *o2* on success, or *NULL* on - failure. The operation is done *in-place* when *o1* supports it. This is the - equivalent of the Python statement ``o1 <<= o2``. - - -.. cfunction:: PyObject* PyNumber_InPlaceRshift(PyObject *o1, PyObject *o2) - - Returns the result of right shifting *o1* by *o2* on success, or *NULL* on - failure. The operation is done *in-place* when *o1* supports it. This is the - equivalent of the Python statement ``o1 >>= o2``. - - -.. cfunction:: PyObject* PyNumber_InPlaceAnd(PyObject *o1, PyObject *o2) - - Returns the "bitwise and" of *o1* and *o2* on success and *NULL* on failure. The - operation is done *in-place* when *o1* supports it. This is the equivalent of - the Python statement ``o1 &= o2``. - - -.. cfunction:: PyObject* PyNumber_InPlaceXor(PyObject *o1, PyObject *o2) - - Returns the "bitwise exclusive or" of *o1* by *o2* on success, or *NULL* on - failure. The operation is done *in-place* when *o1* supports it. This is the - equivalent of the Python statement ``o1 ^= o2``. - - -.. cfunction:: PyObject* PyNumber_InPlaceOr(PyObject *o1, PyObject *o2) - - Returns the "bitwise or" of *o1* and *o2* on success, or *NULL* on failure. The - operation is done *in-place* when *o1* supports it. This is the equivalent of - the Python statement ``o1 |= o2``. - - -.. cfunction:: int PyNumber_Coerce(PyObject **p1, PyObject **p2) - - .. index:: builtin: coerce - - This function takes the addresses of two variables of type :ctype:`PyObject\*`. - If the objects pointed to by ``*p1`` and ``*p2`` have the same type, increment - their reference count and return ``0`` (success). If the objects can be - converted to a common numeric type, replace ``*p1`` and ``*p2`` by their - converted value (with 'new' reference counts), and return ``0``. If no - conversion is possible, or if some other error occurs, return ``-1`` (failure) - and don't increment the reference counts. The call ``PyNumber_Coerce(&o1, - &o2)`` is equivalent to the Python statement ``o1, o2 = coerce(o1, o2)``. - - -.. cfunction:: int PyNumber_CoerceEx(PyObject **p1, PyObject **p2) - - This function is similar to :cfunc:`PyNumber_Coerce`, except that it returns - ``1`` when the conversion is not possible and when no error is raised. - Reference counts are still not increased in this case. - - -.. cfunction:: PyObject* PyNumber_Int(PyObject *o) - - .. index:: builtin: int - - Returns the *o* converted to an integer object on success, or *NULL* on failure. - If the argument is outside the integer range a long object will be returned - instead. This is the equivalent of the Python expression ``int(o)``. - - -.. cfunction:: PyObject* PyNumber_Long(PyObject *o) - - .. index:: builtin: long - - Returns the *o* converted to a long integer object on success, or *NULL* on - failure. This is the equivalent of the Python expression ``long(o)``. - - -.. cfunction:: PyObject* PyNumber_Float(PyObject *o) - - .. index:: builtin: float - - Returns the *o* converted to a float object on success, or *NULL* on failure. - This is the equivalent of the Python expression ``float(o)``. - - -.. cfunction:: PyObject* PyNumber_Index(PyObject *o) - - Returns the *o* converted to a Python int or long on success or *NULL* with a - TypeError exception raised on failure. - - .. versionadded:: 2.5 - - -.. cfunction:: Py_ssize_t PyNumber_AsSsize_t(PyObject *o, PyObject *exc) - - Returns *o* converted to a Py_ssize_t value if *o* can be interpreted as an - integer. If *o* can be converted to a Python int or long but the attempt to - convert to a Py_ssize_t value would raise an :exc:`OverflowError`, then the - *exc* argument is the type of exception that will be raised (usually - :exc:`IndexError` or :exc:`OverflowError`). If *exc* is *NULL*, then the - exception is cleared and the value is clipped to *PY_SSIZE_T_MIN* for a negative - integer or *PY_SSIZE_T_MAX* for a positive integer. - - .. versionadded:: 2.5 - - -.. cfunction:: int PyIndex_Check(PyObject *o) - - Returns True if *o* is an index integer (has the nb_index slot of the - tp_as_number structure filled in). - - .. versionadded:: 2.5 - - -.. _sequence: - -Sequence Protocol -================= - - -.. cfunction:: int PySequence_Check(PyObject *o) - - Return ``1`` if the object provides sequence protocol, and ``0`` otherwise. - This function always succeeds. - - -.. cfunction:: Py_ssize_t PySequence_Size(PyObject *o) - - .. index:: builtin: len - - Returns the number of objects in sequence *o* on success, and ``-1`` on failure. - For objects that do not provide sequence protocol, this is equivalent to the - Python expression ``len(o)``. - - -.. cfunction:: Py_ssize_t PySequence_Length(PyObject *o) - - Alternate name for :cfunc:`PySequence_Size`. - - -.. cfunction:: PyObject* PySequence_Concat(PyObject *o1, PyObject *o2) - - Return the concatenation of *o1* and *o2* on success, and *NULL* on failure. - This is the equivalent of the Python expression ``o1 + o2``. - - -.. cfunction:: PyObject* PySequence_Repeat(PyObject *o, Py_ssize_t count) - - Return the result of repeating sequence object *o* *count* times, or *NULL* on - failure. This is the equivalent of the Python expression ``o * count``. - - -.. cfunction:: PyObject* PySequence_InPlaceConcat(PyObject *o1, PyObject *o2) - - Return the concatenation of *o1* and *o2* on success, and *NULL* on failure. - The operation is done *in-place* when *o1* supports it. This is the equivalent - of the Python expression ``o1 += o2``. - - -.. cfunction:: PyObject* PySequence_InPlaceRepeat(PyObject *o, Py_ssize_t count) - - Return the result of repeating sequence object *o* *count* times, or *NULL* on - failure. The operation is done *in-place* when *o* supports it. This is the - equivalent of the Python expression ``o *= count``. - - -.. cfunction:: PyObject* PySequence_GetItem(PyObject *o, Py_ssize_t i) - - Return the *i*th element of *o*, or *NULL* on failure. This is the equivalent of - the Python expression ``o[i]``. - - -.. cfunction:: PyObject* PySequence_GetSlice(PyObject *o, Py_ssize_t i1, Py_ssize_t i2) - - Return the slice of sequence object *o* between *i1* and *i2*, or *NULL* on - failure. This is the equivalent of the Python expression ``o[i1:i2]``. - - -.. cfunction:: int PySequence_SetItem(PyObject *o, Py_ssize_t i, PyObject *v) - - Assign object *v* to the *i*th element of *o*. Returns ``-1`` on failure. This - is the equivalent of the Python statement ``o[i] = v``. This function *does - not* steal a reference to *v*. - - -.. cfunction:: int PySequence_DelItem(PyObject *o, Py_ssize_t i) - - Delete the *i*th element of object *o*. Returns ``-1`` on failure. This is the - equivalent of the Python statement ``del o[i]``. - - -.. cfunction:: int PySequence_SetSlice(PyObject *o, Py_ssize_t i1, Py_ssize_t i2, PyObject *v) - - Assign the sequence object *v* to the slice in sequence object *o* from *i1* to - *i2*. This is the equivalent of the Python statement ``o[i1:i2] = v``. - - -.. cfunction:: int PySequence_DelSlice(PyObject *o, Py_ssize_t i1, Py_ssize_t i2) - - Delete the slice in sequence object *o* from *i1* to *i2*. Returns ``-1`` on - failure. This is the equivalent of the Python statement ``del o[i1:i2]``. - - -.. cfunction:: Py_ssize_t PySequence_Count(PyObject *o, PyObject *value) - - Return the number of occurrences of *value* in *o*, that is, return the number - of keys for which ``o[key] == value``. On failure, return ``-1``. This is - equivalent to the Python expression ``o.count(value)``. - - -.. cfunction:: int PySequence_Contains(PyObject *o, PyObject *value) - - Determine if *o* contains *value*. If an item in *o* is equal to *value*, - return ``1``, otherwise return ``0``. On error, return ``-1``. This is - equivalent to the Python expression ``value in o``. - - -.. cfunction:: Py_ssize_t PySequence_Index(PyObject *o, PyObject *value) - - Return the first index *i* for which ``o[i] == value``. On error, return - ``-1``. This is equivalent to the Python expression ``o.index(value)``. - - -.. cfunction:: PyObject* PySequence_List(PyObject *o) - - Return a list object with the same contents as the arbitrary sequence *o*. The - returned list is guaranteed to be new. - - -.. cfunction:: PyObject* PySequence_Tuple(PyObject *o) - - .. index:: builtin: tuple - - Return a tuple object with the same contents as the arbitrary sequence *o* or - *NULL* on failure. If *o* is a tuple, a new reference will be returned, - otherwise a tuple will be constructed with the appropriate contents. This is - equivalent to the Python expression ``tuple(o)``. - - -.. cfunction:: PyObject* PySequence_Fast(PyObject *o, const char *m) - - Returns the sequence *o* as a tuple, unless it is already a tuple or list, in - which case *o* is returned. Use :cfunc:`PySequence_Fast_GET_ITEM` to access the - members of the result. Returns *NULL* on failure. If the object is not a - sequence, raises :exc:`TypeError` with *m* as the message text. - - -.. cfunction:: PyObject* PySequence_Fast_GET_ITEM(PyObject *o, Py_ssize_t i) - - Return the *i*th element of *o*, assuming that *o* was returned by - :cfunc:`PySequence_Fast`, *o* is not *NULL*, and that *i* is within bounds. - - -.. cfunction:: PyObject** PySequence_Fast_ITEMS(PyObject *o) - - Return the underlying array of PyObject pointers. Assumes that *o* was returned - by :cfunc:`PySequence_Fast` and *o* is not *NULL*. - - .. versionadded:: 2.4 - - -.. cfunction:: PyObject* PySequence_ITEM(PyObject *o, Py_ssize_t i) - - Return the *i*th element of *o* or *NULL* on failure. Macro form of - :cfunc:`PySequence_GetItem` but without checking that - :cfunc:`PySequence_Check(o)` is true and without adjustment for negative - indices. - - .. versionadded:: 2.3 - - -.. cfunction:: Py_ssize_t PySequence_Fast_GET_SIZE(PyObject *o) - - Returns the length of *o*, assuming that *o* was returned by - :cfunc:`PySequence_Fast` and that *o* is not *NULL*. The size can also be - gotten by calling :cfunc:`PySequence_Size` on *o*, but - :cfunc:`PySequence_Fast_GET_SIZE` is faster because it can assume *o* is a list - or tuple. - - -.. _mapping: - -Mapping Protocol -================ - - -.. cfunction:: int PyMapping_Check(PyObject *o) - - Return ``1`` if the object provides mapping protocol, and ``0`` otherwise. This - function always succeeds. - - -.. cfunction:: Py_ssize_t PyMapping_Length(PyObject *o) - - .. index:: builtin: len - - Returns the number of keys in object *o* on success, and ``-1`` on failure. For - objects that do not provide mapping protocol, this is equivalent to the Python - expression ``len(o)``. - - -.. cfunction:: int PyMapping_DelItemString(PyObject *o, char *key) - - Remove the mapping for object *key* from the object *o*. Return ``-1`` on - failure. This is equivalent to the Python statement ``del o[key]``. - - -.. cfunction:: int PyMapping_DelItem(PyObject *o, PyObject *key) - - Remove the mapping for object *key* from the object *o*. Return ``-1`` on - failure. This is equivalent to the Python statement ``del o[key]``. - - -.. cfunction:: int PyMapping_HasKeyString(PyObject *o, char *key) - - On success, return ``1`` if the mapping object has the key *key* and ``0`` - otherwise. This is equivalent to the Python expression ``o.has_key(key)``. - This function always succeeds. - - -.. cfunction:: int PyMapping_HasKey(PyObject *o, PyObject *key) - - Return ``1`` if the mapping object has the key *key* and ``0`` otherwise. This - is equivalent to the Python expression ``o.has_key(key)``. This function always - succeeds. - - -.. cfunction:: PyObject* PyMapping_Keys(PyObject *o) - - On success, return a list of the keys in object *o*. On failure, return *NULL*. - This is equivalent to the Python expression ``o.keys()``. - - -.. cfunction:: PyObject* PyMapping_Values(PyObject *o) - - On success, return a list of the values in object *o*. On failure, return - *NULL*. This is equivalent to the Python expression ``o.values()``. - - -.. cfunction:: PyObject* PyMapping_Items(PyObject *o) - - On success, return a list of the items in object *o*, where each item is a tuple - containing a key-value pair. On failure, return *NULL*. This is equivalent to - the Python expression ``o.items()``. - - -.. cfunction:: PyObject* PyMapping_GetItemString(PyObject *o, char *key) - - Return element of *o* corresponding to the object *key* or *NULL* on failure. - This is the equivalent of the Python expression ``o[key]``. - - -.. cfunction:: int PyMapping_SetItemString(PyObject *o, char *key, PyObject *v) - - Map the object *key* to the value *v* in object *o*. Returns ``-1`` on failure. - This is the equivalent of the Python statement ``o[key] = v``. - - -.. _iterator: - -Iterator Protocol -================= - -.. versionadded:: 2.2 - -There are only a couple of functions specifically for working with iterators. - - -.. cfunction:: int PyIter_Check(PyObject *o) - - Return true if the object *o* supports the iterator protocol. - - -.. cfunction:: PyObject* PyIter_Next(PyObject *o) - - Return the next value from the iteration *o*. If the object is an iterator, - this retrieves the next value from the iteration, and returns *NULL* with no - exception set if there are no remaining items. If the object is not an - iterator, :exc:`TypeError` is raised, or if there is an error in retrieving the - item, returns *NULL* and passes along the exception. - -To write a loop which iterates over an iterator, the C code should look -something like this:: - - PyObject *iterator = PyObject_GetIter(obj); - PyObject *item; - - if (iterator == NULL) { - /* propagate error */ - } - - while (item = PyIter_Next(iterator)) { - /* do something with item */ - ... - /* release reference when done */ - Py_DECREF(item); - } - - Py_DECREF(iterator); - - if (PyErr_Occurred()) { - /* propagate error */ - } - else { - /* continue doing useful work */ - } - - -.. _abstract-buffer: - -Buffer Protocol -=============== - - -.. cfunction:: int PyObject_AsCharBuffer(PyObject *obj, const char **buffer, Py_ssize_t *buffer_len) - - Returns a pointer to a read-only memory location useable as character- based - input. The *obj* argument must support the single-segment character buffer - interface. On success, returns ``0``, sets *buffer* to the memory location and - *buffer_len* to the buffer length. Returns ``-1`` and sets a :exc:`TypeError` - on error. - - .. versionadded:: 1.6 - - -.. cfunction:: int PyObject_AsReadBuffer(PyObject *obj, const void **buffer, Py_ssize_t *buffer_len) - - Returns a pointer to a read-only memory location containing arbitrary data. The - *obj* argument must support the single-segment readable buffer interface. On - success, returns ``0``, sets *buffer* to the memory location and *buffer_len* to - the buffer length. Returns ``-1`` and sets a :exc:`TypeError` on error. - - .. versionadded:: 1.6 - - -.. cfunction:: int PyObject_CheckReadBuffer(PyObject *o) - - Returns ``1`` if *o* supports the single-segment readable buffer interface. - Otherwise returns ``0``. - - .. versionadded:: 2.2 - - -.. cfunction:: int PyObject_AsWriteBuffer(PyObject *obj, void **buffer, Py_ssize_t *buffer_len) - - Returns a pointer to a writeable memory location. The *obj* argument must - support the single-segment, character buffer interface. On success, returns - ``0``, sets *buffer* to the memory location and *buffer_len* to the buffer - length. Returns ``-1`` and sets a :exc:`TypeError` on error. - - .. versionadded:: 1.6 - + object.rst + number.rst + sequence.rst + mapping.rst + iter.rst + objbuffer.rst Added: python/trunk/Doc/c-api/allocation.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/c-api/allocation.rst Sat Jan 19 23:08:21 2008 @@ -0,0 +1,104 @@ +.. highlightlang:: c + +.. _allocating-objects: + +Allocating Objects on the Heap +============================== + + +.. cfunction:: PyObject* _PyObject_New(PyTypeObject *type) + + +.. cfunction:: PyVarObject* _PyObject_NewVar(PyTypeObject *type, Py_ssize_t size) + + +.. cfunction:: void _PyObject_Del(PyObject *op) + + +.. cfunction:: PyObject* PyObject_Init(PyObject *op, PyTypeObject *type) + + Initialize a newly-allocated object *op* with its type and initial reference. + Returns the initialized object. If *type* indicates that the object + participates in the cyclic garbage detector, it is added to the detector's set + of observed objects. Other fields of the object are not affected. + + +.. cfunction:: PyVarObject* PyObject_InitVar(PyVarObject *op, PyTypeObject *type, Py_ssize_t size) + + This does everything :cfunc:`PyObject_Init` does, and also initializes the + length information for a variable-size object. + + +.. cfunction:: TYPE* PyObject_New(TYPE, PyTypeObject *type) + + Allocate a new Python object using the C structure type *TYPE* and the Python + type object *type*. Fields not defined by the Python object header are not + initialized; the object's reference count will be one. The size of the memory + allocation is determined from the :attr:`tp_basicsize` field of the type object. + + +.. cfunction:: TYPE* PyObject_NewVar(TYPE, PyTypeObject *type, Py_ssize_t size) + + Allocate a new Python object using the C structure type *TYPE* and the Python + type object *type*. Fields not defined by the Python object header are not + initialized. The allocated memory allows for the *TYPE* structure plus *size* + fields of the size given by the :attr:`tp_itemsize` field of *type*. This is + useful for implementing objects like tuples, which are able to determine their + size at construction time. Embedding the array of fields into the same + allocation decreases the number of allocations, improving the memory management + efficiency. + + +.. cfunction:: void PyObject_Del(PyObject *op) + + Releases memory allocated to an object using :cfunc:`PyObject_New` or + :cfunc:`PyObject_NewVar`. This is normally called from the :attr:`tp_dealloc` + handler specified in the object's type. The fields of the object should not be + accessed after this call as the memory is no longer a valid Python object. + + +.. cfunction:: PyObject* Py_InitModule(char *name, PyMethodDef *methods) + + Create a new module object based on a name and table of functions, returning the + new module object. + + .. versionchanged:: 2.3 + Older versions of Python did not support *NULL* as the value for the *methods* + argument. + + +.. cfunction:: PyObject* Py_InitModule3(char *name, PyMethodDef *methods, char *doc) + + Create a new module object based on a name and table of functions, returning the + new module object. If *doc* is non-*NULL*, it will be used to define the + docstring for the module. + + .. versionchanged:: 2.3 + Older versions of Python did not support *NULL* as the value for the *methods* + argument. + + +.. cfunction:: PyObject* Py_InitModule4(char *name, PyMethodDef *methods, char *doc, PyObject *self, int apiver) + + Create a new module object based on a name and table of functions, returning the + new module object. If *doc* is non-*NULL*, it will be used to define the + docstring for the module. If *self* is non-*NULL*, it will passed to the + functions of the module as their (otherwise *NULL*) first parameter. (This was + added as an experimental feature, and there are no known uses in the current + version of Python.) For *apiver*, the only value which should be passed is + defined by the constant :const:`PYTHON_API_VERSION`. + + .. note:: + + Most uses of this function should probably be using the :cfunc:`Py_InitModule3` + instead; only use this if you are sure you need it. + + .. versionchanged:: 2.3 + Older versions of Python did not support *NULL* as the value for the *methods* + argument. + + +.. cvar:: PyObject _Py_NoneStruct + + Object which is visible in Python as ``None``. This should only be accessed + using the ``Py_None`` macro, which evaluates to a pointer to this object. Added: python/trunk/Doc/c-api/bool.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/c-api/bool.rst Sat Jan 19 23:08:21 2008 @@ -0,0 +1,54 @@ +.. highlightlang:: c + +.. _boolobjects: + +Boolean Objects +--------------- + +Booleans in Python are implemented as a subclass of integers. There are only +two booleans, :const:`Py_False` and :const:`Py_True`. As such, the normal +creation and deletion functions don't apply to booleans. The following macros +are available, however. + + +.. cfunction:: int PyBool_Check(PyObject *o) + + Return true if *o* is of type :cdata:`PyBool_Type`. + + .. versionadded:: 2.3 + + +.. cvar:: PyObject* Py_False + + The Python ``False`` object. This object has no methods. It needs to be + treated just like any other object with respect to reference counts. + + +.. cvar:: PyObject* Py_True + + The Python ``True`` object. This object has no methods. It needs to be treated + just like any other object with respect to reference counts. + + +.. cmacro:: Py_RETURN_FALSE + + Return :const:`Py_False` from a function, properly incrementing its reference + count. + + .. versionadded:: 2.4 + + +.. cmacro:: Py_RETURN_TRUE + + Return :const:`Py_True` from a function, properly incrementing its reference + count. + + .. versionadded:: 2.4 + + +.. cfunction:: PyObject* PyBool_FromLong(long v) + + Return a new reference to :const:`Py_True` or :const:`Py_False` depending on the + truth value of *v*. + + .. versionadded:: 2.3 Added: python/trunk/Doc/c-api/buffer.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/c-api/buffer.rst Sat Jan 19 23:08:21 2008 @@ -0,0 +1,119 @@ +.. highlightlang:: c + +.. _bufferobjects: + +Buffer Objects +-------------- + +.. sectionauthor:: Greg Stein + + +.. index:: + object: buffer + single: buffer interface + +Python objects implemented in C can export a group of functions called the +"buffer interface." These functions can be used by an object to expose its data +in a raw, byte-oriented format. Clients of the object can use the buffer +interface to access the object data directly, without needing to copy it first. + +Two examples of objects that support the buffer interface are strings and +arrays. The string object exposes the character contents in the buffer +interface's byte-oriented form. An array can also expose its contents, but it +should be noted that array elements may be multi-byte values. + +An example user of the buffer interface is the file object's :meth:`write` +method. Any object that can export a series of bytes through the buffer +interface can be written to a file. There are a number of format codes to +:cfunc:`PyArg_ParseTuple` that operate against an object's buffer interface, +returning data from the target object. + +.. index:: single: PyBufferProcs + +More information on the buffer interface is provided in the section +:ref:`buffer-structs`, under the description for :ctype:`PyBufferProcs`. + +A "buffer object" is defined in the :file:`bufferobject.h` header (included by +:file:`Python.h`). These objects look very similar to string objects at the +Python programming level: they support slicing, indexing, concatenation, and +some other standard string operations. However, their data can come from one of +two sources: from a block of memory, or from another object which exports the +buffer interface. + +Buffer objects are useful as a way to expose the data from another object's +buffer interface to the Python programmer. They can also be used as a zero-copy +slicing mechanism. Using their ability to reference a block of memory, it is +possible to expose any data to the Python programmer quite easily. The memory +could be a large, constant array in a C extension, it could be a raw block of +memory for manipulation before passing to an operating system library, or it +could be used to pass around structured data in its native, in-memory format. + + +.. ctype:: PyBufferObject + + This subtype of :ctype:`PyObject` represents a buffer object. + + +.. cvar:: PyTypeObject PyBuffer_Type + + .. index:: single: BufferType (in module types) + + The instance of :ctype:`PyTypeObject` which represents the Python buffer type; + it is the same object as ``buffer`` and ``types.BufferType`` in the Python + layer. . + + +.. cvar:: int Py_END_OF_BUFFER + + This constant may be passed as the *size* parameter to + :cfunc:`PyBuffer_FromObject` or :cfunc:`PyBuffer_FromReadWriteObject`. It + indicates that the new :ctype:`PyBufferObject` should refer to *base* object + from the specified *offset* to the end of its exported buffer. Using this + enables the caller to avoid querying the *base* object for its length. + + +.. cfunction:: int PyBuffer_Check(PyObject *p) + + Return true if the argument has type :cdata:`PyBuffer_Type`. + + +.. cfunction:: PyObject* PyBuffer_FromObject(PyObject *base, Py_ssize_t offset, Py_ssize_t size) + + Return a new read-only buffer object. This raises :exc:`TypeError` if *base* + doesn't support the read-only buffer protocol or doesn't provide exactly one + buffer segment, or it raises :exc:`ValueError` if *offset* is less than zero. + The buffer will hold a reference to the *base* object, and the buffer's contents + will refer to the *base* object's buffer interface, starting as position + *offset* and extending for *size* bytes. If *size* is :const:`Py_END_OF_BUFFER`, + then the new buffer's contents extend to the length of the *base* object's + exported buffer data. + + +.. cfunction:: PyObject* PyBuffer_FromReadWriteObject(PyObject *base, Py_ssize_t offset, Py_ssize_t size) + + Return a new writable buffer object. Parameters and exceptions are similar to + those for :cfunc:`PyBuffer_FromObject`. If the *base* object does not export + the writeable buffer protocol, then :exc:`TypeError` is raised. + + +.. cfunction:: PyObject* PyBuffer_FromMemory(void *ptr, Py_ssize_t size) + + Return a new read-only buffer object that reads from a specified location in + memory, with a specified size. The caller is responsible for ensuring that the + memory buffer, passed in as *ptr*, is not deallocated while the returned buffer + object exists. Raises :exc:`ValueError` if *size* is less than zero. Note that + :const:`Py_END_OF_BUFFER` may *not* be passed for the *size* parameter; + :exc:`ValueError` will be raised in that case. + + +.. cfunction:: PyObject* PyBuffer_FromReadWriteMemory(void *ptr, Py_ssize_t size) + + Similar to :cfunc:`PyBuffer_FromMemory`, but the returned buffer is writable. + + +.. cfunction:: PyObject* PyBuffer_New(Py_ssize_t size) + + Return a new writable buffer object that maintains its own memory buffer of + *size* bytes. :exc:`ValueError` is returned if *size* is not zero or positive. + Note that the memory buffer (as returned by :cfunc:`PyObject_AsWriteBuffer`) is + not specifically aligned. Added: python/trunk/Doc/c-api/cell.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/c-api/cell.rst Sat Jan 19 23:08:21 2008 @@ -0,0 +1,62 @@ +.. highlightlang:: c + +.. _cell-objects: + +Cell Objects +------------ + +"Cell" objects are used to implement variables referenced by multiple scopes. +For each such variable, a cell object is created to store the value; the local +variables of each stack frame that references the value contains a reference to +the cells from outer scopes which also use that variable. When the value is +accessed, the value contained in the cell is used instead of the cell object +itself. This de-referencing of the cell object requires support from the +generated byte-code; these are not automatically de-referenced when accessed. +Cell objects are not likely to be useful elsewhere. + + +.. ctype:: PyCellObject + + The C structure used for cell objects. + + +.. cvar:: PyTypeObject PyCell_Type + + The type object corresponding to cell objects. + + +.. cfunction:: int PyCell_Check(ob) + + Return true if *ob* is a cell object; *ob* must not be *NULL*. + + +.. cfunction:: PyObject* PyCell_New(PyObject *ob) + + Create and return a new cell object containing the value *ob*. The parameter may + be *NULL*. + + +.. cfunction:: PyObject* PyCell_Get(PyObject *cell) + + Return the contents of the cell *cell*. + + +.. cfunction:: PyObject* PyCell_GET(PyObject *cell) + + Return the contents of the cell *cell*, but without checking that *cell* is + non-*NULL* and a cell object. + + +.. cfunction:: int PyCell_Set(PyObject *cell, PyObject *value) + + Set the contents of the cell object *cell* to *value*. This releases the + reference to any current content of the cell. *value* may be *NULL*. *cell* + must be non-*NULL*; if it is not a cell object, ``-1`` will be returned. On + success, ``0`` will be returned. + + +.. cfunction:: void PyCell_SET(PyObject *cell, PyObject *value) + + Sets the value of the cell object *cell* to *value*. No reference counts are + adjusted, and no checks are made for safety; *cell* must be non-*NULL* and must + be a cell object. Added: python/trunk/Doc/c-api/class.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/c-api/class.rst Sat Jan 19 23:08:21 2008 @@ -0,0 +1,65 @@ +.. highlightlang:: c + +.. _classobjects: + +Class and Instance Objects +-------------------------- + +.. index:: object: class + +Note that the class objects described here represent old-style classes, which +will go away in Python 3. When creating new types for extension modules, you +will want to work with type objects (section :ref:`typeobjects`). + + +.. ctype:: PyClassObject + + The C structure of the objects used to describe built-in classes. + + +.. cvar:: PyObject* PyClass_Type + + .. index:: single: ClassType (in module types) + + This is the type object for class objects; it is the same object as + ``types.ClassType`` in the Python layer. + + +.. cfunction:: int PyClass_Check(PyObject *o) + + Return true if the object *o* is a class object, including instances of types + derived from the standard class object. Return false in all other cases. + + +.. cfunction:: int PyClass_IsSubclass(PyObject *klass, PyObject *base) + + Return true if *klass* is a subclass of *base*. Return false in all other cases. + + +.. index:: object: instance + +There are very few functions specific to instance objects. + + +.. cvar:: PyTypeObject PyInstance_Type + + Type object for class instances. + + +.. cfunction:: int PyInstance_Check(PyObject *obj) + + Return true if *obj* is an instance. + + +.. cfunction:: PyObject* PyInstance_New(PyObject *class, PyObject *arg, PyObject *kw) + + Create a new instance of a specific class. The parameters *arg* and *kw* are + used as the positional and keyword parameters to the object's constructor. + + +.. cfunction:: PyObject* PyInstance_NewRaw(PyObject *class, PyObject *dict) + + Create a new instance of a specific class without calling its constructor. + *class* is the class of new object. The *dict* parameter will be used as the + object's :attr:`__dict__`; if *NULL*, a new dictionary will be created for the + instance. Added: python/trunk/Doc/c-api/cobject.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/c-api/cobject.rst Sat Jan 19 23:08:21 2008 @@ -0,0 +1,56 @@ +.. highlightlang:: c + +.. _cobjects: + +CObjects +-------- + +.. index:: object: CObject + +Refer to :ref:`using-cobjects` for more information on using these objects. + + +.. ctype:: PyCObject + + This subtype of :ctype:`PyObject` represents an opaque value, useful for C + extension modules who need to pass an opaque value (as a :ctype:`void\*` + pointer) through Python code to other C code. It is often used to make a C + function pointer defined in one module available to other modules, so the + regular import mechanism can be used to access C APIs defined in dynamically + loaded modules. + + +.. cfunction:: int PyCObject_Check(PyObject *p) + + Return true if its argument is a :ctype:`PyCObject`. + + +.. cfunction:: PyObject* PyCObject_FromVoidPtr(void* cobj, void (*destr)(void *)) + + Create a :ctype:`PyCObject` from the ``void *`` *cobj*. The *destr* function + will be called when the object is reclaimed, unless it is *NULL*. + + +.. cfunction:: PyObject* PyCObject_FromVoidPtrAndDesc(void* cobj, void* desc, void (*destr)(void *, void *)) + + Create a :ctype:`PyCObject` from the :ctype:`void \*` *cobj*. The *destr* + function will be called when the object is reclaimed. The *desc* argument can + be used to pass extra callback data for the destructor function. + + +.. cfunction:: void* PyCObject_AsVoidPtr(PyObject* self) + + Return the object :ctype:`void \*` that the :ctype:`PyCObject` *self* was + created with. + + +.. cfunction:: void* PyCObject_GetDesc(PyObject* self) + + Return the description :ctype:`void \*` that the :ctype:`PyCObject` *self* was + created with. + + +.. cfunction:: int PyCObject_SetVoidPtr(PyObject* self, void* cobj) + + Set the void pointer inside *self* to *cobj*. The :ctype:`PyCObject` must not + have an associated destructor. Return true on success, false on failure. Added: python/trunk/Doc/c-api/complex.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/c-api/complex.rst Sat Jan 19 23:08:21 2008 @@ -0,0 +1,132 @@ +.. highlightlang:: c + +.. _complexobjects: + +Complex Number Objects +---------------------- + +.. index:: object: complex number + +Python's complex number objects are implemented as two distinct types when +viewed from the C API: one is the Python object exposed to Python programs, and +the other is a C structure which represents the actual complex number value. +The API provides functions for working with both. + + +Complex Numbers as C Structures +^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + +Note that the functions which accept these structures as parameters and return +them as results do so *by value* rather than dereferencing them through +pointers. This is consistent throughout the API. + + +.. ctype:: Py_complex + + The C structure which corresponds to the value portion of a Python complex + number object. Most of the functions for dealing with complex number objects + use structures of this type as input or output values, as appropriate. It is + defined as:: + + typedef struct { + double real; + double imag; + } Py_complex; + + +.. cfunction:: Py_complex _Py_c_sum(Py_complex left, Py_complex right) + + Return the sum of two complex numbers, using the C :ctype:`Py_complex` + representation. + + +.. cfunction:: Py_complex _Py_c_diff(Py_complex left, Py_complex right) + + Return the difference between two complex numbers, using the C + :ctype:`Py_complex` representation. + + +.. cfunction:: Py_complex _Py_c_neg(Py_complex complex) + + Return the negation of the complex number *complex*, using the C + :ctype:`Py_complex` representation. + + +.. cfunction:: Py_complex _Py_c_prod(Py_complex left, Py_complex right) + + Return the product of two complex numbers, using the C :ctype:`Py_complex` + representation. + + +.. cfunction:: Py_complex _Py_c_quot(Py_complex dividend, Py_complex divisor) + + Return the quotient of two complex numbers, using the C :ctype:`Py_complex` + representation. + + +.. cfunction:: Py_complex _Py_c_pow(Py_complex num, Py_complex exp) + + Return the exponentiation of *num* by *exp*, using the C :ctype:`Py_complex` + representation. + + +Complex Numbers as Python Objects +^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + + +.. ctype:: PyComplexObject + + This subtype of :ctype:`PyObject` represents a Python complex number object. + + +.. cvar:: PyTypeObject PyComplex_Type + + This instance of :ctype:`PyTypeObject` represents the Python complex number + type. It is the same object as ``complex`` and ``types.ComplexType``. + + +.. cfunction:: int PyComplex_Check(PyObject *p) + + Return true if its argument is a :ctype:`PyComplexObject` or a subtype of + :ctype:`PyComplexObject`. + + .. versionchanged:: 2.2 + Allowed subtypes to be accepted. + + +.. cfunction:: int PyComplex_CheckExact(PyObject *p) + + Return true if its argument is a :ctype:`PyComplexObject`, but not a subtype of + :ctype:`PyComplexObject`. + + .. versionadded:: 2.2 + + +.. cfunction:: PyObject* PyComplex_FromCComplex(Py_complex v) + + Create a new Python complex number object from a C :ctype:`Py_complex` value. + + +.. cfunction:: PyObject* PyComplex_FromDoubles(double real, double imag) + + Return a new :ctype:`PyComplexObject` object from *real* and *imag*. + + +.. cfunction:: double PyComplex_RealAsDouble(PyObject *op) + + Return the real part of *op* as a C :ctype:`double`. + + +.. cfunction:: double PyComplex_ImagAsDouble(PyObject *op) + + Return the imaginary part of *op* as a C :ctype:`double`. + + +.. cfunction:: Py_complex PyComplex_AsCComplex(PyObject *op) + + Return the :ctype:`Py_complex` value of the complex number *op*. + + .. versionchanged:: 2.6 + If *op* is not a Python complex number object but has a :meth:`__complex__` + method, this method will first be called to convert *op* to a Python complex + number object. Modified: python/trunk/Doc/c-api/concrete.rst ============================================================================== --- python/trunk/Doc/c-api/concrete.rst (original) +++ python/trunk/Doc/c-api/concrete.rst Sat Jan 19 23:08:21 2008 @@ -29,108 +29,10 @@ This section describes Python type objects and the singleton object ``None``. +.. toctree:: -.. _typeobjects: - -Type Objects ------------- - -.. index:: object: type - - -.. ctype:: PyTypeObject - - The C structure of the objects used to describe built-in types. - - -.. cvar:: PyObject* PyType_Type - - .. index:: single: TypeType (in module types) - - This is the type object for type objects; it is the same object as ``type`` and - ``types.TypeType`` in the Python layer. - - -.. cfunction:: int PyType_Check(PyObject *o) - - Return true if the object *o* is a type object, including instances of types - derived from the standard type object. Return false in all other cases. - - -.. cfunction:: int PyType_CheckExact(PyObject *o) - - Return true if the object *o* is a type object, but not a subtype of the - standard type object. Return false in all other cases. - - .. versionadded:: 2.2 - - -.. cfunction:: int PyType_HasFeature(PyObject *o, int feature) - - Return true if the type object *o* sets the feature *feature*. Type features - are denoted by single bit flags. - - -.. cfunction:: int PyType_IS_GC(PyObject *o) - - Return true if the type object includes support for the cycle detector; this - tests the type flag :const:`Py_TPFLAGS_HAVE_GC`. - - .. versionadded:: 2.0 - - -.. cfunction:: int PyType_IsSubtype(PyTypeObject *a, PyTypeObject *b) - - Return true if *a* is a subtype of *b*. - - .. versionadded:: 2.2 - - -.. cfunction:: PyObject* PyType_GenericAlloc(PyTypeObject *type, Py_ssize_t nitems) - - .. versionadded:: 2.2 - - -.. cfunction:: PyObject* PyType_GenericNew(PyTypeObject *type, PyObject *args, PyObject *kwds) - - .. versionadded:: 2.2 - - -.. cfunction:: int PyType_Ready(PyTypeObject *type) - - Finalize a type object. This should be called on all type objects to finish - their initialization. This function is responsible for adding inherited slots - from a type's base class. Return ``0`` on success, or return ``-1`` and sets an - exception on error. - - .. versionadded:: 2.2 - - -.. _noneobject: - -The None Object ---------------- - -.. index:: object: None - -Note that the :ctype:`PyTypeObject` for ``None`` is not directly exposed in the -Python/C API. Since ``None`` is a singleton, testing for object identity (using -``==`` in C) is sufficient. There is no :cfunc:`PyNone_Check` function for the -same reason. - - -.. cvar:: PyObject* Py_None - - The Python ``None`` object, denoting lack of value. This object has no methods. - It needs to be treated just like any other object with respect to reference - counts. - - -.. cmacro:: Py_RETURN_NONE - - Properly handle returning :cdata:`Py_None` from within a C function. - - .. versionadded:: 2.4 + type.rst + none.rst .. _numericobjects: @@ -140,3508 +42,65 @@ .. index:: object: numeric +.. toctree:: -.. _intobjects: - -Plain Integer Objects ---------------------- - -.. index:: object: integer - - -.. ctype:: PyIntObject - - This subtype of :ctype:`PyObject` represents a Python integer object. - - -.. cvar:: PyTypeObject PyInt_Type - - .. index:: single: IntType (in modules types) - - This instance of :ctype:`PyTypeObject` represents the Python plain integer type. - This is the same object as ``int`` and ``types.IntType``. - - -.. cfunction:: int PyInt_Check(PyObject *o) - - Return true if *o* is of type :cdata:`PyInt_Type` or a subtype of - :cdata:`PyInt_Type`. - - .. versionchanged:: 2.2 - Allowed subtypes to be accepted. - - -.. cfunction:: int PyInt_CheckExact(PyObject *o) - - Return true if *o* is of type :cdata:`PyInt_Type`, but not a subtype of - :cdata:`PyInt_Type`. - - .. versionadded:: 2.2 - - -.. cfunction:: PyObject* PyInt_FromString(char *str, char **pend, int base) - - Return a new :ctype:`PyIntObject` or :ctype:`PyLongObject` based on the string - value in *str*, which is interpreted according to the radix in *base*. If - *pend* is non-*NULL*, ``*pend`` will point to the first character in *str* which - follows the representation of the number. If *base* is ``0``, the radix will be - determined based on the leading characters of *str*: if *str* starts with - ``'0x'`` or ``'0X'``, radix 16 will be used; if *str* starts with ``'0'``, radix - 8 will be used; otherwise radix 10 will be used. If *base* is not ``0``, it - must be between ``2`` and ``36``, inclusive. Leading spaces are ignored. If - there are no digits, :exc:`ValueError` will be raised. If the string represents - a number too large to be contained within the machine's :ctype:`long int` type - and overflow warnings are being suppressed, a :ctype:`PyLongObject` will be - returned. If overflow warnings are not being suppressed, *NULL* will be - returned in this case. - - -.. cfunction:: PyObject* PyInt_FromLong(long ival) - - Create a new integer object with a value of *ival*. - - The current implementation keeps an array of integer objects for all integers - between ``-5`` and ``256``, when you create an int in that range you actually - just get back a reference to the existing object. So it should be possible to - change the value of ``1``. I suspect the behaviour of Python in this case is - undefined. :-) - - -.. cfunction:: PyObject* PyInt_FromSsize_t(Py_ssize_t ival) - - Create a new integer object with a value of *ival*. If the value exceeds - ``LONG_MAX``, a long integer object is returned. - - .. versionadded:: 2.5 - - -.. cfunction:: long PyInt_AsLong(PyObject *io) - - Will first attempt to cast the object to a :ctype:`PyIntObject`, if it is not - already one, and then return its value. If there is an error, ``-1`` is - returned, and the caller should check ``PyErr_Occurred()`` to find out whether - there was an error, or whether the value just happened to be -1. - - -.. cfunction:: long PyInt_AS_LONG(PyObject *io) - - Return the value of the object *io*. No error checking is performed. - - -.. cfunction:: unsigned long PyInt_AsUnsignedLongMask(PyObject *io) - - Will first attempt to cast the object to a :ctype:`PyIntObject` or - :ctype:`PyLongObject`, if it is not already one, and then return its value as - unsigned long. This function does not check for overflow. - - .. versionadded:: 2.3 - - -.. cfunction:: unsigned PY_LONG_LONG PyInt_AsUnsignedLongLongMask(PyObject *io) - - Will first attempt to cast the object to a :ctype:`PyIntObject` or - :ctype:`PyLongObject`, if it is not already one, and then return its value as - unsigned long long, without checking for overflow. - - .. versionadded:: 2.3 - - -.. cfunction:: Py_ssize_t PyInt_AsSsize_t(PyObject *io) - - Will first attempt to cast the object to a :ctype:`PyIntObject` or - :ctype:`PyLongObject`, if it is not already one, and then return its value as - :ctype:`Py_ssize_t`. - - .. versionadded:: 2.5 - - -.. cfunction:: long PyInt_GetMax() - - .. index:: single: LONG_MAX - - Return the system's idea of the largest integer it can handle - (:const:`LONG_MAX`, as defined in the system header files). - - -.. _boolobjects: - -Boolean Objects ---------------- - -Booleans in Python are implemented as a subclass of integers. There are only -two booleans, :const:`Py_False` and :const:`Py_True`. As such, the normal -creation and deletion functions don't apply to booleans. The following macros -are available, however. - - -.. cfunction:: int PyBool_Check(PyObject *o) - - Return true if *o* is of type :cdata:`PyBool_Type`. - - .. versionadded:: 2.3 - - -.. cvar:: PyObject* Py_False - - The Python ``False`` object. This object has no methods. It needs to be - treated just like any other object with respect to reference counts. - - -.. cvar:: PyObject* Py_True - - The Python ``True`` object. This object has no methods. It needs to be treated - just like any other object with respect to reference counts. - - -.. cmacro:: Py_RETURN_FALSE - - Return :const:`Py_False` from a function, properly incrementing its reference - count. - - .. versionadded:: 2.4 - - -.. cmacro:: Py_RETURN_TRUE - - Return :const:`Py_True` from a function, properly incrementing its reference - count. - - .. versionadded:: 2.4 - - -.. cfunction:: PyObject* PyBool_FromLong(long v) - - Return a new reference to :const:`Py_True` or :const:`Py_False` depending on the - truth value of *v*. - - .. versionadded:: 2.3 - - -.. _longobjects: - -Long Integer Objects --------------------- + int.rst + bool.rst + long.rst + float.rst + complex.rst -.. index:: object: long integer +.. _sequenceobjects: -.. ctype:: PyLongObject - - This subtype of :ctype:`PyObject` represents a Python long integer object. - - -.. cvar:: PyTypeObject PyLong_Type - - .. index:: single: LongType (in modules types) - - This instance of :ctype:`PyTypeObject` represents the Python long integer type. - This is the same object as ``long`` and ``types.LongType``. - - -.. cfunction:: int PyLong_Check(PyObject *p) - - Return true if its argument is a :ctype:`PyLongObject` or a subtype of - :ctype:`PyLongObject`. - - .. versionchanged:: 2.2 - Allowed subtypes to be accepted. - - -.. cfunction:: int PyLong_CheckExact(PyObject *p) - - Return true if its argument is a :ctype:`PyLongObject`, but not a subtype of - :ctype:`PyLongObject`. - - .. versionadded:: 2.2 - - -.. cfunction:: PyObject* PyLong_FromLong(long v) - - Return a new :ctype:`PyLongObject` object from *v*, or *NULL* on failure. - - -.. cfunction:: PyObject* PyLong_FromUnsignedLong(unsigned long v) - - Return a new :ctype:`PyLongObject` object from a C :ctype:`unsigned long`, or - *NULL* on failure. - - -.. cfunction:: PyObject* PyLong_FromLongLong(PY_LONG_LONG v) - - Return a new :ctype:`PyLongObject` object from a C :ctype:`long long`, or *NULL* - on failure. - - -.. cfunction:: PyObject* PyLong_FromUnsignedLongLong(unsigned PY_LONG_LONG v) - - Return a new :ctype:`PyLongObject` object from a C :ctype:`unsigned long long`, - or *NULL* on failure. - - -.. cfunction:: PyObject* PyLong_FromDouble(double v) - - Return a new :ctype:`PyLongObject` object from the integer part of *v*, or - *NULL* on failure. - - -.. cfunction:: PyObject* PyLong_FromString(char *str, char **pend, int base) - - Return a new :ctype:`PyLongObject` based on the string value in *str*, which is - interpreted according to the radix in *base*. If *pend* is non-*NULL*, - ``*pend`` will point to the first character in *str* which follows the - representation of the number. If *base* is ``0``, the radix will be determined - based on the leading characters of *str*: if *str* starts with ``'0x'`` or - ``'0X'``, radix 16 will be used; if *str* starts with ``'0'``, radix 8 will be - used; otherwise radix 10 will be used. If *base* is not ``0``, it must be - between ``2`` and ``36``, inclusive. Leading spaces are ignored. If there are - no digits, :exc:`ValueError` will be raised. - - -.. cfunction:: PyObject* PyLong_FromUnicode(Py_UNICODE *u, Py_ssize_t length, int base) - - Convert a sequence of Unicode digits to a Python long integer value. The first - parameter, *u*, points to the first character of the Unicode string, *length* - gives the number of characters, and *base* is the radix for the conversion. The - radix must be in the range [2, 36]; if it is out of range, :exc:`ValueError` - will be raised. - - .. versionadded:: 1.6 - - -.. cfunction:: PyObject* PyLong_FromVoidPtr(void *p) - - Create a Python integer or long integer from the pointer *p*. The pointer value - can be retrieved from the resulting value using :cfunc:`PyLong_AsVoidPtr`. - - .. versionadded:: 1.5.2 - - .. versionchanged:: 2.5 - If the integer is larger than LONG_MAX, a positive long integer is returned. - - -.. cfunction:: long PyLong_AsLong(PyObject *pylong) - - .. index:: - single: LONG_MAX - single: OverflowError (built-in exception) - - Return a C :ctype:`long` representation of the contents of *pylong*. If - *pylong* is greater than :const:`LONG_MAX`, an :exc:`OverflowError` is raised. - - -.. cfunction:: unsigned long PyLong_AsUnsignedLong(PyObject *pylong) - - .. index:: - single: ULONG_MAX - single: OverflowError (built-in exception) - - Return a C :ctype:`unsigned long` representation of the contents of *pylong*. - If *pylong* is greater than :const:`ULONG_MAX`, an :exc:`OverflowError` is - raised. - - -.. cfunction:: PY_LONG_LONG PyLong_AsLongLong(PyObject *pylong) - - Return a C :ctype:`long long` from a Python long integer. If *pylong* cannot be - represented as a :ctype:`long long`, an :exc:`OverflowError` will be raised. - - .. versionadded:: 2.2 - - -.. cfunction:: unsigned PY_LONG_LONG PyLong_AsUnsignedLongLong(PyObject *pylong) - - Return a C :ctype:`unsigned long long` from a Python long integer. If *pylong* - cannot be represented as an :ctype:`unsigned long long`, an :exc:`OverflowError` - will be raised if the value is positive, or a :exc:`TypeError` will be raised if - the value is negative. - - .. versionadded:: 2.2 - - -.. cfunction:: unsigned long PyLong_AsUnsignedLongMask(PyObject *io) - - Return a C :ctype:`unsigned long` from a Python long integer, without checking - for overflow. - - .. versionadded:: 2.3 - - -.. cfunction:: unsigned PY_LONG_LONG PyLong_AsUnsignedLongLongMask(PyObject *io) - - Return a C :ctype:`unsigned long long` from a Python long integer, without - checking for overflow. - - .. versionadded:: 2.3 - - -.. cfunction:: double PyLong_AsDouble(PyObject *pylong) - - Return a C :ctype:`double` representation of the contents of *pylong*. If - *pylong* cannot be approximately represented as a :ctype:`double`, an - :exc:`OverflowError` exception is raised and ``-1.0`` will be returned. - - -.. cfunction:: void* PyLong_AsVoidPtr(PyObject *pylong) - - Convert a Python integer or long integer *pylong* to a C :ctype:`void` pointer. - If *pylong* cannot be converted, an :exc:`OverflowError` will be raised. This - is only assured to produce a usable :ctype:`void` pointer for values created - with :cfunc:`PyLong_FromVoidPtr`. - - .. versionadded:: 1.5.2 - - .. versionchanged:: 2.5 - For values outside 0..LONG_MAX, both signed and unsigned integers are acccepted. - - -.. _floatobjects: - -Floating Point Objects ----------------------- - -.. index:: object: floating point - - -.. ctype:: PyFloatObject - - This subtype of :ctype:`PyObject` represents a Python floating point object. - - -.. cvar:: PyTypeObject PyFloat_Type - - .. index:: single: FloatType (in modules types) - - This instance of :ctype:`PyTypeObject` represents the Python floating point - type. This is the same object as ``float`` and ``types.FloatType``. - - -.. cfunction:: int PyFloat_Check(PyObject *p) - - Return true if its argument is a :ctype:`PyFloatObject` or a subtype of - :ctype:`PyFloatObject`. - - .. versionchanged:: 2.2 - Allowed subtypes to be accepted. - - -.. cfunction:: int PyFloat_CheckExact(PyObject *p) - - Return true if its argument is a :ctype:`PyFloatObject`, but not a subtype of - :ctype:`PyFloatObject`. - - .. versionadded:: 2.2 - - -.. cfunction:: PyObject* PyFloat_FromString(PyObject *str, char **pend) - - Create a :ctype:`PyFloatObject` object based on the string value in *str*, or - *NULL* on failure. The *pend* argument is ignored. It remains only for - backward compatibility. - - -.. cfunction:: PyObject* PyFloat_FromDouble(double v) - - Create a :ctype:`PyFloatObject` object from *v*, or *NULL* on failure. - - -.. cfunction:: double PyFloat_AsDouble(PyObject *pyfloat) - - Return a C :ctype:`double` representation of the contents of *pyfloat*. If - *pyfloat* is not a Python floating point object but has a :meth:`__float__` - method, this method will first be called to convert *pyfloat* into a float. - - -.. cfunction:: double PyFloat_AS_DOUBLE(PyObject *pyfloat) - - Return a C :ctype:`double` representation of the contents of *pyfloat*, but - without error checking. - - -.. cfunction:: PyObject* PyFloat_GetInfo(void) - - Return a structseq instance which contains information about the - precision, minimum and maximum values of a float. It's a thin wrapper - around the header file :file:`float.h`. - - .. versionadded:: 2.6 - - -.. cfunction:: double PyFloat_GetMax(void) - - Return the maximum representable finite float *DBL_MAX* as C :ctype:`double`. - - .. versionadded:: 2.6 - - -.. cfunction:: double PyFloat_GetMin(void) - - Return the minimum normalized positive float *DBL_MIN* as C :ctype:`double`. - - .. versionadded:: 2.6 - +Sequence Objects +================ -.. _complexobjects: +.. index:: object: sequence -Complex Number Objects ----------------------- +Generic operations on sequence objects were discussed in the previous chapter; +this section deals with the specific kinds of sequence objects that are +intrinsic to the Python language. -.. index:: object: complex number +.. toctree:: -Python's complex number objects are implemented as two distinct types when -viewed from the C API: one is the Python object exposed to Python programs, and -the other is a C structure which represents the actual complex number value. -The API provides functions for working with both. + string.rst + unicode.rst + buffer.rst + tuple.rst + list.rst -Complex Numbers as C Structures -^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ +.. _mapobjects: -Note that the functions which accept these structures as parameters and return -them as results do so *by value* rather than dereferencing them through -pointers. This is consistent throughout the API. +Mapping Objects +=============== +.. index:: object: mapping -.. ctype:: Py_complex +.. toctree:: - The C structure which corresponds to the value portion of a Python complex - number object. Most of the functions for dealing with complex number objects - use structures of this type as input or output values, as appropriate. It is - defined as:: + dict.rst - typedef struct { - double real; - double imag; - } Py_complex; +.. _otherobjects: -.. cfunction:: Py_complex _Py_c_sum(Py_complex left, Py_complex right) - - Return the sum of two complex numbers, using the C :ctype:`Py_complex` - representation. - - -.. cfunction:: Py_complex _Py_c_diff(Py_complex left, Py_complex right) - - Return the difference between two complex numbers, using the C - :ctype:`Py_complex` representation. - - -.. cfunction:: Py_complex _Py_c_neg(Py_complex complex) - - Return the negation of the complex number *complex*, using the C - :ctype:`Py_complex` representation. - - -.. cfunction:: Py_complex _Py_c_prod(Py_complex left, Py_complex right) - - Return the product of two complex numbers, using the C :ctype:`Py_complex` - representation. - - -.. cfunction:: Py_complex _Py_c_quot(Py_complex dividend, Py_complex divisor) - - Return the quotient of two complex numbers, using the C :ctype:`Py_complex` - representation. - - -.. cfunction:: Py_complex _Py_c_pow(Py_complex num, Py_complex exp) - - Return the exponentiation of *num* by *exp*, using the C :ctype:`Py_complex` - representation. - - -Complex Numbers as Python Objects -^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ - - -.. ctype:: PyComplexObject - - This subtype of :ctype:`PyObject` represents a Python complex number object. - - -.. cvar:: PyTypeObject PyComplex_Type - - This instance of :ctype:`PyTypeObject` represents the Python complex number - type. It is the same object as ``complex`` and ``types.ComplexType``. - - -.. cfunction:: int PyComplex_Check(PyObject *p) - - Return true if its argument is a :ctype:`PyComplexObject` or a subtype of - :ctype:`PyComplexObject`. - - .. versionchanged:: 2.2 - Allowed subtypes to be accepted. - - -.. cfunction:: int PyComplex_CheckExact(PyObject *p) - - Return true if its argument is a :ctype:`PyComplexObject`, but not a subtype of - :ctype:`PyComplexObject`. - - .. versionadded:: 2.2 - - -.. cfunction:: PyObject* PyComplex_FromCComplex(Py_complex v) - - Create a new Python complex number object from a C :ctype:`Py_complex` value. - - -.. cfunction:: PyObject* PyComplex_FromDoubles(double real, double imag) - - Return a new :ctype:`PyComplexObject` object from *real* and *imag*. - - -.. cfunction:: double PyComplex_RealAsDouble(PyObject *op) - - Return the real part of *op* as a C :ctype:`double`. - - -.. cfunction:: double PyComplex_ImagAsDouble(PyObject *op) - - Return the imaginary part of *op* as a C :ctype:`double`. - - -.. cfunction:: Py_complex PyComplex_AsCComplex(PyObject *op) - - Return the :ctype:`Py_complex` value of the complex number *op*. - - .. versionchanged:: 2.6 - If *op* is not a Python complex number object but has a :meth:`__complex__` - method, this method will first be called to convert *op* to a Python complex - number object. - - -.. _sequenceobjects: - -Sequence Objects -================ - -.. index:: object: sequence - -Generic operations on sequence objects were discussed in the previous chapter; -this section deals with the specific kinds of sequence objects that are -intrinsic to the Python language. - - -.. _stringobjects: - -String Objects --------------- - -These functions raise :exc:`TypeError` when expecting a string parameter and are -called with a non-string parameter. - -.. index:: object: string - - -.. ctype:: PyStringObject - - This subtype of :ctype:`PyObject` represents a Python string object. - - -.. cvar:: PyTypeObject PyString_Type - - .. index:: single: StringType (in module types) - - This instance of :ctype:`PyTypeObject` represents the Python string type; it is - the same object as ``str`` and ``types.StringType`` in the Python layer. . - - -.. cfunction:: int PyString_Check(PyObject *o) - - Return true if the object *o* is a string object or an instance of a subtype of - the string type. - - .. versionchanged:: 2.2 - Allowed subtypes to be accepted. - - -.. cfunction:: int PyString_CheckExact(PyObject *o) - - Return true if the object *o* is a string object, but not an instance of a - subtype of the string type. - - .. versionadded:: 2.2 - - -.. cfunction:: PyObject* PyString_FromString(const char *v) - - Return a new string object with a copy of the string *v* as value on success, - and *NULL* on failure. The parameter *v* must not be *NULL*; it will not be - checked. - - -.. cfunction:: PyObject* PyString_FromStringAndSize(const char *v, Py_ssize_t len) - - Return a new string object with a copy of the string *v* as value and length - *len* on success, and *NULL* on failure. If *v* is *NULL*, the contents of the - string are uninitialized. - - -.. cfunction:: PyObject* PyString_FromFormat(const char *format, ...) - - Take a C :cfunc:`printf`\ -style *format* string and a variable number of - arguments, calculate the size of the resulting Python string and return a string - with the values formatted into it. The variable arguments must be C types and - must correspond exactly to the format characters in the *format* string. The - following format characters are allowed: - - .. % This should be exactly the same as the table in PyErr_Format. - .. % One should just refer to the other. - .. % The descriptions for %zd and %zu are wrong, but the truth is complicated - .. % because not all compilers support the %z width modifier -- we fake it - .. % when necessary via interpolating PY_FORMAT_SIZE_T. - .. % %u, %lu, %zu should have "new in Python 2.5" blurbs. - - +-------------------+---------------+--------------------------------+ - | Format Characters | Type | Comment | - +===================+===============+================================+ - | :attr:`%%` | *n/a* | The literal % character. | - +-------------------+---------------+--------------------------------+ - | :attr:`%c` | int | A single character, | - | | | represented as an C int. | - +-------------------+---------------+--------------------------------+ - | :attr:`%d` | int | Exactly equivalent to | - | | | ``printf("%d")``. | - +-------------------+---------------+--------------------------------+ - | :attr:`%u` | unsigned int | Exactly equivalent to | - | | | ``printf("%u")``. | - +-------------------+---------------+--------------------------------+ - | :attr:`%ld` | long | Exactly equivalent to | - | | | ``printf("%ld")``. | - +-------------------+---------------+--------------------------------+ - | :attr:`%lu` | unsigned long | Exactly equivalent to | - | | | ``printf("%lu")``. | - +-------------------+---------------+--------------------------------+ - | :attr:`%zd` | Py_ssize_t | Exactly equivalent to | - | | | ``printf("%zd")``. | - +-------------------+---------------+--------------------------------+ - | :attr:`%zu` | size_t | Exactly equivalent to | - | | | ``printf("%zu")``. | - +-------------------+---------------+--------------------------------+ - | :attr:`%i` | int | Exactly equivalent to | - | | | ``printf("%i")``. | - +-------------------+---------------+--------------------------------+ - | :attr:`%x` | int | Exactly equivalent to | - | | | ``printf("%x")``. | - +-------------------+---------------+--------------------------------+ - | :attr:`%s` | char\* | A null-terminated C character | - | | | array. | - +-------------------+---------------+--------------------------------+ - | :attr:`%p` | void\* | The hex representation of a C | - | | | pointer. Mostly equivalent to | - | | | ``printf("%p")`` except that | - | | | it is guaranteed to start with | - | | | the literal ``0x`` regardless | - | | | of what the platform's | - | | | ``printf`` yields. | - +-------------------+---------------+--------------------------------+ - - An unrecognized format character causes all the rest of the format string to be - copied as-is to the result string, and any extra arguments discarded. - - -.. cfunction:: PyObject* PyString_FromFormatV(const char *format, va_list vargs) - - Identical to :func:`PyString_FromFormat` except that it takes exactly two - arguments. - - -.. cfunction:: Py_ssize_t PyString_Size(PyObject *string) - - Return the length of the string in string object *string*. - - -.. cfunction:: Py_ssize_t PyString_GET_SIZE(PyObject *string) - - Macro form of :cfunc:`PyString_Size` but without error checking. - - -.. cfunction:: char* PyString_AsString(PyObject *string) - - Return a NUL-terminated representation of the contents of *string*. The pointer - refers to the internal buffer of *string*, not a copy. The data must not be - modified in any way, unless the string was just created using - ``PyString_FromStringAndSize(NULL, size)``. It must not be deallocated. If - *string* is a Unicode object, this function computes the default encoding of - *string* and operates on that. If *string* is not a string object at all, - :cfunc:`PyString_AsString` returns *NULL* and raises :exc:`TypeError`. - - -.. cfunction:: char* PyString_AS_STRING(PyObject *string) - - Macro form of :cfunc:`PyString_AsString` but without error checking. Only - string objects are supported; no Unicode objects should be passed. - - -.. cfunction:: int PyString_AsStringAndSize(PyObject *obj, char **buffer, Py_ssize_t *length) - - Return a NUL-terminated representation of the contents of the object *obj* - through the output variables *buffer* and *length*. - - The function accepts both string and Unicode objects as input. For Unicode - objects it returns the default encoded version of the object. If *length* is - *NULL*, the resulting buffer may not contain NUL characters; if it does, the - function returns ``-1`` and a :exc:`TypeError` is raised. - - The buffer refers to an internal string buffer of *obj*, not a copy. The data - must not be modified in any way, unless the string was just created using - ``PyString_FromStringAndSize(NULL, size)``. It must not be deallocated. If - *string* is a Unicode object, this function computes the default encoding of - *string* and operates on that. If *string* is not a string object at all, - :cfunc:`PyString_AsStringAndSize` returns ``-1`` and raises :exc:`TypeError`. - - -.. cfunction:: void PyString_Concat(PyObject **string, PyObject *newpart) - - Create a new string object in *\*string* containing the contents of *newpart* - appended to *string*; the caller will own the new reference. The reference to - the old value of *string* will be stolen. If the new string cannot be created, - the old reference to *string* will still be discarded and the value of - *\*string* will be set to *NULL*; the appropriate exception will be set. - - -.. cfunction:: void PyString_ConcatAndDel(PyObject **string, PyObject *newpart) - - Create a new string object in *\*string* containing the contents of *newpart* - appended to *string*. This version decrements the reference count of *newpart*. - - -.. cfunction:: int _PyString_Resize(PyObject **string, Py_ssize_t newsize) - - A way to resize a string object even though it is "immutable". Only use this to - build up a brand new string object; don't use this if the string may already be - known in other parts of the code. It is an error to call this function if the - refcount on the input string object is not one. Pass the address of an existing - string object as an lvalue (it may be written into), and the new size desired. - On success, *\*string* holds the resized string object and ``0`` is returned; - the address in *\*string* may differ from its input value. If the reallocation - fails, the original string object at *\*string* is deallocated, *\*string* is - set to *NULL*, a memory exception is set, and ``-1`` is returned. - - -.. cfunction:: PyObject* PyString_Format(PyObject *format, PyObject *args) - - Return a new string object from *format* and *args*. Analogous to ``format % - args``. The *args* argument must be a tuple. - - -.. cfunction:: void PyString_InternInPlace(PyObject **string) - - Intern the argument *\*string* in place. The argument must be the address of a - pointer variable pointing to a Python string object. If there is an existing - interned string that is the same as *\*string*, it sets *\*string* to it - (decrementing the reference count of the old string object and incrementing the - reference count of the interned string object), otherwise it leaves *\*string* - alone and interns it (incrementing its reference count). (Clarification: even - though there is a lot of talk about reference counts, think of this function as - reference-count-neutral; you own the object after the call if and only if you - owned it before the call.) - - -.. cfunction:: PyObject* PyString_InternFromString(const char *v) - - A combination of :cfunc:`PyString_FromString` and - :cfunc:`PyString_InternInPlace`, returning either a new string object that has - been interned, or a new ("owned") reference to an earlier interned string object - with the same value. - - -.. cfunction:: PyObject* PyString_Decode(const char *s, Py_ssize_t size, const char *encoding, const char *errors) - - Create an object by decoding *size* bytes of the encoded buffer *s* using the - codec registered for *encoding*. *encoding* and *errors* have the same meaning - as the parameters of the same name in the :func:`unicode` built-in function. - The codec to be used is looked up using the Python codec registry. Return - *NULL* if an exception was raised by the codec. - - -.. cfunction:: PyObject* PyString_AsDecodedObject(PyObject *str, const char *encoding, const char *errors) - - Decode a string object by passing it to the codec registered for *encoding* and - return the result as Python object. *encoding* and *errors* have the same - meaning as the parameters of the same name in the string :meth:`encode` method. - The codec to be used is looked up using the Python codec registry. Return *NULL* - if an exception was raised by the codec. - - -.. cfunction:: PyObject* PyString_Encode(const char *s, Py_ssize_t size, const char *encoding, const char *errors) - - Encode the :ctype:`char` buffer of the given size by passing it to the codec - registered for *encoding* and return a Python object. *encoding* and *errors* - have the same meaning as the parameters of the same name in the string - :meth:`encode` method. The codec to be used is looked up using the Python codec - registry. Return *NULL* if an exception was raised by the codec. - - -.. cfunction:: PyObject* PyString_AsEncodedObject(PyObject *str, const char *encoding, const char *errors) - - Encode a string object using the codec registered for *encoding* and return the - result as Python object. *encoding* and *errors* have the same meaning as the - parameters of the same name in the string :meth:`encode` method. The codec to be - used is looked up using the Python codec registry. Return *NULL* if an exception - was raised by the codec. - - -.. _unicodeobjects: - -Unicode Objects ---------------- - -.. sectionauthor:: Marc-Andre Lemburg - - -These are the basic Unicode object types used for the Unicode implementation in -Python: - -.. % --- Unicode Type ------------------------------------------------------- - - -.. ctype:: Py_UNICODE - - This type represents the storage type which is used by Python internally as - basis for holding Unicode ordinals. Python's default builds use a 16-bit type - for :ctype:`Py_UNICODE` and store Unicode values internally as UCS2. It is also - possible to build a UCS4 version of Python (most recent Linux distributions come - with UCS4 builds of Python). These builds then use a 32-bit type for - :ctype:`Py_UNICODE` and store Unicode data internally as UCS4. On platforms - where :ctype:`wchar_t` is available and compatible with the chosen Python - Unicode build variant, :ctype:`Py_UNICODE` is a typedef alias for - :ctype:`wchar_t` to enhance native platform compatibility. On all other - platforms, :ctype:`Py_UNICODE` is a typedef alias for either :ctype:`unsigned - short` (UCS2) or :ctype:`unsigned long` (UCS4). - -Note that UCS2 and UCS4 Python builds are not binary compatible. Please keep -this in mind when writing extensions or interfaces. - - -.. ctype:: PyUnicodeObject - - This subtype of :ctype:`PyObject` represents a Python Unicode object. - - -.. cvar:: PyTypeObject PyUnicode_Type - - This instance of :ctype:`PyTypeObject` represents the Python Unicode type. It - is exposed to Python code as ``unicode`` and ``types.UnicodeType``. - -The following APIs are really C macros and can be used to do fast checks and to -access internal read-only data of Unicode objects: - - -.. cfunction:: int PyUnicode_Check(PyObject *o) - - Return true if the object *o* is a Unicode object or an instance of a Unicode - subtype. - - .. versionchanged:: 2.2 - Allowed subtypes to be accepted. - - -.. cfunction:: int PyUnicode_CheckExact(PyObject *o) - - Return true if the object *o* is a Unicode object, but not an instance of a - subtype. - - .. versionadded:: 2.2 - - -.. cfunction:: Py_ssize_t PyUnicode_GET_SIZE(PyObject *o) - - Return the size of the object. *o* has to be a :ctype:`PyUnicodeObject` (not - checked). - - -.. cfunction:: Py_ssize_t PyUnicode_GET_DATA_SIZE(PyObject *o) - - Return the size of the object's internal buffer in bytes. *o* has to be a - :ctype:`PyUnicodeObject` (not checked). - - -.. cfunction:: Py_UNICODE* PyUnicode_AS_UNICODE(PyObject *o) - - Return a pointer to the internal :ctype:`Py_UNICODE` buffer of the object. *o* - has to be a :ctype:`PyUnicodeObject` (not checked). - - -.. cfunction:: const char* PyUnicode_AS_DATA(PyObject *o) - - Return a pointer to the internal buffer of the object. *o* has to be a - :ctype:`PyUnicodeObject` (not checked). - -Unicode provides many different character properties. The most often needed ones -are available through these macros which are mapped to C functions depending on -the Python configuration. - -.. % --- Unicode character properties --------------------------------------- - - -.. cfunction:: int Py_UNICODE_ISSPACE(Py_UNICODE ch) - - Return 1 or 0 depending on whether *ch* is a whitespace character. - - -.. cfunction:: int Py_UNICODE_ISLOWER(Py_UNICODE ch) - - Return 1 or 0 depending on whether *ch* is a lowercase character. - - -.. cfunction:: int Py_UNICODE_ISUPPER(Py_UNICODE ch) - - Return 1 or 0 depending on whether *ch* is an uppercase character. - - -.. cfunction:: int Py_UNICODE_ISTITLE(Py_UNICODE ch) - - Return 1 or 0 depending on whether *ch* is a titlecase character. - - -.. cfunction:: int Py_UNICODE_ISLINEBREAK(Py_UNICODE ch) - - Return 1 or 0 depending on whether *ch* is a linebreak character. - - -.. cfunction:: int Py_UNICODE_ISDECIMAL(Py_UNICODE ch) - - Return 1 or 0 depending on whether *ch* is a decimal character. - - -.. cfunction:: int Py_UNICODE_ISDIGIT(Py_UNICODE ch) - - Return 1 or 0 depending on whether *ch* is a digit character. - - -.. cfunction:: int Py_UNICODE_ISNUMERIC(Py_UNICODE ch) - - Return 1 or 0 depending on whether *ch* is a numeric character. - - -.. cfunction:: int Py_UNICODE_ISALPHA(Py_UNICODE ch) - - Return 1 or 0 depending on whether *ch* is an alphabetic character. - - -.. cfunction:: int Py_UNICODE_ISALNUM(Py_UNICODE ch) - - Return 1 or 0 depending on whether *ch* is an alphanumeric character. - -These APIs can be used for fast direct character conversions: - - -.. cfunction:: Py_UNICODE Py_UNICODE_TOLOWER(Py_UNICODE ch) - - Return the character *ch* converted to lower case. - - -.. cfunction:: Py_UNICODE Py_UNICODE_TOUPPER(Py_UNICODE ch) - - Return the character *ch* converted to upper case. - - -.. cfunction:: Py_UNICODE Py_UNICODE_TOTITLE(Py_UNICODE ch) - - Return the character *ch* converted to title case. - - -.. cfunction:: int Py_UNICODE_TODECIMAL(Py_UNICODE ch) - - Return the character *ch* converted to a decimal positive integer. Return - ``-1`` if this is not possible. This macro does not raise exceptions. - - -.. cfunction:: int Py_UNICODE_TODIGIT(Py_UNICODE ch) - - Return the character *ch* converted to a single digit integer. Return ``-1`` if - this is not possible. This macro does not raise exceptions. - - -.. cfunction:: double Py_UNICODE_TONUMERIC(Py_UNICODE ch) - - Return the character *ch* converted to a double. Return ``-1.0`` if this is not - possible. This macro does not raise exceptions. - -To create Unicode objects and access their basic sequence properties, use these -APIs: - -.. % --- Plain Py_UNICODE --------------------------------------------------- - - -.. cfunction:: PyObject* PyUnicode_FromUnicode(const Py_UNICODE *u, Py_ssize_t size) - - Create a Unicode Object from the Py_UNICODE buffer *u* of the given size. *u* - may be *NULL* which causes the contents to be undefined. It is the user's - responsibility to fill in the needed data. The buffer is copied into the new - object. If the buffer is not *NULL*, the return value might be a shared object. - Therefore, modification of the resulting Unicode object is only allowed when *u* - is *NULL*. - - -.. cfunction:: Py_UNICODE* PyUnicode_AsUnicode(PyObject *unicode) - - Return a read-only pointer to the Unicode object's internal :ctype:`Py_UNICODE` - buffer, *NULL* if *unicode* is not a Unicode object. - - -.. cfunction:: Py_ssize_t PyUnicode_GetSize(PyObject *unicode) - - Return the length of the Unicode object. - - -.. cfunction:: PyObject* PyUnicode_FromEncodedObject(PyObject *obj, const char *encoding, const char *errors) - - Coerce an encoded object *obj* to an Unicode object and return a reference with - incremented refcount. - - String and other char buffer compatible objects are decoded according to the - given encoding and using the error handling defined by errors. Both can be - *NULL* to have the interface use the default values (see the next section for - details). - - All other objects, including Unicode objects, cause a :exc:`TypeError` to be - set. - - The API returns *NULL* if there was an error. The caller is responsible for - decref'ing the returned objects. - - -.. cfunction:: PyObject* PyUnicode_FromObject(PyObject *obj) - - Shortcut for ``PyUnicode_FromEncodedObject(obj, NULL, "strict")`` which is used - throughout the interpreter whenever coercion to Unicode is needed. - -If the platform supports :ctype:`wchar_t` and provides a header file wchar.h, -Python can interface directly to this type using the following functions. -Support is optimized if Python's own :ctype:`Py_UNICODE` type is identical to -the system's :ctype:`wchar_t`. - -.. % --- wchar_t support for platforms which support it --------------------- - - -.. cfunction:: PyObject* PyUnicode_FromWideChar(const wchar_t *w, Py_ssize_t size) - - Create a Unicode object from the :ctype:`wchar_t` buffer *w* of the given size. - Return *NULL* on failure. - - -.. cfunction:: Py_ssize_t PyUnicode_AsWideChar(PyUnicodeObject *unicode, wchar_t *w, Py_ssize_t size) - - Copy the Unicode object contents into the :ctype:`wchar_t` buffer *w*. At most - *size* :ctype:`wchar_t` characters are copied (excluding a possibly trailing - 0-termination character). Return the number of :ctype:`wchar_t` characters - copied or -1 in case of an error. Note that the resulting :ctype:`wchar_t` - string may or may not be 0-terminated. It is the responsibility of the caller - to make sure that the :ctype:`wchar_t` string is 0-terminated in case this is - required by the application. - - -.. _builtincodecs: - -Built-in Codecs -^^^^^^^^^^^^^^^ - -Python provides a set of builtin codecs which are written in C for speed. All of -these codecs are directly usable via the following functions. - -Many of the following APIs take two arguments encoding and errors. These -parameters encoding and errors have the same semantics as the ones of the -builtin unicode() Unicode object constructor. - -Setting encoding to *NULL* causes the default encoding to be used which is -ASCII. The file system calls should use :cdata:`Py_FileSystemDefaultEncoding` -as the encoding for file names. This variable should be treated as read-only: On -some systems, it will be a pointer to a static string, on others, it will change -at run-time (such as when the application invokes setlocale). - -Error handling is set by errors which may also be set to *NULL* meaning to use -the default handling defined for the codec. Default error handling for all -builtin codecs is "strict" (:exc:`ValueError` is raised). - -The codecs all use a similar interface. Only deviation from the following -generic ones are documented for simplicity. - -These are the generic codec APIs: - -.. % --- Generic Codecs ----------------------------------------------------- - - -.. cfunction:: PyObject* PyUnicode_Decode(const char *s, Py_ssize_t size, const char *encoding, const char *errors) - - Create a Unicode object by decoding *size* bytes of the encoded string *s*. - *encoding* and *errors* have the same meaning as the parameters of the same name - in the :func:`unicode` builtin function. The codec to be used is looked up - using the Python codec registry. Return *NULL* if an exception was raised by - the codec. - - -.. cfunction:: PyObject* PyUnicode_Encode(const Py_UNICODE *s, Py_ssize_t size, const char *encoding, const char *errors) - - Encode the :ctype:`Py_UNICODE` buffer of the given size and return a Python - string object. *encoding* and *errors* have the same meaning as the parameters - of the same name in the Unicode :meth:`encode` method. The codec to be used is - looked up using the Python codec registry. Return *NULL* if an exception was - raised by the codec. - - -.. cfunction:: PyObject* PyUnicode_AsEncodedString(PyObject *unicode, const char *encoding, const char *errors) - - Encode a Unicode object and return the result as Python string object. - *encoding* and *errors* have the same meaning as the parameters of the same name - in the Unicode :meth:`encode` method. The codec to be used is looked up using - the Python codec registry. Return *NULL* if an exception was raised by the - codec. - -These are the UTF-8 codec APIs: - -.. % --- UTF-8 Codecs ------------------------------------------------------- - - -.. cfunction:: PyObject* PyUnicode_DecodeUTF8(const char *s, Py_ssize_t size, const char *errors) - - Create a Unicode object by decoding *size* bytes of the UTF-8 encoded string - *s*. Return *NULL* if an exception was raised by the codec. - - -.. cfunction:: PyObject* PyUnicode_DecodeUTF8Stateful(const char *s, Py_ssize_t size, const char *errors, Py_ssize_t *consumed) - - If *consumed* is *NULL*, behave like :cfunc:`PyUnicode_DecodeUTF8`. If - *consumed* is not *NULL*, trailing incomplete UTF-8 byte sequences will not be - treated as an error. Those bytes will not be decoded and the number of bytes - that have been decoded will be stored in *consumed*. - - .. versionadded:: 2.4 - - -.. cfunction:: PyObject* PyUnicode_EncodeUTF8(const Py_UNICODE *s, Py_ssize_t size, const char *errors) - - Encode the :ctype:`Py_UNICODE` buffer of the given size using UTF-8 and return a - Python string object. Return *NULL* if an exception was raised by the codec. - - -.. cfunction:: PyObject* PyUnicode_AsUTF8String(PyObject *unicode) - - Encode a Unicode object using UTF-8 and return the result as Python string - object. Error handling is "strict". Return *NULL* if an exception was raised - by the codec. - -These are the UTF-32 codec APIs: - -.. % --- UTF-32 Codecs ------------------------------------------------------ */ - - -.. cfunction:: PyObject* PyUnicode_DecodeUTF32(const char *s, Py_ssize_t size, const char *errors, int *byteorder) - - Decode *length* bytes from a UTF-32 encoded buffer string and return the - corresponding Unicode object. *errors* (if non-*NULL*) defines the error - handling. It defaults to "strict". - - If *byteorder* is non-*NULL*, the decoder starts decoding using the given byte - order:: - - *byteorder == -1: little endian - *byteorder == 0: native order - *byteorder == 1: big endian - - and then switches if the first four bytes of the input data are a byte order mark - (BOM) and the specified byte order is native order. This BOM is not copied into - the resulting Unicode string. After completion, *\*byteorder* is set to the - current byte order at the end of input data. - - In a narrow build codepoints outside the BMP will be decoded as surrogate pairs. - - If *byteorder* is *NULL*, the codec starts in native order mode. - - Return *NULL* if an exception was raised by the codec. - - .. versionadded:: 2.6 - - -.. cfunction:: PyObject* PyUnicode_DecodeUTF32Stateful(const char *s, Py_ssize_t size, const char *errors, int *byteorder, Py_ssize_t *consumed) - - If *consumed* is *NULL*, behave like :cfunc:`PyUnicode_DecodeUTF32`. If - *consumed* is not *NULL*, :cfunc:`PyUnicode_DecodeUTF32Stateful` will not treat - trailing incomplete UTF-32 byte sequences (such as a number of bytes not divisible - by four) as an error. Those bytes will not be decoded and the number of bytes - that have been decoded will be stored in *consumed*. - - .. versionadded:: 2.6 - - -.. cfunction:: PyObject* PyUnicode_EncodeUTF32(const Py_UNICODE *s, Py_ssize_t size, const char *errors, int byteorder) - - Return a Python bytes object holding the UTF-32 encoded value of the Unicode - data in *s*. If *byteorder* is not ``0``, output is written according to the - following byte order:: - - byteorder == -1: little endian - byteorder == 0: native byte order (writes a BOM mark) - byteorder == 1: big endian - - If byteorder is ``0``, the output string will always start with the Unicode BOM - mark (U+FEFF). In the other two modes, no BOM mark is prepended. - - If *Py_UNICODE_WIDE* is not defined, surrogate pairs will be output - as a single codepoint. - - Return *NULL* if an exception was raised by the codec. - - .. versionadded:: 2.6 - - -.. cfunction:: PyObject* PyUnicode_AsUTF32String(PyObject *unicode) - - Return a Python string using the UTF-32 encoding in native byte order. The - string always starts with a BOM mark. Error handling is "strict". Return - *NULL* if an exception was raised by the codec. - - .. versionadded:: 2.6 - - -These are the UTF-16 codec APIs: - -.. % --- UTF-16 Codecs ------------------------------------------------------ */ - - -.. cfunction:: PyObject* PyUnicode_DecodeUTF16(const char *s, Py_ssize_t size, const char *errors, int *byteorder) - - Decode *length* bytes from a UTF-16 encoded buffer string and return the - corresponding Unicode object. *errors* (if non-*NULL*) defines the error - handling. It defaults to "strict". - - If *byteorder* is non-*NULL*, the decoder starts decoding using the given byte - order:: - - *byteorder == -1: little endian - *byteorder == 0: native order - *byteorder == 1: big endian - - and then switches if the first two bytes of the input data are a byte order mark - (BOM) and the specified byte order is native order. This BOM is not copied into - the resulting Unicode string. After completion, *\*byteorder* is set to the - current byte order at the. - - If *byteorder* is *NULL*, the codec starts in native order mode. - - Return *NULL* if an exception was raised by the codec. - - -.. cfunction:: PyObject* PyUnicode_DecodeUTF16Stateful(const char *s, Py_ssize_t size, const char *errors, int *byteorder, Py_ssize_t *consumed) - - If *consumed* is *NULL*, behave like :cfunc:`PyUnicode_DecodeUTF16`. If - *consumed* is not *NULL*, :cfunc:`PyUnicode_DecodeUTF16Stateful` will not treat - trailing incomplete UTF-16 byte sequences (such as an odd number of bytes or a - split surrogate pair) as an error. Those bytes will not be decoded and the - number of bytes that have been decoded will be stored in *consumed*. - - .. versionadded:: 2.4 - - -.. cfunction:: PyObject* PyUnicode_EncodeUTF16(const Py_UNICODE *s, Py_ssize_t size, const char *errors, int byteorder) - - Return a Python string object holding the UTF-16 encoded value of the Unicode - data in *s*. If *byteorder* is not ``0``, output is written according to the - following byte order:: - - byteorder == -1: little endian - byteorder == 0: native byte order (writes a BOM mark) - byteorder == 1: big endian - - If byteorder is ``0``, the output string will always start with the Unicode BOM - mark (U+FEFF). In the other two modes, no BOM mark is prepended. - - If *Py_UNICODE_WIDE* is defined, a single :ctype:`Py_UNICODE` value may get - represented as a surrogate pair. If it is not defined, each :ctype:`Py_UNICODE` - values is interpreted as an UCS-2 character. - - Return *NULL* if an exception was raised by the codec. - - -.. cfunction:: PyObject* PyUnicode_AsUTF16String(PyObject *unicode) - - Return a Python string using the UTF-16 encoding in native byte order. The - string always starts with a BOM mark. Error handling is "strict". Return - *NULL* if an exception was raised by the codec. - -These are the "Unicode Escape" codec APIs: - -.. % --- Unicode-Escape Codecs ---------------------------------------------- - - -.. cfunction:: PyObject* PyUnicode_DecodeUnicodeEscape(const char *s, Py_ssize_t size, const char *errors) - - Create a Unicode object by decoding *size* bytes of the Unicode-Escape encoded - string *s*. Return *NULL* if an exception was raised by the codec. - - -.. cfunction:: PyObject* PyUnicode_EncodeUnicodeEscape(const Py_UNICODE *s, Py_ssize_t size) - - Encode the :ctype:`Py_UNICODE` buffer of the given size using Unicode-Escape and - return a Python string object. Return *NULL* if an exception was raised by the - codec. - - -.. cfunction:: PyObject* PyUnicode_AsUnicodeEscapeString(PyObject *unicode) - - Encode a Unicode object using Unicode-Escape and return the result as Python - string object. Error handling is "strict". Return *NULL* if an exception was - raised by the codec. - -These are the "Raw Unicode Escape" codec APIs: - -.. % --- Raw-Unicode-Escape Codecs ------------------------------------------ - - -.. cfunction:: PyObject* PyUnicode_DecodeRawUnicodeEscape(const char *s, Py_ssize_t size, const char *errors) - - Create a Unicode object by decoding *size* bytes of the Raw-Unicode-Escape - encoded string *s*. Return *NULL* if an exception was raised by the codec. - - -.. cfunction:: PyObject* PyUnicode_EncodeRawUnicodeEscape(const Py_UNICODE *s, Py_ssize_t size, const char *errors) - - Encode the :ctype:`Py_UNICODE` buffer of the given size using Raw-Unicode-Escape - and return a Python string object. Return *NULL* if an exception was raised by - the codec. - - -.. cfunction:: PyObject* PyUnicode_AsRawUnicodeEscapeString(PyObject *unicode) - - Encode a Unicode object using Raw-Unicode-Escape and return the result as - Python string object. Error handling is "strict". Return *NULL* if an exception - was raised by the codec. - -These are the Latin-1 codec APIs: Latin-1 corresponds to the first 256 Unicode -ordinals and only these are accepted by the codecs during encoding. - -.. % --- Latin-1 Codecs ----------------------------------------------------- - - -.. cfunction:: PyObject* PyUnicode_DecodeLatin1(const char *s, Py_ssize_t size, const char *errors) - - Create a Unicode object by decoding *size* bytes of the Latin-1 encoded string - *s*. Return *NULL* if an exception was raised by the codec. - - -.. cfunction:: PyObject* PyUnicode_EncodeLatin1(const Py_UNICODE *s, Py_ssize_t size, const char *errors) - - Encode the :ctype:`Py_UNICODE` buffer of the given size using Latin-1 and return - a Python string object. Return *NULL* if an exception was raised by the codec. - - -.. cfunction:: PyObject* PyUnicode_AsLatin1String(PyObject *unicode) - - Encode a Unicode object using Latin-1 and return the result as Python string - object. Error handling is "strict". Return *NULL* if an exception was raised - by the codec. - -These are the ASCII codec APIs. Only 7-bit ASCII data is accepted. All other -codes generate errors. - -.. % --- ASCII Codecs ------------------------------------------------------- - - -.. cfunction:: PyObject* PyUnicode_DecodeASCII(const char *s, Py_ssize_t size, const char *errors) - - Create a Unicode object by decoding *size* bytes of the ASCII encoded string - *s*. Return *NULL* if an exception was raised by the codec. - - -.. cfunction:: PyObject* PyUnicode_EncodeASCII(const Py_UNICODE *s, Py_ssize_t size, const char *errors) - - Encode the :ctype:`Py_UNICODE` buffer of the given size using ASCII and return a - Python string object. Return *NULL* if an exception was raised by the codec. - - -.. cfunction:: PyObject* PyUnicode_AsASCIIString(PyObject *unicode) - - Encode a Unicode object using ASCII and return the result as Python string - object. Error handling is "strict". Return *NULL* if an exception was raised - by the codec. - -These are the mapping codec APIs: - -.. % --- Character Map Codecs ----------------------------------------------- - -This codec is special in that it can be used to implement many different codecs -(and this is in fact what was done to obtain most of the standard codecs -included in the :mod:`encodings` package). The codec uses mapping to encode and -decode characters. - -Decoding mappings must map single string characters to single Unicode -characters, integers (which are then interpreted as Unicode ordinals) or None -(meaning "undefined mapping" and causing an error). - -Encoding mappings must map single Unicode characters to single string -characters, integers (which are then interpreted as Latin-1 ordinals) or None -(meaning "undefined mapping" and causing an error). - -The mapping objects provided must only support the __getitem__ mapping -interface. - -If a character lookup fails with a LookupError, the character is copied as-is -meaning that its ordinal value will be interpreted as Unicode or Latin-1 ordinal -resp. Because of this, mappings only need to contain those mappings which map -characters to different code points. - - -.. cfunction:: PyObject* PyUnicode_DecodeCharmap(const char *s, Py_ssize_t size, PyObject *mapping, const char *errors) - - Create a Unicode object by decoding *size* bytes of the encoded string *s* using - the given *mapping* object. Return *NULL* if an exception was raised by the - codec. If *mapping* is *NULL* latin-1 decoding will be done. Else it can be a - dictionary mapping byte or a unicode string, which is treated as a lookup table. - Byte values greater that the length of the string and U+FFFE "characters" are - treated as "undefined mapping". - - .. versionchanged:: 2.4 - Allowed unicode string as mapping argument. - - -.. cfunction:: PyObject* PyUnicode_EncodeCharmap(const Py_UNICODE *s, Py_ssize_t size, PyObject *mapping, const char *errors) - - Encode the :ctype:`Py_UNICODE` buffer of the given size using the given - *mapping* object and return a Python string object. Return *NULL* if an - exception was raised by the codec. - - -.. cfunction:: PyObject* PyUnicode_AsCharmapString(PyObject *unicode, PyObject *mapping) - - Encode a Unicode object using the given *mapping* object and return the result - as Python string object. Error handling is "strict". Return *NULL* if an - exception was raised by the codec. - -The following codec API is special in that maps Unicode to Unicode. - - -.. cfunction:: PyObject* PyUnicode_TranslateCharmap(const Py_UNICODE *s, Py_ssize_t size, PyObject *table, const char *errors) - - Translate a :ctype:`Py_UNICODE` buffer of the given length by applying a - character mapping *table* to it and return the resulting Unicode object. Return - *NULL* when an exception was raised by the codec. - - The *mapping* table must map Unicode ordinal integers to Unicode ordinal - integers or None (causing deletion of the character). - - Mapping tables need only provide the :meth:`__getitem__` interface; dictionaries - and sequences work well. Unmapped character ordinals (ones which cause a - :exc:`LookupError`) are left untouched and are copied as-is. - -These are the MBCS codec APIs. They are currently only available on Windows and -use the Win32 MBCS converters to implement the conversions. Note that MBCS (or -DBCS) is a class of encodings, not just one. The target encoding is defined by -the user settings on the machine running the codec. - -.. % --- MBCS codecs for Windows -------------------------------------------- - - -.. cfunction:: PyObject* PyUnicode_DecodeMBCS(const char *s, Py_ssize_t size, const char *errors) - - Create a Unicode object by decoding *size* bytes of the MBCS encoded string *s*. - Return *NULL* if an exception was raised by the codec. - - -.. cfunction:: PyObject* PyUnicode_DecodeMBCSStateful(const char *s, int size, const char *errors, int *consumed) - - If *consumed* is *NULL*, behave like :cfunc:`PyUnicode_DecodeMBCS`. If - *consumed* is not *NULL*, :cfunc:`PyUnicode_DecodeMBCSStateful` will not decode - trailing lead byte and the number of bytes that have been decoded will be stored - in *consumed*. - - .. versionadded:: 2.5 - - -.. cfunction:: PyObject* PyUnicode_EncodeMBCS(const Py_UNICODE *s, Py_ssize_t size, const char *errors) - - Encode the :ctype:`Py_UNICODE` buffer of the given size using MBCS and return a - Python string object. Return *NULL* if an exception was raised by the codec. - - -.. cfunction:: PyObject* PyUnicode_AsMBCSString(PyObject *unicode) - - Encode a Unicode object using MBCS and return the result as Python string - object. Error handling is "strict". Return *NULL* if an exception was raised - by the codec. - -.. % --- Methods & Slots ---------------------------------------------------- - - -.. _unicodemethodsandslots: - -Methods and Slot Functions -^^^^^^^^^^^^^^^^^^^^^^^^^^ - -The following APIs are capable of handling Unicode objects and strings on input -(we refer to them as strings in the descriptions) and return Unicode objects or -integers as appropriate. - -They all return *NULL* or ``-1`` if an exception occurs. - - -.. cfunction:: PyObject* PyUnicode_Concat(PyObject *left, PyObject *right) - - Concat two strings giving a new Unicode string. - - -.. cfunction:: PyObject* PyUnicode_Split(PyObject *s, PyObject *sep, Py_ssize_t maxsplit) - - Split a string giving a list of Unicode strings. If sep is *NULL*, splitting - will be done at all whitespace substrings. Otherwise, splits occur at the given - separator. At most *maxsplit* splits will be done. If negative, no limit is - set. Separators are not included in the resulting list. - - -.. cfunction:: PyObject* PyUnicode_Splitlines(PyObject *s, int keepend) - - Split a Unicode string at line breaks, returning a list of Unicode strings. - CRLF is considered to be one line break. If *keepend* is 0, the Line break - characters are not included in the resulting strings. - - -.. cfunction:: PyObject* PyUnicode_Translate(PyObject *str, PyObject *table, const char *errors) - - Translate a string by applying a character mapping table to it and return the - resulting Unicode object. - - The mapping table must map Unicode ordinal integers to Unicode ordinal integers - or None (causing deletion of the character). - - Mapping tables need only provide the :meth:`__getitem__` interface; dictionaries - and sequences work well. Unmapped character ordinals (ones which cause a - :exc:`LookupError`) are left untouched and are copied as-is. - - *errors* has the usual meaning for codecs. It may be *NULL* which indicates to - use the default error handling. - - -.. cfunction:: PyObject* PyUnicode_Join(PyObject *separator, PyObject *seq) - - Join a sequence of strings using the given separator and return the resulting - Unicode string. - - -.. cfunction:: int PyUnicode_Tailmatch(PyObject *str, PyObject *substr, Py_ssize_t start, Py_ssize_t end, int direction) - - Return 1 if *substr* matches *str*[*start*:*end*] at the given tail end - (*direction* == -1 means to do a prefix match, *direction* == 1 a suffix match), - 0 otherwise. Return ``-1`` if an error occurred. - - -.. cfunction:: Py_ssize_t PyUnicode_Find(PyObject *str, PyObject *substr, Py_ssize_t start, Py_ssize_t end, int direction) - - Return the first position of *substr* in *str*[*start*:*end*] using the given - *direction* (*direction* == 1 means to do a forward search, *direction* == -1 a - backward search). The return value is the index of the first match; a value of - ``-1`` indicates that no match was found, and ``-2`` indicates that an error - occurred and an exception has been set. - - -.. cfunction:: Py_ssize_t PyUnicode_Count(PyObject *str, PyObject *substr, Py_ssize_t start, Py_ssize_t end) - - Return the number of non-overlapping occurrences of *substr* in - ``str[start:end]``. Return ``-1`` if an error occurred. - - -.. cfunction:: PyObject* PyUnicode_Replace(PyObject *str, PyObject *substr, PyObject *replstr, Py_ssize_t maxcount) - - Replace at most *maxcount* occurrences of *substr* in *str* with *replstr* and - return the resulting Unicode object. *maxcount* == -1 means replace all - occurrences. - - -.. cfunction:: int PyUnicode_Compare(PyObject *left, PyObject *right) - - Compare two strings and return -1, 0, 1 for less than, equal, and greater than, - respectively. - - -.. cfunction:: int PyUnicode_RichCompare(PyObject *left, PyObject *right, int op) - - Rich compare two unicode strings and return one of the following: - - * ``NULL`` in case an exception was raised - * :const:`Py_True` or :const:`Py_False` for successful comparisons - * :const:`Py_NotImplemented` in case the type combination is unknown - - Note that :const:`Py_EQ` and :const:`Py_NE` comparisons can cause a - :exc:`UnicodeWarning` in case the conversion of the arguments to Unicode fails - with a :exc:`UnicodeDecodeError`. - - Possible values for *op* are :const:`Py_GT`, :const:`Py_GE`, :const:`Py_EQ`, - :const:`Py_NE`, :const:`Py_LT`, and :const:`Py_LE`. - - -.. cfunction:: PyObject* PyUnicode_Format(PyObject *format, PyObject *args) - - Return a new string object from *format* and *args*; this is analogous to - ``format % args``. The *args* argument must be a tuple. - - -.. cfunction:: int PyUnicode_Contains(PyObject *container, PyObject *element) - - Check whether *element* is contained in *container* and return true or false - accordingly. - - *element* has to coerce to a one element Unicode string. ``-1`` is returned if - there was an error. - - -.. _bufferobjects: - -Buffer Objects --------------- - -.. sectionauthor:: Greg Stein - - -.. index:: - object: buffer - single: buffer interface - -Python objects implemented in C can export a group of functions called the -"buffer interface." These functions can be used by an object to expose its data -in a raw, byte-oriented format. Clients of the object can use the buffer -interface to access the object data directly, without needing to copy it first. - -Two examples of objects that support the buffer interface are strings and -arrays. The string object exposes the character contents in the buffer -interface's byte-oriented form. An array can also expose its contents, but it -should be noted that array elements may be multi-byte values. - -An example user of the buffer interface is the file object's :meth:`write` -method. Any object that can export a series of bytes through the buffer -interface can be written to a file. There are a number of format codes to -:cfunc:`PyArg_ParseTuple` that operate against an object's buffer interface, -returning data from the target object. - -.. index:: single: PyBufferProcs - -More information on the buffer interface is provided in the section -:ref:`buffer-structs`, under the description for :ctype:`PyBufferProcs`. - -A "buffer object" is defined in the :file:`bufferobject.h` header (included by -:file:`Python.h`). These objects look very similar to string objects at the -Python programming level: they support slicing, indexing, concatenation, and -some other standard string operations. However, their data can come from one of -two sources: from a block of memory, or from another object which exports the -buffer interface. - -Buffer objects are useful as a way to expose the data from another object's -buffer interface to the Python programmer. They can also be used as a zero-copy -slicing mechanism. Using their ability to reference a block of memory, it is -possible to expose any data to the Python programmer quite easily. The memory -could be a large, constant array in a C extension, it could be a raw block of -memory for manipulation before passing to an operating system library, or it -could be used to pass around structured data in its native, in-memory format. - - -.. ctype:: PyBufferObject - - This subtype of :ctype:`PyObject` represents a buffer object. - - -.. cvar:: PyTypeObject PyBuffer_Type - - .. index:: single: BufferType (in module types) - - The instance of :ctype:`PyTypeObject` which represents the Python buffer type; - it is the same object as ``buffer`` and ``types.BufferType`` in the Python - layer. . - - -.. cvar:: int Py_END_OF_BUFFER - - This constant may be passed as the *size* parameter to - :cfunc:`PyBuffer_FromObject` or :cfunc:`PyBuffer_FromReadWriteObject`. It - indicates that the new :ctype:`PyBufferObject` should refer to *base* object - from the specified *offset* to the end of its exported buffer. Using this - enables the caller to avoid querying the *base* object for its length. - - -.. cfunction:: int PyBuffer_Check(PyObject *p) - - Return true if the argument has type :cdata:`PyBuffer_Type`. - - -.. cfunction:: PyObject* PyBuffer_FromObject(PyObject *base, Py_ssize_t offset, Py_ssize_t size) - - Return a new read-only buffer object. This raises :exc:`TypeError` if *base* - doesn't support the read-only buffer protocol or doesn't provide exactly one - buffer segment, or it raises :exc:`ValueError` if *offset* is less than zero. - The buffer will hold a reference to the *base* object, and the buffer's contents - will refer to the *base* object's buffer interface, starting as position - *offset* and extending for *size* bytes. If *size* is :const:`Py_END_OF_BUFFER`, - then the new buffer's contents extend to the length of the *base* object's - exported buffer data. - - -.. cfunction:: PyObject* PyBuffer_FromReadWriteObject(PyObject *base, Py_ssize_t offset, Py_ssize_t size) - - Return a new writable buffer object. Parameters and exceptions are similar to - those for :cfunc:`PyBuffer_FromObject`. If the *base* object does not export - the writeable buffer protocol, then :exc:`TypeError` is raised. - - -.. cfunction:: PyObject* PyBuffer_FromMemory(void *ptr, Py_ssize_t size) - - Return a new read-only buffer object that reads from a specified location in - memory, with a specified size. The caller is responsible for ensuring that the - memory buffer, passed in as *ptr*, is not deallocated while the returned buffer - object exists. Raises :exc:`ValueError` if *size* is less than zero. Note that - :const:`Py_END_OF_BUFFER` may *not* be passed for the *size* parameter; - :exc:`ValueError` will be raised in that case. - - -.. cfunction:: PyObject* PyBuffer_FromReadWriteMemory(void *ptr, Py_ssize_t size) - - Similar to :cfunc:`PyBuffer_FromMemory`, but the returned buffer is writable. - - -.. cfunction:: PyObject* PyBuffer_New(Py_ssize_t size) - - Return a new writable buffer object that maintains its own memory buffer of - *size* bytes. :exc:`ValueError` is returned if *size* is not zero or positive. - Note that the memory buffer (as returned by :cfunc:`PyObject_AsWriteBuffer`) is - not specifically aligned. - - -.. _tupleobjects: - -Tuple Objects -------------- - -.. index:: object: tuple - - -.. ctype:: PyTupleObject - - This subtype of :ctype:`PyObject` represents a Python tuple object. - - -.. cvar:: PyTypeObject PyTuple_Type - - .. index:: single: TupleType (in module types) - - This instance of :ctype:`PyTypeObject` represents the Python tuple type; it is - the same object as ``tuple`` and ``types.TupleType`` in the Python layer.. - - -.. cfunction:: int PyTuple_Check(PyObject *p) - - Return true if *p* is a tuple object or an instance of a subtype of the tuple - type. - - .. versionchanged:: 2.2 - Allowed subtypes to be accepted. - - -.. cfunction:: int PyTuple_CheckExact(PyObject *p) - - Return true if *p* is a tuple object, but not an instance of a subtype of the - tuple type. - - .. versionadded:: 2.2 - - -.. cfunction:: PyObject* PyTuple_New(Py_ssize_t len) - - Return a new tuple object of size *len*, or *NULL* on failure. - - -.. cfunction:: PyObject* PyTuple_Pack(Py_ssize_t n, ...) - - Return a new tuple object of size *n*, or *NULL* on failure. The tuple values - are initialized to the subsequent *n* C arguments pointing to Python objects. - ``PyTuple_Pack(2, a, b)`` is equivalent to ``Py_BuildValue("(OO)", a, b)``. - - .. versionadded:: 2.4 - - -.. cfunction:: Py_ssize_t PyTuple_Size(PyObject *p) - - Take a pointer to a tuple object, and return the size of that tuple. - - -.. cfunction:: Py_ssize_t PyTuple_GET_SIZE(PyObject *p) - - Return the size of the tuple *p*, which must be non-*NULL* and point to a tuple; - no error checking is performed. - - -.. cfunction:: PyObject* PyTuple_GetItem(PyObject *p, Py_ssize_t pos) - - Return the object at position *pos* in the tuple pointed to by *p*. If *pos* is - out of bounds, return *NULL* and sets an :exc:`IndexError` exception. - - -.. cfunction:: PyObject* PyTuple_GET_ITEM(PyObject *p, Py_ssize_t pos) - - Like :cfunc:`PyTuple_GetItem`, but does no checking of its arguments. - - -.. cfunction:: PyObject* PyTuple_GetSlice(PyObject *p, Py_ssize_t low, Py_ssize_t high) - - Take a slice of the tuple pointed to by *p* from *low* to *high* and return it - as a new tuple. - - -.. cfunction:: int PyTuple_SetItem(PyObject *p, Py_ssize_t pos, PyObject *o) - - Insert a reference to object *o* at position *pos* of the tuple pointed to by - *p*. Return ``0`` on success. - - .. note:: - - This function "steals" a reference to *o*. - - -.. cfunction:: void PyTuple_SET_ITEM(PyObject *p, Py_ssize_t pos, PyObject *o) - - Like :cfunc:`PyTuple_SetItem`, but does no error checking, and should *only* be - used to fill in brand new tuples. - - .. note:: - - This function "steals" a reference to *o*. - - -.. cfunction:: int _PyTuple_Resize(PyObject **p, Py_ssize_t newsize) - - Can be used to resize a tuple. *newsize* will be the new length of the tuple. - Because tuples are *supposed* to be immutable, this should only be used if there - is only one reference to the object. Do *not* use this if the tuple may already - be known to some other part of the code. The tuple will always grow or shrink - at the end. Think of this as destroying the old tuple and creating a new one, - only more efficiently. Returns ``0`` on success. Client code should never - assume that the resulting value of ``*p`` will be the same as before calling - this function. If the object referenced by ``*p`` is replaced, the original - ``*p`` is destroyed. On failure, returns ``-1`` and sets ``*p`` to *NULL*, and - raises :exc:`MemoryError` or :exc:`SystemError`. - - .. versionchanged:: 2.2 - Removed unused third parameter, *last_is_sticky*. - - -.. _listobjects: - -List Objects ------------- - -.. index:: object: list - - -.. ctype:: PyListObject - - This subtype of :ctype:`PyObject` represents a Python list object. - - -.. cvar:: PyTypeObject PyList_Type - - .. index:: single: ListType (in module types) - - This instance of :ctype:`PyTypeObject` represents the Python list type. This is - the same object as ``list`` and ``types.ListType`` in the Python layer. - - -.. cfunction:: int PyList_Check(PyObject *p) - - Return true if *p* is a list object or an instance of a subtype of the list - type. - - .. versionchanged:: 2.2 - Allowed subtypes to be accepted. - - -.. cfunction:: int PyList_CheckExact(PyObject *p) - - Return true if *p* is a list object, but not an instance of a subtype of the - list type. - - .. versionadded:: 2.2 - - -.. cfunction:: PyObject* PyList_New(Py_ssize_t len) - - Return a new list of length *len* on success, or *NULL* on failure. - - .. note:: - - If *length* is greater than zero, the returned list object's items are set to - ``NULL``. Thus you cannot use abstract API functions such as - :cfunc:`PySequence_SetItem` or expose the object to Python code before setting - all items to a real object with :cfunc:`PyList_SetItem`. - - -.. cfunction:: Py_ssize_t PyList_Size(PyObject *list) - - .. index:: builtin: len - - Return the length of the list object in *list*; this is equivalent to - ``len(list)`` on a list object. - - -.. cfunction:: Py_ssize_t PyList_GET_SIZE(PyObject *list) - - Macro form of :cfunc:`PyList_Size` without error checking. - - -.. cfunction:: PyObject* PyList_GetItem(PyObject *list, Py_ssize_t index) - - Return the object at position *pos* in the list pointed to by *p*. The position - must be positive, indexing from the end of the list is not supported. If *pos* - is out of bounds, return *NULL* and set an :exc:`IndexError` exception. - - -.. cfunction:: PyObject* PyList_GET_ITEM(PyObject *list, Py_ssize_t i) - - Macro form of :cfunc:`PyList_GetItem` without error checking. - - -.. cfunction:: int PyList_SetItem(PyObject *list, Py_ssize_t index, PyObject *item) - - Set the item at index *index* in list to *item*. Return ``0`` on success or - ``-1`` on failure. - - .. note:: - - This function "steals" a reference to *item* and discards a reference to an item - already in the list at the affected position. - - -.. cfunction:: void PyList_SET_ITEM(PyObject *list, Py_ssize_t i, PyObject *o) - - Macro form of :cfunc:`PyList_SetItem` without error checking. This is normally - only used to fill in new lists where there is no previous content. - - .. note:: - - This function "steals" a reference to *item*, and, unlike - :cfunc:`PyList_SetItem`, does *not* discard a reference to any item that it - being replaced; any reference in *list* at position *i* will be leaked. - - -.. cfunction:: int PyList_Insert(PyObject *list, Py_ssize_t index, PyObject *item) - - Insert the item *item* into list *list* in front of index *index*. Return ``0`` - if successful; return ``-1`` and set an exception if unsuccessful. Analogous to - ``list.insert(index, item)``. - - -.. cfunction:: int PyList_Append(PyObject *list, PyObject *item) - - Append the object *item* at the end of list *list*. Return ``0`` if successful; - return ``-1`` and set an exception if unsuccessful. Analogous to - ``list.append(item)``. - - -.. cfunction:: PyObject* PyList_GetSlice(PyObject *list, Py_ssize_t low, Py_ssize_t high) - - Return a list of the objects in *list* containing the objects *between* *low* - and *high*. Return *NULL* and set an exception if unsuccessful. Analogous to - ``list[low:high]``. - - -.. cfunction:: int PyList_SetSlice(PyObject *list, Py_ssize_t low, Py_ssize_t high, PyObject *itemlist) - - Set the slice of *list* between *low* and *high* to the contents of *itemlist*. - Analogous to ``list[low:high] = itemlist``. The *itemlist* may be *NULL*, - indicating the assignment of an empty list (slice deletion). Return ``0`` on - success, ``-1`` on failure. - - -.. cfunction:: int PyList_Sort(PyObject *list) - - Sort the items of *list* in place. Return ``0`` on success, ``-1`` on failure. - This is equivalent to ``list.sort()``. - - -.. cfunction:: int PyList_Reverse(PyObject *list) - - Reverse the items of *list* in place. Return ``0`` on success, ``-1`` on - failure. This is the equivalent of ``list.reverse()``. - - -.. cfunction:: PyObject* PyList_AsTuple(PyObject *list) - - .. index:: builtin: tuple - - Return a new tuple object containing the contents of *list*; equivalent to - ``tuple(list)``. - - -.. _mapobjects: - -Mapping Objects -=============== - -.. index:: object: mapping - - -.. _dictobjects: - -Dictionary Objects ------------------- - -.. index:: object: dictionary - - -.. ctype:: PyDictObject - - This subtype of :ctype:`PyObject` represents a Python dictionary object. - - -.. cvar:: PyTypeObject PyDict_Type - - .. index:: - single: DictType (in module types) - single: DictionaryType (in module types) - - This instance of :ctype:`PyTypeObject` represents the Python dictionary type. - This is exposed to Python programs as ``dict`` and ``types.DictType``. - - -.. cfunction:: int PyDict_Check(PyObject *p) - - Return true if *p* is a dict object or an instance of a subtype of the dict - type. - - .. versionchanged:: 2.2 - Allowed subtypes to be accepted. - - -.. cfunction:: int PyDict_CheckExact(PyObject *p) - - Return true if *p* is a dict object, but not an instance of a subtype of the - dict type. - - .. versionadded:: 2.4 - - -.. cfunction:: PyObject* PyDict_New() - - Return a new empty dictionary, or *NULL* on failure. - - -.. cfunction:: PyObject* PyDictProxy_New(PyObject *dict) - - Return a proxy object for a mapping which enforces read-only behavior. This is - normally used to create a proxy to prevent modification of the dictionary for - non-dynamic class types. - - .. versionadded:: 2.2 - - -.. cfunction:: void PyDict_Clear(PyObject *p) - - Empty an existing dictionary of all key-value pairs. - - -.. cfunction:: int PyDict_Contains(PyObject *p, PyObject *key) - - Determine if dictionary *p* contains *key*. If an item in *p* is matches *key*, - return ``1``, otherwise return ``0``. On error, return ``-1``. This is - equivalent to the Python expression ``key in p``. - - .. versionadded:: 2.4 - - -.. cfunction:: PyObject* PyDict_Copy(PyObject *p) - - Return a new dictionary that contains the same key-value pairs as *p*. - - .. versionadded:: 1.6 - - -.. cfunction:: int PyDict_SetItem(PyObject *p, PyObject *key, PyObject *val) - - Insert *value* into the dictionary *p* with a key of *key*. *key* must be - :term:`hashable`; if it isn't, :exc:`TypeError` will be raised. Return ``0`` - on success or ``-1`` on failure. - - -.. cfunction:: int PyDict_SetItemString(PyObject *p, const char *key, PyObject *val) - - .. index:: single: PyString_FromString() - - Insert *value* into the dictionary *p* using *key* as a key. *key* should be a - :ctype:`char\*`. The key object is created using ``PyString_FromString(key)``. - Return ``0`` on success or ``-1`` on failure. - - -.. cfunction:: int PyDict_DelItem(PyObject *p, PyObject *key) - - Remove the entry in dictionary *p* with key *key*. *key* must be hashable; if it - isn't, :exc:`TypeError` is raised. Return ``0`` on success or ``-1`` on - failure. - - -.. cfunction:: int PyDict_DelItemString(PyObject *p, char *key) - - Remove the entry in dictionary *p* which has a key specified by the string - *key*. Return ``0`` on success or ``-1`` on failure. - - -.. cfunction:: PyObject* PyDict_GetItem(PyObject *p, PyObject *key) - - Return the object from dictionary *p* which has a key *key*. Return *NULL* if - the key *key* is not present, but *without* setting an exception. - - -.. cfunction:: PyObject* PyDict_GetItemString(PyObject *p, const char *key) - - This is the same as :cfunc:`PyDict_GetItem`, but *key* is specified as a - :ctype:`char\*`, rather than a :ctype:`PyObject\*`. - - -.. cfunction:: PyObject* PyDict_Items(PyObject *p) - - Return a :ctype:`PyListObject` containing all the items from the dictionary, as - in the dictionary method :meth:`dict.items`. - - -.. cfunction:: PyObject* PyDict_Keys(PyObject *p) - - Return a :ctype:`PyListObject` containing all the keys from the dictionary, as - in the dictionary method :meth:`dict.keys`. - - -.. cfunction:: PyObject* PyDict_Values(PyObject *p) - - Return a :ctype:`PyListObject` containing all the values from the dictionary - *p*, as in the dictionary method :meth:`dict.values`. - - -.. cfunction:: Py_ssize_t PyDict_Size(PyObject *p) - - .. index:: builtin: len - - Return the number of items in the dictionary. This is equivalent to ``len(p)`` - on a dictionary. - - -.. cfunction:: int PyDict_Next(PyObject *p, Py_ssize_t *ppos, PyObject **pkey, PyObject **pvalue) - - Iterate over all key-value pairs in the dictionary *p*. The :ctype:`int` - referred to by *ppos* must be initialized to ``0`` prior to the first call to - this function to start the iteration; the function returns true for each pair in - the dictionary, and false once all pairs have been reported. The parameters - *pkey* and *pvalue* should either point to :ctype:`PyObject\*` variables that - will be filled in with each key and value, respectively, or may be *NULL*. Any - references returned through them are borrowed. *ppos* should not be altered - during iteration. Its value represents offsets within the internal dictionary - structure, and since the structure is sparse, the offsets are not consecutive. - - For example:: - - PyObject *key, *value; - Py_ssize_t pos = 0; - - while (PyDict_Next(self->dict, &pos, &key, &value)) { - /* do something interesting with the values... */ - ... - } - - The dictionary *p* should not be mutated during iteration. It is safe (since - Python 2.1) to modify the values of the keys as you iterate over the dictionary, - but only so long as the set of keys does not change. For example:: - - PyObject *key, *value; - Py_ssize_t pos = 0; - - while (PyDict_Next(self->dict, &pos, &key, &value)) { - int i = PyInt_AS_LONG(value) + 1; - PyObject *o = PyInt_FromLong(i); - if (o == NULL) - return -1; - if (PyDict_SetItem(self->dict, key, o) < 0) { - Py_DECREF(o); - return -1; - } - Py_DECREF(o); - } - - -.. cfunction:: int PyDict_Merge(PyObject *a, PyObject *b, int override) - - Iterate over mapping object *b* adding key-value pairs to dictionary *a*. *b* - may be a dictionary, or any object supporting :func:`PyMapping_Keys` and - :func:`PyObject_GetItem`. If *override* is true, existing pairs in *a* will be - replaced if a matching key is found in *b*, otherwise pairs will only be added - if there is not a matching key in *a*. Return ``0`` on success or ``-1`` if an - exception was raised. - - .. versionadded:: 2.2 - - -.. cfunction:: int PyDict_Update(PyObject *a, PyObject *b) - - This is the same as ``PyDict_Merge(a, b, 1)`` in C, or ``a.update(b)`` in - Python. Return ``0`` on success or ``-1`` if an exception was raised. - - .. versionadded:: 2.2 - - -.. cfunction:: int PyDict_MergeFromSeq2(PyObject *a, PyObject *seq2, int override) - - Update or merge into dictionary *a*, from the key-value pairs in *seq2*. *seq2* - must be an iterable object producing iterable objects of length 2, viewed as - key-value pairs. In case of duplicate keys, the last wins if *override* is - true, else the first wins. Return ``0`` on success or ``-1`` if an exception was - raised. Equivalent Python (except for the return value):: - - def PyDict_MergeFromSeq2(a, seq2, override): - for key, value in seq2: - if override or key not in a: - a[key] = value - - .. versionadded:: 2.2 - - -.. _otherobjects: - -Other Objects -============= - - -.. _classobjects: - -Class Objects -------------- - -.. index:: object: class - -Note that the class objects described here represent old-style classes, which -will go away in Python 3. When creating new types for extension modules, you -will want to work with type objects (section :ref:`typeobjects`). - - -.. ctype:: PyClassObject - - The C structure of the objects used to describe built-in classes. - - -.. cvar:: PyObject* PyClass_Type - - .. index:: single: ClassType (in module types) - - This is the type object for class objects; it is the same object as - ``types.ClassType`` in the Python layer. - - -.. cfunction:: int PyClass_Check(PyObject *o) - - Return true if the object *o* is a class object, including instances of types - derived from the standard class object. Return false in all other cases. - - -.. cfunction:: int PyClass_IsSubclass(PyObject *klass, PyObject *base) - - Return true if *klass* is a subclass of *base*. Return false in all other cases. - - -.. _fileobjects: - -File Objects ------------- - -.. index:: object: file - -Python's built-in file objects are implemented entirely on the :ctype:`FILE\*` -support from the C standard library. This is an implementation detail and may -change in future releases of Python. - - -.. ctype:: PyFileObject - - This subtype of :ctype:`PyObject` represents a Python file object. - - -.. cvar:: PyTypeObject PyFile_Type - - .. index:: single: FileType (in module types) - - This instance of :ctype:`PyTypeObject` represents the Python file type. This is - exposed to Python programs as ``file`` and ``types.FileType``. - - -.. cfunction:: int PyFile_Check(PyObject *p) - - Return true if its argument is a :ctype:`PyFileObject` or a subtype of - :ctype:`PyFileObject`. - - .. versionchanged:: 2.2 - Allowed subtypes to be accepted. - - -.. cfunction:: int PyFile_CheckExact(PyObject *p) - - Return true if its argument is a :ctype:`PyFileObject`, but not a subtype of - :ctype:`PyFileObject`. - - .. versionadded:: 2.2 - - -.. cfunction:: PyObject* PyFile_FromString(char *filename, char *mode) - - .. index:: single: fopen() - - On success, return a new file object that is opened on the file given by - *filename*, with a file mode given by *mode*, where *mode* has the same - semantics as the standard C routine :cfunc:`fopen`. On failure, return *NULL*. - - -.. cfunction:: PyObject* PyFile_FromFile(FILE *fp, char *name, char *mode, int (*close)(FILE*)) - - Create a new :ctype:`PyFileObject` from the already-open standard C file - pointer, *fp*. The function *close* will be called when the file should be - closed. Return *NULL* on failure. - - -.. cfunction:: FILE* PyFile_AsFile(PyObject *p) - - Return the file object associated with *p* as a :ctype:`FILE\*`. - - -.. cfunction:: PyObject* PyFile_GetLine(PyObject *p, int n) - - .. index:: single: EOFError (built-in exception) - - Equivalent to ``p.readline([n])``, this function reads one line from the - object *p*. *p* may be a file object or any object with a :meth:`readline` - method. If *n* is ``0``, exactly one line is read, regardless of the length of - the line. If *n* is greater than ``0``, no more than *n* bytes will be read - from the file; a partial line can be returned. In both cases, an empty string - is returned if the end of the file is reached immediately. If *n* is less than - ``0``, however, one line is read regardless of length, but :exc:`EOFError` is - raised if the end of the file is reached immediately. - - -.. cfunction:: PyObject* PyFile_Name(PyObject *p) - - Return the name of the file specified by *p* as a string object. - - -.. cfunction:: void PyFile_SetBufSize(PyFileObject *p, int n) - - .. index:: single: setvbuf() - - Available on systems with :cfunc:`setvbuf` only. This should only be called - immediately after file object creation. - - -.. cfunction:: int PyFile_SetEncoding(PyFileObject *p, const char *enc) - - Set the file's encoding for Unicode output to *enc*. Return 1 on success and 0 - on failure. - - .. versionadded:: 2.3 - - -.. cfunction:: int PyFile_SoftSpace(PyObject *p, int newflag) - - .. index:: single: softspace (file attribute) - - This function exists for internal use by the interpreter. Set the - :attr:`softspace` attribute of *p* to *newflag* and return the previous value. - *p* does not have to be a file object for this function to work properly; any - object is supported (thought its only interesting if the :attr:`softspace` - attribute can be set). This function clears any errors, and will return ``0`` - as the previous value if the attribute either does not exist or if there were - errors in retrieving it. There is no way to detect errors from this function, - but doing so should not be needed. - - -.. cfunction:: int PyFile_WriteObject(PyObject *obj, PyObject *p, int flags) - - .. index:: single: Py_PRINT_RAW - - Write object *obj* to file object *p*. The only supported flag for *flags* is - :const:`Py_PRINT_RAW`; if given, the :func:`str` of the object is written - instead of the :func:`repr`. Return ``0`` on success or ``-1`` on failure; the - appropriate exception will be set. - - -.. cfunction:: int PyFile_WriteString(const char *s, PyObject *p) - - Write string *s* to file object *p*. Return ``0`` on success or ``-1`` on - failure; the appropriate exception will be set. - - -.. _instanceobjects: - -Instance Objects ----------------- - -.. index:: object: instance - -There are very few functions specific to instance objects. - - -.. cvar:: PyTypeObject PyInstance_Type - - Type object for class instances. - - -.. cfunction:: int PyInstance_Check(PyObject *obj) - - Return true if *obj* is an instance. - - -.. cfunction:: PyObject* PyInstance_New(PyObject *class, PyObject *arg, PyObject *kw) - - Create a new instance of a specific class. The parameters *arg* and *kw* are - used as the positional and keyword parameters to the object's constructor. - - -.. cfunction:: PyObject* PyInstance_NewRaw(PyObject *class, PyObject *dict) - - Create a new instance of a specific class without calling its constructor. - *class* is the class of new object. The *dict* parameter will be used as the - object's :attr:`__dict__`; if *NULL*, a new dictionary will be created for the - instance. - - -.. _function-objects: - -Function Objects ----------------- - -.. index:: object: function - -There are a few functions specific to Python functions. - - -.. ctype:: PyFunctionObject - - The C structure used for functions. - - -.. cvar:: PyTypeObject PyFunction_Type - - .. index:: single: MethodType (in module types) - - This is an instance of :ctype:`PyTypeObject` and represents the Python function - type. It is exposed to Python programmers as ``types.FunctionType``. - - -.. cfunction:: int PyFunction_Check(PyObject *o) - - Return true if *o* is a function object (has type :cdata:`PyFunction_Type`). - The parameter must not be *NULL*. - - -.. cfunction:: PyObject* PyFunction_New(PyObject *code, PyObject *globals) - - Return a new function object associated with the code object *code*. *globals* - must be a dictionary with the global variables accessible to the function. - - The function's docstring, name and *__module__* are retrieved from the code - object, the argument defaults and closure are set to *NULL*. - - -.. cfunction:: PyObject* PyFunction_GetCode(PyObject *op) - - Return the code object associated with the function object *op*. - - -.. cfunction:: PyObject* PyFunction_GetGlobals(PyObject *op) - - Return the globals dictionary associated with the function object *op*. - - -.. cfunction:: PyObject* PyFunction_GetModule(PyObject *op) - - Return the *__module__* attribute of the function object *op*. This is normally - a string containing the module name, but can be set to any other object by - Python code. - - -.. cfunction:: PyObject* PyFunction_GetDefaults(PyObject *op) - - Return the argument default values of the function object *op*. This can be a - tuple of arguments or *NULL*. - - -.. cfunction:: int PyFunction_SetDefaults(PyObject *op, PyObject *defaults) - - Set the argument default values for the function object *op*. *defaults* must be - *Py_None* or a tuple. - - Raises :exc:`SystemError` and returns ``-1`` on failure. - - -.. cfunction:: PyObject* PyFunction_GetClosure(PyObject *op) - - Return the closure associated with the function object *op*. This can be *NULL* - or a tuple of cell objects. - - -.. cfunction:: int PyFunction_SetClosure(PyObject *op, PyObject *closure) - - Set the closure associated with the function object *op*. *closure* must be - *Py_None* or a tuple of cell objects. - - Raises :exc:`SystemError` and returns ``-1`` on failure. - - -.. _method-objects: - -Method Objects --------------- - -.. index:: object: method - -There are some useful functions that are useful for working with method objects. - - -.. cvar:: PyTypeObject PyMethod_Type - - .. index:: single: MethodType (in module types) - - This instance of :ctype:`PyTypeObject` represents the Python method type. This - is exposed to Python programs as ``types.MethodType``. - - -.. cfunction:: int PyMethod_Check(PyObject *o) - - Return true if *o* is a method object (has type :cdata:`PyMethod_Type`). The - parameter must not be *NULL*. - - -.. cfunction:: PyObject* PyMethod_New(PyObject *func, PyObject *self, PyObject *class) - - Return a new method object, with *func* being any callable object; this is the - function that will be called when the method is called. If this method should - be bound to an instance, *self* should be the instance and *class* should be the - class of *self*, otherwise *self* should be *NULL* and *class* should be the - class which provides the unbound method.. - - -.. cfunction:: PyObject* PyMethod_Class(PyObject *meth) - - Return the class object from which the method *meth* was created; if this was - created from an instance, it will be the class of the instance. - - -.. cfunction:: PyObject* PyMethod_GET_CLASS(PyObject *meth) - - Macro version of :cfunc:`PyMethod_Class` which avoids error checking. - - -.. cfunction:: PyObject* PyMethod_Function(PyObject *meth) - - Return the function object associated with the method *meth*. - - -.. cfunction:: PyObject* PyMethod_GET_FUNCTION(PyObject *meth) - - Macro version of :cfunc:`PyMethod_Function` which avoids error checking. - - -.. cfunction:: PyObject* PyMethod_Self(PyObject *meth) - - Return the instance associated with the method *meth* if it is bound, otherwise - return *NULL*. - - -.. cfunction:: PyObject* PyMethod_GET_SELF(PyObject *meth) - - Macro version of :cfunc:`PyMethod_Self` which avoids error checking. - - -.. _moduleobjects: - -Module Objects --------------- - -.. index:: object: module - -There are only a few functions special to module objects. - - -.. cvar:: PyTypeObject PyModule_Type - - .. index:: single: ModuleType (in module types) - - This instance of :ctype:`PyTypeObject` represents the Python module type. This - is exposed to Python programs as ``types.ModuleType``. - - -.. cfunction:: int PyModule_Check(PyObject *p) - - Return true if *p* is a module object, or a subtype of a module object. - - .. versionchanged:: 2.2 - Allowed subtypes to be accepted. - - -.. cfunction:: int PyModule_CheckExact(PyObject *p) - - Return true if *p* is a module object, but not a subtype of - :cdata:`PyModule_Type`. - - .. versionadded:: 2.2 - - -.. cfunction:: PyObject* PyModule_New(const char *name) - - .. index:: - single: __name__ (module attribute) - single: __doc__ (module attribute) - single: __file__ (module attribute) - - Return a new module object with the :attr:`__name__` attribute set to *name*. - Only the module's :attr:`__doc__` and :attr:`__name__` attributes are filled in; - the caller is responsible for providing a :attr:`__file__` attribute. - - -.. cfunction:: PyObject* PyModule_GetDict(PyObject *module) - - .. index:: single: __dict__ (module attribute) - - Return the dictionary object that implements *module*'s namespace; this object - is the same as the :attr:`__dict__` attribute of the module object. This - function never fails. It is recommended extensions use other - :cfunc:`PyModule_\*` and :cfunc:`PyObject_\*` functions rather than directly - manipulate a module's :attr:`__dict__`. - - -.. cfunction:: char* PyModule_GetName(PyObject *module) - - .. index:: - single: __name__ (module attribute) - single: SystemError (built-in exception) - - Return *module*'s :attr:`__name__` value. If the module does not provide one, - or if it is not a string, :exc:`SystemError` is raised and *NULL* is returned. - - -.. cfunction:: char* PyModule_GetFilename(PyObject *module) - - .. index:: - single: __file__ (module attribute) - single: SystemError (built-in exception) - - Return the name of the file from which *module* was loaded using *module*'s - :attr:`__file__` attribute. If this is not defined, or if it is not a string, - raise :exc:`SystemError` and return *NULL*. - - -.. cfunction:: int PyModule_AddObject(PyObject *module, const char *name, PyObject *value) - - Add an object to *module* as *name*. This is a convenience function which can - be used from the module's initialization function. This steals a reference to - *value*. Return ``-1`` on error, ``0`` on success. - - .. versionadded:: 2.0 - - -.. cfunction:: int PyModule_AddIntConstant(PyObject *module, const char *name, long value) - - Add an integer constant to *module* as *name*. This convenience function can be - used from the module's initialization function. Return ``-1`` on error, ``0`` on - success. - - .. versionadded:: 2.0 - - -.. cfunction:: int PyModule_AddStringConstant(PyObject *module, const char *name, const char *value) - - Add a string constant to *module* as *name*. This convenience function can be - used from the module's initialization function. The string *value* must be - null-terminated. Return ``-1`` on error, ``0`` on success. - - .. versionadded:: 2.0 - - -.. _iterator-objects: - -Iterator Objects ----------------- - -Python provides two general-purpose iterator objects. The first, a sequence -iterator, works with an arbitrary sequence supporting the :meth:`__getitem__` -method. The second works with a callable object and a sentinel value, calling -the callable for each item in the sequence, and ending the iteration when the -sentinel value is returned. - - -.. cvar:: PyTypeObject PySeqIter_Type - - Type object for iterator objects returned by :cfunc:`PySeqIter_New` and the - one-argument form of the :func:`iter` built-in function for built-in sequence - types. - - .. versionadded:: 2.2 - - -.. cfunction:: int PySeqIter_Check(op) - - Return true if the type of *op* is :cdata:`PySeqIter_Type`. - - .. versionadded:: 2.2 - - -.. cfunction:: PyObject* PySeqIter_New(PyObject *seq) - - Return an iterator that works with a general sequence object, *seq*. The - iteration ends when the sequence raises :exc:`IndexError` for the subscripting - operation. - - .. versionadded:: 2.2 - - -.. cvar:: PyTypeObject PyCallIter_Type - - Type object for iterator objects returned by :cfunc:`PyCallIter_New` and the - two-argument form of the :func:`iter` built-in function. - - .. versionadded:: 2.2 - - -.. cfunction:: int PyCallIter_Check(op) - - Return true if the type of *op* is :cdata:`PyCallIter_Type`. - - .. versionadded:: 2.2 - - -.. cfunction:: PyObject* PyCallIter_New(PyObject *callable, PyObject *sentinel) - - Return a new iterator. The first parameter, *callable*, can be any Python - callable object that can be called with no parameters; each call to it should - return the next item in the iteration. When *callable* returns a value equal to - *sentinel*, the iteration will be terminated. - - .. versionadded:: 2.2 - - -.. _descriptor-objects: - -Descriptor Objects ------------------- - -"Descriptors" are objects that describe some attribute of an object. They are -found in the dictionary of type objects. - - -.. cvar:: PyTypeObject PyProperty_Type - - The type object for the built-in descriptor types. - - .. versionadded:: 2.2 - - -.. cfunction:: PyObject* PyDescr_NewGetSet(PyTypeObject *type, struct PyGetSetDef *getset) - - .. versionadded:: 2.2 - - -.. cfunction:: PyObject* PyDescr_NewMember(PyTypeObject *type, struct PyMemberDef *meth) - - .. versionadded:: 2.2 - - -.. cfunction:: PyObject* PyDescr_NewMethod(PyTypeObject *type, struct PyMethodDef *meth) - - .. versionadded:: 2.2 - - -.. cfunction:: PyObject* PyDescr_NewWrapper(PyTypeObject *type, struct wrapperbase *wrapper, void *wrapped) - - .. versionadded:: 2.2 - - -.. cfunction:: PyObject* PyDescr_NewClassMethod(PyTypeObject *type, PyMethodDef *method) - - .. versionadded:: 2.3 - - -.. cfunction:: int PyDescr_IsData(PyObject *descr) - - Return true if the descriptor objects *descr* describes a data attribute, or - false if it describes a method. *descr* must be a descriptor object; there is - no error checking. - - .. versionadded:: 2.2 - - -.. cfunction:: PyObject* PyWrapper_New(PyObject *, PyObject *) - - .. versionadded:: 2.2 - - -.. _slice-objects: - -Slice Objects -------------- - - -.. cvar:: PyTypeObject PySlice_Type - - .. index:: single: SliceType (in module types) - - The type object for slice objects. This is the same as ``slice`` and - ``types.SliceType``. - - -.. cfunction:: int PySlice_Check(PyObject *ob) - - Return true if *ob* is a slice object; *ob* must not be *NULL*. - - -.. cfunction:: PyObject* PySlice_New(PyObject *start, PyObject *stop, PyObject *step) - - Return a new slice object with the given values. The *start*, *stop*, and - *step* parameters are used as the values of the slice object attributes of the - same names. Any of the values may be *NULL*, in which case the ``None`` will be - used for the corresponding attribute. Return *NULL* if the new object could not - be allocated. - - -.. cfunction:: int PySlice_GetIndices(PySliceObject *slice, Py_ssize_t length, Py_ssize_t *start, Py_ssize_t *stop, Py_ssize_t *step) - - Retrieve the start, stop and step indices from the slice object *slice*, - assuming a sequence of length *length*. Treats indices greater than *length* as - errors. - - Returns 0 on success and -1 on error with no exception set (unless one of the - indices was not :const:`None` and failed to be converted to an integer, in which - case -1 is returned with an exception set). - - You probably do not want to use this function. If you want to use slice objects - in versions of Python prior to 2.3, you would probably do well to incorporate - the source of :cfunc:`PySlice_GetIndicesEx`, suitably renamed, in the source of - your extension. - - -.. cfunction:: int PySlice_GetIndicesEx(PySliceObject *slice, Py_ssize_t length, Py_ssize_t *start, Py_ssize_t *stop, Py_ssize_t *step, Py_ssize_t *slicelength) - - Usable replacement for :cfunc:`PySlice_GetIndices`. Retrieve the start, stop, - and step indices from the slice object *slice* assuming a sequence of length - *length*, and store the length of the slice in *slicelength*. Out of bounds - indices are clipped in a manner consistent with the handling of normal slices. - - Returns 0 on success and -1 on error with exception set. - - .. versionadded:: 2.3 - - -.. _weakrefobjects: - -Weak Reference Objects ----------------------- - -Python supports *weak references* as first-class objects. There are two -specific object types which directly implement weak references. The first is a -simple reference object, and the second acts as a proxy for the original object -as much as it can. - - -.. cfunction:: int PyWeakref_Check(ob) - - Return true if *ob* is either a reference or proxy object. - - .. versionadded:: 2.2 - - -.. cfunction:: int PyWeakref_CheckRef(ob) - - Return true if *ob* is a reference object. - - .. versionadded:: 2.2 - - -.. cfunction:: int PyWeakref_CheckProxy(ob) - - Return true if *ob* is a proxy object. - - .. versionadded:: 2.2 - - -.. cfunction:: PyObject* PyWeakref_NewRef(PyObject *ob, PyObject *callback) - - Return a weak reference object for the object *ob*. This will always return - a new reference, but is not guaranteed to create a new object; an existing - reference object may be returned. The second parameter, *callback*, can be a - callable object that receives notification when *ob* is garbage collected; it - should accept a single parameter, which will be the weak reference object - itself. *callback* may also be ``None`` or *NULL*. If *ob* is not a - weakly-referencable object, or if *callback* is not callable, ``None``, or - *NULL*, this will return *NULL* and raise :exc:`TypeError`. - - .. versionadded:: 2.2 - - -.. cfunction:: PyObject* PyWeakref_NewProxy(PyObject *ob, PyObject *callback) - - Return a weak reference proxy object for the object *ob*. This will always - return a new reference, but is not guaranteed to create a new object; an - existing proxy object may be returned. The second parameter, *callback*, can - be a callable object that receives notification when *ob* is garbage - collected; it should accept a single parameter, which will be the weak - reference object itself. *callback* may also be ``None`` or *NULL*. If *ob* - is not a weakly-referencable object, or if *callback* is not callable, - ``None``, or *NULL*, this will return *NULL* and raise :exc:`TypeError`. - - .. versionadded:: 2.2 - - -.. cfunction:: PyObject* PyWeakref_GetObject(PyObject *ref) - - Return the referenced object from a weak reference, *ref*. If the referent is - no longer live, returns ``None``. - - .. versionadded:: 2.2 - - -.. cfunction:: PyObject* PyWeakref_GET_OBJECT(PyObject *ref) - - Similar to :cfunc:`PyWeakref_GetObject`, but implemented as a macro that does no - error checking. - - .. versionadded:: 2.2 - - -.. _cobjects: - -CObjects --------- - -.. index:: object: CObject - -Refer to *Extending and Embedding the Python Interpreter*, section 1.12, -"Providing a C API for an Extension Module," for more information on using these -objects. - - -.. ctype:: PyCObject - - This subtype of :ctype:`PyObject` represents an opaque value, useful for C - extension modules who need to pass an opaque value (as a :ctype:`void\*` - pointer) through Python code to other C code. It is often used to make a C - function pointer defined in one module available to other modules, so the - regular import mechanism can be used to access C APIs defined in dynamically - loaded modules. - - -.. cfunction:: int PyCObject_Check(PyObject *p) - - Return true if its argument is a :ctype:`PyCObject`. - - -.. cfunction:: PyObject* PyCObject_FromVoidPtr(void* cobj, void (*destr)(void *)) - - Create a :ctype:`PyCObject` from the ``void *`` *cobj*. The *destr* function - will be called when the object is reclaimed, unless it is *NULL*. - - -.. cfunction:: PyObject* PyCObject_FromVoidPtrAndDesc(void* cobj, void* desc, void (*destr)(void *, void *)) - - Create a :ctype:`PyCObject` from the :ctype:`void \*` *cobj*. The *destr* - function will be called when the object is reclaimed. The *desc* argument can - be used to pass extra callback data for the destructor function. - - -.. cfunction:: void* PyCObject_AsVoidPtr(PyObject* self) - - Return the object :ctype:`void \*` that the :ctype:`PyCObject` *self* was - created with. - - -.. cfunction:: void* PyCObject_GetDesc(PyObject* self) - - Return the description :ctype:`void \*` that the :ctype:`PyCObject` *self* was - created with. - - -.. cfunction:: int PyCObject_SetVoidPtr(PyObject* self, void* cobj) - - Set the void pointer inside *self* to *cobj*. The :ctype:`PyCObject` must not - have an associated destructor. Return true on success, false on failure. - - -.. _cell-objects: - -Cell Objects ------------- - -"Cell" objects are used to implement variables referenced by multiple scopes. -For each such variable, a cell object is created to store the value; the local -variables of each stack frame that references the value contains a reference to -the cells from outer scopes which also use that variable. When the value is -accessed, the value contained in the cell is used instead of the cell object -itself. This de-referencing of the cell object requires support from the -generated byte-code; these are not automatically de-referenced when accessed. -Cell objects are not likely to be useful elsewhere. - - -.. ctype:: PyCellObject - - The C structure used for cell objects. - - -.. cvar:: PyTypeObject PyCell_Type - - The type object corresponding to cell objects. - - -.. cfunction:: int PyCell_Check(ob) - - Return true if *ob* is a cell object; *ob* must not be *NULL*. - - -.. cfunction:: PyObject* PyCell_New(PyObject *ob) - - Create and return a new cell object containing the value *ob*. The parameter may - be *NULL*. - - -.. cfunction:: PyObject* PyCell_Get(PyObject *cell) - - Return the contents of the cell *cell*. - - -.. cfunction:: PyObject* PyCell_GET(PyObject *cell) - - Return the contents of the cell *cell*, but without checking that *cell* is - non-*NULL* and a cell object. - - -.. cfunction:: int PyCell_Set(PyObject *cell, PyObject *value) - - Set the contents of the cell object *cell* to *value*. This releases the - reference to any current content of the cell. *value* may be *NULL*. *cell* - must be non-*NULL*; if it is not a cell object, ``-1`` will be returned. On - success, ``0`` will be returned. - - -.. cfunction:: void PyCell_SET(PyObject *cell, PyObject *value) - - Sets the value of the cell object *cell* to *value*. No reference counts are - adjusted, and no checks are made for safety; *cell* must be non-*NULL* and must - be a cell object. - - -.. _gen-objects: - -Generator Objects ------------------ - -Generator objects are what Python uses to implement generator iterators. They -are normally created by iterating over a function that yields values, rather -than explicitly calling :cfunc:`PyGen_New`. - - -.. ctype:: PyGenObject - - The C structure used for generator objects. - - -.. cvar:: PyTypeObject PyGen_Type - - The type object corresponding to generator objects - - -.. cfunction:: int PyGen_Check(ob) - - Return true if *ob* is a generator object; *ob* must not be *NULL*. - - -.. cfunction:: int PyGen_CheckExact(ob) - - Return true if *ob*'s type is *PyGen_Type* is a generator object; *ob* must not - be *NULL*. - - -.. cfunction:: PyObject* PyGen_New(PyFrameObject *frame) - - Create and return a new generator object based on the *frame* object. A - reference to *frame* is stolen by this function. The parameter must not be - *NULL*. - - -.. _datetimeobjects: - -DateTime Objects ----------------- - -Various date and time objects are supplied by the :mod:`datetime` module. -Before using any of these functions, the header file :file:`datetime.h` must be -included in your source (note that this is not included by :file:`Python.h`), -and the macro :cfunc:`PyDateTime_IMPORT` must be invoked. The macro puts a -pointer to a C structure into a static variable, ``PyDateTimeAPI``, that is -used by the following macros. - -Type-check macros: - - -.. cfunction:: int PyDate_Check(PyObject *ob) - - Return true if *ob* is of type :cdata:`PyDateTime_DateType` or a subtype of - :cdata:`PyDateTime_DateType`. *ob* must not be *NULL*. - - .. versionadded:: 2.4 - - -.. cfunction:: int PyDate_CheckExact(PyObject *ob) - - Return true if *ob* is of type :cdata:`PyDateTime_DateType`. *ob* must not be - *NULL*. - - .. versionadded:: 2.4 - - -.. cfunction:: int PyDateTime_Check(PyObject *ob) - - Return true if *ob* is of type :cdata:`PyDateTime_DateTimeType` or a subtype of - :cdata:`PyDateTime_DateTimeType`. *ob* must not be *NULL*. - - .. versionadded:: 2.4 - - -.. cfunction:: int PyDateTime_CheckExact(PyObject *ob) - - Return true if *ob* is of type :cdata:`PyDateTime_DateTimeType`. *ob* must not - be *NULL*. - - .. versionadded:: 2.4 - - -.. cfunction:: int PyTime_Check(PyObject *ob) - - Return true if *ob* is of type :cdata:`PyDateTime_TimeType` or a subtype of - :cdata:`PyDateTime_TimeType`. *ob* must not be *NULL*. - - .. versionadded:: 2.4 - - -.. cfunction:: int PyTime_CheckExact(PyObject *ob) - - Return true if *ob* is of type :cdata:`PyDateTime_TimeType`. *ob* must not be - *NULL*. - - .. versionadded:: 2.4 - - -.. cfunction:: int PyDelta_Check(PyObject *ob) - - Return true if *ob* is of type :cdata:`PyDateTime_DeltaType` or a subtype of - :cdata:`PyDateTime_DeltaType`. *ob* must not be *NULL*. - - .. versionadded:: 2.4 - - -.. cfunction:: int PyDelta_CheckExact(PyObject *ob) - - Return true if *ob* is of type :cdata:`PyDateTime_DeltaType`. *ob* must not be - *NULL*. - - .. versionadded:: 2.4 - - -.. cfunction:: int PyTZInfo_Check(PyObject *ob) - - Return true if *ob* is of type :cdata:`PyDateTime_TZInfoType` or a subtype of - :cdata:`PyDateTime_TZInfoType`. *ob* must not be *NULL*. - - .. versionadded:: 2.4 - - -.. cfunction:: int PyTZInfo_CheckExact(PyObject *ob) - - Return true if *ob* is of type :cdata:`PyDateTime_TZInfoType`. *ob* must not be - *NULL*. - - .. versionadded:: 2.4 - -Macros to create objects: - - -.. cfunction:: PyObject* PyDate_FromDate(int year, int month, int day) - - Return a ``datetime.date`` object with the specified year, month and day. - - .. versionadded:: 2.4 - - -.. cfunction:: PyObject* PyDateTime_FromDateAndTime(int year, int month, int day, int hour, int minute, int second, int usecond) - - Return a ``datetime.datetime`` object with the specified year, month, day, hour, - minute, second and microsecond. - - .. versionadded:: 2.4 - - -.. cfunction:: PyObject* PyTime_FromTime(int hour, int minute, int second, int usecond) - - Return a ``datetime.time`` object with the specified hour, minute, second and - microsecond. - - .. versionadded:: 2.4 - - -.. cfunction:: PyObject* PyDelta_FromDSU(int days, int seconds, int useconds) - - Return a ``datetime.timedelta`` object representing the given number of days, - seconds and microseconds. Normalization is performed so that the resulting - number of microseconds and seconds lie in the ranges documented for - ``datetime.timedelta`` objects. - - .. versionadded:: 2.4 - -Macros to extract fields from date objects. The argument must be an instance of -:cdata:`PyDateTime_Date`, including subclasses (such as -:cdata:`PyDateTime_DateTime`). The argument must not be *NULL*, and the type is -not checked: - - -.. cfunction:: int PyDateTime_GET_YEAR(PyDateTime_Date *o) - - Return the year, as a positive int. - - .. versionadded:: 2.4 - - -.. cfunction:: int PyDateTime_GET_MONTH(PyDateTime_Date *o) - - Return the month, as an int from 1 through 12. - - .. versionadded:: 2.4 - - -.. cfunction:: int PyDateTime_GET_DAY(PyDateTime_Date *o) - - Return the day, as an int from 1 through 31. - - .. versionadded:: 2.4 - -Macros to extract fields from datetime objects. The argument must be an -instance of :cdata:`PyDateTime_DateTime`, including subclasses. The argument -must not be *NULL*, and the type is not checked: - - -.. cfunction:: int PyDateTime_DATE_GET_HOUR(PyDateTime_DateTime *o) - - Return the hour, as an int from 0 through 23. - - .. versionadded:: 2.4 - - -.. cfunction:: int PyDateTime_DATE_GET_MINUTE(PyDateTime_DateTime *o) - - Return the minute, as an int from 0 through 59. - - .. versionadded:: 2.4 - - -.. cfunction:: int PyDateTime_DATE_GET_SECOND(PyDateTime_DateTime *o) - - Return the second, as an int from 0 through 59. - - .. versionadded:: 2.4 - - -.. cfunction:: int PyDateTime_DATE_GET_MICROSECOND(PyDateTime_DateTime *o) - - Return the microsecond, as an int from 0 through 999999. - - .. versionadded:: 2.4 - -Macros to extract fields from time objects. The argument must be an instance of -:cdata:`PyDateTime_Time`, including subclasses. The argument must not be *NULL*, -and the type is not checked: - - -.. cfunction:: int PyDateTime_TIME_GET_HOUR(PyDateTime_Time *o) - - Return the hour, as an int from 0 through 23. - - .. versionadded:: 2.4 - - -.. cfunction:: int PyDateTime_TIME_GET_MINUTE(PyDateTime_Time *o) - - Return the minute, as an int from 0 through 59. - - .. versionadded:: 2.4 - - -.. cfunction:: int PyDateTime_TIME_GET_SECOND(PyDateTime_Time *o) - - Return the second, as an int from 0 through 59. - - .. versionadded:: 2.4 - - -.. cfunction:: int PyDateTime_TIME_GET_MICROSECOND(PyDateTime_Time *o) - - Return the microsecond, as an int from 0 through 999999. - - .. versionadded:: 2.4 - -Macros for the convenience of modules implementing the DB API: - - -.. cfunction:: PyObject* PyDateTime_FromTimestamp(PyObject *args) - - Create and return a new ``datetime.datetime`` object given an argument tuple - suitable for passing to ``datetime.datetime.fromtimestamp()``. - - .. versionadded:: 2.4 - - -.. cfunction:: PyObject* PyDate_FromTimestamp(PyObject *args) - - Create and return a new ``datetime.date`` object given an argument tuple - suitable for passing to ``datetime.date.fromtimestamp()``. - - .. versionadded:: 2.4 - - -.. _setobjects: - -Set Objects ------------ - -.. sectionauthor:: Raymond D. Hettinger - - -.. index:: - object: set - object: frozenset - -.. versionadded:: 2.5 - -This section details the public API for :class:`set` and :class:`frozenset` -objects. Any functionality not listed below is best accessed using the either -the abstract object protocol (including :cfunc:`PyObject_CallMethod`, -:cfunc:`PyObject_RichCompareBool`, :cfunc:`PyObject_Hash`, -:cfunc:`PyObject_Repr`, :cfunc:`PyObject_IsTrue`, :cfunc:`PyObject_Print`, and -:cfunc:`PyObject_GetIter`) or the abstract number protocol (including -:cfunc:`PyNumber_And`, :cfunc:`PyNumber_Subtract`, :cfunc:`PyNumber_Or`, -:cfunc:`PyNumber_Xor`, :cfunc:`PyNumber_InPlaceAnd`, -:cfunc:`PyNumber_InPlaceSubtract`, :cfunc:`PyNumber_InPlaceOr`, and -:cfunc:`PyNumber_InPlaceXor`). - - -.. ctype:: PySetObject - - This subtype of :ctype:`PyObject` is used to hold the internal data for both - :class:`set` and :class:`frozenset` objects. It is like a :ctype:`PyDictObject` - in that it is a fixed size for small sets (much like tuple storage) and will - point to a separate, variable sized block of memory for medium and large sized - sets (much like list storage). None of the fields of this structure should be - considered public and are subject to change. All access should be done through - the documented API rather than by manipulating the values in the structure. - - -.. cvar:: PyTypeObject PySet_Type - - This is an instance of :ctype:`PyTypeObject` representing the Python - :class:`set` type. - - -.. cvar:: PyTypeObject PyFrozenSet_Type - - This is an instance of :ctype:`PyTypeObject` representing the Python - :class:`frozenset` type. - -The following type check macros work on pointers to any Python object. Likewise, -the constructor functions work with any iterable Python object. - - -.. cfunction:: int PyAnySet_Check(PyObject *p) - - Return true if *p* is a :class:`set` object, a :class:`frozenset` object, or an - instance of a subtype. - - -.. cfunction:: int PyAnySet_CheckExact(PyObject *p) - - Return true if *p* is a :class:`set` object or a :class:`frozenset` object but - not an instance of a subtype. - - -.. cfunction:: int PyFrozenSet_CheckExact(PyObject *p) - - Return true if *p* is a :class:`frozenset` object but not an instance of a - subtype. - - -.. cfunction:: PyObject* PySet_New(PyObject *iterable) - - Return a new :class:`set` containing objects returned by the *iterable*. The - *iterable* may be *NULL* to create a new empty set. Return the new set on - success or *NULL* on failure. Raise :exc:`TypeError` if *iterable* is not - actually iterable. The constructor is also useful for copying a set - (``c=set(s)``). - - -.. cfunction:: PyObject* PyFrozenSet_New(PyObject *iterable) - - Return a new :class:`frozenset` containing objects returned by the *iterable*. - The *iterable* may be *NULL* to create a new empty frozenset. Return the new - set on success or *NULL* on failure. Raise :exc:`TypeError` if *iterable* is - not actually iterable. - -The following functions and macros are available for instances of :class:`set` -or :class:`frozenset` or instances of their subtypes. - - -.. cfunction:: Py_ssize_t PySet_Size(PyObject *anyset) - - .. index:: builtin: len - - Return the length of a :class:`set` or :class:`frozenset` object. Equivalent to - ``len(anyset)``. Raises a :exc:`PyExc_SystemError` if *anyset* is not a - :class:`set`, :class:`frozenset`, or an instance of a subtype. - - -.. cfunction:: Py_ssize_t PySet_GET_SIZE(PyObject *anyset) - - Macro form of :cfunc:`PySet_Size` without error checking. - - -.. cfunction:: int PySet_Contains(PyObject *anyset, PyObject *key) - - Return 1 if found, 0 if not found, and -1 if an error is encountered. Unlike - the Python :meth:`__contains__` method, this function does not automatically - convert unhashable sets into temporary frozensets. Raise a :exc:`TypeError` if - the *key* is unhashable. Raise :exc:`PyExc_SystemError` if *anyset* is not a - :class:`set`, :class:`frozenset`, or an instance of a subtype. - -The following functions are available for instances of :class:`set` or its -subtypes but not for instances of :class:`frozenset` or its subtypes. - - -.. cfunction:: int PySet_Add(PyObject *set, PyObject *key) - - Add *key* to a :class:`set` instance. Does not apply to :class:`frozenset` - instances. Return 0 on success or -1 on failure. Raise a :exc:`TypeError` if - the *key* is unhashable. Raise a :exc:`MemoryError` if there is no room to grow. - Raise a :exc:`SystemError` if *set* is an not an instance of :class:`set` or its - subtype. - - -.. cfunction:: int PySet_Discard(PyObject *set, PyObject *key) - - Return 1 if found and removed, 0 if not found (no action taken), and -1 if an - error is encountered. Does not raise :exc:`KeyError` for missing keys. Raise a - :exc:`TypeError` if the *key* is unhashable. Unlike the Python :meth:`discard` - method, this function does not automatically convert unhashable sets into - temporary frozensets. Raise :exc:`PyExc_SystemError` if *set* is an not an - instance of :class:`set` or its subtype. - - -.. cfunction:: PyObject* PySet_Pop(PyObject *set) - - Return a new reference to an arbitrary object in the *set*, and removes the - object from the *set*. Return *NULL* on failure. Raise :exc:`KeyError` if the - set is empty. Raise a :exc:`SystemError` if *set* is an not an instance of - :class:`set` or its subtype. - - -.. cfunction:: int PySet_Clear(PyObject *set) +Other Objects +============= - Empty an existing set of all elements. +.. toctree:: + class.rst + function.rst + method.rst + file.rst + module.rst + iterator.rst + descriptor.rst + slice.rst + weakref.rst + cobject.rst + cell.rst + gen.rst + datetime.rst + set.rst Added: python/trunk/Doc/c-api/datetime.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/c-api/datetime.rst Sat Jan 19 23:08:21 2008 @@ -0,0 +1,238 @@ +.. highlightlang:: c + +.. _datetimeobjects: + +DateTime Objects +---------------- + +Various date and time objects are supplied by the :mod:`datetime` module. +Before using any of these functions, the header file :file:`datetime.h` must be +included in your source (note that this is not included by :file:`Python.h`), +and the macro :cfunc:`PyDateTime_IMPORT` must be invoked. The macro puts a +pointer to a C structure into a static variable, ``PyDateTimeAPI``, that is +used by the following macros. + +Type-check macros: + + +.. cfunction:: int PyDate_Check(PyObject *ob) + + Return true if *ob* is of type :cdata:`PyDateTime_DateType` or a subtype of + :cdata:`PyDateTime_DateType`. *ob* must not be *NULL*. + + .. versionadded:: 2.4 + + +.. cfunction:: int PyDate_CheckExact(PyObject *ob) + + Return true if *ob* is of type :cdata:`PyDateTime_DateType`. *ob* must not be + *NULL*. + + .. versionadded:: 2.4 + + +.. cfunction:: int PyDateTime_Check(PyObject *ob) + + Return true if *ob* is of type :cdata:`PyDateTime_DateTimeType` or a subtype of + :cdata:`PyDateTime_DateTimeType`. *ob* must not be *NULL*. + + .. versionadded:: 2.4 + + +.. cfunction:: int PyDateTime_CheckExact(PyObject *ob) + + Return true if *ob* is of type :cdata:`PyDateTime_DateTimeType`. *ob* must not + be *NULL*. + + .. versionadded:: 2.4 + + +.. cfunction:: int PyTime_Check(PyObject *ob) + + Return true if *ob* is of type :cdata:`PyDateTime_TimeType` or a subtype of + :cdata:`PyDateTime_TimeType`. *ob* must not be *NULL*. + + .. versionadded:: 2.4 + + +.. cfunction:: int PyTime_CheckExact(PyObject *ob) + + Return true if *ob* is of type :cdata:`PyDateTime_TimeType`. *ob* must not be + *NULL*. + + .. versionadded:: 2.4 + + +.. cfunction:: int PyDelta_Check(PyObject *ob) + + Return true if *ob* is of type :cdata:`PyDateTime_DeltaType` or a subtype of + :cdata:`PyDateTime_DeltaType`. *ob* must not be *NULL*. + + .. versionadded:: 2.4 + + +.. cfunction:: int PyDelta_CheckExact(PyObject *ob) + + Return true if *ob* is of type :cdata:`PyDateTime_DeltaType`. *ob* must not be + *NULL*. + + .. versionadded:: 2.4 + + +.. cfunction:: int PyTZInfo_Check(PyObject *ob) + + Return true if *ob* is of type :cdata:`PyDateTime_TZInfoType` or a subtype of + :cdata:`PyDateTime_TZInfoType`. *ob* must not be *NULL*. + + .. versionadded:: 2.4 + + +.. cfunction:: int PyTZInfo_CheckExact(PyObject *ob) + + Return true if *ob* is of type :cdata:`PyDateTime_TZInfoType`. *ob* must not be + *NULL*. + + .. versionadded:: 2.4 + +Macros to create objects: + + +.. cfunction:: PyObject* PyDate_FromDate(int year, int month, int day) + + Return a ``datetime.date`` object with the specified year, month and day. + + .. versionadded:: 2.4 + + +.. cfunction:: PyObject* PyDateTime_FromDateAndTime(int year, int month, int day, int hour, int minute, int second, int usecond) + + Return a ``datetime.datetime`` object with the specified year, month, day, hour, + minute, second and microsecond. + + .. versionadded:: 2.4 + + +.. cfunction:: PyObject* PyTime_FromTime(int hour, int minute, int second, int usecond) + + Return a ``datetime.time`` object with the specified hour, minute, second and + microsecond. + + .. versionadded:: 2.4 + + +.. cfunction:: PyObject* PyDelta_FromDSU(int days, int seconds, int useconds) + + Return a ``datetime.timedelta`` object representing the given number of days, + seconds and microseconds. Normalization is performed so that the resulting + number of microseconds and seconds lie in the ranges documented for + ``datetime.timedelta`` objects. + + .. versionadded:: 2.4 + +Macros to extract fields from date objects. The argument must be an instance of +:cdata:`PyDateTime_Date`, including subclasses (such as +:cdata:`PyDateTime_DateTime`). The argument must not be *NULL*, and the type is +not checked: + + +.. cfunction:: int PyDateTime_GET_YEAR(PyDateTime_Date *o) + + Return the year, as a positive int. + + .. versionadded:: 2.4 + + +.. cfunction:: int PyDateTime_GET_MONTH(PyDateTime_Date *o) + + Return the month, as an int from 1 through 12. + + .. versionadded:: 2.4 + + +.. cfunction:: int PyDateTime_GET_DAY(PyDateTime_Date *o) + + Return the day, as an int from 1 through 31. + + .. versionadded:: 2.4 + +Macros to extract fields from datetime objects. The argument must be an +instance of :cdata:`PyDateTime_DateTime`, including subclasses. The argument +must not be *NULL*, and the type is not checked: + + +.. cfunction:: int PyDateTime_DATE_GET_HOUR(PyDateTime_DateTime *o) + + Return the hour, as an int from 0 through 23. + + .. versionadded:: 2.4 + + +.. cfunction:: int PyDateTime_DATE_GET_MINUTE(PyDateTime_DateTime *o) + + Return the minute, as an int from 0 through 59. + + .. versionadded:: 2.4 + + +.. cfunction:: int PyDateTime_DATE_GET_SECOND(PyDateTime_DateTime *o) + + Return the second, as an int from 0 through 59. + + .. versionadded:: 2.4 + + +.. cfunction:: int PyDateTime_DATE_GET_MICROSECOND(PyDateTime_DateTime *o) + + Return the microsecond, as an int from 0 through 999999. + + .. versionadded:: 2.4 + +Macros to extract fields from time objects. The argument must be an instance of +:cdata:`PyDateTime_Time`, including subclasses. The argument must not be *NULL*, +and the type is not checked: + + +.. cfunction:: int PyDateTime_TIME_GET_HOUR(PyDateTime_Time *o) + + Return the hour, as an int from 0 through 23. + + .. versionadded:: 2.4 + + +.. cfunction:: int PyDateTime_TIME_GET_MINUTE(PyDateTime_Time *o) + + Return the minute, as an int from 0 through 59. + + .. versionadded:: 2.4 + + +.. cfunction:: int PyDateTime_TIME_GET_SECOND(PyDateTime_Time *o) + + Return the second, as an int from 0 through 59. + + .. versionadded:: 2.4 + + +.. cfunction:: int PyDateTime_TIME_GET_MICROSECOND(PyDateTime_Time *o) + + Return the microsecond, as an int from 0 through 999999. + + .. versionadded:: 2.4 + +Macros for the convenience of modules implementing the DB API: + + +.. cfunction:: PyObject* PyDateTime_FromTimestamp(PyObject *args) + + Create and return a new ``datetime.datetime`` object given an argument tuple + suitable for passing to ``datetime.datetime.fromtimestamp()``. + + .. versionadded:: 2.4 + + +.. cfunction:: PyObject* PyDate_FromTimestamp(PyObject *args) + + Create and return a new ``datetime.date`` object given an argument tuple + suitable for passing to ``datetime.date.fromtimestamp()``. + + .. versionadded:: 2.4 Added: python/trunk/Doc/c-api/descriptor.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/c-api/descriptor.rst Sat Jan 19 23:08:21 2008 @@ -0,0 +1,55 @@ +.. highlightlang:: c + +.. _descriptor-objects: + +Descriptor Objects +------------------ + +"Descriptors" are objects that describe some attribute of an object. They are +found in the dictionary of type objects. + + +.. cvar:: PyTypeObject PyProperty_Type + + The type object for the built-in descriptor types. + + .. versionadded:: 2.2 + + +.. cfunction:: PyObject* PyDescr_NewGetSet(PyTypeObject *type, struct PyGetSetDef *getset) + + .. versionadded:: 2.2 + + +.. cfunction:: PyObject* PyDescr_NewMember(PyTypeObject *type, struct PyMemberDef *meth) + + .. versionadded:: 2.2 + + +.. cfunction:: PyObject* PyDescr_NewMethod(PyTypeObject *type, struct PyMethodDef *meth) + + .. versionadded:: 2.2 + + +.. cfunction:: PyObject* PyDescr_NewWrapper(PyTypeObject *type, struct wrapperbase *wrapper, void *wrapped) + + .. versionadded:: 2.2 + + +.. cfunction:: PyObject* PyDescr_NewClassMethod(PyTypeObject *type, PyMethodDef *method) + + .. versionadded:: 2.3 + + +.. cfunction:: int PyDescr_IsData(PyObject *descr) + + Return true if the descriptor objects *descr* describes a data attribute, or + false if it describes a method. *descr* must be a descriptor object; there is + no error checking. + + .. versionadded:: 2.2 + + +.. cfunction:: PyObject* PyWrapper_New(PyObject *, PyObject *) + + .. versionadded:: 2.2 Added: python/trunk/Doc/c-api/dict.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/c-api/dict.rst Sat Jan 19 23:08:21 2008 @@ -0,0 +1,220 @@ +.. highlightlang:: c + +.. _dictobjects: + +Dictionary Objects +------------------ + +.. index:: object: dictionary + + +.. ctype:: PyDictObject + + This subtype of :ctype:`PyObject` represents a Python dictionary object. + + +.. cvar:: PyTypeObject PyDict_Type + + .. index:: + single: DictType (in module types) + single: DictionaryType (in module types) + + This instance of :ctype:`PyTypeObject` represents the Python dictionary type. + This is exposed to Python programs as ``dict`` and ``types.DictType``. + + +.. cfunction:: int PyDict_Check(PyObject *p) + + Return true if *p* is a dict object or an instance of a subtype of the dict + type. + + .. versionchanged:: 2.2 + Allowed subtypes to be accepted. + + +.. cfunction:: int PyDict_CheckExact(PyObject *p) + + Return true if *p* is a dict object, but not an instance of a subtype of the + dict type. + + .. versionadded:: 2.4 + + +.. cfunction:: PyObject* PyDict_New() + + Return a new empty dictionary, or *NULL* on failure. + + +.. cfunction:: PyObject* PyDictProxy_New(PyObject *dict) + + Return a proxy object for a mapping which enforces read-only behavior. This is + normally used to create a proxy to prevent modification of the dictionary for + non-dynamic class types. + + .. versionadded:: 2.2 + + +.. cfunction:: void PyDict_Clear(PyObject *p) + + Empty an existing dictionary of all key-value pairs. + + +.. cfunction:: int PyDict_Contains(PyObject *p, PyObject *key) + + Determine if dictionary *p* contains *key*. If an item in *p* is matches *key*, + return ``1``, otherwise return ``0``. On error, return ``-1``. This is + equivalent to the Python expression ``key in p``. + + .. versionadded:: 2.4 + + +.. cfunction:: PyObject* PyDict_Copy(PyObject *p) + + Return a new dictionary that contains the same key-value pairs as *p*. + + .. versionadded:: 1.6 + + +.. cfunction:: int PyDict_SetItem(PyObject *p, PyObject *key, PyObject *val) + + Insert *value* into the dictionary *p* with a key of *key*. *key* must be + :term:`hashable`; if it isn't, :exc:`TypeError` will be raised. Return ``0`` + on success or ``-1`` on failure. + + +.. cfunction:: int PyDict_SetItemString(PyObject *p, const char *key, PyObject *val) + + .. index:: single: PyString_FromString() + + Insert *value* into the dictionary *p* using *key* as a key. *key* should be a + :ctype:`char\*`. The key object is created using ``PyString_FromString(key)``. + Return ``0`` on success or ``-1`` on failure. + + +.. cfunction:: int PyDict_DelItem(PyObject *p, PyObject *key) + + Remove the entry in dictionary *p* with key *key*. *key* must be hashable; if it + isn't, :exc:`TypeError` is raised. Return ``0`` on success or ``-1`` on + failure. + + +.. cfunction:: int PyDict_DelItemString(PyObject *p, char *key) + + Remove the entry in dictionary *p* which has a key specified by the string + *key*. Return ``0`` on success or ``-1`` on failure. + + +.. cfunction:: PyObject* PyDict_GetItem(PyObject *p, PyObject *key) + + Return the object from dictionary *p* which has a key *key*. Return *NULL* if + the key *key* is not present, but *without* setting an exception. + + +.. cfunction:: PyObject* PyDict_GetItemString(PyObject *p, const char *key) + + This is the same as :cfunc:`PyDict_GetItem`, but *key* is specified as a + :ctype:`char\*`, rather than a :ctype:`PyObject\*`. + + +.. cfunction:: PyObject* PyDict_Items(PyObject *p) + + Return a :ctype:`PyListObject` containing all the items from the dictionary, as + in the dictionary method :meth:`dict.items`. + + +.. cfunction:: PyObject* PyDict_Keys(PyObject *p) + + Return a :ctype:`PyListObject` containing all the keys from the dictionary, as + in the dictionary method :meth:`dict.keys`. + + +.. cfunction:: PyObject* PyDict_Values(PyObject *p) + + Return a :ctype:`PyListObject` containing all the values from the dictionary + *p*, as in the dictionary method :meth:`dict.values`. + + +.. cfunction:: Py_ssize_t PyDict_Size(PyObject *p) + + .. index:: builtin: len + + Return the number of items in the dictionary. This is equivalent to ``len(p)`` + on a dictionary. + + +.. cfunction:: int PyDict_Next(PyObject *p, Py_ssize_t *ppos, PyObject **pkey, PyObject **pvalue) + + Iterate over all key-value pairs in the dictionary *p*. The :ctype:`int` + referred to by *ppos* must be initialized to ``0`` prior to the first call to + this function to start the iteration; the function returns true for each pair in + the dictionary, and false once all pairs have been reported. The parameters + *pkey* and *pvalue* should either point to :ctype:`PyObject\*` variables that + will be filled in with each key and value, respectively, or may be *NULL*. Any + references returned through them are borrowed. *ppos* should not be altered + during iteration. Its value represents offsets within the internal dictionary + structure, and since the structure is sparse, the offsets are not consecutive. + + For example:: + + PyObject *key, *value; + Py_ssize_t pos = 0; + + while (PyDict_Next(self->dict, &pos, &key, &value)) { + /* do something interesting with the values... */ + ... + } + + The dictionary *p* should not be mutated during iteration. It is safe (since + Python 2.1) to modify the values of the keys as you iterate over the dictionary, + but only so long as the set of keys does not change. For example:: + + PyObject *key, *value; + Py_ssize_t pos = 0; + + while (PyDict_Next(self->dict, &pos, &key, &value)) { + int i = PyInt_AS_LONG(value) + 1; + PyObject *o = PyInt_FromLong(i); + if (o == NULL) + return -1; + if (PyDict_SetItem(self->dict, key, o) < 0) { + Py_DECREF(o); + return -1; + } + Py_DECREF(o); + } + + +.. cfunction:: int PyDict_Merge(PyObject *a, PyObject *b, int override) + + Iterate over mapping object *b* adding key-value pairs to dictionary *a*. *b* + may be a dictionary, or any object supporting :func:`PyMapping_Keys` and + :func:`PyObject_GetItem`. If *override* is true, existing pairs in *a* will be + replaced if a matching key is found in *b*, otherwise pairs will only be added + if there is not a matching key in *a*. Return ``0`` on success or ``-1`` if an + exception was raised. + + .. versionadded:: 2.2 + + +.. cfunction:: int PyDict_Update(PyObject *a, PyObject *b) + + This is the same as ``PyDict_Merge(a, b, 1)`` in C, or ``a.update(b)`` in + Python. Return ``0`` on success or ``-1`` if an exception was raised. + + .. versionadded:: 2.2 + + +.. cfunction:: int PyDict_MergeFromSeq2(PyObject *a, PyObject *seq2, int override) + + Update or merge into dictionary *a*, from the key-value pairs in *seq2*. *seq2* + must be an iterable object producing iterable objects of length 2, viewed as + key-value pairs. In case of duplicate keys, the last wins if *override* is + true, else the first wins. Return ``0`` on success or ``-1`` if an exception was + raised. Equivalent Python (except for the return value):: + + def PyDict_MergeFromSeq2(a, seq2, override): + for key, value in seq2: + if override or key not in a: + a[key] = value + + .. versionadded:: 2.2 Added: python/trunk/Doc/c-api/file.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/c-api/file.rst Sat Jan 19 23:08:21 2008 @@ -0,0 +1,128 @@ +.. highlightlang:: c + +.. _fileobjects: + +File Objects +------------ + +.. index:: object: file + +Python's built-in file objects are implemented entirely on the :ctype:`FILE\*` +support from the C standard library. This is an implementation detail and may +change in future releases of Python. + + +.. ctype:: PyFileObject + + This subtype of :ctype:`PyObject` represents a Python file object. + + +.. cvar:: PyTypeObject PyFile_Type + + .. index:: single: FileType (in module types) + + This instance of :ctype:`PyTypeObject` represents the Python file type. This is + exposed to Python programs as ``file`` and ``types.FileType``. + + +.. cfunction:: int PyFile_Check(PyObject *p) + + Return true if its argument is a :ctype:`PyFileObject` or a subtype of + :ctype:`PyFileObject`. + + .. versionchanged:: 2.2 + Allowed subtypes to be accepted. + + +.. cfunction:: int PyFile_CheckExact(PyObject *p) + + Return true if its argument is a :ctype:`PyFileObject`, but not a subtype of + :ctype:`PyFileObject`. + + .. versionadded:: 2.2 + + +.. cfunction:: PyObject* PyFile_FromString(char *filename, char *mode) + + .. index:: single: fopen() + + On success, return a new file object that is opened on the file given by + *filename*, with a file mode given by *mode*, where *mode* has the same + semantics as the standard C routine :cfunc:`fopen`. On failure, return *NULL*. + + +.. cfunction:: PyObject* PyFile_FromFile(FILE *fp, char *name, char *mode, int (*close)(FILE*)) + + Create a new :ctype:`PyFileObject` from the already-open standard C file + pointer, *fp*. The function *close* will be called when the file should be + closed. Return *NULL* on failure. + + +.. cfunction:: FILE* PyFile_AsFile(PyObject *p) + + Return the file object associated with *p* as a :ctype:`FILE\*`. + + +.. cfunction:: PyObject* PyFile_GetLine(PyObject *p, int n) + + .. index:: single: EOFError (built-in exception) + + Equivalent to ``p.readline([n])``, this function reads one line from the + object *p*. *p* may be a file object or any object with a :meth:`readline` + method. If *n* is ``0``, exactly one line is read, regardless of the length of + the line. If *n* is greater than ``0``, no more than *n* bytes will be read + from the file; a partial line can be returned. In both cases, an empty string + is returned if the end of the file is reached immediately. If *n* is less than + ``0``, however, one line is read regardless of length, but :exc:`EOFError` is + raised if the end of the file is reached immediately. + + +.. cfunction:: PyObject* PyFile_Name(PyObject *p) + + Return the name of the file specified by *p* as a string object. + + +.. cfunction:: void PyFile_SetBufSize(PyFileObject *p, int n) + + .. index:: single: setvbuf() + + Available on systems with :cfunc:`setvbuf` only. This should only be called + immediately after file object creation. + + +.. cfunction:: int PyFile_SetEncoding(PyFileObject *p, const char *enc) + + Set the file's encoding for Unicode output to *enc*. Return 1 on success and 0 + on failure. + + .. versionadded:: 2.3 + + +.. cfunction:: int PyFile_SoftSpace(PyObject *p, int newflag) + + .. index:: single: softspace (file attribute) + + This function exists for internal use by the interpreter. Set the + :attr:`softspace` attribute of *p* to *newflag* and return the previous value. + *p* does not have to be a file object for this function to work properly; any + object is supported (thought its only interesting if the :attr:`softspace` + attribute can be set). This function clears any errors, and will return ``0`` + as the previous value if the attribute either does not exist or if there were + errors in retrieving it. There is no way to detect errors from this function, + but doing so should not be needed. + + +.. cfunction:: int PyFile_WriteObject(PyObject *obj, PyObject *p, int flags) + + .. index:: single: Py_PRINT_RAW + + Write object *obj* to file object *p*. The only supported flag for *flags* is + :const:`Py_PRINT_RAW`; if given, the :func:`str` of the object is written + instead of the :func:`repr`. Return ``0`` on success or ``-1`` on failure; the + appropriate exception will be set. + + +.. cfunction:: int PyFile_WriteString(const char *s, PyObject *p) + + Write string *s* to file object *p*. Return ``0`` on success or ``-1`` on + failure; the appropriate exception will be set. Added: python/trunk/Doc/c-api/float.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/c-api/float.rst Sat Jan 19 23:08:21 2008 @@ -0,0 +1,86 @@ +.. highlightlang:: c + +.. _floatobjects: + +Floating Point Objects +---------------------- + +.. index:: object: floating point + + +.. ctype:: PyFloatObject + + This subtype of :ctype:`PyObject` represents a Python floating point object. + + +.. cvar:: PyTypeObject PyFloat_Type + + .. index:: single: FloatType (in modules types) + + This instance of :ctype:`PyTypeObject` represents the Python floating point + type. This is the same object as ``float`` and ``types.FloatType``. + + +.. cfunction:: int PyFloat_Check(PyObject *p) + + Return true if its argument is a :ctype:`PyFloatObject` or a subtype of + :ctype:`PyFloatObject`. + + .. versionchanged:: 2.2 + Allowed subtypes to be accepted. + + +.. cfunction:: int PyFloat_CheckExact(PyObject *p) + + Return true if its argument is a :ctype:`PyFloatObject`, but not a subtype of + :ctype:`PyFloatObject`. + + .. versionadded:: 2.2 + + +.. cfunction:: PyObject* PyFloat_FromString(PyObject *str, char **pend) + + Create a :ctype:`PyFloatObject` object based on the string value in *str*, or + *NULL* on failure. The *pend* argument is ignored. It remains only for + backward compatibility. + + +.. cfunction:: PyObject* PyFloat_FromDouble(double v) + + Create a :ctype:`PyFloatObject` object from *v*, or *NULL* on failure. + + +.. cfunction:: double PyFloat_AsDouble(PyObject *pyfloat) + + Return a C :ctype:`double` representation of the contents of *pyfloat*. If + *pyfloat* is not a Python floating point object but has a :meth:`__float__` + method, this method will first be called to convert *pyfloat* into a float. + + +.. cfunction:: double PyFloat_AS_DOUBLE(PyObject *pyfloat) + + Return a C :ctype:`double` representation of the contents of *pyfloat*, but + without error checking. + + +.. cfunction:: PyObject* PyFloat_GetInfo(void) + + Return a structseq instance which contains information about the + precision, minimum and maximum values of a float. It's a thin wrapper + around the header file :file:`float.h`. + + .. versionadded:: 2.6 + + +.. cfunction:: double PyFloat_GetMax(void) + + Return the maximum representable finite float *DBL_MAX* as C :ctype:`double`. + + .. versionadded:: 2.6 + + +.. cfunction:: double PyFloat_GetMin(void) + + Return the minimum normalized positive float *DBL_MIN* as C :ctype:`double`. + + .. versionadded:: 2.6 Added: python/trunk/Doc/c-api/function.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/c-api/function.rst Sat Jan 19 23:08:21 2008 @@ -0,0 +1,83 @@ +.. highlightlang:: c + +.. _function-objects: + +Function Objects +---------------- + +.. index:: object: function + +There are a few functions specific to Python functions. + + +.. ctype:: PyFunctionObject + + The C structure used for functions. + + +.. cvar:: PyTypeObject PyFunction_Type + + .. index:: single: MethodType (in module types) + + This is an instance of :ctype:`PyTypeObject` and represents the Python function + type. It is exposed to Python programmers as ``types.FunctionType``. + + +.. cfunction:: int PyFunction_Check(PyObject *o) + + Return true if *o* is a function object (has type :cdata:`PyFunction_Type`). + The parameter must not be *NULL*. + + +.. cfunction:: PyObject* PyFunction_New(PyObject *code, PyObject *globals) + + Return a new function object associated with the code object *code*. *globals* + must be a dictionary with the global variables accessible to the function. + + The function's docstring, name and *__module__* are retrieved from the code + object, the argument defaults and closure are set to *NULL*. + + +.. cfunction:: PyObject* PyFunction_GetCode(PyObject *op) + + Return the code object associated with the function object *op*. + + +.. cfunction:: PyObject* PyFunction_GetGlobals(PyObject *op) + + Return the globals dictionary associated with the function object *op*. + + +.. cfunction:: PyObject* PyFunction_GetModule(PyObject *op) + + Return the *__module__* attribute of the function object *op*. This is normally + a string containing the module name, but can be set to any other object by + Python code. + + +.. cfunction:: PyObject* PyFunction_GetDefaults(PyObject *op) + + Return the argument default values of the function object *op*. This can be a + tuple of arguments or *NULL*. + + +.. cfunction:: int PyFunction_SetDefaults(PyObject *op, PyObject *defaults) + + Set the argument default values for the function object *op*. *defaults* must be + *Py_None* or a tuple. + + Raises :exc:`SystemError` and returns ``-1`` on failure. + + +.. cfunction:: PyObject* PyFunction_GetClosure(PyObject *op) + + Return the closure associated with the function object *op*. This can be *NULL* + or a tuple of cell objects. + + +.. cfunction:: int PyFunction_SetClosure(PyObject *op, PyObject *closure) + + Set the closure associated with the function object *op*. *closure* must be + *Py_None* or a tuple of cell objects. + + Raises :exc:`SystemError` and returns ``-1`` on failure. Added: python/trunk/Doc/c-api/gcsupport.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/c-api/gcsupport.rst Sat Jan 19 23:08:21 2008 @@ -0,0 +1,153 @@ +.. highlightlang:: c + +.. _supporting-cycle-detection: + +Supporting Cyclic Garbage Collection +==================================== + +Python's support for detecting and collecting garbage which involves circular +references requires support from object types which are "containers" for other +objects which may also be containers. Types which do not store references to +other objects, or which only store references to atomic types (such as numbers +or strings), do not need to provide any explicit support for garbage collection. + +.. An example showing the use of these interfaces can be found in "Supporting the +.. Cycle Collector (XXX not found: ../ext/example-cycle-support.html)". + +To create a container type, the :attr:`tp_flags` field of the type object must +include the :const:`Py_TPFLAGS_HAVE_GC` and provide an implementation of the +:attr:`tp_traverse` handler. If instances of the type are mutable, a +:attr:`tp_clear` implementation must also be provided. + + +.. data:: Py_TPFLAGS_HAVE_GC + :noindex: + + Objects with a type with this flag set must conform with the rules documented + here. For convenience these objects will be referred to as container objects. + +Constructors for container types must conform to two rules: + +#. The memory for the object must be allocated using :cfunc:`PyObject_GC_New` or + :cfunc:`PyObject_GC_VarNew`. + +#. Once all the fields which may contain references to other containers are + initialized, it must call :cfunc:`PyObject_GC_Track`. + + +.. cfunction:: TYPE* PyObject_GC_New(TYPE, PyTypeObject *type) + + Analogous to :cfunc:`PyObject_New` but for container objects with the + :const:`Py_TPFLAGS_HAVE_GC` flag set. + + +.. cfunction:: TYPE* PyObject_GC_NewVar(TYPE, PyTypeObject *type, Py_ssize_t size) + + Analogous to :cfunc:`PyObject_NewVar` but for container objects with the + :const:`Py_TPFLAGS_HAVE_GC` flag set. + + +.. cfunction:: PyVarObject * PyObject_GC_Resize(PyVarObject *op, Py_ssize_t) + + Resize an object allocated by :cfunc:`PyObject_NewVar`. Returns the resized + object or *NULL* on failure. + + +.. cfunction:: void PyObject_GC_Track(PyObject *op) + + Adds the object *op* to the set of container objects tracked by the collector. + The collector can run at unexpected times so objects must be valid while being + tracked. This should be called once all the fields followed by the + :attr:`tp_traverse` handler become valid, usually near the end of the + constructor. + + +.. cfunction:: void _PyObject_GC_TRACK(PyObject *op) + + A macro version of :cfunc:`PyObject_GC_Track`. It should not be used for + extension modules. + +Similarly, the deallocator for the object must conform to a similar pair of +rules: + +#. Before fields which refer to other containers are invalidated, + :cfunc:`PyObject_GC_UnTrack` must be called. + +#. The object's memory must be deallocated using :cfunc:`PyObject_GC_Del`. + + +.. cfunction:: void PyObject_GC_Del(void *op) + + Releases memory allocated to an object using :cfunc:`PyObject_GC_New` or + :cfunc:`PyObject_GC_NewVar`. + + +.. cfunction:: void PyObject_GC_UnTrack(void *op) + + Remove the object *op* from the set of container objects tracked by the + collector. Note that :cfunc:`PyObject_GC_Track` can be called again on this + object to add it back to the set of tracked objects. The deallocator + (:attr:`tp_dealloc` handler) should call this for the object before any of the + fields used by the :attr:`tp_traverse` handler become invalid. + + +.. cfunction:: void _PyObject_GC_UNTRACK(PyObject *op) + + A macro version of :cfunc:`PyObject_GC_UnTrack`. It should not be used for + extension modules. + +The :attr:`tp_traverse` handler accepts a function parameter of this type: + + +.. ctype:: int (*visitproc)(PyObject *object, void *arg) + + Type of the visitor function passed to the :attr:`tp_traverse` handler. The + function should be called with an object to traverse as *object* and the third + parameter to the :attr:`tp_traverse` handler as *arg*. The Python core uses + several visitor functions to implement cyclic garbage detection; it's not + expected that users will need to write their own visitor functions. + +The :attr:`tp_traverse` handler must have the following type: + + +.. ctype:: int (*traverseproc)(PyObject *self, visitproc visit, void *arg) + + Traversal function for a container object. Implementations must call the + *visit* function for each object directly contained by *self*, with the + parameters to *visit* being the contained object and the *arg* value passed to + the handler. The *visit* function must not be called with a *NULL* object + argument. If *visit* returns a non-zero value that value should be returned + immediately. + +To simplify writing :attr:`tp_traverse` handlers, a :cfunc:`Py_VISIT` macro is +provided. In order to use this macro, the :attr:`tp_traverse` implementation +must name its arguments exactly *visit* and *arg*: + + +.. cfunction:: void Py_VISIT(PyObject *o) + + Call the *visit* callback, with arguments *o* and *arg*. If *visit* returns a + non-zero value, then return it. Using this macro, :attr:`tp_traverse` handlers + look like:: + + static int + my_traverse(Noddy *self, visitproc visit, void *arg) + { + Py_VISIT(self->foo); + Py_VISIT(self->bar); + return 0; + } + + .. versionadded:: 2.4 + +The :attr:`tp_clear` handler must be of the :ctype:`inquiry` type, or *NULL* if +the object is immutable. + + +.. ctype:: int (*inquiry)(PyObject *self) + + Drop references that may have created reference cycles. Immutable objects do + not have to define this method since they can never directly create reference + cycles. Note that the object must still be valid after calling this method + (don't just call :cfunc:`Py_DECREF` on a reference). The collector will call + this method if it detects that this object is involved in a reference cycle. Added: python/trunk/Doc/c-api/gen.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/c-api/gen.rst Sat Jan 19 23:08:21 2008 @@ -0,0 +1,38 @@ +.. highlightlang:: c + +.. _gen-objects: + +Generator Objects +----------------- + +Generator objects are what Python uses to implement generator iterators. They +are normally created by iterating over a function that yields values, rather +than explicitly calling :cfunc:`PyGen_New`. + + +.. ctype:: PyGenObject + + The C structure used for generator objects. + + +.. cvar:: PyTypeObject PyGen_Type + + The type object corresponding to generator objects + + +.. cfunction:: int PyGen_Check(ob) + + Return true if *ob* is a generator object; *ob* must not be *NULL*. + + +.. cfunction:: int PyGen_CheckExact(ob) + + Return true if *ob*'s type is *PyGen_Type* is a generator object; *ob* must not + be *NULL*. + + +.. cfunction:: PyObject* PyGen_New(PyFrameObject *frame) + + Create and return a new generator object based on the *frame* object. A + reference to *frame* is stolen by this function. The parameter must not be + *NULL*. Modified: python/trunk/Doc/c-api/index.rst ============================================================================== --- python/trunk/Doc/c-api/index.rst (original) +++ python/trunk/Doc/c-api/index.rst Sat Jan 19 23:08:21 2008 @@ -24,4 +24,4 @@ concrete.rst init.rst memory.rst - newtypes.rst + objimpl.rst Added: python/trunk/Doc/c-api/int.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/c-api/int.rst Sat Jan 19 23:08:21 2008 @@ -0,0 +1,122 @@ +.. highlightlang:: c + +.. _intobjects: + +Plain Integer Objects +--------------------- + +.. index:: object: integer + + +.. ctype:: PyIntObject + + This subtype of :ctype:`PyObject` represents a Python integer object. + + +.. cvar:: PyTypeObject PyInt_Type + + .. index:: single: IntType (in modules types) + + This instance of :ctype:`PyTypeObject` represents the Python plain integer type. + This is the same object as ``int`` and ``types.IntType``. + + +.. cfunction:: int PyInt_Check(PyObject *o) + + Return true if *o* is of type :cdata:`PyInt_Type` or a subtype of + :cdata:`PyInt_Type`. + + .. versionchanged:: 2.2 + Allowed subtypes to be accepted. + + +.. cfunction:: int PyInt_CheckExact(PyObject *o) + + Return true if *o* is of type :cdata:`PyInt_Type`, but not a subtype of + :cdata:`PyInt_Type`. + + .. versionadded:: 2.2 + + +.. cfunction:: PyObject* PyInt_FromString(char *str, char **pend, int base) + + Return a new :ctype:`PyIntObject` or :ctype:`PyLongObject` based on the string + value in *str*, which is interpreted according to the radix in *base*. If + *pend* is non-*NULL*, ``*pend`` will point to the first character in *str* which + follows the representation of the number. If *base* is ``0``, the radix will be + determined based on the leading characters of *str*: if *str* starts with + ``'0x'`` or ``'0X'``, radix 16 will be used; if *str* starts with ``'0'``, radix + 8 will be used; otherwise radix 10 will be used. If *base* is not ``0``, it + must be between ``2`` and ``36``, inclusive. Leading spaces are ignored. If + there are no digits, :exc:`ValueError` will be raised. If the string represents + a number too large to be contained within the machine's :ctype:`long int` type + and overflow warnings are being suppressed, a :ctype:`PyLongObject` will be + returned. If overflow warnings are not being suppressed, *NULL* will be + returned in this case. + + +.. cfunction:: PyObject* PyInt_FromLong(long ival) + + Create a new integer object with a value of *ival*. + + The current implementation keeps an array of integer objects for all integers + between ``-5`` and ``256``, when you create an int in that range you actually + just get back a reference to the existing object. So it should be possible to + change the value of ``1``. I suspect the behaviour of Python in this case is + undefined. :-) + + +.. cfunction:: PyObject* PyInt_FromSsize_t(Py_ssize_t ival) + + Create a new integer object with a value of *ival*. If the value exceeds + ``LONG_MAX``, a long integer object is returned. + + .. versionadded:: 2.5 + + +.. cfunction:: long PyInt_AsLong(PyObject *io) + + Will first attempt to cast the object to a :ctype:`PyIntObject`, if it is not + already one, and then return its value. If there is an error, ``-1`` is + returned, and the caller should check ``PyErr_Occurred()`` to find out whether + there was an error, or whether the value just happened to be -1. + + +.. cfunction:: long PyInt_AS_LONG(PyObject *io) + + Return the value of the object *io*. No error checking is performed. + + +.. cfunction:: unsigned long PyInt_AsUnsignedLongMask(PyObject *io) + + Will first attempt to cast the object to a :ctype:`PyIntObject` or + :ctype:`PyLongObject`, if it is not already one, and then return its value as + unsigned long. This function does not check for overflow. + + .. versionadded:: 2.3 + + +.. cfunction:: unsigned PY_LONG_LONG PyInt_AsUnsignedLongLongMask(PyObject *io) + + Will first attempt to cast the object to a :ctype:`PyIntObject` or + :ctype:`PyLongObject`, if it is not already one, and then return its value as + unsigned long long, without checking for overflow. + + .. versionadded:: 2.3 + + +.. cfunction:: Py_ssize_t PyInt_AsSsize_t(PyObject *io) + + Will first attempt to cast the object to a :ctype:`PyIntObject` or + :ctype:`PyLongObject`, if it is not already one, and then return its value as + :ctype:`Py_ssize_t`. + + .. versionadded:: 2.5 + + +.. cfunction:: long PyInt_GetMax() + + .. index:: single: LONG_MAX + + Return the system's idea of the largest integer it can handle + (:const:`LONG_MAX`, as defined in the system header files). Added: python/trunk/Doc/c-api/iter.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/c-api/iter.rst Sat Jan 19 23:08:21 2008 @@ -0,0 +1,50 @@ +.. highlightlang:: c + +.. _iterator: + +Iterator Protocol +================= + +.. versionadded:: 2.2 + +There are only a couple of functions specifically for working with iterators. + + +.. cfunction:: int PyIter_Check(PyObject *o) + + Return true if the object *o* supports the iterator protocol. + + +.. cfunction:: PyObject* PyIter_Next(PyObject *o) + + Return the next value from the iteration *o*. If the object is an iterator, + this retrieves the next value from the iteration, and returns *NULL* with no + exception set if there are no remaining items. If the object is not an + iterator, :exc:`TypeError` is raised, or if there is an error in retrieving the + item, returns *NULL* and passes along the exception. + +To write a loop which iterates over an iterator, the C code should look +something like this:: + + PyObject *iterator = PyObject_GetIter(obj); + PyObject *item; + + if (iterator == NULL) { + /* propagate error */ + } + + while (item = PyIter_Next(iterator)) { + /* do something with item */ + ... + /* release reference when done */ + Py_DECREF(item); + } + + Py_DECREF(iterator); + + if (PyErr_Occurred()) { + /* propagate error */ + } + else { + /* continue doing useful work */ + } Added: python/trunk/Doc/c-api/iterator.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/c-api/iterator.rst Sat Jan 19 23:08:21 2008 @@ -0,0 +1,62 @@ +.. highlightlang:: c + +.. _iterator-objects: + +Iterator Objects +---------------- + +Python provides two general-purpose iterator objects. The first, a sequence +iterator, works with an arbitrary sequence supporting the :meth:`__getitem__` +method. The second works with a callable object and a sentinel value, calling +the callable for each item in the sequence, and ending the iteration when the +sentinel value is returned. + + +.. cvar:: PyTypeObject PySeqIter_Type + + Type object for iterator objects returned by :cfunc:`PySeqIter_New` and the + one-argument form of the :func:`iter` built-in function for built-in sequence + types. + + .. versionadded:: 2.2 + + +.. cfunction:: int PySeqIter_Check(op) + + Return true if the type of *op* is :cdata:`PySeqIter_Type`. + + .. versionadded:: 2.2 + + +.. cfunction:: PyObject* PySeqIter_New(PyObject *seq) + + Return an iterator that works with a general sequence object, *seq*. The + iteration ends when the sequence raises :exc:`IndexError` for the subscripting + operation. + + .. versionadded:: 2.2 + + +.. cvar:: PyTypeObject PyCallIter_Type + + Type object for iterator objects returned by :cfunc:`PyCallIter_New` and the + two-argument form of the :func:`iter` built-in function. + + .. versionadded:: 2.2 + + +.. cfunction:: int PyCallIter_Check(op) + + Return true if the type of *op* is :cdata:`PyCallIter_Type`. + + .. versionadded:: 2.2 + + +.. cfunction:: PyObject* PyCallIter_New(PyObject *callable, PyObject *sentinel) + + Return a new iterator. The first parameter, *callable*, can be any Python + callable object that can be called with no parameters; each call to it should + return the next item in the iteration. When *callable* returns a value equal to + *sentinel*, the iteration will be terminated. + + .. versionadded:: 2.2 Added: python/trunk/Doc/c-api/list.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/c-api/list.rst Sat Jan 19 23:08:21 2008 @@ -0,0 +1,147 @@ +.. highlightlang:: c + +.. _listobjects: + +List Objects +------------ + +.. index:: object: list + + +.. ctype:: PyListObject + + This subtype of :ctype:`PyObject` represents a Python list object. + + +.. cvar:: PyTypeObject PyList_Type + + .. index:: single: ListType (in module types) + + This instance of :ctype:`PyTypeObject` represents the Python list type. This is + the same object as ``list`` and ``types.ListType`` in the Python layer. + + +.. cfunction:: int PyList_Check(PyObject *p) + + Return true if *p* is a list object or an instance of a subtype of the list + type. + + .. versionchanged:: 2.2 + Allowed subtypes to be accepted. + + +.. cfunction:: int PyList_CheckExact(PyObject *p) + + Return true if *p* is a list object, but not an instance of a subtype of the + list type. + + .. versionadded:: 2.2 + + +.. cfunction:: PyObject* PyList_New(Py_ssize_t len) + + Return a new list of length *len* on success, or *NULL* on failure. + + .. note:: + + If *length* is greater than zero, the returned list object's items are set to + ``NULL``. Thus you cannot use abstract API functions such as + :cfunc:`PySequence_SetItem` or expose the object to Python code before setting + all items to a real object with :cfunc:`PyList_SetItem`. + + +.. cfunction:: Py_ssize_t PyList_Size(PyObject *list) + + .. index:: builtin: len + + Return the length of the list object in *list*; this is equivalent to + ``len(list)`` on a list object. + + +.. cfunction:: Py_ssize_t PyList_GET_SIZE(PyObject *list) + + Macro form of :cfunc:`PyList_Size` without error checking. + + +.. cfunction:: PyObject* PyList_GetItem(PyObject *list, Py_ssize_t index) + + Return the object at position *pos* in the list pointed to by *p*. The position + must be positive, indexing from the end of the list is not supported. If *pos* + is out of bounds, return *NULL* and set an :exc:`IndexError` exception. + + +.. cfunction:: PyObject* PyList_GET_ITEM(PyObject *list, Py_ssize_t i) + + Macro form of :cfunc:`PyList_GetItem` without error checking. + + +.. cfunction:: int PyList_SetItem(PyObject *list, Py_ssize_t index, PyObject *item) + + Set the item at index *index* in list to *item*. Return ``0`` on success or + ``-1`` on failure. + + .. note:: + + This function "steals" a reference to *item* and discards a reference to an item + already in the list at the affected position. + + +.. cfunction:: void PyList_SET_ITEM(PyObject *list, Py_ssize_t i, PyObject *o) + + Macro form of :cfunc:`PyList_SetItem` without error checking. This is normally + only used to fill in new lists where there is no previous content. + + .. note:: + + This function "steals" a reference to *item*, and, unlike + :cfunc:`PyList_SetItem`, does *not* discard a reference to any item that it + being replaced; any reference in *list* at position *i* will be leaked. + + +.. cfunction:: int PyList_Insert(PyObject *list, Py_ssize_t index, PyObject *item) + + Insert the item *item* into list *list* in front of index *index*. Return ``0`` + if successful; return ``-1`` and set an exception if unsuccessful. Analogous to + ``list.insert(index, item)``. + + +.. cfunction:: int PyList_Append(PyObject *list, PyObject *item) + + Append the object *item* at the end of list *list*. Return ``0`` if successful; + return ``-1`` and set an exception if unsuccessful. Analogous to + ``list.append(item)``. + + +.. cfunction:: PyObject* PyList_GetSlice(PyObject *list, Py_ssize_t low, Py_ssize_t high) + + Return a list of the objects in *list* containing the objects *between* *low* + and *high*. Return *NULL* and set an exception if unsuccessful. Analogous to + ``list[low:high]``. + + +.. cfunction:: int PyList_SetSlice(PyObject *list, Py_ssize_t low, Py_ssize_t high, PyObject *itemlist) + + Set the slice of *list* between *low* and *high* to the contents of *itemlist*. + Analogous to ``list[low:high] = itemlist``. The *itemlist* may be *NULL*, + indicating the assignment of an empty list (slice deletion). Return ``0`` on + success, ``-1`` on failure. + + +.. cfunction:: int PyList_Sort(PyObject *list) + + Sort the items of *list* in place. Return ``0`` on success, ``-1`` on failure. + This is equivalent to ``list.sort()``. + + +.. cfunction:: int PyList_Reverse(PyObject *list) + + Reverse the items of *list* in place. Return ``0`` on success, ``-1`` on + failure. This is the equivalent of ``list.reverse()``. + + +.. cfunction:: PyObject* PyList_AsTuple(PyObject *list) + + .. index:: builtin: tuple + + Return a new tuple object containing the contents of *list*; equivalent to + ``tuple(list)``. Added: python/trunk/Doc/c-api/long.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/c-api/long.rst Sat Jan 19 23:08:21 2008 @@ -0,0 +1,179 @@ +.. highlightlang:: c + +.. _longobjects: + +Long Integer Objects +-------------------- + +.. index:: object: long integer + + +.. ctype:: PyLongObject + + This subtype of :ctype:`PyObject` represents a Python long integer object. + + +.. cvar:: PyTypeObject PyLong_Type + + .. index:: single: LongType (in modules types) + + This instance of :ctype:`PyTypeObject` represents the Python long integer type. + This is the same object as ``long`` and ``types.LongType``. + + +.. cfunction:: int PyLong_Check(PyObject *p) + + Return true if its argument is a :ctype:`PyLongObject` or a subtype of + :ctype:`PyLongObject`. + + .. versionchanged:: 2.2 + Allowed subtypes to be accepted. + + +.. cfunction:: int PyLong_CheckExact(PyObject *p) + + Return true if its argument is a :ctype:`PyLongObject`, but not a subtype of + :ctype:`PyLongObject`. + + .. versionadded:: 2.2 + + +.. cfunction:: PyObject* PyLong_FromLong(long v) + + Return a new :ctype:`PyLongObject` object from *v*, or *NULL* on failure. + + +.. cfunction:: PyObject* PyLong_FromUnsignedLong(unsigned long v) + + Return a new :ctype:`PyLongObject` object from a C :ctype:`unsigned long`, or + *NULL* on failure. + + +.. cfunction:: PyObject* PyLong_FromLongLong(PY_LONG_LONG v) + + Return a new :ctype:`PyLongObject` object from a C :ctype:`long long`, or *NULL* + on failure. + + +.. cfunction:: PyObject* PyLong_FromUnsignedLongLong(unsigned PY_LONG_LONG v) + + Return a new :ctype:`PyLongObject` object from a C :ctype:`unsigned long long`, + or *NULL* on failure. + + +.. cfunction:: PyObject* PyLong_FromDouble(double v) + + Return a new :ctype:`PyLongObject` object from the integer part of *v*, or + *NULL* on failure. + + +.. cfunction:: PyObject* PyLong_FromString(char *str, char **pend, int base) + + Return a new :ctype:`PyLongObject` based on the string value in *str*, which is + interpreted according to the radix in *base*. If *pend* is non-*NULL*, + ``*pend`` will point to the first character in *str* which follows the + representation of the number. If *base* is ``0``, the radix will be determined + based on the leading characters of *str*: if *str* starts with ``'0x'`` or + ``'0X'``, radix 16 will be used; if *str* starts with ``'0'``, radix 8 will be + used; otherwise radix 10 will be used. If *base* is not ``0``, it must be + between ``2`` and ``36``, inclusive. Leading spaces are ignored. If there are + no digits, :exc:`ValueError` will be raised. + + +.. cfunction:: PyObject* PyLong_FromUnicode(Py_UNICODE *u, Py_ssize_t length, int base) + + Convert a sequence of Unicode digits to a Python long integer value. The first + parameter, *u*, points to the first character of the Unicode string, *length* + gives the number of characters, and *base* is the radix for the conversion. The + radix must be in the range [2, 36]; if it is out of range, :exc:`ValueError` + will be raised. + + .. versionadded:: 1.6 + + +.. cfunction:: PyObject* PyLong_FromVoidPtr(void *p) + + Create a Python integer or long integer from the pointer *p*. The pointer value + can be retrieved from the resulting value using :cfunc:`PyLong_AsVoidPtr`. + + .. versionadded:: 1.5.2 + + .. versionchanged:: 2.5 + If the integer is larger than LONG_MAX, a positive long integer is returned. + + +.. cfunction:: long PyLong_AsLong(PyObject *pylong) + + .. index:: + single: LONG_MAX + single: OverflowError (built-in exception) + + Return a C :ctype:`long` representation of the contents of *pylong*. If + *pylong* is greater than :const:`LONG_MAX`, an :exc:`OverflowError` is raised. + + +.. cfunction:: unsigned long PyLong_AsUnsignedLong(PyObject *pylong) + + .. index:: + single: ULONG_MAX + single: OverflowError (built-in exception) + + Return a C :ctype:`unsigned long` representation of the contents of *pylong*. + If *pylong* is greater than :const:`ULONG_MAX`, an :exc:`OverflowError` is + raised. + + +.. cfunction:: PY_LONG_LONG PyLong_AsLongLong(PyObject *pylong) + + Return a C :ctype:`long long` from a Python long integer. If *pylong* cannot be + represented as a :ctype:`long long`, an :exc:`OverflowError` will be raised. + + .. versionadded:: 2.2 + + +.. cfunction:: unsigned PY_LONG_LONG PyLong_AsUnsignedLongLong(PyObject *pylong) + + Return a C :ctype:`unsigned long long` from a Python long integer. If *pylong* + cannot be represented as an :ctype:`unsigned long long`, an :exc:`OverflowError` + will be raised if the value is positive, or a :exc:`TypeError` will be raised if + the value is negative. + + .. versionadded:: 2.2 + + +.. cfunction:: unsigned long PyLong_AsUnsignedLongMask(PyObject *io) + + Return a C :ctype:`unsigned long` from a Python long integer, without checking + for overflow. + + .. versionadded:: 2.3 + + +.. cfunction:: unsigned PY_LONG_LONG PyLong_AsUnsignedLongLongMask(PyObject *io) + + Return a C :ctype:`unsigned long long` from a Python long integer, without + checking for overflow. + + .. versionadded:: 2.3 + + +.. cfunction:: double PyLong_AsDouble(PyObject *pylong) + + Return a C :ctype:`double` representation of the contents of *pylong*. If + *pylong* cannot be approximately represented as a :ctype:`double`, an + :exc:`OverflowError` exception is raised and ``-1.0`` will be returned. + + +.. cfunction:: void* PyLong_AsVoidPtr(PyObject *pylong) + + Convert a Python integer or long integer *pylong* to a C :ctype:`void` pointer. + If *pylong* cannot be converted, an :exc:`OverflowError` will be raised. This + is only assured to produce a usable :ctype:`void` pointer for values created + with :cfunc:`PyLong_FromVoidPtr`. + + .. versionadded:: 1.5.2 + + .. versionchanged:: 2.5 + For values outside 0..LONG_MAX, both signed and unsigned integers are acccepted. + + Added: python/trunk/Doc/c-api/mapping.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/c-api/mapping.rst Sat Jan 19 23:08:21 2008 @@ -0,0 +1,78 @@ +.. highlightlang:: c + +.. _mapping: + +Mapping Protocol +================ + + +.. cfunction:: int PyMapping_Check(PyObject *o) + + Return ``1`` if the object provides mapping protocol, and ``0`` otherwise. This + function always succeeds. + + +.. cfunction:: Py_ssize_t PyMapping_Length(PyObject *o) + + .. index:: builtin: len + + Returns the number of keys in object *o* on success, and ``-1`` on failure. For + objects that do not provide mapping protocol, this is equivalent to the Python + expression ``len(o)``. + + +.. cfunction:: int PyMapping_DelItemString(PyObject *o, char *key) + + Remove the mapping for object *key* from the object *o*. Return ``-1`` on + failure. This is equivalent to the Python statement ``del o[key]``. + + +.. cfunction:: int PyMapping_DelItem(PyObject *o, PyObject *key) + + Remove the mapping for object *key* from the object *o*. Return ``-1`` on + failure. This is equivalent to the Python statement ``del o[key]``. + + +.. cfunction:: int PyMapping_HasKeyString(PyObject *o, char *key) + + On success, return ``1`` if the mapping object has the key *key* and ``0`` + otherwise. This is equivalent to the Python expression ``o.has_key(key)``. + This function always succeeds. + + +.. cfunction:: int PyMapping_HasKey(PyObject *o, PyObject *key) + + Return ``1`` if the mapping object has the key *key* and ``0`` otherwise. This + is equivalent to the Python expression ``o.has_key(key)``. This function always + succeeds. + + +.. cfunction:: PyObject* PyMapping_Keys(PyObject *o) + + On success, return a list of the keys in object *o*. On failure, return *NULL*. + This is equivalent to the Python expression ``o.keys()``. + + +.. cfunction:: PyObject* PyMapping_Values(PyObject *o) + + On success, return a list of the values in object *o*. On failure, return + *NULL*. This is equivalent to the Python expression ``o.values()``. + + +.. cfunction:: PyObject* PyMapping_Items(PyObject *o) + + On success, return a list of the items in object *o*, where each item is a tuple + containing a key-value pair. On failure, return *NULL*. This is equivalent to + the Python expression ``o.items()``. + + +.. cfunction:: PyObject* PyMapping_GetItemString(PyObject *o, char *key) + + Return element of *o* corresponding to the object *key* or *NULL* on failure. + This is the equivalent of the Python expression ``o[key]``. + + +.. cfunction:: int PyMapping_SetItemString(PyObject *o, char *key, PyObject *v) + + Map the object *key* to the value *v* in object *o*. Returns ``-1`` on failure. + This is the equivalent of the Python statement ``o[key] = v``. Added: python/trunk/Doc/c-api/method.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/c-api/method.rst Sat Jan 19 23:08:21 2008 @@ -0,0 +1,65 @@ +.. highlightlang:: c + +.. _method-objects: + +Method Objects +-------------- + +.. index:: object: method + +There are some useful functions that are useful for working with method objects. + + +.. cvar:: PyTypeObject PyMethod_Type + + .. index:: single: MethodType (in module types) + + This instance of :ctype:`PyTypeObject` represents the Python method type. This + is exposed to Python programs as ``types.MethodType``. + + +.. cfunction:: int PyMethod_Check(PyObject *o) + + Return true if *o* is a method object (has type :cdata:`PyMethod_Type`). The + parameter must not be *NULL*. + + +.. cfunction:: PyObject* PyMethod_New(PyObject *func, PyObject *self, PyObject *class) + + Return a new method object, with *func* being any callable object; this is the + function that will be called when the method is called. If this method should + be bound to an instance, *self* should be the instance and *class* should be the + class of *self*, otherwise *self* should be *NULL* and *class* should be the + class which provides the unbound method.. + + +.. cfunction:: PyObject* PyMethod_Class(PyObject *meth) + + Return the class object from which the method *meth* was created; if this was + created from an instance, it will be the class of the instance. + + +.. cfunction:: PyObject* PyMethod_GET_CLASS(PyObject *meth) + + Macro version of :cfunc:`PyMethod_Class` which avoids error checking. + + +.. cfunction:: PyObject* PyMethod_Function(PyObject *meth) + + Return the function object associated with the method *meth*. + + +.. cfunction:: PyObject* PyMethod_GET_FUNCTION(PyObject *meth) + + Macro version of :cfunc:`PyMethod_Function` which avoids error checking. + + +.. cfunction:: PyObject* PyMethod_Self(PyObject *meth) + + Return the instance associated with the method *meth* if it is bound, otherwise + return *NULL*. + + +.. cfunction:: PyObject* PyMethod_GET_SELF(PyObject *meth) + + Macro version of :cfunc:`PyMethod_Self` which avoids error checking. Added: python/trunk/Doc/c-api/module.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/c-api/module.rst Sat Jan 19 23:08:21 2008 @@ -0,0 +1,105 @@ +.. highlightlang:: c + +.. _moduleobjects: + +Module Objects +-------------- + +.. index:: object: module + +There are only a few functions special to module objects. + + +.. cvar:: PyTypeObject PyModule_Type + + .. index:: single: ModuleType (in module types) + + This instance of :ctype:`PyTypeObject` represents the Python module type. This + is exposed to Python programs as ``types.ModuleType``. + + +.. cfunction:: int PyModule_Check(PyObject *p) + + Return true if *p* is a module object, or a subtype of a module object. + + .. versionchanged:: 2.2 + Allowed subtypes to be accepted. + + +.. cfunction:: int PyModule_CheckExact(PyObject *p) + + Return true if *p* is a module object, but not a subtype of + :cdata:`PyModule_Type`. + + .. versionadded:: 2.2 + + +.. cfunction:: PyObject* PyModule_New(const char *name) + + .. index:: + single: __name__ (module attribute) + single: __doc__ (module attribute) + single: __file__ (module attribute) + + Return a new module object with the :attr:`__name__` attribute set to *name*. + Only the module's :attr:`__doc__` and :attr:`__name__` attributes are filled in; + the caller is responsible for providing a :attr:`__file__` attribute. + + +.. cfunction:: PyObject* PyModule_GetDict(PyObject *module) + + .. index:: single: __dict__ (module attribute) + + Return the dictionary object that implements *module*'s namespace; this object + is the same as the :attr:`__dict__` attribute of the module object. This + function never fails. It is recommended extensions use other + :cfunc:`PyModule_\*` and :cfunc:`PyObject_\*` functions rather than directly + manipulate a module's :attr:`__dict__`. + + +.. cfunction:: char* PyModule_GetName(PyObject *module) + + .. index:: + single: __name__ (module attribute) + single: SystemError (built-in exception) + + Return *module*'s :attr:`__name__` value. If the module does not provide one, + or if it is not a string, :exc:`SystemError` is raised and *NULL* is returned. + + +.. cfunction:: char* PyModule_GetFilename(PyObject *module) + + .. index:: + single: __file__ (module attribute) + single: SystemError (built-in exception) + + Return the name of the file from which *module* was loaded using *module*'s + :attr:`__file__` attribute. If this is not defined, or if it is not a string, + raise :exc:`SystemError` and return *NULL*. + + +.. cfunction:: int PyModule_AddObject(PyObject *module, const char *name, PyObject *value) + + Add an object to *module* as *name*. This is a convenience function which can + be used from the module's initialization function. This steals a reference to + *value*. Return ``-1`` on error, ``0`` on success. + + .. versionadded:: 2.0 + + +.. cfunction:: int PyModule_AddIntConstant(PyObject *module, const char *name, long value) + + Add an integer constant to *module* as *name*. This convenience function can be + used from the module's initialization function. Return ``-1`` on error, ``0`` on + success. + + .. versionadded:: 2.0 + + +.. cfunction:: int PyModule_AddStringConstant(PyObject *module, const char *name, const char *value) + + Add a string constant to *module* as *name*. This convenience function can be + used from the module's initialization function. The string *value* must be + null-terminated. Return ``-1`` on error, ``0`` on success. + + .. versionadded:: 2.0 Deleted: /python/trunk/Doc/c-api/newtypes.rst ============================================================================== --- /python/trunk/Doc/c-api/newtypes.rst Sat Jan 19 23:08:21 2008 +++ (empty file) @@ -1,1911 +0,0 @@ -.. highlightlang:: c - - -.. _newtypes: - -***************************** -Object Implementation Support -***************************** - -This chapter describes the functions, types, and macros used when defining new -object types. - - -.. _allocating-objects: - -Allocating Objects on the Heap -============================== - - -.. cfunction:: PyObject* _PyObject_New(PyTypeObject *type) - - -.. cfunction:: PyVarObject* _PyObject_NewVar(PyTypeObject *type, Py_ssize_t size) - - -.. cfunction:: void _PyObject_Del(PyObject *op) - - -.. cfunction:: PyObject* PyObject_Init(PyObject *op, PyTypeObject *type) - - Initialize a newly-allocated object *op* with its type and initial reference. - Returns the initialized object. If *type* indicates that the object - participates in the cyclic garbage detector, it is added to the detector's set - of observed objects. Other fields of the object are not affected. - - -.. cfunction:: PyVarObject* PyObject_InitVar(PyVarObject *op, PyTypeObject *type, Py_ssize_t size) - - This does everything :cfunc:`PyObject_Init` does, and also initializes the - length information for a variable-size object. - - -.. cfunction:: TYPE* PyObject_New(TYPE, PyTypeObject *type) - - Allocate a new Python object using the C structure type *TYPE* and the Python - type object *type*. Fields not defined by the Python object header are not - initialized; the object's reference count will be one. The size of the memory - allocation is determined from the :attr:`tp_basicsize` field of the type object. - - -.. cfunction:: TYPE* PyObject_NewVar(TYPE, PyTypeObject *type, Py_ssize_t size) - - Allocate a new Python object using the C structure type *TYPE* and the Python - type object *type*. Fields not defined by the Python object header are not - initialized. The allocated memory allows for the *TYPE* structure plus *size* - fields of the size given by the :attr:`tp_itemsize` field of *type*. This is - useful for implementing objects like tuples, which are able to determine their - size at construction time. Embedding the array of fields into the same - allocation decreases the number of allocations, improving the memory management - efficiency. - - -.. cfunction:: void PyObject_Del(PyObject *op) - - Releases memory allocated to an object using :cfunc:`PyObject_New` or - :cfunc:`PyObject_NewVar`. This is normally called from the :attr:`tp_dealloc` - handler specified in the object's type. The fields of the object should not be - accessed after this call as the memory is no longer a valid Python object. - - -.. cfunction:: PyObject* Py_InitModule(char *name, PyMethodDef *methods) - - Create a new module object based on a name and table of functions, returning the - new module object. - - .. versionchanged:: 2.3 - Older versions of Python did not support *NULL* as the value for the *methods* - argument. - - -.. cfunction:: PyObject* Py_InitModule3(char *name, PyMethodDef *methods, char *doc) - - Create a new module object based on a name and table of functions, returning the - new module object. If *doc* is non-*NULL*, it will be used to define the - docstring for the module. - - .. versionchanged:: 2.3 - Older versions of Python did not support *NULL* as the value for the *methods* - argument. - - -.. cfunction:: PyObject* Py_InitModule4(char *name, PyMethodDef *methods, char *doc, PyObject *self, int apiver) - - Create a new module object based on a name and table of functions, returning the - new module object. If *doc* is non-*NULL*, it will be used to define the - docstring for the module. If *self* is non-*NULL*, it will passed to the - functions of the module as their (otherwise *NULL*) first parameter. (This was - added as an experimental feature, and there are no known uses in the current - version of Python.) For *apiver*, the only value which should be passed is - defined by the constant :const:`PYTHON_API_VERSION`. - - .. note:: - - Most uses of this function should probably be using the :cfunc:`Py_InitModule3` - instead; only use this if you are sure you need it. - - .. versionchanged:: 2.3 - Older versions of Python did not support *NULL* as the value for the *methods* - argument. - - -.. cvar:: PyObject _Py_NoneStruct - - Object which is visible in Python as ``None``. This should only be accessed - using the ``Py_None`` macro, which evaluates to a pointer to this object. - - -.. _common-structs: - -Common Object Structures -======================== - -There are a large number of structures which are used in the definition of -object types for Python. This section describes these structures and how they -are used. - -All Python objects ultimately share a small number of fields at the beginning of -the object's representation in memory. These are represented by the -:ctype:`PyObject` and :ctype:`PyVarObject` types, which are defined, in turn, by -the expansions of some macros also used, whether directly or indirectly, in the -definition of all other Python objects. - - -.. ctype:: PyObject - - All object types are extensions of this type. This is a type which contains the - information Python needs to treat a pointer to an object as an object. In a - normal "release" build, it contains only the objects reference count and a - pointer to the corresponding type object. It corresponds to the fields defined - by the expansion of the ``PyObject_HEAD`` macro. - - -.. ctype:: PyVarObject - - This is an extension of :ctype:`PyObject` that adds the :attr:`ob_size` field. - This is only used for objects that have some notion of *length*. This type does - not often appear in the Python/C API. It corresponds to the fields defined by - the expansion of the ``PyObject_VAR_HEAD`` macro. - -These macros are used in the definition of :ctype:`PyObject` and -:ctype:`PyVarObject`: - - -.. cmacro:: PyObject_HEAD - - This is a macro which expands to the declarations of the fields of the - :ctype:`PyObject` type; it is used when declaring new types which represent - objects without a varying length. The specific fields it expands to depend on - the definition of :cmacro:`Py_TRACE_REFS`. By default, that macro is not - defined, and :cmacro:`PyObject_HEAD` expands to:: - - Py_ssize_t ob_refcnt; - PyTypeObject *ob_type; - - When :cmacro:`Py_TRACE_REFS` is defined, it expands to:: - - PyObject *_ob_next, *_ob_prev; - Py_ssize_t ob_refcnt; - PyTypeObject *ob_type; - - -.. cmacro:: PyObject_VAR_HEAD - - This is a macro which expands to the declarations of the fields of the - :ctype:`PyVarObject` type; it is used when declaring new types which represent - objects with a length that varies from instance to instance. This macro always - expands to:: - - PyObject_HEAD - Py_ssize_t ob_size; - - Note that :cmacro:`PyObject_HEAD` is part of the expansion, and that its own - expansion varies depending on the definition of :cmacro:`Py_TRACE_REFS`. - -PyObject_HEAD_INIT - - -.. ctype:: PyCFunction - - Type of the functions used to implement most Python callables in C. Functions of - this type take two :ctype:`PyObject\*` parameters and return one such value. If - the return value is *NULL*, an exception shall have been set. If not *NULL*, - the return value is interpreted as the return value of the function as exposed - in Python. The function must return a new reference. - - -.. ctype:: PyMethodDef - - Structure used to describe a method of an extension type. This structure has - four fields: - - +------------------+-------------+-------------------------------+ - | Field | C Type | Meaning | - +==================+=============+===============================+ - | :attr:`ml_name` | char \* | name of the method | - +------------------+-------------+-------------------------------+ - | :attr:`ml_meth` | PyCFunction | pointer to the C | - | | | implementation | - +------------------+-------------+-------------------------------+ - | :attr:`ml_flags` | int | flag bits indicating how the | - | | | call should be constructed | - +------------------+-------------+-------------------------------+ - | :attr:`ml_doc` | char \* | points to the contents of the | - | | | docstring | - +------------------+-------------+-------------------------------+ - -The :attr:`ml_meth` is a C function pointer. The functions may be of different -types, but they always return :ctype:`PyObject\*`. If the function is not of -the :ctype:`PyCFunction`, the compiler will require a cast in the method table. -Even though :ctype:`PyCFunction` defines the first parameter as -:ctype:`PyObject\*`, it is common that the method implementation uses a the -specific C type of the *self* object. - -The :attr:`ml_flags` field is a bitfield which can include the following flags. -The individual flags indicate either a calling convention or a binding -convention. Of the calling convention flags, only :const:`METH_VARARGS` and -:const:`METH_KEYWORDS` can be combined (but note that :const:`METH_KEYWORDS` -alone is equivalent to ``METH_VARARGS | METH_KEYWORDS``). Any of the calling -convention flags can be combined with a binding flag. - - -.. data:: METH_VARARGS - - This is the typical calling convention, where the methods have the type - :ctype:`PyCFunction`. The function expects two :ctype:`PyObject\*` values. The - first one is the *self* object for methods; for module functions, it has the - value given to :cfunc:`Py_InitModule4` (or *NULL* if :cfunc:`Py_InitModule` was - used). The second parameter (often called *args*) is a tuple object - representing all arguments. This parameter is typically processed using - :cfunc:`PyArg_ParseTuple` or :cfunc:`PyArg_UnpackTuple`. - - -.. data:: METH_KEYWORDS - - Methods with these flags must be of type :ctype:`PyCFunctionWithKeywords`. The - function expects three parameters: *self*, *args*, and a dictionary of all the - keyword arguments. The flag is typically combined with :const:`METH_VARARGS`, - and the parameters are typically processed using - :cfunc:`PyArg_ParseTupleAndKeywords`. - - -.. data:: METH_NOARGS - - Methods without parameters don't need to check whether arguments are given if - they are listed with the :const:`METH_NOARGS` flag. They need to be of type - :ctype:`PyCFunction`. When used with object methods, the first parameter is - typically named ``self`` and will hold a reference to the object instance. In - all cases the second parameter will be *NULL*. - - -.. data:: METH_O - - Methods with a single object argument can be listed with the :const:`METH_O` - flag, instead of invoking :cfunc:`PyArg_ParseTuple` with a ``"O"`` argument. - They have the type :ctype:`PyCFunction`, with the *self* parameter, and a - :ctype:`PyObject\*` parameter representing the single argument. - - -.. data:: METH_OLDARGS - - This calling convention is deprecated. The method must be of type - :ctype:`PyCFunction`. The second argument is *NULL* if no arguments are given, - a single object if exactly one argument is given, and a tuple of objects if more - than one argument is given. There is no way for a function using this - convention to distinguish between a call with multiple arguments and a call with - a tuple as the only argument. - -These two constants are not used to indicate the calling convention but the -binding when use with methods of classes. These may not be used for functions -defined for modules. At most one of these flags may be set for any given -method. - - -.. data:: METH_CLASS - - .. index:: builtin: classmethod - - The method will be passed the type object as the first parameter rather than an - instance of the type. This is used to create *class methods*, similar to what - is created when using the :func:`classmethod` built-in function. - - .. versionadded:: 2.3 - - -.. data:: METH_STATIC - - .. index:: builtin: staticmethod - - The method will be passed *NULL* as the first parameter rather than an instance - of the type. This is used to create *static methods*, similar to what is - created when using the :func:`staticmethod` built-in function. - - .. versionadded:: 2.3 - -One other constant controls whether a method is loaded in place of another -definition with the same method name. - - -.. data:: METH_COEXIST - - The method will be loaded in place of existing definitions. Without - *METH_COEXIST*, the default is to skip repeated definitions. Since slot - wrappers are loaded before the method table, the existence of a *sq_contains* - slot, for example, would generate a wrapped method named :meth:`__contains__` - and preclude the loading of a corresponding PyCFunction with the same name. - With the flag defined, the PyCFunction will be loaded in place of the wrapper - object and will co-exist with the slot. This is helpful because calls to - PyCFunctions are optimized more than wrapper object calls. - - .. versionadded:: 2.4 - - -.. cfunction:: PyObject* Py_FindMethod(PyMethodDef table[], PyObject *ob, char *name) - - Return a bound method object for an extension type implemented in C. This can - be useful in the implementation of a :attr:`tp_getattro` or :attr:`tp_getattr` - handler that does not use the :cfunc:`PyObject_GenericGetAttr` function. - - -.. _type-structs: - -Type Objects -============ - -Perhaps one of the most important structures of the Python object system is the -structure that defines a new type: the :ctype:`PyTypeObject` structure. Type -objects can be handled using any of the :cfunc:`PyObject_\*` or -:cfunc:`PyType_\*` functions, but do not offer much that's interesting to most -Python applications. These objects are fundamental to how objects behave, so -they are very important to the interpreter itself and to any extension module -that implements new types. - -Type objects are fairly large compared to most of the standard types. The reason -for the size is that each type object stores a large number of values, mostly C -function pointers, each of which implements a small part of the type's -functionality. The fields of the type object are examined in detail in this -section. The fields will be described in the order in which they occur in the -structure. - -Typedefs: unaryfunc, binaryfunc, ternaryfunc, inquiry, coercion, intargfunc, -intintargfunc, intobjargproc, intintobjargproc, objobjargproc, destructor, -freefunc, printfunc, getattrfunc, getattrofunc, setattrfunc, setattrofunc, -cmpfunc, reprfunc, hashfunc - -The structure definition for :ctype:`PyTypeObject` can be found in -:file:`Include/object.h`. For convenience of reference, this repeats the -definition found there: - -.. literalinclude:: ../includes/typestruct.h - - -The type object structure extends the :ctype:`PyVarObject` structure. The -:attr:`ob_size` field is used for dynamic types (created by :func:`type_new`, -usually called from a class statement). Note that :cdata:`PyType_Type` (the -metatype) initializes :attr:`tp_itemsize`, which means that its instances (i.e. -type objects) *must* have the :attr:`ob_size` field. - - -.. cmember:: PyObject* PyObject._ob_next - PyObject* PyObject._ob_prev - - These fields are only present when the macro ``Py_TRACE_REFS`` is defined. - Their initialization to *NULL* is taken care of by the ``PyObject_HEAD_INIT`` - macro. For statically allocated objects, these fields always remain *NULL*. - For dynamically allocated objects, these two fields are used to link the object - into a doubly-linked list of *all* live objects on the heap. This could be used - for various debugging purposes; currently the only use is to print the objects - that are still alive at the end of a run when the environment variable - :envvar:`PYTHONDUMPREFS` is set. - - These fields are not inherited by subtypes. - - -.. cmember:: Py_ssize_t PyObject.ob_refcnt - - This is the type object's reference count, initialized to ``1`` by the - ``PyObject_HEAD_INIT`` macro. Note that for statically allocated type objects, - the type's instances (objects whose :attr:`ob_type` points back to the type) do - *not* count as references. But for dynamically allocated type objects, the - instances *do* count as references. - - This field is not inherited by subtypes. - - -.. cmember:: PyTypeObject* PyObject.ob_type - - This is the type's type, in other words its metatype. It is initialized by the - argument to the ``PyObject_HEAD_INIT`` macro, and its value should normally be - ``&PyType_Type``. However, for dynamically loadable extension modules that must - be usable on Windows (at least), the compiler complains that this is not a valid - initializer. Therefore, the convention is to pass *NULL* to the - ``PyObject_HEAD_INIT`` macro and to initialize this field explicitly at the - start of the module's initialization function, before doing anything else. This - is typically done like this:: - - Foo_Type.ob_type = &PyType_Type; - - This should be done before any instances of the type are created. - :cfunc:`PyType_Ready` checks if :attr:`ob_type` is *NULL*, and if so, - initializes it: in Python 2.2, it is set to ``&PyType_Type``; in Python 2.2.1 - and later it is initialized to the :attr:`ob_type` field of the base class. - :cfunc:`PyType_Ready` will not change this field if it is non-zero. - - In Python 2.2, this field is not inherited by subtypes. In 2.2.1, and in 2.3 - and beyond, it is inherited by subtypes. - - -.. cmember:: Py_ssize_t PyVarObject.ob_size - - For statically allocated type objects, this should be initialized to zero. For - dynamically allocated type objects, this field has a special internal meaning. - - This field is not inherited by subtypes. - - -.. cmember:: char* PyTypeObject.tp_name - - Pointer to a NUL-terminated string containing the name of the type. For types - that are accessible as module globals, the string should be the full module - name, followed by a dot, followed by the type name; for built-in types, it - should be just the type name. If the module is a submodule of a package, the - full package name is part of the full module name. For example, a type named - :class:`T` defined in module :mod:`M` in subpackage :mod:`Q` in package :mod:`P` - should have the :attr:`tp_name` initializer ``"P.Q.M.T"``. - - For dynamically allocated type objects, this should just be the type name, and - the module name explicitly stored in the type dict as the value for key - ``'__module__'``. - - For statically allocated type objects, the tp_name field should contain a dot. - Everything before the last dot is made accessible as the :attr:`__module__` - attribute, and everything after the last dot is made accessible as the - :attr:`__name__` attribute. - - If no dot is present, the entire :attr:`tp_name` field is made accessible as the - :attr:`__name__` attribute, and the :attr:`__module__` attribute is undefined - (unless explicitly set in the dictionary, as explained above). This means your - type will be impossible to pickle. - - This field is not inherited by subtypes. - - -.. cmember:: Py_ssize_t PyTypeObject.tp_basicsize - Py_ssize_t PyTypeObject.tp_itemsize - - These fields allow calculating the size in bytes of instances of the type. - - There are two kinds of types: types with fixed-length instances have a zero - :attr:`tp_itemsize` field, types with variable-length instances have a non-zero - :attr:`tp_itemsize` field. For a type with fixed-length instances, all - instances have the same size, given in :attr:`tp_basicsize`. - - For a type with variable-length instances, the instances must have an - :attr:`ob_size` field, and the instance size is :attr:`tp_basicsize` plus N - times :attr:`tp_itemsize`, where N is the "length" of the object. The value of - N is typically stored in the instance's :attr:`ob_size` field. There are - exceptions: for example, long ints use a negative :attr:`ob_size` to indicate a - negative number, and N is ``abs(ob_size)`` there. Also, the presence of an - :attr:`ob_size` field in the instance layout doesn't mean that the instance - structure is variable-length (for example, the structure for the list type has - fixed-length instances, yet those instances have a meaningful :attr:`ob_size` - field). - - The basic size includes the fields in the instance declared by the macro - :cmacro:`PyObject_HEAD` or :cmacro:`PyObject_VAR_HEAD` (whichever is used to - declare the instance struct) and this in turn includes the :attr:`_ob_prev` and - :attr:`_ob_next` fields if they are present. This means that the only correct - way to get an initializer for the :attr:`tp_basicsize` is to use the - ``sizeof`` operator on the struct used to declare the instance layout. - The basic size does not include the GC header size (this is new in Python 2.2; - in 2.1 and 2.0, the GC header size was included in :attr:`tp_basicsize`). - - These fields are inherited separately by subtypes. If the base type has a - non-zero :attr:`tp_itemsize`, it is generally not safe to set - :attr:`tp_itemsize` to a different non-zero value in a subtype (though this - depends on the implementation of the base type). - - A note about alignment: if the variable items require a particular alignment, - this should be taken care of by the value of :attr:`tp_basicsize`. Example: - suppose a type implements an array of ``double``. :attr:`tp_itemsize` is - ``sizeof(double)``. It is the programmer's responsibility that - :attr:`tp_basicsize` is a multiple of ``sizeof(double)`` (assuming this is the - alignment requirement for ``double``). - - -.. cmember:: destructor PyTypeObject.tp_dealloc - - A pointer to the instance destructor function. This function must be defined - unless the type guarantees that its instances will never be deallocated (as is - the case for the singletons ``None`` and ``Ellipsis``). - - The destructor function is called by the :cfunc:`Py_DECREF` and - :cfunc:`Py_XDECREF` macros when the new reference count is zero. At this point, - the instance is still in existence, but there are no references to it. The - destructor function should free all references which the instance owns, free all - memory buffers owned by the instance (using the freeing function corresponding - to the allocation function used to allocate the buffer), and finally (as its - last action) call the type's :attr:`tp_free` function. If the type is not - subtypable (doesn't have the :const:`Py_TPFLAGS_BASETYPE` flag bit set), it is - permissible to call the object deallocator directly instead of via - :attr:`tp_free`. The object deallocator should be the one used to allocate the - instance; this is normally :cfunc:`PyObject_Del` if the instance was allocated - using :cfunc:`PyObject_New` or :cfunc:`PyObject_VarNew`, or - :cfunc:`PyObject_GC_Del` if the instance was allocated using - :cfunc:`PyObject_GC_New` or :cfunc:`PyObject_GC_VarNew`. - - This field is inherited by subtypes. - - -.. cmember:: printfunc PyTypeObject.tp_print - - An optional pointer to the instance print function. - - The print function is only called when the instance is printed to a *real* file; - when it is printed to a pseudo-file (like a :class:`StringIO` instance), the - instance's :attr:`tp_repr` or :attr:`tp_str` function is called to convert it to - a string. These are also called when the type's :attr:`tp_print` field is - *NULL*. A type should never implement :attr:`tp_print` in a way that produces - different output than :attr:`tp_repr` or :attr:`tp_str` would. - - The print function is called with the same signature as :cfunc:`PyObject_Print`: - ``int tp_print(PyObject *self, FILE *file, int flags)``. The *self* argument is - the instance to be printed. The *file* argument is the stdio file to which it - is to be printed. The *flags* argument is composed of flag bits. The only flag - bit currently defined is :const:`Py_PRINT_RAW`. When the :const:`Py_PRINT_RAW` - flag bit is set, the instance should be printed the same way as :attr:`tp_str` - would format it; when the :const:`Py_PRINT_RAW` flag bit is clear, the instance - should be printed the same was as :attr:`tp_repr` would format it. It should - return ``-1`` and set an exception condition when an error occurred during the - comparison. - - It is possible that the :attr:`tp_print` field will be deprecated. In any case, - it is recommended not to define :attr:`tp_print`, but instead to rely on - :attr:`tp_repr` and :attr:`tp_str` for printing. - - This field is inherited by subtypes. - - -.. cmember:: getattrfunc PyTypeObject.tp_getattr - - An optional pointer to the get-attribute-string function. - - This field is deprecated. When it is defined, it should point to a function - that acts the same as the :attr:`tp_getattro` function, but taking a C string - instead of a Python string object to give the attribute name. The signature is - the same as for :cfunc:`PyObject_GetAttrString`. - - This field is inherited by subtypes together with :attr:`tp_getattro`: a subtype - inherits both :attr:`tp_getattr` and :attr:`tp_getattro` from its base type when - the subtype's :attr:`tp_getattr` and :attr:`tp_getattro` are both *NULL*. - - -.. cmember:: setattrfunc PyTypeObject.tp_setattr - - An optional pointer to the set-attribute-string function. - - This field is deprecated. When it is defined, it should point to a function - that acts the same as the :attr:`tp_setattro` function, but taking a C string - instead of a Python string object to give the attribute name. The signature is - the same as for :cfunc:`PyObject_SetAttrString`. - - This field is inherited by subtypes together with :attr:`tp_setattro`: a subtype - inherits both :attr:`tp_setattr` and :attr:`tp_setattro` from its base type when - the subtype's :attr:`tp_setattr` and :attr:`tp_setattro` are both *NULL*. - - -.. cmember:: cmpfunc PyTypeObject.tp_compare - - An optional pointer to the three-way comparison function. - - The signature is the same as for :cfunc:`PyObject_Compare`. The function should - return ``1`` if *self* greater than *other*, ``0`` if *self* is equal to - *other*, and ``-1`` if *self* less than *other*. It should return ``-1`` and - set an exception condition when an error occurred during the comparison. - - This field is inherited by subtypes together with :attr:`tp_richcompare` and - :attr:`tp_hash`: a subtypes inherits all three of :attr:`tp_compare`, - :attr:`tp_richcompare`, and :attr:`tp_hash` when the subtype's - :attr:`tp_compare`, :attr:`tp_richcompare`, and :attr:`tp_hash` are all *NULL*. - - -.. cmember:: reprfunc PyTypeObject.tp_repr - - .. index:: builtin: repr - - An optional pointer to a function that implements the built-in function - :func:`repr`. - - The signature is the same as for :cfunc:`PyObject_Repr`; it must return a string - or a Unicode object. Ideally, this function should return a string that, when - passed to :func:`eval`, given a suitable environment, returns an object with the - same value. If this is not feasible, it should return a string starting with - ``'<'`` and ending with ``'>'`` from which both the type and the value of the - object can be deduced. - - When this field is not set, a string of the form ``<%s object at %p>`` is - returned, where ``%s`` is replaced by the type name, and ``%p`` by the object's - memory address. - - This field is inherited by subtypes. - -.. cmember:: PyNumberMethods* tp_as_number - - Pointer to an additional structure that contains fields relevant only to - objects which implement the number protocol. These fields are documented in - :ref:`number-structs`. - - The :attr:`tp_as_number` field is not inherited, but the contained fields are - inherited individually. - - -.. cmember:: PySequenceMethods* tp_as_sequence - - Pointer to an additional structure that contains fields relevant only to - objects which implement the sequence protocol. These fields are documented - in :ref:`sequence-structs`. - - The :attr:`tp_as_sequence` field is not inherited, but the contained fields - are inherited individually. - - -.. cmember:: PyMappingMethods* tp_as_mapping - - Pointer to an additional structure that contains fields relevant only to - objects which implement the mapping protocol. These fields are documented in - :ref:`mapping-structs`. - - The :attr:`tp_as_mapping` field is not inherited, but the contained fields - are inherited individually. - - -.. cmember:: hashfunc PyTypeObject.tp_hash - - .. index:: builtin: hash - - An optional pointer to a function that implements the built-in function - :func:`hash`. - - The signature is the same as for :cfunc:`PyObject_Hash`; it must return a C - long. The value ``-1`` should not be returned as a normal return value; when an - error occurs during the computation of the hash value, the function should set - an exception and return ``-1``. - - When this field is not set, two possibilities exist: if the :attr:`tp_compare` - and :attr:`tp_richcompare` fields are both *NULL*, a default hash value based on - the object's address is returned; otherwise, a :exc:`TypeError` is raised. - - This field is inherited by subtypes together with :attr:`tp_richcompare` and - :attr:`tp_compare`: a subtypes inherits all three of :attr:`tp_compare`, - :attr:`tp_richcompare`, and :attr:`tp_hash`, when the subtype's - :attr:`tp_compare`, :attr:`tp_richcompare` and :attr:`tp_hash` are all *NULL*. - - -.. cmember:: ternaryfunc PyTypeObject.tp_call - - An optional pointer to a function that implements calling the object. This - should be *NULL* if the object is not callable. The signature is the same as - for :cfunc:`PyObject_Call`. - - This field is inherited by subtypes. - - -.. cmember:: reprfunc PyTypeObject.tp_str - - An optional pointer to a function that implements the built-in operation - :func:`str`. (Note that :class:`str` is a type now, and :func:`str` calls the - constructor for that type. This constructor calls :cfunc:`PyObject_Str` to do - the actual work, and :cfunc:`PyObject_Str` will call this handler.) - - The signature is the same as for :cfunc:`PyObject_Str`; it must return a string - or a Unicode object. This function should return a "friendly" string - representation of the object, as this is the representation that will be used by - the print statement. - - When this field is not set, :cfunc:`PyObject_Repr` is called to return a string - representation. - - This field is inherited by subtypes. - - -.. cmember:: getattrofunc PyTypeObject.tp_getattro - - An optional pointer to the get-attribute function. - - The signature is the same as for :cfunc:`PyObject_GetAttr`. It is usually - convenient to set this field to :cfunc:`PyObject_GenericGetAttr`, which - implements the normal way of looking for object attributes. - - This field is inherited by subtypes together with :attr:`tp_getattr`: a subtype - inherits both :attr:`tp_getattr` and :attr:`tp_getattro` from its base type when - the subtype's :attr:`tp_getattr` and :attr:`tp_getattro` are both *NULL*. - - -.. cmember:: setattrofunc PyTypeObject.tp_setattro - - An optional pointer to the set-attribute function. - - The signature is the same as for :cfunc:`PyObject_SetAttr`. It is usually - convenient to set this field to :cfunc:`PyObject_GenericSetAttr`, which - implements the normal way of setting object attributes. - - This field is inherited by subtypes together with :attr:`tp_setattr`: a subtype - inherits both :attr:`tp_setattr` and :attr:`tp_setattro` from its base type when - the subtype's :attr:`tp_setattr` and :attr:`tp_setattro` are both *NULL*. - - -.. cmember:: PyBufferProcs* PyTypeObject.tp_as_buffer - - Pointer to an additional structure that contains fields relevant only to objects - which implement the buffer interface. These fields are documented in - :ref:`buffer-structs`. - - The :attr:`tp_as_buffer` field is not inherited, but the contained fields are - inherited individually. - - -.. cmember:: long PyTypeObject.tp_flags - - This field is a bit mask of various flags. Some flags indicate variant - semantics for certain situations; others are used to indicate that certain - fields in the type object (or in the extension structures referenced via - :attr:`tp_as_number`, :attr:`tp_as_sequence`, :attr:`tp_as_mapping`, and - :attr:`tp_as_buffer`) that were historically not always present are valid; if - such a flag bit is clear, the type fields it guards must not be accessed and - must be considered to have a zero or *NULL* value instead. - - Inheritance of this field is complicated. Most flag bits are inherited - individually, i.e. if the base type has a flag bit set, the subtype inherits - this flag bit. The flag bits that pertain to extension structures are strictly - inherited if the extension structure is inherited, i.e. the base type's value of - the flag bit is copied into the subtype together with a pointer to the extension - structure. The :const:`Py_TPFLAGS_HAVE_GC` flag bit is inherited together with - the :attr:`tp_traverse` and :attr:`tp_clear` fields, i.e. if the - :const:`Py_TPFLAGS_HAVE_GC` flag bit is clear in the subtype and the - :attr:`tp_traverse` and :attr:`tp_clear` fields in the subtype exist (as - indicated by the :const:`Py_TPFLAGS_HAVE_RICHCOMPARE` flag bit) and have *NULL* - values. - - The following bit masks are currently defined; these can be ORed together using - the ``|`` operator to form the value of the :attr:`tp_flags` field. The macro - :cfunc:`PyType_HasFeature` takes a type and a flags value, *tp* and *f*, and - checks whether ``tp->tp_flags & f`` is non-zero. - - - .. data:: Py_TPFLAGS_HAVE_GETCHARBUFFER - - If this bit is set, the :ctype:`PyBufferProcs` struct referenced by - :attr:`tp_as_buffer` has the :attr:`bf_getcharbuffer` field. - - - .. data:: Py_TPFLAGS_HAVE_SEQUENCE_IN - - If this bit is set, the :ctype:`PySequenceMethods` struct referenced by - :attr:`tp_as_sequence` has the :attr:`sq_contains` field. - - - .. data:: Py_TPFLAGS_GC - - This bit is obsolete. The bit it used to name is no longer in use. The symbol - is now defined as zero. - - - .. data:: Py_TPFLAGS_HAVE_INPLACEOPS - - If this bit is set, the :ctype:`PySequenceMethods` struct referenced by - :attr:`tp_as_sequence` and the :ctype:`PyNumberMethods` structure referenced by - :attr:`tp_as_number` contain the fields for in-place operators. In particular, - this means that the :ctype:`PyNumberMethods` structure has the fields - :attr:`nb_inplace_add`, :attr:`nb_inplace_subtract`, - :attr:`nb_inplace_multiply`, :attr:`nb_inplace_divide`, - :attr:`nb_inplace_remainder`, :attr:`nb_inplace_power`, - :attr:`nb_inplace_lshift`, :attr:`nb_inplace_rshift`, :attr:`nb_inplace_and`, - :attr:`nb_inplace_xor`, and :attr:`nb_inplace_or`; and the - :ctype:`PySequenceMethods` struct has the fields :attr:`sq_inplace_concat` and - :attr:`sq_inplace_repeat`. - - - .. data:: Py_TPFLAGS_CHECKTYPES - - If this bit is set, the binary and ternary operations in the - :ctype:`PyNumberMethods` structure referenced by :attr:`tp_as_number` accept - arguments of arbitrary object types, and do their own type conversions if - needed. If this bit is clear, those operations require that all arguments have - the current type as their type, and the caller is supposed to perform a coercion - operation first. This applies to :attr:`nb_add`, :attr:`nb_subtract`, - :attr:`nb_multiply`, :attr:`nb_divide`, :attr:`nb_remainder`, :attr:`nb_divmod`, - :attr:`nb_power`, :attr:`nb_lshift`, :attr:`nb_rshift`, :attr:`nb_and`, - :attr:`nb_xor`, and :attr:`nb_or`. - - - .. data:: Py_TPFLAGS_HAVE_RICHCOMPARE - - If this bit is set, the type object has the :attr:`tp_richcompare` field, as - well as the :attr:`tp_traverse` and the :attr:`tp_clear` fields. - - - .. data:: Py_TPFLAGS_HAVE_WEAKREFS - - If this bit is set, the :attr:`tp_weaklistoffset` field is defined. Instances - of a type are weakly referenceable if the type's :attr:`tp_weaklistoffset` field - has a value greater than zero. - - - .. data:: Py_TPFLAGS_HAVE_ITER - - If this bit is set, the type object has the :attr:`tp_iter` and - :attr:`tp_iternext` fields. - - - .. data:: Py_TPFLAGS_HAVE_CLASS - - If this bit is set, the type object has several new fields defined starting in - Python 2.2: :attr:`tp_methods`, :attr:`tp_members`, :attr:`tp_getset`, - :attr:`tp_base`, :attr:`tp_dict`, :attr:`tp_descr_get`, :attr:`tp_descr_set`, - :attr:`tp_dictoffset`, :attr:`tp_init`, :attr:`tp_alloc`, :attr:`tp_new`, - :attr:`tp_free`, :attr:`tp_is_gc`, :attr:`tp_bases`, :attr:`tp_mro`, - :attr:`tp_cache`, :attr:`tp_subclasses`, and :attr:`tp_weaklist`. - - - .. data:: Py_TPFLAGS_HEAPTYPE - - This bit is set when the type object itself is allocated on the heap. In this - case, the :attr:`ob_type` field of its instances is considered a reference to - the type, and the type object is INCREF'ed when a new instance is created, and - DECREF'ed when an instance is destroyed (this does not apply to instances of - subtypes; only the type referenced by the instance's ob_type gets INCREF'ed or - DECREF'ed). - - - .. data:: Py_TPFLAGS_BASETYPE - - This bit is set when the type can be used as the base type of another type. If - this bit is clear, the type cannot be subtyped (similar to a "final" class in - Java). - - - .. data:: Py_TPFLAGS_READY - - This bit is set when the type object has been fully initialized by - :cfunc:`PyType_Ready`. - - - .. data:: Py_TPFLAGS_READYING - - This bit is set while :cfunc:`PyType_Ready` is in the process of initializing - the type object. - - - .. data:: Py_TPFLAGS_HAVE_GC - - This bit is set when the object supports garbage collection. If this bit - is set, instances must be created using :cfunc:`PyObject_GC_New` and - destroyed using :cfunc:`PyObject_GC_Del`. More information in section - :ref:`supporting-cycle-detection`. This bit also implies that the - GC-related fields :attr:`tp_traverse` and :attr:`tp_clear` are present in - the type object; but those fields also exist when - :const:`Py_TPFLAGS_HAVE_GC` is clear but - :const:`Py_TPFLAGS_HAVE_RICHCOMPARE` is set. - - - .. data:: Py_TPFLAGS_DEFAULT - - This is a bitmask of all the bits that pertain to the existence of certain - fields in the type object and its extension structures. Currently, it includes - the following bits: :const:`Py_TPFLAGS_HAVE_GETCHARBUFFER`, - :const:`Py_TPFLAGS_HAVE_SEQUENCE_IN`, :const:`Py_TPFLAGS_HAVE_INPLACEOPS`, - :const:`Py_TPFLAGS_HAVE_RICHCOMPARE`, :const:`Py_TPFLAGS_HAVE_WEAKREFS`, - :const:`Py_TPFLAGS_HAVE_ITER`, and :const:`Py_TPFLAGS_HAVE_CLASS`. - - -.. cmember:: char* PyTypeObject.tp_doc - - An optional pointer to a NUL-terminated C string giving the docstring for this - type object. This is exposed as the :attr:`__doc__` attribute on the type and - instances of the type. - - This field is *not* inherited by subtypes. - -The following three fields only exist if the -:const:`Py_TPFLAGS_HAVE_RICHCOMPARE` flag bit is set. - - -.. cmember:: traverseproc PyTypeObject.tp_traverse - - An optional pointer to a traversal function for the garbage collector. This is - only used if the :const:`Py_TPFLAGS_HAVE_GC` flag bit is set. More information - about Python's garbage collection scheme can be found in section - :ref:`supporting-cycle-detection`. - - The :attr:`tp_traverse` pointer is used by the garbage collector to detect - reference cycles. A typical implementation of a :attr:`tp_traverse` function - simply calls :cfunc:`Py_VISIT` on each of the instance's members that are Python - objects. For exampe, this is function :cfunc:`local_traverse` from the - :mod:`thread` extension module:: - - static int - local_traverse(localobject *self, visitproc visit, void *arg) - { - Py_VISIT(self->args); - Py_VISIT(self->kw); - Py_VISIT(self->dict); - return 0; - } - - Note that :cfunc:`Py_VISIT` is called only on those members that can participate - in reference cycles. Although there is also a ``self->key`` member, it can only - be *NULL* or a Python string and therefore cannot be part of a reference cycle. - - On the other hand, even if you know a member can never be part of a cycle, as a - debugging aid you may want to visit it anyway just so the :mod:`gc` module's - :func:`get_referents` function will include it. - - Note that :cfunc:`Py_VISIT` requires the *visit* and *arg* parameters to - :cfunc:`local_traverse` to have these specific names; don't name them just - anything. - - This field is inherited by subtypes together with :attr:`tp_clear` and the - :const:`Py_TPFLAGS_HAVE_GC` flag bit: the flag bit, :attr:`tp_traverse`, and - :attr:`tp_clear` are all inherited from the base type if they are all zero in - the subtype *and* the subtype has the :const:`Py_TPFLAGS_HAVE_RICHCOMPARE` flag - bit set. - - -.. cmember:: inquiry PyTypeObject.tp_clear - - An optional pointer to a clear function for the garbage collector. This is only - used if the :const:`Py_TPFLAGS_HAVE_GC` flag bit is set. - - The :attr:`tp_clear` member function is used to break reference cycles in cyclic - garbage detected by the garbage collector. Taken together, all :attr:`tp_clear` - functions in the system must combine to break all reference cycles. This is - subtle, and if in any doubt supply a :attr:`tp_clear` function. For example, - the tuple type does not implement a :attr:`tp_clear` function, because it's - possible to prove that no reference cycle can be composed entirely of tuples. - Therefore the :attr:`tp_clear` functions of other types must be sufficient to - break any cycle containing a tuple. This isn't immediately obvious, and there's - rarely a good reason to avoid implementing :attr:`tp_clear`. - - Implementations of :attr:`tp_clear` should drop the instance's references to - those of its members that may be Python objects, and set its pointers to those - members to *NULL*, as in the following example:: - - static int - local_clear(localobject *self) - { - Py_CLEAR(self->key); - Py_CLEAR(self->args); - Py_CLEAR(self->kw); - Py_CLEAR(self->dict); - return 0; - } - - The :cfunc:`Py_CLEAR` macro should be used, because clearing references is - delicate: the reference to the contained object must not be decremented until - after the pointer to the contained object is set to *NULL*. This is because - decrementing the reference count may cause the contained object to become trash, - triggering a chain of reclamation activity that may include invoking arbitrary - Python code (due to finalizers, or weakref callbacks, associated with the - contained object). If it's possible for such code to reference *self* again, - it's important that the pointer to the contained object be *NULL* at that time, - so that *self* knows the contained object can no longer be used. The - :cfunc:`Py_CLEAR` macro performs the operations in a safe order. - - Because the goal of :attr:`tp_clear` functions is to break reference cycles, - it's not necessary to clear contained objects like Python strings or Python - integers, which can't participate in reference cycles. On the other hand, it may - be convenient to clear all contained Python objects, and write the type's - :attr:`tp_dealloc` function to invoke :attr:`tp_clear`. - - More information about Python's garbage collection scheme can be found in - section :ref:`supporting-cycle-detection`. - - This field is inherited by subtypes together with :attr:`tp_traverse` and the - :const:`Py_TPFLAGS_HAVE_GC` flag bit: the flag bit, :attr:`tp_traverse`, and - :attr:`tp_clear` are all inherited from the base type if they are all zero in - the subtype *and* the subtype has the :const:`Py_TPFLAGS_HAVE_RICHCOMPARE` flag - bit set. - - -.. cmember:: richcmpfunc PyTypeObject.tp_richcompare - - An optional pointer to the rich comparison function. - - The signature is the same as for :cfunc:`PyObject_RichCompare`. The function - should return the result of the comparison (usually ``Py_True`` or - ``Py_False``). If the comparison is undefined, it must return - ``Py_NotImplemented``, if another error occurred it must return ``NULL`` and set - an exception condition. - - This field is inherited by subtypes together with :attr:`tp_compare` and - :attr:`tp_hash`: a subtype inherits all three of :attr:`tp_compare`, - :attr:`tp_richcompare`, and :attr:`tp_hash`, when the subtype's - :attr:`tp_compare`, :attr:`tp_richcompare`, and :attr:`tp_hash` are all *NULL*. - - The following constants are defined to be used as the third argument for - :attr:`tp_richcompare` and for :cfunc:`PyObject_RichCompare`: - - +----------------+------------+ - | Constant | Comparison | - +================+============+ - | :const:`Py_LT` | ``<`` | - +----------------+------------+ - | :const:`Py_LE` | ``<=`` | - +----------------+------------+ - | :const:`Py_EQ` | ``==`` | - +----------------+------------+ - | :const:`Py_NE` | ``!=`` | - +----------------+------------+ - | :const:`Py_GT` | ``>`` | - +----------------+------------+ - | :const:`Py_GE` | ``>=`` | - +----------------+------------+ - -The next field only exists if the :const:`Py_TPFLAGS_HAVE_WEAKREFS` flag bit is -set. - - -.. cmember:: long PyTypeObject.tp_weaklistoffset - - If the instances of this type are weakly referenceable, this field is greater - than zero and contains the offset in the instance structure of the weak - reference list head (ignoring the GC header, if present); this offset is used by - :cfunc:`PyObject_ClearWeakRefs` and the :cfunc:`PyWeakref_\*` functions. The - instance structure needs to include a field of type :ctype:`PyObject\*` which is - initialized to *NULL*. - - Do not confuse this field with :attr:`tp_weaklist`; that is the list head for - weak references to the type object itself. - - This field is inherited by subtypes, but see the rules listed below. A subtype - may override this offset; this means that the subtype uses a different weak - reference list head than the base type. Since the list head is always found via - :attr:`tp_weaklistoffset`, this should not be a problem. - - When a type defined by a class statement has no :attr:`__slots__` declaration, - and none of its base types are weakly referenceable, the type is made weakly - referenceable by adding a weak reference list head slot to the instance layout - and setting the :attr:`tp_weaklistoffset` of that slot's offset. - - When a type's :attr:`__slots__` declaration contains a slot named - :attr:`__weakref__`, that slot becomes the weak reference list head for - instances of the type, and the slot's offset is stored in the type's - :attr:`tp_weaklistoffset`. - - When a type's :attr:`__slots__` declaration does not contain a slot named - :attr:`__weakref__`, the type inherits its :attr:`tp_weaklistoffset` from its - base type. - -The next two fields only exist if the :const:`Py_TPFLAGS_HAVE_CLASS` flag bit is -set. - - -.. cmember:: getiterfunc PyTypeObject.tp_iter - - An optional pointer to a function that returns an iterator for the object. Its - presence normally signals that the instances of this type are iterable (although - sequences may be iterable without this function, and classic instances always - have this function, even if they don't define an :meth:`__iter__` method). - - This function has the same signature as :cfunc:`PyObject_GetIter`. - - This field is inherited by subtypes. - - -.. cmember:: iternextfunc PyTypeObject.tp_iternext - - An optional pointer to a function that returns the next item in an iterator, or - raises :exc:`StopIteration` when the iterator is exhausted. Its presence - normally signals that the instances of this type are iterators (although classic - instances always have this function, even if they don't define a :meth:`next` - method). - - Iterator types should also define the :attr:`tp_iter` function, and that - function should return the iterator instance itself (not a new iterator - instance). - - This function has the same signature as :cfunc:`PyIter_Next`. - - This field is inherited by subtypes. - -The next fields, up to and including :attr:`tp_weaklist`, only exist if the -:const:`Py_TPFLAGS_HAVE_CLASS` flag bit is set. - - -.. cmember:: struct PyMethodDef* PyTypeObject.tp_methods - - An optional pointer to a static *NULL*-terminated array of :ctype:`PyMethodDef` - structures, declaring regular methods of this type. - - For each entry in the array, an entry is added to the type's dictionary (see - :attr:`tp_dict` below) containing a method descriptor. - - This field is not inherited by subtypes (methods are inherited through a - different mechanism). - - -.. cmember:: struct PyMemberDef* PyTypeObject.tp_members - - An optional pointer to a static *NULL*-terminated array of :ctype:`PyMemberDef` - structures, declaring regular data members (fields or slots) of instances of - this type. - - For each entry in the array, an entry is added to the type's dictionary (see - :attr:`tp_dict` below) containing a member descriptor. - - This field is not inherited by subtypes (members are inherited through a - different mechanism). - - -.. cmember:: struct PyGetSetDef* PyTypeObject.tp_getset - - An optional pointer to a static *NULL*-terminated array of :ctype:`PyGetSetDef` - structures, declaring computed attributes of instances of this type. - - For each entry in the array, an entry is added to the type's dictionary (see - :attr:`tp_dict` below) containing a getset descriptor. - - This field is not inherited by subtypes (computed attributes are inherited - through a different mechanism). - - Docs for PyGetSetDef (XXX belong elsewhere):: - - typedef PyObject *(*getter)(PyObject *, void *); - typedef int (*setter)(PyObject *, PyObject *, void *); - - typedef struct PyGetSetDef { - char *name; /* attribute name */ - getter get; /* C function to get the attribute */ - setter set; /* C function to set the attribute */ - char *doc; /* optional doc string */ - void *closure; /* optional additional data for getter and setter */ - } PyGetSetDef; - - -.. cmember:: PyTypeObject* PyTypeObject.tp_base - - An optional pointer to a base type from which type properties are inherited. At - this level, only single inheritance is supported; multiple inheritance require - dynamically creating a type object by calling the metatype. - - This field is not inherited by subtypes (obviously), but it defaults to - ``&PyBaseObject_Type`` (which to Python programmers is known as the type - :class:`object`). - - -.. cmember:: PyObject* PyTypeObject.tp_dict - - The type's dictionary is stored here by :cfunc:`PyType_Ready`. - - This field should normally be initialized to *NULL* before PyType_Ready is - called; it may also be initialized to a dictionary containing initial attributes - for the type. Once :cfunc:`PyType_Ready` has initialized the type, extra - attributes for the type may be added to this dictionary only if they don't - correspond to overloaded operations (like :meth:`__add__`). - - This field is not inherited by subtypes (though the attributes defined in here - are inherited through a different mechanism). - - -.. cmember:: descrgetfunc PyTypeObject.tp_descr_get - - An optional pointer to a "descriptor get" function. - - The function signature is :: - - PyObject * tp_descr_get(PyObject *self, PyObject *obj, PyObject *type); - - XXX explain. - - This field is inherited by subtypes. - - -.. cmember:: descrsetfunc PyTypeObject.tp_descr_set - - An optional pointer to a "descriptor set" function. - - The function signature is :: - - int tp_descr_set(PyObject *self, PyObject *obj, PyObject *value); - - This field is inherited by subtypes. - - XXX explain. - - -.. cmember:: long PyTypeObject.tp_dictoffset - - If the instances of this type have a dictionary containing instance variables, - this field is non-zero and contains the offset in the instances of the type of - the instance variable dictionary; this offset is used by - :cfunc:`PyObject_GenericGetAttr`. - - Do not confuse this field with :attr:`tp_dict`; that is the dictionary for - attributes of the type object itself. - - If the value of this field is greater than zero, it specifies the offset from - the start of the instance structure. If the value is less than zero, it - specifies the offset from the *end* of the instance structure. A negative - offset is more expensive to use, and should only be used when the instance - structure contains a variable-length part. This is used for example to add an - instance variable dictionary to subtypes of :class:`str` or :class:`tuple`. Note - that the :attr:`tp_basicsize` field should account for the dictionary added to - the end in that case, even though the dictionary is not included in the basic - object layout. On a system with a pointer size of 4 bytes, - :attr:`tp_dictoffset` should be set to ``-4`` to indicate that the dictionary is - at the very end of the structure. - - The real dictionary offset in an instance can be computed from a negative - :attr:`tp_dictoffset` as follows:: - - dictoffset = tp_basicsize + abs(ob_size)*tp_itemsize + tp_dictoffset - if dictoffset is not aligned on sizeof(void*): - round up to sizeof(void*) - - where :attr:`tp_basicsize`, :attr:`tp_itemsize` and :attr:`tp_dictoffset` are - taken from the type object, and :attr:`ob_size` is taken from the instance. The - absolute value is taken because long ints use the sign of :attr:`ob_size` to - store the sign of the number. (There's never a need to do this calculation - yourself; it is done for you by :cfunc:`_PyObject_GetDictPtr`.) - - This field is inherited by subtypes, but see the rules listed below. A subtype - may override this offset; this means that the subtype instances store the - dictionary at a difference offset than the base type. Since the dictionary is - always found via :attr:`tp_dictoffset`, this should not be a problem. - - When a type defined by a class statement has no :attr:`__slots__` declaration, - and none of its base types has an instance variable dictionary, a dictionary - slot is added to the instance layout and the :attr:`tp_dictoffset` is set to - that slot's offset. - - When a type defined by a class statement has a :attr:`__slots__` declaration, - the type inherits its :attr:`tp_dictoffset` from its base type. - - (Adding a slot named :attr:`__dict__` to the :attr:`__slots__` declaration does - not have the expected effect, it just causes confusion. Maybe this should be - added as a feature just like :attr:`__weakref__` though.) - - -.. cmember:: initproc PyTypeObject.tp_init - - An optional pointer to an instance initialization function. - - This function corresponds to the :meth:`__init__` method of classes. Like - :meth:`__init__`, it is possible to create an instance without calling - :meth:`__init__`, and it is possible to reinitialize an instance by calling its - :meth:`__init__` method again. - - The function signature is :: - - int tp_init(PyObject *self, PyObject *args, PyObject *kwds) - - The self argument is the instance to be initialized; the *args* and *kwds* - arguments represent positional and keyword arguments of the call to - :meth:`__init__`. - - The :attr:`tp_init` function, if not *NULL*, is called when an instance is - created normally by calling its type, after the type's :attr:`tp_new` function - has returned an instance of the type. If the :attr:`tp_new` function returns an - instance of some other type that is not a subtype of the original type, no - :attr:`tp_init` function is called; if :attr:`tp_new` returns an instance of a - subtype of the original type, the subtype's :attr:`tp_init` is called. (VERSION - NOTE: described here is what is implemented in Python 2.2.1 and later. In - Python 2.2, the :attr:`tp_init` of the type of the object returned by - :attr:`tp_new` was always called, if not *NULL*.) - - This field is inherited by subtypes. - - -.. cmember:: allocfunc PyTypeObject.tp_alloc - - An optional pointer to an instance allocation function. - - The function signature is :: - - PyObject *tp_alloc(PyTypeObject *self, Py_ssize_t nitems) - - The purpose of this function is to separate memory allocation from memory - initialization. It should return a pointer to a block of memory of adequate - length for the instance, suitably aligned, and initialized to zeros, but with - :attr:`ob_refcnt` set to ``1`` and :attr:`ob_type` set to the type argument. If - the type's :attr:`tp_itemsize` is non-zero, the object's :attr:`ob_size` field - should be initialized to *nitems* and the length of the allocated memory block - should be ``tp_basicsize + nitems*tp_itemsize``, rounded up to a multiple of - ``sizeof(void*)``; otherwise, *nitems* is not used and the length of the block - should be :attr:`tp_basicsize`. - - Do not use this function to do any other instance initialization, not even to - allocate additional memory; that should be done by :attr:`tp_new`. - - This field is inherited by static subtypes, but not by dynamic subtypes - (subtypes created by a class statement); in the latter, this field is always set - to :cfunc:`PyType_GenericAlloc`, to force a standard heap allocation strategy. - That is also the recommended value for statically defined types. - - -.. cmember:: newfunc PyTypeObject.tp_new - - An optional pointer to an instance creation function. - - If this function is *NULL* for a particular type, that type cannot be called to - create new instances; presumably there is some other way to create instances, - like a factory function. - - The function signature is :: - - PyObject *tp_new(PyTypeObject *subtype, PyObject *args, PyObject *kwds) - - The subtype argument is the type of the object being created; the *args* and - *kwds* arguments represent positional and keyword arguments of the call to the - type. Note that subtype doesn't have to equal the type whose :attr:`tp_new` - function is called; it may be a subtype of that type (but not an unrelated - type). - - The :attr:`tp_new` function should call ``subtype->tp_alloc(subtype, nitems)`` - to allocate space for the object, and then do only as much further - initialization as is absolutely necessary. Initialization that can safely be - ignored or repeated should be placed in the :attr:`tp_init` handler. A good - rule of thumb is that for immutable types, all initialization should take place - in :attr:`tp_new`, while for mutable types, most initialization should be - deferred to :attr:`tp_init`. - - This field is inherited by subtypes, except it is not inherited by static types - whose :attr:`tp_base` is *NULL* or ``&PyBaseObject_Type``. The latter exception - is a precaution so that old extension types don't become callable simply by - being linked with Python 2.2. - - -.. cmember:: destructor PyTypeObject.tp_free - - An optional pointer to an instance deallocation function. - - The signature of this function has changed slightly: in Python 2.2 and 2.2.1, - its signature is :ctype:`destructor`:: - - void tp_free(PyObject *) - - In Python 2.3 and beyond, its signature is :ctype:`freefunc`:: - - void tp_free(void *) - - The only initializer that is compatible with both versions is ``_PyObject_Del``, - whose definition has suitably adapted in Python 2.3. - - This field is inherited by static subtypes, but not by dynamic subtypes - (subtypes created by a class statement); in the latter, this field is set to a - deallocator suitable to match :cfunc:`PyType_GenericAlloc` and the value of the - :const:`Py_TPFLAGS_HAVE_GC` flag bit. - - -.. cmember:: inquiry PyTypeObject.tp_is_gc - - An optional pointer to a function called by the garbage collector. - - The garbage collector needs to know whether a particular object is collectible - or not. Normally, it is sufficient to look at the object's type's - :attr:`tp_flags` field, and check the :const:`Py_TPFLAGS_HAVE_GC` flag bit. But - some types have a mixture of statically and dynamically allocated instances, and - the statically allocated instances are not collectible. Such types should - define this function; it should return ``1`` for a collectible instance, and - ``0`` for a non-collectible instance. The signature is :: - - int tp_is_gc(PyObject *self) - - (The only example of this are types themselves. The metatype, - :cdata:`PyType_Type`, defines this function to distinguish between statically - and dynamically allocated types.) - - This field is inherited by subtypes. (VERSION NOTE: in Python 2.2, it was not - inherited. It is inherited in 2.2.1 and later versions.) - - -.. cmember:: PyObject* PyTypeObject.tp_bases - - Tuple of base types. - - This is set for types created by a class statement. It should be *NULL* for - statically defined types. - - This field is not inherited. - - -.. cmember:: PyObject* PyTypeObject.tp_mro - - Tuple containing the expanded set of base types, starting with the type itself - and ending with :class:`object`, in Method Resolution Order. - - This field is not inherited; it is calculated fresh by :cfunc:`PyType_Ready`. - - -.. cmember:: PyObject* PyTypeObject.tp_cache - - Unused. Not inherited. Internal use only. - - -.. cmember:: PyObject* PyTypeObject.tp_subclasses - - List of weak references to subclasses. Not inherited. Internal use only. - - -.. cmember:: PyObject* PyTypeObject.tp_weaklist - - Weak reference list head, for weak references to this type object. Not - inherited. Internal use only. - -The remaining fields are only defined if the feature test macro -:const:`COUNT_ALLOCS` is defined, and are for internal use only. They are -documented here for completeness. None of these fields are inherited by -subtypes. - - -.. cmember:: Py_ssize_t PyTypeObject.tp_allocs - - Number of allocations. - - -.. cmember:: Py_ssize_t PyTypeObject.tp_frees - - Number of frees. - - -.. cmember:: Py_ssize_t PyTypeObject.tp_maxalloc - - Maximum simultaneously allocated objects. - - -.. cmember:: PyTypeObject* PyTypeObject.tp_next - - Pointer to the next type object with a non-zero :attr:`tp_allocs` field. - -Also, note that, in a garbage collected Python, tp_dealloc may be called from -any Python thread, not just the thread which created the object (if the object -becomes part of a refcount cycle, that cycle might be collected by a garbage -collection on any thread). This is not a problem for Python API calls, since -the thread on which tp_dealloc is called will own the Global Interpreter Lock -(GIL). However, if the object being destroyed in turn destroys objects from some -other C or C++ library, care should be taken to ensure that destroying those -objects on the thread which called tp_dealloc will not violate any assumptions -of the library. - - -.. _number-structs: - -Number Object Structures -======================== - -.. sectionauthor:: Amaury Forgeot d'Arc - - -.. ctype:: PyNumberMethods - - This structure holds pointers to the functions which an object uses to - implement the number protocol. Almost every function below is used by the - function of similar name documented in the :ref:`number` section. - - Here is the structure definition:: - - typedef struct { - binaryfunc nb_add; - binaryfunc nb_subtract; - binaryfunc nb_multiply; - binaryfunc nb_remainder; - binaryfunc nb_divmod; - ternaryfunc nb_power; - unaryfunc nb_negative; - unaryfunc nb_positive; - unaryfunc nb_absolute; - inquiry nb_nonzero; /* Used by PyObject_IsTrue */ - unaryfunc nb_invert; - binaryfunc nb_lshift; - binaryfunc nb_rshift; - binaryfunc nb_and; - binaryfunc nb_xor; - binaryfunc nb_or; - coercion nb_coerce; /* Used by the coerce() funtion */ - unaryfunc nb_int; - unaryfunc nb_long; - unaryfunc nb_float; - unaryfunc nb_oct; - unaryfunc nb_hex; - - /* Added in release 2.0 */ - binaryfunc nb_inplace_add; - binaryfunc nb_inplace_subtract; - binaryfunc nb_inplace_multiply; - binaryfunc nb_inplace_remainder; - ternaryfunc nb_inplace_power; - binaryfunc nb_inplace_lshift; - binaryfunc nb_inplace_rshift; - binaryfunc nb_inplace_and; - binaryfunc nb_inplace_xor; - binaryfunc nb_inplace_or; - - /* Added in release 2.2 */ - binaryfunc nb_floor_divide; - binaryfunc nb_true_divide; - binaryfunc nb_inplace_floor_divide; - binaryfunc nb_inplace_true_divide; - - /* Added in release 2.5 */ - unaryfunc nb_index; - } PyNumberMethods; - - -Binary and ternary functions may receive different kinds of arguments, depending -on the flag bit :const:`Py_TPFLAGS_CHECKTYPES`: - -- If :const:`Py_TPFLAGS_CHECKTYPES` is not set, the function arguments are - guaranteed to be of the object's type; the caller is responsible for calling - the coercion method specified by the :attr:`nb_coerce` member to convert the - arguments: - - .. cmember:: coercion PyNumberMethods.nb_coerce - - This function is used by :cfunc:`PyNumber_CoerceEx` and has the same - signature. The first argument is always a pointer to an object of the - defined type. If the conversion to a common "larger" type is possible, the - function replaces the pointers with new references to the converted objects - and returns ``0``. If the conversion is not possible, the function returns - ``1``. If an error condition is set, it will return ``-1``. - -- If the :const:`Py_TPFLAGS_CHECKTYPES` flag is set, binary and ternary - functions must check the type of all their operands, and implement the - necessary conversions (at least one of the operands is an instance of the - defined type). This is the recommended way; with Python 3.0 coercion will - disappear completely. - -If the operation is not defined for the given operands, binary and ternary -functions must return ``Py_NotImplemented``, if another error occurred they must -return ``NULL`` and set an exception. - - -.. _mapping-structs: - -Mapping Object Structures -========================= - -.. sectionauthor:: Amaury Forgeot d'Arc - - -.. ctype:: PyMappingMethods - - This structure holds pointers to the functions which an object uses to - implement the mapping protocol. It has three members: - -.. cmember:: lenfunc PyMappingMethods.mp_length - - This function is used by :cfunc:`PyMapping_Length` and - :cfunc:`PyObject_Size`, and has the same signature. This slot may be set to - *NULL* if the object has no defined length. - -.. cmember:: binaryfunc PyMappingMethods.mp_subscript - - This function is used by :cfunc:`PyObject_GetItem` and has the same - signature. This slot must be filled for the :cfunc:`PyMapping_Check` - function to return ``1``, it can be *NULL* otherwise. - -.. cmember:: objobjargproc PyMappingMethods.mp_ass_subscript - - This function is used by :cfunc:`PyObject_SetItem` and has the same - signature. If this slot is *NULL*, the object does not support item - assignment. - - -.. _sequence-structs: - -Sequence Object Structures -========================== - -.. sectionauthor:: Amaury Forgeot d'Arc - - -.. ctype:: PySequenceMethods - - This structure holds pointers to the functions which an object uses to - implement the sequence protocol. - -.. cmember:: lenfunc PySequenceMethods.sq_length - - This function is used by :cfunc:`PySequence_Size` and :cfunc:`PyObject_Size`, - and has the same signature. - -.. cmember:: binaryfunc PySequenceMethods.sq_concat - - This function is used by :cfunc:`PySequence_Concat` and has the same - signature. It is also used by the ``+`` operator, after trying the numeric - addition via the :attr:`tp_as_number.nb_add` slot. - -.. cmember:: ssizeargfunc PySequenceMethods.sq_repeat - - This function is used by :cfunc:`PySequence_Repeat` and has the same - signature. It is also used by the ``*`` operator, after trying numeric - multiplication via the :attr:`tp_as_number.nb_mul` slot. - -.. cmember:: ssizeargfunc PySequenceMethods.sq_item - - This function is used by :cfunc:`PySequence_GetItem` and has the same - signature. This slot must be filled for the :cfunc:`PySequence_Check` - function to return ``1``, it can be *NULL* otherwise. - - Negative indexes are handled as follows: if the :attr:`sq_length` slot is - filled, it is called and the sequence length is used to compute a positive - index which is passed to :attr:`sq_item`. If :attr:`sq_length` is *NULL*, - the index is passed as is to the function. - -.. cmember:: ssizeobjargproc PySequenceMethods.sq_ass_item - - This function is used by :cfunc:`PySequence_SetItem` and has the same - signature. This slot may be left to *NULL* if the object does not support - item assignment. - -.. cmember:: objobjproc PySequenceMethods.sq_contains - - This function may be used by :cfunc:`PySequence_Contains` and has the same - signature. This slot may be left to *NULL*, in this case - :cfunc:`PySequence_Contains` simply traverses the sequence until it finds a - match. - -.. cmember:: binaryfunc PySequenceMethods.sq_inplace_concat - - This function is used by :cfunc:`PySequence_InPlaceConcat` and has the same - signature. It should modify its first operand, and return it. - -.. cmember:: ssizeargfunc PySequenceMethods.sq_inplace_repeat - - This function is used by :cfunc:`PySequence_InPlaceRepeat` and has the same - signature. It should modify its first operand, and return it. - -.. XXX need to explain precedence between mapping and sequence -.. XXX explains when to implement the sq_inplace_* slots - - -.. _buffer-structs: - -Buffer Object Structures -======================== - -.. sectionauthor:: Greg J. Stein - - -The buffer interface exports a model where an object can expose its internal -data as a set of chunks of data, where each chunk is specified as a -pointer/length pair. These chunks are called :dfn:`segments` and are presumed -to be non-contiguous in memory. - -If an object does not export the buffer interface, then its :attr:`tp_as_buffer` -member in the :ctype:`PyTypeObject` structure should be *NULL*. Otherwise, the -:attr:`tp_as_buffer` will point to a :ctype:`PyBufferProcs` structure. - -.. note:: - - It is very important that your :ctype:`PyTypeObject` structure uses - :const:`Py_TPFLAGS_DEFAULT` for the value of the :attr:`tp_flags` member rather - than ``0``. This tells the Python runtime that your :ctype:`PyBufferProcs` - structure contains the :attr:`bf_getcharbuffer` slot. Older versions of Python - did not have this member, so a new Python interpreter using an old extension - needs to be able to test for its presence before using it. - - -.. ctype:: PyBufferProcs - - Structure used to hold the function pointers which define an implementation of - the buffer protocol. - - The first slot is :attr:`bf_getreadbuffer`, of type :ctype:`getreadbufferproc`. - If this slot is *NULL*, then the object does not support reading from the - internal data. This is non-sensical, so implementors should fill this in, but - callers should test that the slot contains a non-*NULL* value. - - The next slot is :attr:`bf_getwritebuffer` having type - :ctype:`getwritebufferproc`. This slot may be *NULL* if the object does not - allow writing into its returned buffers. - - The third slot is :attr:`bf_getsegcount`, with type :ctype:`getsegcountproc`. - This slot must not be *NULL* and is used to inform the caller how many segments - the object contains. Simple objects such as :ctype:`PyString_Type` and - :ctype:`PyBuffer_Type` objects contain a single segment. - - .. index:: single: PyType_HasFeature() - - The last slot is :attr:`bf_getcharbuffer`, of type :ctype:`getcharbufferproc`. - This slot will only be present if the :const:`Py_TPFLAGS_HAVE_GETCHARBUFFER` - flag is present in the :attr:`tp_flags` field of the object's - :ctype:`PyTypeObject`. Before using this slot, the caller should test whether it - is present by using the :cfunc:`PyType_HasFeature` function. If the flag is - present, :attr:`bf_getcharbuffer` may be *NULL*, indicating that the object's - contents cannot be used as *8-bit characters*. The slot function may also raise - an error if the object's contents cannot be interpreted as 8-bit characters. - For example, if the object is an array which is configured to hold floating - point values, an exception may be raised if a caller attempts to use - :attr:`bf_getcharbuffer` to fetch a sequence of 8-bit characters. This notion of - exporting the internal buffers as "text" is used to distinguish between objects - that are binary in nature, and those which have character-based content. - - .. note:: - - The current policy seems to state that these characters may be multi-byte - characters. This implies that a buffer size of *N* does not mean there are *N* - characters present. - - -.. data:: Py_TPFLAGS_HAVE_GETCHARBUFFER - - Flag bit set in the type structure to indicate that the :attr:`bf_getcharbuffer` - slot is known. This being set does not indicate that the object supports the - buffer interface or that the :attr:`bf_getcharbuffer` slot is non-*NULL*. - - -.. ctype:: Py_ssize_t (*readbufferproc) (PyObject *self, Py_ssize_t segment, void **ptrptr) - - Return a pointer to a readable segment of the buffer in ``*ptrptr``. This - function is allowed to raise an exception, in which case it must return ``-1``. - The *segment* which is specified must be zero or positive, and strictly less - than the number of segments returned by the :attr:`bf_getsegcount` slot - function. On success, it returns the length of the segment, and sets - ``*ptrptr`` to a pointer to that memory. - - -.. ctype:: Py_ssize_t (*writebufferproc) (PyObject *self, Py_ssize_t segment, void **ptrptr) - - Return a pointer to a writable memory buffer in ``*ptrptr``, and the length of - that segment as the function return value. The memory buffer must correspond to - buffer segment *segment*. Must return ``-1`` and set an exception on error. - :exc:`TypeError` should be raised if the object only supports read-only buffers, - and :exc:`SystemError` should be raised when *segment* specifies a segment that - doesn't exist. - - .. Why doesn't it raise ValueError for this one? - GJS: because you shouldn't be calling it with an invalid - segment. That indicates a blatant programming error in the C code. - - -.. ctype:: Py_ssize_t (*segcountproc) (PyObject *self, Py_ssize_t *lenp) - - Return the number of memory segments which comprise the buffer. If *lenp* is - not *NULL*, the implementation must report the sum of the sizes (in bytes) of - all segments in ``*lenp``. The function cannot fail. - - -.. ctype:: Py_ssize_t (*charbufferproc) (PyObject *self, Py_ssize_t segment, const char **ptrptr) - - Return the size of the segment *segment* that *ptrptr* is set to. ``*ptrptr`` - is set to the memory buffer. Returns ``-1`` on error. - - -.. _supporting-iteration: - -Supporting the Iterator Protocol -================================ - - -.. _supporting-cycle-detection: - -Supporting Cyclic Garbage Collection -==================================== - -Python's support for detecting and collecting garbage which involves circular -references requires support from object types which are "containers" for other -objects which may also be containers. Types which do not store references to -other objects, or which only store references to atomic types (such as numbers -or strings), do not need to provide any explicit support for garbage collection. - -.. An example showing the use of these interfaces can be found in "Supporting the -.. Cycle Collector (XXX not found: ../ext/example-cycle-support.html)". - -To create a container type, the :attr:`tp_flags` field of the type object must -include the :const:`Py_TPFLAGS_HAVE_GC` and provide an implementation of the -:attr:`tp_traverse` handler. If instances of the type are mutable, a -:attr:`tp_clear` implementation must also be provided. - - -.. data:: Py_TPFLAGS_HAVE_GC - - Objects with a type with this flag set must conform with the rules documented - here. For convenience these objects will be referred to as container objects. - -Constructors for container types must conform to two rules: - -#. The memory for the object must be allocated using :cfunc:`PyObject_GC_New` or - :cfunc:`PyObject_GC_VarNew`. - -#. Once all the fields which may contain references to other containers are - initialized, it must call :cfunc:`PyObject_GC_Track`. - - -.. cfunction:: TYPE* PyObject_GC_New(TYPE, PyTypeObject *type) - - Analogous to :cfunc:`PyObject_New` but for container objects with the - :const:`Py_TPFLAGS_HAVE_GC` flag set. - - -.. cfunction:: TYPE* PyObject_GC_NewVar(TYPE, PyTypeObject *type, Py_ssize_t size) - - Analogous to :cfunc:`PyObject_NewVar` but for container objects with the - :const:`Py_TPFLAGS_HAVE_GC` flag set. - - -.. cfunction:: PyVarObject * PyObject_GC_Resize(PyVarObject *op, Py_ssize_t) - - Resize an object allocated by :cfunc:`PyObject_NewVar`. Returns the resized - object or *NULL* on failure. - - -.. cfunction:: void PyObject_GC_Track(PyObject *op) - - Adds the object *op* to the set of container objects tracked by the collector. - The collector can run at unexpected times so objects must be valid while being - tracked. This should be called once all the fields followed by the - :attr:`tp_traverse` handler become valid, usually near the end of the - constructor. - - -.. cfunction:: void _PyObject_GC_TRACK(PyObject *op) - - A macro version of :cfunc:`PyObject_GC_Track`. It should not be used for - extension modules. - -Similarly, the deallocator for the object must conform to a similar pair of -rules: - -#. Before fields which refer to other containers are invalidated, - :cfunc:`PyObject_GC_UnTrack` must be called. - -#. The object's memory must be deallocated using :cfunc:`PyObject_GC_Del`. - - -.. cfunction:: void PyObject_GC_Del(void *op) - - Releases memory allocated to an object using :cfunc:`PyObject_GC_New` or - :cfunc:`PyObject_GC_NewVar`. - - -.. cfunction:: void PyObject_GC_UnTrack(void *op) - - Remove the object *op* from the set of container objects tracked by the - collector. Note that :cfunc:`PyObject_GC_Track` can be called again on this - object to add it back to the set of tracked objects. The deallocator - (:attr:`tp_dealloc` handler) should call this for the object before any of the - fields used by the :attr:`tp_traverse` handler become invalid. - - -.. cfunction:: void _PyObject_GC_UNTRACK(PyObject *op) - - A macro version of :cfunc:`PyObject_GC_UnTrack`. It should not be used for - extension modules. - -The :attr:`tp_traverse` handler accepts a function parameter of this type: - - -.. ctype:: int (*visitproc)(PyObject *object, void *arg) - - Type of the visitor function passed to the :attr:`tp_traverse` handler. The - function should be called with an object to traverse as *object* and the third - parameter to the :attr:`tp_traverse` handler as *arg*. The Python core uses - several visitor functions to implement cyclic garbage detection; it's not - expected that users will need to write their own visitor functions. - -The :attr:`tp_traverse` handler must have the following type: - - -.. ctype:: int (*traverseproc)(PyObject *self, visitproc visit, void *arg) - - Traversal function for a container object. Implementations must call the - *visit* function for each object directly contained by *self*, with the - parameters to *visit* being the contained object and the *arg* value passed to - the handler. The *visit* function must not be called with a *NULL* object - argument. If *visit* returns a non-zero value that value should be returned - immediately. - -To simplify writing :attr:`tp_traverse` handlers, a :cfunc:`Py_VISIT` macro is -provided. In order to use this macro, the :attr:`tp_traverse` implementation -must name its arguments exactly *visit* and *arg*: - - -.. cfunction:: void Py_VISIT(PyObject *o) - - Call the *visit* callback, with arguments *o* and *arg*. If *visit* returns a - non-zero value, then return it. Using this macro, :attr:`tp_traverse` handlers - look like:: - - static int - my_traverse(Noddy *self, visitproc visit, void *arg) - { - Py_VISIT(self->foo); - Py_VISIT(self->bar); - return 0; - } - - .. versionadded:: 2.4 - -The :attr:`tp_clear` handler must be of the :ctype:`inquiry` type, or *NULL* if -the object is immutable. - - -.. ctype:: int (*inquiry)(PyObject *self) - - Drop references that may have created reference cycles. Immutable objects do - not have to define this method since they can never directly create reference - cycles. Note that the object must still be valid after calling this method - (don't just call :cfunc:`Py_DECREF` on a reference). The collector will call - this method if it detects that this object is involved in a reference cycle. - Added: python/trunk/Doc/c-api/none.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/c-api/none.rst Sat Jan 19 23:08:21 2008 @@ -0,0 +1,28 @@ +.. highlightlang:: c + +.. _noneobject: + +The None Object +--------------- + +.. index:: object: None + +Note that the :ctype:`PyTypeObject` for ``None`` is not directly exposed in the +Python/C API. Since ``None`` is a singleton, testing for object identity (using +``==`` in C) is sufficient. There is no :cfunc:`PyNone_Check` function for the +same reason. + + +.. cvar:: PyObject* Py_None + + The Python ``None`` object, denoting lack of value. This object has no methods. + It needs to be treated just like any other object with respect to reference + counts. + + +.. cmacro:: Py_RETURN_NONE + + Properly handle returning :cdata:`Py_None` from within a C function. + + .. versionadded:: 2.4 + Added: python/trunk/Doc/c-api/number.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/c-api/number.rst Sat Jan 19 23:08:21 2008 @@ -0,0 +1,311 @@ +.. highlightlang:: c + +.. _number: + +Number Protocol +=============== + + +.. cfunction:: int PyNumber_Check(PyObject *o) + + Returns ``1`` if the object *o* provides numeric protocols, and false otherwise. + This function always succeeds. + + +.. cfunction:: PyObject* PyNumber_Add(PyObject *o1, PyObject *o2) + + Returns the result of adding *o1* and *o2*, or *NULL* on failure. This is the + equivalent of the Python expression ``o1 + o2``. + + +.. cfunction:: PyObject* PyNumber_Subtract(PyObject *o1, PyObject *o2) + + Returns the result of subtracting *o2* from *o1*, or *NULL* on failure. This is + the equivalent of the Python expression ``o1 - o2``. + + +.. cfunction:: PyObject* PyNumber_Multiply(PyObject *o1, PyObject *o2) + + Returns the result of multiplying *o1* and *o2*, or *NULL* on failure. This is + the equivalent of the Python expression ``o1 * o2``. + + +.. cfunction:: PyObject* PyNumber_Divide(PyObject *o1, PyObject *o2) + + Returns the result of dividing *o1* by *o2*, or *NULL* on failure. This is the + equivalent of the Python expression ``o1 / o2``. + + +.. cfunction:: PyObject* PyNumber_FloorDivide(PyObject *o1, PyObject *o2) + + Return the floor of *o1* divided by *o2*, or *NULL* on failure. This is + equivalent to the "classic" division of integers. + + .. versionadded:: 2.2 + + +.. cfunction:: PyObject* PyNumber_TrueDivide(PyObject *o1, PyObject *o2) + + Return a reasonable approximation for the mathematical value of *o1* divided by + *o2*, or *NULL* on failure. The return value is "approximate" because binary + floating point numbers are approximate; it is not possible to represent all real + numbers in base two. This function can return a floating point value when + passed two integers. + + .. versionadded:: 2.2 + + +.. cfunction:: PyObject* PyNumber_Remainder(PyObject *o1, PyObject *o2) + + Returns the remainder of dividing *o1* by *o2*, or *NULL* on failure. This is + the equivalent of the Python expression ``o1 % o2``. + + +.. cfunction:: PyObject* PyNumber_Divmod(PyObject *o1, PyObject *o2) + + .. index:: builtin: divmod + + See the built-in function :func:`divmod`. Returns *NULL* on failure. This is + the equivalent of the Python expression ``divmod(o1, o2)``. + + +.. cfunction:: PyObject* PyNumber_Power(PyObject *o1, PyObject *o2, PyObject *o3) + + .. index:: builtin: pow + + See the built-in function :func:`pow`. Returns *NULL* on failure. This is the + equivalent of the Python expression ``pow(o1, o2, o3)``, where *o3* is optional. + If *o3* is to be ignored, pass :cdata:`Py_None` in its place (passing *NULL* for + *o3* would cause an illegal memory access). + + +.. cfunction:: PyObject* PyNumber_Negative(PyObject *o) + + Returns the negation of *o* on success, or *NULL* on failure. This is the + equivalent of the Python expression ``-o``. + + +.. cfunction:: PyObject* PyNumber_Positive(PyObject *o) + + Returns *o* on success, or *NULL* on failure. This is the equivalent of the + Python expression ``+o``. + + +.. cfunction:: PyObject* PyNumber_Absolute(PyObject *o) + + .. index:: builtin: abs + + Returns the absolute value of *o*, or *NULL* on failure. This is the equivalent + of the Python expression ``abs(o)``. + + +.. cfunction:: PyObject* PyNumber_Invert(PyObject *o) + + Returns the bitwise negation of *o* on success, or *NULL* on failure. This is + the equivalent of the Python expression ``~o``. + + +.. cfunction:: PyObject* PyNumber_Lshift(PyObject *o1, PyObject *o2) + + Returns the result of left shifting *o1* by *o2* on success, or *NULL* on + failure. This is the equivalent of the Python expression ``o1 << o2``. + + +.. cfunction:: PyObject* PyNumber_Rshift(PyObject *o1, PyObject *o2) + + Returns the result of right shifting *o1* by *o2* on success, or *NULL* on + failure. This is the equivalent of the Python expression ``o1 >> o2``. + + +.. cfunction:: PyObject* PyNumber_And(PyObject *o1, PyObject *o2) + + Returns the "bitwise and" of *o1* and *o2* on success and *NULL* on failure. + This is the equivalent of the Python expression ``o1 & o2``. + + +.. cfunction:: PyObject* PyNumber_Xor(PyObject *o1, PyObject *o2) + + Returns the "bitwise exclusive or" of *o1* by *o2* on success, or *NULL* on + failure. This is the equivalent of the Python expression ``o1 ^ o2``. + + +.. cfunction:: PyObject* PyNumber_Or(PyObject *o1, PyObject *o2) + + Returns the "bitwise or" of *o1* and *o2* on success, or *NULL* on failure. + This is the equivalent of the Python expression ``o1 | o2``. + + +.. cfunction:: PyObject* PyNumber_InPlaceAdd(PyObject *o1, PyObject *o2) + + Returns the result of adding *o1* and *o2*, or *NULL* on failure. The operation + is done *in-place* when *o1* supports it. This is the equivalent of the Python + statement ``o1 += o2``. + + +.. cfunction:: PyObject* PyNumber_InPlaceSubtract(PyObject *o1, PyObject *o2) + + Returns the result of subtracting *o2* from *o1*, or *NULL* on failure. The + operation is done *in-place* when *o1* supports it. This is the equivalent of + the Python statement ``o1 -= o2``. + + +.. cfunction:: PyObject* PyNumber_InPlaceMultiply(PyObject *o1, PyObject *o2) + + Returns the result of multiplying *o1* and *o2*, or *NULL* on failure. The + operation is done *in-place* when *o1* supports it. This is the equivalent of + the Python statement ``o1 *= o2``. + + +.. cfunction:: PyObject* PyNumber_InPlaceDivide(PyObject *o1, PyObject *o2) + + Returns the result of dividing *o1* by *o2*, or *NULL* on failure. The + operation is done *in-place* when *o1* supports it. This is the equivalent of + the Python statement ``o1 /= o2``. + + +.. cfunction:: PyObject* PyNumber_InPlaceFloorDivide(PyObject *o1, PyObject *o2) + + Returns the mathematical floor of dividing *o1* by *o2*, or *NULL* on failure. + The operation is done *in-place* when *o1* supports it. This is the equivalent + of the Python statement ``o1 //= o2``. + + .. versionadded:: 2.2 + + +.. cfunction:: PyObject* PyNumber_InPlaceTrueDivide(PyObject *o1, PyObject *o2) + + Return a reasonable approximation for the mathematical value of *o1* divided by + *o2*, or *NULL* on failure. The return value is "approximate" because binary + floating point numbers are approximate; it is not possible to represent all real + numbers in base two. This function can return a floating point value when + passed two integers. The operation is done *in-place* when *o1* supports it. + + .. versionadded:: 2.2 + + +.. cfunction:: PyObject* PyNumber_InPlaceRemainder(PyObject *o1, PyObject *o2) + + Returns the remainder of dividing *o1* by *o2*, or *NULL* on failure. The + operation is done *in-place* when *o1* supports it. This is the equivalent of + the Python statement ``o1 %= o2``. + + +.. cfunction:: PyObject* PyNumber_InPlacePower(PyObject *o1, PyObject *o2, PyObject *o3) + + .. index:: builtin: pow + + See the built-in function :func:`pow`. Returns *NULL* on failure. The operation + is done *in-place* when *o1* supports it. This is the equivalent of the Python + statement ``o1 **= o2`` when o3 is :cdata:`Py_None`, or an in-place variant of + ``pow(o1, o2, o3)`` otherwise. If *o3* is to be ignored, pass :cdata:`Py_None` + in its place (passing *NULL* for *o3* would cause an illegal memory access). + + +.. cfunction:: PyObject* PyNumber_InPlaceLshift(PyObject *o1, PyObject *o2) + + Returns the result of left shifting *o1* by *o2* on success, or *NULL* on + failure. The operation is done *in-place* when *o1* supports it. This is the + equivalent of the Python statement ``o1 <<= o2``. + + +.. cfunction:: PyObject* PyNumber_InPlaceRshift(PyObject *o1, PyObject *o2) + + Returns the result of right shifting *o1* by *o2* on success, or *NULL* on + failure. The operation is done *in-place* when *o1* supports it. This is the + equivalent of the Python statement ``o1 >>= o2``. + + +.. cfunction:: PyObject* PyNumber_InPlaceAnd(PyObject *o1, PyObject *o2) + + Returns the "bitwise and" of *o1* and *o2* on success and *NULL* on failure. The + operation is done *in-place* when *o1* supports it. This is the equivalent of + the Python statement ``o1 &= o2``. + + +.. cfunction:: PyObject* PyNumber_InPlaceXor(PyObject *o1, PyObject *o2) + + Returns the "bitwise exclusive or" of *o1* by *o2* on success, or *NULL* on + failure. The operation is done *in-place* when *o1* supports it. This is the + equivalent of the Python statement ``o1 ^= o2``. + + +.. cfunction:: PyObject* PyNumber_InPlaceOr(PyObject *o1, PyObject *o2) + + Returns the "bitwise or" of *o1* and *o2* on success, or *NULL* on failure. The + operation is done *in-place* when *o1* supports it. This is the equivalent of + the Python statement ``o1 |= o2``. + + +.. cfunction:: int PyNumber_Coerce(PyObject **p1, PyObject **p2) + + .. index:: builtin: coerce + + This function takes the addresses of two variables of type :ctype:`PyObject\*`. + If the objects pointed to by ``*p1`` and ``*p2`` have the same type, increment + their reference count and return ``0`` (success). If the objects can be + converted to a common numeric type, replace ``*p1`` and ``*p2`` by their + converted value (with 'new' reference counts), and return ``0``. If no + conversion is possible, or if some other error occurs, return ``-1`` (failure) + and don't increment the reference counts. The call ``PyNumber_Coerce(&o1, + &o2)`` is equivalent to the Python statement ``o1, o2 = coerce(o1, o2)``. + + +.. cfunction:: int PyNumber_CoerceEx(PyObject **p1, PyObject **p2) + + This function is similar to :cfunc:`PyNumber_Coerce`, except that it returns + ``1`` when the conversion is not possible and when no error is raised. + Reference counts are still not increased in this case. + + +.. cfunction:: PyObject* PyNumber_Int(PyObject *o) + + .. index:: builtin: int + + Returns the *o* converted to an integer object on success, or *NULL* on failure. + If the argument is outside the integer range a long object will be returned + instead. This is the equivalent of the Python expression ``int(o)``. + + +.. cfunction:: PyObject* PyNumber_Long(PyObject *o) + + .. index:: builtin: long + + Returns the *o* converted to a long integer object on success, or *NULL* on + failure. This is the equivalent of the Python expression ``long(o)``. + + +.. cfunction:: PyObject* PyNumber_Float(PyObject *o) + + .. index:: builtin: float + + Returns the *o* converted to a float object on success, or *NULL* on failure. + This is the equivalent of the Python expression ``float(o)``. + + +.. cfunction:: PyObject* PyNumber_Index(PyObject *o) + + Returns the *o* converted to a Python int or long on success or *NULL* with a + TypeError exception raised on failure. + + .. versionadded:: 2.5 + + +.. cfunction:: Py_ssize_t PyNumber_AsSsize_t(PyObject *o, PyObject *exc) + + Returns *o* converted to a Py_ssize_t value if *o* can be interpreted as an + integer. If *o* can be converted to a Python int or long but the attempt to + convert to a Py_ssize_t value would raise an :exc:`OverflowError`, then the + *exc* argument is the type of exception that will be raised (usually + :exc:`IndexError` or :exc:`OverflowError`). If *exc* is *NULL*, then the + exception is cleared and the value is clipped to *PY_SSIZE_T_MIN* for a negative + integer or *PY_SSIZE_T_MAX* for a positive integer. + + .. versionadded:: 2.5 + + +.. cfunction:: int PyIndex_Check(PyObject *o) + + Returns True if *o* is an index integer (has the nb_index slot of the + tp_as_number structure filled in). + + .. versionadded:: 2.5 Added: python/trunk/Doc/c-api/objbuffer.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/c-api/objbuffer.rst Sat Jan 19 23:08:21 2008 @@ -0,0 +1,46 @@ +.. highlightlang:: c + +.. _abstract-buffer: + +Buffer Protocol +=============== + + +.. cfunction:: int PyObject_AsCharBuffer(PyObject *obj, const char **buffer, Py_ssize_t *buffer_len) + + Returns a pointer to a read-only memory location useable as character- based + input. The *obj* argument must support the single-segment character buffer + interface. On success, returns ``0``, sets *buffer* to the memory location and + *buffer_len* to the buffer length. Returns ``-1`` and sets a :exc:`TypeError` + on error. + + .. versionadded:: 1.6 + + +.. cfunction:: int PyObject_AsReadBuffer(PyObject *obj, const void **buffer, Py_ssize_t *buffer_len) + + Returns a pointer to a read-only memory location containing arbitrary data. The + *obj* argument must support the single-segment readable buffer interface. On + success, returns ``0``, sets *buffer* to the memory location and *buffer_len* to + the buffer length. Returns ``-1`` and sets a :exc:`TypeError` on error. + + .. versionadded:: 1.6 + + +.. cfunction:: int PyObject_CheckReadBuffer(PyObject *o) + + Returns ``1`` if *o* supports the single-segment readable buffer interface. + Otherwise returns ``0``. + + .. versionadded:: 2.2 + + +.. cfunction:: int PyObject_AsWriteBuffer(PyObject *obj, void **buffer, Py_ssize_t *buffer_len) + + Returns a pointer to a writeable memory location. The *obj* argument must + support the single-segment, character buffer interface. On success, returns + ``0``, sets *buffer* to the memory location and *buffer_len* to the buffer + length. Returns ``-1`` and sets a :exc:`TypeError` on error. + + .. versionadded:: 1.6 + Added: python/trunk/Doc/c-api/object.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/c-api/object.rst Sat Jan 19 23:08:21 2008 @@ -0,0 +1,357 @@ +.. highlightlang:: c + +.. _object: + +Object Protocol +=============== + + +.. cfunction:: int PyObject_Print(PyObject *o, FILE *fp, int flags) + + Print an object *o*, on file *fp*. Returns ``-1`` on error. The flags argument + is used to enable certain printing options. The only option currently supported + is :const:`Py_PRINT_RAW`; if given, the :func:`str` of the object is written + instead of the :func:`repr`. + + +.. cfunction:: int PyObject_HasAttr(PyObject *o, PyObject *attr_name) + + Returns ``1`` if *o* has the attribute *attr_name*, and ``0`` otherwise. This + is equivalent to the Python expression ``hasattr(o, attr_name)``. This function + always succeeds. + + +.. cfunction:: int PyObject_HasAttrString(PyObject *o, const char *attr_name) + + Returns ``1`` if *o* has the attribute *attr_name*, and ``0`` otherwise. This + is equivalent to the Python expression ``hasattr(o, attr_name)``. This function + always succeeds. + + +.. cfunction:: PyObject* PyObject_GetAttr(PyObject *o, PyObject *attr_name) + + Retrieve an attribute named *attr_name* from object *o*. Returns the attribute + value on success, or *NULL* on failure. This is the equivalent of the Python + expression ``o.attr_name``. + + +.. cfunction:: PyObject* PyObject_GetAttrString(PyObject *o, const char *attr_name) + + Retrieve an attribute named *attr_name* from object *o*. Returns the attribute + value on success, or *NULL* on failure. This is the equivalent of the Python + expression ``o.attr_name``. + + +.. cfunction:: int PyObject_SetAttr(PyObject *o, PyObject *attr_name, PyObject *v) + + Set the value of the attribute named *attr_name*, for object *o*, to the value + *v*. Returns ``-1`` on failure. This is the equivalent of the Python statement + ``o.attr_name = v``. + + +.. cfunction:: int PyObject_SetAttrString(PyObject *o, const char *attr_name, PyObject *v) + + Set the value of the attribute named *attr_name*, for object *o*, to the value + *v*. Returns ``-1`` on failure. This is the equivalent of the Python statement + ``o.attr_name = v``. + + +.. cfunction:: int PyObject_DelAttr(PyObject *o, PyObject *attr_name) + + Delete attribute named *attr_name*, for object *o*. Returns ``-1`` on failure. + This is the equivalent of the Python statement ``del o.attr_name``. + + +.. cfunction:: int PyObject_DelAttrString(PyObject *o, const char *attr_name) + + Delete attribute named *attr_name*, for object *o*. Returns ``-1`` on failure. + This is the equivalent of the Python statement ``del o.attr_name``. + + +.. cfunction:: PyObject* PyObject_RichCompare(PyObject *o1, PyObject *o2, int opid) + + Compare the values of *o1* and *o2* using the operation specified by *opid*, + which must be one of :const:`Py_LT`, :const:`Py_LE`, :const:`Py_EQ`, + :const:`Py_NE`, :const:`Py_GT`, or :const:`Py_GE`, corresponding to ``<``, + ``<=``, ``==``, ``!=``, ``>``, or ``>=`` respectively. This is the equivalent of + the Python expression ``o1 op o2``, where ``op`` is the operator corresponding + to *opid*. Returns the value of the comparison on success, or *NULL* on failure. + + +.. cfunction:: int PyObject_RichCompareBool(PyObject *o1, PyObject *o2, int opid) + + Compare the values of *o1* and *o2* using the operation specified by *opid*, + which must be one of :const:`Py_LT`, :const:`Py_LE`, :const:`Py_EQ`, + :const:`Py_NE`, :const:`Py_GT`, or :const:`Py_GE`, corresponding to ``<``, + ``<=``, ``==``, ``!=``, ``>``, or ``>=`` respectively. Returns ``-1`` on error, + ``0`` if the result is false, ``1`` otherwise. This is the equivalent of the + Python expression ``o1 op o2``, where ``op`` is the operator corresponding to + *opid*. + + +.. cfunction:: int PyObject_Cmp(PyObject *o1, PyObject *o2, int *result) + + .. index:: builtin: cmp + + Compare the values of *o1* and *o2* using a routine provided by *o1*, if one + exists, otherwise with a routine provided by *o2*. The result of the comparison + is returned in *result*. Returns ``-1`` on failure. This is the equivalent of + the Python statement ``result = cmp(o1, o2)``. + + +.. cfunction:: int PyObject_Compare(PyObject *o1, PyObject *o2) + + .. index:: builtin: cmp + + Compare the values of *o1* and *o2* using a routine provided by *o1*, if one + exists, otherwise with a routine provided by *o2*. Returns the result of the + comparison on success. On error, the value returned is undefined; use + :cfunc:`PyErr_Occurred` to detect an error. This is equivalent to the Python + expression ``cmp(o1, o2)``. + + +.. cfunction:: PyObject* PyObject_Repr(PyObject *o) + + .. index:: builtin: repr + + Compute a string representation of object *o*. Returns the string + representation on success, *NULL* on failure. This is the equivalent of the + Python expression ``repr(o)``. Called by the :func:`repr` built-in function and + by reverse quotes. + + +.. cfunction:: PyObject* PyObject_Str(PyObject *o) + + .. index:: builtin: str + + Compute a string representation of object *o*. Returns the string + representation on success, *NULL* on failure. This is the equivalent of the + Python expression ``str(o)``. Called by the :func:`str` built-in function and + by the :keyword:`print` statement. + + +.. cfunction:: PyObject* PyObject_Unicode(PyObject *o) + + .. index:: builtin: unicode + + Compute a Unicode string representation of object *o*. Returns the Unicode + string representation on success, *NULL* on failure. This is the equivalent of + the Python expression ``unicode(o)``. Called by the :func:`unicode` built-in + function. + + +.. cfunction:: int PyObject_IsInstance(PyObject *inst, PyObject *cls) + + Returns ``1`` if *inst* is an instance of the class *cls* or a subclass of + *cls*, or ``0`` if not. On error, returns ``-1`` and sets an exception. If + *cls* is a type object rather than a class object, :cfunc:`PyObject_IsInstance` + returns ``1`` if *inst* is of type *cls*. If *cls* is a tuple, the check will + be done against every entry in *cls*. The result will be ``1`` when at least one + of the checks returns ``1``, otherwise it will be ``0``. If *inst* is not a + class instance and *cls* is neither a type object, nor a class object, nor a + tuple, *inst* must have a :attr:`__class__` attribute --- the class relationship + of the value of that attribute with *cls* will be used to determine the result + of this function. + + .. versionadded:: 2.1 + + .. versionchanged:: 2.2 + Support for a tuple as the second argument added. + +Subclass determination is done in a fairly straightforward way, but includes a +wrinkle that implementors of extensions to the class system may want to be aware +of. If :class:`A` and :class:`B` are class objects, :class:`B` is a subclass of +:class:`A` if it inherits from :class:`A` either directly or indirectly. If +either is not a class object, a more general mechanism is used to determine the +class relationship of the two objects. When testing if *B* is a subclass of +*A*, if *A* is *B*, :cfunc:`PyObject_IsSubclass` returns true. If *A* and *B* +are different objects, *B*'s :attr:`__bases__` attribute is searched in a +depth-first fashion for *A* --- the presence of the :attr:`__bases__` attribute +is considered sufficient for this determination. + + +.. cfunction:: int PyObject_IsSubclass(PyObject *derived, PyObject *cls) + + Returns ``1`` if the class *derived* is identical to or derived from the class + *cls*, otherwise returns ``0``. In case of an error, returns ``-1``. If *cls* + is a tuple, the check will be done against every entry in *cls*. The result will + be ``1`` when at least one of the checks returns ``1``, otherwise it will be + ``0``. If either *derived* or *cls* is not an actual class object (or tuple), + this function uses the generic algorithm described above. + + .. versionadded:: 2.1 + + .. versionchanged:: 2.3 + Older versions of Python did not support a tuple as the second argument. + + +.. cfunction:: int PyCallable_Check(PyObject *o) + + Determine if the object *o* is callable. Return ``1`` if the object is callable + and ``0`` otherwise. This function always succeeds. + + +.. cfunction:: PyObject* PyObject_Call(PyObject *callable_object, PyObject *args, PyObject *kw) + + .. index:: builtin: apply + + Call a callable Python object *callable_object*, with arguments given by the + tuple *args*, and named arguments given by the dictionary *kw*. If no named + arguments are needed, *kw* may be *NULL*. *args* must not be *NULL*, use an + empty tuple if no arguments are needed. Returns the result of the call on + success, or *NULL* on failure. This is the equivalent of the Python expression + ``apply(callable_object, args, kw)`` or ``callable_object(*args, **kw)``. + + .. versionadded:: 2.2 + + +.. cfunction:: PyObject* PyObject_CallObject(PyObject *callable_object, PyObject *args) + + .. index:: builtin: apply + + Call a callable Python object *callable_object*, with arguments given by the + tuple *args*. If no arguments are needed, then *args* may be *NULL*. Returns + the result of the call on success, or *NULL* on failure. This is the equivalent + of the Python expression ``apply(callable_object, args)`` or + ``callable_object(*args)``. + + +.. cfunction:: PyObject* PyObject_CallFunction(PyObject *callable, char *format, ...) + + .. index:: builtin: apply + + Call a callable Python object *callable*, with a variable number of C arguments. + The C arguments are described using a :cfunc:`Py_BuildValue` style format + string. The format may be *NULL*, indicating that no arguments are provided. + Returns the result of the call on success, or *NULL* on failure. This is the + equivalent of the Python expression ``apply(callable, args)`` or + ``callable(*args)``. Note that if you only pass :ctype:`PyObject \*` args, + :cfunc:`PyObject_CallFunctionObjArgs` is a faster alternative. + + +.. cfunction:: PyObject* PyObject_CallMethod(PyObject *o, char *method, char *format, ...) + + Call the method named *method* of object *o* with a variable number of C + arguments. The C arguments are described by a :cfunc:`Py_BuildValue` format + string that should produce a tuple. The format may be *NULL*, indicating that + no arguments are provided. Returns the result of the call on success, or *NULL* + on failure. This is the equivalent of the Python expression ``o.method(args)``. + Note that if you only pass :ctype:`PyObject \*` args, + :cfunc:`PyObject_CallMethodObjArgs` is a faster alternative. + + +.. cfunction:: PyObject* PyObject_CallFunctionObjArgs(PyObject *callable, ..., NULL) + + Call a callable Python object *callable*, with a variable number of + :ctype:`PyObject\*` arguments. The arguments are provided as a variable number + of parameters followed by *NULL*. Returns the result of the call on success, or + *NULL* on failure. + + .. versionadded:: 2.2 + + +.. cfunction:: PyObject* PyObject_CallMethodObjArgs(PyObject *o, PyObject *name, ..., NULL) + + Calls a method of the object *o*, where the name of the method is given as a + Python string object in *name*. It is called with a variable number of + :ctype:`PyObject\*` arguments. The arguments are provided as a variable number + of parameters followed by *NULL*. Returns the result of the call on success, or + *NULL* on failure. + + .. versionadded:: 2.2 + + +.. cfunction:: long PyObject_Hash(PyObject *o) + + .. index:: builtin: hash + + Compute and return the hash value of an object *o*. On failure, return ``-1``. + This is the equivalent of the Python expression ``hash(o)``. + + +.. cfunction:: int PyObject_IsTrue(PyObject *o) + + Returns ``1`` if the object *o* is considered to be true, and ``0`` otherwise. + This is equivalent to the Python expression ``not not o``. On failure, return + ``-1``. + + +.. cfunction:: int PyObject_Not(PyObject *o) + + Returns ``0`` if the object *o* is considered to be true, and ``1`` otherwise. + This is equivalent to the Python expression ``not o``. On failure, return + ``-1``. + + +.. cfunction:: PyObject* PyObject_Type(PyObject *o) + + .. index:: builtin: type + + When *o* is non-*NULL*, returns a type object corresponding to the object type + of object *o*. On failure, raises :exc:`SystemError` and returns *NULL*. This + is equivalent to the Python expression ``type(o)``. This function increments the + reference count of the return value. There's really no reason to use this + function instead of the common expression ``o->ob_type``, which returns a + pointer of type :ctype:`PyTypeObject\*`, except when the incremented reference + count is needed. + + +.. cfunction:: int PyObject_TypeCheck(PyObject *o, PyTypeObject *type) + + Return true if the object *o* is of type *type* or a subtype of *type*. Both + parameters must be non-*NULL*. + + .. versionadded:: 2.2 + + +.. cfunction:: Py_ssize_t PyObject_Length(PyObject *o) + Py_ssize_t PyObject_Size(PyObject *o) + + .. index:: builtin: len + + Return the length of object *o*. If the object *o* provides either the sequence + and mapping protocols, the sequence length is returned. On error, ``-1`` is + returned. This is the equivalent to the Python expression ``len(o)``. + + +.. cfunction:: PyObject* PyObject_GetItem(PyObject *o, PyObject *key) + + Return element of *o* corresponding to the object *key* or *NULL* on failure. + This is the equivalent of the Python expression ``o[key]``. + + +.. cfunction:: int PyObject_SetItem(PyObject *o, PyObject *key, PyObject *v) + + Map the object *key* to the value *v*. Returns ``-1`` on failure. This is the + equivalent of the Python statement ``o[key] = v``. + + +.. cfunction:: int PyObject_DelItem(PyObject *o, PyObject *key) + + Delete the mapping for *key* from *o*. Returns ``-1`` on failure. This is the + equivalent of the Python statement ``del o[key]``. + + +.. cfunction:: int PyObject_AsFileDescriptor(PyObject *o) + + Derives a file descriptor from a Python object. If the object is an integer or + long integer, its value is returned. If not, the object's :meth:`fileno` method + is called if it exists; the method must return an integer or long integer, which + is returned as the file descriptor value. Returns ``-1`` on failure. + + +.. cfunction:: PyObject* PyObject_Dir(PyObject *o) + + This is equivalent to the Python expression ``dir(o)``, returning a (possibly + empty) list of strings appropriate for the object argument, or *NULL* if there + was an error. If the argument is *NULL*, this is like the Python ``dir()``, + returning the names of the current locals; in this case, if no execution frame + is active then *NULL* is returned but :cfunc:`PyErr_Occurred` will return false. + + +.. cfunction:: PyObject* PyObject_GetIter(PyObject *o) + + This is equivalent to the Python expression ``iter(o)``. It returns a new + iterator for the object argument, or the object itself if the object is already + an iterator. Raises :exc:`TypeError` and returns *NULL* if the object cannot be + iterated. Copied: python/trunk/Doc/c-api/objimpl.rst (from r60093, python/trunk/Doc/c-api/newtypes.rst) ============================================================================== --- python/trunk/Doc/c-api/newtypes.rst (original) +++ python/trunk/Doc/c-api/objimpl.rst Sat Jan 19 23:08:21 2008 @@ -10,1902 +10,9 @@ This chapter describes the functions, types, and macros used when defining new object types. +.. toctree:: -.. _allocating-objects: - -Allocating Objects on the Heap -============================== - - -.. cfunction:: PyObject* _PyObject_New(PyTypeObject *type) - - -.. cfunction:: PyVarObject* _PyObject_NewVar(PyTypeObject *type, Py_ssize_t size) - - -.. cfunction:: void _PyObject_Del(PyObject *op) - - -.. cfunction:: PyObject* PyObject_Init(PyObject *op, PyTypeObject *type) - - Initialize a newly-allocated object *op* with its type and initial reference. - Returns the initialized object. If *type* indicates that the object - participates in the cyclic garbage detector, it is added to the detector's set - of observed objects. Other fields of the object are not affected. - - -.. cfunction:: PyVarObject* PyObject_InitVar(PyVarObject *op, PyTypeObject *type, Py_ssize_t size) - - This does everything :cfunc:`PyObject_Init` does, and also initializes the - length information for a variable-size object. - - -.. cfunction:: TYPE* PyObject_New(TYPE, PyTypeObject *type) - - Allocate a new Python object using the C structure type *TYPE* and the Python - type object *type*. Fields not defined by the Python object header are not - initialized; the object's reference count will be one. The size of the memory - allocation is determined from the :attr:`tp_basicsize` field of the type object. - - -.. cfunction:: TYPE* PyObject_NewVar(TYPE, PyTypeObject *type, Py_ssize_t size) - - Allocate a new Python object using the C structure type *TYPE* and the Python - type object *type*. Fields not defined by the Python object header are not - initialized. The allocated memory allows for the *TYPE* structure plus *size* - fields of the size given by the :attr:`tp_itemsize` field of *type*. This is - useful for implementing objects like tuples, which are able to determine their - size at construction time. Embedding the array of fields into the same - allocation decreases the number of allocations, improving the memory management - efficiency. - - -.. cfunction:: void PyObject_Del(PyObject *op) - - Releases memory allocated to an object using :cfunc:`PyObject_New` or - :cfunc:`PyObject_NewVar`. This is normally called from the :attr:`tp_dealloc` - handler specified in the object's type. The fields of the object should not be - accessed after this call as the memory is no longer a valid Python object. - - -.. cfunction:: PyObject* Py_InitModule(char *name, PyMethodDef *methods) - - Create a new module object based on a name and table of functions, returning the - new module object. - - .. versionchanged:: 2.3 - Older versions of Python did not support *NULL* as the value for the *methods* - argument. - - -.. cfunction:: PyObject* Py_InitModule3(char *name, PyMethodDef *methods, char *doc) - - Create a new module object based on a name and table of functions, returning the - new module object. If *doc* is non-*NULL*, it will be used to define the - docstring for the module. - - .. versionchanged:: 2.3 - Older versions of Python did not support *NULL* as the value for the *methods* - argument. - - -.. cfunction:: PyObject* Py_InitModule4(char *name, PyMethodDef *methods, char *doc, PyObject *self, int apiver) - - Create a new module object based on a name and table of functions, returning the - new module object. If *doc* is non-*NULL*, it will be used to define the - docstring for the module. If *self* is non-*NULL*, it will passed to the - functions of the module as their (otherwise *NULL*) first parameter. (This was - added as an experimental feature, and there are no known uses in the current - version of Python.) For *apiver*, the only value which should be passed is - defined by the constant :const:`PYTHON_API_VERSION`. - - .. note:: - - Most uses of this function should probably be using the :cfunc:`Py_InitModule3` - instead; only use this if you are sure you need it. - - .. versionchanged:: 2.3 - Older versions of Python did not support *NULL* as the value for the *methods* - argument. - - -.. cvar:: PyObject _Py_NoneStruct - - Object which is visible in Python as ``None``. This should only be accessed - using the ``Py_None`` macro, which evaluates to a pointer to this object. - - -.. _common-structs: - -Common Object Structures -======================== - -There are a large number of structures which are used in the definition of -object types for Python. This section describes these structures and how they -are used. - -All Python objects ultimately share a small number of fields at the beginning of -the object's representation in memory. These are represented by the -:ctype:`PyObject` and :ctype:`PyVarObject` types, which are defined, in turn, by -the expansions of some macros also used, whether directly or indirectly, in the -definition of all other Python objects. - - -.. ctype:: PyObject - - All object types are extensions of this type. This is a type which contains the - information Python needs to treat a pointer to an object as an object. In a - normal "release" build, it contains only the objects reference count and a - pointer to the corresponding type object. It corresponds to the fields defined - by the expansion of the ``PyObject_HEAD`` macro. - - -.. ctype:: PyVarObject - - This is an extension of :ctype:`PyObject` that adds the :attr:`ob_size` field. - This is only used for objects that have some notion of *length*. This type does - not often appear in the Python/C API. It corresponds to the fields defined by - the expansion of the ``PyObject_VAR_HEAD`` macro. - -These macros are used in the definition of :ctype:`PyObject` and -:ctype:`PyVarObject`: - - -.. cmacro:: PyObject_HEAD - - This is a macro which expands to the declarations of the fields of the - :ctype:`PyObject` type; it is used when declaring new types which represent - objects without a varying length. The specific fields it expands to depend on - the definition of :cmacro:`Py_TRACE_REFS`. By default, that macro is not - defined, and :cmacro:`PyObject_HEAD` expands to:: - - Py_ssize_t ob_refcnt; - PyTypeObject *ob_type; - - When :cmacro:`Py_TRACE_REFS` is defined, it expands to:: - - PyObject *_ob_next, *_ob_prev; - Py_ssize_t ob_refcnt; - PyTypeObject *ob_type; - - -.. cmacro:: PyObject_VAR_HEAD - - This is a macro which expands to the declarations of the fields of the - :ctype:`PyVarObject` type; it is used when declaring new types which represent - objects with a length that varies from instance to instance. This macro always - expands to:: - - PyObject_HEAD - Py_ssize_t ob_size; - - Note that :cmacro:`PyObject_HEAD` is part of the expansion, and that its own - expansion varies depending on the definition of :cmacro:`Py_TRACE_REFS`. - -PyObject_HEAD_INIT - - -.. ctype:: PyCFunction - - Type of the functions used to implement most Python callables in C. Functions of - this type take two :ctype:`PyObject\*` parameters and return one such value. If - the return value is *NULL*, an exception shall have been set. If not *NULL*, - the return value is interpreted as the return value of the function as exposed - in Python. The function must return a new reference. - - -.. ctype:: PyMethodDef - - Structure used to describe a method of an extension type. This structure has - four fields: - - +------------------+-------------+-------------------------------+ - | Field | C Type | Meaning | - +==================+=============+===============================+ - | :attr:`ml_name` | char \* | name of the method | - +------------------+-------------+-------------------------------+ - | :attr:`ml_meth` | PyCFunction | pointer to the C | - | | | implementation | - +------------------+-------------+-------------------------------+ - | :attr:`ml_flags` | int | flag bits indicating how the | - | | | call should be constructed | - +------------------+-------------+-------------------------------+ - | :attr:`ml_doc` | char \* | points to the contents of the | - | | | docstring | - +------------------+-------------+-------------------------------+ - -The :attr:`ml_meth` is a C function pointer. The functions may be of different -types, but they always return :ctype:`PyObject\*`. If the function is not of -the :ctype:`PyCFunction`, the compiler will require a cast in the method table. -Even though :ctype:`PyCFunction` defines the first parameter as -:ctype:`PyObject\*`, it is common that the method implementation uses a the -specific C type of the *self* object. - -The :attr:`ml_flags` field is a bitfield which can include the following flags. -The individual flags indicate either a calling convention or a binding -convention. Of the calling convention flags, only :const:`METH_VARARGS` and -:const:`METH_KEYWORDS` can be combined (but note that :const:`METH_KEYWORDS` -alone is equivalent to ``METH_VARARGS | METH_KEYWORDS``). Any of the calling -convention flags can be combined with a binding flag. - - -.. data:: METH_VARARGS - - This is the typical calling convention, where the methods have the type - :ctype:`PyCFunction`. The function expects two :ctype:`PyObject\*` values. The - first one is the *self* object for methods; for module functions, it has the - value given to :cfunc:`Py_InitModule4` (or *NULL* if :cfunc:`Py_InitModule` was - used). The second parameter (often called *args*) is a tuple object - representing all arguments. This parameter is typically processed using - :cfunc:`PyArg_ParseTuple` or :cfunc:`PyArg_UnpackTuple`. - - -.. data:: METH_KEYWORDS - - Methods with these flags must be of type :ctype:`PyCFunctionWithKeywords`. The - function expects three parameters: *self*, *args*, and a dictionary of all the - keyword arguments. The flag is typically combined with :const:`METH_VARARGS`, - and the parameters are typically processed using - :cfunc:`PyArg_ParseTupleAndKeywords`. - - -.. data:: METH_NOARGS - - Methods without parameters don't need to check whether arguments are given if - they are listed with the :const:`METH_NOARGS` flag. They need to be of type - :ctype:`PyCFunction`. When used with object methods, the first parameter is - typically named ``self`` and will hold a reference to the object instance. In - all cases the second parameter will be *NULL*. - - -.. data:: METH_O - - Methods with a single object argument can be listed with the :const:`METH_O` - flag, instead of invoking :cfunc:`PyArg_ParseTuple` with a ``"O"`` argument. - They have the type :ctype:`PyCFunction`, with the *self* parameter, and a - :ctype:`PyObject\*` parameter representing the single argument. - - -.. data:: METH_OLDARGS - - This calling convention is deprecated. The method must be of type - :ctype:`PyCFunction`. The second argument is *NULL* if no arguments are given, - a single object if exactly one argument is given, and a tuple of objects if more - than one argument is given. There is no way for a function using this - convention to distinguish between a call with multiple arguments and a call with - a tuple as the only argument. - -These two constants are not used to indicate the calling convention but the -binding when use with methods of classes. These may not be used for functions -defined for modules. At most one of these flags may be set for any given -method. - - -.. data:: METH_CLASS - - .. index:: builtin: classmethod - - The method will be passed the type object as the first parameter rather than an - instance of the type. This is used to create *class methods*, similar to what - is created when using the :func:`classmethod` built-in function. - - .. versionadded:: 2.3 - - -.. data:: METH_STATIC - - .. index:: builtin: staticmethod - - The method will be passed *NULL* as the first parameter rather than an instance - of the type. This is used to create *static methods*, similar to what is - created when using the :func:`staticmethod` built-in function. - - .. versionadded:: 2.3 - -One other constant controls whether a method is loaded in place of another -definition with the same method name. - - -.. data:: METH_COEXIST - - The method will be loaded in place of existing definitions. Without - *METH_COEXIST*, the default is to skip repeated definitions. Since slot - wrappers are loaded before the method table, the existence of a *sq_contains* - slot, for example, would generate a wrapped method named :meth:`__contains__` - and preclude the loading of a corresponding PyCFunction with the same name. - With the flag defined, the PyCFunction will be loaded in place of the wrapper - object and will co-exist with the slot. This is helpful because calls to - PyCFunctions are optimized more than wrapper object calls. - - .. versionadded:: 2.4 - - -.. cfunction:: PyObject* Py_FindMethod(PyMethodDef table[], PyObject *ob, char *name) - - Return a bound method object for an extension type implemented in C. This can - be useful in the implementation of a :attr:`tp_getattro` or :attr:`tp_getattr` - handler that does not use the :cfunc:`PyObject_GenericGetAttr` function. - - -.. _type-structs: - -Type Objects -============ - -Perhaps one of the most important structures of the Python object system is the -structure that defines a new type: the :ctype:`PyTypeObject` structure. Type -objects can be handled using any of the :cfunc:`PyObject_\*` or -:cfunc:`PyType_\*` functions, but do not offer much that's interesting to most -Python applications. These objects are fundamental to how objects behave, so -they are very important to the interpreter itself and to any extension module -that implements new types. - -Type objects are fairly large compared to most of the standard types. The reason -for the size is that each type object stores a large number of values, mostly C -function pointers, each of which implements a small part of the type's -functionality. The fields of the type object are examined in detail in this -section. The fields will be described in the order in which they occur in the -structure. - -Typedefs: unaryfunc, binaryfunc, ternaryfunc, inquiry, coercion, intargfunc, -intintargfunc, intobjargproc, intintobjargproc, objobjargproc, destructor, -freefunc, printfunc, getattrfunc, getattrofunc, setattrfunc, setattrofunc, -cmpfunc, reprfunc, hashfunc - -The structure definition for :ctype:`PyTypeObject` can be found in -:file:`Include/object.h`. For convenience of reference, this repeats the -definition found there: - -.. literalinclude:: ../includes/typestruct.h - - -The type object structure extends the :ctype:`PyVarObject` structure. The -:attr:`ob_size` field is used for dynamic types (created by :func:`type_new`, -usually called from a class statement). Note that :cdata:`PyType_Type` (the -metatype) initializes :attr:`tp_itemsize`, which means that its instances (i.e. -type objects) *must* have the :attr:`ob_size` field. - - -.. cmember:: PyObject* PyObject._ob_next - PyObject* PyObject._ob_prev - - These fields are only present when the macro ``Py_TRACE_REFS`` is defined. - Their initialization to *NULL* is taken care of by the ``PyObject_HEAD_INIT`` - macro. For statically allocated objects, these fields always remain *NULL*. - For dynamically allocated objects, these two fields are used to link the object - into a doubly-linked list of *all* live objects on the heap. This could be used - for various debugging purposes; currently the only use is to print the objects - that are still alive at the end of a run when the environment variable - :envvar:`PYTHONDUMPREFS` is set. - - These fields are not inherited by subtypes. - - -.. cmember:: Py_ssize_t PyObject.ob_refcnt - - This is the type object's reference count, initialized to ``1`` by the - ``PyObject_HEAD_INIT`` macro. Note that for statically allocated type objects, - the type's instances (objects whose :attr:`ob_type` points back to the type) do - *not* count as references. But for dynamically allocated type objects, the - instances *do* count as references. - - This field is not inherited by subtypes. - - -.. cmember:: PyTypeObject* PyObject.ob_type - - This is the type's type, in other words its metatype. It is initialized by the - argument to the ``PyObject_HEAD_INIT`` macro, and its value should normally be - ``&PyType_Type``. However, for dynamically loadable extension modules that must - be usable on Windows (at least), the compiler complains that this is not a valid - initializer. Therefore, the convention is to pass *NULL* to the - ``PyObject_HEAD_INIT`` macro and to initialize this field explicitly at the - start of the module's initialization function, before doing anything else. This - is typically done like this:: - - Foo_Type.ob_type = &PyType_Type; - - This should be done before any instances of the type are created. - :cfunc:`PyType_Ready` checks if :attr:`ob_type` is *NULL*, and if so, - initializes it: in Python 2.2, it is set to ``&PyType_Type``; in Python 2.2.1 - and later it is initialized to the :attr:`ob_type` field of the base class. - :cfunc:`PyType_Ready` will not change this field if it is non-zero. - - In Python 2.2, this field is not inherited by subtypes. In 2.2.1, and in 2.3 - and beyond, it is inherited by subtypes. - - -.. cmember:: Py_ssize_t PyVarObject.ob_size - - For statically allocated type objects, this should be initialized to zero. For - dynamically allocated type objects, this field has a special internal meaning. - - This field is not inherited by subtypes. - - -.. cmember:: char* PyTypeObject.tp_name - - Pointer to a NUL-terminated string containing the name of the type. For types - that are accessible as module globals, the string should be the full module - name, followed by a dot, followed by the type name; for built-in types, it - should be just the type name. If the module is a submodule of a package, the - full package name is part of the full module name. For example, a type named - :class:`T` defined in module :mod:`M` in subpackage :mod:`Q` in package :mod:`P` - should have the :attr:`tp_name` initializer ``"P.Q.M.T"``. - - For dynamically allocated type objects, this should just be the type name, and - the module name explicitly stored in the type dict as the value for key - ``'__module__'``. - - For statically allocated type objects, the tp_name field should contain a dot. - Everything before the last dot is made accessible as the :attr:`__module__` - attribute, and everything after the last dot is made accessible as the - :attr:`__name__` attribute. - - If no dot is present, the entire :attr:`tp_name` field is made accessible as the - :attr:`__name__` attribute, and the :attr:`__module__` attribute is undefined - (unless explicitly set in the dictionary, as explained above). This means your - type will be impossible to pickle. - - This field is not inherited by subtypes. - - -.. cmember:: Py_ssize_t PyTypeObject.tp_basicsize - Py_ssize_t PyTypeObject.tp_itemsize - - These fields allow calculating the size in bytes of instances of the type. - - There are two kinds of types: types with fixed-length instances have a zero - :attr:`tp_itemsize` field, types with variable-length instances have a non-zero - :attr:`tp_itemsize` field. For a type with fixed-length instances, all - instances have the same size, given in :attr:`tp_basicsize`. - - For a type with variable-length instances, the instances must have an - :attr:`ob_size` field, and the instance size is :attr:`tp_basicsize` plus N - times :attr:`tp_itemsize`, where N is the "length" of the object. The value of - N is typically stored in the instance's :attr:`ob_size` field. There are - exceptions: for example, long ints use a negative :attr:`ob_size` to indicate a - negative number, and N is ``abs(ob_size)`` there. Also, the presence of an - :attr:`ob_size` field in the instance layout doesn't mean that the instance - structure is variable-length (for example, the structure for the list type has - fixed-length instances, yet those instances have a meaningful :attr:`ob_size` - field). - - The basic size includes the fields in the instance declared by the macro - :cmacro:`PyObject_HEAD` or :cmacro:`PyObject_VAR_HEAD` (whichever is used to - declare the instance struct) and this in turn includes the :attr:`_ob_prev` and - :attr:`_ob_next` fields if they are present. This means that the only correct - way to get an initializer for the :attr:`tp_basicsize` is to use the - ``sizeof`` operator on the struct used to declare the instance layout. - The basic size does not include the GC header size (this is new in Python 2.2; - in 2.1 and 2.0, the GC header size was included in :attr:`tp_basicsize`). - - These fields are inherited separately by subtypes. If the base type has a - non-zero :attr:`tp_itemsize`, it is generally not safe to set - :attr:`tp_itemsize` to a different non-zero value in a subtype (though this - depends on the implementation of the base type). - - A note about alignment: if the variable items require a particular alignment, - this should be taken care of by the value of :attr:`tp_basicsize`. Example: - suppose a type implements an array of ``double``. :attr:`tp_itemsize` is - ``sizeof(double)``. It is the programmer's responsibility that - :attr:`tp_basicsize` is a multiple of ``sizeof(double)`` (assuming this is the - alignment requirement for ``double``). - - -.. cmember:: destructor PyTypeObject.tp_dealloc - - A pointer to the instance destructor function. This function must be defined - unless the type guarantees that its instances will never be deallocated (as is - the case for the singletons ``None`` and ``Ellipsis``). - - The destructor function is called by the :cfunc:`Py_DECREF` and - :cfunc:`Py_XDECREF` macros when the new reference count is zero. At this point, - the instance is still in existence, but there are no references to it. The - destructor function should free all references which the instance owns, free all - memory buffers owned by the instance (using the freeing function corresponding - to the allocation function used to allocate the buffer), and finally (as its - last action) call the type's :attr:`tp_free` function. If the type is not - subtypable (doesn't have the :const:`Py_TPFLAGS_BASETYPE` flag bit set), it is - permissible to call the object deallocator directly instead of via - :attr:`tp_free`. The object deallocator should be the one used to allocate the - instance; this is normally :cfunc:`PyObject_Del` if the instance was allocated - using :cfunc:`PyObject_New` or :cfunc:`PyObject_VarNew`, or - :cfunc:`PyObject_GC_Del` if the instance was allocated using - :cfunc:`PyObject_GC_New` or :cfunc:`PyObject_GC_VarNew`. - - This field is inherited by subtypes. - - -.. cmember:: printfunc PyTypeObject.tp_print - - An optional pointer to the instance print function. - - The print function is only called when the instance is printed to a *real* file; - when it is printed to a pseudo-file (like a :class:`StringIO` instance), the - instance's :attr:`tp_repr` or :attr:`tp_str` function is called to convert it to - a string. These are also called when the type's :attr:`tp_print` field is - *NULL*. A type should never implement :attr:`tp_print` in a way that produces - different output than :attr:`tp_repr` or :attr:`tp_str` would. - - The print function is called with the same signature as :cfunc:`PyObject_Print`: - ``int tp_print(PyObject *self, FILE *file, int flags)``. The *self* argument is - the instance to be printed. The *file* argument is the stdio file to which it - is to be printed. The *flags* argument is composed of flag bits. The only flag - bit currently defined is :const:`Py_PRINT_RAW`. When the :const:`Py_PRINT_RAW` - flag bit is set, the instance should be printed the same way as :attr:`tp_str` - would format it; when the :const:`Py_PRINT_RAW` flag bit is clear, the instance - should be printed the same was as :attr:`tp_repr` would format it. It should - return ``-1`` and set an exception condition when an error occurred during the - comparison. - - It is possible that the :attr:`tp_print` field will be deprecated. In any case, - it is recommended not to define :attr:`tp_print`, but instead to rely on - :attr:`tp_repr` and :attr:`tp_str` for printing. - - This field is inherited by subtypes. - - -.. cmember:: getattrfunc PyTypeObject.tp_getattr - - An optional pointer to the get-attribute-string function. - - This field is deprecated. When it is defined, it should point to a function - that acts the same as the :attr:`tp_getattro` function, but taking a C string - instead of a Python string object to give the attribute name. The signature is - the same as for :cfunc:`PyObject_GetAttrString`. - - This field is inherited by subtypes together with :attr:`tp_getattro`: a subtype - inherits both :attr:`tp_getattr` and :attr:`tp_getattro` from its base type when - the subtype's :attr:`tp_getattr` and :attr:`tp_getattro` are both *NULL*. - - -.. cmember:: setattrfunc PyTypeObject.tp_setattr - - An optional pointer to the set-attribute-string function. - - This field is deprecated. When it is defined, it should point to a function - that acts the same as the :attr:`tp_setattro` function, but taking a C string - instead of a Python string object to give the attribute name. The signature is - the same as for :cfunc:`PyObject_SetAttrString`. - - This field is inherited by subtypes together with :attr:`tp_setattro`: a subtype - inherits both :attr:`tp_setattr` and :attr:`tp_setattro` from its base type when - the subtype's :attr:`tp_setattr` and :attr:`tp_setattro` are both *NULL*. - - -.. cmember:: cmpfunc PyTypeObject.tp_compare - - An optional pointer to the three-way comparison function. - - The signature is the same as for :cfunc:`PyObject_Compare`. The function should - return ``1`` if *self* greater than *other*, ``0`` if *self* is equal to - *other*, and ``-1`` if *self* less than *other*. It should return ``-1`` and - set an exception condition when an error occurred during the comparison. - - This field is inherited by subtypes together with :attr:`tp_richcompare` and - :attr:`tp_hash`: a subtypes inherits all three of :attr:`tp_compare`, - :attr:`tp_richcompare`, and :attr:`tp_hash` when the subtype's - :attr:`tp_compare`, :attr:`tp_richcompare`, and :attr:`tp_hash` are all *NULL*. - - -.. cmember:: reprfunc PyTypeObject.tp_repr - - .. index:: builtin: repr - - An optional pointer to a function that implements the built-in function - :func:`repr`. - - The signature is the same as for :cfunc:`PyObject_Repr`; it must return a string - or a Unicode object. Ideally, this function should return a string that, when - passed to :func:`eval`, given a suitable environment, returns an object with the - same value. If this is not feasible, it should return a string starting with - ``'<'`` and ending with ``'>'`` from which both the type and the value of the - object can be deduced. - - When this field is not set, a string of the form ``<%s object at %p>`` is - returned, where ``%s`` is replaced by the type name, and ``%p`` by the object's - memory address. - - This field is inherited by subtypes. - -.. cmember:: PyNumberMethods* tp_as_number - - Pointer to an additional structure that contains fields relevant only to - objects which implement the number protocol. These fields are documented in - :ref:`number-structs`. - - The :attr:`tp_as_number` field is not inherited, but the contained fields are - inherited individually. - - -.. cmember:: PySequenceMethods* tp_as_sequence - - Pointer to an additional structure that contains fields relevant only to - objects which implement the sequence protocol. These fields are documented - in :ref:`sequence-structs`. - - The :attr:`tp_as_sequence` field is not inherited, but the contained fields - are inherited individually. - - -.. cmember:: PyMappingMethods* tp_as_mapping - - Pointer to an additional structure that contains fields relevant only to - objects which implement the mapping protocol. These fields are documented in - :ref:`mapping-structs`. - - The :attr:`tp_as_mapping` field is not inherited, but the contained fields - are inherited individually. - - -.. cmember:: hashfunc PyTypeObject.tp_hash - - .. index:: builtin: hash - - An optional pointer to a function that implements the built-in function - :func:`hash`. - - The signature is the same as for :cfunc:`PyObject_Hash`; it must return a C - long. The value ``-1`` should not be returned as a normal return value; when an - error occurs during the computation of the hash value, the function should set - an exception and return ``-1``. - - When this field is not set, two possibilities exist: if the :attr:`tp_compare` - and :attr:`tp_richcompare` fields are both *NULL*, a default hash value based on - the object's address is returned; otherwise, a :exc:`TypeError` is raised. - - This field is inherited by subtypes together with :attr:`tp_richcompare` and - :attr:`tp_compare`: a subtypes inherits all three of :attr:`tp_compare`, - :attr:`tp_richcompare`, and :attr:`tp_hash`, when the subtype's - :attr:`tp_compare`, :attr:`tp_richcompare` and :attr:`tp_hash` are all *NULL*. - - -.. cmember:: ternaryfunc PyTypeObject.tp_call - - An optional pointer to a function that implements calling the object. This - should be *NULL* if the object is not callable. The signature is the same as - for :cfunc:`PyObject_Call`. - - This field is inherited by subtypes. - - -.. cmember:: reprfunc PyTypeObject.tp_str - - An optional pointer to a function that implements the built-in operation - :func:`str`. (Note that :class:`str` is a type now, and :func:`str` calls the - constructor for that type. This constructor calls :cfunc:`PyObject_Str` to do - the actual work, and :cfunc:`PyObject_Str` will call this handler.) - - The signature is the same as for :cfunc:`PyObject_Str`; it must return a string - or a Unicode object. This function should return a "friendly" string - representation of the object, as this is the representation that will be used by - the print statement. - - When this field is not set, :cfunc:`PyObject_Repr` is called to return a string - representation. - - This field is inherited by subtypes. - - -.. cmember:: getattrofunc PyTypeObject.tp_getattro - - An optional pointer to the get-attribute function. - - The signature is the same as for :cfunc:`PyObject_GetAttr`. It is usually - convenient to set this field to :cfunc:`PyObject_GenericGetAttr`, which - implements the normal way of looking for object attributes. - - This field is inherited by subtypes together with :attr:`tp_getattr`: a subtype - inherits both :attr:`tp_getattr` and :attr:`tp_getattro` from its base type when - the subtype's :attr:`tp_getattr` and :attr:`tp_getattro` are both *NULL*. - - -.. cmember:: setattrofunc PyTypeObject.tp_setattro - - An optional pointer to the set-attribute function. - - The signature is the same as for :cfunc:`PyObject_SetAttr`. It is usually - convenient to set this field to :cfunc:`PyObject_GenericSetAttr`, which - implements the normal way of setting object attributes. - - This field is inherited by subtypes together with :attr:`tp_setattr`: a subtype - inherits both :attr:`tp_setattr` and :attr:`tp_setattro` from its base type when - the subtype's :attr:`tp_setattr` and :attr:`tp_setattro` are both *NULL*. - - -.. cmember:: PyBufferProcs* PyTypeObject.tp_as_buffer - - Pointer to an additional structure that contains fields relevant only to objects - which implement the buffer interface. These fields are documented in - :ref:`buffer-structs`. - - The :attr:`tp_as_buffer` field is not inherited, but the contained fields are - inherited individually. - - -.. cmember:: long PyTypeObject.tp_flags - - This field is a bit mask of various flags. Some flags indicate variant - semantics for certain situations; others are used to indicate that certain - fields in the type object (or in the extension structures referenced via - :attr:`tp_as_number`, :attr:`tp_as_sequence`, :attr:`tp_as_mapping`, and - :attr:`tp_as_buffer`) that were historically not always present are valid; if - such a flag bit is clear, the type fields it guards must not be accessed and - must be considered to have a zero or *NULL* value instead. - - Inheritance of this field is complicated. Most flag bits are inherited - individually, i.e. if the base type has a flag bit set, the subtype inherits - this flag bit. The flag bits that pertain to extension structures are strictly - inherited if the extension structure is inherited, i.e. the base type's value of - the flag bit is copied into the subtype together with a pointer to the extension - structure. The :const:`Py_TPFLAGS_HAVE_GC` flag bit is inherited together with - the :attr:`tp_traverse` and :attr:`tp_clear` fields, i.e. if the - :const:`Py_TPFLAGS_HAVE_GC` flag bit is clear in the subtype and the - :attr:`tp_traverse` and :attr:`tp_clear` fields in the subtype exist (as - indicated by the :const:`Py_TPFLAGS_HAVE_RICHCOMPARE` flag bit) and have *NULL* - values. - - The following bit masks are currently defined; these can be ORed together using - the ``|`` operator to form the value of the :attr:`tp_flags` field. The macro - :cfunc:`PyType_HasFeature` takes a type and a flags value, *tp* and *f*, and - checks whether ``tp->tp_flags & f`` is non-zero. - - - .. data:: Py_TPFLAGS_HAVE_GETCHARBUFFER - - If this bit is set, the :ctype:`PyBufferProcs` struct referenced by - :attr:`tp_as_buffer` has the :attr:`bf_getcharbuffer` field. - - - .. data:: Py_TPFLAGS_HAVE_SEQUENCE_IN - - If this bit is set, the :ctype:`PySequenceMethods` struct referenced by - :attr:`tp_as_sequence` has the :attr:`sq_contains` field. - - - .. data:: Py_TPFLAGS_GC - - This bit is obsolete. The bit it used to name is no longer in use. The symbol - is now defined as zero. - - - .. data:: Py_TPFLAGS_HAVE_INPLACEOPS - - If this bit is set, the :ctype:`PySequenceMethods` struct referenced by - :attr:`tp_as_sequence` and the :ctype:`PyNumberMethods` structure referenced by - :attr:`tp_as_number` contain the fields for in-place operators. In particular, - this means that the :ctype:`PyNumberMethods` structure has the fields - :attr:`nb_inplace_add`, :attr:`nb_inplace_subtract`, - :attr:`nb_inplace_multiply`, :attr:`nb_inplace_divide`, - :attr:`nb_inplace_remainder`, :attr:`nb_inplace_power`, - :attr:`nb_inplace_lshift`, :attr:`nb_inplace_rshift`, :attr:`nb_inplace_and`, - :attr:`nb_inplace_xor`, and :attr:`nb_inplace_or`; and the - :ctype:`PySequenceMethods` struct has the fields :attr:`sq_inplace_concat` and - :attr:`sq_inplace_repeat`. - - - .. data:: Py_TPFLAGS_CHECKTYPES - - If this bit is set, the binary and ternary operations in the - :ctype:`PyNumberMethods` structure referenced by :attr:`tp_as_number` accept - arguments of arbitrary object types, and do their own type conversions if - needed. If this bit is clear, those operations require that all arguments have - the current type as their type, and the caller is supposed to perform a coercion - operation first. This applies to :attr:`nb_add`, :attr:`nb_subtract`, - :attr:`nb_multiply`, :attr:`nb_divide`, :attr:`nb_remainder`, :attr:`nb_divmod`, - :attr:`nb_power`, :attr:`nb_lshift`, :attr:`nb_rshift`, :attr:`nb_and`, - :attr:`nb_xor`, and :attr:`nb_or`. - - - .. data:: Py_TPFLAGS_HAVE_RICHCOMPARE - - If this bit is set, the type object has the :attr:`tp_richcompare` field, as - well as the :attr:`tp_traverse` and the :attr:`tp_clear` fields. - - - .. data:: Py_TPFLAGS_HAVE_WEAKREFS - - If this bit is set, the :attr:`tp_weaklistoffset` field is defined. Instances - of a type are weakly referenceable if the type's :attr:`tp_weaklistoffset` field - has a value greater than zero. - - - .. data:: Py_TPFLAGS_HAVE_ITER - - If this bit is set, the type object has the :attr:`tp_iter` and - :attr:`tp_iternext` fields. - - - .. data:: Py_TPFLAGS_HAVE_CLASS - - If this bit is set, the type object has several new fields defined starting in - Python 2.2: :attr:`tp_methods`, :attr:`tp_members`, :attr:`tp_getset`, - :attr:`tp_base`, :attr:`tp_dict`, :attr:`tp_descr_get`, :attr:`tp_descr_set`, - :attr:`tp_dictoffset`, :attr:`tp_init`, :attr:`tp_alloc`, :attr:`tp_new`, - :attr:`tp_free`, :attr:`tp_is_gc`, :attr:`tp_bases`, :attr:`tp_mro`, - :attr:`tp_cache`, :attr:`tp_subclasses`, and :attr:`tp_weaklist`. - - - .. data:: Py_TPFLAGS_HEAPTYPE - - This bit is set when the type object itself is allocated on the heap. In this - case, the :attr:`ob_type` field of its instances is considered a reference to - the type, and the type object is INCREF'ed when a new instance is created, and - DECREF'ed when an instance is destroyed (this does not apply to instances of - subtypes; only the type referenced by the instance's ob_type gets INCREF'ed or - DECREF'ed). - - - .. data:: Py_TPFLAGS_BASETYPE - - This bit is set when the type can be used as the base type of another type. If - this bit is clear, the type cannot be subtyped (similar to a "final" class in - Java). - - - .. data:: Py_TPFLAGS_READY - - This bit is set when the type object has been fully initialized by - :cfunc:`PyType_Ready`. - - - .. data:: Py_TPFLAGS_READYING - - This bit is set while :cfunc:`PyType_Ready` is in the process of initializing - the type object. - - - .. data:: Py_TPFLAGS_HAVE_GC - - This bit is set when the object supports garbage collection. If this bit - is set, instances must be created using :cfunc:`PyObject_GC_New` and - destroyed using :cfunc:`PyObject_GC_Del`. More information in section - :ref:`supporting-cycle-detection`. This bit also implies that the - GC-related fields :attr:`tp_traverse` and :attr:`tp_clear` are present in - the type object; but those fields also exist when - :const:`Py_TPFLAGS_HAVE_GC` is clear but - :const:`Py_TPFLAGS_HAVE_RICHCOMPARE` is set. - - - .. data:: Py_TPFLAGS_DEFAULT - - This is a bitmask of all the bits that pertain to the existence of certain - fields in the type object and its extension structures. Currently, it includes - the following bits: :const:`Py_TPFLAGS_HAVE_GETCHARBUFFER`, - :const:`Py_TPFLAGS_HAVE_SEQUENCE_IN`, :const:`Py_TPFLAGS_HAVE_INPLACEOPS`, - :const:`Py_TPFLAGS_HAVE_RICHCOMPARE`, :const:`Py_TPFLAGS_HAVE_WEAKREFS`, - :const:`Py_TPFLAGS_HAVE_ITER`, and :const:`Py_TPFLAGS_HAVE_CLASS`. - - -.. cmember:: char* PyTypeObject.tp_doc - - An optional pointer to a NUL-terminated C string giving the docstring for this - type object. This is exposed as the :attr:`__doc__` attribute on the type and - instances of the type. - - This field is *not* inherited by subtypes. - -The following three fields only exist if the -:const:`Py_TPFLAGS_HAVE_RICHCOMPARE` flag bit is set. - - -.. cmember:: traverseproc PyTypeObject.tp_traverse - - An optional pointer to a traversal function for the garbage collector. This is - only used if the :const:`Py_TPFLAGS_HAVE_GC` flag bit is set. More information - about Python's garbage collection scheme can be found in section - :ref:`supporting-cycle-detection`. - - The :attr:`tp_traverse` pointer is used by the garbage collector to detect - reference cycles. A typical implementation of a :attr:`tp_traverse` function - simply calls :cfunc:`Py_VISIT` on each of the instance's members that are Python - objects. For exampe, this is function :cfunc:`local_traverse` from the - :mod:`thread` extension module:: - - static int - local_traverse(localobject *self, visitproc visit, void *arg) - { - Py_VISIT(self->args); - Py_VISIT(self->kw); - Py_VISIT(self->dict); - return 0; - } - - Note that :cfunc:`Py_VISIT` is called only on those members that can participate - in reference cycles. Although there is also a ``self->key`` member, it can only - be *NULL* or a Python string and therefore cannot be part of a reference cycle. - - On the other hand, even if you know a member can never be part of a cycle, as a - debugging aid you may want to visit it anyway just so the :mod:`gc` module's - :func:`get_referents` function will include it. - - Note that :cfunc:`Py_VISIT` requires the *visit* and *arg* parameters to - :cfunc:`local_traverse` to have these specific names; don't name them just - anything. - - This field is inherited by subtypes together with :attr:`tp_clear` and the - :const:`Py_TPFLAGS_HAVE_GC` flag bit: the flag bit, :attr:`tp_traverse`, and - :attr:`tp_clear` are all inherited from the base type if they are all zero in - the subtype *and* the subtype has the :const:`Py_TPFLAGS_HAVE_RICHCOMPARE` flag - bit set. - - -.. cmember:: inquiry PyTypeObject.tp_clear - - An optional pointer to a clear function for the garbage collector. This is only - used if the :const:`Py_TPFLAGS_HAVE_GC` flag bit is set. - - The :attr:`tp_clear` member function is used to break reference cycles in cyclic - garbage detected by the garbage collector. Taken together, all :attr:`tp_clear` - functions in the system must combine to break all reference cycles. This is - subtle, and if in any doubt supply a :attr:`tp_clear` function. For example, - the tuple type does not implement a :attr:`tp_clear` function, because it's - possible to prove that no reference cycle can be composed entirely of tuples. - Therefore the :attr:`tp_clear` functions of other types must be sufficient to - break any cycle containing a tuple. This isn't immediately obvious, and there's - rarely a good reason to avoid implementing :attr:`tp_clear`. - - Implementations of :attr:`tp_clear` should drop the instance's references to - those of its members that may be Python objects, and set its pointers to those - members to *NULL*, as in the following example:: - - static int - local_clear(localobject *self) - { - Py_CLEAR(self->key); - Py_CLEAR(self->args); - Py_CLEAR(self->kw); - Py_CLEAR(self->dict); - return 0; - } - - The :cfunc:`Py_CLEAR` macro should be used, because clearing references is - delicate: the reference to the contained object must not be decremented until - after the pointer to the contained object is set to *NULL*. This is because - decrementing the reference count may cause the contained object to become trash, - triggering a chain of reclamation activity that may include invoking arbitrary - Python code (due to finalizers, or weakref callbacks, associated with the - contained object). If it's possible for such code to reference *self* again, - it's important that the pointer to the contained object be *NULL* at that time, - so that *self* knows the contained object can no longer be used. The - :cfunc:`Py_CLEAR` macro performs the operations in a safe order. - - Because the goal of :attr:`tp_clear` functions is to break reference cycles, - it's not necessary to clear contained objects like Python strings or Python - integers, which can't participate in reference cycles. On the other hand, it may - be convenient to clear all contained Python objects, and write the type's - :attr:`tp_dealloc` function to invoke :attr:`tp_clear`. - - More information about Python's garbage collection scheme can be found in - section :ref:`supporting-cycle-detection`. - - This field is inherited by subtypes together with :attr:`tp_traverse` and the - :const:`Py_TPFLAGS_HAVE_GC` flag bit: the flag bit, :attr:`tp_traverse`, and - :attr:`tp_clear` are all inherited from the base type if they are all zero in - the subtype *and* the subtype has the :const:`Py_TPFLAGS_HAVE_RICHCOMPARE` flag - bit set. - - -.. cmember:: richcmpfunc PyTypeObject.tp_richcompare - - An optional pointer to the rich comparison function. - - The signature is the same as for :cfunc:`PyObject_RichCompare`. The function - should return the result of the comparison (usually ``Py_True`` or - ``Py_False``). If the comparison is undefined, it must return - ``Py_NotImplemented``, if another error occurred it must return ``NULL`` and set - an exception condition. - - This field is inherited by subtypes together with :attr:`tp_compare` and - :attr:`tp_hash`: a subtype inherits all three of :attr:`tp_compare`, - :attr:`tp_richcompare`, and :attr:`tp_hash`, when the subtype's - :attr:`tp_compare`, :attr:`tp_richcompare`, and :attr:`tp_hash` are all *NULL*. - - The following constants are defined to be used as the third argument for - :attr:`tp_richcompare` and for :cfunc:`PyObject_RichCompare`: - - +----------------+------------+ - | Constant | Comparison | - +================+============+ - | :const:`Py_LT` | ``<`` | - +----------------+------------+ - | :const:`Py_LE` | ``<=`` | - +----------------+------------+ - | :const:`Py_EQ` | ``==`` | - +----------------+------------+ - | :const:`Py_NE` | ``!=`` | - +----------------+------------+ - | :const:`Py_GT` | ``>`` | - +----------------+------------+ - | :const:`Py_GE` | ``>=`` | - +----------------+------------+ - -The next field only exists if the :const:`Py_TPFLAGS_HAVE_WEAKREFS` flag bit is -set. - - -.. cmember:: long PyTypeObject.tp_weaklistoffset - - If the instances of this type are weakly referenceable, this field is greater - than zero and contains the offset in the instance structure of the weak - reference list head (ignoring the GC header, if present); this offset is used by - :cfunc:`PyObject_ClearWeakRefs` and the :cfunc:`PyWeakref_\*` functions. The - instance structure needs to include a field of type :ctype:`PyObject\*` which is - initialized to *NULL*. - - Do not confuse this field with :attr:`tp_weaklist`; that is the list head for - weak references to the type object itself. - - This field is inherited by subtypes, but see the rules listed below. A subtype - may override this offset; this means that the subtype uses a different weak - reference list head than the base type. Since the list head is always found via - :attr:`tp_weaklistoffset`, this should not be a problem. - - When a type defined by a class statement has no :attr:`__slots__` declaration, - and none of its base types are weakly referenceable, the type is made weakly - referenceable by adding a weak reference list head slot to the instance layout - and setting the :attr:`tp_weaklistoffset` of that slot's offset. - - When a type's :attr:`__slots__` declaration contains a slot named - :attr:`__weakref__`, that slot becomes the weak reference list head for - instances of the type, and the slot's offset is stored in the type's - :attr:`tp_weaklistoffset`. - - When a type's :attr:`__slots__` declaration does not contain a slot named - :attr:`__weakref__`, the type inherits its :attr:`tp_weaklistoffset` from its - base type. - -The next two fields only exist if the :const:`Py_TPFLAGS_HAVE_CLASS` flag bit is -set. - - -.. cmember:: getiterfunc PyTypeObject.tp_iter - - An optional pointer to a function that returns an iterator for the object. Its - presence normally signals that the instances of this type are iterable (although - sequences may be iterable without this function, and classic instances always - have this function, even if they don't define an :meth:`__iter__` method). - - This function has the same signature as :cfunc:`PyObject_GetIter`. - - This field is inherited by subtypes. - - -.. cmember:: iternextfunc PyTypeObject.tp_iternext - - An optional pointer to a function that returns the next item in an iterator, or - raises :exc:`StopIteration` when the iterator is exhausted. Its presence - normally signals that the instances of this type are iterators (although classic - instances always have this function, even if they don't define a :meth:`next` - method). - - Iterator types should also define the :attr:`tp_iter` function, and that - function should return the iterator instance itself (not a new iterator - instance). - - This function has the same signature as :cfunc:`PyIter_Next`. - - This field is inherited by subtypes. - -The next fields, up to and including :attr:`tp_weaklist`, only exist if the -:const:`Py_TPFLAGS_HAVE_CLASS` flag bit is set. - - -.. cmember:: struct PyMethodDef* PyTypeObject.tp_methods - - An optional pointer to a static *NULL*-terminated array of :ctype:`PyMethodDef` - structures, declaring regular methods of this type. - - For each entry in the array, an entry is added to the type's dictionary (see - :attr:`tp_dict` below) containing a method descriptor. - - This field is not inherited by subtypes (methods are inherited through a - different mechanism). - - -.. cmember:: struct PyMemberDef* PyTypeObject.tp_members - - An optional pointer to a static *NULL*-terminated array of :ctype:`PyMemberDef` - structures, declaring regular data members (fields or slots) of instances of - this type. - - For each entry in the array, an entry is added to the type's dictionary (see - :attr:`tp_dict` below) containing a member descriptor. - - This field is not inherited by subtypes (members are inherited through a - different mechanism). - - -.. cmember:: struct PyGetSetDef* PyTypeObject.tp_getset - - An optional pointer to a static *NULL*-terminated array of :ctype:`PyGetSetDef` - structures, declaring computed attributes of instances of this type. - - For each entry in the array, an entry is added to the type's dictionary (see - :attr:`tp_dict` below) containing a getset descriptor. - - This field is not inherited by subtypes (computed attributes are inherited - through a different mechanism). - - Docs for PyGetSetDef (XXX belong elsewhere):: - - typedef PyObject *(*getter)(PyObject *, void *); - typedef int (*setter)(PyObject *, PyObject *, void *); - - typedef struct PyGetSetDef { - char *name; /* attribute name */ - getter get; /* C function to get the attribute */ - setter set; /* C function to set the attribute */ - char *doc; /* optional doc string */ - void *closure; /* optional additional data for getter and setter */ - } PyGetSetDef; - - -.. cmember:: PyTypeObject* PyTypeObject.tp_base - - An optional pointer to a base type from which type properties are inherited. At - this level, only single inheritance is supported; multiple inheritance require - dynamically creating a type object by calling the metatype. - - This field is not inherited by subtypes (obviously), but it defaults to - ``&PyBaseObject_Type`` (which to Python programmers is known as the type - :class:`object`). - - -.. cmember:: PyObject* PyTypeObject.tp_dict - - The type's dictionary is stored here by :cfunc:`PyType_Ready`. - - This field should normally be initialized to *NULL* before PyType_Ready is - called; it may also be initialized to a dictionary containing initial attributes - for the type. Once :cfunc:`PyType_Ready` has initialized the type, extra - attributes for the type may be added to this dictionary only if they don't - correspond to overloaded operations (like :meth:`__add__`). - - This field is not inherited by subtypes (though the attributes defined in here - are inherited through a different mechanism). - - -.. cmember:: descrgetfunc PyTypeObject.tp_descr_get - - An optional pointer to a "descriptor get" function. - - The function signature is :: - - PyObject * tp_descr_get(PyObject *self, PyObject *obj, PyObject *type); - - XXX explain. - - This field is inherited by subtypes. - - -.. cmember:: descrsetfunc PyTypeObject.tp_descr_set - - An optional pointer to a "descriptor set" function. - - The function signature is :: - - int tp_descr_set(PyObject *self, PyObject *obj, PyObject *value); - - This field is inherited by subtypes. - - XXX explain. - - -.. cmember:: long PyTypeObject.tp_dictoffset - - If the instances of this type have a dictionary containing instance variables, - this field is non-zero and contains the offset in the instances of the type of - the instance variable dictionary; this offset is used by - :cfunc:`PyObject_GenericGetAttr`. - - Do not confuse this field with :attr:`tp_dict`; that is the dictionary for - attributes of the type object itself. - - If the value of this field is greater than zero, it specifies the offset from - the start of the instance structure. If the value is less than zero, it - specifies the offset from the *end* of the instance structure. A negative - offset is more expensive to use, and should only be used when the instance - structure contains a variable-length part. This is used for example to add an - instance variable dictionary to subtypes of :class:`str` or :class:`tuple`. Note - that the :attr:`tp_basicsize` field should account for the dictionary added to - the end in that case, even though the dictionary is not included in the basic - object layout. On a system with a pointer size of 4 bytes, - :attr:`tp_dictoffset` should be set to ``-4`` to indicate that the dictionary is - at the very end of the structure. - - The real dictionary offset in an instance can be computed from a negative - :attr:`tp_dictoffset` as follows:: - - dictoffset = tp_basicsize + abs(ob_size)*tp_itemsize + tp_dictoffset - if dictoffset is not aligned on sizeof(void*): - round up to sizeof(void*) - - where :attr:`tp_basicsize`, :attr:`tp_itemsize` and :attr:`tp_dictoffset` are - taken from the type object, and :attr:`ob_size` is taken from the instance. The - absolute value is taken because long ints use the sign of :attr:`ob_size` to - store the sign of the number. (There's never a need to do this calculation - yourself; it is done for you by :cfunc:`_PyObject_GetDictPtr`.) - - This field is inherited by subtypes, but see the rules listed below. A subtype - may override this offset; this means that the subtype instances store the - dictionary at a difference offset than the base type. Since the dictionary is - always found via :attr:`tp_dictoffset`, this should not be a problem. - - When a type defined by a class statement has no :attr:`__slots__` declaration, - and none of its base types has an instance variable dictionary, a dictionary - slot is added to the instance layout and the :attr:`tp_dictoffset` is set to - that slot's offset. - - When a type defined by a class statement has a :attr:`__slots__` declaration, - the type inherits its :attr:`tp_dictoffset` from its base type. - - (Adding a slot named :attr:`__dict__` to the :attr:`__slots__` declaration does - not have the expected effect, it just causes confusion. Maybe this should be - added as a feature just like :attr:`__weakref__` though.) - - -.. cmember:: initproc PyTypeObject.tp_init - - An optional pointer to an instance initialization function. - - This function corresponds to the :meth:`__init__` method of classes. Like - :meth:`__init__`, it is possible to create an instance without calling - :meth:`__init__`, and it is possible to reinitialize an instance by calling its - :meth:`__init__` method again. - - The function signature is :: - - int tp_init(PyObject *self, PyObject *args, PyObject *kwds) - - The self argument is the instance to be initialized; the *args* and *kwds* - arguments represent positional and keyword arguments of the call to - :meth:`__init__`. - - The :attr:`tp_init` function, if not *NULL*, is called when an instance is - created normally by calling its type, after the type's :attr:`tp_new` function - has returned an instance of the type. If the :attr:`tp_new` function returns an - instance of some other type that is not a subtype of the original type, no - :attr:`tp_init` function is called; if :attr:`tp_new` returns an instance of a - subtype of the original type, the subtype's :attr:`tp_init` is called. (VERSION - NOTE: described here is what is implemented in Python 2.2.1 and later. In - Python 2.2, the :attr:`tp_init` of the type of the object returned by - :attr:`tp_new` was always called, if not *NULL*.) - - This field is inherited by subtypes. - - -.. cmember:: allocfunc PyTypeObject.tp_alloc - - An optional pointer to an instance allocation function. - - The function signature is :: - - PyObject *tp_alloc(PyTypeObject *self, Py_ssize_t nitems) - - The purpose of this function is to separate memory allocation from memory - initialization. It should return a pointer to a block of memory of adequate - length for the instance, suitably aligned, and initialized to zeros, but with - :attr:`ob_refcnt` set to ``1`` and :attr:`ob_type` set to the type argument. If - the type's :attr:`tp_itemsize` is non-zero, the object's :attr:`ob_size` field - should be initialized to *nitems* and the length of the allocated memory block - should be ``tp_basicsize + nitems*tp_itemsize``, rounded up to a multiple of - ``sizeof(void*)``; otherwise, *nitems* is not used and the length of the block - should be :attr:`tp_basicsize`. - - Do not use this function to do any other instance initialization, not even to - allocate additional memory; that should be done by :attr:`tp_new`. - - This field is inherited by static subtypes, but not by dynamic subtypes - (subtypes created by a class statement); in the latter, this field is always set - to :cfunc:`PyType_GenericAlloc`, to force a standard heap allocation strategy. - That is also the recommended value for statically defined types. - - -.. cmember:: newfunc PyTypeObject.tp_new - - An optional pointer to an instance creation function. - - If this function is *NULL* for a particular type, that type cannot be called to - create new instances; presumably there is some other way to create instances, - like a factory function. - - The function signature is :: - - PyObject *tp_new(PyTypeObject *subtype, PyObject *args, PyObject *kwds) - - The subtype argument is the type of the object being created; the *args* and - *kwds* arguments represent positional and keyword arguments of the call to the - type. Note that subtype doesn't have to equal the type whose :attr:`tp_new` - function is called; it may be a subtype of that type (but not an unrelated - type). - - The :attr:`tp_new` function should call ``subtype->tp_alloc(subtype, nitems)`` - to allocate space for the object, and then do only as much further - initialization as is absolutely necessary. Initialization that can safely be - ignored or repeated should be placed in the :attr:`tp_init` handler. A good - rule of thumb is that for immutable types, all initialization should take place - in :attr:`tp_new`, while for mutable types, most initialization should be - deferred to :attr:`tp_init`. - - This field is inherited by subtypes, except it is not inherited by static types - whose :attr:`tp_base` is *NULL* or ``&PyBaseObject_Type``. The latter exception - is a precaution so that old extension types don't become callable simply by - being linked with Python 2.2. - - -.. cmember:: destructor PyTypeObject.tp_free - - An optional pointer to an instance deallocation function. - - The signature of this function has changed slightly: in Python 2.2 and 2.2.1, - its signature is :ctype:`destructor`:: - - void tp_free(PyObject *) - - In Python 2.3 and beyond, its signature is :ctype:`freefunc`:: - - void tp_free(void *) - - The only initializer that is compatible with both versions is ``_PyObject_Del``, - whose definition has suitably adapted in Python 2.3. - - This field is inherited by static subtypes, but not by dynamic subtypes - (subtypes created by a class statement); in the latter, this field is set to a - deallocator suitable to match :cfunc:`PyType_GenericAlloc` and the value of the - :const:`Py_TPFLAGS_HAVE_GC` flag bit. - - -.. cmember:: inquiry PyTypeObject.tp_is_gc - - An optional pointer to a function called by the garbage collector. - - The garbage collector needs to know whether a particular object is collectible - or not. Normally, it is sufficient to look at the object's type's - :attr:`tp_flags` field, and check the :const:`Py_TPFLAGS_HAVE_GC` flag bit. But - some types have a mixture of statically and dynamically allocated instances, and - the statically allocated instances are not collectible. Such types should - define this function; it should return ``1`` for a collectible instance, and - ``0`` for a non-collectible instance. The signature is :: - - int tp_is_gc(PyObject *self) - - (The only example of this are types themselves. The metatype, - :cdata:`PyType_Type`, defines this function to distinguish between statically - and dynamically allocated types.) - - This field is inherited by subtypes. (VERSION NOTE: in Python 2.2, it was not - inherited. It is inherited in 2.2.1 and later versions.) - - -.. cmember:: PyObject* PyTypeObject.tp_bases - - Tuple of base types. - - This is set for types created by a class statement. It should be *NULL* for - statically defined types. - - This field is not inherited. - - -.. cmember:: PyObject* PyTypeObject.tp_mro - - Tuple containing the expanded set of base types, starting with the type itself - and ending with :class:`object`, in Method Resolution Order. - - This field is not inherited; it is calculated fresh by :cfunc:`PyType_Ready`. - - -.. cmember:: PyObject* PyTypeObject.tp_cache - - Unused. Not inherited. Internal use only. - - -.. cmember:: PyObject* PyTypeObject.tp_subclasses - - List of weak references to subclasses. Not inherited. Internal use only. - - -.. cmember:: PyObject* PyTypeObject.tp_weaklist - - Weak reference list head, for weak references to this type object. Not - inherited. Internal use only. - -The remaining fields are only defined if the feature test macro -:const:`COUNT_ALLOCS` is defined, and are for internal use only. They are -documented here for completeness. None of these fields are inherited by -subtypes. - - -.. cmember:: Py_ssize_t PyTypeObject.tp_allocs - - Number of allocations. - - -.. cmember:: Py_ssize_t PyTypeObject.tp_frees - - Number of frees. - - -.. cmember:: Py_ssize_t PyTypeObject.tp_maxalloc - - Maximum simultaneously allocated objects. - - -.. cmember:: PyTypeObject* PyTypeObject.tp_next - - Pointer to the next type object with a non-zero :attr:`tp_allocs` field. - -Also, note that, in a garbage collected Python, tp_dealloc may be called from -any Python thread, not just the thread which created the object (if the object -becomes part of a refcount cycle, that cycle might be collected by a garbage -collection on any thread). This is not a problem for Python API calls, since -the thread on which tp_dealloc is called will own the Global Interpreter Lock -(GIL). However, if the object being destroyed in turn destroys objects from some -other C or C++ library, care should be taken to ensure that destroying those -objects on the thread which called tp_dealloc will not violate any assumptions -of the library. - - -.. _number-structs: - -Number Object Structures -======================== - -.. sectionauthor:: Amaury Forgeot d'Arc - - -.. ctype:: PyNumberMethods - - This structure holds pointers to the functions which an object uses to - implement the number protocol. Almost every function below is used by the - function of similar name documented in the :ref:`number` section. - - Here is the structure definition:: - - typedef struct { - binaryfunc nb_add; - binaryfunc nb_subtract; - binaryfunc nb_multiply; - binaryfunc nb_remainder; - binaryfunc nb_divmod; - ternaryfunc nb_power; - unaryfunc nb_negative; - unaryfunc nb_positive; - unaryfunc nb_absolute; - inquiry nb_nonzero; /* Used by PyObject_IsTrue */ - unaryfunc nb_invert; - binaryfunc nb_lshift; - binaryfunc nb_rshift; - binaryfunc nb_and; - binaryfunc nb_xor; - binaryfunc nb_or; - coercion nb_coerce; /* Used by the coerce() funtion */ - unaryfunc nb_int; - unaryfunc nb_long; - unaryfunc nb_float; - unaryfunc nb_oct; - unaryfunc nb_hex; - - /* Added in release 2.0 */ - binaryfunc nb_inplace_add; - binaryfunc nb_inplace_subtract; - binaryfunc nb_inplace_multiply; - binaryfunc nb_inplace_remainder; - ternaryfunc nb_inplace_power; - binaryfunc nb_inplace_lshift; - binaryfunc nb_inplace_rshift; - binaryfunc nb_inplace_and; - binaryfunc nb_inplace_xor; - binaryfunc nb_inplace_or; - - /* Added in release 2.2 */ - binaryfunc nb_floor_divide; - binaryfunc nb_true_divide; - binaryfunc nb_inplace_floor_divide; - binaryfunc nb_inplace_true_divide; - - /* Added in release 2.5 */ - unaryfunc nb_index; - } PyNumberMethods; - - -Binary and ternary functions may receive different kinds of arguments, depending -on the flag bit :const:`Py_TPFLAGS_CHECKTYPES`: - -- If :const:`Py_TPFLAGS_CHECKTYPES` is not set, the function arguments are - guaranteed to be of the object's type; the caller is responsible for calling - the coercion method specified by the :attr:`nb_coerce` member to convert the - arguments: - - .. cmember:: coercion PyNumberMethods.nb_coerce - - This function is used by :cfunc:`PyNumber_CoerceEx` and has the same - signature. The first argument is always a pointer to an object of the - defined type. If the conversion to a common "larger" type is possible, the - function replaces the pointers with new references to the converted objects - and returns ``0``. If the conversion is not possible, the function returns - ``1``. If an error condition is set, it will return ``-1``. - -- If the :const:`Py_TPFLAGS_CHECKTYPES` flag is set, binary and ternary - functions must check the type of all their operands, and implement the - necessary conversions (at least one of the operands is an instance of the - defined type). This is the recommended way; with Python 3.0 coercion will - disappear completely. - -If the operation is not defined for the given operands, binary and ternary -functions must return ``Py_NotImplemented``, if another error occurred they must -return ``NULL`` and set an exception. - - -.. _mapping-structs: - -Mapping Object Structures -========================= - -.. sectionauthor:: Amaury Forgeot d'Arc - - -.. ctype:: PyMappingMethods - - This structure holds pointers to the functions which an object uses to - implement the mapping protocol. It has three members: - -.. cmember:: lenfunc PyMappingMethods.mp_length - - This function is used by :cfunc:`PyMapping_Length` and - :cfunc:`PyObject_Size`, and has the same signature. This slot may be set to - *NULL* if the object has no defined length. - -.. cmember:: binaryfunc PyMappingMethods.mp_subscript - - This function is used by :cfunc:`PyObject_GetItem` and has the same - signature. This slot must be filled for the :cfunc:`PyMapping_Check` - function to return ``1``, it can be *NULL* otherwise. - -.. cmember:: objobjargproc PyMappingMethods.mp_ass_subscript - - This function is used by :cfunc:`PyObject_SetItem` and has the same - signature. If this slot is *NULL*, the object does not support item - assignment. - - -.. _sequence-structs: - -Sequence Object Structures -========================== - -.. sectionauthor:: Amaury Forgeot d'Arc - - -.. ctype:: PySequenceMethods - - This structure holds pointers to the functions which an object uses to - implement the sequence protocol. - -.. cmember:: lenfunc PySequenceMethods.sq_length - - This function is used by :cfunc:`PySequence_Size` and :cfunc:`PyObject_Size`, - and has the same signature. - -.. cmember:: binaryfunc PySequenceMethods.sq_concat - - This function is used by :cfunc:`PySequence_Concat` and has the same - signature. It is also used by the ``+`` operator, after trying the numeric - addition via the :attr:`tp_as_number.nb_add` slot. - -.. cmember:: ssizeargfunc PySequenceMethods.sq_repeat - - This function is used by :cfunc:`PySequence_Repeat` and has the same - signature. It is also used by the ``*`` operator, after trying numeric - multiplication via the :attr:`tp_as_number.nb_mul` slot. - -.. cmember:: ssizeargfunc PySequenceMethods.sq_item - - This function is used by :cfunc:`PySequence_GetItem` and has the same - signature. This slot must be filled for the :cfunc:`PySequence_Check` - function to return ``1``, it can be *NULL* otherwise. - - Negative indexes are handled as follows: if the :attr:`sq_length` slot is - filled, it is called and the sequence length is used to compute a positive - index which is passed to :attr:`sq_item`. If :attr:`sq_length` is *NULL*, - the index is passed as is to the function. - -.. cmember:: ssizeobjargproc PySequenceMethods.sq_ass_item - - This function is used by :cfunc:`PySequence_SetItem` and has the same - signature. This slot may be left to *NULL* if the object does not support - item assignment. - -.. cmember:: objobjproc PySequenceMethods.sq_contains - - This function may be used by :cfunc:`PySequence_Contains` and has the same - signature. This slot may be left to *NULL*, in this case - :cfunc:`PySequence_Contains` simply traverses the sequence until it finds a - match. - -.. cmember:: binaryfunc PySequenceMethods.sq_inplace_concat - - This function is used by :cfunc:`PySequence_InPlaceConcat` and has the same - signature. It should modify its first operand, and return it. - -.. cmember:: ssizeargfunc PySequenceMethods.sq_inplace_repeat - - This function is used by :cfunc:`PySequence_InPlaceRepeat` and has the same - signature. It should modify its first operand, and return it. - -.. XXX need to explain precedence between mapping and sequence -.. XXX explains when to implement the sq_inplace_* slots - - -.. _buffer-structs: - -Buffer Object Structures -======================== - -.. sectionauthor:: Greg J. Stein - - -The buffer interface exports a model where an object can expose its internal -data as a set of chunks of data, where each chunk is specified as a -pointer/length pair. These chunks are called :dfn:`segments` and are presumed -to be non-contiguous in memory. - -If an object does not export the buffer interface, then its :attr:`tp_as_buffer` -member in the :ctype:`PyTypeObject` structure should be *NULL*. Otherwise, the -:attr:`tp_as_buffer` will point to a :ctype:`PyBufferProcs` structure. - -.. note:: - - It is very important that your :ctype:`PyTypeObject` structure uses - :const:`Py_TPFLAGS_DEFAULT` for the value of the :attr:`tp_flags` member rather - than ``0``. This tells the Python runtime that your :ctype:`PyBufferProcs` - structure contains the :attr:`bf_getcharbuffer` slot. Older versions of Python - did not have this member, so a new Python interpreter using an old extension - needs to be able to test for its presence before using it. - - -.. ctype:: PyBufferProcs - - Structure used to hold the function pointers which define an implementation of - the buffer protocol. - - The first slot is :attr:`bf_getreadbuffer`, of type :ctype:`getreadbufferproc`. - If this slot is *NULL*, then the object does not support reading from the - internal data. This is non-sensical, so implementors should fill this in, but - callers should test that the slot contains a non-*NULL* value. - - The next slot is :attr:`bf_getwritebuffer` having type - :ctype:`getwritebufferproc`. This slot may be *NULL* if the object does not - allow writing into its returned buffers. - - The third slot is :attr:`bf_getsegcount`, with type :ctype:`getsegcountproc`. - This slot must not be *NULL* and is used to inform the caller how many segments - the object contains. Simple objects such as :ctype:`PyString_Type` and - :ctype:`PyBuffer_Type` objects contain a single segment. - - .. index:: single: PyType_HasFeature() - - The last slot is :attr:`bf_getcharbuffer`, of type :ctype:`getcharbufferproc`. - This slot will only be present if the :const:`Py_TPFLAGS_HAVE_GETCHARBUFFER` - flag is present in the :attr:`tp_flags` field of the object's - :ctype:`PyTypeObject`. Before using this slot, the caller should test whether it - is present by using the :cfunc:`PyType_HasFeature` function. If the flag is - present, :attr:`bf_getcharbuffer` may be *NULL*, indicating that the object's - contents cannot be used as *8-bit characters*. The slot function may also raise - an error if the object's contents cannot be interpreted as 8-bit characters. - For example, if the object is an array which is configured to hold floating - point values, an exception may be raised if a caller attempts to use - :attr:`bf_getcharbuffer` to fetch a sequence of 8-bit characters. This notion of - exporting the internal buffers as "text" is used to distinguish between objects - that are binary in nature, and those which have character-based content. - - .. note:: - - The current policy seems to state that these characters may be multi-byte - characters. This implies that a buffer size of *N* does not mean there are *N* - characters present. - - -.. data:: Py_TPFLAGS_HAVE_GETCHARBUFFER - - Flag bit set in the type structure to indicate that the :attr:`bf_getcharbuffer` - slot is known. This being set does not indicate that the object supports the - buffer interface or that the :attr:`bf_getcharbuffer` slot is non-*NULL*. - - -.. ctype:: Py_ssize_t (*readbufferproc) (PyObject *self, Py_ssize_t segment, void **ptrptr) - - Return a pointer to a readable segment of the buffer in ``*ptrptr``. This - function is allowed to raise an exception, in which case it must return ``-1``. - The *segment* which is specified must be zero or positive, and strictly less - than the number of segments returned by the :attr:`bf_getsegcount` slot - function. On success, it returns the length of the segment, and sets - ``*ptrptr`` to a pointer to that memory. - - -.. ctype:: Py_ssize_t (*writebufferproc) (PyObject *self, Py_ssize_t segment, void **ptrptr) - - Return a pointer to a writable memory buffer in ``*ptrptr``, and the length of - that segment as the function return value. The memory buffer must correspond to - buffer segment *segment*. Must return ``-1`` and set an exception on error. - :exc:`TypeError` should be raised if the object only supports read-only buffers, - and :exc:`SystemError` should be raised when *segment* specifies a segment that - doesn't exist. - - .. Why doesn't it raise ValueError for this one? - GJS: because you shouldn't be calling it with an invalid - segment. That indicates a blatant programming error in the C code. - - -.. ctype:: Py_ssize_t (*segcountproc) (PyObject *self, Py_ssize_t *lenp) - - Return the number of memory segments which comprise the buffer. If *lenp* is - not *NULL*, the implementation must report the sum of the sizes (in bytes) of - all segments in ``*lenp``. The function cannot fail. - - -.. ctype:: Py_ssize_t (*charbufferproc) (PyObject *self, Py_ssize_t segment, const char **ptrptr) - - Return the size of the segment *segment* that *ptrptr* is set to. ``*ptrptr`` - is set to the memory buffer. Returns ``-1`` on error. - - -.. _supporting-iteration: - -Supporting the Iterator Protocol -================================ - - -.. _supporting-cycle-detection: - -Supporting Cyclic Garbage Collection -==================================== - -Python's support for detecting and collecting garbage which involves circular -references requires support from object types which are "containers" for other -objects which may also be containers. Types which do not store references to -other objects, or which only store references to atomic types (such as numbers -or strings), do not need to provide any explicit support for garbage collection. - -.. An example showing the use of these interfaces can be found in "Supporting the -.. Cycle Collector (XXX not found: ../ext/example-cycle-support.html)". - -To create a container type, the :attr:`tp_flags` field of the type object must -include the :const:`Py_TPFLAGS_HAVE_GC` and provide an implementation of the -:attr:`tp_traverse` handler. If instances of the type are mutable, a -:attr:`tp_clear` implementation must also be provided. - - -.. data:: Py_TPFLAGS_HAVE_GC - - Objects with a type with this flag set must conform with the rules documented - here. For convenience these objects will be referred to as container objects. - -Constructors for container types must conform to two rules: - -#. The memory for the object must be allocated using :cfunc:`PyObject_GC_New` or - :cfunc:`PyObject_GC_VarNew`. - -#. Once all the fields which may contain references to other containers are - initialized, it must call :cfunc:`PyObject_GC_Track`. - - -.. cfunction:: TYPE* PyObject_GC_New(TYPE, PyTypeObject *type) - - Analogous to :cfunc:`PyObject_New` but for container objects with the - :const:`Py_TPFLAGS_HAVE_GC` flag set. - - -.. cfunction:: TYPE* PyObject_GC_NewVar(TYPE, PyTypeObject *type, Py_ssize_t size) - - Analogous to :cfunc:`PyObject_NewVar` but for container objects with the - :const:`Py_TPFLAGS_HAVE_GC` flag set. - - -.. cfunction:: PyVarObject * PyObject_GC_Resize(PyVarObject *op, Py_ssize_t) - - Resize an object allocated by :cfunc:`PyObject_NewVar`. Returns the resized - object or *NULL* on failure. - - -.. cfunction:: void PyObject_GC_Track(PyObject *op) - - Adds the object *op* to the set of container objects tracked by the collector. - The collector can run at unexpected times so objects must be valid while being - tracked. This should be called once all the fields followed by the - :attr:`tp_traverse` handler become valid, usually near the end of the - constructor. - - -.. cfunction:: void _PyObject_GC_TRACK(PyObject *op) - - A macro version of :cfunc:`PyObject_GC_Track`. It should not be used for - extension modules. - -Similarly, the deallocator for the object must conform to a similar pair of -rules: - -#. Before fields which refer to other containers are invalidated, - :cfunc:`PyObject_GC_UnTrack` must be called. - -#. The object's memory must be deallocated using :cfunc:`PyObject_GC_Del`. - - -.. cfunction:: void PyObject_GC_Del(void *op) - - Releases memory allocated to an object using :cfunc:`PyObject_GC_New` or - :cfunc:`PyObject_GC_NewVar`. - - -.. cfunction:: void PyObject_GC_UnTrack(void *op) - - Remove the object *op* from the set of container objects tracked by the - collector. Note that :cfunc:`PyObject_GC_Track` can be called again on this - object to add it back to the set of tracked objects. The deallocator - (:attr:`tp_dealloc` handler) should call this for the object before any of the - fields used by the :attr:`tp_traverse` handler become invalid. - - -.. cfunction:: void _PyObject_GC_UNTRACK(PyObject *op) - - A macro version of :cfunc:`PyObject_GC_UnTrack`. It should not be used for - extension modules. - -The :attr:`tp_traverse` handler accepts a function parameter of this type: - - -.. ctype:: int (*visitproc)(PyObject *object, void *arg) - - Type of the visitor function passed to the :attr:`tp_traverse` handler. The - function should be called with an object to traverse as *object* and the third - parameter to the :attr:`tp_traverse` handler as *arg*. The Python core uses - several visitor functions to implement cyclic garbage detection; it's not - expected that users will need to write their own visitor functions. - -The :attr:`tp_traverse` handler must have the following type: - - -.. ctype:: int (*traverseproc)(PyObject *self, visitproc visit, void *arg) - - Traversal function for a container object. Implementations must call the - *visit* function for each object directly contained by *self*, with the - parameters to *visit* being the contained object and the *arg* value passed to - the handler. The *visit* function must not be called with a *NULL* object - argument. If *visit* returns a non-zero value that value should be returned - immediately. - -To simplify writing :attr:`tp_traverse` handlers, a :cfunc:`Py_VISIT` macro is -provided. In order to use this macro, the :attr:`tp_traverse` implementation -must name its arguments exactly *visit* and *arg*: - - -.. cfunction:: void Py_VISIT(PyObject *o) - - Call the *visit* callback, with arguments *o* and *arg*. If *visit* returns a - non-zero value, then return it. Using this macro, :attr:`tp_traverse` handlers - look like:: - - static int - my_traverse(Noddy *self, visitproc visit, void *arg) - { - Py_VISIT(self->foo); - Py_VISIT(self->bar); - return 0; - } - - .. versionadded:: 2.4 - -The :attr:`tp_clear` handler must be of the :ctype:`inquiry` type, or *NULL* if -the object is immutable. - - -.. ctype:: int (*inquiry)(PyObject *self) - - Drop references that may have created reference cycles. Immutable objects do - not have to define this method since they can never directly create reference - cycles. Note that the object must still be valid after calling this method - (don't just call :cfunc:`Py_DECREF` on a reference). The collector will call - this method if it detects that this object is involved in a reference cycle. - + allocation.rst + structures.rst + typeobj.rst + gcsupport.rst Added: python/trunk/Doc/c-api/sequence.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/c-api/sequence.rst Sat Jan 19 23:08:21 2008 @@ -0,0 +1,166 @@ +.. highlightlang:: c + +.. _sequence: + +Sequence Protocol +================= + + +.. cfunction:: int PySequence_Check(PyObject *o) + + Return ``1`` if the object provides sequence protocol, and ``0`` otherwise. + This function always succeeds. + + +.. cfunction:: Py_ssize_t PySequence_Size(PyObject *o) + + .. index:: builtin: len + + Returns the number of objects in sequence *o* on success, and ``-1`` on failure. + For objects that do not provide sequence protocol, this is equivalent to the + Python expression ``len(o)``. + + +.. cfunction:: Py_ssize_t PySequence_Length(PyObject *o) + + Alternate name for :cfunc:`PySequence_Size`. + + +.. cfunction:: PyObject* PySequence_Concat(PyObject *o1, PyObject *o2) + + Return the concatenation of *o1* and *o2* on success, and *NULL* on failure. + This is the equivalent of the Python expression ``o1 + o2``. + + +.. cfunction:: PyObject* PySequence_Repeat(PyObject *o, Py_ssize_t count) + + Return the result of repeating sequence object *o* *count* times, or *NULL* on + failure. This is the equivalent of the Python expression ``o * count``. + + +.. cfunction:: PyObject* PySequence_InPlaceConcat(PyObject *o1, PyObject *o2) + + Return the concatenation of *o1* and *o2* on success, and *NULL* on failure. + The operation is done *in-place* when *o1* supports it. This is the equivalent + of the Python expression ``o1 += o2``. + + +.. cfunction:: PyObject* PySequence_InPlaceRepeat(PyObject *o, Py_ssize_t count) + + Return the result of repeating sequence object *o* *count* times, or *NULL* on + failure. The operation is done *in-place* when *o* supports it. This is the + equivalent of the Python expression ``o *= count``. + + +.. cfunction:: PyObject* PySequence_GetItem(PyObject *o, Py_ssize_t i) + + Return the *i*th element of *o*, or *NULL* on failure. This is the equivalent of + the Python expression ``o[i]``. + + +.. cfunction:: PyObject* PySequence_GetSlice(PyObject *o, Py_ssize_t i1, Py_ssize_t i2) + + Return the slice of sequence object *o* between *i1* and *i2*, or *NULL* on + failure. This is the equivalent of the Python expression ``o[i1:i2]``. + + +.. cfunction:: int PySequence_SetItem(PyObject *o, Py_ssize_t i, PyObject *v) + + Assign object *v* to the *i*th element of *o*. Returns ``-1`` on failure. This + is the equivalent of the Python statement ``o[i] = v``. This function *does + not* steal a reference to *v*. + + +.. cfunction:: int PySequence_DelItem(PyObject *o, Py_ssize_t i) + + Delete the *i*th element of object *o*. Returns ``-1`` on failure. This is the + equivalent of the Python statement ``del o[i]``. + + +.. cfunction:: int PySequence_SetSlice(PyObject *o, Py_ssize_t i1, Py_ssize_t i2, PyObject *v) + + Assign the sequence object *v* to the slice in sequence object *o* from *i1* to + *i2*. This is the equivalent of the Python statement ``o[i1:i2] = v``. + + +.. cfunction:: int PySequence_DelSlice(PyObject *o, Py_ssize_t i1, Py_ssize_t i2) + + Delete the slice in sequence object *o* from *i1* to *i2*. Returns ``-1`` on + failure. This is the equivalent of the Python statement ``del o[i1:i2]``. + + +.. cfunction:: Py_ssize_t PySequence_Count(PyObject *o, PyObject *value) + + Return the number of occurrences of *value* in *o*, that is, return the number + of keys for which ``o[key] == value``. On failure, return ``-1``. This is + equivalent to the Python expression ``o.count(value)``. + + +.. cfunction:: int PySequence_Contains(PyObject *o, PyObject *value) + + Determine if *o* contains *value*. If an item in *o* is equal to *value*, + return ``1``, otherwise return ``0``. On error, return ``-1``. This is + equivalent to the Python expression ``value in o``. + + +.. cfunction:: Py_ssize_t PySequence_Index(PyObject *o, PyObject *value) + + Return the first index *i* for which ``o[i] == value``. On error, return + ``-1``. This is equivalent to the Python expression ``o.index(value)``. + + +.. cfunction:: PyObject* PySequence_List(PyObject *o) + + Return a list object with the same contents as the arbitrary sequence *o*. The + returned list is guaranteed to be new. + + +.. cfunction:: PyObject* PySequence_Tuple(PyObject *o) + + .. index:: builtin: tuple + + Return a tuple object with the same contents as the arbitrary sequence *o* or + *NULL* on failure. If *o* is a tuple, a new reference will be returned, + otherwise a tuple will be constructed with the appropriate contents. This is + equivalent to the Python expression ``tuple(o)``. + + +.. cfunction:: PyObject* PySequence_Fast(PyObject *o, const char *m) + + Returns the sequence *o* as a tuple, unless it is already a tuple or list, in + which case *o* is returned. Use :cfunc:`PySequence_Fast_GET_ITEM` to access the + members of the result. Returns *NULL* on failure. If the object is not a + sequence, raises :exc:`TypeError` with *m* as the message text. + + +.. cfunction:: PyObject* PySequence_Fast_GET_ITEM(PyObject *o, Py_ssize_t i) + + Return the *i*th element of *o*, assuming that *o* was returned by + :cfunc:`PySequence_Fast`, *o* is not *NULL*, and that *i* is within bounds. + + +.. cfunction:: PyObject** PySequence_Fast_ITEMS(PyObject *o) + + Return the underlying array of PyObject pointers. Assumes that *o* was returned + by :cfunc:`PySequence_Fast` and *o* is not *NULL*. + + .. versionadded:: 2.4 + + +.. cfunction:: PyObject* PySequence_ITEM(PyObject *o, Py_ssize_t i) + + Return the *i*th element of *o* or *NULL* on failure. Macro form of + :cfunc:`PySequence_GetItem` but without checking that + :cfunc:`PySequence_Check(o)` is true and without adjustment for negative + indices. + + .. versionadded:: 2.3 + + +.. cfunction:: Py_ssize_t PySequence_Fast_GET_SIZE(PyObject *o) + + Returns the length of *o*, assuming that *o* was returned by + :cfunc:`PySequence_Fast` and that *o* is not *NULL*. The size can also be + gotten by calling :cfunc:`PySequence_Size` on *o*, but + :cfunc:`PySequence_Fast_GET_SIZE` is faster because it can assume *o* is a list + or tuple. Added: python/trunk/Doc/c-api/set.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/c-api/set.rst Sat Jan 19 23:08:21 2008 @@ -0,0 +1,148 @@ +.. highlightlang:: c + +.. _setobjects: + +Set Objects +----------- + +.. sectionauthor:: Raymond D. Hettinger + + +.. index:: + object: set + object: frozenset + +.. versionadded:: 2.5 + +This section details the public API for :class:`set` and :class:`frozenset` +objects. Any functionality not listed below is best accessed using the either +the abstract object protocol (including :cfunc:`PyObject_CallMethod`, +:cfunc:`PyObject_RichCompareBool`, :cfunc:`PyObject_Hash`, +:cfunc:`PyObject_Repr`, :cfunc:`PyObject_IsTrue`, :cfunc:`PyObject_Print`, and +:cfunc:`PyObject_GetIter`) or the abstract number protocol (including +:cfunc:`PyNumber_And`, :cfunc:`PyNumber_Subtract`, :cfunc:`PyNumber_Or`, +:cfunc:`PyNumber_Xor`, :cfunc:`PyNumber_InPlaceAnd`, +:cfunc:`PyNumber_InPlaceSubtract`, :cfunc:`PyNumber_InPlaceOr`, and +:cfunc:`PyNumber_InPlaceXor`). + + +.. ctype:: PySetObject + + This subtype of :ctype:`PyObject` is used to hold the internal data for both + :class:`set` and :class:`frozenset` objects. It is like a :ctype:`PyDictObject` + in that it is a fixed size for small sets (much like tuple storage) and will + point to a separate, variable sized block of memory for medium and large sized + sets (much like list storage). None of the fields of this structure should be + considered public and are subject to change. All access should be done through + the documented API rather than by manipulating the values in the structure. + + +.. cvar:: PyTypeObject PySet_Type + + This is an instance of :ctype:`PyTypeObject` representing the Python + :class:`set` type. + + +.. cvar:: PyTypeObject PyFrozenSet_Type + + This is an instance of :ctype:`PyTypeObject` representing the Python + :class:`frozenset` type. + +The following type check macros work on pointers to any Python object. Likewise, +the constructor functions work with any iterable Python object. + + +.. cfunction:: int PyAnySet_Check(PyObject *p) + + Return true if *p* is a :class:`set` object, a :class:`frozenset` object, or an + instance of a subtype. + + +.. cfunction:: int PyAnySet_CheckExact(PyObject *p) + + Return true if *p* is a :class:`set` object or a :class:`frozenset` object but + not an instance of a subtype. + + +.. cfunction:: int PyFrozenSet_CheckExact(PyObject *p) + + Return true if *p* is a :class:`frozenset` object but not an instance of a + subtype. + + +.. cfunction:: PyObject* PySet_New(PyObject *iterable) + + Return a new :class:`set` containing objects returned by the *iterable*. The + *iterable* may be *NULL* to create a new empty set. Return the new set on + success or *NULL* on failure. Raise :exc:`TypeError` if *iterable* is not + actually iterable. The constructor is also useful for copying a set + (``c=set(s)``). + + +.. cfunction:: PyObject* PyFrozenSet_New(PyObject *iterable) + + Return a new :class:`frozenset` containing objects returned by the *iterable*. + The *iterable* may be *NULL* to create a new empty frozenset. Return the new + set on success or *NULL* on failure. Raise :exc:`TypeError` if *iterable* is + not actually iterable. + +The following functions and macros are available for instances of :class:`set` +or :class:`frozenset` or instances of their subtypes. + + +.. cfunction:: Py_ssize_t PySet_Size(PyObject *anyset) + + .. index:: builtin: len + + Return the length of a :class:`set` or :class:`frozenset` object. Equivalent to + ``len(anyset)``. Raises a :exc:`PyExc_SystemError` if *anyset* is not a + :class:`set`, :class:`frozenset`, or an instance of a subtype. + + +.. cfunction:: Py_ssize_t PySet_GET_SIZE(PyObject *anyset) + + Macro form of :cfunc:`PySet_Size` without error checking. + + +.. cfunction:: int PySet_Contains(PyObject *anyset, PyObject *key) + + Return 1 if found, 0 if not found, and -1 if an error is encountered. Unlike + the Python :meth:`__contains__` method, this function does not automatically + convert unhashable sets into temporary frozensets. Raise a :exc:`TypeError` if + the *key* is unhashable. Raise :exc:`PyExc_SystemError` if *anyset* is not a + :class:`set`, :class:`frozenset`, or an instance of a subtype. + +The following functions are available for instances of :class:`set` or its +subtypes but not for instances of :class:`frozenset` or its subtypes. + + +.. cfunction:: int PySet_Add(PyObject *set, PyObject *key) + + Add *key* to a :class:`set` instance. Does not apply to :class:`frozenset` + instances. Return 0 on success or -1 on failure. Raise a :exc:`TypeError` if + the *key* is unhashable. Raise a :exc:`MemoryError` if there is no room to grow. + Raise a :exc:`SystemError` if *set* is an not an instance of :class:`set` or its + subtype. + + +.. cfunction:: int PySet_Discard(PyObject *set, PyObject *key) + + Return 1 if found and removed, 0 if not found (no action taken), and -1 if an + error is encountered. Does not raise :exc:`KeyError` for missing keys. Raise a + :exc:`TypeError` if the *key* is unhashable. Unlike the Python :meth:`discard` + method, this function does not automatically convert unhashable sets into + temporary frozensets. Raise :exc:`PyExc_SystemError` if *set* is an not an + instance of :class:`set` or its subtype. + + +.. cfunction:: PyObject* PySet_Pop(PyObject *set) + + Return a new reference to an arbitrary object in the *set*, and removes the + object from the *set*. Return *NULL* on failure. Raise :exc:`KeyError` if the + set is empty. Raise a :exc:`SystemError` if *set* is an not an instance of + :class:`set` or its subtype. + + +.. cfunction:: int PySet_Clear(PyObject *set) + + Empty an existing set of all elements. Added: python/trunk/Doc/c-api/slice.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/c-api/slice.rst Sat Jan 19 23:08:21 2008 @@ -0,0 +1,56 @@ +.. highlightlang:: c + +.. _slice-objects: + +Slice Objects +------------- + + +.. cvar:: PyTypeObject PySlice_Type + + .. index:: single: SliceType (in module types) + + The type object for slice objects. This is the same as ``slice`` and + ``types.SliceType``. + + +.. cfunction:: int PySlice_Check(PyObject *ob) + + Return true if *ob* is a slice object; *ob* must not be *NULL*. + + +.. cfunction:: PyObject* PySlice_New(PyObject *start, PyObject *stop, PyObject *step) + + Return a new slice object with the given values. The *start*, *stop*, and + *step* parameters are used as the values of the slice object attributes of the + same names. Any of the values may be *NULL*, in which case the ``None`` will be + used for the corresponding attribute. Return *NULL* if the new object could not + be allocated. + + +.. cfunction:: int PySlice_GetIndices(PySliceObject *slice, Py_ssize_t length, Py_ssize_t *start, Py_ssize_t *stop, Py_ssize_t *step) + + Retrieve the start, stop and step indices from the slice object *slice*, + assuming a sequence of length *length*. Treats indices greater than *length* as + errors. + + Returns 0 on success and -1 on error with no exception set (unless one of the + indices was not :const:`None` and failed to be converted to an integer, in which + case -1 is returned with an exception set). + + You probably do not want to use this function. If you want to use slice objects + in versions of Python prior to 2.3, you would probably do well to incorporate + the source of :cfunc:`PySlice_GetIndicesEx`, suitably renamed, in the source of + your extension. + + +.. cfunction:: int PySlice_GetIndicesEx(PySliceObject *slice, Py_ssize_t length, Py_ssize_t *start, Py_ssize_t *stop, Py_ssize_t *step, Py_ssize_t *slicelength) + + Usable replacement for :cfunc:`PySlice_GetIndices`. Retrieve the start, stop, + and step indices from the slice object *slice* assuming a sequence of length + *length*, and store the length of the slice in *slicelength*. Out of bounds + indices are clipped in a manner consistent with the handling of normal slices. + + Returns 0 on success and -1 on error with exception set. + + .. versionadded:: 2.3 Added: python/trunk/Doc/c-api/string.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/c-api/string.rst Sat Jan 19 23:08:21 2008 @@ -0,0 +1,260 @@ +.. highlightlang:: c + +.. _stringobjects: + +String Objects +-------------- + +These functions raise :exc:`TypeError` when expecting a string parameter and are +called with a non-string parameter. + +.. index:: object: string + + +.. ctype:: PyStringObject + + This subtype of :ctype:`PyObject` represents a Python string object. + + +.. cvar:: PyTypeObject PyString_Type + + .. index:: single: StringType (in module types) + + This instance of :ctype:`PyTypeObject` represents the Python string type; it is + the same object as ``str`` and ``types.StringType`` in the Python layer. . + + +.. cfunction:: int PyString_Check(PyObject *o) + + Return true if the object *o* is a string object or an instance of a subtype of + the string type. + + .. versionchanged:: 2.2 + Allowed subtypes to be accepted. + + +.. cfunction:: int PyString_CheckExact(PyObject *o) + + Return true if the object *o* is a string object, but not an instance of a + subtype of the string type. + + .. versionadded:: 2.2 + + +.. cfunction:: PyObject* PyString_FromString(const char *v) + + Return a new string object with a copy of the string *v* as value on success, + and *NULL* on failure. The parameter *v* must not be *NULL*; it will not be + checked. + + +.. cfunction:: PyObject* PyString_FromStringAndSize(const char *v, Py_ssize_t len) + + Return a new string object with a copy of the string *v* as value and length + *len* on success, and *NULL* on failure. If *v* is *NULL*, the contents of the + string are uninitialized. + + +.. cfunction:: PyObject* PyString_FromFormat(const char *format, ...) + + Take a C :cfunc:`printf`\ -style *format* string and a variable number of + arguments, calculate the size of the resulting Python string and return a string + with the values formatted into it. The variable arguments must be C types and + must correspond exactly to the format characters in the *format* string. The + following format characters are allowed: + + .. % This should be exactly the same as the table in PyErr_Format. + .. % One should just refer to the other. + .. % The descriptions for %zd and %zu are wrong, but the truth is complicated + .. % because not all compilers support the %z width modifier -- we fake it + .. % when necessary via interpolating PY_FORMAT_SIZE_T. + .. % %u, %lu, %zu should have "new in Python 2.5" blurbs. + + +-------------------+---------------+--------------------------------+ + | Format Characters | Type | Comment | + +===================+===============+================================+ + | :attr:`%%` | *n/a* | The literal % character. | + +-------------------+---------------+--------------------------------+ + | :attr:`%c` | int | A single character, | + | | | represented as an C int. | + +-------------------+---------------+--------------------------------+ + | :attr:`%d` | int | Exactly equivalent to | + | | | ``printf("%d")``. | + +-------------------+---------------+--------------------------------+ + | :attr:`%u` | unsigned int | Exactly equivalent to | + | | | ``printf("%u")``. | + +-------------------+---------------+--------------------------------+ + | :attr:`%ld` | long | Exactly equivalent to | + | | | ``printf("%ld")``. | + +-------------------+---------------+--------------------------------+ + | :attr:`%lu` | unsigned long | Exactly equivalent to | + | | | ``printf("%lu")``. | + +-------------------+---------------+--------------------------------+ + | :attr:`%zd` | Py_ssize_t | Exactly equivalent to | + | | | ``printf("%zd")``. | + +-------------------+---------------+--------------------------------+ + | :attr:`%zu` | size_t | Exactly equivalent to | + | | | ``printf("%zu")``. | + +-------------------+---------------+--------------------------------+ + | :attr:`%i` | int | Exactly equivalent to | + | | | ``printf("%i")``. | + +-------------------+---------------+--------------------------------+ + | :attr:`%x` | int | Exactly equivalent to | + | | | ``printf("%x")``. | + +-------------------+---------------+--------------------------------+ + | :attr:`%s` | char\* | A null-terminated C character | + | | | array. | + +-------------------+---------------+--------------------------------+ + | :attr:`%p` | void\* | The hex representation of a C | + | | | pointer. Mostly equivalent to | + | | | ``printf("%p")`` except that | + | | | it is guaranteed to start with | + | | | the literal ``0x`` regardless | + | | | of what the platform's | + | | | ``printf`` yields. | + +-------------------+---------------+--------------------------------+ + + An unrecognized format character causes all the rest of the format string to be + copied as-is to the result string, and any extra arguments discarded. + + +.. cfunction:: PyObject* PyString_FromFormatV(const char *format, va_list vargs) + + Identical to :func:`PyString_FromFormat` except that it takes exactly two + arguments. + + +.. cfunction:: Py_ssize_t PyString_Size(PyObject *string) + + Return the length of the string in string object *string*. + + +.. cfunction:: Py_ssize_t PyString_GET_SIZE(PyObject *string) + + Macro form of :cfunc:`PyString_Size` but without error checking. + + +.. cfunction:: char* PyString_AsString(PyObject *string) + + Return a NUL-terminated representation of the contents of *string*. The pointer + refers to the internal buffer of *string*, not a copy. The data must not be + modified in any way, unless the string was just created using + ``PyString_FromStringAndSize(NULL, size)``. It must not be deallocated. If + *string* is a Unicode object, this function computes the default encoding of + *string* and operates on that. If *string* is not a string object at all, + :cfunc:`PyString_AsString` returns *NULL* and raises :exc:`TypeError`. + + +.. cfunction:: char* PyString_AS_STRING(PyObject *string) + + Macro form of :cfunc:`PyString_AsString` but without error checking. Only + string objects are supported; no Unicode objects should be passed. + + +.. cfunction:: int PyString_AsStringAndSize(PyObject *obj, char **buffer, Py_ssize_t *length) + + Return a NUL-terminated representation of the contents of the object *obj* + through the output variables *buffer* and *length*. + + The function accepts both string and Unicode objects as input. For Unicode + objects it returns the default encoded version of the object. If *length* is + *NULL*, the resulting buffer may not contain NUL characters; if it does, the + function returns ``-1`` and a :exc:`TypeError` is raised. + + The buffer refers to an internal string buffer of *obj*, not a copy. The data + must not be modified in any way, unless the string was just created using + ``PyString_FromStringAndSize(NULL, size)``. It must not be deallocated. If + *string* is a Unicode object, this function computes the default encoding of + *string* and operates on that. If *string* is not a string object at all, + :cfunc:`PyString_AsStringAndSize` returns ``-1`` and raises :exc:`TypeError`. + + +.. cfunction:: void PyString_Concat(PyObject **string, PyObject *newpart) + + Create a new string object in *\*string* containing the contents of *newpart* + appended to *string*; the caller will own the new reference. The reference to + the old value of *string* will be stolen. If the new string cannot be created, + the old reference to *string* will still be discarded and the value of + *\*string* will be set to *NULL*; the appropriate exception will be set. + + +.. cfunction:: void PyString_ConcatAndDel(PyObject **string, PyObject *newpart) + + Create a new string object in *\*string* containing the contents of *newpart* + appended to *string*. This version decrements the reference count of *newpart*. + + +.. cfunction:: int _PyString_Resize(PyObject **string, Py_ssize_t newsize) + + A way to resize a string object even though it is "immutable". Only use this to + build up a brand new string object; don't use this if the string may already be + known in other parts of the code. It is an error to call this function if the + refcount on the input string object is not one. Pass the address of an existing + string object as an lvalue (it may be written into), and the new size desired. + On success, *\*string* holds the resized string object and ``0`` is returned; + the address in *\*string* may differ from its input value. If the reallocation + fails, the original string object at *\*string* is deallocated, *\*string* is + set to *NULL*, a memory exception is set, and ``-1`` is returned. + + +.. cfunction:: PyObject* PyString_Format(PyObject *format, PyObject *args) + + Return a new string object from *format* and *args*. Analogous to ``format % + args``. The *args* argument must be a tuple. + + +.. cfunction:: void PyString_InternInPlace(PyObject **string) + + Intern the argument *\*string* in place. The argument must be the address of a + pointer variable pointing to a Python string object. If there is an existing + interned string that is the same as *\*string*, it sets *\*string* to it + (decrementing the reference count of the old string object and incrementing the + reference count of the interned string object), otherwise it leaves *\*string* + alone and interns it (incrementing its reference count). (Clarification: even + though there is a lot of talk about reference counts, think of this function as + reference-count-neutral; you own the object after the call if and only if you + owned it before the call.) + + +.. cfunction:: PyObject* PyString_InternFromString(const char *v) + + A combination of :cfunc:`PyString_FromString` and + :cfunc:`PyString_InternInPlace`, returning either a new string object that has + been interned, or a new ("owned") reference to an earlier interned string object + with the same value. + + +.. cfunction:: PyObject* PyString_Decode(const char *s, Py_ssize_t size, const char *encoding, const char *errors) + + Create an object by decoding *size* bytes of the encoded buffer *s* using the + codec registered for *encoding*. *encoding* and *errors* have the same meaning + as the parameters of the same name in the :func:`unicode` built-in function. + The codec to be used is looked up using the Python codec registry. Return + *NULL* if an exception was raised by the codec. + + +.. cfunction:: PyObject* PyString_AsDecodedObject(PyObject *str, const char *encoding, const char *errors) + + Decode a string object by passing it to the codec registered for *encoding* and + return the result as Python object. *encoding* and *errors* have the same + meaning as the parameters of the same name in the string :meth:`encode` method. + The codec to be used is looked up using the Python codec registry. Return *NULL* + if an exception was raised by the codec. + + +.. cfunction:: PyObject* PyString_Encode(const char *s, Py_ssize_t size, const char *encoding, const char *errors) + + Encode the :ctype:`char` buffer of the given size by passing it to the codec + registered for *encoding* and return a Python object. *encoding* and *errors* + have the same meaning as the parameters of the same name in the string + :meth:`encode` method. The codec to be used is looked up using the Python codec + registry. Return *NULL* if an exception was raised by the codec. + + +.. cfunction:: PyObject* PyString_AsEncodedObject(PyObject *str, const char *encoding, const char *errors) + + Encode a string object using the codec registered for *encoding* and return the + result as Python object. *encoding* and *errors* have the same meaning as the + parameters of the same name in the string :meth:`encode` method. The codec to be + used is looked up using the Python codec registry. Return *NULL* if an exception + was raised by the codec. Added: python/trunk/Doc/c-api/structures.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/c-api/structures.rst Sat Jan 19 23:08:21 2008 @@ -0,0 +1,212 @@ +.. highlightlang:: c + +.. _common-structs: + +Common Object Structures +======================== + +There are a large number of structures which are used in the definition of +object types for Python. This section describes these structures and how they +are used. + +All Python objects ultimately share a small number of fields at the beginning of +the object's representation in memory. These are represented by the +:ctype:`PyObject` and :ctype:`PyVarObject` types, which are defined, in turn, by +the expansions of some macros also used, whether directly or indirectly, in the +definition of all other Python objects. + + +.. ctype:: PyObject + + All object types are extensions of this type. This is a type which contains the + information Python needs to treat a pointer to an object as an object. In a + normal "release" build, it contains only the objects reference count and a + pointer to the corresponding type object. It corresponds to the fields defined + by the expansion of the ``PyObject_HEAD`` macro. + + +.. ctype:: PyVarObject + + This is an extension of :ctype:`PyObject` that adds the :attr:`ob_size` field. + This is only used for objects that have some notion of *length*. This type does + not often appear in the Python/C API. It corresponds to the fields defined by + the expansion of the ``PyObject_VAR_HEAD`` macro. + +These macros are used in the definition of :ctype:`PyObject` and +:ctype:`PyVarObject`: + + +.. cmacro:: PyObject_HEAD + + This is a macro which expands to the declarations of the fields of the + :ctype:`PyObject` type; it is used when declaring new types which represent + objects without a varying length. The specific fields it expands to depend on + the definition of :cmacro:`Py_TRACE_REFS`. By default, that macro is not + defined, and :cmacro:`PyObject_HEAD` expands to:: + + Py_ssize_t ob_refcnt; + PyTypeObject *ob_type; + + When :cmacro:`Py_TRACE_REFS` is defined, it expands to:: + + PyObject *_ob_next, *_ob_prev; + Py_ssize_t ob_refcnt; + PyTypeObject *ob_type; + + +.. cmacro:: PyObject_VAR_HEAD + + This is a macro which expands to the declarations of the fields of the + :ctype:`PyVarObject` type; it is used when declaring new types which represent + objects with a length that varies from instance to instance. This macro always + expands to:: + + PyObject_HEAD + Py_ssize_t ob_size; + + Note that :cmacro:`PyObject_HEAD` is part of the expansion, and that its own + expansion varies depending on the definition of :cmacro:`Py_TRACE_REFS`. + +PyObject_HEAD_INIT + + +.. ctype:: PyCFunction + + Type of the functions used to implement most Python callables in C. Functions of + this type take two :ctype:`PyObject\*` parameters and return one such value. If + the return value is *NULL*, an exception shall have been set. If not *NULL*, + the return value is interpreted as the return value of the function as exposed + in Python. The function must return a new reference. + + +.. ctype:: PyMethodDef + + Structure used to describe a method of an extension type. This structure has + four fields: + + +------------------+-------------+-------------------------------+ + | Field | C Type | Meaning | + +==================+=============+===============================+ + | :attr:`ml_name` | char \* | name of the method | + +------------------+-------------+-------------------------------+ + | :attr:`ml_meth` | PyCFunction | pointer to the C | + | | | implementation | + +------------------+-------------+-------------------------------+ + | :attr:`ml_flags` | int | flag bits indicating how the | + | | | call should be constructed | + +------------------+-------------+-------------------------------+ + | :attr:`ml_doc` | char \* | points to the contents of the | + | | | docstring | + +------------------+-------------+-------------------------------+ + +The :attr:`ml_meth` is a C function pointer. The functions may be of different +types, but they always return :ctype:`PyObject\*`. If the function is not of +the :ctype:`PyCFunction`, the compiler will require a cast in the method table. +Even though :ctype:`PyCFunction` defines the first parameter as +:ctype:`PyObject\*`, it is common that the method implementation uses a the +specific C type of the *self* object. + +The :attr:`ml_flags` field is a bitfield which can include the following flags. +The individual flags indicate either a calling convention or a binding +convention. Of the calling convention flags, only :const:`METH_VARARGS` and +:const:`METH_KEYWORDS` can be combined (but note that :const:`METH_KEYWORDS` +alone is equivalent to ``METH_VARARGS | METH_KEYWORDS``). Any of the calling +convention flags can be combined with a binding flag. + + +.. data:: METH_VARARGS + + This is the typical calling convention, where the methods have the type + :ctype:`PyCFunction`. The function expects two :ctype:`PyObject\*` values. The + first one is the *self* object for methods; for module functions, it has the + value given to :cfunc:`Py_InitModule4` (or *NULL* if :cfunc:`Py_InitModule` was + used). The second parameter (often called *args*) is a tuple object + representing all arguments. This parameter is typically processed using + :cfunc:`PyArg_ParseTuple` or :cfunc:`PyArg_UnpackTuple`. + + +.. data:: METH_KEYWORDS + + Methods with these flags must be of type :ctype:`PyCFunctionWithKeywords`. The + function expects three parameters: *self*, *args*, and a dictionary of all the + keyword arguments. The flag is typically combined with :const:`METH_VARARGS`, + and the parameters are typically processed using + :cfunc:`PyArg_ParseTupleAndKeywords`. + + +.. data:: METH_NOARGS + + Methods without parameters don't need to check whether arguments are given if + they are listed with the :const:`METH_NOARGS` flag. They need to be of type + :ctype:`PyCFunction`. When used with object methods, the first parameter is + typically named ``self`` and will hold a reference to the object instance. In + all cases the second parameter will be *NULL*. + + +.. data:: METH_O + + Methods with a single object argument can be listed with the :const:`METH_O` + flag, instead of invoking :cfunc:`PyArg_ParseTuple` with a ``"O"`` argument. + They have the type :ctype:`PyCFunction`, with the *self* parameter, and a + :ctype:`PyObject\*` parameter representing the single argument. + + +.. data:: METH_OLDARGS + + This calling convention is deprecated. The method must be of type + :ctype:`PyCFunction`. The second argument is *NULL* if no arguments are given, + a single object if exactly one argument is given, and a tuple of objects if more + than one argument is given. There is no way for a function using this + convention to distinguish between a call with multiple arguments and a call with + a tuple as the only argument. + +These two constants are not used to indicate the calling convention but the +binding when use with methods of classes. These may not be used for functions +defined for modules. At most one of these flags may be set for any given +method. + + +.. data:: METH_CLASS + + .. index:: builtin: classmethod + + The method will be passed the type object as the first parameter rather than an + instance of the type. This is used to create *class methods*, similar to what + is created when using the :func:`classmethod` built-in function. + + .. versionadded:: 2.3 + + +.. data:: METH_STATIC + + .. index:: builtin: staticmethod + + The method will be passed *NULL* as the first parameter rather than an instance + of the type. This is used to create *static methods*, similar to what is + created when using the :func:`staticmethod` built-in function. + + .. versionadded:: 2.3 + +One other constant controls whether a method is loaded in place of another +definition with the same method name. + + +.. data:: METH_COEXIST + + The method will be loaded in place of existing definitions. Without + *METH_COEXIST*, the default is to skip repeated definitions. Since slot + wrappers are loaded before the method table, the existence of a *sq_contains* + slot, for example, would generate a wrapped method named :meth:`__contains__` + and preclude the loading of a corresponding PyCFunction with the same name. + With the flag defined, the PyCFunction will be loaded in place of the wrapper + object and will co-exist with the slot. This is helpful because calls to + PyCFunctions are optimized more than wrapper object calls. + + .. versionadded:: 2.4 + + +.. cfunction:: PyObject* Py_FindMethod(PyMethodDef table[], PyObject *ob, char *name) + + Return a bound method object for an extension type implemented in C. This can + be useful in the implementation of a :attr:`tp_getattro` or :attr:`tp_getattr` + handler that does not use the :cfunc:`PyObject_GenericGetAttr` function. Added: python/trunk/Doc/c-api/tuple.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/c-api/tuple.rst Sat Jan 19 23:08:21 2008 @@ -0,0 +1,117 @@ +.. highlightlang:: c + +.. _tupleobjects: + +Tuple Objects +------------- + +.. index:: object: tuple + + +.. ctype:: PyTupleObject + + This subtype of :ctype:`PyObject` represents a Python tuple object. + + +.. cvar:: PyTypeObject PyTuple_Type + + .. index:: single: TupleType (in module types) + + This instance of :ctype:`PyTypeObject` represents the Python tuple type; it is + the same object as ``tuple`` and ``types.TupleType`` in the Python layer.. + + +.. cfunction:: int PyTuple_Check(PyObject *p) + + Return true if *p* is a tuple object or an instance of a subtype of the tuple + type. + + .. versionchanged:: 2.2 + Allowed subtypes to be accepted. + + +.. cfunction:: int PyTuple_CheckExact(PyObject *p) + + Return true if *p* is a tuple object, but not an instance of a subtype of the + tuple type. + + .. versionadded:: 2.2 + + +.. cfunction:: PyObject* PyTuple_New(Py_ssize_t len) + + Return a new tuple object of size *len*, or *NULL* on failure. + + +.. cfunction:: PyObject* PyTuple_Pack(Py_ssize_t n, ...) + + Return a new tuple object of size *n*, or *NULL* on failure. The tuple values + are initialized to the subsequent *n* C arguments pointing to Python objects. + ``PyTuple_Pack(2, a, b)`` is equivalent to ``Py_BuildValue("(OO)", a, b)``. + + .. versionadded:: 2.4 + + +.. cfunction:: Py_ssize_t PyTuple_Size(PyObject *p) + + Take a pointer to a tuple object, and return the size of that tuple. + + +.. cfunction:: Py_ssize_t PyTuple_GET_SIZE(PyObject *p) + + Return the size of the tuple *p*, which must be non-*NULL* and point to a tuple; + no error checking is performed. + + +.. cfunction:: PyObject* PyTuple_GetItem(PyObject *p, Py_ssize_t pos) + + Return the object at position *pos* in the tuple pointed to by *p*. If *pos* is + out of bounds, return *NULL* and sets an :exc:`IndexError` exception. + + +.. cfunction:: PyObject* PyTuple_GET_ITEM(PyObject *p, Py_ssize_t pos) + + Like :cfunc:`PyTuple_GetItem`, but does no checking of its arguments. + + +.. cfunction:: PyObject* PyTuple_GetSlice(PyObject *p, Py_ssize_t low, Py_ssize_t high) + + Take a slice of the tuple pointed to by *p* from *low* to *high* and return it + as a new tuple. + + +.. cfunction:: int PyTuple_SetItem(PyObject *p, Py_ssize_t pos, PyObject *o) + + Insert a reference to object *o* at position *pos* of the tuple pointed to by + *p*. Return ``0`` on success. + + .. note:: + + This function "steals" a reference to *o*. + + +.. cfunction:: void PyTuple_SET_ITEM(PyObject *p, Py_ssize_t pos, PyObject *o) + + Like :cfunc:`PyTuple_SetItem`, but does no error checking, and should *only* be + used to fill in brand new tuples. + + .. note:: + + This function "steals" a reference to *o*. + + +.. cfunction:: int _PyTuple_Resize(PyObject **p, Py_ssize_t newsize) + + Can be used to resize a tuple. *newsize* will be the new length of the tuple. + Because tuples are *supposed* to be immutable, this should only be used if there + is only one reference to the object. Do *not* use this if the tuple may already + be known to some other part of the code. The tuple will always grow or shrink + at the end. Think of this as destroying the old tuple and creating a new one, + only more efficiently. Returns ``0`` on success. Client code should never + assume that the resulting value of ``*p`` will be the same as before calling + this function. If the object referenced by ``*p`` is replaced, the original + ``*p`` is destroyed. On failure, returns ``-1`` and sets ``*p`` to *NULL*, and + raises :exc:`MemoryError` or :exc:`SystemError`. + + .. versionchanged:: 2.2 + Removed unused third parameter, *last_is_sticky*. Added: python/trunk/Doc/c-api/type.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/c-api/type.rst Sat Jan 19 23:08:21 2008 @@ -0,0 +1,76 @@ +.. highlightlang:: c + +.. _typeobjects: + +Type Objects +------------ + +.. index:: object: type + + +.. ctype:: PyTypeObject + + The C structure of the objects used to describe built-in types. + + +.. cvar:: PyObject* PyType_Type + + .. index:: single: TypeType (in module types) + + This is the type object for type objects; it is the same object as ``type`` and + ``types.TypeType`` in the Python layer. + + +.. cfunction:: int PyType_Check(PyObject *o) + + Return true if the object *o* is a type object, including instances of types + derived from the standard type object. Return false in all other cases. + + +.. cfunction:: int PyType_CheckExact(PyObject *o) + + Return true if the object *o* is a type object, but not a subtype of the + standard type object. Return false in all other cases. + + .. versionadded:: 2.2 + + +.. cfunction:: int PyType_HasFeature(PyObject *o, int feature) + + Return true if the type object *o* sets the feature *feature*. Type features + are denoted by single bit flags. + + +.. cfunction:: int PyType_IS_GC(PyObject *o) + + Return true if the type object includes support for the cycle detector; this + tests the type flag :const:`Py_TPFLAGS_HAVE_GC`. + + .. versionadded:: 2.0 + + +.. cfunction:: int PyType_IsSubtype(PyTypeObject *a, PyTypeObject *b) + + Return true if *a* is a subtype of *b*. + + .. versionadded:: 2.2 + + +.. cfunction:: PyObject* PyType_GenericAlloc(PyTypeObject *type, Py_ssize_t nitems) + + .. versionadded:: 2.2 + + +.. cfunction:: PyObject* PyType_GenericNew(PyTypeObject *type, PyObject *args, PyObject *kwds) + + .. versionadded:: 2.2 + + +.. cfunction:: int PyType_Ready(PyTypeObject *type) + + Finalize a type object. This should be called on all type objects to finish + their initialization. This function is responsible for adding inherited slots + from a type's base class. Return ``0`` on success, or return ``-1`` and sets an + exception on error. + + .. versionadded:: 2.2 Added: python/trunk/Doc/c-api/typeobj.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/c-api/typeobj.rst Sat Jan 19 23:08:21 2008 @@ -0,0 +1,1425 @@ +.. highlightlang:: c + +.. _type-structs: + +Type Objects +============ + +Perhaps one of the most important structures of the Python object system is the +structure that defines a new type: the :ctype:`PyTypeObject` structure. Type +objects can be handled using any of the :cfunc:`PyObject_\*` or +:cfunc:`PyType_\*` functions, but do not offer much that's interesting to most +Python applications. These objects are fundamental to how objects behave, so +they are very important to the interpreter itself and to any extension module +that implements new types. + +Type objects are fairly large compared to most of the standard types. The reason +for the size is that each type object stores a large number of values, mostly C +function pointers, each of which implements a small part of the type's +functionality. The fields of the type object are examined in detail in this +section. The fields will be described in the order in which they occur in the +structure. + +Typedefs: unaryfunc, binaryfunc, ternaryfunc, inquiry, coercion, intargfunc, +intintargfunc, intobjargproc, intintobjargproc, objobjargproc, destructor, +freefunc, printfunc, getattrfunc, getattrofunc, setattrfunc, setattrofunc, +cmpfunc, reprfunc, hashfunc + +The structure definition for :ctype:`PyTypeObject` can be found in +:file:`Include/object.h`. For convenience of reference, this repeats the +definition found there: + +.. literalinclude:: ../includes/typestruct.h + + +The type object structure extends the :ctype:`PyVarObject` structure. The +:attr:`ob_size` field is used for dynamic types (created by :func:`type_new`, +usually called from a class statement). Note that :cdata:`PyType_Type` (the +metatype) initializes :attr:`tp_itemsize`, which means that its instances (i.e. +type objects) *must* have the :attr:`ob_size` field. + + +.. cmember:: PyObject* PyObject._ob_next + PyObject* PyObject._ob_prev + + These fields are only present when the macro ``Py_TRACE_REFS`` is defined. + Their initialization to *NULL* is taken care of by the ``PyObject_HEAD_INIT`` + macro. For statically allocated objects, these fields always remain *NULL*. + For dynamically allocated objects, these two fields are used to link the object + into a doubly-linked list of *all* live objects on the heap. This could be used + for various debugging purposes; currently the only use is to print the objects + that are still alive at the end of a run when the environment variable + :envvar:`PYTHONDUMPREFS` is set. + + These fields are not inherited by subtypes. + + +.. cmember:: Py_ssize_t PyObject.ob_refcnt + + This is the type object's reference count, initialized to ``1`` by the + ``PyObject_HEAD_INIT`` macro. Note that for statically allocated type objects, + the type's instances (objects whose :attr:`ob_type` points back to the type) do + *not* count as references. But for dynamically allocated type objects, the + instances *do* count as references. + + This field is not inherited by subtypes. + + +.. cmember:: PyTypeObject* PyObject.ob_type + + This is the type's type, in other words its metatype. It is initialized by the + argument to the ``PyObject_HEAD_INIT`` macro, and its value should normally be + ``&PyType_Type``. However, for dynamically loadable extension modules that must + be usable on Windows (at least), the compiler complains that this is not a valid + initializer. Therefore, the convention is to pass *NULL* to the + ``PyObject_HEAD_INIT`` macro and to initialize this field explicitly at the + start of the module's initialization function, before doing anything else. This + is typically done like this:: + + Foo_Type.ob_type = &PyType_Type; + + This should be done before any instances of the type are created. + :cfunc:`PyType_Ready` checks if :attr:`ob_type` is *NULL*, and if so, + initializes it: in Python 2.2, it is set to ``&PyType_Type``; in Python 2.2.1 + and later it is initialized to the :attr:`ob_type` field of the base class. + :cfunc:`PyType_Ready` will not change this field if it is non-zero. + + In Python 2.2, this field is not inherited by subtypes. In 2.2.1, and in 2.3 + and beyond, it is inherited by subtypes. + + +.. cmember:: Py_ssize_t PyVarObject.ob_size + + For statically allocated type objects, this should be initialized to zero. For + dynamically allocated type objects, this field has a special internal meaning. + + This field is not inherited by subtypes. + + +.. cmember:: char* PyTypeObject.tp_name + + Pointer to a NUL-terminated string containing the name of the type. For types + that are accessible as module globals, the string should be the full module + name, followed by a dot, followed by the type name; for built-in types, it + should be just the type name. If the module is a submodule of a package, the + full package name is part of the full module name. For example, a type named + :class:`T` defined in module :mod:`M` in subpackage :mod:`Q` in package :mod:`P` + should have the :attr:`tp_name` initializer ``"P.Q.M.T"``. + + For dynamically allocated type objects, this should just be the type name, and + the module name explicitly stored in the type dict as the value for key + ``'__module__'``. + + For statically allocated type objects, the tp_name field should contain a dot. + Everything before the last dot is made accessible as the :attr:`__module__` + attribute, and everything after the last dot is made accessible as the + :attr:`__name__` attribute. + + If no dot is present, the entire :attr:`tp_name` field is made accessible as the + :attr:`__name__` attribute, and the :attr:`__module__` attribute is undefined + (unless explicitly set in the dictionary, as explained above). This means your + type will be impossible to pickle. + + This field is not inherited by subtypes. + + +.. cmember:: Py_ssize_t PyTypeObject.tp_basicsize + Py_ssize_t PyTypeObject.tp_itemsize + + These fields allow calculating the size in bytes of instances of the type. + + There are two kinds of types: types with fixed-length instances have a zero + :attr:`tp_itemsize` field, types with variable-length instances have a non-zero + :attr:`tp_itemsize` field. For a type with fixed-length instances, all + instances have the same size, given in :attr:`tp_basicsize`. + + For a type with variable-length instances, the instances must have an + :attr:`ob_size` field, and the instance size is :attr:`tp_basicsize` plus N + times :attr:`tp_itemsize`, where N is the "length" of the object. The value of + N is typically stored in the instance's :attr:`ob_size` field. There are + exceptions: for example, long ints use a negative :attr:`ob_size` to indicate a + negative number, and N is ``abs(ob_size)`` there. Also, the presence of an + :attr:`ob_size` field in the instance layout doesn't mean that the instance + structure is variable-length (for example, the structure for the list type has + fixed-length instances, yet those instances have a meaningful :attr:`ob_size` + field). + + The basic size includes the fields in the instance declared by the macro + :cmacro:`PyObject_HEAD` or :cmacro:`PyObject_VAR_HEAD` (whichever is used to + declare the instance struct) and this in turn includes the :attr:`_ob_prev` and + :attr:`_ob_next` fields if they are present. This means that the only correct + way to get an initializer for the :attr:`tp_basicsize` is to use the + ``sizeof`` operator on the struct used to declare the instance layout. + The basic size does not include the GC header size (this is new in Python 2.2; + in 2.1 and 2.0, the GC header size was included in :attr:`tp_basicsize`). + + These fields are inherited separately by subtypes. If the base type has a + non-zero :attr:`tp_itemsize`, it is generally not safe to set + :attr:`tp_itemsize` to a different non-zero value in a subtype (though this + depends on the implementation of the base type). + + A note about alignment: if the variable items require a particular alignment, + this should be taken care of by the value of :attr:`tp_basicsize`. Example: + suppose a type implements an array of ``double``. :attr:`tp_itemsize` is + ``sizeof(double)``. It is the programmer's responsibility that + :attr:`tp_basicsize` is a multiple of ``sizeof(double)`` (assuming this is the + alignment requirement for ``double``). + + +.. cmember:: destructor PyTypeObject.tp_dealloc + + A pointer to the instance destructor function. This function must be defined + unless the type guarantees that its instances will never be deallocated (as is + the case for the singletons ``None`` and ``Ellipsis``). + + The destructor function is called by the :cfunc:`Py_DECREF` and + :cfunc:`Py_XDECREF` macros when the new reference count is zero. At this point, + the instance is still in existence, but there are no references to it. The + destructor function should free all references which the instance owns, free all + memory buffers owned by the instance (using the freeing function corresponding + to the allocation function used to allocate the buffer), and finally (as its + last action) call the type's :attr:`tp_free` function. If the type is not + subtypable (doesn't have the :const:`Py_TPFLAGS_BASETYPE` flag bit set), it is + permissible to call the object deallocator directly instead of via + :attr:`tp_free`. The object deallocator should be the one used to allocate the + instance; this is normally :cfunc:`PyObject_Del` if the instance was allocated + using :cfunc:`PyObject_New` or :cfunc:`PyObject_VarNew`, or + :cfunc:`PyObject_GC_Del` if the instance was allocated using + :cfunc:`PyObject_GC_New` or :cfunc:`PyObject_GC_VarNew`. + + This field is inherited by subtypes. + + +.. cmember:: printfunc PyTypeObject.tp_print + + An optional pointer to the instance print function. + + The print function is only called when the instance is printed to a *real* file; + when it is printed to a pseudo-file (like a :class:`StringIO` instance), the + instance's :attr:`tp_repr` or :attr:`tp_str` function is called to convert it to + a string. These are also called when the type's :attr:`tp_print` field is + *NULL*. A type should never implement :attr:`tp_print` in a way that produces + different output than :attr:`tp_repr` or :attr:`tp_str` would. + + The print function is called with the same signature as :cfunc:`PyObject_Print`: + ``int tp_print(PyObject *self, FILE *file, int flags)``. The *self* argument is + the instance to be printed. The *file* argument is the stdio file to which it + is to be printed. The *flags* argument is composed of flag bits. The only flag + bit currently defined is :const:`Py_PRINT_RAW`. When the :const:`Py_PRINT_RAW` + flag bit is set, the instance should be printed the same way as :attr:`tp_str` + would format it; when the :const:`Py_PRINT_RAW` flag bit is clear, the instance + should be printed the same was as :attr:`tp_repr` would format it. It should + return ``-1`` and set an exception condition when an error occurred during the + comparison. + + It is possible that the :attr:`tp_print` field will be deprecated. In any case, + it is recommended not to define :attr:`tp_print`, but instead to rely on + :attr:`tp_repr` and :attr:`tp_str` for printing. + + This field is inherited by subtypes. + + +.. cmember:: getattrfunc PyTypeObject.tp_getattr + + An optional pointer to the get-attribute-string function. + + This field is deprecated. When it is defined, it should point to a function + that acts the same as the :attr:`tp_getattro` function, but taking a C string + instead of a Python string object to give the attribute name. The signature is + the same as for :cfunc:`PyObject_GetAttrString`. + + This field is inherited by subtypes together with :attr:`tp_getattro`: a subtype + inherits both :attr:`tp_getattr` and :attr:`tp_getattro` from its base type when + the subtype's :attr:`tp_getattr` and :attr:`tp_getattro` are both *NULL*. + + +.. cmember:: setattrfunc PyTypeObject.tp_setattr + + An optional pointer to the set-attribute-string function. + + This field is deprecated. When it is defined, it should point to a function + that acts the same as the :attr:`tp_setattro` function, but taking a C string + instead of a Python string object to give the attribute name. The signature is + the same as for :cfunc:`PyObject_SetAttrString`. + + This field is inherited by subtypes together with :attr:`tp_setattro`: a subtype + inherits both :attr:`tp_setattr` and :attr:`tp_setattro` from its base type when + the subtype's :attr:`tp_setattr` and :attr:`tp_setattro` are both *NULL*. + + +.. cmember:: cmpfunc PyTypeObject.tp_compare + + An optional pointer to the three-way comparison function. + + The signature is the same as for :cfunc:`PyObject_Compare`. The function should + return ``1`` if *self* greater than *other*, ``0`` if *self* is equal to + *other*, and ``-1`` if *self* less than *other*. It should return ``-1`` and + set an exception condition when an error occurred during the comparison. + + This field is inherited by subtypes together with :attr:`tp_richcompare` and + :attr:`tp_hash`: a subtypes inherits all three of :attr:`tp_compare`, + :attr:`tp_richcompare`, and :attr:`tp_hash` when the subtype's + :attr:`tp_compare`, :attr:`tp_richcompare`, and :attr:`tp_hash` are all *NULL*. + + +.. cmember:: reprfunc PyTypeObject.tp_repr + + .. index:: builtin: repr + + An optional pointer to a function that implements the built-in function + :func:`repr`. + + The signature is the same as for :cfunc:`PyObject_Repr`; it must return a string + or a Unicode object. Ideally, this function should return a string that, when + passed to :func:`eval`, given a suitable environment, returns an object with the + same value. If this is not feasible, it should return a string starting with + ``'<'`` and ending with ``'>'`` from which both the type and the value of the + object can be deduced. + + When this field is not set, a string of the form ``<%s object at %p>`` is + returned, where ``%s`` is replaced by the type name, and ``%p`` by the object's + memory address. + + This field is inherited by subtypes. + +.. cmember:: PyNumberMethods* tp_as_number + + Pointer to an additional structure that contains fields relevant only to + objects which implement the number protocol. These fields are documented in + :ref:`number-structs`. + + The :attr:`tp_as_number` field is not inherited, but the contained fields are + inherited individually. + + +.. cmember:: PySequenceMethods* tp_as_sequence + + Pointer to an additional structure that contains fields relevant only to + objects which implement the sequence protocol. These fields are documented + in :ref:`sequence-structs`. + + The :attr:`tp_as_sequence` field is not inherited, but the contained fields + are inherited individually. + + +.. cmember:: PyMappingMethods* tp_as_mapping + + Pointer to an additional structure that contains fields relevant only to + objects which implement the mapping protocol. These fields are documented in + :ref:`mapping-structs`. + + The :attr:`tp_as_mapping` field is not inherited, but the contained fields + are inherited individually. + + +.. cmember:: hashfunc PyTypeObject.tp_hash + + .. index:: builtin: hash + + An optional pointer to a function that implements the built-in function + :func:`hash`. + + The signature is the same as for :cfunc:`PyObject_Hash`; it must return a C + long. The value ``-1`` should not be returned as a normal return value; when an + error occurs during the computation of the hash value, the function should set + an exception and return ``-1``. + + When this field is not set, two possibilities exist: if the :attr:`tp_compare` + and :attr:`tp_richcompare` fields are both *NULL*, a default hash value based on + the object's address is returned; otherwise, a :exc:`TypeError` is raised. + + This field is inherited by subtypes together with :attr:`tp_richcompare` and + :attr:`tp_compare`: a subtypes inherits all three of :attr:`tp_compare`, + :attr:`tp_richcompare`, and :attr:`tp_hash`, when the subtype's + :attr:`tp_compare`, :attr:`tp_richcompare` and :attr:`tp_hash` are all *NULL*. + + +.. cmember:: ternaryfunc PyTypeObject.tp_call + + An optional pointer to a function that implements calling the object. This + should be *NULL* if the object is not callable. The signature is the same as + for :cfunc:`PyObject_Call`. + + This field is inherited by subtypes. + + +.. cmember:: reprfunc PyTypeObject.tp_str + + An optional pointer to a function that implements the built-in operation + :func:`str`. (Note that :class:`str` is a type now, and :func:`str` calls the + constructor for that type. This constructor calls :cfunc:`PyObject_Str` to do + the actual work, and :cfunc:`PyObject_Str` will call this handler.) + + The signature is the same as for :cfunc:`PyObject_Str`; it must return a string + or a Unicode object. This function should return a "friendly" string + representation of the object, as this is the representation that will be used by + the print statement. + + When this field is not set, :cfunc:`PyObject_Repr` is called to return a string + representation. + + This field is inherited by subtypes. + + +.. cmember:: getattrofunc PyTypeObject.tp_getattro + + An optional pointer to the get-attribute function. + + The signature is the same as for :cfunc:`PyObject_GetAttr`. It is usually + convenient to set this field to :cfunc:`PyObject_GenericGetAttr`, which + implements the normal way of looking for object attributes. + + This field is inherited by subtypes together with :attr:`tp_getattr`: a subtype + inherits both :attr:`tp_getattr` and :attr:`tp_getattro` from its base type when + the subtype's :attr:`tp_getattr` and :attr:`tp_getattro` are both *NULL*. + + +.. cmember:: setattrofunc PyTypeObject.tp_setattro + + An optional pointer to the set-attribute function. + + The signature is the same as for :cfunc:`PyObject_SetAttr`. It is usually + convenient to set this field to :cfunc:`PyObject_GenericSetAttr`, which + implements the normal way of setting object attributes. + + This field is inherited by subtypes together with :attr:`tp_setattr`: a subtype + inherits both :attr:`tp_setattr` and :attr:`tp_setattro` from its base type when + the subtype's :attr:`tp_setattr` and :attr:`tp_setattro` are both *NULL*. + + +.. cmember:: PyBufferProcs* PyTypeObject.tp_as_buffer + + Pointer to an additional structure that contains fields relevant only to objects + which implement the buffer interface. These fields are documented in + :ref:`buffer-structs`. + + The :attr:`tp_as_buffer` field is not inherited, but the contained fields are + inherited individually. + + +.. cmember:: long PyTypeObject.tp_flags + + This field is a bit mask of various flags. Some flags indicate variant + semantics for certain situations; others are used to indicate that certain + fields in the type object (or in the extension structures referenced via + :attr:`tp_as_number`, :attr:`tp_as_sequence`, :attr:`tp_as_mapping`, and + :attr:`tp_as_buffer`) that were historically not always present are valid; if + such a flag bit is clear, the type fields it guards must not be accessed and + must be considered to have a zero or *NULL* value instead. + + Inheritance of this field is complicated. Most flag bits are inherited + individually, i.e. if the base type has a flag bit set, the subtype inherits + this flag bit. The flag bits that pertain to extension structures are strictly + inherited if the extension structure is inherited, i.e. the base type's value of + the flag bit is copied into the subtype together with a pointer to the extension + structure. The :const:`Py_TPFLAGS_HAVE_GC` flag bit is inherited together with + the :attr:`tp_traverse` and :attr:`tp_clear` fields, i.e. if the + :const:`Py_TPFLAGS_HAVE_GC` flag bit is clear in the subtype and the + :attr:`tp_traverse` and :attr:`tp_clear` fields in the subtype exist (as + indicated by the :const:`Py_TPFLAGS_HAVE_RICHCOMPARE` flag bit) and have *NULL* + values. + + The following bit masks are currently defined; these can be ORed together using + the ``|`` operator to form the value of the :attr:`tp_flags` field. The macro + :cfunc:`PyType_HasFeature` takes a type and a flags value, *tp* and *f*, and + checks whether ``tp->tp_flags & f`` is non-zero. + + + .. data:: Py_TPFLAGS_HAVE_GETCHARBUFFER + + If this bit is set, the :ctype:`PyBufferProcs` struct referenced by + :attr:`tp_as_buffer` has the :attr:`bf_getcharbuffer` field. + + + .. data:: Py_TPFLAGS_HAVE_SEQUENCE_IN + + If this bit is set, the :ctype:`PySequenceMethods` struct referenced by + :attr:`tp_as_sequence` has the :attr:`sq_contains` field. + + + .. data:: Py_TPFLAGS_GC + + This bit is obsolete. The bit it used to name is no longer in use. The symbol + is now defined as zero. + + + .. data:: Py_TPFLAGS_HAVE_INPLACEOPS + + If this bit is set, the :ctype:`PySequenceMethods` struct referenced by + :attr:`tp_as_sequence` and the :ctype:`PyNumberMethods` structure referenced by + :attr:`tp_as_number` contain the fields for in-place operators. In particular, + this means that the :ctype:`PyNumberMethods` structure has the fields + :attr:`nb_inplace_add`, :attr:`nb_inplace_subtract`, + :attr:`nb_inplace_multiply`, :attr:`nb_inplace_divide`, + :attr:`nb_inplace_remainder`, :attr:`nb_inplace_power`, + :attr:`nb_inplace_lshift`, :attr:`nb_inplace_rshift`, :attr:`nb_inplace_and`, + :attr:`nb_inplace_xor`, and :attr:`nb_inplace_or`; and the + :ctype:`PySequenceMethods` struct has the fields :attr:`sq_inplace_concat` and + :attr:`sq_inplace_repeat`. + + + .. data:: Py_TPFLAGS_CHECKTYPES + + If this bit is set, the binary and ternary operations in the + :ctype:`PyNumberMethods` structure referenced by :attr:`tp_as_number` accept + arguments of arbitrary object types, and do their own type conversions if + needed. If this bit is clear, those operations require that all arguments have + the current type as their type, and the caller is supposed to perform a coercion + operation first. This applies to :attr:`nb_add`, :attr:`nb_subtract`, + :attr:`nb_multiply`, :attr:`nb_divide`, :attr:`nb_remainder`, :attr:`nb_divmod`, + :attr:`nb_power`, :attr:`nb_lshift`, :attr:`nb_rshift`, :attr:`nb_and`, + :attr:`nb_xor`, and :attr:`nb_or`. + + + .. data:: Py_TPFLAGS_HAVE_RICHCOMPARE + + If this bit is set, the type object has the :attr:`tp_richcompare` field, as + well as the :attr:`tp_traverse` and the :attr:`tp_clear` fields. + + + .. data:: Py_TPFLAGS_HAVE_WEAKREFS + + If this bit is set, the :attr:`tp_weaklistoffset` field is defined. Instances + of a type are weakly referenceable if the type's :attr:`tp_weaklistoffset` field + has a value greater than zero. + + + .. data:: Py_TPFLAGS_HAVE_ITER + + If this bit is set, the type object has the :attr:`tp_iter` and + :attr:`tp_iternext` fields. + + + .. data:: Py_TPFLAGS_HAVE_CLASS + + If this bit is set, the type object has several new fields defined starting in + Python 2.2: :attr:`tp_methods`, :attr:`tp_members`, :attr:`tp_getset`, + :attr:`tp_base`, :attr:`tp_dict`, :attr:`tp_descr_get`, :attr:`tp_descr_set`, + :attr:`tp_dictoffset`, :attr:`tp_init`, :attr:`tp_alloc`, :attr:`tp_new`, + :attr:`tp_free`, :attr:`tp_is_gc`, :attr:`tp_bases`, :attr:`tp_mro`, + :attr:`tp_cache`, :attr:`tp_subclasses`, and :attr:`tp_weaklist`. + + + .. data:: Py_TPFLAGS_HEAPTYPE + + This bit is set when the type object itself is allocated on the heap. In this + case, the :attr:`ob_type` field of its instances is considered a reference to + the type, and the type object is INCREF'ed when a new instance is created, and + DECREF'ed when an instance is destroyed (this does not apply to instances of + subtypes; only the type referenced by the instance's ob_type gets INCREF'ed or + DECREF'ed). + + + .. data:: Py_TPFLAGS_BASETYPE + + This bit is set when the type can be used as the base type of another type. If + this bit is clear, the type cannot be subtyped (similar to a "final" class in + Java). + + + .. data:: Py_TPFLAGS_READY + + This bit is set when the type object has been fully initialized by + :cfunc:`PyType_Ready`. + + + .. data:: Py_TPFLAGS_READYING + + This bit is set while :cfunc:`PyType_Ready` is in the process of initializing + the type object. + + + .. data:: Py_TPFLAGS_HAVE_GC + + This bit is set when the object supports garbage collection. If this bit + is set, instances must be created using :cfunc:`PyObject_GC_New` and + destroyed using :cfunc:`PyObject_GC_Del`. More information in section + :ref:`supporting-cycle-detection`. This bit also implies that the + GC-related fields :attr:`tp_traverse` and :attr:`tp_clear` are present in + the type object; but those fields also exist when + :const:`Py_TPFLAGS_HAVE_GC` is clear but + :const:`Py_TPFLAGS_HAVE_RICHCOMPARE` is set. + + + .. data:: Py_TPFLAGS_DEFAULT + + This is a bitmask of all the bits that pertain to the existence of certain + fields in the type object and its extension structures. Currently, it includes + the following bits: :const:`Py_TPFLAGS_HAVE_GETCHARBUFFER`, + :const:`Py_TPFLAGS_HAVE_SEQUENCE_IN`, :const:`Py_TPFLAGS_HAVE_INPLACEOPS`, + :const:`Py_TPFLAGS_HAVE_RICHCOMPARE`, :const:`Py_TPFLAGS_HAVE_WEAKREFS`, + :const:`Py_TPFLAGS_HAVE_ITER`, and :const:`Py_TPFLAGS_HAVE_CLASS`. + + +.. cmember:: char* PyTypeObject.tp_doc + + An optional pointer to a NUL-terminated C string giving the docstring for this + type object. This is exposed as the :attr:`__doc__` attribute on the type and + instances of the type. + + This field is *not* inherited by subtypes. + +The following three fields only exist if the +:const:`Py_TPFLAGS_HAVE_RICHCOMPARE` flag bit is set. + + +.. cmember:: traverseproc PyTypeObject.tp_traverse + + An optional pointer to a traversal function for the garbage collector. This is + only used if the :const:`Py_TPFLAGS_HAVE_GC` flag bit is set. More information + about Python's garbage collection scheme can be found in section + :ref:`supporting-cycle-detection`. + + The :attr:`tp_traverse` pointer is used by the garbage collector to detect + reference cycles. A typical implementation of a :attr:`tp_traverse` function + simply calls :cfunc:`Py_VISIT` on each of the instance's members that are Python + objects. For exampe, this is function :cfunc:`local_traverse` from the + :mod:`thread` extension module:: + + static int + local_traverse(localobject *self, visitproc visit, void *arg) + { + Py_VISIT(self->args); + Py_VISIT(self->kw); + Py_VISIT(self->dict); + return 0; + } + + Note that :cfunc:`Py_VISIT` is called only on those members that can participate + in reference cycles. Although there is also a ``self->key`` member, it can only + be *NULL* or a Python string and therefore cannot be part of a reference cycle. + + On the other hand, even if you know a member can never be part of a cycle, as a + debugging aid you may want to visit it anyway just so the :mod:`gc` module's + :func:`get_referents` function will include it. + + Note that :cfunc:`Py_VISIT` requires the *visit* and *arg* parameters to + :cfunc:`local_traverse` to have these specific names; don't name them just + anything. + + This field is inherited by subtypes together with :attr:`tp_clear` and the + :const:`Py_TPFLAGS_HAVE_GC` flag bit: the flag bit, :attr:`tp_traverse`, and + :attr:`tp_clear` are all inherited from the base type if they are all zero in + the subtype *and* the subtype has the :const:`Py_TPFLAGS_HAVE_RICHCOMPARE` flag + bit set. + + +.. cmember:: inquiry PyTypeObject.tp_clear + + An optional pointer to a clear function for the garbage collector. This is only + used if the :const:`Py_TPFLAGS_HAVE_GC` flag bit is set. + + The :attr:`tp_clear` member function is used to break reference cycles in cyclic + garbage detected by the garbage collector. Taken together, all :attr:`tp_clear` + functions in the system must combine to break all reference cycles. This is + subtle, and if in any doubt supply a :attr:`tp_clear` function. For example, + the tuple type does not implement a :attr:`tp_clear` function, because it's + possible to prove that no reference cycle can be composed entirely of tuples. + Therefore the :attr:`tp_clear` functions of other types must be sufficient to + break any cycle containing a tuple. This isn't immediately obvious, and there's + rarely a good reason to avoid implementing :attr:`tp_clear`. + + Implementations of :attr:`tp_clear` should drop the instance's references to + those of its members that may be Python objects, and set its pointers to those + members to *NULL*, as in the following example:: + + static int + local_clear(localobject *self) + { + Py_CLEAR(self->key); + Py_CLEAR(self->args); + Py_CLEAR(self->kw); + Py_CLEAR(self->dict); + return 0; + } + + The :cfunc:`Py_CLEAR` macro should be used, because clearing references is + delicate: the reference to the contained object must not be decremented until + after the pointer to the contained object is set to *NULL*. This is because + decrementing the reference count may cause the contained object to become trash, + triggering a chain of reclamation activity that may include invoking arbitrary + Python code (due to finalizers, or weakref callbacks, associated with the + contained object). If it's possible for such code to reference *self* again, + it's important that the pointer to the contained object be *NULL* at that time, + so that *self* knows the contained object can no longer be used. The + :cfunc:`Py_CLEAR` macro performs the operations in a safe order. + + Because the goal of :attr:`tp_clear` functions is to break reference cycles, + it's not necessary to clear contained objects like Python strings or Python + integers, which can't participate in reference cycles. On the other hand, it may + be convenient to clear all contained Python objects, and write the type's + :attr:`tp_dealloc` function to invoke :attr:`tp_clear`. + + More information about Python's garbage collection scheme can be found in + section :ref:`supporting-cycle-detection`. + + This field is inherited by subtypes together with :attr:`tp_traverse` and the + :const:`Py_TPFLAGS_HAVE_GC` flag bit: the flag bit, :attr:`tp_traverse`, and + :attr:`tp_clear` are all inherited from the base type if they are all zero in + the subtype *and* the subtype has the :const:`Py_TPFLAGS_HAVE_RICHCOMPARE` flag + bit set. + + +.. cmember:: richcmpfunc PyTypeObject.tp_richcompare + + An optional pointer to the rich comparison function. + + The signature is the same as for :cfunc:`PyObject_RichCompare`. The function + should return the result of the comparison (usually ``Py_True`` or + ``Py_False``). If the comparison is undefined, it must return + ``Py_NotImplemented``, if another error occurred it must return ``NULL`` and set + an exception condition. + + This field is inherited by subtypes together with :attr:`tp_compare` and + :attr:`tp_hash`: a subtype inherits all three of :attr:`tp_compare`, + :attr:`tp_richcompare`, and :attr:`tp_hash`, when the subtype's + :attr:`tp_compare`, :attr:`tp_richcompare`, and :attr:`tp_hash` are all *NULL*. + + The following constants are defined to be used as the third argument for + :attr:`tp_richcompare` and for :cfunc:`PyObject_RichCompare`: + + +----------------+------------+ + | Constant | Comparison | + +================+============+ + | :const:`Py_LT` | ``<`` | + +----------------+------------+ + | :const:`Py_LE` | ``<=`` | + +----------------+------------+ + | :const:`Py_EQ` | ``==`` | + +----------------+------------+ + | :const:`Py_NE` | ``!=`` | + +----------------+------------+ + | :const:`Py_GT` | ``>`` | + +----------------+------------+ + | :const:`Py_GE` | ``>=`` | + +----------------+------------+ + +The next field only exists if the :const:`Py_TPFLAGS_HAVE_WEAKREFS` flag bit is +set. + + +.. cmember:: long PyTypeObject.tp_weaklistoffset + + If the instances of this type are weakly referenceable, this field is greater + than zero and contains the offset in the instance structure of the weak + reference list head (ignoring the GC header, if present); this offset is used by + :cfunc:`PyObject_ClearWeakRefs` and the :cfunc:`PyWeakref_\*` functions. The + instance structure needs to include a field of type :ctype:`PyObject\*` which is + initialized to *NULL*. + + Do not confuse this field with :attr:`tp_weaklist`; that is the list head for + weak references to the type object itself. + + This field is inherited by subtypes, but see the rules listed below. A subtype + may override this offset; this means that the subtype uses a different weak + reference list head than the base type. Since the list head is always found via + :attr:`tp_weaklistoffset`, this should not be a problem. + + When a type defined by a class statement has no :attr:`__slots__` declaration, + and none of its base types are weakly referenceable, the type is made weakly + referenceable by adding a weak reference list head slot to the instance layout + and setting the :attr:`tp_weaklistoffset` of that slot's offset. + + When a type's :attr:`__slots__` declaration contains a slot named + :attr:`__weakref__`, that slot becomes the weak reference list head for + instances of the type, and the slot's offset is stored in the type's + :attr:`tp_weaklistoffset`. + + When a type's :attr:`__slots__` declaration does not contain a slot named + :attr:`__weakref__`, the type inherits its :attr:`tp_weaklistoffset` from its + base type. + +The next two fields only exist if the :const:`Py_TPFLAGS_HAVE_CLASS` flag bit is +set. + + +.. cmember:: getiterfunc PyTypeObject.tp_iter + + An optional pointer to a function that returns an iterator for the object. Its + presence normally signals that the instances of this type are iterable (although + sequences may be iterable without this function, and classic instances always + have this function, even if they don't define an :meth:`__iter__` method). + + This function has the same signature as :cfunc:`PyObject_GetIter`. + + This field is inherited by subtypes. + + +.. cmember:: iternextfunc PyTypeObject.tp_iternext + + An optional pointer to a function that returns the next item in an iterator, or + raises :exc:`StopIteration` when the iterator is exhausted. Its presence + normally signals that the instances of this type are iterators (although classic + instances always have this function, even if they don't define a :meth:`next` + method). + + Iterator types should also define the :attr:`tp_iter` function, and that + function should return the iterator instance itself (not a new iterator + instance). + + This function has the same signature as :cfunc:`PyIter_Next`. + + This field is inherited by subtypes. + +The next fields, up to and including :attr:`tp_weaklist`, only exist if the +:const:`Py_TPFLAGS_HAVE_CLASS` flag bit is set. + + +.. cmember:: struct PyMethodDef* PyTypeObject.tp_methods + + An optional pointer to a static *NULL*-terminated array of :ctype:`PyMethodDef` + structures, declaring regular methods of this type. + + For each entry in the array, an entry is added to the type's dictionary (see + :attr:`tp_dict` below) containing a method descriptor. + + This field is not inherited by subtypes (methods are inherited through a + different mechanism). + + +.. cmember:: struct PyMemberDef* PyTypeObject.tp_members + + An optional pointer to a static *NULL*-terminated array of :ctype:`PyMemberDef` + structures, declaring regular data members (fields or slots) of instances of + this type. + + For each entry in the array, an entry is added to the type's dictionary (see + :attr:`tp_dict` below) containing a member descriptor. + + This field is not inherited by subtypes (members are inherited through a + different mechanism). + + +.. cmember:: struct PyGetSetDef* PyTypeObject.tp_getset + + An optional pointer to a static *NULL*-terminated array of :ctype:`PyGetSetDef` + structures, declaring computed attributes of instances of this type. + + For each entry in the array, an entry is added to the type's dictionary (see + :attr:`tp_dict` below) containing a getset descriptor. + + This field is not inherited by subtypes (computed attributes are inherited + through a different mechanism). + + Docs for PyGetSetDef (XXX belong elsewhere):: + + typedef PyObject *(*getter)(PyObject *, void *); + typedef int (*setter)(PyObject *, PyObject *, void *); + + typedef struct PyGetSetDef { + char *name; /* attribute name */ + getter get; /* C function to get the attribute */ + setter set; /* C function to set the attribute */ + char *doc; /* optional doc string */ + void *closure; /* optional additional data for getter and setter */ + } PyGetSetDef; + + +.. cmember:: PyTypeObject* PyTypeObject.tp_base + + An optional pointer to a base type from which type properties are inherited. At + this level, only single inheritance is supported; multiple inheritance require + dynamically creating a type object by calling the metatype. + + This field is not inherited by subtypes (obviously), but it defaults to + ``&PyBaseObject_Type`` (which to Python programmers is known as the type + :class:`object`). + + +.. cmember:: PyObject* PyTypeObject.tp_dict + + The type's dictionary is stored here by :cfunc:`PyType_Ready`. + + This field should normally be initialized to *NULL* before PyType_Ready is + called; it may also be initialized to a dictionary containing initial attributes + for the type. Once :cfunc:`PyType_Ready` has initialized the type, extra + attributes for the type may be added to this dictionary only if they don't + correspond to overloaded operations (like :meth:`__add__`). + + This field is not inherited by subtypes (though the attributes defined in here + are inherited through a different mechanism). + + +.. cmember:: descrgetfunc PyTypeObject.tp_descr_get + + An optional pointer to a "descriptor get" function. + + The function signature is :: + + PyObject * tp_descr_get(PyObject *self, PyObject *obj, PyObject *type); + + XXX explain. + + This field is inherited by subtypes. + + +.. cmember:: descrsetfunc PyTypeObject.tp_descr_set + + An optional pointer to a "descriptor set" function. + + The function signature is :: + + int tp_descr_set(PyObject *self, PyObject *obj, PyObject *value); + + This field is inherited by subtypes. + + XXX explain. + + +.. cmember:: long PyTypeObject.tp_dictoffset + + If the instances of this type have a dictionary containing instance variables, + this field is non-zero and contains the offset in the instances of the type of + the instance variable dictionary; this offset is used by + :cfunc:`PyObject_GenericGetAttr`. + + Do not confuse this field with :attr:`tp_dict`; that is the dictionary for + attributes of the type object itself. + + If the value of this field is greater than zero, it specifies the offset from + the start of the instance structure. If the value is less than zero, it + specifies the offset from the *end* of the instance structure. A negative + offset is more expensive to use, and should only be used when the instance + structure contains a variable-length part. This is used for example to add an + instance variable dictionary to subtypes of :class:`str` or :class:`tuple`. Note + that the :attr:`tp_basicsize` field should account for the dictionary added to + the end in that case, even though the dictionary is not included in the basic + object layout. On a system with a pointer size of 4 bytes, + :attr:`tp_dictoffset` should be set to ``-4`` to indicate that the dictionary is + at the very end of the structure. + + The real dictionary offset in an instance can be computed from a negative + :attr:`tp_dictoffset` as follows:: + + dictoffset = tp_basicsize + abs(ob_size)*tp_itemsize + tp_dictoffset + if dictoffset is not aligned on sizeof(void*): + round up to sizeof(void*) + + where :attr:`tp_basicsize`, :attr:`tp_itemsize` and :attr:`tp_dictoffset` are + taken from the type object, and :attr:`ob_size` is taken from the instance. The + absolute value is taken because long ints use the sign of :attr:`ob_size` to + store the sign of the number. (There's never a need to do this calculation + yourself; it is done for you by :cfunc:`_PyObject_GetDictPtr`.) + + This field is inherited by subtypes, but see the rules listed below. A subtype + may override this offset; this means that the subtype instances store the + dictionary at a difference offset than the base type. Since the dictionary is + always found via :attr:`tp_dictoffset`, this should not be a problem. + + When a type defined by a class statement has no :attr:`__slots__` declaration, + and none of its base types has an instance variable dictionary, a dictionary + slot is added to the instance layout and the :attr:`tp_dictoffset` is set to + that slot's offset. + + When a type defined by a class statement has a :attr:`__slots__` declaration, + the type inherits its :attr:`tp_dictoffset` from its base type. + + (Adding a slot named :attr:`__dict__` to the :attr:`__slots__` declaration does + not have the expected effect, it just causes confusion. Maybe this should be + added as a feature just like :attr:`__weakref__` though.) + + +.. cmember:: initproc PyTypeObject.tp_init + + An optional pointer to an instance initialization function. + + This function corresponds to the :meth:`__init__` method of classes. Like + :meth:`__init__`, it is possible to create an instance without calling + :meth:`__init__`, and it is possible to reinitialize an instance by calling its + :meth:`__init__` method again. + + The function signature is :: + + int tp_init(PyObject *self, PyObject *args, PyObject *kwds) + + The self argument is the instance to be initialized; the *args* and *kwds* + arguments represent positional and keyword arguments of the call to + :meth:`__init__`. + + The :attr:`tp_init` function, if not *NULL*, is called when an instance is + created normally by calling its type, after the type's :attr:`tp_new` function + has returned an instance of the type. If the :attr:`tp_new` function returns an + instance of some other type that is not a subtype of the original type, no + :attr:`tp_init` function is called; if :attr:`tp_new` returns an instance of a + subtype of the original type, the subtype's :attr:`tp_init` is called. (VERSION + NOTE: described here is what is implemented in Python 2.2.1 and later. In + Python 2.2, the :attr:`tp_init` of the type of the object returned by + :attr:`tp_new` was always called, if not *NULL*.) + + This field is inherited by subtypes. + + +.. cmember:: allocfunc PyTypeObject.tp_alloc + + An optional pointer to an instance allocation function. + + The function signature is :: + + PyObject *tp_alloc(PyTypeObject *self, Py_ssize_t nitems) + + The purpose of this function is to separate memory allocation from memory + initialization. It should return a pointer to a block of memory of adequate + length for the instance, suitably aligned, and initialized to zeros, but with + :attr:`ob_refcnt` set to ``1`` and :attr:`ob_type` set to the type argument. If + the type's :attr:`tp_itemsize` is non-zero, the object's :attr:`ob_size` field + should be initialized to *nitems* and the length of the allocated memory block + should be ``tp_basicsize + nitems*tp_itemsize``, rounded up to a multiple of + ``sizeof(void*)``; otherwise, *nitems* is not used and the length of the block + should be :attr:`tp_basicsize`. + + Do not use this function to do any other instance initialization, not even to + allocate additional memory; that should be done by :attr:`tp_new`. + + This field is inherited by static subtypes, but not by dynamic subtypes + (subtypes created by a class statement); in the latter, this field is always set + to :cfunc:`PyType_GenericAlloc`, to force a standard heap allocation strategy. + That is also the recommended value for statically defined types. + + +.. cmember:: newfunc PyTypeObject.tp_new + + An optional pointer to an instance creation function. + + If this function is *NULL* for a particular type, that type cannot be called to + create new instances; presumably there is some other way to create instances, + like a factory function. + + The function signature is :: + + PyObject *tp_new(PyTypeObject *subtype, PyObject *args, PyObject *kwds) + + The subtype argument is the type of the object being created; the *args* and + *kwds* arguments represent positional and keyword arguments of the call to the + type. Note that subtype doesn't have to equal the type whose :attr:`tp_new` + function is called; it may be a subtype of that type (but not an unrelated + type). + + The :attr:`tp_new` function should call ``subtype->tp_alloc(subtype, nitems)`` + to allocate space for the object, and then do only as much further + initialization as is absolutely necessary. Initialization that can safely be + ignored or repeated should be placed in the :attr:`tp_init` handler. A good + rule of thumb is that for immutable types, all initialization should take place + in :attr:`tp_new`, while for mutable types, most initialization should be + deferred to :attr:`tp_init`. + + This field is inherited by subtypes, except it is not inherited by static types + whose :attr:`tp_base` is *NULL* or ``&PyBaseObject_Type``. The latter exception + is a precaution so that old extension types don't become callable simply by + being linked with Python 2.2. + + +.. cmember:: destructor PyTypeObject.tp_free + + An optional pointer to an instance deallocation function. + + The signature of this function has changed slightly: in Python 2.2 and 2.2.1, + its signature is :ctype:`destructor`:: + + void tp_free(PyObject *) + + In Python 2.3 and beyond, its signature is :ctype:`freefunc`:: + + void tp_free(void *) + + The only initializer that is compatible with both versions is ``_PyObject_Del``, + whose definition has suitably adapted in Python 2.3. + + This field is inherited by static subtypes, but not by dynamic subtypes + (subtypes created by a class statement); in the latter, this field is set to a + deallocator suitable to match :cfunc:`PyType_GenericAlloc` and the value of the + :const:`Py_TPFLAGS_HAVE_GC` flag bit. + + +.. cmember:: inquiry PyTypeObject.tp_is_gc + + An optional pointer to a function called by the garbage collector. + + The garbage collector needs to know whether a particular object is collectible + or not. Normally, it is sufficient to look at the object's type's + :attr:`tp_flags` field, and check the :const:`Py_TPFLAGS_HAVE_GC` flag bit. But + some types have a mixture of statically and dynamically allocated instances, and + the statically allocated instances are not collectible. Such types should + define this function; it should return ``1`` for a collectible instance, and + ``0`` for a non-collectible instance. The signature is :: + + int tp_is_gc(PyObject *self) + + (The only example of this are types themselves. The metatype, + :cdata:`PyType_Type`, defines this function to distinguish between statically + and dynamically allocated types.) + + This field is inherited by subtypes. (VERSION NOTE: in Python 2.2, it was not + inherited. It is inherited in 2.2.1 and later versions.) + + +.. cmember:: PyObject* PyTypeObject.tp_bases + + Tuple of base types. + + This is set for types created by a class statement. It should be *NULL* for + statically defined types. + + This field is not inherited. + + +.. cmember:: PyObject* PyTypeObject.tp_mro + + Tuple containing the expanded set of base types, starting with the type itself + and ending with :class:`object`, in Method Resolution Order. + + This field is not inherited; it is calculated fresh by :cfunc:`PyType_Ready`. + + +.. cmember:: PyObject* PyTypeObject.tp_cache + + Unused. Not inherited. Internal use only. + + +.. cmember:: PyObject* PyTypeObject.tp_subclasses + + List of weak references to subclasses. Not inherited. Internal use only. + + +.. cmember:: PyObject* PyTypeObject.tp_weaklist + + Weak reference list head, for weak references to this type object. Not + inherited. Internal use only. + +The remaining fields are only defined if the feature test macro +:const:`COUNT_ALLOCS` is defined, and are for internal use only. They are +documented here for completeness. None of these fields are inherited by +subtypes. + + +.. cmember:: Py_ssize_t PyTypeObject.tp_allocs + + Number of allocations. + + +.. cmember:: Py_ssize_t PyTypeObject.tp_frees + + Number of frees. + + +.. cmember:: Py_ssize_t PyTypeObject.tp_maxalloc + + Maximum simultaneously allocated objects. + + +.. cmember:: PyTypeObject* PyTypeObject.tp_next + + Pointer to the next type object with a non-zero :attr:`tp_allocs` field. + +Also, note that, in a garbage collected Python, tp_dealloc may be called from +any Python thread, not just the thread which created the object (if the object +becomes part of a refcount cycle, that cycle might be collected by a garbage +collection on any thread). This is not a problem for Python API calls, since +the thread on which tp_dealloc is called will own the Global Interpreter Lock +(GIL). However, if the object being destroyed in turn destroys objects from some +other C or C++ library, care should be taken to ensure that destroying those +objects on the thread which called tp_dealloc will not violate any assumptions +of the library. + + +.. _number-structs: + +Number Object Structures +======================== + +.. sectionauthor:: Amaury Forgeot d'Arc + + +.. ctype:: PyNumberMethods + + This structure holds pointers to the functions which an object uses to + implement the number protocol. Almost every function below is used by the + function of similar name documented in the :ref:`number` section. + + Here is the structure definition:: + + typedef struct { + binaryfunc nb_add; + binaryfunc nb_subtract; + binaryfunc nb_multiply; + binaryfunc nb_remainder; + binaryfunc nb_divmod; + ternaryfunc nb_power; + unaryfunc nb_negative; + unaryfunc nb_positive; + unaryfunc nb_absolute; + inquiry nb_nonzero; /* Used by PyObject_IsTrue */ + unaryfunc nb_invert; + binaryfunc nb_lshift; + binaryfunc nb_rshift; + binaryfunc nb_and; + binaryfunc nb_xor; + binaryfunc nb_or; + coercion nb_coerce; /* Used by the coerce() funtion */ + unaryfunc nb_int; + unaryfunc nb_long; + unaryfunc nb_float; + unaryfunc nb_oct; + unaryfunc nb_hex; + + /* Added in release 2.0 */ + binaryfunc nb_inplace_add; + binaryfunc nb_inplace_subtract; + binaryfunc nb_inplace_multiply; + binaryfunc nb_inplace_remainder; + ternaryfunc nb_inplace_power; + binaryfunc nb_inplace_lshift; + binaryfunc nb_inplace_rshift; + binaryfunc nb_inplace_and; + binaryfunc nb_inplace_xor; + binaryfunc nb_inplace_or; + + /* Added in release 2.2 */ + binaryfunc nb_floor_divide; + binaryfunc nb_true_divide; + binaryfunc nb_inplace_floor_divide; + binaryfunc nb_inplace_true_divide; + + /* Added in release 2.5 */ + unaryfunc nb_index; + } PyNumberMethods; + + +Binary and ternary functions may receive different kinds of arguments, depending +on the flag bit :const:`Py_TPFLAGS_CHECKTYPES`: + +- If :const:`Py_TPFLAGS_CHECKTYPES` is not set, the function arguments are + guaranteed to be of the object's type; the caller is responsible for calling + the coercion method specified by the :attr:`nb_coerce` member to convert the + arguments: + + .. cmember:: coercion PyNumberMethods.nb_coerce + + This function is used by :cfunc:`PyNumber_CoerceEx` and has the same + signature. The first argument is always a pointer to an object of the + defined type. If the conversion to a common "larger" type is possible, the + function replaces the pointers with new references to the converted objects + and returns ``0``. If the conversion is not possible, the function returns + ``1``. If an error condition is set, it will return ``-1``. + +- If the :const:`Py_TPFLAGS_CHECKTYPES` flag is set, binary and ternary + functions must check the type of all their operands, and implement the + necessary conversions (at least one of the operands is an instance of the + defined type). This is the recommended way; with Python 3.0 coercion will + disappear completely. + +If the operation is not defined for the given operands, binary and ternary +functions must return ``Py_NotImplemented``, if another error occurred they must +return ``NULL`` and set an exception. + + +.. _mapping-structs: + +Mapping Object Structures +========================= + +.. sectionauthor:: Amaury Forgeot d'Arc + + +.. ctype:: PyMappingMethods + + This structure holds pointers to the functions which an object uses to + implement the mapping protocol. It has three members: + +.. cmember:: lenfunc PyMappingMethods.mp_length + + This function is used by :cfunc:`PyMapping_Length` and + :cfunc:`PyObject_Size`, and has the same signature. This slot may be set to + *NULL* if the object has no defined length. + +.. cmember:: binaryfunc PyMappingMethods.mp_subscript + + This function is used by :cfunc:`PyObject_GetItem` and has the same + signature. This slot must be filled for the :cfunc:`PyMapping_Check` + function to return ``1``, it can be *NULL* otherwise. + +.. cmember:: objobjargproc PyMappingMethods.mp_ass_subscript + + This function is used by :cfunc:`PyObject_SetItem` and has the same + signature. If this slot is *NULL*, the object does not support item + assignment. + + +.. _sequence-structs: + +Sequence Object Structures +========================== + +.. sectionauthor:: Amaury Forgeot d'Arc + + +.. ctype:: PySequenceMethods + + This structure holds pointers to the functions which an object uses to + implement the sequence protocol. + +.. cmember:: lenfunc PySequenceMethods.sq_length + + This function is used by :cfunc:`PySequence_Size` and :cfunc:`PyObject_Size`, + and has the same signature. + +.. cmember:: binaryfunc PySequenceMethods.sq_concat + + This function is used by :cfunc:`PySequence_Concat` and has the same + signature. It is also used by the ``+`` operator, after trying the numeric + addition via the :attr:`tp_as_number.nb_add` slot. + +.. cmember:: ssizeargfunc PySequenceMethods.sq_repeat + + This function is used by :cfunc:`PySequence_Repeat` and has the same + signature. It is also used by the ``*`` operator, after trying numeric + multiplication via the :attr:`tp_as_number.nb_mul` slot. + +.. cmember:: ssizeargfunc PySequenceMethods.sq_item + + This function is used by :cfunc:`PySequence_GetItem` and has the same + signature. This slot must be filled for the :cfunc:`PySequence_Check` + function to return ``1``, it can be *NULL* otherwise. + + Negative indexes are handled as follows: if the :attr:`sq_length` slot is + filled, it is called and the sequence length is used to compute a positive + index which is passed to :attr:`sq_item`. If :attr:`sq_length` is *NULL*, + the index is passed as is to the function. + +.. cmember:: ssizeobjargproc PySequenceMethods.sq_ass_item + + This function is used by :cfunc:`PySequence_SetItem` and has the same + signature. This slot may be left to *NULL* if the object does not support + item assignment. + +.. cmember:: objobjproc PySequenceMethods.sq_contains + + This function may be used by :cfunc:`PySequence_Contains` and has the same + signature. This slot may be left to *NULL*, in this case + :cfunc:`PySequence_Contains` simply traverses the sequence until it finds a + match. + +.. cmember:: binaryfunc PySequenceMethods.sq_inplace_concat + + This function is used by :cfunc:`PySequence_InPlaceConcat` and has the same + signature. It should modify its first operand, and return it. + +.. cmember:: ssizeargfunc PySequenceMethods.sq_inplace_repeat + + This function is used by :cfunc:`PySequence_InPlaceRepeat` and has the same + signature. It should modify its first operand, and return it. + +.. XXX need to explain precedence between mapping and sequence +.. XXX explains when to implement the sq_inplace_* slots + + +.. _buffer-structs: + +Buffer Object Structures +======================== + +.. sectionauthor:: Greg J. Stein + + +The buffer interface exports a model where an object can expose its internal +data as a set of chunks of data, where each chunk is specified as a +pointer/length pair. These chunks are called :dfn:`segments` and are presumed +to be non-contiguous in memory. + +If an object does not export the buffer interface, then its :attr:`tp_as_buffer` +member in the :ctype:`PyTypeObject` structure should be *NULL*. Otherwise, the +:attr:`tp_as_buffer` will point to a :ctype:`PyBufferProcs` structure. + +.. note:: + + It is very important that your :ctype:`PyTypeObject` structure uses + :const:`Py_TPFLAGS_DEFAULT` for the value of the :attr:`tp_flags` member rather + than ``0``. This tells the Python runtime that your :ctype:`PyBufferProcs` + structure contains the :attr:`bf_getcharbuffer` slot. Older versions of Python + did not have this member, so a new Python interpreter using an old extension + needs to be able to test for its presence before using it. + + +.. ctype:: PyBufferProcs + + Structure used to hold the function pointers which define an implementation of + the buffer protocol. + + The first slot is :attr:`bf_getreadbuffer`, of type :ctype:`getreadbufferproc`. + If this slot is *NULL*, then the object does not support reading from the + internal data. This is non-sensical, so implementors should fill this in, but + callers should test that the slot contains a non-*NULL* value. + + The next slot is :attr:`bf_getwritebuffer` having type + :ctype:`getwritebufferproc`. This slot may be *NULL* if the object does not + allow writing into its returned buffers. + + The third slot is :attr:`bf_getsegcount`, with type :ctype:`getsegcountproc`. + This slot must not be *NULL* and is used to inform the caller how many segments + the object contains. Simple objects such as :ctype:`PyString_Type` and + :ctype:`PyBuffer_Type` objects contain a single segment. + + .. index:: single: PyType_HasFeature() + + The last slot is :attr:`bf_getcharbuffer`, of type :ctype:`getcharbufferproc`. + This slot will only be present if the :const:`Py_TPFLAGS_HAVE_GETCHARBUFFER` + flag is present in the :attr:`tp_flags` field of the object's + :ctype:`PyTypeObject`. Before using this slot, the caller should test whether it + is present by using the :cfunc:`PyType_HasFeature` function. If the flag is + present, :attr:`bf_getcharbuffer` may be *NULL*, indicating that the object's + contents cannot be used as *8-bit characters*. The slot function may also raise + an error if the object's contents cannot be interpreted as 8-bit characters. + For example, if the object is an array which is configured to hold floating + point values, an exception may be raised if a caller attempts to use + :attr:`bf_getcharbuffer` to fetch a sequence of 8-bit characters. This notion of + exporting the internal buffers as "text" is used to distinguish between objects + that are binary in nature, and those which have character-based content. + + .. note:: + + The current policy seems to state that these characters may be multi-byte + characters. This implies that a buffer size of *N* does not mean there are *N* + characters present. + + +.. data:: Py_TPFLAGS_HAVE_GETCHARBUFFER + + Flag bit set in the type structure to indicate that the :attr:`bf_getcharbuffer` + slot is known. This being set does not indicate that the object supports the + buffer interface or that the :attr:`bf_getcharbuffer` slot is non-*NULL*. + + +.. ctype:: Py_ssize_t (*readbufferproc) (PyObject *self, Py_ssize_t segment, void **ptrptr) + + Return a pointer to a readable segment of the buffer in ``*ptrptr``. This + function is allowed to raise an exception, in which case it must return ``-1``. + The *segment* which is specified must be zero or positive, and strictly less + than the number of segments returned by the :attr:`bf_getsegcount` slot + function. On success, it returns the length of the segment, and sets + ``*ptrptr`` to a pointer to that memory. + + +.. ctype:: Py_ssize_t (*writebufferproc) (PyObject *self, Py_ssize_t segment, void **ptrptr) + + Return a pointer to a writable memory buffer in ``*ptrptr``, and the length of + that segment as the function return value. The memory buffer must correspond to + buffer segment *segment*. Must return ``-1`` and set an exception on error. + :exc:`TypeError` should be raised if the object only supports read-only buffers, + and :exc:`SystemError` should be raised when *segment* specifies a segment that + doesn't exist. + + .. Why doesn't it raise ValueError for this one? + GJS: because you shouldn't be calling it with an invalid + segment. That indicates a blatant programming error in the C code. + + +.. ctype:: Py_ssize_t (*segcountproc) (PyObject *self, Py_ssize_t *lenp) + + Return the number of memory segments which comprise the buffer. If *lenp* is + not *NULL*, the implementation must report the sum of the sizes (in bytes) of + all segments in ``*lenp``. The function cannot fail. + + +.. ctype:: Py_ssize_t (*charbufferproc) (PyObject *self, Py_ssize_t segment, const char **ptrptr) + + Return the size of the segment *segment* that *ptrptr* is set to. ``*ptrptr`` + is set to the memory buffer. Returns ``-1`` on error. Added: python/trunk/Doc/c-api/unicode.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/c-api/unicode.rst Sat Jan 19 23:08:21 2008 @@ -0,0 +1,804 @@ +.. highlightlang:: c + +.. _unicodeobjects: + +Unicode Objects and Codecs +-------------------------- + +.. sectionauthor:: Marc-Andre Lemburg + +Unicode Objects +^^^^^^^^^^^^^^^ + + +These are the basic Unicode object types used for the Unicode implementation in +Python: + +.. % --- Unicode Type ------------------------------------------------------- + + +.. ctype:: Py_UNICODE + + This type represents the storage type which is used by Python internally as + basis for holding Unicode ordinals. Python's default builds use a 16-bit type + for :ctype:`Py_UNICODE` and store Unicode values internally as UCS2. It is also + possible to build a UCS4 version of Python (most recent Linux distributions come + with UCS4 builds of Python). These builds then use a 32-bit type for + :ctype:`Py_UNICODE` and store Unicode data internally as UCS4. On platforms + where :ctype:`wchar_t` is available and compatible with the chosen Python + Unicode build variant, :ctype:`Py_UNICODE` is a typedef alias for + :ctype:`wchar_t` to enhance native platform compatibility. On all other + platforms, :ctype:`Py_UNICODE` is a typedef alias for either :ctype:`unsigned + short` (UCS2) or :ctype:`unsigned long` (UCS4). + +Note that UCS2 and UCS4 Python builds are not binary compatible. Please keep +this in mind when writing extensions or interfaces. + + +.. ctype:: PyUnicodeObject + + This subtype of :ctype:`PyObject` represents a Python Unicode object. + + +.. cvar:: PyTypeObject PyUnicode_Type + + This instance of :ctype:`PyTypeObject` represents the Python Unicode type. It + is exposed to Python code as ``unicode`` and ``types.UnicodeType``. + +The following APIs are really C macros and can be used to do fast checks and to +access internal read-only data of Unicode objects: + + +.. cfunction:: int PyUnicode_Check(PyObject *o) + + Return true if the object *o* is a Unicode object or an instance of a Unicode + subtype. + + .. versionchanged:: 2.2 + Allowed subtypes to be accepted. + + +.. cfunction:: int PyUnicode_CheckExact(PyObject *o) + + Return true if the object *o* is a Unicode object, but not an instance of a + subtype. + + .. versionadded:: 2.2 + + +.. cfunction:: Py_ssize_t PyUnicode_GET_SIZE(PyObject *o) + + Return the size of the object. *o* has to be a :ctype:`PyUnicodeObject` (not + checked). + + +.. cfunction:: Py_ssize_t PyUnicode_GET_DATA_SIZE(PyObject *o) + + Return the size of the object's internal buffer in bytes. *o* has to be a + :ctype:`PyUnicodeObject` (not checked). + + +.. cfunction:: Py_UNICODE* PyUnicode_AS_UNICODE(PyObject *o) + + Return a pointer to the internal :ctype:`Py_UNICODE` buffer of the object. *o* + has to be a :ctype:`PyUnicodeObject` (not checked). + + +.. cfunction:: const char* PyUnicode_AS_DATA(PyObject *o) + + Return a pointer to the internal buffer of the object. *o* has to be a + :ctype:`PyUnicodeObject` (not checked). + +Unicode provides many different character properties. The most often needed ones +are available through these macros which are mapped to C functions depending on +the Python configuration. + +.. % --- Unicode character properties --------------------------------------- + + +.. cfunction:: int Py_UNICODE_ISSPACE(Py_UNICODE ch) + + Return 1 or 0 depending on whether *ch* is a whitespace character. + + +.. cfunction:: int Py_UNICODE_ISLOWER(Py_UNICODE ch) + + Return 1 or 0 depending on whether *ch* is a lowercase character. + + +.. cfunction:: int Py_UNICODE_ISUPPER(Py_UNICODE ch) + + Return 1 or 0 depending on whether *ch* is an uppercase character. + + +.. cfunction:: int Py_UNICODE_ISTITLE(Py_UNICODE ch) + + Return 1 or 0 depending on whether *ch* is a titlecase character. + + +.. cfunction:: int Py_UNICODE_ISLINEBREAK(Py_UNICODE ch) + + Return 1 or 0 depending on whether *ch* is a linebreak character. + + +.. cfunction:: int Py_UNICODE_ISDECIMAL(Py_UNICODE ch) + + Return 1 or 0 depending on whether *ch* is a decimal character. + + +.. cfunction:: int Py_UNICODE_ISDIGIT(Py_UNICODE ch) + + Return 1 or 0 depending on whether *ch* is a digit character. + + +.. cfunction:: int Py_UNICODE_ISNUMERIC(Py_UNICODE ch) + + Return 1 or 0 depending on whether *ch* is a numeric character. + + +.. cfunction:: int Py_UNICODE_ISALPHA(Py_UNICODE ch) + + Return 1 or 0 depending on whether *ch* is an alphabetic character. + + +.. cfunction:: int Py_UNICODE_ISALNUM(Py_UNICODE ch) + + Return 1 or 0 depending on whether *ch* is an alphanumeric character. + +These APIs can be used for fast direct character conversions: + + +.. cfunction:: Py_UNICODE Py_UNICODE_TOLOWER(Py_UNICODE ch) + + Return the character *ch* converted to lower case. + + +.. cfunction:: Py_UNICODE Py_UNICODE_TOUPPER(Py_UNICODE ch) + + Return the character *ch* converted to upper case. + + +.. cfunction:: Py_UNICODE Py_UNICODE_TOTITLE(Py_UNICODE ch) + + Return the character *ch* converted to title case. + + +.. cfunction:: int Py_UNICODE_TODECIMAL(Py_UNICODE ch) + + Return the character *ch* converted to a decimal positive integer. Return + ``-1`` if this is not possible. This macro does not raise exceptions. + + +.. cfunction:: int Py_UNICODE_TODIGIT(Py_UNICODE ch) + + Return the character *ch* converted to a single digit integer. Return ``-1`` if + this is not possible. This macro does not raise exceptions. + + +.. cfunction:: double Py_UNICODE_TONUMERIC(Py_UNICODE ch) + + Return the character *ch* converted to a double. Return ``-1.0`` if this is not + possible. This macro does not raise exceptions. + +To create Unicode objects and access their basic sequence properties, use these +APIs: + +.. % --- Plain Py_UNICODE --------------------------------------------------- + + +.. cfunction:: PyObject* PyUnicode_FromUnicode(const Py_UNICODE *u, Py_ssize_t size) + + Create a Unicode Object from the Py_UNICODE buffer *u* of the given size. *u* + may be *NULL* which causes the contents to be undefined. It is the user's + responsibility to fill in the needed data. The buffer is copied into the new + object. If the buffer is not *NULL*, the return value might be a shared object. + Therefore, modification of the resulting Unicode object is only allowed when *u* + is *NULL*. + + +.. cfunction:: Py_UNICODE* PyUnicode_AsUnicode(PyObject *unicode) + + Return a read-only pointer to the Unicode object's internal :ctype:`Py_UNICODE` + buffer, *NULL* if *unicode* is not a Unicode object. + + +.. cfunction:: Py_ssize_t PyUnicode_GetSize(PyObject *unicode) + + Return the length of the Unicode object. + + +.. cfunction:: PyObject* PyUnicode_FromEncodedObject(PyObject *obj, const char *encoding, const char *errors) + + Coerce an encoded object *obj* to an Unicode object and return a reference with + incremented refcount. + + String and other char buffer compatible objects are decoded according to the + given encoding and using the error handling defined by errors. Both can be + *NULL* to have the interface use the default values (see the next section for + details). + + All other objects, including Unicode objects, cause a :exc:`TypeError` to be + set. + + The API returns *NULL* if there was an error. The caller is responsible for + decref'ing the returned objects. + + +.. cfunction:: PyObject* PyUnicode_FromObject(PyObject *obj) + + Shortcut for ``PyUnicode_FromEncodedObject(obj, NULL, "strict")`` which is used + throughout the interpreter whenever coercion to Unicode is needed. + +If the platform supports :ctype:`wchar_t` and provides a header file wchar.h, +Python can interface directly to this type using the following functions. +Support is optimized if Python's own :ctype:`Py_UNICODE` type is identical to +the system's :ctype:`wchar_t`. + +.. % --- wchar_t support for platforms which support it --------------------- + + +.. cfunction:: PyObject* PyUnicode_FromWideChar(const wchar_t *w, Py_ssize_t size) + + Create a Unicode object from the :ctype:`wchar_t` buffer *w* of the given size. + Return *NULL* on failure. + + +.. cfunction:: Py_ssize_t PyUnicode_AsWideChar(PyUnicodeObject *unicode, wchar_t *w, Py_ssize_t size) + + Copy the Unicode object contents into the :ctype:`wchar_t` buffer *w*. At most + *size* :ctype:`wchar_t` characters are copied (excluding a possibly trailing + 0-termination character). Return the number of :ctype:`wchar_t` characters + copied or -1 in case of an error. Note that the resulting :ctype:`wchar_t` + string may or may not be 0-terminated. It is the responsibility of the caller + to make sure that the :ctype:`wchar_t` string is 0-terminated in case this is + required by the application. + + +.. _builtincodecs: + +Built-in Codecs +^^^^^^^^^^^^^^^ + +Python provides a set of builtin codecs which are written in C for speed. All of +these codecs are directly usable via the following functions. + +Many of the following APIs take two arguments encoding and errors. These +parameters encoding and errors have the same semantics as the ones of the +builtin unicode() Unicode object constructor. + +Setting encoding to *NULL* causes the default encoding to be used which is +ASCII. The file system calls should use :cdata:`Py_FileSystemDefaultEncoding` +as the encoding for file names. This variable should be treated as read-only: On +some systems, it will be a pointer to a static string, on others, it will change +at run-time (such as when the application invokes setlocale). + +Error handling is set by errors which may also be set to *NULL* meaning to use +the default handling defined for the codec. Default error handling for all +builtin codecs is "strict" (:exc:`ValueError` is raised). + +The codecs all use a similar interface. Only deviation from the following +generic ones are documented for simplicity. + +These are the generic codec APIs: + +.. % --- Generic Codecs ----------------------------------------------------- + + +.. cfunction:: PyObject* PyUnicode_Decode(const char *s, Py_ssize_t size, const char *encoding, const char *errors) + + Create a Unicode object by decoding *size* bytes of the encoded string *s*. + *encoding* and *errors* have the same meaning as the parameters of the same name + in the :func:`unicode` builtin function. The codec to be used is looked up + using the Python codec registry. Return *NULL* if an exception was raised by + the codec. + + +.. cfunction:: PyObject* PyUnicode_Encode(const Py_UNICODE *s, Py_ssize_t size, const char *encoding, const char *errors) + + Encode the :ctype:`Py_UNICODE` buffer of the given size and return a Python + string object. *encoding* and *errors* have the same meaning as the parameters + of the same name in the Unicode :meth:`encode` method. The codec to be used is + looked up using the Python codec registry. Return *NULL* if an exception was + raised by the codec. + + +.. cfunction:: PyObject* PyUnicode_AsEncodedString(PyObject *unicode, const char *encoding, const char *errors) + + Encode a Unicode object and return the result as Python string object. + *encoding* and *errors* have the same meaning as the parameters of the same name + in the Unicode :meth:`encode` method. The codec to be used is looked up using + the Python codec registry. Return *NULL* if an exception was raised by the + codec. + +These are the UTF-8 codec APIs: + +.. % --- UTF-8 Codecs ------------------------------------------------------- + + +.. cfunction:: PyObject* PyUnicode_DecodeUTF8(const char *s, Py_ssize_t size, const char *errors) + + Create a Unicode object by decoding *size* bytes of the UTF-8 encoded string + *s*. Return *NULL* if an exception was raised by the codec. + + +.. cfunction:: PyObject* PyUnicode_DecodeUTF8Stateful(const char *s, Py_ssize_t size, const char *errors, Py_ssize_t *consumed) + + If *consumed* is *NULL*, behave like :cfunc:`PyUnicode_DecodeUTF8`. If + *consumed* is not *NULL*, trailing incomplete UTF-8 byte sequences will not be + treated as an error. Those bytes will not be decoded and the number of bytes + that have been decoded will be stored in *consumed*. + + .. versionadded:: 2.4 + + +.. cfunction:: PyObject* PyUnicode_EncodeUTF8(const Py_UNICODE *s, Py_ssize_t size, const char *errors) + + Encode the :ctype:`Py_UNICODE` buffer of the given size using UTF-8 and return a + Python string object. Return *NULL* if an exception was raised by the codec. + + +.. cfunction:: PyObject* PyUnicode_AsUTF8String(PyObject *unicode) + + Encode a Unicode object using UTF-8 and return the result as Python string + object. Error handling is "strict". Return *NULL* if an exception was raised + by the codec. + +These are the UTF-32 codec APIs: + +.. % --- UTF-32 Codecs ------------------------------------------------------ */ + + +.. cfunction:: PyObject* PyUnicode_DecodeUTF32(const char *s, Py_ssize_t size, const char *errors, int *byteorder) + + Decode *length* bytes from a UTF-32 encoded buffer string and return the + corresponding Unicode object. *errors* (if non-*NULL*) defines the error + handling. It defaults to "strict". + + If *byteorder* is non-*NULL*, the decoder starts decoding using the given byte + order:: + + *byteorder == -1: little endian + *byteorder == 0: native order + *byteorder == 1: big endian + + and then switches if the first four bytes of the input data are a byte order mark + (BOM) and the specified byte order is native order. This BOM is not copied into + the resulting Unicode string. After completion, *\*byteorder* is set to the + current byte order at the end of input data. + + In a narrow build codepoints outside the BMP will be decoded as surrogate pairs. + + If *byteorder* is *NULL*, the codec starts in native order mode. + + Return *NULL* if an exception was raised by the codec. + + .. versionadded:: 2.6 + + +.. cfunction:: PyObject* PyUnicode_DecodeUTF32Stateful(const char *s, Py_ssize_t size, const char *errors, int *byteorder, Py_ssize_t *consumed) + + If *consumed* is *NULL*, behave like :cfunc:`PyUnicode_DecodeUTF32`. If + *consumed* is not *NULL*, :cfunc:`PyUnicode_DecodeUTF32Stateful` will not treat + trailing incomplete UTF-32 byte sequences (such as a number of bytes not divisible + by four) as an error. Those bytes will not be decoded and the number of bytes + that have been decoded will be stored in *consumed*. + + .. versionadded:: 2.6 + + +.. cfunction:: PyObject* PyUnicode_EncodeUTF32(const Py_UNICODE *s, Py_ssize_t size, const char *errors, int byteorder) + + Return a Python bytes object holding the UTF-32 encoded value of the Unicode + data in *s*. If *byteorder* is not ``0``, output is written according to the + following byte order:: + + byteorder == -1: little endian + byteorder == 0: native byte order (writes a BOM mark) + byteorder == 1: big endian + + If byteorder is ``0``, the output string will always start with the Unicode BOM + mark (U+FEFF). In the other two modes, no BOM mark is prepended. + + If *Py_UNICODE_WIDE* is not defined, surrogate pairs will be output + as a single codepoint. + + Return *NULL* if an exception was raised by the codec. + + .. versionadded:: 2.6 + + +.. cfunction:: PyObject* PyUnicode_AsUTF32String(PyObject *unicode) + + Return a Python string using the UTF-32 encoding in native byte order. The + string always starts with a BOM mark. Error handling is "strict". Return + *NULL* if an exception was raised by the codec. + + .. versionadded:: 2.6 + + +These are the UTF-16 codec APIs: + +.. % --- UTF-16 Codecs ------------------------------------------------------ */ + + +.. cfunction:: PyObject* PyUnicode_DecodeUTF16(const char *s, Py_ssize_t size, const char *errors, int *byteorder) + + Decode *length* bytes from a UTF-16 encoded buffer string and return the + corresponding Unicode object. *errors* (if non-*NULL*) defines the error + handling. It defaults to "strict". + + If *byteorder* is non-*NULL*, the decoder starts decoding using the given byte + order:: + + *byteorder == -1: little endian + *byteorder == 0: native order + *byteorder == 1: big endian + + and then switches if the first two bytes of the input data are a byte order mark + (BOM) and the specified byte order is native order. This BOM is not copied into + the resulting Unicode string. After completion, *\*byteorder* is set to the + current byte order at the. + + If *byteorder* is *NULL*, the codec starts in native order mode. + + Return *NULL* if an exception was raised by the codec. + + +.. cfunction:: PyObject* PyUnicode_DecodeUTF16Stateful(const char *s, Py_ssize_t size, const char *errors, int *byteorder, Py_ssize_t *consumed) + + If *consumed* is *NULL*, behave like :cfunc:`PyUnicode_DecodeUTF16`. If + *consumed* is not *NULL*, :cfunc:`PyUnicode_DecodeUTF16Stateful` will not treat + trailing incomplete UTF-16 byte sequences (such as an odd number of bytes or a + split surrogate pair) as an error. Those bytes will not be decoded and the + number of bytes that have been decoded will be stored in *consumed*. + + .. versionadded:: 2.4 + + +.. cfunction:: PyObject* PyUnicode_EncodeUTF16(const Py_UNICODE *s, Py_ssize_t size, const char *errors, int byteorder) + + Return a Python string object holding the UTF-16 encoded value of the Unicode + data in *s*. If *byteorder* is not ``0``, output is written according to the + following byte order:: + + byteorder == -1: little endian + byteorder == 0: native byte order (writes a BOM mark) + byteorder == 1: big endian + + If byteorder is ``0``, the output string will always start with the Unicode BOM + mark (U+FEFF). In the other two modes, no BOM mark is prepended. + + If *Py_UNICODE_WIDE* is defined, a single :ctype:`Py_UNICODE` value may get + represented as a surrogate pair. If it is not defined, each :ctype:`Py_UNICODE` + values is interpreted as an UCS-2 character. + + Return *NULL* if an exception was raised by the codec. + + +.. cfunction:: PyObject* PyUnicode_AsUTF16String(PyObject *unicode) + + Return a Python string using the UTF-16 encoding in native byte order. The + string always starts with a BOM mark. Error handling is "strict". Return + *NULL* if an exception was raised by the codec. + +These are the "Unicode Escape" codec APIs: + +.. % --- Unicode-Escape Codecs ---------------------------------------------- + + +.. cfunction:: PyObject* PyUnicode_DecodeUnicodeEscape(const char *s, Py_ssize_t size, const char *errors) + + Create a Unicode object by decoding *size* bytes of the Unicode-Escape encoded + string *s*. Return *NULL* if an exception was raised by the codec. + + +.. cfunction:: PyObject* PyUnicode_EncodeUnicodeEscape(const Py_UNICODE *s, Py_ssize_t size) + + Encode the :ctype:`Py_UNICODE` buffer of the given size using Unicode-Escape and + return a Python string object. Return *NULL* if an exception was raised by the + codec. + + +.. cfunction:: PyObject* PyUnicode_AsUnicodeEscapeString(PyObject *unicode) + + Encode a Unicode object using Unicode-Escape and return the result as Python + string object. Error handling is "strict". Return *NULL* if an exception was + raised by the codec. + +These are the "Raw Unicode Escape" codec APIs: + +.. % --- Raw-Unicode-Escape Codecs ------------------------------------------ + + +.. cfunction:: PyObject* PyUnicode_DecodeRawUnicodeEscape(const char *s, Py_ssize_t size, const char *errors) + + Create a Unicode object by decoding *size* bytes of the Raw-Unicode-Escape + encoded string *s*. Return *NULL* if an exception was raised by the codec. + + +.. cfunction:: PyObject* PyUnicode_EncodeRawUnicodeEscape(const Py_UNICODE *s, Py_ssize_t size, const char *errors) + + Encode the :ctype:`Py_UNICODE` buffer of the given size using Raw-Unicode-Escape + and return a Python string object. Return *NULL* if an exception was raised by + the codec. + + +.. cfunction:: PyObject* PyUnicode_AsRawUnicodeEscapeString(PyObject *unicode) + + Encode a Unicode object using Raw-Unicode-Escape and return the result as + Python string object. Error handling is "strict". Return *NULL* if an exception + was raised by the codec. + +These are the Latin-1 codec APIs: Latin-1 corresponds to the first 256 Unicode +ordinals and only these are accepted by the codecs during encoding. + +.. % --- Latin-1 Codecs ----------------------------------------------------- + + +.. cfunction:: PyObject* PyUnicode_DecodeLatin1(const char *s, Py_ssize_t size, const char *errors) + + Create a Unicode object by decoding *size* bytes of the Latin-1 encoded string + *s*. Return *NULL* if an exception was raised by the codec. + + +.. cfunction:: PyObject* PyUnicode_EncodeLatin1(const Py_UNICODE *s, Py_ssize_t size, const char *errors) + + Encode the :ctype:`Py_UNICODE` buffer of the given size using Latin-1 and return + a Python string object. Return *NULL* if an exception was raised by the codec. + + +.. cfunction:: PyObject* PyUnicode_AsLatin1String(PyObject *unicode) + + Encode a Unicode object using Latin-1 and return the result as Python string + object. Error handling is "strict". Return *NULL* if an exception was raised + by the codec. + +These are the ASCII codec APIs. Only 7-bit ASCII data is accepted. All other +codes generate errors. + +.. % --- ASCII Codecs ------------------------------------------------------- + + +.. cfunction:: PyObject* PyUnicode_DecodeASCII(const char *s, Py_ssize_t size, const char *errors) + + Create a Unicode object by decoding *size* bytes of the ASCII encoded string + *s*. Return *NULL* if an exception was raised by the codec. + + +.. cfunction:: PyObject* PyUnicode_EncodeASCII(const Py_UNICODE *s, Py_ssize_t size, const char *errors) + + Encode the :ctype:`Py_UNICODE` buffer of the given size using ASCII and return a + Python string object. Return *NULL* if an exception was raised by the codec. + + +.. cfunction:: PyObject* PyUnicode_AsASCIIString(PyObject *unicode) + + Encode a Unicode object using ASCII and return the result as Python string + object. Error handling is "strict". Return *NULL* if an exception was raised + by the codec. + +These are the mapping codec APIs: + +.. % --- Character Map Codecs ----------------------------------------------- + +This codec is special in that it can be used to implement many different codecs +(and this is in fact what was done to obtain most of the standard codecs +included in the :mod:`encodings` package). The codec uses mapping to encode and +decode characters. + +Decoding mappings must map single string characters to single Unicode +characters, integers (which are then interpreted as Unicode ordinals) or None +(meaning "undefined mapping" and causing an error). + +Encoding mappings must map single Unicode characters to single string +characters, integers (which are then interpreted as Latin-1 ordinals) or None +(meaning "undefined mapping" and causing an error). + +The mapping objects provided must only support the __getitem__ mapping +interface. + +If a character lookup fails with a LookupError, the character is copied as-is +meaning that its ordinal value will be interpreted as Unicode or Latin-1 ordinal +resp. Because of this, mappings only need to contain those mappings which map +characters to different code points. + + +.. cfunction:: PyObject* PyUnicode_DecodeCharmap(const char *s, Py_ssize_t size, PyObject *mapping, const char *errors) + + Create a Unicode object by decoding *size* bytes of the encoded string *s* using + the given *mapping* object. Return *NULL* if an exception was raised by the + codec. If *mapping* is *NULL* latin-1 decoding will be done. Else it can be a + dictionary mapping byte or a unicode string, which is treated as a lookup table. + Byte values greater that the length of the string and U+FFFE "characters" are + treated as "undefined mapping". + + .. versionchanged:: 2.4 + Allowed unicode string as mapping argument. + + +.. cfunction:: PyObject* PyUnicode_EncodeCharmap(const Py_UNICODE *s, Py_ssize_t size, PyObject *mapping, const char *errors) + + Encode the :ctype:`Py_UNICODE` buffer of the given size using the given + *mapping* object and return a Python string object. Return *NULL* if an + exception was raised by the codec. + + +.. cfunction:: PyObject* PyUnicode_AsCharmapString(PyObject *unicode, PyObject *mapping) + + Encode a Unicode object using the given *mapping* object and return the result + as Python string object. Error handling is "strict". Return *NULL* if an + exception was raised by the codec. + +The following codec API is special in that maps Unicode to Unicode. + + +.. cfunction:: PyObject* PyUnicode_TranslateCharmap(const Py_UNICODE *s, Py_ssize_t size, PyObject *table, const char *errors) + + Translate a :ctype:`Py_UNICODE` buffer of the given length by applying a + character mapping *table* to it and return the resulting Unicode object. Return + *NULL* when an exception was raised by the codec. + + The *mapping* table must map Unicode ordinal integers to Unicode ordinal + integers or None (causing deletion of the character). + + Mapping tables need only provide the :meth:`__getitem__` interface; dictionaries + and sequences work well. Unmapped character ordinals (ones which cause a + :exc:`LookupError`) are left untouched and are copied as-is. + +These are the MBCS codec APIs. They are currently only available on Windows and +use the Win32 MBCS converters to implement the conversions. Note that MBCS (or +DBCS) is a class of encodings, not just one. The target encoding is defined by +the user settings on the machine running the codec. + +.. % --- MBCS codecs for Windows -------------------------------------------- + + +.. cfunction:: PyObject* PyUnicode_DecodeMBCS(const char *s, Py_ssize_t size, const char *errors) + + Create a Unicode object by decoding *size* bytes of the MBCS encoded string *s*. + Return *NULL* if an exception was raised by the codec. + + +.. cfunction:: PyObject* PyUnicode_DecodeMBCSStateful(const char *s, int size, const char *errors, int *consumed) + + If *consumed* is *NULL*, behave like :cfunc:`PyUnicode_DecodeMBCS`. If + *consumed* is not *NULL*, :cfunc:`PyUnicode_DecodeMBCSStateful` will not decode + trailing lead byte and the number of bytes that have been decoded will be stored + in *consumed*. + + .. versionadded:: 2.5 + + +.. cfunction:: PyObject* PyUnicode_EncodeMBCS(const Py_UNICODE *s, Py_ssize_t size, const char *errors) + + Encode the :ctype:`Py_UNICODE` buffer of the given size using MBCS and return a + Python string object. Return *NULL* if an exception was raised by the codec. + + +.. cfunction:: PyObject* PyUnicode_AsMBCSString(PyObject *unicode) + + Encode a Unicode object using MBCS and return the result as Python string + object. Error handling is "strict". Return *NULL* if an exception was raised + by the codec. + +.. % --- Methods & Slots ---------------------------------------------------- + + +.. _unicodemethodsandslots: + +Methods and Slot Functions +^^^^^^^^^^^^^^^^^^^^^^^^^^ + +The following APIs are capable of handling Unicode objects and strings on input +(we refer to them as strings in the descriptions) and return Unicode objects or +integers as appropriate. + +They all return *NULL* or ``-1`` if an exception occurs. + + +.. cfunction:: PyObject* PyUnicode_Concat(PyObject *left, PyObject *right) + + Concat two strings giving a new Unicode string. + + +.. cfunction:: PyObject* PyUnicode_Split(PyObject *s, PyObject *sep, Py_ssize_t maxsplit) + + Split a string giving a list of Unicode strings. If sep is *NULL*, splitting + will be done at all whitespace substrings. Otherwise, splits occur at the given + separator. At most *maxsplit* splits will be done. If negative, no limit is + set. Separators are not included in the resulting list. + + +.. cfunction:: PyObject* PyUnicode_Splitlines(PyObject *s, int keepend) + + Split a Unicode string at line breaks, returning a list of Unicode strings. + CRLF is considered to be one line break. If *keepend* is 0, the Line break + characters are not included in the resulting strings. + + +.. cfunction:: PyObject* PyUnicode_Translate(PyObject *str, PyObject *table, const char *errors) + + Translate a string by applying a character mapping table to it and return the + resulting Unicode object. + + The mapping table must map Unicode ordinal integers to Unicode ordinal integers + or None (causing deletion of the character). + + Mapping tables need only provide the :meth:`__getitem__` interface; dictionaries + and sequences work well. Unmapped character ordinals (ones which cause a + :exc:`LookupError`) are left untouched and are copied as-is. + + *errors* has the usual meaning for codecs. It may be *NULL* which indicates to + use the default error handling. + + +.. cfunction:: PyObject* PyUnicode_Join(PyObject *separator, PyObject *seq) + + Join a sequence of strings using the given separator and return the resulting + Unicode string. + + +.. cfunction:: int PyUnicode_Tailmatch(PyObject *str, PyObject *substr, Py_ssize_t start, Py_ssize_t end, int direction) + + Return 1 if *substr* matches *str*[*start*:*end*] at the given tail end + (*direction* == -1 means to do a prefix match, *direction* == 1 a suffix match), + 0 otherwise. Return ``-1`` if an error occurred. + + +.. cfunction:: Py_ssize_t PyUnicode_Find(PyObject *str, PyObject *substr, Py_ssize_t start, Py_ssize_t end, int direction) + + Return the first position of *substr* in *str*[*start*:*end*] using the given + *direction* (*direction* == 1 means to do a forward search, *direction* == -1 a + backward search). The return value is the index of the first match; a value of + ``-1`` indicates that no match was found, and ``-2`` indicates that an error + occurred and an exception has been set. + + +.. cfunction:: Py_ssize_t PyUnicode_Count(PyObject *str, PyObject *substr, Py_ssize_t start, Py_ssize_t end) + + Return the number of non-overlapping occurrences of *substr* in + ``str[start:end]``. Return ``-1`` if an error occurred. + + +.. cfunction:: PyObject* PyUnicode_Replace(PyObject *str, PyObject *substr, PyObject *replstr, Py_ssize_t maxcount) + + Replace at most *maxcount* occurrences of *substr* in *str* with *replstr* and + return the resulting Unicode object. *maxcount* == -1 means replace all + occurrences. + + +.. cfunction:: int PyUnicode_Compare(PyObject *left, PyObject *right) + + Compare two strings and return -1, 0, 1 for less than, equal, and greater than, + respectively. + + +.. cfunction:: int PyUnicode_RichCompare(PyObject *left, PyObject *right, int op) + + Rich compare two unicode strings and return one of the following: + + * ``NULL`` in case an exception was raised + * :const:`Py_True` or :const:`Py_False` for successful comparisons + * :const:`Py_NotImplemented` in case the type combination is unknown + + Note that :const:`Py_EQ` and :const:`Py_NE` comparisons can cause a + :exc:`UnicodeWarning` in case the conversion of the arguments to Unicode fails + with a :exc:`UnicodeDecodeError`. + + Possible values for *op* are :const:`Py_GT`, :const:`Py_GE`, :const:`Py_EQ`, + :const:`Py_NE`, :const:`Py_LT`, and :const:`Py_LE`. + + +.. cfunction:: PyObject* PyUnicode_Format(PyObject *format, PyObject *args) + + Return a new string object from *format* and *args*; this is analogous to + ``format % args``. The *args* argument must be a tuple. + + +.. cfunction:: int PyUnicode_Contains(PyObject *container, PyObject *element) + + Check whether *element* is contained in *container* and return true or false + accordingly. + + *element* has to coerce to a one element Unicode string. ``-1`` is returned if + there was an error. Added: python/trunk/Doc/c-api/weakref.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/c-api/weakref.rst Sat Jan 19 23:08:21 2008 @@ -0,0 +1,76 @@ +.. highlightlang:: c + +.. _weakrefobjects: + +Weak Reference Objects +---------------------- + +Python supports *weak references* as first-class objects. There are two +specific object types which directly implement weak references. The first is a +simple reference object, and the second acts as a proxy for the original object +as much as it can. + + +.. cfunction:: int PyWeakref_Check(ob) + + Return true if *ob* is either a reference or proxy object. + + .. versionadded:: 2.2 + + +.. cfunction:: int PyWeakref_CheckRef(ob) + + Return true if *ob* is a reference object. + + .. versionadded:: 2.2 + + +.. cfunction:: int PyWeakref_CheckProxy(ob) + + Return true if *ob* is a proxy object. + + .. versionadded:: 2.2 + + +.. cfunction:: PyObject* PyWeakref_NewRef(PyObject *ob, PyObject *callback) + + Return a weak reference object for the object *ob*. This will always return + a new reference, but is not guaranteed to create a new object; an existing + reference object may be returned. The second parameter, *callback*, can be a + callable object that receives notification when *ob* is garbage collected; it + should accept a single parameter, which will be the weak reference object + itself. *callback* may also be ``None`` or *NULL*. If *ob* is not a + weakly-referencable object, or if *callback* is not callable, ``None``, or + *NULL*, this will return *NULL* and raise :exc:`TypeError`. + + .. versionadded:: 2.2 + + +.. cfunction:: PyObject* PyWeakref_NewProxy(PyObject *ob, PyObject *callback) + + Return a weak reference proxy object for the object *ob*. This will always + return a new reference, but is not guaranteed to create a new object; an + existing proxy object may be returned. The second parameter, *callback*, can + be a callable object that receives notification when *ob* is garbage + collected; it should accept a single parameter, which will be the weak + reference object itself. *callback* may also be ``None`` or *NULL*. If *ob* + is not a weakly-referencable object, or if *callback* is not callable, + ``None``, or *NULL*, this will return *NULL* and raise :exc:`TypeError`. + + .. versionadded:: 2.2 + + +.. cfunction:: PyObject* PyWeakref_GetObject(PyObject *ref) + + Return the referenced object from a weak reference, *ref*. If the referent is + no longer live, returns ``None``. + + .. versionadded:: 2.2 + + +.. cfunction:: PyObject* PyWeakref_GET_OBJECT(PyObject *ref) + + Similar to :cfunc:`PyWeakref_GetObject`, but implemented as a macro that does no + error checking. + + .. versionadded:: 2.2 From python-checkins at python.org Sat Jan 19 23:14:29 2008 From: python-checkins at python.org (georg.brandl) Date: Sat, 19 Jan 2008 23:14:29 +0100 (CET) Subject: [Python-checkins] r60110 - python/trunk/Doc/c-api/arg.rst python/trunk/Doc/c-api/conversion.rst python/trunk/Doc/c-api/import.rst python/trunk/Doc/c-api/marshal.rst python/trunk/Doc/c-api/reflection.rst python/trunk/Doc/c-api/sys.rst python/trunk/Doc/c-api/utilities.rst Message-ID: <20080119221429.3FD761E401A@bag.python.org> Author: georg.brandl Date: Sat Jan 19 23:14:27 2008 New Revision: 60110 Added: python/trunk/Doc/c-api/arg.rst python/trunk/Doc/c-api/conversion.rst python/trunk/Doc/c-api/import.rst python/trunk/Doc/c-api/marshal.rst python/trunk/Doc/c-api/reflection.rst python/trunk/Doc/c-api/sys.rst Modified: python/trunk/Doc/c-api/utilities.rst Log: Missed one big file to split up. Added: python/trunk/Doc/c-api/arg.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/c-api/arg.rst Sat Jan 19 23:14:27 2008 @@ -0,0 +1,509 @@ +.. highlightlang:: c + +.. _arg-parsing: + +Parsing arguments and building values +===================================== + +These functions are useful when creating your own extensions functions and +methods. Additional information and examples are available in +:ref:`extending-index`. + +The first three of these functions described, :cfunc:`PyArg_ParseTuple`, +:cfunc:`PyArg_ParseTupleAndKeywords`, and :cfunc:`PyArg_Parse`, all use *format +strings* which are used to tell the function about the expected arguments. The +format strings use the same syntax for each of these functions. + +A format string consists of zero or more "format units." A format unit +describes one Python object; it is usually a single character or a parenthesized +sequence of format units. With a few exceptions, a format unit that is not a +parenthesized sequence normally corresponds to a single address argument to +these functions. In the following description, the quoted form is the format +unit; the entry in (round) parentheses is the Python object type that matches +the format unit; and the entry in [square] brackets is the type of the C +variable(s) whose address should be passed. + +``s`` (string or Unicode object) [const char \*] + Convert a Python string or Unicode object to a C pointer to a character string. + You must not provide storage for the string itself; a pointer to an existing + string is stored into the character pointer variable whose address you pass. + The C string is NUL-terminated. The Python string must not contain embedded NUL + bytes; if it does, a :exc:`TypeError` exception is raised. Unicode objects are + converted to C strings using the default encoding. If this conversion fails, a + :exc:`UnicodeError` is raised. + +``s#`` (string, Unicode or any read buffer compatible object) [const char \*, int] + This variant on ``s`` stores into two C variables, the first one a pointer to a + character string, the second one its length. In this case the Python string may + contain embedded null bytes. Unicode objects pass back a pointer to the default + encoded string version of the object if such a conversion is possible. All + other read-buffer compatible objects pass back a reference to the raw internal + data representation. + +``z`` (string or ``None``) [const char \*] + Like ``s``, but the Python object may also be ``None``, in which case the C + pointer is set to *NULL*. + +``z#`` (string or ``None`` or any read buffer compatible object) [const char \*, int] + This is to ``s#`` as ``z`` is to ``s``. + +``u`` (Unicode object) [Py_UNICODE \*] + Convert a Python Unicode object to a C pointer to a NUL-terminated buffer of + 16-bit Unicode (UTF-16) data. As with ``s``, there is no need to provide + storage for the Unicode data buffer; a pointer to the existing Unicode data is + stored into the :ctype:`Py_UNICODE` pointer variable whose address you pass. + +``u#`` (Unicode object) [Py_UNICODE \*, int] + This variant on ``u`` stores into two C variables, the first one a pointer to a + Unicode data buffer, the second one its length. Non-Unicode objects are handled + by interpreting their read-buffer pointer as pointer to a :ctype:`Py_UNICODE` + array. + +``es`` (string, Unicode object or character buffer compatible object) [const char \*encoding, char \*\*buffer] + This variant on ``s`` is used for encoding Unicode and objects convertible to + Unicode into a character buffer. It only works for encoded data without embedded + NUL bytes. + + This format requires two arguments. The first is only used as input, and + must be a :ctype:`const char\*` which points to the name of an encoding as a + NUL-terminated string, or *NULL*, in which case the default encoding is used. + An exception is raised if the named encoding is not known to Python. The + second argument must be a :ctype:`char\*\*`; the value of the pointer it + references will be set to a buffer with the contents of the argument text. + The text will be encoded in the encoding specified by the first argument. + + :cfunc:`PyArg_ParseTuple` will allocate a buffer of the needed size, copy the + encoded data into this buffer and adjust *\*buffer* to reference the newly + allocated storage. The caller is responsible for calling :cfunc:`PyMem_Free` to + free the allocated buffer after use. + +``et`` (string, Unicode object or character buffer compatible object) [const char \*encoding, char \*\*buffer] + Same as ``es`` except that 8-bit string objects are passed through without + recoding them. Instead, the implementation assumes that the string object uses + the encoding passed in as parameter. + +``es#`` (string, Unicode object or character buffer compatible object) [const char \*encoding, char \*\*buffer, int \*buffer_length] + This variant on ``s#`` is used for encoding Unicode and objects convertible to + Unicode into a character buffer. Unlike the ``es`` format, this variant allows + input data which contains NUL characters. + + It requires three arguments. The first is only used as input, and must be a + :ctype:`const char\*` which points to the name of an encoding as a + NUL-terminated string, or *NULL*, in which case the default encoding is used. + An exception is raised if the named encoding is not known to Python. The + second argument must be a :ctype:`char\*\*`; the value of the pointer it + references will be set to a buffer with the contents of the argument text. + The text will be encoded in the encoding specified by the first argument. + The third argument must be a pointer to an integer; the referenced integer + will be set to the number of bytes in the output buffer. + + There are two modes of operation: + + If *\*buffer* points a *NULL* pointer, the function will allocate a buffer of + the needed size, copy the encoded data into this buffer and set *\*buffer* to + reference the newly allocated storage. The caller is responsible for calling + :cfunc:`PyMem_Free` to free the allocated buffer after usage. + + If *\*buffer* points to a non-*NULL* pointer (an already allocated buffer), + :cfunc:`PyArg_ParseTuple` will use this location as the buffer and interpret the + initial value of *\*buffer_length* as the buffer size. It will then copy the + encoded data into the buffer and NUL-terminate it. If the buffer is not large + enough, a :exc:`ValueError` will be set. + + In both cases, *\*buffer_length* is set to the length of the encoded data + without the trailing NUL byte. + +``et#`` (string, Unicode object or character buffer compatible object) [const char \*encoding, char \*\*buffer] + Same as ``es#`` except that string objects are passed through without recoding + them. Instead, the implementation assumes that the string object uses the + encoding passed in as parameter. + +``b`` (integer) [char] + Convert a Python integer to a tiny int, stored in a C :ctype:`char`. + +``B`` (integer) [unsigned char] + Convert a Python integer to a tiny int without overflow checking, stored in a C + :ctype:`unsigned char`. + + .. versionadded:: 2.3 + +``h`` (integer) [short int] + Convert a Python integer to a C :ctype:`short int`. + +``H`` (integer) [unsigned short int] + Convert a Python integer to a C :ctype:`unsigned short int`, without overflow + checking. + + .. versionadded:: 2.3 + +``i`` (integer) [int] + Convert a Python integer to a plain C :ctype:`int`. + +``I`` (integer) [unsigned int] + Convert a Python integer to a C :ctype:`unsigned int`, without overflow + checking. + + .. versionadded:: 2.3 + +``l`` (integer) [long int] + Convert a Python integer to a C :ctype:`long int`. + +``k`` (integer) [unsigned long] + Convert a Python integer or long integer to a C :ctype:`unsigned long` without + overflow checking. + + .. versionadded:: 2.3 + +``L`` (integer) [PY_LONG_LONG] + Convert a Python integer to a C :ctype:`long long`. This format is only + available on platforms that support :ctype:`long long` (or :ctype:`_int64` on + Windows). + +``K`` (integer) [unsigned PY_LONG_LONG] + Convert a Python integer or long integer to a C :ctype:`unsigned long long` + without overflow checking. This format is only available on platforms that + support :ctype:`unsigned long long` (or :ctype:`unsigned _int64` on Windows). + + .. versionadded:: 2.3 + +``n`` (integer) [Py_ssize_t] + Convert a Python integer or long integer to a C :ctype:`Py_ssize_t`. + + .. versionadded:: 2.5 + +``c`` (string of length 1) [char] + Convert a Python character, represented as a string of length 1, to a C + :ctype:`char`. + +``f`` (float) [float] + Convert a Python floating point number to a C :ctype:`float`. + +``d`` (float) [double] + Convert a Python floating point number to a C :ctype:`double`. + +``D`` (complex) [Py_complex] + Convert a Python complex number to a C :ctype:`Py_complex` structure. + +``O`` (object) [PyObject \*] + Store a Python object (without any conversion) in a C object pointer. The C + program thus receives the actual object that was passed. The object's reference + count is not increased. The pointer stored is not *NULL*. + +``O!`` (object) [*typeobject*, PyObject \*] + Store a Python object in a C object pointer. This is similar to ``O``, but + takes two C arguments: the first is the address of a Python type object, the + second is the address of the C variable (of type :ctype:`PyObject\*`) into which + the object pointer is stored. If the Python object does not have the required + type, :exc:`TypeError` is raised. + +``O&`` (object) [*converter*, *anything*] + Convert a Python object to a C variable through a *converter* function. This + takes two arguments: the first is a function, the second is the address of a C + variable (of arbitrary type), converted to :ctype:`void \*`. The *converter* + function in turn is called as follows:: + + status = converter(object, address); + + where *object* is the Python object to be converted and *address* is the + :ctype:`void\*` argument that was passed to the :cfunc:`PyArg_Parse\*` function. + The returned *status* should be ``1`` for a successful conversion and ``0`` if + the conversion has failed. When the conversion fails, the *converter* function + should raise an exception. + +``S`` (string) [PyStringObject \*] + Like ``O`` but requires that the Python object is a string object. Raises + :exc:`TypeError` if the object is not a string object. The C variable may also + be declared as :ctype:`PyObject\*`. + +``U`` (Unicode string) [PyUnicodeObject \*] + Like ``O`` but requires that the Python object is a Unicode object. Raises + :exc:`TypeError` if the object is not a Unicode object. The C variable may also + be declared as :ctype:`PyObject\*`. + +``t#`` (read-only character buffer) [char \*, int] + Like ``s#``, but accepts any object which implements the read-only buffer + interface. The :ctype:`char\*` variable is set to point to the first byte of + the buffer, and the :ctype:`int` is set to the length of the buffer. Only + single-segment buffer objects are accepted; :exc:`TypeError` is raised for all + others. + +``w`` (read-write character buffer) [char \*] + Similar to ``s``, but accepts any object which implements the read-write buffer + interface. The caller must determine the length of the buffer by other means, + or use ``w#`` instead. Only single-segment buffer objects are accepted; + :exc:`TypeError` is raised for all others. + +``w#`` (read-write character buffer) [char \*, int] + Like ``s#``, but accepts any object which implements the read-write buffer + interface. The :ctype:`char \*` variable is set to point to the first byte of + the buffer, and the :ctype:`int` is set to the length of the buffer. Only + single-segment buffer objects are accepted; :exc:`TypeError` is raised for all + others. + +``(items)`` (tuple) [*matching-items*] + The object must be a Python sequence whose length is the number of format units + in *items*. The C arguments must correspond to the individual format units in + *items*. Format units for sequences may be nested. + + .. note:: + + Prior to Python version 1.5.2, this format specifier only accepted a tuple + containing the individual parameters, not an arbitrary sequence. Code which + previously caused :exc:`TypeError` to be raised here may now proceed without an + exception. This is not expected to be a problem for existing code. + +It is possible to pass Python long integers where integers are requested; +however no proper range checking is done --- the most significant bits are +silently truncated when the receiving field is too small to receive the value +(actually, the semantics are inherited from downcasts in C --- your mileage may +vary). + +A few other characters have a meaning in a format string. These may not occur +inside nested parentheses. They are: + +``|`` + Indicates that the remaining arguments in the Python argument list are optional. + The C variables corresponding to optional arguments should be initialized to + their default value --- when an optional argument is not specified, + :cfunc:`PyArg_ParseTuple` does not touch the contents of the corresponding C + variable(s). + +``:`` + The list of format units ends here; the string after the colon is used as the + function name in error messages (the "associated value" of the exception that + :cfunc:`PyArg_ParseTuple` raises). + +``;`` + The list of format units ends here; the string after the semicolon is used as + the error message *instead* of the default error message. Clearly, ``:`` and + ``;`` mutually exclude each other. + +Note that any Python object references which are provided to the caller are +*borrowed* references; do not decrement their reference count! + +Additional arguments passed to these functions must be addresses of variables +whose type is determined by the format string; these are used to store values +from the input tuple. There are a few cases, as described in the list of format +units above, where these parameters are used as input values; they should match +what is specified for the corresponding format unit in that case. + +For the conversion to succeed, the *arg* object must match the format and the +format must be exhausted. On success, the :cfunc:`PyArg_Parse\*` functions +return true, otherwise they return false and raise an appropriate exception. + + +.. cfunction:: int PyArg_ParseTuple(PyObject *args, const char *format, ...) + + Parse the parameters of a function that takes only positional parameters into + local variables. Returns true on success; on failure, it returns false and + raises the appropriate exception. + + +.. cfunction:: int PyArg_VaParse(PyObject *args, const char *format, va_list vargs) + + Identical to :cfunc:`PyArg_ParseTuple`, except that it accepts a va_list rather + than a variable number of arguments. + + +.. cfunction:: int PyArg_ParseTupleAndKeywords(PyObject *args, PyObject *kw, const char *format, char *keywords[], ...) + + Parse the parameters of a function that takes both positional and keyword + parameters into local variables. Returns true on success; on failure, it + returns false and raises the appropriate exception. + + +.. cfunction:: int PyArg_VaParseTupleAndKeywords(PyObject *args, PyObject *kw, const char *format, char *keywords[], va_list vargs) + + Identical to :cfunc:`PyArg_ParseTupleAndKeywords`, except that it accepts a + va_list rather than a variable number of arguments. + + +.. cfunction:: int PyArg_Parse(PyObject *args, const char *format, ...) + + Function used to deconstruct the argument lists of "old-style" functions --- + these are functions which use the :const:`METH_OLDARGS` parameter parsing + method. This is not recommended for use in parameter parsing in new code, and + most code in the standard interpreter has been modified to no longer use this + for that purpose. It does remain a convenient way to decompose other tuples, + however, and may continue to be used for that purpose. + + +.. cfunction:: int PyArg_UnpackTuple(PyObject *args, const char *name, Py_ssize_t min, Py_ssize_t max, ...) + + A simpler form of parameter retrieval which does not use a format string to + specify the types of the arguments. Functions which use this method to retrieve + their parameters should be declared as :const:`METH_VARARGS` in function or + method tables. The tuple containing the actual parameters should be passed as + *args*; it must actually be a tuple. The length of the tuple must be at least + *min* and no more than *max*; *min* and *max* may be equal. Additional + arguments must be passed to the function, each of which should be a pointer to a + :ctype:`PyObject\*` variable; these will be filled in with the values from + *args*; they will contain borrowed references. The variables which correspond + to optional parameters not given by *args* will not be filled in; these should + be initialized by the caller. This function returns true on success and false if + *args* is not a tuple or contains the wrong number of elements; an exception + will be set if there was a failure. + + This is an example of the use of this function, taken from the sources for the + :mod:`_weakref` helper module for weak references:: + + static PyObject * + weakref_ref(PyObject *self, PyObject *args) + { + PyObject *object; + PyObject *callback = NULL; + PyObject *result = NULL; + + if (PyArg_UnpackTuple(args, "ref", 1, 2, &object, &callback)) { + result = PyWeakref_NewRef(object, callback); + } + return result; + } + + The call to :cfunc:`PyArg_UnpackTuple` in this example is entirely equivalent to + this call to :cfunc:`PyArg_ParseTuple`:: + + PyArg_ParseTuple(args, "O|O:ref", &object, &callback) + + .. versionadded:: 2.2 + + +.. cfunction:: PyObject* Py_BuildValue(const char *format, ...) + + Create a new value based on a format string similar to those accepted by the + :cfunc:`PyArg_Parse\*` family of functions and a sequence of values. Returns + the value or *NULL* in the case of an error; an exception will be raised if + *NULL* is returned. + + :cfunc:`Py_BuildValue` does not always build a tuple. It builds a tuple only if + its format string contains two or more format units. If the format string is + empty, it returns ``None``; if it contains exactly one format unit, it returns + whatever object is described by that format unit. To force it to return a tuple + of size 0 or one, parenthesize the format string. + + When memory buffers are passed as parameters to supply data to build objects, as + for the ``s`` and ``s#`` formats, the required data is copied. Buffers provided + by the caller are never referenced by the objects created by + :cfunc:`Py_BuildValue`. In other words, if your code invokes :cfunc:`malloc` + and passes the allocated memory to :cfunc:`Py_BuildValue`, your code is + responsible for calling :cfunc:`free` for that memory once + :cfunc:`Py_BuildValue` returns. + + In the following description, the quoted form is the format unit; the entry in + (round) parentheses is the Python object type that the format unit will return; + and the entry in [square] brackets is the type of the C value(s) to be passed. + + The characters space, tab, colon and comma are ignored in format strings (but + not within format units such as ``s#``). This can be used to make long format + strings a tad more readable. + + ``s`` (string) [char \*] + Convert a null-terminated C string to a Python object. If the C string pointer + is *NULL*, ``None`` is used. + + ``s#`` (string) [char \*, int] + Convert a C string and its length to a Python object. If the C string pointer + is *NULL*, the length is ignored and ``None`` is returned. + + ``z`` (string or ``None``) [char \*] + Same as ``s``. + + ``z#`` (string or ``None``) [char \*, int] + Same as ``s#``. + + ``u`` (Unicode string) [Py_UNICODE \*] + Convert a null-terminated buffer of Unicode (UCS-2 or UCS-4) data to a Python + Unicode object. If the Unicode buffer pointer is *NULL*, ``None`` is returned. + + ``u#`` (Unicode string) [Py_UNICODE \*, int] + Convert a Unicode (UCS-2 or UCS-4) data buffer and its length to a Python + Unicode object. If the Unicode buffer pointer is *NULL*, the length is ignored + and ``None`` is returned. + + ``i`` (integer) [int] + Convert a plain C :ctype:`int` to a Python integer object. + + ``b`` (integer) [char] + Convert a plain C :ctype:`char` to a Python integer object. + + ``h`` (integer) [short int] + Convert a plain C :ctype:`short int` to a Python integer object. + + ``l`` (integer) [long int] + Convert a C :ctype:`long int` to a Python integer object. + + ``B`` (integer) [unsigned char] + Convert a C :ctype:`unsigned char` to a Python integer object. + + ``H`` (integer) [unsigned short int] + Convert a C :ctype:`unsigned short int` to a Python integer object. + + ``I`` (integer/long) [unsigned int] + Convert a C :ctype:`unsigned int` to a Python integer object or a Python long + integer object, if it is larger than ``sys.maxint``. + + ``k`` (integer/long) [unsigned long] + Convert a C :ctype:`unsigned long` to a Python integer object or a Python long + integer object, if it is larger than ``sys.maxint``. + + ``L`` (long) [PY_LONG_LONG] + Convert a C :ctype:`long long` to a Python long integer object. Only available + on platforms that support :ctype:`long long`. + + ``K`` (long) [unsigned PY_LONG_LONG] + Convert a C :ctype:`unsigned long long` to a Python long integer object. Only + available on platforms that support :ctype:`unsigned long long`. + + ``n`` (int) [Py_ssize_t] + Convert a C :ctype:`Py_ssize_t` to a Python integer or long integer. + + .. versionadded:: 2.5 + + ``c`` (string of length 1) [char] + Convert a C :ctype:`int` representing a character to a Python string of length + 1. + + ``d`` (float) [double] + Convert a C :ctype:`double` to a Python floating point number. + + ``f`` (float) [float] + Same as ``d``. + + ``D`` (complex) [Py_complex \*] + Convert a C :ctype:`Py_complex` structure to a Python complex number. + + ``O`` (object) [PyObject \*] + Pass a Python object untouched (except for its reference count, which is + incremented by one). If the object passed in is a *NULL* pointer, it is assumed + that this was caused because the call producing the argument found an error and + set an exception. Therefore, :cfunc:`Py_BuildValue` will return *NULL* but won't + raise an exception. If no exception has been raised yet, :exc:`SystemError` is + set. + + ``S`` (object) [PyObject \*] + Same as ``O``. + + ``N`` (object) [PyObject \*] + Same as ``O``, except it doesn't increment the reference count on the object. + Useful when the object is created by a call to an object constructor in the + argument list. + + ``O&`` (object) [*converter*, *anything*] + Convert *anything* to a Python object through a *converter* function. The + function is called with *anything* (which should be compatible with :ctype:`void + \*`) as its argument and should return a "new" Python object, or *NULL* if an + error occurred. + + ``(items)`` (tuple) [*matching-items*] + Convert a sequence of C values to a Python tuple with the same number of items. + + ``[items]`` (list) [*matching-items*] + Convert a sequence of C values to a Python list with the same number of items. + + ``{items}`` (dictionary) [*matching-items*] + Convert a sequence of C values to a Python dictionary. Each pair of consecutive + C values adds one item to the dictionary, serving as key and value, + respectively. + + If there is an error in the format string, the :exc:`SystemError` exception is + set and *NULL* returned. Added: python/trunk/Doc/c-api/conversion.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/c-api/conversion.rst Sat Jan 19 23:14:27 2008 @@ -0,0 +1,103 @@ +.. highlightlang:: c + +.. _string-conversion: + +String conversion and formatting +================================ + +Functions for number conversion and formatted string output. + + +.. cfunction:: int PyOS_snprintf(char *str, size_t size, const char *format, ...) + + Output not more than *size* bytes to *str* according to the format string + *format* and the extra arguments. See the Unix man page :manpage:`snprintf(2)`. + + +.. cfunction:: int PyOS_vsnprintf(char *str, size_t size, const char *format, va_list va) + + Output not more than *size* bytes to *str* according to the format string + *format* and the variable argument list *va*. Unix man page + :manpage:`vsnprintf(2)`. + +:cfunc:`PyOS_snprintf` and :cfunc:`PyOS_vsnprintf` wrap the Standard C library +functions :cfunc:`snprintf` and :cfunc:`vsnprintf`. Their purpose is to +guarantee consistent behavior in corner cases, which the Standard C functions do +not. + +The wrappers ensure that *str*[*size*-1] is always ``'\0'`` upon return. They +never write more than *size* bytes (including the trailing ``'\0'`` into str. +Both functions require that ``str != NULL``, ``size > 0`` and ``format != +NULL``. + +If the platform doesn't have :cfunc:`vsnprintf` and the buffer size needed to +avoid truncation exceeds *size* by more than 512 bytes, Python aborts with a +*Py_FatalError*. + +The return value (*rv*) for these functions should be interpreted as follows: + +* When ``0 <= rv < size``, the output conversion was successful and *rv* + characters were written to *str* (excluding the trailing ``'\0'`` byte at + *str*[*rv*]). + +* When ``rv >= size``, the output conversion was truncated and a buffer with + ``rv + 1`` bytes would have been needed to succeed. *str*[*size*-1] is ``'\0'`` + in this case. + +* When ``rv < 0``, "something bad happened." *str*[*size*-1] is ``'\0'`` in + this case too, but the rest of *str* is undefined. The exact cause of the error + depends on the underlying platform. + +The following functions provide locale-independent string to number conversions. + + +.. cfunction:: double PyOS_ascii_strtod(const char *nptr, char **endptr) + + Convert a string to a :ctype:`double`. This function behaves like the Standard C + function :cfunc:`strtod` does in the C locale. It does this without changing the + current locale, since that would not be thread-safe. + + :cfunc:`PyOS_ascii_strtod` should typically be used for reading configuration + files or other non-user input that should be locale independent. + + .. versionadded:: 2.4 + + See the Unix man page :manpage:`strtod(2)` for details. + + +.. cfunction:: char * PyOS_ascii_formatd(char *buffer, size_t buf_len, const char *format, double d) + + Convert a :ctype:`double` to a string using the ``'.'`` as the decimal + separator. *format* is a :cfunc:`printf`\ -style format string specifying the + number format. Allowed conversion characters are ``'e'``, ``'E'``, ``'f'``, + ``'F'``, ``'g'`` and ``'G'``. + + The return value is a pointer to *buffer* with the converted string or NULL if + the conversion failed. + + .. versionadded:: 2.4 + + +.. cfunction:: double PyOS_ascii_atof(const char *nptr) + + Convert a string to a :ctype:`double` in a locale-independent way. + + .. versionadded:: 2.4 + + See the Unix man page :manpage:`atof(2)` for details. + + +.. cfunction:: char * PyOS_stricmp(char *s1, char *s2) + + Case insensitive comparsion of strings. The functions works almost + identical to :cfunc:`strcmp` except that it ignores the case. + + .. versionadded:: 2.6 + + +.. cfunction:: char * PyOS_strnicmp(char *s1, char *s2, Py_ssize_t size) + + Case insensitive comparsion of strings. The functions works almost + identical to :cfunc:`strncmp` except that it ignores the case. + + .. versionadded:: 2.6 Added: python/trunk/Doc/c-api/import.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/c-api/import.rst Sat Jan 19 23:14:27 2008 @@ -0,0 +1,254 @@ +.. highlightlang:: c + +.. _importing: + +Importing Modules +================= + + +.. cfunction:: PyObject* PyImport_ImportModule(const char *name) + + .. index:: + single: package variable; __all__ + single: __all__ (package variable) + single: modules (in module sys) + + This is a simplified interface to :cfunc:`PyImport_ImportModuleEx` below, + leaving the *globals* and *locals* arguments set to *NULL* and *level* set + to 0. When the *name* + argument contains a dot (when it specifies a submodule of a package), the + *fromlist* argument is set to the list ``['*']`` so that the return value is the + named module rather than the top-level package containing it as would otherwise + be the case. (Unfortunately, this has an additional side effect when *name* in + fact specifies a subpackage instead of a submodule: the submodules specified in + the package's ``__all__`` variable are loaded.) Return a new reference to the + imported module, or *NULL* with an exception set on failure. Before Python 2.4, + the module may still be created in the failure case --- examine ``sys.modules`` + to find out. Starting with Python 2.4, a failing import of a module no longer + leaves the module in ``sys.modules``. + + .. versionchanged:: 2.4 + failing imports remove incomplete module objects. + + .. versionchanged:: 2.6 + always use absolute imports + + +.. cfunction:: PyObject* PyImport_ImportModuleNoBlock(const char *name) + + This version of :cfunc:`PyImport_ImportModule` does not block. It's intended + to be used in C functions that import other modules to execute a function. + The import may block if another thread holds the import lock. The function + :cfunc:`PyImport_ImportModuleNoBlock` never blocks. It first tries to fetch + the module from sys.modules and falls back to :cfunc:`PyImport_ImportModule` + unless the lock is held, in which case the function will raise an + :exc:`ImportError`. + + .. versionadded:: 2.6 + + +.. cfunction:: PyObject* PyImport_ImportModuleEx(char *name, PyObject *globals, PyObject *locals, PyObject *fromlist) + + .. index:: builtin: __import__ + + Import a module. This is best described by referring to the built-in Python + function :func:`__import__`, as the standard :func:`__import__` function calls + this function directly. + + The return value is a new reference to the imported module or top-level package, + or *NULL* with an exception set on failure (before Python 2.4, the module may + still be created in this case). Like for :func:`__import__`, the return value + when a submodule of a package was requested is normally the top-level package, + unless a non-empty *fromlist* was given. + + .. versionchanged:: 2.4 + failing imports remove incomplete module objects. + + .. versionchanged:: 2.6 + The function is an alias for :cfunc:`PyImport_ImportModuleLevel` with + -1 as level, meaning relative import. + + +.. cfunction:: PyObject* PyImport_ImportModuleLevel(char *name, PyObject *globals, PyObject *locals, PyObject *fromlist, int level) + + Import a module. This is best described by referring to the built-in Python + function :func:`__import__`, as the standard :func:`__import__` function calls + this function directly. + + The return value is a new reference to the imported module or top-level package, + or *NULL* with an exception set on failure. Like for :func:`__import__`, + the return value when a submodule of a package was requested is normally the + top-level package, unless a non-empty *fromlist* was given. + + .. versionadded:: 2.5 + + +.. cfunction:: PyObject* PyImport_Import(PyObject *name) + + .. index:: + module: rexec + module: ihooks + + This is a higher-level interface that calls the current "import hook function". + It invokes the :func:`__import__` function from the ``__builtins__`` of the + current globals. This means that the import is done using whatever import hooks + are installed in the current environment, e.g. by :mod:`rexec` or :mod:`ihooks`. + + .. versionchanged:: 2.6 + always use absolute imports + + +.. cfunction:: PyObject* PyImport_ReloadModule(PyObject *m) + + .. index:: builtin: reload + + Reload a module. This is best described by referring to the built-in Python + function :func:`reload`, as the standard :func:`reload` function calls this + function directly. Return a new reference to the reloaded module, or *NULL* + with an exception set on failure (the module still exists in this case). + + +.. cfunction:: PyObject* PyImport_AddModule(const char *name) + + Return the module object corresponding to a module name. The *name* argument + may be of the form ``package.module``. First check the modules dictionary if + there's one there, and if not, create a new one and insert it in the modules + dictionary. Return *NULL* with an exception set on failure. + + .. note:: + + This function does not load or import the module; if the module wasn't already + loaded, you will get an empty module object. Use :cfunc:`PyImport_ImportModule` + or one of its variants to import a module. Package structures implied by a + dotted name for *name* are not created if not already present. + + +.. cfunction:: PyObject* PyImport_ExecCodeModule(char *name, PyObject *co) + + .. index:: builtin: compile + + Given a module name (possibly of the form ``package.module``) and a code object + read from a Python bytecode file or obtained from the built-in function + :func:`compile`, load the module. Return a new reference to the module object, + or *NULL* with an exception set if an error occurred. Before Python 2.4, the + module could still be created in error cases. Starting with Python 2.4, *name* + is removed from :attr:`sys.modules` in error cases, and even if *name* was already + in :attr:`sys.modules` on entry to :cfunc:`PyImport_ExecCodeModule`. Leaving + incompletely initialized modules in :attr:`sys.modules` is dangerous, as imports of + such modules have no way to know that the module object is an unknown (and + probably damaged with respect to the module author's intents) state. + + This function will reload the module if it was already imported. See + :cfunc:`PyImport_ReloadModule` for the intended way to reload a module. + + If *name* points to a dotted name of the form ``package.module``, any package + structures not already created will still not be created. + + .. versionchanged:: 2.4 + *name* is removed from :attr:`sys.modules` in error cases. + + +.. cfunction:: long PyImport_GetMagicNumber() + + Return the magic number for Python bytecode files (a.k.a. :file:`.pyc` and + :file:`.pyo` files). The magic number should be present in the first four bytes + of the bytecode file, in little-endian byte order. + + +.. cfunction:: PyObject* PyImport_GetModuleDict() + + Return the dictionary used for the module administration (a.k.a. + ``sys.modules``). Note that this is a per-interpreter variable. + + +.. cfunction:: void _PyImport_Init() + + Initialize the import mechanism. For internal use only. + + +.. cfunction:: void PyImport_Cleanup() + + Empty the module table. For internal use only. + + +.. cfunction:: void _PyImport_Fini() + + Finalize the import mechanism. For internal use only. + + +.. cfunction:: PyObject* _PyImport_FindExtension(char *, char *) + + For internal use only. + + +.. cfunction:: PyObject* _PyImport_FixupExtension(char *, char *) + + For internal use only. + + +.. cfunction:: int PyImport_ImportFrozenModule(char *name) + + Load a frozen module named *name*. Return ``1`` for success, ``0`` if the + module is not found, and ``-1`` with an exception set if the initialization + failed. To access the imported module on a successful load, use + :cfunc:`PyImport_ImportModule`. (Note the misnomer --- this function would + reload the module if it was already imported.) + + +.. ctype:: struct _frozen + + .. index:: single: freeze utility + + This is the structure type definition for frozen module descriptors, as + generated by the :program:`freeze` utility (see :file:`Tools/freeze/` in the + Python source distribution). Its definition, found in :file:`Include/import.h`, + is:: + + struct _frozen { + char *name; + unsigned char *code; + int size; + }; + + +.. cvar:: struct _frozen* PyImport_FrozenModules + + This pointer is initialized to point to an array of :ctype:`struct _frozen` + records, terminated by one whose members are all *NULL* or zero. When a frozen + module is imported, it is searched in this table. Third-party code could play + tricks with this to provide a dynamically created collection of frozen modules. + + +.. cfunction:: int PyImport_AppendInittab(char *name, void (*initfunc)(void)) + + Add a single module to the existing table of built-in modules. This is a + convenience wrapper around :cfunc:`PyImport_ExtendInittab`, returning ``-1`` if + the table could not be extended. The new module can be imported by the name + *name*, and uses the function *initfunc* as the initialization function called + on the first attempted import. This should be called before + :cfunc:`Py_Initialize`. + + +.. ctype:: struct _inittab + + Structure describing a single entry in the list of built-in modules. Each of + these structures gives the name and initialization function for a module built + into the interpreter. Programs which embed Python may use an array of these + structures in conjunction with :cfunc:`PyImport_ExtendInittab` to provide + additional built-in modules. The structure is defined in + :file:`Include/import.h` as:: + + struct _inittab { + char *name; + void (*initfunc)(void); + }; + + +.. cfunction:: int PyImport_ExtendInittab(struct _inittab *newtab) + + Add a collection of modules to the table of built-in modules. The *newtab* + array must end with a sentinel entry which contains *NULL* for the :attr:`name` + field; failure to provide the sentinel value can result in a memory fault. + Returns ``0`` on success or ``-1`` if insufficient memory could be allocated to + extend the internal table. In the event of failure, no modules are added to the + internal table. This should be called before :cfunc:`Py_Initialize`. Added: python/trunk/Doc/c-api/marshal.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/c-api/marshal.rst Sat Jan 19 23:14:27 2008 @@ -0,0 +1,93 @@ +.. highlightlang:: c + +.. _marshalling-utils: + +Data marshalling support +======================== + +These routines allow C code to work with serialized objects using the same data +format as the :mod:`marshal` module. There are functions to write data into the +serialization format, and additional functions that can be used to read the data +back. Files used to store marshalled data must be opened in binary mode. + +Numeric values are stored with the least significant byte first. + +The module supports two versions of the data format: version 0 is the historical +version, version 1 (new in Python 2.4) shares interned strings in the file, and +upon unmarshalling. *Py_MARSHAL_VERSION* indicates the current file format +(currently 1). + + +.. cfunction:: void PyMarshal_WriteLongToFile(long value, FILE *file, int version) + + Marshal a :ctype:`long` integer, *value*, to *file*. This will only write the + least-significant 32 bits of *value*; regardless of the size of the native + :ctype:`long` type. + + .. versionchanged:: 2.4 + *version* indicates the file format. + + +.. cfunction:: void PyMarshal_WriteObjectToFile(PyObject *value, FILE *file, int version) + + Marshal a Python object, *value*, to *file*. + + .. versionchanged:: 2.4 + *version* indicates the file format. + + +.. cfunction:: PyObject* PyMarshal_WriteObjectToString(PyObject *value, int version) + + Return a string object containing the marshalled representation of *value*. + + .. versionchanged:: 2.4 + *version* indicates the file format. + + +The following functions allow marshalled values to be read back in. + +XXX What about error detection? It appears that reading past the end of the +file will always result in a negative numeric value (where that's relevant), but +it's not clear that negative values won't be handled properly when there's no +error. What's the right way to tell? Should only non-negative values be written +using these routines? + + +.. cfunction:: long PyMarshal_ReadLongFromFile(FILE *file) + + Return a C :ctype:`long` from the data stream in a :ctype:`FILE\*` opened for + reading. Only a 32-bit value can be read in using this function, regardless of + the native size of :ctype:`long`. + + +.. cfunction:: int PyMarshal_ReadShortFromFile(FILE *file) + + Return a C :ctype:`short` from the data stream in a :ctype:`FILE\*` opened for + reading. Only a 16-bit value can be read in using this function, regardless of + the native size of :ctype:`short`. + + +.. cfunction:: PyObject* PyMarshal_ReadObjectFromFile(FILE *file) + + Return a Python object from the data stream in a :ctype:`FILE\*` opened for + reading. On error, sets the appropriate exception (:exc:`EOFError` or + :exc:`TypeError`) and returns *NULL*. + + +.. cfunction:: PyObject* PyMarshal_ReadLastObjectFromFile(FILE *file) + + Return a Python object from the data stream in a :ctype:`FILE\*` opened for + reading. Unlike :cfunc:`PyMarshal_ReadObjectFromFile`, this function assumes + that no further objects will be read from the file, allowing it to aggressively + load file data into memory so that the de-serialization can operate from data in + memory rather than reading a byte at a time from the file. Only use these + variant if you are certain that you won't be reading anything else from the + file. On error, sets the appropriate exception (:exc:`EOFError` or + :exc:`TypeError`) and returns *NULL*. + + +.. cfunction:: PyObject* PyMarshal_ReadObjectFromString(char *string, Py_ssize_t len) + + Return a Python object from the data stream in a character buffer containing + *len* bytes pointed to by *string*. On error, sets the appropriate exception + (:exc:`EOFError` or :exc:`TypeError`) and returns *NULL*. Added: python/trunk/Doc/c-api/reflection.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/c-api/reflection.rst Sat Jan 19 23:14:27 2008 @@ -0,0 +1,50 @@ +.. highlightlang:: c + +.. _reflection: + +Reflection +========== + +.. cfunction:: PyObject* PyEval_GetBuiltins() + + Return a dictionary of the builtins in the current execution frame, + or the interpreter of the thread state if no frame is currently executing. + + +.. cfunction:: PyObject* PyEval_GetLocals() + + Return a dictionary of the local variables in the current execution frame, + or *NULL* if no frame is currently executing. + + +.. cfunction:: PyObject* PyEval_GetGlobals() + + Return a dictionary of the global variables in the current execution frame, + or *NULL* if no frame is currently executing. + + +.. cfunction:: PyFrameObject* PyEval_GetFrame() + + Return the current thread state's frame, which is *NULL* if no frame is + currently executing. + + +.. cfunction:: int PyEval_GetRestricted() + + If there is a current frame and it is executing in restricted mode, return true, + otherwise false. + + +.. cfunction:: const char* PyEval_GetFuncName(PyObject *func) + + Return the name of *func* if it is a function, class or instance object, else the + name of *func*\s type. + + +.. cfunction:: const char* PyEval_GetFuncDesc(PyObject *func) + + Return a description string, depending on the type of *func*. + Return values include "()" for functions and methods, " constructor", + " instance", and " object". Concatenated with the result of + :cfunc:`PyEval_GetFuncName`, the result will be a description of + *func*. Added: python/trunk/Doc/c-api/sys.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/c-api/sys.rst Sat Jan 19 23:14:27 2008 @@ -0,0 +1,158 @@ +.. highlightlang:: c + +.. _os: + +Operating System Utilities +========================== + + +.. cfunction:: int Py_FdIsInteractive(FILE *fp, const char *filename) + + Return true (nonzero) if the standard I/O file *fp* with name *filename* is + deemed interactive. This is the case for files for which ``isatty(fileno(fp))`` + is true. If the global flag :cdata:`Py_InteractiveFlag` is true, this function + also returns true if the *filename* pointer is *NULL* or if the name is equal to + one of the strings ``''`` or ``'???'``. + + +.. cfunction:: long PyOS_GetLastModificationTime(char *filename) + + Return the time of last modification of the file *filename*. The result is + encoded in the same way as the timestamp returned by the standard C library + function :cfunc:`time`. + + +.. cfunction:: void PyOS_AfterFork() + + Function to update some internal state after a process fork; this should be + called in the new process if the Python interpreter will continue to be used. + If a new executable is loaded into the new process, this function does not need + to be called. + + +.. cfunction:: int PyOS_CheckStack() + + Return true when the interpreter runs out of stack space. This is a reliable + check, but is only available when :const:`USE_STACKCHECK` is defined (currently + on Windows using the Microsoft Visual C++ compiler). :const:`USE_STACKCHECK` + will be defined automatically; you should never change the definition in your + own code. + + +.. cfunction:: PyOS_sighandler_t PyOS_getsig(int i) + + Return the current signal handler for signal *i*. This is a thin wrapper around + either :cfunc:`sigaction` or :cfunc:`signal`. Do not call those functions + directly! :ctype:`PyOS_sighandler_t` is a typedef alias for :ctype:`void + (\*)(int)`. + + +.. cfunction:: PyOS_sighandler_t PyOS_setsig(int i, PyOS_sighandler_t h) + + Set the signal handler for signal *i* to be *h*; return the old signal handler. + This is a thin wrapper around either :cfunc:`sigaction` or :cfunc:`signal`. Do + not call those functions directly! :ctype:`PyOS_sighandler_t` is a typedef + alias for :ctype:`void (\*)(int)`. + +.. _systemfunctions: + +System Functions +================ + +These are utility functions that make functionality from the :mod:`sys` module +accessible to C code. They all work with the current interpreter thread's +:mod:`sys` module's dict, which is contained in the internal thread state structure. + +.. cfunction:: PyObject *PySys_GetObject(char *name) + + Return the object *name* from the :mod:`sys` module or *NULL* if it does + not exist, without setting an exception. + +.. cfunction:: FILE *PySys_GetFile(char *name, FILE *def) + + Return the :ctype:`FILE*` associated with the object *name* in the + :mod:`sys` module, or *def* if *name* is not in the module or is not associated + with a :ctype:`FILE*`. + +.. cfunction:: int PySys_SetObject(char *name, PyObject *v) + + Set *name* in the :mod:`sys` module to *v* unless *v* is *NULL*, in which + case *name* is deleted from the sys module. Returns ``0`` on success, ``-1`` + on error. + +.. cfunction:: void PySys_ResetWarnOptions(void) + + Reset :data:`sys.warnoptions` to an empty list. + +.. cfunction:: void PySys_AddWarnOption(char *s) + + Append *s* to :data:`sys.warnoptions`. + +.. cfunction:: void PySys_SetPath(char *path) + + Set :data:`sys.path` to a list object of paths found in *path* which should + be a list of paths separated with the platform's search path delimiter + (``:`` on Unix, ``;`` on Windows). + +.. cfunction:: void PySys_WriteStdout(const char *format, ...) + + Write the output string described by *format* to :data:`sys.stdout`. No + exceptions are raised, even if truncation occurs (see below). + + *format* should limit the total size of the formatted output string to + 1000 bytes or less -- after 1000 bytes, the output string is truncated. + In particular, this means that no unrestricted "%s" formats should occur; + these should be limited using "%.s" where is a decimal number + calculated so that plus the maximum size of other formatted text does not + exceed 1000 bytes. Also watch out for "%f", which can print hundreds of + digits for very large numbers. + + If a problem occurs, or :data:`sys.stdout` is unset, the formatted message + is written to the real (C level) *stdout*. + +.. cfunction:: void PySys_WriteStderr(const char *format, ...) + + As above, but write to :data:`sys.stderr` or *stderr* instead. + + +.. _processcontrol: + +Process Control +=============== + + +.. cfunction:: void Py_FatalError(const char *message) + + .. index:: single: abort() + + Print a fatal error message and kill the process. No cleanup is performed. + This function should only be invoked when a condition is detected that would + make it dangerous to continue using the Python interpreter; e.g., when the + object administration appears to be corrupted. On Unix, the standard C library + function :cfunc:`abort` is called which will attempt to produce a :file:`core` + file. + + +.. cfunction:: void Py_Exit(int status) + + .. index:: + single: Py_Finalize() + single: exit() + + Exit the current process. This calls :cfunc:`Py_Finalize` and then calls the + standard C library function ``exit(status)``. + + +.. cfunction:: int Py_AtExit(void (*func) ()) + + .. index:: + single: Py_Finalize() + single: cleanup functions + + Register a cleanup function to be called by :cfunc:`Py_Finalize`. The cleanup + function will be called with no arguments and should return no value. At most + 32 cleanup functions can be registered. When the registration is successful, + :cfunc:`Py_AtExit` returns ``0``; on failure, it returns ``-1``. The cleanup + function registered last is called first. Each cleanup function will be called + at most once. Since Python's internal finalization will have completed before + the cleanup function, no Python APIs should be called by *func*. Modified: python/trunk/Doc/c-api/utilities.rst ============================================================================== --- python/trunk/Doc/c-api/utilities.rst (original) +++ python/trunk/Doc/c-api/utilities.rst Sat Jan 19 23:14:27 2008 @@ -11,1169 +11,11 @@ helping C code be more portable across platforms, using Python modules from C, and parsing function arguments and constructing Python values from C values. +.. toctree:: -.. _os: - -Operating System Utilities -========================== - - -.. cfunction:: int Py_FdIsInteractive(FILE *fp, const char *filename) - - Return true (nonzero) if the standard I/O file *fp* with name *filename* is - deemed interactive. This is the case for files for which ``isatty(fileno(fp))`` - is true. If the global flag :cdata:`Py_InteractiveFlag` is true, this function - also returns true if the *filename* pointer is *NULL* or if the name is equal to - one of the strings ``''`` or ``'???'``. - - -.. cfunction:: long PyOS_GetLastModificationTime(char *filename) - - Return the time of last modification of the file *filename*. The result is - encoded in the same way as the timestamp returned by the standard C library - function :cfunc:`time`. - - -.. cfunction:: void PyOS_AfterFork() - - Function to update some internal state after a process fork; this should be - called in the new process if the Python interpreter will continue to be used. - If a new executable is loaded into the new process, this function does not need - to be called. - - -.. cfunction:: int PyOS_CheckStack() - - Return true when the interpreter runs out of stack space. This is a reliable - check, but is only available when :const:`USE_STACKCHECK` is defined (currently - on Windows using the Microsoft Visual C++ compiler). :const:`USE_STACKCHECK` - will be defined automatically; you should never change the definition in your - own code. - - -.. cfunction:: PyOS_sighandler_t PyOS_getsig(int i) - - Return the current signal handler for signal *i*. This is a thin wrapper around - either :cfunc:`sigaction` or :cfunc:`signal`. Do not call those functions - directly! :ctype:`PyOS_sighandler_t` is a typedef alias for :ctype:`void - (\*)(int)`. - - -.. cfunction:: PyOS_sighandler_t PyOS_setsig(int i, PyOS_sighandler_t h) - - Set the signal handler for signal *i* to be *h*; return the old signal handler. - This is a thin wrapper around either :cfunc:`sigaction` or :cfunc:`signal`. Do - not call those functions directly! :ctype:`PyOS_sighandler_t` is a typedef - alias for :ctype:`void (\*)(int)`. - -.. _systemfunctions: - -System Functions -================ - -These are utility functions that make functionality from the :mod:`sys` module -accessible to C code. They all work with the current interpreter thread's -:mod:`sys` module's dict, which is contained in the internal thread state structure. - -.. cfunction:: PyObject *PySys_GetObject(char *name) - - Return the object *name* from the :mod:`sys` module or *NULL* if it does - not exist, without setting an exception. - -.. cfunction:: FILE *PySys_GetFile(char *name, FILE *def) - - Return the :ctype:`FILE*` associated with the object *name* in the - :mod:`sys` module, or *def* if *name* is not in the module or is not associated - with a :ctype:`FILE*`. - -.. cfunction:: int PySys_SetObject(char *name, PyObject *v) - - Set *name* in the :mod:`sys` module to *v* unless *v* is *NULL*, in which - case *name* is deleted from the sys module. Returns ``0`` on success, ``-1`` - on error. - -.. cfunction:: void PySys_ResetWarnOptions(void) - - Reset :data:`sys.warnoptions` to an empty list. - -.. cfunction:: void PySys_AddWarnOption(char *s) - - Append *s* to :data:`sys.warnoptions`. - -.. cfunction:: void PySys_SetPath(char *path) - - Set :data:`sys.path` to a list object of paths found in *path* which should - be a list of paths separated with the platform's search path delimiter - (``:`` on Unix, ``;`` on Windows). - -.. cfunction:: void PySys_WriteStdout(const char *format, ...) - - Write the output string described by *format* to :data:`sys.stdout`. No - exceptions are raised, even if truncation occurs (see below). - - *format* should limit the total size of the formatted output string to - 1000 bytes or less -- after 1000 bytes, the output string is truncated. - In particular, this means that no unrestricted "%s" formats should occur; - these should be limited using "%.s" where is a decimal number - calculated so that plus the maximum size of other formatted text does not - exceed 1000 bytes. Also watch out for "%f", which can print hundreds of - digits for very large numbers. - - If a problem occurs, or :data:`sys.stdout` is unset, the formatted message - is written to the real (C level) *stdout*. - -.. cfunction:: void PySys_WriteStderr(const char *format, ...) - - As above, but write to :data:`sys.stderr` or *stderr* instead. - - -.. _processcontrol: - -Process Control -=============== - - -.. cfunction:: void Py_FatalError(const char *message) - - .. index:: single: abort() - - Print a fatal error message and kill the process. No cleanup is performed. - This function should only be invoked when a condition is detected that would - make it dangerous to continue using the Python interpreter; e.g., when the - object administration appears to be corrupted. On Unix, the standard C library - function :cfunc:`abort` is called which will attempt to produce a :file:`core` - file. - - -.. cfunction:: void Py_Exit(int status) - - .. index:: - single: Py_Finalize() - single: exit() - - Exit the current process. This calls :cfunc:`Py_Finalize` and then calls the - standard C library function ``exit(status)``. - - -.. cfunction:: int Py_AtExit(void (*func) ()) - - .. index:: - single: Py_Finalize() - single: cleanup functions - - Register a cleanup function to be called by :cfunc:`Py_Finalize`. The cleanup - function will be called with no arguments and should return no value. At most - 32 cleanup functions can be registered. When the registration is successful, - :cfunc:`Py_AtExit` returns ``0``; on failure, it returns ``-1``. The cleanup - function registered last is called first. Each cleanup function will be called - at most once. Since Python's internal finalization will have completed before - the cleanup function, no Python APIs should be called by *func*. - - -.. _importing: - -Importing Modules -================= - - -.. cfunction:: PyObject* PyImport_ImportModule(const char *name) - - .. index:: - single: package variable; __all__ - single: __all__ (package variable) - single: modules (in module sys) - - This is a simplified interface to :cfunc:`PyImport_ImportModuleEx` below, - leaving the *globals* and *locals* arguments set to *NULL* and *level* set - to 0. When the *name* - argument contains a dot (when it specifies a submodule of a package), the - *fromlist* argument is set to the list ``['*']`` so that the return value is the - named module rather than the top-level package containing it as would otherwise - be the case. (Unfortunately, this has an additional side effect when *name* in - fact specifies a subpackage instead of a submodule: the submodules specified in - the package's ``__all__`` variable are loaded.) Return a new reference to the - imported module, or *NULL* with an exception set on failure. Before Python 2.4, - the module may still be created in the failure case --- examine ``sys.modules`` - to find out. Starting with Python 2.4, a failing import of a module no longer - leaves the module in ``sys.modules``. - - .. versionchanged:: 2.4 - failing imports remove incomplete module objects. - - .. versionchanged:: 2.6 - always use absolute imports - - -.. cfunction:: PyObject* PyImport_ImportModuleNoBlock(const char *name) - - This version of :cfunc:`PyImport_ImportModule` does not block. It's intended - to be used in C functions that import other modules to execute a function. - The import may block if another thread holds the import lock. The function - :cfunc:`PyImport_ImportModuleNoBlock` never blocks. It first tries to fetch - the module from sys.modules and falls back to :cfunc:`PyImport_ImportModule` - unless the lock is held, in which case the function will raise an - :exc:`ImportError`. - - .. versionadded:: 2.6 - - -.. cfunction:: PyObject* PyImport_ImportModuleEx(char *name, PyObject *globals, PyObject *locals, PyObject *fromlist) - - .. index:: builtin: __import__ - - Import a module. This is best described by referring to the built-in Python - function :func:`__import__`, as the standard :func:`__import__` function calls - this function directly. - - The return value is a new reference to the imported module or top-level package, - or *NULL* with an exception set on failure (before Python 2.4, the module may - still be created in this case). Like for :func:`__import__`, the return value - when a submodule of a package was requested is normally the top-level package, - unless a non-empty *fromlist* was given. - - .. versionchanged:: 2.4 - failing imports remove incomplete module objects. - - .. versionchanged:: 2.6 - The function is an alias for :cfunc:`PyImport_ImportModuleLevel` with - -1 as level, meaning relative import. - - -.. cfunction:: PyObject* PyImport_ImportModuleLevel(char *name, PyObject *globals, PyObject *locals, PyObject *fromlist, int level) - - Import a module. This is best described by referring to the built-in Python - function :func:`__import__`, as the standard :func:`__import__` function calls - this function directly. - - The return value is a new reference to the imported module or top-level package, - or *NULL* with an exception set on failure. Like for :func:`__import__`, - the return value when a submodule of a package was requested is normally the - top-level package, unless a non-empty *fromlist* was given. - - .. versionadded:: 2.5 - - -.. cfunction:: PyObject* PyImport_Import(PyObject *name) - - .. index:: - module: rexec - module: ihooks - - This is a higher-level interface that calls the current "import hook function". - It invokes the :func:`__import__` function from the ``__builtins__`` of the - current globals. This means that the import is done using whatever import hooks - are installed in the current environment, e.g. by :mod:`rexec` or :mod:`ihooks`. - - .. versionchanged:: 2.6 - always use absolute imports - - -.. cfunction:: PyObject* PyImport_ReloadModule(PyObject *m) - - .. index:: builtin: reload - - Reload a module. This is best described by referring to the built-in Python - function :func:`reload`, as the standard :func:`reload` function calls this - function directly. Return a new reference to the reloaded module, or *NULL* - with an exception set on failure (the module still exists in this case). - - -.. cfunction:: PyObject* PyImport_AddModule(const char *name) - - Return the module object corresponding to a module name. The *name* argument - may be of the form ``package.module``. First check the modules dictionary if - there's one there, and if not, create a new one and insert it in the modules - dictionary. Return *NULL* with an exception set on failure. - - .. note:: - - This function does not load or import the module; if the module wasn't already - loaded, you will get an empty module object. Use :cfunc:`PyImport_ImportModule` - or one of its variants to import a module. Package structures implied by a - dotted name for *name* are not created if not already present. - - -.. cfunction:: PyObject* PyImport_ExecCodeModule(char *name, PyObject *co) - - .. index:: builtin: compile - - Given a module name (possibly of the form ``package.module``) and a code object - read from a Python bytecode file or obtained from the built-in function - :func:`compile`, load the module. Return a new reference to the module object, - or *NULL* with an exception set if an error occurred. Before Python 2.4, the - module could still be created in error cases. Starting with Python 2.4, *name* - is removed from :attr:`sys.modules` in error cases, and even if *name* was already - in :attr:`sys.modules` on entry to :cfunc:`PyImport_ExecCodeModule`. Leaving - incompletely initialized modules in :attr:`sys.modules` is dangerous, as imports of - such modules have no way to know that the module object is an unknown (and - probably damaged with respect to the module author's intents) state. - - This function will reload the module if it was already imported. See - :cfunc:`PyImport_ReloadModule` for the intended way to reload a module. - - If *name* points to a dotted name of the form ``package.module``, any package - structures not already created will still not be created. - - .. versionchanged:: 2.4 - *name* is removed from :attr:`sys.modules` in error cases. - - -.. cfunction:: long PyImport_GetMagicNumber() - - Return the magic number for Python bytecode files (a.k.a. :file:`.pyc` and - :file:`.pyo` files). The magic number should be present in the first four bytes - of the bytecode file, in little-endian byte order. - - -.. cfunction:: PyObject* PyImport_GetModuleDict() - - Return the dictionary used for the module administration (a.k.a. - ``sys.modules``). Note that this is a per-interpreter variable. - - -.. cfunction:: void _PyImport_Init() - - Initialize the import mechanism. For internal use only. - - -.. cfunction:: void PyImport_Cleanup() - - Empty the module table. For internal use only. - - -.. cfunction:: void _PyImport_Fini() - - Finalize the import mechanism. For internal use only. - - -.. cfunction:: PyObject* _PyImport_FindExtension(char *, char *) - - For internal use only. - - -.. cfunction:: PyObject* _PyImport_FixupExtension(char *, char *) - - For internal use only. - - -.. cfunction:: int PyImport_ImportFrozenModule(char *name) - - Load a frozen module named *name*. Return ``1`` for success, ``0`` if the - module is not found, and ``-1`` with an exception set if the initialization - failed. To access the imported module on a successful load, use - :cfunc:`PyImport_ImportModule`. (Note the misnomer --- this function would - reload the module if it was already imported.) - - -.. ctype:: struct _frozen - - .. index:: single: freeze utility - - This is the structure type definition for frozen module descriptors, as - generated by the :program:`freeze` utility (see :file:`Tools/freeze/` in the - Python source distribution). Its definition, found in :file:`Include/import.h`, - is:: - - struct _frozen { - char *name; - unsigned char *code; - int size; - }; - - -.. cvar:: struct _frozen* PyImport_FrozenModules - - This pointer is initialized to point to an array of :ctype:`struct _frozen` - records, terminated by one whose members are all *NULL* or zero. When a frozen - module is imported, it is searched in this table. Third-party code could play - tricks with this to provide a dynamically created collection of frozen modules. - - -.. cfunction:: int PyImport_AppendInittab(char *name, void (*initfunc)(void)) - - Add a single module to the existing table of built-in modules. This is a - convenience wrapper around :cfunc:`PyImport_ExtendInittab`, returning ``-1`` if - the table could not be extended. The new module can be imported by the name - *name*, and uses the function *initfunc* as the initialization function called - on the first attempted import. This should be called before - :cfunc:`Py_Initialize`. - - -.. ctype:: struct _inittab - - Structure describing a single entry in the list of built-in modules. Each of - these structures gives the name and initialization function for a module built - into the interpreter. Programs which embed Python may use an array of these - structures in conjunction with :cfunc:`PyImport_ExtendInittab` to provide - additional built-in modules. The structure is defined in - :file:`Include/import.h` as:: - - struct _inittab { - char *name; - void (*initfunc)(void); - }; - - -.. cfunction:: int PyImport_ExtendInittab(struct _inittab *newtab) - - Add a collection of modules to the table of built-in modules. The *newtab* - array must end with a sentinel entry which contains *NULL* for the :attr:`name` - field; failure to provide the sentinel value can result in a memory fault. - Returns ``0`` on success or ``-1`` if insufficient memory could be allocated to - extend the internal table. In the event of failure, no modules are added to the - internal table. This should be called before :cfunc:`Py_Initialize`. - - -.. _marshalling-utils: - -Data marshalling support -======================== - -These routines allow C code to work with serialized objects using the same data -format as the :mod:`marshal` module. There are functions to write data into the -serialization format, and additional functions that can be used to read the data -back. Files used to store marshalled data must be opened in binary mode. - -Numeric values are stored with the least significant byte first. - -The module supports two versions of the data format: version 0 is the historical -version, version 1 (new in Python 2.4) shares interned strings in the file, and -upon unmarshalling. *Py_MARSHAL_VERSION* indicates the current file format -(currently 1). - - -.. cfunction:: void PyMarshal_WriteLongToFile(long value, FILE *file, int version) - - Marshal a :ctype:`long` integer, *value*, to *file*. This will only write the - least-significant 32 bits of *value*; regardless of the size of the native - :ctype:`long` type. - - .. versionchanged:: 2.4 - *version* indicates the file format. - - -.. cfunction:: void PyMarshal_WriteObjectToFile(PyObject *value, FILE *file, int version) - - Marshal a Python object, *value*, to *file*. - - .. versionchanged:: 2.4 - *version* indicates the file format. - - -.. cfunction:: PyObject* PyMarshal_WriteObjectToString(PyObject *value, int version) - - Return a string object containing the marshalled representation of *value*. - - .. versionchanged:: 2.4 - *version* indicates the file format. - - -The following functions allow marshalled values to be read back in. - -XXX What about error detection? It appears that reading past the end of the -file will always result in a negative numeric value (where that's relevant), but -it's not clear that negative values won't be handled properly when there's no -error. What's the right way to tell? Should only non-negative values be written -using these routines? - - -.. cfunction:: long PyMarshal_ReadLongFromFile(FILE *file) - - Return a C :ctype:`long` from the data stream in a :ctype:`FILE\*` opened for - reading. Only a 32-bit value can be read in using this function, regardless of - the native size of :ctype:`long`. - - -.. cfunction:: int PyMarshal_ReadShortFromFile(FILE *file) - - Return a C :ctype:`short` from the data stream in a :ctype:`FILE\*` opened for - reading. Only a 16-bit value can be read in using this function, regardless of - the native size of :ctype:`short`. - - -.. cfunction:: PyObject* PyMarshal_ReadObjectFromFile(FILE *file) - - Return a Python object from the data stream in a :ctype:`FILE\*` opened for - reading. On error, sets the appropriate exception (:exc:`EOFError` or - :exc:`TypeError`) and returns *NULL*. - - -.. cfunction:: PyObject* PyMarshal_ReadLastObjectFromFile(FILE *file) - - Return a Python object from the data stream in a :ctype:`FILE\*` opened for - reading. Unlike :cfunc:`PyMarshal_ReadObjectFromFile`, this function assumes - that no further objects will be read from the file, allowing it to aggressively - load file data into memory so that the de-serialization can operate from data in - memory rather than reading a byte at a time from the file. Only use these - variant if you are certain that you won't be reading anything else from the - file. On error, sets the appropriate exception (:exc:`EOFError` or - :exc:`TypeError`) and returns *NULL*. - - -.. cfunction:: PyObject* PyMarshal_ReadObjectFromString(char *string, Py_ssize_t len) - - Return a Python object from the data stream in a character buffer containing - *len* bytes pointed to by *string*. On error, sets the appropriate exception - (:exc:`EOFError` or :exc:`TypeError`) and returns *NULL*. - - -.. _arg-parsing: - -Parsing arguments and building values -===================================== - -These functions are useful when creating your own extensions functions and -methods. Additional information and examples are available in -:ref:`extending-index`. - -The first three of these functions described, :cfunc:`PyArg_ParseTuple`, -:cfunc:`PyArg_ParseTupleAndKeywords`, and :cfunc:`PyArg_Parse`, all use *format -strings* which are used to tell the function about the expected arguments. The -format strings use the same syntax for each of these functions. - -A format string consists of zero or more "format units." A format unit -describes one Python object; it is usually a single character or a parenthesized -sequence of format units. With a few exceptions, a format unit that is not a -parenthesized sequence normally corresponds to a single address argument to -these functions. In the following description, the quoted form is the format -unit; the entry in (round) parentheses is the Python object type that matches -the format unit; and the entry in [square] brackets is the type of the C -variable(s) whose address should be passed. - -``s`` (string or Unicode object) [const char \*] - Convert a Python string or Unicode object to a C pointer to a character string. - You must not provide storage for the string itself; a pointer to an existing - string is stored into the character pointer variable whose address you pass. - The C string is NUL-terminated. The Python string must not contain embedded NUL - bytes; if it does, a :exc:`TypeError` exception is raised. Unicode objects are - converted to C strings using the default encoding. If this conversion fails, a - :exc:`UnicodeError` is raised. - -``s#`` (string, Unicode or any read buffer compatible object) [const char \*, int] - This variant on ``s`` stores into two C variables, the first one a pointer to a - character string, the second one its length. In this case the Python string may - contain embedded null bytes. Unicode objects pass back a pointer to the default - encoded string version of the object if such a conversion is possible. All - other read-buffer compatible objects pass back a reference to the raw internal - data representation. - -``z`` (string or ``None``) [const char \*] - Like ``s``, but the Python object may also be ``None``, in which case the C - pointer is set to *NULL*. - -``z#`` (string or ``None`` or any read buffer compatible object) [const char \*, int] - This is to ``s#`` as ``z`` is to ``s``. - -``u`` (Unicode object) [Py_UNICODE \*] - Convert a Python Unicode object to a C pointer to a NUL-terminated buffer of - 16-bit Unicode (UTF-16) data. As with ``s``, there is no need to provide - storage for the Unicode data buffer; a pointer to the existing Unicode data is - stored into the :ctype:`Py_UNICODE` pointer variable whose address you pass. - -``u#`` (Unicode object) [Py_UNICODE \*, int] - This variant on ``u`` stores into two C variables, the first one a pointer to a - Unicode data buffer, the second one its length. Non-Unicode objects are handled - by interpreting their read-buffer pointer as pointer to a :ctype:`Py_UNICODE` - array. - -``es`` (string, Unicode object or character buffer compatible object) [const char \*encoding, char \*\*buffer] - This variant on ``s`` is used for encoding Unicode and objects convertible to - Unicode into a character buffer. It only works for encoded data without embedded - NUL bytes. - - This format requires two arguments. The first is only used as input, and - must be a :ctype:`const char\*` which points to the name of an encoding as a - NUL-terminated string, or *NULL*, in which case the default encoding is used. - An exception is raised if the named encoding is not known to Python. The - second argument must be a :ctype:`char\*\*`; the value of the pointer it - references will be set to a buffer with the contents of the argument text. - The text will be encoded in the encoding specified by the first argument. - - :cfunc:`PyArg_ParseTuple` will allocate a buffer of the needed size, copy the - encoded data into this buffer and adjust *\*buffer* to reference the newly - allocated storage. The caller is responsible for calling :cfunc:`PyMem_Free` to - free the allocated buffer after use. - -``et`` (string, Unicode object or character buffer compatible object) [const char \*encoding, char \*\*buffer] - Same as ``es`` except that 8-bit string objects are passed through without - recoding them. Instead, the implementation assumes that the string object uses - the encoding passed in as parameter. - -``es#`` (string, Unicode object or character buffer compatible object) [const char \*encoding, char \*\*buffer, int \*buffer_length] - This variant on ``s#`` is used for encoding Unicode and objects convertible to - Unicode into a character buffer. Unlike the ``es`` format, this variant allows - input data which contains NUL characters. - - It requires three arguments. The first is only used as input, and must be a - :ctype:`const char\*` which points to the name of an encoding as a - NUL-terminated string, or *NULL*, in which case the default encoding is used. - An exception is raised if the named encoding is not known to Python. The - second argument must be a :ctype:`char\*\*`; the value of the pointer it - references will be set to a buffer with the contents of the argument text. - The text will be encoded in the encoding specified by the first argument. - The third argument must be a pointer to an integer; the referenced integer - will be set to the number of bytes in the output buffer. - - There are two modes of operation: - - If *\*buffer* points a *NULL* pointer, the function will allocate a buffer of - the needed size, copy the encoded data into this buffer and set *\*buffer* to - reference the newly allocated storage. The caller is responsible for calling - :cfunc:`PyMem_Free` to free the allocated buffer after usage. - - If *\*buffer* points to a non-*NULL* pointer (an already allocated buffer), - :cfunc:`PyArg_ParseTuple` will use this location as the buffer and interpret the - initial value of *\*buffer_length* as the buffer size. It will then copy the - encoded data into the buffer and NUL-terminate it. If the buffer is not large - enough, a :exc:`ValueError` will be set. - - In both cases, *\*buffer_length* is set to the length of the encoded data - without the trailing NUL byte. - -``et#`` (string, Unicode object or character buffer compatible object) [const char \*encoding, char \*\*buffer] - Same as ``es#`` except that string objects are passed through without recoding - them. Instead, the implementation assumes that the string object uses the - encoding passed in as parameter. - -``b`` (integer) [char] - Convert a Python integer to a tiny int, stored in a C :ctype:`char`. - -``B`` (integer) [unsigned char] - Convert a Python integer to a tiny int without overflow checking, stored in a C - :ctype:`unsigned char`. - - .. versionadded:: 2.3 - -``h`` (integer) [short int] - Convert a Python integer to a C :ctype:`short int`. - -``H`` (integer) [unsigned short int] - Convert a Python integer to a C :ctype:`unsigned short int`, without overflow - checking. - - .. versionadded:: 2.3 - -``i`` (integer) [int] - Convert a Python integer to a plain C :ctype:`int`. - -``I`` (integer) [unsigned int] - Convert a Python integer to a C :ctype:`unsigned int`, without overflow - checking. - - .. versionadded:: 2.3 - -``l`` (integer) [long int] - Convert a Python integer to a C :ctype:`long int`. - -``k`` (integer) [unsigned long] - Convert a Python integer or long integer to a C :ctype:`unsigned long` without - overflow checking. - - .. versionadded:: 2.3 - -``L`` (integer) [PY_LONG_LONG] - Convert a Python integer to a C :ctype:`long long`. This format is only - available on platforms that support :ctype:`long long` (or :ctype:`_int64` on - Windows). - -``K`` (integer) [unsigned PY_LONG_LONG] - Convert a Python integer or long integer to a C :ctype:`unsigned long long` - without overflow checking. This format is only available on platforms that - support :ctype:`unsigned long long` (or :ctype:`unsigned _int64` on Windows). - - .. versionadded:: 2.3 - -``n`` (integer) [Py_ssize_t] - Convert a Python integer or long integer to a C :ctype:`Py_ssize_t`. - - .. versionadded:: 2.5 - -``c`` (string of length 1) [char] - Convert a Python character, represented as a string of length 1, to a C - :ctype:`char`. - -``f`` (float) [float] - Convert a Python floating point number to a C :ctype:`float`. - -``d`` (float) [double] - Convert a Python floating point number to a C :ctype:`double`. - -``D`` (complex) [Py_complex] - Convert a Python complex number to a C :ctype:`Py_complex` structure. - -``O`` (object) [PyObject \*] - Store a Python object (without any conversion) in a C object pointer. The C - program thus receives the actual object that was passed. The object's reference - count is not increased. The pointer stored is not *NULL*. - -``O!`` (object) [*typeobject*, PyObject \*] - Store a Python object in a C object pointer. This is similar to ``O``, but - takes two C arguments: the first is the address of a Python type object, the - second is the address of the C variable (of type :ctype:`PyObject\*`) into which - the object pointer is stored. If the Python object does not have the required - type, :exc:`TypeError` is raised. - -``O&`` (object) [*converter*, *anything*] - Convert a Python object to a C variable through a *converter* function. This - takes two arguments: the first is a function, the second is the address of a C - variable (of arbitrary type), converted to :ctype:`void \*`. The *converter* - function in turn is called as follows:: - - status = converter(object, address); - - where *object* is the Python object to be converted and *address* is the - :ctype:`void\*` argument that was passed to the :cfunc:`PyArg_Parse\*` function. - The returned *status* should be ``1`` for a successful conversion and ``0`` if - the conversion has failed. When the conversion fails, the *converter* function - should raise an exception. - -``S`` (string) [PyStringObject \*] - Like ``O`` but requires that the Python object is a string object. Raises - :exc:`TypeError` if the object is not a string object. The C variable may also - be declared as :ctype:`PyObject\*`. - -``U`` (Unicode string) [PyUnicodeObject \*] - Like ``O`` but requires that the Python object is a Unicode object. Raises - :exc:`TypeError` if the object is not a Unicode object. The C variable may also - be declared as :ctype:`PyObject\*`. - -``t#`` (read-only character buffer) [char \*, int] - Like ``s#``, but accepts any object which implements the read-only buffer - interface. The :ctype:`char\*` variable is set to point to the first byte of - the buffer, and the :ctype:`int` is set to the length of the buffer. Only - single-segment buffer objects are accepted; :exc:`TypeError` is raised for all - others. - -``w`` (read-write character buffer) [char \*] - Similar to ``s``, but accepts any object which implements the read-write buffer - interface. The caller must determine the length of the buffer by other means, - or use ``w#`` instead. Only single-segment buffer objects are accepted; - :exc:`TypeError` is raised for all others. - -``w#`` (read-write character buffer) [char \*, int] - Like ``s#``, but accepts any object which implements the read-write buffer - interface. The :ctype:`char \*` variable is set to point to the first byte of - the buffer, and the :ctype:`int` is set to the length of the buffer. Only - single-segment buffer objects are accepted; :exc:`TypeError` is raised for all - others. - -``(items)`` (tuple) [*matching-items*] - The object must be a Python sequence whose length is the number of format units - in *items*. The C arguments must correspond to the individual format units in - *items*. Format units for sequences may be nested. - - .. note:: - - Prior to Python version 1.5.2, this format specifier only accepted a tuple - containing the individual parameters, not an arbitrary sequence. Code which - previously caused :exc:`TypeError` to be raised here may now proceed without an - exception. This is not expected to be a problem for existing code. - -It is possible to pass Python long integers where integers are requested; -however no proper range checking is done --- the most significant bits are -silently truncated when the receiving field is too small to receive the value -(actually, the semantics are inherited from downcasts in C --- your mileage may -vary). - -A few other characters have a meaning in a format string. These may not occur -inside nested parentheses. They are: - -``|`` - Indicates that the remaining arguments in the Python argument list are optional. - The C variables corresponding to optional arguments should be initialized to - their default value --- when an optional argument is not specified, - :cfunc:`PyArg_ParseTuple` does not touch the contents of the corresponding C - variable(s). - -``:`` - The list of format units ends here; the string after the colon is used as the - function name in error messages (the "associated value" of the exception that - :cfunc:`PyArg_ParseTuple` raises). - -``;`` - The list of format units ends here; the string after the semicolon is used as - the error message *instead* of the default error message. Clearly, ``:`` and - ``;`` mutually exclude each other. - -Note that any Python object references which are provided to the caller are -*borrowed* references; do not decrement their reference count! - -Additional arguments passed to these functions must be addresses of variables -whose type is determined by the format string; these are used to store values -from the input tuple. There are a few cases, as described in the list of format -units above, where these parameters are used as input values; they should match -what is specified for the corresponding format unit in that case. - -For the conversion to succeed, the *arg* object must match the format and the -format must be exhausted. On success, the :cfunc:`PyArg_Parse\*` functions -return true, otherwise they return false and raise an appropriate exception. - - -.. cfunction:: int PyArg_ParseTuple(PyObject *args, const char *format, ...) - - Parse the parameters of a function that takes only positional parameters into - local variables. Returns true on success; on failure, it returns false and - raises the appropriate exception. - - -.. cfunction:: int PyArg_VaParse(PyObject *args, const char *format, va_list vargs) - - Identical to :cfunc:`PyArg_ParseTuple`, except that it accepts a va_list rather - than a variable number of arguments. - - -.. cfunction:: int PyArg_ParseTupleAndKeywords(PyObject *args, PyObject *kw, const char *format, char *keywords[], ...) - - Parse the parameters of a function that takes both positional and keyword - parameters into local variables. Returns true on success; on failure, it - returns false and raises the appropriate exception. - - -.. cfunction:: int PyArg_VaParseTupleAndKeywords(PyObject *args, PyObject *kw, const char *format, char *keywords[], va_list vargs) - - Identical to :cfunc:`PyArg_ParseTupleAndKeywords`, except that it accepts a - va_list rather than a variable number of arguments. - - -.. cfunction:: int PyArg_Parse(PyObject *args, const char *format, ...) - - Function used to deconstruct the argument lists of "old-style" functions --- - these are functions which use the :const:`METH_OLDARGS` parameter parsing - method. This is not recommended for use in parameter parsing in new code, and - most code in the standard interpreter has been modified to no longer use this - for that purpose. It does remain a convenient way to decompose other tuples, - however, and may continue to be used for that purpose. - - -.. cfunction:: int PyArg_UnpackTuple(PyObject *args, const char *name, Py_ssize_t min, Py_ssize_t max, ...) - - A simpler form of parameter retrieval which does not use a format string to - specify the types of the arguments. Functions which use this method to retrieve - their parameters should be declared as :const:`METH_VARARGS` in function or - method tables. The tuple containing the actual parameters should be passed as - *args*; it must actually be a tuple. The length of the tuple must be at least - *min* and no more than *max*; *min* and *max* may be equal. Additional - arguments must be passed to the function, each of which should be a pointer to a - :ctype:`PyObject\*` variable; these will be filled in with the values from - *args*; they will contain borrowed references. The variables which correspond - to optional parameters not given by *args* will not be filled in; these should - be initialized by the caller. This function returns true on success and false if - *args* is not a tuple or contains the wrong number of elements; an exception - will be set if there was a failure. - - This is an example of the use of this function, taken from the sources for the - :mod:`_weakref` helper module for weak references:: - - static PyObject * - weakref_ref(PyObject *self, PyObject *args) - { - PyObject *object; - PyObject *callback = NULL; - PyObject *result = NULL; - - if (PyArg_UnpackTuple(args, "ref", 1, 2, &object, &callback)) { - result = PyWeakref_NewRef(object, callback); - } - return result; - } - - The call to :cfunc:`PyArg_UnpackTuple` in this example is entirely equivalent to - this call to :cfunc:`PyArg_ParseTuple`:: - - PyArg_ParseTuple(args, "O|O:ref", &object, &callback) - - .. versionadded:: 2.2 - - -.. cfunction:: PyObject* Py_BuildValue(const char *format, ...) - - Create a new value based on a format string similar to those accepted by the - :cfunc:`PyArg_Parse\*` family of functions and a sequence of values. Returns - the value or *NULL* in the case of an error; an exception will be raised if - *NULL* is returned. - - :cfunc:`Py_BuildValue` does not always build a tuple. It builds a tuple only if - its format string contains two or more format units. If the format string is - empty, it returns ``None``; if it contains exactly one format unit, it returns - whatever object is described by that format unit. To force it to return a tuple - of size 0 or one, parenthesize the format string. - - When memory buffers are passed as parameters to supply data to build objects, as - for the ``s`` and ``s#`` formats, the required data is copied. Buffers provided - by the caller are never referenced by the objects created by - :cfunc:`Py_BuildValue`. In other words, if your code invokes :cfunc:`malloc` - and passes the allocated memory to :cfunc:`Py_BuildValue`, your code is - responsible for calling :cfunc:`free` for that memory once - :cfunc:`Py_BuildValue` returns. - - In the following description, the quoted form is the format unit; the entry in - (round) parentheses is the Python object type that the format unit will return; - and the entry in [square] brackets is the type of the C value(s) to be passed. - - The characters space, tab, colon and comma are ignored in format strings (but - not within format units such as ``s#``). This can be used to make long format - strings a tad more readable. - - ``s`` (string) [char \*] - Convert a null-terminated C string to a Python object. If the C string pointer - is *NULL*, ``None`` is used. - - ``s#`` (string) [char \*, int] - Convert a C string and its length to a Python object. If the C string pointer - is *NULL*, the length is ignored and ``None`` is returned. - - ``z`` (string or ``None``) [char \*] - Same as ``s``. - - ``z#`` (string or ``None``) [char \*, int] - Same as ``s#``. - - ``u`` (Unicode string) [Py_UNICODE \*] - Convert a null-terminated buffer of Unicode (UCS-2 or UCS-4) data to a Python - Unicode object. If the Unicode buffer pointer is *NULL*, ``None`` is returned. - - ``u#`` (Unicode string) [Py_UNICODE \*, int] - Convert a Unicode (UCS-2 or UCS-4) data buffer and its length to a Python - Unicode object. If the Unicode buffer pointer is *NULL*, the length is ignored - and ``None`` is returned. - - ``i`` (integer) [int] - Convert a plain C :ctype:`int` to a Python integer object. - - ``b`` (integer) [char] - Convert a plain C :ctype:`char` to a Python integer object. - - ``h`` (integer) [short int] - Convert a plain C :ctype:`short int` to a Python integer object. - - ``l`` (integer) [long int] - Convert a C :ctype:`long int` to a Python integer object. - - ``B`` (integer) [unsigned char] - Convert a C :ctype:`unsigned char` to a Python integer object. - - ``H`` (integer) [unsigned short int] - Convert a C :ctype:`unsigned short int` to a Python integer object. - - ``I`` (integer/long) [unsigned int] - Convert a C :ctype:`unsigned int` to a Python integer object or a Python long - integer object, if it is larger than ``sys.maxint``. - - ``k`` (integer/long) [unsigned long] - Convert a C :ctype:`unsigned long` to a Python integer object or a Python long - integer object, if it is larger than ``sys.maxint``. - - ``L`` (long) [PY_LONG_LONG] - Convert a C :ctype:`long long` to a Python long integer object. Only available - on platforms that support :ctype:`long long`. - - ``K`` (long) [unsigned PY_LONG_LONG] - Convert a C :ctype:`unsigned long long` to a Python long integer object. Only - available on platforms that support :ctype:`unsigned long long`. - - ``n`` (int) [Py_ssize_t] - Convert a C :ctype:`Py_ssize_t` to a Python integer or long integer. - - .. versionadded:: 2.5 - - ``c`` (string of length 1) [char] - Convert a C :ctype:`int` representing a character to a Python string of length - 1. - - ``d`` (float) [double] - Convert a C :ctype:`double` to a Python floating point number. - - ``f`` (float) [float] - Same as ``d``. - - ``D`` (complex) [Py_complex \*] - Convert a C :ctype:`Py_complex` structure to a Python complex number. - - ``O`` (object) [PyObject \*] - Pass a Python object untouched (except for its reference count, which is - incremented by one). If the object passed in is a *NULL* pointer, it is assumed - that this was caused because the call producing the argument found an error and - set an exception. Therefore, :cfunc:`Py_BuildValue` will return *NULL* but won't - raise an exception. If no exception has been raised yet, :exc:`SystemError` is - set. - - ``S`` (object) [PyObject \*] - Same as ``O``. - - ``N`` (object) [PyObject \*] - Same as ``O``, except it doesn't increment the reference count on the object. - Useful when the object is created by a call to an object constructor in the - argument list. - - ``O&`` (object) [*converter*, *anything*] - Convert *anything* to a Python object through a *converter* function. The - function is called with *anything* (which should be compatible with :ctype:`void - \*`) as its argument and should return a "new" Python object, or *NULL* if an - error occurred. - - ``(items)`` (tuple) [*matching-items*] - Convert a sequence of C values to a Python tuple with the same number of items. - - ``[items]`` (list) [*matching-items*] - Convert a sequence of C values to a Python list with the same number of items. - - ``{items}`` (dictionary) [*matching-items*] - Convert a sequence of C values to a Python dictionary. Each pair of consecutive - C values adds one item to the dictionary, serving as key and value, - respectively. - - If there is an error in the format string, the :exc:`SystemError` exception is - set and *NULL* returned. - - -.. _string-conversion: - -String conversion and formatting -================================ - -Functions for number conversion and formatted string output. - - -.. cfunction:: int PyOS_snprintf(char *str, size_t size, const char *format, ...) - - Output not more than *size* bytes to *str* according to the format string - *format* and the extra arguments. See the Unix man page :manpage:`snprintf(2)`. - - -.. cfunction:: int PyOS_vsnprintf(char *str, size_t size, const char *format, va_list va) - - Output not more than *size* bytes to *str* according to the format string - *format* and the variable argument list *va*. Unix man page - :manpage:`vsnprintf(2)`. - -:cfunc:`PyOS_snprintf` and :cfunc:`PyOS_vsnprintf` wrap the Standard C library -functions :cfunc:`snprintf` and :cfunc:`vsnprintf`. Their purpose is to -guarantee consistent behavior in corner cases, which the Standard C functions do -not. - -The wrappers ensure that *str*[*size*-1] is always ``'\0'`` upon return. They -never write more than *size* bytes (including the trailing ``'\0'`` into str. -Both functions require that ``str != NULL``, ``size > 0`` and ``format != -NULL``. - -If the platform doesn't have :cfunc:`vsnprintf` and the buffer size needed to -avoid truncation exceeds *size* by more than 512 bytes, Python aborts with a -*Py_FatalError*. - -The return value (*rv*) for these functions should be interpreted as follows: - -* When ``0 <= rv < size``, the output conversion was successful and *rv* - characters were written to *str* (excluding the trailing ``'\0'`` byte at - *str*[*rv*]). - -* When ``rv >= size``, the output conversion was truncated and a buffer with - ``rv + 1`` bytes would have been needed to succeed. *str*[*size*-1] is ``'\0'`` - in this case. - -* When ``rv < 0``, "something bad happened." *str*[*size*-1] is ``'\0'`` in - this case too, but the rest of *str* is undefined. The exact cause of the error - depends on the underlying platform. - -The following functions provide locale-independent string to number conversions. - - -.. cfunction:: double PyOS_ascii_strtod(const char *nptr, char **endptr) - - Convert a string to a :ctype:`double`. This function behaves like the Standard C - function :cfunc:`strtod` does in the C locale. It does this without changing the - current locale, since that would not be thread-safe. - - :cfunc:`PyOS_ascii_strtod` should typically be used for reading configuration - files or other non-user input that should be locale independent. - - .. versionadded:: 2.4 - - See the Unix man page :manpage:`strtod(2)` for details. - - -.. cfunction:: char * PyOS_ascii_formatd(char *buffer, size_t buf_len, const char *format, double d) - - Convert a :ctype:`double` to a string using the ``'.'`` as the decimal - separator. *format* is a :cfunc:`printf`\ -style format string specifying the - number format. Allowed conversion characters are ``'e'``, ``'E'``, ``'f'``, - ``'F'``, ``'g'`` and ``'G'``. - - The return value is a pointer to *buffer* with the converted string or NULL if - the conversion failed. - - .. versionadded:: 2.4 - - -.. cfunction:: double PyOS_ascii_atof(const char *nptr) - - Convert a string to a :ctype:`double` in a locale-independent way. - - .. versionadded:: 2.4 - - See the Unix man page :manpage:`atof(2)` for details. - - -.. cfunction:: char * PyOS_stricmp(char *s1, char *s2) - - Case insensitive comparsion of strings. The functions works almost - identical to :cfunc:`strcmp` except that it ignores the case. - - .. versionadded:: 2.6 - - -.. cfunction:: char * PyOS_strnicmp(char *s1, char *s2, Py_ssize_t size) - - Case insensitive comparsion of strings. The functions works almost - identical to :cfunc:`strncmp` except that it ignores the case. - - .. versionadded:: 2.6 - - -.. _reflection: - -Reflection -========== - -.. cfunction:: PyObject* PyEval_GetBuiltins() - - Return a dictionary of the builtins in the current execution frame, - or the interpreter of the thread state if no frame is currently executing. - - -.. cfunction:: PyObject* PyEval_GetLocals() - - Return a dictionary of the local variables in the current execution frame, - or *NULL* if no frame is currently executing. - - -.. cfunction:: PyObject* PyEval_GetGlobals() - - Return a dictionary of the global variables in the current execution frame, - or *NULL* if no frame is currently executing. - - -.. cfunction:: PyFrameObject* PyEval_GetFrame() - - Return the current thread state's frame, which is *NULL* if no frame is - currently executing. - - -.. cfunction:: int PyEval_GetRestricted() - - If there is a current frame and it is executing in restricted mode, return true, - otherwise false. - - -.. cfunction:: const char* PyEval_GetFuncName(PyObject *func) - - Return the name of *func* if it is a function, class or instance object, else the - name of *func*\s type. - - -.. cfunction:: const char* PyEval_GetFuncDesc(PyObject *func) - - Return a description string, depending on the type of *func*. - Return values include "()" for functions and methods, " constructor", - " instance", and " object". Concatenated with the result of - :cfunc:`PyEval_GetFuncName`, the result will be a description of - *func*. + sys.rst + import.rst + marshal.rst + arg.rst + conversion.rst + reflection.rst From python-checkins at python.org Sat Jan 19 23:23:56 2008 From: python-checkins at python.org (gregory.p.smith) Date: Sat, 19 Jan 2008 23:23:56 +0100 (CET) Subject: [Python-checkins] r60111 - python/trunk/Lib/subprocess.py Message-ID: <20080119222356.B44E31E4022@bag.python.org> Author: gregory.p.smith Date: Sat Jan 19 23:23:56 2008 New Revision: 60111 Modified: python/trunk/Lib/subprocess.py Log: Undo an unnecessary else: and indentation that r60104 added. try: ... except: ... raise else: ... the else: is unecessary due to the blind except: with a raise. Modified: python/trunk/Lib/subprocess.py ============================================================================== --- python/trunk/Lib/subprocess.py (original) +++ python/trunk/Lib/subprocess.py Sat Jan 19 23:23:56 2008 @@ -1005,64 +1005,63 @@ if gc_was_enabled: gc.enable() raise - else: - self._child_created = True - if self.pid == 0: - # Child - try: - # Close parent's pipe ends - if p2cwrite is not None: - os.close(p2cwrite) - if c2pread is not None: - os.close(c2pread) - if errread is not None: - os.close(errread) - os.close(errpipe_read) - - # Dup fds for child - if p2cread is not None: - os.dup2(p2cread, 0) - if c2pwrite is not None: - os.dup2(c2pwrite, 1) - if errwrite is not None: - os.dup2(errwrite, 2) - - # Close pipe fds. Make sure we don't close the same - # fd more than once, or standard fds. - if p2cread is not None and p2cread not in (0,): - os.close(p2cread) - if c2pwrite is not None and c2pwrite not in (p2cread, 1): - os.close(c2pwrite) - if errwrite is not None and errwrite not in (p2cread, c2pwrite, 2): - os.close(errwrite) - - # Close all other fds, if asked for - if close_fds: - self._close_fds(but=errpipe_write) - - if cwd is not None: - os.chdir(cwd) - - if preexec_fn: - apply(preexec_fn) - - if env is None: - os.execvp(executable, args) - else: - os.execvpe(executable, args, env) - - except: - exc_type, exc_value, tb = sys.exc_info() - # Save the traceback and attach it to the exception object - exc_lines = traceback.format_exception(exc_type, - exc_value, - tb) - exc_value.child_traceback = ''.join(exc_lines) - os.write(errpipe_write, pickle.dumps(exc_value)) - - # This exitcode won't be reported to applications, so it - # really doesn't matter what we return. - os._exit(255) + self._child_created = True + if self.pid == 0: + # Child + try: + # Close parent's pipe ends + if p2cwrite is not None: + os.close(p2cwrite) + if c2pread is not None: + os.close(c2pread) + if errread is not None: + os.close(errread) + os.close(errpipe_read) + + # Dup fds for child + if p2cread is not None: + os.dup2(p2cread, 0) + if c2pwrite is not None: + os.dup2(c2pwrite, 1) + if errwrite is not None: + os.dup2(errwrite, 2) + + # Close pipe fds. Make sure we don't close the same + # fd more than once, or standard fds. + if p2cread is not None and p2cread not in (0,): + os.close(p2cread) + if c2pwrite is not None and c2pwrite not in (p2cread, 1): + os.close(c2pwrite) + if errwrite is not None and errwrite not in (p2cread, c2pwrite, 2): + os.close(errwrite) + + # Close all other fds, if asked for + if close_fds: + self._close_fds(but=errpipe_write) + + if cwd is not None: + os.chdir(cwd) + + if preexec_fn: + apply(preexec_fn) + + if env is None: + os.execvp(executable, args) + else: + os.execvpe(executable, args, env) + + except: + exc_type, exc_value, tb = sys.exc_info() + # Save the traceback and attach it to the exception object + exc_lines = traceback.format_exception(exc_type, + exc_value, + tb) + exc_value.child_traceback = ''.join(exc_lines) + os.write(errpipe_write, pickle.dumps(exc_value)) + + # This exitcode won't be reported to applications, so it + # really doesn't matter what we return. + os._exit(255) # Parent if gc_was_enabled: From python-checkins at python.org Sat Jan 19 23:29:42 2008 From: python-checkins at python.org (gregory.p.smith) Date: Sat, 19 Jan 2008 23:29:42 +0100 (CET) Subject: [Python-checkins] r60113 - in python/branches/release25-maint: Lib/subprocess.py Misc/NEWS Message-ID: <20080119222942.42F3F1E401A@bag.python.org> Author: gregory.p.smith Date: Sat Jan 19 23:29:41 2008 New Revision: 60113 Modified: python/branches/release25-maint/Lib/subprocess.py python/branches/release25-maint/Misc/NEWS Log: backport r60104 + r60111 from trunk. - Issue #1336: fix a race condition in subprocess.Popen if the garbage collector kicked in at the wrong time that would cause the process to hang when the child wrote to stderr. Modified: python/branches/release25-maint/Lib/subprocess.py ============================================================================== --- python/branches/release25-maint/Lib/subprocess.py (original) +++ python/branches/release25-maint/Lib/subprocess.py Sat Jan 19 23:29:41 2008 @@ -358,6 +358,7 @@ import os import types import traceback +import gc # Exception classes used by this module. class CalledProcessError(Exception): @@ -1002,7 +1003,16 @@ errpipe_read, errpipe_write = os.pipe() self._set_cloexec_flag(errpipe_write) - self.pid = os.fork() + gc_was_enabled = gc.isenabled() + # Disable gc to avoid bug where gc -> file_dealloc -> + # write to stderr -> hang. http://bugs.python.org/issue1336 + gc.disable() + try: + self.pid = os.fork() + except: + if gc_was_enabled: + gc.enable() + raise self._child_created = True if self.pid == 0: # Child @@ -1062,6 +1072,8 @@ os._exit(255) # Parent + if gc_was_enabled: + gc.enable() os.close(errpipe_write) if p2cread and p2cwrite: os.close(p2cread) Modified: python/branches/release25-maint/Misc/NEWS ============================================================================== --- python/branches/release25-maint/Misc/NEWS (original) +++ python/branches/release25-maint/Misc/NEWS Sat Jan 19 23:29:41 2008 @@ -53,6 +53,10 @@ Library ------- +- Issue #1336: fix a race condition in subprocess.Popen if the garbage + collector kicked in at the wrong time that would cause the process + to hang when the child wrote to stderr. + - Bug #1687: Fixed plistlib.py restricts to Python int when writing. - Issue #1182: many arithmetic bugs in the decimal module have been From python-checkins at python.org Sat Jan 19 23:35:09 2008 From: python-checkins at python.org (gregory.p.smith) Date: Sat, 19 Jan 2008 23:35:09 +0100 (CET) Subject: [Python-checkins] r60114 - in python/branches/release24-maint: Lib/subprocess.py Misc/NEWS Message-ID: <20080119223509.910281E401A@bag.python.org> Author: gregory.p.smith Date: Sat Jan 19 23:35:09 2008 New Revision: 60114 Modified: python/branches/release24-maint/Lib/subprocess.py python/branches/release24-maint/Misc/NEWS Log: Backport r60104 + r60111 from trunk. - Issue #1336: fix a race condition in subprocess.Popen if the garbage collector kicked in at the wrong time that would cause the process to hang when the child wrote to stderr. Modified: python/branches/release24-maint/Lib/subprocess.py ============================================================================== --- python/branches/release24-maint/Lib/subprocess.py (original) +++ python/branches/release24-maint/Lib/subprocess.py Sat Jan 19 23:35:09 2008 @@ -346,6 +346,7 @@ import os import types import traceback +import gc if mswindows: import threading @@ -899,7 +900,16 @@ errpipe_read, errpipe_write = os.pipe() self._set_cloexec_flag(errpipe_write) - self.pid = os.fork() + gc_was_enabled = gc.isenabled() + # Disable gc to avoid bug where gc -> file_dealloc -> + # write to stderr -> hang. http://bugs.python.org/issue1336 + gc.disable() + try: + self.pid = os.fork() + except: + if gc_was_enabled: + gc.enable() + raise if self.pid == 0: # Child try: @@ -958,6 +968,8 @@ os._exit(255) # Parent + if gc_was_enabled: + gc.enable() os.close(errpipe_write) if p2cread and p2cwrite: os.close(p2cread) Modified: python/branches/release24-maint/Misc/NEWS ============================================================================== --- python/branches/release24-maint/Misc/NEWS (original) +++ python/branches/release24-maint/Misc/NEWS Sat Jan 19 23:35:09 2008 @@ -26,6 +26,10 @@ Library ------- +- Issue #1336: fix a race condition in subprocess.Popen if the garbage + collector kicked in at the wrong time that would cause the process + to hang when the child wrote to stderr. + - Bug #1728403: Fix a bug that CJKCodecs StreamReader hangs when it reads a file that ends with incomplete sequence and sizehint argument for .read() is specified. From buildbot at python.org Sat Jan 19 23:35:52 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 19 Jan 2008 22:35:52 +0000 Subject: [Python-checkins] buildbot failure in alpha Tru64 5.1 2.5 Message-ID: <20080119223552.8D2851E401A@bag.python.org> The Buildbot has detected a new failure of alpha Tru64 5.1 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/alpha%20Tru64%205.1%202.5/builds/402 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-tru64 Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: georg.brandl BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_signal sincerely, -The Buildbot From python-checkins at python.org Sat Jan 19 23:49:37 2008 From: python-checkins at python.org (gregory.p.smith) Date: Sat, 19 Jan 2008 23:49:37 +0100 (CET) Subject: [Python-checkins] r60115 - in python/trunk/Lib: subprocess.py test/test_subprocess.py Message-ID: <20080119224937.9738B1E401A@bag.python.org> Author: gregory.p.smith Date: Sat Jan 19 23:49:37 2008 New Revision: 60115 Modified: python/trunk/Lib/subprocess.py python/trunk/Lib/test/test_subprocess.py Log: Fix issue 1300: Quote command line arguments that contain a '|' character in subprocess.list2cmdline (windows). Modified: python/trunk/Lib/subprocess.py ============================================================================== --- python/trunk/Lib/subprocess.py (original) +++ python/trunk/Lib/subprocess.py Sat Jan 19 23:49:37 2008 @@ -471,8 +471,8 @@ 2) A string surrounded by double quotation marks is interpreted as a single argument, regardless of white space - contained within. A quoted string can be embedded in an - argument. + or pipe characters contained within. A quoted string can be + embedded in an argument. 3) A double quotation mark preceded by a backslash is interpreted as a literal double quotation mark. @@ -498,7 +498,7 @@ if result: result.append(' ') - needquote = (" " in arg) or ("\t" in arg) or not arg + needquote = (" " in arg) or ("\t" in arg) or ("|" in arg) or not arg if needquote: result.append('"') Modified: python/trunk/Lib/test/test_subprocess.py ============================================================================== --- python/trunk/Lib/test/test_subprocess.py (original) +++ python/trunk/Lib/test/test_subprocess.py Sat Jan 19 23:49:37 2008 @@ -434,6 +434,8 @@ '"a\\\\b\\ c" d e') self.assertEqual(subprocess.list2cmdline(['ab', '']), 'ab ""') + self.assertEqual(subprocess.list2cmdline(['echo', 'foo|bar']), + 'echo "foo|bar"') def test_poll(self): From python-checkins at python.org Sun Jan 20 00:10:53 2008 From: python-checkins at python.org (gregory.p.smith) Date: Sun, 20 Jan 2008 00:10:53 +0100 (CET) Subject: [Python-checkins] r60116 - in python/trunk: Lib/zipfile.py Misc/NEWS Message-ID: <20080119231053.047671E4022@bag.python.org> Author: gregory.p.smith Date: Sun Jan 20 00:10:52 2008 New Revision: 60116 Modified: python/trunk/Lib/zipfile.py python/trunk/Misc/NEWS Log: Fixes/Accepts Patch for issue1189216 - Work properly with archives that have file headers past the 2**31 byte boundary. Modified: python/trunk/Lib/zipfile.py ============================================================================== --- python/trunk/Lib/zipfile.py (original) +++ python/trunk/Lib/zipfile.py Sun Jan 20 00:10:52 2008 @@ -32,9 +32,9 @@ # Other ZIP compression methods not supported # Here are some struct module formats for reading headers -structEndArchive = "<4s4H2lH" # 9 items, end of archive, 22 bytes +structEndArchive = "<4s4H2LH" # 9 items, end of archive, 22 bytes stringEndArchive = "PK\005\006" # magic number for end of archive record -structCentralDir = "<4s4B4HlLL5HLl"# 19 items, central directory, 46 bytes +structCentralDir = "<4s4B4HlLL5HLL"# 19 items, central directory, 46 bytes stringCentralDir = "PK\001\002" # magic number for central directory structFileHeader = "<4s2B4HlLL2H" # 12 items, file header record, 30 bytes stringFileHeader = "PK\003\004" # magic number for file header Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Sun Jan 20 00:10:52 2008 @@ -369,6 +369,9 @@ Library ------- +- #1189216: Fix the zipfile module to work on archives with headers + past the 2**31 byte boundary. + - #1336: fix a race condition in subprocess.Popen if the garbage collector kicked in at the wrong time that would cause the process to hang when the child wrote to stderr. From python-checkins at python.org Sun Jan 20 00:16:02 2008 From: python-checkins at python.org (gregory.p.smith) Date: Sun, 20 Jan 2008 00:16:02 +0100 (CET) Subject: [Python-checkins] r60117 - in python/branches/release25-maint: Lib/zipfile.py Misc/NEWS Message-ID: <20080119231602.3AA8C1E401A@bag.python.org> Author: gregory.p.smith Date: Sun Jan 20 00:16:01 2008 New Revision: 60117 Modified: python/branches/release25-maint/Lib/zipfile.py python/branches/release25-maint/Misc/NEWS Log: backport r60116 - fix zipfile to work with archives having file headers beyond the signed 2**31 byte boundary. Modified: python/branches/release25-maint/Lib/zipfile.py ============================================================================== --- python/branches/release25-maint/Lib/zipfile.py (original) +++ python/branches/release25-maint/Lib/zipfile.py Sun Jan 20 00:16:01 2008 @@ -32,9 +32,9 @@ # Other ZIP compression methods not supported # Here are some struct module formats for reading headers -structEndArchive = "<4s4H2lH" # 9 items, end of archive, 22 bytes +structEndArchive = "<4s4H2LH" # 9 items, end of archive, 22 bytes stringEndArchive = "PK\005\006" # magic number for end of archive record -structCentralDir = "<4s4B4HlLL5HLl"# 19 items, central directory, 46 bytes +structCentralDir = "<4s4B4HlLL5HLL"# 19 items, central directory, 46 bytes stringCentralDir = "PK\001\002" # magic number for central directory structFileHeader = "<4s2B4HlLL2H" # 12 items, file header record, 30 bytes stringFileHeader = "PK\003\004" # magic number for file header Modified: python/branches/release25-maint/Misc/NEWS ============================================================================== --- python/branches/release25-maint/Misc/NEWS (original) +++ python/branches/release25-maint/Misc/NEWS Sun Jan 20 00:16:01 2008 @@ -53,6 +53,9 @@ Library ------- +- #1189216: Fix the zipfile module to work on archives with headers + past the 2**31 byte boundary. + - Issue #1336: fix a race condition in subprocess.Popen if the garbage collector kicked in at the wrong time that would cause the process to hang when the child wrote to stderr. From buildbot at python.org Sun Jan 20 00:24:16 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 19 Jan 2008 23:24:16 +0000 Subject: [Python-checkins] buildbot failure in x86 XP-3 3.0 Message-ID: <20080119232417.99BD41E4027@bag.python.org> The Buildbot has detected a new failure of x86 XP-3 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20XP-3%203.0/builds/494 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: heller-windows Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: georg.brandl BUILD FAILED: failed test Excerpt from the test logfile: 9 tests failed: test_anydbm test_bsddb test_bsddb3 test_cProfile test_mailbox test_shelve test_whichdb test_winreg test_zipfile ====================================================================== ERROR: test_anydbm_access (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_anydbm.py", line 90, in test_anydbm_access self.init_db() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_anydbm.py", line 103, in init_db f = anydbm.open(_fname, 'n') File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_anydbm_creation (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_anydbm.py", line 63, in test_anydbm_creation f = anydbm.open(_fname, 'c') File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_anydbm_keys (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_anydbm.py", line 84, in test_anydbm_keys self.init_db() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_anydbm.py", line 103, in init_db f = anydbm.open(_fname, 'n') File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_anydbm_modification (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_anydbm.py", line 71, in test_anydbm_modification self.init_db() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_anydbm.py", line 103, in init_db f = anydbm.open(_fname, 'n') File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_anydbm_read (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_anydbm.py", line 78, in test_anydbm_read self.init_db() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_anydbm.py", line 103, in init_db f = anydbm.open(_fname, 'n') File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') Traceback (most recent call last): File "../lib/test/regrtest.py", line 596, in runtest_inner indirect_test() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb3.py", line 64, in test_main run_unittest(suite()) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb3.py", line 28, in suite import bsddb.test.test_1413192 File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\test\test_1413192.py", line 38, in context = Context() File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\test\test_1413192.py", line 26, in __init__ db.DB_CREATE | db.DB_INIT_TXN | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_flush (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 703, in tearDown self._delete_recursively(self._path) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 47, in _delete_recursively os.remove(target) WindowsError: [Error 32] The process cannot access the file because it is being used by another process: '@test' ====================================================================== ERROR: test_popitem (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 336, in test_popitem self.assertEqual(int(msg.get_payload()), keys.index(key)) ValueError: invalid literal for int() with base 10: 'From: foo 0 F' ====================================================================== ERROR: test_flush (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 703, in tearDown self._delete_recursively(self._path) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 47, in _delete_recursively os.remove(target) WindowsError: [Error 32] The process cannot access the file because it is being used by another process: '@test' ====================================================================== ERROR: test_popitem (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 336, in test_popitem self.assertEqual(int(msg.get_payload()), keys.index(key)) ValueError: invalid literal for int() with base 10: 'From: foo 0 \x01' ====================================================================== ERROR: test_flush (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 926, in tearDown self._delete_recursively(self._path) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 47, in _delete_recursively os.remove(target) WindowsError: [Error 32] The process cannot access the file because it is being used by another process: '@test' ====================================================================== ERROR: test_popitem (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 336, in test_popitem self.assertEqual(int(msg.get_payload()), keys.index(key)) ValueError: invalid literal for int() with base 10: 'From: foo *** EOOH *** From: foo 0 1,, From: foo *** EOOH *** From: foo 1 1,, From: foo *** EOOH *** From: foo 2 1,, From: foo *** EOOH *** From: foo 3 ' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestMaildir) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_add (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 77, in test_add self.assertEqual(self._box.get_string(keys[0]), self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\nF' != 'From: foo\n\n0' ====================================================================== FAIL: test_add_and_close (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 743, in test_add_and_close self.assertEqual(contents, open(self._path, 'r').read()) AssertionError: 'From MAILER-DAEMON Sun Jan 20 02:03:08 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Sun Jan 20 02:03:08 2008\n\nFrom: foo\n\n0\n\nFrom MAILER-DAEMON Sun Jan 20 02:03:08 2008\n\nFrom: foo\n\n1\n\nFrom MAILER-DAEMON Sun Jan 20 02:03:08 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Sun Jan 20 02:03:08 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'From MAILER-DAEMON Sun Jan 20 02:03:08 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Sun Jan 20 02:03:08 2008\n\nFrom: foo\n\n0\n\nFrom MAILER-DAEMON Sun Jan 20 02:03:08 2008\n\nFrom: foo\n\n1\n\nFrom MAILER-DAEMON Sun Jan 20 02:03:08 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Sun Jan 20 02:03:08 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Sun Jan 20 02:03:08 2008\n\nFrom: foo\n\n0\n\nFrom MAILER-DAEMON Sun Jan 20 02:03:08 2008\n\nFrom: foo\n\n1\n\nFrom MAILER-DAEMON Sun Jan 20 02:03:08 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Sun Jan 20 02:03:08 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Sun Jan 20 02:03:08 2008\n\nFrom: foo\n\n1\n\nFrom MAILER-DAEMON Sun Jan 20 02:03:08 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Sun Jan 20 02:03:08 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Sun Jan 20 02:03:08 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Sun Jan 20 02:03:08 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Sun Jan 20 02:03:08 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' ====================================================================== FAIL: test_add_from_string (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 710, in test_add_from_string self.assertEqual(self._box[key].get_from(), 'foo at bar blah') AssertionError: 'foo at bar blah\n' != 'foo at bar blah' ====================================================================== FAIL: test_close (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 389, in test_close self._test_flush_or_close(self._box.close) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 6 != 3 ====================================================================== FAIL: test_delitem (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 87, in test_delitem self._test_remove_or_delitem(self._box.__delitem__) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n1' != 'From: foo\n\n1' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_flush (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 377, in test_flush self._test_flush_or_close(self._box.flush) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 6 != 3 ====================================================================== FAIL: test_get (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 129, in test_get self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_file (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 174, in test_get_file self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\nF' != 'From: foo\n\n0' ====================================================================== FAIL: test_get_message (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 156, in test_get_message self.assertEqual(msg0['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_string (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 164, in test_get_string self.assertEqual(self._box.get_string(key0), self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\nF' != 'From: foo\n\n0' ====================================================================== FAIL: test_getitem (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 144, in test_getitem self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_items (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 207, in test_items self._check_iteration(self._box.items, do_keys=True, do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iter (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 194, in test_iter do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iteritems (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 203, in test_iteritems do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_itervalues (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 189, in test_itervalues do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_open_close_open (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 727, in test_open_close_open self.assertEqual(len(self._box), 3) AssertionError: 6 != 3 ====================================================================== FAIL: test_pop (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 313, in test_pop self.assertEqual(self._box.pop(key0).get_payload(), '0') AssertionError: 'From: foo\n\n0\n\nF' != '0' ====================================================================== FAIL: test_remove (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 83, in test_remove self._test_remove_or_delitem(self._box.remove) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n1' != 'From: foo\n\n1' ====================================================================== FAIL: test_set_item (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 272, in test_set_item self._template % 'original 0') AssertionError: '\nFrom: foo\n\noriginal 0' != 'From: foo\n\noriginal 0' ====================================================================== FAIL: test_update (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 350, in test_update self._template % 'changed 0') AssertionError: '\nFrom: foo\n\nchanged 0\n\nF' != 'From: foo\n\nchanged 0' ====================================================================== FAIL: test_values (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 198, in test_values self._check_iteration(self._box.values, do_keys=False, do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_add (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 77, in test_add self.assertEqual(self._box.get_string(keys[0]), self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\n\x01' != 'From: foo\n\n0' ====================================================================== FAIL: test_add_and_close (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 743, in test_add_and_close self.assertEqual(contents, open(self._path, 'r').read()) AssertionError: '\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 20 02:03:15 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 20 02:03:15 2008\n\nFrom: foo\n\n0\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 20 02:03:15 2008\n\nFrom: foo\n\n1\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 20 02:03:15 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 20 02:03:15 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n' != '\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 20 02:03:15 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 20 02:03:15 2008\n\nFrom: foo\n\n0\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 20 02:03:15 2008\n\nFrom: foo\n\n1\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 20 02:03:15 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 20 02:03:15 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 20 02:03:15 2008\n\nFrom: foo\n\n0\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 20 02:03:15 2008\n\nFrom: foo\n\n1\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 20 02:03:15 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 20 02:03:15 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 20 02:03:15 2008\n\nFrom: foo\n\n1\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 20 02:03:15 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 20 02:03:15 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 20 02:03:15 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 20 02:03:15 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 20 02:03:15 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n' ====================================================================== FAIL: test_add_from_string (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 710, in test_add_from_string self.assertEqual(self._box[key].get_from(), 'foo at bar blah') AssertionError: 'foo at bar blah\n' != 'foo at bar blah' ====================================================================== FAIL: test_close (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 389, in test_close self._test_flush_or_close(self._box.close) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_delitem (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 87, in test_delitem self._test_remove_or_delitem(self._box.__delitem__) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n1\n\n\x01' != 'From: foo\n\n1' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_flush (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 377, in test_flush self._test_flush_or_close(self._box.flush) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_get (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 129, in test_get self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_file (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 174, in test_get_file self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\n\x01' != 'From: foo\n\n0' ====================================================================== FAIL: test_get_message (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 156, in test_get_message self.assertEqual(msg0['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_string (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 164, in test_get_string self.assertEqual(self._box.get_string(key0), self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\n\x01' != 'From: foo\n\n0' ====================================================================== FAIL: test_getitem (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 144, in test_getitem self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_items (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 207, in test_items self._check_iteration(self._box.items, do_keys=True, do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iter (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 194, in test_iter do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iteritems (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 203, in test_iteritems do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_itervalues (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 189, in test_itervalues do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_open_close_open (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 727, in test_open_close_open self.assertEqual(len(self._box), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_pop (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 313, in test_pop self.assertEqual(self._box.pop(key0).get_payload(), '0') AssertionError: 'From: foo\n\n0\n\n\x01' != '0' ====================================================================== FAIL: test_remove (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 83, in test_remove self._test_remove_or_delitem(self._box.remove) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n1\n\n\x01' != 'From: foo\n\n1' ====================================================================== FAIL: test_set_item (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 272, in test_set_item self._template % 'original 0') AssertionError: '\nFrom: foo\n\noriginal 0\n\n\x01' != 'From: foo\n\noriginal 0' ====================================================================== FAIL: test_update (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 350, in test_update self._template % 'changed 0') AssertionError: '\nFrom: foo\n\nchanged 0\n\n\x01' != 'From: foo\n\nchanged 0' ====================================================================== FAIL: test_values (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 198, in test_values self._check_iteration(self._box.values, do_keys=False, do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestMH) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_add (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 77, in test_add self.assertEqual(self._box.get_string(keys[0]), self._template % 0) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n0\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f' != 'From: foo\n\n0' ====================================================================== FAIL: test_close (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 389, in test_close self._test_flush_or_close(self._box.close) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_delitem (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 87, in test_delitem self._test_remove_or_delitem(self._box.__delitem__) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n1\n\n\x1f' != 'From: foo\n\n1' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_flush (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 377, in test_flush self._test_flush_or_close(self._box.flush) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_get (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 129, in test_get self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_file (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 174, in test_get_file self._template % 0) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n0\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f' != 'From: foo\n\n0' ====================================================================== FAIL: test_get_message (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 156, in test_get_message self.assertEqual(msg0['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_string (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 164, in test_get_string self.assertEqual(self._box.get_string(key0), self._template % 0) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n0\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f' != 'From: foo\n\n0' ====================================================================== FAIL: test_getitem (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 144, in test_getitem self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_items (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 207, in test_items self._check_iteration(self._box.items, do_keys=True, do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iter (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 194, in test_iter do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iteritems (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 203, in test_iteritems do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_itervalues (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 189, in test_itervalues do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_pop (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 313, in test_pop self.assertEqual(self._box.pop(key0).get_payload(), '0') AssertionError: 'From: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n0\n\n\x1f\x0c\n\n1,,\n\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n1\n\n\x1f' != '0' ====================================================================== FAIL: test_remove (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 83, in test_remove self._test_remove_or_delitem(self._box.remove) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n1\n\n\x1f' != 'From: foo\n\n1' ====================================================================== FAIL: test_set_item (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 272, in test_set_item self._template % 'original 0') AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\noriginal 0\n\n\x1f' != 'From: foo\n\noriginal 0' ====================================================================== FAIL: test_update (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 350, in test_update self._template % 'changed 0') AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\nchanged 0\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f' != 'From: foo\n\nchanged 0' ====================================================================== FAIL: test_values (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 198, in test_values self._check_iteration(self._box.values, do_keys=False, do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== ERROR: test_bool (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 136, in test_bool self.assert_(not self._empty_mapping()) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_constructor (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 133, in test_constructor self.assertEqual(self._empty_mapping(), self._empty_mapping()) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 270, in test_get d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_items (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 156, in test_items d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keys (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 142, in test_keys d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 162, in test_len d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 293, in test_pop d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 288, in test_popitem d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_read (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 44, in test_read p = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 284, in test_setdefault d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 174, in test_update d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_values (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 150, in test_values d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_write (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 92, in test_write p = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_bool (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 136, in test_bool self.assert_(not self._empty_mapping()) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_constructor (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 133, in test_constructor self.assertEqual(self._empty_mapping(), self._empty_mapping()) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 270, in test_get d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_items (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 156, in test_items d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keys (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 142, in test_keys d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 162, in test_len d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 293, in test_pop d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 288, in test_popitem d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_read (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 44, in test_read p = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 284, in test_setdefault d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 174, in test_update d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_values (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 150, in test_values d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_write (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 92, in test_write p = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_bool (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 136, in test_bool self.assert_(not self._empty_mapping()) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_constructor (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 133, in test_constructor self.assertEqual(self._empty_mapping(), self._empty_mapping()) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 270, in test_get d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_items (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 156, in test_items d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keys (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 142, in test_keys d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 162, in test_len d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 293, in test_pop d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 288, in test_popitem d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_read (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 44, in test_read p = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 284, in test_setdefault d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 174, in test_update d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_values (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 150, in test_values d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_write (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 92, in test_write p = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_ascii_file_shelf (test.test_shelve.TestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 46, in test_ascii_file_shelf s = shelve.open(self.fn, protocol=0) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_binary_file_shelf (test.test_shelve.TestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 54, in test_binary_file_shelf s = shelve.open(self.fn, protocol=1) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_proto2_file_shelf (test.test_shelve.TestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 62, in test_proto2_file_shelf s = shelve.open(self.fn, protocol=2) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_whichdb (test.test_whichdb.WhichDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_whichdb.py", line 32, in test_whichdb f = module.open(_fname, 'c') File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== FAIL: testLocalMachineRegistryWorks (test.test_winreg.WinregTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_winreg.py", line 144, in testLocalMachineRegistryWorks self.TestAll(HKEY_CURRENT_USER) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_winreg.py", line 139, in TestAll self.WriteTestData(root_key, subkeystr) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_winreg.py", line 41, in WriteTestData self.assertEquals(nkeys, 1, "Not the correct number of sub keys") AssertionError: Not the correct number of sub keys ====================================================================== ERROR: testExtract (test.test_zipfile.TestsWithSourceFile) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_zipfile.py", line 350, in tearDown os.remove(TESTFN2) WindowsError: [Error 32] The process cannot access the file because it is being used by another process: '@test2' ====================================================================== FAIL: testExtract (test.test_zipfile.TestsWithSourceFile) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_zipfile.py", line 313, in testExtract self.assertEqual(writtenfile, correctfile) AssertionError: 'C:\\buildbot\\work\\3.0.heller-windows\\build\\PCbuild\\ziptest2dir\\_ziptest2' != 'C:\\buildbot\\work\\3.0.heller-windows\\build\\PCbuild\\ziptest2dir/_ziptest2' sincerely, -The Buildbot From buildbot at python.org Sun Jan 20 00:40:42 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 19 Jan 2008 23:40:42 +0000 Subject: [Python-checkins] buildbot failure in x86 XP-4 2.5 Message-ID: <20080119234042.5F80C1E401F@bag.python.org> The Buildbot has detected a new failure of x86 XP-4 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20XP-4%202.5/builds/96 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-windows Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: georg.brandl BUILD FAILED: failed test Excerpt from the test logfile: 2 tests failed: test_mailbox test_winreg ====================================================================== ERROR: test_consistent_factory (test.test_mailbox.TestMaildir) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\2.5.bolen-windows\build\lib\test\test_mailbox.py", line 522, in test_consistent_factory msg2 = box.get_message(key) File "E:\cygwin\home\db3l\buildarea\2.5.bolen-windows\build\lib\mailbox.py", line 315, in get_message subpath = self._lookup(key) File "E:\cygwin\home\db3l\buildarea\2.5.bolen-windows\build\lib\mailbox.py", line 484, in _lookup raise KeyError('No message with key: %s' % key) KeyError: 'No message with key: 1200785941.M680000P1548Q203.buildbot' sincerely, -The Buildbot From python-checkins at python.org Sun Jan 20 00:44:41 2008 From: python-checkins at python.org (andrew.kuchling) Date: Sun, 20 Jan 2008 00:44:41 +0100 (CET) Subject: [Python-checkins] r60118 - python/branches/release25-maint/Lib/curses/textpad.py Message-ID: <20080119234441.1B5DD1E401A@bag.python.org> Author: andrew.kuchling Date: Sun Jan 20 00:44:39 2008 New Revision: 60118 Modified: python/branches/release25-maint/Lib/curses/textpad.py Log: Fix off-by-one error that resulted in missed characters Modified: python/branches/release25-maint/Lib/curses/textpad.py ============================================================================== --- python/branches/release25-maint/Lib/curses/textpad.py (original) +++ python/branches/release25-maint/Lib/curses/textpad.py Sun Jan 20 00:44:39 2008 @@ -139,7 +139,7 @@ if stop == 0 and self.stripspaces: continue for x in range(self.maxx+1): - if self.stripspaces and x == stop: + if self.stripspaces and x > stop: break result = result + chr(ascii.ascii(self.win.inch(y, x))) if self.maxy > 0: From python-checkins at python.org Sun Jan 20 01:00:39 2008 From: python-checkins at python.org (andrew.kuchling) Date: Sun, 20 Jan 2008 01:00:39 +0100 (CET) Subject: [Python-checkins] r60119 - in python/trunk: Doc/whatsnew/2.6.rst Lib/curses/textpad.py Misc/ACKS Misc/NEWS Message-ID: <20080120000039.71FC41E401A@bag.python.org> Author: andrew.kuchling Date: Sun Jan 20 01:00:38 2008 New Revision: 60119 Modified: python/trunk/Doc/whatsnew/2.6.rst python/trunk/Lib/curses/textpad.py python/trunk/Misc/ACKS python/trunk/Misc/NEWS Log: Patch #1048820 from Stefan Wehr: add insert-mode editing to Textbox. Fix an off-by-one error I noticed. Modified: python/trunk/Doc/whatsnew/2.6.rst ============================================================================== --- python/trunk/Doc/whatsnew/2.6.rst (original) +++ python/trunk/Doc/whatsnew/2.6.rst Sun Jan 20 01:00:38 2008 @@ -868,16 +868,19 @@ .. Revision 57769 - * A new method in the :mod:`curses` module: for a window, :meth:`chgat` changes the display characters for a certain number of characters on a single line. + (Contributed by Fabian Kreutz.) :: # Boldface text starting at y=0,x=21 # and affecting the rest of the line. stdscr.chgat(0,21, curses.A_BOLD) - (Contributed by Fabian Kreutz.) + The :class:`Textbox` class in the :mod:`curses.textpad` module + now supports editing in insert mode as well as overwrite mode. + Insert mode is enabled by supplying a true value for the *insert_mode* + parameter when creating the :class:`Textbox` instance. * The :mod:`decimal` module was updated to version 1.66 of `the General Decimal Specification `__. New features Modified: python/trunk/Lib/curses/textpad.py ============================================================================== --- python/trunk/Lib/curses/textpad.py (original) +++ python/trunk/Lib/curses/textpad.py Sun Jan 20 01:00:38 2008 @@ -39,8 +39,9 @@ KEY_LEFT = Ctrl-B, KEY_RIGHT = Ctrl-F, KEY_UP = Ctrl-P, KEY_DOWN = Ctrl-N KEY_BACKSPACE = Ctrl-h """ - def __init__(self, win): + def __init__(self, win, insert_mode=False): self.win = win + self.insert_mode = insert_mode (self.maxy, self.maxx) = win.getmaxyx() self.maxy = self.maxy - 1 self.maxx = self.maxx - 1 @@ -49,9 +50,10 @@ win.keypad(1) def _end_of_line(self, y): - "Go to the location of the first blank on the given line." + """Go to the location of the first blank on the given line, + returning the index of the last non-blank character.""" last = self.maxx - while 1: + while True: if ascii.ascii(self.win.inch(y, last)) != ascii.SP: last = min(self.maxx, last+1) break @@ -60,19 +62,31 @@ last = last - 1 return last + def _insert_printable_char(self, ch): + (y, x) = self.win.getyx() + if y < self.maxy or x < self.maxx: + if self.insert_mode: + oldch = self.win.inch() + # The try-catch ignores the error we trigger from some curses + # versions by trying to write into the lowest-rightmost spot + # in the window. + try: + self.win.addch(ch) + except curses.error: + pass + if self.insert_mode: + (backy, backx) = self.win.getyx() + if ascii.isprint(oldch): + self._insert_printable_char(oldch) + self.win.move(backy, backx) + def do_command(self, ch): "Process a single editing command." (y, x) = self.win.getyx() self.lastcmd = ch if ascii.isprint(ch): if y < self.maxy or x < self.maxx: - # The try-catch ignores the error we trigger from some curses - # versions by trying to write into the lowest-rightmost spot - # in the window. - try: - self.win.addch(ch) - except curses.error: - pass + self._insert_printable_char(ch) elif ch == ascii.SOH: # ^a self.win.move(y, 0) elif ch in (ascii.STX,curses.KEY_LEFT, ascii.BS,curses.KEY_BACKSPACE): @@ -139,7 +153,7 @@ if stop == 0 and self.stripspaces: continue for x in range(self.maxx+1): - if self.stripspaces and x == stop: + if self.stripspaces and x > stop: break result = result + chr(ascii.ascii(self.win.inch(y, x))) if self.maxy > 0: Modified: python/trunk/Misc/ACKS ============================================================================== --- python/trunk/Misc/ACKS (original) +++ python/trunk/Misc/ACKS Sun Jan 20 01:00:38 2008 @@ -696,6 +696,7 @@ Aaron Watters Henrik Weber Corran Webster +Stefan Wehr Zack Weinberg Edward Welbourne Cliff Wells Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Sun Jan 20 01:00:38 2008 @@ -390,6 +390,10 @@ - #1837: The queue module now also supports a LIFO queue and a priority queue. +- Patch #1048820: Add insert-mode editing to curses.textpad.Textbox + (patch by Stefan Wehr). Also, fix an off-by-one bug in + Textbox.gather(). + - Issue #1831: ctypes now raises a TypeError if conflicting positional and named arguments are passed to a Structure or Union initializer. When too many positional arguments are passed, also a TypeError is From python-checkins at python.org Sun Jan 20 01:12:19 2008 From: python-checkins at python.org (andrew.kuchling) Date: Sun, 20 Jan 2008 01:12:19 +0100 (CET) Subject: [Python-checkins] r60120 - python/trunk/Lib/test/curses_tests.py Message-ID: <20080120001219.CBC7E1E401A@bag.python.org> Author: andrew.kuchling Date: Sun Jan 20 01:12:19 2008 New Revision: 60120 Added: python/trunk/Lib/test/curses_tests.py Log: Add an interactive test script for exercising curses Added: python/trunk/Lib/test/curses_tests.py ============================================================================== --- (empty file) +++ python/trunk/Lib/test/curses_tests.py Sun Jan 20 01:12:19 2008 @@ -0,0 +1,46 @@ +#!/usr/bin/env python +# +# $Id: ncurses.py 36559 2004-07-18 05:56:09Z tim_one $ +# +# Interactive test suite for the curses module. +# This script displays various things and the user should verify whether +# they display correctly. +# + +import curses +from curses import textpad + +def test_textpad(stdscr, insert_mode=False): + ncols, nlines = 8, 3 + uly, ulx = 3, 2 + if insert_mode: + mode = 'insert mode' + else: + mode = 'overwrite mode' + + stdscr.addstr(uly-3, ulx, "Use Ctrl-G to end editing (%s)." % mode) + stdscr.addstr(uly-2, ulx, "Be sure to try typing in the lower-right corner.") + win = curses.newwin(nlines, ncols, uly, ulx) + textpad.rectangle(stdscr, uly-1, ulx-1, uly + nlines, ulx + ncols) + stdscr.refresh() + + box = textpad.Textbox(win, insert_mode) + contents = box.edit() + stdscr.addstr(uly+ncols+2, 0, "Text entered in the box\n") + stdscr.addstr(repr(contents)) + stdscr.addstr('\n') + stdscr.addstr('Press any key') + stdscr.getch() + + for i in range(3): + stdscr.move(uly+ncols+2 + i, 0) + stdscr.clrtoeol() + +def main(stdscr): + stdscr.clear() + test_textpad(stdscr, False) + test_textpad(stdscr, True) + + +if __name__ == '__main__': + curses.wrapper(main) From nnorwitz at gmail.com Sun Jan 20 01:56:44 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Sat, 19 Jan 2008 19:56:44 -0500 Subject: [Python-checkins] Python Regression Test Failures refleak (7) Message-ID: <20080120005644.GA21866@python.psfb.org> test_opcodes leaked [-2, 0, 2] references, sum=0 test_doctest leaked [0, 0, -4] references, sum=-4 test_descrtut leaked [-4, 4, 2] references, sum=2 test_docxmlrpc leaked [-11, 11, 0] references, sum=0 test_dummy_threading leaked [-2, 0, 0] references, sum=-2 test_gc leaked [0, 2, -2] references, sum=0 test_genexps leaked [0, -2, 2] references, sum=0 test_importhooks leaked [-8, 4, -4] references, sum=-8 test_peepholer leaked [0, -2, 0] references, sum=-2 test_threadsignals leaked [-188, 0, -8] references, sum=-196 test_tokenize leaked [0, -2, 0] references, sum=-2 test_urllib2_localnet leaked [3, 3, 3] references, sum=9 test_weakref leaked [-2, 2, 0] references, sum=0 test_whichdb leaked [-2, 0, 0] references, sum=-2 From nnorwitz at gmail.com Sun Jan 20 02:14:05 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Sat, 19 Jan 2008 20:14:05 -0500 Subject: [Python-checkins] Python Regression Test Failures all (1) Message-ID: <20080120011405.GA23954@python.psfb.org> test_grammar test_opcodes test_dict test_builtin test_exceptions test_types test_unittest test_doctest test_doctest2 test_MimeWriter test_StringIO test___all__ test___future__ test__locale test_abc test_abstract_numbers test_aepack test_aepack skipped -- No module named aepack test_al test_al skipped -- No module named al test_anydbm test_applesingle test_applesingle skipped -- No module named macostools test_array test_ast test_asynchat test_asyncore test_atexit test_audioop test_augassign test_base64 test_bastion test_bigaddrspace test_bigmem test_binascii test_binhex test_binop test_bisect test_bool test_bsddb test_bsddb185 test_bsddb185 skipped -- No module named bsddb185 test_bsddb3 test test_bsddb3 failed -- errors occurred; run in verbose mode for details test_buffer test_bufio test_bz2 test_cProfile test_calendar test_call test_capi test_cd test_cd skipped -- No module named cd test_cfgparser test_cgi test_charmapcodec test_cl test_cl skipped -- No module named cl test_class test_cmath test_cmd test_cmd_line test_cmd_line_script test_code test_codeccallbacks test_codecencodings_cn test_codecencodings_hk test_codecencodings_jp test_codecencodings_kr test_codecencodings_tw test_codecmaps_cn test_codecmaps_hk test_codecmaps_jp test_codecmaps_kr test_codecmaps_tw test_codecs test_codeop test_coding test_coercion test_collections test_colorsys test_commands test_compare test_compile test_compiler testCompileLibrary still working, be patient... test_complex test_complex_args test_contains test_contextlib test_cookie test_cookielib test_copy test_copy_reg test_cpickle test_crypt test_csv test_ctypes test_datetime test_dbm test_decimal test_decorators test_defaultdict test_deque test_descr test_descrtut test_difflib test_dircache test_dis test_distutils test_dl test_docxmlrpc test_dumbdbm test_dummy_thread test_dummy_threading test_email test_email_codecs test_email_renamed test_enumerate test_eof test_errno test_exception_variations test_extcall test_fcntl test_file test_filecmp test_fileinput test_float test_fnmatch test_fork1 test_format test_fpformat test_frozen test_ftplib test_funcattrs test_functools test_future test_gc test_gdbm test_generators test_genericpath test_genexps test_getargs test_getargs2 test_getopt test_gettext test_gl test_gl skipped -- No module named gl test_glob test_global test_grp test_gzip test_hash test_hashlib test_heapq test_hexoct test_hmac test_hotshot test_htmllib test_htmlparser test_httplib test_imageop test_imageop skipped -- No module named imgfile test_imaplib test_imgfile test_imgfile skipped -- No module named imgfile test_imp test_import test_importhooks test_index test_inspect test_ioctl test_ioctl skipped -- Unable to open /dev/tty test_isinstance test_iter test_iterlen test_itertools test_largefile test_list test_locale test_logging test_long test_long_future test_longexp test_macostools test_macostools skipped -- No module named macostools test_macpath test_mailbox test_marshal test_math test_md5 test_mhlib test_mimetools test_mimetypes test_minidom test_mmap test_module test_modulefinder test_multibytecodec test_multibytecodec_support test_multifile test_mutants test_netrc test_new test_nis test_normalization test_ntpath test_old_mailbox test_openpty test_operator test_optparse test_os test_parser test_peepholer test_pep247 test_pep263 test_pep277 test_pep277 skipped -- test works only on NT+ test_pep292 test_pep352 test_pickle test_pickletools test_pipes test_pkg test_pkgimport test_platform test_plistlib test_plistlib skipped -- No module named plistlib test_poll test_popen [8900 refs] [8900 refs] [8900 refs] test_popen2 test_poplib test_posix test_posixpath test_pow test_pprint test_profile test_profilehooks test_property test_pty test_pwd test_pyclbr test_pyexpat test_queue test_quopri [9269 refs] [9269 refs] test_random test_rational test_re test_repr test_resource test_rfc822 test_richcmp test_robotparser test_runpy test_sax test_scope test_scriptpackages test_scriptpackages skipped -- No module named aetools test_select test_set test_sets test_sgmllib test_sha test_shelve test_shlex test_shutil test_signal test_site test_slice test_smtplib test_socket test_socket_ssl /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:94: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ssl_sock = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:60: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:130: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:144: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) test_socketserver test_softspace test_sort test_sqlite test_ssl test_startfile test_startfile skipped -- cannot import name startfile test_str test_strftime test_string test_stringprep test_strop test_strptime test_struct test_structmembers test_structseq test_subprocess [8895 refs] [8898 refs] [8895 refs] [8895 refs] [8895 refs] [8895 refs] [8895 refs] [8895 refs] [8895 refs] [8897 refs] [8898 refs] [10449 refs] [9113 refs] [8898 refs] [8895 refs] [8895 refs] [8895 refs] [8895 refs] [8895 refs] . [8895 refs] [8895 refs] this bit of output is from a test of stdout in a different process ... [8895 refs] [8895 refs] [9113 refs] test_sunaudiodev test_sunaudiodev skipped -- No module named sunaudiodev test_sundry test_symtable test_syntax test_sys [8895 refs] [8895 refs] test_tarfile test_tcl test_tcl skipped -- No module named _tkinter test_telnetlib test_tempfile [8901 refs] test_textwrap test_thread test_threaded_import test_threadedtempfile test_threading [13143 refs] test_threading_local test_threadsignals test_time test_timeout test_tokenize test_trace test_traceback test_transformer test_tuple test_typechecks test_ucn test_unary test_unicode test_unicode_file test_unicode_file skipped -- No Unicode filesystem semantics on this platform. test_unicodedata test_univnewlines test_unpack test_urllib test_urllib2 test_urllib2_localnet test_urllib2net test_urllibnet test_urlparse test_userdict test_userlist test_userstring test_uu test_uuid WARNING: uuid.getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._ifconfig_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._unixdll_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. test_wait3 test_wait4 test_warnings test_wave test_weakref test_whichdb test_winreg test_winreg skipped -- No module named _winreg test_winsound test_winsound skipped -- No module named winsound test_with test_wsgiref test_xdrlib test_xml_etree test_xml_etree_c test_xmllib test_xmlrpc test_xpickle test_xrange test_zipfile test_zipfile64 test_zipfile64 skipped -- test requires loads of disk-space bytes and a long time to run test_zipimport test_zlib 313 tests OK. 1 test failed: test_bsddb3 21 tests skipped: test_aepack test_al test_applesingle test_bsddb185 test_cd test_cl test_gl test_imageop test_imgfile test_ioctl test_macostools test_pep277 test_plistlib test_scriptpackages test_startfile test_sunaudiodev test_tcl test_unicode_file test_winreg test_winsound test_zipfile64 1 skip unexpected on linux2: test_ioctl [540802 refs] From python-checkins at python.org Sun Jan 20 02:21:04 2008 From: python-checkins at python.org (gregory.p.smith) Date: Sun, 20 Jan 2008 02:21:04 +0100 (CET) Subject: [Python-checkins] r60121 - in python/trunk/Lib: test/test_zipfile.py zipfile.py Message-ID: <20080120012104.3B00F1E401A@bag.python.org> Author: gregory.p.smith Date: Sun Jan 20 02:21:03 2008 New Revision: 60121 Modified: python/trunk/Lib/test/test_zipfile.py python/trunk/Lib/zipfile.py Log: Fix zipfile decryption. The check for validity only worked on one type of encrypted zip files. Files using extended local headers needed to compare the check byte against different values. (according to reading the infozip unzip crypt.c source code) Fixes issue1003. Modified: python/trunk/Lib/test/test_zipfile.py ============================================================================== --- python/trunk/Lib/test/test_zipfile.py (original) +++ python/trunk/Lib/test/test_zipfile.py Sun Jan 20 02:21:03 2008 @@ -698,31 +698,52 @@ '\x1a\x00\x00\x00\x08\x00\x00\x00\x00\x00\x00\x00\x01\x00 \x00\xb6\x81' '\x00\x00\x00\x00test.txtPK\x05\x06\x00\x00\x00\x00\x01\x00\x01\x006\x00' '\x00\x00L\x00\x00\x00\x00\x00' ) + data2 = ( + 'PK\x03\x04\x14\x00\t\x00\x08\x00\xcf}38xu\xaa\xb2\x14\x00\x00\x00\x00\x02' + '\x00\x00\x04\x00\x15\x00zeroUT\t\x00\x03\xd6\x8b\x92G\xda\x8b\x92GUx\x04' + '\x00\xe8\x03\xe8\x03\xc7>9)+1980, (d>>5)&0xF, d&0x1F, t>>11, (t>>5)&0x3F, (t&0x1F) * 2 ) @@ -790,11 +792,18 @@ # The first 12 bytes in the cypher stream is an encryption header # used to strengthen the algorithm. The first 11 bytes are # completely random, while the 12th contains the MSB of the CRC, + # or the MSB of the file time depending on the header type # and is used to check the correctness of the password. bytes = zef_file.read(12) h = map(zd, bytes[0:12]) - if ord(h[11]) != ((zinfo.CRC>>24)&255): - raise RuntimeError, "Bad password for file %s" % name + if zinfo.flag_bits & 0x8: + # compare against the file type from extended local headers + check_byte = (zinfo._raw_time >> 8) & 0xff + else: + # compare against the CRC otherwise + check_byte = (zinfo.CRC >> 24) & 0xff + if ord(h[11]) != check_byte: + raise RuntimeError("Bad password for file", name) # build and return a ZipExtFile if zd is None: From python-checkins at python.org Sun Jan 20 02:26:04 2008 From: python-checkins at python.org (gregory.p.smith) Date: Sun, 20 Jan 2008 02:26:04 +0100 (CET) Subject: [Python-checkins] r60122 - python/trunk/Misc/NEWS Message-ID: <20080120012604.AB5CB1E4020@bag.python.org> Author: gregory.p.smith Date: Sun Jan 20 02:26:04 2008 New Revision: 60122 Modified: python/trunk/Misc/NEWS Log: note for r60121 Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Sun Jan 20 02:26:04 2008 @@ -369,6 +369,9 @@ Library ------- +- Issue #1003: Fix zipfile decryption check, it would fail zip files + with extended local headers. + - #1189216: Fix the zipfile module to work on archives with headers past the 2**31 byte boundary. From python-checkins at python.org Sun Jan 20 02:32:00 2008 From: python-checkins at python.org (gregory.p.smith) Date: Sun, 20 Jan 2008 02:32:00 +0100 (CET) Subject: [Python-checkins] r60123 - in python/trunk: Doc/library/zipfile.rst Lib/zipfile.py Message-ID: <20080120013200.947E61E401A@bag.python.org> Author: gregory.p.smith Date: Sun Jan 20 02:32:00 2008 New Revision: 60123 Modified: python/trunk/Doc/library/zipfile.rst python/trunk/Lib/zipfile.py Log: Document that zipfile decryption is insanely slow and fix a typo and blatant lie in a docstring (it is not useful for security regardless of how you spell it). Modified: python/trunk/Doc/library/zipfile.rst ============================================================================== --- python/trunk/Doc/library/zipfile.rst (original) +++ python/trunk/Doc/library/zipfile.rst Sun Jan 20 02:32:00 2008 @@ -21,7 +21,8 @@ documentation). It can handle ZIP files that use the ZIP64 extensions (that is ZIP files that are more than 4 GByte in size). It supports decryption of encrypted files in ZIP archives, but it currently cannot -create an encrypted file. +create an encrypted file. Decryption is extremely slow as it is +implemented in native python rather than C. For other archive formats, see the :mod:`bz2`, :mod:`gzip`, and :mod:`tarfile` modules. Modified: python/trunk/Lib/zipfile.py ============================================================================== --- python/trunk/Lib/zipfile.py (original) +++ python/trunk/Lib/zipfile.py Sun Jan 20 02:32:00 2008 @@ -302,7 +302,7 @@ ZIP supports a password-based form of encryption. Even though known plaintext attacks have been found against it, it is still useful - for low-level securicy. + to be able to get data out of such a file. Usage: zd = _ZipDecrypter(mypwd) From buildbot at python.org Sun Jan 20 06:54:11 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 20 Jan 2008 05:54:11 +0000 Subject: [Python-checkins] buildbot failure in x86 FreeBSD trunk Message-ID: <20080120055411.9B70E1E4006@bag.python.org> The Buildbot has detected a new failure of x86 FreeBSD trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20FreeBSD%20trunk/builds/431 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-freebsd Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: andrew.kuchling,gregory.p.smith BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 227, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 268, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 281, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 560, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 227, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 268, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 281, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 560, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 227, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 268, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 281, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 560, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 227, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 268, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 281, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 560, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable 1 test failed: test_xmlrpc sincerely, -The Buildbot From python-checkins at python.org Sun Jan 20 10:47:50 2008 From: python-checkins at python.org (martin.v.loewis) Date: Sun, 20 Jan 2008 10:47:50 +0100 (CET) Subject: [Python-checkins] r60127 - tracker/importer/xmlexport2toroundup.py Message-ID: <20080120094750.763471E401D@bag.python.org> Author: martin.v.loewis Date: Sun Jan 20 10:47:50 2008 New Revision: 60127 Modified: tracker/importer/xmlexport2toroundup.py Log: Add --update option, which doesn't set the next id. Modified: tracker/importer/xmlexport2toroundup.py ============================================================================== --- tracker/importer/xmlexport2toroundup.py (original) +++ tracker/importer/xmlexport2toroundup.py Sun Jan 20 10:47:50 2008 @@ -127,9 +127,10 @@ xmlfile = "small.xml" trackerhome = "/var/lib/roundup/trackers/python-dev" startat = 0 + update = False opts, args = getopt.getopt(sys.argv[1:], "", ["xmlfile=", "trackerhome=", - "startat="]) + "startat=", "update"]) for opt, optarg in opts: if "--xmlfile" == opt: xmlfile = optarg @@ -137,6 +138,8 @@ trackerhome = optarg elif "--startat" == opt: startat = int(optarg) + elif "--update" == opt: + update = 1 rounduptracker = instance.open(trackerhome) db = rounduptracker.open("admin") @@ -151,7 +154,8 @@ for tracker in trackers.findall("tracker"): handle_tracker(db, project_group_id, tracker, pmembers) - db.setid('issue', str(999)) + if not update: + db.setid('issue', str(999)) db.commit() From nnorwitz at gmail.com Sun Jan 20 11:34:55 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Sun, 20 Jan 2008 05:34:55 -0500 Subject: [Python-checkins] Python Regression Test Failures refleak (8) Message-ID: <20080120103455.GA24572@python.psfb.org> test_opcodes leaked [-2, 0, 2] references, sum=0 test_doctest leaked [0, 0, -2] references, sum=-2 test_cmd_line leaked [-23, 23, 0] references, sum=0 test_descrtut leaked [0, -4, 6] references, sum=2 test_dummy_thread leaked [-2, 0, 0] references, sum=-2 test_dummy_threading leaked [-2, 0, 0] references, sum=-2 test_gc leaked [0, 2, -2] references, sum=0 test_importhooks leaked [6, -4, 6] references, sum=8 test_pep247 leaked [0, 0, -2] references, sum=-2 test_pkgimport leaked [-2, 2, 0] references, sum=0 test_popen2 leaked [26, 0, -26] references, sum=0 test_threadsignals leaked [-188, 0, -8] references, sum=-196 test_timeout leaked [0, 0, -2] references, sum=-2 test_urllib2_localnet leaked [3, 3, 3] references, sum=9 test_urllibnet leaked [0, 0, -2] references, sum=-2 From nnorwitz at gmail.com Sun Jan 20 11:52:10 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Sun, 20 Jan 2008 05:52:10 -0500 Subject: [Python-checkins] Python Regression Test Failures all (1) Message-ID: <20080120105210.GA26654@python.psfb.org> test_grammar test_opcodes test_dict test_builtin test_exceptions test_types test_unittest test_doctest test_doctest2 test_MimeWriter test_StringIO test___all__ test___future__ test__locale test_abc test_abstract_numbers test_aepack test_aepack skipped -- No module named aepack test_al test_al skipped -- No module named al test_anydbm test_applesingle test_applesingle skipped -- No module named macostools test_array test_ast test_asynchat test_asyncore test_atexit test_audioop test_augassign test_base64 test_bastion test_bigaddrspace test_bigmem test_binascii test_binhex test_binop test_bisect test_bool test_bsddb test_bsddb185 test_bsddb185 skipped -- No module named bsddb185 test_bsddb3 test test_bsddb3 failed -- errors occurred; run in verbose mode for details test_buffer test_bufio test_bz2 test_cProfile test_calendar test_call test_capi test_cd test_cd skipped -- No module named cd test_cfgparser test_cgi test_charmapcodec test_cl test_cl skipped -- No module named cl test_class test_cmath test_cmd test_cmd_line test_cmd_line_script test_code test_codeccallbacks test_codecencodings_cn test_codecencodings_hk test_codecencodings_jp test_codecencodings_kr test_codecencodings_tw test_codecmaps_cn test_codecmaps_hk test_codecmaps_jp test_codecmaps_kr test_codecmaps_tw test_codecs test_codeop test_coding test_coercion test_collections test_colorsys test_commands test_compare test_compile test_compiler testCompileLibrary still working, be patient... test_complex test_complex_args test_contains test_contextlib test_cookie test_cookielib test_copy test_copy_reg test_cpickle test_crypt test_csv test_ctypes test_datetime test_dbm test_decimal test_decorators test_defaultdict test_deque test_descr test_descrtut test_difflib test_dircache test_dis test_distutils test_dl test_docxmlrpc test_dumbdbm test_dummy_thread test_dummy_threading test_email test_email_codecs test_email_renamed test_enumerate test_eof test_errno test_exception_variations test_extcall test_fcntl test_file test_filecmp test_fileinput test_float test_fnmatch test_fork1 test_format test_fpformat test_frozen test_ftplib test_funcattrs test_functools test_future test_gc test_gdbm test_generators test_genericpath test_genexps test_getargs test_getargs2 test_getopt test_gettext test_gl test_gl skipped -- No module named gl test_glob test_global test_grp test_gzip test_hash test_hashlib test_heapq test_hexoct test_hmac test_hotshot test_htmllib test_htmlparser test_httplib test_imageop test_imageop skipped -- No module named imgfile test_imaplib test_imgfile test_imgfile skipped -- No module named imgfile test_imp test_import test_importhooks test_index test_inspect test_ioctl test_ioctl skipped -- Unable to open /dev/tty test_isinstance test_iter test_iterlen test_itertools test_largefile test_list test_locale test_logging test_long test_long_future test_longexp test_macostools test_macostools skipped -- No module named macostools test_macpath test_mailbox test_marshal test_math test_md5 test_mhlib test_mimetools test_mimetypes test_minidom test_mmap test_module test_modulefinder test_multibytecodec test_multibytecodec_support test_multifile test_mutants test_netrc test_new test_nis test_normalization test_ntpath test_old_mailbox test_openpty test_operator test_optparse test_os test_parser test_peepholer test_pep247 test_pep263 test_pep277 test_pep277 skipped -- test works only on NT+ test_pep292 test_pep352 test_pickle test_pickletools test_pipes test_pkg test_pkgimport test_platform test_plistlib test_plistlib skipped -- No module named plistlib test_poll test_popen [8900 refs] [8900 refs] [8900 refs] test_popen2 test_poplib test_posix test_posixpath test_pow test_pprint test_profile test_profilehooks test_property test_pty test_pwd test_pyclbr test_pyexpat test_queue test_quopri [9269 refs] [9269 refs] test_random test_rational test_re test_repr test_resource test_rfc822 test_richcmp test_robotparser test_runpy test_sax test_scope test_scriptpackages test_scriptpackages skipped -- No module named aetools test_select test_set test_sets test_sgmllib test_sha test_shelve test_shlex test_shutil test_signal test_site test_slice test_smtplib test_socket test_socket_ssl /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:94: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ssl_sock = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:60: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:130: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:144: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) test_socketserver test_softspace test_sort test_sqlite test_ssl test_startfile test_startfile skipped -- cannot import name startfile test_str test_strftime test_string test_stringprep test_strop test_strptime test_struct test_structmembers test_structseq test_subprocess [8895 refs] [8898 refs] [8895 refs] [8895 refs] [8895 refs] [8895 refs] [8895 refs] [8895 refs] [8895 refs] [8897 refs] [8898 refs] [10449 refs] [9113 refs] [8898 refs] [8895 refs] [8895 refs] [8895 refs] [8895 refs] [8895 refs] . [8895 refs] [8895 refs] this bit of output is from a test of stdout in a different process ... [8895 refs] [8895 refs] [9113 refs] test_sunaudiodev test_sunaudiodev skipped -- No module named sunaudiodev test_sundry test_symtable test_syntax test_sys [8895 refs] [8895 refs] test_tarfile test_tcl test_tcl skipped -- No module named _tkinter test_telnetlib test_tempfile [8901 refs] test_textwrap test_thread test_threaded_import test_threadedtempfile test_threading [13143 refs] test_threading_local test_threadsignals test_time test_timeout test_tokenize test_trace test_traceback test_transformer test_tuple test_typechecks test_ucn test_unary test_unicode test_unicode_file test_unicode_file skipped -- No Unicode filesystem semantics on this platform. test_unicodedata test_univnewlines test_unpack test_urllib test_urllib2 test_urllib2_localnet test_urllib2net test_urllibnet test_urlparse test_userdict test_userlist test_userstring test_uu test_uuid WARNING: uuid.getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._ifconfig_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._unixdll_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. test_wait3 test_wait4 test_warnings test_wave test_weakref test_whichdb test_winreg test_winreg skipped -- No module named _winreg test_winsound test_winsound skipped -- No module named winsound test_with test_wsgiref test_xdrlib test_xml_etree test_xml_etree_c test_xmllib test_xmlrpc test_xpickle test_xrange test_zipfile /tmp/python-test/local/lib/python2.6/test/test_zipfile.py:471: DeprecationWarning: struct integer overflow masking is deprecated zipfp.close() /tmp/python-test/local/lib/python2.6/test/test_zipfile.py:398: DeprecationWarning: struct integer overflow masking is deprecated zipfp.close() test_zipfile64 test_zipfile64 skipped -- test requires loads of disk-space bytes and a long time to run test_zipimport test_zlib 313 tests OK. 1 test failed: test_bsddb3 21 tests skipped: test_aepack test_al test_applesingle test_bsddb185 test_cd test_cl test_gl test_imageop test_imgfile test_ioctl test_macostools test_pep277 test_plistlib test_scriptpackages test_startfile test_sunaudiodev test_tcl test_unicode_file test_winreg test_winsound test_zipfile64 1 skip unexpected on linux2: test_ioctl [540847 refs] From buildbot at python.org Sun Jan 20 11:37:19 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 20 Jan 2008 10:37:19 +0000 Subject: [Python-checkins] buildbot failure in x86 XP-4 3.0 Message-ID: <20080120103720.15CFE1E401D@bag.python.org> The Buildbot has detected a new failure of x86 XP-4 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20XP-4%203.0/builds/433 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-windows Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes,georg.brandl BUILD FAILED: failed test Excerpt from the test logfile: 8 tests failed: test_anydbm test_bsddb test_bsddb3 test_mailbox test_shelve test_whichdb test_winreg test_zipfile ====================================================================== ERROR: test_anydbm_access (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 90, in test_anydbm_access self.init_db() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 103, in init_db f = anydbm.open(_fname, 'n') File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_anydbm_creation (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 63, in test_anydbm_creation f = anydbm.open(_fname, 'c') File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_anydbm_keys (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 84, in test_anydbm_keys self.init_db() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 103, in init_db f = anydbm.open(_fname, 'n') File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_anydbm_modification (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 71, in test_anydbm_modification self.init_db() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 103, in init_db f = anydbm.open(_fname, 'n') File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_anydbm_read (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 78, in test_anydbm_read self.init_db() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 103, in init_db f = anydbm.open(_fname, 'n') File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') Traceback (most recent call last): File "../lib/test/regrtest.py", line 596, in runtest_inner indirect_test() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb3.py", line 64, in test_main run_unittest(suite()) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb3.py", line 28, in suite import bsddb.test.test_1413192 File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\test\test_1413192.py", line 38, in context = Context() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\test\test_1413192.py", line 26, in __init__ db.DB_CREATE | db.DB_INIT_TXN | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_consistent_factory (test.test_mailbox.TestMaildir) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 520, in test_consistent_factory msg2 = box.get_message(key) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\mailbox.py", line 313, in get_message subpath = self._lookup(key) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\mailbox.py", line 482, in _lookup raise KeyError('No message with key: %s' % key) KeyError: 'No message with key: 1200825310.M625000P2404Q201.buildbot' ====================================================================== ERROR: test_flush (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 717, in tearDown self._delete_recursively(self._path) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 47, in _delete_recursively os.remove(target) WindowsError: [Error 32] The process cannot access the file because it is being used by another process: '@test' ====================================================================== ERROR: test_popitem (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 336, in test_popitem self.assertEqual(int(msg.get_payload()), keys.index(key)) ValueError: invalid literal for int() with base 10: 'From: foo 0 F' ====================================================================== ERROR: test_flush (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 717, in tearDown self._delete_recursively(self._path) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 47, in _delete_recursively os.remove(target) WindowsError: [Error 32] The process cannot access the file because it is being used by another process: '@test' ====================================================================== ERROR: test_popitem (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 336, in test_popitem self.assertEqual(int(msg.get_payload()), keys.index(key)) ValueError: invalid literal for int() with base 10: 'From: foo 0 \x01' ====================================================================== ERROR: test_flush (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 940, in tearDown self._delete_recursively(self._path) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 47, in _delete_recursively os.remove(target) WindowsError: [Error 32] The process cannot access the file because it is being used by another process: '@test' ====================================================================== ERROR: test_popitem (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 336, in test_popitem self.assertEqual(int(msg.get_payload()), keys.index(key)) ValueError: invalid literal for int() with base 10: 'From: foo *** EOOH *** From: foo 0 1,, From: foo *** EOOH *** From: foo 1 1,, From: foo *** EOOH *** From: foo 2 1,, From: foo *** EOOH *** From: foo 3 ' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestMaildir) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_add (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 77, in test_add self.assertEqual(self._box.get_string(keys[0]), self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\nF' != 'From: foo\n\n0' ====================================================================== FAIL: test_add_and_close (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 757, in test_add_and_close self.assertEqual(contents, open(self._path, 'r').read()) AssertionError: 'From MAILER-DAEMON Sun Jan 20 10:35:26 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Sun Jan 20 10:35:27 2008\n\nFrom: foo\n\n0\n\nFrom MAILER-DAEMON Sun Jan 20 10:35:27 2008\n\nFrom: foo\n\n1\n\nFrom MAILER-DAEMON Sun Jan 20 10:35:27 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Sun Jan 20 10:35:27 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'From MAILER-DAEMON Sun Jan 20 10:35:26 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Sun Jan 20 10:35:27 2008\n\nFrom: foo\n\n0\n\nFrom MAILER-DAEMON Sun Jan 20 10:35:27 2008\n\nFrom: foo\n\n1\n\nFrom MAILER-DAEMON Sun Jan 20 10:35:27 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Sun Jan 20 10:35:27 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Sun Jan 20 10:35:27 2008\n\nFrom: foo\n\n0\n\nFrom MAILER-DAEMON Sun Jan 20 10:35:27 2008\n\nFrom: foo\n\n1\n\nFrom MAILER-DAEMON Sun Jan 20 10:35:27 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Sun Jan 20 10:35:27 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Sun Jan 20 10:35:27 2008\n\nFrom: foo\n\n1\n\nFrom MAILER-DAEMON Sun Jan 20 10:35:27 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Sun Jan 20 10:35:27 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Sun Jan 20 10:35:27 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Sun Jan 20 10:35:27 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Sun Jan 20 10:35:27 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' ====================================================================== FAIL: test_add_from_string (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 724, in test_add_from_string self.assertEqual(self._box[key].get_from(), 'foo at bar blah') AssertionError: 'foo at bar blah\n' != 'foo at bar blah' ====================================================================== FAIL: test_close (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 389, in test_close self._test_flush_or_close(self._box.close) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 6 != 3 ====================================================================== FAIL: test_delitem (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 87, in test_delitem self._test_remove_or_delitem(self._box.__delitem__) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n1' != 'From: foo\n\n1' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_flush (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 377, in test_flush self._test_flush_or_close(self._box.flush) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 6 != 3 ====================================================================== FAIL: test_get (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 129, in test_get self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_file (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 174, in test_get_file self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\nF' != 'From: foo\n\n0' ====================================================================== FAIL: test_get_message (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 156, in test_get_message self.assertEqual(msg0['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_string (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 164, in test_get_string self.assertEqual(self._box.get_string(key0), self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\nF' != 'From: foo\n\n0' ====================================================================== FAIL: test_getitem (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 144, in test_getitem self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_items (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 207, in test_items self._check_iteration(self._box.items, do_keys=True, do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iter (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 194, in test_iter do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iteritems (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 203, in test_iteritems do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_itervalues (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 189, in test_itervalues do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_open_close_open (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 741, in test_open_close_open self.assertEqual(len(self._box), 3) AssertionError: 6 != 3 ====================================================================== FAIL: test_pop (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 313, in test_pop self.assertEqual(self._box.pop(key0).get_payload(), '0') AssertionError: 'From: foo\n\n0\n\nF' != '0' ====================================================================== FAIL: test_remove (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 83, in test_remove self._test_remove_or_delitem(self._box.remove) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n1' != 'From: foo\n\n1' ====================================================================== FAIL: test_set_item (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 272, in test_set_item self._template % 'original 0') AssertionError: '\nFrom: foo\n\noriginal 0' != 'From: foo\n\noriginal 0' ====================================================================== FAIL: test_update (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 350, in test_update self._template % 'changed 0') AssertionError: '\nFrom: foo\n\nchanged 0\n\nF' != 'From: foo\n\nchanged 0' ====================================================================== FAIL: test_values (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 198, in test_values self._check_iteration(self._box.values, do_keys=False, do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_add (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 77, in test_add self.assertEqual(self._box.get_string(keys[0]), self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\n\x01' != 'From: foo\n\n0' ====================================================================== FAIL: test_add_and_close (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 757, in test_add_and_close self.assertEqual(contents, open(self._path, 'r').read()) AssertionError: '\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 20 10:35:37 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 20 10:35:37 2008\n\nFrom: foo\n\n0\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 20 10:35:37 2008\n\nFrom: foo\n\n1\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 20 10:35:37 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 20 10:35:37 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n' != '\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 20 10:35:37 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 20 10:35:37 2008\n\nFrom: foo\n\n0\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 20 10:35:37 2008\n\nFrom: foo\n\n1\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 20 10:35:37 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 20 10:35:37 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 20 10:35:37 2008\n\nFrom: foo\n\n0\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 20 10:35:37 2008\n\nFrom: foo\n\n1\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 20 10:35:37 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 20 10:35:37 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 20 10:35:37 2008\n\nFrom: foo\n\n1\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 20 10:35:37 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 20 10:35:37 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 20 10:35:37 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 20 10:35:37 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sun Jan 20 10:35:37 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n' ====================================================================== FAIL: test_add_from_string (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 724, in test_add_from_string self.assertEqual(self._box[key].get_from(), 'foo at bar blah') AssertionError: 'foo at bar blah\n' != 'foo at bar blah' ====================================================================== FAIL: test_close (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 389, in test_close self._test_flush_or_close(self._box.close) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_delitem (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 87, in test_delitem self._test_remove_or_delitem(self._box.__delitem__) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n1\n\n\x01' != 'From: foo\n\n1' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_flush (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 377, in test_flush self._test_flush_or_close(self._box.flush) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_get (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 129, in test_get self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_file (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 174, in test_get_file self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\n\x01' != 'From: foo\n\n0' ====================================================================== FAIL: test_get_message (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 156, in test_get_message self.assertEqual(msg0['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_string (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 164, in test_get_string self.assertEqual(self._box.get_string(key0), self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\n\x01' != 'From: foo\n\n0' ====================================================================== FAIL: test_getitem (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 144, in test_getitem self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_items (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 207, in test_items self._check_iteration(self._box.items, do_keys=True, do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iter (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 194, in test_iter do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iteritems (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 203, in test_iteritems do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_itervalues (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 189, in test_itervalues do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_open_close_open (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 741, in test_open_close_open self.assertEqual(len(self._box), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_pop (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 313, in test_pop self.assertEqual(self._box.pop(key0).get_payload(), '0') AssertionError: 'From: foo\n\n0\n\n\x01' != '0' ====================================================================== FAIL: test_remove (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 83, in test_remove self._test_remove_or_delitem(self._box.remove) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n1\n\n\x01' != 'From: foo\n\n1' ====================================================================== FAIL: test_set_item (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 272, in test_set_item self._template % 'original 0') AssertionError: '\nFrom: foo\n\noriginal 0\n\n\x01' != 'From: foo\n\noriginal 0' ====================================================================== FAIL: test_update (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 350, in test_update self._template % 'changed 0') AssertionError: '\nFrom: foo\n\nchanged 0\n\n\x01' != 'From: foo\n\nchanged 0' ====================================================================== FAIL: test_values (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 198, in test_values self._check_iteration(self._box.values, do_keys=False, do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestMH) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_add (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 77, in test_add self.assertEqual(self._box.get_string(keys[0]), self._template % 0) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n0\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f' != 'From: foo\n\n0' ====================================================================== FAIL: test_close (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 389, in test_close self._test_flush_or_close(self._box.close) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_delitem (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 87, in test_delitem self._test_remove_or_delitem(self._box.__delitem__) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n1\n\n\x1f' != 'From: foo\n\n1' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_flush (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 377, in test_flush self._test_flush_or_close(self._box.flush) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_get (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 129, in test_get self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_file (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 174, in test_get_file self._template % 0) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n0\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f' != 'From: foo\n\n0' ====================================================================== FAIL: test_get_message (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 156, in test_get_message self.assertEqual(msg0['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_string (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 164, in test_get_string self.assertEqual(self._box.get_string(key0), self._template % 0) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n0\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f' != 'From: foo\n\n0' ====================================================================== FAIL: test_getitem (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 144, in test_getitem self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_items (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 207, in test_items self._check_iteration(self._box.items, do_keys=True, do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iter (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 194, in test_iter do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iteritems (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 203, in test_iteritems do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_itervalues (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 189, in test_itervalues do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_pop (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 313, in test_pop self.assertEqual(self._box.pop(key0).get_payload(), '0') AssertionError: 'From: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n0\n\n\x1f\x0c\n\n1,,\n\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n1\n\n\x1f' != '0' ====================================================================== FAIL: test_remove (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 83, in test_remove self._test_remove_or_delitem(self._box.remove) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n1\n\n\x1f' != 'From: foo\n\n1' ====================================================================== FAIL: test_set_item (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 272, in test_set_item self._template % 'original 0') AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\noriginal 0\n\n\x1f' != 'From: foo\n\noriginal 0' ====================================================================== FAIL: test_update (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 350, in test_update self._template % 'changed 0') AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\nchanged 0\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f' != 'From: foo\n\nchanged 0' ====================================================================== FAIL: test_values (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 198, in test_values self._check_iteration(self._box.values, do_keys=False, do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== ERROR: test_bool (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 136, in test_bool self.assert_(not self._empty_mapping()) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_constructor (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 133, in test_constructor self.assertEqual(self._empty_mapping(), self._empty_mapping()) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 270, in test_get d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_items (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 156, in test_items d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keys (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 142, in test_keys d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 162, in test_len d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 293, in test_pop d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 288, in test_popitem d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_read (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 44, in test_read p = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 284, in test_setdefault d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 174, in test_update d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_values (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 150, in test_values d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_write (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 92, in test_write p = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_bool (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 136, in test_bool self.assert_(not self._empty_mapping()) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_constructor (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 133, in test_constructor self.assertEqual(self._empty_mapping(), self._empty_mapping()) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 270, in test_get d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_items (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 156, in test_items d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keys (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 142, in test_keys d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 162, in test_len d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 293, in test_pop d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 288, in test_popitem d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_read (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 44, in test_read p = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 284, in test_setdefault d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 174, in test_update d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_values (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 150, in test_values d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_write (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 92, in test_write p = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_bool (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 136, in test_bool self.assert_(not self._empty_mapping()) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_constructor (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 133, in test_constructor self.assertEqual(self._empty_mapping(), self._empty_mapping()) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 270, in test_get d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_items (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 156, in test_items d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keys (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 142, in test_keys d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 162, in test_len d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 293, in test_pop d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 288, in test_popitem d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_read (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 44, in test_read p = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 284, in test_setdefault d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 174, in test_update d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_values (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 150, in test_values d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_write (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 92, in test_write p = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_ascii_file_shelf (test.test_shelve.TestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 46, in test_ascii_file_shelf s = shelve.open(self.fn, protocol=0) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_binary_file_shelf (test.test_shelve.TestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 54, in test_binary_file_shelf s = shelve.open(self.fn, protocol=1) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_proto2_file_shelf (test.test_shelve.TestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 62, in test_proto2_file_shelf s = shelve.open(self.fn, protocol=2) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_whichdb (test.test_whichdb.WhichDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_whichdb.py", line 32, in test_whichdb f = module.open(_fname, 'c') File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== FAIL: testLocalMachineRegistryWorks (test.test_winreg.WinregTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_winreg.py", line 144, in testLocalMachineRegistryWorks self.TestAll(HKEY_CURRENT_USER) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_winreg.py", line 139, in TestAll self.WriteTestData(root_key, subkeystr) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_winreg.py", line 41, in WriteTestData self.assertEquals(nkeys, 1, "Not the correct number of sub keys") AssertionError: Not the correct number of sub keys ====================================================================== ERROR: testExtract (test.test_zipfile.TestsWithSourceFile) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_zipfile.py", line 350, in tearDown os.remove(TESTFN2) WindowsError: [Error 32] The process cannot access the file because it is being used by another process: '@test2' ====================================================================== FAIL: testExtract (test.test_zipfile.TestsWithSourceFile) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_zipfile.py", line 313, in testExtract self.assertEqual(writtenfile, correctfile) AssertionError: 'E:\\cygwin\\home\\db3l\\buildarea\\3.0.bolen-windows\\build\\PCbuild\\ziptest2dir\\_ziptest2' != 'E:\\cygwin\\home\\db3l\\buildarea\\3.0.bolen-windows\\build\\PCbuild\\ziptest2dir/_ziptest2' sincerely, -The Buildbot From buildbot at python.org Sun Jan 20 12:06:17 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 20 Jan 2008 11:06:17 +0000 Subject: [Python-checkins] buildbot failure in x86 FreeBSD 3.0 Message-ID: <20080120110617.B37061E4022@bag.python.org> The Buildbot has detected a new failure of x86 FreeBSD 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20FreeBSD%203.0/builds/402 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-freebsd Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes,georg.brandl BUILD FAILED: failed test Excerpt from the test logfile: sincerely, -The Buildbot From python-checkins at python.org Sun Jan 20 12:13:29 2008 From: python-checkins at python.org (georg.brandl) Date: Sun, 20 Jan 2008 12:13:29 +0100 (CET) Subject: [Python-checkins] r60131 - python/trunk/Lib/pprint.py Message-ID: <20080120111329.6A7A61E401F@bag.python.org> Author: georg.brandl Date: Sun Jan 20 12:13:29 2008 New Revision: 60131 Modified: python/trunk/Lib/pprint.py Log: #1351692: in pprint, always call format() for dict and list items to enable custom formatting of contents via subclassing PrettyPrinter. Modified: python/trunk/Lib/pprint.py ============================================================================== --- python/trunk/Lib/pprint.py (original) +++ python/trunk/Lib/pprint.py Sun Jan 20 12:13:29 2008 @@ -131,65 +131,70 @@ sepLines = _len(rep) > (self._width - 1 - indent - allowance) write = stream.write - if sepLines: - r = getattr(typ, "__repr__", None) - if issubclass(typ, dict) and r is dict.__repr__: - write('{') - if self._indent_per_level > 1: - write((self._indent_per_level - 1) * ' ') - length = _len(object) - if length: - context[objid] = 1 - indent = indent + self._indent_per_level - items = object.items() - items.sort() - key, ent = items[0] - rep = self._repr(key, context, level) - write(rep) - write(': ') - self._format(ent, stream, indent + _len(rep) + 2, - allowance + 1, context, level) - if length > 1: - for key, ent in items[1:]: - rep = self._repr(key, context, level) + r = getattr(typ, "__repr__", None) + if issubclass(typ, dict) and r is dict.__repr__: + write('{') + if self._indent_per_level > 1: + write((self._indent_per_level - 1) * ' ') + length = _len(object) + if length: + context[objid] = 1 + indent = indent + self._indent_per_level + items = object.items() + items.sort() + key, ent = items[0] + rep = self._repr(key, context, level) + write(rep) + write(': ') + self._format(ent, stream, indent + _len(rep) + 2, + allowance + 1, context, level) + if length > 1: + for key, ent in items[1:]: + rep = self._repr(key, context, level) + if sepLines: write(',\n%s%s: ' % (' '*indent, rep)) - self._format(ent, stream, indent + _len(rep) + 2, - allowance + 1, context, level) - indent = indent - self._indent_per_level - del context[objid] - write('}') - return - - if (issubclass(typ, list) and r is list.__repr__) or \ - (issubclass(typ, tuple) and r is tuple.__repr__): - if issubclass(typ, list): - write('[') - endchar = ']' - else: - write('(') - endchar = ')' - if self._indent_per_level > 1: - write((self._indent_per_level - 1) * ' ') - length = _len(object) - if length: - context[objid] = 1 - indent = indent + self._indent_per_level - self._format(object[0], stream, indent, allowance + 1, - context, level) - if length > 1: - for ent in object[1:]: + else: + write(', %s: ' % rep) + self._format(ent, stream, indent + _len(rep) + 2, + allowance + 1, context, level) + indent = indent - self._indent_per_level + del context[objid] + write('}') + return + + if (issubclass(typ, list) and r is list.__repr__) or \ + (issubclass(typ, tuple) and r is tuple.__repr__): + if issubclass(typ, list): + write('[') + endchar = ']' + else: + write('(') + endchar = ')' + if self._indent_per_level > 1: + write((self._indent_per_level - 1) * ' ') + length = _len(object) + if length: + context[objid] = 1 + indent = indent + self._indent_per_level + self._format(object[0], stream, indent, allowance + 1, + context, level) + if length > 1: + for ent in object[1:]: + if sepLines: write(',\n' + ' '*indent) - self._format(ent, stream, indent, - allowance + 1, context, level) - indent = indent - self._indent_per_level - del context[objid] - if issubclass(typ, tuple) and length == 1: - write(',') - write(endchar) - return - + else: + write(', ') + self._format(ent, stream, indent, + allowance + 1, context, level) + indent = indent - self._indent_per_level + del context[objid] + if issubclass(typ, tuple) and length == 1: + write(',') + write(endchar) + return write(rep) + def _repr(self, object, context, level): repr, readable, recursive = self.format(object, context.copy(), self._depth, level) From python-checkins at python.org Sun Jan 20 12:43:03 2008 From: python-checkins at python.org (georg.brandl) Date: Sun, 20 Jan 2008 12:43:03 +0100 (CET) Subject: [Python-checkins] r60133 - in python/trunk: Doc/library/urllib.rst Lib/test/test_urllib.py Lib/test/test_urllibnet.py Lib/urllib.py Misc/NEWS Message-ID: <20080120114303.B8ADB1E401F@bag.python.org> Author: georg.brandl Date: Sun Jan 20 12:43:03 2008 New Revision: 60133 Modified: python/trunk/Doc/library/urllib.rst python/trunk/Lib/test/test_urllib.py python/trunk/Lib/test/test_urllibnet.py python/trunk/Lib/urllib.py python/trunk/Misc/NEWS Log: #1178141: add addinfourl.code to get http status code from urllib. Modified: python/trunk/Doc/library/urllib.rst ============================================================================== --- python/trunk/Doc/library/urllib.rst (original) +++ python/trunk/Doc/library/urllib.rst Sun Jan 20 12:43:03 2008 @@ -27,16 +27,17 @@ a server somewhere on the network. If the connection cannot be made the :exc:`IOError` exception is raised. If all went well, a file-like object is returned. This supports the following methods: :meth:`read`, :meth:`readline`, - :meth:`readlines`, :meth:`fileno`, :meth:`close`, :meth:`info` and + :meth:`readlines`, :meth:`fileno`, :meth:`close`, :meth:`info`, :meth:`getcode` and :meth:`geturl`. It also has proper support for the :term:`iterator` protocol. One caveat: the :meth:`read` method, if the size argument is omitted or negative, may not read until the end of the data stream; there is no good way to determine that the entire stream from a socket has been read in the general case. - Except for the :meth:`info` and :meth:`geturl` methods, these methods have the - same interface as for file objects --- see section :ref:`bltin-file-objects` in - this manual. (It is not a built-in file object, however, so it can't be used at - those few places where a true built-in file object is required.) + Except for the :meth:`info`, :meth:`getcode` and :meth:`geturl` methods, + these methods have the same interface as for file objects --- see section + :ref:`bltin-file-objects` in this manual. (It is not a built-in file object, + however, so it can't be used at those few places where a true built-in file + object is required.) .. index:: module: mimetools @@ -58,6 +59,9 @@ the client was redirected to. The :meth:`geturl` method can be used to get at this redirected URL. + The :meth:`getcode` method returns the HTTP status code that was sent with the + response, or ``None`` if the URL is no HTTP URL. + If the *url* uses the :file:`http:` scheme identifier, the optional *data* argument may be given to specify a ``POST`` request (normally the request type is ``GET``). The *data* argument must be in standard Modified: python/trunk/Lib/test/test_urllib.py ============================================================================== --- python/trunk/Lib/test/test_urllib.py (original) +++ python/trunk/Lib/test/test_urllib.py Sun Jan 20 12:43:03 2008 @@ -47,7 +47,7 @@ def test_interface(self): # Make sure object returned by urlopen() has the specified methods for attr in ("read", "readline", "readlines", "fileno", - "close", "info", "geturl", "__iter__"): + "close", "info", "geturl", "getcode", "__iter__"): self.assert_(hasattr(self.returned_obj, attr), "object returned by urlopen() lacks %s attribute" % attr) @@ -87,6 +87,9 @@ def test_geturl(self): self.assertEqual(self.returned_obj.geturl(), self.pathname) + def test_getcode(self): + self.assertEqual(self.returned_obj.getcode(), None) + def test_iter(self): # Test iterator # Don't need to count number of iterations since test would fail the @@ -123,6 +126,8 @@ fp = urllib.urlopen("http://python.org/") self.assertEqual(fp.readline(), 'Hello!') self.assertEqual(fp.readline(), '') + self.assertEqual(fp.geturl(), 'http://python.org/') + self.assertEqual(fp.getcode(), 200) finally: self.unfakehttp() Modified: python/trunk/Lib/test/test_urllibnet.py ============================================================================== --- python/trunk/Lib/test/test_urllibnet.py (original) +++ python/trunk/Lib/test/test_urllibnet.py Sun Jan 20 12:43:03 2008 @@ -83,6 +83,16 @@ open_url.close() self.assertEqual(gotten_url, URL) + def test_getcode(self): + # test getcode() with the fancy opener to get 404 error codes + URL = "http://www.python.org/XXXinvalidXXX" + open_url = urllib.FancyURLopener().open(URL) + try: + code = open_url.getcode() + finally: + open_url.close() + self.assertEqual(code, 404) + def test_fileno(self): if (sys.platform in ('win32',) or not hasattr(os, 'fdopen')): Modified: python/trunk/Lib/urllib.py ============================================================================== --- python/trunk/Lib/urllib.py (original) +++ python/trunk/Lib/urllib.py Sun Jan 20 12:43:03 2008 @@ -343,7 +343,7 @@ # According to RFC 2616, "2xx" code indicates that the client's # request was successfully received, understood, and accepted. if (200 <= errcode < 300): - return addinfourl(fp, headers, "http:" + url) + return addinfourl(fp, headers, "http:" + url, errcode) else: if data is None: return self.http_error(url, fp, errcode, errmsg, headers) @@ -438,7 +438,7 @@ # According to RFC 2616, "2xx" code indicates that the client's # request was successfully received, understood, and accepted. if (200 <= errcode < 300): - return addinfourl(fp, headers, "https:" + url) + return addinfourl(fp, headers, "https:" + url, errcode) else: if data is None: return self.http_error(url, fp, errcode, errmsg, headers) @@ -610,7 +610,7 @@ def http_error_default(self, url, fp, errcode, errmsg, headers): """Default error handling -- don't raise an exception.""" - return addinfourl(fp, headers, "http:" + url) + return addinfourl(fp, headers, "http:" + url, errcode) def http_error_302(self, url, fp, errcode, errmsg, headers, data=None): """Error 302 -- relocated (temporarily).""" @@ -953,14 +953,18 @@ class addinfourl(addbase): """class to add info() and geturl() methods to an open file.""" - def __init__(self, fp, headers, url): + def __init__(self, fp, headers, url, code=None): addbase.__init__(self, fp) self.headers = headers self.url = url + self.code = code def info(self): return self.headers + def getcode(self): + return self.code + def geturl(self): return self.url Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Sun Jan 20 12:43:03 2008 @@ -369,6 +369,9 @@ Library ------- +- #1178141: add a getcode() method to the addinfourls that urllib.open() + returns so that you can retrieve the HTTP status code. + - Issue #1003: Fix zipfile decryption check, it would fail zip files with extended local headers. From python-checkins at python.org Sun Jan 20 13:05:43 2008 From: python-checkins at python.org (georg.brandl) Date: Sun, 20 Jan 2008 13:05:43 +0100 (CET) Subject: [Python-checkins] r60134 - in python/trunk: Doc/library/urllib.rst Lib/urllib.py Misc/NEWS Message-ID: <20080120120543.BBE301E4037@bag.python.org> Author: georg.brandl Date: Sun Jan 20 13:05:43 2008 New Revision: 60134 Modified: python/trunk/Doc/library/urllib.rst python/trunk/Lib/urllib.py python/trunk/Misc/NEWS Log: #856047: respect the ``no_proxy`` env var when checking for proxies in urllib and using the other ``_proxy`` env vars. Original patch by Donovan Baarda. Modified: python/trunk/Doc/library/urllib.rst ============================================================================== --- python/trunk/Doc/library/urllib.rst (original) +++ python/trunk/Doc/library/urllib.rst Sun Jan 20 13:05:43 2008 @@ -79,6 +79,11 @@ % python ... + The :envvar:`no_proxy` environment variable can be used to specify hosts which + shouldn't be reached via proxy; if set, it should be a comma-separated list + of hostname suffixes, optionally with ``:port`` appended, for example + ``cern.ch,ncsa.uiuc.edu,some.host:8080``. + In a Windows environment, if no proxy environment variables are set, proxy settings are obtained from the registry's Internet Settings section. @@ -112,6 +117,10 @@ .. versionchanged:: 2.3 Added the *proxies* support. + .. versionchanged:: 2.6 + Added :meth:`getcode` to returned object and support for the + :envvar:`no_proxy` environment variable. + .. function:: urlretrieve(url[, filename[, reporthook[, data]]]) Modified: python/trunk/Lib/urllib.py ============================================================================== --- python/trunk/Lib/urllib.py (original) +++ python/trunk/Lib/urllib.py Sun Jan 20 13:05:43 2008 @@ -1283,10 +1283,33 @@ proxies = {} for name, value in os.environ.items(): name = name.lower() + if name == 'no_proxy': + # handled in proxy_bypass_environment + continue if value and name[-6:] == '_proxy': proxies[name[:-6]] = value return proxies +def proxy_bypass_environment(host): + """Test if proxies should not be used for a particular host. + + Checks the environment for a variable named no_proxy, which should + be a list of DNS suffixes separated by commas, or '*' for all hosts. + """ + no_proxy = os.environ.get('no_proxy', '') or os.environ.get('NO_PROXY', '') + # '*' is special case for always bypass + if no_proxy == '*': + return 1 + # strip port off host + hostonly, port = splitport(host) + # check if the host ends with any of the DNS suffixes + for name in no_proxy.split(','): + if name and (hostonly.endswith(name) or host.endswith(name)): + return 1 + # otherwise, don't bypass + return 0 + + if sys.platform == 'darwin': def getproxies_internetconfig(): """Return a dictionary of scheme -> proxy server URL mappings. @@ -1314,12 +1337,15 @@ pass else: proxies['http'] = 'http://%s' % value - # FTP: XXXX To be done. - # Gopher: XXXX To be done. + # FTP: XXX To be done. + # Gopher: XXX To be done. return proxies - def proxy_bypass(x): - return 0 + def proxy_bypass(host): + if getproxies_environment(): + return proxy_bypass_environment(host) + else: + return 0 def getproxies(): return getproxies_environment() or getproxies_internetconfig() @@ -1379,7 +1405,7 @@ """ return getproxies_environment() or getproxies_registry() - def proxy_bypass(host): + def proxy_bypass_registry(host): try: import _winreg import re @@ -1438,12 +1464,22 @@ return 1 return 0 + def proxy_bypass(host): + """Return a dictionary of scheme -> proxy server URL mappings. + + Returns settings gathered from the environment, if specified, + or the registry. + + """ + if getproxies_environment(): + return proxy_bypass_environment(host) + else: + return proxy_bypass_registry(host) + else: # By default use environment variables getproxies = getproxies_environment - - def proxy_bypass(host): - return 0 + proxy_bypass = proxy_bypass_environment # Test and time quote() and unquote() def test1(): Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Sun Jan 20 13:05:43 2008 @@ -369,6 +369,9 @@ Library ------- +- #856047: respect the ``no_proxy`` environment variable when using the + ``http_proxy`` etc. environment variables in urllib. + - #1178141: add a getcode() method to the addinfourls that urllib.open() returns so that you can retrieve the HTTP status code. From python-checkins at python.org Sun Jan 20 13:18:18 2008 From: python-checkins at python.org (georg.brandl) Date: Sun, 20 Jan 2008 13:18:18 +0100 (CET) Subject: [Python-checkins] r60135 - in python/trunk: Lib/urllib.py Misc/NEWS Message-ID: <20080120121818.7EF081E401F@bag.python.org> Author: georg.brandl Date: Sun Jan 20 13:18:17 2008 New Revision: 60135 Modified: python/trunk/Lib/urllib.py python/trunk/Misc/NEWS Log: #1664522: in urllib, don't read non-existing directories in ftp mode, returning a 0-byte file -- raise an IOError instead. Original patch from Phil Knirsch. Modified: python/trunk/Lib/urllib.py ============================================================================== --- python/trunk/Lib/urllib.py (original) +++ python/trunk/Lib/urllib.py Sun Jan 20 13:18:17 2008 @@ -872,9 +872,19 @@ if not conn: # Set transfer mode to ASCII! self.ftp.voidcmd('TYPE A') - # Try a directory listing - if file: cmd = 'LIST ' + file - else: cmd = 'LIST' + # Try a directory listing. Verify that directory exists. + if file: + pwd = self.ftp.pwd() + try: + try: + self.ftp.cwd(file) + except ftplib.error_perm, reason: + raise IOError, ('ftp error', reason), sys.exc_info()[2] + finally: + self.ftp.cwd(pwd) + cmd = 'LIST ' + file + else: + cmd = 'LIST' conn = self.ftp.ntransfercmd(cmd) self.busy = 1 # Pass back both a suitably decorated object and a retrieval length Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Sun Jan 20 13:18:17 2008 @@ -369,6 +369,9 @@ Library ------- +- #1664522: in urllib, don't read non-existing directories in ftp mode, + returning a 0-byte file -- raise an IOError instead. + - #856047: respect the ``no_proxy`` environment variable when using the ``http_proxy`` etc. environment variables in urllib. From buildbot at python.org Sun Jan 20 13:32:29 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 20 Jan 2008 12:32:29 +0000 Subject: [Python-checkins] buildbot failure in x86 mvlgcc trunk Message-ID: <20080120123230.20F0E1E4053@bag.python.org> The Buildbot has detected a new failure of x86 mvlgcc trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20mvlgcc%20trunk/builds/1258 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-linux Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: georg.brandl BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_pyclbr ====================================================================== FAIL: test_others (test.test_pyclbr.PyclbrTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home2/buildbot/slave/trunk.loewis-linux/build/Lib/test/test_pyclbr.py", line 170, in test_others 'getproxies_internetconfig',)) # not on all platforms File "/home2/buildbot/slave/trunk.loewis-linux/build/Lib/test/test_pyclbr.py", line 92, in checkModule self.assertHasattr(module, name, ignore) File "/home2/buildbot/slave/trunk.loewis-linux/build/Lib/test/test_pyclbr.py", line 39, in assertHasattr 'expected hasattr(%r, %r)' % (obj, attr)) AssertionError: expected hasattr(, 'proxy_bypass_registry') make: *** [buildbottest] Fehler 1 sincerely, -The Buildbot From python-checkins at python.org Sun Jan 20 13:57:47 2008 From: python-checkins at python.org (georg.brandl) Date: Sun, 20 Jan 2008 13:57:47 +0100 (CET) Subject: [Python-checkins] r60136 - python/trunk/Doc/library/sys.rst Message-ID: <20080120125747.E78101E402E@bag.python.org> Author: georg.brandl Date: Sun Jan 20 13:57:47 2008 New Revision: 60136 Modified: python/trunk/Doc/library/sys.rst Log: #799369: document possible sys.platform values. Modified: python/trunk/Doc/library/sys.rst ============================================================================== --- python/trunk/Doc/library/sys.rst (original) +++ python/trunk/Doc/library/sys.rst Sun Jan 20 13:57:47 2008 @@ -507,9 +507,26 @@ .. data:: platform - This string contains a platform identifier, e.g. ``'sunos5'`` or ``'linux1'``. - This can be used to append platform-specific components to ``path``, for - instance. + This string contains a platform identifier that can be used to append + platform-specific components to :data:`sys.path`, for instance. + + For Unix systems, this is the lowercased OS name as returned by ``uname -s`` + with the first part of the version as returned by ``uname -r`` appended, + e.g. ``'sunos5'`` or ``'linux2'``, *at the time when Python was built*. + For other systems, the values are: + + ================ =========================== + System :data:`platform` value + ================ =========================== + Windows ``'win32'`` + Windows/Cygwin ``'cygwin'`` + MacOS X ``'darwin'`` + MacOS 9 ``'mac'`` + OS/2 ``'os2'`` + OS/2 EMX ``'os2emx'`` + RiscOS ``'riscos'`` + AtheOS ``'atheos'`` + ================ =========================== .. data:: prefix From python-checkins at python.org Sun Jan 20 14:08:38 2008 From: python-checkins at python.org (georg.brandl) Date: Sun, 20 Jan 2008 14:08:38 +0100 (CET) Subject: [Python-checkins] r60137 - python/trunk/Doc/library/constants.rst python/trunk/Doc/library/functions.rst Message-ID: <20080120130838.32A2C1E401F@bag.python.org> Author: georg.brandl Date: Sun Jan 20 14:08:37 2008 New Revision: 60137 Modified: python/trunk/Doc/library/constants.rst python/trunk/Doc/library/functions.rst Log: #652749: document the constants added to the builtins by site.py. Modified: python/trunk/Doc/library/constants.rst ============================================================================== --- python/trunk/Doc/library/constants.rst (original) +++ python/trunk/Doc/library/constants.rst Sun Jan 20 14:08:37 2008 @@ -1,4 +1,3 @@ - Built-in Constants ================== @@ -47,4 +46,28 @@ This constant is true if Python was not started with an :option:`-O` option. Assignments to :const:`__debug__` are illegal and raise a :exc:`SyntaxError`. - See also the :keyword:`assert` statement. \ No newline at end of file + See also the :keyword:`assert` statement. + + +Constants added by the :mod:`site` module +----------------------------------------- + +The :mod:`site` module (which is imported automatically during startup, except +if the :option:`-S` command-line option is given) adds several constants to the +built-in namespace. They are useful for the interactive interpreter shell and +should not be used in programs. + +.. data:: quit([code=None]) + exit([code=None]) + + Objects that when printed, print a message like "Use quit() or Ctrl-D + (i.e. EOF) to exit", and when called, raise :exc:`SystemExit` with the + specified exit code, and when . + +.. data:: copyright + license + credits + + Objects that when printed, print a message like "Type license() to see the + full license text", and when called, display the corresponding text in a + pager-like fashion (one screen at a time). Modified: python/trunk/Doc/library/functions.rst ============================================================================== --- python/trunk/Doc/library/functions.rst (original) +++ python/trunk/Doc/library/functions.rst Sun Jan 20 14:08:37 2008 @@ -511,6 +511,8 @@ topic, and a help page is printed on the console. If the argument is any other kind of object, a help page on the object is generated. + This function is added to the built-in namespace by the :mod:`site` module. + .. versionadded:: 2.2 From buildbot at python.org Sun Jan 20 14:32:18 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 20 Jan 2008 13:32:18 +0000 Subject: [Python-checkins] buildbot failure in sparc solaris10 gcc trunk Message-ID: <20080120133218.C114F1E401F@bag.python.org> The Buildbot has detected a new failure of sparc solaris10 gcc trunk. Full details are available at: http://www.python.org/dev/buildbot/all/sparc%20solaris10%20gcc%20trunk/builds/2654 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-sun Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: georg.brandl BUILD FAILED: failed test Excerpt from the test logfile: 2 tests failed: test_pyclbr test_urllib2net ====================================================================== FAIL: test_others (test.test_pyclbr.PyclbrTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/test/test_pyclbr.py", line 170, in test_others 'getproxies_internetconfig',)) # not on all platforms File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/test/test_pyclbr.py", line 92, in checkModule self.assertHasattr(module, name, ignore) File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/test/test_pyclbr.py", line 39, in assertHasattr 'expected hasattr(%r, %r)' % (obj, attr)) AssertionError: expected hasattr(, 'proxy_bypass_registry') ====================================================================== ERROR: test_ftp (test.test_urllib2net.OtherNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/test/test_urllib2net.py", line 175, in test_ftp self._test_urls(urls, self._extra_handlers()) File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/test/test_urllib2net.py", line 244, in _test_urls f = urllib2.urlopen(url, req) File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/urllib2.py", line 124, in urlopen return _opener.open(url, data, timeout) File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/urllib2.py", line 380, in open response = self._open(req, data) File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/urllib2.py", line 398, in _open '_open', req) File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/urllib2.py", line 358, in _call_chain result = func(*args) File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/urllib2.py", line 1284, in ftp_open fp, retrlen = fw.retrfile(file, type) File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/urllib.py", line 880, in retrfile self.ftp.cwd(file) File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/ftplib.py", line 503, in cwd return self.voidcmd(cmd) File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/ftplib.py", line 246, in voidcmd return self.voidresp() File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/ftplib.py", line 221, in voidresp resp = self.getresp() File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/ftplib.py", line 216, in getresp raise error_perm, resp TypeError: __init__() takes exactly 2 arguments (3 given) sincerely, -The Buildbot From buildbot at python.org Sun Jan 20 14:45:10 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 20 Jan 2008 13:45:10 +0000 Subject: [Python-checkins] buildbot failure in g4 osx.4 trunk Message-ID: <20080120134510.5B8821E4008@bag.python.org> The Buildbot has detected a new failure of g4 osx.4 trunk. Full details are available at: http://www.python.org/dev/buildbot/all/g4%20osx.4%20trunk/builds/2652 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: psf-g4 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: georg.brandl BUILD FAILED: failed test Excerpt from the test logfile: 2 tests failed: test_pyclbr test_urllib2net ====================================================================== FAIL: test_others (test.test_pyclbr.PyclbrTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/test/test_pyclbr.py", line 170, in test_others 'getproxies_internetconfig',)) # not on all platforms File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/test/test_pyclbr.py", line 92, in checkModule self.assertHasattr(module, name, ignore) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/test/test_pyclbr.py", line 39, in assertHasattr 'expected hasattr(%r, %r)' % (obj, attr)) AssertionError: expected hasattr(, 'proxy_bypass_registry') ====================================================================== ERROR: test_ftp (test.test_urllib2net.OtherNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/test/test_urllib2net.py", line 175, in test_ftp self._test_urls(urls, self._extra_handlers()) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/test/test_urllib2net.py", line 244, in _test_urls f = urllib2.urlopen(url, req) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 124, in urlopen return _opener.open(url, data, timeout) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 380, in open response = self._open(req, data) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 398, in _open '_open', req) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 358, in _call_chain result = func(*args) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib2.py", line 1284, in ftp_open fp, retrlen = fw.retrfile(file, type) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/urllib.py", line 880, in retrfile self.ftp.cwd(file) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/ftplib.py", line 503, in cwd return self.voidcmd(cmd) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/ftplib.py", line 246, in voidcmd return self.voidresp() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/ftplib.py", line 221, in voidresp resp = self.getresp() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/ftplib.py", line 216, in getresp raise error_perm, resp TypeError: __init__() takes exactly 2 arguments (3 given) make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Sun Jan 20 14:59:47 2008 From: python-checkins at python.org (georg.brandl) Date: Sun, 20 Jan 2008 14:59:47 +0100 (CET) Subject: [Python-checkins] r60138 - in python/trunk: Doc/library/sys.rst Lib/test/test_profilehooks.py Lib/test/test_trace.py Misc/NEWS Python/sysmodule.c Message-ID: <20080120135947.0B44B1E4008@bag.python.org> Author: georg.brandl Date: Sun Jan 20 14:59:46 2008 New Revision: 60138 Modified: python/trunk/Doc/library/sys.rst python/trunk/Lib/test/test_profilehooks.py python/trunk/Lib/test/test_trace.py python/trunk/Misc/NEWS python/trunk/Python/sysmodule.c Log: #1648: add sys.gettrace() and sys.getprofile(). Modified: python/trunk/Doc/library/sys.rst ============================================================================== --- python/trunk/Doc/library/sys.rst (original) +++ python/trunk/Doc/library/sys.rst Sun Jan 20 14:59:46 2008 @@ -392,6 +392,35 @@ This function should be used for internal and specialized purposes only. +.. function:: getprofile() + + .. index:: + single: profile function + single: profiler + + Get the profiler function as set by :func:`setprofile`. + + .. versionadded:: 2.6 + + +.. function:: gettrace() + + .. index:: + single: trace function + single: debugger + + Get the trace function as set by :func:`settrace`. + + .. note:: + + The :func:`gettrace` function is intended only for implementing debuggers, + profilers, coverage tools and the like. Its behavior is part of the + implementation platform, rather than part of the language definition, + and thus may not be available in all Python implementations. + + .. versionadded:: 2.6 + + .. function:: getwindowsversion() Return a tuple containing five components, describing the Windows version Modified: python/trunk/Lib/test/test_profilehooks.py ============================================================================== --- python/trunk/Lib/test/test_profilehooks.py (original) +++ python/trunk/Lib/test/test_profilehooks.py Sun Jan 20 14:59:46 2008 @@ -4,6 +4,22 @@ from test import test_support +class TestGetProfile(unittest.TestCase): + def setUp(self): + sys.setprofile(None) + + def tearDown(self): + sys.setprofile(None) + + def test_empty(self): + assert sys.getprofile() == None + + def test_setget(self): + def fn(*args): + pass + + sys.setprofile(fn) + assert sys.getprofile() == fn class HookWatcher: def __init__(self): @@ -359,6 +375,7 @@ def test_main(): test_support.run_unittest( + TestGetProfile, ProfileHookTestCase, ProfileSimulatorTestCase ) Modified: python/trunk/Lib/test/test_trace.py ============================================================================== --- python/trunk/Lib/test/test_trace.py (original) +++ python/trunk/Lib/test/test_trace.py Sun Jan 20 14:59:46 2008 @@ -268,6 +268,20 @@ self.compare_events(func.func_code.co_firstlineno, tracer.events, func.events) + def set_and_retrieve_none(self): + sys.settrace(None) + assert sys.gettrace() is None + + def set_and_retrieve_func(self): + def fn(*args): + pass + + sys.settrace(fn) + try: + assert sys.gettrace() is fn + finally: + sys.settrace(None) + def test_01_basic(self): self.run_test(basic) def test_02_arigo(self): Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Sun Jan 20 14:59:46 2008 @@ -1042,6 +1042,8 @@ Extension Modules ----------------- +- Patch #1648: added ``sys.getprofile()`` and ``sys.gettrace()``. + - Patch #1663329: added ``os.closerange()`` function to quickly close a range of file descriptors without considering errors. Modified: python/trunk/Python/sysmodule.c ============================================================================== --- python/trunk/Python/sysmodule.c (original) +++ python/trunk/Python/sysmodule.c Sun Jan 20 14:59:46 2008 @@ -398,6 +398,25 @@ ); static PyObject * +sys_gettrace(PyObject *self, PyObject *args) +{ + PyThreadState *tstate = PyThreadState_GET(); + PyObject *temp = tstate->c_traceobj; + + if (temp == NULL) + temp = Py_None; + Py_INCREF(temp); + return temp; +} + +PyDoc_STRVAR(gettrace_doc, +"gettrace()\n\ +\n\ +Return the global debug tracing function set with sys.settrace.\n\ +See the debugger chapter in the library manual." +); + +static PyObject * sys_setprofile(PyObject *self, PyObject *args) { if (trace_init() == -1) @@ -418,6 +437,25 @@ ); static PyObject * +sys_getprofile(PyObject *self, PyObject *args) +{ + PyThreadState *tstate = PyThreadState_GET(); + PyObject *temp = tstate->c_profileobj; + + if (temp == NULL) + temp = Py_None; + Py_INCREF(temp); + return temp; +} + +PyDoc_STRVAR(getprofile_doc, +"getprofile()\n\ +\n\ +Return the profiling function set with sys.setprofile.\n\ +See the profiler chapter in the library manual." +); + +static PyObject * sys_setcheckinterval(PyObject *self, PyObject *args) { if (!PyArg_ParseTuple(args, "i:setcheckinterval", &_Py_CheckInterval)) @@ -793,12 +831,14 @@ setdlopenflags_doc}, #endif {"setprofile", sys_setprofile, METH_O, setprofile_doc}, + {"getprofile", sys_getprofile, METH_NOARGS, getprofile_doc}, {"setrecursionlimit", sys_setrecursionlimit, METH_VARARGS, setrecursionlimit_doc}, #ifdef WITH_TSC {"settscdump", sys_settscdump, METH_VARARGS, settscdump_doc}, #endif {"settrace", sys_settrace, METH_O, settrace_doc}, + {"gettrace", sys_gettrace, METH_NOARGS, gettrace_doc}, {"call_tracing", sys_call_tracing, METH_VARARGS, call_tracing_doc}, {NULL, NULL} /* sentinel */ }; @@ -941,8 +981,10 @@ exc_clear() -- clear the exception state for the current thread\n\ exit() -- exit the interpreter by raising SystemExit\n\ getdlopenflags() -- returns flags to be used for dlopen() calls\n\ +getprofile() -- get the global profiling function\n\ getrefcount() -- return the reference count for an object (plus one :-)\n\ getrecursionlimit() -- return the max recursion depth for the interpreter\n\ +gettrace() -- get the global debug tracing function\n\ setcheckinterval() -- control how often the interpreter checks for events\n\ setdlopenflags() -- set the flags to be used for dlopen() calls\n\ setprofile() -- set the global profiling function\n\ From python-checkins at python.org Sun Jan 20 15:17:42 2008 From: python-checkins at python.org (georg.brandl) Date: Sun, 20 Jan 2008 15:17:42 +0100 (CET) Subject: [Python-checkins] r60139 - in python/trunk: Doc/library/shutil.rst Lib/shutil.py Lib/test/test_shutil.py Misc/NEWS Message-ID: <20080120141742.E2C5E1E4008@bag.python.org> Author: georg.brandl Date: Sun Jan 20 15:17:42 2008 New Revision: 60139 Modified: python/trunk/Doc/library/shutil.rst python/trunk/Lib/shutil.py python/trunk/Lib/test/test_shutil.py python/trunk/Misc/NEWS Log: #1669: don't allow shutil.rmtree() to be called on a symlink. Modified: python/trunk/Doc/library/shutil.rst ============================================================================== --- python/trunk/Doc/library/shutil.rst (original) +++ python/trunk/Doc/library/shutil.rst Sun Jan 20 15:17:42 2008 @@ -101,18 +101,24 @@ .. index:: single: directory; deleting - Delete an entire directory tree (*path* must point to a directory). If - *ignore_errors* is true, errors resulting from failed removals will be ignored; - if false or omitted, such errors are handled by calling a handler specified by - *onerror* or, if that is omitted, they raise an exception. - - If *onerror* is provided, it must be a callable that accepts three parameters: - *function*, *path*, and *excinfo*. The first parameter, *function*, is the - function which raised the exception; it will be :func:`os.listdir`, - :func:`os.remove` or :func:`os.rmdir`. The second parameter, *path*, will be - the path name passed to *function*. The third parameter, *excinfo*, will be the - exception information return by :func:`sys.exc_info`. Exceptions raised by - *onerror* will not be caught. + Delete an entire directory tree; *path* must point to a directory (but not a + symbolic link to a directory). If *ignore_errors* is true, errors resulting + from failed removals will be ignored; if false or omitted, such errors are + handled by calling a handler specified by *onerror* or, if that is omitted, + they raise an exception. + + If *onerror* is provided, it must be a callable that accepts three + parameters: *function*, *path*, and *excinfo*. The first parameter, + *function*, is the function which raised the exception; it will be + :func:`os.path.islink`, :func:`os.listdir`, :func:`os.remove` or + :func:`os.rmdir`. The second parameter, *path*, will be the path name passed + to *function*. The third parameter, *excinfo*, will be the exception + information return by :func:`sys.exc_info`. Exceptions raised by *onerror* + will not be caught. + + .. versionchanged:: 2.6 + Explicitly check for *path* being a symbolic link and raise :exc:`OSError` + in that case. .. function:: move(src, dst) Modified: python/trunk/Lib/shutil.py ============================================================================== --- python/trunk/Lib/shutil.py (original) +++ python/trunk/Lib/shutil.py Sun Jan 20 15:17:42 2008 @@ -156,6 +156,14 @@ elif onerror is None: def onerror(*args): raise + try: + if os.path.islink(path): + # symlinks to directories are forbidden, see bug #1669 + raise OSError("Cannot call rmtree on a symbolic link") + except OSError: + onerror(os.path.islink, path, sys.exc_info()) + # can't continue even if onerror hook returns + return names = [] try: names = os.listdir(path) Modified: python/trunk/Lib/test/test_shutil.py ============================================================================== --- python/trunk/Lib/test/test_shutil.py (original) +++ python/trunk/Lib/test/test_shutil.py Sun Jan 20 15:17:42 2008 @@ -149,6 +149,20 @@ except OSError: pass + def test_rmtree_on_symlink(self): + # bug 1669. + os.mkdir(TESTFN) + try: + src = os.path.join(TESTFN, 'cheese') + dst = os.path.join(TESTFN, 'shop') + os.mkdir(src) + os.symlink(src, dst) + self.assertRaises(OSError, shutil.rmtree, dst) + finally: + shutil.rmtree(TESTFN, ignore_errors=True) + + + def test_main(): test_support.run_unittest(TestShutil) Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Sun Jan 20 15:17:42 2008 @@ -369,6 +369,9 @@ Library ------- +- #1669: don't allow shutil.rmtree() to be called on a symlink to a + directory. + - #1664522: in urllib, don't read non-existing directories in ftp mode, returning a 0-byte file -- raise an IOError instead. From python-checkins at python.org Sun Jan 20 15:20:03 2008 From: python-checkins at python.org (georg.brandl) Date: Sun, 20 Jan 2008 15:20:03 +0100 (CET) Subject: [Python-checkins] r60140 - python/trunk/Lib/test/test_pyclbr.py Message-ID: <20080120142003.1CEF21E4008@bag.python.org> Author: georg.brandl Date: Sun Jan 20 15:20:02 2008 New Revision: 60140 Modified: python/trunk/Lib/test/test_pyclbr.py Log: Fix test_pyclbr after urllib change. Modified: python/trunk/Lib/test/test_pyclbr.py ============================================================================== --- python/trunk/Lib/test/test_pyclbr.py (original) +++ python/trunk/Lib/test/test_pyclbr.py Sun Jan 20 15:20:02 2008 @@ -166,6 +166,7 @@ cm('cgi', ignore=('log',)) # set with = in module cm('mhlib') cm('urllib', ignore=('getproxies_registry', + 'proxy_bypass_registry', 'open_https', 'getproxies_internetconfig',)) # not on all platforms cm('pickle') From python-checkins at python.org Sun Jan 20 15:28:29 2008 From: python-checkins at python.org (christian.heimes) Date: Sun, 20 Jan 2008 15:28:29 +0100 (CET) Subject: [Python-checkins] r60141 - in python/trunk: Include/pyport.h Python/hypot.c configure configure.in pyconfig.h.in Message-ID: <20080120142829.1C7E41E4008@bag.python.org> Author: christian.heimes Date: Sun Jan 20 15:28:28 2008 New Revision: 60141 Modified: python/trunk/Include/pyport.h python/trunk/Python/hypot.c python/trunk/configure python/trunk/configure.in python/trunk/pyconfig.h.in Log: Fixed a wrong assumption in configure.in and Include/pyport.h. The is finite function is not called isfinite() but finite(). Sorry, my fault. :) Modified: python/trunk/Include/pyport.h ============================================================================== --- python/trunk/Include/pyport.h (original) +++ python/trunk/Include/pyport.h Sun Jan 20 15:28:28 2008 @@ -405,8 +405,8 @@ * macro for this particular test is useful */ #ifndef Py_IS_FINITE -#ifdef HAVE_ISFINITE -#define Py_IS_FINITE(X) isfinite +#ifdef HAVE_FINITE +#define Py_IS_FINITE(X) finite #else #define Py_IS_FINITE(X) (!Py_IS_INFINITY(X) && !Py_IS_NAN(X)) #endif Modified: python/trunk/Python/hypot.c ============================================================================== --- python/trunk/Python/hypot.c (original) +++ python/trunk/Python/hypot.c Sun Jan 20 15:28:28 2008 @@ -2,6 +2,7 @@ #include "Python.h" +#ifndef HAVE_HYPOT double hypot(double x, double y) { double yx; @@ -20,3 +21,5 @@ return x*sqrt(1.+yx*yx); } } +#endif /* HAVE_HYPOT */ + Modified: python/trunk/configure ============================================================================== --- python/trunk/configure (original) +++ python/trunk/configure Sun Jan 20 15:28:28 2008 @@ -1,5 +1,5 @@ #! /bin/sh -# From configure.in Revision: 59611 . +# From configure.in Revision: 59819 . # Guess values for system-dependent variables and create Makefiles. # Generated by GNU Autoconf 2.61 for python 2.6. # @@ -20373,7 +20373,6 @@ # ************************************ # * Check for mathematical functions * # ************************************ -# check for hypot() in math library LIBS_SAVE=$LIBS LIBS="$LIBS $LIBM" @@ -20483,7 +20482,12 @@ -for ac_func in copysign isfinite isnan isinf + + + + + +for ac_func in acosh asinh atanh copysign expm1 finite isinf isnan log1p do as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` { echo "$as_me:$LINENO: checking for $ac_func" >&5 Modified: python/trunk/configure.in ============================================================================== --- python/trunk/configure.in (original) +++ python/trunk/configure.in Sun Jan 20 15:28:28 2008 @@ -2978,12 +2978,11 @@ # ************************************ # * Check for mathematical functions * # ************************************ -# check for hypot() in math library LIBS_SAVE=$LIBS LIBS="$LIBS $LIBM" AC_REPLACE_FUNCS(hypot) -AC_CHECK_FUNCS(copysign isfinite isnan isinf) +AC_CHECK_FUNCS(acosh asinh atanh copysign expm1 finite isinf isnan log1p) LIBS=$LIBS_SAVE Modified: python/trunk/pyconfig.h.in ============================================================================== --- python/trunk/pyconfig.h.in (original) +++ python/trunk/pyconfig.h.in Sun Jan 20 15:28:28 2008 @@ -28,6 +28,9 @@ the case on Motorola V4 (R40V4.2) */ #undef GETTIMEOFDAY_NO_TZ +/* Define to 1 if you have the `acosh' function. */ +#undef HAVE_ACOSH + /* struct addrinfo (netdb.h) */ #undef HAVE_ADDRINFO @@ -37,9 +40,15 @@ /* Define this if your time.h defines altzone. */ #undef HAVE_ALTZONE +/* Define to 1 if you have the `asinh' function. */ +#undef HAVE_ASINH + /* Define to 1 if you have the header file. */ #undef HAVE_ASM_TYPES_H +/* Define to 1 if you have the `atanh' function. */ +#undef HAVE_ATANH + /* Define if GCC supports __attribute__((format(PyArg_ParseTuple, 2, 3))) */ #undef HAVE_ATTRIBUTE_FORMAT_PARSETUPLE @@ -144,6 +153,9 @@ /* Define to 1 if you have the `execv' function. */ #undef HAVE_EXECV +/* Define to 1 if you have the `expm1' function. */ +#undef HAVE_EXPM1 + /* Define if you have the 'fchdir' function. */ #undef HAVE_FCHDIR @@ -159,6 +171,9 @@ /* Define if you have the 'fdatasync' function. */ #undef HAVE_FDATASYNC +/* Define to 1 if you have the `finite' function. */ +#undef HAVE_FINITE + /* Define if you have the 'flock' function. */ #undef HAVE_FLOCK @@ -291,9 +306,6 @@ /* Define to 1 if you have the header file. */ #undef HAVE_IO_H -/* Define to 1 if you have the `isfinite' function. */ -#undef HAVE_ISFINITE - /* Define to 1 if you have the `isinf' function. */ #undef HAVE_ISINF @@ -357,6 +369,9 @@ /* Define to 1 if you have the header file. */ #undef HAVE_LINUX_TIPC_H +/* Define to 1 if you have the `log1p' function. */ +#undef HAVE_LOG1P + /* Define this if you have the type long long. */ #undef HAVE_LONG_LONG From python-checkins at python.org Sun Jan 20 15:31:27 2008 From: python-checkins at python.org (georg.brandl) Date: Sun, 20 Jan 2008 15:31:27 +0100 (CET) Subject: [Python-checkins] r60142 - python/trunk/Lib/test/test_operator.py Message-ID: <20080120143127.F03BC1E4008@bag.python.org> Author: georg.brandl Date: Sun Jan 20 15:31:27 2008 New Revision: 60142 Modified: python/trunk/Lib/test/test_operator.py Log: #1876: fix typos in test_operator. Modified: python/trunk/Lib/test/test_operator.py ============================================================================== --- python/trunk/Lib/test/test_operator.py (original) +++ python/trunk/Lib/test/test_operator.py Sun Jan 20 15:31:27 2008 @@ -382,9 +382,9 @@ self.assertRaises(TypeError, operator.attrgetter('x', (), 'y'), record) class C(object): - def __getattr(self, name): + def __getattr__(self, name): raise SyntaxError - self.failUnlessRaises(AttributeError, operator.attrgetter('foo'), C()) + self.failUnlessRaises(SyntaxError, operator.attrgetter('foo'), C()) def test_itemgetter(self): a = 'ABCDE' @@ -394,9 +394,9 @@ self.assertRaises(IndexError, f, a) class C(object): - def __getitem(self, name): + def __getitem__(self, name): raise SyntaxError - self.failUnlessRaises(TypeError, operator.itemgetter(42), C()) + self.failUnlessRaises(SyntaxError, operator.itemgetter(42), C()) f = operator.itemgetter('name') self.assertRaises(TypeError, f, a) From python-checkins at python.org Sun Jan 20 15:50:05 2008 From: python-checkins at python.org (georg.brandl) Date: Sun, 20 Jan 2008 15:50:05 +0100 (CET) Subject: [Python-checkins] r60143 - python/trunk/Modules/mmapmodule.c Message-ID: <20080120145005.EDCE61E4008@bag.python.org> Author: georg.brandl Date: Sun Jan 20 15:50:05 2008 New Revision: 60143 Modified: python/trunk/Modules/mmapmodule.c Log: Switch mmap from old Py_FindMethod to new PyObject_GenericGetAttr attribute access. Fixes #1087735. Modified: python/trunk/Modules/mmapmodule.c ============================================================================== --- python/trunk/Modules/mmapmodule.c (original) +++ python/trunk/Modules/mmapmodule.c Sun Jan 20 15:50:05 2008 @@ -687,12 +687,6 @@ return self->size; } -static PyObject * -mmap_object_getattr(mmap_object *self, char *name) -{ - return Py_FindMethod(mmap_object_methods, (PyObject *)self, name); -} - static Py_ssize_t mmap_length(mmap_object *self) { @@ -980,6 +974,30 @@ (charbufferproc)mmap_buffer_getcharbuffer, }; +PyDoc_STRVAR(mmap_doc, +"Windows: mmap(fileno, length[, tagname[, access[, offset]]])\n\ +\n\ +Maps length bytes from the file specified by the file handle fileno,\n\ +and returns a mmap object. If length is larger than the current size\n\ +of the file, the file is extended to contain length bytes. If length\n\ +is 0, the maximum length of the map is the current size of the file,\n\ +except that if the file is empty Windows raises an exception (you cannot\n\ +create an empty mapping on Windows).\n\ +\n\ +Unix: mmap(fileno, length[, flags[, prot[, access[, offset]]]])\n\ +\n\ +Maps length bytes from the file specified by the file descriptor fileno,\n\ +and returns a mmap object. If length is 0, the maximum length of the map\n\ +will be the current size of the file when mmap is called.\n\ +flags specifies the nature of the mapping. MAP_PRIVATE creates a\n\ +private copy-on-write mapping, so changes to the contents of the mmap\n\ +object will be private to this process, and MAP_SHARED`creates a mapping\n\ +that's shared with all other processes mapping the same areas of the file.\n\ +The default value is MAP_SHARED.\n\ +\n\ +To map anonymous memory, pass -1 as the fileno (both versions)."); + + static PyTypeObject mmap_object_type = { PyVarObject_HEAD_INIT(0, 0) /* patched in module init */ "mmap.mmap", /* tp_name */ @@ -988,7 +1006,7 @@ /* methods */ (destructor) mmap_object_dealloc, /* tp_dealloc */ 0, /* tp_print */ - (getattrfunc) mmap_object_getattr, /* tp_getattr */ + 0, /* tp_getattr */ 0, /* tp_setattr */ 0, /* tp_compare */ 0, /* tp_repr */ @@ -998,11 +1016,19 @@ 0, /*tp_hash*/ 0, /*tp_call*/ 0, /*tp_str*/ - 0, /*tp_getattro*/ + PyObject_GenericGetAttr, /*tp_getattro*/ 0, /*tp_setattro*/ &mmap_as_buffer, /*tp_as_buffer*/ Py_TPFLAGS_HAVE_GETCHARBUFFER, /*tp_flags*/ - 0, /*tp_doc*/ + mmap_doc, /*tp_doc*/ + 0, /* tp_traverse */ + 0, /* tp_clear */ + 0, /* tp_richcompare */ + 0, /* tp_weaklistoffset */ + 0, /* tp_iter */ + 0, /* tp_iternext */ + mmap_object_methods, /* tp_methods */ + }; @@ -1341,7 +1367,7 @@ /* List of functions exported by this module */ static struct PyMethodDef mmap_functions[] = { {"mmap", (PyCFunction) new_mmap_object, - METH_VARARGS|METH_KEYWORDS}, + METH_VARARGS|METH_KEYWORDS, mmap_doc}, {NULL, NULL} /* Sentinel */ }; From buildbot at python.org Sun Jan 20 16:02:29 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 20 Jan 2008 15:02:29 +0000 Subject: [Python-checkins] buildbot failure in x86 FreeBSD trunk Message-ID: <20080120150231.0C36C1E4008@bag.python.org> The Buildbot has detected a new failure of x86 FreeBSD trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20FreeBSD%20trunk/builds/433 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-freebsd Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: georg.brandl BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 227, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 268, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 281, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 560, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 227, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 268, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 281, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 560, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 227, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 268, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 281, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 560, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 227, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 268, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 281, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 560, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable 2 tests failed: test_pyclbr test_urllib2net ====================================================================== FAIL: test_others (test.test_pyclbr.PyclbrTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/test/test_pyclbr.py", line 170, in test_others 'getproxies_internetconfig',)) # not on all platforms File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/test/test_pyclbr.py", line 92, in checkModule self.assertHasattr(module, name, ignore) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/test/test_pyclbr.py", line 39, in assertHasattr 'expected hasattr(%r, %r)' % (obj, attr)) AssertionError: expected hasattr(, 'proxy_bypass_registry') ====================================================================== ERROR: test_ftp (test.test_urllib2net.OtherNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/test/test_urllib2net.py", line 175, in test_ftp self._test_urls(urls, self._extra_handlers()) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/test/test_urllib2net.py", line 244, in _test_urls f = urllib2.urlopen(url, req) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/urllib2.py", line 124, in urlopen return _opener.open(url, data, timeout) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/urllib2.py", line 380, in open response = self._open(req, data) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/urllib2.py", line 398, in _open '_open', req) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/urllib2.py", line 358, in _call_chain result = func(*args) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/urllib2.py", line 1284, in ftp_open fp, retrlen = fw.retrfile(file, type) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/urllib.py", line 880, in retrfile self.ftp.cwd(file) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/ftplib.py", line 503, in cwd return self.voidcmd(cmd) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/ftplib.py", line 246, in voidcmd return self.voidresp() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/ftplib.py", line 221, in voidresp resp = self.getresp() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/ftplib.py", line 216, in getresp raise error_perm, resp TypeError: __init__() takes exactly 2 arguments (3 given) sincerely, -The Buildbot From buildbot at python.org Sun Jan 20 16:20:44 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 20 Jan 2008 15:20:44 +0000 Subject: [Python-checkins] buildbot failure in sparc solaris10 gcc 3.0 Message-ID: <20080120152044.68C5B1E456B@bag.python.org> The Buildbot has detected a new failure of sparc solaris10 gcc 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/sparc%20solaris10%20gcc%203.0/builds/504 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-sun Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes,georg.brandl BUILD FAILED: failed compile sincerely, -The Buildbot From buildbot at python.org Sun Jan 20 17:36:28 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 20 Jan 2008 16:36:28 +0000 Subject: [Python-checkins] buildbot failure in g4 osx.4 3.0 Message-ID: <20080120163628.DE9D61E4008@bag.python.org> The Buildbot has detected a new failure of g4 osx.4 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/g4%20osx.4%203.0/builds/452 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: psf-g4 Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes,georg.brandl BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_urllib ====================================================================== FAIL: test_read (test.test_urllib.urlopen_HttpTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/test/test_urllib.py", line 130, in test_read self.assertEqual(fp.getcode(), 200) AssertionError: None != 200 make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Sun Jan 20 20:40:58 2008 From: python-checkins at python.org (georg.brandl) Date: Sun, 20 Jan 2008 20:40:58 +0100 (CET) Subject: [Python-checkins] r60145 - python/trunk/Doc/tutorial/interpreter.rst Message-ID: <20080120194058.B53ED1E4041@bag.python.org> Author: georg.brandl Date: Sun Jan 20 20:40:58 2008 New Revision: 60145 Modified: python/trunk/Doc/tutorial/interpreter.rst Log: Add blurb about executable scripts on Windows. #760657. Modified: python/trunk/Doc/tutorial/interpreter.rst ============================================================================== --- python/trunk/Doc/tutorial/interpreter.rst (original) +++ python/trunk/Doc/tutorial/interpreter.rst Sun Jan 20 20:40:58 2008 @@ -166,6 +166,12 @@ $ chmod +x myscript.py +On Windows systems, there is no notion of an "executable mode". The Python +installer automatically associates ``.py`` files with ``python.exe`` so that +a double-click on a Python file will run it as a script. The extension can +also be ``.pyw``, in that case, the console window that normally appears is +suppressed. + Source Code Encoding -------------------- From python-checkins at python.org Sun Jan 20 20:48:40 2008 From: python-checkins at python.org (georg.brandl) Date: Sun, 20 Jan 2008 20:48:40 +0100 (CET) Subject: [Python-checkins] r60146 - python/trunk/Doc/c-api/typeobj.rst Message-ID: <20080120194840.BE6CB1E4023@bag.python.org> Author: georg.brandl Date: Sun Jan 20 20:48:40 2008 New Revision: 60146 Modified: python/trunk/Doc/c-api/typeobj.rst Log: #1219903: fix tp_richcompare docs. Modified: python/trunk/Doc/c-api/typeobj.rst ============================================================================== --- python/trunk/Doc/c-api/typeobj.rst (original) +++ python/trunk/Doc/c-api/typeobj.rst Sun Jan 20 20:48:40 2008 @@ -662,13 +662,19 @@ .. cmember:: richcmpfunc PyTypeObject.tp_richcompare - An optional pointer to the rich comparison function. + An optional pointer to the rich comparison function, whose signature is + ``PyObject *tp_richcompare(PyObject *a, PyObject *b, int op)``. - The signature is the same as for :cfunc:`PyObject_RichCompare`. The function - should return the result of the comparison (usually ``Py_True`` or - ``Py_False``). If the comparison is undefined, it must return - ``Py_NotImplemented``, if another error occurred it must return ``NULL`` and set - an exception condition. + The function should return the result of the comparison (usually ``Py_True`` + or ``Py_False``). If the comparison is undefined, it must return + ``Py_NotImplemented``, if another error occurred it must return ``NULL`` and + set an exception condition. + + .. note:: + + If you want to implement a type for which only a limited set of + comparisons makes sense (e.g. ``==`` and ``!=``, but not ``<`` and + friends), directly raise :exc:`TypeError` in the rich comparison function. This field is inherited by subtypes together with :attr:`tp_compare` and :attr:`tp_hash`: a subtype inherits all three of :attr:`tp_compare`, @@ -694,10 +700,10 @@ | :const:`Py_GE` | ``>=`` | +----------------+------------+ + The next field only exists if the :const:`Py_TPFLAGS_HAVE_WEAKREFS` flag bit is set. - .. cmember:: long PyTypeObject.tp_weaklistoffset If the instances of this type are weakly referenceable, this field is greater From python-checkins at python.org Sun Jan 20 22:10:08 2008 From: python-checkins at python.org (georg.brandl) Date: Sun, 20 Jan 2008 22:10:08 +0100 (CET) Subject: [Python-checkins] r60147 - python/trunk/Doc/using/cmdline.rst Message-ID: <20080120211008.866B71E4026@bag.python.org> Author: georg.brandl Date: Sun Jan 20 22:10:08 2008 New Revision: 60147 Modified: python/trunk/Doc/using/cmdline.rst Log: Fix markup. Modified: python/trunk/Doc/using/cmdline.rst ============================================================================== --- python/trunk/Doc/using/cmdline.rst (original) +++ python/trunk/Doc/using/cmdline.rst Sun Jan 20 22:10:08 2008 @@ -340,14 +340,14 @@ .. envvar:: PYTHONHOME Change the location of the standard Python libraries. By default, the - libraries are searched in :file:`{prefix}/lib/python` and - :file:`{exec_prefix}/lib/python`, where :file:`{prefix}` and + libraries are searched in :file:`{prefix}/lib/python{version}` and + :file:`{exec_prefix}/lib/python{version}`, where :file:`{prefix}` and :file:`{exec_prefix}` are installation-dependent directories, both defaulting to :file:`/usr/local`. When :envvar:`PYTHONHOME` is set to a single directory, its value replaces both :file:`{prefix}` and :file:`{exec_prefix}`. To specify different values - for these, set :envvar:`PYTHONHOME` to :file:`{prefix}:{exec_prefix}``. + for these, set :envvar:`PYTHONHOME` to :file:`{prefix}:{exec_prefix}`. .. envvar:: PYTHONPATH @@ -357,7 +357,7 @@ colons. Non-existent directories are silently ignored. The default search path is installation dependent, but generally begins with - :file:`{prefix}/lib/python`` (see :envvar:`PYTHONHOME` above). It + :file:`{prefix}/lib/python{version}`` (see :envvar:`PYTHONHOME` above). It is *always* appended to :envvar:`PYTHONPATH`. If a script argument is given, the directory containing the script is From nnorwitz at gmail.com Sun Jan 20 23:27:21 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Sun, 20 Jan 2008 17:27:21 -0500 Subject: [Python-checkins] Python Regression Test Failures refleak (8) Message-ID: <20080120222721.GA26282@python.psfb.org> test_opcodes leaked [-2, 0, 2] references, sum=0 test_doctest leaked [0, 0, -2] references, sum=-2 test_cmd_line leaked [0, 23, -23] references, sum=0 test_descrtut leaked [-2, -2, 4] references, sum=0 test_dummy_thread leaked [0, -2, 0] references, sum=-2 test_gc leaked [-2, 0, 2] references, sum=0 test_genericpath leaked [0, -2, 0] references, sum=-2 test_importhooks leaked [6, 4, 0] references, sum=10 test_index leaked [-2, 0, 0] references, sum=-2 test_os leaked [2, -2, 2] references, sum=2 test_pkgimport leaked [2, 0, 0] references, sum=2 test_popen leaked [0, 0, -2] references, sum=-2 test_sqlite leaked [-2, 2, 0] references, sum=0 test_threadsignals leaked [0, -8, 0] references, sum=-8 test_urllib2_localnet leaked [3, 3, 3] references, sum=9 From nnorwitz at gmail.com Sun Jan 20 23:44:30 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Sun, 20 Jan 2008 17:44:30 -0500 Subject: [Python-checkins] Python Regression Test Failures all (1) Message-ID: <20080120224430.GA28360@python.psfb.org> test_grammar test_opcodes test_dict test_builtin test_exceptions test_types test_unittest test_doctest test_doctest2 test_MimeWriter test_StringIO test___all__ test___future__ test__locale test_abc test_abstract_numbers test_aepack test_aepack skipped -- No module named aepack test_al test_al skipped -- No module named al test_anydbm test_applesingle test_applesingle skipped -- No module named macostools test_array test_ast test_asynchat test_asyncore test_atexit test_audioop test_augassign test_base64 test_bastion test_bigaddrspace test_bigmem test_binascii test_binhex test_binop test_bisect test_bool test_bsddb test_bsddb185 test_bsddb185 skipped -- No module named bsddb185 test_bsddb3 test test_bsddb3 failed -- errors occurred; run in verbose mode for details test_buffer test_bufio test_bz2 test_cProfile test_calendar test_call test_capi test_cd test_cd skipped -- No module named cd test_cfgparser test_cgi test_charmapcodec test_cl test_cl skipped -- No module named cl test_class test_cmath test_cmd test_cmd_line test_cmd_line_script test_code test_codeccallbacks test_codecencodings_cn test_codecencodings_hk test_codecencodings_jp test_codecencodings_kr test_codecencodings_tw test_codecmaps_cn test_codecmaps_hk test_codecmaps_jp test_codecmaps_kr test_codecmaps_tw test_codecs test_codeop test_coding test_coercion test_collections test_colorsys test_commands test_compare test_compile test_compiler testCompileLibrary still working, be patient... test_complex test_complex_args test_contains test_contextlib test_cookie test_cookielib test_copy test_copy_reg test_cpickle test_crypt test_csv test_ctypes test_datetime test_dbm test_decimal test_decorators test_defaultdict test_deque test_descr test_descrtut test_difflib test_dircache test_dis test_distutils test_dl test_docxmlrpc test_dumbdbm test_dummy_thread test_dummy_threading test_email test_email_codecs test_email_renamed test_enumerate test_eof test_errno test_exception_variations test_extcall test_fcntl test_file test_filecmp test_fileinput test_float test_fnmatch test_fork1 test_format test_fpformat test_frozen test_ftplib test_funcattrs test_functools test_future test_gc test_gdbm test_generators test_genericpath test_genexps test_getargs test_getargs2 test_getopt test_gettext test_gl test_gl skipped -- No module named gl test_glob test_global test_grp test_gzip test_hash test_hashlib test_heapq test_hexoct test_hmac test_hotshot test_htmllib test_htmlparser test_httplib test_imageop test_imageop skipped -- No module named imgfile test_imaplib test_imgfile test_imgfile skipped -- No module named imgfile test_imp test_import test_importhooks test_index test_inspect test_ioctl test_ioctl skipped -- Unable to open /dev/tty test_isinstance test_iter test_iterlen test_itertools test_largefile test_list test_locale test_logging test_long test_long_future test_longexp test_macostools test_macostools skipped -- No module named macostools test_macpath test_mailbox test_marshal test_math test_md5 test_mhlib test_mimetools test_mimetypes test_minidom test_mmap test_module test_modulefinder test_multibytecodec test_multibytecodec_support test_multifile test_mutants test_netrc test_new test_nis test_normalization test_ntpath test_old_mailbox test_openpty test_operator test_optparse test_os test_parser test_peepholer test_pep247 test_pep263 test_pep277 test_pep277 skipped -- test works only on NT+ test_pep292 test_pep352 test_pickle test_pickletools test_pipes test_pkg test_pkgimport test_platform test_plistlib test_plistlib skipped -- No module named plistlib test_poll test_popen [8908 refs] [8908 refs] [8908 refs] test_popen2 test_poplib test_posix test_posixpath test_pow test_pprint test_profile test_profilehooks test_property test_pty test_pwd test_pyclbr test_pyexpat test_queue test_quopri [9277 refs] [9277 refs] test_random test_rational test_re test_repr test_resource test_rfc822 test_richcmp test_robotparser test_runpy test_sax test_scope test_scriptpackages test_scriptpackages skipped -- No module named aetools test_select test_set test_sets test_sgmllib test_sha test_shelve test_shlex test_shutil test_signal test_site test_slice test_smtplib test_socket test_socket_ssl /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:94: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ssl_sock = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:60: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:130: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:144: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) test_socketserver test_softspace test_sort test_sqlite test_ssl test_startfile test_startfile skipped -- cannot import name startfile test_str test_strftime test_string test_stringprep test_strop test_strptime test_struct test_structmembers test_structseq test_subprocess [8903 refs] [8906 refs] [8903 refs] [8903 refs] [8903 refs] [8903 refs] [8903 refs] [8903 refs] [8903 refs] [8905 refs] [8906 refs] [10457 refs] [9121 refs] [8906 refs] [8903 refs] [8903 refs] [8903 refs] [8903 refs] [8903 refs] . [8903 refs] [8903 refs] this bit of output is from a test of stdout in a different process ... [8903 refs] [8903 refs] [9121 refs] test_sunaudiodev test_sunaudiodev skipped -- No module named sunaudiodev test_sundry test_symtable test_syntax test_sys [8903 refs] [8903 refs] test_tarfile test_tcl test_tcl skipped -- No module named _tkinter test_telnetlib test_tempfile [8909 refs] test_textwrap test_thread test_threaded_import test_threadedtempfile test_threading [13151 refs] test_threading_local test_threadsignals test_time test_timeout test_tokenize test_trace test_traceback test_transformer test_tuple test_typechecks test_ucn test_unary test_unicode test_unicode_file test_unicode_file skipped -- No Unicode filesystem semantics on this platform. test_unicodedata test_univnewlines test_unpack test_urllib test_urllib2 test_urllib2_localnet test_urllib2net test test_urllib2net failed -- Traceback (most recent call last): File "/tmp/python-test/local/lib/python2.6/test/test_urllib2net.py", line 175, in test_ftp self._test_urls(urls, self._extra_handlers()) File "/tmp/python-test/local/lib/python2.6/test/test_urllib2net.py", line 244, in _test_urls f = urllib2.urlopen(url, req) File "/tmp/python-test/local/lib/python2.6/urllib2.py", line 124, in urlopen return _opener.open(url, data, timeout) File "/tmp/python-test/local/lib/python2.6/urllib2.py", line 380, in open response = self._open(req, data) File "/tmp/python-test/local/lib/python2.6/urllib2.py", line 398, in _open '_open', req) File "/tmp/python-test/local/lib/python2.6/urllib2.py", line 358, in _call_chain result = func(*args) File "/tmp/python-test/local/lib/python2.6/urllib2.py", line 1284, in ftp_open fp, retrlen = fw.retrfile(file, type) File "/tmp/python-test/local/lib/python2.6/urllib.py", line 880, in retrfile self.ftp.cwd(file) File "/tmp/python-test/local/lib/python2.6/ftplib.py", line 503, in cwd return self.voidcmd(cmd) File "/tmp/python-test/local/lib/python2.6/ftplib.py", line 246, in voidcmd return self.voidresp() File "/tmp/python-test/local/lib/python2.6/ftplib.py", line 221, in voidresp resp = self.getresp() File "/tmp/python-test/local/lib/python2.6/ftplib.py", line 216, in getresp raise error_perm, resp TypeError: __init__() takes exactly 2 arguments (3 given) test_urllibnet test_urlparse test_userdict test_userlist test_userstring test_uu test_uuid WARNING: uuid.getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._ifconfig_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._unixdll_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. test_wait3 test_wait4 test_warnings test_wave test_weakref test_whichdb test_winreg test_winreg skipped -- No module named _winreg test_winsound test_winsound skipped -- No module named winsound test_with test_wsgiref test_xdrlib test_xml_etree test_xml_etree_c test_xmllib test_xmlrpc test_xpickle test_xrange test_zipfile /tmp/python-test/local/lib/python2.6/test/test_zipfile.py:471: DeprecationWarning: struct integer overflow masking is deprecated zipfp.close() /tmp/python-test/local/lib/python2.6/test/test_zipfile.py:398: DeprecationWarning: struct integer overflow masking is deprecated zipfp.close() test_zipfile64 test_zipfile64 skipped -- test requires loads of disk-space bytes and a long time to run test_zipimport test_zlib 312 tests OK. 2 tests failed: test_bsddb3 test_urllib2net 21 tests skipped: test_aepack test_al test_applesingle test_bsddb185 test_cd test_cl test_gl test_imageop test_imgfile test_ioctl test_macostools test_pep277 test_plistlib test_scriptpackages test_startfile test_sunaudiodev test_tcl test_unicode_file test_winreg test_winsound test_zipfile64 1 skip unexpected on linux2: test_ioctl [541285 refs] From buildbot at python.org Mon Jan 21 01:07:44 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 21 Jan 2008 00:07:44 +0000 Subject: [Python-checkins] buildbot failure in alpha Debian 2.5 Message-ID: <20080121000744.BF79A1E4023@bag.python.org> The Buildbot has detected a new failure of alpha Debian 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/alpha%20Debian%202.5/builds/11 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-alpha Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: andrew.kuchling,gregory.p.smith BUILD FAILED: failed failed slave lost sincerely, -The Buildbot From python-checkins at python.org Mon Jan 21 08:11:11 2008 From: python-checkins at python.org (gregory.p.smith) Date: Mon, 21 Jan 2008 08:11:11 +0100 (CET) Subject: [Python-checkins] r60148 - python/trunk/Python/pystate.c Message-ID: <20080121071111.B82C81E4411@bag.python.org> Author: gregory.p.smith Date: Mon Jan 21 08:11:11 2008 New Revision: 60148 Modified: python/trunk/Python/pystate.c Log: Provide a sanity check during PyThreadState_DeleteCurrent() and PyThreadState_Delete() to avoid an infinite loop when the tstate list is messed up and has somehow becomes circular and does not contain the current thread. I don't know how this happens but it does, *very* rarely. On more than one hardware platform. I have not been able to reproduce it manually. Attaching to a process where its happening: it has always been in an infinite loop over a single element tstate list that is not the tstate we're looking to delete. It has been in t_bootstrap()'s call to PyThreadState_DeleteCurrent() as a pthread is exiting. Modified: python/trunk/Python/pystate.c ============================================================================== --- python/trunk/Python/pystate.c (original) +++ python/trunk/Python/pystate.c Mon Jan 21 08:11:11 2008 @@ -240,6 +240,7 @@ { PyInterpreterState *interp; PyThreadState **p; + PyThreadState *prev_p = NULL; if (tstate == NULL) Py_FatalError("PyThreadState_Delete: NULL tstate"); interp = tstate->interp; @@ -252,6 +253,15 @@ "PyThreadState_Delete: invalid tstate"); if (*p == tstate) break; + if (*p == prev_p) + Py_FatalError( + "PyThreadState_Delete: small circular list(!)" + " and tstate not found."); + prev_p = *p; + if ((*p)->next == interp->tstate_head) + Py_FatalError( + "PyThreadState_Delete: circular list(!) and" + " tstate not found."); } *p = tstate->next; HEAD_UNLOCK(); From nnorwitz at gmail.com Mon Jan 21 11:26:16 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Mon, 21 Jan 2008 05:26:16 -0500 Subject: [Python-checkins] Python Regression Test Failures refleak (8) Message-ID: <20080121102616.GA17149@python.psfb.org> test_opcodes leaked [-2, 0, 2] references, sum=0 test_doctest leaked [0, 0, -2] references, sum=-2 test_descrtut leaked [-2, -2, 4] references, sum=0 test_dummy_thread leaked [0, -2, 0] references, sum=-2 test_gc leaked [-2, 0, 2] references, sum=0 test_genericpath leaked [0, -2, 0] references, sum=-2 test_importhooks leaked [6, 4, 0] references, sum=10 test_index leaked [-2, 0, 0] references, sum=-2 test_os leaked [2, -2, 2] references, sum=2 test_pkgimport leaked [2, 0, 0] references, sum=2 test_popen leaked [0, 0, -2] references, sum=-2 test_sqlite leaked [-2, 2, 0] references, sum=0 test_threadsignals leaked [0, -8, 0] references, sum=-8 test_urllib2_localnet leaked [3, 3, 3] references, sum=9 test_weakref leaked [-2, 2, 0] references, sum=0 From nnorwitz at gmail.com Mon Jan 21 11:43:21 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Mon, 21 Jan 2008 05:43:21 -0500 Subject: [Python-checkins] Python Regression Test Failures all (1) Message-ID: <20080121104321.GA19222@python.psfb.org> test_grammar test_opcodes test_dict test_builtin test_exceptions test_types test_unittest test_doctest test_doctest2 test_MimeWriter test_StringIO test___all__ test___future__ test__locale test_abc test_abstract_numbers test_aepack test_aepack skipped -- No module named aepack test_al test_al skipped -- No module named al test_anydbm test_applesingle test_applesingle skipped -- No module named macostools test_array test_ast test_asynchat test_asyncore test_atexit test_audioop test_augassign test_base64 test_bastion test_bigaddrspace test_bigmem test_binascii test_binhex test_binop test_bisect test_bool test_bsddb test_bsddb185 test_bsddb185 skipped -- No module named bsddb185 test_bsddb3 test test_bsddb3 failed -- errors occurred; run in verbose mode for details test_buffer test_bufio test_bz2 test_cProfile test_calendar test_call test_capi test_cd test_cd skipped -- No module named cd test_cfgparser test_cgi test_charmapcodec test_cl test_cl skipped -- No module named cl test_class test_cmath test_cmd test_cmd_line test_cmd_line_script test_code test_codeccallbacks test_codecencodings_cn test_codecencodings_hk test_codecencodings_jp test_codecencodings_kr test_codecencodings_tw test_codecmaps_cn test_codecmaps_hk test_codecmaps_jp test_codecmaps_kr test_codecmaps_tw test_codecs test_codeop test_coding test_coercion test_collections test_colorsys test_commands test_compare test_compile test_compiler testCompileLibrary still working, be patient... test_complex test_complex_args test_contains test_contextlib test_cookie test_cookielib test_copy test_copy_reg test_cpickle test_crypt test_csv test_ctypes test_datetime test_dbm test_decimal test_decorators test_defaultdict test_deque test_descr test_descrtut test_difflib test_dircache test_dis test_distutils test_dl test_docxmlrpc test_dumbdbm test_dummy_thread test_dummy_threading test_email test_email_codecs test_email_renamed test_enumerate test_eof test_errno test_exception_variations test_extcall test_fcntl test_file test_filecmp test_fileinput test_float test_fnmatch test_fork1 test_format test_fpformat test_frozen test_ftplib test_funcattrs test_functools test_future test_gc test_gdbm test_generators test_genericpath test_genexps test_getargs test_getargs2 test_getopt test_gettext test_gl test_gl skipped -- No module named gl test_glob test_global test_grp test_gzip test_hash test_hashlib test_heapq test_hexoct test_hmac test_hotshot test_htmllib test_htmlparser test_httplib test_imageop test_imageop skipped -- No module named imgfile test_imaplib test_imgfile test_imgfile skipped -- No module named imgfile test_imp test_import test_importhooks test_index test_inspect test_ioctl test_ioctl skipped -- Unable to open /dev/tty test_isinstance test_iter test_iterlen test_itertools test_largefile test_list test_locale test_logging test_long test_long_future test_longexp test_macostools test_macostools skipped -- No module named macostools test_macpath test_mailbox test_marshal test_math test_md5 test_mhlib test_mimetools test_mimetypes test_minidom test_mmap test_module test_modulefinder test_multibytecodec test_multibytecodec_support test_multifile test_mutants test_netrc test_new test_nis test_normalization test_ntpath test_old_mailbox test_openpty test_operator test_optparse test_os test_parser test_peepholer test_pep247 test_pep263 test_pep277 test_pep277 skipped -- test works only on NT+ test_pep292 test_pep352 test_pickle test_pickletools test_pipes test_pkg test_pkgimport test_platform test_plistlib test_plistlib skipped -- No module named plistlib test_poll test_popen [8908 refs] [8908 refs] [8908 refs] test_popen2 test_poplib test_posix test_posixpath test_pow test_pprint test_profile test_profilehooks test_property test_pty test_pwd test_pyclbr test_pyexpat test_queue test_quopri [9277 refs] [9277 refs] test_random test_rational test_re test_repr test_resource test_rfc822 test_richcmp test_robotparser test_runpy test_sax test_scope test_scriptpackages test_scriptpackages skipped -- No module named aetools test_select test_set test_sets test_sgmllib test_sha test_shelve test_shlex test_shutil test_signal test_site test_slice test_smtplib test_socket test_socket_ssl /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:94: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ssl_sock = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:60: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:130: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:144: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) test_socketserver test_softspace test_sort test_sqlite test_ssl test_startfile test_startfile skipped -- cannot import name startfile test_str test_strftime test_string test_stringprep test_strop test_strptime test_struct test_structmembers test_structseq test_subprocess [8903 refs] [8906 refs] [8903 refs] [8903 refs] [8903 refs] [8903 refs] [8903 refs] [8903 refs] [8903 refs] [8905 refs] [8906 refs] [10457 refs] [9121 refs] [8906 refs] [8903 refs] [8903 refs] [8903 refs] [8903 refs] [8903 refs] . [8903 refs] [8903 refs] this bit of output is from a test of stdout in a different process ... [8903 refs] [8903 refs] [9121 refs] test_sunaudiodev test_sunaudiodev skipped -- No module named sunaudiodev test_sundry test_symtable test_syntax test_sys [8903 refs] [8903 refs] test_tarfile test_tcl test_tcl skipped -- No module named _tkinter test_telnetlib test_tempfile [8909 refs] test_textwrap test_thread test_threaded_import test_threadedtempfile test_threading [13151 refs] test_threading_local test_threadsignals test_time test_timeout test_tokenize test_trace test_traceback test_transformer test_tuple test_typechecks test_ucn test_unary test_unicode test_unicode_file test_unicode_file skipped -- No Unicode filesystem semantics on this platform. test_unicodedata test_univnewlines test_unpack test_urllib test_urllib2 test_urllib2_localnet test_urllib2net test test_urllib2net failed -- Traceback (most recent call last): File "/tmp/python-test/local/lib/python2.6/test/test_urllib2net.py", line 175, in test_ftp self._test_urls(urls, self._extra_handlers()) File "/tmp/python-test/local/lib/python2.6/test/test_urllib2net.py", line 244, in _test_urls f = urllib2.urlopen(url, req) File "/tmp/python-test/local/lib/python2.6/urllib2.py", line 124, in urlopen return _opener.open(url, data, timeout) File "/tmp/python-test/local/lib/python2.6/urllib2.py", line 380, in open response = self._open(req, data) File "/tmp/python-test/local/lib/python2.6/urllib2.py", line 398, in _open '_open', req) File "/tmp/python-test/local/lib/python2.6/urllib2.py", line 358, in _call_chain result = func(*args) File "/tmp/python-test/local/lib/python2.6/urllib2.py", line 1284, in ftp_open fp, retrlen = fw.retrfile(file, type) File "/tmp/python-test/local/lib/python2.6/urllib.py", line 880, in retrfile self.ftp.cwd(file) File "/tmp/python-test/local/lib/python2.6/ftplib.py", line 503, in cwd return self.voidcmd(cmd) File "/tmp/python-test/local/lib/python2.6/ftplib.py", line 246, in voidcmd return self.voidresp() File "/tmp/python-test/local/lib/python2.6/ftplib.py", line 221, in voidresp resp = self.getresp() File "/tmp/python-test/local/lib/python2.6/ftplib.py", line 216, in getresp raise error_perm, resp TypeError: __init__() takes exactly 2 arguments (3 given) test_urllibnet test_urlparse test_userdict test_userlist test_userstring test_uu test_uuid WARNING: uuid.getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._ifconfig_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._unixdll_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. test_wait3 test_wait4 test_warnings test_wave test_weakref test_whichdb test_winreg test_winreg skipped -- No module named _winreg test_winsound test_winsound skipped -- No module named winsound test_with test_wsgiref test_xdrlib test_xml_etree test_xml_etree_c test_xmllib test_xmlrpc test_xpickle test_xrange test_zipfile /tmp/python-test/local/lib/python2.6/test/test_zipfile.py:471: DeprecationWarning: struct integer overflow masking is deprecated zipfp.close() /tmp/python-test/local/lib/python2.6/test/test_zipfile.py:398: DeprecationWarning: struct integer overflow masking is deprecated zipfp.close() test_zipfile64 test_zipfile64 skipped -- test requires loads of disk-space bytes and a long time to run test_zipimport test_zlib 312 tests OK. 2 tests failed: test_bsddb3 test_urllib2net 21 tests skipped: test_aepack test_al test_applesingle test_bsddb185 test_cd test_cl test_gl test_imageop test_imgfile test_ioctl test_macostools test_pep277 test_plistlib test_scriptpackages test_startfile test_sunaudiodev test_tcl test_unicode_file test_winreg test_winsound test_zipfile64 1 skip unexpected on linux2: test_ioctl [541289 refs] From python-checkins at python.org Mon Jan 21 11:25:00 2008 From: python-checkins at python.org (georg.brandl) Date: Mon, 21 Jan 2008 11:25:00 +0100 (CET) Subject: [Python-checkins] r60149 - in python/trunk: Lib/pstats.py Lib/test/test_pstats.py Misc/NEWS Message-ID: <20080121102500.4A3581E4019@bag.python.org> Author: georg.brandl Date: Mon Jan 21 11:24:59 2008 New Revision: 60149 Added: python/trunk/Lib/test/test_pstats.py Modified: python/trunk/Lib/pstats.py python/trunk/Misc/NEWS Log: #1269: fix a bug in pstats.add_callers() and add a unit test file for pstats. Modified: python/trunk/Lib/pstats.py ============================================================================== --- python/trunk/Lib/pstats.py (original) +++ python/trunk/Lib/pstats.py Mon Jan 21 11:24:59 2008 @@ -512,7 +512,8 @@ new_callers[func] = caller for func, caller in source.iteritems(): if func in new_callers: - new_callers[func] = caller + new_callers[func] + new_callers[func] = tuple([i[0] + i[1] for i in + zip(caller, new_callers[func])]) else: new_callers[func] = caller return new_callers Added: python/trunk/Lib/test/test_pstats.py ============================================================================== --- (empty file) +++ python/trunk/Lib/test/test_pstats.py Mon Jan 21 11:24:59 2008 @@ -0,0 +1,26 @@ +import unittest +from test import test_support +import pstats + + + +class AddCallersTestCase(unittest.TestCase): + """Tests for pstats.add_callers helper.""" + + def test_combine_results(self): + """pstats.add_callers should combine the call results of both target + and source by adding the call time. See issue1269.""" + target = {"a": (1, 2, 3, 4)} + source = {"a": (1, 2, 3, 4), "b": (5, 6, 7, 8)} + new_callers = pstats.add_callers(target, source) + self.assertEqual(new_callers, {'a': (2, 4, 6, 8), 'b': (5, 6, 7, 8)}) + + +def test_main(): + test_support.run_unittest( + AddCallersTestCase + ) + + +if __name__ == "__main__": + test_main() Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Mon Jan 21 11:24:59 2008 @@ -369,6 +369,9 @@ Library ------- +- #1269: fix a bug in pstats.add_callers() and add a unit test file for + pstats. + - #1669: don't allow shutil.rmtree() to be called on a symlink to a directory. From python-checkins at python.org Mon Jan 21 14:11:16 2008 From: python-checkins at python.org (christian.heimes) Date: Mon, 21 Jan 2008 14:11:16 +0100 (CET) Subject: [Python-checkins] r60151 - python/trunk/Makefile.pre.in Message-ID: <20080121131116.084541E403D@bag.python.org> Author: christian.heimes Date: Mon Jan 21 14:11:15 2008 New Revision: 60151 Modified: python/trunk/Makefile.pre.in Log: A bunch of header files were not listed as dependencies for object files. Changes to files like Parser/parser.h weren't picked up by make. Modified: python/trunk/Makefile.pre.in ============================================================================== --- python/trunk/Makefile.pre.in (original) +++ python/trunk/Makefile.pre.in Mon Jan 21 14:11:15 2008 @@ -224,6 +224,10 @@ Parser/printgrammar.o \ Parser/pgenmain.o +PARSER_HEADERS= \ + Parser/parser.h \ + Parser/tokenizer.h + PGENOBJS= $(PGENMAIN) $(POBJS) $(PGOBJS) ########################################################################## @@ -515,12 +519,15 @@ # Header files PYTHON_HEADERS= \ - Include/Python.h \ Include/Python-ast.h \ - Include/asdl.h \ + Include/Python.h \ Include/abstract.h \ + Include/asdl.h \ + Include/ast.h \ + Include/bitset.h \ Include/boolobject.h \ Include/bufferobject.h \ + Include/cellobject.h \ Include/ceval.h \ Include/classobject.h \ Include/cobject.h \ @@ -531,46 +538,61 @@ Include/descrobject.h \ Include/dictobject.h \ Include/enumobject.h \ - Include/genobject.h \ + Include/errcode.h \ + Include/eval.h \ Include/fileobject.h \ Include/floatobject.h \ + Include/frameobject.h \ Include/funcobject.h \ + Include/genobject.h \ Include/import.h \ Include/intobject.h \ Include/intrcheck.h \ Include/iterobject.h \ Include/listobject.h \ + Include/longintrepr.h \ Include/longobject.h \ + Include/marshal.h \ + Include/metagrammar.h \ Include/methodobject.h \ Include/modsupport.h \ Include/moduleobject.h \ + Include/node.h \ Include/object.h \ Include/objimpl.h \ + Include/opcode.h \ + Include/osdefs.h \ Include/parsetok.h \ Include/patchlevel.h \ + Include/pgen.h \ + Include/pgenheaders.h \ Include/pyarena.h \ Include/pydebug.h \ Include/pyerrors.h \ Include/pyfpe.h \ + Include/pygetopt.h \ Include/pymem.h \ Include/pyport.h \ Include/pystate.h \ - Include/pystrtod.h \ Include/pystrcmp.h \ + Include/pystrtod.h \ Include/pythonrun.h \ + Include/pythread.h \ Include/rangeobject.h \ - Include/setobject.h \ + Include/setobject.h \ Include/sliceobject.h \ Include/stringobject.h \ - Include/structseq.h \ Include/structmember.h \ + Include/structseq.h \ Include/symtable.h \ Include/sysmodule.h \ Include/traceback.h \ Include/tupleobject.h \ + Include/ucnhash.h \ Include/unicodeobject.h \ Include/weakrefobject.h \ - pyconfig.h + pyconfig.h \ + $(PARSER_HEADERS) $(LIBRARY_OBJS) $(MODOBJS) Modules/python.o: $(PYTHON_HEADERS) From python-checkins at python.org Mon Jan 21 15:16:47 2008 From: python-checkins at python.org (georg.brandl) Date: Mon, 21 Jan 2008 15:16:47 +0100 (CET) Subject: [Python-checkins] r60152 - in python/trunk: Doc/library/mmap.rst Misc/NEWS Modules/mmapmodule.c Message-ID: <20080121141647.14A781E401C@bag.python.org> Author: georg.brandl Date: Mon Jan 21 15:16:46 2008 New Revision: 60152 Modified: python/trunk/Doc/library/mmap.rst python/trunk/Misc/NEWS python/trunk/Modules/mmapmodule.c Log: #1087741: make mmap.mmap the type of mmap objects, not a factory function. Allow it to be subclassed. Modified: python/trunk/Doc/library/mmap.rst ============================================================================== --- python/trunk/Doc/library/mmap.rst (original) +++ python/trunk/Doc/library/mmap.rst Mon Jan 21 15:16:46 2008 @@ -15,7 +15,7 @@ and write data starting at the current file position, and :meth:`seek` through the file to different positions. -A memory-mapped file is created by the :func:`mmap` function, which is different +A memory-mapped file is created by the :class:`mmap` constructor, which is different on Unix and on Windows. In either case you must provide a file descriptor for a file opened for update. If you wish to map an existing Python file object, use its :meth:`fileno` method to obtain the correct value for the *fileno* @@ -23,7 +23,7 @@ which returns a file descriptor directly (the file still needs to be closed when done). -For both the Unix and Windows versions of the function, *access* may be +For both the Unix and Windows versions of the constructor, *access* may be specified as an optional keyword parameter. *access* accepts one of three values: :const:`ACCESS_READ`, :const:`ACCESS_WRITE`, or :const:`ACCESS_COPY` to specify readonly, write-through or copy-on-write memory respectively. *access* @@ -39,11 +39,14 @@ To map anonymous memory, -1 should be passed as the fileno along with the length. +.. versionchanged:: 2.6 + mmap.mmap has formerly been a factory function creating mmap objects. Now + mmap.mmap is the class itself. -.. function:: mmap(fileno, length[, tagname[, access[, offset]]]) +.. class:: mmap(fileno, length[, tagname[, access[, offset]]]) **(Windows version)** Maps *length* bytes from the file specified by the file - handle *fileno*, and returns a mmap object. If *length* is larger than the + handle *fileno*, and creates a mmap object. If *length* is larger than the current size of the file, the file is extended to contain *length* bytes. If *length* is ``0``, the maximum length of the map is the current size of the file, except that if the file is empty Windows raises an exception (you cannot @@ -61,12 +64,12 @@ *offset* must be a multiple of the ALLOCATIONGRANULARITY. -.. function:: mmap(fileno, length[, flags[, prot[, access[, offset]]]]) +.. class:: mmap(fileno, length[, flags[, prot[, access[, offset]]]]) :noindex: **(Unix version)** Maps *length* bytes from the file specified by the file descriptor *fileno*, and returns a mmap object. If *length* is ``0``, the - maximum length of the map will be the current size of the file when :func:`mmap` + maximum length of the map will be the current size of the file when :class:`mmap` is called. *flags* specifies the nature of the mapping. :const:`MAP_PRIVATE` creates a @@ -87,7 +90,7 @@ be relative to the offset from the beginning of the file. *offset* defaults to 0. *offset* must be a multiple of the PAGESIZE or ALLOCATIONGRANULARITY. - This example shows a simple way of using :func:`mmap`:: + This example shows a simple way of using :class:`mmap`:: import mmap Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Mon Jan 21 15:16:46 2008 @@ -368,6 +368,8 @@ Library ------- +- #1087741: mmap.mmap is now a class, not a factory function. It is also + subclassable now. - #1269: fix a bug in pstats.add_callers() and add a unit test file for pstats. Modified: python/trunk/Modules/mmapmodule.c ============================================================================== --- python/trunk/Modules/mmapmodule.c (original) +++ python/trunk/Modules/mmapmodule.c Mon Jan 21 15:16:46 2008 @@ -974,6 +974,9 @@ (charbufferproc)mmap_buffer_getcharbuffer, }; +static PyObject * +new_mmap_object(PyTypeObject *type, PyObject *args, PyObject *kwdict); + PyDoc_STRVAR(mmap_doc, "Windows: mmap(fileno, length[, tagname[, access[, offset]]])\n\ \n\ @@ -999,7 +1002,7 @@ static PyTypeObject mmap_object_type = { - PyVarObject_HEAD_INIT(0, 0) /* patched in module init */ + PyVarObject_HEAD_INIT(NULL, 0) "mmap.mmap", /* tp_name */ sizeof(mmap_object), /* tp_size */ 0, /* tp_itemsize */ @@ -1019,16 +1022,26 @@ PyObject_GenericGetAttr, /*tp_getattro*/ 0, /*tp_setattro*/ &mmap_as_buffer, /*tp_as_buffer*/ - Py_TPFLAGS_HAVE_GETCHARBUFFER, /*tp_flags*/ + Py_TPFLAGS_DEFAULT | Py_TPFLAGS_BASETYPE | Py_TPFLAGS_HAVE_GETCHARBUFFER, /*tp_flags*/ mmap_doc, /*tp_doc*/ 0, /* tp_traverse */ 0, /* tp_clear */ 0, /* tp_richcompare */ 0, /* tp_weaklistoffset */ - 0, /* tp_iter */ - 0, /* tp_iternext */ + 0, /* tp_iter */ + 0, /* tp_iternext */ mmap_object_methods, /* tp_methods */ - + 0, /* tp_members */ + 0, /* tp_getset */ + 0, /* tp_base */ + 0, /* tp_dict */ + 0, /* tp_descr_get */ + 0, /* tp_descr_set */ + 0, /* tp_dictoffset */ + 0, /* tp_init */ + PyType_GenericAlloc, /* tp_alloc */ + new_mmap_object, /* tp_new */ + PyObject_Del, /* tp_free */ }; @@ -1060,7 +1073,7 @@ #ifdef UNIX static PyObject * -new_mmap_object(PyObject *self, PyObject *args, PyObject *kwdict) +new_mmap_object(PyTypeObject *type, PyObject *args, PyObject *kwdict) { #ifdef HAVE_FSTAT struct stat st; @@ -1128,7 +1141,7 @@ } } #endif - m_obj = PyObject_New(mmap_object, &mmap_object_type); + m_obj = (mmap_object *)type->tp_alloc(type, 0); if (m_obj == NULL) {return NULL;} m_obj->data = NULL; m_obj->size = (size_t) map_size; @@ -1182,7 +1195,7 @@ #ifdef MS_WINDOWS static PyObject * -new_mmap_object(PyObject *self, PyObject *args, PyObject *kwdict) +new_mmap_object(PyTypeObject *type, PyObject *args, PyObject *kwdict) { mmap_object *m_obj; PyObject *map_size_obj = NULL, *offset_obj = NULL; @@ -1250,7 +1263,7 @@ lseek(fileno, 0, SEEK_SET); } - m_obj = PyObject_New(mmap_object, &mmap_object_type); + m_obj = (mmap_object *)type->tp_alloc(type, 0); if (m_obj == NULL) return NULL; /* Set every field to an invalid marker, so we can safely @@ -1364,13 +1377,6 @@ } #endif /* MS_WINDOWS */ -/* List of functions exported by this module */ -static struct PyMethodDef mmap_functions[] = { - {"mmap", (PyCFunction) new_mmap_object, - METH_VARARGS|METH_KEYWORDS, mmap_doc}, - {NULL, NULL} /* Sentinel */ -}; - static void setint(PyObject *d, const char *name, long value) { @@ -1381,14 +1387,14 @@ } PyMODINIT_FUNC - initmmap(void) +initmmap(void) { PyObject *dict, *module; - /* Patch the object type */ - Py_TYPE(&mmap_object_type) = &PyType_Type; + if (PyType_Ready(&mmap_object_type) < 0) + return; - module = Py_InitModule("mmap", mmap_functions); + module = Py_InitModule("mmap", NULL); if (module == NULL) return; dict = PyModule_GetDict(module); @@ -1396,6 +1402,7 @@ return; mmap_module_error = PyExc_EnvironmentError; PyDict_SetItemString(dict, "error", mmap_module_error); + PyDict_SetItemString(dict, "mmap", (PyObject*) &mmap_object_type); #ifdef PROT_EXEC setint(dict, "PROT_EXEC", PROT_EXEC); #endif From python-checkins at python.org Mon Jan 21 15:18:14 2008 From: python-checkins at python.org (georg.brandl) Date: Mon, 21 Jan 2008 15:18:14 +0100 (CET) Subject: [Python-checkins] r60153 - python/trunk/Misc/NEWS Message-ID: <20080121141814.D19E21E402F@bag.python.org> Author: georg.brandl Date: Mon Jan 21 15:18:14 2008 New Revision: 60153 Modified: python/trunk/Misc/NEWS Log: mmap is an extension module. Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Mon Jan 21 15:18:14 2008 @@ -368,8 +368,6 @@ Library ------- -- #1087741: mmap.mmap is now a class, not a factory function. It is also - subclassable now. - #1269: fix a bug in pstats.add_callers() and add a unit test file for pstats. @@ -1050,6 +1048,9 @@ Extension Modules ----------------- +- #1087741: mmap.mmap is now a class, not a factory function. It is also + subclassable now. + - Patch #1648: added ``sys.getprofile()`` and ``sys.gettrace()``. - Patch #1663329: added ``os.closerange()`` function to quickly close a range From python-checkins at python.org Mon Jan 21 17:28:13 2008 From: python-checkins at python.org (georg.brandl) Date: Mon, 21 Jan 2008 17:28:13 +0100 (CET) Subject: [Python-checkins] r60154 - python/trunk/Doc/library/configparser.rst Message-ID: <20080121162814.03FBB1E4038@bag.python.org> Author: georg.brandl Date: Mon Jan 21 17:28:13 2008 New Revision: 60154 Modified: python/trunk/Doc/library/configparser.rst Log: Fix example. Modified: python/trunk/Doc/library/configparser.rst ============================================================================== --- python/trunk/Doc/library/configparser.rst (original) +++ python/trunk/Doc/library/configparser.rst Mon Jan 21 17:28:13 2008 @@ -446,3 +446,5 @@ # Create non-existent section config.add_section(section2) opt_move(config, section1, section2, option) + else: + config.remove_option(section1, option) From python-checkins at python.org Mon Jan 21 17:34:08 2008 From: python-checkins at python.org (georg.brandl) Date: Mon, 21 Jan 2008 17:34:08 +0100 (CET) Subject: [Python-checkins] r60155 - in python/trunk: Doc/library/fileformats.rst Doc/library/plistlib.rst Lib/plat-mac/plistlib.py Lib/plistlib.py Misc/NEWS Message-ID: <20080121163408.59F8A1E401C@bag.python.org> Author: georg.brandl Date: Mon Jan 21 17:34:07 2008 New Revision: 60155 Added: python/trunk/Doc/library/plistlib.rst python/trunk/Lib/plistlib.py - copied, changed from r60148, python/trunk/Lib/plat-mac/plistlib.py Removed: python/trunk/Lib/plat-mac/plistlib.py Modified: python/trunk/Doc/library/fileformats.rst python/trunk/Misc/NEWS Log: #1555501: document plistlib and move it to the general library. Modified: python/trunk/Doc/library/fileformats.rst ============================================================================== --- python/trunk/Doc/library/fileformats.rst (original) +++ python/trunk/Doc/library/fileformats.rst Mon Jan 21 17:34:07 2008 @@ -16,3 +16,4 @@ robotparser.rst netrc.rst xdrlib.rst + plistlib.rst Added: python/trunk/Doc/library/plistlib.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/library/plistlib.rst Mon Jan 21 17:34:07 2008 @@ -0,0 +1,124 @@ +:mod:`plistlib` --- Generate and parse MacOS X ``.plist`` files +=============================================================== + +.. module:: plistlib + :synopsis: Generate and parse MacOS X plist files. +.. moduleauthor:: Jack Jansen +.. sectionauthor:: Georg Brandl +.. (harvested from docstrings in the original file) + +.. versionchanged:: 2.6 + This module was previously only available in the Mac-specific library, it is + now available for all platforms. + +.. index:: + pair: plist; file + single: property list + +This module provides an interface for reading and writing the "property list" +XML files used mainly by MacOS X. + +The property list (``.plist``) file format is a simple XML pickle supporting +basic object types, like dictionaries, lists, numbers and strings. Usually the +top level object is a dictionary. + +Values can be strings, integers, floats, booleans, tuples, lists, dictionaries +(but only with string keys), :class:`Data` or :class:`datetime.datetime` +objects. String values (including dictionary keys) may be unicode strings -- +they will be written out as UTF-8. + +The ```` plist type is supported through the :class:`Data` class. This is +a thin wrapper around a Python string. Use :class:`Data` if your strings +contain control characters. + +.. seealso:: + + `PList manual page ` + Apple's documentation of the file format. + + +This module defines the following functions: + +.. function:: readPlist(pathOrFile) + + Read a plist file. *pathOrFile* may either be a file name or a (readable) + file object. Return the unpacked root object (which usually is a + dictionary). + + The XML data is parsed using the Expat parser from :mod:`xml.parsers.expat` + -- see its documentation for possible exceptions on ill-formed XML. + Unknown elements will simply be ignored by the plist parser. + + +.. function:: writePlist(rootObject, pathOrFile) + + Write *rootObject* to a plist file. *pathOrFile* may either be a file name + or a (writable) file object. + + A :exc:`TypeError` will be raised if the object is of an unsupported type or + a container that contains objects of unsupported types. + + +.. function:: readPlistFromString(data) + + Read a plist from a string. Return the root object. + + +.. function:: writePlistToString(rootObject) + + Return *rootObject* as a plist-formatted string. + + + +.. function:: readPlistFromResource(path[, restype='plst'[, resid=0]]) + + Read a plist from the resource with type *restype* from the resource fork of + *path*. Availability: MacOS X. + + +.. function:: writePlistToResource(rootObject, path[, restype='plst'[, resid=0]]) + + Write *rootObject* as a resource with type *restype* to the resource fork of + *path*. Availability: MacOS X. + + +The following class is available: + +.. class:: Data(data) + + Return a "data" wrapper object around the string *data*. This is used in + functions converting from/to plists to represent the ```` type + available in plists. + + It has one attribute, :attr:`data`, that can be used to retrieve the Python + string stored in it. + + +Examples +-------- + +Generating a plist:: + + pl = dict( + aString="Doodah", + aList=["A", "B", 12, 32.1, [1, 2, 3]], + aFloat = 0.1, + anInt = 728, + aDict=dict( + anotherString="", + aUnicodeValue=u'M\xe4ssig, Ma\xdf', + aTrueValue=True, + aFalseValue=False, + ), + someData = Data(""), + someMoreData = Data("" * 10), + aDate = datetime.datetime.fromtimestamp(time.mktime(time.gmtime())), + ) + # unicode keys are possible, but a little awkward to use: + pl[u'\xc5benraa'] = "That was a unicode key." + writePlist(pl, fileName) + +Parsing a plist:: + + pl = readPlist(pathOrFile) + print pl["aKey"] Deleted: /python/trunk/Lib/plat-mac/plistlib.py ============================================================================== --- /python/trunk/Lib/plat-mac/plistlib.py Mon Jan 21 17:34:07 2008 +++ (empty file) @@ -1,470 +0,0 @@ -"""plistlib.py -- a tool to generate and parse MacOSX .plist files. - -The PropertList (.plist) file format is a simple XML pickle supporting -basic object types, like dictionaries, lists, numbers and strings. -Usually the top level object is a dictionary. - -To write out a plist file, use the writePlist(rootObject, pathOrFile) -function. 'rootObject' is the top level object, 'pathOrFile' is a -filename or a (writable) file object. - -To parse a plist from a file, use the readPlist(pathOrFile) function, -with a file name or a (readable) file object as the only argument. It -returns the top level object (again, usually a dictionary). - -To work with plist data in strings, you can use readPlistFromString() -and writePlistToString(). - -Values can be strings, integers, floats, booleans, tuples, lists, -dictionaries, Data or datetime.datetime objects. String values (including -dictionary keys) may be unicode strings -- they will be written out as -UTF-8. - -The plist type is supported through the Data class. This is a -thin wrapper around a Python string. - -Generate Plist example: - - pl = dict( - aString="Doodah", - aList=["A", "B", 12, 32.1, [1, 2, 3]], - aFloat = 0.1, - anInt = 728, - aDict=dict( - anotherString="", - aUnicodeValue=u'M\xe4ssig, Ma\xdf', - aTrueValue=True, - aFalseValue=False, - ), - someData = Data(""), - someMoreData = Data("" * 10), - aDate = datetime.datetime.fromtimestamp(time.mktime(time.gmtime())), - ) - # unicode keys are possible, but a little awkward to use: - pl[u'\xc5benraa'] = "That was a unicode key." - writePlist(pl, fileName) - -Parse Plist example: - - pl = readPlist(pathOrFile) - print pl["aKey"] -""" - - -__all__ = [ - "readPlist", "writePlist", "readPlistFromString", "writePlistToString", - "readPlistFromResource", "writePlistToResource", - "Plist", "Data", "Dict" -] -# Note: the Plist and Dict classes have been deprecated. - -import binascii -import datetime -from cStringIO import StringIO -import re - - -def readPlist(pathOrFile): - """Read a .plist file. 'pathOrFile' may either be a file name or a - (readable) file object. Return the unpacked root object (which - usually is a dictionary). - """ - didOpen = 0 - if isinstance(pathOrFile, (str, unicode)): - pathOrFile = open(pathOrFile) - didOpen = 1 - p = PlistParser() - rootObject = p.parse(pathOrFile) - if didOpen: - pathOrFile.close() - return rootObject - - -def writePlist(rootObject, pathOrFile): - """Write 'rootObject' to a .plist file. 'pathOrFile' may either be a - file name or a (writable) file object. - """ - didOpen = 0 - if isinstance(pathOrFile, (str, unicode)): - pathOrFile = open(pathOrFile, "w") - didOpen = 1 - writer = PlistWriter(pathOrFile) - writer.writeln("") - writer.writeValue(rootObject) - writer.writeln("") - if didOpen: - pathOrFile.close() - - -def readPlistFromString(data): - """Read a plist data from a string. Return the root object. - """ - return readPlist(StringIO(data)) - - -def writePlistToString(rootObject): - """Return 'rootObject' as a plist-formatted string. - """ - f = StringIO() - writePlist(rootObject, f) - return f.getvalue() - - -def readPlistFromResource(path, restype='plst', resid=0): - """Read plst resource from the resource fork of path. - """ - from Carbon.File import FSRef, FSGetResourceForkName - from Carbon.Files import fsRdPerm - from Carbon import Res - fsRef = FSRef(path) - resNum = Res.FSOpenResourceFile(fsRef, FSGetResourceForkName(), fsRdPerm) - Res.UseResFile(resNum) - plistData = Res.Get1Resource(restype, resid).data - Res.CloseResFile(resNum) - return readPlistFromString(plistData) - - -def writePlistToResource(rootObject, path, restype='plst', resid=0): - """Write 'rootObject' as a plst resource to the resource fork of path. - """ - from Carbon.File import FSRef, FSGetResourceForkName - from Carbon.Files import fsRdWrPerm - from Carbon import Res - plistData = writePlistToString(rootObject) - fsRef = FSRef(path) - resNum = Res.FSOpenResourceFile(fsRef, FSGetResourceForkName(), fsRdWrPerm) - Res.UseResFile(resNum) - try: - Res.Get1Resource(restype, resid).RemoveResource() - except Res.Error: - pass - res = Res.Resource(plistData) - res.AddResource(restype, resid, '') - res.WriteResource() - Res.CloseResFile(resNum) - - -class DumbXMLWriter: - - def __init__(self, file, indentLevel=0, indent="\t"): - self.file = file - self.stack = [] - self.indentLevel = indentLevel - self.indent = indent - - def beginElement(self, element): - self.stack.append(element) - self.writeln("<%s>" % element) - self.indentLevel += 1 - - def endElement(self, element): - assert self.indentLevel > 0 - assert self.stack.pop() == element - self.indentLevel -= 1 - self.writeln("" % element) - - def simpleElement(self, element, value=None): - if value is not None: - value = _escapeAndEncode(value) - self.writeln("<%s>%s" % (element, value, element)) - else: - self.writeln("<%s/>" % element) - - def writeln(self, line): - if line: - self.file.write(self.indentLevel * self.indent + line + "\n") - else: - self.file.write("\n") - - -# Contents should conform to a subset of ISO 8601 -# (in particular, YYYY '-' MM '-' DD 'T' HH ':' MM ':' SS 'Z'. Smaller units may be omitted with -# a loss of precision) -_dateParser = re.compile(r"(?P\d\d\d\d)(?:-(?P\d\d)(?:-(?P\d\d)(?:T(?P\d\d)(?::(?P\d\d)(?::(?P\d\d))?)?)?)?)?Z") - -def _dateFromString(s): - order = ('year', 'month', 'day', 'hour', 'minute', 'second') - gd = _dateParser.match(s).groupdict() - lst = [] - for key in order: - val = gd[key] - if val is None: - break - lst.append(int(val)) - return datetime.datetime(*lst) - -def _dateToString(d): - return '%04d-%02d-%02dT%02d:%02d:%02dZ' % ( - d.year, d.month, d.day, - d.hour, d.minute, d.second - ) - - -# Regex to find any control chars, except for \t \n and \r -_controlCharPat = re.compile( - r"[\x00\x01\x02\x03\x04\x05\x06\x07\x08\x0b\x0c\x0e\x0f" - r"\x10\x11\x12\x13\x14\x15\x16\x17\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f]") - -def _escapeAndEncode(text): - m = _controlCharPat.search(text) - if m is not None: - raise ValueError("strings can't contains control characters; " - "use plistlib.Data instead") - text = text.replace("\r\n", "\n") # convert DOS line endings - text = text.replace("\r", "\n") # convert Mac line endings - text = text.replace("&", "&") # escape '&' - text = text.replace("<", "<") # escape '<' - text = text.replace(">", ">") # escape '>' - return text.encode("utf-8") # encode as UTF-8 - - -PLISTHEADER = """\ - - -""" - -class PlistWriter(DumbXMLWriter): - - def __init__(self, file, indentLevel=0, indent="\t", writeHeader=1): - if writeHeader: - file.write(PLISTHEADER) - DumbXMLWriter.__init__(self, file, indentLevel, indent) - - def writeValue(self, value): - if isinstance(value, (str, unicode)): - self.simpleElement("string", value) - elif isinstance(value, bool): - # must switch for bool before int, as bool is a - # subclass of int... - if value: - self.simpleElement("true") - else: - self.simpleElement("false") - elif isinstance(value, (int, long)): - self.simpleElement("integer", "%d" % value) - elif isinstance(value, float): - self.simpleElement("real", repr(value)) - elif isinstance(value, dict): - self.writeDict(value) - elif isinstance(value, Data): - self.writeData(value) - elif isinstance(value, datetime.datetime): - self.simpleElement("date", _dateToString(value)) - elif isinstance(value, (tuple, list)): - self.writeArray(value) - else: - raise TypeError("unsuported type: %s" % type(value)) - - def writeData(self, data): - self.beginElement("data") - self.indentLevel -= 1 - maxlinelength = 76 - len(self.indent.replace("\t", " " * 8) * - self.indentLevel) - for line in data.asBase64(maxlinelength).split("\n"): - if line: - self.writeln(line) - self.indentLevel += 1 - self.endElement("data") - - def writeDict(self, d): - self.beginElement("dict") - items = d.items() - items.sort() - for key, value in items: - if not isinstance(key, (str, unicode)): - raise TypeError("keys must be strings") - self.simpleElement("key", key) - self.writeValue(value) - self.endElement("dict") - - def writeArray(self, array): - self.beginElement("array") - for value in array: - self.writeValue(value) - self.endElement("array") - - -class _InternalDict(dict): - - # This class is needed while Dict is scheduled for deprecation: - # we only need to warn when a *user* instantiates Dict or when - # the "attribute notation for dict keys" is used. - - def __getattr__(self, attr): - try: - value = self[attr] - except KeyError: - raise AttributeError, attr - from warnings import warn - warn("Attribute access from plist dicts is deprecated, use d[key] " - "notation instead", PendingDeprecationWarning) - return value - - def __setattr__(self, attr, value): - from warnings import warn - warn("Attribute access from plist dicts is deprecated, use d[key] " - "notation instead", PendingDeprecationWarning) - self[attr] = value - - def __delattr__(self, attr): - try: - del self[attr] - except KeyError: - raise AttributeError, attr - from warnings import warn - warn("Attribute access from plist dicts is deprecated, use d[key] " - "notation instead", PendingDeprecationWarning) - -class Dict(_InternalDict): - - def __init__(self, **kwargs): - from warnings import warn - warn("The plistlib.Dict class is deprecated, use builtin dict instead", - PendingDeprecationWarning) - super(Dict, self).__init__(**kwargs) - - -class Plist(_InternalDict): - - """This class has been deprecated. Use readPlist() and writePlist() - functions instead, together with regular dict objects. - """ - - def __init__(self, **kwargs): - from warnings import warn - warn("The Plist class is deprecated, use the readPlist() and " - "writePlist() functions instead", PendingDeprecationWarning) - super(Plist, self).__init__(**kwargs) - - def fromFile(cls, pathOrFile): - """Deprecated. Use the readPlist() function instead.""" - rootObject = readPlist(pathOrFile) - plist = cls() - plist.update(rootObject) - return plist - fromFile = classmethod(fromFile) - - def write(self, pathOrFile): - """Deprecated. Use the writePlist() function instead.""" - writePlist(self, pathOrFile) - - -def _encodeBase64(s, maxlinelength=76): - # copied from base64.encodestring(), with added maxlinelength argument - maxbinsize = (maxlinelength//4)*3 - pieces = [] - for i in range(0, len(s), maxbinsize): - chunk = s[i : i + maxbinsize] - pieces.append(binascii.b2a_base64(chunk)) - return "".join(pieces) - -class Data: - - """Wrapper for binary data.""" - - def __init__(self, data): - self.data = data - - def fromBase64(cls, data): - # base64.decodestring just calls binascii.a2b_base64; - # it seems overkill to use both base64 and binascii. - return cls(binascii.a2b_base64(data)) - fromBase64 = classmethod(fromBase64) - - def asBase64(self, maxlinelength=76): - return _encodeBase64(self.data, maxlinelength) - - def __cmp__(self, other): - if isinstance(other, self.__class__): - return cmp(self.data, other.data) - elif isinstance(other, str): - return cmp(self.data, other) - else: - return cmp(id(self), id(other)) - - def __repr__(self): - return "%s(%s)" % (self.__class__.__name__, repr(self.data)) - - -class PlistParser: - - def __init__(self): - self.stack = [] - self.currentKey = None - self.root = None - - def parse(self, fileobj): - from xml.parsers.expat import ParserCreate - parser = ParserCreate() - parser.StartElementHandler = self.handleBeginElement - parser.EndElementHandler = self.handleEndElement - parser.CharacterDataHandler = self.handleData - parser.ParseFile(fileobj) - return self.root - - def handleBeginElement(self, element, attrs): - self.data = [] - handler = getattr(self, "begin_" + element, None) - if handler is not None: - handler(attrs) - - def handleEndElement(self, element): - handler = getattr(self, "end_" + element, None) - if handler is not None: - handler() - - def handleData(self, data): - self.data.append(data) - - def addObject(self, value): - if self.currentKey is not None: - self.stack[-1][self.currentKey] = value - self.currentKey = None - elif not self.stack: - # this is the root object - self.root = value - else: - self.stack[-1].append(value) - - def getData(self): - data = "".join(self.data) - try: - data = data.encode("ascii") - except UnicodeError: - pass - self.data = [] - return data - - # element handlers - - def begin_dict(self, attrs): - d = _InternalDict() - self.addObject(d) - self.stack.append(d) - def end_dict(self): - self.stack.pop() - - def end_key(self): - self.currentKey = self.getData() - - def begin_array(self, attrs): - a = [] - self.addObject(a) - self.stack.append(a) - def end_array(self): - self.stack.pop() - - def end_true(self): - self.addObject(True) - def end_false(self): - self.addObject(False) - def end_integer(self): - self.addObject(int(self.getData())) - def end_real(self): - self.addObject(float(self.getData())) - def end_string(self): - self.addObject(self.getData()) - def end_data(self): - self.addObject(Data.fromBase64(self.getData())) - def end_date(self): - self.addObject(_dateFromString(self.getData())) Copied: python/trunk/Lib/plistlib.py (from r60148, python/trunk/Lib/plat-mac/plistlib.py) ============================================================================== --- python/trunk/Lib/plat-mac/plistlib.py (original) +++ python/trunk/Lib/plistlib.py Mon Jan 21 17:34:07 2008 @@ -1,6 +1,6 @@ """plistlib.py -- a tool to generate and parse MacOSX .plist files. -The PropertList (.plist) file format is a simple XML pickle supporting +The PropertyList (.plist) file format is a simple XML pickle supporting basic object types, like dictionaries, lists, numbers and strings. Usually the top level object is a dictionary. Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Mon Jan 21 17:34:07 2008 @@ -369,6 +369,8 @@ Library ------- +- #1555501: move plistlib from plat-mac directory to general library. + - #1269: fix a bug in pstats.add_callers() and add a unit test file for pstats. From python-checkins at python.org Mon Jan 21 17:36:00 2008 From: python-checkins at python.org (georg.brandl) Date: Mon, 21 Jan 2008 17:36:00 +0100 (CET) Subject: [Python-checkins] r60156 - python/trunk/Doc/library/bundlebuilder.rst python/trunk/Doc/library/mac.rst Message-ID: <20080121163600.A9DF51E4019@bag.python.org> Author: georg.brandl Date: Mon Jan 21 17:36:00 2008 New Revision: 60156 Added: python/trunk/Doc/library/bundlebuilder.rst Modified: python/trunk/Doc/library/mac.rst Log: Add a stub for bundlebuilder documentation. Added: python/trunk/Doc/library/bundlebuilder.rst ============================================================================== --- (empty file) +++ python/trunk/Doc/library/bundlebuilder.rst Mon Jan 21 17:36:00 2008 @@ -0,0 +1,28 @@ +:mod:`bundlebuilder` --- Assemble MacOS X (application) bundles +=============================================================== + +.. module:: bundlebuilder + :synopsis: Tools to assemble MacOS X (application) bundles. + :platform: Mac +.. moduleauthor:: Just van Rossum + +.. index:: + pair: creating; application bundles + +This module contains two classes to build so called "bundles" for MacOS X. +:class:`BundleBuilder` is a general tool, :class:`AppBuilder` is a subclass +specialized in building application bundles. + +These Builder objects are instantiated with a bunch of keyword arguments, and +have a :meth:`build` method that will do all the work. + +The module also contains a main program that can be used in two ways:: + + % python bundlebuilder.py [options] build + % python buildapp.py [options] build + +where :file:`buildapp.py` is a user-supplied setup.py-like script following this +model:: + + from bundlebuilder import buildapp + buildapp() Modified: python/trunk/Doc/library/mac.rst ============================================================================== --- python/trunk/Doc/library/mac.rst (original) +++ python/trunk/Doc/library/mac.rst Mon Jan 21 17:36:00 2008 @@ -21,3 +21,4 @@ autogil.rst carbon.rst colorpicker.rst + bundlebuilder.rst From python-checkins at python.org Mon Jan 21 17:46:58 2008 From: python-checkins at python.org (georg.brandl) Date: Mon, 21 Jan 2008 17:46:58 +0100 (CET) Subject: [Python-checkins] r60157 - python/trunk/Doc/library/bundlebuilder.rst python/trunk/Doc/library/mac.rst Message-ID: <20080121164658.B6B5A1E4019@bag.python.org> Author: georg.brandl Date: Mon Jan 21 17:46:58 2008 New Revision: 60157 Removed: python/trunk/Doc/library/bundlebuilder.rst Modified: python/trunk/Doc/library/mac.rst Log: Removing bundlebuilder docs again -- it's not to be used anymore (see #779825). Deleted: /python/trunk/Doc/library/bundlebuilder.rst ============================================================================== --- /python/trunk/Doc/library/bundlebuilder.rst Mon Jan 21 17:46:58 2008 +++ (empty file) @@ -1,28 +0,0 @@ -:mod:`bundlebuilder` --- Assemble MacOS X (application) bundles -=============================================================== - -.. module:: bundlebuilder - :synopsis: Tools to assemble MacOS X (application) bundles. - :platform: Mac -.. moduleauthor:: Just van Rossum - -.. index:: - pair: creating; application bundles - -This module contains two classes to build so called "bundles" for MacOS X. -:class:`BundleBuilder` is a general tool, :class:`AppBuilder` is a subclass -specialized in building application bundles. - -These Builder objects are instantiated with a bunch of keyword arguments, and -have a :meth:`build` method that will do all the work. - -The module also contains a main program that can be used in two ways:: - - % python bundlebuilder.py [options] build - % python buildapp.py [options] build - -where :file:`buildapp.py` is a user-supplied setup.py-like script following this -model:: - - from bundlebuilder import buildapp - buildapp() Modified: python/trunk/Doc/library/mac.rst ============================================================================== --- python/trunk/Doc/library/mac.rst (original) +++ python/trunk/Doc/library/mac.rst Mon Jan 21 17:46:58 2008 @@ -21,4 +21,3 @@ autogil.rst carbon.rst colorpicker.rst - bundlebuilder.rst From python-checkins at python.org Mon Jan 21 17:51:51 2008 From: python-checkins at python.org (georg.brandl) Date: Mon, 21 Jan 2008 17:51:51 +0100 (CET) Subject: [Python-checkins] r60158 - python/trunk/Doc/tutorial/controlflow.rst Message-ID: <20080121165151.F075B1E4019@bag.python.org> Author: georg.brandl Date: Mon Jan 21 17:51:51 2008 New Revision: 60158 Modified: python/trunk/Doc/tutorial/controlflow.rst Log: #997912: acknowledge nested scopes in tutorial. Modified: python/trunk/Doc/tutorial/controlflow.rst ============================================================================== --- python/trunk/Doc/tutorial/controlflow.rst (original) +++ python/trunk/Doc/tutorial/controlflow.rst Mon Jan 21 17:51:51 2008 @@ -204,10 +204,11 @@ The *execution* of a function introduces a new symbol table used for the local variables of the function. More precisely, all variable assignments in a function store the value in the local symbol table; whereas variable references -first look in the local symbol table, then in the global symbol table, and then -in the table of built-in names. Thus, global variables cannot be directly -assigned a value within a function (unless named in a :keyword:`global` -statement), although they may be referenced. +first look in the local symbol table, then in the local symbol tables of +enclosing functions, then in the global symbol table, and finally in the table +of built-in names. Thus, global variables cannot be directly assigned a value +within a function (unless named in a :keyword:`global` statement), although they +may be referenced. The actual parameters (arguments) to a function call are introduced in the local symbol table of the called function when it is called; thus, arguments are From python-checkins at python.org Mon Jan 21 18:02:26 2008 From: python-checkins at python.org (vinay.sajip) Date: Mon, 21 Jan 2008 18:02:26 +0100 (CET) Subject: [Python-checkins] r60159 - python/trunk/Lib/logging/handlers.py Message-ID: <20080121170226.C11031E4019@bag.python.org> Author: vinay.sajip Date: Mon Jan 21 18:02:26 2008 New Revision: 60159 Modified: python/trunk/Lib/logging/handlers.py Log: Fix: #1836: Off-by-one bug in TimedRotatingFileHandler rollover calculation. Patch thanks to Kathryn M. Kowalski. Modified: python/trunk/Lib/logging/handlers.py ============================================================================== --- python/trunk/Lib/logging/handlers.py (original) +++ python/trunk/Lib/logging/handlers.py Mon Jan 21 18:02:26 2008 @@ -228,13 +228,16 @@ # Days to rollover is 6 - 5 + 3, or 4. In this case, it's the # number of days left in the current week (1) plus the number # of days in the next week until the rollover day (3). + # The calculations described in 2) and 3) above need to have a day added. + # This is because the above time calculation takes us to midnight on this + # day, i.e. the start of the next day. if when.startswith('W'): day = t[6] # 0 is Monday if day != self.dayOfWeek: if day < self.dayOfWeek: - daysToWait = self.dayOfWeek - day - 1 + daysToWait = self.dayOfWeek - day else: - daysToWait = 6 - day + self.dayOfWeek + daysToWait = 6 - day + self.dayOfWeek + 1 self.rolloverAt = self.rolloverAt + (daysToWait * (60 * 60 * 24)) #print "Will rollover at %d, %d seconds from now" % (self.rolloverAt, self.rolloverAt - currentTime) From python-checkins at python.org Mon Jan 21 18:03:47 2008 From: python-checkins at python.org (vinay.sajip) Date: Mon, 21 Jan 2008 18:03:47 +0100 (CET) Subject: [Python-checkins] r60160 - python/branches/release25-maint/Lib/logging/handlers.py Message-ID: <20080121170347.1124D1E4019@bag.python.org> Author: vinay.sajip Date: Mon Jan 21 18:03:46 2008 New Revision: 60160 Modified: python/branches/release25-maint/Lib/logging/handlers.py Log: Fix: #1836: Off-by-one bug in TimedRotatingFileHandler rollover calculation. Patch thanks to Kathryn M. Kowalski. Modified: python/branches/release25-maint/Lib/logging/handlers.py ============================================================================== --- python/branches/release25-maint/Lib/logging/handlers.py (original) +++ python/branches/release25-maint/Lib/logging/handlers.py Mon Jan 21 18:03:46 2008 @@ -229,13 +229,16 @@ # Days to rollover is 6 - 5 + 3, or 4. In this case, it's the # number of days left in the current week (1) plus the number # of days in the next week until the rollover day (3). + # The calculations described in 2) and 3) above need to have a day added. + # This is because the above time calculation takes us to midnight on this + # day, i.e. the start of the next day. if when.startswith('W'): day = t[6] # 0 is Monday if day != self.dayOfWeek: if day < self.dayOfWeek: - daysToWait = self.dayOfWeek - day - 1 + daysToWait = self.dayOfWeek - day else: - daysToWait = 6 - day + self.dayOfWeek + daysToWait = 6 - day + self.dayOfWeek + 1 self.rolloverAt = self.rolloverAt + (daysToWait * (60 * 60 * 24)) #print "Will rollover at %d, %d seconds from now" % (self.rolloverAt, self.rolloverAt - currentTime) From python-checkins at python.org Mon Jan 21 18:13:03 2008 From: python-checkins at python.org (georg.brandl) Date: Mon, 21 Jan 2008 18:13:03 +0100 (CET) Subject: [Python-checkins] r60161 - in python/trunk: Doc/extending/building.rst Doc/library/pydoc.rst Lib/pydoc.py Message-ID: <20080121171303.7AF2C1E4038@bag.python.org> Author: georg.brandl Date: Mon Jan 21 18:13:03 2008 New Revision: 60161 Modified: python/trunk/Doc/extending/building.rst python/trunk/Doc/library/pydoc.rst python/trunk/Lib/pydoc.py Log: Adapt pydoc to new doc URLs. Modified: python/trunk/Doc/extending/building.rst ============================================================================== --- python/trunk/Doc/extending/building.rst (original) +++ python/trunk/Doc/extending/building.rst Mon Jan 21 18:13:03 2008 @@ -80,7 +80,7 @@ description = 'This is a demo package', author = 'Martin v. Loewis', author_email = 'martin at v.loewis.de', - url = 'http://www.python.org/doc/current/ext/building.html', + url = 'http://docs.python.org/extending/building', long_description = ''' This is really just a demo package. ''', Modified: python/trunk/Doc/library/pydoc.rst ============================================================================== --- python/trunk/Doc/library/pydoc.rst (original) +++ python/trunk/Doc/library/pydoc.rst Mon Jan 21 18:13:03 2008 @@ -59,7 +59,7 @@ Python interpreter and typed ``import spam``. Module docs for core modules are assumed to reside in -http://www.python.org/doc/current/lib/. This can be overridden by setting the +http://docs.python.org/library/. This can be overridden by setting the :envvar:`PYTHONDOCS` environment variable to a different URL or to a local directory containing the Library Reference Manual pages. Modified: python/trunk/Lib/pydoc.py ============================================================================== --- python/trunk/Lib/pydoc.py (original) +++ python/trunk/Lib/pydoc.py Mon Jan 21 18:13:03 2008 @@ -27,7 +27,7 @@ Module docs for core modules are assumed to be in - http://www.python.org/doc/current/lib/ + http://docs.python.org/library/ This can be overridden by setting the PYTHONDOCS environment variable to a different URL or to a local directory containing the Library @@ -346,7 +346,7 @@ file = '(built-in)' docloc = os.environ.get("PYTHONDOCS", - "http://www.python.org/doc/current/lib") + "http://docs.python.org/library") basedir = os.path.join(sys.exec_prefix, "lib", "python"+sys.version[0:3]) if (isinstance(object, type(os)) and @@ -355,11 +355,10 @@ 'thread', 'zipimport') or (file.startswith(basedir) and not file.startswith(os.path.join(basedir, 'site-packages'))))): - htmlfile = "module-%s.html" % object.__name__ if docloc.startswith("http://"): - docloc = "%s/%s" % (docloc.rstrip("/"), htmlfile) + docloc = "%s/%s" % (docloc.rstrip("/"), object.__name__) else: - docloc = os.path.join(docloc, htmlfile) + docloc = os.path.join(docloc, object.__name__ + ".html") else: docloc = None return docloc @@ -541,7 +540,7 @@ url = 'http://www.rfc-editor.org/rfc/rfc%d.txt' % int(rfc) results.append('%s' % (url, escape(all))) elif pep: - url = 'http://www.python.org/peps/pep-%04d.html' % int(pep) + url = 'http://www.python.org/peps/pep-%04d' % int(pep) results.append('%s' % (url, escape(all))) elif text[end:end+1] == '(': results.append(self.namelink(name, methods, funcs, classes)) @@ -1710,7 +1709,7 @@ Welcome to Python %s! This is the online help utility. If this is your first time using Python, you should definitely check out -the tutorial on the Internet at http://www.python.org/doc/tut/. +the tutorial on the Internet at http://docs.python.org/tutorial/. Enter the name of any module, keyword, or topic to get help on writing Python programs and using Python modules. To quit this help utility and From python-checkins at python.org Mon Jan 21 18:17:00 2008 From: python-checkins at python.org (georg.brandl) Date: Mon, 21 Jan 2008 18:17:00 +0100 (CET) Subject: [Python-checkins] r60162 - python/trunk/Doc/howto/regex.rst Message-ID: <20080121171700.C594D1E4019@bag.python.org> Author: georg.brandl Date: Mon Jan 21 18:17:00 2008 New Revision: 60162 Modified: python/trunk/Doc/howto/regex.rst Log: Fix old link. Modified: python/trunk/Doc/howto/regex.rst ============================================================================== --- python/trunk/Doc/howto/regex.rst (original) +++ python/trunk/Doc/howto/regex.rst Mon Jan 21 18:17:00 2008 @@ -335,9 +335,8 @@ Once you have an object representing a compiled regular expression, what do you do with it? :class:`RegexObject` instances have several methods and attributes. -Only the most significant ones will be covered here; consult `the Library -Reference `_ for a complete -listing. +Only the most significant ones will be covered here; consult the :mod:`re` docs +for a complete listing. +------------------+-----------------------------------------------+ | Method/Attribute | Purpose | From python-checkins at python.org Mon Jan 21 18:22:07 2008 From: python-checkins at python.org (georg.brandl) Date: Mon, 21 Jan 2008 18:22:07 +0100 (CET) Subject: [Python-checkins] r60163 - in python/trunk: Lib/formatter.py Lib/keyword.py Lib/urlparse.py Tools/pynche/ColorDB.py Message-ID: <20080121172207.4D8761E4019@bag.python.org> Author: georg.brandl Date: Mon Jan 21 18:22:06 2008 New Revision: 60163 Modified: python/trunk/Lib/formatter.py python/trunk/Lib/keyword.py python/trunk/Lib/urlparse.py python/trunk/Tools/pynche/ColorDB.py Log: #1726198: replace while 1: fp.readline() with file iteration. Modified: python/trunk/Lib/formatter.py ============================================================================== --- python/trunk/Lib/formatter.py (original) +++ python/trunk/Lib/formatter.py Mon Jan 21 18:22:06 2008 @@ -432,10 +432,7 @@ fp = open(sys.argv[1]) else: fp = sys.stdin - while 1: - line = fp.readline() - if not line: - break + for line in fp: if line == '\n': f.end_paragraph(1) else: Modified: python/trunk/Lib/keyword.py ============================================================================== --- python/trunk/Lib/keyword.py (original) +++ python/trunk/Lib/keyword.py Mon Jan 21 18:22:06 2008 @@ -62,9 +62,7 @@ fp = open(iptfile) strprog = re.compile('"([^"]+)"') lines = [] - while 1: - line = fp.readline() - if not line: break + for line in fp: if '{1, "' in line: match = strprog.search(line) if match: Modified: python/trunk/Lib/urlparse.py ============================================================================== --- python/trunk/Lib/urlparse.py (original) +++ python/trunk/Lib/urlparse.py Mon Jan 21 18:22:06 2008 @@ -306,9 +306,7 @@ except ImportError: from StringIO import StringIO fp = StringIO(test_input) - while 1: - line = fp.readline() - if not line: break + for line in fp: words = line.split() if not words: continue Modified: python/trunk/Tools/pynche/ColorDB.py ============================================================================== --- python/trunk/Tools/pynche/ColorDB.py (original) +++ python/trunk/Tools/pynche/ColorDB.py Mon Jan 21 18:22:06 2008 @@ -50,10 +50,7 @@ self.__byname = {} # all unique names (non-aliases). built-on demand self.__allnames = None - while 1: - line = fp.readline() - if not line: - break + for line in fp: # get this compiled regular expression from derived class mo = self._re.match(line) if not mo: From python-checkins at python.org Mon Jan 21 18:29:23 2008 From: python-checkins at python.org (georg.brandl) Date: Mon, 21 Jan 2008 18:29:23 +0100 (CET) Subject: [Python-checkins] r60164 - python/trunk/Lib/re.py Message-ID: <20080121172923.D37D31E4019@bag.python.org> Author: georg.brandl Date: Mon Jan 21 18:29:23 2008 New Revision: 60164 Modified: python/trunk/Lib/re.py Log: Clarify $ behavior in re docstring. #1631394. Modified: python/trunk/Lib/re.py ============================================================================== --- python/trunk/Lib/re.py (original) +++ python/trunk/Lib/re.py Mon Jan 21 18:29:23 2008 @@ -29,7 +29,8 @@ The special characters are: "." Matches any character except a newline. "^" Matches the start of the string. - "$" Matches the end of the string. + "$" Matches the end of the string or just before the newline at + the end of the string. "*" Matches 0 or more (greedy) repetitions of the preceding RE. Greedy means that it will match as many repetitions as possible. "+" Matches 1 or more (greedy) repetitions of the preceding RE. @@ -83,8 +84,10 @@ Some of the functions in this module takes flags as optional parameters: I IGNORECASE Perform case-insensitive matching. L LOCALE Make \w, \W, \b, \B, dependent on the current locale. - M MULTILINE "^" matches the beginning of lines as well as the string. - "$" matches the end of lines as well as the string. + M MULTILINE "^" matches the beginning of lines (after a newline) + as well as the string. + "$" matches the end of lines (before a newline) as well + as the end of the string. S DOTALL "." matches any character at all, including the newline. X VERBOSE Ignore whitespace and comments for nicer looking RE's. U UNICODE Make \w, \W, \b, \B, dependent on the Unicode locale. From python-checkins at python.org Mon Jan 21 18:39:22 2008 From: python-checkins at python.org (vinay.sajip) Date: Mon, 21 Jan 2008 18:39:22 +0100 (CET) Subject: [Python-checkins] r60165 - python/trunk/Doc/library/logging.rst Message-ID: <20080121173922.DB6C31E4027@bag.python.org> Author: vinay.sajip Date: Mon Jan 21 18:39:22 2008 New Revision: 60165 Modified: python/trunk/Doc/library/logging.rst Log: Minor documentation change - hyperlink tidied up. Modified: python/trunk/Doc/library/logging.rst ============================================================================== --- python/trunk/Doc/library/logging.rst (original) +++ python/trunk/Doc/library/logging.rst Mon Jan 21 18:39:22 2008 @@ -1199,13 +1199,13 @@ "dict-like" object for use in the constructor:: import logging - + class ConnInfo: """ An example class which shows how an arbitrary class can be used as the 'extra' context information repository passed to a LoggerAdapter. """ - + def __getitem__(self, name): """ To allow this instance to look like a dict. @@ -1218,7 +1218,7 @@ else: result = self.__dict__.get(name, "?") return result - + def __iter__(self): """ To allow iteration over keys, which will be merged into @@ -1227,7 +1227,7 @@ keys = ["ip", "user"] keys.extend(self.__dict__.keys()) return keys.__iter__() - + if __name__ == "__main__": from random import choice levels = (logging.DEBUG, logging.INFO, logging.WARNING, logging.ERROR, logging.CRITICAL) @@ -2163,7 +2163,10 @@ .. versionadded:: 2.6 :class:`LoggerAdapter` instances are used to conveniently pass contextual -information into logging calls. For a usage example , see context-info_. +information into logging calls. For a usage example , see the section on +`adding contextual information to your logging output`__. + +__ context-info_ .. class:: LoggerAdapter(logger, extra) From python-checkins at python.org Mon Jan 21 18:42:41 2008 From: python-checkins at python.org (georg.brandl) Date: Mon, 21 Jan 2008 18:42:41 +0100 (CET) Subject: [Python-checkins] r60166 - in python/trunk: Lib/distutils/command/build.py Misc/NEWS Message-ID: <20080121174241.071051E401C@bag.python.org> Author: georg.brandl Date: Mon Jan 21 18:42:40 2008 New Revision: 60166 Modified: python/trunk/Lib/distutils/command/build.py python/trunk/Misc/NEWS Log: #1530959: change distutils build dir for --with-pydebug python builds. Modified: python/trunk/Lib/distutils/command/build.py ============================================================================== --- python/trunk/Lib/distutils/command/build.py (original) +++ python/trunk/Lib/distutils/command/build.py Mon Jan 21 18:42:40 2008 @@ -69,6 +69,12 @@ plat_specifier = ".%s-%s" % (get_platform(), sys.version[0:3]) + # Make it so Python 2.x and Python 2.x with --with-pydebug don't + # share the same build directories. Doing so confuses the build + # process for C modules + if hasattr(sys, 'gettotalrefcount'): + plat_specifier += '-pydebug' + # 'build_purelib' and 'build_platlib' just default to 'lib' and # 'lib.' under the base build directory. We only use one of # them for a given distribution, though -- Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Mon Jan 21 18:42:40 2008 @@ -369,6 +369,10 @@ Library ------- +- Bug #1530959: distutils' build command now uses different build directory + when building extension modules against versions of Python compiled + with ``--with-pydebug``. + - #1555501: move plistlib from plat-mac directory to general library. - #1269: fix a bug in pstats.add_callers() and add a unit test file for From buildbot at python.org Mon Jan 21 19:11:10 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 21 Jan 2008 18:11:10 +0000 Subject: [Python-checkins] buildbot failure in alpha Tru64 5.1 2.5 Message-ID: <20080121181110.A57E21E4019@bag.python.org> The Buildbot has detected a new failure of alpha Tru64 5.1 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/alpha%20Tru64%205.1%202.5/builds/405 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-tru64 Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: vinay.sajip BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_socket ====================================================================== FAIL: testInterruptedTimeout (test.test_socket.TCPTimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/net/taipan/scratch1/nnorwitz/python/2.5.norwitz-tru64/build/Lib/test/test_socket.py", line 879, in testInterruptedTimeout self.fail("got Alarm in wrong place") AssertionError: got Alarm in wrong place sincerely, -The Buildbot From python-checkins at python.org Mon Jan 21 19:16:05 2008 From: python-checkins at python.org (vinay.sajip) Date: Mon, 21 Jan 2008 19:16:05 +0100 (CET) Subject: [Python-checkins] r60167 - python/trunk/Misc/NEWS Message-ID: <20080121181605.EFCD71E402E@bag.python.org> Author: vinay.sajip Date: Mon Jan 21 19:16:05 2008 New Revision: 60167 Modified: python/trunk/Misc/NEWS Log: Updated to include news on recent logging fixes and documentation changes. Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Mon Jan 21 19:16:05 2008 @@ -21,7 +21,7 @@ object was converted from a dict to a specialized structseq object. - Patch #1816: Added sys.flags structseq. It exposes the status of most - command line arguments and PYTHON* environment variables. + command line arguments and PYTHON* environment variables. - Object/structseq.c: Implemented new structseq representation. The patch makes structseqs (e.g. the return value of os.stat) more readable. @@ -88,7 +88,7 @@ - Expose the Py_Py3kWarningFlag as sys.py3kwarning. -- Issue #1445: Fix a SystemError when accessing the ``cell_contents`` +- Issue #1445: Fix a SystemError when accessing the ``cell_contents`` attribute of an empty cell object. - Issue #1460: The utf-7 incremental decoder did not accept truncated input. @@ -369,6 +369,17 @@ Library ------- +- #1836: fix an off-by-one bug in TimedRotatingHandler's rollover + time calculation. + +- #1021: fix a bug to allow basicConfig to accept NOTSET as a level. + +- #932563: add LoggerAdapter convenience class to make it easier to add + contextual information in logging output. + +- #1760556: fix a bug to avoid FileHandler throwing an exception in + flush(). + - Bug #1530959: distutils' build command now uses different build directory when building extension modules against versions of Python compiled with ``--with-pydebug``. @@ -415,7 +426,7 @@ - #1837: The queue module now also supports a LIFO queue and a priority queue. - Patch #1048820: Add insert-mode editing to curses.textpad.Textbox - (patch by Stefan Wehr). Also, fix an off-by-one bug in + (patch by Stefan Wehr). Also, fix an off-by-one bug in Textbox.gather(). - Issue #1831: ctypes now raises a TypeError if conflicting positional @@ -439,13 +450,13 @@ - Decimal.as_tuple(), difflib.find_longest_match() and inspect functions that returned a tuple now return a named tuple. -- Doctest now returns results as a named tuple for readability: +- Doctest now returns results as a named tuple for readability: (0, 7) --> TestResults(failed=0, attempted=7) - Issue #846388. re.match is interruptible now, which is particularly good for long regular expression matches. -- pyexpat, patch #1137: allow setting buffer_size attribute +- pyexpat, patch #1137: allow setting buffer_size attribute on Parser objects to set the character data buffer size. - Issue #1757: The hash of a Decimal instance is no longer affected by @@ -572,7 +583,7 @@ - Bug #1734723: Fix repr.Repr() so it doesn't ignore the maxtuple attribute. -- The urlopen function of urllib2 now has an optional timeout parameter (note +- The urlopen function of urllib2 now has an optional timeout parameter (note that it actually works with HTTP, HTTPS, FTP and FTPS connections). - In ftplib, the FTP.ntransfercmd method, when in passive mode, now uses @@ -760,8 +771,8 @@ - Patch #1481079: add support for HTTP_REFERER to CGIHTTPServer. -- Patch #1675424: Added tests for uncovered code in the zipfile module. - The KeyError raised by Zipfile.getinfo for nonexistent names now has +- Patch #1675424: Added tests for uncovered code in the zipfile module. + The KeyError raised by Zipfile.getinfo for nonexistent names now has a descriptive message. - Bug #1115886: os.path.splitext('.cshrc') gives now ('.cshrc', ''). @@ -1041,7 +1052,7 @@ - The implementation of UnicodeError objects has been simplified (start and end attributes are now stored directly as Py_ssize_t members). -- Issue829951: In the smtplib module, SMTP.starttls() now complies with +- Issue829951: In the smtplib module, SMTP.starttls() now complies with RFC 3207 and forgets any knowledge obtained from the server not obtained from the TLS negotiation itself. Patch contributed by Bill Fenner. @@ -1054,7 +1065,7 @@ Extension Modules ----------------- -- #1087741: mmap.mmap is now a class, not a factory function. It is also +- #1087741: mmap.mmap is now a class, not a factory function. It is also subclassable now. - Patch #1648: added ``sys.getprofile()`` and ``sys.gettrace()``. @@ -1160,7 +1171,7 @@ - Patch #1544279: Improve thread-safety of the socket module by moving the sock_addr_t storage out of the socket object. -- Patch #1019808: fix bug that causes an incorrect error to be returned +- Patch #1019808: fix bug that causes an incorrect error to be returned when a socket timeout is set and a connection attempt fails. - Speed up function calls into the math module. @@ -1193,7 +1204,7 @@ - Bug #1548092: fix curses.tparm seg fault on invalid input. - Patch #1114: fix curses module compilation on 64-bit AIX, & possibly - other 64-bit LP64 platforms where attr_t is not the same size as a long. + other 64-bit LP64 platforms where attr_t is not the same size as a long. (Contributed by Luke Mewburn.) - Bug #1550714: fix SystemError from itertools.tee on negative value for n. @@ -1283,6 +1294,12 @@ Documentation ------------- +- Bug #932563: Added section on getting contextual information into logging + output, and added documentation for the new LoggerAdapter class. + +- Bug #1295: Added information about caching of formatted exception + information in the LogRecord by Formatter.format(). + - Bug #1637365: add subsection about "__name__ == __main__" to the Python tutorial. @@ -1339,7 +1356,7 @@ - Issue #1726: Remove Python/atof.c from PCBuild/pythoncore.vcproj - Removed PCbuild8/ directory and added a new build directory for VS 2005 - based on the VS 2008 build directory to PC/VS8.0. The script + based on the VS 2008 build directory to PC/VS8.0. The script PCbuild/vs8to9.py was added to sync changes from PCbuild to PC/VS8.0. - Moved PCbuild/ directory for VS 2003 to PC/VS7.1 and renamed PCBuild9/ @@ -1666,7 +1683,7 @@ ------- - Fix #1693149. Now you can pass several modules separated by - comma to trace.py in the same --ignore-module option. + comma to trace.py in the same --ignore-module option. - Correction of patch #1455898: In the mbcs decoder, set final=False for stream decoder, but final=True for the decode function. From python-checkins at python.org Mon Jan 21 19:35:49 2008 From: python-checkins at python.org (georg.brandl) Date: Mon, 21 Jan 2008 19:35:49 +0100 (CET) Subject: [Python-checkins] r60168 - in python/trunk: Lib/test/test_pep263.py Parser/tokenizer.c Message-ID: <20080121183549.EA23C1E4019@bag.python.org> Author: georg.brandl Date: Mon Jan 21 19:35:49 2008 New Revision: 60168 Modified: python/trunk/Lib/test/test_pep263.py python/trunk/Parser/tokenizer.c Log: Issue #1882: when compiling code from a string, encoding cookies in the second line of code were not always recognized correctly. Modified: python/trunk/Lib/test/test_pep263.py ============================================================================== Binary files. No diff available. Modified: python/trunk/Parser/tokenizer.c ============================================================================== --- python/trunk/Parser/tokenizer.c (original) +++ python/trunk/Parser/tokenizer.c Mon Jan 21 19:35:49 2008 @@ -586,6 +586,7 @@ { PyObject* utf8 = NULL; const char *s; + char *newl[2] = {NULL, NULL}; int lineno = 0; tok->enc = NULL; tok->str = str; @@ -604,13 +605,23 @@ for (s = str;; s++) { if (*s == '\0') break; else if (*s == '\n') { + newl[lineno] = s; lineno++; if (lineno == 2) break; } } tok->enc = NULL; - if (!check_coding_spec(str, s - str, tok, buf_setreadl)) - return error_ret(tok); + /* need to check line 1 and 2 separately since check_coding_spec + assumes a single line as input */ + if (newl[0]) { + if (!check_coding_spec(str, newl[0] - str, tok, buf_setreadl)) + return error_ret(tok); + if (tok->enc == NULL && newl[1]) { + if (!check_coding_spec(newl[0]+1, newl[1] - newl[0], + tok, buf_setreadl)) + return error_ret(tok); + } + } #ifdef Py_USING_UNICODE if (tok->enc != NULL) { assert(utf8 == NULL); From python-checkins at python.org Mon Jan 21 19:35:52 2008 From: python-checkins at python.org (georg.brandl) Date: Mon, 21 Jan 2008 19:35:52 +0100 (CET) Subject: [Python-checkins] r60169 - in python/branches/release25-maint: Lib/test/test_pep263.py Parser/tokenizer.c Message-ID: <20080121183552.86B921E4019@bag.python.org> Author: georg.brandl Date: Mon Jan 21 19:35:52 2008 New Revision: 60169 Modified: python/branches/release25-maint/Lib/test/test_pep263.py python/branches/release25-maint/Parser/tokenizer.c Log: Issue #1882: when compiling code from a string, encoding cookies in the second line of code were not always recognized correctly. (backport from rev. 60168) Modified: python/branches/release25-maint/Lib/test/test_pep263.py ============================================================================== Binary files. No diff available. Modified: python/branches/release25-maint/Parser/tokenizer.c ============================================================================== --- python/branches/release25-maint/Parser/tokenizer.c (original) +++ python/branches/release25-maint/Parser/tokenizer.c Mon Jan 21 19:35:52 2008 @@ -585,6 +585,7 @@ { PyObject* utf8 = NULL; const char *s; + char *newl[2] = {NULL, NULL}; int lineno = 0; tok->enc = NULL; tok->str = str; @@ -603,13 +604,23 @@ for (s = str;; s++) { if (*s == '\0') break; else if (*s == '\n') { + newl[lineno] = s; lineno++; if (lineno == 2) break; } } tok->enc = NULL; - if (!check_coding_spec(str, s - str, tok, buf_setreadl)) - return error_ret(tok); + /* need to check line 1 and 2 separately since check_coding_spec + assumes a single line as input */ + if (newl[0]) { + if (!check_coding_spec(str, newl[0] - str, tok, buf_setreadl)) + return error_ret(tok); + if (tok->enc == NULL && newl[1]) { + if (!check_coding_spec(newl[0]+1, newl[1] - newl[0], + tok, buf_setreadl)) + return error_ret(tok); + } + } #ifdef Py_USING_UNICODE if (tok->enc != NULL) { assert(utf8 == NULL); From python-checkins at python.org Mon Jan 21 19:36:51 2008 From: python-checkins at python.org (georg.brandl) Date: Mon, 21 Jan 2008 19:36:51 +0100 (CET) Subject: [Python-checkins] r60170 - python/trunk/Misc/NEWS Message-ID: <20080121183651.BA8E41E4019@bag.python.org> Author: georg.brandl Date: Mon Jan 21 19:36:51 2008 New Revision: 60170 Modified: python/trunk/Misc/NEWS Log: Add NEWS entry for #1882. Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Mon Jan 21 19:36:51 2008 @@ -12,6 +12,9 @@ Core and builtins ----------------- +- Issue #1882: when compiling code from a string, encoding cookies in the + second line of code were not always recognized correctly. + - Issue #1679: "0x" was taken as a valid integer literal. - Issue #1865: Bytes as an alias for str and b"" as an alias "" were From python-checkins at python.org Mon Jan 21 19:36:54 2008 From: python-checkins at python.org (georg.brandl) Date: Mon, 21 Jan 2008 19:36:54 +0100 (CET) Subject: [Python-checkins] r60171 - python/branches/release25-maint/Misc/NEWS Message-ID: <20080121183654.8F0691E402A@bag.python.org> Author: georg.brandl Date: Mon Jan 21 19:36:54 2008 New Revision: 60171 Modified: python/branches/release25-maint/Misc/NEWS Log: Add NEWS entry for #1882. (backport from rev. 60170) Modified: python/branches/release25-maint/Misc/NEWS ============================================================================== --- python/branches/release25-maint/Misc/NEWS (original) +++ python/branches/release25-maint/Misc/NEWS Mon Jan 21 19:36:54 2008 @@ -12,6 +12,9 @@ Core and builtins ----------------- +- Issue #1882: when compiling code from a string, encoding cookies in the + second line of code were not always recognized correctly. + - Bug #1517: Possible segfault in lookup(). - Issue #1638: %zd configure test fails on Linux. From python-checkins at python.org Mon Jan 21 19:41:24 2008 From: python-checkins at python.org (georg.brandl) Date: Mon, 21 Jan 2008 19:41:24 +0100 (CET) Subject: [Python-checkins] r60172 - python/trunk/Doc/bugs.rst Message-ID: <20080121184124.BBD291E4019@bag.python.org> Author: georg.brandl Date: Mon Jan 21 19:41:24 2008 New Revision: 60172 Modified: python/trunk/Doc/bugs.rst Log: Use original location of document, which has translations. Modified: python/trunk/Doc/bugs.rst ============================================================================== --- python/trunk/Doc/bugs.rst (original) +++ python/trunk/Doc/bugs.rst Mon Jan 21 19:41:24 2008 @@ -49,7 +49,7 @@ .. seealso:: - `How to Report Bugs Effectively `_ + `How to Report Bugs Effectively `_ Article which goes into some detail about how to create a useful bug report. This describes what kind of information is useful and why it is useful. From python-checkins at python.org Mon Jan 21 21:18:05 2008 From: python-checkins at python.org (walter.doerwald) Date: Mon, 21 Jan 2008 21:18:05 +0100 (CET) Subject: [Python-checkins] r60173 - python/trunk/Lib/plistlib.py Message-ID: <20080121201805.2B6301E4019@bag.python.org> Author: walter.doerwald Date: Mon Jan 21 21:18:04 2008 New Revision: 60173 Modified: python/trunk/Lib/plistlib.py Log: Follow PEP 8 in module docstring. Modified: python/trunk/Lib/plistlib.py ============================================================================== --- python/trunk/Lib/plistlib.py (original) +++ python/trunk/Lib/plistlib.py Mon Jan 21 21:18:04 2008 @@ -28,17 +28,17 @@ pl = dict( aString="Doodah", aList=["A", "B", 12, 32.1, [1, 2, 3]], - aFloat = 0.1, - anInt = 728, + aFloat=0.1, + anInt=728, aDict=dict( anotherString="", aUnicodeValue=u'M\xe4ssig, Ma\xdf', aTrueValue=True, aFalseValue=False, ), - someData = Data(""), - someMoreData = Data("" * 10), - aDate = datetime.datetime.fromtimestamp(time.mktime(time.gmtime())), + someData=Data(""), + someMoreData=Data("" * 10), + aDate=datetime.datetime.fromtimestamp(time.mktime(time.gmtime())), ) # unicode keys are possible, but a little awkward to use: pl[u'\xc5benraa'] = "That was a unicode key." From python-checkins at python.org Mon Jan 21 21:20:38 2008 From: python-checkins at python.org (georg.brandl) Date: Mon, 21 Jan 2008 21:20:38 +0100 (CET) Subject: [Python-checkins] r60174 - in doctools/trunk/sphinx: __init__.py builder.py config.py directives.py environment.py extension.py htmlhelp.py htmlwriter.py latexwriter.py patchlevel.py roles.py templates/layout.html Message-ID: <20080121202038.642781E4019@bag.python.org> Author: georg.brandl Date: Mon Jan 21 21:20:37 2008 New Revision: 60174 Added: doctools/trunk/sphinx/config.py doctools/trunk/sphinx/extension.py Removed: doctools/trunk/sphinx/patchlevel.py Modified: doctools/trunk/sphinx/__init__.py doctools/trunk/sphinx/builder.py doctools/trunk/sphinx/directives.py doctools/trunk/sphinx/environment.py doctools/trunk/sphinx/htmlhelp.py doctools/trunk/sphinx/htmlwriter.py doctools/trunk/sphinx/latexwriter.py doctools/trunk/sphinx/roles.py doctools/trunk/sphinx/templates/layout.html Log: Further refactorings, add extensibility API. Modified: doctools/trunk/sphinx/__init__.py ============================================================================== --- doctools/trunk/sphinx/__init__.py (original) +++ doctools/trunk/sphinx/__init__.py Mon Jan 21 21:20:37 2008 @@ -9,15 +9,51 @@ :license: BSD. """ +import os import sys import getopt from os import path from cStringIO import StringIO +from sphinx.config import Config, ConfigError from sphinx.builder import builders +from sphinx.extension import EventManager from sphinx.util.console import nocolor -__version__ = '$Revision: 5369 $' +__version__ = '$Revision: 5369 $'[11:-2] + + +def init_builder(buildername, srcdirname, outdirname, doctreedir, + confoverrides, status, warning=sys.stderr, freshenv=False): + # read config + config = Config(srcdirname, 'conf.py') + if confoverrides: + for key, val in confoverrides.items(): + setattr(config, key, val) + + # extensibility + events = EventManager() + for extension in config.extensions: + try: + mod = __import__(extension, None, None, ['setup']) + except ImportError, err: + raise ConfigError('Could not import extension %s' % module, err) + if hasattr(mod, 'setup'): + mod.setup(events, builders) + + if buildername not in builders: + print >>warning, 'Builder name %s not registered' % buildername + return None + + if buildername is None: + print >>status, 'No builder selected, using default: html' + buildername = 'html' + + builderclass = builders[buildername] + builder = builderclass(srcdirname, outdirname, doctreedir, + status_stream=status, warning_stream=warning, + events=events, config=config, freshenv=freshenv) + events.emit('builder-created', builder) def usage(argv, msg=None): @@ -42,6 +78,10 @@ def main(argv): + if not sys.stdout.isatty() or sys.platform == 'win32': + # Windows' poor cmd box doesn't understand ANSI sequences + nocolor() + try: opts, args = getopt.getopt(argv[1:], 'ab:d:D:NEqP') srcdirname = path.abspath(args[0]) @@ -68,17 +108,14 @@ if err: return 1 - builder = all_files = None + buildername = all_files = None freshenv = use_pdb = False status = sys.stdout confoverrides = {} doctreedir = path.join(outdirname, '.doctrees') for opt, val in opts: if opt == '-b': - if val not in builders: - usage(argv, 'Invalid builder value specified.') - return 1 - builder = val + buildername = val elif opt == '-a': if filenames: usage(argv, 'Cannot combine -a option and filenames.') @@ -101,28 +138,18 @@ elif opt == '-P': use_pdb = True - if not sys.stdout.isatty() or sys.platform == 'win32': - # Windows' cmd box doesn't understand ANSI sequences - nocolor() - - if builder is None: - print >>status, 'No builder selected, using default: html' - builder = 'html' - - builderobj = builders[builder] + builder = init_builder(buildername, srcdirname, outdirname, doctreedir, + confoverrides, status, sys.stderr, freshenv) + if not builder: + return 1 try: - builderobj = builderobj(srcdirname, outdirname, doctreedir, - status_stream=status, - warning_stream=sys.stderr, - confoverrides=confoverrides, - freshenv=freshenv) if all_files: - builderobj.build_all() + builder.build_all() elif filenames: - builderobj.build_specific(filenames) + builder.build_specific(filenames) else: - builderobj.build_update() + builder.build_update() except: if not use_pdb: raise Modified: doctools/trunk/sphinx/builder.py ============================================================================== --- doctools/trunk/sphinx/builder.py (original) +++ doctools/trunk/sphinx/builder.py Mon Jan 21 21:20:37 2008 @@ -12,7 +12,6 @@ import os import sys import time -import types import codecs import shutil import cPickle as pickle @@ -31,8 +30,9 @@ from sphinx.util import (get_matching_files, attrdict, status_iterator, ensuredir, relative_uri, os_path, SEP) from sphinx.htmlhelp import build_hhx +from sphinx.extension import DummyEventManager, import_object from sphinx.patchlevel import get_version_info, get_sys_version_info -from sphinx.htmlwriter import HTMLWriter +from sphinx.htmlwriter import HTMLWriter, HTMLTranslator, SmartyPantsHTMLTranslator from sphinx.latexwriter import LaTeXWriter from sphinx.environment import BuildEnvironment, NoUri from sphinx.highlighting import pygments, highlight_block, get_stylesheet @@ -45,25 +45,13 @@ ENV_PICKLE_FILENAME = 'environment.pickle' LAST_BUILD_FILENAME = 'last_build' -# Helper objects - -class relpath_to(object): - def __init__(self, builder, filename): - self.baseuri = builder.get_target_uri(filename) - self.builder = builder - def __call__(self, otheruri, resource=False): - if not resource: - otheruri = self.builder.get_target_uri(otheruri + '.rst') - return relative_uri(self.baseuri, otheruri) - - class Builder(object): """ Builds target formats from the reST sources. """ def __init__(self, srcdirname, outdirname, doctreedirname, - confoverrides=None, env=None, freshenv=False, + config, env=None, freshenv=False, events=None, status_stream=None, warning_stream=None): self.srcdir = srcdirname self.outdir = outdirname @@ -75,35 +63,11 @@ self.status_stream = status_stream or sys.stdout self.warning_stream = warning_stream or sys.stderr - # probably set in load_env() + self.config = config + # if None, this is set in load_env() self.env = env - self.config = {} - olddir = os.getcwd() - try: - os.chdir(srcdirname) - execfile(path.join(srcdirname, 'conf.py'), self.config) - finally: - os.chdir(olddir) - # remove potentially pickling-problematic values - del self.config['__builtins__'] - for key, val in self.config.items(): - if isinstance(val, types.ModuleType): - del self.config[key] - if confoverrides: - self.config.update(confoverrides) - # replace version info if '' - if self.config['version'] == '' or self.config['release'] == '': - try: - version, release = get_version_info(srcdirname) - except (IOError, OSError): - version, release = get_sys_version_info() - self.warn('Can\'t get version info from Include/patchlevel.h, ' - 'using version of this interpreter (%s).' % release) - if self.config['version'] == '': - self.config['version'] = version - if self.config['release'] == '': - self.config['release'] = release + self.events = events or DummyEventManager() self.init() @@ -124,12 +88,34 @@ """Load necessary templates and perform initialization.""" raise NotImplementedError + def init_templates(self): + """Call if you need Jinja templates in the builder.""" + # lazily import this, maybe other builders won't need it + from sphinx._jinja import Environment, SphinxFileSystemLoader + + # load templates + self.templates = {} + templates_path = [path.join(path.dirname(__file__), 'templates')] + templates_path.extend(self.config.templates_path) + self.jinja_env = Environment(loader=SphinxFileSystemLoader(templates_path), + # disable traceback, more likely that something + # in the application is broken than in the templates + friendly_traceback=False) + + def get_template(self, name): + if name in self.templates: + return self.templates[name] + template = self.templates[name] = self.jinja_env.get_template(name) + return template + def get_target_uri(self, source_filename, typ=None): """Return the target URI for a source filename.""" raise NotImplementedError def get_relative_uri(self, from_, to, typ=None): - """Return a relative URI between two source filenames.""" + """Return a relative URI between two source filenames. + May raise environment.NoUri if there's no way to return a + sensible URI.""" return relative_uri(self.get_target_uri(from_), self.get_target_uri(to, typ)) @@ -196,7 +182,9 @@ warnings = [] self.env.set_warnfunc(warnings.append) self.msg('reading, updating environment:', nonl=1) - iterator = self.env.update(self.config) + iterator = self.env.update( + self.config, + hook=lambda doctree: self.events.emit('doctree-read', doctree)) self.msg(iterator.next(), nonl=1, nobold=1) for filename in iterator: if not updated_filenames: @@ -274,25 +262,14 @@ def init(self): """Load templates.""" - # lazily import this, maybe other builders won't need it - from sphinx._jinja import Environment, SphinxFileSystemLoader - - # load templates - self.templates = {} - templates_path = path.join(path.dirname(__file__), 'templates') - self.jinja_env = Environment(loader=SphinxFileSystemLoader([templates_path]), - # disable traceback, more likely that something - # in the application is broken than in the templates - friendly_traceback=False) - # pre-load built-in templates - for fname in os.listdir(templates_path): - if fname.endswith('.html'): - self.templates[fname] = self.jinja_env.get_template(fname) - - def get_template(self, name): - if name in self.templates: - return self.templates[name] - return self.jinja_env.get_template(name) + self.init_templates() + if self.config.html_translator_class: + self.translator_class = import_object(self.config.html_translator_class, + 'html_translator_class setting') + elif self.config.html_use_smartypants: + self.translator_class = SmartyPantsHTMLTranslator + else: + self.translator_class = HTMLTranslator def render_partial(self, node): """Utility: Render a lone doctree node.""" @@ -317,17 +294,17 @@ # format the "last updated on" string, only once is enough since it # typically doesn't include the time of day - lufmt = self.config.get('html_last_updated_fmt') + lufmt = self.config.html_last_updated_fmt if lufmt: self.last_updated = time.strftime(lufmt) else: self.last_updated = None self.globalcontext = dict( - project = self.config.get('project', 'Python'), - copyright = self.config.get('copyright', ''), - release = self.config['release'], - version = self.config['version'], + project = self.config.project, + copyright = self.config.copyright, + release = self.config.release, + version = self.config.version, last_updated = self.last_updated, builder = self.name, parents = [], @@ -336,6 +313,7 @@ ) def write_file(self, filename, doctree): + pagename = filename[:-4] destination = StringOutput(encoding='utf-8') doctree.settings = self.docsettings @@ -366,7 +344,7 @@ else: title = '' self.globalcontext['titles'][filename] = title - sourcename = filename[:-4] + '.txt' + sourcename = pagename + '.txt' context = dict( title = title, sourcename = sourcename, @@ -379,8 +357,8 @@ next = next, ) - self.index_file(filename, doctree, title) - self.handle_page(filename[:-4], context) + self.index_page(pagename, doctree, title) + self.handle_page(pagename, context) def finish(self): self.msg('writing additional files...') @@ -446,12 +424,12 @@ self.handle_page('search', {}, 'search.html') # additional pages from conf.py - for pagename, template in self.config.get('html_additional_pages', {}).items(): + for pagename, template in self.config.html_additional_pages.items(): template = path.join(self.srcdir, template) self.handle_page(pagename, {}, template) # the index page - indextemplate = self.config.get('html_index') + indextemplate = self.config.html_index if indextemplate: indextemplate = path.join(self.srcdir, indextemplate) self.handle_page('index', {'indextemplate': indextemplate}, 'index.html') @@ -480,7 +458,7 @@ def get_outdated_files(self): for filename in get_matching_files( - self.srcdir, '*.rst', exclude=set(self.config.get('unused_files', ()))): + self.srcdir, '*.rst', exclude=set(self.config.unused_files)): try: rstname = path.join(self.outdir, os_path(filename)) targetmtime = path.getmtime(rstname[:-4] + '.html') @@ -504,21 +482,26 @@ # delete all entries for files that will be rebuilt self.indexer.prune([fn[:-4] for fn in set(self.env.all_files) - set(filenames)]) - def index_file(self, filename, doctree, title): + def index_page(self, pagename, doctree, title): # only index pages with title if self.indexer is not None and title: - self.indexer.feed(self.get_target_uri(filename)[:-5], # strip '.html' - title, doctree) + self.indexer.feed(pagename, title, doctree) - def handle_page(self, pagename, context, templatename='page.html'): + def handle_page(self, pagename, addctx, templatename='page.html'): ctx = self.globalcontext.copy() ctx['current_page_name'] = pagename - ctx['pathto'] = relpath_to(self, self.get_target_uri(pagename+'.rst')) + + def pathto(otheruri, resource=False, + baseuri=self.get_target_uri(pagename+'.rst')): + if not resource: + otheruri = self.get_target_uri(otheruri+'.rst') + return relative_uri(baseuri, otheruri) + ctx['pathto'] = pathto ctx['hasdoc'] = lambda name: name+'.rst' in self.env.all_files - sidebarfile = self.config.get('html_sidebars', {}).get(pagename) + sidebarfile = self.config.html_sidebars.get(pagename) if sidebarfile: ctx['customsidebar'] = path.join(self.srcdir, sidebarfile) - ctx.update(context) + ctx.update(addctx) output = self.get_template(templatename).render(ctx) outfilename = path.join(self.outdir, os_path(pagename) + '.html') @@ -531,14 +514,14 @@ f.close() except (IOError, OSError), err: self.warn("Error writing file %s: %s" % (outfilename, err)) - if self.copysource and context.get('sourcename'): + if self.copysource and ctx.get('sourcename'): # copy the source file for the "show source" link shutil.copyfile(path.join(self.srcdir, os_path(pagename+'.rst')), - path.join(self.outdir, os_path(context['sourcename']))) + path.join(self.outdir, os_path(ctx['sourcename']))) def handle_finish(self): self.msg('dumping search index...') - self.indexer.prune([self.get_target_uri(fn)[:-5] for fn in self.env.all_files]) + self.indexer.prune([fn[:-4] for fn in self.env.all_files]) f = open(path.join(self.outdir, 'searchindex.json'), 'w') try: self.indexer.dump(f, 'json') @@ -558,7 +541,7 @@ def get_outdated_files(self): for filename in get_matching_files( - self.srcdir, '*.rst', exclude=set(self.config.get('unused_files', ()))): + self.srcdir, '*.rst', exclude=set(self.config.unused_files)): try: targetmtime = path.getmtime( path.join(self.outdir, os_path(filename)[:-4] + '.fpickle')) @@ -587,14 +570,14 @@ # delete all entries for files that will be rebuilt self.indexer.prune(set(self.env.all_files) - set(filenames)) - def index_file(self, filename, doctree, title): + def index_page(self, pagename, doctree, title): # only index pages with title if self.indexer is not None and title: - self.indexer.feed(filename, title, doctree) + self.indexer.feed(pagename+'.rst', title, doctree) def handle_page(self, pagename, context, templatename='page.html'): context['current_page_name'] = pagename - sidebarfile = self.config.get('html_sidebars', {}).get(pagename, '') + sidebarfile = self.confightml_sidebars.get(pagename, '') if sidebarfile: context['customsidebar'] = path.join(self.srcdir, sidebarfile) outfilename = path.join(self.outdir, os_path(pagename) + '.fpickle') @@ -654,7 +637,7 @@ copysource = False def handle_finish(self): - build_hhx(self, self.outdir, self.config.get('htmlhelp_basename', 'pydoc')) + build_hhx(self, self.outdir, self.config.htmlhelp_basename) class LaTeXBuilder(Builder): @@ -665,13 +648,12 @@ def init(self): self.filenames = [] - self.document_data = map(list, self.config.get('latex_documents', ())) + self.document_data = map(list, self.config.latex_documents) # assign subdirs to titles self.titles = [] for entry in self.document_data: # replace version with real version - entry[0] = entry[0].replace('', self.config['version']) sourcename = entry[0] if sourcename.endswith('/index.rst'): sourcename = sourcename[:-9] @@ -693,7 +675,7 @@ def write(self, *ignored): # first, assemble the "appendix" docs that are in every PDF appendices = [] - for fname in self.config.get('latex_appendices', []): + for fname in self.config.latex_appendices: appendices.append(self.env.get_doctree(fname)) docwriter = LaTeXWriter(self) @@ -780,15 +762,10 @@ name = 'changes' def init(self): - from sphinx._jinja import Environment, FileSystemLoader - templates_path = path.join(path.dirname(__file__), 'templates') - jinja_env = Environment(loader=SphinxFileSystemLoader([templates_path]), - # disable traceback, more likely that something in the - # application is broken than in the templates - friendly_traceback=False) - self.ftemplate = jinja_env.get_template('changes/frameset.html') - self.vtemplate = jinja_env.get_template('changes/versionchanges.html') - self.stemplate = jinja_env.get_template('changes/rstsource.html') + self.init_templates() + self.ftemplate = self.get_template('changes/frameset.html') + self.vtemplate = self.get_template('changes/versionchanges.html') + self.stemplate = self.get_template('changes/rstsource.html') def get_outdated_files(self): return self.outdir @@ -800,13 +777,13 @@ } def write(self, *ignored): - ver = self.config['version'] + version = self.config.version libchanges = {} apichanges = [] otherchanges = {} self.msg('writing summary file...') for type, filename, lineno, module, descname, content in \ - self.env.versionchanges[ver]: + self.env.versionchanges[version]: ttext = self.typemap[type] context = content.replace('\n', ' ') if descname and filename.startswith('c-api'): @@ -836,8 +813,8 @@ (entry, filename, lineno)) ctx = { - 'project': self.config.get('project', 'Python'), - 'version': ver, + 'project': self.config.project, + 'version': version, 'libchanges': sorted(libchanges.iteritems()), 'apichanges': sorted(apichanges), 'otherchanges': sorted(otherchanges.iteritems()), @@ -853,9 +830,9 @@ finally: f.close() - hltext = ['.. versionadded:: %s' % ver, - '.. versionchanged:: %s' % ver, - '.. deprecated:: %s' % ver] + hltext = ['.. versionadded:: %s' % version, + '.. versionchanged:: %s' % version, + '.. deprecated:: %s' % version] def hl(no, line): line = ' ' % no + escape(line) @@ -881,11 +858,11 @@ shutil.copyfile(path.join(path.dirname(__file__), 'style', 'default.css'), path.join(self.outdir, 'default.css')) - def hl(self, text, ver): + def hl(self, text, version): text = escape(text) for directive in ['versionchanged', 'versionadded', 'deprecated']: - text = text.replace('.. %s:: %s' % (directive, ver), - '.. %s:: %s' % (directive, ver)) + text = text.replace('.. %s:: %s' % (directive, version), + '.. %s:: %s' % (directive, version)) return text def finish(self): Added: doctools/trunk/sphinx/config.py ============================================================================== --- (empty file) +++ doctools/trunk/sphinx/config.py Mon Jan 21 21:20:37 2008 @@ -0,0 +1,103 @@ +# -*- coding: utf-8 -*- +""" + sphinx.config + ~~~~~~~~~~~~~ + + Build configuration file handling. + + :copyright: 2008 by Georg Brandl. + :license: BSD license. +""" + +import os +import sys +import types +from os import path + + +class ConfigError(Exception): + """Raised if something's wrong with the configuration.""" + + def __init__(self, message, orig_exc=None): + self.message = message + self.orig_exc = orig_exc + + def __repr__(self): + if self.orig_exc: + return 'ConfigError(%r, %r)' % (self.message, self.orig_exc) + return 'ConfigError(%r)' % self.message + + def __str__(self): + if self.orig_exc: + return '%s (exception: %s)' % (self.message, self.orig_exc) + return self.message + + +class Config(object): + """Configuration file abstraction.""" + + # the values are: (default, needs fresh doctrees if changed) + + config_values = dict( + # general substitutions + project = ('Python', True), + copyright = ('', False), + version = ('', True), + release = ('', True), + today = ('', True), + today_fmt = ('%B %d, %Y', True), + + # extensibility + templates_path = ([], False), + extensions = ([], True), + + # general reading options + unused_files = ([], True), + refcount_file = ('', True), + add_function_parentheses = (True, True), + add_module_names = (True, True), + + # HTML options + html_last_updated_fmt = ('%b %d, %Y', False), + html_use_smartypants = (True, False), + html_translator_class = (None, False), + html_index = ('', False), + html_sidebars = ({}, False), + html_additional_pages = ({}, False), + + # HTML help options + htmlhelp_basename = ('pydoc', False), + + # LaTeX options + latex_paper_size = ('letter', False), + latex_font_size = ('10pt', False), + latex_documents = ([], False), + latex_preamble = ('', False), + latex_appendices = ([], False), + ) + + def __init__(self, dirname, filename): + config = {} + olddir = os.getcwd() + try: + os.chdir(dirname) + execfile(path.join(dirname, filename), config) + finally: + os.chdir(olddir) + # remove potentially pickling-problematic values + for key, val in config.items(): + if key.startswith('_') or isinstance(val, types.ModuleType): + del config[key] + self.__dict__.update(config) + + def __getattr__(self, name): + if name in self.config_values: + defval = self.config_values[name][0] + setattr(self, name, defval) + return defval + if name[0:1] == '_': + return object.__getattr__(self, name) + raise AttributeError('no configuration value named %r' % name) + + def __getitem__(self, name): + return getattr(self, name) Modified: doctools/trunk/sphinx/directives.py ============================================================================== --- doctools/trunk/sphinx/directives.py (original) +++ doctools/trunk/sphinx/directives.py Mon Jan 21 21:20:37 2008 @@ -147,7 +147,7 @@ signode += addnodes.desc_classname(classname, classname) # exceptions are a special case, since they are documented in the # 'exceptions' module. - elif env.config.get('add_module_names', True) and \ + elif env.config.add_module_names and \ env.currmodule and env.currmodule != 'exceptions': nodetext = env.currmodule + '.' signode += addnodes.desc_classname(nodetext, nodetext) Modified: doctools/trunk/sphinx/environment.py ============================================================================== --- doctools/trunk/sphinx/environment.py (original) +++ doctools/trunk/sphinx/environment.py Mon Jan 21 21:20:37 2008 @@ -22,6 +22,7 @@ import hashlib md5 = hashlib.md5 except: + # 2.4 compatibility import md5 md5 = md5.new @@ -102,10 +103,10 @@ for ref in self.document.traverse(nodes.substitution_reference): refname = ref['refname'] if refname in to_handle: - text = config.get(refname, '') + text = config[refname] if refname == 'today' and not text: # special handling: can also specify a strftime format - text = time.strftime(config.get('today_fmt', '%B %d, %Y')) + text = time.strftime(config.today_fmt) ref.replace_self(nodes.Text(text, text)) @@ -186,7 +187,7 @@ def __init__(self, srcdir, doctreedir): self.doctreedir = doctreedir self.srcdir = srcdir - self.config = {} + self.config = None # refcount data if present self.refcounts = {} @@ -203,6 +204,7 @@ # Build times -- to determine changed files # Also use this as an inventory of all existing and built filenames. + # All "filenames" here are /-separated and relative and include '.rst'. self.all_files = {} # filename -> (mtime, md5sum) at the time of build # File metadata @@ -279,7 +281,7 @@ Return (added, changed, removed) iterables. """ all_source_files = list(get_matching_files( - self.srcdir, '*.rst', exclude=set(config.get('unused_files', ())))) + self.srcdir, '*.rst', exclude=set(config.unused_files))) # clear all files no longer present removed = set(self.all_files) - set(all_source_files) @@ -312,27 +314,26 @@ return added, changed, removed - # If one of these config values changes, all files need to be re-read. - influential_config_values = [ - 'version', 'release', 'today', 'today_fmt', 'unused_files', - 'project', 'refcount_file', 'add_function_parentheses', 'add_module_names' - ] - - def update(self, config): - """ - (Re-)read all files new or changed since last update. - Yields a summary and then filenames as it processes them. - Store all environment filenames in the canonical format - (ie using SEP as a separator in place of os.path.sep). - """ + def update(self, config, hook=None): + """(Re-)read all files new or changed since last update. Yields a summary + and then filenames as it processes them. Store all environment filenames + in the canonical format (ie using SEP as a separator in place of + os.path.sep).""" config_changed = False - for val in self.influential_config_values: - if self.config.get(val) != config.get(val): - msg = '[config changed] ' - config_changed = True - break + if self.config is None: + msg = '[new config] ' + config_changed = True else: - msg = '' + # check if a config value was changed that affects how doctrees are read + for key, descr in config.config_values.iteritems(): + if not descr[1]: + continue + if self.config[key] != config[key]: + msg = '[config changed] ' + config_changed = True + break + else: + msg = '' added, changed, removed = self.get_outdated_files(config, config_changed) msg += '%s added, %s changed, %s removed' % (len(added), len(changed), len(removed)) @@ -341,9 +342,9 @@ self.config = config # read the refcounts file - if self.config.get('refcount_file'): + if self.config.refcount_file: self.refcounts = Refcounts.fromfile( - path.join(self.srcdir, self.config['refcount_file'])) + path.join(self.srcdir, self.config.refcount_file)) # clear all files no longer present for filename in removed: @@ -354,9 +355,12 @@ yield filename self.read_file(filename) + if 'contents.rst' not in self.all_files: + self._warnfunc('no master file contents.rst found') + # --------- SINGLE FILE BUILDING ------------------------------------------- - def read_file(self, filename, src_path=None, save_parsed=True): + def read_file(self, filename, src_path=None, save_parsed=True, hook=None): """Parse a file and add/update inventory entries for the doctree. If srcpath is given, read from a different source file.""" # remove all inventory entries for that file @@ -382,6 +386,10 @@ f.close() self.all_files[filename] = (path.getmtime(src_path), md5sum) + # run post-read hook + if hook: + hook(doctree) + # make it picklable doctree.reporter = None doctree.transformer = None Added: doctools/trunk/sphinx/extension.py ============================================================================== --- (empty file) +++ doctools/trunk/sphinx/extension.py Mon Jan 21 21:20:37 2008 @@ -0,0 +1,83 @@ +# -*- coding: utf-8 -*- +""" + sphinx.extension + ~~~~~~~~~~~~~~~~ + + Gracefully adapted from the TextPress event system by Armin. + + :copyright: 2008 by Georg Brandl, Armin Ronacher. + :license: BSD. +""" + +from sphinx.config import ConfigError + + +def import_object(objname, source=None): + """Import an object from a 'module.name' string.""" + try: + module, name = objname.rsplit('.', 1) + except ValueError, err: + raise ConfigError('Invalid full object name %s' % objname + + (source and ' (needed for %s)' % source or ''), err) + try: + return getattr(__import__(module, None, None, [name]), name) + except ImportError, err: + raise ConfigError('Could not import %s' % module + + (source and ' (needed for %s)' % source or ''), err) + except AttributeError, err: + raise ConfigError('Could not find %s' % objname + + (source and ' (needed for %s)' % source or ''), err) + + +# List of all known events. Maps name to arguments description. +events = { + 'builder-created' : 'builder instance', + 'doctree-read' : 'the doctree before being pickled', +} + +class EventManager(object): + """ + Helper class that handles event listeners and events. + + This is *not* a public interface. Always use the emit_event() + functions to access it or the connect_event() / disconnect_event() + functions on the application. + """ + + def __init__(self): + self.next_listener_id = 0 + self._listeners = {} + + def _validate(self, event): + event = intern(event) + if event not in events: + raise RuntimeError('unknown event name: %s' % event) + + def connect(self, event, callback): + self._validate(event) + listener_id = self.next_listener_id + if event not in self._listeners: + self._listeners[event] = {listener_id: callback} + else: + self._listeners[event][listener_id] = callback + self.next_listener_id += 1 + return listener_id + + def remove(self, listener_id): + for event in self._listeners: + event.pop(listener_id, None) + + def emit(self, event, *args): + self._validate(event) + if event in self._listeners: + for listener_id, callback in self._listeners[event].iteritems(): + yield listener_id, callback(*args) + + +class DummyEventManager(EventManager): + def connect(self, event, callback): + self._validate(event) + def remove(self, listener_id): + pass + def emit(self, event, *args): + self._validate(event) Modified: doctools/trunk/sphinx/htmlhelp.py ============================================================================== --- doctools/trunk/sphinx/htmlhelp.py (original) +++ doctools/trunk/sphinx/htmlhelp.py Mon Jan 21 21:20:37 2008 @@ -129,8 +129,8 @@ f = open(path.join(outdir, outname+'.hhp'), 'w') try: f.write(project_template % {'outname': outname, - 'version': builder.config['version'], - 'project': builder.config['project']}) + 'version': builder.config.version, + 'project': builder.config.project}) if not outdir.endswith(os.sep): outdir += os.sep olen = len(outdir) Modified: doctools/trunk/sphinx/htmlwriter.py ============================================================================== --- doctools/trunk/sphinx/htmlwriter.py (original) +++ doctools/trunk/sphinx/htmlwriter.py Mon Jan 21 21:20:37 2008 @@ -18,7 +18,18 @@ class HTMLWriter(Writer): def __init__(self, builder): Writer.__init__(self) - self.translator_class = translator_class(builder) + self.builder = builder + + def translate(self): + # sadly, this is mostly copied from parent class + self.visitor = visitor = self.builder.translator_class(self.builder, + self.document) + self.document.walkabout(visitor) + self.output = visitor.astext() + for attr in ('head_prefix', 'stylesheet', 'head', 'body_prefix', + 'body_pre_docinfo', 'docinfo', 'body', 'fragment', + 'body_suffix'): + setattr(self, attr, getattr(visitor, attr)) version_text = { @@ -27,283 +38,278 @@ 'versionadded': 'New in version %s', } -def translator_class(builder): - class HTMLTranslator(BaseTranslator): - """ - Our custom HTML translator. - """ - - def __init__(self, *args, **kwds): - self.no_smarty = 0 - BaseTranslator.__init__(self, *args, **kwds) - self.highlightlang = 'python' - self.language.labels['warning'] = 'Caveat' - - def visit_desc(self, node): - self.body.append(self.starttag(node, 'dl', CLASS=node['desctype'])) - def depart_desc(self, node): - self.body.append('\n\n') - - def visit_desc_signature(self, node): - # the id is set automatically - self.body.append(self.starttag(node, 'dt')) - # anchor for per-desc interactive data - if node.parent['desctype'] != 'describe' and node['ids'] and node['first']: - self.body.append('' % node['ids'][0]) - if node.parent['desctype'] in ('class', 'exception'): - self.body.append('%s ' % node.parent['desctype']) - def depart_desc_signature(self, node): - if node['ids'] and builder.name != 'htmlhelp': - self.body.append(u'\u00B6') - self.body.append('\n') - - def visit_desc_classname(self, node): - self.body.append(self.starttag(node, 'tt', '', CLASS='descclassname')) - def depart_desc_classname(self, node): - self.body.append('') - - def visit_desc_type(self, node): - # return type of C functions -- nothing to do here - pass - def depart_desc_type(self, node): - pass - - def visit_desc_name(self, node): - self.body.append(self.starttag(node, 'tt', '', CLASS='descname')) - def depart_desc_name(self, node): - self.body.append('') - - def visit_desc_parameterlist(self, node): - self.body.append('(') - self.first_param = 1 - def depart_desc_parameterlist(self, node): - self.body.append(')') - - def visit_desc_parameter(self, node): - if not self.first_param: - self.body.append(', ') - else: - self.first_param = 0 - if not node.hasattr('noemph'): - self.body.append('') - def depart_desc_parameter(self, node): - if not node.hasattr('noemph'): - self.body.append('') - - def visit_desc_optional(self, node): - self.body.append('[') - def depart_desc_optional(self, node): - self.body.append(']') - - def visit_desc_content(self, node): - self.body.append(self.starttag(node, 'dd', '')) - def depart_desc_content(self, node): - self.body.append('') - - def visit_refcount(self, node): - self.body.append(self.starttag(node, 'em', '', CLASS='refcount')) - def depart_refcount(self, node): +class HTMLTranslator(BaseTranslator): + """ + Our custom HTML translator. + """ + + def __init__(self, builder, *args, **kwds): + BaseTranslator.__init__(self, *args, **kwds) + self.no_smarty = 0 + self.builder = builder + self.highlightlang = 'python' + self.language.labels['warning'] = 'Caveat' + + def visit_desc(self, node): + self.body.append(self.starttag(node, 'dl', CLASS=node['desctype'])) + def depart_desc(self, node): + self.body.append('\n\n') + + def visit_desc_signature(self, node): + # the id is set automatically + self.body.append(self.starttag(node, 'dt')) + # anchor for per-desc interactive data + if node.parent['desctype'] != 'describe' and node['ids'] and node['first']: + self.body.append('' % node['ids'][0]) + if node.parent['desctype'] in ('class', 'exception'): + self.body.append('%s ' % node.parent['desctype']) + def depart_desc_signature(self, node): + if node['ids'] and self.builder.name != 'htmlhelp': + self.body.append(u'\u00B6') + self.body.append('\n') + + def visit_desc_classname(self, node): + self.body.append(self.starttag(node, 'tt', '', CLASS='descclassname')) + def depart_desc_classname(self, node): + self.body.append('') + + def visit_desc_type(self, node): + # return type of C functions -- nothing to do here + pass + def depart_desc_type(self, node): + pass + + def visit_desc_name(self, node): + self.body.append(self.starttag(node, 'tt', '', CLASS='descname')) + def depart_desc_name(self, node): + self.body.append('') + + def visit_desc_parameterlist(self, node): + self.body.append('(') + self.first_param = 1 + def depart_desc_parameterlist(self, node): + self.body.append(')') + + def visit_desc_parameter(self, node): + if not self.first_param: + self.body.append(', ') + else: + self.first_param = 0 + if not node.hasattr('noemph'): + self.body.append('') + def depart_desc_parameter(self, node): + if not node.hasattr('noemph'): self.body.append('') - def visit_versionmodified(self, node): - self.body.append(self.starttag(node, 'p')) - text = version_text[node['type']] % node['version'] - if len(node): - text += ': ' + def visit_desc_optional(self, node): + self.body.append('[') + def depart_desc_optional(self, node): + self.body.append(']') + + def visit_desc_content(self, node): + self.body.append(self.starttag(node, 'dd', '')) + def depart_desc_content(self, node): + self.body.append('') + + def visit_refcount(self, node): + self.body.append(self.starttag(node, 'em', '', CLASS='refcount')) + def depart_refcount(self, node): + self.body.append('') + + def visit_versionmodified(self, node): + self.body.append(self.starttag(node, 'p')) + text = version_text[node['type']] % node['version'] + if len(node): + text += ': ' + else: + text += '.' + self.body.append('%s' % text) + def depart_versionmodified(self, node): + self.body.append('

    \n') + + # overwritten + def visit_reference(self, node): + BaseTranslator.visit_reference(self, node) + if node.hasattr('reftitle'): + # ugly hack to add a title attribute + starttag = self.body[-1] + if not starttag.startswith('%s' % text) - def depart_versionmodified(self, node): - self.body.append('

    \n') - - # overwritten - def visit_reference(self, node): - BaseTranslator.visit_reference(self, node) - if node.hasattr('reftitle'): - # ugly hack to add a title attribute - starttag = self.body[-1] - if not starttag.startswith('
    \n' % h_level) + attrs = {} + self.body.append(self.starttag(node, 'h%d' % h_level, '', **attrs)) + self.context.append('\n' % h_level) + else: + BaseTranslator.visit_title(self, node, move_ids) + + # overwritten + def visit_literal_block(self, node): + from sphinx.highlighting import highlight_block + self.body.append(highlight_block(node.rawsource, self.highlightlang)) + raise nodes.SkipNode + + # overwritten + def visit_literal(self, node): + if len(node.children) == 1 and \ + node.children[0] in ('None', 'True', 'False'): + node['classes'].append('xref') + BaseTranslator.visit_literal(self, node) + + def visit_productionlist(self, node): + self.body.append(self.starttag(node, 'pre')) + names = [] + for production in node: + names.append(production['tokenname']) + maxlen = max(len(name) for name in names) + for production in node: + if production['tokenname']: + self.body.append(self.starttag(production, 'strong', '')) + self.body.append(production['tokenname'].ljust(maxlen) + + ' ::= ') + lastname = production['tokenname'] else: - BaseTranslator.visit_title(self, node, move_ids) - - # overwritten - def visit_literal_block(self, node): - from sphinx.highlighting import highlight_block - self.body.append(highlight_block(node.rawsource, self.highlightlang)) - raise nodes.SkipNode - - # overwritten - def visit_literal(self, node): - if len(node.children) == 1 and \ - node.children[0] in ('None', 'True', 'False'): - node['classes'].append('xref') - BaseTranslator.visit_literal(self, node) - - def visit_productionlist(self, node): - self.body.append(self.starttag(node, 'pre')) - names = [] - for production in node: - names.append(production['tokenname']) - maxlen = max(len(name) for name in names) - for production in node: - if production['tokenname']: - self.body.append(self.starttag(production, 'strong', '')) - self.body.append(production['tokenname'].ljust(maxlen) + - ' ::= ') - lastname = production['tokenname'] - else: - self.body.append('%s ' % (' '*len(lastname))) - production.walkabout(self) - self.body.append('\n') - self.body.append('\n') - raise nodes.SkipNode - def depart_productionlist(self, node): - pass - - def visit_production(self, node): - pass - def depart_production(self, node): - pass - - def visit_centered(self, node): - self.body.append(self.starttag(node, 'p', CLASS="centered") + '') - def depart_centered(self, node): - self.body.append('

    ') - - def visit_compact_paragraph(self, node): - pass - def depart_compact_paragraph(self, node): - pass - - def visit_highlightlang(self, node): - self.highlightlang = node['lang'] - def depart_highlightlang(self, node): - pass - - def visit_toctree(self, node): - # this only happens when formatting a toc from env.tocs -- in this - # case we don't want to include the subtree - raise nodes.SkipNode - - def visit_index(self, node): - raise nodes.SkipNode - - def visit_glossary(self, node): - pass - def depart_glossary(self, node): - pass - - def visit_acks(self, node): - pass - def depart_acks(self, node): - pass - - def visit_module(self, node): - pass - def depart_module(self, node): - pass - - # these are only handled specially in the SmartyPantsHTMLTranslator - def visit_literal_emphasis(self, node): - return self.visit_emphasis(node) - def depart_literal_emphasis(self, node): - return self.depart_emphasis(node) - - def depart_title(self, node): - close_tag = self.context[-1] - if builder.name != 'htmlhelp' and \ - (close_tag.startswith('\u00B6
    ') - BaseTranslator.depart_title(self, node) - - - class SmartyPantsHTMLTranslator(HTMLTranslator): - """ - Handle ordinary text via smartypants, converting quotes and dashes - to the correct entities. - """ - - def __init__(self, *args, **kwds): - self.no_smarty = 0 - HTMLTranslator.__init__(self, *args, **kwds) - - def visit_literal(self, node): - self.no_smarty += 1 - try: - # this raises SkipNode - HTMLTranslator.visit_literal(self, node) - finally: - self.no_smarty -= 1 - - def visit_literal_emphasis(self, node): - self.no_smarty += 1 - self.visit_emphasis(node) - - def depart_literal_emphasis(self, node): - self.depart_emphasis(node) + self.body.append('%s ' % (' '*len(lastname))) + production.walkabout(self) + self.body.append('\n') + self.body.append('\n') + raise nodes.SkipNode + def depart_productionlist(self, node): + pass + + def visit_production(self, node): + pass + def depart_production(self, node): + pass + + def visit_centered(self, node): + self.body.append(self.starttag(node, 'p', CLASS="centered") + '') + def depart_centered(self, node): + self.body.append('

    ') + + def visit_compact_paragraph(self, node): + pass + def depart_compact_paragraph(self, node): + pass + + def visit_highlightlang(self, node): + self.highlightlang = node['lang'] + def depart_highlightlang(self, node): + pass + + def visit_toctree(self, node): + # this only happens when formatting a toc from env.tocs -- in this + # case we don't want to include the subtree + raise nodes.SkipNode + + def visit_index(self, node): + raise nodes.SkipNode + + def visit_glossary(self, node): + pass + def depart_glossary(self, node): + pass + + def visit_acks(self, node): + pass + def depart_acks(self, node): + pass + + def visit_module(self, node): + pass + def depart_module(self, node): + pass + + # these are only handled specially in the SmartyPantsHTMLTranslator + def visit_literal_emphasis(self, node): + return self.visit_emphasis(node) + def depart_literal_emphasis(self, node): + return self.depart_emphasis(node) + + def depart_title(self, node): + close_tag = self.context[-1] + if self.builder.name != 'htmlhelp' and \ + (close_tag.startswith('\u00B6') + BaseTranslator.depart_title(self, node) + + +class SmartyPantsHTMLTranslator(HTMLTranslator): + """ + Handle ordinary text via smartypants, converting quotes and dashes + to the correct entities. + """ + + def __init__(self, *args, **kwds): + self.no_smarty = 0 + HTMLTranslator.__init__(self, *args, **kwds) + + def visit_literal(self, node): + self.no_smarty += 1 + try: + # this raises SkipNode + HTMLTranslator.visit_literal(self, node) + finally: self.no_smarty -= 1 - def visit_desc_signature(self, node): - self.no_smarty += 1 - HTMLTranslator.visit_desc_signature(self, node) - - def depart_desc_signature(self, node): + def visit_literal_emphasis(self, node): + self.no_smarty += 1 + self.visit_emphasis(node) + + def depart_literal_emphasis(self, node): + self.depart_emphasis(node) + self.no_smarty -= 1 + + def visit_desc_signature(self, node): + self.no_smarty += 1 + HTMLTranslator.visit_desc_signature(self, node) + + def depart_desc_signature(self, node): + self.no_smarty -= 1 + HTMLTranslator.depart_desc_signature(self, node) + + def visit_productionlist(self, node): + self.no_smarty += 1 + try: + HTMLTranslator.visit_productionlist(self, node) + finally: self.no_smarty -= 1 - HTMLTranslator.depart_desc_signature(self, node) - def visit_productionlist(self, node): - self.no_smarty += 1 - try: - HTMLTranslator.visit_productionlist(self, node) - finally: - self.no_smarty -= 1 - - def encode(self, text): - text = HTMLTranslator.encode(self, text) - if self.no_smarty <= 0: - text = sphinx_smarty_pants(text) - return text - - if builder.config.get('html_use_smartypants', False): - return SmartyPantsHTMLTranslator - else: - return HTMLTranslator + def encode(self, text): + text = HTMLTranslator.encode(self, text) + if self.no_smarty <= 0: + text = sphinx_smarty_pants(text) + return text Modified: doctools/trunk/sphinx/latexwriter.py ============================================================================== --- doctools/trunk/sphinx/latexwriter.py (original) +++ doctools/trunk/sphinx/latexwriter.py Mon Jan 21 21:20:37 2008 @@ -21,7 +21,7 @@ from sphinx import addnodes from sphinx import highlighting - +# Move to a template? HEADER = r'''%% Generated by Sphinx. \documentclass[%(papersize)s,%(pointsize)s]{%(docclass)s} \usepackage[utf8]{inputenc} @@ -92,18 +92,18 @@ self.builder = builder self.body = [] docclass = document.settings.docclass - paper = builder.config.get('latex_paper_size', 'letter') + 'paper' + paper = builder.config.latex_paper_size + 'paper' if paper == 'paper': # e.g. command line "-D latex_paper_size=" paper = 'letterpaper' - date = time.strftime(builder.config.get('today_fmt', '%B %d, %Y')) + date = time.strftime(builder.config.today_fmt) self.options = {'docclass': docclass, 'papersize': paper, - 'pointsize': builder.config.get('latex_font_size', '10pt'), - 'preamble': builder.config['latex_preamble'], + 'pointsize': builder.config.latex_font_size, + 'preamble': builder.config.latex_preamble, 'author': document.settings.author, 'filename': document.settings.filename, 'title': None, # is determined later - 'release': builder.config['release'], + 'release': builder.config.release, 'date': date, } self.context = [] Deleted: /doctools/trunk/sphinx/patchlevel.py ============================================================================== --- /doctools/trunk/sphinx/patchlevel.py Mon Jan 21 21:20:37 2008 +++ (empty file) @@ -1,60 +0,0 @@ -# -*- coding: utf-8 -*- -""" - sphinx.patchlevel - ~~~~~~~~~~~~~~~~~ - - Extract version info from Include/patchlevel.h. - Adapted from Doc/tools/getversioninfo. - - XXX Python specific - - :copyright: 2007-2008 by Georg Brandl. - :license: BSD. -""" - -import os -import re -import sys - -def get_version_info(srcdir): - patchlevel_h = os.path.join(srcdir, '..', "Include", "patchlevel.h") - - # This won't pick out all #defines, but it will pick up the ones we - # care about. - rx = re.compile(r"\s*#define\s+([a-zA-Z][a-zA-Z_0-9]*)\s+([a-zA-Z_0-9]+)") - - d = {} - f = open(patchlevel_h) - try: - for line in f: - m = rx.match(line) - if m is not None: - name, value = m.group(1, 2) - d[name] = value - finally: - f.close() - - release = version = "%s.%s" % (d["PY_MAJOR_VERSION"], d["PY_MINOR_VERSION"]) - micro = int(d["PY_MICRO_VERSION"]) - if micro != 0: - release += "." + str(micro) - - level = d["PY_RELEASE_LEVEL"] - suffixes = { - "PY_RELEASE_LEVEL_ALPHA": "a", - "PY_RELEASE_LEVEL_BETA": "b", - "PY_RELEASE_LEVEL_GAMMA": "c", - } - if level != "PY_RELEASE_LEVEL_FINAL": - release += suffixes[level] + str(int(d["PY_RELEASE_SERIAL"])) - return version, release - - -def get_sys_version_info(): - major, minor, micro, level, serial = sys.version_info - release = version = '%s.%s' % (major, minor) - if micro: - release += '.%s' % micro - if level != 'final': - release += '%s%s' % (level[0], serial) - return version, release Modified: doctools/trunk/sphinx/roles.py ============================================================================== --- doctools/trunk/sphinx/roles.py (original) +++ doctools/trunk/sphinx/roles.py Mon Jan 21 21:20:37 2008 @@ -109,7 +109,7 @@ if text.endswith('()'): # remove parentheses text = text[:-2] - if env.config.get('add_function_parentheses', True): + if env.config.add_function_parentheses: # add them back to all occurrences if configured text += '()' # if the first character is a bang, don't cross-reference at all Modified: doctools/trunk/sphinx/templates/layout.html ============================================================================== --- doctools/trunk/sphinx/templates/layout.html (original) +++ doctools/trunk/sphinx/templates/layout.html Mon Jan 21 21:20:37 2008 @@ -113,7 +113,8 @@ {% if customsidebar %} {{ rendertemplate(customsidebar) }} {% endif %} - {% if current_page_name != "search" %} + {% if current_page_name != "search" and builder == 'web' %} + {# HTML builder search is disabled for now #}

    {{ builder == 'web' and 'Keyword' or 'Quick' }} search

    From python-checkins at python.org Mon Jan 21 21:20:54 2008 From: python-checkins at python.org (georg.brandl) Date: Mon, 21 Jan 2008 21:20:54 +0100 (CET) Subject: [Python-checkins] r60175 - in python/trunk/Doc: conf.py tools/sphinxext/patchlevel.py Message-ID: <20080121202054.384301E4019@bag.python.org> Author: georg.brandl Date: Mon Jan 21 21:20:53 2008 New Revision: 60175 Added: python/trunk/Doc/tools/sphinxext/patchlevel.py Modified: python/trunk/Doc/conf.py Log: Adapt to latest doctools refactoring. Modified: python/trunk/Doc/conf.py ============================================================================== --- python/trunk/Doc/conf.py (original) +++ python/trunk/Doc/conf.py Mon Jan 21 21:20:53 2008 @@ -7,23 +7,27 @@ # The contents of this file are pickled, so don't put values in the namespace # that aren't pickleable (module imports are okay, they're removed automatically). +import sys, os, time +sys.path.append('tools/sphinxext') + # General configuration # --------------------- # General substitutions. project = 'Python' -copyright = '1990-2007, Python Software Foundation' +copyright = '1990-%s, Python Software Foundation' % time.strftime('%Y') # The default replacements for |version| and |release|. -# If '', Sphinx looks for the Include/patchlevel.h file in the current Python -# source tree and replaces the values accordingly. # # The short X.Y version. # version = '2.6' -version = '' # The full version, including alpha/beta/rc tags. # release = '2.6a0' -release = '' + +# We look for the Include/patchlevel.h file in the current Python source tree +# and replace the values accordingly. +import patchlevel +version, release = patchlevel.get_version_info() # There are two options for replacing |today|: either, you set today to some # non-false value, then it is used: @@ -118,7 +122,6 @@ 'What\'s New in Python', 'A. M. Kuchling', 'howto'), ] # Collect all HOWTOs individually -import os latex_documents.extend(('howto/' + fn, 'howto-' + fn[:-4] + '.tex', 'HOWTO', _stdauthor, 'howto') for fn in os.listdir('howto') Added: python/trunk/Doc/tools/sphinxext/patchlevel.py ============================================================================== --- (empty file) +++ python/trunk/Doc/tools/sphinxext/patchlevel.py Mon Jan 21 21:20:53 2008 @@ -0,0 +1,68 @@ +# -*- coding: utf-8 -*- +""" + patchlevel.py + ~~~~~~~~~~~~~ + + Extract version info from Include/patchlevel.h. + Adapted from Doc/tools/getversioninfo. + + :copyright: 2007-2008 by Georg Brandl. + :license: Python license. +""" + +import os +import re +import sys + +def get_header_version_info(srcdir): + patchlevel_h = os.path.join(srcdir, '..', 'Include', 'patchlevel.h') + + # This won't pick out all #defines, but it will pick up the ones we + # care about. + rx = re.compile(r'\s*#define\s+([a-zA-Z][a-zA-Z_0-9]*)\s+([a-zA-Z_0-9]+)') + + d = {} + f = open(patchlevel_h) + try: + for line in f: + m = rx.match(line) + if m is not None: + name, value = m.group(1, 2) + d[name] = value + finally: + f.close() + + release = version = '%s.%s' % (d['PY_MAJOR_VERSION'], d['PY_MINOR_VERSION']) + micro = int(d['PY_MICRO_VERSION']) + if micro != 0: + release += '.' + str(micro) + + level = d['PY_RELEASE_LEVEL'] + suffixes = { + 'PY_RELEASE_LEVEL_ALPHA': 'a', + 'PY_RELEASE_LEVEL_BETA': 'b', + 'PY_RELEASE_LEVEL_GAMMA': 'c', + } + if level != 'PY_RELEASE_LEVEL_FINAL': + release += suffixes[level] + str(int(d['PY_RELEASE_SERIAL'])) + return version, release + + +def get_sys_version_info(): + major, minor, micro, level, serial = sys.version_info + release = version = '%s.%s' % (major, minor) + if micro: + release += '.%s' % micro + if level != 'final': + release += '%s%s' % (level[0], serial) + return version, release + + +def get_version_info(): + try: + return get_header_version_info('.') + except (IOError, OSError): + version, release = get_sys_version_info() + print >>sys.stderr, 'Can\'t get version info from Include/patchlevel.h, ' \ + 'using version of this interpreter (%s).' % release + return version, release From python-checkins at python.org Mon Jan 21 21:39:53 2008 From: python-checkins at python.org (georg.brandl) Date: Mon, 21 Jan 2008 21:39:53 +0100 (CET) Subject: [Python-checkins] r60177 - doctools/trunk/sphinx/__init__.py Message-ID: <20080121203953.627351E401C@bag.python.org> Author: georg.brandl Date: Mon Jan 21 21:39:53 2008 New Revision: 60177 Modified: doctools/trunk/sphinx/__init__.py Log: Fix. Modified: doctools/trunk/sphinx/__init__.py ============================================================================== --- doctools/trunk/sphinx/__init__.py (original) +++ doctools/trunk/sphinx/__init__.py Mon Jan 21 21:39:53 2008 @@ -54,6 +54,7 @@ status_stream=status, warning_stream=warning, events=events, config=config, freshenv=freshenv) events.emit('builder-created', builder) + return builder def usage(argv, msg=None): From python-checkins at python.org Mon Jan 21 22:05:49 2008 From: python-checkins at python.org (georg.brandl) Date: Mon, 21 Jan 2008 22:05:49 +0100 (CET) Subject: [Python-checkins] r60178 - in python/trunk: Lib/pydoc.py Lib/test/pydocfodder.py Misc/NEWS Message-ID: <20080121210549.E23331E4023@bag.python.org> Author: georg.brandl Date: Mon Jan 21 22:05:49 2008 New Revision: 60178 Modified: python/trunk/Lib/pydoc.py python/trunk/Lib/test/pydocfodder.py python/trunk/Misc/NEWS Log: #1715: include sub-extension modules in pydoc text output. Modified: python/trunk/Lib/pydoc.py ============================================================================== --- python/trunk/Lib/pydoc.py (original) +++ python/trunk/Lib/pydoc.py Mon Jan 21 22:05:49 2008 @@ -1051,9 +1051,11 @@ if visiblename(key, all): data.append((key, value)) + modpkgs = [] + modpkgs_names = set() if hasattr(object, '__path__'): - modpkgs = [] for importer, modname, ispkg in pkgutil.iter_modules(object.__path__): + modpkgs_names.add(modname) if ispkg: modpkgs.append(modname + ' (package)') else: @@ -1063,6 +1065,16 @@ result = result + self.section( 'PACKAGE CONTENTS', join(modpkgs, '\n')) + # Detect submodules as sometimes created by C extensions + submodules = [] + for key, value in inspect.getmembers(object, inspect.ismodule): + if value.__name__.startswith(name + '.') and key not in modpkgs_names: + submodules.append(key) + if submodules: + submodules.sort() + result = result + self.section( + 'SUBMODULES', join(submodules, '\n')) + if classes: classlist = map(lambda (key, value): value, classes) contents = [self.formattree( Modified: python/trunk/Lib/test/pydocfodder.py ============================================================================== --- python/trunk/Lib/test/pydocfodder.py (original) +++ python/trunk/Lib/test/pydocfodder.py Mon Jan 21 22:05:49 2008 @@ -1,5 +1,7 @@ """Something just to look at via pydoc.""" +import types + class A_classic: "A classic class." def A_method(self): @@ -208,3 +210,7 @@ del inst.desc[self.attr] x = property(get_desc('x'), set_desc('x'), del_desc('x'), 'prop x') + + +submodule = types.ModuleType(__name__ + '.submodule', + """A submodule, which should appear in its parent's summary""") Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Mon Jan 21 22:05:49 2008 @@ -372,6 +372,8 @@ Library ------- +- #1715: include sub-extension modules in pydoc's text output. + - #1836: fix an off-by-one bug in TimedRotatingHandler's rollover time calculation. From python-checkins at python.org Mon Jan 21 22:14:21 2008 From: python-checkins at python.org (georg.brandl) Date: Mon, 21 Jan 2008 22:14:21 +0100 (CET) Subject: [Python-checkins] r60179 - python/trunk/Parser/tokenizer.c Message-ID: <20080121211421.448AB1E4019@bag.python.org> Author: georg.brandl Date: Mon Jan 21 22:14:21 2008 New Revision: 60179 Modified: python/trunk/Parser/tokenizer.c Log: Add a "const" to make gcc happy. Modified: python/trunk/Parser/tokenizer.c ============================================================================== --- python/trunk/Parser/tokenizer.c (original) +++ python/trunk/Parser/tokenizer.c Mon Jan 21 22:14:21 2008 @@ -586,7 +586,7 @@ { PyObject* utf8 = NULL; const char *s; - char *newl[2] = {NULL, NULL}; + const char *newl[2] = {NULL, NULL}; int lineno = 0; tok->enc = NULL; tok->str = str; From python-checkins at python.org Mon Jan 21 22:19:07 2008 From: python-checkins at python.org (georg.brandl) Date: Mon, 21 Jan 2008 22:19:07 +0100 (CET) Subject: [Python-checkins] r60180 - python/trunk/Lib/site.py Message-ID: <20080121211907.B28421E4019@bag.python.org> Author: georg.brandl Date: Mon Jan 21 22:19:07 2008 New Revision: 60180 Modified: python/trunk/Lib/site.py Log: Add the correct build dir when building with pydebug. Modified: python/trunk/Lib/site.py ============================================================================== --- python/trunk/Lib/site.py (original) +++ python/trunk/Lib/site.py Mon Jan 21 22:19:07 2008 @@ -102,6 +102,8 @@ (especially for Guido :-)""" from distutils.util import get_platform s = "build/lib.%s-%.3s" % (get_platform(), sys.version) + if hasattr(sys, 'gettotalrefcount'): + s += '-pydebug' s = os.path.join(os.path.dirname(sys.path[-1]), s) sys.path.append(s) From python-checkins at python.org Mon Jan 21 22:23:15 2008 From: python-checkins at python.org (georg.brandl) Date: Mon, 21 Jan 2008 22:23:15 +0100 (CET) Subject: [Python-checkins] r60181 - in python/trunk: Include/structmember.h Lib/test/test_structmembers.py Misc/NEWS Modules/_testcapimodule.c Python/structmember.c Message-ID: <20080121212315.7258C1E4019@bag.python.org> Author: georg.brandl Date: Mon Jan 21 22:23:15 2008 New Revision: 60181 Modified: python/trunk/Include/structmember.h python/trunk/Lib/test/test_structmembers.py python/trunk/Misc/NEWS python/trunk/Modules/_testcapimodule.c python/trunk/Python/structmember.c Log: Patch #1720595: add T_BOOL to the range of structmember types. Patch by Angelo Mottola, reviewed by MvL, tests by me. Modified: python/trunk/Include/structmember.h ============================================================================== --- python/trunk/Include/structmember.h (original) +++ python/trunk/Include/structmember.h Mon Jan 21 22:23:15 2008 @@ -62,6 +62,9 @@ /* Added by Jack: strings contained in the structure */ #define T_STRING_INPLACE 13 +/* Added by Lillo: bools contained in the structure (assumed char) */ +#define T_BOOL 14 + #define T_OBJECT_EX 16 /* Like T_OBJECT, but raises AttributeError when the value is NULL, instead of converting to None. */ Modified: python/trunk/Lib/test/test_structmembers.py ============================================================================== --- python/trunk/Lib/test/test_structmembers.py (original) +++ python/trunk/Lib/test/test_structmembers.py Mon Jan 21 22:23:15 2008 @@ -8,10 +8,16 @@ import warnings, exceptions, unittest, sys from test import test_support -ts=test_structmembersType(1,2,3,4,5,6,7,8,9.99999,10.1010101010) +ts=test_structmembersType(False,1,2,3,4,5,6,7,8,9.99999,10.1010101010) class ReadWriteTests(unittest.TestCase): def test_types(self): + ts.T_BOOL=True + self.assertEquals(ts.T_BOOL, True) + ts.T_BOOL=False + self.assertEquals(ts.T_BOOL, False) + self.assertRaises(TypeError, setattr, ts, 'T_BOOL', 1) + ts.T_BYTE=CHAR_MAX self.assertEquals(ts.T_BYTE, CHAR_MAX) ts.T_BYTE=CHAR_MIN Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Mon Jan 21 22:23:15 2008 @@ -12,6 +12,8 @@ Core and builtins ----------------- +- Patch #1720595: add T_BOOL to the range of structmember types. + - Issue #1882: when compiling code from a string, encoding cookies in the second line of code were not always recognized correctly. Modified: python/trunk/Modules/_testcapimodule.c ============================================================================== --- python/trunk/Modules/_testcapimodule.c (original) +++ python/trunk/Modules/_testcapimodule.c Mon Jan 21 22:23:15 2008 @@ -762,6 +762,7 @@ #define AddSym(d, n, f, v) {PyObject *o = f(v); PyDict_SetItemString(d, n, o); Py_DECREF(o);} typedef struct { + char bool_member; char byte_member; unsigned char ubyte_member; short short_member; @@ -784,6 +785,7 @@ } test_structmembers; static struct PyMemberDef test_members[] = { + {"T_BOOL", T_BOOL, offsetof(test_structmembers, structmembers.bool_member), 0, NULL}, {"T_BYTE", T_BYTE, offsetof(test_structmembers, structmembers.byte_member), 0, NULL}, {"T_UBYTE", T_UBYTE, offsetof(test_structmembers, structmembers.ubyte_member), 0, NULL}, {"T_SHORT", T_SHORT, offsetof(test_structmembers, structmembers.short_member), 0, NULL}, @@ -803,13 +805,13 @@ static PyObject *test_structmembers_new(PyTypeObject *type, PyObject *args, PyObject *kwargs){ - static char *keywords[]={"T_BYTE", "T_UBYTE", "T_SHORT", "T_USHORT", "T_INT", "T_UINT", + static char *keywords[]={"T_BOOL", "T_BYTE", "T_UBYTE", "T_SHORT", "T_USHORT", "T_INT", "T_UINT", "T_LONG", "T_ULONG", "T_FLOAT", "T_DOUBLE", #ifdef HAVE_LONG_LONG "T_LONGLONG", "T_ULONGLONG", #endif NULL}; - static char *fmt="|bBhHiIlkfd" + static char *fmt="|bbBhHiIlkfd" #ifdef HAVE_LONG_LONG "LK" #endif @@ -819,6 +821,7 @@ return NULL; memset(&ob->structmembers, 0, sizeof(all_structmembers)); if (!PyArg_ParseTupleAndKeywords(args, kwargs, fmt, keywords, + &ob->structmembers.bool_member, &ob->structmembers.byte_member, &ob->structmembers.ubyte_member, &ob->structmembers.short_member, &ob->structmembers.ushort_member, &ob->structmembers.int_member, &ob->structmembers.uint_member, Modified: python/trunk/Python/structmember.c ============================================================================== --- python/trunk/Python/structmember.c (original) +++ python/trunk/Python/structmember.c Mon Jan 21 22:23:15 2008 @@ -61,6 +61,9 @@ } addr += l->offset; switch (l->type) { + case T_BOOL: + v = PyBool_FromLong(*(char*)addr); + break; case T_BYTE: v = PyInt_FromLong(*(char*)addr); break; @@ -183,6 +186,18 @@ } addr += l->offset; switch (l->type) { + case T_BOOL:{ + if (!PyBool_Check(v)) { + PyErr_SetString(PyExc_TypeError, + "attribute value type must be bool"); + return -1; + } + if (v == Py_True) + *(char*)addr = (char) 1; + else + *(char*)addr = (char) 0; + break; + } case T_BYTE:{ long long_val = PyInt_AsLong(v); if ((long_val == -1) && PyErr_Occurred()) From python-checkins at python.org Mon Jan 21 22:28:32 2008 From: python-checkins at python.org (georg.brandl) Date: Mon, 21 Jan 2008 22:28:32 +0100 (CET) Subject: [Python-checkins] r60182 - in python/trunk: Lib/test/test_structmembers.py Modules/_testcapimodule.c Message-ID: <20080121212832.DD0D81E4019@bag.python.org> Author: georg.brandl Date: Mon Jan 21 22:28:32 2008 New Revision: 60182 Modified: python/trunk/Lib/test/test_structmembers.py python/trunk/Modules/_testcapimodule.c Log: Reformat some ugly code. Modified: python/trunk/Lib/test/test_structmembers.py ============================================================================== --- python/trunk/Lib/test/test_structmembers.py (original) +++ python/trunk/Lib/test/test_structmembers.py Mon Jan 21 22:28:32 2008 @@ -8,58 +8,59 @@ import warnings, exceptions, unittest, sys from test import test_support -ts=test_structmembersType(False,1,2,3,4,5,6,7,8,9.99999,10.1010101010) +ts=test_structmembersType(False, 1, 2, 3, 4, 5, 6, 7, 8, + 9.99999, 10.1010101010) class ReadWriteTests(unittest.TestCase): def test_types(self): - ts.T_BOOL=True + ts.T_BOOL = True self.assertEquals(ts.T_BOOL, True) - ts.T_BOOL=False + ts.T_BOOL = False self.assertEquals(ts.T_BOOL, False) self.assertRaises(TypeError, setattr, ts, 'T_BOOL', 1) - ts.T_BYTE=CHAR_MAX + ts.T_BYTE = CHAR_MAX self.assertEquals(ts.T_BYTE, CHAR_MAX) - ts.T_BYTE=CHAR_MIN + ts.T_BYTE = CHAR_MIN self.assertEquals(ts.T_BYTE, CHAR_MIN) - ts.T_UBYTE=UCHAR_MAX + ts.T_UBYTE = UCHAR_MAX self.assertEquals(ts.T_UBYTE, UCHAR_MAX) - ts.T_SHORT=SHRT_MAX + ts.T_SHORT = SHRT_MAX self.assertEquals(ts.T_SHORT, SHRT_MAX) - ts.T_SHORT=SHRT_MIN + ts.T_SHORT = SHRT_MIN self.assertEquals(ts.T_SHORT, SHRT_MIN) - ts.T_USHORT=USHRT_MAX + ts.T_USHORT = USHRT_MAX self.assertEquals(ts.T_USHORT, USHRT_MAX) - ts.T_INT=INT_MAX + ts.T_INT = INT_MAX self.assertEquals(ts.T_INT, INT_MAX) - ts.T_INT=INT_MIN + ts.T_INT = INT_MIN self.assertEquals(ts.T_INT, INT_MIN) - ts.T_UINT=UINT_MAX + ts.T_UINT = UINT_MAX self.assertEquals(ts.T_UINT, UINT_MAX) - ts.T_LONG=LONG_MAX + ts.T_LONG = LONG_MAX self.assertEquals(ts.T_LONG, LONG_MAX) - ts.T_LONG=LONG_MIN + ts.T_LONG = LONG_MIN self.assertEquals(ts.T_LONG, LONG_MIN) - ts.T_ULONG=ULONG_MAX + ts.T_ULONG = ULONG_MAX self.assertEquals(ts.T_ULONG, ULONG_MAX) ## T_LONGLONG and T_ULONGLONG may not be present on some platforms if hasattr(ts, 'T_LONGLONG'): - ts.T_LONGLONG=LLONG_MAX + ts.T_LONGLONG = LLONG_MAX self.assertEquals(ts.T_LONGLONG, LLONG_MAX) - ts.T_LONGLONG=LLONG_MIN + ts.T_LONGLONG = LLONG_MIN self.assertEquals(ts.T_LONGLONG, LLONG_MIN) - ts.T_ULONGLONG=ULLONG_MAX + ts.T_ULONGLONG = ULLONG_MAX self.assertEquals(ts.T_ULONGLONG, ULLONG_MAX) ## make sure these will accept a plain int as well as a long - ts.T_LONGLONG=3 + ts.T_LONGLONG = 3 self.assertEquals(ts.T_LONGLONG, 3) - ts.T_ULONGLONG=4 + ts.T_ULONGLONG = 4 self.assertEquals(ts.T_ULONGLONG, 4) @@ -69,32 +70,32 @@ def test_byte_max(self): with test_support.catch_warning() as w: - ts.T_BYTE=CHAR_MAX+1 + ts.T_BYTE = CHAR_MAX+1 self.has_warned(w) def test_byte_min(self): with test_support.catch_warning() as w: - ts.T_BYTE=CHAR_MIN-1 + ts.T_BYTE = CHAR_MIN-1 self.has_warned(w) def test_ubyte_max(self): with test_support.catch_warning() as w: - ts.T_UBYTE=UCHAR_MAX+1 + ts.T_UBYTE = UCHAR_MAX+1 self.has_warned(w) def test_short_max(self): with test_support.catch_warning() as w: - ts.T_SHORT=SHRT_MAX+1 + ts.T_SHORT = SHRT_MAX+1 self.has_warned(w) def test_short_min(self): with test_support.catch_warning() as w: - ts.T_SHORT=SHRT_MIN-1 + ts.T_SHORT = SHRT_MIN-1 self.has_warned(w) def test_ushort_max(self): with test_support.catch_warning() as w: - ts.T_USHORT=USHRT_MAX+1 + ts.T_USHORT = USHRT_MAX+1 self.has_warned(w) Modified: python/trunk/Modules/_testcapimodule.c ============================================================================== --- python/trunk/Modules/_testcapimodule.c (original) +++ python/trunk/Modules/_testcapimodule.c Mon Jan 21 22:28:32 2008 @@ -804,40 +804,53 @@ }; -static PyObject *test_structmembers_new(PyTypeObject *type, PyObject *args, PyObject *kwargs){ - static char *keywords[]={"T_BOOL", "T_BYTE", "T_UBYTE", "T_SHORT", "T_USHORT", "T_INT", "T_UINT", - "T_LONG", "T_ULONG", "T_FLOAT", "T_DOUBLE", - #ifdef HAVE_LONG_LONG +static PyObject * +test_structmembers_new(PyTypeObject *type, PyObject *args, PyObject *kwargs) +{ + static char *keywords[] = { + "T_BOOL", "T_BYTE", "T_UBYTE", "T_SHORT", "T_USHORT", + "T_INT", "T_UINT", "T_LONG", "T_ULONG", + "T_FLOAT", "T_DOUBLE", +#ifdef HAVE_LONG_LONG "T_LONGLONG", "T_ULONGLONG", - #endif +#endif NULL}; - static char *fmt="|bbBhHiIlkfd" - #ifdef HAVE_LONG_LONG + static char *fmt = "|bbBhHiIlkfd" +#ifdef HAVE_LONG_LONG "LK" - #endif +#endif ; - test_structmembers *ob=PyObject_New(test_structmembers, type); - if (ob==NULL) + test_structmembers *ob; + ob = PyObject_New(test_structmembers, type); + if (ob == NULL) return NULL; memset(&ob->structmembers, 0, sizeof(all_structmembers)); if (!PyArg_ParseTupleAndKeywords(args, kwargs, fmt, keywords, - &ob->structmembers.bool_member, - &ob->structmembers.byte_member, &ob->structmembers.ubyte_member, - &ob->structmembers.short_member, &ob->structmembers.ushort_member, - &ob->structmembers.int_member, &ob->structmembers.uint_member, - &ob->structmembers.long_member, &ob->structmembers.ulong_member, - &ob->structmembers.float_member, &ob->structmembers.double_member - #ifdef HAVE_LONG_LONG - ,&ob->structmembers.longlong_member, &ob->structmembers.ulonglong_member - #endif - )){ + &ob->structmembers.bool_member, + &ob->structmembers.byte_member, + &ob->structmembers.ubyte_member, + &ob->structmembers.short_member, + &ob->structmembers.ushort_member, + &ob->structmembers.int_member, + &ob->structmembers.uint_member, + &ob->structmembers.long_member, + &ob->structmembers.ulong_member, + &ob->structmembers.float_member, + &ob->structmembers.double_member +#ifdef HAVE_LONG_LONG + , &ob->structmembers.longlong_member, + &ob->structmembers.ulonglong_member +#endif + )) { Py_DECREF(ob); return NULL; - } + } return (PyObject *)ob; } -static void test_structmembers_free(PyObject *ob){ +static void +test_structmembers_free(PyObject *ob) +{ PyObject_FREE(ob); } @@ -858,8 +871,8 @@ 0, /* tp_hash */ 0, /* tp_call */ 0, /* tp_str */ - PyObject_GenericGetAttr, - PyObject_GenericSetAttr, + PyObject_GenericGetAttr, /* tp_getattro */ + PyObject_GenericSetAttr, /* tp_setattro */ 0, /* tp_as_buffer */ 0, /* tp_flags */ "Type containing all structmember types", @@ -870,7 +883,7 @@ 0, /* tp_iter */ 0, /* tp_iternext */ 0, /* tp_methods */ - test_members, /* tp_members */ + test_members, /* tp_members */ 0, 0, 0, @@ -879,7 +892,7 @@ 0, 0, 0, - test_structmembers_new, /* tp_new */ + test_structmembers_new, /* tp_new */ }; From python-checkins at python.org Mon Jan 21 22:54:47 2008 From: python-checkins at python.org (mark.dickinson) Date: Mon, 21 Jan 2008 22:54:47 +0100 (CET) Subject: [Python-checkins] r60183 - in python/branches/release25-maint: Lib/test/test_float.py Misc/NEWS Python/compile.c Message-ID: <20080121215447.D73A41E4003@bag.python.org> Author: mark.dickinson Date: Mon Jan 21 22:54:47 2008 New Revision: 60183 Modified: python/branches/release25-maint/Lib/test/test_float.py python/branches/release25-maint/Misc/NEWS python/branches/release25-maint/Python/compile.c Log: Issue 1678380: fix a bug identifying -0.0 and 0.0 Modified: python/branches/release25-maint/Lib/test/test_float.py ============================================================================== --- python/branches/release25-maint/Lib/test/test_float.py (original) +++ python/branches/release25-maint/Lib/test/test_float.py Mon Jan 21 22:54:47 2008 @@ -99,6 +99,27 @@ ('ob_type); + /* _and_ to distinguish 0.0 from -0.0 e.g. on IEEE platforms */ + if (PyFloat_Check(o)) { + double d = PyFloat_AS_DOUBLE(o); + unsigned char* p = (unsigned char*) &d; + /* all we need is to make the tuple different in either the 0.0 + * or -0.0 case from all others, just to avoid the "coercion". + */ + if (*p==0 && p[sizeof(double)-1]==0) + t = PyTuple_Pack(3, o, o->ob_type, Py_None); + else + t = PyTuple_Pack(2, o, o->ob_type); + } else { + t = PyTuple_Pack(2, o, o->ob_type); + } if (t == NULL) return -1; From nnorwitz at gmail.com Mon Jan 21 23:32:16 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Mon, 21 Jan 2008 17:32:16 -0500 Subject: [Python-checkins] Python Regression Test Failures refleak (8) Message-ID: <20080121223216.GA1981@python.psfb.org> test_opcodes leaked [0, -2, 2] references, sum=0 test_doctest leaked [-2, 2, 0] references, sum=0 test_doctest2 leaked [-2, -2, 0] references, sum=-4 test_cmd_line leaked [0, 23, -23] references, sum=0 test_descrtut leaked [2, 2, -2] references, sum=2 test_difflib leaked [0, -2, 0] references, sum=-2 test_gc leaked [-2, 0, 0] references, sum=-2 test_getargs2 leaked [0, -2, 0] references, sum=-2 test_importhooks leaked [-2, 2, -2] references, sum=-2 test_os leaked [-2, 2, 0] references, sum=0 test_plistlib leaked [0, -2, 0] references, sum=-2 test_threadsignals leaked [0, -8, 0] references, sum=-8 test_urllib2_localnet leaked [3, 3, 3] references, sum=9 test_urlparse leaked [0, -2, 0] references, sum=-2 test_weakref leaked [2, 0, -2] references, sum=0 From python-checkins at python.org Mon Jan 21 23:18:07 2008 From: python-checkins at python.org (brett.cannon) Date: Mon, 21 Jan 2008 23:18:07 +0100 (CET) Subject: [Python-checkins] r60184 - peps/trunk/pep-3108.txt Message-ID: <20080121221807.193901E4003@bag.python.org> Author: brett.cannon Date: Mon Jan 21 23:18:06 2008 New Revision: 60184 Modified: peps/trunk/pep-3108.txt Log: Add dbm package. Modified: peps/trunk/pep-3108.txt ============================================================================== --- peps/trunk/pep-3108.txt (original) +++ peps/trunk/pep-3108.txt Mon Jan 21 23:18:06 2008 @@ -351,7 +351,8 @@ Along with the stdlib gaining some modules that are no longer relevant, there is also the issue of naming. Many modules existed in the stdlib before PEP 8 came into existence [#pep-0008]_. This has -led to some naming inconsistencies that should be addressed. +led to some naming inconsistencies and namespace bloat that should be +addressed. Any module that has been suggested for removal and does not meet the required naming scheme is *not* listed below. @@ -464,6 +465,35 @@ ================= =============================== +Grouping of modules +------------------- + +As the stdlib has grown, several areas within it have expanded to +include multiple modules (e.g., dbm support). Thus some new packages +make sense where the renaming makes a module's name easier to work +with. + + +dbm package +/////////// + +The ``dbm`` package is to collect all dbm-related modules. Do note +that both ``anydbm`` and ``whichdb`` are merged into a single module. +This was done as both modules currently have minimal functionality and +have no name conflicts. + +================= =============================== +Current Name Replacement Name +================= =============================== +anydbm dbm.tools +dbhash dbm.db +dbm dbm.ndbm +dumbdm dbm.dumb +gdbm dbm.gnu +whichdb dbm.tools +================= =============================== + + Transition Plan =============== @@ -496,7 +526,7 @@ to bind in the module namespace to the old name while importing based on the new name. -All the database related modules will be moved to a database package. +All database related modules will be moved to a database package. These modules include: bsddb, dbm, gdbm, sqlite, anydbm, dbhash, dumbdbm, whichdb. From buildbot at python.org Mon Jan 21 23:25:55 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 21 Jan 2008 22:25:55 +0000 Subject: [Python-checkins] buildbot failure in x86 gentoo 2.5 Message-ID: <20080121222555.E8C7F1E4024@bag.python.org> The Buildbot has detected a new failure of x86 gentoo 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20gentoo%202.5/builds/513 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-x86 Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: mark.dickinson BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_float ====================================================================== FAIL: test_underflow_sign (test.test_float.IEEEFormatTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildslave/python-trunk/2.5.norwitz-x86/build/Lib/test/test_float.py", line 120, in test_underflow_sign self.assertEquals(math.atan2(-1e-1000, -1), math.atan2(-0.0, -1)) AssertionError: 3.1415926535897931 != -3.1415926535897931 make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Mon Jan 21 23:30:54 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 21 Jan 2008 22:30:54 +0000 Subject: [Python-checkins] buildbot failure in x86 mvlgcc 2.5 Message-ID: <20080121223055.586891E4003@bag.python.org> The Buildbot has detected a new failure of x86 mvlgcc 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20mvlgcc%202.5/builds/389 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-linux Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: mark.dickinson BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_float ====================================================================== FAIL: test_underflow_sign (test.test_float.IEEEFormatTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home2/buildbot/slave/2.5.loewis-linux/build/Lib/test/test_float.py", line 120, in test_underflow_sign self.assertEquals(math.atan2(-1e-1000, -1), math.atan2(-0.0, -1)) AssertionError: 3.1415926535897931 != -3.1415926535897931 make: *** [buildbottest] Fehler 1 sincerely, -The Buildbot From nnorwitz at gmail.com Mon Jan 21 23:55:13 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Mon, 21 Jan 2008 17:55:13 -0500 Subject: [Python-checkins] Python Regression Test Failures all (1) Message-ID: <20080121225513.GA6856@python.psfb.org> test_grammar test_opcodes test_dict test_builtin test_exceptions test_types test_unittest test_doctest test_doctest2 test_MimeWriter test_StringIO test___all__ test___future__ test__locale test_abc test_abstract_numbers test_aepack test_aepack skipped -- No module named aepack test_al test_al skipped -- No module named al test_anydbm test_applesingle test_applesingle skipped -- No module named macostools test_array test_ast test_asynchat test_asyncore test_atexit test_audioop test_augassign test_base64 test_bastion test_bigaddrspace test_bigmem test_binascii test_binhex test_binop test_bisect test_bool test_bsddb test_bsddb185 test_bsddb185 skipped -- No module named bsddb185 test_bsddb3 test test_bsddb3 failed -- errors occurred; run in verbose mode for details test_buffer test_bufio test_bz2 test_cProfile test_calendar test_call test_capi test_cd test_cd skipped -- No module named cd test_cfgparser test_cgi test_charmapcodec test_cl test_cl skipped -- No module named cl test_class test_cmath test_cmd test_cmd_line test_cmd_line_script test_code test_codeccallbacks test_codecencodings_cn test_codecencodings_hk test_codecencodings_jp test_codecencodings_kr test_codecencodings_tw test_codecmaps_cn test_codecmaps_hk test_codecmaps_jp test_codecmaps_kr test_codecmaps_tw test_codecs test_codeop test_coding test_coercion test_collections test_colorsys test_commands test_compare test_compile test_compiler testCompileLibrary still working, be patient... test_complex test_complex_args test_contains test_contextlib test_cookie test_cookielib test_copy test_copy_reg test_cpickle test_crypt test_csv test_ctypes test_datetime test_dbm test_decimal test_decorators test_defaultdict test_deque test_descr test_descrtut test_difflib test_dircache test_dis test_distutils test_dl test_docxmlrpc test_dumbdbm test_dummy_thread test_dummy_threading test_email test_email_codecs test_email_renamed test_enumerate test_eof test_errno test_exception_variations test_extcall test_fcntl test_file test_filecmp test_fileinput test_float test_fnmatch test_fork1 test_format test_fpformat test_frozen test_ftplib test_funcattrs test_functools test_future test_gc test_gdbm test_generators test_genericpath test_genexps test_getargs test_getargs2 test_getopt test_gettext test_gl test_gl skipped -- No module named gl test_glob test_global test_grp test_gzip test_hash test_hashlib test_heapq test_hexoct test_hmac test_hotshot test_htmllib test_htmlparser test_httplib test_imageop test_imageop skipped -- No module named imgfile test_imaplib test_imgfile test_imgfile skipped -- No module named imgfile test_imp test_import test_importhooks test_index test_inspect test_ioctl test_ioctl skipped -- Unable to open /dev/tty test_isinstance test_iter test_iterlen test_itertools test_largefile test_list test_locale test_logging test_long test_long_future test_longexp test_macostools test_macostools skipped -- No module named macostools test_macpath test_mailbox test_marshal test_math test_md5 test_mhlib test_mimetools test_mimetypes test_minidom test_mmap test_module test_modulefinder test_multibytecodec test_multibytecodec_support test_multifile test_mutants test_netrc test_new test_nis test_normalization test_ntpath test_old_mailbox test_openpty test_operator test_optparse test_os test_parser test_peepholer test_pep247 test_pep263 test_pep277 test_pep277 skipped -- test works only on NT+ test_pep292 test_pep352 test_pickle test_pickletools test_pipes test_pkg test_pkgimport test_platform test_plistlib test_poll test_popen [8908 refs] [8908 refs] [8908 refs] test_popen2 test_poplib test_posix test_posixpath test_pow test_pprint test_profile test_profilehooks test_property test_pstats test_pty test_pwd test_pyclbr test_pyexpat test_queue test_quopri [9277 refs] [9277 refs] test_random test_rational test_re test_repr test_resource test_rfc822 test_richcmp test_robotparser test_runpy test_sax test_scope test_scriptpackages test_scriptpackages skipped -- No module named aetools test_select test_set test_sets test_sgmllib test_sha test_shelve test_shlex test_shutil test_signal test_site test_slice test_smtplib test_socket test_socket_ssl /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:94: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ssl_sock = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:60: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:130: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:144: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) test_socketserver test_softspace test_sort test_sqlite test_ssl test_startfile test_startfile skipped -- cannot import name startfile test_str test_strftime test_string test_stringprep test_strop test_strptime test_struct test_structmembers test_structseq test_subprocess [8903 refs] [8906 refs] [8903 refs] [8903 refs] [8903 refs] [8903 refs] [8903 refs] [8903 refs] [8903 refs] [8905 refs] [8906 refs] [10457 refs] [9121 refs] [8906 refs] [8903 refs] [8903 refs] [8903 refs] [8903 refs] [8903 refs] . [8903 refs] [8903 refs] this bit of output is from a test of stdout in a different process ... [8903 refs] [8903 refs] [9121 refs] test_sunaudiodev test_sunaudiodev skipped -- No module named sunaudiodev test_sundry test_symtable test_syntax test_sys [8903 refs] [8903 refs] test_tarfile test_tcl test_tcl skipped -- No module named _tkinter test_telnetlib test_tempfile [8909 refs] test_textwrap test_thread test_threaded_import test_threadedtempfile test_threading [13151 refs] test_threading_local test_threadsignals test_time test_timeout test_tokenize test_trace test_traceback test_transformer test_tuple test_typechecks test_ucn test_unary test_unicode test_unicode_file test_unicode_file skipped -- No Unicode filesystem semantics on this platform. test_unicodedata test_univnewlines test_unpack test_urllib test_urllib2 test_urllib2_localnet test_urllib2net test test_urllib2net failed -- Traceback (most recent call last): File "/tmp/python-test/local/lib/python2.6/test/test_urllib2net.py", line 175, in test_ftp self._test_urls(urls, self._extra_handlers()) File "/tmp/python-test/local/lib/python2.6/test/test_urllib2net.py", line 244, in _test_urls f = urllib2.urlopen(url, req) File "/tmp/python-test/local/lib/python2.6/urllib2.py", line 124, in urlopen return _opener.open(url, data, timeout) File "/tmp/python-test/local/lib/python2.6/urllib2.py", line 380, in open response = self._open(req, data) File "/tmp/python-test/local/lib/python2.6/urllib2.py", line 398, in _open '_open', req) File "/tmp/python-test/local/lib/python2.6/urllib2.py", line 358, in _call_chain result = func(*args) File "/tmp/python-test/local/lib/python2.6/urllib2.py", line 1284, in ftp_open fp, retrlen = fw.retrfile(file, type) File "/tmp/python-test/local/lib/python2.6/urllib.py", line 880, in retrfile self.ftp.cwd(file) File "/tmp/python-test/local/lib/python2.6/ftplib.py", line 503, in cwd return self.voidcmd(cmd) File "/tmp/python-test/local/lib/python2.6/ftplib.py", line 246, in voidcmd return self.voidresp() File "/tmp/python-test/local/lib/python2.6/ftplib.py", line 221, in voidresp resp = self.getresp() File "/tmp/python-test/local/lib/python2.6/ftplib.py", line 216, in getresp raise error_perm, resp TypeError: __init__() takes exactly 2 arguments (3 given) test_urllibnet test_urlparse test_userdict test_userlist test_userstring test_uu test_uuid WARNING: uuid.getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._ifconfig_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._unixdll_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. test_wait3 test_wait4 test_warnings test_wave test_weakref test_whichdb test_winreg test_winreg skipped -- No module named _winreg test_winsound test_winsound skipped -- No module named winsound test_with test_wsgiref test_xdrlib test_xml_etree test_xml_etree_c test_xmllib test_xmlrpc test_xpickle test_xrange test_zipfile /tmp/python-test/local/lib/python2.6/test/test_zipfile.py:471: DeprecationWarning: struct integer overflow masking is deprecated zipfp.close() /tmp/python-test/local/lib/python2.6/test/test_zipfile.py:398: DeprecationWarning: struct integer overflow masking is deprecated zipfp.close() test_zipfile64 test_zipfile64 skipped -- test requires loads of disk-space bytes and a long time to run test_zipimport test_zlib 314 tests OK. 2 tests failed: test_bsddb3 test_urllib2net 20 tests skipped: test_aepack test_al test_applesingle test_bsddb185 test_cd test_cl test_gl test_imageop test_imgfile test_ioctl test_macostools test_pep277 test_scriptpackages test_startfile test_sunaudiodev test_tcl test_unicode_file test_winreg test_winsound test_zipfile64 1 skip unexpected on linux2: test_ioctl [542239 refs] From nnorwitz at gmail.com Mon Jan 21 23:55:21 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Mon, 21 Jan 2008 17:55:21 -0500 Subject: [Python-checkins] Python Regression Test Failures doc (1) Message-ID: <20080121225521.GA6876@python.psfb.org> svn update tools/sphinx D tools/sphinx/patchlevel.py U tools/sphinx/__init__.py U tools/sphinx/htmlwriter.py U tools/sphinx/directives.py U tools/sphinx/environment.py A tools/sphinx/config.py U tools/sphinx/templates/layout.html U tools/sphinx/latexwriter.py A tools/sphinx/extension.py U tools/sphinx/htmlhelp.py U tools/sphinx/roles.py U tools/sphinx/builder.py Fetching external item into 'tools/sphinx/jinja' Updated external to revision 60184. Updated to revision 60184. svn update tools/docutils At revision 60184. svn update tools/pygments At revision 60184. mkdir -p build/html build/doctrees python tools/sphinx-build.py -b html -d build/doctrees -D latex_paper_size= . build/html trying to load pickled env... done building [html]: targets for 11 source files that are out of date reading, updating environment: Traceback (most recent call last): File "tools/sphinx-build.py", line 24, in sys.exit(main(sys.argv)) File "/home/neal/python/trunk/Doc/tools/sphinx/__init__.py", line 153, in main builder.build_update() File "/home/neal/python/trunk/Doc/tools/sphinx/builder.py", line 173, in build_update 'out of date' % len(to_build)) File "/home/neal/python/trunk/Doc/tools/sphinx/builder.py", line 188, in build self.msg(iterator.next(), nonl=1, nobold=1) File "/home/neal/python/trunk/Doc/tools/sphinx/environment.py", line 331, in update if self.config[key] != config[key]: KeyError: 'extensions' make: *** [build] Error 1 From python-checkins at python.org Mon Jan 21 23:36:32 2008 From: python-checkins at python.org (georg.brandl) Date: Mon, 21 Jan 2008 23:36:32 +0100 (CET) Subject: [Python-checkins] r60185 - doctools/trunk/sphinx/environment.py Message-ID: <20080121223632.B75251E4023@bag.python.org> Author: georg.brandl Date: Mon Jan 21 23:36:32 2008 New Revision: 60185 Modified: doctools/trunk/sphinx/environment.py Log: Bump env version because of new config class. Modified: doctools/trunk/sphinx/environment.py ============================================================================== --- doctools/trunk/sphinx/environment.py (original) +++ doctools/trunk/sphinx/environment.py Mon Jan 21 23:36:32 2008 @@ -57,7 +57,7 @@ # This is increased every time a new environment attribute is added # to properly invalidate pickle files. -ENV_VERSION = 14 +ENV_VERSION = 15 def walk_depth(node, depth, maxdepth): From python-checkins at python.org Tue Jan 22 00:35:12 2008 From: python-checkins at python.org (mark.dickinson) Date: Tue, 22 Jan 2008 00:35:12 +0100 (CET) Subject: [Python-checkins] r60186 - python/branches/release25-maint/Lib/test/test_float.py Message-ID: <20080121233512.49A5A1E4025@bag.python.org> Author: mark.dickinson Date: Tue Jan 22 00:35:11 2008 New Revision: 60186 Modified: python/branches/release25-maint/Lib/test/test_float.py Log: Remove extra test that was accidentally backported from the trunk Modified: python/branches/release25-maint/Lib/test/test_float.py ============================================================================== --- python/branches/release25-maint/Lib/test/test_float.py (original) +++ python/branches/release25-maint/Lib/test/test_float.py Tue Jan 22 00:35:11 2008 @@ -113,14 +113,6 @@ self.assertEquals(pos_pos(), neg_pos()) self.assertEquals(pos_neg(), neg_neg()) - if float.__getformat__("double").startswith("IEEE"): - def test_underflow_sign(self): - import math - # check that -1e-1000 gives -0.0, not 0.0 - self.assertEquals(math.atan2(-1e-1000, -1), math.atan2(-0.0, -1)) - self.assertEquals(math.atan2(float('-1e-1000'), -1), - math.atan2(-0.0, -1)) - def test_main(): test_support.run_unittest( FormatFunctionsTestCase, From python-checkins at python.org Tue Jan 22 00:50:16 2008 From: python-checkins at python.org (brett.cannon) Date: Tue, 22 Jan 2008 00:50:16 +0100 (CET) Subject: [Python-checkins] r60187 - python/trunk/Makefile.pre.in Message-ID: <20080121235016.9A3191E4003@bag.python.org> Author: brett.cannon Date: Tue Jan 22 00:50:16 2008 New Revision: 60187 Modified: python/trunk/Makefile.pre.in Log: Make's MAKEFLAGS variable is set to a string containing the single-letter arguments to Make. This means there are no hyphens. Fix the '-s' check to silence distutils to now work. Modified: python/trunk/Makefile.pre.in ============================================================================== --- python/trunk/Makefile.pre.in (original) +++ python/trunk/Makefile.pre.in Tue Jan 22 00:50:16 2008 @@ -358,7 +358,7 @@ # Build the shared modules sharedmods: $(BUILDPYTHON) @case $$MAKEFLAGS in \ - *-s*) $(RUNSHARED) CC='$(CC)' LDSHARED='$(BLDSHARED)' OPT='$(OPT)' ./$(BUILDPYTHON) -E $(srcdir)/setup.py -q build;; \ + *s*) $(RUNSHARED) CC='$(CC)' LDSHARED='$(BLDSHARED)' OPT='$(OPT)' ./$(BUILDPYTHON) -E $(srcdir)/setup.py -q build;; \ *) $(RUNSHARED) CC='$(CC)' LDSHARED='$(BLDSHARED)' OPT='$(OPT)' ./$(BUILDPYTHON) -E $(srcdir)/setup.py build;; \ esac From python-checkins at python.org Tue Jan 22 01:19:42 2008 From: python-checkins at python.org (gregory.p.smith) Date: Tue, 22 Jan 2008 01:19:42 +0100 (CET) Subject: [Python-checkins] r60188 - in python/trunk: Lib/ftplib.py Misc/NEWS Message-ID: <20080122001942.5BD581E4003@bag.python.org> Author: gregory.p.smith Date: Tue Jan 22 01:19:41 2008 New Revision: 60188 Modified: python/trunk/Lib/ftplib.py python/trunk/Misc/NEWS Log: accepts and closes issue #1221598: adds an optional callback to ftplib.FTP storbinary() and storlines() methods. Modified: python/trunk/Lib/ftplib.py ============================================================================== --- python/trunk/Lib/ftplib.py (original) +++ python/trunk/Lib/ftplib.py Tue Jan 22 01:19:41 2008 @@ -32,6 +32,7 @@ # Changes and improvements suggested by Steve Majewski. # Modified by Jack to work on the mac. # Modified by Siebren to support docstrings and PASV. +# Modified by Phil Schwartz to add storbinary and storlines callbacks. # import os @@ -375,14 +376,18 @@ return resp def retrbinary(self, cmd, callback, blocksize=8192, rest=None): - """Retrieve data in binary mode. + """Retrieve data in binary mode. A new port is created for you. - `cmd' is a RETR command. `callback' is a callback function is - called for each block. No more than `blocksize' number of - bytes will be read from the socket. Optional `rest' is passed - to transfercmd(). + Args: + cmd: A RETR command. + callback: A single parameter callable to be called on each + block of data read. + blocksize: The maximum number of bytes to read from the + socket at one time. [default: 8192] + rest: Passed to transfercmd(). [default: None] - A new port is created for you. Return the response code. + Returns: + The response code. """ self.voidcmd('TYPE I') conn = self.transfercmd(cmd, rest) @@ -395,11 +400,17 @@ return self.voidresp() def retrlines(self, cmd, callback = None): - '''Retrieve data in line mode. - The argument is a RETR or LIST command. - The callback function (2nd argument) is called for each line, - with trailing CRLF stripped. This creates a new port for you. - print_line() is the default callback.''' + """Retrieve data in line mode. A new port is created for you. + + Args: + cmd: A RETR or LIST command. + callback: An optional single parameter callable that is called + for each line with the trailing CRLF stripped. + [default: print_line()] + + Returns: + The response code. + """ if callback is None: callback = print_line resp = self.sendcmd('TYPE A') conn = self.transfercmd(cmd) @@ -418,19 +429,42 @@ conn.close() return self.voidresp() - def storbinary(self, cmd, fp, blocksize=8192): - '''Store a file in binary mode.''' + def storbinary(self, cmd, fp, blocksize=8192, callback=None): + """Store a file in binary mode. A new port is created for you. + + Args: + cmd: A STOR command. + fp: A file-like object with a read(num_bytes) method. + blocksize: The maximum data size to read from fp and send over + the connection at once. [default: 8192] + callback: An optional single parameter callable that is called on + on each block of data after it is sent. [default: None] + + Returns: + The response code. + """ self.voidcmd('TYPE I') conn = self.transfercmd(cmd) while 1: buf = fp.read(blocksize) if not buf: break conn.sendall(buf) + if callback: callback(buf) conn.close() return self.voidresp() - def storlines(self, cmd, fp): - '''Store a file in line mode.''' + def storlines(self, cmd, fp, callback=None): + """Store a file in line mode. A new port is created for you. + + Args: + cmd: A STOR command. + fp: A file-like object with a readline() method. + callback: An optional single parameter callable that is called on + on each line after it is sent. [default: None] + + Returns: + The response code. + """ self.voidcmd('TYPE A') conn = self.transfercmd(cmd) while 1: @@ -440,6 +474,7 @@ if buf[-1] in CRLF: buf = buf[:-1] buf = buf + CRLF conn.sendall(buf) + if callback: callback(buf) conn.close() return self.voidresp() Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Tue Jan 22 01:19:41 2008 @@ -374,6 +374,9 @@ Library ------- +- #1221598: add optional callbacks to ftplib.FTP's storbinary() and + storlines() methods. (Contributed by Phil Schwartz) + - #1715: include sub-extension modules in pydoc's text output. - #1836: fix an off-by-one bug in TimedRotatingHandler's rollover From buildbot at python.org Tue Jan 22 01:41:17 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 22 Jan 2008 00:41:17 +0000 Subject: [Python-checkins] buildbot failure in alpha Tru64 5.1 2.5 Message-ID: <20080122004117.22C371E4003@bag.python.org> The Buildbot has detected a new failure of alpha Tru64 5.1 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/alpha%20Tru64%205.1%202.5/builds/408 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-tru64 Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: mark.dickinson BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_socket sincerely, -The Buildbot From python-checkins at python.org Tue Jan 22 02:12:03 2008 From: python-checkins at python.org (gregory.p.smith) Date: Tue, 22 Jan 2008 02:12:03 +0100 (CET) Subject: [Python-checkins] r60189 - python/trunk/Lib/threading.py Message-ID: <20080122011203.1FA881E4003@bag.python.org> Author: gregory.p.smith Date: Tue Jan 22 02:12:02 2008 New Revision: 60189 Modified: python/trunk/Lib/threading.py Log: Replace spam.acquire() try: ... finally: spam.release() with "with spam:" Modified: python/trunk/Lib/threading.py ============================================================================== --- python/trunk/Lib/threading.py (original) +++ python/trunk/Lib/threading.py Tue Jan 22 02:12:02 2008 @@ -347,27 +347,18 @@ return self.__flag def set(self): - self.__cond.acquire() - try: + with self.__cond: self.__flag = True self.__cond.notifyAll() - finally: - self.__cond.release() def clear(self): - self.__cond.acquire() - try: + with self.__cond: self.__flag = False - finally: - self.__cond.release() def wait(self, timeout=None): - self.__cond.acquire() - try: + with self.__cond: if not self.__flag: self.__cond.wait(timeout) - finally: - self.__cond.release() # Helper to generate new thread names _counter = 0 @@ -531,10 +522,9 @@ pass def __stop(self): - self.__block.acquire() - self.__stopped = True - self.__block.notifyAll() - self.__block.release() + with self.__block: + self.__stopped = True + self.__block.notifyAll() def __delete(self): "Remove current thread from the dict of currently running threads." @@ -560,15 +550,12 @@ # since it isn't if dummy_threading is *not* being used then don't # hide the exception. - _active_limbo_lock.acquire() - try: + with _active_limbo_lock: try: del _active[_get_ident()] except KeyError: if 'dummy_threading' not in _sys.modules: raise - finally: - _active_limbo_lock.release() def join(self, timeout=None): if not self.__initialized: @@ -581,8 +568,7 @@ if __debug__: if not self.__stopped: self._note("%s.join(): waiting until thread stops", self) - self.__block.acquire() - try: + with self.__block: if timeout is None: while not self.__stopped: self.__block.wait() @@ -600,8 +586,6 @@ else: if __debug__: self._note("%s.join(): thread stopped", self) - finally: - self.__block.release() def getName(self): assert self.__initialized, "Thread.__init__() not called" From python-checkins at python.org Tue Jan 22 02:20:42 2008 From: python-checkins at python.org (gregory.p.smith) Date: Tue, 22 Jan 2008 02:20:42 +0100 (CET) Subject: [Python-checkins] r60190 - in python/trunk: Lib/test/test_threading.py Lib/threading.py Misc/NEWS Message-ID: <20080122012042.E51031E4003@bag.python.org> Author: gregory.p.smith Date: Tue Jan 22 02:20:42 2008 New Revision: 60190 Modified: python/trunk/Lib/test/test_threading.py python/trunk/Lib/threading.py python/trunk/Misc/NEWS Log: - Fix Issue #1703448: A joined thread could show up in the threading.enumerate() list after the join() for a brief period until it actually exited. Modified: python/trunk/Lib/test/test_threading.py ============================================================================== --- python/trunk/Lib/test/test_threading.py (original) +++ python/trunk/Lib/test/test_threading.py Tue Jan 22 02:20:42 2008 @@ -236,6 +236,24 @@ """]) self.assertEqual(rc, 42) + def test_enumerate_after_join(self): + # Try hard to trigger #1703448: a thread is still returned in + # threading.enumerate() after it has been join()ed. + enum = threading.enumerate + old_interval = sys.getcheckinterval() + sys.setcheckinterval(1) + try: + for i in xrange(1, 1000): + t = threading.Thread(target=lambda: None) + t.start() + t.join() + l = enum() + self.assertFalse(t in l, + "#1703448 triggered after %d trials: %s" % (i, l)) + finally: + sys.setcheckinterval(old_interval) + + class ThreadingExceptionTests(unittest.TestCase): # A RuntimeError should be raised if Thread.start() is called # multiple times. Modified: python/trunk/Lib/threading.py ============================================================================== --- python/trunk/Lib/threading.py (original) +++ python/trunk/Lib/threading.py Tue Jan 22 02:20:42 2008 @@ -515,11 +515,14 @@ if __debug__: self._note("%s.__bootstrap(): normal return", self) finally: - self.__stop() - try: - self.__delete() - except: - pass + with _active_limbo_lock: + self.__stop() + try: + # We don't call self.__delete() because it also + # grabs _active_limbo_lock. + del _active[_get_ident()] + except: + pass def __stop(self): with self.__block: Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Tue Jan 22 02:20:42 2008 @@ -371,6 +371,10 @@ - Issue #1537: Changed GeneratorExit's base class from Exception to BaseException. +- Fix Issue #1703448: A joined thread could show up in the + threading.enumerate() list after the join() for a brief period until + it actually exited. + Library ------- From python-checkins at python.org Tue Jan 22 02:29:12 2008 From: python-checkins at python.org (gregory.p.smith) Date: Tue, 22 Jan 2008 02:29:12 +0100 (CET) Subject: [Python-checkins] r60191 - in python/branches/release25-maint: Lib/test/test_threading.py Lib/threading.py Misc/NEWS Message-ID: <20080122012912.3C8BB1E4003@bag.python.org> Author: gregory.p.smith Date: Tue Jan 22 02:29:11 2008 New Revision: 60191 Modified: python/branches/release25-maint/Lib/test/test_threading.py python/branches/release25-maint/Lib/threading.py python/branches/release25-maint/Misc/NEWS Log: Backport of r60190: - Fix Issue #1703448: A joined thread could show up in the threading.enumerate() list after the join() for a brief period until it actually exited. Modified: python/branches/release25-maint/Lib/test/test_threading.py ============================================================================== --- python/branches/release25-maint/Lib/test/test_threading.py (original) +++ python/branches/release25-maint/Lib/test/test_threading.py Tue Jan 22 02:29:11 2008 @@ -3,6 +3,7 @@ import test.test_support from test.test_support import verbose import random +import sys import threading import thread import time @@ -201,6 +202,24 @@ t.join() # else the thread is still running, and we have no way to kill it + def test_enumerate_after_join(self): + # Try hard to trigger #1703448: a thread is still returned in + # threading.enumerate() after it has been join()ed. + enum = threading.enumerate + old_interval = sys.getcheckinterval() + sys.setcheckinterval(1) + try: + for i in xrange(1, 1000): + t = threading.Thread(target=lambda: None) + t.start() + t.join() + l = enum() + self.assertFalse(t in l, + "#1703448 triggered after %d trials: %s" % (i, l)) + finally: + sys.setcheckinterval(old_interval) + + def test_main(): test.test_support.run_unittest(ThreadTests) Modified: python/branches/release25-maint/Lib/threading.py ============================================================================== --- python/branches/release25-maint/Lib/threading.py (original) +++ python/branches/release25-maint/Lib/threading.py Tue Jan 22 02:29:11 2008 @@ -524,11 +524,17 @@ if __debug__: self._note("%s.__bootstrap(): normal return", self) finally: - self.__stop() + _active_limbo_lock.acquire() try: - self.__delete() - except: - pass + self.__stop() + try: + # We don't call self.__delete() because it also + # grabs _active_limbo_lock. + del _active[_get_ident()] + except: + pass + finally: + _active_limbo_lock.release() def __stop(self): self.__block.acquire() Modified: python/branches/release25-maint/Misc/NEWS ============================================================================== --- python/branches/release25-maint/Misc/NEWS (original) +++ python/branches/release25-maint/Misc/NEWS Tue Jan 22 02:29:11 2008 @@ -55,6 +55,10 @@ - Bug #1733488: Fix compilation of bufferobject.c on AIX. +- Fix Issue #1703448: A joined thread could show up in the + threading.enumerate() list after the join() for a brief period until + it actually exited. + Library ------- From python-checkins at python.org Tue Jan 22 02:59:47 2008 From: python-checkins at python.org (brett.cannon) Date: Tue, 22 Jan 2008 02:59:47 +0100 (CET) Subject: [Python-checkins] r60192 - peps/trunk/pep-3108.txt Message-ID: <20080122015947.5D27A1E4003@bag.python.org> Author: brett.cannon Date: Tue Jan 22 02:59:47 2008 New Revision: 60192 Modified: peps/trunk/pep-3108.txt Log: Remove mention of a 'databases' package. Modified: peps/trunk/pep-3108.txt ============================================================================== --- peps/trunk/pep-3108.txt (original) +++ peps/trunk/pep-3108.txt Tue Jan 22 02:59:47 2008 @@ -526,10 +526,6 @@ to bind in the module namespace to the old name while importing based on the new name. -All database related modules will be moved to a database package. -These modules include: bsddb, dbm, gdbm, sqlite, -anydbm, dbhash, dumbdbm, whichdb. - Open Issues =========== From python-checkins at python.org Tue Jan 22 08:53:32 2008 From: python-checkins at python.org (georg.brandl) Date: Tue, 22 Jan 2008 08:53:32 +0100 (CET) Subject: [Python-checkins] r60193 - python/trunk/Doc/reference/lexical_analysis.rst Message-ID: <20080122075332.496791E4003@bag.python.org> Author: georg.brandl Date: Tue Jan 22 08:53:31 2008 New Revision: 60193 Modified: python/trunk/Doc/reference/lexical_analysis.rst Log: Fix \xhh specs, #1889. Modified: python/trunk/Doc/reference/lexical_analysis.rst ============================================================================== --- python/trunk/Doc/reference/lexical_analysis.rst (original) +++ python/trunk/Doc/reference/lexical_analysis.rst Tue Jan 22 08:53:31 2008 @@ -530,7 +530,7 @@ As in Standard C, up to three octal digits are accepted. (4) - Unlike in Standard C, at most two hex digits are accepted. + Unlike in Standard C, exactly two hex digits are required. (5) In a string literal, hexadecimal and octal escapes denote the byte with the From python-checkins at python.org Tue Jan 22 08:54:07 2008 From: python-checkins at python.org (georg.brandl) Date: Tue, 22 Jan 2008 08:54:07 +0100 (CET) Subject: [Python-checkins] r60194 - python/branches/release25-maint/Doc/ref/ref2.tex Message-ID: <20080122075407.723321E4003@bag.python.org> Author: georg.brandl Date: Tue Jan 22 08:54:07 2008 New Revision: 60194 Modified: python/branches/release25-maint/Doc/ref/ref2.tex Log: Backport: #1889 - fixup \xhh specs. Modified: python/branches/release25-maint/Doc/ref/ref2.tex ============================================================================== --- python/branches/release25-maint/Doc/ref/ref2.tex (original) +++ python/branches/release25-maint/Doc/ref/ref2.tex Tue Jan 22 08:54:07 2008 @@ -485,7 +485,7 @@ \item[(3)] As in Standard C, up to three octal digits are accepted. \item[(4)] - Unlike in Standard C, at most two hex digits are accepted. + Unlike in Standard C, exactly two hex digits are required. \item[(5)] In a string literal, hexadecimal and octal escapes denote the byte with the given value; it is not necessary that the byte From nnorwitz at gmail.com Tue Jan 22 11:26:49 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Tue, 22 Jan 2008 05:26:49 -0500 Subject: [Python-checkins] Python Regression Test Failures refleak (10) Message-ID: <20080122102649.GA31789@python.psfb.org> test_opcodes leaked [0, -2, 2] references, sum=0 test_doctest leaked [-2, 2, 0] references, sum=0 test_doctest2 leaked [-2, -2, 0] references, sum=-4 test_cmd_line leaked [-23, 0, 23] references, sum=0 test_descrtut leaked [2, 2, -2] references, sum=2 test_difflib leaked [0, -2, 0] references, sum=-2 test_gc leaked [-2, 0, 0] references, sum=-2 test_getargs2 leaked [0, -2, 0] references, sum=-2 test_importhooks leaked [-2, 2, -2] references, sum=-2 test_os leaked [-2, 2, 0] references, sum=0 test_plistlib leaked [0, -2, 0] references, sum=-2 test_ssl leaked [-2, 0, 0] references, sum=-2 test_threadedtempfile leaked [0, 0, 80] references, sum=80 test_threadsignals leaked [0, -8, 0] references, sum=-8 test_urllib2_localnet leaked [5, 4, 0] references, sum=9 test_urlparse leaked [-2, 0, 0] references, sum=-2 test_weakref leaked [0, -2, 2] references, sum=0 From nnorwitz at gmail.com Tue Jan 22 11:43:47 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Tue, 22 Jan 2008 05:43:47 -0500 Subject: [Python-checkins] Python Regression Test Failures all (1) Message-ID: <20080122104347.GA2401@python.psfb.org> test_grammar test_opcodes test_dict test_builtin test_exceptions test_types test_unittest test_doctest test_doctest2 test_MimeWriter test_StringIO test___all__ test___future__ test__locale test_abc test_abstract_numbers test_aepack test_aepack skipped -- No module named aepack test_al test_al skipped -- No module named al test_anydbm test_applesingle test_applesingle skipped -- No module named macostools test_array test_ast test_asynchat test_asyncore test_atexit test_audioop test_augassign test_base64 test_bastion test_bigaddrspace test_bigmem test_binascii test_binhex test_binop test_bisect test_bool test_bsddb test_bsddb185 test_bsddb185 skipped -- No module named bsddb185 test_bsddb3 test test_bsddb3 failed -- errors occurred; run in verbose mode for details test_buffer test_bufio test_bz2 test_cProfile test_calendar test_call test_capi test_cd test_cd skipped -- No module named cd test_cfgparser test_cgi test_charmapcodec test_cl test_cl skipped -- No module named cl test_class test_cmath test_cmd test_cmd_line test_cmd_line_script test_code test_codeccallbacks test_codecencodings_cn test_codecencodings_hk test_codecencodings_jp test_codecencodings_kr test_codecencodings_tw test_codecmaps_cn test_codecmaps_hk test_codecmaps_jp test_codecmaps_kr test_codecmaps_tw test_codecs test_codeop test_coding test_coercion test_collections test_colorsys test_commands test_compare test_compile test_compiler testCompileLibrary still working, be patient... test_complex test_complex_args test_contains test_contextlib test_cookie test_cookielib test_copy test_copy_reg test_cpickle test_crypt test_csv test_ctypes test_datetime test_dbm test_decimal test_decorators test_defaultdict test_deque test_descr test_descrtut test_difflib test_dircache test_dis test_distutils test_dl test_docxmlrpc test_dumbdbm test_dummy_thread test_dummy_threading test_email test_email_codecs test_email_renamed test_enumerate test_eof test_errno test_exception_variations test_extcall test_fcntl test_file test_filecmp test_fileinput test_float test_fnmatch test_fork1 test_format test_fpformat test_frozen test_ftplib test_funcattrs test_functools test_future test_gc test_gdbm test_generators test_genericpath test_genexps test_getargs test_getargs2 test_getopt test_gettext test_gl test_gl skipped -- No module named gl test_glob test_global test_grp test_gzip test_hash test_hashlib test_heapq test_hexoct test_hmac test_hotshot test_htmllib test_htmlparser test_httplib test_imageop test_imageop skipped -- No module named imgfile test_imaplib test_imgfile test_imgfile skipped -- No module named imgfile test_imp test_import test_importhooks test_index test_inspect test_ioctl test_ioctl skipped -- Unable to open /dev/tty test_isinstance test_iter test_iterlen test_itertools test_largefile test_list test_locale test_logging test_long test_long_future test_longexp test_macostools test_macostools skipped -- No module named macostools test_macpath test_mailbox test_marshal test_math test_md5 test_mhlib test_mimetools test_mimetypes test_minidom test_mmap test_module test_modulefinder test_multibytecodec test_multibytecodec_support test_multifile test_mutants test_netrc test_new test_nis test_normalization test_ntpath test_old_mailbox test_openpty test_operator test_optparse test_os test_parser test_peepholer test_pep247 test_pep263 test_pep277 test_pep277 skipped -- test works only on NT+ test_pep292 test_pep352 test_pickle test_pickletools test_pipes test_pkg test_pkgimport test_platform test_plistlib test_poll test_popen [8908 refs] [8908 refs] [8908 refs] test_popen2 test_poplib test_posix test_posixpath test_pow test_pprint test_profile test_profilehooks test_property test_pstats test_pty test_pwd test_pyclbr test_pyexpat test_queue test_quopri [9277 refs] [9277 refs] test_random test_rational test_re test_repr test_resource test_rfc822 test_richcmp test_robotparser test_runpy test_sax test_scope test_scriptpackages test_scriptpackages skipped -- No module named aetools test_select test_set test_sets test_sgmllib test_sha test_shelve test_shlex test_shutil test_signal test_site test_slice test_smtplib test_socket test_socket_ssl /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:94: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ssl_sock = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:60: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:130: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:144: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) test_socketserver test_softspace test_sort test_sqlite test_ssl test_startfile test_startfile skipped -- cannot import name startfile test_str test_strftime test_string test_stringprep test_strop test_strptime test_struct test_structmembers test_structseq test_subprocess [8903 refs] [8906 refs] [8903 refs] [8903 refs] [8903 refs] [8903 refs] [8903 refs] [8903 refs] [8903 refs] [8905 refs] [8906 refs] [10457 refs] [9121 refs] [8906 refs] [8903 refs] [8903 refs] [8903 refs] [8903 refs] [8903 refs] . [8903 refs] [8903 refs] this bit of output is from a test of stdout in a different process ... [8903 refs] [8903 refs] [9121 refs] test_sunaudiodev test_sunaudiodev skipped -- No module named sunaudiodev test_sundry test_symtable test_syntax test_sys [8903 refs] [8903 refs] test_tarfile test_tcl test_tcl skipped -- No module named _tkinter test_telnetlib test_tempfile [8909 refs] test_textwrap test_thread test_threaded_import test_threadedtempfile test_threading [13151 refs] test_threading_local test_threadsignals test_time test_timeout test_tokenize test_trace test_traceback test_transformer test_tuple test_typechecks test_ucn test_unary test_unicode test_unicode_file test_unicode_file skipped -- No Unicode filesystem semantics on this platform. test_unicodedata test_univnewlines test_unpack test_urllib test_urllib2 test_urllib2_localnet test_urllib2net test test_urllib2net failed -- Traceback (most recent call last): File "/tmp/python-test/local/lib/python2.6/test/test_urllib2net.py", line 175, in test_ftp self._test_urls(urls, self._extra_handlers()) File "/tmp/python-test/local/lib/python2.6/test/test_urllib2net.py", line 244, in _test_urls f = urllib2.urlopen(url, req) File "/tmp/python-test/local/lib/python2.6/urllib2.py", line 124, in urlopen return _opener.open(url, data, timeout) File "/tmp/python-test/local/lib/python2.6/urllib2.py", line 380, in open response = self._open(req, data) File "/tmp/python-test/local/lib/python2.6/urllib2.py", line 398, in _open '_open', req) File "/tmp/python-test/local/lib/python2.6/urllib2.py", line 358, in _call_chain result = func(*args) File "/tmp/python-test/local/lib/python2.6/urllib2.py", line 1284, in ftp_open fp, retrlen = fw.retrfile(file, type) File "/tmp/python-test/local/lib/python2.6/urllib.py", line 880, in retrfile self.ftp.cwd(file) File "/tmp/python-test/local/lib/python2.6/ftplib.py", line 538, in cwd return self.voidcmd(cmd) File "/tmp/python-test/local/lib/python2.6/ftplib.py", line 247, in voidcmd return self.voidresp() File "/tmp/python-test/local/lib/python2.6/ftplib.py", line 222, in voidresp resp = self.getresp() File "/tmp/python-test/local/lib/python2.6/ftplib.py", line 217, in getresp raise error_perm, resp TypeError: __init__() takes exactly 2 arguments (3 given) test_urllibnet test_urlparse test_userdict test_userlist test_userstring test_uu test_uuid WARNING: uuid.getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._ifconfig_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._unixdll_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. test_wait3 test_wait4 test_warnings test_wave test_weakref test_whichdb test_winreg test_winreg skipped -- No module named _winreg test_winsound test_winsound skipped -- No module named winsound test_with test_wsgiref test_xdrlib test_xml_etree test_xml_etree_c test_xmllib test_xmlrpc test_xpickle test_xrange test_zipfile /tmp/python-test/local/lib/python2.6/test/test_zipfile.py:471: DeprecationWarning: struct integer overflow masking is deprecated zipfp.close() /tmp/python-test/local/lib/python2.6/test/test_zipfile.py:398: DeprecationWarning: struct integer overflow masking is deprecated zipfp.close() test_zipfile64 test_zipfile64 skipped -- test requires loads of disk-space bytes and a long time to run test_zipimport test_zlib 314 tests OK. 2 tests failed: test_bsddb3 test_urllib2net 20 tests skipped: test_aepack test_al test_applesingle test_bsddb185 test_cd test_cl test_gl test_imageop test_imgfile test_ioctl test_macostools test_pep277 test_scriptpackages test_startfile test_sunaudiodev test_tcl test_unicode_file test_winreg test_winsound test_zipfile64 1 skip unexpected on linux2: test_ioctl [542327 refs] From python-checkins at python.org Tue Jan 22 12:13:43 2008 From: python-checkins at python.org (christian.heimes) Date: Tue, 22 Jan 2008 12:13:43 +0100 (CET) Subject: [Python-checkins] r60195 - python/branches/trunk-math Message-ID: <20080122111343.67F061E4019@bag.python.org> Author: christian.heimes Date: Tue Jan 22 12:13:43 2008 New Revision: 60195 Added: python/branches/trunk-math/ - copied from r60194, python/trunk/ Log: Creating a branch for Mark Dickinson's and my work on fixes and enhancements for Python's mathematical libraries. See #1640 and and #1381. From python-checkins at python.org Tue Jan 22 12:14:53 2008 From: python-checkins at python.org (christian.heimes) Date: Tue, 22 Jan 2008 12:14:53 +0100 (CET) Subject: [Python-checkins] r60196 - python/branches/trunk-math Message-ID: <20080122111453.C1DBB1E4019@bag.python.org> Author: christian.heimes Date: Tue Jan 22 12:14:53 2008 New Revision: 60196 Modified: python/branches/trunk-math/ (props changed) Log: svnmerge.py init From python-checkins at python.org Tue Jan 22 12:46:55 2008 From: python-checkins at python.org (christian.heimes) Date: Tue, 22 Jan 2008 12:46:55 +0100 (CET) Subject: [Python-checkins] r60197 - in python/branches/trunk-math: Doc/library/cmath.rst Doc/library/math.rst Doc/license.rst Include/Python.h Include/pymath.h Include/pyport.h Lib/test/cmath.ctest Lib/test/test_cmath.py Lib/test/test_math.py Makefile.pre.in Misc/NEWS Modules/cmathmodule.c Modules/mathmodule.c PC/pyconfig.h PCbuild/pythoncore.vcproj Python/hypot.c Python/pymath.c pyconfig.h.in Message-ID: <20080122114655.81D791E4019@bag.python.org> Author: christian.heimes Date: Tue Jan 22 12:46:53 2008 New Revision: 60197 Added: python/branches/trunk-math/Include/pymath.h (contents, props changed) python/branches/trunk-math/Lib/test/cmath.ctest python/branches/trunk-math/Python/pymath.c (contents, props changed) Removed: python/branches/trunk-math/Python/hypot.c Modified: python/branches/trunk-math/Doc/library/cmath.rst python/branches/trunk-math/Doc/library/math.rst python/branches/trunk-math/Doc/license.rst python/branches/trunk-math/Include/Python.h python/branches/trunk-math/Include/pyport.h python/branches/trunk-math/Lib/test/test_cmath.py python/branches/trunk-math/Lib/test/test_math.py python/branches/trunk-math/Makefile.pre.in python/branches/trunk-math/Misc/NEWS python/branches/trunk-math/Modules/cmathmodule.c python/branches/trunk-math/Modules/mathmodule.c python/branches/trunk-math/PC/pyconfig.h python/branches/trunk-math/PCbuild/pythoncore.vcproj python/branches/trunk-math/pyconfig.h.in Log: The patch is a joined effort of Mark and me. Mark implemented the cmath changes, the test values in cmath.ctest and the code for log1p and copysign. He also helped me to get the three replacements for the inverse hyperbolic functions right. The rest of pymath.[ch], mathmodule.c and the math tests were written by me. The test adds the inverse hyberbolic functions, log1p and copysign for platforms w/o the functions in their math lib. It also tries to set the handling of inf and nan straight but it's not perfect yet. Modified: python/branches/trunk-math/Doc/library/cmath.rst ============================================================================== --- python/branches/trunk-math/Doc/library/cmath.rst (original) +++ python/branches/trunk-math/Doc/library/cmath.rst Tue Jan 22 12:46:53 2008 @@ -14,6 +14,15 @@ floating-point number, respectively, and the function is then applied to the result of the conversion. +.. note:: + + On platforms with hardware and system-level support for signed + zeros, functions involving branch cuts are continuous on *both* + sides of the branch cut: the sign of the zero distinguishes one + side of the branch cut from the other. On platforms that do not + support signed zeros the continuity is as specified below. + + The functions are: @@ -37,30 +46,35 @@ .. function:: asinh(x) - Return the hyperbolic arc sine of *x*. There are two branch cuts, extending - left from ``?1j`` to ``??j``, both continuous from above. These branch cuts - should be considered a bug to be corrected in a future release. The correct - branch cuts should extend along the imaginary axis, one from ``1j`` up to - ``?j`` and continuous from the right, and one from ``-1j`` down to ``-?j`` - and continuous from the left. + Return the hyperbolic arc sine of *x*. There are two branch cuts: + One extends from ``1j`` along the imaginary axis to ``?j``, + continuous from the right. The other extends from ``-1j`` along + the imaginary axis to ``-?j``, continuous from the left. + + .. versionchanged:: 2.6 + branch cuts moved to match those recommended by the C99 standard .. function:: atan(x) Return the arc tangent of *x*. There are two branch cuts: One extends from - ``1j`` along the imaginary axis to ``?j``, continuous from the left. The + ``1j`` along the imaginary axis to ``?j``, continuous from the right. The other extends from ``-1j`` along the imaginary axis to ``-?j``, continuous - from the left. (This should probably be changed so the upper cut becomes - continuous from the other side.) + from the left. + + .. versionchanged:: 2.6 + direction of continuity of upper cut reversed .. function:: atanh(x) Return the hyperbolic arc tangent of *x*. There are two branch cuts: One - extends from ``1`` along the real axis to ``?``, continuous from above. The + extends from ``1`` along the real axis to ``?``, continuous from below. The other extends from ``-1`` along the real axis to ``-?``, continuous from - above. (This should probably be changed so the right cut becomes continuous - from the other side.) + above. + + .. versionchanged:: 2.6 + direction of continuity of right cut reversed .. function:: cos(x) @@ -154,3 +168,4 @@ nothing's sign bit. In Iserles, A., and Powell, M. (eds.), The state of the art in numerical analysis. Clarendon Press (1987) pp165-211. + Modified: python/branches/trunk-math/Doc/library/math.rst ============================================================================== --- python/branches/trunk-math/Doc/library/math.rst (original) +++ python/branches/trunk-math/Doc/library/math.rst Tue Jan 22 12:46:53 2008 @@ -131,6 +131,15 @@ *base* argument added. +.. function:: log1p(x[, base]) + + Return the logarithm of *1+x* to the given *base*. If the *base* is not specified, + return the natural logarithm of *1+x* (that is, the logarithm to base *e*). The + result is calculated in a way which is accurate for *x* near zero. + + .. versionadded:: 2.6 + + .. function:: log10(x) Return the base-10 logarithm of *x*. @@ -189,6 +198,13 @@ Return the sine of *x* radians. +.. function:: asinh(x) + + Return the inverse hyperbolic sine of *x*, in radians. + + .. versionadded:: 2.6 + + .. function:: tan(x) Return the tangent of *x* radians. @@ -213,6 +229,13 @@ Return the hyperbolic cosine of *x*. +.. function:: acosh(x) + + Return the inverse hyperbolic cosine of *x*, in radians. + + .. versionadded:: 2.6 + + .. function:: sinh(x) Return the hyperbolic sine of *x*. @@ -222,6 +245,14 @@ Return the hyperbolic tangent of *x*. + +.. function:: atanh(x) + + Return the inverse hyperbolic tangent of *x*, in radians. + + .. versionadded:: 2.6 + + The module also defines two mathematical constants: @@ -234,6 +265,7 @@ The mathematical constant *e*. + .. note:: The :mod:`math` module consists mostly of thin wrappers around the platform C @@ -247,6 +279,15 @@ :exc:`OverflowError` isn't defined, and in cases where ``math.log(0)`` raises :exc:`OverflowError`, ``math.log(0L)`` may raise :exc:`ValueError` instead. + All functions return a quite *NaN* if at least one of the args is *NaN*. + Signaling *NaN*s raise an exception. The exception type still depends on the + platform and libm implementation. It's usually :exc:`ValueError` for *EDOM* + and :exc:`OverflowError` for errno *ERANGE*. + + ..versionchanged:: 2.6 + In earlier versions of Python the outcome of an operation with NaN as + input depended on platform and libm implementation. + .. seealso:: Modified: python/branches/trunk-math/Doc/license.rst ============================================================================== --- python/branches/trunk-math/Doc/license.rst (original) +++ python/branches/trunk-math/Doc/license.rst Tue Jan 22 12:46:53 2008 @@ -645,3 +645,15 @@ ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + +Python/pymath.c +--------------- + +The :file:`Python/pymath.c` module contains the following notice:: + + Copyright (C) 1993 by Sun Microsystems, Inc. All rights reserved. + + Developed at SunPro, a Sun Microsystems, Inc. business. + Permission to use, copy, modify, and distribute this + software is freely granted, provided that this notice + is preserved. Modified: python/branches/trunk-math/Include/Python.h ============================================================================== --- python/branches/trunk-math/Include/Python.h (original) +++ python/branches/trunk-math/Include/Python.h Tue Jan 22 12:46:53 2008 @@ -73,6 +73,7 @@ #if defined(PYMALLOC_DEBUG) && !defined(WITH_PYMALLOC) #error "PYMALLOC_DEBUG requires WITH_PYMALLOC" #endif +#include "pymath.h" #include "pymem.h" #include "object.h" Added: python/branches/trunk-math/Include/pymath.h ============================================================================== --- (empty file) +++ python/branches/trunk-math/Include/pymath.h Tue Jan 22 12:46:53 2008 @@ -0,0 +1,175 @@ +#ifndef Py_PYMATH_H +#define Py_PYMATH_H + +#include "pyconfig.h" /* include for defines */ + +#ifdef HAVE_STDINT_H +#include +#endif + +/************************************************************************** +Symbols and macros to supply platform-independent interfaces to mathematical +functions and constants +**************************************************************************/ + +/* Python provides implementations for copysign, acosh, asinh, atanh, + * log1p and hypot in Python/pymath.c just in case your math library doesn't + * provide the functions. + * + *Note: PC/pyconfig.h defines copysign as _copysign + */ +#ifndef HAVE_COPYSIGN +extern double copysign(doube, double); +#endif + +#ifndef HAVE_ACOSH +extern double acosh(double); +#endif + +#ifndef HAVE_ASINH +extern double asinh(double); +#endif + +#ifndef HAVE_ATANH +extern double atanh(double); +#endif + +#ifndef HAVE_LOG1P +extern double log1p(double); +#endif + +#ifndef HAVE_HYPOT +extern double hypot(double, double); +#endif + +/* extra declarations */ +#ifndef _MSC_VER +#ifndef __STDC__ +extern double fmod (double, double); +extern double frexp (double, int *); +extern double ldexp (double, int); +extern double modf (double, double *); +#endif /* __STDC__ */ +#endif /* _MSC_VER */ + +/* High precision defintion of pi and e (Euler) + * The values are taken from libc6's math.h. + */ +#ifndef Py_MATH_PIl +#define Py_MATH_PIl 3.1415926535897932384626433832795029L +#endif +#ifndef Py_MATH_PI +#define Py_MATH_PI 3.14159265358979323846 +#endif + +#ifndef Py_MATH_El +#define Py_MATH_El 2.7182818284590452353602874713526625L +#endif + +#ifndef Py_MATH_E +#define Py_MATH_E 2.7182818284590452354 +#endif + +/* Py_IS_NAN(X) + * Return 1 if float or double arg is a NaN, else 0. + * Caution: + * X is evaluated more than once. + * This may not work on all platforms. Each platform has *some* + * way to spell this, though -- override in pyconfig.h if you have + * a platform where it doesn't work. + * Note: PC/pyconfig.h defines Py_IS_NAN as _isnan + */ +#ifndef Py_IS_NAN +#ifdef HAVE_ISNAN +#define Py_IS_NAN(X) isnan(X) +#else +#define Py_IS_NAN(X) ((X) != (X)) +#endif +#endif + +/* Py_IS_INFINITY(X) + * Return 1 if float or double arg is an infinity, else 0. + * Caution: + * X is evaluated more than once. + * This implementation may set the underflow flag if |X| is very small; + * it really can't be implemented correctly (& easily) before C99. + * Override in pyconfig.h if you have a better spelling on your platform. + * Note: PC/pyconfig.h defines Py_IS_INFINITY as _isinf + */ +#ifndef Py_IS_INFINITY +#ifdef HAVE_ISINF +#define Py_IS_INFINITY(X) isinf(X) +#else +#define Py_IS_INFINITY(X) ((X) && (X)*0.5 == (X)) +#endif +#endif + +/* Py_IS_FINITE(X) + * Return 1 if float or double arg is neither infinite nor NAN, else 0. + * Some compilers (e.g. VisualStudio) have intrisics for this, so a special + * macro for this particular test is useful + * Note: PC/pyconfig.h defines Py_IS_FINITE as _finite + */ +#ifndef Py_IS_FINITE +#ifdef HAVE_FINITE +#define Py_IS_FINITE(X) finite(X) +#else +#define Py_IS_FINITE(X) (!Py_IS_INFINITY(X) && !Py_IS_NAN(X)) +#endif +#endif + +/* HUGE_VAL is supposed to expand to a positive double infinity. Python + * uses Py_HUGE_VAL instead because some platforms are broken in this + * respect. We used to embed code in pyport.h to try to worm around that, + * but different platforms are broken in conflicting ways. If you're on + * a platform where HUGE_VAL is defined incorrectly, fiddle your Python + * config to #define Py_HUGE_VAL to something that works on your platform. + */ +#ifndef Py_HUGE_VAL +#define Py_HUGE_VAL HUGE_VAL +#endif + +/* Py_NAN + * A value that evaluates to a NaN. On IEEE 754 platforms INF*0 or + * INF/INF works. Define Py_NO_NAN in pyconfig.h if your platform + * doesn't support NaNs. + */ +#if !defined(Py_NAN) && !defined(Py_NO_NAN) +#define Py_NAN (Py_HUGE_VAL * 0.) +#endif + +/* Py_OVERFLOWED(X) + * Return 1 iff a libm function overflowed. Set errno to 0 before calling + * a libm function, and invoke this macro after, passing the function + * result. + * Caution: + * This isn't reliable. C99 no longer requires libm to set errno under + * any exceptional condition, but does require +- HUGE_VAL return + * values on overflow. A 754 box *probably* maps HUGE_VAL to a + * double infinity, and we're cool if that's so, unless the input + * was an infinity and an infinity is the expected result. A C89 + * system sets errno to ERANGE, so we check for that too. We're + * out of luck if a C99 754 box doesn't map HUGE_VAL to +Inf, or + * if the returned result is a NaN, or if a C89 box returns HUGE_VAL + * in non-overflow cases. + * X is evaluated more than once. + * Some platforms have better way to spell this, so expect some #ifdef'ery. + * + * OpenBSD uses 'isinf()' because a compiler bug on that platform causes + * the longer macro version to be mis-compiled. This isn't optimal, and + * should be removed once a newer compiler is available on that platform. + * The system that had the failure was running OpenBSD 3.2 on Intel, with + * gcc 2.95.3. + * + * According to Tim's checkin, the FreeBSD systems use isinf() to work + * around a FPE bug on that platform. + */ +#if defined(__FreeBSD__) || defined(__OpenBSD__) +#define Py_OVERFLOWED(X) isinf(X) +#else +#define Py_OVERFLOWED(X) ((X) != 0.0 && (errno == ERANGE || \ + (X) == Py_HUGE_VAL || \ + (X) == -Py_HUGE_VAL)) +#endif + +#endif /* Py_PYMATH_H */ Modified: python/branches/trunk-math/Include/pyport.h ============================================================================== --- python/branches/trunk-math/Include/pyport.h (original) +++ python/branches/trunk-math/Include/pyport.h Tue Jan 22 12:46:53 2008 @@ -349,123 +349,6 @@ #define Py_SAFE_DOWNCAST(VALUE, WIDE, NARROW) (NARROW)(VALUE) #endif -/* High precision defintion of pi and e (Euler) - * The values are taken from libc6's math.h. - */ -#ifndef Py_MATH_PIl -#define Py_MATH_PIl 3.1415926535897932384626433832795029L -#endif -#ifndef Py_MATH_PI -#define Py_MATH_PI 3.14159265358979323846 -#endif - -#ifndef Py_MATH_El -#define Py_MATH_El 2.7182818284590452353602874713526625L -#endif - -#ifndef Py_MATH_E -#define Py_MATH_E 2.7182818284590452354 -#endif - -/* Py_IS_NAN(X) - * Return 1 if float or double arg is a NaN, else 0. - * Caution: - * X is evaluated more than once. - * This may not work on all platforms. Each platform has *some* - * way to spell this, though -- override in pyconfig.h if you have - * a platform where it doesn't work. - */ -#ifndef Py_IS_NAN -#ifdef HAVE_ISNAN -#define Py_IS_NAN(X) isnan(X) -#else -#define Py_IS_NAN(X) ((X) != (X)) -#endif -#endif - -/* Py_IS_INFINITY(X) - * Return 1 if float or double arg is an infinity, else 0. - * Caution: - * X is evaluated more than once. - * This implementation may set the underflow flag if |X| is very small; - * it really can't be implemented correctly (& easily) before C99. - * Override in pyconfig.h if you have a better spelling on your platform. - */ -#ifndef Py_IS_INFINITY -#ifdef HAVE_ISINF -#define Py_IS_INFINITY(X) isinf(X) -#else -#define Py_IS_INFINITY(X) ((X) && (X)*0.5 == (X)) -#endif -#endif - -/* Py_IS_FINITE(X) - * Return 1 if float or double arg is neither infinite nor NAN, else 0. - * Some compilers (e.g. VisualStudio) have intrisics for this, so a special - * macro for this particular test is useful - */ -#ifndef Py_IS_FINITE -#ifdef HAVE_FINITE -#define Py_IS_FINITE(X) finite -#else -#define Py_IS_FINITE(X) (!Py_IS_INFINITY(X) && !Py_IS_NAN(X)) -#endif -#endif - -/* HUGE_VAL is supposed to expand to a positive double infinity. Python - * uses Py_HUGE_VAL instead because some platforms are broken in this - * respect. We used to embed code in pyport.h to try to worm around that, - * but different platforms are broken in conflicting ways. If you're on - * a platform where HUGE_VAL is defined incorrectly, fiddle your Python - * config to #define Py_HUGE_VAL to something that works on your platform. - */ -#ifndef Py_HUGE_VAL -#define Py_HUGE_VAL HUGE_VAL -#endif - -/* Py_NAN - * A value that evaluates to a NaN. On IEEE 754 platforms INF*0 or - * INF/INF works. Define Py_NO_NAN in pyconfig.h if your platform - * doesn't support NaNs. - */ -#if !defined(Py_NAN) && !defined(Py_NO_NAN) -#define Py_NAN (Py_HUGE_VAL * 0.) -#endif - -/* Py_OVERFLOWED(X) - * Return 1 iff a libm function overflowed. Set errno to 0 before calling - * a libm function, and invoke this macro after, passing the function - * result. - * Caution: - * This isn't reliable. C99 no longer requires libm to set errno under - * any exceptional condition, but does require +- HUGE_VAL return - * values on overflow. A 754 box *probably* maps HUGE_VAL to a - * double infinity, and we're cool if that's so, unless the input - * was an infinity and an infinity is the expected result. A C89 - * system sets errno to ERANGE, so we check for that too. We're - * out of luck if a C99 754 box doesn't map HUGE_VAL to +Inf, or - * if the returned result is a NaN, or if a C89 box returns HUGE_VAL - * in non-overflow cases. - * X is evaluated more than once. - * Some platforms have better way to spell this, so expect some #ifdef'ery. - * - * OpenBSD uses 'isinf()' because a compiler bug on that platform causes - * the longer macro version to be mis-compiled. This isn't optimal, and - * should be removed once a newer compiler is available on that platform. - * The system that had the failure was running OpenBSD 3.2 on Intel, with - * gcc 2.95.3. - * - * According to Tim's checkin, the FreeBSD systems use isinf() to work - * around a FPE bug on that platform. - */ -#if defined(__FreeBSD__) || defined(__OpenBSD__) -#define Py_OVERFLOWED(X) isinf(X) -#else -#define Py_OVERFLOWED(X) ((X) != 0.0 && (errno == ERANGE || \ - (X) == Py_HUGE_VAL || \ - (X) == -Py_HUGE_VAL)) -#endif - /* Py_SET_ERRNO_ON_MATH_ERROR(x) * If a libm function did not set errno, but it looks like the result * overflowed or not-a-number, set errno to ERANGE or EDOM. Set errno @@ -597,15 +480,6 @@ #endif /* 0 */ -/************************ - * WRAPPER FOR * - ************************/ - -#ifndef HAVE_HYPOT -extern double hypot(double, double); -#endif - - /* On 4.4BSD-descendants, ctype functions serves the whole range of * wchar_t character set rather than single byte code points only. * This characteristic can break some operations of string object Added: python/branches/trunk-math/Lib/test/cmath.ctest ============================================================================== --- (empty file) +++ python/branches/trunk-math/Lib/test/cmath.ctest Tue Jan 22 12:46:53 2008 @@ -0,0 +1,1276 @@ +-- Testcases for functions in cmath. +-- +-- Each line takes the form: +-- +-- -> +-- +-- where: +-- is a short name identifying the test, +-- is the function to be tested (exp, cos, asinh, ...), +-- is a pair of floats separated by whitespace +-- representing real and imaginary parts of a complex number, and +-- is the expected (ideal) output value, again +-- represented as a pair of floats. +-- +-- Lines beginning with '--' (like this one) start a comment, and are +-- ignored. Blank lines, or lines containing only whitespace, are also +-- ignored. +-- + +-------------------------- +-- acos: Inverse cosine -- +-------------------------- + +-- zeros +acos0000 acos 0.0 0.0 -> 1.5707963267948966 -0.0 +acos0001 acos 0.0 -0.0 -> 1.5707963267948966 0.0 +acos0002 acos -0.0 0.0 -> 1.5707963267948966 -0.0 +acos0003 acos -0.0 -0.0 -> 1.5707963267948966 0.0 + +-- branch points: +/-1 +acos0010 acos 1.0 0.0 -> 0.0 -0.0 +acos0011 acos 1.0 -0.0 -> 0.0 0.0 +acos0012 acos -1.0 0.0 -> 3.1415926535897931 -0.0 +acos0013 acos -1.0 -0.0 -> 3.1415926535897931 0.0 + +-- values along both sides of real axis +acos0020 acos -9.8813129168249309e-324 0.0 -> 1.5707963267948966 -0.0 +acos0021 acos -9.8813129168249309e-324 -0.0 -> 1.5707963267948966 0.0 +acos0022 acos -1e-305 0.0 -> 1.5707963267948966 -0.0 +acos0023 acos -1e-305 -0.0 -> 1.5707963267948966 0.0 +acos0024 acos -1e-150 0.0 -> 1.5707963267948966 -0.0 +acos0025 acos -1e-150 -0.0 -> 1.5707963267948966 0.0 +acos0026 acos -9.9999999999999998e-17 0.0 -> 1.5707963267948968 -0.0 +acos0027 acos -9.9999999999999998e-17 -0.0 -> 1.5707963267948968 0.0 +acos0028 acos -0.001 0.0 -> 1.5717963269615634 -0.0 +acos0029 acos -0.001 -0.0 -> 1.5717963269615634 0.0 +acos0030 acos -0.57899999999999996 0.0 -> 2.1882979816120667 -0.0 +acos0031 acos -0.57899999999999996 -0.0 -> 2.1882979816120667 0.0 +acos0032 acos -0.99999999999999989 0.0 -> 3.1415926386886319 -0.0 +acos0033 acos -0.99999999999999989 -0.0 -> 3.1415926386886319 0.0 +acos0034 acos -1.0000000000000002 0.0 -> 3.1415926535897931 -2.1073424255447014e-08 +acos0035 acos -1.0000000000000002 -0.0 -> 3.1415926535897931 2.1073424255447014e-08 +acos0036 acos -1.0009999999999999 0.0 -> 3.1415926535897931 -0.044717633608306849 +acos0037 acos -1.0009999999999999 -0.0 -> 3.1415926535897931 0.044717633608306849 +acos0038 acos -2.0 0.0 -> 3.1415926535897931 -1.3169578969248168 +acos0039 acos -2.0 -0.0 -> 3.1415926535897931 1.3169578969248168 +acos0040 acos -23.0 0.0 -> 3.1415926535897931 -3.8281684713331012 +acos0041 acos -23.0 -0.0 -> 3.1415926535897931 3.8281684713331012 +acos0042 acos -10000000000000000.0 0.0 -> 3.1415926535897931 -37.534508668464674 +acos0043 acos -10000000000000000.0 -0.0 -> 3.1415926535897931 37.534508668464674 +acos0044 acos -9.9999999999999998e+149 0.0 -> 3.1415926535897931 -346.08091112966679 +acos0045 acos -9.9999999999999998e+149 -0.0 -> 3.1415926535897931 346.08091112966679 +acos0046 acos -1.0000000000000001e+299 0.0 -> 3.1415926535897931 -689.16608998577965 +acos0047 acos -1.0000000000000001e+299 -0.0 -> 3.1415926535897931 689.16608998577965 +acos0048 acos 9.8813129168249309e-324 0.0 -> 1.5707963267948966 -0.0 +acos0049 acos 9.8813129168249309e-324 -0.0 -> 1.5707963267948966 0.0 +acos0050 acos 1e-305 0.0 -> 1.5707963267948966 -0.0 +acos0051 acos 1e-305 -0.0 -> 1.5707963267948966 0.0 +acos0052 acos 1e-150 0.0 -> 1.5707963267948966 -0.0 +acos0053 acos 1e-150 -0.0 -> 1.5707963267948966 0.0 +acos0054 acos 9.9999999999999998e-17 0.0 -> 1.5707963267948966 -0.0 +acos0055 acos 9.9999999999999998e-17 -0.0 -> 1.5707963267948966 0.0 +acos0056 acos 0.001 0.0 -> 1.56979632662823 -0.0 +acos0057 acos 0.001 -0.0 -> 1.56979632662823 0.0 +acos0058 acos 0.57899999999999996 0.0 -> 0.95329467197772655 -0.0 +acos0059 acos 0.57899999999999996 -0.0 -> 0.95329467197772655 0.0 +acos0060 acos 0.99999999999999989 0.0 -> 1.4901161193847656e-08 -0.0 +acos0061 acos 0.99999999999999989 -0.0 -> 1.4901161193847656e-08 0.0 +acos0062 acos 1.0000000000000002 0.0 -> 0.0 -2.1073424255447014e-08 +acos0063 acos 1.0000000000000002 -0.0 -> 0.0 2.1073424255447014e-08 +acos0064 acos 1.0009999999999999 0.0 -> 0.0 -0.044717633608306849 +acos0065 acos 1.0009999999999999 -0.0 -> 0.0 0.044717633608306849 +acos0066 acos 2.0 0.0 -> 0.0 -1.3169578969248168 +acos0067 acos 2.0 -0.0 -> 0.0 1.3169578969248168 +acos0068 acos 23.0 0.0 -> 0.0 -3.8281684713331012 +acos0069 acos 23.0 -0.0 -> 0.0 3.8281684713331012 +acos0070 acos 10000000000000000.0 0.0 -> 0.0 -37.534508668464674 +acos0071 acos 10000000000000000.0 -0.0 -> 0.0 37.534508668464674 +acos0072 acos 9.9999999999999998e+149 0.0 -> 0.0 -346.08091112966679 +acos0073 acos 9.9999999999999998e+149 -0.0 -> 0.0 346.08091112966679 +acos0074 acos 1.0000000000000001e+299 0.0 -> 0.0 -689.16608998577965 +acos0075 acos 1.0000000000000001e+299 -0.0 -> 0.0 689.16608998577965 + +-- random inputs +acos0100 acos -3.3307113324596682 -10.732007530863266 -> 1.8706085694482339 3.113986806554613 +acos0101 acos -2863.952991743291 -2681013315.2571239 -> 1.5707973950301699 22.402607843274758 +acos0102 acos -0.33072639793220088 -0.85055464658253055 -> 1.8219426895922601 0.79250166729311966 +acos0103 acos -2.5722325842097802 -12.703940809821574 -> 1.7699942413107408 3.2565170156527325 +acos0104 acos -42.495233785459583 -0.54039320751337161 -> 3.1288732573153304 4.4424815519735601 +acos0105 acos -1.1363818625856401 9641.1325498630376 -> 1.5709141948820049 -9.8669410553254284 +acos0106 acos -2.4398426824157866e-11 0.33002051890266165 -> 1.570796326818066 -0.32430578041578667 +acos0107 acos -1.3521340428186552 2.9369737912076772 -> 1.9849059192339338 -1.8822893674117942 +acos0108 acos -1.827364706477915 1.0355459232147557 -> 2.5732246307960032 -1.4090688267854969 +acos0109 acos -0.25978373706403546 10.09712669185833 -> 1.5963940386378306 -3.0081673050196063 +acos0110 acos 0.33561778471072551 -4587350.6823999118 -> 1.5707962536333251 16.031960402579539 +acos0111 acos 0.49133444610998445 -0.8071422362990015 -> 1.1908761712801788 0.78573345813187867 +acos0112 acos 0.42196734507823974 -2.4812965431745115 -> 1.414091186100692 1.651707260988172 +acos0113 acos 2.961426210100655 -219.03295695248664 -> 1.5572768319822778 6.0824659885827304 +acos0114 acos 2.886209063652641 -20.38011207220606 -> 1.4302765252297889 3.718201853147642 +acos0115 acos 0.4180568075276509 1.4833433990823484 -> 1.3393834558303042 -1.2079847758301576 +acos0116 acos 52.376111405924718 0.013930429001941001 -> 0.00026601761804024188 -4.6515066691204714 +acos0117 acos 41637948387.625969 1.563418292894041 -> 3.7547918507883548e-11 -25.145424989809381 +acos0118 acos 0.061226659122249526 0.8447234394615154 -> 1.5240280306367315 -0.76791798971140812 +acos0119 acos 2.4480466420442959e+26 0.18002339201384662 -> 7.353756620564798e-28 -61.455650015996376 + +-- values near infinity +acos0200 acos 1.6206860518683021e+308 1.0308426226285283e+308 -> 0.56650826093826223 -710.54206874241561 +acos0201 acos 1.2067735875070062e+308 -1.3429173724390276e+308 -> 0.83874369390864889 710.48017794027498 +acos0202 acos -7.4130145132549047e+307 1.1759130543927645e+308 -> 2.1332729346478536 -710.21871115698752 +acos0203 acos -8.6329426442257249e+307 -1.2316282952184133e+308 -> 2.1821511032444838 710.29752145697148 +acos0204 acos 0.0 1.4289713855849746e+308 -> 1.5707963267948966 -710.24631069738996 +acos0205 acos -0.0 1.3153524545987432e+308 -> 1.5707963267948966 -710.1634604787539 +acos0206 acos 0.0 -9.6229037669269321e+307 -> 1.5707963267948966 709.85091679573691 +acos0207 acos -0.0 -4.9783616421107088e+307 -> 1.5707963267948966 709.19187157911233 +acos0208 acos 1.3937541925739389e+308 0.0 -> 0.0 -710.22135678707264 +acos0209 acos 9.1362388967371536e+307 -0.0 -> 0.0 709.79901953124613 +acos0210 acos -1.3457361220697436e+308 0.0 -> 3.1415926535897931 -710.18629698871848 +acos0211 acos -5.4699090056144284e+307 -0.0 -> 3.1415926535897931 709.28603271085649 +acos0212 acos 1.5880716932358901e+308 5.5638401252339929 -> 3.503519487773873e-308 -710.35187633140583 +acos0213 acos 1.2497211663463164e+308 -3.0456477717911024 -> 2.4370618453197486e-308 710.11227628223412 +acos0214 acos -9.9016224006029528e+307 4.9570427340789056 -> 3.1415926535897931 -709.87946935229468 +acos0215 acos -1.5854071066874139e+308 -4.4233577741497783 -> 3.1415926535897931 710.35019704672004 +acos0216 acos 9.3674623083647628 1.5209559051877979e+308 -> 1.5707963267948966 -710.30869484491086 +acos0217 acos 8.1773832021784383 -6.6093445795000056e+307 -> 1.5707963267948966 709.4752552227792 +acos0218 acos -3.1845935000665104 1.5768856396650893e+308 -> 1.5707963267948966 -710.34480761042687 +acos0219 acos -1.0577303880953903 -6.4574626815735613e+307 -> 1.5707963267948966 709.45200719662046 + +-- values near 0 +acos0220 acos 1.8566986970714045e-320 3.1867234156760402e-321 -> 1.5707963267948966 -3.1867234156760402e-321 +acos0221 acos 7.9050503334599447e-323 -8.8931816251424378e-323 -> 1.5707963267948966 8.8931816251424378e-323 +acos0222 acos -4.4465908125712189e-323 2.4654065097222727e-311 -> 1.5707963267948966 -2.4654065097222727e-311 +acos0223 acos -6.1016916408192619e-311 -2.4703282292062327e-323 -> 1.5707963267948966 2.4703282292062327e-323 +acos0224 acos 0.0 3.4305783621842729e-311 -> 1.5707963267948966 -3.4305783621842729e-311 +acos0225 acos -0.0 1.6117409498633145e-319 -> 1.5707963267948966 -1.6117409498633145e-319 +acos0226 acos 0.0 -4.9900630229965901e-322 -> 1.5707963267948966 4.9900630229965901e-322 +acos0227 acos -0.0 -4.4889279210592818e-311 -> 1.5707963267948966 4.4889279210592818e-311 +acos0228 acos 5.3297678681477214e-312 0.0 -> 1.5707963267948966 -0.0 +acos0229 acos 6.2073425897211614e-313 -0.0 -> 1.5707963267948966 0.0 +acos0230 acos -4.9406564584124654e-324 0.0 -> 1.5707963267948966 -0.0 +acos0231 acos -1.7107517052899003e-318 -0.0 -> 1.5707963267948966 0.0 + +-------------------------------------- +-- acosh: Inverse hyperbolic cosine -- +-------------------------------------- + +-- zeros +acosh0000 acosh 0.0 0.0 -> 0.0 1.5707963267948966 +acosh0001 acosh 0.0 -0.0 -> 0.0 -1.5707963267948966 +acosh0002 acosh -0.0 0.0 -> 0.0 1.5707963267948966 +acosh0003 acosh -0.0 -0.0 -> 0.0 -1.5707963267948966 + +-- branch points: +/-1 +acosh0010 acosh 1.0 0.0 -> 0.0 0.0 +acosh0011 acosh 1.0 -0.0 -> 0.0 -0.0 +acosh0012 acosh -1.0 0.0 -> 0.0 3.1415926535897931 +acosh0013 acosh -1.0 -0.0 -> 0.0 -3.1415926535897931 + +-- values along both sides of real axis +acosh0020 acosh -9.8813129168249309e-324 0.0 -> 0.0 1.5707963267948966 +acosh0021 acosh -9.8813129168249309e-324 -0.0 -> 0.0 -1.5707963267948966 +acosh0022 acosh -1e-305 0.0 -> 0.0 1.5707963267948966 +acosh0023 acosh -1e-305 -0.0 -> 0.0 -1.5707963267948966 +acosh0024 acosh -1e-150 0.0 -> 0.0 1.5707963267948966 +acosh0025 acosh -1e-150 -0.0 -> 0.0 -1.5707963267948966 +acosh0026 acosh -9.9999999999999998e-17 0.0 -> 0.0 1.5707963267948968 +acosh0027 acosh -9.9999999999999998e-17 -0.0 -> 0.0 -1.5707963267948968 +acosh0028 acosh -0.001 0.0 -> 0.0 1.5717963269615634 +acosh0029 acosh -0.001 -0.0 -> 0.0 -1.5717963269615634 +acosh0030 acosh -0.57899999999999996 0.0 -> 0.0 2.1882979816120667 +acosh0031 acosh -0.57899999999999996 -0.0 -> 0.0 -2.1882979816120667 +acosh0032 acosh -0.99999999999999989 0.0 -> 0.0 3.1415926386886319 +acosh0033 acosh -0.99999999999999989 -0.0 -> 0.0 -3.1415926386886319 +acosh0034 acosh -1.0000000000000002 0.0 -> 2.1073424255447014e-08 3.1415926535897931 +acosh0035 acosh -1.0000000000000002 -0.0 -> 2.1073424255447014e-08 -3.1415926535897931 +acosh0036 acosh -1.0009999999999999 0.0 -> 0.044717633608306849 3.1415926535897931 +acosh0037 acosh -1.0009999999999999 -0.0 -> 0.044717633608306849 -3.1415926535897931 +acosh0038 acosh -2.0 0.0 -> 1.3169578969248168 3.1415926535897931 +acosh0039 acosh -2.0 -0.0 -> 1.3169578969248168 -3.1415926535897931 +acosh0040 acosh -23.0 0.0 -> 3.8281684713331012 3.1415926535897931 +acosh0041 acosh -23.0 -0.0 -> 3.8281684713331012 -3.1415926535897931 +acosh0042 acosh -10000000000000000.0 0.0 -> 37.534508668464674 3.1415926535897931 +acosh0043 acosh -10000000000000000.0 -0.0 -> 37.534508668464674 -3.1415926535897931 +acosh0044 acosh -9.9999999999999998e+149 0.0 -> 346.08091112966679 3.1415926535897931 +acosh0045 acosh -9.9999999999999998e+149 -0.0 -> 346.08091112966679 -3.1415926535897931 +acosh0046 acosh -1.0000000000000001e+299 0.0 -> 689.16608998577965 3.1415926535897931 +acosh0047 acosh -1.0000000000000001e+299 -0.0 -> 689.16608998577965 -3.1415926535897931 +acosh0048 acosh 9.8813129168249309e-324 0.0 -> 0.0 1.5707963267948966 +acosh0049 acosh 9.8813129168249309e-324 -0.0 -> 0.0 -1.5707963267948966 +acosh0050 acosh 1e-305 0.0 -> 0.0 1.5707963267948966 +acosh0051 acosh 1e-305 -0.0 -> 0.0 -1.5707963267948966 +acosh0052 acosh 1e-150 0.0 -> 0.0 1.5707963267948966 +acosh0053 acosh 1e-150 -0.0 -> 0.0 -1.5707963267948966 +acosh0054 acosh 9.9999999999999998e-17 0.0 -> 0.0 1.5707963267948966 +acosh0055 acosh 9.9999999999999998e-17 -0.0 -> 0.0 -1.5707963267948966 +acosh0056 acosh 0.001 0.0 -> 0.0 1.56979632662823 +acosh0057 acosh 0.001 -0.0 -> 0.0 -1.56979632662823 +acosh0058 acosh 0.57899999999999996 0.0 -> 0.0 0.95329467197772655 +acosh0059 acosh 0.57899999999999996 -0.0 -> 0.0 -0.95329467197772655 +acosh0060 acosh 0.99999999999999989 0.0 -> 0.0 1.4901161193847656e-08 +acosh0061 acosh 0.99999999999999989 -0.0 -> 0.0 -1.4901161193847656e-08 +acosh0062 acosh 1.0000000000000002 0.0 -> 2.1073424255447014e-08 0.0 +acosh0063 acosh 1.0000000000000002 -0.0 -> 2.1073424255447014e-08 -0.0 +acosh0064 acosh 1.0009999999999999 0.0 -> 0.044717633608306849 0.0 +acosh0065 acosh 1.0009999999999999 -0.0 -> 0.044717633608306849 -0.0 +acosh0066 acosh 2.0 0.0 -> 1.3169578969248168 0.0 +acosh0067 acosh 2.0 -0.0 -> 1.3169578969248168 -0.0 +acosh0068 acosh 23.0 0.0 -> 3.8281684713331012 0.0 +acosh0069 acosh 23.0 -0.0 -> 3.8281684713331012 -0.0 +acosh0070 acosh 10000000000000000.0 0.0 -> 37.534508668464674 0.0 +acosh0071 acosh 10000000000000000.0 -0.0 -> 37.534508668464674 -0.0 +acosh0072 acosh 9.9999999999999998e+149 0.0 -> 346.08091112966679 0.0 +acosh0073 acosh 9.9999999999999998e+149 -0.0 -> 346.08091112966679 -0.0 +acosh0074 acosh 1.0000000000000001e+299 0.0 -> 689.16608998577965 0.0 +acosh0075 acosh 1.0000000000000001e+299 -0.0 -> 689.16608998577965 -0.0 + +-- random inputs +acosh0100 acosh -1.4328589581250843 -1.8370347775558309 -> 1.5526962646549587 -2.190250168435786 +acosh0101 acosh -0.31075819156220957 -1.0772555786839297 -> 0.95139168286193709 -1.7812228089636479 +acosh0102 acosh -1.9044776578070453 -20.485370158932124 -> 3.7177411088932359 -1.6633888745861227 +acosh0103 acosh -0.075642506000858742 -21965976320.873051 -> 24.505907742881991 -1.5707963267983402 +acosh0104 acosh -1.6162271181056307 -3.0369343458696099 -> 1.9407057262861227 -2.0429549461750209 +acosh0105 acosh -0.3103780280298063 0.00018054880018078987 -> 0.00018992877058761416 1.886386995096728 +acosh0106 acosh -9159468751.5897655 5.8014747664273649 -> 23.631201197959193 3.1415926529564078 +acosh0107 acosh -0.037739157550933884 0.21841357493510705 -> 0.21685844960602488 1.6076735133449402 +acosh0108 acosh -8225991.0508394297 0.28318543008913644 -> 16.615956520420287 3.1415926191641019 +acosh0109 acosh -35.620070502302639 0.31303237005015 -> 4.2658980006943965 3.1328013255541873 +acosh0110 acosh 96.729939906820917 -0.029345228372365334 -> 5.2650434775863548 -0.00030338895866972843 +acosh0111 acosh 0.59656024007966491 -2.0412294654163978 -> 1.4923002024287835 -1.312568421900338 +acosh0112 acosh 109.29384112677828 -0.00015454863061533812 -> 5.3871662961545477 -1.4141245154061214e-06 +acosh0113 acosh 8.6705651969361597 -3.6723631649787465 -> 2.9336180958363545 -0.40267362031872861 +acosh0114 acosh 1.8101646445052686 -0.012345132721855478 -> 1.1997148566285769 -0.0081813912760150265 +acosh0115 acosh 52.56897195025288 0.001113916065985443 -> 4.6551827622264135 2.1193445872040307e-05 +acosh0116 acosh 0.28336786164214739 355643992457.40485 -> 27.290343226816528 1.5707963267940999 +acosh0117 acosh 0.73876621291911437 2.8828594541104322e-20 -> 4.2774820978159067e-20 0.73955845836827927 +acosh0118 acosh 0.025865471781718878 37125746064318.492 -> 31.938478989418012 1.5707963267948959 +acosh0119 acosh 2.2047353511780132 0.074712248143489271 -> 1.4286403248698021 0.037997904971626598 + +-- values near infinity +acosh0200 acosh 8.1548592876467785e+307 9.0943779335951128e+307 -> 710.08944620800605 0.83981165425478954 +acosh0201 acosh 1.4237229680972531e+308 -1.0336966617874858e+308 -> 710.4543331094759 -0.6279972876348755 +acosh0202 acosh -1.5014526899738939e+308 1.5670700378448792e+308 -> 710.66420706795464 2.3348137299106697 +acosh0203 acosh -1.0939040375213928e+308 -1.0416960351127978e+308 -> 710.30182863115886 -2.380636147787027 +acosh0204 acosh 0.0 1.476062433559588e+308 -> 710.27873384716929 1.5707963267948966 +acosh0205 acosh -0.0 6.2077210326221094e+307 -> 709.41256457484769 1.5707963267948966 +acosh0206 acosh 0.0 -1.5621899909968308e+308 -> 710.33544449990734 -1.5707963267948966 +acosh0207 acosh -0.0 -8.3556624833839122e+307 -> 709.70971018048317 -1.5707963267948966 +acosh0208 acosh 1.3067079752499342e+308 0.0 -> 710.15686680107228 0.0 +acosh0209 acosh 1.5653640340214026e+308 -0.0 -> 710.33747422926706 -0.0 +acosh0210 acosh -6.9011375992290636e+307 0.0 -> 709.51845699719922 3.1415926535897931 +acosh0211 acosh -9.9539576809926973e+307 -0.0 -> 709.88474095870185 -3.1415926535897931 +acosh0212 acosh 7.6449598518914925e+307 9.5706540768268358 -> 709.62081731754802 1.2518906916769345e-307 +acosh0213 acosh 5.4325410972602197e+307 -7.8064807816522706 -> 709.279177727925 -1.4369851312471974e-307 +acosh0214 acosh -1.1523626112360465e+308 7.0617510038869336 -> 710.03117010216909 3.1415926535897931 +acosh0215 acosh -1.1685027786862599e+308 -5.1568558357925625 -> 710.04507907571417 -3.1415926535897931 +acosh0216 acosh 3.0236370339788721 1.7503248720096417e+308 -> 710.44915723458064 1.5707963267948966 +acosh0217 acosh 6.6108007926031149 -9.1469968225806149e+307 -> 709.80019633903328 -1.5707963267948966 +acosh0218 acosh -5.1096262905623959 6.4484926785412395e+307 -> 709.45061713997973 1.5707963267948966 +acosh0219 acosh -2.8080920608735846 -1.7716118836519368e+308 -> 710.46124562363445 -1.5707963267948966 + +-- values near 0 +acosh0220 acosh 4.5560530326699304e-317 7.3048989121436657e-318 -> 7.3048989121436657e-318 1.5707963267948966 +acosh0221 acosh 4.8754274133585331e-314 -9.8469794897684199e-315 -> 9.8469794897684199e-315 -1.5707963267948966 +acosh0222 acosh -4.6748876009960097e-312 9.7900342887557606e-318 -> 9.7900342887557606e-318 1.5707963267948966 +acosh0223 acosh -4.3136871538399236e-320 -4.9406564584124654e-323 -> 4.9406564584124654e-323 -1.5707963267948966 +acosh0224 acosh 0.0 4.3431013866496774e-314 -> 4.3431013866496774e-314 1.5707963267948966 +acosh0225 acosh -0.0 6.0147334335829184e-317 -> 6.0147334335829184e-317 1.5707963267948966 +acosh0226 acosh 0.0 -1.2880291387081297e-320 -> 1.2880291387081297e-320 -1.5707963267948966 +acosh0227 acosh -0.0 -1.4401563976534621e-317 -> 1.4401563976534621e-317 -1.5707963267948966 +acosh0228 acosh 1.3689680570863091e-313 0.0 -> 0.0 1.5707963267948966 +acosh0229 acosh 1.5304346893494371e-312 -0.0 -> 0.0 -1.5707963267948966 +acosh0230 acosh -3.7450175954766488e-320 0.0 -> 0.0 1.5707963267948966 +acosh0231 acosh -8.4250563080885801e-311 -0.0 -> 0.0 -1.5707963267948966 + +------------------------ +-- asin: Inverse sine -- +------------------------ + +-- zeros +asin0000 asin 0.0 0.0 -> 0.0 0.0 +asin0001 asin 0.0 -0.0 -> 0.0 -0.0 +asin0002 asin -0.0 0.0 -> -0.0 0.0 +asin0003 asin -0.0 -0.0 -> -0.0 -0.0 + +-- branch points: +/-1 +asin0010 asin 1.0 0.0 -> 1.5707963267948966 0.0 +asin0011 asin 1.0 -0.0 -> 1.5707963267948966 -0.0 +asin0012 asin -1.0 0.0 -> -1.5707963267948966 0.0 +asin0013 asin -1.0 -0.0 -> -1.5707963267948966 -0.0 + +-- values along both sides of real axis +asin0020 asin -9.8813129168249309e-324 0.0 -> -9.8813129168249309e-324 0.0 +asin0021 asin -9.8813129168249309e-324 -0.0 -> -9.8813129168249309e-324 -0.0 +asin0022 asin -1e-305 0.0 -> -1e-305 0.0 +asin0023 asin -1e-305 -0.0 -> -1e-305 -0.0 +asin0024 asin -1e-150 0.0 -> -1e-150 0.0 +asin0025 asin -1e-150 -0.0 -> -1e-150 -0.0 +asin0026 asin -9.9999999999999998e-17 0.0 -> -9.9999999999999998e-17 0.0 +asin0027 asin -9.9999999999999998e-17 -0.0 -> -9.9999999999999998e-17 -0.0 +asin0028 asin -0.001 0.0 -> -0.0010000001666667416 0.0 +asin0029 asin -0.001 -0.0 -> -0.0010000001666667416 -0.0 +asin0030 asin -0.57899999999999996 0.0 -> -0.61750165481717001 0.0 +asin0031 asin -0.57899999999999996 -0.0 -> -0.61750165481717001 -0.0 +asin0032 asin -0.99999999999999989 0.0 -> -1.5707963118937354 0.0 +asin0033 asin -0.99999999999999989 -0.0 -> -1.5707963118937354 -0.0 +asin0034 asin -1.0000000000000002 0.0 -> -1.5707963267948966 2.1073424255447014e-08 +asin0035 asin -1.0000000000000002 -0.0 -> -1.5707963267948966 -2.1073424255447014e-08 +asin0036 asin -1.0009999999999999 0.0 -> -1.5707963267948966 0.044717633608306849 +asin0037 asin -1.0009999999999999 -0.0 -> -1.5707963267948966 -0.044717633608306849 +asin0038 asin -2.0 0.0 -> -1.5707963267948966 1.3169578969248168 +asin0039 asin -2.0 -0.0 -> -1.5707963267948966 -1.3169578969248168 +asin0040 asin -23.0 0.0 -> -1.5707963267948966 3.8281684713331012 +asin0041 asin -23.0 -0.0 -> -1.5707963267948966 -3.8281684713331012 +asin0042 asin -10000000000000000.0 0.0 -> -1.5707963267948966 37.534508668464674 +asin0043 asin -10000000000000000.0 -0.0 -> -1.5707963267948966 -37.534508668464674 +asin0044 asin -9.9999999999999998e+149 0.0 -> -1.5707963267948966 346.08091112966679 +asin0045 asin -9.9999999999999998e+149 -0.0 -> -1.5707963267948966 -346.08091112966679 +asin0046 asin -1.0000000000000001e+299 0.0 -> -1.5707963267948966 689.16608998577965 +asin0047 asin -1.0000000000000001e+299 -0.0 -> -1.5707963267948966 -689.16608998577965 +asin0048 asin 9.8813129168249309e-324 0.0 -> 9.8813129168249309e-324 0.0 +asin0049 asin 9.8813129168249309e-324 -0.0 -> 9.8813129168249309e-324 -0.0 +asin0050 asin 1e-305 0.0 -> 1e-305 0.0 +asin0051 asin 1e-305 -0.0 -> 1e-305 -0.0 +asin0052 asin 1e-150 0.0 -> 1e-150 0.0 +asin0053 asin 1e-150 -0.0 -> 1e-150 -0.0 +asin0054 asin 9.9999999999999998e-17 0.0 -> 9.9999999999999998e-17 0.0 +asin0055 asin 9.9999999999999998e-17 -0.0 -> 9.9999999999999998e-17 -0.0 +asin0056 asin 0.001 0.0 -> 0.0010000001666667416 0.0 +asin0057 asin 0.001 -0.0 -> 0.0010000001666667416 -0.0 +asin0058 asin 0.57899999999999996 0.0 -> 0.61750165481717001 0.0 +asin0059 asin 0.57899999999999996 -0.0 -> 0.61750165481717001 -0.0 +asin0060 asin 0.99999999999999989 0.0 -> 1.5707963118937354 0.0 +asin0061 asin 0.99999999999999989 -0.0 -> 1.5707963118937354 -0.0 +asin0062 asin 1.0000000000000002 0.0 -> 1.5707963267948966 2.1073424255447014e-08 +asin0063 asin 1.0000000000000002 -0.0 -> 1.5707963267948966 -2.1073424255447014e-08 +asin0064 asin 1.0009999999999999 0.0 -> 1.5707963267948966 0.044717633608306849 +asin0065 asin 1.0009999999999999 -0.0 -> 1.5707963267948966 -0.044717633608306849 +asin0066 asin 2.0 0.0 -> 1.5707963267948966 1.3169578969248168 +asin0067 asin 2.0 -0.0 -> 1.5707963267948966 -1.3169578969248168 +asin0068 asin 23.0 0.0 -> 1.5707963267948966 3.8281684713331012 +asin0069 asin 23.0 -0.0 -> 1.5707963267948966 -3.8281684713331012 +asin0070 asin 10000000000000000.0 0.0 -> 1.5707963267948966 37.534508668464674 +asin0071 asin 10000000000000000.0 -0.0 -> 1.5707963267948966 -37.534508668464674 +asin0072 asin 9.9999999999999998e+149 0.0 -> 1.5707963267948966 346.08091112966679 +asin0073 asin 9.9999999999999998e+149 -0.0 -> 1.5707963267948966 -346.08091112966679 +asin0074 asin 1.0000000000000001e+299 0.0 -> 1.5707963267948966 689.16608998577965 +asin0075 asin 1.0000000000000001e+299 -0.0 -> 1.5707963267948966 -689.16608998577965 + +-- random inputs +asin0100 asin -1.5979555835086083 -0.15003009814595247 -> -1.4515369557405788 -1.0544476399790823 +asin0101 asin -0.57488225895317679 -9.6080397838952743e-13 -> -0.61246024460412851 -1.174238005400403e-12 +asin0102 asin -3.6508087930516249 -0.36027527093220152 -> -1.4685890605305874 -1.9742273007152038 +asin0103 asin -1.5238659792326819 -1.1360813516996364 -> -0.86080051691147275 -1.3223742205689195 +asin0104 asin -1592.0639045555306 -0.72362427935018236 -> -1.5703418071175179 -8.0659336918729228 +asin0105 asin -0.19835471371312019 4.2131508416697709 -> -0.045777831019935149 2.1461732751933171 +asin0106 asin -1.918471054430213 0.40603305079779234 -> -1.3301396585791556 1.30263642314981 +asin0107 asin -254495.01623373642 0.71084414434470822 -> -1.5707935336394359 13.140183712762321 +asin0108 asin -0.31315882715691157 3.9647994288429866 -> -0.076450403840916004 2.0889762138713457 +asin0109 asin -0.90017064284720816 1.2530659485907105 -> -0.53466509741943447 1.1702811557577 +asin0110 asin 2.1615181696571075 -0.14058647488229523 -> 1.4976166323896871 -1.4085811039334604 +asin0111 asin 1.2104749210707795 -0.85732484485298999 -> 0.83913071588343924 -1.0681719250525901 +asin0112 asin 1.7059733185128891 -0.84032966373156581 -> 1.0510900815816229 -1.2967979791361652 +asin0113 asin 9.9137085017290687 -1.4608383970250893 -> 1.4237704820128891 -2.995414677560686 +asin0114 asin 117.12344751041495 -5453908091.5334015 -> 2.1475141411392012e-08 -23.112745450217066 +asin0115 asin 0.081041187798029227 0.067054349860173196 -> 0.080946786856771813 0.067223991060639698 +asin0116 asin 46.635472322049949 2.3835190718056678 -> 1.5197194940010779 4.5366989600972083 +asin0117 asin 3907.0687961127105 19.144021886390181 -> 1.5658965233083235 8.9637018715924217 +asin0118 asin 1.0889312322308273 509.01577883554768 -> 0.0021392803817829316 6.9256294494524706 +asin0119 asin 0.10851518277509224 1.5612510908217476 -> 0.058491014243902621 1.2297075725621327 + +-- values near infinity +asin0200 asin 1.5230241998821499e+308 5.5707228994084525e+307 -> 1.2201446370892068 710.37283486535966 +asin0201 asin 8.1334317698672204e+307 -9.2249425197872451e+307 -> 0.72259991284020042 -710.0962453049026 +asin0202 asin -9.9138506659241768e+307 6.701544526434995e+307 -> -0.97637511742194594 710.06887486671371 +asin0203 asin -1.4141298868173842e+308 -5.401505134514191e+307 -> -1.2059319055160587 -710.30396478954628 +asin0204 asin 0.0 9.1618092977897431e+307 -> 0.0 709.80181441050593 +asin0205 asin -0.0 6.8064342551939755e+307 -> -0.0 709.50463910853489 +asin0206 asin 0.0 -6.4997516454798215e+307 -> 0.0 -709.45853469751592 +asin0207 asin -0.0 -1.6767449053345242e+308 -> -0.0 -710.4062101803022 +asin0208 asin 5.4242749957378916e+307 0.0 -> 1.5707963267948966 709.27765497888902 +asin0209 asin 9.5342145121164749e+307 -0.0 -> 1.5707963267948966 -709.84165758595907 +asin0210 asin -7.0445698006201847e+307 0.0 -> -1.5707963267948966 709.53902780872136 +asin0211 asin -1.0016025569769706e+308 -0.0 -> -1.5707963267948966 -709.89095709697881 +asin0212 asin 1.6552203778877204e+308 0.48761543336249491 -> 1.5707963267948966 710.39328998153474 +asin0213 asin 1.2485712830384869e+308 -4.3489311161278899 -> 1.5707963267948966 -710.1113557467786 +asin0214 asin -1.5117842813353125e+308 5.123452666102434 -> -1.5707963267948966 710.30264641923031 +asin0215 asin -1.3167634313008016e+308 -0.52939679793528982 -> -1.5707963267948966 -710.16453260239768 +asin0216 asin 0.80843929176985907 1.0150851827767876e+308 -> 7.9642507396113875e-309 709.90432835561637 +asin0217 asin 8.2544809829680901 -1.7423548140539474e+308 -> 4.7375430746865733e-308 -710.44459336242164 +asin0218 asin -5.2499000118824295 4.6655578977512214e+307 -> -1.1252459249113292e-307 709.1269781491103 +asin0219 asin -5.9904782760833433 -4.7315689314781163e+307 -> -1.2660659419394637e-307 -709.14102757522312 + +------------------------------------ +-- asinh: Inverse hyperbolic sine -- +------------------------------------ + +-- zeros +asinh0000 asinh 0.0 0.0 -> 0.0 0.0 +asinh0001 asinh 0.0 -0.0 -> 0.0 -0.0 +asinh0002 asinh -0.0 0.0 -> -0.0 0.0 +asinh0003 asinh -0.0 -0.0 -> -0.0 -0.0 + +-- branch points: +/-i +asinh0010 asinh 0.0 1.0 -> 0.0 1.5707963267948966 +asinh0011 asinh 0.0 -1.0 -> 0.0 -1.5707963267948966 +asinh0012 asinh -0.0 1.0 -> -0.0 1.5707963267948966 +asinh0013 asinh -0.0 -1.0 -> -0.0 -1.5707963267948966 + +-- values along both sides of imaginary axis +asinh0020 asinh 0.0 -9.8813129168249309e-324 -> 0.0 -9.8813129168249309e-324 +asinh0021 asinh -0.0 -9.8813129168249309e-324 -> -0.0 -9.8813129168249309e-324 +asinh0022 asinh 0.0 -1e-305 -> 0.0 -1e-305 +asinh0023 asinh -0.0 -1e-305 -> -0.0 -1e-305 +asinh0024 asinh 0.0 -1e-150 -> 0.0 -1e-150 +asinh0025 asinh -0.0 -1e-150 -> -0.0 -1e-150 +asinh0026 asinh 0.0 -9.9999999999999998e-17 -> 0.0 -9.9999999999999998e-17 +asinh0027 asinh -0.0 -9.9999999999999998e-17 -> -0.0 -9.9999999999999998e-17 +asinh0028 asinh 0.0 -0.001 -> 0.0 -0.0010000001666667416 +asinh0029 asinh -0.0 -0.001 -> -0.0 -0.0010000001666667416 +asinh0030 asinh 0.0 -0.57899999999999996 -> 0.0 -0.61750165481717001 +asinh0031 asinh -0.0 -0.57899999999999996 -> -0.0 -0.61750165481717001 +asinh0032 asinh 0.0 -0.99999999999999989 -> 0.0 -1.5707963118937354 +asinh0033 asinh -0.0 -0.99999999999999989 -> -0.0 -1.5707963118937354 +asinh0034 asinh 0.0 -1.0000000000000002 -> 2.1073424255447014e-08 -1.5707963267948966 +asinh0035 asinh -0.0 -1.0000000000000002 -> -2.1073424255447014e-08 -1.5707963267948966 +asinh0036 asinh 0.0 -1.0009999999999999 -> 0.044717633608306849 -1.5707963267948966 +asinh0037 asinh -0.0 -1.0009999999999999 -> -0.044717633608306849 -1.5707963267948966 +asinh0038 asinh 0.0 -2.0 -> 1.3169578969248168 -1.5707963267948966 +asinh0039 asinh -0.0 -2.0 -> -1.3169578969248168 -1.5707963267948966 +asinh0040 asinh 0.0 -20.0 -> 3.6882538673612966 -1.5707963267948966 +asinh0041 asinh -0.0 -20.0 -> -3.6882538673612966 -1.5707963267948966 +asinh0042 asinh 0.0 -10000000000000000.0 -> 37.534508668464674 -1.5707963267948966 +asinh0043 asinh -0.0 -10000000000000000.0 -> -37.534508668464674 -1.5707963267948966 +asinh0044 asinh 0.0 -9.9999999999999998e+149 -> 346.08091112966679 -1.5707963267948966 +asinh0045 asinh -0.0 -9.9999999999999998e+149 -> -346.08091112966679 -1.5707963267948966 +asinh0046 asinh 0.0 -1.0000000000000001e+299 -> 689.16608998577965 -1.5707963267948966 +asinh0047 asinh -0.0 -1.0000000000000001e+299 -> -689.16608998577965 -1.5707963267948966 +asinh0048 asinh 0.0 9.8813129168249309e-324 -> 0.0 9.8813129168249309e-324 +asinh0049 asinh -0.0 9.8813129168249309e-324 -> -0.0 9.8813129168249309e-324 +asinh0050 asinh 0.0 1e-305 -> 0.0 1e-305 +asinh0051 asinh -0.0 1e-305 -> -0.0 1e-305 +asinh0052 asinh 0.0 1e-150 -> 0.0 1e-150 +asinh0053 asinh -0.0 1e-150 -> -0.0 1e-150 +asinh0054 asinh 0.0 9.9999999999999998e-17 -> 0.0 9.9999999999999998e-17 +asinh0055 asinh -0.0 9.9999999999999998e-17 -> -0.0 9.9999999999999998e-17 +asinh0056 asinh 0.0 0.001 -> 0.0 0.0010000001666667416 +asinh0057 asinh -0.0 0.001 -> -0.0 0.0010000001666667416 +asinh0058 asinh 0.0 0.57899999999999996 -> 0.0 0.61750165481717001 +asinh0059 asinh -0.0 0.57899999999999996 -> -0.0 0.61750165481717001 +asinh0060 asinh 0.0 0.99999999999999989 -> 0.0 1.5707963118937354 +asinh0061 asinh -0.0 0.99999999999999989 -> -0.0 1.5707963118937354 +asinh0062 asinh 0.0 1.0000000000000002 -> 2.1073424255447014e-08 1.5707963267948966 +asinh0063 asinh -0.0 1.0000000000000002 -> -2.1073424255447014e-08 1.5707963267948966 +asinh0064 asinh 0.0 1.0009999999999999 -> 0.044717633608306849 1.5707963267948966 +asinh0065 asinh -0.0 1.0009999999999999 -> -0.044717633608306849 1.5707963267948966 +asinh0066 asinh 0.0 2.0 -> 1.3169578969248168 1.5707963267948966 +asinh0067 asinh -0.0 2.0 -> -1.3169578969248168 1.5707963267948966 +asinh0068 asinh 0.0 20.0 -> 3.6882538673612966 1.5707963267948966 +asinh0069 asinh -0.0 20.0 -> -3.6882538673612966 1.5707963267948966 +asinh0070 asinh 0.0 10000000000000000.0 -> 37.534508668464674 1.5707963267948966 +asinh0071 asinh -0.0 10000000000000000.0 -> -37.534508668464674 1.5707963267948966 +asinh0072 asinh 0.0 9.9999999999999998e+149 -> 346.08091112966679 1.5707963267948966 +asinh0073 asinh -0.0 9.9999999999999998e+149 -> -346.08091112966679 1.5707963267948966 +asinh0074 asinh 0.0 1.0000000000000001e+299 -> 689.16608998577965 1.5707963267948966 +asinh0075 asinh -0.0 1.0000000000000001e+299 -> -689.16608998577965 1.5707963267948966 + +-- random inputs +asinh0100 asinh -0.5946402853710423 -0.044506548910000145 -> -0.56459775392653022 -0.038256221441536356 +asinh0101 asinh -0.19353958046180916 -0.017489624793193454 -> -0.19237926804196651 -0.017171741895336792 +asinh0102 asinh -0.033117585138955893 -8.5256414015933757 -> -2.8327758348650969 -1.5668848791092411 +asinh0103 asinh -1.5184043184035716 -0.73491245339073275 -> -1.2715891419764005 -0.39204624408542355 +asinh0104 asinh -0.60716120271208818 -0.28900743958436542 -> -0.59119299421187232 -0.24745931678118135 +asinh0105 asinh -0.0237177865112429 2.8832601052166313 -> -1.7205820772413236 1.5620261702963094 +asinh0106 asinh -2.3906812342743979 2.6349216848574013 -> -1.9609636249445124 0.8142142660574706 +asinh0107 asinh -0.0027605019787620517 183.85588476550555 -> -5.9072920005445066 1.5707813120847871 +asinh0108 asinh -0.99083661164404713 0.028006797051617648 -> -0.8750185251283995 0.019894099615994653 +asinh0109 asinh -3.0362951937986393 0.86377266758504867 -> -1.8636030714685221 0.26475058859950168 +asinh0110 asinh 0.34438464536152769 -0.71603790174885029 -> 0.43985415690734164 -0.71015037409294324 +asinh0111 asinh 4.4925124413876256 -60604595352.871613 -> 25.520783738612078 -1.5707963267207683 +asinh0112 asinh 2.3213991428170337 -7.5459667007307258 -> 2.7560464993451643 -1.270073210856117 +asinh0113 asinh 0.21291939741682028 -1.2720428814784408 -> 0.77275088137338266 -1.3182099250896895 +asinh0114 asinh 6.6447359379455957 -0.97196191666946996 -> 2.602830695139672 -0.14368247412319965 +asinh0115 asinh 7.1326256655083746 2.1516360452706857 -> 2.7051146374367212 0.29051701669727581 +asinh0116 asinh 0.18846550905063442 3.4705348585339832 -> 1.917697875799296 1.514155593347924 +asinh0117 asinh 0.19065075303281598 0.26216814548222012 -> 0.19603050785932474 0.26013422809614117 +asinh0118 asinh 2.0242004665739719 0.70510281647495787 -> 1.4970366212896002 0.30526007200481453 +asinh0119 asinh 37.336596461576057 717.29157391678234 -> 7.269981997945294 1.5187910219576033 + +-- values near infinity +asinh0200 asinh 1.0760517500874541e+308 1.1497786241240167e+308 -> 710.34346055651815 0.81850936961793475 +asinh0201 asinh 1.1784839328845529e+308 -1.6478429586716638e+308 -> 710.59536255783678 -0.94996311735607697 +asinh0202 asinh -4.8777682248909193e+307 1.4103736217538474e+308 -> -710.28970147376992 1.2378239519096443 +asinh0203 asinh -1.2832478903233108e+308 -1.5732392613155698e+308 -> -710.59750164290745 -0.88657181439322452 +asinh0204 asinh 0.0 6.8431383856345372e+307 -> 709.51001718444604 1.5707963267948966 +asinh0205 asinh -0.0 8.601822432238051e+307 -> -709.73874482126689 1.5707963267948966 +asinh0206 asinh 0.0 -5.5698396067303782e+307 -> 709.30413698733742 -1.5707963267948966 +asinh0207 asinh -0.0 -7.1507777734621804e+307 -> -709.55399186002705 -1.5707963267948966 +asinh0208 asinh 1.6025136110019349e+308 0.0 -> 710.3609292261076 0.0 +asinh0209 asinh 1.3927819858239114e+308 -0.0 -> 710.22065899832899 -0.0 +asinh0210 asinh -6.0442994056210995e+307 0.0 -> -709.38588631057621 0.0 +asinh0211 asinh -1.2775271979042634e+308 -0.0 -> -710.13428215553972 -0.0 +asinh0212 asinh 1.0687496260268489e+308 1.0255615699476961 -> 709.95584521407841 9.5959010882679093e-309 +asinh0213 asinh 1.0050967333370962e+308 -0.87668970117333433 -> 709.89443961168183 -8.7224410556242882e-309 +asinh0214 asinh -5.7161452814862392e+307 8.2377808413450122 -> -709.33006540611166 1.4411426644501116e-307 +asinh0215 asinh -8.2009040727653315e+307 -6.407409526654976 -> -709.69101513070109 -7.8130526461510088e-308 +asinh0216 asinh 6.4239368496483982 1.6365990821551427e+308 -> 710.38197618101287 1.5707963267948966 +asinh0217 asinh 5.4729111423315882 -1.1227237438144211e+308 -> 710.00511346983546 -1.5707963267948966 +asinh0218 asinh -8.3455818297412723 1.443172020182019e+308 -> -710.25619930551818 1.5707963267948966 +asinh0219 asinh -2.6049726230372441 -1.7952291144022702e+308 -> -710.47448847685644 -1.5707963267948966 + +-- values near 0 +asinh0220 asinh 1.2940113339664088e-314 6.9169190417774516e-323 -> 1.2940113339664088e-314 6.9169190417774516e-323 +asinh0221 asinh 2.3848478863874649e-315 -3.1907655025717717e-310 -> 2.3848478863874649e-315 -3.1907655025717717e-310 +asinh0222 asinh -3.0097643679641622e-316 4.6936236354918422e-322 -> -3.0097643679641622e-316 4.6936236354918422e-322 +asinh0223 asinh -1.787997087755751e-308 -8.5619622834902341e-310 -> -1.787997087755751e-308 -8.5619622834902341e-310 +asinh0224 asinh 0.0 1.2491433448427325e-314 -> 0.0 1.2491433448427325e-314 +asinh0225 asinh -0.0 2.5024072154538062e-308 -> -0.0 2.5024072154538062e-308 +asinh0226 asinh 0.0 -2.9643938750474793e-323 -> 0.0 -2.9643938750474793e-323 +asinh0227 asinh -0.0 -2.9396905927554169e-320 -> -0.0 -2.9396905927554169e-320 +asinh0228 asinh 5.64042930029359e-317 0.0 -> 5.64042930029359e-317 0.0 +asinh0229 asinh 3.3833911866596068e-318 -0.0 -> 3.3833911866596068e-318 -0.0 +asinh0230 asinh -4.9406564584124654e-324 0.0 -> -4.9406564584124654e-324 0.0 +asinh0231 asinh -2.221137922799485e-308 -0.0 -> -2.2211379227994845e-308 -0.0 + +--------------------------- +-- atan: Inverse tangent -- +--------------------------- + +-- zeros +atan0000 atan 0.0 0.0 -> 0.0 0.0 +atan0001 atan 0.0 -0.0 -> 0.0 0.0 +atan0002 atan -0.0 0.0 -> -0.0 0.0 +atan0003 atan -0.0 -0.0 -> -0.0 0.0 + +-- values along both sides of imaginary axis +atan0010 atan 0.0 -9.8813129168249309e-324 -> 0.0 -9.8813129168249309e-324 +atan0011 atan -0.0 -9.8813129168249309e-324 -> -0.0 -9.8813129168249309e-324 +atan0012 atan 0.0 -1e-305 -> 0.0 -1e-305 +atan0013 atan -0.0 -1e-305 -> -0.0 -1e-305 +atan0014 atan 0.0 -1e-150 -> 0.0 -1e-150 +atan0015 atan -0.0 -1e-150 -> -0.0 -1e-150 +atan0016 atan 0.0 -9.9999999999999998e-17 -> 0.0 -9.9999999999999998e-17 +atan0017 atan -0.0 -9.9999999999999998e-17 -> -0.0 -9.9999999999999998e-17 +atan0018 atan 0.0 -0.001 -> 0.0 -0.0010000003333335333 +atan0019 atan -0.0 -0.001 -> -0.0 -0.0010000003333335333 +atan0020 atan 0.0 -0.57899999999999996 -> 0.0 -0.6609570902866303 +atan0021 atan -0.0 -0.57899999999999996 -> -0.0 -0.6609570902866303 +atan0022 atan 0.0 -0.99999999999999989 -> 0.0 -18.714973875118524 +atan0023 atan -0.0 -0.99999999999999989 -> -0.0 -18.714973875118524 +atan0024 atan 0.0 -1.0000000000000002 -> 1.5707963267948966 -18.36840028483855 +atan0025 atan -0.0 -1.0000000000000002 -> -1.5707963267948966 -18.36840028483855 +atan0026 atan 0.0 -1.0009999999999999 -> 1.5707963267948966 -3.8007011672919218 +atan0027 atan -0.0 -1.0009999999999999 -> -1.5707963267948966 -3.8007011672919218 +atan0028 atan 0.0 -2.0 -> 1.5707963267948966 -0.54930614433405489 +atan0029 atan -0.0 -2.0 -> -1.5707963267948966 -0.54930614433405489 +atan0030 atan 0.0 -20.0 -> 1.5707963267948966 -0.050041729278491265 +atan0031 atan -0.0 -20.0 -> -1.5707963267948966 -0.050041729278491265 +atan0032 atan 0.0 -10000000000000000.0 -> 1.5707963267948966 -9.9999999999999998e-17 +atan0033 atan -0.0 -10000000000000000.0 -> -1.5707963267948966 -9.9999999999999998e-17 +atan0034 atan 0.0 -9.9999999999999998e+149 -> 1.5707963267948966 -1e-150 +atan0035 atan -0.0 -9.9999999999999998e+149 -> -1.5707963267948966 -1e-150 +atan0036 atan 0.0 -1.0000000000000001e+299 -> 1.5707963267948966 -9.9999999999999999e-300 +atan0037 atan -0.0 -1.0000000000000001e+299 -> -1.5707963267948966 -9.9999999999999999e-300 +atan0038 atan 0.0 9.8813129168249309e-324 -> 0.0 9.8813129168249309e-324 +atan0039 atan -0.0 9.8813129168249309e-324 -> -0.0 9.8813129168249309e-324 +atan0040 atan 0.0 1e-305 -> 0.0 1e-305 +atan0041 atan -0.0 1e-305 -> -0.0 1e-305 +atan0042 atan 0.0 1e-150 -> 0.0 1e-150 +atan0043 atan -0.0 1e-150 -> -0.0 1e-150 +atan0044 atan 0.0 9.9999999999999998e-17 -> 0.0 9.9999999999999998e-17 +atan0045 atan -0.0 9.9999999999999998e-17 -> -0.0 9.9999999999999998e-17 +atan0046 atan 0.0 0.001 -> 0.0 0.0010000003333335333 +atan0047 atan -0.0 0.001 -> -0.0 0.0010000003333335333 +atan0048 atan 0.0 0.57899999999999996 -> 0.0 0.6609570902866303 +atan0049 atan -0.0 0.57899999999999996 -> -0.0 0.6609570902866303 +atan0050 atan 0.0 0.99999999999999989 -> 0.0 18.714973875118524 +atan0051 atan -0.0 0.99999999999999989 -> -0.0 18.714973875118524 +atan0052 atan 0.0 1.0000000000000002 -> 1.5707963267948966 18.36840028483855 +atan0053 atan -0.0 1.0000000000000002 -> -1.5707963267948966 18.36840028483855 +atan0054 atan 0.0 1.0009999999999999 -> 1.5707963267948966 3.8007011672919218 +atan0055 atan -0.0 1.0009999999999999 -> -1.5707963267948966 3.8007011672919218 +atan0056 atan 0.0 2.0 -> 1.5707963267948966 0.54930614433405489 +atan0057 atan -0.0 2.0 -> -1.5707963267948966 0.54930614433405489 +atan0058 atan 0.0 20.0 -> 1.5707963267948966 0.050041729278491265 +atan0059 atan -0.0 20.0 -> -1.5707963267948966 0.050041729278491265 +atan0060 atan 0.0 10000000000000000.0 -> 1.5707963267948966 9.9999999999999998e-17 +atan0061 atan -0.0 10000000000000000.0 -> -1.5707963267948966 9.9999999999999998e-17 +atan0062 atan 0.0 9.9999999999999998e+149 -> 1.5707963267948966 1e-150 +atan0063 atan -0.0 9.9999999999999998e+149 -> -1.5707963267948966 1e-150 +atan0064 atan 0.0 1.0000000000000001e+299 -> 1.5707963267948966 9.9999999999999999e-300 +atan0065 atan -0.0 1.0000000000000001e+299 -> -1.5707963267948966 9.9999999999999999e-300 + +-- random inputs +atan0100 atan -0.32538873661060214 -1.5530461550412578 -> -1.3682728427554227 -0.69451401598762041 +atan0101 atan -0.45863393495197929 -4799.1747094903594 -> -1.5707963068820623 -0.00020836916050636145 +atan0102 atan -8.3006999685976162 -2.6788890251790938 -> -1.4619862771810199 -0.034811669653327826 +atan0103 atan -1.8836307682985314 -1.1441976638861771 -> -1.1839984370871612 -0.20630956157312796 +atan0104 atan -0.00063230482407491669 -4.9312520961829485 -> -1.5707692093223147 -0.20563867743008304 +atan0105 atan -0.84278137150065946 179012.37493146997 -> -1.5707963267685969 5.5862059836425272e-06 +atan0106 atan -0.95487853984049287 14.311334539886177 -> -1.5661322859434561 0.069676024526232005 +atan0107 atan -1.3513252539663239 6.0500727021632198e-08 -> -0.93371676315220975 2.140800269742656e-08 +atan0108 atan -0.20566254458595795 0.11933771944159823 -> -0.20556463711174916 0.11493405387141732 +atan0109 atan -0.58563718795408559 0.64438965423212868 -> -0.68361089300233124 0.46759762751800249 +atan0110 atan 48.479267751948292 -78.386382460112543 -> 1.5650888770910523 -0.0092276811373297584 +atan0111 atan 1.0575373914056061 -0.75988012377296987 -> 0.94430886722043594 -0.31915698126703118 +atan0112 atan 4444810.4314677203 -0.56553404593942558 -> 1.5707961018134231 -2.8625446437701909e-14 +atan0113 atan 0.010101405082520009 -0.032932668550282478 -> 0.01011202676646334 -0.032941214776834996 +atan0114 atan 1.5353585300154911 -2.1947099346796519 -> 1.3400310739206394 -0.29996003607449045 +atan0115 atan 0.21869457055670882 9.9915684254007093 -> 1.5685846078876444 0.1003716881759439 +atan0116 atan 0.17783290150246836 0.064334689863650957 -> 0.17668728064286277 0.062435808728873846 +atan0117 atan 15.757474087615918 383.57262142534 -> 1.5706894060369621 0.0026026817278826603 +atan0118 atan 10.587017408533317 0.21720238081843438 -> 1.4766594681336236 0.0019199097383010061 +atan0119 atan 0.86026078678781204 0.1230148609359502 -> 0.7147259322534929 0.070551221954286605 + +-- values near infinity +atan0200 atan 7.8764397011195798e+307 8.1647921137746308e+307 -> 1.5707963267948966 6.3439446939604493e-309 +atan0201 atan 1.5873698696131487e+308 -1.0780367422960641e+308 -> 1.5707963267948966 -2.9279309368530781e-309 +atan0202 atan -1.5844551864825834e+308 1.0290657809098675e+308 -> -1.5707963267948966 2.8829614736961417e-309 +atan0203 atan -1.3168792562524032e+308 -9.088432341614825e+307 -> -1.5707963267948966 -3.5499373057390056e-309 +atan0204 atan 0.0 1.0360465742258337e+308 -> 1.5707963267948966 9.6520757355646018e-309 +atan0205 atan -0.0 1.0045063210373196e+308 -> -1.5707963267948966 9.955138947929503e-309 +atan0206 atan 0.0 -9.5155296715763696e+307 -> 1.5707963267948966 -1.050913648020118e-308 +atan0207 atan -0.0 -1.5565700490496501e+308 -> -1.5707963267948966 -6.4243816114189071e-309 +atan0208 atan 1.2956339389525244e+308 0.0 -> 1.5707963267948966 0.0 +atan0209 atan 1.4408126243772151e+308 -0.0 -> 1.5707963267948966 0.0 +atan0210 atan -1.0631786461936417e+308 0.0 -> -1.5707963267948966 0.0 +atan0211 atan -1.0516056964171069e+308 -0.0 -> -1.5707963267948966 0.0 +atan0212 atan 1.236162319603838e+308 4.6827953496242936 -> 1.5707963267948966 0.0 +atan0213 atan 7.000516472897218e+307 -5.8631608017844163 -> 1.5707963267948966 -0.0 +atan0214 atan -1.5053444003338508e+308 5.1199197268420313 -> -1.5707963267948966 0.0 +atan0215 atan -1.399172518147259e+308 -3.5687766472913673 -> -1.5707963267948966 -0.0 +atan0216 atan 8.1252833070803021 6.2782953917343822e+307 -> 1.5707963267948966 1.5927890256908564e-308 +atan0217 atan 2.8034285947515167 -1.3378049775753878e+308 -> 1.5707963267948966 -7.4749310756219562e-309 +atan0218 atan -1.4073509988974953 1.6776381785968355e+308 -> -1.5707963267948966 5.9607608646364569e-309 +atan0219 atan -2.7135551527592119 -1.281567445525738e+308 -> -1.5707963267948966 -7.8029447727565326e-309 + +-- imaginary part = +/-1, real part tiny +atan0300 atan -1e-150 -1.0 -> -0.78539816339744828 -173.04045556483339 +atan0301 atan 1e-155 1.0 -> 0.78539816339744828 178.79691829731851 +atan0302 atan 9.9999999999999999e-161 -1.0 -> 0.78539816339744828 -184.55338102980363 +atan0303 atan -1e-165 1.0 -> -0.78539816339744828 190.30984376228875 +atan0304 atan -9.9998886718268301e-321 -1.0 -> -0.78539816339744828 -368.76019403576692 + +--------------------------------------- +-- atanh: Inverse hyperbolic tangent -- +--------------------------------------- + +-- zeros +atanh0000 atanh 0.0 0.0 -> 0.0 0.0 +atanh0001 atanh 0.0 -0.0 -> 0.0 -0.0 +atanh0002 atanh -0.0 0.0 -> 0.0 0.0 +atanh0003 atanh -0.0 -0.0 -> 0.0 -0.0 + +-- values along both sides of real axis +atanh0010 atanh -9.8813129168249309e-324 0.0 -> -9.8813129168249309e-324 0.0 +atanh0011 atanh -9.8813129168249309e-324 -0.0 -> -9.8813129168249309e-324 -0.0 +atanh0012 atanh -1e-305 0.0 -> -1e-305 0.0 +atanh0013 atanh -1e-305 -0.0 -> -1e-305 -0.0 +atanh0014 atanh -1e-150 0.0 -> -1e-150 0.0 +atanh0015 atanh -1e-150 -0.0 -> -1e-150 -0.0 +atanh0016 atanh -9.9999999999999998e-17 0.0 -> -9.9999999999999998e-17 0.0 +atanh0017 atanh -9.9999999999999998e-17 -0.0 -> -9.9999999999999998e-17 -0.0 +atanh0018 atanh -0.001 0.0 -> -0.0010000003333335333 0.0 +atanh0019 atanh -0.001 -0.0 -> -0.0010000003333335333 -0.0 +atanh0020 atanh -0.57899999999999996 0.0 -> -0.6609570902866303 0.0 +atanh0021 atanh -0.57899999999999996 -0.0 -> -0.6609570902866303 -0.0 +atanh0022 atanh -0.99999999999999989 0.0 -> -18.714973875118524 0.0 +atanh0023 atanh -0.99999999999999989 -0.0 -> -18.714973875118524 -0.0 +atanh0024 atanh -1.0000000000000002 0.0 -> -18.36840028483855 1.5707963267948966 +atanh0025 atanh -1.0000000000000002 -0.0 -> -18.36840028483855 -1.5707963267948966 +atanh0026 atanh -1.0009999999999999 0.0 -> -3.8007011672919218 1.5707963267948966 +atanh0027 atanh -1.0009999999999999 -0.0 -> -3.8007011672919218 -1.5707963267948966 +atanh0028 atanh -2.0 0.0 -> -0.54930614433405489 1.5707963267948966 +atanh0029 atanh -2.0 -0.0 -> -0.54930614433405489 -1.5707963267948966 +atanh0030 atanh -23.0 0.0 -> -0.043505688494814884 1.5707963267948966 +atanh0031 atanh -23.0 -0.0 -> -0.043505688494814884 -1.5707963267948966 +atanh0032 atanh -10000000000000000.0 0.0 -> -9.9999999999999998e-17 1.5707963267948966 +atanh0033 atanh -10000000000000000.0 -0.0 -> -9.9999999999999998e-17 -1.5707963267948966 +atanh0034 atanh -9.9999999999999998e+149 0.0 -> -1e-150 1.5707963267948966 +atanh0035 atanh -9.9999999999999998e+149 -0.0 -> -1e-150 -1.5707963267948966 +atanh0036 atanh -1.0000000000000001e+299 0.0 -> -9.9999999999999999e-300 1.5707963267948966 +atanh0037 atanh -1.0000000000000001e+299 -0.0 -> -9.9999999999999999e-300 -1.5707963267948966 +atanh0038 atanh 9.8813129168249309e-324 0.0 -> 9.8813129168249309e-324 0.0 +atanh0039 atanh 9.8813129168249309e-324 -0.0 -> 9.8813129168249309e-324 -0.0 +atanh0040 atanh 1e-305 0.0 -> 1e-305 0.0 +atanh0041 atanh 1e-305 -0.0 -> 1e-305 -0.0 +atanh0042 atanh 1e-150 0.0 -> 1e-150 0.0 +atanh0043 atanh 1e-150 -0.0 -> 1e-150 -0.0 +atanh0044 atanh 9.9999999999999998e-17 0.0 -> 9.9999999999999998e-17 0.0 +atanh0045 atanh 9.9999999999999998e-17 -0.0 -> 9.9999999999999998e-17 -0.0 +atanh0046 atanh 0.001 0.0 -> 0.0010000003333335333 0.0 +atanh0047 atanh 0.001 -0.0 -> 0.0010000003333335333 -0.0 +atanh0048 atanh 0.57899999999999996 0.0 -> 0.6609570902866303 0.0 +atanh0049 atanh 0.57899999999999996 -0.0 -> 0.6609570902866303 -0.0 +atanh0050 atanh 0.99999999999999989 0.0 -> 18.714973875118524 0.0 +atanh0051 atanh 0.99999999999999989 -0.0 -> 18.714973875118524 -0.0 +atanh0052 atanh 1.0000000000000002 0.0 -> 18.36840028483855 1.5707963267948966 +atanh0053 atanh 1.0000000000000002 -0.0 -> 18.36840028483855 -1.5707963267948966 +atanh0054 atanh 1.0009999999999999 0.0 -> 3.8007011672919218 1.5707963267948966 +atanh0055 atanh 1.0009999999999999 -0.0 -> 3.8007011672919218 -1.5707963267948966 +atanh0056 atanh 2.0 0.0 -> 0.54930614433405489 1.5707963267948966 +atanh0057 atanh 2.0 -0.0 -> 0.54930614433405489 -1.5707963267948966 +atanh0058 atanh 23.0 0.0 -> 0.043505688494814884 1.5707963267948966 +atanh0059 atanh 23.0 -0.0 -> 0.043505688494814884 -1.5707963267948966 +atanh0060 atanh 10000000000000000.0 0.0 -> 9.9999999999999998e-17 1.5707963267948966 +atanh0061 atanh 10000000000000000.0 -0.0 -> 9.9999999999999998e-17 -1.5707963267948966 +atanh0062 atanh 9.9999999999999998e+149 0.0 -> 1e-150 1.5707963267948966 +atanh0063 atanh 9.9999999999999998e+149 -0.0 -> 1e-150 -1.5707963267948966 +atanh0064 atanh 1.0000000000000001e+299 0.0 -> 9.9999999999999999e-300 1.5707963267948966 +atanh0065 atanh 1.0000000000000001e+299 -0.0 -> 9.9999999999999999e-300 -1.5707963267948966 + +-- random inputs +atanh0100 atanh -0.54460925980633501 -0.54038050126721027 -> -0.41984265808446974 -0.60354153938352828 +atanh0101 atanh -1.6934614269829051 -0.48807386108113621 -> -0.58592769102243281 -1.3537837470975898 +atanh0102 atanh -1.3467293985501207 -0.47868354895395876 -> -0.69961624370709985 -1.1994450156570076 +atanh0103 atanh -5.6142232418984888 -544551613.39307702 -> -1.8932657550925744e-17 -1.5707963249585235 +atanh0104 atanh -0.011841460381263651 -3.259978899823385 -> -0.0010183936547405188 -1.2731614020743838 +atanh0105 atanh -0.0073345736950029532 0.35821949670922248 -> -0.0065004869024682466 0.34399359971920895 +atanh0106 atanh -13.866782244320014 0.9541129545860273 -> -0.071896852055058899 1.5658322704631409 +atanh0107 atanh -708.59964982780775 21.984802159266675 -> -0.0014098779074189741 1.5707525842838959 +atanh0108 atanh -30.916832076030602 1.3691897138829843 -> -0.032292682045743676 1.5693652094847115 +atanh0109 atanh -0.57461806339861754 0.29534797443913063 -> -0.56467464472482765 0.39615612824172625 +atanh0110 atanh 0.40089246737415685 -1.632285984300659 -> 0.1063832707890608 -1.0402821335326482 +atanh0111 atanh 2119.6167688262176 -1.5383653437377242e+17 -> 8.9565008518382049e-32 -1.5707963267948966 +atanh0112 atanh 756.86017850941641 -6.6064087133223817 -> 0.0013211481136820046 -1.5707847948702234 +atanh0113 atanh 4.0490617718041602 -2.5784456791040652e-12 -> 0.25218425538553618 -1.5707963267947291 +atanh0114 atanh 10.589254957173523 -0.13956391149624509 -> 0.094700890282197664 -1.5695407140217623 +atanh0115 atanh 1.0171187553160499 0.70766113465354019 -> 0.55260251975367791 0.96619711116641682 +atanh0116 atanh 0.031645502527750849 0.067319983726544394 -> 0.031513018344086742 0.067285437670549036 +atanh0117 atanh 0.13670177624994517 0.43240089361857947 -> 0.11538933151017253 0.41392008145336212 +atanh0118 atanh 0.64173899243596688 2.9008577686695256 -> 0.065680142424134405 1.2518535724053921 +atanh0119 atanh 0.19313813528025942 38.799619150741869 -> 0.00012820765917366644 1.5450292202823612 + +-- values near infinity +atanh0200 atanh 5.3242646831347954e+307 1.3740396080084153e+308 -> 2.4519253616695576e-309 1.5707963267948966 +atanh0201 atanh 1.158701641241358e+308 -6.5579268873375853e+307 -> 6.5365375267795098e-309 -1.5707963267948966 +atanh0202 atanh -1.3435325735762247e+308 9.8947369259601547e+307 -> -4.8256680906589956e-309 1.5707963267948966 +atanh0203 atanh -1.4359857522598942e+308 -9.4701204702391004e+307 -> -4.8531282262872645e-309 -1.5707963267948966 +atanh0204 atanh 0.0 5.6614181068098497e+307 -> 0.0 1.5707963267948966 +atanh0205 atanh -0.0 6.9813212721450139e+307 -> 0.0 1.5707963267948966 +atanh0206 atanh 0.0 -7.4970613060311453e+307 -> 0.0 -1.5707963267948966 +atanh0207 atanh -0.0 -1.5280601880314068e+308 -> 0.0 -1.5707963267948966 +atanh0208 atanh 8.2219472336000745e+307 0.0 -> 1.2162568933954813e-308 1.5707963267948966 +atanh0209 atanh 1.4811519617280899e+308 -0.0 -> 6.7515017083951325e-309 -1.5707963267948966 +atanh0210 atanh -1.2282016263598785e+308 0.0 -> -8.1419856360537615e-309 1.5707963267948966 +atanh0211 atanh -1.0616427760154426e+308 -0.0 -> -9.4193642399489563e-309 -1.5707963267948966 +atanh0212 atanh 1.2971536510180682e+308 5.2847948452333293 -> 7.7091869510998328e-309 1.5707963267948966 +atanh0213 atanh 1.1849860977411851e+308 -7.9781906447459949 -> 8.4389175696339014e-309 -1.5707963267948966 +atanh0214 atanh -1.4029969422586635e+308 0.93891986543663375 -> -7.127599283218073e-309 1.5707963267948966 +atanh0215 atanh -4.7508098912248211e+307 -8.2702421247039908 -> -2.1049042645278043e-308 -1.5707963267948966 +atanh0216 atanh 8.2680742115769998 8.1153898410918065e+307 -> 0.0 1.5707963267948966 +atanh0217 atanh 1.2575325146218885 -1.4746679147661649e+308 -> 0.0 -1.5707963267948966 +atanh0218 atanh -2.4618803682310899 1.3781522717005568e+308 -> -0.0 1.5707963267948966 +atanh0219 atanh -4.0952386694788112 -1.231083376353703e+308 -> -0.0 -1.5707963267948966 + +-- values near 0 +atanh0220 atanh 3.8017563659811628e-314 2.6635484239074319e-312 -> 3.8017563659811628e-314 2.6635484239074319e-312 +atanh0221 atanh 1.7391110733611878e-321 -4.3547800672541419e-313 -> 1.7391110733611878e-321 -4.3547800672541419e-313 +atanh0222 atanh -5.9656816081325078e-317 9.9692253555416263e-313 -> -5.9656816081325078e-317 9.9692253555416263e-313 +atanh0223 atanh -6.5606671178400239e-313 -2.1680936406357335e-309 -> -6.5606671178400239e-313 -2.1680936406357335e-309 +atanh0224 atanh 0.0 2.5230944401820779e-319 -> 0.0 2.5230944401820779e-319 +atanh0225 atanh -0.0 5.6066569490064658e-320 -> 0.0 5.6066569490064658e-320 +atanh0226 atanh 0.0 -2.4222487249468377e-317 -> 0.0 -2.4222487249468377e-317 +atanh0227 atanh -0.0 -3.0861101089206037e-316 -> 0.0 -3.0861101089206037e-316 +atanh0228 atanh 3.1219222884393986e-310 0.0 -> 3.1219222884393986e-310 0.0 +atanh0229 atanh 9.8926337564976196e-309 -0.0 -> 9.8926337564976196e-309 -0.0 +atanh0230 atanh -1.5462535092918154e-312 0.0 -> -1.5462535092918154e-312 0.0 +atanh0231 atanh -9.8813129168249309e-324 -0.0 -> -9.8813129168249309e-324 -0.0 + +-- real part = +/-1, imaginary part tiny +atanh0300 atanh 1.0 1e-153 -> 176.49433320432448 0.78539816339744828 +atanh0301 atanh 1.0 9.9999999999999997e-155 -> 177.64562575082149 0.78539816339744828 +atanh0302 atanh -1.0 1e-161 -> -185.70467357630065 0.78539816339744828 +atanh0303 atanh 1.0 -1e-165 -> 190.30984376228875 -0.78539816339744828 +atanh0304 atanh -1.0 -9.8813129168249309e-324 -> -372.22003596069061 -0.78539816339744828 + +---------------------------- +-- log: Natural logarithm -- +---------------------------- + +log0000 log 1 0.0 -> 0.0 0.0 +log0001 log 1 -0.0 -> 0.0 -0.0 +log0002 log -1 0.0 -> 0.0 3.1415926535897931 +log0003 log -1 -0.0 -> 0.0 -3.1415926535897931 +-- values along both sides of real axis +log0010 log -9.8813129168249309e-324 0.0 -> -743.74692474082133 3.1415926535897931 +log0011 log -9.8813129168249309e-324 -0.0 -> -743.74692474082133 -3.1415926535897931 +log0012 log -1e-305 0.0 -> -702.28845336318398 3.1415926535897931 +log0013 log -1e-305 -0.0 -> -702.28845336318398 -3.1415926535897931 +log0014 log -1e-150 0.0 -> -345.38776394910684 3.1415926535897931 +log0015 log -1e-150 -0.0 -> -345.38776394910684 -3.1415926535897931 +log0016 log -9.9999999999999998e-17 0.0 -> -36.841361487904734 3.1415926535897931 +log0017 log -9.9999999999999998e-17 -0.0 -> -36.841361487904734 -3.1415926535897931 +log0018 log -0.001 0.0 -> -6.9077552789821368 3.1415926535897931 +log0019 log -0.001 -0.0 -> -6.9077552789821368 -3.1415926535897931 +log0020 log -0.57899999999999996 0.0 -> -0.54645280140914188 3.1415926535897931 +log0021 log -0.57899999999999996 -0.0 -> -0.54645280140914188 -3.1415926535897931 +log0022 log -0.99999999999999989 0.0 -> -1.1102230246251565e-16 3.1415926535897931 +log0023 log -0.99999999999999989 -0.0 -> -1.1102230246251565e-16 -3.1415926535897931 +log0024 log -1.0000000000000002 0.0 -> 2.2204460492503128e-16 3.1415926535897931 +log0025 log -1.0000000000000002 -0.0 -> 2.2204460492503128e-16 -3.1415926535897931 +log0026 log -1.0009999999999999 0.0 -> 0.00099950033308342321 3.1415926535897931 +log0027 log -1.0009999999999999 -0.0 -> 0.00099950033308342321 -3.1415926535897931 +log0028 log -2.0 0.0 -> 0.69314718055994529 3.1415926535897931 +log0029 log -2.0 -0.0 -> 0.69314718055994529 -3.1415926535897931 +log0030 log -23.0 0.0 -> 3.1354942159291497 3.1415926535897931 +log0031 log -23.0 -0.0 -> 3.1354942159291497 -3.1415926535897931 +log0032 log -10000000000000000.0 0.0 -> 36.841361487904734 3.1415926535897931 +log0033 log -10000000000000000.0 -0.0 -> 36.841361487904734 -3.1415926535897931 +log0034 log -9.9999999999999998e+149 0.0 -> 345.38776394910684 3.1415926535897931 +log0035 log -9.9999999999999998e+149 -0.0 -> 345.38776394910684 -3.1415926535897931 +log0036 log -1.0000000000000001e+299 0.0 -> 688.47294280521965 3.1415926535897931 +log0037 log -1.0000000000000001e+299 -0.0 -> 688.47294280521965 -3.1415926535897931 +log0038 log 9.8813129168249309e-324 0.0 -> -743.74692474082133 0.0 +log0039 log 9.8813129168249309e-324 -0.0 -> -743.74692474082133 -0.0 +log0040 log 1e-305 0.0 -> -702.28845336318398 0.0 +log0041 log 1e-305 -0.0 -> -702.28845336318398 -0.0 +log0042 log 1e-150 0.0 -> -345.38776394910684 0.0 +log0043 log 1e-150 -0.0 -> -345.38776394910684 -0.0 +log0044 log 9.9999999999999998e-17 0.0 -> -36.841361487904734 0.0 +log0045 log 9.9999999999999998e-17 -0.0 -> -36.841361487904734 -0.0 +log0046 log 0.001 0.0 -> -6.9077552789821368 0.0 +log0047 log 0.001 -0.0 -> -6.9077552789821368 -0.0 +log0048 log 0.57899999999999996 0.0 -> -0.54645280140914188 0.0 +log0049 log 0.57899999999999996 -0.0 -> -0.54645280140914188 -0.0 +log0050 log 0.99999999999999989 0.0 -> -1.1102230246251565e-16 0.0 +log0051 log 0.99999999999999989 -0.0 -> -1.1102230246251565e-16 -0.0 +log0052 log 1.0000000000000002 0.0 -> 2.2204460492503128e-16 0.0 +log0053 log 1.0000000000000002 -0.0 -> 2.2204460492503128e-16 -0.0 +log0054 log 1.0009999999999999 0.0 -> 0.00099950033308342321 0.0 +log0055 log 1.0009999999999999 -0.0 -> 0.00099950033308342321 -0.0 +log0056 log 2.0 0.0 -> 0.69314718055994529 0.0 +log0057 log 2.0 -0.0 -> 0.69314718055994529 -0.0 +log0058 log 23.0 0.0 -> 3.1354942159291497 0.0 +log0059 log 23.0 -0.0 -> 3.1354942159291497 -0.0 +log0060 log 10000000000000000.0 0.0 -> 36.841361487904734 0.0 +log0061 log 10000000000000000.0 -0.0 -> 36.841361487904734 -0.0 +log0062 log 9.9999999999999998e+149 0.0 -> 345.38776394910684 0.0 +log0063 log 9.9999999999999998e+149 -0.0 -> 345.38776394910684 -0.0 +log0064 log 1.0000000000000001e+299 0.0 -> 688.47294280521965 0.0 +log0065 log 1.0000000000000001e+299 -0.0 -> 688.47294280521965 -0.0 + +-- random inputs +log0066 log -1.9830454945186191e-16 -2.0334448025673346 -> 0.70973130194329803 -1.5707963267948968 +log0067 log -0.96745853024741857 -0.84995816228299692 -> 0.25292811398722387 -2.4207570438536905 +log0068 log -0.1603644313948418 -0.2929942111041835 -> -1.0965857872427374 -2.0715870859971419 +log0069 log -0.15917913168438699 -0.25238799251132177 -> -1.2093477313249901 -2.1334784232033863 +log0070 log -0.68907818535078802 -3.0693105853476346 -> 1.1460398629184565 -1.7916403813913211 +log0071 log -17.268133447565589 6.8165120014604756 -> 2.9212694465974836 2.7656245081603164 +log0072 log -1.7153894479690328 26.434055372802636 -> 3.2767542953718003 1.6355986276341734 +log0073 log -8.0456794648936578e-06 0.19722758057570208 -> -1.6233969848296075 1.5708371206810101 +log0074 log -2.4306442691323173 0.6846919750700996 -> 0.92633592001969589 2.8670160576718331 +log0075 log -3.5488049250888194 0.45324040643185254 -> 1.2747008374256426 3.0145640007885111 +log0076 log 0.18418516851510189 -0.26062518836212617 -> -1.1421287121940344 -0.95558440841183434 +log0077 log 2.7124837795638399 -13.148769067133387 -> 2.5971659975706802 -1.3673583045209439 +log0078 log 3.6521275476169149e-13 -3.7820543023170673e-05 -> -10.182658136741569 -1.5707963171384316 +log0079 log 5.0877545813862239 -1.2834978326786852 -> 1.6576856213076328 -0.24711583497738485 +log0080 log 0.26477986808461512 -0.67659001194187429 -> -0.31944085207999973 -1.197773671987121 +log0081 log 0.0014754261398071962 5.3514691608205442 -> 1.6773711707153829 1.5705206219261802 +log0082 log 0.29667334462157885 0.00020056045042584795 -> -1.2151233667079588 0.00067603114168689204 +log0083 log 0.82104233671099425 3.9005387130133102 -> 1.3827918965299593 1.3633304701848363 +log0084 log 0.27268135358180667 124.42088110945804 -> 4.8236724223559229 1.5686047258789015 +log0085 log 0.0026286959168267485 0.47795808180573013 -> -0.73821712137809126 1.5652965360960087 + +-- values near infinity +log0100 log 1.0512025744003172e+308 7.2621669750664611e+307 -> 709.44123967814494 0.60455434048332968 +log0101 log 5.5344249034372126e+307 -1.2155859158431275e+308 -> 709.48562300345679 -1.143553056717973 +log0102 log -1.3155575403469408e+308 1.1610793541663864e+308 -> 709.75847809546428 2.41848796504974 +log0103 log -1.632366720973235e+308 -1.54299446211448e+308 -> 710.00545236515586 -2.3843326028455087 +log0104 log 0.0 5.9449276692327712e+307 -> 708.67616191258526 1.5707963267948966 +log0105 log -0.0 1.1201850459025692e+308 -> 709.30970253338171 1.5707963267948966 +log0106 log 0.0 -1.6214225933466528e+308 -> 709.6795125501086 -1.5707963267948966 +log0107 log -0.0 -1.7453269791591058e+308 -> 709.75315056087379 -1.5707963267948966 +log0108 log 1.440860577601428e+308 0.0 -> 709.56144920058262 0.0 +log0109 log 1.391515176148282e+308 -0.0 -> 709.52660185041327 -0.0 +log0110 log -1.201354401295296e+308 0.0 -> 709.37965823023956 3.1415926535897931 +log0111 log -1.6704337825976804e+308 -0.0 -> 709.70929198492399 -3.1415926535897931 +log0112 log 7.2276974655190223e+307 7.94879711369164 -> 708.87154406512104 1.0997689307850458e-307 +log0113 log 1.1207859593716076e+308 -6.1956200868221147 -> 709.31023883080104 -5.5279244310803286e-308 +log0114 log -4.6678933874471045e+307 9.947107893220382 -> 708.43433142431388 3.1415926535897931 +log0115 log -1.5108012453950142e+308 -5.3117197179375619 -> 709.60884877835008 -3.1415926535897931 +log0116 log 7.4903750871504435 1.5320703776626352e+308 -> 709.62282865085137 1.5707963267948966 +log0117 log 5.9760325525654778 -8.0149473997349123e+307 -> 708.97493177248396 -1.5707963267948966 +log0118 log -7.880194206386629 1.7861845814767441e+308 -> 709.77629046837137 1.5707963267948966 +log0119 log -9.886438993852865 -6.19235781080747e+307 -> 708.71693946977302 -1.5707963267948966 + +-- values near 0 +log0120 log 2.2996867579227779e-308 6.7861840770939125e-312 -> -708.36343567717392 0.00029509166223339815 +log0121 log 6.9169190417774516e-323 -9.0414013188948118e-322 -> -739.22766796468386 -1.4944423210001669 +log0122 log -1.5378064962914011e-316 1.8243628389354635e-310 -> -713.20014803142965 1.5707971697228842 +log0123 log -2.3319898483706837e-321 -2.2358763941866371e-313 -> -719.9045008332522 -1.570796337224766 +log0124 log 0.0 3.872770101081121e-315 -> -723.96033425374401 1.5707963267948966 +log0125 log -0.0 9.6342800939043076e-322 -> -739.16707236281752 1.5707963267948966 +log0126 log 0.0 -2.266099393427834e-308 -> -708.37814861757965 -1.5707963267948966 +log0127 log -0.0 -2.1184695673766626e-315 -> -724.56361036731812 -1.5707963267948966 +log0128 log 1.1363509854348671e-322 0.0 -> -741.30457770545206 0.0 +log0129 log 3.5572726500569751e-322 -0.0 -> -740.16340580236522 -0.0 +log0130 log -2.3696071074040593e-310 0.0 -> -712.93865466421641 3.1415926535897931 +log0131 log -2.813283897266934e-317 -0.0 -> -728.88512203138862 -3.1415926535897931 + +-- values near the unit circle +log0200 log -0.59999999999999998 0.80000000000000004 -> 2.2204460492503132e-17 2.2142974355881808 +log0201 log 0.79999999999999993 0.60000000000000009 -> 6.1629758220391547e-33 0.64350110879328448 + +----------------------- +-- sqrt: Square root -- +----------------------- + +-- zeros +sqrt0000 sqrt 0.0 0.0 -> 0.0 0.0 +sqrt0001 sqrt 0.0 -0.0 -> 0.0 -0.0 +sqrt0002 sqrt -0.0 0.0 -> 0.0 0.0 +sqrt0003 sqrt -0.0 -0.0 -> 0.0 -0.0 + +-- values along both sides of real axis +sqrt0010 sqrt -9.8813129168249309e-324 0.0 -> 0.0 3.1434555694052576e-162 +sqrt0011 sqrt -9.8813129168249309e-324 -0.0 -> 0.0 -3.1434555694052576e-162 +sqrt0012 sqrt -1e-305 0.0 -> 0.0 3.1622776601683791e-153 +sqrt0013 sqrt -1e-305 -0.0 -> 0.0 -3.1622776601683791e-153 +sqrt0014 sqrt -1e-150 0.0 -> 0.0 9.9999999999999996e-76 +sqrt0015 sqrt -1e-150 -0.0 -> 0.0 -9.9999999999999996e-76 +sqrt0016 sqrt -9.9999999999999998e-17 0.0 -> 0.0 1e-08 +sqrt0017 sqrt -9.9999999999999998e-17 -0.0 -> 0.0 -1e-08 +sqrt0018 sqrt -0.001 0.0 -> 0.0 0.031622776601683791 +sqrt0019 sqrt -0.001 -0.0 -> 0.0 -0.031622776601683791 +sqrt0020 sqrt -0.57899999999999996 0.0 -> 0.0 0.76092049518987193 +sqrt0021 sqrt -0.57899999999999996 -0.0 -> 0.0 -0.76092049518987193 +sqrt0022 sqrt -0.99999999999999989 0.0 -> 0.0 0.99999999999999989 +sqrt0023 sqrt -0.99999999999999989 -0.0 -> 0.0 -0.99999999999999989 +sqrt0024 sqrt -1.0000000000000002 0.0 -> 0.0 1.0 +sqrt0025 sqrt -1.0000000000000002 -0.0 -> 0.0 -1.0 +sqrt0026 sqrt -1.0009999999999999 0.0 -> 0.0 1.000499875062461 +sqrt0027 sqrt -1.0009999999999999 -0.0 -> 0.0 -1.000499875062461 +sqrt0028 sqrt -2.0 0.0 -> 0.0 1.4142135623730951 +sqrt0029 sqrt -2.0 -0.0 -> 0.0 -1.4142135623730951 +sqrt0030 sqrt -23.0 0.0 -> 0.0 4.7958315233127191 +sqrt0031 sqrt -23.0 -0.0 -> 0.0 -4.7958315233127191 +sqrt0032 sqrt -10000000000000000.0 0.0 -> 0.0 100000000.0 +sqrt0033 sqrt -10000000000000000.0 -0.0 -> 0.0 -100000000.0 +sqrt0034 sqrt -9.9999999999999998e+149 0.0 -> 0.0 9.9999999999999993e+74 +sqrt0035 sqrt -9.9999999999999998e+149 -0.0 -> 0.0 -9.9999999999999993e+74 +sqrt0036 sqrt -1.0000000000000001e+299 0.0 -> 0.0 3.1622776601683796e+149 +sqrt0037 sqrt -1.0000000000000001e+299 -0.0 -> 0.0 -3.1622776601683796e+149 +sqrt0038 sqrt 9.8813129168249309e-324 0.0 -> 3.1434555694052576e-162 0.0 +sqrt0039 sqrt 9.8813129168249309e-324 -0.0 -> 3.1434555694052576e-162 -0.0 +sqrt0040 sqrt 1e-305 0.0 -> 3.1622776601683791e-153 0.0 +sqrt0041 sqrt 1e-305 -0.0 -> 3.1622776601683791e-153 -0.0 +sqrt0042 sqrt 1e-150 0.0 -> 9.9999999999999996e-76 0.0 +sqrt0043 sqrt 1e-150 -0.0 -> 9.9999999999999996e-76 -0.0 +sqrt0044 sqrt 9.9999999999999998e-17 0.0 -> 1e-08 0.0 +sqrt0045 sqrt 9.9999999999999998e-17 -0.0 -> 1e-08 -0.0 +sqrt0046 sqrt 0.001 0.0 -> 0.031622776601683791 0.0 +sqrt0047 sqrt 0.001 -0.0 -> 0.031622776601683791 -0.0 +sqrt0048 sqrt 0.57899999999999996 0.0 -> 0.76092049518987193 0.0 +sqrt0049 sqrt 0.57899999999999996 -0.0 -> 0.76092049518987193 -0.0 +sqrt0050 sqrt 0.99999999999999989 0.0 -> 0.99999999999999989 0.0 +sqrt0051 sqrt 0.99999999999999989 -0.0 -> 0.99999999999999989 -0.0 +sqrt0052 sqrt 1.0000000000000002 0.0 -> 1.0 0.0 +sqrt0053 sqrt 1.0000000000000002 -0.0 -> 1.0 -0.0 +sqrt0054 sqrt 1.0009999999999999 0.0 -> 1.000499875062461 0.0 +sqrt0055 sqrt 1.0009999999999999 -0.0 -> 1.000499875062461 -0.0 +sqrt0056 sqrt 2.0 0.0 -> 1.4142135623730951 0.0 +sqrt0057 sqrt 2.0 -0.0 -> 1.4142135623730951 -0.0 +sqrt0058 sqrt 23.0 0.0 -> 4.7958315233127191 0.0 +sqrt0059 sqrt 23.0 -0.0 -> 4.7958315233127191 -0.0 +sqrt0060 sqrt 10000000000000000.0 0.0 -> 100000000.0 0.0 +sqrt0061 sqrt 10000000000000000.0 -0.0 -> 100000000.0 -0.0 +sqrt0062 sqrt 9.9999999999999998e+149 0.0 -> 9.9999999999999993e+74 0.0 +sqrt0063 sqrt 9.9999999999999998e+149 -0.0 -> 9.9999999999999993e+74 -0.0 +sqrt0064 sqrt 1.0000000000000001e+299 0.0 -> 3.1622776601683796e+149 0.0 +sqrt0065 sqrt 1.0000000000000001e+299 -0.0 -> 3.1622776601683796e+149 -0.0 + +-- random inputs +sqrt0100 sqrt -0.34252542541549913 -223039880.15076211 -> 10560.300180587592 -10560.300196805192 +sqrt0101 sqrt -0.88790791393018909 -5.3307751730827402 -> 1.5027154613689004 -1.7737140896343291 +sqrt0102 sqrt -113916.89291310767 -0.018143374626153858 -> 2.6877817875351178e-05 -337.51576691038952 +sqrt0103 sqrt -0.63187172386197121 -0.26293913366617694 -> 0.16205707495266153 -0.81125471918761971 +sqrt0104 sqrt -0.058185169308906215 -2.3548312990430991 -> 1.0717660342420072 -1.0985752598086966 +sqrt0105 sqrt -1.0580584765935896 0.14400319259151736 -> 0.069837489270111242 1.030987755262468 +sqrt0106 sqrt -1.1667595947504932 0.11159711473953678 -> 0.051598531319315251 1.0813981705111229 +sqrt0107 sqrt -0.5123728411449906 0.026175433648339085 -> 0.018278026262418718 0.71603556293597614 +sqrt0108 sqrt -3.7453400060067228 1.0946500314809635 -> 0.27990088541692498 1.9554243814742367 +sqrt0109 sqrt -0.0027736121575097673 1.0367943000839817 -> 0.71903560338719175 0.72096172651250545 +sqrt0110 sqrt 1501.2559699453188 -1.1997325207283589 -> 38.746047664730959 -0.015481998720355024 +sqrt0111 sqrt 1.4830075326850578 -0.64100878436755349 -> 1.244712815741096 -0.25749264258434584 +sqrt0112 sqrt 0.095395618499734602 -0.48226565701639595 -> 0.54175904053472879 -0.44509239434231551 +sqrt0113 sqrt 0.50109185681863277 -0.54054037379892561 -> 0.7868179858332387 -0.34349772344520979 +sqrt0114 sqrt 0.98779807595367897 -0.00019848758437225191 -> 0.99388031770665153 -9.9854872279921968e-05 +sqrt0115 sqrt 11.845472380792259 0.0010051104581506761 -> 3.4417252072345397 0.00014601840612346451 +sqrt0116 sqrt 2.3558249686735975 0.25605157371744403 -> 1.5371278477386647 0.083288964575761404 +sqrt0117 sqrt 0.77584894123159098 1.0496420627016076 -> 1.0200744386390885 0.51449287568756552 +sqrt0118 sqrt 1.8961715669604893 0.34940793467158854 -> 1.3827991781411615 0.12634080935066902 +sqrt0119 sqrt 0.96025378316565801 0.69573224860140515 -> 1.0358710342209998 0.33581991658093457 + +-- values near 0 +sqrt0120 sqrt 7.3577938365086866e-313 8.1181408465112743e-319 -> 8.5777583531543516e-157 4.732087634251168e-163 +sqrt0121 sqrt 1.2406883874892108e-310 -5.1210133324269776e-312 -> 1.1140990057468052e-155 -2.2982756945349973e-157 +sqrt0122 sqrt -7.1145453001139502e-322 2.9561379244703735e-314 -> 1.2157585807480286e-157 1.2157586100077242e-157 +sqrt0123 sqrt -4.9963244206801218e-314 -8.4718424423690227e-319 -> 1.8950582312540437e-162 -2.2352459419578971e-157 +sqrt0124 sqrt 0.0 7.699553609385195e-318 -> 1.9620848107797476e-159 1.9620848107797476e-159 +sqrt0125 sqrt -0.0 3.3900826606499415e-309 -> 4.1170879639922327e-155 4.1170879639922327e-155 +sqrt0126 sqrt 0.0 -9.8907989772250828e-319 -> 7.032353438652342e-160 -7.032353438652342e-160 +sqrt0127 sqrt -0.0 -1.3722939367590908e-315 -> 2.6194407196566702e-158 -2.6194407196566702e-158 +sqrt0128 sqrt 7.9050503334599447e-323 0.0 -> 8.8910349979403099e-162 0.0 +sqrt0129 sqrt 1.8623241768349486e-309 -0.0 -> 4.3154654173506579e-155 -0.0 +sqrt0130 sqrt -2.665971134499887e-308 0.0 -> 0.0 1.6327801856036491e-154 +sqrt0131 sqrt -1.5477066694467245e-310 -0.0 -> 0.0 -1.2440685951533077e-155 + +-- inputs whose absolute value overflows +sqrt0140 sqrt 1.6999999999999999e+308 -1.6999999999999999e+308 -> 1.4325088230154573e+154 -5.9336458271212207e+153 +sqrt0141 sqrt -1.797e+308 -9.9999999999999999e+306 -> 3.7284476432057307e+152 -1.3410406899802901e+154 + +-- For exp, cosh, sinh, tanh we limit tests to arguments whose +-- imaginary part is less than 10 in absolute value: most math +-- libraries have poor accuracy for (real) sine and cosine for +-- large arguments, and the accuracy of these complex functions +-- suffer correspondingly. +-- +-- Similarly, for cos, sin and tan we limit tests to arguments +-- with relatively small real part. + +------------------------------- +-- exp: Exponential function -- +------------------------------- + +-- zeros +exp0000 exp 0.0 0.0 -> 1.0 0.0 +exp0001 exp 0.0 -0.0 -> 1.0 -0.0 +exp0002 exp -0.0 0.0 -> 1.0 0.0 +exp0003 exp -0.0 -0.0 -> 1.0 -0.0 + +-- random inputs +exp0004 exp -17.957359009564684 -1.108613895795274 -> 7.0869292576226611e-09 -1.4225929202377833e-08 +exp0005 exp -1.4456149663368642e-15 -0.75359817331772239 -> 0.72923148323917997 -0.68426708517419033 +exp0006 exp -0.76008654883512661 -0.46657235480105019 -> 0.41764393109928666 -0.21035108396792854 +exp0007 exp -5.7071614697735731 -2.3744161818115816e-11 -> 0.0033220890242068356 -7.8880219364953578e-14 +exp0008 exp -0.4653981327927097 -5.2236706667445587e-21 -> 0.62788507378216663 -3.2798648420026468e-21 +exp0009 exp -3.2444565242295518 1.1535625304243959 -> 0.015799936931457641 0.035644950380024749 +exp0010 exp -3.0651456337977727 0.87765086532391878 -> 0.029805595629855953 0.035882775180855669 +exp0011 exp -0.11080823753233926 0.96486386300873106 -> 0.50979112534376314 0.73575512419561562 +exp0012 exp -2.5629722598928648 0.019636235754708079 -> 0.077060452853917397 0.0015133717341137684 +exp0013 exp -3.3201709957983357e-10 1.2684017344487268 -> 0.29780699855434889 0.95462610007689186 +exp0014 exp 0.88767276057993272 -0.18953422986895557 -> 2.3859624049858095 -0.45771559132044426 +exp0015 exp 1.5738333486794742 -2.2576803075544328e-11 -> 4.8251091132458654 -1.0893553826776623e-10 +exp0016 exp 1.6408702341813795 -1.438879484380837 -> 0.6786733590689048 -5.1148284173168825 +exp0017 exp 1.820279424202033 -0.020812040370785722 -> 6.1722462896420902 -0.1284755888435051 +exp0018 exp 1.7273965735945873 -0.61140621328954947 -> 4.6067931898799976 -3.2294267694441308 +exp0019 exp 2.5606034306862995 0.098153136008435504 -> 12.881325889966629 1.2684184812864494 +exp0020 exp 10.280368619483029 3.4564622559748535 -> -27721.283321551502 -9028.9663215568835 +exp0021 exp 1.104007405129741e-155 0.21258803067317278 -> 0.97748813933531764 0.21099037290544478 +exp0022 exp 0.027364777809295172 0.00059226603500623363 -> 1.0277424518451876 0.0006086970181346579 +exp0023 exp 0.94356313429255245 3.418530463518592 -> -2.4712285695346194 -0.70242654900218349 + +-- cases where exp(z) representable, exp(z.real) not +exp0030 exp 710.0 0.78500000000000003 -> 1.5803016909637158e+308 1.5790437551806911e+308 +exp0031 exp 710.0 -0.78500000000000003 -> 1.5803016909637158e+308 -1.5790437551806911e+308 + +-- values for which exp(x) underflows +exp0040 exp -735.0 0.78500000000000003 -> 4.3976783136329355e-320 4.3942198541120468e-320 +exp0041 exp -735.0 -2.3559999999999999 -> -4.3952079854037293e-320 -4.396690182341253e-320 + +----------------------------- +-- cosh: Hyperbolic Cosine -- +----------------------------- + +-- zeros +cosh0000 cosh 0.0 0.0 -> 1.0 0.0 +cosh0001 cosh 0.0 -0.0 -> 1.0 -0.0 +cosh0002 cosh -0.0 0.0 -> 1.0 -0.0 +cosh0003 cosh -0.0 -0.0 -> 1.0 0.0 + +-- random inputs +cosh0004 cosh -0.85395264297414253 -8.8553756148671958 -> -1.1684340348021185 0.51842195359787435 +cosh0005 cosh -19.584904237211223 -0.066582627994906177 -> 159816812.23336992 10656776.050406246 +cosh0006 cosh -0.11072618401130772 -1.484820215073247 -> 0.086397164744949503 0.11054275637717284 +cosh0007 cosh -3.4764840250681752 -0.48440348288275276 -> 14.325931955190844 7.5242053548737955 +cosh0008 cosh -0.52047063604524602 -0.3603805382775585 -> 1.0653940354683802 0.19193293606252473 +cosh0009 cosh -1.39518962975995 0.0074738604700702906 -> 2.1417031027235969 -0.01415518712296308 +cosh0010 cosh -0.37107064757653541 0.14728085307856609 -> 1.0580601496776991 -0.055712531964568587 +cosh0011 cosh -5.8470200958739653 4.0021722388336292 -> -112.86220667618285 131.24734033545013 +cosh0012 cosh -0.1700261444851883 0.97167540135354513 -> 0.57208748253577946 -0.1410904820240203 +cosh0013 cosh -0.44042397902648783 1.0904791964139742 -> 0.50760322393058133 -0.40333966652010816 +cosh0014 cosh 0.052267552491867299 -3.8889011430644174 -> -0.73452303414639297 0.035540704833537134 +cosh0015 cosh 0.98000764177127453 -1.2548829247784097 -> 0.47220747341416142 -1.0879421432180316 +cosh0016 cosh 0.083594701222644008 -0.88847899930181284 -> 0.63279782419312613 -0.064954566816002285 +cosh0017 cosh 1.38173531783776 -0.43185040816732229 -> 1.9221663374671647 -0.78073830858849347 +cosh0018 cosh 0.57315681120148465 -0.22255760951027942 -> 1.1399733125173004 -0.1335512343605956 +cosh0019 cosh 1.8882512333062347 4.5024932182383797 -> -0.7041602065362691 -3.1573822131964615 +cosh0020 cosh 0.5618219206858317 0.92620452129575348 -> 0.69822380405378381 0.47309067471054522 +cosh0021 cosh 0.54361442847062591 0.64176483583018462 -> 0.92234462074193491 0.34167906495845501 +cosh0022 cosh 0.0014777403107920331 1.3682028122677661 -> 0.2012106963899549 0.001447518137863219 +cosh0023 cosh 2.218885944363501 2.0015727395883687 -> -1.94294321081968 4.1290269176083196 + +-- large real part +cosh0030 cosh 710.5 2.3519999999999999 -> -1.2967465239355998e+308 1.3076707908857333e+308 +cosh0031 cosh -710.5 0.69999999999999996 -> 1.4085466381392499e+308 -1.1864024666450239e+308 + +--------------------------- +-- sinh: Hyperbolic Sine -- +--------------------------- + +-- zeros +sinh0000 sinh 0.0 0.0 -> 0.0 0.0 +sinh0001 sinh 0.0 -0.0 -> 0.0 -0.0 +sinh0002 sinh -0.0 0.0 -> -0.0 0.0 +sinh0003 sinh -0.0 -0.0 -> -0.0 -0.0 + +-- random inputs +sinh0004 sinh -17.282588091462742 -0.38187948694103546 -> -14867386.857248396 -5970648.6553516639 +sinh0005 sinh -343.91971203143208 -5.0172868877771525e-22 -> -1.1518691776521735e+149 -5.7792581214689021e+127 +sinh0006 sinh -14.178122253300922 -1.9387157579351293 -> 258440.37909034826 -670452.58500946441 +sinh0007 sinh -1.0343810581686239 -1.0970235266369905 -> -0.56070858278092739 -1.4098883258046697 +sinh0008 sinh -0.066126561416368204 -0.070461584169961872 -> -0.066010558700938124 -0.070557276738637542 +sinh0009 sinh -0.37630149150308484 3.3621734692162173 -> 0.37591118119332617 -0.23447115926369383 +sinh0010 sinh -0.049941960978670055 0.40323767020414625 -> -0.045955482136329009 0.3928878494430646 +sinh0011 sinh -16.647852603903715 0.0026852219129082098 -> -8492566.5739382561 22804.480671133562 +sinh0012 sinh -1.476625314303694 0.89473773116683386 -> -1.2982943334382224 1.7966593367791204 +sinh0013 sinh -422.36429577556913 0.10366634502307912 -> -1.3400321008920044e+183 1.3941600948045599e+182 +sinh0014 sinh 0.09108340745641981 -0.40408227416070353 -> 0.083863724802237902 -0.39480716553935602 +sinh0015 sinh 2.036064132067386 -2.6831729961386239 -> -3.37621124363175 -1.723868330002817 +sinh0016 sinh 2.5616717223063317 -0.0078978498622717767 -> 6.4399415853815869 -0.051472264400722133 +sinh0017 sinh 0.336804011985188 -6.5654622971649337 -> 0.32962499307574578 -0.29449170159995197 +sinh0018 sinh 0.23774603755649693 -0.92467195799232049 -> 0.14449839490603389 -0.82109449053556793 +sinh0019 sinh 0.0011388273541465494 1.9676196882949855 -> -0.00044014605389634999 0.92229398407098806 +sinh0020 sinh 3.2443870105663759 0.8054287559616895 -> 8.8702890778527426 9.2610748597042196 +sinh0021 sinh 0.040628908857054738 0.098206391190944958 -> 0.04044426841671233 0.098129544739707392 +sinh0022 sinh 4.7252283918217696e-30 9.1198155642656697 -> -4.5071980561644404e-30 0.30025730701661713 +sinh0023 sinh 0.043713693678420068 0.22512549887532657 -> 0.042624198673416713 0.22344201231217961 + +-- large real part +sinh0030 sinh 710.5 -2.3999999999999999 -> -1.3579970564885919e+308 -1.24394470907798e+308 +sinh0031 sinh -710.5 0.80000000000000004 -> -1.2830671601735164e+308 1.3210954193997678e+308 + +------------------------------ +-- tanh: Hyperbolic Tangent -- +------------------------------ + +-- zeros +tanh0000 tanh 0.0 0.0 -> 0.0 0.0 +tanh0001 tanh 0.0 -0.0 -> 0.0 -0.0 +tanh0002 tanh -0.0 0.0 -> -0.0 0.0 +tanh0003 tanh -0.0 -0.0 -> -0.0 -0.0 + +-- random inputs +tanh0004 tanh -21.200500450664993 -1.6970729480342996 -> -1.0 1.9241352344849399e-19 +tanh0005 tanh -0.34158771504251928 -8.0848504951747131 -> -2.123711225855613 1.2827526782026006 +tanh0006 tanh -15.454144725193689 -0.23619582288265617 -> -0.99999999999993283 -3.4336684248260036e-14 +tanh0007 tanh -7.6103163119661952 -0.7802748320307008 -> -0.99999999497219438 -4.9064845343755437e-07 +tanh0008 tanh -0.15374717235792129 -0.6351086327306138 -> -0.23246081703561869 -0.71083467433910219 +tanh0009 tanh -0.49101115474392465 0.09723001264886301 -> -0.45844445715492133 0.077191158541805888 +tanh0010 tanh -0.10690612157664491 2.861612800856395 -> -0.11519761626257358 -0.28400488355647507 +tanh0011 tanh -0.91505774192066702 1.5431174597727007 -> -1.381109893068114 0.025160819663709356 +tanh0012 tanh -0.057433367093792223 0.35491159541246459 -> -0.065220499046696953 0.36921788332369498 +tanh0013 tanh -1.3540418621233514 0.18969415642242535 -> -0.88235642861151387 0.043764069984411721 +tanh0014 tanh 0.94864783961003529 -0.11333689578867717 -> 0.74348401861861368 -0.051271042543855221 +tanh0015 tanh 1.9591698133845488 -0.0029654444904578339 -> 0.9610270776968135 -0.00022664240049212933 +tanh0016 tanh 1.0949715796669197 -0.24706642853984456 -> 0.81636574501369386 -0.087767436914149954 +tanh0017 tanh 5770428.2113731047 -3.7160580339833165 -> 1.0 -0.0 +tanh0018 tanh 1.5576782321399629 -1.0357943787966468 -> 1.0403002384895388 -0.081126347894671463 +tanh0019 tanh 0.62378536230552961 2.3471393579560216 -> 0.85582499238960363 -0.53569473646842869 +tanh0020 tanh 17.400628602508025 9.3987059533841979 -> 0.99999999999999845 -8.0175867720530832e-17 +tanh0021 tanh 0.15026177509871896 0.50630349159505472 -> 0.19367536571827768 0.53849847858853661 +tanh0022 tanh 0.57433977530711167 1.0071604546265627 -> 1.0857848159262844 0.69139213955872214 +tanh0023 tanh 0.16291181500449456 0.006972810241567544 -> 0.16149335907551157 0.0067910772903467817 + +-- large real part +tanh0030 tanh 710 0.13 -> 1.0 0.0 +tanh0031 tanh -711 7.4000000000000004 -> -1.0 0.0 +tanh0032 tanh 1000 -2.3199999999999998 -> 1.0 0.0 +tanh0033 tanh -1.0000000000000001e+300 -9.6699999999999999 -> -1.0 -0.0 + +----------------- +-- cos: Cosine -- +----------------- + +-- zeros +cos0000 cos 0.0 0.0 -> 1.0 -0.0 +cos0001 cos 0.0 -0.0 -> 1.0 0.0 +cos0002 cos -0.0 0.0 -> 1.0 0.0 +cos0003 cos -0.0 -0.0 -> 1.0 -0.0 + +-- random inputs +cos0004 cos -2.0689194692073034 -0.0016802181751734313 -> -0.47777827208561469 -0.0014760401501695971 +cos0005 cos -0.4209627318177977 -1.8238516774258027 -> 2.9010402201444108 -1.2329207042329617 +cos0006 cos -1.9402181630694557 -2.9751857392891217 -> -3.5465459297970985 -9.1119163586282248 +cos0007 cos -3.3118320290191616 -0.87871302909286142 -> -1.3911528636565498 0.16878141517391701 +cos0008 cos -4.9540404623376872 -0.57949232239026827 -> 0.28062445586552065 0.59467861308508008 +cos0009 cos -0.45374584316245026 1.3950283448373935 -> 1.9247665574290578 0.83004572204761107 +cos0010 cos -0.42578172040176843 1.2715881615413049 -> 1.7517161459489148 0.67863902697363332 +cos0011 cos -0.13862985354300136 0.43587635877670328 -> 1.0859880290361912 0.062157548146672272 +cos0012 cos -0.11073221308966584 9.9384082307326475e-15 -> 0.99387545040722947 1.0982543264065479e-15 +cos0013 cos -1.5027633662054623e-07 0.0069668060249955498 -> 1.0000242682912412 1.0469545565660995e-09 +cos0014 cos 4.9728645490503052 -0.00027479808860952822 -> 0.25754011731975501 -0.00026552849549083186 +cos0015 cos 7.81969303486719 -0.79621523445878783 -> 0.045734882501585063 0.88253139933082991 +cos0016 cos 0.13272421880766716 -0.74668445308718201 -> 1.2806012244432847 0.10825373267437005 +cos0017 cos 4.2396521985973274 -2.2178848380884881 -> -2.1165117057056855 -4.0416492444641401 +cos0018 cos 1.1622206624927296 -0.50400115461197081 -> 0.44884072613370379 0.4823469915034318 +cos0019 cos 1.628772864620884e-08 0.58205705428979282 -> 1.1742319995791435 -1.0024839481956604e-08 +cos0020 cos 2.6385212606111241 2.9886107100937296 -> -8.7209475927161417 -4.7748352107199796 +cos0021 cos 4.8048375263775256 0.0062248852898515658 -> 0.092318702015846243 0.0061983430422306142 +cos0022 cos 7.9914515433858515 0.71659966615501436 -> -0.17375439906936566 -0.77217043527294582 +cos0023 cos 0.45124351152540226 1.6992693993812158 -> 2.543477948972237 -1.1528193694875477 + +--------------- +-- sin: Sine -- +--------------- + +-- zeros +sin0000 sin 0.0 0.0 -> 0.0 0.0 +sin0001 sin 0.0 -0.0 -> 0.0 -0.0 +sin0002 sin -0.0 0.0 -> -0.0 0.0 +sin0003 sin -0.0 -0.0 -> -0.0 -0.0 + +-- random inputs +sin0004 sin -0.18691829163163759 -0.74388741985507034 -> -0.2396636733773444 -0.80023231101856751 +sin0005 sin -0.45127453702459158 -461.81339920716164 -> -7.9722299331077877e+199 -1.6450205811004628e+200 +sin0006 sin -0.47669228345768921 -2.7369936564987514 -> -3.557238022267124 -6.8308030771226615 +sin0007 sin -0.31024285525950857 -1.4869219939188296 -> -0.70972676047175209 -1.9985029635426839 +sin0008 sin -4.4194573407025608 -1.405999210989288 -> 2.0702480800802685 0.55362250792180601 +sin0009 sin -1.7810832046434898e-05 0.0016439555384379083 -> -1.7810856113185261e-05 0.0016439562786668375 +sin0010 sin -0.8200017874897666 0.61724876887771929 -> -0.8749078195948865 0.44835295550987758 +sin0011 sin -1.4536502806107114 0.63998575534150415 -> -1.2035709929437679 0.080012187489163708 +sin0012 sin -2.2653412155506079 0.13172760685583729 -> -0.77502093809190431 -0.084554426868229532 +sin0013 sin -0.02613983069491858 0.18404766597776073 -> -0.026580778863127943 0.18502525396735642 +sin0014 sin 1.5743065001054617 -0.53125574272642029 -> 1.1444596332092725 0.0019537598099352077 +sin0015 sin 7.3833101791283289e-20 -0.16453221324236217 -> 7.4834720674379429e-20 -0.16527555646466915 +sin0016 sin 0.34763834641254038 -2.8377416421089565 -> 2.918883541504663 -8.0002718053250224 +sin0017 sin 0.077105785180421563 -0.090056027316200674 -> 0.077341973814471304 -0.089909869380524587 +sin0018 sin 3.9063227798142329e-17 -0.05954098654295524 -> 3.9132490348956512e-17 -0.059576172859837351 +sin0019 sin 0.57333917932544598 8.7785221430594696e-06 -> 0.54244029338302935 7.3747869125301368e-06 +sin0020 sin 0.024861722816513169 0.33044620756118515 -> 0.026228801369651 0.3363889671570689 +sin0021 sin 1.4342727387492671 0.81361889790284347 -> 1.3370960060947923 0.12336137961387163 +sin0022 sin 1.1518087354403725 4.8597235966150558 -> 58.919141989603041 26.237003403758852 +sin0023 sin 0.00087773078406649192 34.792379211312095 -> 565548145569.38245 644329685822700.62 + +------------------ +-- tan: Tangent -- +------------------ + +-- zeros +tan0000 tan 0.0 0.0 -> 0.0 0.0 +tan0001 tan 0.0 -0.0 -> 0.0 -0.0 +tan0002 tan -0.0 0.0 -> -0.0 0.0 +tan0003 tan -0.0 -0.0 -> -0.0 -0.0 + +-- random inputs +tan0004 tan -0.56378561833861074 -1.7110276237187664e+73 -> -0.0 -1.0 +tan0005 tan -3.5451633993471915e-12 -2.855471863564059 -> -4.6622441304889575e-14 -0.99340273843093951 +tan0006 tan -2.502442719638696 -0.26742234390504221 -> 0.66735215252994995 -0.39078997935420956 +tan0007 tan -0.87639597720371365 -55.586225523280206 -> -1.0285264565948176e-48 -1.0 +tan0008 tan -0.015783869596427243 -520.05944436039272 -> -0.0 -1.0 +tan0009 tan -0.84643549990725164 2.0749097935396343 -> -0.031412661676959573 1.0033548479526764 +tan0010 tan -0.43613792248559646 8.1082741629458059 -> -1.3879848444644593e-07 0.99999988344224011 +tan0011 tan -1.0820906367833114 0.28571868992480248 -> -1.3622485737936536 0.99089269377971245 +tan0012 tan -1.1477859580220084 1.9021637002708041 -> -0.034348450042071196 1.0293954097901687 +tan0013 tan -0.12465543176953409 3.0606851016344815e-05 -> -0.12530514290387343 3.1087420769945479e-05 +tan0014 tan 3.7582848717525343 -692787020.44038939 -> 0.0 -1.0 +tan0015 tan 2.2321967655142176e-06 -10.090069423008169 -> 1.5369846120622643e-14 -0.99999999655723759 +tan0016 tan 0.88371172390245012 -1.1635053630132823 -> 0.19705017118625889 -1.0196452280843129 +tan0017 tan 2.1347414231849267 -1.9311339960416831 -> -0.038663576915982524 -1.0174399993980778 +tan0018 tan 5.9027945255899974 -2.1574195684607135e-183 -> -0.39986591539281496 -2.5023753167976915e-183 +tan0019 tan 0.44811489490805362 683216075670.07556 -> 0.0 1.0 +tan0020 tan 4.1459766396068325 12.523017205605756 -> 2.4022514758988068e-11 1.0000000000112499 +tan0021 tan 1.7809617968443272 1.5052381702853379 -> -0.044066222118946903 1.0932684517702778 +tan0022 tan 1.1615313900880577 1.7956298728647107 -> 0.041793186826390362 1.0375339546034792 +tan0023 tan 0.067014779477908945 5.8517361577457097 -> 2.2088639754800034e-06 0.9999836182420061 + Modified: python/branches/trunk-math/Lib/test/test_cmath.py ============================================================================== --- python/branches/trunk-math/Lib/test/test_cmath.py (original) +++ python/branches/trunk-math/Lib/test/test_cmath.py Tue Jan 22 12:46:53 2008 @@ -1,5 +1,7 @@ from test.test_support import run_unittest +from test.test_math import parse_testfile, test_file import unittest +import os, sys import cmath, math class CMathTests(unittest.TestCase): @@ -12,24 +14,35 @@ test_functions.append(lambda x : cmath.log(x, 1729. + 0j)) test_functions.append(lambda x : cmath.log(14.-27j, x)) - def cAssertAlmostEqual(self, a, b, rel_eps = 1e-10, abs_eps = 1e-100): - """Check that two complex numbers are almost equal.""" - # the two complex numbers are considered almost equal if - # either the relative error is <= rel_eps or the absolute error - # is tiny, <= abs_eps. - if a == b == 0: - return - absolute_error = abs(a-b) - relative_error = absolute_error/max(abs(a), abs(b)) - if relative_error > rel_eps and absolute_error > abs_eps: - self.fail("%s and %s are not almost equal" % (a, b)) + def setUp(self): + self.test_values = open(test_file) + + def tearDown(self): + self.test_values.close() + + def rAssertAlmostEqual(self, a, b, rel_eps = 2e-15, abs_eps = 5e-323): + """Check that two floating-point numbers are almost equal.""" + + # test passes if either the absolute error or the relative + # error is sufficiently small. The defaults amount to an + # error of between 9 ulps and 19 ulps on an IEEE-754 compliant + # machine. + + try: + absolute_error = abs(b-a) + except OverflowError: + pass + else: + if absolute_error <= max(abs_eps, rel_eps * abs(a)): + return + self.fail("%s and %s are not sufficiently close" % (repr(a), repr(b))) def test_constants(self): e_expected = 2.71828182845904523536 pi_expected = 3.14159265358979323846 - self.assertAlmostEqual(cmath.pi, pi_expected, 9, + self.rAssertAlmostEqual(cmath.pi, pi_expected, 9, "cmath.pi is %s; should be %s" % (cmath.pi, pi_expected)) - self.assertAlmostEqual(cmath.e, e_expected, 9, + self.rAssertAlmostEqual(cmath.e, e_expected, 9, "cmath.e is %s; should be %s" % (cmath.e, e_expected)) def test_user_object(self): @@ -109,13 +122,13 @@ for f in self.test_functions: # usual usage - self.cAssertAlmostEqual(f(MyComplex(cx_arg)), f(cx_arg)) - self.cAssertAlmostEqual(f(MyComplexOS(cx_arg)), f(cx_arg)) + self.assertEqual(f(MyComplex(cx_arg)), f(cx_arg)) + self.assertEqual(f(MyComplexOS(cx_arg)), f(cx_arg)) # other combinations of __float__ and __complex__ - self.cAssertAlmostEqual(f(FloatAndComplex()), f(cx_arg)) - self.cAssertAlmostEqual(f(FloatAndComplexOS()), f(cx_arg)) - self.cAssertAlmostEqual(f(JustFloat()), f(flt_arg)) - self.cAssertAlmostEqual(f(JustFloatOS()), f(flt_arg)) + self.assertEqual(f(FloatAndComplex()), f(cx_arg)) + self.assertEqual(f(FloatAndComplexOS()), f(cx_arg)) + self.assertEqual(f(JustFloat()), f(flt_arg)) + self.assertEqual(f(JustFloatOS()), f(flt_arg)) # TypeError should be raised for classes not providing # either __complex__ or __float__, even if they provide # __int__, __long__ or __index__. An old-style class @@ -138,7 +151,7 @@ # functions, by virtue of providing a __float__ method for f in self.test_functions: for arg in [2, 2L, 2.]: - self.cAssertAlmostEqual(f(arg), f(arg.__float__())) + self.assertEqual(f(arg), f(arg.__float__())) # but strings should give a TypeError for f in self.test_functions: @@ -182,12 +195,34 @@ float_fn = getattr(math, fn) complex_fn = getattr(cmath, fn) for v in values: - self.cAssertAlmostEqual(float_fn(v), complex_fn(v)) + z = complex_fn(v) + self.rAssertAlmostEqual(float_fn(v), z.real) + self.assertEqual(0., z.imag) # test two-argument version of log with various bases for base in [0.5, 2., 10.]: for v in positive: - self.cAssertAlmostEqual(cmath.log(v, base), math.log(v, base)) + z = cmath.log(v, base) + self.rAssertAlmostEqual(math.log(v, base), z.real) + self.assertEqual(0., z.imag) + + def test_specific_values(self): + if not float.__getformat__("double").startswith("IEEE"): + return + for id, fn, ar, ai, er, ei in parse_testfile(test_file): + arg = complex(ar, ai) + expected = complex(er, ei) + function = getattr(cmath, fn) + actual = function(arg) + + if fn=='log': + # for the real part of the log function, we allow an + # absolute error of up to 2e-15. + self.rAssertAlmostEqual(expected.real, actual.real, + abs_eps = 2e-15) + else: + self.rAssertAlmostEqual(expected.real, actual.real) + self.rAssertAlmostEqual(expected.imag, actual.imag) def test_main(): run_unittest(CMathTests) Modified: python/branches/trunk-math/Lib/test/test_math.py ============================================================================== --- python/branches/trunk-math/Lib/test/test_math.py (original) +++ python/branches/trunk-math/Lib/test/test_math.py Tue Jan 22 12:46:53 2008 @@ -4,9 +4,42 @@ from test.test_support import run_unittest, verbose import unittest import math +import os +import sys -seps='1e-05' -eps = eval(seps) +eps = 1E-05 +NAN = float('nan') +INF = float('inf') +NINF = float('-inf') + +# locate file with test values +if __name__ == '__main__': + file = sys.argv[0] +else: + file = __file__ +testdir = os.path.dirname(file) or os.curdir +test_file = os.path.join(testdir, 'cmath.ctest') + +def parse_testfile(fname): + """Parse a file with test values + + Empty lines or lines starting with -- are ignored + yields id, fn, arg_real, arg_imag, exp_real, exp_imag + """ + with open(fname) as fp: + for line in fp: + # skip comment lines and blank lines + if line.startswith('--') or not line.strip(): + continue + + lhs, rhs = line.split('->') + id, fn, arg_real, arg_imag = lhs.split() + exp_real, exp_imag = rhs.split() + + yield (id, fn, + float(arg_real), float(arg_imag), + float(exp_real), float(exp_imag) + ) class MathTests(unittest.TestCase): @@ -28,18 +61,57 @@ self.ftest('acos(-1)', math.acos(-1), math.pi) self.ftest('acos(0)', math.acos(0), math.pi/2) self.ftest('acos(1)', math.acos(1), 0) + self.assertRaises(ValueError, math.acos, INF) + self.assertRaises(ValueError, math.acos, NINF) + self.assert_(math.isnan(math.acos(NAN))) + + def testAcosh(self): + self.assertRaises(TypeError, math.acosh) + self.ftest('acosh(1)', math.acosh(1), 0) + self.ftest('acosh(2)', math.acosh(2), 1.3169578969248168) + self.assertRaises(ValueError, math.acosh, 0) + self.assertRaises(ValueError, math.acosh, -1) + self.assertRaises(OverflowError, math.acosh, INF) + self.assertRaises(ValueError, math.acosh, NINF) + self.assert_(math.isnan(math.acosh(NAN))) def testAsin(self): self.assertRaises(TypeError, math.asin) self.ftest('asin(-1)', math.asin(-1), -math.pi/2) self.ftest('asin(0)', math.asin(0), 0) self.ftest('asin(1)', math.asin(1), math.pi/2) + self.assertRaises(ValueError, math.asin, INF) + self.assertRaises(ValueError, math.asin, NINF) + self.assert_(math.isnan(math.asin(NAN))) + + def testAsinh(self): + self.assertRaises(TypeError, math.asinh) + self.ftest('asinh(0)', math.asinh(0), 0) + self.ftest('asinh(1)', math.asinh(1), 0.88137358701954305) + self.ftest('asinh(-1)', math.asinh(-1), -0.88137358701954305) + self.assertRaises(OverflowError, math.asinh, INF) + self.assertRaises(OverflowError, math.asinh, NINF) + self.assert_(math.isnan(math.asinh(NAN))) def testAtan(self): self.assertRaises(TypeError, math.atan) self.ftest('atan(-1)', math.atan(-1), -math.pi/4) self.ftest('atan(0)', math.atan(0), 0) self.ftest('atan(1)', math.atan(1), math.pi/4) + self.ftest('atan(inf)', math.atan(INF), math.pi/2) + self.ftest('atan(-inf)', math.atan(-INF), -math.pi/2) + self.assert_(math.isnan(math.atan(NAN))) + + def testAtanh(self): + self.assertRaises(TypeError, math.atan) + self.ftest('atanh(0)', math.atanh(0), 0) + self.ftest('atanh(0.5)', math.atanh(0.5), 0.54930614433405489) + self.ftest('atanh(-0.5)', math.atanh(-0.5), -0.54930614433405489) + self.assertRaises(ValueError, math.atanh, 1) + self.assertRaises(ValueError, math.atanh, -1) + self.assertRaises(ValueError, math.atanh, INF) + self.assertRaises(ValueError, math.atanh, NINF) + self.assert_(math.isnan(math.atanh(NAN))) def testAtan2(self): self.assertRaises(TypeError, math.atan2) @@ -61,6 +133,9 @@ self.ftest('ceil(-0.5)', math.ceil(-0.5), 0) self.ftest('ceil(-1.0)', math.ceil(-1.0), -1) self.ftest('ceil(-1.5)', math.ceil(-1.5), -1) + self.assertRaises(OverflowError, math.ceil, INF) + self.assertRaises(OverflowError, math.ceil, NINF) + self.assert_(math.isnan(math.ceil(NAN))) class TestCeil(object): def __float__(self): @@ -81,11 +156,17 @@ self.ftest('cos(0)', math.cos(0), 1) self.ftest('cos(pi/2)', math.cos(math.pi/2), 0) self.ftest('cos(pi)', math.cos(math.pi), -1) + self.assertRaises(ValueError, math.cos, INF) + self.assertRaises(ValueError, math.cos, NINF) + self.assert_(math.isnan(math.cos(NAN))) def testCosh(self): self.assertRaises(TypeError, math.cosh) self.ftest('cosh(0)', math.cosh(0), 1) self.ftest('cosh(2)-2*cosh(1)**2', math.cosh(2)-2*math.cosh(1)**2, -1) # Thanks to Lambert + self.assertRaises(OverflowError, math.cosh, INF) + self.assertRaises(OverflowError, math.cosh, NINF) + self.assert_(math.isnan(math.cosh(NAN))) def testDegrees(self): self.assertRaises(TypeError, math.degrees) @@ -98,6 +179,9 @@ self.ftest('exp(-1)', math.exp(-1), 1/math.e) self.ftest('exp(0)', math.exp(0), 1) self.ftest('exp(1)', math.exp(1), math.e) + self.assertRaises(OverflowError, math.exp, INF) + self.ftest('exp(-INF)', math.exp(NINF), 0) + self.assert_(math.isnan(math.exp(NAN))) def testFabs(self): self.assertRaises(TypeError, math.fabs) @@ -121,6 +205,9 @@ # This fails on some platforms - so check it here self.ftest('floor(1.23e167)', math.floor(1.23e167), 1.23e167) self.ftest('floor(-1.23e167)', math.floor(-1.23e167), -1.23e167) + self.assertRaises(OverflowError, math.floor, INF) + self.assertRaises(OverflowError, math.floor, NINF) + self.assert_(math.isnan(math.floor(NAN))) class TestFloor(object): def __float__(self): @@ -177,12 +264,28 @@ self.ftest('log(32,2)', math.log(32,2), 5) self.ftest('log(10**40, 10)', math.log(10**40, 10), 40) self.ftest('log(10**40, 10**20)', math.log(10**40, 10**20), 2) + self.assertRaises(OverflowError, math.log, INF) + self.assertRaises(ValueError, math.log, NINF) + self.assert_(math.isnan(math.log(NAN))) + + def testLog1p(self): + self.assertRaises(TypeError, math.log1p) + self.ftest('log1p(1/e -1)', math.log1p(1/math.e-1), -1) + self.ftest('log1p(0)', math.log1p(0), 0) + self.ftest('log1p(e-1)', math.log1p(math.e-1), 1) + self.ftest('log1p(1)', math.log1p(1), math.log(2)) + self.assertRaises(OverflowError, math.log1p, INF) + self.assertRaises(ValueError, math.log1p, NINF) + self.assert_(math.isnan(math.log1p(NAN))) def testLog10(self): self.assertRaises(TypeError, math.log10) self.ftest('log10(0.1)', math.log10(0.1), -1) self.ftest('log10(1)', math.log10(1), 0) self.ftest('log10(10)', math.log10(10), 1) + self.assertRaises(OverflowError, math.log10, INF) + self.assertRaises(ValueError, math.log10, NINF) + self.assert_(math.isnan(math.log10(NAN))) def testModf(self): self.assertRaises(TypeError, math.modf) @@ -201,6 +304,12 @@ self.ftest('pow(1,0)', math.pow(1,0), 1) self.ftest('pow(2,1)', math.pow(2,1), 2) self.ftest('pow(2,-1)', math.pow(2,-1), 0.5) + self.assertRaises(OverflowError, math.pow, INF, 1) + self.assertRaises(ValueError, math.pow, 1, INF) + self.assertRaises(OverflowError, math.pow, NINF, 1) + self.assertRaises(ValueError, math.pow, 1, NINF) + self.assert_(math.isnan(math.pow(NAN, 1))) + self.assert_(math.isnan(math.pow(1, NAN))) def testRadians(self): self.assertRaises(TypeError, math.radians) @@ -213,29 +322,44 @@ self.ftest('sin(0)', math.sin(0), 0) self.ftest('sin(pi/2)', math.sin(math.pi/2), 1) self.ftest('sin(-pi/2)', math.sin(-math.pi/2), -1) + self.assertRaises(ValueError, math.sin, INF) + self.assertRaises(ValueError, math.sin, NINF) + self.assert_(math.isnan(math.sin(NAN))) def testSinh(self): self.assertRaises(TypeError, math.sinh) self.ftest('sinh(0)', math.sinh(0), 0) self.ftest('sinh(1)**2-cosh(1)**2', math.sinh(1)**2-math.cosh(1)**2, -1) self.ftest('sinh(1)+sinh(-1)', math.sinh(1)+math.sinh(-1), 0) + self.assertRaises(OverflowError, math.sinh, INF) + self.assertRaises(OverflowError, math.sinh, NINF) + self.assert_(math.isnan(math.sinh(NAN))) def testSqrt(self): self.assertRaises(TypeError, math.sqrt) self.ftest('sqrt(0)', math.sqrt(0), 0) self.ftest('sqrt(1)', math.sqrt(1), 1) self.ftest('sqrt(4)', math.sqrt(4), 2) + self.assertRaises(OverflowError, math.sqrt, INF) + self.assertRaises(ValueError, math.sqrt, NINF) + self.assert_(math.isnan(math.sqrt(NAN))) def testTan(self): self.assertRaises(TypeError, math.tan) self.ftest('tan(0)', math.tan(0), 0) self.ftest('tan(pi/4)', math.tan(math.pi/4), 1) self.ftest('tan(-pi/4)', math.tan(-math.pi/4), -1) + self.assertRaises(ValueError, math.tan, INF) + self.assertRaises(ValueError, math.tan, NINF) + self.assert_(math.isnan(math.tan(NAN))) def testTanh(self): self.assertRaises(TypeError, math.tanh) self.ftest('tanh(0)', math.tanh(0), 0) self.ftest('tanh(1)+tanh(-1)', math.tanh(1)+math.tanh(-1), 0) + self.ftest('tanh(inf)', math.tanh(INF), 1) + self.ftest('tanh(-inf)', math.tanh(NINF), -1) + self.assert_(math.isnan(math.tanh(NAN))) def testCopysign(self): self.assertEqual(math.copysign(1, 42), 1.0) @@ -298,6 +422,16 @@ else: self.fail("sqrt(-1) didn't raise ValueError") + def test_testfile(self): + if not float.__getformat__("double").startswith("IEEE"): + return + for id, fn, ar, ai, er, ei in parse_testfile(test_file): + # Skip if either input or result is complex + if ai != 0. or ei != 0.: + continue + func = getattr(math, fn) + result = func(ar) + self.ftest("%s:%s(%r)" % (id, fn, ar), result, er) def test_main(): run_unittest(MathTests) Modified: python/branches/trunk-math/Makefile.pre.in ============================================================================== --- python/branches/trunk-math/Makefile.pre.in (original) +++ python/branches/trunk-math/Makefile.pre.in Tue Jan 22 12:46:53 2008 @@ -272,6 +272,7 @@ Python/peephole.o \ Python/pyarena.o \ Python/pyfpe.o \ + Python/pymath.o \ Python/pystate.o \ Python/pythonrun.o \ Python/structmember.o \ @@ -570,6 +571,7 @@ Include/pydebug.h \ Include/pyerrors.h \ Include/pyfpe.h \ + Include/pymath.h \ Include/pygetopt.h \ Include/pymem.h \ Include/pyport.h \ Modified: python/branches/trunk-math/Misc/NEWS ============================================================================== --- python/branches/trunk-math/Misc/NEWS (original) +++ python/branches/trunk-math/Misc/NEWS Tue Jan 22 12:46:53 2008 @@ -17,6 +17,11 @@ - Issue #1882: when compiling code from a string, encoding cookies in the second line of code were not always recognized correctly. +- Issue #XXXX: Four new methods were added to the math and cmath modules: + acosh, asinh, atanh and log1p. Replacement implementations for platforms + without the four functions and copysign in libm were added to a new file + Python/pymath.c. + - Issue #1679: "0x" was taken as a valid integer literal. - Issue #1865: Bytes as an alias for str and b"" as an alias "" were Modified: python/branches/trunk-math/Modules/cmathmodule.c ============================================================================== --- python/branches/trunk-math/Modules/cmathmodule.c (original) +++ python/branches/trunk-math/Modules/cmathmodule.c Tue Jan 22 12:46:53 2008 @@ -4,30 +4,73 @@ #include "Python.h" -#ifndef M_PI -#define M_PI (3.141592653589793239) +/* we need DBL_MAX, DBL_MIN, DBL_EPSILON and DBL_MANT_DIG from float.h */ +/* We assume that FLT_RADIX is 2, not 10 or 16. */ +#include + +#ifndef M_LN2 +#define M_LN2 (0.6931471805599453094) /* natural log of 2 */ #endif -/* First, the C functions that do the real work */ +#ifndef M_LN10 +#define M_LN10 (2.302585092994045684) /* natural log of 10 */ +#endif + +/* + CM_LARGE_DOUBLE is used to avoid spurious overflow in the sqrt, log, + inverse trig and inverse hyperbolic trig functions. Its log is used in the + evaluation of exp, cos, cosh, sin, sinh, tan, and tanh to avoid unecessary + overflow. + */ + +#define CM_LARGE_DOUBLE (DBL_MAX/4.) +#define CM_SQRT_LARGE_DOUBLE (sqrt(CM_LARGE_DOUBLE)) +#define CM_LOG_LARGE_DOUBLE (log(CM_LARGE_DOUBLE)) +#define CM_SQRT_DBL_MIN (sqrt(DBL_MIN)) + +/* CM_SCALE_UP defines the power of 2 to multiply by to turn a subnormal into + a normal; used in sqrt. must be odd */ +#define CM_SCALE_UP 2*(DBL_MANT_DIG/2) + 1 +#define CM_SCALE_DOWN -(DBL_MANT_DIG/2 + 1) + -/* constants */ -static Py_complex c_one = {1., 0.}; -static Py_complex c_half = {0.5, 0.}; -static Py_complex c_i = {0., 1.}; -static Py_complex c_halfi = {0., 0.5}; /* forward declarations */ -static Py_complex c_log(Py_complex); -static Py_complex c_prodi(Py_complex); +static Py_complex c_asinh(Py_complex); +static Py_complex c_atanh(Py_complex); +static Py_complex c_cosh(Py_complex); +static Py_complex c_sinh(Py_complex); static Py_complex c_sqrt(Py_complex); +static Py_complex c_tanh(Py_complex); static PyObject * math_error(void); +/* First, the C functions that do the real work */ static Py_complex -c_acos(Py_complex x) +c_acos(Py_complex z) { - return c_neg(c_prodi(c_log(c_sum(x,c_prod(c_i, - c_sqrt(c_diff(c_one,c_prod(x,x)))))))); + Py_complex s1, s2, r; + if (fabs(z.real) > CM_LARGE_DOUBLE || fabs(z.imag) > CM_LARGE_DOUBLE) { + /* avoid unnecessary overflow for large arguments */ + r.real = atan2(fabs(z.imag), z.real); + /* split into cases to make sure that the branch cut has the + correct continuity on systems with unsigned zeros */ + if (z.real < 0.) { + r.imag = -copysign(log(hypot(z.real/2., z.imag/2.)) + M_LN2*2., z.imag); + } else { + r.imag = copysign(log(hypot(z.real/2., z.imag/2.)) + M_LN2*2., -z.imag); + } + } else { + s1.real = 1.-z.real; + s1.imag = -z.imag; + s1 = c_sqrt(s1); + s2.real = 1.+z.real; + s2.imag = z.imag; + s2 = c_sqrt(s2); + r.real = 2.*atan2(s1.real, s2.real); + r.imag = asinh(s2.real*s1.imag - s2.imag*s1.real); + } + return r; } PyDoc_STRVAR(c_acos_doc, @@ -37,13 +80,25 @@ static Py_complex -c_acosh(Py_complex x) +c_acosh(Py_complex z) { - Py_complex z; - z = c_sqrt(c_half); - z = c_log(c_prod(z, c_sum(c_sqrt(c_sum(x,c_one)), - c_sqrt(c_diff(x,c_one))))); - return c_sum(z, z); + Py_complex s1, s2, r; + + if (fabs(z.real) > CM_LARGE_DOUBLE || fabs(z.imag) > CM_LARGE_DOUBLE) { + /* avoid unnecessary overflow for large arguments */ + r.real = log(hypot(z.real/2., z.imag/2.)) + M_LN2*2.; + r.imag = atan2(z.imag, z.real); + } else { + s1.real = z.real - 1.; + s1.imag = z.imag; + s1 = c_sqrt(s1); + s2.real = z.real + 1.; + s2.imag = z.imag; + s2 = c_sqrt(s2); + r.real = asinh(s1.real*s2.real + s1.imag*s2.imag); + r.imag = 2.*atan2(s1.imag, s2.real); + } + return r; } PyDoc_STRVAR(c_acosh_doc, @@ -53,14 +108,16 @@ static Py_complex -c_asin(Py_complex x) +c_asin(Py_complex z) { - /* -i * log[(sqrt(1-x**2) + i*x] */ - const Py_complex squared = c_prod(x, x); - const Py_complex sqrt_1_minus_x_sq = c_sqrt(c_diff(c_one, squared)); - return c_neg(c_prodi(c_log( - c_sum(sqrt_1_minus_x_sq, c_prodi(x)) - ) ) ); + /* asin(z) = -i asinh(iz) */ + Py_complex s, r; + s.real = -z.imag; + s.imag = z.real; + s = c_asinh(s); + r.real = s.imag; + r.imag = -s.real; + return r; } PyDoc_STRVAR(c_asin_doc, @@ -70,13 +127,28 @@ static Py_complex -c_asinh(Py_complex x) +c_asinh(Py_complex z) { - Py_complex z; - z = c_sqrt(c_half); - z = c_log(c_prod(z, c_sum(c_sqrt(c_sum(x, c_i)), - c_sqrt(c_diff(x, c_i))))); - return c_sum(z, z); + Py_complex s1, s2, r; + + if (fabs(z.real) > CM_LARGE_DOUBLE || fabs(z.imag) > CM_LARGE_DOUBLE) { + if (z.imag >= 0.) { + r.real = copysign(log(hypot(z.real/2., z.imag/2.)) + M_LN2*2., z.real); + } else { + r.real = -copysign(log(hypot(z.real/2., z.imag/2.)) + M_LN2*2., -z.real); + } + r.imag = atan2(z.imag, fabs(z.real)); + } else { + s1.real = 1.+z.imag; + s1.imag = -z.real; + s1 = c_sqrt(s1); + s2.real = 1.-z.imag; + s2.imag = z.real; + s2 = c_sqrt(s2); + r.real = asinh(s1.real*s2.imag-s2.real*s1.imag); + r.imag = atan2(z.imag, s1.real*s2.real-s1.imag*s2.imag); + } + return r; } PyDoc_STRVAR(c_asinh_doc, @@ -86,9 +158,16 @@ static Py_complex -c_atan(Py_complex x) +c_atan(Py_complex z) { - return c_prod(c_halfi,c_log(c_quot(c_sum(c_i,x),c_diff(c_i,x)))); + /* atan(z) = -i atanh(iz) */ + Py_complex s, r; + s.real = -z.imag; + s.imag = z.real; + s = c_atanh(s); + r.real = s.imag; + r.imag = -s.real; + return r; } PyDoc_STRVAR(c_atan_doc, @@ -98,9 +177,43 @@ static Py_complex -c_atanh(Py_complex x) +c_atanh(Py_complex z) { - return c_prod(c_half,c_log(c_quot(c_sum(c_one,x),c_diff(c_one,x)))); + Py_complex r; + double ay, h; + + /* Reduce to case where z.real >= 0., using atanh(z) = -atanh(-z). */ + if (z.real < 0.) { + return c_neg(c_atanh(c_neg(z))); + } + + ay = fabs(z.imag); + if (z.real > CM_SQRT_LARGE_DOUBLE || ay > CM_SQRT_LARGE_DOUBLE) { + /* + if abs(z) is large then we use the approximation + atanh(z) ~ 1/z +/- i*pi/2 (+/- depending on the sign + of z.imag) + */ + h = hypot(z.real/2., z.imag/2.); /* safe from overflow */ + r.real = z.real/4./h/h; + /* the two negations in the next line cancel each other out + except when working with unsigned zeros: they're there to + ensure that the branch cut has the correct continuity on + systems that don't support signed zeros */ + r.imag = -copysign(Py_MATH_PI/2., -z.imag); + } else if (z.real == 1. && ay < CM_SQRT_DBL_MIN) { + /* C99 standard says: atanh(1+/-0.) should be inf +/- 0i */ + r.real = -log(sqrt(ay)/sqrt(hypot(ay, 2.))); + if (ay == 0.) { + r.imag = z.imag; + } else { + r.imag = copysign(atan2(2., -ay)/2, z.imag); + } + } else { + r.real = log1p(4.*z.real/((1-z.real)*(1-z.real) + ay*ay))/4.; + r.imag = -atan2(-2.*z.imag, (1-z.real)*(1+z.real) - ay*ay)/2.; + } + return r; } PyDoc_STRVAR(c_atanh_doc, @@ -110,11 +223,13 @@ static Py_complex -c_cos(Py_complex x) +c_cos(Py_complex z) { + /* cos(z) = cosh(iz) */ Py_complex r; - r.real = cos(x.real)*cosh(x.imag); - r.imag = -sin(x.real)*sinh(x.imag); + r.real = -z.imag; + r.imag = z.real; + r = c_cosh(r); return r; } @@ -125,11 +240,21 @@ static Py_complex -c_cosh(Py_complex x) +c_cosh(Py_complex z) { Py_complex r; - r.real = cos(x.imag)*cosh(x.real); - r.imag = sin(x.imag)*sinh(x.real); + double x_minus_one; + + if (fabs(z.real) > CM_LOG_LARGE_DOUBLE) { + /* deal correctly with cases where cosh(z.real) overflows but + cosh(z) does not. */ + x_minus_one = z.real - copysign(1., z.real); + r.real = cos(z.imag) * cosh(x_minus_one) * Py_MATH_E; + r.imag = sin(z.imag) * sinh(x_minus_one) * Py_MATH_E; + } else { + r.real = cos(z.imag) * cosh(z.real); + r.imag = sin(z.imag) * sinh(z.real); + } return r; } @@ -140,12 +265,20 @@ static Py_complex -c_exp(Py_complex x) +c_exp(Py_complex z) { Py_complex r; - double l = exp(x.real); - r.real = l*cos(x.imag); - r.imag = l*sin(x.imag); + double l; + + if (z.real > CM_LOG_LARGE_DOUBLE) { + l = exp(z.real-1.); + r.real = l*cos(z.imag)*Py_MATH_E; + r.imag = l*sin(z.imag)*Py_MATH_E; + } else { + l = exp(z.real); + r.real = l*cos(z.imag); + r.imag = l*sin(z.imag); + } return r; } @@ -156,23 +289,70 @@ static Py_complex -c_log(Py_complex x) +c_log(Py_complex z) { - Py_complex r; - double l = hypot(x.real,x.imag); - r.imag = atan2(x.imag, x.real); - r.real = log(l); + /* + The usual formula for the real part is log(hypot(z.real, z.imag)). + There are four situations where this formula is potentially + problematic: + + (1) the absolute value of z is subnormal. Then hypot is subnormal, + so has fewer than the usual number of bits of accuracy, hence may + have large relative error. This then gives a large absolute error + in the log. This can be solved by rescaling z by a suitable power + of 2. + + (2) the absolute value of z is greater than DBL_MAX (e.g. when both + z.real and z.imag are within a factor of 1/sqrt(2) of DBL_MAX) + Again, rescaling solves this. + + (3) the absolute value of z is close to 1. In this case it's + difficult to achieve good accuracy, at least in part because a + change of 1ulp in the real or imaginary part of z can result in a + change of billions of ulps in the correctly rounded answer. + + (4) z = 0. The simplest thing to do here is to call the + floating-point log with an argument of 0, and let its behaviour + (returning -infinity, signaling a floating-point exception, setting + errno, or whatever) determine that of c_log. So the usual formula + is fine here. + + */ + + Py_complex r; + double ax, ay, am, an, h; + + ax = fabs(z.real); + ay = fabs(z.imag); + + if (ax > CM_LARGE_DOUBLE || ay > CM_LARGE_DOUBLE) { + r.real = log(hypot(ax/2., ay/2.)) + M_LN2; + } else if (ax < DBL_MIN && ay < DBL_MIN && (ax > 0. || ay > 0.)) { + /* catch cases where hypot(ax, ay) is subnormal */ + r.real = log(hypot(ldexp(ax, DBL_MANT_DIG), ldexp(ay, DBL_MANT_DIG))) - DBL_MANT_DIG*M_LN2; + } else { + h = hypot(ax, ay); + if (0.71 <= h && h <= 1.73) { + am = ax > ay ? ax : ay; /* max(ax, ay) */ + an = ax > ay ? ay : ax; /* min(ax, ay) */ + r.real = log1p((am-1)*(am+1)+an*an)/2.; + } else { + r.real = log(h); + } + } + r.imag = atan2(z.imag, z.real); return r; } static Py_complex -c_log10(Py_complex x) +c_log10(Py_complex z) { Py_complex r; - double l = hypot(x.real,x.imag); - r.imag = atan2(x.imag, x.real)/log(10.); - r.real = log10(l); + + r = c_log(z); + r.real = r.real / M_LN10; + r.imag = r.imag / M_LN10; return r; } @@ -182,23 +362,16 @@ "Return the base-10 logarithm of x."); -/* internal function not available from Python */ static Py_complex -c_prodi(Py_complex x) +c_sin(Py_complex z) { - Py_complex r; - r.real = -x.imag; - r.imag = x.real; - return r; -} - - -static Py_complex -c_sin(Py_complex x) -{ - Py_complex r; - r.real = sin(x.real) * cosh(x.imag); - r.imag = cos(x.real) * sinh(x.imag); + /* sin(z) = -i sin(iz) */ + Py_complex s, r; + s.real = -z.imag; + s.imag = z.real; + s = c_sinh(s); + r.real = s.imag; + r.imag = -s.real; return r; } @@ -209,12 +382,21 @@ static Py_complex -c_sinh(Py_complex x) +c_sinh(Py_complex z) { Py_complex r; - r.real = cos(x.imag) * sinh(x.real); - r.imag = sin(x.imag) * cosh(x.real); + double x_minus_one; + + if (fabs(z.real) > CM_LOG_LARGE_DOUBLE) { + x_minus_one = z.real - copysign(1., z.real); + r.real = cos(z.imag) * sinh(x_minus_one) * Py_MATH_E; + r.imag = sin(z.imag) * cosh(x_minus_one) * Py_MATH_E; + } else { + r.real = cos(z.imag) * sinh(z.real); + r.imag = sin(z.imag) * cosh(z.real); + } return r; + } PyDoc_STRVAR(c_sinh_doc, @@ -224,27 +406,64 @@ static Py_complex -c_sqrt(Py_complex x) +c_sqrt(Py_complex z) { + /* + Method: use symmetries to reduce to the case when x = z.real and y + = z.imag are nonnegative. Then the real part of the result is + given by + + s = sqrt((x + hypot(x, y))/2) + + and the imaginary part is + + d = (y/2)/s + + If either x or y is very large then there's a risk of overflow in + computation of the expression x + hypot(x, y). We can avoid this + by rewriting the formula for s as: + + s = 2*sqrt(x/8 + hypot(x/8, y/8)) + + This costs us two extra multiplications/divisions, but avoids the + overhead of checking for x and y large. + + If both x and y are subnormal then hypot(x, y) may also be + subnormal, so will lack full precision. We solve this by rescaling + x and y by a sufficiently large power of 2 to ensure that x and y + are normal. + */ + + Py_complex r; double s,d; - if (x.real == 0. && x.imag == 0.) - r = x; - else { - s = sqrt(0.5*(fabs(x.real) + hypot(x.real,x.imag))); - d = 0.5*x.imag/s; - if (x.real > 0.) { - r.real = s; - r.imag = d; - } - else if (x.imag >= 0.) { - r.real = d; - r.imag = s; - } - else { - r.real = -d; - r.imag = -s; - } + double ax, ay; + + if (z.real == 0. && z.imag == 0.) { + r.real = 0.; + r.imag = z.imag; + return r; + } + + ax = fabs(z.real); + ay = fabs(z.imag); + + if (ax < DBL_MIN && ay < DBL_MIN && (ax > 0. || ay > 0.)) { + /* here we catch cases where hypot(ax, ay) is subnormal */ + ax = ldexp(ax, CM_SCALE_UP); + s = ldexp(sqrt(ax + hypot(ax, ldexp(ay, CM_SCALE_UP))), CM_SCALE_DOWN); + } else { + ax /= 8.; + s = 2.*sqrt(ax + hypot(ax, ay/8.)); + } + d = ay/(2.*s); + + if (z.real >= 0.) { + r.real = s; + r.imag = copysign(d, z.imag); + } else { + r.real = d; + r.imag = copysign(s, z.imag); } return r; } @@ -256,23 +475,15 @@ static Py_complex -c_tan(Py_complex x) +c_tan(Py_complex z) { - Py_complex r; - double sr,cr,shi,chi; - double rs,is,rc,ic; - double d; - sr = sin(x.real); - cr = cos(x.real); - shi = sinh(x.imag); - chi = cosh(x.imag); - rs = sr * chi; - is = cr * shi; - rc = cr * chi; - ic = -sr * shi; - d = rc*rc + ic * ic; - r.real = (rs*rc + is*ic) / d; - r.imag = (is*rc - rs*ic) / d; + /* tan(z) = -i tanh(iz) */ + Py_complex s, r; + s.real = -z.imag; + s.imag = z.real; + s = c_tanh(s); + r.real = s.imag; + r.imag = -s.real; return r; } @@ -283,23 +494,35 @@ static Py_complex -c_tanh(Py_complex x) +c_tanh(Py_complex z) { - Py_complex r; - double si,ci,shr,chr; - double rs,is,rc,ic; - double d; - si = sin(x.imag); - ci = cos(x.imag); - shr = sinh(x.real); - chr = cosh(x.real); - rs = ci * shr; - is = si * chr; - rc = ci * chr; - ic = si * shr; - d = rc*rc + ic*ic; - r.real = (rs*rc + is*ic) / d; - r.imag = (is*rc - rs*ic) / d; + /* Formula: + + tanh(x+iy) = (tanh(x)(1+tan(y)^2) + i tan(y)(1-tanh(x))^2) / + (1+tan(y)^2 tanh(x)^2) + + To avoid excessive roundoff error, 1-tanh(x)^2 is better computed + as 1/cosh(x)^2. When abs(x) is large, we approximate 1-tanh(x)^2 + by 4 exp(-2*x) instead, to avoid possible overflow in the + computation of cosh(x). + + */ + + Py_complex r; + double tx, ty, cx, txty, denom; + + if (fabs(z.real) > CM_LOG_LARGE_DOUBLE) { + r.real = copysign(1., z.real); + r.imag = 2.*sin(2.*z.imag)*exp(-2.*fabs(z.real)); + } else { + tx = tanh(z.real); + ty = tan(z.imag); + cx = 1./cosh(z.real); + txty = tx*ty; + denom = 1. + txty*txty; + r.real = tx*(1.+ty*ty)/denom; + r.imag = ((ty/denom)*cx)*cx; + } return r; } @@ -323,9 +546,9 @@ if (PyTuple_GET_SIZE(args) == 2) x = c_quot(x, c_log(y)); PyFPE_END_PROTECT(x) + Py_ADJUST_ERANGE2(x.real, x.imag); if (errno != 0) return math_error(); - Py_ADJUST_ERANGE2(x.real, x.imag); return PyComplex_FromCComplex(x); } @@ -421,6 +644,6 @@ return; PyModule_AddObject(m, "pi", - PyFloat_FromDouble(atan(1.0) * 4.0)); - PyModule_AddObject(m, "e", PyFloat_FromDouble(exp(1.0))); + PyFloat_FromDouble(Py_MATH_PI)); + PyModule_AddObject(m, "e", PyFloat_FromDouble(Py_MATH_E)); } Modified: python/branches/trunk-math/Modules/mathmodule.c ============================================================================== --- python/branches/trunk-math/Modules/mathmodule.c (original) +++ python/branches/trunk-math/Modules/mathmodule.c Tue Jan 22 12:46:53 2008 @@ -3,15 +3,6 @@ #include "Python.h" #include "longintrepr.h" /* just for SHIFT */ -#ifndef _MSC_VER -#ifndef __STDC__ -extern double fmod (double, double); -extern double frexp (double, int *); -extern double ldexp (double, int); -extern double modf (double, double *); -#endif /* __STDC__ */ -#endif /* _MSC_VER */ - /* Call is_error when errno != 0, and where x is the result libm * returned. is_error will usually set up an exception and return * true (1), but may return false (0) without setting up an exception. @@ -53,6 +44,10 @@ double x = PyFloat_AsDouble(arg); if (x == -1.0 && PyErr_Occurred()) return NULL; +#ifndef __GNUC__ /* Windows et al */ + if (Py_IS_NAN(x)) + return PyFloat_FromDouble(x+x); +#endif errno = 0; PyFPE_START_PROTECT("in math_1", return 0) x = (*func)(x); @@ -75,6 +70,10 @@ y = PyFloat_AsDouble(oy); if ((x == -1.0 || y == -1.0) && PyErr_Occurred()) return NULL; +#ifndef __GNUC__ /* Windows et al */ + if (Py_IS_NAN(x) || Py_IS_NAN(y)) + return PyFloat_FromDouble(x+y); +#endif errno = 0; PyFPE_START_PROTECT("in math_2", return 0) x = (*func)(x, y); @@ -100,13 +99,19 @@ FUNC1(acos, acos, "acos(x)\n\nReturn the arc cosine (measured in radians) of x.") +FUNC1(acosh, acosh, + "acosh(x)\n\nReturn the hyperbolic arc cosine (measured in radians) of x.") FUNC1(asin, asin, "asin(x)\n\nReturn the arc sine (measured in radians) of x.") +FUNC1(asinh, asinh, + "asinh(x)\n\nReturn the hyperbolic arc sine (measured in radians) of x.") FUNC1(atan, atan, "atan(x)\n\nReturn the arc tangent (measured in radians) of x.") FUNC2(atan2, atan2, "atan2(y, x)\n\nReturn the arc tangent (measured in radians) of y/x.\n" "Unlike atan(y/x), the signs of both x and y are considered.") +FUNC1(atanh, atanh, + "atanh(x)\n\nReturn the hyperbolic arc tangent (measured in radians) of x.") FUNC1(ceil, ceil, "ceil(x)\n\nReturn the ceiling of x as a float.\n" "This is the smallest integral value >= x.") @@ -114,16 +119,8 @@ "cos(x)\n\nReturn the cosine of x (measured in radians).") FUNC1(cosh, cosh, "cosh(x)\n\nReturn the hyperbolic cosine of x.") - -#ifdef MS_WINDOWS -# define copysign _copysign -# define HAVE_COPYSIGN 1 -#endif -#ifdef HAVE_COPYSIGN FUNC2(copysign, copysign, "copysign(x,y)\n\nReturn x with the sign of y."); -#endif - FUNC1(exp, exp, "exp(x)\n\nReturn e raised to the power of x.") FUNC1(fabs, fabs, @@ -279,6 +276,38 @@ If the base not specified, returns the natural logarithm (base e) of x."); static PyObject * +math_log1p(PyObject *self, PyObject *args) +{ + PyObject *arg; + PyObject *base = NULL; + PyObject *num, *den; + PyObject *ans; + + if (!PyArg_UnpackTuple(args, "log1p", 1, 2, &arg, &base)) + return NULL; + + num = loghelper(arg, log1p, "log"); + if (num == NULL || base == NULL) + return num; + + den = loghelper(base, log1p, "log"); + if (den == NULL) { + Py_DECREF(num); + return NULL; + } + + ans = PyNumber_Divide(num, den); + Py_DECREF(num); + Py_DECREF(den); + return ans; +} + +PyDoc_STRVAR(math_log1p_doc, +"log1p(x[, base]) -> the logarithm of 1+x to the given base.\n\ +If the base not specified, returns the natural logarithm (base e) of x.\n\ +The result is computed in a way which is accurate for x near zero."); + +static PyObject * math_log10(PyObject *self, PyObject *arg) { return loghelper(arg, log10, "log10"); @@ -343,13 +372,14 @@ static PyMethodDef math_methods[] = { {"acos", math_acos, METH_O, math_acos_doc}, + {"acosh", math_acosh, METH_O, math_acosh_doc}, {"asin", math_asin, METH_O, math_asin_doc}, + {"asinh", math_asinh, METH_O, math_asinh_doc}, {"atan", math_atan, METH_O, math_atan_doc}, {"atan2", math_atan2, METH_VARARGS, math_atan2_doc}, + {"atanh", math_atanh, METH_O, math_atanh_doc}, {"ceil", math_ceil, METH_O, math_ceil_doc}, -#ifdef HAVE_COPYSIGN {"copysign", math_copysign, METH_VARARGS, math_copysign_doc}, -#endif {"cos", math_cos, METH_O, math_cos_doc}, {"cosh", math_cosh, METH_O, math_cosh_doc}, {"degrees", math_degrees, METH_O, math_degrees_doc}, @@ -363,6 +393,7 @@ {"isnan", math_isnan, METH_O, math_isnan_doc}, {"ldexp", math_ldexp, METH_VARARGS, math_ldexp_doc}, {"log", math_log, METH_VARARGS, math_log_doc}, + {"log1p", math_log1p, METH_VARARGS, math_log1p_doc}, {"log10", math_log10, METH_O, math_log10_doc}, {"modf", math_modf, METH_O, math_modf_doc}, {"pow", math_pow, METH_VARARGS, math_pow_doc}, Modified: python/branches/trunk-math/PC/pyconfig.h ============================================================================== --- python/branches/trunk-math/PC/pyconfig.h (original) +++ python/branches/trunk-math/PC/pyconfig.h Tue Jan 22 12:46:53 2008 @@ -202,12 +202,13 @@ #endif /* MS_WIN32 && !MS_WIN64 */ typedef int pid_t; -#define hypot _hypot #include #define Py_IS_NAN _isnan #define Py_IS_INFINITY(X) (!_finite(X) && !_isnan(X)) #define Py_IS_FINITE(X) _finite(X) +#define copysign _copysign +#define hypot _hypot #endif /* _MSC_VER */ @@ -387,7 +388,7 @@ /* Fairly standard from here! */ /* Define to 1 if you have the `copysign' function. */ -/* #define HAVE_COPYSIGN 1*/ +#define HAVE_COPYSIGN 1 /* Define to 1 if you have the `isinf' function. */ #define HAVE_ISINF 1 Modified: python/branches/trunk-math/PCbuild/pythoncore.vcproj ============================================================================== --- python/branches/trunk-math/PCbuild/pythoncore.vcproj (original) +++ python/branches/trunk-math/PCbuild/pythoncore.vcproj Tue Jan 22 12:46:53 2008 @@ -863,6 +863,10 @@ > + + @@ -1707,6 +1711,10 @@ > + + Deleted: /python/branches/trunk-math/Python/hypot.c ============================================================================== --- /python/branches/trunk-math/Python/hypot.c Tue Jan 22 12:46:53 2008 +++ (empty file) @@ -1,25 +0,0 @@ -/* hypot() replacement */ - -#include "Python.h" - -#ifndef HAVE_HYPOT -double hypot(double x, double y) -{ - double yx; - - x = fabs(x); - y = fabs(y); - if (x < y) { - double temp = x; - x = y; - y = temp; - } - if (x == 0.) - return 0.; - else { - yx = y/x; - return x*sqrt(1.+yx*yx); - } -} -#endif /* HAVE_HYPOT */ - Added: python/branches/trunk-math/Python/pymath.c ============================================================================== --- (empty file) +++ python/branches/trunk-math/Python/pymath.c Tue Jan 22 12:46:53 2008 @@ -0,0 +1,234 @@ +#include "Python.h" + +#ifndef HAVE_HYPOT +double hypot(double x, double y) +{ + double yx; + + x = fabs(x); + y = fabs(y); + if (x < y) { + double temp = x; + x = y; + y = temp; + } + if (x == 0.) + return 0.; + else { + yx = y/x; + return x*sqrt(1.+yx*yx); + } +} +#endif /* HAVE_HYPOT */ + +#ifndef HAVE_COPYSIGN +static double +copysign(double x, double y) +{ + /* use atan2 to distinguish -0. from 0. */ + if (y > 0. || (y == 0. && atan2(y, -1.) > 0.)) { + return fabs(x); + } else { + return -fabs(x); + } +} +#endif /* HAVE_COPYSIGN */ + +#ifndef HAVE_LOG1P +double +log1p(double x) +{ + /* For x small, we use the following approach. Let y be the nearest + float to 1+x, then + + 1+x = y * (1 - (y-1-x)/y) + + so log(1+x) = log(y) + log(1-(y-1-x)/y). Since (y-1-x)/y is tiny, + the second term is well approximated by (y-1-x)/y. If abs(x) >= + DBL_EPSILON/2 or the rounding-mode is some form of round-to-nearest + then y-1-x will be exactly representable, and is computed exactly + by (y-1)-x. + + If abs(x) < DBL_EPSILON/2 and the rounding mode is not known to be + round-to-nearest then this method is slightly dangerous: 1+x could + be rounded up to 1+DBL_EPSILON instead of down to 1, and in that + case y-1-x will not be exactly representable any more and the + result can be off by many ulps. But this is easily fixed: for a + floating-point number |x| < DBL_EPSILON/2., the closest + floating-point number to log(1+x) is exactly x. + */ + + double y; + if (fabs(x) < DBL_EPSILON/2.) { + return x; + } else if (-0.5 <= x && x <= 1.) { + /* WARNING: it's possible than an overeager compiler + will incorrectly optimize the following two lines + to the equivalent of "return log(1.+x)". If this + happens, then results from log1p will be inaccurate + for small x. */ + y = 1.+x; + return log(y)-((y-1.)-x)/y; + } else { + /* NaNs and infinities should end up here */ + return log(1.+x); + } +} +#endif /* HAVE_LOG1P */ + +/* + * ==================================================== + * Copyright (C) 1993 by Sun Microsystems, Inc. All rights reserved. + * + * Developed at SunPro, a Sun Microsystems, Inc. business. + * Permission to use, copy, modify, and distribute this + * software is freely granted, provided that this notice + * is preserved. + * ==================================================== + */ + +static const double ln2 = 6.93147180559945286227E-01; +static const double huge = 1E+300; +static const double two_pow_m28 = 3.7252902984619141E-09; /* 2**-28 */ +static const double two_pow_p28 = 268435456.0; /* 2**28 */ +static const double zero = 0.0; + +/* asinh(x) + * Method : + * Based on + * asinh(x) = sign(x) * log [ |x| + sqrt(x*x+1) ] + * we have + * asinh(x) := x if 1+x*x=1, + * := sign(x)*(log(x)+ln2)) for large |x|, else + * := sign(x)*log(2|x|+1/(|x|+sqrt(x*x+1))) if|x|>2, else + * := sign(x)*log1p(|x| + x^2/(1 + sqrt(1+x^2))) + */ + +#ifndef HAVE_ASINH +double +asinh(double x) +{ + double w; + double absx = fabs(x); + + if (Py_IS_NAN(x) || Py_IS_INFINITY(x)) { + return x+x; + } + if (absx < two_pow_m28) { /* |x| < 2**-28 */ + if ((huge + x) > 1.0) + return x; /* return x inexact except 0 */ + } + if (absx > two_pow_p28) { /* |x| > 2**28 */ + w = log(absx)+ln2; + } + else if (absx > 2.0) { /* 2 < |x| < 2**28 */ + w = log(2.0*absx + 1.0 / (sqrt(x*x + 1.0) + absx)); + } + else { /* 2**-28 <= |x| < 2= */ + double t = x*x; + w = log1p(absx + t / (1.0 + sqrt(1.0 + t))); + } + return copysign(w, x); + +} +#endif /* HAVE_ASINH */ + +/* acosh(x) + * Method : + * Based on + * acosh(x) = log [ x + sqrt(x*x-1) ] + * we have + * acosh(x) := log(x)+ln2, if x is large; else + * acosh(x) := log(2x-1/(sqrt(x*x-1)+x)) if x>2; else + * acosh(x) := log1p(t+sqrt(2.0*t+t*t)); where t=x-1. + * + * Special cases: + * acosh(x) is NaN with signal if x<1. + * acosh(NaN) is NaN without signal. + */ + +#ifndef HAVE_ACOSH +double +acosh(double x) +{ + if (Py_IS_NAN(x)) { + return x+x; + } + if (x < 1.) { /* x < 1; return a signaling NaN */ + errno = EDOM; +#ifdef Py_NAN + return Py_NAN; +#else + return (x-x)/(x-x); +#endif + } + else if (x >= two_pow_p28) { /* x > 2**28 */ + if (Py_IS_INFINITY(x)) { + return x+x; + } else { + return log(x)+ln2; /* acosh(huge)=log(2x) */ + } + } + else if (x == 1.) { + return 0.0; /* acosh(1) = 0 */ + } + else if (x > 2.) { /* 2 < x < 2**28 */ + double t = x*x; + return log(2.0*x - 1.0 / (x + sqrt(t - 1.0))); + } + else { /* 1 < x <= 2 */ + double t = x - 1.0; + return log1p(t + sqrt(2.0*t + t*t)); + } +} +#endif /* HAVE_ACOSH */ + +/* atanh(x) + * Method : + * 1.Reduced x to positive by atanh(-x) = -atanh(x) + * 2.For x>=0.5 + * 1 2x x + * atanh(x) = --- * log(1 + -------) = 0.5 * log1p(2 * --------) + * 2 1 - x 1 - x + * + * For x<0.5 + * atanh(x) = 0.5*log1p(2x+2x*x/(1-x)) + * + * Special cases: + * atanh(x) is NaN if |x| >= 1 with signal; + * atanh(NaN) is that NaN with no signal; + * + */ + +#ifndef HAVE_ATANH +double +atanh(double x) +{ + double absx; + double t; + + if (Py_IS_NAN(x)) { + return x+x; + } + absx = fabs(x); + if (absx >= 1.) { /* |x| >= 1 */ + errno = EDOM; +#ifdef Py_NAN + return Py_NAN; +#else + return x/zero; +#endif + } + if (absx < two_pow_m28) { /* |x| < 2**-28 */ + return x; + } + if (absx < 0.5) { /* |x| < 0.5 */ + t = absx+absx; + t = 0.5 * log1p(t + t*absx / (1.0 - absx)); + } + else { /* 0.5 <= |x| <= 1.0 */ + t = 0.5 * log1p((absx + absx) / (1.0 - absx)); + } + return copysign(t, x); +} +#endif /* HAVE_ATANH */ \ No newline at end of file Modified: python/branches/trunk-math/pyconfig.h.in ============================================================================== --- python/branches/trunk-math/pyconfig.h.in (original) +++ python/branches/trunk-math/pyconfig.h.in Tue Jan 22 12:46:53 2008 @@ -147,6 +147,9 @@ /* Defined when any dynamic module loading is enabled. */ #undef HAVE_DYNAMIC_LOADING +/* Define if you have the 'epoll' functions. */ +#undef HAVE_EPOLL + /* Define to 1 if you have the header file. */ #undef HAVE_ERRNO_H @@ -318,6 +321,9 @@ /* Define to 1 if you have the `killpg' function. */ #undef HAVE_KILLPG +/* Define if you have the 'kqueue' functions. */ +#undef HAVE_KQUEUE + /* Define to 1 if you have the header file. */ #undef HAVE_LANGINFO_H @@ -630,6 +636,12 @@ */ #undef HAVE_SYS_DIR_H +/* Define to 1 if you have the header file. */ +#undef HAVE_SYS_EPOLL_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_SYS_EVENT_H + /* Define to 1 if you have the header file. */ #undef HAVE_SYS_FILE_H @@ -1058,3 +1070,4 @@ #endif /*Py_PYCONFIG_H*/ + From python-checkins at python.org Tue Jan 22 16:01:25 2008 From: python-checkins at python.org (christian.heimes) Date: Tue, 22 Jan 2008 16:01:25 +0100 (CET) Subject: [Python-checkins] r60198 - python/trunk/Include/pyport.h Message-ID: <20080122150125.7C0811E402E@bag.python.org> Author: christian.heimes Date: Tue Jan 22 16:01:25 2008 New Revision: 60198 Modified: python/trunk/Include/pyport.h Log: Fixed a missing (X) in define Modified: python/trunk/Include/pyport.h ============================================================================== --- python/trunk/Include/pyport.h (original) +++ python/trunk/Include/pyport.h Tue Jan 22 16:01:25 2008 @@ -406,7 +406,7 @@ */ #ifndef Py_IS_FINITE #ifdef HAVE_FINITE -#define Py_IS_FINITE(X) finite +#define Py_IS_FINITE(X) finite(X) #else #define Py_IS_FINITE(X) (!Py_IS_INFINITY(X) && !Py_IS_NAN(X)) #endif From python-checkins at python.org Tue Jan 22 16:25:18 2008 From: python-checkins at python.org (christian.heimes) Date: Tue, 22 Jan 2008 16:25:18 +0100 (CET) Subject: [Python-checkins] r60199 - in python/trunk: Doc/c-api/module.rst Include/modsupport.h Message-ID: <20080122152518.5C2EB1E401C@bag.python.org> Author: christian.heimes Date: Tue Jan 22 16:25:18 2008 New Revision: 60199 Modified: python/trunk/Doc/c-api/module.rst python/trunk/Include/modsupport.h Log: Don't repeat yourself Added the macros PyModule_AddIntMacro and PyModule_AddStringMacro. They shorten PyModule_AddIntConstant(m, "AF_INET", AF_INET) to PyModule_AddIntMacro(m, AF_INET) Modified: python/trunk/Doc/c-api/module.rst ============================================================================== --- python/trunk/Doc/c-api/module.rst (original) +++ python/trunk/Doc/c-api/module.rst Tue Jan 22 16:25:18 2008 @@ -18,7 +18,7 @@ is exposed to Python programs as ``types.ModuleType``. -.. cfunction:: int PyModule_Check(PyObject *p) +.. cmacro:: int PyModule_Check(PyObject *p) Return true if *p* is a module object, or a subtype of a module object. @@ -26,7 +26,7 @@ Allowed subtypes to be accepted. -.. cfunction:: int PyModule_CheckExact(PyObject *p) +.. cmacro:: int PyModule_CheckExact(PyObject *p) Return true if *p* is a module object, but not a subtype of :cdata:`PyModule_Type`. @@ -103,3 +103,19 @@ null-terminated. Return ``-1`` on error, ``0`` on success. .. versionadded:: 2.0 + +.. cmacro:: int PyModule_AddIntMacro(PyObject *module, macro) + + Add an int constant to *module*. The name and the value are taken from + *macro*. For example ``PyModule_AddConstant(module, AF_INET)`` adds the int + constant *AF_INET* with the value of *AF_INET* to *module*. + Return ``-1`` on error, ``0`` on success. + + .. versionadded:: 2.6 + +.. cmacro:: int PyModule_AddStringMacro(PyObject *module, macro) + + Add a string constant to *module*. + + .. versionadded:: 2.6 + Modified: python/trunk/Include/modsupport.h ============================================================================== --- python/trunk/Include/modsupport.h (original) +++ python/trunk/Include/modsupport.h Tue Jan 22 16:25:18 2008 @@ -40,7 +40,8 @@ PyAPI_FUNC(int) PyModule_AddObject(PyObject *, const char *, PyObject *); PyAPI_FUNC(int) PyModule_AddIntConstant(PyObject *, const char *, long); PyAPI_FUNC(int) PyModule_AddStringConstant(PyObject *, const char *, const char *); - +#define PyModule_AddIntMacro(m, c) PyModule_AddIntConstant(m, #c, c) +#define PyModule_AddStringMacro(m, c) PyModule_AddStringConstant(m, #c, c) #define PYTHON_API_VERSION 1013 #define PYTHON_API_STRING "1013" From python-checkins at python.org Tue Jan 22 20:02:47 2008 From: python-checkins at python.org (georg.brandl) Date: Tue, 22 Jan 2008 20:02:47 +0100 (CET) Subject: [Python-checkins] r60200 - doctools/trunk/sphinx/builder.py Message-ID: <20080122190247.BA68A1E402C@bag.python.org> Author: georg.brandl Date: Tue Jan 22 20:02:47 2008 New Revision: 60200 Modified: doctools/trunk/sphinx/builder.py Log: Fix. Modified: doctools/trunk/sphinx/builder.py ============================================================================== --- doctools/trunk/sphinx/builder.py (original) +++ doctools/trunk/sphinx/builder.py Tue Jan 22 20:02:47 2008 @@ -31,7 +31,6 @@ ensuredir, relative_uri, os_path, SEP) from sphinx.htmlhelp import build_hhx from sphinx.extension import DummyEventManager, import_object -from sphinx.patchlevel import get_version_info, get_sys_version_info from sphinx.htmlwriter import HTMLWriter, HTMLTranslator, SmartyPantsHTMLTranslator from sphinx.latexwriter import LaTeXWriter from sphinx.environment import BuildEnvironment, NoUri From python-checkins at python.org Tue Jan 22 20:51:42 2008 From: python-checkins at python.org (raymond.hettinger) Date: Tue, 22 Jan 2008 20:51:42 +0100 (CET) Subject: [Python-checkins] r60201 - python/trunk/Doc/library/itertools.rst Message-ID: <20080122195142.150AC1E4035@bag.python.org> Author: raymond.hettinger Date: Tue Jan 22 20:51:41 2008 New Revision: 60201 Modified: python/trunk/Doc/library/itertools.rst Log: Document when to use izip_longest(). Modified: python/trunk/Doc/library/itertools.rst ============================================================================== --- python/trunk/Doc/library/itertools.rst (original) +++ python/trunk/Doc/library/itertools.rst Tue Jan 22 20:51:41 2008 @@ -269,22 +269,13 @@ When no iterables are specified, returns a zero length iterator instead of raising a :exc:`TypeError` exception. - Note, the left-to-right evaluation order of the iterables is guaranteed. This - makes possible an idiom for clustering a data series into n-length groups using - ``izip(*[iter(s)]*n)``. For data that doesn't fit n-length groups exactly, the - last tuple can be pre-padded with fill values using ``izip(*[chain(s, - [None]*(n-1))]*n)``. - - Note, when :func:`izip` is used with unequal length inputs, subsequent - iteration over the longer iterables cannot reliably be continued after - :func:`izip` terminates. Potentially, up to one entry will be missing from - each of the left-over iterables. This occurs because a value is fetched from - each iterator in turn, but the process ends when one of the iterators - terminates. This leaves the last fetched values in limbo (they cannot be - returned in a final, incomplete tuple and they are cannot be pushed back into - the iterator for retrieval with ``it.next()``). In general, :func:`izip` - should only be used with unequal length inputs when you don't care about - trailing, unmatched values from the longer iterables. + The left-to-right evaluation order of the iterables is guaranteed. This + makes possible an idiom for clustering a data series into n-length groups + using ``izip(*[iter(s)]*n)``. + + :func:`izip` should only be used with unequal length inputs when you don't + care about trailing, unmatched values from the longer iterables. If those + values are important, use :func:`izip_longest` instead. .. function:: izip_longest(*iterables[, fillvalue]) From python-checkins at python.org Tue Jan 22 20:56:03 2008 From: python-checkins at python.org (georg.brandl) Date: Tue, 22 Jan 2008 20:56:03 +0100 (CET) Subject: [Python-checkins] r60202 - in python/trunk: Lib/test/test_mmap.py Modules/mmapmodule.c Message-ID: <20080122195603.E221E1E4025@bag.python.org> Author: georg.brandl Date: Tue Jan 22 20:56:03 2008 New Revision: 60202 Modified: python/trunk/Lib/test/test_mmap.py python/trunk/Modules/mmapmodule.c Log: Fix for #1087741 patch. Modified: python/trunk/Lib/test/test_mmap.py ============================================================================== --- python/trunk/Lib/test/test_mmap.py (original) +++ python/trunk/Lib/test/test_mmap.py Tue Jan 22 20:56:03 2008 @@ -420,6 +420,13 @@ except OSError: pass + def test_subclass(self): + class anon_mmap(mmap.mmap): + def __new__(klass, *args, **kwargs): + return mmap.mmap.__new__(klass, -1, *args, **kwargs) + anon_mmap(PAGESIZE) + + def test_main(): run_unittest(MmapTests) Modified: python/trunk/Modules/mmapmodule.c ============================================================================== --- python/trunk/Modules/mmapmodule.c (original) +++ python/trunk/Modules/mmapmodule.c Tue Jan 22 20:56:03 2008 @@ -129,7 +129,7 @@ } #endif /* UNIX */ - PyObject_Del(m_obj); + m_obj->ob_type->tp_free((PyObject*)m_obj); } static PyObject * From python-checkins at python.org Tue Jan 22 21:18:53 2008 From: python-checkins at python.org (raymond.hettinger) Date: Tue, 22 Jan 2008 21:18:53 +0100 (CET) Subject: [Python-checkins] r60203 - python/trunk/Doc/library/functions.rst Message-ID: <20080122201853.8C84E1E4023@bag.python.org> Author: raymond.hettinger Date: Tue Jan 22 21:18:53 2008 New Revision: 60203 Modified: python/trunk/Doc/library/functions.rst Log: Give zip() the same guarantee as izip() for left-to-right evaluation. Modified: python/trunk/Doc/library/functions.rst ============================================================================== --- python/trunk/Doc/library/functions.rst (original) +++ python/trunk/Doc/library/functions.rst Tue Jan 22 21:18:53 2008 @@ -1285,6 +1285,10 @@ sequence argument, it returns a list of 1-tuples. With no arguments, it returns an empty list. + The left-to-right evaluation order of the iterables is guaranteed. This + makes possible an idiom for clustering a data series into n-length groups + using ``zip(*[iter(s)]*n)``. + .. versionadded:: 2.0 .. versionchanged:: 2.4 From nnorwitz at gmail.com Tue Jan 22 22:06:23 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Tue, 22 Jan 2008 16:06:23 -0500 Subject: [Python-checkins] Python Regression Test Failures doc (1) Message-ID: <20080122210623.GA4884@python.psfb.org> svn update tools/sphinx svn: PROPFIND request failed on '/projects/doctools/trunk/sphinx' svn: PROPFIND of '/projects/doctools/trunk/sphinx': could not connect to server (http://svn.python.org) make: *** [update] Error 1 From python-checkins at python.org Tue Jan 22 23:09:26 2008 From: python-checkins at python.org (raymond.hettinger) Date: Tue, 22 Jan 2008 23:09:26 +0100 (CET) Subject: [Python-checkins] r60204 - python/trunk/Doc/library/itertools.rst Message-ID: <20080122220926.9A1BD1E400D@bag.python.org> Author: raymond.hettinger Date: Tue Jan 22 23:09:26 2008 New Revision: 60204 Modified: python/trunk/Doc/library/itertools.rst Log: Improve variable name in sample code Modified: python/trunk/Doc/library/itertools.rst ============================================================================== --- python/trunk/Doc/library/itertools.rst (original) +++ python/trunk/Doc/library/itertools.rst Tue Jan 22 23:09:26 2008 @@ -218,7 +218,7 @@ def imap(function, *iterables): iterables = map(iter, iterables) while True: - args = [i.next() for i in iterables] + args = [it.next() for it in iterables] if function is None: yield tuple(args) else: From python-checkins at python.org Wed Jan 23 00:15:34 2008 From: python-checkins at python.org (gregory.p.smith) Date: Wed, 23 Jan 2008 00:15:34 +0100 (CET) Subject: [Python-checkins] r60205 - python/trunk/Lib/ftplib.py Message-ID: <20080122231534.7C0ED1E400D@bag.python.org> Author: gregory.p.smith Date: Wed Jan 23 00:15:34 2008 New Revision: 60205 Modified: python/trunk/Lib/ftplib.py Log: docstring and comment updates suggested by Giampaolo Rodola' Modified: python/trunk/Lib/ftplib.py ============================================================================== --- python/trunk/Lib/ftplib.py (original) +++ python/trunk/Lib/ftplib.py Wed Jan 23 00:15:34 2008 @@ -313,7 +313,7 @@ expected size may be None if it could not be determined. Optional `rest' argument can be a string that is sent as the - argument to a RESTART command. This is essentially a server + argument to a REST command. This is essentially a server marker used to tell the server to skip over any data up to the given marker. """ @@ -403,7 +403,7 @@ """Retrieve data in line mode. A new port is created for you. Args: - cmd: A RETR or LIST command. + cmd: A RETR, LIST, NLST, or MLSD command. callback: An optional single parameter callable that is called for each line with the trailing CRLF stripped. [default: print_line()] @@ -539,7 +539,7 @@ def size(self, filename): '''Retrieve the size of a file.''' - # Note that the RFC doesn't say anything about 'SIZE' + # The SIZE command is defined in RFC-3659 resp = self.sendcmd('SIZE ' + filename) if resp[:3] == '213': s = resp[3:].strip() From buildbot at python.org Wed Jan 23 00:43:30 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 22 Jan 2008 23:43:30 +0000 Subject: [Python-checkins] buildbot failure in x86 gentoo trunk Message-ID: <20080122234330.2E4931E400D@bag.python.org> The Buildbot has detected a new failure of x86 gentoo trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20gentoo%20trunk/builds/2915 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-x86 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: gregory.p.smith,raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 477, in __bootstrap_inner self.run() File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 437, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30996, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Traceback (most recent call last): File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 477, in __bootstrap_inner self.run() File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 437, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30996, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Traceback (most recent call last): File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 477, in __bootstrap_inner self.run() File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 437, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30996, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Traceback (most recent call last): File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 477, in __bootstrap_inner self.run() File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 437, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30996, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Traceback (most recent call last): File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 477, in __bootstrap_inner self.run() File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 437, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30996, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') 1 test failed: test_urllib2net ====================================================================== ERROR: test_ftp (test.test_urllib2net.OtherNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/test/test_urllib2net.py", line 175, in test_ftp self._test_urls(urls, self._extra_handlers()) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/test/test_urllib2net.py", line 244, in _test_urls f = urllib2.urlopen(url, req) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/urllib2.py", line 124, in urlopen return _opener.open(url, data, timeout) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/urllib2.py", line 380, in open response = self._open(req, data) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/urllib2.py", line 398, in _open '_open', req) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/urllib2.py", line 358, in _call_chain result = func(*args) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/urllib2.py", line 1284, in ftp_open fp, retrlen = fw.retrfile(file, type) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/urllib.py", line 880, in retrfile self.ftp.cwd(file) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/ftplib.py", line 538, in cwd return self.voidcmd(cmd) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/ftplib.py", line 247, in voidcmd return self.voidresp() File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/ftplib.py", line 222, in voidresp resp = self.getresp() File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/ftplib.py", line 217, in getresp raise error_perm, resp TypeError: __init__() takes exactly 2 arguments (3 given) make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Wed Jan 23 01:04:41 2008 From: python-checkins at python.org (raymond.hettinger) Date: Wed, 23 Jan 2008 01:04:41 +0100 (CET) Subject: [Python-checkins] r60207 - in python/trunk: Doc/library/pprint.rst Lib/pprint.py Misc/NEWS Message-ID: <20080123000441.0E4CA1E400D@bag.python.org> Author: raymond.hettinger Date: Wed Jan 23 01:04:40 2008 New Revision: 60207 Modified: python/trunk/Doc/library/pprint.rst python/trunk/Lib/pprint.py python/trunk/Misc/NEWS Log: Let pprint() support sets and frozensets (suggested by David Mertz). Modified: python/trunk/Doc/library/pprint.rst ============================================================================== --- python/trunk/Doc/library/pprint.rst (original) +++ python/trunk/Doc/library/pprint.rst Wed Jan 23 01:04:40 2008 @@ -25,6 +25,9 @@ dictionary was sorted only if its display required more than one line, although that wasn't documented. +.. versionchanged:: 2.6 + Added support for :class:`set` and :class:`frozenset`. + The :mod:`pprint` module defines one class: .. First the implementation class: Modified: python/trunk/Lib/pprint.py ============================================================================== --- python/trunk/Lib/pprint.py (original) +++ python/trunk/Lib/pprint.py Wed Jan 23 01:04:40 2008 @@ -162,11 +162,24 @@ write('}') return - if (issubclass(typ, list) and r is list.__repr__) or \ - (issubclass(typ, tuple) and r is tuple.__repr__): + if ((issubclass(typ, list) and r is list.__repr__) or + (issubclass(typ, tuple) and r is tuple.__repr__) or + (issubclass(typ, set) and r is set.__repr__) or + (issubclass(typ, frozenset) and r is frozenset.__repr__) + ): if issubclass(typ, list): write('[') endchar = ']' + elif issubclass(typ, set): + write('set([') + endchar = '])' + object = sorted(object) + indent += 4 + elif issubclass(typ, frozenset): + write('frozenset([') + endchar = '])' + object = sorted(object) + indent += 9 else: write('(') endchar = ')' Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Wed Jan 23 01:04:40 2008 @@ -378,6 +378,8 @@ Library ------- +- The pprint module now supports sets and frozensets. + - #1221598: add optional callbacks to ftplib.FTP's storbinary() and storlines() methods. (Contributed by Phil Schwartz) From guido at python.org Wed Jan 23 01:27:50 2008 From: guido at python.org (Guido van Rossum) Date: Tue, 22 Jan 2008 16:27:50 -0800 Subject: [Python-checkins] r60207 - in python/trunk: Doc/library/pprint.rst Lib/pprint.py Misc/NEWS In-Reply-To: <20080123000441.0E4CA1E400D@bag.python.org> References: <20080123000441.0E4CA1E400D@bag.python.org> Message-ID: On Jan 22, 2008 4:04 PM, raymond.hettinger wrote: > Author: raymond.hettinger > Date: Wed Jan 23 01:04:40 2008 > New Revision: 60207 > > Modified: > python/trunk/Doc/library/pprint.rst > python/trunk/Lib/pprint.py > python/trunk/Misc/NEWS > Log: > Let pprint() support sets and frozensets (suggested by David Mertz). Kewl! Some 3.0 notes below. > Modified: python/trunk/Doc/library/pprint.rst > ============================================================================== > --- python/trunk/Doc/library/pprint.rst (original) > +++ python/trunk/Doc/library/pprint.rst Wed Jan 23 01:04:40 2008 > @@ -25,6 +25,9 @@ > dictionary was sorted only if its display required more than one line, although > that wasn't documented. > > +.. versionchanged:: 2.6 > + Added support for :class:`set` and :class:`frozenset`. > + > The :mod:`pprint` module defines one class: > > .. First the implementation class: > > Modified: python/trunk/Lib/pprint.py > ============================================================================== > --- python/trunk/Lib/pprint.py (original) > +++ python/trunk/Lib/pprint.py Wed Jan 23 01:04:40 2008 > @@ -162,11 +162,24 @@ > write('}') > return > > - if (issubclass(typ, list) and r is list.__repr__) or \ > - (issubclass(typ, tuple) and r is tuple.__repr__): > + if ((issubclass(typ, list) and r is list.__repr__) or > + (issubclass(typ, tuple) and r is tuple.__repr__) or > + (issubclass(typ, set) and r is set.__repr__) or > + (issubclass(typ, frozenset) and r is frozenset.__repr__) > + ): > if issubclass(typ, list): > write('[') > endchar = ']' > + elif issubclass(typ, set): > + write('set([') > + endchar = '])' > + object = sorted(object) > + indent += 4 Warning: this should be done differently in 3.0 -- if the set is non-empty, it should write '{' and set endchar to '}'. And indent should vary accordingly. An empty set could be shortened to 'set()' instead of 'set([])'. > + elif issubclass(typ, frozenset): > + write('frozenset([') > + endchar = '])' > + object = sorted(object) > + indent += 9 And here, if the set is non-empty, write 'frozenset({' and set endchar to '})'; if it is empty, use 'frozenset()' if possible. > else: > write('(') > endchar = ')' > > Modified: python/trunk/Misc/NEWS > ============================================================================== > --- python/trunk/Misc/NEWS (original) > +++ python/trunk/Misc/NEWS Wed Jan 23 01:04:40 2008 > @@ -378,6 +378,8 @@ > Library > ------- > > +- The pprint module now supports sets and frozensets. > + > - #1221598: add optional callbacks to ftplib.FTP's storbinary() and > storlines() methods. (Contributed by Phil Schwartz) > > _______________________________________________ > Python-checkins mailing list > Python-checkins at python.org > http://mail.python.org/mailman/listinfo/python-checkins > -- --Guido van Rossum (home page: http://www.python.org/~guido/) From python at rcn.com Wed Jan 23 01:46:30 2008 From: python at rcn.com (Raymond Hettinger) Date: Tue, 22 Jan 2008 19:46:30 -0500 (EST) Subject: [Python-checkins] r60207 - in python/trunk: Doc/library/pprint.rst Lib/pprint.py Misc/NEWS Message-ID: <20080122194630.AFN26415@ms19.lnh.mail.rcn.net> [GvR] > Warning: this should be done differently in 3.0 -- > if the set is non-empty, it should write '{' and set > endchar to '}'. What is the right procedure for this sort of thing? Should I wait for the next merge and then add the customization? Should I let it live on the head a bit to see if there is more commentary? Raymond From guido at python.org Wed Jan 23 02:04:42 2008 From: guido at python.org (Guido van Rossum) Date: Tue, 22 Jan 2008 17:04:42 -0800 Subject: [Python-checkins] r60207 - in python/trunk: Doc/library/pprint.rst Lib/pprint.py Misc/NEWS In-Reply-To: <20080122194630.AFN26415@ms19.lnh.mail.rcn.net> References: <20080122194630.AFN26415@ms19.lnh.mail.rcn.net> Message-ID: On Jan 22, 2008 4:46 PM, Raymond Hettinger wrote: > [GvR] > > Warning: this should be done differently in 3.0 -- > > if the set is non-empty, it should write '{' and set > > endchar to '}'. > > What is the right procedure for this sort of thing? > Should I wait for the next merge and then add the > customization? Yes, or you could do the next merge yourself. Christian can help you with the procedure if you need it. > Should I let it live on the head a > bit to see if there is more commentary? Only if you worry that this would be controversial, which I doubt in this particular case. -- --Guido van Rossum (home page: http://www.python.org/~guido/) From python-checkins at python.org Wed Jan 23 02:18:28 2008 From: python-checkins at python.org (guido.van.rossum) Date: Wed, 23 Jan 2008 02:18:28 +0100 (CET) Subject: [Python-checkins] r60208 - python/trunk/Lib/test/test_grp.py python/trunk/Lib/test/test_pwd.py Message-ID: <20080123011828.322801E4002@bag.python.org> Author: guido.van.rossum Date: Wed Jan 23 02:18:27 2008 New Revision: 60208 Modified: python/trunk/Lib/test/test_grp.py python/trunk/Lib/test/test_pwd.py Log: I'm tired of these tests breaking at Google due to our large number of users and groups in LDAP/NIS. So I'm limiting the extra-heavy part of the tests to passwd/group files with at most 1000 entries. Modified: python/trunk/Lib/test/test_grp.py ============================================================================== --- python/trunk/Lib/test/test_grp.py (original) +++ python/trunk/Lib/test/test_grp.py Wed Jan 23 02:18:27 2008 @@ -25,6 +25,9 @@ for e in entries: self.check_value(e) + if len(entries) > 1000: # Huge group file (NIS?) -- skip the rest + return + for e in entries: e2 = grp.getgrgid(e.gr_gid) self.check_value(e2) Modified: python/trunk/Lib/test/test_pwd.py ============================================================================== --- python/trunk/Lib/test/test_pwd.py (original) +++ python/trunk/Lib/test/test_pwd.py Wed Jan 23 02:18:27 2008 @@ -35,6 +35,9 @@ entriesbyname.setdefault(e.pw_name, []).append(e) entriesbyuid.setdefault(e.pw_uid, []).append(e) + if len(entries) > 1000: # Huge passwd file (NIS?) -- skip the rest + return + # check whether the entry returned by getpwuid() # for each uid is among those from getpwall() for this uid for e in entries: From python-checkins at python.org Wed Jan 23 02:20:27 2008 From: python-checkins at python.org (guido.van.rossum) Date: Wed, 23 Jan 2008 02:20:27 +0100 (CET) Subject: [Python-checkins] r60209 - python/branches/release25-maint/Lib/test/test_grp.py python/branches/release25-maint/Lib/test/test_pwd.py Message-ID: <20080123012027.307411E4002@bag.python.org> Author: guido.van.rossum Date: Wed Jan 23 02:20:26 2008 New Revision: 60209 Modified: python/branches/release25-maint/Lib/test/test_grp.py python/branches/release25-maint/Lib/test/test_pwd.py Log: Backport r60208, skip some tests for huge passwd/group files. Modified: python/branches/release25-maint/Lib/test/test_grp.py ============================================================================== --- python/branches/release25-maint/Lib/test/test_grp.py (original) +++ python/branches/release25-maint/Lib/test/test_grp.py Wed Jan 23 02:20:26 2008 @@ -25,6 +25,9 @@ for e in entries: self.check_value(e) + if len(entries) > 1000: # Huge group file (NIS?) -- skip the rest + return + for e in entries: e2 = grp.getgrgid(e.gr_gid) self.check_value(e2) Modified: python/branches/release25-maint/Lib/test/test_pwd.py ============================================================================== --- python/branches/release25-maint/Lib/test/test_pwd.py (original) +++ python/branches/release25-maint/Lib/test/test_pwd.py Wed Jan 23 02:20:26 2008 @@ -35,6 +35,9 @@ entriesbyname.setdefault(e.pw_name, []).append(e) entriesbyuid.setdefault(e.pw_uid, []).append(e) + if len(entries) > 1000: # Huge passwd file (NIS?) -- skip the rest + return + # check whether the entry returned by getpwuid() # for each uid is among those from getpwall() for this uid for e in entries: From lists at cheimes.de Wed Jan 23 09:38:24 2008 From: lists at cheimes.de (Christian Heimes) Date: Wed, 23 Jan 2008 09:38:24 +0100 Subject: [Python-checkins] r60207 - in python/trunk: Doc/library/pprint.rst Lib/pprint.py Misc/NEWS In-Reply-To: References: <20080122194630.AFN26415@ms19.lnh.mail.rcn.net> Message-ID: Guido van Rossum wrote: > Yes, or you could do the next merge yourself. Christian can help you > with the procedure if you need it. I read your post to the python cvs list and did the customization for you. The pprint has no test for set and frozenset so I don't know if it works. *wink* Christian From buildbot at python.org Wed Jan 23 10:46:05 2008 From: buildbot at python.org (buildbot at python.org) Date: Wed, 23 Jan 2008 09:46:05 +0000 Subject: [Python-checkins] buildbot failure in x86 XP-4 3.0 Message-ID: <20080123094605.DD2131E400F@bag.python.org> The Buildbot has detected a new failure of x86 XP-4 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20XP-4%203.0/builds/438 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-windows Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: 11 tests failed: test_anydbm test_bsddb test_bsddb3 test_mailbox test_pep263 test_plistlib test_shelve test_urllib test_whichdb test_winreg test_zipfile ====================================================================== ERROR: test_anydbm_access (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 90, in test_anydbm_access self.init_db() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 103, in init_db f = anydbm.open(_fname, 'n') File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_anydbm_creation (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 63, in test_anydbm_creation f = anydbm.open(_fname, 'c') File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_anydbm_keys (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 84, in test_anydbm_keys self.init_db() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 103, in init_db f = anydbm.open(_fname, 'n') File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_anydbm_modification (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 71, in test_anydbm_modification self.init_db() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 103, in init_db f = anydbm.open(_fname, 'n') File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_anydbm_read (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 78, in test_anydbm_read self.init_db() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 103, in init_db f = anydbm.open(_fname, 'n') File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') Traceback (most recent call last): File "../lib/test/regrtest.py", line 596, in runtest_inner indirect_test() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb3.py", line 64, in test_main run_unittest(suite()) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb3.py", line 28, in suite import bsddb.test.test_1413192 File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\test\test_1413192.py", line 38, in context = Context() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\test\test_1413192.py", line 26, in __init__ db.DB_CREATE | db.DB_INIT_TXN | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_consistent_factory (test.test_mailbox.TestMaildir) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 520, in test_consistent_factory msg2 = box.get_message(key) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\mailbox.py", line 313, in get_message subpath = self._lookup(key) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\mailbox.py", line 482, in _lookup raise KeyError('No message with key: %s' % key) KeyError: 'No message with key: 1201081443.M84000P1840Q201.buildbot' ====================================================================== ERROR: test_flush (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 717, in tearDown self._delete_recursively(self._path) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 47, in _delete_recursively os.remove(target) WindowsError: [Error 32] The process cannot access the file because it is being used by another process: '@test' ====================================================================== ERROR: test_popitem (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 336, in test_popitem self.assertEqual(int(msg.get_payload()), keys.index(key)) ValueError: invalid literal for int() with base 10: 'From: foo 0 F' ====================================================================== ERROR: test_flush (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 717, in tearDown self._delete_recursively(self._path) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 47, in _delete_recursively os.remove(target) WindowsError: [Error 32] The process cannot access the file because it is being used by another process: '@test' ====================================================================== ERROR: test_popitem (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 336, in test_popitem self.assertEqual(int(msg.get_payload()), keys.index(key)) ValueError: invalid literal for int() with base 10: 'From: foo 0 \x01' ====================================================================== ERROR: test_flush (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 940, in tearDown self._delete_recursively(self._path) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 47, in _delete_recursively os.remove(target) WindowsError: [Error 32] The process cannot access the file because it is being used by another process: '@test' ====================================================================== ERROR: test_popitem (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 336, in test_popitem self.assertEqual(int(msg.get_payload()), keys.index(key)) ValueError: invalid literal for int() with base 10: 'From: foo *** EOOH *** From: foo 0 1,, From: foo *** EOOH *** From: foo 1 1,, From: foo *** EOOH *** From: foo 2 1,, From: foo *** EOOH *** From: foo 3 ' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestMaildir) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_add (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 77, in test_add self.assertEqual(self._box.get_string(keys[0]), self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\nF' != 'From: foo\n\n0' ====================================================================== FAIL: test_add_and_close (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 757, in test_add_and_close self.assertEqual(contents, open(self._path, 'r').read()) AssertionError: 'From MAILER-DAEMON Wed Jan 23 09:44:23 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Wed Jan 23 09:44:23 2008\n\nFrom: foo\n\n0\n\nFrom MAILER-DAEMON Wed Jan 23 09:44:23 2008\n\nFrom: foo\n\n1\n\nFrom MAILER-DAEMON Wed Jan 23 09:44:23 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Wed Jan 23 09:44:23 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'From MAILER-DAEMON Wed Jan 23 09:44:23 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Wed Jan 23 09:44:23 2008\n\nFrom: foo\n\n0\n\nFrom MAILER-DAEMON Wed Jan 23 09:44:23 2008\n\nFrom: foo\n\n1\n\nFrom MAILER-DAEMON Wed Jan 23 09:44:23 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Wed Jan 23 09:44:23 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Wed Jan 23 09:44:23 2008\n\nFrom: foo\n\n0\n\nFrom MAILER-DAEMON Wed Jan 23 09:44:23 2008\n\nFrom: foo\n\n1\n\nFrom MAILER-DAEMON Wed Jan 23 09:44:23 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Wed Jan 23 09:44:23 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Wed Jan 23 09:44:23 2008\n\nFrom: foo\n\n1\n\nFrom MAILER-DAEMON Wed Jan 23 09:44:23 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Wed Jan 23 09:44:23 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Wed Jan 23 09:44:23 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Wed Jan 23 09:44:23 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Wed Jan 23 09:44:23 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' ====================================================================== FAIL: test_add_from_string (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 724, in test_add_from_string self.assertEqual(self._box[key].get_from(), 'foo at bar blah') AssertionError: 'foo at bar blah\n' != 'foo at bar blah' ====================================================================== FAIL: test_close (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 389, in test_close self._test_flush_or_close(self._box.close) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 6 != 3 ====================================================================== FAIL: test_delitem (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 87, in test_delitem self._test_remove_or_delitem(self._box.__delitem__) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n1' != 'From: foo\n\n1' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_flush (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 377, in test_flush self._test_flush_or_close(self._box.flush) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 6 != 3 ====================================================================== FAIL: test_get (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 129, in test_get self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_file (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 174, in test_get_file self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\nF' != 'From: foo\n\n0' ====================================================================== FAIL: test_get_message (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 156, in test_get_message self.assertEqual(msg0['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_string (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 164, in test_get_string self.assertEqual(self._box.get_string(key0), self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\nF' != 'From: foo\n\n0' ====================================================================== FAIL: test_getitem (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 144, in test_getitem self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_items (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 207, in test_items self._check_iteration(self._box.items, do_keys=True, do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iter (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 194, in test_iter do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iteritems (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 203, in test_iteritems do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_itervalues (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 189, in test_itervalues do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_open_close_open (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 741, in test_open_close_open self.assertEqual(len(self._box), 3) AssertionError: 6 != 3 ====================================================================== FAIL: test_pop (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 313, in test_pop self.assertEqual(self._box.pop(key0).get_payload(), '0') AssertionError: 'From: foo\n\n0\n\nF' != '0' ====================================================================== FAIL: test_remove (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 83, in test_remove self._test_remove_or_delitem(self._box.remove) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n1' != 'From: foo\n\n1' ====================================================================== FAIL: test_set_item (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 272, in test_set_item self._template % 'original 0') AssertionError: '\nFrom: foo\n\noriginal 0' != 'From: foo\n\noriginal 0' ====================================================================== FAIL: test_update (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 350, in test_update self._template % 'changed 0') AssertionError: '\nFrom: foo\n\nchanged 0\n\nF' != 'From: foo\n\nchanged 0' ====================================================================== FAIL: test_values (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 198, in test_values self._check_iteration(self._box.values, do_keys=False, do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_add (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 77, in test_add self.assertEqual(self._box.get_string(keys[0]), self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\n\x01' != 'From: foo\n\n0' ====================================================================== FAIL: test_add_and_close (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 757, in test_add_and_close self.assertEqual(contents, open(self._path, 'r').read()) AssertionError: '\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Wed Jan 23 09:44:32 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Wed Jan 23 09:44:32 2008\n\nFrom: foo\n\n0\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Wed Jan 23 09:44:32 2008\n\nFrom: foo\n\n1\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Wed Jan 23 09:44:32 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Wed Jan 23 09:44:32 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n' != '\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Wed Jan 23 09:44:32 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Wed Jan 23 09:44:32 2008\n\nFrom: foo\n\n0\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Wed Jan 23 09:44:32 2008\n\nFrom: foo\n\n1\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Wed Jan 23 09:44:32 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Wed Jan 23 09:44:32 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Wed Jan 23 09:44:32 2008\n\nFrom: foo\n\n0\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Wed Jan 23 09:44:32 2008\n\nFrom: foo\n\n1\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Wed Jan 23 09:44:32 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Wed Jan 23 09:44:32 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Wed Jan 23 09:44:32 2008\n\nFrom: foo\n\n1\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Wed Jan 23 09:44:32 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Wed Jan 23 09:44:32 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Wed Jan 23 09:44:32 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Wed Jan 23 09:44:32 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Wed Jan 23 09:44:32 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n' ====================================================================== FAIL: test_add_from_string (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 724, in test_add_from_string self.assertEqual(self._box[key].get_from(), 'foo at bar blah') AssertionError: 'foo at bar blah\n' != 'foo at bar blah' ====================================================================== FAIL: test_close (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 389, in test_close self._test_flush_or_close(self._box.close) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_delitem (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 87, in test_delitem self._test_remove_or_delitem(self._box.__delitem__) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n1\n\n\x01' != 'From: foo\n\n1' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_flush (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 377, in test_flush self._test_flush_or_close(self._box.flush) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_get (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 129, in test_get self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_file (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 174, in test_get_file self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\n\x01' != 'From: foo\n\n0' ====================================================================== FAIL: test_get_message (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 156, in test_get_message self.assertEqual(msg0['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_string (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 164, in test_get_string self.assertEqual(self._box.get_string(key0), self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\n\x01' != 'From: foo\n\n0' ====================================================================== FAIL: test_getitem (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 144, in test_getitem self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_items (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 207, in test_items self._check_iteration(self._box.items, do_keys=True, do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iter (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 194, in test_iter do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iteritems (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 203, in test_iteritems do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_itervalues (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 189, in test_itervalues do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_open_close_open (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 741, in test_open_close_open self.assertEqual(len(self._box), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_pop (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 313, in test_pop self.assertEqual(self._box.pop(key0).get_payload(), '0') AssertionError: 'From: foo\n\n0\n\n\x01' != '0' ====================================================================== FAIL: test_remove (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 83, in test_remove self._test_remove_or_delitem(self._box.remove) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n1\n\n\x01' != 'From: foo\n\n1' ====================================================================== FAIL: test_set_item (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 272, in test_set_item self._template % 'original 0') AssertionError: '\nFrom: foo\n\noriginal 0\n\n\x01' != 'From: foo\n\noriginal 0' ====================================================================== FAIL: test_update (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 350, in test_update self._template % 'changed 0') AssertionError: '\nFrom: foo\n\nchanged 0\n\n\x01' != 'From: foo\n\nchanged 0' ====================================================================== FAIL: test_values (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 198, in test_values self._check_iteration(self._box.values, do_keys=False, do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestMH) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_add (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 77, in test_add self.assertEqual(self._box.get_string(keys[0]), self._template % 0) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n0\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f' != 'From: foo\n\n0' ====================================================================== FAIL: test_close (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 389, in test_close self._test_flush_or_close(self._box.close) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_delitem (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 87, in test_delitem self._test_remove_or_delitem(self._box.__delitem__) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n1\n\n\x1f' != 'From: foo\n\n1' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_flush (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 377, in test_flush self._test_flush_or_close(self._box.flush) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_get (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 129, in test_get self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_file (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 174, in test_get_file self._template % 0) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n0\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f' != 'From: foo\n\n0' ====================================================================== FAIL: test_get_message (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 156, in test_get_message self.assertEqual(msg0['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_string (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 164, in test_get_string self.assertEqual(self._box.get_string(key0), self._template % 0) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n0\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f' != 'From: foo\n\n0' ====================================================================== FAIL: test_getitem (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 144, in test_getitem self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_items (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 207, in test_items self._check_iteration(self._box.items, do_keys=True, do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iter (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 194, in test_iter do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iteritems (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 203, in test_iteritems do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_itervalues (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 189, in test_itervalues do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_pop (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 313, in test_pop self.assertEqual(self._box.pop(key0).get_payload(), '0') AssertionError: 'From: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n0\n\n\x1f\x0c\n\n1,,\n\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n1\n\n\x1f' != '0' ====================================================================== FAIL: test_remove (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 83, in test_remove self._test_remove_or_delitem(self._box.remove) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n1\n\n\x1f' != 'From: foo\n\n1' ====================================================================== FAIL: test_set_item (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 272, in test_set_item self._template % 'original 0') AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\noriginal 0\n\n\x1f' != 'From: foo\n\noriginal 0' ====================================================================== FAIL: test_update (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 350, in test_update self._template % 'changed 0') AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\nchanged 0\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f' != 'From: foo\n\nchanged 0' ====================================================================== FAIL: test_values (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 198, in test_values self._check_iteration(self._box.values, do_keys=False, do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_compilestring (test.test_pep263.PEP263Test) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_pep263.py", line 25, in test_compilestring AssertionError: '\xc3\xb3' != '\xf3' ====================================================================== ERROR: test_appleformatting (test.test_plistlib.TestPlistlib) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_plistlib.py", line 140, in test_appleformatting pl = plistlib.readPlistFromBytes(TESTDATA) AttributeError: 'module' object has no attribute 'readPlistFromBytes' ====================================================================== ERROR: test_appleformattingfromliteral (test.test_plistlib.TestPlistlib) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_plistlib.py", line 147, in test_appleformattingfromliteral pl2 = plistlib.readPlistFromBytes(TESTDATA) AttributeError: 'module' object has no attribute 'readPlistFromBytes' ====================================================================== ERROR: test_bytes (test.test_plistlib.TestPlistlib) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_plistlib.py", line 133, in test_bytes data = plistlib.writePlistToBytes(pl) AttributeError: 'module' object has no attribute 'writePlistToBytes' ====================================================================== ERROR: test_bytesio (test.test_plistlib.TestPlistlib) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_plistlib.py", line 155, in test_bytesio plistlib.writePlist(pl, b) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\plistlib.py", line 91, in writePlist writer = PlistWriter(pathOrFile) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\plistlib.py", line 230, in __init__ file.write(PLISTHEADER) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\io.py", line 701, in write raise TypeError("can't write str to binary stream") TypeError: can't write str to binary stream ====================================================================== ERROR: test_controlcharacters (test.test_plistlib.TestPlistlib) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_plistlib.py", line 168, in test_controlcharacters plistlib.writePlistToBytes, AttributeError: 'module' object has no attribute 'writePlistToBytes' ====================================================================== ERROR: test_io (test.test_plistlib.TestPlistlib) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_plistlib.py", line 127, in test_io plistlib.writePlist(pl, test_support.TESTFN) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\plistlib.py", line 93, in writePlist writer.writeValue(rootObject) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\plistlib.py", line 248, in writeValue self.writeDict(value) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\plistlib.py", line 277, in writeDict self.writeValue(value) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\plistlib.py", line 254, in writeValue self.writeArray(value) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\plistlib.py", line 283, in writeArray self.writeValue(value) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\plistlib.py", line 250, in writeValue self.writeData(value) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\plistlib.py", line 263, in writeData for line in data.asBase64(maxlinelength).split("\n"): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\plistlib.py", line 375, in asBase64 return _encodeBase64(self.data, maxlinelength) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\plistlib.py", line 359, in _encodeBase64 return "".join(pieces) TypeError: sequence item 0: expected str instance, bytes found ====================================================================== ERROR: test_nondictroot (test.test_plistlib.TestPlistlib) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_plistlib.py", line 174, in test_nondictroot result1 = plistlib.readPlistFromBytes(plistlib.writePlistToBytes(test1)) AttributeError: 'module' object has no attribute 'readPlistFromBytes' ====================================================================== ERROR: test_bool (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 136, in test_bool self.assert_(not self._empty_mapping()) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_constructor (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 133, in test_constructor self.assertEqual(self._empty_mapping(), self._empty_mapping()) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 270, in test_get d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_items (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 156, in test_items d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keys (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 142, in test_keys d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 162, in test_len d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 293, in test_pop d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 288, in test_popitem d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_read (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 44, in test_read p = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 284, in test_setdefault d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 174, in test_update d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_values (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 150, in test_values d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_write (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 92, in test_write p = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_bool (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 136, in test_bool self.assert_(not self._empty_mapping()) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_constructor (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 133, in test_constructor self.assertEqual(self._empty_mapping(), self._empty_mapping()) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 270, in test_get d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_items (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 156, in test_items d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keys (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 142, in test_keys d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 162, in test_len d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 293, in test_pop d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 288, in test_popitem d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_read (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 44, in test_read p = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 284, in test_setdefault d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 174, in test_update d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_values (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 150, in test_values d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_write (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 92, in test_write p = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_bool (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 136, in test_bool self.assert_(not self._empty_mapping()) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_constructor (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 133, in test_constructor self.assertEqual(self._empty_mapping(), self._empty_mapping()) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 270, in test_get d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_items (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 156, in test_items d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keys (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 142, in test_keys d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 162, in test_len d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 293, in test_pop d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 288, in test_popitem d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_read (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 44, in test_read p = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 284, in test_setdefault d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 174, in test_update d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_values (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 150, in test_values d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_write (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 92, in test_write p = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_ascii_file_shelf (test.test_shelve.TestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 46, in test_ascii_file_shelf s = shelve.open(self.fn, protocol=0) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_binary_file_shelf (test.test_shelve.TestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 54, in test_binary_file_shelf s = shelve.open(self.fn, protocol=1) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_proto2_file_shelf (test.test_shelve.TestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 62, in test_proto2_file_shelf s = shelve.open(self.fn, protocol=2) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== FAIL: test_read (test.test_urllib.urlopen_HttpTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_urllib.py", line 130, in test_read self.assertEqual(fp.getcode(), 200) AssertionError: None != 200 ====================================================================== ERROR: test_whichdb (test.test_whichdb.WhichDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_whichdb.py", line 32, in test_whichdb f = module.open(_fname, 'c') File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== FAIL: testLocalMachineRegistryWorks (test.test_winreg.WinregTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_winreg.py", line 144, in testLocalMachineRegistryWorks self.TestAll(HKEY_CURRENT_USER) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_winreg.py", line 139, in TestAll self.WriteTestData(root_key, subkeystr) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_winreg.py", line 41, in WriteTestData self.assertEquals(nkeys, 1, "Not the correct number of sub keys") AssertionError: Not the correct number of sub keys ====================================================================== ERROR: testExtract (test.test_zipfile.TestsWithSourceFile) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_zipfile.py", line 350, in tearDown os.remove(TESTFN2) WindowsError: [Error 32] The process cannot access the file because it is being used by another process: '@test2' ====================================================================== FAIL: testExtract (test.test_zipfile.TestsWithSourceFile) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_zipfile.py", line 313, in testExtract self.assertEqual(writtenfile, correctfile) AssertionError: 'E:\\cygwin\\home\\db3l\\buildarea\\3.0.bolen-windows\\build\\PCbuild\\ziptest2dir\\_ziptest2' != 'E:\\cygwin\\home\\db3l\\buildarea\\3.0.bolen-windows\\build\\PCbuild\\ziptest2dir/_ziptest2' sincerely, -The Buildbot From python-checkins at python.org Wed Jan 23 14:35:41 2008 From: python-checkins at python.org (christian.heimes) Date: Wed, 23 Jan 2008 14:35:41 +0100 (CET) Subject: [Python-checkins] r60211 - in python/branches/trunk-math: Doc/c-api/module.rst Doc/library/functions.rst Doc/library/itertools.rst Doc/library/pprint.rst Include/modsupport.h Lib/ftplib.py Lib/pprint.py Lib/test/test_grp.py Lib/test/test_mmap.py Lib/test/test_pwd.py Misc/NEWS Modules/mmapmodule.c Message-ID: <20080123133541.4AE0F1E400F@bag.python.org> Author: christian.heimes Date: Wed Jan 23 14:35:40 2008 New Revision: 60211 Modified: python/branches/trunk-math/ (props changed) python/branches/trunk-math/Doc/c-api/module.rst python/branches/trunk-math/Doc/library/functions.rst python/branches/trunk-math/Doc/library/itertools.rst python/branches/trunk-math/Doc/library/pprint.rst python/branches/trunk-math/Include/modsupport.h python/branches/trunk-math/Lib/ftplib.py python/branches/trunk-math/Lib/pprint.py python/branches/trunk-math/Lib/test/test_grp.py python/branches/trunk-math/Lib/test/test_mmap.py python/branches/trunk-math/Lib/test/test_pwd.py python/branches/trunk-math/Misc/NEWS python/branches/trunk-math/Modules/mmapmodule.c Log: Merged revisions 60195-60210 via svnmerge from svn+ssh://pythondev at svn.python.org/python/trunk ........ r60198 | christian.heimes | 2008-01-22 16:01:25 +0100 (Tue, 22 Jan 2008) | 1 line Fixed a missing (X) in define ........ r60199 | christian.heimes | 2008-01-22 16:25:18 +0100 (Tue, 22 Jan 2008) | 2 lines Don't repeat yourself Added the macros PyModule_AddIntMacro and PyModule_AddStringMacro. They shorten PyModule_AddIntConstant(m, "AF_INET", AF_INET) to PyModule_AddIntMacro(m, AF_INET) ........ r60201 | raymond.hettinger | 2008-01-22 20:51:41 +0100 (Tue, 22 Jan 2008) | 1 line Document when to use izip_longest(). ........ r60202 | georg.brandl | 2008-01-22 20:56:03 +0100 (Tue, 22 Jan 2008) | 2 lines Fix for #1087741 patch. ........ r60203 | raymond.hettinger | 2008-01-22 21:18:53 +0100 (Tue, 22 Jan 2008) | 1 line Give zip() the same guarantee as izip() for left-to-right evaluation. ........ r60204 | raymond.hettinger | 2008-01-22 23:09:26 +0100 (Tue, 22 Jan 2008) | 1 line Improve variable name in sample code ........ r60205 | gregory.p.smith | 2008-01-23 00:15:34 +0100 (Wed, 23 Jan 2008) | 2 lines docstring and comment updates suggested by Giampaolo Rodola' ........ r60207 | raymond.hettinger | 2008-01-23 01:04:40 +0100 (Wed, 23 Jan 2008) | 1 line Let pprint() support sets and frozensets (suggested by David Mertz). ........ r60208 | guido.van.rossum | 2008-01-23 02:18:27 +0100 (Wed, 23 Jan 2008) | 4 lines I'm tired of these tests breaking at Google due to our large number of users and groups in LDAP/NIS. So I'm limiting the extra-heavy part of the tests to passwd/group files with at most 1000 entries. ........ Modified: python/branches/trunk-math/Doc/c-api/module.rst ============================================================================== --- python/branches/trunk-math/Doc/c-api/module.rst (original) +++ python/branches/trunk-math/Doc/c-api/module.rst Wed Jan 23 14:35:40 2008 @@ -18,7 +18,7 @@ is exposed to Python programs as ``types.ModuleType``. -.. cfunction:: int PyModule_Check(PyObject *p) +.. cmacro:: int PyModule_Check(PyObject *p) Return true if *p* is a module object, or a subtype of a module object. @@ -26,7 +26,7 @@ Allowed subtypes to be accepted. -.. cfunction:: int PyModule_CheckExact(PyObject *p) +.. cmacro:: int PyModule_CheckExact(PyObject *p) Return true if *p* is a module object, but not a subtype of :cdata:`PyModule_Type`. @@ -103,3 +103,19 @@ null-terminated. Return ``-1`` on error, ``0`` on success. .. versionadded:: 2.0 + +.. cmacro:: int PyModule_AddIntMacro(PyObject *module, macro) + + Add an int constant to *module*. The name and the value are taken from + *macro*. For example ``PyModule_AddConstant(module, AF_INET)`` adds the int + constant *AF_INET* with the value of *AF_INET* to *module*. + Return ``-1`` on error, ``0`` on success. + + .. versionadded:: 2.6 + +.. cmacro:: int PyModule_AddStringMacro(PyObject *module, macro) + + Add a string constant to *module*. + + .. versionadded:: 2.6 + Modified: python/branches/trunk-math/Doc/library/functions.rst ============================================================================== --- python/branches/trunk-math/Doc/library/functions.rst (original) +++ python/branches/trunk-math/Doc/library/functions.rst Wed Jan 23 14:35:40 2008 @@ -1285,6 +1285,10 @@ sequence argument, it returns a list of 1-tuples. With no arguments, it returns an empty list. + The left-to-right evaluation order of the iterables is guaranteed. This + makes possible an idiom for clustering a data series into n-length groups + using ``zip(*[iter(s)]*n)``. + .. versionadded:: 2.0 .. versionchanged:: 2.4 Modified: python/branches/trunk-math/Doc/library/itertools.rst ============================================================================== --- python/branches/trunk-math/Doc/library/itertools.rst (original) +++ python/branches/trunk-math/Doc/library/itertools.rst Wed Jan 23 14:35:40 2008 @@ -218,7 +218,7 @@ def imap(function, *iterables): iterables = map(iter, iterables) while True: - args = [i.next() for i in iterables] + args = [it.next() for it in iterables] if function is None: yield tuple(args) else: @@ -269,22 +269,13 @@ When no iterables are specified, returns a zero length iterator instead of raising a :exc:`TypeError` exception. - Note, the left-to-right evaluation order of the iterables is guaranteed. This - makes possible an idiom for clustering a data series into n-length groups using - ``izip(*[iter(s)]*n)``. For data that doesn't fit n-length groups exactly, the - last tuple can be pre-padded with fill values using ``izip(*[chain(s, - [None]*(n-1))]*n)``. - - Note, when :func:`izip` is used with unequal length inputs, subsequent - iteration over the longer iterables cannot reliably be continued after - :func:`izip` terminates. Potentially, up to one entry will be missing from - each of the left-over iterables. This occurs because a value is fetched from - each iterator in turn, but the process ends when one of the iterators - terminates. This leaves the last fetched values in limbo (they cannot be - returned in a final, incomplete tuple and they are cannot be pushed back into - the iterator for retrieval with ``it.next()``). In general, :func:`izip` - should only be used with unequal length inputs when you don't care about - trailing, unmatched values from the longer iterables. + The left-to-right evaluation order of the iterables is guaranteed. This + makes possible an idiom for clustering a data series into n-length groups + using ``izip(*[iter(s)]*n)``. + + :func:`izip` should only be used with unequal length inputs when you don't + care about trailing, unmatched values from the longer iterables. If those + values are important, use :func:`izip_longest` instead. .. function:: izip_longest(*iterables[, fillvalue]) Modified: python/branches/trunk-math/Doc/library/pprint.rst ============================================================================== --- python/branches/trunk-math/Doc/library/pprint.rst (original) +++ python/branches/trunk-math/Doc/library/pprint.rst Wed Jan 23 14:35:40 2008 @@ -25,6 +25,9 @@ dictionary was sorted only if its display required more than one line, although that wasn't documented. +.. versionchanged:: 2.6 + Added support for :class:`set` and :class:`frozenset`. + The :mod:`pprint` module defines one class: .. First the implementation class: Modified: python/branches/trunk-math/Include/modsupport.h ============================================================================== --- python/branches/trunk-math/Include/modsupport.h (original) +++ python/branches/trunk-math/Include/modsupport.h Wed Jan 23 14:35:40 2008 @@ -40,7 +40,8 @@ PyAPI_FUNC(int) PyModule_AddObject(PyObject *, const char *, PyObject *); PyAPI_FUNC(int) PyModule_AddIntConstant(PyObject *, const char *, long); PyAPI_FUNC(int) PyModule_AddStringConstant(PyObject *, const char *, const char *); - +#define PyModule_AddIntMacro(m, c) PyModule_AddIntConstant(m, #c, c) +#define PyModule_AddStringMacro(m, c) PyModule_AddStringConstant(m, #c, c) #define PYTHON_API_VERSION 1013 #define PYTHON_API_STRING "1013" Modified: python/branches/trunk-math/Lib/ftplib.py ============================================================================== --- python/branches/trunk-math/Lib/ftplib.py (original) +++ python/branches/trunk-math/Lib/ftplib.py Wed Jan 23 14:35:40 2008 @@ -313,7 +313,7 @@ expected size may be None if it could not be determined. Optional `rest' argument can be a string that is sent as the - argument to a RESTART command. This is essentially a server + argument to a REST command. This is essentially a server marker used to tell the server to skip over any data up to the given marker. """ @@ -403,7 +403,7 @@ """Retrieve data in line mode. A new port is created for you. Args: - cmd: A RETR or LIST command. + cmd: A RETR, LIST, NLST, or MLSD command. callback: An optional single parameter callable that is called for each line with the trailing CRLF stripped. [default: print_line()] @@ -539,7 +539,7 @@ def size(self, filename): '''Retrieve the size of a file.''' - # Note that the RFC doesn't say anything about 'SIZE' + # The SIZE command is defined in RFC-3659 resp = self.sendcmd('SIZE ' + filename) if resp[:3] == '213': s = resp[3:].strip() Modified: python/branches/trunk-math/Lib/pprint.py ============================================================================== --- python/branches/trunk-math/Lib/pprint.py (original) +++ python/branches/trunk-math/Lib/pprint.py Wed Jan 23 14:35:40 2008 @@ -162,11 +162,24 @@ write('}') return - if (issubclass(typ, list) and r is list.__repr__) or \ - (issubclass(typ, tuple) and r is tuple.__repr__): + if ((issubclass(typ, list) and r is list.__repr__) or + (issubclass(typ, tuple) and r is tuple.__repr__) or + (issubclass(typ, set) and r is set.__repr__) or + (issubclass(typ, frozenset) and r is frozenset.__repr__) + ): if issubclass(typ, list): write('[') endchar = ']' + elif issubclass(typ, set): + write('set([') + endchar = '])' + object = sorted(object) + indent += 4 + elif issubclass(typ, frozenset): + write('frozenset([') + endchar = '])' + object = sorted(object) + indent += 9 else: write('(') endchar = ')' Modified: python/branches/trunk-math/Lib/test/test_grp.py ============================================================================== --- python/branches/trunk-math/Lib/test/test_grp.py (original) +++ python/branches/trunk-math/Lib/test/test_grp.py Wed Jan 23 14:35:40 2008 @@ -25,6 +25,9 @@ for e in entries: self.check_value(e) + if len(entries) > 1000: # Huge group file (NIS?) -- skip the rest + return + for e in entries: e2 = grp.getgrgid(e.gr_gid) self.check_value(e2) Modified: python/branches/trunk-math/Lib/test/test_mmap.py ============================================================================== --- python/branches/trunk-math/Lib/test/test_mmap.py (original) +++ python/branches/trunk-math/Lib/test/test_mmap.py Wed Jan 23 14:35:40 2008 @@ -420,6 +420,13 @@ except OSError: pass + def test_subclass(self): + class anon_mmap(mmap.mmap): + def __new__(klass, *args, **kwargs): + return mmap.mmap.__new__(klass, -1, *args, **kwargs) + anon_mmap(PAGESIZE) + + def test_main(): run_unittest(MmapTests) Modified: python/branches/trunk-math/Lib/test/test_pwd.py ============================================================================== --- python/branches/trunk-math/Lib/test/test_pwd.py (original) +++ python/branches/trunk-math/Lib/test/test_pwd.py Wed Jan 23 14:35:40 2008 @@ -35,6 +35,9 @@ entriesbyname.setdefault(e.pw_name, []).append(e) entriesbyuid.setdefault(e.pw_uid, []).append(e) + if len(entries) > 1000: # Huge passwd file (NIS?) -- skip the rest + return + # check whether the entry returned by getpwuid() # for each uid is among those from getpwall() for this uid for e in entries: Modified: python/branches/trunk-math/Misc/NEWS ============================================================================== --- python/branches/trunk-math/Misc/NEWS (original) +++ python/branches/trunk-math/Misc/NEWS Wed Jan 23 14:35:40 2008 @@ -383,6 +383,8 @@ Library ------- +- The pprint module now supports sets and frozensets. + - #1221598: add optional callbacks to ftplib.FTP's storbinary() and storlines() methods. (Contributed by Phil Schwartz) Modified: python/branches/trunk-math/Modules/mmapmodule.c ============================================================================== --- python/branches/trunk-math/Modules/mmapmodule.c (original) +++ python/branches/trunk-math/Modules/mmapmodule.c Wed Jan 23 14:35:40 2008 @@ -129,7 +129,7 @@ } #endif /* UNIX */ - PyObject_Del(m_obj); + m_obj->ob_type->tp_free((PyObject*)m_obj); } static PyObject * From python-checkins at python.org Wed Jan 23 14:57:34 2008 From: python-checkins at python.org (christian.heimes) Date: Wed, 23 Jan 2008 14:57:34 +0100 (CET) Subject: [Python-checkins] r60212 - python/branches/trunk-math/Lib/test/test_math.py Message-ID: <20080123135734.738DE1E400F@bag.python.org> Author: christian.heimes Date: Wed Jan 23 14:57:34 2008 New Revision: 60212 Modified: python/branches/trunk-math/Lib/test/test_math.py Log: Allow nan or ValueError Modified: python/branches/trunk-math/Lib/test/test_math.py ============================================================================== --- python/branches/trunk-math/Lib/test/test_math.py (original) +++ python/branches/trunk-math/Lib/test/test_math.py Wed Jan 23 14:57:34 2008 @@ -156,8 +156,12 @@ self.ftest('cos(0)', math.cos(0), 1) self.ftest('cos(pi/2)', math.cos(math.pi/2), 0) self.ftest('cos(pi)', math.cos(math.pi), -1) - self.assertRaises(ValueError, math.cos, INF) - self.assertRaises(ValueError, math.cos, NINF) + try: + self.assert_(math.isnan(math.cos(INF))) + self.assert_(math.isnan(math.cos(NINF))) + except ValueError: + self.assertRaises(ValueError, math.cos, INF) + self.assertRaises(ValueError, math.cos, NINF) self.assert_(math.isnan(math.cos(NAN))) def testCosh(self): @@ -275,7 +279,10 @@ self.ftest('log1p(e-1)', math.log1p(math.e-1), 1) self.ftest('log1p(1)', math.log1p(1), math.log(2)) self.assertRaises(OverflowError, math.log1p, INF) - self.assertRaises(ValueError, math.log1p, NINF) + try: + self.assert_(math.isnan(math.log1p(NINF))) + except ValueError: + self.assertRaises(ValueError, math.log1p, NINF) self.assert_(math.isnan(math.log1p(NAN))) def testLog10(self): @@ -305,9 +312,13 @@ self.ftest('pow(2,1)', math.pow(2,1), 2) self.ftest('pow(2,-1)', math.pow(2,-1), 0.5) self.assertRaises(OverflowError, math.pow, INF, 1) - self.assertRaises(ValueError, math.pow, 1, INF) self.assertRaises(OverflowError, math.pow, NINF, 1) - self.assertRaises(ValueError, math.pow, 1, NINF) + try: + self.assertEqual((math.pow(1, INF)), 1.) + self.assertEqual((math.pow(1, NINF)), 1.) + except ValueError: + self.assertRaises(ValueError, math.pow, 1, INF) + self.assertRaises(ValueError, math.pow, 1, NINF) self.assert_(math.isnan(math.pow(NAN, 1))) self.assert_(math.isnan(math.pow(1, NAN))) @@ -322,8 +333,12 @@ self.ftest('sin(0)', math.sin(0), 0) self.ftest('sin(pi/2)', math.sin(math.pi/2), 1) self.ftest('sin(-pi/2)', math.sin(-math.pi/2), -1) - self.assertRaises(ValueError, math.sin, INF) - self.assertRaises(ValueError, math.sin, NINF) + try: + self.assert_(math.isnan(math.sin(INF))) + self.assert_(math.isnan(math.sin(NINF))) + except ValueError: + self.assertRaises(ValueError, math.sin, INF) + self.assertRaises(ValueError, math.sin, NINF) self.assert_(math.isnan(math.sin(NAN))) def testSinh(self): @@ -349,8 +364,12 @@ self.ftest('tan(0)', math.tan(0), 0) self.ftest('tan(pi/4)', math.tan(math.pi/4), 1) self.ftest('tan(-pi/4)', math.tan(-math.pi/4), -1) - self.assertRaises(ValueError, math.tan, INF) - self.assertRaises(ValueError, math.tan, NINF) + try: + self.assert_(math.isnan(math.tan(INF))) + self.assert_(math.isnan(math.tan(NINF))) + except: + self.assertRaises(ValueError, math.tan, INF) + self.assertRaises(ValueError, math.tan, NINF) self.assert_(math.isnan(math.tan(NAN))) def testTanh(self): From python-checkins at python.org Wed Jan 23 15:00:25 2008 From: python-checkins at python.org (christian.heimes) Date: Wed, 23 Jan 2008 15:00:25 +0100 (CET) Subject: [Python-checkins] r60213 - python/trunk/Modules/mmapmodule.c Message-ID: <20080123140025.D13191E402C@bag.python.org> Author: christian.heimes Date: Wed Jan 23 15:00:25 2008 New Revision: 60213 Modified: python/trunk/Modules/mmapmodule.c Log: Use Py_TYPE() instead of ->ob_type Modified: python/trunk/Modules/mmapmodule.c ============================================================================== --- python/trunk/Modules/mmapmodule.c (original) +++ python/trunk/Modules/mmapmodule.c Wed Jan 23 15:00:25 2008 @@ -129,7 +129,7 @@ } #endif /* UNIX */ - m_obj->ob_type->tp_free((PyObject*)m_obj); + Py_TYPE(m_obj)->tp_free((PyObject*)m_obj); } static PyObject * From python-checkins at python.org Wed Jan 23 15:07:13 2008 From: python-checkins at python.org (armin.rigo) Date: Wed, 23 Jan 2008 15:07:13 +0100 (CET) Subject: [Python-checkins] r60214 - python/trunk/Modules/socketmodule.c Message-ID: <20080123140713.B10B51E4038@bag.python.org> Author: armin.rigo Date: Wed Jan 23 15:07:13 2008 New Revision: 60214 Modified: python/trunk/Modules/socketmodule.c Log: patch 1754489 by vlahan: improve portability of address length calculation for AF_UNIX sockets Modified: python/trunk/Modules/socketmodule.c ============================================================================== --- python/trunk/Modules/socketmodule.c (original) +++ python/trunk/Modules/socketmodule.c Wed Jan 23 15:07:13 2008 @@ -1001,7 +1001,7 @@ struct sockaddr_un *a = (struct sockaddr_un *) addr; #ifdef linux if (a->sun_path[0] == 0) { /* Linux abstract namespace */ - addrlen -= (sizeof(*a) - sizeof(a->sun_path)); + addrlen -= offsetof(struct sockaddr_un, sun_path); return PyString_FromStringAndSize(a->sun_path, addrlen); } @@ -1207,7 +1207,7 @@ #if defined(PYOS_OS2) *len_ret = sizeof(*addr); #else - *len_ret = len + sizeof(*addr) - sizeof(addr->sun_path); + *len_ret = len + offsetof(struct sockaddr_un, sun_path); #endif return 1; } From python-checkins at python.org Wed Jan 23 15:20:41 2008 From: python-checkins at python.org (christian.heimes) Date: Wed, 23 Jan 2008 15:20:41 +0100 (CET) Subject: [Python-checkins] r60215 - in python/branches/release25-maint: Lib/encodings/__init__.py Lib/optparse.py Misc/NEWS Parser/tokenizer.c Message-ID: <20080123142041.CD93C1E4043@bag.python.org> Author: christian.heimes Date: Wed Jan 23 15:20:41 2008 New Revision: 60215 Modified: python/branches/release25-maint/Lib/encodings/__init__.py python/branches/release25-maint/Lib/optparse.py python/branches/release25-maint/Misc/NEWS python/branches/release25-maint/Parser/tokenizer.c Log: Fixed bug #1915: Python compiles with --enable-unicode=no again. However several extension methods and modules do not work without unicode support. Modified: python/branches/release25-maint/Lib/encodings/__init__.py ============================================================================== --- python/branches/release25-maint/Lib/encodings/__init__.py (original) +++ python/branches/release25-maint/Lib/encodings/__init__.py Wed Jan 23 15:20:41 2008 @@ -60,7 +60,7 @@ """ # Make sure we have an 8-bit string, because .translate() works # differently for Unicode strings. - if type(encoding) is types.UnicodeType: + if hasattr(types, "UnicodeType") and type(encoding) is types.UnicodeType: # Note that .encode('latin-1') does *not* use the codec # registry, so this call doesn't recurse. (See unicodeobject.c # PyUnicode_AsEncodedString() for details) Modified: python/branches/release25-maint/Lib/optparse.py ============================================================================== --- python/branches/release25-maint/Lib/optparse.py (original) +++ python/branches/release25-maint/Lib/optparse.py Wed Jan 23 15:20:41 2008 @@ -824,7 +824,11 @@ (True, False) = (1, 0) def isbasestring(x): - return isinstance(x, types.StringType) or isinstance(x, types.UnicodeType) + try: + return isinstance(x, basestring) + except: + return isinstance(x, types.StringType) or isinstance(x, types.UnicodeType) + class Values: Modified: python/branches/release25-maint/Misc/NEWS ============================================================================== --- python/branches/release25-maint/Misc/NEWS (original) +++ python/branches/release25-maint/Misc/NEWS Wed Jan 23 15:20:41 2008 @@ -12,6 +12,10 @@ Core and builtins ----------------- +- Bug #1915: Python compiles with --enable-unicode=no again. However + several extension methods and modules do not work without unicode + support. + - Issue #1678380: distinction between 0.0 and -0.0 was lost during constant folding optimization. This was a regression from Python 2.4. Modified: python/branches/release25-maint/Parser/tokenizer.c ============================================================================== --- python/branches/release25-maint/Parser/tokenizer.c (original) +++ python/branches/release25-maint/Parser/tokenizer.c Wed Jan 23 15:20:41 2008 @@ -1537,7 +1537,7 @@ there, as it must be empty for PGEN, and we can check for PGEN only in this file. */ -#ifdef PGEN +#if defined(PGEN) || !defined(Py_USING_UNICODE) char* PyTokenizer_RestoreEncoding(struct tok_state* tok, int len, int* offset) { @@ -1557,7 +1557,6 @@ } return ret; } - char * PyTokenizer_RestoreEncoding(struct tok_state* tok, int len, int *offset) { From python-checkins at python.org Wed Jan 23 15:20:51 2008 From: python-checkins at python.org (christian.heimes) Date: Wed, 23 Jan 2008 15:20:51 +0100 (CET) Subject: [Python-checkins] r60216 - in python/trunk: Lib/encodings/__init__.py Lib/optparse.py Misc/NEWS Parser/tokenizer.c Message-ID: <20080123142051.495541E4039@bag.python.org> Author: christian.heimes Date: Wed Jan 23 15:20:50 2008 New Revision: 60216 Modified: python/trunk/Lib/encodings/__init__.py python/trunk/Lib/optparse.py python/trunk/Misc/NEWS python/trunk/Parser/tokenizer.c Log: Fixed bug #1915: Python compiles with --enable-unicode=no again. However several extension methods and modules do not work without unicode support. Modified: python/trunk/Lib/encodings/__init__.py ============================================================================== --- python/trunk/Lib/encodings/__init__.py (original) +++ python/trunk/Lib/encodings/__init__.py Wed Jan 23 15:20:50 2008 @@ -30,6 +30,7 @@ import codecs from encodings import aliases +import __builtin__ _cache = {} _unknown = '--unknown--' @@ -60,7 +61,7 @@ """ # Make sure we have an 8-bit string, because .translate() works # differently for Unicode strings. - if isinstance(encoding, unicode): + if hasattr(__builtin__, "unicode") and isinstance(encoding, unicode): # Note that .encode('latin-1') does *not* use the codec # registry, so this call doesn't recurse. (See unicodeobject.c # PyUnicode_AsEncodedString() for details) Modified: python/trunk/Lib/optparse.py ============================================================================== --- python/trunk/Lib/optparse.py (original) +++ python/trunk/Lib/optparse.py Wed Jan 23 15:20:50 2008 @@ -824,7 +824,11 @@ (True, False) = (1, 0) def isbasestring(x): - return isinstance(x, types.StringType) or isinstance(x, types.UnicodeType) + try: + return isinstance(x, basestring) + except: + return isinstance(x, types.StringType) or isinstance(x, types.UnicodeType) + class Values: Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Wed Jan 23 15:20:50 2008 @@ -12,6 +12,10 @@ Core and builtins ----------------- +- Bug #1915: Python compiles with --enable-unicode=no again. However + several extension methods and modules do not work without unicode + support. + - Patch #1720595: add T_BOOL to the range of structmember types. - Issue #1882: when compiling code from a string, encoding cookies in the Modified: python/trunk/Parser/tokenizer.c ============================================================================== --- python/trunk/Parser/tokenizer.c (original) +++ python/trunk/Parser/tokenizer.c Wed Jan 23 15:20:50 2008 @@ -1563,7 +1563,7 @@ there, as it must be empty for PGEN, and we can check for PGEN only in this file. */ -#ifdef PGEN +#if defined(PGEN) || !defined(Py_USING_UNICODE) char* PyTokenizer_RestoreEncoding(struct tok_state* tok, int len, int* offset) { @@ -1584,7 +1584,6 @@ } return ret; } - char * PyTokenizer_RestoreEncoding(struct tok_state* tok, int len, int *offset) { From buildbot at python.org Wed Jan 23 16:09:21 2008 From: buildbot at python.org (buildbot at python.org) Date: Wed, 23 Jan 2008 15:09:21 +0000 Subject: [Python-checkins] buildbot failure in x86 gentoo 2.5 Message-ID: <20080123150921.ECEA51E400F@bag.python.org> The Buildbot has detected a new failure of x86 gentoo 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20gentoo%202.5/builds/517 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-x86 Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/home/buildslave/python-trunk/2.5.norwitz-x86/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildslave/python-trunk/2.5.norwitz-x86/build/Lib/test/test_asynchat.py", line 17, in run PORT = test_support.bind_port(sock, HOST, PORT) File "/home/buildslave/python-trunk/2.5.norwitz-x86/build/Lib/test/test_support.py", line 108, in bind_port raise TestFailed, 'unable to find port to listen on' TestFailed: unable to find port to listen on sincerely, -The Buildbot From nnorwitz at gmail.com Wed Jan 23 16:38:59 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Wed, 23 Jan 2008 10:38:59 -0500 Subject: [Python-checkins] Python Regression Test Failures basics (1) Message-ID: <20080123153859.GA7786@python.psfb.org> test_grammar test_opcodes test_dict test_builtin test_exceptions test_types test_unittest test_doctest test_doctest2 test_MimeWriter test_StringIO test___all__ test___future__ test__locale test_abc test_abstract_numbers test_aepack test_aepack skipped -- No module named aepack test_al test_al skipped -- No module named al test_anydbm test_applesingle test_applesingle skipped -- No module named macostools test_array test_ast test_asynchat test test_asynchat failed -- Traceback (most recent call last): File "/tmp/python-test/local/lib/python2.6/test/test_asynchat.py", line 118, in test_line_terminator3 self.line_terminator_check('qqq', l) File "/tmp/python-test/local/lib/python2.6/test/test_asynchat.py", line 99, in line_terminator_check self.assertEqual(c.contents, ["hello world", "I'm not dead yet!"]) AssertionError: [] != ['hello world', "I'm not dead yet!"] test_asyncore test_atexit test_audioop test_augassign test_base64 test_bastion test_bigaddrspace test_bigmem test_binascii test_binhex test_binop test_bisect test_bool test_bsddb test_bsddb185 test_bsddb185 skipped -- No module named bsddb185 test_bsddb3 test_bsddb3 skipped -- Use of the `bsddb' resource not enabled test_buffer test_bufio test_bz2 test_cProfile test_calendar test_call test_capi test_cd test_cd skipped -- No module named cd test_cfgparser test_cgi test_charmapcodec test_cl test_cl skipped -- No module named cl test_class test_cmath test_cmd test_cmd_line test_cmd_line_script test_code test_codeccallbacks test_codecencodings_cn test_codecencodings_hk test_codecencodings_jp test_codecencodings_kr test_codecencodings_tw test_codecmaps_cn test_codecmaps_cn skipped -- Use of the `urlfetch' resource not enabled test_codecmaps_hk test_codecmaps_hk skipped -- Use of the `urlfetch' resource not enabled test_codecmaps_jp test_codecmaps_jp skipped -- Use of the `urlfetch' resource not enabled test_codecmaps_kr test_codecmaps_kr skipped -- Use of the `urlfetch' resource not enabled test_codecmaps_tw test_codecmaps_tw skipped -- Use of the `urlfetch' resource not enabled test_codecs test_codeop test_coding test_coercion test_collections test_colorsys test_commands test_compare test_compile test_compiler test_complex test_complex_args test_contains test_contextlib test_cookie test_cookielib test_copy test_copy_reg test_cpickle test_crypt test_csv test_ctypes test_curses test_curses skipped -- Use of the `curses' resource not enabled test_datetime test_dbm test_decimal test_decorators test_defaultdict test_deque test_descr test_descrtut test_difflib test_dircache test_dis test_distutils test_dl test_docxmlrpc test_dumbdbm test_dummy_thread test_dummy_threading test_email test_email_codecs test_email_renamed test_enumerate test_eof test_errno test_exception_variations test_extcall test_fcntl test_file test_filecmp test_fileinput test_float test_fnmatch test_fork1 test_format test_fpformat test_frozen test_ftplib test test_ftplib failed -- Traceback (most recent call last): File "/tmp/python-test/local/lib/python2.6/test/test_ftplib.py", line 81, in testTimeoutNone ftp = ftplib.FTP("localhost", timeout=None) File "/tmp/python-test/local/lib/python2.6/ftplib.py", line 115, in __init__ self.connect(host) File "/tmp/python-test/local/lib/python2.6/ftplib.py", line 130, in connect self.sock = socket.create_connection((self.host, self.port), self.timeout) File "/tmp/python-test/local/lib/python2.6/socket.py", line 465, in create_connection raise error, msg error: [Errno 111] Connection refused test_funcattrs test_functools test_future test_gc test_gdbm test_generators test_genericpath test_genexps test_getargs test_getargs2 test_getopt test_gettext test_gl test_gl skipped -- No module named gl test_glob test_global test_grp test_gzip test_hash test_hashlib test_heapq test_hexoct test_hmac test_hotshot test_htmllib test_htmlparser test_httplib test_imageop test_imageop skipped -- No module named imgfile test_imaplib test_imgfile test_imgfile skipped -- No module named imgfile test_imp test_import test_importhooks test_index test_inspect test_ioctl test_ioctl skipped -- Unable to open /dev/tty test_isinstance test_iter test_iterlen test_itertools test_largefile test_linuxaudiodev test_linuxaudiodev skipped -- Use of the `audio' resource not enabled test_list test_locale test_logging test_long test_long_future test_longexp test_macostools test_macostools skipped -- No module named macostools test_macpath test_mailbox test_marshal test_math test_md5 test_mhlib test_mimetools test_mimetypes test_minidom test_mmap test_module test_modulefinder test_multibytecodec test_multibytecodec_support test_multifile test_mutants test_netrc test_new test_nis test_normalization test_normalization skipped -- Use of the `urlfetch' resource not enabled test_ntpath test_old_mailbox test_openpty test_operator test_optparse test_os test_ossaudiodev test_ossaudiodev skipped -- Use of the `audio' resource not enabled test_parser test_peepholer test_pep247 test_pep263 test_pep277 test_pep277 skipped -- test works only on NT+ test_pep292 test_pep352 test_pickle test_pickletools test_pipes test_pkg test_pkgimport test_platform test_plistlib test_poll test_popen [8908 refs] [8908 refs] [8908 refs] test_popen2 test_poplib test_posix test_posixpath test_pow test_pprint test_profile test_profilehooks test_property test_pstats test_pty test_pwd test_pyclbr test_pyexpat test_queue test_quopri [9277 refs] [9277 refs] test_random test_rational test_re test_repr test_resource test_rfc822 test_richcmp test_robotparser test_runpy test_sax test_scope test_scriptpackages test_scriptpackages skipped -- No module named aetools test_select test_set test_sets test_sgmllib test_sha test_shelve test_shlex test_shutil test_signal test_site test_slice test_smtplib test_socket test_socket_ssl /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:94: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ssl_sock = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:130: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:144: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) test_socketserver test_socketserver skipped -- Use of the `network' resource not enabled test_softspace test_sort test_sqlite test_ssl test_startfile test_startfile skipped -- cannot import name startfile test_str test_strftime test_string test_stringprep test_strop test_strptime test_struct test_structmembers test_structseq test_subprocess [8903 refs] [8906 refs] [8903 refs] [8903 refs] [8903 refs] [8903 refs] [8903 refs] [8903 refs] [8903 refs] [8905 refs] [8906 refs] [10457 refs] [9121 refs] [8906 refs] [8903 refs] [8903 refs] [8903 refs] [8903 refs] [8903 refs] . [8903 refs] [8903 refs] this bit of output is from a test of stdout in a different process ... [8903 refs] [8903 refs] [9121 refs] test_sunaudiodev test_sunaudiodev skipped -- No module named sunaudiodev test_sundry test_symtable test_syntax test_sys [8903 refs] [8903 refs] test_tarfile test_tcl test_tcl skipped -- No module named _tkinter test_telnetlib test_tempfile [8909 refs] test_textwrap test_thread test_threaded_import test_threadedtempfile test_threading [13151 refs] test_threading_local test_threadsignals test_time test_timeout test_timeout skipped -- Use of the `network' resource not enabled test_tokenize test_trace test_traceback test_transformer test_tuple test_typechecks test_ucn test_unary test_unicode test_unicode_file test_unicode_file skipped -- No Unicode filesystem semantics on this platform. test_unicodedata test_univnewlines test_unpack test_urllib test_urllib2 test_urllib2_localnet test_urllib2net test_urllib2net skipped -- Use of the `network' resource not enabled test_urllibnet test_urllibnet skipped -- Use of the `network' resource not enabled test_urlparse test_userdict test_userlist test_userstring test_uu test_uuid WARNING: uuid.getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._ifconfig_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._unixdll_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. test_wait3 test_wait4 test_warnings test_wave test_weakref test_whichdb test_winreg test_winreg skipped -- No module named _winreg test_winsound test_winsound skipped -- No module named winsound test_with test_wsgiref test_xdrlib test_xml_etree test_xml_etree_c test_xmllib test_xmlrpc test_xpickle test_xrange test_zipfile /tmp/python-test/local/lib/python2.6/test/test_zipfile.py:471: DeprecationWarning: struct integer overflow masking is deprecated zipfp.close() /tmp/python-test/local/lib/python2.6/test/test_zipfile.py:398: DeprecationWarning: struct integer overflow masking is deprecated zipfp.close() test_zipfile64 test_zipfile64 skipped -- test requires loads of disk-space bytes and a long time to run test_zipimport test_zlib 303 tests OK. 2 tests failed: test_asynchat test_ftplib 34 tests skipped: test_aepack test_al test_applesingle test_bsddb185 test_bsddb3 test_cd test_cl test_codecmaps_cn test_codecmaps_hk test_codecmaps_jp test_codecmaps_kr test_codecmaps_tw test_curses test_gl test_imageop test_imgfile test_ioctl test_linuxaudiodev test_macostools test_normalization test_ossaudiodev test_pep277 test_scriptpackages test_socketserver test_startfile test_sunaudiodev test_tcl test_timeout test_unicode_file test_urllib2net test_urllibnet test_winreg test_winsound test_zipfile64 1 skip unexpected on linux2: test_ioctl [532137 refs] From guido at python.org Wed Jan 23 16:21:44 2008 From: guido at python.org (Guido van Rossum) Date: Wed, 23 Jan 2008 07:21:44 -0800 Subject: [Python-checkins] r60207 - in python/trunk: Doc/library/pprint.rst Lib/pprint.py Misc/NEWS In-Reply-To: References: <20080122194630.AFN26415@ms19.lnh.mail.rcn.net> Message-ID: Raymond, can you add tests for the new output format? *nudge* On Jan 23, 2008 12:38 AM, Christian Heimes wrote: > Guido van Rossum wrote: > > Yes, or you could do the next merge yourself. Christian can help you > > with the procedure if you need it. > > I read your post to the python cvs list and did the customization for > you. The pprint has no test for set and frozenset so I don't know if it > works. *wink* > > Christian -- --Guido van Rossum (home page: http://www.python.org/~guido/) From buildbot at python.org Wed Jan 23 16:28:28 2008 From: buildbot at python.org (buildbot at python.org) Date: Wed, 23 Jan 2008 15:28:28 +0000 Subject: [Python-checkins] buildbot failure in alpha Tru64 5.1 2.5 Message-ID: <20080123152829.03F241E400F@bag.python.org> The Buildbot has detected a new failure of alpha Tru64 5.1 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/alpha%20Tru64%205.1%202.5/builds/411 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-tru64 Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_socket sincerely, -The Buildbot From python-checkins at python.org Wed Jan 23 16:44:46 2008 From: python-checkins at python.org (christian.heimes) Date: Wed, 23 Jan 2008 16:44:46 +0100 (CET) Subject: [Python-checkins] r60217 - in python/branches/trunk-math: Lib/test/test_math.py Modules/mathmodule.c Objects/floatobject.c Message-ID: <20080123154446.60E3D1E400F@bag.python.org> Author: christian.heimes Date: Wed Jan 23 16:44:46 2008 New Revision: 60217 Modified: python/branches/trunk-math/Lib/test/test_math.py python/branches/trunk-math/Modules/mathmodule.c python/branches/trunk-math/Objects/floatobject.c Log: Make 1**x and pow(1,x) always return 1, even for nan and inf Modified: python/branches/trunk-math/Lib/test/test_math.py ============================================================================== --- python/branches/trunk-math/Lib/test/test_math.py (original) +++ python/branches/trunk-math/Lib/test/test_math.py Wed Jan 23 16:44:46 2008 @@ -320,7 +320,16 @@ self.assertRaises(ValueError, math.pow, 1, INF) self.assertRaises(ValueError, math.pow, 1, NINF) self.assert_(math.isnan(math.pow(NAN, 1))) - self.assert_(math.isnan(math.pow(1, NAN))) + self.assert_(math.isnan(math.pow(2, NAN))) + self.assertEqual(math.pow(1, NAN), 1) + self.assertEqual(1**NAN, 1) + self.assertEqual(1**INF, 1) + self.assertEqual(1**NINF, 1) + self.assertEqual(1**0, 1) + self.assertEqual(1.**NAN, 1) + self.assertEqual(1.**INF, 1) + self.assertEqual(1.**NINF, 1) + self.assertEqual(1.**0, 1) def testRadians(self): self.assertRaises(TypeError, math.radians) Modified: python/branches/trunk-math/Modules/mathmodule.c ============================================================================== --- python/branches/trunk-math/Modules/mathmodule.c (original) +++ python/branches/trunk-math/Modules/mathmodule.c Wed Jan 23 16:44:46 2008 @@ -133,8 +133,6 @@ " x % y may differ.") FUNC2(hypot, hypot, "hypot(x,y)\n\nReturn the Euclidean distance, sqrt(x*x + y*y).") -FUNC2(pow, pow, - "pow(x,y)\n\nReturn x**y (x to the power of y).") FUNC1(sin, sin, "sin(x)\n\nReturn the sine of x (measured in radians).") FUNC1(sinh, sinh, @@ -316,6 +314,38 @@ PyDoc_STRVAR(math_log10_doc, "log10(x) -> the base 10 logarithm of x."); +static PyObject * +math_pow(PyObject *self, PyObject *args) +{ + PyObject *ox, *oy; + double x, y; + if (! PyArg_UnpackTuple(args, "pow", 2, 2, &ox, &oy)) + return NULL; + x = PyFloat_AsDouble(ox); + y = PyFloat_AsDouble(oy); + if ((x == -1.0 || y == -1.0) && PyErr_Occurred()) + return NULL; + /* 1^x returns 1., even NaN and INF */ + if (x == 1.0) + return PyFloat_FromDouble(1.); +#ifndef __GNUC__ /* Windows et al */ + if (Py_IS_NAN(x) || Py_IS_NAN(y)) + return PyFloat_FromDouble(x+y); +#endif + errno = 0; + PyFPE_START_PROTECT("in math_pow", return 0) + x = pow(x, y); + PyFPE_END_PROTECT(x) + Py_SET_ERRNO_ON_MATH_ERROR(x); + if (errno && is_error(x)) + return NULL; + else + return PyFloat_FromDouble(x); +} + +PyDoc_STRVAR(math_pow_doc, +"pow(x,y)\n\nReturn x**y (x to the power of y)."); + static const double degToRad = Py_MATH_PI / 180.0; static const double radToDeg = 180.0 / Py_MATH_PI; Modified: python/branches/trunk-math/Objects/floatobject.c ============================================================================== --- python/branches/trunk-math/Objects/floatobject.c (original) +++ python/branches/trunk-math/Objects/floatobject.c Wed Jan 23 16:44:46 2008 @@ -1029,6 +1029,9 @@ return NULL; } return PyFloat_FromDouble(0.0); + if (iv == 1.0) { /* 1**w is 1, even 1**inf and 1**nan */ + return PyFloat_FromDouble(1.0); + } } if (iv < 0.0) { /* Whether this is an error is a mess, and bumps into libm From python-checkins at python.org Wed Jan 23 17:02:55 2008 From: python-checkins at python.org (christian.heimes) Date: Wed, 23 Jan 2008 17:02:55 +0100 (CET) Subject: [Python-checkins] r60218 - in python/branches/trunk-math: Doc/library/math.rst Lib/test/test_math.py Modules/mathmodule.c Message-ID: <20080123160255.DB2E11E400F@bag.python.org> Author: christian.heimes Date: Wed Jan 23 17:02:55 2008 New Revision: 60218 Modified: python/branches/trunk-math/Doc/library/math.rst python/branches/trunk-math/Lib/test/test_math.py python/branches/trunk-math/Modules/mathmodule.c Log: Make sure pow(0., y) has a constant outcome on all platforms Modified: python/branches/trunk-math/Doc/library/math.rst ============================================================================== --- python/branches/trunk-math/Doc/library/math.rst (original) +++ python/branches/trunk-math/Doc/library/math.rst Wed Jan 23 17:02:55 2008 @@ -147,7 +147,11 @@ .. function:: pow(x, y) - Return ``x**y``. + Return ``x**y``. ``1.0**y`` returns *1.0*, even for ``1.0**nan``. ``0**y`` + returns *0.* for all positive *y* and *0*. + + .. versionchanged:: 2.6 + The outcome of 1**nan was undefined. .. function:: sqrt(x) Modified: python/branches/trunk-math/Lib/test/test_math.py ============================================================================== --- python/branches/trunk-math/Lib/test/test_math.py (original) +++ python/branches/trunk-math/Lib/test/test_math.py Wed Jan 23 17:02:55 2008 @@ -321,6 +321,7 @@ self.assertRaises(ValueError, math.pow, 1, NINF) self.assert_(math.isnan(math.pow(NAN, 1))) self.assert_(math.isnan(math.pow(2, NAN))) + self.assert_(math.isnan(math.pow(0, NAN))) self.assertEqual(math.pow(1, NAN), 1) self.assertEqual(1**NAN, 1) self.assertEqual(1**INF, 1) Modified: python/branches/trunk-math/Modules/mathmodule.c ============================================================================== --- python/branches/trunk-math/Modules/mathmodule.c (original) +++ python/branches/trunk-math/Modules/mathmodule.c Wed Jan 23 17:02:55 2008 @@ -328,6 +328,16 @@ /* 1^x returns 1., even NaN and INF */ if (x == 1.0) return PyFloat_FromDouble(1.); + if (x == 0.0) { + if (y >= 0.0) + return PyFloat_FromDouble(0.); + if (Py_IS_NAN(y)) + return PyFloat_FromDouble(Py_NAN); + /* 0 raise to a negative value */ + errno = EDOM; + is_error(x); + return NULL; + } #ifndef __GNUC__ /* Windows et al */ if (Py_IS_NAN(x) || Py_IS_NAN(y)) return PyFloat_FromDouble(x+y); From nnorwitz at gmail.com Wed Jan 23 17:59:26 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Wed, 23 Jan 2008 11:59:26 -0500 Subject: [Python-checkins] Python Regression Test Failures refleak (7) Message-ID: <20080123165926.GA25989@python.psfb.org> test_opcodes leaked [0, -2, 2] references, sum=0 test_doctest leaked [-2, 2, 0] references, sum=0 test_doctest2 leaked [-2, -2, 0] references, sum=-4 test_descrtut leaked [2, 2, -2] references, sum=2 test_difflib leaked [0, -2, 0] references, sum=-2 test_gc leaked [-2, 0, 0] references, sum=-2 test_getargs2 leaked [0, -2, 0] references, sum=-2 test_importhooks leaked [-2, 2, -2] references, sum=-2 test_plistlib leaked [0, -2, 0] references, sum=-2 test_threadedtempfile leaked [0, 70, -70] references, sum=0 test_threadsignals leaked [0, -8, 0] references, sum=-8 test_urllib2_localnet leaked [3, 3, 3] references, sum=9 test_weakref leaked [0, -2, 2] references, sum=0 From python-checkins at python.org Wed Jan 23 17:49:01 2008 From: python-checkins at python.org (christian.heimes) Date: Wed, 23 Jan 2008 17:49:01 +0100 (CET) Subject: [Python-checkins] r60219 - python/branches/trunk-math/Objects/floatobject.c Message-ID: <20080123164901.722021E400F@bag.python.org> Author: christian.heimes Date: Wed Jan 23 17:49:01 2008 New Revision: 60219 Modified: python/branches/trunk-math/Objects/floatobject.c Log: Moved the check for 1.0 to the right place. Modified: python/branches/trunk-math/Objects/floatobject.c ============================================================================== --- python/branches/trunk-math/Objects/floatobject.c (original) +++ python/branches/trunk-math/Objects/floatobject.c Wed Jan 23 17:49:01 2008 @@ -1029,10 +1029,10 @@ return NULL; } return PyFloat_FromDouble(0.0); + } if (iv == 1.0) { /* 1**w is 1, even 1**inf and 1**nan */ return PyFloat_FromDouble(1.0); } - } if (iv < 0.0) { /* Whether this is an error is a mess, and bumps into libm * bugs so we have to figure it out ourselves. From nnorwitz at gmail.com Wed Jan 23 18:18:58 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Wed, 23 Jan 2008 12:18:58 -0500 Subject: [Python-checkins] Python Regression Test Failures all (1) Message-ID: <20080123171858.GA29208@python.psfb.org> test_grammar test_opcodes test_dict test_builtin test_exceptions test_types test_unittest test_doctest test_doctest2 test_MimeWriter test_StringIO test___all__ test___future__ test__locale test_abc test_abstract_numbers test_aepack test_aepack skipped -- No module named aepack test_al test_al skipped -- No module named al test_anydbm test_applesingle test_applesingle skipped -- No module named macostools test_array test_ast test_asynchat test_asyncore test_atexit test_audioop test_augassign test_base64 test_bastion test_bigaddrspace test_bigmem test_binascii test_binhex test_binop test_bisect test_bool test_bsddb test_bsddb185 test_bsddb185 skipped -- No module named bsddb185 test_bsddb3 Exception in thread reader 2: Traceback (most recent call last): File "/tmp/python-test/local/lib/python2.6/threading.py", line 477, in __bootstrap_inner self.run() File "/tmp/python-test/local/lib/python2.6/threading.py", line 437, in run self.__target(*self.__args, **self.__kwargs) File "/tmp/python-test/local/lib/python2.6/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/tmp/python-test/local/lib/python2.6/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30996, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Exception in thread reader 1: Traceback (most recent call last): File "/tmp/python-test/local/lib/python2.6/threading.py", line 477, in __bootstrap_inner self.run() File "/tmp/python-test/local/lib/python2.6/threading.py", line 437, in run self.__target(*self.__args, **self.__kwargs) File "/tmp/python-test/local/lib/python2.6/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/tmp/python-test/local/lib/python2.6/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30996, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Exception in thread reader 0: Traceback (most recent call last): File "/tmp/python-test/local/lib/python2.6/threading.py", line 477, in __bootstrap_inner self.run() File "/tmp/python-test/local/lib/python2.6/threading.py", line 437, in run self.__target(*self.__args, **self.__kwargs) File "/tmp/python-test/local/lib/python2.6/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/tmp/python-test/local/lib/python2.6/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30996, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Exception in thread reader 4: Traceback (most recent call last): File "/tmp/python-test/local/lib/python2.6/threading.py", line 477, in __bootstrap_inner self.run() File "/tmp/python-test/local/lib/python2.6/threading.py", line 437, in run self.__target(*self.__args, **self.__kwargs) File "/tmp/python-test/local/lib/python2.6/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/tmp/python-test/local/lib/python2.6/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30996, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Exception in thread reader 3: Traceback (most recent call last): File "/tmp/python-test/local/lib/python2.6/threading.py", line 477, in __bootstrap_inner self.run() File "/tmp/python-test/local/lib/python2.6/threading.py", line 437, in run self.__target(*self.__args, **self.__kwargs) File "/tmp/python-test/local/lib/python2.6/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/tmp/python-test/local/lib/python2.6/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30996, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') test_buffer test_bufio test_bz2 test_cProfile test_calendar test_call test_capi test_cd test_cd skipped -- No module named cd test_cfgparser test_cgi test_charmapcodec test_cl test_cl skipped -- No module named cl test_class test_cmath test_cmd test_cmd_line test_cmd_line_script test_code test_codeccallbacks test_codecencodings_cn test_codecencodings_hk test_codecencodings_jp test_codecencodings_kr test_codecencodings_tw test_codecmaps_cn test_codecmaps_hk test_codecmaps_jp test_codecmaps_kr test_codecmaps_tw test_codecs test_codeop test_coding test_coercion test_collections test_colorsys test_commands test_compare test_compile test_compiler testCompileLibrary still working, be patient... test_complex test_complex_args test_contains test_contextlib test_cookie test_cookielib test_copy test_copy_reg test_cpickle test_crypt test_csv test_ctypes test_datetime test_dbm test_decimal test_decorators test_defaultdict test_deque test_descr test_descrtut test_difflib test_dircache test_dis test_distutils test_dl test_docxmlrpc test_dumbdbm test_dummy_thread test_dummy_threading test_email test_email_codecs test_email_renamed test_enumerate test_eof test_errno test_exception_variations test_extcall test_fcntl test_file test_filecmp test_fileinput test_float test_fnmatch test_fork1 test_format test_fpformat test_frozen test_ftplib test_funcattrs test_functools test_future test_gc test_gdbm test_generators test_genericpath test_genexps test_getargs test_getargs2 test_getopt test_gettext test_gl test_gl skipped -- No module named gl test_glob test_global test_grp test_gzip test_hash test_hashlib test_heapq test_hexoct test_hmac test_hotshot test_htmllib test_htmlparser test_httplib test_imageop test_imageop skipped -- No module named imgfile test_imaplib test_imgfile test_imgfile skipped -- No module named imgfile test_imp test_import test_importhooks test_index test_inspect test_ioctl test_ioctl skipped -- Unable to open /dev/tty test_isinstance test_iter test_iterlen test_itertools test_largefile test_list test_locale test_logging test_long test_long_future test_longexp test_macostools test_macostools skipped -- No module named macostools test_macpath test_mailbox test_marshal test_math test_md5 test_mhlib test_mimetools test_mimetypes test_minidom test_mmap test_module test_modulefinder test_multibytecodec test_multibytecodec_support test_multifile test_mutants test_netrc test_new test_nis test_normalization test_ntpath test_old_mailbox test_openpty test_operator test_optparse test_os test_parser test_peepholer test_pep247 test_pep263 test_pep277 test_pep277 skipped -- test works only on NT+ test_pep292 test_pep352 test_pickle test_pickletools test_pipes test_pkg test_pkgimport test_platform test_plistlib test_poll test_popen [8908 refs] [8908 refs] [8908 refs] test_popen2 test_poplib test_posix test_posixpath test_pow test_pprint test_profile test_profilehooks test_property test_pstats test_pty test_pwd test_pyclbr test_pyexpat test_queue test_quopri [9277 refs] [9277 refs] test_random test_rational test_re test_repr test_resource test_rfc822 test_richcmp test_robotparser test_runpy test_sax test_scope test_scriptpackages test_scriptpackages skipped -- No module named aetools test_select test_set test_sets test_sgmllib test_sha test_shelve test_shlex test_shutil test_signal test_site test_slice test_smtplib test_socket test_socket_ssl /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:94: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ssl_sock = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:60: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:130: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:144: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) test_socketserver test_softspace test_sort test_sqlite test_ssl test_startfile test_startfile skipped -- cannot import name startfile test_str test_strftime test_string test_stringprep test_strop test_strptime test_struct test_structmembers test_structseq test_subprocess [8903 refs] [8906 refs] [8903 refs] [8903 refs] [8903 refs] [8903 refs] [8903 refs] [8903 refs] [8903 refs] [8905 refs] [8906 refs] [10457 refs] [9121 refs] [8906 refs] [8903 refs] [8903 refs] [8903 refs] [8903 refs] [8903 refs] . [8903 refs] [8903 refs] this bit of output is from a test of stdout in a different process ... [8903 refs] [8903 refs] [9121 refs] test_sunaudiodev test_sunaudiodev skipped -- No module named sunaudiodev test_sundry test_symtable test_syntax test_sys [8903 refs] [8903 refs] test_tarfile test_tcl test_tcl skipped -- No module named _tkinter test_telnetlib test_tempfile [8909 refs] test_textwrap test_thread test_threaded_import test_threadedtempfile test_threading [13151 refs] test_threading_local test_threadsignals test_time test_timeout test_tokenize test_trace test_traceback test_transformer test_tuple test_typechecks test_ucn test_unary test_unicode test_unicode_file test_unicode_file skipped -- No Unicode filesystem semantics on this platform. test_unicodedata test_univnewlines test_unpack test_urllib test_urllib2 test_urllib2_localnet test_urllib2net test test_urllib2net failed -- Traceback (most recent call last): File "/tmp/python-test/local/lib/python2.6/test/test_urllib2net.py", line 175, in test_ftp self._test_urls(urls, self._extra_handlers()) File "/tmp/python-test/local/lib/python2.6/test/test_urllib2net.py", line 244, in _test_urls f = urllib2.urlopen(url, req) File "/tmp/python-test/local/lib/python2.6/urllib2.py", line 124, in urlopen return _opener.open(url, data, timeout) File "/tmp/python-test/local/lib/python2.6/urllib2.py", line 380, in open response = self._open(req, data) File "/tmp/python-test/local/lib/python2.6/urllib2.py", line 398, in _open '_open', req) File "/tmp/python-test/local/lib/python2.6/urllib2.py", line 358, in _call_chain result = func(*args) File "/tmp/python-test/local/lib/python2.6/urllib2.py", line 1284, in ftp_open fp, retrlen = fw.retrfile(file, type) File "/tmp/python-test/local/lib/python2.6/urllib.py", line 868, in retrfile conn = self.ftp.ntransfercmd(cmd) File "/tmp/python-test/local/lib/python2.6/ftplib.py", line 323, in ntransfercmd conn = socket.create_connection((host, port), self.timeout) File "/tmp/python-test/local/lib/python2.6/socket.py", line 465, in create_connection raise error, msg TypeError: __init__() takes exactly 2 arguments (3 given) test_urllibnet test_urlparse test_userdict test_userlist test_userstring test_uu test_uuid WARNING: uuid.getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._ifconfig_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._unixdll_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. test_wait3 test_wait4 test_warnings test_wave test_weakref test_whichdb test_winreg test_winreg skipped -- No module named _winreg test_winsound test_winsound skipped -- No module named winsound test_with test_wsgiref test_xdrlib test_xml_etree test_xml_etree_c test_xmllib test_xmlrpc test_xpickle test_xrange test_zipfile /tmp/python-test/local/lib/python2.6/test/test_zipfile.py:471: DeprecationWarning: struct integer overflow masking is deprecated zipfp.close() /tmp/python-test/local/lib/python2.6/test/test_zipfile.py:398: DeprecationWarning: struct integer overflow masking is deprecated zipfp.close() test_zipfile64 test_zipfile64 skipped -- test requires loads of disk-space bytes and a long time to run test_zipimport test_zlib 315 tests OK. 1 test failed: test_urllib2net 20 tests skipped: test_aepack test_al test_applesingle test_bsddb185 test_cd test_cl test_gl test_imageop test_imgfile test_ioctl test_macostools test_pep277 test_scriptpackages test_startfile test_sunaudiodev test_tcl test_unicode_file test_winreg test_winsound test_zipfile64 1 skip unexpected on linux2: test_ioctl [542387 refs] From python-checkins at python.org Wed Jan 23 18:15:06 2008 From: python-checkins at python.org (christian.heimes) Date: Wed, 23 Jan 2008 18:15:06 +0100 (CET) Subject: [Python-checkins] r60221 - in python/trunk: Misc/NEWS Python/dynload_win.c Message-ID: <20080123171506.CF5E51E400F@bag.python.org> Author: christian.heimes Date: Wed Jan 23 18:15:06 2008 New Revision: 60221 Modified: python/trunk/Misc/NEWS python/trunk/Python/dynload_win.c Log: Applied #1069410 The "can't load dll" message box on Windows is suppressed while an extension is loaded by calling SetErrorMode in dynload_win.c. The error is still reported properly. Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Wed Jan 23 18:15:06 2008 @@ -12,6 +12,10 @@ Core and builtins ----------------- +- Issue #1069410: The "can't load dll" message box on Windows is + suppressed while an extension is loaded by calling SetErrorMode in + dynload_win.c. The error is still reported properly. + - Bug #1915: Python compiles with --enable-unicode=no again. However several extension methods and modules do not work without unicode support. Modified: python/trunk/Python/dynload_win.c ============================================================================== --- python/trunk/Python/dynload_win.c (original) +++ python/trunk/Python/dynload_win.c Wed Jan 23 18:15:06 2008 @@ -171,11 +171,16 @@ HINSTANCE hDLL = NULL; char pathbuf[260]; LPTSTR dummy; + unsigned int old_mode; /* We use LoadLibraryEx so Windows looks for dependent DLLs in directory of pathname first. However, Windows95 can sometimes not work correctly unless the absolute path is used. If GetFullPathName() fails, the LoadLibrary will certainly fail too, so use its error code */ + + /* Don't display a message box when Python can't load a DLL */ + old_mode = SetErrorMode(SEM_FAILCRITICALERRORS); + if (GetFullPathName(pathname, sizeof(pathbuf), pathbuf, @@ -183,6 +188,10 @@ /* XXX This call doesn't exist in Windows CE */ hDLL = LoadLibraryEx(pathname, NULL, LOAD_WITH_ALTERED_SEARCH_PATH); + + /* restore old error mode settings */ + SetErrorMode(old_mode); + if (hDLL==NULL){ char errBuf[256]; unsigned int errorCode; From python-checkins at python.org Wed Jan 23 18:54:14 2008 From: python-checkins at python.org (martin.v.loewis) Date: Wed, 23 Jan 2008 18:54:14 +0100 (CET) Subject: [Python-checkins] r60222 - python/branches/release25-maint/Tools/msi/msi.py Message-ID: <20080123175414.C3C331E400F@bag.python.org> Author: martin.v.loewis Date: Wed Jan 23 18:54:14 2008 New Revision: 60222 Modified: python/branches/release25-maint/Tools/msi/msi.py Log: Fix product code handling for Win64. Modified: python/branches/release25-maint/Tools/msi/msi.py ============================================================================== --- python/branches/release25-maint/Tools/msi/msi.py (original) +++ python/branches/release25-maint/Tools/msi/msi.py Wed Jan 23 18:54:14 2008 @@ -68,6 +68,11 @@ # both 32-bit and 64-bit versions of Python on a single system. upgrade_code_64='{6A965A0C-6EE6-4E3A-9983-3263F56311EC}' +# Determine the target architechture +dll_file = "python%s%s.dll" % (major, minor) +dll_path = os.path.join(srcdir, "PCBuild", dll_file) +msilib.set_arch_from_file(dll_path) + if snapshot: current_version = "%s.%s.%s" % (major, minor, int(time.time()/3600/24)) product_code = msilib.gen_uuid() @@ -76,7 +81,7 @@ if msilib.Win64: # Bump the last digit of the code by one, so that 32-bit and 64-bit # releases get separate product codes - digit = hex((int(product_codes[-2],16)+1)%16)[-1] + digit = hex((int(product_code[-2],16)+1)%16)[-1] product_code = product_code[:-2] + digit + '}' if full_current_version is None: @@ -155,14 +160,10 @@ # Target files (.def and .a) go in PCBuild directory lib_file = os.path.join(srcdir, "PCBuild", "python%s%s.lib" % (major, minor)) def_file = os.path.join(srcdir, "PCBuild", "python%s%s.def" % (major, minor)) -dll_file = "python%s%s.dll" % (major, minor) mingw_lib = os.path.join(srcdir, "PCBuild", "libpython%s%s.a" % (major, minor)) have_mingw = build_mingw_lib(lib_file, def_file, dll_file, mingw_lib) -# Determine the target architechture -dll_path = os.path.join(srcdir, "PCBuild", dll_file) -msilib.set_arch_from_file(dll_path) if msilib.pe_type(dll_path) != msilib.pe_type("msisupport.dll"): raise SystemError, "msisupport.dll for incorrect architecture" @@ -196,11 +197,15 @@ uc = upgrade_code_64 else: uc = upgrade_code + if msilib.Win64: + productsuffix = " (64 bit)" + else: + productsuffix = "" # schema represents the installer 2.0 database schema. # sequence is the set of standard sequences # (ui/execute, admin/advt/install) db = msilib.init_database("python-%s%s.msi" % (full_current_version, msilib.arch_ext), - schema, ProductName="Python "+full_current_version, + schema, ProductName="Python "+full_current_version+productsuffix, ProductCode=product_code, ProductVersion=current_version, Manufacturer=u"Python Software Foundation") @@ -249,9 +254,9 @@ # For 2.5, also upgrade installation with upgrade_code # of 2.5.0 and 2.5.1, since they used the same code for # 64-bit versions - assert major==2 and minor==5 - extra = (upgrade_code, start, "2.5.2", - None, migrate_features, None, "REMOVEOLDVERSION") + assert major=='2' and minor=='5' + extra = [(upgrade_code, start, "2.5.2000", + None, migrate_features, None, "REMOVEOLDVERSION")] else: uc = upgrade_code extra = [] @@ -259,7 +264,7 @@ [(uc, start, current_version, None, migrate_features, None, "REMOVEOLDVERSION"), (upgrade_code_snapshot, start, "%s.%d.0" % (major, int(minor)+1), - None, migrate_features, None, "REMOVEOLDSNAPSHOT")+extra]) + None, migrate_features, None, "REMOVEOLDSNAPSHOT")]+extra) props = "REMOVEOLDSNAPSHOT;REMOVEOLDVERSION" # Installer collects the product codes of the earlier releases in # these properties. In order to allow modification of the properties, From python-checkins at python.org Wed Jan 23 21:09:40 2008 From: python-checkins at python.org (guido.van.rossum) Date: Wed, 23 Jan 2008 21:09:40 +0100 (CET) Subject: [Python-checkins] r60223 - python/branches/release25-maint/Python/bltinmodule.c python/branches/release25-maint/Python/ceval.c Message-ID: <20080123200940.724161E4011@bag.python.org> Author: guido.van.rossum Date: Wed Jan 23 21:09:39 2008 New Revision: 60223 Modified: python/branches/release25-maint/Python/bltinmodule.c python/branches/release25-maint/Python/ceval.c Log: Fix two crashers (borrowed_ref_[34].py from the trunk). Modified: python/branches/release25-maint/Python/bltinmodule.c ============================================================================== --- python/branches/release25-maint/Python/bltinmodule.c (original) +++ python/branches/release25-maint/Python/bltinmodule.c Wed Jan 23 21:09:39 2008 @@ -1218,11 +1218,14 @@ "%s() got an unexpected keyword argument", name); return NULL; } + Py_INCREF(keyfunc); } it = PyObject_GetIter(v); - if (it == NULL) + if (it == NULL) { + Py_XDECREF(keyfunc); return NULL; + } maxitem = NULL; /* the result */ maxval = NULL; /* the value associated with the result */ @@ -1271,6 +1274,7 @@ else Py_DECREF(maxval); Py_DECREF(it); + Py_XDECREF(keyfunc); return maxitem; Fail_it_item_and_val: @@ -1281,6 +1285,7 @@ Py_XDECREF(maxval); Py_XDECREF(maxitem); Py_DECREF(it); + Py_XDECREF(keyfunc); return NULL; } Modified: python/branches/release25-maint/Python/ceval.c ============================================================================== --- python/branches/release25-maint/Python/ceval.c (original) +++ python/branches/release25-maint/Python/ceval.c Wed Jan 23 21:09:39 2008 @@ -2036,6 +2036,7 @@ "__import__ not found"); break; } + Py_INCREF(x); v = POP(); u = TOP(); if (PyInt_AsLong(u) != -1 || PyErr_Occurred()) @@ -2057,11 +2058,14 @@ Py_DECREF(u); if (w == NULL) { u = POP(); + Py_DECREF(x); x = NULL; break; } READ_TIMESTAMP(intr0); - x = PyEval_CallObject(x, w); + v = x; + x = PyEval_CallObject(v, w); + Py_DECREF(v); READ_TIMESTAMP(intr1); Py_DECREF(w); SET_TOP(x); From python-checkins at python.org Wed Jan 23 21:19:02 2008 From: python-checkins at python.org (guido.van.rossum) Date: Wed, 23 Jan 2008 21:19:02 +0100 (CET) Subject: [Python-checkins] r60224 - in python/trunk: Lib/test/crashers/borrowed_ref_3.py Lib/test/crashers/borrowed_ref_4.py Python/bltinmodule.c Python/ceval.c Message-ID: <20080123201902.47B251E400F@bag.python.org> Author: guido.van.rossum Date: Wed Jan 23 21:19:01 2008 New Revision: 60224 Removed: python/trunk/Lib/test/crashers/borrowed_ref_3.py python/trunk/Lib/test/crashers/borrowed_ref_4.py Modified: python/trunk/Python/bltinmodule.c python/trunk/Python/ceval.c Log: Fix two crashers. Deleted: /python/trunk/Lib/test/crashers/borrowed_ref_3.py ============================================================================== --- /python/trunk/Lib/test/crashers/borrowed_ref_3.py Wed Jan 23 21:19:01 2008 +++ (empty file) @@ -1,14 +0,0 @@ -""" -PyDict_GetItem() returns a borrowed reference. -There are probably a number of places that are open to attacks -such as the following one, in bltinmodule.c:min_max(). -""" - -class KeyFunc(object): - def __call__(self, n): - del d['key'] - return 1 - - -d = {'key': KeyFunc()} -min(range(10), **d) Deleted: /python/trunk/Lib/test/crashers/borrowed_ref_4.py ============================================================================== --- /python/trunk/Lib/test/crashers/borrowed_ref_4.py Wed Jan 23 21:19:01 2008 +++ (empty file) @@ -1,28 +0,0 @@ -""" -PyDict_GetItem() returns a borrowed reference. -This attack is against ceval.c:IMPORT_NAME, which calls an -object (__builtin__.__import__) without holding a reference to it. -""" - -import types -import __builtin__ - - -class X(object): - def __getattr__(self, name): - # this is called with name == '__bases__' by PyObject_IsInstance() - # during the unbound method call -- it frees the unbound method - # itself before it invokes its im_func. - del __builtin__.__import__ - return () - -pseudoclass = X() - -class Y(object): - def __call__(self, *args): - # 'self' was freed already - print self, args - -# make an unbound method -__builtin__.__import__ = types.MethodType(Y(), None, (pseudoclass, str)) -import spam Modified: python/trunk/Python/bltinmodule.c ============================================================================== --- python/trunk/Python/bltinmodule.c (original) +++ python/trunk/Python/bltinmodule.c Wed Jan 23 21:19:01 2008 @@ -1245,11 +1245,14 @@ "%s() got an unexpected keyword argument", name); return NULL; } + Py_INCREF(keyfunc); } it = PyObject_GetIter(v); - if (it == NULL) + if (it == NULL) { + Py_XDECREF(keyfunc); return NULL; + } maxitem = NULL; /* the result */ maxval = NULL; /* the value associated with the result */ @@ -1298,6 +1301,7 @@ else Py_DECREF(maxval); Py_DECREF(it); + Py_XDECREF(keyfunc); return maxitem; Fail_it_item_and_val: @@ -1308,6 +1312,7 @@ Py_XDECREF(maxval); Py_XDECREF(maxitem); Py_DECREF(it); + Py_XDECREF(keyfunc); return NULL; } Modified: python/trunk/Python/ceval.c ============================================================================== --- python/trunk/Python/ceval.c (original) +++ python/trunk/Python/ceval.c Wed Jan 23 21:19:01 2008 @@ -2066,6 +2066,7 @@ "__import__ not found"); break; } + Py_INCREF(x); v = POP(); u = TOP(); if (PyInt_AsLong(u) != -1 || PyErr_Occurred()) @@ -2087,11 +2088,14 @@ Py_DECREF(u); if (w == NULL) { u = POP(); + Py_DECREF(x); x = NULL; break; } READ_TIMESTAMP(intr0); - x = PyEval_CallObject(x, w); + v = x; + x = PyEval_CallObject(v, w); + Py_DECREF(v); READ_TIMESTAMP(intr1); Py_DECREF(w); SET_TOP(x); From nnorwitz at gmail.com Wed Jan 23 22:53:23 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Wed, 23 Jan 2008 13:53:23 -0800 Subject: [Python-checkins] r60224 - in python/trunk: Lib/test/crashers/borrowed_ref_3.py Lib/test/crashers/borrowed_ref_4.py Python/bltinmodule.c Python/ceval.c In-Reply-To: <20080123201902.47B251E400F@bag.python.org> References: <20080123201902.47B251E400F@bag.python.org> Message-ID: On Jan 23, 2008 12:19 PM, guido.van.rossum wrote: > Author: guido.van.rossum > Date: Wed Jan 23 21:19:01 2008 > New Revision: 60224 > > Removed: > python/trunk/Lib/test/crashers/borrowed_ref_3.py > python/trunk/Lib/test/crashers/borrowed_ref_4.py > Modified: > python/trunk/Python/bltinmodule.c > python/trunk/Python/ceval.c > Log: > Fix two crashers. Rather than just remove the crasher files, it would be good to turn them into tests. n From nnorwitz at gmail.com Wed Jan 23 23:27:25 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Wed, 23 Jan 2008 17:27:25 -0500 Subject: [Python-checkins] Python Regression Test Failures refleak (9) Message-ID: <20080123222725.GA26512@python.psfb.org> test_opcodes leaked [0, -2, 2] references, sum=0 test_doctest leaked [-2, 2, 0] references, sum=0 test_doctest2 leaked [-2, -2, 0] references, sum=-4 test_cmd_line leaked [0, -23, 23] references, sum=0 test_descrtut leaked [2, 2, -2] references, sum=2 test_difflib leaked [0, -2, 0] references, sum=-2 test_gc leaked [-2, 0, 0] references, sum=-2 test_getargs2 leaked [0, -2, 0] references, sum=-2 test_importhooks leaked [-2, 2, -2] references, sum=-2 test_plistlib leaked [0, -2, 0] references, sum=-2 test_ssl leaked [-2, 0, 0] references, sum=-2 test_threadsignals leaked [0, -8, 0] references, sum=-8 test_urllib2_localnet leaked [-120, 158, -30] references, sum=8 test_urlparse leaked [-2, 0, 0] references, sum=-2 test_weakref leaked [0, -2, 2] references, sum=0 From python-checkins at python.org Wed Jan 23 23:19:24 2008 From: python-checkins at python.org (kurt.kaiser) Date: Wed, 23 Jan 2008 23:19:24 +0100 (CET) Subject: [Python-checkins] r60225 - python/trunk/Lib/idlelib/NEWS.txt python/trunk/Lib/idlelib/configHandler.py Message-ID: <20080123221924.57B021E401C@bag.python.org> Author: kurt.kaiser Date: Wed Jan 23 23:19:23 2008 New Revision: 60225 Modified: python/trunk/Lib/idlelib/NEWS.txt python/trunk/Lib/idlelib/configHandler.py Log: Could not open files in .idlerc directory if latter was hidden on Windows. Issue 1743, Issue 1862. Modified: python/trunk/Lib/idlelib/NEWS.txt ============================================================================== --- python/trunk/Lib/idlelib/NEWS.txt (original) +++ python/trunk/Lib/idlelib/NEWS.txt Wed Jan 23 23:19:23 2008 @@ -1,7 +1,10 @@ What's New in IDLE 2.6a1? ========================= -*Release date: XX-XXX-200X* +*Release date: XX-XXX-2008* + +- Could not open files in .idlerc directory if latter was hidden on Windows. + Issue 1743, Issue 1862. - Configure Dialog: improved layout for keybinding. Patch 1457 Tal Einat. Modified: python/trunk/Lib/idlelib/configHandler.py ============================================================================== --- python/trunk/Lib/idlelib/configHandler.py (original) +++ python/trunk/Lib/idlelib/configHandler.py Wed Jan 23 23:19:23 2008 @@ -139,7 +139,12 @@ """ if not self.IsEmpty(): - cfgFile=open(self.file,'w') + fname = self.file + try: + cfgFile = open(fname, 'w') + except IOError: + fname.unlink() + cfgFile = open(fname, 'w') self.write(cfgFile) else: self.RemoveFile() From nnorwitz at gmail.com Wed Jan 23 23:46:26 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Wed, 23 Jan 2008 17:46:26 -0500 Subject: [Python-checkins] Python Regression Test Failures all (1) Message-ID: <20080123224626.GA5191@python.psfb.org> test_grammar test_opcodes test_dict test_builtin test_exceptions test_types test_unittest test_doctest test_doctest2 test_MimeWriter test_StringIO test___all__ test___future__ test__locale test_abc test_abstract_numbers test_aepack test_aepack skipped -- No module named aepack test_al test_al skipped -- No module named al test_anydbm test_applesingle test_applesingle skipped -- No module named macostools test_array test_ast test_asynchat test_asyncore test_atexit test_audioop test_augassign test_base64 test_bastion test_bigaddrspace test_bigmem test_binascii test_binhex test_binop test_bisect test_bool test_bsddb test_bsddb185 test_bsddb185 skipped -- No module named bsddb185 test_bsddb3 test_buffer test_bufio test_bz2 test_cProfile test_calendar test_call test_capi test_cd test_cd skipped -- No module named cd test_cfgparser test_cgi test_charmapcodec test_cl test_cl skipped -- No module named cl test_class test_cmath test_cmd test_cmd_line test_cmd_line_script test_code test_codeccallbacks test_codecencodings_cn test_codecencodings_hk test_codecencodings_jp test_codecencodings_kr test_codecencodings_tw test_codecmaps_cn test_codecmaps_hk test_codecmaps_jp test_codecmaps_kr test_codecmaps_tw test_codecs test_codeop test_coding test_coercion test_collections test_colorsys test_commands test_compare test_compile test_compiler testCompileLibrary still working, be patient... test_complex test_complex_args test_contains test_contextlib test_cookie test_cookielib test_copy test_copy_reg test_cpickle test_crypt test_csv test_ctypes test_datetime test_dbm test_decimal test_decorators test_defaultdict test_deque test_descr test_descrtut test_difflib test_dircache test_dis test_distutils test_dl test_docxmlrpc test_dumbdbm test_dummy_thread test_dummy_threading test_email test_email_codecs test_email_renamed test_enumerate test_eof test_errno test_exception_variations test_extcall test_fcntl test_file test_filecmp test_fileinput test_float test_fnmatch test_fork1 test_format test_fpformat test_frozen test_ftplib test_funcattrs test_functools test_future test_gc test_gdbm test_generators test_genericpath test_genexps test_getargs test_getargs2 test_getopt test_gettext test_gl test_gl skipped -- No module named gl test_glob test_global test_grp test_gzip test_hash test_hashlib test_heapq test_hexoct test_hmac test_hotshot test_htmllib test_htmlparser test_httplib test_imageop test_imageop skipped -- No module named imgfile test_imaplib test_imgfile test_imgfile skipped -- No module named imgfile test_imp test_import test_importhooks test_index test_inspect test_ioctl test_ioctl skipped -- Unable to open /dev/tty test_isinstance test_iter test_iterlen test_itertools test_largefile test_list test_locale test_logging test_long test_long_future test_longexp test_macostools test_macostools skipped -- No module named macostools test_macpath test_mailbox test_marshal test_math test_md5 test_mhlib test_mimetools test_mimetypes test_minidom test_mmap test_module test_modulefinder test_multibytecodec test_multibytecodec_support test_multifile test_mutants test_netrc test_new test_nis test_normalization test_ntpath test_old_mailbox test_openpty test_operator test_optparse test_os test_parser test_peepholer test_pep247 test_pep263 test_pep277 test_pep277 skipped -- test works only on NT+ test_pep292 test_pep352 test_pickle test_pickletools test_pipes test_pkg test_pkgimport test_platform test_plistlib test_poll test_popen [8910 refs] [8910 refs] [8910 refs] test_popen2 test_poplib test_posix test_posixpath test_pow test_pprint test_profile test_profilehooks test_property test_pstats test_pty test_pwd test_pyclbr test_pyexpat test_queue test_quopri [9279 refs] [9279 refs] test_random test_rational test_re test_repr test_resource test_rfc822 test_richcmp test_robotparser test_runpy test_sax test_scope test_scriptpackages test_scriptpackages skipped -- No module named aetools test_select test_set test_sets test_sgmllib test_sha test_shelve test_shlex test_shutil test_signal test_site test_slice test_smtplib test_socket test_socket_ssl /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:94: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ssl_sock = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:60: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:130: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:144: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) test_socketserver test_softspace test_sort test_sqlite test_ssl test_startfile test_startfile skipped -- cannot import name startfile test_str test_strftime test_string test_stringprep test_strop test_strptime test_struct test_structmembers test_structseq test_subprocess [8905 refs] [8908 refs] [8905 refs] [8905 refs] [8905 refs] [8905 refs] [8905 refs] [8905 refs] [8905 refs] [8907 refs] [8908 refs] [10459 refs] [9123 refs] [8908 refs] [8905 refs] [8905 refs] [8905 refs] [8905 refs] [8905 refs] . [8905 refs] [8905 refs] this bit of output is from a test of stdout in a different process ... [8905 refs] [8905 refs] [9123 refs] test_sunaudiodev test_sunaudiodev skipped -- No module named sunaudiodev test_sundry test_symtable test_syntax test_sys [8905 refs] [8905 refs] test_tarfile test_tcl test_tcl skipped -- No module named _tkinter test_telnetlib test_tempfile [8911 refs] test_textwrap test_thread test_threaded_import test_threadedtempfile test_threading [13153 refs] test_threading_local test_threadsignals test_time test_timeout test_tokenize test_trace test_traceback test_transformer test_tuple test_typechecks test_ucn test_unary test_unicode test_unicode_file test_unicode_file skipped -- No Unicode filesystem semantics on this platform. test_unicodedata test_univnewlines test_unpack test_urllib test_urllib2 test_urllib2_localnet test_urllib2net test test_urllib2net failed -- Traceback (most recent call last): File "/tmp/python-test/local/lib/python2.6/test/test_urllib2net.py", line 175, in test_ftp self._test_urls(urls, self._extra_handlers()) File "/tmp/python-test/local/lib/python2.6/test/test_urllib2net.py", line 244, in _test_urls f = urllib2.urlopen(url, req) File "/tmp/python-test/local/lib/python2.6/urllib2.py", line 124, in urlopen return _opener.open(url, data, timeout) File "/tmp/python-test/local/lib/python2.6/urllib2.py", line 380, in open response = self._open(req, data) File "/tmp/python-test/local/lib/python2.6/urllib2.py", line 398, in _open '_open', req) File "/tmp/python-test/local/lib/python2.6/urllib2.py", line 358, in _call_chain result = func(*args) File "/tmp/python-test/local/lib/python2.6/urllib2.py", line 1284, in ftp_open fp, retrlen = fw.retrfile(file, type) File "/tmp/python-test/local/lib/python2.6/urllib.py", line 880, in retrfile self.ftp.cwd(file) File "/tmp/python-test/local/lib/python2.6/ftplib.py", line 538, in cwd return self.voidcmd(cmd) File "/tmp/python-test/local/lib/python2.6/ftplib.py", line 247, in voidcmd return self.voidresp() File "/tmp/python-test/local/lib/python2.6/ftplib.py", line 222, in voidresp resp = self.getresp() File "/tmp/python-test/local/lib/python2.6/ftplib.py", line 217, in getresp raise error_perm, resp TypeError: __init__() takes exactly 2 arguments (3 given) test_urllibnet test_urlparse test_userdict test_userlist test_userstring test_uu test_uuid WARNING: uuid.getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._ifconfig_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._unixdll_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. test_wait3 test_wait4 test_warnings test_wave test_weakref test_whichdb test_winreg test_winreg skipped -- No module named _winreg test_winsound test_winsound skipped -- No module named winsound test_with test_wsgiref test_xdrlib test_xml_etree test_xml_etree_c test_xmllib test_xmlrpc test_xpickle test_xrange test_zipfile /tmp/python-test/local/lib/python2.6/test/test_zipfile.py:471: DeprecationWarning: struct integer overflow masking is deprecated zipfp.close() /tmp/python-test/local/lib/python2.6/test/test_zipfile.py:398: DeprecationWarning: struct integer overflow masking is deprecated zipfp.close() test_zipfile64 test_zipfile64 skipped -- test requires loads of disk-space bytes and a long time to run test_zipimport test_zlib 315 tests OK. 1 test failed: test_urllib2net 20 tests skipped: test_aepack test_al test_applesingle test_bsddb185 test_cd test_cl test_gl test_imageop test_imgfile test_ioctl test_macostools test_pep277 test_scriptpackages test_startfile test_sunaudiodev test_tcl test_unicode_file test_winreg test_winsound test_zipfile64 1 skip unexpected on linux2: test_ioctl [542394 refs] From python-checkins at python.org Wed Jan 23 23:43:27 2008 From: python-checkins at python.org (guido.van.rossum) Date: Wed, 23 Jan 2008 23:43:27 +0100 (CET) Subject: [Python-checkins] r60226 - python/trunk/Modules/config.c.in Message-ID: <20080123224327.EBF341E4025@bag.python.org> Author: guido.van.rossum Date: Wed Jan 23 23:43:27 2008 New Revision: 60226 Modified: python/trunk/Modules/config.c.in Log: Fix misleading comment reported in issue #1917. Modified: python/trunk/Modules/config.c.in ============================================================================== --- python/trunk/Modules/config.c.in (original) +++ python/trunk/Modules/config.c.in Wed Jan 23 23:43:27 2008 @@ -43,7 +43,7 @@ /* This lives in Python/Python-ast.c */ {"_ast", init_ast}, - /* This lives in Python/_types.c */ + /* This lives in Modules/_typesmodule.c */ {"_types", init_types}, /* These entries are here for sys.builtin_module_names */ From python-checkins at python.org Wed Jan 23 23:55:26 2008 From: python-checkins at python.org (kurt.kaiser) Date: Wed, 23 Jan 2008 23:55:26 +0100 (CET) Subject: [Python-checkins] r60227 - python/trunk/Lib/idlelib/NEWS.txt python/trunk/Lib/idlelib/run.py Message-ID: <20080123225526.A84061E4011@bag.python.org> Author: kurt.kaiser Date: Wed Jan 23 23:55:26 2008 New Revision: 60227 Modified: python/trunk/Lib/idlelib/NEWS.txt python/trunk/Lib/idlelib/run.py Log: There was an error on exit if no sys.exitfunc was defined. Issue 1647. Modified: python/trunk/Lib/idlelib/NEWS.txt ============================================================================== --- python/trunk/Lib/idlelib/NEWS.txt (original) +++ python/trunk/Lib/idlelib/NEWS.txt Wed Jan 23 23:55:26 2008 @@ -3,6 +3,8 @@ *Release date: XX-XXX-2008* +- There was an error on exit if no sys.exitfunc was defined. Issue 1647. + - Could not open files in .idlerc directory if latter was hidden on Windows. Issue 1743, Issue 1862. Modified: python/trunk/Lib/idlelib/run.py ============================================================================== --- python/trunk/Lib/idlelib/run.py (original) +++ python/trunk/Lib/idlelib/run.py Wed Jan 23 23:55:26 2008 @@ -206,7 +206,10 @@ """ if no_exitfunc: - del sys.exitfunc + try: + del sys.exitfunc + except AttributeError: + pass sys.exit(0) class MyRPCServer(rpc.RPCServer): From python-checkins at python.org Thu Jan 24 00:23:43 2008 From: python-checkins at python.org (guido.van.rossum) Date: Thu, 24 Jan 2008 00:23:43 +0100 (CET) Subject: [Python-checkins] r60228 - python/trunk/Lib/test/test_descr.py Message-ID: <20080123232343.734C01E400F@bag.python.org> Author: guido.van.rossum Date: Thu Jan 24 00:23:43 2008 New Revision: 60228 Modified: python/trunk/Lib/test/test_descr.py Log: Turn three recently fixed crashers into regular tests. Modified: python/trunk/Lib/test/test_descr.py ============================================================================== --- python/trunk/Lib/test/test_descr.py (original) +++ python/trunk/Lib/test/test_descr.py Thu Jan 24 00:23:43 2008 @@ -1,5 +1,7 @@ # Test enhancements related to descriptors and new-style classes +# XXX Please, please, please, someone convert this to unittest style! + from test.test_support import verify, vereq, verbose, TestFailed, TESTFN, get_original_stdout from copy import deepcopy import warnings @@ -4427,6 +4429,8 @@ # ceval.c's assign_slice used to check for # tp->tp_as_sequence->sq_slice instead of # tp->tp_as_sequence->sq_ass_slice + if verbose: + print "Testing assign_slice..." class C(object): def __setslice__(self, start, stop, value): @@ -4436,8 +4440,70 @@ c[1:2] = 3 vereq(c.value, 3) +def test_weakref_in_del_segfault(): + # This used to segfault until r60057 + if verbose: + print "Testing weakref in del segfault..." + + import weakref + global ref + + class Target(): + def __del__(self): + global ref + ref = weakref.ref(self) + + w = Target() + del w + del ref + +def test_borrowed_ref_3_segfault(): + # This used to segfault until r60224 + if verbose: + print "Testing borrowed ref 3 segfault..." + + class KeyFunc(object): + def __call__(self, n): + del d['key'] + return 1 + + d = {'key': KeyFunc()} + try: + min(range(10), **d) + except: + pass + +def test_borrowed_ref_4_segfault(): + # This used to segfault until r60224 + if verbose: + print "Testing borrowed ref 4 segfault..." + + import types + import __builtin__ + + + class X(object): + def __getattr__(self, name): + # this is called with name == '__bases__' by PyObject_IsInstance() + # during the unbound method call -- it frees the unbound method + # itself before it invokes its im_func. + del __builtin__.__import__ + return () + + pseudoclass = X() + + class Y(object): + def __call__(self, *args): + # 'self' was freed already + return (self, args) + + # make an unbound method + __builtin__.__import__ = types.MethodType(Y(), None, (pseudoclass, str)) + import spam + + def test_main(): - weakref_segfault() # Must be first, somehow + #XXXweakref_segfault() # Must be first, somehow wrapper_segfault() do_this_first() class_docstrings() @@ -4535,6 +4601,9 @@ methodwrapper() notimplemented() test_assign_slice() + test_weakref_in_del_segfault() + test_borrowed_ref_3_segfault() + test_borrowed_ref_4_segfault() if verbose: print "All OK" From python-checkins at python.org Thu Jan 24 01:54:21 2008 From: python-checkins at python.org (raymond.hettinger) Date: Thu, 24 Jan 2008 01:54:21 +0100 (CET) Subject: [Python-checkins] r60229 - in python/trunk/Lib: rational.py test/test_rational.py Message-ID: <20080124005421.73FE61E400F@bag.python.org> Author: raymond.hettinger Date: Thu Jan 24 01:54:21 2008 New Revision: 60229 Modified: python/trunk/Lib/rational.py python/trunk/Lib/test/test_rational.py Log: Add first-cut at an approximation function (still needs rounding tweaks). Add continued fraction conversions. Modified: python/trunk/Lib/rational.py ============================================================================== --- python/trunk/Lib/rational.py (original) +++ python/trunk/Lib/rational.py Thu Jan 24 01:54:21 2008 @@ -172,6 +172,42 @@ else: return cls(digits, 10 ** -exp) + @classmethod + def from_continued_fraction(cls, seq): + 'Build a Rational from a continued fraction expessed as a sequence' + n, d = 1, 0 + for e in reversed(seq): + n, d = d, n + n += e * d + return cls(n, d) + + def as_continued_fraction(self): + 'Return continued fraction expressed as a list' + n = self.numerator + d = self.denominator + cf = [] + while d: + e = int(n // d) + cf.append(e) + n -= e * d + n, d = d, n + return cf + + @classmethod + def approximate_from_float(cls, f, max_denominator): + 'Best rational approximation to f with a denominator <= max_denominator' + # XXX First cut at algorithm + # Still needs rounding rules as specified at + # http://en.wikipedia.org/wiki/Continued_fraction + cf = cls.from_float(f).as_continued_fraction() + result = new = Rational(0, 1) + for i in range(1, len(cf)): + new = cls.from_continued_fraction(cf[:i]) + if new.denominator > max_denominator: + break + result = new + return result + @property def numerator(a): return a._numerator Modified: python/trunk/Lib/test/test_rational.py ============================================================================== --- python/trunk/Lib/test/test_rational.py (original) +++ python/trunk/Lib/test/test_rational.py Thu Jan 24 01:54:21 2008 @@ -135,6 +135,18 @@ TypeError, "Cannot convert sNaN to Rational.", R.from_decimal, Decimal("snan")) + def testFromContinuedFraction(self): + self.assertRaises(TypeError, R.from_continued_fraction, None) + phi = R.from_continued_fraction([1]*100) + self.assertEquals(round(phi - (1 + 5 ** 0.5) / 2, 10), 0.0) + + def testAsContinuedFraction(self): + self.assertEqual(R.from_float(math.pi).as_continued_fraction()[:15], + [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 3, 3]) + + def testApproximateFromFloat(self): + self.assertEqual(R.approximate_from_float(math.pi, 10000), R(355, 113)) + def testConversions(self): self.assertTypedEquals(-1, trunc(R(-11, 10))) self.assertTypedEquals(-2, R(-11, 10).__floor__()) From python-checkins at python.org Thu Jan 24 03:00:25 2008 From: python-checkins at python.org (raymond.hettinger) Date: Thu, 24 Jan 2008 03:00:25 +0100 (CET) Subject: [Python-checkins] r60230 - in python/trunk/Lib: rational.py test/test_rational.py Message-ID: <20080124020025.C54001E400F@bag.python.org> Author: raymond.hettinger Date: Thu Jan 24 03:00:25 2008 New Revision: 60230 Modified: python/trunk/Lib/rational.py python/trunk/Lib/test/test_rational.py Log: Minor clean-up and more tests. Modified: python/trunk/Lib/rational.py ============================================================================== --- python/trunk/Lib/rational.py (original) +++ python/trunk/Lib/rational.py Thu Jan 24 03:00:25 2008 @@ -179,7 +179,9 @@ for e in reversed(seq): n, d = d, n n += e * d - return cls(n, d) + if seq: + return cls(n, d) + return cls(0) def as_continued_fraction(self): 'Return continued fraction expressed as a list' @@ -200,7 +202,7 @@ # Still needs rounding rules as specified at # http://en.wikipedia.org/wiki/Continued_fraction cf = cls.from_float(f).as_continued_fraction() - result = new = Rational(0, 1) + result = Rational(0) for i in range(1, len(cf)): new = cls.from_continued_fraction(cf[:i]) if new.denominator > max_denominator: Modified: python/trunk/Lib/test/test_rational.py ============================================================================== --- python/trunk/Lib/test/test_rational.py (original) +++ python/trunk/Lib/test/test_rational.py Thu Jan 24 03:00:25 2008 @@ -140,12 +140,23 @@ phi = R.from_continued_fraction([1]*100) self.assertEquals(round(phi - (1 + 5 ** 0.5) / 2, 10), 0.0) + minusphi = R.from_continued_fraction([-1]*100) + self.assertEquals(round(minusphi + (1 + 5 ** 0.5) / 2, 10), 0.0) + + self.assertEquals(R.from_continued_fraction([0]), R(0)) + self.assertEquals(R.from_continued_fraction([]), R(0)) + def testAsContinuedFraction(self): self.assertEqual(R.from_float(math.pi).as_continued_fraction()[:15], [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 3, 3]) + self.assertEqual(R.from_float(-math.pi).as_continued_fraction()[:16], + [-4, 1, 6, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 3, 3]) + self.assertEqual(R(0).as_continued_fraction(), [0]) def testApproximateFromFloat(self): self.assertEqual(R.approximate_from_float(math.pi, 10000), R(355, 113)) + self.assertEqual(R.approximate_from_float(-math.pi, 10000), R(-355, 113)) + self.assertEqual(R.approximate_from_float(0.0, 10000), R(0)) def testConversions(self): self.assertTypedEquals(-1, trunc(R(-11, 10))) From python-checkins at python.org Thu Jan 24 03:05:06 2008 From: python-checkins at python.org (raymond.hettinger) Date: Thu, 24 Jan 2008 03:05:06 +0100 (CET) Subject: [Python-checkins] r60231 - python/trunk/Lib/rational.py Message-ID: <20080124020506.9F3DF1E400F@bag.python.org> Author: raymond.hettinger Date: Thu Jan 24 03:05:06 2008 New Revision: 60231 Modified: python/trunk/Lib/rational.py Log: Cleanup Modified: python/trunk/Lib/rational.py ============================================================================== --- python/trunk/Lib/rational.py (original) +++ python/trunk/Lib/rational.py Thu Jan 24 03:05:06 2008 @@ -179,9 +179,7 @@ for e in reversed(seq): n, d = d, n n += e * d - if seq: - return cls(n, d) - return cls(0) + return cls(n, d) if seq else cls(0) def as_continued_fraction(self): 'Return continued fraction expressed as a list' From buildbot at python.org Thu Jan 24 04:54:00 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 24 Jan 2008 03:54:00 +0000 Subject: [Python-checkins] buildbot failure in amd64 gentoo trunk Message-ID: <20080124035401.1C0321E4004@bag.python.org> The Buildbot has detected a new failure of amd64 gentoo trunk. Full details are available at: http://www.python.org/dev/buildbot/all/amd64%20gentoo%20trunk/builds/0 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-amd64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: armin.rigo,christian.heimes,gregory.p.smith,guido.van.rossum,kurt.kaiser,raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "./Lib/test/regrtest.py", line 1211, in main() File "./Lib/test/regrtest.py", line 368, in main huntrleaks) File "./Lib/test/regrtest.py", line 524, in runtest cleanup_test_droppings(test, verbose) File "./Lib/test/regrtest.py", line 619, in cleanup_test_droppings import shutil ImportError: __import__ not found make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Thu Jan 24 05:14:51 2008 From: python-checkins at python.org (neal.norwitz) Date: Thu, 24 Jan 2008 05:14:51 +0100 (CET) Subject: [Python-checkins] r60232 - python/trunk/Lib/test/test_descr.py Message-ID: <20080124041451.3A0BA1E4005@bag.python.org> Author: neal.norwitz Date: Thu Jan 24 05:14:50 2008 New Revision: 60232 Modified: python/trunk/Lib/test/test_descr.py Log: Fix the tests by restoring __import__. I think the test is still valid. Modified: python/trunk/Lib/test/test_descr.py ============================================================================== --- python/trunk/Lib/test/test_descr.py (original) +++ python/trunk/Lib/test/test_descr.py Thu Jan 24 05:14:50 2008 @@ -4481,7 +4481,6 @@ import types import __builtin__ - class X(object): def __getattr__(self, name): # this is called with name == '__bases__' by PyObject_IsInstance() @@ -4498,9 +4497,12 @@ return (self, args) # make an unbound method - __builtin__.__import__ = types.MethodType(Y(), None, (pseudoclass, str)) - import spam - + orig_import = __import__ + try: + __builtin__.__import__ = types.MethodType(Y(), None, (pseudoclass, str)) + import spam + finally: + __builtin__.__import__ = orig_import def test_main(): #XXXweakref_segfault() # Must be first, somehow From buildbot at python.org Thu Jan 24 05:40:15 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 24 Jan 2008 04:40:15 +0000 Subject: [Python-checkins] buildbot failure in amd64 gentoo 3.0 Message-ID: <20080124044015.8E2861E4005@bag.python.org> The Buildbot has detected a new failure of amd64 gentoo 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/amd64%20gentoo%203.0/builds/0 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-amd64 Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes,georg.brandl,raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: 2 tests failed: test_plistlib test_urllib ====================================================================== ERROR: test_appleformatting (test.test_plistlib.TestPlistlib) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/3.0.norwitz-amd64/build/Lib/test/test_plistlib.py", line 140, in test_appleformatting pl = plistlib.readPlistFromBytes(TESTDATA) AttributeError: 'module' object has no attribute 'readPlistFromBytes' ====================================================================== ERROR: test_appleformattingfromliteral (test.test_plistlib.TestPlistlib) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/3.0.norwitz-amd64/build/Lib/test/test_plistlib.py", line 147, in test_appleformattingfromliteral pl2 = plistlib.readPlistFromBytes(TESTDATA) AttributeError: 'module' object has no attribute 'readPlistFromBytes' ====================================================================== ERROR: test_bytes (test.test_plistlib.TestPlistlib) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/3.0.norwitz-amd64/build/Lib/test/test_plistlib.py", line 133, in test_bytes data = plistlib.writePlistToBytes(pl) AttributeError: 'module' object has no attribute 'writePlistToBytes' ====================================================================== ERROR: test_bytesio (test.test_plistlib.TestPlistlib) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/3.0.norwitz-amd64/build/Lib/test/test_plistlib.py", line 155, in test_bytesio plistlib.writePlist(pl, b) File "/home/buildbot/slave/py-build/3.0.norwitz-amd64/build/Lib/plistlib.py", line 91, in writePlist writer = PlistWriter(pathOrFile) File "/home/buildbot/slave/py-build/3.0.norwitz-amd64/build/Lib/plistlib.py", line 230, in __init__ file.write(PLISTHEADER) File "/home/buildbot/slave/py-build/3.0.norwitz-amd64/build/Lib/io.py", line 701, in write raise TypeError("can't write str to binary stream") TypeError: can't write str to binary stream ====================================================================== ERROR: test_controlcharacters (test.test_plistlib.TestPlistlib) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/3.0.norwitz-amd64/build/Lib/test/test_plistlib.py", line 168, in test_controlcharacters plistlib.writePlistToBytes, AttributeError: 'module' object has no attribute 'writePlistToBytes' ====================================================================== ERROR: test_io (test.test_plistlib.TestPlistlib) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/3.0.norwitz-amd64/build/Lib/test/test_plistlib.py", line 127, in test_io plistlib.writePlist(pl, test_support.TESTFN) File "/home/buildbot/slave/py-build/3.0.norwitz-amd64/build/Lib/plistlib.py", line 93, in writePlist writer.writeValue(rootObject) File "/home/buildbot/slave/py-build/3.0.norwitz-amd64/build/Lib/plistlib.py", line 248, in writeValue self.writeDict(value) File "/home/buildbot/slave/py-build/3.0.norwitz-amd64/build/Lib/plistlib.py", line 277, in writeDict self.writeValue(value) File "/home/buildbot/slave/py-build/3.0.norwitz-amd64/build/Lib/plistlib.py", line 254, in writeValue self.writeArray(value) File "/home/buildbot/slave/py-build/3.0.norwitz-amd64/build/Lib/plistlib.py", line 283, in writeArray self.writeValue(value) File "/home/buildbot/slave/py-build/3.0.norwitz-amd64/build/Lib/plistlib.py", line 250, in writeValue self.writeData(value) File "/home/buildbot/slave/py-build/3.0.norwitz-amd64/build/Lib/plistlib.py", line 263, in writeData for line in data.asBase64(maxlinelength).split("\n"): File "/home/buildbot/slave/py-build/3.0.norwitz-amd64/build/Lib/plistlib.py", line 375, in asBase64 return _encodeBase64(self.data, maxlinelength) File "/home/buildbot/slave/py-build/3.0.norwitz-amd64/build/Lib/plistlib.py", line 359, in _encodeBase64 return "".join(pieces) TypeError: sequence item 0: expected str instance, bytes found ====================================================================== ERROR: test_nondictroot (test.test_plistlib.TestPlistlib) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/3.0.norwitz-amd64/build/Lib/test/test_plistlib.py", line 174, in test_nondictroot result1 = plistlib.readPlistFromBytes(plistlib.writePlistToBytes(test1)) AttributeError: 'module' object has no attribute 'readPlistFromBytes' ====================================================================== FAIL: test_read (test.test_urllib.urlopen_HttpTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/3.0.norwitz-amd64/build/Lib/test/test_urllib.py", line 130, in test_read self.assertEqual(fp.getcode(), 200) AssertionError: None != 200 make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Thu Jan 24 08:40:52 2008 From: python-checkins at python.org (neal.norwitz) Date: Thu, 24 Jan 2008 08:40:52 +0100 (CET) Subject: [Python-checkins] r60233 - python/trunk/Lib/urllib2.py Message-ID: <20080124074052.263C81E400F@bag.python.org> Author: neal.norwitz Date: Thu Jan 24 08:40:51 2008 New Revision: 60233 Modified: python/trunk/Lib/urllib2.py Log: Fix the test_urllib2net failures that were caused by r58067. I'm not sure this is the correct fix, but at least the test passes now and should be closer to correct. Modified: python/trunk/Lib/urllib2.py ============================================================================== --- python/trunk/Lib/urllib2.py (original) +++ python/trunk/Lib/urllib2.py Thu Jan 24 08:40:51 2008 @@ -1246,7 +1246,7 @@ import mimetypes host = req.get_host() if not host: - raise URLError, ('ftp error', 'no host given') + raise URLError('ftp error: no host given') host, port = splitport(host) if port is None: port = ftplib.FTP_PORT @@ -1292,7 +1292,7 @@ headers = mimetools.Message(sf) return addinfourl(fp, headers, req.get_full_url()) except ftplib.all_errors, msg: - raise URLError, ('ftp error', msg), sys.exc_info()[2] + raise URLError, ('ftp error: %s' % msg), sys.exc_info()[2] def connect_ftp(self, user, passwd, host, port, dirs, timeout): fw = ftpwrapper(user, passwd, host, port, dirs, timeout) From python-checkins at python.org Thu Jan 24 10:38:27 2008 From: python-checkins at python.org (gregory.p.smith) Date: Thu, 24 Jan 2008 10:38:27 +0100 (CET) Subject: [Python-checkins] r60234 - in python/trunk: Doc/library/struct.rst Doc/tutorial/stdlib2.rst Lib/test/test_largefile.py Message-ID: <20080124093827.16F031E400F@bag.python.org> Author: gregory.p.smith Date: Thu Jan 24 10:38:26 2008 New Revision: 60234 Modified: python/trunk/Doc/library/struct.rst python/trunk/Doc/tutorial/stdlib2.rst python/trunk/Lib/test/test_largefile.py Log: Fix issue1789: The tutorial contained a misuse of the struct module. (also remove an unneeded import struct from test_largefile) Modified: python/trunk/Doc/library/struct.rst ============================================================================== --- python/trunk/Doc/library/struct.rst (original) +++ python/trunk/Doc/library/struct.rst Thu Jan 24 10:38:26 2008 @@ -85,7 +85,7 @@ +--------+-------------------------+--------------------+-------+ | ``i`` | :ctype:`int` | integer | | +--------+-------------------------+--------------------+-------+ -| ``I`` | :ctype:`unsigned int` | long | | +| ``I`` | :ctype:`unsigned int` | integer or long | | +--------+-------------------------+--------------------+-------+ | ``l`` | :ctype:`long` | integer | | +--------+-------------------------+--------------------+-------+ @@ -104,7 +104,7 @@ +--------+-------------------------+--------------------+-------+ | ``p`` | :ctype:`char[]` | string | | +--------+-------------------------+--------------------+-------+ -| ``P`` | :ctype:`void \*` | integer | | +| ``P`` | :ctype:`void \*` | long | | +--------+-------------------------+--------------------+-------+ Notes: Modified: python/trunk/Doc/tutorial/stdlib2.rst ============================================================================== --- python/trunk/Doc/tutorial/stdlib2.rst (original) +++ python/trunk/Doc/tutorial/stdlib2.rst Thu Jan 24 10:38:26 2008 @@ -134,8 +134,10 @@ The :mod:`struct` module provides :func:`pack` and :func:`unpack` functions for working with variable length binary record formats. The following example shows -how to loop through header information in a ZIP file (with pack codes ``"H"`` -and ``"L"`` representing two and four byte unsigned numbers respectively):: +how to loop through header information in a ZIP file without using the +:mod:`zipfile` module. Pack codes ``"H"`` and ``"I"`` represent two and four +byte unsigned numbers respectively. The ``"<"`` indicates that they are +standard size and in little-endian byte order:: import struct @@ -143,7 +145,7 @@ start = 0 for i in range(3): # show the first 3 file headers start += 14 - fields = struct.unpack('LLLHH', data[start:start+16]) + fields = struct.unpack(' test_opcodes leaked [0, -2, 2] references, sum=0 test_doctest leaked [-2, 2, 0] references, sum=0 test_doctest2 leaked [-2, -2, 0] references, sum=-4 test_descrtut leaked [0, 0, -4] references, sum=-4 test_functools leaked [0, 0, -2] references, sum=-2 test_gc leaked [0, 0, -4] references, sum=-4 test_importhooks leaked [-6, 2, 2] references, sum=-2 test_threadsignals leaked [0, -8, 0] references, sum=-8 test_urllib2_localnet leaked [3, 3, 3] references, sum=9 From ncoghlan at gmail.com Thu Jan 24 12:34:25 2008 From: ncoghlan at gmail.com (Nick Coghlan) Date: Thu, 24 Jan 2008 21:34:25 +1000 Subject: [Python-checkins] r60216 - in python/trunk: Lib/encodings/__init__.py Lib/optparse.py Misc/NEWS Parser/tokenizer.c In-Reply-To: <20080123142051.495541E4039@bag.python.org> References: <20080123142051.495541E4039@bag.python.org> Message-ID: <479877C1.5040402@gmail.com> christian.heimes wrote: > Author: christian.heimes > Date: Wed Jan 23 15:20:50 2008 > New Revision: 60216 > > Modified: > python/trunk/Lib/encodings/__init__.py > python/trunk/Lib/optparse.py > python/trunk/Misc/NEWS > python/trunk/Parser/tokenizer.c > Log: > Fixed bug #1915: Python compiles with --enable-unicode=no again. However several extension methods and modules do not work without unicode support. > > Modified: python/trunk/Lib/encodings/__init__.py > ============================================================================== > --- python/trunk/Lib/encodings/__init__.py (original) > +++ python/trunk/Lib/encodings/__init__.py Wed Jan 23 15:20:50 2008 > @@ -30,6 +30,7 @@ > > import codecs > from encodings import aliases > +import __builtin__ > > _cache = {} > _unknown = '--unknown--' > @@ -60,7 +61,7 @@ > """ > # Make sure we have an 8-bit string, because .translate() works > # differently for Unicode strings. > - if isinstance(encoding, unicode): > + if hasattr(__builtin__, "unicode") and isinstance(encoding, unicode): > # Note that .encode('latin-1') does *not* use the codec > # registry, so this call doesn't recurse. (See unicodeobject.c > # PyUnicode_AsEncodedString() for details) > > Modified: python/trunk/Lib/optparse.py > ============================================================================== > --- python/trunk/Lib/optparse.py (original) > +++ python/trunk/Lib/optparse.py Wed Jan 23 15:20:50 2008 > @@ -824,7 +824,11 @@ > (True, False) = (1, 0) > > def isbasestring(x): > - return isinstance(x, types.StringType) or isinstance(x, types.UnicodeType) > + try: > + return isinstance(x, basestring) > + except: > + return isinstance(x, types.StringType) or isinstance(x, types.UnicodeType) > + If this is trying to define isbasestring differently depending on whether or not basestring exists, wouldn't it make more sense to put the def statement inside the try/except statement? Something like: try: basestring def isbasestring(x): return isinstance(x, basestring) except NameError: def isbasestring(x): return (isinstance(x, types.StringType) or isinstance(x, types.UnicodeType)) Cheers, Nick. -- Nick Coghlan | ncoghlan at gmail.com | Brisbane, Australia --------------------------------------------------------------- http://www.boredomandlaziness.org From python-checkins at python.org Thu Jan 24 13:37:09 2008 From: python-checkins at python.org (vinay.sajip) Date: Thu, 24 Jan 2008 13:37:09 +0100 (CET) Subject: [Python-checkins] r60237 - python/trunk/Lib/logging/__init__.py Message-ID: <20080124123709.2CB4A1E400F@bag.python.org> Author: vinay.sajip Date: Thu Jan 24 13:37:08 2008 New Revision: 60237 Modified: python/trunk/Lib/logging/__init__.py Log: Added optional delay argument to FileHandler and subclasses. Modified: python/trunk/Lib/logging/__init__.py ============================================================================== --- python/trunk/Lib/logging/__init__.py (original) +++ python/trunk/Lib/logging/__init__.py Thu Jan 24 13:37:08 2008 @@ -41,8 +41,8 @@ __author__ = "Vinay Sajip " __status__ = "production" -__version__ = "0.5.0.4" -__date__ = "18 January 2008" +__version__ = "0.5.0.5" +__date__ = "24 January 2008" #--------------------------------------------------------------------------- # Miscellaneous module data @@ -763,7 +763,7 @@ """ A handler class which writes formatted logging records to disk files. """ - def __init__(self, filename, mode='a', encoding=None): + def __init__(self, filename, mode='a', encoding=None, delay=0): """ Open the specified file and use it as the stream for logging. """ @@ -774,8 +774,11 @@ self.baseFilename = os.path.abspath(filename) self.mode = mode self.encoding = encoding - stream = self._open() - StreamHandler.__init__(self, stream) + if delay: + self.stream = None + else: + stream = self._open() + StreamHandler.__init__(self, stream) def close(self): """ @@ -798,6 +801,18 @@ stream = codecs.open(self.baseFilename, self.mode, self.encoding) return stream + def emit(self, record): + """ + Emit a record. + + If the stream was not opened because 'delay' was specified in the + constructor, open it before calling the superclass's emit. + """ + if self.stream is None: + stream = self._open() + StreamHandler.__init__(self, stream) + StreamHandler.emit(self, record) + #--------------------------------------------------------------------------- # Manager classes and functions #--------------------------------------------------------------------------- From python-checkins at python.org Thu Jan 24 13:37:33 2008 From: python-checkins at python.org (vinay.sajip) Date: Thu, 24 Jan 2008 13:37:33 +0100 (CET) Subject: [Python-checkins] r60238 - python/trunk/Lib/logging/handlers.py Message-ID: <20080124123733.759591E400F@bag.python.org> Author: vinay.sajip Date: Thu Jan 24 13:37:33 2008 New Revision: 60238 Modified: python/trunk/Lib/logging/handlers.py Log: Added optional delay argument to FileHandler and subclasses. Modified: python/trunk/Lib/logging/handlers.py ============================================================================== --- python/trunk/Lib/logging/handlers.py (original) +++ python/trunk/Lib/logging/handlers.py Thu Jan 24 13:37:33 2008 @@ -53,13 +53,13 @@ Not meant to be instantiated directly. Instead, use RotatingFileHandler or TimedRotatingFileHandler. """ - def __init__(self, filename, mode, encoding=None): + def __init__(self, filename, mode, encoding=None, delay=0): """ Use the specified filename for streamed logging """ if codecs is None: encoding = None - logging.FileHandler.__init__(self, filename, mode, encoding) + logging.FileHandler.__init__(self, filename, mode, encoding, delay) self.mode = mode self.encoding = encoding @@ -84,7 +84,7 @@ Handler for logging to a set of files, which switches from one file to the next when the current file reaches a certain size. """ - def __init__(self, filename, mode='a', maxBytes=0, backupCount=0, encoding=None): + def __init__(self, filename, mode='a', maxBytes=0, backupCount=0, encoding=None, delay=0): """ Open the specified file and use it as the stream for logging. @@ -107,7 +107,7 @@ """ if maxBytes > 0: mode = 'a' # doesn't make sense otherwise! - BaseRotatingHandler.__init__(self, filename, mode, encoding) + BaseRotatingHandler.__init__(self, filename, mode, encoding, delay) self.maxBytes = maxBytes self.backupCount = backupCount @@ -156,8 +156,8 @@ If backupCount is > 0, when rollover is done, no more than backupCount files are kept - the oldest ones are deleted. """ - def __init__(self, filename, when='h', interval=1, backupCount=0, encoding=None): - BaseRotatingHandler.__init__(self, filename, 'a', encoding) + def __init__(self, filename, when='h', interval=1, backupCount=0, encoding=None, delay=0): + BaseRotatingHandler.__init__(self, filename, 'a', encoding, delay) self.when = string.upper(when) self.backupCount = backupCount # Calculate the real rollover interval, which is just the number of @@ -302,10 +302,13 @@ This handler is based on a suggestion and patch by Chad J. Schroeder. """ - def __init__(self, filename, mode='a', encoding=None): - logging.FileHandler.__init__(self, filename, mode, encoding) - stat = os.stat(self.baseFilename) - self.dev, self.ino = stat[ST_DEV], stat[ST_INO] + def __init__(self, filename, mode='a', encoding=None, delay=0): + logging.FileHandler.__init__(self, filename, mode, encoding, delay) + if not os.path.exists(self.baseFilename): + self.dev, self.ino = -1, -1 + else: + stat = os.stat(self.baseFilename) + self.dev, self.ino = stat[ST_DEV], stat[ST_INO] def emit(self, record): """ @@ -321,7 +324,7 @@ else: stat = os.stat(self.baseFilename) changed = (stat[ST_DEV] != self.dev) or (stat[ST_INO] != self.ino) - if changed: + if changed and self.stream is not None: self.stream.flush() self.stream.close() self.stream = self._open() From python-checkins at python.org Thu Jan 24 13:38:31 2008 From: python-checkins at python.org (vinay.sajip) Date: Thu, 24 Jan 2008 13:38:31 +0100 (CET) Subject: [Python-checkins] r60239 - python/trunk/Doc/library/logging.rst Message-ID: <20080124123831.26D691E400F@bag.python.org> Author: vinay.sajip Date: Thu Jan 24 13:38:30 2008 New Revision: 60239 Modified: python/trunk/Doc/library/logging.rst Log: Added documentation for optional delay argument to FileHandler and subclasses. Modified: python/trunk/Doc/library/logging.rst ============================================================================== --- python/trunk/Doc/library/logging.rst (original) +++ python/trunk/Doc/library/logging.rst Thu Jan 24 13:38:30 2008 @@ -1536,12 +1536,13 @@ :class:`StreamHandler`. -.. class:: FileHandler(filename[, mode[, encoding]]) +.. class:: FileHandler(filename[, mode[, encoding[, delay]]]) Returns a new instance of the :class:`FileHandler` class. The specified file is opened and used as the stream for logging. If *mode* is not specified, :const:`'a'` is used. If *encoding* is not *None*, it is used to open the file - with that encoding. By default, the file grows indefinitely. + with that encoding. If *delay* is true, then file opening is deferred until the + first call to :meth:`emit`. By default, the file grows indefinitely. .. method:: FileHandler.close() @@ -1577,12 +1578,13 @@ this value. -.. class:: WatchedFileHandler(filename[,mode[, encoding]]) +.. class:: WatchedFileHandler(filename[,mode[, encoding[, delay]]]) Returns a new instance of the :class:`WatchedFileHandler` class. The specified file is opened and used as the stream for logging. If *mode* is not specified, :const:`'a'` is used. If *encoding* is not *None*, it is used to open the file - with that encoding. By default, the file grows indefinitely. + with that encoding. If *delay* is true, then file opening is deferred until the + first call to :meth:`emit`. By default, the file grows indefinitely. .. method:: WatchedFileHandler.emit(record) @@ -1599,11 +1601,13 @@ module, supports rotation of disk log files. -.. class:: RotatingFileHandler(filename[, mode[, maxBytes[, backupCount]]]) +.. class:: RotatingFileHandler(filename[, mode[, maxBytes[, backupCount[, encoding[, delay]]]]]) Returns a new instance of the :class:`RotatingFileHandler` class. The specified file is opened and used as the stream for logging. If *mode* is not specified, - ``'a'`` is used. By default, the file grows indefinitely. + ``'a'`` is used. If *encoding* is not *None*, it is used to open the file + with that encoding. If *delay* is true, then file opening is deferred until the + first call to :meth:`emit`. By default, the file grows indefinitely. You can use the *maxBytes* and *backupCount* values to allow the file to :dfn:`rollover` at a predetermined size. When the size is about to be exceeded, @@ -1637,7 +1641,7 @@ timed intervals. -.. class:: TimedRotatingFileHandler(filename [,when [,interval [,backupCount]]]) +.. class:: TimedRotatingFileHandler(filename [,when [,interval [,backupCount[, encoding[, delay]]]]]) Returns a new instance of the :class:`TimedRotatingFileHandler` class. The specified file is opened and used as the stream for logging. On rotating it also @@ -2080,7 +2084,13 @@ record is computed using *msg* % *args*. If the formatting string contains ``'(asctime)'``, :meth:`formatTime` is called to format the event time. If there is exception information, it is formatted using :meth:`formatException` and - appended to the message. + appended to the message. Note that the formatted exception information is cached + in attribute *exc_text*. This is useful because the exception information can + be pickled and sent across the wire, but you should be careful if you have more + than one :class:`Formatter` subclass which customizes the formatting of exception + information. In this case, you will have to clear the cached value after a + formatter has done its formatting, so that the next formatter to handle the event + doesn't use the cached value but recalculates it afresh. .. method:: Formatter.formatTime(record[, datefmt]) From python-checkins at python.org Thu Jan 24 13:43:33 2008 From: python-checkins at python.org (vinay.sajip) Date: Thu, 24 Jan 2008 13:43:33 +0100 (CET) Subject: [Python-checkins] r60240 - python/trunk/Misc/NEWS Message-ID: <20080124124333.D31D21E400F@bag.python.org> Author: vinay.sajip Date: Thu Jan 24 13:43:33 2008 New Revision: 60240 Modified: python/trunk/Misc/NEWS Log: Updated for optional delay argument to FileHandler and subclasses. Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Thu Jan 24 13:43:33 2008 @@ -12,7 +12,7 @@ Core and builtins ----------------- -- Issue #1069410: The "can't load dll" message box on Windows is +- Issue #1069410: The "can't load dll" message box on Windows is suppressed while an extension is loaded by calling SetErrorMode in dynload_win.c. The error is still reported properly. @@ -386,6 +386,10 @@ Library ------- +- #1765140: add an optional delay argument to FileHandler and its + subclasses. Defaults to false (existing behaviour), but if true, + defers opening the file until the first call to emit(). + - The pprint module now supports sets and frozensets. - #1221598: add optional callbacks to ftplib.FTP's storbinary() and @@ -1318,6 +1322,9 @@ Documentation ------------- +- RFE #1765140: Updated documentation on FileHandler and subclasses to + include new optional delay argument. + - Bug #932563: Added section on getting contextual information into logging output, and added documentation for the new LoggerAdapter class. From buildbot at python.org Thu Jan 24 13:57:50 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 24 Jan 2008 12:57:50 +0000 Subject: [Python-checkins] buildbot failure in x86 XP-3 2.5 Message-ID: <20080124125750.E1FF41E400F@bag.python.org> The Buildbot has detected a new failure of x86 XP-3 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20XP-3%202.5/builds/161 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: heller-windows Build Reason: The web-page 'rebuild' button was pressed by '': Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_mailbox ====================================================================== ERROR: test_consistent_factory (test.test_mailbox.TestMaildir) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\2.5.heller-windows\build\lib\test\test_mailbox.py", line 522, in test_consistent_factory msg2 = box.get_message(key) File "C:\buildbot\work\2.5.heller-windows\build\lib\mailbox.py", line 315, in get_message subpath = self._lookup(key) File "C:\buildbot\work\2.5.heller-windows\build\lib\mailbox.py", line 484, in _lookup raise KeyError('No message with key: %s' % key) KeyError: 'No message with key: 1201187194.M530999P29224Q203.thomasxpbb' sincerely, -The Buildbot From python-checkins at python.org Thu Jan 24 14:08:55 2008 From: python-checkins at python.org (thomas.heller) Date: Thu, 24 Jan 2008 14:08:55 +0100 (CET) Subject: [Python-checkins] r60241 - in python/branches/release25-maint: Lib/ctypes/test/test_numbers.py Misc/NEWS Modules/_ctypes/cfield.c Message-ID: <20080124130855.AFB9D1E4011@bag.python.org> Author: thomas.heller Date: Thu Jan 24 14:08:54 2008 New Revision: 60241 Modified: python/branches/release25-maint/Lib/ctypes/test/test_numbers.py python/branches/release25-maint/Misc/NEWS python/branches/release25-maint/Modules/_ctypes/cfield.c Log: Invert the checks in get_[u]long and get_[u]longlong. The intent was to not accept float types; the result was that integer-like objects were not accepted. Modified: python/branches/release25-maint/Lib/ctypes/test/test_numbers.py ============================================================================== --- python/branches/release25-maint/Lib/ctypes/test/test_numbers.py (original) +++ python/branches/release25-maint/Lib/ctypes/test/test_numbers.py Thu Jan 24 14:08:54 2008 @@ -90,15 +90,31 @@ def test_floats(self): # c_float and c_double can be created from # Python int, long and float + class FloatLike(object): + def __float__(self): + return 2.0 + f = FloatLike() for t in float_types: self.failUnlessEqual(t(2.0).value, 2.0) self.failUnlessEqual(t(2).value, 2.0) self.failUnlessEqual(t(2L).value, 2.0) + self.failUnlessEqual(t(f).value, 2.0) def test_integers(self): - # integers cannot be constructed from floats + class FloatLike(object): + def __float__(self): + return 2.0 + f = FloatLike() + class IntLike(object): + def __int__(self): + return 2 + i = IntLike() + # integers cannot be constructed from floats, + # but from integer-like objects for t in signed_types + unsigned_types: self.assertRaises(TypeError, t, 3.14) + self.assertRaises(TypeError, t, f) + self.failUnlessEqual(t(i).value, 2) def test_sizes(self): for t in signed_types + unsigned_types + float_types: Modified: python/branches/release25-maint/Misc/NEWS ============================================================================== --- python/branches/release25-maint/Misc/NEWS (original) +++ python/branches/release25-maint/Misc/NEWS Thu Jan 24 14:08:54 2008 @@ -67,6 +67,9 @@ Library ------- +- The ctypes int types did not accept objects implementing + __int__() in the constructor. + - #1189216: Fix the zipfile module to work on archives with headers past the 2**31 byte boundary. Modified: python/branches/release25-maint/Modules/_ctypes/cfield.c ============================================================================== --- python/branches/release25-maint/Modules/_ctypes/cfield.c (original) +++ python/branches/release25-maint/Modules/_ctypes/cfield.c Thu Jan 24 14:08:54 2008 @@ -355,10 +355,9 @@ get_long(PyObject *v, long *p) { long x; - if (!PyInt_Check(v) && !PyLong_Check(v)) { - PyErr_Format(PyExc_TypeError, - "int expected instead of %s instance", - v->ob_type->tp_name); + if (PyFloat_Check(v)) { + PyErr_SetString(PyExc_TypeError, + "int expected instead of float"); return -1; } x = PyInt_AsUnsignedLongMask(v); @@ -374,10 +373,9 @@ get_ulong(PyObject *v, unsigned long *p) { unsigned long x; - if (!PyInt_Check(v) && !PyLong_Check(v)) { - PyErr_Format(PyExc_TypeError, - "int expected instead of %s instance", - v->ob_type->tp_name); + if (PyFloat_Check(v)) { + PyErr_SetString(PyExc_TypeError, + "int expected instead of float"); return -1; } x = PyInt_AsUnsignedLongMask(v); @@ -395,11 +393,10 @@ get_longlong(PyObject *v, PY_LONG_LONG *p) { PY_LONG_LONG x; - if (!PyInt_Check(v) && !PyLong_Check(v)) { - PyErr_Format(PyExc_TypeError, - "int expected instead of %s instance", - v->ob_type->tp_name); - return -1; + if (PyFloat_Check(v)) { + PyErr_SetString(PyExc_TypeError, + "int expected instead of float"); + return -1; } x = PyInt_AsUnsignedLongLongMask(v); if (x == -1 && PyErr_Occurred()) @@ -414,12 +411,11 @@ get_ulonglong(PyObject *v, unsigned PY_LONG_LONG *p) { unsigned PY_LONG_LONG x; - if (!PyInt_Check(v) && !PyLong_Check(v)) { - PyErr_Format(PyExc_TypeError, - "int expected instead of %s instance", - v->ob_type->tp_name); - return -1; - } + if (PyFloat_Check(v)) { + PyErr_SetString(PyExc_TypeError, + "int expected instead of float"); + return -1; + } x = PyInt_AsUnsignedLongLongMask(v); if (x == -1 && PyErr_Occurred()) return -1; From python-checkins at python.org Thu Jan 24 15:08:00 2008 From: python-checkins at python.org (andrew.kuchling) Date: Thu, 24 Jan 2008 15:08:00 +0100 (CET) Subject: [Python-checkins] r60242 - python/branches/release25-maint/Lib/test/test_mailbox.py Message-ID: <20080124140800.E5B7C1E401E@bag.python.org> Author: andrew.kuchling Date: Thu Jan 24 15:08:00 2008 New Revision: 60242 Modified: python/branches/release25-maint/Lib/test/test_mailbox.py Log: Fix failing test_mailbox on Cygwin Modified: python/branches/release25-maint/Lib/test/test_mailbox.py ============================================================================== --- python/branches/release25-maint/Lib/test/test_mailbox.py (original) +++ python/branches/release25-maint/Lib/test/test_mailbox.py Thu Jan 24 15:08:00 2008 @@ -519,6 +519,7 @@ class FakeMessage(mailbox.MaildirMessage): pass box = mailbox.Maildir(self._path, factory=FakeMessage) + box.colon = self._box.colon msg2 = box.get_message(key) self.assert_(isinstance(msg2, FakeMessage)) From python-checkins at python.org Thu Jan 24 16:53:22 2008 From: python-checkins at python.org (guido.van.rossum) Date: Thu, 24 Jan 2008 16:53:22 +0100 (CET) Subject: [Python-checkins] r60243 - python/trunk/Lib/test/test_descr.py Message-ID: <20080124155322.D71EC1E401C@bag.python.org> Author: guido.van.rossum Date: Thu Jan 24 16:53:22 2008 New Revision: 60243 Modified: python/trunk/Lib/test/test_descr.py Log: Fi debug turd -- a call accidentally left out. Modified: python/trunk/Lib/test/test_descr.py ============================================================================== --- python/trunk/Lib/test/test_descr.py (original) +++ python/trunk/Lib/test/test_descr.py Thu Jan 24 16:53:22 2008 @@ -4505,7 +4505,7 @@ __builtin__.__import__ = orig_import def test_main(): - #XXXweakref_segfault() # Must be first, somehow + weakref_segfault() # Must be first, somehow wrapper_segfault() do_this_first() class_docstrings() From python-checkins at python.org Thu Jan 24 17:15:30 2008 From: python-checkins at python.org (christian.heimes) Date: Thu, 24 Jan 2008 17:15:30 +0100 (CET) Subject: [Python-checkins] r60244 - in python/branches/trunk-math: Doc/library/math.rst Lib/test/ieee754.txt Lib/test/test_math.py Modules/mathmodule.c Message-ID: <20080124161530.35F3E1E4027@bag.python.org> Author: christian.heimes Date: Thu Jan 24 17:15:29 2008 New Revision: 60244 Added: python/branches/trunk-math/Lib/test/ieee754.txt (contents, props changed) Modified: python/branches/trunk-math/Doc/library/math.rst python/branches/trunk-math/Lib/test/test_math.py python/branches/trunk-math/Modules/mathmodule.c Log: Return 0.0 for 0.0**x iff x element R+0, nan for x == nan and raise an exception for x < 0 Added doc test for IEEE 754 invariants Modified: python/branches/trunk-math/Doc/library/math.rst ============================================================================== --- python/branches/trunk-math/Doc/library/math.rst (original) +++ python/branches/trunk-math/Doc/library/math.rst Thu Jan 24 17:15:29 2008 @@ -148,10 +148,10 @@ .. function:: pow(x, y) Return ``x**y``. ``1.0**y`` returns *1.0*, even for ``1.0**nan``. ``0**y`` - returns *0.* for all positive *y* and *0*. + returns *0.* for all positive *y*, *0* and *NAN*. .. versionchanged:: 2.6 - The outcome of 1**nan was undefined. + The outcome of ``1**nan`` and ``0**nan`` was undefined. .. function:: sqrt(x) Added: python/branches/trunk-math/Lib/test/ieee754.txt ============================================================================== --- (empty file) +++ python/branches/trunk-math/Lib/test/ieee754.txt Thu Jan 24 17:15:29 2008 @@ -0,0 +1,158 @@ +====================================== +Python IEEE 754 floating point support +====================================== + +>>> from sys import float_info as FI +>>> from math import * +>>> PI = pi +>>> E = e + +You must never compare two floats with == because you are not going to get +what you expect. We treat two floats as equal if the difference between them +is small than epsilon. +>>> EPS = 1E-15 +>>> def equal(x, y): +... """Almost equal helper for floats""" +... return abs(x - y) < EPS + + +NaNs and INFs +============= + +In Python 2.6 and newer NaNs (not a number) and infinity can be constructed +from the strings 'inf' and 'nan'. + +>>> INF = float('inf') +>>> NINF = float('-inf') +>>> NAN = float('nan') + +>>> INF +inf +>>> NINF +-inf +>>> NAN +nan + +The math module's ``isnan`` and ``isinf`` functions can be used to detect INF +and NAN: +>>> isinf(INF), isinf(NINF), isnan(NAN) +(True, True, True) +>>> INF == -NINF +True + +Infinity +-------- + +Ambiguous operations like ``0 * inf`` or ``inf - inf`` result in NaN. +>>> INF * 0 +nan +>>> INF - INF +nan +>>> INF / INF +nan + +However unambigous operations with inf return inf: +>>> INF * INF +inf +>>> 1.5 * INF +inf +>>> 0.5 * INF +inf +>>> INF / 1000 +inf + +Not a Number +------------ + +NaNs are never equal to another number, even itself +>>> NAN == NAN +False +>>> NAN < 0 +False +>>> NAN >= 0 +False + +All operations involving a NaN return a NaN except for the power of *0* and *1*. +>>> 1 + NAN +nan +>>> 1 * NAN +nan +>>> 0 * NAN +nan +>>> 1 ** NAN +1.0 +>>> 0 ** NAN +0.0 +>>> (1.0 + FI.epsilon) * NAN +nan + +Misc Functions +============== + +The power of 1 raised to x is always 1.0, even for special values like 0, +infinity and NaN. + +>>> pow(1, 0) +1.0 +>>> pow(1, INF) +1.0 +>>> pow(1, -INF) +1.0 +>>> pow(1, NAN) +1.0 + +The power of 0 raised to x is defined as 0, iff x is zero or positive. Negative +values are a domain error or zero division error and NaN result in a silent NaN. + +>>> pow(0, 0) +0.0 +>>> pow(0, INF) +0.0 +>>> pow(0, -INF) +Traceback (most recent call last): +... +ValueError: math domain error +>>> 0 ** -1 +Traceback (most recent call last): +... +ZeroDivisionError: 0.0 cannot be raised to a negative power +>>> pow(0, NAN) +nan + + +Trigonometric Functions +======================= + +>>> sin(INF), sin(NINF), sin(NAN) +(nan, nan, nan) +>>> cos(INF), cos(NINF), cos(NAN) +(nan, nan, nan) +>>> tan(INF), tan(NINF), tan(NAN) +(nan, nan, nan) + +Neither pi nor tan are exact, but you can assume that tan(pi/2) is a large value +and tan(pi) is a very small value: +>>> tan(PI/2) > 1E10 +True +>>> -tan(-PI/2) > 1E10 +True +>>> tan(PI) < 1E-15 +True + +>>> asin(NAN), acos(NAN), atan(NAN) +(nan, nan, nan) +>>> asin(INF), asin(NINF) +Traceback (most recent call last): +... +ValueError: math domain error +>>> acos(INF), acos(NINF) +Traceback (most recent call last): +... +ValueError: math domain error +>>> equal(atan(INF), PI/2), equal(atan(NINF), -PI/2) +(True, True) + + +Hyberbolic Functions +==================== + Modified: python/branches/trunk-math/Lib/test/test_math.py ============================================================================== --- python/branches/trunk-math/Lib/test/test_math.py (original) +++ python/branches/trunk-math/Lib/test/test_math.py Thu Jan 24 17:15:29 2008 @@ -17,8 +17,8 @@ file = sys.argv[0] else: file = __file__ -testdir = os.path.dirname(file) or os.curdir -test_file = os.path.join(testdir, 'cmath.ctest') +test_dir = os.path.dirname(file) or os.curdir +test_file = os.path.join(test_dir, 'cmath.ctest') def parse_testfile(fname): """Parse a file with test values @@ -463,7 +463,11 @@ self.ftest("%s:%s(%r)" % (id, fn, ar), result, er) def test_main(): - run_unittest(MathTests) + from doctest import DocFileSuite + suite = unittest.TestSuite() + suite.addTest(unittest.makeSuite(MathTests)) + suite.addTest(DocFileSuite("ieee754.txt")) + run_unittest(suite) if __name__ == '__main__': test_main() Modified: python/branches/trunk-math/Modules/mathmodule.c ============================================================================== --- python/branches/trunk-math/Modules/mathmodule.c (original) +++ python/branches/trunk-math/Modules/mathmodule.c Thu Jan 24 17:15:29 2008 @@ -329,14 +329,14 @@ if (x == 1.0) return PyFloat_FromDouble(1.); if (x == 0.0) { - if (y >= 0.0) + if (y >= 0.0 || Py_IS_NAN(y)) return PyFloat_FromDouble(0.); - if (Py_IS_NAN(y)) - return PyFloat_FromDouble(Py_NAN); - /* 0 raise to a negative value */ - errno = EDOM; - is_error(x); - return NULL; + else { + /* 0 raise to a negative value */ + errno = EDOM; + is_error(x); + return NULL; + } } #ifndef __GNUC__ /* Windows et al */ if (Py_IS_NAN(x) || Py_IS_NAN(y)) From python-checkins at python.org Thu Jan 24 18:58:06 2008 From: python-checkins at python.org (guido.van.rossum) Date: Thu, 24 Jan 2008 18:58:06 +0100 (CET) Subject: [Python-checkins] r60246 - in python/trunk: Lib/test/crashers/loosing_dict_ref.py Lib/test/test_descr.py Objects/object.c Message-ID: <20080124175806.5657B1E4021@bag.python.org> Author: guido.van.rossum Date: Thu Jan 24 18:58:05 2008 New Revision: 60246 Removed: python/trunk/Lib/test/crashers/loosing_dict_ref.py Modified: python/trunk/Lib/test/test_descr.py python/trunk/Objects/object.c Log: Fix test67.py from issue #1303614. Deleted: /python/trunk/Lib/test/crashers/loosing_dict_ref.py ============================================================================== --- /python/trunk/Lib/test/crashers/loosing_dict_ref.py Thu Jan 24 18:58:05 2008 +++ (empty file) @@ -1,21 +0,0 @@ - -# http://python.org/sf/1303614 - -class Strange(object): - def __hash__(self): - return hash('hello') - - def __eq__(self, other): - x.__dict__ = {} # the old x.__dict__ is deallocated - return False - - -class X(object): - pass - -if __name__ == '__main__': - v = 123 - x = X() - x.__dict__ = {Strange(): 42, - 'hello': v+456} - x.hello # segfault: the above dict is accessed after it's deallocated Modified: python/trunk/Lib/test/test_descr.py ============================================================================== --- python/trunk/Lib/test/test_descr.py (original) +++ python/trunk/Lib/test/test_descr.py Thu Jan 24 18:58:05 2008 @@ -4504,6 +4504,29 @@ finally: __builtin__.__import__ = orig_import +def test_losing_dict_ref_segfault(): + # This used to segfault; + # derived from issue #1303614, test67.py + if verbose: + print "Testing losing dict ref segfault..." + + class Strange(object): + def __hash__(self): + return hash('hello') + + def __eq__(self, other): + x.__dict__ = {} # the old x.__dict__ is deallocated + return False + + class X(object): + pass + + v = 123 + x = X() + x.__dict__ = {Strange(): 42, 'hello': v+456} + x.hello + + def test_main(): weakref_segfault() # Must be first, somehow wrapper_segfault() @@ -4606,6 +4629,7 @@ test_weakref_in_del_segfault() test_borrowed_ref_3_segfault() test_borrowed_ref_4_segfault() + test_losing_dict_ref_segfault() if verbose: print "All OK" Modified: python/trunk/Objects/object.c ============================================================================== --- python/trunk/Objects/object.c (original) +++ python/trunk/Objects/object.c Thu Jan 24 18:58:05 2008 @@ -1349,12 +1349,15 @@ dictptr = (PyObject **) ((char *)obj + dictoffset); dict = *dictptr; if (dict != NULL) { + Py_INCREF(dict); res = PyDict_GetItem(dict, name); if (res != NULL) { Py_INCREF(res); Py_XDECREF(descr); + Py_DECREF(dict); goto done; } + Py_DECREF(dict); } } @@ -1435,12 +1438,14 @@ *dictptr = dict; } if (dict != NULL) { + Py_INCREF(dict); if (value == NULL) res = PyDict_DelItem(dict, name); else res = PyDict_SetItem(dict, name, value); if (res < 0 && PyErr_ExceptionMatches(PyExc_KeyError)) PyErr_SetObject(PyExc_AttributeError, name); + Py_DECREF(dict); goto done; } } From python-checkins at python.org Thu Jan 24 18:59:56 2008 From: python-checkins at python.org (guido.van.rossum) Date: Thu, 24 Jan 2008 18:59:56 +0100 (CET) Subject: [Python-checkins] r60247 - python/branches/release25-maint/Objects/object.c Message-ID: <20080124175956.C36081E4016@bag.python.org> Author: guido.van.rossum Date: Thu Jan 24 18:59:56 2008 New Revision: 60247 Modified: python/branches/release25-maint/Objects/object.c Log: Backport r60246. Fix issue #1303614, test67.py. Modified: python/branches/release25-maint/Objects/object.c ============================================================================== --- python/branches/release25-maint/Objects/object.c (original) +++ python/branches/release25-maint/Objects/object.c Thu Jan 24 18:59:56 2008 @@ -1335,12 +1335,15 @@ dictptr = (PyObject **) ((char *)obj + dictoffset); dict = *dictptr; if (dict != NULL) { + Py_INCREF(dict); res = PyDict_GetItem(dict, name); if (res != NULL) { Py_INCREF(res); Py_XDECREF(descr); + Py_DECREF(dict); goto done; } + Py_DECREF(dict); } } @@ -1421,12 +1424,14 @@ *dictptr = dict; } if (dict != NULL) { + Py_INCREF(dict); if (value == NULL) res = PyDict_DelItem(dict, name); else res = PyDict_SetItem(dict, name, value); if (res < 0 && PyErr_ExceptionMatches(PyExc_KeyError)) PyErr_SetObject(PyExc_AttributeError, name); + Py_DECREF(dict); goto done; } } From python-checkins at python.org Thu Jan 24 19:05:54 2008 From: python-checkins at python.org (raymond.hettinger) Date: Thu, 24 Jan 2008 19:05:54 +0100 (CET) Subject: [Python-checkins] r60248 - python/trunk/Lib/rational.py Message-ID: <20080124180554.5950B1E4013@bag.python.org> Author: raymond.hettinger Date: Thu Jan 24 19:05:54 2008 New Revision: 60248 Modified: python/trunk/Lib/rational.py Log: Clean-up and speed-up code by accessing numerator/denominator directly. There's no reason to enforce readonliness Modified: python/trunk/Lib/rational.py ============================================================================== --- python/trunk/Lib/rational.py (original) +++ python/trunk/Lib/rational.py Thu Jan 24 19:05:54 2008 @@ -94,7 +94,7 @@ """ - __slots__ = ('_numerator', '_denominator') + __slots__ = ('numerator', 'denominator') # We're immutable, so use __new__ not __init__ def __new__(cls, numerator=0, denominator=1): @@ -134,8 +134,8 @@ raise ZeroDivisionError('Rational(%s, 0)' % numerator) g = _gcd(numerator, denominator) - self._numerator = int(numerator // g) - self._denominator = int(denominator // g) + self.numerator = int(numerator // g) + self.denominator = int(denominator // g) return self @classmethod @@ -208,14 +208,6 @@ result = new return result - @property - def numerator(a): - return a._numerator - - @property - def denominator(a): - return a._denominator - def __repr__(self): """repr(self)""" return ('Rational(%r,%r)' % (self.numerator, self.denominator)) From guido at python.org Thu Jan 24 19:09:52 2008 From: guido at python.org (Guido van Rossum) Date: Thu, 24 Jan 2008 10:09:52 -0800 Subject: [Python-checkins] r60216 - in python/trunk: Lib/encodings/__init__.py Lib/optparse.py Misc/NEWS Parser/tokenizer.c In-Reply-To: <479877C1.5040402@gmail.com> References: <20080123142051.495541E4039@bag.python.org> <479877C1.5040402@gmail.com> Message-ID: On Jan 24, 2008 3:34 AM, Nick Coghlan wrote: > If this is trying to define isbasestring differently depending on > whether or not basestring exists, wouldn't it make more sense to put the > def statement inside the try/except statement? Something like: > > try: > basestring > def isbasestring(x): > return isinstance(x, basestring) > except NameError: > def isbasestring(x): > return (isinstance(x, types.StringType) > or isinstance(x, types.UnicodeType)) Well, the first 'def' should be moved into the else clause of course. -- --Guido van Rossum (home page: http://www.python.org/~guido/) From python-checkins at python.org Thu Jan 24 19:12:24 2008 From: python-checkins at python.org (raymond.hettinger) Date: Thu, 24 Jan 2008 19:12:24 +0100 (CET) Subject: [Python-checkins] r60249 - python/trunk/Lib/threading.py Message-ID: <20080124181224.3E9281E4013@bag.python.org> Author: raymond.hettinger Date: Thu Jan 24 19:12:23 2008 New Revision: 60249 Modified: python/trunk/Lib/threading.py Log: Revert 60189 and restore performance. Modified: python/trunk/Lib/threading.py ============================================================================== --- python/trunk/Lib/threading.py (original) +++ python/trunk/Lib/threading.py Thu Jan 24 19:12:23 2008 @@ -347,18 +347,27 @@ return self.__flag def set(self): - with self.__cond: + self.__cond.acquire() + try: self.__flag = True self.__cond.notifyAll() + finally: + self.__cond.release() def clear(self): - with self.__cond: + self.__cond.acquire() + try: self.__flag = False + finally: + self.__cond.release() def wait(self, timeout=None): - with self.__cond: + self.__cond.acquire() + try: if not self.__flag: self.__cond.wait(timeout) + finally: + self.__cond.release() # Helper to generate new thread names _counter = 0 @@ -525,9 +534,10 @@ pass def __stop(self): - with self.__block: - self.__stopped = True - self.__block.notifyAll() + self.__block.acquire() + self.__stopped = True + self.__block.notifyAll() + self.__block.release() def __delete(self): "Remove current thread from the dict of currently running threads." @@ -553,12 +563,15 @@ # since it isn't if dummy_threading is *not* being used then don't # hide the exception. - with _active_limbo_lock: + _active_limbo_lock.acquire() + try: try: del _active[_get_ident()] except KeyError: if 'dummy_threading' not in _sys.modules: raise + finally: + _active_limbo_lock.release() def join(self, timeout=None): if not self.__initialized: @@ -571,7 +584,8 @@ if __debug__: if not self.__stopped: self._note("%s.join(): waiting until thread stops", self) - with self.__block: + self.__block.acquire() + try: if timeout is None: while not self.__stopped: self.__block.wait() @@ -589,6 +603,8 @@ else: if __debug__: self._note("%s.join(): thread stopped", self) + finally: + self.__block.release() def getName(self): assert self.__initialized, "Thread.__init__() not called" From python-checkins at python.org Thu Jan 24 19:21:02 2008 From: python-checkins at python.org (guido.van.rossum) Date: Thu, 24 Jan 2008 19:21:02 +0100 (CET) Subject: [Python-checkins] r60250 - python/trunk/Misc/NEWS Message-ID: <20080124182102.BDD221E4013@bag.python.org> Author: guido.van.rossum Date: Thu Jan 24 19:21:02 2008 New Revision: 60250 Modified: python/trunk/Misc/NEWS Log: News about recently fixed crashers: - A few crashers fixed: weakref_in_del.py (issue #1377858); loosing_dict_ref.py (issue #1303614, test67.py); borrowed_ref_[34].py (not in tracker). Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Thu Jan 24 19:21:02 2008 @@ -12,6 +12,10 @@ Core and builtins ----------------- +- A few crashers fixed: weakref_in_del.py (issue #1377858); + loosing_dict_ref.py (issue #1303614, test67.py); + borrowed_ref_[34].py (not in tracker). + - Issue #1069410: The "can't load dll" message box on Windows is suppressed while an extension is loaded by calling SetErrorMode in dynload_win.c. The error is still reported properly. From python-checkins at python.org Thu Jan 24 19:28:37 2008 From: python-checkins at python.org (guido.van.rossum) Date: Thu, 24 Jan 2008 19:28:37 +0100 (CET) Subject: [Python-checkins] r60251 - python/branches/release25-maint/Misc/NEWS Message-ID: <20080124182837.9A7311E4013@bag.python.org> Author: guido.van.rossum Date: Thu Jan 24 19:28:37 2008 New Revision: 60251 Modified: python/branches/release25-maint/Misc/NEWS Log: News for some crashers I fixed recently. Also removed three non-ASCII chars at start of file. Modified: python/branches/release25-maint/Misc/NEWS ============================================================================== --- python/branches/release25-maint/Misc/NEWS (original) +++ python/branches/release25-maint/Misc/NEWS Thu Jan 24 19:28:37 2008 @@ -1,4 +1,4 @@ -?+++++++++++ ++++++++++++ Python News +++++++++++ @@ -12,6 +12,14 @@ Core and builtins ----------------- +- A few crashers fixed: weakref_in_del.py (issue #1377858); + loosing_dict_ref.py (issue #1303614, test67.py); + borrowed_ref_[34].py (not in tracker). + +- Fix for #1303614 and #1174712 backported from the trunk: + __dict__ descriptor abuse for subclasses of built-in types; + subclassing from both ModuleType and another built-in types. + - Bug #1915: Python compiles with --enable-unicode=no again. However several extension methods and modules do not work without unicode support. From python-checkins at python.org Thu Jan 24 19:36:27 2008 From: python-checkins at python.org (thomas.heller) Date: Thu, 24 Jan 2008 19:36:27 +0100 (CET) Subject: [Python-checkins] r60252 - python/trunk/Modules/_ctypes/_ctypes.c Message-ID: <20080124183627.A5C2C1E401E@bag.python.org> Author: thomas.heller Date: Thu Jan 24 19:36:27 2008 New Revision: 60252 Modified: python/trunk/Modules/_ctypes/_ctypes.c Log: Use a PyDictObject again for the array type cache; retrieving items from the WeakValueDictionary was slower by nearly a factor of 3. To avoid leaks, weakref proxies for the array types are put into the cache dict, with weakref callbacks that removes the entries when the type goes away. Modified: python/trunk/Modules/_ctypes/_ctypes.c ============================================================================== --- python/trunk/Modules/_ctypes/_ctypes.c (original) +++ python/trunk/Modules/_ctypes/_ctypes.c Thu Jan 24 19:36:27 2008 @@ -127,12 +127,134 @@ PyObject *PyExc_ArgError; static PyTypeObject Simple_Type; -PyObject *array_types_cache; char *conversion_mode_encoding = NULL; char *conversion_mode_errors = NULL; +/****************************************************************/ + +typedef struct { + PyObject_HEAD + PyObject *key; + PyObject *dict; +} DictRemoverObject; + +static void +_DictRemover_dealloc(PyObject *_self) +{ + DictRemoverObject *self = (DictRemoverObject *)_self; + Py_XDECREF(self->key); + Py_XDECREF(self->dict); + Py_TYPE(self)->tp_free(_self); +} + +static PyObject * +_DictRemover_call(PyObject *_self, PyObject *args, PyObject *kw) +{ + DictRemoverObject *self = (DictRemoverObject *)_self; + if (self->key && self->dict) { + if (-1 == PyDict_DelItem(self->dict, self->key)) + /* XXX Error context */ + PyErr_WriteUnraisable(Py_None); + Py_DECREF(self->key); + self->key = NULL; + Py_DECREF(self->dict); + self->dict = NULL; + } + Py_INCREF(Py_None); + return Py_None; +} + +static PyTypeObject DictRemover_Type = { + PyVarObject_HEAD_INIT(NULL, 0) + "_ctypes.DictRemover", /* tp_name */ + sizeof(DictRemoverObject), /* tp_basicsize */ + 0, /* tp_itemsize */ + _DictRemover_dealloc, /* tp_dealloc */ + 0, /* tp_print */ + 0, /* tp_getattr */ + 0, /* tp_setattr */ + 0, /* tp_compare */ + 0, /* tp_repr */ + 0, /* tp_as_number */ + 0, /* tp_as_sequence */ + 0, /* tp_as_mapping */ + 0, /* tp_hash */ + _DictRemover_call, /* tp_call */ + 0, /* tp_str */ + 0, /* tp_getattro */ + 0, /* tp_setattro */ + 0, /* tp_as_buffer */ +/* XXX should participate in GC? */ + Py_TPFLAGS_DEFAULT, /* tp_flags */ + "deletes a key from a dictionary", /* tp_doc */ + 0, /* tp_traverse */ + 0, /* tp_clear */ + 0, /* tp_richcompare */ + 0, /* tp_weaklistoffset */ + 0, /* tp_iter */ + 0, /* tp_iternext */ + 0, /* tp_methods */ + 0, /* tp_members */ + 0, /* tp_getset */ + 0, /* tp_base */ + 0, /* tp_dict */ + 0, /* tp_descr_get */ + 0, /* tp_descr_set */ + 0, /* tp_dictoffset */ + 0, /* tp_init */ + 0, /* tp_alloc */ + PyType_GenericNew, /* tp_new */ + 0, /* tp_free */ +}; + +int +PyDict_SetItemProxy(PyObject *dict, PyObject *key, PyObject *item) +{ + PyObject *obj; + DictRemoverObject *remover; + PyObject *proxy; + int result; + + obj = PyObject_CallObject((PyObject *)&DictRemover_Type, NULL); + if (obj == NULL) + return -1; + + remover = (DictRemoverObject *)obj; + assert(remover->key == NULL); + assert(remover->dict == NULL); + Py_INCREF(key); + remover->key = key; + Py_INCREF(dict); + remover->dict = dict; + + proxy = PyWeakref_NewProxy(item, obj); + Py_DECREF(obj); + if (proxy == NULL) + return -1; + + result = PyDict_SetItem(dict, key, proxy); + Py_DECREF(proxy); + return result; +} + +PyObject * +PyDict_GetItemProxy(PyObject *dict, PyObject *key) +{ + PyObject *result; + PyObject *item = PyDict_GetItem(dict, key); + + if (item == NULL) + return NULL; + if (!PyWeakref_CheckProxy(item)) + return item; + result = PyWeakref_GET_OBJECT(item); + if (result == Py_None) + return NULL; + return result; +} + /******************************************************************/ /* StructType_Type - a meta type/class. Creating a new class using this one as @@ -4102,10 +4224,16 @@ PyObject * CreateArrayType(PyObject *itemtype, Py_ssize_t length) { + static PyObject *cache; PyObject *key; PyObject *result; char name[256]; + if (cache == NULL) { + cache = PyDict_New(); + if (cache == NULL) + return NULL; + } #if (PY_VERSION_HEX < 0x02050000) key = Py_BuildValue("(Oi)", itemtype, length); #else @@ -4113,12 +4241,12 @@ #endif if (!key) return NULL; - result = PyObject_GetItem(array_types_cache, key); + result = PyDict_GetItemProxy(cache, key); if (result) { + Py_INCREF(result); Py_DECREF(key); return result; - } else - PyErr_Clear(); + } if (!PyType_Check(itemtype)) { PyErr_SetString(PyExc_TypeError, @@ -4148,7 +4276,7 @@ ); if (!result) return NULL; - if (-1 == PyObject_SetItem(array_types_cache, key, result)) { + if (-1 == PyDict_SetItemProxy(cache, key, result)) { Py_DECREF(key); Py_DECREF(result); return NULL; @@ -4965,7 +5093,6 @@ init_ctypes(void) { PyObject *m; - PyObject *weakref; /* Note: ob_type is the metatype (the 'type'), defaults to PyType_Type, @@ -4978,16 +5105,6 @@ if (!m) return; - weakref = PyImport_ImportModule("weakref"); - if (weakref == NULL) - return; - array_types_cache = PyObject_CallMethod(weakref, - "WeakValueDictionary", - NULL); - if (array_types_cache == NULL) - return; - Py_DECREF(weakref); - if (PyType_Ready(&PyCArg_Type) < 0) return; @@ -5083,6 +5200,10 @@ * Other stuff */ + DictRemover_Type.tp_new = PyType_GenericNew; + if (PyType_Ready(&DictRemover_Type) < 0) + return; + #ifdef MS_WIN32 if (create_comerror() < 0) return; From python-checkins at python.org Thu Jan 24 19:54:12 2008 From: python-checkins at python.org (thomas.heller) Date: Thu, 24 Jan 2008 19:54:12 +0100 (CET) Subject: [Python-checkins] r60253 - python/trunk/Modules/_ctypes/_ctypes.c Message-ID: <20080124185412.5FB051E4013@bag.python.org> Author: thomas.heller Date: Thu Jan 24 19:54:12 2008 New Revision: 60253 Modified: python/trunk/Modules/_ctypes/_ctypes.c Log: Replace Py_BuildValue with PyTuple_Pack because it is faster. Also add a missing DECREF. Modified: python/trunk/Modules/_ctypes/_ctypes.c ============================================================================== --- python/trunk/Modules/_ctypes/_ctypes.c (original) +++ python/trunk/Modules/_ctypes/_ctypes.c Thu Jan 24 19:54:12 2008 @@ -2523,7 +2523,7 @@ only it's object list. So we create a tuple, containing b_objects list PLUS the array itself, and return that! */ - return Py_BuildValue("(OO)", keep, value); + return PyTuple_Pack(2, keep, value); } PyErr_Format(PyExc_TypeError, "incompatible types, %s instance instead of %s instance", @@ -4228,17 +4228,18 @@ PyObject *key; PyObject *result; char name[256]; + PyObject *len; if (cache == NULL) { cache = PyDict_New(); if (cache == NULL) return NULL; } -#if (PY_VERSION_HEX < 0x02050000) - key = Py_BuildValue("(Oi)", itemtype, length); -#else - key = Py_BuildValue("(On)", itemtype, length); -#endif + len = PyInt_FromSsize_t(length); + if (len == NULL) + return NULL; + key = PyTuple_Pack(2, itemtype, len); + Py_DECREF(len); if (!key) return NULL; result = PyDict_GetItemProxy(cache, key); @@ -4274,8 +4275,10 @@ "_type_", itemtype ); - if (!result) + if (result == NULL) { + Py_DECREF(key); return NULL; + } if (-1 == PyDict_SetItemProxy(cache, key, result)) { Py_DECREF(key); Py_DECREF(result); From python-checkins at python.org Thu Jan 24 20:05:29 2008 From: python-checkins at python.org (raymond.hettinger) Date: Thu, 24 Jan 2008 20:05:29 +0100 (CET) Subject: [Python-checkins] r60254 - in python/trunk/Lib: decimal.py test/test_decimal.py Message-ID: <20080124190529.DC6951E4014@bag.python.org> Author: raymond.hettinger Date: Thu Jan 24 20:05:29 2008 New Revision: 60254 Modified: python/trunk/Lib/decimal.py python/trunk/Lib/test/test_decimal.py Log: Add support for trunc(). Modified: python/trunk/Lib/decimal.py ============================================================================== --- python/trunk/Lib/decimal.py (original) +++ python/trunk/Lib/decimal.py Thu Jan 24 20:05:29 2008 @@ -1433,6 +1433,8 @@ else: return s*int(self._int[:self._exp] or '0') + __trunc__ = __int__ + def __long__(self): """Converts to a long. Modified: python/trunk/Lib/test/test_decimal.py ============================================================================== --- python/trunk/Lib/test/test_decimal.py (original) +++ python/trunk/Lib/test/test_decimal.py Thu Jan 24 20:05:29 2008 @@ -1151,6 +1151,7 @@ checkSameDec("__floordiv__", True) checkSameDec("__hash__") checkSameDec("__int__") + checkSameDec("__trunc__") checkSameDec("__long__") checkSameDec("__mod__", True) checkSameDec("__mul__", True) @@ -1216,6 +1217,16 @@ r = d.to_integral(ROUND_DOWN) self.assertEqual(Decimal(int(d)), r) + def test_trunc(self): + for x in range(-250, 250): + s = '%0.2f' % (x / 100.0) + # should work the same as for floats + self.assertEqual(int(Decimal(s)), int(float(s))) + # should work the same as to_integral in the ROUND_DOWN mode + d = Decimal(s) + r = d.to_integral(ROUND_DOWN) + self.assertEqual(Decimal(trunc(d)), r) + class ContextAPItests(unittest.TestCase): def test_pickle(self): From python-checkins at python.org Thu Jan 24 20:15:03 2008 From: python-checkins at python.org (thomas.heller) Date: Thu, 24 Jan 2008 20:15:03 +0100 (CET) Subject: [Python-checkins] r60255 - in python/trunk: Lib/ctypes/test/test_numbers.py Modules/_ctypes/cfield.c Message-ID: <20080124191503.29B151E4023@bag.python.org> Author: thomas.heller Date: Thu Jan 24 20:15:02 2008 New Revision: 60255 Modified: python/trunk/Lib/ctypes/test/test_numbers.py python/trunk/Modules/_ctypes/cfield.c Log: Invert the checks in get_[u]long and get_[u]longlong. The intent was to not accept float types; the result was that integer-like objects were not accepted. Ported from release25-maint. Modified: python/trunk/Lib/ctypes/test/test_numbers.py ============================================================================== --- python/trunk/Lib/ctypes/test/test_numbers.py (original) +++ python/trunk/Lib/ctypes/test/test_numbers.py Thu Jan 24 20:15:02 2008 @@ -105,15 +105,31 @@ def test_floats(self): # c_float and c_double can be created from # Python int, long and float + class FloatLike(object): + def __float__(self): + return 2.0 + f = FloatLike() for t in float_types: self.failUnlessEqual(t(2.0).value, 2.0) self.failUnlessEqual(t(2).value, 2.0) self.failUnlessEqual(t(2L).value, 2.0) + self.failUnlessEqual(t(f).value, 2.0) def test_integers(self): - # integers cannot be constructed from floats + class FloatLike(object): + def __float__(self): + return 2.0 + f = FloatLike() + class IntLike(object): + def __int__(self): + return 2 + i = IntLike() + # integers cannot be constructed from floats, + # but from integer-like objects for t in signed_types + unsigned_types: self.assertRaises(TypeError, t, 3.14) + self.assertRaises(TypeError, t, f) + self.failUnlessEqual(t(i).value, 2) def test_sizes(self): for t in signed_types + unsigned_types + float_types + bool_types: Modified: python/trunk/Modules/_ctypes/cfield.c ============================================================================== --- python/trunk/Modules/_ctypes/cfield.c (original) +++ python/trunk/Modules/_ctypes/cfield.c Thu Jan 24 20:15:02 2008 @@ -346,10 +346,9 @@ get_long(PyObject *v, long *p) { long x; - if (!PyInt_Check(v) && !PyLong_Check(v)) { - PyErr_Format(PyExc_TypeError, - "int expected instead of %s instance", - v->ob_type->tp_name); + if (PyFloat_Check(v)) { + PyErr_SetString(PyExc_TypeError, + "int expected instead of float"); return -1; } x = PyInt_AsUnsignedLongMask(v); @@ -365,10 +364,9 @@ get_ulong(PyObject *v, unsigned long *p) { unsigned long x; - if (!PyInt_Check(v) && !PyLong_Check(v)) { - PyErr_Format(PyExc_TypeError, - "int expected instead of %s instance", - v->ob_type->tp_name); + if (PyFloat_Check(v)) { + PyErr_SetString(PyExc_TypeError, + "int expected instead of float"); return -1; } x = PyInt_AsUnsignedLongMask(v); @@ -386,11 +384,10 @@ get_longlong(PyObject *v, PY_LONG_LONG *p) { PY_LONG_LONG x; - if (!PyInt_Check(v) && !PyLong_Check(v)) { - PyErr_Format(PyExc_TypeError, - "int expected instead of %s instance", - v->ob_type->tp_name); - return -1; + if (PyFloat_Check(v)) { + PyErr_SetString(PyExc_TypeError, + "int expected instead of float"); + return -1; } x = PyInt_AsUnsignedLongLongMask(v); if (x == -1 && PyErr_Occurred()) @@ -405,12 +402,11 @@ get_ulonglong(PyObject *v, unsigned PY_LONG_LONG *p) { unsigned PY_LONG_LONG x; - if (!PyInt_Check(v) && !PyLong_Check(v)) { - PyErr_Format(PyExc_TypeError, - "int expected instead of %s instance", - v->ob_type->tp_name); - return -1; - } + if (PyFloat_Check(v)) { + PyErr_SetString(PyExc_TypeError, + "int expected instead of float"); + return -1; + } x = PyInt_AsUnsignedLongLongMask(v); if (x == -1 && PyErr_Occurred()) return -1; From buildbot at python.org Thu Jan 24 20:15:07 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 24 Jan 2008 19:15:07 +0000 Subject: [Python-checkins] buildbot failure in amd64 gentoo trunk Message-ID: <20080124191507.E8C6F1E4032@bag.python.org> The Buildbot has detected a new failure of amd64 gentoo trunk. Full details are available at: http://www.python.org/dev/buildbot/all/amd64%20gentoo%20trunk/builds/7 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-amd64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30995, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30995, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30995, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_thread.py", line 260, in writerThread self.assertEqual(data, self.makeData(key)) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/unittest.py", line 343, in failUnlessEqual (msg or '%r != %r' % (first, second)) AssertionError: None != '1001-1001-1001-1001-1001' Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_thread.py", line 260, in writerThread self.assertEqual(data, self.makeData(key)) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/unittest.py", line 343, in failUnlessEqual (msg or '%r != %r' % (first, second)) AssertionError: None != '2000-2000-2000-2000-2000' Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_thread.py", line 260, in writerThread self.assertEqual(data, self.makeData(key)) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/unittest.py", line 343, in failUnlessEqual (msg or '%r != %r' % (first, second)) AssertionError: None != '0002-0002-0002-0002-0002' 1 test failed: test_urllib2net make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Thu Jan 24 20:30:19 2008 From: python-checkins at python.org (raymond.hettinger) Date: Thu, 24 Jan 2008 20:30:19 +0100 (CET) Subject: [Python-checkins] r60256 - in python/trunk/Lib: rational.py test/test_rational.py Message-ID: <20080124193019.9BD561E4013@bag.python.org> Author: raymond.hettinger Date: Thu Jan 24 20:30:19 2008 New Revision: 60256 Modified: python/trunk/Lib/rational.py python/trunk/Lib/test/test_rational.py Log: Add support for int(r) just like the other numeric classes. Modified: python/trunk/Lib/rational.py ============================================================================== --- python/trunk/Lib/rational.py (original) +++ python/trunk/Lib/rational.py Thu Jan 24 20:30:19 2008 @@ -376,6 +376,8 @@ else: return a.numerator // a.denominator + __int__ = __trunc__ + def __floor__(a): """Will be math.floor(a) in 3.0.""" return a.numerator // a.denominator Modified: python/trunk/Lib/test/test_rational.py ============================================================================== --- python/trunk/Lib/test/test_rational.py (original) +++ python/trunk/Lib/test/test_rational.py Thu Jan 24 20:30:19 2008 @@ -160,6 +160,7 @@ def testConversions(self): self.assertTypedEquals(-1, trunc(R(-11, 10))) + self.assertTypedEquals(-1, int(R(-11, 10))) self.assertTypedEquals(-2, R(-11, 10).__floor__()) self.assertTypedEquals(-1, R(-11, 10).__ceil__()) self.assertTypedEquals(-1, R(-10, 10).__ceil__()) From brett at python.org Thu Jan 24 20:38:52 2008 From: brett at python.org (Brett Cannon) Date: Thu, 24 Jan 2008 11:38:52 -0800 Subject: [Python-checkins] r60249 - python/trunk/Lib/threading.py In-Reply-To: <20080124181224.3E9281E4013@bag.python.org> References: <20080124181224.3E9281E4013@bag.python.org> Message-ID: How bad was the performance hit? The code is so much cleaner with the context managers. -Brett On Jan 24, 2008 10:12 AM, raymond.hettinger wrote: > Author: raymond.hettinger > Date: Thu Jan 24 19:12:23 2008 > New Revision: 60249 > > Modified: > python/trunk/Lib/threading.py > Log: > Revert 60189 and restore performance. > > Modified: python/trunk/Lib/threading.py > ============================================================================== > --- python/trunk/Lib/threading.py (original) > +++ python/trunk/Lib/threading.py Thu Jan 24 19:12:23 2008 > @@ -347,18 +347,27 @@ > return self.__flag > > def set(self): > - with self.__cond: > + self.__cond.acquire() > + try: > self.__flag = True > self.__cond.notifyAll() > + finally: > + self.__cond.release() > > def clear(self): > - with self.__cond: > + self.__cond.acquire() > + try: > self.__flag = False > + finally: > + self.__cond.release() > > def wait(self, timeout=None): > - with self.__cond: > + self.__cond.acquire() > + try: > if not self.__flag: > self.__cond.wait(timeout) > + finally: > + self.__cond.release() > > # Helper to generate new thread names > _counter = 0 > @@ -525,9 +534,10 @@ > pass > > def __stop(self): > - with self.__block: > - self.__stopped = True > - self.__block.notifyAll() > + self.__block.acquire() > + self.__stopped = True > + self.__block.notifyAll() > + self.__block.release() > > def __delete(self): > "Remove current thread from the dict of currently running threads." > @@ -553,12 +563,15 @@ > # since it isn't if dummy_threading is *not* being used then don't > # hide the exception. > > - with _active_limbo_lock: > + _active_limbo_lock.acquire() > + try: > try: > del _active[_get_ident()] > except KeyError: > if 'dummy_threading' not in _sys.modules: > raise > + finally: > + _active_limbo_lock.release() > > def join(self, timeout=None): > if not self.__initialized: > @@ -571,7 +584,8 @@ > if __debug__: > if not self.__stopped: > self._note("%s.join(): waiting until thread stops", self) > - with self.__block: > + self.__block.acquire() > + try: > if timeout is None: > while not self.__stopped: > self.__block.wait() > @@ -589,6 +603,8 @@ > else: > if __debug__: > self._note("%s.join(): thread stopped", self) > + finally: > + self.__block.release() > > def getName(self): > assert self.__initialized, "Thread.__init__() not called" > _______________________________________________ > Python-checkins mailing list > Python-checkins at python.org > http://mail.python.org/mailman/listinfo/python-checkins > From buildbot at python.org Thu Jan 24 20:43:43 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 24 Jan 2008 19:43:43 +0000 Subject: [Python-checkins] buildbot failure in x86 gentoo trunk Message-ID: <20080124194343.D18CD1E4017@bag.python.org> The Buildbot has detected a new failure of x86 gentoo trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20gentoo%20trunk/builds/2935 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-x86 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: guido.van.rossum,thomas.heller BUILD FAILED: failed test Excerpt from the test logfile: sincerely, -The Buildbot From nnorwitz at gmail.com Thu Jan 24 22:12:01 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Thu, 24 Jan 2008 13:12:01 -0800 Subject: [Python-checkins] r60216 - in python/trunk: Lib/encodings/__init__.py Lib/optparse.py Misc/NEWS Parser/tokenizer.c In-Reply-To: <479877C1.5040402@gmail.com> References: <20080123142051.495541E4039@bag.python.org> <479877C1.5040402@gmail.com> Message-ID: On Jan 24, 2008 3:34 AM, Nick Coghlan wrote: > > christian.heimes wrote: > > Author: christian.heimes > > Date: Wed Jan 23 15:20:50 2008 > > New Revision: 60216 > > > > Modified: > > python/trunk/Lib/encodings/__init__.py > > python/trunk/Lib/optparse.py > > python/trunk/Misc/NEWS > > python/trunk/Parser/tokenizer.c > > Log: > > Fixed bug #1915: Python compiles with --enable-unicode=no again. However several extension methods and modules do not work without unicode support. > > > > Modified: python/trunk/Lib/encodings/__init__.py > > ============================================================================== > > --- python/trunk/Lib/encodings/__init__.py (original) > > +++ python/trunk/Lib/encodings/__init__.py Wed Jan 23 15:20:50 2008 > > @@ -30,6 +30,7 @@ > > > > import codecs > > from encodings import aliases > > +import __builtin__ > > > > _cache = {} > > _unknown = '--unknown--' > > @@ -60,7 +61,7 @@ > > """ > > # Make sure we have an 8-bit string, because .translate() works > > # differently for Unicode strings. > > - if isinstance(encoding, unicode): > > + if hasattr(__builtin__, "unicode") and isinstance(encoding, unicode): > > # Note that .encode('latin-1') does *not* use the codec > > # registry, so this call doesn't recurse. (See unicodeobject.c > > # PyUnicode_AsEncodedString() for details) > > > > Modified: python/trunk/Lib/optparse.py > > ============================================================================== > > --- python/trunk/Lib/optparse.py (original) > > +++ python/trunk/Lib/optparse.py Wed Jan 23 15:20:50 2008 > > @@ -824,7 +824,11 @@ > > (True, False) = (1, 0) > > > > def isbasestring(x): > > - return isinstance(x, types.StringType) or isinstance(x, types.UnicodeType) > > + try: > > + return isinstance(x, basestring) > > + except: > > + return isinstance(x, types.StringType) or isinstance(x, types.UnicodeType) > > + > > If this is trying to define isbasestring differently depending on > whether or not basestring exists, wouldn't it make more sense to put the > def statement inside the try/except statement? Something like: > > try: > basestring > def isbasestring(x): > return isinstance(x, basestring) > except NameError: > def isbasestring(x): > return (isinstance(x, types.StringType) > or isinstance(x, types.UnicodeType)) isinstance(x, (str, unicode)) works just fine too. or isinstance(x, types.StringTypes) n From python-checkins at python.org Thu Jan 24 22:24:14 2008 From: python-checkins at python.org (raymond.hettinger) Date: Thu, 24 Jan 2008 22:24:14 +0100 (CET) Subject: [Python-checkins] r60263 - python/trunk/Lib/test/test_set.py Message-ID: <20080124212414.03EF81E4013@bag.python.org> Author: raymond.hettinger Date: Thu Jan 24 22:23:58 2008 New Revision: 60263 Modified: python/trunk/Lib/test/test_set.py Log: Expand tests to include nested graph structures. Modified: python/trunk/Lib/test/test_set.py ============================================================================== --- python/trunk/Lib/test/test_set.py (original) +++ python/trunk/Lib/test/test_set.py Thu Jan 24 22:23:58 2008 @@ -7,6 +7,7 @@ import os from random import randrange, shuffle import sys +import collections class PassThru(Exception): pass @@ -1525,6 +1526,110 @@ self.assertRaises(TypeError, getattr(set('january'), methname), N(data)) self.assertRaises(ZeroDivisionError, getattr(set('january'), methname), E(data)) +# Application tests (based on David Eppstein's graph recipes ==================================== + +def powerset(U): + """Generates all subsets of a set or sequence U.""" + U = iter(U) + try: + x = frozenset([U.next()]) + for S in powerset(U): + yield S + yield S | x + except StopIteration: + yield frozenset() + +def cube(n): + """Graph of n-dimensional hypercube.""" + singletons = [frozenset([x]) for x in range(n)] + return dict([(x, frozenset([x^s for s in singletons])) + for x in powerset(range(n))]) + +def linegraph(G): + """Graph, the vertices of which are edges of G, + with two vertices being adjacent iff the corresponding + edges share a vertex.""" + L = {} + for x in G: + for y in G[x]: + nx = [frozenset([x,z]) for z in G[x] if z != y] + ny = [frozenset([y,z]) for z in G[y] if z != x] + L[frozenset([x,y])] = frozenset(nx+ny) + return L + +def faces(G): + 'Return a set of faces in G. Where a face is a set of vertices on that face' + # currently limited to triangles,squares, and pentagons + f = set() + for v1, edges in G.items(): + for v2 in edges: + for v3 in G[v2]: + if v1 == v3: + continue + if v1 in G[v3]: + f.add(frozenset([v1, v2, v3])) + else: + for v4 in G[v3]: + if v4 == v2: + continue + if v1 in G[v4]: + f.add(frozenset([v1, v2, v3, v4])) + else: + for v5 in G[v4]: + if v5 == v3 or v5 == v2: + continue + if v1 in G[v5]: + f.add(frozenset([v1, v2, v3, v4, v5])) + return f + + +class TestGraphs(unittest.TestCase): + + def test_cube(self): + + g = cube(3) # vert --> {v1, v2, v3} + vertices1 = set(g) + self.assertEqual(len(vertices1), 8) # eight vertices + for edge in g.values(): + self.assertEqual(len(edge), 3) # each vertex connects to three edges + vertices2 = set(v for edges in g.values() for v in edges) + self.assertEqual(vertices1, vertices2) # edge vertices in original set + + cubefaces = faces(g) + self.assertEqual(len(cubefaces), 6) # six faces + for face in cubefaces: + self.assertEqual(len(face), 4) # each face is a square + + def test_cuboctahedron(self): + + # http://en.wikipedia.org/wiki/Cuboctahedron + # 8 triangular faces and 6 square faces + # 12 indentical vertices each connecting a triangle and square + + g = cube(3) + cuboctahedron = linegraph(g) # V( --> {V1, V2, V3, V4} + self.assertEqual(len(cuboctahedron), 12)# twelve vertices + + vertices = set(cuboctahedron) + for edges in cuboctahedron.values(): + self.assertEqual(len(edges), 4) # each vertex connects to four other vertices + othervertices = set(edge for edges in cuboctahedron.values() for edge in edges) + self.assertEqual(vertices, othervertices) # edge vertices in original set + + cubofaces = faces(cuboctahedron) + facesizes = collections.defaultdict(int) + for face in cubofaces: + facesizes[len(face)] += 1 + self.assertEqual(facesizes[3], 8) # eight triangular faces + self.assertEqual(facesizes[4], 6) # six square faces + + for vertex in cuboctahedron: + edge = vertex # Cuboctahedron vertices are edges in Cube + self.assertEqual(len(edge), 2) # Two cube vertices define an edge + for cubevert in edge: + self.assert_(cubevert in g) + + #============================================================================== def test_main(verbose=None): @@ -1562,6 +1667,7 @@ TestCopyingNested, TestIdentities, TestVariousIteratorArgs, + TestGraphs, ) test_support.run_unittest(*test_classes) From lists at cheimes.de Thu Jan 24 22:36:27 2008 From: lists at cheimes.de (Christian Heimes) Date: Thu, 24 Jan 2008 22:36:27 +0100 Subject: [Python-checkins] r60216 - in python/trunk: Lib/encodings/__init__.py Lib/optparse.py Misc/NEWS Parser/tokenizer.c In-Reply-To: References: <20080123142051.495541E4039@bag.python.org> <479877C1.5040402@gmail.com> Message-ID: Neal Norwitz wrote: > isinstance(x, (str, unicode)) works just fine too. or > isinstance(x, types.StringTypes) isinstance(x, (str, unicode)) does not work when Python is build with --enable-unicode=no. I could simplify the code with isinstance(x, basestring) but it won't be b/w with older releases of Python. From nnorwitz at gmail.com Thu Jan 24 22:45:04 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Thu, 24 Jan 2008 13:45:04 -0800 Subject: [Python-checkins] r60216 - in python/trunk: Lib/encodings/__init__.py Lib/optparse.py Misc/NEWS Parser/tokenizer.c In-Reply-To: References: <20080123142051.495541E4039@bag.python.org> <479877C1.5040402@gmail.com> Message-ID: On Jan 24, 2008 1:36 PM, Christian Heimes wrote: > Neal Norwitz wrote: > > isinstance(x, (str, unicode)) works just fine too. or > > isinstance(x, types.StringTypes) > > isinstance(x, (str, unicode)) does not work when Python is build with > --enable-unicode=no. I could simplify the code with isinstance(x, I was assuming you would do the full transformation. I really just wanted to point out that you can use a tuple rather than call isinstance twice. > basestring) but it won't be b/w with older releases of Python. I didn't check how old this code needs to work with. Hmm, actually optparse is maintained outside of python. See this comment at the top: # Python developers: please do not make changes to this file, since # it is automatically generated from the Optik source code. It hassn't changed very often though. n From python-checkins at python.org Thu Jan 24 22:47:56 2008 From: python-checkins at python.org (raymond.hettinger) Date: Thu, 24 Jan 2008 22:47:56 +0100 (CET) Subject: [Python-checkins] r60264 - in python/trunk/Lib: pprint.py test/test_pprint.py Message-ID: <20080124214756.60F531E4013@bag.python.org> Author: raymond.hettinger Date: Thu Jan 24 22:47:56 2008 New Revision: 60264 Modified: python/trunk/Lib/pprint.py python/trunk/Lib/test/test_pprint.py Log: Shorter pprint's for empty sets and frozensets. Fix indentation of frozensets. Add tests including two complex data structures. Modified: python/trunk/Lib/pprint.py ============================================================================== --- python/trunk/Lib/pprint.py (original) +++ python/trunk/Lib/pprint.py Thu Jan 24 22:47:56 2008 @@ -167,25 +167,31 @@ (issubclass(typ, set) and r is set.__repr__) or (issubclass(typ, frozenset) and r is frozenset.__repr__) ): + length = _len(object) if issubclass(typ, list): write('[') endchar = ']' elif issubclass(typ, set): + if not length: + write('set()') + return write('set([') endchar = '])' object = sorted(object) indent += 4 elif issubclass(typ, frozenset): + if not length: + write('frozenset()') + return write('frozenset([') endchar = '])' object = sorted(object) - indent += 9 + indent += 10 else: write('(') endchar = ')' if self._indent_per_level > 1: write((self._indent_per_level - 1) * ' ') - length = _len(object) if length: context[objid] = 1 indent = indent + self._indent_per_level Modified: python/trunk/Lib/test/test_pprint.py ============================================================================== --- python/trunk/Lib/test/test_pprint.py (original) +++ python/trunk/Lib/test/test_pprint.py Thu Jan 24 22:47:56 2008 @@ -1,6 +1,7 @@ import pprint import test.test_support import unittest +import test.test_set try: uni = unicode @@ -195,6 +196,197 @@ others.should.not.be: like.this}""" self.assertEqual(DottedPrettyPrinter().pformat(o), exp) + def test_set_reprs(self): + self.assertEqual(pprint.pformat(set()), 'set()') + self.assertEqual(pprint.pformat(set(range(3))), 'set([0, 1, 2])') + self.assertEqual(pprint.pformat(frozenset()), 'frozenset()') + self.assertEqual(pprint.pformat(frozenset(range(3))), 'frozenset([0, 1, 2])') + cube_repr_tgt = """\ +{frozenset([]): frozenset([frozenset([2]), frozenset([0]), frozenset([1])]), + frozenset([0]): frozenset([frozenset(), + frozenset([0, 2]), + frozenset([0, 1])]), + frozenset([1]): frozenset([frozenset(), + frozenset([1, 2]), + frozenset([0, 1])]), + frozenset([2]): frozenset([frozenset(), + frozenset([1, 2]), + frozenset([0, 2])]), + frozenset([1, 2]): frozenset([frozenset([2]), + frozenset([1]), + frozenset([0, 1, 2])]), + frozenset([0, 2]): frozenset([frozenset([2]), + frozenset([0]), + frozenset([0, 1, 2])]), + frozenset([0, 1]): frozenset([frozenset([0]), + frozenset([1]), + frozenset([0, 1, 2])]), + frozenset([0, 1, 2]): frozenset([frozenset([1, 2]), + frozenset([0, 2]), + frozenset([0, 1])])}""" + cube = test.test_set.cube(3) + self.assertEqual(pprint.pformat(cube), cube_repr_tgt) + cubo_repr_tgt = """\ +{frozenset([frozenset([0, 2]), frozenset([0])]): frozenset([frozenset([frozenset([0, + 2]), + frozenset([0, + 1, + 2])]), + frozenset([frozenset([0]), + frozenset([0, + 1])]), + frozenset([frozenset(), + frozenset([0])]), + frozenset([frozenset([2]), + frozenset([0, + 2])])]), + frozenset([frozenset([0, 1]), frozenset([1])]): frozenset([frozenset([frozenset([0, + 1]), + frozenset([0, + 1, + 2])]), + frozenset([frozenset([0]), + frozenset([0, + 1])]), + frozenset([frozenset([1]), + frozenset([1, + 2])]), + frozenset([frozenset(), + frozenset([1])])]), + frozenset([frozenset([1, 2]), frozenset([1])]): frozenset([frozenset([frozenset([1, + 2]), + frozenset([0, + 1, + 2])]), + frozenset([frozenset([2]), + frozenset([1, + 2])]), + frozenset([frozenset(), + frozenset([1])]), + frozenset([frozenset([1]), + frozenset([0, + 1])])]), + frozenset([frozenset([1, 2]), frozenset([2])]): frozenset([frozenset([frozenset([1, + 2]), + frozenset([0, + 1, + 2])]), + frozenset([frozenset([1]), + frozenset([1, + 2])]), + frozenset([frozenset([2]), + frozenset([0, + 2])]), + frozenset([frozenset(), + frozenset([2])])]), + frozenset([frozenset([]), frozenset([0])]): frozenset([frozenset([frozenset([0]), + frozenset([0, + 1])]), + frozenset([frozenset([0]), + frozenset([0, + 2])]), + frozenset([frozenset(), + frozenset([1])]), + frozenset([frozenset(), + frozenset([2])])]), + frozenset([frozenset([]), frozenset([1])]): frozenset([frozenset([frozenset(), + frozenset([0])]), + frozenset([frozenset([1]), + frozenset([1, + 2])]), + frozenset([frozenset(), + frozenset([2])]), + frozenset([frozenset([1]), + frozenset([0, + 1])])]), + frozenset([frozenset([2]), frozenset([])]): frozenset([frozenset([frozenset([2]), + frozenset([1, + 2])]), + frozenset([frozenset(), + frozenset([0])]), + frozenset([frozenset(), + frozenset([1])]), + frozenset([frozenset([2]), + frozenset([0, + 2])])]), + frozenset([frozenset([0, 1, 2]), frozenset([0, 1])]): frozenset([frozenset([frozenset([1, + 2]), + frozenset([0, + 1, + 2])]), + frozenset([frozenset([0, + 2]), + frozenset([0, + 1, + 2])]), + frozenset([frozenset([0]), + frozenset([0, + 1])]), + frozenset([frozenset([1]), + frozenset([0, + 1])])]), + frozenset([frozenset([0]), frozenset([0, 1])]): frozenset([frozenset([frozenset(), + frozenset([0])]), + frozenset([frozenset([0, + 1]), + frozenset([0, + 1, + 2])]), + frozenset([frozenset([0]), + frozenset([0, + 2])]), + frozenset([frozenset([1]), + frozenset([0, + 1])])]), + frozenset([frozenset([2]), frozenset([0, 2])]): frozenset([frozenset([frozenset([0, + 2]), + frozenset([0, + 1, + 2])]), + frozenset([frozenset([2]), + frozenset([1, + 2])]), + frozenset([frozenset([0]), + frozenset([0, + 2])]), + frozenset([frozenset(), + frozenset([2])])]), + frozenset([frozenset([0, 1, 2]), frozenset([0, 2])]): frozenset([frozenset([frozenset([1, + 2]), + frozenset([0, + 1, + 2])]), + frozenset([frozenset([0, + 1]), + frozenset([0, + 1, + 2])]), + frozenset([frozenset([0]), + frozenset([0, + 2])]), + frozenset([frozenset([2]), + frozenset([0, + 2])])]), + frozenset([frozenset([1, 2]), frozenset([0, 1, 2])]): frozenset([frozenset([frozenset([0, + 2]), + frozenset([0, + 1, + 2])]), + frozenset([frozenset([0, + 1]), + frozenset([0, + 1, + 2])]), + frozenset([frozenset([2]), + frozenset([1, + 2])]), + frozenset([frozenset([1]), + frozenset([1, + 2])])])}""" + + cubo = test.test_set.linegraph(cube) + self.assertEqual(pprint.pformat(cubo), cubo_repr_tgt) + class DottedPrettyPrinter(pprint.PrettyPrinter): From buildbot at python.org Thu Jan 24 22:53:52 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 24 Jan 2008 21:53:52 +0000 Subject: [Python-checkins] buildbot failure in x86 gentoo trunk Message-ID: <20080124215352.2E1491E4013@bag.python.org> The Buildbot has detected a new failure of x86 gentoo trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20gentoo%20trunk/builds/2937 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-x86 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_xmlrpc make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python at rcn.com Thu Jan 24 22:59:19 2008 From: python at rcn.com (Raymond Hettinger) Date: Thu, 24 Jan 2008 16:59:19 -0500 (EST) Subject: [Python-checkins] r60249 - python/trunk/Lib/threading.py Message-ID: <20080124165919.AFQ88215@ms19.lnh.mail.rcn.net> > How bad was the performance hit? Depends on how you measure it (the whole method, the try/finally part, the call to the lock, etc). The with-statement has try/finally logic embedded but adds a few steps. The threading module is a core building block and needs to be as fast as it can (with the try/finally logic remaining in-line). > The code is so much cleaner with the context managers. Sort of yes, sort of no. This code has been much exercised and is stable. It would not be hard to destabilize it and introduce hard-to-find bugs. Also, at Guido's behest, I plan to rewrite this module in C at some point -- that will be a bit easier with the in-lined try/finally logic still in place. Also, it is not immediately clear to me that all of the changes were semantically neutral (those in the __stop and __delete methods). Raymond From buildbot at python.org Thu Jan 24 23:04:53 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 24 Jan 2008 22:04:53 +0000 Subject: [Python-checkins] buildbot failure in amd64 gentoo trunk Message-ID: <20080124220453.4677C1E4017@bag.python.org> The Buildbot has detected a new failure of amd64 gentoo trunk. Full details are available at: http://www.python.org/dev/buildbot/all/amd64%20gentoo%20trunk/builds/10 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-amd64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_urllib2net make: *** [buildbottest] Error 1 sincerely, -The Buildbot From nnorwitz at gmail.com Thu Jan 24 23:36:39 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Thu, 24 Jan 2008 17:36:39 -0500 Subject: [Python-checkins] Python Regression Test Failures refleak (6) Message-ID: <20080124223639.GA18066@python.psfb.org> test_opcodes leaked [0, -2, 2] references, sum=0 test_doctest leaked [-2, 2, 0] references, sum=0 test_doctest2 leaked [-2, -2, 0] references, sum=-4 test_difflib leaked [-2, -2, 0] references, sum=-4 test_dummy_threading leaked [0, 0, -2] references, sum=-2 test_gc leaked [-2, 2, -4] references, sum=-4 test_generators leaked [0, -2, 2] references, sum=0 test_importhooks leaked [-2, 2, -6] references, sum=-6 test_platform leaked [0, 0, -2] references, sum=-2 test_threadsignals leaked [0, 0, -8] references, sum=-8 test_urllib2_localnet leaked [-107, 123, -117] references, sum=-101 test_weakref leaked [-2, 2, 0] references, sum=0 From python-checkins at python.org Thu Jan 24 23:51:22 2008 From: python-checkins at python.org (amaury.forgeotdarc) Date: Thu, 24 Jan 2008 23:51:22 +0100 (CET) Subject: [Python-checkins] r60265 - in python/trunk: Lib/test/test_grammar.py Python/compile.c Message-ID: <20080124225122.9D30B1E4018@bag.python.org> Author: amaury.forgeotdarc Date: Thu Jan 24 23:51:18 2008 New Revision: 60265 Modified: python/trunk/Lib/test/test_grammar.py python/trunk/Python/compile.c Log: #1920: when considering a block starting by "while 0", the compiler optimized the whole construct away, even when an 'else' clause is present:: while 0: print("no") else: print("yes") did not generate any code at all. Now the compiler emits the 'else' block, like it already does for 'if' statements. Will backport. Modified: python/trunk/Lib/test/test_grammar.py ============================================================================== --- python/trunk/Lib/test/test_grammar.py (original) +++ python/trunk/Lib/test/test_grammar.py Thu Jan 24 23:51:18 2008 @@ -572,6 +572,15 @@ while 0: pass else: pass + # Issue1920: "while 0" is optimized away, + # ensure that the "else" clause is still present. + x = 0 + while 0: + x = 1 + else: + x = 2 + self.assertEquals(x, 2) + def testFor(self): # 'for' exprlist 'in' exprlist ':' suite ['else' ':' suite] for i in 1, 2, 3: pass Modified: python/trunk/Python/compile.c ============================================================================== --- python/trunk/Python/compile.c (original) +++ python/trunk/Python/compile.c Thu Jan 24 23:51:18 2008 @@ -1598,8 +1598,11 @@ basicblock *loop, *orelse, *end, *anchor = NULL; int constant = expr_constant(s->v.While.test); - if (constant == 0) + if (constant == 0) { + if (s->v.While.orelse) + VISIT_SEQ(c, stmt, s->v.While.orelse); return 1; + } loop = compiler_new_block(c); end = compiler_new_block(c); if (constant == -1) { From python-checkins at python.org Thu Jan 24 23:59:26 2008 From: python-checkins at python.org (amaury.forgeotdarc) Date: Thu, 24 Jan 2008 23:59:26 +0100 (CET) Subject: [Python-checkins] r60266 - python/trunk/Misc/NEWS Message-ID: <20080124225926.2E32B1E400F@bag.python.org> Author: amaury.forgeotdarc Date: Thu Jan 24 23:59:25 2008 New Revision: 60266 Modified: python/trunk/Misc/NEWS Log: News entry for r60265 (Issue 1920). Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Thu Jan 24 23:59:25 2008 @@ -1,4 +1,4 @@ -+++++++++++ +?+++++++++++ Python News +++++++++++ @@ -12,6 +12,11 @@ Core and builtins ----------------- +- Issue #1920: "while 0" statements were completely removed by the compiler, + even in the presence of an "else" clause, which is supposed to be run when + the condition is false. Now the compiler correctly emits bytecode for the + "else" suite. + - A few crashers fixed: weakref_in_del.py (issue #1377858); loosing_dict_ref.py (issue #1303614, test67.py); borrowed_ref_[34].py (not in tracker). From nnorwitz at gmail.com Fri Jan 25 00:01:16 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Thu, 24 Jan 2008 15:01:16 -0800 Subject: [Python-checkins] r60265 - in python/trunk: Lib/test/test_grammar.py Python/compile.c In-Reply-To: <20080124225122.9D30B1E4018@bag.python.org> References: <20080124225122.9D30B1E4018@bag.python.org> Message-ID: On Jan 24, 2008 2:51 PM, amaury.forgeotdarc wrote: > Author: amaury.forgeotdarc > Date: Thu Jan 24 23:51:18 2008 > New Revision: 60265 > > Modified: > python/trunk/Lib/test/test_grammar.py > python/trunk/Python/compile.c > Log: > #1920: when considering a block starting by "while 0", the compiler optimized the > whole construct away, even when an 'else' clause is present:: > > while 0: > print("no") > else: > print("yes") > > did not generate any code at all. > > Now the compiler emits the 'else' block, like it already does for 'if' statements. Since this change affects byte code generation, the import magic # should be updated for 2.6. We can't update the magic for 2.5. For more info see Python/import.c or PEP 339. n From guido at python.org Fri Jan 25 00:26:44 2008 From: guido at python.org (Guido van Rossum) Date: Thu, 24 Jan 2008 15:26:44 -0800 Subject: [Python-checkins] r60265 - in python/trunk: Lib/test/test_grammar.py Python/compile.c In-Reply-To: References: <20080124225122.9D30B1E4018@bag.python.org> Message-ID: On Jan 24, 2008 3:01 PM, Neal Norwitz wrote: > On Jan 24, 2008 2:51 PM, amaury.forgeotdarc wrote: > > Author: amaury.forgeotdarc > > Date: Thu Jan 24 23:51:18 2008 > > New Revision: 60265 > > > > Modified: > > python/trunk/Lib/test/test_grammar.py > > python/trunk/Python/compile.c > > Log: > > #1920: when considering a block starting by "while 0", the compiler optimized the > > whole construct away, even when an 'else' clause is present:: > > > > while 0: > > print("no") > > else: > > print("yes") > > > > did not generate any code at all. > > > > Now the compiler emits the 'else' block, like it already does for 'if' statements. > > Since this change affects byte code generation, the import magic # > should be updated for 2.6. We can't update the magic for 2.5. For > more info see Python/import.c or PEP 339. I don't think so. While the old byte code may be wrong, we're not introducing new opcodes or changing the semantics of bytecode. So I don't think MAGIC needs to change. -- --Guido van Rossum (home page: http://www.python.org/~guido/) From amauryfa at gmail.com Fri Jan 25 00:27:13 2008 From: amauryfa at gmail.com (Amaury Forgeot d'Arc) Date: Fri, 25 Jan 2008 00:27:13 +0100 Subject: [Python-checkins] r60265 - in python/trunk: Lib/test/test_grammar.py Python/compile.c Message-ID: Neal Norwitz wrote: > Since this change affects byte code generation, the import magic # > should be updated for 2.6. We can't update the magic for 2.5. For > more info see Python/import.c or PEP 339. Many thanks, I was just bitten by this in my 2.5 workspace: I patched the files, ran the test to see it fail. After recompiling the interpreter, test still failed... because the pyc was considered up-to-date. I will bump the magic number for 2.6 only. -- Amaury Forgeot d'Arc From buildbot at python.org Fri Jan 25 00:31:54 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 24 Jan 2008 23:31:54 +0000 Subject: [Python-checkins] buildbot failure in amd64 gentoo trunk Message-ID: <20080124233154.E074C1E4017@bag.python.org> The Buildbot has detected a new failure of amd64 gentoo trunk. Full details are available at: http://www.python.org/dev/buildbot/all/amd64%20gentoo%20trunk/builds/12 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-amd64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: amaury.forgeotdarc BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30995, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30995, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30995, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_thread.py", line 260, in writerThread self.assertEqual(data, self.makeData(key)) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/unittest.py", line 343, in failUnlessEqual (msg or '%r != %r' % (first, second)) AssertionError: None != '2000-2000-2000-2000-2000' Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_thread.py", line 260, in writerThread self.assertEqual(data, self.makeData(key)) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/unittest.py", line 343, in failUnlessEqual (msg or '%r != %r' % (first, second)) AssertionError: None != '1000-1000-1000-1000-1000' Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_thread.py", line 260, in writerThread self.assertEqual(data, self.makeData(key)) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/unittest.py", line 343, in failUnlessEqual (msg or '%r != %r' % (first, second)) AssertionError: None != '0002-0002-0002-0002-0002' 1 test failed: test_urllib2net ====================================================================== ERROR: test_ftp_basic (test.test_urllib2net.TimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/test/test_urllib2net.py", line 291, in test_ftp_basic u = urllib2.urlopen("ftp://ftp.mirror.nl/pub/mirror/gnu/") File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/urllib2.py", line 124, in urlopen return _opener.open(url, data, timeout) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/urllib2.py", line 380, in open response = self._open(req, data) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/urllib2.py", line 398, in _open '_open', req) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/urllib2.py", line 358, in _call_chain result = func(*args) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/urllib2.py", line 1277, in ftp_open fw = self.connect_ftp(user, passwd, host, port, dirs, req.timeout) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/urllib2.py", line 1323, in connect_ftp self.cache[key] = ftpwrapper(user, passwd, host, port, dirs, timeout) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/urllib.py", line 842, in __init__ self.init() File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/urllib.py", line 848, in init self.ftp.connect(self.host, self.port, self.timeout) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/ftplib.py", line 133, in connect self.welcome = self.getresp() File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/ftplib.py", line 208, in getresp resp = self.getmultiline() File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/ftplib.py", line 194, in getmultiline line = self.getline() File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/ftplib.py", line 181, in getline line = self.file.readline() File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) URLError: make: *** [buildbottest] Error 1 sincerely, -The Buildbot From amauryfa at gmail.com Fri Jan 25 00:38:12 2008 From: amauryfa at gmail.com (Amaury Forgeot d'Arc) Date: Fri, 25 Jan 2008 00:38:12 +0100 Subject: [Python-checkins] r60265 - in python/trunk: Lib/test/test_grammar.py Python/compile.c In-Reply-To: References: Message-ID: Amaury Forgeot d'Arc wrote: > Neal Norwitz wrote: > > Since this change affects byte code generation, the import magic # > > should be updated for 2.6. We can't update the magic for 2.5. For > > more info see Python/import.c or PEP 339. > > Many thanks, I was just bitten by this in my 2.5 workspace: > I patched the files, ran the test to see it fail. > After recompiling the interpreter, test still failed... > because the pyc was considered up-to-date. > > I will bump the magic number for 2.6 only. Now I won't... Guido van Rossum wrote: > I don't think so. While the old byte code may be wrong, we're not > introducing new opcodes or changing the semantics of bytecode. So I > don't think MAGIC needs to change. I agree. Moreover only files affected by this problem are to be recompiled. And they are not expected to be so common... -- Amaury Forgeot d'Arc From python-checkins at python.org Fri Jan 25 00:42:09 2008 From: python-checkins at python.org (amaury.forgeotdarc) Date: Fri, 25 Jan 2008 00:42:09 +0100 (CET) Subject: [Python-checkins] r60268 - in python/branches/release25-maint: Lib/test/test_grammar.py Misc/NEWS Python/compile.c Message-ID: <20080124234209.040321E4013@bag.python.org> Author: amaury.forgeotdarc Date: Fri Jan 25 00:42:08 2008 New Revision: 60268 Modified: python/branches/release25-maint/Lib/test/test_grammar.py python/branches/release25-maint/Misc/NEWS python/branches/release25-maint/Python/compile.c Log: #1920: when considering a block starting by "while 0", the compiler optimized the whole construct away, even when an 'else' clause is present:: while 0: print("no") else: print("yes") did not generate any code at all. Now the compiler emits the 'else' block, like it already does for 'if' statements. Backport of r60265. Modified: python/branches/release25-maint/Lib/test/test_grammar.py ============================================================================== --- python/branches/release25-maint/Lib/test/test_grammar.py (original) +++ python/branches/release25-maint/Lib/test/test_grammar.py Fri Jan 25 00:42:08 2008 @@ -511,6 +511,15 @@ while 0: pass else: pass +# Issue1920: "while 0" is optimized away, +# ensure that the "else" clause is still present. +x = 0 +while 0: + x = 1 +else: + x = 2 +assert x == 2 + print 'for_stmt' # 'for' exprlist 'in' exprlist ':' suite ['else' ':' suite] for i in 1, 2, 3: pass for i, j, k in (): pass Modified: python/branches/release25-maint/Misc/NEWS ============================================================================== --- python/branches/release25-maint/Misc/NEWS (original) +++ python/branches/release25-maint/Misc/NEWS Fri Jan 25 00:42:08 2008 @@ -12,6 +12,11 @@ Core and builtins ----------------- +- Issue #1920: "while 0" statements were completely removed by the compiler, + even in the presence of an "else" clause, which is supposed to be run when + the condition is false. Now the compiler correctly emits bytecode for the + "else" suite. + - A few crashers fixed: weakref_in_del.py (issue #1377858); loosing_dict_ref.py (issue #1303614, test67.py); borrowed_ref_[34].py (not in tracker). Modified: python/branches/release25-maint/Python/compile.c ============================================================================== --- python/branches/release25-maint/Python/compile.c (original) +++ python/branches/release25-maint/Python/compile.c Fri Jan 25 00:42:08 2008 @@ -2256,8 +2256,11 @@ basicblock *loop, *orelse, *end, *anchor = NULL; int constant = expr_constant(s->v.While.test); - if (constant == 0) + if (constant == 0) { + if (s->v.While.orelse) + VISIT_SEQ(c, stmt, s->v.While.orelse); return 1; + } loop = compiler_new_block(c); end = compiler_new_block(c); if (constant == -1) { From python-checkins at python.org Fri Jan 25 00:50:26 2008 From: python-checkins at python.org (raymond.hettinger) Date: Fri, 25 Jan 2008 00:50:26 +0100 (CET) Subject: [Python-checkins] r60269 - python/trunk/Lib/rational.py Message-ID: <20080124235026.9706C1E402F@bag.python.org> Author: raymond.hettinger Date: Fri Jan 25 00:50:26 2008 New Revision: 60269 Modified: python/trunk/Lib/rational.py Log: More code cleanup. Remove unnecessary indirection to useless class methods. Modified: python/trunk/Lib/rational.py ============================================================================== --- python/trunk/Lib/rational.py (original) +++ python/trunk/Lib/rational.py Fri Jan 25 00:50:26 2008 @@ -285,8 +285,9 @@ __truediv__, __rtruediv__ = _operator_fallbacks(_div, operator.truediv) __div__, __rdiv__ = _operator_fallbacks(_div, operator.div) - @classmethod - def _floordiv(cls, a, b): + def __floordiv__(a, b): + """a // b""" + # Will be math.floor(a / b) in 3.0. div = a / b if isinstance(div, RationalAbc): # trunc(math.floor(div)) doesn't work if the rational is @@ -296,28 +297,27 @@ else: return math.floor(div) - def __floordiv__(a, b): - """a // b""" - # Will be math.floor(a / b) in 3.0. - return a._floordiv(a, b) - def __rfloordiv__(b, a): """a // b""" # Will be math.floor(a / b) in 3.0. - return b._floordiv(a, b) - - @classmethod - def _mod(cls, a, b): - div = a // b - return a - b * div + div = a / b + if isinstance(div, RationalAbc): + # trunc(math.floor(div)) doesn't work if the rational is + # more precise than a float because the intermediate + # rounding may cross an integer boundary. + return div.numerator // div.denominator + else: + return math.floor(div) def __mod__(a, b): """a % b""" - return a._mod(a, b) + div = a // b + return a - b * div def __rmod__(b, a): """a % b""" - return b._mod(a, b) + div = a // b + return a - b * div def __pow__(a, b): """a ** b From brett at python.org Fri Jan 25 01:14:36 2008 From: brett at python.org (Brett Cannon) Date: Thu, 24 Jan 2008 16:14:36 -0800 Subject: [Python-checkins] r60249 - python/trunk/Lib/threading.py In-Reply-To: <20080124165919.AFQ88215@ms19.lnh.mail.rcn.net> References: <20080124165919.AFQ88215@ms19.lnh.mail.rcn.net> Message-ID: On Jan 24, 2008 1:59 PM, Raymond Hettinger wrote: > > How bad was the performance hit? > > Depends on how you measure it (the whole method, the try/finally part, the call to the lock, etc). The with-statement has try/finally logic embedded but adds a few steps. The threading module is a core building block and needs to be as fast as it can (with the try/finally logic remaining in-line). > True. I just wanted to know if it was truly marginal or enough to actually measure. > > > The code is so much cleaner with the context managers. > > Sort of yes, sort of no. This code has been much exercised and is stable. It would not be hard to destabilize it and introduce hard-to-find bugs. Overall, sure, but I don't think the context managers for the locks are that complex. But I get your point. > Also, at Guido's behest, I plan to rewrite this module in C at some point -- that will be a bit easier with the in-lined try/finally logic still in place. Do you think it will be worth revisiting the API? I know the 'threading' module was inspired by Java so it might stand a Pythonic update. I personally don't know, though, since I use the module infrequently. -Brett From python-checkins at python.org Fri Jan 25 01:21:54 2008 From: python-checkins at python.org (raymond.hettinger) Date: Fri, 25 Jan 2008 01:21:54 +0100 (CET) Subject: [Python-checkins] r60270 - in python/trunk/Lib: rational.py test/test_rational.py Message-ID: <20080125002154.A08B81E400F@bag.python.org> Author: raymond.hettinger Date: Fri Jan 25 01:21:54 2008 New Revision: 60270 Modified: python/trunk/Lib/rational.py python/trunk/Lib/test/test_rational.py Log: Add support for copy, deepcopy, and pickle. Modified: python/trunk/Lib/rational.py ============================================================================== --- python/trunk/Lib/rational.py (original) +++ python/trunk/Lib/rational.py Fri Jan 25 01:21:54 2008 @@ -490,3 +490,18 @@ def __nonzero__(a): """a != 0""" return a.numerator != 0 + + # support for pickling, copy, and deepcopy + + def __reduce__(self): + return (self.__class__, (str(self),)) + + def __copy__(self): + if type(self) == Rational: + return self # I'm immutable; therefore I am my own clone + return self.__class__(self.numerator, self.denominator) + + def __deepcopy__(self, memo): + if type(self) == Rational: + return self # My components are also immutable + return self.__class__(self.numerator, self.denominator) Modified: python/trunk/Lib/test/test_rational.py ============================================================================== --- python/trunk/Lib/test/test_rational.py (original) +++ python/trunk/Lib/test/test_rational.py Fri Jan 25 01:21:54 2008 @@ -6,6 +6,8 @@ import operator import rational import unittest +from copy import copy, deepcopy +from cPickle import dumps, loads R = rational.Rational def _components(r): @@ -359,6 +361,12 @@ s += num / fact * sign self.assertAlmostEquals(math.cos(1), s) + def test_copy_deepcopy_pickle(self): + r = R(13, 7) + self.assertEqual(r, loads(dumps(r))) + self.assertEqual(id(r), id(copy(r))) + self.assertEqual(id(r), id(deepcopy(r))) + def test_main(): run_unittest(RationalTest) From python-checkins at python.org Fri Jan 25 01:33:46 2008 From: python-checkins at python.org (raymond.hettinger) Date: Fri, 25 Jan 2008 01:33:46 +0100 (CET) Subject: [Python-checkins] r60271 - python/trunk/Lib/rational.py Message-ID: <20080125003346.2A8C81E4013@bag.python.org> Author: raymond.hettinger Date: Fri Jan 25 01:33:45 2008 New Revision: 60271 Modified: python/trunk/Lib/rational.py Log: Mark todos and review comments. Modified: python/trunk/Lib/rational.py ============================================================================== --- python/trunk/Lib/rational.py (original) +++ python/trunk/Lib/rational.py Fri Jan 25 01:33:45 2008 @@ -40,6 +40,8 @@ >>> _binary_float_to_ratio(-.25) (-1, 4) """ + # XXX Consider moving this to to floatobject.c + # with a name like float.as_intger_ratio() if x == 0: return 0, 1 @@ -219,6 +221,16 @@ else: return '%s/%s' % (self.numerator, self.denominator) + """ XXX This section needs a lot more commentary + + * Explain the typical sequence of checks, calls, and fallbacks. + * Explain the subtle reasons why this logic was needed. + * It is not clear how common cases are handled (for example, how + does the ratio of two huge integers get converted to a float + without overflowing the long-->float conversion. + + """ + def _operator_fallbacks(monomorphic_operator, fallback_operator): """Generates forward and reverse operators given a purely-rational operator and a function from the operator module. @@ -419,6 +431,7 @@ float must have the same hash as that float. """ + # XXX since this method is expensive, consider caching the result if self.denominator == 1: # Get integers right. return hash(self.numerator) From python-checkins at python.org Fri Jan 25 02:13:12 2008 From: python-checkins at python.org (raymond.hettinger) Date: Fri, 25 Jan 2008 02:13:12 +0100 (CET) Subject: [Python-checkins] r60272 - python/trunk/Lib/rational.py Message-ID: <20080125011312.79FF01E400F@bag.python.org> Author: raymond.hettinger Date: Fri Jan 25 02:13:12 2008 New Revision: 60272 Modified: python/trunk/Lib/rational.py Log: Add one other review comment. Modified: python/trunk/Lib/rational.py ============================================================================== --- python/trunk/Lib/rational.py (original) +++ python/trunk/Lib/rational.py Fri Jan 25 02:13:12 2008 @@ -14,7 +14,7 @@ RationalAbc = numbers.Rational -def _gcd(a, b): +def _gcd(a, b): # XXX This is a useful function. Consider making it public. """Calculate the Greatest Common Divisor. Unless b==0, the result will have the same sign as b (so that when From python-checkins at python.org Fri Jan 25 02:23:38 2008 From: python-checkins at python.org (raymond.hettinger) Date: Fri, 25 Jan 2008 02:23:38 +0100 (CET) Subject: [Python-checkins] r60273 - in python/trunk/Lib: rational.py test/test_rational.py Message-ID: <20080125012338.A11181E400F@bag.python.org> Author: raymond.hettinger Date: Fri Jan 25 02:23:38 2008 New Revision: 60273 Modified: python/trunk/Lib/rational.py python/trunk/Lib/test/test_rational.py Log: Fix-up signature for approximation. Modified: python/trunk/Lib/rational.py ============================================================================== --- python/trunk/Lib/rational.py (original) +++ python/trunk/Lib/rational.py Fri Jan 25 02:23:38 2008 @@ -195,16 +195,17 @@ n, d = d, n return cf - @classmethod - def approximate_from_float(cls, f, max_denominator): - 'Best rational approximation to f with a denominator <= max_denominator' + def approximate(self, max_denominator): + 'Best rational approximation with a denominator <= max_denominator' # XXX First cut at algorithm # Still needs rounding rules as specified at # http://en.wikipedia.org/wiki/Continued_fraction - cf = cls.from_float(f).as_continued_fraction() + if self.denominator <= max_denominator: + return self + cf = self.as_continued_fraction() result = Rational(0) for i in range(1, len(cf)): - new = cls.from_continued_fraction(cf[:i]) + new = self.from_continued_fraction(cf[:i]) if new.denominator > max_denominator: break result = new Modified: python/trunk/Lib/test/test_rational.py ============================================================================== --- python/trunk/Lib/test/test_rational.py (original) +++ python/trunk/Lib/test/test_rational.py Fri Jan 25 02:23:38 2008 @@ -155,10 +155,10 @@ [-4, 1, 6, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 3, 3]) self.assertEqual(R(0).as_continued_fraction(), [0]) - def testApproximateFromFloat(self): - self.assertEqual(R.approximate_from_float(math.pi, 10000), R(355, 113)) - self.assertEqual(R.approximate_from_float(-math.pi, 10000), R(-355, 113)) - self.assertEqual(R.approximate_from_float(0.0, 10000), R(0)) + def testApproximateFrom(self): + self.assertEqual(R.from_float(math.pi).approximate(10000), R(355, 113)) + self.assertEqual(R.from_float(-math.pi).approximate(10000), R(-355, 113)) + self.assertEqual(R.from_float(0.0).approximate(10000), R(0)) def testConversions(self): self.assertTypedEquals(-1, trunc(R(-11, 10))) From python-checkins at python.org Fri Jan 25 02:46:33 2008 From: python-checkins at python.org (raymond.hettinger) Date: Fri, 25 Jan 2008 02:46:33 +0100 (CET) Subject: [Python-checkins] r60274 - python/trunk/Lib/rational.py Message-ID: <20080125014633.7EB6E1E400F@bag.python.org> Author: raymond.hettinger Date: Fri Jan 25 02:46:33 2008 New Revision: 60274 Modified: python/trunk/Lib/rational.py Log: More design notes Modified: python/trunk/Lib/rational.py ============================================================================== --- python/trunk/Lib/rational.py (original) +++ python/trunk/Lib/rational.py Fri Jan 25 02:46:33 2008 @@ -82,6 +82,10 @@ _RATIONAL_FORMAT = re.compile( r'^\s*(?P[-+]?)(?P\d+)(?:/(?P\d+))?\s*$') +# XXX Consider accepting decimal strings as input since they are exact. +# Rational("2.01") --> s="2.01" ; Rational.from_decimal(Decimal(s)) --> Rational(201, 100)" +# If you want to avoid going through the decimal module, just parse the string directly: +# s.partition('.') --> ('2', '.', '01') --> Rational(int('2'+'01'), 10**len('01')) --> Rational(201, 100) class Rational(RationalAbc): """This class implements rational numbers. From nnorwitz at gmail.com Fri Jan 25 05:51:26 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Thu, 24 Jan 2008 20:51:26 -0800 Subject: [Python-checkins] r60225 - python/trunk/Lib/idlelib/NEWS.txt python/trunk/Lib/idlelib/configHandler.py In-Reply-To: <20080123221924.57B021E401C@bag.python.org> References: <20080123221924.57B021E401C@bag.python.org> Message-ID: On Jan 23, 2008 2:19 PM, kurt.kaiser wrote: > Author: kurt.kaiser > Date: Wed Jan 23 23:19:23 2008 > New Revision: 60225 > > Modified: > python/trunk/Lib/idlelib/NEWS.txt > python/trunk/Lib/idlelib/configHandler.py > Log: > Could not open files in .idlerc directory if latter was hidden on Windows. > Issue 1743, Issue 1862. > > Modified: python/trunk/Lib/idlelib/configHandler.py > ============================================================================== > --- python/trunk/Lib/idlelib/configHandler.py (original) > +++ python/trunk/Lib/idlelib/configHandler.py Wed Jan 23 23:19:23 2008 > @@ -139,7 +139,12 @@ > > """ > if not self.IsEmpty(): > - cfgFile=open(self.file,'w') > + fname = self.file > + try: > + cfgFile = open(fname, 'w') > + except IOError: > + fname.unlink() Isn't fname a string? Should this be os.unlink(fname)? n From python-checkins at python.org Fri Jan 25 07:11:54 2008 From: python-checkins at python.org (guido.van.rossum) Date: Fri, 25 Jan 2008 07:11:54 +0100 (CET) Subject: [Python-checkins] r60275 - python/branches/release25-maint/Parser/tokenizer.c Message-ID: <20080125061154.146DF1E400F@bag.python.org> Author: guido.van.rossum Date: Fri Jan 25 07:11:53 2008 New Revision: 60275 Modified: python/branches/release25-maint/Parser/tokenizer.c Log: Silence a compiler warning. Modified: python/branches/release25-maint/Parser/tokenizer.c ============================================================================== --- python/branches/release25-maint/Parser/tokenizer.c (original) +++ python/branches/release25-maint/Parser/tokenizer.c Fri Jan 25 07:11:53 2008 @@ -585,7 +585,7 @@ { PyObject* utf8 = NULL; const char *s; - char *newl[2] = {NULL, NULL}; + const char *newl[2] = {NULL, NULL}; int lineno = 0; tok->enc = NULL; tok->str = str; From python-checkins at python.org Fri Jan 25 07:37:24 2008 From: python-checkins at python.org (neal.norwitz) Date: Fri, 25 Jan 2008 07:37:24 +0100 (CET) Subject: [Python-checkins] r60276 - python/trunk/Lib/test/test_urllib2net.py Message-ID: <20080125063724.17FB71E400F@bag.python.org> Author: neal.norwitz Date: Fri Jan 25 07:37:23 2008 New Revision: 60276 Modified: python/trunk/Lib/test/test_urllib2net.py Log: Make the test more robust by trying to reconnect up to 3 times in case there were transient failures. This will hopefully silence the buildbots for this test. As we find other tests that have a problem, we can fix with a similar strategy assuming it is successful. It worked on my box in a loop for 10+ runs where it would have an exception otherwise. Modified: python/trunk/Lib/test/test_urllib2net.py ============================================================================== --- python/trunk/Lib/test/test_urllib2net.py (original) +++ python/trunk/Lib/test/test_urllib2net.py Fri Jan 25 07:37:23 2008 @@ -10,6 +10,20 @@ import os import mimetools + +def _urlopen_with_retry(host, *args, **kwargs): + # Connecting to remote hosts is flaky. Make it more robust + # by retrying the connection several times. + for i in range(3): + try: + return urllib2.urlopen(host, *args, **kwargs) + except urllib2.URLError, last_exc: + continue + except: + raise + raise last_exc + + class URLTimeoutTest(unittest.TestCase): TIMEOUT = 10.0 @@ -21,7 +35,7 @@ socket.setdefaulttimeout(None) def testURLread(self): - f = urllib2.urlopen("http://www.python.org/") + f = _urlopen_with_retry("http://www.python.org/") x = f.read() @@ -42,7 +56,7 @@ # # # failure # try: -# urllib2.urlopen(test_url) +# _urlopen_with_retry(test_url) # except urllib2.HTTPError, exc: # self.assertEqual(exc.code, 401) # else: @@ -54,7 +68,7 @@ # test_user, test_password) # opener = urllib2.build_opener(auth_handler) # f = opener.open('http://localhost/') -# response = urllib2.urlopen("http://www.python.org/") +# response = _urlopen_with_retry("http://www.python.org/") # # # The 'userinfo' URL component is deprecated by RFC 3986 for security # # reasons, let's not implement it! (it's already implemented for proxy @@ -73,7 +87,7 @@ # underlying socket # delve deep into response to fetch socket._socketobject - response = urllib2.urlopen("http://www.python.org/") + response = _urlopen_with_retry("http://www.python.org/") abused_fileobject = response.fp self.assert_(abused_fileobject.__class__ is socket._fileobject) httpresponse = abused_fileobject._sock @@ -102,7 +116,7 @@ def test_basic(self): # Simple test expected to pass. - open_url = urllib2.urlopen("http://www.python.org/") + open_url = _urlopen_with_retry("http://www.python.org/") for attr in ("read", "close", "info", "geturl"): self.assert_(hasattr(open_url, attr), "object returned from " "urlopen lacks the %s attribute" % attr) @@ -113,7 +127,7 @@ def test_info(self): # Test 'info'. - open_url = urllib2.urlopen("http://www.python.org/") + open_url = _urlopen_with_retry("http://www.python.org/") try: info_obj = open_url.info() finally: @@ -126,7 +140,7 @@ def test_geturl(self): # Make sure same URL as opened is returned by geturl. URL = "http://www.python.org/" - open_url = urllib2.urlopen(URL) + open_url = _urlopen_with_retry(URL) try: gotten_url = open_url.geturl() finally: @@ -157,7 +171,7 @@ def test_range (self): req = urllib2.Request("http://www.python.org", headers={'Range': 'bytes=20-39'}) - result = urllib2.urlopen(req) + result = _urlopen_with_retry(req) data = result.read() self.assertEqual(len(data), 20) @@ -184,7 +198,7 @@ 'file:'+sanepathname2url(os.path.abspath(TESTFN)), ('file:///nonsensename/etc/passwd', None, urllib2.URLError), ] - self._test_urls(urls, self._extra_handlers()) + self._test_urls(urls, self._extra_handlers(), urllib2.urlopen) finally: os.remove(TESTFN) @@ -226,7 +240,7 @@ ## self._test_urls(urls, self._extra_handlers()+[bauth, dauth]) - def _test_urls(self, urls, handlers): + def _test_urls(self, urls, handlers, urlopen=_urlopen_with_retry): import socket import time import logging @@ -241,7 +255,7 @@ req = expected_err = None debug(url) try: - f = urllib2.urlopen(url, req) + f = urlopen(url, req) except EnvironmentError, err: debug(err) if expected_err: @@ -267,45 +281,47 @@ class TimeoutTest(unittest.TestCase): def test_http_basic(self): - u = urllib2.urlopen("http://www.python.org") + u = _urlopen_with_retry("http://www.python.org") self.assertTrue(u.fp._sock.fp._sock.gettimeout() is None) def test_http_NoneWithdefault(self): prev = socket.getdefaulttimeout() socket.setdefaulttimeout(60) try: - u = urllib2.urlopen("http://www.python.org", timeout=None) + u = _urlopen_with_retry("http://www.python.org", timeout=None) self.assertEqual(u.fp._sock.fp._sock.gettimeout(), 60) finally: socket.setdefaulttimeout(prev) def test_http_Value(self): - u = urllib2.urlopen("http://www.python.org", timeout=120) + u = _urlopen_with_retry("http://www.python.org", timeout=120) self.assertEqual(u.fp._sock.fp._sock.gettimeout(), 120) def test_http_NoneNodefault(self): - u = urllib2.urlopen("http://www.python.org", timeout=None) + u = _urlopen_with_retry("http://www.python.org", timeout=None) self.assertTrue(u.fp._sock.fp._sock.gettimeout() is None) + FTP_HOST = "ftp://ftp.mirror.nl/pub/mirror/gnu/" + def test_ftp_basic(self): - u = urllib2.urlopen("ftp://ftp.mirror.nl/pub/mirror/gnu/") + u = _urlopen_with_retry(self.FTP_HOST) self.assertTrue(u.fp.fp._sock.gettimeout() is None) def test_ftp_NoneWithdefault(self): prev = socket.getdefaulttimeout() socket.setdefaulttimeout(60) try: - u = urllib2.urlopen("ftp://ftp.mirror.nl/pub/mirror/gnu/", timeout=None) + u = _urlopen_with_retry(self.FTP_HOST, timeout=None) self.assertEqual(u.fp.fp._sock.gettimeout(), 60) finally: socket.setdefaulttimeout(prev) def test_ftp_NoneNodefault(self): - u = urllib2.urlopen("ftp://ftp.mirror.nl/pub/mirror/gnu/", timeout=None) + u = _urlopen_with_retry(self.FTP_HOST, timeout=None) self.assertTrue(u.fp.fp._sock.gettimeout() is None) def test_ftp_Value(self): - u = urllib2.urlopen("ftp://ftp.mirror.nl/pub/mirror/gnu/", timeout=60) + u = _urlopen_with_retry(self.FTP_HOST, timeout=60) self.assertEqual(u.fp.fp._sock.gettimeout(), 60) From nnorwitz at gmail.com Fri Jan 25 07:38:28 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Thu, 24 Jan 2008 22:38:28 -0800 Subject: [Python-checkins] r60188 - in python/trunk: Lib/ftplib.py Misc/NEWS In-Reply-To: <20080122001942.5BD581E4003@bag.python.org> References: <20080122001942.5BD581E4003@bag.python.org> Message-ID: On Jan 21, 2008 4:19 PM, gregory.p.smith wrote: > Author: gregory.p.smith > Date: Tue Jan 22 01:19:41 2008 > New Revision: 60188 > > Modified: > python/trunk/Lib/ftplib.py > python/trunk/Misc/NEWS > Log: > accepts and closes issue #1221598: adds an optional callback to ftplib.FTP > storbinary() and storlines() methods. Can you update the docs too or were they updated in a separate checkin? n From buildbot at python.org Fri Jan 25 07:39:57 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 25 Jan 2008 06:39:57 +0000 Subject: [Python-checkins] buildbot failure in amd64 gentoo 2.5 Message-ID: <20080125063957.781D91E400F@bag.python.org> The Buildbot has detected a new failure of amd64 gentoo 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/amd64%20gentoo%202.5/builds/5 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-amd64 Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: guido.van.rossum BUILD FAILED: failed test Excerpt from the test logfile: 2 tests failed: test_socket_ssl test_timeout make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Fri Jan 25 07:42:34 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 25 Jan 2008 06:42:34 +0000 Subject: [Python-checkins] buildbot failure in x86 XP-3 2.5 Message-ID: <20080125064234.9E3451E400F@bag.python.org> The Buildbot has detected a new failure of x86 XP-3 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20XP-3%202.5/builds/166 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: heller-windows Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: guido.van.rossum BUILD FAILED: failed failed slave lost sincerely, -The Buildbot From buildbot at python.org Fri Jan 25 08:20:14 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 25 Jan 2008 07:20:14 +0000 Subject: [Python-checkins] buildbot failure in alpha Tru64 5.1 2.5 Message-ID: <20080125072014.6E9C61E400F@bag.python.org> The Buildbot has detected a new failure of alpha Tru64 5.1 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/alpha%20Tru64%205.1%202.5/builds/418 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-tru64 Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: guido.van.rossum BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_socket ====================================================================== FAIL: testInterruptedTimeout (test.test_socket.TCPTimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/net/taipan/scratch1/nnorwitz/python/2.5.norwitz-tru64/build/Lib/test/test_socket.py", line 879, in testInterruptedTimeout self.fail("got Alarm in wrong place") AssertionError: got Alarm in wrong place sincerely, -The Buildbot From python-checkins at python.org Fri Jan 25 09:04:16 2008 From: python-checkins at python.org (neal.norwitz) Date: Fri, 25 Jan 2008 09:04:16 +0100 (CET) Subject: [Python-checkins] r60277 - in python/trunk: Modules/mathmodule.c Objects/floatobject.c Message-ID: <20080125080416.9CFFB1E400F@bag.python.org> Author: neal.norwitz Date: Fri Jan 25 09:04:16 2008 New Revision: 60277 Modified: python/trunk/Modules/mathmodule.c python/trunk/Objects/floatobject.c Log: Add prototypes to get the mathmodule.c to compile on OSF1 5.1 (Tru64) and eliminate a compiler warning in floatobject.c. There might be a better way to go about this, but it should be good enough for now. Modified: python/trunk/Modules/mathmodule.c ============================================================================== --- python/trunk/Modules/mathmodule.c (original) +++ python/trunk/Modules/mathmodule.c Fri Jan 25 09:04:16 2008 @@ -12,6 +12,11 @@ #endif /* __STDC__ */ #endif /* _MSC_VER */ +#ifdef _OSF_SOURCE +/* OSF1 5.1 doesn't make this available with XOPEN_SOURCE_EXTENDED defined */ +extern double copysign(double, double); +#endif + /* Call is_error when errno != 0, and where x is the result libm * returned. is_error will usually set up an exception and return * true (1), but may return false (0) without setting up an exception. Modified: python/trunk/Objects/floatobject.c ============================================================================== --- python/trunk/Objects/floatobject.c (original) +++ python/trunk/Objects/floatobject.c Fri Jan 25 09:04:16 2008 @@ -16,6 +16,11 @@ extern double pow(double, double); #endif +#ifdef _OSF_SOURCE +/* OSF1 5.1 doesn't make this available with XOPEN_SOURCE_EXTENDED defined */ +extern int finite(double); +#endif + /* Special free list -- see comments for same code in intobject.c. */ #define BLOCK_SIZE 1000 /* 1K less typical malloc overhead */ #define BHEAD_SIZE 8 /* Enough for a 64-bit pointer */ From nnorwitz at gmail.com Fri Jan 25 11:28:26 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Fri, 25 Jan 2008 05:28:26 -0500 Subject: [Python-checkins] Python Regression Test Failures refleak (7) Message-ID: <20080125102826.GA17131@python.psfb.org> test_opcodes leaked [0, -2, 2] references, sum=0 test_doctest leaked [-2, 2, 0] references, sum=0 test_doctest2 leaked [-2, -2, 0] references, sum=-4 test_difflib leaked [-2, -2, 0] references, sum=-4 test_dummy_threading leaked [0, 0, -2] references, sum=-2 test_gc leaked [-2, 2, -4] references, sum=-4 test_generators leaked [0, -2, 2] references, sum=0 test_importhooks leaked [-2, 2, -6] references, sum=-6 test_platform leaked [0, 0, -2] references, sum=-2 test_threadsignals leaked [0, -8, 0] references, sum=-8 test_timeout leaked [-2, 0, 0] references, sum=-2 test_urllib2_localnet leaked [3, 134, -128] references, sum=9 From python-checkins at python.org Fri Jan 25 13:18:44 2008 From: python-checkins at python.org (christian.heimes) Date: Fri, 25 Jan 2008 13:18:44 +0100 (CET) Subject: [Python-checkins] r60283 - in python/trunk: Include/longintrepr.h Include/longobject.h Include/unicodeobject.h Misc/NEWS Modules/_fileio.c Objects/longobject.c Objects/unicodeobject.c setup.py Message-ID: <20080125121844.4BC4D1E400F@bag.python.org> Author: christian.heimes Date: Fri Jan 25 13:18:43 2008 New Revision: 60283 Added: python/trunk/Modules/_fileio.c - copied, changed from r60280, python/branches/py3k/Modules/_fileio.c Modified: python/trunk/Include/longintrepr.h python/trunk/Include/longobject.h python/trunk/Include/unicodeobject.h python/trunk/Misc/NEWS python/trunk/Objects/longobject.c python/trunk/Objects/unicodeobject.c python/trunk/setup.py Log: Backport of several functions from Python 3.0 to 2.6 including PyUnicode_FromString, PyUnicode_Format and PyLong_From/AsSsize_t. The functions are partly required for the backport of the bytearray type and _fileio module. They should also make it easier to port C to 3.0. First chapter of the Python 3.0 io framework back port: _fileio The next step depends on a working bytearray type which itself depends on a backport of the nwe buffer API. Modified: python/trunk/Include/longintrepr.h ============================================================================== --- python/trunk/Include/longintrepr.h (original) +++ python/trunk/Include/longintrepr.h Fri Jan 25 13:18:43 2008 @@ -24,11 +24,11 @@ typedef unsigned BASE_TWODIGITS_TYPE twodigits; typedef BASE_TWODIGITS_TYPE stwodigits; /* signed variant of twodigits */ -#define SHIFT 15 -#define BASE ((digit)1 << SHIFT) -#define MASK ((int)(BASE - 1)) +#define PyLong_SHIFT 15 +#define PyLong_BASE ((digit)1 << PyLong_SHIFT) +#define PyLong_MASK ((int)(PyLong_BASE - 1)) -#if SHIFT % 5 != 0 +#if PyLong_SHIFT % 5 != 0 #error "longobject.c requires that SHIFT be divisible by 5" #endif Modified: python/trunk/Include/longobject.h ============================================================================== --- python/trunk/Include/longobject.h (original) +++ python/trunk/Include/longobject.h Fri Jan 25 13:18:43 2008 @@ -18,14 +18,17 @@ PyAPI_FUNC(PyObject *) PyLong_FromLong(long); PyAPI_FUNC(PyObject *) PyLong_FromUnsignedLong(unsigned long); PyAPI_FUNC(PyObject *) PyLong_FromDouble(double); +PyAPI_FUNC(PyObject *) PyLong_FromSize_t(size_t); +PyAPI_FUNC(PyObject *) PyLong_FromSsize_t(Py_ssize_t); PyAPI_FUNC(long) PyLong_AsLong(PyObject *); PyAPI_FUNC(unsigned long) PyLong_AsUnsignedLong(PyObject *); PyAPI_FUNC(unsigned long) PyLong_AsUnsignedLongMask(PyObject *); +PyAPI_FUNC(Py_ssize_t) PyLong_AsSsize_t(PyObject *); /* For use by intobject.c only */ -PyAPI_FUNC(Py_ssize_t) _PyLong_AsSsize_t(PyObject *); -PyAPI_FUNC(PyObject *) _PyLong_FromSize_t(size_t); -PyAPI_FUNC(PyObject *) _PyLong_FromSsize_t(Py_ssize_t); +#define _PyLong_AsSsize_t PyLong_AsSsize_t +#define _PyLong_FromSize_t PyLong_FromSize_t +#define _PyLong_FromSsize_t PyLong_FromSsize_t PyAPI_DATA(int) _PyLong_DigitValue[256]; /* _PyLong_AsScaledDouble returns a double x and an exponent e such that Modified: python/trunk/Include/unicodeobject.h ============================================================================== --- python/trunk/Include/unicodeobject.h (original) +++ python/trunk/Include/unicodeobject.h Fri Jan 25 13:18:43 2008 @@ -183,6 +183,10 @@ # define PyUnicode_FromObject PyUnicodeUCS2_FromObject # define PyUnicode_FromOrdinal PyUnicodeUCS2_FromOrdinal # define PyUnicode_FromUnicode PyUnicodeUCS2_FromUnicode +# define PyUnicode_FromString PyUnicodeUCS2_FromString +# define PyUnicode_FromStringAndSize PyUnicodeUCS2_FromStringAndSize +# define PyUnicode_FromFormatV PyUnicodeUCS2_FromFormatV +# define PyUnicode_FromFormat PyUnicodeUCS2_FromFormat # define PyUnicode_FromWideChar PyUnicodeUCS2_FromWideChar # define PyUnicode_GetDefaultEncoding PyUnicodeUCS2_GetDefaultEncoding # define PyUnicode_GetMax PyUnicodeUCS2_GetMax @@ -265,6 +269,10 @@ # define PyUnicode_FromObject PyUnicodeUCS4_FromObject # define PyUnicode_FromOrdinal PyUnicodeUCS4_FromOrdinal # define PyUnicode_FromUnicode PyUnicodeUCS4_FromUnicode +# define PyUnicode_FromString PyUnicodeUCS4_FromString +# define PyUnicode_FromStringAndSize PyUnicodeUCS4_FromStringAndSize +# define PyUnicode_FromFormatV PyUnicodeUCS4_FromFormatV +# define PyUnicode_FromFormat PyUnicodeUCS4_FromFormat # define PyUnicode_FromWideChar PyUnicodeUCS4_FromWideChar # define PyUnicode_GetDefaultEncoding PyUnicodeUCS4_GetDefaultEncoding # define PyUnicode_GetMax PyUnicodeUCS4_GetMax @@ -442,6 +450,18 @@ Py_ssize_t size /* size of buffer */ ); +/* Similar to PyUnicode_FromUnicode(), but u points to Latin-1 encoded bytes */ +PyAPI_FUNC(PyObject*) PyUnicode_FromStringAndSize( + const char *u, /* char buffer */ + Py_ssize_t size /* size of buffer */ + ); + +/* Similar to PyUnicode_FromUnicode(), but u points to null-terminated + Latin-1 encoded bytes */ +PyAPI_FUNC(PyObject*) PyUnicode_FromString( + const char *u /* string */ + ); + /* Return a read-only pointer to the Unicode object's internal Py_UNICODE buffer. */ @@ -517,6 +537,9 @@ register PyObject *obj /* Object */ ); +PyAPI_FUNC(PyObject *) PyUnicode_FromFormatV(const char*, va_list); +PyAPI_FUNC(PyObject *) PyUnicode_FromFormat(const char*, ...); + /* --- wchar_t support for platforms which support it --------------------- */ #ifdef HAVE_WCHAR_H Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Fri Jan 25 13:18:43 2008 @@ -1,4 +1,4 @@ -?+++++++++++ ++++++++++++ Python News +++++++++++ @@ -12,6 +12,10 @@ Core and builtins ----------------- +- Backport of PyUnicode_FromString(), _FromStringAndSize(), _Format and + _FormatV from Python 3.0. Made PyLong_AsSsize_t and PyLong_FromSsize_t + public functions. + - Issue #1920: "while 0" statements were completely removed by the compiler, even in the presence of an "else" clause, which is supposed to be run when the condition is false. Now the compiler correctly emits bytecode for the @@ -1102,6 +1106,8 @@ Extension Modules ----------------- +- Backport of _fileio module from Python 3.0. + - #1087741: mmap.mmap is now a class, not a factory function. It is also subclassable now. Copied: python/trunk/Modules/_fileio.c (from r60280, python/branches/py3k/Modules/_fileio.c) ============================================================================== --- python/branches/py3k/Modules/_fileio.c (original) +++ python/trunk/Modules/_fileio.c Fri Jan 25 13:18:43 2008 @@ -326,7 +326,7 @@ { if (self->fd < 0) return err_closed(); - return PyLong_FromLong((long) self->fd); + return PyInt_FromLong((long) self->fd); } static PyObject * @@ -731,9 +731,9 @@ fileio_repr(PyFileIOObject *self) { if (self->fd < 0) - return PyUnicode_FromFormat("_fileio._FileIO(-1)"); + return PyString_FromFormat("_fileio._FileIO(-1)"); - return PyUnicode_FromFormat("_fileio._FileIO(%d, '%s')", + return PyString_FromFormat("_fileio._FileIO(%d, '%s')", self->fd, mode_string(self)); } @@ -856,7 +856,7 @@ static PyObject * get_mode(PyFileIOObject *self, void *closure) { - return PyUnicode_FromString(mode_string(self)); + return PyString_FromString(mode_string(self)); } static PyGetSetDef fileio_getsetlist[] = { Modified: python/trunk/Objects/longobject.c ============================================================================== --- python/trunk/Objects/longobject.c (original) +++ python/trunk/Objects/longobject.c Fri Jan 25 13:18:43 2008 @@ -11,7 +11,7 @@ /* For long multiplication, use the O(N**2) school algorithm unless * both operands contain more than KARATSUBA_CUTOFF digits (this - * being an internal Python long digit, in base BASE). + * being an internal Python long digit, in base PyLong_BASE). */ #define KARATSUBA_CUTOFF 70 #define KARATSUBA_SQUARE_CUTOFF (2 * KARATSUBA_CUTOFF) @@ -115,7 +115,7 @@ t = (unsigned long)ival; while (t) { ++ndigits; - t >>= SHIFT; + t >>= PyLong_SHIFT; } v = _PyLong_New(ndigits); if (v != NULL) { @@ -123,8 +123,8 @@ v->ob_size = negative ? -ndigits : ndigits; t = (unsigned long)ival; while (t) { - *p++ = (digit)(t & MASK); - t >>= SHIFT; + *p++ = (digit)(t & PyLong_MASK); + t >>= PyLong_SHIFT; } } return (PyObject *)v; @@ -143,15 +143,15 @@ t = (unsigned long)ival; while (t) { ++ndigits; - t >>= SHIFT; + t >>= PyLong_SHIFT; } v = _PyLong_New(ndigits); if (v != NULL) { digit *p = v->ob_digit; Py_SIZE(v) = ndigits; while (ival) { - *p++ = (digit)(ival & MASK); - ival >>= SHIFT; + *p++ = (digit)(ival & PyLong_MASK); + ival >>= PyLong_SHIFT; } } return (PyObject *)v; @@ -181,16 +181,16 @@ frac = frexp(dval, &expo); /* dval = frac*2**expo; 0.0 <= frac < 1.0 */ if (expo <= 0) return PyLong_FromLong(0L); - ndig = (expo-1) / SHIFT + 1; /* Number of 'digits' in result */ + ndig = (expo-1) / PyLong_SHIFT + 1; /* Number of 'digits' in result */ v = _PyLong_New(ndig); if (v == NULL) return NULL; - frac = ldexp(frac, (expo-1) % SHIFT + 1); + frac = ldexp(frac, (expo-1) % PyLong_SHIFT + 1); for (i = ndig; --i >= 0; ) { long bits = (long)frac; v->ob_digit[i] = (digit) bits; frac = frac - (double)bits; - frac = ldexp(frac, SHIFT); + frac = ldexp(frac, PyLong_SHIFT); } if (neg) Py_SIZE(v) = -(Py_SIZE(v)); @@ -237,8 +237,8 @@ } while (--i >= 0) { prev = x; - x = (x << SHIFT) + v->ob_digit[i]; - if ((x >> SHIFT) != prev) + x = (x << PyLong_SHIFT) + v->ob_digit[i]; + if ((x >> PyLong_SHIFT) != prev) goto overflow; } /* Haven't lost any bits, but casting to long requires extra care @@ -262,7 +262,7 @@ Returns -1 and sets an error condition if overflow occurs. */ Py_ssize_t -_PyLong_AsSsize_t(PyObject *vv) { +PyLong_AsSsize_t(PyObject *vv) { register PyLongObject *v; size_t x, prev; Py_ssize_t i; @@ -282,8 +282,8 @@ } while (--i >= 0) { prev = x; - x = (x << SHIFT) + v->ob_digit[i]; - if ((x >> SHIFT) != prev) + x = (x << PyLong_SHIFT) + v->ob_digit[i]; + if ((x >> PyLong_SHIFT) != prev) goto overflow; } /* Haven't lost any bits, but casting to a signed type requires @@ -336,8 +336,8 @@ } while (--i >= 0) { prev = x; - x = (x << SHIFT) + v->ob_digit[i]; - if ((x >> SHIFT) != prev) { + x = (x << PyLong_SHIFT) + v->ob_digit[i]; + if ((x >> PyLong_SHIFT) != prev) { PyErr_SetString(PyExc_OverflowError, "long int too large to convert"); return (unsigned long) -1; @@ -372,7 +372,7 @@ i = -i; } while (--i >= 0) { - x = (x << SHIFT) + v->ob_digit[i]; + x = (x << PyLong_SHIFT) + v->ob_digit[i]; } return x * sign; } @@ -402,8 +402,8 @@ if (ndigits > 0) { digit msd = v->ob_digit[ndigits - 1]; - result = (ndigits - 1) * SHIFT; - if (result / SHIFT != (size_t)(ndigits - 1)) + result = (ndigits - 1) * PyLong_SHIFT; + if (result / PyLong_SHIFT != (size_t)(ndigits - 1)) goto Overflow; do { ++result; @@ -473,9 +473,9 @@ } /* How many Python long digits do we need? We have - 8*numsignificantbytes bits, and each Python long digit has SHIFT + 8*numsignificantbytes bits, and each Python long digit has PyLong_SHIFT bits, so it's the ceiling of the quotient. */ - ndigits = (numsignificantbytes * 8 + SHIFT - 1) / SHIFT; + ndigits = (numsignificantbytes * 8 + PyLong_SHIFT - 1) / PyLong_SHIFT; if (ndigits > (size_t)INT_MAX) return PyErr_NoMemory(); v = _PyLong_New((int)ndigits); @@ -505,17 +505,17 @@ so needs to be prepended to accum. */ accum |= thisbyte << accumbits; accumbits += 8; - if (accumbits >= SHIFT) { + if (accumbits >= PyLong_SHIFT) { /* There's enough to fill a Python digit. */ assert(idigit < (int)ndigits); - v->ob_digit[idigit] = (digit)(accum & MASK); + v->ob_digit[idigit] = (digit)(accum & PyLong_MASK); ++idigit; - accum >>= SHIFT; - accumbits -= SHIFT; - assert(accumbits < SHIFT); + accum >>= PyLong_SHIFT; + accumbits -= PyLong_SHIFT; + assert(accumbits < PyLong_SHIFT); } } - assert(accumbits < SHIFT); + assert(accumbits < PyLong_SHIFT); if (accumbits) { assert(idigit < (int)ndigits); v->ob_digit[idigit] = (digit)accum; @@ -569,7 +569,7 @@ /* Copy over all the Python digits. It's crucial that every Python digit except for the MSD contribute - exactly SHIFT bits to the total, so first assert that the long is + exactly PyLong_SHIFT bits to the total, so first assert that the long is normalized. */ assert(ndigits == 0 || v->ob_digit[ndigits - 1] != 0); j = 0; @@ -579,15 +579,15 @@ for (i = 0; i < ndigits; ++i) { twodigits thisdigit = v->ob_digit[i]; if (do_twos_comp) { - thisdigit = (thisdigit ^ MASK) + carry; - carry = thisdigit >> SHIFT; - thisdigit &= MASK; + thisdigit = (thisdigit ^ PyLong_MASK) + carry; + carry = thisdigit >> PyLong_SHIFT; + thisdigit &= PyLong_MASK; } /* Because we're going LSB to MSB, thisdigit is more significant than what's already in accum, so needs to be prepended to accum. */ accum |= thisdigit << accumbits; - accumbits += SHIFT; + accumbits += PyLong_SHIFT; /* The most-significant digit may be (probably is) at least partly empty. */ @@ -598,9 +598,9 @@ * First shift conceptual sign bit to real sign bit. */ stwodigits s = (stwodigits)(thisdigit << - (8*sizeof(stwodigits) - SHIFT)); + (8*sizeof(stwodigits) - PyLong_SHIFT)); unsigned int nsignbits = 0; - while ((s < 0) == do_twos_comp && nsignbits < SHIFT) { + while ((s < 0) == do_twos_comp && nsignbits < PyLong_SHIFT) { ++nsignbits; s <<= 1; } @@ -680,7 +680,7 @@ #define NBITS_WANTED 57 PyLongObject *v; double x; - const double multiplier = (double)(1L << SHIFT); + const double multiplier = (double)(1L << PyLong_SHIFT); Py_ssize_t i; int sign; int nbitsneeded; @@ -707,10 +707,10 @@ while (i > 0 && nbitsneeded > 0) { --i; x = x * multiplier + (double)v->ob_digit[i]; - nbitsneeded -= SHIFT; + nbitsneeded -= PyLong_SHIFT; } /* There are i digits we didn't shift in. Pretending they're all - zeroes, the true value is x * 2**(i*SHIFT). */ + zeroes, the true value is x * 2**(i*PyLong_SHIFT). */ *exponent = i; assert(x > 0.0); return x * sign; @@ -735,10 +735,10 @@ /* 'e' initialized to -1 to silence gcc-4.0.x, but it should be set correctly after a successful _PyLong_AsScaledDouble() call */ assert(e >= 0); - if (e > INT_MAX / SHIFT) + if (e > INT_MAX / PyLong_SHIFT) goto overflow; errno = 0; - x = ldexp(x, e * SHIFT); + x = ldexp(x, e * PyLong_SHIFT); if (Py_OVERFLOWED(x)) goto overflow; return x; @@ -846,7 +846,7 @@ t = (unsigned PY_LONG_LONG)ival; while (t) { ++ndigits; - t >>= SHIFT; + t >>= PyLong_SHIFT; } v = _PyLong_New(ndigits); if (v != NULL) { @@ -854,8 +854,8 @@ Py_SIZE(v) = negative ? -ndigits : ndigits; t = (unsigned PY_LONG_LONG)ival; while (t) { - *p++ = (digit)(t & MASK); - t >>= SHIFT; + *p++ = (digit)(t & PyLong_MASK); + t >>= PyLong_SHIFT; } } return (PyObject *)v; @@ -874,15 +874,15 @@ t = (unsigned PY_LONG_LONG)ival; while (t) { ++ndigits; - t >>= SHIFT; + t >>= PyLong_SHIFT; } v = _PyLong_New(ndigits); if (v != NULL) { digit *p = v->ob_digit; Py_SIZE(v) = ndigits; while (ival) { - *p++ = (digit)(ival & MASK); - ival >>= SHIFT; + *p++ = (digit)(ival & PyLong_MASK); + ival >>= PyLong_SHIFT; } } return (PyObject *)v; @@ -891,7 +891,7 @@ /* Create a new long int object from a C Py_ssize_t. */ PyObject * -_PyLong_FromSsize_t(Py_ssize_t ival) +PyLong_FromSsize_t(Py_ssize_t ival) { Py_ssize_t bytes = ival; int one = 1; @@ -903,7 +903,7 @@ /* Create a new long int object from a C size_t. */ PyObject * -_PyLong_FromSize_t(size_t ival) +PyLong_FromSize_t(size_t ival) { size_t bytes = ival; int one = 1; @@ -1015,7 +1015,7 @@ i = -i; } while (--i >= 0) { - x = (x << SHIFT) + v->ob_digit[i]; + x = (x << PyLong_SHIFT) + v->ob_digit[i]; } return x * sign; } @@ -1069,14 +1069,14 @@ assert(m >= n); for (i = 0; i < n; ++i) { carry += x[i] + y[i]; - x[i] = carry & MASK; - carry >>= SHIFT; + x[i] = carry & PyLong_MASK; + carry >>= PyLong_SHIFT; assert((carry & 1) == carry); } for (; carry && i < m; ++i) { carry += x[i]; - x[i] = carry & MASK; - carry >>= SHIFT; + x[i] = carry & PyLong_MASK; + carry >>= PyLong_SHIFT; assert((carry & 1) == carry); } return carry; @@ -1095,14 +1095,14 @@ assert(m >= n); for (i = 0; i < n; ++i) { borrow = x[i] - y[i] - borrow; - x[i] = borrow & MASK; - borrow >>= SHIFT; + x[i] = borrow & PyLong_MASK; + borrow >>= PyLong_SHIFT; borrow &= 1; /* keep only 1 sign bit */ } for (; borrow && i < m; ++i) { borrow = x[i] - borrow; - x[i] = borrow & MASK; - borrow >>= SHIFT; + x[i] = borrow & PyLong_MASK; + borrow >>= PyLong_SHIFT; borrow &= 1; } return borrow; @@ -1130,8 +1130,8 @@ return NULL; for (i = 0; i < size_a; ++i) { carry += (twodigits)a->ob_digit[i] * n; - z->ob_digit[i] = (digit) (carry & MASK); - carry >>= SHIFT; + z->ob_digit[i] = (digit) (carry & PyLong_MASK); + carry >>= PyLong_SHIFT; } z->ob_digit[i] = (digit) carry; return long_normalize(z); @@ -1148,12 +1148,12 @@ { twodigits rem = 0; - assert(n > 0 && n <= MASK); + assert(n > 0 && n <= PyLong_MASK); pin += size; pout += size; while (--size >= 0) { digit hi; - rem = (rem << SHIFT) + *--pin; + rem = (rem << PyLong_SHIFT) + *--pin; *--pout = hi = (digit)(rem / n); rem -= hi * n; } @@ -1170,7 +1170,7 @@ const Py_ssize_t size = ABS(Py_SIZE(a)); PyLongObject *z; - assert(n > 0 && n <= MASK); + assert(n > 0 && n <= PyLong_MASK); z = _PyLong_New(size); if (z == NULL) return NULL; @@ -1208,9 +1208,9 @@ i >>= 1; } i = 5 + (addL ? 1 : 0); - j = size_a*SHIFT + bits-1; + j = size_a*PyLong_SHIFT + bits-1; sz = i + j / bits; - if (j / SHIFT < size_a || sz < i) { + if (j / PyLong_SHIFT < size_a || sz < i) { PyErr_SetString(PyExc_OverflowError, "long is too large to format"); return NULL; @@ -1239,7 +1239,7 @@ for (i = 0; i < size_a; ++i) { accum |= (twodigits)a->ob_digit[i] << accumbits; - accumbits += SHIFT; + accumbits += PyLong_SHIFT; assert(accumbits >= basebits); do { char cdigit = (char)(accum & (base - 1)); @@ -1264,7 +1264,7 @@ int power = 1; for (;;) { unsigned long newpow = powbase * (unsigned long)base; - if (newpow >> SHIFT) /* doesn't fit in a digit */ + if (newpow >> PyLong_SHIFT) /* doesn't fit in a digit */ break; powbase = (digit)newpow; ++power; @@ -1390,14 +1390,14 @@ while (_PyLong_DigitValue[Py_CHARMASK(*p)] < base) ++p; *str = p; - /* n <- # of Python digits needed, = ceiling(n/SHIFT). */ - n = (p - start) * bits_per_char + SHIFT - 1; + /* n <- # of Python digits needed, = ceiling(n/PyLong_SHIFT). */ + n = (p - start) * bits_per_char + PyLong_SHIFT - 1; if (n / bits_per_char < p - start) { PyErr_SetString(PyExc_ValueError, "long string too large to convert"); return NULL; } - n = n / SHIFT; + n = n / PyLong_SHIFT; z = _PyLong_New(n); if (z == NULL) return NULL; @@ -1412,16 +1412,16 @@ assert(k >= 0 && k < base); accum |= (twodigits)(k << bits_in_accum); bits_in_accum += bits_per_char; - if (bits_in_accum >= SHIFT) { - *pdigit++ = (digit)(accum & MASK); + if (bits_in_accum >= PyLong_SHIFT) { + *pdigit++ = (digit)(accum & PyLong_MASK); assert(pdigit - z->ob_digit <= (int)n); - accum >>= SHIFT; - bits_in_accum -= SHIFT; - assert(bits_in_accum < SHIFT); + accum >>= PyLong_SHIFT; + bits_in_accum -= PyLong_SHIFT; + assert(bits_in_accum < PyLong_SHIFT); } } if (bits_in_accum) { - assert(bits_in_accum <= SHIFT); + assert(bits_in_accum <= PyLong_SHIFT); *pdigit++ = (digit)accum; assert(pdigit - z->ob_digit <= (int)n); } @@ -1478,18 +1478,18 @@ is B**N-1. Consequently, if we have an N-digit input in base B, the worst- case number of Python digits needed to hold it is the smallest integer n s.t. - BASE**n-1 >= B**N-1 [or, adding 1 to both sides] - BASE**n >= B**N [taking logs to base BASE] - n >= log(B**N)/log(BASE) = N * log(B)/log(BASE) + PyLong_BASE**n-1 >= B**N-1 [or, adding 1 to both sides] + PyLong_BASE**n >= B**N [taking logs to base PyLong_BASE] + n >= log(B**N)/log(PyLong_BASE) = N * log(B)/log(PyLong_BASE) -The static array log_base_BASE[base] == log(base)/log(BASE) so we can compute +The static array log_base_PyLong_BASE[base] == log(base)/log(PyLong_BASE) so we can compute this quickly. A Python long with that much space is reserved near the start, and the result is computed into it. The input string is actually treated as being in base base**i (i.e., i digits are processed at a time), where two more static arrays hold: - convwidth_base[base] = the largest integer i such that base**i <= BASE + convwidth_base[base] = the largest integer i such that base**i <= PyLong_BASE convmultmax_base[base] = base ** convwidth_base[base] The first of these is the largest i such that i consecutive input digits @@ -1506,37 +1506,37 @@ Error analysis: as above, the number of Python digits `n` needed is worst- case - n >= N * log(B)/log(BASE) + n >= N * log(B)/log(PyLong_BASE) where `N` is the number of input digits in base `B`. This is computed via - size_z = (Py_ssize_t)((scan - str) * log_base_BASE[base]) + 1; + size_z = (Py_ssize_t)((scan - str) * log_base_PyLong_BASE[base]) + 1; below. Two numeric concerns are how much space this can waste, and whether -the computed result can be too small. To be concrete, assume BASE = 2**15, +the computed result can be too small. To be concrete, assume PyLong_BASE = 2**15, which is the default (and it's unlikely anyone changes that). Waste isn't a problem: provided the first input digit isn't 0, the difference between the worst-case input with N digits and the smallest input with N -digits is about a factor of B, but B is small compared to BASE so at most +digits is about a factor of B, but B is small compared to PyLong_BASE so at most one allocated Python digit can remain unused on that count. If -N*log(B)/log(BASE) is mathematically an exact integer, then truncating that +N*log(B)/log(PyLong_BASE) is mathematically an exact integer, then truncating that and adding 1 returns a result 1 larger than necessary. However, that can't happen: whenever B is a power of 2, long_from_binary_base() is called instead, and it's impossible for B**i to be an integer power of 2**15 when -B is not a power of 2 (i.e., it's impossible for N*log(B)/log(BASE) to be +B is not a power of 2 (i.e., it's impossible for N*log(B)/log(PyLong_BASE) to be an exact integer when B is not a power of 2, since B**i has a prime factor other than 2 in that case, but (2**15)**j's only prime factor is 2). -The computed result can be too small if the true value of N*log(B)/log(BASE) +The computed result can be too small if the true value of N*log(B)/log(PyLong_BASE) is a little bit larger than an exact integer, but due to roundoff errors (in -computing log(B), log(BASE), their quotient, and/or multiplying that by N) +computing log(B), log(PyLong_BASE), their quotient, and/or multiplying that by N) yields a numeric result a little less than that integer. Unfortunately, "how close can a transcendental function get to an integer over some range?" questions are generally theoretically intractable. Computer analysis via -continued fractions is practical: expand log(B)/log(BASE) via continued +continued fractions is practical: expand log(B)/log(PyLong_BASE) via continued fractions, giving a sequence i/j of "the best" rational approximations. Then -j*log(B)/log(BASE) is approximately equal to (the integer) i. This shows that +j*log(B)/log(PyLong_BASE) is approximately equal to (the integer) i. This shows that we can get very close to being in trouble, but very rarely. For example, 76573 is a denominator in one of the continued-fraction approximations to log(10)/log(2**15), and indeed: @@ -1562,19 +1562,19 @@ digit *pz, *pzstop; char* scan; - static double log_base_BASE[37] = {0.0e0,}; + static double log_base_PyLong_BASE[37] = {0.0e0,}; static int convwidth_base[37] = {0,}; static twodigits convmultmax_base[37] = {0,}; - if (log_base_BASE[base] == 0.0) { + if (log_base_PyLong_BASE[base] == 0.0) { twodigits convmax = base; int i = 1; - log_base_BASE[base] = log((double)base) / - log((double)BASE); + log_base_PyLong_BASE[base] = log((double)base) / + log((double)PyLong_BASE); for (;;) { twodigits next = convmax * base; - if (next > BASE) + if (next > PyLong_BASE) break; convmax = next; ++i; @@ -1594,7 +1594,7 @@ * need to initialize z->ob_digit -- no slot is read up before * being stored into. */ - size_z = (Py_ssize_t)((scan - str) * log_base_BASE[base]) + 1; + size_z = (Py_ssize_t)((scan - str) * log_base_PyLong_BASE[base]) + 1; /* Uncomment next line to test exceedingly rare copy code */ /* size_z = 1; */ assert(size_z > 0); @@ -1616,7 +1616,7 @@ for (i = 1; i < convwidth && str != scan; ++i, ++str) { c = (twodigits)(c * base + _PyLong_DigitValue[Py_CHARMASK(*str)]); - assert(c < BASE); + assert(c < PyLong_BASE); } convmult = convmultmax; @@ -1634,12 +1634,12 @@ pzstop = pz + Py_SIZE(z); for (; pz < pzstop; ++pz) { c += (twodigits)*pz * convmult; - *pz = (digit)(c & MASK); - c >>= SHIFT; + *pz = (digit)(c & PyLong_MASK); + c >>= PyLong_SHIFT; } /* carry off the current end? */ if (c) { - assert(c < BASE); + assert(c < PyLong_BASE); if (Py_SIZE(z) < size_z) { *pz = (digit)c; ++Py_SIZE(z); @@ -1783,7 +1783,7 @@ x_divrem(PyLongObject *v1, PyLongObject *w1, PyLongObject **prem) { Py_ssize_t size_v = ABS(Py_SIZE(v1)), size_w = ABS(Py_SIZE(w1)); - digit d = (digit) ((twodigits)BASE / (w1->ob_digit[size_w-1] + 1)); + digit d = (digit) ((twodigits)PyLong_BASE / (w1->ob_digit[size_w-1] + 1)); PyLongObject *v = mul1(v1, d); PyLongObject *w = mul1(w1, d); PyLongObject *a; @@ -1815,28 +1815,28 @@ break; }) if (vj == w->ob_digit[size_w-1]) - q = MASK; + q = PyLong_MASK; else - q = (((twodigits)vj << SHIFT) + v->ob_digit[j-1]) / + q = (((twodigits)vj << PyLong_SHIFT) + v->ob_digit[j-1]) / w->ob_digit[size_w-1]; while (w->ob_digit[size_w-2]*q > (( - ((twodigits)vj << SHIFT) + ((twodigits)vj << PyLong_SHIFT) + v->ob_digit[j-1] - q*w->ob_digit[size_w-1] - ) << SHIFT) + ) << PyLong_SHIFT) + v->ob_digit[j-2]) --q; for (i = 0; i < size_w && i+k < size_v; ++i) { twodigits z = w->ob_digit[i] * q; - digit zz = (digit) (z >> SHIFT); + digit zz = (digit) (z >> PyLong_SHIFT); carry += v->ob_digit[i+k] - z - + ((twodigits)zz << SHIFT); - v->ob_digit[i+k] = (digit)(carry & MASK); - carry = Py_ARITHMETIC_RIGHT_SHIFT(BASE_TWODIGITS_TYPE, - carry, SHIFT); + + ((twodigits)zz << PyLong_SHIFT); + v->ob_digit[i+k] = (digit)(carry & PyLong_MASK); + carry = Py_ARITHMETIC_RIGHT_SHIFT(PyLong_BASE_TWODIGITS_TYPE, + carry, PyLong_SHIFT); carry -= zz; } @@ -1853,10 +1853,10 @@ carry = 0; for (i = 0; i < size_w && i+k < size_v; ++i) { carry += v->ob_digit[i+k] + w->ob_digit[i]; - v->ob_digit[i+k] = (digit)(carry & MASK); + v->ob_digit[i+k] = (digit)(carry & PyLong_MASK); carry = Py_ARITHMETIC_RIGHT_SHIFT( - BASE_TWODIGITS_TYPE, - carry, SHIFT); + PyLong_BASE_TWODIGITS_TYPE, + carry, PyLong_SHIFT); } } } /* for j, k */ @@ -1940,13 +1940,13 @@ sign = -1; i = -(i); } -#define LONG_BIT_SHIFT (8*sizeof(long) - SHIFT) +#define LONG_BIT_PyLong_SHIFT (8*sizeof(long) - PyLong_SHIFT) /* The following loop produces a C long x such that (unsigned long)x is congruent to the absolute value of v modulo ULONG_MAX. The resulting x is nonzero if and only if v is. */ while (--i >= 0) { /* Force a native long #-bits (32 or 64) circular shift */ - x = ((x << SHIFT) & ~MASK) | ((x >> LONG_BIT_SHIFT) & MASK); + x = ((x << PyLong_SHIFT) & ~PyLong_MASK) | ((x >> LONG_BIT_PyLong_SHIFT) & PyLong_MASK); x += v->ob_digit[i]; /* If the addition above overflowed (thinking of x as unsigned), we compensate by incrementing. This preserves @@ -1954,7 +1954,7 @@ if ((unsigned long)x < v->ob_digit[i]) x++; } -#undef LONG_BIT_SHIFT +#undef LONG_BIT_PyLong_SHIFT x = x * sign; if (x == -1) x = -2; @@ -1984,13 +1984,13 @@ return NULL; for (i = 0; i < size_b; ++i) { carry += a->ob_digit[i] + b->ob_digit[i]; - z->ob_digit[i] = carry & MASK; - carry >>= SHIFT; + z->ob_digit[i] = carry & PyLong_MASK; + carry >>= PyLong_SHIFT; } for (; i < size_a; ++i) { carry += a->ob_digit[i]; - z->ob_digit[i] = carry & MASK; - carry >>= SHIFT; + z->ob_digit[i] = carry & PyLong_MASK; + carry >>= PyLong_SHIFT; } z->ob_digit[i] = carry; return long_normalize(z); @@ -2033,16 +2033,16 @@ return NULL; for (i = 0; i < size_b; ++i) { /* The following assumes unsigned arithmetic - works module 2**N for some N>SHIFT. */ + works module 2**N for some N>PyLong_SHIFT. */ borrow = a->ob_digit[i] - b->ob_digit[i] - borrow; - z->ob_digit[i] = borrow & MASK; - borrow >>= SHIFT; + z->ob_digit[i] = borrow & PyLong_MASK; + borrow >>= PyLong_SHIFT; borrow &= 1; /* Keep only one sign bit */ } for (; i < size_a; ++i) { borrow = a->ob_digit[i] - borrow; - z->ob_digit[i] = borrow & MASK; - borrow >>= SHIFT; + z->ob_digit[i] = borrow & PyLong_MASK; + borrow >>= PyLong_SHIFT; borrow &= 1; /* Keep only one sign bit */ } assert(borrow == 0); @@ -2140,9 +2140,9 @@ }) carry = *pz + f * f; - *pz++ = (digit)(carry & MASK); - carry >>= SHIFT; - assert(carry <= MASK); + *pz++ = (digit)(carry & PyLong_MASK); + carry >>= PyLong_SHIFT; + assert(carry <= PyLong_MASK); /* Now f is added in twice in each column of the * pyramid it appears. Same as adding f<<1 once. @@ -2150,18 +2150,18 @@ f <<= 1; while (pa < paend) { carry += *pz + *pa++ * f; - *pz++ = (digit)(carry & MASK); - carry >>= SHIFT; - assert(carry <= (MASK << 1)); + *pz++ = (digit)(carry & PyLong_MASK); + carry >>= PyLong_SHIFT; + assert(carry <= (PyLong_MASK << 1)); } if (carry) { carry += *pz; - *pz++ = (digit)(carry & MASK); - carry >>= SHIFT; + *pz++ = (digit)(carry & PyLong_MASK); + carry >>= PyLong_SHIFT; } if (carry) - *pz += (digit)(carry & MASK); - assert((carry >> SHIFT) == 0); + *pz += (digit)(carry & PyLong_MASK); + assert((carry >> PyLong_SHIFT) == 0); } } else { /* a is not the same as b -- gradeschool long mult */ @@ -2179,13 +2179,13 @@ while (pb < pbend) { carry += *pz + *pb++ * f; - *pz++ = (digit)(carry & MASK); - carry >>= SHIFT; - assert(carry <= MASK); + *pz++ = (digit)(carry & PyLong_MASK); + carry >>= PyLong_SHIFT; + assert(carry <= PyLong_MASK); } if (carry) - *pz += (digit)(carry & MASK); - assert((carry >> SHIFT) == 0); + *pz += (digit)(carry & PyLong_MASK); + assert((carry >> PyLong_SHIFT) == 0); } } return long_normalize(z); @@ -2304,7 +2304,7 @@ * 4. Subtract al*bl from the result, starting at shift. This may * underflow (borrow out of the high digit), but we don't care: * we're effectively doing unsigned arithmetic mod - * BASE**(sizea + sizeb), and so long as the *final* result fits, + * PyLong_BASE**(sizea + sizeb), and so long as the *final* result fits, * borrows and carries out of the high digit can be ignored. * 5. Subtract ah*bh from the result, starting at shift. * 6. Compute (ah+al)*(bh+bl), and add it into the result starting @@ -2431,7 +2431,7 @@ (asize == bsize ? c(bsize/2) : f(bsize/2)) digits + 2 bits. If asize < bsize, then we're asking whether asize digits >= f(bsize/2) digits + 2 bits. By #4, asize is at least f(bsize/2)+1 digits, so this in turn reduces to whether 1 -digit is enough to hold 2 bits. This is so since SHIFT=15 >= 2. If +digit is enough to hold 2 bits. This is so since PyLong_SHIFT=15 >= 2. If asize == bsize, then we're asking whether bsize digits is enough to hold c(bsize/2) digits + 2 bits, or equivalently (by #1) whether f(bsize/2) digits is enough to hold 2 bits. This is so if bsize >= 2, which holds because @@ -2643,15 +2643,15 @@ return NULL; } - /* True value is very close to ad/bd * 2**(SHIFT*(aexp-bexp)) */ + /* True value is very close to ad/bd * 2**(PyLong_SHIFT*(aexp-bexp)) */ ad /= bd; /* overflow/underflow impossible here */ aexp -= bexp; - if (aexp > INT_MAX / SHIFT) + if (aexp > INT_MAX / PyLong_SHIFT) goto overflow; - else if (aexp < -(INT_MAX / SHIFT)) + else if (aexp < -(INT_MAX / PyLong_SHIFT)) return PyFloat_FromDouble(0.0); /* underflow to 0 */ errno = 0; - ad = ldexp(ad, aexp * SHIFT); + ad = ldexp(ad, aexp * PyLong_SHIFT); if (Py_OVERFLOWED(ad)) /* ignore underflow to 0.0 */ goto overflow; return PyFloat_FromDouble(ad); @@ -2837,7 +2837,7 @@ for (i = Py_SIZE(b) - 1; i >= 0; --i) { digit bi = b->ob_digit[i]; - for (j = 1 << (SHIFT-1); j != 0; j >>= 1) { + for (j = 1 << (PyLong_SHIFT-1); j != 0; j >>= 1) { MULT(z, z, z) if (bi & j) MULT(z, a, z) @@ -2854,7 +2854,7 @@ for (i = Py_SIZE(b) - 1; i >= 0; --i) { const digit bi = b->ob_digit[i]; - for (j = SHIFT - 5; j >= 0; j -= 5) { + for (j = PyLong_SHIFT - 5; j >= 0; j -= 5) { const int index = (bi >> j) & 0x1f; for (k = 0; k < 5; ++k) MULT(z, z, z) @@ -2973,7 +2973,7 @@ "negative shift count"); goto rshift_error; } - wordshift = shiftby / SHIFT; + wordshift = shiftby / PyLong_SHIFT; newsize = ABS(Py_SIZE(a)) - wordshift; if (newsize <= 0) { z = _PyLong_New(0); @@ -2981,10 +2981,10 @@ Py_DECREF(b); return (PyObject *)z; } - loshift = shiftby % SHIFT; - hishift = SHIFT - loshift; + loshift = shiftby % PyLong_SHIFT; + hishift = PyLong_SHIFT - loshift; lomask = ((digit)1 << hishift) - 1; - himask = MASK ^ lomask; + himask = PyLong_MASK ^ lomask; z = _PyLong_New(newsize); if (z == NULL) goto rshift_error; @@ -3029,9 +3029,9 @@ "outrageous left shift count"); goto lshift_error; } - /* wordshift, remshift = divmod(shiftby, SHIFT) */ - wordshift = (int)shiftby / SHIFT; - remshift = (int)shiftby - wordshift * SHIFT; + /* wordshift, remshift = divmod(shiftby, PyLong_SHIFT) */ + wordshift = (int)shiftby / PyLong_SHIFT; + remshift = (int)shiftby - wordshift * PyLong_SHIFT; oldsize = ABS(a->ob_size); newsize = oldsize + wordshift; @@ -3047,8 +3047,8 @@ accum = 0; for (i = wordshift, j = 0; j < oldsize; i++, j++) { accum |= (twodigits)a->ob_digit[j] << remshift; - z->ob_digit[i] = (digit)(accum & MASK); - accum >>= SHIFT; + z->ob_digit[i] = (digit)(accum & PyLong_MASK); + accum >>= PyLong_SHIFT; } if (remshift) z->ob_digit[newsize-1] = (digit)accum; @@ -3069,7 +3069,7 @@ int op, /* '&', '|', '^' */ PyLongObject *b) { - digit maska, maskb; /* 0 or MASK */ + digit maska, maskb; /* 0 or PyLong_MASK */ int negz; Py_ssize_t size_a, size_b, size_z; PyLongObject *z; @@ -3081,7 +3081,7 @@ a = (PyLongObject *) long_invert(a); if (a == NULL) return NULL; - maska = MASK; + maska = PyLong_MASK; } else { Py_INCREF(a); @@ -3093,7 +3093,7 @@ Py_DECREF(a); return NULL; } - maskb = MASK; + maskb = PyLong_MASK; } else { Py_INCREF(b); @@ -3104,23 +3104,23 @@ switch (op) { case '^': if (maska != maskb) { - maska ^= MASK; + maska ^= PyLong_MASK; negz = -1; } break; case '&': if (maska && maskb) { op = '|'; - maska ^= MASK; - maskb ^= MASK; + maska ^= PyLong_MASK; + maskb ^= PyLong_MASK; negz = -1; } break; case '|': if (maska || maskb) { op = '&'; - maska ^= MASK; - maskb ^= MASK; + maska ^= PyLong_MASK; + maskb ^= PyLong_MASK; negz = -1; } break; Modified: python/trunk/Objects/unicodeobject.c ============================================================================== --- python/trunk/Objects/unicodeobject.c (original) +++ python/trunk/Objects/unicodeobject.c Fri Jan 25 13:18:43 2008 @@ -397,6 +397,57 @@ return (PyObject *)unicode; } +PyObject *PyUnicode_FromStringAndSize(const char *u, Py_ssize_t size) +{ + PyUnicodeObject *unicode; + /* If the Unicode data is known at construction time, we can apply + some optimizations which share commonly used objects. + Also, this means the input must be UTF-8, so fall back to the + UTF-8 decoder at the end. */ + if (u != NULL) { + + /* Optimization for empty strings */ + if (size == 0 && unicode_empty != NULL) { + Py_INCREF(unicode_empty); + return (PyObject *)unicode_empty; + } + + /* Single characters are shared when using this constructor. + Restrict to ASCII, since the input must be UTF-8. */ + if (size == 1 && Py_CHARMASK(*u) < 128) { + unicode = unicode_latin1[Py_CHARMASK(*u)]; + if (!unicode) { + unicode = _PyUnicode_New(1); + if (!unicode) + return NULL; + unicode->str[0] = Py_CHARMASK(*u); + unicode_latin1[Py_CHARMASK(*u)] = unicode; + } + Py_INCREF(unicode); + return (PyObject *)unicode; + } + + return PyUnicode_DecodeUTF8(u, size, NULL); + } + + unicode = _PyUnicode_New(size); + if (!unicode) + return NULL; + + return (PyObject *)unicode; +} + +PyObject *PyUnicode_FromString(const char *u) +{ + size_t size = strlen(u); + if (size > PY_SSIZE_T_MAX) { + PyErr_SetString(PyExc_OverflowError, "input too long"); + return NULL; + } + + return PyUnicode_FromStringAndSize(u, size); +} + #ifdef HAVE_WCHAR_H PyObject *PyUnicode_FromWideChar(register const wchar_t *w, @@ -429,6 +480,420 @@ return (PyObject *)unicode; } +static void +makefmt(char *fmt, int longflag, int size_tflag, int zeropad, int width, int precision, char c) +{ + *fmt++ = '%'; + if (width) { + if (zeropad) + *fmt++ = '0'; + fmt += sprintf(fmt, "%d", width); + } + if (precision) + fmt += sprintf(fmt, ".%d", precision); + if (longflag) + *fmt++ = 'l'; + else if (size_tflag) { + char *f = PY_FORMAT_SIZE_T; + while (*f) + *fmt++ = *f++; + } + *fmt++ = c; + *fmt = '\0'; +} + +#define appendstring(string) {for (copy = string;*copy;) *s++ = *copy++;} + +PyObject * +PyUnicode_FromFormatV(const char *format, va_list vargs) +{ + va_list count; + Py_ssize_t callcount = 0; + PyObject **callresults = NULL; + PyObject **callresult = NULL; + Py_ssize_t n = 0; + int width = 0; + int precision = 0; + int zeropad; + const char* f; + Py_UNICODE *s; + PyObject *string; + /* used by sprintf */ + char buffer[21]; + /* use abuffer instead of buffer, if we need more space + * (which can happen if there's a format specifier with width). */ + char *abuffer = NULL; + char *realbuffer; + Py_ssize_t abuffersize = 0; + char fmt[60]; /* should be enough for %0width.precisionld */ + const char *copy; + +#ifdef VA_LIST_IS_ARRAY + Py_MEMCPY(count, vargs, sizeof(va_list)); +#else +#ifdef __va_copy + __va_copy(count, vargs); +#else + count = vargs; +#endif +#endif + /* step 1: count the number of %S/%R format specifications + * (we call PyObject_Str()/PyObject_Repr() for these objects + * once during step 3 and put the result in an array) */ + for (f = format; *f; f++) { + if (*f == '%' && (*(f+1)=='S' || *(f+1)=='R')) + ++callcount; + } + /* step 2: allocate memory for the results of + * PyObject_Str()/PyObject_Repr() calls */ + if (callcount) { + callresults = PyMem_Malloc(sizeof(PyObject *)*callcount); + if (!callresults) { + PyErr_NoMemory(); + return NULL; + } + callresult = callresults; + } + /* step 3: figure out how large a buffer we need */ + for (f = format; *f; f++) { + if (*f == '%') { + const char* p = f; + width = 0; + while (isdigit(*f)) + width = (width*10) + *f++ - '0'; + while (*++f && *f != '%' && !isalpha(*f)) + ; + + /* skip the 'l' or 'z' in {%ld, %zd, %lu, %zu} since + * they don't affect the amount of space we reserve. + */ + if ((*f == 'l' || *f == 'z') && + (f[1] == 'd' || f[1] == 'u')) + ++f; + + switch (*f) { + case 'c': + (void)va_arg(count, int); + /* fall through... */ + case '%': + n++; + break; + case 'd': case 'u': case 'i': case 'x': + (void) va_arg(count, int); + /* 20 bytes is enough to hold a 64-bit + integer. Decimal takes the most space. + This isn't enough for octal. + If a width is specified we need more + (which we allocate later). */ + if (width < 20) + width = 20; + n += width; + if (abuffersize < width) + abuffersize = width; + break; + case 's': + { + /* UTF-8 */ + unsigned char*s; + s = va_arg(count, unsigned char*); + while (*s) { + if (*s < 128) { + n++; s++; + } else if (*s < 0xc0) { + /* invalid UTF-8 */ + n++; s++; + } else if (*s < 0xc0) { + n++; + s++; if(!*s)break; + s++; + } else if (*s < 0xe0) { + n++; + s++; if(!*s)break; + s++; if(!*s)break; + s++; + } else { + #ifdef Py_UNICODE_WIDE + n++; + #else + n+=2; + #endif + s++; if(!*s)break; + s++; if(!*s)break; + s++; if(!*s)break; + s++; + } + } + break; + } + case 'U': + { + PyObject *obj = va_arg(count, PyObject *); + assert(obj && PyUnicode_Check(obj)); + n += PyUnicode_GET_SIZE(obj); + break; + } + case 'V': + { + PyObject *obj = va_arg(count, PyObject *); + const char *str = va_arg(count, const char *); + assert(obj || str); + assert(!obj || PyUnicode_Check(obj)); + if (obj) + n += PyUnicode_GET_SIZE(obj); + else + n += strlen(str); + break; + } + case 'S': + { + PyObject *obj = va_arg(count, PyObject *); + PyObject *str; + assert(obj); + str = PyObject_Str(obj); + if (!str) + goto fail; + n += PyUnicode_GET_SIZE(str); + /* Remember the str and switch to the next slot */ + *callresult++ = str; + break; + } + case 'R': + { + PyObject *obj = va_arg(count, PyObject *); + PyObject *repr; + assert(obj); + repr = PyObject_Repr(obj); + if (!repr) + goto fail; + n += PyUnicode_GET_SIZE(repr); + /* Remember the repr and switch to the next slot */ + *callresult++ = repr; + break; + } + case 'p': + (void) va_arg(count, int); + /* maximum 64-bit pointer representation: + * 0xffffffffffffffff + * so 19 characters is enough. + * XXX I count 18 -- what's the extra for? + */ + n += 19; + break; + default: + /* if we stumble upon an unknown + formatting code, copy the rest of + the format string to the output + string. (we cannot just skip the + code, since there's no way to know + what's in the argument list) */ + n += strlen(p); + goto expand; + } + } else + n++; + } + expand: + if (abuffersize > 20) { + abuffer = PyMem_Malloc(abuffersize); + if (!abuffer) { + PyErr_NoMemory(); + goto fail; + } + realbuffer = abuffer; + } + else + realbuffer = buffer; + /* step 4: fill the buffer */ + /* Since we've analyzed how much space we need for the worst case, + we don't have to resize the string. + There can be no errors beyond this point. */ + string = PyUnicode_FromUnicode(NULL, n); + if (!string) + goto fail; + + s = PyUnicode_AS_UNICODE(string); + callresult = callresults; + + for (f = format; *f; f++) { + if (*f == '%') { + const char* p = f++; + int longflag = 0; + int size_tflag = 0; + zeropad = (*f == '0'); + /* parse the width.precision part */ + width = 0; + while (isdigit(*f)) + width = (width*10) + *f++ - '0'; + precision = 0; + if (*f == '.') { + f++; + while (isdigit(*f)) + precision = (precision*10) + *f++ - '0'; + } + /* handle the long flag, but only for %ld and %lu. + others can be added when necessary. */ + if (*f == 'l' && (f[1] == 'd' || f[1] == 'u')) { + longflag = 1; + ++f; + } + /* handle the size_t flag. */ + if (*f == 'z' && (f[1] == 'd' || f[1] == 'u')) { + size_tflag = 1; + ++f; + } + + switch (*f) { + case 'c': + *s++ = va_arg(vargs, int); + break; + case 'd': + makefmt(fmt, longflag, size_tflag, zeropad, width, precision, 'd'); + if (longflag) + sprintf(realbuffer, fmt, va_arg(vargs, long)); + else if (size_tflag) + sprintf(realbuffer, fmt, va_arg(vargs, Py_ssize_t)); + else + sprintf(realbuffer, fmt, va_arg(vargs, int)); + appendstring(realbuffer); + break; + case 'u': + makefmt(fmt, longflag, size_tflag, zeropad, width, precision, 'u'); + if (longflag) + sprintf(realbuffer, fmt, va_arg(vargs, unsigned long)); + else if (size_tflag) + sprintf(realbuffer, fmt, va_arg(vargs, size_t)); + else + sprintf(realbuffer, fmt, va_arg(vargs, unsigned int)); + appendstring(realbuffer); + break; + case 'i': + makefmt(fmt, 0, 0, zeropad, width, precision, 'i'); + sprintf(realbuffer, fmt, va_arg(vargs, int)); + appendstring(realbuffer); + break; + case 'x': + makefmt(fmt, 0, 0, zeropad, width, precision, 'x'); + sprintf(realbuffer, fmt, va_arg(vargs, int)); + appendstring(realbuffer); + break; + case 's': + { + /* Parameter must be UTF-8 encoded. + In case of encoding errors, use + the replacement character. */ + PyObject *u; + p = va_arg(vargs, char*); + u = PyUnicode_DecodeUTF8(p, strlen(p), + "replace"); + if (!u) + goto fail; + Py_UNICODE_COPY(s, PyUnicode_AS_UNICODE(u), + PyUnicode_GET_SIZE(u)); + s += PyUnicode_GET_SIZE(u); + Py_DECREF(u); + break; + } + case 'U': + { + PyObject *obj = va_arg(vargs, PyObject *); + Py_ssize_t size = PyUnicode_GET_SIZE(obj); + Py_UNICODE_COPY(s, PyUnicode_AS_UNICODE(obj), size); + s += size; + break; + } + case 'V': + { + PyObject *obj = va_arg(vargs, PyObject *); + const char *str = va_arg(vargs, const char *); + if (obj) { + Py_ssize_t size = PyUnicode_GET_SIZE(obj); + Py_UNICODE_COPY(s, PyUnicode_AS_UNICODE(obj), size); + s += size; + } else { + appendstring(str); + } + break; + } + case 'S': + case 'R': + { + Py_UNICODE *ucopy; + Py_ssize_t usize; + Py_ssize_t upos; + /* unused, since we already have the result */ + (void) va_arg(vargs, PyObject *); + ucopy = PyUnicode_AS_UNICODE(*callresult); + usize = PyUnicode_GET_SIZE(*callresult); + for (upos = 0; upos forget it */ + Py_DECREF(*callresult); + /* switch to next unicode()/repr() result */ + ++callresult; + break; + } + case 'p': + sprintf(buffer, "%p", va_arg(vargs, void*)); + /* %p is ill-defined: ensure leading 0x. */ + if (buffer[1] == 'X') + buffer[1] = 'x'; + else if (buffer[1] != 'x') { + memmove(buffer+2, buffer, strlen(buffer)+1); + buffer[0] = '0'; + buffer[1] = 'x'; + } + appendstring(buffer); + break; + case '%': + *s++ = '%'; + break; + default: + appendstring(p); + goto end; + } + } else + *s++ = *f; + } + + end: + if (callresults) + PyMem_Free(callresults); + if (abuffer) + PyMem_Free(abuffer); + _PyUnicode_Resize(&string, s - PyUnicode_AS_UNICODE(string)); + return string; + fail: + if (callresults) { + PyObject **callresult2 = callresults; + while (callresult2 < callresult) { + Py_DECREF(*callresult2); + ++callresult2; + } + PyMem_Free(callresults); + } + if (abuffer) + PyMem_Free(abuffer); + return NULL; +} + +#undef appendstring + +PyObject * +PyUnicode_FromFormat(const char *format, ...) +{ + PyObject* ret; + va_list vargs; + +#ifdef HAVE_STDARG_PROTOTYPES + va_start(vargs, format); +#else + va_start(vargs); +#endif + ret = PyUnicode_FromFormatV(format, vargs); + va_end(vargs); + return ret; +} + Py_ssize_t PyUnicode_AsWideChar(PyUnicodeObject *unicode, wchar_t *w, Py_ssize_t size) Modified: python/trunk/setup.py ============================================================================== --- python/trunk/setup.py (original) +++ python/trunk/setup.py Fri Jan 25 13:18:43 2008 @@ -420,6 +420,8 @@ exts.append( Extension("_heapq", ["_heapqmodule.c"]) ) # operator.add() and similar goodies exts.append( Extension('operator', ['operator.c']) ) + # Python 3.0 _fileio module + exts.append( Extension("_fileio", ["_fileio.c"]) ) # _functools exts.append( Extension("_functools", ["_functoolsmodule.c"]) ) # Python C API test module From buildbot at python.org Fri Jan 25 13:25:41 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 25 Jan 2008 12:25:41 +0000 Subject: [Python-checkins] buildbot failure in x86 mvlgcc trunk Message-ID: <20080125122541.506B81E400F@bag.python.org> The Buildbot has detected a new failure of x86 mvlgcc trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20mvlgcc%20trunk/builds/1318 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-linux Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "./Lib/test/regrtest.py", line 127, in import random File "/home2/buildbot/slave/trunk.loewis-linux/build/Lib/random.py", line 43, in from math import log as _log, exp as _exp, pi as _pi, e as _e, ceil as _ceil ImportError: No module named math make: *** [buildbottest] Fehler 1 sincerely, -The Buildbot From buildbot at python.org Fri Jan 25 13:25:51 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 25 Jan 2008 12:25:51 +0000 Subject: [Python-checkins] buildbot failure in x86 gentoo trunk Message-ID: <20080125122551.3B4AB1E400F@bag.python.org> The Buildbot has detected a new failure of x86 gentoo trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20gentoo%20trunk/builds/2948 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-x86 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "./Lib/test/regrtest.py", line 127, in import random File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/random.py", line 43, in from math import log as _log, exp as _exp, pi as _pi, e as _e, ceil as _ceil ImportError: No module named math make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Fri Jan 25 13:26:19 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 25 Jan 2008 12:26:19 +0000 Subject: [Python-checkins] buildbot failure in amd64 gentoo trunk Message-ID: <20080125122619.AE7901E400F@bag.python.org> The Buildbot has detected a new failure of amd64 gentoo trunk. Full details are available at: http://www.python.org/dev/buildbot/all/amd64%20gentoo%20trunk/builds/21 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-amd64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "./Lib/test/regrtest.py", line 127, in import random File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/random.py", line 43, in from math import log as _log, exp as _exp, pi as _pi, e as _e, ceil as _ceil ImportError: No module named math make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Fri Jan 25 13:27:09 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 25 Jan 2008 12:27:09 +0000 Subject: [Python-checkins] buildbot failure in sparc solaris10 gcc trunk Message-ID: <20080125122709.E397B1E400F@bag.python.org> The Buildbot has detected a new failure of sparc solaris10 gcc trunk. Full details are available at: http://www.python.org/dev/buildbot/all/sparc%20solaris10%20gcc%20trunk/builds/2705 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-sun Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "./Lib/test/regrtest.py", line 127, in import random File "/opt/users/buildbot/slave/trunk.loewis-sun/build/Lib/random.py", line 43, in from math import log as _log, exp as _exp, pi as _pi, e as _e, ceil as _ceil ImportError: No module named math sincerely, -The Buildbot From buildbot at python.org Fri Jan 25 13:29:14 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 25 Jan 2008 12:29:14 +0000 Subject: [Python-checkins] buildbot failure in g4 osx.4 trunk Message-ID: <20080125122914.A11EB1E43AB@bag.python.org> The Buildbot has detected a new failure of g4 osx.4 trunk. Full details are available at: http://www.python.org/dev/buildbot/all/g4%20osx.4%20trunk/builds/2700 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: psf-g4 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "./Lib/test/regrtest.py", line 127, in import random File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/random.py", line 43, in from math import log as _log, exp as _exp, pi as _pi, e as _e, ceil as _ceil ImportError: No module named math make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Fri Jan 25 14:15:26 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 25 Jan 2008 13:15:26 +0000 Subject: [Python-checkins] buildbot failure in x86 FreeBSD trunk Message-ID: <20080125131527.00DBE1E400F@bag.python.org> The Buildbot has detected a new failure of x86 FreeBSD trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20FreeBSD%20trunk/builds/468 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-freebsd Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "./Lib/test/regrtest.py", line 127, in import random File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/random.py", line 43, in from math import log as _log, exp as _exp, pi as _pi, e as _e, ceil as _ceil ImportError: No module named math sincerely, -The Buildbot From python-checkins at python.org Fri Jan 25 15:54:23 2008 From: python-checkins at python.org (christian.heimes) Date: Fri, 25 Jan 2008 15:54:23 +0100 (CET) Subject: [Python-checkins] r60286 - python/trunk/Modules/mathmodule.c Message-ID: <20080125145423.98EA41E4015@bag.python.org> Author: christian.heimes Date: Fri Jan 25 15:54:23 2008 New Revision: 60286 Modified: python/trunk/Modules/mathmodule.c Log: setup.py doesn't pick up changes to a header file Modified: python/trunk/Modules/mathmodule.c ============================================================================== --- python/trunk/Modules/mathmodule.c (original) +++ python/trunk/Modules/mathmodule.c Fri Jan 25 15:54:23 2008 @@ -240,11 +240,11 @@ "math domain error"); return NULL; } - /* Value is ~= x * 2**(e*SHIFT), so the log ~= - log(x) + log(2) * e * SHIFT. - CAUTION: e*SHIFT may overflow using int arithmetic, + /* Value is ~= x * 2**(e*PyLong_SHIFT), so the log ~= + log(x) + log(2) * e * PyLong_SHIFT. + CAUTION: e*PyLong_SHIFT may overflow using int arithmetic, so force use of double. */ - x = func(x) + (e * (double)SHIFT) * func(2.0); + x = func(x) + (e * (double)PyLong_SHIFT) * func(2.0); return PyFloat_FromDouble(x); } From python-checkins at python.org Fri Jan 25 16:52:11 2008 From: python-checkins at python.org (christian.heimes) Date: Fri, 25 Jan 2008 16:52:11 +0100 (CET) Subject: [Python-checkins] r60287 - python/trunk/setup.py Message-ID: <20080125155211.7DF3D1E400E@bag.python.org> Author: christian.heimes Date: Fri Jan 25 16:52:11 2008 New Revision: 60287 Modified: python/trunk/setup.py Log: Added the Python core headers Include/*.h and pyconfig.h as dependencies for the extensions in Modules/ It forces a rebuild of all extensions when a header files has been modified Modified: python/trunk/setup.py ============================================================================== --- python/trunk/setup.py (original) +++ python/trunk/setup.py Fri Jan 25 16:52:11 2008 @@ -4,6 +4,7 @@ __version__ = "$Revision$" import sys, os, imp, re, optparse +from glob import glob from distutils import log from distutils import sysconfig @@ -142,12 +143,20 @@ self.distribution.scripts = [os.path.join(srcdir, filename) for filename in self.distribution.scripts] + # Python header files + headers = glob("Include/*.h") + ["pyconfig.h"] + for ext in self.extensions[:]: ext.sources = [ find_module_file(filename, moddirlist) for filename in ext.sources ] if ext.depends is not None: ext.depends = [find_module_file(filename, alldirlist) for filename in ext.depends] + else: + ext.depends = [] + # re-compile extensions if a header file has been changed + ext.depends.extend(headers) + ext.include_dirs.append( '.' ) # to get config.h for incdir in incdirlist: ext.include_dirs.append( os.path.join(srcdir, incdir) ) From buildbot at python.org Fri Jan 25 17:22:32 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 25 Jan 2008 16:22:32 +0000 Subject: [Python-checkins] buildbot failure in amd64 gentoo trunk Message-ID: <20080125162232.DD4031E400E@bag.python.org> The Buildbot has detected a new failure of amd64 gentoo trunk. Full details are available at: http://www.python.org/dev/buildbot/all/amd64%20gentoo%20trunk/builds/23 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-amd64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30995, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_thread.py", line 260, in writerThread self.assertEqual(data, self.makeData(key)) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/unittest.py", line 343, in failUnlessEqual (msg or '%r != %r' % (first, second)) AssertionError: None != '2000-2000-2000-2000-2000' Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_thread.py", line 260, in writerThread self.assertEqual(data, self.makeData(key)) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/unittest.py", line 343, in failUnlessEqual (msg or '%r != %r' % (first, second)) AssertionError: None != '1001-1001-1001-1001-1001' Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_thread.py", line 260, in writerThread self.assertEqual(data, self.makeData(key)) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/unittest.py", line 343, in failUnlessEqual (msg or '%r != %r' % (first, second)) AssertionError: None != '0002-0002-0002-0002-0002' 1 test failed: test_urllibnet make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Fri Jan 25 20:21:08 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 25 Jan 2008 19:21:08 +0000 Subject: [Python-checkins] buildbot failure in hppa Ubuntu 2.5 Message-ID: <20080125192108.750FE1E402D@bag.python.org> The Buildbot has detected a new failure of hppa Ubuntu 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/hppa%20Ubuntu%202.5/builds/121 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-ubuntu-hppa Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: amaury.forgeotdarc,andrew.kuchling,christian.heimes,guido.van.rossum,martin.v.loewis,thomas.heller BUILD FAILED: failed test Excerpt from the test logfile: 2 tests failed: test_resource test_urllib2net Traceback (most recent call last): File "./Lib/test/regrtest.py", line 549, in runtest_inner the_package = __import__(abstest, globals(), locals(), []) File "/home/pybot/buildarea/2.5.klose-ubuntu-hppa/build/Lib/test/test_resource.py", line 42, in f.close() IOError: [Errno 27] File too large make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Fri Jan 25 20:24:47 2008 From: python-checkins at python.org (raymond.hettinger) Date: Fri, 25 Jan 2008 20:24:47 +0100 (CET) Subject: [Python-checkins] r60291 - in python/trunk: Lib/test/test_dict.py Objects/dictobject.c Objects/setobject.c Message-ID: <20080125192447.1E17F1E402B@bag.python.org> Author: raymond.hettinger Date: Fri Jan 25 20:24:46 2008 New Revision: 60291 Modified: python/trunk/Lib/test/test_dict.py python/trunk/Objects/dictobject.c python/trunk/Objects/setobject.c Log: Changes 54857 and 54840 broke code and were reverted in Py2.5 just before it was released, but that reversion never made it to the Py2.6 head. Modified: python/trunk/Lib/test/test_dict.py ============================================================================== --- python/trunk/Lib/test/test_dict.py (original) +++ python/trunk/Lib/test/test_dict.py Fri Jan 25 20:24:46 2008 @@ -200,14 +200,6 @@ self.assertRaises(ValueError, {}.update, [(1, 2, 3)]) - # SF #1615701: make d.update(m) honor __getitem__() and keys() in dict subclasses - class KeyUpperDict(dict): - def __getitem__(self, key): - return key.upper() - d.clear() - d.update(KeyUpperDict.fromkeys('abc')) - self.assertEqual(d, {'a':'A', 'b':'B', 'c':'C'}) - def test_fromkeys(self): self.assertEqual(dict.fromkeys('abc'), {'a':None, 'b':None, 'c':None}) d = {} Modified: python/trunk/Objects/dictobject.c ============================================================================== --- python/trunk/Objects/dictobject.c (original) +++ python/trunk/Objects/dictobject.c Fri Jan 25 20:24:46 2008 @@ -1406,7 +1406,7 @@ return -1; } mp = (PyDictObject*)a; - if (PyDict_CheckExact(b)) { + if (PyDict_Check(b)) { other = (PyDictObject*)b; if (other == mp || other->ma_used == 0) /* a.update(a) or a.update({}); nothing to do */ Modified: python/trunk/Objects/setobject.c ============================================================================== --- python/trunk/Objects/setobject.c (original) +++ python/trunk/Objects/setobject.c Fri Jan 25 20:24:46 2008 @@ -912,7 +912,7 @@ { PyObject *key, *it; - if (PyAnySet_CheckExact(other)) + if (PyAnySet_Check(other)) return set_merge(so, other); if (PyDict_CheckExact(other)) { @@ -1207,7 +1207,7 @@ if (result == NULL) return NULL; - if (PyAnySet_CheckExact(other)) { + if (PyAnySet_Check(other)) { Py_ssize_t pos = 0; setentry *entry; @@ -1398,7 +1398,7 @@ if ((PyObject *)so == other) return set_clear_internal(so); - if (PyAnySet_CheckExact(other)) { + if (PyAnySet_Check(other)) { setentry *entry; Py_ssize_t pos = 0; @@ -1447,7 +1447,7 @@ setentry *entry; Py_ssize_t pos = 0; - if (!PyAnySet_CheckExact(other) && !PyDict_CheckExact(other)) { + if (!PyAnySet_Check(other) && !PyDict_CheckExact(other)) { result = set_copy(so); if (result == NULL) return NULL; @@ -1554,7 +1554,7 @@ Py_RETURN_NONE; } - if (PyAnySet_CheckExact(other)) { + if (PyAnySet_Check(other)) { Py_INCREF(other); otherset = (PySetObject *)other; } else { @@ -1637,7 +1637,7 @@ setentry *entry; Py_ssize_t pos = 0; - if (!PyAnySet_CheckExact(other)) { + if (!PyAnySet_Check(other)) { PyObject *tmp, *result; tmp = make_new_set(&PySet_Type, other); if (tmp == NULL) @@ -1666,7 +1666,7 @@ { PyObject *tmp, *result; - if (!PyAnySet_CheckExact(other)) { + if (!PyAnySet_Check(other)) { tmp = make_new_set(&PySet_Type, other); if (tmp == NULL) return NULL; From python-checkins at python.org Fri Jan 25 20:42:37 2008 From: python-checkins at python.org (guido.van.rossum) Date: Fri, 25 Jan 2008 20:42:37 +0100 (CET) Subject: [Python-checkins] r60294 - python/branches/release25-maint/Objects/listobject.c Message-ID: <20080125194237.0ED081E400E@bag.python.org> Author: guido.van.rossum Date: Fri Jan 25 20:42:36 2008 New Revision: 60294 Modified: python/branches/release25-maint/Objects/listobject.c Log: Rewrite the list_inline_repeat overflow check slightly differently. Modified: python/branches/release25-maint/Objects/listobject.c ============================================================================== --- python/branches/release25-maint/Objects/listobject.c (original) +++ python/branches/release25-maint/Objects/listobject.c Fri Jan 25 20:42:36 2008 @@ -490,7 +490,7 @@ if (n && size/n != a->ob_size) return PyErr_NoMemory(); if (size == 0) - return PyList_New(0); + return PyList_New(0); np = (PyListObject *) PyList_New(size); if (np == NULL) return NULL; @@ -672,10 +672,11 @@ return (PyObject *)self; } - p = size*n; - if (p/n != size) + if (size > SSIZE_MAX / n) { return PyErr_NoMemory(); - if (list_resize(self, p) == -1) + } + + if (list_resize(self, size*n) == -1) return NULL; p = size; From python-checkins at python.org Fri Jan 25 20:50:27 2008 From: python-checkins at python.org (guido.van.rossum) Date: Fri, 25 Jan 2008 20:50:27 +0100 (CET) Subject: [Python-checkins] r60296 - python/trunk/Objects/listobject.c Message-ID: <20080125195027.5B6B61E4021@bag.python.org> Author: guido.van.rossum Date: Fri Jan 25 20:50:26 2008 New Revision: 60296 Modified: python/trunk/Objects/listobject.c Log: Rewrite the list_inline_repeat overflow check slightly differently. Modified: python/trunk/Objects/listobject.c ============================================================================== --- python/trunk/Objects/listobject.c (original) +++ python/trunk/Objects/listobject.c Fri Jan 25 20:50:26 2008 @@ -502,7 +502,7 @@ if (n && size/n != Py_SIZE(a)) return PyErr_NoMemory(); if (size == 0) - return PyList_New(0); + return PyList_New(0); np = (PyListObject *) PyList_New(size); if (np == NULL) return NULL; @@ -669,11 +669,11 @@ list_inplace_repeat(PyListObject *self, Py_ssize_t n) { PyObject **items; - Py_ssize_t size, i, j, p, newsize; + Py_ssize_t size, i, j, p; size = PyList_GET_SIZE(self); - if (size == 0) { + if (size == 0 || n == 1) { Py_INCREF(self); return (PyObject *)self; } @@ -684,10 +684,11 @@ return (PyObject *)self; } - newsize = size * n; - if (newsize/n != size) + if (size > SSIZE_MAX / n) { return PyErr_NoMemory(); - if (list_resize(self, newsize) == -1) + } + + if (list_resize(self, size*n) == -1) return NULL; p = size; From python-checkins at python.org Fri Jan 25 20:51:25 2008 From: python-checkins at python.org (thomas.wouters) Date: Fri, 25 Jan 2008 20:51:25 +0100 (CET) Subject: [Python-checkins] r60297 - python/branches/release25-maint/Objects/listobject.c Message-ID: <20080125195125.6F0FC1E401D@bag.python.org> Author: thomas.wouters Date: Fri Jan 25 20:51:24 2008 New Revision: 60297 Modified: python/branches/release25-maint/Objects/listobject.c Log: Use the right (portable) definition of the max of a Py_ssize_t. Modified: python/branches/release25-maint/Objects/listobject.c ============================================================================== --- python/branches/release25-maint/Objects/listobject.c (original) +++ python/branches/release25-maint/Objects/listobject.c Fri Jan 25 20:51:24 2008 @@ -672,7 +672,7 @@ return (PyObject *)self; } - if (size > SSIZE_MAX / n) { + if (size > Py_SSIZE_T_MAX / n) { return PyErr_NoMemory(); } From buildbot at python.org Fri Jan 25 21:32:39 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 25 Jan 2008 20:32:39 +0000 Subject: [Python-checkins] buildbot failure in x86 gentoo 2.5 Message-ID: <20080125203239.854471E4021@bag.python.org> The Buildbot has detected a new failure of x86 gentoo 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20gentoo%202.5/builds/526 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-x86 Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: thomas.wouters BUILD FAILED: failed compile sincerely, -The Buildbot From buildbot at python.org Fri Jan 25 21:33:30 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 25 Jan 2008 20:33:30 +0000 Subject: [Python-checkins] buildbot failure in x86 mvlgcc 2.5 Message-ID: <20080125203330.CAB311E401D@bag.python.org> The Buildbot has detected a new failure of x86 mvlgcc 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20mvlgcc%202.5/builds/402 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-linux Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: thomas.wouters BUILD FAILED: failed compile sincerely, -The Buildbot From buildbot at python.org Fri Jan 25 21:40:45 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 25 Jan 2008 20:40:45 +0000 Subject: [Python-checkins] buildbot failure in amd64 gentoo 2.5 Message-ID: <20080125204046.134291E4018@bag.python.org> The Buildbot has detected a new failure of amd64 gentoo 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/amd64%20gentoo%202.5/builds/7 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-amd64 Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: thomas.wouters BUILD FAILED: failed compile sincerely, -The Buildbot From buildbot at python.org Fri Jan 25 21:52:19 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 25 Jan 2008 20:52:19 +0000 Subject: [Python-checkins] buildbot failure in x86 FreeBSD trunk Message-ID: <20080125205220.13FC41E4023@bag.python.org> The Buildbot has detected a new failure of x86 FreeBSD trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20FreeBSD%20trunk/builds/471 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-freebsd Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_smtplib sincerely, -The Buildbot From python-checkins at python.org Fri Jan 25 22:08:41 2008 From: python-checkins at python.org (thomas.wouters) Date: Fri, 25 Jan 2008 22:08:41 +0100 (CET) Subject: [Python-checkins] r60300 - python/branches/release25-maint/Objects/listobject.c Message-ID: <20080125210841.C0A591E4026@bag.python.org> Author: thomas.wouters Date: Fri Jan 25 22:08:41 2008 New Revision: 60300 Modified: python/branches/release25-maint/Objects/listobject.c Log: Fix typo in constant name. Modified: python/branches/release25-maint/Objects/listobject.c ============================================================================== --- python/branches/release25-maint/Objects/listobject.c (original) +++ python/branches/release25-maint/Objects/listobject.c Fri Jan 25 22:08:41 2008 @@ -672,7 +672,7 @@ return (PyObject *)self; } - if (size > Py_SSIZE_T_MAX / n) { + if (size > PY_SSIZE_T_MAX / n) { return PyErr_NoMemory(); } From python-checkins at python.org Fri Jan 25 22:09:34 2008 From: python-checkins at python.org (thomas.wouters) Date: Fri, 25 Jan 2008 22:09:34 +0100 (CET) Subject: [Python-checkins] r60301 - python/trunk/Objects/listobject.c Message-ID: <20080125210934.EED241E401A@bag.python.org> Author: thomas.wouters Date: Fri Jan 25 22:09:34 2008 New Revision: 60301 Modified: python/trunk/Objects/listobject.c Log: Use the right (portable) definition of the max of a Py_ssize_t. Modified: python/trunk/Objects/listobject.c ============================================================================== --- python/trunk/Objects/listobject.c (original) +++ python/trunk/Objects/listobject.c Fri Jan 25 22:09:34 2008 @@ -684,7 +684,7 @@ return (PyObject *)self; } - if (size > SSIZE_MAX / n) { + if (size > PY_SSIZE_T_MAX / n) { return PyErr_NoMemory(); } From buildbot at python.org Fri Jan 25 22:18:10 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 25 Jan 2008 21:18:10 +0000 Subject: [Python-checkins] buildbot failure in ppc Debian unstable 2.5 Message-ID: <20080125211810.B9A821E400E@bag.python.org> The Buildbot has detected a new failure of ppc Debian unstable 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/ppc%20Debian%20unstable%202.5/builds/151 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: thomas.wouters BUILD FAILED: failed compile sincerely, -The Buildbot From buildbot at python.org Fri Jan 25 22:40:28 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 25 Jan 2008 21:40:28 +0000 Subject: [Python-checkins] buildbot failure in sparc solaris10 gcc 2.5 Message-ID: <20080125214029.2AB0F1E4016@bag.python.org> The Buildbot has detected a new failure of sparc solaris10 gcc 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/sparc%20solaris10%20gcc%202.5/builds/508 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-sun Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: thomas.wouters BUILD FAILED: failed compile sincerely, -The Buildbot From buildbot at python.org Fri Jan 25 22:56:12 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 25 Jan 2008 21:56:12 +0000 Subject: [Python-checkins] buildbot failure in g4 osx.4 2.5 Message-ID: <20080125215613.201291E4093@bag.python.org> The Buildbot has detected a new failure of g4 osx.4 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/g4%20osx.4%202.5/builds/508 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: psf-g4 Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: thomas.wouters BUILD FAILED: failed compile sincerely, -The Buildbot From nnorwitz at gmail.com Fri Jan 25 23:38:14 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Fri, 25 Jan 2008 17:38:14 -0500 Subject: [Python-checkins] Python Regression Test Failures refleak (8) Message-ID: <20080125223814.GA32107@python.psfb.org> test_opcodes leaked [0, -2, 2] references, sum=0 test_doctest leaked [0, 0, -2] references, sum=-2 test_descrtut leaked [0, 2, -6] references, sum=-4 test_dummy_threading leaked [0, -2, 0] references, sum=-2 test_functools leaked [-2, -2, -2] references, sum=-6 test_gc leaked [0, 4, 0] references, sum=4 test_gdbm leaked [-2, 0, 0] references, sum=-2 test_generators leaked [0, -2, 2] references, sum=0 test_importhooks leaked [-4, -4, 6] references, sum=-2 test_parser leaked [0, -2, 0] references, sum=-2 test_popen2 leaked [23, -23, 26] references, sum=26 test_threadsignals leaked [-8, 0, 0] references, sum=-8 test_urllib2_localnet leaked [-107, 123, -117] references, sum=-101 From buildbot at python.org Sat Jan 26 00:53:49 2008 From: buildbot at python.org (buildbot at python.org) Date: Fri, 25 Jan 2008 23:53:49 +0000 Subject: [Python-checkins] buildbot failure in x86 XP-3 3.0 Message-ID: <20080125235350.808711E4016@bag.python.org> The Buildbot has detected a new failure of x86 XP-3 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20XP-3%203.0/builds/507 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: heller-windows Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: thomas.wouters BUILD FAILED: failed test Excerpt from the test logfile: 10 tests failed: test_anydbm test_bsddb test_bsddb3 test_mailbox test_plistlib test_shelve test_urllib test_urllib2net test_whichdb test_zipfile ====================================================================== ERROR: test_anydbm_access (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_anydbm.py", line 90, in test_anydbm_access self.init_db() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_anydbm.py", line 103, in init_db f = anydbm.open(_fname, 'n') File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_anydbm_creation (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_anydbm.py", line 63, in test_anydbm_creation f = anydbm.open(_fname, 'c') File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_anydbm_keys (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_anydbm.py", line 84, in test_anydbm_keys self.init_db() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_anydbm.py", line 103, in init_db f = anydbm.open(_fname, 'n') File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_anydbm_modification (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_anydbm.py", line 71, in test_anydbm_modification self.init_db() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_anydbm.py", line 103, in init_db f = anydbm.open(_fname, 'n') File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_anydbm_read (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_anydbm.py", line 78, in test_anydbm_read self.init_db() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_anydbm.py", line 103, in init_db f = anydbm.open(_fname, 'n') File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') Traceback (most recent call last): File "../lib/test/regrtest.py", line 596, in runtest_inner indirect_test() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb3.py", line 64, in test_main run_unittest(suite()) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb3.py", line 28, in suite import bsddb.test.test_1413192 File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\test\test_1413192.py", line 38, in context = Context() File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\test\test_1413192.py", line 26, in __init__ db.DB_CREATE | db.DB_INIT_TXN | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_consistent_factory (test.test_mailbox.TestMaildir) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 520, in test_consistent_factory msg2 = box.get_message(key) File "C:\buildbot\work\3.0.heller-windows\build\lib\mailbox.py", line 313, in get_message subpath = self._lookup(key) File "C:\buildbot\work\3.0.heller-windows\build\lib\mailbox.py", line 482, in _lookup raise KeyError('No message with key: %s' % key) KeyError: 'No message with key: 1201316410.M78000P36564Q201.thomasxpbb' ====================================================================== ERROR: test_flush (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 717, in tearDown self._delete_recursively(self._path) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 47, in _delete_recursively os.remove(target) WindowsError: [Error 32] The process cannot access the file because it is being used by another process: '@test' ====================================================================== ERROR: test_popitem (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 336, in test_popitem self.assertEqual(int(msg.get_payload()), keys.index(key)) ValueError: invalid literal for int() with base 10: 'From: foo 0 F' ====================================================================== ERROR: test_flush (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 717, in tearDown self._delete_recursively(self._path) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 47, in _delete_recursively os.remove(target) WindowsError: [Error 32] The process cannot access the file because it is being used by another process: '@test' ====================================================================== ERROR: test_popitem (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 336, in test_popitem self.assertEqual(int(msg.get_payload()), keys.index(key)) ValueError: invalid literal for int() with base 10: 'From: foo 0 \x01' ====================================================================== ERROR: test_flush (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 940, in tearDown self._delete_recursively(self._path) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 47, in _delete_recursively os.remove(target) WindowsError: [Error 32] The process cannot access the file because it is being used by another process: '@test' ====================================================================== ERROR: test_popitem (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 336, in test_popitem self.assertEqual(int(msg.get_payload()), keys.index(key)) ValueError: invalid literal for int() with base 10: 'From: foo *** EOOH *** From: foo 0 1,, From: foo *** EOOH *** From: foo 1 1,, From: foo *** EOOH *** From: foo 2 1,, From: foo *** EOOH *** From: foo 3 ' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestMaildir) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_add (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 77, in test_add self.assertEqual(self._box.get_string(keys[0]), self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\nF' != 'From: foo\n\n0' ====================================================================== FAIL: test_add_and_close (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 757, in test_add_and_close self.assertEqual(contents, open(self._path, 'r').read()) AssertionError: 'From MAILER-DAEMON Sat Jan 26 03:00:21 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Sat Jan 26 03:00:21 2008\n\nFrom: foo\n\n0\n\nFrom MAILER-DAEMON Sat Jan 26 03:00:21 2008\n\nFrom: foo\n\n1\n\nFrom MAILER-DAEMON Sat Jan 26 03:00:21 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Sat Jan 26 03:00:21 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'From MAILER-DAEMON Sat Jan 26 03:00:21 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Sat Jan 26 03:00:21 2008\n\nFrom: foo\n\n0\n\nFrom MAILER-DAEMON Sat Jan 26 03:00:21 2008\n\nFrom: foo\n\n1\n\nFrom MAILER-DAEMON Sat Jan 26 03:00:21 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Sat Jan 26 03:00:21 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Sat Jan 26 03:00:21 2008\n\nFrom: foo\n\n0\n\nFrom MAILER-DAEMON Sat Jan 26 03:00:21 2008\n\nFrom: foo\n\n1\n\nFrom MAILER-DAEMON Sat Jan 26 03:00:21 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Sat Jan 26 03:00:21 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Sat Jan 26 03:00:21 2008\n\nFrom: foo\n\n1\n\nFrom MAILER-DAEMON Sat Jan 26 03:00:21 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Sat Jan 26 03:00:21 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Sat Jan 26 03:00:21 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Sat Jan 26 03:00:21 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Sat Jan 26 03:00:21 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' ====================================================================== FAIL: test_add_from_string (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 724, in test_add_from_string self.assertEqual(self._box[key].get_from(), 'foo at bar blah') AssertionError: 'foo at bar blah\n' != 'foo at bar blah' ====================================================================== FAIL: test_close (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 389, in test_close self._test_flush_or_close(self._box.close) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 6 != 3 ====================================================================== FAIL: test_delitem (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 87, in test_delitem self._test_remove_or_delitem(self._box.__delitem__) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n1' != 'From: foo\n\n1' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_flush (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 377, in test_flush self._test_flush_or_close(self._box.flush) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 6 != 3 ====================================================================== FAIL: test_get (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 129, in test_get self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_file (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 174, in test_get_file self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\nF' != 'From: foo\n\n0' ====================================================================== FAIL: test_get_message (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 156, in test_get_message self.assertEqual(msg0['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_string (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 164, in test_get_string self.assertEqual(self._box.get_string(key0), self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\nF' != 'From: foo\n\n0' ====================================================================== FAIL: test_getitem (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 144, in test_getitem self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_items (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 207, in test_items self._check_iteration(self._box.items, do_keys=True, do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iter (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 194, in test_iter do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iteritems (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 203, in test_iteritems do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_itervalues (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 189, in test_itervalues do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_open_close_open (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 741, in test_open_close_open self.assertEqual(len(self._box), 3) AssertionError: 6 != 3 ====================================================================== FAIL: test_pop (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 313, in test_pop self.assertEqual(self._box.pop(key0).get_payload(), '0') AssertionError: 'From: foo\n\n0\n\nF' != '0' ====================================================================== FAIL: test_remove (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 83, in test_remove self._test_remove_or_delitem(self._box.remove) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n1' != 'From: foo\n\n1' ====================================================================== FAIL: test_set_item (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 272, in test_set_item self._template % 'original 0') AssertionError: '\nFrom: foo\n\noriginal 0' != 'From: foo\n\noriginal 0' ====================================================================== FAIL: test_update (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 350, in test_update self._template % 'changed 0') AssertionError: '\nFrom: foo\n\nchanged 0\n\nF' != 'From: foo\n\nchanged 0' ====================================================================== FAIL: test_values (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 198, in test_values self._check_iteration(self._box.values, do_keys=False, do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_add (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 77, in test_add self.assertEqual(self._box.get_string(keys[0]), self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\n\x01' != 'From: foo\n\n0' ====================================================================== FAIL: test_add_and_close (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 757, in test_add_and_close self.assertEqual(contents, open(self._path, 'r').read()) AssertionError: '\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sat Jan 26 03:00:25 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sat Jan 26 03:00:25 2008\n\nFrom: foo\n\n0\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sat Jan 26 03:00:25 2008\n\nFrom: foo\n\n1\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sat Jan 26 03:00:25 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sat Jan 26 03:00:25 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n' != '\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sat Jan 26 03:00:25 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sat Jan 26 03:00:25 2008\n\nFrom: foo\n\n0\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sat Jan 26 03:00:25 2008\n\nFrom: foo\n\n1\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sat Jan 26 03:00:25 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sat Jan 26 03:00:25 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sat Jan 26 03:00:25 2008\n\nFrom: foo\n\n0\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sat Jan 26 03:00:25 2008\n\nFrom: foo\n\n1\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sat Jan 26 03:00:25 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sat Jan 26 03:00:25 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sat Jan 26 03:00:25 2008\n\nFrom: foo\n\n1\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sat Jan 26 03:00:25 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sat Jan 26 03:00:25 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sat Jan 26 03:00:25 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sat Jan 26 03:00:25 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sat Jan 26 03:00:25 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n' ====================================================================== FAIL: test_add_from_string (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 724, in test_add_from_string self.assertEqual(self._box[key].get_from(), 'foo at bar blah') AssertionError: 'foo at bar blah\n' != 'foo at bar blah' ====================================================================== FAIL: test_close (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 389, in test_close self._test_flush_or_close(self._box.close) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_delitem (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 87, in test_delitem self._test_remove_or_delitem(self._box.__delitem__) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n1\n\n\x01' != 'From: foo\n\n1' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_flush (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 377, in test_flush self._test_flush_or_close(self._box.flush) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_get (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 129, in test_get self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_file (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 174, in test_get_file self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\n\x01' != 'From: foo\n\n0' ====================================================================== FAIL: test_get_message (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 156, in test_get_message self.assertEqual(msg0['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_string (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 164, in test_get_string self.assertEqual(self._box.get_string(key0), self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\n\x01' != 'From: foo\n\n0' ====================================================================== FAIL: test_getitem (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 144, in test_getitem self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_items (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 207, in test_items self._check_iteration(self._box.items, do_keys=True, do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iter (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 194, in test_iter do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iteritems (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 203, in test_iteritems do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_itervalues (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 189, in test_itervalues do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_open_close_open (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 741, in test_open_close_open self.assertEqual(len(self._box), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_pop (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 313, in test_pop self.assertEqual(self._box.pop(key0).get_payload(), '0') AssertionError: 'From: foo\n\n0\n\n\x01' != '0' ====================================================================== FAIL: test_remove (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 83, in test_remove self._test_remove_or_delitem(self._box.remove) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n1\n\n\x01' != 'From: foo\n\n1' ====================================================================== FAIL: test_set_item (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 272, in test_set_item self._template % 'original 0') AssertionError: '\nFrom: foo\n\noriginal 0\n\n\x01' != 'From: foo\n\noriginal 0' ====================================================================== FAIL: test_update (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 350, in test_update self._template % 'changed 0') AssertionError: '\nFrom: foo\n\nchanged 0\n\n\x01' != 'From: foo\n\nchanged 0' ====================================================================== FAIL: test_values (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 198, in test_values self._check_iteration(self._box.values, do_keys=False, do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestMH) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_add (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 77, in test_add self.assertEqual(self._box.get_string(keys[0]), self._template % 0) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n0\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f' != 'From: foo\n\n0' ====================================================================== FAIL: test_close (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 389, in test_close self._test_flush_or_close(self._box.close) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_delitem (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 87, in test_delitem self._test_remove_or_delitem(self._box.__delitem__) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n1\n\n\x1f' != 'From: foo\n\n1' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_flush (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 377, in test_flush self._test_flush_or_close(self._box.flush) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_get (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 129, in test_get self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_file (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 174, in test_get_file self._template % 0) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n0\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f' != 'From: foo\n\n0' ====================================================================== FAIL: test_get_message (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 156, in test_get_message self.assertEqual(msg0['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_string (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 164, in test_get_string self.assertEqual(self._box.get_string(key0), self._template % 0) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n0\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f' != 'From: foo\n\n0' ====================================================================== FAIL: test_getitem (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 144, in test_getitem self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_items (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 207, in test_items self._check_iteration(self._box.items, do_keys=True, do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iter (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 194, in test_iter do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iteritems (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 203, in test_iteritems do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_itervalues (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 189, in test_itervalues do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_pop (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 313, in test_pop self.assertEqual(self._box.pop(key0).get_payload(), '0') AssertionError: 'From: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n0\n\n\x1f\x0c\n\n1,,\n\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n1\n\n\x1f' != '0' ====================================================================== FAIL: test_remove (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 83, in test_remove self._test_remove_or_delitem(self._box.remove) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n1\n\n\x1f' != 'From: foo\n\n1' ====================================================================== FAIL: test_set_item (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 272, in test_set_item self._template % 'original 0') AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\noriginal 0\n\n\x1f' != 'From: foo\n\noriginal 0' ====================================================================== FAIL: test_update (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 350, in test_update self._template % 'changed 0') AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\nchanged 0\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f' != 'From: foo\n\nchanged 0' ====================================================================== FAIL: test_values (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 198, in test_values self._check_iteration(self._box.values, do_keys=False, do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== ERROR: test_appleformatting (test.test_plistlib.TestPlistlib) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_plistlib.py", line 140, in test_appleformatting pl = plistlib.readPlistFromBytes(TESTDATA) AttributeError: 'module' object has no attribute 'readPlistFromBytes' ====================================================================== ERROR: test_appleformattingfromliteral (test.test_plistlib.TestPlistlib) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_plistlib.py", line 147, in test_appleformattingfromliteral pl2 = plistlib.readPlistFromBytes(TESTDATA) AttributeError: 'module' object has no attribute 'readPlistFromBytes' ====================================================================== ERROR: test_bytes (test.test_plistlib.TestPlistlib) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_plistlib.py", line 133, in test_bytes data = plistlib.writePlistToBytes(pl) AttributeError: 'module' object has no attribute 'writePlistToBytes' ====================================================================== ERROR: test_bytesio (test.test_plistlib.TestPlistlib) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_plistlib.py", line 155, in test_bytesio plistlib.writePlist(pl, b) File "C:\buildbot\work\3.0.heller-windows\build\lib\plistlib.py", line 91, in writePlist writer = PlistWriter(pathOrFile) File "C:\buildbot\work\3.0.heller-windows\build\lib\plistlib.py", line 230, in __init__ file.write(PLISTHEADER) File "c:\buildbot\work\3.0.heller-windows\build\lib\io.py", line 701, in write raise TypeError("can't write str to binary stream") TypeError: can't write str to binary stream ====================================================================== ERROR: test_controlcharacters (test.test_plistlib.TestPlistlib) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_plistlib.py", line 168, in test_controlcharacters plistlib.writePlistToBytes, AttributeError: 'module' object has no attribute 'writePlistToBytes' ====================================================================== ERROR: test_io (test.test_plistlib.TestPlistlib) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_plistlib.py", line 127, in test_io plistlib.writePlist(pl, test_support.TESTFN) File "C:\buildbot\work\3.0.heller-windows\build\lib\plistlib.py", line 93, in writePlist writer.writeValue(rootObject) File "C:\buildbot\work\3.0.heller-windows\build\lib\plistlib.py", line 248, in writeValue self.writeDict(value) File "C:\buildbot\work\3.0.heller-windows\build\lib\plistlib.py", line 277, in writeDict self.writeValue(value) File "C:\buildbot\work\3.0.heller-windows\build\lib\plistlib.py", line 254, in writeValue self.writeArray(value) File "C:\buildbot\work\3.0.heller-windows\build\lib\plistlib.py", line 283, in writeArray self.writeValue(value) File "C:\buildbot\work\3.0.heller-windows\build\lib\plistlib.py", line 250, in writeValue self.writeData(value) File "C:\buildbot\work\3.0.heller-windows\build\lib\plistlib.py", line 263, in writeData for line in data.asBase64(maxlinelength).split("\n"): File "C:\buildbot\work\3.0.heller-windows\build\lib\plistlib.py", line 375, in asBase64 return _encodeBase64(self.data, maxlinelength) File "C:\buildbot\work\3.0.heller-windows\build\lib\plistlib.py", line 359, in _encodeBase64 return "".join(pieces) TypeError: sequence item 0: expected str instance, bytes found ====================================================================== ERROR: test_nondictroot (test.test_plistlib.TestPlistlib) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_plistlib.py", line 174, in test_nondictroot result1 = plistlib.readPlistFromBytes(plistlib.writePlistToBytes(test1)) AttributeError: 'module' object has no attribute 'readPlistFromBytes' ====================================================================== ERROR: test_bool (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 136, in test_bool self.assert_(not self._empty_mapping()) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_constructor (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 133, in test_constructor self.assertEqual(self._empty_mapping(), self._empty_mapping()) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 270, in test_get d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_items (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 156, in test_items d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keys (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 142, in test_keys d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 162, in test_len d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 293, in test_pop d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 288, in test_popitem d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_read (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 44, in test_read p = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 284, in test_setdefault d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 174, in test_update d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_values (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 150, in test_values d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_write (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 92, in test_write p = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_bool (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 136, in test_bool self.assert_(not self._empty_mapping()) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_constructor (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 133, in test_constructor self.assertEqual(self._empty_mapping(), self._empty_mapping()) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 270, in test_get d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_items (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 156, in test_items d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keys (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 142, in test_keys d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 162, in test_len d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 293, in test_pop d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 288, in test_popitem d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_read (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 44, in test_read p = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 284, in test_setdefault d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 174, in test_update d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_values (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 150, in test_values d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_write (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 92, in test_write p = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_bool (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 136, in test_bool self.assert_(not self._empty_mapping()) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_constructor (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 133, in test_constructor self.assertEqual(self._empty_mapping(), self._empty_mapping()) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 270, in test_get d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_items (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 156, in test_items d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keys (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 142, in test_keys d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 162, in test_len d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 293, in test_pop d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 288, in test_popitem d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_read (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 44, in test_read p = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 284, in test_setdefault d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 174, in test_update d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_values (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 150, in test_values d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_write (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 92, in test_write p = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_ascii_file_shelf (test.test_shelve.TestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 46, in test_ascii_file_shelf s = shelve.open(self.fn, protocol=0) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_binary_file_shelf (test.test_shelve.TestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 54, in test_binary_file_shelf s = shelve.open(self.fn, protocol=1) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_proto2_file_shelf (test.test_shelve.TestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 62, in test_proto2_file_shelf s = shelve.open(self.fn, protocol=2) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== FAIL: test_read (test.test_urllib.urlopen_HttpTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_urllib.py", line 130, in test_read self.assertEqual(fp.getcode(), 200) AssertionError: None != 200 ====================================================================== ERROR: test_ftp (test.test_urllib2net.OtherNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_urllib2net.py", line 187, in test_ftp self._test_urls(urls, self._extra_handlers()) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_urllib2net.py", line 256, in _test_urls f = urlopen(url, req) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_urllib2net.py", line 24, in _urlopen_with_retry raise last_exc UnboundLocalError: local variable 'last_exc' referenced before assignment ====================================================================== ERROR: test_http (test.test_urllib2net.OtherNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_urllib2net.py", line 211, in test_http self._test_urls(urls, self._extra_handlers()) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_urllib2net.py", line 256, in _test_urls f = urlopen(url, req) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_urllib2net.py", line 24, in _urlopen_with_retry raise last_exc UnboundLocalError: local variable 'last_exc' referenced before assignment ====================================================================== ERROR: test_ftp_NoneNodefault (test.test_urllib2net.TimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_urllib2net.py", line 319, in test_ftp_NoneNodefault self.assertTrue(u.fp.fp._sock.gettimeout() is None) AttributeError: 'BufferedReader' object has no attribute '_sock' ====================================================================== ERROR: test_ftp_NoneWithdefault (test.test_urllib2net.TimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_urllib2net.py", line 313, in test_ftp_NoneWithdefault self.assertEqual(u.fp.fp._sock.gettimeout(), 60) AttributeError: 'BufferedReader' object has no attribute '_sock' ====================================================================== ERROR: test_whichdb (test.test_whichdb.WhichDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_whichdb.py", line 32, in test_whichdb f = module.open(_fname, 'c') File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: testExtract (test.test_zipfile.TestsWithSourceFile) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_zipfile.py", line 350, in tearDown os.remove(TESTFN2) WindowsError: [Error 32] The process cannot access the file because it is being used by another process: '@test2' ====================================================================== FAIL: testExtract (test.test_zipfile.TestsWithSourceFile) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_zipfile.py", line 313, in testExtract self.assertEqual(writtenfile, correctfile) AssertionError: 'C:\\buildbot\\work\\3.0.heller-windows\\build\\PCbuild\\ziptest2dir\\_ziptest2' != 'C:\\buildbot\\work\\3.0.heller-windows\\build\\PCbuild\\ziptest2dir/_ziptest2' sincerely, -The Buildbot From python-checkins at python.org Sat Jan 26 02:47:05 2008 From: python-checkins at python.org (thomas.wouters) Date: Sat, 26 Jan 2008 02:47:05 +0100 (CET) Subject: [Python-checkins] r60303 - python/trunk/Makefile.pre.in Message-ID: <20080126014705.578FA1E4018@bag.python.org> Author: thomas.wouters Date: Sat Jan 26 02:47:05 2008 New Revision: 60303 Modified: python/trunk/Makefile.pre.in Log: Make 'testall' work again when building in a separate directory. test_distutils still fails when doing that. Modified: python/trunk/Makefile.pre.in ============================================================================== --- python/trunk/Makefile.pre.in (original) +++ python/trunk/Makefile.pre.in Sat Jan 26 02:47:05 2008 @@ -617,7 +617,7 @@ testall: all platform -find $(srcdir)/Lib -name '*.py[co]' -print | xargs rm -f - $(TESTPYTHON) Lib/compileall.py + $(TESTPYTHON) $(srcdir)/Lib/compileall.py -find $(srcdir)/Lib -name '*.py[co]' -print | xargs rm -f -$(TESTPYTHON) $(TESTPROG) $(TESTOPTS) -uall $(TESTPYTHON) $(TESTPROG) $(TESTOPTS) -uall From python-checkins at python.org Sat Jan 26 03:38:33 2008 From: python-checkins at python.org (guido.van.rossum) Date: Sat, 26 Jan 2008 03:38:33 +0100 (CET) Subject: [Python-checkins] r60304 - peps/trunk/pep-3137.txt Message-ID: <20080126023833.5F06F1E4018@bag.python.org> Author: guido.van.rossum Date: Sat Jan 26 03:38:33 2008 New Revision: 60304 Modified: peps/trunk/pep-3137.txt Log: Fix typo found by Forest Wilkinson. Modified: peps/trunk/pep-3137.txt ============================================================================== --- peps/trunk/pep-3137.txt (original) +++ peps/trunk/pep-3137.txt Sat Jan 26 03:38:33 2008 @@ -64,7 +64,7 @@ - ``memoryview`` is a bytes view on another object (PyMemory) -The old type named ``bytearray`` is so similar to the new type +The old type named ``buffer`` is so similar to the new type ``memoryview``, introduce by PEP 3118, that it is redundant. The rest of this PEP doesn't discuss the functionality of ``memoryview``; it is just mentioned here to justify getting rid of the old ``buffer`` type. From buildbot at python.org Sat Jan 26 04:12:16 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 26 Jan 2008 03:12:16 +0000 Subject: [Python-checkins] buildbot failure in hppa Ubuntu trunk Message-ID: <20080126031216.875621E4024@bag.python.org> The Buildbot has detected a new failure of hppa Ubuntu trunk. Full details are available at: http://www.python.org/dev/buildbot/all/hppa%20Ubuntu%20trunk/builds/535 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-ubuntu-hppa Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: thomas.wouters BUILD FAILED: failed test Excerpt from the test logfile: make: *** [buildbottest] Segmentation fault sincerely, -The Buildbot From buildbot at python.org Sat Jan 26 05:51:11 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 26 Jan 2008 04:51:11 +0000 Subject: [Python-checkins] buildbot failure in x86 FreeBSD trunk Message-ID: <20080126045111.5C55F1E4016@bag.python.org> The Buildbot has detected a new failure of x86 FreeBSD trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20FreeBSD%20trunk/builds/474 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-freebsd Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: thomas.wouters BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_smtplib sincerely, -The Buildbot From python-checkins at python.org Sat Jan 26 06:54:49 2008 From: python-checkins at python.org (neal.norwitz) Date: Sat, 26 Jan 2008 06:54:49 +0100 (CET) Subject: [Python-checkins] r60305 - python/trunk/Lib/test/test_urllibnet.py Message-ID: <20080126055449.217B71E4016@bag.python.org> Author: neal.norwitz Date: Sat Jan 26 06:54:48 2008 New Revision: 60305 Modified: python/trunk/Lib/test/test_urllibnet.py Log: Prevent this test from failing if there are transient network problems by retrying the host for up to 3 times. Modified: python/trunk/Lib/test/test_urllibnet.py ============================================================================== --- python/trunk/Lib/test/test_urllibnet.py (original) +++ python/trunk/Lib/test/test_urllibnet.py Sat Jan 26 06:54:48 2008 @@ -9,6 +9,20 @@ import os import mimetools + +def _open_with_retry(func, host, *args, **kwargs): + # Connecting to remote hosts is flaky. Make it more robust + # by retrying the connection several times. + for i in range(3): + try: + return func(host, *args, **kwargs) + except IOError, last_exc: + continue + except: + raise + raise last_exc + + class URLTimeoutTest(unittest.TestCase): TIMEOUT = 10.0 @@ -20,7 +34,7 @@ socket.setdefaulttimeout(None) def testURLread(self): - f = urllib.urlopen("http://www.python.org/") + f = _open_with_retry(urllib.urlopen, "http://www.python.org/") x = f.read() class urlopenNetworkTests(unittest.TestCase): @@ -38,9 +52,12 @@ """ + def urlopen(self, *args): + return _open_with_retry(urllib.urlopen, *args) + def test_basic(self): # Simple test expected to pass. - open_url = urllib.urlopen("http://www.python.org/") + open_url = self.urlopen("http://www.python.org/") for attr in ("read", "readline", "readlines", "fileno", "close", "info", "geturl"): self.assert_(hasattr(open_url, attr), "object returned from " @@ -52,7 +69,7 @@ def test_readlines(self): # Test both readline and readlines. - open_url = urllib.urlopen("http://www.python.org/") + open_url = self.urlopen("http://www.python.org/") try: self.assert_(isinstance(open_url.readline(), basestring), "readline did not return a string") @@ -63,7 +80,7 @@ def test_info(self): # Test 'info'. - open_url = urllib.urlopen("http://www.python.org/") + open_url = self.urlopen("http://www.python.org/") try: info_obj = open_url.info() finally: @@ -76,7 +93,7 @@ def test_geturl(self): # Make sure same URL as opened is returned by geturl. URL = "http://www.python.org/" - open_url = urllib.urlopen(URL) + open_url = self.urlopen(URL) try: gotten_url = open_url.geturl() finally: @@ -100,7 +117,7 @@ # test can't pass on Windows. return # Make sure fd returned by fileno is valid. - open_url = urllib.urlopen("http://www.python.org/") + open_url = self.urlopen("http://www.python.org/") fd = open_url.fileno() FILE = os.fdopen(fd) try: @@ -125,9 +142,12 @@ class urlretrieveNetworkTests(unittest.TestCase): """Tests urllib.urlretrieve using the network.""" + def urlretrieve(self, *args): + return _open_with_retry(urllib.urlretrieve, *args) + def test_basic(self): # Test basic functionality. - file_location,info = urllib.urlretrieve("http://www.python.org/") + file_location,info = self.urlretrieve("http://www.python.org/") self.assert_(os.path.exists(file_location), "file location returned by" " urlretrieve is not a valid path") FILE = file(file_location) @@ -140,8 +160,8 @@ def test_specified_path(self): # Make sure that specifying the location of the file to write to works. - file_location,info = urllib.urlretrieve("http://www.python.org/", - test_support.TESTFN) + file_location,info = self.urlretrieve("http://www.python.org/", + test_support.TESTFN) self.assertEqual(file_location, test_support.TESTFN) self.assert_(os.path.exists(file_location)) FILE = file(file_location) @@ -153,7 +173,7 @@ def test_header(self): # Make sure header returned as 2nd value from urlretrieve is good. - file_location, header = urllib.urlretrieve("http://www.python.org/") + file_location, header = self.urlretrieve("http://www.python.org/") os.unlink(file_location) self.assert_(isinstance(header, mimetools.Message), "header is not an instance of mimetools.Message") From python-checkins at python.org Sat Jan 26 08:26:12 2008 From: python-checkins at python.org (neal.norwitz) Date: Sat, 26 Jan 2008 08:26:12 +0100 (CET) Subject: [Python-checkins] r60306 - python/trunk/Lib/test/test_xmlrpc.py Message-ID: <20080126072612.BE2CA1E4024@bag.python.org> Author: neal.norwitz Date: Sat Jan 26 08:26:12 2008 New Revision: 60306 Modified: python/trunk/Lib/test/test_xmlrpc.py Log: Use a condition variable (threading.Event) rather than sleeps and checking a global to determine when the server is ready to be used. This slows the test down, but should make it correct. There was a race condition before where the server could have assigned a port, yet it wasn't ready to serve requests. If the client sent a request before the server was completely ready, it would get an exception. There was machinery to try to handle this condition. All of that should be unnecessary and removed if this change works. A NOTE was added as a comment about what needs to be fixed. The buildbots will tell us if there are more errors or if this test is now stable. Modified: python/trunk/Lib/test/test_xmlrpc.py ============================================================================== --- python/trunk/Lib/test/test_xmlrpc.py (original) +++ python/trunk/Lib/test/test_xmlrpc.py Sat Jan 26 08:26:12 2008 @@ -296,6 +296,9 @@ PORT = None +# The evt is set twice. First when the server is ready to serve. +# Second when the server has been shutdown. The user must clear +# the event after it has been set the first time to catch the second set. def http_server(evt, numrequests): class TestInstanceClass: def div(self, x, y): @@ -323,6 +326,7 @@ serv.register_function(lambda x,y: x+y, 'add') serv.register_function(my_function) serv.register_instance(TestInstanceClass()) + evt.set() # handle up to 'numrequests' requests while numrequests > 0: @@ -336,10 +340,19 @@ PORT = None evt.set() +# TODO(nnorwitz): 25-Jan-2008 since we now notify the test when the server +# is totally ready to serve, this function should not be necessary. +# It is disabled by returning False. If the buildbots don't show any +# failures for this test over the next week, all the code associated +# with this function should be removed. The code that needs to be removed +# is this function, the NOTE below, and the entire except body that +# calls this function. def is_unavailable_exception(e): '''Returns True if the given ProtocolError is the product of a server-side exception caused by the 'temporarily unavailable' response sometimes given by operations on non-blocking sockets.''' + return False + # sometimes we get a -1 error code and/or empty headers if e.errcode == -1 or e.headers is None: return True @@ -367,13 +380,9 @@ serv_args = (self.evt, 1) threading.Thread(target=http_server, args=serv_args).start() - # wait for port to be assigned to server - n = 1000 - while n > 0 and PORT is None: - time.sleep(0.001) - n -= 1 - - time.sleep(0.5) + # wait for the server to be ready + self.evt.wait() + self.evt.clear() def tearDown(self): # wait on the server thread to terminate @@ -518,13 +527,9 @@ serv_args = (self.evt, 2) threading.Thread(target=http_server, args=serv_args).start() - # wait for port to be assigned to server - n = 1000 - while n > 0 and PORT is None: - time.sleep(0.001) - n -= 1 - - time.sleep(0.5) + # wait for the server to be ready + self.evt.wait() + self.evt.clear() def tearDown(self): # wait on the server thread to terminate From python-checkins at python.org Sat Jan 26 08:38:03 2008 From: python-checkins at python.org (neal.norwitz) Date: Sat, 26 Jan 2008 08:38:03 +0100 (CET) Subject: [Python-checkins] r60307 - python/trunk/Lib/bsddb/test/test_thread.py Message-ID: <20080126073803.7FCF21E401F@bag.python.org> Author: neal.norwitz Date: Sat Jan 26 08:38:03 2008 New Revision: 60307 Modified: python/trunk/Lib/bsddb/test/test_thread.py Log: Fix exception in tearDown on ppc buildbot. If there's no directory, that shouldn't cause the test to fail. Just like it setUp. Modified: python/trunk/Lib/bsddb/test/test_thread.py ============================================================================== --- python/trunk/Lib/bsddb/test/test_thread.py (original) +++ python/trunk/Lib/bsddb/test/test_thread.py Sat Jan 26 08:38:03 2008 @@ -58,7 +58,7 @@ try: os.mkdir(homeDir) except OSError, e: - if e.errno <> errno.EEXIST: raise + if e.errno != errno.EEXIST: raise self.env = db.DBEnv() self.setEnvOpts() self.env.open(homeDir, self.envflags | db.DB_CREATE) @@ -72,7 +72,10 @@ def tearDown(self): self.d.close() self.env.close() - shutil.rmtree(self.homeDir) + try: + shutil.rmtree(self.homeDir) + except OSError, e: + if e.errno != errno.EEXIST: raise def setEnvOpts(self): pass From buildbot at python.org Sat Jan 26 08:55:12 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 26 Jan 2008 07:55:12 +0000 Subject: [Python-checkins] buildbot failure in amd64 gentoo trunk Message-ID: <20080126075512.EB1A31E40CD@bag.python.org> The Buildbot has detected a new failure of amd64 gentoo trunk. Full details are available at: http://www.python.org/dev/buildbot/all/amd64%20gentoo%20trunk/builds/29 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-amd64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: neal.norwitz BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_bsddb3 ====================================================================== ERROR: test00_associateDBError (bsddb.test.test_associate.AssociateErrorTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_associate.py", line 102, in setUp os.remove(file) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test07_EnvRemoveAndRename (bsddb.test.test_basics.BasicBTreeWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test07_EnvRemoveAndRename (bsddb.test.test_basics.BasicHashWithEnvTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test06_Transactions (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test07_TxnTruncate (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test08_TxnLateUse (bsddb.test.test_basics.BTreeTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test06_Transactions (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test07_TxnTruncate (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test08_TxnLateUse (bsddb.test.test_basics.HashTransactionTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test09_MultiDB (bsddb.test.test_basics.BTreeMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test01_GetsAndPuts (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test02_DictionaryMethods (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test03_SimpleCursorStuff (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test03b_SimpleCursorWithGetReturnsNone1 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test03b_SimpleCursorWithoutGetReturnsNone0 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test03c_SimpleCursorGetReturnsNone2 (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test04_PartialGetAndPut (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test05_GetSize (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test06_Truncate (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test09_MultiDB (bsddb.test.test_basics.HashMultiDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_basics.py", line 60, in setUp shutil.rmtree(homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test01_both (bsddb.test.test_dbobj.dbobjTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_dbobj.py", line 45, in test01_both self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/dbobj.py", line 39, in open return apply(self._cobj.open, args, kwargs) DBAccessError: (13, 'Permission denied') ====================================================================== ERROR: test01_both (bsddb.test.test_dbobj.dbobjTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_dbobj.py", line 35, in tearDown os.remove(file) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test02_dbobj_dict_interface (bsddb.test.test_dbobj.dbobjTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_dbobj.py", line 58, in test02_dbobj_dict_interface self.env.open(self.homeDir, db.DB_CREATE | db.DB_INIT_MPOOL) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/dbobj.py", line 39, in open return apply(self._cobj.open, args, kwargs) DBAccessError: (13, 'Permission denied') ====================================================================== ERROR: test02_dbobj_dict_interface (bsddb.test.test_dbobj.dbobjTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_dbobj.py", line 35, in tearDown os.remove(file) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test03_dbobj_type_before_open (bsddb.test.test_dbobj.dbobjTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_dbobj.py", line 35, in tearDown os.remove(file) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBAccessError: (13, 'Permission denied') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBAccessError: (13, 'Permission denied') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBAccessError: (13, 'Permission denied') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBAccessError: (13, 'Permission denied') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBAccessError: (13, 'Permission denied') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBAccessError: (13, 'Permission denied') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBAccessError: (13, 'Permission denied') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBAccessError: (13, 'Permission denied') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvThreadBTreeShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBAccessError: (13, 'Permission denied') ====================================================================== ERROR: test01_basics (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBAccessError: (13, 'Permission denied') ====================================================================== ERROR: test02_cursors (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBAccessError: (13, 'Permission denied') ====================================================================== ERROR: test03_append (bsddb.test.test_dbshelve.EnvThreadHashShelveTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_dbshelve.py", line 35, in setUp self.do_open() File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_dbshelve.py", line 253, in do_open self.env.open(homeDir, self.envflags | db.DB_INIT_MPOOL | db.DB_CREATE) DBAccessError: (13, 'Permission denied') ====================================================================== ERROR: test01_close_dbenv_before_db (bsddb.test.test_env_close.DBEnvClosedEarlyCrash) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_env_close.py", line 53, in test01_close_dbenv_before_db 0666) DBAccessError: (13, 'Permission denied') ====================================================================== ERROR: test01_close_dbenv_before_db (bsddb.test.test_env_close.DBEnvClosedEarlyCrash) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_env_close.py", line 46, in tearDown os.remove(file) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test02_close_dbenv_delete_db_success (bsddb.test.test_env_close.DBEnvClosedEarlyCrash) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_env_close.py", line 78, in test02_close_dbenv_delete_db_success 0666) DBAccessError: (13, 'Permission denied') ====================================================================== ERROR: test02_close_dbenv_delete_db_success (bsddb.test.test_env_close.DBEnvClosedEarlyCrash) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_env_close.py", line 46, in tearDown os.remove(file) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test01_join (bsddb.test.test_join.JoinTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_join.py", line 57, in setUp self.env.open(homeDir, db.DB_CREATE | db.DB_INIT_MPOOL | db.DB_INIT_LOCK ) DBAccessError: (13, 'Permission denied') ====================================================================== ERROR: test01_badpointer (bsddb.test.test_misc.MiscTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_misc.py", line 34, in tearDown shutil.rmtree(self.homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test02_db_home (bsddb.test.test_misc.MiscTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_misc.py", line 45, in test02_db_home env.open(self.homeDir, db.DB_CREATE) DBAccessError: (13, 'Permission denied') ====================================================================== ERROR: test02_db_home (bsddb.test.test_misc.MiscTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_misc.py", line 34, in tearDown shutil.rmtree(self.homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test03_repr_closed_db (bsddb.test.test_misc.MiscTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_misc.py", line 34, in tearDown shutil.rmtree(self.homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test04_double_free_make_key_dbt (bsddb.test.test_misc.MiscTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_misc.py", line 34, in tearDown shutil.rmtree(self.homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test05_key_with_null_bytes (bsddb.test.test_misc.MiscTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_misc.py", line 34, in tearDown shutil.rmtree(self.homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test_DB_set_flags_persists (bsddb.test.test_misc.MiscTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_misc.py", line 34, in tearDown shutil.rmtree(self.homeDir) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 184, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/shutil.py", line 182, in rmtree os.remove(fullname) OSError: [Errno 13] Permission denied: '/tmp/db_home/__db.001' ====================================================================== ERROR: test02_WithSource (bsddb.test.test_recno.SimpleRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_recno.py", line 210, in test02_WithSource f = open(source, 'w') # create the file IOError: [Errno 13] Permission denied: '/tmp/db_home/test_recno.txt' ====================================================================== ERROR: test02_WithSource (bsddb.test.test_recno.SimpleRecnoTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_recno.py", line 31, in tearDown os.remove(self.filename) OSError: [Errno 2] No such file or directory: '/tmp/tmppgcD0R' ====================================================================== ERROR: test01_1WriterMultiReaders (bsddb.test.test_thread.BTreeConcurrentDataStore) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBAccessError: (13, 'Permission denied') ====================================================================== ERROR: test01_1WriterMultiReaders (bsddb.test.test_thread.HashConcurrentDataStore) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBAccessError: (13, 'Permission denied') ====================================================================== ERROR: test02_SimpleLocks (bsddb.test.test_thread.BTreeSimpleThreaded) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBAccessError: (13, 'Permission denied') ====================================================================== ERROR: test02_SimpleLocks (bsddb.test.test_thread.HashSimpleThreaded) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBAccessError: (13, 'Permission denied') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.BTreeThreadedTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBAccessError: (13, 'Permission denied') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.HashThreadedTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBAccessError: (13, 'Permission denied') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.BTreeThreadedNoWaitTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBAccessError: (13, 'Permission denied') ====================================================================== ERROR: test03_ThreadedTransactions (bsddb.test.test_thread.HashThreadedNoWaitTransactions) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_thread.py", line 64, in setUp self.env.open(homeDir, self.envflags | db.DB_CREATE) DBAccessError: (13, 'Permission denied') make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Sat Jan 26 09:19:06 2008 From: python-checkins at python.org (raymond.hettinger) Date: Sat, 26 Jan 2008 09:19:06 +0100 (CET) Subject: [Python-checkins] r60308 - in python/trunk: Doc/c-api/set.rst Objects/setobject.c Message-ID: <20080126081906.784BC1E4010@bag.python.org> Author: raymond.hettinger Date: Sat Jan 26 09:19:06 2008 New Revision: 60308 Modified: python/trunk/Doc/c-api/set.rst python/trunk/Objects/setobject.c Log: Make PySet_Add() work with frozensets. Works like PyTuple_SetItem() to build-up values in a brand new frozenset. Modified: python/trunk/Doc/c-api/set.rst ============================================================================== --- python/trunk/Doc/c-api/set.rst (original) +++ python/trunk/Doc/c-api/set.rst Sat Jan 26 09:19:06 2008 @@ -112,9 +112,6 @@ the *key* is unhashable. Raise :exc:`PyExc_SystemError` if *anyset* is not a :class:`set`, :class:`frozenset`, or an instance of a subtype. -The following functions are available for instances of :class:`set` or its -subtypes but not for instances of :class:`frozenset` or its subtypes. - .. cfunction:: int PySet_Add(PyObject *set, PyObject *key) @@ -124,6 +121,14 @@ Raise a :exc:`SystemError` if *set* is an not an instance of :class:`set` or its subtype. + .. versionchanged:: 2.6 + Now works with instances of :class:`frozenset` or its subtypes. + Like :cfunc:`PyTuple_SetItem` in that it can be used to fill-in the + values of brand new frozensets before they are exposed to other code. + +The following functions are available for instances of :class:`set` or its +subtypes but not for instances of :class:`frozenset` or its subtypes. + .. cfunction:: int PySet_Discard(PyObject *set, PyObject *key) Modified: python/trunk/Objects/setobject.c ============================================================================== --- python/trunk/Objects/setobject.c (original) +++ python/trunk/Objects/setobject.c Sat Jan 26 09:19:06 2008 @@ -2198,10 +2198,6 @@ int PySet_Add(PyObject *set, PyObject *key) { - if (!PyType_IsSubtype(Py_TYPE(set), &PySet_Type)) { - PyErr_BadInternalCall(); - return -1; - } return set_add_key((PySetObject *)set, key); } From buildbot at python.org Sat Jan 26 09:20:40 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 26 Jan 2008 08:20:40 +0000 Subject: [Python-checkins] buildbot failure in g4 osx.4 trunk Message-ID: <20080126082040.E03D51E4025@bag.python.org> The Buildbot has detected a new failure of g4 osx.4 trunk. Full details are available at: http://www.python.org/dev/buildbot/all/g4%20osx.4%20trunk/builds/2708 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: psf-g4 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: neal.norwitz BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_xmlrpc ====================================================================== FAIL: test_introspection1 (test.test_xmlrpc.SimpleServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/test/test_xmlrpc.py", line 428, in test_introspection1 self.fail("%s\n%s" % (e, e.headers)) AssertionError: ====================================================================== FAIL: test_introspection2 (test.test_xmlrpc.SimpleServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/test/test_xmlrpc.py", line 440, in test_introspection2 self.fail("%s\n%s" % (e, e.headers)) AssertionError: ====================================================================== FAIL: test_introspection3 (test.test_xmlrpc.SimpleServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/test/test_xmlrpc.py", line 452, in test_introspection3 self.fail("%s\n%s" % (e, e.headers)) AssertionError: ====================================================================== FAIL: test_introspection4 (test.test_xmlrpc.SimpleServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/test/test_xmlrpc.py", line 465, in test_introspection4 self.fail("%s\n%s" % (e, e.headers)) AssertionError: ====================================================================== FAIL: test_multicall (test.test_xmlrpc.SimpleServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/test/test_xmlrpc.py", line 482, in test_multicall self.fail("%s\n%s" % (e, e.headers)) AssertionError: ====================================================================== FAIL: test_non_existing_multicall (test.test_xmlrpc.SimpleServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/test/test_xmlrpc.py", line 503, in test_non_existing_multicall self.fail("%s\n%s" % (e, e.headers)) AssertionError: ====================================================================== FAIL: test_simple1 (test.test_xmlrpc.SimpleServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/test/test_xmlrpc.py", line 402, in test_simple1 self.fail("%s\n%s" % (e, e.headers)) AssertionError: ====================================================================== FAIL: test_basic (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/test/test_xmlrpc.py", line 558, in test_basic self.fail("%s\n%s" % (e, e.headers)) AssertionError: make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Sat Jan 26 09:26:00 2008 From: python-checkins at python.org (neal.norwitz) Date: Sat, 26 Jan 2008 09:26:00 +0100 (CET) Subject: [Python-checkins] r60309 - python/trunk/Lib/test/test_xmlrpc.py Message-ID: <20080126082600.780711E4010@bag.python.org> Author: neal.norwitz Date: Sat Jan 26 09:26:00 2008 New Revision: 60309 Modified: python/trunk/Lib/test/test_xmlrpc.py Log: The OS X buildbot had errors with the unavailable exceptions disabled. Restore it. Modified: python/trunk/Lib/test/test_xmlrpc.py ============================================================================== --- python/trunk/Lib/test/test_xmlrpc.py (original) +++ python/trunk/Lib/test/test_xmlrpc.py Sat Jan 26 09:26:00 2008 @@ -340,18 +340,12 @@ PORT = None evt.set() -# TODO(nnorwitz): 25-Jan-2008 since we now notify the test when the server -# is totally ready to serve, this function should not be necessary. -# It is disabled by returning False. If the buildbots don't show any -# failures for this test over the next week, all the code associated -# with this function should be removed. The code that needs to be removed -# is this function, the NOTE below, and the entire except body that -# calls this function. +# This function prevents errors like: +# def is_unavailable_exception(e): '''Returns True if the given ProtocolError is the product of a server-side exception caused by the 'temporarily unavailable' response sometimes given by operations on non-blocking sockets.''' - return False # sometimes we get a -1 error code and/or empty headers if e.errcode == -1 or e.headers is None: From buildbot at python.org Sat Jan 26 09:27:42 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 26 Jan 2008 08:27:42 +0000 Subject: [Python-checkins] buildbot failure in amd64 gentoo trunk Message-ID: <20080126082742.563611E4010@bag.python.org> The Buildbot has detected a new failure of amd64 gentoo trunk. Full details are available at: http://www.python.org/dev/buildbot/all/amd64%20gentoo%20trunk/builds/31 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-amd64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: make: *** [buildbottest] Aborted (core dumped) sincerely, -The Buildbot From buildbot at python.org Sat Jan 26 09:30:18 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 26 Jan 2008 08:30:18 +0000 Subject: [Python-checkins] buildbot failure in x86 gentoo trunk Message-ID: <20080126083018.ACE941E4010@bag.python.org> The Buildbot has detected a new failure of x86 gentoo trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20gentoo%20trunk/builds/2958 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-x86 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: make: *** [buildbottest] Aborted sincerely, -The Buildbot From python-checkins at python.org Sat Jan 26 09:37:28 2008 From: python-checkins at python.org (raymond.hettinger) Date: Sat, 26 Jan 2008 09:37:28 +0100 (CET) Subject: [Python-checkins] r60310 - python/trunk/Python/marshal.c Message-ID: <20080126083728.E36521E4010@bag.python.org> Author: raymond.hettinger Date: Sat Jan 26 09:37:28 2008 New Revision: 60310 Modified: python/trunk/Python/marshal.c Log: Let marshal build-up sets and frozensets one element at a time. Saves the unnecessary creation of a tuple as intermediate container. Modified: python/trunk/Python/marshal.c ============================================================================== --- python/trunk/Python/marshal.c (original) +++ python/trunk/Python/marshal.c Sat Jan 26 09:37:28 2008 @@ -860,7 +860,7 @@ retval = NULL; break; } - v = PyTuple_New((int)n); + v = (type == TYPE_SET) ? PySet_New(NULL) : PyFrozenSet_New(NULL); if (v == NULL) { retval = NULL; break; @@ -875,18 +875,14 @@ v = NULL; break; } - PyTuple_SET_ITEM(v, (int)i, v2); + if (PySet_Add(v, v2) == -1) { + Py_DECREF(v); + Py_DECREF(v2); + v = NULL; + break; + } } - if (v == NULL) { - retval = NULL; - break; - } - if (type == TYPE_SET) - v3 = PySet_New(v); - else - v3 = PyFrozenSet_New(v); - Py_DECREF(v); - retval = v3; + retval = (v == NULL) ? NULL : v; break; case TYPE_CODE: From buildbot at python.org Sat Jan 26 09:37:37 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 26 Jan 2008 08:37:37 +0000 Subject: [Python-checkins] buildbot failure in ia64 Ubuntu trunk Message-ID: <20080126083737.9CEC91E4010@bag.python.org> The Buildbot has detected a new failure of ia64 Ubuntu trunk. Full details are available at: http://www.python.org/dev/buildbot/all/ia64%20Ubuntu%20trunk/builds/1304 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ia64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: neal.norwitz,raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: make: *** [buildbottest] Aborted sincerely, -The Buildbot From python-checkins at python.org Sat Jan 26 09:41:14 2008 From: python-checkins at python.org (raymond.hettinger) Date: Sat, 26 Jan 2008 09:41:14 +0100 (CET) Subject: [Python-checkins] r60311 - python/trunk/Objects/setobject.c Message-ID: <20080126084114.081801E4010@bag.python.org> Author: raymond.hettinger Date: Sat Jan 26 09:41:13 2008 New Revision: 60311 Modified: python/trunk/Objects/setobject.c Log: Update test code for change to PySet_Add(). Modified: python/trunk/Objects/setobject.c ============================================================================== --- python/trunk/Objects/setobject.c (original) +++ python/trunk/Objects/setobject.c Sat Jan 26 09:41:13 2008 @@ -2341,7 +2341,6 @@ f = PyFrozenSet_New(dup); assert(PySet_Size(f) == 3); assert(PyFrozenSet_CheckExact(f)); - assertRaises(PySet_Add(f, elem) == -1, PyExc_SystemError); assertRaises(PySet_Discard(f, elem) == -1, PyExc_SystemError); assertRaises(PySet_Pop(f) == NULL, PyExc_SystemError); Py_DECREF(f); From buildbot at python.org Sat Jan 26 09:45:36 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 26 Jan 2008 08:45:36 +0000 Subject: [Python-checkins] buildbot failure in x86 mvlgcc trunk Message-ID: <20080126084537.1E6641E4010@bag.python.org> The Buildbot has detected a new failure of x86 mvlgcc trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20mvlgcc%20trunk/builds/1328 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-linux Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: make: *** [buildbottest] Abgebrochen sincerely, -The Buildbot From g.brandl at gmx.net Sat Jan 26 09:45:10 2008 From: g.brandl at gmx.net (Georg Brandl) Date: Sat, 26 Jan 2008 09:45:10 +0100 Subject: [Python-checkins] r60283 - in python/trunk: Include/longintrepr.h Include/longobject.h Include/unicodeobject.h Misc/NEWS Modules/_fileio.c Objects/longobject.c Objects/unicodeobject.c setup.py In-Reply-To: <20080125121844.4BC4D1E400F@bag.python.org> References: <20080125121844.4BC4D1E400F@bag.python.org> Message-ID: christian.heimes schrieb: > Author: christian.heimes > Date: Fri Jan 25 13:18:43 2008 > New Revision: 60283 > > Added: > python/trunk/Modules/_fileio.c > - copied, changed from r60280, python/branches/py3k/Modules/_fileio.c > Modified: > python/trunk/Include/longintrepr.h > python/trunk/Include/longobject.h > python/trunk/Include/unicodeobject.h > python/trunk/Misc/NEWS > python/trunk/Objects/longobject.c > python/trunk/Objects/unicodeobject.c > python/trunk/setup.py > Log: > Backport of several functions from Python 3.0 to 2.6 including PyUnicode_FromString, PyUnicode_Format and PyLong_From/AsSsize_t. The functions are partly required for the backport of the bytearray type and _fileio module. They should also make it easier to port C to 3.0. > First chapter of the Python 3.0 io framework back port: _fileio > The next step depends on a working bytearray type which itself depends on a backport of the nwe buffer API. What about backporting documentation? Georg -- Thus spake the Lord: Thou shalt indent with four spaces. No more, no less. Four shall be the number of spaces thou shalt indent, and the number of thy indenting shall be four. Eight shalt thou not indent, nor either indent thou two, excepting that thou then proceed to four. Tabs are right out. From buildbot at python.org Sat Jan 26 10:10:11 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 26 Jan 2008 09:10:11 +0000 Subject: [Python-checkins] buildbot failure in x86 FreeBSD trunk Message-ID: <20080126091011.3AAD61E4010@bag.python.org> The Buildbot has detected a new failure of x86 FreeBSD trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20FreeBSD%20trunk/builds/476 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-freebsd Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: neal.norwitz BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 227, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 268, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 281, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 560, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 227, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 268, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 281, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 560, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 227, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 268, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 281, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 560, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable 1 test failed: test_xmlrpc Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 227, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 268, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 281, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 560, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable ====================================================================== FAIL: test_introspection1 (test.test_xmlrpc.SimpleServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/test/test_xmlrpc.py", line 428, in test_introspection1 self.fail("%s\n%s" % (e, e.headers)) AssertionError: ====================================================================== FAIL: test_introspection2 (test.test_xmlrpc.SimpleServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/test/test_xmlrpc.py", line 440, in test_introspection2 self.fail("%s\n%s" % (e, e.headers)) AssertionError: ====================================================================== FAIL: test_introspection3 (test.test_xmlrpc.SimpleServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/test/test_xmlrpc.py", line 452, in test_introspection3 self.fail("%s\n%s" % (e, e.headers)) AssertionError: ====================================================================== FAIL: test_introspection4 (test.test_xmlrpc.SimpleServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/test/test_xmlrpc.py", line 465, in test_introspection4 self.fail("%s\n%s" % (e, e.headers)) AssertionError: ====================================================================== FAIL: test_multicall (test.test_xmlrpc.SimpleServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/test/test_xmlrpc.py", line 482, in test_multicall self.fail("%s\n%s" % (e, e.headers)) AssertionError: ====================================================================== FAIL: test_non_existing_multicall (test.test_xmlrpc.SimpleServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/test/test_xmlrpc.py", line 503, in test_non_existing_multicall self.fail("%s\n%s" % (e, e.headers)) AssertionError: ====================================================================== FAIL: test_simple1 (test.test_xmlrpc.SimpleServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/test/test_xmlrpc.py", line 402, in test_simple1 self.fail("%s\n%s" % (e, e.headers)) AssertionError: ====================================================================== FAIL: test_basic (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/test/test_xmlrpc.py", line 558, in test_basic self.fail("%s\n%s" % (e, e.headers)) AssertionError: sincerely, -The Buildbot From buildbot at python.org Sat Jan 26 10:10:29 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 26 Jan 2008 09:10:29 +0000 Subject: [Python-checkins] buildbot failure in sparc solaris10 gcc trunk Message-ID: <20080126091029.D1E491E4010@bag.python.org> The Buildbot has detected a new failure of sparc solaris10 gcc trunk. Full details are available at: http://www.python.org/dev/buildbot/all/sparc%20solaris10%20gcc%20trunk/builds/2715 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-sun Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: neal.norwitz,raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: sincerely, -The Buildbot From buildbot at python.org Sat Jan 26 10:24:05 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 26 Jan 2008 09:24:05 +0000 Subject: [Python-checkins] buildbot failure in hppa Ubuntu trunk Message-ID: <20080126092405.B4B311E4010@bag.python.org> The Buildbot has detected a new failure of hppa Ubuntu trunk. Full details are available at: http://www.python.org/dev/buildbot/all/hppa%20Ubuntu%20trunk/builds/538 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-ubuntu-hppa Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: neal.norwitz,raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: make: *** [buildbottest] Aborted sincerely, -The Buildbot From python-checkins at python.org Sat Jan 26 10:31:11 2008 From: python-checkins at python.org (raymond.hettinger) Date: Sat, 26 Jan 2008 10:31:11 +0100 (CET) Subject: [Python-checkins] r60312 - in python/trunk: Doc/c-api/set.rst Objects/setobject.c Python/marshal.c Message-ID: <20080126093111.AA2171E4010@bag.python.org> Author: raymond.hettinger Date: Sat Jan 26 10:31:11 2008 New Revision: 60312 Modified: python/trunk/Doc/c-api/set.rst python/trunk/Objects/setobject.c python/trunk/Python/marshal.c Log: Revert PySet_Add() changes. Modified: python/trunk/Doc/c-api/set.rst ============================================================================== --- python/trunk/Doc/c-api/set.rst (original) +++ python/trunk/Doc/c-api/set.rst Sat Jan 26 10:31:11 2008 @@ -112,6 +112,9 @@ the *key* is unhashable. Raise :exc:`PyExc_SystemError` if *anyset* is not a :class:`set`, :class:`frozenset`, or an instance of a subtype. +The following functions are available for instances of :class:`set` or its +subtypes but not for instances of :class:`frozenset` or its subtypes. + .. cfunction:: int PySet_Add(PyObject *set, PyObject *key) @@ -121,14 +124,6 @@ Raise a :exc:`SystemError` if *set* is an not an instance of :class:`set` or its subtype. - .. versionchanged:: 2.6 - Now works with instances of :class:`frozenset` or its subtypes. - Like :cfunc:`PyTuple_SetItem` in that it can be used to fill-in the - values of brand new frozensets before they are exposed to other code. - -The following functions are available for instances of :class:`set` or its -subtypes but not for instances of :class:`frozenset` or its subtypes. - .. cfunction:: int PySet_Discard(PyObject *set, PyObject *key) Modified: python/trunk/Objects/setobject.c ============================================================================== --- python/trunk/Objects/setobject.c (original) +++ python/trunk/Objects/setobject.c Sat Jan 26 10:31:11 2008 @@ -2198,6 +2198,10 @@ int PySet_Add(PyObject *set, PyObject *key) { + if (!PyType_IsSubtype(Py_TYPE(set), &PySet_Type)) { + PyErr_BadInternalCall(); + return -1; + } return set_add_key((PySetObject *)set, key); } @@ -2341,6 +2345,7 @@ f = PyFrozenSet_New(dup); assert(PySet_Size(f) == 3); assert(PyFrozenSet_CheckExact(f)); + assertRaises(PySet_Add(f, elem) == -1, PyExc_SystemError); assertRaises(PySet_Discard(f, elem) == -1, PyExc_SystemError); assertRaises(PySet_Pop(f) == NULL, PyExc_SystemError); Py_DECREF(f); Modified: python/trunk/Python/marshal.c ============================================================================== --- python/trunk/Python/marshal.c (original) +++ python/trunk/Python/marshal.c Sat Jan 26 10:31:11 2008 @@ -860,7 +860,7 @@ retval = NULL; break; } - v = (type == TYPE_SET) ? PySet_New(NULL) : PyFrozenSet_New(NULL); + v = PyTuple_New((int)n); if (v == NULL) { retval = NULL; break; @@ -875,14 +875,18 @@ v = NULL; break; } - if (PySet_Add(v, v2) == -1) { - Py_DECREF(v); - Py_DECREF(v2); - v = NULL; - break; - } + PyTuple_SET_ITEM(v, (int)i, v2); } - retval = (v == NULL) ? NULL : v; + if (v == NULL) { + retval = NULL; + break; + } + if (type == TYPE_SET) + v3 = PySet_New(v); + else + v3 = PyFrozenSet_New(v); + Py_DECREF(v); + retval = v3; break; case TYPE_CODE: From python-checkins at python.org Sat Jan 26 10:43:35 2008 From: python-checkins at python.org (georg.brandl) Date: Sat, 26 Jan 2008 10:43:35 +0100 (CET) Subject: [Python-checkins] r60314 - python/trunk/Doc/library/os.path.rst Message-ID: <20080126094335.BEFEB1E4010@bag.python.org> Author: georg.brandl Date: Sat Jan 26 10:43:35 2008 New Revision: 60314 Modified: python/trunk/Doc/library/os.path.rst Log: #1934: fix os.path.isabs docs. Modified: python/trunk/Doc/library/os.path.rst ============================================================================== --- python/trunk/Doc/library/os.path.rst (original) +++ python/trunk/Doc/library/os.path.rst Sat Jan 26 10:43:35 2008 @@ -144,7 +144,9 @@ .. function:: isabs(path) - Return ``True`` if *path* is an absolute pathname (begins with a slash). + Return ``True`` if *path* is an absolute pathname. On Unix, that means it + begins with a slash, on Windows that it begins with a backslash after chopping + off a potential drive letter. .. function:: isfile(path) From buildbot at python.org Sat Jan 26 11:03:10 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 26 Jan 2008 10:03:10 +0000 Subject: [Python-checkins] buildbot failure in x86 mvlgcc trunk Message-ID: <20080126100310.7B0031E4010@bag.python.org> The Buildbot has detected a new failure of x86 mvlgcc trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20mvlgcc%20trunk/builds/1331 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-linux Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_xmlrpc make: *** [buildbottest] Fehler 1 sincerely, -The Buildbot From buildbot at python.org Sat Jan 26 11:15:10 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 26 Jan 2008 10:15:10 +0000 Subject: [Python-checkins] buildbot failure in x86 XP-3 trunk Message-ID: <20080126101510.B8DE81E401F@bag.python.org> The Buildbot has detected a new failure of x86 XP-3 trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20XP-3%20trunk/builds/766 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: heller-windows Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: 2 tests failed: test_mailbox test_zipfile ====================================================================== ERROR: test_consistent_factory (test.test_mailbox.TestMaildir) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\trunk.heller-windows\build\lib\test\test_mailbox.py", line 523, in test_consistent_factory msg2 = box.get_message(key) File "C:\buildbot\work\trunk.heller-windows\build\lib\mailbox.py", line 315, in get_message subpath = self._lookup(key) File "C:\buildbot\work\trunk.heller-windows\build\lib\mailbox.py", line 484, in _lookup raise KeyError('No message with key: %s' % key) KeyError: 'No message with key: 1201354433.M921000P33336Q203.thomasxpbb' ====================================================================== ERROR: testExtract (test.test_zipfile.TestsWithSourceFile) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\trunk.heller-windows\build\lib\test\test_zipfile.py", line 357, in tearDown os.remove(TESTFN2) WindowsError: [Error 32] The process cannot access the file because it is being used by another process: '@test2' ====================================================================== FAIL: testExtract (test.test_zipfile.TestsWithSourceFile) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\trunk.heller-windows\build\lib\test\test_zipfile.py", line 320, in testExtract self.assertEqual(writtenfile, correctfile) AssertionError: 'C:\\buildbot\\work\\trunk.heller-windows\\build\\PCbuild\\ziptest2dir\\_ziptest2' != 'C:\\buildbot\\work\\trunk.heller-windows\\build\\PCbuild\\ziptest2dir/_ziptest2' sincerely, -The Buildbot From python-checkins at python.org Sat Jan 26 12:00:20 2008 From: python-checkins at python.org (georg.brandl) Date: Sat, 26 Jan 2008 12:00:20 +0100 (CET) Subject: [Python-checkins] r60316 - python/trunk/Lib/re.py Message-ID: <20080126110020.701551E4018@bag.python.org> Author: georg.brandl Date: Sat Jan 26 12:00:18 2008 New Revision: 60316 Modified: python/trunk/Lib/re.py Log: Add missing things in re docstring. Modified: python/trunk/Lib/re.py ============================================================================== --- python/trunk/Lib/re.py (original) +++ python/trunk/Lib/re.py Sat Jan 26 12:00:18 2008 @@ -38,7 +38,7 @@ *?,+?,?? Non-greedy versions of the previous three special characters. {m,n} Matches from m to n repetitions of the preceding RE. {m,n}? Non-greedy version of the above. - "\\" Either escapes special characters or signals a special sequence. + "\\" Either escapes special characters or signals a special sequence. [] Indicates a set of characters. A "^" as the first character indicates a complementing set. "|" A|B, creates an RE that will match either A or B. @@ -51,6 +51,10 @@ (?#...) A comment; ignored. (?=...) Matches if ... matches next, but doesn't consume the string. (?!...) Matches if ... doesn't match next. + (?<=...) Matches if preceded by ... (must be fixed length). + (? Author: georg.brandl Date: Sat Jan 26 12:02:22 2008 New Revision: 60317 Modified: python/trunk/Doc/library/os.path.rst Log: Slashes allowed on Windows. Modified: python/trunk/Doc/library/os.path.rst ============================================================================== --- python/trunk/Doc/library/os.path.rst (original) +++ python/trunk/Doc/library/os.path.rst Sat Jan 26 12:02:22 2008 @@ -145,7 +145,7 @@ .. function:: isabs(path) Return ``True`` if *path* is an absolute pathname. On Unix, that means it - begins with a slash, on Windows that it begins with a backslash after chopping + begins with a slash, on Windows that it begins with a (back)slash after chopping off a potential drive letter. From buildbot at python.org Sat Jan 26 12:33:43 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 26 Jan 2008 11:33:43 +0000 Subject: [Python-checkins] buildbot failure in x86 XP-4 trunk Message-ID: <20080126113344.5D68A1E4010@bag.python.org> The Buildbot has detected a new failure of x86 XP-4 trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20XP-4%20trunk/builds/554 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-windows Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: sincerely, -The Buildbot From python-checkins at python.org Sat Jan 26 14:41:21 2008 From: python-checkins at python.org (georg.brandl) Date: Sat, 26 Jan 2008 14:41:21 +0100 (CET) Subject: [Python-checkins] r60319 - python/trunk/Doc/c-api/module.rst Message-ID: <20080126134121.8D0C91E4025@bag.python.org> Author: georg.brandl Date: Sat Jan 26 14:41:21 2008 New Revision: 60319 Modified: python/trunk/Doc/c-api/module.rst Log: Fix markup again. Modified: python/trunk/Doc/c-api/module.rst ============================================================================== --- python/trunk/Doc/c-api/module.rst (original) +++ python/trunk/Doc/c-api/module.rst Sat Jan 26 14:41:21 2008 @@ -18,7 +18,7 @@ is exposed to Python programs as ``types.ModuleType``. -.. cmacro:: int PyModule_Check(PyObject *p) +.. cfunction:: int PyModule_Check(PyObject *p) Return true if *p* is a module object, or a subtype of a module object. @@ -26,7 +26,7 @@ Allowed subtypes to be accepted. -.. cmacro:: int PyModule_CheckExact(PyObject *p) +.. cfunction:: int PyModule_CheckExact(PyObject *p) Return true if *p* is a module object, but not a subtype of :cdata:`PyModule_Type`. @@ -104,7 +104,7 @@ .. versionadded:: 2.0 -.. cmacro:: int PyModule_AddIntMacro(PyObject *module, macro) +.. cfunction:: int PyModule_AddIntMacro(PyObject *module, macro) Add an int constant to *module*. The name and the value are taken from *macro*. For example ``PyModule_AddConstant(module, AF_INET)`` adds the int @@ -113,7 +113,7 @@ .. versionadded:: 2.6 -.. cmacro:: int PyModule_AddStringMacro(PyObject *module, macro) +.. cfunction:: int PyModule_AddStringMacro(PyObject *module, macro) Add a string constant to *module*. From python-checkins at python.org Sat Jan 26 14:50:51 2008 From: python-checkins at python.org (andrew.kuchling) Date: Sat, 26 Jan 2008 14:50:51 +0100 (CET) Subject: [Python-checkins] r60320 - python/trunk/Doc/whatsnew/2.6.rst Message-ID: <20080126135051.EAAFF1E4029@bag.python.org> Author: andrew.kuchling Date: Sat Jan 26 14:50:51 2008 New Revision: 60320 Modified: python/trunk/Doc/whatsnew/2.6.rst Log: Add some items Modified: python/trunk/Doc/whatsnew/2.6.rst ============================================================================== --- python/trunk/Doc/whatsnew/2.6.rst (original) +++ python/trunk/Doc/whatsnew/2.6.rst Sat Jan 26 14:50:51 2008 @@ -3,6 +3,7 @@ **************************** .. XXX mention switch to Roundup for bug tracking +.. XXX add trademark info for Apple, Microsoft. :Author: A.M. Kuchling :Release: |release| @@ -909,7 +910,13 @@ * An optional ``timeout`` parameter was added to the :class:`ftplib.FTP` class constructor as well as the :meth:`connect` method, specifying a timeout measured in seconds. (Added by Facundo - Batista.) + Batista.) Also, the :class:`FTP` class's + :meth:`storbinary` and :meth:`storlines` + now take an optional *callback* parameter that will be called with + each block of data after the data has been sent. + (Contributed by Phil Schwartz.) + + .. Patch 1221598 * The :func:`reduce` built-in function is also available in the :mod:`functools` module. In Python 3.0, the built-in is dropped and it's @@ -1041,6 +1048,13 @@ .. Patch 1137 +* The :mod:`Queue` module now provides queue classes that retrieve entries + in different orders. The :class:`PriorityQueue` class stores + queued items in a heap and retrieves them in priority order, + and :class:`LifoQueue` retrieves the most recently added entries first, + meaning that it behaves like a stack. + (Contributed by Raymond Hettinger.) + * The :mod:`random` module's :class:`Random` objects can now be pickled on a 32-bit system and unpickled on a 64-bit system, and vice versa. Unfortunately, this change also means @@ -1304,6 +1318,47 @@ SSL module documentation. + +.. ====================================================================== + +plistlib: A Property-List Parser +-------------------------------------------------- + +A commonly-used format on MacOS X is the ``.plist`` format, +which stores basic data types (numbers, strings, lists, +and dictionaries) and serializes them into an XML-based format. +(It's a lot like the XML-RPC serialization of data types.) + +Despite being primarily used on MacOS X, the format +has nothing Mac-specific about it and the Python implementation works +on any platform that Python supports, so the :mod:`plistlib` module +has been promoted to the standard library. + +Using the module is simple:: + + import sys + import plistlib + import datetime + + # Create data structure + data_struct = dict(lastAccessed=datetime.datetime.now(), + version=1, + categories=('Personal', 'Shared', 'Private')) + + # Create string containing XML. + plist_str = plistlib.writePlistToString(data_struct) + new_struct = plistlib.readPlistFromString(plist_str) + print data_struct + print new_struct + + # Write data structure to a file and read it back. + plistlib.writePlist(data_struct, '/tmp/customizations.plist') + new_struct = plistlib.readPlist('/tmp/customizations.plist') + + # read/writePlist accepts file-like objects as well as paths. + plistlib.writePlist(data_struct, sys.stdout) + + .. ====================================================================== @@ -1351,6 +1406,13 @@ .. Issue 1629 +* Distutils now places C extensions it builds in a + different directory when running on a debug version of Python. + (Contributed by Collin Winter.) + + .. Patch 1530959 + + .. ====================================================================== From python-checkins at python.org Sat Jan 26 15:02:39 2008 From: python-checkins at python.org (georg.brandl) Date: Sat, 26 Jan 2008 15:02:39 +0100 (CET) Subject: [Python-checkins] r60321 - python/trunk/Doc/tutorial/inputoutput.rst Message-ID: <20080126140239.269541E4018@bag.python.org> Author: georg.brandl Date: Sat Jan 26 15:02:38 2008 New Revision: 60321 Modified: python/trunk/Doc/tutorial/inputoutput.rst Log: Clarify "b" mode under Unix. Modified: python/trunk/Doc/tutorial/inputoutput.rst ============================================================================== --- python/trunk/Doc/tutorial/inputoutput.rst (original) +++ python/trunk/Doc/tutorial/inputoutput.rst Sat Jan 26 15:02:38 2008 @@ -200,7 +200,8 @@ written. This behind-the-scenes modification to file data is fine for ASCII text files, but it'll corrupt binary data like that in :file:`JPEG` or :file:`EXE` files. Be very careful to use binary mode when reading and writing -such files. +such files. On Unix, it doesn't hurt to append a ``'b'`` to the mode, so +you can use it platform-independently for all binary files. .. _tut-filemethods: From python-checkins at python.org Sat Jan 26 15:03:47 2008 From: python-checkins at python.org (georg.brandl) Date: Sat, 26 Jan 2008 15:03:47 +0100 (CET) Subject: [Python-checkins] r60322 - in python/trunk: Misc/NEWS Modules/_cursesmodule.c Message-ID: <20080126140347.D6B2A1E4018@bag.python.org> Author: georg.brandl Date: Sat Jan 26 15:03:47 2008 New Revision: 60322 Modified: python/trunk/Misc/NEWS python/trunk/Modules/_cursesmodule.c Log: #1940: make it possible to use curses.filter() before curses.initscr() as the documentation says. Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Sat Jan 26 15:03:47 2008 @@ -1103,9 +1103,13 @@ does not claim to support starttls. Adds the SMTP.ehlo_or_helo_if_needed() method. Patch contributed by Bill Fenner. + Extension Modules ----------------- +- #1940: make it possible to use curses.filter() before curses.initscr() + as the documentation says. + - Backport of _fileio module from Python 3.0. - #1087741: mmap.mmap is now a class, not a factory function. It is also Modified: python/trunk/Modules/_cursesmodule.c ============================================================================== --- python/trunk/Modules/_cursesmodule.c (original) +++ python/trunk/Modules/_cursesmodule.c Sat Jan 26 15:03:47 2008 @@ -1677,11 +1677,20 @@ NoArgTrueFalseFunction(has_ic) NoArgTrueFalseFunction(has_il) NoArgTrueFalseFunction(isendwin) -NoArgNoReturnVoidFunction(filter) NoArgNoReturnVoidFunction(flushinp) NoArgNoReturnVoidFunction(noqiflush) static PyObject * +PyCurses_filter(PyObject *self) +{ + /* not checking for PyCursesInitialised here since filter() must + be called before initscr() */ + filter(); + Py_INCREF(Py_None); + return Py_None; +} + +static PyObject * PyCurses_Color_Content(PyObject *self, PyObject *args) { short color,r,g,b; From python-checkins at python.org Sat Jan 26 15:03:52 2008 From: python-checkins at python.org (georg.brandl) Date: Sat, 26 Jan 2008 15:03:52 +0100 (CET) Subject: [Python-checkins] r60323 - in python/branches/release25-maint: Misc/NEWS Modules/_cursesmodule.c Message-ID: <20080126140352.3B09C1E4018@bag.python.org> Author: georg.brandl Date: Sat Jan 26 15:03:51 2008 New Revision: 60323 Modified: python/branches/release25-maint/Misc/NEWS python/branches/release25-maint/Modules/_cursesmodule.c Log: #1940: make it possible to use curses.filter() before curses.initscr() as the documentation says. (backport from rev. 60322) Modified: python/branches/release25-maint/Misc/NEWS ============================================================================== --- python/branches/release25-maint/Misc/NEWS (original) +++ python/branches/release25-maint/Misc/NEWS Sat Jan 26 15:03:51 2008 @@ -212,6 +212,9 @@ Extension Modules ----------------- +- #1940: make it possible to use curses.filter() before curses.initscr() + as the documentation says. + - Fix a potential 'SystemError: NULL result without error' in _ctypes. - Prevent a segfault when a ctypes NULL function pointer is called. Modified: python/branches/release25-maint/Modules/_cursesmodule.c ============================================================================== --- python/branches/release25-maint/Modules/_cursesmodule.c (original) +++ python/branches/release25-maint/Modules/_cursesmodule.c Sat Jan 26 15:03:51 2008 @@ -1619,11 +1619,20 @@ NoArgTrueFalseFunction(has_ic) NoArgTrueFalseFunction(has_il) NoArgTrueFalseFunction(isendwin) -NoArgNoReturnVoidFunction(filter) NoArgNoReturnVoidFunction(flushinp) NoArgNoReturnVoidFunction(noqiflush) static PyObject * +PyCurses_filter(PyObject *self) +{ + /* not checking for PyCursesInitialised here since filter() must + be called before initscr() */ + filter(); + Py_INCREF(Py_None); + return Py_None; +} + +static PyObject * PyCurses_Color_Content(PyObject *self, PyObject *args) { short color,r,g,b; From python-checkins at python.org Sat Jan 26 15:14:21 2008 From: python-checkins at python.org (georg.brandl) Date: Sat, 26 Jan 2008 15:14:21 +0100 (CET) Subject: [Python-checkins] r60324 - in python/trunk: Include/genobject.h Lib/test/test_generators.py Misc/NEWS Objects/genobject.c Message-ID: <20080126141421.5BA5C1E4018@bag.python.org> Author: georg.brandl Date: Sat Jan 26 15:14:20 2008 New Revision: 60324 Modified: python/trunk/Include/genobject.h python/trunk/Lib/test/test_generators.py python/trunk/Misc/NEWS python/trunk/Objects/genobject.c Log: #1473257: add generator.gi_code attribute that refers to the original code object backing the generator. Patch by Collin Winter. Modified: python/trunk/Include/genobject.h ============================================================================== --- python/trunk/Include/genobject.h (original) +++ python/trunk/Include/genobject.h Sat Jan 26 15:14:20 2008 @@ -18,6 +18,9 @@ /* True if generator is being executed. */ int gi_running; + + /* The code object backing the generator */ + PyObject *gi_code; /* List of weak reference. */ PyObject *gi_weakreflist; Modified: python/trunk/Lib/test/test_generators.py ============================================================================== --- python/trunk/Lib/test/test_generators.py (original) +++ python/trunk/Lib/test/test_generators.py Sat Jan 26 15:14:20 2008 @@ -382,7 +382,7 @@ >>> type(i) >>> [s for s in dir(i) if not s.startswith('_')] -['close', 'gi_frame', 'gi_running', 'next', 'send', 'throw'] +['close', 'gi_code', 'gi_frame', 'gi_running', 'next', 'send', 'throw'] >>> print i.next.__doc__ x.next() -> the next value, or raise StopIteration >>> iter(i) is i @@ -899,6 +899,24 @@ >>> print g.next() Traceback (most recent call last): StopIteration + + +Test the gi_code attribute + +>>> def f(): +... yield 5 +... +>>> g = f() +>>> g.gi_code is f.func_code +True +>>> g.next() +5 +>>> g.next() +Traceback (most recent call last): +StopIteration +>>> g.gi_code is f.func_code +True + """ # conjoin is a simple backtracking generator, named in honor of Icon's Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Sat Jan 26 15:14:20 2008 @@ -12,7 +12,11 @@ Core and builtins ----------------- -- Backport of PyUnicode_FromString(), _FromStringAndSize(), _Format and +- Patch #1473257: generator objects gain a gi_code attribute. This is the + same object as the func_code attribute of the function that produced the + generator. + + Backport of PyUnicode_FromString(), _FromStringAndSize(), _Format and _FormatV from Python 3.0. Made PyLong_AsSsize_t and PyLong_FromSsize_t public functions. Modified: python/trunk/Objects/genobject.c ============================================================================== --- python/trunk/Objects/genobject.c (original) +++ python/trunk/Objects/genobject.c Sat Jan 26 15:14:20 2008 @@ -11,6 +11,7 @@ gen_traverse(PyGenObject *gen, visitproc visit, void *arg) { Py_VISIT((PyObject *)gen->gi_frame); + Py_VISIT(gen->gi_code); return 0; } @@ -35,6 +36,7 @@ _PyObject_GC_UNTRACK(self); Py_CLEAR(gen->gi_frame); + Py_CLEAR(gen->gi_code); PyObject_GC_Del(gen); } @@ -282,6 +284,7 @@ static PyMemberDef gen_memberlist[] = { {"gi_frame", T_OBJECT, offsetof(PyGenObject, gi_frame), RO}, {"gi_running", T_INT, offsetof(PyGenObject, gi_running), RO}, + {"gi_code", T_OBJECT, offsetof(PyGenObject, gi_code), RO}, {NULL} /* Sentinel */ }; @@ -352,6 +355,8 @@ return NULL; } gen->gi_frame = f; + Py_INCREF(f->f_code); + gen->gi_code = (PyObject *)(f->f_code); gen->gi_running = 0; gen->gi_weakreflist = NULL; _PyObject_GC_TRACK(gen); From python-checkins at python.org Sat Jan 26 15:19:22 2008 From: python-checkins at python.org (georg.brandl) Date: Sat, 26 Jan 2008 15:19:22 +0100 (CET) Subject: [Python-checkins] r60325 - python/trunk/Misc/NEWS Message-ID: <20080126141922.81CF31E401A@bag.python.org> Author: georg.brandl Date: Sat Jan 26 15:19:22 2008 New Revision: 60325 Modified: python/trunk/Misc/NEWS Log: Move C API entries to the corresponding section. Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Sat Jan 26 15:19:22 2008 @@ -16,10 +16,6 @@ same object as the func_code attribute of the function that produced the generator. - Backport of PyUnicode_FromString(), _FromStringAndSize(), _Format and - _FormatV from Python 3.0. Made PyLong_AsSsize_t and PyLong_FromSsize_t - public functions. - - Issue #1920: "while 0" statements were completely removed by the compiler, even in the presence of an "else" clause, which is supposed to be run when the condition is false. Now the compiler correctly emits bytecode for the @@ -37,14 +33,12 @@ several extension methods and modules do not work without unicode support. -- Patch #1720595: add T_BOOL to the range of structmember types. - - Issue #1882: when compiling code from a string, encoding cookies in the second line of code were not always recognized correctly. - Issue #1679: "0x" was taken as a valid integer literal. -- Issue #1865: Bytes as an alias for str and b"" as an alias "" were +- Issue #1865: ``bytes`` as an alias for ``str`` and b"" as an alias "" were added. - sys.float_info / PyFloat_GetInfo: The floating point information @@ -53,7 +47,7 @@ - Patch #1816: Added sys.flags structseq. It exposes the status of most command line arguments and PYTHON* environment variables. -- Object/structseq.c: Implemented new structseq representation. The patch +- Objects/structseq.c: Implemented new structseq representation. The patch makes structseqs (e.g. the return value of os.stat) more readable. - Patch #1700288: added a type attribute cache that caches method accesses, @@ -104,14 +98,6 @@ inside packages with the -m switch via a new module level __package__ attribute. -- Issue #1534: Added ``PyFloat_GetMax()``, ``PyFloat_GetMin()`` and - ``PyFloat_GetInfo()`` to the float API. - -- Issue #1521: On 64bit platforms, using PyArgs_ParseTuple with the t# of w# - format code incorrectly truncated the length to an int, even when - PY_SSIZE_T_CLEAN is set. The str.decode method used to return incorrect - results with huge strings. - - Issue #1402: Fix a crash on exit, when another thread is still running, and if the deallocation of its frames somehow calls the PyGILState_Ensure() / PyGILState_Release() functions. @@ -168,19 +154,9 @@ - Patch #1031213: Decode source line in SyntaxErrors back to its original source encoding. -- Py_ssize_t fields work in structmember when HAVE_LONG_LONG is not defined. - -- PEP 3123: Provide forward compatibility with Python 3.0, while keeping - backwards compatibility. Add Py_Refcnt, Py_Type, Py_Size, and - PyVarObject_HEAD_INIT. - - Patch #1673759: add a missing overflow check when formatting floats with %G. -- Patch #1733960: Allow T_LONGLONG to accept ints. - -- T_PYSSIZET can now be used in PyMemberDef lists for Py_ssize_t members. - - Prevent expandtabs() on string and unicode objects from causing a segfault when a large width is passed on 32-bit platforms. @@ -296,8 +272,6 @@ - patch #1630975: Fix crash when replacing sys.stdout in sitecustomize.py -- Bug #1637022: Prefix AST symbols with _Py_. - - Prevent seg fault on shutdown which could occur if an object raised a warning. @@ -337,9 +311,6 @@ - list.pop(x) accepts any object x following the __index__ protocol. -- Fix some leftovers from the conversion from int to Py_ssize_t - (relevant to strings and sequences of more than 2**31 items). - - A number of places, including integer negation and absolute value, were fixed to not rely on undefined behaviour of the C compiler anymore. @@ -364,9 +335,6 @@ - Bug #1551432: Exceptions do not define an explicit __unicode__ method. This allows calling unicode() on exceptions classes directly to succeed. -- Make _PyGILState_NoteThreadState() static, it was not used anywhere - outside of pystate.c and should not be necessary. - - Bug #1542051: Exceptions now correctly call PyObject_GC_UnTrack. Also make sure that every exception class has __module__ set to 'exceptions'. @@ -389,7 +357,7 @@ required changing the .pyc magic number. This means that .pyc files generated before 2.5c2 will be regenerated. -- with and as are now keywords. +- ``with`` and ``as`` are now keywords. - Bug #1664966: Fix crash in exec if Unicode filename can't be decoded. @@ -400,6 +368,7 @@ threading.enumerate() list after the join() for a brief period until it actually exited. + Library ------- @@ -1342,6 +1311,7 @@ platform.python_implementation(); this will now be saved in the benchmark pickle + Documentation ------------- @@ -1473,18 +1443,51 @@ - Makefile.pre.in(buildbottest): Run an optional script pybuildbot.identify to include some information about the build environment. + C API ----- +- Backport of PyUnicode_FromString(), _FromStringAndSize(), _Format and + _FormatV from Python 3.0. Made PyLong_AsSsize_t and PyLong_FromSsize_t + public functions. + +- Patch #1720595: add T_BOOL to the range of structmember types. + +- Issue #1534: Added ``PyFloat_GetMax()``, ``PyFloat_GetMin()`` and + ``PyFloat_GetInfo()`` to the float API. + +- Issue #1521: On 64bit platforms, using PyArgs_ParseTuple with the t# of w# + format code incorrectly truncated the length to an int, even when + PY_SSIZE_T_CLEAN is set. The str.decode method used to return incorrect + results with huge strings. + +- Issue #1629: Renamed Py_Size, Py_Type and Py_Refcnt to Py_SIZE, Py_TYPE + and Py_REFCNT. + +- PEP 3123: Provide forward compatibility with Python 3.0, while keeping + backwards compatibility. Add Py_Refcnt, Py_Type, Py_Size, and + PyVarObject_HEAD_INIT. + +- Py_ssize_t fields work in structmember when HAVE_LONG_LONG is not defined. + +- Patch #1733960: Allow T_LONGLONG to accept ints. + +- T_PYSSIZET can now be used in PyMemberDef lists for Py_ssize_t members. + - Added a new API function ``PyImport_ImportModuleNoBlock``. +- Bug #1637022: Prefix AST symbols with _Py_. + +- Fix some leftovers from the conversion from int to Py_ssize_t + (relevant to strings and sequences of more than 2**31 items). + +- Make _PyGILState_NoteThreadState() static, it was not used anywhere + outside of pystate.c and should not be necessary. + - ``PyImport_Import`` and ``PyImport_ImportModule`` now always do absolute imports. In earlier versions they might have used relative imports under some conditions. -- Issue #1629: Renamed Py_Size, Py_Type and Py_Refcnt to Py_SIZE, Py_TYPE - and Py_REFCNT. - - Added case insensitive comparison methods ``PyOS_stricmp(char*, char*)`` and ``PyOS_strnicmp(char*, char*, Py_ssize_t)``. From buildbot at python.org Sat Jan 26 16:17:22 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 26 Jan 2008 15:17:22 +0000 Subject: [Python-checkins] buildbot failure in alpha Tru64 5.1 trunk Message-ID: <20080126151723.1718C1E4018@bag.python.org> The Buildbot has detected a new failure of alpha Tru64 5.1 trunk. Full details are available at: http://www.python.org/dev/buildbot/all/alpha%20Tru64%205.1%20trunk/builds/2415 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-tru64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: andrew.kuchling,georg.brandl BUILD FAILED: failed test Excerpt from the test logfile: sincerely, -The Buildbot From buildbot at python.org Sat Jan 26 16:19:52 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 26 Jan 2008 15:19:52 +0000 Subject: [Python-checkins] buildbot failure in x86 gentoo 2.5 Message-ID: <20080126151952.D6F551E4018@bag.python.org> The Buildbot has detected a new failure of x86 gentoo 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20gentoo%202.5/builds/528 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-x86 Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: georg.brandl BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/home/buildslave/python-trunk/2.5.norwitz-x86/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildslave/python-trunk/2.5.norwitz-x86/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildslave/python-trunk/2.5.norwitz-x86/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/home/buildslave/python-trunk/2.5.norwitz-x86/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30996, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Traceback (most recent call last): File "/home/buildslave/python-trunk/2.5.norwitz-x86/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildslave/python-trunk/2.5.norwitz-x86/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildslave/python-trunk/2.5.norwitz-x86/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/home/buildslave/python-trunk/2.5.norwitz-x86/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30996, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Traceback (most recent call last): File "/home/buildslave/python-trunk/2.5.norwitz-x86/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildslave/python-trunk/2.5.norwitz-x86/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildslave/python-trunk/2.5.norwitz-x86/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/home/buildslave/python-trunk/2.5.norwitz-x86/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30996, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Traceback (most recent call last): File "/home/buildslave/python-trunk/2.5.norwitz-x86/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildslave/python-trunk/2.5.norwitz-x86/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildslave/python-trunk/2.5.norwitz-x86/build/Lib/bsddb/test/test_thread.py", line 281, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/home/buildslave/python-trunk/2.5.norwitz-x86/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30996, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Traceback (most recent call last): File "/home/buildslave/python-trunk/2.5.norwitz-x86/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildslave/python-trunk/2.5.norwitz-x86/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildslave/python-trunk/2.5.norwitz-x86/build/Lib/bsddb/test/test_thread.py", line 260, in writerThread self.assertEqual(data, self.makeData(key)) File "/home/buildslave/python-trunk/2.5.norwitz-x86/build/Lib/unittest.py", line 334, in failUnlessEqual (msg or '%r != %r' % (first, second)) AssertionError: None != '2002-2002-2002-2002-2002' Traceback (most recent call last): File "/home/buildslave/python-trunk/2.5.norwitz-x86/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildslave/python-trunk/2.5.norwitz-x86/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildslave/python-trunk/2.5.norwitz-x86/build/Lib/bsddb/test/test_thread.py", line 260, in writerThread self.assertEqual(data, self.makeData(key)) File "/home/buildslave/python-trunk/2.5.norwitz-x86/build/Lib/unittest.py", line 334, in failUnlessEqual (msg or '%r != %r' % (first, second)) AssertionError: None != '0004-0004-0004-0004-0004' Traceback (most recent call last): File "/home/buildslave/python-trunk/2.5.norwitz-x86/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildslave/python-trunk/2.5.norwitz-x86/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildslave/python-trunk/2.5.norwitz-x86/build/Lib/bsddb/test/test_thread.py", line 260, in writerThread self.assertEqual(data, self.makeData(key)) File "/home/buildslave/python-trunk/2.5.norwitz-x86/build/Lib/unittest.py", line 334, in failUnlessEqual (msg or '%r != %r' % (first, second)) AssertionError: None != '1007-1007-1007-1007-1007' Traceback (most recent call last): File "/home/buildslave/python-trunk/2.5.norwitz-x86/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildslave/python-trunk/2.5.norwitz-x86/build/Lib/test/test_asynchat.py", line 17, in run PORT = test_support.bind_port(sock, HOST, PORT) File "/home/buildslave/python-trunk/2.5.norwitz-x86/build/Lib/test/test_support.py", line 108, in bind_port raise TestFailed, 'unable to find port to listen on' TestFailed: unable to find port to listen on sincerely, -The Buildbot From buildbot at python.org Sat Jan 26 16:47:56 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 26 Jan 2008 15:47:56 +0000 Subject: [Python-checkins] buildbot failure in x86 FreeBSD trunk Message-ID: <20080126154756.C5DB71E4018@bag.python.org> The Buildbot has detected a new failure of x86 FreeBSD trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20FreeBSD%20trunk/builds/479 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-freebsd Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: georg.brandl BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_smtplib ====================================================================== ERROR: testSend (test.test_smtplib.DebuggingServerTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/test/test_smtplib.py", line 249, in testSend smtp = smtplib.SMTP(HOST, PORT, local_hostname='localhost', timeout=3) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/smtplib.py", line 237, in __init__ (code, msg) = self.connect(host, port) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/smtplib.py", line 294, in connect (code, msg) = self.getreply() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/smtplib.py", line 335, in getreply line = self.file.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) timeout: timed out sincerely, -The Buildbot From buildbot at python.org Sat Jan 26 16:54:53 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 26 Jan 2008 15:54:53 +0000 Subject: [Python-checkins] buildbot failure in x86 gentoo trunk Message-ID: <20080126155453.69FBE1E4018@bag.python.org> The Buildbot has detected a new failure of x86 gentoo trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20gentoo%20trunk/builds/2964 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-x86 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: georg.brandl BUILD FAILED: failed test Excerpt from the test logfile: sincerely, -The Buildbot From nnorwitz at gmail.com Sat Jan 26 17:18:48 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Sat, 26 Jan 2008 11:18:48 -0500 Subject: [Python-checkins] Python Regression Test Failures refleak (9) Message-ID: <20080126161848.GA12134@python.psfb.org> test_opcodes leaked [0, -2, 2] references, sum=0 test_doctest leaked [0, 0, -2] references, sum=-2 test_cmd_line leaked [0, -23, 0] references, sum=-23 test_descrtut leaked [0, 2, -6] references, sum=-4 test_dummy_threading leaked [0, -2, 0] references, sum=-2 test_functools leaked [-2, -2, -2] references, sum=-6 test_gc leaked [0, 4, 0] references, sum=4 test_gdbm leaked [-2, 0, 0] references, sum=-2 test_generators leaked [0, -2, 2] references, sum=0 test_importhooks leaked [-4, -4, 6] references, sum=-2 test_marshal leaked [32, 32, 32] references, sum=96 test_parser leaked [0, -2, 0] references, sum=-2 From python-checkins at python.org Sat Jan 26 17:43:35 2008 From: python-checkins at python.org (christian.heimes) Date: Sat, 26 Jan 2008 17:43:35 +0100 (CET) Subject: [Python-checkins] r60326 - python/trunk/Lib/test/test_zipfile.py Message-ID: <20080126164335.9406D1E4018@bag.python.org> Author: christian.heimes Date: Sat Jan 26 17:43:35 2008 New Revision: 60326 Modified: python/trunk/Lib/test/test_zipfile.py Log: Unit test fix from Giampaolo Rodola, #1938 Modified: python/trunk/Lib/test/test_zipfile.py ============================================================================== --- python/trunk/Lib/test/test_zipfile.py (original) +++ python/trunk/Lib/test/test_zipfile.py Sat Jan 26 17:43:35 2008 @@ -316,6 +316,7 @@ correctfile = os.path.join(os.getcwd(), fpath[1:]) else: correctfile = os.path.join(os.getcwd(), fpath) + correctfile = os.path.normpath(correctfile) self.assertEqual(writtenfile, correctfile) From python-checkins at python.org Sat Jan 26 19:51:06 2008 From: python-checkins at python.org (gregory.p.smith) Date: Sat, 26 Jan 2008 19:51:06 +0100 (CET) Subject: [Python-checkins] r60327 - python/trunk/Doc/library/ftplib.rst Message-ID: <20080126185106.3631B1E4026@bag.python.org> Author: gregory.p.smith Date: Sat Jan 26 19:51:05 2008 New Revision: 60327 Modified: python/trunk/Doc/library/ftplib.rst Log: Update docs for new callpack params added in r60188 Modified: python/trunk/Doc/library/ftplib.rst ============================================================================== --- python/trunk/Doc/library/ftplib.rst (original) +++ python/trunk/Doc/library/ftplib.rst Sat Jan 26 19:51:05 2008 @@ -182,11 +182,12 @@ .. method:: FTP.retrlines(command[, callback]) - Retrieve a file or directory listing in ASCII transfer mode. *command* should be - an appropriate ``RETR`` command (see :meth:`retrbinary`) or a ``LIST`` command - (usually just the string ``'LIST'``). The *callback* function is called for - each line, with the trailing CRLF stripped. The default *callback* prints the - line to ``sys.stdout``. + Retrieve a file or directory listing in ASCII transfer mode. *command* + should be an appropriate ``RETR`` command (see :meth:`retrbinary`) or a + command such as ``LIST``, ``NLST`` or ``MLSD`` (usually just the string + ``'LIST'``). The *callback* function is called for each line, with the + trailing CRLF stripped. The default *callback* prints the line to + ``sys.stdout``. .. method:: FTP.set_pasv(boolean) @@ -196,23 +197,32 @@ it is on by default.) -.. method:: FTP.storbinary(command, file[, blocksize]) +.. method:: FTP.storbinary(command, file[, blocksize, callback]) Store a file in binary transfer mode. *command* should be an appropriate ``STOR`` command: ``"STOR filename"``. *file* is an open file object which is read until EOF using its :meth:`read` method in blocks of size *blocksize* to provide the data to be stored. The *blocksize* argument defaults to 8192. + *callback* is an optional single parameter callable that is called + on each block of data after it is sent. .. versionchanged:: 2.1 default for *blocksize* added. + .. versionchanged:: 2.6 + *callback* parameter added. -.. method:: FTP.storlines(command, file) + +.. method:: FTP.storlines(command, file[, callback]) Store a file in ASCII transfer mode. *command* should be an appropriate ``STOR`` command (see :meth:`storbinary`). Lines are read until EOF from the open file object *file* using its :meth:`readline` method to provide the data to - be stored. + be stored. *callback* is an optional single parameter callable + that is called on each line after it is sent. + + .. versionchanged:: 2.6 + *callback* parameter added. .. method:: FTP.transfercmd(cmd[, rest]) From buildbot at python.org Sat Jan 26 20:46:08 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 26 Jan 2008 19:46:08 +0000 Subject: [Python-checkins] buildbot failure in x86 XP-3 trunk Message-ID: <20080126194608.678461E4018@bag.python.org> The Buildbot has detected a new failure of x86 XP-3 trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20XP-3%20trunk/builds/773 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: heller-windows Build Reason: The web-page 'rebuild' button was pressed by '': restarted machine Build Source Stamp: [branch trunk] HEAD Blamelist: christian.heimes,georg.brandl BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_mailbox ====================================================================== ERROR: test_consistent_factory (test.test_mailbox.TestMaildir) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\trunk.heller-windows\build\lib\test\test_mailbox.py", line 523, in test_consistent_factory msg2 = box.get_message(key) File "C:\buildbot\work\trunk.heller-windows\build\lib\mailbox.py", line 315, in get_message subpath = self._lookup(key) File "C:\buildbot\work\trunk.heller-windows\build\lib\mailbox.py", line 484, in _lookup raise KeyError('No message with key: %s' % key) KeyError: 'No message with key: 1201378216.M841000P3416Q203.thomasxpbb' sincerely, -The Buildbot From python-checkins at python.org Sat Jan 26 21:24:36 2008 From: python-checkins at python.org (neal.norwitz) Date: Sat, 26 Jan 2008 21:24:36 +0100 (CET) Subject: [Python-checkins] r60329 - python/trunk/Modules/mmapmodule.c Message-ID: <20080126202436.952831E401A@bag.python.org> Author: neal.norwitz Date: Sat Jan 26 21:24:36 2008 New Revision: 60329 Modified: python/trunk/Modules/mmapmodule.c Log: Cleanup the code a bit. test_rfind is failing on PPC and PPC64 buildbots, this might fix the problem. Modified: python/trunk/Modules/mmapmodule.c ============================================================================== --- python/trunk/Modules/mmapmodule.c (original) +++ python/trunk/Modules/mmapmodule.c Sat Jan 26 21:24:36 2008 @@ -253,8 +253,8 @@ int reverse) { Py_ssize_t start = self->pos; - Py_ssize_t end = self->size; - char *needle; + Py_ssize_t end = self->size; + const char *needle; Py_ssize_t len; CHECK_VALID(NULL); @@ -262,7 +262,7 @@ &needle, &len, &start, &end)) { return NULL; } else { - char *p; + const char *p, *start_p, *end_p; char sign = reverse ? -1 : 1; if (start < 0) @@ -279,11 +279,11 @@ else if ((size_t)end > self->size) end = self->size; - start += (Py_ssize_t)self->data; - end += (Py_ssize_t)self->data; + start_p = self->data + start; + end_p = self->data + end; - for (p = (char *)(reverse ? end - len : start); - p >= (char *)start && p + len <= (char *)end; p+=sign) { + for (p = (reverse ? end_p - len : start_p); + (p >= start_p) && (p + len <= end_p); p += sign) { Py_ssize_t i; for (i = 0; i < len && needle[i] == p[i]; ++i) /* nothing */; From buildbot at python.org Sat Jan 26 21:53:39 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 26 Jan 2008 20:53:39 +0000 Subject: [Python-checkins] buildbot failure in hppa Ubuntu trunk Message-ID: <20080126205339.9B5BD1E4018@bag.python.org> The Buildbot has detected a new failure of hppa Ubuntu trunk. Full details are available at: http://www.python.org/dev/buildbot/all/hppa%20Ubuntu%20trunk/builds/543 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-ubuntu-hppa Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: gregory.p.smith,neal.norwitz BUILD FAILED: failed test Excerpt from the test logfile: make: *** [buildbottest] Segmentation fault sincerely, -The Buildbot From buildbot at python.org Sat Jan 26 21:55:18 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 26 Jan 2008 20:55:18 +0000 Subject: [Python-checkins] buildbot failure in x86 gentoo trunk Message-ID: <20080126205518.228D61E4018@bag.python.org> The Buildbot has detected a new failure of x86 gentoo trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20gentoo%20trunk/builds/2966 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-x86 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: gregory.p.smith,neal.norwitz BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/test/test_thread.py", line 284, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30996, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Traceback (most recent call last): File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/test/test_thread.py", line 284, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30996, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Traceback (most recent call last): File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/test/test_thread.py", line 284, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30996, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Traceback (most recent call last): File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/test/test_thread.py", line 284, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30996, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Traceback (most recent call last): File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/test/test_thread.py", line 284, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30996, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') 1 test failed: test_telnetlib make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Sat Jan 26 22:02:45 2008 From: python-checkins at python.org (neal.norwitz) Date: Sat, 26 Jan 2008 22:02:45 +0100 (CET) Subject: [Python-checkins] r60330 - python/trunk/Lib/test/test_resource.py Message-ID: <20080126210245.6853F1E4018@bag.python.org> Author: neal.norwitz Date: Sat Jan 26 22:02:45 2008 New Revision: 60330 Modified: python/trunk/Lib/test/test_resource.py Log: Always try to remove the test file even if close raises an exception Modified: python/trunk/Lib/test/test_resource.py ============================================================================== --- python/trunk/Lib/test/test_resource.py (original) +++ python/trunk/Lib/test/test_resource.py Sat Jan 26 22:02:45 2008 @@ -15,7 +15,6 @@ self.assertRaises(TypeError, resource.setrlimit, 42, 42, 42) def test_fsize_ismax(self): - try: (cur, max) = resource.getrlimit(resource.RLIMIT_FSIZE) except AttributeError: @@ -63,10 +62,10 @@ resource.setrlimit(resource.RLIMIT_FSIZE, (cur, max)) finally: f.close() - os.unlink(test_support.TESTFN) finally: if limit_set: resource.setrlimit(resource.RLIMIT_FSIZE, (cur, max)) + test_support.unlink(test_support.TESTFN) def test_fsize_toobig(self): # Be sure that setrlimit is checking for really large values From python-checkins at python.org Sat Jan 26 22:21:59 2008 From: python-checkins at python.org (neal.norwitz) Date: Sat, 26 Jan 2008 22:21:59 +0100 (CET) Subject: [Python-checkins] r60331 - python/trunk/Lib/test/test_telnetlib.py Message-ID: <20080126212159.6B0D41E4018@bag.python.org> Author: neal.norwitz Date: Sat Jan 26 22:21:59 2008 New Revision: 60331 Modified: python/trunk/Lib/test/test_telnetlib.py Log: Reduce the race condition by signalling when the server is ready and not trying to connect before. Modified: python/trunk/Lib/test/test_telnetlib.py ============================================================================== --- python/trunk/Lib/test/test_telnetlib.py (original) +++ python/trunk/Lib/test/test_telnetlib.py Sat Jan 26 22:21:59 2008 @@ -13,6 +13,7 @@ serv.setsockopt(socket.SOL_SOCKET, socket.SO_REUSEADDR, 1) serv.bind(("", 9091)) serv.listen(5) + evt.set() try: conn, addr = serv.accept() except socket.timeout: @@ -26,6 +27,8 @@ def setUp(self): self.evt = threading.Event() threading.Thread(target=server, args=(self.evt,)).start() + self.evt.wait() + self.evt.clear() time.sleep(.1) def tearDown(self): From buildbot at python.org Sat Jan 26 22:29:37 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 26 Jan 2008 21:29:37 +0000 Subject: [Python-checkins] buildbot failure in amd64 gentoo trunk Message-ID: <20080126212937.D8F021E4018@bag.python.org> The Buildbot has detected a new failure of amd64 gentoo trunk. Full details are available at: http://www.python.org/dev/buildbot/all/amd64%20gentoo%20trunk/builds/40 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-amd64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: neal.norwitz BUILD FAILED: failed failed slave lost sincerely, -The Buildbot From buildbot at python.org Sat Jan 26 23:14:55 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 26 Jan 2008 22:14:55 +0000 Subject: [Python-checkins] buildbot failure in x86 XP-3 3.0 Message-ID: <20080126221455.ED2761E402C@bag.python.org> The Buildbot has detected a new failure of x86 XP-3 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20XP-3%203.0/builds/512 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: heller-windows Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: neal.norwitz BUILD FAILED: failed test Excerpt from the test logfile: 10 tests failed: test_anydbm test_bsddb test_bsddb3 test_mailbox test_plistlib test_shelve test_time test_urllib2net test_whichdb test_zipfile ====================================================================== ERROR: test_anydbm_access (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_anydbm.py", line 90, in test_anydbm_access self.init_db() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_anydbm.py", line 103, in init_db f = anydbm.open(_fname, 'n') File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_anydbm_creation (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_anydbm.py", line 63, in test_anydbm_creation f = anydbm.open(_fname, 'c') File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_anydbm_keys (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_anydbm.py", line 84, in test_anydbm_keys self.init_db() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_anydbm.py", line 103, in init_db f = anydbm.open(_fname, 'n') File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_anydbm_modification (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_anydbm.py", line 71, in test_anydbm_modification self.init_db() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_anydbm.py", line 103, in init_db f = anydbm.open(_fname, 'n') File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_anydbm_read (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_anydbm.py", line 78, in test_anydbm_read self.init_db() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_anydbm.py", line 103, in init_db f = anydbm.open(_fname, 'n') File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') Traceback (most recent call last): File "../lib/test/regrtest.py", line 596, in runtest_inner indirect_test() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb3.py", line 64, in test_main run_unittest(suite()) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_bsddb3.py", line 28, in suite import bsddb.test.test_1413192 File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\test\test_1413192.py", line 38, in context = Context() File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\test\test_1413192.py", line 26, in __init__ db.DB_CREATE | db.DB_INIT_TXN | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_consistent_factory (test.test_mailbox.TestMaildir) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 520, in test_consistent_factory msg2 = box.get_message(key) File "C:\buildbot\work\3.0.heller-windows\build\lib\mailbox.py", line 313, in get_message subpath = self._lookup(key) File "C:\buildbot\work\3.0.heller-windows\build\lib\mailbox.py", line 482, in _lookup raise KeyError('No message with key: %s' % key) KeyError: 'No message with key: 1201391193.M888000P2872Q201.thomasxpbb' ====================================================================== ERROR: test_flush (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 717, in tearDown self._delete_recursively(self._path) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 47, in _delete_recursively os.remove(target) WindowsError: [Error 32] The process cannot access the file because it is being used by another process: '@test' ====================================================================== ERROR: test_popitem (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 336, in test_popitem self.assertEqual(int(msg.get_payload()), keys.index(key)) ValueError: invalid literal for int() with base 10: 'From: foo 0 F' ====================================================================== ERROR: test_flush (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 717, in tearDown self._delete_recursively(self._path) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 47, in _delete_recursively os.remove(target) WindowsError: [Error 32] The process cannot access the file because it is being used by another process: '@test' ====================================================================== ERROR: test_popitem (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 336, in test_popitem self.assertEqual(int(msg.get_payload()), keys.index(key)) ValueError: invalid literal for int() with base 10: 'From: foo 0 \x01' ====================================================================== ERROR: test_flush (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 940, in tearDown self._delete_recursively(self._path) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 47, in _delete_recursively os.remove(target) WindowsError: [Error 32] The process cannot access the file because it is being used by another process: '@test' ====================================================================== ERROR: test_popitem (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 336, in test_popitem self.assertEqual(int(msg.get_payload()), keys.index(key)) ValueError: invalid literal for int() with base 10: 'From: foo *** EOOH *** From: foo 0 1,, From: foo *** EOOH *** From: foo 1 1,, From: foo *** EOOH *** From: foo 2 1,, From: foo *** EOOH *** From: foo 3 ' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestMaildir) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_add (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 77, in test_add self.assertEqual(self._box.get_string(keys[0]), self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\nF' != 'From: foo\n\n0' ====================================================================== FAIL: test_add_and_close (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 757, in test_add_and_close self.assertEqual(contents, open(self._path, 'r').read()) AssertionError: 'From MAILER-DAEMON Sat Jan 26 23:46:40 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Sat Jan 26 23:46:40 2008\n\nFrom: foo\n\n0\n\nFrom MAILER-DAEMON Sat Jan 26 23:46:40 2008\n\nFrom: foo\n\n1\n\nFrom MAILER-DAEMON Sat Jan 26 23:46:40 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Sat Jan 26 23:46:40 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'From MAILER-DAEMON Sat Jan 26 23:46:40 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Sat Jan 26 23:46:40 2008\n\nFrom: foo\n\n0\n\nFrom MAILER-DAEMON Sat Jan 26 23:46:40 2008\n\nFrom: foo\n\n1\n\nFrom MAILER-DAEMON Sat Jan 26 23:46:40 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Sat Jan 26 23:46:40 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Sat Jan 26 23:46:40 2008\n\nFrom: foo\n\n0\n\nFrom MAILER-DAEMON Sat Jan 26 23:46:40 2008\n\nFrom: foo\n\n1\n\nFrom MAILER-DAEMON Sat Jan 26 23:46:40 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Sat Jan 26 23:46:40 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Sat Jan 26 23:46:40 2008\n\nFrom: foo\n\n1\n\nFrom MAILER-DAEMON Sat Jan 26 23:46:40 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Sat Jan 26 23:46:40 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Sat Jan 26 23:46:40 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Sat Jan 26 23:46:40 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Sat Jan 26 23:46:40 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' ====================================================================== FAIL: test_add_from_string (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 724, in test_add_from_string self.assertEqual(self._box[key].get_from(), 'foo at bar blah') AssertionError: 'foo at bar blah\n' != 'foo at bar blah' ====================================================================== FAIL: test_close (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 389, in test_close self._test_flush_or_close(self._box.close) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 6 != 3 ====================================================================== FAIL: test_delitem (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 87, in test_delitem self._test_remove_or_delitem(self._box.__delitem__) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n1' != 'From: foo\n\n1' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_flush (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 377, in test_flush self._test_flush_or_close(self._box.flush) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 6 != 3 ====================================================================== FAIL: test_get (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 129, in test_get self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_file (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 174, in test_get_file self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\nF' != 'From: foo\n\n0' ====================================================================== FAIL: test_get_message (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 156, in test_get_message self.assertEqual(msg0['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_string (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 164, in test_get_string self.assertEqual(self._box.get_string(key0), self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\nF' != 'From: foo\n\n0' ====================================================================== FAIL: test_getitem (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 144, in test_getitem self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_items (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 207, in test_items self._check_iteration(self._box.items, do_keys=True, do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iter (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 194, in test_iter do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iteritems (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 203, in test_iteritems do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_itervalues (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 189, in test_itervalues do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_open_close_open (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 741, in test_open_close_open self.assertEqual(len(self._box), 3) AssertionError: 6 != 3 ====================================================================== FAIL: test_pop (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 313, in test_pop self.assertEqual(self._box.pop(key0).get_payload(), '0') AssertionError: 'From: foo\n\n0\n\nF' != '0' ====================================================================== FAIL: test_remove (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 83, in test_remove self._test_remove_or_delitem(self._box.remove) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n1' != 'From: foo\n\n1' ====================================================================== FAIL: test_set_item (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 272, in test_set_item self._template % 'original 0') AssertionError: '\nFrom: foo\n\noriginal 0' != 'From: foo\n\noriginal 0' ====================================================================== FAIL: test_update (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 350, in test_update self._template % 'changed 0') AssertionError: '\nFrom: foo\n\nchanged 0\n\nF' != 'From: foo\n\nchanged 0' ====================================================================== FAIL: test_values (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 198, in test_values self._check_iteration(self._box.values, do_keys=False, do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_add (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 77, in test_add self.assertEqual(self._box.get_string(keys[0]), self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\n\x01' != 'From: foo\n\n0' ====================================================================== FAIL: test_add_and_close (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 757, in test_add_and_close self.assertEqual(contents, open(self._path, 'r').read()) AssertionError: '\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sat Jan 26 23:46:44 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sat Jan 26 23:46:44 2008\n\nFrom: foo\n\n0\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sat Jan 26 23:46:44 2008\n\nFrom: foo\n\n1\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sat Jan 26 23:46:44 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sat Jan 26 23:46:44 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n' != '\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sat Jan 26 23:46:44 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sat Jan 26 23:46:44 2008\n\nFrom: foo\n\n0\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sat Jan 26 23:46:44 2008\n\nFrom: foo\n\n1\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sat Jan 26 23:46:44 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sat Jan 26 23:46:44 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sat Jan 26 23:46:44 2008\n\nFrom: foo\n\n0\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sat Jan 26 23:46:44 2008\n\nFrom: foo\n\n1\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sat Jan 26 23:46:44 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sat Jan 26 23:46:44 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sat Jan 26 23:46:44 2008\n\nFrom: foo\n\n1\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sat Jan 26 23:46:44 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sat Jan 26 23:46:44 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sat Jan 26 23:46:44 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sat Jan 26 23:46:44 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Sat Jan 26 23:46:44 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n' ====================================================================== FAIL: test_add_from_string (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 724, in test_add_from_string self.assertEqual(self._box[key].get_from(), 'foo at bar blah') AssertionError: 'foo at bar blah\n' != 'foo at bar blah' ====================================================================== FAIL: test_close (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 389, in test_close self._test_flush_or_close(self._box.close) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_delitem (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 87, in test_delitem self._test_remove_or_delitem(self._box.__delitem__) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n1\n\n\x01' != 'From: foo\n\n1' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_flush (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 377, in test_flush self._test_flush_or_close(self._box.flush) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_get (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 129, in test_get self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_file (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 174, in test_get_file self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\n\x01' != 'From: foo\n\n0' ====================================================================== FAIL: test_get_message (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 156, in test_get_message self.assertEqual(msg0['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_string (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 164, in test_get_string self.assertEqual(self._box.get_string(key0), self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\n\x01' != 'From: foo\n\n0' ====================================================================== FAIL: test_getitem (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 144, in test_getitem self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_items (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 207, in test_items self._check_iteration(self._box.items, do_keys=True, do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iter (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 194, in test_iter do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iteritems (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 203, in test_iteritems do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_itervalues (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 189, in test_itervalues do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_open_close_open (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 741, in test_open_close_open self.assertEqual(len(self._box), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_pop (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 313, in test_pop self.assertEqual(self._box.pop(key0).get_payload(), '0') AssertionError: 'From: foo\n\n0\n\n\x01' != '0' ====================================================================== FAIL: test_remove (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 83, in test_remove self._test_remove_or_delitem(self._box.remove) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n1\n\n\x01' != 'From: foo\n\n1' ====================================================================== FAIL: test_set_item (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 272, in test_set_item self._template % 'original 0') AssertionError: '\nFrom: foo\n\noriginal 0\n\n\x01' != 'From: foo\n\noriginal 0' ====================================================================== FAIL: test_update (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 350, in test_update self._template % 'changed 0') AssertionError: '\nFrom: foo\n\nchanged 0\n\n\x01' != 'From: foo\n\nchanged 0' ====================================================================== FAIL: test_values (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 198, in test_values self._check_iteration(self._box.values, do_keys=False, do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestMH) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_add (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 77, in test_add self.assertEqual(self._box.get_string(keys[0]), self._template % 0) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n0\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f' != 'From: foo\n\n0' ====================================================================== FAIL: test_close (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 389, in test_close self._test_flush_or_close(self._box.close) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_delitem (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 87, in test_delitem self._test_remove_or_delitem(self._box.__delitem__) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n1\n\n\x1f' != 'From: foo\n\n1' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_flush (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 377, in test_flush self._test_flush_or_close(self._box.flush) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_get (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 129, in test_get self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_file (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 174, in test_get_file self._template % 0) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n0\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f' != 'From: foo\n\n0' ====================================================================== FAIL: test_get_message (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 156, in test_get_message self.assertEqual(msg0['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_string (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 164, in test_get_string self.assertEqual(self._box.get_string(key0), self._template % 0) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n0\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f' != 'From: foo\n\n0' ====================================================================== FAIL: test_getitem (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 144, in test_getitem self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_items (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 207, in test_items self._check_iteration(self._box.items, do_keys=True, do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iter (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 194, in test_iter do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iteritems (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 203, in test_iteritems do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_itervalues (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 189, in test_itervalues do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_pop (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 313, in test_pop self.assertEqual(self._box.pop(key0).get_payload(), '0') AssertionError: 'From: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n0\n\n\x1f\x0c\n\n1,,\n\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n1\n\n\x1f' != '0' ====================================================================== FAIL: test_remove (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 83, in test_remove self._test_remove_or_delitem(self._box.remove) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n1\n\n\x1f' != 'From: foo\n\n1' ====================================================================== FAIL: test_set_item (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 272, in test_set_item self._template % 'original 0') AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\noriginal 0\n\n\x1f' != 'From: foo\n\noriginal 0' ====================================================================== FAIL: test_update (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 350, in test_update self._template % 'changed 0') AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\nchanged 0\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f' != 'From: foo\n\nchanged 0' ====================================================================== FAIL: test_values (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 198, in test_values self._check_iteration(self._box.values, do_keys=False, do_values=True) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== ERROR: test_appleformatting (test.test_plistlib.TestPlistlib) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_plistlib.py", line 140, in test_appleformatting pl = plistlib.readPlistFromBytes(TESTDATA) AttributeError: 'module' object has no attribute 'readPlistFromBytes' ====================================================================== ERROR: test_appleformattingfromliteral (test.test_plistlib.TestPlistlib) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_plistlib.py", line 147, in test_appleformattingfromliteral pl2 = plistlib.readPlistFromBytes(TESTDATA) AttributeError: 'module' object has no attribute 'readPlistFromBytes' ====================================================================== ERROR: test_bytes (test.test_plistlib.TestPlistlib) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_plistlib.py", line 133, in test_bytes data = plistlib.writePlistToBytes(pl) AttributeError: 'module' object has no attribute 'writePlistToBytes' ====================================================================== ERROR: test_bytesio (test.test_plistlib.TestPlistlib) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_plistlib.py", line 155, in test_bytesio plistlib.writePlist(pl, b) File "C:\buildbot\work\3.0.heller-windows\build\lib\plistlib.py", line 91, in writePlist writer = PlistWriter(pathOrFile) File "C:\buildbot\work\3.0.heller-windows\build\lib\plistlib.py", line 230, in __init__ file.write(PLISTHEADER) File "c:\buildbot\work\3.0.heller-windows\build\lib\io.py", line 701, in write raise TypeError("can't write str to binary stream") TypeError: can't write str to binary stream ====================================================================== ERROR: test_controlcharacters (test.test_plistlib.TestPlistlib) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_plistlib.py", line 168, in test_controlcharacters plistlib.writePlistToBytes, AttributeError: 'module' object has no attribute 'writePlistToBytes' ====================================================================== ERROR: test_io (test.test_plistlib.TestPlistlib) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_plistlib.py", line 127, in test_io plistlib.writePlist(pl, test_support.TESTFN) File "C:\buildbot\work\3.0.heller-windows\build\lib\plistlib.py", line 93, in writePlist writer.writeValue(rootObject) File "C:\buildbot\work\3.0.heller-windows\build\lib\plistlib.py", line 248, in writeValue self.writeDict(value) File "C:\buildbot\work\3.0.heller-windows\build\lib\plistlib.py", line 277, in writeDict self.writeValue(value) File "C:\buildbot\work\3.0.heller-windows\build\lib\plistlib.py", line 254, in writeValue self.writeArray(value) File "C:\buildbot\work\3.0.heller-windows\build\lib\plistlib.py", line 283, in writeArray self.writeValue(value) File "C:\buildbot\work\3.0.heller-windows\build\lib\plistlib.py", line 250, in writeValue self.writeData(value) File "C:\buildbot\work\3.0.heller-windows\build\lib\plistlib.py", line 263, in writeData for line in data.asBase64(maxlinelength).split("\n"): File "C:\buildbot\work\3.0.heller-windows\build\lib\plistlib.py", line 375, in asBase64 return _encodeBase64(self.data, maxlinelength) File "C:\buildbot\work\3.0.heller-windows\build\lib\plistlib.py", line 359, in _encodeBase64 return "".join(pieces) TypeError: sequence item 0: expected str instance, bytes found ====================================================================== ERROR: test_nondictroot (test.test_plistlib.TestPlistlib) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_plistlib.py", line 174, in test_nondictroot result1 = plistlib.readPlistFromBytes(plistlib.writePlistToBytes(test1)) AttributeError: 'module' object has no attribute 'readPlistFromBytes' ====================================================================== ERROR: test_bool (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 136, in test_bool self.assert_(not self._empty_mapping()) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_constructor (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 133, in test_constructor self.assertEqual(self._empty_mapping(), self._empty_mapping()) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 270, in test_get d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_items (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 156, in test_items d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keys (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 142, in test_keys d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 162, in test_len d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 293, in test_pop d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 288, in test_popitem d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_read (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 44, in test_read p = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 284, in test_setdefault d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 174, in test_update d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_values (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 150, in test_values d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_write (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 92, in test_write p = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_bool (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 136, in test_bool self.assert_(not self._empty_mapping()) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_constructor (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 133, in test_constructor self.assertEqual(self._empty_mapping(), self._empty_mapping()) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 270, in test_get d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_items (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 156, in test_items d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keys (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 142, in test_keys d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 162, in test_len d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 293, in test_pop d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 288, in test_popitem d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_read (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 44, in test_read p = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 284, in test_setdefault d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 174, in test_update d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_values (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 150, in test_values d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_write (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 92, in test_write p = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_bool (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 136, in test_bool self.assert_(not self._empty_mapping()) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_constructor (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 133, in test_constructor self.assertEqual(self._empty_mapping(), self._empty_mapping()) File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 270, in test_get d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_items (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 156, in test_items d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keys (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 142, in test_keys d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 162, in test_len d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 293, in test_pop d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 288, in test_popitem d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_read (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 44, in test_read p = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 284, in test_setdefault d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 174, in test_update d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_values (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 150, in test_values d = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_write (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\mapping_tests.py", line 92, in test_write p = self._empty_mapping() File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_ascii_file_shelf (test.test_shelve.TestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 46, in test_ascii_file_shelf s = shelve.open(self.fn, protocol=0) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_binary_file_shelf (test.test_shelve.TestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 54, in test_binary_file_shelf s = shelve.open(self.fn, protocol=1) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_proto2_file_shelf (test.test_shelve.TestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_shelve.py", line 62, in test_proto2_file_shelf s = shelve.open(self.fn, protocol=2) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "C:\buildbot\work\3.0.heller-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_whichdb (test.test_whichdb.WhichDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_whichdb.py", line 32, in test_whichdb f = module.open(_fname, 'c') File "C:\buildbot\work\3.0.heller-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "C:\buildbot\work\3.0.heller-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: testExtract (test.test_zipfile.TestsWithSourceFile) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_zipfile.py", line 350, in tearDown os.remove(TESTFN2) WindowsError: [Error 32] The process cannot access the file because it is being used by another process: '@test2' ====================================================================== FAIL: testExtract (test.test_zipfile.TestsWithSourceFile) ---------------------------------------------------------------------- Traceback (most recent call last): File "C:\buildbot\work\3.0.heller-windows\build\lib\test\test_zipfile.py", line 313, in testExtract self.assertEqual(writtenfile, correctfile) AssertionError: 'C:\\buildbot\\work\\3.0.heller-windows\\build\\PCbuild\\ziptest2dir\\_ziptest2' != 'C:\\buildbot\\work\\3.0.heller-windows\\build\\PCbuild\\ziptest2dir/_ziptest2' sincerely, -The Buildbot From nnorwitz at gmail.com Sat Jan 26 23:54:10 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Sat, 26 Jan 2008 17:54:10 -0500 Subject: [Python-checkins] Python Regression Test Failures refleak (7) Message-ID: <20080126225410.GA7357@python.psfb.org> test_opcodes leaked [0, -2, 2] references, sum=0 test_doctest leaked [0, 0, -2] references, sum=-2 test_descrtut leaked [4, 0, -2] references, sum=2 test_functools leaked [-4, -2, 0] references, sum=-6 test_gc leaked [0, -2, 0] references, sum=-2 test_importhooks leaked [-6, 2, 6] references, sum=2 test_os leaked [0, -2, 2] references, sum=0 test_threadsignals leaked [0, 0, -8] references, sum=-8 test_time leaked [0, -2, 0] references, sum=-2 test_urllib2_localnet leaked [-117, 134, -128] references, sum=-111 test_weakref leaked [0, 0, -2] references, sum=-2 From python-checkins at python.org Sun Jan 27 00:13:46 2008 From: python-checkins at python.org (neal.norwitz) Date: Sun, 27 Jan 2008 00:13:46 +0100 (CET) Subject: [Python-checkins] r60334 - python/trunk/Lib/test/test_resource.py Message-ID: <20080126231346.80A391E4018@bag.python.org> Author: neal.norwitz Date: Sun Jan 27 00:13:46 2008 New Revision: 60334 Modified: python/trunk/Lib/test/test_resource.py Log: On some systems (e.g., Ubuntu on hppa) the flush() doesn't cause the exception, but the close() does. Will backport. Modified: python/trunk/Lib/test/test_resource.py ============================================================================== --- python/trunk/Lib/test/test_resource.py (original) +++ python/trunk/Lib/test/test_resource.py Sun Jan 27 00:13:46 2008 @@ -53,6 +53,9 @@ try: f.write("Y") f.flush() + # On some systems (e.g., Ubuntu on hppa) the flush() + # doesn't cause the exception, but the close() does. + f.close() except IOError: if not limit_set: raise From python-checkins at python.org Sun Jan 27 00:14:18 2008 From: python-checkins at python.org (neal.norwitz) Date: Sun, 27 Jan 2008 00:14:18 +0100 (CET) Subject: [Python-checkins] r60335 - python/trunk/Lib/bsddb/test/test_associate.py python/trunk/Lib/bsddb/test/test_compare.py python/trunk/Lib/bsddb/test/test_cursor_pget_bug.py python/trunk/Lib/bsddb/test/test_pickle.py python/trunk/Lib/bsddb/test/test_sequence.py Message-ID: <20080126231418.3E3431E4018@bag.python.org> Author: neal.norwitz Date: Sun Jan 27 00:14:17 2008 New Revision: 60335 Modified: python/trunk/Lib/bsddb/test/test_associate.py python/trunk/Lib/bsddb/test/test_compare.py python/trunk/Lib/bsddb/test/test_cursor_pget_bug.py python/trunk/Lib/bsddb/test/test_pickle.py python/trunk/Lib/bsddb/test/test_sequence.py Log: Consistently use tempfile.tempdir for the db_home directory. Modified: python/trunk/Lib/bsddb/test/test_associate.py ============================================================================== --- python/trunk/Lib/bsddb/test/test_associate.py (original) +++ python/trunk/Lib/bsddb/test/test_associate.py Sun Jan 27 00:14:17 2008 @@ -151,7 +151,7 @@ def setUp(self): self.filename = self.__class__.__name__ + '.db' - homeDir = os.path.join(os.path.dirname(sys.argv[0]), 'db_home') + homeDir = os.path.join(tempfile.gettempdir(), 'db_home') self.homeDir = homeDir try: os.mkdir(homeDir) Modified: python/trunk/Lib/bsddb/test/test_compare.py ============================================================================== --- python/trunk/Lib/bsddb/test/test_compare.py (original) +++ python/trunk/Lib/bsddb/test/test_compare.py Sun Jan 27 00:14:17 2008 @@ -4,6 +4,7 @@ import sys, os, re import test_all +import tempfile from cStringIO import StringIO import unittest @@ -51,7 +52,7 @@ def setUp (self): self.filename = self.__class__.__name__ + '.db' - homeDir = os.path.join (os.path.dirname (sys.argv[0]), 'db_home') + homeDir = os.path.join (tempfile.gettempdir(), 'db_home') self.homeDir = homeDir try: os.mkdir (homeDir) Modified: python/trunk/Lib/bsddb/test/test_cursor_pget_bug.py ============================================================================== --- python/trunk/Lib/bsddb/test/test_cursor_pget_bug.py (original) +++ python/trunk/Lib/bsddb/test/test_cursor_pget_bug.py Sun Jan 27 00:14:17 2008 @@ -1,4 +1,5 @@ import unittest +import tempfile import sys, os, glob try: @@ -16,7 +17,7 @@ db_name = 'test-cursor_pget.db' def setUp(self): - self.homeDir = os.path.join(os.path.dirname(sys.argv[0]), 'db_home') + self.homeDir = os.path.join(tempfile.gettempdir(), 'db_home') try: os.mkdir(self.homeDir) except os.error: Modified: python/trunk/Lib/bsddb/test/test_pickle.py ============================================================================== --- python/trunk/Lib/bsddb/test/test_pickle.py (original) +++ python/trunk/Lib/bsddb/test/test_pickle.py Sun Jan 27 00:14:17 2008 @@ -6,6 +6,7 @@ except ImportError: cPickle = None import unittest +import tempfile import glob try: @@ -24,7 +25,7 @@ db_name = 'test-dbobj.db' def setUp(self): - homeDir = os.path.join(os.path.dirname(sys.argv[0]), 'db_home') + homeDir = os.path.join(tempfile.gettempdir(), 'db_home') self.homeDir = homeDir try: os.mkdir(homeDir) except os.error: pass Modified: python/trunk/Lib/bsddb/test/test_sequence.py ============================================================================== --- python/trunk/Lib/bsddb/test/test_sequence.py (original) +++ python/trunk/Lib/bsddb/test/test_sequence.py Sun Jan 27 00:14:17 2008 @@ -16,7 +16,7 @@ class DBSequenceTest(unittest.TestCase): def setUp(self): self.int_32_max = 0x100000000 - self.homeDir = os.path.join(os.path.dirname(sys.argv[0]), 'db_home') + self.homeDir = os.path.join(tempfile.gettempdir(), 'db_home') try: os.mkdir(self.homeDir) except os.error: From buildbot at python.org Sun Jan 27 00:27:09 2008 From: buildbot at python.org (buildbot at python.org) Date: Sat, 26 Jan 2008 23:27:09 +0000 Subject: [Python-checkins] buildbot failure in ARM Linux EABI trunk Message-ID: <20080126232709.C712B1E4018@bag.python.org> The Buildbot has detected a new failure of ARM Linux EABI trunk. Full details are available at: http://www.python.org/dev/buildbot/all/ARM%20Linux%20EABI%20trunk/builds/13 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-linux-armeabi Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: amaury.forgeotdarc,andrew.kuchling,armin.rigo,christian.heimes,georg.brandl,gregory.p.smith,guido.van.rossum,kurt.kaiser,neal.norwitz,raymond.hettinger,thomas.heller,thomas.wouters,vinay.sajip BUILD FAILED: failed failed slave lost sincerely, -The Buildbot From python-checkins at python.org Sun Jan 27 02:23:50 2008 From: python-checkins at python.org (neal.norwitz) Date: Sun, 27 Jan 2008 02:23:50 +0100 (CET) Subject: [Python-checkins] r60336 - python/branches/release25-maint/Lib/test/test_resource.py Message-ID: <20080127012350.C72E21E4018@bag.python.org> Author: neal.norwitz Date: Sun Jan 27 02:23:50 2008 New Revision: 60336 Modified: python/branches/release25-maint/Lib/test/test_resource.py Log: Backport 60334: On some systems (e.g., Ubuntu on hppa) the flush() doesn't (always) cause the exception, but the close() does. Modified: python/branches/release25-maint/Lib/test/test_resource.py ============================================================================== --- python/branches/release25-maint/Lib/test/test_resource.py (original) +++ python/branches/release25-maint/Lib/test/test_resource.py Sun Jan 27 02:23:50 2008 @@ -36,6 +36,9 @@ try: f.write("Y") f.flush() + # On some systems (e.g., Ubuntu on hppa) the flush() + # doesn't cause the exception, but the close() does. + f.close() except IOError: if not limit_set: raise From python-checkins at python.org Sun Jan 27 02:24:44 2008 From: python-checkins at python.org (neal.norwitz) Date: Sun, 27 Jan 2008 02:24:44 +0100 (CET) Subject: [Python-checkins] r60337 - python/branches/release25-maint/Lib/test/test_support.py Message-ID: <20080127012444.8CDC21E401E@bag.python.org> Author: neal.norwitz Date: Sun Jan 27 02:24:44 2008 New Revision: 60337 Modified: python/branches/release25-maint/Lib/test/test_support.py Log: Backport r58453: Let the O/S supply a port if none of the default ports can be used. This should make the tests more robust at the expense of allowing tests to be sloppier by not requiring them to cleanup after themselves. (It will legitamitely help when running two test suites simultaneously or if another process is already using one of the predefined ports.) This will hopefully fix test_asynchat. Modified: python/branches/release25-maint/Lib/test/test_support.py ============================================================================== --- python/branches/release25-maint/Lib/test/test_support.py (original) +++ python/branches/release25-maint/Lib/test/test_support.py Sun Jan 27 02:24:44 2008 @@ -95,10 +95,20 @@ makes the test more robust.""" import socket, errno - # some random ports that hopefully no one is listening on. - for port in [preferred_port, 9907, 10243, 32999]: + + # Find some random ports that hopefully no one is listening on. + # Ideally each test would clean up after itself and not continue listening + # on any ports. However, this isn't the case. The last port (0) is + # a stop-gap that asks the O/S to assign a port. Whenever the warning + # message below is printed, the test that is listening on the port should + # be fixed to close the socket at the end of the test. + # Another reason why we can't use a port is another process (possibly + # another instance of the test suite) is using the same port. + for port in [preferred_port, 9907, 10243, 32999, 0]: try: sock.bind((host, port)) + if port == 0: + port = sock.getsockname()[1] return port except socket.error, (err, msg): if err != errno.EADDRINUSE: From python-checkins at python.org Sun Jan 27 02:44:05 2008 From: python-checkins at python.org (neal.norwitz) Date: Sun, 27 Jan 2008 02:44:05 +0100 (CET) Subject: [Python-checkins] r60338 - python/trunk/Lib/test/test_asynchat.py Message-ID: <20080127014405.C92371E4018@bag.python.org> Author: neal.norwitz Date: Sun Jan 27 02:44:05 2008 New Revision: 60338 Modified: python/trunk/Lib/test/test_asynchat.py Log: Eliminate the sleeps that assume the server will start in .5 seconds. This should make the test less flaky. It also speeds up the test by about 75% on my box (20+ seconds -> ~4 seconds). Modified: python/trunk/Lib/test/test_asynchat.py ============================================================================== --- python/trunk/Lib/test/test_asynchat.py (original) +++ python/trunk/Lib/test/test_asynchat.py Sun Jan 27 02:44:05 2008 @@ -15,12 +15,17 @@ # client each send chunk_size = 1 + def __init__(self, event): + threading.Thread.__init__(self) + self.event = event + def run(self): sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM) sock.setsockopt(socket.SOL_SOCKET, socket.SO_REUSEADDR, 1) global PORT PORT = test_support.bind_port(sock, HOST, PORT) sock.listen(1) + self.event.set() conn, client = sock.accept() self.buffer = "" # collect data until quit message is seen @@ -74,6 +79,16 @@ self.buffer = "" +def start_echo_server(): + event = threading.Event() + s = echo_server(event) + s.start() + event.wait() + event.clear() + time.sleep(0.01) # Give server time to start accepting. + return s, event + + class TestAsynchat(unittest.TestCase): usepoll = False @@ -84,10 +99,13 @@ pass def line_terminator_check(self, term, server_chunk): - s = echo_server() + event = threading.Event() + s = echo_server(event) s.chunk_size = server_chunk s.start() - time.sleep(0.5) # Give server time to initialize + event.wait() + event.clear() + time.sleep(0.01) # Give server time to start accepting. c = echo_client(term) c.push("hello ") c.push("world%s" % term) @@ -119,9 +137,7 @@ def numeric_terminator_check(self, termlen): # Try reading a fixed number of bytes - s = echo_server() - s.start() - time.sleep(0.5) # Give server time to initialize + s, event = start_echo_server() c = echo_client(termlen) data = "hello world, I'm not dead yet!\n" c.push(data) @@ -142,9 +158,7 @@ def test_none_terminator(self): # Try reading a fixed number of bytes - s = echo_server() - s.start() - time.sleep(0.5) # Give server time to initialize + s, event = start_echo_server() c = echo_client(None) data = "hello world, I'm not dead yet!\n" c.push(data) @@ -156,9 +170,7 @@ self.assertEqual(c.buffer, data) def test_simple_producer(self): - s = echo_server() - s.start() - time.sleep(0.5) # Give server time to initialize + s, event = start_echo_server() c = echo_client('\n') data = "hello world\nI'm not dead yet!\n" p = asynchat.simple_producer(data+SERVER_QUIT, buffer_size=8) @@ -169,9 +181,7 @@ self.assertEqual(c.contents, ["hello world", "I'm not dead yet!"]) def test_string_producer(self): - s = echo_server() - s.start() - time.sleep(0.5) # Give server time to initialize + s, event = start_echo_server() c = echo_client('\n') data = "hello world\nI'm not dead yet!\n" c.push_with_producer(data+SERVER_QUIT) @@ -182,9 +192,7 @@ def test_empty_line(self): # checks that empty lines are handled correctly - s = echo_server() - s.start() - time.sleep(0.5) # Give server time to initialize + s, event = start_echo_server() c = echo_client('\n') c.push("hello world\n\nI'm not dead yet!\n") c.push(SERVER_QUIT) @@ -194,9 +202,7 @@ self.assertEqual(c.contents, ["hello world", "", "I'm not dead yet!"]) def test_close_when_done(self): - s = echo_server() - s.start() - time.sleep(0.5) # Give server time to initialize + s, event = start_echo_server() c = echo_client('\n') c.push("hello world\nI'm not dead yet!\n") c.push(SERVER_QUIT) From python-checkins at python.org Sun Jan 27 03:09:07 2008 From: python-checkins at python.org (mark.dickinson) Date: Sun, 27 Jan 2008 03:09:07 +0100 (CET) Subject: [Python-checkins] r60339 - in python/branches/trunk-math: Lib/test/ieee754.txt Lib/test/test_math.py Modules/mathmodule.c Message-ID: <20080127020907.5387A1E4018@bag.python.org> Author: mark.dickinson Date: Sun Jan 27 03:09:06 2008 New Revision: 60339 Modified: python/branches/trunk-math/Lib/test/ieee754.txt python/branches/trunk-math/Lib/test/test_math.py python/branches/trunk-math/Modules/mathmodule.c Log: Make math functions return +/-infinity instead of raising OverflowError in cases where the result is infinite and (one of) the input argument(s) is already an infinity. The rationale for this change is twofold: (1) this is what C99 appendix F recommends, and (2) this fits in nicely with the philosophy that new users shouldn't be surprised by NaNs and Infs: in general, try to ensure that nans and infs aren't returned from computations involving just finite numbers. But someone supplying an infinity to a math function is much less likely to be surprised by an infinite result. Also make some changes to the pow function to make it fit better with C99, and add some general guidelines from Tim Peters on Python and IEEE exceptions. Modified: python/branches/trunk-math/Lib/test/ieee754.txt ============================================================================== --- python/branches/trunk-math/Lib/test/ieee754.txt (original) +++ python/branches/trunk-math/Lib/test/ieee754.txt Sun Jan 27 03:09:06 2008 @@ -101,11 +101,12 @@ >>> pow(1, NAN) 1.0 -The power of 0 raised to x is defined as 0, iff x is zero or positive. Negative -values are a domain error or zero division error and NaN result in a silent NaN. +The power of 0 raised to x is defined as 0, if x is positive. Negative +values are a domain error or zero division error and NaN result in a +silent NaN. >>> pow(0, 0) -0.0 +1.0 >>> pow(0, INF) 0.0 >>> pow(0, -INF) @@ -123,12 +124,36 @@ Trigonometric Functions ======================= ->>> sin(INF), sin(NINF), sin(NAN) -(nan, nan, nan) ->>> cos(INF), cos(NINF), cos(NAN) -(nan, nan, nan) ->>> tan(INF), tan(NINF), tan(NAN) -(nan, nan, nan) +>>> sin(INF) +Traceback (most recent call last): +... +ValueError: math domain error +>>> sin(NINF) +Traceback (most recent call last): +... +ValueError: math domain error +>>> sin(NAN) +nan +>>> cos(INF) +Traceback (most recent call last): +... +ValueError: math domain error +>>> cos(NINF) +Traceback (most recent call last): +... +ValueError: math domain error +>>> cos(NAN) +nan +>>> tan(INF) +Traceback (most recent call last): +... +ValueError: math domain error +>>> tan(NINF) +Traceback (most recent call last): +... +ValueError: math domain error +>>> tan(NAN) +nan Neither pi nor tan are exact, but you can assume that tan(pi/2) is a large value and tan(pi) is a very small value: Modified: python/branches/trunk-math/Lib/test/test_math.py ============================================================================== --- python/branches/trunk-math/Lib/test/test_math.py (original) +++ python/branches/trunk-math/Lib/test/test_math.py Sun Jan 27 03:09:06 2008 @@ -71,7 +71,7 @@ self.ftest('acosh(2)', math.acosh(2), 1.3169578969248168) self.assertRaises(ValueError, math.acosh, 0) self.assertRaises(ValueError, math.acosh, -1) - self.assertRaises(OverflowError, math.acosh, INF) + self.assertEquals(math.acosh(INF), INF) self.assertRaises(ValueError, math.acosh, NINF) self.assert_(math.isnan(math.acosh(NAN))) @@ -89,8 +89,8 @@ self.ftest('asinh(0)', math.asinh(0), 0) self.ftest('asinh(1)', math.asinh(1), 0.88137358701954305) self.ftest('asinh(-1)', math.asinh(-1), -0.88137358701954305) - self.assertRaises(OverflowError, math.asinh, INF) - self.assertRaises(OverflowError, math.asinh, NINF) + self.assertEquals(math.asinh(INF), INF) + self.assertEquals(math.asinh(NINF), NINF) self.assert_(math.isnan(math.asinh(NAN))) def testAtan(self): @@ -133,8 +133,8 @@ self.ftest('ceil(-0.5)', math.ceil(-0.5), 0) self.ftest('ceil(-1.0)', math.ceil(-1.0), -1) self.ftest('ceil(-1.5)', math.ceil(-1.5), -1) - self.assertRaises(OverflowError, math.ceil, INF) - self.assertRaises(OverflowError, math.ceil, NINF) + self.assertEquals(math.ceil(INF), INF) + self.assertEquals(math.ceil(NINF), NINF) self.assert_(math.isnan(math.ceil(NAN))) class TestCeil(object): @@ -168,8 +168,8 @@ self.assertRaises(TypeError, math.cosh) self.ftest('cosh(0)', math.cosh(0), 1) self.ftest('cosh(2)-2*cosh(1)**2', math.cosh(2)-2*math.cosh(1)**2, -1) # Thanks to Lambert - self.assertRaises(OverflowError, math.cosh, INF) - self.assertRaises(OverflowError, math.cosh, NINF) + self.assertEquals(math.cosh(INF), INF) + self.assertEquals(math.cosh(NINF), INF) self.assert_(math.isnan(math.cosh(NAN))) def testDegrees(self): @@ -183,8 +183,8 @@ self.ftest('exp(-1)', math.exp(-1), 1/math.e) self.ftest('exp(0)', math.exp(0), 1) self.ftest('exp(1)', math.exp(1), math.e) - self.assertRaises(OverflowError, math.exp, INF) - self.ftest('exp(-INF)', math.exp(NINF), 0) + self.assertEquals(math.exp(INF), INF) + self.assertEquals(math.exp(NINF), 0.) self.assert_(math.isnan(math.exp(NAN))) def testFabs(self): @@ -209,8 +209,8 @@ # This fails on some platforms - so check it here self.ftest('floor(1.23e167)', math.floor(1.23e167), 1.23e167) self.ftest('floor(-1.23e167)', math.floor(-1.23e167), -1.23e167) - self.assertRaises(OverflowError, math.floor, INF) - self.assertRaises(OverflowError, math.floor, NINF) + self.assertEquals(math.ceil(INF), INF) + self.assertEquals(math.ceil(NINF), NINF) self.assert_(math.isnan(math.floor(NAN))) class TestFloor(object): @@ -268,7 +268,7 @@ self.ftest('log(32,2)', math.log(32,2), 5) self.ftest('log(10**40, 10)', math.log(10**40, 10), 40) self.ftest('log(10**40, 10**20)', math.log(10**40, 10**20), 2) - self.assertRaises(OverflowError, math.log, INF) + self.assertEquals(math.log(INF), INF) self.assertRaises(ValueError, math.log, NINF) self.assert_(math.isnan(math.log(NAN))) @@ -278,11 +278,8 @@ self.ftest('log1p(0)', math.log1p(0), 0) self.ftest('log1p(e-1)', math.log1p(math.e-1), 1) self.ftest('log1p(1)', math.log1p(1), math.log(2)) - self.assertRaises(OverflowError, math.log1p, INF) - try: - self.assert_(math.isnan(math.log1p(NINF))) - except ValueError: - self.assertRaises(ValueError, math.log1p, NINF) + self.assertEquals(math.log1p(INF), INF) + self.assertRaises(ValueError, math.log1p, NINF) self.assert_(math.isnan(math.log1p(NAN))) def testLog10(self): @@ -290,7 +287,7 @@ self.ftest('log10(0.1)', math.log10(0.1), -1) self.ftest('log10(1)', math.log10(1), 0) self.ftest('log10(10)', math.log10(10), 1) - self.assertRaises(OverflowError, math.log10, INF) + self.assertEquals(math.log(INF), INF) self.assertRaises(ValueError, math.log10, NINF) self.assert_(math.isnan(math.log10(NAN))) @@ -311,14 +308,10 @@ self.ftest('pow(1,0)', math.pow(1,0), 1) self.ftest('pow(2,1)', math.pow(2,1), 2) self.ftest('pow(2,-1)', math.pow(2,-1), 0.5) - self.assertRaises(OverflowError, math.pow, INF, 1) - self.assertRaises(OverflowError, math.pow, NINF, 1) - try: - self.assertEqual((math.pow(1, INF)), 1.) - self.assertEqual((math.pow(1, NINF)), 1.) - except ValueError: - self.assertRaises(ValueError, math.pow, 1, INF) - self.assertRaises(ValueError, math.pow, 1, NINF) + self.assertEqual(math.pow(INF, 1), INF) + self.assertEqual(math.pow(NINF, 1), NINF) + self.assertEqual((math.pow(1, INF)), 1.) + self.assertEqual((math.pow(1, NINF)), 1.) self.assert_(math.isnan(math.pow(NAN, 1))) self.assert_(math.isnan(math.pow(2, NAN))) self.assert_(math.isnan(math.pow(0, NAN))) @@ -356,8 +349,8 @@ self.ftest('sinh(0)', math.sinh(0), 0) self.ftest('sinh(1)**2-cosh(1)**2', math.sinh(1)**2-math.cosh(1)**2, -1) self.ftest('sinh(1)+sinh(-1)', math.sinh(1)+math.sinh(-1), 0) - self.assertRaises(OverflowError, math.sinh, INF) - self.assertRaises(OverflowError, math.sinh, NINF) + self.assertEquals(math.sinh(INF), INF) + self.assertEquals(math.sinh(-INF), -INF) self.assert_(math.isnan(math.sinh(NAN))) def testSqrt(self): @@ -365,7 +358,7 @@ self.ftest('sqrt(0)', math.sqrt(0), 0) self.ftest('sqrt(1)', math.sqrt(1), 1) self.ftest('sqrt(4)', math.sqrt(4), 2) - self.assertRaises(OverflowError, math.sqrt, INF) + self.assertEquals(math.sqrt(INF), INF) self.assertRaises(ValueError, math.sqrt, NINF) self.assert_(math.isnan(math.sqrt(NAN))) Modified: python/branches/trunk-math/Modules/mathmodule.c ============================================================================== --- python/branches/trunk-math/Modules/mathmodule.c (original) +++ python/branches/trunk-math/Modules/mathmodule.c Sun Jan 27 03:09:06 2008 @@ -1,5 +1,50 @@ /* Math module -- standard C math library functions, pi and e */ +/* Here are some comments from Tim Peters, extracted from the + discussion attached to http://bugs.python.org/issue1640. They + describe the general aims of the math module with respect to + special values, IEEE-754 floating-point exceptions, and Python + exceptions. + +These are the "spirit of 754" rules: + +1. If the mathematical result is a real number, but of magnitude too +large to approximate by a machine float, overflow is signaled and the +result is an infinity (with the appropriate sign). + +2. If the mathematical result is a real number, but of magnitude too +small to approximate by a machine float, underflow is signaled and the +result is a zero (with the appropriate sign). + +3. At a singularity (a value x such that the limit of f(y) as y +approaches x exists and is an infinity), "divide by zero" is signaled +and the result is an infinity (with the appropriate sign). This is +complicated a little by that the left-side and right-side limits may +not be the same; e.g., 1/x approaches +inf or -inf as x approaches 0 +from the positive or negative directions. In that specific case, the +sign of the zero determines the result of 1/0. + +4. At a point where a function has no defined result in the extended +reals (i.e., the reals plus an infinity or two), invalid operation is +signaled and a NaN is returned. + +And these are what Python has historically /tried/ to do (but not +always successfully, as platform libm behavior varies a lot): + +For #1, raise OverflowError. + +For #2, return a zero (with the appropriate sign if that happens by +accident ;-)). + +For #3 and #4, raise ValueError. It may have made sense to raise +Python's ZeroDivisionError in #3, but historically that's only been +raised for division by zero and mod by zero. + +*/ + +/* Platform notes: on many BSDs and Mac OS X, the functions in libm never set + errno. In GNU's libm, setting of errno is erratic. */ + #include "Python.h" #include "longintrepr.h" /* just for SHIFT */ @@ -39,20 +84,38 @@ } static PyObject * -math_1(PyObject *arg, double (*func) (double)) +math_1(PyObject *arg, double (*func) (double), int can_overflow) { + int x_is_infinity; double x = PyFloat_AsDouble(arg); if (x == -1.0 && PyErr_Occurred()) return NULL; -#ifndef __GNUC__ /* Windows et al */ + /* a NaN input should be returned unscathed */ if (Py_IS_NAN(x)) - return PyFloat_FromDouble(x+x); -#endif + return PyFloat_FromDouble(x); + x_is_infinity = Py_IS_INFINITY(x); errno = 0; - PyFPE_START_PROTECT("in math_1", return 0) + PyFPE_START_PROTECT("in math_1", return 0); + //printf("math_1: Before func call: errno=%d; input = %.20e\n", errno, x); x = (*func)(x); - PyFPE_END_PROTECT(x) - Py_SET_ERRNO_ON_MATH_ERROR(x); + //printf("math_1: Aftern func call: errno=%d; result = %.20e\n", errno, x); + PyFPE_END_PROTECT(x); + + /* if the result was a NaN then we should be signalling a ValueError; + this should only happen in the cases where C99 recommends raising + invalid */ + if (Py_IS_NAN(x)) + errno = EDOM; + + /* if the input was finite and the result is an infinity, then either + overflow occurred and we should be setting errno to ERANGE so that + Python raises an OverflowError, or we were evaluating at a + singularity, and we should setting errno to EDOM so that Python + raises ValueError. Currently, none of the functions using math_1 + have singularities *and* the possibility of overflow :-) */ + if (!x_is_infinity && Py_IS_INFINITY(x)) + errno = can_overflow ? ERANGE : EDOM; + if (errno && is_error(x)) return NULL; else @@ -85,9 +148,9 @@ return PyFloat_FromDouble(x); } -#define FUNC1(funcname, func, docstring) \ +#define FUNC1(funcname, func, can_overflow, docstring) \ static PyObject * math_##funcname(PyObject *self, PyObject *args) { \ - return math_1(args, func); \ + return math_1(args, func, can_overflow); \ }\ PyDoc_STRVAR(math_##funcname##_doc, docstring); @@ -97,35 +160,35 @@ }\ PyDoc_STRVAR(math_##funcname##_doc, docstring); -FUNC1(acos, acos, +FUNC1(acos, acos, 0, "acos(x)\n\nReturn the arc cosine (measured in radians) of x.") -FUNC1(acosh, acosh, +FUNC1(acosh, acosh, 0, "acosh(x)\n\nReturn the hyperbolic arc cosine (measured in radians) of x.") -FUNC1(asin, asin, +FUNC1(asin, asin, 0, "asin(x)\n\nReturn the arc sine (measured in radians) of x.") -FUNC1(asinh, asinh, +FUNC1(asinh, asinh, 0, "asinh(x)\n\nReturn the hyperbolic arc sine (measured in radians) of x.") -FUNC1(atan, atan, +FUNC1(atan, atan, 0, "atan(x)\n\nReturn the arc tangent (measured in radians) of x.") FUNC2(atan2, atan2, "atan2(y, x)\n\nReturn the arc tangent (measured in radians) of y/x.\n" "Unlike atan(y/x), the signs of both x and y are considered.") -FUNC1(atanh, atanh, +FUNC1(atanh, atanh, 0, "atanh(x)\n\nReturn the hyperbolic arc tangent (measured in radians) of x.") -FUNC1(ceil, ceil, +FUNC1(ceil, ceil, 0, "ceil(x)\n\nReturn the ceiling of x as a float.\n" "This is the smallest integral value >= x.") -FUNC1(cos, cos, +FUNC1(cos, cos, 0, "cos(x)\n\nReturn the cosine of x (measured in radians).") -FUNC1(cosh, cosh, +FUNC1(cosh, cosh, 1, "cosh(x)\n\nReturn the hyperbolic cosine of x.") FUNC2(copysign, copysign, "copysign(x,y)\n\nReturn x with the sign of y."); -FUNC1(exp, exp, +FUNC1(exp, exp, 1, "exp(x)\n\nReturn e raised to the power of x.") -FUNC1(fabs, fabs, +FUNC1(fabs, fabs, 0, "fabs(x)\n\nReturn the absolute value of the float x.") -FUNC1(floor, floor, +FUNC1(floor, floor, 0, "floor(x)\n\nReturn the floor of x as a float.\n" "This is the largest integral value <= x.") FUNC2(fmod, fmod, @@ -133,15 +196,15 @@ " x % y may differ.") FUNC2(hypot, hypot, "hypot(x,y)\n\nReturn the Euclidean distance, sqrt(x*x + y*y).") -FUNC1(sin, sin, +FUNC1(sin, sin, 0, "sin(x)\n\nReturn the sine of x (measured in radians).") -FUNC1(sinh, sinh, +FUNC1(sinh, sinh, 1, "sinh(x)\n\nReturn the hyperbolic sine of x.") -FUNC1(sqrt, sqrt, +FUNC1(sqrt, sqrt, 0, "sqrt(x)\n\nReturn the square root of x.") -FUNC1(tan, tan, +FUNC1(tan, tan, 0, "tan(x)\n\nReturn the tangent of x (measured in radians).") -FUNC1(tanh, tanh, +FUNC1(tanh, tanh, 0, "tanh(x)\n\nReturn the hyperbolic tangent of x.") static PyObject * @@ -239,7 +302,7 @@ } /* Else let libm handle it by itself. */ - return math_1(arg, func); + return math_1(arg, func, 0); } static PyObject * @@ -319,34 +382,55 @@ { PyObject *ox, *oy; double x, y; + int x_is_infinity, y_is_infinity; + if (! PyArg_UnpackTuple(args, "pow", 2, 2, &ox, &oy)) return NULL; x = PyFloat_AsDouble(ox); y = PyFloat_AsDouble(oy); if ((x == -1.0 || y == -1.0) && PyErr_Occurred()) return NULL; - /* 1^x returns 1., even NaN and INF */ - if (x == 1.0) + + /* 1**x and x**0 return 1., even if x is a NaN or infinity */ + if (x == 1.0 || y == 0.0) return PyFloat_FromDouble(1.); - if (x == 0.0) { - if (y >= 0.0 || Py_IS_NAN(y)) - return PyFloat_FromDouble(0.); - else { - /* 0 raise to a negative value */ - errno = EDOM; - is_error(x); - return NULL; - } + + /* with the above two exceptions out of the way, usual rules for NaNs + apply: if either x or y is a NaN then NaN should be returned. */ + if (Py_IS_NAN(x)) + return PyFloat_FromDouble(x); + if (Py_IS_NAN(y)) + return PyFloat_FromDouble(y); + + x_is_infinity = Py_IS_INFINITY(x); + y_is_infinity = Py_IS_INFINITY(y); + + /* 0 ** negative should give a divide-by-zero exception according + to IEEE-754; we want errno = EDOM here to get a ValueError. + Note: for 0.0 ** positive we let the libm routine take care of + evaluation, to give maximum chance of getting the sign of the result + correct. (e.g. (-0.0)**27 should be -0.0.) */ + if (x == 0.0 && y < 0.0) { + errno = EDOM; + is_error(x); + return NULL; } -#ifndef __GNUC__ /* Windows et al */ - if (Py_IS_NAN(x) || Py_IS_NAN(y)) - return PyFloat_FromDouble(x+y); -#endif + + /* Finally, call the libm pow. */ errno = 0; - PyFPE_START_PROTECT("in math_pow", return 0) + PyFPE_START_PROTECT("in math_pow", return 0); x = pow(x, y); - PyFPE_END_PROTECT(x) - Py_SET_ERRNO_ON_MATH_ERROR(x); + PyFPE_END_PROTECT(x); + + /* a NaN at this point should result in ValueError being raised */ + if (Py_IS_NAN(x)) + errno = EDOM; + + /* if neither x nor y was infinity, then an infinite result here + indicates overflow. */ + if (!x_is_infinity && !y_is_infinity && Py_IS_INFINITY(x)) + errno = ERANGE; + if (errno && is_error(x)) return NULL; else From buildbot at python.org Sun Jan 27 03:32:59 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 27 Jan 2008 02:32:59 +0000 Subject: [Python-checkins] buildbot failure in alpha Tru64 5.1 2.5 Message-ID: <20080127023259.B654F1E4018@bag.python.org> The Buildbot has detected a new failure of alpha Tru64 5.1 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/alpha%20Tru64%205.1%202.5/builds/422 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-tru64 Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: neal.norwitz BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_signal sincerely, -The Buildbot From python-checkins at python.org Sun Jan 27 03:38:17 2008 From: python-checkins at python.org (mark.dickinson) Date: Sun, 27 Jan 2008 03:38:17 +0100 (CET) Subject: [Python-checkins] r60340 - python/branches/trunk-math/Modules/mathmodule.c Message-ID: <20080127023817.AE4FA1E4018@bag.python.org> Author: mark.dickinson Date: Sun Jan 27 03:38:17 2008 New Revision: 60340 Modified: python/branches/trunk-math/Modules/mathmodule.c Log: Remove non-ANSI comments Modified: python/branches/trunk-math/Modules/mathmodule.c ============================================================================== --- python/branches/trunk-math/Modules/mathmodule.c (original) +++ python/branches/trunk-math/Modules/mathmodule.c Sun Jan 27 03:38:17 2008 @@ -96,9 +96,7 @@ x_is_infinity = Py_IS_INFINITY(x); errno = 0; PyFPE_START_PROTECT("in math_1", return 0); - //printf("math_1: Before func call: errno=%d; input = %.20e\n", errno, x); x = (*func)(x); - //printf("math_1: Aftern func call: errno=%d; result = %.20e\n", errno, x); PyFPE_END_PROTECT(x); /* if the result was a NaN then we should be signalling a ValueError; From buildbot at python.org Sun Jan 27 05:19:26 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 27 Jan 2008 04:19:26 +0000 Subject: [Python-checkins] buildbot failure in alpha Debian 2.5 Message-ID: <20080127041926.40B591E4018@bag.python.org> The Buildbot has detected a new failure of alpha Debian 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/alpha%20Debian%202.5/builds/17 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-alpha Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: georg.brandl,neal.norwitz BUILD FAILED: failed test Excerpt from the test logfile: sincerely, -The Buildbot From python-checkins at python.org Sun Jan 27 05:31:10 2008 From: python-checkins at python.org (mark.dickinson) Date: Sun, 27 Jan 2008 05:31:10 +0100 (CET) Subject: [Python-checkins] r60341 - in python/branches/trunk-math: Lib/test/test_math.py Modules/mathmodule.c Message-ID: <20080127043110.AEF431E4018@bag.python.org> Author: mark.dickinson Date: Sun Jan 27 05:31:10 2008 New Revision: 60341 Modified: python/branches/trunk-math/Lib/test/test_math.py python/branches/trunk-math/Modules/mathmodule.c Log: Fix up hypot to follow C99 standard: hypot(inf, nan) should be inf. Modified: python/branches/trunk-math/Lib/test/test_math.py ============================================================================== --- python/branches/trunk-math/Lib/test/test_math.py (original) +++ python/branches/trunk-math/Lib/test/test_math.py Sun Jan 27 05:31:10 2008 @@ -252,6 +252,12 @@ self.assertRaises(TypeError, math.hypot) self.ftest('hypot(0,0)', math.hypot(0,0), 0) self.ftest('hypot(3,4)', math.hypot(3,4), 5) + self.assertEqual(math.hypot(NAN, INF), INF) + self.assertEqual(math.hypot(INF, NAN), INF) + self.assertEqual(math.hypot(NAN, NINF), INF) + self.assertEqual(math.hypot(NINF, NAN), INF) + self.assert_(math.isnan(math.hypot(1.0, NAN))) + self.assert_(math.isnan(math.hypot(NAN, -2.0))) def testLdexp(self): self.assertRaises(TypeError, math.ldexp) Modified: python/branches/trunk-math/Modules/mathmodule.c ============================================================================== --- python/branches/trunk-math/Modules/mathmodule.c (original) +++ python/branches/trunk-math/Modules/mathmodule.c Sun Jan 27 05:31:10 2008 @@ -42,8 +42,15 @@ */ -/* Platform notes: on many BSDs and Mac OS X, the functions in libm never set - errno. In GNU's libm, setting of errno is erratic. */ +/* + In general, on an IEEE-754 platform the aim is to follow the C99 + standard, including Annex 'F', whenever possible. Where the + standard recommends raising the 'divide-by-zero' or 'invalid' + floating-point exceptions, Python should raise a ValueError. Where + the standard recommends raising 'overflow', Python should raise an + OverflowError. In all other circumstances a value should be + returned. + */ #include "Python.h" #include "longintrepr.h" /* just for SHIFT */ @@ -131,15 +138,14 @@ y = PyFloat_AsDouble(oy); if ((x == -1.0 || y == -1.0) && PyErr_Occurred()) return NULL; -#ifndef __GNUC__ /* Windows et al */ - if (Py_IS_NAN(x) || Py_IS_NAN(y)) - return PyFloat_FromDouble(x+y); -#endif + if (Py_IS_NAN(x)) + return PyFloat_FromDouble(x); + if (Py_IS_NAN(y)) + return PyFloat_FromDouble(y); errno = 0; PyFPE_START_PROTECT("in math_2", return 0) x = (*func)(x, y); - PyFPE_END_PROTECT(x) - Py_SET_ERRNO_ON_MATH_ERROR(x); + PyFPE_END_PROTECT(x); if (errno && is_error(x)) return NULL; else @@ -192,8 +198,6 @@ FUNC2(fmod, fmod, "fmod(x,y)\n\nReturn fmod(x, y), according to platform C." " x % y may differ.") -FUNC2(hypot, hypot, - "hypot(x,y)\n\nReturn the Euclidean distance, sqrt(x*x + y*y).") FUNC1(sin, sin, 0, "sin(x)\n\nReturn the sine of x (measured in radians).") FUNC1(sinh, sinh, 1, @@ -438,6 +442,52 @@ PyDoc_STRVAR(math_pow_doc, "pow(x,y)\n\nReturn x**y (x to the power of y)."); +static PyObject * +math_hypot(PyObject *self, PyObject *args) +{ + PyObject *ox, *oy; + double x, y; + int x_is_infinity, y_is_infinity; + + if (! PyArg_UnpackTuple(args, "hypot", 2, 2, &ox, &oy)) + return NULL; + x = PyFloat_AsDouble(ox); + y = PyFloat_AsDouble(oy); + if ((x == -1.0 || y == -1.0) && PyErr_Occurred()) + return NULL; + + /* hypot (+/-infinity, x) returns infinity, even if x is a NaN */ + if (Py_IS_INFINITY(x) || Py_IS_INFINITY(y)) + return PyFloat_FromDouble(Py_HUGE_VAL); + + /* Now the usual rules apply: if either argument is a NaN, return NaN */ + if (Py_IS_NAN(x)) + return PyFloat_FromDouble(x); + if (Py_IS_NAN(y)) + return PyFloat_FromDouble(y); + + x_is_infinity = Py_IS_INFINITY(x); + y_is_infinity = Py_IS_INFINITY(y); + + errno = 0; + PyFPE_START_PROTECT("in math_hypot", return 0); + x = hypot(x, y); + PyFPE_END_PROTECT(x); + + /* we can get an infinity here either as an exact result, or + as a result of overflow */ + if (!x_is_infinity && !y_is_infinity && Py_IS_INFINITY(x)) + errno = ERANGE; + + if (errno && is_error(x)) + return NULL; + else + return PyFloat_FromDouble(x); +} + +PyDoc_STRVAR(math_hypot_doc, + "hypot(x,y)\n\nReturn the Euclidean distance, sqrt(x*x + y*y)."); + static const double degToRad = Py_MATH_PI / 180.0; static const double radToDeg = 180.0 / Py_MATH_PI; From python-checkins at python.org Sun Jan 27 06:02:35 2008 From: python-checkins at python.org (neal.norwitz) Date: Sun, 27 Jan 2008 06:02:35 +0100 (CET) Subject: [Python-checkins] r60342 - python/trunk/Lib/test/test_resource.py Message-ID: <20080127050235.4E1AE1E401C@bag.python.org> Author: neal.norwitz Date: Sun Jan 27 06:02:34 2008 New Revision: 60342 Modified: python/trunk/Lib/test/test_resource.py Log: Try to prevent this test from being flaky. We might need a sleep in here which isn't as bad as it sounds. The close() *should* raise an exception, so if it didn't we should give more time to sync and really raise it. Will backport. Modified: python/trunk/Lib/test/test_resource.py ============================================================================== --- python/trunk/Lib/test/test_resource.py (original) +++ python/trunk/Lib/test/test_resource.py Sun Jan 27 06:02:34 2008 @@ -54,8 +54,12 @@ f.write("Y") f.flush() # On some systems (e.g., Ubuntu on hppa) the flush() - # doesn't cause the exception, but the close() does. - f.close() + # doesn't always cause the exception, but the close() + # does eventually. Try closing several times in + # an attempt to ensure the file is really synced and + # the exception raised. + for i in range(5): + f.close() except IOError: if not limit_set: raise From python-checkins at python.org Sun Jan 27 06:02:56 2008 From: python-checkins at python.org (neal.norwitz) Date: Sun, 27 Jan 2008 06:02:56 +0100 (CET) Subject: [Python-checkins] r60343 - python/branches/release25-maint/Lib/test/test_resource.py Message-ID: <20080127050257.00F491E4024@bag.python.org> Author: neal.norwitz Date: Sun Jan 27 06:02:56 2008 New Revision: 60343 Modified: python/branches/release25-maint/Lib/test/test_resource.py Log: Backport 60342: Try to prevent this test from being flaky. We might need a sleep in here which isn't as bad as it sounds. The close() *should* raise an exception, so if it didn't we should give more time to sync and really raise it. Modified: python/branches/release25-maint/Lib/test/test_resource.py ============================================================================== --- python/branches/release25-maint/Lib/test/test_resource.py (original) +++ python/branches/release25-maint/Lib/test/test_resource.py Sun Jan 27 06:02:56 2008 @@ -37,8 +37,11 @@ f.write("Y") f.flush() # On some systems (e.g., Ubuntu on hppa) the flush() - # doesn't cause the exception, but the close() does. - f.close() + # doesn't always cause the exception, but the close() + # does eventually. Try closing several times in an attempt + # to ensure the file is really synced and the exception raised. + for i in range(5): + f.close() except IOError: if not limit_set: raise From buildbot at python.org Sun Jan 27 06:03:38 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 27 Jan 2008 05:03:38 +0000 Subject: [Python-checkins] buildbot failure in ARM Linux EABI 3.0 Message-ID: <20080127050339.1F6481E4018@bag.python.org> The Buildbot has detected a new failure of ARM Linux EABI 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/ARM%20Linux%20EABI%203.0/builds/11 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-linux-armeabi Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes,neal.norwitz BUILD FAILED: failed compile sincerely, -The Buildbot From buildbot at python.org Sun Jan 27 06:04:31 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 27 Jan 2008 05:04:31 +0000 Subject: [Python-checkins] buildbot failure in hppa Ubuntu trunk Message-ID: <20080127050431.52C041E4018@bag.python.org> The Buildbot has detected a new failure of hppa Ubuntu trunk. Full details are available at: http://www.python.org/dev/buildbot/all/hppa%20Ubuntu%20trunk/builds/547 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-ubuntu-hppa Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: neal.norwitz BUILD FAILED: failed test Excerpt from the test logfile: sincerely, -The Buildbot From skip at pobox.com Sun Jan 27 06:09:39 2008 From: skip at pobox.com (skip at pobox.com) Date: Sat, 26 Jan 2008 23:09:39 -0600 Subject: [Python-checkins] r60341 - in python/branches/trunk-math: Lib/test/test_math.py Modules/mathmodule.c In-Reply-To: <20080127043110.AEF431E4018@bag.python.org> References: <20080127043110.AEF431E4018@bag.python.org> Message-ID: <18332.4627.342312.499160@montanaro.dyndns.org> > Log: > Fix up hypot to follow C99 standard: hypot(inf, nan) should be inf. Is Python migrating to C99 or do earlier versions ambiguous in their definition of the return value of hypot(inf, nan)? Skip From buildbot at python.org Sun Jan 27 06:11:03 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 27 Jan 2008 05:11:03 +0000 Subject: [Python-checkins] buildbot failure in alpha Tru64 5.1 trunk Message-ID: <20080127051103.F3DB11E4018@bag.python.org> The Buildbot has detected a new failure of alpha Tru64 5.1 trunk. Full details are available at: http://www.python.org/dev/buildbot/all/alpha%20Tru64%205.1%20trunk/builds/2422 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-tru64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: neal.norwitz BUILD FAILED: failed test Excerpt from the test logfile: sincerely, -The Buildbot From buildbot at python.org Sun Jan 27 06:29:43 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 27 Jan 2008 05:29:43 +0000 Subject: [Python-checkins] buildbot failure in x86 gentoo 2.5 Message-ID: <20080127052943.4A0FF1E4018@bag.python.org> The Buildbot has detected a new failure of x86 gentoo 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20gentoo%202.5/builds/530 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-x86 Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: neal.norwitz BUILD FAILED: failed svn sincerely, -The Buildbot From buildbot at python.org Sun Jan 27 06:30:04 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 27 Jan 2008 05:30:04 +0000 Subject: [Python-checkins] buildbot failure in x86 mvlgcc 2.5 Message-ID: <20080127053004.9BACF1E4018@bag.python.org> The Buildbot has detected a new failure of x86 mvlgcc 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20mvlgcc%202.5/builds/406 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-linux Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: neal.norwitz BUILD FAILED: failed svn sincerely, -The Buildbot From buildbot at python.org Sun Jan 27 06:32:07 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 27 Jan 2008 05:32:07 +0000 Subject: [Python-checkins] buildbot failure in amd64 gentoo trunk Message-ID: <20080127053207.65D401E4018@bag.python.org> The Buildbot has detected a new failure of amd64 gentoo trunk. Full details are available at: http://www.python.org/dev/buildbot/all/amd64%20gentoo%20trunk/builds/44 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-amd64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: neal.norwitz BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_thread.py", line 284, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30995, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_thread.py", line 263, in writerThread self.assertEqual(data, self.makeData(key)) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/unittest.py", line 343, in failUnlessEqual (msg or '%r != %r' % (first, second)) AssertionError: None != '2000-2000-2000-2000-2000' Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_thread.py", line 263, in writerThread self.assertEqual(data, self.makeData(key)) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/unittest.py", line 343, in failUnlessEqual (msg or '%r != %r' % (first, second)) AssertionError: None != '1001-1001-1001-1001-1001' Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_thread.py", line 263, in writerThread self.assertEqual(data, self.makeData(key)) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/unittest.py", line 343, in failUnlessEqual (msg or '%r != %r' % (first, second)) AssertionError: None != '0002-0002-0002-0002-0002' 1 test failed: test_socket_ssl make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Sun Jan 27 06:40:36 2008 From: python-checkins at python.org (jeffrey.yasskin) Date: Sun, 27 Jan 2008 06:40:36 +0100 (CET) Subject: [Python-checkins] r60344 - in python/trunk/Lib: rational.py test/test_rational.py Message-ID: <20080127054036.1420A1E401E@bag.python.org> Author: jeffrey.yasskin Date: Sun Jan 27 06:40:35 2008 New Revision: 60344 Modified: python/trunk/Lib/rational.py python/trunk/Lib/test/test_rational.py Log: Make rational.gcd() public and allow Rational to take decimal strings, per Raymond's advice. Modified: python/trunk/Lib/rational.py ============================================================================== --- python/trunk/Lib/rational.py (original) +++ python/trunk/Lib/rational.py Sun Jan 27 06:40:35 2008 @@ -14,8 +14,8 @@ RationalAbc = numbers.Rational -def _gcd(a, b): # XXX This is a useful function. Consider making it public. - """Calculate the Greatest Common Divisor. +def gcd(a, b): + """Calculate the Greatest Common Divisor of a and b. Unless b==0, the result will have the same sign as b (so that when b is divided by it, the result comes out positive). @@ -40,8 +40,8 @@ >>> _binary_float_to_ratio(-.25) (-1, 4) """ - # XXX Consider moving this to to floatobject.c - # with a name like float.as_intger_ratio() + # XXX Move this to floatobject.c with a name like + # float.as_integer_ratio() if x == 0: return 0, 1 @@ -80,12 +80,9 @@ _RATIONAL_FORMAT = re.compile( - r'^\s*(?P[-+]?)(?P\d+)(?:/(?P\d+))?\s*$') + r'^\s*(?P[-+]?)(?P\d+)' + r'(?:/(?P\d+)|\.(?P\d+))?\s*$') -# XXX Consider accepting decimal strings as input since they are exact. -# Rational("2.01") --> s="2.01" ; Rational.from_decimal(Decimal(s)) --> Rational(201, 100)" -# If you want to avoid going through the decimal module, just parse the string directly: -# s.partition('.') --> ('2', '.', '01') --> Rational(int('2'+'01'), 10**len('01')) --> Rational(201, 100) class Rational(RationalAbc): """This class implements rational numbers. @@ -96,7 +93,7 @@ Rational() == 0. Rationals can also be constructed from strings of the form - '[-+]?[0-9]+(/[0-9]+)?', optionally surrounded by spaces. + '[-+]?[0-9]+((/|.)[0-9]+)?', optionally surrounded by spaces. """ @@ -106,7 +103,8 @@ def __new__(cls, numerator=0, denominator=1): """Constructs a Rational. - Takes a string, another Rational, or a numerator/denominator pair. + Takes a string like '3/2' or '3.2', another Rational, or a + numerator/denominator pair. """ self = super(Rational, cls).__new__(cls) @@ -118,9 +116,18 @@ m = _RATIONAL_FORMAT.match(input) if m is None: raise ValueError('Invalid literal for Rational: ' + input) - numerator = int(m.group('num')) - # Default denominator to 1. That's the only optional group. - denominator = int(m.group('denom') or 1) + numerator = m.group('num') + decimal = m.group('decimal') + if decimal: + # The literal is a decimal number. + numerator = int(numerator + decimal) + denominator = 10**len(decimal) + else: + # The literal is an integer or fraction. + numerator = int(numerator) + # Default denominator to 1. + denominator = int(m.group('denom') or 1) + if m.group('sign') == '-': numerator = -numerator @@ -139,7 +146,7 @@ if denominator == 0: raise ZeroDivisionError('Rational(%s, 0)' % numerator) - g = _gcd(numerator, denominator) + g = gcd(numerator, denominator) self.numerator = int(numerator // g) self.denominator = int(denominator // g) return self Modified: python/trunk/Lib/test/test_rational.py ============================================================================== --- python/trunk/Lib/test/test_rational.py (original) +++ python/trunk/Lib/test/test_rational.py Sun Jan 27 06:40:35 2008 @@ -9,10 +9,28 @@ from copy import copy, deepcopy from cPickle import dumps, loads R = rational.Rational +gcd = rational.gcd + + +class GcdTest(unittest.TestCase): + + def testMisc(self): + self.assertEquals(0, gcd(0, 0)) + self.assertEquals(1, gcd(1, 0)) + self.assertEquals(-1, gcd(-1, 0)) + self.assertEquals(1, gcd(0, 1)) + self.assertEquals(-1, gcd(0, -1)) + self.assertEquals(1, gcd(7, 1)) + self.assertEquals(-1, gcd(7, -1)) + self.assertEquals(1, gcd(-23, 15)) + self.assertEquals(12, gcd(120, 84)) + self.assertEquals(-12, gcd(84, -120)) + def _components(r): return (r.numerator, r.denominator) + class RationalTest(unittest.TestCase): def assertTypedEquals(self, expected, actual): @@ -55,8 +73,12 @@ self.assertEquals((3, 2), _components(R("3/2"))) self.assertEquals((3, 2), _components(R(" \n +3/2"))) self.assertEquals((-3, 2), _components(R("-3/2 "))) - self.assertEquals((3, 2), _components(R(" 03/02 \n "))) - self.assertEquals((3, 2), _components(R(u" 03/02 \n "))) + self.assertEquals((13, 2), _components(R(" 013/02 \n "))) + self.assertEquals((13, 2), _components(R(u" 013/02 \n "))) + + self.assertEquals((16, 5), _components(R(" 3.2 "))) + self.assertEquals((-16, 5), _components(R(u" -3.2 "))) + self.assertRaisesMessage( ZeroDivisionError, "Rational(3, 0)", @@ -76,9 +98,21 @@ ValueError, "Invalid literal for Rational: + 3/2", R, "+ 3/2") self.assertRaisesMessage( - # Only parse fractions, not decimals. - ValueError, "Invalid literal for Rational: 3.2", - R, "3.2") + # Avoid treating '.' as a regex special character. + ValueError, "Invalid literal for Rational: 3a2", + R, "3a2") + self.assertRaisesMessage( + # Only parse ordinary decimals, not scientific form. + ValueError, "Invalid literal for Rational: 3.2e4", + R, "3.2e4") + self.assertRaisesMessage( + # Don't accept combinations of decimals and rationals. + ValueError, "Invalid literal for Rational: 3/7.2", + R, "3/7.2") + self.assertRaisesMessage( + # Don't accept combinations of decimals and rationals. + ValueError, "Invalid literal for Rational: 3.2/7", + R, "3.2/7") def testImmutable(self): r = R(7, 3) @@ -368,7 +402,7 @@ self.assertEqual(id(r), id(deepcopy(r))) def test_main(): - run_unittest(RationalTest) + run_unittest(RationalTest, GcdTest) if __name__ == '__main__': test_main() From buildbot at python.org Sun Jan 27 06:57:46 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 27 Jan 2008 05:57:46 +0000 Subject: [Python-checkins] buildbot failure in g4 osx.4 trunk Message-ID: <20080127055746.4082C1E4018@bag.python.org> The Buildbot has detected a new failure of g4 osx.4 trunk. Full details are available at: http://www.python.org/dev/buildbot/all/g4%20osx.4%20trunk/builds/2720 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: psf-g4 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: neal.norwitz BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/bsddb/test/test_thread.py", line 284, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/Users/buildslave/bb/trunk.psf-g4/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30995, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') 1 test failed: test_socket_ssl make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Sun Jan 27 08:36:03 2008 From: python-checkins at python.org (neal.norwitz) Date: Sun, 27 Jan 2008 08:36:03 +0100 (CET) Subject: [Python-checkins] r60345 - python/trunk/Modules/mmapmodule.c Message-ID: <20080127073603.986A41E4018@bag.python.org> Author: neal.norwitz Date: Sun Jan 27 08:36:03 2008 New Revision: 60345 Modified: python/trunk/Modules/mmapmodule.c Log: Mostly reformat. Also set an error and return NULL if neither MS_WINDOWS nor UNIX is defined. This may have caused problems on cygwin. Modified: python/trunk/Modules/mmapmodule.c ============================================================================== --- python/trunk/Modules/mmapmodule.c (original) +++ python/trunk/Modules/mmapmodule.c Sun Jan 27 08:36:03 2008 @@ -532,23 +532,21 @@ if ((size_t)(offset + size) > self->size) { PyErr_SetString(PyExc_ValueError, "flush values out of range"); return NULL; - } else { + } #ifdef MS_WINDOWS - return PyInt_FromLong((long) - FlushViewOfFile(self->data+offset, size)); -#endif /* MS_WINDOWS */ -#ifdef UNIX - /* XXX semantics of return value? */ - /* XXX flags for msync? */ - if (-1 == msync(self->data + offset, size, - MS_SYNC)) - { - PyErr_SetFromErrno(mmap_module_error); - return NULL; - } - return PyInt_FromLong(0); -#endif /* UNIX */ + return PyInt_FromLong((long) FlushViewOfFile(self->data+offset, size)); +#elif defined(UNIX) + /* XXX semantics of return value? */ + /* XXX flags for msync? */ + if (-1 == msync(self->data + offset, size, MS_SYNC)) { + PyErr_SetFromErrno(mmap_module_error); + return NULL; } + return PyInt_FromLong(0); +#else + PyErr_SetString(PyExc_ValueError, "flush not supported on this system"); + return NULL; +#endif } static PyObject * From python-checkins at python.org Sun Jan 27 08:37:38 2008 From: python-checkins at python.org (neal.norwitz) Date: Sun, 27 Jan 2008 08:37:38 +0100 (CET) Subject: [Python-checkins] r60346 - python/trunk/Modules/mmapmodule.c Message-ID: <20080127073738.69FA41E4018@bag.python.org> Author: neal.norwitz Date: Sun Jan 27 08:37:38 2008 New Revision: 60346 Modified: python/trunk/Modules/mmapmodule.c Log: Use int for the sign rather than a char. char can be signed or unsigned. It's system dependent. This might fix the problem with test_rfind failing. Modified: python/trunk/Modules/mmapmodule.c ============================================================================== --- python/trunk/Modules/mmapmodule.c (original) +++ python/trunk/Modules/mmapmodule.c Sun Jan 27 08:37:38 2008 @@ -263,7 +263,7 @@ return NULL; } else { const char *p, *start_p, *end_p; - char sign = reverse ? -1 : 1; + int sign = reverse ? -1 : 1; if (start < 0) start += self->size; From python-checkins at python.org Sun Jan 27 08:41:33 2008 From: python-checkins at python.org (neal.norwitz) Date: Sun, 27 Jan 2008 08:41:33 +0100 (CET) Subject: [Python-checkins] r60347 - python/trunk/Include/unicodeobject.h Message-ID: <20080127074133.DD6731E4018@bag.python.org> Author: neal.norwitz Date: Sun Jan 27 08:41:33 2008 New Revision: 60347 Modified: python/trunk/Include/unicodeobject.h Log: Add stdarg include for va_list to get this to compile on cygwin Modified: python/trunk/Include/unicodeobject.h ============================================================================== --- python/trunk/Include/unicodeobject.h (original) +++ python/trunk/Include/unicodeobject.h Sun Jan 27 08:41:33 2008 @@ -1,6 +1,8 @@ #ifndef Py_UNICODEOBJECT_H #define Py_UNICODEOBJECT_H +#include + /* Unicode implementation based on original code by Fredrik Lundh, From buildbot at python.org Sun Jan 27 09:18:52 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 27 Jan 2008 08:18:52 +0000 Subject: [Python-checkins] buildbot failure in x86 gentoo trunk Message-ID: <20080127081853.21FE11E4018@bag.python.org> The Buildbot has detected a new failure of x86 gentoo trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20gentoo%20trunk/builds/2973 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-x86 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: neal.norwitz BUILD FAILED: failed test Excerpt from the test logfile: sincerely, -The Buildbot From buildbot at python.org Sun Jan 27 09:50:30 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 27 Jan 2008 08:50:30 +0000 Subject: [Python-checkins] buildbot failure in ia64 Ubuntu trunk Message-ID: <20080127085030.922561E402D@bag.python.org> The Buildbot has detected a new failure of ia64 Ubuntu trunk. Full details are available at: http://www.python.org/dev/buildbot/all/ia64%20Ubuntu%20trunk/builds/1318 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ia64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: neal.norwitz BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_socket_ssl make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Sun Jan 27 10:06:28 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 27 Jan 2008 09:06:28 +0000 Subject: [Python-checkins] buildbot failure in x86 FreeBSD trunk Message-ID: <20080127090628.53B561E4003@bag.python.org> The Buildbot has detected a new failure of x86 FreeBSD trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20FreeBSD%20trunk/builds/485 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-freebsd Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: jeffrey.yasskin,neal.norwitz BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 227, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 268, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 281, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 560, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 227, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 268, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 281, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 560, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable 1 test failed: test_xmlrpc Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 227, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 268, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 281, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 560, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable ====================================================================== ERROR: test_introspection1 (test.test_xmlrpc.SimpleServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/test/test_xmlrpc.py", line 413, in test_introspection1 meth = p.system.listMethods() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/xmlrpclib.py", line 1157, in __call__ return self.__send(self.__name, args) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/xmlrpclib.py", line 1447, in __request verbose=self.__verbose File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/xmlrpclib.py", line 1193, in request self.send_content(h, request_body) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/xmlrpclib.py", line 1309, in send_content connection.send(request_body) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/httplib.py", line 701, in send self.sock.sendall(str) File "", line 1, in sendall error: [Errno 32] Broken pipe sincerely, -The Buildbot From buildbot at python.org Sun Jan 27 10:39:59 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 27 Jan 2008 09:39:59 +0000 Subject: [Python-checkins] buildbot failure in S-390 Debian 3.0 Message-ID: <20080127093959.C106F1E4003@bag.python.org> The Buildbot has detected a new failure of S-390 Debian 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/S-390%20Debian%203.0/builds/0 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-s390 Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes,georg.brandl,neal.norwitz,raymond.hettinger,thomas.heller,thomas.wouters,walter.doerwald BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_mmap ====================================================================== FAIL: test_rfind (test.test_mmap.MmapTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-s390/build/Lib/test/test_mmap.py", line 283, in test_rfind self.assertEqual(m.rfind('one'), 8) AssertionError: -1 != 8 make: *** [buildbottest] Error 1 sincerely, -The Buildbot From nnorwitz at gmail.com Sun Jan 27 11:26:52 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Sun, 27 Jan 2008 05:26:52 -0500 Subject: [Python-checkins] Python Regression Test Failures refleak (5) Message-ID: <20080127102652.GA24154@python.psfb.org> test_opcodes leaked [0, -2, 2] references, sum=0 test_doctest leaked [0, 0, -2] references, sum=-2 test_asynchat leaked [87, -87, 0] references, sum=0 test_cmd_line leaked [0, 23, -23] references, sum=0 test_descrtut leaked [4, 0, -2] references, sum=2 test_functools leaked [-4, -2, 0] references, sum=-6 test_gc leaked [0, -2, 0] references, sum=-2 test_importhooks leaked [-6, 2, 6] references, sum=2 test_os leaked [0, -2, 2] references, sum=0 test_threadedtempfile leaked [0, 79, -79] references, sum=0 test_threadsignals leaked [0, -10, 0] references, sum=-10 test_urllib2_localnet leaked [-116, 126, -120] references, sum=-110 From python-checkins at python.org Sun Jan 27 11:13:57 2008 From: python-checkins at python.org (raymond.hettinger) Date: Sun, 27 Jan 2008 11:13:57 +0100 (CET) Subject: [Python-checkins] r60348 - python/trunk/Lib/rational.py Message-ID: <20080127101357.995321E4003@bag.python.org> Author: raymond.hettinger Date: Sun Jan 27 11:13:57 2008 New Revision: 60348 Modified: python/trunk/Lib/rational.py Log: Docstring nit Modified: python/trunk/Lib/rational.py ============================================================================== --- python/trunk/Lib/rational.py (original) +++ python/trunk/Lib/rational.py Sun Jan 27 11:13:57 2008 @@ -103,7 +103,7 @@ def __new__(cls, numerator=0, denominator=1): """Constructs a Rational. - Takes a string like '3/2' or '3.2', another Rational, or a + Takes a string like '3/2' or '1.5', another Rational, or a numerator/denominator pair. """ From python-checkins at python.org Sun Jan 27 11:47:55 2008 From: python-checkins at python.org (raymond.hettinger) Date: Sun, 27 Jan 2008 11:47:55 +0100 (CET) Subject: [Python-checkins] r60349 - python/trunk/Doc/library/collections.rst Message-ID: <20080127104755.A3D1B1E4003@bag.python.org> Author: raymond.hettinger Date: Sun Jan 27 11:47:55 2008 New Revision: 60349 Modified: python/trunk/Doc/library/collections.rst Log: Removed an unnecessary and confusing paragraph from the namedtuple docs. Modified: python/trunk/Doc/library/collections.rst ============================================================================== --- python/trunk/Doc/library/collections.rst (original) +++ python/trunk/Doc/library/collections.rst Sun Jan 27 11:47:55 2008 @@ -526,16 +526,7 @@ Point: x= 3.000 y= 4.000 hypot= 5.000 Point: x=14.000 y= 0.714 hypot=14.018 -Another use for subclassing is to replace performance critcal methods with -faster versions that bypass error-checking:: - - class Point(namedtuple('Point', 'x y')): - __slots__ = () - _make = classmethod(tuple.__new__) - def _replace(self, _map=map, **kwds): - return self._make(_map(kwds.get, ('x', 'y'), self)) - -The subclasses shown above set ``__slots__`` to an empty tuple. This keeps +The subclass shown above sets ``__slots__`` to an empty tuple. This keeps keep memory requirements low by preventing the creation of instance dictionaries. Subclassing is not useful for adding new, stored fields. Instead, simply From buildbot at python.org Sun Jan 27 11:56:39 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 27 Jan 2008 10:56:39 +0000 Subject: [Python-checkins] buildbot failure in ppc Debian unstable trunk Message-ID: <20080127105640.108461E4003@bag.python.org> The Buildbot has detected a new failure of ppc Debian unstable trunk. Full details are available at: http://www.python.org/dev/buildbot/all/ppc%20Debian%20unstable%20trunk/builds/684 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/bsddb/test/test_thread.py", line 263, in writerThread self.assertEqual(data, self.makeData(key)) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/unittest.py", line 343, in failUnlessEqual (msg or '%r != %r' % (first, second)) AssertionError: None != '2002-2002-2002-2002-2002' Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/bsddb/test/test_thread.py", line 263, in writerThread self.assertEqual(data, self.makeData(key)) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/unittest.py", line 343, in failUnlessEqual (msg or '%r != %r' % (first, second)) AssertionError: None != '1007-1007-1007-1007-1007' Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/bsddb/test/test_thread.py", line 263, in writerThread self.assertEqual(data, self.makeData(key)) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/unittest.py", line 343, in failUnlessEqual (msg or '%r != %r' % (first, second)) AssertionError: None != '0004-0004-0004-0004-0004' 1 test failed: test_xmlrpc ====================================================================== ERROR: test_fail_no_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_xmlrpc.py", line 560, in test_fail_no_info p.pow(6,8) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1157, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1447, in __request verbose=self.__verbose File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1195, in request errcode, errmsg, headers = h.getreply() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 1006, in getreply response = self._conn.getresponse() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 932, in getresponse response.begin() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 415, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 271, in readheaders line = self.fp.readline() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/socket.py", line 354, in readline data = recv(1) error: [Errno 104] Connection reset by peer ====================================================================== ERROR: test_fail_with_info (test.test_xmlrpc.FailingServerTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_xmlrpc.py", line 580, in test_fail_with_info p.pow(6,8) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1157, in __call__ return self.__send(self.__name, args) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1447, in __request verbose=self.__verbose File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/xmlrpclib.py", line 1195, in request errcode, errmsg, headers = h.getreply() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 1006, in getreply response = self._conn.getresponse() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 932, in getresponse response.begin() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 415, in begin self.msg = HTTPMessage(self.fp, 0) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/mimetools.py", line 16, in __init__ rfc822.Message.__init__(self, fp, seekable) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/rfc822.py", line 104, in __init__ self.readheaders() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/httplib.py", line 271, in readheaders line = self.fp.readline() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/socket.py", line 354, in readline data = recv(1) error: [Errno 104] Connection reset by peer make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Sun Jan 27 11:56:46 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 27 Jan 2008 10:56:46 +0000 Subject: [Python-checkins] buildbot failure in ppc Debian unstable 2.5 Message-ID: <20080127105646.658881E4003@bag.python.org> The Buildbot has detected a new failure of ppc Debian unstable 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/ppc%20Debian%20unstable%202.5/builds/156 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc Build Reason: The web-page 'force build' button was pressed by 'doko': gcc-4.3 Build Source Stamp: [branch release25-maint] HEAD Blamelist: BUILD FAILED: failed svn sincerely, -The Buildbot From buildbot at python.org Sun Jan 27 12:21:13 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 27 Jan 2008 11:21:13 +0000 Subject: [Python-checkins] buildbot failure in S-390 Debian 2.5 Message-ID: <20080127112114.4CB671E401D@bag.python.org> The Buildbot has detected a new failure of S-390 Debian 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/S-390%20Debian%202.5/builds/0 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-s390 Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: amaury.forgeotdarc,andrew.kuchling,christian.heimes,georg.brandl,guido.van.rossum,martin.v.loewis,neal.norwitz,thomas.heller,thomas.wouters BUILD FAILED: failed test Excerpt from the test logfile: sincerely, -The Buildbot From buildbot at python.org Sun Jan 27 13:37:36 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 27 Jan 2008 12:37:36 +0000 Subject: [Python-checkins] buildbot failure in S-390 Debian trunk Message-ID: <20080127123736.EDAFF1E4003@bag.python.org> The Buildbot has detected a new failure of S-390 Debian trunk. Full details are available at: http://www.python.org/dev/buildbot/all/S-390%20Debian%20trunk/builds/0 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-s390 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: amaury.forgeotdarc,andrew.kuchling,armin.rigo,christian.heimes,georg.brandl,gregory.p.smith,guido.van.rossum,jeffrey.yasskin,kurt.kaiser,neal.norwitz,raymond.hettinger,thomas.heller,thomas.wouters,vinay.sajip BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_socket_ssl ====================================================================== ERROR: testBasic (test.test_socket_ssl.ConnectedTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-s390/build/Lib/test/test_socket_ssl.py", line 31, in testBasic buf = f.read() File "/home/pybot/buildarea/trunk.klose-debian-s390/build/Lib/ssl.py", line 333, in read data = self._sslobj.read(recv_size) SSLError: [Errno 8] _ssl.c:1276: EOF occurred in violation of protocol make: *** [buildbottest] Error 1 sincerely, -The Buildbot From lists at cheimes.de Sun Jan 27 14:46:39 2008 From: lists at cheimes.de (Christian Heimes) Date: Sun, 27 Jan 2008 14:46:39 +0100 Subject: [Python-checkins] r60341 - in python/branches/trunk-math: Lib/test/test_math.py Modules/mathmodule.c In-Reply-To: <18332.4627.342312.499160@montanaro.dyndns.org> References: <20080127043110.AEF431E4018@bag.python.org> <18332.4627.342312.499160@montanaro.dyndns.org> Message-ID: skip at pobox.com wrote: > Is Python migrating to C99 or do earlier versions ambiguous in their > definition of the return value of hypot(inf, nan)? Mark and I are trying to make the math module more reliable. Currently it's platform dependent when a function raises ValueError, OverflowError or returns NAN. Christian From dickinsm at gmail.com Sun Jan 27 15:38:50 2008 From: dickinsm at gmail.com (Mark Dickinson) Date: Sun, 27 Jan 2008 14:38:50 +0000 (UTC) Subject: [Python-checkins] =?utf-8?q?r60341_-_in_python/branches/trunk-mat?= =?utf-8?q?h=3A_Lib/test/test=5Fmath=2Epy_Modules/mathmodule=2Ec?= References: <20080127043110.AEF431E4018@bag.python.org> <18332.4627.342312.499160@montanaro.dyndns.org> Message-ID: Christian Heimes cheimes.de> writes: > Mark and I are trying to make the math module more reliable. Currently > it's platform dependent when a function raises ValueError, OverflowError > or returns NAN. And I'd quite like to be able to remove the warning that you added to the end of the math library documentation around 5 years ago. But there's some way to go yet :) As far as I know there are no plans to migrate to C99---all the code should still be ANSI C. C99 is just a handy standard for deciding exactly what Python should do in various circumstances. (IEEE-754r would work too, except that it isn't finished yet.) From buildbot at python.org Sun Jan 27 16:25:23 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 27 Jan 2008 15:25:23 +0000 Subject: [Python-checkins] buildbot failure in amd64 gentoo trunk Message-ID: <20080127152524.075871E4003@bag.python.org> The Buildbot has detected a new failure of amd64 gentoo trunk. Full details are available at: http://www.python.org/dev/buildbot/all/amd64%20gentoo%20trunk/builds/47 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-amd64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed failed slave lost sincerely, -The Buildbot From buildbot at python.org Sun Jan 27 16:27:56 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 27 Jan 2008 15:27:56 +0000 Subject: [Python-checkins] buildbot failure in sparc solaris10 gcc 3.0 Message-ID: <20080127152756.CA90D1E4003@bag.python.org> The Buildbot has detected a new failure of sparc solaris10 gcc 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/sparc%20solaris10%20gcc%203.0/builds/522 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-sun Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes BUILD FAILED: failed compile sincerely, -The Buildbot From buildbot at python.org Sun Jan 27 16:28:00 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 27 Jan 2008 15:28:00 +0000 Subject: [Python-checkins] buildbot failure in g4 osx.4 3.0 Message-ID: <20080127152801.193A71E4003@bag.python.org> The Buildbot has detected a new failure of g4 osx.4 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/g4%20osx.4%203.0/builds/470 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: psf-g4 Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes BUILD FAILED: failed compile sincerely, -The Buildbot From buildbot at python.org Sun Jan 27 16:28:18 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 27 Jan 2008 15:28:18 +0000 Subject: [Python-checkins] buildbot failure in ia64 Ubuntu 3.0 Message-ID: <20080127152818.85C4C1E4003@bag.python.org> The Buildbot has detected a new failure of ia64 Ubuntu 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/ia64%20Ubuntu%203.0/builds/474 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ia64 Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes BUILD FAILED: failed compile sincerely, -The Buildbot From python-checkins at python.org Sun Jan 27 18:10:15 2008 From: python-checkins at python.org (neal.norwitz) Date: Sun, 27 Jan 2008 18:10:15 +0100 (CET) Subject: [Python-checkins] r60355 - python/trunk/Objects/typeobject.c Message-ID: <20080127171015.6912D1E4018@bag.python.org> Author: neal.norwitz Date: Sun Jan 27 18:10:14 2008 New Revision: 60355 Modified: python/trunk/Objects/typeobject.c Log: Whitespace cleanup Modified: python/trunk/Objects/typeobject.c ============================================================================== --- python/trunk/Objects/typeobject.c (original) +++ python/trunk/Objects/typeobject.c Sun Jan 27 18:10:14 2008 @@ -58,7 +58,7 @@ PyObject *raw, *ref; Py_ssize_t i, n; - if(!PyType_HasFeature(type, Py_TPFLAGS_VALID_VERSION_TAG)) + if (!PyType_HasFeature(type, Py_TPFLAGS_VALID_VERSION_TAG)) return; raw = type->tp_subclasses; @@ -94,7 +94,7 @@ Py_ssize_t i, n; int clear = 0; - if(!PyType_HasFeature(type, Py_TPFLAGS_HAVE_VERSION_TAG)) + if (!PyType_HasFeature(type, Py_TPFLAGS_HAVE_VERSION_TAG)) return; n = PyTuple_GET_SIZE(bases); @@ -1388,8 +1388,8 @@ PyObject *bases, *result; PyObject *to_merge, *bases_aslist; - if(type->tp_dict == NULL) { - if(PyType_Ready(type) < 0) + if (type->tp_dict == NULL) { + if (PyType_Ready(type) < 0) return NULL; } @@ -2321,7 +2321,7 @@ unsigned int h; if (MCACHE_CACHEABLE_NAME(name) && - PyType_HasFeature(type,Py_TPFLAGS_VALID_VERSION_TAG)) { + PyType_HasFeature(type, Py_TPFLAGS_VALID_VERSION_TAG)) { /* fast path */ h = MCACHE_HASH_METHOD(type, name); if (method_cache[h].version == type->tp_version_tag && From python-checkins at python.org Sun Jan 27 18:10:29 2008 From: python-checkins at python.org (neal.norwitz) Date: Sun, 27 Jan 2008 18:10:29 +0100 (CET) Subject: [Python-checkins] r60356 - python/trunk/Parser/tokenizer.c Message-ID: <20080127171029.BE00C1E4024@bag.python.org> Author: neal.norwitz Date: Sun Jan 27 18:10:29 2008 New Revision: 60356 Modified: python/trunk/Parser/tokenizer.c Log: Add assertion that we do not blow out newl Modified: python/trunk/Parser/tokenizer.c ============================================================================== --- python/trunk/Parser/tokenizer.c (original) +++ python/trunk/Parser/tokenizer.c Sun Jan 27 18:10:29 2008 @@ -605,6 +605,7 @@ for (s = str;; s++) { if (*s == '\0') break; else if (*s == '\n') { + assert(lineno < 2); newl[lineno] = s; lineno++; if (lineno == 2) break; From python-checkins at python.org Sun Jan 27 18:10:36 2008 From: python-checkins at python.org (neal.norwitz) Date: Sun, 27 Jan 2008 18:10:36 +0100 (CET) Subject: [Python-checkins] r60357 - python/trunk/Modules/_ssl.c Message-ID: <20080127171036.380401E402E@bag.python.org> Author: neal.norwitz Date: Sun Jan 27 18:10:35 2008 New Revision: 60357 Modified: python/trunk/Modules/_ssl.c Log: Initialize variable to prevent warning on some platform/config. Modified: python/trunk/Modules/_ssl.c ============================================================================== --- python/trunk/Modules/_ssl.c (original) +++ python/trunk/Modules/_ssl.c Sun Jan 27 18:10:35 2008 @@ -17,7 +17,7 @@ #ifdef WITH_THREAD #include "pythread.h" #define PySSL_BEGIN_ALLOW_THREADS { \ - PyThreadState *_save; \ + PyThreadState *_save = NULL; \ if (_ssl_locks_count>0) {_save = PyEval_SaveThread();} #define PySSL_BLOCK_THREADS if (_ssl_locks_count>0){PyEval_RestoreThread(_save)}; #define PySSL_UNBLOCK_THREADS if (_ssl_locks_count>0){_save = PyEval_SaveThread()}; @@ -687,7 +687,7 @@ } p = ext->value->data; - if(method->it) + if (method->it) names = (GENERAL_NAMES*) (ASN1_item_d2i(NULL, &p, ext->value->length, From python-checkins at python.org Sun Jan 27 18:10:43 2008 From: python-checkins at python.org (neal.norwitz) Date: Sun, 27 Jan 2008 18:10:43 +0100 (CET) Subject: [Python-checkins] r60358 - python/trunk/Modules/_ctypes/libffi/src/alpha/ffi.c python/trunk/Modules/_ctypes/libffi/src/alpha/osf.S Message-ID: <20080127171043.6C1351E400B@bag.python.org> Author: neal.norwitz Date: Sun Jan 27 18:10:43 2008 New Revision: 60358 Modified: python/trunk/Modules/_ctypes/libffi/src/alpha/ffi.c python/trunk/Modules/_ctypes/libffi/src/alpha/osf.S Log: Update to newer version of ffi. Fixes crashes and test failures of longdouble Modified: python/trunk/Modules/_ctypes/libffi/src/alpha/ffi.c ============================================================================== --- python/trunk/Modules/_ctypes/libffi/src/alpha/ffi.c (original) +++ python/trunk/Modules/_ctypes/libffi/src/alpha/ffi.c Sun Jan 27 18:10:43 2008 @@ -25,11 +25,22 @@ #include #include - #include -extern void ffi_call_osf(void *, unsigned long, unsigned, void *, void (*)(void)); -extern void ffi_closure_osf(void); +/* Force FFI_TYPE_LONGDOUBLE to be different than FFI_TYPE_DOUBLE; + all further uses in this file will refer to the 128-bit type. */ +#if defined(__LONG_DOUBLE_128__) +# if FFI_TYPE_LONGDOUBLE != 4 +# error FFI_TYPE_LONGDOUBLE out of date +# endif +#else +# undef FFI_TYPE_LONGDOUBLE +# define FFI_TYPE_LONGDOUBLE 4 +#endif + +extern void ffi_call_osf(void *, unsigned long, unsigned, void *, void (*)(void)) + FFI_HIDDEN; +extern void ffi_closure_osf(void) FFI_HIDDEN; ffi_status @@ -49,6 +60,11 @@ cif->flags = cif->rtype->type; break; + case FFI_TYPE_LONGDOUBLE: + /* 128-bit long double is returned in memory, like a struct. */ + cif->flags = FFI_TYPE_STRUCT; + break; + default: cif->flags = FFI_TYPE_INT; break; @@ -57,6 +73,7 @@ return FFI_OK; } + void ffi_call(ffi_cif *cif, void (*fn)(void), void *rvalue, void **avalue) { @@ -64,8 +81,6 @@ long i, avn; ffi_type **arg_types; - FFI_ASSERT (cif->abi == FFI_OSF); - /* If the return value is a struct and we don't have a return value address then we need to make one. */ if (rvalue == NULL && cif->flags == FFI_TYPE_STRUCT) @@ -84,6 +99,8 @@ while (i < avn) { + size_t size = (*arg_types)->size; + switch ((*arg_types)->type) { case FFI_TYPE_SINT8: @@ -129,6 +146,12 @@ *(double *) argp = *(double *)(* avalue); break; + case FFI_TYPE_LONGDOUBLE: + /* 128-bit long double is passed by reference. */ + *(long double **) argp = (long double *)(* avalue); + size = sizeof (long double *); + break; + case FFI_TYPE_STRUCT: memcpy(argp, *avalue, (*arg_types)->size); break; @@ -137,7 +160,7 @@ FFI_ASSERT(0); } - argp += ALIGN((*arg_types)->size, FFI_SIZEOF_ARG) / FFI_SIZEOF_ARG; + argp += ALIGN(size, FFI_SIZEOF_ARG) / FFI_SIZEOF_ARG; i++, arg_types++, avalue++; } @@ -153,8 +176,6 @@ { unsigned int *tramp; - FFI_ASSERT (cif->abi == FFI_OSF); - tramp = (unsigned int *) &closure->tramp[0]; tramp[0] = 0x47fb0401; /* mov $27,$1 */ tramp[1] = 0xa77b0010; /* ldq $27,16($27) */ @@ -177,7 +198,8 @@ return FFI_OK; } -int + +long FFI_HIDDEN ffi_closure_osf_inner(ffi_closure *closure, void *rvalue, unsigned long *argp) { ffi_cif *cif; @@ -205,6 +227,8 @@ /* Grab the addresses of the arguments from the stack frame. */ while (i < avn) { + size_t size = arg_types[i]->size; + switch (arg_types[i]->type) { case FFI_TYPE_SINT8: @@ -236,16 +260,22 @@ avalue[i] = &argp[argn - (argn < 6 ? 6 : 0)]; break; + case FFI_TYPE_LONGDOUBLE: + /* 128-bit long double is passed by reference. */ + avalue[i] = (long double *) argp[argn]; + size = sizeof (long double *); + break; + default: - FFI_ASSERT(0); + abort (); } - argn += ALIGN(arg_types[i]->size, FFI_SIZEOF_ARG) / FFI_SIZEOF_ARG; + argn += ALIGN(size, FFI_SIZEOF_ARG) / FFI_SIZEOF_ARG; i++; } /* Invoke the closure. */ - (closure->fun) (cif, rvalue, avalue, closure->user_data); + closure->fun (cif, rvalue, avalue, closure->user_data); /* Tell ffi_closure_osf how to perform return type promotions. */ return cif->rtype->type; Modified: python/trunk/Modules/_ctypes/libffi/src/alpha/osf.S ============================================================================== --- python/trunk/Modules/_ctypes/libffi/src/alpha/osf.S (original) +++ python/trunk/Modules/_ctypes/libffi/src/alpha/osf.S Sun Jan 27 18:10:43 2008 @@ -1,10 +1,8 @@ /* ----------------------------------------------------------------------- - osf.S - Copyright (c) 1998, 2001 Red Hat + osf.S - Copyright (c) 1998, 2001, 2007 Red Hat Alpha/OSF Foreign Function Interface - $Id: osf.S,v 1.2 2006/03/03 20:24:26 theller Exp $ - Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the ``Software''), to deal in the Software without restriction, including @@ -42,6 +40,8 @@ .align 3 .globl ffi_call_osf .ent ffi_call_osf + FFI_HIDDEN(ffi_call_osf) + ffi_call_osf: .frame $15, 32, $26, 0 .mask 0x4008000, -32 @@ -129,6 +129,8 @@ .align 3 .globl ffi_closure_osf .ent ffi_closure_osf + FFI_HIDDEN(ffi_closure_osf) + ffi_closure_osf: .frame $30, 16*8, $26, 0 .mask 0x4000000, -16*8 @@ -265,7 +267,7 @@ .gprel32 $load_32 # FFI_TYPE_INT .gprel32 $load_float # FFI_TYPE_FLOAT .gprel32 $load_double # FFI_TYPE_DOUBLE - .gprel32 $load_double # FFI_TYPE_LONGDOUBLE + .gprel32 $load_none # FFI_TYPE_LONGDOUBLE .gprel32 $load_u8 # FFI_TYPE_UINT8 .gprel32 $load_s8 # FFI_TYPE_SINT8 .gprel32 $load_u16 # FFI_TYPE_UINT16 From python-checkins at python.org Sun Jan 27 18:10:50 2008 From: python-checkins at python.org (neal.norwitz) Date: Sun, 27 Jan 2008 18:10:50 +0100 (CET) Subject: [Python-checkins] r60359 - python/trunk/Lib/test/test_resource.py Message-ID: <20080127171050.B03A01E401E@bag.python.org> Author: neal.norwitz Date: Sun Jan 27 18:10:50 2008 New Revision: 60359 Modified: python/trunk/Lib/test/test_resource.py Log: Add a tiny sleep and additional flush to force the file to really be synced. Modified: python/trunk/Lib/test/test_resource.py ============================================================================== --- python/trunk/Lib/test/test_resource.py (original) +++ python/trunk/Lib/test/test_resource.py Sun Jan 27 18:10:50 2008 @@ -1,8 +1,9 @@ import unittest from test import test_support - -import os, resource +import os +import resource +import time # This test is checking a few specific problem spots with the resource module. @@ -59,6 +60,8 @@ # an attempt to ensure the file is really synced and # the exception raised. for i in range(5): + time.sleep(.1) + f.flush() f.close() except IOError: if not limit_set: From python-checkins at python.org Sun Jan 27 18:10:58 2008 From: python-checkins at python.org (neal.norwitz) Date: Sun, 27 Jan 2008 18:10:58 +0100 (CET) Subject: [Python-checkins] r60360 - python/trunk/Lib/test/test_socket_ssl.py Message-ID: <20080127171058.66D2F1E401D@bag.python.org> Author: neal.norwitz Date: Sun Jan 27 18:10:58 2008 New Revision: 60360 Modified: python/trunk/Lib/test/test_socket_ssl.py Log: Retry connection in case it fails to reduce flakiness Modified: python/trunk/Lib/test/test_socket_ssl.py ============================================================================== --- python/trunk/Lib/test/test_socket_ssl.py (original) +++ python/trunk/Lib/test/test_socket_ssl.py Sun Jan 27 18:10:58 2008 @@ -14,8 +14,22 @@ # Optionally test SSL support, if we have it in the tested platform skip_expected = not hasattr(socket, "ssl") + class ConnectedTests(unittest.TestCase): + def urlopen(self, host, *args, **kwargs): + # Connecting to remote hosts is flaky. Make it more robust + # by retrying the connection several times. + for i in range(3): + try: + return urllib.urlopen(host, *args, **kwargs) + except IOError, e: + last_exc = e + continue + except: + raise + raise last_exc + def testBasic(self): socket.RAND_status() try: @@ -27,7 +41,7 @@ socket.RAND_add("this is a random string", 75.0) with test_support.transient_internet(): - f = urllib.urlopen('https://sf.net') + f = self.urlopen('https://sf.net') buf = f.read() f.close() @@ -36,7 +50,7 @@ print >> sys.stderr, """\ WARNING: an attempt to connect to %r %s, in test_timeout. That may be legitimate, but is not the outcome we - hoped for. If this message is seen often, test_timeout should be + hoped for. If this message is seen often, testTimeout should be changed to use a more reliable address.""" % (ADDR, extra_msg) # A service which issues a welcome banner (without need to write @@ -103,6 +117,19 @@ connector() t.join() + def connect(self, s, host_port): + # Connecting to remote hosts is flaky. Make it more robust + # by retrying the connection several times. + for i in range(3): + try: + return s.connect(host_port) + except IOError, e: + last_exc = e + continue + except: + raise + raise last_exc + def test_978833(self): if test_support.verbose: print "test_978833 ..." @@ -110,7 +137,7 @@ import os, httplib, ssl with test_support.transient_internet(): s = socket.socket(socket.AF_INET) - s.connect(("svn.python.org", 443)) + self.connect(s, ("svn.python.org", 443)) fd = s._sock.fileno() sock = ssl.wrap_socket(s) s = None From python-checkins at python.org Sun Jan 27 18:11:11 2008 From: python-checkins at python.org (neal.norwitz) Date: Sun, 27 Jan 2008 18:11:11 +0100 (CET) Subject: [Python-checkins] r60361 - python/trunk/Lib/test/test_xmlrpc.py Message-ID: <20080127171111.740841E4021@bag.python.org> Author: neal.norwitz Date: Sun Jan 27 18:11:11 2008 New Revision: 60361 Modified: python/trunk/Lib/test/test_xmlrpc.py Log: Catch socket errors that are often the cause of transient failures. Many of these exceptions are due to resource unavailable, so the existing code should be able to handle many more spurious errors. Modified: python/trunk/Lib/test/test_xmlrpc.py ============================================================================== --- python/trunk/Lib/test/test_xmlrpc.py (original) +++ python/trunk/Lib/test/test_xmlrpc.py Sun Jan 27 18:11:11 2008 @@ -389,7 +389,7 @@ try: p = xmlrpclib.ServerProxy('http://localhost:%d' % PORT) self.assertEqual(p.pow(6,8), 6**8) - except xmlrpclib.ProtocolError, e: + except (xmlrpclib.ProtocolError, socket.error), e: # ignore failures due to non-blocking socket 'unavailable' errors if not is_unavailable_exception(e): # protocol error; provide additional information in test output @@ -415,7 +415,7 @@ 'system.listMethods', 'system.methodHelp', 'system.methodSignature', 'system.multicall']) self.assertEqual(set(meth), expected_methods) - except xmlrpclib.ProtocolError, e: + except (xmlrpclib.ProtocolError, socket.error), e: # ignore failures due to non-blocking socket 'unavailable' errors if not is_unavailable_exception(e): # protocol error; provide additional information in test output @@ -427,7 +427,7 @@ p = xmlrpclib.ServerProxy('http://localhost:%d' % PORT) divhelp = p.system.methodHelp('div') self.assertEqual(divhelp, 'This is the div function') - except xmlrpclib.ProtocolError, e: + except (xmlrpclib.ProtocolError, socket.error), e: # ignore failures due to non-blocking socket 'unavailable' errors if not is_unavailable_exception(e): # protocol error; provide additional information in test output @@ -439,7 +439,7 @@ p = xmlrpclib.ServerProxy('http://localhost:%d' % PORT) myfunction = p.system.methodHelp('my_function') self.assertEqual(myfunction, 'This is my function') - except xmlrpclib.ProtocolError, e: + except (xmlrpclib.ProtocolError, socket.error), e: # ignore failures due to non-blocking socket 'unavailable' errors if not is_unavailable_exception(e): # protocol error; provide additional information in test output @@ -452,7 +452,7 @@ p = xmlrpclib.ServerProxy('http://localhost:%d' % PORT) divsig = p.system.methodSignature('div') self.assertEqual(divsig, 'signatures not supported') - except xmlrpclib.ProtocolError, e: + except (xmlrpclib.ProtocolError, socket.error), e: # ignore failures due to non-blocking socket 'unavailable' errors if not is_unavailable_exception(e): # protocol error; provide additional information in test output @@ -469,7 +469,7 @@ self.assertEqual(add_result, 2+3) self.assertEqual(pow_result, 6**8) self.assertEqual(div_result, 127//42) - except xmlrpclib.ProtocolError, e: + except (xmlrpclib.ProtocolError, socket.error), e: # ignore failures due to non-blocking socket 'unavailable' errors if not is_unavailable_exception(e): # protocol error; provide additional information in test output @@ -490,7 +490,7 @@ self.assertEqual(result.results[0]['faultString'], ':method "this_is_not_exists" ' 'is not supported') - except xmlrpclib.ProtocolError, e: + except (xmlrpclib.ProtocolError, socket.error), e: # ignore failures due to non-blocking socket 'unavailable' errors if not is_unavailable_exception(e): # protocol error; provide additional information in test output @@ -545,7 +545,7 @@ try: p = xmlrpclib.ServerProxy('http://localhost:%d' % PORT) self.assertEqual(p.pow(6,8), 6**8) - except xmlrpclib.ProtocolError, e: + except (xmlrpclib.ProtocolError, socket.error), e: # ignore failures due to non-blocking socket 'unavailable' errors if not is_unavailable_exception(e): # protocol error; provide additional information in test output @@ -558,7 +558,7 @@ try: p = xmlrpclib.ServerProxy('http://localhost:%d' % PORT) p.pow(6,8) - except xmlrpclib.ProtocolError, e: + except (xmlrpclib.ProtocolError, socket.error), e: # ignore failures due to non-blocking socket 'unavailable' errors if not is_unavailable_exception(e): # The two server-side error headers shouldn't be sent back in this case @@ -578,7 +578,7 @@ try: p = xmlrpclib.ServerProxy('http://localhost:%d' % PORT) p.pow(6,8) - except xmlrpclib.ProtocolError, e: + except (xmlrpclib.ProtocolError, socket.error), e: # ignore failures due to non-blocking socket 'unavailable' errors if not is_unavailable_exception(e): # We should get error info in the response From python-checkins at python.org Sun Jan 27 18:12:15 2008 From: python-checkins at python.org (neal.norwitz) Date: Sun, 27 Jan 2008 18:12:15 +0100 (CET) Subject: [Python-checkins] r60362 - python/trunk/Python/ceval.c Message-ID: <20080127171216.00D8E1E400B@bag.python.org> Author: neal.norwitz Date: Sun Jan 27 18:12:15 2008 New Revision: 60362 Modified: python/trunk/Python/ceval.c Log: Reduce buffer size since we do not need 1k Modified: python/trunk/Python/ceval.c ============================================================================== --- python/trunk/Python/ceval.c (original) +++ python/trunk/Python/ceval.c Sun Jan 27 18:12:15 2008 @@ -2492,7 +2492,7 @@ else { /* This check is expensive! */ if (PyErr_Occurred()) { - char buf[1024]; + char buf[128]; sprintf(buf, "Stack unwind with exception " "set and why=%d", why); Py_FatalError(buf); From python-checkins at python.org Sun Jan 27 18:13:07 2008 From: python-checkins at python.org (neal.norwitz) Date: Sun, 27 Jan 2008 18:13:07 +0100 (CET) Subject: [Python-checkins] r60363 - python/trunk/Lib/test/test_bsddb3.py Message-ID: <20080127171307.EC6881E400B@bag.python.org> Author: neal.norwitz Date: Sun Jan 27 18:13:07 2008 New Revision: 60363 Modified: python/trunk/Lib/test/test_bsddb3.py Log: Print periodic "still working" messages since this suite is slow. Modified: python/trunk/Lib/test/test_bsddb3.py ============================================================================== --- python/trunk/Lib/test/test_bsddb3.py (original) +++ python/trunk/Lib/test/test_bsddb3.py Sun Jan 27 18:13:07 2008 @@ -3,6 +3,7 @@ Run all test cases. """ import sys +import time import unittest from test.test_support import requires, verbose, run_unittest, unlink @@ -21,6 +22,30 @@ sys.argv.remove('silent') +class TimingCheck(unittest.TestCase): + + """This class is not a real test. Its purpose is to print a message + periodically when the test runs slowly. This will prevent the buildbots + from timing out on slow machines.""" + + # How much time in seconds before printing a 'Still working' message. + # Since this is run at most once between each test module, use a smaller + # interval than other tests. + _PRINT_WORKING_MSG_INTERVAL = 4 * 60 + + # next_time is used as a global variable that survives each instance. + # This is necessary since a new instance will be created for each test. + next_time = time.time() + _PRINT_WORKING_MSG_INTERVAL + + def testCheckElapsedTime(self): + # Print still working message since these tests can be really slow. + now = time.time() + if self.next_time <= now: + TimingCheck.next_time = now + self._PRINT_WORKING_MSG_INTERVAL + sys.__stdout__.write(' test_bsddb3 still working, be patient...\n') + sys.__stdout__.flush() + + def suite(): try: # this is special, it used to segfault the interpreter @@ -53,6 +78,7 @@ module = __import__("bsddb.test."+name, globals(), locals(), name) #print module,name alltests.addTest(module.test_suite()) + alltests.addTest(unittest.makeSuite(TimingCheck)) return alltests From python-checkins at python.org Sun Jan 27 19:09:48 2008 From: python-checkins at python.org (neal.norwitz) Date: Sun, 27 Jan 2008 19:09:48 +0100 (CET) Subject: [Python-checkins] r60364 - python/trunk/Lib/test/test_resource.py Message-ID: <20080127180948.514EB1E400B@bag.python.org> Author: neal.norwitz Date: Sun Jan 27 19:09:48 2008 New Revision: 60364 Modified: python/trunk/Lib/test/test_resource.py Log: Update the comment and remove the close. If we close we can't flush anymore. We might still need to close after the for loop if flushing 6! times still doesn't cause the signal/exception. Modified: python/trunk/Lib/test/test_resource.py ============================================================================== --- python/trunk/Lib/test/test_resource.py (original) +++ python/trunk/Lib/test/test_resource.py Sun Jan 27 19:09:48 2008 @@ -56,13 +56,12 @@ f.flush() # On some systems (e.g., Ubuntu on hppa) the flush() # doesn't always cause the exception, but the close() - # does eventually. Try closing several times in + # does eventually. Try flushing several times in # an attempt to ensure the file is really synced and # the exception raised. for i in range(5): time.sleep(.1) f.flush() - f.close() except IOError: if not limit_set: raise From python-checkins at python.org Sun Jan 27 19:14:43 2008 From: python-checkins at python.org (georg.brandl) Date: Sun, 27 Jan 2008 19:14:43 +0100 (CET) Subject: [Python-checkins] r60365 - python/trunk/Lib/pydoc.py Message-ID: <20080127181443.9B8B71E400B@bag.python.org> Author: georg.brandl Date: Sun Jan 27 19:14:43 2008 New Revision: 60365 Modified: python/trunk/Lib/pydoc.py Log: Remove effectless expression statement. Modified: python/trunk/Lib/pydoc.py ============================================================================== --- python/trunk/Lib/pydoc.py (original) +++ python/trunk/Lib/pydoc.py Sun Jan 27 19:14:43 2008 @@ -1197,7 +1197,6 @@ else: tag = "inherited from %s" % classname(thisclass, object.__module__) - filter(lambda t: not t[0].startswith('_'), attrs) # Sort attrs by name. attrs.sort() From python-checkins at python.org Sun Jan 27 19:19:04 2008 From: python-checkins at python.org (neal.norwitz) Date: Sun, 27 Jan 2008 19:19:04 +0100 (CET) Subject: [Python-checkins] r60367 - python/trunk/Lib/test/test_xmlrpc.py Message-ID: <20080127181904.A1B331E400B@bag.python.org> Author: neal.norwitz Date: Sun Jan 27 19:19:04 2008 New Revision: 60367 Modified: python/trunk/Lib/test/test_xmlrpc.py Log: Try to handle socket.errors properly in is_unavailable Modified: python/trunk/Lib/test/test_xmlrpc.py ============================================================================== --- python/trunk/Lib/test/test_xmlrpc.py (original) +++ python/trunk/Lib/test/test_xmlrpc.py Sun Jan 27 19:19:04 2008 @@ -348,10 +348,14 @@ given by operations on non-blocking sockets.''' # sometimes we get a -1 error code and/or empty headers - if e.errcode == -1 or e.headers is None: - return True + try: + if e.errcode == -1 or e.headers is None: + return True + exc_mess = e.headers.get('X-exception') + except AttributeError: + # Ignore socket.errors here. + exc_mess = str(e) - exc_mess = e.headers.get('X-exception') if exc_mess and 'temporarily unavailable' in exc_mess.lower(): return True From python-checkins at python.org Sun Jan 27 19:55:46 2008 From: python-checkins at python.org (christian.heimes) Date: Sun, 27 Jan 2008 19:55:46 +0100 (CET) Subject: [Python-checkins] r60368 - in python/branches/trunk-math: Doc/c-api/module.rst Doc/library/collections.rst Doc/library/ftplib.rst Doc/library/logging.rst Doc/library/os.path.rst Doc/library/struct.rst Doc/tutorial/inputoutput.rst Doc/tutorial/stdlib2.rst Doc/whatsnew/2.6.rst Include/genobject.h Include/longintrepr.h Include/longobject.h Include/unicodeobject.h Lib/bsddb/test/test_associate.py Lib/bsddb/test/test_compare.py Lib/bsddb/test/test_cursor_pget_bug.py Lib/bsddb/test/test_pickle.py Lib/bsddb/test/test_sequence.py Lib/bsddb/test/test_thread.py Lib/ctypes/test/test_numbers.py Lib/decimal.py Lib/encodings/__init__.py Lib/idlelib/NEWS.txt Lib/idlelib/configHandler.py Lib/idlelib/run.py Lib/logging/__init__.py Lib/logging/handlers.py Lib/optparse.py Lib/pprint.py Lib/rational.py Lib/re.py Lib/test/crashers/borrowed_ref_3.py Lib/test/crashers/borrowed_ref_4.py Lib/test/crashers/loosing_dict_ref.py Lib/test/test_asynchat.py Lib/test/test_bsddb3.py Lib/test/test_decimal.py Lib/test/test_descr.py Lib/test/test_dict.py Lib/test/test_generators.py Lib/test/test_grammar.py Lib/test/test_largefile.py Lib/test/test_pprint.py Lib/test/test_rational.py Lib/test/test_resource.py Lib/test/test_set.py Lib/test/test_socket_ssl.py Lib/test/test_telnetlib.py Lib/test/test_urllib2net.py Lib/test/test_urllibnet.py Lib/test/test_xmlrpc.py Lib/test/test_zipfile.py Lib/threading.py Lib/urllib2.py Makefile.pre.in Misc/NEWS Modules/_ctypes/_ctypes.c Modules/_ctypes/cfield.c Modules/_ctypes/libffi/src/alpha/ffi.c Modules/_ctypes/libffi/src/alpha/osf.S Modules/_cursesmodule.c Modules/_ssl.c Modules/config.c.in Modules/mathmodule.c Modules/mmapmodule.c Modules/socketmodule.c Objects/dictobject.c Objects/floatobject.c Objects/genobject.c Objects/listobject.c Objects/longobject.c Objects/object.c Objects/setobject.c Objects/typeobject.c Objects/unicodeobject.c Parser/tokenizer.c Python/bltinmodule.c Python/ceval.c Python/compile.c Python/dynload_win.c setup.py Message-ID: <20080127185546.9125C1E4025@bag.python.org> Author: christian.heimes Date: Sun Jan 27 19:55:42 2008 New Revision: 60368 Removed: python/branches/trunk-math/Lib/test/crashers/borrowed_ref_3.py python/branches/trunk-math/Lib/test/crashers/borrowed_ref_4.py python/branches/trunk-math/Lib/test/crashers/loosing_dict_ref.py Modified: python/branches/trunk-math/ (props changed) python/branches/trunk-math/Doc/c-api/module.rst python/branches/trunk-math/Doc/library/collections.rst python/branches/trunk-math/Doc/library/ftplib.rst python/branches/trunk-math/Doc/library/logging.rst python/branches/trunk-math/Doc/library/os.path.rst python/branches/trunk-math/Doc/library/struct.rst python/branches/trunk-math/Doc/tutorial/inputoutput.rst python/branches/trunk-math/Doc/tutorial/stdlib2.rst python/branches/trunk-math/Doc/whatsnew/2.6.rst python/branches/trunk-math/Include/genobject.h python/branches/trunk-math/Include/longintrepr.h python/branches/trunk-math/Include/longobject.h python/branches/trunk-math/Include/unicodeobject.h python/branches/trunk-math/Lib/bsddb/test/test_associate.py python/branches/trunk-math/Lib/bsddb/test/test_compare.py python/branches/trunk-math/Lib/bsddb/test/test_cursor_pget_bug.py python/branches/trunk-math/Lib/bsddb/test/test_pickle.py python/branches/trunk-math/Lib/bsddb/test/test_sequence.py python/branches/trunk-math/Lib/bsddb/test/test_thread.py python/branches/trunk-math/Lib/ctypes/test/test_numbers.py python/branches/trunk-math/Lib/decimal.py python/branches/trunk-math/Lib/encodings/__init__.py python/branches/trunk-math/Lib/idlelib/NEWS.txt python/branches/trunk-math/Lib/idlelib/configHandler.py python/branches/trunk-math/Lib/idlelib/run.py python/branches/trunk-math/Lib/logging/__init__.py python/branches/trunk-math/Lib/logging/handlers.py python/branches/trunk-math/Lib/optparse.py python/branches/trunk-math/Lib/pprint.py python/branches/trunk-math/Lib/rational.py python/branches/trunk-math/Lib/re.py python/branches/trunk-math/Lib/test/test_asynchat.py python/branches/trunk-math/Lib/test/test_bsddb3.py python/branches/trunk-math/Lib/test/test_decimal.py python/branches/trunk-math/Lib/test/test_descr.py python/branches/trunk-math/Lib/test/test_dict.py python/branches/trunk-math/Lib/test/test_generators.py python/branches/trunk-math/Lib/test/test_grammar.py python/branches/trunk-math/Lib/test/test_largefile.py python/branches/trunk-math/Lib/test/test_pprint.py python/branches/trunk-math/Lib/test/test_rational.py python/branches/trunk-math/Lib/test/test_resource.py python/branches/trunk-math/Lib/test/test_set.py python/branches/trunk-math/Lib/test/test_socket_ssl.py python/branches/trunk-math/Lib/test/test_telnetlib.py python/branches/trunk-math/Lib/test/test_urllib2net.py python/branches/trunk-math/Lib/test/test_urllibnet.py python/branches/trunk-math/Lib/test/test_xmlrpc.py python/branches/trunk-math/Lib/test/test_zipfile.py python/branches/trunk-math/Lib/threading.py python/branches/trunk-math/Lib/urllib2.py python/branches/trunk-math/Makefile.pre.in python/branches/trunk-math/Misc/NEWS python/branches/trunk-math/Modules/_ctypes/_ctypes.c python/branches/trunk-math/Modules/_ctypes/cfield.c python/branches/trunk-math/Modules/_ctypes/libffi/src/alpha/ffi.c python/branches/trunk-math/Modules/_ctypes/libffi/src/alpha/osf.S python/branches/trunk-math/Modules/_cursesmodule.c python/branches/trunk-math/Modules/_ssl.c python/branches/trunk-math/Modules/config.c.in python/branches/trunk-math/Modules/mathmodule.c python/branches/trunk-math/Modules/mmapmodule.c python/branches/trunk-math/Modules/socketmodule.c python/branches/trunk-math/Objects/dictobject.c python/branches/trunk-math/Objects/floatobject.c python/branches/trunk-math/Objects/genobject.c python/branches/trunk-math/Objects/listobject.c python/branches/trunk-math/Objects/longobject.c python/branches/trunk-math/Objects/object.c python/branches/trunk-math/Objects/setobject.c python/branches/trunk-math/Objects/typeobject.c python/branches/trunk-math/Objects/unicodeobject.c python/branches/trunk-math/Parser/tokenizer.c python/branches/trunk-math/Python/bltinmodule.c python/branches/trunk-math/Python/ceval.c python/branches/trunk-math/Python/compile.c python/branches/trunk-math/Python/dynload_win.c python/branches/trunk-math/setup.py Log: Merged revisions 60211-60363 via svnmerge from svn+ssh://pythondev at svn.python.org/python/trunk ........ r60213 | christian.heimes | 2008-01-23 15:00:25 +0100 (Wed, 23 Jan 2008) | 1 line Use Py_TYPE() instead of ->ob_type ........ r60214 | armin.rigo | 2008-01-23 15:07:13 +0100 (Wed, 23 Jan 2008) | 3 lines patch 1754489 by vlahan: improve portability of address length calculation for AF_UNIX sockets ........ r60216 | christian.heimes | 2008-01-23 15:20:50 +0100 (Wed, 23 Jan 2008) | 1 line Fixed bug #1915: Python compiles with --enable-unicode=no again. However several extension methods and modules do not work without unicode support. ........ r60221 | christian.heimes | 2008-01-23 18:15:06 +0100 (Wed, 23 Jan 2008) | 2 lines Applied #1069410 The "can't load dll" message box on Windows is suppressed while an extension is loaded by calling SetErrorMode in dynload_win.c. The error is still reported properly. ........ r60224 | guido.van.rossum | 2008-01-23 21:19:01 +0100 (Wed, 23 Jan 2008) | 2 lines Fix two crashers. ........ r60225 | kurt.kaiser | 2008-01-23 23:19:23 +0100 (Wed, 23 Jan 2008) | 3 lines Could not open files in .idlerc directory if latter was hidden on Windows. Issue 1743, Issue 1862. ........ r60226 | guido.van.rossum | 2008-01-23 23:43:27 +0100 (Wed, 23 Jan 2008) | 2 lines Fix misleading comment reported in issue #1917. ........ r60227 | kurt.kaiser | 2008-01-23 23:55:26 +0100 (Wed, 23 Jan 2008) | 2 lines There was an error on exit if no sys.exitfunc was defined. Issue 1647. ........ r60228 | guido.van.rossum | 2008-01-24 00:23:43 +0100 (Thu, 24 Jan 2008) | 2 lines Turn three recently fixed crashers into regular tests. ........ r60229 | raymond.hettinger | 2008-01-24 01:54:21 +0100 (Thu, 24 Jan 2008) | 1 line Add first-cut at an approximation function (still needs rounding tweaks). Add continued fraction conversions. ........ r60230 | raymond.hettinger | 2008-01-24 03:00:25 +0100 (Thu, 24 Jan 2008) | 1 line Minor clean-up and more tests. ........ r60231 | raymond.hettinger | 2008-01-24 03:05:06 +0100 (Thu, 24 Jan 2008) | 1 line Cleanup ........ r60232 | neal.norwitz | 2008-01-24 05:14:50 +0100 (Thu, 24 Jan 2008) | 1 line Fix the tests by restoring __import__. I think the test is still valid. ........ r60233 | neal.norwitz | 2008-01-24 08:40:51 +0100 (Thu, 24 Jan 2008) | 4 lines Fix the test_urllib2net failures that were caused by r58067. I'm not sure this is the correct fix, but at least the test passes now and should be closer to correct. ........ r60234 | gregory.p.smith | 2008-01-24 10:38:26 +0100 (Thu, 24 Jan 2008) | 4 lines Fix issue1789: The tutorial contained a misuse of the struct module. (also remove an unneeded import struct from test_largefile) ........ r60237 | vinay.sajip | 2008-01-24 13:37:08 +0100 (Thu, 24 Jan 2008) | 1 line Added optional delay argument to FileHandler and subclasses. ........ r60238 | vinay.sajip | 2008-01-24 13:37:33 +0100 (Thu, 24 Jan 2008) | 1 line Added optional delay argument to FileHandler and subclasses. ........ r60239 | vinay.sajip | 2008-01-24 13:38:30 +0100 (Thu, 24 Jan 2008) | 1 line Added documentation for optional delay argument to FileHandler and subclasses. ........ r60240 | vinay.sajip | 2008-01-24 13:43:33 +0100 (Thu, 24 Jan 2008) | 1 line Updated for optional delay argument to FileHandler and subclasses. ........ r60243 | guido.van.rossum | 2008-01-24 16:53:22 +0100 (Thu, 24 Jan 2008) | 2 lines Fi debug turd -- a call accidentally left out. ........ r60246 | guido.van.rossum | 2008-01-24 18:58:05 +0100 (Thu, 24 Jan 2008) | 2 lines Fix test67.py from issue #1303614. ........ r60248 | raymond.hettinger | 2008-01-24 19:05:54 +0100 (Thu, 24 Jan 2008) | 1 line Clean-up and speed-up code by accessing numerator/denominator directly. There's no reason to enforce readonliness ........ r60249 | raymond.hettinger | 2008-01-24 19:12:23 +0100 (Thu, 24 Jan 2008) | 1 line Revert 60189 and restore performance. ........ r60250 | guido.van.rossum | 2008-01-24 19:21:02 +0100 (Thu, 24 Jan 2008) | 5 lines News about recently fixed crashers: - A few crashers fixed: weakref_in_del.py (issue #1377858); loosing_dict_ref.py (issue #1303614, test67.py); borrowed_ref_[34].py (not in tracker). ........ r60252 | thomas.heller | 2008-01-24 19:36:27 +0100 (Thu, 24 Jan 2008) | 7 lines Use a PyDictObject again for the array type cache; retrieving items from the WeakValueDictionary was slower by nearly a factor of 3. To avoid leaks, weakref proxies for the array types are put into the cache dict, with weakref callbacks that removes the entries when the type goes away. ........ r60253 | thomas.heller | 2008-01-24 19:54:12 +0100 (Thu, 24 Jan 2008) | 2 lines Replace Py_BuildValue with PyTuple_Pack because it is faster. Also add a missing DECREF. ........ r60254 | raymond.hettinger | 2008-01-24 20:05:29 +0100 (Thu, 24 Jan 2008) | 1 line Add support for trunc(). ........ r60255 | thomas.heller | 2008-01-24 20:15:02 +0100 (Thu, 24 Jan 2008) | 5 lines Invert the checks in get_[u]long and get_[u]longlong. The intent was to not accept float types; the result was that integer-like objects were not accepted. Ported from release25-maint. ........ r60256 | raymond.hettinger | 2008-01-24 20:30:19 +0100 (Thu, 24 Jan 2008) | 1 line Add support for int(r) just like the other numeric classes. ........ r60263 | raymond.hettinger | 2008-01-24 22:23:58 +0100 (Thu, 24 Jan 2008) | 1 line Expand tests to include nested graph structures. ........ r60264 | raymond.hettinger | 2008-01-24 22:47:56 +0100 (Thu, 24 Jan 2008) | 1 line Shorter pprint's for empty sets and frozensets. Fix indentation of frozensets. Add tests including two complex data structures. ........ r60265 | amaury.forgeotdarc | 2008-01-24 23:51:18 +0100 (Thu, 24 Jan 2008) | 14 lines #1920: when considering a block starting by "while 0", the compiler optimized the whole construct away, even when an 'else' clause is present:: while 0: print("no") else: print("yes") did not generate any code at all. Now the compiler emits the 'else' block, like it already does for 'if' statements. Will backport. ........ r60266 | amaury.forgeotdarc | 2008-01-24 23:59:25 +0100 (Thu, 24 Jan 2008) | 2 lines News entry for r60265 (Issue 1920). ........ r60269 | raymond.hettinger | 2008-01-25 00:50:26 +0100 (Fri, 25 Jan 2008) | 1 line More code cleanup. Remove unnecessary indirection to useless class methods. ........ r60270 | raymond.hettinger | 2008-01-25 01:21:54 +0100 (Fri, 25 Jan 2008) | 1 line Add support for copy, deepcopy, and pickle. ........ r60271 | raymond.hettinger | 2008-01-25 01:33:45 +0100 (Fri, 25 Jan 2008) | 1 line Mark todos and review comments. ........ r60272 | raymond.hettinger | 2008-01-25 02:13:12 +0100 (Fri, 25 Jan 2008) | 1 line Add one other review comment. ........ r60273 | raymond.hettinger | 2008-01-25 02:23:38 +0100 (Fri, 25 Jan 2008) | 1 line Fix-up signature for approximation. ........ r60274 | raymond.hettinger | 2008-01-25 02:46:33 +0100 (Fri, 25 Jan 2008) | 1 line More design notes ........ r60276 | neal.norwitz | 2008-01-25 07:37:23 +0100 (Fri, 25 Jan 2008) | 6 lines Make the test more robust by trying to reconnect up to 3 times in case there were transient failures. This will hopefully silence the buildbots for this test. As we find other tests that have a problem, we can fix with a similar strategy assuming it is successful. It worked on my box in a loop for 10+ runs where it would have an exception otherwise. ........ r60277 | neal.norwitz | 2008-01-25 09:04:16 +0100 (Fri, 25 Jan 2008) | 4 lines Add prototypes to get the mathmodule.c to compile on OSF1 5.1 (Tru64) and eliminate a compiler warning in floatobject.c. There might be a better way to go about this, but it should be good enough for now. ........ r60283 | christian.heimes | 2008-01-25 13:18:43 +0100 (Fri, 25 Jan 2008) | 3 lines Backport of several functions from Python 3.0 to 2.6 including PyUnicode_FromString, PyUnicode_Format and PyLong_From/AsSsize_t. The functions are partly required for the backport of the bytearray type and _fileio module. They should also make it easier to port C to 3.0. First chapter of the Python 3.0 io framework back port: _fileio The next step depends on a working bytearray type which itself depends on a backport of the nwe buffer API. ........ r60286 | christian.heimes | 2008-01-25 15:54:23 +0100 (Fri, 25 Jan 2008) | 1 line setup.py doesn't pick up changes to a header file ........ r60287 | christian.heimes | 2008-01-25 16:52:11 +0100 (Fri, 25 Jan 2008) | 2 lines Added the Python core headers Include/*.h and pyconfig.h as dependencies for the extensions in Modules/ It forces a rebuild of all extensions when a header files has been modified ........ r60291 | raymond.hettinger | 2008-01-25 20:24:46 +0100 (Fri, 25 Jan 2008) | 4 lines Changes 54857 and 54840 broke code and were reverted in Py2.5 just before it was released, but that reversion never made it to the Py2.6 head. ........ r60296 | guido.van.rossum | 2008-01-25 20:50:26 +0100 (Fri, 25 Jan 2008) | 2 lines Rewrite the list_inline_repeat overflow check slightly differently. ........ r60301 | thomas.wouters | 2008-01-25 22:09:34 +0100 (Fri, 25 Jan 2008) | 4 lines Use the right (portable) definition of the max of a Py_ssize_t. ........ r60303 | thomas.wouters | 2008-01-26 02:47:05 +0100 (Sat, 26 Jan 2008) | 5 lines Make 'testall' work again when building in a separate directory. test_distutils still fails when doing that. ........ r60305 | neal.norwitz | 2008-01-26 06:54:48 +0100 (Sat, 26 Jan 2008) | 3 lines Prevent this test from failing if there are transient network problems by retrying the host for up to 3 times. ........ r60306 | neal.norwitz | 2008-01-26 08:26:12 +0100 (Sat, 26 Jan 2008) | 12 lines Use a condition variable (threading.Event) rather than sleeps and checking a global to determine when the server is ready to be used. This slows the test down, but should make it correct. There was a race condition before where the server could have assigned a port, yet it wasn't ready to serve requests. If the client sent a request before the server was completely ready, it would get an exception. There was machinery to try to handle this condition. All of that should be unnecessary and removed if this change works. A NOTE was added as a comment about what needs to be fixed. The buildbots will tell us if there are more errors or if this test is now stable. ........ r60307 | neal.norwitz | 2008-01-26 08:38:03 +0100 (Sat, 26 Jan 2008) | 3 lines Fix exception in tearDown on ppc buildbot. If there's no directory, that shouldn't cause the test to fail. Just like it setUp. ........ r60308 | raymond.hettinger | 2008-01-26 09:19:06 +0100 (Sat, 26 Jan 2008) | 3 lines Make PySet_Add() work with frozensets. Works like PyTuple_SetItem() to build-up values in a brand new frozenset. ........ r60309 | neal.norwitz | 2008-01-26 09:26:00 +0100 (Sat, 26 Jan 2008) | 1 line The OS X buildbot had errors with the unavailable exceptions disabled. Restore it. ........ r60310 | raymond.hettinger | 2008-01-26 09:37:28 +0100 (Sat, 26 Jan 2008) | 4 lines Let marshal build-up sets and frozensets one element at a time. Saves the unnecessary creation of a tuple as intermediate container. ........ r60311 | raymond.hettinger | 2008-01-26 09:41:13 +0100 (Sat, 26 Jan 2008) | 1 line Update test code for change to PySet_Add(). ........ r60312 | raymond.hettinger | 2008-01-26 10:31:11 +0100 (Sat, 26 Jan 2008) | 1 line Revert PySet_Add() changes. ........ r60314 | georg.brandl | 2008-01-26 10:43:35 +0100 (Sat, 26 Jan 2008) | 2 lines #1934: fix os.path.isabs docs. ........ r60316 | georg.brandl | 2008-01-26 12:00:18 +0100 (Sat, 26 Jan 2008) | 2 lines Add missing things in re docstring. ........ r60317 | georg.brandl | 2008-01-26 12:02:22 +0100 (Sat, 26 Jan 2008) | 2 lines Slashes allowed on Windows. ........ r60319 | georg.brandl | 2008-01-26 14:41:21 +0100 (Sat, 26 Jan 2008) | 2 lines Fix markup again. ........ r60320 | andrew.kuchling | 2008-01-26 14:50:51 +0100 (Sat, 26 Jan 2008) | 1 line Add some items ........ r60321 | georg.brandl | 2008-01-26 15:02:38 +0100 (Sat, 26 Jan 2008) | 2 lines Clarify "b" mode under Unix. ........ r60322 | georg.brandl | 2008-01-26 15:03:47 +0100 (Sat, 26 Jan 2008) | 3 lines #1940: make it possible to use curses.filter() before curses.initscr() as the documentation says. ........ r60324 | georg.brandl | 2008-01-26 15:14:20 +0100 (Sat, 26 Jan 2008) | 3 lines #1473257: add generator.gi_code attribute that refers to the original code object backing the generator. Patch by Collin Winter. ........ r60325 | georg.brandl | 2008-01-26 15:19:22 +0100 (Sat, 26 Jan 2008) | 2 lines Move C API entries to the corresponding section. ........ r60326 | christian.heimes | 2008-01-26 17:43:35 +0100 (Sat, 26 Jan 2008) | 1 line Unit test fix from Giampaolo Rodola, #1938 ........ r60327 | gregory.p.smith | 2008-01-26 19:51:05 +0100 (Sat, 26 Jan 2008) | 2 lines Update docs for new callpack params added in r60188 ........ r60329 | neal.norwitz | 2008-01-26 21:24:36 +0100 (Sat, 26 Jan 2008) | 3 lines Cleanup the code a bit. test_rfind is failing on PPC and PPC64 buildbots, this might fix the problem. ........ r60330 | neal.norwitz | 2008-01-26 22:02:45 +0100 (Sat, 26 Jan 2008) | 1 line Always try to remove the test file even if close raises an exception ........ r60331 | neal.norwitz | 2008-01-26 22:21:59 +0100 (Sat, 26 Jan 2008) | 3 lines Reduce the race condition by signalling when the server is ready and not trying to connect before. ........ r60334 | neal.norwitz | 2008-01-27 00:13:46 +0100 (Sun, 27 Jan 2008) | 5 lines On some systems (e.g., Ubuntu on hppa) the flush() doesn't cause the exception, but the close() does. Will backport. ........ r60335 | neal.norwitz | 2008-01-27 00:14:17 +0100 (Sun, 27 Jan 2008) | 2 lines Consistently use tempfile.tempdir for the db_home directory. ........ r60338 | neal.norwitz | 2008-01-27 02:44:05 +0100 (Sun, 27 Jan 2008) | 4 lines Eliminate the sleeps that assume the server will start in .5 seconds. This should make the test less flaky. It also speeds up the test by about 75% on my box (20+ seconds -> ~4 seconds). ........ r60342 | neal.norwitz | 2008-01-27 06:02:34 +0100 (Sun, 27 Jan 2008) | 6 lines Try to prevent this test from being flaky. We might need a sleep in here which isn't as bad as it sounds. The close() *should* raise an exception, so if it didn't we should give more time to sync and really raise it. Will backport. ........ r60344 | jeffrey.yasskin | 2008-01-27 06:40:35 +0100 (Sun, 27 Jan 2008) | 3 lines Make rational.gcd() public and allow Rational to take decimal strings, per Raymond's advice. ........ r60345 | neal.norwitz | 2008-01-27 08:36:03 +0100 (Sun, 27 Jan 2008) | 3 lines Mostly reformat. Also set an error and return NULL if neither MS_WINDOWS nor UNIX is defined. This may have caused problems on cygwin. ........ r60346 | neal.norwitz | 2008-01-27 08:37:38 +0100 (Sun, 27 Jan 2008) | 3 lines Use int for the sign rather than a char. char can be signed or unsigned. It's system dependent. This might fix the problem with test_rfind failing. ........ r60347 | neal.norwitz | 2008-01-27 08:41:33 +0100 (Sun, 27 Jan 2008) | 1 line Add stdarg include for va_list to get this to compile on cygwin ........ r60348 | raymond.hettinger | 2008-01-27 11:13:57 +0100 (Sun, 27 Jan 2008) | 1 line Docstring nit ........ r60349 | raymond.hettinger | 2008-01-27 11:47:55 +0100 (Sun, 27 Jan 2008) | 1 line Removed an unnecessary and confusing paragraph from the namedtuple docs. ........ r60355 | neal.norwitz | 2008-01-27 18:10:14 +0100 (Sun, 27 Jan 2008) | 1 line Whitespace cleanup ........ r60356 | neal.norwitz | 2008-01-27 18:10:29 +0100 (Sun, 27 Jan 2008) | 1 line Add assertion that we do not blow out newl ........ r60357 | neal.norwitz | 2008-01-27 18:10:35 +0100 (Sun, 27 Jan 2008) | 1 line Initialize variable to prevent warning on some platform/config. ........ r60358 | neal.norwitz | 2008-01-27 18:10:43 +0100 (Sun, 27 Jan 2008) | 1 line Update to newer version of ffi. Fixes crashes and test failures of longdouble ........ r60359 | neal.norwitz | 2008-01-27 18:10:50 +0100 (Sun, 27 Jan 2008) | 1 line Add a tiny sleep and additional flush to force the file to really be synced. ........ r60360 | neal.norwitz | 2008-01-27 18:10:58 +0100 (Sun, 27 Jan 2008) | 1 line Retry connection in case it fails to reduce flakiness ........ r60361 | neal.norwitz | 2008-01-27 18:11:11 +0100 (Sun, 27 Jan 2008) | 4 lines Catch socket errors that are often the cause of transient failures. Many of these exceptions are due to resource unavailable, so the existing code should be able to handle many more spurious errors. ........ r60362 | neal.norwitz | 2008-01-27 18:12:15 +0100 (Sun, 27 Jan 2008) | 1 line Reduce buffer size since we do not need 1k ........ r60363 | neal.norwitz | 2008-01-27 18:13:07 +0100 (Sun, 27 Jan 2008) | 1 line Print periodic "still working" messages since this suite is slow. ........ Modified: python/branches/trunk-math/Doc/c-api/module.rst ============================================================================== --- python/branches/trunk-math/Doc/c-api/module.rst (original) +++ python/branches/trunk-math/Doc/c-api/module.rst Sun Jan 27 19:55:42 2008 @@ -18,7 +18,7 @@ is exposed to Python programs as ``types.ModuleType``. -.. cmacro:: int PyModule_Check(PyObject *p) +.. cfunction:: int PyModule_Check(PyObject *p) Return true if *p* is a module object, or a subtype of a module object. @@ -26,7 +26,7 @@ Allowed subtypes to be accepted. -.. cmacro:: int PyModule_CheckExact(PyObject *p) +.. cfunction:: int PyModule_CheckExact(PyObject *p) Return true if *p* is a module object, but not a subtype of :cdata:`PyModule_Type`. @@ -104,7 +104,7 @@ .. versionadded:: 2.0 -.. cmacro:: int PyModule_AddIntMacro(PyObject *module, macro) +.. cfunction:: int PyModule_AddIntMacro(PyObject *module, macro) Add an int constant to *module*. The name and the value are taken from *macro*. For example ``PyModule_AddConstant(module, AF_INET)`` adds the int @@ -113,7 +113,7 @@ .. versionadded:: 2.6 -.. cmacro:: int PyModule_AddStringMacro(PyObject *module, macro) +.. cfunction:: int PyModule_AddStringMacro(PyObject *module, macro) Add a string constant to *module*. Modified: python/branches/trunk-math/Doc/library/collections.rst ============================================================================== --- python/branches/trunk-math/Doc/library/collections.rst (original) +++ python/branches/trunk-math/Doc/library/collections.rst Sun Jan 27 19:55:42 2008 @@ -526,16 +526,7 @@ Point: x= 3.000 y= 4.000 hypot= 5.000 Point: x=14.000 y= 0.714 hypot=14.018 -Another use for subclassing is to replace performance critcal methods with -faster versions that bypass error-checking:: - - class Point(namedtuple('Point', 'x y')): - __slots__ = () - _make = classmethod(tuple.__new__) - def _replace(self, _map=map, **kwds): - return self._make(_map(kwds.get, ('x', 'y'), self)) - -The subclasses shown above set ``__slots__`` to an empty tuple. This keeps +The subclass shown above sets ``__slots__`` to an empty tuple. This keeps keep memory requirements low by preventing the creation of instance dictionaries. Subclassing is not useful for adding new, stored fields. Instead, simply Modified: python/branches/trunk-math/Doc/library/ftplib.rst ============================================================================== --- python/branches/trunk-math/Doc/library/ftplib.rst (original) +++ python/branches/trunk-math/Doc/library/ftplib.rst Sun Jan 27 19:55:42 2008 @@ -182,11 +182,12 @@ .. method:: FTP.retrlines(command[, callback]) - Retrieve a file or directory listing in ASCII transfer mode. *command* should be - an appropriate ``RETR`` command (see :meth:`retrbinary`) or a ``LIST`` command - (usually just the string ``'LIST'``). The *callback* function is called for - each line, with the trailing CRLF stripped. The default *callback* prints the - line to ``sys.stdout``. + Retrieve a file or directory listing in ASCII transfer mode. *command* + should be an appropriate ``RETR`` command (see :meth:`retrbinary`) or a + command such as ``LIST``, ``NLST`` or ``MLSD`` (usually just the string + ``'LIST'``). The *callback* function is called for each line, with the + trailing CRLF stripped. The default *callback* prints the line to + ``sys.stdout``. .. method:: FTP.set_pasv(boolean) @@ -196,23 +197,32 @@ it is on by default.) -.. method:: FTP.storbinary(command, file[, blocksize]) +.. method:: FTP.storbinary(command, file[, blocksize, callback]) Store a file in binary transfer mode. *command* should be an appropriate ``STOR`` command: ``"STOR filename"``. *file* is an open file object which is read until EOF using its :meth:`read` method in blocks of size *blocksize* to provide the data to be stored. The *blocksize* argument defaults to 8192. + *callback* is an optional single parameter callable that is called + on each block of data after it is sent. .. versionchanged:: 2.1 default for *blocksize* added. + .. versionchanged:: 2.6 + *callback* parameter added. -.. method:: FTP.storlines(command, file) + +.. method:: FTP.storlines(command, file[, callback]) Store a file in ASCII transfer mode. *command* should be an appropriate ``STOR`` command (see :meth:`storbinary`). Lines are read until EOF from the open file object *file* using its :meth:`readline` method to provide the data to - be stored. + be stored. *callback* is an optional single parameter callable + that is called on each line after it is sent. + + .. versionchanged:: 2.6 + *callback* parameter added. .. method:: FTP.transfercmd(cmd[, rest]) Modified: python/branches/trunk-math/Doc/library/logging.rst ============================================================================== --- python/branches/trunk-math/Doc/library/logging.rst (original) +++ python/branches/trunk-math/Doc/library/logging.rst Sun Jan 27 19:55:42 2008 @@ -1536,12 +1536,13 @@ :class:`StreamHandler`. -.. class:: FileHandler(filename[, mode[, encoding]]) +.. class:: FileHandler(filename[, mode[, encoding[, delay]]]) Returns a new instance of the :class:`FileHandler` class. The specified file is opened and used as the stream for logging. If *mode* is not specified, :const:`'a'` is used. If *encoding* is not *None*, it is used to open the file - with that encoding. By default, the file grows indefinitely. + with that encoding. If *delay* is true, then file opening is deferred until the + first call to :meth:`emit`. By default, the file grows indefinitely. .. method:: FileHandler.close() @@ -1577,12 +1578,13 @@ this value. -.. class:: WatchedFileHandler(filename[,mode[, encoding]]) +.. class:: WatchedFileHandler(filename[,mode[, encoding[, delay]]]) Returns a new instance of the :class:`WatchedFileHandler` class. The specified file is opened and used as the stream for logging. If *mode* is not specified, :const:`'a'` is used. If *encoding* is not *None*, it is used to open the file - with that encoding. By default, the file grows indefinitely. + with that encoding. If *delay* is true, then file opening is deferred until the + first call to :meth:`emit`. By default, the file grows indefinitely. .. method:: WatchedFileHandler.emit(record) @@ -1599,11 +1601,13 @@ module, supports rotation of disk log files. -.. class:: RotatingFileHandler(filename[, mode[, maxBytes[, backupCount]]]) +.. class:: RotatingFileHandler(filename[, mode[, maxBytes[, backupCount[, encoding[, delay]]]]]) Returns a new instance of the :class:`RotatingFileHandler` class. The specified file is opened and used as the stream for logging. If *mode* is not specified, - ``'a'`` is used. By default, the file grows indefinitely. + ``'a'`` is used. If *encoding* is not *None*, it is used to open the file + with that encoding. If *delay* is true, then file opening is deferred until the + first call to :meth:`emit`. By default, the file grows indefinitely. You can use the *maxBytes* and *backupCount* values to allow the file to :dfn:`rollover` at a predetermined size. When the size is about to be exceeded, @@ -1637,7 +1641,7 @@ timed intervals. -.. class:: TimedRotatingFileHandler(filename [,when [,interval [,backupCount]]]) +.. class:: TimedRotatingFileHandler(filename [,when [,interval [,backupCount[, encoding[, delay]]]]]) Returns a new instance of the :class:`TimedRotatingFileHandler` class. The specified file is opened and used as the stream for logging. On rotating it also @@ -2080,7 +2084,13 @@ record is computed using *msg* % *args*. If the formatting string contains ``'(asctime)'``, :meth:`formatTime` is called to format the event time. If there is exception information, it is formatted using :meth:`formatException` and - appended to the message. + appended to the message. Note that the formatted exception information is cached + in attribute *exc_text*. This is useful because the exception information can + be pickled and sent across the wire, but you should be careful if you have more + than one :class:`Formatter` subclass which customizes the formatting of exception + information. In this case, you will have to clear the cached value after a + formatter has done its formatting, so that the next formatter to handle the event + doesn't use the cached value but recalculates it afresh. .. method:: Formatter.formatTime(record[, datefmt]) Modified: python/branches/trunk-math/Doc/library/os.path.rst ============================================================================== --- python/branches/trunk-math/Doc/library/os.path.rst (original) +++ python/branches/trunk-math/Doc/library/os.path.rst Sun Jan 27 19:55:42 2008 @@ -144,7 +144,9 @@ .. function:: isabs(path) - Return ``True`` if *path* is an absolute pathname (begins with a slash). + Return ``True`` if *path* is an absolute pathname. On Unix, that means it + begins with a slash, on Windows that it begins with a (back)slash after chopping + off a potential drive letter. .. function:: isfile(path) Modified: python/branches/trunk-math/Doc/library/struct.rst ============================================================================== --- python/branches/trunk-math/Doc/library/struct.rst (original) +++ python/branches/trunk-math/Doc/library/struct.rst Sun Jan 27 19:55:42 2008 @@ -85,7 +85,7 @@ +--------+-------------------------+--------------------+-------+ | ``i`` | :ctype:`int` | integer | | +--------+-------------------------+--------------------+-------+ -| ``I`` | :ctype:`unsigned int` | long | | +| ``I`` | :ctype:`unsigned int` | integer or long | | +--------+-------------------------+--------------------+-------+ | ``l`` | :ctype:`long` | integer | | +--------+-------------------------+--------------------+-------+ @@ -104,7 +104,7 @@ +--------+-------------------------+--------------------+-------+ | ``p`` | :ctype:`char[]` | string | | +--------+-------------------------+--------------------+-------+ -| ``P`` | :ctype:`void \*` | integer | | +| ``P`` | :ctype:`void \*` | long | | +--------+-------------------------+--------------------+-------+ Notes: Modified: python/branches/trunk-math/Doc/tutorial/inputoutput.rst ============================================================================== --- python/branches/trunk-math/Doc/tutorial/inputoutput.rst (original) +++ python/branches/trunk-math/Doc/tutorial/inputoutput.rst Sun Jan 27 19:55:42 2008 @@ -200,7 +200,8 @@ written. This behind-the-scenes modification to file data is fine for ASCII text files, but it'll corrupt binary data like that in :file:`JPEG` or :file:`EXE` files. Be very careful to use binary mode when reading and writing -such files. +such files. On Unix, it doesn't hurt to append a ``'b'`` to the mode, so +you can use it platform-independently for all binary files. .. _tut-filemethods: Modified: python/branches/trunk-math/Doc/tutorial/stdlib2.rst ============================================================================== --- python/branches/trunk-math/Doc/tutorial/stdlib2.rst (original) +++ python/branches/trunk-math/Doc/tutorial/stdlib2.rst Sun Jan 27 19:55:42 2008 @@ -134,8 +134,10 @@ The :mod:`struct` module provides :func:`pack` and :func:`unpack` functions for working with variable length binary record formats. The following example shows -how to loop through header information in a ZIP file (with pack codes ``"H"`` -and ``"L"`` representing two and four byte unsigned numbers respectively):: +how to loop through header information in a ZIP file without using the +:mod:`zipfile` module. Pack codes ``"H"`` and ``"I"`` represent two and four +byte unsigned numbers respectively. The ``"<"`` indicates that they are +standard size and in little-endian byte order:: import struct @@ -143,7 +145,7 @@ start = 0 for i in range(3): # show the first 3 file headers start += 14 - fields = struct.unpack('LLLHH', data[start:start+16]) + fields = struct.unpack(' + /* Unicode implementation based on original code by Fredrik Lundh, @@ -183,6 +185,10 @@ # define PyUnicode_FromObject PyUnicodeUCS2_FromObject # define PyUnicode_FromOrdinal PyUnicodeUCS2_FromOrdinal # define PyUnicode_FromUnicode PyUnicodeUCS2_FromUnicode +# define PyUnicode_FromString PyUnicodeUCS2_FromString +# define PyUnicode_FromStringAndSize PyUnicodeUCS2_FromStringAndSize +# define PyUnicode_FromFormatV PyUnicodeUCS2_FromFormatV +# define PyUnicode_FromFormat PyUnicodeUCS2_FromFormat # define PyUnicode_FromWideChar PyUnicodeUCS2_FromWideChar # define PyUnicode_GetDefaultEncoding PyUnicodeUCS2_GetDefaultEncoding # define PyUnicode_GetMax PyUnicodeUCS2_GetMax @@ -265,6 +271,10 @@ # define PyUnicode_FromObject PyUnicodeUCS4_FromObject # define PyUnicode_FromOrdinal PyUnicodeUCS4_FromOrdinal # define PyUnicode_FromUnicode PyUnicodeUCS4_FromUnicode +# define PyUnicode_FromString PyUnicodeUCS4_FromString +# define PyUnicode_FromStringAndSize PyUnicodeUCS4_FromStringAndSize +# define PyUnicode_FromFormatV PyUnicodeUCS4_FromFormatV +# define PyUnicode_FromFormat PyUnicodeUCS4_FromFormat # define PyUnicode_FromWideChar PyUnicodeUCS4_FromWideChar # define PyUnicode_GetDefaultEncoding PyUnicodeUCS4_GetDefaultEncoding # define PyUnicode_GetMax PyUnicodeUCS4_GetMax @@ -442,6 +452,18 @@ Py_ssize_t size /* size of buffer */ ); +/* Similar to PyUnicode_FromUnicode(), but u points to Latin-1 encoded bytes */ +PyAPI_FUNC(PyObject*) PyUnicode_FromStringAndSize( + const char *u, /* char buffer */ + Py_ssize_t size /* size of buffer */ + ); + +/* Similar to PyUnicode_FromUnicode(), but u points to null-terminated + Latin-1 encoded bytes */ +PyAPI_FUNC(PyObject*) PyUnicode_FromString( + const char *u /* string */ + ); + /* Return a read-only pointer to the Unicode object's internal Py_UNICODE buffer. */ @@ -517,6 +539,9 @@ register PyObject *obj /* Object */ ); +PyAPI_FUNC(PyObject *) PyUnicode_FromFormatV(const char*, va_list); +PyAPI_FUNC(PyObject *) PyUnicode_FromFormat(const char*, ...); + /* --- wchar_t support for platforms which support it --------------------- */ #ifdef HAVE_WCHAR_H Modified: python/branches/trunk-math/Lib/bsddb/test/test_associate.py ============================================================================== --- python/branches/trunk-math/Lib/bsddb/test/test_associate.py (original) +++ python/branches/trunk-math/Lib/bsddb/test/test_associate.py Sun Jan 27 19:55:42 2008 @@ -151,7 +151,7 @@ def setUp(self): self.filename = self.__class__.__name__ + '.db' - homeDir = os.path.join(os.path.dirname(sys.argv[0]), 'db_home') + homeDir = os.path.join(tempfile.gettempdir(), 'db_home') self.homeDir = homeDir try: os.mkdir(homeDir) Modified: python/branches/trunk-math/Lib/bsddb/test/test_compare.py ============================================================================== --- python/branches/trunk-math/Lib/bsddb/test/test_compare.py (original) +++ python/branches/trunk-math/Lib/bsddb/test/test_compare.py Sun Jan 27 19:55:42 2008 @@ -4,6 +4,7 @@ import sys, os, re import test_all +import tempfile from cStringIO import StringIO import unittest @@ -51,7 +52,7 @@ def setUp (self): self.filename = self.__class__.__name__ + '.db' - homeDir = os.path.join (os.path.dirname (sys.argv[0]), 'db_home') + homeDir = os.path.join (tempfile.gettempdir(), 'db_home') self.homeDir = homeDir try: os.mkdir (homeDir) Modified: python/branches/trunk-math/Lib/bsddb/test/test_cursor_pget_bug.py ============================================================================== --- python/branches/trunk-math/Lib/bsddb/test/test_cursor_pget_bug.py (original) +++ python/branches/trunk-math/Lib/bsddb/test/test_cursor_pget_bug.py Sun Jan 27 19:55:42 2008 @@ -1,4 +1,5 @@ import unittest +import tempfile import sys, os, glob try: @@ -16,7 +17,7 @@ db_name = 'test-cursor_pget.db' def setUp(self): - self.homeDir = os.path.join(os.path.dirname(sys.argv[0]), 'db_home') + self.homeDir = os.path.join(tempfile.gettempdir(), 'db_home') try: os.mkdir(self.homeDir) except os.error: Modified: python/branches/trunk-math/Lib/bsddb/test/test_pickle.py ============================================================================== --- python/branches/trunk-math/Lib/bsddb/test/test_pickle.py (original) +++ python/branches/trunk-math/Lib/bsddb/test/test_pickle.py Sun Jan 27 19:55:42 2008 @@ -6,6 +6,7 @@ except ImportError: cPickle = None import unittest +import tempfile import glob try: @@ -24,7 +25,7 @@ db_name = 'test-dbobj.db' def setUp(self): - homeDir = os.path.join(os.path.dirname(sys.argv[0]), 'db_home') + homeDir = os.path.join(tempfile.gettempdir(), 'db_home') self.homeDir = homeDir try: os.mkdir(homeDir) except os.error: pass Modified: python/branches/trunk-math/Lib/bsddb/test/test_sequence.py ============================================================================== --- python/branches/trunk-math/Lib/bsddb/test/test_sequence.py (original) +++ python/branches/trunk-math/Lib/bsddb/test/test_sequence.py Sun Jan 27 19:55:42 2008 @@ -16,7 +16,7 @@ class DBSequenceTest(unittest.TestCase): def setUp(self): self.int_32_max = 0x100000000 - self.homeDir = os.path.join(os.path.dirname(sys.argv[0]), 'db_home') + self.homeDir = os.path.join(tempfile.gettempdir(), 'db_home') try: os.mkdir(self.homeDir) except os.error: Modified: python/branches/trunk-math/Lib/bsddb/test/test_thread.py ============================================================================== --- python/branches/trunk-math/Lib/bsddb/test/test_thread.py (original) +++ python/branches/trunk-math/Lib/bsddb/test/test_thread.py Sun Jan 27 19:55:42 2008 @@ -58,7 +58,7 @@ try: os.mkdir(homeDir) except OSError, e: - if e.errno <> errno.EEXIST: raise + if e.errno != errno.EEXIST: raise self.env = db.DBEnv() self.setEnvOpts() self.env.open(homeDir, self.envflags | db.DB_CREATE) @@ -72,7 +72,10 @@ def tearDown(self): self.d.close() self.env.close() - shutil.rmtree(self.homeDir) + try: + shutil.rmtree(self.homeDir) + except OSError, e: + if e.errno != errno.EEXIST: raise def setEnvOpts(self): pass Modified: python/branches/trunk-math/Lib/ctypes/test/test_numbers.py ============================================================================== --- python/branches/trunk-math/Lib/ctypes/test/test_numbers.py (original) +++ python/branches/trunk-math/Lib/ctypes/test/test_numbers.py Sun Jan 27 19:55:42 2008 @@ -105,15 +105,31 @@ def test_floats(self): # c_float and c_double can be created from # Python int, long and float + class FloatLike(object): + def __float__(self): + return 2.0 + f = FloatLike() for t in float_types: self.failUnlessEqual(t(2.0).value, 2.0) self.failUnlessEqual(t(2).value, 2.0) self.failUnlessEqual(t(2L).value, 2.0) + self.failUnlessEqual(t(f).value, 2.0) def test_integers(self): - # integers cannot be constructed from floats + class FloatLike(object): + def __float__(self): + return 2.0 + f = FloatLike() + class IntLike(object): + def __int__(self): + return 2 + i = IntLike() + # integers cannot be constructed from floats, + # but from integer-like objects for t in signed_types + unsigned_types: self.assertRaises(TypeError, t, 3.14) + self.assertRaises(TypeError, t, f) + self.failUnlessEqual(t(i).value, 2) def test_sizes(self): for t in signed_types + unsigned_types + float_types + bool_types: Modified: python/branches/trunk-math/Lib/decimal.py ============================================================================== --- python/branches/trunk-math/Lib/decimal.py (original) +++ python/branches/trunk-math/Lib/decimal.py Sun Jan 27 19:55:42 2008 @@ -1433,6 +1433,8 @@ else: return s*int(self._int[:self._exp] or '0') + __trunc__ = __int__ + def __long__(self): """Converts to a long. Modified: python/branches/trunk-math/Lib/encodings/__init__.py ============================================================================== --- python/branches/trunk-math/Lib/encodings/__init__.py (original) +++ python/branches/trunk-math/Lib/encodings/__init__.py Sun Jan 27 19:55:42 2008 @@ -30,6 +30,7 @@ import codecs from encodings import aliases +import __builtin__ _cache = {} _unknown = '--unknown--' @@ -60,7 +61,7 @@ """ # Make sure we have an 8-bit string, because .translate() works # differently for Unicode strings. - if isinstance(encoding, unicode): + if hasattr(__builtin__, "unicode") and isinstance(encoding, unicode): # Note that .encode('latin-1') does *not* use the codec # registry, so this call doesn't recurse. (See unicodeobject.c # PyUnicode_AsEncodedString() for details) Modified: python/branches/trunk-math/Lib/idlelib/NEWS.txt ============================================================================== --- python/branches/trunk-math/Lib/idlelib/NEWS.txt (original) +++ python/branches/trunk-math/Lib/idlelib/NEWS.txt Sun Jan 27 19:55:42 2008 @@ -1,7 +1,12 @@ What's New in IDLE 2.6a1? ========================= -*Release date: XX-XXX-200X* +*Release date: XX-XXX-2008* + +- There was an error on exit if no sys.exitfunc was defined. Issue 1647. + +- Could not open files in .idlerc directory if latter was hidden on Windows. + Issue 1743, Issue 1862. - Configure Dialog: improved layout for keybinding. Patch 1457 Tal Einat. Modified: python/branches/trunk-math/Lib/idlelib/configHandler.py ============================================================================== --- python/branches/trunk-math/Lib/idlelib/configHandler.py (original) +++ python/branches/trunk-math/Lib/idlelib/configHandler.py Sun Jan 27 19:55:42 2008 @@ -139,7 +139,12 @@ """ if not self.IsEmpty(): - cfgFile=open(self.file,'w') + fname = self.file + try: + cfgFile = open(fname, 'w') + except IOError: + fname.unlink() + cfgFile = open(fname, 'w') self.write(cfgFile) else: self.RemoveFile() Modified: python/branches/trunk-math/Lib/idlelib/run.py ============================================================================== --- python/branches/trunk-math/Lib/idlelib/run.py (original) +++ python/branches/trunk-math/Lib/idlelib/run.py Sun Jan 27 19:55:42 2008 @@ -206,7 +206,10 @@ """ if no_exitfunc: - del sys.exitfunc + try: + del sys.exitfunc + except AttributeError: + pass sys.exit(0) class MyRPCServer(rpc.RPCServer): Modified: python/branches/trunk-math/Lib/logging/__init__.py ============================================================================== --- python/branches/trunk-math/Lib/logging/__init__.py (original) +++ python/branches/trunk-math/Lib/logging/__init__.py Sun Jan 27 19:55:42 2008 @@ -41,8 +41,8 @@ __author__ = "Vinay Sajip " __status__ = "production" -__version__ = "0.5.0.4" -__date__ = "18 January 2008" +__version__ = "0.5.0.5" +__date__ = "24 January 2008" #--------------------------------------------------------------------------- # Miscellaneous module data @@ -763,7 +763,7 @@ """ A handler class which writes formatted logging records to disk files. """ - def __init__(self, filename, mode='a', encoding=None): + def __init__(self, filename, mode='a', encoding=None, delay=0): """ Open the specified file and use it as the stream for logging. """ @@ -774,8 +774,11 @@ self.baseFilename = os.path.abspath(filename) self.mode = mode self.encoding = encoding - stream = self._open() - StreamHandler.__init__(self, stream) + if delay: + self.stream = None + else: + stream = self._open() + StreamHandler.__init__(self, stream) def close(self): """ @@ -798,6 +801,18 @@ stream = codecs.open(self.baseFilename, self.mode, self.encoding) return stream + def emit(self, record): + """ + Emit a record. + + If the stream was not opened because 'delay' was specified in the + constructor, open it before calling the superclass's emit. + """ + if self.stream is None: + stream = self._open() + StreamHandler.__init__(self, stream) + StreamHandler.emit(self, record) + #--------------------------------------------------------------------------- # Manager classes and functions #--------------------------------------------------------------------------- Modified: python/branches/trunk-math/Lib/logging/handlers.py ============================================================================== --- python/branches/trunk-math/Lib/logging/handlers.py (original) +++ python/branches/trunk-math/Lib/logging/handlers.py Sun Jan 27 19:55:42 2008 @@ -53,13 +53,13 @@ Not meant to be instantiated directly. Instead, use RotatingFileHandler or TimedRotatingFileHandler. """ - def __init__(self, filename, mode, encoding=None): + def __init__(self, filename, mode, encoding=None, delay=0): """ Use the specified filename for streamed logging """ if codecs is None: encoding = None - logging.FileHandler.__init__(self, filename, mode, encoding) + logging.FileHandler.__init__(self, filename, mode, encoding, delay) self.mode = mode self.encoding = encoding @@ -84,7 +84,7 @@ Handler for logging to a set of files, which switches from one file to the next when the current file reaches a certain size. """ - def __init__(self, filename, mode='a', maxBytes=0, backupCount=0, encoding=None): + def __init__(self, filename, mode='a', maxBytes=0, backupCount=0, encoding=None, delay=0): """ Open the specified file and use it as the stream for logging. @@ -107,7 +107,7 @@ """ if maxBytes > 0: mode = 'a' # doesn't make sense otherwise! - BaseRotatingHandler.__init__(self, filename, mode, encoding) + BaseRotatingHandler.__init__(self, filename, mode, encoding, delay) self.maxBytes = maxBytes self.backupCount = backupCount @@ -156,8 +156,8 @@ If backupCount is > 0, when rollover is done, no more than backupCount files are kept - the oldest ones are deleted. """ - def __init__(self, filename, when='h', interval=1, backupCount=0, encoding=None): - BaseRotatingHandler.__init__(self, filename, 'a', encoding) + def __init__(self, filename, when='h', interval=1, backupCount=0, encoding=None, delay=0): + BaseRotatingHandler.__init__(self, filename, 'a', encoding, delay) self.when = string.upper(when) self.backupCount = backupCount # Calculate the real rollover interval, which is just the number of @@ -302,10 +302,13 @@ This handler is based on a suggestion and patch by Chad J. Schroeder. """ - def __init__(self, filename, mode='a', encoding=None): - logging.FileHandler.__init__(self, filename, mode, encoding) - stat = os.stat(self.baseFilename) - self.dev, self.ino = stat[ST_DEV], stat[ST_INO] + def __init__(self, filename, mode='a', encoding=None, delay=0): + logging.FileHandler.__init__(self, filename, mode, encoding, delay) + if not os.path.exists(self.baseFilename): + self.dev, self.ino = -1, -1 + else: + stat = os.stat(self.baseFilename) + self.dev, self.ino = stat[ST_DEV], stat[ST_INO] def emit(self, record): """ @@ -321,7 +324,7 @@ else: stat = os.stat(self.baseFilename) changed = (stat[ST_DEV] != self.dev) or (stat[ST_INO] != self.ino) - if changed: + if changed and self.stream is not None: self.stream.flush() self.stream.close() self.stream = self._open() Modified: python/branches/trunk-math/Lib/optparse.py ============================================================================== --- python/branches/trunk-math/Lib/optparse.py (original) +++ python/branches/trunk-math/Lib/optparse.py Sun Jan 27 19:55:42 2008 @@ -824,7 +824,11 @@ (True, False) = (1, 0) def isbasestring(x): - return isinstance(x, types.StringType) or isinstance(x, types.UnicodeType) + try: + return isinstance(x, basestring) + except: + return isinstance(x, types.StringType) or isinstance(x, types.UnicodeType) + class Values: Modified: python/branches/trunk-math/Lib/pprint.py ============================================================================== --- python/branches/trunk-math/Lib/pprint.py (original) +++ python/branches/trunk-math/Lib/pprint.py Sun Jan 27 19:55:42 2008 @@ -167,25 +167,31 @@ (issubclass(typ, set) and r is set.__repr__) or (issubclass(typ, frozenset) and r is frozenset.__repr__) ): + length = _len(object) if issubclass(typ, list): write('[') endchar = ']' elif issubclass(typ, set): + if not length: + write('set()') + return write('set([') endchar = '])' object = sorted(object) indent += 4 elif issubclass(typ, frozenset): + if not length: + write('frozenset()') + return write('frozenset([') endchar = '])' object = sorted(object) - indent += 9 + indent += 10 else: write('(') endchar = ')' if self._indent_per_level > 1: write((self._indent_per_level - 1) * ' ') - length = _len(object) if length: context[objid] = 1 indent = indent + self._indent_per_level Modified: python/branches/trunk-math/Lib/rational.py ============================================================================== --- python/branches/trunk-math/Lib/rational.py (original) +++ python/branches/trunk-math/Lib/rational.py Sun Jan 27 19:55:42 2008 @@ -14,8 +14,8 @@ RationalAbc = numbers.Rational -def _gcd(a, b): - """Calculate the Greatest Common Divisor. +def gcd(a, b): + """Calculate the Greatest Common Divisor of a and b. Unless b==0, the result will have the same sign as b (so that when b is divided by it, the result comes out positive). @@ -40,6 +40,8 @@ >>> _binary_float_to_ratio(-.25) (-1, 4) """ + # XXX Move this to floatobject.c with a name like + # float.as_integer_ratio() if x == 0: return 0, 1 @@ -78,7 +80,8 @@ _RATIONAL_FORMAT = re.compile( - r'^\s*(?P[-+]?)(?P\d+)(?:/(?P\d+))?\s*$') + r'^\s*(?P[-+]?)(?P\d+)' + r'(?:/(?P\d+)|\.(?P\d+))?\s*$') class Rational(RationalAbc): @@ -90,17 +93,18 @@ Rational() == 0. Rationals can also be constructed from strings of the form - '[-+]?[0-9]+(/[0-9]+)?', optionally surrounded by spaces. + '[-+]?[0-9]+((/|.)[0-9]+)?', optionally surrounded by spaces. """ - __slots__ = ('_numerator', '_denominator') + __slots__ = ('numerator', 'denominator') # We're immutable, so use __new__ not __init__ def __new__(cls, numerator=0, denominator=1): """Constructs a Rational. - Takes a string, another Rational, or a numerator/denominator pair. + Takes a string like '3/2' or '1.5', another Rational, or a + numerator/denominator pair. """ self = super(Rational, cls).__new__(cls) @@ -112,9 +116,18 @@ m = _RATIONAL_FORMAT.match(input) if m is None: raise ValueError('Invalid literal for Rational: ' + input) - numerator = int(m.group('num')) - # Default denominator to 1. That's the only optional group. - denominator = int(m.group('denom') or 1) + numerator = m.group('num') + decimal = m.group('decimal') + if decimal: + # The literal is a decimal number. + numerator = int(numerator + decimal) + denominator = 10**len(decimal) + else: + # The literal is an integer or fraction. + numerator = int(numerator) + # Default denominator to 1. + denominator = int(m.group('denom') or 1) + if m.group('sign') == '-': numerator = -numerator @@ -133,9 +146,9 @@ if denominator == 0: raise ZeroDivisionError('Rational(%s, 0)' % numerator) - g = _gcd(numerator, denominator) - self._numerator = int(numerator // g) - self._denominator = int(denominator // g) + g = gcd(numerator, denominator) + self.numerator = int(numerator // g) + self.denominator = int(denominator // g) return self @classmethod @@ -172,13 +185,42 @@ else: return cls(digits, 10 ** -exp) - @property - def numerator(a): - return a._numerator - - @property - def denominator(a): - return a._denominator + @classmethod + def from_continued_fraction(cls, seq): + 'Build a Rational from a continued fraction expessed as a sequence' + n, d = 1, 0 + for e in reversed(seq): + n, d = d, n + n += e * d + return cls(n, d) if seq else cls(0) + + def as_continued_fraction(self): + 'Return continued fraction expressed as a list' + n = self.numerator + d = self.denominator + cf = [] + while d: + e = int(n // d) + cf.append(e) + n -= e * d + n, d = d, n + return cf + + def approximate(self, max_denominator): + 'Best rational approximation with a denominator <= max_denominator' + # XXX First cut at algorithm + # Still needs rounding rules as specified at + # http://en.wikipedia.org/wiki/Continued_fraction + if self.denominator <= max_denominator: + return self + cf = self.as_continued_fraction() + result = Rational(0) + for i in range(1, len(cf)): + new = self.from_continued_fraction(cf[:i]) + if new.denominator > max_denominator: + break + result = new + return result def __repr__(self): """repr(self)""" @@ -191,6 +233,16 @@ else: return '%s/%s' % (self.numerator, self.denominator) + """ XXX This section needs a lot more commentary + + * Explain the typical sequence of checks, calls, and fallbacks. + * Explain the subtle reasons why this logic was needed. + * It is not clear how common cases are handled (for example, how + does the ratio of two huge integers get converted to a float + without overflowing the long-->float conversion. + + """ + def _operator_fallbacks(monomorphic_operator, fallback_operator): """Generates forward and reverse operators given a purely-rational operator and a function from the operator module. @@ -257,8 +309,9 @@ __truediv__, __rtruediv__ = _operator_fallbacks(_div, operator.truediv) __div__, __rdiv__ = _operator_fallbacks(_div, operator.div) - @classmethod - def _floordiv(cls, a, b): + def __floordiv__(a, b): + """a // b""" + # Will be math.floor(a / b) in 3.0. div = a / b if isinstance(div, RationalAbc): # trunc(math.floor(div)) doesn't work if the rational is @@ -268,28 +321,27 @@ else: return math.floor(div) - def __floordiv__(a, b): - """a // b""" - # Will be math.floor(a / b) in 3.0. - return a._floordiv(a, b) - def __rfloordiv__(b, a): """a // b""" # Will be math.floor(a / b) in 3.0. - return b._floordiv(a, b) - - @classmethod - def _mod(cls, a, b): - div = a // b - return a - b * div + div = a / b + if isinstance(div, RationalAbc): + # trunc(math.floor(div)) doesn't work if the rational is + # more precise than a float because the intermediate + # rounding may cross an integer boundary. + return div.numerator // div.denominator + else: + return math.floor(div) def __mod__(a, b): """a % b""" - return a._mod(a, b) + div = a // b + return a - b * div def __rmod__(b, a): """a % b""" - return b._mod(a, b) + div = a // b + return a - b * div def __pow__(a, b): """a ** b @@ -348,6 +400,8 @@ else: return a.numerator // a.denominator + __int__ = __trunc__ + def __floor__(a): """Will be math.floor(a) in 3.0.""" return a.numerator // a.denominator @@ -389,6 +443,7 @@ float must have the same hash as that float. """ + # XXX since this method is expensive, consider caching the result if self.denominator == 1: # Get integers right. return hash(self.numerator) @@ -460,3 +515,18 @@ def __nonzero__(a): """a != 0""" return a.numerator != 0 + + # support for pickling, copy, and deepcopy + + def __reduce__(self): + return (self.__class__, (str(self),)) + + def __copy__(self): + if type(self) == Rational: + return self # I'm immutable; therefore I am my own clone + return self.__class__(self.numerator, self.denominator) + + def __deepcopy__(self, memo): + if type(self) == Rational: + return self # My components are also immutable + return self.__class__(self.numerator, self.denominator) Modified: python/branches/trunk-math/Lib/re.py ============================================================================== --- python/branches/trunk-math/Lib/re.py (original) +++ python/branches/trunk-math/Lib/re.py Sun Jan 27 19:55:42 2008 @@ -38,7 +38,7 @@ *?,+?,?? Non-greedy versions of the previous three special characters. {m,n} Matches from m to n repetitions of the preceding RE. {m,n}? Non-greedy version of the above. - "\\" Either escapes special characters or signals a special sequence. + "\\" Either escapes special characters or signals a special sequence. [] Indicates a set of characters. A "^" as the first character indicates a complementing set. "|" A|B, creates an RE that will match either A or B. @@ -51,6 +51,10 @@ (?#...) A comment; ignored. (?=...) Matches if ... matches next, but doesn't consume the string. (?!...) Matches if ... doesn't match next. + (?<=...) Matches if preceded by ... (must be fixed length). + (?tp_as_sequence->sq_slice instead of # tp->tp_as_sequence->sq_ass_slice + if verbose: + print "Testing assign_slice..." class C(object): def __setslice__(self, start, stop, value): @@ -4436,6 +4440,93 @@ c[1:2] = 3 vereq(c.value, 3) +def test_weakref_in_del_segfault(): + # This used to segfault until r60057 + if verbose: + print "Testing weakref in del segfault..." + + import weakref + global ref + + class Target(): + def __del__(self): + global ref + ref = weakref.ref(self) + + w = Target() + del w + del ref + +def test_borrowed_ref_3_segfault(): + # This used to segfault until r60224 + if verbose: + print "Testing borrowed ref 3 segfault..." + + class KeyFunc(object): + def __call__(self, n): + del d['key'] + return 1 + + d = {'key': KeyFunc()} + try: + min(range(10), **d) + except: + pass + +def test_borrowed_ref_4_segfault(): + # This used to segfault until r60224 + if verbose: + print "Testing borrowed ref 4 segfault..." + + import types + import __builtin__ + + class X(object): + def __getattr__(self, name): + # this is called with name == '__bases__' by PyObject_IsInstance() + # during the unbound method call -- it frees the unbound method + # itself before it invokes its im_func. + del __builtin__.__import__ + return () + + pseudoclass = X() + + class Y(object): + def __call__(self, *args): + # 'self' was freed already + return (self, args) + + # make an unbound method + orig_import = __import__ + try: + __builtin__.__import__ = types.MethodType(Y(), None, (pseudoclass, str)) + import spam + finally: + __builtin__.__import__ = orig_import + +def test_losing_dict_ref_segfault(): + # This used to segfault; + # derived from issue #1303614, test67.py + if verbose: + print "Testing losing dict ref segfault..." + + class Strange(object): + def __hash__(self): + return hash('hello') + + def __eq__(self, other): + x.__dict__ = {} # the old x.__dict__ is deallocated + return False + + class X(object): + pass + + v = 123 + x = X() + x.__dict__ = {Strange(): 42, 'hello': v+456} + x.hello + + def test_main(): weakref_segfault() # Must be first, somehow wrapper_segfault() @@ -4535,6 +4626,10 @@ methodwrapper() notimplemented() test_assign_slice() + test_weakref_in_del_segfault() + test_borrowed_ref_3_segfault() + test_borrowed_ref_4_segfault() + test_losing_dict_ref_segfault() if verbose: print "All OK" Modified: python/branches/trunk-math/Lib/test/test_dict.py ============================================================================== --- python/branches/trunk-math/Lib/test/test_dict.py (original) +++ python/branches/trunk-math/Lib/test/test_dict.py Sun Jan 27 19:55:42 2008 @@ -200,14 +200,6 @@ self.assertRaises(ValueError, {}.update, [(1, 2, 3)]) - # SF #1615701: make d.update(m) honor __getitem__() and keys() in dict subclasses - class KeyUpperDict(dict): - def __getitem__(self, key): - return key.upper() - d.clear() - d.update(KeyUpperDict.fromkeys('abc')) - self.assertEqual(d, {'a':'A', 'b':'B', 'c':'C'}) - def test_fromkeys(self): self.assertEqual(dict.fromkeys('abc'), {'a':None, 'b':None, 'c':None}) d = {} Modified: python/branches/trunk-math/Lib/test/test_generators.py ============================================================================== --- python/branches/trunk-math/Lib/test/test_generators.py (original) +++ python/branches/trunk-math/Lib/test/test_generators.py Sun Jan 27 19:55:42 2008 @@ -382,7 +382,7 @@ >>> type(i) >>> [s for s in dir(i) if not s.startswith('_')] -['close', 'gi_frame', 'gi_running', 'next', 'send', 'throw'] +['close', 'gi_code', 'gi_frame', 'gi_running', 'next', 'send', 'throw'] >>> print i.next.__doc__ x.next() -> the next value, or raise StopIteration >>> iter(i) is i @@ -899,6 +899,24 @@ >>> print g.next() Traceback (most recent call last): StopIteration + + +Test the gi_code attribute + +>>> def f(): +... yield 5 +... +>>> g = f() +>>> g.gi_code is f.func_code +True +>>> g.next() +5 +>>> g.next() +Traceback (most recent call last): +StopIteration +>>> g.gi_code is f.func_code +True + """ # conjoin is a simple backtracking generator, named in honor of Icon's Modified: python/branches/trunk-math/Lib/test/test_grammar.py ============================================================================== --- python/branches/trunk-math/Lib/test/test_grammar.py (original) +++ python/branches/trunk-math/Lib/test/test_grammar.py Sun Jan 27 19:55:42 2008 @@ -572,6 +572,15 @@ while 0: pass else: pass + # Issue1920: "while 0" is optimized away, + # ensure that the "else" clause is still present. + x = 0 + while 0: + x = 1 + else: + x = 2 + self.assertEquals(x, 2) + def testFor(self): # 'for' exprlist 'in' exprlist ':' suite ['else' ':' suite] for i in 1, 2, 3: pass Modified: python/branches/trunk-math/Lib/test/test_largefile.py ============================================================================== --- python/branches/trunk-math/Lib/test/test_largefile.py (original) +++ python/branches/trunk-math/Lib/test/test_largefile.py Sun Jan 27 19:55:42 2008 @@ -6,7 +6,7 @@ #---------------------------------------------------------------------- from test import test_support -import os, struct, stat, sys +import os, stat, sys try: import signal Modified: python/branches/trunk-math/Lib/test/test_pprint.py ============================================================================== --- python/branches/trunk-math/Lib/test/test_pprint.py (original) +++ python/branches/trunk-math/Lib/test/test_pprint.py Sun Jan 27 19:55:42 2008 @@ -1,6 +1,7 @@ import pprint import test.test_support import unittest +import test.test_set try: uni = unicode @@ -195,6 +196,197 @@ others.should.not.be: like.this}""" self.assertEqual(DottedPrettyPrinter().pformat(o), exp) + def test_set_reprs(self): + self.assertEqual(pprint.pformat(set()), 'set()') + self.assertEqual(pprint.pformat(set(range(3))), 'set([0, 1, 2])') + self.assertEqual(pprint.pformat(frozenset()), 'frozenset()') + self.assertEqual(pprint.pformat(frozenset(range(3))), 'frozenset([0, 1, 2])') + cube_repr_tgt = """\ +{frozenset([]): frozenset([frozenset([2]), frozenset([0]), frozenset([1])]), + frozenset([0]): frozenset([frozenset(), + frozenset([0, 2]), + frozenset([0, 1])]), + frozenset([1]): frozenset([frozenset(), + frozenset([1, 2]), + frozenset([0, 1])]), + frozenset([2]): frozenset([frozenset(), + frozenset([1, 2]), + frozenset([0, 2])]), + frozenset([1, 2]): frozenset([frozenset([2]), + frozenset([1]), + frozenset([0, 1, 2])]), + frozenset([0, 2]): frozenset([frozenset([2]), + frozenset([0]), + frozenset([0, 1, 2])]), + frozenset([0, 1]): frozenset([frozenset([0]), + frozenset([1]), + frozenset([0, 1, 2])]), + frozenset([0, 1, 2]): frozenset([frozenset([1, 2]), + frozenset([0, 2]), + frozenset([0, 1])])}""" + cube = test.test_set.cube(3) + self.assertEqual(pprint.pformat(cube), cube_repr_tgt) + cubo_repr_tgt = """\ +{frozenset([frozenset([0, 2]), frozenset([0])]): frozenset([frozenset([frozenset([0, + 2]), + frozenset([0, + 1, + 2])]), + frozenset([frozenset([0]), + frozenset([0, + 1])]), + frozenset([frozenset(), + frozenset([0])]), + frozenset([frozenset([2]), + frozenset([0, + 2])])]), + frozenset([frozenset([0, 1]), frozenset([1])]): frozenset([frozenset([frozenset([0, + 1]), + frozenset([0, + 1, + 2])]), + frozenset([frozenset([0]), + frozenset([0, + 1])]), + frozenset([frozenset([1]), + frozenset([1, + 2])]), + frozenset([frozenset(), + frozenset([1])])]), + frozenset([frozenset([1, 2]), frozenset([1])]): frozenset([frozenset([frozenset([1, + 2]), + frozenset([0, + 1, + 2])]), + frozenset([frozenset([2]), + frozenset([1, + 2])]), + frozenset([frozenset(), + frozenset([1])]), + frozenset([frozenset([1]), + frozenset([0, + 1])])]), + frozenset([frozenset([1, 2]), frozenset([2])]): frozenset([frozenset([frozenset([1, + 2]), + frozenset([0, + 1, + 2])]), + frozenset([frozenset([1]), + frozenset([1, + 2])]), + frozenset([frozenset([2]), + frozenset([0, + 2])]), + frozenset([frozenset(), + frozenset([2])])]), + frozenset([frozenset([]), frozenset([0])]): frozenset([frozenset([frozenset([0]), + frozenset([0, + 1])]), + frozenset([frozenset([0]), + frozenset([0, + 2])]), + frozenset([frozenset(), + frozenset([1])]), + frozenset([frozenset(), + frozenset([2])])]), + frozenset([frozenset([]), frozenset([1])]): frozenset([frozenset([frozenset(), + frozenset([0])]), + frozenset([frozenset([1]), + frozenset([1, + 2])]), + frozenset([frozenset(), + frozenset([2])]), + frozenset([frozenset([1]), + frozenset([0, + 1])])]), + frozenset([frozenset([2]), frozenset([])]): frozenset([frozenset([frozenset([2]), + frozenset([1, + 2])]), + frozenset([frozenset(), + frozenset([0])]), + frozenset([frozenset(), + frozenset([1])]), + frozenset([frozenset([2]), + frozenset([0, + 2])])]), + frozenset([frozenset([0, 1, 2]), frozenset([0, 1])]): frozenset([frozenset([frozenset([1, + 2]), + frozenset([0, + 1, + 2])]), + frozenset([frozenset([0, + 2]), + frozenset([0, + 1, + 2])]), + frozenset([frozenset([0]), + frozenset([0, + 1])]), + frozenset([frozenset([1]), + frozenset([0, + 1])])]), + frozenset([frozenset([0]), frozenset([0, 1])]): frozenset([frozenset([frozenset(), + frozenset([0])]), + frozenset([frozenset([0, + 1]), + frozenset([0, + 1, + 2])]), + frozenset([frozenset([0]), + frozenset([0, + 2])]), + frozenset([frozenset([1]), + frozenset([0, + 1])])]), + frozenset([frozenset([2]), frozenset([0, 2])]): frozenset([frozenset([frozenset([0, + 2]), + frozenset([0, + 1, + 2])]), + frozenset([frozenset([2]), + frozenset([1, + 2])]), + frozenset([frozenset([0]), + frozenset([0, + 2])]), + frozenset([frozenset(), + frozenset([2])])]), + frozenset([frozenset([0, 1, 2]), frozenset([0, 2])]): frozenset([frozenset([frozenset([1, + 2]), + frozenset([0, + 1, + 2])]), + frozenset([frozenset([0, + 1]), + frozenset([0, + 1, + 2])]), + frozenset([frozenset([0]), + frozenset([0, + 2])]), + frozenset([frozenset([2]), + frozenset([0, + 2])])]), + frozenset([frozenset([1, 2]), frozenset([0, 1, 2])]): frozenset([frozenset([frozenset([0, + 2]), + frozenset([0, + 1, + 2])]), + frozenset([frozenset([0, + 1]), + frozenset([0, + 1, + 2])]), + frozenset([frozenset([2]), + frozenset([1, + 2])]), + frozenset([frozenset([1]), + frozenset([1, + 2])])])}""" + + cubo = test.test_set.linegraph(cube) + self.assertEqual(pprint.pformat(cubo), cubo_repr_tgt) + class DottedPrettyPrinter(pprint.PrettyPrinter): Modified: python/branches/trunk-math/Lib/test/test_rational.py ============================================================================== --- python/branches/trunk-math/Lib/test/test_rational.py (original) +++ python/branches/trunk-math/Lib/test/test_rational.py Sun Jan 27 19:55:42 2008 @@ -6,11 +6,31 @@ import operator import rational import unittest +from copy import copy, deepcopy +from cPickle import dumps, loads R = rational.Rational +gcd = rational.gcd + + +class GcdTest(unittest.TestCase): + + def testMisc(self): + self.assertEquals(0, gcd(0, 0)) + self.assertEquals(1, gcd(1, 0)) + self.assertEquals(-1, gcd(-1, 0)) + self.assertEquals(1, gcd(0, 1)) + self.assertEquals(-1, gcd(0, -1)) + self.assertEquals(1, gcd(7, 1)) + self.assertEquals(-1, gcd(7, -1)) + self.assertEquals(1, gcd(-23, 15)) + self.assertEquals(12, gcd(120, 84)) + self.assertEquals(-12, gcd(84, -120)) + def _components(r): return (r.numerator, r.denominator) + class RationalTest(unittest.TestCase): def assertTypedEquals(self, expected, actual): @@ -53,8 +73,12 @@ self.assertEquals((3, 2), _components(R("3/2"))) self.assertEquals((3, 2), _components(R(" \n +3/2"))) self.assertEquals((-3, 2), _components(R("-3/2 "))) - self.assertEquals((3, 2), _components(R(" 03/02 \n "))) - self.assertEquals((3, 2), _components(R(u" 03/02 \n "))) + self.assertEquals((13, 2), _components(R(" 013/02 \n "))) + self.assertEquals((13, 2), _components(R(u" 013/02 \n "))) + + self.assertEquals((16, 5), _components(R(" 3.2 "))) + self.assertEquals((-16, 5), _components(R(u" -3.2 "))) + self.assertRaisesMessage( ZeroDivisionError, "Rational(3, 0)", @@ -74,9 +98,21 @@ ValueError, "Invalid literal for Rational: + 3/2", R, "+ 3/2") self.assertRaisesMessage( - # Only parse fractions, not decimals. - ValueError, "Invalid literal for Rational: 3.2", - R, "3.2") + # Avoid treating '.' as a regex special character. + ValueError, "Invalid literal for Rational: 3a2", + R, "3a2") + self.assertRaisesMessage( + # Only parse ordinary decimals, not scientific form. + ValueError, "Invalid literal for Rational: 3.2e4", + R, "3.2e4") + self.assertRaisesMessage( + # Don't accept combinations of decimals and rationals. + ValueError, "Invalid literal for Rational: 3/7.2", + R, "3/7.2") + self.assertRaisesMessage( + # Don't accept combinations of decimals and rationals. + ValueError, "Invalid literal for Rational: 3.2/7", + R, "3.2/7") def testImmutable(self): r = R(7, 3) @@ -135,8 +171,32 @@ TypeError, "Cannot convert sNaN to Rational.", R.from_decimal, Decimal("snan")) + def testFromContinuedFraction(self): + self.assertRaises(TypeError, R.from_continued_fraction, None) + phi = R.from_continued_fraction([1]*100) + self.assertEquals(round(phi - (1 + 5 ** 0.5) / 2, 10), 0.0) + + minusphi = R.from_continued_fraction([-1]*100) + self.assertEquals(round(minusphi + (1 + 5 ** 0.5) / 2, 10), 0.0) + + self.assertEquals(R.from_continued_fraction([0]), R(0)) + self.assertEquals(R.from_continued_fraction([]), R(0)) + + def testAsContinuedFraction(self): + self.assertEqual(R.from_float(math.pi).as_continued_fraction()[:15], + [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 3, 3]) + self.assertEqual(R.from_float(-math.pi).as_continued_fraction()[:16], + [-4, 1, 6, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 3, 3]) + self.assertEqual(R(0).as_continued_fraction(), [0]) + + def testApproximateFrom(self): + self.assertEqual(R.from_float(math.pi).approximate(10000), R(355, 113)) + self.assertEqual(R.from_float(-math.pi).approximate(10000), R(-355, 113)) + self.assertEqual(R.from_float(0.0).approximate(10000), R(0)) + def testConversions(self): self.assertTypedEquals(-1, trunc(R(-11, 10))) + self.assertTypedEquals(-1, int(R(-11, 10))) self.assertTypedEquals(-2, R(-11, 10).__floor__()) self.assertTypedEquals(-1, R(-11, 10).__ceil__()) self.assertTypedEquals(-1, R(-10, 10).__ceil__()) @@ -335,8 +395,14 @@ s += num / fact * sign self.assertAlmostEquals(math.cos(1), s) + def test_copy_deepcopy_pickle(self): + r = R(13, 7) + self.assertEqual(r, loads(dumps(r))) + self.assertEqual(id(r), id(copy(r))) + self.assertEqual(id(r), id(deepcopy(r))) + def test_main(): - run_unittest(RationalTest) + run_unittest(RationalTest, GcdTest) if __name__ == '__main__': test_main() Modified: python/branches/trunk-math/Lib/test/test_resource.py ============================================================================== --- python/branches/trunk-math/Lib/test/test_resource.py (original) +++ python/branches/trunk-math/Lib/test/test_resource.py Sun Jan 27 19:55:42 2008 @@ -1,8 +1,9 @@ import unittest from test import test_support - -import os, resource +import os +import resource +import time # This test is checking a few specific problem spots with the resource module. @@ -15,7 +16,6 @@ self.assertRaises(TypeError, resource.setrlimit, 42, 42, 42) def test_fsize_ismax(self): - try: (cur, max) = resource.getrlimit(resource.RLIMIT_FSIZE) except AttributeError: @@ -54,6 +54,15 @@ try: f.write("Y") f.flush() + # On some systems (e.g., Ubuntu on hppa) the flush() + # doesn't always cause the exception, but the close() + # does eventually. Try closing several times in + # an attempt to ensure the file is really synced and + # the exception raised. + for i in range(5): + time.sleep(.1) + f.flush() + f.close() except IOError: if not limit_set: raise @@ -63,10 +72,10 @@ resource.setrlimit(resource.RLIMIT_FSIZE, (cur, max)) finally: f.close() - os.unlink(test_support.TESTFN) finally: if limit_set: resource.setrlimit(resource.RLIMIT_FSIZE, (cur, max)) + test_support.unlink(test_support.TESTFN) def test_fsize_toobig(self): # Be sure that setrlimit is checking for really large values Modified: python/branches/trunk-math/Lib/test/test_set.py ============================================================================== --- python/branches/trunk-math/Lib/test/test_set.py (original) +++ python/branches/trunk-math/Lib/test/test_set.py Sun Jan 27 19:55:42 2008 @@ -7,6 +7,7 @@ import os from random import randrange, shuffle import sys +import collections class PassThru(Exception): pass @@ -1525,6 +1526,110 @@ self.assertRaises(TypeError, getattr(set('january'), methname), N(data)) self.assertRaises(ZeroDivisionError, getattr(set('january'), methname), E(data)) +# Application tests (based on David Eppstein's graph recipes ==================================== + +def powerset(U): + """Generates all subsets of a set or sequence U.""" + U = iter(U) + try: + x = frozenset([U.next()]) + for S in powerset(U): + yield S + yield S | x + except StopIteration: + yield frozenset() + +def cube(n): + """Graph of n-dimensional hypercube.""" + singletons = [frozenset([x]) for x in range(n)] + return dict([(x, frozenset([x^s for s in singletons])) + for x in powerset(range(n))]) + +def linegraph(G): + """Graph, the vertices of which are edges of G, + with two vertices being adjacent iff the corresponding + edges share a vertex.""" + L = {} + for x in G: + for y in G[x]: + nx = [frozenset([x,z]) for z in G[x] if z != y] + ny = [frozenset([y,z]) for z in G[y] if z != x] + L[frozenset([x,y])] = frozenset(nx+ny) + return L + +def faces(G): + 'Return a set of faces in G. Where a face is a set of vertices on that face' + # currently limited to triangles,squares, and pentagons + f = set() + for v1, edges in G.items(): + for v2 in edges: + for v3 in G[v2]: + if v1 == v3: + continue + if v1 in G[v3]: + f.add(frozenset([v1, v2, v3])) + else: + for v4 in G[v3]: + if v4 == v2: + continue + if v1 in G[v4]: + f.add(frozenset([v1, v2, v3, v4])) + else: + for v5 in G[v4]: + if v5 == v3 or v5 == v2: + continue + if v1 in G[v5]: + f.add(frozenset([v1, v2, v3, v4, v5])) + return f + + +class TestGraphs(unittest.TestCase): + + def test_cube(self): + + g = cube(3) # vert --> {v1, v2, v3} + vertices1 = set(g) + self.assertEqual(len(vertices1), 8) # eight vertices + for edge in g.values(): + self.assertEqual(len(edge), 3) # each vertex connects to three edges + vertices2 = set(v for edges in g.values() for v in edges) + self.assertEqual(vertices1, vertices2) # edge vertices in original set + + cubefaces = faces(g) + self.assertEqual(len(cubefaces), 6) # six faces + for face in cubefaces: + self.assertEqual(len(face), 4) # each face is a square + + def test_cuboctahedron(self): + + # http://en.wikipedia.org/wiki/Cuboctahedron + # 8 triangular faces and 6 square faces + # 12 indentical vertices each connecting a triangle and square + + g = cube(3) + cuboctahedron = linegraph(g) # V( --> {V1, V2, V3, V4} + self.assertEqual(len(cuboctahedron), 12)# twelve vertices + + vertices = set(cuboctahedron) + for edges in cuboctahedron.values(): + self.assertEqual(len(edges), 4) # each vertex connects to four other vertices + othervertices = set(edge for edges in cuboctahedron.values() for edge in edges) + self.assertEqual(vertices, othervertices) # edge vertices in original set + + cubofaces = faces(cuboctahedron) + facesizes = collections.defaultdict(int) + for face in cubofaces: + facesizes[len(face)] += 1 + self.assertEqual(facesizes[3], 8) # eight triangular faces + self.assertEqual(facesizes[4], 6) # six square faces + + for vertex in cuboctahedron: + edge = vertex # Cuboctahedron vertices are edges in Cube + self.assertEqual(len(edge), 2) # Two cube vertices define an edge + for cubevert in edge: + self.assert_(cubevert in g) + + #============================================================================== def test_main(verbose=None): @@ -1562,6 +1667,7 @@ TestCopyingNested, TestIdentities, TestVariousIteratorArgs, + TestGraphs, ) test_support.run_unittest(*test_classes) Modified: python/branches/trunk-math/Lib/test/test_socket_ssl.py ============================================================================== --- python/branches/trunk-math/Lib/test/test_socket_ssl.py (original) +++ python/branches/trunk-math/Lib/test/test_socket_ssl.py Sun Jan 27 19:55:42 2008 @@ -14,8 +14,22 @@ # Optionally test SSL support, if we have it in the tested platform skip_expected = not hasattr(socket, "ssl") + class ConnectedTests(unittest.TestCase): + def urlopen(self, host, *args, **kwargs): + # Connecting to remote hosts is flaky. Make it more robust + # by retrying the connection several times. + for i in range(3): + try: + return urllib.urlopen(host, *args, **kwargs) + except IOError, e: + last_exc = e + continue + except: + raise + raise last_exc + def testBasic(self): socket.RAND_status() try: @@ -27,7 +41,7 @@ socket.RAND_add("this is a random string", 75.0) with test_support.transient_internet(): - f = urllib.urlopen('https://sf.net') + f = self.urlopen('https://sf.net') buf = f.read() f.close() @@ -36,7 +50,7 @@ print >> sys.stderr, """\ WARNING: an attempt to connect to %r %s, in test_timeout. That may be legitimate, but is not the outcome we - hoped for. If this message is seen often, test_timeout should be + hoped for. If this message is seen often, testTimeout should be changed to use a more reliable address.""" % (ADDR, extra_msg) # A service which issues a welcome banner (without need to write @@ -103,6 +117,19 @@ connector() t.join() + def connect(self, s, host_port): + # Connecting to remote hosts is flaky. Make it more robust + # by retrying the connection several times. + for i in range(3): + try: + return s.connect(host_port) + except IOError, e: + last_exc = e + continue + except: + raise + raise last_exc + def test_978833(self): if test_support.verbose: print "test_978833 ..." @@ -110,7 +137,7 @@ import os, httplib, ssl with test_support.transient_internet(): s = socket.socket(socket.AF_INET) - s.connect(("svn.python.org", 443)) + self.connect(s, ("svn.python.org", 443)) fd = s._sock.fileno() sock = ssl.wrap_socket(s) s = None Modified: python/branches/trunk-math/Lib/test/test_telnetlib.py ============================================================================== --- python/branches/trunk-math/Lib/test/test_telnetlib.py (original) +++ python/branches/trunk-math/Lib/test/test_telnetlib.py Sun Jan 27 19:55:42 2008 @@ -13,6 +13,7 @@ serv.setsockopt(socket.SOL_SOCKET, socket.SO_REUSEADDR, 1) serv.bind(("", 9091)) serv.listen(5) + evt.set() try: conn, addr = serv.accept() except socket.timeout: @@ -26,6 +27,8 @@ def setUp(self): self.evt = threading.Event() threading.Thread(target=server, args=(self.evt,)).start() + self.evt.wait() + self.evt.clear() time.sleep(.1) def tearDown(self): Modified: python/branches/trunk-math/Lib/test/test_urllib2net.py ============================================================================== --- python/branches/trunk-math/Lib/test/test_urllib2net.py (original) +++ python/branches/trunk-math/Lib/test/test_urllib2net.py Sun Jan 27 19:55:42 2008 @@ -10,6 +10,20 @@ import os import mimetools + +def _urlopen_with_retry(host, *args, **kwargs): + # Connecting to remote hosts is flaky. Make it more robust + # by retrying the connection several times. + for i in range(3): + try: + return urllib2.urlopen(host, *args, **kwargs) + except urllib2.URLError, last_exc: + continue + except: + raise + raise last_exc + + class URLTimeoutTest(unittest.TestCase): TIMEOUT = 10.0 @@ -21,7 +35,7 @@ socket.setdefaulttimeout(None) def testURLread(self): - f = urllib2.urlopen("http://www.python.org/") + f = _urlopen_with_retry("http://www.python.org/") x = f.read() @@ -42,7 +56,7 @@ # # # failure # try: -# urllib2.urlopen(test_url) +# _urlopen_with_retry(test_url) # except urllib2.HTTPError, exc: # self.assertEqual(exc.code, 401) # else: @@ -54,7 +68,7 @@ # test_user, test_password) # opener = urllib2.build_opener(auth_handler) # f = opener.open('http://localhost/') -# response = urllib2.urlopen("http://www.python.org/") +# response = _urlopen_with_retry("http://www.python.org/") # # # The 'userinfo' URL component is deprecated by RFC 3986 for security # # reasons, let's not implement it! (it's already implemented for proxy @@ -73,7 +87,7 @@ # underlying socket # delve deep into response to fetch socket._socketobject - response = urllib2.urlopen("http://www.python.org/") + response = _urlopen_with_retry("http://www.python.org/") abused_fileobject = response.fp self.assert_(abused_fileobject.__class__ is socket._fileobject) httpresponse = abused_fileobject._sock @@ -102,7 +116,7 @@ def test_basic(self): # Simple test expected to pass. - open_url = urllib2.urlopen("http://www.python.org/") + open_url = _urlopen_with_retry("http://www.python.org/") for attr in ("read", "close", "info", "geturl"): self.assert_(hasattr(open_url, attr), "object returned from " "urlopen lacks the %s attribute" % attr) @@ -113,7 +127,7 @@ def test_info(self): # Test 'info'. - open_url = urllib2.urlopen("http://www.python.org/") + open_url = _urlopen_with_retry("http://www.python.org/") try: info_obj = open_url.info() finally: @@ -126,7 +140,7 @@ def test_geturl(self): # Make sure same URL as opened is returned by geturl. URL = "http://www.python.org/" - open_url = urllib2.urlopen(URL) + open_url = _urlopen_with_retry(URL) try: gotten_url = open_url.geturl() finally: @@ -157,7 +171,7 @@ def test_range (self): req = urllib2.Request("http://www.python.org", headers={'Range': 'bytes=20-39'}) - result = urllib2.urlopen(req) + result = _urlopen_with_retry(req) data = result.read() self.assertEqual(len(data), 20) @@ -184,7 +198,7 @@ 'file:'+sanepathname2url(os.path.abspath(TESTFN)), ('file:///nonsensename/etc/passwd', None, urllib2.URLError), ] - self._test_urls(urls, self._extra_handlers()) + self._test_urls(urls, self._extra_handlers(), urllib2.urlopen) finally: os.remove(TESTFN) @@ -226,7 +240,7 @@ ## self._test_urls(urls, self._extra_handlers()+[bauth, dauth]) - def _test_urls(self, urls, handlers): + def _test_urls(self, urls, handlers, urlopen=_urlopen_with_retry): import socket import time import logging @@ -241,7 +255,7 @@ req = expected_err = None debug(url) try: - f = urllib2.urlopen(url, req) + f = urlopen(url, req) except EnvironmentError, err: debug(err) if expected_err: @@ -267,45 +281,47 @@ class TimeoutTest(unittest.TestCase): def test_http_basic(self): - u = urllib2.urlopen("http://www.python.org") + u = _urlopen_with_retry("http://www.python.org") self.assertTrue(u.fp._sock.fp._sock.gettimeout() is None) def test_http_NoneWithdefault(self): prev = socket.getdefaulttimeout() socket.setdefaulttimeout(60) try: - u = urllib2.urlopen("http://www.python.org", timeout=None) + u = _urlopen_with_retry("http://www.python.org", timeout=None) self.assertEqual(u.fp._sock.fp._sock.gettimeout(), 60) finally: socket.setdefaulttimeout(prev) def test_http_Value(self): - u = urllib2.urlopen("http://www.python.org", timeout=120) + u = _urlopen_with_retry("http://www.python.org", timeout=120) self.assertEqual(u.fp._sock.fp._sock.gettimeout(), 120) def test_http_NoneNodefault(self): - u = urllib2.urlopen("http://www.python.org", timeout=None) + u = _urlopen_with_retry("http://www.python.org", timeout=None) self.assertTrue(u.fp._sock.fp._sock.gettimeout() is None) + FTP_HOST = "ftp://ftp.mirror.nl/pub/mirror/gnu/" + def test_ftp_basic(self): - u = urllib2.urlopen("ftp://ftp.mirror.nl/pub/mirror/gnu/") + u = _urlopen_with_retry(self.FTP_HOST) self.assertTrue(u.fp.fp._sock.gettimeout() is None) def test_ftp_NoneWithdefault(self): prev = socket.getdefaulttimeout() socket.setdefaulttimeout(60) try: - u = urllib2.urlopen("ftp://ftp.mirror.nl/pub/mirror/gnu/", timeout=None) + u = _urlopen_with_retry(self.FTP_HOST, timeout=None) self.assertEqual(u.fp.fp._sock.gettimeout(), 60) finally: socket.setdefaulttimeout(prev) def test_ftp_NoneNodefault(self): - u = urllib2.urlopen("ftp://ftp.mirror.nl/pub/mirror/gnu/", timeout=None) + u = _urlopen_with_retry(self.FTP_HOST, timeout=None) self.assertTrue(u.fp.fp._sock.gettimeout() is None) def test_ftp_Value(self): - u = urllib2.urlopen("ftp://ftp.mirror.nl/pub/mirror/gnu/", timeout=60) + u = _urlopen_with_retry(self.FTP_HOST, timeout=60) self.assertEqual(u.fp.fp._sock.gettimeout(), 60) Modified: python/branches/trunk-math/Lib/test/test_urllibnet.py ============================================================================== --- python/branches/trunk-math/Lib/test/test_urllibnet.py (original) +++ python/branches/trunk-math/Lib/test/test_urllibnet.py Sun Jan 27 19:55:42 2008 @@ -9,6 +9,20 @@ import os import mimetools + +def _open_with_retry(func, host, *args, **kwargs): + # Connecting to remote hosts is flaky. Make it more robust + # by retrying the connection several times. + for i in range(3): + try: + return func(host, *args, **kwargs) + except IOError, last_exc: + continue + except: + raise + raise last_exc + + class URLTimeoutTest(unittest.TestCase): TIMEOUT = 10.0 @@ -20,7 +34,7 @@ socket.setdefaulttimeout(None) def testURLread(self): - f = urllib.urlopen("http://www.python.org/") + f = _open_with_retry(urllib.urlopen, "http://www.python.org/") x = f.read() class urlopenNetworkTests(unittest.TestCase): @@ -38,9 +52,12 @@ """ + def urlopen(self, *args): + return _open_with_retry(urllib.urlopen, *args) + def test_basic(self): # Simple test expected to pass. - open_url = urllib.urlopen("http://www.python.org/") + open_url = self.urlopen("http://www.python.org/") for attr in ("read", "readline", "readlines", "fileno", "close", "info", "geturl"): self.assert_(hasattr(open_url, attr), "object returned from " @@ -52,7 +69,7 @@ def test_readlines(self): # Test both readline and readlines. - open_url = urllib.urlopen("http://www.python.org/") + open_url = self.urlopen("http://www.python.org/") try: self.assert_(isinstance(open_url.readline(), basestring), "readline did not return a string") @@ -63,7 +80,7 @@ def test_info(self): # Test 'info'. - open_url = urllib.urlopen("http://www.python.org/") + open_url = self.urlopen("http://www.python.org/") try: info_obj = open_url.info() finally: @@ -76,7 +93,7 @@ def test_geturl(self): # Make sure same URL as opened is returned by geturl. URL = "http://www.python.org/" - open_url = urllib.urlopen(URL) + open_url = self.urlopen(URL) try: gotten_url = open_url.geturl() finally: @@ -100,7 +117,7 @@ # test can't pass on Windows. return # Make sure fd returned by fileno is valid. - open_url = urllib.urlopen("http://www.python.org/") + open_url = self.urlopen("http://www.python.org/") fd = open_url.fileno() FILE = os.fdopen(fd) try: @@ -125,9 +142,12 @@ class urlretrieveNetworkTests(unittest.TestCase): """Tests urllib.urlretrieve using the network.""" + def urlretrieve(self, *args): + return _open_with_retry(urllib.urlretrieve, *args) + def test_basic(self): # Test basic functionality. - file_location,info = urllib.urlretrieve("http://www.python.org/") + file_location,info = self.urlretrieve("http://www.python.org/") self.assert_(os.path.exists(file_location), "file location returned by" " urlretrieve is not a valid path") FILE = file(file_location) @@ -140,8 +160,8 @@ def test_specified_path(self): # Make sure that specifying the location of the file to write to works. - file_location,info = urllib.urlretrieve("http://www.python.org/", - test_support.TESTFN) + file_location,info = self.urlretrieve("http://www.python.org/", + test_support.TESTFN) self.assertEqual(file_location, test_support.TESTFN) self.assert_(os.path.exists(file_location)) FILE = file(file_location) @@ -153,7 +173,7 @@ def test_header(self): # Make sure header returned as 2nd value from urlretrieve is good. - file_location, header = urllib.urlretrieve("http://www.python.org/") + file_location, header = self.urlretrieve("http://www.python.org/") os.unlink(file_location) self.assert_(isinstance(header, mimetools.Message), "header is not an instance of mimetools.Message") Modified: python/branches/trunk-math/Lib/test/test_xmlrpc.py ============================================================================== --- python/branches/trunk-math/Lib/test/test_xmlrpc.py (original) +++ python/branches/trunk-math/Lib/test/test_xmlrpc.py Sun Jan 27 19:55:42 2008 @@ -296,6 +296,9 @@ PORT = None +# The evt is set twice. First when the server is ready to serve. +# Second when the server has been shutdown. The user must clear +# the event after it has been set the first time to catch the second set. def http_server(evt, numrequests): class TestInstanceClass: def div(self, x, y): @@ -323,6 +326,7 @@ serv.register_function(lambda x,y: x+y, 'add') serv.register_function(my_function) serv.register_instance(TestInstanceClass()) + evt.set() # handle up to 'numrequests' requests while numrequests > 0: @@ -336,10 +340,13 @@ PORT = None evt.set() +# This function prevents errors like: +# def is_unavailable_exception(e): '''Returns True if the given ProtocolError is the product of a server-side exception caused by the 'temporarily unavailable' response sometimes given by operations on non-blocking sockets.''' + # sometimes we get a -1 error code and/or empty headers if e.errcode == -1 or e.headers is None: return True @@ -367,13 +374,9 @@ serv_args = (self.evt, 1) threading.Thread(target=http_server, args=serv_args).start() - # wait for port to be assigned to server - n = 1000 - while n > 0 and PORT is None: - time.sleep(0.001) - n -= 1 - - time.sleep(0.5) + # wait for the server to be ready + self.evt.wait() + self.evt.clear() def tearDown(self): # wait on the server thread to terminate @@ -386,7 +389,7 @@ try: p = xmlrpclib.ServerProxy('http://localhost:%d' % PORT) self.assertEqual(p.pow(6,8), 6**8) - except xmlrpclib.ProtocolError, e: + except (xmlrpclib.ProtocolError, socket.error), e: # ignore failures due to non-blocking socket 'unavailable' errors if not is_unavailable_exception(e): # protocol error; provide additional information in test output @@ -412,7 +415,7 @@ 'system.listMethods', 'system.methodHelp', 'system.methodSignature', 'system.multicall']) self.assertEqual(set(meth), expected_methods) - except xmlrpclib.ProtocolError, e: + except (xmlrpclib.ProtocolError, socket.error), e: # ignore failures due to non-blocking socket 'unavailable' errors if not is_unavailable_exception(e): # protocol error; provide additional information in test output @@ -424,7 +427,7 @@ p = xmlrpclib.ServerProxy('http://localhost:%d' % PORT) divhelp = p.system.methodHelp('div') self.assertEqual(divhelp, 'This is the div function') - except xmlrpclib.ProtocolError, e: + except (xmlrpclib.ProtocolError, socket.error), e: # ignore failures due to non-blocking socket 'unavailable' errors if not is_unavailable_exception(e): # protocol error; provide additional information in test output @@ -436,7 +439,7 @@ p = xmlrpclib.ServerProxy('http://localhost:%d' % PORT) myfunction = p.system.methodHelp('my_function') self.assertEqual(myfunction, 'This is my function') - except xmlrpclib.ProtocolError, e: + except (xmlrpclib.ProtocolError, socket.error), e: # ignore failures due to non-blocking socket 'unavailable' errors if not is_unavailable_exception(e): # protocol error; provide additional information in test output @@ -449,7 +452,7 @@ p = xmlrpclib.ServerProxy('http://localhost:%d' % PORT) divsig = p.system.methodSignature('div') self.assertEqual(divsig, 'signatures not supported') - except xmlrpclib.ProtocolError, e: + except (xmlrpclib.ProtocolError, socket.error), e: # ignore failures due to non-blocking socket 'unavailable' errors if not is_unavailable_exception(e): # protocol error; provide additional information in test output @@ -466,7 +469,7 @@ self.assertEqual(add_result, 2+3) self.assertEqual(pow_result, 6**8) self.assertEqual(div_result, 127//42) - except xmlrpclib.ProtocolError, e: + except (xmlrpclib.ProtocolError, socket.error), e: # ignore failures due to non-blocking socket 'unavailable' errors if not is_unavailable_exception(e): # protocol error; provide additional information in test output @@ -487,7 +490,7 @@ self.assertEqual(result.results[0]['faultString'], ':method "this_is_not_exists" ' 'is not supported') - except xmlrpclib.ProtocolError, e: + except (xmlrpclib.ProtocolError, socket.error), e: # ignore failures due to non-blocking socket 'unavailable' errors if not is_unavailable_exception(e): # protocol error; provide additional information in test output @@ -518,13 +521,9 @@ serv_args = (self.evt, 2) threading.Thread(target=http_server, args=serv_args).start() - # wait for port to be assigned to server - n = 1000 - while n > 0 and PORT is None: - time.sleep(0.001) - n -= 1 - - time.sleep(0.5) + # wait for the server to be ready + self.evt.wait() + self.evt.clear() def tearDown(self): # wait on the server thread to terminate @@ -546,7 +545,7 @@ try: p = xmlrpclib.ServerProxy('http://localhost:%d' % PORT) self.assertEqual(p.pow(6,8), 6**8) - except xmlrpclib.ProtocolError, e: + except (xmlrpclib.ProtocolError, socket.error), e: # ignore failures due to non-blocking socket 'unavailable' errors if not is_unavailable_exception(e): # protocol error; provide additional information in test output @@ -559,7 +558,7 @@ try: p = xmlrpclib.ServerProxy('http://localhost:%d' % PORT) p.pow(6,8) - except xmlrpclib.ProtocolError, e: + except (xmlrpclib.ProtocolError, socket.error), e: # ignore failures due to non-blocking socket 'unavailable' errors if not is_unavailable_exception(e): # The two server-side error headers shouldn't be sent back in this case @@ -579,7 +578,7 @@ try: p = xmlrpclib.ServerProxy('http://localhost:%d' % PORT) p.pow(6,8) - except xmlrpclib.ProtocolError, e: + except (xmlrpclib.ProtocolError, socket.error), e: # ignore failures due to non-blocking socket 'unavailable' errors if not is_unavailable_exception(e): # We should get error info in the response Modified: python/branches/trunk-math/Lib/test/test_zipfile.py ============================================================================== --- python/branches/trunk-math/Lib/test/test_zipfile.py (original) +++ python/branches/trunk-math/Lib/test/test_zipfile.py Sun Jan 27 19:55:42 2008 @@ -316,6 +316,7 @@ correctfile = os.path.join(os.getcwd(), fpath[1:]) else: correctfile = os.path.join(os.getcwd(), fpath) + correctfile = os.path.normpath(correctfile) self.assertEqual(writtenfile, correctfile) Modified: python/branches/trunk-math/Lib/threading.py ============================================================================== --- python/branches/trunk-math/Lib/threading.py (original) +++ python/branches/trunk-math/Lib/threading.py Sun Jan 27 19:55:42 2008 @@ -347,18 +347,27 @@ return self.__flag def set(self): - with self.__cond: + self.__cond.acquire() + try: self.__flag = True self.__cond.notifyAll() + finally: + self.__cond.release() def clear(self): - with self.__cond: + self.__cond.acquire() + try: self.__flag = False + finally: + self.__cond.release() def wait(self, timeout=None): - with self.__cond: + self.__cond.acquire() + try: if not self.__flag: self.__cond.wait(timeout) + finally: + self.__cond.release() # Helper to generate new thread names _counter = 0 @@ -525,9 +534,10 @@ pass def __stop(self): - with self.__block: - self.__stopped = True - self.__block.notifyAll() + self.__block.acquire() + self.__stopped = True + self.__block.notifyAll() + self.__block.release() def __delete(self): "Remove current thread from the dict of currently running threads." @@ -553,12 +563,15 @@ # since it isn't if dummy_threading is *not* being used then don't # hide the exception. - with _active_limbo_lock: + _active_limbo_lock.acquire() + try: try: del _active[_get_ident()] except KeyError: if 'dummy_threading' not in _sys.modules: raise + finally: + _active_limbo_lock.release() def join(self, timeout=None): if not self.__initialized: @@ -571,7 +584,8 @@ if __debug__: if not self.__stopped: self._note("%s.join(): waiting until thread stops", self) - with self.__block: + self.__block.acquire() + try: if timeout is None: while not self.__stopped: self.__block.wait() @@ -589,6 +603,8 @@ else: if __debug__: self._note("%s.join(): thread stopped", self) + finally: + self.__block.release() def getName(self): assert self.__initialized, "Thread.__init__() not called" Modified: python/branches/trunk-math/Lib/urllib2.py ============================================================================== --- python/branches/trunk-math/Lib/urllib2.py (original) +++ python/branches/trunk-math/Lib/urllib2.py Sun Jan 27 19:55:42 2008 @@ -1246,7 +1246,7 @@ import mimetypes host = req.get_host() if not host: - raise URLError, ('ftp error', 'no host given') + raise URLError('ftp error: no host given') host, port = splitport(host) if port is None: port = ftplib.FTP_PORT @@ -1292,7 +1292,7 @@ headers = mimetools.Message(sf) return addinfourl(fp, headers, req.get_full_url()) except ftplib.all_errors, msg: - raise URLError, ('ftp error', msg), sys.exc_info()[2] + raise URLError, ('ftp error: %s' % msg), sys.exc_info()[2] def connect_ftp(self, user, passwd, host, port, dirs, timeout): fw = ftpwrapper(user, passwd, host, port, dirs, timeout) Modified: python/branches/trunk-math/Makefile.pre.in ============================================================================== --- python/branches/trunk-math/Makefile.pre.in (original) +++ python/branches/trunk-math/Makefile.pre.in Sun Jan 27 19:55:42 2008 @@ -619,7 +619,7 @@ testall: all platform -find $(srcdir)/Lib -name '*.py[co]' -print | xargs rm -f - $(TESTPYTHON) Lib/compileall.py + $(TESTPYTHON) $(srcdir)/Lib/compileall.py -find $(srcdir)/Lib -name '*.py[co]' -print | xargs rm -f -$(TESTPYTHON) $(TESTPROG) $(TESTOPTS) -uall $(TESTPYTHON) $(TESTPROG) $(TESTOPTS) -uall Modified: python/branches/trunk-math/Misc/NEWS ============================================================================== --- python/branches/trunk-math/Misc/NEWS (original) +++ python/branches/trunk-math/Misc/NEWS Sun Jan 27 19:55:42 2008 @@ -12,7 +12,26 @@ Core and builtins ----------------- -- Patch #1720595: add T_BOOL to the range of structmember types. +- Patch #1473257: generator objects gain a gi_code attribute. This is the + same object as the func_code attribute of the function that produced the + generator. + +- Issue #1920: "while 0" statements were completely removed by the compiler, + even in the presence of an "else" clause, which is supposed to be run when + the condition is false. Now the compiler correctly emits bytecode for the + "else" suite. + +- A few crashers fixed: weakref_in_del.py (issue #1377858); + loosing_dict_ref.py (issue #1303614, test67.py); + borrowed_ref_[34].py (not in tracker). + +- Issue #1069410: The "can't load dll" message box on Windows is + suppressed while an extension is loaded by calling SetErrorMode in + dynload_win.c. The error is still reported properly. + +- Bug #1915: Python compiles with --enable-unicode=no again. However + several extension methods and modules do not work without unicode + support. - Issue #1882: when compiling code from a string, encoding cookies in the second line of code were not always recognized correctly. @@ -24,7 +43,7 @@ - Issue #1679: "0x" was taken as a valid integer literal. -- Issue #1865: Bytes as an alias for str and b"" as an alias "" were +- Issue #1865: ``bytes`` as an alias for ``str`` and b"" as an alias "" were added. - sys.float_info / PyFloat_GetInfo: The floating point information @@ -33,7 +52,7 @@ - Patch #1816: Added sys.flags structseq. It exposes the status of most command line arguments and PYTHON* environment variables. -- Object/structseq.c: Implemented new structseq representation. The patch +- Objects/structseq.c: Implemented new structseq representation. The patch makes structseqs (e.g. the return value of os.stat) more readable. - Patch #1700288: added a type attribute cache that caches method accesses, @@ -84,14 +103,6 @@ inside packages with the -m switch via a new module level __package__ attribute. -- Issue #1534: Added ``PyFloat_GetMax()``, ``PyFloat_GetMin()`` and - ``PyFloat_GetInfo()`` to the float API. - -- Issue #1521: On 64bit platforms, using PyArgs_ParseTuple with the t# of w# - format code incorrectly truncated the length to an int, even when - PY_SSIZE_T_CLEAN is set. The str.decode method used to return incorrect - results with huge strings. - - Issue #1402: Fix a crash on exit, when another thread is still running, and if the deallocation of its frames somehow calls the PyGILState_Ensure() / PyGILState_Release() functions. @@ -148,19 +159,9 @@ - Patch #1031213: Decode source line in SyntaxErrors back to its original source encoding. -- Py_ssize_t fields work in structmember when HAVE_LONG_LONG is not defined. - -- PEP 3123: Provide forward compatibility with Python 3.0, while keeping - backwards compatibility. Add Py_Refcnt, Py_Type, Py_Size, and - PyVarObject_HEAD_INIT. - - Patch #1673759: add a missing overflow check when formatting floats with %G. -- Patch #1733960: Allow T_LONGLONG to accept ints. - -- T_PYSSIZET can now be used in PyMemberDef lists for Py_ssize_t members. - - Prevent expandtabs() on string and unicode objects from causing a segfault when a large width is passed on 32-bit platforms. @@ -276,8 +277,6 @@ - patch #1630975: Fix crash when replacing sys.stdout in sitecustomize.py -- Bug #1637022: Prefix AST symbols with _Py_. - - Prevent seg fault on shutdown which could occur if an object raised a warning. @@ -317,9 +316,6 @@ - list.pop(x) accepts any object x following the __index__ protocol. -- Fix some leftovers from the conversion from int to Py_ssize_t - (relevant to strings and sequences of more than 2**31 items). - - A number of places, including integer negation and absolute value, were fixed to not rely on undefined behaviour of the C compiler anymore. @@ -344,9 +340,6 @@ - Bug #1551432: Exceptions do not define an explicit __unicode__ method. This allows calling unicode() on exceptions classes directly to succeed. -- Make _PyGILState_NoteThreadState() static, it was not used anywhere - outside of pystate.c and should not be necessary. - - Bug #1542051: Exceptions now correctly call PyObject_GC_UnTrack. Also make sure that every exception class has __module__ set to 'exceptions'. @@ -369,7 +362,7 @@ required changing the .pyc magic number. This means that .pyc files generated before 2.5c2 will be regenerated. -- with and as are now keywords. +- ``with`` and ``as`` are now keywords. - Bug #1664966: Fix crash in exec if Unicode filename can't be decoded. @@ -380,9 +373,14 @@ threading.enumerate() list after the join() for a brief period until it actually exited. + Library ------- +- #1765140: add an optional delay argument to FileHandler and its + subclasses. Defaults to false (existing behaviour), but if true, + defers opening the file until the first call to emit(). + - The pprint module now supports sets and frozensets. - #1221598: add optional callbacks to ftplib.FTP's storbinary() and @@ -1083,9 +1081,15 @@ does not claim to support starttls. Adds the SMTP.ehlo_or_helo_if_needed() method. Patch contributed by Bill Fenner. + Extension Modules ----------------- +- #1940: make it possible to use curses.filter() before curses.initscr() + as the documentation says. + +- Backport of _fileio module from Python 3.0. + - #1087741: mmap.mmap is now a class, not a factory function. It is also subclassable now. @@ -1312,9 +1316,13 @@ platform.python_implementation(); this will now be saved in the benchmark pickle + Documentation ------------- +- RFE #1765140: Updated documentation on FileHandler and subclasses to + include new optional delay argument. + - Bug #932563: Added section on getting contextual information into logging output, and added documentation for the new LoggerAdapter class. @@ -1440,18 +1448,51 @@ - Makefile.pre.in(buildbottest): Run an optional script pybuildbot.identify to include some information about the build environment. + C API ----- +- Backport of PyUnicode_FromString(), _FromStringAndSize(), _Format and + _FormatV from Python 3.0. Made PyLong_AsSsize_t and PyLong_FromSsize_t + public functions. + +- Patch #1720595: add T_BOOL to the range of structmember types. + +- Issue #1534: Added ``PyFloat_GetMax()``, ``PyFloat_GetMin()`` and + ``PyFloat_GetInfo()`` to the float API. + +- Issue #1521: On 64bit platforms, using PyArgs_ParseTuple with the t# of w# + format code incorrectly truncated the length to an int, even when + PY_SSIZE_T_CLEAN is set. The str.decode method used to return incorrect + results with huge strings. + +- Issue #1629: Renamed Py_Size, Py_Type and Py_Refcnt to Py_SIZE, Py_TYPE + and Py_REFCNT. + +- PEP 3123: Provide forward compatibility with Python 3.0, while keeping + backwards compatibility. Add Py_Refcnt, Py_Type, Py_Size, and + PyVarObject_HEAD_INIT. + +- Py_ssize_t fields work in structmember when HAVE_LONG_LONG is not defined. + +- Patch #1733960: Allow T_LONGLONG to accept ints. + +- T_PYSSIZET can now be used in PyMemberDef lists for Py_ssize_t members. + - Added a new API function ``PyImport_ImportModuleNoBlock``. +- Bug #1637022: Prefix AST symbols with _Py_. + +- Fix some leftovers from the conversion from int to Py_ssize_t + (relevant to strings and sequences of more than 2**31 items). + +- Make _PyGILState_NoteThreadState() static, it was not used anywhere + outside of pystate.c and should not be necessary. + - ``PyImport_Import`` and ``PyImport_ImportModule`` now always do absolute imports. In earlier versions they might have used relative imports under some conditions. -- Issue #1629: Renamed Py_Size, Py_Type and Py_Refcnt to Py_SIZE, Py_TYPE - and Py_REFCNT. - - Added case insensitive comparison methods ``PyOS_stricmp(char*, char*)`` and ``PyOS_strnicmp(char*, char*, Py_ssize_t)``. Modified: python/branches/trunk-math/Modules/_ctypes/_ctypes.c ============================================================================== --- python/branches/trunk-math/Modules/_ctypes/_ctypes.c (original) +++ python/branches/trunk-math/Modules/_ctypes/_ctypes.c Sun Jan 27 19:55:42 2008 @@ -127,12 +127,134 @@ PyObject *PyExc_ArgError; static PyTypeObject Simple_Type; -PyObject *array_types_cache; char *conversion_mode_encoding = NULL; char *conversion_mode_errors = NULL; +/****************************************************************/ + +typedef struct { + PyObject_HEAD + PyObject *key; + PyObject *dict; +} DictRemoverObject; + +static void +_DictRemover_dealloc(PyObject *_self) +{ + DictRemoverObject *self = (DictRemoverObject *)_self; + Py_XDECREF(self->key); + Py_XDECREF(self->dict); + Py_TYPE(self)->tp_free(_self); +} + +static PyObject * +_DictRemover_call(PyObject *_self, PyObject *args, PyObject *kw) +{ + DictRemoverObject *self = (DictRemoverObject *)_self; + if (self->key && self->dict) { + if (-1 == PyDict_DelItem(self->dict, self->key)) + /* XXX Error context */ + PyErr_WriteUnraisable(Py_None); + Py_DECREF(self->key); + self->key = NULL; + Py_DECREF(self->dict); + self->dict = NULL; + } + Py_INCREF(Py_None); + return Py_None; +} + +static PyTypeObject DictRemover_Type = { + PyVarObject_HEAD_INIT(NULL, 0) + "_ctypes.DictRemover", /* tp_name */ + sizeof(DictRemoverObject), /* tp_basicsize */ + 0, /* tp_itemsize */ + _DictRemover_dealloc, /* tp_dealloc */ + 0, /* tp_print */ + 0, /* tp_getattr */ + 0, /* tp_setattr */ + 0, /* tp_compare */ + 0, /* tp_repr */ + 0, /* tp_as_number */ + 0, /* tp_as_sequence */ + 0, /* tp_as_mapping */ + 0, /* tp_hash */ + _DictRemover_call, /* tp_call */ + 0, /* tp_str */ + 0, /* tp_getattro */ + 0, /* tp_setattro */ + 0, /* tp_as_buffer */ +/* XXX should participate in GC? */ + Py_TPFLAGS_DEFAULT, /* tp_flags */ + "deletes a key from a dictionary", /* tp_doc */ + 0, /* tp_traverse */ + 0, /* tp_clear */ + 0, /* tp_richcompare */ + 0, /* tp_weaklistoffset */ + 0, /* tp_iter */ + 0, /* tp_iternext */ + 0, /* tp_methods */ + 0, /* tp_members */ + 0, /* tp_getset */ + 0, /* tp_base */ + 0, /* tp_dict */ + 0, /* tp_descr_get */ + 0, /* tp_descr_set */ + 0, /* tp_dictoffset */ + 0, /* tp_init */ + 0, /* tp_alloc */ + PyType_GenericNew, /* tp_new */ + 0, /* tp_free */ +}; + +int +PyDict_SetItemProxy(PyObject *dict, PyObject *key, PyObject *item) +{ + PyObject *obj; + DictRemoverObject *remover; + PyObject *proxy; + int result; + + obj = PyObject_CallObject((PyObject *)&DictRemover_Type, NULL); + if (obj == NULL) + return -1; + + remover = (DictRemoverObject *)obj; + assert(remover->key == NULL); + assert(remover->dict == NULL); + Py_INCREF(key); + remover->key = key; + Py_INCREF(dict); + remover->dict = dict; + + proxy = PyWeakref_NewProxy(item, obj); + Py_DECREF(obj); + if (proxy == NULL) + return -1; + + result = PyDict_SetItem(dict, key, proxy); + Py_DECREF(proxy); + return result; +} + +PyObject * +PyDict_GetItemProxy(PyObject *dict, PyObject *key) +{ + PyObject *result; + PyObject *item = PyDict_GetItem(dict, key); + + if (item == NULL) + return NULL; + if (!PyWeakref_CheckProxy(item)) + return item; + result = PyWeakref_GET_OBJECT(item); + if (result == Py_None) + return NULL; + return result; +} + /******************************************************************/ /* StructType_Type - a meta type/class. Creating a new class using this one as @@ -2401,7 +2523,7 @@ only it's object list. So we create a tuple, containing b_objects list PLUS the array itself, and return that! */ - return Py_BuildValue("(OO)", keep, value); + return PyTuple_Pack(2, keep, value); } PyErr_Format(PyExc_TypeError, "incompatible types, %s instance instead of %s instance", @@ -4102,23 +4224,30 @@ PyObject * CreateArrayType(PyObject *itemtype, Py_ssize_t length) { + static PyObject *cache; PyObject *key; PyObject *result; char name[256]; + PyObject *len; -#if (PY_VERSION_HEX < 0x02050000) - key = Py_BuildValue("(Oi)", itemtype, length); -#else - key = Py_BuildValue("(On)", itemtype, length); -#endif + if (cache == NULL) { + cache = PyDict_New(); + if (cache == NULL) + return NULL; + } + len = PyInt_FromSsize_t(length); + if (len == NULL) + return NULL; + key = PyTuple_Pack(2, itemtype, len); + Py_DECREF(len); if (!key) return NULL; - result = PyObject_GetItem(array_types_cache, key); + result = PyDict_GetItemProxy(cache, key); if (result) { + Py_INCREF(result); Py_DECREF(key); return result; - } else - PyErr_Clear(); + } if (!PyType_Check(itemtype)) { PyErr_SetString(PyExc_TypeError, @@ -4146,9 +4275,11 @@ "_type_", itemtype ); - if (!result) + if (result == NULL) { + Py_DECREF(key); return NULL; - if (-1 == PyObject_SetItem(array_types_cache, key, result)) { + } + if (-1 == PyDict_SetItemProxy(cache, key, result)) { Py_DECREF(key); Py_DECREF(result); return NULL; @@ -4965,7 +5096,6 @@ init_ctypes(void) { PyObject *m; - PyObject *weakref; /* Note: ob_type is the metatype (the 'type'), defaults to PyType_Type, @@ -4978,16 +5108,6 @@ if (!m) return; - weakref = PyImport_ImportModule("weakref"); - if (weakref == NULL) - return; - array_types_cache = PyObject_CallMethod(weakref, - "WeakValueDictionary", - NULL); - if (array_types_cache == NULL) - return; - Py_DECREF(weakref); - if (PyType_Ready(&PyCArg_Type) < 0) return; @@ -5083,6 +5203,10 @@ * Other stuff */ + DictRemover_Type.tp_new = PyType_GenericNew; + if (PyType_Ready(&DictRemover_Type) < 0) + return; + #ifdef MS_WIN32 if (create_comerror() < 0) return; Modified: python/branches/trunk-math/Modules/_ctypes/cfield.c ============================================================================== --- python/branches/trunk-math/Modules/_ctypes/cfield.c (original) +++ python/branches/trunk-math/Modules/_ctypes/cfield.c Sun Jan 27 19:55:42 2008 @@ -346,10 +346,9 @@ get_long(PyObject *v, long *p) { long x; - if (!PyInt_Check(v) && !PyLong_Check(v)) { - PyErr_Format(PyExc_TypeError, - "int expected instead of %s instance", - v->ob_type->tp_name); + if (PyFloat_Check(v)) { + PyErr_SetString(PyExc_TypeError, + "int expected instead of float"); return -1; } x = PyInt_AsUnsignedLongMask(v); @@ -365,10 +364,9 @@ get_ulong(PyObject *v, unsigned long *p) { unsigned long x; - if (!PyInt_Check(v) && !PyLong_Check(v)) { - PyErr_Format(PyExc_TypeError, - "int expected instead of %s instance", - v->ob_type->tp_name); + if (PyFloat_Check(v)) { + PyErr_SetString(PyExc_TypeError, + "int expected instead of float"); return -1; } x = PyInt_AsUnsignedLongMask(v); @@ -386,11 +384,10 @@ get_longlong(PyObject *v, PY_LONG_LONG *p) { PY_LONG_LONG x; - if (!PyInt_Check(v) && !PyLong_Check(v)) { - PyErr_Format(PyExc_TypeError, - "int expected instead of %s instance", - v->ob_type->tp_name); - return -1; + if (PyFloat_Check(v)) { + PyErr_SetString(PyExc_TypeError, + "int expected instead of float"); + return -1; } x = PyInt_AsUnsignedLongLongMask(v); if (x == -1 && PyErr_Occurred()) @@ -405,12 +402,11 @@ get_ulonglong(PyObject *v, unsigned PY_LONG_LONG *p) { unsigned PY_LONG_LONG x; - if (!PyInt_Check(v) && !PyLong_Check(v)) { - PyErr_Format(PyExc_TypeError, - "int expected instead of %s instance", - v->ob_type->tp_name); - return -1; - } + if (PyFloat_Check(v)) { + PyErr_SetString(PyExc_TypeError, + "int expected instead of float"); + return -1; + } x = PyInt_AsUnsignedLongLongMask(v); if (x == -1 && PyErr_Occurred()) return -1; Modified: python/branches/trunk-math/Modules/_ctypes/libffi/src/alpha/ffi.c ============================================================================== --- python/branches/trunk-math/Modules/_ctypes/libffi/src/alpha/ffi.c (original) +++ python/branches/trunk-math/Modules/_ctypes/libffi/src/alpha/ffi.c Sun Jan 27 19:55:42 2008 @@ -25,11 +25,22 @@ #include #include - #include -extern void ffi_call_osf(void *, unsigned long, unsigned, void *, void (*)(void)); -extern void ffi_closure_osf(void); +/* Force FFI_TYPE_LONGDOUBLE to be different than FFI_TYPE_DOUBLE; + all further uses in this file will refer to the 128-bit type. */ +#if defined(__LONG_DOUBLE_128__) +# if FFI_TYPE_LONGDOUBLE != 4 +# error FFI_TYPE_LONGDOUBLE out of date +# endif +#else +# undef FFI_TYPE_LONGDOUBLE +# define FFI_TYPE_LONGDOUBLE 4 +#endif + +extern void ffi_call_osf(void *, unsigned long, unsigned, void *, void (*)(void)) + FFI_HIDDEN; +extern void ffi_closure_osf(void) FFI_HIDDEN; ffi_status @@ -49,6 +60,11 @@ cif->flags = cif->rtype->type; break; + case FFI_TYPE_LONGDOUBLE: + /* 128-bit long double is returned in memory, like a struct. */ + cif->flags = FFI_TYPE_STRUCT; + break; + default: cif->flags = FFI_TYPE_INT; break; @@ -57,6 +73,7 @@ return FFI_OK; } + void ffi_call(ffi_cif *cif, void (*fn)(void), void *rvalue, void **avalue) { @@ -64,8 +81,6 @@ long i, avn; ffi_type **arg_types; - FFI_ASSERT (cif->abi == FFI_OSF); - /* If the return value is a struct and we don't have a return value address then we need to make one. */ if (rvalue == NULL && cif->flags == FFI_TYPE_STRUCT) @@ -84,6 +99,8 @@ while (i < avn) { + size_t size = (*arg_types)->size; + switch ((*arg_types)->type) { case FFI_TYPE_SINT8: @@ -129,6 +146,12 @@ *(double *) argp = *(double *)(* avalue); break; + case FFI_TYPE_LONGDOUBLE: + /* 128-bit long double is passed by reference. */ + *(long double **) argp = (long double *)(* avalue); + size = sizeof (long double *); + break; + case FFI_TYPE_STRUCT: memcpy(argp, *avalue, (*arg_types)->size); break; @@ -137,7 +160,7 @@ FFI_ASSERT(0); } - argp += ALIGN((*arg_types)->size, FFI_SIZEOF_ARG) / FFI_SIZEOF_ARG; + argp += ALIGN(size, FFI_SIZEOF_ARG) / FFI_SIZEOF_ARG; i++, arg_types++, avalue++; } @@ -153,8 +176,6 @@ { unsigned int *tramp; - FFI_ASSERT (cif->abi == FFI_OSF); - tramp = (unsigned int *) &closure->tramp[0]; tramp[0] = 0x47fb0401; /* mov $27,$1 */ tramp[1] = 0xa77b0010; /* ldq $27,16($27) */ @@ -177,7 +198,8 @@ return FFI_OK; } -int + +long FFI_HIDDEN ffi_closure_osf_inner(ffi_closure *closure, void *rvalue, unsigned long *argp) { ffi_cif *cif; @@ -205,6 +227,8 @@ /* Grab the addresses of the arguments from the stack frame. */ while (i < avn) { + size_t size = arg_types[i]->size; + switch (arg_types[i]->type) { case FFI_TYPE_SINT8: @@ -236,16 +260,22 @@ avalue[i] = &argp[argn - (argn < 6 ? 6 : 0)]; break; + case FFI_TYPE_LONGDOUBLE: + /* 128-bit long double is passed by reference. */ + avalue[i] = (long double *) argp[argn]; + size = sizeof (long double *); + break; + default: - FFI_ASSERT(0); + abort (); } - argn += ALIGN(arg_types[i]->size, FFI_SIZEOF_ARG) / FFI_SIZEOF_ARG; + argn += ALIGN(size, FFI_SIZEOF_ARG) / FFI_SIZEOF_ARG; i++; } /* Invoke the closure. */ - (closure->fun) (cif, rvalue, avalue, closure->user_data); + closure->fun (cif, rvalue, avalue, closure->user_data); /* Tell ffi_closure_osf how to perform return type promotions. */ return cif->rtype->type; Modified: python/branches/trunk-math/Modules/_ctypes/libffi/src/alpha/osf.S ============================================================================== --- python/branches/trunk-math/Modules/_ctypes/libffi/src/alpha/osf.S (original) +++ python/branches/trunk-math/Modules/_ctypes/libffi/src/alpha/osf.S Sun Jan 27 19:55:42 2008 @@ -1,10 +1,8 @@ /* ----------------------------------------------------------------------- - osf.S - Copyright (c) 1998, 2001 Red Hat + osf.S - Copyright (c) 1998, 2001, 2007 Red Hat Alpha/OSF Foreign Function Interface - $Id: osf.S,v 1.2 2006/03/03 20:24:26 theller Exp $ - Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the ``Software''), to deal in the Software without restriction, including @@ -42,6 +40,8 @@ .align 3 .globl ffi_call_osf .ent ffi_call_osf + FFI_HIDDEN(ffi_call_osf) + ffi_call_osf: .frame $15, 32, $26, 0 .mask 0x4008000, -32 @@ -129,6 +129,8 @@ .align 3 .globl ffi_closure_osf .ent ffi_closure_osf + FFI_HIDDEN(ffi_closure_osf) + ffi_closure_osf: .frame $30, 16*8, $26, 0 .mask 0x4000000, -16*8 @@ -265,7 +267,7 @@ .gprel32 $load_32 # FFI_TYPE_INT .gprel32 $load_float # FFI_TYPE_FLOAT .gprel32 $load_double # FFI_TYPE_DOUBLE - .gprel32 $load_double # FFI_TYPE_LONGDOUBLE + .gprel32 $load_none # FFI_TYPE_LONGDOUBLE .gprel32 $load_u8 # FFI_TYPE_UINT8 .gprel32 $load_s8 # FFI_TYPE_SINT8 .gprel32 $load_u16 # FFI_TYPE_UINT16 Modified: python/branches/trunk-math/Modules/_cursesmodule.c ============================================================================== --- python/branches/trunk-math/Modules/_cursesmodule.c (original) +++ python/branches/trunk-math/Modules/_cursesmodule.c Sun Jan 27 19:55:42 2008 @@ -1677,11 +1677,20 @@ NoArgTrueFalseFunction(has_ic) NoArgTrueFalseFunction(has_il) NoArgTrueFalseFunction(isendwin) -NoArgNoReturnVoidFunction(filter) NoArgNoReturnVoidFunction(flushinp) NoArgNoReturnVoidFunction(noqiflush) static PyObject * +PyCurses_filter(PyObject *self) +{ + /* not checking for PyCursesInitialised here since filter() must + be called before initscr() */ + filter(); + Py_INCREF(Py_None); + return Py_None; +} + +static PyObject * PyCurses_Color_Content(PyObject *self, PyObject *args) { short color,r,g,b; Modified: python/branches/trunk-math/Modules/_ssl.c ============================================================================== --- python/branches/trunk-math/Modules/_ssl.c (original) +++ python/branches/trunk-math/Modules/_ssl.c Sun Jan 27 19:55:42 2008 @@ -17,7 +17,7 @@ #ifdef WITH_THREAD #include "pythread.h" #define PySSL_BEGIN_ALLOW_THREADS { \ - PyThreadState *_save; \ + PyThreadState *_save = NULL; \ if (_ssl_locks_count>0) {_save = PyEval_SaveThread();} #define PySSL_BLOCK_THREADS if (_ssl_locks_count>0){PyEval_RestoreThread(_save)}; #define PySSL_UNBLOCK_THREADS if (_ssl_locks_count>0){_save = PyEval_SaveThread()}; @@ -687,7 +687,7 @@ } p = ext->value->data; - if(method->it) + if (method->it) names = (GENERAL_NAMES*) (ASN1_item_d2i(NULL, &p, ext->value->length, Modified: python/branches/trunk-math/Modules/config.c.in ============================================================================== --- python/branches/trunk-math/Modules/config.c.in (original) +++ python/branches/trunk-math/Modules/config.c.in Sun Jan 27 19:55:42 2008 @@ -43,7 +43,7 @@ /* This lives in Python/Python-ast.c */ {"_ast", init_ast}, - /* This lives in Python/_types.c */ + /* This lives in Modules/_typesmodule.c */ {"_types", init_types}, /* These entries are here for sys.builtin_module_names */ Modified: python/branches/trunk-math/Modules/mathmodule.c ============================================================================== --- python/branches/trunk-math/Modules/mathmodule.c (original) +++ python/branches/trunk-math/Modules/mathmodule.c Sun Jan 27 19:55:42 2008 @@ -55,6 +55,11 @@ #include "Python.h" #include "longintrepr.h" /* just for SHIFT */ +#ifdef _OSF_SOURCE +/* OSF1 5.1 doesn't make this available with XOPEN_SOURCE_EXTENDED defined */ +extern double copysign(double, double); +#endif + /* Call is_error when errno != 0, and where x is the result libm * returned. is_error will usually set up an exception and return * true (1), but may return false (0) without setting up an exception. @@ -295,11 +300,11 @@ "math domain error"); return NULL; } - /* Value is ~= x * 2**(e*SHIFT), so the log ~= - log(x) + log(2) * e * SHIFT. - CAUTION: e*SHIFT may overflow using int arithmetic, + /* Value is ~= x * 2**(e*PyLong_SHIFT), so the log ~= + log(x) + log(2) * e * PyLong_SHIFT. + CAUTION: e*PyLong_SHIFT may overflow using int arithmetic, so force use of double. */ - x = func(x) + (e * (double)SHIFT) * func(2.0); + x = func(x) + (e * (double)PyLong_SHIFT) * func(2.0); return PyFloat_FromDouble(x); } Modified: python/branches/trunk-math/Modules/mmapmodule.c ============================================================================== --- python/branches/trunk-math/Modules/mmapmodule.c (original) +++ python/branches/trunk-math/Modules/mmapmodule.c Sun Jan 27 19:55:42 2008 @@ -129,7 +129,7 @@ } #endif /* UNIX */ - m_obj->ob_type->tp_free((PyObject*)m_obj); + Py_TYPE(m_obj)->tp_free((PyObject*)m_obj); } static PyObject * @@ -253,8 +253,8 @@ int reverse) { Py_ssize_t start = self->pos; - Py_ssize_t end = self->size; - char *needle; + Py_ssize_t end = self->size; + const char *needle; Py_ssize_t len; CHECK_VALID(NULL); @@ -262,8 +262,8 @@ &needle, &len, &start, &end)) { return NULL; } else { - char *p; - char sign = reverse ? -1 : 1; + const char *p, *start_p, *end_p; + int sign = reverse ? -1 : 1; if (start < 0) start += self->size; @@ -279,11 +279,11 @@ else if ((size_t)end > self->size) end = self->size; - start += (Py_ssize_t)self->data; - end += (Py_ssize_t)self->data; + start_p = self->data + start; + end_p = self->data + end; - for (p = (char *)(reverse ? end - len : start); - p >= (char *)start && p + len <= (char *)end; p+=sign) { + for (p = (reverse ? end_p - len : start_p); + (p >= start_p) && (p + len <= end_p); p += sign) { Py_ssize_t i; for (i = 0; i < len && needle[i] == p[i]; ++i) /* nothing */; @@ -532,23 +532,21 @@ if ((size_t)(offset + size) > self->size) { PyErr_SetString(PyExc_ValueError, "flush values out of range"); return NULL; - } else { + } #ifdef MS_WINDOWS - return PyInt_FromLong((long) - FlushViewOfFile(self->data+offset, size)); -#endif /* MS_WINDOWS */ -#ifdef UNIX - /* XXX semantics of return value? */ - /* XXX flags for msync? */ - if (-1 == msync(self->data + offset, size, - MS_SYNC)) - { - PyErr_SetFromErrno(mmap_module_error); - return NULL; - } - return PyInt_FromLong(0); -#endif /* UNIX */ + return PyInt_FromLong((long) FlushViewOfFile(self->data+offset, size)); +#elif defined(UNIX) + /* XXX semantics of return value? */ + /* XXX flags for msync? */ + if (-1 == msync(self->data + offset, size, MS_SYNC)) { + PyErr_SetFromErrno(mmap_module_error); + return NULL; } + return PyInt_FromLong(0); +#else + PyErr_SetString(PyExc_ValueError, "flush not supported on this system"); + return NULL; +#endif } static PyObject * Modified: python/branches/trunk-math/Modules/socketmodule.c ============================================================================== --- python/branches/trunk-math/Modules/socketmodule.c (original) +++ python/branches/trunk-math/Modules/socketmodule.c Sun Jan 27 19:55:42 2008 @@ -1001,7 +1001,7 @@ struct sockaddr_un *a = (struct sockaddr_un *) addr; #ifdef linux if (a->sun_path[0] == 0) { /* Linux abstract namespace */ - addrlen -= (sizeof(*a) - sizeof(a->sun_path)); + addrlen -= offsetof(struct sockaddr_un, sun_path); return PyString_FromStringAndSize(a->sun_path, addrlen); } @@ -1207,7 +1207,7 @@ #if defined(PYOS_OS2) *len_ret = sizeof(*addr); #else - *len_ret = len + sizeof(*addr) - sizeof(addr->sun_path); + *len_ret = len + offsetof(struct sockaddr_un, sun_path); #endif return 1; } Modified: python/branches/trunk-math/Objects/dictobject.c ============================================================================== --- python/branches/trunk-math/Objects/dictobject.c (original) +++ python/branches/trunk-math/Objects/dictobject.c Sun Jan 27 19:55:42 2008 @@ -1406,7 +1406,7 @@ return -1; } mp = (PyDictObject*)a; - if (PyDict_CheckExact(b)) { + if (PyDict_Check(b)) { other = (PyDictObject*)b; if (other == mp || other->ma_used == 0) /* a.update(a) or a.update({}); nothing to do */ Modified: python/branches/trunk-math/Objects/floatobject.c ============================================================================== --- python/branches/trunk-math/Objects/floatobject.c (original) +++ python/branches/trunk-math/Objects/floatobject.c Sun Jan 27 19:55:42 2008 @@ -16,6 +16,11 @@ extern double pow(double, double); #endif +#ifdef _OSF_SOURCE +/* OSF1 5.1 doesn't make this available with XOPEN_SOURCE_EXTENDED defined */ +extern int finite(double); +#endif + /* Special free list -- see comments for same code in intobject.c. */ #define BLOCK_SIZE 1000 /* 1K less typical malloc overhead */ #define BHEAD_SIZE 8 /* Enough for a 64-bit pointer */ Modified: python/branches/trunk-math/Objects/genobject.c ============================================================================== --- python/branches/trunk-math/Objects/genobject.c (original) +++ python/branches/trunk-math/Objects/genobject.c Sun Jan 27 19:55:42 2008 @@ -11,6 +11,7 @@ gen_traverse(PyGenObject *gen, visitproc visit, void *arg) { Py_VISIT((PyObject *)gen->gi_frame); + Py_VISIT(gen->gi_code); return 0; } @@ -35,6 +36,7 @@ _PyObject_GC_UNTRACK(self); Py_CLEAR(gen->gi_frame); + Py_CLEAR(gen->gi_code); PyObject_GC_Del(gen); } @@ -282,6 +284,7 @@ static PyMemberDef gen_memberlist[] = { {"gi_frame", T_OBJECT, offsetof(PyGenObject, gi_frame), RO}, {"gi_running", T_INT, offsetof(PyGenObject, gi_running), RO}, + {"gi_code", T_OBJECT, offsetof(PyGenObject, gi_code), RO}, {NULL} /* Sentinel */ }; @@ -352,6 +355,8 @@ return NULL; } gen->gi_frame = f; + Py_INCREF(f->f_code); + gen->gi_code = (PyObject *)(f->f_code); gen->gi_running = 0; gen->gi_weakreflist = NULL; _PyObject_GC_TRACK(gen); Modified: python/branches/trunk-math/Objects/listobject.c ============================================================================== --- python/branches/trunk-math/Objects/listobject.c (original) +++ python/branches/trunk-math/Objects/listobject.c Sun Jan 27 19:55:42 2008 @@ -502,7 +502,7 @@ if (n && size/n != Py_SIZE(a)) return PyErr_NoMemory(); if (size == 0) - return PyList_New(0); + return PyList_New(0); np = (PyListObject *) PyList_New(size); if (np == NULL) return NULL; @@ -669,11 +669,11 @@ list_inplace_repeat(PyListObject *self, Py_ssize_t n) { PyObject **items; - Py_ssize_t size, i, j, p, newsize; + Py_ssize_t size, i, j, p; size = PyList_GET_SIZE(self); - if (size == 0) { + if (size == 0 || n == 1) { Py_INCREF(self); return (PyObject *)self; } @@ -684,10 +684,11 @@ return (PyObject *)self; } - newsize = size * n; - if (newsize/n != size) + if (size > PY_SSIZE_T_MAX / n) { return PyErr_NoMemory(); - if (list_resize(self, newsize) == -1) + } + + if (list_resize(self, size*n) == -1) return NULL; p = size; Modified: python/branches/trunk-math/Objects/longobject.c ============================================================================== --- python/branches/trunk-math/Objects/longobject.c (original) +++ python/branches/trunk-math/Objects/longobject.c Sun Jan 27 19:55:42 2008 @@ -11,7 +11,7 @@ /* For long multiplication, use the O(N**2) school algorithm unless * both operands contain more than KARATSUBA_CUTOFF digits (this - * being an internal Python long digit, in base BASE). + * being an internal Python long digit, in base PyLong_BASE). */ #define KARATSUBA_CUTOFF 70 #define KARATSUBA_SQUARE_CUTOFF (2 * KARATSUBA_CUTOFF) @@ -115,7 +115,7 @@ t = (unsigned long)ival; while (t) { ++ndigits; - t >>= SHIFT; + t >>= PyLong_SHIFT; } v = _PyLong_New(ndigits); if (v != NULL) { @@ -123,8 +123,8 @@ v->ob_size = negative ? -ndigits : ndigits; t = (unsigned long)ival; while (t) { - *p++ = (digit)(t & MASK); - t >>= SHIFT; + *p++ = (digit)(t & PyLong_MASK); + t >>= PyLong_SHIFT; } } return (PyObject *)v; @@ -143,15 +143,15 @@ t = (unsigned long)ival; while (t) { ++ndigits; - t >>= SHIFT; + t >>= PyLong_SHIFT; } v = _PyLong_New(ndigits); if (v != NULL) { digit *p = v->ob_digit; Py_SIZE(v) = ndigits; while (ival) { - *p++ = (digit)(ival & MASK); - ival >>= SHIFT; + *p++ = (digit)(ival & PyLong_MASK); + ival >>= PyLong_SHIFT; } } return (PyObject *)v; @@ -181,16 +181,16 @@ frac = frexp(dval, &expo); /* dval = frac*2**expo; 0.0 <= frac < 1.0 */ if (expo <= 0) return PyLong_FromLong(0L); - ndig = (expo-1) / SHIFT + 1; /* Number of 'digits' in result */ + ndig = (expo-1) / PyLong_SHIFT + 1; /* Number of 'digits' in result */ v = _PyLong_New(ndig); if (v == NULL) return NULL; - frac = ldexp(frac, (expo-1) % SHIFT + 1); + frac = ldexp(frac, (expo-1) % PyLong_SHIFT + 1); for (i = ndig; --i >= 0; ) { long bits = (long)frac; v->ob_digit[i] = (digit) bits; frac = frac - (double)bits; - frac = ldexp(frac, SHIFT); + frac = ldexp(frac, PyLong_SHIFT); } if (neg) Py_SIZE(v) = -(Py_SIZE(v)); @@ -237,8 +237,8 @@ } while (--i >= 0) { prev = x; - x = (x << SHIFT) + v->ob_digit[i]; - if ((x >> SHIFT) != prev) + x = (x << PyLong_SHIFT) + v->ob_digit[i]; + if ((x >> PyLong_SHIFT) != prev) goto overflow; } /* Haven't lost any bits, but casting to long requires extra care @@ -262,7 +262,7 @@ Returns -1 and sets an error condition if overflow occurs. */ Py_ssize_t -_PyLong_AsSsize_t(PyObject *vv) { +PyLong_AsSsize_t(PyObject *vv) { register PyLongObject *v; size_t x, prev; Py_ssize_t i; @@ -282,8 +282,8 @@ } while (--i >= 0) { prev = x; - x = (x << SHIFT) + v->ob_digit[i]; - if ((x >> SHIFT) != prev) + x = (x << PyLong_SHIFT) + v->ob_digit[i]; + if ((x >> PyLong_SHIFT) != prev) goto overflow; } /* Haven't lost any bits, but casting to a signed type requires @@ -336,8 +336,8 @@ } while (--i >= 0) { prev = x; - x = (x << SHIFT) + v->ob_digit[i]; - if ((x >> SHIFT) != prev) { + x = (x << PyLong_SHIFT) + v->ob_digit[i]; + if ((x >> PyLong_SHIFT) != prev) { PyErr_SetString(PyExc_OverflowError, "long int too large to convert"); return (unsigned long) -1; @@ -372,7 +372,7 @@ i = -i; } while (--i >= 0) { - x = (x << SHIFT) + v->ob_digit[i]; + x = (x << PyLong_SHIFT) + v->ob_digit[i]; } return x * sign; } @@ -402,8 +402,8 @@ if (ndigits > 0) { digit msd = v->ob_digit[ndigits - 1]; - result = (ndigits - 1) * SHIFT; - if (result / SHIFT != (size_t)(ndigits - 1)) + result = (ndigits - 1) * PyLong_SHIFT; + if (result / PyLong_SHIFT != (size_t)(ndigits - 1)) goto Overflow; do { ++result; @@ -473,9 +473,9 @@ } /* How many Python long digits do we need? We have - 8*numsignificantbytes bits, and each Python long digit has SHIFT + 8*numsignificantbytes bits, and each Python long digit has PyLong_SHIFT bits, so it's the ceiling of the quotient. */ - ndigits = (numsignificantbytes * 8 + SHIFT - 1) / SHIFT; + ndigits = (numsignificantbytes * 8 + PyLong_SHIFT - 1) / PyLong_SHIFT; if (ndigits > (size_t)INT_MAX) return PyErr_NoMemory(); v = _PyLong_New((int)ndigits); @@ -505,17 +505,17 @@ so needs to be prepended to accum. */ accum |= thisbyte << accumbits; accumbits += 8; - if (accumbits >= SHIFT) { + if (accumbits >= PyLong_SHIFT) { /* There's enough to fill a Python digit. */ assert(idigit < (int)ndigits); - v->ob_digit[idigit] = (digit)(accum & MASK); + v->ob_digit[idigit] = (digit)(accum & PyLong_MASK); ++idigit; - accum >>= SHIFT; - accumbits -= SHIFT; - assert(accumbits < SHIFT); + accum >>= PyLong_SHIFT; + accumbits -= PyLong_SHIFT; + assert(accumbits < PyLong_SHIFT); } } - assert(accumbits < SHIFT); + assert(accumbits < PyLong_SHIFT); if (accumbits) { assert(idigit < (int)ndigits); v->ob_digit[idigit] = (digit)accum; @@ -569,7 +569,7 @@ /* Copy over all the Python digits. It's crucial that every Python digit except for the MSD contribute - exactly SHIFT bits to the total, so first assert that the long is + exactly PyLong_SHIFT bits to the total, so first assert that the long is normalized. */ assert(ndigits == 0 || v->ob_digit[ndigits - 1] != 0); j = 0; @@ -579,15 +579,15 @@ for (i = 0; i < ndigits; ++i) { twodigits thisdigit = v->ob_digit[i]; if (do_twos_comp) { - thisdigit = (thisdigit ^ MASK) + carry; - carry = thisdigit >> SHIFT; - thisdigit &= MASK; + thisdigit = (thisdigit ^ PyLong_MASK) + carry; + carry = thisdigit >> PyLong_SHIFT; + thisdigit &= PyLong_MASK; } /* Because we're going LSB to MSB, thisdigit is more significant than what's already in accum, so needs to be prepended to accum. */ accum |= thisdigit << accumbits; - accumbits += SHIFT; + accumbits += PyLong_SHIFT; /* The most-significant digit may be (probably is) at least partly empty. */ @@ -598,9 +598,9 @@ * First shift conceptual sign bit to real sign bit. */ stwodigits s = (stwodigits)(thisdigit << - (8*sizeof(stwodigits) - SHIFT)); + (8*sizeof(stwodigits) - PyLong_SHIFT)); unsigned int nsignbits = 0; - while ((s < 0) == do_twos_comp && nsignbits < SHIFT) { + while ((s < 0) == do_twos_comp && nsignbits < PyLong_SHIFT) { ++nsignbits; s <<= 1; } @@ -680,7 +680,7 @@ #define NBITS_WANTED 57 PyLongObject *v; double x; - const double multiplier = (double)(1L << SHIFT); + const double multiplier = (double)(1L << PyLong_SHIFT); Py_ssize_t i; int sign; int nbitsneeded; @@ -707,10 +707,10 @@ while (i > 0 && nbitsneeded > 0) { --i; x = x * multiplier + (double)v->ob_digit[i]; - nbitsneeded -= SHIFT; + nbitsneeded -= PyLong_SHIFT; } /* There are i digits we didn't shift in. Pretending they're all - zeroes, the true value is x * 2**(i*SHIFT). */ + zeroes, the true value is x * 2**(i*PyLong_SHIFT). */ *exponent = i; assert(x > 0.0); return x * sign; @@ -735,10 +735,10 @@ /* 'e' initialized to -1 to silence gcc-4.0.x, but it should be set correctly after a successful _PyLong_AsScaledDouble() call */ assert(e >= 0); - if (e > INT_MAX / SHIFT) + if (e > INT_MAX / PyLong_SHIFT) goto overflow; errno = 0; - x = ldexp(x, e * SHIFT); + x = ldexp(x, e * PyLong_SHIFT); if (Py_OVERFLOWED(x)) goto overflow; return x; @@ -846,7 +846,7 @@ t = (unsigned PY_LONG_LONG)ival; while (t) { ++ndigits; - t >>= SHIFT; + t >>= PyLong_SHIFT; } v = _PyLong_New(ndigits); if (v != NULL) { @@ -854,8 +854,8 @@ Py_SIZE(v) = negative ? -ndigits : ndigits; t = (unsigned PY_LONG_LONG)ival; while (t) { - *p++ = (digit)(t & MASK); - t >>= SHIFT; + *p++ = (digit)(t & PyLong_MASK); + t >>= PyLong_SHIFT; } } return (PyObject *)v; @@ -874,15 +874,15 @@ t = (unsigned PY_LONG_LONG)ival; while (t) { ++ndigits; - t >>= SHIFT; + t >>= PyLong_SHIFT; } v = _PyLong_New(ndigits); if (v != NULL) { digit *p = v->ob_digit; Py_SIZE(v) = ndigits; while (ival) { - *p++ = (digit)(ival & MASK); - ival >>= SHIFT; + *p++ = (digit)(ival & PyLong_MASK); + ival >>= PyLong_SHIFT; } } return (PyObject *)v; @@ -891,7 +891,7 @@ /* Create a new long int object from a C Py_ssize_t. */ PyObject * -_PyLong_FromSsize_t(Py_ssize_t ival) +PyLong_FromSsize_t(Py_ssize_t ival) { Py_ssize_t bytes = ival; int one = 1; @@ -903,7 +903,7 @@ /* Create a new long int object from a C size_t. */ PyObject * -_PyLong_FromSize_t(size_t ival) +PyLong_FromSize_t(size_t ival) { size_t bytes = ival; int one = 1; @@ -1015,7 +1015,7 @@ i = -i; } while (--i >= 0) { - x = (x << SHIFT) + v->ob_digit[i]; + x = (x << PyLong_SHIFT) + v->ob_digit[i]; } return x * sign; } @@ -1069,14 +1069,14 @@ assert(m >= n); for (i = 0; i < n; ++i) { carry += x[i] + y[i]; - x[i] = carry & MASK; - carry >>= SHIFT; + x[i] = carry & PyLong_MASK; + carry >>= PyLong_SHIFT; assert((carry & 1) == carry); } for (; carry && i < m; ++i) { carry += x[i]; - x[i] = carry & MASK; - carry >>= SHIFT; + x[i] = carry & PyLong_MASK; + carry >>= PyLong_SHIFT; assert((carry & 1) == carry); } return carry; @@ -1095,14 +1095,14 @@ assert(m >= n); for (i = 0; i < n; ++i) { borrow = x[i] - y[i] - borrow; - x[i] = borrow & MASK; - borrow >>= SHIFT; + x[i] = borrow & PyLong_MASK; + borrow >>= PyLong_SHIFT; borrow &= 1; /* keep only 1 sign bit */ } for (; borrow && i < m; ++i) { borrow = x[i] - borrow; - x[i] = borrow & MASK; - borrow >>= SHIFT; + x[i] = borrow & PyLong_MASK; + borrow >>= PyLong_SHIFT; borrow &= 1; } return borrow; @@ -1130,8 +1130,8 @@ return NULL; for (i = 0; i < size_a; ++i) { carry += (twodigits)a->ob_digit[i] * n; - z->ob_digit[i] = (digit) (carry & MASK); - carry >>= SHIFT; + z->ob_digit[i] = (digit) (carry & PyLong_MASK); + carry >>= PyLong_SHIFT; } z->ob_digit[i] = (digit) carry; return long_normalize(z); @@ -1148,12 +1148,12 @@ { twodigits rem = 0; - assert(n > 0 && n <= MASK); + assert(n > 0 && n <= PyLong_MASK); pin += size; pout += size; while (--size >= 0) { digit hi; - rem = (rem << SHIFT) + *--pin; + rem = (rem << PyLong_SHIFT) + *--pin; *--pout = hi = (digit)(rem / n); rem -= hi * n; } @@ -1170,7 +1170,7 @@ const Py_ssize_t size = ABS(Py_SIZE(a)); PyLongObject *z; - assert(n > 0 && n <= MASK); + assert(n > 0 && n <= PyLong_MASK); z = _PyLong_New(size); if (z == NULL) return NULL; @@ -1208,9 +1208,9 @@ i >>= 1; } i = 5 + (addL ? 1 : 0); - j = size_a*SHIFT + bits-1; + j = size_a*PyLong_SHIFT + bits-1; sz = i + j / bits; - if (j / SHIFT < size_a || sz < i) { + if (j / PyLong_SHIFT < size_a || sz < i) { PyErr_SetString(PyExc_OverflowError, "long is too large to format"); return NULL; @@ -1239,7 +1239,7 @@ for (i = 0; i < size_a; ++i) { accum |= (twodigits)a->ob_digit[i] << accumbits; - accumbits += SHIFT; + accumbits += PyLong_SHIFT; assert(accumbits >= basebits); do { char cdigit = (char)(accum & (base - 1)); @@ -1264,7 +1264,7 @@ int power = 1; for (;;) { unsigned long newpow = powbase * (unsigned long)base; - if (newpow >> SHIFT) /* doesn't fit in a digit */ + if (newpow >> PyLong_SHIFT) /* doesn't fit in a digit */ break; powbase = (digit)newpow; ++power; @@ -1390,14 +1390,14 @@ while (_PyLong_DigitValue[Py_CHARMASK(*p)] < base) ++p; *str = p; - /* n <- # of Python digits needed, = ceiling(n/SHIFT). */ - n = (p - start) * bits_per_char + SHIFT - 1; + /* n <- # of Python digits needed, = ceiling(n/PyLong_SHIFT). */ + n = (p - start) * bits_per_char + PyLong_SHIFT - 1; if (n / bits_per_char < p - start) { PyErr_SetString(PyExc_ValueError, "long string too large to convert"); return NULL; } - n = n / SHIFT; + n = n / PyLong_SHIFT; z = _PyLong_New(n); if (z == NULL) return NULL; @@ -1412,16 +1412,16 @@ assert(k >= 0 && k < base); accum |= (twodigits)(k << bits_in_accum); bits_in_accum += bits_per_char; - if (bits_in_accum >= SHIFT) { - *pdigit++ = (digit)(accum & MASK); + if (bits_in_accum >= PyLong_SHIFT) { + *pdigit++ = (digit)(accum & PyLong_MASK); assert(pdigit - z->ob_digit <= (int)n); - accum >>= SHIFT; - bits_in_accum -= SHIFT; - assert(bits_in_accum < SHIFT); + accum >>= PyLong_SHIFT; + bits_in_accum -= PyLong_SHIFT; + assert(bits_in_accum < PyLong_SHIFT); } } if (bits_in_accum) { - assert(bits_in_accum <= SHIFT); + assert(bits_in_accum <= PyLong_SHIFT); *pdigit++ = (digit)accum; assert(pdigit - z->ob_digit <= (int)n); } @@ -1478,18 +1478,18 @@ is B**N-1. Consequently, if we have an N-digit input in base B, the worst- case number of Python digits needed to hold it is the smallest integer n s.t. - BASE**n-1 >= B**N-1 [or, adding 1 to both sides] - BASE**n >= B**N [taking logs to base BASE] - n >= log(B**N)/log(BASE) = N * log(B)/log(BASE) + PyLong_BASE**n-1 >= B**N-1 [or, adding 1 to both sides] + PyLong_BASE**n >= B**N [taking logs to base PyLong_BASE] + n >= log(B**N)/log(PyLong_BASE) = N * log(B)/log(PyLong_BASE) -The static array log_base_BASE[base] == log(base)/log(BASE) so we can compute +The static array log_base_PyLong_BASE[base] == log(base)/log(PyLong_BASE) so we can compute this quickly. A Python long with that much space is reserved near the start, and the result is computed into it. The input string is actually treated as being in base base**i (i.e., i digits are processed at a time), where two more static arrays hold: - convwidth_base[base] = the largest integer i such that base**i <= BASE + convwidth_base[base] = the largest integer i such that base**i <= PyLong_BASE convmultmax_base[base] = base ** convwidth_base[base] The first of these is the largest i such that i consecutive input digits @@ -1506,37 +1506,37 @@ Error analysis: as above, the number of Python digits `n` needed is worst- case - n >= N * log(B)/log(BASE) + n >= N * log(B)/log(PyLong_BASE) where `N` is the number of input digits in base `B`. This is computed via - size_z = (Py_ssize_t)((scan - str) * log_base_BASE[base]) + 1; + size_z = (Py_ssize_t)((scan - str) * log_base_PyLong_BASE[base]) + 1; below. Two numeric concerns are how much space this can waste, and whether -the computed result can be too small. To be concrete, assume BASE = 2**15, +the computed result can be too small. To be concrete, assume PyLong_BASE = 2**15, which is the default (and it's unlikely anyone changes that). Waste isn't a problem: provided the first input digit isn't 0, the difference between the worst-case input with N digits and the smallest input with N -digits is about a factor of B, but B is small compared to BASE so at most +digits is about a factor of B, but B is small compared to PyLong_BASE so at most one allocated Python digit can remain unused on that count. If -N*log(B)/log(BASE) is mathematically an exact integer, then truncating that +N*log(B)/log(PyLong_BASE) is mathematically an exact integer, then truncating that and adding 1 returns a result 1 larger than necessary. However, that can't happen: whenever B is a power of 2, long_from_binary_base() is called instead, and it's impossible for B**i to be an integer power of 2**15 when -B is not a power of 2 (i.e., it's impossible for N*log(B)/log(BASE) to be +B is not a power of 2 (i.e., it's impossible for N*log(B)/log(PyLong_BASE) to be an exact integer when B is not a power of 2, since B**i has a prime factor other than 2 in that case, but (2**15)**j's only prime factor is 2). -The computed result can be too small if the true value of N*log(B)/log(BASE) +The computed result can be too small if the true value of N*log(B)/log(PyLong_BASE) is a little bit larger than an exact integer, but due to roundoff errors (in -computing log(B), log(BASE), their quotient, and/or multiplying that by N) +computing log(B), log(PyLong_BASE), their quotient, and/or multiplying that by N) yields a numeric result a little less than that integer. Unfortunately, "how close can a transcendental function get to an integer over some range?" questions are generally theoretically intractable. Computer analysis via -continued fractions is practical: expand log(B)/log(BASE) via continued +continued fractions is practical: expand log(B)/log(PyLong_BASE) via continued fractions, giving a sequence i/j of "the best" rational approximations. Then -j*log(B)/log(BASE) is approximately equal to (the integer) i. This shows that +j*log(B)/log(PyLong_BASE) is approximately equal to (the integer) i. This shows that we can get very close to being in trouble, but very rarely. For example, 76573 is a denominator in one of the continued-fraction approximations to log(10)/log(2**15), and indeed: @@ -1562,19 +1562,19 @@ digit *pz, *pzstop; char* scan; - static double log_base_BASE[37] = {0.0e0,}; + static double log_base_PyLong_BASE[37] = {0.0e0,}; static int convwidth_base[37] = {0,}; static twodigits convmultmax_base[37] = {0,}; - if (log_base_BASE[base] == 0.0) { + if (log_base_PyLong_BASE[base] == 0.0) { twodigits convmax = base; int i = 1; - log_base_BASE[base] = log((double)base) / - log((double)BASE); + log_base_PyLong_BASE[base] = log((double)base) / + log((double)PyLong_BASE); for (;;) { twodigits next = convmax * base; - if (next > BASE) + if (next > PyLong_BASE) break; convmax = next; ++i; @@ -1594,7 +1594,7 @@ * need to initialize z->ob_digit -- no slot is read up before * being stored into. */ - size_z = (Py_ssize_t)((scan - str) * log_base_BASE[base]) + 1; + size_z = (Py_ssize_t)((scan - str) * log_base_PyLong_BASE[base]) + 1; /* Uncomment next line to test exceedingly rare copy code */ /* size_z = 1; */ assert(size_z > 0); @@ -1616,7 +1616,7 @@ for (i = 1; i < convwidth && str != scan; ++i, ++str) { c = (twodigits)(c * base + _PyLong_DigitValue[Py_CHARMASK(*str)]); - assert(c < BASE); + assert(c < PyLong_BASE); } convmult = convmultmax; @@ -1634,12 +1634,12 @@ pzstop = pz + Py_SIZE(z); for (; pz < pzstop; ++pz) { c += (twodigits)*pz * convmult; - *pz = (digit)(c & MASK); - c >>= SHIFT; + *pz = (digit)(c & PyLong_MASK); + c >>= PyLong_SHIFT; } /* carry off the current end? */ if (c) { - assert(c < BASE); + assert(c < PyLong_BASE); if (Py_SIZE(z) < size_z) { *pz = (digit)c; ++Py_SIZE(z); @@ -1783,7 +1783,7 @@ x_divrem(PyLongObject *v1, PyLongObject *w1, PyLongObject **prem) { Py_ssize_t size_v = ABS(Py_SIZE(v1)), size_w = ABS(Py_SIZE(w1)); - digit d = (digit) ((twodigits)BASE / (w1->ob_digit[size_w-1] + 1)); + digit d = (digit) ((twodigits)PyLong_BASE / (w1->ob_digit[size_w-1] + 1)); PyLongObject *v = mul1(v1, d); PyLongObject *w = mul1(w1, d); PyLongObject *a; @@ -1815,28 +1815,28 @@ break; }) if (vj == w->ob_digit[size_w-1]) - q = MASK; + q = PyLong_MASK; else - q = (((twodigits)vj << SHIFT) + v->ob_digit[j-1]) / + q = (((twodigits)vj << PyLong_SHIFT) + v->ob_digit[j-1]) / w->ob_digit[size_w-1]; while (w->ob_digit[size_w-2]*q > (( - ((twodigits)vj << SHIFT) + ((twodigits)vj << PyLong_SHIFT) + v->ob_digit[j-1] - q*w->ob_digit[size_w-1] - ) << SHIFT) + ) << PyLong_SHIFT) + v->ob_digit[j-2]) --q; for (i = 0; i < size_w && i+k < size_v; ++i) { twodigits z = w->ob_digit[i] * q; - digit zz = (digit) (z >> SHIFT); + digit zz = (digit) (z >> PyLong_SHIFT); carry += v->ob_digit[i+k] - z - + ((twodigits)zz << SHIFT); - v->ob_digit[i+k] = (digit)(carry & MASK); - carry = Py_ARITHMETIC_RIGHT_SHIFT(BASE_TWODIGITS_TYPE, - carry, SHIFT); + + ((twodigits)zz << PyLong_SHIFT); + v->ob_digit[i+k] = (digit)(carry & PyLong_MASK); + carry = Py_ARITHMETIC_RIGHT_SHIFT(PyLong_BASE_TWODIGITS_TYPE, + carry, PyLong_SHIFT); carry -= zz; } @@ -1853,10 +1853,10 @@ carry = 0; for (i = 0; i < size_w && i+k < size_v; ++i) { carry += v->ob_digit[i+k] + w->ob_digit[i]; - v->ob_digit[i+k] = (digit)(carry & MASK); + v->ob_digit[i+k] = (digit)(carry & PyLong_MASK); carry = Py_ARITHMETIC_RIGHT_SHIFT( - BASE_TWODIGITS_TYPE, - carry, SHIFT); + PyLong_BASE_TWODIGITS_TYPE, + carry, PyLong_SHIFT); } } } /* for j, k */ @@ -1940,13 +1940,13 @@ sign = -1; i = -(i); } -#define LONG_BIT_SHIFT (8*sizeof(long) - SHIFT) +#define LONG_BIT_PyLong_SHIFT (8*sizeof(long) - PyLong_SHIFT) /* The following loop produces a C long x such that (unsigned long)x is congruent to the absolute value of v modulo ULONG_MAX. The resulting x is nonzero if and only if v is. */ while (--i >= 0) { /* Force a native long #-bits (32 or 64) circular shift */ - x = ((x << SHIFT) & ~MASK) | ((x >> LONG_BIT_SHIFT) & MASK); + x = ((x << PyLong_SHIFT) & ~PyLong_MASK) | ((x >> LONG_BIT_PyLong_SHIFT) & PyLong_MASK); x += v->ob_digit[i]; /* If the addition above overflowed (thinking of x as unsigned), we compensate by incrementing. This preserves @@ -1954,7 +1954,7 @@ if ((unsigned long)x < v->ob_digit[i]) x++; } -#undef LONG_BIT_SHIFT +#undef LONG_BIT_PyLong_SHIFT x = x * sign; if (x == -1) x = -2; @@ -1984,13 +1984,13 @@ return NULL; for (i = 0; i < size_b; ++i) { carry += a->ob_digit[i] + b->ob_digit[i]; - z->ob_digit[i] = carry & MASK; - carry >>= SHIFT; + z->ob_digit[i] = carry & PyLong_MASK; + carry >>= PyLong_SHIFT; } for (; i < size_a; ++i) { carry += a->ob_digit[i]; - z->ob_digit[i] = carry & MASK; - carry >>= SHIFT; + z->ob_digit[i] = carry & PyLong_MASK; + carry >>= PyLong_SHIFT; } z->ob_digit[i] = carry; return long_normalize(z); @@ -2033,16 +2033,16 @@ return NULL; for (i = 0; i < size_b; ++i) { /* The following assumes unsigned arithmetic - works module 2**N for some N>SHIFT. */ + works module 2**N for some N>PyLong_SHIFT. */ borrow = a->ob_digit[i] - b->ob_digit[i] - borrow; - z->ob_digit[i] = borrow & MASK; - borrow >>= SHIFT; + z->ob_digit[i] = borrow & PyLong_MASK; + borrow >>= PyLong_SHIFT; borrow &= 1; /* Keep only one sign bit */ } for (; i < size_a; ++i) { borrow = a->ob_digit[i] - borrow; - z->ob_digit[i] = borrow & MASK; - borrow >>= SHIFT; + z->ob_digit[i] = borrow & PyLong_MASK; + borrow >>= PyLong_SHIFT; borrow &= 1; /* Keep only one sign bit */ } assert(borrow == 0); @@ -2140,9 +2140,9 @@ }) carry = *pz + f * f; - *pz++ = (digit)(carry & MASK); - carry >>= SHIFT; - assert(carry <= MASK); + *pz++ = (digit)(carry & PyLong_MASK); + carry >>= PyLong_SHIFT; + assert(carry <= PyLong_MASK); /* Now f is added in twice in each column of the * pyramid it appears. Same as adding f<<1 once. @@ -2150,18 +2150,18 @@ f <<= 1; while (pa < paend) { carry += *pz + *pa++ * f; - *pz++ = (digit)(carry & MASK); - carry >>= SHIFT; - assert(carry <= (MASK << 1)); + *pz++ = (digit)(carry & PyLong_MASK); + carry >>= PyLong_SHIFT; + assert(carry <= (PyLong_MASK << 1)); } if (carry) { carry += *pz; - *pz++ = (digit)(carry & MASK); - carry >>= SHIFT; + *pz++ = (digit)(carry & PyLong_MASK); + carry >>= PyLong_SHIFT; } if (carry) - *pz += (digit)(carry & MASK); - assert((carry >> SHIFT) == 0); + *pz += (digit)(carry & PyLong_MASK); + assert((carry >> PyLong_SHIFT) == 0); } } else { /* a is not the same as b -- gradeschool long mult */ @@ -2179,13 +2179,13 @@ while (pb < pbend) { carry += *pz + *pb++ * f; - *pz++ = (digit)(carry & MASK); - carry >>= SHIFT; - assert(carry <= MASK); + *pz++ = (digit)(carry & PyLong_MASK); + carry >>= PyLong_SHIFT; + assert(carry <= PyLong_MASK); } if (carry) - *pz += (digit)(carry & MASK); - assert((carry >> SHIFT) == 0); + *pz += (digit)(carry & PyLong_MASK); + assert((carry >> PyLong_SHIFT) == 0); } } return long_normalize(z); @@ -2304,7 +2304,7 @@ * 4. Subtract al*bl from the result, starting at shift. This may * underflow (borrow out of the high digit), but we don't care: * we're effectively doing unsigned arithmetic mod - * BASE**(sizea + sizeb), and so long as the *final* result fits, + * PyLong_BASE**(sizea + sizeb), and so long as the *final* result fits, * borrows and carries out of the high digit can be ignored. * 5. Subtract ah*bh from the result, starting at shift. * 6. Compute (ah+al)*(bh+bl), and add it into the result starting @@ -2431,7 +2431,7 @@ (asize == bsize ? c(bsize/2) : f(bsize/2)) digits + 2 bits. If asize < bsize, then we're asking whether asize digits >= f(bsize/2) digits + 2 bits. By #4, asize is at least f(bsize/2)+1 digits, so this in turn reduces to whether 1 -digit is enough to hold 2 bits. This is so since SHIFT=15 >= 2. If +digit is enough to hold 2 bits. This is so since PyLong_SHIFT=15 >= 2. If asize == bsize, then we're asking whether bsize digits is enough to hold c(bsize/2) digits + 2 bits, or equivalently (by #1) whether f(bsize/2) digits is enough to hold 2 bits. This is so if bsize >= 2, which holds because @@ -2643,15 +2643,15 @@ return NULL; } - /* True value is very close to ad/bd * 2**(SHIFT*(aexp-bexp)) */ + /* True value is very close to ad/bd * 2**(PyLong_SHIFT*(aexp-bexp)) */ ad /= bd; /* overflow/underflow impossible here */ aexp -= bexp; - if (aexp > INT_MAX / SHIFT) + if (aexp > INT_MAX / PyLong_SHIFT) goto overflow; - else if (aexp < -(INT_MAX / SHIFT)) + else if (aexp < -(INT_MAX / PyLong_SHIFT)) return PyFloat_FromDouble(0.0); /* underflow to 0 */ errno = 0; - ad = ldexp(ad, aexp * SHIFT); + ad = ldexp(ad, aexp * PyLong_SHIFT); if (Py_OVERFLOWED(ad)) /* ignore underflow to 0.0 */ goto overflow; return PyFloat_FromDouble(ad); @@ -2837,7 +2837,7 @@ for (i = Py_SIZE(b) - 1; i >= 0; --i) { digit bi = b->ob_digit[i]; - for (j = 1 << (SHIFT-1); j != 0; j >>= 1) { + for (j = 1 << (PyLong_SHIFT-1); j != 0; j >>= 1) { MULT(z, z, z) if (bi & j) MULT(z, a, z) @@ -2854,7 +2854,7 @@ for (i = Py_SIZE(b) - 1; i >= 0; --i) { const digit bi = b->ob_digit[i]; - for (j = SHIFT - 5; j >= 0; j -= 5) { + for (j = PyLong_SHIFT - 5; j >= 0; j -= 5) { const int index = (bi >> j) & 0x1f; for (k = 0; k < 5; ++k) MULT(z, z, z) @@ -2973,7 +2973,7 @@ "negative shift count"); goto rshift_error; } - wordshift = shiftby / SHIFT; + wordshift = shiftby / PyLong_SHIFT; newsize = ABS(Py_SIZE(a)) - wordshift; if (newsize <= 0) { z = _PyLong_New(0); @@ -2981,10 +2981,10 @@ Py_DECREF(b); return (PyObject *)z; } - loshift = shiftby % SHIFT; - hishift = SHIFT - loshift; + loshift = shiftby % PyLong_SHIFT; + hishift = PyLong_SHIFT - loshift; lomask = ((digit)1 << hishift) - 1; - himask = MASK ^ lomask; + himask = PyLong_MASK ^ lomask; z = _PyLong_New(newsize); if (z == NULL) goto rshift_error; @@ -3029,9 +3029,9 @@ "outrageous left shift count"); goto lshift_error; } - /* wordshift, remshift = divmod(shiftby, SHIFT) */ - wordshift = (int)shiftby / SHIFT; - remshift = (int)shiftby - wordshift * SHIFT; + /* wordshift, remshift = divmod(shiftby, PyLong_SHIFT) */ + wordshift = (int)shiftby / PyLong_SHIFT; + remshift = (int)shiftby - wordshift * PyLong_SHIFT; oldsize = ABS(a->ob_size); newsize = oldsize + wordshift; @@ -3047,8 +3047,8 @@ accum = 0; for (i = wordshift, j = 0; j < oldsize; i++, j++) { accum |= (twodigits)a->ob_digit[j] << remshift; - z->ob_digit[i] = (digit)(accum & MASK); - accum >>= SHIFT; + z->ob_digit[i] = (digit)(accum & PyLong_MASK); + accum >>= PyLong_SHIFT; } if (remshift) z->ob_digit[newsize-1] = (digit)accum; @@ -3069,7 +3069,7 @@ int op, /* '&', '|', '^' */ PyLongObject *b) { - digit maska, maskb; /* 0 or MASK */ + digit maska, maskb; /* 0 or PyLong_MASK */ int negz; Py_ssize_t size_a, size_b, size_z; PyLongObject *z; @@ -3081,7 +3081,7 @@ a = (PyLongObject *) long_invert(a); if (a == NULL) return NULL; - maska = MASK; + maska = PyLong_MASK; } else { Py_INCREF(a); @@ -3093,7 +3093,7 @@ Py_DECREF(a); return NULL; } - maskb = MASK; + maskb = PyLong_MASK; } else { Py_INCREF(b); @@ -3104,23 +3104,23 @@ switch (op) { case '^': if (maska != maskb) { - maska ^= MASK; + maska ^= PyLong_MASK; negz = -1; } break; case '&': if (maska && maskb) { op = '|'; - maska ^= MASK; - maskb ^= MASK; + maska ^= PyLong_MASK; + maskb ^= PyLong_MASK; negz = -1; } break; case '|': if (maska || maskb) { op = '&'; - maska ^= MASK; - maskb ^= MASK; + maska ^= PyLong_MASK; + maskb ^= PyLong_MASK; negz = -1; } break; Modified: python/branches/trunk-math/Objects/object.c ============================================================================== --- python/branches/trunk-math/Objects/object.c (original) +++ python/branches/trunk-math/Objects/object.c Sun Jan 27 19:55:42 2008 @@ -1349,12 +1349,15 @@ dictptr = (PyObject **) ((char *)obj + dictoffset); dict = *dictptr; if (dict != NULL) { + Py_INCREF(dict); res = PyDict_GetItem(dict, name); if (res != NULL) { Py_INCREF(res); Py_XDECREF(descr); + Py_DECREF(dict); goto done; } + Py_DECREF(dict); } } @@ -1435,12 +1438,14 @@ *dictptr = dict; } if (dict != NULL) { + Py_INCREF(dict); if (value == NULL) res = PyDict_DelItem(dict, name); else res = PyDict_SetItem(dict, name, value); if (res < 0 && PyErr_ExceptionMatches(PyExc_KeyError)) PyErr_SetObject(PyExc_AttributeError, name); + Py_DECREF(dict); goto done; } } Modified: python/branches/trunk-math/Objects/setobject.c ============================================================================== --- python/branches/trunk-math/Objects/setobject.c (original) +++ python/branches/trunk-math/Objects/setobject.c Sun Jan 27 19:55:42 2008 @@ -912,7 +912,7 @@ { PyObject *key, *it; - if (PyAnySet_CheckExact(other)) + if (PyAnySet_Check(other)) return set_merge(so, other); if (PyDict_CheckExact(other)) { @@ -1207,7 +1207,7 @@ if (result == NULL) return NULL; - if (PyAnySet_CheckExact(other)) { + if (PyAnySet_Check(other)) { Py_ssize_t pos = 0; setentry *entry; @@ -1398,7 +1398,7 @@ if ((PyObject *)so == other) return set_clear_internal(so); - if (PyAnySet_CheckExact(other)) { + if (PyAnySet_Check(other)) { setentry *entry; Py_ssize_t pos = 0; @@ -1447,7 +1447,7 @@ setentry *entry; Py_ssize_t pos = 0; - if (!PyAnySet_CheckExact(other) && !PyDict_CheckExact(other)) { + if (!PyAnySet_Check(other) && !PyDict_CheckExact(other)) { result = set_copy(so); if (result == NULL) return NULL; @@ -1554,7 +1554,7 @@ Py_RETURN_NONE; } - if (PyAnySet_CheckExact(other)) { + if (PyAnySet_Check(other)) { Py_INCREF(other); otherset = (PySetObject *)other; } else { @@ -1637,7 +1637,7 @@ setentry *entry; Py_ssize_t pos = 0; - if (!PyAnySet_CheckExact(other)) { + if (!PyAnySet_Check(other)) { PyObject *tmp, *result; tmp = make_new_set(&PySet_Type, other); if (tmp == NULL) @@ -1666,7 +1666,7 @@ { PyObject *tmp, *result; - if (!PyAnySet_CheckExact(other)) { + if (!PyAnySet_Check(other)) { tmp = make_new_set(&PySet_Type, other); if (tmp == NULL) return NULL; Modified: python/branches/trunk-math/Objects/typeobject.c ============================================================================== --- python/branches/trunk-math/Objects/typeobject.c (original) +++ python/branches/trunk-math/Objects/typeobject.c Sun Jan 27 19:55:42 2008 @@ -58,7 +58,7 @@ PyObject *raw, *ref; Py_ssize_t i, n; - if(!PyType_HasFeature(type, Py_TPFLAGS_VALID_VERSION_TAG)) + if (!PyType_HasFeature(type, Py_TPFLAGS_VALID_VERSION_TAG)) return; raw = type->tp_subclasses; @@ -94,7 +94,7 @@ Py_ssize_t i, n; int clear = 0; - if(!PyType_HasFeature(type, Py_TPFLAGS_HAVE_VERSION_TAG)) + if (!PyType_HasFeature(type, Py_TPFLAGS_HAVE_VERSION_TAG)) return; n = PyTuple_GET_SIZE(bases); @@ -1388,8 +1388,8 @@ PyObject *bases, *result; PyObject *to_merge, *bases_aslist; - if(type->tp_dict == NULL) { - if(PyType_Ready(type) < 0) + if (type->tp_dict == NULL) { + if (PyType_Ready(type) < 0) return NULL; } @@ -2321,7 +2321,7 @@ unsigned int h; if (MCACHE_CACHEABLE_NAME(name) && - PyType_HasFeature(type,Py_TPFLAGS_VALID_VERSION_TAG)) { + PyType_HasFeature(type, Py_TPFLAGS_VALID_VERSION_TAG)) { /* fast path */ h = MCACHE_HASH_METHOD(type, name); if (method_cache[h].version == type->tp_version_tag && Modified: python/branches/trunk-math/Objects/unicodeobject.c ============================================================================== --- python/branches/trunk-math/Objects/unicodeobject.c (original) +++ python/branches/trunk-math/Objects/unicodeobject.c Sun Jan 27 19:55:42 2008 @@ -397,6 +397,57 @@ return (PyObject *)unicode; } +PyObject *PyUnicode_FromStringAndSize(const char *u, Py_ssize_t size) +{ + PyUnicodeObject *unicode; + /* If the Unicode data is known at construction time, we can apply + some optimizations which share commonly used objects. + Also, this means the input must be UTF-8, so fall back to the + UTF-8 decoder at the end. */ + if (u != NULL) { + + /* Optimization for empty strings */ + if (size == 0 && unicode_empty != NULL) { + Py_INCREF(unicode_empty); + return (PyObject *)unicode_empty; + } + + /* Single characters are shared when using this constructor. + Restrict to ASCII, since the input must be UTF-8. */ + if (size == 1 && Py_CHARMASK(*u) < 128) { + unicode = unicode_latin1[Py_CHARMASK(*u)]; + if (!unicode) { + unicode = _PyUnicode_New(1); + if (!unicode) + return NULL; + unicode->str[0] = Py_CHARMASK(*u); + unicode_latin1[Py_CHARMASK(*u)] = unicode; + } + Py_INCREF(unicode); + return (PyObject *)unicode; + } + + return PyUnicode_DecodeUTF8(u, size, NULL); + } + + unicode = _PyUnicode_New(size); + if (!unicode) + return NULL; + + return (PyObject *)unicode; +} + +PyObject *PyUnicode_FromString(const char *u) +{ + size_t size = strlen(u); + if (size > PY_SSIZE_T_MAX) { + PyErr_SetString(PyExc_OverflowError, "input too long"); + return NULL; + } + + return PyUnicode_FromStringAndSize(u, size); +} + #ifdef HAVE_WCHAR_H PyObject *PyUnicode_FromWideChar(register const wchar_t *w, @@ -429,6 +480,420 @@ return (PyObject *)unicode; } +static void +makefmt(char *fmt, int longflag, int size_tflag, int zeropad, int width, int precision, char c) +{ + *fmt++ = '%'; + if (width) { + if (zeropad) + *fmt++ = '0'; + fmt += sprintf(fmt, "%d", width); + } + if (precision) + fmt += sprintf(fmt, ".%d", precision); + if (longflag) + *fmt++ = 'l'; + else if (size_tflag) { + char *f = PY_FORMAT_SIZE_T; + while (*f) + *fmt++ = *f++; + } + *fmt++ = c; + *fmt = '\0'; +} + +#define appendstring(string) {for (copy = string;*copy;) *s++ = *copy++;} + +PyObject * +PyUnicode_FromFormatV(const char *format, va_list vargs) +{ + va_list count; + Py_ssize_t callcount = 0; + PyObject **callresults = NULL; + PyObject **callresult = NULL; + Py_ssize_t n = 0; + int width = 0; + int precision = 0; + int zeropad; + const char* f; + Py_UNICODE *s; + PyObject *string; + /* used by sprintf */ + char buffer[21]; + /* use abuffer instead of buffer, if we need more space + * (which can happen if there's a format specifier with width). */ + char *abuffer = NULL; + char *realbuffer; + Py_ssize_t abuffersize = 0; + char fmt[60]; /* should be enough for %0width.precisionld */ + const char *copy; + +#ifdef VA_LIST_IS_ARRAY + Py_MEMCPY(count, vargs, sizeof(va_list)); +#else +#ifdef __va_copy + __va_copy(count, vargs); +#else + count = vargs; +#endif +#endif + /* step 1: count the number of %S/%R format specifications + * (we call PyObject_Str()/PyObject_Repr() for these objects + * once during step 3 and put the result in an array) */ + for (f = format; *f; f++) { + if (*f == '%' && (*(f+1)=='S' || *(f+1)=='R')) + ++callcount; + } + /* step 2: allocate memory for the results of + * PyObject_Str()/PyObject_Repr() calls */ + if (callcount) { + callresults = PyMem_Malloc(sizeof(PyObject *)*callcount); + if (!callresults) { + PyErr_NoMemory(); + return NULL; + } + callresult = callresults; + } + /* step 3: figure out how large a buffer we need */ + for (f = format; *f; f++) { + if (*f == '%') { + const char* p = f; + width = 0; + while (isdigit(*f)) + width = (width*10) + *f++ - '0'; + while (*++f && *f != '%' && !isalpha(*f)) + ; + + /* skip the 'l' or 'z' in {%ld, %zd, %lu, %zu} since + * they don't affect the amount of space we reserve. + */ + if ((*f == 'l' || *f == 'z') && + (f[1] == 'd' || f[1] == 'u')) + ++f; + + switch (*f) { + case 'c': + (void)va_arg(count, int); + /* fall through... */ + case '%': + n++; + break; + case 'd': case 'u': case 'i': case 'x': + (void) va_arg(count, int); + /* 20 bytes is enough to hold a 64-bit + integer. Decimal takes the most space. + This isn't enough for octal. + If a width is specified we need more + (which we allocate later). */ + if (width < 20) + width = 20; + n += width; + if (abuffersize < width) + abuffersize = width; + break; + case 's': + { + /* UTF-8 */ + unsigned char*s; + s = va_arg(count, unsigned char*); + while (*s) { + if (*s < 128) { + n++; s++; + } else if (*s < 0xc0) { + /* invalid UTF-8 */ + n++; s++; + } else if (*s < 0xc0) { + n++; + s++; if(!*s)break; + s++; + } else if (*s < 0xe0) { + n++; + s++; if(!*s)break; + s++; if(!*s)break; + s++; + } else { + #ifdef Py_UNICODE_WIDE + n++; + #else + n+=2; + #endif + s++; if(!*s)break; + s++; if(!*s)break; + s++; if(!*s)break; + s++; + } + } + break; + } + case 'U': + { + PyObject *obj = va_arg(count, PyObject *); + assert(obj && PyUnicode_Check(obj)); + n += PyUnicode_GET_SIZE(obj); + break; + } + case 'V': + { + PyObject *obj = va_arg(count, PyObject *); + const char *str = va_arg(count, const char *); + assert(obj || str); + assert(!obj || PyUnicode_Check(obj)); + if (obj) + n += PyUnicode_GET_SIZE(obj); + else + n += strlen(str); + break; + } + case 'S': + { + PyObject *obj = va_arg(count, PyObject *); + PyObject *str; + assert(obj); + str = PyObject_Str(obj); + if (!str) + goto fail; + n += PyUnicode_GET_SIZE(str); + /* Remember the str and switch to the next slot */ + *callresult++ = str; + break; + } + case 'R': + { + PyObject *obj = va_arg(count, PyObject *); + PyObject *repr; + assert(obj); + repr = PyObject_Repr(obj); + if (!repr) + goto fail; + n += PyUnicode_GET_SIZE(repr); + /* Remember the repr and switch to the next slot */ + *callresult++ = repr; + break; + } + case 'p': + (void) va_arg(count, int); + /* maximum 64-bit pointer representation: + * 0xffffffffffffffff + * so 19 characters is enough. + * XXX I count 18 -- what's the extra for? + */ + n += 19; + break; + default: + /* if we stumble upon an unknown + formatting code, copy the rest of + the format string to the output + string. (we cannot just skip the + code, since there's no way to know + what's in the argument list) */ + n += strlen(p); + goto expand; + } + } else + n++; + } + expand: + if (abuffersize > 20) { + abuffer = PyMem_Malloc(abuffersize); + if (!abuffer) { + PyErr_NoMemory(); + goto fail; + } + realbuffer = abuffer; + } + else + realbuffer = buffer; + /* step 4: fill the buffer */ + /* Since we've analyzed how much space we need for the worst case, + we don't have to resize the string. + There can be no errors beyond this point. */ + string = PyUnicode_FromUnicode(NULL, n); + if (!string) + goto fail; + + s = PyUnicode_AS_UNICODE(string); + callresult = callresults; + + for (f = format; *f; f++) { + if (*f == '%') { + const char* p = f++; + int longflag = 0; + int size_tflag = 0; + zeropad = (*f == '0'); + /* parse the width.precision part */ + width = 0; + while (isdigit(*f)) + width = (width*10) + *f++ - '0'; + precision = 0; + if (*f == '.') { + f++; + while (isdigit(*f)) + precision = (precision*10) + *f++ - '0'; + } + /* handle the long flag, but only for %ld and %lu. + others can be added when necessary. */ + if (*f == 'l' && (f[1] == 'd' || f[1] == 'u')) { + longflag = 1; + ++f; + } + /* handle the size_t flag. */ + if (*f == 'z' && (f[1] == 'd' || f[1] == 'u')) { + size_tflag = 1; + ++f; + } + + switch (*f) { + case 'c': + *s++ = va_arg(vargs, int); + break; + case 'd': + makefmt(fmt, longflag, size_tflag, zeropad, width, precision, 'd'); + if (longflag) + sprintf(realbuffer, fmt, va_arg(vargs, long)); + else if (size_tflag) + sprintf(realbuffer, fmt, va_arg(vargs, Py_ssize_t)); + else + sprintf(realbuffer, fmt, va_arg(vargs, int)); + appendstring(realbuffer); + break; + case 'u': + makefmt(fmt, longflag, size_tflag, zeropad, width, precision, 'u'); + if (longflag) + sprintf(realbuffer, fmt, va_arg(vargs, unsigned long)); + else if (size_tflag) + sprintf(realbuffer, fmt, va_arg(vargs, size_t)); + else + sprintf(realbuffer, fmt, va_arg(vargs, unsigned int)); + appendstring(realbuffer); + break; + case 'i': + makefmt(fmt, 0, 0, zeropad, width, precision, 'i'); + sprintf(realbuffer, fmt, va_arg(vargs, int)); + appendstring(realbuffer); + break; + case 'x': + makefmt(fmt, 0, 0, zeropad, width, precision, 'x'); + sprintf(realbuffer, fmt, va_arg(vargs, int)); + appendstring(realbuffer); + break; + case 's': + { + /* Parameter must be UTF-8 encoded. + In case of encoding errors, use + the replacement character. */ + PyObject *u; + p = va_arg(vargs, char*); + u = PyUnicode_DecodeUTF8(p, strlen(p), + "replace"); + if (!u) + goto fail; + Py_UNICODE_COPY(s, PyUnicode_AS_UNICODE(u), + PyUnicode_GET_SIZE(u)); + s += PyUnicode_GET_SIZE(u); + Py_DECREF(u); + break; + } + case 'U': + { + PyObject *obj = va_arg(vargs, PyObject *); + Py_ssize_t size = PyUnicode_GET_SIZE(obj); + Py_UNICODE_COPY(s, PyUnicode_AS_UNICODE(obj), size); + s += size; + break; + } + case 'V': + { + PyObject *obj = va_arg(vargs, PyObject *); + const char *str = va_arg(vargs, const char *); + if (obj) { + Py_ssize_t size = PyUnicode_GET_SIZE(obj); + Py_UNICODE_COPY(s, PyUnicode_AS_UNICODE(obj), size); + s += size; + } else { + appendstring(str); + } + break; + } + case 'S': + case 'R': + { + Py_UNICODE *ucopy; + Py_ssize_t usize; + Py_ssize_t upos; + /* unused, since we already have the result */ + (void) va_arg(vargs, PyObject *); + ucopy = PyUnicode_AS_UNICODE(*callresult); + usize = PyUnicode_GET_SIZE(*callresult); + for (upos = 0; upos forget it */ + Py_DECREF(*callresult); + /* switch to next unicode()/repr() result */ + ++callresult; + break; + } + case 'p': + sprintf(buffer, "%p", va_arg(vargs, void*)); + /* %p is ill-defined: ensure leading 0x. */ + if (buffer[1] == 'X') + buffer[1] = 'x'; + else if (buffer[1] != 'x') { + memmove(buffer+2, buffer, strlen(buffer)+1); + buffer[0] = '0'; + buffer[1] = 'x'; + } + appendstring(buffer); + break; + case '%': + *s++ = '%'; + break; + default: + appendstring(p); + goto end; + } + } else + *s++ = *f; + } + + end: + if (callresults) + PyMem_Free(callresults); + if (abuffer) + PyMem_Free(abuffer); + _PyUnicode_Resize(&string, s - PyUnicode_AS_UNICODE(string)); + return string; + fail: + if (callresults) { + PyObject **callresult2 = callresults; + while (callresult2 < callresult) { + Py_DECREF(*callresult2); + ++callresult2; + } + PyMem_Free(callresults); + } + if (abuffer) + PyMem_Free(abuffer); + return NULL; +} + +#undef appendstring + +PyObject * +PyUnicode_FromFormat(const char *format, ...) +{ + PyObject* ret; + va_list vargs; + +#ifdef HAVE_STDARG_PROTOTYPES + va_start(vargs, format); +#else + va_start(vargs); +#endif + ret = PyUnicode_FromFormatV(format, vargs); + va_end(vargs); + return ret; +} + Py_ssize_t PyUnicode_AsWideChar(PyUnicodeObject *unicode, wchar_t *w, Py_ssize_t size) Modified: python/branches/trunk-math/Parser/tokenizer.c ============================================================================== --- python/branches/trunk-math/Parser/tokenizer.c (original) +++ python/branches/trunk-math/Parser/tokenizer.c Sun Jan 27 19:55:42 2008 @@ -605,6 +605,7 @@ for (s = str;; s++) { if (*s == '\0') break; else if (*s == '\n') { + assert(lineno < 2); newl[lineno] = s; lineno++; if (lineno == 2) break; @@ -1563,7 +1564,7 @@ there, as it must be empty for PGEN, and we can check for PGEN only in this file. */ -#ifdef PGEN +#if defined(PGEN) || !defined(Py_USING_UNICODE) char* PyTokenizer_RestoreEncoding(struct tok_state* tok, int len, int* offset) { @@ -1584,7 +1585,6 @@ } return ret; } - char * PyTokenizer_RestoreEncoding(struct tok_state* tok, int len, int *offset) { Modified: python/branches/trunk-math/Python/bltinmodule.c ============================================================================== --- python/branches/trunk-math/Python/bltinmodule.c (original) +++ python/branches/trunk-math/Python/bltinmodule.c Sun Jan 27 19:55:42 2008 @@ -1245,11 +1245,14 @@ "%s() got an unexpected keyword argument", name); return NULL; } + Py_INCREF(keyfunc); } it = PyObject_GetIter(v); - if (it == NULL) + if (it == NULL) { + Py_XDECREF(keyfunc); return NULL; + } maxitem = NULL; /* the result */ maxval = NULL; /* the value associated with the result */ @@ -1298,6 +1301,7 @@ else Py_DECREF(maxval); Py_DECREF(it); + Py_XDECREF(keyfunc); return maxitem; Fail_it_item_and_val: @@ -1308,6 +1312,7 @@ Py_XDECREF(maxval); Py_XDECREF(maxitem); Py_DECREF(it); + Py_XDECREF(keyfunc); return NULL; } Modified: python/branches/trunk-math/Python/ceval.c ============================================================================== --- python/branches/trunk-math/Python/ceval.c (original) +++ python/branches/trunk-math/Python/ceval.c Sun Jan 27 19:55:42 2008 @@ -2066,6 +2066,7 @@ "__import__ not found"); break; } + Py_INCREF(x); v = POP(); u = TOP(); if (PyInt_AsLong(u) != -1 || PyErr_Occurred()) @@ -2087,11 +2088,14 @@ Py_DECREF(u); if (w == NULL) { u = POP(); + Py_DECREF(x); x = NULL; break; } READ_TIMESTAMP(intr0); - x = PyEval_CallObject(x, w); + v = x; + x = PyEval_CallObject(v, w); + Py_DECREF(v); READ_TIMESTAMP(intr1); Py_DECREF(w); SET_TOP(x); @@ -2488,7 +2492,7 @@ else { /* This check is expensive! */ if (PyErr_Occurred()) { - char buf[1024]; + char buf[128]; sprintf(buf, "Stack unwind with exception " "set and why=%d", why); Py_FatalError(buf); Modified: python/branches/trunk-math/Python/compile.c ============================================================================== --- python/branches/trunk-math/Python/compile.c (original) +++ python/branches/trunk-math/Python/compile.c Sun Jan 27 19:55:42 2008 @@ -1598,8 +1598,11 @@ basicblock *loop, *orelse, *end, *anchor = NULL; int constant = expr_constant(s->v.While.test); - if (constant == 0) + if (constant == 0) { + if (s->v.While.orelse) + VISIT_SEQ(c, stmt, s->v.While.orelse); return 1; + } loop = compiler_new_block(c); end = compiler_new_block(c); if (constant == -1) { Modified: python/branches/trunk-math/Python/dynload_win.c ============================================================================== --- python/branches/trunk-math/Python/dynload_win.c (original) +++ python/branches/trunk-math/Python/dynload_win.c Sun Jan 27 19:55:42 2008 @@ -171,11 +171,16 @@ HINSTANCE hDLL = NULL; char pathbuf[260]; LPTSTR dummy; + unsigned int old_mode; /* We use LoadLibraryEx so Windows looks for dependent DLLs in directory of pathname first. However, Windows95 can sometimes not work correctly unless the absolute path is used. If GetFullPathName() fails, the LoadLibrary will certainly fail too, so use its error code */ + + /* Don't display a message box when Python can't load a DLL */ + old_mode = SetErrorMode(SEM_FAILCRITICALERRORS); + if (GetFullPathName(pathname, sizeof(pathbuf), pathbuf, @@ -183,6 +188,10 @@ /* XXX This call doesn't exist in Windows CE */ hDLL = LoadLibraryEx(pathname, NULL, LOAD_WITH_ALTERED_SEARCH_PATH); + + /* restore old error mode settings */ + SetErrorMode(old_mode); + if (hDLL==NULL){ char errBuf[256]; unsigned int errorCode; Modified: python/branches/trunk-math/setup.py ============================================================================== --- python/branches/trunk-math/setup.py (original) +++ python/branches/trunk-math/setup.py Sun Jan 27 19:55:42 2008 @@ -4,6 +4,7 @@ __version__ = "$Revision$" import sys, os, imp, re, optparse +from glob import glob from distutils import log from distutils import sysconfig @@ -142,12 +143,20 @@ self.distribution.scripts = [os.path.join(srcdir, filename) for filename in self.distribution.scripts] + # Python header files + headers = glob("Include/*.h") + ["pyconfig.h"] + for ext in self.extensions[:]: ext.sources = [ find_module_file(filename, moddirlist) for filename in ext.sources ] if ext.depends is not None: ext.depends = [find_module_file(filename, alldirlist) for filename in ext.depends] + else: + ext.depends = [] + # re-compile extensions if a header file has been changed + ext.depends.extend(headers) + ext.include_dirs.append( '.' ) # to get config.h for incdir in incdirlist: ext.include_dirs.append( os.path.join(srcdir, incdir) ) @@ -420,6 +429,8 @@ exts.append( Extension("_heapq", ["_heapqmodule.c"]) ) # operator.add() and similar goodies exts.append( Extension('operator', ['operator.c']) ) + # Python 3.0 _fileio module + exts.append( Extension("_fileio", ["_fileio.c"]) ) # _functools exts.append( Extension("_functools", ["_functoolsmodule.c"]) ) # Python C API test module From python-checkins at python.org Sun Jan 27 20:01:46 2008 From: python-checkins at python.org (christian.heimes) Date: Sun, 27 Jan 2008 20:01:46 +0100 (CET) Subject: [Python-checkins] r60370 - python/trunk/Lib/optparse.py Message-ID: <20080127190146.363271E4021@bag.python.org> Author: christian.heimes Date: Sun Jan 27 20:01:45 2008 New Revision: 60370 Modified: python/trunk/Lib/optparse.py Log: Change isbasestring function as discussed on the cvs list a while ago Modified: python/trunk/Lib/optparse.py ============================================================================== --- python/trunk/Lib/optparse.py (original) +++ python/trunk/Lib/optparse.py Sun Jan 27 20:01:45 2008 @@ -823,12 +823,14 @@ except NameError: (True, False) = (1, 0) -def isbasestring(x): - try: +try: + basestring +except NameError: + def isbasestring(x): + return isinstance(x, (types.StringType, types.UnicodeType)) +else: + def isbasestring(x): return isinstance(x, basestring) - except: - return isinstance(x, types.StringType) or isinstance(x, types.UnicodeType) - class Values: From buildbot at python.org Sun Jan 27 20:01:48 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 27 Jan 2008 19:01:48 +0000 Subject: [Python-checkins] buildbot failure in x86 mvlgcc trunk Message-ID: <20080127190148.57B571E4019@bag.python.org> The Buildbot has detected a new failure of x86 mvlgcc trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20mvlgcc%20trunk/builds/1346 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-linux Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: georg.brandl,neal.norwitz BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_socket_ssl make: *** [buildbottest] Fehler 1 sincerely, -The Buildbot From python-checkins at python.org Sun Jan 27 20:02:00 2008 From: python-checkins at python.org (christian.heimes) Date: Sun, 27 Jan 2008 20:02:00 +0100 (CET) Subject: [Python-checkins] r60371 - python/branches/release25-maint/Lib/optparse.py Message-ID: <20080127190200.2D9CE1E4022@bag.python.org> Author: christian.heimes Date: Sun Jan 27 20:01:59 2008 New Revision: 60371 Modified: python/branches/release25-maint/Lib/optparse.py Log: Change isbasestring function as discussed on the cvs list a while ago Modified: python/branches/release25-maint/Lib/optparse.py ============================================================================== --- python/branches/release25-maint/Lib/optparse.py (original) +++ python/branches/release25-maint/Lib/optparse.py Sun Jan 27 20:01:59 2008 @@ -823,11 +823,14 @@ except NameError: (True, False) = (1, 0) -def isbasestring(x): - try: +try: + basestring +except NameError: + def isbasestring(x): + return isinstance(x, (types.StringType, types.UnicodeType)) +else: + def isbasestring(x): return isinstance(x, basestring) - except: - return isinstance(x, types.StringType) or isinstance(x, types.UnicodeType) class Values: From buildbot at python.org Sun Jan 27 20:07:04 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 27 Jan 2008 19:07:04 +0000 Subject: [Python-checkins] buildbot failure in PPC64 Debian 2.5 Message-ID: <20080127190704.86CE01E401E@bag.python.org> The Buildbot has detected a new failure of PPC64 Debian 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/PPC64%20Debian%202.5/builds/153 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc64 Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: christian.heimes BUILD FAILED: failed configure sincerely, -The Buildbot From python-checkins at python.org Sun Jan 27 21:03:16 2008 From: python-checkins at python.org (neal.norwitz) Date: Sun, 27 Jan 2008 21:03:16 +0100 (CET) Subject: [Python-checkins] r60372 - python/trunk/Lib/test/test_xmlrpc.py Message-ID: <20080127200316.5F0CC1E4014@bag.python.org> Author: neal.norwitz Date: Sun Jan 27 21:03:13 2008 New Revision: 60372 Modified: python/trunk/Lib/test/test_xmlrpc.py Log: socket.error doesn't have a headers attribute like ProtocolError. Handle that situation where we catch socket.errors. Modified: python/trunk/Lib/test/test_xmlrpc.py ============================================================================== --- python/trunk/Lib/test/test_xmlrpc.py (original) +++ python/trunk/Lib/test/test_xmlrpc.py Sun Jan 27 21:03:13 2008 @@ -397,7 +397,7 @@ # ignore failures due to non-blocking socket 'unavailable' errors if not is_unavailable_exception(e): # protocol error; provide additional information in test output - self.fail("%s\n%s" % (e, e.headers)) + self.fail("%s\n%s" % (e, getattr(e, "headers", ""))) # [ch] The test 404 is causing lots of false alarms. def XXXtest_404(self): @@ -423,7 +423,7 @@ # ignore failures due to non-blocking socket 'unavailable' errors if not is_unavailable_exception(e): # protocol error; provide additional information in test output - self.fail("%s\n%s" % (e, e.headers)) + self.fail("%s\n%s" % (e, getattr(e, "headers", ""))) def test_introspection2(self): try: @@ -435,7 +435,7 @@ # ignore failures due to non-blocking socket 'unavailable' errors if not is_unavailable_exception(e): # protocol error; provide additional information in test output - self.fail("%s\n%s" % (e, e.headers)) + self.fail("%s\n%s" % (e, getattr(e, "headers", ""))) def test_introspection3(self): try: @@ -447,7 +447,7 @@ # ignore failures due to non-blocking socket 'unavailable' errors if not is_unavailable_exception(e): # protocol error; provide additional information in test output - self.fail("%s\n%s" % (e, e.headers)) + self.fail("%s\n%s" % (e, getattr(e, "headers", ""))) def test_introspection4(self): # the SimpleXMLRPCServer doesn't support signatures, but @@ -460,7 +460,7 @@ # ignore failures due to non-blocking socket 'unavailable' errors if not is_unavailable_exception(e): # protocol error; provide additional information in test output - self.fail("%s\n%s" % (e, e.headers)) + self.fail("%s\n%s" % (e, getattr(e, "headers", ""))) def test_multicall(self): try: @@ -477,7 +477,7 @@ # ignore failures due to non-blocking socket 'unavailable' errors if not is_unavailable_exception(e): # protocol error; provide additional information in test output - self.fail("%s\n%s" % (e, e.headers)) + self.fail("%s\n%s" % (e, getattr(e, "headers", ""))) def test_non_existing_multicall(self): try: @@ -498,7 +498,7 @@ # ignore failures due to non-blocking socket 'unavailable' errors if not is_unavailable_exception(e): # protocol error; provide additional information in test output - self.fail("%s\n%s" % (e, e.headers)) + self.fail("%s\n%s" % (e, getattr(e, "headers", ""))) def test_dotted_attribute(self): # this will raise AttirebuteError because code don't want us to use @@ -553,7 +553,7 @@ # ignore failures due to non-blocking socket 'unavailable' errors if not is_unavailable_exception(e): # protocol error; provide additional information in test output - self.fail("%s\n%s" % (e, e.headers)) + self.fail("%s\n%s" % (e, getattr(e, "headers", ""))) def test_fail_no_info(self): # use the broken message class @@ -564,7 +564,7 @@ p.pow(6,8) except (xmlrpclib.ProtocolError, socket.error), e: # ignore failures due to non-blocking socket 'unavailable' errors - if not is_unavailable_exception(e): + if not is_unavailable_exception(e) and hasattr(e, "headers"): # The two server-side error headers shouldn't be sent back in this case self.assertTrue(e.headers.get("X-exception") is None) self.assertTrue(e.headers.get("X-traceback") is None) @@ -584,7 +584,7 @@ p.pow(6,8) except (xmlrpclib.ProtocolError, socket.error), e: # ignore failures due to non-blocking socket 'unavailable' errors - if not is_unavailable_exception(e): + if not is_unavailable_exception(e) and hasattr(e, "headers"): # We should get error info in the response expected_err = "invalid literal for int() with base 10: 'I am broken'" self.assertEqual(e.headers.get("x-exception"), expected_err) From python-checkins at python.org Sun Jan 27 21:08:04 2008 From: python-checkins at python.org (neal.norwitz) Date: Sun, 27 Jan 2008 21:08:04 +0100 (CET) Subject: [Python-checkins] r60373 - python/branches/release25-maint/Lib/test/test_resource.py Message-ID: <20080127200804.4FD081E400B@bag.python.org> Author: neal.norwitz Date: Sun Jan 27 21:08:04 2008 New Revision: 60373 Modified: python/branches/release25-maint/Lib/test/test_resource.py Log: Sync up with trunk. Try to flush repeatedly to ensure the exception is raised. Modified: python/branches/release25-maint/Lib/test/test_resource.py ============================================================================== --- python/branches/release25-maint/Lib/test/test_resource.py (original) +++ python/branches/release25-maint/Lib/test/test_resource.py Sun Jan 27 21:08:04 2008 @@ -1,7 +1,7 @@ import os import resource -from test.test_support import TESTFN +from test.test_support import TESTFN, unlink # This test is checking a few specific problem spots. RLIMIT_FSIZE # should be RLIM_INFINITY, which will be a really big number on a @@ -38,17 +38,19 @@ f.flush() # On some systems (e.g., Ubuntu on hppa) the flush() # doesn't always cause the exception, but the close() - # does eventually. Try closing several times in an attempt + # does eventually. Try flushing several times in an attempt # to ensure the file is really synced and the exception raised. for i in range(5): - f.close() + time.sleep(.1) + f.flush() except IOError: if not limit_set: raise f.close() - os.unlink(TESTFN) finally: - resource.setrlimit(resource.RLIMIT_FSIZE, (cur, max)) + if limit_set: + resource.setrlimit(resource.RLIMIT_FSIZE, (cur, max)) + unlink(TESTFN) # And be sure that setrlimit is checking for really large values too_big = 10L**50 From python-checkins at python.org Sun Jan 27 21:23:25 2008 From: python-checkins at python.org (georg.brandl) Date: Sun, 27 Jan 2008 21:23:25 +0100 (CET) Subject: [Python-checkins] r60374 - in doctools/trunk/sphinx: __init__.py addnodes.py addons addons/__init__.py addons/ifconfig.py addons/refcounting.py application.py builder.py config.py directives.py environment.py extension.py latexwriter.py refcounting.py util/__init__.py util/console.py util/smartypants.py Message-ID: <20080127202325.D253A1E400B@bag.python.org> Author: georg.brandl Date: Sun Jan 27 21:23:25 2008 New Revision: 60374 Added: doctools/trunk/sphinx/addons/ doctools/trunk/sphinx/addons/__init__.py doctools/trunk/sphinx/addons/ifconfig.py doctools/trunk/sphinx/addons/refcounting.py doctools/trunk/sphinx/application.py - copied, changed from r60174, doctools/trunk/sphinx/extension.py Removed: doctools/trunk/sphinx/extension.py doctools/trunk/sphinx/refcounting.py Modified: doctools/trunk/sphinx/__init__.py doctools/trunk/sphinx/addnodes.py doctools/trunk/sphinx/builder.py doctools/trunk/sphinx/config.py doctools/trunk/sphinx/directives.py doctools/trunk/sphinx/environment.py doctools/trunk/sphinx/latexwriter.py doctools/trunk/sphinx/util/__init__.py doctools/trunk/sphinx/util/console.py doctools/trunk/sphinx/util/smartypants.py Log: More refactoring: * Move refcounting into an addon module. * Rename the extension manager to Application and use it throughout. * Fix some bugs found by pylint. * Add "ifconfig" addon. Modified: doctools/trunk/sphinx/__init__.py ============================================================================== --- doctools/trunk/sphinx/__init__.py (original) +++ doctools/trunk/sphinx/__init__.py Sun Jan 27 21:23:25 2008 @@ -15,55 +15,19 @@ from os import path from cStringIO import StringIO -from sphinx.config import Config, ConfigError -from sphinx.builder import builders -from sphinx.extension import EventManager +from sphinx.application import Application from sphinx.util.console import nocolor __version__ = '$Revision: 5369 $'[11:-2] -def init_builder(buildername, srcdirname, outdirname, doctreedir, - confoverrides, status, warning=sys.stderr, freshenv=False): - # read config - config = Config(srcdirname, 'conf.py') - if confoverrides: - for key, val in confoverrides.items(): - setattr(config, key, val) - - # extensibility - events = EventManager() - for extension in config.extensions: - try: - mod = __import__(extension, None, None, ['setup']) - except ImportError, err: - raise ConfigError('Could not import extension %s' % module, err) - if hasattr(mod, 'setup'): - mod.setup(events, builders) - - if buildername not in builders: - print >>warning, 'Builder name %s not registered' % buildername - return None - - if buildername is None: - print >>status, 'No builder selected, using default: html' - buildername = 'html' - - builderclass = builders[buildername] - builder = builderclass(srcdirname, outdirname, doctreedir, - status_stream=status, warning_stream=warning, - events=events, config=config, freshenv=freshenv) - events.emit('builder-created', builder) - return builder - - def usage(argv, msg=None): if msg: print >>sys.stderr, msg print >>sys.stderr print >>sys.stderr, """\ usage: %s [options] sourcedir outdir [filenames...]" -options: -b -- builder to use (one of %s) +options: -b -- builder to use; default is html -a -- write all files; default is to only write new and changed files -E -- don't use a saved environment, always read all files -d -- path for the cached environment and doctree files @@ -75,7 +39,7 @@ modi: * without -a and without filenames, write new and changed files. * with -a, write all files. -* with filenames, write these.""" % (argv[0], ', '.join(builders)) +* with filenames, write these.""" % (argv[0],) def main(argv): @@ -85,15 +49,15 @@ try: opts, args = getopt.getopt(argv[1:], 'ab:d:D:NEqP') - srcdirname = path.abspath(args[0]) - if not path.isdir(srcdirname): + srcdir = path.abspath(args[0]) + if not path.isdir(srcdir): print >>sys.stderr, 'Error: Cannot find source directory.' return 1 - if not path.isfile(path.join(srcdirname, 'conf.py')): + if not path.isfile(path.join(srcdir, 'conf.py')): print >>sys.stderr, 'Error: Source directory doesn\'t contain conf.py file.' return 1 - outdirname = path.abspath(args[1]) - if not path.isdir(outdirname): + outdir = path.abspath(args[1]) + if not path.isdir(outdir): print >>sys.stderr, 'Error: Cannot find output directory.' return 1 except (IndexError, getopt.error): @@ -113,7 +77,7 @@ freshenv = use_pdb = False status = sys.stdout confoverrides = {} - doctreedir = path.join(outdirname, '.doctrees') + doctreedir = path.join(outdir, '.doctrees') for opt, val in opts: if opt == '-b': buildername = val @@ -139,18 +103,18 @@ elif opt == '-P': use_pdb = True - builder = init_builder(buildername, srcdirname, outdirname, doctreedir, - confoverrides, status, sys.stderr, freshenv) - if not builder: + app = Application(srcdir, outdir, doctreedir, buildername, + confoverrides, status, sys.stderr, freshenv) + if not app.builder: return 1 try: if all_files: - builder.build_all() + app.builder.build_all() elif filenames: - builder.build_specific(filenames) + app.builder.build_specific(filenames) else: - builder.build_update() + app.builder.build_update() except: if not use_pdb: raise Modified: doctools/trunk/sphinx/addnodes.py ============================================================================== --- doctools/trunk/sphinx/addnodes.py (original) +++ doctools/trunk/sphinx/addnodes.py Sun Jan 27 21:23:25 2008 @@ -29,9 +29,6 @@ def astext(self): return '[' + nodes.TextElement.astext(self) + ']' -# refcount annotation -class refcount(nodes.emphasis): pass - # \versionadded, \versionchanged, \deprecated class versionmodified(nodes.Admonition, nodes.TextElement): pass Added: doctools/trunk/sphinx/addons/__init__.py ============================================================================== --- (empty file) +++ doctools/trunk/sphinx/addons/__init__.py Sun Jan 27 21:23:25 2008 @@ -0,0 +1,10 @@ +# -*- coding: utf-8 -*- +""" + sphinx.addons + ~~~~~~~~~~~~~ + + Contains Sphinx features not activated by default. + + :copyright: 2008 by Georg Brandl. + :license: BSD. +""" Added: doctools/trunk/sphinx/addons/ifconfig.py ============================================================================== --- (empty file) +++ doctools/trunk/sphinx/addons/ifconfig.py Sun Jan 27 21:23:25 2008 @@ -0,0 +1,50 @@ +# -*- coding: utf-8 -*- +""" + sphinx.addons.ifconfig + ~~~~~~~~~~~~~~~~~~~~~~ + + Provides the ``ifconfig`` directive that allows to write documentation + that is included depending on configuration variables. + + Usage:: + + .. ifconfig:: releaselevel in ('alpha', 'beta', 'rc') + + This stuff is only included in the built docs for unstable versions. + + The argument for ``ifconfig`` is a plain Python expression, evaluated in the + namespace of the project configuration (that is, all variables from ``conf.py`` + are available.) + + :copyright: 2008 by Georg Brandl. + :license: BSD. +""" + +from docutils import nodes + + +class ifconfig(nodes.Element): pass + + +def ifconfig_directive(name, arguments, options, content, lineno, + content_offset, block_text, state, state_machine): + node = ifconfig() + node['expr'] = arguments[0] + state.nested_parse(content, content_offset, node) + return [node] + + +def process_ifconfig_nodes(app, doctree, docfilename): + ns = app.config.__dict__.copy() + ns['builder'] = app.builder.name + for node in doctree.traverse(ifconfig): + if not eval(node['expr'], ns): + node.replace_self([]) + else: + node.replace_self(node.children) + + +def setup(app): + app.add_node(ifconfig) + app.add_directive('ifconfig', ifconfig_directive, 1, (1, 0, 1)) + app.connect('doctree-resolved', process_ifconfig_nodes) Added: doctools/trunk/sphinx/addons/refcounting.py ============================================================================== --- (empty file) +++ doctools/trunk/sphinx/addons/refcounting.py Sun Jan 27 21:23:25 2008 @@ -0,0 +1,95 @@ +# -*- coding: utf-8 -*- +""" + sphinx.addons.refcounting + ~~~~~~~~~~~~~~~~~~~~~~~~~ + + Supports reference count annotations for C API functions. Based on + refcount.py and anno-api.py in the old Python documentation tools. + + :copyright: 2008 by Georg Brandl. + :license: BSD. +""" + +from os import path +from docutils import nodes + +from sphinx import addnodes + + +# refcount annotation +class refcount(nodes.emphasis): pass + + +class RCEntry: + def __init__(self, name): + self.name = name + self.args = [] + self.result_type = '' + self.result_refs = None + + +class Refcounts(dict): + @classmethod + def fromfile(cls, filename): + d = cls() + fp = open(filename, 'r') + try: + for line in fp: + line = line.strip() + if line[:1] in ("", "#"): + # blank lines and comments + continue + parts = line.split(":", 4) + if len(parts) != 5: + raise ValueError("Wrong field count in %r" % line) + function, type, arg, refcount, comment = parts + # Get the entry, creating it if needed: + try: + entry = d[function] + except KeyError: + entry = d[function] = RCEntry(function) + if not refcount or refcount == "null": + refcount = None + else: + refcount = int(refcount) + # Update the entry with the new parameter or the result information. + if arg: + entry.args.append((arg, type, refcount)) + else: + entry.result_type = type + entry.result_refs = refcount + finally: + fp.close() + return d + + def add_refcount_annotations(self, app, doctree): + for node in doctree.traverse(addnodes.desc_content): + par = node.parent + if par['desctype'] != 'cfunction': + continue + if not par[0].has_key('names') or not par[0]['names']: + continue + entry = self.get(par[0]['names'][0]) + if not entry: + continue + elif entry.result_type not in ("PyObject*", "PyVarObject*"): + continue + rc = 'Return value: ' + if entry.result_refs is None: + rc += "Always NULL." + else: + rc += (entry.result_refs and "New" or "Borrowed") + " reference." + node.insert(0, refcount(rc, rc)) + + +def init_refcounts(app): + if app.config.refcount_file: + refcounts = Refcounts.fromfile( + path.join(app.srcdir, app.config.refcount_file)) + app.connect('doctree-read', refcounts.add_refcount_annotations) + + +def setup(app): + app.add_node(refcount) + app.add_config_value('refcount_file', '', True) + app.connect('builder-inited', init_refcounts) Copied: doctools/trunk/sphinx/application.py (from r60174, doctools/trunk/sphinx/extension.py) ============================================================================== --- doctools/trunk/sphinx/extension.py (original) +++ doctools/trunk/sphinx/application.py Sun Jan 27 21:23:25 2008 @@ -1,60 +1,139 @@ # -*- coding: utf-8 -*- """ - sphinx.extension - ~~~~~~~~~~~~~~~~ + sphinx.application + ~~~~~~~~~~~~~~~~~~ + + Sphinx application object. + + Gracefully adapted from the TextPress system by Armin. - Gracefully adapted from the TextPress event system by Armin. :copyright: 2008 by Georg Brandl, Armin Ronacher. :license: BSD. """ -from sphinx.config import ConfigError +import sys + +from docutils import nodes +from docutils.parsers.rst import directives, roles + +from sphinx.config import Config +from sphinx.builder import builtin_builders -def import_object(objname, source=None): - """Import an object from a 'module.name' string.""" - try: - module, name = objname.rsplit('.', 1) - except ValueError, err: - raise ConfigError('Invalid full object name %s' % objname + - (source and ' (needed for %s)' % source or ''), err) - try: - return getattr(__import__(module, None, None, [name]), name) - except ImportError, err: - raise ConfigError('Could not import %s' % module + - (source and ' (needed for %s)' % source or ''), err) - except AttributeError, err: - raise ConfigError('Could not find %s' % objname + - (source and ' (needed for %s)' % source or ''), err) +class ExtensionError(Exception): + """Raised if something's wrong with the configuration.""" + + def __init__(self, message, orig_exc=None): + self.message = message + self.orig_exc = orig_exc + + def __repr__(self): + if self.orig_exc: + return '%s(%r, %r)' % (self.__class__.__name__, + self.message, self.orig_exc) + return '%s(%r)' % (self.__class__.__name__, self.message) + + def __str__(self): + if self.orig_exc: + return '%s (exception: %s)' % (self.message, self.orig_exc) + return self.message # List of all known events. Maps name to arguments description. events = { - 'builder-created' : 'builder instance', + 'builder-inited': 'builder instance', 'doctree-read' : 'the doctree before being pickled', + 'doctree-resolved' : 'the doctree, the filename, the builder', } -class EventManager(object): - """ - Helper class that handles event listeners and events. - - This is *not* a public interface. Always use the emit_event() - functions to access it or the connect_event() / disconnect_event() - functions on the application. - """ +class Application(object): - def __init__(self): + def __init__(self, srcdir, outdir, doctreedir, buildername, + confoverrides, status, warning=sys.stderr, freshenv=False): self.next_listener_id = 0 self._listeners = {} + self.builderclasses = builtin_builders.copy() + self.builder = None - def _validate(self, event): + self.srcdir = srcdir + self.outdir = outdir + self.doctreedir = doctreedir + + self._status = status + self._warning = warning + + # read config + self.config = Config(srcdir, 'conf.py') + if confoverrides: + for key, val in confoverrides.items(): + setattr(self.config, key, val) + + # load all extension modules + for extension in getattr(self.config, 'extensions', ()): + self.setup_extension(extension) + + # this must happen after loading extension modules, since they + # can add custom config values + self.config.init_defaults() + + if buildername is None: + print >>status, 'No builder selected, using default: html' + buildername = 'html' + if buildername not in self.builderclasses: + print >>warning, 'Builder name %s not registered' % buildername + return + + builderclass = self.builderclasses[buildername] + self.builder = builderclass(self, freshenv=freshenv) + self.emit('builder-inited') + + def warn(self, message): + self._warning.write('WARNING: %s\n' % message) + + def info(self, message='', nonl=False): + if nonl: + self._status.write(message) + else: + self._status.write(message + '\n') + self._status.flush() + + # general extensibility interface + + def setup_extension(self, extension): + """Import and setup a Sphinx extension module.""" + try: + mod = __import__(extension, None, None, ['setup']) + except ImportError, err: + raise ExtensionError('Could not import extension %s' % extension, err) + if hasattr(mod, 'setup'): + mod.setup(self) + + def import_object(self, objname, source=None): + """Import an object from a 'module.name' string.""" + try: + module, name = objname.rsplit('.', 1) + except ValueError, err: + raise ExtensionError('Invalid full object name %s' % objname + + (source and ' (needed for %s)' % source or ''), err) + try: + return getattr(__import__(module, None, None, [name]), name) + except ImportError, err: + raise ExtensionError('Could not import %s' % module + + (source and ' (needed for %s)' % source or ''), err) + except AttributeError, err: + raise ExtensionError('Could not find %s' % objname + + (source and ' (needed for %s)' % source or ''), err) + + # event interface + + def _validate_event(self, event): event = intern(event) if event not in events: - raise RuntimeError('unknown event name: %s' % event) + raise ExtensionError('Unknown event name: %s' % event) def connect(self, event, callback): - self._validate(event) + self._validate_event(event) listener_id = self.next_listener_id if event not in self._listeners: self._listeners[event] = {listener_id: callback} @@ -63,21 +142,39 @@ self.next_listener_id += 1 return listener_id - def remove(self, listener_id): + def disconnect(self, listener_id): for event in self._listeners: event.pop(listener_id, None) def emit(self, event, *args): - self._validate(event) + result = [] if event in self._listeners: - for listener_id, callback in self._listeners[event].iteritems(): - yield listener_id, callback(*args) + for _, callback in self._listeners[event].iteritems(): + result.append(callback(self, *args)) + return result + + # registering addon parts + + def add_builder(self, builder): + if not hasattr(builder, 'name'): + raise ExtensionError('Builder class %s has no "name" attribute' % builder) + if builder.name in self.builderclasses: + raise ExtensionError('Builder %r already exists (in module %s)' % ( + builder.name, self.builderclasses[builder.name].__module__)) + self.builderclasses[builder.name] = builder + + def add_config_value(self, name, default, rebuild_env): + if name in self.config.values: + raise ExtensionError('Config value %r already present') + self.config.values[name] = (default, rebuild_env) + + def add_node(self, node): + nodes._add_node_class_names([node.__name__]) + + def add_directive(self, name, cls, content, arguments): + cls.content = content + cls.arguments = arguments + directives.register_directive(name, cls) - -class DummyEventManager(EventManager): - def connect(self, event, callback): - self._validate(event) - def remove(self, listener_id): - pass - def emit(self, event, *args): - self._validate(event) + def add_role(self, name, role): + roles.register_canonical_role(name, role) Modified: doctools/trunk/sphinx/builder.py ============================================================================== --- doctools/trunk/sphinx/builder.py (original) +++ doctools/trunk/sphinx/builder.py Sun Jan 27 21:23:25 2008 @@ -10,12 +10,10 @@ """ import os -import sys import time import codecs import shutil import cPickle as pickle -import cStringIO as StringIO from os import path from cgi import escape @@ -23,18 +21,16 @@ from docutils.io import StringOutput, FileOutput, DocTreeInput from docutils.core import publish_parts from docutils.utils import new_document -from docutils.readers import doctree from docutils.frontend import OptionParser +from docutils.readers.doctree import Reader as DoctreeReader from sphinx import addnodes -from sphinx.util import (get_matching_files, attrdict, status_iterator, - ensuredir, relative_uri, os_path, SEP) +from sphinx.util import (get_matching_files, ensuredir, relative_uri, os_path, SEP) from sphinx.htmlhelp import build_hhx -from sphinx.extension import DummyEventManager, import_object from sphinx.htmlwriter import HTMLWriter, HTMLTranslator, SmartyPantsHTMLTranslator from sphinx.latexwriter import LaTeXWriter from sphinx.environment import BuildEnvironment, NoUri -from sphinx.highlighting import pygments, highlight_block, get_stylesheet +from sphinx.highlighting import pygments, get_stylesheet from sphinx.util.console import bold, purple, green # side effect: registers roles and directives @@ -49,40 +45,26 @@ Builds target formats from the reST sources. """ - def __init__(self, srcdirname, outdirname, doctreedirname, - config, env=None, freshenv=False, events=None, - status_stream=None, warning_stream=None): - self.srcdir = srcdirname - self.outdir = outdirname - self.doctreedir = doctreedirname - if not path.isdir(doctreedirname): - os.mkdir(doctreedirname) - self.freshenv = freshenv - - self.status_stream = status_stream or sys.stdout - self.warning_stream = warning_stream or sys.stderr + def __init__(self, app, env=None, freshenv=False): + self.srcdir = app.srcdir + self.outdir = app.outdir + self.doctreedir = app.doctreedir + if not path.isdir(self.doctreedir): + os.mkdir(self.doctreedir) + + self.app = app + self.warn = app.warn + self.info = app.info + self.config = app.config - self.config = config # if None, this is set in load_env() self.env = env - - self.events = events or DummyEventManager() + self.freshenv = freshenv self.init() # helper methods - def msg(self, message='', nonl=False, nobold=False): - if not nobold: message = bold(message) - if nonl: - print >>self.status_stream, message, - else: - print >>self.status_stream, message - self.status_stream.flush() - - def warn(self, message): - print >>self.warning_stream, 'WARNING:', message - def init(self): """Load necessary templates and perform initialization.""" raise NotImplementedError @@ -122,6 +104,17 @@ """Return a list of output files that are outdated.""" raise NotImplementedError + def status_iterator(self, iterable, summary, colorfunc): + l = -1 + for item in iterable: + if l == -1: + self.info(bold(summary), nonl=1) + l = 0 + self.info(colorfunc(item) + ' ', nonl=1) + yield item + if l == 0: + self.info() + # build methods def load_env(self): @@ -131,12 +124,12 @@ return if not self.freshenv: try: - self.msg('trying to load pickled env...', nonl=True) + self.info(bold('trying to load pickled env... '), nonl=True) self.env = BuildEnvironment.frompickle( path.join(self.doctreedir, ENV_PICKLE_FILENAME)) - self.msg('done', nobold=True) + self.info('done') except Exception, err: - self.msg('failed: %s' % err, nobold=True) + self.info('failed: %s' % err) self.env = BuildEnvironment(self.srcdir, self.doctreedir) else: self.env = BuildEnvironment(self.srcdir, self.doctreedir) @@ -161,7 +154,7 @@ self.load_env() to_build = self.get_outdated_files() if not to_build: - self.msg('no target files are out of date, exiting.') + self.info(bold('no target files are out of date, exiting.')) return if isinstance(to_build, str): self.build([], to_build) @@ -173,36 +166,32 @@ def build(self, filenames, summary=None): if summary: - self.msg('building [%s]:' % self.name, nonl=1) - self.msg(summary, nobold=1) + self.info(bold('building [%s]: ' % self.name), nonl=1) + self.info(summary) updated_filenames = [] # while reading, collect all warnings from docutils warnings = [] self.env.set_warnfunc(warnings.append) - self.msg('reading, updating environment:', nonl=1) - iterator = self.env.update( - self.config, - hook=lambda doctree: self.events.emit('doctree-read', doctree)) - self.msg(iterator.next(), nonl=1, nobold=1) - for filename in iterator: - if not updated_filenames: - self.msg('') + self.info(bold('updating environment: '), nonl=1) + iterator = self.env.update(self.config, self.app) + # the first item in the iterator is a summary message + self.info(iterator.next()) + for filename in self.status_iterator(iterator, 'reading... ', purple): updated_filenames.append(filename) - self.msg(purple(filename), nonl=1, nobold=1) - self.msg() + # nothing further to do, the environment has already done the reading for warning in warnings: self.warn(warning) self.env.set_warnfunc(self.warn) if updated_filenames: # save the environment - self.msg('pickling the env...', nonl=True) + self.info(bold('pickling the env... '), nonl=True) self.env.topickle(path.join(self.doctreedir, ENV_PICKLE_FILENAME)) - self.msg('done', nobold=True) + self.info('done') # global actions - self.msg('checking consistency...') + self.info(bold('checking consistency...')) self.env.check_consistency() # another indirection to support methods which don't build files @@ -210,9 +199,9 @@ self.write(filenames, updated_filenames) # finish (write style files etc.) - self.msg('finishing...') + self.info(bold('finishing... ')) self.finish() - self.msg('done!') + self.info(bold('build succeeded.')) def write(self, build_filenames, updated_filenames): if build_filenames is None: # build_all @@ -225,16 +214,15 @@ filenames.add(tocfilename) filenames.add('contents.rst') - self.msg('creating index...') + self.info(bold('creating index...')) self.env.create_index(self) self.prepare_writing(filenames) # write target files warnings = [] self.env.set_warnfunc(warnings.append) - self.msg('writing output...') - for filename in status_iterator(sorted(filenames), green, - stream=self.status_stream): + for filename in self.status_iterator(sorted(filenames), + 'writing output... ', green): doctree = self.env.get_and_resolve_doctree(filename, self) self.write_file(filename, doctree) for warning in warnings: @@ -263,8 +251,8 @@ """Load templates.""" self.init_templates() if self.config.html_translator_class: - self.translator_class = import_object(self.config.html_translator_class, - 'html_translator_class setting') + self.translator_class = self.app.import_object( + self.config.html_translator_class, 'html_translator_class setting') elif self.config.html_use_smartypants: self.translator_class = SmartyPantsHTMLTranslator else: @@ -277,7 +265,7 @@ return publish_parts( doc, source_class=DocTreeInput, - reader=doctree.Reader(), + reader=DoctreeReader(), writer=HTMLWriter(self), settings_overrides={'output_encoding': 'unicode'} ) @@ -316,7 +304,7 @@ destination = StringOutput(encoding='utf-8') doctree.settings = self.docsettings - output = self.docwriter.write(doctree, destination) + self.docwriter.write(doctree, destination) self.docwriter.assemble_parts() prev = next = None @@ -360,14 +348,14 @@ self.handle_page(pagename, context) def finish(self): - self.msg('writing additional files...') + self.info(bold('writing additional files...')) # the global general index # the total count of lines for each index letter, used to distribute # the entries into two columns indexcounts = [] - for key, entries in self.env.index: + for _, entries in self.env.index: indexcounts.append(sum(1 + len(subitems) for _, (_, subitems) in entries)) genindexcontext = dict( @@ -434,7 +422,7 @@ self.handle_page('index', {'indextemplate': indextemplate}, 'index.html') # copy style files - self.msg('copying style files...') + self.info(bold('copying style files...')) styledirname = path.join(path.dirname(__file__), 'style') ensuredir(path.join(self.outdir, 'style')) for filename in os.listdir(styledirname): @@ -519,7 +507,7 @@ path.join(self.outdir, os_path(ctx['sourcename']))) def handle_finish(self): - self.msg('dumping search index...') + self.info(bold('dumping search index...')) self.indexer.prune([fn[:-4] for fn in self.env.all_files]) f = open(path.join(self.outdir, 'searchindex.json'), 'w') try: @@ -576,7 +564,7 @@ def handle_page(self, pagename, context, templatename='page.html'): context['current_page_name'] = pagename - sidebarfile = self.confightml_sidebars.get(pagename, '') + sidebarfile = self.config.html_sidebars.get(pagename, '') if sidebarfile: context['customsidebar'] = path.join(self.srcdir, sidebarfile) outfilename = path.join(self.outdir, os_path(pagename) + '.fpickle') @@ -603,7 +591,7 @@ finally: f.close() - self.msg('dumping search index...') + self.info(bold('dumping search index...')) self.indexer.prune(self.env.all_files) f = open(path.join(self.outdir, 'searchindex.pickle'), 'wb') try: @@ -698,7 +686,7 @@ doctree.settings.author = author doctree.settings.filename = sourcename doctree.settings.docclass = docclass - output = docwriter.write(doctree, destination) + docwriter.write(doctree, destination) print "done" def assemble_doctree(self, indexfile, appendices): @@ -746,7 +734,7 @@ return largetree def finish(self): - self.msg('copying TeX support files...') + self.info(bold('copying TeX support files...')) styledirname = path.join(path.dirname(__file__), 'texinputs') for filename in os.listdir(styledirname): if not filename.startswith('.'): @@ -780,7 +768,7 @@ libchanges = {} apichanges = [] otherchanges = {} - self.msg('writing summary file...') + self.info(bold('writing summary file...')) for type, filename, lineno, module, descname, content in \ self.env.versionchanges[version]: ttext = self.typemap[type] @@ -841,7 +829,7 @@ break return line - self.msg('copying source files...') + self.info(bold('copying source files...')) for filename in self.env.all_files: f = open(path.join(self.srcdir, os_path(filename))) lines = f.readlines() @@ -868,7 +856,7 @@ pass -builders = { +builtin_builders = { 'html': StandaloneHTMLBuilder, 'web': WebHTMLBuilder, 'htmlhelp': HTMLHelpBuilder, Modified: doctools/trunk/sphinx/config.py ============================================================================== --- doctools/trunk/sphinx/config.py (original) +++ doctools/trunk/sphinx/config.py Sun Jan 27 21:23:25 2008 @@ -10,29 +10,10 @@ """ import os -import sys import types from os import path -class ConfigError(Exception): - """Raised if something's wrong with the configuration.""" - - def __init__(self, message, orig_exc=None): - self.message = message - self.orig_exc = orig_exc - - def __repr__(self): - if self.orig_exc: - return 'ConfigError(%r, %r)' % (self.message, self.orig_exc) - return 'ConfigError(%r)' % self.message - - def __str__(self): - if self.orig_exc: - return '%s (exception: %s)' % (self.message, self.orig_exc) - return self.message - - class Config(object): """Configuration file abstraction.""" @@ -53,7 +34,6 @@ # general reading options unused_files = ([], True), - refcount_file = ('', True), add_function_parentheses = (True, True), add_module_names = (True, True), @@ -77,6 +57,7 @@ ) def __init__(self, dirname, filename): + self.values = self.config_values.copy() config = {} olddir = os.getcwd() try: @@ -90,14 +71,10 @@ del config[key] self.__dict__.update(config) - def __getattr__(self, name): - if name in self.config_values: - defval = self.config_values[name][0] - setattr(self, name, defval) - return defval - if name[0:1] == '_': - return object.__getattr__(self, name) - raise AttributeError('no configuration value named %r' % name) + def init_defaults(self): + for val in self.values: + if val not in self.__dict__: + self.__dict__[val] = self.values[val][0] def __getitem__(self, name): return getattr(self, name) Modified: doctools/trunk/sphinx/directives.py ============================================================================== --- doctools/trunk/sphinx/directives.py (original) +++ doctools/trunk/sphinx/directives.py Sun Jan 27 21:23:25 2008 @@ -15,7 +15,7 @@ from os import path from docutils import nodes -from docutils.parsers.rst import directives, roles +from docutils.parsers.rst import directives from docutils.parsers.rst.directives import admonitions from sphinx import addnodes @@ -273,21 +273,6 @@ return optname -def add_refcount_annotation(env, node, name): - """Add a reference count annotation. Return None.""" - entry = env.refcounts.get(name) - if not entry: - return - elif entry.result_type not in ("PyObject*", "PyVarObject*"): - return - rc = 'Return value: ' - if entry.result_refs is None: - rc += "Always NULL." - else: - rc += (entry.result_refs and "New" or "Borrowed") + " reference." - node += addnodes.refcount(rc, rc) - - def desc_directive(desctype, arguments, options, content, lineno, content_offset, block_text, state, state_machine): env = state.document.settings.env @@ -361,8 +346,6 @@ fullname, fullname) subnode = addnodes.desc_content() - if desctype == 'cfunction': - add_refcount_annotation(env, subnode, name) # needed for automatic qualification of members clsname_set = False if desctype == 'class' and names: @@ -407,8 +390,8 @@ 'describe', ] -for name in desctypes: - directives.register_directive(name, desc_directive) +for _name in desctypes: + directives.register_directive(_name, desc_directive) # ------ versionadded/versionchanged ----------------------------------------------- Modified: doctools/trunk/sphinx/environment.py ============================================================================== --- doctools/trunk/sphinx/environment.py (original) +++ doctools/trunk/sphinx/environment.py Sun Jan 27 21:23:25 2008 @@ -44,7 +44,6 @@ from sphinx import addnodes from sphinx.util import get_matching_files, os_path, SEP -from sphinx.refcounting import Refcounts default_settings = { 'embed_stylesheet': False, @@ -128,7 +127,7 @@ class MyStandaloneReader(standalone.Reader): """ - Add our own Substitutions transform. + Add our own transforms. """ def get_transforms(self): tf = standalone.Reader.get_transforms(self) @@ -189,9 +188,6 @@ self.srcdir = srcdir self.config = None - # refcount data if present - self.refcounts = {} - # the docutils settings for building self.settings = default_settings.copy() self.settings['env'] = self @@ -314,7 +310,7 @@ return added, changed, removed - def update(self, config, hook=None): + def update(self, config, app=None): """(Re-)read all files new or changed since last update. Yields a summary and then filenames as it processes them. Store all environment filenames in the canonical format (ie using SEP as a separator in place of @@ -341,11 +337,6 @@ self.config = config - # read the refcounts file - if self.config.refcount_file: - self.refcounts = Refcounts.fromfile( - path.join(self.srcdir, self.config.refcount_file)) - # clear all files no longer present for filename in removed: self.clear_file(filename) @@ -353,14 +344,14 @@ # read all new and changed files for filename in added + changed: yield filename - self.read_file(filename) + self.read_file(filename, app=app) if 'contents.rst' not in self.all_files: self._warnfunc('no master file contents.rst found') # --------- SINGLE FILE BUILDING ------------------------------------------- - def read_file(self, filename, src_path=None, save_parsed=True, hook=None): + def read_file(self, filename, src_path=None, save_parsed=True, app=None): """Parse a file and add/update inventory entries for the doctree. If srcpath is given, read from a different source file.""" # remove all inventory entries for that file @@ -386,9 +377,8 @@ f.close() self.all_files[filename] = (path.getmtime(src_path), md5sum) - # run post-read hook - if hook: - hook(doctree) + if app: + app.emit('doctree-read', doctree) # make it picklable doctree.reporter = None @@ -590,7 +580,7 @@ for includefile in includefiles: try: toc = self.tocs[includefile].deepcopy() - except KeyError, err: + except KeyError: # this is raised if the included file does not exist self._warnfunc('%s: toctree contains ref to nonexisting ' 'file %r' % (filename, includefile)) @@ -622,6 +612,9 @@ return doctree + descroles = frozenset(('data', 'exc', 'func', 'class', 'const', 'attr', + 'meth', 'cfunc', 'cdata', 'ctype', 'cmacro')) + def resolve_references(self, doctree, docfilename, builder): for node in doctree.traverse(addnodes.pending_xref): contnode = node[0].deepcopy() @@ -702,7 +695,7 @@ (platform and '(%s) ' % platform), synopsis, (deprecated and ' (deprecated)' or '')) newnode.append(contnode) - else: + elif typ in self.descroles: # "descrefs" modname = node['modname'] clsname = node['classname'] @@ -720,11 +713,16 @@ builder.get_relative_uri(docfilename, desc[0]) + '#' + name) newnode.append(contnode) + else: + raise RuntimeError('unknown xfileref node encountered: %s' % node) except NoUri: newnode = contnode if newnode: node.replace_self(newnode) + # allow custom references to be resolved + builder.app.emit('doctree-resolved', doctree, docfilename) + def create_index(self, builder, _fixre=re.compile(r'(.*) ([(][^()]*[)])')): """Create the real index from the collected index entries.""" new = {} Deleted: /doctools/trunk/sphinx/extension.py ============================================================================== --- /doctools/trunk/sphinx/extension.py Sun Jan 27 21:23:25 2008 +++ (empty file) @@ -1,83 +0,0 @@ -# -*- coding: utf-8 -*- -""" - sphinx.extension - ~~~~~~~~~~~~~~~~ - - Gracefully adapted from the TextPress event system by Armin. - - :copyright: 2008 by Georg Brandl, Armin Ronacher. - :license: BSD. -""" - -from sphinx.config import ConfigError - - -def import_object(objname, source=None): - """Import an object from a 'module.name' string.""" - try: - module, name = objname.rsplit('.', 1) - except ValueError, err: - raise ConfigError('Invalid full object name %s' % objname + - (source and ' (needed for %s)' % source or ''), err) - try: - return getattr(__import__(module, None, None, [name]), name) - except ImportError, err: - raise ConfigError('Could not import %s' % module + - (source and ' (needed for %s)' % source or ''), err) - except AttributeError, err: - raise ConfigError('Could not find %s' % objname + - (source and ' (needed for %s)' % source or ''), err) - - -# List of all known events. Maps name to arguments description. -events = { - 'builder-created' : 'builder instance', - 'doctree-read' : 'the doctree before being pickled', -} - -class EventManager(object): - """ - Helper class that handles event listeners and events. - - This is *not* a public interface. Always use the emit_event() - functions to access it or the connect_event() / disconnect_event() - functions on the application. - """ - - def __init__(self): - self.next_listener_id = 0 - self._listeners = {} - - def _validate(self, event): - event = intern(event) - if event not in events: - raise RuntimeError('unknown event name: %s' % event) - - def connect(self, event, callback): - self._validate(event) - listener_id = self.next_listener_id - if event not in self._listeners: - self._listeners[event] = {listener_id: callback} - else: - self._listeners[event][listener_id] = callback - self.next_listener_id += 1 - return listener_id - - def remove(self, listener_id): - for event in self._listeners: - event.pop(listener_id, None) - - def emit(self, event, *args): - self._validate(event) - if event in self._listeners: - for listener_id, callback in self._listeners[event].iteritems(): - yield listener_id, callback(*args) - - -class DummyEventManager(EventManager): - def connect(self, event, callback): - self._validate(event) - def remove(self, listener_id): - pass - def emit(self, event, *args): - self._validate(event) Modified: doctools/trunk/sphinx/latexwriter.py ============================================================================== --- doctools/trunk/sphinx/latexwriter.py (original) +++ doctools/trunk/sphinx/latexwriter.py Sun Jan 27 21:23:25 2008 @@ -14,9 +14,8 @@ import re import time -import string -from docutils import frontend, nodes, languages, writers, utils +from docutils import nodes, writers from sphinx import addnodes from sphinx import highlighting Deleted: /doctools/trunk/sphinx/refcounting.py ============================================================================== --- /doctools/trunk/sphinx/refcounting.py Sun Jan 27 21:23:25 2008 +++ (empty file) @@ -1,53 +0,0 @@ -# -*- coding: utf-8 -*- -""" - sphinx.refcounting - ~~~~~~~~~~~~~~~~~~ - - Handle reference counting annotations, based on refcount.py - and anno-api.py. - - :copyright: 2007-2008 by Georg Brandl. - :license: BSD. -""" - -class RCEntry: - def __init__(self, name): - self.name = name - self.args = [] - self.result_type = '' - self.result_refs = None - - -class Refcounts(dict): - @classmethod - def fromfile(cls, filename): - d = cls() - fp = open(filename, 'r') - try: - for line in fp: - line = line.strip() - if line[:1] in ("", "#"): - # blank lines and comments - continue - parts = line.split(":", 4) - if len(parts) != 5: - raise ValueError("Wrong field count in %r" % line) - function, type, arg, refcount, comment = parts - # Get the entry, creating it if needed: - try: - entry = d[function] - except KeyError: - entry = d[function] = RCEntry(function) - if not refcount or refcount == "null": - refcount = None - else: - refcount = int(refcount) - # Update the entry with the new parameter or the result information. - if arg: - entry.args.append((arg, type, refcount)) - else: - entry.result_type = type - entry.result_refs = refcount - finally: - fp.close() - return d Modified: doctools/trunk/sphinx/util/__init__.py ============================================================================== --- doctools/trunk/sphinx/util/__init__.py (original) +++ doctools/trunk/sphinx/util/__init__.py Sun Jan 27 21:23:25 2008 @@ -51,15 +51,6 @@ raise -def status_iterator(iterable, colorfunc=lambda x: x, stream=sys.stdout): - """Print out each item before yielding it.""" - for item in iterable: - print >>stream, colorfunc(item), - stream.flush() - yield item - print >>stream - - def get_matching_files(dirname, pattern, exclude=()): """Get all files matching a pattern in a directory, recursively.""" # dirname is a normalized absolute path. Modified: doctools/trunk/sphinx/util/console.py ============================================================================== --- doctools/trunk/sphinx/util/console.py (original) +++ doctools/trunk/sphinx/util/console.py Sun Jan 27 21:23:25 2008 @@ -11,6 +11,30 @@ codes = {} +def get_terminal_width(): + """Borrowed from the py lib.""" + try: + import os, termios, fcntl, struct + call = fcntl.ioctl(0, termios.TIOCGWINSZ, "\000"*8) + height, width = struct.unpack("hhhh", call)[:2] + terminal_width = width + except (SystemExit, KeyboardInterrupt): + raise + except: + # FALLBACK + terminal_width = int(os.environ.get('COLUMNS', 80))-1 + return terminal_width + +_tw = get_terminal_width() + +def print_and_backspace(text, func): + if not codes: + # if no coloring, don't output fancy backspaces + func(text) + else: + func(text.ljust(_tw) + _tw * "\b") + + def nocolor(): codes.clear() @@ -31,8 +55,8 @@ 'blink': '05m', } -for name, value in _attrs.items(): - codes[name] = '\x1b[' + value +for _name, _value in _attrs.items(): + codes[_name] = '\x1b[' + _value _colors = [ ('black', 'darkgray'), @@ -49,5 +73,5 @@ codes[dark] = '\x1b[%im' % (i+30) codes[light] = '\x1b[%i;01m' % (i+30) -for name in codes: - create_color_func(name) +for _name in codes: + create_color_func(_name) Modified: doctools/trunk/sphinx/util/smartypants.py ============================================================================== --- doctools/trunk/sphinx/util/smartypants.py (original) +++ doctools/trunk/sphinx/util/smartypants.py Sun Jan 27 21:23:25 2008 @@ -151,7 +151,7 @@ (\s | s\b) """ % (close_class,), re.VERBOSE) -def educateQuotes(str): +def educateQuotes(s): """ Parameter: String. @@ -163,35 +163,33 @@ # Special case if the very first character is a quote # followed by punctuation at a non-word-break. Close the quotes by brute force: - str = single_quote_start_re.sub("’", str) - str = double_quote_start_re.sub("”", str) + s = single_quote_start_re.sub("’", s) + s = double_quote_start_re.sub("”", s) # Special case for double sets of quotes, e.g.: #

    He said, "'Quoted' words in a larger quote."

    - str = double_quote_sets_re.sub("“‘", str) - str = single_quote_sets_re.sub("‘“", str) + s = double_quote_sets_re.sub("“‘", s) + s = single_quote_sets_re.sub("‘“", s) # Special case for decade abbreviations (the '80s): - str = decade_abbr_re.sub("’", str) + s = decade_abbr_re.sub("’", s) - str = opening_single_quotes_regex.sub(r"\1‘", str) - str = closing_single_quotes_regex.sub(r"\1’", str) - str = closing_single_quotes_regex_2.sub(r"\1’\2", str) + s = opening_single_quotes_regex.sub(r"\1‘", s) + s = closing_single_quotes_regex.sub(r"\1’", s) + s = closing_single_quotes_regex_2.sub(r"\1’\2", s) # Any remaining single quotes should be opening ones: - str = str.replace("'", "‘") + s = s.replace("'", "‘") - str = opening_double_quotes_regex.sub(r"\1“", str) - str = closing_double_quotes_regex.sub(r"”", str) - str = closing_double_quotes_regex_2.sub(r"\1”", str) + s = opening_double_quotes_regex.sub(r"\1“", s) + s = closing_double_quotes_regex.sub(r"”", s) + s = closing_double_quotes_regex_2.sub(r"\1”", s) # Any remaining quotes should be opening ones. - str = str.replace('"', "“") + return s.replace('"', "“") - return str - -def educateBackticks(str): +def educateBackticks(s): """ Parameter: String. Returns: The string, with ``backticks'' -style double quotes @@ -199,10 +197,10 @@ Example input: ``Isn't this fun?'' Example output: “Isn't this fun?” """ - return str.replace("``", "“").replace("''", "”") + return s.replace("``", "“").replace("''", "”") -def educateSingleBackticks(str): +def educateSingleBackticks(s): """ Parameter: String. Returns: The string, with `backticks' -style single quotes @@ -211,10 +209,10 @@ Example input: `Isn't this fun?' Example output: ‘Isn’t this fun?’ """ - return str.replace('`', "‘").replace("'", "’") + return s.replace('`', "‘").replace("'", "’") -def educateDashesOldSchool(str): +def educateDashesOldSchool(s): """ Parameter: String. @@ -222,10 +220,10 @@ an en-dash HTML entity, and each "---" translated to an em-dash HTML entity. """ - return str.replace('---', "—").replace('--', "–") + return s.replace('---', "—").replace('--', "–") -def educateDashesOldSchoolInverted(str): +def educateDashesOldSchoolInverted(s): """ Parameter: String. @@ -240,11 +238,11 @@ the shortcut should be shorter to type. (Thanks to Aaron Swartz for the idea.) """ - return str.replace('---', "–").replace('--', "—") + return s.replace('---', "–").replace('--', "—") -def educateEllipses(str): +def educateEllipses(s): """ Parameter: String. Returns: The string, with each instance of "..." translated to @@ -253,7 +251,7 @@ Example input: Huh...? Example output: Huh…? """ - return str.replace('...', "…").replace('. . .', "…") + return s.replace('...', "…").replace('. . .', "…") __author__ = "Chad Miller " From python-checkins at python.org Sun Jan 27 21:25:12 2008 From: python-checkins at python.org (georg.brandl) Date: Sun, 27 Jan 2008 21:25:12 +0100 (CET) Subject: [Python-checkins] r60375 - python/trunk/Doc/conf.py Message-ID: <20080127202512.C2B641E401C@bag.python.org> Author: georg.brandl Date: Sun Jan 27 21:25:12 2008 New Revision: 60375 Modified: python/trunk/Doc/conf.py Log: Add refcounting extension to build config. Modified: python/trunk/Doc/conf.py ============================================================================== --- python/trunk/Doc/conf.py (original) +++ python/trunk/Doc/conf.py Sun Jan 27 21:25:12 2008 @@ -13,6 +13,8 @@ # General configuration # --------------------- +extensions = ['sphinx.addons.refcounting'] + # General substitutions. project = 'Python' copyright = '1990-%s, Python Software Foundation' % time.strftime('%Y') From nnorwitz at gmail.com Sun Jan 27 23:38:52 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Sun, 27 Jan 2008 17:38:52 -0500 Subject: [Python-checkins] Python Regression Test Failures refleak (9) Message-ID: <20080127223852.GA31465@python.psfb.org> test_opcodes leaked [0, -2, 2] references, sum=0 test_doctest leaked [0, 0, -2] references, sum=-2 test_asynchat leaked [-91, 0, 0] references, sum=-91 test_cmd_line leaked [0, 0, -23] references, sum=-23 test_descrtut leaked [0, 2, -6] references, sum=-4 test_dummy_threading leaked [0, -2, 0] references, sum=-2 test_functools leaked [-2, -2, -2] references, sum=-6 test_gc leaked [0, 4, 0] references, sum=4 test_gdbm leaked [-2, 0, 0] references, sum=-2 test_generators leaked [0, -2, 2] references, sum=0 test_importhooks leaked [-4, -4, 6] references, sum=-2 test_parser leaked [0, -2, 0] references, sum=-2 test_threadedtempfile leaked [80, -80, 0] references, sum=0 test_threadsignals leaked [0, -10, 0] references, sum=-10 test_urllib2_localnet leaked [3, 3, 120] references, sum=126 From nnorwitz at gmail.com Sun Jan 27 23:55:51 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Sun, 27 Jan 2008 17:55:51 -0500 Subject: [Python-checkins] Python Regression Test Failures all (1) Message-ID: <20080127225551.GA2084@python.psfb.org> test_grammar test_opcodes test_dict test_builtin test_exceptions test_types test_unittest test_doctest test_doctest2 test_MimeWriter test_StringIO test___all__ test___future__ test__locale test_abc test_abstract_numbers test_aepack test_aepack skipped -- No module named aepack test_al test_al skipped -- No module named al test_anydbm test_applesingle test_applesingle skipped -- No module named macostools test_array test_ast test_asynchat WARNING: failed to listen on port 54322, trying another WARNING: failed to listen on port 9907, trying another WARNING: failed to listen on port 10243, trying another WARNING: failed to listen on port 32999, trying another test_asyncore test_atexit test_audioop test_augassign test_base64 test_bastion test_bigaddrspace test_bigmem test_binascii test_binhex test_binop test_bisect test_bool test_bsddb test_bsddb185 test_bsddb185 skipped -- No module named bsddb185 test_bsddb3 test test_bsddb3 failed -- errors occurred; run in verbose mode for details test_buffer test_bufio test_bz2 test_cProfile test_calendar test_call test_capi test_cd test_cd skipped -- No module named cd test_cfgparser test_cgi test_charmapcodec test_cl test_cl skipped -- No module named cl test_class test_cmath test_cmd test_cmd_line test_cmd_line_script test_code test_codeccallbacks test_codecencodings_cn test_codecencodings_hk test_codecencodings_jp test_codecencodings_kr test_codecencodings_tw test_codecmaps_cn test_codecmaps_hk test_codecmaps_jp test_codecmaps_kr test_codecmaps_tw test_codecs test_codeop test_coding test_coercion test_collections test_colorsys test_commands test_compare test_compile test_compiler testCompileLibrary still working, be patient... test_complex test_complex_args test_contains test_contextlib test_cookie test_cookielib test_copy test_copy_reg test_cpickle test_crypt test_csv test_ctypes test_datetime test_dbm test_decimal test_decorators test_defaultdict test_deque test_descr test_descrtut test_difflib test_dircache test_dis test_distutils test_dl test_docxmlrpc test_dumbdbm test_dummy_thread test_dummy_threading test_email test_email_codecs test_email_renamed test_enumerate test_eof test_errno test_exception_variations test_extcall test_fcntl test_file test_filecmp test_fileinput test_float test_fnmatch test_fork1 test_format test_fpformat test_frozen test_ftplib test_funcattrs test_functools test_future test_gc test_gdbm test_generators test_genericpath test_genexps test_getargs test_getargs2 test_getopt test_gettext test_gl test_gl skipped -- No module named gl test_glob test_global test_grp test_gzip test_hash test_hashlib test_heapq test_hexoct test_hmac test_hotshot test_htmllib test_htmlparser test_httplib test_imageop test_imageop skipped -- No module named imgfile test_imaplib test_imgfile test_imgfile skipped -- No module named imgfile test_imp test_import test_importhooks test_index test_inspect test_ioctl test_ioctl skipped -- Unable to open /dev/tty test_isinstance test_iter test_iterlen test_itertools test_largefile test_list test_locale test_logging test_long test_long_future test_longexp test_macostools test_macostools skipped -- No module named macostools test_macpath test_mailbox test_marshal test_math test_md5 test_mhlib test_mimetools test_mimetypes test_minidom test_mmap test_module test_modulefinder test_multibytecodec test_multibytecodec_support test_multifile test_mutants test_netrc test_new test_nis test_normalization test_ntpath test_old_mailbox test_openpty test_operator test_optparse test_os test_parser test_peepholer test_pep247 test_pep263 test_pep277 test_pep277 skipped -- test works only on NT+ test_pep292 test_pep352 test_pickle test_pickletools test_pipes test_pkg test_pkgimport test_platform test_plistlib test_poll test_popen [8910 refs] [8910 refs] [8910 refs] test_popen2 test_poplib test_posix test_posixpath test_pow test_pprint test_profile test_profilehooks test_property test_pstats test_pty test_pwd test_pyclbr test_pyexpat test_queue test_quopri [9279 refs] [9279 refs] test_random test_rational test_re test_repr test_resource test_rfc822 test_richcmp test_robotparser test_runpy test_sax test_scope test_scriptpackages test_scriptpackages skipped -- No module named aetools test_select test_set test_sets test_sgmllib test_sha test_shelve test_shlex test_shutil test_signal test_site test_slice test_smtplib test_socket test_socket_ssl /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:108: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ssl_sock = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:74: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:157: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:171: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) test_socketserver test_softspace test_sort test_sqlite test_ssl test_startfile test_startfile skipped -- cannot import name startfile test_str test_strftime test_string test_stringprep test_strop test_strptime test_struct test_structmembers test_structseq test_subprocess [8905 refs] [8908 refs] [8905 refs] [8905 refs] [8905 refs] [8905 refs] [8905 refs] [8905 refs] [8905 refs] [8907 refs] [8908 refs] [10459 refs] [9123 refs] [8908 refs] [8905 refs] [8905 refs] [8905 refs] [8905 refs] [8905 refs] . [8905 refs] [8905 refs] this bit of output is from a test of stdout in a different process ... [8905 refs] [8905 refs] [9123 refs] test_sunaudiodev test_sunaudiodev skipped -- No module named sunaudiodev test_sundry test_symtable test_syntax test_sys [8905 refs] [8905 refs] test_tarfile test_tcl test_tcl skipped -- No module named _tkinter test_telnetlib test_tempfile [8911 refs] test_textwrap test_thread test_threaded_import test_threadedtempfile test_threading [11939 refs] test_threading_local test_threadsignals test_time test_timeout test_tokenize test_trace test_traceback test_transformer test_tuple test_typechecks test_ucn test_unary test_unicode test_unicode_file test_unicode_file skipped -- No Unicode filesystem semantics on this platform. test_unicodedata test_univnewlines test_unpack test_urllib test_urllib2 test_urllib2_localnet test_urllib2net test_urllibnet test_urlparse test_userdict test_userlist test_userstring test_uu test_uuid WARNING: uuid.getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._ifconfig_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._unixdll_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. test_wait3 test_wait4 test_warnings test_wave test_weakref test_whichdb test_winreg test_winreg skipped -- No module named _winreg test_winsound test_winsound skipped -- No module named winsound test_with test_wsgiref test_xdrlib test_xml_etree test_xml_etree_c test_xmllib test_xmlrpc test_xpickle test_xrange test_zipfile /tmp/python-test/local/lib/python2.6/test/test_zipfile.py:472: DeprecationWarning: struct integer overflow masking is deprecated zipfp.close() /tmp/python-test/local/lib/python2.6/test/test_zipfile.py:399: DeprecationWarning: struct integer overflow masking is deprecated zipfp.close() test_zipfile64 test_zipfile64 skipped -- test requires loads of disk-space bytes and a long time to run test_zipimport test_zlib 315 tests OK. 1 test failed: test_bsddb3 20 tests skipped: test_aepack test_al test_applesingle test_bsddb185 test_cd test_cl test_gl test_imageop test_imgfile test_ioctl test_macostools test_pep277 test_scriptpackages test_startfile test_sunaudiodev test_tcl test_unicode_file test_winreg test_winsound test_zipfile64 1 skip unexpected on linux2: test_ioctl [543270 refs] From python-checkins at python.org Mon Jan 28 00:08:47 2008 From: python-checkins at python.org (jeffrey.yasskin) Date: Mon, 28 Jan 2008 00:08:47 +0100 (CET) Subject: [Python-checkins] r60377 - in python/trunk: Lib/rational.py Lib/test/test_builtin.py Objects/floatobject.c Message-ID: <20080127230847.45BA61E402B@bag.python.org> Author: jeffrey.yasskin Date: Mon Jan 28 00:08:46 2008 New Revision: 60377 Modified: python/trunk/Lib/rational.py python/trunk/Lib/test/test_builtin.py python/trunk/Objects/floatobject.c Log: Moved Rational._binary_float_to_ratio() to float.as_integer_ratio() because it's useful outside of rational numbers. This is my first C code that had to do anything significant. Please be more careful when looking over it. Modified: python/trunk/Lib/rational.py ============================================================================== --- python/trunk/Lib/rational.py (original) +++ python/trunk/Lib/rational.py Mon Jan 28 00:08:46 2008 @@ -25,60 +25,6 @@ return a -def _binary_float_to_ratio(x): - """x -> (top, bot), a pair of ints s.t. x = top/bot. - - The conversion is done exactly, without rounding. - bot > 0 guaranteed. - Some form of binary fp is assumed. - Pass NaNs or infinities at your own risk. - - >>> _binary_float_to_ratio(10.0) - (10, 1) - >>> _binary_float_to_ratio(0.0) - (0, 1) - >>> _binary_float_to_ratio(-.25) - (-1, 4) - """ - # XXX Move this to floatobject.c with a name like - # float.as_integer_ratio() - - if x == 0: - return 0, 1 - f, e = math.frexp(x) - signbit = 1 - if f < 0: - f = -f - signbit = -1 - assert 0.5 <= f < 1.0 - # x = signbit * f * 2**e exactly - - # Suck up CHUNK bits at a time; 28 is enough so that we suck - # up all bits in 2 iterations for all known binary double- - # precision formats, and small enough to fit in an int. - CHUNK = 28 - top = 0 - # invariant: x = signbit * (top + f) * 2**e exactly - while f: - f = math.ldexp(f, CHUNK) - digit = trunc(f) - assert digit >> CHUNK == 0 - top = (top << CHUNK) | digit - f = f - digit - assert 0.0 <= f < 1.0 - e = e - CHUNK - assert top - - # Add in the sign bit. - top = signbit * top - - # now x = top * 2**e exactly; fold in 2**e - if e>0: - return (top * 2**e, 1) - else: - return (top, 2 ** -e) - - _RATIONAL_FORMAT = re.compile( r'^\s*(?P[-+]?)(?P\d+)' r'(?:/(?P\d+)|\.(?P\d+))?\s*$') @@ -163,7 +109,7 @@ (cls.__name__, f, type(f).__name__)) if math.isnan(f) or math.isinf(f): raise TypeError("Cannot convert %r to %s." % (f, cls.__name__)) - return cls(*_binary_float_to_ratio(f)) + return cls(*f.as_integer_ratio()) @classmethod def from_decimal(cls, dec): Modified: python/trunk/Lib/test/test_builtin.py ============================================================================== --- python/trunk/Lib/test/test_builtin.py (original) +++ python/trunk/Lib/test/test_builtin.py Mon Jan 28 00:08:46 2008 @@ -5,7 +5,7 @@ run_unittest, run_with_locale from operator import neg -import sys, warnings, cStringIO, random, UserDict +import sys, warnings, cStringIO, random, rational, UserDict warnings.filterwarnings("ignore", "hex../oct.. of negative int", FutureWarning, __name__) warnings.filterwarnings("ignore", "integer argument expected", @@ -688,6 +688,25 @@ self.assertAlmostEqual(float(Foo3(21)), 42.) self.assertRaises(TypeError, float, Foo4(42)) + def test_floatasratio(self): + R = rational.Rational + self.assertEqual(R(0, 1), + R(*float(0.0).as_integer_ratio())) + self.assertEqual(R(5, 2), + R(*float(2.5).as_integer_ratio())) + self.assertEqual(R(1, 2), + R(*float(0.5).as_integer_ratio())) + self.assertEqual(R(4728779608739021, 2251799813685248), + R(*float(2.1).as_integer_ratio())) + self.assertEqual(R(-4728779608739021, 2251799813685248), + R(*float(-2.1).as_integer_ratio())) + self.assertEqual(R(-2100, 1), + R(*float(-2100.0).as_integer_ratio())) + + self.assertRaises(OverflowError, float('inf').as_integer_ratio) + self.assertRaises(OverflowError, float('-inf').as_integer_ratio) + self.assertRaises(ValueError, float('nan').as_integer_ratio) + def test_getattr(self): import sys self.assert_(getattr(sys, 'stdout') is sys.stdout) Modified: python/trunk/Objects/floatobject.c ============================================================================== --- python/trunk/Objects/floatobject.c (original) +++ python/trunk/Objects/floatobject.c Mon Jan 28 00:08:46 2008 @@ -1161,6 +1161,163 @@ return v; } +static PyObject * +float_as_integer_ratio(PyObject *v) +{ + double self; + double float_part; + int exponent; + int is_negative; + const int chunk_size = 28; + PyObject *prev; + PyObject *py_chunk = NULL; + PyObject *py_exponent = NULL; + PyObject *numerator = NULL; + PyObject *denominator = NULL; + PyObject *result_pair = NULL; + PyNumberMethods *long_methods; + +#define INPLACE_UPDATE(obj, call) \ + prev = obj; \ + obj = call; \ + Py_DECREF(prev); \ + + CONVERT_TO_DOUBLE(v, self); + + if (Py_IS_INFINITY(self)) { + PyErr_SetString(PyExc_OverflowError, + "Cannot pass infinity to float.as_integer_ratio."); + return NULL; + } +#ifdef Py_NAN + if (Py_IS_NAN(self)) { + PyErr_SetString(PyExc_ValueError, + "Cannot pass nan to float.as_integer_ratio."); + return NULL; + } +#endif + + if (self == 0) { + numerator = PyInt_FromLong(0); + if (numerator == NULL) goto error; + denominator = PyInt_FromLong(1); + if (denominator == NULL) goto error; + result_pair = PyTuple_Pack(2, numerator, denominator); + /* Hand ownership over to the tuple. If the tuple + wasn't created successfully, we want to delete the + ints anyway. */ + Py_DECREF(numerator); + Py_DECREF(denominator); + return result_pair; + } + + /* XXX: Could perhaps handle FLT_RADIX!=2 by using ilogb and + scalbn, but those may not be in C89. */ + PyFPE_START_PROTECT("as_integer_ratio", goto error); + float_part = frexp(self, &exponent); + is_negative = 0; + if (float_part < 0) { + float_part = -float_part; + is_negative = 1; + /* 0.5 <= float_part < 1.0 */ + } + PyFPE_END_PROTECT(float_part); + /* abs(self) == float_part * 2**exponent exactly */ + + /* Suck up chunk_size bits at a time; 28 is enough so that we + suck up all bits in 2 iterations for all known binary + double-precision formats, and small enough to fit in a + long. */ + numerator = PyLong_FromLong(0); + if (numerator == NULL) goto error; + + long_methods = PyLong_Type.tp_as_number; + + py_chunk = PyLong_FromLong(chunk_size); + if (py_chunk == NULL) goto error; + + while (float_part != 0) { + /* invariant: abs(self) == + (numerator + float_part) * 2**exponent exactly */ + long digit; + PyObject *py_digit; + + PyFPE_START_PROTECT("as_integer_ratio", goto error); + /* Pull chunk_size bits out of float_part, into digits. */ + float_part = ldexp(float_part, chunk_size); + digit = (long)float_part; + float_part -= digit; + /* 0 <= float_part < 1 */ + exponent -= chunk_size; + PyFPE_END_PROTECT(float_part); + + /* Shift digits into numerator. */ + // numerator <<= chunk_size + INPLACE_UPDATE(numerator, + long_methods->nb_lshift(numerator, py_chunk)); + if (numerator == NULL) goto error; + + // numerator |= digit + py_digit = PyLong_FromLong(digit); + if (py_digit == NULL) goto error; + INPLACE_UPDATE(numerator, + long_methods->nb_or(numerator, py_digit)); + Py_DECREF(py_digit); + if (numerator == NULL) goto error; + } + + /* Add in the sign bit. */ + if (is_negative) { + INPLACE_UPDATE(numerator, + long_methods->nb_negative(numerator)); + if (numerator == NULL) goto error; + } + + /* now self = numerator * 2**exponent exactly; fold in 2**exponent */ + denominator = PyLong_FromLong(1); + py_exponent = PyLong_FromLong(labs(exponent)); + if (py_exponent == NULL) goto error; + INPLACE_UPDATE(py_exponent, + long_methods->nb_lshift(denominator, py_exponent)); + if (py_exponent == NULL) goto error; + if (exponent > 0) { + INPLACE_UPDATE(numerator, + long_methods->nb_multiply(numerator, + py_exponent)); + if (numerator == NULL) goto error; + } + else { + Py_DECREF(denominator); + denominator = py_exponent; + py_exponent = NULL; + } + + result_pair = PyTuple_Pack(2, numerator, denominator); + +#undef INPLACE_UPDATE +error: + Py_XDECREF(py_exponent); + Py_XDECREF(py_chunk); + Py_XDECREF(denominator); + Py_XDECREF(numerator); + return result_pair; +} + +PyDoc_STRVAR(float_as_integer_ratio_doc, +"float.as_integer_ratio() -> (int, int)\n" +"\n" +"Returns a pair of integers, not necessarily in lowest terms, whose\n" +"ratio is exactly equal to the original float. This method raises an\n" +"OverflowError on infinities and a ValueError on nans. The resulting\n" +"denominator will be positive.\n" +"\n" +">>> (10.0).as_integer_ratio()\n" +"(167772160L, 16777216L)\n" +">>> (0.0).as_integer_ratio()\n" +"(0, 1)\n" +">>> (-.25).as_integer_ratio()\n" +"(-134217728L, 536870912L)"); + static PyObject * float_subtype_new(PyTypeObject *type, PyObject *args, PyObject *kwds); @@ -1349,6 +1506,8 @@ "Returns self, the complex conjugate of any float."}, {"__trunc__", (PyCFunction)float_trunc, METH_NOARGS, "Returns the Integral closest to x between 0 and x."}, + {"as_integer_ratio", (PyCFunction)float_as_integer_ratio, METH_NOARGS, + float_as_integer_ratio_doc}, {"__getnewargs__", (PyCFunction)float_getnewargs, METH_NOARGS}, {"__getformat__", (PyCFunction)float_getformat, METH_O|METH_CLASS, float_getformat_doc}, From buildbot at python.org Mon Jan 28 00:23:25 2008 From: buildbot at python.org (buildbot at python.org) Date: Sun, 27 Jan 2008 23:23:25 +0000 Subject: [Python-checkins] buildbot failure in ARM Linux EABI 2.5 Message-ID: <20080127232325.713901E400C@bag.python.org> The Buildbot has detected a new failure of ARM Linux EABI 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/ARM%20Linux%20EABI%202.5/builds/6 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-linux-armeabi Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: neal.norwitz BUILD FAILED: failed failed slave lost sincerely, -The Buildbot From python-checkins at python.org Mon Jan 28 00:35:00 2008 From: python-checkins at python.org (christian.heimes) Date: Mon, 28 Jan 2008 00:35:00 +0100 (CET) Subject: [Python-checkins] r60378 - in python/trunk: Doc/c-api/type.rst Doc/library/sys.rst Include/object.h Lib/test/regrtest.py Misc/NEWS Objects/typeobject.c Python/pythonrun.c Python/sysmodule.c Message-ID: <20080127233500.A7FE71E4023@bag.python.org> Author: christian.heimes Date: Mon Jan 28 00:34:59 2008 New Revision: 60378 Modified: python/trunk/Doc/c-api/type.rst python/trunk/Doc/library/sys.rst python/trunk/Include/object.h python/trunk/Lib/test/regrtest.py python/trunk/Misc/NEWS python/trunk/Objects/typeobject.c python/trunk/Python/pythonrun.c python/trunk/Python/sysmodule.c Log: Added clear cache methods to clear the internal type lookup cache for ref leak test runs. Modified: python/trunk/Doc/c-api/type.rst ============================================================================== --- python/trunk/Doc/c-api/type.rst (original) +++ python/trunk/Doc/c-api/type.rst Mon Jan 28 00:34:59 2008 @@ -35,6 +35,13 @@ .. versionadded:: 2.2 +.. cfunction:: unsigned int PyType_ClearCache(void) + + Clears the internal lookup cache. Return the current version tag. + + .. versionadded:: 2.6 + + .. cfunction:: int PyType_HasFeature(PyObject *o, int feature) Return true if the type object *o* sets the feature *feature*. Type features Modified: python/trunk/Doc/library/sys.rst ============================================================================== --- python/trunk/Doc/library/sys.rst (original) +++ python/trunk/Doc/library/sys.rst Mon Jan 28 00:34:59 2008 @@ -58,6 +58,13 @@ A string containing the copyright pertaining to the Python interpreter. +.. function:: _cleartypecache() + + Clear the internal type lookup cache. + + .. versionadded:: 2.6 + + .. function:: _current_frames() Return a dictionary mapping each thread's identifier to the topmost stack frame Modified: python/trunk/Include/object.h ============================================================================== --- python/trunk/Include/object.h (original) +++ python/trunk/Include/object.h Mon Jan 28 00:34:59 2008 @@ -399,6 +399,7 @@ PyAPI_FUNC(PyObject *) PyType_GenericNew(PyTypeObject *, PyObject *, PyObject *); PyAPI_FUNC(PyObject *) _PyType_Lookup(PyTypeObject *, PyObject *); +PyAPI_FUNC(unsigned int) PyType_ClearCache(void); /* Generic operations on objects */ PyAPI_FUNC(int) PyObject_Print(PyObject *, FILE *, int); Modified: python/trunk/Lib/test/regrtest.py ============================================================================== --- python/trunk/Lib/test/regrtest.py (original) +++ python/trunk/Lib/test/regrtest.py Mon Jan 28 00:34:59 2008 @@ -709,6 +709,9 @@ sys.path_importer_cache.clear() sys.path_importer_cache.update(pic) + # clear type cache + sys._cleartypecache() + # Clear ABC registries, restoring previously saved ABC registries. for abc in [getattr(_abcoll, a) for a in _abcoll.__all__]: if not issubclass(abc, _Abstract): Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Mon Jan 28 00:34:59 2008 @@ -12,6 +12,9 @@ Core and builtins ----------------- +- Added ``PyType_ClearCache()`` and ``sys._cleartypecache`` to clear the + internal lookup cache for ref leak tests. + - Patch #1473257: generator objects gain a gi_code attribute. This is the same object as the func_code attribute of the function that produced the generator. Modified: python/trunk/Objects/typeobject.c ============================================================================== --- python/trunk/Objects/typeobject.c (original) +++ python/trunk/Objects/typeobject.c Mon Jan 28 00:34:59 2008 @@ -32,6 +32,24 @@ static struct method_cache_entry method_cache[1 << MCACHE_SIZE_EXP]; static unsigned int next_version_tag = 0; +static void type_modified(PyTypeObject *); + +unsigned int +PyType_ClearCache(void) +{ + Py_ssize_t i; + unsigned int cur_version_tag = next_version_tag - 1; + + for (i = 0; i < (1 << MCACHE_SIZE_EXP); i++) { + method_cache[i].version = 0; + Py_CLEAR(method_cache[i].name); + method_cache[i].value = NULL; + } + next_version_tag = 0; + /* mark all version tags as invalid */ + type_modified(&PyBaseObject_Type); + return cur_version_tag; +} static void type_modified(PyTypeObject *type) Modified: python/trunk/Python/pythonrun.c ============================================================================== --- python/trunk/Python/pythonrun.c (original) +++ python/trunk/Python/pythonrun.c Mon Jan 28 00:34:59 2008 @@ -377,6 +377,9 @@ Py_XDECREF(warnings_module); warnings_module = NULL; + /* Clear type lookup cache */ + PyType_ClearCache(); + /* Collect garbage. This may call finalizers; it's nice to call these * before all modules are destroyed. * XXX If a __del__ or weakref callback is triggered here, and tries to Modified: python/trunk/Python/sysmodule.c ============================================================================== --- python/trunk/Python/sysmodule.c (original) +++ python/trunk/Python/sysmodule.c Mon Jan 28 00:34:59 2008 @@ -754,6 +754,17 @@ 10. Number of stack pops performed by call_function()" ); +static PyObject * +sys_cleartypecache(PyObject* self, PyObject* args) +{ + PyType_ClearCache(); + Py_RETURN_NONE; +} + +PyDoc_STRVAR(cleartypecache_doc, +"_cleartypecache() -> None\n\ +Clear the internal type lookup cache."); + #ifdef __cplusplus extern "C" { #endif @@ -776,6 +787,8 @@ /* Might as well keep this in alphabetic order */ {"callstats", (PyCFunction)PyEval_GetCallStats, METH_NOARGS, callstats_doc}, + {"_cleartypecache", sys_cleartypecache, METH_NOARGS, + cleartypecache_doc}, {"_current_frames", sys_current_frames, METH_NOARGS, current_frames_doc}, {"displayhook", sys_displayhook, METH_O, displayhook_doc}, From buildbot at python.org Mon Jan 28 02:06:35 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 28 Jan 2008 01:06:35 +0000 Subject: [Python-checkins] buildbot failure in hppa Ubuntu trunk Message-ID: <20080128010635.353361E401F@bag.python.org> The Buildbot has detected a new failure of hppa Ubuntu trunk. Full details are available at: http://www.python.org/dev/buildbot/all/hppa%20Ubuntu%20trunk/builds/554 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-ubuntu-hppa Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: christian.heimes,neal.norwitz BUILD FAILED: failed test Excerpt from the test logfile: make: *** [buildbottest] Segmentation fault sincerely, -The Buildbot From python-checkins at python.org Mon Jan 28 02:33:24 2008 From: python-checkins at python.org (neal.norwitz) Date: Mon, 28 Jan 2008 02:33:24 +0100 (CET) Subject: [Python-checkins] r60380 - python/branches/release25-maint/Lib/test/test_resource.py Message-ID: <20080128013324.062B81E401B@bag.python.org> Author: neal.norwitz Date: Mon Jan 28 02:33:23 2008 New Revision: 60380 Modified: python/branches/release25-maint/Lib/test/test_resource.py Log: Try harder to provoke the exception since the ia64 buildbot still doesn't reliably produce an exception. Modified: python/branches/release25-maint/Lib/test/test_resource.py ============================================================================== --- python/branches/release25-maint/Lib/test/test_resource.py (original) +++ python/branches/release25-maint/Lib/test/test_resource.py Mon Jan 28 02:33:23 2008 @@ -33,6 +33,7 @@ limit_set = 0 f = open(TESTFN, "wb") f.write("X" * 1024) + f.flush() try: f.write("Y") f.flush() @@ -43,6 +44,7 @@ for i in range(5): time.sleep(.1) f.flush() + f.close() except IOError: if not limit_set: raise From buildbot at python.org Mon Jan 28 02:35:42 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 28 Jan 2008 01:35:42 +0000 Subject: [Python-checkins] buildbot failure in alpha Tru64 5.1 2.5 Message-ID: <20080128013542.E2A2F1E402D@bag.python.org> The Buildbot has detected a new failure of alpha Tru64 5.1 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/alpha%20Tru64%205.1%202.5/builds/425 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-tru64 Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: neal.norwitz BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_socket sincerely, -The Buildbot From buildbot at python.org Mon Jan 28 02:47:27 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 28 Jan 2008 01:47:27 +0000 Subject: [Python-checkins] buildbot failure in alpha Tru64 5.1 3.0 Message-ID: <20080128014727.4A1491E400C@bag.python.org> The Buildbot has detected a new failure of alpha Tru64 5.1 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/alpha%20Tru64%205.1%203.0/builds/578 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-tru64 Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: eric.smith BUILD FAILED: failed test Excerpt from the test logfile: sincerely, -The Buildbot From python-checkins at python.org Mon Jan 28 03:07:53 2008 From: python-checkins at python.org (christian.heimes) Date: Mon, 28 Jan 2008 03:07:53 +0100 (CET) Subject: [Python-checkins] r60381 - in python/trunk: Modules/_ctypes/_ctypes.c Modules/_ctypes/callbacks.c Objects/abstract.c Objects/complexobject.c Objects/fileobject.c Python/compile.c Message-ID: <20080128020753.DB23F1E400C@bag.python.org> Author: christian.heimes Date: Mon Jan 28 03:07:53 2008 New Revision: 60381 Modified: python/trunk/Modules/_ctypes/_ctypes.c python/trunk/Modules/_ctypes/callbacks.c python/trunk/Objects/abstract.c python/trunk/Objects/complexobject.c python/trunk/Objects/fileobject.c python/trunk/Python/compile.c Log: static PyObject* variables should use PyString_InternFromString() instead of PyObject_FromString() to store a python string in a function level static var. Modified: python/trunk/Modules/_ctypes/_ctypes.c ============================================================================== --- python/trunk/Modules/_ctypes/_ctypes.c (original) +++ python/trunk/Modules/_ctypes/_ctypes.c Mon Jan 28 03:07:53 2008 @@ -1529,9 +1529,9 @@ if (suffix == NULL) #ifdef WORDS_BIGENDIAN - suffix = PyString_FromString("_le"); + suffix = PyString_InternFromString("_le"); #else - suffix = PyString_FromString("_be"); + suffix = PyString_InternFromString("_be"); #endif Py_INCREF(name); @@ -4416,7 +4416,7 @@ } if (format == NULL) { - format = PyString_FromString("%s(%r)"); + format = PyString_InternFromString("%s(%r)"); if (format == NULL) return NULL; } Modified: python/trunk/Modules/_ctypes/callbacks.c ============================================================================== --- python/trunk/Modules/_ctypes/callbacks.c (original) +++ python/trunk/Modules/_ctypes/callbacks.c Mon Jan 28 03:07:53 2008 @@ -368,7 +368,7 @@ static PyObject *context; if (context == NULL) - context = PyString_FromString("_ctypes.DllGetClassObject"); + context = PyString_InternFromString("_ctypes.DllGetClassObject"); mod = PyImport_ImportModuleNoBlock("ctypes"); if (!mod) { @@ -447,7 +447,7 @@ static PyObject *context; if (context == NULL) - context = PyString_FromString("_ctypes.DllCanUnloadNow"); + context = PyString_InternFromString("_ctypes.DllCanUnloadNow"); mod = PyImport_ImportModuleNoBlock("ctypes"); if (!mod) { Modified: python/trunk/Objects/abstract.c ============================================================================== --- python/trunk/Objects/abstract.c (original) +++ python/trunk/Objects/abstract.c Mon Jan 28 03:07:53 2008 @@ -2142,7 +2142,7 @@ PyObject *bases; if (__bases__ == NULL) { - __bases__ = PyString_FromString("__bases__"); + __bases__ = PyString_InternFromString("__bases__"); if (__bases__ == NULL) return NULL; } @@ -2220,7 +2220,7 @@ int retval = 0; if (__class__ == NULL) { - __class__ = PyString_FromString("__class__"); + __class__ = PyString_InternFromString("__class__"); if (__class__ == NULL) return -1; } Modified: python/trunk/Objects/complexobject.c ============================================================================== --- python/trunk/Objects/complexobject.c (original) +++ python/trunk/Objects/complexobject.c Mon Jan 28 03:07:53 2008 @@ -261,14 +261,19 @@ return ((PyComplexObject *)op)->cval; } /* If not, use op's __complex__ method, if it exists */ - + /* return -1 on failure */ cv.real = -1.; cv.imag = 0.; + + if (complex_str == NULL) { + if (!(complex_str = PyString_InternFromString("__complex__"))) + return cv; + } if (PyInstance_Check(op)) { /* this can go away in python 3000 */ - if (PyObject_HasAttrString(op, "__complex__")) { + if (PyObject_HasAttr(op, complex_str)) { newop = PyObject_CallMethod(op, "__complex__", NULL); if (!newop) return cv; @@ -276,10 +281,6 @@ /* else try __float__ */ } else { PyObject *complexfunc; - if (!complex_str) { - if (!(complex_str = PyString_FromString("__complex__"))) - return cv; - } complexfunc = _PyType_Lookup(op->ob_type, complex_str); /* complexfunc is a borrowed reference */ if (complexfunc) { Modified: python/trunk/Objects/fileobject.c ============================================================================== --- python/trunk/Objects/fileobject.c (original) +++ python/trunk/Objects/fileobject.c Mon Jan 28 03:07:53 2008 @@ -1965,7 +1965,7 @@ assert(type != NULL && type->tp_alloc != NULL); if (not_yet_string == NULL) { - not_yet_string = PyString_FromString(""); + not_yet_string = PyString_InternFromString(""); if (not_yet_string == NULL) return NULL; } Modified: python/trunk/Python/compile.c ============================================================================== --- python/trunk/Python/compile.c (original) +++ python/trunk/Python/compile.c Mon Jan 28 03:07:53 2008 @@ -1153,7 +1153,7 @@ int addNone = 1; static PyObject *module; if (!module) { - module = PyString_FromString(""); + module = PyString_InternFromString(""); if (!module) return NULL; } @@ -2001,7 +2001,7 @@ if (Py_OptimizeFlag) return 1; if (assertion_error == NULL) { - assertion_error = PyString_FromString("AssertionError"); + assertion_error = PyString_InternFromString("AssertionError"); if (assertion_error == NULL) return 0; } From python-checkins at python.org Mon Jan 28 03:19:42 2008 From: python-checkins at python.org (mark.dickinson) Date: Mon, 28 Jan 2008 03:19:42 +0100 (CET) Subject: [Python-checkins] r60382 - in python/branches/trunk-math: Lib/test/test_math.py Modules/mathmodule.c Message-ID: <20080128021942.580011E4002@bag.python.org> Author: mark.dickinson Date: Mon Jan 28 03:19:42 2008 New Revision: 60382 Modified: python/branches/trunk-math/Lib/test/test_math.py python/branches/trunk-math/Modules/mathmodule.c Log: Fix up handling of special values in copysign and fmod. Modified: python/branches/trunk-math/Lib/test/test_math.py ============================================================================== --- python/branches/trunk-math/Lib/test/test_math.py (original) +++ python/branches/trunk-math/Lib/test/test_math.py Mon Jan 28 03:19:42 2008 @@ -150,6 +150,34 @@ self.assertRaises(TypeError, math.ceil, t) self.assertRaises(TypeError, math.ceil, t, 0) + if float.__getformat__("double").startswith("IEEE"): + def testCopysign(self): + self.assertRaises(TypeError, math.copysign) + # copysign should let us distinguish signs of zeros + self.assertEquals(copysign(1., 0.), 1.) + self.assertEquals(copysign(1., -0.), -1.) + self.assertEquals(copysign(INF, 0.), INF) + self.assertEquals(copysign(INF, -0.), NINF) + self.assertEquals(copysign(NINF, 0.), INF) + self.assertEquals(copysign(NINF, -0.), NINF) + # and of infinities + self.assertEquals(copysign(1., INF), 1.) + self.assertEquals(copysign(1., NINF), -1.) + self.assertEquals(copysign(INF, INF), INF) + self.assertEquals(copysign(INF, NINF), NINF) + self.assertEquals(copysign(NINF, INF), INF) + self.assertEquals(copysign(NINF, NINF), NINF) + self.assert_(math.isnan(copysign(NAN, 1.))) + self.assert_(math.isnan(copysign(NAN, INF))) + self.assert_(math.isnan(copysign(NAN, NINF))) + self.assert_(math.isnan(copysign(NAN, NAN))) + # copysign(INF, NAN) may be INF or it may be NINF, since + # we don't know whether the sign bit of NAN is set on any + # given platform. + self.assert_(math.isinf(copysign(INF, NAN))) + # similarly, copysign(2., NAN) could be 2. or -2. + self.assertEquals(abs(copysign(2., NAN)), 2.) + def testCos(self): self.assertRaises(TypeError, math.cos) self.ftest('cos(-pi/2)', math.cos(-math.pi/2), 0) @@ -234,6 +262,19 @@ self.ftest('fmod(-10,1)', math.fmod(-10,1), 0) self.ftest('fmod(-10,0.5)', math.fmod(-10,0.5), 0) self.ftest('fmod(-10,1.5)', math.fmod(-10,1.5), -1) + self.assert_(math.isnan(math.fmod(NAN, 1.))) + self.assert_(math.isnan(math.fmod(1., NAN))) + self.assert_(math.isnan(math.fmod(NAN, NAN))) + self.assertRaises(ValueError, math.fmod, 1., 0.) + self.assertRaises(ValueError, math.fmod, INF, 1.) + self.assertRaises(ValueError, math.fmod, NINF, 1.) + self.assertRaises(ValueError, math.fmod, INF, 0.) + self.assertEquals(math.fmod(3.0, INF), 3.0) + self.assertEquals(math.fmod(-3.0, INF), -3.0) + self.assertEquals(math.fmod(3.0, NINF), 3.0) + self.assertEquals(math.fmod(-3.0, NINF), -3.0) + self.assertEquals(math.fmod(0.0, 3.0), 0.0) + self.assertEquals(math.fmod(0.0, NINF), 0.0) def testFrexp(self): self.assertRaises(TypeError, math.frexp) Modified: python/branches/trunk-math/Modules/mathmodule.c ============================================================================== --- python/branches/trunk-math/Modules/mathmodule.c (original) +++ python/branches/trunk-math/Modules/mathmodule.c Mon Jan 28 03:19:42 2008 @@ -143,14 +143,18 @@ y = PyFloat_AsDouble(oy); if ((x == -1.0 || y == -1.0) && PyErr_Occurred()) return NULL; - if (Py_IS_NAN(x)) + if (Py_IS_NAN(x)) return PyFloat_FromDouble(x); if (Py_IS_NAN(y)) return PyFloat_FromDouble(y); errno = 0; - PyFPE_START_PROTECT("in math_2", return 0) + PyFPE_START_PROTECT("in math_2", return 0); x = (*func)(x, y); PyFPE_END_PROTECT(x); + + if (Py_IS_NAN(x)) + errno = EDOM; + if (errno && is_error(x)) return NULL; else @@ -191,8 +195,6 @@ "cos(x)\n\nReturn the cosine of x (measured in radians).") FUNC1(cosh, cosh, 1, "cosh(x)\n\nReturn the hyperbolic cosine of x.") -FUNC2(copysign, copysign, - "copysign(x,y)\n\nReturn x with the sign of y."); FUNC1(exp, exp, 1, "exp(x)\n\nReturn e raised to the power of x.") FUNC1(fabs, fabs, 0, @@ -384,6 +386,42 @@ PyDoc_STRVAR(math_log10_doc, "log10(x) -> the base 10 logarithm of x."); +/* copysign can't use math_2, since it doesn't follow the general rules for + NaNs (i.e., it's not true that copysign(x, y) is NaN whenever x or y is a + NaN.) */ + +static PyObject * +math_copysign(PyObject *self, PyObject *args) +{ + PyObject *ox, *oy; + double x, y; + + if (! PyArg_UnpackTuple(args, "copysign", 2, 2, &ox, &oy)) + return NULL; + x = PyFloat_AsDouble(ox); + y = PyFloat_AsDouble(oy); + if ((x == -1.0 || y == -1.0) && PyErr_Occurred()) + return NULL; + + errno = 0; + /* copysign shouldn't raise any floating-point + exception, but better to be safe than sorry */ + PyFPE_START_PROTECT("in math_copysign", return 0); + x = copysign(x, y); + PyFPE_END_PROTECT(x); + + if (errno && is_error(x)) + /* if errno is set then something unexpected happened. Better + to raise a Python exception than to return a possibly + incorrect value in this case. */ + return NULL; + else + return PyFloat_FromDouble(x); +} + +PyDoc_STRVAR(math_copysign_doc, + "copysign(x,y)\n\nReturn x with the sign of y."); + static PyObject * math_pow(PyObject *self, PyObject *args) { From buildbot at python.org Mon Jan 28 04:48:50 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 28 Jan 2008 03:48:50 +0000 Subject: [Python-checkins] buildbot failure in ARM Linux trunk Message-ID: <20080128034850.CBFC71E4002@bag.python.org> The Buildbot has detected a new failure of ARM Linux trunk. Full details are available at: http://www.python.org/dev/buildbot/all/ARM%20Linux%20trunk/builds/3 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-linux-arm Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: amaury.forgeotdarc,andrew.kuchling,armin.rigo,christian.heimes,georg.brandl,gregory.p.smith,guido.van.rossum,jeffrey.yasskin,kurt.kaiser,neal.norwitz,raymond.hettinger,thomas.heller,thomas.wouters,vinay.sajip BUILD FAILED: failed test Excerpt from the test logfile: sincerely, -The Buildbot From buildbot at python.org Mon Jan 28 05:30:10 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 28 Jan 2008 04:30:10 +0000 Subject: [Python-checkins] buildbot failure in x86 XP-4 2.5 Message-ID: <20080128043010.30F271E4002@bag.python.org> The Buildbot has detected a new failure of x86 XP-4 2.5. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20XP-4%202.5/builds/121 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-windows Build Reason: Build Source Stamp: [branch branches/release25-maint] HEAD Blamelist: neal.norwitz BUILD FAILED: failed compile sincerely, -The Buildbot From buildbot at python.org Mon Jan 28 05:31:12 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 28 Jan 2008 04:31:12 +0000 Subject: [Python-checkins] buildbot failure in ARM Linux 3.0 Message-ID: <20080128043112.950301E402B@bag.python.org> The Buildbot has detected a new failure of ARM Linux 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/ARM%20Linux%203.0/builds/3 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-linux-arm Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: alexandre.vassalotti,christian.heimes,eric.smith,georg.brandl,neal.norwitz,raymond.hettinger,thomas.heller,thomas.wouters,walter.doerwald BUILD FAILED: failed compile sincerely, -The Buildbot From buildbot at python.org Mon Jan 28 07:11:28 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 28 Jan 2008 06:11:28 +0000 Subject: [Python-checkins] buildbot failure in alpha Tru64 5.1 3.0 Message-ID: <20080128061128.A8AF61E4002@bag.python.org> The Buildbot has detected a new failure of alpha Tru64 5.1 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/alpha%20Tru64%205.1%203.0/builds/580 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-tru64 Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: sincerely, -The Buildbot From python-checkins at python.org Mon Jan 28 09:32:03 2008 From: python-checkins at python.org (martin.v.loewis) Date: Mon, 28 Jan 2008 09:32:03 +0100 (CET) Subject: [Python-checkins] r60386 - tracker/instances/python-dev/html/msg.index.html Message-ID: <20080128083203.505741E4026@bag.python.org> Author: martin.v.loewis Date: Mon Jan 28 09:32:02 2008 New Revision: 60386 Modified: tracker/instances/python-dev/html/msg.index.html Log: Add msgid and link to message into index. Modified: tracker/instances/python-dev/html/msg.index.html ============================================================================== --- tracker/instances/python-dev/html/msg.index.html (original) +++ tracker/instances/python-dev/html/msg.index.html Mon Jan 28 09:32:02 2008 @@ -6,14 +6,15 @@ i18n:translate="">Message listing - + + - + From python-checkins at python.org Mon Jan 28 09:42:22 2008 From: python-checkins at python.org (thomas.heller) Date: Mon, 28 Jan 2008 09:42:22 +0100 (CET) Subject: [Python-checkins] r60387 - in python/branches/release25-maint: Lib/ctypes/test/test_funcptr.py Misc/NEWS Modules/_ctypes/_ctypes.c Message-ID: <20080128084222.870361E402D@bag.python.org> Author: thomas.heller Date: Mon Jan 28 09:42:22 2008 New Revision: 60387 Modified: python/branches/release25-maint/Lib/ctypes/test/test_funcptr.py python/branches/release25-maint/Misc/NEWS python/branches/release25-maint/Modules/_ctypes/_ctypes.c Log: Revert rev. 59926, it breaks comtypes (I need to further examine this). Modified: python/branches/release25-maint/Lib/ctypes/test/test_funcptr.py ============================================================================== --- python/branches/release25-maint/Lib/ctypes/test/test_funcptr.py (original) +++ python/branches/release25-maint/Lib/ctypes/test/test_funcptr.py Mon Jan 28 09:42:22 2008 @@ -123,11 +123,5 @@ self.failUnlessEqual(strtok(None, "\n"), "c") self.failUnlessEqual(strtok(None, "\n"), None) - def test_NULL_funcptr(self): - tp = CFUNCTYPE(c_int) - func = tp() # NULL function pointer - # raise a ValueError when we try to call it - self.assertRaises(ValueError, func) - if __name__ == '__main__': unittest.main() Modified: python/branches/release25-maint/Misc/NEWS ============================================================================== --- python/branches/release25-maint/Misc/NEWS (original) +++ python/branches/release25-maint/Misc/NEWS Mon Jan 28 09:42:22 2008 @@ -217,8 +217,6 @@ - Fix a potential 'SystemError: NULL result without error' in _ctypes. -- Prevent a segfault when a ctypes NULL function pointer is called. - - Bug #1301: Bad assert in _tkinter fixed. - Patch #1114: fix curses module compilation on 64-bit AIX, & possibly Modified: python/branches/release25-maint/Modules/_ctypes/_ctypes.c ============================================================================== --- python/branches/release25-maint/Modules/_ctypes/_ctypes.c (original) +++ python/branches/release25-maint/Modules/_ctypes/_ctypes.c Mon Jan 28 09:42:22 2008 @@ -3305,11 +3305,6 @@ pProc = *(void **)self->b_ptr; - if (pProc == NULL) { - PyErr_SetString(PyExc_ValueError, - "attempt to call NULL function pointer"); - return NULL; - } #ifdef MS_WIN32 if (self->index) { /* It's a COM method */ From python-checkins at python.org Mon Jan 28 09:44:14 2008 From: python-checkins at python.org (thomas.heller) Date: Mon, 28 Jan 2008 09:44:14 +0100 (CET) Subject: [Python-checkins] r60388 - in python/trunk: Lib/ctypes/test/test_funcptr.py Modules/_ctypes/_ctypes.c Message-ID: <20080128084414.06CE01E4002@bag.python.org> Author: thomas.heller Date: Mon Jan 28 09:44:13 2008 New Revision: 60388 Modified: python/trunk/Lib/ctypes/test/test_funcptr.py python/trunk/Modules/_ctypes/_ctypes.c Log: Revert rev. 59925, it breaks comtypes (I need to further examine this). Modified: python/trunk/Lib/ctypes/test/test_funcptr.py ============================================================================== --- python/trunk/Lib/ctypes/test/test_funcptr.py (original) +++ python/trunk/Lib/ctypes/test/test_funcptr.py Mon Jan 28 09:44:13 2008 @@ -123,11 +123,5 @@ self.failUnlessEqual(strtok(None, "\n"), "c") self.failUnlessEqual(strtok(None, "\n"), None) - def test_NULL_funcptr(self): - tp = CFUNCTYPE(c_int) - func = tp() # NULL function pointer - # raise a ValueError when we try to call it - self.assertRaises(ValueError, func) - if __name__ == '__main__': unittest.main() Modified: python/trunk/Modules/_ctypes/_ctypes.c ============================================================================== --- python/trunk/Modules/_ctypes/_ctypes.c (original) +++ python/trunk/Modules/_ctypes/_ctypes.c Mon Jan 28 09:44:13 2008 @@ -3435,11 +3435,6 @@ pProc = *(void **)self->b_ptr; - if (pProc == NULL) { - PyErr_SetString(PyExc_ValueError, - "attempt to call NULL function pointer"); - return NULL; - } #ifdef MS_WIN32 if (self->index) { /* It's a COM method */ From python-checkins at python.org Mon Jan 28 09:44:41 2008 From: python-checkins at python.org (martin.v.loewis) Date: Mon, 28 Jan 2008 09:44:41 +0100 (CET) Subject: [Python-checkins] r60389 - tracker/instances/python-dev/html/page.html Message-ID: <20080128084441.B44D11E4002@bag.python.org> Author: martin.v.loewis Date: Mon Jan 28 09:44:41 2008 New Revision: 60389 Modified: tracker/instances/python-dev/html/page.html Log: Add View Spam link for coordinators. Modified: tracker/instances/python-dev/html/page.html ============================================================================== --- tracker/instances/python-dev/html/page.html (original) +++ tracker/instances/python-dev/html/page.html Mon Jan 28 09:44:41 2008 @@ -190,6 +190,8 @@
  • Edit Keywords
  • +
  • View Spam +
  • From buildbot at python.org Mon Jan 28 10:43:21 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 28 Jan 2008 09:43:21 +0000 Subject: [Python-checkins] buildbot failure in ARM Linux EABI trunk Message-ID: <20080128094321.7CCC21E4002@bag.python.org> The Buildbot has detected a new failure of ARM Linux EABI trunk. Full details are available at: http://www.python.org/dev/buildbot/all/ARM%20Linux%20EABI%20trunk/builds/17 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-linux-armeabi Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: christian.heimes,georg.brandl,jeffrey.yasskin,neal.norwitz BUILD FAILED: failed test Excerpt from the test logfile: sincerely, -The Buildbot From buildbot at python.org Mon Jan 28 11:22:10 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 28 Jan 2008 10:22:10 +0000 Subject: [Python-checkins] buildbot failure in ARM Linux EABI 3.0 Message-ID: <20080128102210.C53AE1E4002@bag.python.org> The Buildbot has detected a new failure of ARM Linux EABI 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/ARM%20Linux%20EABI%203.0/builds/13 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-linux-armeabi Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: alexandre.vassalotti,christian.heimes,eric.smith,georg.brandl BUILD FAILED: failed compile sincerely, -The Buildbot From nnorwitz at gmail.com Mon Jan 28 11:44:45 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Mon, 28 Jan 2008 05:44:45 -0500 Subject: [Python-checkins] Python Regression Test Failures refleak (1) Message-ID: <20080128104445.GA12943@python.psfb.org> test_ftplib leaked [-6, -84, 0] references, sum=-90 test_popen2 leaked [0, 26, 0] references, sum=26 test_threadsignals leaked [0, -8, 0] references, sum=-8 test_urllib2_localnet leaked [3, 3, 3] references, sum=9 From buildbot at python.org Mon Jan 28 11:59:17 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 28 Jan 2008 10:59:17 +0000 Subject: [Python-checkins] buildbot failure in alpha Tru64 5.1 trunk Message-ID: <20080128105917.4629D1E400C@bag.python.org> The Buildbot has detected a new failure of alpha Tru64 5.1 trunk. Full details are available at: http://www.python.org/dev/buildbot/all/alpha%20Tru64%205.1%20trunk/builds/2431 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-tru64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: thomas.heller BUILD FAILED: failed test Excerpt from the test logfile: 3 tests failed: test_asynchat test_smtplib test_socket ====================================================================== FAIL: testInterruptedTimeout (test.test_socket.TCPTimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/net/taipan/scratch1/nnorwitz/python/trunk.norwitz-tru64/build/Lib/test/test_socket.py", line 994, in testInterruptedTimeout self.fail("got Alarm in wrong place") AssertionError: got Alarm in wrong place sincerely, -The Buildbot From buildbot at python.org Mon Jan 28 12:06:02 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 28 Jan 2008 11:06:02 +0000 Subject: [Python-checkins] buildbot failure in x86 FreeBSD trunk Message-ID: <20080128110602.4298D1E400C@bag.python.org> The Buildbot has detected a new failure of x86 FreeBSD trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20FreeBSD%20trunk/builds/490 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-freebsd Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: christian.heimes,georg.brandl,jeffrey.yasskin BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 227, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 268, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 281, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 560, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 227, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 268, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 281, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 560, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/bsddb/test/test_thread.py", line 284, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30995, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') 1 test failed: test_xmlrpc Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 227, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 268, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 281, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 560, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable sincerely, -The Buildbot From python-checkins at python.org Mon Jan 28 15:39:39 2008 From: python-checkins at python.org (christian.heimes) Date: Mon, 28 Jan 2008 15:39:39 +0100 (CET) Subject: [Python-checkins] r60391 - python/branches/trunk-math/Modules/_fileio.c Message-ID: <20080128143939.910581E400D@bag.python.org> Author: christian.heimes Date: Mon Jan 28 15:39:39 2008 New Revision: 60391 Added: python/branches/trunk-math/Modules/_fileio.c (contents, props changed) Log: Added lost file. Memo to me: svnmerge doesn't add new files to the commit list. Added: python/branches/trunk-math/Modules/_fileio.c ============================================================================== --- (empty file) +++ python/branches/trunk-math/Modules/_fileio.c Mon Jan 28 15:39:39 2008 @@ -0,0 +1,927 @@ +/* Author: Daniel Stutzbach */ + +#define PY_SSIZE_T_CLEAN +#include "Python.h" +#include +#include +#include +#include /* For offsetof */ + +/* + * Known likely problems: + * + * - Files larger then 2**32-1 + * - Files with unicode filenames + * - Passing numbers greater than 2**32-1 when an integer is expected + * - Making it work on Windows and other oddball platforms + * + * To Do: + * + * - autoconfify header file inclusion + */ + +#ifdef MS_WINDOWS +/* can simulate truncate with Win32 API functions; see file_truncate */ +#define HAVE_FTRUNCATE +#define WIN32_LEAN_AND_MEAN +#include +#endif + +typedef struct { + PyObject_HEAD + int fd; + unsigned readable : 1; + unsigned writable : 1; + int seekable : 2; /* -1 means unknown */ + int closefd : 1; + PyObject *weakreflist; +} PyFileIOObject; + +PyTypeObject PyFileIO_Type; + +#define PyFileIO_Check(op) (PyObject_TypeCheck((op), &PyFileIO_Type)) + +/* Returns 0 on success, errno (which is < 0) on failure. */ +static int +internal_close(PyFileIOObject *self) +{ + int save_errno = 0; + if (self->fd >= 0) { + int fd = self->fd; + self->fd = -1; + Py_BEGIN_ALLOW_THREADS + if (close(fd) < 0) + save_errno = errno; + Py_END_ALLOW_THREADS + } + return save_errno; +} + +static PyObject * +fileio_close(PyFileIOObject *self) +{ + if (!self->closefd) { + if (PyErr_WarnEx(PyExc_RuntimeWarning, + "Trying to close unclosable fd!", 3) < 0) { + return NULL; + } + Py_RETURN_NONE; + } + errno = internal_close(self); + if (errno < 0) { + PyErr_SetFromErrno(PyExc_IOError); + return NULL; + } + + Py_RETURN_NONE; +} + +static PyObject * +fileio_new(PyTypeObject *type, PyObject *args, PyObject *kews) +{ + PyFileIOObject *self; + + assert(type != NULL && type->tp_alloc != NULL); + + self = (PyFileIOObject *) type->tp_alloc(type, 0); + if (self != NULL) { + self->fd = -1; + self->weakreflist = NULL; + } + + return (PyObject *) self; +} + +/* On Unix, open will succeed for directories. + In Python, there should be no file objects referring to + directories, so we need a check. */ + +static int +dircheck(PyFileIOObject* self) +{ +#if defined(HAVE_FSTAT) && defined(S_IFDIR) && defined(EISDIR) + struct stat buf; + if (self->fd < 0) + return 0; + if (fstat(self->fd, &buf) == 0 && S_ISDIR(buf.st_mode)) { +#ifdef HAVE_STRERROR + char *msg = strerror(EISDIR); +#else + char *msg = "Is a directory"; +#endif + PyObject *exc; + internal_close(self); + + exc = PyObject_CallFunction(PyExc_IOError, "(is)", + EISDIR, msg); + PyErr_SetObject(PyExc_IOError, exc); + Py_XDECREF(exc); + return -1; + } +#endif + return 0; +} + + +static int +fileio_init(PyObject *oself, PyObject *args, PyObject *kwds) +{ + PyFileIOObject *self = (PyFileIOObject *) oself; + static char *kwlist[] = {"file", "mode", "closefd", NULL}; + char *name = NULL; + char *mode = "r"; + char *s; +#ifdef MS_WINDOWS + Py_UNICODE *widename = NULL; +#endif + int ret = 0; + int rwa = 0, plus = 0, append = 0; + int flags = 0; + int fd = -1; + int closefd = 1; + + assert(PyFileIO_Check(oself)); + if (self->fd >= 0) { + /* Have to close the existing file first. */ + if (internal_close(self) < 0) + return -1; + } + + if (PyArg_ParseTupleAndKeywords(args, kwds, "i|si:fileio", + kwlist, &fd, &mode, &closefd)) { + if (fd < 0) { + PyErr_SetString(PyExc_ValueError, + "Negative filedescriptor"); + return -1; + } + } + else { + PyErr_Clear(); + +#ifdef Py_WIN_WIDE_FILENAMES + if (GetVersion() < 0x80000000) { + /* On NT, so wide API available */ + PyObject *po; + if (PyArg_ParseTupleAndKeywords(args, kwds, "U|si:fileio", + kwlist, &po, &mode, &closefd) + ) { + widename = PyUnicode_AS_UNICODE(po); + } else { + /* Drop the argument parsing error as narrow + strings are also valid. */ + PyErr_Clear(); + } + } + if (widename == NULL) +#endif + { + if (!PyArg_ParseTupleAndKeywords(args, kwds, "et|si:fileio", + kwlist, + Py_FileSystemDefaultEncoding, + &name, &mode, &closefd)) + goto error; + } + } + + self->readable = self->writable = 0; + self->seekable = -1; + s = mode; + while (*s) { + switch (*s++) { + case 'r': + if (rwa) { + bad_mode: + PyErr_SetString(PyExc_ValueError, + "Must have exactly one of read/write/append mode"); + goto error; + } + rwa = 1; + self->readable = 1; + break; + case 'w': + if (rwa) + goto bad_mode; + rwa = 1; + self->writable = 1; + flags |= O_CREAT | O_TRUNC; + break; + case 'a': + if (rwa) + goto bad_mode; + rwa = 1; + self->writable = 1; + flags |= O_CREAT; + append = 1; + break; + case '+': + if (plus) + goto bad_mode; + self->readable = self->writable = 1; + plus = 1; + break; + default: + PyErr_Format(PyExc_ValueError, + "invalid mode: %.200s", mode); + goto error; + } + } + + if (!rwa) + goto bad_mode; + + if (self->readable && self->writable) + flags |= O_RDWR; + else if (self->readable) + flags |= O_RDONLY; + else + flags |= O_WRONLY; + +#ifdef O_BINARY + flags |= O_BINARY; +#endif + +#ifdef O_APPEND + if (append) + flags |= O_APPEND; +#endif + + if (fd >= 0) { + self->fd = fd; + self->closefd = closefd; + } + else { + self->closefd = 1; + if (!closefd) { + PyErr_SetString(PyExc_ValueError, + "Cannot use closefd=True with file name"); + goto error; + } + + Py_BEGIN_ALLOW_THREADS + errno = 0; +#ifdef MS_WINDOWS + if (widename != NULL) + self->fd = _wopen(widename, flags, 0666); + else +#endif + self->fd = open(name, flags, 0666); + Py_END_ALLOW_THREADS + if (self->fd < 0 || dircheck(self) < 0) { +#ifdef MS_WINDOWS + PyErr_SetFromErrnoWithUnicodeFilename(PyExc_IOError, widename); +#else + PyErr_SetFromErrnoWithFilename(PyExc_IOError, name); +#endif + goto error; + } + } + + goto done; + + error: + ret = -1; + + done: + PyMem_Free(name); + return ret; +} + +static void +fileio_dealloc(PyFileIOObject *self) +{ + if (self->weakreflist != NULL) + PyObject_ClearWeakRefs((PyObject *) self); + + if (self->fd >= 0 && self->closefd) { + errno = internal_close(self); + if (errno < 0) { +#ifdef HAVE_STRERROR + PySys_WriteStderr("close failed: [Errno %d] %s\n", + errno, strerror(errno)); +#else + PySys_WriteStderr("close failed: [Errno %d]\n", errno); +#endif + } + } + + Py_TYPE(self)->tp_free((PyObject *)self); +} + +static PyObject * +err_closed(void) +{ + PyErr_SetString(PyExc_ValueError, "I/O operation on closed file"); + return NULL; +} + +static PyObject * +err_mode(char *action) +{ + PyErr_Format(PyExc_ValueError, "File not open for %s", action); + return NULL; +} + +static PyObject * +fileio_fileno(PyFileIOObject *self) +{ + if (self->fd < 0) + return err_closed(); + return PyInt_FromLong((long) self->fd); +} + +static PyObject * +fileio_readable(PyFileIOObject *self) +{ + if (self->fd < 0) + return err_closed(); + return PyBool_FromLong((long) self->readable); +} + +static PyObject * +fileio_writable(PyFileIOObject *self) +{ + if (self->fd < 0) + return err_closed(); + return PyBool_FromLong((long) self->writable); +} + +static PyObject * +fileio_seekable(PyFileIOObject *self) +{ + if (self->fd < 0) + return err_closed(); + if (self->seekable < 0) { + int ret; + Py_BEGIN_ALLOW_THREADS + ret = lseek(self->fd, 0, SEEK_CUR); + Py_END_ALLOW_THREADS + if (ret < 0) + self->seekable = 0; + else + self->seekable = 1; + } + return PyBool_FromLong((long) self->seekable); +} + +static PyObject * +fileio_readinto(PyFileIOObject *self, PyObject *args) +{ + char *ptr; + Py_ssize_t n; + + if (self->fd < 0) + return err_closed(); + if (!self->readable) + return err_mode("reading"); + + if (!PyArg_ParseTuple(args, "w#", &ptr, &n)) + return NULL; + + Py_BEGIN_ALLOW_THREADS + errno = 0; + n = read(self->fd, ptr, n); + Py_END_ALLOW_THREADS + if (n < 0) { + if (errno == EAGAIN) + Py_RETURN_NONE; + PyErr_SetFromErrno(PyExc_IOError); + return NULL; + } + + return PyLong_FromSsize_t(n); +} + +#define DEFAULT_BUFFER_SIZE (8*1024) + +static PyObject * +fileio_readall(PyFileIOObject *self) +{ + PyObject *result; + Py_ssize_t total = 0; + int n; + + result = PyString_FromStringAndSize(NULL, DEFAULT_BUFFER_SIZE); + if (result == NULL) + return NULL; + + while (1) { + Py_ssize_t newsize = total + DEFAULT_BUFFER_SIZE; + if (PyString_GET_SIZE(result) < newsize) { + if (_PyString_Resize(&result, newsize) < 0) { + if (total == 0) { + Py_DECREF(result); + return NULL; + } + PyErr_Clear(); + break; + } + } + Py_BEGIN_ALLOW_THREADS + errno = 0; + n = read(self->fd, + PyString_AS_STRING(result) + total, + newsize - total); + Py_END_ALLOW_THREADS + if (n == 0) + break; + if (n < 0) { + if (total > 0) + break; + if (errno == EAGAIN) { + Py_DECREF(result); + Py_RETURN_NONE; + } + Py_DECREF(result); + PyErr_SetFromErrno(PyExc_IOError); + return NULL; + } + total += n; + } + + if (PyString_GET_SIZE(result) > total) { + if (_PyString_Resize(&result, total) < 0) { + /* This should never happen, but just in case */ + Py_DECREF(result); + return NULL; + } + } + return result; +} + +static PyObject * +fileio_read(PyFileIOObject *self, PyObject *args) +{ + char *ptr; + Py_ssize_t n; + Py_ssize_t size = -1; + PyObject *bytes; + + if (self->fd < 0) + return err_closed(); + if (!self->readable) + return err_mode("reading"); + + if (!PyArg_ParseTuple(args, "|n", &size)) + return NULL; + + if (size < 0) { + return fileio_readall(self); + } + + bytes = PyString_FromStringAndSize(NULL, size); + if (bytes == NULL) + return NULL; + ptr = PyString_AS_STRING(bytes); + + Py_BEGIN_ALLOW_THREADS + errno = 0; + n = read(self->fd, ptr, size); + Py_END_ALLOW_THREADS + + if (n < 0) { + if (errno == EAGAIN) + Py_RETURN_NONE; + PyErr_SetFromErrno(PyExc_IOError); + return NULL; + } + + if (n != size) { + if (_PyString_Resize(&bytes, n) < 0) { + Py_DECREF(bytes); + return NULL; + } + } + + return (PyObject *) bytes; +} + +static PyObject * +fileio_write(PyFileIOObject *self, PyObject *args) +{ + Py_ssize_t n; + char *ptr; + + if (self->fd < 0) + return err_closed(); + if (!self->writable) + return err_mode("writing"); + + if (!PyArg_ParseTuple(args, "s#", &ptr, &n)) + return NULL; + + Py_BEGIN_ALLOW_THREADS + errno = 0; + n = write(self->fd, ptr, n); + Py_END_ALLOW_THREADS + + if (n < 0) { + if (errno == EAGAIN) + Py_RETURN_NONE; + PyErr_SetFromErrno(PyExc_IOError); + return NULL; + } + + return PyLong_FromSsize_t(n); +} + +/* XXX Windows support below is likely incomplete */ + +#if defined(MS_WIN64) || defined(MS_WINDOWS) +typedef PY_LONG_LONG Py_off_t; +#else +typedef off_t Py_off_t; +#endif + +/* Cribbed from posix_lseek() */ +static PyObject * +portable_lseek(int fd, PyObject *posobj, int whence) +{ + Py_off_t pos, res; + +#ifdef SEEK_SET + /* Turn 0, 1, 2 into SEEK_{SET,CUR,END} */ + switch (whence) { +#if SEEK_SET != 0 + case 0: whence = SEEK_SET; break; +#endif +#if SEEK_CUR != 1 + case 1: whence = SEEK_CUR; break; +#endif +#if SEEL_END != 2 + case 2: whence = SEEK_END; break; +#endif + } +#endif /* SEEK_SET */ + + if (posobj == NULL) + pos = 0; + else { + if(PyFloat_Check(posobj)) { + PyErr_SetString(PyExc_TypeError, "an integer is required"); + return NULL; + } +#if !defined(HAVE_LARGEFILE_SUPPORT) + pos = PyLong_AsLong(posobj); +#else + pos = PyLong_Check(posobj) ? + PyLong_AsLongLong(posobj) : PyLong_AsLong(posobj); +#endif + if (PyErr_Occurred()) + return NULL; + } + + Py_BEGIN_ALLOW_THREADS +#if defined(MS_WIN64) || defined(MS_WINDOWS) + res = _lseeki64(fd, pos, whence); +#else + res = lseek(fd, pos, whence); +#endif + Py_END_ALLOW_THREADS + if (res < 0) + return PyErr_SetFromErrno(PyExc_IOError); + +#if !defined(HAVE_LARGEFILE_SUPPORT) + return PyLong_FromLong(res); +#else + return PyLong_FromLongLong(res); +#endif +} + +static PyObject * +fileio_seek(PyFileIOObject *self, PyObject *args) +{ + PyObject *posobj; + int whence = 0; + + if (self->fd < 0) + return err_closed(); + + if (!PyArg_ParseTuple(args, "O|i", &posobj, &whence)) + return NULL; + + return portable_lseek(self->fd, posobj, whence); +} + +static PyObject * +fileio_tell(PyFileIOObject *self, PyObject *args) +{ + if (self->fd < 0) + return err_closed(); + + return portable_lseek(self->fd, NULL, 1); +} + +#ifdef HAVE_FTRUNCATE +static PyObject * +fileio_truncate(PyFileIOObject *self, PyObject *args) +{ + PyObject *posobj = NULL; + Py_off_t pos; + int ret; + int fd; + + fd = self->fd; + if (fd < 0) + return err_closed(); + if (!self->writable) + return err_mode("writing"); + + if (!PyArg_ParseTuple(args, "|O", &posobj)) + return NULL; + + if (posobj == Py_None || posobj == NULL) { + posobj = portable_lseek(fd, NULL, 1); + if (posobj == NULL) + return NULL; + } + else { + Py_INCREF(posobj); + } + +#if !defined(HAVE_LARGEFILE_SUPPORT) + pos = PyLong_AsLong(posobj); +#else + pos = PyLong_Check(posobj) ? + PyLong_AsLongLong(posobj) : PyLong_AsLong(posobj); +#endif + if (PyErr_Occurred()) { + Py_DECREF(posobj); + return NULL; + } + +#ifdef MS_WINDOWS + /* MS _chsize doesn't work if newsize doesn't fit in 32 bits, + so don't even try using it. */ + { + HANDLE hFile; + PyObject *pos2, *oldposobj; + + /* store the current position */ + oldposobj = portable_lseek(self->fd, NULL, 1); + if (oldposobj == NULL) { + Py_DECREF(posobj); + return NULL; + } + + /* Have to move current pos to desired endpoint on Windows. */ + errno = 0; + pos2 = portable_lseek(fd, posobj, SEEK_SET); + if (pos2 == NULL) { + Py_DECREF(posobj); + Py_DECREF(oldposobj); + return NULL; + } + Py_DECREF(pos2); + + /* Truncate. Note that this may grow the file! */ + Py_BEGIN_ALLOW_THREADS + errno = 0; + hFile = (HANDLE)_get_osfhandle(fd); + ret = hFile == (HANDLE)-1; + if (ret == 0) { + ret = SetEndOfFile(hFile) == 0; + if (ret) + errno = EACCES; + } + Py_END_ALLOW_THREADS + + if (ret == 0) { + /* Move to the previous position in the file */ + pos2 = portable_lseek(fd, oldposobj, SEEK_SET); + if (pos2 == NULL) { + Py_DECREF(posobj); + Py_DECREF(oldposobj); + return NULL; + } + } + Py_DECREF(pos2); + Py_DECREF(oldposobj); + } +#else + Py_BEGIN_ALLOW_THREADS + errno = 0; + ret = ftruncate(fd, pos); + Py_END_ALLOW_THREADS +#endif /* !MS_WINDOWS */ + + if (ret != 0) { + Py_DECREF(posobj); + PyErr_SetFromErrno(PyExc_IOError); + return NULL; + } + + return posobj; +} +#endif + +static char * +mode_string(PyFileIOObject *self) +{ + if (self->readable) { + if (self->writable) + return "r+"; + else + return "r"; + } + else + return "w"; +} + +static PyObject * +fileio_repr(PyFileIOObject *self) +{ + if (self->fd < 0) + return PyString_FromFormat("_fileio._FileIO(-1)"); + + return PyString_FromFormat("_fileio._FileIO(%d, '%s')", + self->fd, mode_string(self)); +} + +static PyObject * +fileio_isatty(PyFileIOObject *self) +{ + long res; + + if (self->fd < 0) + return err_closed(); + Py_BEGIN_ALLOW_THREADS + res = isatty(self->fd); + Py_END_ALLOW_THREADS + return PyBool_FromLong(res); +} + + +PyDoc_STRVAR(fileio_doc, +"file(name: str[, mode: str]) -> file IO object\n" +"\n" +"Open a file. The mode can be 'r', 'w' or 'a' for reading (default),\n" +"writing or appending. The file will be created if it doesn't exist\n" +"when opened for writing or appending; it will be truncated when\n" +"opened for writing. Add a '+' to the mode to allow simultaneous\n" +"reading and writing."); + +PyDoc_STRVAR(read_doc, +"read(size: int) -> bytes. read at most size bytes, returned as bytes.\n" +"\n" +"Only makes one system call, so less data may be returned than requested\n" +"In non-blocking mode, returns None if no data is available.\n" +"On end-of-file, returns ''."); + +PyDoc_STRVAR(readall_doc, +"readall() -> bytes. read all data from the file, returned as bytes.\n" +"\n" +"In non-blocking mode, returns as much as is immediately available,\n" +"or None if no data is available. On end-of-file, returns ''."); + +PyDoc_STRVAR(write_doc, +"write(b: bytes) -> int. Write bytes b to file, return number written.\n" +"\n" +"Only makes one system call, so not all of the data may be written.\n" +"The number of bytes actually written is returned."); + +PyDoc_STRVAR(fileno_doc, +"fileno() -> int. \"file descriptor\".\n" +"\n" +"This is needed for lower-level file interfaces, such the fcntl module."); + +PyDoc_STRVAR(seek_doc, +"seek(offset: int[, whence: int]) -> None. Move to new file position.\n" +"\n" +"Argument offset is a byte count. Optional argument whence defaults to\n" +"0 (offset from start of file, offset should be >= 0); other values are 1\n" +"(move relative to current position, positive or negative), and 2 (move\n" +"relative to end of file, usually negative, although many platforms allow\n" +"seeking beyond the end of a file)." +"\n" +"Note that not all file objects are seekable."); + +#ifdef HAVE_FTRUNCATE +PyDoc_STRVAR(truncate_doc, +"truncate([size: int]) -> None. Truncate the file to at most size bytes.\n" +"\n" +"Size defaults to the current file position, as returned by tell()."); +#endif + +PyDoc_STRVAR(tell_doc, +"tell() -> int. Current file position"); + +PyDoc_STRVAR(readinto_doc, +"readinto() -> Undocumented. Don't use this; it may go away."); + +PyDoc_STRVAR(close_doc, +"close() -> None. Close the file.\n" +"\n" +"A closed file cannot be used for further I/O operations. close() may be\n" +"called more than once without error. Changes the fileno to -1."); + +PyDoc_STRVAR(isatty_doc, +"isatty() -> bool. True if the file is connected to a tty device."); + +PyDoc_STRVAR(seekable_doc, +"seekable() -> bool. True if file supports random-access."); + +PyDoc_STRVAR(readable_doc, +"readable() -> bool. True if file was opened in a read mode."); + +PyDoc_STRVAR(writable_doc, +"writable() -> bool. True if file was opened in a write mode."); + +static PyMethodDef fileio_methods[] = { + {"read", (PyCFunction)fileio_read, METH_VARARGS, read_doc}, + {"readall", (PyCFunction)fileio_readall, METH_NOARGS, readall_doc}, + {"readinto", (PyCFunction)fileio_readinto, METH_VARARGS, readinto_doc}, + {"write", (PyCFunction)fileio_write, METH_VARARGS, write_doc}, + {"seek", (PyCFunction)fileio_seek, METH_VARARGS, seek_doc}, + {"tell", (PyCFunction)fileio_tell, METH_VARARGS, tell_doc}, +#ifdef HAVE_FTRUNCATE + {"truncate", (PyCFunction)fileio_truncate, METH_VARARGS, truncate_doc}, +#endif + {"close", (PyCFunction)fileio_close, METH_NOARGS, close_doc}, + {"seekable", (PyCFunction)fileio_seekable, METH_NOARGS, seekable_doc}, + {"readable", (PyCFunction)fileio_readable, METH_NOARGS, readable_doc}, + {"writable", (PyCFunction)fileio_writable, METH_NOARGS, writable_doc}, + {"fileno", (PyCFunction)fileio_fileno, METH_NOARGS, fileno_doc}, + {"isatty", (PyCFunction)fileio_isatty, METH_NOARGS, isatty_doc}, + {NULL, NULL} /* sentinel */ +}; + +/* 'closed' and 'mode' are attributes for backwards compatibility reasons. */ + +static PyObject * +get_closed(PyFileIOObject *self, void *closure) +{ + return PyBool_FromLong((long)(self->fd < 0)); +} + +static PyObject * +get_mode(PyFileIOObject *self, void *closure) +{ + return PyString_FromString(mode_string(self)); +} + +static PyGetSetDef fileio_getsetlist[] = { + {"closed", (getter)get_closed, NULL, "True if the file is closed"}, + {"mode", (getter)get_mode, NULL, "String giving the file mode"}, + {0}, +}; + +PyTypeObject PyFileIO_Type = { + PyVarObject_HEAD_INIT(&PyType_Type, 0) + "_FileIO", + sizeof(PyFileIOObject), + 0, + (destructor)fileio_dealloc, /* tp_dealloc */ + 0, /* tp_print */ + 0, /* tp_getattr */ + 0, /* tp_setattr */ + 0, /* tp_compare */ + (reprfunc)fileio_repr, /* tp_repr */ + 0, /* tp_as_number */ + 0, /* tp_as_sequence */ + 0, /* tp_as_mapping */ + 0, /* tp_hash */ + 0, /* tp_call */ + 0, /* tp_str */ + PyObject_GenericGetAttr, /* tp_getattro */ + 0, /* tp_setattro */ + 0, /* tp_as_buffer */ + Py_TPFLAGS_DEFAULT | Py_TPFLAGS_BASETYPE, /* tp_flags */ + fileio_doc, /* tp_doc */ + 0, /* tp_traverse */ + 0, /* tp_clear */ + 0, /* tp_richcompare */ + offsetof(PyFileIOObject, weakreflist), /* tp_weaklistoffset */ + 0, /* tp_iter */ + 0, /* tp_iternext */ + fileio_methods, /* tp_methods */ + 0, /* tp_members */ + fileio_getsetlist, /* tp_getset */ + 0, /* tp_base */ + 0, /* tp_dict */ + 0, /* tp_descr_get */ + 0, /* tp_descr_set */ + 0, /* tp_dictoffset */ + fileio_init, /* tp_init */ + PyType_GenericAlloc, /* tp_alloc */ + fileio_new, /* tp_new */ + PyObject_Del, /* tp_free */ +}; + +static PyMethodDef module_methods[] = { + {NULL, NULL} +}; + +PyMODINIT_FUNC +init_fileio(void) +{ + PyObject *m; /* a module object */ + + m = Py_InitModule3("_fileio", module_methods, + "Fast implementation of io.FileIO."); + if (m == NULL) + return; + if (PyType_Ready(&PyFileIO_Type) < 0) + return; + Py_INCREF(&PyFileIO_Type); + PyModule_AddObject(m, "_FileIO", (PyObject *) &PyFileIO_Type); +} From python-checkins at python.org Mon Jan 28 15:40:48 2008 From: python-checkins at python.org (christian.heimes) Date: Mon, 28 Jan 2008 15:40:48 +0100 (CET) Subject: [Python-checkins] r60392 - in python/branches/trunk-math: Doc/library/stdtypes.rst Lib/test/test_complex.py Objects/complexobject.c Message-ID: <20080128144048.994D41E401A@bag.python.org> Author: christian.heimes Date: Mon Jan 28 15:40:48 2008 New Revision: 60392 Modified: python/branches/trunk-math/Doc/library/stdtypes.rst python/branches/trunk-math/Lib/test/test_complex.py python/branches/trunk-math/Objects/complexobject.c Log: Added from_cis and as_cis to the complex type. The functions creates / return the cis form of a complex (aka polar form or exp form) which is often used in engineering. Modified: python/branches/trunk-math/Doc/library/stdtypes.rst ============================================================================== --- python/branches/trunk-math/Doc/library/stdtypes.rst (original) +++ python/branches/trunk-math/Doc/library/stdtypes.rst Mon Jan 28 15:40:48 2008 @@ -302,7 +302,7 @@ +--------------------+---------------------------------+--------+ | ``float(x)`` | *x* converted to floating point | \(6) | +--------------------+---------------------------------+--------+ -| ``complex(re,im)`` | a complex number with real part | | +| ``complex(re,im)`` | a complex number with real part | \(8) | | | *re*, imaginary part *im*. | | | | *im* defaults to zero. | | +--------------------+---------------------------------+--------+ @@ -370,6 +370,13 @@ Python defines ``pow(0, 0)`` and ``0 ** 0`` to be ``1``, as is common for programming languages. +(8) + The complex type has also the constructor ``from_cis(r, phi)`` to create a + complex from the polar form ``r * (cos(phi) + j * sin(pih))`` or + expotentional form ``r * exp(j * phi)``. The method ``as_cis()`` returns the + radius *r* and angle *phi* of a complex number. + + All :class:`numbers.Real` types (:class:`int`, :class:`long`, and :class:`float`) also include the following operations: Modified: python/branches/trunk-math/Lib/test/test_complex.py ============================================================================== --- python/branches/trunk-math/Lib/test/test_complex.py (original) +++ python/branches/trunk-math/Lib/test/test_complex.py Mon Jan 28 15:40:48 2008 @@ -9,7 +9,7 @@ ) from random import random -from math import atan2 +from math import atan2, pi # These tests ensure that complex math does the right thing @@ -359,6 +359,30 @@ except (OSError, IOError): pass + def assertCISEqual(self, a, b): + eps = 1E-7 + if abs(a[0] - b[0]) > eps or abs(a[1] - b[1]) > eps: + self.fail((a ,b)) + + def test_as_cis(self): + self.assertCISEqual(complex().as_cis(), (0., 0.)) + self.assertCISEqual(complex(1.).as_cis(), (1., 0.)) + self.assertCISEqual(complex(-1.).as_cis(), (1., pi)) + self.assertCISEqual(complex(0., 1).as_cis(), (1., pi/2)) + self.assertCISEqual(complex(0., -1).as_cis(), (1., -pi/2)) + + def assertCEqual(self, a, b): + eps = 1E-7 + if abs(a.real - b[0]) > eps or abs(a.imag - b[1]) > eps: + self.fail((a ,b)) + + def test_from_cis(self): + self.assertCEqual(complex.from_cis(0, 0), (0, 0)) + self.assertCEqual(complex.from_cis(1, 0), (1., 0)) + self.assertCEqual(complex.from_cis(1, -pi), (-1., 0)) + self.assertCEqual(complex.from_cis(1, pi/2), (0, 1.)) + self.assertCEqual(complex.from_cis(1, -pi/2), (0, -1.)) + def test_main(): test_support.run_unittest(ComplexTest) Modified: python/branches/trunk-math/Objects/complexobject.c ============================================================================== --- python/branches/trunk-math/Objects/complexobject.c (original) +++ python/branches/trunk-math/Objects/complexobject.c Mon Jan 28 15:40:48 2008 @@ -183,6 +183,31 @@ } +static Py_complex +c_from_cis(float r, float phi) +{ + Py_complex cn; + + if (r <= 0.) { + if (r != 0.) { + errno = EDOM; + } + cn.real = cn.imag = 0.; + return cn; + } + + cn.real = r * cos(phi); + cn.imag = r * sin(phi); + return cn; +} + +static void +c_as_cis(Py_complex cn, float *r, float *phi) +{ + *r = hypot(cn.real, cn.imag); + *phi = atan2(cn.imag, cn.real); +} + static PyObject * complex_subtype_from_c_complex(PyTypeObject *type, Py_complex cval) { @@ -748,9 +773,62 @@ return Py_BuildValue("(D)", &v->cval); } +static PyObject * +complex_from_cis(PyObject *ignored, PyObject *args) +{ + Py_complex c; + float r, phi; + + if (!PyArg_ParseTuple(args, "ff:fromcis", &r, &phi)) + return NULL; + + PyFPE_START_PROTECT("complex_from_cis", return NULL) + errno = 0; + c = c_from_cis(r, phi); + PyFPE_END_PROTECT(r) + Py_ADJUST_ERANGE2(c.real, c.imag); + if (errno == EDOM) { + PyErr_SetString(PyExc_ValueError, + "r must not be negative"); + return NULL; + } + return PyComplex_FromCComplex(c); +} + +PyDoc_STRVAR(complex_from_cis_doc, +"complex.from_cis(r, phi) -> complex\n" +"\n" +"Creates a complex number from the polar form r * (cos(phi) + j * sin(phi))" +"or exponential form r * exp(j * phi)"); + +static PyObject * +complex_as_cis(PyObject *self) +{ + Py_complex c; + float r, phi; + + c = ((PyComplexObject *)self)->cval; + PyFPE_START_PROTECT("complex_as_cis", return NULL) + errno = 0; + c_as_cis(c, &r, &phi); + PyFPE_END_PROTECT(r) + return Py_BuildValue("ff", r, phi); +} + +PyDoc_STRVAR(complex_as_cis_doc, +"complex.as_cis() -> r, phi\n" +"\n" +"Converts a complex number to the polar form r * (cos(phi) + j * sin(phi))" +"or exponential form r * exp(j * phi)"); + + static PyMethodDef complex_methods[] = { + {"as_cis", (PyCFunction)complex_as_cis, METH_NOARGS, + complex_as_cis_doc}, {"conjugate", (PyCFunction)complex_conjugate, METH_NOARGS, complex_conjugate_doc}, + {"from_cis", (PyCFunction)complex_from_cis, + METH_VARARGS | METH_STATIC, complex_from_cis_doc}, {"__getnewargs__", (PyCFunction)complex_getnewargs, METH_NOARGS}, {NULL, NULL} /* sentinel */ }; From theller at ctypes.org Mon Jan 28 16:10:12 2008 From: theller at ctypes.org (Thomas Heller) Date: Mon, 28 Jan 2008 16:10:12 +0100 Subject: [Python-checkins] r60391 - python/branches/trunk-math/Modules/_fileio.c In-Reply-To: <20080128143939.910581E400D@bag.python.org> References: <20080128143939.910581E400D@bag.python.org> Message-ID: christian.heimes schrieb: > Author: christian.heimes > Date: Mon Jan 28 15:39:39 2008 > New Revision: 60391 > > Added: > python/branches/trunk-math/Modules/_fileio.c (contents, props changed) > Log: > Added lost file. Memo to me: svnmerge doesn't add new files to the commit list. > IIRC, it *does* add new files. But only if they are not already present in the filesystem. So, if you do an svnmerge, then 'svn revert', and then do svnmerge again, it will not be added to the commit list because 'svn revert' doesn't remove the file. Thomas From python-checkins at python.org Mon Jan 28 17:05:57 2008 From: python-checkins at python.org (christian.heimes) Date: Mon, 28 Jan 2008 17:05:57 +0100 (CET) Subject: [Python-checkins] r60393 - in python/branches/trunk-math: Doc/library/math.rst Doc/library/stdtypes.rst Misc/NEWS Message-ID: <20080128160557.14FA61E400C@bag.python.org> Author: christian.heimes Date: Mon Jan 28 17:05:56 2008 New Revision: 60393 Modified: python/branches/trunk-math/Doc/library/math.rst python/branches/trunk-math/Doc/library/stdtypes.rst python/branches/trunk-math/Misc/NEWS Log: Doc fixes Modified: python/branches/trunk-math/Doc/library/math.rst ============================================================================== --- python/branches/trunk-math/Doc/library/math.rst (original) +++ python/branches/trunk-math/Doc/library/math.rst Mon Jan 28 17:05:56 2008 @@ -151,7 +151,7 @@ returns *0.* for all positive *y*, *0* and *NAN*. .. versionchanged:: 2.6 - The outcome of ``1**nan`` and ``0**nan`` was undefined. + The outcome of ``1**nan`` and ``0**nan`` was undefined. .. function:: sqrt(x) Modified: python/branches/trunk-math/Doc/library/stdtypes.rst ============================================================================== --- python/branches/trunk-math/Doc/library/stdtypes.rst (original) +++ python/branches/trunk-math/Doc/library/stdtypes.rst Mon Jan 28 17:05:56 2008 @@ -376,6 +376,8 @@ expotentional form ``r * exp(j * phi)``. The method ``as_cis()`` returns the radius *r* and angle *phi* of a complex number. + .. versionadded:: 2.6 + All :class:`numbers.Real` types (:class:`int`, :class:`long`, and :class:`float`) also include the following operations: Modified: python/branches/trunk-math/Misc/NEWS ============================================================================== --- python/branches/trunk-math/Misc/NEWS (original) +++ python/branches/trunk-math/Misc/NEWS Mon Jan 28 17:05:56 2008 @@ -12,6 +12,15 @@ Core and builtins ----------------- +- Added ``from_cis`` constructor to the ``complex`` type to create a complex + from a polar or exp notation. The new method ``as_cis`` returns radius *r* + and angle *phi* of a complex. + +- Issue #XXXX: Four new methods were added to the math and cmath modules: + acosh, asinh, atanh and log1p. Replacement implementations for platforms + without the four functions and copysign in libm were added to a new file + Python/pymath.c. + - Patch #1473257: generator objects gain a gi_code attribute. This is the same object as the func_code attribute of the function that produced the generator. @@ -36,11 +45,6 @@ - Issue #1882: when compiling code from a string, encoding cookies in the second line of code were not always recognized correctly. -- Issue #XXXX: Four new methods were added to the math and cmath modules: - acosh, asinh, atanh and log1p. Replacement implementations for platforms - without the four functions and copysign in libm were added to a new file - Python/pymath.c. - - Issue #1679: "0x" was taken as a valid integer literal. - Issue #1865: ``bytes`` as an alias for ``str`` and b"" as an alias "" were From buildbot at python.org Mon Jan 28 19:25:20 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 28 Jan 2008 18:25:20 +0000 Subject: [Python-checkins] buildbot failure in ARM Linux trunk Message-ID: <20080128182521.399491E401C@bag.python.org> The Buildbot has detected a new failure of ARM Linux trunk. Full details are available at: http://www.python.org/dev/buildbot/all/ARM%20Linux%20trunk/builds/6 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-linux-arm Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: thomas.heller BUILD FAILED: failed test Excerpt from the test logfile: make: *** [buildbottest] Segmentation fault sincerely, -The Buildbot From python-checkins at python.org Mon Jan 28 19:58:32 2008 From: python-checkins at python.org (guido.van.rossum) Date: Mon, 28 Jan 2008 19:58:32 +0100 (CET) Subject: [Python-checkins] r60395 - peps/trunk/pep-3000.txt Message-ID: <20080128185832.3B9A01E400C@bag.python.org> Author: guido.van.rossum Date: Mon Jan 28 19:58:31 2008 New Revision: 60395 Modified: peps/trunk/pep-3000.txt Log: Fix typo in release schedule (early 2007 should be early 2008). Modified: peps/trunk/pep-3000.txt ============================================================================== --- peps/trunk/pep-3000.txt (original) +++ peps/trunk/pep-3000.txt Mon Jan 28 19:58:31 2008 @@ -56,7 +56,7 @@ * August 2007: release 3.0a1. * December 2007: release 3.0a2. -* Early 2007 (pre-PyCon): release 2.6a1. +* Early 2008 (pre-PyCon): release 2.6a1. * May 2008 (post-PyCon): full feature freeze for 3.0 and 2.6. * July 2008: release 2.6 (final). * August 2008: release 3.0 (final). From buildbot at python.org Mon Jan 28 20:10:26 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 28 Jan 2008 19:10:26 +0000 Subject: [Python-checkins] buildbot failure in amd64 gentoo 3.0 Message-ID: <20080128191027.5D4E61E401F@bag.python.org> The Buildbot has detected a new failure of amd64 gentoo 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/amd64%20gentoo%203.0/builds/20 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-amd64 Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_bsddb3 ====================================================================== ERROR: test_cachesize (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/3.0.norwitz-amd64/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined ====================================================================== ERROR: test_flags (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/3.0.norwitz-amd64/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined ====================================================================== ERROR: test_get (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/3.0.norwitz-amd64/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined ====================================================================== ERROR: test_get_dbp (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/3.0.norwitz-amd64/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined ====================================================================== ERROR: test_get_key (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/3.0.norwitz-amd64/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined ====================================================================== ERROR: test_range (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/3.0.norwitz-amd64/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined ====================================================================== ERROR: test_remove (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/3.0.norwitz-amd64/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined ====================================================================== ERROR: test_stat (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/buildbot/slave/py-build/3.0.norwitz-amd64/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Mon Jan 28 20:17:49 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 28 Jan 2008 19:17:49 +0000 Subject: [Python-checkins] buildbot failure in ppc Debian unstable 3.0 Message-ID: <20080128191749.64C5C1E400C@bag.python.org> The Buildbot has detected a new failure of ppc Debian unstable 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/ppc%20Debian%20unstable%203.0/builds/502 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_bsddb3 ====================================================================== ERROR: test_cachesize (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined ====================================================================== ERROR: test_flags (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined ====================================================================== ERROR: test_get (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined ====================================================================== ERROR: test_get_dbp (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined ====================================================================== ERROR: test_get_key (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined ====================================================================== ERROR: test_range (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined ====================================================================== ERROR: test_remove (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined ====================================================================== ERROR: test_stat (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ppc/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Mon Jan 28 20:38:19 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 28 Jan 2008 19:38:19 +0000 Subject: [Python-checkins] buildbot failure in ia64 Ubuntu 3.0 Message-ID: <20080128193819.95E4A1E400C@bag.python.org> The Buildbot has detected a new failure of ia64 Ubuntu 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/ia64%20Ubuntu%203.0/builds/483 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ia64 Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_bsddb3 ====================================================================== ERROR: test_cachesize (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ia64/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined ====================================================================== ERROR: test_flags (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ia64/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined ====================================================================== ERROR: test_get (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ia64/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined ====================================================================== ERROR: test_get_dbp (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ia64/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined ====================================================================== ERROR: test_get_key (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ia64/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined ====================================================================== ERROR: test_range (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ia64/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined ====================================================================== ERROR: test_remove (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ia64/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined ====================================================================== ERROR: test_stat (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-ia64/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Mon Jan 28 20:39:10 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 28 Jan 2008 19:39:10 +0000 Subject: [Python-checkins] buildbot failure in g4 osx.4 3.0 Message-ID: <20080128193910.5D0B41E400C@bag.python.org> The Buildbot has detected a new failure of g4 osx.4 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/g4%20osx.4%203.0/builds/479 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: psf-g4 Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_bsddb3 ====================================================================== ERROR: test_cachesize (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined ====================================================================== ERROR: test_flags (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined ====================================================================== ERROR: test_get (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined ====================================================================== ERROR: test_get_dbp (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined ====================================================================== ERROR: test_get_key (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined ====================================================================== ERROR: test_range (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined ====================================================================== ERROR: test_remove (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): ====================================================================== ERROR: test_stat (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/buildslave/bb/3.0.psf-g4/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Mon Jan 28 20:50:54 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 28 Jan 2008 19:50:54 +0000 Subject: [Python-checkins] buildbot failure in S-390 Debian 3.0 Message-ID: <20080128195054.983761E400C@bag.python.org> The Buildbot has detected a new failure of S-390 Debian 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/S-390%20Debian%203.0/builds/10 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-s390 Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_bsddb3 ====================================================================== ERROR: test_cachesize (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-s390/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined ====================================================================== ERROR: test_flags (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-s390/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined ====================================================================== ERROR: test_get (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-s390/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined ====================================================================== ERROR: test_get_dbp (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-s390/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined ====================================================================== ERROR: test_get_key (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-s390/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined ====================================================================== ERROR: test_range (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-s390/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined ====================================================================== ERROR: test_remove (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-s390/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined ====================================================================== ERROR: test_stat (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-debian-s390/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Mon Jan 28 21:03:50 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 28 Jan 2008 20:03:50 +0000 Subject: [Python-checkins] buildbot failure in hppa Ubuntu 3.0 Message-ID: <20080128200350.A858F1E400D@bag.python.org> The Buildbot has detected a new failure of hppa Ubuntu 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/hppa%20Ubuntu%203.0/builds/466 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-ubuntu-hppa Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_bsddb3 ====================================================================== ERROR: test_cachesize (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined ====================================================================== ERROR: test_flags (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined ====================================================================== ERROR: test_get (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined ====================================================================== ERROR: test_get_dbp (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined ====================================================================== ERROR: test_get_key (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined ====================================================================== ERROR: test_range (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined ====================================================================== ERROR: test_remove (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined ====================================================================== ERROR: test_stat (bsddb.test.test_sequence.DBSequenceTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/bsddb/test/test_sequence.py", line 27, in setUp tempfile.tempdir = old_tempfile_tempdir NameError: global name 'old_tempfile_tempdir' is not defined make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Mon Jan 28 21:34:34 2008 From: python-checkins at python.org (raymond.hettinger) Date: Mon, 28 Jan 2008 21:34:34 +0100 (CET) Subject: [Python-checkins] r60397 - in python/trunk: Doc/c-api/set.rst Objects/setobject.c Message-ID: <20080128203434.42BED1E400D@bag.python.org> Author: raymond.hettinger Date: Mon Jan 28 21:34:33 2008 New Revision: 60397 Modified: python/trunk/Doc/c-api/set.rst python/trunk/Objects/setobject.c Log: Make PySet_Add() work with frozensets. Works like PyTuple_SetItem() to build-up values in a brand new frozenset. Also, PyFrozenSet_New() is now guaranteed to produce a distinct new frozenset. Modified: python/trunk/Doc/c-api/set.rst ============================================================================== --- python/trunk/Doc/c-api/set.rst (original) +++ python/trunk/Doc/c-api/set.rst Mon Jan 28 21:34:33 2008 @@ -86,6 +86,11 @@ set on success or *NULL* on failure. Raise :exc:`TypeError` if *iterable* is not actually iterable. + .. versionchanged:: 2.6 + Now guaranteed to return a brand-new :class:`frozenset`. Formerly, + frozensets of zero-length were a singleton. This got in the way of + building-up new frozensets with :meth:`PySet_Add`. + The following functions and macros are available for instances of :class:`set` or :class:`frozenset` or instances of their subtypes. @@ -112,9 +117,6 @@ the *key* is unhashable. Raise :exc:`PyExc_SystemError` if *anyset* is not a :class:`set`, :class:`frozenset`, or an instance of a subtype. -The following functions are available for instances of :class:`set` or its -subtypes but not for instances of :class:`frozenset` or its subtypes. - .. cfunction:: int PySet_Add(PyObject *set, PyObject *key) @@ -124,6 +126,14 @@ Raise a :exc:`SystemError` if *set* is an not an instance of :class:`set` or its subtype. + .. versionchanged:: 2.6 + Now works with instances of :class:`frozenset` or its subtypes. + Like :cfunc:`PyTuple_SetItem` in that it can be used to fill-in the + values of brand new frozensets before they are exposed to other code. + +The following functions are available for instances of :class:`set` or its +subtypes but not for instances of :class:`frozenset` or its subtypes. + .. cfunction:: int PySet_Discard(PyObject *set, PyObject *key) Modified: python/trunk/Objects/setobject.c ============================================================================== --- python/trunk/Objects/setobject.c (original) +++ python/trunk/Objects/setobject.c Mon Jan 28 21:34:33 2008 @@ -2142,17 +2142,7 @@ PyObject * PyFrozenSet_New(PyObject *iterable) { - PyObject *args, *result; - - if (iterable == NULL) - args = PyTuple_New(0); - else - args = PyTuple_Pack(1, iterable); - if (args == NULL) - return NULL; - result = frozenset_new(&PyFrozenSet_Type, args, NULL); - Py_DECREF(args); - return result; + return make_new_set(&PyFrozenSet_Type, iterable); } Py_ssize_t @@ -2196,13 +2186,13 @@ } int -PySet_Add(PyObject *set, PyObject *key) +PySet_Add(PyObject *anyset, PyObject *key) { - if (!PyType_IsSubtype(Py_TYPE(set), &PySet_Type)) { + if (!PyAnySet_Check(anyset)) { PyErr_BadInternalCall(); return -1; } - return set_add_key((PySetObject *)set, key); + return set_add_key((PySetObject *)anyset, key); } int @@ -2345,7 +2335,6 @@ f = PyFrozenSet_New(dup); assert(PySet_Size(f) == 3); assert(PyFrozenSet_CheckExact(f)); - assertRaises(PySet_Add(f, elem) == -1, PyExc_SystemError); assertRaises(PySet_Discard(f, elem) == -1, PyExc_SystemError); assertRaises(PySet_Pop(f) == NULL, PyExc_SystemError); Py_DECREF(f); From nnorwitz at gmail.com Mon Jan 28 22:12:05 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Mon, 28 Jan 2008 16:12:05 -0500 Subject: [Python-checkins] Python Regression Test Failures basics (1) Message-ID: <20080128211205.GA8670@python.psfb.org> test_grammar test_opcodes test_dict test_builtin test_exceptions test_types test_unittest test_doctest test_doctest2 test_MimeWriter test_StringIO test___all__ test___future__ test__locale test_abc test_abstract_numbers test_aepack test_aepack skipped -- No module named aepack test_al test_al skipped -- No module named al test_anydbm test_applesingle test_applesingle skipped -- No module named macostools test_array test_ast test_asynchat WARNING: failed to listen on port 54322, trying another WARNING: failed to listen on port 9907, trying another WARNING: failed to listen on port 10243, trying another WARNING: failed to listen on port 32999, trying another test_asyncore test_atexit test_audioop test_augassign test_base64 test_bastion test_bigaddrspace test_bigmem test_binascii test_binhex test_binop test_bisect test_bool test_bsddb test_bsddb185 test_bsddb185 skipped -- No module named bsddb185 test_bsddb3 test_bsddb3 skipped -- Use of the `bsddb' resource not enabled test_buffer test_bufio test_bz2 test_cProfile test_calendar test_call test_capi test_cd test_cd skipped -- No module named cd test_cfgparser test_cgi test_charmapcodec test_cl test_cl skipped -- No module named cl test_class test_cmath test_cmd test_cmd_line test_cmd_line_script test_code test_codeccallbacks test_codecencodings_cn test_codecencodings_hk test_codecencodings_jp test_codecencodings_kr test_codecencodings_tw test_codecmaps_cn test_codecmaps_cn skipped -- Use of the `urlfetch' resource not enabled test_codecmaps_hk test_codecmaps_hk skipped -- Use of the `urlfetch' resource not enabled test_codecmaps_jp test_codecmaps_jp skipped -- Use of the `urlfetch' resource not enabled test_codecmaps_kr test_codecmaps_kr skipped -- Use of the `urlfetch' resource not enabled test_codecmaps_tw test_codecmaps_tw skipped -- Use of the `urlfetch' resource not enabled test_codecs test_codeop test_coding test_coercion test_collections test_colorsys test_commands test_compare test_compile test_compiler test_complex test_complex_args test_contains test_contextlib test_cookie test_cookielib test_copy test_copy_reg test_cpickle test_crypt test_csv test_ctypes test_curses test_curses skipped -- Use of the `curses' resource not enabled test_datetime test_dbm test_decimal test_decorators test_defaultdict test_deque test_descr test_descrtut test_difflib test_dircache test_dis test_distutils test_dl test_docxmlrpc test_dumbdbm test_dummy_thread test_dummy_threading test_email test_email_codecs test_email_renamed test_enumerate test_eof test_errno test_exception_variations test_extcall test_fcntl test_file test_filecmp test_fileinput test_float test_fnmatch test_fork1 test_format test_fpformat test_frozen test_ftplib test_funcattrs test_functools test_future test_gc test_gdbm test_generators test_genericpath test_genexps test_getargs test_getargs2 test_getopt test_gettext test_gl test_gl skipped -- No module named gl test_glob test_global test_grp test_gzip test_hash test_hashlib test_heapq test_hexoct test_hmac test_hotshot test_htmllib test_htmlparser test_httplib test_imageop test_imageop skipped -- No module named imgfile test_imaplib test_imgfile test_imgfile skipped -- No module named imgfile test_imp test_import test_importhooks test_index test_inspect test_ioctl test_ioctl skipped -- Unable to open /dev/tty test_isinstance test_iter test_iterlen test_itertools test_largefile test_linuxaudiodev test_linuxaudiodev skipped -- Use of the `audio' resource not enabled test_list test_locale test_logging test_long test_long_future test_longexp test_macostools test_macostools skipped -- No module named macostools test_macpath test_mailbox test_marshal test_math test_md5 test_mhlib test_mimetools test_mimetypes test_minidom test_mmap test_module test_modulefinder test_multibytecodec test_multibytecodec_support test_multifile test_mutants test_netrc test_new test_nis test_normalization test_normalization skipped -- Use of the `urlfetch' resource not enabled test_ntpath test_old_mailbox test_openpty test_operator test_optparse test_os test_ossaudiodev test_ossaudiodev skipped -- Use of the `audio' resource not enabled test_parser test_peepholer test_pep247 test_pep263 test_pep277 test_pep277 skipped -- test works only on NT+ test_pep292 test_pep352 test_pickle test_pickletools test_pipes test_pkg test_pkgimport test_platform test_plistlib test_poll test_popen [7792 refs] [7792 refs] [7792 refs] test_popen2 test_poplib test test_poplib failed -- Traceback (most recent call last): File "/tmp/python-test/local/lib/python2.6/test/test_poplib.py", line 39, in testBasic pop = poplib.POP3("localhost", 9091) File "/tmp/python-test/local/lib/python2.6/poplib.py", line 82, in __init__ self.sock = socket.create_connection((host, port), timeout) File "/tmp/python-test/local/lib/python2.6/socket.py", line 465, in create_connection raise error, msg error: [Errno 111] Connection refused test_posix test_posixpath test_pow test_pprint test_profile test_profilehooks test_property test_pstats test_pty test_pwd test_pyclbr test_pyexpat test_queue test_quopri [8169 refs] [8169 refs] test_random test_rational test_re test_repr test_resource test_rfc822 test_richcmp test_robotparser test_runpy test_sax test_scope test_scriptpackages test_scriptpackages skipped -- No module named aetools test_select test_set test_sets test_sgmllib test_sha test_shelve test_shlex test_shutil test_signal test_site test_slice test_smtplib test_socket WARNING: failed to listen on port 50007, trying another WARNING: failed to listen on port 9907, trying another WARNING: failed to listen on port 10243, trying another WARNING: failed to listen on port 32999, trying another test_socket_ssl /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:108: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ssl_sock = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:157: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) /tmp/python-test/local/lib/python2.6/test/test_socket_ssl.py:171: DeprecationWarning: socket.ssl() is deprecated. Use ssl.wrap_socket() instead. ss = socket.ssl(s) test_socketserver test_socketserver skipped -- Use of the `network' resource not enabled test_softspace test_sort test_sqlite test_ssl test_startfile test_startfile skipped -- cannot import name startfile test_str test_strftime test_string test_stringprep test_strop test_strptime test_struct test_structmembers test_structseq test_subprocess [7787 refs] [7788 refs] [7787 refs] [7787 refs] [7787 refs] [7787 refs] [7787 refs] [7787 refs] [7787 refs] [7787 refs] [7788 refs] [9407 refs] [8005 refs] [7788 refs] [7787 refs] [7787 refs] [7787 refs] [7787 refs] [7787 refs] . [7787 refs] [7787 refs] this bit of output is from a test of stdout in a different process ... [7787 refs] [7787 refs] [8005 refs] test_sunaudiodev test_sunaudiodev skipped -- No module named sunaudiodev test_sundry test_symtable test_syntax test_sys [7787 refs] [7787 refs] test_tarfile test_tcl test_tcl skipped -- No module named _tkinter test_telnetlib test_tempfile [7791 refs] test_textwrap test_thread test_threaded_import test_threadedtempfile test_threading [10915 refs] test_threading_local test_threadsignals test_time test_timeout test_timeout skipped -- Use of the `network' resource not enabled test_tokenize test_trace test_traceback test_transformer test_tuple test_typechecks test_ucn test_unary test_unicode test_unicode_file test_unicode_file skipped -- No Unicode filesystem semantics on this platform. test_unicodedata test_univnewlines test_unpack test_urllib test_urllib2 test_urllib2_localnet test_urllib2net test_urllib2net skipped -- Use of the `network' resource not enabled test_urllibnet test_urllibnet skipped -- Use of the `network' resource not enabled test_urlparse test_userdict test_userlist test_userstring test_uu test_uuid WARNING: uuid.getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._ifconfig_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. WARNING: uuid._unixdll_getnode is unreliable on many platforms. It is disabled until the code and/or test can be fixed properly. test_wait3 test_wait4 test_warnings test_wave test_weakref test_whichdb test_winreg test_winreg skipped -- No module named _winreg test_winsound test_winsound skipped -- No module named winsound test_with test_wsgiref test_xdrlib test_xml_etree test_xml_etree_c test_xmllib test_xmlrpc test_xpickle test_xrange test_zipfile /tmp/python-test/local/lib/python2.6/test/test_zipfile.py:472: DeprecationWarning: struct integer overflow masking is deprecated zipfp.close() /tmp/python-test/local/lib/python2.6/test/test_zipfile.py:399: DeprecationWarning: struct integer overflow masking is deprecated zipfp.close() test_zipfile64 test_zipfile64 skipped -- test requires loads of disk-space bytes and a long time to run test_zipimport test_zlib 304 tests OK. 1 test failed: test_poplib 34 tests skipped: test_aepack test_al test_applesingle test_bsddb185 test_bsddb3 test_cd test_cl test_codecmaps_cn test_codecmaps_hk test_codecmaps_jp test_codecmaps_kr test_codecmaps_tw test_curses test_gl test_imageop test_imgfile test_ioctl test_linuxaudiodev test_macostools test_normalization test_ossaudiodev test_pep277 test_scriptpackages test_socketserver test_startfile test_sunaudiodev test_tcl test_timeout test_unicode_file test_urllib2net test_urllibnet test_winreg test_winsound test_zipfile64 1 skip unexpected on linux2: test_ioctl [531955 refs] From buildbot at python.org Mon Jan 28 22:07:02 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 28 Jan 2008 21:07:02 +0000 Subject: [Python-checkins] buildbot failure in x86 XP-4 3.0 Message-ID: <20080128210704.31D451E400D@bag.python.org> The Buildbot has detected a new failure of x86 XP-4 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20XP-4%203.0/builds/460 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-windows Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: 7 tests failed: test_anydbm test_asynchat test_bsddb test_bsddb3 test_mailbox test_shelve test_whichdb ====================================================================== ERROR: test_anydbm_access (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 90, in test_anydbm_access self.init_db() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 103, in init_db f = anydbm.open(_fname, 'n') File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_anydbm_creation (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 63, in test_anydbm_creation f = anydbm.open(_fname, 'c') File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_anydbm_keys (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 84, in test_anydbm_keys self.init_db() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 103, in init_db f = anydbm.open(_fname, 'n') File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_anydbm_modification (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 71, in test_anydbm_modification self.init_db() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 103, in init_db f = anydbm.open(_fname, 'n') File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_anydbm_read (test.test_anydbm.AnyDBMTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 78, in test_anydbm_read self.init_db() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_anydbm.py", line 103, in init_db f = anydbm.open(_fname, 'n') File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_when_done (test.test_asynchat.TestAsynchat) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_asynchat.py", line 210, in test_close_when_done asyncore.loop(use_poll=self.usepoll, count=300, timeout=.01) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 195, in loop poll_fun(timeout, map) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 132, in poll read(obj) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 72, in read obj.handle_error() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 68, in read obj.handle_read_event() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 390, in handle_read_event self.handle_read() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_ssl.py", line 517, in handle_read data = self.recv(1024) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 342, in recv data = self.socket.recv(buffer_size) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\ssl.py", line 247, in recv return self.read(buflen) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\ssl.py", line 162, in read v = self._sslobj.read(len or 1024) socket.error: [Errno 10053] An established connection was aborted by the software in your host machine ====================================================================== ERROR: test_empty_line (test.test_asynchat.TestAsynchat) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_asynchat.py", line 198, in test_empty_line asyncore.loop(use_poll=self.usepoll, count=300, timeout=.01) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 195, in loop poll_fun(timeout, map) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 132, in poll read(obj) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 72, in read obj.handle_error() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 68, in read obj.handle_read_event() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 390, in handle_read_event self.handle_read() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_ssl.py", line 517, in handle_read data = self.recv(1024) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 342, in recv data = self.socket.recv(buffer_size) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\ssl.py", line 247, in recv return self.read(buflen) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\ssl.py", line 162, in read v = self._sslobj.read(len or 1024) socket.error: [Errno 10053] An established connection was aborted by the software in your host machine ====================================================================== ERROR: test_line_terminator1 (test.test_asynchat.TestAsynchat) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_asynchat.py", line 126, in test_line_terminator1 self.line_terminator_check('\n', l) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_asynchat.py", line 114, in line_terminator_check asyncore.loop(use_poll=self.usepoll, count=300, timeout=.01) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 195, in loop poll_fun(timeout, map) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 132, in poll read(obj) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 72, in read obj.handle_error() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 68, in read obj.handle_read_event() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 390, in handle_read_event self.handle_read() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_ssl.py", line 517, in handle_read data = self.recv(1024) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 342, in recv data = self.socket.recv(buffer_size) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\ssl.py", line 247, in recv return self.read(buflen) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\ssl.py", line 162, in read v = self._sslobj.read(len or 1024) socket.error: [Errno 10053] An established connection was aborted by the software in your host machine ====================================================================== ERROR: test_line_terminator2 (test.test_asynchat.TestAsynchat) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_asynchat.py", line 131, in test_line_terminator2 self.line_terminator_check('\r\n', l) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_asynchat.py", line 114, in line_terminator_check asyncore.loop(use_poll=self.usepoll, count=300, timeout=.01) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 195, in loop poll_fun(timeout, map) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 132, in poll read(obj) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 72, in read obj.handle_error() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 68, in read obj.handle_read_event() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 390, in handle_read_event self.handle_read() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_ssl.py", line 517, in handle_read data = self.recv(1024) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 342, in recv data = self.socket.recv(buffer_size) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\ssl.py", line 247, in recv return self.read(buflen) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\ssl.py", line 162, in read v = self._sslobj.read(len or 1024) socket.error: [Errno 10053] An established connection was aborted by the software in your host machine ====================================================================== ERROR: test_line_terminator3 (test.test_asynchat.TestAsynchat) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_asynchat.py", line 136, in test_line_terminator3 self.line_terminator_check('qqq', l) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_asynchat.py", line 114, in line_terminator_check asyncore.loop(use_poll=self.usepoll, count=300, timeout=.01) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 195, in loop poll_fun(timeout, map) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 132, in poll read(obj) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 72, in read obj.handle_error() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 68, in read obj.handle_read_event() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 390, in handle_read_event self.handle_read() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_ssl.py", line 517, in handle_read data = self.recv(1024) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 342, in recv data = self.socket.recv(buffer_size) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\ssl.py", line 247, in recv return self.read(buflen) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\ssl.py", line 162, in read v = self._sslobj.read(len or 1024) socket.error: [Errno 10053] An established connection was aborted by the software in your host machine ====================================================================== ERROR: test_none_terminator (test.test_asynchat.TestAsynchat) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_asynchat.py", line 165, in test_none_terminator asyncore.loop(use_poll=self.usepoll, count=300, timeout=.01) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 195, in loop poll_fun(timeout, map) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 132, in poll read(obj) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 72, in read obj.handle_error() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 68, in read obj.handle_read_event() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 390, in handle_read_event self.handle_read() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_ssl.py", line 517, in handle_read data = self.recv(1024) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 342, in recv data = self.socket.recv(buffer_size) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\ssl.py", line 247, in recv return self.read(buflen) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\ssl.py", line 162, in read v = self._sslobj.read(len or 1024) socket.error: [Errno 10053] An established connection was aborted by the software in your host machine ====================================================================== ERROR: test_numeric_terminator1 (test.test_asynchat.TestAsynchat) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_asynchat.py", line 153, in test_numeric_terminator1 self.numeric_terminator_check(1) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_asynchat.py", line 145, in numeric_terminator_check asyncore.loop(use_poll=self.usepoll, count=300, timeout=.01) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 195, in loop poll_fun(timeout, map) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 132, in poll read(obj) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 72, in read obj.handle_error() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 68, in read obj.handle_read_event() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 390, in handle_read_event self.handle_read() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_ssl.py", line 517, in handle_read data = self.recv(1024) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 342, in recv data = self.socket.recv(buffer_size) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\ssl.py", line 247, in recv return self.read(buflen) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\ssl.py", line 162, in read v = self._sslobj.read(len or 1024) socket.error: [Errno 10053] An established connection was aborted by the software in your host machine ====================================================================== ERROR: test_numeric_terminator2 (test.test_asynchat.TestAsynchat) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_asynchat.py", line 156, in test_numeric_terminator2 self.numeric_terminator_check(6) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_asynchat.py", line 145, in numeric_terminator_check asyncore.loop(use_poll=self.usepoll, count=300, timeout=.01) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 195, in loop poll_fun(timeout, map) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 132, in poll read(obj) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 72, in read obj.handle_error() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 68, in read obj.handle_read_event() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 390, in handle_read_event self.handle_read() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_ssl.py", line 517, in handle_read data = self.recv(1024) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 342, in recv data = self.socket.recv(buffer_size) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\ssl.py", line 247, in recv return self.read(buflen) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\ssl.py", line 162, in read v = self._sslobj.read(len or 1024) socket.error: [Errno 10053] An established connection was aborted by the software in your host machine ====================================================================== ERROR: test_simple_producer (test.test_asynchat.TestAsynchat) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_asynchat.py", line 177, in test_simple_producer asyncore.loop(use_poll=self.usepoll, count=300, timeout=.01) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 195, in loop poll_fun(timeout, map) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 132, in poll read(obj) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 72, in read obj.handle_error() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 68, in read obj.handle_read_event() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 390, in handle_read_event self.handle_read() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_ssl.py", line 517, in handle_read data = self.recv(1024) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 342, in recv data = self.socket.recv(buffer_size) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\ssl.py", line 247, in recv return self.read(buflen) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\ssl.py", line 162, in read v = self._sslobj.read(len or 1024) socket.error: [Errno 10053] An established connection was aborted by the software in your host machine ====================================================================== ERROR: test_string_producer (test.test_asynchat.TestAsynchat) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_asynchat.py", line 187, in test_string_producer asyncore.loop(use_poll=self.usepoll, count=300, timeout=.01) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 195, in loop poll_fun(timeout, map) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 132, in poll read(obj) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 72, in read obj.handle_error() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 68, in read obj.handle_read_event() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 390, in handle_read_event self.handle_read() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_ssl.py", line 517, in handle_read data = self.recv(1024) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 342, in recv data = self.socket.recv(buffer_size) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\ssl.py", line 247, in recv return self.read(buflen) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\ssl.py", line 162, in read v = self._sslobj.read(len or 1024) socket.error: [Errno 10053] An established connection was aborted by the software in your host machine ====================================================================== ERROR: test_close_when_done (test.test_asynchat.TestAsynchat_WithPoll) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_asynchat.py", line 210, in test_close_when_done asyncore.loop(use_poll=self.usepoll, count=300, timeout=.01) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 195, in loop poll_fun(timeout, map) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 132, in poll read(obj) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 72, in read obj.handle_error() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 68, in read obj.handle_read_event() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 390, in handle_read_event self.handle_read() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_ssl.py", line 517, in handle_read data = self.recv(1024) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 342, in recv data = self.socket.recv(buffer_size) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\ssl.py", line 247, in recv return self.read(buflen) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\ssl.py", line 162, in read v = self._sslobj.read(len or 1024) socket.error: [Errno 10053] An established connection was aborted by the software in your host machine ====================================================================== ERROR: test_empty_line (test.test_asynchat.TestAsynchat_WithPoll) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_asynchat.py", line 198, in test_empty_line asyncore.loop(use_poll=self.usepoll, count=300, timeout=.01) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 195, in loop poll_fun(timeout, map) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 132, in poll read(obj) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 72, in read obj.handle_error() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 68, in read obj.handle_read_event() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 390, in handle_read_event self.handle_read() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_ssl.py", line 517, in handle_read data = self.recv(1024) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 342, in recv data = self.socket.recv(buffer_size) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\ssl.py", line 247, in recv return self.read(buflen) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\ssl.py", line 162, in read v = self._sslobj.read(len or 1024) socket.error: [Errno 10053] An established connection was aborted by the software in your host machine ====================================================================== ERROR: test_line_terminator1 (test.test_asynchat.TestAsynchat_WithPoll) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_asynchat.py", line 126, in test_line_terminator1 self.line_terminator_check('\n', l) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_asynchat.py", line 114, in line_terminator_check asyncore.loop(use_poll=self.usepoll, count=300, timeout=.01) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 195, in loop poll_fun(timeout, map) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 132, in poll read(obj) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 72, in read obj.handle_error() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 68, in read obj.handle_read_event() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 390, in handle_read_event self.handle_read() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_ssl.py", line 517, in handle_read data = self.recv(1024) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 342, in recv data = self.socket.recv(buffer_size) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\ssl.py", line 247, in recv return self.read(buflen) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\ssl.py", line 162, in read v = self._sslobj.read(len or 1024) socket.error: [Errno 10053] An established connection was aborted by the software in your host machine ====================================================================== ERROR: test_line_terminator2 (test.test_asynchat.TestAsynchat_WithPoll) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_asynchat.py", line 131, in test_line_terminator2 self.line_terminator_check('\r\n', l) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_asynchat.py", line 114, in line_terminator_check asyncore.loop(use_poll=self.usepoll, count=300, timeout=.01) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 195, in loop poll_fun(timeout, map) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 132, in poll read(obj) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 72, in read obj.handle_error() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 68, in read obj.handle_read_event() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 390, in handle_read_event self.handle_read() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_ssl.py", line 517, in handle_read data = self.recv(1024) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 342, in recv data = self.socket.recv(buffer_size) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\ssl.py", line 247, in recv return self.read(buflen) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\ssl.py", line 162, in read v = self._sslobj.read(len or 1024) socket.error: [Errno 10053] An established connection was aborted by the software in your host machine ====================================================================== ERROR: test_line_terminator3 (test.test_asynchat.TestAsynchat_WithPoll) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_asynchat.py", line 136, in test_line_terminator3 self.line_terminator_check('qqq', l) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_asynchat.py", line 114, in line_terminator_check asyncore.loop(use_poll=self.usepoll, count=300, timeout=.01) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 195, in loop poll_fun(timeout, map) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 132, in poll read(obj) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 72, in read obj.handle_error() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 68, in read obj.handle_read_event() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 390, in handle_read_event self.handle_read() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_ssl.py", line 517, in handle_read data = self.recv(1024) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 342, in recv data = self.socket.recv(buffer_size) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\ssl.py", line 247, in recv return self.read(buflen) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\ssl.py", line 162, in read v = self._sslobj.read(len or 1024) socket.error: [Errno 10053] An established connection was aborted by the software in your host machine ====================================================================== ERROR: test_none_terminator (test.test_asynchat.TestAsynchat_WithPoll) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_asynchat.py", line 165, in test_none_terminator asyncore.loop(use_poll=self.usepoll, count=300, timeout=.01) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 195, in loop poll_fun(timeout, map) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 132, in poll read(obj) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 72, in read obj.handle_error() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 68, in read obj.handle_read_event() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 390, in handle_read_event self.handle_read() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_ssl.py", line 517, in handle_read data = self.recv(1024) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 342, in recv data = self.socket.recv(buffer_size) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\ssl.py", line 247, in recv return self.read(buflen) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\ssl.py", line 162, in read v = self._sslobj.read(len or 1024) socket.error: [Errno 10053] An established connection was aborted by the software in your host machine ====================================================================== ERROR: test_numeric_terminator1 (test.test_asynchat.TestAsynchat_WithPoll) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_asynchat.py", line 153, in test_numeric_terminator1 self.numeric_terminator_check(1) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_asynchat.py", line 145, in numeric_terminator_check asyncore.loop(use_poll=self.usepoll, count=300, timeout=.01) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 195, in loop poll_fun(timeout, map) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 132, in poll read(obj) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 72, in read obj.handle_error() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 68, in read obj.handle_read_event() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 390, in handle_read_event self.handle_read() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_ssl.py", line 517, in handle_read data = self.recv(1024) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 342, in recv data = self.socket.recv(buffer_size) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\ssl.py", line 247, in recv return self.read(buflen) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\ssl.py", line 162, in read v = self._sslobj.read(len or 1024) socket.error: [Errno 10053] An established connection was aborted by the software in your host machine ====================================================================== ERROR: test_numeric_terminator2 (test.test_asynchat.TestAsynchat_WithPoll) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_asynchat.py", line 156, in test_numeric_terminator2 self.numeric_terminator_check(6) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_asynchat.py", line 145, in numeric_terminator_check asyncore.loop(use_poll=self.usepoll, count=300, timeout=.01) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 195, in loop poll_fun(timeout, map) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 132, in poll read(obj) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 72, in read obj.handle_error() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 68, in read obj.handle_read_event() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 390, in handle_read_event self.handle_read() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_ssl.py", line 517, in handle_read data = self.recv(1024) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 342, in recv data = self.socket.recv(buffer_size) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\ssl.py", line 247, in recv return self.read(buflen) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\ssl.py", line 162, in read v = self._sslobj.read(len or 1024) socket.error: [Errno 10053] An established connection was aborted by the software in your host machine ====================================================================== ERROR: test_simple_producer (test.test_asynchat.TestAsynchat_WithPoll) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_asynchat.py", line 177, in test_simple_producer asyncore.loop(use_poll=self.usepoll, count=300, timeout=.01) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 195, in loop poll_fun(timeout, map) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 132, in poll read(obj) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 72, in read obj.handle_error() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 68, in read obj.handle_read_event() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 390, in handle_read_event self.handle_read() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_ssl.py", line 517, in handle_read data = self.recv(1024) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 342, in recv data = self.socket.recv(buffer_size) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\ssl.py", line 247, in recv return self.read(buflen) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\ssl.py", line 162, in read v = self._sslobj.read(len or 1024) socket.error: [Errno 10053] An established connection was aborted by the software in your host machine ====================================================================== ERROR: test_string_producer (test.test_asynchat.TestAsynchat_WithPoll) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_asynchat.py", line 187, in test_string_producer asyncore.loop(use_poll=self.usepoll, count=300, timeout=.01) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 195, in loop poll_fun(timeout, map) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 132, in poll read(obj) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 72, in read obj.handle_error() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 68, in read obj.handle_read_event() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 390, in handle_read_event self.handle_read() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_ssl.py", line 517, in handle_read data = self.recv(1024) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\asyncore.py", line 342, in recv data = self.socket.recv(buffer_size) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\ssl.py", line 247, in recv return self.read(buflen) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\ssl.py", line 162, in read v = self._sslobj.read(len or 1024) socket.error: [Errno 10053] An established connection was aborted by the software in your host machine ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestBTree) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestHashTable) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestBTree_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestHashTable_InMemory) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test__no_deadlock_first (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_change (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_clear (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_close_and_reopen (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_contains (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_next_looping (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_first_while_deleting (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_for_cursor_memleak (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_getitem (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iter_while_modifying_values (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_iteritems_while_modifying_values (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keyordering (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_last_while_deleting (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_mapping_iteration_methods (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_previous_last_looping (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_set_location (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_bsddb.TestBTree_InMemory_Truncate) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 20, in setUp self.f = self.do_open(self.fname, self.openflag, cachesize=32768) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb.py", line 17, in do_open return bsddb.StringValues(bsddb.StringKeys(self.openmethod[0](*args, **kw))) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 452, in btopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 488, in _openDBEnv e.set_cachesize(0, cachesize) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') Traceback (most recent call last): File "../lib/test/regrtest.py", line 596, in runtest_inner indirect_test() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb3.py", line 90, in test_main run_unittest(suite()) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_bsddb3.py", line 53, in suite import bsddb.test.test_1413192 File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\test\test_1413192.py", line 38, in context = Context() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\test\test_1413192.py", line 26, in __init__ db.DB_CREATE | db.DB_INIT_TXN | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_consistent_factory (test.test_mailbox.TestMaildir) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 520, in test_consistent_factory msg2 = box.get_message(key) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\mailbox.py", line 313, in get_message subpath = self._lookup(key) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\mailbox.py", line 482, in _lookup raise KeyError('No message with key: %s' % key) KeyError: 'No message with key: 1201554260.M144000P2532Q201.buildbot' ====================================================================== ERROR: test_flush (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 717, in tearDown self._delete_recursively(self._path) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 47, in _delete_recursively os.remove(target) WindowsError: [Error 32] The process cannot access the file because it is being used by another process: '@test' ====================================================================== ERROR: test_popitem (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 336, in test_popitem self.assertEqual(int(msg.get_payload()), keys.index(key)) ValueError: invalid literal for int() with base 10: 'From: foo 0 F' ====================================================================== ERROR: test_flush (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 717, in tearDown self._delete_recursively(self._path) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 47, in _delete_recursively os.remove(target) WindowsError: [Error 32] The process cannot access the file because it is being used by another process: '@test' ====================================================================== ERROR: test_popitem (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 336, in test_popitem self.assertEqual(int(msg.get_payload()), keys.index(key)) ValueError: invalid literal for int() with base 10: 'From: foo 0 \x01' ====================================================================== ERROR: test_flush (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 940, in tearDown self._delete_recursively(self._path) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 47, in _delete_recursively os.remove(target) WindowsError: [Error 32] The process cannot access the file because it is being used by another process: '@test' ====================================================================== ERROR: test_popitem (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 336, in test_popitem self.assertEqual(int(msg.get_payload()), keys.index(key)) ValueError: invalid literal for int() with base 10: 'From: foo *** EOOH *** From: foo 0 1,, From: foo *** EOOH *** From: foo 1 1,, From: foo *** EOOH *** From: foo 2 1,, From: foo *** EOOH *** From: foo 3 ' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestMaildir) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_add (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 77, in test_add self.assertEqual(self._box.get_string(keys[0]), self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\nF' != 'From: foo\n\n0' ====================================================================== FAIL: test_add_and_close (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 757, in test_add_and_close self.assertEqual(contents, open(self._path, 'r').read()) AssertionError: 'From MAILER-DAEMON Mon Jan 28 21:04:58 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Mon Jan 28 21:04:58 2008\n\nFrom: foo\n\n0\n\nFrom MAILER-DAEMON Mon Jan 28 21:04:58 2008\n\nFrom: foo\n\n1\n\nFrom MAILER-DAEMON Mon Jan 28 21:04:58 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Mon Jan 28 21:04:58 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'From MAILER-DAEMON Mon Jan 28 21:04:58 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Mon Jan 28 21:04:58 2008\n\nFrom: foo\n\n0\n\nFrom MAILER-DAEMON Mon Jan 28 21:04:58 2008\n\nFrom: foo\n\n1\n\nFrom MAILER-DAEMON Mon Jan 28 21:04:58 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Mon Jan 28 21:04:58 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Mon Jan 28 21:04:58 2008\n\nFrom: foo\n\n0\n\nFrom MAILER-DAEMON Mon Jan 28 21:04:58 2008\n\nFrom: foo\n\n1\n\nFrom MAILER-DAEMON Mon Jan 28 21:04:58 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Mon Jan 28 21:04:58 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Mon Jan 28 21:04:58 2008\n\nFrom: foo\n\n1\n\nFrom MAILER-DAEMON Mon Jan 28 21:04:58 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Mon Jan 28 21:04:58 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Mon Jan 28 21:04:58 2008\n\nFrom: foo\n\n2\n\nFrom MAILER-DAEMON Mon Jan 28 21:04:58 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\nFrom MAILER-DAEMON Mon Jan 28 21:04:58 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' ====================================================================== FAIL: test_add_from_string (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 724, in test_add_from_string self.assertEqual(self._box[key].get_from(), 'foo at bar blah') AssertionError: 'foo at bar blah\n' != 'foo at bar blah' ====================================================================== FAIL: test_close (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 389, in test_close self._test_flush_or_close(self._box.close) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 6 != 3 ====================================================================== FAIL: test_delitem (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 87, in test_delitem self._test_remove_or_delitem(self._box.__delitem__) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n1' != 'From: foo\n\n1' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_flush (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 377, in test_flush self._test_flush_or_close(self._box.flush) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 6 != 3 ====================================================================== FAIL: test_get (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 129, in test_get self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_file (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 174, in test_get_file self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\nF' != 'From: foo\n\n0' ====================================================================== FAIL: test_get_message (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 156, in test_get_message self.assertEqual(msg0['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_string (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 164, in test_get_string self.assertEqual(self._box.get_string(key0), self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\nF' != 'From: foo\n\n0' ====================================================================== FAIL: test_getitem (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 144, in test_getitem self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_items (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 207, in test_items self._check_iteration(self._box.items, do_keys=True, do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iter (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 194, in test_iter do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iteritems (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 203, in test_iteritems do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_itervalues (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 189, in test_itervalues do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_open_close_open (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 741, in test_open_close_open self.assertEqual(len(self._box), 3) AssertionError: 6 != 3 ====================================================================== FAIL: test_pop (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 313, in test_pop self.assertEqual(self._box.pop(key0).get_payload(), '0') AssertionError: 'From: foo\n\n0\n\nF' != '0' ====================================================================== FAIL: test_remove (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 83, in test_remove self._test_remove_or_delitem(self._box.remove) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n1' != 'From: foo\n\n1' ====================================================================== FAIL: test_set_item (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 272, in test_set_item self._template % 'original 0') AssertionError: '\nFrom: foo\n\noriginal 0' != 'From: foo\n\noriginal 0' ====================================================================== FAIL: test_update (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 350, in test_update self._template % 'changed 0') AssertionError: '\nFrom: foo\n\nchanged 0\n\nF' != 'From: foo\n\nchanged 0' ====================================================================== FAIL: test_values (test.test_mailbox.TestMbox) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 198, in test_values self._check_iteration(self._box.values, do_keys=False, do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_add (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 77, in test_add self.assertEqual(self._box.get_string(keys[0]), self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\n\x01' != 'From: foo\n\n0' ====================================================================== FAIL: test_add_and_close (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 757, in test_add_and_close self.assertEqual(contents, open(self._path, 'r').read()) AssertionError: '\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Mon Jan 28 21:05:20 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Mon Jan 28 21:05:20 2008\n\nFrom: foo\n\n0\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Mon Jan 28 21:05:20 2008\n\nFrom: foo\n\n1\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Mon Jan 28 21:05:20 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Mon Jan 28 21:05:20 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n' != '\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Mon Jan 28 21:05:20 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Mon Jan 28 21:05:20 2008\n\nFrom: foo\n\n0\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Mon Jan 28 21:05:20 2008\n\nFrom: foo\n\n1\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Mon Jan 28 21:05:20 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Mon Jan 28 21:05:20 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Mon Jan 28 21:05:20 2008\n\nFrom: foo\n\n0\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Mon Jan 28 21:05:20 2008\n\nFrom: foo\n\n1\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Mon Jan 28 21:05:20 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Mon Jan 28 21:05:20 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Mon Jan 28 21:05:20 2008\n\nFrom: foo\n\n1\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Mon Jan 28 21:05:20 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Mon Jan 28 21:05:20 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Mon Jan 28 21:05:20 2008\n\nFrom: foo\n\n2\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Mon Jan 28 21:05:20 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n\x01\x01\x01\x01\n\nFrom MAILER-DAEMON Mon Jan 28 21:05:20 2008\n\nReturn-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n\n\n\x01\x01\x01\x01\n\n\n\n\x01\x01\x01\x01\n\n' ====================================================================== FAIL: test_add_from_string (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 724, in test_add_from_string self.assertEqual(self._box[key].get_from(), 'foo at bar blah') AssertionError: 'foo at bar blah\n' != 'foo at bar blah' ====================================================================== FAIL: test_close (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 389, in test_close self._test_flush_or_close(self._box.close) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_delitem (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 87, in test_delitem self._test_remove_or_delitem(self._box.__delitem__) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n1\n\n\x01' != 'From: foo\n\n1' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_flush (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 377, in test_flush self._test_flush_or_close(self._box.flush) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_get (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 129, in test_get self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_file (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 174, in test_get_file self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\n\x01' != 'From: foo\n\n0' ====================================================================== FAIL: test_get_message (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 156, in test_get_message self.assertEqual(msg0['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_string (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 164, in test_get_string self.assertEqual(self._box.get_string(key0), self._template % 0) AssertionError: '\nFrom: foo\n\n0\n\n\x01' != 'From: foo\n\n0' ====================================================================== FAIL: test_getitem (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 144, in test_getitem self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_items (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 207, in test_items self._check_iteration(self._box.items, do_keys=True, do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iter (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 194, in test_iter do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iteritems (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 203, in test_iteritems do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_itervalues (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 189, in test_itervalues do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_open_close_open (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 741, in test_open_close_open self.assertEqual(len(self._box), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_pop (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 313, in test_pop self.assertEqual(self._box.pop(key0).get_payload(), '0') AssertionError: 'From: foo\n\n0\n\n\x01' != '0' ====================================================================== FAIL: test_remove (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 83, in test_remove self._test_remove_or_delitem(self._box.remove) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n1\n\n\x01' != 'From: foo\n\n1' ====================================================================== FAIL: test_set_item (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 272, in test_set_item self._template % 'original 0') AssertionError: '\nFrom: foo\n\noriginal 0\n\n\x01' != 'From: foo\n\noriginal 0' ====================================================================== FAIL: test_update (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 350, in test_update self._template % 'changed 0') AssertionError: '\nFrom: foo\n\nchanged 0\n\n\x01' != 'From: foo\n\nchanged 0' ====================================================================== FAIL: test_values (test.test_mailbox.TestMMDF) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 198, in test_values self._check_iteration(self._box.values, do_keys=False, do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestMH) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_add (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 77, in test_add self.assertEqual(self._box.get_string(keys[0]), self._template % 0) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n0\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f' != 'From: foo\n\n0' ====================================================================== FAIL: test_close (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 389, in test_close self._test_flush_or_close(self._box.close) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_delitem (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 87, in test_delitem self._test_remove_or_delitem(self._box.__delitem__) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n1\n\n\x1f' != 'From: foo\n\n1' ====================================================================== FAIL: test_dump_message (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 412, in test_dump_message _sample_message.replace('\n', os.linesep)) AssertionError: 'Return-Path: \nX-Original-To: gkj+person at localhost\nDelivered-To: gkj+person at localhost\nReceived: from localhost (localhost [127.0.0.1])\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nDelivered-To: gkj at sundance.gregorykjohnson.com\nReceived: from localhost [127.0.0.1]\n by localhost with POP3 (fetchmail-6.2.5)\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\nDate: Wed, 13 Jul 2005 17:23:11 -0400\nFrom: "Gregory K. Johnson" \nTo: gkj at gregorykjohnson.com\nSubject: Sample message\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\nMime-Version: 1.0\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\nContent-Disposition: inline\nUser-Agent: Mutt/1.5.9i\n\n\n--NMuMz9nt05w80d4+\nContent-Type: text/plain; charset=us-ascii\nContent-Disposition: inline\n\nThis is a sample message.\n\n--\nGregory K. Johnson\n\n--NMuMz9nt05w80d4+\nContent-Type: application/octet-stream\nContent-Disposition: attachment; filename="text.gz"\nContent-Transfer-Encoding: base64\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n3FYlAAAA\n\n--NMuMz9nt05w80d4+--\n' != 'Return-Path: \r\nX-Original-To: gkj+person at localhost\r\nDelivered-To: gkj+person at localhost\r\nReceived: from localhost (localhost [127.0.0.1])\r\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\r\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nDelivered-To: gkj at sundance.gregorykjohnson.com\r\nReceived: from localhost [127.0.0.1]\r\n by localhost with POP3 (fetchmail-6.2.5)\r\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\r\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\r\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\r\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\r\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\r\nDate: Wed, 13 Jul 2005 17:23:11 -0400\r\nFrom: "Gregory K. Johnson" \r\nTo: gkj at gregorykjohnson.com\r\nSubject: Sample message\r\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\r\nMime-Version: 1.0\r\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\r\nContent-Disposition: inline\r\nUser-Agent: Mutt/1.5.9i\r\n\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: text/plain; charset=us-ascii\r\nContent-Disposition: inline\r\n\r\nThis is a sample message.\r\n\r\n--\r\nGregory K. Johnson\r\n\r\n--NMuMz9nt05w80d4+\r\nContent-Type: application/octet-stream\r\nContent-Disposition: attachment; filename="text.gz"\r\nContent-Transfer-Encoding: base64\r\n\r\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\r\n3FYlAAAA\r\n\r\n--NMuMz9nt05w80d4+--\r\n' ====================================================================== FAIL: test_flush (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 377, in test_flush self._test_flush_or_close(self._box.flush) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 400, in _test_flush_or_close self.assertEqual(len(keys), 3) AssertionError: 0 != 3 ====================================================================== FAIL: test_get (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 129, in test_get self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_file (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 174, in test_get_file self._template % 0) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n0\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f' != 'From: foo\n\n0' ====================================================================== FAIL: test_get_message (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 156, in test_get_message self.assertEqual(msg0['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_get_string (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 164, in test_get_string self.assertEqual(self._box.get_string(key0), self._template % 0) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n0\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f' != 'From: foo\n\n0' ====================================================================== FAIL: test_getitem (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 144, in test_getitem self.assertEqual(msg['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_items (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 207, in test_items self._check_iteration(self._box.items, do_keys=True, do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iter (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 194, in test_iter do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_iteritems (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 203, in test_iteritems do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_itervalues (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 189, in test_itervalues do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== FAIL: test_pop (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 313, in test_pop self.assertEqual(self._box.pop(key0).get_payload(), '0') AssertionError: 'From: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n0\n\n\x1f\x0c\n\n1,,\n\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n1\n\n\x1f' != '0' ====================================================================== FAIL: test_remove (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 83, in test_remove self._test_remove_or_delitem(self._box.remove) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 99, in _test_remove_or_delitem self.assertEqual(self._box.get_string(key1), self._template % 1) AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\n1\n\n\x1f' != 'From: foo\n\n1' ====================================================================== FAIL: test_set_item (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 272, in test_set_item self._template % 'original 0') AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\noriginal 0\n\n\x1f' != 'From: foo\n\noriginal 0' ====================================================================== FAIL: test_update (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 350, in test_update self._template % 'changed 0') AssertionError: '\nFrom: foo\n\n\n\n*** EOOH ***\n\nFrom: foo\n\n\n\nchanged 0\n\n\x1f\x0c\n\n1,,\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n*** EOOH ***\n\nReturn-Path: \n\nX-Original-To: gkj+person at localhost\n\nDelivered-To: gkj+person at localhost\n\nReceived: from localhost (localhost [127.0.0.1])\n\n by andy.gregorykjohnson.com (Postfix) with ESMTP id 356ED9DD17\n\n for ; Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nDelivered-To: gkj at sundance.gregorykjohnson.com\n\nReceived: from localhost [127.0.0.1]\n\n by localhost with POP3 (fetchmail-6.2.5)\n\n for gkj+person at localhost (single-drop); Wed, 13 Jul 2005 17:23:16 -0400 (EDT)\n\nReceived: from andy.gregorykjohnson.com (andy.gregorykjohnson.com [64.32.235.228])\n\n by sundance.gregorykjohnson.com (Postfix) with ESMTP id 5B056316746\n\n for ; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nReceived: by andy.gregorykjohnson.com (Postfix, from userid 1000)\n\n id 490CD9DD17; Wed, 13 Jul 2005 17:23:11 -0400 (EDT)\n\nDate: Wed, 13 Jul 2005 17:23:11 -0400\n\nFrom: "Gregory K. Johnson" \n\nTo: gkj at gregorykjohnson.com\n\nSubject: Sample message\n\nMessage-ID: <20050713212311.GC4701 at andy.gregorykjohnson.com>\n\nMime-Version: 1.0\n\nContent-Type: multipart/mixed; boundary="NMuMz9nt05w80d4+"\n\nContent-Disposition: inline\n\nUser-Agent: Mutt/1.5.9i\n\n\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: text/plain; charset=us-ascii\n\nContent-Disposition: inline\n\n\n\nThis is a sample message.\n\n\n\n--\n\nGregory K. Johnson\n\n\n\n--NMuMz9nt05w80d4+\n\nContent-Type: application/octet-stream\n\nContent-Disposition: attachment; filename="text.gz"\n\nContent-Transfer-Encoding: base64\n\n\n\nH4sICM2D1UIAA3RleHQAC8nILFYAokSFktSKEoW0zJxUPa7wzJIMhZLyfIWczLzUYj0uAHTs\n\n3FYlAAAA\n\n\n\n--NMuMz9nt05w80d4+--\n\n\n\n\x1f' != 'From: foo\n\nchanged 0' ====================================================================== FAIL: test_values (test.test_mailbox.TestBabyl) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 198, in test_values self._check_iteration(self._box.values, do_keys=False, do_values=True) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_mailbox.py", line 231, in _check_iteration self.assertEqual(value['from'], 'foo') AssertionError: None != 'foo' ====================================================================== ERROR: test_bool (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 136, in test_bool self.assert_(not self._empty_mapping()) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_constructor (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 133, in test_constructor self.assertEqual(self._empty_mapping(), self._empty_mapping()) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 270, in test_get d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_items (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 156, in test_items d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keys (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 142, in test_keys d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 162, in test_len d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 293, in test_pop d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 288, in test_popitem d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_read (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 44, in test_read p = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 284, in test_setdefault d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 174, in test_update d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_values (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 150, in test_values d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_write (test.test_shelve.TestAsciiFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 92, in test_write p = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_bool (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 136, in test_bool self.assert_(not self._empty_mapping()) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_constructor (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 133, in test_constructor self.assertEqual(self._empty_mapping(), self._empty_mapping()) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 270, in test_get d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_items (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 156, in test_items d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keys (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 142, in test_keys d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 162, in test_len d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 293, in test_pop d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 288, in test_popitem d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_read (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 44, in test_read p = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 284, in test_setdefault d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 174, in test_update d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_values (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 150, in test_values d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_write (test.test_shelve.TestBinaryFileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 92, in test_write p = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_bool (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 136, in test_bool self.assert_(not self._empty_mapping()) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_constructor (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 133, in test_constructor self.assertEqual(self._empty_mapping(), self._empty_mapping()) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_get (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 270, in test_get d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_items (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 156, in test_items d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_keys (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 142, in test_keys d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_len (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 162, in test_len d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_pop (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 293, in test_pop d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_popitem (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 288, in test_popitem d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_read (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 44, in test_read p = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_setdefault (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 284, in test_setdefault d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_update (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 174, in test_update d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_values (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 150, in test_values d = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_write (test.test_shelve.TestProto2FileShelve) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\mapping_tests.py", line 92, in test_write p = self._empty_mapping() File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 122, in _empty_mapping x= shelve.open(self.fn+str(self.counter), **self._args) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_ascii_file_shelf (test.test_shelve.TestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 46, in test_ascii_file_shelf s = shelve.open(self.fn, protocol=0) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_binary_file_shelf (test.test_shelve.TestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 54, in test_binary_file_shelf s = shelve.open(self.fn, protocol=1) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_proto2_file_shelf (test.test_shelve.TestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_shelve.py", line 62, in test_proto2_file_shelf s = shelve.open(self.fn, protocol=2) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 217, in open return DbfilenameShelf(filename, flag, protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\shelve.py", line 201, in __init__ Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\anydbm.py", line 83, in open return mod.open(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') ====================================================================== ERROR: test_whichdb (test.test_whichdb.WhichDBTestCase) ---------------------------------------------------------------------- Traceback (most recent call last): File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\test\test_whichdb.py", line 32, in test_whichdb f = module.open(_fname, 'c') File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 435, in hashopen e = _openDBEnv(cachesize) File "E:\cygwin\home\db3l\buildarea\3.0.bolen-windows\build\lib\bsddb\__init__.py", line 492, in _openDBEnv e.open('.', db.DB_PRIVATE | db.DB_CREATE | db.DB_THREAD | db.DB_INIT_LOCK | db.DB_INIT_MPOOL) bsddb.db.DBInvalidArgError: (22, 'Invalid argument') sincerely, -The Buildbot From python-checkins at python.org Mon Jan 28 22:34:30 2008 From: python-checkins at python.org (raymond.hettinger) Date: Mon, 28 Jan 2008 22:34:30 +0100 (CET) Subject: [Python-checkins] r60398 - python/trunk/Python/marshal.c Message-ID: <20080128213430.6C6501E400D@bag.python.org> Author: raymond.hettinger Date: Mon Jan 28 22:34:30 2008 New Revision: 60398 Modified: python/trunk/Python/marshal.c Log: Let marshal built-up sets and frozensets one element at a time (without creating an intermediate tuple). Modified: python/trunk/Python/marshal.c ============================================================================== --- python/trunk/Python/marshal.c (original) +++ python/trunk/Python/marshal.c Mon Jan 28 22:34:30 2008 @@ -860,7 +860,7 @@ retval = NULL; break; } - v = PyTuple_New((int)n); + v = (type == TYPE_SET) ? PySet_New(NULL) : PyFrozenSet_New(NULL); if (v == NULL) { retval = NULL; break; @@ -875,18 +875,14 @@ v = NULL; break; } - PyTuple_SET_ITEM(v, (int)i, v2); + if (PySet_Add(v, v2) == -1) { + Py_DECREF(v); + Py_DECREF(v2); + v = NULL; + break; + } } - if (v == NULL) { - retval = NULL; - break; - } - if (type == TYPE_SET) - v3 = PySet_New(v); - else - v3 = PyFrozenSet_New(v); - Py_DECREF(v); - retval = v3; + retval = (v == NULL) ? NULL : v; break; case TYPE_CODE: From python-checkins at python.org Mon Jan 28 22:47:42 2008 From: python-checkins at python.org (raymond.hettinger) Date: Mon, 28 Jan 2008 22:47:42 +0100 (CET) Subject: [Python-checkins] r60399 - in python/trunk: Include/setobject.h Objects/setobject.c Message-ID: <20080128214742.85B9B1E400D@bag.python.org> Author: raymond.hettinger Date: Mon Jan 28 22:47:42 2008 New Revision: 60399 Modified: python/trunk/Include/setobject.h python/trunk/Objects/setobject.c Log: Factor-out common code with a new macro Modified: python/trunk/Include/setobject.h ============================================================================== --- python/trunk/Include/setobject.h (original) +++ python/trunk/Include/setobject.h Mon Jan 28 22:47:42 2008 @@ -73,6 +73,8 @@ (Py_TYPE(ob) == &PySet_Type || Py_TYPE(ob) == &PyFrozenSet_Type || \ PyType_IsSubtype(Py_TYPE(ob), &PySet_Type) || \ PyType_IsSubtype(Py_TYPE(ob), &PyFrozenSet_Type)) +#define PySet_Check(ob) \ + (Py_TYPE(ob) == &PySet_Type || PyType_IsSubtype(Py_TYPE(ob), &PySet_Type)) PyAPI_FUNC(PyObject *) PySet_New(PyObject *); PyAPI_FUNC(PyObject *) PyFrozenSet_New(PyObject *); Modified: python/trunk/Objects/setobject.c ============================================================================== --- python/trunk/Objects/setobject.c (original) +++ python/trunk/Objects/setobject.c Mon Jan 28 22:47:42 2008 @@ -2158,7 +2158,7 @@ int PySet_Clear(PyObject *set) { - if (!PyType_IsSubtype(Py_TYPE(set), &PySet_Type)) { + if (!PySet_Check(set)) { PyErr_BadInternalCall(); return -1; } @@ -2178,7 +2178,7 @@ int PySet_Discard(PyObject *set, PyObject *key) { - if (!PyType_IsSubtype(Py_TYPE(set), &PySet_Type)) { + if (!PySet_Check(set)) { PyErr_BadInternalCall(); return -1; } @@ -2229,7 +2229,7 @@ PyObject * PySet_Pop(PyObject *set) { - if (!PyType_IsSubtype(Py_TYPE(set), &PySet_Type)) { + if (!PySet_Check(set)) { PyErr_BadInternalCall(); return NULL; } @@ -2239,7 +2239,7 @@ int _PySet_Update(PyObject *set, PyObject *iterable) { - if (!PyType_IsSubtype(Py_TYPE(set), &PySet_Type)) { + if (!PySet_Check(set)) { PyErr_BadInternalCall(); return -1; } From python-checkins at python.org Mon Jan 28 22:48:07 2008 From: python-checkins at python.org (raymond.hettinger) Date: Mon, 28 Jan 2008 22:48:07 +0100 (CET) Subject: [Python-checkins] r60400 - python/trunk/Doc/c-api/set.rst Message-ID: <20080128214807.DD0691E4014@bag.python.org> Author: raymond.hettinger Date: Mon Jan 28 22:48:07 2008 New Revision: 60400 Modified: python/trunk/Doc/c-api/set.rst Log: Factor-out common code with a new macro Modified: python/trunk/Doc/c-api/set.rst ============================================================================== --- python/trunk/Doc/c-api/set.rst (original) +++ python/trunk/Doc/c-api/set.rst Mon Jan 28 22:48:07 2008 @@ -52,6 +52,12 @@ the constructor functions work with any iterable Python object. +.. cfunction:: int PySet_Check(PyObject *p) + + Return true if *p* is a :class:`set` object or an instance of a subtype. + + .. versionadded:: 2.6 + .. cfunction:: int PyAnySet_Check(PyObject *p) Return true if *p* is a :class:`set` object, a :class:`frozenset` object, or an From python-checkins at python.org Mon Jan 28 22:51:25 2008 From: python-checkins at python.org (raymond.hettinger) Date: Mon, 28 Jan 2008 22:51:25 +0100 (CET) Subject: [Python-checkins] r60401 - python/trunk/Python/marshal.c Message-ID: <20080128215125.48EB41E4056@bag.python.org> Author: raymond.hettinger Date: Mon Jan 28 22:51:25 2008 New Revision: 60401 Modified: python/trunk/Python/marshal.c Log: Removed unnecessary conditional (spotted by Neal Norwitz). Modified: python/trunk/Python/marshal.c ============================================================================== --- python/trunk/Python/marshal.c (original) +++ python/trunk/Python/marshal.c Mon Jan 28 22:51:25 2008 @@ -882,7 +882,7 @@ break; } } - retval = (v == NULL) ? NULL : v; + retval = v; break; case TYPE_CODE: From buildbot at python.org Mon Jan 28 23:16:39 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 28 Jan 2008 22:16:39 +0000 Subject: [Python-checkins] buildbot failure in S-390 Debian trunk Message-ID: <20080128221639.9034F1E4025@bag.python.org> The Buildbot has detected a new failure of S-390 Debian trunk. Full details are available at: http://www.python.org/dev/buildbot/all/S-390%20Debian%20trunk/builds/8 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-s390 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_socket_ssl ====================================================================== ERROR: testBasic (test.test_socket_ssl.ConnectedTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-s390/build/Lib/test/test_socket_ssl.py", line 45, in testBasic buf = f.read() File "/home/pybot/buildarea/trunk.klose-debian-s390/build/Lib/ssl.py", line 333, in read data = self._sslobj.read(recv_size) SSLError: [Errno 8] _ssl.c:1276: EOF occurred in violation of protocol make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Mon Jan 28 23:31:57 2008 From: python-checkins at python.org (mark.dickinson) Date: Mon, 28 Jan 2008 23:31:57 +0100 (CET) Subject: [Python-checkins] r60402 - python/branches/trunk-math/Modules/mathmodule.c Message-ID: <20080128223157.D19DE1E400D@bag.python.org> Author: mark.dickinson Date: Mon Jan 28 23:31:57 2008 New Revision: 60402 Modified: python/branches/trunk-math/Modules/mathmodule.c Log: Rework math_1 so that the NaN-checking occurs after the function call, not before. math_1 now looks more like it did originally, it reads more cleanly, and it does the right thing for fabs(NaN) on OS X (where the default NaN has its sign bit set). Also added some additional comments explaining the changes to math_1. Modified: python/branches/trunk-math/Modules/mathmodule.c ============================================================================== --- python/branches/trunk-math/Modules/mathmodule.c (original) +++ python/branches/trunk-math/Modules/mathmodule.c Mon Jan 28 23:31:57 2008 @@ -95,41 +95,49 @@ return result; } +/* In math_1, the following rules are used to try to ensure that + functions raise the correct exceptions both on ANSI C platforms and + on C99 platforms: + + (1) Whenever a non-NaN argument gives a NaN result, set errno = EDOM + to force Python to raise a ValueError. + + (2) Whenever a finite argument gives an infinite result, set errno + to either EDOM or ERANGE to force Python to raise ValueError or + OverflowError respectively. The "can_overflow" argument should be + set to 1 for functions which might overflow but never raise + "divide-by-zero", and 0 for functions that never overflow. + Fortunately, none of the single-argument functions currently + implemented can raise both "divide-by-zero" *and* "overflow". + + (3) If neither of the above occurred but errno was set by the libm + function (this can happen in cases where Py_HUGE_VAL is not an + infinity) then raise OverflowError if errno==ERANGE and the result + was nonzero, do nothing if errno==ERANGE and the result was zero + (this can happen on underflow under ANSI C), and raise ValueError + if errno==EDOM. + +*/ + static PyObject * math_1(PyObject *arg, double (*func) (double), int can_overflow) { - int x_is_infinity; - double x = PyFloat_AsDouble(arg); + double x, r; + x = PyFloat_AsDouble(arg); if (x == -1.0 && PyErr_Occurred()) return NULL; - /* a NaN input should be returned unscathed */ - if (Py_IS_NAN(x)) - return PyFloat_FromDouble(x); - x_is_infinity = Py_IS_INFINITY(x); errno = 0; PyFPE_START_PROTECT("in math_1", return 0); - x = (*func)(x); - PyFPE_END_PROTECT(x); - - /* if the result was a NaN then we should be signalling a ValueError; - this should only happen in the cases where C99 recommends raising - invalid */ - if (Py_IS_NAN(x)) + r = (*func)(x); + PyFPE_END_PROTECT(r); + if (!Py_IS_NAN(x) && Py_IS_NAN(r)) errno = EDOM; - - /* if the input was finite and the result is an infinity, then either - overflow occurred and we should be setting errno to ERANGE so that - Python raises an OverflowError, or we were evaluating at a - singularity, and we should setting errno to EDOM so that Python - raises ValueError. Currently, none of the functions using math_1 - have singularities *and* the possibility of overflow :-) */ - if (!x_is_infinity && Py_IS_INFINITY(x)) + if (Py_IS_FINITE(x) && Py_IS_INFINITY(r)) errno = can_overflow ? ERANGE : EDOM; - - if (errno && is_error(x)) + if (errno && is_error(r)) return NULL; else - return PyFloat_FromDouble(x); + return PyFloat_FromDouble(r); } static PyObject * From buildbot at python.org Tue Jan 29 00:20:03 2008 From: buildbot at python.org (buildbot at python.org) Date: Mon, 28 Jan 2008 23:20:03 +0000 Subject: [Python-checkins] buildbot failure in x86 FreeBSD trunk Message-ID: <20080128232003.3DA191E4021@bag.python.org> The Buildbot has detected a new failure of x86 FreeBSD trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20FreeBSD%20trunk/builds/492 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-freebsd Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 227, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 268, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 281, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 560, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable 1 test failed: test_xmlrpc sincerely, -The Buildbot From python-checkins at python.org Tue Jan 29 00:21:00 2008 From: python-checkins at python.org (gregory.p.smith) Date: Tue, 29 Jan 2008 00:21:00 +0100 (CET) Subject: [Python-checkins] r60403 - python/trunk/setup.py Message-ID: <20080128232100.A8A801E400D@bag.python.org> Author: gregory.p.smith Date: Tue Jan 29 00:21:00 2008 New Revision: 60403 Modified: python/trunk/setup.py Log: Disable use of BerkeleyDB 4.6.x to see what the odd platform buildbots think. In particular, neal norwitz has traced an Ubuntu sparc64 crash to the Lib/test/bsddb/test_basics.py test when opening a db with DB_THREAD. Modified: python/trunk/setup.py ============================================================================== --- python/trunk/setup.py (original) +++ python/trunk/setup.py Tue Jan 29 00:21:00 2008 @@ -681,7 +681,10 @@ # a release. Most open source OSes come with one or more # versions of BerkeleyDB already installed. - max_db_ver = (4, 6) + max_db_ver = (4, 5) # XXX(gregory.p.smith): 4.6 "works" but seems to + # have issues on many platforms. I've temporarily + # disabled 4.6 to see what the odd platform + # buildbots say. min_db_ver = (3, 3) db_setup_debug = False # verbose debug prints from this script? From python-checkins at python.org Tue Jan 29 00:26:59 2008 From: python-checkins at python.org (mark.dickinson) Date: Tue, 29 Jan 2008 00:26:59 +0100 (CET) Subject: [Python-checkins] r60404 - in python/branches/trunk-math: Lib/test/test_math.py Modules/mathmodule.c Message-ID: <20080128232659.D89711E400D@bag.python.org> Author: mark.dickinson Date: Tue Jan 29 00:26:59 2008 New Revision: 60404 Modified: python/branches/trunk-math/Lib/test/test_math.py python/branches/trunk-math/Modules/mathmodule.c Log: Fix up special-value handling for modf, ldexp and frexp. Modified: python/branches/trunk-math/Lib/test/test_math.py ============================================================================== --- python/branches/trunk-math/Lib/test/test_math.py (original) +++ python/branches/trunk-math/Lib/test/test_math.py Tue Jan 29 00:26:59 2008 @@ -289,6 +289,10 @@ testfrexp('frexp(1)', math.frexp(1), (0.5, 1)) testfrexp('frexp(2)', math.frexp(2), (0.5, 2)) + self.assertEquals(math.frexp(INF)[0], INF) + self.assertEquals(math.frexp(NINF)[0], NINF) + self.assert_(math.isnan(math.frexp(NAN)[0])) + def testHypot(self): self.assertRaises(TypeError, math.hypot) self.ftest('hypot(0,0)', math.hypot(0,0), 0) @@ -306,6 +310,13 @@ self.ftest('ldexp(1,1)', math.ldexp(1,1), 2) self.ftest('ldexp(1,-1)', math.ldexp(1,-1), 0.5) self.ftest('ldexp(-1,1)', math.ldexp(-1,1), -2) + self.assertRaises(OverflowError, math.ldexp, 1., 1000000) + self.assertRaises(OverflowError, math.ldexp, -1., 1000000) + self.assertEquals(math.ldexp(1., -1000000), 0.) + self.assertEquals(math.ldexp(-1., -1000000), -0.) + self.assertEquals(math.ldexp(INF, 30), INF) + self.assertEquals(math.ldexp(NINF, -213), NINF) + self.assert_(math.isnan(math.ldexp(NAN, 0))) def testLog(self): self.assertRaises(TypeError, math.log) @@ -349,6 +360,13 @@ testmodf('modf(1.5)', math.modf(1.5), (0.5, 1.0)) testmodf('modf(-1.5)', math.modf(-1.5), (-0.5, -1.0)) + self.assertEquals(math.modf(INF), (0.0, INF)) + self.assertEquals(math.modf(NINF), (-0.0, NINF)) + + modf_nan = math.modf(NAN) + self.assert_(math.isnan(modf_nan[0])) + self.assert_(math.isnan(modf_nan[1])) + def testPow(self): self.assertRaises(TypeError, math.pow) self.ftest('pow(0,1)', math.pow(0,1), 0) Modified: python/branches/trunk-math/Modules/mathmodule.c ============================================================================== --- python/branches/trunk-math/Modules/mathmodule.c (original) +++ python/branches/trunk-math/Modules/mathmodule.c Tue Jan 29 00:26:59 2008 @@ -233,7 +233,7 @@ return NULL; errno = 0; x = frexp(x, &i); - Py_SET_ERRNO_ON_MATH_ERROR(x); + /* frexp shouldn't set errno; check, just in case. */ if (errno && is_error(x)) return NULL; else @@ -250,19 +250,20 @@ static PyObject * math_ldexp(PyObject *self, PyObject *args) { - double x; + double x, r; int exp; if (! PyArg_ParseTuple(args, "di:ldexp", &x, &exp)) return NULL; errno = 0; PyFPE_START_PROTECT("ldexp", return 0) - x = ldexp(x, exp); - PyFPE_END_PROTECT(x) - Py_SET_ERRNO_ON_MATH_ERROR(x); - if (errno && is_error(x)) + r = ldexp(x, exp); + PyFPE_END_PROTECT(r) + if (Py_IS_FINITE(x) && Py_IS_INFINITY(r)) + errno = ERANGE; + if (errno && is_error(r)) return NULL; else - return PyFloat_FromDouble(x); + return PyFloat_FromDouble(r); } PyDoc_STRVAR(math_ldexp_doc, @@ -276,7 +277,9 @@ return NULL; errno = 0; x = modf(x, &y); - Py_SET_ERRNO_ON_MATH_ERROR(x); + /* modf should never set errno; if it does, we raise a Python + exception---better to raise an exception than silently return + a possibly wrong value */ if (errno && is_error(x)) return NULL; else From buildbot at python.org Tue Jan 29 02:29:54 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 29 Jan 2008 01:29:54 +0000 Subject: [Python-checkins] buildbot failure in alpha Debian 3.0 Message-ID: <20080129012955.0A9481E400D@bag.python.org> The Buildbot has detected a new failure of alpha Debian 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/alpha%20Debian%203.0/builds/25 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-alpha Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes,eric.smith BUILD FAILED: failed failed slave lost sincerely, -The Buildbot From python-checkins at python.org Tue Jan 29 05:13:08 2008 From: python-checkins at python.org (brett.cannon) Date: Tue, 29 Jan 2008 05:13:08 +0100 (CET) Subject: [Python-checkins] r60405 - python/trunk/Makefile.pre.in Message-ID: <20080129041308.547101E400D@bag.python.org> Author: brett.cannon Date: Tue Jan 29 05:13:07 2008 New Revision: 60405 Modified: python/trunk/Makefile.pre.in Log: Fix the reindent rule to use $(BUILDPYTHON). Modified: python/trunk/Makefile.pre.in ============================================================================== --- python/trunk/Makefile.pre.in (original) +++ python/trunk/Makefile.pre.in Tue Jan 29 05:13:07 2008 @@ -1025,7 +1025,7 @@ # Run reindent on the library reindent: - ./python$(EXEEXT) $(srcdir)/Tools/scripts/reindent.py -r $(srcdir)/Lib + ./$(BUILDPYTHON) $(srcdir)/Tools/scripts/reindent.py -r $(srcdir)/Lib # Rerun configure with the same options as it was run last time, # provided the config.status script exists From python-checkins at python.org Tue Jan 29 05:18:05 2008 From: python-checkins at python.org (brett.cannon) Date: Tue, 29 Jan 2008 05:18:05 +0100 (CET) Subject: [Python-checkins] r60406 - python/trunk/Misc/Vim/python.vim python/trunk/Misc/Vim/syntax_test.py python/trunk/Misc/Vim/vim_syntax.py Message-ID: <20080129041805.586831E400D@bag.python.org> Author: brett.cannon Date: Tue Jan 29 05:18:04 2008 New Revision: 60406 Modified: python/trunk/Misc/Vim/python.vim python/trunk/Misc/Vim/syntax_test.py python/trunk/Misc/Vim/vim_syntax.py Log: Update Vim syntax highlighting to specify what revision was used to generate the file. Modified: python/trunk/Misc/Vim/python.vim ============================================================================== --- python/trunk/Misc/Vim/python.vim (original) +++ python/trunk/Misc/Vim/python.vim Tue Jan 29 05:18:04 2008 @@ -1,4 +1,4 @@ -" Auto-generated Vim syntax file for Python +" Auto-generated Vim syntax file for Python (trunk: r60376M). " " To use: copy or symlink to ~/.vim/syntax/python.vim @@ -64,7 +64,7 @@ if exists("python_highlight_builtins") syn keyword pythonBuiltin Ellipsis False None NotImplemented True __debug__ syn keyword pythonBuiltin __import__ abs all any apply basestring bool - syn keyword pythonBuiltin buffer callable chr classmethod cmp coerce + syn keyword pythonBuiltin buffer bytes callable chr classmethod cmp coerce syn keyword pythonBuiltin compile complex copyright credits delattr dict syn keyword pythonBuiltin dir divmod enumerate eval execfile exit file syn keyword pythonBuiltin filter float frozenset getattr globals hasattr @@ -73,7 +73,8 @@ syn keyword pythonBuiltin max min object oct open ord pow property quit syn keyword pythonBuiltin range raw_input reduce reload repr reversed round syn keyword pythonBuiltin set setattr slice sorted staticmethod str sum - syn keyword pythonBuiltin super tuple type unichr unicode vars xrange zip + syn keyword pythonBuiltin super trunc tuple type unichr unicode vars xrange + syn keyword pythonBuiltin zip endif Modified: python/trunk/Misc/Vim/syntax_test.py ============================================================================== --- python/trunk/Misc/Vim/syntax_test.py (original) +++ python/trunk/Misc/Vim/syntax_test.py Tue Jan 29 05:18:04 2008 @@ -4,9 +4,8 @@ Not necessarily sensical or comprehensive (assume that if one exception is highlighted that all are, for instance). -Highlighting extraneous whitespace at the end of the line is not represented -here as all trailing whitespace is automatically removed from .py files in the -repository. +Extraneous trailing whitespace can't be tested because of svn pre-commit hook +checks for such things. """ # Comment Modified: python/trunk/Misc/Vim/vim_syntax.py ============================================================================== --- python/trunk/Misc/Vim/vim_syntax.py (original) +++ python/trunk/Misc/Vim/vim_syntax.py Tue Jan 29 05:18:04 2008 @@ -4,8 +4,9 @@ import exceptions import __builtin__ from string import Template +from sys import subversion -comment_header = '''" Auto-generated Vim syntax file for Python. +comment_header = '''" Auto-generated Vim syntax file for Python (%s: r%s). " " To use: copy or symlink to ~/.vim/syntax/python.vim''' @@ -160,7 +161,7 @@ def main(file_path): with open(file_path, 'w') as FILE: # Comment for file - print>>FILE, comment_header + print>>FILE, comment_header % subversion[1:] print>>FILE, '' # Statements at start of file print>>FILE, statement_header From python-checkins at python.org Tue Jan 29 05:20:56 2008 From: python-checkins at python.org (brett.cannon) Date: Tue, 29 Jan 2008 05:20:56 +0100 (CET) Subject: [Python-checkins] r60407 - python/trunk/Doc/tools/sphinxext Message-ID: <20080129042056.B64C31E400D@bag.python.org> Author: brett.cannon Date: Tue Jan 29 05:20:56 2008 New Revision: 60407 Modified: python/trunk/Doc/tools/sphinxext/ (props changed) Log: Ignore .pyc and .pyo files. From buildbot at python.org Tue Jan 29 05:57:44 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 29 Jan 2008 04:57:44 +0000 Subject: [Python-checkins] buildbot failure in x86 gentoo trunk Message-ID: <20080129045745.104D31E4004@bag.python.org> The Buildbot has detected a new failure of x86 gentoo trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20gentoo%20trunk/builds/2987 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-x86 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: brett.cannon BUILD FAILED: failed test Excerpt from the test logfile: sincerely, -The Buildbot From buildbot at python.org Tue Jan 29 06:31:28 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 29 Jan 2008 05:31:28 +0000 Subject: [Python-checkins] buildbot failure in S-390 Debian trunk Message-ID: <20080129053128.9DCE91E4004@bag.python.org> The Buildbot has detected a new failure of S-390 Debian trunk. Full details are available at: http://www.python.org/dev/buildbot/all/S-390%20Debian%20trunk/builds/11 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-s390 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: brett.cannon BUILD FAILED: failed test Excerpt from the test logfile: 1 test failed: test_socket_ssl ====================================================================== ERROR: test_978833 (test.test_socket_ssl.BasicTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-s390/build/Lib/test/test_socket_ssl.py", line 140, in test_978833 self.connect(s, ("svn.python.org", 443)) File "/home/pybot/buildarea/trunk.klose-debian-s390/build/Lib/test/test_socket_ssl.py", line 131, in connect raise last_exc error: [Errno 111] Connection refused make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Tue Jan 29 06:49:17 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 29 Jan 2008 05:49:17 +0000 Subject: [Python-checkins] buildbot failure in x86 FreeBSD trunk Message-ID: <20080129054917.695B21E4003@bag.python.org> The Buildbot has detected a new failure of x86 FreeBSD trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20FreeBSD%20trunk/builds/495 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-freebsd Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: brett.cannon BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 227, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 268, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 281, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 560, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 227, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 268, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 281, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 560, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable 1 test failed: test_smtplib sincerely, -The Buildbot From amauryfa at gmail.com Tue Jan 29 09:17:54 2008 From: amauryfa at gmail.com (Amaury Forgeot d'Arc) Date: Tue, 29 Jan 2008 09:17:54 +0100 Subject: [Python-checkins] r60397 - in python/trunk: Doc/c-api/set.rst Objects/setobject.c Message-ID: > Log: > Make PySet_Add() work with frozensets. > Works like PyTuple_SetItem() to build-up values in a brand new frozenset. It seems to me that the function should verify that PySet_Add really operates on a new frozenset. PyTuple_SetItem does check that Py_REFCNT(ob)==1. -- Amaury Forgeot d'Arc From nnorwitz at gmail.com Tue Jan 29 11:26:37 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Tue, 29 Jan 2008 05:26:37 -0500 Subject: [Python-checkins] Python Regression Test Failures refleak (2) Message-ID: <20080129102637.GA21779@python.psfb.org> test_cmd_line leaked [0, 0, 23] references, sum=23 test_marshal leaked [32, 32, 32] references, sum=96 test_threadedtempfile leaked [-78, 0, 0] references, sum=-78 test_threadsignals leaked [0, -8, 0] references, sum=-8 test_urllib2_localnet leaked [3, 123, -117] references, sum=9 From buildbot at python.org Tue Jan 29 14:03:15 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 29 Jan 2008 13:03:15 +0000 Subject: [Python-checkins] buildbot failure in ARM Linux EABI 3.0 Message-ID: <20080129130315.7552C1E4003@bag.python.org> The Buildbot has detected a new failure of ARM Linux EABI 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/ARM%20Linux%20EABI%203.0/builds/17 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-linux-armeabi Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes BUILD FAILED: failed compile sincerely, -The Buildbot From python-checkins at python.org Tue Jan 29 14:07:21 2008 From: python-checkins at python.org (christian.heimes) Date: Tue, 29 Jan 2008 14:07:21 +0100 (CET) Subject: [Python-checkins] r60409 - in python/branches/trunk-math: Doc/library/cmath.rst Doc/library/stdtypes.rst Lib/test/test_cmath.py Lib/test/test_complex.py Misc/NEWS Modules/cmathmodule.c Objects/complexobject.c Message-ID: <20080129130722.02AF31E401E@bag.python.org> Author: christian.heimes Date: Tue Jan 29 14:07:21 2008 New Revision: 60409 Modified: python/branches/trunk-math/Doc/library/cmath.rst python/branches/trunk-math/Doc/library/stdtypes.rst python/branches/trunk-math/Lib/test/test_cmath.py python/branches/trunk-math/Lib/test/test_complex.py python/branches/trunk-math/Misc/NEWS python/branches/trunk-math/Modules/cmathmodule.c python/branches/trunk-math/Objects/complexobject.c Log: Removed from/as_cis methods and added arg, polar and rect functions to the math module. Modified: python/branches/trunk-math/Doc/library/cmath.rst ============================================================================== --- python/branches/trunk-math/Doc/library/cmath.rst (original) +++ python/branches/trunk-math/Doc/library/cmath.rst Tue Jan 29 14:07:21 2008 @@ -39,6 +39,13 @@ from 1 along the real axis to -?, continuous from above. +.. function:: arg(x) + + Return argument, also known as the phase angle, of a complex. + + .. versionadded:: 2.6 + + .. function:: asin(x) Return the arc sine of *x*. This has the same branch cuts as :func:`acos`. @@ -108,6 +115,21 @@ :func:`log`. +.. function:: polar(x) + + Convert a complex from rectangular coordinates to polar coordinates. r is + the distance from 0 and phi the phase angle. + + .. versionadded:: 2.6 + + +.. function:: rect(r, phi) + + Convert from polar coordinates to rectangular coordinates. + + .. versionadded:: 2.6 + + .. function:: sin(x) Return the sine of *x*. Modified: python/branches/trunk-math/Doc/library/stdtypes.rst ============================================================================== --- python/branches/trunk-math/Doc/library/stdtypes.rst (original) +++ python/branches/trunk-math/Doc/library/stdtypes.rst Tue Jan 29 14:07:21 2008 @@ -302,7 +302,7 @@ +--------------------+---------------------------------+--------+ | ``float(x)`` | *x* converted to floating point | \(6) | +--------------------+---------------------------------+--------+ -| ``complex(re,im)`` | a complex number with real part | \(8) | +| ``complex(re,im)`` | a complex number with real part | | | | *re*, imaginary part *im*. | | | | *im* defaults to zero. | | +--------------------+---------------------------------+--------+ @@ -370,14 +370,6 @@ Python defines ``pow(0, 0)`` and ``0 ** 0`` to be ``1``, as is common for programming languages. -(8) - The complex type has also the constructor ``from_cis(r, phi)`` to create a - complex from the polar form ``r * (cos(phi) + j * sin(pih))`` or - expotentional form ``r * exp(j * phi)``. The method ``as_cis()`` returns the - radius *r* and angle *phi* of a complex number. - - .. versionadded:: 2.6 - All :class:`numbers.Real` types (:class:`int`, :class:`long`, and :class:`float`) also include the following operations: Modified: python/branches/trunk-math/Lib/test/test_cmath.py ============================================================================== --- python/branches/trunk-math/Lib/test/test_cmath.py (original) +++ python/branches/trunk-math/Lib/test/test_cmath.py Tue Jan 29 14:07:21 2008 @@ -3,6 +3,7 @@ import unittest import os, sys import cmath, math +from cmath import arg, polar, rect, pi class CMathTests(unittest.TestCase): # list of all functions in cmath @@ -224,6 +225,38 @@ self.rAssertAlmostEqual(expected.real, actual.real) self.rAssertAlmostEqual(expected.imag, actual.imag) + def assertCISEqual(self, a, b): + eps = 1E-7 + if abs(a[0] - b[0]) > eps or abs(a[1] - b[1]) > eps: + self.fail((a ,b)) + + def test_polar(self): + self.assertCISEqual(polar(0), (0., 0.)) + self.assertCISEqual(polar(1.), (1., 0.)) + self.assertCISEqual(polar(-1.), (1., pi)) + self.assertCISEqual(polar(1j), (1., pi/2)) + self.assertCISEqual(polar(-1j), (1., -pi/2)) + + def test_arg(self): + self.assertAlmostEqual(arg(0), 0.) + self.assertAlmostEqual(arg(1.), 0.) + self.assertAlmostEqual(arg(-1.), pi) + self.assertAlmostEqual(arg(1j), pi/2) + self.assertAlmostEqual(arg(-1j), -pi/2) + + def assertCEqual(self, a, b): + eps = 1E-7 + if abs(a.real - b[0]) > eps or abs(a.imag - b[1]) > eps: + self.fail((a ,b)) + + def test_rect(self): + self.assertCEqual(rect(0, 0), (0, 0)) + self.assertCEqual(rect(1, 0), (1., 0)) + self.assertCEqual(rect(1, -pi), (-1., 0)) + self.assertCEqual(rect(1, pi/2), (0, 1.)) + self.assertCEqual(rect(1, -pi/2), (0, -1.)) + + def test_main(): run_unittest(CMathTests) Modified: python/branches/trunk-math/Lib/test/test_complex.py ============================================================================== --- python/branches/trunk-math/Lib/test/test_complex.py (original) +++ python/branches/trunk-math/Lib/test/test_complex.py Tue Jan 29 14:07:21 2008 @@ -359,30 +359,6 @@ except (OSError, IOError): pass - def assertCISEqual(self, a, b): - eps = 1E-7 - if abs(a[0] - b[0]) > eps or abs(a[1] - b[1]) > eps: - self.fail((a ,b)) - - def test_as_cis(self): - self.assertCISEqual(complex().as_cis(), (0., 0.)) - self.assertCISEqual(complex(1.).as_cis(), (1., 0.)) - self.assertCISEqual(complex(-1.).as_cis(), (1., pi)) - self.assertCISEqual(complex(0., 1).as_cis(), (1., pi/2)) - self.assertCISEqual(complex(0., -1).as_cis(), (1., -pi/2)) - - def assertCEqual(self, a, b): - eps = 1E-7 - if abs(a.real - b[0]) > eps or abs(a.imag - b[1]) > eps: - self.fail((a ,b)) - - def test_from_cis(self): - self.assertCEqual(complex.from_cis(0, 0), (0, 0)) - self.assertCEqual(complex.from_cis(1, 0), (1., 0)) - self.assertCEqual(complex.from_cis(1, -pi), (-1., 0)) - self.assertCEqual(complex.from_cis(1, pi/2), (0, 1.)) - self.assertCEqual(complex.from_cis(1, -pi/2), (0, -1.)) - def test_main(): test_support.run_unittest(ComplexTest) Modified: python/branches/trunk-math/Misc/NEWS ============================================================================== --- python/branches/trunk-math/Misc/NEWS (original) +++ python/branches/trunk-math/Misc/NEWS Tue Jan 29 14:07:21 2008 @@ -12,9 +12,8 @@ Core and builtins ----------------- -- Added ``from_cis`` constructor to the ``complex`` type to create a complex - from a polar or exp notation. The new method ``as_cis`` returns radius *r* - and angle *phi* of a complex. +- Added arg(z) -> phi, polar(z) -> r, phi and rect(r, phi) -> z to the cmath + module. - Issue #XXXX: Four new methods were added to the math and cmath modules: acosh, asinh, atanh and log1p. Replacement implementations for platforms Modified: python/branches/trunk-math/Modules/cmathmodule.c ============================================================================== --- python/branches/trunk-math/Modules/cmathmodule.c (original) +++ python/branches/trunk-math/Modules/cmathmodule.c Tue Jan 29 14:07:21 2008 @@ -33,8 +33,6 @@ #define CM_SCALE_UP 2*(DBL_MANT_DIG/2) + 1 #define CM_SCALE_DOWN -(DBL_MANT_DIG/2 + 1) - - /* forward declarations */ static Py_complex c_asinh(Py_complex); static Py_complex c_atanh(Py_complex); @@ -609,6 +607,75 @@ FUNC1(cmath_tan, c_tan) FUNC1(cmath_tanh, c_tanh) +static PyObject * +cmath_arg(PyObject *self, PyObject *args) +{ + Py_complex z; + double phi; + if (!PyArg_ParseTuple(args, "D:arg", &z)) + return NULL; + errno = 0; + PyFPE_START_PROTECT("arg function", return 0) + phi = atan2(z.imag, z.real); + PyFPE_END_PROTECT(r) + if (errno != 0) + return math_error(); + else + return PyFloat_FromDouble(phi); +} + +PyDoc_STRVAR(cmath_arg_doc, +"arg(z) -> float\n\n\ +Return argument, also known as the phase angle, of a complex."); + +static PyObject * +cmath_polar(PyObject *self, PyObject *args) +{ + Py_complex z; + double r, phi; + if (!PyArg_ParseTuple(args, "D:polar", &z)) + return NULL; + errno = 0; + PyFPE_START_PROTECT("polar function", return 0) + r = hypot(z.real, z.imag); + phi = atan2(z.imag, z.real); + PyFPE_END_PROTECT(r) + if (errno != 0) + return math_error(); + else + return Py_BuildValue("dd", r, phi); +} + +PyDoc_STRVAR(cmath_polar_doc, +"polar(z) -> r: float, phi: float\n\n\ +Convert a complex from rectangular coordinates to polar coordinates. r is\n\ +the distance from 0 and phi the phase angle."); + +static PyObject * +cmath_rect(PyObject *self, PyObject *args) +{ + Py_complex z; + double r, phi; + if (!PyArg_ParseTuple(args, "dd:rect", &r, &phi)) + return NULL; + errno = 0; + if (r < 0.) { + errno = EDOM; + return math_error(); + } + PyFPE_START_PROTECT("rect function", return 0) + z.real = r * cos(phi); + z.imag = r * sin(phi); + PyFPE_END_PROTECT(z) + if (errno != 0) + return math_error(); + else + return PyComplex_FromCComplex(z); +} + +PyDoc_STRVAR(cmath_rect_doc, +"rect(r, phi) -> z: complex\n\n\ +Convert from polar coordinates to rectangular coordinates."); PyDoc_STRVAR(module_doc, "This module is always available. It provides access to mathematical\n" @@ -617,6 +684,7 @@ static PyMethodDef cmath_methods[] = { {"acos", cmath_acos, METH_VARARGS, c_acos_doc}, {"acosh", cmath_acosh, METH_VARARGS, c_acosh_doc}, + {"arg", cmath_arg, METH_VARARGS, cmath_arg_doc}, {"asin", cmath_asin, METH_VARARGS, c_asin_doc}, {"asinh", cmath_asinh, METH_VARARGS, c_asinh_doc}, {"atan", cmath_atan, METH_VARARGS, c_atan_doc}, @@ -626,6 +694,8 @@ {"exp", cmath_exp, METH_VARARGS, c_exp_doc}, {"log", cmath_log, METH_VARARGS, cmath_log_doc}, {"log10", cmath_log10, METH_VARARGS, c_log10_doc}, + {"polar", cmath_polar, METH_VARARGS, cmath_polar_doc}, + {"rect", cmath_rect, METH_VARARGS, cmath_rect_doc}, {"sin", cmath_sin, METH_VARARGS, c_sin_doc}, {"sinh", cmath_sinh, METH_VARARGS, c_sinh_doc}, {"sqrt", cmath_sqrt, METH_VARARGS, c_sqrt_doc}, Modified: python/branches/trunk-math/Objects/complexobject.c ============================================================================== --- python/branches/trunk-math/Objects/complexobject.c (original) +++ python/branches/trunk-math/Objects/complexobject.c Tue Jan 29 14:07:21 2008 @@ -183,31 +183,6 @@ } -static Py_complex -c_from_cis(float r, float phi) -{ - Py_complex cn; - - if (r <= 0.) { - if (r != 0.) { - errno = EDOM; - } - cn.real = cn.imag = 0.; - return cn; - } - - cn.real = r * cos(phi); - cn.imag = r * sin(phi); - return cn; -} - -static void -c_as_cis(Py_complex cn, float *r, float *phi) -{ - *r = hypot(cn.real, cn.imag); - *phi = atan2(cn.imag, cn.real); -} - static PyObject * complex_subtype_from_c_complex(PyTypeObject *type, Py_complex cval) { @@ -773,62 +748,9 @@ return Py_BuildValue("(D)", &v->cval); } -static PyObject * -complex_from_cis(PyObject *ignored, PyObject *args) -{ - Py_complex c; - float r, phi; - - if (!PyArg_ParseTuple(args, "ff:fromcis", &r, &phi)) - return NULL; - - PyFPE_START_PROTECT("complex_from_cis", return NULL) - errno = 0; - c = c_from_cis(r, phi); - PyFPE_END_PROTECT(r) - Py_ADJUST_ERANGE2(c.real, c.imag); - if (errno == EDOM) { - PyErr_SetString(PyExc_ValueError, - "r must not be negative"); - return NULL; - } - return PyComplex_FromCComplex(c); -} - -PyDoc_STRVAR(complex_from_cis_doc, -"complex.from_cis(r, phi) -> complex\n" -"\n" -"Creates a complex number from the polar form r * (cos(phi) + j * sin(phi))" -"or exponential form r * exp(j * phi)"); - -static PyObject * -complex_as_cis(PyObject *self) -{ - Py_complex c; - float r, phi; - - c = ((PyComplexObject *)self)->cval; - PyFPE_START_PROTECT("complex_as_cis", return NULL) - errno = 0; - c_as_cis(c, &r, &phi); - PyFPE_END_PROTECT(r) - return Py_BuildValue("ff", r, phi); -} - -PyDoc_STRVAR(complex_as_cis_doc, -"complex.as_cis() -> r, phi\n" -"\n" -"Converts a complex number to the polar form r * (cos(phi) + j * sin(phi))" -"or exponential form r * exp(j * phi)"); - - static PyMethodDef complex_methods[] = { - {"as_cis", (PyCFunction)complex_as_cis, METH_NOARGS, - complex_as_cis_doc}, {"conjugate", (PyCFunction)complex_conjugate, METH_NOARGS, complex_conjugate_doc}, - {"from_cis", (PyCFunction)complex_from_cis, - METH_VARARGS | METH_STATIC, complex_from_cis_doc}, {"__getnewargs__", (PyCFunction)complex_getnewargs, METH_NOARGS}, {NULL, NULL} /* sentinel */ }; From buildbot at python.org Tue Jan 29 14:13:41 2008 From: buildbot at python.org (buildbot at python.org) Date: Tue, 29 Jan 2008 13:13:41 +0000 Subject: [Python-checkins] buildbot failure in alpha Tru64 5.1 3.0 Message-ID: <20080129131341.916181E4003@bag.python.org> The Buildbot has detected a new failure of alpha Tru64 5.1 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/alpha%20Tru64%205.1%203.0/builds/584 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-tru64 Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: sincerely, -The Buildbot From python-checkins at python.org Tue Jan 29 14:58:01 2008 From: python-checkins at python.org (barry.warsaw) Date: Tue, 29 Jan 2008 14:58:01 +0100 (CET) Subject: [Python-checkins] r60410 - sandbox/trunk/emailpkg/2_5/email Message-ID: <20080129135801.88BE71E4004@bag.python.org> Author: barry.warsaw Date: Tue Jan 29 14:58:01 2008 New Revision: 60410 Added: sandbox/trunk/emailpkg/2_5/email/ - copied from r60409, python/branches/release23-maint/Lib/email/ Log: In order to support security-only releases on the Python 2.3 branch, svn copy the email 2.5 tree into the sandbox. This replaces the svn:external'ing in of the directory and diverges the branches. It means that any security changes for email 2.5 must be committed to both places. From python-checkins at python.org Tue Jan 29 14:59:36 2008 From: python-checkins at python.org (barry.warsaw) Date: Tue, 29 Jan 2008 14:59:36 +0100 (CET) Subject: [Python-checkins] r60411 - sandbox/trunk/emailpkg/2_5 Message-ID: <20080129135936.C23121E401A@bag.python.org> Author: barry.warsaw Date: Tue Jan 29 14:59:36 2008 New Revision: 60411 Modified: sandbox/trunk/emailpkg/2_5/ (props changed) Log: Remove the svn:external. From python-checkins at python.org Tue Jan 29 15:08:44 2008 From: python-checkins at python.org (barry.warsaw) Date: Tue, 29 Jan 2008 15:08:44 +0100 (CET) Subject: [Python-checkins] r60412 - sandbox/trunk/emailpkg/3_0/email Message-ID: <20080129140844.1AAE91E4003@bag.python.org> Author: barry.warsaw Date: Tue Jan 29 15:08:38 2008 New Revision: 60412 Added: sandbox/trunk/emailpkg/3_0/email/ - copied from r60411, python/branches/release24-maint/Lib/email/ Log: As with email 2.5, svn copy Python 2.4's email package 3.0 to here so that Python security releases can be separated from email package maintenance. This means any email 3.0 security patches must be applied to both locations. From python-checkins at python.org Tue Jan 29 15:14:23 2008 From: python-checkins at python.org (barry.warsaw) Date: Tue, 29 Jan 2008 15:14:23 +0100 (CET) Subject: [Python-checkins] r60413 - sandbox/trunk/emailpkg/3_0 Message-ID: <20080129141423.3F05A1E4003@bag.python.org> Author: barry.warsaw Date: Tue Jan 29 15:14:23 2008 New Revision: 60413 Modified: sandbox/trunk/emailpkg/3_0/ (props changed) Log: Remove the svn:externals definition. From python-checkins at python.org Tue Jan 29 16:16:45 2008 From: python-checkins at python.org (christian.heimes) Date: Tue, 29 Jan 2008 16:16:45 +0100 (CET) Subject: [Python-checkins] r60414 - in python/branches/trunk-math: Include/pymath.h Modules/mathmodule.c Objects/floatobject.c Message-ID: <20080129151645.CB0A01E4004@bag.python.org> Author: christian.heimes Date: Tue Jan 29 16:16:45 2008 New Revision: 60414 Modified: python/branches/trunk-math/Include/pymath.h python/branches/trunk-math/Modules/mathmodule.c python/branches/trunk-math/Objects/floatobject.c Log: Move all external and math related declarations into pymath.h Modified: python/branches/trunk-math/Include/pymath.h ============================================================================== --- python/branches/trunk-math/Include/pymath.h (original) +++ python/branches/trunk-math/Include/pymath.h Tue Jan 29 16:16:45 2008 @@ -49,9 +49,16 @@ extern double frexp (double, int *); extern double ldexp (double, int); extern double modf (double, double *); +extern double pow(double, double); #endif /* __STDC__ */ #endif /* _MSC_VER */ +#ifdef _OSF_SOURCE +/* OSF1 5.1 doesn't make these available with XOPEN_SOURCE_EXTENDED defined */ +extern int finite(double); +extern double copysign(double, double); +#endif + /* High precision defintion of pi and e (Euler) * The values are taken from libc6's math.h. */ Modified: python/branches/trunk-math/Modules/mathmodule.c ============================================================================== --- python/branches/trunk-math/Modules/mathmodule.c (original) +++ python/branches/trunk-math/Modules/mathmodule.c Tue Jan 29 16:16:45 2008 @@ -55,11 +55,6 @@ #include "Python.h" #include "longintrepr.h" /* just for SHIFT */ -#ifdef _OSF_SOURCE -/* OSF1 5.1 doesn't make this available with XOPEN_SOURCE_EXTENDED defined */ -extern double copysign(double, double); -#endif - /* Call is_error when errno != 0, and where x is the result libm * returned. is_error will usually set up an exception and return * true (1), but may return false (0) without setting up an exception. Modified: python/branches/trunk-math/Objects/floatobject.c ============================================================================== --- python/branches/trunk-math/Objects/floatobject.c (original) +++ python/branches/trunk-math/Objects/floatobject.c Tue Jan 29 16:16:45 2008 @@ -10,17 +10,6 @@ #include #include - -#if !defined(__STDC__) -extern double fmod(double, double); -extern double pow(double, double); -#endif - -#ifdef _OSF_SOURCE -/* OSF1 5.1 doesn't make this available with XOPEN_SOURCE_EXTENDED defined */ -extern int finite(double); -#endif - /* Special free list -- see comments for same code in intobject.c. */ #define BLOCK_SIZE 1000 /* 1K less typical malloc overhead */ #define BHEAD_SIZE 8 /* Enough for a 64-bit pointer */ From python-checkins at python.org Tue Jan 29 16:17:43 2008 From: python-checkins at python.org (christian.heimes) Date: Tue, 29 Jan 2008 16:17:43 +0100 (CET) Subject: [Python-checkins] r60415 - in python/branches/trunk-math: Doc/library/cmath.rst Lib/test/test_cmath.py Modules/cmathmodule.c Message-ID: <20080129151743.CF56E1E4004@bag.python.org> Author: christian.heimes Date: Tue Jan 29 16:17:43 2008 New Revision: 60415 Modified: python/branches/trunk-math/Doc/library/cmath.rst python/branches/trunk-math/Lib/test/test_cmath.py python/branches/trunk-math/Modules/cmathmodule.c Log: Added complex isinf and isnan Modified: python/branches/trunk-math/Doc/library/cmath.rst ============================================================================== --- python/branches/trunk-math/Doc/library/cmath.rst (original) +++ python/branches/trunk-math/Doc/library/cmath.rst Tue Jan 29 16:17:43 2008 @@ -99,6 +99,16 @@ Return the exponential value ``e**x``. +.. function:: isinf(x) + + .. versionadded:: 2.6 + + +.. function:: isnan(x) + + .. versionadded:: 2.6 + + .. function:: log(x[, base]) Returns the logarithm of *x* to the given *base*. If the *base* is not Modified: python/branches/trunk-math/Lib/test/test_cmath.py ============================================================================== --- python/branches/trunk-math/Lib/test/test_cmath.py (original) +++ python/branches/trunk-math/Lib/test/test_cmath.py Tue Jan 29 16:17:43 2008 @@ -5,6 +5,9 @@ import cmath, math from cmath import arg, polar, rect, pi +INF = float('inf') +NAN = float('nan') + class CMathTests(unittest.TestCase): # list of all functions in cmath test_functions = [getattr(cmath, fname) for fname in [ @@ -256,6 +259,28 @@ self.assertCEqual(rect(1, pi/2), (0, 1.)) self.assertCEqual(rect(1, -pi/2), (0, -1.)) + def test_isnan(self): + self.failIf(cmath.isnan(1)) + self.failIf(cmath.isnan(1j)) + self.failIf(cmath.isnan(INF)) + self.assert_(cmath.isnan(NAN)) + self.assert_(cmath.isnan(complex(NAN, 0))) + self.assert_(cmath.isnan(complex(0, NAN))) + self.assert_(cmath.isnan(complex(NAN, NAN))) + self.assert_(cmath.isnan(complex(NAN, INF))) + self.assert_(cmath.isnan(complex(INF, NAN))) + + def test_isinf(self): + self.failIf(cmath.isinf(1)) + self.failIf(cmath.isinf(1j)) + self.failIf(cmath.isinf(NAN)) + self.assert_(cmath.isinf(INF)) + self.assert_(cmath.isinf(complex(INF, 0))) + self.assert_(cmath.isinf(complex(0, INF))) + self.assert_(cmath.isinf(complex(INF, INF))) + self.assert_(cmath.isinf(complex(NAN, INF))) + self.assert_(cmath.isinf(complex(INF, NAN))) + def test_main(): run_unittest(CMathTests) Modified: python/branches/trunk-math/Modules/cmathmodule.c ============================================================================== --- python/branches/trunk-math/Modules/cmathmodule.c (original) +++ python/branches/trunk-math/Modules/cmathmodule.c Tue Jan 29 16:17:43 2008 @@ -677,6 +677,34 @@ "rect(r, phi) -> z: complex\n\n\ Convert from polar coordinates to rectangular coordinates."); +static PyObject * +cmath_isnan(PyObject *self, PyObject *args) +{ + Py_complex z; + if (!PyArg_ParseTuple(args, "D:isnan", &z)) + return NULL; + return PyBool_FromLong(Py_IS_NAN(z.real) || Py_IS_NAN(z.imag)); +} + +PyDoc_STRVAR(cmath_isnan_doc, +"isnan(z) -> bool\n\ +Checks if the real or imaginary part of z not a number (NaN)"); + +static PyObject * +cmath_isinf(PyObject *self, PyObject *args) +{ + Py_complex z; + if (!PyArg_ParseTuple(args, "D:isnan", &z)) + return NULL; + return PyBool_FromLong(Py_IS_INFINITY(z.real) || + Py_IS_INFINITY(z.imag)); +} + +PyDoc_STRVAR(cmath_isinf_doc, +"isinf(z) -> bool\n\ +Checks if the real or imaginary part of z is infinite."); + + PyDoc_STRVAR(module_doc, "This module is always available. It provides access to mathematical\n" "functions for complex numbers."); @@ -692,6 +720,8 @@ {"cos", cmath_cos, METH_VARARGS, c_cos_doc}, {"cosh", cmath_cosh, METH_VARARGS, c_cosh_doc}, {"exp", cmath_exp, METH_VARARGS, c_exp_doc}, + {"isinf", cmath_isinf, METH_VARARGS, cmath_isinf_doc}, + {"isnan", cmath_isnan, METH_VARARGS, cmath_isnan_doc}, {"log", cmath_log, METH_VARARGS, cmath_log_doc}, {"log10", cmath_log10, METH_VARARGS, c_log10_doc}, {"polar", cmath_polar, METH_VARARGS, cmath_polar_doc}, From ncoghlan at gmail.com Tue Jan 29 16:48:18 2008 From: ncoghlan at gmail.com (Nick Coghlan) Date: Wed, 30 Jan 2008 01:48:18 +1000 Subject: [Python-checkins] r60409 - in python/branches/trunk-math: Doc/library/cmath.rst Doc/library/stdtypes.rst Lib/test/test_cmath.py Lib/test/test_complex.py Misc/NEWS Modules/cmathmodule.c Objects/complexobject.c In-Reply-To: <20080129130722.02AF31E401E@bag.python.org> References: <20080129130722.02AF31E401E@bag.python.org> Message-ID: <479F4AC2.2020401@gmail.com> christian.heimes wrote: +.. function:: polar(x) > + > + Convert a complex from rectangular coordinates to polar coordinates. r is > + the distance from 0 and phi the phase angle. This doesn't make it clear to me that the function returns a 2-tuple. Something like "Determines the polar coordinates (r, phi) from the rectangular coordinates given by the complex number x. r is ..." might be clearer. > +.. function:: rect(r, phi) > + > + Convert from polar coordinates to rectangular coordinates. Similar to the above comment, this wording doesn't make it clear to me that the result is a complex number rather than an (x, y) 2-tuple. Perhaps the phrase "expressed as a complex number" could be added to the end of the sentence? Cheers, Nick. -- Nick Coghlan | ncoghlan at gmail.com | Brisbane, Australia --------------------------------------------------------------- http://www.boredomandlaziness.org From python-checkins at python.org Tue Jan 29 16:50:31 2008 From: python-checkins at python.org (mark.dickinson) Date: Tue, 29 Jan 2008 16:50:31 +0100 (CET) Subject: [Python-checkins] r60416 - python/branches/trunk-math/Modules/mathmodule.c Message-ID: <20080129155031.519D81E4022@bag.python.org> Author: mark.dickinson Date: Tue Jan 29 16:50:30 2008 New Revision: 60416 Modified: python/branches/trunk-math/Modules/mathmodule.c Log: General clean up of math_ wrappers; revised and expanded comments for math_1 and math_2, reworking of math_2 to force it to make the libm call first and do the error analysis afterwards, and put copysign and hypot back under the control of math_2. Modified: python/branches/trunk-math/Modules/mathmodule.c ============================================================================== --- python/branches/trunk-math/Modules/mathmodule.c (original) +++ python/branches/trunk-math/Modules/mathmodule.c Tue Jan 29 16:50:30 2008 @@ -90,28 +90,29 @@ return result; } -/* In math_1, the following rules are used to try to ensure that - functions raise the correct exceptions both on ANSI C platforms and - on C99 platforms: - - (1) Whenever a non-NaN argument gives a NaN result, set errno = EDOM - to force Python to raise a ValueError. - - (2) Whenever a finite argument gives an infinite result, set errno - to either EDOM or ERANGE to force Python to raise ValueError or - OverflowError respectively. The "can_overflow" argument should be - set to 1 for functions which might overflow but never raise - "divide-by-zero", and 0 for functions that never overflow. - Fortunately, none of the single-argument functions currently - implemented can raise both "divide-by-zero" *and* "overflow". - - (3) If neither of the above occurred but errno was set by the libm - function (this can happen in cases where Py_HUGE_VAL is not an - infinity) then raise OverflowError if errno==ERANGE and the result - was nonzero, do nothing if errno==ERANGE and the result was zero - (this can happen on underflow under ANSI C), and raise ValueError - if errno==EDOM. - +/* + math_1 is used to wrap a libm function f that takes a double + arguments and returns a double. + + The error reporting follows these rules, which are designed to do the right thing + on C89/C99 platforms and IEEE 754/non IEEE 754 platforms. + + - a NaN result from non-NaN inputs causes ValueError to be raised + - an infinite result from finite inputs causes OverflowError to be raised if can_overflow is 1, + or raises ValueError if can_overflow is 0. + - if the result is finite and errno == EDOM then ValueError is raised + - if the result is finite and nonzero and errno == ERANGE then OverflowError is raised + + The last rule is used to catch overflow on platforms which follow C89 + but for which HUGE_VAL is not an infinity. + + For the majority of one-argument functions these rules are enough to ensure + that Python's functions behave as specified in 'Annex F' of the C99 + standard, with the 'invalid' and 'divide-by-zero' floating-point exceptions + mapping to Python's ValueError and the 'overflow' floating-point exception + mapping to OverflowError. math_1 only works for functions that don't have + singularities *and* the possibility of overflow; fortunately, that covers + everything we care about right now. */ static PyObject * @@ -125,43 +126,77 @@ PyFPE_START_PROTECT("in math_1", return 0); r = (*func)(x); PyFPE_END_PROTECT(r); - if (!Py_IS_NAN(x) && Py_IS_NAN(r)) - errno = EDOM; - if (Py_IS_FINITE(x) && Py_IS_INFINITY(r)) - errno = can_overflow ? ERANGE : EDOM; + if (Py_IS_NAN(r)) { + if (!Py_IS_NAN(x)) + errno = EDOM; + else + errno = 0; + } + else if (Py_IS_INFINITY(r)) { + if (Py_IS_FINITE(x)) + errno = can_overflow ? ERANGE : EDOM; + else + errno = 0; + } if (errno && is_error(r)) return NULL; else return PyFloat_FromDouble(r); } +/* + math_2 is used to wrap a libm function f that takes two double + arguments and returns a double. + + The error reporting follows these rules, which are designed to do the right thing + on C89/C99 platforms and IEEE 754/non IEEE 754 platforms. + + - a NaN result from non-NaN inputs causes ValueError to be raised + - an infinite result from finite inputs causes OverflowError to be raised. + - if the result is finite and errno == EDOM then ValueError is raised + - if the result is finite and nonzero and errno == ERANGE then OverflowError is raised + + The last rule is used to catch overflow on platforms which follow C89 + but for which HUGE_VAL is not an infinity. + + For most two-argument functions (copysign, fmod, hypot, atan2) these rules + are enough to ensure that Python's functions behave as specified in 'Annex + F' of the C99 standard, with the 'invalid' and 'divide-by-zero' + floating-point exceptions mapping to Python's ValueError and the 'overflow' + floating-point exception mapping to OverflowError. +*/ + static PyObject * math_2(PyObject *args, double (*func) (double, double), char *funcname) { PyObject *ox, *oy; - double x, y; + double x, y, r; if (! PyArg_UnpackTuple(args, funcname, 2, 2, &ox, &oy)) return NULL; x = PyFloat_AsDouble(ox); y = PyFloat_AsDouble(oy); if ((x == -1.0 || y == -1.0) && PyErr_Occurred()) return NULL; - if (Py_IS_NAN(x)) - return PyFloat_FromDouble(x); - if (Py_IS_NAN(y)) - return PyFloat_FromDouble(y); errno = 0; PyFPE_START_PROTECT("in math_2", return 0); - x = (*func)(x, y); - PyFPE_END_PROTECT(x); - - if (Py_IS_NAN(x)) - errno = EDOM; - - if (errno && is_error(x)) + r = (*func)(x, y); + PyFPE_END_PROTECT(r); + if (Py_IS_NAN(r)) { + if (!Py_IS_NAN(x) && !Py_IS_NAN(y)) + errno = EDOM; + else + errno = 0; + } + else if (Py_IS_INFINITY(r)) { + if (Py_IS_FINITE(x) && Py_IS_FINITE(y)) + errno = ERANGE; + else + errno = 0; + } + if (errno && is_error(r)) return NULL; else - return PyFloat_FromDouble(x); + return PyFloat_FromDouble(r); } #define FUNC1(funcname, func, can_overflow, docstring) \ @@ -194,6 +229,8 @@ FUNC1(ceil, ceil, 0, "ceil(x)\n\nReturn the ceiling of x as a float.\n" "This is the smallest integral value >= x.") +FUNC2(copysign, copysign, + "copysign(x,y)\n\nReturn x with the sign of y.") FUNC1(cos, cos, 0, "cos(x)\n\nReturn the cosine of x (measured in radians).") FUNC1(cosh, cosh, 1, @@ -208,6 +245,8 @@ FUNC2(fmod, fmod, "fmod(x,y)\n\nReturn fmod(x, y), according to platform C." " x % y may differ.") +FUNC2(hypot, hypot, + "hypot(x,y)\n\nReturn the Euclidean distance, sqrt(x*x + y*y).") FUNC1(sin, sin, 0, "sin(x)\n\nReturn the sine of x (measured in radians).") FUNC1(sinh, sinh, 1, @@ -392,48 +431,17 @@ PyDoc_STRVAR(math_log10_doc, "log10(x) -> the base 10 logarithm of x."); -/* copysign can't use math_2, since it doesn't follow the general rules for - NaNs (i.e., it's not true that copysign(x, y) is NaN whenever x or y is a - NaN.) */ - -static PyObject * -math_copysign(PyObject *self, PyObject *args) -{ - PyObject *ox, *oy; - double x, y; - - if (! PyArg_UnpackTuple(args, "copysign", 2, 2, &ox, &oy)) - return NULL; - x = PyFloat_AsDouble(ox); - y = PyFloat_AsDouble(oy); - if ((x == -1.0 || y == -1.0) && PyErr_Occurred()) - return NULL; - - errno = 0; - /* copysign shouldn't raise any floating-point - exception, but better to be safe than sorry */ - PyFPE_START_PROTECT("in math_copysign", return 0); - x = copysign(x, y); - PyFPE_END_PROTECT(x); - - if (errno && is_error(x)) - /* if errno is set then something unexpected happened. Better - to raise a Python exception than to return a possibly - incorrect value in this case. */ - return NULL; - else - return PyFloat_FromDouble(x); -} - -PyDoc_STRVAR(math_copysign_doc, - "copysign(x,y)\n\nReturn x with the sign of y."); +/* pow can't use math_2, but needs its own wrapper: the problem is that an + infinite result can arise either as a result of overflow (in which case + OverflowError should be raised) or as a result of e.g. 0.**-5. (for which + ValueError needs to be raised.) +*/ static PyObject * math_pow(PyObject *self, PyObject *args) { PyObject *ox, *oy; - double x, y; - int x_is_infinity, y_is_infinity; + double r, x, y; if (! PyArg_UnpackTuple(args, "pow", 2, 2, &ox, &oy)) return NULL; @@ -441,102 +449,49 @@ y = PyFloat_AsDouble(oy); if ((x == -1.0 || y == -1.0) && PyErr_Occurred()) return NULL; - - /* 1**x and x**0 return 1., even if x is a NaN or infinity */ + /* 1**x and x**0 return 1., even if x is a NaN or infinity. It may be + necessary to uncomment the following two lines on Windows. if (x == 1.0 || y == 0.0) - return PyFloat_FromDouble(1.); - - /* with the above two exceptions out of the way, usual rules for NaNs - apply: if either x or y is a NaN then NaN should be returned. */ - if (Py_IS_NAN(x)) - return PyFloat_FromDouble(x); - if (Py_IS_NAN(y)) - return PyFloat_FromDouble(y); - - x_is_infinity = Py_IS_INFINITY(x); - y_is_infinity = Py_IS_INFINITY(y); - - /* 0 ** negative should give a divide-by-zero exception according - to IEEE-754; we want errno = EDOM here to get a ValueError. - Note: for 0.0 ** positive we let the libm routine take care of - evaluation, to give maximum chance of getting the sign of the result - correct. (e.g. (-0.0)**27 should be -0.0.) */ - if (x == 0.0 && y < 0.0) { - errno = EDOM; - is_error(x); - return NULL; - } - - /* Finally, call the libm pow. */ + return PyFloat_FromDouble(1.); */ errno = 0; PyFPE_START_PROTECT("in math_pow", return 0); - x = pow(x, y); - PyFPE_END_PROTECT(x); + r = pow(x, y); + PyFPE_END_PROTECT(r); + if (Py_IS_NAN(r)) { + if (!Py_IS_NAN(x) && !Py_IS_NAN(y)) + errno = EDOM; + else + errno = 0; + } + /* an infinite result arises either from: - /* a NaN at this point should result in ValueError being raised */ - if (Py_IS_NAN(x)) - errno = EDOM; - - /* if neither x nor y was infinity, then an infinite result here - indicates overflow. */ - if (!x_is_infinity && !y_is_infinity && Py_IS_INFINITY(x)) - errno = ERANGE; + (A) (+/-0.)**negative, + (B) overflow of x**y with both x and y finite (and x nonzero) + (C) (+/-inf)**positive, or + (D) x**inf with |x| > 1, or x**-inf with |x| < 1. + + In case (A) we want ValueError to be raised. In case (B) + OverflowError should be raised. In cases (C) and (D) the infinite + result should be returned. + */ + else if (Py_IS_INFINITY(r)) { + if (x == 0.) + errno = EDOM; + else if (Py_IS_FINITE(x) && Py_IS_FINITE(y)) + errno = ERANGE; + else + errno = 0; + } - if (errno && is_error(x)) + if (errno && is_error(r)) return NULL; else - return PyFloat_FromDouble(x); + return PyFloat_FromDouble(r); } PyDoc_STRVAR(math_pow_doc, "pow(x,y)\n\nReturn x**y (x to the power of y)."); -static PyObject * -math_hypot(PyObject *self, PyObject *args) -{ - PyObject *ox, *oy; - double x, y; - int x_is_infinity, y_is_infinity; - - if (! PyArg_UnpackTuple(args, "hypot", 2, 2, &ox, &oy)) - return NULL; - x = PyFloat_AsDouble(ox); - y = PyFloat_AsDouble(oy); - if ((x == -1.0 || y == -1.0) && PyErr_Occurred()) - return NULL; - - /* hypot (+/-infinity, x) returns infinity, even if x is a NaN */ - if (Py_IS_INFINITY(x) || Py_IS_INFINITY(y)) - return PyFloat_FromDouble(Py_HUGE_VAL); - - /* Now the usual rules apply: if either argument is a NaN, return NaN */ - if (Py_IS_NAN(x)) - return PyFloat_FromDouble(x); - if (Py_IS_NAN(y)) - return PyFloat_FromDouble(y); - - x_is_infinity = Py_IS_INFINITY(x); - y_is_infinity = Py_IS_INFINITY(y); - - errno = 0; - PyFPE_START_PROTECT("in math_hypot", return 0); - x = hypot(x, y); - PyFPE_END_PROTECT(x); - - /* we can get an infinity here either as an exact result, or - as a result of overflow */ - if (!x_is_infinity && !y_is_infinity && Py_IS_INFINITY(x)) - errno = ERANGE; - - if (errno && is_error(x)) - return NULL; - else - return PyFloat_FromDouble(x); -} - -PyDoc_STRVAR(math_hypot_doc, - "hypot(x,y)\n\nReturn the Euclidean distance, sqrt(x*x + y*y)."); - static const double degToRad = Py_MATH_PI / 180.0; static const double radToDeg = 180.0 / Py_MATH_PI; From python-checkins at python.org Tue Jan 29 16:58:42 2008 From: python-checkins at python.org (mark.dickinson) Date: Tue, 29 Jan 2008 16:58:42 +0100 (CET) Subject: [Python-checkins] r60417 - python/branches/trunk-math/Modules/mathmodule.c Message-ID: <20080129155842.AE44D1E4004@bag.python.org> Author: mark.dickinson Date: Tue Jan 29 16:58:42 2008 New Revision: 60417 Modified: python/branches/trunk-math/Modules/mathmodule.c Log: Some comment lines exceeded the 80-character limit Modified: python/branches/trunk-math/Modules/mathmodule.c ============================================================================== --- python/branches/trunk-math/Modules/mathmodule.c (original) +++ python/branches/trunk-math/Modules/mathmodule.c Tue Jan 29 16:58:42 2008 @@ -94,25 +94,30 @@ math_1 is used to wrap a libm function f that takes a double arguments and returns a double. - The error reporting follows these rules, which are designed to do the right thing - on C89/C99 platforms and IEEE 754/non IEEE 754 platforms. + The error reporting follows these rules, which are designed to do + the right thing on C89/C99 platforms and IEEE 754/non IEEE 754 + platforms. - a NaN result from non-NaN inputs causes ValueError to be raised - - an infinite result from finite inputs causes OverflowError to be raised if can_overflow is 1, - or raises ValueError if can_overflow is 0. - - if the result is finite and errno == EDOM then ValueError is raised - - if the result is finite and nonzero and errno == ERANGE then OverflowError is raised - - The last rule is used to catch overflow on platforms which follow C89 - but for which HUGE_VAL is not an infinity. - - For the majority of one-argument functions these rules are enough to ensure - that Python's functions behave as specified in 'Annex F' of the C99 - standard, with the 'invalid' and 'divide-by-zero' floating-point exceptions - mapping to Python's ValueError and the 'overflow' floating-point exception - mapping to OverflowError. math_1 only works for functions that don't have - singularities *and* the possibility of overflow; fortunately, that covers - everything we care about right now. + - an infinite result from finite inputs causes OverflowError to be + raised if can_overflow is 1, or raises ValueError if can_overflow + is 0. + - if the result is finite and errno == EDOM then ValueError is + raised + - if the result is finite and nonzero and errno == ERANGE then + OverflowError is raised + + The last rule is used to catch overflow on platforms which follow + C89 but for which HUGE_VAL is not an infinity. + + For the majority of one-argument functions these rules are enough + to ensure that Python's functions behave as specified in 'Annex F' + of the C99 standard, with the 'invalid' and 'divide-by-zero' + floating-point exceptions mapping to Python's ValueError and the + 'overflow' floating-point exception mapping to OverflowError. + math_1 only works for functions that don't have singularities *and* + the possibility of overflow; fortunately, that covers everything we + care about right now. */ static PyObject * @@ -148,22 +153,27 @@ math_2 is used to wrap a libm function f that takes two double arguments and returns a double. - The error reporting follows these rules, which are designed to do the right thing - on C89/C99 platforms and IEEE 754/non IEEE 754 platforms. + The error reporting follows these rules, which are designed to do + the right thing on C89/C99 platforms and IEEE 754/non IEEE 754 + platforms. - a NaN result from non-NaN inputs causes ValueError to be raised - - an infinite result from finite inputs causes OverflowError to be raised. - - if the result is finite and errno == EDOM then ValueError is raised - - if the result is finite and nonzero and errno == ERANGE then OverflowError is raised - - The last rule is used to catch overflow on platforms which follow C89 - but for which HUGE_VAL is not an infinity. - - For most two-argument functions (copysign, fmod, hypot, atan2) these rules - are enough to ensure that Python's functions behave as specified in 'Annex - F' of the C99 standard, with the 'invalid' and 'divide-by-zero' - floating-point exceptions mapping to Python's ValueError and the 'overflow' - floating-point exception mapping to OverflowError. + - an infinite result from finite inputs causes OverflowError to be + raised. + - if the result is finite and errno == EDOM then ValueError is + raised + - if the result is finite and nonzero and errno == ERANGE then + OverflowError is raised + + The last rule is used to catch overflow on platforms which follow + C89 but for which HUGE_VAL is not an infinity. + + For most two-argument functions (copysign, fmod, hypot, atan2) + these rules are enough to ensure that Python's functions behave as + specified in 'Annex F' of the C99 standard, with the 'invalid' and + 'divide-by-zero' floating-point exceptions mapping to Python's + ValueError and the 'overflow' floating-point exception mapping to + OverflowError. */ static PyObject * @@ -431,10 +441,10 @@ PyDoc_STRVAR(math_log10_doc, "log10(x) -> the base 10 logarithm of x."); -/* pow can't use math_2, but needs its own wrapper: the problem is that an - infinite result can arise either as a result of overflow (in which case - OverflowError should be raised) or as a result of e.g. 0.**-5. (for which - ValueError needs to be raised.) +/* pow can't use math_2, but needs its own wrapper: the problem is + that an infinite result can arise either as a result of overflow + (in which case OverflowError should be raised) or as a result of + e.g. 0.**-5. (for which ValueError needs to be raised.) */ static PyObject * @@ -449,8 +459,9 @@ y = PyFloat_AsDouble(oy); if ((x == -1.0 || y == -1.0) && PyErr_Occurred()) return NULL; - /* 1**x and x**0 return 1., even if x is a NaN or infinity. It may be - necessary to uncomment the following two lines on Windows. + /* 1**x and x**0 return 1., even if x is a NaN or infinity. + It may be necessary to uncomment the following two lines on + Windows. if (x == 1.0 || y == 0.0) return PyFloat_FromDouble(1.); */ errno = 0; From python-checkins at python.org Tue Jan 29 17:18:09 2008 From: python-checkins at python.org (christian.heimes) Date: Tue, 29 Jan 2008 17:18:09 +0100 (CET) Subject: [Python-checkins] r60418 - in python/branches/trunk-math: Doc/library/math.rst Modules/mathmodule.c Message-ID: <20080129161809.59AF61E4004@bag.python.org> Author: christian.heimes Date: Tue Jan 29 17:18:09 2008 New Revision: 60418 Modified: python/branches/trunk-math/Doc/library/math.rst python/branches/trunk-math/Modules/mathmodule.c Log: Removed the optional base argument from log1p(). Modified: python/branches/trunk-math/Doc/library/math.rst ============================================================================== --- python/branches/trunk-math/Doc/library/math.rst (original) +++ python/branches/trunk-math/Doc/library/math.rst Tue Jan 29 17:18:09 2008 @@ -131,10 +131,9 @@ *base* argument added. -.. function:: log1p(x[, base]) +.. function:: log1p(x) - Return the logarithm of *1+x* to the given *base*. If the *base* is not specified, - return the natural logarithm of *1+x* (that is, the logarithm to base *e*). The + Return the natural logarithm of *1+x* (base *e*). The result is calculated in a way which is accurate for *x* near zero. .. versionadded:: 2.6 @@ -297,4 +296,3 @@ Module :mod:`cmath` Complex number versions of many of these functions. - Modified: python/branches/trunk-math/Modules/mathmodule.c ============================================================================== --- python/branches/trunk-math/Modules/mathmodule.c (original) +++ python/branches/trunk-math/Modules/mathmodule.c Tue Jan 29 17:18:09 2008 @@ -401,35 +401,13 @@ If the base not specified, returns the natural logarithm (base e) of x."); static PyObject * -math_log1p(PyObject *self, PyObject *args) +math_log1p(PyObject *self, PyObject *arg) { - PyObject *arg; - PyObject *base = NULL; - PyObject *num, *den; - PyObject *ans; - - if (!PyArg_UnpackTuple(args, "log1p", 1, 2, &arg, &base)) - return NULL; - - num = loghelper(arg, log1p, "log"); - if (num == NULL || base == NULL) - return num; - - den = loghelper(base, log1p, "log"); - if (den == NULL) { - Py_DECREF(num); - return NULL; - } - - ans = PyNumber_Divide(num, den); - Py_DECREF(num); - Py_DECREF(den); - return ans; + return loghelper(arg, log1p, "log1p"); } PyDoc_STRVAR(math_log1p_doc, -"log1p(x[, base]) -> the logarithm of 1+x to the given base.\n\ -If the base not specified, returns the natural logarithm (base e) of x.\n\ +"log1p(x) -> the natural logarithm of 1+x (base e).\n\ The result is computed in a way which is accurate for x near zero."); static PyObject * @@ -580,7 +558,7 @@ {"isnan", math_isnan, METH_O, math_isnan_doc}, {"ldexp", math_ldexp, METH_VARARGS, math_ldexp_doc}, {"log", math_log, METH_VARARGS, math_log_doc}, - {"log1p", math_log1p, METH_VARARGS, math_log1p_doc}, + {"log1p", math_log1p, METH_O, math_log1p_doc}, {"log10", math_log10, METH_O, math_log10_doc}, {"modf", math_modf, METH_O, math_modf_doc}, {"pow", math_pow, METH_VARARGS, math_pow_doc}, From python-checkins at python.org Tue Jan 29 17:59:29 2008 From: python-checkins at python.org (christian.heimes) Date: Tue, 29 Jan 2008 17:59:29 +0100 (CET) Subject: [Python-checkins] r60419 - python/branches/trunk-math/Modules/mathmodule.c Message-ID: <20080129165929.6A28D1E4005@bag.python.org> Author: christian.heimes Date: Tue Jan 29 17:59:29 2008 New Revision: 60419 Modified: python/branches/trunk-math/Modules/mathmodule.c Log: Indeed, the two lines are required on Windows. Modified: python/branches/trunk-math/Modules/mathmodule.c ============================================================================== --- python/branches/trunk-math/Modules/mathmodule.c (original) +++ python/branches/trunk-math/Modules/mathmodule.c Tue Jan 29 17:59:29 2008 @@ -437,11 +437,9 @@ y = PyFloat_AsDouble(oy); if ((x == -1.0 || y == -1.0) && PyErr_Occurred()) return NULL; - /* 1**x and x**0 return 1., even if x is a NaN or infinity. - It may be necessary to uncomment the following two lines on - Windows. + /* 1**x and x**0 return 1., even if x is a NaN or infinity. */ if (x == 1.0 || y == 0.0) - return PyFloat_FromDouble(1.); */ + return PyFloat_FromDouble(1.); errno = 0; PyFPE_START_PROTECT("in math_pow", return 0); r = pow(x, y); From python-checkins at python.org Tue Jan 29 18:02:19 2008 From: python-checkins at python.org (christian.heimes) Date: Tue, 29 Jan 2008 18:02:19 +0100 (CET) Subject: [Python-checkins] r60420 - python/branches/trunk-math/Doc/library/cmath.rst Message-ID: <20080129170219.775E41E400D@bag.python.org> Author: christian.heimes Date: Tue Jan 29 18:02:19 2008 New Revision: 60420 Modified: python/branches/trunk-math/Doc/library/cmath.rst Log: Clarify rect/polar and explain the two most import coordinate systems for complex numbers Modified: python/branches/trunk-math/Doc/library/cmath.rst ============================================================================== --- python/branches/trunk-math/Doc/library/cmath.rst (original) +++ python/branches/trunk-math/Doc/library/cmath.rst Tue Jan 29 18:02:19 2008 @@ -23,8 +23,56 @@ support signed zeros the continuity is as specified below. -The functions are: +Complex coordinates +------------------- +Complex numbers can be expressed by two important coordinate systems. +Python's :class:`complex` type uses rectangular coordinates where a number +on the complex plain is defined by two floats, the real part and the imaginary +part. + +Definition:: + + z = x + 1j * y + + x := real(z) + y := imag(z) + +In engineering the polar coordinate system is popular for complex numbers. In +polar coordinates a complex number is defined by the radius *r* and the phase +angle *?*. The radius *r* is the absolute value of the complex, which can be +viewed as distance from (0, 0). The radius *r* is always 0 or a positive float. +The phase angle *?* is the counter clockwise angle from the positive x axis, +e.g. *1* has the angle *0*, *1j* has the angle *?/2* and *-1* the angle *-?*. + +Definition:: + + z = r * exp(1j * ?) + z = r * cis(?) + + r := abs(z) + phi := arg(z) := atan2(imag(z), real(z)) + cis(?) := cos(?) + 1j * sin(?) + + +.. function:: polar(z) -> r, phi + + Convert a complex from rectangular coordinates to polar coordinates. + ``polar(z)`` returns a tuple with the two elements *r* and *?*. *r* is + the distance from 0 and *?* the phase angle. + + .. versionadded:: 2.6 + + +.. function:: rect(r, phi) -> complex + + Convert from polar coordinates to rectangular coordinates. + + .. versionadded:: 2.6 + + +cmath functions +--------------- .. function:: acos(x) @@ -125,21 +173,6 @@ :func:`log`. -.. function:: polar(x) - - Convert a complex from rectangular coordinates to polar coordinates. r is - the distance from 0 and phi the phase angle. - - .. versionadded:: 2.6 - - -.. function:: rect(r, phi) - - Convert from polar coordinates to rectangular coordinates. - - .. versionadded:: 2.6 - - .. function:: sin(x) Return the sine of *x*. From python-checkins at python.org Tue Jan 29 18:20:59 2008 From: python-checkins at python.org (christian.heimes) Date: Tue, 29 Jan 2008 18:20:59 +0100 (CET) Subject: [Python-checkins] r60421 - in python/branches/trunk-math: Doc/library/cmath.rst Lib/test/test_math.py Modules/mathmodule.c Message-ID: <20080129172059.C4FFC1E4005@bag.python.org> Author: christian.heimes Date: Tue Jan 29 18:20:59 2008 New Revision: 60421 Modified: python/branches/trunk-math/Doc/library/cmath.rst python/branches/trunk-math/Lib/test/test_math.py python/branches/trunk-math/Modules/mathmodule.c Log: log1p is designated for small ints. There is no need to support large longs. Modified: python/branches/trunk-math/Doc/library/cmath.rst ============================================================================== --- python/branches/trunk-math/Doc/library/cmath.rst (original) +++ python/branches/trunk-math/Doc/library/cmath.rst Tue Jan 29 18:20:59 2008 @@ -50,7 +50,7 @@ z = r * exp(1j * ?) z = r * cis(?) - r := abs(z) + r := abs(z) := sqrt(real(z)**2 + imag(z)**2) phi := arg(z) := atan2(imag(z), real(z)) cis(?) := cos(?) + 1j * sin(?) Modified: python/branches/trunk-math/Lib/test/test_math.py ============================================================================== --- python/branches/trunk-math/Lib/test/test_math.py (original) +++ python/branches/trunk-math/Lib/test/test_math.py Tue Jan 29 18:20:59 2008 @@ -339,6 +339,9 @@ self.assertEquals(math.log1p(INF), INF) self.assertRaises(ValueError, math.log1p, NINF) self.assert_(math.isnan(math.log1p(NAN))) + n= 2**90 + self.assertAlmostEquals(math.log1p(n), 62.383246250395075) + self.assertAlmostEquals(math.log1p(n), math.log1p(float(n))) def testLog10(self): self.assertRaises(TypeError, math.log10) Modified: python/branches/trunk-math/Modules/mathmodule.c ============================================================================== --- python/branches/trunk-math/Modules/mathmodule.c (original) +++ python/branches/trunk-math/Modules/mathmodule.c Tue Jan 29 18:20:59 2008 @@ -257,6 +257,9 @@ " x % y may differ.") FUNC2(hypot, hypot, "hypot(x,y)\n\nReturn the Euclidean distance, sqrt(x*x + y*y).") +FUNC1(log1p, log1p, 1, + "log1p(x)\n\nReturn the natural logarithm of 1+x (base e).\n\ + The result is computed in a way which is accurate for x near zero.") FUNC1(sin, sin, 0, "sin(x)\n\nReturn the sine of x (measured in radians).") FUNC1(sinh, sinh, 1, @@ -401,16 +404,6 @@ If the base not specified, returns the natural logarithm (base e) of x."); static PyObject * -math_log1p(PyObject *self, PyObject *arg) -{ - return loghelper(arg, log1p, "log1p"); -} - -PyDoc_STRVAR(math_log1p_doc, -"log1p(x) -> the natural logarithm of 1+x (base e).\n\ -The result is computed in a way which is accurate for x near zero."); - -static PyObject * math_log10(PyObject *self, PyObject *arg) { return loghelper(arg, log10, "log10"); From python-checkins at python.org Tue Jan 29 18:35:39 2008 From: python-checkins at python.org (mark.dickinson) Date: Tue, 29 Jan 2008 18:35:39 +0100 (CET) Subject: [Python-checkins] r60422 - python/branches/trunk-math/Modules/mathmodule.c Message-ID: <20080129173539.EBC0A1E4011@bag.python.org> Author: mark.dickinson Date: Tue Jan 29 18:35:39 2008 New Revision: 60422 Modified: python/branches/trunk-math/Modules/mathmodule.c Log: Make hypot work on Windows again Modified: python/branches/trunk-math/Modules/mathmodule.c ============================================================================== --- python/branches/trunk-math/Modules/mathmodule.c (original) +++ python/branches/trunk-math/Modules/mathmodule.c Tue Jan 29 18:35:39 2008 @@ -255,8 +255,6 @@ FUNC2(fmod, fmod, "fmod(x,y)\n\nReturn fmod(x, y), according to platform C." " x % y may differ.") -FUNC2(hypot, hypot, - "hypot(x,y)\n\nReturn the Euclidean distance, sqrt(x*x + y*y).") FUNC1(log1p, log1p, 1, "log1p(x)\n\nReturn the natural logarithm of 1+x (base e).\n\ The result is computed in a way which is accurate for x near zero.") @@ -412,6 +410,47 @@ PyDoc_STRVAR(math_log10_doc, "log10(x) -> the base 10 logarithm of x."); +static PyObject * +math_hypot(PyObject *self, PyObject *args) +{ + PyObject *ox, *oy; + double r, x, y; + if (! PyArg_UnpackTuple(args, "hypot", 2, 2, &ox, &oy)) + return NULL; + x = PyFloat_AsDouble(ox); + y = PyFloat_AsDouble(oy); + if ((x == -1.0 || y == -1.0) && PyErr_Occurred()) + return NULL; + /* hypot(x, +/-Inf) returns Inf, even if x is a NaN. */ + if (Py_IS_INFINITY(x)) + return PyFloat_FromDouble(fabs(x)); + if (Py_IS_INFINITY(y)) + return PyFloat_FromDouble(fabs(y)); + errno = 0; + PyFPE_START_PROTECT("in math_hypot", return 0); + r = hypot(x, y); + PyFPE_END_PROTECT(r); + if (Py_IS_NAN(r)) { + if (!Py_IS_NAN(x) && !Py_IS_NAN(y)) + errno = EDOM; + else + errno = 0; + } + else if (Py_IS_INFINITY(r)) { + if (Py_IS_FINITE(x) && Py_IS_FINITE(y)) + errno = ERANGE; + else + errno = 0; + } + if (errno && is_error(r)) + return NULL; + else + return PyFloat_FromDouble(r); +} + +PyDoc_STRVAR(math_hypot_doc, +"hypot(x,y)\n\nReturn the Euclidean distance, sqrt(x*x + y*y)."); + /* pow can't use math_2, but needs its own wrapper: the problem is that an infinite result can arise either as a result of overflow (in which case OverflowError should be raised) or as a result of From python-checkins at python.org Tue Jan 29 18:57:16 2008 From: python-checkins at python.org (mark.dickinson) Date: Tue, 29 Jan 2008 18:57:16 +0100 (CET) Subject: [Python-checkins] r60423 - python/branches/trunk-math/Modules/mathmodule.c Message-ID: <20080129175716.59DC81E401E@bag.python.org> Author: mark.dickinson Date: Tue Jan 29 18:57:16 2008 New Revision: 60423 Modified: python/branches/trunk-math/Modules/mathmodule.c Log: Make frexp, ldexp, modf work on Windows (possibly) Modified: python/branches/trunk-math/Modules/mathmodule.c ============================================================================== --- python/branches/trunk-math/Modules/mathmodule.c (original) +++ python/branches/trunk-math/Modules/mathmodule.c Tue Jan 29 18:57:16 2008 @@ -277,12 +277,10 @@ if (x == -1.0 && PyErr_Occurred()) return NULL; errno = 0; + PyFPE_START_PROTECT("ldexp", return 0); x = frexp(x, &i); - /* frexp shouldn't set errno; check, just in case. */ - if (errno && is_error(x)) - return NULL; - else - return Py_BuildValue("(di)", x, i); + PyFPE_END_PROTECT(x); + return Py_BuildValue("(di)", x, i); } PyDoc_STRVAR(math_frexp_doc, @@ -305,6 +303,10 @@ PyFPE_END_PROTECT(r) if (Py_IS_FINITE(x) && Py_IS_INFINITY(r)) errno = ERANGE; + /* Windows MSVC8 sets errno = EDOM on ldexp(NaN, i); + we unset it to avoid raising a ValueError here. */ + if (errno == EDOM) + errno = 0; if (errno && is_error(r)) return NULL; else @@ -321,14 +323,10 @@ if (x == -1.0 && PyErr_Occurred()) return NULL; errno = 0; + PyFPE_START_PROTECT("ldexp", return 0); x = modf(x, &y); - /* modf should never set errno; if it does, we raise a Python - exception---better to raise an exception than silently return - a possibly wrong value */ - if (errno && is_error(x)) - return NULL; - else - return Py_BuildValue("(dd)", x, y); + PyFPE_END_PROTECT(x); + return Py_BuildValue("(dd)", x, y); } PyDoc_STRVAR(math_modf_doc, From python-checkins at python.org Tue Jan 29 19:05:08 2008 From: python-checkins at python.org (mark.dickinson) Date: Tue, 29 Jan 2008 19:05:08 +0100 (CET) Subject: [Python-checkins] r60424 - python/branches/trunk-math/Modules/mathmodule.c Message-ID: <20080129180508.67DB01E4018@bag.python.org> Author: mark.dickinson Date: Tue Jan 29 19:05:08 2008 New Revision: 60424 Modified: python/branches/trunk-math/Modules/mathmodule.c Log: Possible fix for fmod on Windows Modified: python/branches/trunk-math/Modules/mathmodule.c ============================================================================== --- python/branches/trunk-math/Modules/mathmodule.c (original) +++ python/branches/trunk-math/Modules/mathmodule.c Tue Jan 29 19:05:08 2008 @@ -252,9 +252,6 @@ FUNC1(floor, floor, 0, "floor(x)\n\nReturn the floor of x as a float.\n" "This is the largest integral value <= x.") -FUNC2(fmod, fmod, - "fmod(x,y)\n\nReturn fmod(x, y), according to platform C." - " x % y may differ.") FUNC1(log1p, log1p, 1, "log1p(x)\n\nReturn the natural logarithm of 1+x (base e).\n\ The result is computed in a way which is accurate for x near zero.") @@ -409,6 +406,40 @@ "log10(x) -> the base 10 logarithm of x."); static PyObject * +math_fmod(PyObject *self, PyObject *args) +{ + PyObject *ox, *oy; + double r, x, y; + if (! PyArg_UnpackTuple(args, "fmod", 2, 2, &ox, &oy)) + return NULL; + x = PyFloat_AsDouble(ox); + y = PyFloat_AsDouble(oy); + if ((x == -1.0 || y == -1.0) && PyErr_Occurred()) + return NULL; + /* fmod(x, +/-Inf) returns x for finite x. */ + if (Py_IS_INFINITY(y) && Py_IS_FINITE(x)) + return PyFloat_FromDouble(x); + errno = 0; + PyFPE_START_PROTECT("in math_fmod", return 0); + r = fmod(x, y); + PyFPE_END_PROTECT(r); + if (Py_IS_NAN(r)) { + if (!Py_IS_NAN(x) && !Py_IS_NAN(y)) + errno = EDOM; + else + errno = 0; + } + if (errno && is_error(r)) + return NULL; + else + return PyFloat_FromDouble(r); +} + +PyDoc_STRVAR(math_fmod_doc, +"fmod(x,y)\n\nReturn fmod(x, y), according to platform C." +" x % y may differ."); + +static PyObject * math_hypot(PyObject *self, PyObject *args) { PyObject *ox, *oy; From python-checkins at python.org Tue Jan 29 20:52:10 2008 From: python-checkins at python.org (raymond.hettinger) Date: Tue, 29 Jan 2008 20:52:10 +0100 (CET) Subject: [Python-checkins] r60425 - python/trunk/Python/bltinmodule.c Message-ID: <20080129195210.530601E4005@bag.python.org> Author: raymond.hettinger Date: Tue Jan 29 20:52:09 2008 New Revision: 60425 Modified: python/trunk/Python/bltinmodule.c Log: CallMethod is faster with a NULL third-argument than with an empty format string. Modified: python/trunk/Python/bltinmodule.c ============================================================================== --- python/trunk/Python/bltinmodule.c (original) +++ python/trunk/Python/bltinmodule.c Tue Jan 29 20:52:09 2008 @@ -2050,7 +2050,7 @@ /* XXX: The py3k branch gets better errors for this by using _PyType_Lookup(), but since float's mro isn't set in py2.6, we just use PyObject_CallMethod here. */ - return PyObject_CallMethod(number, "__trunc__", ""); + return PyObject_CallMethod(number, "__trunc__", NULL); } PyDoc_STRVAR(trunc_doc, From python-checkins at python.org Tue Jan 29 21:29:16 2008 From: python-checkins at python.org (mark.dickinson) Date: Tue, 29 Jan 2008 21:29:16 +0100 (CET) Subject: [Python-checkins] r60427 - python/branches/trunk-math/Modules/mathmodule.c Message-ID: <20080129202916.226011E4005@bag.python.org> Author: mark.dickinson Date: Tue Jan 29 21:29:15 2008 New Revision: 60427 Modified: python/branches/trunk-math/Modules/mathmodule.c Log: Deal with special cases (infinities, nans, zeros) directly in math_frexp to avoid platform differences. Also fix up some error messages for PyFPE_START_PROTECT. Modified: python/branches/trunk-math/Modules/mathmodule.c ============================================================================== --- python/branches/trunk-math/Modules/mathmodule.c (original) +++ python/branches/trunk-math/Modules/mathmodule.c Tue Jan 29 21:29:15 2008 @@ -273,10 +273,16 @@ double x = PyFloat_AsDouble(arg); if (x == -1.0 && PyErr_Occurred()) return NULL; - errno = 0; - PyFPE_START_PROTECT("ldexp", return 0); - x = frexp(x, &i); - PyFPE_END_PROTECT(x); + /* deal with special cases directly, to sidestep platform + differences */ + if (Py_IS_NAN(x) || Py_IS_INFINITY(x) || !x) { + i = 0; + } + else { + PyFPE_START_PROTECT("in math_frexp", return 0); + x = frexp(x, &i); + PyFPE_END_PROTECT(x); + } return Py_BuildValue("(di)", x, i); } @@ -295,7 +301,7 @@ if (! PyArg_ParseTuple(args, "di:ldexp", &x, &exp)) return NULL; errno = 0; - PyFPE_START_PROTECT("ldexp", return 0) + PyFPE_START_PROTECT("in math_ldexp", return 0) r = ldexp(x, exp); PyFPE_END_PROTECT(r) if (Py_IS_FINITE(x) && Py_IS_INFINITY(r)) @@ -320,7 +326,7 @@ if (x == -1.0 && PyErr_Occurred()) return NULL; errno = 0; - PyFPE_START_PROTECT("ldexp", return 0); + PyFPE_START_PROTECT("in math_modf", return 0); x = modf(x, &y); PyFPE_END_PROTECT(x); return Py_BuildValue("(dd)", x, y); From nnorwitz at gmail.com Tue Jan 29 23:25:13 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Tue, 29 Jan 2008 17:25:13 -0500 Subject: [Python-checkins] Python Regression Test Failures refleak (1) Message-ID: <20080129222513.GA19929@python.psfb.org> test_marshal leaked [32, 32, 32] references, sum=96 test_urllib2_localnet leaked [-120, 3, 123] references, sum=6 From python-checkins at python.org Tue Jan 29 23:39:13 2008 From: python-checkins at python.org (mark.dickinson) Date: Tue, 29 Jan 2008 23:39:13 +0100 (CET) Subject: [Python-checkins] r60429 - python/branches/trunk-math/Python/pymath.c Message-ID: <20080129223913.8F0271E4005@bag.python.org> Author: mark.dickinson Date: Tue Jan 29 23:39:13 2008 New Revision: 60429 Modified: python/branches/trunk-math/Python/pymath.c Log: Remove the ((huge+x) > 1.0) check from asinh; it's unnecessary (it serves only to raise the inexact floating-point exception, which Python doesn't care about), and the value huge is a potential platform-dependency. Modified: python/branches/trunk-math/Python/pymath.c ============================================================================== --- python/branches/trunk-math/Python/pymath.c (original) +++ python/branches/trunk-math/Python/pymath.c Tue Jan 29 23:39:13 2008 @@ -88,7 +88,6 @@ */ static const double ln2 = 6.93147180559945286227E-01; -static const double huge = 1E+300; static const double two_pow_m28 = 3.7252902984619141E-09; /* 2**-28 */ static const double two_pow_p28 = 268435456.0; /* 2**28 */ static const double zero = 0.0; @@ -115,8 +114,7 @@ return x+x; } if (absx < two_pow_m28) { /* |x| < 2**-28 */ - if ((huge + x) > 1.0) - return x; /* return x inexact except 0 */ + return x; /* return x inexact except 0 */ } if (absx > two_pow_p28) { /* |x| > 2**28 */ w = log(absx)+ln2; @@ -231,4 +229,4 @@ } return copysign(t, x); } -#endif /* HAVE_ATANH */ \ No newline at end of file +#endif /* HAVE_ATANH */ From python-checkins at python.org Wed Jan 30 00:44:20 2008 From: python-checkins at python.org (brett.cannon) Date: Wed, 30 Jan 2008 00:44:20 +0100 (CET) Subject: [Python-checkins] r60430 - peps/trunk/pep-3108.txt Message-ID: <20080129234420.4C13C1E4005@bag.python.org> Author: brett.cannon Date: Wed Jan 30 00:44:20 2008 New Revision: 60430 Modified: peps/trunk/pep-3108.txt Log: Add a footnote about the proposed dbm package and the combining of two existing modules into one. Modified: peps/trunk/pep-3108.txt ============================================================================== --- peps/trunk/pep-3108.txt (original) +++ peps/trunk/pep-3108.txt Wed Jan 30 00:44:20 2008 @@ -477,23 +477,22 @@ dbm package /////////// -The ``dbm`` package is to collect all dbm-related modules. Do note -that both ``anydbm`` and ``whichdb`` are merged into a single module. -This was done as both modules currently have minimal functionality and -have no name conflicts. - ================= =============================== Current Name Replacement Name ================= =============================== -anydbm dbm.tools +anydbm dbm.tools [1]_ dbhash dbm.db dbm dbm.ndbm dumbdm dbm.dumb gdbm dbm.gnu -whichdb dbm.tools +whichdb dbm.tools [1]_ ================= =============================== +.. [1] ``dbm.tools`` can combine ``anybdbm`` and ``whichdb`` since the public + API for both modules has no name conflict. + + Transition Plan =============== From python-checkins at python.org Wed Jan 30 01:01:08 2008 From: python-checkins at python.org (raymond.hettinger) Date: Wed, 30 Jan 2008 01:01:08 +0100 (CET) Subject: [Python-checkins] r60431 - python/trunk/Lib/_abcoll.py Message-ID: <20080130000108.3772E1E4005@bag.python.org> Author: raymond.hettinger Date: Wed Jan 30 01:01:07 2008 New Revision: 60431 Modified: python/trunk/Lib/_abcoll.py Log: Add isdisjoint() to the Set/MutableSet ABCs. Modified: python/trunk/Lib/_abcoll.py ============================================================================== --- python/trunk/Lib/_abcoll.py (original) +++ python/trunk/Lib/_abcoll.py Wed Jan 30 01:01:07 2008 @@ -177,6 +177,12 @@ return NotImplemented return self._from_iterable(value for value in other if value in self) + def isdisjoint(self, other): + for value in other: + if value in self: + return False + return True + def __or__(self, other): if not isinstance(other, Iterable): return NotImplemented From python-checkins at python.org Wed Jan 30 01:08:31 2008 From: python-checkins at python.org (raymond.hettinger) Date: Wed, 30 Jan 2008 01:08:31 +0100 (CET) Subject: [Python-checkins] r60432 - python/trunk/Lib/_abcoll.py Message-ID: <20080130000831.56DFA1E401D@bag.python.org> Author: raymond.hettinger Date: Wed Jan 30 01:08:31 2008 New Revision: 60432 Modified: python/trunk/Lib/_abcoll.py Log: MutableSets support a remove() method. Modified: python/trunk/Lib/_abcoll.py ============================================================================== --- python/trunk/Lib/_abcoll.py (original) +++ python/trunk/Lib/_abcoll.py Wed Jan 30 01:08:31 2008 @@ -250,6 +250,12 @@ """Return True if it was deleted, False if not there.""" raise NotImplementedError + def remove(self, value): + """Remove an element. If not a member, raise a KeyError.""" + if value not in self: + raise KeyError(value) + self.discard(value) + def pop(self): """Return the popped value. Raise KeyError if empty.""" it = iter(self) From python-checkins at python.org Wed Jan 30 01:51:59 2008 From: python-checkins at python.org (raymond.hettinger) Date: Wed, 30 Jan 2008 01:51:59 +0100 (CET) Subject: [Python-checkins] r60433 - python/trunk/Doc/tutorial/errors.rst Message-ID: <20080130005159.0BEAC1E4009@bag.python.org> Author: raymond.hettinger Date: Wed Jan 30 01:51:58 2008 New Revision: 60433 Modified: python/trunk/Doc/tutorial/errors.rst Log: Demonstrate new except/as syntax. Modified: python/trunk/Doc/tutorial/errors.rst ============================================================================== --- python/trunk/Doc/tutorial/errors.rst (original) +++ python/trunk/Doc/tutorial/errors.rst Wed Jan 30 01:51:58 2008 @@ -131,7 +131,7 @@ f = open('myfile.txt') s = f.readline() i = int(s.strip()) - except IOError, (errno, strerror): + except IOError as (errno, strerror): print "I/O error(%s): %s" % (errno, strerror) except ValueError: print "Could not convert data to an integer." @@ -176,7 +176,7 @@ >>> try: ... raise Exception('spam', 'eggs') - ... except Exception, inst: + ... except Exception as inst: ... print type(inst) # the exception instance ... print inst.args # arguments stored in .args ... print inst # __str__ allows args to printed directly @@ -202,7 +202,7 @@ ... >>> try: ... this_fails() - ... except ZeroDivisionError, detail: + ... except ZeroDivisionError as detail: ... print 'Handling run-time error:', detail ... Handling run-time error: integer division or modulo by zero @@ -259,7 +259,7 @@ ... >>> try: ... raise MyError(2*2) - ... except MyError, e: + ... except MyError as e: ... print 'My exception occurred, value:', e.value ... My exception occurred, value: 4 From buildbot at python.org Wed Jan 30 02:32:02 2008 From: buildbot at python.org (buildbot at python.org) Date: Wed, 30 Jan 2008 01:32:02 +0000 Subject: [Python-checkins] buildbot failure in x86 FreeBSD trunk Message-ID: <20080130013202.D8C6A1E4005@bag.python.org> The Buildbot has detected a new failure of x86 FreeBSD trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20FreeBSD%20trunk/builds/497 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-freebsd Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 227, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 268, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 281, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 560, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable sincerely, -The Buildbot From buildbot at python.org Wed Jan 30 02:40:13 2008 From: buildbot at python.org (buildbot at python.org) Date: Wed, 30 Jan 2008 01:40:13 +0000 Subject: [Python-checkins] buildbot failure in ppc Debian unstable trunk Message-ID: <20080130014013.3BBA31E4005@bag.python.org> The Buildbot has detected a new failure of ppc Debian unstable trunk. Full details are available at: http://www.python.org/dev/buildbot/all/ppc%20Debian%20unstable%20trunk/builds/700 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: 2 tests failed: test_urllib2 test_urllib2net ====================================================================== ERROR: test_trivial (test.test_urllib2.TrivialTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_urllib2.py", line 19, in test_trivial self.assertRaises(ValueError, urllib2.urlopen, 'bogus url') File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/unittest.py", line 329, in failUnlessRaises callableObj(*args, **kwargs) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 123, in urlopen _opener = build_opener() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 461, in build_opener opener.add_handler(klass()) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 670, in __init__ proxies = getproxies() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib.py", line 1294, in getproxies_environment for name, value in os.environ.items(): AttributeError: 'NoneType' object has no attribute 'environ' ====================================================================== ERROR: test_file (test.test_urllib2.HandlerTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_urllib2.py", line 619, in test_file r = h.file_open(Request(url)) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 1204, in file_open return self.open_local_file(req) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 1223, in open_local_file localfile = url2pathname(file) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib.py", line 55, in url2pathname return unquote(pathname) TypeError: 'NoneType' object is not callable ====================================================================== ERROR: test_http (test.test_urllib2.HandlerTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_urllib2.py", line 725, in test_http r.read; r.readline # wrapped MockFile methods AttributeError: addinfourl instance has no attribute 'read' ====================================================================== ERROR: test_build_opener (test.test_urllib2.MiscTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_urllib2.py", line 1031, in test_build_opener o = build_opener(FooHandler, BarHandler) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 461, in build_opener opener.add_handler(klass()) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 670, in __init__ proxies = getproxies() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib.py", line 1294, in getproxies_environment for name, value in os.environ.items(): AttributeError: 'NoneType' object has no attribute 'environ' ====================================================================== ERROR: testURLread (test.test_urllib2net.URLTimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_urllib2net.py", line 38, in testURLread f = _urlopen_with_retry("http://www.python.org/") File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_urllib2net.py", line 19, in _urlopen_with_retry return urllib2.urlopen(host, *args, **kwargs) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 123, in urlopen _opener = build_opener() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 461, in build_opener opener.add_handler(klass()) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 670, in __init__ proxies = getproxies() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib.py", line 1294, in getproxies_environment for name, value in os.environ.items(): AttributeError: 'NoneType' object has no attribute 'environ' ====================================================================== ERROR: test_bad_address (test.test_urllib2net.urlopenNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_urllib2net.py", line 161, in test_bad_address urllib2.urlopen, "http://www.python.invalid./") File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/unittest.py", line 329, in failUnlessRaises callableObj(*args, **kwargs) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 123, in urlopen _opener = build_opener() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 461, in build_opener opener.add_handler(klass()) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 670, in __init__ proxies = getproxies() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib.py", line 1294, in getproxies_environment for name, value in os.environ.items(): AttributeError: 'NoneType' object has no attribute 'environ' ====================================================================== ERROR: test_basic (test.test_urllib2net.urlopenNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_urllib2net.py", line 119, in test_basic open_url = _urlopen_with_retry("http://www.python.org/") File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_urllib2net.py", line 19, in _urlopen_with_retry return urllib2.urlopen(host, *args, **kwargs) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 123, in urlopen _opener = build_opener() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 461, in build_opener opener.add_handler(klass()) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 670, in __init__ proxies = getproxies() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib.py", line 1294, in getproxies_environment for name, value in os.environ.items(): AttributeError: 'NoneType' object has no attribute 'environ' ====================================================================== ERROR: test_geturl (test.test_urllib2net.urlopenNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_urllib2net.py", line 143, in test_geturl open_url = _urlopen_with_retry(URL) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_urllib2net.py", line 19, in _urlopen_with_retry return urllib2.urlopen(host, *args, **kwargs) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 123, in urlopen _opener = build_opener() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 461, in build_opener opener.add_handler(klass()) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 670, in __init__ proxies = getproxies() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib.py", line 1294, in getproxies_environment for name, value in os.environ.items(): AttributeError: 'NoneType' object has no attribute 'environ' ====================================================================== ERROR: test_info (test.test_urllib2net.urlopenNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_urllib2net.py", line 130, in test_info open_url = _urlopen_with_retry("http://www.python.org/") File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_urllib2net.py", line 19, in _urlopen_with_retry return urllib2.urlopen(host, *args, **kwargs) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 123, in urlopen _opener = build_opener() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 461, in build_opener opener.add_handler(klass()) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 670, in __init__ proxies = getproxies() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib.py", line 1294, in getproxies_environment for name, value in os.environ.items(): AttributeError: 'NoneType' object has no attribute 'environ' ====================================================================== ERROR: test_file (test.test_urllib2net.OtherNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_urllib2net.py", line 201, in test_file self._test_urls(urls, self._extra_handlers(), urllib2.urlopen) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_urllib2net.py", line 249, in _test_urls urllib2.install_opener(urllib2.build_opener(*handlers)) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 461, in build_opener opener.add_handler(klass()) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 670, in __init__ proxies = getproxies() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib.py", line 1294, in getproxies_environment for name, value in os.environ.items(): AttributeError: 'NoneType' object has no attribute 'environ' ====================================================================== ERROR: test_ftp (test.test_urllib2net.OtherNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_urllib2net.py", line 189, in test_ftp self._test_urls(urls, self._extra_handlers()) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_urllib2net.py", line 249, in _test_urls urllib2.install_opener(urllib2.build_opener(*handlers)) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 461, in build_opener opener.add_handler(klass()) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 670, in __init__ proxies = getproxies() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib.py", line 1294, in getproxies_environment for name, value in os.environ.items(): AttributeError: 'NoneType' object has no attribute 'environ' ====================================================================== ERROR: test_http (test.test_urllib2net.OtherNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_urllib2net.py", line 213, in test_http self._test_urls(urls, self._extra_handlers()) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_urllib2net.py", line 249, in _test_urls urllib2.install_opener(urllib2.build_opener(*handlers)) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 461, in build_opener opener.add_handler(klass()) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 670, in __init__ proxies = getproxies() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib.py", line 1294, in getproxies_environment for name, value in os.environ.items(): AttributeError: 'NoneType' object has no attribute 'environ' ====================================================================== ERROR: test_range (test.test_urllib2net.OtherNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_urllib2net.py", line 174, in test_range result = _urlopen_with_retry(req) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_urllib2net.py", line 19, in _urlopen_with_retry return urllib2.urlopen(host, *args, **kwargs) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 123, in urlopen _opener = build_opener() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 461, in build_opener opener.add_handler(klass()) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 670, in __init__ proxies = getproxies() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib.py", line 1294, in getproxies_environment for name, value in os.environ.items(): AttributeError: 'NoneType' object has no attribute 'environ' ====================================================================== ERROR: test_close (test.test_urllib2net.CloseSocketTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_urllib2net.py", line 90, in test_close response = _urlopen_with_retry("http://www.python.org/") File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_urllib2net.py", line 19, in _urlopen_with_retry return urllib2.urlopen(host, *args, **kwargs) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 123, in urlopen _opener = build_opener() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 461, in build_opener opener.add_handler(klass()) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 670, in __init__ proxies = getproxies() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib.py", line 1294, in getproxies_environment for name, value in os.environ.items(): AttributeError: 'NoneType' object has no attribute 'environ' ====================================================================== ERROR: test_ftp_NoneNodefault (test.test_urllib2net.TimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_urllib2net.py", line 320, in test_ftp_NoneNodefault u = _urlopen_with_retry(self.FTP_HOST, timeout=None) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_urllib2net.py", line 19, in _urlopen_with_retry return urllib2.urlopen(host, *args, **kwargs) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 123, in urlopen _opener = build_opener() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 461, in build_opener opener.add_handler(klass()) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 670, in __init__ proxies = getproxies() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib.py", line 1294, in getproxies_environment for name, value in os.environ.items(): AttributeError: 'NoneType' object has no attribute 'environ' ====================================================================== ERROR: test_ftp_NoneWithdefault (test.test_urllib2net.TimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_urllib2net.py", line 314, in test_ftp_NoneWithdefault u = _urlopen_with_retry(self.FTP_HOST, timeout=None) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_urllib2net.py", line 19, in _urlopen_with_retry return urllib2.urlopen(host, *args, **kwargs) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 123, in urlopen _opener = build_opener() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 461, in build_opener opener.add_handler(klass()) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 670, in __init__ proxies = getproxies() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib.py", line 1294, in getproxies_environment for name, value in os.environ.items(): AttributeError: 'NoneType' object has no attribute 'environ' ====================================================================== ERROR: test_ftp_Value (test.test_urllib2net.TimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_urllib2net.py", line 324, in test_ftp_Value u = _urlopen_with_retry(self.FTP_HOST, timeout=60) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_urllib2net.py", line 19, in _urlopen_with_retry return urllib2.urlopen(host, *args, **kwargs) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 123, in urlopen _opener = build_opener() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 461, in build_opener opener.add_handler(klass()) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 670, in __init__ proxies = getproxies() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib.py", line 1294, in getproxies_environment for name, value in os.environ.items(): AttributeError: 'NoneType' object has no attribute 'environ' ====================================================================== ERROR: test_ftp_basic (test.test_urllib2net.TimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_urllib2net.py", line 307, in test_ftp_basic u = _urlopen_with_retry(self.FTP_HOST) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_urllib2net.py", line 19, in _urlopen_with_retry return urllib2.urlopen(host, *args, **kwargs) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 123, in urlopen _opener = build_opener() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 461, in build_opener opener.add_handler(klass()) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 670, in __init__ proxies = getproxies() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib.py", line 1294, in getproxies_environment for name, value in os.environ.items(): AttributeError: 'NoneType' object has no attribute 'environ' ====================================================================== ERROR: test_http_NoneNodefault (test.test_urllib2net.TimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_urllib2net.py", line 301, in test_http_NoneNodefault u = _urlopen_with_retry("http://www.python.org", timeout=None) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_urllib2net.py", line 19, in _urlopen_with_retry return urllib2.urlopen(host, *args, **kwargs) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 123, in urlopen _opener = build_opener() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 461, in build_opener opener.add_handler(klass()) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 670, in __init__ proxies = getproxies() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib.py", line 1294, in getproxies_environment for name, value in os.environ.items(): AttributeError: 'NoneType' object has no attribute 'environ' ====================================================================== ERROR: test_http_NoneWithdefault (test.test_urllib2net.TimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_urllib2net.py", line 291, in test_http_NoneWithdefault u = _urlopen_with_retry("http://www.python.org", timeout=None) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_urllib2net.py", line 19, in _urlopen_with_retry return urllib2.urlopen(host, *args, **kwargs) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 123, in urlopen _opener = build_opener() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 461, in build_opener opener.add_handler(klass()) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 670, in __init__ proxies = getproxies() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib.py", line 1294, in getproxies_environment for name, value in os.environ.items(): AttributeError: 'NoneType' object has no attribute 'environ' ====================================================================== ERROR: test_http_Value (test.test_urllib2net.TimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_urllib2net.py", line 297, in test_http_Value u = _urlopen_with_retry("http://www.python.org", timeout=120) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_urllib2net.py", line 19, in _urlopen_with_retry return urllib2.urlopen(host, *args, **kwargs) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 123, in urlopen _opener = build_opener() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 461, in build_opener opener.add_handler(klass()) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 670, in __init__ proxies = getproxies() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib.py", line 1294, in getproxies_environment for name, value in os.environ.items(): AttributeError: 'NoneType' object has no attribute 'environ' ====================================================================== ERROR: test_http_basic (test.test_urllib2net.TimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_urllib2net.py", line 284, in test_http_basic u = _urlopen_with_retry("http://www.python.org") File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/test/test_urllib2net.py", line 19, in _urlopen_with_retry return urllib2.urlopen(host, *args, **kwargs) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 123, in urlopen _opener = build_opener() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 461, in build_opener opener.add_handler(klass()) File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib2.py", line 670, in __init__ proxies = getproxies() File "/home/pybot/buildarea/trunk.klose-debian-ppc/build/Lib/urllib.py", line 1294, in getproxies_environment for name, value in os.environ.items(): AttributeError: 'NoneType' object has no attribute 'environ' make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Wed Jan 30 04:25:59 2008 From: python-checkins at python.org (martin.v.loewis) Date: Wed, 30 Jan 2008 04:25:59 +0100 (CET) Subject: [Python-checkins] r60435 - tracker/instances/python-dev/html/msg.item.html Message-ID: <20080130032559.2A7191E4005@bag.python.org> Author: martin.v.loewis Date: Wed Jan 30 04:25:58 2008 New Revision: 60435 Modified: tracker/instances/python-dev/html/msg.item.html Log: Display msgid and in-reply-to. Modified: tracker/instances/python-dev/html/msg.item.html ============================================================================== --- tracker/instances/python-dev/html/msg.item.html (original) +++ tracker/instances/python-dev/html/msg.item.html Wed Jan 30 04:25:58 2008 @@ -58,6 +58,16 @@
  • + + + + + + + + + +
    Messages
    Messages
    author date
    content
    content
    Messge-id
    In-reply-to

    From python-checkins at python.org Wed Jan 30 04:34:28 2008 From: python-checkins at python.org (martin.v.loewis) Date: Wed, 30 Jan 2008 04:34:28 +0100 (CET) Subject: [Python-checkins] r60436 - tracker/instances/python-dev/html/msg.item.html Message-ID: <20080130033428.1B4B41E4009@bag.python.org> Author: martin.v.loewis Date: Wed Jan 30 04:34:27 2008 New Revision: 60436 Modified: tracker/instances/python-dev/html/msg.item.html Log: Fix typo. Modified: tracker/instances/python-dev/html/msg.item.html ============================================================================== --- tracker/instances/python-dev/html/msg.item.html (original) +++ tracker/instances/python-dev/html/msg.item.html Wed Jan 30 04:34:27 2008 @@ -59,7 +59,7 @@ - Messge-id + Message-id From buildbot at python.org Wed Jan 30 11:13:20 2008 From: buildbot at python.org (buildbot at python.org) Date: Wed, 30 Jan 2008 10:13:20 +0000 Subject: [Python-checkins] buildbot failure in alpha Tru64 5.1 3.0 Message-ID: <20080130101320.E57141E4011@bag.python.org> The Buildbot has detected a new failure of alpha Tru64 5.1 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/alpha%20Tru64%205.1%203.0/builds/586 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-tru64 Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: sincerely, -The Buildbot From buildbot at python.org Wed Jan 30 11:19:32 2008 From: buildbot at python.org (buildbot at python.org) Date: Wed, 30 Jan 2008 10:19:32 +0000 Subject: [Python-checkins] buildbot failure in hppa Ubuntu 3.0 Message-ID: <20080130101932.419C81E4011@bag.python.org> The Buildbot has detected a new failure of hppa Ubuntu 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/hppa%20Ubuntu%203.0/builds/470 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-ubuntu-hppa Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes BUILD FAILED: failed failed slave lost sincerely, -The Buildbot From buildbot at python.org Wed Jan 30 11:42:31 2008 From: buildbot at python.org (buildbot at python.org) Date: Wed, 30 Jan 2008 10:42:31 +0000 Subject: [Python-checkins] buildbot failure in ia64 Ubuntu 3.0 Message-ID: <20080130104232.05A761E4011@bag.python.org> The Buildbot has detected a new failure of ia64 Ubuntu 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/ia64%20Ubuntu%203.0/builds/487 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ia64 Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes BUILD FAILED: failed failed slave lost sincerely, -The Buildbot From python-checkins at python.org Wed Jan 30 12:32:38 2008 From: python-checkins at python.org (christian.heimes) Date: Wed, 30 Jan 2008 12:32:38 +0100 (CET) Subject: [Python-checkins] r60440 - in python/trunk: Include/unicodeobject.h Misc/NEWS Objects/unicodeobject.c Message-ID: <20080130113238.73F8A1E4006@bag.python.org> Author: christian.heimes Date: Wed Jan 30 12:32:37 2008 New Revision: 60440 Modified: python/trunk/Include/unicodeobject.h python/trunk/Misc/NEWS python/trunk/Objects/unicodeobject.c Log: Patch #1970 by Antoine Pitrou: Speedup unicode whitespace and linebreak detection. The speedup is about 25% for split() (571 / 457 usec) and 35% (175 / 127 usec )for splitlines() Modified: python/trunk/Include/unicodeobject.h ============================================================================== --- python/trunk/Include/unicodeobject.h (original) +++ python/trunk/Include/unicodeobject.h Wed Jan 30 12:32:37 2008 @@ -348,7 +348,14 @@ #else -#define Py_UNICODE_ISSPACE(ch) _PyUnicode_IsWhitespace(ch) +/* Since splitting on whitespace is an important use case, and whitespace + in most situations is solely ASCII whitespace, we optimize for the common + case by using a quick look-up table with an inlined check. + */ +extern const unsigned char _Py_ascii_whitespace[]; + +#define Py_UNICODE_ISSPACE(ch) \ + ((ch) < 128U ? _Py_ascii_whitespace[(ch)] : _PyUnicode_IsWhitespace(ch)) #define Py_UNICODE_ISLOWER(ch) _PyUnicode_IsLowercase(ch) #define Py_UNICODE_ISUPPER(ch) _PyUnicode_IsUppercase(ch) Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Wed Jan 30 12:32:37 2008 @@ -12,6 +12,9 @@ Core and builtins ----------------- +- Patch #1970 by Antoine Pitrou: Speedup unicode whitespace and linebreak + detection + - Added ``PyType_ClearCache()`` and ``sys._cleartypecache`` to clear the internal lookup cache for ref leak tests. Modified: python/trunk/Objects/unicodeobject.c ============================================================================== --- python/trunk/Objects/unicodeobject.c (original) +++ python/trunk/Objects/unicodeobject.c Wed Jan 30 12:32:37 2008 @@ -112,6 +112,64 @@ */ static char unicode_default_encoding[100]; +/* Fast detection of the most frequent whitespace characters */ +const unsigned char _Py_ascii_whitespace[] = { + 0, 0, 0, 0, 0, 0, 0, 0, +// case 0x0009: /* HORIZONTAL TABULATION */ +// case 0x000A: /* LINE FEED */ +// case 0x000B: /* VERTICAL TABULATION */ +// case 0x000C: /* FORM FEED */ +// case 0x000D: /* CARRIAGE RETURN */ + 0, 1, 1, 1, 1, 1, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, +// case 0x001C: /* FILE SEPARATOR */ +// case 0x001D: /* GROUP SEPARATOR */ +// case 0x001E: /* RECORD SEPARATOR */ +// case 0x001F: /* UNIT SEPARATOR */ + 0, 0, 0, 0, 1, 1, 1, 1, +// case 0x0020: /* SPACE */ + 1, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0 +}; + +/* Same for linebreaks */ +static unsigned char ascii_linebreak[] = { + 0, 0, 0, 0, 0, 0, 0, 0, +// 0x000A, /* LINE FEED */ +// 0x000D, /* CARRIAGE RETURN */ + 0, 0, 1, 0, 0, 1, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, +// 0x001C, /* FILE SEPARATOR */ +// 0x001D, /* GROUP SEPARATOR */ +// 0x001E, /* RECORD SEPARATOR */ + 0, 0, 0, 0, 1, 1, 1, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0 +}; + + Py_UNICODE PyUnicode_GetMax(void) { @@ -138,8 +196,9 @@ #define BLOOM(mask, ch) ((mask & (1 << ((ch) & 0x1F)))) -#define BLOOM_LINEBREAK(ch)\ - (BLOOM(bloom_linebreak, (ch)) && Py_UNICODE_ISLINEBREAK((ch))) +#define BLOOM_LINEBREAK(ch) \ + ((ch) < 128U ? ascii_linebreak[(ch)] : \ + (BLOOM(bloom_linebreak, (ch)) && Py_UNICODE_ISLINEBREAK(ch))) Py_LOCAL_INLINE(BLOOM_MASK) make_bloom_mask(Py_UNICODE* ptr, Py_ssize_t len) { @@ -5505,25 +5564,26 @@ register Py_ssize_t j; Py_ssize_t len = self->length; PyObject *str; + register const Py_UNICODE *buf = self->str; for (i = j = 0; i < len; ) { /* find a token */ - while (i < len && Py_UNICODE_ISSPACE(self->str[i])) + while (i < len && Py_UNICODE_ISSPACE(buf[i])) i++; j = i; - while (i < len && !Py_UNICODE_ISSPACE(self->str[i])) + while (i < len && !Py_UNICODE_ISSPACE(buf[i])) i++; if (j < i) { if (maxcount-- <= 0) break; - SPLIT_APPEND(self->str, j, i); - while (i < len && Py_UNICODE_ISSPACE(self->str[i])) + SPLIT_APPEND(buf, j, i); + while (i < len && Py_UNICODE_ISSPACE(buf[i])) i++; j = i; } } if (j < len) { - SPLIT_APPEND(self->str, j, len); + SPLIT_APPEND(buf, j, len); } return list; @@ -5596,18 +5656,19 @@ register Py_ssize_t j; Py_ssize_t len = self->length; PyObject *str; + register const Py_UNICODE *buf = self->str; for (i = j = 0; i < len; ) { - if (self->str[i] == ch) { + if (buf[i] == ch) { if (maxcount-- <= 0) break; - SPLIT_APPEND(self->str, j, i); + SPLIT_APPEND(buf, j, i); i = j = i + 1; } else i++; } if (j <= len) { - SPLIT_APPEND(self->str, j, len); + SPLIT_APPEND(buf, j, len); } return list; @@ -5656,25 +5717,26 @@ register Py_ssize_t j; Py_ssize_t len = self->length; PyObject *str; + register const Py_UNICODE *buf = self->str; for (i = j = len - 1; i >= 0; ) { /* find a token */ - while (i >= 0 && Py_UNICODE_ISSPACE(self->str[i])) + while (i >= 0 && Py_UNICODE_ISSPACE(buf[i])) i--; j = i; - while (i >= 0 && !Py_UNICODE_ISSPACE(self->str[i])) + while (i >= 0 && !Py_UNICODE_ISSPACE(buf[i])) i--; if (j > i) { if (maxcount-- <= 0) break; - SPLIT_APPEND(self->str, i + 1, j + 1); - while (i >= 0 && Py_UNICODE_ISSPACE(self->str[i])) + SPLIT_APPEND(buf, i + 1, j + 1); + while (i >= 0 && Py_UNICODE_ISSPACE(buf[i])) i--; j = i; } } if (j >= 0) { - SPLIT_APPEND(self->str, 0, j + 1); + SPLIT_APPEND(buf, 0, j + 1); } if (PyList_Reverse(list) < 0) goto onError; @@ -5695,18 +5757,19 @@ register Py_ssize_t j; Py_ssize_t len = self->length; PyObject *str; + register const Py_UNICODE *buf = self->str; for (i = j = len - 1; i >= 0; ) { - if (self->str[i] == ch) { + if (buf[i] == ch) { if (maxcount-- <= 0) break; - SPLIT_APPEND(self->str, i + 1, j + 1); + SPLIT_APPEND(buf, i + 1, j + 1); j = i = i - 1; } else i--; } if (j >= -1) { - SPLIT_APPEND(self->str, 0, j + 1); + SPLIT_APPEND(buf, 0, j + 1); } if (PyList_Reverse(list) < 0) goto onError; From python-checkins at python.org Wed Jan 30 12:46:01 2008 From: python-checkins at python.org (christian.heimes) Date: Wed, 30 Jan 2008 12:46:01 +0100 (CET) Subject: [Python-checkins] r60441 - python/trunk/Python/marshal.c Message-ID: <20080130114601.1B78C1E4006@bag.python.org> Author: christian.heimes Date: Wed Jan 30 12:46:00 2008 New Revision: 60441 Modified: python/trunk/Python/marshal.c Log: Removed unused var Modified: python/trunk/Python/marshal.c ============================================================================== --- python/trunk/Python/marshal.c (original) +++ python/trunk/Python/marshal.c Wed Jan 30 12:46:00 2008 @@ -508,7 +508,7 @@ { /* NULL is a valid return value, it does not necessarily means that an exception is set. */ - PyObject *v, *v2, *v3; + PyObject *v, *v2; long i, n; int type = r_byte(p); PyObject *retval; From python-checkins at python.org Wed Jan 30 14:41:40 2008 From: python-checkins at python.org (christian.heimes) Date: Wed, 30 Jan 2008 14:41:40 +0100 (CET) Subject: [Python-checkins] r60445 - python/branches/trunk-math/Doc/library/cmath.rst Message-ID: <20080130134140.834A61E402B@bag.python.org> Author: christian.heimes Date: Wed Jan 30 14:41:40 2008 New Revision: 60445 Modified: python/branches/trunk-math/Doc/library/cmath.rst Log: More doc updates Modified: python/branches/trunk-math/Doc/library/cmath.rst ============================================================================== --- python/branches/trunk-math/Doc/library/cmath.rst (original) +++ python/branches/trunk-math/Doc/library/cmath.rst Wed Jan 30 14:41:40 2008 @@ -55,22 +55,32 @@ cis(?) := cos(?) + 1j * sin(?) -.. function:: polar(z) -> r, phi +.. function:: arg(x) - Convert a complex from rectangular coordinates to polar coordinates. - ``polar(z)`` returns a tuple with the two elements *r* and *?*. *r* is - the distance from 0 and *?* the phase angle. + Return argument, also known as the phase angle, of a complex. .. versionadded:: 2.6 -.. function:: rect(r, phi) -> complex +.. function:: polar(x) - Convert from polar coordinates to rectangular coordinates. + Convert a :class:`complex` from rectangular coordinates to polar + coordinates. The function returns a tuple with the two elements + *r* and *phi*. *r* is the distance from 0 and *phi* the phase + angle. .. versionadded:: 2.6 +.. function:: rect(r, phi) + + Convert from polar coordinates to rectangular coordinates and return + a :class:`complex`. + + .. versionadded:: 2.6 + + + cmath functions --------------- @@ -87,13 +97,6 @@ from 1 along the real axis to -?, continuous from above. -.. function:: arg(x) - - Return argument, also known as the phase angle, of a complex. - - .. versionadded:: 2.6 - - .. function:: asin(x) Return the arc sine of *x*. This has the same branch cuts as :func:`acos`. @@ -149,11 +152,16 @@ .. function:: isinf(x) + Return *True* if the real or the imaginary part of x is positive + or negative infinity. + .. versionadded:: 2.6 .. function:: isnan(x) + Return *True* if the real or imaginary part of x is not a number (NaN). + .. versionadded:: 2.6 From python-checkins at python.org Wed Jan 30 14:42:24 2008 From: python-checkins at python.org (christian.heimes) Date: Wed, 30 Jan 2008 14:42:24 +0100 (CET) Subject: [Python-checkins] r60446 - in python/branches/trunk-math: Doc/c-api/set.rst Doc/c-api/type.rst Doc/conf.py Doc/library/sys.rst Doc/tools/sphinxext Doc/tutorial/errors.rst Include/object.h Include/setobject.h Include/unicodeobject.h Lib/_abcoll.py Lib/ctypes/test/test_funcptr.py Lib/optparse.py Lib/pydoc.py Lib/rational.py Lib/test/regrtest.py Lib/test/test_builtin.py Lib/test/test_resource.py Lib/test/test_xmlrpc.py Makefile.pre.in Misc/NEWS Misc/Vim/python.vim Misc/Vim/syntax_test.py Misc/Vim/vim_syntax.py Modules/_ctypes/_ctypes.c Modules/_ctypes/callbacks.c Objects/abstract.c Objects/complexobject.c Objects/fileobject.c Objects/floatobject.c Objects/setobject.c Objects/typeobject.c Objects/unicodeobject.c Python/bltinmodule.c Python/compile.c Python/marshal.c Python/pythonrun.c Python/sysmodule.c setup.py Message-ID: <20080130134224.C76E61E4006@bag.python.org> Author: christian.heimes Date: Wed Jan 30 14:42:22 2008 New Revision: 60446 Modified: python/branches/trunk-math/ (props changed) python/branches/trunk-math/Doc/c-api/set.rst python/branches/trunk-math/Doc/c-api/type.rst python/branches/trunk-math/Doc/conf.py python/branches/trunk-math/Doc/library/sys.rst python/branches/trunk-math/Doc/tools/sphinxext/ (props changed) python/branches/trunk-math/Doc/tutorial/errors.rst python/branches/trunk-math/Include/object.h python/branches/trunk-math/Include/setobject.h python/branches/trunk-math/Include/unicodeobject.h python/branches/trunk-math/Lib/_abcoll.py python/branches/trunk-math/Lib/ctypes/test/test_funcptr.py python/branches/trunk-math/Lib/optparse.py python/branches/trunk-math/Lib/pydoc.py python/branches/trunk-math/Lib/rational.py python/branches/trunk-math/Lib/test/regrtest.py python/branches/trunk-math/Lib/test/test_builtin.py python/branches/trunk-math/Lib/test/test_resource.py python/branches/trunk-math/Lib/test/test_xmlrpc.py python/branches/trunk-math/Makefile.pre.in python/branches/trunk-math/Misc/NEWS python/branches/trunk-math/Misc/Vim/python.vim python/branches/trunk-math/Misc/Vim/syntax_test.py python/branches/trunk-math/Misc/Vim/vim_syntax.py python/branches/trunk-math/Modules/_ctypes/_ctypes.c python/branches/trunk-math/Modules/_ctypes/callbacks.c python/branches/trunk-math/Objects/abstract.c python/branches/trunk-math/Objects/complexobject.c python/branches/trunk-math/Objects/fileobject.c python/branches/trunk-math/Objects/floatobject.c python/branches/trunk-math/Objects/setobject.c python/branches/trunk-math/Objects/typeobject.c python/branches/trunk-math/Objects/unicodeobject.c python/branches/trunk-math/Python/bltinmodule.c python/branches/trunk-math/Python/compile.c python/branches/trunk-math/Python/marshal.c python/branches/trunk-math/Python/pythonrun.c python/branches/trunk-math/Python/sysmodule.c python/branches/trunk-math/setup.py Log: Merged revisions 60364-60444 via svnmerge from svn+ssh://pythondev at svn.python.org/python/trunk ........ r60364 | neal.norwitz | 2008-01-27 19:09:48 +0100 (Sun, 27 Jan 2008) | 4 lines Update the comment and remove the close. If we close we can't flush anymore. We might still need to close after the for loop if flushing 6! times still doesn't cause the signal/exception. ........ r60365 | georg.brandl | 2008-01-27 19:14:43 +0100 (Sun, 27 Jan 2008) | 2 lines Remove effectless expression statement. ........ r60367 | neal.norwitz | 2008-01-27 19:19:04 +0100 (Sun, 27 Jan 2008) | 1 line Try to handle socket.errors properly in is_unavailable ........ r60370 | christian.heimes | 2008-01-27 20:01:45 +0100 (Sun, 27 Jan 2008) | 1 line Change isbasestring function as discussed on the cvs list a while ago ........ r60372 | neal.norwitz | 2008-01-27 21:03:13 +0100 (Sun, 27 Jan 2008) | 3 lines socket.error doesn't have a headers attribute like ProtocolError. Handle that situation where we catch socket.errors. ........ r60375 | georg.brandl | 2008-01-27 21:25:12 +0100 (Sun, 27 Jan 2008) | 2 lines Add refcounting extension to build config. ........ r60377 | jeffrey.yasskin | 2008-01-28 00:08:46 +0100 (Mon, 28 Jan 2008) | 6 lines Moved Rational._binary_float_to_ratio() to float.as_integer_ratio() because it's useful outside of rational numbers. This is my first C code that had to do anything significant. Please be more careful when looking over it. ........ r60378 | christian.heimes | 2008-01-28 00:34:59 +0100 (Mon, 28 Jan 2008) | 1 line Added clear cache methods to clear the internal type lookup cache for ref leak test runs. ........ r60381 | christian.heimes | 2008-01-28 03:07:53 +0100 (Mon, 28 Jan 2008) | 1 line static PyObject* variables should use PyString_InternFromString() instead of PyObject_FromString() to store a python string in a function level static var. ........ r60388 | thomas.heller | 2008-01-28 09:44:13 +0100 (Mon, 28 Jan 2008) | 1 line Revert rev. 59925, it breaks comtypes (I need to further examine this). ........ r60397 | raymond.hettinger | 2008-01-28 21:34:33 +0100 (Mon, 28 Jan 2008) | 5 lines Make PySet_Add() work with frozensets. Works like PyTuple_SetItem() to build-up values in a brand new frozenset. Also, PyFrozenSet_New() is now guaranteed to produce a distinct new frozenset. ........ r60398 | raymond.hettinger | 2008-01-28 22:34:30 +0100 (Mon, 28 Jan 2008) | 1 line Let marshal built-up sets and frozensets one element at a time (without creating an intermediate tuple). ........ r60399 | raymond.hettinger | 2008-01-28 22:47:42 +0100 (Mon, 28 Jan 2008) | 1 line Factor-out common code with a new macro ........ r60400 | raymond.hettinger | 2008-01-28 22:48:07 +0100 (Mon, 28 Jan 2008) | 1 line Factor-out common code with a new macro ........ r60401 | raymond.hettinger | 2008-01-28 22:51:25 +0100 (Mon, 28 Jan 2008) | 1 line Removed unnecessary conditional (spotted by Neal Norwitz). ........ r60403 | gregory.p.smith | 2008-01-29 00:21:00 +0100 (Tue, 29 Jan 2008) | 4 lines Disable use of BerkeleyDB 4.6.x to see what the odd platform buildbots think. In particular, neal norwitz has traced an Ubuntu sparc64 crash to the Lib/test/bsddb/test_basics.py test when opening a db with DB_THREAD. ........ r60405 | brett.cannon | 2008-01-29 05:13:07 +0100 (Tue, 29 Jan 2008) | 2 lines Fix the reindent rule to use $(BUILDPYTHON). ........ r60406 | brett.cannon | 2008-01-29 05:18:04 +0100 (Tue, 29 Jan 2008) | 3 lines Update Vim syntax highlighting to specify what revision was used to generate the file. ........ r60407 | brett.cannon | 2008-01-29 05:20:56 +0100 (Tue, 29 Jan 2008) | 2 lines Ignore .pyc and .pyo files. ........ r60425 | raymond.hettinger | 2008-01-29 20:52:09 +0100 (Tue, 29 Jan 2008) | 1 line CallMethod is faster with a NULL third-argument than with an empty format string. ........ r60431 | raymond.hettinger | 2008-01-30 01:01:07 +0100 (Wed, 30 Jan 2008) | 1 line Add isdisjoint() to the Set/MutableSet ABCs. ........ r60432 | raymond.hettinger | 2008-01-30 01:08:31 +0100 (Wed, 30 Jan 2008) | 1 line MutableSets support a remove() method. ........ r60433 | raymond.hettinger | 2008-01-30 01:51:58 +0100 (Wed, 30 Jan 2008) | 1 line Demonstrate new except/as syntax. ........ r60440 | christian.heimes | 2008-01-30 12:32:37 +0100 (Wed, 30 Jan 2008) | 1 line Patch #1970 by Antoine Pitrou: Speedup unicode whitespace and linebreak detection. The speedup is about 25% for split() (571 / 457 usec) and 35% (175 / 127 usec )for splitlines() ........ r60441 | christian.heimes | 2008-01-30 12:46:00 +0100 (Wed, 30 Jan 2008) | 1 line Removed unused var ........ Modified: python/branches/trunk-math/Doc/c-api/set.rst ============================================================================== --- python/branches/trunk-math/Doc/c-api/set.rst (original) +++ python/branches/trunk-math/Doc/c-api/set.rst Wed Jan 30 14:42:22 2008 @@ -52,6 +52,12 @@ the constructor functions work with any iterable Python object. +.. cfunction:: int PySet_Check(PyObject *p) + + Return true if *p* is a :class:`set` object or an instance of a subtype. + + .. versionadded:: 2.6 + .. cfunction:: int PyAnySet_Check(PyObject *p) Return true if *p* is a :class:`set` object, a :class:`frozenset` object, or an @@ -86,6 +92,11 @@ set on success or *NULL* on failure. Raise :exc:`TypeError` if *iterable* is not actually iterable. + .. versionchanged:: 2.6 + Now guaranteed to return a brand-new :class:`frozenset`. Formerly, + frozensets of zero-length were a singleton. This got in the way of + building-up new frozensets with :meth:`PySet_Add`. + The following functions and macros are available for instances of :class:`set` or :class:`frozenset` or instances of their subtypes. @@ -112,9 +123,6 @@ the *key* is unhashable. Raise :exc:`PyExc_SystemError` if *anyset* is not a :class:`set`, :class:`frozenset`, or an instance of a subtype. -The following functions are available for instances of :class:`set` or its -subtypes but not for instances of :class:`frozenset` or its subtypes. - .. cfunction:: int PySet_Add(PyObject *set, PyObject *key) @@ -124,6 +132,14 @@ Raise a :exc:`SystemError` if *set* is an not an instance of :class:`set` or its subtype. + .. versionchanged:: 2.6 + Now works with instances of :class:`frozenset` or its subtypes. + Like :cfunc:`PyTuple_SetItem` in that it can be used to fill-in the + values of brand new frozensets before they are exposed to other code. + +The following functions are available for instances of :class:`set` or its +subtypes but not for instances of :class:`frozenset` or its subtypes. + .. cfunction:: int PySet_Discard(PyObject *set, PyObject *key) Modified: python/branches/trunk-math/Doc/c-api/type.rst ============================================================================== --- python/branches/trunk-math/Doc/c-api/type.rst (original) +++ python/branches/trunk-math/Doc/c-api/type.rst Wed Jan 30 14:42:22 2008 @@ -35,6 +35,13 @@ .. versionadded:: 2.2 +.. cfunction:: unsigned int PyType_ClearCache(void) + + Clears the internal lookup cache. Return the current version tag. + + .. versionadded:: 2.6 + + .. cfunction:: int PyType_HasFeature(PyObject *o, int feature) Return true if the type object *o* sets the feature *feature*. Type features Modified: python/branches/trunk-math/Doc/conf.py ============================================================================== --- python/branches/trunk-math/Doc/conf.py (original) +++ python/branches/trunk-math/Doc/conf.py Wed Jan 30 14:42:22 2008 @@ -13,6 +13,8 @@ # General configuration # --------------------- +extensions = ['sphinx.addons.refcounting'] + # General substitutions. project = 'Python' copyright = '1990-%s, Python Software Foundation' % time.strftime('%Y') Modified: python/branches/trunk-math/Doc/library/sys.rst ============================================================================== --- python/branches/trunk-math/Doc/library/sys.rst (original) +++ python/branches/trunk-math/Doc/library/sys.rst Wed Jan 30 14:42:22 2008 @@ -58,6 +58,13 @@ A string containing the copyright pertaining to the Python interpreter. +.. function:: _cleartypecache() + + Clear the internal type lookup cache. + + .. versionadded:: 2.6 + + .. function:: _current_frames() Return a dictionary mapping each thread's identifier to the topmost stack frame Modified: python/branches/trunk-math/Doc/tutorial/errors.rst ============================================================================== --- python/branches/trunk-math/Doc/tutorial/errors.rst (original) +++ python/branches/trunk-math/Doc/tutorial/errors.rst Wed Jan 30 14:42:22 2008 @@ -131,7 +131,7 @@ f = open('myfile.txt') s = f.readline() i = int(s.strip()) - except IOError, (errno, strerror): + except IOError as (errno, strerror): print "I/O error(%s): %s" % (errno, strerror) except ValueError: print "Could not convert data to an integer." @@ -176,7 +176,7 @@ >>> try: ... raise Exception('spam', 'eggs') - ... except Exception, inst: + ... except Exception as inst: ... print type(inst) # the exception instance ... print inst.args # arguments stored in .args ... print inst # __str__ allows args to printed directly @@ -202,7 +202,7 @@ ... >>> try: ... this_fails() - ... except ZeroDivisionError, detail: + ... except ZeroDivisionError as detail: ... print 'Handling run-time error:', detail ... Handling run-time error: integer division or modulo by zero @@ -259,7 +259,7 @@ ... >>> try: ... raise MyError(2*2) - ... except MyError, e: + ... except MyError as e: ... print 'My exception occurred, value:', e.value ... My exception occurred, value: 4 Modified: python/branches/trunk-math/Include/object.h ============================================================================== --- python/branches/trunk-math/Include/object.h (original) +++ python/branches/trunk-math/Include/object.h Wed Jan 30 14:42:22 2008 @@ -399,6 +399,7 @@ PyAPI_FUNC(PyObject *) PyType_GenericNew(PyTypeObject *, PyObject *, PyObject *); PyAPI_FUNC(PyObject *) _PyType_Lookup(PyTypeObject *, PyObject *); +PyAPI_FUNC(unsigned int) PyType_ClearCache(void); /* Generic operations on objects */ PyAPI_FUNC(int) PyObject_Print(PyObject *, FILE *, int); Modified: python/branches/trunk-math/Include/setobject.h ============================================================================== --- python/branches/trunk-math/Include/setobject.h (original) +++ python/branches/trunk-math/Include/setobject.h Wed Jan 30 14:42:22 2008 @@ -73,6 +73,8 @@ (Py_TYPE(ob) == &PySet_Type || Py_TYPE(ob) == &PyFrozenSet_Type || \ PyType_IsSubtype(Py_TYPE(ob), &PySet_Type) || \ PyType_IsSubtype(Py_TYPE(ob), &PyFrozenSet_Type)) +#define PySet_Check(ob) \ + (Py_TYPE(ob) == &PySet_Type || PyType_IsSubtype(Py_TYPE(ob), &PySet_Type)) PyAPI_FUNC(PyObject *) PySet_New(PyObject *); PyAPI_FUNC(PyObject *) PyFrozenSet_New(PyObject *); Modified: python/branches/trunk-math/Include/unicodeobject.h ============================================================================== --- python/branches/trunk-math/Include/unicodeobject.h (original) +++ python/branches/trunk-math/Include/unicodeobject.h Wed Jan 30 14:42:22 2008 @@ -348,7 +348,14 @@ #else -#define Py_UNICODE_ISSPACE(ch) _PyUnicode_IsWhitespace(ch) +/* Since splitting on whitespace is an important use case, and whitespace + in most situations is solely ASCII whitespace, we optimize for the common + case by using a quick look-up table with an inlined check. + */ +extern const unsigned char _Py_ascii_whitespace[]; + +#define Py_UNICODE_ISSPACE(ch) \ + ((ch) < 128U ? _Py_ascii_whitespace[(ch)] : _PyUnicode_IsWhitespace(ch)) #define Py_UNICODE_ISLOWER(ch) _PyUnicode_IsLowercase(ch) #define Py_UNICODE_ISUPPER(ch) _PyUnicode_IsUppercase(ch) Modified: python/branches/trunk-math/Lib/_abcoll.py ============================================================================== --- python/branches/trunk-math/Lib/_abcoll.py (original) +++ python/branches/trunk-math/Lib/_abcoll.py Wed Jan 30 14:42:22 2008 @@ -177,6 +177,12 @@ return NotImplemented return self._from_iterable(value for value in other if value in self) + def isdisjoint(self, other): + for value in other: + if value in self: + return False + return True + def __or__(self, other): if not isinstance(other, Iterable): return NotImplemented @@ -244,6 +250,12 @@ """Return True if it was deleted, False if not there.""" raise NotImplementedError + def remove(self, value): + """Remove an element. If not a member, raise a KeyError.""" + if value not in self: + raise KeyError(value) + self.discard(value) + def pop(self): """Return the popped value. Raise KeyError if empty.""" it = iter(self) Modified: python/branches/trunk-math/Lib/ctypes/test/test_funcptr.py ============================================================================== --- python/branches/trunk-math/Lib/ctypes/test/test_funcptr.py (original) +++ python/branches/trunk-math/Lib/ctypes/test/test_funcptr.py Wed Jan 30 14:42:22 2008 @@ -123,11 +123,5 @@ self.failUnlessEqual(strtok(None, "\n"), "c") self.failUnlessEqual(strtok(None, "\n"), None) - def test_NULL_funcptr(self): - tp = CFUNCTYPE(c_int) - func = tp() # NULL function pointer - # raise a ValueError when we try to call it - self.assertRaises(ValueError, func) - if __name__ == '__main__': unittest.main() Modified: python/branches/trunk-math/Lib/optparse.py ============================================================================== --- python/branches/trunk-math/Lib/optparse.py (original) +++ python/branches/trunk-math/Lib/optparse.py Wed Jan 30 14:42:22 2008 @@ -823,12 +823,14 @@ except NameError: (True, False) = (1, 0) -def isbasestring(x): - try: +try: + basestring +except NameError: + def isbasestring(x): + return isinstance(x, (types.StringType, types.UnicodeType)) +else: + def isbasestring(x): return isinstance(x, basestring) - except: - return isinstance(x, types.StringType) or isinstance(x, types.UnicodeType) - class Values: Modified: python/branches/trunk-math/Lib/pydoc.py ============================================================================== --- python/branches/trunk-math/Lib/pydoc.py (original) +++ python/branches/trunk-math/Lib/pydoc.py Wed Jan 30 14:42:22 2008 @@ -1197,7 +1197,6 @@ else: tag = "inherited from %s" % classname(thisclass, object.__module__) - filter(lambda t: not t[0].startswith('_'), attrs) # Sort attrs by name. attrs.sort() Modified: python/branches/trunk-math/Lib/rational.py ============================================================================== --- python/branches/trunk-math/Lib/rational.py (original) +++ python/branches/trunk-math/Lib/rational.py Wed Jan 30 14:42:22 2008 @@ -25,60 +25,6 @@ return a -def _binary_float_to_ratio(x): - """x -> (top, bot), a pair of ints s.t. x = top/bot. - - The conversion is done exactly, without rounding. - bot > 0 guaranteed. - Some form of binary fp is assumed. - Pass NaNs or infinities at your own risk. - - >>> _binary_float_to_ratio(10.0) - (10, 1) - >>> _binary_float_to_ratio(0.0) - (0, 1) - >>> _binary_float_to_ratio(-.25) - (-1, 4) - """ - # XXX Move this to floatobject.c with a name like - # float.as_integer_ratio() - - if x == 0: - return 0, 1 - f, e = math.frexp(x) - signbit = 1 - if f < 0: - f = -f - signbit = -1 - assert 0.5 <= f < 1.0 - # x = signbit * f * 2**e exactly - - # Suck up CHUNK bits at a time; 28 is enough so that we suck - # up all bits in 2 iterations for all known binary double- - # precision formats, and small enough to fit in an int. - CHUNK = 28 - top = 0 - # invariant: x = signbit * (top + f) * 2**e exactly - while f: - f = math.ldexp(f, CHUNK) - digit = trunc(f) - assert digit >> CHUNK == 0 - top = (top << CHUNK) | digit - f = f - digit - assert 0.0 <= f < 1.0 - e = e - CHUNK - assert top - - # Add in the sign bit. - top = signbit * top - - # now x = top * 2**e exactly; fold in 2**e - if e>0: - return (top * 2**e, 1) - else: - return (top, 2 ** -e) - - _RATIONAL_FORMAT = re.compile( r'^\s*(?P[-+]?)(?P\d+)' r'(?:/(?P\d+)|\.(?P\d+))?\s*$') @@ -163,7 +109,7 @@ (cls.__name__, f, type(f).__name__)) if math.isnan(f) or math.isinf(f): raise TypeError("Cannot convert %r to %s." % (f, cls.__name__)) - return cls(*_binary_float_to_ratio(f)) + return cls(*f.as_integer_ratio()) @classmethod def from_decimal(cls, dec): Modified: python/branches/trunk-math/Lib/test/regrtest.py ============================================================================== --- python/branches/trunk-math/Lib/test/regrtest.py (original) +++ python/branches/trunk-math/Lib/test/regrtest.py Wed Jan 30 14:42:22 2008 @@ -709,6 +709,9 @@ sys.path_importer_cache.clear() sys.path_importer_cache.update(pic) + # clear type cache + sys._cleartypecache() + # Clear ABC registries, restoring previously saved ABC registries. for abc in [getattr(_abcoll, a) for a in _abcoll.__all__]: if not issubclass(abc, _Abstract): Modified: python/branches/trunk-math/Lib/test/test_builtin.py ============================================================================== --- python/branches/trunk-math/Lib/test/test_builtin.py (original) +++ python/branches/trunk-math/Lib/test/test_builtin.py Wed Jan 30 14:42:22 2008 @@ -5,7 +5,7 @@ run_unittest, run_with_locale from operator import neg -import sys, warnings, cStringIO, random, UserDict +import sys, warnings, cStringIO, random, rational, UserDict warnings.filterwarnings("ignore", "hex../oct.. of negative int", FutureWarning, __name__) warnings.filterwarnings("ignore", "integer argument expected", @@ -688,6 +688,25 @@ self.assertAlmostEqual(float(Foo3(21)), 42.) self.assertRaises(TypeError, float, Foo4(42)) + def test_floatasratio(self): + R = rational.Rational + self.assertEqual(R(0, 1), + R(*float(0.0).as_integer_ratio())) + self.assertEqual(R(5, 2), + R(*float(2.5).as_integer_ratio())) + self.assertEqual(R(1, 2), + R(*float(0.5).as_integer_ratio())) + self.assertEqual(R(4728779608739021, 2251799813685248), + R(*float(2.1).as_integer_ratio())) + self.assertEqual(R(-4728779608739021, 2251799813685248), + R(*float(-2.1).as_integer_ratio())) + self.assertEqual(R(-2100, 1), + R(*float(-2100.0).as_integer_ratio())) + + self.assertRaises(OverflowError, float('inf').as_integer_ratio) + self.assertRaises(OverflowError, float('-inf').as_integer_ratio) + self.assertRaises(ValueError, float('nan').as_integer_ratio) + def test_getattr(self): import sys self.assert_(getattr(sys, 'stdout') is sys.stdout) Modified: python/branches/trunk-math/Lib/test/test_resource.py ============================================================================== --- python/branches/trunk-math/Lib/test/test_resource.py (original) +++ python/branches/trunk-math/Lib/test/test_resource.py Wed Jan 30 14:42:22 2008 @@ -56,13 +56,12 @@ f.flush() # On some systems (e.g., Ubuntu on hppa) the flush() # doesn't always cause the exception, but the close() - # does eventually. Try closing several times in + # does eventually. Try flushing several times in # an attempt to ensure the file is really synced and # the exception raised. for i in range(5): time.sleep(.1) f.flush() - f.close() except IOError: if not limit_set: raise Modified: python/branches/trunk-math/Lib/test/test_xmlrpc.py ============================================================================== --- python/branches/trunk-math/Lib/test/test_xmlrpc.py (original) +++ python/branches/trunk-math/Lib/test/test_xmlrpc.py Wed Jan 30 14:42:22 2008 @@ -348,10 +348,14 @@ given by operations on non-blocking sockets.''' # sometimes we get a -1 error code and/or empty headers - if e.errcode == -1 or e.headers is None: - return True + try: + if e.errcode == -1 or e.headers is None: + return True + exc_mess = e.headers.get('X-exception') + except AttributeError: + # Ignore socket.errors here. + exc_mess = str(e) - exc_mess = e.headers.get('X-exception') if exc_mess and 'temporarily unavailable' in exc_mess.lower(): return True @@ -393,7 +397,7 @@ # ignore failures due to non-blocking socket 'unavailable' errors if not is_unavailable_exception(e): # protocol error; provide additional information in test output - self.fail("%s\n%s" % (e, e.headers)) + self.fail("%s\n%s" % (e, getattr(e, "headers", ""))) # [ch] The test 404 is causing lots of false alarms. def XXXtest_404(self): @@ -419,7 +423,7 @@ # ignore failures due to non-blocking socket 'unavailable' errors if not is_unavailable_exception(e): # protocol error; provide additional information in test output - self.fail("%s\n%s" % (e, e.headers)) + self.fail("%s\n%s" % (e, getattr(e, "headers", ""))) def test_introspection2(self): try: @@ -431,7 +435,7 @@ # ignore failures due to non-blocking socket 'unavailable' errors if not is_unavailable_exception(e): # protocol error; provide additional information in test output - self.fail("%s\n%s" % (e, e.headers)) + self.fail("%s\n%s" % (e, getattr(e, "headers", ""))) def test_introspection3(self): try: @@ -443,7 +447,7 @@ # ignore failures due to non-blocking socket 'unavailable' errors if not is_unavailable_exception(e): # protocol error; provide additional information in test output - self.fail("%s\n%s" % (e, e.headers)) + self.fail("%s\n%s" % (e, getattr(e, "headers", ""))) def test_introspection4(self): # the SimpleXMLRPCServer doesn't support signatures, but @@ -456,7 +460,7 @@ # ignore failures due to non-blocking socket 'unavailable' errors if not is_unavailable_exception(e): # protocol error; provide additional information in test output - self.fail("%s\n%s" % (e, e.headers)) + self.fail("%s\n%s" % (e, getattr(e, "headers", ""))) def test_multicall(self): try: @@ -473,7 +477,7 @@ # ignore failures due to non-blocking socket 'unavailable' errors if not is_unavailable_exception(e): # protocol error; provide additional information in test output - self.fail("%s\n%s" % (e, e.headers)) + self.fail("%s\n%s" % (e, getattr(e, "headers", ""))) def test_non_existing_multicall(self): try: @@ -494,7 +498,7 @@ # ignore failures due to non-blocking socket 'unavailable' errors if not is_unavailable_exception(e): # protocol error; provide additional information in test output - self.fail("%s\n%s" % (e, e.headers)) + self.fail("%s\n%s" % (e, getattr(e, "headers", ""))) def test_dotted_attribute(self): # this will raise AttirebuteError because code don't want us to use @@ -549,7 +553,7 @@ # ignore failures due to non-blocking socket 'unavailable' errors if not is_unavailable_exception(e): # protocol error; provide additional information in test output - self.fail("%s\n%s" % (e, e.headers)) + self.fail("%s\n%s" % (e, getattr(e, "headers", ""))) def test_fail_no_info(self): # use the broken message class @@ -560,7 +564,7 @@ p.pow(6,8) except (xmlrpclib.ProtocolError, socket.error), e: # ignore failures due to non-blocking socket 'unavailable' errors - if not is_unavailable_exception(e): + if not is_unavailable_exception(e) and hasattr(e, "headers"): # The two server-side error headers shouldn't be sent back in this case self.assertTrue(e.headers.get("X-exception") is None) self.assertTrue(e.headers.get("X-traceback") is None) @@ -580,7 +584,7 @@ p.pow(6,8) except (xmlrpclib.ProtocolError, socket.error), e: # ignore failures due to non-blocking socket 'unavailable' errors - if not is_unavailable_exception(e): + if not is_unavailable_exception(e) and hasattr(e, "headers"): # We should get error info in the response expected_err = "invalid literal for int() with base 10: 'I am broken'" self.assertEqual(e.headers.get("x-exception"), expected_err) Modified: python/branches/trunk-math/Makefile.pre.in ============================================================================== --- python/branches/trunk-math/Makefile.pre.in (original) +++ python/branches/trunk-math/Makefile.pre.in Wed Jan 30 14:42:22 2008 @@ -1027,7 +1027,7 @@ # Run reindent on the library reindent: - ./python$(EXEEXT) $(srcdir)/Tools/scripts/reindent.py -r $(srcdir)/Lib + ./$(BUILDPYTHON) $(srcdir)/Tools/scripts/reindent.py -r $(srcdir)/Lib # Rerun configure with the same options as it was run last time, # provided the config.status script exists Modified: python/branches/trunk-math/Misc/NEWS ============================================================================== --- python/branches/trunk-math/Misc/NEWS (original) +++ python/branches/trunk-math/Misc/NEWS Wed Jan 30 14:42:22 2008 @@ -20,6 +20,12 @@ without the four functions and copysign in libm were added to a new file Python/pymath.c. +- Patch #1970 by Antoine Pitrou: Speedup unicode whitespace and linebreak + detection + +- Added ``PyType_ClearCache()`` and ``sys._cleartypecache`` to clear the + internal lookup cache for ref leak tests. + - Patch #1473257: generator objects gain a gi_code attribute. This is the same object as the func_code attribute of the function that produced the generator. Modified: python/branches/trunk-math/Misc/Vim/python.vim ============================================================================== --- python/branches/trunk-math/Misc/Vim/python.vim (original) +++ python/branches/trunk-math/Misc/Vim/python.vim Wed Jan 30 14:42:22 2008 @@ -1,4 +1,4 @@ -" Auto-generated Vim syntax file for Python +" Auto-generated Vim syntax file for Python (trunk: r60376M). " " To use: copy or symlink to ~/.vim/syntax/python.vim @@ -64,7 +64,7 @@ if exists("python_highlight_builtins") syn keyword pythonBuiltin Ellipsis False None NotImplemented True __debug__ syn keyword pythonBuiltin __import__ abs all any apply basestring bool - syn keyword pythonBuiltin buffer callable chr classmethod cmp coerce + syn keyword pythonBuiltin buffer bytes callable chr classmethod cmp coerce syn keyword pythonBuiltin compile complex copyright credits delattr dict syn keyword pythonBuiltin dir divmod enumerate eval execfile exit file syn keyword pythonBuiltin filter float frozenset getattr globals hasattr @@ -73,7 +73,8 @@ syn keyword pythonBuiltin max min object oct open ord pow property quit syn keyword pythonBuiltin range raw_input reduce reload repr reversed round syn keyword pythonBuiltin set setattr slice sorted staticmethod str sum - syn keyword pythonBuiltin super tuple type unichr unicode vars xrange zip + syn keyword pythonBuiltin super trunc tuple type unichr unicode vars xrange + syn keyword pythonBuiltin zip endif Modified: python/branches/trunk-math/Misc/Vim/syntax_test.py ============================================================================== --- python/branches/trunk-math/Misc/Vim/syntax_test.py (original) +++ python/branches/trunk-math/Misc/Vim/syntax_test.py Wed Jan 30 14:42:22 2008 @@ -4,9 +4,8 @@ Not necessarily sensical or comprehensive (assume that if one exception is highlighted that all are, for instance). -Highlighting extraneous whitespace at the end of the line is not represented -here as all trailing whitespace is automatically removed from .py files in the -repository. +Extraneous trailing whitespace can't be tested because of svn pre-commit hook +checks for such things. """ # Comment Modified: python/branches/trunk-math/Misc/Vim/vim_syntax.py ============================================================================== --- python/branches/trunk-math/Misc/Vim/vim_syntax.py (original) +++ python/branches/trunk-math/Misc/Vim/vim_syntax.py Wed Jan 30 14:42:22 2008 @@ -4,8 +4,9 @@ import exceptions import __builtin__ from string import Template +from sys import subversion -comment_header = '''" Auto-generated Vim syntax file for Python. +comment_header = '''" Auto-generated Vim syntax file for Python (%s: r%s). " " To use: copy or symlink to ~/.vim/syntax/python.vim''' @@ -160,7 +161,7 @@ def main(file_path): with open(file_path, 'w') as FILE: # Comment for file - print>>FILE, comment_header + print>>FILE, comment_header % subversion[1:] print>>FILE, '' # Statements at start of file print>>FILE, statement_header Modified: python/branches/trunk-math/Modules/_ctypes/_ctypes.c ============================================================================== --- python/branches/trunk-math/Modules/_ctypes/_ctypes.c (original) +++ python/branches/trunk-math/Modules/_ctypes/_ctypes.c Wed Jan 30 14:42:22 2008 @@ -1529,9 +1529,9 @@ if (suffix == NULL) #ifdef WORDS_BIGENDIAN - suffix = PyString_FromString("_le"); + suffix = PyString_InternFromString("_le"); #else - suffix = PyString_FromString("_be"); + suffix = PyString_InternFromString("_be"); #endif Py_INCREF(name); @@ -3435,11 +3435,6 @@ pProc = *(void **)self->b_ptr; - if (pProc == NULL) { - PyErr_SetString(PyExc_ValueError, - "attempt to call NULL function pointer"); - return NULL; - } #ifdef MS_WIN32 if (self->index) { /* It's a COM method */ @@ -4416,7 +4411,7 @@ } if (format == NULL) { - format = PyString_FromString("%s(%r)"); + format = PyString_InternFromString("%s(%r)"); if (format == NULL) return NULL; } Modified: python/branches/trunk-math/Modules/_ctypes/callbacks.c ============================================================================== --- python/branches/trunk-math/Modules/_ctypes/callbacks.c (original) +++ python/branches/trunk-math/Modules/_ctypes/callbacks.c Wed Jan 30 14:42:22 2008 @@ -368,7 +368,7 @@ static PyObject *context; if (context == NULL) - context = PyString_FromString("_ctypes.DllGetClassObject"); + context = PyString_InternFromString("_ctypes.DllGetClassObject"); mod = PyImport_ImportModuleNoBlock("ctypes"); if (!mod) { @@ -447,7 +447,7 @@ static PyObject *context; if (context == NULL) - context = PyString_FromString("_ctypes.DllCanUnloadNow"); + context = PyString_InternFromString("_ctypes.DllCanUnloadNow"); mod = PyImport_ImportModuleNoBlock("ctypes"); if (!mod) { Modified: python/branches/trunk-math/Objects/abstract.c ============================================================================== --- python/branches/trunk-math/Objects/abstract.c (original) +++ python/branches/trunk-math/Objects/abstract.c Wed Jan 30 14:42:22 2008 @@ -2142,7 +2142,7 @@ PyObject *bases; if (__bases__ == NULL) { - __bases__ = PyString_FromString("__bases__"); + __bases__ = PyString_InternFromString("__bases__"); if (__bases__ == NULL) return NULL; } @@ -2220,7 +2220,7 @@ int retval = 0; if (__class__ == NULL) { - __class__ = PyString_FromString("__class__"); + __class__ = PyString_InternFromString("__class__"); if (__class__ == NULL) return -1; } Modified: python/branches/trunk-math/Objects/complexobject.c ============================================================================== --- python/branches/trunk-math/Objects/complexobject.c (original) +++ python/branches/trunk-math/Objects/complexobject.c Wed Jan 30 14:42:22 2008 @@ -261,14 +261,19 @@ return ((PyComplexObject *)op)->cval; } /* If not, use op's __complex__ method, if it exists */ - + /* return -1 on failure */ cv.real = -1.; cv.imag = 0.; + + if (complex_str == NULL) { + if (!(complex_str = PyString_InternFromString("__complex__"))) + return cv; + } if (PyInstance_Check(op)) { /* this can go away in python 3000 */ - if (PyObject_HasAttrString(op, "__complex__")) { + if (PyObject_HasAttr(op, complex_str)) { newop = PyObject_CallMethod(op, "__complex__", NULL); if (!newop) return cv; @@ -276,10 +281,6 @@ /* else try __float__ */ } else { PyObject *complexfunc; - if (!complex_str) { - if (!(complex_str = PyString_FromString("__complex__"))) - return cv; - } complexfunc = _PyType_Lookup(op->ob_type, complex_str); /* complexfunc is a borrowed reference */ if (complexfunc) { Modified: python/branches/trunk-math/Objects/fileobject.c ============================================================================== --- python/branches/trunk-math/Objects/fileobject.c (original) +++ python/branches/trunk-math/Objects/fileobject.c Wed Jan 30 14:42:22 2008 @@ -1965,7 +1965,7 @@ assert(type != NULL && type->tp_alloc != NULL); if (not_yet_string == NULL) { - not_yet_string = PyString_FromString(""); + not_yet_string = PyString_InternFromString(""); if (not_yet_string == NULL) return NULL; } Modified: python/branches/trunk-math/Objects/floatobject.c ============================================================================== --- python/branches/trunk-math/Objects/floatobject.c (original) +++ python/branches/trunk-math/Objects/floatobject.c Wed Jan 30 14:42:22 2008 @@ -1153,6 +1153,163 @@ return v; } +static PyObject * +float_as_integer_ratio(PyObject *v) +{ + double self; + double float_part; + int exponent; + int is_negative; + const int chunk_size = 28; + PyObject *prev; + PyObject *py_chunk = NULL; + PyObject *py_exponent = NULL; + PyObject *numerator = NULL; + PyObject *denominator = NULL; + PyObject *result_pair = NULL; + PyNumberMethods *long_methods; + +#define INPLACE_UPDATE(obj, call) \ + prev = obj; \ + obj = call; \ + Py_DECREF(prev); \ + + CONVERT_TO_DOUBLE(v, self); + + if (Py_IS_INFINITY(self)) { + PyErr_SetString(PyExc_OverflowError, + "Cannot pass infinity to float.as_integer_ratio."); + return NULL; + } +#ifdef Py_NAN + if (Py_IS_NAN(self)) { + PyErr_SetString(PyExc_ValueError, + "Cannot pass nan to float.as_integer_ratio."); + return NULL; + } +#endif + + if (self == 0) { + numerator = PyInt_FromLong(0); + if (numerator == NULL) goto error; + denominator = PyInt_FromLong(1); + if (denominator == NULL) goto error; + result_pair = PyTuple_Pack(2, numerator, denominator); + /* Hand ownership over to the tuple. If the tuple + wasn't created successfully, we want to delete the + ints anyway. */ + Py_DECREF(numerator); + Py_DECREF(denominator); + return result_pair; + } + + /* XXX: Could perhaps handle FLT_RADIX!=2 by using ilogb and + scalbn, but those may not be in C89. */ + PyFPE_START_PROTECT("as_integer_ratio", goto error); + float_part = frexp(self, &exponent); + is_negative = 0; + if (float_part < 0) { + float_part = -float_part; + is_negative = 1; + /* 0.5 <= float_part < 1.0 */ + } + PyFPE_END_PROTECT(float_part); + /* abs(self) == float_part * 2**exponent exactly */ + + /* Suck up chunk_size bits at a time; 28 is enough so that we + suck up all bits in 2 iterations for all known binary + double-precision formats, and small enough to fit in a + long. */ + numerator = PyLong_FromLong(0); + if (numerator == NULL) goto error; + + long_methods = PyLong_Type.tp_as_number; + + py_chunk = PyLong_FromLong(chunk_size); + if (py_chunk == NULL) goto error; + + while (float_part != 0) { + /* invariant: abs(self) == + (numerator + float_part) * 2**exponent exactly */ + long digit; + PyObject *py_digit; + + PyFPE_START_PROTECT("as_integer_ratio", goto error); + /* Pull chunk_size bits out of float_part, into digits. */ + float_part = ldexp(float_part, chunk_size); + digit = (long)float_part; + float_part -= digit; + /* 0 <= float_part < 1 */ + exponent -= chunk_size; + PyFPE_END_PROTECT(float_part); + + /* Shift digits into numerator. */ + // numerator <<= chunk_size + INPLACE_UPDATE(numerator, + long_methods->nb_lshift(numerator, py_chunk)); + if (numerator == NULL) goto error; + + // numerator |= digit + py_digit = PyLong_FromLong(digit); + if (py_digit == NULL) goto error; + INPLACE_UPDATE(numerator, + long_methods->nb_or(numerator, py_digit)); + Py_DECREF(py_digit); + if (numerator == NULL) goto error; + } + + /* Add in the sign bit. */ + if (is_negative) { + INPLACE_UPDATE(numerator, + long_methods->nb_negative(numerator)); + if (numerator == NULL) goto error; + } + + /* now self = numerator * 2**exponent exactly; fold in 2**exponent */ + denominator = PyLong_FromLong(1); + py_exponent = PyLong_FromLong(labs(exponent)); + if (py_exponent == NULL) goto error; + INPLACE_UPDATE(py_exponent, + long_methods->nb_lshift(denominator, py_exponent)); + if (py_exponent == NULL) goto error; + if (exponent > 0) { + INPLACE_UPDATE(numerator, + long_methods->nb_multiply(numerator, + py_exponent)); + if (numerator == NULL) goto error; + } + else { + Py_DECREF(denominator); + denominator = py_exponent; + py_exponent = NULL; + } + + result_pair = PyTuple_Pack(2, numerator, denominator); + +#undef INPLACE_UPDATE +error: + Py_XDECREF(py_exponent); + Py_XDECREF(py_chunk); + Py_XDECREF(denominator); + Py_XDECREF(numerator); + return result_pair; +} + +PyDoc_STRVAR(float_as_integer_ratio_doc, +"float.as_integer_ratio() -> (int, int)\n" +"\n" +"Returns a pair of integers, not necessarily in lowest terms, whose\n" +"ratio is exactly equal to the original float. This method raises an\n" +"OverflowError on infinities and a ValueError on nans. The resulting\n" +"denominator will be positive.\n" +"\n" +">>> (10.0).as_integer_ratio()\n" +"(167772160L, 16777216L)\n" +">>> (0.0).as_integer_ratio()\n" +"(0, 1)\n" +">>> (-.25).as_integer_ratio()\n" +"(-134217728L, 536870912L)"); + static PyObject * float_subtype_new(PyTypeObject *type, PyObject *args, PyObject *kwds); @@ -1341,6 +1498,8 @@ "Returns self, the complex conjugate of any float."}, {"__trunc__", (PyCFunction)float_trunc, METH_NOARGS, "Returns the Integral closest to x between 0 and x."}, + {"as_integer_ratio", (PyCFunction)float_as_integer_ratio, METH_NOARGS, + float_as_integer_ratio_doc}, {"__getnewargs__", (PyCFunction)float_getnewargs, METH_NOARGS}, {"__getformat__", (PyCFunction)float_getformat, METH_O|METH_CLASS, float_getformat_doc}, Modified: python/branches/trunk-math/Objects/setobject.c ============================================================================== --- python/branches/trunk-math/Objects/setobject.c (original) +++ python/branches/trunk-math/Objects/setobject.c Wed Jan 30 14:42:22 2008 @@ -2142,17 +2142,7 @@ PyObject * PyFrozenSet_New(PyObject *iterable) { - PyObject *args, *result; - - if (iterable == NULL) - args = PyTuple_New(0); - else - args = PyTuple_Pack(1, iterable); - if (args == NULL) - return NULL; - result = frozenset_new(&PyFrozenSet_Type, args, NULL); - Py_DECREF(args); - return result; + return make_new_set(&PyFrozenSet_Type, iterable); } Py_ssize_t @@ -2168,7 +2158,7 @@ int PySet_Clear(PyObject *set) { - if (!PyType_IsSubtype(Py_TYPE(set), &PySet_Type)) { + if (!PySet_Check(set)) { PyErr_BadInternalCall(); return -1; } @@ -2188,7 +2178,7 @@ int PySet_Discard(PyObject *set, PyObject *key) { - if (!PyType_IsSubtype(Py_TYPE(set), &PySet_Type)) { + if (!PySet_Check(set)) { PyErr_BadInternalCall(); return -1; } @@ -2196,13 +2186,13 @@ } int -PySet_Add(PyObject *set, PyObject *key) +PySet_Add(PyObject *anyset, PyObject *key) { - if (!PyType_IsSubtype(Py_TYPE(set), &PySet_Type)) { + if (!PyAnySet_Check(anyset)) { PyErr_BadInternalCall(); return -1; } - return set_add_key((PySetObject *)set, key); + return set_add_key((PySetObject *)anyset, key); } int @@ -2239,7 +2229,7 @@ PyObject * PySet_Pop(PyObject *set) { - if (!PyType_IsSubtype(Py_TYPE(set), &PySet_Type)) { + if (!PySet_Check(set)) { PyErr_BadInternalCall(); return NULL; } @@ -2249,7 +2239,7 @@ int _PySet_Update(PyObject *set, PyObject *iterable) { - if (!PyType_IsSubtype(Py_TYPE(set), &PySet_Type)) { + if (!PySet_Check(set)) { PyErr_BadInternalCall(); return -1; } @@ -2345,7 +2335,6 @@ f = PyFrozenSet_New(dup); assert(PySet_Size(f) == 3); assert(PyFrozenSet_CheckExact(f)); - assertRaises(PySet_Add(f, elem) == -1, PyExc_SystemError); assertRaises(PySet_Discard(f, elem) == -1, PyExc_SystemError); assertRaises(PySet_Pop(f) == NULL, PyExc_SystemError); Py_DECREF(f); Modified: python/branches/trunk-math/Objects/typeobject.c ============================================================================== --- python/branches/trunk-math/Objects/typeobject.c (original) +++ python/branches/trunk-math/Objects/typeobject.c Wed Jan 30 14:42:22 2008 @@ -32,6 +32,24 @@ static struct method_cache_entry method_cache[1 << MCACHE_SIZE_EXP]; static unsigned int next_version_tag = 0; +static void type_modified(PyTypeObject *); + +unsigned int +PyType_ClearCache(void) +{ + Py_ssize_t i; + unsigned int cur_version_tag = next_version_tag - 1; + + for (i = 0; i < (1 << MCACHE_SIZE_EXP); i++) { + method_cache[i].version = 0; + Py_CLEAR(method_cache[i].name); + method_cache[i].value = NULL; + } + next_version_tag = 0; + /* mark all version tags as invalid */ + type_modified(&PyBaseObject_Type); + return cur_version_tag; +} static void type_modified(PyTypeObject *type) Modified: python/branches/trunk-math/Objects/unicodeobject.c ============================================================================== --- python/branches/trunk-math/Objects/unicodeobject.c (original) +++ python/branches/trunk-math/Objects/unicodeobject.c Wed Jan 30 14:42:22 2008 @@ -112,6 +112,64 @@ */ static char unicode_default_encoding[100]; +/* Fast detection of the most frequent whitespace characters */ +const unsigned char _Py_ascii_whitespace[] = { + 0, 0, 0, 0, 0, 0, 0, 0, +// case 0x0009: /* HORIZONTAL TABULATION */ +// case 0x000A: /* LINE FEED */ +// case 0x000B: /* VERTICAL TABULATION */ +// case 0x000C: /* FORM FEED */ +// case 0x000D: /* CARRIAGE RETURN */ + 0, 1, 1, 1, 1, 1, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, +// case 0x001C: /* FILE SEPARATOR */ +// case 0x001D: /* GROUP SEPARATOR */ +// case 0x001E: /* RECORD SEPARATOR */ +// case 0x001F: /* UNIT SEPARATOR */ + 0, 0, 0, 0, 1, 1, 1, 1, +// case 0x0020: /* SPACE */ + 1, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0 +}; + +/* Same for linebreaks */ +static unsigned char ascii_linebreak[] = { + 0, 0, 0, 0, 0, 0, 0, 0, +// 0x000A, /* LINE FEED */ +// 0x000D, /* CARRIAGE RETURN */ + 0, 0, 1, 0, 0, 1, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, +// 0x001C, /* FILE SEPARATOR */ +// 0x001D, /* GROUP SEPARATOR */ +// 0x001E, /* RECORD SEPARATOR */ + 0, 0, 0, 0, 1, 1, 1, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0 +}; + + Py_UNICODE PyUnicode_GetMax(void) { @@ -138,8 +196,9 @@ #define BLOOM(mask, ch) ((mask & (1 << ((ch) & 0x1F)))) -#define BLOOM_LINEBREAK(ch)\ - (BLOOM(bloom_linebreak, (ch)) && Py_UNICODE_ISLINEBREAK((ch))) +#define BLOOM_LINEBREAK(ch) \ + ((ch) < 128U ? ascii_linebreak[(ch)] : \ + (BLOOM(bloom_linebreak, (ch)) && Py_UNICODE_ISLINEBREAK(ch))) Py_LOCAL_INLINE(BLOOM_MASK) make_bloom_mask(Py_UNICODE* ptr, Py_ssize_t len) { @@ -5505,25 +5564,26 @@ register Py_ssize_t j; Py_ssize_t len = self->length; PyObject *str; + register const Py_UNICODE *buf = self->str; for (i = j = 0; i < len; ) { /* find a token */ - while (i < len && Py_UNICODE_ISSPACE(self->str[i])) + while (i < len && Py_UNICODE_ISSPACE(buf[i])) i++; j = i; - while (i < len && !Py_UNICODE_ISSPACE(self->str[i])) + while (i < len && !Py_UNICODE_ISSPACE(buf[i])) i++; if (j < i) { if (maxcount-- <= 0) break; - SPLIT_APPEND(self->str, j, i); - while (i < len && Py_UNICODE_ISSPACE(self->str[i])) + SPLIT_APPEND(buf, j, i); + while (i < len && Py_UNICODE_ISSPACE(buf[i])) i++; j = i; } } if (j < len) { - SPLIT_APPEND(self->str, j, len); + SPLIT_APPEND(buf, j, len); } return list; @@ -5596,18 +5656,19 @@ register Py_ssize_t j; Py_ssize_t len = self->length; PyObject *str; + register const Py_UNICODE *buf = self->str; for (i = j = 0; i < len; ) { - if (self->str[i] == ch) { + if (buf[i] == ch) { if (maxcount-- <= 0) break; - SPLIT_APPEND(self->str, j, i); + SPLIT_APPEND(buf, j, i); i = j = i + 1; } else i++; } if (j <= len) { - SPLIT_APPEND(self->str, j, len); + SPLIT_APPEND(buf, j, len); } return list; @@ -5656,25 +5717,26 @@ register Py_ssize_t j; Py_ssize_t len = self->length; PyObject *str; + register const Py_UNICODE *buf = self->str; for (i = j = len - 1; i >= 0; ) { /* find a token */ - while (i >= 0 && Py_UNICODE_ISSPACE(self->str[i])) + while (i >= 0 && Py_UNICODE_ISSPACE(buf[i])) i--; j = i; - while (i >= 0 && !Py_UNICODE_ISSPACE(self->str[i])) + while (i >= 0 && !Py_UNICODE_ISSPACE(buf[i])) i--; if (j > i) { if (maxcount-- <= 0) break; - SPLIT_APPEND(self->str, i + 1, j + 1); - while (i >= 0 && Py_UNICODE_ISSPACE(self->str[i])) + SPLIT_APPEND(buf, i + 1, j + 1); + while (i >= 0 && Py_UNICODE_ISSPACE(buf[i])) i--; j = i; } } if (j >= 0) { - SPLIT_APPEND(self->str, 0, j + 1); + SPLIT_APPEND(buf, 0, j + 1); } if (PyList_Reverse(list) < 0) goto onError; @@ -5695,18 +5757,19 @@ register Py_ssize_t j; Py_ssize_t len = self->length; PyObject *str; + register const Py_UNICODE *buf = self->str; for (i = j = len - 1; i >= 0; ) { - if (self->str[i] == ch) { + if (buf[i] == ch) { if (maxcount-- <= 0) break; - SPLIT_APPEND(self->str, i + 1, j + 1); + SPLIT_APPEND(buf, i + 1, j + 1); j = i = i - 1; } else i--; } if (j >= -1) { - SPLIT_APPEND(self->str, 0, j + 1); + SPLIT_APPEND(buf, 0, j + 1); } if (PyList_Reverse(list) < 0) goto onError; Modified: python/branches/trunk-math/Python/bltinmodule.c ============================================================================== --- python/branches/trunk-math/Python/bltinmodule.c (original) +++ python/branches/trunk-math/Python/bltinmodule.c Wed Jan 30 14:42:22 2008 @@ -2050,7 +2050,7 @@ /* XXX: The py3k branch gets better errors for this by using _PyType_Lookup(), but since float's mro isn't set in py2.6, we just use PyObject_CallMethod here. */ - return PyObject_CallMethod(number, "__trunc__", ""); + return PyObject_CallMethod(number, "__trunc__", NULL); } PyDoc_STRVAR(trunc_doc, Modified: python/branches/trunk-math/Python/compile.c ============================================================================== --- python/branches/trunk-math/Python/compile.c (original) +++ python/branches/trunk-math/Python/compile.c Wed Jan 30 14:42:22 2008 @@ -1153,7 +1153,7 @@ int addNone = 1; static PyObject *module; if (!module) { - module = PyString_FromString(""); + module = PyString_InternFromString(""); if (!module) return NULL; } @@ -2001,7 +2001,7 @@ if (Py_OptimizeFlag) return 1; if (assertion_error == NULL) { - assertion_error = PyString_FromString("AssertionError"); + assertion_error = PyString_InternFromString("AssertionError"); if (assertion_error == NULL) return 0; } Modified: python/branches/trunk-math/Python/marshal.c ============================================================================== --- python/branches/trunk-math/Python/marshal.c (original) +++ python/branches/trunk-math/Python/marshal.c Wed Jan 30 14:42:22 2008 @@ -508,7 +508,7 @@ { /* NULL is a valid return value, it does not necessarily means that an exception is set. */ - PyObject *v, *v2, *v3; + PyObject *v, *v2; long i, n; int type = r_byte(p); PyObject *retval; @@ -860,7 +860,7 @@ retval = NULL; break; } - v = PyTuple_New((int)n); + v = (type == TYPE_SET) ? PySet_New(NULL) : PyFrozenSet_New(NULL); if (v == NULL) { retval = NULL; break; @@ -875,18 +875,14 @@ v = NULL; break; } - PyTuple_SET_ITEM(v, (int)i, v2); + if (PySet_Add(v, v2) == -1) { + Py_DECREF(v); + Py_DECREF(v2); + v = NULL; + break; + } } - if (v == NULL) { - retval = NULL; - break; - } - if (type == TYPE_SET) - v3 = PySet_New(v); - else - v3 = PyFrozenSet_New(v); - Py_DECREF(v); - retval = v3; + retval = v; break; case TYPE_CODE: Modified: python/branches/trunk-math/Python/pythonrun.c ============================================================================== --- python/branches/trunk-math/Python/pythonrun.c (original) +++ python/branches/trunk-math/Python/pythonrun.c Wed Jan 30 14:42:22 2008 @@ -377,6 +377,9 @@ Py_XDECREF(warnings_module); warnings_module = NULL; + /* Clear type lookup cache */ + PyType_ClearCache(); + /* Collect garbage. This may call finalizers; it's nice to call these * before all modules are destroyed. * XXX If a __del__ or weakref callback is triggered here, and tries to Modified: python/branches/trunk-math/Python/sysmodule.c ============================================================================== --- python/branches/trunk-math/Python/sysmodule.c (original) +++ python/branches/trunk-math/Python/sysmodule.c Wed Jan 30 14:42:22 2008 @@ -754,6 +754,17 @@ 10. Number of stack pops performed by call_function()" ); +static PyObject * +sys_cleartypecache(PyObject* self, PyObject* args) +{ + PyType_ClearCache(); + Py_RETURN_NONE; +} + +PyDoc_STRVAR(cleartypecache_doc, +"_cleartypecache() -> None\n\ +Clear the internal type lookup cache."); + #ifdef __cplusplus extern "C" { #endif @@ -776,6 +787,8 @@ /* Might as well keep this in alphabetic order */ {"callstats", (PyCFunction)PyEval_GetCallStats, METH_NOARGS, callstats_doc}, + {"_cleartypecache", sys_cleartypecache, METH_NOARGS, + cleartypecache_doc}, {"_current_frames", sys_current_frames, METH_NOARGS, current_frames_doc}, {"displayhook", sys_displayhook, METH_O, displayhook_doc}, Modified: python/branches/trunk-math/setup.py ============================================================================== --- python/branches/trunk-math/setup.py (original) +++ python/branches/trunk-math/setup.py Wed Jan 30 14:42:22 2008 @@ -681,7 +681,10 @@ # a release. Most open source OSes come with one or more # versions of BerkeleyDB already installed. - max_db_ver = (4, 6) + max_db_ver = (4, 5) # XXX(gregory.p.smith): 4.6 "works" but seems to + # have issues on many platforms. I've temporarily + # disabled 4.6 to see what the odd platform + # buildbots say. min_db_ver = (3, 3) db_setup_debug = False # verbose debug prints from this script? From buildbot at python.org Wed Jan 30 14:42:35 2008 From: buildbot at python.org (buildbot at python.org) Date: Wed, 30 Jan 2008 13:42:35 +0000 Subject: [Python-checkins] buildbot failure in ia64 Ubuntu 3.0 Message-ID: <20080130134235.40E681E4006@bag.python.org> The Buildbot has detected a new failure of ia64 Ubuntu 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/ia64%20Ubuntu%203.0/builds/489 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ia64 Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes BUILD FAILED: failed failed slave lost sincerely, -The Buildbot From buildbot at python.org Wed Jan 30 16:31:51 2008 From: buildbot at python.org (buildbot at python.org) Date: Wed, 30 Jan 2008 15:31:51 +0000 Subject: [Python-checkins] buildbot failure in alpha Tru64 5.1 trunk Message-ID: <20080130153151.CECAC1E401A@bag.python.org> The Buildbot has detected a new failure of alpha Tru64 5.1 trunk. Full details are available at: http://www.python.org/dev/buildbot/all/alpha%20Tru64%205.1%20trunk/builds/2441 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-tru64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: 2 tests failed: test_asynchat test_smtplib sincerely, -The Buildbot From skip at pobox.com Wed Jan 30 16:59:10 2008 From: skip at pobox.com (skip at pobox.com) Date: Wed, 30 Jan 2008 09:59:10 -0600 Subject: [Python-checkins] r60392 - in python/branches/trunk-math: Doc/library/stdtypes.rst Lib/test/test_complex.py Objects/complexobject.c In-Reply-To: <20080128144048.994D41E401A@bag.python.org> References: <20080128144048.994D41E401A@bag.python.org> Message-ID: <18336.40654.234025.671721@montanaro.dyndns.org> >>>>> "christian" == christian heimes writes: Log: Added from_cis and as_cis to the complex type. The functions creates / return the cis form of a complex (aka polar form or exp form) which is often used in engineering. "cis" doesn't ring any bells with me. (Well, actually I know it as the CIS fuel injection system in Porsche 911s, but that's a rather non-Pythonic usage.). Why not the more obvious (to me) from_polar and as_polar? Skip From lists at cheimes.de Wed Jan 30 17:17:08 2008 From: lists at cheimes.de (Christian Heimes) Date: Wed, 30 Jan 2008 17:17:08 +0100 Subject: [Python-checkins] r60392 - in python/branches/trunk-math: Doc/library/stdtypes.rst Lib/test/test_complex.py Objects/complexobject.c In-Reply-To: <18336.40654.234025.671721@montanaro.dyndns.org> References: <20080128144048.994D41E401A@bag.python.org> <18336.40654.234025.671721@montanaro.dyndns.org> Message-ID: <47A0A304.1040200@cheimes.de> skip at pobox.com wrote: > "cis" doesn't ring any bells with me. (Well, actually I know it as the CIS > fuel injection system in Porsche 911s, but that's a rather non-Pythonic > usage.). Why not the more obvious (to me) from_polar and as_polar? I've learned cis form as a way to express complex polar coodinates: cis(phi) = cos(phi) + i * sin(phi). (cis is also used in Chemistry. Carbon double bindings can occur in cis or trans configuration. It's also used in music (C#).) The complex methods were a test. I've moved them as polar(z) -> (r, phi), arg(z) -> phi and rect(r, phi) -> z to the cmath module. abs(z) is already defined as sqrt(z.real**2 + z.imag**2) -> r. Christian From python-checkins at python.org Wed Jan 30 18:21:23 2008 From: python-checkins at python.org (christian.heimes) Date: Wed, 30 Jan 2008 18:21:23 +0100 (CET) Subject: [Python-checkins] r60448 - in python/trunk: Objects/floatobject.c Python/import.c Python/sysmodule.c Message-ID: <20080130172123.0EC811E4013@bag.python.org> Author: christian.heimes Date: Wed Jan 30 18:21:22 2008 New Revision: 60448 Modified: python/trunk/Objects/floatobject.c python/trunk/Python/import.c python/trunk/Python/sysmodule.c Log: Fixed some references leaks in sys. Modified: python/trunk/Objects/floatobject.c ============================================================================== --- python/trunk/Objects/floatobject.c (original) +++ python/trunk/Objects/floatobject.c Wed Jan 30 18:21:22 2008 @@ -143,7 +143,6 @@ return NULL; } - Py_INCREF(floatinfo); return floatinfo; } Modified: python/trunk/Python/import.c ============================================================================== --- python/trunk/Python/import.c (original) +++ python/trunk/Python/import.c Wed Jan 30 18:21:22 2008 @@ -370,6 +370,8 @@ "exc_type", "exc_value", "exc_traceback", "last_type", "last_value", "last_traceback", "path_hooks", "path_importer_cache", "meta_path", + /* misc stuff */ + "flags", "float_info", NULL }; Modified: python/trunk/Python/sysmodule.c ============================================================================== --- python/trunk/Python/sysmodule.c (original) +++ python/trunk/Python/sysmodule.c Wed Jan 30 18:21:22 2008 @@ -1181,7 +1181,6 @@ return NULL; } - Py_INCREF(seq); return seq; } @@ -1199,6 +1198,11 @@ if (m == NULL) return NULL; sysdict = PyModule_GetDict(m); +#define SET_SYS_FROM_STRING(key, value) \ + v = value; \ + if (v != NULL) \ + PyDict_SetItemString(sysdict, key, v); \ + Py_XDECREF(v) { /* XXX: does this work on Win/Win64? (see posix_fstat) */ @@ -1258,19 +1262,17 @@ Py_XDECREF(sysin); Py_XDECREF(sysout); Py_XDECREF(syserr); - PyDict_SetItemString(sysdict, "version", - v = PyString_FromString(Py_GetVersion())); - Py_XDECREF(v); - PyDict_SetItemString(sysdict, "hexversion", - v = PyInt_FromLong(PY_VERSION_HEX)); - Py_XDECREF(v); + + SET_SYS_FROM_STRING("version", + PyString_FromString(Py_GetVersion())); + SET_SYS_FROM_STRING("hexversion", + PyInt_FromLong(PY_VERSION_HEX)); svnversion_init(); - v = Py_BuildValue("(ssz)", "CPython", branch, svn_revision); - PyDict_SetItemString(sysdict, "subversion", v); - Py_XDECREF(v); - PyDict_SetItemString(sysdict, "dont_write_bytecode", - v = PyBool_FromLong(Py_DontWriteBytecodeFlag)); - Py_XDECREF(v); + SET_SYS_FROM_STRING("subversion", + Py_BuildValue("(ssz)", "CPython", branch, + svn_revision)); + SET_SYS_FROM_STRING("dont_write_bytecode", + PyBool_FromLong(Py_DontWriteBytecodeFlag)); /* * These release level checks are mutually exclusive and cover * the field, so don't get too fancy with the pre-processor! @@ -1285,12 +1287,6 @@ s = "final"; #endif -#define SET_SYS_FROM_STRING(key, value) \ - v = value; \ - if (v != NULL) \ - PyDict_SetItemString(sysdict, key, v); \ - Py_XDECREF(v) - SET_SYS_FROM_STRING("version_info", Py_BuildValue("iiisi", PY_MAJOR_VERSION, PY_MINOR_VERSION, @@ -1340,7 +1336,6 @@ SET_SYS_FROM_STRING("winver", PyString_FromString(PyWin_DLLVersionString)); #endif -#undef SET_SYS_FROM_STRING if (warnoptions == NULL) { warnoptions = PyList_New(0); } @@ -1352,11 +1347,12 @@ } PyStructSequence_InitType(&FlagsType, &flags_desc); - PyDict_SetItemString(sysdict, "flags", make_flags()); + SET_SYS_FROM_STRING("flags", make_flags()); /* prevent user from creating new instances */ FlagsType.tp_init = NULL; FlagsType.tp_new = NULL; +#undef SET_SYS_FROM_STRING if (PyErr_Occurred()) return NULL; return m; From buildbot at python.org Wed Jan 30 19:03:40 2008 From: buildbot at python.org (buildbot at python.org) Date: Wed, 30 Jan 2008 18:03:40 +0000 Subject: [Python-checkins] buildbot failure in hppa Ubuntu trunk Message-ID: <20080130180340.748FF1E4014@bag.python.org> The Buildbot has detected a new failure of hppa Ubuntu trunk. Full details are available at: http://www.python.org/dev/buildbot/all/hppa%20Ubuntu%20trunk/builds/567 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-ubuntu-hppa Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: make: *** [buildbottest] Segmentation fault sincerely, -The Buildbot From skip at pobox.com Wed Jan 30 19:25:52 2008 From: skip at pobox.com (skip at pobox.com) Date: Wed, 30 Jan 2008 12:25:52 -0600 Subject: [Python-checkins] r60448 - in python/trunk: Objects/floatobject.c Python/import.c Python/sysmodule.c In-Reply-To: <20080130172123.0EC811E4013@bag.python.org> References: <20080130172123.0EC811E4013@bag.python.org> Message-ID: <18336.49456.553761.845938@montanaro.dyndns.org> Modified: python/trunk/Objects/floatobject.c python/trunk/Python/import.c python/trunk/Python/sysmodule.c Log: Fixed some references leaks in sys. No mention was made of import.c or floatobject.c in the checkin message. Were they innocent bystanders that just got swept up in the cvs commit? Skip From python-checkins at python.org Wed Jan 30 19:58:29 2008 From: python-checkins at python.org (christian.heimes) Date: Wed, 30 Jan 2008 19:58:29 +0100 (CET) Subject: [Python-checkins] r60450 - in python/trunk: Objects/floatobject.c Python/sysmodule.c Message-ID: <20080130185829.7EBB71E4013@bag.python.org> Author: christian.heimes Date: Wed Jan 30 19:58:29 2008 New Revision: 60450 Modified: python/trunk/Objects/floatobject.c python/trunk/Python/sysmodule.c Log: The previous change was causing a segfault after multiple calls to Py_Initialize() and Py_Finalize(). Modified: python/trunk/Objects/floatobject.c ============================================================================== --- python/trunk/Objects/floatobject.c (original) +++ python/trunk/Objects/floatobject.c Wed Jan 30 19:58:29 2008 @@ -66,7 +66,7 @@ return DBL_MIN; } -static PyTypeObject FloatInfoType = {0}; +static PyTypeObject FloatInfoType = {0, 0, 0, 0, 0, 0}; PyDoc_STRVAR(floatinfo__doc__, "sys.floatinfo\n\ @@ -105,15 +105,9 @@ PyObject * PyFloat_GetInfo(void) { - static PyObject* floatinfo; + PyObject* floatinfo; int pos = 0; - if (floatinfo != NULL) { - Py_INCREF(floatinfo); - return floatinfo; - } - PyStructSequence_InitType(&FloatInfoType, &floatinfo_desc); - floatinfo = PyStructSequence_New(&FloatInfoType); if (floatinfo == NULL) { return NULL; @@ -142,7 +136,6 @@ Py_CLEAR(floatinfo); return NULL; } - return floatinfo; } @@ -1669,6 +1662,9 @@ /* Initialize floating point repr */ _PyFloat_DigitsInit(); #endif + /* Init float info */ + if (FloatInfoType.tp_name == 0) + PyStructSequence_InitType(&FloatInfoType, &floatinfo_desc); } void Modified: python/trunk/Python/sysmodule.c ============================================================================== --- python/trunk/Python/sysmodule.c (original) +++ python/trunk/Python/sysmodule.c Wed Jan 30 19:58:29 2008 @@ -1107,7 +1107,7 @@ \n\ Flags provided through command line arguments or environment vars."); -static PyTypeObject FlagsType; +static PyTypeObject FlagsType = {0, 0, 0, 0, 0, 0}; static PyStructSequence_Field flags_fields[] = { {"debug", "-d"}, @@ -1180,7 +1180,6 @@ if (PyErr_Occurred()) { return NULL; } - return seq; } @@ -1346,7 +1345,8 @@ PyDict_SetItemString(sysdict, "warnoptions", warnoptions); } - PyStructSequence_InitType(&FlagsType, &flags_desc); + if (FlagsType.tp_name == 0) + PyStructSequence_InitType(&FlagsType, &flags_desc); SET_SYS_FROM_STRING("flags", make_flags()); /* prevent user from creating new instances */ FlagsType.tp_init = NULL; From lists at cheimes.de Wed Jan 30 20:00:33 2008 From: lists at cheimes.de (Christian Heimes) Date: Wed, 30 Jan 2008 20:00:33 +0100 Subject: [Python-checkins] r60448 - in python/trunk: Objects/floatobject.c Python/import.c Python/sysmodule.c In-Reply-To: <18336.49456.553761.845938@montanaro.dyndns.org> References: <20080130172123.0EC811E4013@bag.python.org> <18336.49456.553761.845938@montanaro.dyndns.org> Message-ID: <47A0C951.8030700@cheimes.de> skip at pobox.com wrote: > Modified: > python/trunk/Objects/floatobject.c > python/trunk/Python/import.c > python/trunk/Python/sysmodule.c > Log: > Fixed some references leaks in sys. > > No mention was made of import.c or floatobject.c in the checkin message. > Were they innocent bystanders that just got swept up in the cvs commit? The changes were related to each other. The sys.flag and sys.float_info object had once reference too much. They were keeping some floats and ints alive. From buildbot at python.org Wed Jan 30 20:28:07 2008 From: buildbot at python.org (buildbot at python.org) Date: Wed, 30 Jan 2008 19:28:07 +0000 Subject: [Python-checkins] buildbot failure in amd64 gentoo trunk Message-ID: <20080130192808.0610E1E4013@bag.python.org> The Buildbot has detected a new failure of amd64 gentoo trunk. Full details are available at: http://www.python.org/dev/buildbot/all/amd64%20gentoo%20trunk/builds/67 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-amd64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_thread.py", line 284, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30995, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') Traceback (most recent call last): File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/threading.py", line 486, in __bootstrap_inner self.run() File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/threading.py", line 446, in run self.__target(*self.__args, **self.__kwargs) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/test/test_thread.py", line 284, in readerThread rec = dbutils.DeadlockWrap(c.next, max_retries=10) File "/home/buildbot/slave/py-build/trunk.norwitz-amd64/build/Lib/bsddb/dbutils.py", line 62, in DeadlockWrap return function(*_args, **_kwargs) DBLockDeadlockError: (-30995, 'DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock') 1 test failed: test_timeout make: *** [buildbottest] Error 1 sincerely, -The Buildbot From buildbot at python.org Wed Jan 30 21:13:35 2008 From: buildbot at python.org (buildbot at python.org) Date: Wed, 30 Jan 2008 20:13:35 +0000 Subject: [Python-checkins] buildbot failure in alpha Tru64 5.1 trunk Message-ID: <20080130201335.64C791E4008@bag.python.org> The Buildbot has detected a new failure of alpha Tru64 5.1 trunk. Full details are available at: http://www.python.org/dev/buildbot/all/alpha%20Tru64%205.1%20trunk/builds/2443 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-tru64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: 2 tests failed: test_asynchat test_smtplib sincerely, -The Buildbot From ncoghlan at gmail.com Wed Jan 30 22:59:03 2008 From: ncoghlan at gmail.com (Nick Coghlan) Date: Thu, 31 Jan 2008 07:59:03 +1000 Subject: [Python-checkins] r60392 - in python/branches/trunk-math: Doc/library/stdtypes.rst Lib/test/test_complex.py Objects/complexobject.c In-Reply-To: <47A0A304.1040200@cheimes.de> References: <20080128144048.994D41E401A@bag.python.org> <18336.40654.234025.671721@montanaro.dyndns.org> <47A0A304.1040200@cheimes.de> Message-ID: <47A0F327.6050005@gmail.com> Christian Heimes wrote: > The complex methods were a test. I've moved them as polar(z) -> (r, > phi), arg(z) -> phi and rect(r, phi) -> z to the cmath module. abs(z) is > already defined as sqrt(z.real**2 + z.imag**2) -> r. Given that 'arg' has an unfortunate namespace clash with the programming sense of the word 'argument', perhaps we could call that function 'phase' instead? I've never encountered either cis or arg as terms in the context of complex numbers despite using them for years - the terminology has always been either real+imaginary or magnitude+phase for the work I've in AC power handling and digital signal processing. Cheers, Nick. P.S. The latest version of these docs is much clearer - thanks! -- Nick Coghlan | ncoghlan at gmail.com | Brisbane, Australia --------------------------------------------------------------- http://www.boredomandlaziness.org From python-checkins at python.org Wed Jan 30 23:17:31 2008 From: python-checkins at python.org (raymond.hettinger) Date: Wed, 30 Jan 2008 23:17:31 +0100 (CET) Subject: [Python-checkins] r60463 - python/trunk/Doc/library/itertools.rst Message-ID: <20080130221731.BB9811E400E@bag.python.org> Author: raymond.hettinger Date: Wed Jan 30 23:17:31 2008 New Revision: 60463 Modified: python/trunk/Doc/library/itertools.rst Log: Update itertool recipes Modified: python/trunk/Doc/library/itertools.rst ============================================================================== --- python/trunk/Doc/library/itertools.rst (original) +++ python/trunk/Doc/library/itertools.rst Wed Jan 30 23:17:31 2008 @@ -401,17 +401,6 @@ 27 64 - >>> reportlines = ['EuroPython', 'Roster', '', 'alex', '', 'laura', - ... '', 'martin', '', 'walter', '', 'mark'] - >>> for name in islice(reportlines, 3, None, 2): - ... print name.title() - ... - Alex - Laura - Martin - Walter - Mark - # Show a dictionary sorted and grouped by value >>> from operator import itemgetter >>> d = dict(a=1, b=2, c=1, d=2, e=1, f=2, g=3) @@ -534,5 +523,16 @@ "grouper(3, 'abcdefg', 'x') --> ('a','b','c'), ('d','e','f'), ('g','x','x')" return izip(*[chain(iterable, repeat(padvalue, n-1))]*n) - + def roundrobin(*iterables): + "roundrobin('abc', 'd', 'ef') --> 'a', 'd', 'e', 'b', 'f', 'c'" + # Recipe contributed by George Sakkis + pending = len(iterables) + nexts = cycle(iter(it).next for it in iterables) + while pending: + try: + for next in nexts: + yield next() + except StopIteration: + pending -= 1 + nexts = cycle(islice(nexts, pending)) From lists at cheimes.de Wed Jan 30 23:36:02 2008 From: lists at cheimes.de (Christian Heimes) Date: Wed, 30 Jan 2008 23:36:02 +0100 Subject: [Python-checkins] r60392 - in python/branches/trunk-math: Doc/library/stdtypes.rst Lib/test/test_complex.py Objects/complexobject.c In-Reply-To: <47A0F327.6050005@gmail.com> References: <20080128144048.994D41E401A@bag.python.org> <18336.40654.234025.671721@montanaro.dyndns.org> <47A0A304.1040200@cheimes.de> <47A0F327.6050005@gmail.com> Message-ID: <47A0FBD2.3070304@cheimes.de> Nick Coghlan wrote: > Given that 'arg' has an unfortunate namespace clash with the programming > sense of the word 'argument', perhaps we could call that function > 'phase' instead? I've never encountered either cis or arg as terms in > the context of complex numbers despite using them for years - the > terminology has always been either real+imaginary or magnitude+phase for > the work I've in AC power handling and digital signal processing. Mark argued with me that he needs arg(). I had a strange gut feeling about the name but I couldn't put my fingers on it ... now I know. I like your suggestion of phase(). I've learned "cis form" as synonym for complex numbers in polar coordinates and exponential representation in university. We used it all the time for calculation of complex resistors in AC power networks and more. I got used to the name because it's a nice mnemonic trick to memorize the formula for polar -> rect form. Or maybe it's just a German thing. ;) Apropos German I'm having a hard time finding accurate translations of mathematical and scientific terms. Even my beloved site http://dict.leo.org/ doesn't have translations for some terms. Has any of the German readers a good site with translations? Christian From python-checkins at python.org Wed Jan 30 23:54:19 2008 From: python-checkins at python.org (christian.heimes) Date: Wed, 30 Jan 2008 23:54:19 +0100 (CET) Subject: [Python-checkins] r60464 - in python/trunk: Misc/NEWS configure configure.in Message-ID: <20080130225419.196921E400E@bag.python.org> Author: christian.heimes Date: Wed Jan 30 23:54:18 2008 New Revision: 60464 Modified: python/trunk/Misc/NEWS python/trunk/configure python/trunk/configure.in Log: Bug #1234: Fixed semaphore errors on AIX 5.2 Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Wed Jan 30 23:54:18 2008 @@ -1383,6 +1383,8 @@ Build ----- +- Bug #1234: Fixed semaphore errors on AIX 5.2 + - Issue #1726: Remove Python/atof.c from PCBuild/pythoncore.vcproj - Removed PCbuild8/ directory and added a new build directory for VS 2005 Modified: python/trunk/configure ============================================================================== --- python/trunk/configure (original) +++ python/trunk/configure Wed Jan 30 23:54:18 2008 @@ -1,5 +1,5 @@ #! /bin/sh -# From configure.in Revision: 59819 . +# From configure.in Revision: 60141 . # Guess values for system-dependent variables and create Makefiles. # Generated by GNU Autoconf 2.61 for python 2.6. # @@ -14391,6 +14391,12 @@ _ACEOF ;; + AIX/5) +cat >>confdefs.h <<\_ACEOF +#define HAVE_BROKEN_POSIX_SEMAPHORES 1 +_ACEOF + + ;; esac { echo "$as_me:$LINENO: checking if PTHREAD_SCOPE_SYSTEM is supported" >&5 Modified: python/trunk/configure.in ============================================================================== --- python/trunk/configure.in (original) +++ python/trunk/configure.in Wed Jan 30 23:54:18 2008 @@ -1993,6 +1993,9 @@ SunOS/5.8) AC_DEFINE(HAVE_BROKEN_POSIX_SEMAPHORES, 1, Define if the Posix semaphores do not work on your system) ;; + AIX/5) AC_DEFINE(HAVE_BROKEN_POSIX_SEMAPHORES, 1, + Define if the Posix semaphores do not work on your system) + ;; esac AC_MSG_CHECKING(if PTHREAD_SCOPE_SYSTEM is supported) From python-checkins at python.org Wed Jan 30 23:54:28 2008 From: python-checkins at python.org (christian.heimes) Date: Wed, 30 Jan 2008 23:54:28 +0100 (CET) Subject: [Python-checkins] r60465 - in python/branches/release25-maint: Misc/NEWS configure configure.in pyconfig.h.in Message-ID: <20080130225428.5BEF51E400E@bag.python.org> Author: christian.heimes Date: Wed Jan 30 23:54:27 2008 New Revision: 60465 Modified: python/branches/release25-maint/Misc/NEWS python/branches/release25-maint/configure python/branches/release25-maint/configure.in python/branches/release25-maint/pyconfig.h.in Log: Bug #1234: Fixed semaphore errors on AIX 5.2 Modified: python/branches/release25-maint/Misc/NEWS ============================================================================== --- python/branches/release25-maint/Misc/NEWS (original) +++ python/branches/release25-maint/Misc/NEWS Wed Jan 30 23:54:27 2008 @@ -257,6 +257,8 @@ Build ----- +- Bug #1234: Fixed semaphore errors on AIX 5.2 + - Bug #1699: Define _BSD_SOURCE only on OpenBSD. - Bug #1608: use -fwrapv when GCC supports it. This is important, Modified: python/branches/release25-maint/configure ============================================================================== --- python/branches/release25-maint/configure (original) +++ python/branches/release25-maint/configure Wed Jan 30 23:54:27 2008 @@ -1,5 +1,5 @@ #! /bin/sh -# From configure.in Revision: 59552 . +# From configure.in Revision: 59610 . # Guess values for system-dependent variables and create Makefiles. # Generated by GNU Autoconf 2.61 for python 2.5. # @@ -13865,6 +13865,12 @@ _ACEOF ;; + AIX/5) +cat >>confdefs.h <<\_ACEOF +#define HAVE_BROKEN_POSIX_SEMAPHORES 1 +_ACEOF + + ;; esac { echo "$as_me:$LINENO: checking if PTHREAD_SCOPE_SYSTEM is supported" >&5 Modified: python/branches/release25-maint/configure.in ============================================================================== --- python/branches/release25-maint/configure.in (original) +++ python/branches/release25-maint/configure.in Wed Jan 30 23:54:27 2008 @@ -1963,6 +1963,9 @@ SunOS/5.8) AC_DEFINE(HAVE_BROKEN_POSIX_SEMAPHORES, 1, Define if the Posix semaphores do not work on your system) ;; + AIX/5) AC_DEFINE(HAVE_BROKEN_POSIX_SEMAPHORES, 1, + Define if the Posix semaphores do not work on your system) + ;; esac AC_MSG_CHECKING(if PTHREAD_SCOPE_SYSTEM is supported) Modified: python/branches/release25-maint/pyconfig.h.in ============================================================================== --- python/branches/release25-maint/pyconfig.h.in (original) +++ python/branches/release25-maint/pyconfig.h.in Wed Jan 30 23:54:27 2008 @@ -94,6 +94,10 @@ /* Define if you have the 'resize_term' function. */ #undef HAVE_CURSES_RESIZE_TERM +/* Define to 1 if you have the declaration of `tzname', and to 0 if you don't. + */ +#undef HAVE_DECL_TZNAME + /* Define to 1 if you have the device macros. */ #undef HAVE_DEVICE_MACROS @@ -793,22 +797,22 @@ /* Define if i>>j for signed int i does not extend the sign bit when i < 0 */ #undef SIGNED_RIGHT_SHIFT_ZERO_FILLS -/* The size of a `double', as computed by sizeof. */ +/* The size of `double', as computed by sizeof. */ #undef SIZEOF_DOUBLE -/* The size of a `float', as computed by sizeof. */ +/* The size of `float', as computed by sizeof. */ #undef SIZEOF_FLOAT -/* The size of a `fpos_t', as computed by sizeof. */ +/* The size of `fpos_t', as computed by sizeof. */ #undef SIZEOF_FPOS_T -/* The size of a `int', as computed by sizeof. */ +/* The size of `int', as computed by sizeof. */ #undef SIZEOF_INT -/* The size of a `long', as computed by sizeof. */ +/* The size of `long', as computed by sizeof. */ #undef SIZEOF_LONG -/* The size of a `long long', as computed by sizeof. */ +/* The size of `long long', as computed by sizeof. */ #undef SIZEOF_LONG_LONG /* The number of bytes in an off_t. */ @@ -817,22 +821,22 @@ /* The number of bytes in a pthread_t. */ #undef SIZEOF_PTHREAD_T -/* The size of a `short', as computed by sizeof. */ +/* The size of `short', as computed by sizeof. */ #undef SIZEOF_SHORT -/* The size of a `size_t', as computed by sizeof. */ +/* The size of `size_t', as computed by sizeof. */ #undef SIZEOF_SIZE_T /* The number of bytes in a time_t. */ #undef SIZEOF_TIME_T -/* The size of a `uintptr_t', as computed by sizeof. */ +/* The size of `uintptr_t', as computed by sizeof. */ #undef SIZEOF_UINTPTR_T -/* The size of a `void *', as computed by sizeof. */ +/* The size of `void *', as computed by sizeof. */ #undef SIZEOF_VOID_P -/* The size of a `wchar_t', as computed by sizeof. */ +/* The size of `wchar_t', as computed by sizeof. */ #undef SIZEOF_WCHAR_T /* Define to 1 if you have the ANSI C header files. */ @@ -971,7 +975,7 @@ /* Define to `int' if does not define. */ #undef mode_t -/* Define to `long' if does not define. */ +/* Define to `long int' if does not define. */ #undef off_t /* Define to `int' if does not define. */ @@ -980,7 +984,7 @@ /* Define to empty if the keyword does not work. */ #undef signed -/* Define to `unsigned' if does not define. */ +/* Define to `unsigned int' if does not define. */ #undef size_t /* Define to `int' if does not define. */ From buildbot at python.org Thu Jan 31 00:26:45 2008 From: buildbot at python.org (buildbot at python.org) Date: Wed, 30 Jan 2008 23:26:45 +0000 Subject: [Python-checkins] buildbot failure in ARM Linux EABI trunk Message-ID: <20080130232645.37C5D1E4012@bag.python.org> The Buildbot has detected a new failure of ARM Linux EABI trunk. Full details are available at: http://www.python.org/dev/buildbot/all/ARM%20Linux%20EABI%20trunk/builds/26 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-linux-armeabi Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: christian.heimes,raymond.hettinger BUILD FAILED: failed failed slave lost sincerely, -The Buildbot From buildbot at python.org Thu Jan 31 00:45:44 2008 From: buildbot at python.org (buildbot at python.org) Date: Wed, 30 Jan 2008 23:45:44 +0000 Subject: [Python-checkins] buildbot failure in amd64 gentoo 3.0 Message-ID: <20080130234545.23EB21E4012@bag.python.org> The Buildbot has detected a new failure of amd64 gentoo 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/amd64%20gentoo%203.0/builds/29 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-amd64 Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed compile sincerely, -The Buildbot From buildbot at python.org Thu Jan 31 01:17:04 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 31 Jan 2008 00:17:04 +0000 Subject: [Python-checkins] buildbot failure in ppc Debian unstable 3.0 Message-ID: <20080131001705.17B991E400E@bag.python.org> The Buildbot has detected a new failure of ppc Debian unstable 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/ppc%20Debian%20unstable%203.0/builds/511 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ppc Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed compile sincerely, -The Buildbot From buildbot at python.org Thu Jan 31 01:27:50 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 31 Jan 2008 00:27:50 +0000 Subject: [Python-checkins] buildbot failure in sparc solaris10 gcc 3.0 Message-ID: <20080131002750.E2D891E400E@bag.python.org> The Buildbot has detected a new failure of sparc solaris10 gcc 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/sparc%20solaris10%20gcc%203.0/builds/540 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: loewis-sun Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed compile sincerely, -The Buildbot From buildbot at python.org Thu Jan 31 01:36:28 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 31 Jan 2008 00:36:28 +0000 Subject: [Python-checkins] buildbot failure in g4 osx.4 3.0 Message-ID: <20080131003628.B8F0B1E400E@bag.python.org> The Buildbot has detected a new failure of g4 osx.4 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/g4%20osx.4%203.0/builds/488 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: psf-g4 Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed compile sincerely, -The Buildbot From buildbot at python.org Thu Jan 31 01:42:23 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 31 Jan 2008 00:42:23 +0000 Subject: [Python-checkins] buildbot failure in ia64 Ubuntu 3.0 Message-ID: <20080131004223.C8D011E480B@bag.python.org> The Buildbot has detected a new failure of ia64 Ubuntu 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/ia64%20Ubuntu%203.0/builds/492 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-ia64 Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed compile sincerely, -The Buildbot From buildbot at python.org Thu Jan 31 02:27:43 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 31 Jan 2008 01:27:43 +0000 Subject: [Python-checkins] buildbot failure in S-390 Debian 3.0 Message-ID: <20080131012743.DF0321E400E@bag.python.org> The Buildbot has detected a new failure of S-390 Debian 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/S-390%20Debian%203.0/builds/19 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-s390 Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed compile sincerely, -The Buildbot From buildbot at python.org Thu Jan 31 02:31:15 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 31 Jan 2008 01:31:15 +0000 Subject: [Python-checkins] buildbot failure in hppa Ubuntu 3.0 Message-ID: <20080131013115.66B571E400E@bag.python.org> The Buildbot has detected a new failure of hppa Ubuntu 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/hppa%20Ubuntu%203.0/builds/475 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-ubuntu-hppa Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed compile sincerely, -The Buildbot From python-checkins at python.org Thu Jan 31 02:38:15 2008 From: python-checkins at python.org (raymond.hettinger) Date: Thu, 31 Jan 2008 02:38:15 +0100 (CET) Subject: [Python-checkins] r60469 - python/trunk/Lib/_abcoll.py Message-ID: <20080131013815.B08471E400E@bag.python.org> Author: raymond.hettinger Date: Thu Jan 31 02:38:15 2008 New Revision: 60469 Modified: python/trunk/Lib/_abcoll.py Log: Fix defect in __ixor__ which would get the wrong answer if the input iterable had a duplicate element (two calls to toggle() reverse each other). Borrow the correct code from sets.py. Modified: python/trunk/Lib/_abcoll.py ============================================================================== --- python/trunk/Lib/_abcoll.py (original) +++ python/trunk/Lib/_abcoll.py Thu Jan 31 02:38:15 2008 @@ -266,16 +266,6 @@ self.discard(value) return value - def toggle(self, value): - """Return True if it was added, False if deleted.""" - # XXX This implementation is not thread-safe - if value in self: - self.discard(value) - return False - else: - self.add(value) - return True - def clear(self): """This is slow (creates N new iterators!) but effective.""" try: @@ -296,10 +286,13 @@ return self def __ixor__(self, it): - # This calls toggle(), so if that is overridded, we call the override + if not isinstance(it, Set): + it = self._from_iterable(it) for value in it: - self.toggle(it) - return self + if value in self: + self.discard(value) + else: + self.add(value) def __isub__(self, it): for value in it: From python-checkins at python.org Thu Jan 31 02:42:11 2008 From: python-checkins at python.org (raymond.hettinger) Date: Thu, 31 Jan 2008 02:42:11 +0100 (CET) Subject: [Python-checkins] r60470 - python/trunk/Lib/_abcoll.py Message-ID: <20080131014211.55BE01E400E@bag.python.org> Author: raymond.hettinger Date: Thu Jan 31 02:42:11 2008 New Revision: 60470 Modified: python/trunk/Lib/_abcoll.py Log: Missing return Modified: python/trunk/Lib/_abcoll.py ============================================================================== --- python/trunk/Lib/_abcoll.py (original) +++ python/trunk/Lib/_abcoll.py Thu Jan 31 02:42:11 2008 @@ -293,6 +293,7 @@ self.discard(value) else: self.add(value) + return self def __isub__(self, it): for value in it: From buildbot at python.org Thu Jan 31 03:06:01 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 31 Jan 2008 02:06:01 +0000 Subject: [Python-checkins] buildbot failure in x86 FreeBSD trunk Message-ID: <20080131020602.128D91E4012@bag.python.org> The Buildbot has detected a new failure of x86 FreeBSD trunk. Full details are available at: http://www.python.org/dev/buildbot/all/x86%20FreeBSD%20trunk/builds/503 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: bolen-freebsd Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: christian.heimes,raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: Traceback (most recent call last): File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 227, in handle_request self.process_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 268, in process_request self.finish_request(request, client_address) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 281, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/SocketServer.py", line 560, in __init__ self.handle() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 316, in handle self.handle_one_request() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/BaseHTTPServer.py", line 299, in handle_one_request self.raw_requestline = self.rfile.readline() File "/usr/home/db3l/buildarea/trunk.bolen-freebsd/build/Lib/socket.py", line 369, in readline data = self._sock.recv(self._rbufsize) error: [Errno 35] Resource temporarily unavailable 1 test failed: test_smtplib sincerely, -The Buildbot From buildbot at python.org Thu Jan 31 03:42:12 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 31 Jan 2008 02:42:12 +0000 Subject: [Python-checkins] buildbot failure in ARM Linux EABI 3.0 Message-ID: <20080131024212.80FA51E400E@bag.python.org> The Buildbot has detected a new failure of ARM Linux EABI 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/ARM%20Linux%20EABI%203.0/builds/21 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-linux-armeabi Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed compile sincerely, -The Buildbot From buildbot at python.org Thu Jan 31 04:47:58 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 31 Jan 2008 03:47:58 +0000 Subject: [Python-checkins] buildbot failure in alpha Tru64 5.1 trunk Message-ID: <20080131034758.9A3A41E400E@bag.python.org> The Buildbot has detected a new failure of alpha Tru64 5.1 trunk. Full details are available at: http://www.python.org/dev/buildbot/all/alpha%20Tru64%205.1%20trunk/builds/2445 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-tru64 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: 4 tests failed: test_asynchat test_signal test_smtplib test_socket ====================================================================== FAIL: test_main (test.test_signal.InterProcessSignalTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/net/taipan/scratch1/nnorwitz/python/trunk.norwitz-tru64/build/Lib/test/test_signal.py", line 117, in test_main self.assert_(self.b_called) AssertionError sincerely, -The Buildbot From buildbot at python.org Thu Jan 31 04:54:20 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 31 Jan 2008 03:54:20 +0000 Subject: [Python-checkins] buildbot failure in hppa Ubuntu trunk Message-ID: <20080131035420.90E311E400E@bag.python.org> The Buildbot has detected a new failure of hppa Ubuntu trunk. Full details are available at: http://www.python.org/dev/buildbot/all/hppa%20Ubuntu%20trunk/builds/570 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-ubuntu-hppa Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed test Excerpt from the test logfile: make: *** [buildbottest] Segmentation fault sincerely, -The Buildbot From python-checkins at python.org Thu Jan 31 08:44:12 2008 From: python-checkins at python.org (jeffrey.yasskin) Date: Thu, 31 Jan 2008 08:44:12 +0100 (CET) Subject: [Python-checkins] r60471 - in python/trunk: Doc/library/numbers.rst Lib/numbers.py Lib/rational.py Message-ID: <20080131074412.622AF1E4012@bag.python.org> Author: jeffrey.yasskin Date: Thu Jan 31 08:44:11 2008 New Revision: 60471 Modified: python/trunk/Doc/library/numbers.rst python/trunk/Lib/numbers.py python/trunk/Lib/rational.py Log: Added more documentation on how mixed-mode arithmetic should be implemented. I also noticed and fixed a bug in Rational's forward operators (they were claiming all instances of numbers.Rational instead of just the concrete types). Modified: python/trunk/Doc/library/numbers.rst ============================================================================== --- python/trunk/Doc/library/numbers.rst (original) +++ python/trunk/Doc/library/numbers.rst Thu Jan 31 08:44:11 2008 @@ -99,3 +99,144 @@ 3-argument form of :func:`pow`, and the bit-string operations: ``<<``, ``>>``, ``&``, ``^``, ``|``, ``~``. Provides defaults for :func:`float`, :attr:`Rational.numerator`, and :attr:`Rational.denominator`. + + +Notes for type implementors +--------------------------- + +Implementors should be careful to make equal numbers equal and hash +them to the same values. This may be subtle if there are two different +extensions of the real numbers. For example, :class:`rational.Rational` +implements :func:`hash` as follows:: + + def __hash__(self): + if self.denominator == 1: + # Get integers right. + return hash(self.numerator) + # Expensive check, but definitely correct. + if self == float(self): + return hash(float(self)) + else: + # Use tuple's hash to avoid a high collision rate on + # simple fractions. + return hash((self.numerator, self.denominator)) + + +Adding More Numeric ABCs +~~~~~~~~~~~~~~~~~~~~~~~~ + +There are, of course, more possible ABCs for numbers, and this would +be a poor hierarchy if it precluded the possibility of adding +those. You can add ``MyFoo`` between :class:`Complex` and +:class:`Real` with:: + + class MyFoo(Complex): ... + MyFoo.register(Real) + + +Implementing the arithmetic operations +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +We want to implement the arithmetic operations so that mixed-mode +operations either call an implementation whose author knew about the +types of both arguments, or convert both to the nearest built in type +and do the operation there. For subtypes of :class:`Integral`, this +means that :meth:`__add__` and :meth:`__radd__` should be defined as:: + + class MyIntegral(Integral): + + def __add__(self, other): + if isinstance(other, MyIntegral): + return do_my_adding_stuff(self, other) + elif isinstance(other, OtherTypeIKnowAbout): + return do_my_other_adding_stuff(self, other) + else: + return NotImplemented + + def __radd__(self, other): + if isinstance(other, MyIntegral): + return do_my_adding_stuff(other, self) + elif isinstance(other, OtherTypeIKnowAbout): + return do_my_other_adding_stuff(other, self) + elif isinstance(other, Integral): + return int(other) + int(self) + elif isinstance(other, Real): + return float(other) + float(self) + elif isinstance(other, Complex): + return complex(other) + complex(self) + else: + return NotImplemented + + +There are 5 different cases for a mixed-type operation on subclasses +of :class:`Complex`. I'll refer to all of the above code that doesn't +refer to ``MyIntegral`` and ``OtherTypeIKnowAbout`` as +"boilerplate". ``a`` will be an instance of ``A``, which is a subtype +of :class:`Complex` (``a : A <: Complex``), and ``b : B <: +Complex``. I'll consider ``a + b``: + + 1. If ``A`` defines an :meth:`__add__` which accepts ``b``, all is + well. + 2. If ``A`` falls back to the boilerplate code, and it were to + return a value from :meth:`__add__`, we'd miss the possibility + that ``B`` defines a more intelligent :meth:`__radd__`, so the + boilerplate should return :const:`NotImplemented` from + :meth:`__add__`. (Or ``A`` may not implement :meth:`__add__` at + all.) + 3. Then ``B``'s :meth:`__radd__` gets a chance. If it accepts + ``a``, all is well. + 4. If it falls back to the boilerplate, there are no more possible + methods to try, so this is where the default implementation + should live. + 5. If ``B <: A``, Python tries ``B.__radd__`` before + ``A.__add__``. This is ok, because it was implemented with + knowledge of ``A``, so it can handle those instances before + delegating to :class:`Complex`. + +If ``A<:Complex`` and ``B<:Real`` without sharing any other knowledge, +then the appropriate shared operation is the one involving the built +in :class:`complex`, and both :meth:`__radd__` s land there, so ``a+b +== b+a``. + +Because most of the operations on any given type will be very similar, +it can be useful to define a helper function which generates the +forward and reverse instances of any given operator. For example, +:class:`rational.Rational` uses:: + + def _operator_fallbacks(monomorphic_operator, fallback_operator): + def forward(a, b): + if isinstance(b, (int, long, Rational)): + return monomorphic_operator(a, b) + elif isinstance(b, float): + return fallback_operator(float(a), b) + elif isinstance(b, complex): + return fallback_operator(complex(a), b) + else: + return NotImplemented + forward.__name__ = '__' + fallback_operator.__name__ + '__' + forward.__doc__ = monomorphic_operator.__doc__ + + def reverse(b, a): + if isinstance(a, RationalAbc): + # Includes ints. + return monomorphic_operator(a, b) + elif isinstance(a, numbers.Real): + return fallback_operator(float(a), float(b)) + elif isinstance(a, numbers.Complex): + return fallback_operator(complex(a), complex(b)) + else: + return NotImplemented + reverse.__name__ = '__r' + fallback_operator.__name__ + '__' + reverse.__doc__ = monomorphic_operator.__doc__ + + return forward, reverse + + def _add(a, b): + """a + b""" + return Rational(a.numerator * b.denominator + + b.numerator * a.denominator, + a.denominator * b.denominator) + + __add__, __radd__ = _operator_fallbacks(_add, operator.add) + + # ... \ No newline at end of file Modified: python/trunk/Lib/numbers.py ============================================================================== --- python/trunk/Lib/numbers.py (original) +++ python/trunk/Lib/numbers.py Thu Jan 31 08:44:11 2008 @@ -292,7 +292,13 @@ # Concrete implementation of Real's conversion to float. def __float__(self): - """float(self) = self.numerator / self.denominator""" + """float(self) = self.numerator / self.denominator + + It's important that this conversion use the integer's "true" + division rather than casting one side to float before dividing + so that ratios of huge integers convert without overflowing. + + """ return self.numerator / self.denominator Modified: python/trunk/Lib/rational.py ============================================================================== --- python/trunk/Lib/rational.py (original) +++ python/trunk/Lib/rational.py Thu Jan 31 08:44:11 2008 @@ -179,16 +179,6 @@ else: return '%s/%s' % (self.numerator, self.denominator) - """ XXX This section needs a lot more commentary - - * Explain the typical sequence of checks, calls, and fallbacks. - * Explain the subtle reasons why this logic was needed. - * It is not clear how common cases are handled (for example, how - does the ratio of two huge integers get converted to a float - without overflowing the long-->float conversion. - - """ - def _operator_fallbacks(monomorphic_operator, fallback_operator): """Generates forward and reverse operators given a purely-rational operator and a function from the operator module. @@ -196,10 +186,82 @@ Use this like: __op__, __rop__ = _operator_fallbacks(just_rational_op, operator.op) + In general, we want to implement the arithmetic operations so + that mixed-mode operations either call an implementation whose + author knew about the types of both arguments, or convert both + to the nearest built in type and do the operation there. In + Rational, that means that we define __add__ and __radd__ as: + + def __add__(self, other): + if isinstance(other, (int, long, Rational)): + # Do the real operation. + return Rational(self.numerator * other.denominator + + other.numerator * self.denominator, + self.denominator * other.denominator) + # float and complex don't follow this protocol, and + # Rational knows about them, so special case them. + elif isinstance(other, float): + return float(self) + other + elif isinstance(other, complex): + return complex(self) + other + else: + # Let the other type take over. + return NotImplemented + + def __radd__(self, other): + # radd handles more types than add because there's + # nothing left to fall back to. + if isinstance(other, RationalAbc): + return Rational(self.numerator * other.denominator + + other.numerator * self.denominator, + self.denominator * other.denominator) + elif isinstance(other, Real): + return float(other) + float(self) + elif isinstance(other, Complex): + return complex(other) + complex(self) + else: + return NotImplemented + + + There are 5 different cases for a mixed-type addition on + Rational. I'll refer to all of the above code that doesn't + refer to Rational, float, or complex as "boilerplate". 'r' + will be an instance of Rational, which is a subtype of + RationalAbc (r : Rational <: RationalAbc), and b : B <: + Complex. The first three involve 'r + b': + + 1. If B <: Rational, int, float, or complex, we handle + that specially, and all is well. + 2. If Rational falls back to the boilerplate code, and it + were to return a value from __add__, we'd miss the + possibility that B defines a more intelligent __radd__, + so the boilerplate should return NotImplemented from + __add__. In particular, we don't handle RationalAbc + here, even though we could get an exact answer, in case + the other type wants to do something special. + 3. If B <: Rational, Python tries B.__radd__ before + Rational.__add__. This is ok, because it was + implemented with knowledge of Rational, so it can + handle those instances before delegating to Real or + Complex. + + The next two situations describe 'b + r'. We assume that b + didn't know about Rational in its implementation, and that it + uses similar boilerplate code: + + 4. If B <: RationalAbc, then __radd_ converts both to the + builtin rational type (hey look, that's us) and + proceeds. + 5. Otherwise, __radd__ tries to find the nearest common + base ABC, and fall back to its builtin type. Since this + class doesn't subclass a concrete type, there's no + implementation to fall back to, so we need to try as + hard as possible to return an actual value, or the user + will get a TypeError. + """ def forward(a, b): - if isinstance(b, RationalAbc): - # Includes ints. + if isinstance(b, (int, long, Rational)): return monomorphic_operator(a, b) elif isinstance(b, float): return fallback_operator(float(a), b) From buildbot at python.org Thu Jan 31 08:44:37 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 31 Jan 2008 07:44:37 +0000 Subject: [Python-checkins] buildbot failure in ARM Linux 3.0 Message-ID: <20080131074437.3BF5E1E4012@bag.python.org> The Buildbot has detected a new failure of ARM Linux 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/ARM%20Linux%203.0/builds/15 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-linux-arm Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: raymond.hettinger BUILD FAILED: failed compile sincerely, -The Buildbot From nnorwitz at gmail.com Thu Jan 31 11:25:36 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Thu, 31 Jan 2008 05:25:36 -0500 Subject: [Python-checkins] Python Regression Test Failures refleak (2) Message-ID: <20080131102536.GA18522@python.psfb.org> test_asynchat leaked [-6, -85, 0] references, sum=-91 test_cmd_line leaked [0, 0, -23] references, sum=-23 test_marshal leaked [32, 32, 32] references, sum=96 test_threadsignals leaked [0, -8, 0] references, sum=-8 test_urllib2_localnet leaked [3, 3, 126] references, sum=132 From buildbot at python.org Thu Jan 31 17:01:25 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 31 Jan 2008 16:01:25 +0000 Subject: [Python-checkins] buildbot failure in alpha Tru64 5.1 3.0 Message-ID: <20080131160125.5F8331E4023@bag.python.org> The Buildbot has detected a new failure of alpha Tru64 5.1 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/alpha%20Tru64%205.1%203.0/builds/594 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: norwitz-tru64 Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: sincerely, -The Buildbot From python-checkins at python.org Thu Jan 31 18:04:55 2008 From: python-checkins at python.org (christian.heimes) Date: Thu, 31 Jan 2008 18:04:55 +0100 (CET) Subject: [Python-checkins] r60479 - in python/branches/trunk-math: Doc/library/cmath.rst Lib/test/test_cmath.py Misc/NEWS Modules/cmathmodule.c Message-ID: <20080131170455.60E901E4010@bag.python.org> Author: christian.heimes Date: Thu Jan 31 18:04:54 2008 New Revision: 60479 Modified: python/branches/trunk-math/Doc/library/cmath.rst python/branches/trunk-math/Lib/test/test_cmath.py python/branches/trunk-math/Misc/NEWS python/branches/trunk-math/Modules/cmathmodule.c Log: Renamed cmath.arg to phase as suggested by Nick Coghlan Modified: python/branches/trunk-math/Doc/library/cmath.rst ============================================================================== --- python/branches/trunk-math/Doc/library/cmath.rst (original) +++ python/branches/trunk-math/Doc/library/cmath.rst Thu Jan 31 18:04:54 2008 @@ -45,19 +45,25 @@ The phase angle *?* is the counter clockwise angle from the positive x axis, e.g. *1* has the angle *0*, *1j* has the angle *?/2* and *-1* the angle *-?*. +.. note:: + While :func:`phase` and func:`polar` return *+?* for a negative real they + may return *-?* for a complex with a very small negative imaginary + part, e.g. *-1-1E-300j*. + + Definition:: z = r * exp(1j * ?) z = r * cis(?) r := abs(z) := sqrt(real(z)**2 + imag(z)**2) - phi := arg(z) := atan2(imag(z), real(z)) + phi := phase(z) := atan2(imag(z), real(z)) cis(?) := cos(?) + 1j * sin(?) -.. function:: arg(x) +.. function:: phase(x) - Return argument, also known as the phase angle, of a complex. + Return phase, also known as the argument, of a complex. .. versionadded:: 2.6 Modified: python/branches/trunk-math/Lib/test/test_cmath.py ============================================================================== --- python/branches/trunk-math/Lib/test/test_cmath.py (original) +++ python/branches/trunk-math/Lib/test/test_cmath.py Thu Jan 31 18:04:54 2008 @@ -3,7 +3,7 @@ import unittest import os, sys import cmath, math -from cmath import arg, polar, rect, pi +from cmath import phase, polar, rect, pi INF = float('inf') NAN = float('nan') @@ -240,12 +240,14 @@ self.assertCISEqual(polar(1j), (1., pi/2)) self.assertCISEqual(polar(-1j), (1., -pi/2)) - def test_arg(self): - self.assertAlmostEqual(arg(0), 0.) - self.assertAlmostEqual(arg(1.), 0.) - self.assertAlmostEqual(arg(-1.), pi) - self.assertAlmostEqual(arg(1j), pi/2) - self.assertAlmostEqual(arg(-1j), -pi/2) + def test_phase(self): + self.assertAlmostEqual(phase(0), 0.) + self.assertAlmostEqual(phase(1.), 0.) + self.assertAlmostEqual(phase(-1.), pi) + self.assertAlmostEqual(phase(-1.+1E-300j), pi) + self.assertAlmostEqual(phase(-1.-1E-300j), -pi) + self.assertAlmostEqual(phase(1j), pi/2) + self.assertAlmostEqual(phase(-1j), -pi/2) def assertCEqual(self, a, b): eps = 1E-7 Modified: python/branches/trunk-math/Misc/NEWS ============================================================================== --- python/branches/trunk-math/Misc/NEWS (original) +++ python/branches/trunk-math/Misc/NEWS Thu Jan 31 18:04:54 2008 @@ -12,7 +12,7 @@ Core and builtins ----------------- -- Added arg(z) -> phi, polar(z) -> r, phi and rect(r, phi) -> z to the cmath +- Added phase(z) -> phi, polar(z) -> r, phi and rect(r, phi) -> z to the cmath module. - Issue #XXXX: Four new methods were added to the math and cmath modules: Modified: python/branches/trunk-math/Modules/cmathmodule.c ============================================================================== --- python/branches/trunk-math/Modules/cmathmodule.c (original) +++ python/branches/trunk-math/Modules/cmathmodule.c Thu Jan 31 18:04:54 2008 @@ -608,11 +608,11 @@ FUNC1(cmath_tanh, c_tanh) static PyObject * -cmath_arg(PyObject *self, PyObject *args) +cmath_phase(PyObject *self, PyObject *args) { Py_complex z; double phi; - if (!PyArg_ParseTuple(args, "D:arg", &z)) + if (!PyArg_ParseTuple(args, "D:phase", &z)) return NULL; errno = 0; PyFPE_START_PROTECT("arg function", return 0) @@ -624,8 +624,8 @@ return PyFloat_FromDouble(phi); } -PyDoc_STRVAR(cmath_arg_doc, -"arg(z) -> float\n\n\ +PyDoc_STRVAR(cmath_phase_doc, +"phase(z) -> float\n\n\ Return argument, also known as the phase angle, of a complex."); static PyObject * @@ -712,7 +712,6 @@ static PyMethodDef cmath_methods[] = { {"acos", cmath_acos, METH_VARARGS, c_acos_doc}, {"acosh", cmath_acosh, METH_VARARGS, c_acosh_doc}, - {"arg", cmath_arg, METH_VARARGS, cmath_arg_doc}, {"asin", cmath_asin, METH_VARARGS, c_asin_doc}, {"asinh", cmath_asinh, METH_VARARGS, c_asinh_doc}, {"atan", cmath_atan, METH_VARARGS, c_atan_doc}, @@ -724,6 +723,7 @@ {"isnan", cmath_isnan, METH_VARARGS, cmath_isnan_doc}, {"log", cmath_log, METH_VARARGS, cmath_log_doc}, {"log10", cmath_log10, METH_VARARGS, c_log10_doc}, + {"phase", cmath_phase, METH_VARARGS, cmath_phase_doc}, {"polar", cmath_polar, METH_VARARGS, cmath_polar_doc}, {"rect", cmath_rect, METH_VARARGS, cmath_rect_doc}, {"sin", cmath_sin, METH_VARARGS, c_sin_doc}, From buildbot at python.org Thu Jan 31 18:32:10 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 31 Jan 2008 17:32:10 +0000 Subject: [Python-checkins] buildbot failure in hppa Ubuntu 3.0 Message-ID: <20080131173211.1CE061E4010@bag.python.org> The Buildbot has detected a new failure of hppa Ubuntu 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/hppa%20Ubuntu%203.0/builds/478 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-ubuntu-hppa Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: 4 tests failed: test_codecmaps_kr test_urllib2net test_urllibnet test_xmlrpc_net Traceback (most recent call last): File "./Lib/test/regrtest.py", line 596, in runtest_inner indirect_test() File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_codecmaps_kr.py", line 41, in test_main test_support.run_unittest(__name__) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_support.py", line 542, in run_unittest suite.addTest(unittest.findTestCases(sys.modules[cls])) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/unittest.py", line 636, in findTestCases return _makeLoader(prefix, sortUsing, suiteClass).loadTestsFromModule(module) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/unittest.py", line 540, in loadTestsFromModule tests.append(self.loadTestsFromTestCase(obj)) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/unittest.py", line 532, in loadTestsFromTestCase return self.suiteClass(map(testCaseClass, testCaseNames)) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/unittest.py", line 387, in __init__ self.addTests(tests) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/unittest.py", line 423, in addTests for test in tests: File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_multibytecodec_support.py", line 279, in __init__ self.open_mapping_file() # test it to report the error early File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_multibytecodec_support.py", line 282, in open_mapping_file return test_support.open_urlresource(self.mapfileurl) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_support.py", line 268, in open_urlresource fn, _ = urllib.urlretrieve(url, filename) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib.py", line 88, in urlretrieve return _urlopener.retrieve(url, filename, reporthook, data) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib.py", line 230, in retrieve fp = self.open(url, data) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib.py", line 202, in open raise IOError('socket error', msg).with_traceback(sys.exc_info()[2]) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib.py", line 198, in open return getattr(self, name)(url) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib.py", line 372, in open_http return self._open_generic_http(httplib.HTTPConnection, url, data) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib.py", line 351, in _open_generic_http http_conn.request("GET", selector, headers=headers) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 884, in request self._send_request(method, url, body, headers) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 921, in _send_request self.endheaders() File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 879, in endheaders self._send_output() File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 745, in _send_output self.send(msg) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 704, in send self.connect() File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 688, in connect self.timeout) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/socket.py", line 279, in create_connection for res in getaddrinfo(host, port, 0, SOCK_STREAM): IOError: [Errno socket error] [Errno -2] Name or service not known ====================================================================== ERROR: testURLread (test.test_urllib2net.URLTimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllib2net.py", line 39, in testURLread f = _urlopen_with_retry("http://www.python.org/") File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllib2net.py", line 25, in _urlopen_with_retry raise last_exc File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllib2net.py", line 19, in _urlopen_with_retry return urllib2.urlopen(host, *args, **kwargs) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 122, in urlopen return _opener.open(url, data, timeout) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 378, in open response = self._open(req, data) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 396, in _open '_open', req) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 356, in _call_chain result = func(*args) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 1096, in http_open return self.do_open(httplib.HTTPConnection, req) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 1071, in do_open raise URLError(err) urllib2.URLError: ====================================================================== ERROR: test_basic (test.test_urllib2net.urlopenNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllib2net.py", line 118, in test_basic open_url = _urlopen_with_retry("http://www.python.org/") File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllib2net.py", line 25, in _urlopen_with_retry raise last_exc File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllib2net.py", line 19, in _urlopen_with_retry return urllib2.urlopen(host, *args, **kwargs) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 122, in urlopen return _opener.open(url, data, timeout) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 378, in open response = self._open(req, data) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 396, in _open '_open', req) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 356, in _call_chain result = func(*args) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 1096, in http_open return self.do_open(httplib.HTTPConnection, req) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 1071, in do_open raise URLError(err) urllib2.URLError: ====================================================================== ERROR: test_geturl (test.test_urllib2net.urlopenNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllib2net.py", line 142, in test_geturl open_url = _urlopen_with_retry(URL) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllib2net.py", line 25, in _urlopen_with_retry raise last_exc File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllib2net.py", line 19, in _urlopen_with_retry return urllib2.urlopen(host, *args, **kwargs) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 122, in urlopen return _opener.open(url, data, timeout) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 378, in open response = self._open(req, data) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 396, in _open '_open', req) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 356, in _call_chain result = func(*args) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 1096, in http_open return self.do_open(httplib.HTTPConnection, req) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 1071, in do_open raise URLError(err) urllib2.URLError: ====================================================================== ERROR: test_info (test.test_urllib2net.urlopenNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllib2net.py", line 129, in test_info open_url = _urlopen_with_retry("http://www.python.org/") File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllib2net.py", line 25, in _urlopen_with_retry raise last_exc File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllib2net.py", line 19, in _urlopen_with_retry return urllib2.urlopen(host, *args, **kwargs) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 122, in urlopen return _opener.open(url, data, timeout) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 378, in open response = self._open(req, data) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 396, in _open '_open', req) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 356, in _call_chain result = func(*args) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 1096, in http_open return self.do_open(httplib.HTTPConnection, req) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 1071, in do_open raise URLError(err) urllib2.URLError: ====================================================================== ERROR: test_range (test.test_urllib2net.OtherNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllib2net.py", line 173, in test_range result = _urlopen_with_retry(req) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllib2net.py", line 25, in _urlopen_with_retry raise last_exc File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllib2net.py", line 19, in _urlopen_with_retry return urllib2.urlopen(host, *args, **kwargs) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 122, in urlopen return _opener.open(url, data, timeout) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 378, in open response = self._open(req, data) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 396, in _open '_open', req) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 356, in _call_chain result = func(*args) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 1096, in http_open return self.do_open(httplib.HTTPConnection, req) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 1071, in do_open raise URLError(err) urllib2.URLError: ====================================================================== ERROR: test_close (test.test_urllib2net.CloseSocketTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllib2net.py", line 91, in test_close response = _urlopen_with_retry("http://www.python.org/") File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllib2net.py", line 25, in _urlopen_with_retry raise last_exc File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllib2net.py", line 19, in _urlopen_with_retry return urllib2.urlopen(host, *args, **kwargs) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 122, in urlopen return _opener.open(url, data, timeout) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 378, in open response = self._open(req, data) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 396, in _open '_open', req) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 356, in _call_chain result = func(*args) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 1096, in http_open return self.do_open(httplib.HTTPConnection, req) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 1071, in do_open raise URLError(err) urllib2.URLError: ====================================================================== ERROR: test_ftp_NoneNodefault (test.test_urllib2net.TimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllib2net.py", line 319, in test_ftp_NoneNodefault u = _urlopen_with_retry(self.FTP_HOST, timeout=None) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllib2net.py", line 25, in _urlopen_with_retry raise last_exc File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllib2net.py", line 19, in _urlopen_with_retry return urllib2.urlopen(host, *args, **kwargs) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 122, in urlopen return _opener.open(url, data, timeout) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 378, in open response = self._open(req, data) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 396, in _open '_open', req) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 356, in _call_chain result = func(*args) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 1263, in ftp_open raise URLError(msg) urllib2.URLError: ====================================================================== ERROR: test_ftp_NoneWithdefault (test.test_urllib2net.TimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllib2net.py", line 313, in test_ftp_NoneWithdefault u = _urlopen_with_retry(self.FTP_HOST, timeout=None) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllib2net.py", line 25, in _urlopen_with_retry raise last_exc File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllib2net.py", line 19, in _urlopen_with_retry return urllib2.urlopen(host, *args, **kwargs) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 122, in urlopen return _opener.open(url, data, timeout) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 378, in open response = self._open(req, data) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 396, in _open '_open', req) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 356, in _call_chain result = func(*args) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 1263, in ftp_open raise URLError(msg) urllib2.URLError: ====================================================================== ERROR: test_ftp_Value (test.test_urllib2net.TimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllib2net.py", line 323, in test_ftp_Value u = _urlopen_with_retry(self.FTP_HOST, timeout=60) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllib2net.py", line 25, in _urlopen_with_retry raise last_exc File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllib2net.py", line 19, in _urlopen_with_retry return urllib2.urlopen(host, *args, **kwargs) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 122, in urlopen return _opener.open(url, data, timeout) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 378, in open response = self._open(req, data) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 396, in _open '_open', req) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 356, in _call_chain result = func(*args) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 1263, in ftp_open raise URLError(msg) urllib2.URLError: ====================================================================== ERROR: test_ftp_basic (test.test_urllib2net.TimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllib2net.py", line 306, in test_ftp_basic u = _urlopen_with_retry(self.FTP_HOST) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllib2net.py", line 25, in _urlopen_with_retry raise last_exc File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllib2net.py", line 19, in _urlopen_with_retry return urllib2.urlopen(host, *args, **kwargs) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 122, in urlopen return _opener.open(url, data, timeout) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 378, in open response = self._open(req, data) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 396, in _open '_open', req) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 356, in _call_chain result = func(*args) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 1263, in ftp_open raise URLError(msg) urllib2.URLError: ====================================================================== ERROR: test_http_NoneNodefault (test.test_urllib2net.TimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllib2net.py", line 300, in test_http_NoneNodefault u = _urlopen_with_retry("http://www.python.org", timeout=None) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllib2net.py", line 25, in _urlopen_with_retry raise last_exc File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllib2net.py", line 19, in _urlopen_with_retry return urllib2.urlopen(host, *args, **kwargs) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 122, in urlopen return _opener.open(url, data, timeout) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 378, in open response = self._open(req, data) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 396, in _open '_open', req) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 356, in _call_chain result = func(*args) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 1096, in http_open return self.do_open(httplib.HTTPConnection, req) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 1071, in do_open raise URLError(err) urllib2.URLError: ====================================================================== ERROR: test_http_NoneWithdefault (test.test_urllib2net.TimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllib2net.py", line 290, in test_http_NoneWithdefault u = _urlopen_with_retry("http://www.python.org", timeout=None) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllib2net.py", line 25, in _urlopen_with_retry raise last_exc File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllib2net.py", line 19, in _urlopen_with_retry return urllib2.urlopen(host, *args, **kwargs) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 122, in urlopen return _opener.open(url, data, timeout) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 378, in open response = self._open(req, data) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 396, in _open '_open', req) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 356, in _call_chain result = func(*args) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 1096, in http_open return self.do_open(httplib.HTTPConnection, req) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 1071, in do_open raise URLError(err) urllib2.URLError: ====================================================================== ERROR: test_http_Value (test.test_urllib2net.TimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllib2net.py", line 296, in test_http_Value u = _urlopen_with_retry("http://www.python.org", timeout=120) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllib2net.py", line 25, in _urlopen_with_retry raise last_exc File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllib2net.py", line 19, in _urlopen_with_retry return urllib2.urlopen(host, *args, **kwargs) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 122, in urlopen return _opener.open(url, data, timeout) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 378, in open response = self._open(req, data) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 396, in _open '_open', req) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 356, in _call_chain result = func(*args) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 1096, in http_open return self.do_open(httplib.HTTPConnection, req) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 1071, in do_open raise URLError(err) urllib2.URLError: ====================================================================== ERROR: test_http_basic (test.test_urllib2net.TimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllib2net.py", line 283, in test_http_basic u = _urlopen_with_retry("http://www.python.org") File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllib2net.py", line 25, in _urlopen_with_retry raise last_exc File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllib2net.py", line 19, in _urlopen_with_retry return urllib2.urlopen(host, *args, **kwargs) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 122, in urlopen return _opener.open(url, data, timeout) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 378, in open response = self._open(req, data) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 396, in _open '_open', req) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 356, in _call_chain result = func(*args) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 1096, in http_open return self.do_open(httplib.HTTPConnection, req) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib2.py", line 1071, in do_open raise URLError(err) urllib2.URLError: ====================================================================== ERROR: testURLread (test.test_urllibnet.URLTimeoutTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllibnet.py", line 39, in testURLread f = _open_with_retry(urllib.urlopen, "http://www.python.org/") File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllibnet.py", line 25, in _open_with_retry raise last_exc File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllibnet.py", line 19, in _open_with_retry return func(host, *args, **kwargs) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib.py", line 80, in urlopen return opener.open(url) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib.py", line 202, in open raise IOError('socket error', msg).with_traceback(sys.exc_info()[2]) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib.py", line 198, in open return getattr(self, name)(url) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib.py", line 372, in open_http return self._open_generic_http(httplib.HTTPConnection, url, data) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib.py", line 351, in _open_generic_http http_conn.request("GET", selector, headers=headers) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 884, in request self._send_request(method, url, body, headers) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 921, in _send_request self.endheaders() File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 879, in endheaders self._send_output() File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 745, in _send_output self.send(msg) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 704, in send self.connect() File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 688, in connect self.timeout) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/socket.py", line 279, in create_connection for res in getaddrinfo(host, port, 0, SOCK_STREAM): IOError: [Errno socket error] [Errno -2] Name or service not known ====================================================================== ERROR: test_basic (test.test_urllibnet.urlopenNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllibnet.py", line 62, in test_basic open_url = self.urlopen("http://www.python.org/") File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllibnet.py", line 58, in urlopen return _open_with_retry(urllib.urlopen, *args) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllibnet.py", line 25, in _open_with_retry raise last_exc File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllibnet.py", line 19, in _open_with_retry return func(host, *args, **kwargs) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib.py", line 80, in urlopen return opener.open(url) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib.py", line 202, in open raise IOError('socket error', msg).with_traceback(sys.exc_info()[2]) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib.py", line 198, in open return getattr(self, name)(url) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib.py", line 372, in open_http return self._open_generic_http(httplib.HTTPConnection, url, data) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib.py", line 351, in _open_generic_http http_conn.request("GET", selector, headers=headers) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 884, in request self._send_request(method, url, body, headers) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 921, in _send_request self.endheaders() File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 879, in endheaders self._send_output() File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 745, in _send_output self.send(msg) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 704, in send self.connect() File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 688, in connect self.timeout) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/socket.py", line 279, in create_connection for res in getaddrinfo(host, port, 0, SOCK_STREAM): IOError: [Errno socket error] [Errno -2] Name or service not known ====================================================================== ERROR: test_fileno (test.test_urllibnet.urlopenNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllibnet.py", line 122, in test_fileno open_url = self.urlopen("http://www.python.org/") File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllibnet.py", line 58, in urlopen return _open_with_retry(urllib.urlopen, *args) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllibnet.py", line 25, in _open_with_retry raise last_exc File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllibnet.py", line 19, in _open_with_retry return func(host, *args, **kwargs) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib.py", line 80, in urlopen return opener.open(url) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib.py", line 202, in open raise IOError('socket error', msg).with_traceback(sys.exc_info()[2]) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib.py", line 198, in open return getattr(self, name)(url) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib.py", line 372, in open_http return self._open_generic_http(httplib.HTTPConnection, url, data) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib.py", line 351, in _open_generic_http http_conn.request("GET", selector, headers=headers) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 884, in request self._send_request(method, url, body, headers) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 921, in _send_request self.endheaders() File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 879, in endheaders self._send_output() File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 745, in _send_output self.send(msg) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 704, in send self.connect() File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 688, in connect self.timeout) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/socket.py", line 279, in create_connection for res in getaddrinfo(host, port, 0, SOCK_STREAM): IOError: [Errno socket error] [Errno -2] Name or service not known ====================================================================== ERROR: test_getcode (test.test_urllibnet.urlopenNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllibnet.py", line 108, in test_getcode open_url = urllib.FancyURLopener().open(URL) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib.py", line 202, in open raise IOError('socket error', msg).with_traceback(sys.exc_info()[2]) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib.py", line 198, in open return getattr(self, name)(url) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib.py", line 372, in open_http return self._open_generic_http(httplib.HTTPConnection, url, data) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib.py", line 351, in _open_generic_http http_conn.request("GET", selector, headers=headers) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 884, in request self._send_request(method, url, body, headers) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 921, in _send_request self.endheaders() File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 879, in endheaders self._send_output() File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 745, in _send_output self.send(msg) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 704, in send self.connect() File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 688, in connect self.timeout) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/socket.py", line 279, in create_connection for res in getaddrinfo(host, port, 0, SOCK_STREAM): IOError: [Errno socket error] [Errno -2] Name or service not known ====================================================================== ERROR: test_geturl (test.test_urllibnet.urlopenNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllibnet.py", line 98, in test_geturl open_url = self.urlopen(URL) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllibnet.py", line 58, in urlopen return _open_with_retry(urllib.urlopen, *args) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllibnet.py", line 25, in _open_with_retry raise last_exc File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllibnet.py", line 19, in _open_with_retry return func(host, *args, **kwargs) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib.py", line 80, in urlopen return opener.open(url) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib.py", line 202, in open raise IOError('socket error', msg).with_traceback(sys.exc_info()[2]) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib.py", line 198, in open return getattr(self, name)(url) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib.py", line 372, in open_http return self._open_generic_http(httplib.HTTPConnection, url, data) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib.py", line 351, in _open_generic_http http_conn.request("GET", selector, headers=headers) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 884, in request self._send_request(method, url, body, headers) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 921, in _send_request self.endheaders() File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 879, in endheaders self._send_output() File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 745, in _send_output self.send(msg) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 704, in send self.connect() File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 688, in connect self.timeout) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/socket.py", line 279, in create_connection for res in getaddrinfo(host, port, 0, SOCK_STREAM): IOError: [Errno socket error] [Errno -2] Name or service not known ====================================================================== ERROR: test_info (test.test_urllibnet.urlopenNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllibnet.py", line 85, in test_info open_url = self.urlopen("http://www.python.org/") File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllibnet.py", line 58, in urlopen return _open_with_retry(urllib.urlopen, *args) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllibnet.py", line 25, in _open_with_retry raise last_exc File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllibnet.py", line 19, in _open_with_retry return func(host, *args, **kwargs) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib.py", line 80, in urlopen return opener.open(url) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib.py", line 202, in open raise IOError('socket error', msg).with_traceback(sys.exc_info()[2]) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib.py", line 198, in open return getattr(self, name)(url) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib.py", line 372, in open_http return self._open_generic_http(httplib.HTTPConnection, url, data) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib.py", line 351, in _open_generic_http http_conn.request("GET", selector, headers=headers) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 884, in request self._send_request(method, url, body, headers) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 921, in _send_request self.endheaders() File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 879, in endheaders self._send_output() File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 745, in _send_output self.send(msg) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 704, in send self.connect() File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 688, in connect self.timeout) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/socket.py", line 279, in create_connection for res in getaddrinfo(host, port, 0, SOCK_STREAM): IOError: [Errno socket error] [Errno -2] Name or service not known ====================================================================== ERROR: test_readlines (test.test_urllibnet.urlopenNetworkTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllibnet.py", line 74, in test_readlines open_url = self.urlopen("http://www.python.org/") File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllibnet.py", line 58, in urlopen return _open_with_retry(urllib.urlopen, *args) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllibnet.py", line 25, in _open_with_retry raise last_exc File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/test/test_urllibnet.py", line 19, in _open_with_retry return func(host, *args, **kwargs) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib.py", line 80, in urlopen return opener.open(url) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib.py", line 202, in open raise IOError('socket error', msg).with_traceback(sys.exc_info()[2]) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib.py", line 198, in open return getattr(self, name)(url) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib.py", line 372, in open_http return self._open_generic_http(httplib.HTTPConnection, url, data) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/urllib.py", line 351, in _open_generic_http http_conn.request("GET", selector, headers=headers) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 884, in request self._send_request(method, url, body, headers) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 921, in _send_request self.endheaders() File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 879, in endheaders self._send_output() File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 745, in _send_output self.send(msg) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 704, in send self.connect() File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/httplib.py", line 688, in connect self.timeout) File "/home/pybot/buildarea/3.0.klose-ubuntu-hppa/build/Lib/socket.py", line 279, in create_connection for res in getaddrinfo(host, port, 0, SOCK_STREAM): IOError: [Errno socket error] [Errno -2] Name or service not known make: *** [buildbottest] Error 1 sincerely, -The Buildbot From python-checkins at python.org Thu Jan 31 18:45:59 2008 From: python-checkins at python.org (jeffrey.yasskin) Date: Thu, 31 Jan 2008 18:45:59 +0100 (CET) Subject: [Python-checkins] r60480 - in python/trunk/Lib: rational.py test/test_rational.py Message-ID: <20080131174559.5E3DF1E4010@bag.python.org> Author: jeffrey.yasskin Date: Thu Jan 31 18:45:59 2008 New Revision: 60480 Modified: python/trunk/Lib/rational.py python/trunk/Lib/test/test_rational.py Log: Remove unused to-be-magic methods from Rational per issue 1968. Do not port this patch to py3k. Modified: python/trunk/Lib/rational.py ============================================================================== --- python/trunk/Lib/rational.py (original) +++ python/trunk/Lib/rational.py Thu Jan 31 18:45:59 2008 @@ -410,40 +410,6 @@ __int__ = __trunc__ - def __floor__(a): - """Will be math.floor(a) in 3.0.""" - return a.numerator // a.denominator - - def __ceil__(a): - """Will be math.ceil(a) in 3.0.""" - # The negations cleverly convince floordiv to return the ceiling. - return -(-a.numerator // a.denominator) - - def __round__(self, ndigits=None): - """Will be round(self, ndigits) in 3.0. - - Rounds half toward even. - """ - if ndigits is None: - floor, remainder = divmod(self.numerator, self.denominator) - if remainder * 2 < self.denominator: - return floor - elif remainder * 2 > self.denominator: - return floor + 1 - # Deal with the half case: - elif floor % 2 == 0: - return floor - else: - return floor + 1 - shift = 10**abs(ndigits) - # See _operator_fallbacks.forward to check that the results of - # these operations will always be Rational and therefore have - # __round__(). - if ndigits > 0: - return Rational((self * shift).__round__(), shift) - else: - return Rational((self / shift).__round__() * shift) - def __hash__(self): """hash(self) Modified: python/trunk/Lib/test/test_rational.py ============================================================================== --- python/trunk/Lib/test/test_rational.py (original) +++ python/trunk/Lib/test/test_rational.py Thu Jan 31 18:45:59 2008 @@ -197,14 +197,6 @@ def testConversions(self): self.assertTypedEquals(-1, trunc(R(-11, 10))) self.assertTypedEquals(-1, int(R(-11, 10))) - self.assertTypedEquals(-2, R(-11, 10).__floor__()) - self.assertTypedEquals(-1, R(-11, 10).__ceil__()) - self.assertTypedEquals(-1, R(-10, 10).__ceil__()) - - self.assertTypedEquals(0, R(-1, 10).__round__()) - self.assertTypedEquals(0, R(-5, 10).__round__()) - self.assertTypedEquals(-2, R(-15, 10).__round__()) - self.assertTypedEquals(-1, R(-7, 10).__round__()) self.assertEquals(False, bool(R(0, 1))) self.assertEquals(True, bool(R(3, 2))) @@ -218,13 +210,6 @@ self.assertTypedEquals(0.1+0j, complex(R(1,10))) - def testRound(self): - self.assertTypedEquals(R(-200), R(-150).__round__(-2)) - self.assertTypedEquals(R(-200), R(-250).__round__(-2)) - self.assertTypedEquals(R(30), R(26).__round__(-1)) - self.assertTypedEquals(R(-2, 10), R(-15, 100).__round__(1)) - self.assertTypedEquals(R(-2, 10), R(-25, 100).__round__(1)) - def testArithmetic(self): self.assertEquals(R(1, 2), R(1, 10) + R(2, 5)) From lists at cheimes.de Thu Jan 31 19:03:55 2008 From: lists at cheimes.de (Christian Heimes) Date: Thu, 31 Jan 2008 19:03:55 +0100 Subject: [Python-checkins] r60480 - in python/trunk/Lib: rational.py test/test_rational.py In-Reply-To: <20080131174559.5E3DF1E4010@bag.python.org> References: <20080131174559.5E3DF1E4010@bag.python.org> Message-ID: <47A20D8B.6080706@cheimes.de> jeffrey.yasskin wrote: > Remove unused to-be-magic methods from Rational per issue 1968. Do not port > this patch to py3k. The svnmerge.py script has an option to block a revision. .../py3k$ svnmerge.py block -r60480 $ svn proplist -v ... svnmerge-blocked : /python/trunk:60480 svnmerge-integrated : /python/trunk:1-60474 ... You can make my life easier if you set the block option for me. Christian From stackless-checkins-bounces at stackless.com Thu Jan 31 18:16:18 2008 From: stackless-checkins-bounces at stackless.com (stackless-checkins-bounces at stackless.com) Date: Thu, 31 Jan 2008 18:16:18 +0100 Subject: [Python-checkins] Your message to Stackless-checkins awaits moderator approval Message-ID: Your mail to 'Stackless-checkins' with the subject r60478 - in stackless/branches/release25-maint: Doc/README Doc/html/about.html Doc/html/stdabout.dat Doc/lib/libcsv.tex Doc/lib/libhashlib.tex Doc/lib/liblogging.tex Doc/lib/libmarshal.tex Doc/lib/libmsilib.tex Doc/lib/liboptparse.tex Doc/lib/libos.tex Doc/ref/ref2.tex Doc/ref/ref3.tex Doc/tut/tut.tex Include/patchlevel.h Lib/bsddb/dbtables.py Lib/bsddb/test/test_misc.py Lib/bsddb/test/test_recno.py Lib/calendar.py Lib/contextlib.py Lib/ctypes Lib/ctypes/__init__.py Lib/ctypes/test/test_delattr.py Lib/ctypes/test/test_numbers.py Lib/curses/textpad.py Lib/decimal.py Lib/distutils/command/build_scripts.py Lib/distutils/util.py Lib/doctest.py Lib/encodings/__init__.py Lib/encodings/utf_8_sig.py Lib/hmac.py Lib/logging/handlers.py Lib/mailbox.py Lib/optparse.py Lib/os.py Lib/pdb.py Lib/plat-mac/plistlib.py Lib/posixpath.py Lib/smtpd.py Lib/smtplib.py Lib/sre_compile.py Lib/subprocess.py Lib/tarfile.py Lib/test/crashers/dangerous_subclassing.py Lib/test/crashers/modify_d! ict_attr.py Lib/test/crashers/weakref_in_del.py Lib/test/decimaltestdata/abs.decTest Lib/test/decimaltestdata/add.decTest Lib/test/decimaltestdata/and.decTest Lib/test/decimaltestdata/base.decTest Lib/test/decimaltestdata/clamp.decTest Lib/test/decimaltestdata/class.decTest Lib/test/decimaltestdata/compare.decTest Lib/test/decimaltestdata/comparetotal.decTest Lib/test/decimaltestdata/comparetotmag.decTest Lib/test/decimaltestdata/copy.decTest Lib/test/decimaltestdata/copyabs.decTest Lib/test/decimaltestdata/copynegate.decTest Lib/test/decimaltestdata/copysign.decTest Lib/test/decimaltestdata/ddAbs.decTest Lib/test/decimaltestdata/ddAdd.decTest Lib/test/decimaltestdata/ddAnd.decTest Lib/test/decimaltestdata/ddBase.decTest Lib/test/decimaltestdata/ddCanonical.decTest Lib/test/decimaltestdata/ddClass.decTest Lib/test/decimaltestdata/ddCompare.decTest Lib/test/decimaltestdata/ddCompareSig.decTest Lib/test/decimaltestdata/ddCompareTotal.decTest Lib/test/decimaltestdata/ddCompare! TotalMag.decTest Lib/test/decimaltestdata/ddCopy.decTest Lib/test/decimaltestdata/ddCopyAbs.decTest Lib/test/decimaltestdata/ddCopyNegate.decTest Lib/test/decimaltestdata/ddCopySign.decTest Lib/test/decimaltestdata/ddDivide.decTest Lib/test/decimaltestdata/ddDivideInt.decTest Lib/test/decimaltestdata/ddEncode.decTest Lib/tes Is being held until the list moderator can review it for approval. The reason it is being held: Message body is too big: 955415 bytes with a limit of 500 KB Either the message will get posted to the list, or you will receive notification of the moderator's decision. If you would like to cancel this posting, please visit the following URL: http://www.stackless.com/mailman/confirm/stackless-checkins/9b55f5e59ded2e474b411c9ef080b5543e87ac5e From buildbot at python.org Thu Jan 31 19:13:26 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 31 Jan 2008 18:13:26 +0000 Subject: [Python-checkins] buildbot failure in S-390 Debian trunk Message-ID: <20080131181326.EA10B1E4010@bag.python.org> The Buildbot has detected a new failure of S-390 Debian trunk. Full details are available at: http://www.python.org/dev/buildbot/all/S-390%20Debian%20trunk/builds/22 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-debian-s390 Build Reason: Build Source Stamp: [branch trunk] HEAD Blamelist: jeffrey.yasskin BUILD FAILED: failed failed slave lost sincerely, -The Buildbot From buildbot at python.org Thu Jan 31 19:20:30 2008 From: buildbot at python.org (buildbot at python.org) Date: Thu, 31 Jan 2008 18:20:30 +0000 Subject: [Python-checkins] buildbot failure in sparc Ubuntu 3.0 Message-ID: <20080131182030.C2F461E4010@bag.python.org> The Buildbot has detected a new failure of sparc Ubuntu 3.0. Full details are available at: http://www.python.org/dev/buildbot/all/sparc%20Ubuntu%203.0/builds/64 Buildbot URL: http://www.python.org/dev/buildbot/all/ Buildslave for this Build: klose-ubuntu-sparc Build Reason: Build Source Stamp: [branch branches/py3k] HEAD Blamelist: christian.heimes BUILD FAILED: failed test Excerpt from the test logfile: 9 tests failed: test_codecmaps_cn test_codecmaps_jp test_codecmaps_kr test_codecmaps_tw test_normalization test_ssl test_urllib2net test_urllibnet test_xmlrpc_net make: *** [buildbottest] Error 1 sincerely, -The Buildbot From nnorwitz at gmail.com Thu Jan 31 23:25:11 2008 From: nnorwitz at gmail.com (Neal Norwitz) Date: Thu, 31 Jan 2008 17:25:11 -0500 Subject: [Python-checkins] Python Regression Test Failures refleak (1) Message-ID: <20080131222511.GA9855@python.psfb.org> test_cmd_line leaked [0, 23, -23] references, sum=0 test_marshal leaked [32, 32, 32] references, sum=96 test_threadedtempfile leaked [0, 80, -80] references, sum=0 test_threadsignals leaked [-8, 0, 0] references, sum=-8 test_urllib2_localnet leaked [-116, 3, 3] references, sum=-110 From python-checkins at python.org Thu Jan 31 23:07:17 2008 From: python-checkins at python.org (raymond.hettinger) Date: Thu, 31 Jan 2008 23:07:17 +0100 (CET) Subject: [Python-checkins] r60482 - python/trunk/Lib/rational.py Message-ID: <20080131220717.078011E4012@bag.python.org> Author: raymond.hettinger Date: Thu Jan 31 23:07:16 2008 New Revision: 60482 Modified: python/trunk/Lib/rational.py Log: Minor wordsmithing on docstring Modified: python/trunk/Lib/rational.py ============================================================================== --- python/trunk/Lib/rational.py (original) +++ python/trunk/Lib/rational.py Thu Jan 31 23:07:16 2008 @@ -193,20 +193,20 @@ Rational, that means that we define __add__ and __radd__ as: def __add__(self, other): + # Both types have numerators/denominator attributes, + # so do the operation directly if isinstance(other, (int, long, Rational)): - # Do the real operation. return Rational(self.numerator * other.denominator + other.numerator * self.denominator, self.denominator * other.denominator) - # float and complex don't follow this protocol, and - # Rational knows about them, so special case them. + # float and complex don't have those operations, but we + # know about those types, so special case them. elif isinstance(other, float): return float(self) + other elif isinstance(other, complex): return complex(self) + other - else: - # Let the other type take over. - return NotImplemented + # Let the other type take over. + return NotImplemented def __radd__(self, other): # radd handles more types than add because there's @@ -219,8 +219,7 @@ return float(other) + float(self) elif isinstance(other, Complex): return complex(other) + complex(self) - else: - return NotImplemented + return NotImplemented There are 5 different cases for a mixed-type addition on From python-checkins at python.org Thu Jan 31 23:17:38 2008 From: python-checkins at python.org (mark.dickinson) Date: Thu, 31 Jan 2008 23:17:38 +0100 (CET) Subject: [Python-checkins] r60483 - in python/trunk: Lib/test/test_complex.py Misc/NEWS Python/compile.c Message-ID: <20080131221738.309021E4012@bag.python.org> Author: mark.dickinson Date: Thu Jan 31 23:17:37 2008 New Revision: 60483 Modified: python/trunk/Lib/test/test_complex.py python/trunk/Misc/NEWS python/trunk/Python/compile.c Log: Issue #1678380. Fix a bug that identifies 0j and -0j when they appear in the same code unit. The fix is essentially the same as the fix for a previous bug identifying 0. and -0. Modified: python/trunk/Lib/test/test_complex.py ============================================================================== --- python/trunk/Lib/test/test_complex.py (original) +++ python/trunk/Lib/test/test_complex.py Thu Jan 31 23:17:37 2008 @@ -359,6 +359,13 @@ except (OSError, IOError): pass + if float.__getformat__("double").startswith("IEEE"): + def test_plus_minus_0j(self): + # test that -0j and 0j literals are not identified + z1, z2 = 0j, -0j + self.assertEquals(atan2(z1.imag, -1.), atan2(0., -1.)) + self.assertEquals(atan2(z2.imag, -1.), atan2(-0., -1.)) + def test_main(): test_support.run_unittest(ComplexTest) Modified: python/trunk/Misc/NEWS ============================================================================== --- python/trunk/Misc/NEWS (original) +++ python/trunk/Misc/NEWS Thu Jan 31 23:17:37 2008 @@ -12,6 +12,9 @@ Core and builtins ----------------- +- Issue #1678380: Fix a bug that identifies 0j and -0j when they appear + in the same code unit. + - Patch #1970 by Antoine Pitrou: Speedup unicode whitespace and linebreak detection Modified: python/trunk/Python/compile.c ============================================================================== --- python/trunk/Python/compile.c (original) +++ python/trunk/Python/compile.c Thu Jan 31 23:17:37 2008 @@ -907,24 +907,59 @@ { PyObject *t, *v; Py_ssize_t arg; + unsigned char *p, *q; + Py_complex z; + double d; + int real_part_zero, imag_part_zero; /* necessary to make sure types aren't coerced (e.g., int and long) */ /* _and_ to distinguish 0.0 from -0.0 e.g. on IEEE platforms */ if (PyFloat_Check(o)) { - double d = PyFloat_AS_DOUBLE(o); - unsigned char* p = (unsigned char*) &d; - /* all we need is to make the tuple different in either the 0.0 - * or -0.0 case from all others, just to avoid the "coercion". - */ - if (*p==0 && p[sizeof(double)-1]==0) - t = PyTuple_Pack(3, o, o->ob_type, Py_None); - else - t = PyTuple_Pack(2, o, o->ob_type); - } else { - t = PyTuple_Pack(2, o, o->ob_type); + d = PyFloat_AS_DOUBLE(o); + p = (unsigned char*) &d; + /* all we need is to make the tuple different in either the 0.0 + * or -0.0 case from all others, just to avoid the "coercion". + */ + if (*p==0 && p[sizeof(double)-1]==0) + t = PyTuple_Pack(3, o, o->ob_type, Py_None); + else + t = PyTuple_Pack(2, o, o->ob_type); + } + else if (PyComplex_Check(o)) { + /* complex case is even messier: we need to make complex(x, + 0.) different from complex(x, -0.) and complex(0., y) + different from complex(-0., y), for any x and y. In + particular, all four complex zeros should be + distinguished.*/ + z = PyComplex_AsCComplex(o); + p = (unsigned char*) &(z.real); + q = (unsigned char*) &(z.imag); + /* all that matters here is that on IEEE platforms + real_part_zero will be true if z.real == 0., and false if + z.real == -0. In fact, real_part_zero will also be true + for some other rarely occurring nonzero floats, but this + doesn't matter. Similar comments apply to + imag_part_zero. */ + real_part_zero = *p==0 && p[sizeof(double)-1]==0; + imag_part_zero = *q==0 && q[sizeof(double)-1]==0; + if (real_part_zero && imag_part_zero) { + t = PyTuple_Pack(4, o, o->ob_type, Py_True, Py_True); + } + else if (real_part_zero && !imag_part_zero) { + t = PyTuple_Pack(4, o, o->ob_type, Py_True, Py_False); + } + else if (!real_part_zero && imag_part_zero) { + t = PyTuple_Pack(4, o, o->ob_type, Py_False, Py_True); + } + else { + t = PyTuple_Pack(2, o, o->ob_type); + } + } + else { + t = PyTuple_Pack(2, o, o->ob_type); } if (t == NULL) - return -1; + return -1; v = PyDict_GetItem(dict, t); if (!v) {